sqllogictest
Artifact Content
Not logged in

Artifact b70dc48a1b7fd465b556973f9b88c6dccd9fc8ec:


hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - - 24 + + 1 FROM tab1 AS cor0
----
25
25
25

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( col2 ) * cor0.col0 + + 34 + col2 * col0 col2 FROM tab0 AS cor0
----
1294
19834
656854

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + 82 * - col1 + - col2 col1 FROM tab2 AS cor0
----
-1415
-2538
-4805

query I rowsort
SELECT + col1 * - 81 + col2 FROM tab1 cor0
----
-2052
-753
-957

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

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

skipif mysql # not compatible
query I rowsort label-10
SELECT + - col0 + CAST ( col0 + + col2 AS INTEGER ) AS col0 FROM tab2 cor0
----
26
27
38

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

query I rowsort
SELECT + col2 * 3 + + col0 FROM tab2 cor0
----
156
193
88

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

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

query I rowsort
SELECT col0 * col1 * col0 + col2 + + col1 AS col2 FROM tab2 AS cor0
----
106152
1577
359041

onlyif mysql # use DIV operator for integer division
query I rowsort label-15
SELECT DISTINCT - tab1.col1 + 57 DIV + col1 + tab1.col0 col0 FROM tab1
----
-21
59
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-15
SELECT DISTINCT - tab1.col1 + 57 / + col1 + tab1.col0 col0 FROM tab1
----
-21
59
71

query I rowsort
SELECT DISTINCT + col2 + + col0 + - col2 * tab1.col1 * + col0 AS col2 FROM tab1
----
-36359
-4155
-99664

query I rowsort
SELECT + + cor0.col1 + + col1 - + col2 FROM tab1 cor0
----
-2
-37
-70

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

query I rowsort
SELECT - - 23 * col2 FROM tab2 AS cor0
----
598
621
874

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-23
SELECT + col0 DIV + col2 + + col2 * + col2 FROM tab1 AS cor0
----
2916
3250
9216

skipif mysql # not compatible
query I rowsort label-23
SELECT + col0 / + col2 + + col2 * + col2 FROM tab1 AS cor0
----
2916
3250
9216

query I rowsort
SELECT DISTINCT + - col1 * col1 + cor0.col1 * col2 * cor0.col1 + col2 * cor0.col1 * - col0 FROM tab1 AS cor0
----
-30880
-83785
31616

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

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

query I rowsort
SELECT - 16 * col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-129584
-33024
-54320

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

query I rowsort
SELECT col0 + - tab2.col0 * col0 AS col2 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT + col2 + col1 + col0 FROM tab1
----
131
189
83

query I rowsort
SELECT - 23 * col1 + + col0 + + tab1.col2 AS col2 FROM tab1
----
-109
-123
-541

query I rowsort
SELECT DISTINCT + 68 FROM tab2 cor0
----
68

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

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

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

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

query I rowsort
SELECT + 2 * col2 + + col2 * + col1 FROM tab1 AS cor0
----
1440
1512
684

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

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

query I rowsort
SELECT DISTINCT - 15 AS col0 FROM tab2, tab2 AS cor0
----
-15

query I rowsort
SELECT + tab2.col0 * col2 * 64 + - col0 * - col2 FROM tab2
----
12285
131820
195130

query I rowsort
SELECT DISTINCT + 45 AS col0 FROM tab2
----
45

query I rowsort
SELECT ALL - - cor0.col2 + + 9 AS col1 FROM tab1 AS cor0
----
105
63
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-43
SELECT DISTINCT + col1 * 89 DIV col2 FROM tab1 AS cor0
----
12
15
42

skipif mysql # not compatible
query I rowsort label-43
SELECT DISTINCT + col1 * 89 / col2 FROM tab1 AS cor0
----
12
15
42

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-45
SELECT - col1 + + 0 / col2 col1 FROM tab0 AS cor0
----
-86
-91
-97

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

query I rowsort
SELECT DISTINCT + col2 + + col1 * cor0.col1 + col0 AS col0 FROM tab2 AS cor0
----
3585
406
995

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

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

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

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

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

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

query I rowsort
SELECT col2 + - col2 + col2 AS col1 FROM tab2
----
26
27
38

query IIIIII rowsort
SELECT ALL * FROM tab2, tab1 cor0 WHERE NOT ( NULL ) NOT BETWEEN ( NULL ) AND ( NULL )
----

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

query I rowsort
SELECT ALL - - cor0.col2 + - 13 FROM tab2 AS cor0
----
13
14
25

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

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

query I rowsort
SELECT ALL - 69 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

query I rowsort
SELECT DISTINCT - col0 * 54 FROM tab1
----
-162
-3456
-4320

onlyif mysql # use DIV operator for integer division
query I rowsort label-61
SELECT + col2 * + col0 - + col0 DIV + tab2.col1 AS col2 FROM tab2
----
189
2027
2998

skipif mysql # not compatible
query I rowsort label-61
SELECT + col2 * + col0 - + col0 / + tab2.col1 AS col2 FROM tab2
----
189
2027
2998

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

query I rowsort
SELECT col1 + - 33 AS col1 FROM tab1
----
-20
-23
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-64
SELECT + col0 + - tab2.col0 * col2 DIV + tab2.col1 AS col1 FROM tab2
----
-97
1
44

skipif mysql # not compatible
query I rowsort label-64
SELECT + col0 + - tab2.col0 * col2 / + tab2.col1 AS col1 FROM tab2
----
-97
1
44

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

query I rowsort
SELECT + + ( 92 ) * - cor0.col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 4c5806b2f86d805048fe1a64c57161ec

onlyif mysql # use DIV operator for integer division
query I rowsort label-67
SELECT ALL - - col2 * - col1 + + 67 DIV - col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-67
SELECT ALL - - col2 * - col1 + + 67 / - col1 FROM tab0 AS cor0
----
-2838
-7462
-97

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-69
SELECT + 52 DIV + cor0.col1 + 1 AS col1 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-69
SELECT + 52 / + cor0.col1 + 1 AS col1 FROM tab2 AS cor0
----
1
2
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-70
SELECT - CAST( 65 AS SIGNED ) + col0 + + col0 FROM tab1
----
-59
63
95

skipif mysql # not compatible
query I rowsort label-70
SELECT - CAST ( 65 AS INTEGER ) + col0 + + col0 FROM tab1
----
-59
63
95

query I rowsort
SELECT DISTINCT - 28 * + cor0.col2 FROM tab2, tab0, tab2 AS cor0
----
-1064
-728
-756

query I rowsort
SELECT DISTINCT + ( 83 * col2 ) AS col2 FROM tab0
----
2739
6806
83

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

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

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

query I rowsort
SELECT DISTINCT - cor0.col1 + - col2 + - 36 AS col0 FROM tab1 AS cor0
----
-103
-116
-145

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

query I rowsort
SELECT - col0 + - col0 + - col1 FROM tab2 AS cor0
----
-175
-215
-45

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

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

query I rowsort
SELECT ALL + col0 * col2 + + tab1.col1 * col2 * + tab1.col0 FROM tab1
----
107520
40128
4374

query I rowsort
SELECT - tab0.col1 + - col0 + col1 FROM tab0
----
-24
-35
-89

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

query I rowsort
SELECT DISTINCT - 83 + col0 FROM tab2 cor0
----
-4
-5
-76

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

query I rowsort
SELECT + 6 * col0 AS col0 FROM tab2
----
42
468
474

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-87
SELECT - cor0.col0 + - CAST( 43 AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
-3722
-4002
-4206

skipif mysql # not compatible
query I rowsort label-87
SELECT - cor0.col0 + - CAST ( 43 AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
-3722
-4002
-4206

query I rowsort
SELECT DISTINCT - col0 + + ( + col2 ) * - cor0.col0 * - col2 FROM tab1 AS cor0
----
207872
737200
8745

query I rowsort
SELECT DISTINCT col0 - + 69 * col0 FROM tab0 AS cor0
----
-1632
-2380
-6052

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-91
SELECT ALL + - col1 DIV - CAST( col0 AS SIGNED ) + + cor0.col0 + + col2 * - col1 col2 FROM tab0 AS cor0
----
-2811
-60
-7372

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-91
SELECT ALL + - col1 / - CAST ( col0 AS INTEGER ) + + cor0.col0 + + col2 * - col1 col2 FROM tab0 AS cor0
----
-2811
-60
-7372

query I rowsort
SELECT ALL + - col1 + 98 FROM tab0 AS cor0
----
1
12
7

query I rowsort
SELECT DISTINCT - cor0.col2 * + 35 FROM tab0 cor0
----
-1155
-2870
-35

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

query I rowsort
SELECT DISTINCT col1 * + 88 FROM tab2 AS cor0
----
1496
2728
5192

query I rowsort
SELECT ALL - col0 + col1 * col2 + cor0.col1 FROM tab1 AS cor0
----
1181
1427
516

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

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

query I rowsort
SELECT DISTINCT + + cor0.col0 - col2 * + 67 AS col0 FROM tab0 AS cor0
----
-2187
-32
-5405

query I rowsort
SELECT ALL - - cor0.col0 * + col2 + + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-1272
-3360
-801

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-103
SELECT DISTINCT - col0 + CAST( col0 AS SIGNED ) * - col0 * - col1 + - col0 * - col2 FROM tab1 AS cor0
----
393
44544
90800

skipif mysql # not compatible
query I rowsort label-103
SELECT DISTINCT - col0 + CAST ( col0 AS INTEGER ) * - col0 * - col1 + - col0 * - col2 FROM tab1 AS cor0
----
393
44544
90800

query I rowsort
SELECT DISTINCT + cor0.col0 * 36 + + col0 FROM tab0 cor0
----
1295
3293
888

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-106
SELECT - + cor0.col1 DIV - 89 + - 68 * - col0 FROM tab2 cor0
----
476
5304
5372

skipif mysql # not compatible
query I rowsort label-106
SELECT - + cor0.col1 / - 89 + - 68 * - col0 FROM tab2 cor0
----
476
5304
5372

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

query I rowsort
SELECT DISTINCT col1 + 88 FROM tab1 AS cor0
----
101
114
98

query I rowsort
SELECT ALL cor0.col1 * 98 * col1 AS col0 FROM tab1 AS cor0
----
16562
66248
9800

query I rowsort
SELECT - + 36 * col0 FROM tab0 cor0
----
-1260
-3204
-864

onlyif mysql # use DIV operator for integer division
query I rowsort label-111
SELECT + col1 + + col0 DIV col1 AS col1 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-111
SELECT + col1 + + col0 / col1 AS col1 FROM tab2 AS cor0
----
21
31
60

query I rowsort
SELECT DISTINCT - - 82 * + col0 - cor0.col2 AS col1 FROM tab2 AS cor0
----
547
6370
6440

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

query I rowsort
SELECT 92 + col2 * col0 FROM tab0
----
127
7390
884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + ( col2 ) - col2 col0 FROM tab2 AS cor0
----
-17
-31
-59

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

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

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

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

query I rowsort
SELECT DISTINCT ( + 98 ) - col0 FROM tab2 AS cor0
----
19
20
91

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

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

query I rowsort
SELECT + - 55 * col2 + + col2 + + col1 FROM tab0 AS cor0
----
-1696
-4337
43

query I rowsort
SELECT DISTINCT + - 51 + - col0 FROM tab2 cor0
----
-129
-130
-58

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

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

query I rowsort
SELECT ALL col0 * - col0 + - col0 AS col0 FROM tab0 cor0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT + 52 - col1 AS col1 FROM tab2 AS cor0
----
-7
21
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 13 ) + + cor0.col2 * col1 col1 FROM tab2 AS cor0
----
1521
633
824

onlyif mysql # use DIV operator for integer division
query I rowsort label-129
SELECT DISTINCT + 53 DIV - col1 AS col1 FROM tab1
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-129
SELECT DISTINCT + 53 / - col1 AS col1 FROM tab1
----
-2
-4
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-130
SELECT - 92 DIV 33 FROM tab2 AS cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-130
SELECT - 92 / 33 FROM tab2 AS cor0
----
-2
-2
-2

query I rowsort
SELECT - col2 * - 16 FROM tab1 AS cor0
----
1536
864
912

query I rowsort
SELECT DISTINCT + 56 - ( col2 ) * 93 FROM tab1 AS cor0
----
-4966
-5245
-8872

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

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

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

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

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

query I rowsort
SELECT - 11 * 40 AS col2 FROM tab1 AS cor0
----
-440
-440
-440

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

query I rowsort
SELECT - ( - cor0.col1 ) * 25 AS col1 FROM tab1 AS cor0
----
250
325
650

query I rowsort
SELECT DISTINCT - + col0 * - 50 FROM tab0 AS cor0
----
1200
1750
4450

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

query I rowsort
SELECT - + col1 + - col1 + ( col0 ) AS col1 FROM tab0 AS cor0
----
-148
-159
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-142
SELECT + cor0.col0 DIV col2 + cor0.col0 + col2 * - CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
165
3713
7760

skipif mysql # not compatible
query I rowsort label-142
SELECT + cor0.col0 / col2 + cor0.col0 + col2 * - CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
165
3713
7760

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 23 + + col1 * col0 * - 6 col1 FROM tab0
----
-12407
-20393
-48617

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-147
SELECT col0 DIV - 31 + tab2.col2 FROM tab2
----
24
27
36

skipif mysql # not compatible
query I rowsort label-147
SELECT col0 / - 31 + tab2.col2 FROM tab2
----
24
27
36

query I rowsort
SELECT DISTINCT - cor0.col1 * ( 35 ) * col0 AS col2 FROM tab2 cor0
----
-161070
-47005
-7595

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

query I rowsort
SELECT ALL + 94 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT - 18 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

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

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

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

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

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

query I rowsort
SELECT ALL col2 + col1 * ( + col1 ) + col0 * col2 * - 66 AS col2 FROM tab0 AS cor0
----
-44843
-473305
7100

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

query I rowsort
SELECT + col0 + col1 * col0 - - col0 FROM tab0 AS cor0
----
2112
3465
8277

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

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

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

query I rowsort
SELECT DISTINCT - col1 + - ( + 84 ) AS col2 FROM tab2 AS cor0
----
-101
-115
-143

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 + col1 * col1 col1 FROM tab1 AS cor0
----
4196
6569
685

onlyif mysql # use DIV operator for integer division
query I rowsort label-164
SELECT DISTINCT col2 * - col1 DIV + col1 - col1 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-164
SELECT DISTINCT col2 * - col1 / + col1 - col1 FROM tab0 AS cor0
----
-119
-173
-98

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

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

query I rowsort
SELECT + col2 * - 80 + col0 FROM tab2 AS cor0
----
-2002
-2153
-2961

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

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

query I rowsort
SELECT ALL + 84 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

query I rowsort
SELECT - col0 + cor0.col2 * ( col0 + + col0 ) * - 28 AS col1 FROM tab2 AS cor0
----
-10591
-113646
-168191

query I rowsort
SELECT - col1 * col0 + ( - cor0.col2 + col0 ) FROM tab1 AS cor0
----
-1056
-129
-633

query I rowsort
SELECT ALL + 4 + + col2 * + col2 FROM tab2 AS cor0
----
1448
680
733

query I rowsort
SELECT DISTINCT 56 + + col0 FROM tab1 AS cor0
----
120
136
59

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

query I rowsort
SELECT - col0 * + col0 + tab2.col0 FROM tab2
----
-42
-6006
-6162

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

query I rowsort
SELECT ALL + col0 * 13 FROM tab1 AS cor0
----
1040
39
832

query I rowsort
SELECT ALL - 85 + tab1.col0 * + 90 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 1908a79271540204e7fd6071896bd1aa

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

query I rowsort
SELECT DISTINCT + col1 * 57 * 42 FROM tab2 AS cor0
----
141246
40698
74214

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-181
SELECT + 24 * + col2 + + CAST( - col0 AS SIGNED ) FROM tab1
----
1293
1304
2224

skipif mysql # not compatible
query I rowsort label-181
SELECT + 24 * + col2 + + CAST ( - col0 AS INTEGER ) FROM tab1
----
1293
1304
2224

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

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

query I rowsort
SELECT - 97 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

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

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

query I rowsort
SELECT ALL col2 * - col0 * + col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE col0 + + col1 + col1 = ( NULL )
----

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-190
SELECT col1 * - col0 + col2 * col2 DIV - col1 + - col0 FROM tab1
----
-1028
-1828
-193

skipif mysql # not compatible
query I rowsort label-190
SELECT col1 * - col0 + col2 * col2 / - col1 + - col0 FROM tab1
----
-1028
-1828
-193

onlyif mysql # use DIV operator for integer division
query I rowsort label-191
SELECT col0 DIV - col1 + - col0 AS col2 FROM tab2
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-191
SELECT col0 / - col1 + - col0 AS col2 FROM tab2
----
-7
-79
-83

query I rowsort
SELECT ALL col1 + col0 + col0 AS col1 FROM tab1
----
138
173
32

query I rowsort
SELECT DISTINCT - col0 * + col0 * col0 + - col2 * col1 FROM tab1
----
-1431
-262714
-513248

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

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

query I rowsort
SELECT - col1 * + col2 + col0 * + col1 FROM tab2 WHERE NOT + col0 * col1 <> NULL
----

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

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

query I rowsort
SELECT ALL col2 * + col0 + - col0 + tab1.col2 AS col1 FROM tab1
----
213
3641
7696

query I rowsort
SELECT DISTINCT col1 + tab2.col0 * + tab2.col0 AS col0 FROM tab2
----
6143
6258
80

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

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

query I rowsort
SELECT ALL + col1 + tab1.col1 * - col0 + col1 AS col1 FROM tab1
----
-1014
-26
-620

query I rowsort
SELECT ALL - tab0.col2 - col1 FROM tab0 WHERE NOT - col2 - col0 NOT BETWEEN NULL AND + col0
----

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-205
SELECT DISTINCT - col1 + + tab1.col0 + col0 DIV + col2 FROM tab1
----
-23
55
67

skipif mysql # not compatible
query I rowsort label-205
SELECT DISTINCT - col1 + + tab1.col0 + col0 / + col2 FROM tab1
----
-23
55
67

query I rowsort
SELECT ALL + col1 + col1 + + col2 AS col0 FROM tab0
----
195
205
264

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

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

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

query I rowsort
SELECT DISTINCT col2 + - col0 + + col2 * col0 AS col2 FROM tab1
----
213
3641
7696

onlyif mysql # use DIV operator for integer division
query I rowsort label-211
SELECT ALL + col2 DIV col1 col2 FROM tab2
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-211
SELECT ALL + col2 / col1 col2 FROM tab2
----
0
0
2

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

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

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

query I rowsort
SELECT - col1 * col1 - + col1 AS col2 FROM tab2 cor0
----
-306
-3540
-992

onlyif mysql # use DIV operator for integer division
query I rowsort label-216
SELECT DISTINCT + - col0 * + col0 + + 2 DIV - col2 col1 FROM tab0 AS cor0
----
-1227
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-216
SELECT DISTINCT + - col0 * + col0 + + 2 / - col2 col1 FROM tab0 AS cor0
----
-1227
-576
-7921

query I rowsort
SELECT ALL + col1 * col1 - col1 * 38 FROM tab0
----
4128
4823
5723

query I rowsort
SELECT DISTINCT - 25 * + col1 - - col0 AS col2 FROM tab0
----
-2126
-2186
-2390

query I rowsort
SELECT ALL col1 + col0 * - col0 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT + + col1 + col2 * - col1 + - 66 FROM tab2 AS cor0
----
-1541
-695
-872

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-222
SELECT DISTINCT - ( + col1 ) + + CAST( + col2 + col1 * + ( - col0 ) AS SIGNED ) FROM tab2
----
-1322
-221
-4635

skipif mysql # not compatible
query I rowsort label-222
SELECT DISTINCT - ( + col1 ) + + CAST ( + col2 + col1 * + ( - col0 ) AS INTEGER ) FROM tab2
----
-1322
-221
-4635

onlyif mysql # use DIV operator for integer division
query I rowsort label-223
SELECT + col0 DIV - col0 - + cor0.col1 AS col0 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-223
SELECT + col0 / - col0 - + cor0.col1 AS col0 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT ALL + col0 * col1 * - 22 + + col1 FROM tab2 AS cor0
----
-101185
-29529
-4743

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

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

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

query I rowsort
SELECT DISTINCT - - col0 + col0 * - 67 FROM tab1 AS cor0
----
-198
-4224
-5280

query I rowsort
SELECT 7 * cor0.col2 * 19 - - cor0.col2 AS col1 FROM tab0 AS cor0
----
10988
134
4422

query I rowsort
SELECT - col1 * + col1 * 20 FROM tab2 AS cor0
----
-19220
-5780
-69620

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-232
SELECT + ( - col0 ) DIV + 33 + - col0 + col2 col0 FROM tab1 AS cor0
----
-8
14
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-232
SELECT + ( - col0 ) / + 33 + - col0 + col2 col0 FROM tab1 AS cor0
----
-8
14
51

query I rowsort
SELECT DISTINCT + col0 + + col0 * ( + col2 * + col1 ) AS col1 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT DISTINCT + 18 FROM tab0 cor0
----
18

query I rowsort
SELECT - - 69 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1794
-1863
-2622

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

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

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

query I rowsort
SELECT DISTINCT - col1 * - ( col1 ) - col0 AS col1 FROM tab2 AS cor0
----
210
3403
954

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

skipif mysql # not compatible
query I rowsort label-240
SELECT - col1 + + CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
0
0
0

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

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

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

query I rowsort
SELECT DISTINCT - cor2.col2 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab2 cor2
----
-26
-27
-38

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

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab1 cor1, tab2, tab2 cor2
----
3645 values hashing to 803a5565701c4ced6bba69940782c17a

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

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

query I rowsort
SELECT + ( + 77 ) + - col1 FROM tab2 AS cor0
----
18
46
60

query I rowsort
SELECT 69 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to dfada1ee7a4e3e5c74a063a1282769f9

query I rowsort
SELECT DISTINCT col1 + - 29 * col1 AS col1 FROM tab2 AS cor0
----
-1652
-476
-868

query I rowsort
SELECT DISTINCT - tab2.col1 * - cor0.col0 + 95 FROM tab2, tab0, tab1 AS cor0
----
9 values hashing to c5501b8e314df73aa1d511923a8f74ad

query I rowsort
SELECT ALL - + 83 + - col0 * - 48 AS col1 FROM tab0 AS cor0
----
1069
1597
4189

query I rowsort
SELECT ALL + 91 + col2 * 59 FROM tab1 AS cor0
----
3277
3454
5755

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

query I rowsort
SELECT DISTINCT + 28 AS col0 FROM tab0, tab1, tab2 AS cor0
----
28

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

query I rowsort
SELECT ALL + col2 + - col2 * col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT - col0 + ( 92 ) * + col1 FROM tab1 cor0
----
1116
2389
856

onlyif mysql # use DIV operator for integer division
query I rowsort label-260
SELECT ALL + col1 - ( - col0 ) DIV col1 AS col1 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-260
SELECT ALL + col1 - ( - col0 ) / col1 AS col1 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT col1 + 16 * col2 AS col1 FROM tab0 AS cor0
----
113
1403
614

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( 29 ) * + col0 col2 FROM tab1 cor0
----
-1856
-2320
-87

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

query I rowsort
SELECT ALL - + cor0.col0 + - 59 + - col0 * + col0 AS col2 FROM tab2 cor0
----
-115
-6221
-6379

query I rowsort
SELECT ALL - ( col2 ) * cor0.col0 - - col2 * - col2 * cor0.col0 FROM tab0 AS cor0
----
-26928
-605734
-70

query I rowsort
SELECT DISTINCT - - 89 AS col1 FROM tab0 AS cor0
----
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( + 46 ) + col0 col0 FROM tab1 cor0
----
110
126
49

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

query I rowsort
SELECT 62 + col0 FROM tab0 cor0
----
151
86
97

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

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

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

skipif mysql # not compatible
query I rowsort label-272
SELECT + + col2 / - 67 + + col2 / - col0 AS col1 FROM tab1 cor0
----
-18
-2
0

query I rowsort
SELECT ALL + - 92 * + col2 AS col2 FROM tab0 AS cor0
----
-3036
-7544
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-274
SELECT - cor0.col1 DIV - col0 + + 87 * + 39 * col1 FROM tab1 AS cor0
----
33930
44109
88226

skipif mysql # not compatible
query I rowsort label-274
SELECT - cor0.col1 / - col0 + + 87 * + 39 * col1 FROM tab1 AS cor0
----
33930
44109
88226

query I rowsort
SELECT + + 87 * col1 + + col2 AS col2 FROM tab0 cor0
----
7515
7999
8440

query I rowsort
SELECT + 65 * col0 + - col2 AS col2 FROM tab1 AS cor0
----
141
4103
5104

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

skipif mysql # not compatible
query I rowsort label-277
SELECT CAST ( - col1 AS INTEGER ) + col0 * tab0.col0 AS col0 FROM tab0
----
1128
490
7830

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

query I rowsort
SELECT ( col1 ) * + 42 * + col2 FROM tab0 AS cor0
----
119196
313404
4074

query I rowsort
SELECT - col0 + cor0.col1 * 50 FROM tab0 AS cor0
----
4276
4461
4815

query I rowsort
SELECT - cor0.col1 + + col0 - + col1 * col1 AS col0 FROM tab0 AS cor0
----
-7458
-8283
-9471

query I rowsort
SELECT ALL + 87 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT 70 - col1 FROM tab2 AS cor0
----
11
39
53

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

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

query I rowsort
SELECT col0 * ( - col0 ) + - col2 FROM tab1 AS cor0
----
-4153
-63
-6496

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-288
SELECT DISTINCT 53 DIV 57 AS col0 FROM tab1, tab0 cor0, tab2 AS cor1, tab0 AS cor2
----
0

skipif mysql # not compatible
query I rowsort label-288
SELECT DISTINCT 53 / 57 AS col0 FROM tab1, tab0 cor0, tab2 AS cor1, tab0 AS cor2
----
0

query I rowsort
SELECT + 62 * - col1 AS col0 FROM tab1 cor0
----
-1612
-620
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( ( col1 ) ) * ( 87 ) col0 FROM tab1 AS cor0
----
1131
2262
870

query I rowsort
SELECT DISTINCT + col1 * - 89 * 89 FROM tab0
----
-681206
-720811
-768337

query I rowsort
SELECT - 3 * + 68 FROM tab1
----
-204
-204
-204

query I rowsort
SELECT - 77 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT 10 + + cor0.col0 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to a7f9858d7adcd26c9f98d68301f7ff86

query I rowsort
SELECT 97 * col2 FROM tab0
----
3201
7954
97

query I rowsort
SELECT - 62 * col2 FROM tab2
----
-1612
-1674
-2356

query I rowsort
SELECT DISTINCT - tab0.col2 * + 84 - tab0.col2 FROM tab0
----
-2805
-6970
-85

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-300
SELECT + ( - col0 ) * + col0 + - 97 DIV cor0.col1 AS col1 FROM tab1 AS cor0
----
-12
-4105
-6407

skipif mysql # not compatible
query I rowsort label-300
SELECT + ( - col0 ) * + col0 + - 97 / cor0.col1 AS col1 FROM tab1 AS cor0
----
-12
-4105
-6407

query I rowsort
SELECT ALL + col1 * + col2 + cor0.col0 * ( col2 ) AS col1 FROM tab1 cor0
----
1566
4218
8928

query I rowsort
SELECT DISTINCT cor0.col2 * 98 + col2 FROM tab2 AS cor0
----
2574
2673
3762

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

query I rowsort
SELECT ALL + ( 42 ) * + col2 + + 88 * + col2 AS col0 FROM tab2 AS cor0
----
3380
3510
4940

onlyif mysql # use DIV operator for integer division
query I rowsort label-305
SELECT - col0 DIV 13 + - cor0.col1 * col1 + - col1 FROM tab1 cor0
----
-114
-188
-702

skipif mysql # not compatible
query I rowsort label-305
SELECT - col0 / 13 + - cor0.col1 * col1 + - col1 FROM tab1 cor0
----
-114
-188
-702

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

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

query I rowsort
SELECT - - col0 * - cor0.col2 * col1 + + 42 * col1 + - col0 FROM tab2 AS cor0
----
-117252
-4564
-50399

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

skipif mysql # not compatible
query I rowsort label-308
SELECT ALL ( - col1 ) + col2 + + CAST ( + 11 AS INTEGER ) * col1 FROM tab2 AS cor0
----
208
337
616

query I rowsort
SELECT - - col2 + + 81 + + col1 * col2 FROM tab1 cor0
----
1425
1539
708

query I rowsort
SELECT col2 + + col1 * - ( - col1 + - col0 * - col2 ) FROM tab1 AS cor0
----
-3482
-36323
-99575

query I rowsort
SELECT ALL + cor0.col0 + - cor0.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 1c0f12b2ac8c8b522b92205460500f94

query I rowsort
SELECT - + 47 FROM tab1, tab0 AS cor0
----
9 values hashing to 6942a0d9558277afd0d00408d65cf5aa

query I rowsort
SELECT - 33 * - col2 + - 85 AS col2 FROM tab0
----
-52
1004
2621

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-315
SELECT + col0 * - col2 + CAST( - tab1.col1 AS SIGNED ) * col0 * + col1 AS col1 FROM tab1
----
-10048
-21200
-2190

skipif mysql # not compatible
query I rowsort label-315
SELECT + col0 * - col2 + CAST ( - tab1.col1 AS INTEGER ) * col0 * + col1 AS col1 FROM tab1
----
-10048
-21200
-2190

onlyif mysql # use DIV operator for integer division
query I rowsort label-316
SELECT DISTINCT - 37 DIV cor0.col0 + - col1 - cor0.col1 FROM tab0 AS cor0
----
-173
-182
-195

skipif mysql # not compatible
query I rowsort label-316
SELECT DISTINCT - 37 / cor0.col0 + - col1 - cor0.col1 FROM tab0 AS cor0
----
-173
-182
-195

query I rowsort
SELECT - 66 + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-163
-2904
-7528

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

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

query I rowsort
SELECT DISTINCT cor0.col1 * - 75 AS col2 FROM tab0 AS cor0
----
-6450
-6825
-7275

query I rowsort
SELECT DISTINCT - col1 * col2 + - cor0.col0 * col1 AS col1 FROM tab1 cor0
----
-1210
-1482
-2288

query I rowsort
SELECT cor0.col1 - 87 * cor0.col1 AS col2 FROM tab0 cor0
----
-7396
-7826
-8342

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

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

query I rowsort
SELECT + + col2 * - 23 AS col1 FROM tab1 AS cor0
----
-1242
-1311
-2208

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

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

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

query I rowsort
SELECT 54 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 81150d59d6c3fc48b4ef5a4a5495bc7a

query I rowsort
SELECT DISTINCT - col2 * ( 32 + + cor0.col2 ) FROM tab2 AS cor0
----
-1508
-1593
-2660

query I rowsort
SELECT ALL - col0 + col1 * + col2 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT 51 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

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

query I rowsort
SELECT ALL 48 * - tab1.col2 FROM tab1
----
-2592
-2736
-4608

query I rowsort
SELECT ALL + col0 * + 45 AS col2 FROM tab1 AS cor0
----
135
2880
3600

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

query I rowsort
SELECT DISTINCT col0 * 25 FROM tab1
----
1600
2000
75

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

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

query I rowsort
SELECT ALL col1 * - 3 AS col2 FROM tab0
----
-258
-273
-291

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-340
SELECT DISTINCT - col1 + - col0 DIV 11 AS col0 FROM tab1 AS cor0
----
-15
-20
-26

skipif mysql # not compatible
query I rowsort label-340
SELECT DISTINCT - col1 + - col0 / 11 AS col0 FROM tab1 AS cor0
----
-15
-20
-26

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-342
SELECT cor0.col1 + cor0.col1 * - CAST( ( col2 ) AS SIGNED ) + - col2 col1 FROM tab2 AS cor0
----
-1501
-667
-833

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-342
SELECT cor0.col1 + cor0.col1 * - CAST ( ( col2 ) AS INTEGER ) + - col2 col1 FROM tab2 AS cor0
----
-1501
-667
-833

query I rowsort
SELECT DISTINCT - 20 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
-1180
-340
-620

query I rowsort
SELECT DISTINCT - cor0.col2 + - col1 * col0 + - 86 * - col1 FROM tab1 AS cor0
----
-18
163
2104

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

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

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

query I rowsort
SELECT ALL 68 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 * col0 * col2 - col1 col2 FROM tab2
----
126067
7907
85117

query I rowsort
SELECT 46 * ( + tab2.col0 * ( - tab2.col1 ) ) + col0 + + col1 FROM tab2
----
-211555
-61682
-9944

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

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

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

query I rowsort
SELECT ALL col1 * - col2 + - col1 + col2 FROM tab2
----
-1567
-625
-841

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

query I rowsort
SELECT ALL + 19 * - cor0.col2 FROM tab2 cor0
----
-494
-513
-722

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

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

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

query I rowsort
SELECT DISTINCT - col0 * col0 * ( 80 + col1 ) FROM tab1 AS cor0
----
-368640
-595200
-954

query I rowsort
SELECT + col0 + - 86 FROM tab2 AS cor0
----
-7
-79
-8

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-360
SELECT + ( 74 ) + col2 DIV cor0.col1 FROM tab2 AS cor0
----
74
74
76

skipif mysql # not compatible
query I rowsort label-360
SELECT + ( 74 ) + col2 / cor0.col1 FROM tab2 AS cor0
----
74
74
76

query I rowsort
SELECT - + cor0.col0 * col2 * - col0 + ( - col2 * - col2 ) FROM tab1 AS cor0
----
236721
3402
623616

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

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

query I rowsort
SELECT + 73 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

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

query I rowsort
SELECT ALL + col0 + - col2 + - col1 FROM tab2
----
-51
-7
24

query I rowsort
SELECT DISTINCT - col2 + + 79 FROM tab2
----
41
52
53

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( 31 AS REAL ) FROM tab0 AS cor0
----
31

query I rowsort
SELECT DISTINCT + - 83 * col1 AS col0 FROM tab1 AS cor0
----
-1079
-2158
-830

query I rowsort
SELECT ALL - 27 * col1 AS col0 FROM tab2 AS cor0
----
-1593
-459
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-371
SELECT + CAST( + 44 AS SIGNED ) * col2 + ( col1 ) * col0 DIV + 1 AS col0 FROM tab2 AS cor0
----
1405
3015
5746

skipif mysql # not compatible
query I rowsort label-371
SELECT + CAST ( + 44 AS INTEGER ) * col2 + ( col1 ) * col0 / + 1 AS col0 FROM tab2 AS cor0
----
1405
3015
5746

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-373
SELECT - 87 DIV col1 + - col2 AS col1 FROM tab0 AS cor0
----
-1
-34
-82

skipif mysql # not compatible
query I rowsort label-373
SELECT - 87 / col1 + - col2 AS col1 FROM tab0 AS cor0
----
-1
-34
-82

query I rowsort
SELECT - 99 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
1287
2574
990

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

query I rowsort
SELECT ALL - cor0.col2 * + col0 * - col0 + + 11 AS col1 FROM tab1 AS cor0
----
233483
497
614411

query I rowsort
SELECT DISTINCT - - 68 + + cor0.col0 FROM tab1 AS cor0
----
132
148
71

query I rowsort
SELECT DISTINCT - 87 + - col1 * + cor0.col2 FROM tab0 AS cor0
----
-184
-2925
-7549

onlyif mysql # use DIV operator for integer division
query I rowsort label-379
SELECT DISTINCT - cor0.col1 * col2 + + 6 - col0 DIV col2 FROM tab0 AS cor0
----
-126
-2832
-7457

skipif mysql # not compatible
query I rowsort label-379
SELECT DISTINCT - cor0.col1 * col2 + + 6 - col0 / col2 FROM tab0 AS cor0
----
-126
-2832
-7457

query I rowsort
SELECT ALL + + 78 + - col1 AS col1 FROM tab1 AS cor0
----
52
65
68

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

query I rowsort
SELECT ALL + + col1 * col1 + col2 * col0 AS col1 FROM tab0 AS cor0
----
15579
8188
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + ( col0 + col2 * - col1 ) col0 FROM tab1 AS cor0
----
-32384
-4203
-93440

query I rowsort
SELECT DISTINCT + - col2 * - 88 + ( cor0.col1 ) * 49 FROM tab0 AS cor0
----
11675
4841
7118

query I rowsort
SELECT - cor0.col1 + - 65 AS col0 FROM tab1 AS cor0
----
-75
-78
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 21 * col2 col2 FROM tab1
----
-11970
-26208
-29484

query I rowsort
SELECT col2 + 73 FROM tab2 AS cor0
----
100
111
99

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

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

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

query I rowsort
SELECT col1 + cor0.col1 + - cor0.col2 FROM tab1 cor0
----
-2
-37
-70

query I rowsort
SELECT DISTINCT - col2 * + 41 AS col0 FROM tab1 AS cor0
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT - + col2 + + col1 + + col2 AS col2 FROM tab2 AS cor0
----
17
31
59

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-396
SELECT + ( col1 ) + - col2 DIV + col0 AS col2 FROM tab2 AS cor0
----
17
28
59

skipif mysql # not compatible
query I rowsort label-396
SELECT + ( col1 ) + - col2 / + col0 AS col2 FROM tab2 AS cor0
----
17
28
59

query I rowsort
SELECT - col1 + 69 * col2 * 72 AS col2 FROM tab0 AS cor0
----
163858
407285
4871

query I rowsort
SELECT 83 - col2 FROM tab0 AS cor0
----
1
50
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-399
SELECT + + ( - ( col1 ) ) DIV + CAST( col0 * col2 AS SIGNED ) + cor0.col0 FROM tab0 cor0
----
24
33
89

skipif mysql # not compatible
query I rowsort label-399
SELECT + + ( - ( col1 ) ) / + CAST ( col0 * col2 AS INTEGER ) + cor0.col0 FROM tab0 cor0
----
24
33
89

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

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

query I rowsort
SELECT DISTINCT - + ( + col1 ) * col0 + col0 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT 21 * col2 * col2 AS col2 FROM tab1 cor0
----
193536
61236
68229

query I rowsort
SELECT - 60 + cor0.col1 * col2 * - col2 AS col0 FROM tab2 AS cor0
----
-22659
-24608
-39944

query I rowsort
SELECT - col2 * col2 * ( + col0 ) FROM tab1 cor0
----
-207936
-737280
-8748

query I rowsort
SELECT ALL - - 23 * col0 AS col0 FROM tab0 AS cor0
----
2047
552
805

query I rowsort
SELECT - 63 + + col0 + col1 AS col2 FROM tab2 AS cor0
----
-25
33
74

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

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

query I rowsort
SELECT col2 * 88 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-249744
-656656
-8536

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

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

query I rowsort
SELECT DISTINCT 75 * cor0.col0 FROM tab1 AS cor0
----
225
4800
6000

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-414
SELECT ALL 9 DIV col2 - 8 FROM tab0
----
-8
-8
1

skipif mysql # not compatible
query I rowsort label-414
SELECT ALL 9 / col2 - 8 FROM tab0
----
-8
-8
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 15 + col0 * col2 col1 FROM tab1 AS cor0
----
177
3663
7695

query I rowsort
SELECT ALL - tab1.col2 * + col2 - + col0 * tab1.col0 * col1 FROM tab1
----
-3150
-44209
-92416

query I rowsort
SELECT - 80 AS col1 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 26dbcc98d4b4e864ffa31be685a5dfbd

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-419
SELECT ALL col1 DIV - 10 + + 40 AS col2 FROM tab1
----
38
39
39

skipif mysql # not compatible
query I rowsort label-419
SELECT ALL col1 / - 10 + + 40 AS col2 FROM tab1
----
38
39
39

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

skipif mysql # not compatible
query I rowsort label-420
SELECT + - col1 / ( col0 ) + col2 FROM tab1 AS cor0
----
46
57
96

query I rowsort
SELECT col0 - - ( + 93 * - col0 ) AS col2 FROM tab0
----
-2208
-3220
-8188

query I rowsort
SELECT - tab2.col0 + ( + col0 ) * + col2 AS col2 FROM tab2
----
182
1950
2923

query I rowsort
SELECT ALL ( - col1 ) + - cor0.col2 + 61 AS col0 FROM tab1 AS cor0
----
-19
-48
-6

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

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

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

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

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

query I rowsort
SELECT DISTINCT + col2 * + 74 * - col2 + - ( cor0.col2 ) * col2 AS col2 FROM tab0 AS cor0
----
-504300
-75
-81675

query I rowsort
SELECT ALL + col2 * col1 * col2 + 84 AS col1 FROM tab1 AS cor0
----
119892
32574
75900

query I rowsort
SELECT - col2 + 96 * col0 FROM tab1
----
234
6087
7584

query I rowsort
SELECT ALL + col2 + - col0 * + col2 * 58 AS col2 FROM tab2 AS cor0
----
-10935
-117598
-174078

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + ( + cor0.col2 ) + + ( 29 * + col2 ) col1 FROM tab0 AS cor0
----
2378
29
957

query I rowsort
SELECT 47 * col1 + col1 FROM tab1
----
1248
480
624

query I rowsort
SELECT - ( ( - tab0.col1 ) ) * + tab0.col1 + col0 FROM tab0
----
7420
8370
9444

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-437
SELECT DISTINCT ( + col2 ) * + col2 - - CAST( col1 AS SIGNED ) * + col2 FROM tab0 AS cor0
----
14186
3927
98

skipif mysql # not compatible
query I rowsort label-437
SELECT DISTINCT ( + col2 ) * + col2 - - CAST ( col1 AS INTEGER ) * + col2 FROM tab0 AS cor0
----
14186
3927
98

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

query I rowsort
SELECT ALL + col2 + 31 FROM tab0 AS cor0
----
113
32
64

query I rowsort
SELECT ALL + col1 + col1 - col2 * ( 12 ) FROM tab2 AS cor0
----
-194
-262
-422

query I rowsort
SELECT DISTINCT - - 15 + + col2 AS col0 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT ALL + - 48 * + col1 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
-10416
-220896
-64464

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

skipif mysql # not compatible
query I rowsort label-443
SELECT ALL - ( + col0 ) + - CAST ( + 72 AS INTEGER ) - + col1 FROM tab2 AS cor0
----
-110
-168
-209

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

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

query I rowsort
SELECT - ( col0 ) + - col2 * + col2 * + col2 FROM tab0
----
-35961
-36
-551457

query I rowsort
SELECT DISTINCT col2 * 47 AS col0 FROM tab2 AS cor0
----
1222
1269
1786

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

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

query I rowsort
SELECT DISTINCT - col2 + - ( - ( - col1 ) + ( 62 ) ) AS col1 FROM tab1 AS cor0
----
-129
-142
-171

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

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

query I rowsort
SELECT + + col0 * + 36 - - col2 * + col0 FROM tab0 AS cor0
----
10502
1295
1656

query I rowsort
SELECT ALL - col2 + + 12 AS col0 FROM tab2 AS cor0
----
-14
-15
-26

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

query I rowsort
SELECT + col2 + ( col2 + - cor0.col0 ) AS col2 FROM tab1 AS cor0
----
105
112
50

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-455
SELECT DISTINCT - - col0 + CAST ( NULL AS REAL ) * 1 * + col1 col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col0 * + col0 + 30 + col2 AS col0 FROM tab1 AS cor0
----
-4009
-6274
75

query I rowsort
SELECT ALL + 98 AS col1 FROM tab2
----
98
98
98

query I rowsort
SELECT - col1 * + 65 * ( - col2 * col0 ) AS col0 FROM tab1 AS cor0
----
2371200
273780
6489600

query I rowsort
SELECT col2 * - 2 AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT + - col0 * + 29 AS col1 FROM tab1 AS cor0
----
-1856
-2320
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-461
SELECT + tab1.col0 + - 92 DIV ( col1 ) AS col0 FROM tab1
----
0
55
73

skipif mysql # not compatible
query I rowsort label-461
SELECT + tab1.col0 + - 92 / ( col1 ) AS col0 FROM tab1
----
0
55
73

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

query I rowsort
SELECT + 99 FROM tab1, tab0 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to c841a8d826151b422ecdb71db0250739

query I rowsort
SELECT + - col0 * - col2 + - 55 + + col2 * - col2 FROM tab2 AS cor0
----
-595
1297
1503

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

query I rowsort
SELECT DISTINCT - cor0.col0 * 7 FROM tab1 AS cor0
----
-21
-448
-560

query I rowsort
SELECT - col2 * 21 AS col1 FROM tab1 cor0
----
-1134
-1197
-2016

query I rowsort
SELECT + col1 * + 31 AS col0 FROM tab1
----
310
403
806

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

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

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

query I rowsort
SELECT ALL + col2 + + 21 FROM tab0
----
103
22
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-473
SELECT + col2 DIV - col1 - + cor0.col1 FROM tab2 cor0
----
-19
-31
-59

skipif mysql # not compatible
query I rowsort label-473
SELECT + col2 / - col1 - + cor0.col1 FROM tab2 cor0
----
-19
-31
-59

query I rowsort
SELECT + + 21 + - cor0.col2 * + col0 FROM tab1 AS cor0
----
-141
-3627
-7659

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

skipif mysql # not compatible
query I rowsort label-475
SELECT DISTINCT col2 * + CAST ( + ( + col2 ) AS INTEGER ) + - col2 AS col0 FROM tab2
----
1406
650
702

query I rowsort
SELECT - tab0.col0 * 65 AS col0 FROM tab0
----
-1560
-2275
-5785

query I rowsort
SELECT 10 * - ( tab0.col1 ) + ( - col2 ) FROM tab0
----
-893
-971
-992

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

skipif mysql # not compatible
query I rowsort label-478
SELECT + CAST ( col2 * col0 AS INTEGER ) FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 62 ) col1 FROM tab2
----
62
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 43 col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-43

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

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

query I rowsort
SELECT + + cor0.col2 + col2 * - col0 * 48 AS col2 FROM tab0 cor0
----
-1679
-350222
-37983

query I rowsort
SELECT - 13 * + col1 FROM tab1 AS cor0
----
-130
-169
-338

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

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

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

query I rowsort
SELECT + ( col0 ) + 94 * - col2 FROM tab0 cor0
----
-3078
-59
-7619

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

query I rowsort
SELECT DISTINCT + cor0.col0 * - col0 + + 9 * col1 FROM tab2 AS cor0
----
-5553
-6088
230

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

query I rowsort
SELECT - col0 * col0 + - col2 FROM tab1 AS cor0
----
-4153
-63
-6496

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col1 + - CAST ( + 4 AS REAL ) FROM tab0 AS cor0
----
82
87
93

query I rowsort
SELECT ALL cor0.col2 AS col2 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL col1 + - col0 + - col0 AS col0 FROM tab2
----
-141
-97
17

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

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

query I rowsort
SELECT - col1 * + 29 FROM tab0 AS cor0
----
-2494
-2639
-2813

query I rowsort
SELECT - col0 * - col0 + - col1 * - 75 * col1 AS col0 FROM tab0 AS cor0
----
555276
628996
706900

query I rowsort
SELECT 45 + + col2 FROM tab1 AS cor0
----
102
141
99

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-501
SELECT - CAST ( - col1 AS INTEGER ) + - col0 col2 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT ALL - - 51 AS col0 FROM tab0 AS cor0
----
51
51
51

query I rowsort
SELECT DISTINCT + ( cor0.col0 ) + col1 + - 27 AS col1 FROM tab2 AS cor0
----
11
110
69

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

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

query I rowsort
SELECT DISTINCT tab0.col1 * tab0.col2 + - col0 + 92 AS col1 FROM tab0
----
154
2906
7465

query I rowsort
SELECT col2 * col0 * + cor0.col2 + + col0 FROM tab2 AS cor0
----
114155
5110
52806

query I rowsort
SELECT ALL 34 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

onlyif mysql # use DIV operator for integer division
query I rowsort label-508
SELECT DISTINCT col1 DIV col1 + + col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-508
SELECT DISTINCT col1 / col1 + + col2 FROM tab1
----
55
58
97

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

query III rowsort
SELECT ALL * FROM tab2 WHERE col1 <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col0 col2 FROM tab1
----
121
176
57

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

query I rowsort
SELECT ALL col1 - + col2 * col0 FROM tab1 WHERE NULL >= NULL
----

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

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

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

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

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT BETWEEN NULL AND - col2 / col1
----

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

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

query I rowsort
SELECT DISTINCT 31 + col1 AS col1 FROM tab1 cor0
----
41
44
57

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 * 64 + col2 FROM tab0 AS cor0
----
-2239
-466990
-50655

query I rowsort
SELECT DISTINCT col1 * + col0 + 31 AS col2 FROM tab1 cor0
----
1071
109
671

onlyif mysql # use DIV operator for integer division
query I rowsort label-523
SELECT ALL - 60 DIV col1 FROM tab1 AS cor0
----
-2
-4
-6

skipif mysql # not compatible
query I rowsort label-523
SELECT ALL - 60 / col1 FROM tab1 AS cor0
----
-2
-4
-6

query III rowsort
SELECT ALL * FROM tab2 WHERE col0 = ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-525
SELECT ALL col0 DIV tab1.col0 + + col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-525
SELECT ALL col0 / tab1.col0 + + col1 FROM tab1
----
11
14
27

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

query III rowsort
SELECT * FROM tab1 WHERE NOT col0 BETWEEN + col1 + col1 AND col0
----
3
26
54

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

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

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

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

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

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT NULL NOT IN ( - cor0.col1 * col0 / cor0.col2 )
----

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 / + col0 - col0 * - col2 col1 FROM tab0 WHERE NOT NULL NOT IN ( col2 )
----

query I rowsort
SELECT col1 * tab1.col1 * col2 AS col0 FROM tab1 WHERE NOT col2 IN ( + col1 * + col1 * - col0 )
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-538
SELECT - tab2.col0 DIV - tab2.col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-538
SELECT - tab2.col0 / - tab2.col1 FROM tab2
----
0
1
4

query I rowsort
SELECT col1 + col0 * col1 * + col1 + + col0 AS col1 FROM tab0 AS cor0
----
177614
329447
737189

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) >= ( col1 + - col0 * col1 )
----

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

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

query I rowsort
SELECT DISTINCT col0 + + 48 FROM tab1
----
112
128
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-544
SELECT col2 + ( + tab0.col1 ) DIV - col0 AS col2 FROM tab0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-544
SELECT col2 + ( + tab0.col1 ) / - col0 AS col2 FROM tab0
----
-1
30
81

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

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

query I rowsort
SELECT DISTINCT + + 68 FROM tab0 cor0
----
68

query I rowsort
SELECT DISTINCT + 43 AS col0 FROM tab1
----
43

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

query I rowsort
SELECT ALL 8 * - col0 AS col0 FROM tab2
----
-56
-624
-632

query I rowsort
SELECT 93 * - col0 AS col2 FROM tab2
----
-651
-7254
-7347

query I rowsort
SELECT + col1 + col2 * - col1 + + col0 AS col0 FROM tab2 cor0
----
-1397
-550
-799

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

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

query I rowsort
SELECT ALL cor0.col2 * 9 FROM tab2 AS cor0
----
234
243
342

query I rowsort
SELECT + 59 + - col2 FROM tab0 AS cor0
----
-23
26
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-555
SELECT ALL ( - col2 ) + 24 DIV col1 FROM tab1
----
-54
-55
-95

skipif mysql # not compatible
query I rowsort label-555
SELECT ALL ( - col2 ) + 24 / col1 FROM tab1
----
-54
-55
-95

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

query I rowsort
SELECT DISTINCT - 44 * col1 FROM tab2 AS cor0
----
-1364
-2596
-748

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

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

query I rowsort
SELECT + 74 + + col2 * + col1 AS col1 FROM tab2 AS cor0
----
1608
720
911

onlyif mysql # use DIV operator for integer division
query I rowsort label-561
SELECT DISTINCT - 41 DIV col0 AS col2 FROM tab1 AS cor0
----
-13
0

skipif mysql # not compatible
query I rowsort label-561
SELECT DISTINCT - 41 / col0 AS col2 FROM tab1 AS cor0
----
-13
0

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

query I rowsort
SELECT DISTINCT + + col0 * + 66 + - 2 + col1 AS col1 FROM tab0 AS cor0
----
1668
2405
5963

query I rowsort
SELECT DISTINCT - cor0.col2 * 82 FROM tab2 AS cor0
----
-2132
-2214
-3116

query I rowsort
SELECT DISTINCT - col2 + - 54 * col2 AS col1 FROM tab0 AS cor0
----
-1815
-4510
-55

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-567
SELECT - col2 - - col1 * col0 DIV - col2 AS col0 FROM tab0 AS cor0
----
-180
-3396
-95

skipif mysql # not compatible
query I rowsort label-567
SELECT - col2 - - col1 * col0 / - col2 AS col0 FROM tab0 AS cor0
----
-180
-3396
-95

query I rowsort
SELECT ALL + - col1 + - 72 * ( col1 * - 49 ) FROM tab0 AS cor0
----
303322
320957
342119

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col2 - ( + col1 ) * + col1 col1 FROM tab1 cor0
----
-157
-265
-730

query I rowsort
SELECT DISTINCT - col0 * - 56 + + col1 + + col0 AS col0 FROM tab2 AS cor0
----
430
4505
4520

query I rowsort
SELECT + col1 * - 60 + 37 * + col2 FROM tab2 cor0
----
-2578
-861
386

query I rowsort
SELECT ALL col2 + 53 * col2 AS col0 FROM tab1 cor0
----
2916
3078
5184

query I rowsort
SELECT - col2 - 96 AS col1 FROM tab2 AS cor0
----
-122
-123
-134

query I rowsort
SELECT DISTINCT + col2 + - ( col1 ) * + col0 * - 52 AS col1 FROM tab1 AS cor0
----
33337
4110
54176

query I rowsort
SELECT ALL + col2 + - cor0.col0 * + col0 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT - col1 * - col0 * cor0.col0 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
225
36864
76800

query I rowsort
SELECT col1 * - col0 * + 7 FROM tab1
----
-4480
-546
-7280

query I rowsort
SELECT 35 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

query I rowsort
SELECT 3 * + col0 + tab2.col1 * col2 - + col2 * col0 * + tab2.col2 FROM tab2
----
-113193
-4245
-50960

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

query I rowsort
SELECT ALL - + col2 + + col2 * - col2 * + col1 AS col2 FROM tab0 AS cor0
----
-611966
-93687
-98

query I rowsort
SELECT + 4 - tab1.col2 * 8 FROM tab1
----
-428
-452
-764

query I rowsort
SELECT 13 + + col0 + - 41 * - col1 FROM tab2
----
1291
2510
789

query I rowsort
SELECT col2 * col1 * + col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT 36 AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 4d1892e880125dc90345721151acb22c

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

skipif mysql # not compatible
query I rowsort label-586
SELECT ALL - CAST ( col0 * col0 AS INTEGER ) FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT + col1 + + ( col0 ) * col0 FROM tab0 AS cor0
----
1322
662
8012

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col1 - col1 col0 FROM tab0 AS cor0
----
-194
-2924
-7553

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

query I rowsort
SELECT ALL - 79 + cor0.col1 * col2 + - 36 AS col2 FROM tab1 AS cor0
----
1133
1289
455

query I rowsort
SELECT 55 * col2 FROM tab2 cor0
----
1430
1485
2090

query I rowsort
SELECT 75 * col0 FROM tab1 AS cor0
----
225
4800
6000

query I rowsort
SELECT ALL + + col2 + - col1 * - col0 + + 25 FROM tab0 AS cor0
----
2122
3421
8206

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL col2 + col0 * - col0 AS col2 FROM tab2
----
-22
-6058
-6203

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

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

query I rowsort
SELECT - col2 + + cor0.col1 * 42 AS col0 FROM tab2 AS cor0
----
1275
2452
676

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

query I rowsort
SELECT col0 * - 50 FROM tab1 AS cor0
----
-150
-3200
-4000

query I rowsort
SELECT + col1 * + 31 AS col1 FROM tab0
----
2666
2821
3007

query I rowsort
SELECT DISTINCT + tab2.col2 AS col2 FROM tab2, tab0, tab1 AS cor0
----
26
27
38

query I rowsort
SELECT col1 * ( 60 ) AS col2 FROM tab1
----
1560
600
780

query I rowsort
SELECT DISTINCT 97 * - 17 AS col0 FROM tab1
----
-1649

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

query I rowsort
SELECT 21 - col2 AS col0 FROM tab0
----
-12
-61
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + 7 ) + col1 col1 FROM tab1
----
17
20
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-617
SELECT cor0.col0 - - ( col1 ) DIV col2 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-617
SELECT cor0.col0 - - ( col1 ) / col2 FROM tab0 AS cor0
----
132
26
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-618
SELECT - ( col0 ) * CAST( col0 AS SIGNED ) * + cor0.col1 - + 66 DIV col1 AS col2 FROM tab2 AS cor0
----
-106100
-1521
-358957

skipif mysql # not compatible
query I rowsort label-618
SELECT - ( col0 ) * CAST ( col0 AS INTEGER ) * + cor0.col1 - + 66 / col1 AS col2 FROM tab2 AS cor0
----
-106100
-1521
-358957

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 76 * col1 col2 FROM tab0
----
156864
258020
615524

query I rowsort
SELECT + + col2 * - ( + col0 ) * col1 + 86 * + col0 FROM tab1 cor0
----
-30976
-3954
-92960

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

query I rowsort
SELECT - col2 * + 8 AS col2 FROM tab0 cor0
----
-264
-656
-8

query I rowsort
SELECT col2 * + col1 + 17 FROM tab2 AS cor0
----
1551
663
854

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

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

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

query I rowsort
SELECT DISTINCT col2 * - col2 + 39 FROM tab1 cor0
----
-2877
-3210
-9177

query I rowsort
SELECT + + cor0.col0 + - col0 * + col0 FROM tab0 cor0
----
-1190
-552
-7832

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

skipif mysql # not compatible
query I rowsort label-629
SELECT DISTINCT - col0 * col1 / col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + col0 + cor0.col2 * + 18 AS col1 FROM tab0 AS cor0
----
1565
53
618

query I rowsort
SELECT - col2 * col0 + 9 * col2 AS col1 FROM tab1 AS cor0
----
-3135
-6816
324

query I rowsort
SELECT ALL 39 + - cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
-123
-3609
-7641

query I rowsort
SELECT + + col2 * - ( - 80 ) AS col2 FROM tab2 AS cor0
----
2080
2160
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + + col2 * 70 col0 FROM tab1 AS cor0
----
3783
4054
6800

query I rowsort
SELECT DISTINCT cor0.col0 - col1 * + 42 FROM tab0 AS cor0
----
-3588
-3733
-4039

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-638
SELECT DISTINCT col2 DIV + tab0.col0 + - tab0.col0 * - col1 AS col1 FROM tab0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort label-638
SELECT DISTINCT col2 / + tab0.col0 + - tab0.col0 * - col1 AS col1 FROM tab0
----
2065
3395
8099

query I rowsort
SELECT col1 * - ( - col0 + - col0 ) AS col1 FROM tab1 AS cor0
----
1280
156
2080

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

query I rowsort
SELECT DISTINCT - + col2 * 77 * - col1 FROM tab0 cor0
----
218526
574574
7469

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col0 ) + col0 * 56 col1 FROM tab2 AS cor0
----
399
4446
4503

query I rowsort
SELECT ALL cor0.col2 * col1 + col2 + col0 FROM tab2 AS cor0
----
1638
763
871

query I rowsort
SELECT ALL 13 * - 45 FROM tab0, tab1 AS cor0
----
9 values hashing to 02cb68f564b7cd99c799b2b237857bf5

query I rowsort
SELECT ALL - col1 * 36 FROM tab2
----
-1116
-2124
-612

query I rowsort
SELECT - 20 FROM tab0, tab1 cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query I rowsort
SELECT ALL 81 + + col0 * - col2 AS col2 FROM tab0 AS cor0
----
-711
-7217
46

query I rowsort
SELECT - 64 + - 48 AS col2 FROM tab0 cor0
----
-112
-112
-112

query I rowsort
SELECT DISTINCT ( - 67 ) + + col0 - 6 * tab2.col0 FROM tab2
----
-102
-457
-462

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

query I rowsort
SELECT + col0 * tab1.col0 - + col1 FROM tab1
----
-17
4086
6387

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 * + col0 * + col0 + tab1.col1 col0 FROM tab1
----
260
40970
83213

query I rowsort
SELECT DISTINCT + 68 - + cor0.col1 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
42
55
58

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-659
SELECT ALL - ( col2 ) DIV - col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-659
SELECT ALL - ( col2 ) / - col0 FROM tab2 AS cor0
----
0
0
3

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

query I rowsort
SELECT + 72 * col0 + col0 AS col2 FROM tab0 cor0
----
1752
2555
6497

onlyif mysql # use DIV operator for integer division
query I rowsort label-662
SELECT - col0 DIV + tab0.col0 - - col1 AS col0 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-662
SELECT - col0 / + tab0.col0 - - col1 AS col0 FROM tab0
----
85
90
96

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

query I rowsort
SELECT ALL - 71 * col2 + col2 FROM tab1 cor0
----
-3780
-3990
-6720

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-668
SELECT DISTINCT - cor0.col2 * CAST( col0 AS SIGNED ) + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

skipif mysql # not compatible
query I rowsort label-668
SELECT DISTINCT - cor0.col2 * CAST ( col0 AS INTEGER ) + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-669
SELECT ALL - col1 * + CAST( - col2 AS SIGNED ) + col1 AS col2 FROM tab1 cor0
----
1261
1430
580

skipif mysql # not compatible
query I rowsort label-669
SELECT ALL - col1 * + CAST ( - col2 AS INTEGER ) + col1 AS col2 FROM tab1 cor0
----
1261
1430
580

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

query I rowsort
SELECT ALL col0 * - col0 + + col2 * + 64 AS col1 FROM tab2 AS cor0
----
-3809
-4420
1679

onlyif mysql # use DIV operator for integer division
query I rowsort label-672
SELECT DISTINCT - - col2 + ( cor0.col2 ) DIV - col1 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-672
SELECT DISTINCT - - col2 + ( cor0.col2 ) / - col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - 76 AS col0 FROM tab0 AS cor0
----
-76

query I rowsort
SELECT DISTINCT + 25 + col1 AS col1 FROM tab2 AS cor0
----
42
56
84

query I rowsort
SELECT DISTINCT col2 * - col2 + cor0.col2 FROM tab2 AS cor0
----
-1406
-650
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-676
SELECT - 42 DIV - col1 + col1 col1 FROM tab2
----
19
32
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-676
SELECT - 42 / - col1 + col1 col1 FROM tab2
----
19
32
59

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-679
SELECT DISTINCT tab1.col1 * - col1 DIV col1 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-679
SELECT DISTINCT tab1.col1 * - col1 / col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT + 8 * + ( - col2 + col1 ) * col2 FROM tab2 AS cor0
----
-6384
6864
864

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

query I rowsort
SELECT DISTINCT 4 + col0 * - cor0.col1 FROM tab2 AS cor0
----
-1339
-213
-4598

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

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

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

query I rowsort
SELECT ALL + 84 * cor0.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 1e3a35176791a057ba5926fc58de539f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * + ( col2 ) + col2 + ( - cor0.col1 ) * col1 col0 FROM tab2 AS cor0
----
-1663
-1695
-4131

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col2 + col2 ) * - ( - 54 ) * tab0.col1 col2 FROM tab0
----
10476
306504
805896

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

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

query I rowsort
SELECT ALL 9 + - tab2.col2 + + col1 FROM tab2
----
-12
13
42

query I rowsort
SELECT - - ( 17 ) * + col2 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT DISTINCT - 96 * cor0.col0 * - cor0.col2 FROM tab0 AS cor0
----
3360
700608
76032

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

query I rowsort
SELECT + 97 * ( + col1 + + col1 ) * 95 FROM tab2
----
1087370
313310
571330

query I rowsort
SELECT - 20 * col0 FROM tab2
----
-140
-1560
-1580

onlyif mysql # use DIV operator for integer division
query I rowsort label-698
SELECT ALL 25 * col2 * cor0.col0 + + 5 + col2 DIV 98 col2 FROM tab0 cor0
----
182455
19805
880

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-698
SELECT ALL 25 * col2 * cor0.col0 + + 5 + col2 / 98 col2 FROM tab0 cor0
----
182455
19805
880

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

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

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

query I rowsort
SELECT - ( - col1 ) + 35 AS col0 FROM tab2 AS cor0
----
52
66
94

query I rowsort
SELECT 43 * col2 FROM tab2 cor0
----
1118
1161
1634

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

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

query I rowsort
SELECT + 82 * - cor0.col1 + + 37 * cor0.col0 * + col1 AS col2 FROM tab2 AS cor0
----
165436
48297
5487

query I rowsort
SELECT DISTINCT 32 * - col0 - col2 FROM tab1
----
-150
-2105
-2656

query I rowsort
SELECT ALL - col0 * - col2 - - 94 FROM tab2
----
2122
283
3096

query I rowsort
SELECT ALL - tab0.col2 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

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

query I rowsort
SELECT ALL + 75 - + col0 * - tab2.col1 FROM tab2
----
1418
292
4677

query I rowsort
SELECT ALL - - col0 + col2 + + cor0.col0 FROM tab1 AS cor0
----
185
256
60

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

query I rowsort
SELECT col0 * - col0 + ( + 47 ) * + col2 * col0 FROM tab1 AS cor0
----
167360
354560
7605

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-714
SELECT - col2 + ( ( + cor0.col2 ) ) DIV ( - col0 * + col1 ) FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-714
SELECT - col2 + ( ( + cor0.col2 ) ) / ( - col0 * + col1 ) FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-715
SELECT ALL - + col0 * + col2 + + cor0.col1 DIV col2 FROM tab1 cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-715
SELECT ALL - + col0 * + col2 + + cor0.col1 / col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT - col2 * col0 + col0 * + cor0.col1 * col2 FROM tab0 AS cor0
----
3360
656820
67320

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-719
SELECT ALL + col2 DIV col2 + 98 DIV - col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-719
SELECT ALL + col2 / col2 + 98 / - col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 + - 30 - - 6 AS col0 FROM tab0 AS cor0
----
-23
58
9

query I rowsort
SELECT 19 * 14 AS col1 FROM tab0 AS cor0
----
266
266
266

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

query I rowsort
SELECT + 47 * - ( col2 + ( col0 ) ) FROM tab0 AS cor0
----
-1692
-2679
-8037

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

query I rowsort
SELECT + 66 + - col1 FROM tab1 cor0
----
40
53
56

query I rowsort
SELECT DISTINCT + - col0 * col0 + col1 AS col2 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT ALL 13 FROM tab1, tab0 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT 1 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT cor0.col1 * 15 AS col2 FROM tab1 cor0
----
150
195
390

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-731
SELECT ALL + col2 - cor0.col0 DIV - col2 FROM tab1 cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-731
SELECT ALL + col2 - cor0.col0 / - col2 FROM tab1 cor0
----
54
58
96

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

query I rowsort
SELECT ALL + 15 * cor0.col2 * + col1 + 38 AS col0 FROM tab2 AS cor0
----
12593
23048
9728

query I rowsort
SELECT DISTINCT 22 - col2 FROM tab1 cor0
----
-32
-35
-74

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

skipif mysql # not compatible
query I rowsort label-735
SELECT tab0.col1 / - ( col2 + col0 ) FROM tab0
----
-1
-2
0

query I rowsort
SELECT + col0 * - tab1.col1 * 34 + col2 FROM tab1
----
-21703
-2598
-35264

onlyif mysql # use DIV operator for integer division
query I rowsort label-737
SELECT col0 DIV + 49 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-737
SELECT col0 / + 49 FROM tab0
----
0
0
1

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

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

query I rowsort
SELECT ALL + + ( col2 ) * - col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

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

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

query I rowsort
SELECT + 3 * ( - col2 ) + + cor0.col1 FROM tab1 AS cor0
----
-136
-161
-275

onlyif mysql # use DIV operator for integer division
query I rowsort label-742
SELECT DISTINCT - 88 DIV ( - cor0.col0 ) FROM tab0 cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-742
SELECT DISTINCT - 88 / ( - cor0.col0 ) FROM tab0 cor0
----
0
2
3

query I rowsort
SELECT ALL + ( + 24 ) FROM tab1 AS cor0
----
24
24
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-744
SELECT - - col1 + col0 DIV + col1 + - 45 * 91 AS col0 FROM tab0 AS cor0
----
-3998
-4004
-4009

skipif mysql # not compatible
query I rowsort label-744
SELECT - - col1 + col0 / + col1 + - 45 * 91 AS col0 FROM tab0 AS cor0
----
-3998
-4004
-4009

query I rowsort
SELECT + 29 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT 5 + + 22 FROM tab2, tab1 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - + 49 col1 FROM tab0
----
-14
-25
40

query I rowsort
SELECT DISTINCT - 13 * 19 FROM tab2 AS cor0
----
-247

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

query I rowsort
SELECT DISTINCT + - col1 * - 43 + + col1 AS col0 FROM tab0 AS cor0
----
3784
4004
4268

query I rowsort
SELECT DISTINCT col0 * 54 AS col1 FROM tab0 AS cor0
----
1296
1890
4806

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

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

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

skipif mysql # not compatible
query I rowsort label-754
SELECT ALL + - cor0.col2 / + 39 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + ( + 2 ) * col1 AS col1 FROM tab0 AS cor0
----
172
182
194

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

query I rowsort
SELECT - ( - col2 ) * - col1 * 21 FROM tab0 AS cor0
----
-156702
-2037
-59598

query I rowsort
SELECT DISTINCT + col1 + + col0 * col2 * col2 FROM tab0 cor0
----
132
26222
598527

query I rowsort
SELECT - + col1 * 79 + + col2 FROM tab2 AS cor0
----
-1305
-2422
-4635

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

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

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

query I rowsort
SELECT - - ( cor0.col0 ) * 5 + cor0.col1 FROM tab2 cor0
----
412
449
66

query I rowsort
SELECT DISTINCT + col0 + col2 + - 76 AS col2 FROM tab2 AS cor0
----
-42
28
41

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 * 38 AS col0 FROM tab2 AS cor0
----
1014
1053
1482

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * 37 col2 FROM tab0 AS cor0
----
1295
3293
888

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

query I rowsort
SELECT col0 * + 61 FROM tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT DISTINCT col2 + 3 FROM tab1 AS cor0
----
57
60
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-771
SELECT ALL - col0 DIV cor0.col1 + - 46 FROM tab2 AS cor0
----
-46
-47
-50

skipif mysql # not compatible
query I rowsort label-771
SELECT ALL - col0 / cor0.col1 + - 46 FROM tab2 AS cor0
----
-46
-47
-50

query I rowsort
SELECT ALL - + col0 * + col1 - - 34 * col2 AS col2 FROM tab2 cor0
----
-3718
-51
701

query I rowsort
SELECT ALL - 17 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

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

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

query I rowsort
SELECT DISTINCT col1 + - col1 * ( - col1 ) AS col2 FROM tab2 cor0
----
306
3540
992

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-776
SELECT - col0 / + col1 + - col0 col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 55 * col0 col2 FROM tab0 AS cor0
----
1320
1925
4895

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

query I rowsort
SELECT col2 + - 76 FROM tab1
----
-19
-22
20

query I rowsort
SELECT 16 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT cor0.col0 * - 45 FROM tab1, tab0 AS cor0
----
9 values hashing to 0b8dcaf4407478ab89af5e52b21342aa

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-783
SELECT + col1 DIV + col0 + 47 FROM tab0 AS cor0
----
48
49
50

skipif mysql # not compatible
query I rowsort label-783
SELECT + col1 / + col0 + 47 FROM tab0 AS cor0
----
48
49
50

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

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

query I rowsort
SELECT + ( + cor0.col0 ) + col1 + - 67 FROM tab1 AS cor0
----
-38
26
7

query I rowsort
SELECT DISTINCT tab0.col2 + + 88 * - col1 + tab0.col2 FROM tab0
----
-7502
-7844
-8534

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

query I rowsort
SELECT 57 * + col2 * ( col2 ) AS col1 FROM tab2
----
38532
41553
82308

query I rowsort
SELECT - 84 + col2 AS col1 FROM tab0 AS cor0
----
-2
-51
-83

query I rowsort
SELECT ALL + col1 * col2 + - col2 * col0 AS col2 FROM tab1 AS cor0
----
-3078
-6432
1242

query I rowsort
SELECT 62 * col1 + cor0.col2 FROM tab1 AS cor0
----
1666
677
902

onlyif mysql # use DIV operator for integer division
query I rowsort label-793
SELECT DISTINCT + 14 * col2 + - CAST( - col1 AS SIGNED ) + - col1 DIV col0 FROM tab2 AS cor0
----
405
423
549

skipif mysql # not compatible
query I rowsort label-793
SELECT DISTINCT + 14 * col2 + - CAST ( - col1 AS INTEGER ) + - col1 / col0 FROM tab2 AS cor0
----
405
423
549

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-795
SELECT col0 DIV + col2 + - 45 FROM tab1
----
-44
-45
-45

skipif mysql # not compatible
query I rowsort label-795
SELECT col0 / + col2 + - 45 FROM tab1
----
-44
-45
-45

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-796
SELECT CAST ( + cor0.col0 AS INTEGER ) - + col2 * - cor0.col0 * + col2 col2 FROM tab0 AS cor0
----
26160
598525
70

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

skipif mysql # not compatible
query I rowsort label-797
SELECT CAST ( col2 AS INTEGER ) * col0 + + col1 AS col2 FROM tab1 AS cor0
----
188
3658
7693

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

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

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

skipif mysql # not compatible
query I rowsort label-800
SELECT + col2 / 97 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - ( - 55 ) * - col2 * col2 FROM tab0
----
-369820
-55
-59895

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

query I rowsort
SELECT DISTINCT + 25 * col1 FROM tab2
----
1475
425
775

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

query I rowsort
SELECT ALL + col1 * - 90 AS col1 FROM tab1 AS cor0
----
-1170
-2340
-900

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

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

query I rowsort
SELECT + col1 * col1 + - 43 FROM tab1
----
126
57
633

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

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

query I rowsort
SELECT ALL ( + 26 ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor1.col1 col1 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT DISTINCT - col1 * 27 FROM tab2 AS cor0
----
-1593
-459
-837

query I rowsort
SELECT col1 * + 52 AS col2 FROM tab2 cor0
----
1612
3068
884

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-814
SELECT DISTINCT - - col2 * + col2 + + 38 DIV col2 AS col0 FROM tab0 AS cor0
----
1090
39
6724

skipif mysql # not compatible
query I rowsort label-814
SELECT DISTINCT - - col2 * + col2 + + 38 / col2 AS col0 FROM tab0 AS cor0
----
1090
39
6724

query I rowsort
SELECT DISTINCT - + col1 + - col2 * - 45 AS col0 FROM tab2 AS cor0
----
1111
1184
1693

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

query I rowsort
SELECT - col0 * - ( - col0 ) - + col0 * col0 FROM tab0 cor0
----
-1152
-15842
-2450

onlyif mysql # use DIV operator for integer division
query I rowsort label-818
SELECT + tab1.col0 DIV + col1 col1 FROM tab1
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-818
SELECT + tab1.col0 / + col1 col1 FROM tab1
----
0
6
6

query I rowsort
SELECT col2 * - tab2.col2 * col2 - col0 AS col0 FROM tab2
----
-17654
-19690
-54951

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-820
SELECT DISTINCT - tab1.col1 / - col1 col2 FROM tab1
----
1

query I rowsort
SELECT - col2 + + col2 * col0 * cor0.col2 AS col1 FROM tab1 AS cor0
----
207879
737184
8694

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-823
SELECT DISTINCT col1 DIV + col2 - col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-823
SELECT DISTINCT col1 / + col2 - col2 FROM tab1
----
-54
-57
-96

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

skipif mysql # not compatible
query I rowsort label-824
SELECT + tab0.col0 / + col0 + col2 FROM tab0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 * col0 - - col0 col0 FROM tab0
----
-1190
-552
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-826
SELECT - col1 + - col2 DIV col2 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-826
SELECT - col1 + - col2 / col2 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT DISTINCT + col2 * + col2 + - col2 FROM tab2 AS cor0
----
1406
650
702

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

query I rowsort
SELECT + col1 - col0 * - cor0.col0 FROM tab0 AS cor0
----
1322
662
8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-830
SELECT ALL col2 + col0 DIV - col2 FROM tab1
----
54
56
96

skipif mysql # not compatible
query I rowsort label-830
SELECT ALL col2 + col0 / - col2 FROM tab1
----
54
56
96

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

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

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

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

query I rowsort
SELECT DISTINCT - - 0 FROM tab0 cor0
----
0

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

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

query I rowsort
SELECT DISTINCT cor0.col1 + col2 * + 31 AS col2 FROM tab1 AS cor0
----
1700
1777
2989

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

query I rowsort
SELECT col2 + - ( + col1 ) * 48 AS col2 FROM tab0
----
-4095
-4286
-4655

query I rowsort
SELECT 63 - - col2 * col0 * + 22 FROM tab0
----
160619
17487
833

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

query I rowsort
SELECT + ( - col2 ) * + col1 + col0 AS col0 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT col1 * + col0 - tab1.col0 AS col0 FROM tab1
----
576
75
960

query I rowsort
SELECT ALL ( - 46 ) AS col0 FROM tab0
----
-46
-46
-46

query I rowsort
SELECT ALL - col2 - - col1 * ( col2 ) AS col2 FROM tab1
----
1152
1350
513

query I rowsort
SELECT DISTINCT - ( col2 * col2 ) + col0 - - col0 AS col2 FROM tab1
----
-2910
-3121
-9056

query I rowsort
SELECT ALL 78 - col0 AS col2 FROM tab2 AS cor0
----
-1
0
71

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

query I rowsort
SELECT + col2 + + col0 + - 95 * + col1 FROM tab0
----
-8113
-8474
-9179

query I rowsort
SELECT DISTINCT 11 FROM tab1, tab0 cor0
----
11

query I rowsort
SELECT - 49 * 57 * - col1 AS col0 FROM tab0 AS cor0
----
240198
254163
270921

onlyif mysql # use DIV operator for integer division
query I rowsort label-852
SELECT - + col0 + 97 DIV + col0 FROM tab2 AS cor0
----
-77
-78
6

skipif mysql # not compatible
query I rowsort label-852
SELECT - + col0 + 97 / + col0 FROM tab2 AS cor0
----
-77
-78
6

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

query I rowsort
SELECT ALL + 66 FROM tab1, tab0 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT - 99 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 761f5f1a166a00db99360141565a85da

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

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

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

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

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

query I rowsort
SELECT ALL - + col1 + + 41 FROM tab1 AS cor0
----
15
28
31

query I rowsort
SELECT ALL - 61 FROM tab2
----
-61
-61
-61

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

skipif mysql # not compatible
query I rowsort label-861
SELECT + ( - col1 ) * - col1 + ( cor0.col0 + col0 ) / col2 FROM tab1 AS cor0
----
102
170
676

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

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

query I rowsort
SELECT ALL - 49 * cor0.col0 FROM tab1 AS cor0
----
-147
-3136
-3920

query I rowsort
SELECT ALL - col0 * col0 * - col1 AS col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT ( - 59 ) + + col1 AS col1 FROM tab2 AS cor0
----
-28
-42
0

query I rowsort
SELECT DISTINCT + ( 45 ) * col0 + - 71 * - col2 AS col1 FROM tab1 AS cor0
----
10416
3969
6927

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

query I rowsort
SELECT DISTINCT - + cor0.col0 + + 42 * col2 * + col1 FROM tab1 AS cor0
----
23876
52336
58965

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-871
SELECT DISTINCT - 97 + - col1 * ( col0 ) + col1 DIV col1 AS col0 FROM tab0 cor0
----
-2160
-3491
-8195

skipif mysql # not compatible
query I rowsort label-871
SELECT DISTINCT - 97 + - col1 * ( col0 ) + col1 / col1 AS col0 FROM tab0 cor0
----
-2160
-3491
-8195

query I rowsort
SELECT ALL - - 5 * + col2 AS col0 FROM tab2 AS cor0
----
130
135
190

query I rowsort
SELECT DISTINCT col2 * col0 + + col1 * col1 AS col0 FROM tab2 AS cor0
----
1150
3291
5509

query I rowsort
SELECT ALL + ( + cor0.col2 ) + - ( - col1 + - col2 ) FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT - col0 + - 39 * + 67 AS col1 FROM tab0 AS cor0
----
-2637
-2648
-2702

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-879
SELECT ALL + col2 + - 85 DIV col2 AS col1 FROM tab1 AS cor0
----
53
56
96

skipif mysql # not compatible
query I rowsort label-879
SELECT ALL + col2 + - 85 / col2 AS col1 FROM tab1 AS cor0
----
53
56
96

query I rowsort
SELECT + cor0.col0 - - col0 * 54 AS col1 FROM tab0 cor0
----
1320
1925
4895

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

query I rowsort
SELECT + + col2 + - col0 * 39 AS col0 FROM tab2 AS cor0
----
-246
-3016
-3043

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

query I rowsort
SELECT - col2 + 21 AS col2 FROM tab1 AS cor0
----
-33
-36
-75

query I rowsort
SELECT col1 + col2 * tab1.col2 + col0 FROM tab1
----
2945
3323
9309

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

query I rowsort
SELECT + col0 + 62 * 36 FROM tab1 AS cor0
----
2235
2296
2312

query I rowsort
SELECT DISTINCT col2 * 93 + - col0 * - col0 AS col2 FROM tab0 AS cor0
----
1318
15547
3645

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

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

query I rowsort
SELECT ALL tab1.col0 + 54 * + 88 AS col0 FROM tab1
----
4755
4816
4832

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

query I rowsort
SELECT ALL 31 * col0 + col1 FROM tab1 cor0
----
119
1994
2493

query I rowsort
SELECT ALL + + col0 + 89 AS col1 FROM tab2 AS cor0
----
167
168
96

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

query I rowsort
SELECT ALL - - 97 - + col1 AS col1 FROM tab2 AS cor0
----
38
66
80

query I rowsort
SELECT DISTINCT - + ( 14 ) * col2 FROM tab2 AS cor0
----
-364
-378
-532

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

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

query I rowsort
SELECT DISTINCT tab0.col1 + + 27 FROM tab0
----
113
118
124

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * tab0.col0 + + col1 col2 FROM tab0
----
2150
3492
8190

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1, tab2 cor0, tab2 cor1
----
972 values hashing to f94a4a64ac54a61fc21f78e2b831ebee

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

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

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

query I rowsort
SELECT - col1 * 30 FROM tab1
----
-300
-390
-780

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-906
SELECT + tab1.col1 DIV 90 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-906
SELECT + tab1.col1 / 90 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT + - col0 + + ( + col1 * ( col1 ) ) + - col2 FROM tab0 AS cor0
----
7339
8110
9373

onlyif mysql # use DIV operator for integer division
query I rowsort label-908
SELECT - CAST( + col0 AS SIGNED ) * + cor0.col1 + 69 DIV + 10 + col2 FROM tab2 AS cor0
----
-1299
-184
-4570

skipif mysql # not compatible
query I rowsort label-908
SELECT - CAST ( + col0 AS INTEGER ) * + cor0.col1 + 69 / + 10 + col2 FROM tab2 AS cor0
----
-1299
-184
-4570

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

skipif mysql # not compatible
query I rowsort label-909
SELECT col1 / + col1 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT + col0 + col1 * - col1 FROM tab2
----
-210
-3403
-954

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

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

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

query I rowsort
SELECT ALL + + 57 + - col1 FROM tab2 cor0
----
-2
26
40

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

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

skipif mysql # not compatible
query I rowsort label-915
SELECT ALL col1 / col0 + col2 - col1 FROM tab2 AS cor0
----
-33
0
21

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

query I rowsort
SELECT - + col1 + ( 81 ) AS col0 FROM tab0 AS cor0
----
-10
-16
-5

query I rowsort
SELECT cor0.col0 * 45 + col1 FROM tab2 AS cor0
----
346
3569
3572

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * 37 col0 FROM tab1 AS cor0
----
-1998
-2109
-3552

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

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

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

query I rowsort
SELECT col1 * - ( 91 ) FROM tab2 cor0
----
-1547
-2821
-5369

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

query I rowsort
SELECT col2 + - ( - col2 ) AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL - col0 * - 32 FROM tab2
----
224
2496
2528

query I rowsort
SELECT - col0 * 33 * - col0 AS col1 FROM tab0
----
19008
261393
40425

query I rowsort
SELECT - 60 FROM tab0, tab1 cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - ( col1 ) * + col1 FROM tab0
----
-7396
-8281
-9409

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-940
SELECT + + ( - col0 ) DIV + CAST( col2 AS SIGNED ) + - col0 + + ( col0 + cor0.col0 ) AS col1 FROM tab0 AS cor0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-940
SELECT + + ( - col0 ) / + CAST ( col2 AS INTEGER ) + - col0 + + ( col0 + cor0.col0 ) AS col1 FROM tab0 AS cor0
----
0
24
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-941
SELECT - - col0 * col1 + - 78 DIV + col0 + - col2 AS col0 FROM tab0 AS cor0
----
2028
3392
8017

skipif mysql # not compatible
query I rowsort label-941
SELECT - - col0 * col1 + - 78 / + col0 + - col2 AS col0 FROM tab0 AS cor0
----
2028
3392
8017

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

query I rowsort
SELECT + 52 * - 44 + - col0 FROM tab0 cor0
----
-2312
-2323
-2377

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 95 + + col2 * + col0 col1 FROM tab2 cor0
----
2123
284
3097

query I rowsort
SELECT DISTINCT + + 48 + col1 AS col0 FROM tab0 AS cor0
----
134
139
145

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT CAST ( 93 AS REAL ) + + col1 col2 FROM tab0 AS cor0
----
179
184
190

onlyif mysql # use DIV operator for integer division
query I rowsort label-950
SELECT ALL + + 97 - col1 * col1 DIV col0 FROM tab0 AS cor0
----
-171
-211
4

skipif mysql # not compatible
query I rowsort label-950
SELECT ALL + + 97 - col1 * col1 / col0 FROM tab0 AS cor0
----
-171
-211
4

query I rowsort
SELECT DISTINCT - 32 AS col2 FROM tab0 AS cor0
----
-32

query I rowsort
SELECT + 31 * cor0.col0 AS col1 FROM tab0 cor0
----
1085
2759
744

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

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

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

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

query I rowsort
SELECT - 12 + 19 * - col2 FROM tab2
----
-506
-525
-734

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

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

query I rowsort
SELECT ALL + - col1 * ( + 35 ) FROM tab0 AS cor0
----
-3010
-3185
-3395

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * 29 - col2 col2 FROM tab2 AS cor0
----
176
2236
2253

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

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

query I rowsort
SELECT DISTINCT - col2 * - ( 30 * col1 ) FROM tab2 AS cor0
----
19380
25110
46020

query I rowsort
SELECT col2 + 22 AS col1 FROM tab0 AS cor0
----
104
23
55

query I rowsort
SELECT ALL + - col0 * - col0 - cor0.col1 FROM tab1 AS cor0
----
-17
4086
6387

onlyif mysql # use DIV operator for integer division
query I rowsort label-967
SELECT - cor0.col0 * 99 + 78 DIV - col1 FROM tab2 AS cor0
----
-695
-7723
-7825

skipif mysql # not compatible
query I rowsort label-967
SELECT - cor0.col0 * 99 + 78 / - col1 FROM tab2 AS cor0
----
-695
-7723
-7825

query I rowsort
SELECT ALL + - col1 + ( 74 * col2 ) FROM tab2 cor0
----
1865
1967
2795

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

query I rowsort
SELECT - tab2.col2 - + col1 * + col2 * + 57 FROM tab2
----
-36860
-47736
-87464

query I rowsort
SELECT DISTINCT + 37 - col2 FROM tab1
----
-17
-20
-59

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-973
SELECT - col1 + + col0 DIV ( + col1 ) FROM tab2 AS cor0
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-973
SELECT - col1 + + col0 / ( + col1 ) FROM tab2 AS cor0
----
-13
-31
-58

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

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

skipif mysql # not compatible
query I rowsort label-975
SELECT DISTINCT - tab1.col0 / tab1.col0 AS col0 FROM tab1
----
-1

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

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

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

query I rowsort
SELECT DISTINCT + cor0.col0 * 43 AS col0 FROM tab1, tab2 AS cor0
----
301
3354
3397

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

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

query I rowsort
SELECT DISTINCT + col1 * col2 + 52 FROM tab0
----
149
2890
7514

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

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

query I rowsort
SELECT + + 40 + - col0 AS col0 FROM tab1 AS cor0
----
-24
-40
37

query I rowsort
SELECT + 45 * 74 AS col2 FROM tab2 AS cor0
----
3330
3330
3330

query I rowsort
SELECT ALL - col0 * 12 FROM tab2
----
-84
-936
-948

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

query I rowsort
SELECT ALL + col2 * - 91 + - col1 * col0 * - tab2.col0 FROM tab2
----
-938
102639
356590

query I rowsort
SELECT - - 53 FROM tab2, tab0 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 63949b5362442f48bd29195397a57dad

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-992
SELECT cor0.col2 + 80 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
55
58
96

skipif mysql # not compatible
query I rowsort label-992
SELECT cor0.col2 + 80 / cor0.col2 AS col1 FROM tab1 AS cor0
----
55
58
96

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT ( col1 ) * - col2 + 42 FROM tab2 cor0
----
-1492
-604
-795

query I rowsort
SELECT ALL + 47 FROM tab0 cor0
----
47
47
47

query I rowsort
SELECT DISTINCT + 52 AS col2 FROM tab2
----
52

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

query I rowsort
SELECT ALL cor0.col2 * 34 FROM tab1 AS cor0
----
1836
1938
3264

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

skipif mysql # not compatible
query I rowsort label-1002
SELECT col0 + + col2 / col1 FROM tab1 AS cor0
----
5
69
87

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1005
SELECT col2 / - tab0.col1 AS col2 FROM tab0
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-1006
SELECT DISTINCT + + col0 / + ( - col2 ) AS col1 FROM tab0 AS cor0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col2 * col0 col2 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-1008
SELECT + col2 + + col2 DIV + 69 AS col1 FROM tab1 AS cor0
----
54
57
97

skipif mysql # not compatible
query I rowsort label-1008
SELECT + col2 + + col2 / + 69 AS col1 FROM tab1 AS cor0
----
54
57
97

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

skipif mysql # not compatible
query I rowsort label-1009
SELECT ALL + col1 * - ( col0 + cor0.col1 ) * - CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
210158
31806
62016

query I rowsort
SELECT - col1 + - 18 AS col0 FROM tab1 AS cor0
----
-28
-31
-44

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1012
SELECT - col0 + col1 DIV col0 AS col0 FROM tab2 cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-1012
SELECT - col0 + col1 / col0 AS col0 FROM tab2 cor0
----
-3
-78
-79

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

skipif mysql # not compatible
query I rowsort label-1013
SELECT 42 / - col1 FROM tab0 AS cor0
----
0
0
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1015
SELECT 20 - + col1 DIV - 13 AS col0 FROM tab0
----
26
27
27

skipif mysql # not compatible
query I rowsort label-1015
SELECT 20 - + col1 / - 13 AS col0 FROM tab0
----
26
27
27

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

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

skipif mysql # not compatible
query I rowsort label-1017
SELECT - + col2 * cor0.col2 * - CAST ( - 67 AS INTEGER ) FROM tab0 AS cor0
----
-450508
-67
-72963

query I rowsort
SELECT + + 79 AS col2 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to da0116d31b8af0da9f685c090d378baf

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1019
SELECT DISTINCT + + col1 + - CAST( + 75 AS SIGNED ) AS col1 FROM tab0 cor0
----
11
16
22

skipif mysql # not compatible
query I rowsort label-1019
SELECT DISTINCT + + col1 + - CAST ( + 75 AS INTEGER ) AS col1 FROM tab0 cor0
----
11
16
22

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1021
SELECT ALL + cor0.col2 DIV - cor0.col0 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 525114d3cda3b98833487393e7c2b936

skipif mysql # not compatible
query I rowsort label-1021
SELECT ALL + cor0.col2 / - cor0.col0 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 525114d3cda3b98833487393e7c2b936

query I rowsort
SELECT DISTINCT + col2 * - 59 + - col0 * col1 FROM tab2 cor0
----
-1810
-3585
-6136

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

query I rowsort
SELECT + col1 * - 85 AS col1 FROM tab1 AS cor0
----
-1105
-2210
-850

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

query I rowsort
SELECT - col1 * - 93 FROM tab0
----
7998
8463
9021

query I rowsort
SELECT - 98 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

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

query I rowsort
SELECT - ( + 11 ) FROM tab1, tab1 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

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

query I rowsort
SELECT ALL col1 * 17 AS col2 FROM tab2
----
1003
289
527

query I rowsort
SELECT - 98 + 65 AS col2 FROM tab1 AS cor0
----
-33
-33
-33

query I rowsort
SELECT - 48 + ( - col2 ) FROM tab2 AS cor0
----
-74
-75
-86

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

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

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

query I rowsort
SELECT - col2 * - 64 + cor0.col2 FROM tab1 cor0
----
3510
3705
6240

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

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

query I rowsort
SELECT ALL - 44 + cor0.col0 AS col1 FROM tab2 AS cor0
----
-37
34
35

query I rowsort
SELECT DISTINCT + col2 * col1 + ( 94 * col2 ) AS col2 FROM tab1 cor0
----
10272
5928
6480

query I rowsort
SELECT ALL - cor0.col2 * col2 * - 29 - + cor0.col2 AS col1 FROM tab2 AS cor0
----
19578
21114
41838

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1042
SELECT CAST( + 97 AS SIGNED ) + col0 AS col0 FROM tab2
----
104
175
176

skipif mysql # not compatible
query I rowsort label-1042
SELECT CAST ( + 97 AS INTEGER ) + col0 AS col0 FROM tab2
----
104
175
176

query I rowsort
SELECT ALL - col0 + - 62 AS col0 FROM tab0
----
-151
-86
-97

query I rowsort
SELECT ALL col0 + col1 * + tab2.col0 * + col1 AS col2 FROM tab2
----
22910
271596
6734

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1045
SELECT ALL + CAST( col2 AS SIGNED ) * + col2 * + 60 FROM tab1
----
174960
194940
552960

skipif mysql # not compatible
query I rowsort label-1045
SELECT ALL + CAST ( col2 AS INTEGER ) * + col2 * + 60 FROM tab1
----
174960
194940
552960

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

query I rowsort
SELECT - - col2 * col0 + - col1 - + col1 * + col2 AS col0 FROM tab2 AS cor0
----
-679
2339
435

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

skipif mysql # not compatible
query I rowsort label-1048
SELECT col1 + - CAST ( - col0 * + col1 AS INTEGER ) FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + + col2 + 32 * cor0.col1 AS col1 FROM tab1 cor0
----
377
512
886

query I rowsort
SELECT col2 + 96 - - col0 AS col1 FROM tab2 AS cor0
----
130
200
213

query I rowsort
SELECT ( + 12 ) AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

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

skipif mysql # not compatible
query I rowsort label-1052
SELECT DISTINCT + 42 * + cor0.col2 + CAST ( NULL AS INTEGER ) * - 84 AS col1 FROM tab2, tab0, tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 19 * col0 FROM tab2
----
133
1482
1501

query I rowsort
SELECT ALL ( - col0 + + 46 ) * - 15 AS col0 FROM tab2
----
-585
480
495

onlyif mysql # use DIV operator for integer division
query I rowsort label-1055
SELECT ALL tab1.col0 * col1 DIV ( + col1 ) FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-1055
SELECT ALL tab1.col0 * col1 / ( + col1 ) FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT ( + col1 * - 21 + - col0 ) AS col1 FROM tab2
----
-1317
-436
-658

onlyif mysql # use DIV operator for integer division
query I rowsort label-1057
SELECT DISTINCT col0 DIV + ( - 66 ) - - tab0.col2 AS col1 FROM tab0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-1057
SELECT DISTINCT col0 / + ( - 66 ) - - tab0.col2 AS col1 FROM tab0
----
1
33
81

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

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

query I rowsort
SELECT col1 * - ( col0 ) - col2 AS col2 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT + col2 * - col1 * - 38 FROM tab0
----
107844
283556
3686

query I rowsort
SELECT DISTINCT + 20 * 20 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
400

query I rowsort
SELECT + cor0.col1 + - col2 * 45 FROM tab2 AS cor0
----
-1111
-1184
-1693

query I rowsort
SELECT ALL 13 * col0 FROM tab1 AS cor0
----
1040
39
832

query I rowsort
SELECT DISTINCT 21 + col2 * 12 AS col2 FROM tab1
----
1173
669
705

query I rowsort
SELECT 30 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT 69 * + col0 AS col0 FROM tab2
----
483
5382
5451

query I rowsort
SELECT ALL + + cor0.col0 + - col2 + - col0 * 20 FROM tab0 AS cor0
----
-1773
-489
-666

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1070
SELECT DISTINCT - col1 DIV + 67 + 88 AS col2 FROM tab1 AS cor0
----
88

skipif mysql # not compatible
query I rowsort label-1070
SELECT DISTINCT - col1 / + 67 + 88 AS col2 FROM tab1 AS cor0
----
88

query I rowsort
SELECT ALL + col0 * - 42 + - col1 AS col0 FROM tab0 AS cor0
----
-1094
-1567
-3829

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

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

skipif mysql # not compatible
query I rowsort label-1073
SELECT + col1 + CAST ( NULL AS REAL ) * - 16 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 * 49 AS col1 FROM tab1 AS cor0
----
-147
-3136
-3920

query I rowsort
SELECT + col0 * - 89 + col2 * col1 * - 31 + - col2 * - col1 * + ( + 15 ) AS col0 FROM tab1 AS cor0
----
-14816
-22731
-27088

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

skipif mysql # not compatible
query I rowsort label-1076
SELECT ALL - - col2 * CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-2838
-7462
-97

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

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

query I rowsort
SELECT ALL - + col0 + - 2 + 55 AS col1 FROM tab2 AS cor0
----
-25
-26
46

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

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

query I rowsort
SELECT 12 + + col1 AS col0 FROM tab1 AS cor0
----
22
25
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 90 * col2 * + cor0.col1 + col0 col0 FROM tab0 AS cor0
----
255444
671669
8765

onlyif mysql # use DIV operator for integer division
query I rowsort label-1083
SELECT + cor0.col1 * + col1 * cor0.col1 + - ( 39 ) DIV col0 FROM tab2 AS cor0
----
205379
29786
4913

skipif mysql # not compatible
query I rowsort label-1083
SELECT + cor0.col1 * + col1 * cor0.col1 + - ( 39 ) / col0 FROM tab2 AS cor0
----
205379
29786
4913

query I rowsort
SELECT ALL 5 + col2 FROM tab0
----
38
6
87

query I rowsort
SELECT DISTINCT + - col0 * 71 AS col2 FROM tab2 AS cor0
----
-497
-5538
-5609

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

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

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

query I rowsort
SELECT DISTINCT - ( - 3 ) - cor0.col1 * - col1 FROM tab2 AS cor0
----
292
3484
964

query I rowsort
SELECT ALL + col1 * 72 AS col1 FROM tab2 AS cor0
----
1224
2232
4248

query I rowsort
SELECT DISTINCT + 48 + - col2 * - col1 FROM tab2 AS cor0
----
1582
694
885

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

query I rowsort
SELECT DISTINCT + col1 * 40 FROM tab1 AS cor0
----
1040
400
520

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

query I rowsort
SELECT DISTINCT col1 + 84 FROM tab2 AS cor0
----
101
115
143

query I rowsort
SELECT ALL + + ( col2 ) + col1 + - col0 AS col1 FROM tab2 AS cor0
----
-24
51
7

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

query I rowsort
SELECT DISTINCT + col1 + col2 + 61 * + col2 AS col1 FROM tab0 AS cor0
----
159
2132
5175

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

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

query I rowsort
SELECT ALL ( 20 ) - col0 * - 30 AS col1 FROM tab0
----
1070
2690
740

query I rowsort
SELECT + col0 + 92 * tab1.col0 FROM tab1
----
279
5952
7440

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

query I rowsort
SELECT 74 AS col0 FROM tab1, tab1 cor0 CROSS JOIN tab2
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 25 * col2 - - cor0.col1 col2 FROM tab2 AS cor0
----
706
709
967

query I rowsort
SELECT - 97 + col2 * - col1 FROM tab1 AS cor0
----
-1345
-1501
-667

onlyif mysql # use DIV operator for integer division
query I rowsort label-1106
SELECT + col1 * col2 + cor0.col2 - - cor0.col2 * col0 DIV 80 FROM tab2 AS cor0
----
1585
721
866

skipif mysql # not compatible
query I rowsort label-1106
SELECT + col1 * col2 + cor0.col2 - - cor0.col2 * col0 / 80 FROM tab2 AS cor0
----
1585
721
866

query I rowsort
SELECT + 66 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
3564
3762
6336

skipif mysql # not compatible
query I rowsort
SELECT ALL + - col0 * + cor0.col0 + - CAST ( 89 AS REAL ) FROM tab1 AS cor0
----
-4185
-6489
-98

query I rowsort
SELECT ALL + 17 + col0 * col0 FROM tab1 AS cor0
----
26
4113
6417

query I rowsort
SELECT 15 + col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
177
3663
7695

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + tab1.col2 * + col0 col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT 74 * - 79 AS col2 FROM tab1
----
-5846

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

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

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

query I rowsort
SELECT ALL col2 * - col0 - + 5 AS col1 FROM tab2 AS cor0
----
-194
-2033
-3007

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

query I rowsort
SELECT DISTINCT + col2 * - ( 79 ) AS col1 FROM tab0
----
-2607
-6478
-79

query I rowsort
SELECT ALL 45 * + col1 + col2 FROM tab1 AS cor0
----
1224
507
681

query I rowsort
SELECT DISTINCT cor0.col0 * 74 * + col2 AS col1 FROM tab1 cor0
----
11988
269952
568320

query I rowsort
SELECT ALL + 20 + 44 FROM tab1 AS cor0
----
64
64
64

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

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

query I rowsort
SELECT - - ( cor0.col2 ) * - col0 * + col0 AS col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - col2 + + ( 42 ) AS col0 FROM tab1 AS cor0
----
-12
-15
-54

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col2 * col1 col0 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT - cor0.col0 + + 20 + + col2 AS col2 FROM tab2 AS cor0
----
-21
-32
40

query I rowsort
SELECT ALL + col1 + + 48 AS col0 FROM tab1 AS cor0
----
58
61
74

query I rowsort
SELECT ALL tab2.col2 + - ( col1 ) AS col1 FROM tab2
----
-33
-4
21

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

skipif mysql # not compatible
query I rowsort label-1131
SELECT + ( - tab2.col2 ) / + col1 AS col2 FROM tab2
----
-2
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1132
SELECT DISTINCT + col1 * col0 DIV - col2 FROM tab0
----
-3395
-62
-98

skipif mysql # not compatible
query I rowsort label-1132
SELECT DISTINCT + col1 * col0 / - col2 FROM tab0
----
-3395
-62
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 ) + 81 * + col2 col0 FROM tab0 AS cor0
----
116
2697
6731

query I rowsort
SELECT ALL - 38 AS col2 FROM tab1
----
-38
-38
-38

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

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

query I rowsort
SELECT 50 + col0 AS col2 FROM tab0 AS cor0
----
139
74
85

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

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

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

query I rowsort
SELECT + 75 - col1 AS col0 FROM tab1 AS cor0
----
49
62
65

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

query I rowsort
SELECT - + 53 * col0 - + cor0.col0 * col2 FROM tab1 AS cor0
----
-11920
-321
-7040

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1148
SELECT ALL + col1 DIV - col1 + + col2 * tab2.col0 * + col1 FROM tab2
----
119651
51033
5858

skipif mysql # not compatible
query I rowsort label-1148
SELECT ALL + col1 / - col1 + + col2 * tab2.col0 * + col1 FROM tab2
----
119651
51033
5858

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1151
SELECT + col0 * - col2 * col2 + + cor0.col1 DIV + col0 FROM tab1 AS cor0
----
-207936
-737280
-8740

skipif mysql # not compatible
query I rowsort label-1151
SELECT + col0 * - col2 * col2 + + cor0.col1 / + col0 FROM tab1 AS cor0
----
-207936
-737280
-8740

query I rowsort
SELECT DISTINCT - col0 * + col0 * col0 + cor0.col2 AS col2 FROM tab0 AS cor0
----
-13791
-42874
-704887

query I rowsort
SELECT - col2 * cor0.col1 + col0 + + col2 * + col2 FROM tab2 AS cor0
----
-101
-780
877

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 + col2 * col2 * col2 AS col2 FROM tab0 AS cor0
----
-3394
33873
543269

query I rowsort
SELECT + 85 * col1 + + col0 FROM tab0 AS cor0
----
7334
7824
8280

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1157
SELECT + col2 + + col1 * col0 DIV col2 AS col2 FROM tab0
----
180
3396
95

skipif mysql # not compatible
query I rowsort label-1157
SELECT + col2 + + col1 * col0 / col2 AS col2 FROM tab0
----
180
3396
95

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1159
SELECT CAST( col0 AS SIGNED ) + - col2 FROM tab1
----
-16
-51
7

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

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

query I rowsort
SELECT DISTINCT + ( + cor0.col1 ) + - cor0.col0 * col0 FROM tab1 AS cor0
----
-4086
-6387
17

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

query I rowsort
SELECT ALL - ( col2 ) + col1 * + col1 AS col2 FROM tab1 AS cor0
----
43
622
73

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

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

query I rowsort
SELECT cor0.col2 + + col1 + col2 AS col0 FROM tab1 AS cor0
----
124
134
205

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

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

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

query I rowsort
SELECT ALL col2 - - 41 * col1 FROM tab2
----
1298
2445
735

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

skipif mysql # not compatible
query I rowsort label-1171
SELECT ALL CAST ( NULL AS REAL ) + - cor0.col1 / - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 + - col2 * - col0 col0 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT ALL + + 2 * col0 - + col2 * - ( - col0 ) FROM tab2 cor0
----
-175
-1872
-2844

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

query I rowsort
SELECT - ( 87 ) FROM tab0, tab2 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to edb5a8bbcb3204ac8254e54507073328

onlyif mysql # use DIV operator for integer division
query I rowsort label-1177
SELECT ALL - tab2.col1 + 44 * + 25 - + col0 DIV - 95 FROM tab2
----
1041
1069
1083

skipif mysql # not compatible
query I rowsort label-1177
SELECT ALL - tab2.col1 + 44 * + 25 - + col0 / - 95 FROM tab2
----
1041
1069
1083

onlyif mysql # use DIV operator for integer division
query I rowsort label-1178
SELECT + col0 + 3 DIV col1 + + tab1.col0 AS col0 FROM tab1
----
128
160
6

skipif mysql # not compatible
query I rowsort label-1178
SELECT + col0 + 3 / col1 + + tab1.col0 AS col0 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT + 97 + col2 FROM tab1
----
151
154
193

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 30 * + ( col2 ) col2 FROM tab0
----
2460
30
990

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

query I rowsort
SELECT + ( 47 ) * - col1 FROM tab2
----
-1457
-2773
-799

query I rowsort
SELECT ( 20 ) * - cor0.col0 + 96 AS col0 FROM tab0 AS cor0
----
-1684
-384
-604

query I rowsort
SELECT ALL + + col0 + 2 FROM tab2 AS cor0
----
80
81
9

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

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

query I rowsort
SELECT - col0 * + col0 + col0 * - 75 * - col2 FROM tab2 AS cor0
----
14126
146016
218909

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

query I rowsort
SELECT DISTINCT + 88 FROM tab0, tab2, tab1 cor0
----
88

query I rowsort
SELECT DISTINCT - 67 * - col0 FROM tab0
----
1608
2345
5963

query I rowsort
SELECT + 22 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT ALL 98 * + col1 FROM tab1
----
1274
2548
980

query I rowsort
SELECT 50 AS col2 FROM tab1, tab0, tab0 cor0
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT + 76 * + 3 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 14e2ab7f79d4913575e2f4a067d40fa5

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

query I rowsort
SELECT DISTINCT + 85 * + col2 + 51 AS col0 FROM tab1 AS cor0
----
4641
4896
8211

query I rowsort
SELECT DISTINCT col1 * - col0 * - 2 AS col1 FROM tab1
----
1280
156
2080

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

query I rowsort
SELECT ALL 35 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

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

skipif mysql # not compatible
query I rowsort label-1199
SELECT DISTINCT - col0 / ( col2 + col2 * - col1 ) AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - cor0.col2 * 96 AS col0 FROM tab1 AS cor0
----
-5184
-5472
-9216

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

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

query I rowsort
SELECT DISTINCT cor0.col1 + ( + 9 + col2 * + col1 ) FROM tab1 AS cor0
----
1270
1439
589

query I rowsort
SELECT ALL + cor0.col1 + 33 * ( + col2 * + col1 ) AS col0 FROM tab2 AS cor0
----
21335
27652
50681

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

query I rowsort
SELECT - col1 + + col1 * 19 AS col1 FROM tab1 AS cor0
----
180
234
468

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

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

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

query I rowsort
SELECT ALL + col0 * - 87 FROM tab1
----
-261
-5568
-6960

query I rowsort
SELECT ALL - + col1 + + col0 * + 28 AS col2 FROM tab1 cor0
----
1782
2227
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-1212
SELECT DISTINCT + col0 * col1 + col1 DIV col0 AS col0 FROM tab0 AS cor0
----
2067
3397
8100

skipif mysql # not compatible
query I rowsort label-1212
SELECT DISTINCT + col0 * col1 + col1 / col0 AS col0 FROM tab0 AS cor0
----
2067
3397
8100

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

query I rowsort
SELECT ALL - col2 + + col1 + + col1 AS col0 FROM tab1 cor0
----
-2
-37
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-1215
SELECT + + col0 + + col2 DIV + col1 FROM tab2 AS cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-1215
SELECT + + col0 + + col2 / + col1 FROM tab2 AS cor0
----
7
78
81

query I rowsort
SELECT ALL col0 * + 61 FROM tab1 AS cor0
----
183
3904
4880

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

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

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

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

query I rowsort
SELECT - ( + cor0.col0 ) FROM tab0, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT + 45 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1170
450
585

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

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

query I rowsort
SELECT ALL + - col1 * col0 + 95 * + col1 AS col2 FROM tab1 AS cor0
----
195
2392
310

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

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

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

query I rowsort
SELECT ALL - col0 + - col0 * 10 FROM tab1 AS cor0
----
-33
-704
-880

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

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

query I rowsort
SELECT ALL - col0 + + 40 * - col0 * col0 AS col0 FROM tab2
----
-1967
-243438
-249719

query I rowsort
SELECT col2 + - cor0.col2 * + 42 AS col1 FROM tab1 AS cor0
----
-2214
-2337
-3936

query I rowsort
SELECT + 93 + + col2 * + col1 AS col0 FROM tab0 AS cor0
----
190
2931
7555

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

query I rowsort
SELECT - cor0.col2 + + col0 * 63 AS col2 FROM tab0 AS cor0
----
1479
2204
5525

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 27 col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-1236
SELECT + 29 + - col1 DIV + col0 AS col0 FROM tab0 AS cor0
----
26
27
28

skipif mysql # not compatible
query I rowsort label-1236
SELECT + 29 + - col1 / + col0 AS col0 FROM tab0 AS cor0
----
26
27
28

query I rowsort
SELECT - - col0 * col2 * 97 + + col1 * - col2 AS col2 FROM tab1 AS cor0
----
14310
353286
743712

query I rowsort
SELECT - 67 * - cor0.col2 + + 82 * + col2 FROM tab0 cor0
----
12218
149
4917

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1240
SELECT - - col2 DIV cor0.col2 + - 12 * + col1 col2 FROM tab1 AS cor0
----
-119
-155
-311

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1240
SELECT - - col2 / cor0.col2 + - 12 * + col1 col2 FROM tab1 AS cor0
----
-119
-155
-311

query I rowsort
SELECT 92 * - col0 + col0 * ( col0 ) - + 44 * - col0 AS col2 FROM tab2 AS cor0
----
-287
2340
2449

onlyif mysql # use DIV operator for integer division
query I rowsort label-1242
SELECT ALL + col0 * col2 + cor0.col2 DIV 4 FROM tab2 AS cor0
----
195
2034
3011

skipif mysql # not compatible
query I rowsort label-1242
SELECT ALL + col0 * col2 + cor0.col2 / 4 FROM tab2 AS cor0
----
195
2034
3011

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

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

query I rowsort
SELECT DISTINCT col0 - 65 * - 16 AS col2 FROM tab1 AS cor0
----
1043
1104
1120

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

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

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

query I rowsort
SELECT cor0.col2 + - 95 * - col0 AS col0 FROM tab1 AS cor0
----
339
6137
7696

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

query I rowsort
SELECT col2 * + cor0.col2 + - cor0.col0 * 86 FROM tab2 AS cor0
----
-5350
-6032
127

query I rowsort
SELECT + 7 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to d173222899c2eacb69f7b1d1084a1230

query I rowsort
SELECT ALL + 57 - 64 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1254
SELECT ALL ( - col1 ) + + CAST( - cor0.col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-55
-58
-85

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

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

query I rowsort
SELECT DISTINCT - col2 * col0 + + col2 + col1 FROM tab1
----
-3581
-7571
-82

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1258
SELECT DISTINCT ( - col1 ) DIV - CAST( col2 AS SIGNED ) - col1 * col2 FROM tab0
----
-2836
-7461
0

skipif mysql # not compatible
query I rowsort label-1258
SELECT DISTINCT ( - col1 ) / - CAST ( col2 AS INTEGER ) - col1 * col2 FROM tab0
----
-2836
-7461
0

query I rowsort
SELECT 29 * col0 * - ( 83 ) AS col2 FROM tab2
----
-16849
-187746
-190153

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

query I rowsort
SELECT col1 * - col0 + + ( - col2 + + col1 * + ( + cor0.col2 ) ) FROM tab2 AS cor0
----
-3094
-735
593

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1263
SELECT DISTINCT - col2 + 44 DIV col1 FROM tab1
----
-53
-93

skipif mysql # not compatible
query I rowsort label-1263
SELECT DISTINCT - col2 + 44 / col1 FROM tab1
----
-53
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1264
SELECT ALL col1 DIV 96 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1264
SELECT ALL col1 / 96 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col0 * 71 FROM tab0
----
-1704
-2485
-6319

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1266
SELECT DISTINCT + CAST( col2 AS SIGNED ) + - cor0.col1 AS col0 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-1266
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + - cor0.col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - 64 * cor0.col1 FROM tab0 AS cor0
----
-5504
-5824
-6208

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

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

query I rowsort
SELECT DISTINCT - cor0.col2 * - 51 FROM tab1 AS cor0
----
2754
2907
4896

query I rowsort
SELECT ALL + 58 * 26 * cor0.col1 + ( 98 ) * - col1 + 10 AS col0 FROM tab1 AS cor0
----
14110
18340
36670

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * 90 col1 FROM tab1
----
-1170
-2340
-900

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

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

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

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

query I rowsort
SELECT DISTINCT col2 * - 16 AS col0 FROM tab2 AS cor0
----
-416
-432
-608

query I rowsort
SELECT DISTINCT 59 + + col1 AS col0 FROM tab1 cor0
----
69
72
85

query I rowsort
SELECT ALL - 84 + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-119
-7382
-876

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

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

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

query III rowsort
SELECT * FROM tab1 cor0 WHERE NULL = col1 + - col2
----

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

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

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

query I rowsort
SELECT ALL + col2 * col1 * col1 + col2 - col1 AS col1 FROM tab0
----
244015
679033
9313

query I rowsort
SELECT DISTINCT - col2 * - col2 + + col2 * col0 * + tab0.col1 + - tab0.col0 AS col0 FROM tab0
----
3361
670753
69177

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

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

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

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

query I rowsort
SELECT tab2.col0 + col1 + col2 * + col1 FROM tab2
----
1671
742
875

query I rowsort
SELECT ALL col0 + - col1 + tab0.col1 AS col0 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1291
SELECT col0 * col0 DIV + tab1.col1 AS col2 FROM tab1
----
0
409
492

skipif mysql # not compatible
query I rowsort label-1291
SELECT col0 * col0 / + tab1.col1 AS col2 FROM tab1
----
0
409
492

query I rowsort
SELECT ALL tab1.col0 + tab1.col1 * col2 * col0 FROM tab1
----
36544
4215
99920

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

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

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

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1297
SELECT ALL - tab2.col1 DIV col1 - - col2 DIV col1 FROM tab2
----
-1
-1
1

skipif mysql # not compatible
query I rowsort label-1297
SELECT ALL - tab2.col1 / col1 - - col2 / col1 FROM tab2
----
-1
-1
1

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + tab1.col0 + - col2 col0 FROM tab1
----
24
583
944

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col2 + col0 col1 FROM tab0 cor0
----
1113
36
6813

query I rowsort
SELECT col2 * col2 + - col2 FROM tab0
----
0
1056
6642

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

query I rowsort
SELECT ALL - tab2.col1 * col0 + col1 + col1 AS col2 FROM tab2
----
-1309
-155
-4484

query I rowsort
SELECT ALL + col1 + - col2 + + col2 * col2 * - col1 FROM tab1
----
-119891
-32537
-75844

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

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

query I rowsort
SELECT - col0 + - cor0.col0 + col1 FROM tab1 AS cor0
----
-118
-147
20

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

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

query I rowsort
SELECT DISTINCT - col2 * - col2 - col0 FROM tab1 AS cor0
----
2913
3185
9136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 * + col0 col0 FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-1315
SELECT - col2 DIV col1 + - col0 col0 FROM tab2
----
-7
-78
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1315
SELECT - col2 / col1 + - col0 col0 FROM tab2
----
-7
-78
-81

query I rowsort
SELECT DISTINCT + + 76 + col0 * + 63 FROM tab0 AS cor0
----
1588
2281
5683

onlyif mysql # use DIV operator for integer division
query I rowsort label-1317
SELECT col1 * tab1.col2 * - col0 + col2 DIV - col0 AS col0 FROM tab1
----
-36480
-4230
-99841

skipif mysql # not compatible
query I rowsort label-1317
SELECT col1 * tab1.col2 * - col0 + col2 / - col0 AS col0 FROM tab1
----
-36480
-4230
-99841

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1321
SELECT DISTINCT - - cor0.col2 DIV 25 AS col2 FROM tab1 AS cor0
----
2
3

skipif mysql # not compatible
query I rowsort label-1321
SELECT DISTINCT - - cor0.col2 / 25 AS col2 FROM tab1 AS cor0
----
2
3

query I rowsort
SELECT ALL + 1 + + cor0.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2036013494344f92349618089e7342a0

query I rowsort
SELECT col2 * col1 + - ( col2 ) * + col2 FROM tab1 AS cor0
----
-1512
-2679
-7968

query I rowsort
SELECT - + col0 * 18 FROM tab1 AS cor0
----
-1152
-1440
-54

query I rowsort
SELECT + col1 FROM tab0 WHERE + col0 NOT IN ( tab0.col2 * + col0 )
----
86
91

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

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

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

query I rowsort
SELECT ALL col1 AS col0 FROM tab1 WHERE col0 + + col2 + + tab1.col0 NOT IN ( + col0 * tab1.col1 )
----
10
13
26

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

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

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

query I rowsort
SELECT + col0 * col0 * + col2 - col0 AS col2 FROM tab0
----
1190
18984
649433

query I rowsort
SELECT DISTINCT col1 * + col1 + + col1 * col1 FROM tab0
----
14792
16562
18818

query I rowsort
SELECT DISTINCT + col2 FROM tab1 WHERE NOT ( NULL ) > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1336
SELECT DISTINCT + col2 DIV + tab0.col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-1336
SELECT DISTINCT + col2 / + tab0.col1 FROM tab0
----
0

query I rowsort
SELECT - col0 + col2 * + col0 AS col1 FROM tab1
----
159
3584
7600

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1340
SELECT - col2 * + col2 + + CAST( - col2 + col1 AS SIGNED ) DIV col0 FROM tab1 AS cor0
----
-2925
-3249
-9217

skipif mysql # not compatible
query I rowsort label-1340
SELECT - col2 * + col2 + + CAST ( - col2 + col1 AS INTEGER ) / col0 FROM tab1 AS cor0
----
-2925
-3249
-9217

query I rowsort
SELECT + col2 + cor0.col0 + col1 FROM tab0 AS cor0
----
133
143
262

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) IN ( - col0 )
----

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

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

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

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

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

query I rowsort
SELECT 42 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-47
18
7

query I rowsort
SELECT col1 * - 35 * col1 FROM tab0 AS cor0
----
-258860
-289835
-329315

query I rowsort
SELECT + ( + 6 ) * col1 FROM tab2 AS cor0
----
102
186
354

query I rowsort
SELECT - 46 - + col1 AS col2 FROM tab0 AS cor0
----
-132
-137
-143

query I rowsort
SELECT - col2 + + ( col0 ) * - 19 AS col0 FROM tab2 AS cor0
----
-1508
-1539
-160

query I rowsort
SELECT DISTINCT - col2 + 84 AS col1 FROM tab2 AS cor0
----
46
57
58

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

query I rowsort
SELECT DISTINCT 23 + + ( - col0 ) * col0 AS col1 FROM tab0 AS cor0
----
-1202
-553
-7898

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

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

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

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

query I rowsort
SELECT DISTINCT + - ( 49 ) * - col0 AS col1 FROM tab2 AS cor0
----
343
3822
3871

query I rowsort
SELECT ALL 52 * - col2 FROM tab1 AS cor0
----
-2808
-2964
-4992

query I rowsort
SELECT + ( + 36 ) + cor0.col0 * 45 FROM tab2 AS cor0
----
351
3546
3591

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

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

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

query I rowsort
SELECT + 4 * cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to d7ba7ed61b7057db35c81f7023c2891b

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

query I rowsort
SELECT ALL - col0 * ( 75 * col1 ) + - ( 26 ) FROM tab0 AS cor0
----
-154826
-254651
-607451

query I rowsort
SELECT col2 * 34 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
1146
2877
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-1367
SELECT DISTINCT + col0 * + col2 - - col1 DIV - cor0.col1 FROM tab1 cor0
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-1367
SELECT DISTINCT + col0 * + col2 - - col1 / - cor0.col1 FROM tab1 cor0
----
161
3647
7679

query I rowsort
SELECT + col0 * + ( - 11 ) * col0 AS col1 FROM tab0 AS cor0
----
-13475
-6336
-87131

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

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

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

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

query I rowsort
SELECT DISTINCT + col1 * ( + col2 ) * col1 + + col1 * col1 FROM tab2 AS cor0
----
11271
26908
93987

onlyif mysql # use DIV operator for integer division
query I rowsort label-1374
SELECT DISTINCT - + col2 * + col1 + - col1 - cor0.col2 DIV col2 AS col0 FROM tab1 AS cor0
----
-1262
-1431
-581

skipif mysql # not compatible
query I rowsort label-1374
SELECT DISTINCT - + col2 * + col1 + - col1 - cor0.col2 / col2 AS col0 FROM tab1 AS cor0
----
-1262
-1431
-581

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

query I rowsort
SELECT DISTINCT + - col2 * - col2 * col2 - + col2 AS col1 FROM tab1 AS cor0
----
157410
185136
884640

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 20 col1 FROM tab1 AS cor0
----
-200
-260
-520

query I rowsort
SELECT DISTINCT - - cor0.col1 + 87 FROM tab0 AS cor0
----
173
178
184

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 - cor0.col1 * CAST ( 16 AS REAL ) FROM tab2 AS cor0
----
-1003
-289
-527

query I rowsort
SELECT + - ( - col0 ) + 3 FROM tab2 AS cor0
----
10
81
82

query I rowsort
SELECT ALL col1 * - cor0.col0 - + 92 FROM tab0 AS cor0
----
-2156
-3487
-8191

query I rowsort
SELECT ALL - 70 + - col1 AS col0 FROM tab2 cor0
----
-101
-129
-87

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

skipif mysql # not compatible
query I rowsort label-1386
SELECT 19 / col0 + col1 * col2 AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + 69 * col0 * col0 FROM tab0 AS cor0
----
39744
546549
84525

onlyif mysql # use DIV operator for integer division
query I rowsort label-1388
SELECT DISTINCT 55 * + col1 DIV + col1 - - ( - col1 ) FROM tab1
----
29
42
45

skipif mysql # not compatible
query I rowsort label-1388
SELECT DISTINCT 55 * + col1 / + col1 - - ( - col1 ) FROM tab1
----
29
42
45

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1391
SELECT ALL ( col1 ) * + CAST ( - col0 AS INTEGER ) + col0 AS col0 FROM tab1
----
-576
-75
-960

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

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

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

query I rowsort
SELECT ALL - col1 + col1 * - 55 FROM tab0
----
-4816
-5096
-5432

query I rowsort
SELECT DISTINCT ( col2 ) + 89 * 77 AS col0 FROM tab1
----
6907
6910
6949

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 cor2
----
243 values hashing to 3dcd863493ac16ce594c62d4ac8b0412

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

query I rowsort
SELECT DISTINCT - 15 AS col0 FROM tab1 AS cor0
----
-15

query I rowsort
SELECT - col1 * + ( - col1 ) + 93 FROM tab2 AS cor0
----
1054
3574
382

query I rowsort
SELECT ALL col2 + - col1 * + col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT ALL - ( + 80 ) + col1 * col2 FROM tab2 AS cor0
----
1454
566
757

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

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

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

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

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

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

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

query I rowsort
SELECT + 16 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 9ffb4aaf972de606a4957894645b6216

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

query I rowsort
SELECT + col0 + 82 FROM tab1 AS cor0
----
146
162
85

query I rowsort
SELECT + cor0.col0 * + 94 + 3 AS col1 FROM tab0 AS cor0
----
2259
3293
8369

onlyif mysql # use DIV operator for integer division
query I rowsort label-1413
SELECT DISTINCT col2 + + col1 DIV - 63 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1413
SELECT DISTINCT col2 + + col1 / - 63 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL col0 * - col2 + 15 AS col2 FROM tab0 AS cor0
----
-20
-7283
-777

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

query I rowsort
SELECT col1 + - ( - col1 ) * - col1 + - col0 FROM tab1
----
-154
-236
-653

query I rowsort
SELECT 87 AS col2 FROM tab0, tab1, tab2 AS cor0, tab2
----
81 values hashing to 969f31ae779866644763e8a07f1ec501

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

query I rowsort
SELECT - + col0 - + 20 AS col0 FROM tab1 AS cor0
----
-100
-23
-84

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

query I rowsort
SELECT - - col1 * - 95 - - col2 * col1 FROM tab2 AS cor0
----
-2108
-4071
-969

query I rowsort
SELECT + col1 + + 92 * 79 AS col1 FROM tab2 AS cor0
----
7285
7299
7327

query I rowsort
SELECT DISTINCT - cor0.col2 * + col2 + ( col2 ) * col1 * - col2 AS col1 FROM tab1 AS cor0
----
-129024
-35739
-78732

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

query I rowsort
SELECT - 27 + + col0 + + col0 AS col0 FROM tab0 AS cor0
----
151
21
43

query I rowsort
SELECT ALL + col0 * - 37 FROM tab1 AS cor0
----
-111
-2368
-2960

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1428
SELECT DISTINCT + 12 DIV col0 FROM tab1 cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-1428
SELECT DISTINCT + 12 / col0 FROM tab1 cor0
----
0
4

query I rowsort
SELECT ALL + 11 * 21 AS col2 FROM tab0 AS cor0
----
231
231
231

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 31 * col2 + + cor0.col1 + 27 col1 FROM tab0 AS cor0
----
-2424
-910
93

query I rowsort
SELECT DISTINCT - col2 + - 38 AS col1 FROM tab0
----
-120
-39
-71

query I rowsort
SELECT ALL col1 + 89 FROM tab1
----
102
115
99

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col1 * + col2 - ( col2 ) * 59 col2 FROM tab0
----
2624
38
891

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

query I rowsort
SELECT ALL - 35 FROM tab2, tab1 cor0
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT DISTINCT col1 + + col1 * col0 * - tab0.col2 AS col2 FROM tab0
----
-3298
-664027
-68026

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

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

skipif mysql # not compatible
query I rowsort label-1440
SELECT - cor0.col0 + + CAST ( NULL AS INTEGER ) * tab2.col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + col1 * 65 FROM tab2
----
1105
2015
3835

query I rowsort
SELECT DISTINCT + 62 * + col2 AS col2 FROM tab2
----
1612
1674
2356

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

query I rowsort
SELECT - 56 * + col2 FROM tab0
----
-1848
-4592
-56

query I rowsort
SELECT + 74 * 84 FROM tab1
----
6216
6216
6216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col2 * col1 ) + tab1.col1 col0 FROM tab1
----
1261
1430
580

query I rowsort
SELECT - col2 + + ( - col1 * + col0 ) - - 82 FROM tab0 AS cor0
----
-2015
-3314
-8099

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

query I rowsort
SELECT ALL 8 * - col1 * 59 AS col1 FROM tab0
----
-40592
-42952
-45784

query I rowsort
SELECT - cor0.col0 * - 69 FROM tab2, tab2 AS cor0
----
9 values hashing to 327033a0552226769c3eef5e7d8d7666

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

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

query I rowsort
SELECT 67 * 69 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 52f738aee99879c3eefe9d30ca675a81

onlyif mysql # use DIV operator for integer division
query I rowsort label-1454
SELECT + col1 DIV 29 + - 25 AS col2 FROM tab1 cor0
----
-25
-25
-25

skipif mysql # not compatible
query I rowsort label-1454
SELECT + col1 / 29 + - 25 AS col2 FROM tab1 cor0
----
-25
-25
-25

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

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

query I rowsort
SELECT col1 * - col1 - + 37 * col1 AS col2 FROM tab0 AS cor0
----
-10578
-11648
-12998

query I rowsort
SELECT - col2 + 10 * - col1 FROM tab1 cor0
----
-157
-226
-314

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1460
SELECT ALL + ( col1 ) + 89 DIV col1 AS col0 FROM tab1 AS cor0
----
18
19
29

skipif mysql # not compatible
query I rowsort label-1460
SELECT ALL + ( col1 ) + 89 / col1 AS col0 FROM tab1 AS cor0
----
18
19
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-1461
SELECT DISTINCT - col1 DIV - col1 - + 52 FROM tab0 AS cor0
----
-51

skipif mysql # not compatible
query I rowsort label-1461
SELECT DISTINCT - col1 / - col1 - + 52 FROM tab0 AS cor0
----
-51

query I rowsort
SELECT DISTINCT + 17 * + col0 * + col2 - col0 AS col2 FROM tab2 cor0
----
3206
34398
50955

query I rowsort
SELECT ALL - + 29 * col2 AS col1 FROM tab2 AS cor0
----
-1102
-754
-783

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 7 + + cor0.col2 col2 FROM tab2 AS cor0
----
33
34
45

query I rowsort
SELECT ALL + 33 * ( col2 ) FROM tab0
----
1089
2706
33

query I rowsort
SELECT ALL 46 * 94 AS col1 FROM tab1
----
4324
4324
4324

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

query I rowsort
SELECT + 60 * cor0.col0 * - col2 AS col0 FROM tab0 AS cor0
----
-2100
-437880
-47520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * col1 + - col0 col1 FROM tab1 AS cor0
----
36
673
89

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

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

query I rowsort
SELECT - 14 + + col2 FROM tab1 AS cor0
----
40
43
82

query I rowsort
SELECT - 60 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

query I rowsort
SELECT cor0.col0 + 10 * cor0.col1 * col2 AS col2 FROM tab2 AS cor0
----
15418
6539
8377

query I rowsort
SELECT + cor0.col0 * 88 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 745dbe316202e59b0fdd0f07d929c4d1

query I rowsort
SELECT DISTINCT + + 94 * - col2 + cor0.col0 FROM tab2 AS cor0
----
-2366
-2531
-3493

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

skipif mysql # not compatible
query I rowsort label-1477
SELECT + col2 + + 26 / col0 AS col2 FROM tab2 cor0
----
26
30
38

query I rowsort
SELECT DISTINCT + ( col1 ) + - tab0.col2 * col2 AS col2 FROM tab0
----
-1003
-6633
96

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

query I rowsort
SELECT ALL - ( col1 ) + col1 * + ( + 27 * cor0.col0 ) AS col1 FROM tab0 AS cor0
----
218582
55642
91568

query I rowsort
SELECT ALL - col2 * col2 + - col2 * - 14 FROM tab1 AS cor0
----
-2160
-2451
-7872

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * col0 + + col0 * + col0 col1 FROM tab0 cor0
----
1152
15842
2450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - 98 ) - - col2 col0 FROM tab2 AS cor0
----
124
125
136

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

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

query I rowsort
SELECT ALL + - 14 * - col2 * + col0 + - col0 FROM tab1 AS cor0
----
107440
2265
51008

query I rowsort
SELECT ALL + - ( + cor0.col1 ) * cor0.col2 - ( + col2 * col0 ) AS col2 FROM tab1 AS cor0
----
-1566
-4218
-8928

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

query I rowsort
SELECT DISTINCT - col0 + col0 * - 43 AS col1 FROM tab2 AS cor0
----
-308
-3432
-3476

query I rowsort
SELECT DISTINCT col2 * col0 * - 57 AS col2 FROM tab2 cor0
----
-10773
-115596
-171114

onlyif mysql # use DIV operator for integer division
query I rowsort label-1492
SELECT DISTINCT + 61 DIV - col1 + ( - cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-20
-32
-60

skipif mysql # not compatible
query I rowsort label-1492
SELECT DISTINCT + 61 / - col1 + ( - cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-20
-32
-60

query I rowsort
SELECT 28 * + 39 + col1 * 55 AS col2 FROM tab0
----
5822
6097
6427

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

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

query I rowsort
SELECT + - col0 * 99 * cor0.col2 + cor0.col2 FROM tab1 AS cor0
----
-15984
-361095
-760224

query IIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0 WHERE NULL IN ( + cor0.col0 )
----

query I rowsort
SELECT ALL - 66 + 13 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( tab2.col1 ) * ( + 14 ) col2 FROM tab2
----
238
434
826

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1502
SELECT DISTINCT + - cor0.col0 * 42 + - col2 DIV + col0 FROM tab1 AS cor0
----
-144
-2688
-3361

skipif mysql # not compatible
query I rowsort label-1502
SELECT DISTINCT + - cor0.col0 * 42 + - col2 / + col0 FROM tab1 AS cor0
----
-144
-2688
-3361

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

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

query I rowsort
SELECT ALL - - 62 * + col1 + col2 * - col2 FROM tab1 cor0
----
-1304
-2629
-8410

query I rowsort
SELECT DISTINCT col1 * 85 + 84 * col2 AS col1 FROM tab0
----
10082
14623
8329

query I rowsort
SELECT ALL tab2.col0 + ( 89 ) AS col2 FROM tab2
----
167
168
96

query I rowsort
SELECT col2 + + 27 AS col1 FROM tab1
----
123
81
84

query I rowsort
SELECT col2 - - 80 FROM tab1
----
134
137
176

onlyif mysql # use DIV operator for integer division
query I rowsort label-1509
SELECT col0 + + 63 DIV 49 + col2 AS col2 FROM tab1
----
122
177
58

skipif mysql # not compatible
query I rowsort label-1509
SELECT col0 + + 63 / 49 + col2 AS col2 FROM tab1
----
122
177
58

query I rowsort
SELECT DISTINCT + 59 + - col2 FROM tab0
----
-23
26
58

query I rowsort
SELECT - 68 + - col0 FROM tab1 AS cor0
----
-132
-148
-71

query I rowsort
SELECT ALL + col1 + cor0.col0 * ( - col0 ) AS col2 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT + col0 * ( - tab2.col0 ) FROM tab2
----
-49
-6084
-6241

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

query I rowsort
SELECT ALL + cor0.col1 * 90 AS col1 FROM tab2 AS cor0
----
1530
2790
5310

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1517
SELECT - + col2 + 56 DIV col0 + col1 FROM tab0 AS cor0
----
55
9
97

skipif mysql # not compatible
query I rowsort label-1517
SELECT - + col2 + 56 / col0 + col1 FROM tab0 AS cor0
----
55
9
97

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

query I rowsort
SELECT col1 * 38 FROM tab0
----
3268
3458
3686

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

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

query I rowsort
SELECT - tab0.col2 * 85 + + col0 AS col1 FROM tab0
----
-2781
-50
-6881

query I rowsort
SELECT DISTINCT - ( + col1 * - col0 ) + - tab2.col0 * - tab2.col2 + + col1 * + tab2.col2 AS col0 FROM tab2
----
1243
4991
8164

onlyif mysql # use DIV operator for integer division
query I rowsort label-1523
SELECT ALL + col0 + + tab0.col0 * + col2 DIV col2 AS col2 FROM tab0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-1523
SELECT ALL + col0 + + tab0.col0 * + col2 / col2 AS col2 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL 88 + + col0 AS col2 FROM tab1
----
152
168
91

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

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

query I rowsort
SELECT DISTINCT 19 + col2 AS col2 FROM tab1 AS cor0
----
115
73
76

query I rowsort
SELECT + - ( 14 ) + + col1 AS col0 FROM tab1 AS cor0
----
-1
-4
12

query I rowsort
SELECT DISTINCT - ( 77 ) * col0 FROM tab1 AS cor0
----
-231
-4928
-6160

query I rowsort
SELECT cor1.col0 * 9 FROM tab1, tab0 cor0, tab0 cor1
----
27 values hashing to a03f50dcb6acfac53983cdd46b446f85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1530
SELECT DISTINCT + 1 * - col1 + col0 DIV - col2 FROM tab1 cor0
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-1530
SELECT DISTINCT + 1 * - col1 + col0 / - col2 FROM tab1 cor0
----
-11
-13
-26

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

query I rowsort
SELECT DISTINCT 28 * col2 FROM tab1 AS cor0
----
1512
1596
2688

query I rowsort
SELECT DISTINCT - 83 - col0 AS col2 FROM tab0
----
-107
-118
-172

query I rowsort
SELECT ( col0 ) + col1 * - 10 - ( - col2 ) AS col1 FROM tab1
----
-203
21
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-1535
SELECT cor0.col1 - + col0 DIV col1 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-1535
SELECT cor0.col1 - + col0 / col1 FROM tab2 AS cor0
----
13
31
58

query I rowsort
SELECT DISTINCT + 54 * col2 AS col1 FROM tab1 AS cor0
----
2916
3078
5184

query I rowsort
SELECT - - 6 * col0 FROM tab1 AS cor0
----
18
384
480

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

query I rowsort
SELECT col2 + col0 * + ( 92 * + col0 ) AS col0 FROM tab1 AS cor0
----
376889
588896
882

query I rowsort
SELECT + + 20 * - col1 + ( - col1 ) FROM tab2 cor0
----
-1239
-357
-651

query I rowsort
SELECT - tab1.col1 * tab1.col1 * 79 FROM tab1
----
-13351
-53404
-7900

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 13 * - col1 col1 FROM tab0 AS cor0
----
-1118
-1183
-1261

query I rowsort
SELECT - + col1 + col0 + 38 FROM tab2 AS cor0
----
100
14
57

query I rowsort
SELECT - + col2 * 84 - - col0 AS col2 FROM tab1 AS cor0
----
-4533
-4724
-7984

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

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

query I rowsort
SELECT + + col2 * + col1 * + 20 AS col0 FROM tab1 AS cor0
----
11400
24960
28080

query I rowsort
SELECT ALL - 78 + + ( + col0 ) FROM tab1 AS cor0
----
-14
-75
2

query I rowsort
SELECT + + 28 + col1 FROM tab0 AS cor0
----
114
119
125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * + cor0.col1 + + cor0.col1 col0 FROM tab1 cor0
----
-156
-650
-90

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

skipif mysql # not compatible
query I rowsort
SELECT CAST ( ( - col1 ) AS REAL ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1553
SELECT + col0 + + 40 * tab2.col1 DIV + col1 FROM tab2
----
118
119
47

skipif mysql # not compatible
query I rowsort label-1553
SELECT + col0 + + 40 * tab2.col1 / + col1 FROM tab2
----
118
119
47

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

query I rowsort
SELECT - col0 + - 44 * + col0 FROM tab0
----
-1080
-1575
-4005

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

query I rowsort
SELECT DISTINCT - 60 AS col2 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
-60

query I rowsort
SELECT ALL col0 * - ( + col0 + - ( ( + col1 ) ) ) AS col1 FROM tab1 AS cor0
----
-3456
-5360
69

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

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

query I rowsort
SELECT + col2 + 66 FROM tab2 AS cor0
----
104
92
93

query I rowsort
SELECT + col0 * + col1 + - col2 * - 47 FROM tab1 AS cor0
----
2616
3319
5552

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 49 col2 FROM tab1
----
-147
-3136
-3920

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1564
SELECT ALL - col1 DIV ( - cor0.col2 ) - + col1 * + cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-1564
SELECT ALL - col1 / ( - cor0.col2 ) - + col1 * + cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

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

skipif mysql # not compatible
query I rowsort label-1565
SELECT DISTINCT ( + 75 ) / col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT - 3 + col1 * + col1 * + 80 FROM tab0 AS cor0
----
591677
662477
752717

query I rowsort
SELECT ALL + col2 * 30 FROM tab1 AS cor0
----
1620
1710
2880

onlyif mysql # use DIV operator for integer division
query I rowsort label-1568
SELECT ALL - - ( col1 ) DIV + col0 + - CAST( - col0 AS SIGNED ) FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-1568
SELECT ALL - - ( col1 ) / + col0 + - CAST ( - col0 AS INTEGER ) FROM tab2 AS cor0
----
11
78
79

query I rowsort
SELECT ALL + col1 * + col0 * + col1 - cor0.col1 FROM tab1 AS cor0
----
13507
2002
6390

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

skipif mysql # not compatible
query I rowsort label-1570
SELECT DISTINCT - col0 + col1 / - ( cor0.col1 ) FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT ALL cor0.col1 * + col2 * + 93 AS col2 FROM tab2 AS cor0
----
142662
60078
77841

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

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

skipif mysql # not compatible
query I rowsort
SELECT - col0 + col1 * CAST ( 99 AS REAL ) FROM tab0 AS cor0
----
8490
8920
9568

onlyif mysql # use DIV operator for integer division
query I rowsort label-1575
SELECT ALL + col2 * col0 DIV col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-1575
SELECT ALL + col2 * col0 / col0 FROM tab2 AS cor0
----
26
27
38

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

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

query I rowsort
SELECT ALL - col1 + 50 AS col2 FROM tab2
----
-9
19
33

query I rowsort
SELECT ALL + ( tab1.col0 ) + col1 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL - 28 + + 20 * col2 AS col0 FROM tab2
----
492
512
732

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

skipif mysql # not compatible
query I rowsort label-1581
SELECT DISTINCT CAST ( ( col0 ) AS INTEGER ) + - col0 AS col2 FROM tab0
----
0

query I rowsort
SELECT - col2 * - 59 + cor0.col1 AS col1 FROM tab2 AS cor0
----
1593
1624
2259

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

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

query I rowsort
SELECT col0 - + 18 FROM tab1 AS cor0
----
-15
46
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1585
SELECT DISTINCT + + col2 DIV + col2 + + 15 * col2 * - col0 col0 FROM tab0 AS cor0
----
-109469
-11879
-524

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1585
SELECT DISTINCT + + col2 / + col2 + + 15 * col2 * - col0 col0 FROM tab0 AS cor0
----
-109469
-11879
-524

onlyif mysql # use DIV operator for integer division
query I rowsort label-1586
SELECT ALL col2 + - ( - 35 ) - - col1 DIV col0 AS col1 FROM tab1 AS cor0
----
131
92
97

skipif mysql # not compatible
query I rowsort label-1586
SELECT ALL col2 + - ( - 35 ) - - col1 / col0 AS col1 FROM tab1 AS cor0
----
131
92
97

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

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

query I rowsort
SELECT col1 * col1 + + col1 * + cor0.col1 - + col2 AS col1 FROM tab1 AS cor0
----
1298
143
242

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

query I rowsort
SELECT ALL + cor0.col1 * + 34 + 90 FROM tab1, tab1 AS cor0
----
9 values hashing to 024feb3febba3f978fa4842636955774

query I rowsort
SELECT DISTINCT - tab2.col2 FROM tab2, tab0, tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + tab0.col2 * col1 * - ( - 63 ) AS col1 FROM tab0
----
178794
470106
6111

query I rowsort
SELECT - - 80 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

query I rowsort
SELECT ALL + col1 - 60 AS col0 FROM tab2
----
-1
-29
-43

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

query I rowsort
SELECT + col2 * + col0 - + cor0.col1 * col1 FROM tab0 AS cor0
----
-6604
-9374
-983

query I rowsort
SELECT col2 * - col2 * 25 AS col2 FROM tab1 AS cor0
----
-230400
-72900
-81225

query I rowsort
SELECT - + col2 + 76 * - cor0.col2 * col1 FROM tab1 AS cor0
----
-106758
-43377
-94944

query I rowsort
SELECT DISTINCT + col0 - - tab2.col1 FROM tab2
----
137
38
96

query I rowsort
SELECT + col0 * - col0 - col2 * + col2 AS col1 FROM tab1
----
-15616
-2925
-7345

query I rowsort
SELECT - 92 FROM tab2, tab1 cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

onlyif mysql # use DIV operator for integer division
query I rowsort label-1603
SELECT DISTINCT + tab1.col0 DIV - 61 - + col1 DIV col0 FROM tab1
----
-1
-8

skipif mysql # not compatible
query I rowsort label-1603
SELECT DISTINCT + tab1.col0 / - 61 - + col1 / col0 FROM tab1
----
-1
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1604
SELECT DISTINCT - CAST( + 95 AS SIGNED ) * cor0.col0 FROM tab0 cor0
----
-2280
-3325
-8455

skipif mysql # not compatible
query I rowsort label-1604
SELECT DISTINCT - CAST ( + 95 AS INTEGER ) * cor0.col0 FROM tab0 cor0
----
-2280
-3325
-8455

query I rowsort
SELECT + 81 - col1 AS col1 FROM tab1 AS cor0
----
55
68
71

query I rowsort
SELECT ALL col0 * - col1 + + col1 * + 92 FROM tab0 AS cor0
----
273
5529
5848

query I rowsort
SELECT col2 + - 96 + + 17 AS col2 FROM tab0
----
-46
-78
3

query I rowsort
SELECT DISTINCT col1 * col1 + col0 AS col2 FROM tab2
----
3559
368
968

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

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

query I rowsort
SELECT DISTINCT - ( 76 ) - + col0 AS col1 FROM tab1 AS cor0
----
-140
-156
-79

query I rowsort
SELECT - col1 * + col2 * + col0 + - ( col1 ) FROM tab1
----
-36490
-4238
-99853

query I rowsort
SELECT DISTINCT ( col2 ) * + col1 * col2 FROM tab0 cor0
----
611884
93654
97

query I rowsort
SELECT - 30 * 20 AS col0 FROM tab0 AS cor0
----
-600
-600
-600

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

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

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

query I rowsort
SELECT ALL + + cor0.col2 * col2 * col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL - ( - 19 ) * + col2 * 3 FROM tab1 AS cor0
----
3078
3249
5472

query I rowsort
SELECT - col2 * - col2 + - col1 AS col2 FROM tab0 AS cor0
----
-96
1003
6633

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

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

query I rowsort
SELECT ALL cor0.col1 * 16 FROM tab0 AS cor0
----
1376
1456
1552

query I rowsort
SELECT - - 88 * col0 FROM tab2 AS cor0
----
616
6864
6952

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

query I rowsort
SELECT ALL - 6 + + col2 * 11 + col2 FROM tab0 AS cor0
----
390
6
978

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

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

query I rowsort
SELECT - - col1 * 20 FROM tab0 AS cor0
----
1720
1820
1940

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

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

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

query I rowsort
SELECT + cor0.col1 * - ( 89 + - col1 * + cor0.col0 ) FROM tab0 AS cor0
----
169850
320682
728910

query I rowsort
SELECT cor0.col2 * 3 AS col0 FROM tab0 AS cor0
----
246
3
99

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

query I rowsort
SELECT + col1 * col1 + - col0 AS col0 FROM tab2 cor0
----
210
3403
954

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

query I rowsort
SELECT ALL + col0 - - col2 * + cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
114155
5110
52806

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

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

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

query I rowsort
SELECT col0 * + col1 * - col0 AS col2 FROM tab1
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col2 * col0 col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT - col0 * col0 + + tab1.col1 + col0 AS col0 FROM tab1
----
-4022
-6307
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-1642
SELECT + col1 DIV - tab2.col0 + + col0 + + col0 AS col0 FROM tab2
----
10
156
158

skipif mysql # not compatible
query I rowsort label-1642
SELECT + col1 / - tab2.col0 + + col0 + + col0 AS col0 FROM tab2
----
10
156
158

query I rowsort
SELECT DISTINCT col2 * col0 + + col0 AS col2 FROM tab2
----
196
2106
3081

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

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

query I rowsort
SELECT ALL col2 AS col1 FROM tab1 WHERE NOT NULL <= col1
----

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

query I rowsort
SELECT cor0.col1 + col0 + + col0 AS col2 FROM tab2 AS cor0
----
175
215
45

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

query I rowsort
SELECT - col0 FROM tab2 WHERE + col0 >= - col2 * col0 + col0
----
-7
-78
-79

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

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

query I rowsort
SELECT + col0 + + col0 * col0 * - col1 FROM tab2
----
-106018
-1512
-358878

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

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

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

query I rowsort
SELECT DISTINCT + + cor0.col1 * - col0 - col1 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
-2686
-434
-9204

query I rowsort
SELECT ALL col0 / + col1 + + col1 AS col0 FROM tab2 WHERE ( NULL ) > - col0 / col1
----

query III rowsort
SELECT * FROM tab1 WHERE col0 IN ( - col2 )
----

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

query I rowsort
SELECT ALL - col1 + + col1 FROM tab0 WHERE NULL <= NULL
----

query I rowsort
SELECT - col2 + - col2 * - col2 AS col0 FROM tab2
----
1406
650
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-1663
SELECT ALL tab2.col2 DIV col1 + col0 FROM tab2
----
7
78
81

skipif mysql # not compatible
query I rowsort label-1663
SELECT ALL tab2.col2 / col1 + col0 FROM tab2
----
7
78
81

query I rowsort
SELECT + col0 * col1 * - col1 FROM tab2 WHERE NOT ( - col1 ) >= ( - col1 - col1 * col2 * col2 )
----

query I rowsort
SELECT + ( + col1 ) * 62 AS col1 FROM tab1 AS cor0
----
1612
620
806

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

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

query I rowsort
SELECT DISTINCT col2 + - col1 FROM tab1 WHERE NULL BETWEEN NULL AND NULL
----

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

query I rowsort
SELECT DISTINCT - col0 * + col2 - + col2 * tab0.col0 FROM tab0
----
-14596
-1584
-70

query I rowsort
SELECT DISTINCT col2 * - col2 FROM tab1 WHERE ( col0 * - col2 ) NOT IN ( col2 + col2 )
----
-2916
-3249
-9216

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col2 * - col2 <> + col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

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

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

query I rowsort
SELECT - col0 * + col0 + - col2 FROM tab1 cor0
----
-4153
-63
-6496

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

query I rowsort
SELECT ALL - col2 * - col1 + col2 FROM tab1 WHERE NOT NULL BETWEEN col0 / col1 - + col2 * - col2 AND NULL
----

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

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL > - col2 + col2 - col0
----

query I rowsort
SELECT - col0 * col1 + col2 - - col0 FROM tab2
----
-1226
-183
-4498

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

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

query I rowsort
SELECT + col0 * tab0.col0 + - col1 * + col0 AS col2 FROM tab0
----
-1488
-178
-2170

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

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

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

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

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

query I rowsort
SELECT 31 - - col0 FROM tab1
----
111
34
95

query I rowsort
SELECT - 17 * - cor0.col1 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 5a62c337eec1c93b6e7e6d2b3af4eca6

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1691
SELECT ALL + col2 + - col0 + ( 7 ) DIV col1 AS col0 FROM tab2
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-1691
SELECT ALL + col2 + - col0 + ( 7 ) / col1 AS col0 FROM tab2
----
-41
-52
20

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 66 - col1 col0 FROM tab1
----
40
53
56

query I rowsort
SELECT - col1 * col2 * - 96 AS col0 FROM tab2
----
147264
62016
80352

query I rowsort
SELECT 5 + - cor0.col0 FROM tab2 cor0
----
-2
-73
-74

query I rowsort
SELECT + 70 * + col0 * - 98 + col2 FROM tab0 AS cor0
----
-164607
-240099
-610458

query I rowsort
SELECT DISTINCT col0 + col0 + col1 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT - cor0.col1 + + 2 FROM tab2 cor0
----
-15
-29
-57

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

query I rowsort
SELECT col0 + - 40 * col0 AS col0 FROM tab2 cor0
----
-273
-3042
-3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - 66 col0 FROM tab2 AS cor0
----
-104
-92
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * - 43 + - 95 + + col0 col2 FROM tab0 AS cor0
----
-17
1348
3520

query I rowsort
SELECT - col0 * + tab0.col1 * 17 AS col1 FROM tab0
----
-137683
-35088
-57715

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1704
SELECT DISTINCT - col0 + ( - col2 ) * col0 + + CAST( 19 * col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-2758
-985
393

skipif mysql # not compatible
query I rowsort label-1704
SELECT DISTINCT - col0 + ( - col2 ) * col0 + + CAST ( 19 * col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-2758
-985
393

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + - 50 * cor0.col0 + col1 AS col2 FROM tab0 AS cor0
----
-1114
-1653
-4359

query I rowsort
SELECT DISTINCT + col0 - 85 * col1 AS col0 FROM tab1 AS cor0
----
-1025
-2207
-786

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

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

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

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

query I rowsort
SELECT - 65 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 744531575c1b6461ed2916d4940e4d23

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1717
SELECT - col0 + - col1 DIV + col0 FROM tab0 AS cor0
----
-27
-37
-90

skipif mysql # not compatible
query I rowsort label-1717
SELECT - col0 + - col1 / + col0 FROM tab0 AS cor0
----
-27
-37
-90

query I rowsort
SELECT ALL + col1 * col0 + + col0 * ( col2 ) AS col1 FROM tab1 AS cor0
----
240
4288
8720

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1720
SELECT DISTINCT + + col0 DIV col1 + 96 AS col2 FROM tab1 AS cor0
----
102
96

skipif mysql # not compatible
query I rowsort label-1720
SELECT DISTINCT + + col0 / col1 + 96 AS col2 FROM tab1 AS cor0
----
102
96

query I rowsort
SELECT ALL cor0.col1 + cor0.col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - 19 * col2 + ( col0 + + col0 ) * - 79 FROM tab0 AS cor0
----
-15620
-4419
-5549

query I rowsort
SELECT ALL 14 - col1 * + 69 FROM tab1 AS cor0
----
-1780
-676
-883

onlyif mysql # use DIV operator for integer division
query I rowsort label-1724
SELECT DISTINCT col0 + + col2 + cor0.col0 * - col0 DIV col0 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1724
SELECT DISTINCT col0 + + col2 + cor0.col0 * - col0 / col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - 71 + col0 AS col0 FROM tab1 AS cor0
----
-68
-7
9

query I rowsort
SELECT 95 + + col2 AS col2 FROM tab1
----
149
152
191

query I rowsort
SELECT col1 * col0 + - cor0.col0 - ( - col0 + col0 ) AS col2 FROM tab2 AS cor0
----
1264
210
4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * col1 col2 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col0 + - ( col2 ) * + cor0.col1 * col0 col2 FROM tab2 AS cor0
----
-113568
-44793
-5810

query I rowsort
SELECT DISTINCT 87 + cor0.col2 FROM tab0 AS cor0
----
120
169
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 44 col2 FROM tab1 cor0
----
-44
-44
-44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1732
SELECT - CAST( + 85 AS SIGNED ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 91e44ead5e72fa22f87a57243e232ede

skipif mysql # not compatible
query I rowsort label-1732
SELECT - CAST ( + 85 AS INTEGER ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 91e44ead5e72fa22f87a57243e232ede

query I rowsort
SELECT - col1 * col0 + 90 FROM tab0 AS cor0
----
-1974
-3305
-8009

query I rowsort
SELECT ALL 92 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT - 20 * col1 + + tab0.col2 FROM tab0
----
-1687
-1738
-1939

onlyif mysql # use DIV operator for integer division
query I rowsort label-1736
SELECT 97 - - col2 DIV col2 AS col0 FROM tab0
----
98
98
98

skipif mysql # not compatible
query I rowsort label-1736
SELECT 97 - - col2 / col2 AS col0 FROM tab0
----
98
98
98

query I rowsort
SELECT ALL + ( col1 ) + cor0.col2 * col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1738
SELECT ALL - CAST( + ( col2 ) AS SIGNED ) * col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-1738
SELECT ALL - CAST ( + ( col2 ) AS INTEGER ) * col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - 33 AS col1 FROM tab0 cor0
----
-33
-33
-33

query I rowsort
SELECT - 78 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-2574
-6396
-78

query I rowsort
SELECT 42 * - cor0.col0 FROM tab1 AS cor0
----
-126
-2688
-3360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( cor0.col0 ) col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1743
SELECT + - col1 DIV ( 11 * - cor0.col1 + + 93 * col2 ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1743
SELECT + - col1 / ( 11 * - cor0.col1 + + 93 * col2 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * + ( 21 ) FROM tab2 AS cor0
----
-546
-567
-798

query I rowsort
SELECT DISTINCT + col2 + - 67 FROM tab2 AS cor0
----
-29
-40
-41

query I rowsort
SELECT + 27 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT DISTINCT col2 * - 32 + 88 * col1 + col0 AS col2 FROM tab0 AS cor0
----
5473
6536
8539

query I rowsort
SELECT DISTINCT - - col1 * - ( - ( cor0.col2 ) ) + col2 * - col2 * - col1 AS col0 FROM tab1 AS cor0
----
121056
33060
77220

query I rowsort
SELECT + + 65 + - col0 FROM tab0 AS cor0
----
-24
30
41

query I rowsort
SELECT - col1 * 21 FROM tab0 AS cor0
----
-1806
-1911
-2037

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab1 cor2
----
3645 values hashing to 15ae1b54cae2dcf5c6eef7f1d15689eb

query I rowsort
SELECT ALL + 75 + - col2 AS col0 FROM tab0 AS cor0
----
-7
42
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1753
SELECT CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1753
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - col1 * col1 + - tab2.col1 AS col2 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT - cor0.col0 AS col2 FROM tab1, tab0, tab2 cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1756
SELECT ALL - col1 DIV col0 + 97 + - col0 * - col0 * + col1 FROM tab0 cor0
----
118920
49630
720907

skipif mysql # not compatible
query I rowsort label-1756
SELECT ALL - col1 / col0 + 97 + - col0 * - col0 * + col1 FROM tab0 cor0
----
118920
49630
720907

query I rowsort
SELECT ALL - - col0 - + col0 * ( 83 ) AS col1 FROM tab2 AS cor0
----
-574
-6396
-6478

query I rowsort
SELECT + ( col2 + ( + col2 ) ) FROM tab1
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-1759
SELECT - col2 * - CAST( + col0 AS SIGNED ) DIV col0 + col1 AS col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-1759
SELECT - col2 * - CAST ( + col0 AS INTEGER ) / col0 + col1 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - 51 * + col1 AS col2 FROM tab2
----
-1581
-3009
-867

query I rowsort
SELECT ALL col1 * + tab0.col1 * + col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT + + col2 * - 41 FROM tab0 AS cor0
----
-1353
-3362
-41

query I rowsort
SELECT - col0 * + 70 FROM tab2
----
-490
-5460
-5530

query I rowsort
SELECT ALL 28 + ( + col0 ) * ( - tab2.col1 + + col0 ) FROM tab2
----
-140
1510
4926

query I rowsort
SELECT DISTINCT - col0 * col1 * - col0 AS col1 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT ALL - cor1.col2 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT + ( + 47 ) * col0 * tab2.col2 AS col1 FROM tab2
----
141094
8883
95316

query I rowsort
SELECT + 66 + 68 AS col2 FROM tab0 AS cor0
----
134
134
134

query I rowsort
SELECT DISTINCT 60 + - cor0.col0 AS col1 FROM tab0 cor0
----
-29
25
36

query I rowsort
SELECT + col1 + + col0 * + 11 AS col2 FROM tab0 AS cor0
----
1070
350
482

query I rowsort
SELECT 15 + col0 * ( + 65 ) AS col2 FROM tab0 AS cor0
----
1575
2290
5800

query I rowsort
SELECT - - col0 + col0 * - col0 * - col2 + + col2 AS col2 FROM tab2 cor0
----
1357
158288
237275

query I rowsort
SELECT ( col1 ) + ( + col2 ) AS col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT + + 11 + col2 FROM tab1 cor0
----
107
65
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-1775
SELECT + col1 + col1 + - ( 18 ) DIV col0 FROM tab2 cor0
----
118
34
60

skipif mysql # not compatible
query I rowsort label-1775
SELECT + col1 + col1 + - ( 18 ) / col0 FROM tab2 cor0
----
118
34
60

query I rowsort
SELECT ALL + 15 * 43 + + col0 + col1 * col0 FROM tab2 AS cor0
----
2067
5325
869

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + + CAST ( col0 AS REAL ) + col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - + 59 + + col1 * + col2 FROM tab1 cor0
----
1189
1345
511

query I rowsort
SELECT - - col2 + 97 - col2 AS col0 FROM tab1 AS cor0
----
97
97
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1780
SELECT ALL + CAST( - col0 AS SIGNED ) + col1 AS col2 FROM tab1
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-1780
SELECT ALL + CAST ( - col0 AS INTEGER ) + col1 AS col2 FROM tab1
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + tab2.col1 ) + ( 92 ) col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 01a246788be55d383c8bb0e142c09dbf

query I rowsort
SELECT 84 * + ( - col2 * col1 ) + 92 * - col2 + col2 AS col0 FROM tab0
----
-241395
-634270
-8239

query I rowsort
SELECT 47 * - tab2.col1 FROM tab2
----
-1457
-2773
-799

query I rowsort
SELECT DISTINCT - col1 - 9 AS col0 FROM tab1
----
-19
-22
-35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 98 * - ( col0 ) col0 FROM tab2 AS cor0
----
686
7644
7742

query I rowsort
SELECT col0 * 0 + - col2 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - 32 * cor0.col2 - + 12 FROM tab1, tab0 AS cor0
----
-1068
-2636
-44

query I rowsort
SELECT - + 31 AS col1 FROM tab1 cor0
----
-31
-31
-31

query I rowsort
SELECT + + col1 * - 61 + col2 AS col2 FROM tab1 AS cor0
----
-1532
-553
-697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1790
SELECT + 10 * + col0 + CAST( NULL AS SIGNED ) + col0 * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1790
SELECT + 10 * + col0 + CAST ( NULL AS INTEGER ) + col0 * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * - 51 FROM tab0 AS cor0
----
-4386
-4641
-4947

query I rowsort
SELECT DISTINCT + - cor0.col2 * 52 - 11 AS col1 FROM tab0 AS cor0
----
-1727
-4275
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-1793
SELECT DISTINCT col0 DIV 5 AS col0 FROM tab1 AS cor0
----
0
12
16

skipif mysql # not compatible
query I rowsort label-1793
SELECT DISTINCT col0 / 5 AS col0 FROM tab1 AS cor0
----
0
12
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-1794
SELECT DISTINCT col2 DIV col2 AS col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-1794
SELECT DISTINCT col2 / col2 AS col0 FROM tab0
----
1

query I rowsort
SELECT cor0.col2 * 32 FROM tab0 AS cor0
----
1056
2624
32

skipif mysql # not compatible
query I rowsort
SELECT - col2 * CAST ( 49 AS REAL ) FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT cor0.col0 * + 78 FROM tab0 AS cor0
----
1872
2730
6942

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1798
SELECT DISTINCT - col1 * CAST( NULL AS SIGNED ) * - col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1798
SELECT DISTINCT - col1 * CAST ( NULL AS INTEGER ) * - col0 AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1799
SELECT ALL + col1 DIV - 23 AS col1 FROM tab0 cor0
----
-3
-3
-4

skipif mysql # not compatible
query I rowsort label-1799
SELECT ALL + col1 / - 23 AS col1 FROM tab0 cor0
----
-3
-3
-4

query I rowsort
SELECT DISTINCT - col0 * col2 + col0 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT + col0 * - ( cor0.col2 ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + - col1 * 57 FROM tab2 AS cor0
----
-1767
-3363
-969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col2 + 53 col1 FROM tab0 AS cor0
----
1142
54
6777

onlyif mysql # use DIV operator for integer division
query I rowsort label-1804
SELECT ALL + col2 * 43 + + 98 DIV col0 AS col2 FROM tab1 AS cor0
----
2354
2452
4129

skipif mysql # not compatible
query I rowsort label-1804
SELECT ALL + col2 * 43 + + 98 / col0 AS col2 FROM tab1 AS cor0
----
2354
2452
4129

query I rowsort
SELECT - - col0 * ( + cor0.col2 ) AS col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-1806
SELECT col0 DIV + cor0.col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1806
SELECT col0 / + cor0.col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * - 77 FROM tab0 AS cor0
----
1848
2695
6853

query I rowsort
SELECT DISTINCT - col0 * - 77 + col1 * - cor0.col1 + 50 AS col2 FROM tab0 AS cor0
----
-1378
-5498
-6664

onlyif mysql # use DIV operator for integer division
query I rowsort label-1809
SELECT DISTINCT - + 98 DIV ( col1 ) + + col1 * cor0.col0 col0 FROM tab1 cor0
----
1033
631
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1809
SELECT DISTINCT - + 98 / ( col1 ) + + col1 * cor0.col0 col0 FROM tab1 cor0
----
1033
631
75

query I rowsort
SELECT ALL + col0 + + ( col2 ) * + col1 FROM tab0 cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-1811
SELECT DISTINCT col0 DIV col2 AS col1 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-1811
SELECT DISTINCT col0 / col2 AS col1 FROM tab1
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1812
SELECT + col0 DIV tab0.col0 + 34 * col1 AS col0 FROM tab0
----
2925
3095
3299

skipif mysql # not compatible
query I rowsort label-1812
SELECT + col0 / tab0.col0 + 34 * col1 AS col0 FROM tab0
----
2925
3095
3299

onlyif mysql # use DIV operator for integer division
query I rowsort label-1813
SELECT + - 20 + col2 DIV + cor0.col0 AS col1 FROM tab2 AS cor0
----
-17
-20
-20

skipif mysql # not compatible
query I rowsort label-1813
SELECT + - 20 + col2 / + cor0.col0 AS col1 FROM tab2 AS cor0
----
-17
-20
-20

query I rowsort
SELECT - col0 + col2 * tab0.col2 FROM tab0
----
-34
1065
6635

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1815
SELECT col0 + - CAST( NULL AS SIGNED ) * + tab2.col1 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1815
SELECT col0 + - CAST ( NULL AS INTEGER ) * + tab2.col1 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 91 * + col2 + - ( - 59 ) FROM tab2 AS cor0
----
-2307
-2398
-3399

query I rowsort
SELECT DISTINCT 34 + col0 + col0 FROM tab2 cor0
----
190
192
48

query I rowsort
SELECT + col2 * - col0 + - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col0 col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - col0 + col1 * 66 AS col2 FROM tab2 AS cor0
----
1043
2039
3816

query I rowsort
SELECT ALL + 9 - - cor0.col1 AS col1 FROM tab2 cor0
----
26
40
68

query I rowsort
SELECT - col2 * - cor0.col2 + + 89 AS col1 FROM tab0 AS cor0
----
1178
6813
90

query I rowsort
SELECT DISTINCT + - col2 + col2 * - col1 AS col0 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT - cor0.col1 + + col1 + + ( + col0 ) * + col0 FROM tab2 cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 76 * col1 - + col1 col1 FROM tab1
----
1950
750
975

query I rowsort
SELECT DISTINCT - col0 - - col0 FROM tab2
----
0

query I rowsort
SELECT - col2 + + tab0.col1 + - col0 FROM tab0
----
-80
29
61

query I rowsort
SELECT ALL 34 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT ALL + col0 * + col2 + - ( - col0 * col2 ) FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT ALL + 4 * + col1 - ( 36 + - cor0.col0 ) * col0 FROM tab2 AS cor0
----
-79
3465
3512

onlyif mysql # use DIV operator for integer division
query I rowsort label-1831
SELECT ALL + cor0.col1 * - col0 + + col1 - + col2 DIV col2 col1 FROM tab1 AS cor0
----
-1028
-53
-631

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1831
SELECT ALL + cor0.col1 * - col0 + + col1 - + col2 / col2 col1 FROM tab1 AS cor0
----
-1028
-53
-631

onlyif mysql # use DIV operator for integer division
query I rowsort label-1832
SELECT - ( + col0 ) - ( - cor0.col1 + col1 ) DIV col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-1832
SELECT - ( + col0 ) - ( - cor0.col1 + col1 ) / col1 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1833
SELECT DISTINCT col2 * col2 + CAST( - 54 AS SIGNED ) * col0 AS col0 FROM tab1
----
-207
2754
4896

skipif mysql # not compatible
query I rowsort label-1833
SELECT DISTINCT col2 * col2 + CAST ( - 54 AS INTEGER ) * col0 AS col0 FROM tab1
----
-207
2754
4896

query I rowsort
SELECT - 47 + - col1 * + col0 * - col1 AS col1 FROM tab2
----
22784
271471
6680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1835
SELECT DISTINCT + col1 + col1 - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1835
SELECT DISTINCT + col1 + col1 - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - ( - cor1.col0 ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
3
64
80

query I rowsort
SELECT DISTINCT 46 AS col1 FROM tab0
----
46

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col2 AS REAL ) FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col1 FROM tab1, tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + cor0.col1 * tab2.col2 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 2dce99ccc9ab3f12533423eaad01995c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1841
SELECT 62 * + ( col0 ) + - CAST( NULL AS SIGNED ) + col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1841
SELECT 62 * + ( col0 ) + - CAST ( NULL AS INTEGER ) + col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * ( col2 ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT col1 * - col1 * col2 AS col2 FROM tab1
----
-16224
-36504
-5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + ( tab2.col2 ) ) * - 48 col2 FROM tab2
----
1248
1296
1824

query I rowsort
SELECT DISTINCT 4 + cor0.col2 FROM tab1 AS cor0
----
100
58
61

query I rowsort
SELECT ALL + 44 + + col2 * col0 - - 0 * + cor0.col0 FROM tab1 AS cor0
----
206
3692
7724

query I rowsort
SELECT DISTINCT col1 * - col2 + + 77 FROM tab2 AS cor0
----
-1457
-569
-760

query I rowsort
SELECT ALL + col0 * - col1 + 2 * + 10 FROM tab2 cor0
----
-1323
-197
-4582

query I rowsort
SELECT DISTINCT - 91 AS col1 FROM tab0
----
-91

query I rowsort
SELECT col1 * - 66 FROM tab1 AS cor0
----
-1716
-660
-858

query I rowsort
SELECT DISTINCT - cor0.col0 * + 6 AS col0 FROM tab2, tab2 cor0
----
-42
-468
-474

query I rowsort
SELECT DISTINCT - - col2 * + 30 * col1 FROM tab0 AS cor0
----
223860
2910
85140

query I rowsort
SELECT ALL - col0 * - 45 + + col0 FROM tab0 AS cor0
----
1104
1610
4094

query I rowsort
SELECT + + col2 * col1 + + col0 AS col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + col1 + + ( - col2 ) AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + col1 * 40 + + col2 * - col0 FROM tab0 AS cor0
----
-3658
2648
3845

query I rowsort
SELECT cor0.col0 - 65 FROM tab0 AS cor0
----
-30
-41
24

query I rowsort
SELECT ALL - col1 * 96 AS col0 FROM tab0 AS cor0
----
-8256
-8736
-9312

query I rowsort
SELECT - + col2 + ( 19 ) * + col1 AS col1 FROM tab1 AS cor0
----
133
151
440

onlyif mysql # use DIV operator for integer division
query I rowsort label-1860
SELECT ALL - 53 DIV + col0 AS col1 FROM tab2 AS cor0
----
-7
0
0

skipif mysql # not compatible
query I rowsort label-1860
SELECT ALL - 53 / + col0 AS col1 FROM tab2 AS cor0
----
-7
0
0

query I rowsort
SELECT + - cor0.col0 * col2 + cor0.col0 + - 22 FROM tab2 AS cor0
----
-1972
-204
-2945

query I rowsort
SELECT + 67 * - col0 + + col2 + col2 FROM tab2 AS cor0
----
-415
-5174
-5217

query I rowsort
SELECT ( col0 ) * cor0.col1 + col1 * - 78 AS col1 FROM tab0 AS cor0
----
-4171
-4644
1001

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + 45 AS REAL ) FROM tab1 cor0
----
-45
-45
-45

query I rowsort
SELECT - - col2 + + col1 + col2 FROM tab2 AS cor0
----
111
85
93

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( + col0 * col2 AS REAL ) + 55 AS col0 FROM tab0
----
7353
847
90

query I rowsort
SELECT ALL 36 FROM tab0, tab0 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT - cor0.col1 + 98 FROM tab2 AS cor0
----
39
67
81

query I rowsort
SELECT - col2 * - cor0.col1 + - cor0.col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT - - col0 * - col2 * col0 + 74 FROM tab1 cor0
----
-233398
-412
-614326

query I rowsort
SELECT DISTINCT - - 9 * + 26 + + col0 * col1 AS col0 FROM tab2 AS cor0
----
1577
451
4836

query I rowsort
SELECT DISTINCT - col0 * + col2 + - col0 FROM tab2 cor0
----
-196
-2106
-3081

query I rowsort
SELECT + + col1 - + col0 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT - 64 + - cor0.col1 FROM tab0 AS cor0
----
-150
-155
-161

query I rowsort
SELECT ALL - + 99 * col1 AS col1 FROM tab0 AS cor0
----
-8514
-9009
-9603

onlyif mysql # use DIV operator for integer division
query I rowsort label-1876
SELECT DISTINCT + - col0 DIV col0 AS col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-1876
SELECT DISTINCT + - col0 / col0 AS col1 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT + 82 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab0 cor1, tab1, tab2 AS cor2
----
3645 values hashing to b34c9987c389223e07378cde8a36e94f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1879
SELECT - + col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1879
SELECT - + col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 * ( cor0.col2 ) * col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL - cor0.col0 + + tab2.col1 AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 64de71f07a6ba954417f781fbdd78d39

query I rowsort
SELECT ALL + tab0.col1 * - col1 * + col2 AS col0 FROM tab0
----
-244068
-679042
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-1883
SELECT col2 DIV 68 col2 FROM tab0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1883
SELECT col2 / 68 col2 FROM tab0
----
0
0
1

query I rowsort
SELECT ALL cor0.col2 * + 74 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 217f34269dc067351ad01dc43449f514

query I rowsort
SELECT - - 73 + col2 * ( + col1 ) FROM tab2 AS cor0
----
1607
719
910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1886
SELECT + CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1886
SELECT + CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + + 56 * col0 AS col1 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT 12 + + col1 AS col1 FROM tab1
----
22
25
38

query I rowsort
SELECT ALL col0 * col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1225
19008
649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-1890
SELECT ( tab1.col2 ) * - col0 + - col2 DIV col2 AS col2 FROM tab1
----
-163
-3649
-7681

skipif mysql # not compatible
query I rowsort label-1890
SELECT ( tab1.col2 ) * - col0 + - col2 / col2 AS col2 FROM tab1
----
-163
-3649
-7681

query I rowsort
SELECT - 61 - - tab2.col2 AS col1 FROM tab2
----
-23
-34
-35

query I rowsort
SELECT col2 * + col0 * - ( - col1 ) + + col1 * tab2.col1 FROM tab2
----
123133
51323
6820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT ALL 19 AS col0 FROM tab0 cor0
----
19
19
19

query I rowsort
SELECT DISTINCT - 77 + col2 * col1 FROM tab0 AS cor0
----
20
2761
7385

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col0 ) * + col2 col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col2 * 50 AS col0 FROM tab1 AS cor0
----
2700
2850
4800

query I rowsort
SELECT ALL + col0 * - col1 + + col0 * col0 AS col0 FROM tab0
----
-1488
-178
-2170

query I rowsort
SELECT + + col2 + - ( col1 ) * col1 AS col0 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT tab2.col1 * tab2.col1 * + ( col0 ) FROM tab2
----
22831
271518
6727

query I rowsort
SELECT 26 * - 51 * col1 + col2 * - 42 FROM tab2
----
-24138
-42240
-79326

query I rowsort
SELECT col1 - + 2 FROM tab1
----
11
24
8

query I rowsort
SELECT col0 * col1 + + col2 * + 51 * + col1 AS col2 FROM tab2
----
34289
42904
82836

query I rowsort
SELECT + - col2 + - col0 * - col2 AS col0 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-1905
SELECT - col2 * col2 DIV + cor0.col2 + cor0.col1 + + col0 AS col0 FROM tab0 AS cor0
----
131
77
98

skipif mysql # not compatible
query I rowsort label-1905
SELECT - col2 * col2 / + cor0.col2 + cor0.col1 + + col0 AS col0 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT - ( - cor0.col0 ) * + cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT 85 * + col2 AS col2 FROM tab2 AS cor0
----
2210
2295
3230

onlyif mysql # use DIV operator for integer division
query I rowsort label-1908
SELECT ALL + ( col0 ) DIV col0 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1908
SELECT ALL + ( col0 ) / col0 AS col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - 89 + col0 FROM tab1 AS cor0
----
-25
-86
-9

query I rowsort
SELECT ALL ( tab2.col2 ) + col0 * + col1 AS col2 FROM tab2
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1911
SELECT DISTINCT CAST( - col2 AS SIGNED ) * col2 + col1 * - col0 AS col0 FROM tab0
----
-14823
-3153
-3396

skipif mysql # not compatible
query I rowsort label-1911
SELECT DISTINCT CAST ( - col2 AS INTEGER ) * col2 + col1 * - col0 AS col0 FROM tab0
----
-14823
-3153
-3396

query I rowsort
SELECT ALL col0 + - 59 * + col1 + + col1 AS col0 FROM tab0
----
-4964
-5189
-5591

query I rowsort
SELECT + - cor0.col0 AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT - - ( - col2 ) * - col1 + - cor0.col2 * col2 + - col0 AS col2 FROM tab2 AS cor0
----
-877
101
780

query I rowsort
SELECT DISTINCT + - col0 * ( cor0.col1 + col0 ) * - col1 FROM tab2 cor0
----
128928
630474
8246

onlyif mysql # use DIV operator for integer division
query I rowsort label-1916
SELECT - + col2 * col1 DIV - col2 + col1 + col2 * col0 FROM tab0 AS cor0
----
229
7480
964

skipif mysql # not compatible
query I rowsort label-1916
SELECT - + col2 * col1 / - col2 + col1 + col2 * col0 FROM tab0 AS cor0
----
229
7480
964

onlyif mysql # use DIV operator for integer division
query I rowsort label-1917
SELECT - cor0.col0 + - col1 DIV + col1 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-1917
SELECT - cor0.col0 + - col1 / + col1 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT DISTINCT - - col1 * col1 + col0 + col2 * + cor0.col2 FROM tab0 AS cor0
----
15094
8509
9445

query I rowsort
SELECT ALL + - cor0.col2 * + ( + col0 ) AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - tab2.col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT DISTINCT - ( ( + col0 ) ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + - cor0.col1 - + col0 * col2 FROM tab0 AS cor0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 38 col0 FROM tab2 AS cor0
----
-38
-38
-38

query I rowsort
SELECT DISTINCT + col0 * - col1 + col1 AS col0 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + + 42 * - cor0.col0 FROM tab2 cor0
----
-294
-3276
-3318

query I rowsort
SELECT ALL + + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + + cor0.col1 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT 42 * col1 FROM tab1 AS cor0
----
1092
420
546

query I rowsort
SELECT ALL - ( + col2 ) * - col1 + + col1 + - col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT 62 * + cor0.col1 FROM tab0 AS cor0
----
5332
5642
6014

query I rowsort
SELECT DISTINCT 52 * col1 AS col1 FROM tab0 AS cor0
----
4472
4732
5044

query I rowsort
SELECT - - col1 + - cor0.col1 AS col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + 65 * - col2 + col0 * + col1 + - col0 AS col2 FROM tab0 AS cor0
----
-105
2680
3295

query I rowsort
SELECT DISTINCT + 95 * col2 * col0 FROM tab1 AS cor0
----
15390
346560
729600

query I rowsort
SELECT - - col1 + + ( 79 ) + + col0 FROM tab1 AS cor0
----
108
153
172

query I rowsort
SELECT - col1 + - col0 * ( col2 * col2 + col1 ) AS col2 FROM tab2 AS cor0
----
-115436
-5351
-57389

onlyif mysql # use DIV operator for integer division
query I rowsort label-1937
SELECT col1 DIV 61 - + ( - col0 ) * - col2 AS col2 FROM tab0 AS cor0
----
-34
-7297
-791

skipif mysql # not compatible
query I rowsort label-1937
SELECT col1 / 61 - + ( - col0 ) * - col2 AS col2 FROM tab0 AS cor0
----
-34
-7297
-791

onlyif mysql # use DIV operator for integer division
query I rowsort label-1938
SELECT - - col2 DIV ( - ( col1 ) ) FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-1938
SELECT - - col2 / ( - ( col1 ) ) FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT - tab2.col2 * + col2 * col1 FROM tab2
----
-22599
-24548
-39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1940
SELECT DISTINCT + col2 + CAST( col1 + - col1 AS SIGNED ) * - col2 FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-1940
SELECT DISTINCT + col2 + CAST ( col1 + - col1 AS INTEGER ) * - col2 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT + cor0.col2 - cor0.col2 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1942
SELECT ALL - col1 DIV ( - col1 + + col2 ) FROM tab2 AS cor0
----
0
1
7

skipif mysql # not compatible
query I rowsort label-1942
SELECT ALL - col1 / ( - col1 + + col2 ) FROM tab2 AS cor0
----
0
1
7

query I rowsort
SELECT DISTINCT - col0 * - col1 + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL col1 * + ( col1 ) + cor0.col2 * col2 FROM tab1 AS cor0
----
3349
3592
9385

query I rowsort
SELECT ALL col2 * col1 * col0 - + col2 * col2 FROM tab2 AS cor0
----
118976
49590
5130

query I rowsort
SELECT DISTINCT + + col1 + + 76 FROM tab2 cor0
----
107
135
93

query I rowsort
SELECT - cor0.col2 + 88 FROM tab1 AS cor0
----
-8
31
34

query I rowsort
SELECT ALL - - col0 * + col1 + cor0.col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + + col2 * ( col0 * col0 ) - + col1 * col0 AS col0 FROM tab0 AS cor0
----
-2170
16944
641423

query I rowsort
SELECT col1 * col0 * col2 - - col0 * cor0.col1 AS col1 FROM tab2 AS cor0
----
124254
52377
6076

query I rowsort
SELECT DISTINCT col0 + 62 FROM tab1 AS cor0
----
126
142
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-1952
SELECT DISTINCT col1 + + 20 * col2 DIV + col1 col0 FROM tab2 AS cor0
----
48
61
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1952
SELECT DISTINCT col1 + + 20 * col2 / + col1 col0 FROM tab2 AS cor0
----
48
61
67

query I rowsort
SELECT ALL + 10 FROM tab1, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

onlyif mysql # use DIV operator for integer division
query I rowsort label-1954
SELECT ALL col2 DIV 97 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1954
SELECT ALL col2 / 97 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - 50 * + col0 + + col1 + col2 AS col1 FROM tab0 cor0
----
-1081
-1652
-4277

query I rowsort
SELECT - 8 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
18
2
5

query I rowsort
SELECT ALL - 80 * col1 * - col1 FROM tab0 AS cor0
----
591680
662480
752720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1958
SELECT CAST( + 7 AS SIGNED ) + col0 * col1 + col1 AS col2 FROM tab2 AS cor0
----
1367
255
4668

skipif mysql # not compatible
query I rowsort label-1958
SELECT CAST ( + 7 AS INTEGER ) + col0 * col1 + col1 AS col2 FROM tab2 AS cor0
----
1367
255
4668

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1959
SELECT ALL + col0 - CAST( + 33 * + col1 AS SIGNED ) AS col2 FROM tab0
----
-2814
-2914
-3166

skipif mysql # not compatible
query I rowsort label-1959
SELECT ALL + col0 - CAST ( + 33 * + col1 AS INTEGER ) AS col2 FROM tab0
----
-2814
-2914
-3166

query I rowsort
SELECT ALL + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1961
SELECT ALL + ( tab1.col1 ) + + CAST( col2 AS SIGNED ) FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-1961
SELECT ALL + ( tab1.col1 ) + + CAST ( col2 AS INTEGER ) FROM tab1
----
109
67
80

query I rowsort
SELECT - col2 + + 87 FROM tab1 AS cor0
----
-9
30
33

query I rowsort
SELECT cor0.col2 + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-1964
SELECT ALL tab2.col0 DIV cor0.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d38b0634e14aec1019f26e61932e2843

skipif mysql # not compatible
query I rowsort label-1964
SELECT ALL tab2.col0 / cor0.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d38b0634e14aec1019f26e61932e2843

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col2 * - 47 col2 FROM tab0
----
-12
-1527
-3765

query I rowsort
SELECT ALL + tab1.col2 * - tab1.col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ALL 65 + tab2.col1 AS col2 FROM tab2
----
124
82
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1968
SELECT + CAST( + 94 AS SIGNED ) FROM tab0, tab0 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

skipif mysql # not compatible
query I rowsort label-1968
SELECT + CAST ( + 94 AS INTEGER ) FROM tab0, tab0 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT - tab1.col0 + - cor1.col2 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 41d5a9bd2085c265bfcaf0f8facfa543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 - 38 * col1 col1 FROM tab1 AS cor0
----
-316
-414
-985

query I rowsort
SELECT ALL + cor0.col0 + 94 FROM tab2 AS cor0
----
101
172
173

query I rowsort
SELECT DISTINCT cor0.col1 + - 56 AS col2 FROM tab2 AS cor0
----
-25
-39
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-1973
SELECT DISTINCT - 43 DIV col1 FROM tab1 AS cor0
----
-1
-3
-4

skipif mysql # not compatible
query I rowsort label-1973
SELECT DISTINCT - 43 / col1 FROM tab1 AS cor0
----
-1
-3
-4

query I rowsort
SELECT ALL + - ( col1 ) + - col0 * + ( + 84 ) AS col1 FROM tab1 AS cor0
----
-278
-5386
-6733

query I rowsort
SELECT + 8 * + col1 AS col0 FROM tab2 AS cor0
----
136
248
472

onlyif mysql # use DIV operator for integer division
query I rowsort label-1976
SELECT ALL 3 DIV cor0.col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1976
SELECT ALL 3 / cor0.col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL col0 * col2 + col0 AS col0 FROM tab1 AS cor0
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 61 * col2 + - col0 col2 FROM tab2 AS cor0
----
-1654
-1664
-2397

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 35 + - col0 col0 FROM tab1 cor0
----
-29
-45
32

query I rowsort
SELECT ALL + 44 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1452
3608
44

query I rowsort
SELECT ( + col0 ) + 63 * col0 - col2 * col0 AS col1 FROM tab1 AS cor0
----
-2560
30
448

query I rowsort
SELECT + col0 + col0 * + 99 * - col1 FROM tab0 AS cor0
----
-204312
-336070
-801712

query I rowsort
SELECT 12 * + col0 FROM tab0 AS cor0
----
1068
288
420

query I rowsort
SELECT ALL 22 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1985
SELECT - cor0.col1 - - CAST( + ( - col2 ) AS SIGNED ) * 1 col0 FROM tab0 AS cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1985
SELECT - cor0.col1 - - CAST ( + ( - col2 ) AS INTEGER ) * 1 col0 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT col2 - - ( + 89 + - col1 ) AS col1 FROM tab2 cor0
----
110
56
85

query I rowsort
SELECT DISTINCT + col0 + ( 77 ) AS col1 FROM tab0 cor0
----
101
112
166

query I rowsort
SELECT - - cor0.col2 * 49 + - col2 AS col2 FROM tab1 AS cor0
----
2592
2736
4608

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1989
SELECT + cor0.col0 + CAST( NULL AS DECIMAL ) * + col2 * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1989
SELECT + cor0.col0 + CAST ( NULL AS REAL ) * + col2 * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 72 AS col2 FROM tab0 AS cor0
----
-72
-72
-72

query I rowsort
SELECT DISTINCT + 13 AS col0 FROM tab0, tab1 cor0
----
13

query I rowsort
SELECT - ( ( cor0.col1 ) ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + col2 + col1 * + col2 AS col1 FROM tab2
----
1560
684
864

query I rowsort
SELECT - col0 + col1 * + col0 AS col2 FROM tab1 cor0
----
576
75
960

query I rowsort
SELECT DISTINCT 23 * + 37 AS col0 FROM tab2
----
851

query I rowsort
SELECT + + 87 + cor0.col1 AS col0 FROM tab2 AS cor0
----
104
118
146

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1997
SELECT DISTINCT CAST( NULL AS SIGNED ) * tab2.col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-1997
SELECT DISTINCT CAST ( NULL AS INTEGER ) * tab2.col2 FROM tab2
----
NULL

query I rowsort
SELECT + - ( + col1 ) + - col0 * col1 FROM tab0 cor0
----
-2150
-3492
-8190

query I rowsort
SELECT - 57 + + col2 + col1 FROM tab0 AS cor0
----
116
41
62

query I rowsort
SELECT ALL - col1 * - ( col0 ) + + ( + col2 ) + col0 * col2 AS col2 FROM tab0 AS cor0
----
15479
2889
3431

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2001
SELECT + - CAST( col0 AS SIGNED ) + col1 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-2001
SELECT + - CAST ( col0 AS INTEGER ) + col1 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - col2 + 49 FROM tab1 AS cor0
----
-47
-5
-8

query I rowsort
SELECT ALL + 96 * col1 FROM tab2 AS cor0
----
1632
2976
5664

query I rowsort
SELECT + - col2 + + col2 * col2 * + col0 + col0 * col0 FROM tab1 AS cor0
----
211975
743584
8703

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2006
SELECT DISTINCT - + ( - col0 ) * col0 + + CAST( - col1 AS SIGNED ) * col2 + col2 AS col1 FROM tab1 AS cor0
----
-1341
3583
5248

skipif mysql # not compatible
query I rowsort label-2006
SELECT DISTINCT - + ( - col0 ) * col0 + + CAST ( - col1 AS INTEGER ) * col2 + col2 AS col1 FROM tab1 AS cor0
----
-1341
3583
5248

query I rowsort
SELECT col1 + cor0.col0 * + ( col2 * col2 ) AS col1 FROM tab1 AS cor0
----
207946
737293
8774

query I rowsort
SELECT DISTINCT - 95 + + col1 FROM tab0
----
-4
-9
2

query I rowsort
SELECT + 65 * + col0 * - col1 FROM tab0 cor0
----
-134160
-220675
-526435

query I rowsort
SELECT ALL 20 + col1 FROM tab2
----
37
51
79

query I rowsort
SELECT ALL - col1 + col1 * - col1 AS col2 FROM tab0 cor0
----
-7482
-8372
-9506

query I rowsort
SELECT - col0 + + col0 + - col2 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - col1 * col0 * 17 AS col2 FROM tab0 cor0
----
-137683
-35088
-57715

query I rowsort
SELECT ALL + + col2 + col2 * cor0.col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2015
SELECT ALL + + col1 * - CAST( - 8 AS SIGNED ) + col0 * + 82 AS col0 FROM tab0 AS cor0
----
2656
3646
8026

skipif mysql # not compatible
query I rowsort label-2015
SELECT ALL + + col1 * - CAST ( - 8 AS INTEGER ) + col0 * + 82 AS col0 FROM tab0 AS cor0
----
2656
3646
8026

query I rowsort
SELECT - + col1 - 64 * - 24 AS col0 FROM tab0 AS cor0
----
1439
1445
1450

query I rowsort
SELECT + 52 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT DISTINCT 22 AS col0 FROM tab2, tab0 AS cor0
----
22

query I rowsort
SELECT col0 * + 30 AS col1 FROM tab1
----
1920
2400
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2020
SELECT DISTINCT + col0 DIV col2 + + col0 AS col2 FROM tab1 AS cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-2020
SELECT DISTINCT + col0 / col2 + + col0 AS col2 FROM tab1 AS cor0
----
3
65
80

query I rowsort
SELECT DISTINCT 93 + col2 FROM tab0 AS cor0
----
126
175
94

query I rowsort
SELECT ALL + cor0.col0 * + col1 + col0 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 37 + col0 col0 FROM tab1 AS cor0
----
-306
-401
-959

query I rowsort
SELECT + 50 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT + col1 + 28 * col0 FROM tab1
----
110
1802
2253

onlyif mysql # use DIV operator for integer division
query I rowsort label-2026
SELECT ALL col2 + 12 * col0 DIV + col0 AS col2 FROM tab0
----
13
45
94

skipif mysql # not compatible
query I rowsort label-2026
SELECT ALL col2 + 12 * col0 / + col0 AS col2 FROM tab0
----
13
45
94

query I rowsort
SELECT col0 + + 97 * col0 AS col0 FROM tab1
----
294
6272
7840

query I rowsort
SELECT ALL + col1 + - 46 FROM tab2
----
-15
-29
13

query I rowsort
SELECT DISTINCT col0 + - 56 + - 66 * - col1 AS col0 FROM tab2
----
1145
1997
3916

query I rowsort
SELECT - col1 + + 94 + tab0.col2 * col0 FROM tab0
----
32
7301
800

query I rowsort
SELECT + - col1 * + cor0.col2 + col2 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2032
SELECT + + CAST( + col1 AS SIGNED ) * - cor0.col2 - CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2032
SELECT + + CAST ( + col1 AS INTEGER ) * - cor0.col2 - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2033
SELECT - CAST( - 29 AS SIGNED ) FROM tab2 cor0
----
29
29
29

skipif mysql # not compatible
query I rowsort label-2033
SELECT - CAST ( - 29 AS INTEGER ) FROM tab2 cor0
----
29
29
29

query I rowsort
SELECT + 80 * cor0.col1 + col1 AS col0 FROM tab2 AS cor0
----
1377
2511
4779

query I rowsort
SELECT DISTINCT + 84 + - col2 AS col2 FROM tab0 AS cor0
----
2
51
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2036
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col2 + + col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2036
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col2 + + col0 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2037
SELECT ( col1 ) + col1 DIV + 1 FROM tab2 AS cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-2037
SELECT ( col1 ) + col1 / + 1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL col0 + 11 AS col1 FROM tab2
----
18
89
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2039
SELECT ALL - CAST( NULL AS SIGNED ) + + col2 / + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2039
SELECT ALL - CAST ( NULL AS INTEGER ) + + col2 / + col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + 3 AS col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT ( - ( tab0.col0 ) ) * ( - col0 ) * + col1 FROM tab0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-2042
SELECT ALL ( col0 ) DIV tab0.col2 + col0 * col0 AS col0 FROM tab0
----
1260
576
7922

skipif mysql # not compatible
query I rowsort label-2042
SELECT ALL ( col0 ) / tab0.col2 + col0 * col0 AS col0 FROM tab0
----
1260
576
7922

query IIIIII rowsort
SELECT * FROM tab0, tab0 cor0 WHERE NULL >= ( NULL )
----

query I rowsort
SELECT ALL 29 + 88 FROM tab0 AS cor0
----
117
117
117

query I rowsort
SELECT 37 + cor0.col1 FROM tab0 AS cor0
----
123
128
134

query I rowsort
SELECT DISTINCT - col2 * + col2 + + col1 FROM tab2 AS cor0
----
-1427
-617
-698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col1 * - tab1.col0 col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 2afdaba7b80c700b7635230c4f8524be

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2048
SELECT ALL + CAST( col2 * + col2 AS SIGNED ) FROM tab2
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-2048
SELECT ALL + CAST ( col2 * + col2 AS INTEGER ) FROM tab2
----
1444
676
729

query I rowsort
SELECT ALL - + ( 18 ) * - col0 + + 12 AS col0 FROM tab0 AS cor0
----
1614
444
642

query I rowsort
SELECT ALL + 73 AS col1 FROM tab0
----
73
73
73

query I rowsort
SELECT DISTINCT ( - tab0.col0 ) * 97 FROM tab0
----
-2328
-3395
-8633

query I rowsort
SELECT DISTINCT ( + col2 ) * 80 AS col1 FROM tab2
----
2080
2160
3040

query I rowsort
SELECT - 54 + + col2 * col2 * + col1 FROM tab2
----
22545
24494
39830

query I rowsort
SELECT DISTINCT + - cor0.col2 * col1 + + col2 * col1 + - 24 AS col2 FROM tab2 cor0
----
-24

query I rowsort
SELECT ALL - col1 + + col2 * + 11 FROM tab2 cor0
----
227
266
401

query I rowsort
SELECT + - col0 * col1 + - col0 AS col2 FROM tab1 cor0
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2057
SELECT ALL + - col2 DIV - 8 - 28 AS col2 FROM tab1 AS cor0
----
-16
-21
-22

skipif mysql # not compatible
query I rowsort label-2057
SELECT ALL + - col2 / - 8 - 28 AS col2 FROM tab1 AS cor0
----
-16
-21
-22

query I rowsort
SELECT DISTINCT col1 + 21 * - 52 * - col2 AS col0 FROM tab0 AS cor0
----
1189
36122
89635

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - ( - 24 ) col2 FROM tab0 AS cor0
----
2136
576
840

query I rowsort
SELECT DISTINCT + col1 * 86 AS col0 FROM tab1 cor0
----
1118
2236
860

query I rowsort
SELECT DISTINCT - - col0 + - ( 7 ) FROM tab2 AS cor0
----
0
71
72

query I rowsort
SELECT ALL - col2 + ( - col0 ) + col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col2 * + col2 + col0 * col1 FROM tab1 AS cor0
----
-2609
-2838
-8176

query I rowsort
SELECT ALL - - col0 + 86 * 16 + + col0 * ( cor0.col1 ) FROM tab0 AS cor0
----
3464
4806
9564

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2065
SELECT - col1 * CAST( cor0.col0 AS SIGNED ) FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-2065
SELECT - col1 * CAST ( cor0.col0 AS INTEGER ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + + col2 - 33 FROM tab1 AS cor0
----
21
24
63

query I rowsort
SELECT cor0.col0 - 70 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4949cab01af444378bacfa60df08a809

query I rowsort
SELECT - - 38 + col2 AS col0 FROM tab1 AS cor0
----
134
92
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2069
SELECT + col0 * col0 + cor0.col0 DIV + col1 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-2069
SELECT + col0 * col0 + cor0.col0 / + col1 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * 62 + + col0 * + col2 col1 FROM tab2 AS cor0
----
1863
3640
5358

query I rowsort
SELECT - cor0.col1 * + 67 FROM tab0 AS cor0
----
-5762
-6097
-6499

query I rowsort
SELECT col2 * + 78 AS col2 FROM tab1 AS cor0
----
4212
4446
7488

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT 49 * + col0 AS col0 FROM tab1
----
147
3136
3920

query I rowsort
SELECT + 66 + + 46 FROM tab0 AS cor0
----
112
112
112

query I rowsort
SELECT ALL + ( col0 ) + col0 * + col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT + ( 91 ) FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT + col0 + 63 FROM tab0
----
152
87
98

query I rowsort
SELECT col2 + + 13 AS col2 FROM tab2
----
39
40
51

query I rowsort
SELECT ALL - cor1.col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT ALL - 27 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2082
SELECT DISTINCT CAST( - 97 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-97

skipif mysql # not compatible
query I rowsort label-2082
SELECT DISTINCT CAST ( - 97 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2083
SELECT DISTINCT + ( ( col0 ) ) DIV col1 + col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2083
SELECT DISTINCT + ( ( col0 ) ) / col1 + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL 28 * - 15 + - col0 FROM tab0 AS cor0
----
-444
-455
-509

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2085
SELECT ALL + + CAST( NULL AS SIGNED ) + 20 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2085
SELECT ALL + + CAST ( NULL AS INTEGER ) + 20 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 97 FROM tab0, tab0 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT DISTINCT cor0.col1 * + cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - + col2 + + col0 * + ( 35 ) AS col2 FROM tab1 AS cor0
----
2183
2704
51

query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) + 17 FROM tab0 cor0
----
-16
-65
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 80 * col0 - ( col2 ) * col1 col2 FROM tab1 AS cor0
----
-1644
-5690
-7648

query I rowsort
SELECT ALL + + cor0.col1 * cor0.col0 * - 14 FROM tab0 AS cor0
----
-113386
-28896
-47530

query I rowsort
SELECT - 34 * col1 FROM tab1 AS cor0
----
-340
-442
-884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 91 col0 FROM tab2, tab1 AS cor0
----
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 76 col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT tab0.col0 - tab0.col1 AS col2 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT + 63 * cor0.col1 FROM tab2 AS cor0
----
1071
1953
3717

query I rowsort
SELECT + 82 * col1 FROM tab0 cor0
----
7052
7462
7954

onlyif mysql # use DIV operator for integer division
query I rowsort label-2098
SELECT col1 DIV - col1 + - 10 + - col0 FROM tab0 AS cor0
----
-100
-35
-46

skipif mysql # not compatible
query I rowsort label-2098
SELECT col1 / - col1 + - 10 + - col0 FROM tab0 AS cor0
----
-100
-35
-46

onlyif mysql # use DIV operator for integer division
query I rowsort label-2099
SELECT + + col1 * col2 + - col0 DIV col1 + + col2 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-3084
-6438
1242

skipif mysql # not compatible
query I rowsort label-2099
SELECT + + col1 * col2 + - col0 / col1 + + col2 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-3084
-6438
1242

query I rowsort
SELECT col2 * ( - 74 ) FROM tab0 AS cor0
----
-2442
-6068
-74

query I rowsort
SELECT - - col2 + + 67 * - col1 FROM tab1 AS cor0
----
-1688
-613
-775

query I rowsort
SELECT ALL - 35 * col0 FROM tab2 AS cor0
----
-245
-2730
-2765

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 34 col2 FROM tab1 AS cor0
----
-34
-34
-34

query I rowsort
SELECT - 86 * col0 + + col2 FROM tab2 AS cor0
----
-575
-6682
-6756

query I rowsort
SELECT ALL + 4 * - 98 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 4a0de0ed35cc7f5eea7e889244e65332

query I rowsort
SELECT + cor0.col0 * + col2 + - col1 AS col0 FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-2107
SELECT col1 + col2 DIV + col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-2107
SELECT col1 + col2 / + col2 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-2108
SELECT + col1 + - col1 - + col0 DIV - col0 AS col0 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2108
SELECT + col1 + - col1 - + col0 / - col0 AS col0 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT ALL col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

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-2111
SELECT ALL + cor0.col1 DIV + col0 + col2 AS col2 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-2111
SELECT ALL + cor0.col1 / + col0 + col2 AS col2 FROM tab1 AS cor0
----
57
62
96

query I rowsort
SELECT DISTINCT + col0 * + col2 - + col0 * - col1 FROM tab0 cor0
----
15397
2856
3430

query I rowsort
SELECT ALL cor0.col1 * col2 + col2 * - col2 + col0 FROM tab2 AS cor0
----
-719
115
936

onlyif mysql # use DIV operator for integer division
query I rowsort label-2114
SELECT + cor0.col2 + + col2 DIV 68 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2114
SELECT + cor0.col2 + + col2 / 68 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL + col1 + + 65 AS col2 FROM tab1 AS cor0
----
75
78
91

query I rowsort
SELECT + col2 + col1 + col0 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
107
6169
6296

query I rowsort
SELECT + cor0.col2 * 55 FROM tab1 AS cor0
----
2970
3135
5280

query I rowsort
SELECT - col2 + ( - col1 ) AS col0 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT col2 - col1 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT col2 + - 89 AS col0 FROM tab2 AS cor0
----
-51
-62
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-2121
SELECT + ( col1 ) DIV - col2 AS col0 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2121
SELECT + ( col1 ) / - col2 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL ( + 41 * + col2 + - ( col2 ) ) FROM tab1
----
2160
2280
3840

query I rowsort
SELECT DISTINCT + 88 AS col0 FROM tab2, tab2 AS cor0
----
88

query I rowsort
SELECT + + ( 17 ) FROM tab2 AS cor0
----
17
17
17

query I rowsort
SELECT DISTINCT col0 + + col1 * + col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL + - col2 + ( + col1 ) FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - 35 + + cor0.col2 * - 58 FROM tab0, tab0 AS cor0
----
9 values hashing to 0122cf79164ea49fc96909153fb79b91

query I rowsort
SELECT ALL - + col0 * + 59 + + col1 + col2 AS col1 FROM tab2 AS cor0
----
-355
-4517
-4606

query I rowsort
SELECT - col1 + + col1 * - ( 54 + + col2 ) FROM tab1 AS cor0
----
-1120
-1963
-2834

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col0 ) * + ( col0 ) + + col1 col2 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT 71 + + col2 FROM tab1 cor0
----
125
128
167

query I rowsort
SELECT DISTINCT col1 * - col0 + + col0 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - + 30 FROM tab1 AS cor0
----
-30
-30
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2135
SELECT + - 89 DIV - col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2135
SELECT + - 89 / - col2 FROM tab1 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2136
SELECT DISTINCT + 45 DIV cor0.col2 + - 40 * + 43 AS col2 FROM tab1 cor0
----
-1720

skipif mysql # not compatible
query I rowsort label-2136
SELECT DISTINCT + 45 / cor0.col2 + - 40 * + 43 AS col2 FROM tab1 cor0
----
-1720

onlyif mysql # use DIV operator for integer division
query I rowsort label-2137
SELECT DISTINCT + - col1 * cor0.col1 DIV 50 AS col1 FROM tab1 AS cor0
----
-13
-2
-3

skipif mysql # not compatible
query I rowsort label-2137
SELECT DISTINCT + - col1 * cor0.col1 / 50 AS col1 FROM tab1 AS cor0
----
-13
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col2 ) + + col1 - col0 col1 FROM tab0 cor0
----
63
84
95

query I rowsort
SELECT DISTINCT - col0 * - cor0.col0 + col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT - col1 * - col1 + 68 AS col2 FROM tab1 AS cor0
----
168
237
744

query I rowsort
SELECT 0 - col1 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - 54 * col2 AS col0 FROM tab2
----
-1404
-1458
-2052

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 25 col0 FROM tab0 AS cor0
----
25
25
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( col2 ) * col2 * ( col0 ) col0 FROM tab1 AS cor0
----
207936
737280
8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-2145
SELECT DISTINCT + - 17 * col0 DIV - col0 FROM tab1 AS cor0
----
17

skipif mysql # not compatible
query I rowsort label-2145
SELECT DISTINCT + - 17 * col0 / - col0 FROM tab1 AS cor0
----
17

query I rowsort
SELECT DISTINCT + 34 + - tab2.col0 FROM tab2, tab2 cor0, tab0, tab1 AS cor1
----
-44
-45
27

query I rowsort
SELECT 31 * + col2 + col2 FROM tab0
----
1056
2624
32

query I rowsort
SELECT DISTINCT - ( + col0 ) * 43 AS col0 FROM tab2 AS cor0
----
-301
-3354
-3397

query I rowsort
SELECT ALL + + 59 + + col1 AS col0 FROM tab0 AS cor0
----
145
150
156

query I rowsort
SELECT ALL 41 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2151
SELECT ALL tab1.col2 * + col1 - - CAST( 56 AS SIGNED ) FROM tab1
----
1304
1460
626

skipif mysql # not compatible
query I rowsort label-2151
SELECT ALL tab1.col2 * + col1 - - CAST ( 56 AS INTEGER ) FROM tab1
----
1304
1460
626

query I rowsort
SELECT 13 - col2 FROM tab0
----
-20
-69
12

query I rowsort
SELECT - col2 + - col2 * + col0 * + 8 AS col1 FROM tab2
----
-1539
-16250
-24054

query I rowsort
SELECT col0 + col2 + - col0 AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT + col2 * - cor0.col2 + 46 AS col2 FROM tab2 AS cor0
----
-1398
-630
-683

query I rowsort
SELECT DISTINCT - col1 - col0 * + 40 * col0 FROM tab2
----
-1991
-243419
-249657

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 - + col1 * - 15 col0 FROM tab1 AS cor0
----
214
275
393

onlyif mysql # use DIV operator for integer division
query I rowsort label-2158
SELECT DISTINCT 6 * col1 DIV col0 + - 13 FROM tab2
----
-12
-9
13

skipif mysql # not compatible
query I rowsort label-2158
SELECT DISTINCT 6 * col1 / col0 + - 13 FROM tab2
----
-12
-9
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-2159
SELECT ALL 36 + tab2.col0 DIV + 88 + col1 FROM tab2
----
53
67
95

skipif mysql # not compatible
query I rowsort label-2159
SELECT ALL 36 + tab2.col0 / + 88 + col1 FROM tab2
----
53
67
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2160
SELECT DISTINCT - - CAST( ( - col2 ) AS SIGNED ) * ( + col1 ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-2160
SELECT DISTINCT - - CAST ( ( - col2 ) AS INTEGER ) * ( + col1 ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - ( col2 ) * + col0 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + ( + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2163
SELECT - CAST( - 95 AS SIGNED ) * col0 + col2 FROM tab2 AS cor0
----
692
7436
7543

skipif mysql # not compatible
query I rowsort label-2163
SELECT - CAST ( - 95 AS INTEGER ) * col0 + col2 FROM tab2 AS cor0
----
692
7436
7543

query I rowsort
SELECT ALL 68 * - cor0.col0 + col1 FROM tab0 AS cor0
----
-1546
-2283
-5961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 19 col1 FROM tab1
----
115
73
76

query I rowsort
SELECT DISTINCT - col1 + 82 FROM tab0
----
-15
-4
-9

query I rowsort
SELECT - 18 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

onlyif mysql # use DIV operator for integer division
query I rowsort label-2168
SELECT + 31 + + col0 + cor0.col0 DIV - col1 col1 FROM tab2 AS cor0
----
106
108
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2168
SELECT + 31 + + col0 + cor0.col0 / - col1 col1 FROM tab2 AS cor0
----
106
108
38

query I rowsort
SELECT ALL - ( cor0.col0 ) * - col0 * + 78 AS col1 FROM tab0 AS cor0
----
44928
617838
95550

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2170
SELECT CAST( - ( col1 ) AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-2170
SELECT CAST ( - ( col1 ) AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + + 35 * - col0 FROM tab0 AS cor0
----
-1225
-3115
-840

query I rowsort
SELECT ALL - 85 + 81 FROM tab2 AS cor0
----
-4
-4
-4

query I rowsort
SELECT ALL - - ( cor0.col0 ) + cor0.col1 AS col1 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + 17 ) * col2 col0 FROM tab1 AS cor0
----
1632
918
969

query I rowsort
SELECT col1 + + ( + col0 ) * col0 * - col1 AS col2 FROM tab1
----
-208
-40950
-83187

query I rowsort
SELECT DISTINCT - col0 + - col0 + col0 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + ( + col1 ) + col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2178
SELECT ALL - CAST( 24 AS SIGNED ) * - col2 + col0 AS col2 FROM tab2 cor0
----
655
702
991

skipif mysql # not compatible
query I rowsort label-2178
SELECT ALL - CAST ( 24 AS INTEGER ) * - col2 + col0 AS col2 FROM tab2 cor0
----
655
702
991

onlyif mysql # use DIV operator for integer division
query I rowsort label-2179
SELECT ALL - + 13 DIV col1 + - col1 - cor0.col1 FROM tab2 AS cor0
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-2179
SELECT ALL - + 13 / col1 + - col1 - cor0.col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + - 76 + col1 * + col1 FROM tab2 AS cor0
----
213
3405
885

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2181
SELECT ALL + + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2181
SELECT ALL + + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 84 * - col2 + col2 - ( + col1 ) AS col0 FROM tab0 AS cor0
----
-12
2719
6879

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * cor0.col2 + cor0.col2 col0 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT 69 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT ALL - col1 * - ( - ( col0 ) ) * col2 AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT col1 + - col1 * + 61 FROM tab0 cor0
----
-5160
-5460
-5820

query I rowsort
SELECT - col0 * 37 AS col1 FROM tab1 AS cor0
----
-111
-2368
-2960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT + 47 - - col2 AS col2 FROM tab1 cor0
----
101
104
143

query I rowsort
SELECT - cor0.col0 - col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + 51 + - col2 FROM tab2 cor0
----
13
24
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2192
SELECT - CAST( NULL AS DECIMAL ) * - 39 + - col0 - 33 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2192
SELECT - CAST ( NULL AS REAL ) * - 39 + - col0 - 33 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + ( col1 ) * col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT - col0 + 22 FROM tab1 AS cor0
----
-42
-58
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * col2 + cor0.col0 * - ( - cor0.col0 * ( col1 ) ) col2 FROM tab0 AS cor0
----
118860
50328
728109

query I rowsort
SELECT DISTINCT + 18 + col2 FROM tab2 AS cor0
----
44
45
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - cor0.col2 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col1 + cor0.col0 * + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + ( + col0 ) * + col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT col0 * + col0 + ( col0 ) FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT - + 44 AS col2 FROM tab0 AS cor0
----
-44
-44
-44

onlyif mysql # use DIV operator for integer division
query I rowsort label-2202
SELECT col1 * - cor0.col2 * - col0 + - 10 DIV col2 FROM tab0 AS cor0
----
3385
664118
68112

skipif mysql # not compatible
query I rowsort label-2202
SELECT col1 * - cor0.col2 * - col0 + - 10 / col2 FROM tab0 AS cor0
----
3385
664118
68112

query I rowsort
SELECT DISTINCT ( col2 ) + - col1 * 63 AS col0 FROM tab2
----
-1033
-1926
-3691

query I rowsort
SELECT DISTINCT ( col2 ) + - col1 AS col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT + ( col1 ) + + col1 * + col1 * col0 AS col0 FROM tab1 AS cor0
----
13533
2054
6410

query I rowsort
SELECT ALL + cor0.col1 * 2 AS col1 FROM tab0, tab1 cor0, tab0 cor1, tab2 AS cor2
----
81 values hashing to 13abe7c65c319050638dc134e1147927

query I rowsort
SELECT - + 30 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2208
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2208
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT - + cor0.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + - 48 - cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-126
-127
-55

query I rowsort
SELECT + - col2 * col0 * col0 + col0 * - col1 FROM tab2 AS cor0
----
-1540
-162786
-238501

query I rowsort
SELECT - col1 * + 19 + col2 FROM tab2 AS cor0
----
-1095
-285
-562

query I rowsort
SELECT - col0 * ( cor0.col1 ) * + col0 + - ( col2 + cor0.col2 ) * - col2 AS col0 FROM tab0 AS cor0
----
-118823
-47358
-707363

query I rowsort
SELECT - + col2 * 69 + - col2 * col1 AS col1 FROM tab2 AS cor0
----
-2700
-3268
-3328

query I rowsort
SELECT 79 * + tab1.col1 FROM tab1
----
1027
2054
790

query I rowsort
SELECT + + col2 + col1 * ( + col0 ) FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-2217
SELECT DISTINCT cor0.col0 DIV col0 AS col0 FROM tab2 cor0
----
1

skipif mysql # not compatible
query I rowsort label-2217
SELECT DISTINCT cor0.col0 / col0 AS col0 FROM tab2 cor0
----
1

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT ALL - 63 AS col2 FROM tab1 cor0
----
-63
-63
-63

query I rowsort
SELECT - + cor1.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT + tab0.col2 AS col1 FROM tab0, tab2 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2223
SELECT 32 * 2 DIV - tab1.col1 AS col2 FROM tab1
----
-2
-4
-6

skipif mysql # not compatible
query I rowsort label-2223
SELECT 32 * 2 / - tab1.col1 AS col2 FROM tab1
----
-2
-4
-6

query I rowsort
SELECT ALL + 39 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT 23 + + col1 AS col2 FROM tab2 cor0
----
40
54
82

query I rowsort
SELECT DISTINCT + + cor0.col1 AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT tab2.col1 - - col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT + 7 FROM tab2, tab1 cor0, tab2 AS cor1
----
7

query I rowsort
SELECT - + col2 * - cor0.col2 + + col0 * - 32 FROM tab1 AS cor0
----
1201
2820
6656

query I rowsort
SELECT - cor0.col0 * - col0 * + 57 FROM tab2 AS cor0
----
2793
346788
355737

query I rowsort
SELECT DISTINCT + col0 - col0 * cor0.col0 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT ALL + ( col2 ) * + col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 12 + col0 * + col1 FROM tab0 cor0
----
2076
3407
8111

query I rowsort
SELECT DISTINCT 4 AS col2 FROM tab2 AS cor0
----
4

query I rowsort
SELECT ALL + - 31 + col2 FROM tab0 AS cor0
----
-30
2
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-2236
SELECT + + ( col2 ) * col2 DIV col0 AS col2 FROM tab1 AS cor0
----
115
50
972

skipif mysql # not compatible
query I rowsort label-2236
SELECT + + ( col2 ) * col2 / col0 AS col2 FROM tab1 AS cor0
----
115
50
972

query I rowsort
SELECT - - col2 * col0 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + cor0.col2 * ( col1 ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col2 + + col1 * - col0 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-2240
SELECT ALL + col1 DIV + col0 + col1 AS col1 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-2240
SELECT ALL + col1 / + col0 + col1 AS col1 FROM tab1 AS cor0
----
10
13
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2241
SELECT ALL - CAST( 54 AS SIGNED ) * + col1 - cor0.col0 FROM tab1 cor0
----
-1407
-604
-782

skipif mysql # not compatible
query I rowsort label-2241
SELECT ALL - CAST ( 54 AS INTEGER ) * + col1 - cor0.col0 FROM tab1 cor0
----
-1407
-604
-782

query I rowsort
SELECT - 56 * cor0.col1 FROM tab1 AS cor0
----
-1456
-560
-728

query I rowsort
SELECT DISTINCT + col1 * + col1 AS col2 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT + col0 * cor0.col2 + col1 AS col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-2245
SELECT ALL - + cor0.col2 + 20 * col1 + - ( + cor0.col2 ) DIV + col1 col2 FROM tab0 AS cor0
----
1687
1738
1939

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2245
SELECT ALL - + cor0.col2 + 20 * col1 + - ( + cor0.col2 ) / + col1 col2 FROM tab0 AS cor0
----
1687
1738
1939

query I rowsort
SELECT ALL + col1 * + col2 * col1 + col1 AS col2 FROM tab0 cor0
----
244154
679133
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2247
SELECT DISTINCT - col0 + cor0.col0 DIV col1 FROM tab1 AS cor0
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-2247
SELECT DISTINCT - col0 + cor0.col0 / col1 FROM tab1 AS cor0
----
-3
-58
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-2248
SELECT DISTINCT + + 89 DIV col2 + - col1 AS col1 FROM tab0 AS cor0
----
-8
-84
-90

skipif mysql # not compatible
query I rowsort label-2248
SELECT DISTINCT + + 89 / col2 + - col1 AS col1 FROM tab0 AS cor0
----
-8
-84
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) * + col0 + col1 col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL - col0 * + 14 FROM tab1 cor0
----
-1120
-42
-896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 75 - + col0 col2 FROM tab0 AS cor0
----
-14
40
51

query I rowsort
SELECT DISTINCT + 68 * - ( col2 * - 39 ) FROM tab1 AS cor0
----
143208
151164
254592

query I rowsort
SELECT ALL - + 99 * col2 + + col2 AS col2 FROM tab1 AS cor0
----
-5292
-5586
-9408

query I rowsort
SELECT + col2 + tab2.col1 * - col1 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT - col2 * - ( 63 ) FROM tab0 AS cor0
----
2079
5166
63

query I rowsort
SELECT DISTINCT + + col0 * 64 AS col1 FROM tab0 AS cor0
----
1536
2240
5696

query I rowsort
SELECT 12 + col2 FROM tab0 AS cor0
----
13
45
94

query I rowsort
SELECT - - col2 + + ( - col1 ) * - col1 AS col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT + col2 * - ( - 71 ) + + col1 FROM tab0
----
168
2429
5913

query I rowsort
SELECT DISTINCT col1 * 92 - + col0 AS col0 FROM tab0 cor0
----
7888
8283
8889

onlyif mysql # use DIV operator for integer division
query I rowsort label-2261
SELECT ALL + + col1 DIV - 96 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2261
SELECT ALL + + col1 / - 96 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 + + ( 46 + + col2 ) AS col2 FROM tab2 AS cor0
----
-6
5
66

query I rowsort
SELECT ALL col2 * 71 FROM tab2 AS cor0
----
1846
1917
2698

query I rowsort
SELECT - 81 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab2, tab1 cor1, tab0 cor2
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT ALL col2 * + 78 FROM tab2 AS cor0
----
2028
2106
2964

query I rowsort
SELECT col1 + + ( + ( - col1 ) ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * - 58 AS col2 FROM tab0 cor0
----
-1914
-4756
-58

query I rowsort
SELECT DISTINCT + col2 * ( + col1 ) * + col1 AS col0 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT + - col2 + - ( col1 ) * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT ALL col1 * - ( - col0 ) AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT - col0 + 76 AS col2 FROM tab0 cor0
----
-13
41
52

query I rowsort
SELECT + - col2 + - col0 * + 94 * col0 AS col1 FROM tab2 cor0
----
-4633
-571922
-586692

query I rowsort
SELECT ( 60 ) * + col1 FROM tab2 cor0
----
1020
1860
3540

query I rowsort
SELECT 61 + cor0.col1 * cor0.col0 FROM tab2 AS cor0
----
1404
278
4663

query I rowsort
SELECT 84 * cor0.col2 AS col2 FROM tab2 AS cor0
----
2184
2268
3192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col1 ) + col2 col2 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col1 * - col1 col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT ( - col2 ) + col0 + col0 * col1 FROM tab1 AS cor0
----
1024
27
647

query I rowsort
SELECT DISTINCT - col1 + + col1 * cor0.col2 * 18 FROM tab1 AS cor0
----
10250
22451
25246

query I rowsort
SELECT - + col2 * + col1 + - col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL + 71 * + col2 AS col1 FROM tab1 cor0
----
3834
4047
6816

query I rowsort
SELECT + col1 + col2 * - 47 + + col0 AS col2 FROM tab1 AS cor0
----
-2509
-2605
-4419

onlyif mysql # use DIV operator for integer division
query I rowsort label-2284
SELECT - col2 DIV CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2284
SELECT - col2 / CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + + 88 + col2 AS col1 FROM tab1 AS cor0
----
145
209
264

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2286
SELECT DISTINCT col1 + - col0 + CAST( col2 AS SIGNED ) * col0 * - col2 AS col2 FROM tab1
----
-207990
-737347
-8725

skipif mysql # not compatible
query I rowsort label-2286
SELECT DISTINCT col1 + - col0 + CAST ( col2 AS INTEGER ) * col0 * - col2 AS col2 FROM tab1
----
-207990
-737347
-8725

query I rowsort
SELECT + col0 * - tab0.col2 AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT - col2 * + 95 AS col0 FROM tab2 AS cor0
----
-2470
-2565
-3610

query I rowsort
SELECT ALL 87 + - col1 * ( + 20 ) FROM tab1
----
-113
-173
-433

query I rowsort
SELECT ALL 79 * - col2 FROM tab1
----
-4266
-4503
-7584

query I rowsort
SELECT DISTINCT col0 + - col1 * ( + 25 ) * - col2 FROM tab1
----
14314
31280
35103

onlyif mysql # use DIV operator for integer division
query I rowsort label-2292
SELECT ALL col1 * col2 DIV + 8 + 43 + + col0 AS col2 FROM tab2
----
154
202
312

skipif mysql # not compatible
query I rowsort label-2292
SELECT ALL col1 * col2 / + 8 + 43 + + col0 AS col2 FROM tab2
----
154
202
312

query I rowsort
SELECT - 38 + tab2.col1 FROM tab2
----
-21
-7
21

query I rowsort
SELECT 66 AS col0 FROM tab0 AS cor0
----
66
66
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2295
SELECT + col0 DIV col2 + + col2 DIV + cor0.col0 FROM tab1 AS cor0
----
1
1
18

skipif mysql # not compatible
query I rowsort label-2295
SELECT + col0 / col2 + + col2 / + cor0.col0 FROM tab1 AS cor0
----
1
1
18

query I rowsort
SELECT + cor1.col0 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - 49 AS col0 FROM tab0 cor0
----
-49
-49
-49

query I rowsort
SELECT DISTINCT - col0 + + ( + col0 ) AS col0 FROM tab1
----
0

query I rowsort
SELECT ALL col2 * 59 AS col2 FROM tab0
----
1947
4838
59

query I rowsort
SELECT DISTINCT - 36 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-2301
SELECT DISTINCT - - col0 DIV cor0.col0 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2301
SELECT DISTINCT - - col0 / cor0.col0 FROM tab2 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - 24 col2 FROM tab0 AS cor0
----
-1968
-24
-792

query I rowsort
SELECT 62 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT col2 * + 54 AS col0 FROM tab0
----
1782
4428
54

query I rowsort
SELECT - col1 * + col1 + col2 AS col1 FROM tab2 AS cor0
----
-251
-3455
-934

onlyif mysql # use DIV operator for integer division
query I rowsort label-2306
SELECT + + col0 DIV col2 + col2 FROM tab0 AS cor0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-2306
SELECT + + col0 / col2 + col2 FROM tab0 AS cor0
----
33
36
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2307
SELECT - CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2307
SELECT - CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 72 * 63 AS col1 FROM tab0
----
-4536
-4536
-4536

query I rowsort
SELECT 8 + ( col2 ) * + 67 FROM tab0 AS cor0
----
2219
5502
75

query I rowsort
SELECT ALL - ( cor0.col2 ) * col1 * 51 FROM tab2 AS cor0
----
-32946
-42687
-78234

query I rowsort
SELECT 74 * 43 AS col2 FROM tab0 AS cor0
----
3182
3182
3182

query I rowsort
SELECT + + col2 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + ( ( + cor0.col1 ) ) * 67 AS col1 FROM tab2 cor0
----
1139
2077
3953

query I rowsort
SELECT - 36 FROM tab2 cor0
----
-36
-36
-36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2315
SELECT CAST( col0 AS SIGNED ) col0 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2315
SELECT CAST ( col0 AS INTEGER ) col0 FROM tab2
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2316
SELECT DISTINCT - 17 * col1 + col0 * + CAST( NULL AS SIGNED ) * col1 + col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2316
SELECT DISTINCT - 17 * col1 + col0 * + CAST ( NULL AS INTEGER ) * col1 + col2 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + col1 + 47 FROM tab1
----
57
60
73

query I rowsort
SELECT ( col0 ) * col0 - + 95 AS col2 FROM tab2
----
-46
5989
6146

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 43 col2 FROM tab2 AS cor0
----
-1118
-1161
-1634

query I rowsort
SELECT DISTINCT + - 36 + col2 AS col1 FROM tab0 AS cor0
----
-3
-35
46

query I rowsort
SELECT col0 + col1 + col0 FROM tab2 cor0
----
175
215
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2322
SELECT - + CAST( NULL AS DECIMAL ) + + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2322
SELECT - + CAST ( NULL AS REAL ) + + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + col2 * + col0 + 66 FROM tab0 AS cor0
----
198
7455
944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2324
SELECT cor0.col2 + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2324
SELECT cor0.col2 + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 89 + col0 * col0 + 32 AS col0 FROM tab2 cor0
----
170
6205
6362

query I rowsort
SELECT ALL - col0 + + col1 + col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + col0 * + col1 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + - col1 * + col2 + - 71 FROM tab2 AS cor0
----
-1605
-717
-908

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col0 + tab2.col2 * tab2.col0 col1 FROM tab2, tab1 cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + cor0.col2 - - col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - col1 + col2 * col0 AS col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL - col1 * col1 + + ( col1 ) AS col0 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL + 98 + col0 * - col0 * + cor0.col0 AS col0 FROM tab2 cor0
----
-245
-474454
-492941

query I rowsort
SELECT DISTINCT + cor0.col1 + + col2 * + 63 AS col2 FROM tab1 cor0
----
3428
3601
6061

query I rowsort
SELECT - + cor0.col0 * + col2 * - 50 AS col0 FROM tab1 AS cor0
----
182400
384000
8100

query I rowsort
SELECT + cor0.col1 + 40 * - col0 FROM tab2 AS cor0
----
-249
-3061
-3143

query I rowsort
SELECT DISTINCT + 74 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
74

query I rowsort
SELECT - + cor1.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT ALL + 2 * - col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT 56 * 64 - + cor0.col2 AS col0 FROM tab0 AS cor0
----
3502
3551
3583

query I rowsort
SELECT cor1.col2 FROM tab0 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL + - col1 * + col2 + + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT - cor0.col1 * + 50 + + col1 + + col2 FROM tab1 AS cor0
----
-1220
-433
-541

query I rowsort
SELECT cor0.col2 + - 46 AS col2 FROM tab0 AS cor0
----
-13
-45
36

query I rowsort
SELECT ALL - col1 + ( + col2 ) * col0 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2346
SELECT cor0.col0 / - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2346
SELECT cor0.col0 / - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor1.col1 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + - col1 col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT col0 * - 69 + col2 FROM tab0 AS cor0
----
-1623
-2414
-6059

query I rowsort
SELECT - 19 * + tab1.col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 35a6547ab14b6da2500ae09e2264f089

query I rowsort
SELECT ALL - - col1 * + ( - col0 * col2 ) AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-2352
SELECT ALL + col0 DIV + col2 + col0 AS col0 FROM tab1 cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-2352
SELECT ALL + col0 / + col2 + col0 AS col0 FROM tab1 cor0
----
3
65
80

query I rowsort
SELECT DISTINCT + + col0 + + col1 AS col2 FROM tab1 cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - + col2 * cor0.col1 col1 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2355
SELECT ALL - col2 * col0 / CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2355
SELECT ALL - col2 * col0 / CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * - col0 + + col1 * col0 FROM tab0
----
16020
2640
4620

query I rowsort
SELECT col2 * col2 + ( + col0 ) FROM tab2 AS cor0
----
1523
736
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 5 - + cor0.col0 col1 FROM tab0 AS cor0
----
-29
-40
-94

query I rowsort
SELECT - cor0.col1 * - col0 + 30 FROM tab0 AS cor0
----
2094
3425
8129

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2360
SELECT DISTINCT cor0.col1 - - col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2360
SELECT DISTINCT cor0.col1 - - col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2361
SELECT - col2 DIV col2 + + col1 * - col2 FROM tab0 AS cor0
----
-2839
-7463
-98

skipif mysql # not compatible
query I rowsort label-2361
SELECT - col2 / col2 + + col1 * - col2 FROM tab0 AS cor0
----
-2839
-7463
-98

query I rowsort
SELECT DISTINCT + 81 * + col0 - - cor0.col0 FROM tab0 AS cor0
----
1968
2870
7298

query I rowsort
SELECT ALL - - 37 * col0 AS col1 FROM tab0 cor0
----
1295
3293
888

query I rowsort
SELECT DISTINCT - col1 + + col0 + - col1 AS col2 FROM tab0
----
-148
-159
-93

query I rowsort
SELECT + col1 * - col0 * - col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT - tab0.col0 * - col0 AS col0 FROM tab0 WHERE col1 + - col2 NOT BETWEEN NULL AND ( col2 )
----
1225
576

query I rowsort
SELECT - col1 * tab0.col2 + + tab0.col2 * tab0.col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT tab2.col2 * + tab2.col0 + col0 * + col0 + col0 AS col2 FROM tab2
----
245
8190
9322

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col2 + + col1 col2 FROM tab0
----
-2752
-7371
0

query III rowsort
SELECT * FROM tab0 WHERE NOT + col2 * col0 - col2 <> col1
----

query I rowsort
SELECT ALL - tab0.col2 * 41 + 26 * tab0.col2 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 21bb369fcca3759468c13c9b8474545b

query I rowsort
SELECT + cor1.col2 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + col2 * + col0 + - col1 AS col0 FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-2374
SELECT - + col1 + col1 DIV cor0.col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2374
SELECT - + col1 + col1 / cor0.col1 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT 92 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
92

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
26
27
38

query I rowsort
SELECT ALL - col0 * tab0.col1 * ( + tab0.col0 * - col2 ) + + 12 * 43 AS col2 FROM tab0
----
119341
1635204
59107018

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2378
SELECT + 56 - col2 * CAST( NULL AS SIGNED ) * - 93 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2378
SELECT + 56 - col2 * CAST ( NULL AS INTEGER ) * - 93 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + + col0 * cor0.col0 FROM tab1 cor0
----
35
4106
6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-2380
SELECT DISTINCT + 20 * col0 + col1 DIV - col1 AS col1 FROM tab1
----
1279
1599
59

skipif mysql # not compatible
query I rowsort label-2380
SELECT DISTINCT + 20 * col0 + col1 / - col1 AS col1 FROM tab1
----
1279
1599
59

query I rowsort
SELECT ALL + col1 * + col0 + - col2 FROM tab2 cor0
----
1305
190
4576

query I rowsort
SELECT ALL - col2 + - ( - col0 ) AS col1 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2383
SELECT + col0 / + CAST( NULL AS DECIMAL ) + col2 col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2383
SELECT + col0 / + CAST ( NULL AS REAL ) + col2 col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT cor1.col1 AS col2 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # use DIV operator for integer division
query I rowsort label-2385
SELECT DISTINCT col2 * - col1 + 71 DIV col0 + + 99 AS col0 FROM tab2 AS cor0
----
-1435
-547
-728

skipif mysql # not compatible
query I rowsort label-2385
SELECT DISTINCT col2 * - col1 + 71 / col0 + + 99 AS col0 FROM tab2 AS cor0
----
-1435
-547
-728

query I rowsort
SELECT - cor0.col2 * + col2 + - col1 * col1 AS col2 FROM tab2 AS cor0
----
-1690
-1733
-4157

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 cor0, tab0 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to 5d94dfd9164033b5a92f743be8139ecc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2388
SELECT ALL col2 * - CAST( col0 AS SIGNED ) - + cor0.col0 col2 FROM tab1 cor0
----
-165
-3712
-7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2388
SELECT ALL col2 * - CAST ( col0 AS INTEGER ) - + cor0.col0 col2 FROM tab1 cor0
----
-165
-3712
-7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-2389
SELECT 47 * 47 DIV - tab2.col1 FROM tab2
----
-129
-37
-71

skipif mysql # not compatible
query I rowsort label-2389
SELECT 47 * 47 / - tab2.col1 FROM tab2
----
-129
-37
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-2390
SELECT col1 DIV 48 AS col0 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2390
SELECT col1 / 48 AS col0 FROM tab2
----
0
0
1

query I rowsort
SELECT col0 + col1 + - col1 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT + col2 * + 6 FROM tab1 AS cor0
----
324
342
576

query I rowsort
SELECT DISTINCT + 41 AS col0 FROM tab1 cor0
----
41

query I rowsort
SELECT + ( 97 ) FROM tab2 cor0
----
97
97
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 97 + + col1 col2 FROM tab2 AS cor0
----
-38
-66
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2396
SELECT - CAST( - col1 AS SIGNED ) FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2396
SELECT - CAST ( - col1 AS INTEGER ) FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT ALL + 50 * + col2 FROM tab0 cor0
----
1650
4100
50

query I rowsort
SELECT col1 + + col2 * + col1 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 58 * - cor0.col0 - 81 * - col2 * col1 col0 FROM tab1 AS cor0
----
105728
113898
49882

query I rowsort
SELECT + - col1 - col2 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2401
SELECT ALL + - cor0.col0 DIV + col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2401
SELECT ALL + - cor0.col0 / + col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT + 1 + cor0.col2 * - col0 FROM tab1 AS cor0
----
-161
-3647
-7679

query I rowsort
SELECT ALL + 47 * + col1 AS col0 FROM tab2 AS cor0
----
1457
2773
799

query I rowsort
SELECT + col0 + + cor0.col1 * - 79 FROM tab0 AS cor0
----
-6770
-7100
-7628

query I rowsort
SELECT col1 * - col2 + col0 * - ( + col1 ) FROM tab2
----
-1054
-1989
-6136

query I rowsort
SELECT ALL 89 - col2 AS col0 FROM tab0
----
56
7
88

query I rowsort
SELECT 71 + col0 FROM tab2 AS cor0
----
149
150
78

query I rowsort
SELECT + 38 + + col1 AS col1 FROM tab1 AS cor0
----
48
51
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col0 col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2410
SELECT ALL - 10 DIV - col0 + - col0 AS col2 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-2410
SELECT ALL - 10 / - col0 + - col0 AS col2 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - + col1 + + col0 * col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT + - col2 * col2 + col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT tab2.col1 * col1 * col0 FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-2414
SELECT DISTINCT col0 DIV col0 col2 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2414
SELECT DISTINCT col0 / col0 col2 FROM tab0
----
1

query I rowsort
SELECT ALL - ( col2 * - col0 ) + - col2 FROM tab1
----
108
3591
7584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2416
SELECT + CAST( NULL AS SIGNED ) * + col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2416
SELECT + CAST ( NULL AS INTEGER ) * + col2 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - col1 * - col1 + col1 AS col0 FROM tab0
----
244154
679133
9506

query I rowsort
SELECT + + col0 * - col2 + col1 AS col1 FROM tab2 cor0
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-2419
SELECT - col0 DIV col1 + - col0 * col0 FROM tab2 AS cor0
----
-49
-6085
-6245

skipif mysql # not compatible
query I rowsort label-2419
SELECT - col0 / col1 + - col0 * col0 FROM tab2 AS cor0
----
-49
-6085
-6245

query I rowsort
SELECT ALL + tab2.col2 * + 22 FROM tab2
----
572
594
836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col1 * - ( - tab2.col2 ) col0 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 24 col1 FROM tab1 AS cor0
----
24
24
24

query I rowsort
SELECT cor0.col0 * col1 - col1 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT ALL - cor0.col2 + col1 + col0 * + col2 FROM tab1 AS cor0
----
134
3601
7597

query I rowsort
SELECT ( + col1 ) + col2 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - 39 * col1 AS col1 FROM tab2 AS cor0
----
-1209
-2301
-663

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 47 + - cor0.col0 * col0 col1 FROM tab0 AS cor0
----
-1272
-623
-7968

onlyif mysql # use DIV operator for integer division
query I rowsort label-2428
SELECT col2 DIV cor0.col0 - col2 AS col2 FROM tab2 AS cor0
----
-24
-26
-38

skipif mysql # not compatible
query I rowsort label-2428
SELECT col2 / cor0.col0 - col2 AS col2 FROM tab2 AS cor0
----
-24
-26
-38

query I rowsort
SELECT col2 - - col2 * + col2 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-35904
-551286
0

query I rowsort
SELECT ALL tab1.col1 + + col0 AS col2 FROM tab1
----
29
74
93

query I rowsort
SELECT col1 AS col1 FROM tab1 WHERE NULL NOT BETWEEN NULL AND ( col1 * col2 + col1 )
----

query I rowsort
SELECT ALL col0 + + col0 + col1 AS col2 FROM tab0
----
134
167
269

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) IN ( + tab1.col0 )
----

query I rowsort
SELECT ALL col1 + col1 * col1 AS col0 FROM tab2
----
306
3540
992

query I rowsort
SELECT DISTINCT + col0 AS col0 FROM tab0 WHERE ( NULL ) IN ( + col0 )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE ( col2 ) NOT BETWEEN ( - col2 * col2 ) AND ( col0 )
----
7
31
27

query I rowsort
SELECT ALL col1 + - col1 + col1 FROM tab2
----
17
31
59

query I rowsort
SELECT + col1 * col2 FROM tab2 WHERE NULL NOT IN ( tab2.col1 + col0 )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL BETWEEN ( col2 ) AND NULL
----

query I rowsort
SELECT col0 * - col0 + + col2 - - col2 * + col0 FROM tab1
----
-391
1376
207

query I rowsort
SELECT ALL + col2 + - col2 * col0 + col1 AS col0 FROM tab2
----
-131
-1943
-2947

query I rowsort
SELECT - col0 + - col2 + col0 * - col2 AS col2 FROM tab0
----
-71
-7469
-849

query I rowsort
SELECT col2 AS col1 FROM tab1 WHERE - col2 <> col1 - + col1 / + col1
----
54
57
96

query I rowsort
SELECT col0 * + col1 + + col0 * tab0.col2 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT ALL col2 + col2 * - col2 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT ALL tab2.col0 * - col1 + + col2 AS col2 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT ALL col2 + col0 * + col0 * + col1 FROM tab0
----
118826
49569
720893

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col1 * + col2 + col1 * - tab0.col0 < - col2
----
24
86
33

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE col2 * + col1 * - col2 + - col2 IN ( cor0.col2 * + col2 + col0 + + col1 ) OR col0 * - cor0.col0 >= ( NULL )
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT NULL NOT IN ( - col0 * + cor0.col0 ) OR col2 + + col2 = ( NULL )
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT + col0 IN ( - col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT - col1 * col1 * col2 AS col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + + col0 * col2 col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL col0 * - tab1.col0 AS col2 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - col2 FROM tab0 AS cor0 WHERE NOT NULL NOT BETWEEN ( NULL ) AND NULL
----

query III rowsort
SELECT * FROM tab0 WHERE NULL IN ( col0 + col2 )
----

query I rowsort
SELECT DISTINCT - tab1.col2 * - cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 24458b87d784ecaf9184f99bd12fb51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-2458
SELECT col0 DIV + col2 + - col2 * col1 col2 FROM tab0
----
-2838
-62
-7461

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2458
SELECT col0 / + col2 + - col2 * col1 col2 FROM tab0
----
-2838
-62
-7461

query I rowsort
SELECT ALL 44 + + tab1.col1 FROM tab1
----
54
57
70

query I rowsort
SELECT ALL ( - cor0.col1 ) - + col1 AS col2 FROM tab0 cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-2461
SELECT DISTINCT CAST( - 80 AS SIGNED ) DIV col1 col0 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2461
SELECT DISTINCT CAST ( - 80 AS INTEGER ) / col1 col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - 82 * - ( col1 ) + - col2 FROM tab0 AS cor0
----
7019
7380
7953

query I rowsort
SELECT ALL + col1 * 37 FROM tab0 cor0
----
3182
3367
3589

query I rowsort
SELECT + 37 * ( col0 ) FROM tab2
----
259
2886
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-2465
SELECT + - col2 DIV col0 + + col2 AS col2 FROM tab0 AS cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-2465
SELECT + - col2 / col0 + + col2 AS col2 FROM tab0 AS cor0
----
1
32
82

query I rowsort
SELECT DISTINCT - + 36 * 21 + col0 FROM tab2 AS cor0
----
-677
-678
-749

query I rowsort
SELECT DISTINCT + - col2 + col1 - - ( col2 ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + cor0.col0 * + col2 + + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL - 28 * col1 * 19 + 68 * col0 * col2 AS col0 FROM tab2 AS cor0
----
-3640
106516
195092

query I rowsort
SELECT 88 + + col2 * + 71 AS col1 FROM tab1 AS cor0
----
3922
4135
6904

query I rowsort
SELECT ALL - - 17 * col2 + col1 - col0 FROM tab0 cor0
----
1396
623
79

query I rowsort
SELECT - col0 * col0 + + col2 AS col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + col1 + + col1 * - 41 AS col2 FROM tab1 AS cor0
----
-1040
-400
-520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col2 * col1 col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + 2 * col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + 4 + - col1 FROM tab0 AS cor0
----
-82
-87
-93

query I rowsort
SELECT ALL 19 FROM tab0 cor0
----
19
19
19

query I rowsort
SELECT 71 + col2 * + col1 AS col2 FROM tab2 AS cor0
----
1605
717
908

query I rowsort
SELECT DISTINCT - col1 * col2 + 15 * + 95 * col2 AS col2 FROM tab0 AS cor0
----
109388
1328
44187

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2480
SELECT col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2480
SELECT col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 - + 51 FROM tab2 AS cor0
----
-20
-34
8

query I rowsort
SELECT ALL - col2 + 58 * col1 AS col1 FROM tab2 cor0
----
1771
3396
948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2483
SELECT - + col1 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2483
SELECT - + col1 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col0 * col1 + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

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-2486
SELECT DISTINCT + - col2 * CAST( NULL AS DECIMAL ) * - col1 + col1 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2486
SELECT DISTINCT + - col2 * CAST ( NULL AS REAL ) * - col1 + col1 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col2 + 42 AS col1 FROM tab0
----
124
43
75

query I rowsort
SELECT - col1 * 60 + col2 * + col0 AS col0 FROM tab0 AS cor0
----
-4368
-5785
1838

query I rowsort
SELECT - col0 * col0 + 50 * + col1 AS col2 FROM tab2 AS cor0
----
-3134
-5391
1501

query I rowsort
SELECT DISTINCT + cor0.col2 + 36 * - col1 AS col0 FROM tab0 AS cor0
----
-3063
-3194
-3491

query I rowsort
SELECT DISTINCT col2 + - cor0.col0 + - 51 FROM tab2 AS cor0
----
-103
-31
-92

query I rowsort
SELECT ALL - - col1 * ( + cor0.col1 ) AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT + col1 - + col2 * 45 * + cor0.col0 AS col2 FROM tab2 cor0
----
-135073
-8474
-91201

query I rowsort
SELECT DISTINCT cor0.col2 * - 32 FROM tab2 AS cor0
----
-1216
-832
-864

query I rowsort
SELECT + col1 * col0 + col1 * + col2 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT ALL - cor0.col2 * + col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + + cor0.col0 * - cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT 61 * - col1 + col1 AS col2 FROM tab0 AS cor0
----
-5160
-5460
-5820

query I rowsort
SELECT DISTINCT - 14 + col0 * col0 FROM tab0 AS cor0
----
1211
562
7907

onlyif mysql # use DIV operator for integer division
query I rowsort label-2500
SELECT ALL 86 DIV col1 AS col2 FROM tab2 AS cor0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-2500
SELECT ALL 86 / col1 AS col2 FROM tab2 AS cor0
----
1
2
5

query I rowsort
SELECT ALL ( - 79 ) AS col0 FROM tab1 AS cor0
----
-79
-79
-79

query I rowsort
SELECT + + col0 + cor0.col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - 49 + ( col1 * + col1 ) FROM tab1 AS cor0
----
120
51
627

query I rowsort
SELECT + col2 - + 50 * col2 * + ( col1 ) AS col2 FROM tab2 AS cor0
----
-32262
-41823
-76674

query I rowsort
SELECT ALL - 76 + - cor0.col1 * col2 AS col0 FROM tab1 AS cor0
----
-1324
-1480
-646

query I rowsort
SELECT DISTINCT col2 * + 82 FROM tab1 AS cor0
----
4428
4674
7872

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2507
SELECT ALL + - CAST( + col0 AS SIGNED ) + + col1 FROM tab2 cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-2507
SELECT ALL + - CAST ( + col0 AS INTEGER ) + + col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT col2 + + col0 * + col0 + + col1 AS col0 FROM tab2
----
107
6169
6296

onlyif mysql # use DIV operator for integer division
query I rowsort label-2509
SELECT DISTINCT col0 DIV col2 + + ( col1 * col1 ) FROM tab0
----
7396
8282
9444

skipif mysql # not compatible
query I rowsort label-2509
SELECT DISTINCT col0 / col2 + + ( col1 * col1 ) FROM tab0
----
7396
8282
9444

query I rowsort
SELECT + col2 + + 12 + col2 * col1 AS col1 FROM tab1
----
1356
1470
639

query I rowsort
SELECT DISTINCT tab0.col0 * col1 + - col2 AS col1 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT + + cor0.col1 + + col2 * cor0.col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + 55 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2514
SELECT - col1 / CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2514
SELECT - col1 / CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * col0 + + col1 FROM tab1
----
188
3658
7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2516
SELECT ALL col2 / + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2516
SELECT ALL col2 / + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + col2 * - 80 FROM tab1 AS cor0
----
-4317
-4496
-7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + - col1 * col2 col1 FROM tab1 AS cor0
----
-1328
-1407
-634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2519
SELECT ALL CAST( - 55 AS SIGNED ) + cor0.col0 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to c5c29dcaa25b61ad2efa922d42ceddef

skipif mysql # not compatible
query I rowsort label-2519
SELECT ALL CAST ( - 55 AS INTEGER ) + cor0.col0 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to c5c29dcaa25b61ad2efa922d42ceddef

query I rowsort
SELECT - + col2 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT cor0.col1 * - 28 + col0 * + col2 FROM tab0 AS cor0
----
-1616
-2681
4750

onlyif mysql # use DIV operator for integer division
query I rowsort label-2522
SELECT - col0 + ( - 3 + + col1 ) DIV 31 FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2522
SELECT - col0 + ( - 3 + + col1 ) / 31 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT + ( + ( cor0.col2 ) ) * - cor0.col2 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 760e91273f37834612f88abef6e165f8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2524
SELECT DISTINCT - col0 * + col0 DIV + col0 + cor0.col0 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-2524
SELECT DISTINCT - col0 * + col0 / + col0 + cor0.col0 FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2525
SELECT - - col0 DIV cor0.col1 - 18 FROM tab0 AS cor0
----
-18
-18
-18

skipif mysql # not compatible
query I rowsort label-2525
SELECT - - col0 / cor0.col1 - 18 FROM tab0 AS cor0
----
-18
-18
-18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col2 - + col0 col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + col0 * + 54 + col0 AS col2 FROM tab2 AS cor0
----
385
4290
4345

query I rowsort
SELECT ALL col0 * 40 + cor0.col1 FROM tab1 AS cor0
----
146
2570
3213

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col0 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
-1
-33
-82

query I rowsort
SELECT + - col0 * + cor0.col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT - cor1.col1 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT + - 0 * - col0 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2533
SELECT ALL + + col2 * col2 + ( col0 ) * col2 DIV ( + cor0.col2 + + col0 ) FROM tab0 AS cor0
----
1
1102
6766

skipif mysql # not compatible
query I rowsort label-2533
SELECT ALL + + col2 * col2 + ( col0 ) * col2 / ( + cor0.col2 + + col0 ) FROM tab0 AS cor0
----
1
1102
6766

query I rowsort
SELECT col0 + cor0.col2 * 98 FROM tab2 AS cor0
----
2626
2653
3803

onlyif mysql # use DIV operator for integer division
query I rowsort label-2535
SELECT 31 DIV ( + col1 ) + 51 FROM tab0
----
51
51
51

skipif mysql # not compatible
query I rowsort label-2535
SELECT 31 / ( + col1 ) + 51 FROM tab0
----
51
51
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-2536
SELECT + 50 DIV col1 AS col2 FROM tab1 cor0
----
1
3
5

skipif mysql # not compatible
query I rowsort label-2536
SELECT + 50 / col1 AS col2 FROM tab1 cor0
----
1
3
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2537
SELECT - 81 DIV cor0.col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2537
SELECT - 81 / cor0.col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT - - 92 + tab2.col2 FROM tab2, tab1, tab0 AS cor0
----
118
119
130

query I rowsort
SELECT DISTINCT - + col0 * + col0 + + 74 FROM tab1 AS cor0
----
-4022
-6326
65

query I rowsort
SELECT DISTINCT + + col2 + col0 * + cor0.col0 + - col1 AS col0 FROM tab2 AS cor0
----
45
6051
6262

query I rowsort
SELECT DISTINCT + col0 + col1 * - 12 FROM tab1 AS cor0
----
-309
-56
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 63 col0 FROM tab1 AS cor0
----
-63
-63
-63

query I rowsort
SELECT + ( ( - col2 ) * - tab1.col2 ) - ( + col0 * - col1 ) AS col0 FROM tab1
----
10256
2994
3889

query I rowsort
SELECT 94 - col1 FROM tab2
----
35
63
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * col0 * col1 col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT 33 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2547
SELECT 41 * col1 DIV tab1.col1 + col1 AS col2 FROM tab1
----
51
54
67

skipif mysql # not compatible
query I rowsort label-2547
SELECT 41 * col1 / tab1.col1 + col1 AS col2 FROM tab1
----
51
54
67

query I rowsort
SELECT DISTINCT cor1.col1 AS col1 FROM tab0, tab0 cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT ALL tab2.col2 * ( tab2.col2 * col2 ) AS col1 FROM tab2
----
17576
19683
54872

query I rowsort
SELECT DISTINCT - col0 * ( col2 + col1 * + col1 ) AS col2 FROM tab2
----
-25833
-273546
-6916

query I rowsort
SELECT ALL + col2 + + 68 + col2 AS col2 FROM tab2 cor0
----
120
122
144

query I rowsort
SELECT col2 * ( - col2 ) FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT + 57 * + cor0.col1 - col2 AS col0 FROM tab0 AS cor0
----
4869
5105
5528

query I rowsort
SELECT DISTINCT col1 - - col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - + ( 30 ) + col0 AS col0 FROM tab2 AS cor0
----
-23
48
49

query I rowsort
SELECT DISTINCT - col2 + ( 67 ) FROM tab0
----
-15
34
66

query I rowsort
SELECT - 39 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a08a82dc9276c0173448e9a1c89dba93

query I rowsort
SELECT + col0 + + 88 * ( col2 ) FROM tab1
----
4755
5080
8528

query I rowsort
SELECT col1 + 88 * + col1 AS col0 FROM tab1
----
1157
2314
890

query I rowsort
SELECT DISTINCT col2 * - cor0.col0 + col2 + - 30 FROM tab1 cor0
----
-138
-3621
-7614

query I rowsort
SELECT + col1 * 14 FROM tab0 AS cor0
----
1204
1274
1358

query I rowsort
SELECT DISTINCT + 66 + + 89 * col2 AS col0 FROM tab1 AS cor0
----
4872
5139
8610

query I rowsort
SELECT ALL - col1 + + col2 * + col1 FROM tab0 cor0
----
0
2752
7371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2564
SELECT ALL + CAST( NULL AS SIGNED ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2564
SELECT ALL + CAST ( NULL AS INTEGER ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + tab2.col0 - 73 * tab2.col2 FROM tab2
----
-1761
-1933
-2678

query I rowsort
SELECT DISTINCT tab0.col0 - + col0 FROM tab0
----
0

query I rowsort
SELECT DISTINCT - 95 * + col2 - ( - col0 * col2 ) FROM tab1
----
-1440
-1767
-4968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2568
SELECT col2 - - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2568
SELECT col2 - - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2569
SELECT DISTINCT - col2 DIV ( - cor0.col0 ) + - col1 FROM tab2 AS cor0
----
-17
-28
-59

skipif mysql # not compatible
query I rowsort label-2569
SELECT DISTINCT - col2 / ( - cor0.col0 ) + - col1 FROM tab2 AS cor0
----
-17
-28
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * 96 col1 FROM tab1 AS cor0
----
-288
-6144
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2571
SELECT col0 DIV + col0 + col2 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-2571
SELECT col0 / + col0 + col2 AS col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL - 33 + col0 FROM tab0
----
-9
2
56

query I rowsort
SELECT - tab1.col0 + + col0 + - tab1.col2 AS col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL + 99 + col2 FROM tab0
----
100
132
181

query I rowsort
SELECT 80 + tab0.col0 AS col2 FROM tab0
----
104
115
169

query I rowsort
SELECT ALL col0 * + col0 + col1 * - col0 AS col1 FROM tab1 cor0
----
-69
3456
5360

onlyif mysql # use DIV operator for integer division
query I rowsort label-2577
SELECT ALL col1 DIV - ( col0 ) FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-2577
SELECT ALL col1 / - ( col0 ) FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2578
SELECT ALL + col0 DIV + col0 + - col0 * cor0.col0 AS col0 FROM tab0 cor0
----
-1224
-575
-7920

skipif mysql # not compatible
query I rowsort label-2578
SELECT ALL + col0 / + col0 + - col0 * cor0.col0 AS col0 FROM tab0 cor0
----
-1224
-575
-7920

query I rowsort
SELECT ALL - - col2 * col2 + + col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT DISTINCT - - col1 * - 57 + col1 * col2 * ( - col1 + + cor0.col0 * + col2 ) AS col1 FROM tab2 AS cor0
----
130479
1927341
3017083

query I rowsort
SELECT - cor0.col1 * cor0.col0 + col1 * - cor0.col2 FROM tab2 AS cor0
----
-1054
-1989
-6136

query I rowsort
SELECT ALL + col1 * 18 + + col2 FROM tab2 AS cor0
----
1088
344
585

query I rowsort
SELECT + col2 * ( 70 ) AS col2 FROM tab0 AS cor0
----
2310
5740
70

query I rowsort
SELECT col1 - + col0 * - tab0.col2 AS col0 FROM tab0
----
132
7389
878

query I rowsort
SELECT DISTINCT - - ( + 62 ) AS col2 FROM tab2 AS cor0
----
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2586
SELECT ALL - + CAST( NULL AS SIGNED ) * col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2586
SELECT ALL - + CAST ( NULL AS INTEGER ) * col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 38 + col0 AS col0 FROM tab2 cor0
----
-31
40
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-2588
SELECT + ( col2 ) * 56 + 66 DIV col0 FROM tab0 AS cor0
----
1850
4592
57

skipif mysql # not compatible
query I rowsort label-2588
SELECT + ( col2 ) * 56 + 66 / col0 FROM tab0 AS cor0
----
1850
4592
57

query I rowsort
SELECT 42 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT ALL + - 48 FROM tab0 cor0
----
-48
-48
-48

onlyif mysql # use DIV operator for integer division
query I rowsort label-2591
SELECT 84 DIV col2 + - ( + col0 ) DIV + col1 FROM tab0 AS cor0
----
1
2
84

skipif mysql # not compatible
query I rowsort label-2591
SELECT 84 / col2 + - ( + col0 ) / + col1 FROM tab0 AS cor0
----
1
2
84

query I rowsort
SELECT ALL - + col2 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT + col1 * ( - col0 ) AS col2 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2594
SELECT ALL - col2 + cor0.col1 DIV + 73 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2594
SELECT ALL - col2 + cor0.col1 / + 73 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col2 * col0 col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL - col0 + - col1 AS col1 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT - - 81 AS col2 FROM tab1 AS cor0
----
81
81
81

query I rowsort
SELECT + + col0 + - cor0.col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2599
SELECT - col2 + + col0 DIV ( 9 ) AS col0 FROM tab2 AS cor0
----
-18
-27
-30

skipif mysql # not compatible
query I rowsort label-2599
SELECT - col2 + + col0 / ( 9 ) AS col0 FROM tab2 AS cor0
----
-18
-27
-30

query I rowsort
SELECT - - 19 * cor0.col1 AS col0 FROM tab1 AS cor0
----
190
247
494

query I rowsort
SELECT + - col1 + - col1 * + 70 AS col2 FROM tab2 cor0
----
-1207
-2201
-4189

onlyif mysql # use DIV operator for integer division
query I rowsort label-2602
SELECT + + col2 + - 92 - cor0.col2 * col1 DIV 46 AS col0 FROM tab0 AS cor0
----
-120
-172
-93

skipif mysql # not compatible
query I rowsort label-2602
SELECT + + col2 + - 92 - cor0.col2 * col1 / 46 AS col0 FROM tab0 AS cor0
----
-120
-172
-93

query I rowsort
SELECT + col1 + 12 FROM tab1 AS cor0
----
22
25
38

query I rowsort
SELECT col0 - ( ( - col2 ) ) * - 24 FROM tab2 AS cor0
----
-546
-641
-833

query I rowsort
SELECT col2 + + 8 * col1 FROM tab2 AS cor0
----
174
275
498

query I rowsort
SELECT - col0 * - col1 + col0 * - 80 AS col2 FROM tab2
----
-1638
-343
-4977

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col1 AS REAL ) * + cor0.col0 - cor0.col0 / - col0 col2 FROM tab1 AS cor0
----
1041
641
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2608
SELECT - ( col2 ) + cor0.col2 DIV 84 FROM tab1 cor0
----
-54
-57
-95

skipif mysql # not compatible
query I rowsort label-2608
SELECT - ( col2 ) + cor0.col2 / 84 FROM tab1 cor0
----
-54
-57
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2609
SELECT DISTINCT + 50 DIV - 25 + + col2 FROM tab2 AS cor0
----
24
25
36

skipif mysql # not compatible
query I rowsort label-2609
SELECT DISTINCT + 50 / - 25 + + col2 FROM tab2 AS cor0
----
24
25
36

query I rowsort
SELECT DISTINCT + 75 + + col2 * - col2 * - cor0.col0 AS col1 FROM tab1 cor0
----
208011
737355
8823

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( - cor0.col1 ) + col0 col0 FROM tab2 cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2612
SELECT ALL + - CAST( cor0.col0 AS SIGNED ) * + col2 col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2612
SELECT ALL + - CAST ( cor0.col0 AS INTEGER ) * + col2 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL 7 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2614
SELECT ( col1 ) + cor0.col0 DIV - 92 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2614
SELECT ( col1 ) + cor0.col0 / - 92 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + tab0.col1 * 14 FROM tab0
----
1204
1274
1358

query I rowsort
SELECT DISTINCT + ( + 88 ) * col0 + 25 AS col1 FROM tab1 AS cor0
----
289
5657
7065

query I rowsort
SELECT ( 25 ) + + tab1.col2 AS col0 FROM tab1
----
121
79
82

query I rowsort
SELECT + 6 AS col0 FROM tab2
----
6
6
6

query I rowsort
SELECT - 53 FROM tab1, tab1 cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

query I rowsort
SELECT - - col0 + ( - 5 ) FROM tab0 AS cor0
----
19
30
84

query I rowsort
SELECT + col1 + 76 AS col0 FROM tab0 AS cor0
----
162
167
173

query I rowsort
SELECT ALL - 58 FROM tab1, tab2 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT - 76 + col2 FROM tab1 AS cor0
----
-19
-22
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-2624
SELECT DISTINCT tab1.col0 DIV 17 - + col0 AS col0 FROM tab1
----
-3
-61
-76

skipif mysql # not compatible
query I rowsort label-2624
SELECT DISTINCT tab1.col0 / 17 - + col0 AS col0 FROM tab1
----
-3
-61
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 - - tab0.col0 col0 FROM tab0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2626
SELECT - - CAST( - 86 AS SIGNED ) + col0 * ( + ( + col1 ) ) FROM tab0 AS cor0
----
1978
3309
8013

skipif mysql # not compatible
query I rowsort label-2626
SELECT - - CAST ( - 86 AS INTEGER ) + col0 * ( + ( + col1 ) ) FROM tab0 AS cor0
----
1978
3309
8013

query I rowsort
SELECT DISTINCT col2 * - 50 + col1 FROM tab2 AS cor0
----
-1241
-1319
-1883

query I rowsort
SELECT DISTINCT - + col1 + 60 AS col2 FROM tab1 AS cor0
----
34
47
50

query I rowsort
SELECT + tab2.col2 * - col2 * ( + col1 + col0 ) FROM tab2
----
-138624
-27702
-92612

query I rowsort
SELECT ( - col2 + - 79 ) * - col1 FROM tab0
----
14651
7760
9632

onlyif mysql # use DIV operator for integer division
query I rowsort label-2631
SELECT DISTINCT col2 * tab0.col2 DIV + ( 96 ) AS col0 FROM tab0
----
0
11
70

skipif mysql # not compatible
query I rowsort label-2631
SELECT DISTINCT col2 * tab0.col2 / + ( 96 ) AS col0 FROM tab0
----
0
11
70

query I rowsort
SELECT - 60 * col1 AS col1 FROM tab0
----
-5160
-5460
-5820

query I rowsort
SELECT DISTINCT - cor0.col2 AS col2 FROM tab0, tab2, tab1 AS cor0, tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT 8 * - tab2.col1 FROM tab2
----
-136
-248
-472

query I rowsort
SELECT - col1 * - cor0.col2 + + 4 + col0 FROM tab2 AS cor0
----
1616
729
848

query I rowsort
SELECT + - col2 + col1 * - ( + col1 ) * col1 + + col0 AS col1 FROM tab0 AS cor0
----
-636065
-753564
-912639

query I rowsort
SELECT col2 + - col2 + - 66 AS col0 FROM tab2 AS cor0
----
-66
-66
-66

query I rowsort
SELECT - + 26 + col1 FROM tab0 AS cor0
----
60
65
71

query I rowsort
SELECT - + col0 * ( - col1 ) AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - cor0.col1 * - 48 AS col0 FROM tab0 AS cor0
----
4128
4368
4656

query I rowsort
SELECT col2 * 17 AS col2 FROM tab0 cor0
----
1394
17
561

query I rowsort
SELECT - col2 + + ( - col0 ) * - col1 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT + - col1 + col0 * + ( + col2 ) FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - col1 + - cor0.col1 * + col1 AS col0 FROM tab1 cor0
----
-110
-182
-702

query I rowsort
SELECT - + col0 + + ( + col1 ) * cor0.col2 AS col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT - col0 * col2 + cor0.col1 + + col1 FROM tab1 AS cor0
----
-110
-3628
-7654

onlyif mysql # use DIV operator for integer division
query I rowsort label-2647
SELECT - col1 DIV + 87 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2647
SELECT - col1 / + 87 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * - col0 + cor0.col0 * - col1 FROM tab1 AS cor0
----
-4736
-7440
-87

query I rowsort
SELECT - col2 * - cor0.col2 + - col1 * col2 + ( 77 * col2 ) FROM tab2 AS cor0
----
1144
1971
3724

query I rowsort
SELECT ALL - + ( 83 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT - + col2 * + col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + ( + cor0.col0 ) * + col0 + - ( - col0 ) col1 FROM tab2 AS cor0
----
6221
6337
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-2653
SELECT - + 60 DIV + col2 AS col2 FROM tab1 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2653
SELECT - + 60 / + col2 AS col2 FROM tab1 cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT - col2 * 55 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
-156090
-410410
-5335

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2655
SELECT + CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2655
SELECT + CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 57 * col1 + col0 FROM tab1 AS cor0
----
1485
634
821

onlyif mysql # use DIV operator for integer division
query I rowsort label-2657
SELECT col1 DIV cor0.col0 col2 FROM tab1 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2657
SELECT col1 / cor0.col0 col2 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT DISTINCT - col0 * 85 FROM tab2 AS cor0
----
-595
-6630
-6715

query I rowsort
SELECT ALL + 6 * col2 AS col2 FROM tab0 AS cor0
----
198
492
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2660
SELECT DISTINCT + - col1 DIV + col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-2660
SELECT DISTINCT + - col1 / + col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT ALL + + cor0.col2 * + 26 AS col1 FROM tab1 AS cor0
----
1404
1482
2496

query I rowsort
SELECT DISTINCT tab0.col0 + col1 + col1 AS col1 FROM tab0
----
196
229
271

query I rowsort
SELECT ALL + col2 * col1 + + 25 AS col2 FROM tab1
----
1273
1429
595

query I rowsort
SELECT ALL col1 * ( + 68 ) AS col2 FROM tab1
----
1768
680
884

query I rowsort
SELECT col2 + + 75 AS col1 FROM tab2
----
101
102
113

query I rowsort
SELECT ALL + + col0 * col2 + + 25 FROM tab2 AS cor0
----
2053
214
3027

query I rowsort
SELECT ALL col2 - - col2 FROM tab0 cor0
----
164
2
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2668
SELECT DISTINCT + 32 * col2 * - CAST( NULL AS DECIMAL ) - - col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2668
SELECT DISTINCT + 32 * col2 * - CAST ( NULL AS REAL ) - - col0 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2669
SELECT ALL 95 * - col2 + + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2669
SELECT ALL 95 * - col2 + + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + cor0.col1 * + 52 * + cor0.col1 + col0 AS col0 FROM tab0 AS cor0
----
384640
430790
489338

query I rowsort
SELECT - + col0 * col0 + + 68 * + 63 AS col2 FROM tab0 AS cor0
----
-3637
3059
3708

query I rowsort
SELECT 97 + col0 AS col0 FROM tab1 AS cor0
----
100
161
177

query I rowsort
SELECT ALL - cor0.col1 * + col1 + + col0 * - col1 + col1 FROM tab1 AS cor0
----
-1196
-728
-730

query I rowsort
SELECT + 69 * col1 * + col2 AS col1 FROM tab0
----
195822
514878
6693

query I rowsort
SELECT ALL - ( - tab0.col2 * col0 + - ( + ( col0 ) ) ) FROM tab0
----
70
7387
816

query I rowsort
SELECT + col0 * - col2 + - 59 AS col1 FROM tab1 AS cor0
----
-221
-3707
-7739

query I rowsort
SELECT - 35 + col0 FROM tab0 AS cor0
----
-11
0
54

query I rowsort
SELECT + - 29 * + col0 FROM tab0 AS cor0
----
-1015
-2581
-696

query I rowsort
SELECT ALL - 79 * - col1 FROM tab2 AS cor0
----
1343
2449
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-2680
SELECT DISTINCT + + 83 DIV col1 col1 FROM tab1 AS cor0
----
3
6
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2680
SELECT DISTINCT + + 83 / col1 col1 FROM tab1 AS cor0
----
3
6
8

query I rowsort
SELECT ALL + 88 * col1 + - col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
6776
710
8501

onlyif mysql # use DIV operator for integer division
query I rowsort label-2682
SELECT col2 + col2 DIV - col1 + col2 FROM tab1
----
106
109
185

skipif mysql # not compatible
query I rowsort label-2682
SELECT col2 + col2 / - col1 + col2 FROM tab1
----
106
109
185

query I rowsort
SELECT ALL + col1 FROM tab1 WHERE NOT ( NULL ) IN ( + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col2 + col0 * col0 col0 FROM tab1
----
4153
63
6496

query I rowsort
SELECT ALL col1 / - col0 FROM tab2 WHERE ( NULL ) NOT IN ( col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2686
SELECT ALL - + cor0.col0 DIV cor0.col1 + col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2686
SELECT ALL - + cor0.col0 / cor0.col1 + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - 79 * col1 * ( + col1 ) FROM tab2 AS cor0
----
-22831
-274999
-75919

query I rowsort
SELECT DISTINCT ( col1 ) * col1 + ( col2 ) + col1 * + col1 FROM tab2
----
1949
616
6988

onlyif mysql # use DIV operator for integer division
query I rowsort label-2689
SELECT DISTINCT tab2.col0 DIV + tab2.col1 + col1 FROM tab2
----
21
31
60

skipif mysql # not compatible
query I rowsort label-2689
SELECT DISTINCT tab2.col0 / + tab2.col1 + col1 FROM tab2
----
21
31
60

query I rowsort
SELECT 95 * - col0 AS col2 FROM tab1
----
-285
-6080
-7600

query I rowsort
SELECT - ( - col0 ) + ( - col0 * - col1 ) + col1 FROM tab2
----
1439
255
4739

onlyif mysql # use DIV operator for integer division
query I rowsort label-2692
SELECT DISTINCT col2 + col1 DIV 41 + + col1 FROM tab2
----
55
58
86

skipif mysql # not compatible
query I rowsort label-2692
SELECT DISTINCT col2 + col1 / 41 + + col1 FROM tab2
----
55
58
86

query I rowsort
SELECT - 31 AS col0 FROM tab0
----
-31
-31
-31

query I rowsort
SELECT col1 + + col1 * - 69 + col0 AS col1 FROM tab0
----
-5824
-6099
-6561

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2695
SELECT - col0 - + CAST( + col1 + + col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-196
-229
-271

skipif mysql # not compatible
query I rowsort label-2695
SELECT - col0 - + CAST ( + col1 + + col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-196
-229
-271

query I rowsort
SELECT - - cor0.col2 * - col2 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT DISTINCT col2 * col2 + col1 + col0 AS col0 FROM tab2
----
1540
767
813

query I rowsort
SELECT + cor0.col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col0 * col0 + + tab1.col0 + tab1.col2 * + col2 * - ( + col0 ) AS col0 FROM tab1
----
-203776
-730800
-8736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2700
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab1, tab2 cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2700
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab1, tab2 cor0, tab1 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2701
SELECT ALL col0 * - col2 + col2 DIV + col2 col0 FROM tab1
----
-161
-3647
-7679

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2701
SELECT ALL col0 * - col2 + col2 / + col2 col0 FROM tab1
----
-161
-3647
-7679

query I rowsort
SELECT col2 * tab2.col1 + - col0 AS col1 FROM tab2
----
1456
567
830

query III rowsort
SELECT * FROM tab0 WHERE NULL IN ( col0 * col2 / col0 )
----

query I rowsort
SELECT DISTINCT col2 * col1 + + col1 AS col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT DISTINCT - tab2.col0 * col0 AS col1 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT + col0 - col1 * col0 AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT DISTINCT col2 * + col0 - - col1 AS col1 FROM tab1
----
188
3658
7693

query I rowsort
SELECT ALL col1 * tab2.col2 + + col0 * + tab2.col2 FROM tab2
----
1026
3562
3648

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL NOT IN ( + col2 )
----

query III rowsort
SELECT * FROM tab2 WHERE NULL IN ( col2 + - col0 )
----

query I rowsort
SELECT ALL col0 + col2 AS col0 FROM tab1 WHERE NOT NULL > col1 + - col0
----

query I rowsort
SELECT - col2 + col1 * col0 AS col1 FROM tab1
----
24
583
944

query I rowsort
SELECT + col1 * col1 + col0 * col0 AS col0 FROM tab2
----
1010
6530
9565

onlyif mysql # use DIV operator for integer division
query I rowsort label-2714
SELECT ALL + col2 + - col0 DIV + col0 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-2714
SELECT ALL + col2 + - col0 / + col0 FROM tab0
----
0
32
81

query I rowsort
SELECT - col2 * + col2 + col0 AS col2 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT + col2 * col1 / + col1 AS col2 FROM tab0 WHERE NOT NULL NOT IN ( tab0.col0 + col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 + col0 col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT ALL + tab2.col1 * tab2.col1 FROM tab2
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-2719
SELECT col1 + col1 + col2 DIV col2 AS col0 FROM tab0
----
173
183
195

skipif mysql # not compatible
query I rowsort label-2719
SELECT col1 + col1 + col2 / col2 AS col0 FROM tab0
----
173
183
195

query I rowsort
SELECT DISTINCT - col1 + + col2 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ALL + col2 * col0 * col1 + + col2 AS col2 FROM tab0
----
3396
664200
68145

query I rowsort
SELECT DISTINCT + col1 * + tab0.col0 + - col1 * + col1 AS col0 FROM tab0
----
-182
-5332
-6014

query I rowsort
SELECT + tab1.col1 * + col0 * col1 + col1 * col0 + - col2 FROM tab1
----
14464
2052
6983

query I rowsort
SELECT DISTINCT col2 FROM tab2 WHERE col2 <= NULL
----

query I rowsort
SELECT ALL col2 * tab0.col1 FROM tab0 WHERE NULL >= + col0
----

query I rowsort
SELECT - 58 FROM tab0, tab0 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT + 45 + + col1 * col0 AS col2 FROM tab1 cor0
----
1085
123
685

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col2 * cor0.col1 + - col2 col1 FROM tab2 AS cor0
----
1586
687
817

query I rowsort
SELECT DISTINCT + 12 AS col0 FROM tab0
----
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 85 col1 FROM tab0
----
-85

query I rowsort
SELECT - ( ( col1 ) ) AS col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL col0 + col1 - - col0 AS col2 FROM tab2 cor0
----
175
215
45

query I rowsort
SELECT 60 * + cor0.col1 + + 33 AS col2 FROM tab2 AS cor0
----
1053
1893
3573

query I rowsort
SELECT + 94 AS col2 FROM tab1 cor0
----
94
94
94

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 cor1, tab1 AS cor2
----
972 values hashing to 7942394eb7766dfb9ea95b7805ff595d

query I rowsort
SELECT col0 * - col0 * - 8 AS col1 FROM tab0
----
4608
63368
9800

query I rowsort
SELECT - col1 + ( cor0.col2 ) * - col2 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT ALL + cor0.col2 * + col0 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * col1 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT col1 * - ( - ( + col0 ) ) AS col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - - cor0.col0 * + cor0.col2 + - 12 FROM tab0 AS cor0
----
23
7286
780

onlyif mysql # use DIV operator for integer division
query I rowsort label-2742
SELECT + col1 + - col1 * 81 DIV + cor0.col2 AS col0 FROM tab1 AS cor0
----
-13
-4
3

skipif mysql # not compatible
query I rowsort label-2742
SELECT + col1 + - col1 * 81 / + cor0.col2 AS col0 FROM tab1 AS cor0
----
-13
-4
3

query I rowsort
SELECT DISTINCT - col1 * col2 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2744
SELECT DISTINCT + col0 * - CAST( + 19 AS SIGNED ) * col2 + cor0.col0 col0 FROM tab0 AS cor0
----
-138573
-15024
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2744
SELECT DISTINCT + col0 * - CAST ( + 19 AS INTEGER ) * col2 + cor0.col0 col0 FROM tab0 AS cor0
----
-138573
-15024
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-2745
SELECT + - cor0.col0 DIV col2 + col2 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-2745
SELECT + - cor0.col0 / col2 + col2 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT - ( col0 ) * + col2 + - 0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL 58 - col0 AS col2 FROM tab1 AS cor0
----
-22
-6
55

query I rowsort
SELECT + col1 + + 68 AS col0 FROM tab0 AS cor0
----
154
159
165

query I rowsort
SELECT DISTINCT + col2 * + col1 - col2 AS col2 FROM tab2 cor0
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-2750
SELECT ALL - cor0.col2 DIV 7 AS col1 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 15171441afe0b287ee7f0cbfa0be4053

skipif mysql # not compatible
query I rowsort label-2750
SELECT ALL - cor0.col2 / 7 AS col1 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 15171441afe0b287ee7f0cbfa0be4053

query I rowsort
SELECT - col2 + col0 * col2 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-2752
SELECT ALL 31 * col1 + col1 DIV col2 FROM tab1 AS cor0
----
310
403
806

skipif mysql # not compatible
query I rowsort label-2752
SELECT ALL 31 * col1 + col1 / col2 FROM tab1 AS cor0
----
310
403
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2753
SELECT DISTINCT 5 DIV + cor0.col1 col1 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2753
SELECT DISTINCT 5 / + cor0.col1 col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - col2 * - cor0.col2 + + col0 FROM tab0 cor0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-2755
SELECT col0 DIV - cor0.col2 AS col2 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-2755
SELECT col0 / - cor0.col2 AS col2 FROM tab0 cor0
----
-1
-35
0

query I rowsort
SELECT 51 * - col2 AS col2 FROM tab0 AS cor0
----
-1683
-4182
-51

query I rowsort
SELECT + ( - 47 ) AS col2 FROM tab0
----
-47
-47
-47

query I rowsort
SELECT 54 FROM tab0, tab0 AS cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT ALL 15 + cor0.col1 AS col1 FROM tab1 AS cor0
----
25
28
41

query I rowsort
SELECT + 1 + + cor0.col0 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - 71 + - col0 AS col0 FROM tab2 AS cor0
----
-149
-150
-78

query I rowsort
SELECT DISTINCT col1 * - col0 + col1 AS col0 FROM tab1 cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-2763
SELECT ALL col2 DIV - 86 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2763
SELECT ALL col2 / - 86 AS col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2764
SELECT DISTINCT col0 DIV col0 col0 FROM tab2
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2764
SELECT DISTINCT col0 / col0 col0 FROM tab2
----
1

query I rowsort
SELECT - - col2 * col2 * col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT ALL + 1 * col0 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + ( col2 ) * col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + + col2 + col0 * - col0 AS col0 FROM tab0 cor0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 33 col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-33

query I rowsort
SELECT + col0 * + col2 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL - col0 - cor0.col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT DISTINCT - 56 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
-56

query I rowsort
SELECT ALL - cor0.col1 * + cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 79ea663c5f468cc57a869fc826cf04a5

query I rowsort
SELECT ALL ( tab2.col0 ) + col1 FROM tab2
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2775
SELECT DISTINCT CAST( NULL AS SIGNED ) + 97 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2775
SELECT DISTINCT CAST ( NULL AS INTEGER ) + 97 FROM tab2
----
NULL

query I rowsort
SELECT + col0 + + col1 * + tab1.col1 * + col2 AS col0 FROM tab1
----
16304
36507
5764

query I rowsort
SELECT ALL 56 * + 55 FROM tab0
----
3080
3080
3080

query I rowsort
SELECT - col2 * 4 AS col2 FROM tab2
----
-104
-108
-152

query I rowsort
SELECT - cor0.col0 * + tab1.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 1091576b2dabfc91057486e7b5f493ef

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 71d467ba3372dfdd21847af1687c92e7

query I rowsort
SELECT - cor0.col0 + ( + col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT 86 + - col0 AS col1 FROM tab0 AS cor0
----
-3
51
62

query I rowsort
SELECT 84 + - col1 * - col0 * col0 FROM tab2 AS cor0
----
106181
1603
359040

query I rowsort
SELECT - col2 * - col0 + + col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT ALL - col1 + - tab1.col0 * tab1.col2 FROM tab1
----
-188
-3658
-7693

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-2787
SELECT col0 DIV col2 col0 FROM tab1
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2787
SELECT col0 / col2 col0 FROM tab1
----
0
0
1

query I rowsort
SELECT + col2 * col2 - - col2 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-2789
SELECT ALL + col2 + + col0 DIV col0 col1 FROM tab0 AS cor0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2789
SELECT ALL + col2 + + col0 / col0 col1 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2790
SELECT ALL col1 DIV - col1 + + tab2.col0 AS col0 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-2790
SELECT ALL col1 / - col1 + + tab2.col0 AS col0 FROM tab2
----
6
77
78

query I rowsort
SELECT + col1 * col1 + col1 AS col1 FROM tab0 cor0
----
7482
8372
9506

query I rowsort
SELECT ALL - col0 * col0 - cor0.col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL + col2 - col2 * + col2 AS col1 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-2794
SELECT DISTINCT col0 * col0 + col0 DIV tab0.col0 AS col2 FROM tab0
----
1226
577
7922

skipif mysql # not compatible
query I rowsort label-2794
SELECT DISTINCT col0 * col0 + col0 / tab0.col0 AS col2 FROM tab0
----
1226
577
7922

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col1 + + col0 col2 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT col0 + - cor0.col1 * + col2 * col2 AS col1 FROM tab1 cor0
----
-119728
-32426
-75813

query I rowsort
SELECT + col0 + col1 * tab0.col2 * col0 FROM tab0
----
3430
664207
68136

query I rowsort
SELECT - - col1 + col1 * col2 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT col1 - col0 * col2 AS col1 FROM tab0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2800
SELECT ALL col0 + col2 DIV + col1 FROM tab1 cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-2800
SELECT ALL col0 + col2 / + col1 FROM tab1 cor0
----
5
69
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - col0 * + col2 * col2 + + col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

query I rowsort
SELECT col1 + + col1 * + cor0.col0 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-2804
SELECT - col1 - col0 DIV + col0 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-2804
SELECT - col1 - col0 / + col0 FROM tab1 AS cor0
----
-11
-14
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + - col2 * col0 * col2 col0 FROM tab0 AS cor0
----
-26112
-598347
0

query I rowsort
SELECT + col0 + + col2 FROM tab1 WHERE - col0 - + col1 NOT IN ( col2 ) AND NOT - col0 * + col1 + + col2 NOT IN ( + tab1.col1 + + col0 )
----

query I rowsort
SELECT ALL - col1 * - col2 - - col0 * col0 AS col2 FROM tab0
----
1322
15383
3414

query I rowsort
SELECT - - cor0.col0 * - col2 + + col1 - - col0 AS col1 FROM tab2 cor0
----
-151
-1891
-2906

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - ( cor0.col2 ) col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - col0 * col2 + 80 FROM tab0 AS cor0
----
-712
-7218
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 7 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

query I rowsort
SELECT DISTINCT - col1 * 41 FROM tab1
----
-1066
-410
-533

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * col2 + 16 * - col0 col1 FROM tab1
----
2225
2868
7936

query I rowsort
SELECT col0 * - 31 FROM tab0 AS cor0
----
-1085
-2759
-744

query I rowsort
SELECT ALL - + col1 * + col1 * col2 AS col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT + col1 * + ( cor0.col2 + col2 ) FROM tab0 cor0
----
14924
194
5676

query I rowsort
SELECT + - col2 * + col0 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - - col2 + + cor0.col0 * - 75 * - col0 FROM tab2 AS cor0
----
3702
456326
468113

query I rowsort
SELECT DISTINCT cor0.col0 * + 85 AS col0 FROM tab2 AS cor0
----
595
6630
6715

query I rowsort
SELECT - ( - col0 ) + col1 * - col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT + + ( cor0.col2 ) FROM tab0 cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2823
SELECT DISTINCT + - ( col0 ) * col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2823
SELECT DISTINCT + - ( col0 ) * col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( + col2 ) col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - 12 * cor0.col1 FROM tab1 AS cor0
----
-120
-156
-312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2826
SELECT + tab2.col0 + CAST( + 73 AS SIGNED ) * - tab2.col2 col2 FROM tab2
----
-1820
-1964
-2695

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2826
SELECT + tab2.col0 + CAST ( + 73 AS INTEGER ) * - tab2.col2 col2 FROM tab2
----
-1820
-1964
-2695

query I rowsort
SELECT DISTINCT + col2 * 30 FROM tab0
----
2460
30
990

query I rowsort
SELECT + col0 * + col0 + 10 FROM tab2 AS cor0
----
59
6094
6251

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * + col1 + - cor0.col1 col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-2830
SELECT DISTINCT - + col1 DIV - cor0.col1 AS col0 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2830
SELECT DISTINCT - + col1 / - cor0.col1 AS col0 FROM tab1 AS cor0
----
1

query I rowsort
SELECT - + ( - col0 ) + + col2 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + + col0 * + cor0.col2 AS col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + + 95 * - col1 AS col2 FROM tab2 cor0
----
-1615
-2945
-5605

onlyif mysql # use DIV operator for integer division
query I rowsort label-2834
SELECT ALL - + col0 DIV + col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2834
SELECT ALL - + col0 / + col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - 68 + col2 FROM tab0 AS cor0
----
-35
-67
14

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2836
SELECT - CAST( - col1 AS SIGNED ) + col0 FROM tab1
----
29
74
93

skipif mysql # not compatible
query I rowsort label-2836
SELECT - CAST ( - col1 AS INTEGER ) + col0 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2837
SELECT - col0 * col0 * ( cor0.col1 * col0 ) + 17 DIV 60 FROM tab2 AS cor0
----
-10633
-27998568
-8381663

skipif mysql # not compatible
query I rowsort label-2837
SELECT - col0 * col0 * ( cor0.col1 * col0 ) + 17 / 60 FROM tab2 AS cor0
----
-10633
-27998568
-8381663

query I rowsort
SELECT - col1 * col2 + ( 1 ) FROM tab1 AS cor0
----
-1247
-1403
-569

query I rowsort
SELECT DISTINCT 64 * - col0 + + col1 FROM tab1 AS cor0
----
-166
-4086
-5107

query I rowsort
SELECT DISTINCT + 13 AS col2 FROM tab1 AS cor0
----
13

query I rowsort
SELECT - col1 + - col1 * cor0.col1 - col2 FROM tab2 AS cor0
----
-1019
-344
-3566

query I rowsort
SELECT DISTINCT - - 40 FROM tab0 cor0
----
40

query I rowsort
SELECT - 18 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-107
-42
-53

query I rowsort
SELECT - 6 + col1 AS col1 FROM tab0
----
80
85
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + 61 col1 FROM tab1 cor0
----
115
118
157

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2846
SELECT - + col1 * + ( + col1 ) + - col0 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2846
SELECT - + col1 * + ( + col1 ) + - col0 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col1 * col0 + + 23 * + col0 FROM tab1 cor0
----
147
2112
2880

query I rowsort
SELECT - col1 * - 10 + ( col0 ) * col2 FROM tab2 AS cor0
----
2618
3172
499

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 col0 FROM tab2
----
87
87
87

query I rowsort
SELECT + col0 * col2 + - 38 + 36 AS col2 FROM tab1
----
160
3646
7678

query I rowsort
SELECT - cor0.col2 * 51 FROM tab1 AS cor0
----
-2754
-2907
-4896

onlyif mysql # use DIV operator for integer division
query I rowsort label-2852
SELECT - col2 + col2 DIV cor0.col1 FROM tab1 cor0
----
-52
-52
-89

skipif mysql # not compatible
query I rowsort label-2852
SELECT - col2 + col2 / cor0.col1 FROM tab1 cor0
----
-52
-52
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2853
SELECT cor0.col0 DIV 35 col0 FROM tab2 AS cor0
----
0
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2853
SELECT cor0.col0 / 35 col0 FROM tab2 AS cor0
----
0
2
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2854
SELECT + col1 * ( - col2 ) + - col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2854
SELECT + col1 * ( - col2 ) + - col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 32 ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

query I rowsort
SELECT col0 * + cor0.col1 + - col2 * cor0.col0 FROM tab1 cor0
----
-3008
-6640
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2857
SELECT DISTINCT + + CAST( NULL AS DECIMAL ) * col0 - + col2 * - ( col0 + col1 ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2857
SELECT DISTINCT + + CAST ( NULL AS REAL ) * col0 - + col2 * - ( col0 + col1 ) AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + - col0 * + ( - cor0.col0 ) - - 17 * 33 FROM tab2 AS cor0
----
610
6645
6802

query I rowsort
SELECT ALL - - 0 + col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + col2 * col0 + col1 AS col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT - - ( col2 ) * cor0.col2 + 76 - + col0 FROM tab0 AS cor0
----
1141
42
6711

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) * + col0 col2 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2863
SELECT col1 * - col2 + CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2863
SELECT col1 * - col2 + CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2864
SELECT DISTINCT + cor0.col0 DIV col2 + ( - col2 ) col0 FROM tab1 AS cor0
----
-54
-56
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2864
SELECT DISTINCT + cor0.col0 / col2 + ( - col2 ) col0 FROM tab1 AS cor0
----
-54
-56
-96

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) AS col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL - col2 * cor0.col1 + + cor0.col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT + tab1.col0 * + col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT + 40 + - cor0.col1 FROM tab0 cor0
----
-46
-51
-57

query I rowsort
SELECT + + 65 - - col2 FROM tab2 AS cor0
----
103
91
92

query I rowsort
SELECT - col0 * cor0.col2 + - ( + col1 + + col0 ) FROM tab0 AS cor0
----
-167
-7478
-902

query I rowsort
SELECT DISTINCT + col0 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT col1 + col2 * col1 + - cor0.col2 * + 95 FROM tab0 cor0
----
-211
-237
99

query I rowsort
SELECT 19 + col1 AS col1 FROM tab2 AS cor0
----
36
50
78

query I rowsort
SELECT ALL - 42 + 50 FROM tab0
----
8
8
8

query I rowsort
SELECT - tab1.col2 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT - + cor0.col0 * col0 - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1260
-600
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 73 + cor0.col1 col0 FROM tab0 AS cor0
----
159
164
170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col0 * col2 col0 FROM tab2 AS cor0
----
1323
158184
237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 33 col1 FROM tab0 AS cor0
----
33
33
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * cor0.col1 col1 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - - 18 * - ( col0 ) FROM tab2 AS cor0
----
-126
-1404
-1422

query I rowsort
SELECT - col1 + - 20 + col0 FROM tab0 AS cor0
----
-22
-82
-82

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 AS REAL ) + col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2884
SELECT + + col1 * col0 DIV col1 + col0 + col1 FROM tab1 AS cor0
----
138
173
32

skipif mysql # not compatible
query I rowsort label-2884
SELECT + + col1 * col0 / col1 + col0 + col1 FROM tab1 AS cor0
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-2885
SELECT DISTINCT - col1 * col1 DIV col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-2885
SELECT DISTINCT - col1 * col1 / col1 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2886
SELECT ALL 7 DIV - col0 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2886
SELECT ALL 7 / - col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - 43 * + col1 AS col1 FROM tab0 AS cor0
----
-3698
-3913
-4171

query I rowsort
SELECT - col1 + + 93 * + col2 + col0 AS col0 FROM tab2 AS cor0
----
2437
2487
3596

query I rowsort
SELECT ALL ( + tab2.col1 + ( 61 ) ) * + col2 AS col2 FROM tab2
----
2484
2964
3120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 70 col2 FROM tab2, tab0 AS cor0, tab1 cor1
----
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 89 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT DISTINCT 91 AS col1 FROM tab2, tab0 cor0
----
91

query I rowsort
SELECT ALL col0 * 95 AS col2 FROM tab2
----
665
7410
7505

query I rowsort
SELECT DISTINCT col2 + tab0.col1 * 12 - + col2 FROM tab0
----
1032
1092
1164

query I rowsort
SELECT DISTINCT - cor1.col2 AS col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - 37 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab0 cor2
----
-37

query I rowsort
SELECT ALL + - col1 + col0 + + col1 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col2 * col1 col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT + 12 + + cor0.col2 FROM tab1, tab2, tab2 AS cor0
----
38
39
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2900
SELECT ALL 68 * col0 + col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2900
SELECT ALL 68 * col0 + col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2901
SELECT - col2 * col2 DIV col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2901
SELECT - col2 * col2 / col2 FROM tab1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2902
SELECT col2 DIV + col2 + col2 * - col1 FROM tab1 AS cor0
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-2902
SELECT col2 / + col2 + col2 * - col1 FROM tab1 AS cor0
----
-1247
-1403
-569

query I rowsort
SELECT DISTINCT - + col0 + 30 * - col2 FROM tab0 AS cor0
----
-1014
-2549
-65

query I rowsort
SELECT DISTINCT + col2 * - ( col0 * col2 ) FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT ALL + 22 * 23 FROM tab2 cor0
----
506
506
506

query I rowsort
SELECT ALL + 6 AS col2 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

query I rowsort
SELECT + 56 * cor0.col0 AS col0 FROM tab2, tab0, tab0 cor0
----
27 values hashing to cffefce8bf1d6a1b6081b8a561b8731b

query I rowsort
SELECT ALL - 20 * - col1 AS col0 FROM tab1
----
200
260
520

query I rowsort
SELECT - - col2 * + ( + ( col1 ) ) AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL col0 * 2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + - col0 + + col0 * col0 * cor0.col0 FROM tab1 AS cor0
----
24
262080
511920

query I rowsort
SELECT ALL + - col0 * - col0 + 22 FROM tab1 cor0
----
31
4118
6422

query I rowsort
SELECT DISTINCT col1 - col2 * - col1 FROM tab0 cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2914
SELECT + CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2914
SELECT + CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2915
SELECT ALL + col2 DIV 15 + ( + col1 ) AS col2 FROM tab0 AS cor0
----
88
96
97

skipif mysql # not compatible
query I rowsort label-2915
SELECT ALL + col2 / 15 + ( + col1 ) AS col2 FROM tab0 AS cor0
----
88
96
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - 56 col1 FROM tab0 AS cor0
----
-142
-147
-153

query I rowsort
SELECT DISTINCT - col1 * col1 + 5 AS col1 FROM tab1 AS cor0
----
-164
-671
-95

query I rowsort
SELECT ALL col2 + 69 AS col1 FROM tab0
----
102
151
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-2919
SELECT + col1 DIV + col2 + col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2919
SELECT + col1 / + col2 + col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT 72 + - tab2.col1 FROM tab2, tab0 AS cor0
----
13
41
55

query I rowsort
SELECT col2 + ( tab1.col0 * 16 + col0 ) FROM tab1
----
105
1145
1456

query I rowsort
SELECT + 74 AS col1 FROM tab2, tab2 cor0, tab0 AS cor1
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

query I rowsort
SELECT ALL + 15 + + 65 AS col2 FROM tab2
----
80
80
80

query I rowsort
SELECT DISTINCT cor0.col2 + cor0.col2 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + ( col1 ) + col0 * col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL - col2 - - col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab0, tab1, tab0 cor0, tab2
----
24
35
89

query I rowsort
SELECT + col2 + + cor0.col1 * + 23 FROM tab1 AS cor0
----
287
395
652

query I rowsort
SELECT ALL - - col0 * col1 + 93 FROM tab2 AS cor0
----
1436
310
4695

query I rowsort
SELECT + - col1 * + col1 * - col1 + cor0.col2 FROM tab0 AS cor0
----
636089
753653
912674

query I rowsort
SELECT DISTINCT + col1 * col2 - + ( col1 ) * - col0 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT ALL + col0 + ( col0 ) * + col1 AS col2 FROM tab1
----
1120
704
81

query I rowsort
SELECT - tab1.col1 FROM tab1, tab2, tab2 AS cor0, tab0
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT 39 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT 26 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query I rowsort
SELECT + col0 + - 96 FROM tab2
----
-17
-18
-89

query I rowsort
SELECT + col2 + - 9 * col2 * + col2 + col0 AS col2 FROM tab2
----
-12879
-5980
-6527

query I rowsort
SELECT DISTINCT - col2 + + 41 FROM tab0
----
-41
40
8

query I rowsort
SELECT col2 + + 68 * - col0 FROM tab2
----
-449
-5278
-5334

query I rowsort
SELECT + col0 + + ( - 52 * + col1 ) FROM tab0 AS cor0
----
-4448
-4643
-5009

query I rowsort
SELECT ALL + + col1 + - col2 * - col2 + - col2 * col2 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT col0 + - 34 FROM tab2 AS cor0
----
-27
44
45

query I rowsort
SELECT DISTINCT + + col1 + col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ( + col0 ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - + 31 FROM tab2 AS cor0
----
-31
-31
-31

query I rowsort
SELECT + + 87 * - ( col1 * + ( col2 ) ) + col1 AS col0 FROM tab1 AS cor0
----
-108563
-122122
-49580

query I rowsort
SELECT ALL col1 + - col0 * - col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT - col1 * col0 + col2 AS col1 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT - 33 * + col2 + col1 AS col0 FROM tab2 AS cor0
----
-1237
-799
-860

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2950
SELECT DISTINCT - - CAST( NULL AS SIGNED ) + col1 AS col0 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2950
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) + col1 AS col0 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL col2 - - 17 * col1 AS col0 FROM tab0 AS cor0
----
1495
1629
1650

query I rowsort
SELECT ALL + tab2.col2 * col0 + ( col0 + col1 ) * 27 FROM tab2
----
1215
5594
5727

query I rowsort
SELECT DISTINCT col1 + 24 AS col0 FROM tab0
----
110
115
121

query I rowsort
SELECT DISTINCT - col0 + + tab1.col1 * col1 * - col2 FROM tab1
----
-16304
-36507
-5764

query I rowsort
SELECT - col2 * - ( + col0 ) FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2956
SELECT + tab2.col2 DIV ( + tab2.col1 ) FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2956
SELECT + tab2.col2 / ( + tab2.col1 ) FROM tab2
----
0
0
2

query I rowsort
SELECT + col1 + - col1 * + col0 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT ( - 79 ) * + col2 AS col2 FROM tab0 AS cor0
----
-2607
-6478
-79

query I rowsort
SELECT + - 67 + ( cor0.col1 ) * 99 FROM tab1 AS cor0
----
1220
2507
923

query I rowsort
SELECT - 53 + 18 FROM tab1 AS cor0
----
-35
-35
-35

query I rowsort
SELECT ALL 19 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT ALL + ( col0 ) * tab1.col2 AS col2 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2963
SELECT + 80 + + col2 DIV + col0 FROM tab0 AS cor0
----
80
80
81

skipif mysql # not compatible
query I rowsort label-2963
SELECT + 80 + + col2 / + col0 FROM tab0 AS cor0
----
80
80
81

query I rowsort
SELECT col2 + + 16 AS col1 FROM tab0 AS cor0
----
17
49
98

query I rowsort
SELECT - col2 + col0 * 41 FROM tab2 AS cor0
----
260
3172
3201

query I rowsort
SELECT col2 * col1 + + ( col1 + + col2 ) FROM tab1 AS cor0
----
1357
1484
637

query I rowsort
SELECT - + 89 * - col0 + col0 AS col2 FROM tab2 AS cor0
----
630
7020
7110

query I rowsort
SELECT ALL ( + tab2.col0 ) * - col0 FROM tab2
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2969
SELECT CAST( NULL AS SIGNED ) + col0 + col1 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2969
SELECT CAST ( NULL AS INTEGER ) + col0 + col1 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 53 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

onlyif mysql # use DIV operator for integer division
query I rowsort label-2971
SELECT 90 DIV tab2.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 2fb45a4d17d497a4c43fa69a577a1525

skipif mysql # not compatible
query I rowsort label-2971
SELECT 90 / tab2.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 2fb45a4d17d497a4c43fa69a577a1525

onlyif mysql # use DIV operator for integer division
query I rowsort label-2972
SELECT + col0 + col2 DIV 83 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2972
SELECT + col0 + col2 / 83 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - col0 + - 78 * col0 FROM tab1 cor0
----
-237
-5056
-6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2974
SELECT - cor0.col1 * CAST( cor0.col1 AS SIGNED ) FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-2974
SELECT - cor0.col1 * CAST ( cor0.col1 AS INTEGER ) FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2975
SELECT - col0 DIV 96 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2975
SELECT - col0 / 96 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 11 AS col2 FROM tab1
----
11
11
11

query I rowsort
SELECT ALL + - col2 * + col2 AS col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT + + col2 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 + - 28 ) col1 FROM tab1
----
-26
-29
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2980
SELECT ALL - col0 - tab0.col1 * + CAST( NULL AS SIGNED ) * + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2980
SELECT ALL - col0 - tab0.col1 * + CAST ( NULL AS INTEGER ) * + col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 36 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 3bcd07d22b62d2042b499253b1c13d9e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2982
SELECT DISTINCT - CAST( cor1.col1 AS SIGNED ) FROM tab0, tab1 AS cor0, tab1 cor1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-2982
SELECT DISTINCT - CAST ( cor1.col1 AS INTEGER ) FROM tab0, tab1 AS cor0, tab1 cor1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2983
SELECT DISTINCT col0 * col2 DIV ( - col0 ) - + col1 AS col1 FROM tab2
----
-55
-58
-85

skipif mysql # not compatible
query I rowsort label-2983
SELECT DISTINCT col0 * col2 / ( - col0 ) - + col1 AS col1 FROM tab2
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2984
SELECT - col2 * - col0 * col1 + - 77 * col0 + col1 DIV + 9 AS col0 FROM tab1
----
31553
3983
93681

skipif mysql # not compatible
query I rowsort label-2984
SELECT - col2 * - col0 * col1 + - 77 * col0 + col1 / + 9 AS col0 FROM tab1
----
31553
3983
93681

query I rowsort
SELECT + col0 + - col1 * + ( tab2.col2 ) * - col2 FROM tab2
----
22606
24627
39962

query I rowsort
SELECT + col1 * + 37 + + col2 FROM tab0 cor0
----
3215
3449
3590

query I rowsort
SELECT DISTINCT col0 + + col0 * col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT ALL cor0.col1 * 59 * + col2 AS col0 FROM tab0 AS cor0
----
167442
440258
5723

query I rowsort
SELECT ALL - col2 * 87 - - col0 FROM tab1 AS cor0
----
-4695
-4895
-8272

query I rowsort
SELECT + + col1 * col2 - cor0.col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT - col0 + ( col1 + - col2 ) AS col0 FROM tab1 AS cor0
----
-111
-163
-31

query I rowsort
SELECT DISTINCT col1 * col1 + 91 FROM tab2 AS cor0
----
1052
3572
380

query I rowsort
SELECT DISTINCT col2 + - col2 * + col0 AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT cor0.col1 * + cor0.col0 - + 47 FROM tab2 cor0
----
1296
170
4555

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2995
SELECT DISTINCT col0 + + CAST( col2 AS SIGNED ) * col2 FROM tab0 AS cor0
----
1113
36
6813

skipif mysql # not compatible
query I rowsort label-2995
SELECT DISTINCT col0 + + CAST ( col2 AS INTEGER ) * col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT cor0.col2 + + ( - cor0.col0 ) - + col2 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col0 * col0 + - col1 * + col1 - col2 AS col0 FROM tab2 AS cor0
----
-939
2577
5914

query I rowsort
SELECT ALL - - col2 + - col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL - - col1 * col2 + ( - col1 ) AS col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT + - col2 * col1 - - col0 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT + - col1 * + col1 + - col1 FROM tab0 cor0
----
-7482
-8372
-9506

query I rowsort
SELECT col0 + 81 * col1 FROM tab0 AS cor0
----
6990
7460
7892

query I rowsort
SELECT - 35 + + col0 FROM tab2 AS cor0
----
-28
43
44

query I rowsort
SELECT + + cor0.col1 * + 20 * col2 AS col2 FROM tab0 AS cor0
----
149240
1940
56760

query I rowsort
SELECT ( + 23 ) * - cor0.col0 AS col1 FROM tab1 AS cor0
----
-1472
-1840
-69

query I rowsort
SELECT ALL - + ( + col2 ) + 0 * col1 + + cor0.col1 AS col2 FROM tab0 cor0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * + col1 col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT - 14 + + col1 * col0 AS col2 FROM tab1 AS cor0
----
1026
626
64

query I rowsort
SELECT - 52 * cor0.col0 AS col2 FROM tab1 AS cor0
----
-156
-3328
-4160

query I rowsort
SELECT DISTINCT - + col2 * - col0 * + 61 AS col2 FROM tab0 AS cor0
----
2135
445178
48312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3011
SELECT ALL - - 24 DIV + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3011
SELECT ALL - - 24 / + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3012
SELECT DISTINCT - col0 * col1 DIV col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3012
SELECT DISTINCT - col0 * col1 / col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - 29 * col1 AS col0 FROM tab0 AS cor0
----
-2494
-2639
-2813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3014
SELECT - 37 + + col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3014
SELECT - 37 + + col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 10 * - 20 AS col2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to b53ee4caebae2682b84432f871582b7d

query I rowsort
SELECT 97 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1261
-2522
-970

onlyif mysql # use DIV operator for integer division
query I rowsort label-3017
SELECT ALL + + ( col1 ) DIV 98 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3017
SELECT ALL + + ( col1 ) / 98 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col1 + - cor0.col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL - - 0 * + col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * cor0.col2 + ( + col0 ) FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - + col0 * - col1 + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - col1 + + 30 AS col2 FROM tab2 AS cor0
----
-1
-29
13

query I rowsort
SELECT DISTINCT - + col2 * 6 * + cor0.col1 AS col0 FROM tab1 cor0
----
-3420
-7488
-8424

query I rowsort
SELECT DISTINCT + - col1 * ( - col0 ) FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3025
SELECT - col0 DIV col0 + 66 AS col2 FROM tab1
----
65
65
65

skipif mysql # not compatible
query I rowsort label-3025
SELECT - col0 / col0 + 66 AS col2 FROM tab1
----
65
65
65

query I rowsort
SELECT ALL 26 * - col1 + col0 * col0 FROM tab0 AS cor0
----
-1297
-1660
5555

query I rowsort
SELECT DISTINCT 6 AS col2 FROM tab0 AS cor0
----
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3029
SELECT DISTINCT CAST( NULL AS SIGNED ) * - 79 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3029
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - 79 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - ( - cor0.col1 ) + + col2 * 98 FROM tab0 AS cor0
----
195
3320
8127

query I rowsort
SELECT ALL - col0 + - 67 * + col2 AS col0 FROM tab2 AS cor0
----
-1816
-1820
-2625

query I rowsort
SELECT + - 11 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3033
SELECT DISTINCT ( col1 ) * + col0 + CAST( + col2 AS SIGNED ) + + col0 AS col2 FROM tab0
----
2121
3431
8270

skipif mysql # not compatible
query I rowsort label-3033
SELECT DISTINCT ( col1 ) * + col0 + CAST ( + col2 AS INTEGER ) + + col0 AS col2 FROM tab0
----
2121
3431
8270

query I rowsort
SELECT col1 * tab1.col2 + col0 * + col1 AS col2 FROM tab1
----
1210
1482
2288

query I rowsort
SELECT - cor0.col0 + - col2 * cor0.col1 * 14 AS col2 FROM tab2 AS cor0
----
-11725
-21554
-9123

query I rowsort
SELECT DISTINCT - ( 41 ) FROM tab0 AS cor0
----
-41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col1 ) + cor0.col0 col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT - cor0.col1 + ( col0 ) FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT + col1 * + ( - col1 ) + cor0.col1 + + 33 AS col2 FROM tab0 cor0
----
-7277
-8157
-9279

query I rowsort
SELECT DISTINCT - - col0 + + col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT col1 * col0 + 3 * 74 + + col0 * ( tab2.col0 ) AS col0 FROM tab2
----
10908
488
7806

query I rowsort
SELECT ALL - 40 + - col1 * 75 FROM tab1
----
-1015
-1990
-790

query I rowsort
SELECT DISTINCT 57 + cor1.col1 FROM tab2, tab0 cor0, tab1 cor1
----
67
70
83

query I rowsort
SELECT DISTINCT + tab2.col1 + 48 * col1 AS col1 FROM tab2
----
1519
2891
833

onlyif mysql # use DIV operator for integer division
query I rowsort label-3045
SELECT ALL 76 DIV - cor0.col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to b17a2e6dcfa714ddcffb36ed9098aae4

skipif mysql # not compatible
query I rowsort label-3045
SELECT ALL 76 / - cor0.col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to b17a2e6dcfa714ddcffb36ed9098aae4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3046
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3046
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3047
SELECT ALL - + col2 DIV col1 - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3047
SELECT ALL - + col2 / col1 - col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT 0 + tab2.col2 * + col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col1 + - ( tab2.col2 * + col0 ) AS col0 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT ALL col1 + + col1 + 57 * + col1 * - cor0.col1 FROM tab2 AS cor0
----
-16439
-198299
-54715

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 - col2 col1 FROM tab0 AS cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + - col1 col1 FROM tab1 cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - col0 col2 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT - col0 + col2 * + cor0.col2 FROM tab1 AS cor0
----
2913
3185
9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3055
SELECT + CAST( NULL AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3055
SELECT + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-3056
SELECT DISTINCT col1 * - col0 + 4 DIV col0 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-3056
SELECT DISTINCT col1 * - col0 + 4 / col0 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + + 5 AS col1 FROM tab2 AS cor0
----
5
5
5

query I rowsort
SELECT DISTINCT - - col1 * - col0 + col2 AS col1 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL + + ( cor0.col0 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + + 81 + - col0 AS col0 FROM tab2 AS cor0
----
2
3
74

query I rowsort
SELECT DISTINCT - 42 - col1 FROM tab0 AS cor0
----
-128
-133
-139

query I rowsort
SELECT - + 93 * + col2 FROM tab2 AS cor0
----
-2418
-2511
-3534

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col1 ) col2 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - 80 + col0 + col0 FROM tab1 AS cor0
----
-74
48
80

query I rowsort
SELECT + + 46 + cor0.col0 AS col2 FROM tab2 AS cor0
----
124
125
53

query I rowsort
SELECT DISTINCT + 96 + col2 FROM tab1 AS cor0
----
150
153
192

query I rowsort
SELECT ALL 51 AS col2 FROM tab1, tab2, tab1 cor0
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3069
SELECT ALL + ( - col1 ) DIV ( - 48 ) FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3069
SELECT ALL + ( - col1 ) / ( - 48 ) FROM tab2
----
0
0
1

query I rowsort
SELECT DISTINCT 34 AS col1 FROM tab0 AS cor0
----
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3071
SELECT - col1 * CAST( NULL AS SIGNED ) - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3071
SELECT - col1 * CAST ( NULL AS INTEGER ) - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * + 54 + - ( col0 ) FROM tab1 AS cor0
----
1401
476
622

query I rowsort
SELECT - col2 + col2 * + col0 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3074
SELECT + col1 - CAST( NULL AS DECIMAL ) * 89 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3074
SELECT + col1 - CAST ( NULL AS REAL ) * 89 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3075
SELECT DISTINCT + CAST( col1 AS SIGNED ) * + col0 AS col0 FROM tab1 cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-3075
SELECT DISTINCT + CAST ( col1 AS INTEGER ) * + col0 AS col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL col0 * - 92 FROM tab1 AS cor0
----
-276
-5888
-7360

onlyif mysql # use DIV operator for integer division
query I rowsort label-3077
SELECT + col0 + - col2 DIV - col2 AS col2 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-3077
SELECT + col0 + - col2 / - col2 AS col2 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT col2 + + col0 * col1 + ( 88 * - col1 ) FROM tab0 AS cor0
----
-5140
-5471
173

query I rowsort
SELECT ALL + 83 * col0 FROM tab1
----
249
5312
6640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3080
SELECT CAST( - col0 AS SIGNED ) + + col0 + - col2 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-3080
SELECT CAST ( - col0 AS INTEGER ) + + col0 + - col2 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT 14 + + ( + cor0.col0 ) * ( - col1 ) FROM tab0 AS cor0
----
-2050
-3381
-8085

query I rowsort
SELECT + + 37 + + 91 * col2 * - col1 FROM tab0 AS cor0
----
-258221
-679005
-8790

query I rowsort
SELECT - + cor0.col1 + col1 * - col0 AS col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT + 82 * col2 AS col2 FROM tab0 cor0
----
2706
6724
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3085
SELECT + - cor0.col2 + col1 * CAST( - col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-157
-265
-730

skipif mysql # not compatible
query I rowsort label-3085
SELECT + - cor0.col2 + col1 * CAST ( - col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT - cor0.col0 + + 47 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 4701f3a4cf2e27f4365f80179475b3f5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3087
SELECT DISTINCT - - CAST( NULL AS SIGNED ) + ( + cor0.col2 ) / + col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3087
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) + ( + cor0.col2 ) / + col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 + 94 FROM tab1 AS cor0
----
158
174
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + 7 col0 FROM tab2 AS cor0
----
33
34
45

query I rowsort
SELECT DISTINCT 72 + cor0.col0 AS col0 FROM tab2 AS cor0
----
150
151
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3091
SELECT 99 DIV col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3091
SELECT 99 / col2 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( 30 ) col1 FROM tab1 AS cor0
----
30
30
30

query I rowsort
SELECT + ( 65 ) FROM tab1 AS cor0
----
65
65
65

query I rowsort
SELECT col2 + 94 AS col0 FROM tab1 AS cor0
----
148
151
190

query I rowsort
SELECT ALL + 59 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3096
SELECT ALL CAST( NULL AS DECIMAL ) + col1 * + tab0.col2 / + col1 - 78 col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3096
SELECT ALL CAST ( NULL AS REAL ) + col1 * + tab0.col2 / + col1 - 78 col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 96 * - ( - cor0.col0 ) col1 FROM tab1 AS cor0
----
288
6144
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3098
SELECT DISTINCT - ( - col2 ) DIV - col0 FROM tab2 cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-3098
SELECT DISTINCT - ( - col2 ) / - col0 FROM tab2 cor0
----
-3
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3099
SELECT + CAST( - cor0.col0 AS SIGNED ) * - col1 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-3099
SELECT + CAST ( - cor0.col0 AS INTEGER ) * - col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + 74 AS col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
74

query I rowsort
SELECT ALL - col0 * + tab2.col2 * col0 FROM tab2
----
-1323
-158184
-237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 col2 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + col1 * - 12 + col1 AS col2 FROM tab2 AS cor0
----
-187
-341
-649

query I rowsort
SELECT ALL 56 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3105
SELECT + col1 + + CAST( NULL AS SIGNED ) * - col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3105
SELECT + col1 + + CAST ( NULL AS INTEGER ) * - col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + - 12 + - 92 FROM tab2 AS cor0
----
-66
-77
-78

query I rowsort
SELECT - col0 - ( - col2 ) FROM tab1
----
-7
16
51

query I rowsort
SELECT col1 * col0 + tab1.col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT DISTINCT - col1 - ( + col0 ) AS col0 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3110
SELECT DISTINCT - col1 DIV - col0 + col2 DIV col0 AS col2 FROM tab2 AS cor0
----
0
7

skipif mysql # not compatible
query I rowsort label-3110
SELECT DISTINCT - col1 / - col0 + col2 / col0 AS col2 FROM tab2 AS cor0
----
0
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3111
SELECT DISTINCT col2 + - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3111
SELECT DISTINCT col2 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col2 + - cor0.col2 * - col1 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 + + 73 + - cor0.col2 col1 FROM tab2 AS cor0
----
6131
6276
95

query I rowsort
SELECT ALL + + col2 + + 84 * + col0 FROM tab2 AS cor0
----
615
6578
6674

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 97 ) col0 FROM tab2 AS cor0
----
97
97
97

query I rowsort
SELECT + - 37 + + 51 * col0 FROM tab1 AS cor0
----
116
3227
4043

query I rowsort
SELECT DISTINCT + 95 * + col2 AS col0 FROM tab2 AS cor0
----
2470
2565
3610

query I rowsort
SELECT DISTINCT ( + 4 ) FROM tab1 AS cor0
----
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3119
SELECT DISTINCT col2 DIV col0 - + col0 FROM tab1 cor0
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-3119
SELECT DISTINCT col2 / col0 - + col0 FROM tab1 cor0
----
-64
-79
15

query I rowsort
SELECT col0 + 2 FROM tab1
----
5
66
82

query I rowsort
SELECT DISTINCT + 25 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3122
SELECT DISTINCT - cor0.col2 * + CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3122
SELECT DISTINCT - cor0.col2 * + CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0
----
NULL

query I rowsort
SELECT + 1 + col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT + + col1 + - col2 * + col1 FROM tab0 cor0
----
-2752
-7371
0

query I rowsort
SELECT - cor0.col2 + + col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT 83 * tab1.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 7cfac30b9a8f0efdf067d08fb36c850d

query I rowsort
SELECT DISTINCT - tab2.col1 * - ( - tab2.col0 ) AS col2 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3128
SELECT DISTINCT - + col0 DIV col1 + 86 AS col1 FROM tab0 AS cor0
----
86

skipif mysql # not compatible
query I rowsort label-3128
SELECT DISTINCT - + col0 / col1 + 86 AS col1 FROM tab0 AS cor0
----
86

query I rowsort
SELECT ALL + col2 * col0 + - 76 AS col2 FROM tab2 AS cor0
----
113
1952
2926

query I rowsort
SELECT + col1 + col0 * + ( - 33 ) AS col1 FROM tab0 cor0
----
-1058
-2846
-706

onlyif mysql # use DIV operator for integer division
query I rowsort label-3131
SELECT DISTINCT + col2 DIV + cor0.col1 AS col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-3131
SELECT DISTINCT + col2 / + cor0.col1 AS col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT ALL 47 + - col0 * + ( + col0 ) AS col0 FROM tab0 AS cor0
----
-1178
-529
-7874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col2 FROM tab2, tab1 cor0
----
10
13
26

query I rowsort
SELECT col2 + - col1 + + ( col1 ) * + col0 AS col2 FROM tab1
----
106
1123
687

query I rowsort
SELECT + ( col0 ) * + col2 * + ( col2 + - col2 ) FROM tab0
----
0
0
0

query I rowsort
SELECT col0 * col1 - - col0 AS col2 FROM tab0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-3137
SELECT ALL - cor0.col0 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3137
SELECT ALL - cor0.col0 / col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

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 76 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT DISTINCT col2 + + col2 * 53 AS col1 FROM tab2
----
1404
1458
2052

query I rowsort
SELECT col1 * col1 + + col1 * - 78 AS col1 FROM tab0
----
1183
1843
688

query I rowsort
SELECT ALL ( col2 ) * + col1 * - col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT DISTINCT - col0 + - col1 * + 49 AS col2 FROM tab1 AS cor0
----
-1277
-554
-717

query I rowsort
SELECT ALL + cor0.col2 + - col0 * - 61 FROM tab2 AS cor0
----
454
4784
4857

onlyif mysql # use DIV operator for integer division
query I rowsort label-3145
SELECT + col2 + - col1 DIV 54 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3145
SELECT + col2 + - col1 / 54 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + - 93 * col0 AS col1 FROM tab2 AS cor0
----
-651
-7254
-7347

query I rowsort
SELECT - + col1 + cor0.col2 * + 32 AS col1 FROM tab2 cor0
----
1199
773
833

query I rowsort
SELECT - - col0 * + col1 + + col2 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-3149
SELECT + col0 DIV 24 + 57 FROM tab0 cor0
----
58
58
60

skipif mysql # not compatible
query I rowsort label-3149
SELECT + col0 / 24 + 57 FROM tab0 cor0
----
58
58
60

query I rowsort
SELECT - col1 + ( - col1 ) FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT col0 + 58 * + col0 FROM tab1 AS cor0
----
177
3776
4720

query I rowsort
SELECT ALL + col0 + + col2 * - col0 + 91 FROM tab1
----
-3493
-68
-7509

query I rowsort
SELECT ALL + 85 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT DISTINCT - 35 * col1 AS col1 FROM tab0 cor0
----
-3010
-3185
-3395

query I rowsort
SELECT ALL - - 29 + - 33 AS col1 FROM tab1 AS cor0
----
-4
-4
-4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3156
SELECT CAST( NULL AS DECIMAL ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3156
SELECT CAST ( NULL AS REAL ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + 92 * col1 AS col1 FROM tab0 AS cor0
----
7912
8372
8924

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 52 * col2 * col1 col0 FROM tab1 AS cor0
----
29640
64896
73008

query I rowsort
SELECT + cor0.col2 + - 62 + cor0.col1 FROM tab1 cor0
----
18
47
5

query I rowsort
SELECT ALL 73 * 93 AS col0 FROM tab2
----
6789
6789
6789

query I rowsort
SELECT 33 + - tab0.col1 AS col2 FROM tab0
----
-53
-58
-64

query I rowsort
SELECT ALL ( col2 ) * + col0 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3163
SELECT - + ( + col2 ) * + col0 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-3163
SELECT - + ( + col2 ) * + col0 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 57 col2 FROM tab1 cor0
----
57
57
57

query I rowsort
SELECT DISTINCT 29 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2 cor1
----
29

query I rowsort
SELECT DISTINCT + 80 AS col2 FROM tab0
----
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 col2 FROM tab1
----
-97
-97
-97

query I rowsort
SELECT + 52 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3169
SELECT CAST( NULL AS SIGNED ) * cor1.col2 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3169
SELECT CAST ( NULL AS INTEGER ) * cor1.col2 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT col1 * 37 AS col2 FROM tab0
----
3182
3367
3589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 5 col1 FROM tab1
----
5
5
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3172
SELECT 75 DIV + col0 + + col2 FROM tab0 AS cor0
----
3
36
82

skipif mysql # not compatible
query I rowsort label-3172
SELECT 75 / + col0 + + col2 FROM tab0 AS cor0
----
3
36
82

query I rowsort
SELECT col2 + 17 AS col1 FROM tab2 cor0
----
43
44
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * col1 col1 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col0 * + 39 col0 FROM tab2
----
273
3042
3081

query I rowsort
SELECT DISTINCT 93 * + 72 AS col2 FROM tab0, tab1 AS cor0
----
6696

onlyif mysql # use DIV operator for integer division
query I rowsort label-3177
SELECT ALL - col2 + + 72 DIV 17 AS col1 FROM tab2 cor0
----
-22
-23
-34

skipif mysql # not compatible
query I rowsort label-3177
SELECT ALL - col2 + + 72 / 17 AS col1 FROM tab2 cor0
----
-22
-23
-34

query I rowsort
SELECT DISTINCT + ( cor0.col0 ) AS col0 FROM tab0, tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - + col1 * cor0.col2 * col0 AS col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3180
SELECT ALL + - col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3180
SELECT ALL + - col0 / + col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + ( 67 ) * + col0 FROM tab2 AS cor0
----
469
5226
5293

query I rowsort
SELECT ( + 33 ) FROM tab1 AS cor0
----
33
33
33

query I rowsort
SELECT ALL + ( + 90 ) * col1 AS col2 FROM tab2 AS cor0
----
1530
2790
5310

query I rowsort
SELECT DISTINCT - 68 + 26 * col1 FROM tab0 cor0
----
2168
2298
2454

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3185
SELECT ALL + CAST( col0 AS SIGNED ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-3185
SELECT ALL + CAST ( col0 AS INTEGER ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3186
SELECT DISTINCT + col2 DIV + col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3186
SELECT DISTINCT + col2 / + col1 FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3187
SELECT ALL col2 + col2 DIV col0 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-3187
SELECT ALL col2 + col2 / col0 FROM tab1 AS cor0
----
57
72
97

query I rowsort
SELECT DISTINCT + + ( col0 ) + - col1 AS col0 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) * col1 * - cor0.col0 col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL col0 - + col1 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT 74 + ( tab0.col1 ) AS col1 FROM tab0, tab2 cor0
----
160
165
171

query I rowsort
SELECT DISTINCT 49 AS col2 FROM tab1 AS cor0
----
49

query I rowsort
SELECT + + 75 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
139
155
78

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 DISTINCT 76 + cor0.col2 FROM tab0 AS cor0
----
109
158
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3196
SELECT ALL - - col0 * col2 + - CAST( col1 AS SIGNED ) * col0 col0 FROM tab1 AS cor0
----
3008
6640
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3196
SELECT ALL - - col0 * col2 + - CAST ( col1 AS INTEGER ) * col0 col0 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT - + 84 * - col0 + - 18 + col0 FROM tab2 AS cor0
----
577
6612
6697

query I rowsort
SELECT ALL + - col1 * cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT + ( col0 ) - - col0 AS col0 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3200
SELECT + col2 * col1 + col2 DIV col1 AS col0 FROM tab1 AS cor0
----
1255
1406
575

skipif mysql # not compatible
query I rowsort label-3200
SELECT + col2 * col1 + col2 / col1 AS col0 FROM tab1 AS cor0
----
1255
1406
575

query I rowsort
SELECT DISTINCT + - col2 * cor0.col0 * + col1 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT - 77 * + col2 - - 10 AS col1 FROM tab1 AS cor0
----
-4148
-4379
-7382

query I rowsort
SELECT ALL 59 * + 52 + cor1.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to adc1ef49ccdb8fc3558bd017fbd54d3d

query I rowsort
SELECT 60 + + col2 * - ( + 4 ) FROM tab0 AS cor0
----
-268
-72
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-3205
SELECT + cor0.col1 * col0 + - ( - col1 ) * + cor0.col1 + col2 * ( + cor0.col1 ) DIV - col0 AS col2 FROM tab0 AS cor0
----
12802
16297
9342

skipif mysql # not compatible
query I rowsort label-3205
SELECT + cor0.col1 * col0 + - ( - col1 ) * + cor0.col1 + col2 * ( + cor0.col1 ) / - col0 AS col2 FROM tab0 AS cor0
----
12802
16297
9342

query I rowsort
SELECT + tab2.col2 - col0 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ( - col0 ) * + col1 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - col2 + - col0 + 52 AS col0 FROM tab2 AS cor0
----
-52
-65
18

query I rowsort
SELECT ALL + - cor0.col0 + 22 FROM tab1 AS cor0
----
-42
-58
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-3210
SELECT - - cor0.col1 DIV ( - 52 ) + - col0 + - ( + ( - col0 ) + - col2 ) AS col1 FROM tab0 cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-3210
SELECT - - cor0.col1 / ( - 52 ) + - col0 + - ( + ( - col0 ) + - col2 ) AS col1 FROM tab0 cor0
----
0
32
81

query I rowsort
SELECT DISTINCT col1 * col1 + 60 AS col1 FROM tab0
----
7456
8341
9469

query I rowsort
SELECT - tab1.col2 * - tab1.col1 + col2 * col1 + - tab1.col0 FROM tab1
----
1076
2416
2805

query I rowsort
SELECT col0 + col0 + - ( + col1 + col1 ) * - col2 FROM tab1
----
1268
2656
2814

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 + col2 ) * + col2 col0 FROM tab0
----
-14186
-3927
-98

query I rowsort
SELECT DISTINCT tab1.col2 * - 33 FROM tab1, tab2 AS cor0
----
-1782
-1881
-3168

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 59 + + col2 col1 FROM tab2
----
85
86
97

query I rowsort
SELECT + 88 + cor1.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 04c32dfeb6584e905d02ba83a8cad72e

onlyif mysql # use DIV operator for integer division
query I rowsort label-3218
SELECT DISTINCT + cor0.col2 DIV col1 + - 22 * col0 AS col0 FROM tab1 AS cor0
----
-1403
-1753
-64

skipif mysql # not compatible
query I rowsort label-3218
SELECT DISTINCT + cor0.col2 / col1 + - 22 * col0 AS col0 FROM tab1 AS cor0
----
-1403
-1753
-64

query I rowsort
SELECT 72 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT + + col0 + + col1 * col1 AS col2 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT + col2 * col1 + + col0 * - cor0.col2 FROM tab1 AS cor0
----
-3078
-6432
1242

query I rowsort
SELECT ALL + col2 * col0 + 82 FROM tab1 AS cor0
----
244
3730
7762

query I rowsort
SELECT DISTINCT col1 + + col0 AS col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT + cor0.col1 + + col0 * + col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3225
SELECT DISTINCT col2 + + CAST( NULL AS SIGNED ) / col2 col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3225
SELECT DISTINCT col2 + + CAST ( NULL AS INTEGER ) / col2 col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3226
SELECT + cor0.col2 + CAST( NULL AS SIGNED ) / ( cor0.col0 * 87 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3226
SELECT + cor0.col2 + CAST ( NULL AS INTEGER ) / ( cor0.col0 * 87 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + col1 * 29 FROM tab1 AS cor0
----
280
364
728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + - ( + 38 ) col0 FROM tab0 AS cor0
----
-14
-3
51

query I rowsort
SELECT DISTINCT + col2 + 18 AS col1 FROM tab0 AS cor0
----
100
19
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-3230
SELECT ALL + cor0.col0 DIV + col2 - + ( cor0.col1 ) * 80 * + 68 AS col2 FROM tab0 AS cor0
----
-467840
-495039
-527645

skipif mysql # not compatible
query I rowsort label-3230
SELECT ALL + cor0.col0 / + col2 - + ( cor0.col1 ) * 80 * + 68 AS col2 FROM tab0 AS cor0
----
-467840
-495039
-527645

query I rowsort
SELECT col1 * - ( col1 ) + - cor0.col2 * + col1 AS col1 FROM tab2 AS cor0
----
-1798
-5015
-935

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3232
SELECT CAST( NULL AS SIGNED ) + tab2.col0 * + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3232
SELECT CAST ( NULL AS INTEGER ) + tab2.col0 * + col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3233
SELECT DISTINCT + + col0 DIV col1 + - col2 * - col2 FROM tab0 cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-3233
SELECT DISTINCT + + col0 / col1 + - col2 * - col2 FROM tab0 cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col1 ) * cor0.col0 * col0 + col1 col2 FROM tab2 AS cor0
----
106114
1550
359015

query I rowsort
SELECT - 63 * col2 FROM tab0 AS cor0
----
-2079
-5166
-63

query I rowsort
SELECT ALL - 27 * - col2 * col2 FROM tab2 AS cor0
----
18252
19683
38988

query I rowsort
SELECT + 10 * + 72 + col2 AS col0 FROM tab2 cor0
----
746
747
758

query I rowsort
SELECT DISTINCT 72 * - col1 FROM tab0 cor0
----
-6192
-6552
-6984

query I rowsort
SELECT ALL + col1 + - col1 + col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL ( col0 ) * 54 + + col1 + + col0 * + col1 * 22 FROM tab0 AS cor0
----
183075
46790
76677

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 * col2 col2 FROM tab0 AS cor0
----
-3201
-7954
-97

query I rowsort
SELECT ALL - - ( + cor0.col0 ) * 81 + ( - col0 + + 48 * cor0.col0 ) FROM tab2 AS cor0
----
10112
896
9984

query I rowsort
SELECT - 99 - + col0 AS col2 FROM tab2 cor0
----
-106
-177
-178

query I rowsort
SELECT DISTINCT col0 - + col0 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT col0 + col2 + + col1 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT - col0 + + col2 * col0 AS col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT 95 * 28 FROM tab1, tab1 AS cor0
----
9 values hashing to 5f672485374dec5bd5f65144b011f6df

query I rowsort
SELECT DISTINCT + - cor0.col2 + + col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - + col2 + + ( col0 ) * col0 * col0 AS col2 FROM tab1 AS cor0
----
-27
262087
511904

query I rowsort
SELECT 62 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 98 col0 FROM tab1 AS cor0
----
1274
2548
980

onlyif mysql # use DIV operator for integer division
query I rowsort label-3252
SELECT ALL col1 + - col0 DIV col0 AS col2 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-3252
SELECT ALL col1 + - col0 / col0 AS col2 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT - 7 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + - col2 * + col2 col1 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT ALL + 99 + - col0 FROM tab2 AS cor0
----
20
21
92

query I rowsort
SELECT 59 + + 54 FROM tab0 AS cor0
----
113
113
113

onlyif mysql # use DIV operator for integer division
query I rowsort label-3257
SELECT DISTINCT + - 65 * col2 DIV - col0 FROM tab0 AS cor0
----
1
59
89

skipif mysql # not compatible
query I rowsort label-3257
SELECT DISTINCT + - 65 * col2 / - col0 FROM tab0 AS cor0
----
1
59
89

query I rowsort
SELECT 92 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT - - ( - ( col1 ) ) * 36 FROM tab2 AS cor0
----
-1116
-2124
-612

query I rowsort
SELECT + col2 + col2 + col1 AS col1 FROM tab1 AS cor0
----
124
134
205

onlyif mysql # use DIV operator for integer division
query I rowsort label-3261
SELECT + - col1 + + col2 DIV - col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3261
SELECT + - col1 + + col2 / - col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3262
SELECT DISTINCT 22 * + col1 * CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3262
SELECT DISTINCT 22 * + col1 * CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT ( + col1 ) * + 68 AS col2 FROM tab2
----
1156
2108
4012

query I rowsort
SELECT + col1 * - col2 * ( - col2 * col0 ) AS col1 FROM tab1
----
2079360
227448
9584640

query I rowsort
SELECT - col2 + col0 + - 81 FROM tab1 AS cor0
----
-132
-74
-97

query I rowsort
SELECT - col2 + + col1 + cor0.col1 AS col1 FROM tab0 AS cor0
----
100
139
193

onlyif mysql # use DIV operator for integer division
query I rowsort label-3267
SELECT DISTINCT - - 88 DIV col0 AS col0 FROM tab1 AS cor0
----
1
29

skipif mysql # not compatible
query I rowsort label-3267
SELECT DISTINCT - - 88 / col0 AS col0 FROM tab1 AS cor0
----
1
29

query I rowsort
SELECT col0 + - 28 AS col1 FROM tab2 cor0
----
-21
50
51

query I rowsort
SELECT - + col0 + col1 + 37 FROM tab2 AS cor0
----
-25
18
61

query I rowsort
SELECT + 5 + - col2 AS col2 FROM tab2
----
-21
-22
-33

query I rowsort
SELECT DISTINCT + + col1 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + 13 + col2 FROM tab1
----
109
67
70

query I rowsort
SELECT ( - col0 ) + col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + 58 + - tab1.col2 * col1 FROM tab1
----
-1190
-1346
-512

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3275
SELECT col2 + - col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3275
SELECT col2 + - col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 + col1 + col1 AS col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT + col0 + ( + 62 ) FROM tab0 AS cor0
----
151
86
97

query I rowsort
SELECT ALL + 8 * col2 AS col0 FROM tab0
----
264
656
8

query I rowsort
SELECT col0 + 6 * - cor0.col1 FROM tab0 AS cor0
----
-457
-492
-547

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3280
SELECT DISTINCT + CAST( NULL AS SIGNED ) - - ( + cor0.col2 ) FROM tab1, tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3280
SELECT DISTINCT + CAST ( NULL AS INTEGER ) - - ( + cor0.col2 ) FROM tab1, tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3281
SELECT - + CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3281
SELECT - + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + ( 53 ) FROM tab0 AS cor0
----
53

query I rowsort
SELECT ALL - col2 * 72 FROM tab0
----
-2376
-5904
-72

query I rowsort
SELECT + col2 * + 94 FROM tab0
----
3102
7708
94

query I rowsort
SELECT DISTINCT col0 * - ( ( - tab0.col2 ) ) AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT - col1 * + tab1.col0 + + 85 - - col0 * + ( 47 ) FROM tab1
----
148
2453
2805

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 * + tab1.col1 col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT ( 80 ) FROM tab1, tab2 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 * 6 col1 FROM tab1
----
18
384
480

query I rowsort
SELECT + col0 * col1 * - col2 AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT - - col2 + - col0 + ( 40 * cor0.col2 ) FROM tab2 AS cor0
----
1100
1479
988

query I rowsort
SELECT + 96 * col0 + + col2 * + col2 FROM tab0 AS cor0
----
15268
3361
3393

query I rowsort
SELECT 2 FROM tab1, tab2 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT + col0 * + col1 - + ( col0 * col1 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - + col2 * col2 * ( col1 ) + col1 + col1 * col0 AS col0 FROM tab0 AS cor0
----
-603694
-91504
3395

query I rowsort
SELECT DISTINCT - - col0 * col1 + 53 * col1 FROM tab0 cor0
----
12922
6622
8536

query I rowsort
SELECT DISTINCT 16 + - col2 FROM tab0 AS cor0
----
-17
-66
15

query I rowsort
SELECT - cor0.col0 + + col0 AS col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3299
SELECT + + 98 + col1 DIV - col1 AS col2 FROM tab0 AS cor0
----
97
97
97

skipif mysql # not compatible
query I rowsort label-3299
SELECT + + 98 + col1 / - col1 AS col2 FROM tab0 AS cor0
----
97
97
97

query I rowsort
SELECT - tab2.col1 + + 56 FROM tab2
----
-3
25
39

query I rowsort
SELECT ( + 43 ) * - col0 + 70 * col2 * col0 FROM tab2
----
12929
138606
206743

query I rowsort
SELECT col1 - 44 FROM tab2
----
-13
-27
15

query I rowsort
SELECT DISTINCT + ( col0 ) + + col2 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT 31 + col2 * - col2 AS col0 FROM tab0
----
-1058
-6693
30

query I rowsort
SELECT DISTINCT + col2 + tab1.col0 AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL + 49 - + col2 AS col2 FROM tab1 cor0
----
-47
-5
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3307
SELECT + - ( - cor0.col0 ) * col0 * col0 + - col1 DIV + col0 AS col0 FROM tab2 cor0
----
339
474552
493039

skipif mysql # not compatible
query I rowsort label-3307
SELECT + - ( - cor0.col0 ) * col0 * col0 + - col1 / + col0 AS col0 FROM tab2 cor0
----
339
474552
493039

query I rowsort
SELECT ALL + col0 * col0 + col1 * cor0.col0 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT + col2 * - ( col2 ) * + col1 AS col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT DISTINCT + ( col2 ) * cor0.col1 + - col1 AS col2 FROM tab0 cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-3311
SELECT + col0 DIV - col0 + + col1 AS col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-3311
SELECT + col0 / - col0 + + col1 AS col1 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT DISTINCT - col0 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + - col1 * cor0.col1 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col0 + + col0 + ( + col1 ) * - col2 AS col0 FROM tab2 AS cor0
----
-1378
-488
-823

query I rowsort
SELECT DISTINCT + 90 - - col2 * 60 FROM tab2 AS cor0
----
1650
1710
2370

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3316
SELECT CAST( NULL AS SIGNED ) * - 96 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3316
SELECT CAST ( NULL AS INTEGER ) * - 96 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3317
SELECT ALL col0 DIV col0 - col2 AS col1 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-3317
SELECT ALL col0 / col0 - col2 AS col1 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT + 17 * + col1 FROM tab1 AS cor0
----
170
221
442

query I rowsort
SELECT DISTINCT - col2 + 29 FROM tab0 AS cor0
----
-4
-53
28

query I rowsort
SELECT ALL + + 51 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * tab2.col0 col2 FROM tab2
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3322
SELECT + col0 + - ( + col1 ) DIV + cor0.col0 FROM tab2 AS cor0
----
3
78
79

skipif mysql # not compatible
query I rowsort label-3322
SELECT + col0 + - ( + col1 ) / + cor0.col0 FROM tab2 AS cor0
----
3
78
79

query I rowsort
SELECT + col2 * col2 + + cor0.col1 * + cor0.col0 * col0 FROM tab2 AS cor0
----
107541
2248
359632

query I rowsort
SELECT - - ( + 54 ) - + col1 FROM tab2 AS cor0
----
-5
23
37

query I rowsort
SELECT - 70 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col0 * tab1.col1 col0 FROM tab1
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 10 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT - + 95 * 24 - + col1 AS col1 FROM tab1 AS cor0
----
-2290
-2293
-2306

query I rowsort
SELECT ALL 80 + col1 * col1 FROM tab1 AS cor0
----
180
249
756

query I rowsort
SELECT ALL + + col0 * 71 FROM tab0 AS cor0
----
1704
2485
6319

query I rowsort
SELECT DISTINCT ( 34 ) FROM tab0 AS cor0
----
34

query I rowsort
SELECT DISTINCT - - 24 + col2 AS col1 FROM tab2 AS cor0
----
50
51
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3333
SELECT ALL - - 20 DIV + cor0.col2 + col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3333
SELECT ALL - - 20 / + cor0.col2 + col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - ( - col0 ) * + col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL ( 99 ) * col1 AS col0 FROM tab0 AS cor0
----
8514
9009
9603

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3336
SELECT DISTINCT CAST( 33 AS SIGNED ) + col1 FROM tab2 AS cor0
----
50
64
92

skipif mysql # not compatible
query I rowsort label-3336
SELECT DISTINCT CAST ( 33 AS INTEGER ) + col1 FROM tab2 AS cor0
----
50
64
92

query I rowsort
SELECT ALL + cor0.col1 * - 72 FROM tab0, tab0 AS cor0
----
9 values hashing to 845fd9de767a635bfd6049e4d02a7196

query I rowsort
SELECT DISTINCT + - 45 FROM tab1, tab2, tab0 cor0, tab0
----
-45

query I rowsort
SELECT col0 - + 42 AS col0 FROM tab1 cor0
----
-39
22
38

query I rowsort
SELECT - cor0.col1 + 40 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to eacdf98742f14bb3ff555fbabaad737c

query I rowsort
SELECT DISTINCT + - cor0.col1 * col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3342
SELECT ALL - CAST( NULL AS SIGNED ) * 35 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3342
SELECT ALL - CAST ( NULL AS INTEGER ) * 35 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + - ( + col0 ) FROM tab2 cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * + col2 col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + 65 * - col0 + - 11 FROM tab0
----
-1571
-2286
-5796

query I rowsort
SELECT col2 * - 21 FROM tab2 cor0
----
-546
-567
-798

query I rowsort
SELECT 20 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT + col2 * + col0 * 2 AS col0 FROM tab0 AS cor0
----
14596
1584
70

query I rowsort
SELECT ALL + cor0.col1 + ( - col0 ) * col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - col0 + col1 - col2 FROM tab0 AS cor0
----
-80
29
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col1 * col2 col1 FROM tab1 cor0
----
-1261
-1430
-580

query I rowsort
SELECT - col1 * - col0 * ( - col2 ) + col1 + + 64 * - col1 FROM tab0 AS cor0
----
-669851
-73530
-9506

query I rowsort
SELECT + col1 + col0 * - tab1.col2 AS col2 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT - 91 + + 82 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 3dfe689e16ce3a87877d40f349e6c7b5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 90 col0 FROM tab1
----
-90
-90
-90

query I rowsort
SELECT - cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT DISTINCT + 15 AS col0 FROM tab0 AS cor0
----
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 + + 73 col0 FROM tab1 AS cor0
----
1321
1477
643

onlyif mysql # use DIV operator for integer division
query I rowsort label-3359
SELECT ALL 50 DIV col1 col0 FROM tab2
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3359
SELECT ALL 50 / col1 col0 FROM tab2
----
0
1
2

query I rowsort
SELECT ALL - - col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + - 96 + col0 * + cor0.col0 FROM tab1 cor0
----
-87
4000
6304

query I rowsort
SELECT ALL col2 + col2 * col2 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT 0 * 46 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL + col2 - - 89 * ( col0 * ( 60 ) ) AS col0 FROM tab1 AS cor0
----
16074
341817
427296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3365
SELECT DISTINCT col0 * CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3365
SELECT DISTINCT col0 * CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3366
SELECT ALL col2 DIV + col1 + - 62 + + col1 AS col2 FROM tab1 AS cor0
----
-34
-42
-47

skipif mysql # not compatible
query I rowsort label-3366
SELECT ALL col2 / + col1 + - 62 + + col1 AS col2 FROM tab1 AS cor0
----
-34
-42
-47

onlyif mysql # use DIV operator for integer division
query I rowsort label-3367
SELECT DISTINCT - col2 + + ( - 34 ) DIV col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3367
SELECT DISTINCT - col2 + + ( - 34 ) / col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + col0 + + 2 FROM tab1
----
5
66
82

query I rowsort
SELECT DISTINCT col2 + ( col0 ) * + col1 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL + + col1 * ( col0 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL 51 FROM tab2, tab0 cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor1.col0 col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT ALL + ( col0 ) * + col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL 34 * 91 AS col1 FROM tab1
----
3094
3094
3094

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3375
SELECT CAST( NULL AS SIGNED ) + cor0.col0 + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3375
SELECT CAST ( NULL AS INTEGER ) + cor0.col0 + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col2 * 32 + - col0 AS col2 FROM tab1 AS cor0
----
-1731
-1888
-3152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 + + cor0.col2 col1 FROM tab0 AS cor0
----
109
158
77

query I rowsort
SELECT - cor0.col2 * col0 + - cor0.col0 FROM tab1 cor0
----
-165
-3712
-7760

query I rowsort
SELECT + ( ( cor0.col1 ) ) * - col1 + ( col1 ) FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT - 38 + col2 FROM tab0 cor0
----
-37
-5
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3381
SELECT + CAST( col2 AS SIGNED ) - col2 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3381
SELECT + CAST ( col2 AS INTEGER ) - col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - ( + 75 ) - col0 FROM tab1 AS cor0
----
-5
11
72

query I rowsort
SELECT + - 30 - + col0 FROM tab0 AS cor0
----
-119
-54
-65

query I rowsort
SELECT + 14 * cor0.col2 + col1 FROM tab1 AS cor0
----
1357
782
808

query I rowsort
SELECT + cor0.col1 + - col2 * cor0.col2 - ( + col1 ) * col1 AS col2 FROM tab2 AS cor0
----
-1659
-1716
-4098

query I rowsort
SELECT - - col2 * col1 + col2 AS col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT 22 * cor0.col1 + - col2 * cor0.col1 FROM tab0 AS cor0
----
-5460
-946
2037

query I rowsort
SELECT col1 * col2 + ( - 57 * - col2 ) FROM tab0 AS cor0
----
12136
154
4719

onlyif mysql # use DIV operator for integer division
query I rowsort label-3389
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-3389
SELECT + col0 / - col2 col1 FROM tab0
----
-1
-35
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3390
SELECT DISTINCT - ( + col2 ) * - CAST( NULL AS SIGNED ) - 83 * - col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3390
SELECT DISTINCT - ( + col2 ) * - CAST ( NULL AS INTEGER ) - 83 * - col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3391
SELECT + + col0 DIV col2 - 28 col0 FROM tab1 AS cor0
----
-27
-28
-28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3391
SELECT + + col0 / col2 - 28 col0 FROM tab1 AS cor0
----
-27
-28
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-3392
SELECT ALL 64 + - col0 DIV 80 FROM tab0 AS cor0
----
63
64
64

skipif mysql # not compatible
query I rowsort label-3392
SELECT ALL 64 + - col0 / 80 FROM tab0 AS cor0
----
63
64
64

query I rowsort
SELECT DISTINCT - 62 * col2 - + 68 FROM tab0 cor0
----
-130
-2114
-5152

query I rowsort
SELECT DISTINCT - + col2 + col0 * + col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - 49 + + col0 FROM tab0 AS cor0
----
-14
-25
40

query I rowsort
SELECT DISTINCT - + 50 - + col0 * col1 FROM tab2 cor0
----
-1393
-267
-4652

query I rowsort
SELECT ALL - 71 FROM tab2, tab2 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # use DIV operator for integer division
query I rowsort label-3398
SELECT cor0.col0 DIV + 43 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3398
SELECT cor0.col0 / + 43 FROM tab2 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3399
SELECT - col0 + - col1 * 85 DIV + col0 AS col1 FROM tab2 AS cor0
----
-142
-383
-97

skipif mysql # not compatible
query I rowsort label-3399
SELECT - col0 + - col1 * 85 / + col0 AS col1 FROM tab2 AS cor0
----
-142
-383
-97

query I rowsort
SELECT DISTINCT + - ( col0 ) * - cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT - ( - ( col1 ) ) * 90 + ( - col0 ) * - col2 * - col1 FROM tab2 AS cor0
----
-114342
-3069
-49504

query I rowsort
SELECT ALL 49 * - col0 - - col1 FROM tab2 AS cor0
----
-312
-3763
-3854

query I rowsort
SELECT + col1 * + col1 + col2 AS col1 FROM tab2
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 84 + - 40 col2 FROM tab0 AS cor0
----
-124
-124
-124

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3405
SELECT ALL CAST( NULL AS DECIMAL ) AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3405
SELECT ALL CAST ( NULL AS REAL ) AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-3406
SELECT + col1 DIV col1 - col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-3406
SELECT + col1 / col1 - col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT ALL + - col0 + col1 * col2 FROM tab2 cor0
----
1456
567
830

query I rowsort
SELECT - - col2 + col1 * 78 + col0 * + col2 * col1 AS col0 FROM tab2 cor0
----
124280
52398
8304

query I rowsort
SELECT ALL - + col0 * - 55 AS col0 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT DISTINCT - tab1.col2 - col0 * - 72 AS col0 FROM tab1
----
162
4551
5664

query I rowsort
SELECT ALL col2 + + ( + col1 ) + - col2 AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT 23 AS col1 FROM tab2, tab0 AS cor0
----
23

query I rowsort
SELECT col2 * col0 * col1 - tab1.col2 * - col0 AS col1 FROM tab1
----
107520
40128
4374

query I rowsort
SELECT + col2 * 43 AS col1 FROM tab0
----
1419
3526
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-3415
SELECT DISTINCT + col1 * col0 DIV + ( - cor0.col1 * col1 + cor0.col0 ) FROM tab2 AS cor0
----
-1
-6
0

skipif mysql # not compatible
query I rowsort label-3415
SELECT DISTINCT + col1 * col0 / + ( - cor0.col1 * col1 + cor0.col0 ) FROM tab2 AS cor0
----
-1
-6
0

query I rowsort
SELECT 19 + col1 * col1 AS col2 FROM tab0
----
7415
8300
9428

query I rowsort
SELECT - col0 + + col2 * + col0 AS col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT 98 + 68 * col1 AS col1 FROM tab1
----
1866
778
982

onlyif mysql # use DIV operator for integer division
query I rowsort label-3419
SELECT col1 + col2 DIV + cor0.col1 col0 FROM tab1 cor0
----
15
20
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3419
SELECT col1 + col2 / + cor0.col1 col0 FROM tab1 cor0
----
15
20
28

query I rowsort
SELECT ALL + ( - col1 ) * col2 + col2 FROM tab2 cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 0 - - col1 col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3422
SELECT ALL + col2 DIV col2 + 9 DIV + 26 col1 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3422
SELECT ALL + col2 / col2 + 9 / + 26 col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - - col2 * col0 - 44 FROM tab1 AS cor0
----
118
3604
7636

query I rowsort
SELECT ALL - + ( col2 ) + - col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + cor0.col1 col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 68 * col0 * - col1 col1 FROM tab0 AS cor0
----
140352
230860
550732

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-3428
SELECT DISTINCT - - 38 DIV col1 AS col0 FROM tab1 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3428
SELECT DISTINCT - - 38 / col1 AS col0 FROM tab1 AS cor0
----
1
2
3

query I rowsort
SELECT - 71 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 3907e0aa4f29c002120742c4abb3e23a

query I rowsort
SELECT ALL + 15 AS col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT - 67 * + col0 + + 76 FROM tab2
----
-393
-5150
-5217

query I rowsort
SELECT DISTINCT col2 + col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col2 * + ( + ( col1 ) ) col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + col2 - cor0.col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + - col0 + - cor0.col1 * 94 FROM tab0 AS cor0
----
-8108
-8643
-9153

query I rowsort
SELECT - 8 * col0 AS col2 FROM tab0 cor0
----
-192
-280
-712

query I rowsort
SELECT + 53 AS col1 FROM tab2 cor0
----
53
53
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 68 * - col1 col1 FROM tab0 AS cor0
----
-5848
-6188
-6596

query I rowsort
SELECT - col0 + 68 FROM tab1 AS cor0
----
-12
4
65

query I rowsort
SELECT ALL + + cor0.col2 * col0 + col2 AS col1 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT - col0 * + ( col1 ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col0 + + cor0.col0 * - cor0.col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL - cor0.col0 + ( - ( col2 ) ) AS col2 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3444
SELECT ALL col1 * CAST( NULL AS SIGNED ) + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3444
SELECT ALL col1 * CAST ( NULL AS INTEGER ) + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col1 + col2 * col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT col0 * col2 + + col2 + + col1 AS col0 FROM tab2 cor0
----
2113
247
3057

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3447
SELECT ALL - CAST( NULL AS SIGNED ) / + ( + col0 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3447
SELECT ALL - CAST ( NULL AS INTEGER ) / + ( + col0 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 col2 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT cor0.col1 + - 4 + col2 AS col0 FROM tab2 AS cor0
----
51
54
81

query I rowsort
SELECT - ( - col1 ) + col1 * ( 23 ) AS col1 FROM tab1 cor0
----
240
312
624

query I rowsort
SELECT DISTINCT - 2 AS col2 FROM tab1 AS cor0
----
-2

query I rowsort
SELECT ALL + col0 + col1 - + col2 * col0 FROM tab2 AS cor0
----
-151
-1891
-2906

query I rowsort
SELECT ALL col2 * 54 FROM tab0 AS cor0
----
1782
4428
54

query I rowsort
SELECT ALL 47 * 66 FROM tab2 AS cor0
----
3102
3102
3102

query I rowsort
SELECT ALL - tab0.col0 + ( col2 + + tab0.col0 ) FROM tab0
----
1
33
82

query I rowsort
SELECT + tab2.col2 * ( col0 * col1 ) FROM tab2
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3457
SELECT ALL tab2.col1 * + CAST( NULL AS SIGNED ) + + 25 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3457
SELECT ALL tab2.col1 * + CAST ( NULL AS INTEGER ) + + 25 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + ( col0 ) * - col0 FROM tab1 cor0
----
-4153
-63
-6496

query I rowsort
SELECT + 56 + col1 * col0 + + col2 AS col0 FROM tab0 AS cor0
----
2153
3452
8237

query I rowsort
SELECT DISTINCT col2 + - col2 * col1 AS col0 FROM tab2 cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-3461
SELECT DISTINCT 53 * + col1 DIV cor0.col1 col2 FROM tab1 AS cor0
----
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3461
SELECT DISTINCT 53 * + col1 / cor0.col1 col2 FROM tab1 AS cor0
----
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3462
SELECT - CAST( - col1 AS SIGNED ) * col2 col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3462
SELECT - CAST ( - col1 AS INTEGER ) * col2 col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3463
SELECT + - ( - ( - col0 ) ) * - CAST( NULL AS SIGNED ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3463
SELECT + - ( - ( - col0 ) ) * - CAST ( NULL AS INTEGER ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col2 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT cor0.col0 * ( cor1.col1 ) FROM tab0, tab1 cor0, tab1 AS cor1
----
9 values hashing to c7e3d87815c66f5a8360e4fe15424a79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3466
SELECT ALL - CAST( NULL AS SIGNED ) * tab1.col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3466
SELECT ALL - CAST ( NULL AS INTEGER ) * tab1.col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 51 * cor0.col2 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to b5f7287c7ae45a02af184837857314cb

query I rowsort
SELECT DISTINCT + - col1 + - cor0.col2 * col1 FROM tab2 AS cor0
----
-1593
-663
-868

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
3645 values hashing to f7d7f8e55c3be4391aa225222961d676

query I rowsort
SELECT - col0 + col2 * col0 * - col2 FROM tab0
----
-26160
-598525
-70

query I rowsort
SELECT - ( + cor0.col2 ) + 59 FROM tab1, tab2 cor0
----
9 values hashing to f790860fa40497d8872f7a6676dc6d65

query I rowsort
SELECT DISTINCT col0 AS col2 FROM tab2 WHERE col0 + + col2 - col0 NOT IN ( tab2.col0 + - col1 )
----
7
78
79

query I rowsort
SELECT col1 * - col2 * col2 AS col2 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT col0 + + col1 * + col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT col1 + - col0 AS col2 FROM tab2
----
-19
-62
24

query I rowsort
SELECT DISTINCT - col1 / - col1 + + col0 * - col0 FROM tab2 WHERE NULL > NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col0 IN ( - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col2 col1 FROM tab1
----
28
47
83

query I rowsort
SELECT - col0 + col0 FROM tab2 WHERE NOT NULL = NULL
----

query I rowsort
SELECT col0 * - tab2.col2 + - col1 AS col1 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT - col0 AS col2 FROM tab2 WHERE NOT NULL > ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 - col0 * col1 * col1 col1 FROM tab1
----
-14560
-2106
-7040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 * col1 * col2 col1 FROM tab2
----
22599
24548
39884

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) > ( NULL )
----

query I rowsort
SELECT DISTINCT col1 * + col2 + - col2 * tab1.col1 + + tab1.col2 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3486
SELECT ALL col2 * + tab0.col2 DIV + col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3486
SELECT ALL col2 * + tab0.col2 / + col2 FROM tab0
----
1
33
82

query I rowsort
SELECT - col0 + col1 + + col0 * - col1 AS col1 FROM tab2
----
-1405
-193
-4621

query I rowsort
SELECT DISTINCT - col1 + col1 + tab1.col1 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL - col2 + tab0.col1 * + col0 + + col0 * + col0 AS col0 FROM tab0
----
15938
2607
4619

query I rowsort
SELECT DISTINCT - col1 + col1 FROM tab2 WHERE NOT NULL NOT IN ( col2 - col1 )
----

query I rowsort
SELECT DISTINCT + tab1.col2 + + col1 + col2 AS col2 FROM tab1
----
124
134
205

query I rowsort
SELECT DISTINCT col1 * col0 * col2 AS col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT + col0 * - col2 * - col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT + col0 * col1 + col0 AS col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT col2 * + col1 + - col2 AS col2 FROM tab2
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-3496
SELECT DISTINCT tab1.col0 + col1 DIV + tab1.col2 AS col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3496
SELECT DISTINCT tab1.col0 + col1 / + tab1.col2 AS col0 FROM tab1
----
3
64
80

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( col2 * - col2 ) IN ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + col2 col1 FROM tab1
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + tab2.col0 * + col1 * + col1 col0 FROM tab2
----
22752
271440
6720

query I rowsort
SELECT + col2 * - col0 + col0 * + col2 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT + col1 AS col2 FROM tab2 AS cor0 WHERE NOT col0 * col2 <> col0
----

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0 WHERE ( NULL ) > NULL
----

query I rowsort
SELECT - tab0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT DISTINCT col1 + col2 * col0 AS col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT DISTINCT - col0 AS col0 FROM tab1 WHERE NOT + col0 IN ( + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3506
SELECT col1 DIV - col0 - - col1 * - tab0.col2 * + col2 col1 FROM tab0
----
-611885
-93657
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3506
SELECT col1 / - col0 - - col1 * - tab0.col2 * + col2 col1 FROM tab0
----
-611885
-93657
-99

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) NOT BETWEEN ( - col2 ) AND col1 * col0
----

query I rowsort
SELECT DISTINCT col1 * + col0 * - col1 AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT ALL col0 * col2 * - tab2.col2 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT ALL + col1 FROM tab1 WHERE NOT NULL BETWEEN ( NULL ) AND col2 * - col0 / + col1
----

query I rowsort
SELECT DISTINCT + col0 * - col1 FROM tab0 WHERE NOT col2 / + col2 + col2 NOT BETWEEN ( + col1 * - col0 ) AND + col0
----
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 + tab0.col0 col1 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL col0 * + col2 * - tab1.col0 AS col0 FROM tab1
----
-233472
-486
-614400

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT col1 NOT BETWEEN NULL AND NULL
----

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0 WHERE NOT ( NULL ) < NULL
----

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE NOT NULL NOT BETWEEN ( NULL ) AND NULL
----

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 cor1, tab2 AS cor2
----
972 values hashing to e610acd60f342127e6cdba18673d9f0e

query I rowsort
SELECT ALL - 85 + cor0.col1 FROM tab1 AS cor0
----
-59
-72
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-3519
SELECT - 44 + col1 - tab1.col1 DIV + col2 AS col0 FROM tab1
----
-18
-31
-34

skipif mysql # not compatible
query I rowsort label-3519
SELECT - 44 + col1 - tab1.col1 / + col2 AS col0 FROM tab1
----
-18
-31
-34

query I rowsort
SELECT + cor0.col0 + - 76 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 986f5af7cbfb404d2687978f7407695b

query I rowsort
SELECT DISTINCT col1 * - 7 - - col2 * 91 * col2 FROM tab1
----
265174
295589
838565

query I rowsort
SELECT 72 - - col0 FROM tab0
----
107
161
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3523
SELECT DISTINCT cor1.col1 DIV cor1.col1 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
1

skipif mysql # not compatible
query I rowsort label-3523
SELECT DISTINCT cor1.col1 / cor1.col1 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3524
SELECT ( 1 ) DIV + col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3524
SELECT ( 1 ) / + col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * 37 AS col2 FROM tab0 cor0
----
1295
3293
888

query I rowsort
SELECT ALL cor0.col2 + - cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 92ef426526338653e88acd4aba639c47

query I rowsort
SELECT - - cor0.col0 + col2 * - col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT 21 * + col1 AS col1 FROM tab2 AS cor0
----
1239
357
651

query I rowsort
SELECT ALL - 61 * col2 * - ( ( col0 ) ) AS col0 FROM tab0
----
2135
445178
48312

query I rowsort
SELECT 54 * + tab0.col0 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 9badd3cca82253aa5abb0910f28c8ea9

query I rowsort
SELECT - tab1.col1 * + tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 0cea1be551fb4bd88f4da0b7d676ee2f

query I rowsort
SELECT + col1 * + col2 + 16 FROM tab0
----
113
2854
7478

query I rowsort
SELECT DISTINCT + col2 * + ( col2 * col2 ) AS col1 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT - 31 * + col2 * + col1 FROM tab2 AS cor0
----
-20026
-25947
-47554

query I rowsort
SELECT 86 * + col2 FROM tab0 AS cor0
----
2838
7052
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3536
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + ( col2 ) col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3536
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + ( col2 ) col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + ( + 99 ) * cor0.col1 FROM tab2 AS cor0
----
1683
3069
5841

query I rowsort
SELECT ALL + 21 + + col1 AS col1 FROM tab2 AS cor0
----
38
52
80

query I rowsort
SELECT ALL - 87 + 38 * col2 FROM tab0 AS cor0
----
-49
1167
3029

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 86 + + col2 * + col2 col2 FROM tab2 AS cor0
----
1530
762
815

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 84 + + col1 col1 FROM tab2
----
-25
-53
-67

query I rowsort
SELECT DISTINCT + - 27 * - col1 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
124254
36261
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 * cor0.col0 - - col0 col0 FROM tab1 AS cor0
----
-12
-256
-320

query I rowsort
SELECT ALL + col0 * + col0 + col2 FROM tab2 AS cor0
----
6110
6279
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - col2 * tab2.col2 * - col2 col0 FROM tab2
----
17602
19710
54910

query I rowsort
SELECT ALL col2 + col0 - + tab1.col0 * col2 FROM tab1
----
-105
-3527
-7504

query III rowsort
SELECT ALL * FROM tab2 WHERE ( col1 + col2 * col2 IN ( + col0 + col1 ) AND - col1 >= NULL ) AND NOT NULL < ( NULL )
----

query I rowsort
SELECT + col2 * col2 + col2 * + col2 FROM tab2
----
1352
1458
2888

onlyif mysql # use DIV operator for integer division
query I rowsort label-3549
SELECT ALL col0 * tab0.col0 DIV + col1 AS col1 FROM tab0
----
12
6
87

skipif mysql # not compatible
query I rowsort label-3549
SELECT ALL col0 * tab0.col0 / + col1 AS col1 FROM tab0
----
12
6
87

query I rowsort
SELECT DISTINCT 40 * ( + col0 ) AS col1 FROM tab0
----
1400
3560
960

query I rowsort
SELECT ALL - cor0.col0 + + ( + col2 ) * + col2 FROM tab1 AS cor0
----
2913
3185
9136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + 34 + + cor0.col1 col1 FROM tab1 cor0
----
-2166
-2707
-76

query I rowsort
SELECT DISTINCT - cor0.col0 + + 45 AS col0 FROM tab0 cor0
----
-44
10
21

query I rowsort
SELECT ALL + + col0 * col2 + col0 AS col1 FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT - - ( - tab0.col1 ) AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT - tab0.col2 + col0 * - 98 AS col1 FROM tab0
----
-2385
-3431
-8804

query I rowsort
SELECT DISTINCT col2 + tab0.col2 AS col2 FROM tab0
----
164
2
66

query I rowsort
SELECT 84 * tab2.col0 FROM tab2
----
588
6552
6636

query I rowsort
SELECT + cor1.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 + tab2.col1 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 4cf98869877fa51f9321a9b0e7299899

query I rowsort
SELECT ALL - tab2.col1 + col1 * - 14 AS col0 FROM tab2
----
-255
-465
-885

query I rowsort
SELECT ( - col0 ) * - col0 * - col1 + + col0 + col0 FROM tab1
----
-228
-40832
-83040

query I rowsort
SELECT cor1.col2 + tab1.col0 AS col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 8ccec472ba030beef859f936b43eb646

query I rowsort
SELECT + col2 * - ( 63 ) AS col2 FROM tab0 AS cor0
----
-2079
-5166
-63

query I rowsort
SELECT - ( - 64 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ALL col0 * - ( - col2 * + col2 ) FROM tab2
----
114076
5103
52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-3567
SELECT DISTINCT + col2 DIV ( col1 ) FROM tab2
----
0
2

skipif mysql # not compatible
query I rowsort label-3567
SELECT DISTINCT + col2 / ( col1 ) FROM tab2
----
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3568
SELECT DISTINCT - col2 + 35 DIV ( col0 ) + col1 FROM tab1 AS cor0
----
-17
-47
-83

skipif mysql # not compatible
query I rowsort label-3568
SELECT DISTINCT - col2 + 35 / ( col0 ) + col1 FROM tab1 AS cor0
----
-17
-47
-83

query I rowsort
SELECT DISTINCT + col0 + 20 AS col0 FROM tab1 AS cor0
----
100
23
84

query I rowsort
SELECT ALL - + col0 - cor0.col1 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT col2 + 89 AS col0 FROM tab1 AS cor0
----
143
146
185

onlyif mysql # use DIV operator for integer division
query I rowsort label-3572
SELECT ALL + - col0 DIV col2 AS col0 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-3572
SELECT ALL + - col0 / col2 AS col0 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT DISTINCT + + col2 + + 0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - - col2 * 53 AS col2 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT ALL col1 * col2 + - col0 AS col0 FROM tab0
----
2814
62
7373

query I rowsort
SELECT ALL cor0.col1 AS col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-3577
SELECT - col1 DIV - cor0.col2 + cor0.col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3577
SELECT - col1 / - cor0.col2 + cor0.col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT col2 AS col1 FROM tab2 AS cor0 WHERE col2 * col0 * col1 IN ( cor0.col0 ) OR + col1 * col1 - col1 / + col1 NOT BETWEEN col0 AND NULL
----

query I rowsort
SELECT ALL + + col0 * - col0 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-56
-6162
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-3580
SELECT + col0 + col1 * col2 DIV + col0 FROM tab1 cor0
----
471
72
95

skipif mysql # not compatible
query I rowsort label-3580
SELECT + col0 + col1 * col2 / + col0 FROM tab1 cor0
----
471
72
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - + col2 * + col2 * - tab1.col0 col2 FROM tab1
----
208000
737360
8751

query I rowsort
SELECT ALL - - col1 * col1 + + cor0.col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT + col0 + + col1 * cor0.col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL + - cor0.col1 * col1 - + cor0.col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT ALL + + cor0.col2 * - col1 + + col0 + + col2 AS col0 FROM tab0 AS cor0
----
-2781
-61
-7291

query I rowsort
SELECT ALL 0 + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 12 col0 FROM tab0 AS cor0
----
-12

query I rowsort
SELECT ALL - col2 + col0 * + cor0.col1 * - col1 FROM tab2 AS cor0
----
-22869
-271544
-6754

query I rowsort
SELECT DISTINCT + + col0 * - col1 FROM tab2 cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col1 ) col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + col0 + col2 * + col2 - col1 * col1 AS col2 FROM tab2 AS cor0
----
-225
-2727
1234

query I rowsort
SELECT - col0 - col1 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL + col2 + - col0 * - col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
233529
540
614496

query I rowsort
SELECT - cor0.col1 * + col2 + col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 - + col1 col0 FROM tab0 AS cor0
----
-2
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 11 * col2 col2 FROM tab2 cor0
----
286
297
418

query I rowsort
SELECT 26 - col1 AS col0 FROM tab0 AS cor0
----
-60
-65
-71

query I rowsort
SELECT DISTINCT - - cor0.col1 + - col1 * - cor0.col1 AS col0 FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT - col0 + col0 - col1 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - col1 * - col1 + cor0.col1 FROM tab2 AS cor0
----
306
3540
992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + col0 col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col0 * col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT ALL - - col2 - + col1 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + col1 * cor0.col2 + - cor0.col1 * + col0 FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT - + col0 + col0 * + cor0.col2 * col0 FROM tab2 cor0
----
1316
158106
237079

onlyif mysql # use DIV operator for integer division
query I rowsort label-3606
SELECT - + col0 DIV - cor0.col2 + + col0 FROM tab1 AS cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-3606
SELECT - + col0 / - cor0.col2 + + col0 FROM tab1 AS cor0
----
3
65
80

query I rowsort
SELECT + - col2 + col2 * col0 AS col0 FROM tab2 cor0
----
162
2002
2964

query IIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0 WHERE NULL <= ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col0 * col0 * + col0 col0 FROM tab0 cor0
----
13791
42874
704887

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col2 col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT DISTINCT col2 * - col0 + - col2 AS col1 FROM tab2
----
-2054
-216
-3040

query I rowsort
SELECT + cor0.col2 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + 52 AS col2 FROM tab2
----
52
52
52

query I rowsort
SELECT ( + col1 ) + col1 FROM tab2
----
118
34
62

query I rowsort
SELECT + col1 * - col2 * col2 AS col2 FROM tab0 cor0
----
-611884
-93654
-97

query I rowsort
SELECT - col1 * + col2 * 84 FROM tab0 cor0
----
-238392
-626808
-8148

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * cor0.col0 + col1 + + col1 col0 FROM tab1 AS cor0
----
214
3668
7706

onlyif mysql # use DIV operator for integer division
query I rowsort label-3618
SELECT col0 DIV + col0 + - 35 * + col2 FROM tab2 AS cor0
----
-1329
-909
-944

skipif mysql # not compatible
query I rowsort label-3618
SELECT col0 / + col0 + - 35 * + col2 FROM tab2 AS cor0
----
-1329
-909
-944

query I rowsort
SELECT DISTINCT 6 + col1 AS col2 FROM tab0
----
103
92
97

query I rowsort
SELECT col0 * - cor0.col1 - col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT + - 81 + - 63 * col2 - col2 FROM tab0 AS cor0
----
-145
-2193
-5329

query I rowsort
SELECT DISTINCT - 31 * col2 AS col2 FROM tab2 AS cor0
----
-1178
-806
-837

query I rowsort
SELECT + - col1 * 27 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
218673
55728
91665

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col1 + + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col2 * col2 col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT + tab2.col1 AS col2 FROM tab2, tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + 65 + - 75 * - col2 AS col2 FROM tab1 AS cor0
----
4115
4340
7265

query I rowsort
SELECT + ( + col2 ) * col2 + 17 + - col0 AS col0 FROM tab0 AS cor0
----
-17
1082
6652

onlyif mysql # use DIV operator for integer division
query I rowsort label-3629
SELECT ( 57 ) + tab1.col2 DIV - 58 AS col0 FROM tab1
----
56
57
57

skipif mysql # not compatible
query I rowsort label-3629
SELECT ( 57 ) + tab1.col2 / - 58 AS col0 FROM tab1
----
56
57
57

query I rowsort
SELECT cor0.col1 * col2 + - 93 * 88 AS col0 FROM tab0 AS cor0
----
-5346
-722
-8087

query I rowsort
SELECT + col0 * col2 * col2 + + col2 AS col1 FROM tab2 AS cor0
----
114114
5130
52754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * - col0 + col1 col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT 92 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
276
5888
7360

query I rowsort
SELECT DISTINCT + cor0.col2 + - cor0.col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
28
47
83

query I rowsort
SELECT col0 * + 87 * - col1 FROM tab2
----
-116841
-18879
-400374

query I rowsort
SELECT + cor0.col2 + - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3637
SELECT DISTINCT col1 * col1 DIV - col1 AS col0 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-3637
SELECT DISTINCT col1 * col1 / - col1 AS col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL - ( 37 ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

query I rowsort
SELECT DISTINCT col2 * + ( col2 ) + col1 * - ( - col1 ) + + col0 AS col1 FROM tab0 AS cor0
----
15094
8509
9445

query I rowsort
SELECT DISTINCT col1 + - 86 FROM tab0 AS cor0
----
0
11
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3641
SELECT ALL 85 DIV + 66 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3641
SELECT ALL 85 / + 66 AS col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3643
SELECT + CAST( NULL AS SIGNED ) - 13 * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3643
SELECT + CAST ( NULL AS INTEGER ) - 13 * col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 - + 1 FROM tab0
----
0
32
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3645
SELECT ALL 37 + col1 * - col2 * CAST( - col2 AS SIGNED ) FROM tab1
----
119845
32527
75853

skipif mysql # not compatible
query I rowsort label-3645
SELECT ALL 37 + col1 * - col2 * CAST ( - col2 AS INTEGER ) FROM tab1
----
119845
32527
75853

query I rowsort
SELECT 12 * col1 + - col1 * 5 * - ( col1 ) + - col1 AS col1 FROM tab0 AS cor0
----
37926
42406
48112

query I rowsort
SELECT 41 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3648
SELECT CAST( 32 AS SIGNED ) * col0 + col1 * - col2 + - col2 FROM tab2 AS cor0
----
-640
1844
936

skipif mysql # not compatible
query I rowsort label-3648
SELECT CAST ( 32 AS INTEGER ) * col0 + col1 * - col2 + - col2 FROM tab2 AS cor0
----
-640
1844
936

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab0, tab0 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to ba0381921410f59519cc658d8e65eee3

query I rowsort
SELECT + col0 + - ( 55 ) * col0 AS col0 FROM tab1 cor0
----
-162
-3456
-4320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3651
SELECT + col1 + + ( - col2 + - col1 ) * CAST( 94 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-10233
-6288
-7494

skipif mysql # not compatible
query I rowsort label-3651
SELECT + col1 + + ( - col2 + - col1 ) * CAST ( 94 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-10233
-6288
-7494

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3652
SELECT col0 * - CAST( NULL AS SIGNED ) + + col0 * + col2 + 44 / cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3652
SELECT col0 * - CAST ( NULL AS INTEGER ) + + col0 * + col2 + 44 / cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 + col0 * 20 FROM tab0 AS cor0
----
1698
447
699

query I rowsort
SELECT DISTINCT + + col0 * - col2 + - col2 * + col1 AS col0 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT ALL col1 * + col1 - 35 * + col2 FROM tab2 AS cor0
----
-1041
16
2571

query I rowsort
SELECT + col1 + ( + col2 ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - col0 + + col1 * - 38 FROM tab0 AS cor0
----
-3292
-3547
-3721

query I rowsort
SELECT ALL - + col1 + - cor0.col1 + - col1 * - col2 FROM tab0 AS cor0
----
-97
2666
7280

query I rowsort
SELECT DISTINCT + cor0.col1 + col0 * col0 AS col2 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT ALL - col0 * col0 - col1 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT + col0 + - 29 AS col2 FROM tab2 AS cor0
----
-22
49
50

query I rowsort
SELECT ALL - 58 + col1 AS col2 FROM tab2 cor0
----
-27
-41
1

query I rowsort
SELECT DISTINCT + + col1 + - cor0.col2 * col1 * col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
-36406
-4183
-99747

query I rowsort
SELECT ALL + - 16 * col1 FROM tab1 AS cor0
----
-160
-208
-416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3665
SELECT - 55 * - col1 + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3665
SELECT - 55 * - col1 + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - + 71 + - col2 AS col2 FROM tab0 AS cor0
----
-104
-153
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 * 25 + col1 col0 FROM tab1
----
-1298
-1405
-2374

query I rowsort
SELECT DISTINCT - - cor0.col0 - - col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - col2 * cor0.col0 + + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - 15 + col0 AS col1 FROM tab2 AS cor0
----
-8
63
64

query I rowsort
SELECT 65 * col1 AS col2 FROM tab1 AS cor0
----
1690
650
845

query I rowsort
SELECT ALL - ( col0 ) * ( col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + 30 + + tab1.col1 AS col1 FROM tab1
----
40
43
56

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 * - col2 FROM tab0 AS cor0
----
-611884
-93654
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3676
SELECT DISTINCT - col1 * + CAST( + col1 AS SIGNED ) + + col1 AS col0 FROM tab1 AS cor0
----
-156
-650
-90

skipif mysql # not compatible
query I rowsort label-3676
SELECT DISTINCT - col1 * + CAST ( + col1 AS INTEGER ) + + col1 AS col0 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT DISTINCT - + col1 + + col1 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + 81 * - col0 AS col2 FROM tab1
----
-243
-5184
-6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + tab1.col1 + col1 col2 FROM tab1
----
106
55
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-3680
SELECT DISTINCT - 5 DIV - col0 + + ( + col1 ) AS col2 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3680
SELECT DISTINCT - 5 / - col0 + + ( + col1 ) AS col2 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 32 + + col2 - - col0 col0 FROM tab0
----
203
68
89

query I rowsort
SELECT + - 25 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 2e7a33467ee3a4d9570560d60302b35a

query I rowsort
SELECT 89 * col2 FROM tab2
----
2314
2403
3382

query I rowsort
SELECT - + col2 - cor0.col1 * + col2 AS col2 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT - col1 + ( - col0 ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - col1 * - col2 + col0 FROM tab1 cor0
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col2 + col2 * + col1 + ( col0 ) col0 FROM tab1 AS cor0
----
-1509
-2615
-7888

query I rowsort
SELECT - 83 * + tab2.col0 + - col0 FROM tab2
----
-588
-6552
-6636

query I rowsort
SELECT ALL col1 * - col0 * col1 FROM tab0
----
-177504
-329315
-737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3690
SELECT + col1 * - CAST( col0 * - col2 AS SIGNED ) AS col1 FROM tab0
----
3395
664118
68112

skipif mysql # not compatible
query I rowsort label-3690
SELECT + col1 * - CAST ( col0 * - col2 AS INTEGER ) AS col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT 73 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-3692
SELECT + 15 DIV tab0.col0 + tab0.col1 AS col0 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3692
SELECT + 15 / tab0.col0 + tab0.col1 AS col0 FROM tab0
----
86
91
97

query I rowsort
SELECT ( tab0.col0 ) + col0 FROM tab0
----
178
48
70

query I rowsort
SELECT 64 - + col0 FROM tab0
----
-25
29
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3695
SELECT ALL CAST( NULL AS SIGNED ) / - col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3695
SELECT ALL CAST ( NULL AS INTEGER ) / - col2 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT cor1.col0 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT 68 * col2 * col2 FROM tab1 AS cor0
----
198288
220932
626688

query I rowsort
SELECT - 51 - + col2 AS col1 FROM tab2 AS cor0
----
-77
-78
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3699
SELECT ALL - col0 DIV - cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3699
SELECT ALL - col0 / - cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT + col1 * + col1 + col1 FROM tab0 cor0
----
7482
8372
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col1 col0 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3702
SELECT ALL + col1 DIV tab0.col1 + - ( col2 ) AS col2 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-3702
SELECT ALL + col1 / tab0.col1 + - ( col2 ) AS col2 FROM tab0
----
-32
-81
0

query I rowsort
SELECT DISTINCT - col2 + - col0 AS col0 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT ALL + - ( col1 ) * col0 + + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL + + 55 * - col0 + + col0 AS col1 FROM tab2 AS cor0
----
-378
-4212
-4266

query I rowsort
SELECT - - 42 + - cor0.col1 + 83 FROM tab0 cor0
----
28
34
39

query I rowsort
SELECT ALL 97 * - col2 AS col0 FROM tab2 AS cor0
----
-2522
-2619
-3686

query I rowsort
SELECT ALL - - 14 + col1 FROM tab0 AS cor0
----
100
105
111

query I rowsort
SELECT col1 + - col0 * col0 * - col0 AS col1 FROM tab2 AS cor0
----
374
474611
493056

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) * col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + 2 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
19
33
61

query I rowsort
SELECT ALL col1 * - 19 FROM tab2
----
-1121
-323
-589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - cor0.col1 ) col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

onlyif mysql # use DIV operator for integer division
query I rowsort label-3714
SELECT + col2 + + col1 DIV col1 FROM tab1 cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-3714
SELECT + col2 + + col1 / col1 FROM tab1 cor0
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3715
SELECT DISTINCT + - col1 DIV 10 - col0 * col0 FROM tab0 AS cor0
----
-1234
-584
-7930

skipif mysql # not compatible
query I rowsort label-3715
SELECT DISTINCT + - col1 / 10 - col0 * col0 FROM tab0 AS cor0
----
-1234
-584
-7930

query I rowsort
SELECT - - col1 * col0 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col0 * col2 * col0 + col2 FROM tab1 AS cor0
----
-233415
-432
-614304

query I rowsort
SELECT - ( + col0 ) * col2 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT 66 + - col2 FROM tab1 AS cor0
----
-30
12
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - ( col0 ) col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - + ( 60 ) AS col2 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

query I rowsort
SELECT DISTINCT - 7 AS col2 FROM tab2
----
-7

query I rowsort
SELECT ALL - + col0 + col1 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT - 59 - cor0.col1 FROM tab1 AS cor0
----
-69
-72
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3725
SELECT - col1 * col1 + + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3725
SELECT - col1 * col1 + + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 - + cor0.col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + 78 * col0 AS col1 FROM tab0 AS cor0
----
1872
2730
6942

onlyif mysql # use DIV operator for integer division
query I rowsort label-3728
SELECT ALL + - col2 DIV + col1 + col0 + cor0.col1 FROM tab2 AS cor0
----
137
38
94

skipif mysql # not compatible
query I rowsort label-3728
SELECT ALL + - col2 / + col1 + col0 + cor0.col1 FROM tab2 AS cor0
----
137
38
94

query I rowsort
SELECT ALL + 93 * col0 + + ( col2 ) FROM tab2 cor0
----
678
7280
7385

query I rowsort
SELECT DISTINCT + + col2 * col0 - - 60 AS col2 FROM tab0 AS cor0
----
7358
852
95

query I rowsort
SELECT col2 * col1 + 50 * col1 FROM tab0 AS cor0
----
12012
4947
7138

query I rowsort
SELECT ALL + col2 * + ( ( - cor0.col0 ) ) AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + col0 + col2 * + col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT col0 + + col0 * 50 * + col0 AS col0 FROM tab2 AS cor0
----
2457
304278
312129

query I rowsort
SELECT col2 * 1 + - col0 FROM tab2 AS cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + ( cor0.col2 ) + - col1 col2 FROM tab0 AS cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3737
SELECT - - col0 DIV - ( - 70 ) + - col1 DIV ( col2 * col2 ) FROM tab0 AS cor0
----
-97
0
1

skipif mysql # not compatible
query I rowsort label-3737
SELECT - - col0 / - ( - 70 ) + - col1 / ( col2 * col2 ) FROM tab0 AS cor0
----
-97
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3738
SELECT ALL col1 DIV + tab1.col2 + col1 AS col2 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3738
SELECT ALL col1 / + tab1.col2 + col1 AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT + col2 - - 90 FROM tab0 cor0
----
123
172
91

query I rowsort
SELECT + + col1 * + 93 FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT - + col0 * + col0 + + 67 FROM tab0 AS cor0
----
-1158
-509
-7854

query I rowsort
SELECT col0 * + 93 AS col2 FROM tab2 AS cor0
----
651
7254
7347

query I rowsort
SELECT + - col2 + - 98 + col2 AS col0 FROM tab1 AS cor0
----
-98
-98
-98

query I rowsort
SELECT ALL + 53 * col2 AS col0 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT ALL - 57 + 25 FROM tab0 AS cor0
----
-32
-32
-32

query I rowsort
SELECT ALL + 0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col1 * + 5 + col0 * - col1 FROM tab1 AS cor0
----
-1105
-208
-690

query I rowsort
SELECT + 66 + - cor0.col2 FROM tab2 AS cor0
----
28
39
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - - cor0.col1 col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - - cor0.col2 * col2 + 74 FROM tab0 AS cor0
----
1163
6798
75

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE NULL > ( NULL )
----

query I rowsort
SELECT DISTINCT + 69 * + cor0.col1 FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
5934
6279
6693

query I rowsort
SELECT 24 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT ALL - cor0.col2 * + 59 + col2 AS col0 FROM tab2 AS cor0
----
-1508
-1566
-2204

query I rowsort
SELECT + ( col1 * col2 ) AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - col1 + + tab2.col2 + + ( + col1 ) AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT + 77 * + col0 FROM tab2
----
539
6006
6083

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3758
SELECT CAST( tab2.col2 AS SIGNED ) + col0 / CAST( NULL AS SIGNED ) col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3758
SELECT CAST ( tab2.col2 AS INTEGER ) + col0 / CAST ( NULL AS INTEGER ) col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3759
SELECT ALL CAST( NULL AS SIGNED ) + - 96 * + tab1.col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3759
SELECT ALL CAST ( NULL AS INTEGER ) + - 96 * + tab1.col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 21 + - 81 FROM tab1 AS cor0
----
-60
-60
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3761
SELECT ALL + CAST( + col0 AS SIGNED ) - - col0 * - col1 * col2 AS col2 FROM tab0 AS cor0
----
-3360
-664029
-68088

skipif mysql # not compatible
query I rowsort label-3761
SELECT ALL + CAST ( + col0 AS INTEGER ) - - col0 * - col1 * col2 AS col2 FROM tab0 AS cor0
----
-3360
-664029
-68088

query I rowsort
SELECT + col0 + - col2 * + col2 AS col1 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT ALL 80 * - col1 + - col2 * 79 * col2 AS col1 FROM tab1 cor0
----
-232444
-257471
-729104

query I rowsort
SELECT ALL + ( 81 ) * col2 - + 36 AS col1 FROM tab1 cor0
----
4338
4581
7740

query I rowsort
SELECT DISTINCT + 34 + 50 FROM tab2
----
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 33 col1 FROM tab1 AS cor0
----
-33
-33
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + col2 col1 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3768
SELECT 51 * + col2 + col1 DIV - col0 AS col0 FROM tab1 AS cor0
----
2746
2907
4896

skipif mysql # not compatible
query I rowsort label-3768
SELECT 51 * + col2 + col1 / - col0 AS col0 FROM tab1 AS cor0
----
2746
2907
4896

query I rowsort
SELECT ALL - 4 * col1 AS col0 FROM tab1 AS cor0
----
-104
-40
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3770
SELECT ALL - col0 + col0 DIV - 59 col1 FROM tab2 AS cor0
----
-7
-79
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3770
SELECT ALL - col0 + col0 / - 59 col1 FROM tab2 AS cor0
----
-7
-79
-80

query I rowsort
SELECT ALL - 2 * - col2 + cor0.col2 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT DISTINCT - col0 + col2 * ( col0 + - col0 ) FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT 96 + col1 AS col2 FROM tab2 AS cor0
----
113
127
155

query I rowsort
SELECT col1 + - col2 * 81 AS col0 FROM tab1 AS cor0
----
-4348
-4607
-7763

query I rowsort
SELECT - + 8 * + col0 + 76 AS col2 FROM tab2 AS cor0
----
-548
-556
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-3776
SELECT DISTINCT - 99 + - cor0.col2 * 17 DIV col1 AS col2 FROM tab1 AS cor0
----
-134
-195
-224

skipif mysql # not compatible
query I rowsort label-3776
SELECT DISTINCT - 99 + - cor0.col2 * 17 / col1 AS col2 FROM tab1 AS cor0
----
-134
-195
-224

query I rowsort
SELECT - col1 + - 33 AS col0 FROM tab2
----
-50
-64
-92

query I rowsort
SELECT + cor0.col0 * 22 FROM tab1 AS cor0
----
1408
1760
66

query I rowsort
SELECT col2 * + col2 - 44 * col2 FROM tab0
----
-363
-43
3116

query I rowsort
SELECT - + col0 * + ( col0 ) FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - col0 * + 31 AS col1 FROM tab0 AS cor0
----
-1085
-2759
-744

query I rowsort
SELECT DISTINCT cor1.col2 AS col2 FROM tab0, tab1 AS cor0, tab0 cor1
----
1
33
82

query I rowsort
SELECT DISTINCT + + col1 * + 53 * ( cor0.col0 + col2 ) FROM tab0 AS cor0
----
185076
259806
824733

onlyif mysql # use DIV operator for integer division
query I rowsort label-3784
SELECT ALL + + col1 DIV - 22 AS col1 FROM tab0 AS cor0
----
-3
-4
-4

skipif mysql # not compatible
query I rowsort label-3784
SELECT ALL + + col1 / - 22 AS col1 FROM tab0 AS cor0
----
-3
-4
-4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3785
SELECT + col1 + CAST( cor0.col2 AS SIGNED ) FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-3785
SELECT + col1 + CAST ( cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL col0 * + 41 FROM tab0 AS cor0
----
1435
3649
984

query I rowsort
SELECT - ( - cor0.col0 ) AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * - 52 * 66 col2 FROM tab1 AS cor0
----
-34320
-44616
-89232

query I rowsort
SELECT ALL - + 21 + col1 * col0 + ( col2 ) FROM tab1 AS cor0
----
111
1115
676

query I rowsort
SELECT ( 13 ) + + col0 FROM tab0 AS cor0
----
102
37
48

query I rowsort
SELECT DISTINCT - - 62 AS col0 FROM tab0 AS cor0
----
62

query I rowsort
SELECT DISTINCT + 5 FROM tab2 cor0
----
5

query I rowsort
SELECT ALL + + cor0.col1 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - col0 * - 85 * col2 + + col0 * - 2 AS col0 FROM tab1 cor0
----
13764
309952
652640

onlyif mysql # use DIV operator for integer division
query I rowsort label-3795
SELECT ALL - cor0.col0 + col2 DIV + col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-3795
SELECT ALL - cor0.col0 + col2 / + col2 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT - col0 * 80 + col2 AS col0 FROM tab0 AS cor0
----
-1887
-2799
-7038

query I rowsort
SELECT - 67 + - 71 FROM tab1 cor0
----
-138
-138
-138

query I rowsort
SELECT DISTINCT + col1 + - col2 * cor0.col1 + - ( + col1 ) * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1404
-2054
-660

onlyif mysql # use DIV operator for integer division
query I rowsort label-3799
SELECT ALL col0 DIV 29 - col2 FROM tab0
----
-33
-79
0

skipif mysql # not compatible
query I rowsort label-3799
SELECT ALL col0 / 29 - col2 FROM tab0
----
-33
-79
0

query I rowsort
SELECT ALL ( 80 ) + + cor0.col2 + col2 * + col2 AS col1 FROM tab0 AS cor0
----
1202
6886
82

query I rowsort
SELECT ALL - ( + 41 ) FROM tab0 AS cor0
----
-41
-41
-41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3802
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + col1 col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3802
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + col1 col2 FROM tab0 AS cor0
----
NULL

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 DISTINCT + - ( col2 ) * + col2 + + col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT - cor0.col0 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
-3
-64
-80

query I rowsort
SELECT ALL + + 97 * ( + col2 * 67 ) AS col0 FROM tab2 AS cor0
----
168974
175473
246962

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 col0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT + 35 * cor0.col0 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f8b6965b2221db8fd6407963c2285112

query I rowsort
SELECT - - 30 * + 25 * - col1 AS col2 FROM tab0 AS cor0
----
-64500
-68250
-72750

query I rowsort
SELECT col0 + col1 * tab2.col2 + col1 AS col2 FROM tab2
----
1671
742
875

query I rowsort
SELECT 10 - + col2 * col2 FROM tab2 cor0
----
-1434
-666
-719

query I rowsort
SELECT - tab1.col1 * col1 + col0 AS col0 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT 44 + - col1 + - col0 * - col0 AS col0 FROM tab0
----
1172
534
7874

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3814
SELECT DISTINCT + CAST( NULL AS DECIMAL ) + - col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3814
SELECT DISTINCT + CAST ( NULL AS REAL ) + - col0 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT 54 + 73 FROM tab2
----
127

query I rowsort
SELECT + 29 * col1 FROM tab0
----
2494
2639
2813

query I rowsort
SELECT + col2 + + 31 * col1 * col0 AS col0 FROM tab1 cor0
----
19897
2472
32336

query I rowsort
SELECT + - col1 * + ( + col2 ) FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3819
SELECT DISTINCT ( tab1.col0 ) * + 62 + 96 DIV tab1.col2 FROM tab1
----
187
3969
4961

skipif mysql # not compatible
query I rowsort label-3819
SELECT DISTINCT ( tab1.col0 ) * + 62 + 96 / tab1.col2 FROM tab1
----
187
3969
4961

query I rowsort
SELECT ALL + col2 + 16 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-390
-405
-570

query I rowsort
SELECT DISTINCT - col1 * + 65 AS col0 FROM tab1
----
-1690
-650
-845

query I rowsort
SELECT ALL col0 + + 21 * + 58 AS col0 FROM tab1 AS cor0
----
1221
1282
1298

onlyif mysql # use DIV operator for integer division
query I rowsort label-3823
SELECT DISTINCT - - col2 * 81 DIV cor0.col1 AS col2 FROM tab1 AS cor0
----
168
461
598

skipif mysql # not compatible
query I rowsort label-3823
SELECT DISTINCT - - col2 * 81 / cor0.col1 AS col2 FROM tab1 AS cor0
----
168
461
598

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3824
SELECT - + col0 * - CAST( NULL AS SIGNED ) + + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3824
SELECT - + col0 * - CAST ( NULL AS INTEGER ) + + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col1 * 94 + col2 * + col0 FROM tab0 AS cor0
----
-1256
-7292
-9083

query I rowsort
SELECT ( + 88 ) AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT ALL + col1 * 87 FROM tab2 AS cor0
----
1479
2697
5133

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3828
SELECT DISTINCT + col2 * + CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3828
SELECT DISTINCT + col2 * + CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT + cor0.col1 * col2 + col2 + cor0.col2 * cor0.col2 FROM tab1 AS cor0
----
10560
3876
4374

query I rowsort
SELECT col0 + + col1 * + col1 * + col0 + + col1 FROM tab0 AS cor0
----
177614
329447
737189

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) NOT BETWEEN - col0 * col2 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3832
SELECT DISTINCT + col1 * col1 DIV + col0 + col2 * - col1 FROM tab2
----
-1490
-643
-700

skipif mysql # not compatible
query I rowsort label-3832
SELECT DISTINCT + col1 * col1 / + col0 + col2 * - col1 FROM tab2
----
-1490
-643
-700

query III rowsort
SELECT * FROM tab1 WHERE NOT + col0 = ( NULL )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 IN ( col2 * col0 + + col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT - col1 + tab0.col0 * tab0.col2 AS col1 FROM tab0 WHERE + col1 NOT IN ( - col0 * col0 )
----
-62
706
7207

query I rowsort
SELECT DISTINCT tab0.col2 * col1 + tab0.col0 AS col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT col2 + - col2 * tab1.col1 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT col0 + - col1 + col0 * - col1 FROM tab1 WHERE NOT ( NULL ) NOT BETWEEN ( NULL ) AND ( NULL )
----

query I rowsort
SELECT ALL - col2 * col2 * - col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT tab0.col0 * + col2 * - tab0.col1 + - col1 FROM tab0
----
-3492
-664209
-68198

query I rowsort
SELECT DISTINCT tab1.col1 + col1 * - col2 FROM tab1
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col0 col0 FROM tab2
----
14
156
158

query I rowsort
SELECT - col0 * col0 - col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT col0 * col1 + col2 FROM tab0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-3845
SELECT ALL + tab1.col2 + col2 DIV - tab1.col1 AS col1 FROM tab1
----
52
52
89

skipif mysql # not compatible
query I rowsort label-3845
SELECT ALL + tab1.col2 + col2 / - tab1.col1 AS col1 FROM tab1
----
52
52
89

query I rowsort
SELECT DISTINCT - tab2.col0 + + col2 * + col2 FROM tab2
----
1365
598
722

query I rowsort
SELECT - + col1 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + col2 * + cor0.col2 + col1 AS col2 FROM tab0 AS cor0
----
1175
6815
98

query III rowsort
SELECT ALL * FROM tab2 WHERE col0 >= NULL AND NOT NULL NOT IN ( - col2 * - col1 )
----

query I rowsort
SELECT - col2 + - col2 + - col2 AS col2 FROM tab0
----
-246
-3
-99

query I rowsort
SELECT col2 * col2 * + tab1.col2 AS col1 FROM tab1
----
157464
185193
884736

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col1 + + tab0.col1 col1 FROM tab0
----
172
182
194

query III rowsort
SELECT * FROM tab1 WHERE NOT + col2 * + col0 * col1 BETWEEN NULL AND NULL
----

query I rowsort
SELECT - + cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + - col2 * col0 - + col1 FROM tab2 cor0
----
-2087
-220
-3019

query I rowsort
SELECT - - col1 - + col0 * - col1 * col2 AS col0 FROM tab1 AS cor0
----
36490
4238
99853

query I rowsort
SELECT - col2 * + col0 + col0 + + col2 AS col1 FROM tab0 AS cor0
----
-7127
-735
1

query I rowsort
SELECT + + col2 + col0 * cor0.col0 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-3859
SELECT - tab0.col1 DIV - col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3859
SELECT - tab0.col1 / - col0 FROM tab0
----
1
2
3

query I rowsort
SELECT DISTINCT + + col0 * col2 * - 3 + - col1 AS col2 FROM tab2 AS cor0
----
-598
-6143
-9023

onlyif mysql # use DIV operator for integer division
query I rowsort label-3861
SELECT DISTINCT - 1 - tab0.col1 * col1 DIV col1 AS col2 FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-3861
SELECT DISTINCT - 1 - tab0.col1 * col1 / col1 AS col2 FROM tab0
----
-87
-92
-98

query I rowsort
SELECT ALL + tab2.col0 - - col0 AS col2 FROM tab2
----
14
156
158

query I rowsort
SELECT + + 95 AS col2 FROM tab1 AS cor0
----
95
95
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-3864
SELECT - cor0.col0 * cor0.col2 + - col1 + + cor0.col2 * col2 DIV ( - col1 + + col2 ) AS col0 FROM tab2 AS cor0
----
-2107
-2951
-402

skipif mysql # not compatible
query I rowsort label-3864
SELECT - cor0.col0 * cor0.col2 + - col1 + + cor0.col2 * col2 / ( - col1 + + col2 ) AS col0 FROM tab2 AS cor0
----
-2107
-2951
-402

skipif mysql # not compatible
query I rowsort
SELECT col2 * CAST ( 37 AS REAL ) + - col0 FROM tab2 cor0
----
1327
884
992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 * + col0 col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL + + col2 * cor0.col1 + 72 FROM tab2 AS cor0
----
1606
718
909

query I rowsort
SELECT DISTINCT - col1 * ( col2 * col2 ) FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL + col1 * col1 * col2 + col0 * col1 AS col0 FROM tab2 AS cor0
----
12325
26164
95108

query I rowsort
SELECT ALL + + col1 * + 54 + 32 * - cor0.col1 * cor0.col2 FROM tab1 cor0
----
-17700
-39234
-43524

query I rowsort
SELECT DISTINCT + col0 * 42 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT DISTINCT - + col0 + - col2 * 15 AS col2 FROM tab2 AS cor0
----
-412
-468
-649

query I rowsort
SELECT col0 + - col1 * 10 + - col2 FROM tab0 AS cor0
----
-869
-903
-936

query I rowsort
SELECT cor0.col2 - + cor0.col1 * col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT cor0.col2 * col2 + col0 + + cor0.col1 FROM tab2 AS cor0
----
1540
767
813

query I rowsort
SELECT col2 + - col2 * + 89 + col2 FROM tab0 AS cor0
----
-2871
-7134
-87

query I rowsort
SELECT + col2 * 46 AS col2 FROM tab2 cor0
----
1196
1242
1748

query I rowsort
SELECT ALL - col0 * ( 46 ) * + col2 + col2 * - 44 AS col2 FROM tab2 AS cor0
----
-139764
-94432
-9882

query III rowsort
SELECT * FROM tab2 WHERE ( - col1 ) IN ( - col1 * - tab2.col1 )
----

query I rowsort
SELECT DISTINCT col2 * col2 * - col0 + tab2.col2 FROM tab2
----
-114038
-5076
-52702

query I rowsort
SELECT + col2 + col0 * + col2 AS col0 FROM tab2
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 + - col2 col1 FROM tab0
----
-80
29
61

query I rowsort
SELECT ALL - tab2.col0 + col0 AS col2 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3884
SELECT + col0 DIV col0 + tab0.col2 * + col1 * tab0.col0 + col0 FROM tab0
----
3431
664208
68137

skipif mysql # not compatible
query I rowsort label-3884
SELECT + col0 / col0 + tab0.col2 * + col1 * tab0.col0 + col0 FROM tab0
----
3431
664208
68137

query I rowsort
SELECT col0 * - col0 FROM tab0 WHERE NULL NOT IN ( + col1 )
----

query I rowsort
SELECT tab0.col1 * + col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT col2 * + col0 + col1 * - col0 FROM tab2
----
-2574
-28
1659

onlyif mysql # use DIV operator for integer division
query I rowsort label-3888
SELECT col2 + - col2 DIV col0 AS col2 FROM tab1 AS cor0
----
36
57
95

skipif mysql # not compatible
query I rowsort label-3888
SELECT col2 + - col2 / col0 AS col2 FROM tab1 AS cor0
----
36
57
95

query I rowsort
SELECT DISTINCT col1 * col2 + 20 FROM tab1 AS cor0
----
1268
1424
590

query I rowsort
SELECT - 48 * - col0 AS col1 FROM tab2 AS cor0
----
336
3744
3792

query I rowsort
SELECT DISTINCT - + col2 * col1 + 4 AS col2 FROM tab1 AS cor0
----
-1244
-1400
-566

query I rowsort
SELECT ALL col1 / col1 AS col1 FROM tab1 WHERE - col2 IN ( col2 )
----

query I rowsort
SELECT DISTINCT col2 * col1 + col2 * col2 FROM tab0
----
14186
3927
98

query I rowsort
SELECT DISTINCT + - col1 - col2 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + + col2 + + ( col0 * + col2 ) AS col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT + + col1 + + 29 AS col1 FROM tab2 cor0
----
46
60
88

query I rowsort
SELECT - col2 * + cor0.col0 + + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL - col2 * - 98 AS col0 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT ALL + cor0.col1 + + 74 * col0 FROM tab0 AS cor0
----
1862
2687
6677

query I rowsort
SELECT ALL + + col1 + - col0 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + col2 + - col0 * - cor0.col1 * col2 FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT + col0 - col1 * col2 FROM tab0 cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + cor0.col2 + + col2 * 31 * + col0 FROM tab2 AS cor0
----
5886
62894
93100

query I rowsort
SELECT DISTINCT col1 * - 36 - col0 FROM tab1 cor0
----
-424
-548
-939

query I rowsort
SELECT - col1 + 61 FROM tab1 AS cor0
----
35
48
51

query I rowsort
SELECT ALL + - col2 * + col0 AS col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - col2 * - cor0.col0 + + ( col0 ) FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL col2 * - 24 + col1 AS col2 FROM tab1
----
-1270
-1358
-2291

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 26 * - col1 col0 FROM tab0
----
-2260
-2455
-2557

query I rowsort
SELECT ALL - 36 * + 20 AS col2 FROM tab0
----
-720
-720
-720

query I rowsort
SELECT 72 + - ( - col0 + - col1 * col1 ) FROM tab2
----
1040
3631
440

query I rowsort
SELECT + 24 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT ALL + 93 * - col1 FROM tab0 AS cor0
----
-7998
-8463
-9021

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3914
SELECT ALL - ( + col2 ) * + CAST( NULL AS SIGNED ) + 19 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3914
SELECT ALL - ( + col2 ) * + CAST ( NULL AS INTEGER ) + 19 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 90 + col1 AS col1 FROM tab2 AS cor0
----
107
121
149

query I rowsort
SELECT DISTINCT col0 * - tab1.col0 AS col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT + 31 * col0 AS col0 FROM tab2 AS cor0
----
217
2418
2449

query I rowsort
SELECT DISTINCT - ( + col0 ) + col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL + - col1 * cor0.col1 * col1 + col2 FROM tab2 AS cor0
----
-205353
-29764
-4875

query I rowsort
SELECT DISTINCT 77 - + cor0.col0 AS col2 FROM tab2 AS cor0
----
-1
-2
70

query I rowsort
SELECT ALL + + col1 * - col1 * col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 WHERE NOT NULL <= NULL
----

query I rowsort
SELECT ALL - col1 - - col2 AS col0 FROM tab0 cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3924
SELECT + col1 + - cor0.col0 DIV + col1 AS col2 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-3924
SELECT + col1 + - cor0.col0 / + col1 AS col2 FROM tab2 AS cor0
----
13
31
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-3925
SELECT + 27 DIV cor0.col0 + col1 * + col0 FROM tab0 AS cor0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort label-3925
SELECT + 27 / cor0.col0 + col1 * + col0 FROM tab0 AS cor0
----
2065
3395
8099

query I rowsort
SELECT DISTINCT col0 * col1 + col1 * + col1 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT - cor0.col2 * - 28 + col2 * col1 FROM tab1 AS cor0
----
2166
2916
3936

onlyif mysql # use DIV operator for integer division
query I rowsort label-3928
SELECT DISTINCT + col1 + + 98 DIV - col0 + - cor0.col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-1236
-1410
-561

skipif mysql # not compatible
query I rowsort label-3928
SELECT DISTINCT + col1 + + 98 / - col0 + - cor0.col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-1236
-1410
-561

query I rowsort
SELECT ALL - col1 + - col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT - cor0.col1 FROM tab1, tab0 cor0, tab0 cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + 65 col2 FROM tab0
----
1560
2275
5785

query I rowsort
SELECT ALL - ( - ( + tab1.col2 ) * tab1.col2 + + col0 ) FROM tab1
----
2913
3185
9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3933
SELECT + CAST( col1 AS SIGNED ) - + col1 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3933
SELECT + CAST ( col1 AS INTEGER ) - + col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col2 * col2 + cor0.col0 * col1 AS col1 FROM tab2 AS cor0
----
2787
5278
946

query I rowsort
SELECT DISTINCT + ( - ( - col1 ) ) + - col1 AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3936
SELECT ALL 33 * - 89 - + col0 DIV + col0 AS col1 FROM tab0 AS cor0
----
-2938
-2938
-2938

skipif mysql # not compatible
query I rowsort label-3936
SELECT ALL 33 * - 89 - + col0 / + col0 AS col1 FROM tab0 AS cor0
----
-2938
-2938
-2938

query I rowsort
SELECT ALL + 30 + col1 FROM tab1 cor0
----
40
43
56

query I rowsort
SELECT - 54 * col0 + + col2 FROM tab2 AS cor0
----
-351
-4186
-4228

query I rowsort
SELECT - 7 AS col2 FROM tab2 cor0
----
-7
-7
-7

query I rowsort
SELECT col1 * col2 * col0 + - col0 FROM tab0
----
3360
664029
68088

query I rowsort
SELECT - 12 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-1152
-648
-684

query I rowsort
SELECT - col2 * + cor0.col0 + + col0 * - col2 AS col2 FROM tab1 AS cor0
----
-15360
-324
-7296

query I rowsort
SELECT + col1 * col1 + + col2 AS col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT ALL - tab0.col0 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT col2 + + 92 FROM tab1 AS cor0
----
146
149
188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3946
SELECT CAST( NULL AS SIGNED ) + ( - col2 + CAST( col0 AS SIGNED ) ) / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3946
SELECT CAST ( NULL AS INTEGER ) + ( - col2 + CAST ( col0 AS INTEGER ) ) / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3947
SELECT - col2 * col1 + + col0 DIV col2 FROM tab0 AS cor0
----
-2838
-62
-7461

skipif mysql # not compatible
query I rowsort label-3947
SELECT - col2 * col1 + + col0 / col2 FROM tab0 AS cor0
----
-2838
-62
-7461

query I rowsort
SELECT + - 3 + + col0 FROM tab1 AS cor0
----
0
61
77

query I rowsort
SELECT + + 7 * col0 + col1 AS col0 FROM tab1 AS cor0
----
458
47
573

onlyif mysql # use DIV operator for integer division
query I rowsort label-3950
SELECT - + col0 DIV - col0 + 22 DIV + 71 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3950
SELECT - + col0 / - col0 + 22 / + 71 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3951
SELECT ALL - + col0 + col1 DIV + 21 FROM tab2 AS cor0
----
-6
-76
-79

skipif mysql # not compatible
query I rowsort label-3951
SELECT ALL - + col0 + col1 / + 21 FROM tab2 AS cor0
----
-6
-76
-79

query I rowsort
SELECT DISTINCT + + col1 * + cor0.col1 * + 24 FROM tab2 cor0
----
23064
6936
83544

query I rowsort
SELECT - col0 + + col0 * - ( col1 ) FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT + 51 * col2 FROM tab1 AS cor0
----
2754
2907
4896

query I rowsort
SELECT - cor0.col1 + + col1 AS col1 FROM tab1 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3956
SELECT col2 + - col0 * - CAST( + 85 AS SIGNED ) FROM tab2 AS cor0
----
622
6656
6753

skipif mysql # not compatible
query I rowsort label-3956
SELECT col2 + - col0 * - CAST ( + 85 AS INTEGER ) FROM tab2 AS cor0
----
622
6656
6753

query I rowsort
SELECT ALL ( col2 * + col2 ) AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT - ( col0 ) * col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT + col0 * ( + cor0.col0 ) FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - ( col2 ) + - col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + - cor0.col2 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL + col0 * col0 + col2 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - 67 + col1 * cor0.col1 * cor0.col0 FROM tab2 AS cor0
----
22764
271451
6660

onlyif mysql # use DIV operator for integer division
query I rowsort label-3965
SELECT DISTINCT tab0.col2 DIV - 40 FROM tab0
----
-2
0

skipif mysql # not compatible
query I rowsort label-3965
SELECT DISTINCT tab0.col2 / - 40 FROM tab0
----
-2
0

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col2 AS col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col2 * cor0.col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + - col0 * cor0.col1 + - col0 AS col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL + ( - 30 ) * col2 FROM tab2 AS cor0
----
-1140
-780
-810

query I rowsort
SELECT + - col1 * 47 AS col0 FROM tab0 AS cor0
----
-4042
-4277
-4559

query I rowsort
SELECT ALL - 38 FROM tab2, tab1 AS cor0
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

onlyif mysql # use DIV operator for integer division
query I rowsort label-3972
SELECT DISTINCT + 53 DIV 13 - col1 * 65 AS col0 FROM tab2
----
-1101
-2011
-3831

skipif mysql # not compatible
query I rowsort label-3972
SELECT DISTINCT + 53 / 13 - col1 * 65 AS col0 FROM tab2
----
-1101
-2011
-3831

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2
----
3645 values hashing to 71d467ba3372dfdd21847af1687c92e7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3974
SELECT DISTINCT + 44 * + col1 - col0 * col1 DIV 28 FROM tab2
----
1357
2432
701

skipif mysql # not compatible
query I rowsort label-3974
SELECT DISTINCT + 44 * + col1 - col0 * col1 / 28 FROM tab2
----
1357
2432
701

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3975
SELECT + + CAST( NULL AS SIGNED ) + col0 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3975
SELECT + + CAST ( NULL AS INTEGER ) + col0 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3976
SELECT - - 71 DIV + col1 AS col1 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-3976
SELECT - - 71 / + col1 AS col1 FROM tab2 AS cor0
----
1
2
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3977
SELECT DISTINCT - - ( col2 ) DIV col0 + col1 AS col2 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-3977
SELECT DISTINCT - - ( col2 ) / col0 + col1 AS col2 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT + + 29 + - col0 FROM tab1 AS cor0
----
-35
-51
26

query I rowsort
SELECT + - 22 FROM tab2 AS cor0
----
-22
-22
-22

query I rowsort
SELECT + 38 * + cor1.col1 FROM tab2, tab2 cor0, tab2 cor1
----
27 values hashing to 4c652f4dc8e412c66c02581dda097b7f

query I rowsort
SELECT ALL + col2 * 16 FROM tab1 cor0
----
1536
864
912

onlyif mysql # use DIV operator for integer division
query I rowsort label-3982
SELECT - col0 + + 89 DIV + col1 FROM tab2 AS cor0
----
-5
-74
-77

skipif mysql # not compatible
query I rowsort label-3982
SELECT - col0 + + 89 / + col1 FROM tab2 AS cor0
----
-5
-74
-77

query I rowsort
SELECT DISTINCT + col2 * ( col0 ) + + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL + 17 + col1 FROM tab1 cor0
----
27
30
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-3985
SELECT ALL - cor0.col1 * col1 - col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-101
-170
-677

skipif mysql # not compatible
query I rowsort label-3985
SELECT ALL - cor0.col1 * col1 - col0 / col0 AS col2 FROM tab1 AS cor0
----
-101
-170
-677

query I rowsort
SELECT DISTINCT + 19 - - col2 FROM tab2 AS cor0
----
45
46
57

query I rowsort
SELECT ALL - + col1 * col1 * - cor0.col0 + - col0 FROM tab0 AS cor0
----
177480
329280
736920

query I rowsort
SELECT ALL - + col2 * + col2 + - ( + 98 ) + + col1 AS col1 FROM tab1 AS cor0
----
-2988
-3337
-9301

query I rowsort
SELECT + 9 * - col1 + col1 AS col0 FROM tab0 cor0
----
-688
-728
-776

onlyif mysql # use DIV operator for integer division
query I rowsort label-3990
SELECT ALL + col1 DIV col1 - ( col1 ) FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-3990
SELECT ALL + col1 / col1 - ( col1 ) FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT ALL + - 97 * - col0 * col1 FROM tab2 AS cor0
----
130271
21049
446394

query I rowsort
SELECT ALL col1 + cor0.col1 AS col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT + 95 + col2 * 89 FROM tab1 AS cor0
----
4901
5168
8639

query I rowsort
SELECT - col2 * + ( + col1 ) + col2 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT ( + 39 ) * + col0 FROM tab2
----
273
3042
3081

query I rowsort
SELECT - + col2 + - cor0.col2 AS col0 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT DISTINCT - - cor0.col1 * col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + cor0.col2 + + col2 * cor0.col1 FROM tab2 AS cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + cor0.col1 ) col2 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT - col1 * - 7 + col2 FROM tab1 AS cor0
----
127
187
236

onlyif mysql # use DIV operator for integer division
query I rowsort label-4001
SELECT - - col1 DIV col0 + + 20 AS col0 FROM tab2 AS cor0
----
20
20
24

skipif mysql # not compatible
query I rowsort label-4001
SELECT - - col1 / col0 + + 20 AS col0 FROM tab2 AS cor0
----
20
20
24

query I rowsort
SELECT DISTINCT 75 * + col2 AS col0 FROM tab1
----
4050
4275
7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-4003
SELECT col2 + col2 * col1 DIV - tab2.col0 AS col1 FROM tab2
----
-92
30
7

skipif mysql # not compatible
query I rowsort label-4003
SELECT col2 + col2 * col1 / - tab2.col0 AS col1 FROM tab2
----
-92
30
7

query I rowsort
SELECT tab0.col2 + tab0.col2 * ( - 33 ) FROM tab0
----
-1056
-2624
-32

query I rowsort
SELECT DISTINCT 83 * col1 FROM tab2
----
1411
2573
4897

query I rowsort
SELECT DISTINCT - + ( + col0 ) * col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + - 33 + + col0 + col1 FROM tab0 AS cor0
----
147
77
99

query I rowsort
SELECT ( col0 ) * col2 * col1 + col2 * - col2 + - cor0.col1 * ( cor0.col0 + 88 ) FROM tab2 AS cor0
----
109182
2185
46751

query I rowsort
SELECT ALL ( 64 ) * col2 FROM tab0 AS cor0
----
2112
5248
64

query I rowsort
SELECT DISTINCT 7 + cor0.col2 * + cor0.col0 FROM tab1 cor0
----
169
3655
7687

query I rowsort
SELECT - 5 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 cor1
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

query I rowsort
SELECT 25 + 1 AS col1 FROM tab0
----
26
26
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 34 col1 FROM tab0
----
2924
3094
3298

query I rowsort
SELECT ALL col1 * 62 * + cor0.col2 FROM tab0 AS cor0
----
175956
462644
6014

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT DISTINCT + - 40 FROM tab0, tab0 AS cor0, tab2, tab0 AS cor1
----
-40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 87 col1 FROM tab2, tab1 cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 3 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col0 + + tab2.col0 col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT - 13 * + col1 FROM tab2
----
-221
-403
-767

query I rowsort
SELECT ALL 48 + - col0 * - 63 FROM tab0 AS cor0
----
1560
2253
5655

query I rowsort
SELECT DISTINCT 36 + col2 * + col1 FROM tab1 cor0
----
1284
1440
606

query I rowsort
SELECT DISTINCT ( - col1 ) * ( - col1 ) * col1 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT DISTINCT - cor0.col2 * 1 FROM tab2, tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - col1 * cor0.col0 + - col0 * col2 * - col1 FROM tab1 AS cor0
----
35840
4134
98800

query I rowsort
SELECT - - col1 + col2 * - col0 FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-4027
SELECT ALL col0 DIV ( 7 ) + tab1.col0 AS col1 FROM tab1
----
3
73
91

skipif mysql # not compatible
query I rowsort label-4027
SELECT ALL col0 / ( 7 ) + tab1.col0 AS col1 FROM tab1
----
3
73
91

query I rowsort
SELECT DISTINCT col0 + col2 * 99 AS col2 FROM tab1
----
5349
5707
9584

query I rowsort
SELECT col0 + - 19 + + col1 AS col1 FROM tab2
----
118
19
77

query I rowsort
SELECT col2 + col1 * + 14 + col1 FROM tab1
----
207
291
444

query I rowsort
SELECT DISTINCT + col0 + - col1 + - col2 FROM tab2
----
-51
-7
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4032
SELECT DISTINCT + tab0.col1 + - CAST( - col2 AS SIGNED ) * col2 FROM tab0
----
1175
6815
98

skipif mysql # not compatible
query I rowsort label-4032
SELECT DISTINCT + tab0.col1 + - CAST ( - col2 AS INTEGER ) * col2 FROM tab0
----
1175
6815
98

query I rowsort
SELECT + col2 + - 29 FROM tab1 AS cor0
----
25
28
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4034
SELECT DISTINCT col1 + + ( - col2 ) * col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4034
SELECT DISTINCT col1 + + ( - col2 ) * col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 + cor0.col2 * cor0.col2 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT + col0 + 53 FROM tab2 AS cor0
----
131
132
60

query I rowsort
SELECT col1 + col2 * col0 * + col0 FROM tab2
----
1354
158243
237175

onlyif mysql # use DIV operator for integer division
query I rowsort label-4038
SELECT + col0 * ( 71 ) DIV + col1 AS col0 FROM tab1
----
436
454
8

skipif mysql # not compatible
query I rowsort label-4038
SELECT + col0 * ( 71 ) / + col1 AS col0 FROM tab1
----
436
454
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 col1 FROM tab0, tab0 cor0, tab0 cor1
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

query I rowsort
SELECT ALL + - col1 * ( col2 ) AS col2 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4041
SELECT - 8 + - col0 * + col0 DIV - col0 AS col0 FROM tab0 cor0
----
16
27
81

skipif mysql # not compatible
query I rowsort label-4041
SELECT - 8 + - col0 * + col0 / - col0 AS col0 FROM tab0 cor0
----
16
27
81

query I rowsort
SELECT ALL - 60 + 65 AS col2 FROM tab2 AS cor0
----
5
5
5

query I rowsort
SELECT DISTINCT + 60 * - col2 AS col2 FROM tab2 AS cor0
----
-1560
-1620
-2280

query I rowsort
SELECT ALL - + col0 * 13 AS col2 FROM tab0 AS cor0
----
-1157
-312
-455

query I rowsort
SELECT 16 * - col0 - - col0 FROM tab0 AS cor0
----
-1335
-360
-525

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4046
SELECT DISTINCT - CAST( NULL AS SIGNED ) / - col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4046
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / - col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * 39 + - col0 AS col0 FROM tab2 AS cor0
----
1202
2223
584

query I rowsort
SELECT DISTINCT - ( - 12 ) * - col1 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
-125
-365
-630

query I rowsort
SELECT + 99 + - col2 AS col2 FROM tab1 AS cor0
----
3
42
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4050
SELECT + - col2 DIV + 84 + + col2 * 53 * - 78 FROM tab2 AS cor0
----
-107484
-111618
-157092

skipif mysql # not compatible
query I rowsort label-4050
SELECT + - col2 / + 84 + + col2 * 53 * - 78 FROM tab2 AS cor0
----
-107484
-111618
-157092

query I rowsort
SELECT + col0 + + col1 + col2 AS col0 FROM tab2
----
134
163
65

query I rowsort
SELECT ALL col2 + 64 * col1 FROM tab1
----
1718
697
928

query I rowsort
SELECT + + col1 + + 21 AS col1 FROM tab2 AS cor0
----
38
52
80

query I rowsort
SELECT + 30 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col0 * col0 col0 FROM tab2 AS cor0
----
6143
6258
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + - cor0.col1 * + col0 col2 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT col2 * col2 + col0 FROM tab1 cor0
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-4058
SELECT col2 DIV col1 + - col2 - tab1.col2 AS col1 FROM tab1
----
-106
-109
-185

skipif mysql # not compatible
query I rowsort label-4058
SELECT col2 / col1 + - col2 - tab1.col2 AS col1 FROM tab1
----
-106
-109
-185

query I rowsort
SELECT ALL col1 + + tab0.col0 * 61 - + tab0.col0 AS col0 FROM tab0
----
1526
2197
5431

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - 21 col0 FROM tab1
----
-11
-8
5

query I rowsort
SELECT tab0.col2 * + col2 + 4 - tab0.col2 FROM tab0
----
1060
4
6646

query I rowsort
SELECT ALL - + cor0.col2 * ( + col2 ) AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + + col1 + 59 FROM tab1 AS cor0
----
69
72
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4064
SELECT - col2 DIV + col1 FROM tab1 cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-4064
SELECT - col2 / + col1 FROM tab1 cor0
----
-2
-5
-7

query I rowsort
SELECT + + col1 + + col0 * + col2 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-4066
SELECT + 15 DIV - cor0.col0 + - col0 DIV 25 FROM tab2 AS cor0
----
-2
-3
-3

skipif mysql # not compatible
query I rowsort label-4066
SELECT + 15 / - cor0.col0 + - col0 / 25 FROM tab2 AS cor0
----
-2
-3
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4067
SELECT - + cor0.col2 DIV + col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-4067
SELECT - + cor0.col2 / + col0 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT ALL + - col1 + + col0 * col1 + + 14 * + col1 AS col2 FROM tab0 cor0
----
3182
4656
9282

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 + col2 * col0 FROM tab0 AS cor0
----
-164
-2046
-62

query I rowsort
SELECT DISTINCT + - col2 + cor0.col2 + 99 * + col1 AS col2 FROM tab2 AS cor0
----
1683
3069
5841

query I rowsort
SELECT + col1 + - col1 * + cor0.col0 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-3298
-664027
-68026

query I rowsort
SELECT ALL + col0 - + col2 AS col0 FROM tab0 cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 + cor0.col0 - col2 col0 FROM tab2 AS cor0
----
1586
687
817

query I rowsort
SELECT DISTINCT + - cor0.col0 * + col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + + col2 + + col0 col1 FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT DISTINCT - col0 * + col2 + - ( cor0.col0 ) FROM tab0 cor0
----
-70
-7387
-816

query I rowsort
SELECT DISTINCT + + col2 + + col2 * ( cor0.col2 ) FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT + col0 - - ( - 83 ) AS col2 FROM tab2 AS cor0
----
-4
-5
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4079
SELECT ALL col2 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4079
SELECT ALL col2 / cor0.col1 AS col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 * col1 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-611966
-93687
-98

query I rowsort
SELECT ALL - - col0 - - col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + cor0.col0 * + 11 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 9ea7d107b96ac6c9959db685b77c3221

query I rowsort
SELECT - 55 - col2 FROM tab2
----
-81
-82
-93

query I rowsort
SELECT DISTINCT + col0 * - col2 * + col1 - - col1 AS col2 FROM tab0 AS cor0
----
-3298
-664027
-68026

query I rowsort
SELECT DISTINCT ( - 20 ) * + col2 - col0 * - 24 FROM tab1 AS cor0
----
-1008
0
396

query I rowsort
SELECT ALL cor0.col1 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - 64 + 51 FROM tab2 AS cor0
----
-13
-13
-13

query I rowsort
SELECT ALL + ( + col1 ) + col0 * - 41 * col1 + col2 FROM tab1 cor0
----
-26173
-3118
-42531

onlyif mysql # use DIV operator for integer division
query I rowsort label-4089
SELECT col0 + - col1 DIV - col2 + 17 FROM tab1 AS cor0
----
20
81
97

skipif mysql # not compatible
query I rowsort label-4089
SELECT col0 + - col1 / - col2 + 17 FROM tab1 AS cor0
----
20
81
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4090
SELECT - - CAST( col1 AS SIGNED ) DIV - col2 + + CAST( + col1 AS SIGNED ) * cor0.col0 FROM tab0 AS cor0
----
2062
3298
8098

skipif mysql # not compatible
query I rowsort label-4090
SELECT - - CAST ( col1 AS INTEGER ) / - col2 + + CAST ( + col1 AS INTEGER ) * cor0.col0 FROM tab0 AS cor0
----
2062
3298
8098

query I rowsort
SELECT ALL + 22 + - col0 AS col0 FROM tab2 cor0
----
-56
-57
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - 67 ) * col0 col2 FROM tab0 AS cor0
----
-1608
-2345
-5963

query I rowsort
SELECT ALL - + 97 + 43 FROM tab2 AS cor0
----
-54
-54
-54

query I rowsort
SELECT + 3 * + 56 + - col1 AS col1 FROM tab2 AS cor0
----
109
137
151

query I rowsort
SELECT DISTINCT + - ( ( col2 ) ) * + cor0.col1 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4096
SELECT DISTINCT + CAST( - ( - col2 ) AS SIGNED ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4096
SELECT DISTINCT + CAST ( - ( - col2 ) AS INTEGER ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col0 * 45 * col0 FROM tab1
----
184320
288000
405

query I rowsort
SELECT DISTINCT + ( col2 * + col0 ) + + col1 * col1 FROM tab0
----
15579
8188
9444

query I rowsort
SELECT - ( + col1 + tab1.col1 ) AS col1 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT + 50 * - 28 + col2 FROM tab1 AS cor0
----
-1304
-1343
-1346

query I rowsort
SELECT - ( - col2 ) + - col2 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4102
SELECT ALL + col2 DIV 52 + tab2.col2 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-4102
SELECT ALL + col2 / 52 + tab2.col2 FROM tab2
----
26
27
38

query I rowsort
SELECT + col2 + + 15 FROM tab0
----
16
48
97

query I rowsort
SELECT DISTINCT + col1 * - 90 FROM tab1
----
-1170
-2340
-900

query I rowsort
SELECT - 91 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4106
SELECT DISTINCT + + col0 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4106
SELECT DISTINCT + + col0 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col0 + 18 AS col0 FROM tab2 AS cor0
----
25
96
97

query I rowsort
SELECT DISTINCT + col2 * 1 + 89 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
2340
2430
3420

onlyif mysql # use DIV operator for integer division
query I rowsort label-4109
SELECT ALL col1 DIV + 52 col2 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4109
SELECT ALL col1 / + 52 col2 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col2 * + col2 col2 FROM tab0 AS cor0
----
-1003
-6633
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4111
SELECT ALL - CAST( 87 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-87
-87
-87

skipif mysql # not compatible
query I rowsort label-4111
SELECT ALL - CAST ( 87 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-87
-87
-87

query I rowsort
SELECT + + col0 * ( + col0 ) AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - + 87 AS col2 FROM tab1 AS cor0
----
-87
-87
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4114
SELECT ALL col0 * col1 DIV - col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-4114
SELECT ALL col0 * col1 / - col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL - 98 + cor0.col0 FROM tab0 cor0
----
-63
-74
-9

query I rowsort
SELECT col1 + 91 * col0 AS col2 FROM tab0 AS cor0
----
2270
3282
8190

query I rowsort
SELECT col2 * + col2 + ( tab2.col0 ) * 9 FROM tab2
----
1378
2155
792

query I rowsort
SELECT + ( + 49 ) FROM tab0 AS cor0
----
49
49
49

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + cor0.col0 AS REAL ) * + col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - ( - col2 ) * col2 * col0 FROM tab0 cor0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-4121
SELECT ALL - col0 DIV + 18 AS col0 FROM tab1 AS cor0
----
-3
-4
0

skipif mysql # not compatible
query I rowsort label-4121
SELECT ALL - col0 / + 18 AS col0 FROM tab1 AS cor0
----
-3
-4
0

query I rowsort
SELECT + cor0.col1 + + col1 * + col0 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + - 56 * - cor0.col1 + - 92 * + 32 FROM tab2 AS cor0
----
-1208
-1992
360

query I rowsort
SELECT col1 + + col2 * + cor0.col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL - col2 * col0 + + ( col0 ) * col0 AS col2 FROM tab2 AS cor0
----
-140
3239
4056

onlyif mysql # use DIV operator for integer division
query I rowsort label-4126
SELECT + tab0.col0 DIV 38 FROM tab0, tab1 AS cor0
----
9 values hashing to e30b1feec13aa0bbbc46a0526de3ebe0

skipif mysql # not compatible
query I rowsort label-4126
SELECT + tab0.col0 / 38 FROM tab0, tab1 AS cor0
----
9 values hashing to e30b1feec13aa0bbbc46a0526de3ebe0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 57 + col2 * tab1.col0 col1 FROM tab1
----
219
3705
7737

query I rowsort
SELECT DISTINCT 0 AS col0 FROM tab0 cor0 CROSS JOIN tab1 cor1
----
0

query I rowsort
SELECT DISTINCT + col2 + col0 * ( - col1 * - col1 ) FROM tab1 AS cor0
----
13616
2082
6457

query I rowsort
SELECT + 70 + col0 * - col2 * col2 FROM tab1 AS cor0
----
-207866
-737210
-8678

onlyif mysql # use DIV operator for integer division
query I rowsort label-4131
SELECT + col1 DIV col2 - col1 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1
0
95

skipif mysql # not compatible
query I rowsort label-4131
SELECT + col1 / col2 - col1 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1
0
95

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - 60 * col2 + - CAST ( - 90 AS REAL ) FROM tab2 AS cor0
----
-1470
-1530
-2190

onlyif mysql # use DIV operator for integer division
query I rowsort label-4133
SELECT DISTINCT + col2 + col0 + + col1 DIV ( - cor0.col0 * - 87 ) FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-4133
SELECT DISTINCT + col2 + col0 + + col1 / ( - cor0.col0 * - 87 ) FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4134
SELECT 92 - col1 DIV + 98 AS col2 FROM tab2 AS cor0
----
92
92
92

skipif mysql # not compatible
query I rowsort label-4134
SELECT 92 - col1 / + 98 AS col2 FROM tab2 AS cor0
----
92
92
92

query I rowsort
SELECT ALL col1 * col2 + + col2 AS col1 FROM tab0 cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT + + col2 + - col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4137
SELECT - ( col1 ) - + CAST( col2 AS SIGNED ) * - col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

skipif mysql # not compatible
query I rowsort label-4137
SELECT - ( col1 ) - + CAST ( col2 AS INTEGER ) * - col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-4138
SELECT DISTINCT - ( - col0 ) DIV 97 AS col2 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4138
SELECT DISTINCT - ( - col0 ) / 97 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT col2 + + col0 * ( cor0.col0 ) AS col2 FROM tab2 AS cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4140
SELECT ALL - - 50 DIV col0 + - 1 FROM tab0 cor0
----
-1
0
1

skipif mysql # not compatible
query I rowsort label-4140
SELECT ALL - - 50 / col0 + - 1 FROM tab0 cor0
----
-1
0
1

query I rowsort
SELECT ALL + col0 * ( col2 ) AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - cor0.col0 * - col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL ( + 87 * - cor0.col1 ) + ( 73 ) AS col2 FROM tab0, tab2 cor0
----
9 values hashing to 525be0d81e514d50a6115bb300ae0ef9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4144
SELECT - col1 DIV - 77 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4144
SELECT - col1 / - 77 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + col0 * + 9 + + col0 AS col2 FROM tab2 AS cor0
----
70
780
790

query I rowsort
SELECT DISTINCT + 99 AS col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
99

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 cor0, tab0 AS cor1, tab0, tab2 cor2
----
3645 values hashing to 972d282d6d92f451c90dc8ca51a18f3e

query I rowsort
SELECT ALL - - cor0.col1 + 96 * + 54 FROM tab0 AS cor0
----
5270
5275
5281

query I rowsort
SELECT ALL col2 * col2 + + 72 AS col0 FROM tab1 AS cor0
----
2988
3321
9288

onlyif mysql # use DIV operator for integer division
query I rowsort label-4150
SELECT ALL - - col0 * + 2 * col1 + col0 DIV col2 FROM tab0 AS cor0
----
16199
4128
6825

skipif mysql # not compatible
query I rowsort label-4150
SELECT ALL - - col0 * + 2 * col1 + col0 / col2 FROM tab0 AS cor0
----
16199
4128
6825

query I rowsort
SELECT DISTINCT + 51 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 85 col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 59 * - col0 + 10 col0 FROM tab0
----
-1406
-2055
-5241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col0 + col0 col2 FROM tab0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4155
SELECT + - col0 + - col0 DIV 46 col0 FROM tab1 AS cor0
----
-3
-65
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4155
SELECT + - col0 + - col0 / 46 col0 FROM tab1 AS cor0
----
-3
-65
-81

query I rowsort
SELECT - col1 + + col2 * + col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT ALL col2 * - cor0.col1 * + col1 AS col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-4158
SELECT - col2 * ( + col0 ) + col1 * ( + col0 ) DIV col1 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif mysql # not compatible
query I rowsort label-4158
SELECT - col2 * ( + col0 ) + col1 * ( + col0 ) / col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT - col1 * ( + 17 ) AS col1 FROM tab2 AS cor0
----
-1003
-289
-527

query I rowsort
SELECT col0 * + ( + col0 ) * + col1 AS col2 FROM tab1 cor0
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 31 + col2 col1 FROM tab1 cor0
----
-1620
-1710
-2880

query I rowsort
SELECT + - 33 FROM tab0, tab1, tab0 cor0
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

query I rowsort
SELECT - - col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT col1 * ( 5 * - col0 ) FROM tab2 AS cor0
----
-1085
-23010
-6715

query I rowsort
SELECT DISTINCT - 89 AS col2 FROM tab0, tab1 AS cor0
----
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4166
SELECT CAST( col1 + - col1 AS SIGNED ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4166
SELECT CAST ( col1 + - col1 AS INTEGER ) FROM tab0
----
0
0
0

query I rowsort
SELECT + + cor1.col2 AS col1 FROM tab0, tab0 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT DISTINCT tab2.col1 * - col0 AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ( 40 ) + + col2 * tab2.col0 AS col1 FROM tab2
----
2068
229
3042

query I rowsort
SELECT 71 AS col1 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT col2 + col0 + 52 * col0 AS col0 FROM tab1
----
213
3449
4336

query I rowsort
SELECT DISTINCT + 99 * + col0 AS col0 FROM tab1 AS cor0
----
297
6336
7920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 79 * + col2 * col0 col2 FROM tab1 AS cor0
----
-12798
-288192
-606720

query I rowsort
SELECT DISTINCT - ( col2 ) + col1 * - 63 FROM tab1 AS cor0
----
-1692
-687
-915

query I rowsort
SELECT - - 19 + + col2 * cor0.col2 FROM tab0 AS cor0
----
1108
20
6743

query I rowsort
SELECT + 13 * col2 FROM tab1 AS cor0
----
1248
702
741

onlyif mysql # use DIV operator for integer division
query I rowsort label-4177
SELECT + cor0.col1 DIV col0 AS col2 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4177
SELECT + cor0.col1 / col0 AS col2 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT col0 * - ( 0 ) AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT 11 * col0 FROM tab2
----
77
858
869

query I rowsort
SELECT ALL ( 44 ) * - col1 FROM tab0
----
-3784
-4004
-4268

query I rowsort
SELECT + 5 * + col2 FROM tab2
----
130
135
190

query I rowsort
SELECT ALL - ( col1 ) * col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT + col0 + + cor0.col2 * + 28 AS col1 FROM tab0 AS cor0
----
2385
63
948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4184
SELECT + col1 * - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4184
SELECT + col1 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 + 27 FROM tab0 AS cor0
----
109
28
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4186
SELECT - col1 + CAST( cor0.col2 AS SIGNED ) + col1 * 88 AS col2 FROM tab2 AS cor0
----
1517
2724
5159

skipif mysql # not compatible
query I rowsort label-4186
SELECT - col1 + CAST ( cor0.col2 AS INTEGER ) + col1 * 88 AS col2 FROM tab2 AS cor0
----
1517
2724
5159

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4187
SELECT + col1 + CAST( NULL AS SIGNED ) + - 80 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4187
SELECT + col1 + CAST ( NULL AS INTEGER ) + - 80 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * col1 * 6 + + col2 FROM tab0 AS cor0
----
44409
49768
56455

query I rowsort
SELECT + col1 + - tab1.col0 * col2 AS col2 FROM tab1
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-4190
SELECT col1 + - ( + ( col2 ) ) DIV ( - 62 * + col1 ) AS col0 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4190
SELECT col1 + - ( + ( col2 ) ) / ( - 62 * + col1 ) AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT - col2 * ( col0 + + tab0.col2 ) AS col0 FROM tab0
----
-14022
-1881
-36

query I rowsort
SELECT DISTINCT col1 * + 46 + - col2 * + col0 AS col2 FROM tab0
----
-3112
3164
4427

query I rowsort
SELECT col2 * tab2.col2 * + tab2.col2 AS col1 FROM tab2
----
17576
19683
54872

query I rowsort
SELECT DISTINCT col2 * + col1 * + 47 + col0 FROM tab0
----
133410
350803
4594

onlyif mysql # use DIV operator for integer division
query I rowsort label-4195
SELECT - col2 DIV 95 + + 71 AS col0 FROM tab1 AS cor0
----
70
71
71

skipif mysql # not compatible
query I rowsort label-4195
SELECT - col2 / 95 + + 71 AS col0 FROM tab1 AS cor0
----
70
71
71

query I rowsort
SELECT col0 + 31 * col2 AS col1 FROM tab2 AS cor0
----
1257
844
884

query I rowsort
SELECT DISTINCT + + col1 * + col1 + + col0 FROM tab1 AS cor0
----
164
249
679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4198
SELECT - + cor0.col0 * + CAST( 43 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
-1504
-3745
-999

skipif mysql # not compatible
query I rowsort label-4198
SELECT - + cor0.col0 * + CAST ( 43 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
-1504
-3745
-999

query I rowsort
SELECT DISTINCT col2 * 1 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + + cor0.col1 + - col0 * col0 FROM tab0 AS cor0
----
-1128
-490
-7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-4201
SELECT - - CAST( cor0.col0 AS SIGNED ) DIV col1 AS col0 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-4201
SELECT - - CAST ( cor0.col0 AS INTEGER ) / col1 AS col0 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ALL + col1 * + 68 + - col0 * - 12 AS col2 FROM tab1 cor0
----
1448
1804
1844

onlyif mysql # use DIV operator for integer division
query I rowsort label-4203
SELECT 4 DIV - col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4203
SELECT 4 / - col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * + 80 AS col1 FROM tab1 AS cor0
----
-4320
-4560
-7680

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - 49 AS REAL ) FROM tab0 AS cor0
----
-49
-49
-49

query I rowsort
SELECT ALL 49 + - col0 AS col0 FROM tab2 AS cor0
----
-29
-30
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-4207
SELECT 24 + - col2 DIV + col1 AS col1 FROM tab2 AS cor0
----
22
24
24

skipif mysql # not compatible
query I rowsort label-4207
SELECT 24 + - col2 / + col1 AS col1 FROM tab2 AS cor0
----
22
24
24

query I rowsort
SELECT + col0 - + tab2.col1 * + col0 FROM tab2
----
-1264
-210
-4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4209
SELECT + CAST( col2 AS SIGNED ) + + col0 AS col1 FROM tab2 cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-4209
SELECT + CAST ( col2 AS INTEGER ) + + col0 AS col1 FROM tab2 cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col0 + col0 col1 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT ALL - + ( col1 ) + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( + 95 ) AS col0 FROM tab2 AS cor0
----
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4213
SELECT DISTINCT col1 * col2 + col0 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4213
SELECT DISTINCT col1 * col2 + col0 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4214
SELECT - - col1 * col0 DIV col0 + + 77 FROM tab1 AS cor0
----
103
87
90

skipif mysql # not compatible
query I rowsort label-4214
SELECT - - col1 * col0 / col0 + + 77 FROM tab1 AS cor0
----
103
87
90

query I rowsort
SELECT - - col2 + + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + 35 FROM tab0 cor0
----
35
35
35

query I rowsort
SELECT DISTINCT + col1 - col2 AS col0 FROM tab0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4218
SELECT - col1 + cor0.col0 DIV + col0 - - col1 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4218
SELECT - col1 + cor0.col0 / + col0 - - col1 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT 71 + col1 * col0 AS col2 FROM tab2 cor0
----
1414
288
4673

query I rowsort
SELECT ALL tab2.col2 * - ( col1 ) * - 18 FROM tab2
----
11628
15066
27612

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 * col0 - + col1 col0 FROM tab1 cor0
----
-17
4086
6387

query I rowsort
SELECT DISTINCT - 70 FROM tab1 cor0
----
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 57 col2 FROM tab1
----
57
57
57

query I rowsort
SELECT ALL - col0 - - 67 AS col1 FROM tab1 AS cor0
----
-13
3
64

query I rowsort
SELECT ALL - + col2 * - 58 AS col0 FROM tab0 AS cor0
----
1914
4756
58

query I rowsort
SELECT ALL + col1 * + cor0.col2 + 14 AS col1 FROM tab2 AS cor0
----
1548
660
851

onlyif mysql # use DIV operator for integer division
query I rowsort label-4227
SELECT - 64 * col0 DIV + col0 col0 FROM tab0
----
-64
-64
-64

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4227
SELECT - 64 * col0 / + col0 col0 FROM tab0
----
-64
-64
-64

query I rowsort
SELECT col1 + + 63 AS col1 FROM tab2
----
122
80
94

query I rowsort
SELECT DISTINCT - 31 + - 56 AS col1 FROM tab0, tab2, tab2 AS cor0
----
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4230
SELECT DISTINCT tab2.col0 + 93 DIV col0 FROM tab2
----
20
79
80

skipif mysql # not compatible
query I rowsort label-4230
SELECT DISTINCT tab2.col0 + 93 / col0 FROM tab2
----
20
79
80

query I rowsort
SELECT DISTINCT + col0 + col0 + + ( + 7 * col1 ) AS col2 FROM tab1 AS cor0
----
188
198
251

query I rowsort
SELECT cor0.col0 * + cor0.col0 + col2 * + 23 FROM tab1 AS cor0
----
1251
5407
8608

query I rowsort
SELECT - - ( cor0.col0 ) + - col1 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT col2 + - col2 + + col1 FROM tab2
----
17
31
59

query I rowsort
SELECT + 20 FROM tab1, tab0 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT col2 + - col1 * - col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT ( col2 ) + tab2.col0 * - col1 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT 25 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT 61 + - col2 * col2 + tab0.col1 AS col1 FROM tab0
----
-6572
-942
157

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + cor0.col0 * - col1 * - col1 col1 FROM tab2 AS cor0
----
22814
271459
6696

query I rowsort
SELECT ALL cor0.col2 * cor0.col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + + cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - col0 + + col0 * - ( + 22 + col2 ) FROM tab0 cor0
----
-1344
-840
-9345

query I rowsort
SELECT - + ( col1 ) * 27 AS col0 FROM tab0 cor0
----
-2322
-2457
-2619

query I rowsort
SELECT ALL 80 + cor0.col0 * 92 AS col2 FROM tab2 AS cor0
----
724
7256
7348

query I rowsort
SELECT + col2 + - col1 * + ( col2 * - col2 ) + - ( ( col1 ) + col1 ) FROM tab1 AS cor0
----
119878
32527
75818

query I rowsort
SELECT DISTINCT - + ( col1 ) * - col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT col0 + + 38 AS col2 FROM tab2
----
116
117
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4249
SELECT ALL - + cor0.col2 DIV col0 + col2 * col0 * col1 FROM tab0 AS cor0
----
3395
664118
68111

skipif mysql # not compatible
query I rowsort label-4249
SELECT ALL - + cor0.col2 / col0 + col2 * col0 * col1 FROM tab0 AS cor0
----
3395
664118
68111

query I rowsort
SELECT ALL - col1 * - ( - 49 ) + - col1 AS col1 FROM tab2 AS cor0
----
-1550
-2950
-850

query I rowsort
SELECT DISTINCT + + col0 - col1 * - col2 AS col0 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 56 * cor0.col0 col0 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT ALL 46 * - col2 FROM tab0 AS cor0
----
-1518
-3772
-46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4254
SELECT ALL + CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4254
SELECT ALL + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + - col1 + cor0.col0 AS col2 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT ALL - 29 FROM tab0 cor0
----
-29
-29
-29

query I rowsort
SELECT ( col1 ) + cor0.col1 * + col1 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4258
SELECT ALL CAST( + cor0.col2 AS SIGNED ) + col0 * - col2 AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

skipif mysql # not compatible
query I rowsort label-4258
SELECT ALL CAST ( + cor0.col2 AS INTEGER ) + col0 * - col2 AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - 3 + col2 + col1 AS col0 FROM tab2 AS cor0
----
52
55
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 * 5 + - col2 col0 FROM tab2 cor0
----
-156
-162
-228

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - 8 col0 FROM tab0 cor0
----
264
656
8

query I rowsort
SELECT DISTINCT 87 + 72 FROM tab2 AS cor0
----
159

query I rowsort
SELECT + col2 + col2 + col2 * + col1 AS col0 FROM tab0 AS cor0
----
2904
7626
99

query I rowsort
SELECT DISTINCT - 95 FROM tab0 cor0
----
-95

query I rowsort
SELECT ALL + + ( - col1 ) * cor0.col2 + cor0.col2 * ( + col0 ) AS col1 FROM tab0 AS cor0
----
-164
-2046
-62

query I rowsort
SELECT - - col0 * col0 + + col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL col1 * - 57 AS col1 FROM tab2 AS cor0
----
-1767
-3363
-969

query I rowsort
SELECT ALL - - col0 * col0 + + cor0.col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT + - ( col0 ) * col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + - col0 + - 88 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
-267
-5696
-7120

query I rowsort
SELECT 87 * col2 * col2 FROM tab2 AS cor0
----
125628
58812
63423

query I rowsort
SELECT DISTINCT - ( - cor0.col0 ) - + col1 AS col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + col1 + col0 * + cor0.col1 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-4274
SELECT col0 DIV + 90 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4274
SELECT col0 / + 90 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4275
SELECT DISTINCT + cor0.col2 DIV cor0.col2 + - 46 - cor0.col2 AS col0 FROM tab0 AS cor0
----
-127
-46
-78

skipif mysql # not compatible
query I rowsort label-4275
SELECT DISTINCT + cor0.col2 / cor0.col2 + - 46 - cor0.col2 AS col0 FROM tab0 AS cor0
----
-127
-46
-78

query I rowsort
SELECT ALL - 1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - 30 col2 FROM tab1 cor0
----
-1620
-1710
-2880

query I rowsort
SELECT DISTINCT col1 + - col0 * ( + col0 ) AS col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT + - col1 * + ( cor0.col0 * + col2 ) FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - col0 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT 0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - 61 * - cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 549898816cae2e868cfcf2407ea21c95

onlyif mysql # use DIV operator for integer division
query I rowsort label-4283
SELECT ALL 54 DIV 50 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-4283
SELECT ALL 54 / 50 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT DISTINCT - ( + 14 ) AS col1 FROM tab2, tab1 AS cor0
----
-14

query I rowsort
SELECT DISTINCT 37 AS col2 FROM tab0, tab1 AS cor0
----
37

query I rowsort
SELECT DISTINCT col2 * 27 AS col2 FROM tab2
----
1026
702
729

query I rowsort
SELECT DISTINCT 39 FROM tab1, tab0 AS cor0
----
39

skipif mysql # not compatible
query I rowsort
SELECT ALL - col2 * - CAST ( col2 AS REAL ) FROM tab2
----
1444
676
729

query I rowsort
SELECT + col1 * cor0.col1 + cor0.col2 AS col2 FROM tab0 cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT - col0 * + 8 AS col1 FROM tab2 AS cor0
----
-56
-624
-632

query I rowsort
SELECT col1 + col0 * - col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT cor0.col1 * + col0 + - col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT ALL col0 * - 84 AS col1 FROM tab0 AS cor0
----
-2016
-2940
-7476

query I rowsort
SELECT - col1 + 11 FROM tab2 AS cor0
----
-20
-48
-6

query I rowsort
SELECT DISTINCT - col2 * - col1 + col0 * col2 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT + + col1 + - 68 FROM tab0 AS cor0
----
18
23
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-4297
SELECT ALL - col0 DIV col1 col1 FROM tab2 cor0
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4297
SELECT ALL - col0 / col1 col1 FROM tab2 cor0
----
-1
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4298
SELECT DISTINCT + col1 DIV col2 + col1 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4298
SELECT DISTINCT + col1 / col2 + col1 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT cor0.col2 + - ( + col2 ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col1 + - 67 AS col0 FROM tab2 AS cor0
----
-36
-50
-8

query I rowsort
SELECT DISTINCT - - cor0.col2 * col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT 61 + col1 AS col2 FROM tab1 AS cor0
----
71
74
87

query I rowsort
SELECT DISTINCT - - ( ( col2 ) ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + - cor0.col1 * + col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - - ( 23 ) AS col1 FROM tab0 cor0
----
23
23
23

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0, tab0 cor1, tab0, tab2 cor2
----
3645 values hashing to 28412d50061391eec23a02d0efcfb3f9

query I rowsort
SELECT + + col0 * - col1 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab1, tab0 cor1, tab2, tab2 AS cor2, tab0 AS cor3
----
13122 values hashing to 0d5eed6a188e0ee17c524524186e0d13

query I rowsort
SELECT ( cor0.col2 ) AS col2 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4310
SELECT ALL - col1 + col1 / CAST( NULL AS SIGNED ) + ( col0 ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4310
SELECT ALL - col1 + col1 / CAST ( NULL AS INTEGER ) + ( col0 ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( tab2.col0 ) * + col2 * col2 + 57 FROM tab2
----
-114019
-5046
-52671

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 79 col0 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT ( col1 ) * col0 * + 80 - - tab1.col1 * 35 FROM tab1
----
51550
7150
83655

query I rowsort
SELECT ALL 36 - tab2.col2 AS col1 FROM tab2
----
-2
10
9

query I rowsort
SELECT DISTINCT col1 * + col2 - - ( + col0 * + col0 ) AS col0 FROM tab0
----
1322
15383
3414

query I rowsort
SELECT + ( - col1 ) AS col2 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT cor0.col1 * 40 FROM tab2, tab2 cor0
----
9 values hashing to 64f3ea7789613fe9445277e8480f6b00

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4318
SELECT col0 * col0 + - CAST( NULL AS DECIMAL ) * - col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4318
SELECT col0 * col0 + - CAST ( NULL AS REAL ) * - col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + tab2.col0 + col1 - 19 FROM tab2
----
118
19
77

query I rowsort
SELECT DISTINCT - col2 + col0 - col1 FROM tab0
----
-63
-84
-95

query I rowsort
SELECT DISTINCT - col2 + - 79 + - 56 * col1 * - 13 AS col2 FROM tab1
----
18795
7144
9289

query I rowsort
SELECT col0 + tab2.col1 + - tab2.col0 AS col1 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL - col0 + - 12 FROM tab2
----
-19
-90
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4324
SELECT DISTINCT + tab0.col2 + - CAST( NULL AS SIGNED ) + - col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4324
SELECT DISTINCT + tab0.col2 + - CAST ( NULL AS INTEGER ) + - col1 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT col0 + - ( + col1 ) FROM tab0
----
-2
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4326
SELECT col2 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4326
SELECT col2 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + col0 * col0 + col2 FROM tab2
----
107
6169
6296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4328
SELECT - col0 + - CAST( 28 AS SIGNED ) * col0 AS col0 FROM tab1
----
-1856
-2320
-87

skipif mysql # not compatible
query I rowsort label-4328
SELECT - col0 + - CAST ( 28 AS INTEGER ) * col0 AS col0 FROM tab1
----
-1856
-2320
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4329
SELECT + col1 * + cor0.col2 + col0 DIV - col1 FROM tab1 AS cor0
----
1242
1404
564

skipif mysql # not compatible
query I rowsort label-4329
SELECT + col1 * + cor0.col2 + col0 / - col1 FROM tab1 AS cor0
----
1242
1404
564

query I rowsort
SELECT col1 - + 59 * col1 AS col2 FROM tab2 AS cor0
----
-1798
-3422
-986

query I rowsort
SELECT - col0 * 96 AS col0 FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT DISTINCT - + cor0.col0 * + col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4333
SELECT - col0 DIV - cor0.col1 + 14 + col0 FROM tab0 AS cor0
----
103
38
49

skipif mysql # not compatible
query I rowsort label-4333
SELECT - col0 / - cor0.col1 + 14 + col0 FROM tab0 AS cor0
----
103
38
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4334
SELECT ( 40 * - col2 ) + CAST( NULL AS SIGNED ) / - col0 col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4334
SELECT ( 40 * - col2 ) + CAST ( NULL AS INTEGER ) / - col0 col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col0 ) col1 FROM tab1
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4336
SELECT ALL - 23 DIV - 54 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4336
SELECT ALL - 23 / - 54 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4337
SELECT ALL - cor1.col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4337
SELECT ALL - cor1.col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + + 89 * col2 AS col2 FROM tab1 AS cor0
----
4806
5073
8544

query I rowsort
SELECT DISTINCT + 40 * + col1 FROM tab1 cor0
----
1040
400
520

query I rowsort
SELECT DISTINCT - + 24 * col1 FROM tab1 AS cor0
----
-240
-312
-624

query I rowsort
SELECT - - 91 * col2 FROM tab0 AS cor0
----
3003
7462
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4342
SELECT ALL + 44 + col0 * CAST( NULL AS SIGNED ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4342
SELECT ALL + 44 + col0 * CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 49 AS col0 FROM tab1 cor0
----
-49
-49
-49

onlyif mysql # use DIV operator for integer division
query I rowsort label-4344
SELECT - col2 + - col2 DIV - ( col0 + cor0.col2 * - ( col1 ) ) AS col0 FROM tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4344
SELECT - col2 + - col2 / - ( col0 + cor0.col2 * - ( col1 ) ) AS col0 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col2 * col1 + 40 * col2 * - col1 + cor0.col1 * - 75 AS col1 FROM tab0 cor0
----
-11058
-117132
-297843

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 14 * cor0.col1 col0 FROM tab2 AS cor0
----
238
434
826

query I rowsort
SELECT DISTINCT ( 29 ) FROM tab1, tab0, tab0 cor0
----
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 ) * - ( col1 ) + - col1 col2 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) AS col1 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - 40 AS col2 FROM tab1 AS cor0
----
-40
-40
-40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4351
SELECT ALL CAST( NULL AS SIGNED ) + col2 * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4351
SELECT ALL CAST ( NULL AS INTEGER ) + col2 * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 35 + col0 FROM tab0 AS cor0
----
124
59
70

query I rowsort
SELECT ( - col2 ) * + col0 * - ( - col1 ) FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + 25 * - col0 + + cor0.col2 * col0 FROM tab1 cor0
----
2048
5680
87

query I rowsort
SELECT + - 31 FROM tab0 cor0
----
-31
-31
-31

query I rowsort
SELECT ALL - col2 + 14 AS col2 FROM tab0 AS cor0
----
-19
-68
13

query I rowsort
SELECT - 99 + cor0.col0 FROM tab1 AS cor0
----
-19
-35
-96

query I rowsort
SELECT 2 * 48 FROM tab2 AS cor0
----
96
96
96

query I rowsort
SELECT - 81 * - col2 + col1 * - col1 + - 78 FROM tab1
----
3620
4439
7529

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 * col0 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col1 + ( col0 ) AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT col2 + 19 + - col0 * col2 AS col0 FROM tab1
----
-3572
-7565
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4363
SELECT DISTINCT CAST( + col1 AS SIGNED ) AS col2 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4363
SELECT DISTINCT CAST ( + col1 AS INTEGER ) AS col2 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL - 20 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

query I rowsort
SELECT 83 + + tab1.col1 FROM tab1
----
109
93
96

query I rowsort
SELECT DISTINCT - 78 + + col0 FROM tab1
----
-14
-75
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4367
SELECT col0 * 55 DIV tab0.col0 col0 FROM tab0
----
55
55
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4367
SELECT col0 * 55 / tab0.col0 col0 FROM tab0
----
55
55
55

query I rowsort
SELECT + col2 * - 41 FROM tab2 AS cor0
----
-1066
-1107
-1558

query I rowsort
SELECT DISTINCT - tab0.col1 * + col0 AS col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + + col1 * + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT col0 * 80 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT col1 * - col1 + ( tab0.col0 ) * - col0 AS col1 FROM tab0
----
-10634
-16202
-7972

query I rowsort
SELECT + 20 * + col0 AS col2 FROM tab2
----
140
1560
1580

query I rowsort
SELECT - 79 + col1 FROM tab0
----
12
18
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4376
SELECT col1 + tab2.col2 * CAST( + 35 AS SIGNED ) * + col0 AS col0 FROM tab2
----
105087
6646
71039

skipif mysql # not compatible
query I rowsort label-4376
SELECT col1 + tab2.col2 * CAST ( + 35 AS INTEGER ) * + col0 AS col0 FROM tab2
----
105087
6646
71039

query I rowsort
SELECT - 12 * col0 + + 47 * - col2 FROM tab0
----
-1839
-467
-4922

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab1 cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4379
SELECT DISTINCT + + col2 DIV 52 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4379
SELECT DISTINCT + + col2 / 52 FROM tab2 AS cor0
----
0

query I rowsort
SELECT cor0.col1 * 67 FROM tab0 AS cor0
----
5762
6097
6499

query I rowsort
SELECT tab2.col1 + ( col1 ) FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT + col2 - + 82 FROM tab2 AS cor0
----
-44
-55
-56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4383
SELECT - CAST( NULL AS SIGNED ) * - 32 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4383
SELECT - CAST ( NULL AS INTEGER ) * - 32 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col0 * col2 col1 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT col1 * 35 * - col0 AS col0 FROM tab0 AS cor0
----
-118825
-283465
-72240

query I rowsort
SELECT 72 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT 41 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
81 values hashing to 0733f496a5445ffeac9d19797afe4831

query I rowsort
SELECT - col2 + + col1 * col1 AS col0 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT - - col2 + - col2 * col2 FROM tab2 AS cor0
----
-1406
-650
-702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4390
SELECT - + CAST( + ( + col0 ) AS SIGNED ) FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-4390
SELECT - + CAST ( + ( + col0 ) AS INTEGER ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT 23 * col2 FROM tab1
----
1242
1311
2208

onlyif mysql # use DIV operator for integer division
query I rowsort label-4392
SELECT - - col2 + + col1 DIV CAST( - 17 * col0 AS SIGNED ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-4392
SELECT - - col2 + + col1 / CAST ( - 17 * col0 AS INTEGER ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL ( col0 ) * - 54 AS col2 FROM tab0 AS cor0
----
-1296
-1890
-4806

query I rowsort
SELECT - - 81 + - col1 * col0 AS col0 FROM tab1 cor0
----
-559
-959
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4395
SELECT + col1 + + col0 + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4395
SELECT + col1 + + col0 + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 + cor0.col0 + 13 AS col0 FROM tab0 AS cor0
----
13

query I rowsort
SELECT DISTINCT + + cor0.col2 + - col2 FROM tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4398
SELECT - 97 * col2 + CAST( NULL AS SIGNED ) / col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4398
SELECT - 97 * col2 + CAST ( NULL AS INTEGER ) / col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 26 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT ALL 39 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT ( 59 ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT - + col0 * - col2 * 82 FROM tab0 AS cor0
----
2870
598436
64944

query I rowsort
SELECT col1 * ( cor0.col2 * col2 ) + + 78 * col0 FROM tab0 AS cor0
----
2827
618826
95526

query I rowsort
SELECT + cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + - col0 col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT col2 + - ( col2 ) * col2 AS col1 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT - col2 - - 28 FROM tab2 AS cor0
----
-10
1
2

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col0 AS REAL ) * cor0.col2 + ( + 58 ) * + col1 FROM tab0 AS cor0
----
12576
5661
5780

query I rowsort
SELECT - + cor0.col0 * cor0.col1 + ( cor0.col0 ) * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-2686
-434
-9204

query I rowsort
SELECT - + col0 * col1 + cor0.col0 + + cor0.col1 AS col2 FROM tab1 cor0
----
-49
-566
-947

onlyif mysql # use DIV operator for integer division
query I rowsort label-4411
SELECT 43 DIV col1 AS col2 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4411
SELECT 43 / col1 AS col2 FROM tab2
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 27 col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27

query I rowsort
SELECT DISTINCT - + col0 * - col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4414
SELECT + - col1 * - cor0.col0 + col0 + 92 DIV col2 FROM tab1 AS cor0
----
1120
705
82

skipif mysql # not compatible
query I rowsort label-4414
SELECT + - col1 * - cor0.col0 + col0 + 92 / col2 FROM tab1 AS cor0
----
1120
705
82

query I rowsort
SELECT + - cor0.col0 * - col2 AS col0 FROM tab1 cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 25 * - cor0.col0 + - col2 col1 FROM tab0 AS cor0
----
-2307
-633
-876

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col2 ) + col2 col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ( col2 ) * + col0 * col2 FROM tab0 AS cor0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-4419
SELECT DISTINCT cor0.col0 DIV col1 + col1 DIV - col1 col2 FROM tab2 AS cor0
----
-1
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4419
SELECT DISTINCT cor0.col0 / col1 + col1 / - col1 col2 FROM tab2 AS cor0
----
-1
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 57 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT + 42 * - col0 AS col1 FROM tab0 AS cor0
----
-1008
-1470
-3738

query I rowsort
SELECT - - col2 - 94 AS col1 FROM tab0 AS cor0
----
-12
-61
-93

query I rowsort
SELECT + ( - 45 ) + + col0 FROM tab2 AS cor0
----
-38
33
34

query I rowsort
SELECT + col2 - - col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL ( + col2 ) * col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4426
SELECT - col1 DIV col0 - col2 FROM tab0 AS cor0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-4426
SELECT - col1 / col0 - col2 FROM tab0 AS cor0
----
-3
-36
-83

query I rowsort
SELECT DISTINCT - + col2 * - col2 + col0 AS col2 FROM tab2 cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT + col1 - col0 AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - 96 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to a7b3e5dd01c8929180b7ffda67f79798

query I rowsort
SELECT DISTINCT cor0.col1 + 88 + col0 AS col1 FROM tab0 cor0
----
198
220
268

query I rowsort
SELECT DISTINCT + + ( + 55 ) * + col1 FROM tab1 cor0
----
1430
550
715

query I rowsort
SELECT - ( + col0 ) + cor0.col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4433
SELECT + CAST( NULL AS SIGNED ) * col0 + + cor0.col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4433
SELECT + CAST ( NULL AS INTEGER ) * col0 + + cor0.col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 9 + - col2 + col1 FROM tab2 AS cor0
----
-30
-5
24

query I rowsort
SELECT 94 * col1 * tab0.col1 + + col1 AS col1 FROM tab0
----
695310
778505
884543

query I rowsort
SELECT ALL - 98 * col2 - col2 FROM tab0
----
-3267
-8118
-99

query I rowsort
SELECT 20 + col1 AS col0 FROM tab2
----
37
51
79

query I rowsort
SELECT - col0 + - col2 * col0 AS col0 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT - 1 + + cor0.col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to b0368675532cc334130b524d1349d372

query I rowsort
SELECT - col0 + col0 * col2 FROM tab1 cor0
----
159
3584
7600

query I rowsort
SELECT 82 + col1 AS col0 FROM tab2
----
113
141
99

query I rowsort
SELECT - + ( - 5 ) AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT ALL + col2 * 5 FROM tab2 AS cor0
----
130
135
190

query I rowsort
SELECT DISTINCT + col0 + 66 * - col1 AS col1 FROM tab0 AS cor0
----
-5652
-5917
-6367

query I rowsort
SELECT col2 + col1 + ( col0 ) AS col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT - 65 + - col2 * col0 AS col2 FROM tab1
----
-227
-3713
-7745

query I rowsort
SELECT col1 + ( 70 ) * - tab0.col2 AS col0 FROM tab0
----
-2224
-5649
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 83 col0 FROM tab1 AS cor0
----
137
140
179

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4449
SELECT ALL col1 * - CAST( + col2 AS SIGNED ) + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif mysql # not compatible
query I rowsort label-4449
SELECT ALL col1 * - CAST ( + col2 AS INTEGER ) + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL col1 * 24 FROM tab0 AS cor0
----
2064
2184
2328

query I rowsort
SELECT - col0 + ( - col0 ) * col2 * - 64 FROM tab1 cor0
----
10365
233408
491440

query I rowsort
SELECT cor0.col1 AS col2 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT DISTINCT - - col0 + col1 - 85 AS col1 FROM tab0 AS cor0
----
25
47
95

query I rowsort
SELECT ALL - - col1 + col1 * ( col2 ) AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - col0 * - ( col2 ) AS col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + + col1 * + col0 * + col0 FROM tab0 cor0
----
118825
49536
720811

query I rowsort
SELECT + col0 - + col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 * cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT - col1 * + col2 + 93 * col2 FROM tab1 AS cor0
----
3618
4731
7680

query I rowsort
SELECT ALL col0 + - 45 AS col0 FROM tab2 AS cor0
----
-38
33
34

query I rowsort
SELECT DISTINCT - ( - col1 ) * col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - ( + cor0.col0 ) FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + 82 - 11 FROM tab1 AS cor0
----
71

query I rowsort
SELECT DISTINCT + ( + col1 ) * col0 + + cor0.col0 * - cor0.col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT col1 + + 85 * - col2 AS col2 FROM tab0 AS cor0
----
-2719
-6879
12

query I rowsort
SELECT ALL + col0 * cor0.col0 + col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL + 38 AS col1 FROM tab0 cor0
----
38
38
38

query I rowsort
SELECT ALL + + col0 * 21 FROM tab0 AS cor0
----
1869
504
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-4469
SELECT DISTINCT col1 DIV 16 AS col2 FROM tab2 cor0
----
1
3

skipif mysql # not compatible
query I rowsort label-4469
SELECT DISTINCT col1 / 16 AS col2 FROM tab2 cor0
----
1
3

query I rowsort
SELECT 26 AS col2 FROM tab0 cor0
----
26
26
26

query I rowsort
SELECT - + 53 * 12 * + col0 AS col2 FROM tab2 AS cor0
----
-4452
-49608
-50244

query I rowsort
SELECT - col0 - ( - col2 ) AS col2 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL - 26 * 18 + col2 + col2 AS col2 FROM tab1 AS cor0
----
-276
-354
-360

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col1 AS REAL ) - + col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - ( 77 ) FROM tab2 AS cor0
----
-77
-77
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4476
SELECT CAST( NULL AS SIGNED ) + 75 / - tab1.col0 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4476
SELECT CAST ( NULL AS INTEGER ) + 75 / - tab1.col0 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 65 * + col0 FROM tab2 AS cor0
----
455
5070
5135

query I rowsort
SELECT ALL col0 * + 78 + col0 * col2 AS col1 FROM tab2 cor0
----
735
8112
9164

query I rowsort
SELECT + col0 + cor0.col1 + - col1 * 49 AS col1 FROM tab1 cor0
----
-1245
-416
-544

query I rowsort
SELECT - col1 * col2 + - 12 FROM tab1 AS cor0
----
-1260
-1416
-582

query I rowsort
SELECT - + col2 * + col1 + col2 * cor0.col0 FROM tab2 AS cor0
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-4482
SELECT + col1 * - col1 + col2 + cor0.col2 DIV + col0 col2 FROM tab1 cor0
----
-43
-604
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4482
SELECT + col1 * - col1 + col2 + cor0.col2 / + col0 col2 FROM tab1 cor0
----
-43
-604
-72

query I rowsort
SELECT - 91 + - col1 + + col2 FROM tab2 AS cor0
----
-124
-70
-95

query I rowsort
SELECT DISTINCT + col2 * col2 * + col0 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT - 31 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

query I rowsort
SELECT col1 + 56 FROM tab2
----
115
73
87

query I rowsort
SELECT + ( cor0.col0 ) + col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT 24 * + col2 FROM tab1 AS cor0
----
1296
1368
2304

query I rowsort
SELECT 2 + 81 AS col0 FROM tab1 AS cor0
----
83
83
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4490
SELECT ALL - - col2 DIV + 34 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4490
SELECT ALL - - col2 / + 34 FROM tab2 cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + + col0 + col2 * - 36 AS col2 FROM tab0 AS cor0
----
-1
-1164
-2863

query I rowsort
SELECT 20 * col2 AS col1 FROM tab0
----
1640
20
660

query I rowsort
SELECT + 78 + col0 AS col0 FROM tab2 AS cor0
----
156
157
85

query I rowsort
SELECT 6 + + col0 + col2 AS col0 FROM tab0 AS cor0
----
177
42
63

query I rowsort
SELECT ALL col1 * + col2 * col1 AS col0 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT + col1 * 98 - col0 AS col2 FROM tab2 AS cor0
----
1587
3031
5704

query I rowsort
SELECT + col2 * + ( col2 ) + col1 + cor0.col2 * + col0 * col1 AS col0 FROM tab1 AS cor0
----
109069
39739
7154

onlyif mysql # use DIV operator for integer division
query I rowsort label-4498
SELECT + 80 * - col2 + col2 + + 92 DIV + col0 AS col1 FROM tab0 AS cor0
----
-2604
-6477
-77

skipif mysql # not compatible
query I rowsort label-4498
SELECT + 80 * - col2 + col2 + + 92 / + col0 AS col1 FROM tab0 AS cor0
----
-2604
-6477
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4499
SELECT - + cor0.col0 + - ( col0 ) DIV col1 + + col1 FROM tab1 AS cor0
----
-60
-73
23

skipif mysql # not compatible
query I rowsort label-4499
SELECT - + cor0.col0 + - ( col0 ) / col1 + + col1 FROM tab1 AS cor0
----
-60
-73
23

query I rowsort
SELECT - - col1 + - ( col1 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + + 97 * + 77 FROM tab2 AS cor0
----
7495
7496
7507

onlyif mysql # use DIV operator for integer division
query I rowsort label-4502
SELECT DISTINCT ( col1 ) DIV + ( col2 ) FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-4502
SELECT DISTINCT ( col1 ) / + ( col2 ) FROM tab1
----
0

query I rowsort
SELECT ALL - col0 * 71 AS col1 FROM tab2 AS cor0
----
-497
-5538
-5609

onlyif mysql # use DIV operator for integer division
query I rowsort label-4504
SELECT ALL col0 + col1 DIV - col1 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-4504
SELECT ALL col0 + col1 / - col1 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT - tab2.col1 - - col2 * 60 FROM tab2
----
1501
1589
2263

query I rowsort
SELECT DISTINCT col2 * - col1 * col2 AS col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT ALL 26 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT - col1 * + 40 AS col0 FROM tab2 AS cor0
----
-1240
-2360
-680

query I rowsort
SELECT + 59 FROM tab0, tab1 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 05f41d0d3fd0b5c29af79ab9209cab27

query I rowsort
SELECT + col2 + 17 * + 92 AS col0 FROM tab0 AS cor0
----
1565
1597
1646

query I rowsort
SELECT - col0 - - 93 FROM tab0 AS cor0
----
4
58
69

query I rowsort
SELECT col2 * - col2 - col1 FROM tab2 AS cor0
----
-1461
-735
-760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col2 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT - col0 + col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT + 13 - + col0 AS col2 FROM tab2
----
-65
-66
6

query I rowsort
SELECT - - 25 + col2 AS col0 FROM tab2 AS cor0
----
51
52
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4517
SELECT - col1 * col1 DIV + col0 AS col1 FROM tab1 cor0
----
-1
-2
-225

skipif mysql # not compatible
query I rowsort label-4517
SELECT - col1 * col1 / + col0 AS col1 FROM tab1 cor0
----
-1
-2
-225

query I rowsort
SELECT ALL - ( col0 ) * ( ( col0 ) ) AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL 17 + col1 * 72 * col2 FROM tab1 AS cor0
----
101105
41057
89873

onlyif mysql # use DIV operator for integer division
query I rowsort label-4520
SELECT DISTINCT - - col2 + + col2 DIV CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
36
57
95

skipif mysql # not compatible
query I rowsort label-4520
SELECT DISTINCT - - col2 + + col2 / CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
36
57
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4521
SELECT DISTINCT - col2 + - col1 * CAST( NULL AS SIGNED ) * + col1 col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4521
SELECT DISTINCT - col2 + - col1 * CAST ( NULL AS INTEGER ) * + col1 col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + cor0.col0 + col0 AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT + 21 * - col1 FROM tab1 AS cor0
----
-210
-273
-546

query I rowsort
SELECT DISTINCT col1 + col2 AS col0 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + - col0 * + col2 * col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT 59 * cor0.col2 + + ( col2 ) * - col0 FROM tab0 AS cor0
----
-2460
1155
24

query I rowsort
SELECT ALL col1 + col2 * 26 FROM tab1 AS cor0
----
1430
1492
2509

query I rowsort
SELECT DISTINCT - 12 * col1 AS col0 FROM tab2 cor0
----
-204
-372
-708

query I rowsort
SELECT DISTINCT - + col0 * col0 * - col0 FROM tab2 AS cor0
----
343
474552
493039

query I rowsort
SELECT - + 7 FROM tab2, tab0 AS cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

query I rowsort
SELECT col0 * col0 * - col1 - col0 * + col1 AS col0 FROM tab0
----
-122220
-51600
-728910

query I rowsort
SELECT col0 * - ( col0 ) * - cor0.col0 FROM tab1 cor0
----
262144
27
512000

query I rowsort
SELECT ALL + 18 - col0 AS col2 FROM tab1 AS cor0
----
-46
-62
15

query I rowsort
SELECT + 13 AS col2 FROM tab0
----
13
13
13

query I rowsort
SELECT 65 + col0 * - col1 FROM tab0 AS cor0
----
-1999
-3330
-8034

query I rowsort
SELECT DISTINCT ( - ( - col1 ) ) + + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + cor0.col2 + + 65 AS col2 FROM tab0, tab2 AS cor0
----
103
91
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4538
SELECT ALL - CAST( NULL AS SIGNED ) / - 14 + + col2 * 43 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4538
SELECT ALL - CAST ( NULL AS INTEGER ) / - 14 + + col2 * 43 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4539
SELECT + col1 * + col0 - + col2 * + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4539
SELECT + col1 * + col0 - + col2 * + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 26 + col0 - col0 FROM tab1 AS cor0
----
26

query I rowsort
SELECT DISTINCT - 53 * + 0 + - col2 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + ( col2 ) + col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL - ( + 84 ) FROM tab0
----
-84
-84
-84

query I rowsort
SELECT ALL - col2 + col2 + + col2 * - 25 AS col1 FROM tab1
----
-1350
-1425
-2400

onlyif mysql # use DIV operator for integer division
query I rowsort label-4545
SELECT DISTINCT + col1 + + col1 DIV ( + 7 ) AS col2 FROM tab2 AS cor0
----
19
35
67

skipif mysql # not compatible
query I rowsort label-4545
SELECT DISTINCT + col1 + + col1 / ( + 7 ) AS col2 FROM tab2 AS cor0
----
19
35
67

query I rowsort
SELECT ALL - ( col1 ) + 27 FROM tab1 AS cor0
----
1
14
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + col1 col1 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 - + col0 col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4549
SELECT col0 DIV + col0 + col1 + col0 * col2 FROM tab0
----
133
7390
879

skipif mysql # not compatible
query I rowsort label-4549
SELECT col0 / + col0 + col1 + col0 * col2 FROM tab0
----
133
7390
879

query I rowsort
SELECT DISTINCT - 61 AS col1 FROM tab0, tab1 AS cor0
----
-61

query I rowsort
SELECT DISTINCT - 14 * - 55 + + col2 FROM tab2
----
796
797
808

onlyif mysql # use DIV operator for integer division
query I rowsort label-4552
SELECT DISTINCT - 56 * + col1 + - col1 DIV + col0 AS col2 FROM tab1
----
-1464
-560
-728

skipif mysql # not compatible
query I rowsort label-4552
SELECT DISTINCT - 56 * + col1 + - col1 / + col0 AS col2 FROM tab1
----
-1464
-560
-728

query I rowsort
SELECT ( 39 ) * - col2 + col0 * col2 FROM tab1
----
-1944
1425
3936

query I rowsort
SELECT DISTINCT - col0 + - 88 AS col1 FROM tab2
----
-166
-167
-95

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab1 AS cor1, tab2, tab2 cor2
----
3645 values hashing to e3826bc27970dd1a441a9cd4c13b096d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4556
SELECT + - CAST( NULL AS SIGNED ) * 82 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4556
SELECT + - CAST ( NULL AS INTEGER ) * 82 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - 2 col0 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT ( - ( col0 ) * col2 + col2 ) AS col1 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - ( col0 + - tab1.col0 ) * + ( 23 ) FROM tab1
----
0

query I rowsort
SELECT DISTINCT 6 FROM tab2, tab2 AS cor0
----
6

query I rowsort
SELECT + ( - 50 ) FROM tab0
----
-50
-50
-50

query I rowsort
SELECT 91 + col1 FROM tab0 cor0
----
177
182
188

query I rowsort
SELECT DISTINCT + 35 * ( + col2 ) - - col2 * col0 FROM tab0 AS cor0
----
10168
1947
70

query I rowsort
SELECT ALL - 56 - - col0 * + col0 FROM tab0 AS cor0
----
1169
520
7865

onlyif mysql # use DIV operator for integer division
query I rowsort label-4565
SELECT - 56 + col0 DIV col0 + 65 AS col0 FROM tab1
----
10
10
10

skipif mysql # not compatible
query I rowsort label-4565
SELECT - 56 + col0 / col0 + 65 AS col0 FROM tab1
----
10
10
10

query I rowsort
SELECT ( col0 ) * col2 + tab1.col2 AS col1 FROM tab1
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + col2 + col2 col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + 72 + cor0.col2 * 42 FROM tab1 AS cor0
----
2340
2466
4104

query I rowsort
SELECT DISTINCT col2 + - col1 * + 5 FROM tab2 AS cor0
----
-128
-269
-47

query I rowsort
SELECT ALL ( 20 ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT col1 + + cor0.col1 + col1 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT + col1 + col2 + + 89 * - col1 FROM tab1 AS cor0
----
-1048
-2234
-823

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4573
SELECT ALL - cor0.col1 + - 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-4573
SELECT ALL - cor0.col1 + - CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4574
SELECT - col1 * CAST( NULL AS SIGNED ) * + col0 + - col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4574
SELECT - col1 * CAST ( NULL AS INTEGER ) * + col0 + - col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + ( col0 * col0 ) col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT col2 + + cor0.col2 * - 38 + + col2 * ( cor0.col1 ) FROM tab1 AS cor0
----
-1539
-2304
-594

query I rowsort
SELECT DISTINCT + col2 * ( 12 ) AS col0 FROM tab2 AS cor0
----
312
324
456

onlyif mysql # use DIV operator for integer division
query I rowsort label-4578
SELECT DISTINCT - col0 + - 12 * 13 DIV col2 FROM tab0 AS cor0
----
-191
-28
-90

skipif mysql # not compatible
query I rowsort label-4578
SELECT DISTINCT - col0 + - 12 * 13 / col2 FROM tab0 AS cor0
----
-191
-28
-90

query I rowsort
SELECT - col1 + col0 + + col1 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL - col2 * + 71 + - 52 FROM tab1 AS cor0
----
-3886
-4099
-6868

query I rowsort
SELECT DISTINCT - col2 * - 62 FROM tab1 cor0
----
3348
3534
5952

query I rowsort
SELECT ALL ( col0 ) + - 60 AS col0 FROM tab2
----
-53
18
19

query I rowsort
SELECT ALL - tab0.col0 + + col0 * + col2 + 45 * col1 FROM tab0
----
11304
4365
4638

query I rowsort
SELECT DISTINCT + ( + col2 ) + ( 19 * col2 ) FROM tab2
----
520
540
760

query I rowsort
SELECT + + col2 * 84 + col1 FROM tab0 AS cor0
----
181
2858
6979

query I rowsort
SELECT + - col2 + - cor0.col0 + col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - col1 * 51 + col0 + col2 FROM tab0 AS cor0
----
-4329
-4470
-4911

query I rowsort
SELECT - col1 * ( + col1 ) - col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT - col2 * col1 + - col0 FROM tab2 cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-4590
SELECT 3 DIV + 61 + col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4590
SELECT 3 / + 61 + col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( - col0 ) col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - 53 + + col0 * col2 AS col0 FROM tab0 AS cor0
----
-18
7245
739

onlyif mysql # use DIV operator for integer division
query I rowsort label-4593
SELECT - 15 * ( col2 ) DIV col0 FROM tab1 AS cor0
----
-13
-18
-270

skipif mysql # not compatible
query I rowsort label-4593
SELECT - 15 * ( col2 ) / col0 FROM tab1 AS cor0
----
-13
-18
-270

query I rowsort
SELECT - cor0.col2 * - col2 + + col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT + - 68 AS col2 FROM tab2 cor0
----
-68
-68
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-4596
SELECT + col0 + + col1 DIV col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-4596
SELECT + col0 + + col1 / col0 FROM tab1 AS cor0
----
11
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4597
SELECT + - 96 + - 16 + col1 DIV ( + col1 ) AS col1 FROM tab1 AS cor0
----
-111
-111
-111

skipif mysql # not compatible
query I rowsort label-4597
SELECT + - 96 + - 16 + col1 / ( + col1 ) AS col1 FROM tab1 AS cor0
----
-111
-111
-111

query I rowsort
SELECT + col2 * - 57 FROM tab2
----
-1482
-1539
-2166

query I rowsort
SELECT + + 60 + col2 FROM tab0 AS cor0
----
142
61
93

query I rowsort
SELECT + 52 * + col2 AS col1 FROM tab0 AS cor0
----
1716
4264
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4601
SELECT - + 99 * - col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4601
SELECT - + 99 * - col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * ( + col0 ) FROM tab2
----
49
6084
6241

query I rowsort
SELECT ALL - tab1.col1 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT - col0 * + 92 - cor0.col0 FROM tab2 cor0
----
-651
-7254
-7347

query I rowsort
SELECT ALL + 57 * + col1 + - ( - col1 ) * col2 AS col0 FROM tab2
----
1615
2604
4897

onlyif mysql # use DIV operator for integer division
query I rowsort label-4606
SELECT DISTINCT - + col2 + cor0.col2 * ( col1 ) DIV cor0.col1 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-4606
SELECT DISTINCT - + col2 + cor0.col2 * ( col1 ) / cor0.col1 FROM tab2 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4607
SELECT ALL - col0 * col2 - + CAST( col0 * + col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-15397
-2856
-3430

skipif mysql # not compatible
query I rowsort label-4607
SELECT ALL - col0 * col2 - + CAST ( col0 * + col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-15397
-2856
-3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-4608
SELECT ALL - - col0 DIV - col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-4608
SELECT ALL - - col0 / - col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT DISTINCT + col0 * + col0 + col2 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-4610
SELECT DISTINCT + col1 * col0 + col0 - - col1 DIV + col0 col1 FROM tab0 cor0
----
2091
3432
8189

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4610
SELECT DISTINCT + col1 * col0 + col0 - - col1 / + col0 col1 FROM tab0 cor0
----
2091
3432
8189

onlyif mysql # use DIV operator for integer division
query I rowsort label-4611
SELECT ALL col0 DIV cor0.col0 AS col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4611
SELECT ALL col0 / cor0.col0 AS col1 FROM tab2 cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4612
SELECT DISTINCT col0 DIV col0 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-4612
SELECT DISTINCT col0 / col0 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL - col1 AS col1 FROM tab0 AS cor0 WHERE NOT NULL BETWEEN ( col0 ) AND ( - col0 ) OR NOT + col0 IN ( - col0 * - cor0.col2 * - col0 )
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col1 * - col2 + col2 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL - col0 * - col1 + - col1 * cor0.col2 - col0 * col2 FROM tab2 cor0
----
-2305
-809
1040

query I rowsort
SELECT ALL - tab2.col1 AS col2 FROM tab2 WHERE ( + col0 ) <= NULL
----

query I rowsort
SELECT ALL col2 + col1 * - col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT + col0 * + col2 AS col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - - col1 + col2 * + col2 FROM tab2 AS cor0
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4620
SELECT ( tab1.col2 ) DIV - col2 + col0 col0 FROM tab1
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4620
SELECT ( tab1.col2 ) / - col2 + col0 col0 FROM tab1
----
2
63
79

query I rowsort
SELECT DISTINCT tab0.col2 * col1 * - col2 - col0 FROM tab0
----
-132
-611973
-93678

query I rowsort
SELECT DISTINCT - tab2.col1 + col0 * - col0 FROM tab2
----
-6143
-6258
-80

query I rowsort
SELECT ALL col2 + - col2 * - col1 + - col1 * col2 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4624
SELECT col0 + + cor0.col2 DIV col0 AS col0 FROM tab2 AS cor0
----
10
78
79

skipif mysql # not compatible
query I rowsort label-4624
SELECT col0 + + cor0.col2 / col0 AS col0 FROM tab2 AS cor0
----
10
78
79

query I rowsort
SELECT col1 * - col1 + + cor0.col0 AS col2 FROM tab1 cor0
----
-36
-673
-89

query I rowsort
SELECT + + col1 + col2 * col2 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-114059
-5072
-52669

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 * col0 + + col0 * col1 col0 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT ALL + col2 + - col0 * - col2 + col0 FROM tab1 WHERE NOT NULL BETWEEN ( NULL ) AND + col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4629
SELECT DISTINCT + col1 DIV - tab0.col0 + - col0 + + col1 FROM tab0
----
1
59
60

skipif mysql # not compatible
query I rowsort label-4629
SELECT DISTINCT + col1 / - tab0.col0 + - col0 + + col1 FROM tab0
----
1
59
60

query I rowsort
SELECT - col0 + + col2 + col2 * - col1 * + tab0.col1 FROM tab0
----
-244059
-679049
-9443

onlyif mysql # use DIV operator for integer division
query I rowsort label-4631
SELECT ALL col0 + + col0 DIV + col0 + col0 FROM tab1
----
129
161
7

skipif mysql # not compatible
query I rowsort label-4631
SELECT ALL col0 + + col0 / + col0 + col0 FROM tab1
----
129
161
7

query I rowsort
SELECT col0 + + tab2.col0 * - col1 * col1 + col1 FROM tab2
----
-22735
-271381
-6689

query I rowsort
SELECT ALL + col1 + tab2.col0 + col0 AS col0 FROM tab2
----
175
215
45

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 * + col1 + col2 + - col1 BETWEEN ( NULL ) AND ( - col1 + + tab0.col2 * col1 * col0 )
----
35
97
1

query I rowsort
SELECT ALL - col2 * tab2.col1 * - col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT DISTINCT - col1 + - col0 * - tab0.col0 FROM tab0
----
1128
490
7830

query III rowsort
SELECT * FROM tab2 WHERE NOT ( - tab2.col0 ) <= - col1 * col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - tab0.col1 * - col2 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL - col1 + col1 * col0 AS col1 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT + col2 * col0 * + col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT 99 + + col2 FROM tab2 AS cor0
----
125
126
137

query I rowsort
SELECT 8 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to a42c42e56e75960d97c09dd731d99c01

query I rowsort
SELECT DISTINCT col1 + col2 * + 26 AS col0 FROM tab2 AS cor0
----
1005
733
735

query I rowsort
SELECT - 25 * + 18 AS col1 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 437b6a5ca36345488c694fd243f9682f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4645
SELECT ALL ( - col0 + - CAST( NULL AS SIGNED ) ) * + col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4645
SELECT ALL ( - col0 + - CAST ( NULL AS INTEGER ) ) * + col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4646
SELECT col2 * col0 DIV - cor0.col2 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-4646
SELECT col2 * col0 / - cor0.col2 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + + cor0.col0 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT + - 5 * - col2 AS col2 FROM tab1 AS cor0
----
270
285
480

query IIIIII rowsort
SELECT * FROM tab2, tab0 cor0 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND ( NULL )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4650
SELECT ALL - + cor0.col2 * - cor0.col1 + + CAST( col1 AS SIGNED ) * col2 FROM tab0 AS cor0
----
14924
194
5676

skipif mysql # not compatible
query I rowsort label-4650
SELECT ALL - + cor0.col2 * - cor0.col1 + + CAST ( col1 AS INTEGER ) * col2 FROM tab0 AS cor0
----
14924
194
5676

query I rowsort
SELECT + col2 * + tab2.col0 + col0 AS col2 FROM tab2
----
196
2106
3081

query I rowsort
SELECT ALL col1 + tab0.col2 + col0 * + col1 AS col2 FROM tab0
----
2183
3493
8272

query I rowsort
SELECT ALL + col1 + col1 * - col2 + col2 AS col2 FROM tab2
----
-1449
-591
-779

onlyif mysql # use DIV operator for integer division
query I rowsort label-4654
SELECT DISTINCT + tab1.col1 DIV - col1 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-4654
SELECT DISTINCT + tab1.col1 / - col1 FROM tab1
----
-1

query I rowsort
SELECT ALL - tab0.col1 + - col2 + tab0.col1 * col2 AS col1 FROM tab0
----
-1
2719
7289

query I rowsort
SELECT + col1 * col2 * - col0 AS col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - col1 + + col0 + col2 AS col0 FROM tab2
----
100
3
45

query I rowsort
SELECT DISTINCT + col2 + cor0.col2 + col1 FROM tab0 AS cor0
----
152
255
99

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NULL > ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4660
SELECT DISTINCT cor0.col1 DIV + cor0.col1 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4660
SELECT DISTINCT cor0.col1 / + cor0.col1 FROM tab1 AS cor0
----
1

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) BETWEEN NULL AND col0 * + col1 + + col1
----

query I rowsort
SELECT - col2 + + col0 * col1 AS col1 FROM tab2
----
1305
190
4576

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col2 * col1 NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL tab1.col0 FROM tab1 WHERE NOT NULL BETWEEN - col0 + - col0 AND ( + col2 + + col2 )
----

query I rowsort
SELECT ALL col2 + + tab0.col1 * + col0 AS col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT - col2 * col0 AS col0 FROM tab0 WHERE ( NULL ) NOT BETWEEN NULL AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( NULL ) NOT BETWEEN col1 AND ( - col0 )
----

query I rowsort
SELECT ALL col2 * col1 + col1 AS col1 FROM tab1
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-4669
SELECT col0 DIV - col0 - + col0 FROM tab2
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-4669
SELECT col0 / - col0 - + col0 FROM tab2
----
-79
-8
-80

query I rowsort
SELECT DISTINCT col0 AS col2 FROM tab0 WHERE + col2 * - col2 - - col2 NOT BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4671
SELECT - col1 DIV + col2 + - col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4671
SELECT - col1 / + col2 + - col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - col2 + col0 * col2 + col1 FROM tab0
----
131
7307
845

query I rowsort
SELECT DISTINCT + col1 + col1 * col2 * col1 AS col2 FROM tab1
----
16237
36530
5710

query I rowsort
SELECT DISTINCT + col1 - col0 FROM tab1 WHERE NOT + col2 < ( NULL )
----

query I rowsort
SELECT ALL + tab1.col1 + - col0 * - col0 FROM tab1
----
35
4106
6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-4676
SELECT - tab2.col0 DIV - col1 + + tab2.col1 FROM tab2
----
21
31
60

skipif mysql # not compatible
query I rowsort label-4676
SELECT - tab2.col0 / - col1 + + tab2.col1 FROM tab2
----
21
31
60

query I rowsort
SELECT col1 + col0 * col1 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT 52 + + col0 + - 73 FROM tab0 cor0
----
14
3
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-4679
SELECT ALL col0 DIV - col0 + - col0 * col2 AS col2 FROM tab2
----
-190
-2029
-3003

skipif mysql # not compatible
query I rowsort label-4679
SELECT ALL col0 / - col0 + - col0 * col2 AS col2 FROM tab2
----
-190
-2029
-3003

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
81 values hashing to c569638e8a09ff819458d62ddbde994c

query I rowsort
SELECT 66 * col1 + - col2 * - 79 AS col0 FROM tab1
----
5163
5982
8442

query I rowsort
SELECT + col1 + - col2 * col2 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT ALL 67 + - col1 + col1 FROM tab2 AS cor0
----
67
67
67

query I rowsort
SELECT DISTINCT + col1 - - col2 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT col1 * 87 AS col0 FROM tab0
----
7482
7917
8439

onlyif mysql # use DIV operator for integer division
query I rowsort label-4686
SELECT - col0 DIV - 45 AS col1 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4686
SELECT - col0 / - 45 AS col1 FROM tab1 AS cor0
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4687
SELECT DISTINCT + col0 * col0 + col0 + - CAST( cor0.col1 AS SIGNED ) * + col2 AS col2 FROM tab2 AS cor0
----
-781
4628
5674

skipif mysql # not compatible
query I rowsort label-4687
SELECT DISTINCT + col0 * col0 + col0 + - CAST ( cor0.col1 AS INTEGER ) * + col2 AS col2 FROM tab2 AS cor0
----
-781
4628
5674

query I rowsort
SELECT DISTINCT ( col0 ) * col0 * col2 + + col1 * - cor0.col0 FROM tab2 AS cor0
----
1106
153582
235815

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 + col0 * col0 col0 FROM tab0 AS cor0
----
1128
479
7824

query I rowsort
SELECT ALL col0 - col0 AS col0 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col0 AS REAL ) + col2 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT 3 * - col0 FROM tab0 AS cor0
----
-105
-267
-72

query I rowsort
SELECT ALL - - 69 * cor0.col0 FROM tab2 cor0
----
483
5382
5451

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4694
SELECT - col2 * 94 - col2 * + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4694
SELECT - col2 * 94 - col2 * + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 9 * - col2 - col2 AS col1 FROM tab1 AS cor0
----
-540
-570
-960

query I rowsort
SELECT + + col1 * col1 + col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT col1 + - col2 - - col0 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT ALL + - cor0.col0 * + ( - col2 ) - ( col0 + col2 ) * cor0.col1 AS col2 FROM tab0 AS cor0
----
-3457
-4110
-8263

query I rowsort
SELECT 23 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
40
54
82

query I rowsort
SELECT ALL + + ( + col2 ) * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + 23 + 60 * col2 AS col2 FROM tab1 AS cor0
----
3263
3443
5783

query I rowsort
SELECT DISTINCT - - 41 AS col1 FROM tab1 AS cor0
----
41

query I rowsort
SELECT ALL 81 + - 42 AS col0 FROM tab0 AS cor0
----
39
39
39

query I rowsort
SELECT - ( - col1 * + col1 ) AS col0 FROM tab1
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-4705
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-4705
SELECT col0 / + col0 col0 FROM tab0
----
1
1
1

query I rowsort
SELECT - ( col2 ) * - tab1.col0 * + col1 AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT - col1 * + 5 FROM tab2
----
-155
-295
-85

query I rowsort
SELECT DISTINCT + ( + tab0.col1 * col0 ) FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4709
SELECT col2 DIV + ( col1 ) FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4709
SELECT col2 / + ( col1 ) FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 26 * - 81 col2 FROM tab0
----
-2106

query I rowsort
SELECT + col0 * col2 + - col2 * + col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col0 + col0 - col2 * + col1 AS col1 FROM tab1
----
-1088
-1398
-442

query I rowsort
SELECT - col0 + col0 * col0 AS col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT 92 + col1 * + col0 + col2 FROM tab1 AS cor0
----
1228
224
789

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4715
SELECT ALL CAST( + col1 * col0 AS SIGNED ) + col2 * tab2.col2 AS col2 FROM tab2
----
2787
5278
946

skipif mysql # not compatible
query I rowsort label-4715
SELECT ALL CAST ( + col1 * col0 AS INTEGER ) + col2 * tab2.col2 AS col2 FROM tab2
----
2787
5278
946

query I rowsort
SELECT + + 95 * col2 FROM tab2 AS cor0
----
2470
2565
3610

query I rowsort
SELECT DISTINCT 97 + col0 + + tab0.col1 FROM tab0
----
207
229
277

query I rowsort
SELECT DISTINCT col0 + + 95 + tab0.col2 FROM tab0
----
131
152
266

query I rowsort
SELECT + - col1 - col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT + col2 + ( col1 ) FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + cor0.col1 * col1 - - 73 AS col1 FROM tab0 AS cor0
----
7469
8354
9482

query I rowsort
SELECT ALL - col2 * col0 + - col2 - - cor0.col0 FROM tab0 AS cor0
----
-1
-7291
-801

query I rowsort
SELECT - + col0 + 56 FROM tab1 AS cor0
----
-24
-8
53

query I rowsort
SELECT + - col2 * 15 + col2 * col2 FROM tab0 AS cor0
----
-14
5494
594

query I rowsort
SELECT - col1 * col2 + col0 AS col2 FROM tab0 cor0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * ( - cor0.col1 ) + + col0 * cor0.col2 col0 FROM tab2 AS cor0
----
1150
3291
5509

query I rowsort
SELECT - 24 AS col1 FROM tab2 cor0
----
-24
-24
-24

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab0 cor1, tab0 AS cor2
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 23 col2 FROM tab0
----
2047
552
805

onlyif mysql # use DIV operator for integer division
query I rowsort label-4730
SELECT col1 * + 39 + 62 + + col1 DIV + col1 FROM tab2
----
1272
2364
726

skipif mysql # not compatible
query I rowsort label-4730
SELECT col1 * + 39 + 62 + + col1 / + col1 FROM tab2
----
1272
2364
726

query I rowsort
SELECT + col2 + + ( + col1 ) AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL + col0 + + col0 * - col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL - col1 * 96 + - 63 FROM tab0
----
-8319
-8799
-9375

query I rowsort
SELECT col2 * + col2 + ( - col1 * col0 ) + - col2 * col2 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - col1 * cor0.col1 + 60 AS col2 FROM tab2 cor0
----
-229
-3421
-901

query I rowsort
SELECT ALL - + col1 + 68 AS col0 FROM tab2 AS cor0
----
37
51
9

query I rowsort
SELECT ALL - - col0 + 55 FROM tab2 AS cor0
----
133
134
62

query I rowsort
SELECT ALL - 65 AS col0 FROM tab0 cor0
----
-65
-65
-65

query I rowsort
SELECT + + 2 * ( col0 ) AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + + col2 * col2 + + col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ( - cor0.col0 ) + col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4742
SELECT ALL + col2 DIV + col1 AS col2 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4742
SELECT ALL + col2 / + col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * + ( cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4744
SELECT - + col2 DIV - 2 FROM tab0 AS cor0
----
0
16
41

skipif mysql # not compatible
query I rowsort label-4744
SELECT - + col2 / - 2 FROM tab0 AS cor0
----
0
16
41

query I rowsort
SELECT ALL + col1 * - 89 FROM tab0 AS cor0
----
-7654
-8099
-8633

query I rowsort
SELECT DISTINCT ( cor0.col0 ) + + col1 * col2 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT + ( 56 ) * col1 + - col2 FROM tab0 AS cor0
----
4783
5014
5431

query I rowsort
SELECT DISTINCT - col0 * 48 + - col0 FROM tab2 AS cor0
----
-343
-3822
-3871

onlyif mysql # use DIV operator for integer division
query I rowsort label-4749
SELECT ALL col0 DIV + 65 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4749
SELECT ALL col0 / + 65 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL - + 16 * 86 + col0 FROM tab1 AS cor0
----
-1296
-1312
-1373

onlyif mysql # use DIV operator for integer division
query I rowsort label-4751
SELECT ALL col0 * cor0.col0 DIV + col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-4751
SELECT ALL col0 * cor0.col0 / + col0 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * ( col2 ) col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + col2 * + 73 AS col1 FROM tab0 AS cor0
----
2409
5986
73

query I rowsort
SELECT ALL + + 20 FROM tab2 AS cor0
----
20
20
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 * - 15 + - col2 * - col1 col1 FROM tab2 cor0
----
-1998
-28886
-44384

query I rowsort
SELECT DISTINCT + col0 * col0 - - 39 FROM tab0
----
1264
615
7960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4757
SELECT - - 81 * - cor0.col0 * CAST( NULL AS SIGNED ) - - col0 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-4757
SELECT - - 81 * - cor0.col0 * CAST ( NULL AS INTEGER ) - - col0 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 * col1 + col2 AS col0 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT ALL - - 65 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
119
122
161

onlyif mysql # use DIV operator for integer division
query I rowsort label-4760
SELECT ALL + 18 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4760
SELECT ALL + 18 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 45 + col2 FROM tab0 AS cor0
----
127
46
78

query I rowsort
SELECT col0 - + cor0.col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - + col2 * col1 * ( col0 ) AS col1 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT ALL + cor0.col2 + col1 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + col2 + col0 + 38 * - col0 * - col2 AS col0 FROM tab0 AS cor0
----
1366
277495
30153

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col0 + ( col2 ) col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL cor0.col2 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT - 88 AS col0 FROM tab0
----
-88
-88
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4769
SELECT + col2 - + CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-4769
SELECT + col2 - + CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 + ( col0 * - col0 ) - 25 col1 FROM tab0 AS cor0
----
-1285
-1393
-15244

query I rowsort
SELECT DISTINCT - - cor0.col0 * - 60 FROM tab1 AS cor0
----
-180
-3840
-4800

query I rowsort
SELECT DISTINCT + + col2 * 35 * - cor0.col2 AS col2 FROM tab1 cor0
----
-102060
-113715
-322560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col2 col0 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT ALL - + col2 * - cor0.col0 - + ( col0 ) FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT + col2 + - 72 AS col1 FROM tab1 AS cor0
----
-15
-18
24

query I rowsort
SELECT ALL - col1 * 32 + - 11 - col2 FROM tab2 AS cor0
----
-1030
-1925
-593

query I rowsort
SELECT DISTINCT col2 + - 85 FROM tab0 AS cor0
----
-3
-52
-84

query I rowsort
SELECT ALL + col2 + 36 FROM tab1 AS cor0
----
132
90
93

query I rowsort
SELECT - + col0 * ( + col0 ) * + cor0.col0 + col0 FROM tab0 AS cor0
----
-13800
-42840
-704880

query I rowsort
SELECT + col0 * col1 - - 69 FROM tab0 cor0
----
2133
3464
8168

onlyif mysql # use DIV operator for integer division
query I rowsort label-4781
SELECT DISTINCT + 14 DIV + col0 - - 86 FROM tab0
----
86

skipif mysql # not compatible
query I rowsort label-4781
SELECT DISTINCT + 14 / + col0 - - 86 FROM tab0
----
86

query I rowsort
SELECT + tab1.col2 AS col0 FROM tab1, tab2, tab2 AS cor0, tab2 AS cor1
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT DISTINCT + + 14 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
14

query I rowsort
SELECT ALL + col0 * - 9 + 70 FROM tab0 AS cor0
----
-146
-245
-731

query I rowsort
SELECT - + col1 * col0 + 40 FROM tab2 AS cor0
----
-1303
-177
-4562

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4786
SELECT ALL CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4786
SELECT ALL CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL col1 * + 10 FROM tab0
----
860
910
970

query I rowsort
SELECT ALL cor0.col1 * 69 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 45c925e7846348e192cfdd0f425e3550

query I rowsort
SELECT - + 9 * - col1 FROM tab0 AS cor0
----
774
819
873

query I rowsort
SELECT ALL + + cor0.col2 * col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - cor0.col1 * + col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 18 col0 FROM tab1
----
18

query I rowsort
SELECT ALL - 72 * cor0.col1 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 31d3ddcf60e3c8205de69314baba4dc5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4794
SELECT col0 + col1 DIV col1 AS col0 FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-4794
SELECT col0 + col1 / col1 AS col0 FROM tab2
----
79
8
80

query I rowsort
SELECT ALL + + cor0.col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT + + 99 + - 27 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab0, tab0 AS cor2
----
72

query I rowsort
SELECT col1 * - col1 + + col2 AS col0 FROM tab2 cor0
----
-251
-3455
-934

query I rowsort
SELECT + - col2 + + col2 * col2 AS col2 FROM tab2 AS cor0
----
1406
650
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-4799
SELECT + + 28 * - col0 DIV col0 AS col1 FROM tab0 AS cor0
----
-28
-28
-28

skipif mysql # not compatible
query I rowsort label-4799
SELECT + + 28 * - col0 / col0 AS col1 FROM tab0 AS cor0
----
-28
-28
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-4800
SELECT + ( + cor0.col1 ) DIV + col0 AS col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4800
SELECT + ( + cor0.col1 ) / + col0 AS col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT ALL - 38 * + col0 + + col1 AS col2 FROM tab2 AS cor0
----
-235
-2905
-2985

query I rowsort
SELECT ALL - + col2 - 22 AS col1 FROM tab2 AS cor0
----
-48
-49
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-4803
SELECT - 33 DIV col1 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4803
SELECT - 33 / col1 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT ( - col2 ) * 44 + col2 FROM tab2 cor0
----
-1118
-1161
-1634

query I rowsort
SELECT 54 + - col0 AS col0 FROM tab2 cor0
----
-24
-25
47

query I rowsort
SELECT ( col0 ) * + col1 + - ( col0 ) AS col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT cor0.col1 * cor0.col0 AS col0 FROM tab1, tab2 cor0 WHERE NOT NULL < ( NULL )
----

query I rowsort
SELECT ALL + cor1.col2 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT DISTINCT col0 + - 16 FROM tab2
----
-9
62
63

query I rowsort
SELECT ALL + col2 - ( + col1 ) FROM tab2 AS cor0
----
-33
-4
21

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 cor0, tab0 AS cor1, tab2, tab0 cor2
----
3645 values hashing to 283f1c907a0999dbd972d3bd45746c06

query I rowsort
SELECT - - col1 + 30 * col1 AS col1 FROM tab1 AS cor0
----
310
403
806

query I rowsort
SELECT + ( cor1.col1 ) FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + ( - 51 ) + - col1 * col1 FROM tab0 AS cor0
----
-7447
-8332
-9460

query I rowsort
SELECT DISTINCT + cor0.col2 * ( ( + col2 ) ) - 79 AS col2 FROM tab1 AS cor0
----
2837
3170
9137

query I rowsort
SELECT DISTINCT col2 * 60 AS col1 FROM tab2
----
1560
1620
2280

query I rowsort
SELECT ( 56 ) FROM tab1
----
56
56
56

query I rowsort
SELECT - tab1.col1 * - col0 + col2 * - 69 * 79 AS col2 FROM tab1
----
-294276
-310067
-522256

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 34 col1 FROM tab1
----
34
34
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4820
SELECT DISTINCT CAST( NULL AS SIGNED ) * + 43 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4820
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + 43 FROM tab0
----
NULL

query I rowsort
SELECT - 87 * - cor0.col2 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 126d67ae3258e3466d77694a94cddacf

query I rowsort
SELECT DISTINCT + 10 FROM tab2, tab2 AS cor0
----
10

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4823
SELECT CAST( NULL AS SIGNED ) * + 15 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-4823
SELECT CAST ( NULL AS INTEGER ) * + 15 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT - + cor0.col1 * - tab1.col1 AS col2 FROM tab1, tab0, tab0 cor0
----
27 values hashing to 5ea193ba73427313aa6d66d856b32bc7

query I rowsort
SELECT + 29 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

onlyif mysql # use DIV operator for integer division
query I rowsort label-4826
SELECT - col1 DIV col0 + - col2 col1 FROM tab0 AS cor0
----
-3
-36
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4826
SELECT - col1 / col0 + - col2 col1 FROM tab0 AS cor0
----
-3
-36
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4827
SELECT + - col2 + CAST( NULL AS SIGNED ) * - col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4827
SELECT + - col2 + CAST ( NULL AS INTEGER ) * - col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + cor0.col2 + - col1 FROM tab0 cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4829
SELECT DISTINCT + - col0 DIV - cor0.col0 AS col1 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4829
SELECT DISTINCT + - col0 / - cor0.col0 AS col1 FROM tab0 AS cor0
----
1

query I rowsort
SELECT - cor0.col0 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4831
SELECT - cor0.col1 + CAST( 29 AS SIGNED ) FROM tab1 AS cor0
----
16
19
3

skipif mysql # not compatible
query I rowsort label-4831
SELECT - cor0.col1 + CAST ( 29 AS INTEGER ) FROM tab1 AS cor0
----
16
19
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4832
SELECT - CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4832
SELECT - CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4833
SELECT ALL ( col2 * col0 ) - + CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4833
SELECT ALL ( col2 * col0 ) - + CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4834
SELECT ALL - col2 DIV - col1 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4834
SELECT ALL - col2 / - col1 FROM tab1 cor0
----
2
5
7

query I rowsort
SELECT ALL - col2 * - col0 * ( col1 ) FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ( + col1 ) - + 61 * 23 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-36419
-37850
-53297

query I rowsort
SELECT ALL + col2 - - 53 * + col1 FROM tab0
----
4591
4905
5142

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4838
SELECT ALL CAST( NULL AS SIGNED ) - col1 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4838
SELECT ALL CAST ( NULL AS INTEGER ) - col1 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 + - col2 * col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 57 + - col1 col2 FROM tab2 AS cor0
----
-2
26
40

query I rowsort
SELECT DISTINCT - - 44 * col1 * ( - col0 ) FROM tab2 AS cor0
----
-202488
-59092
-9548

query I rowsort
SELECT + 59 * + col0 - 62 AS col1 FROM tab2 AS cor0
----
351
4540
4599

query I rowsort
SELECT ALL - 50 + col2 AS col1 FROM tab1 AS cor0
----
4
46
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4844
SELECT + cor0.col2 DIV cor0.col2 + - col0 AS col2 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4844
SELECT + cor0.col2 / cor0.col2 + - col0 AS col2 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT ALL + + col1 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - + col0 * - col1 + col2 + + 28 AS col0 FROM tab0 AS cor0
----
2125
3424
8209

query I rowsort
SELECT DISTINCT + col0 * + col2 - - col2 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT ALL col0 - - cor0.col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + col0 + 2 FROM tab2 cor0
----
80
81
9

query I rowsort
SELECT - + col0 * ( + 51 * - col2 ) AS col2 FROM tab2 AS cor0
----
103428
153102
9639

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + ( col1 ) col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + - col2 * ( 9 ) FROM tab1 AS cor0
----
-486
-513
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col0 + - col2 * col0 col0 FROM tab0 cor0
----
-15397
-2856
-3430

query I rowsort
SELECT DISTINCT - + 42 FROM tab2 AS cor0
----
-42

query I rowsort
SELECT DISTINCT + 51 + 70 FROM tab1 AS cor0
----
121

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * 11 col0 FROM tab2 AS cor0
----
77
858
869

query I rowsort
SELECT ALL - ( - col1 ) * - col2 + + 61 FROM tab2 AS cor0
----
-1473
-585
-776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4858
SELECT + CAST( - col1 AS SIGNED ) * - col1 + - cor0.col0 * + ( - col1 ) FROM tab2 AS cor0
----
1178
1632
8083

skipif mysql # not compatible
query I rowsort label-4858
SELECT + CAST ( - col1 AS INTEGER ) * - col1 + - cor0.col0 * + ( - col1 ) FROM tab2 AS cor0
----
1178
1632
8083

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4859
SELECT - CAST( NULL AS DECIMAL ) + col0 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4859
SELECT - CAST ( NULL AS REAL ) + col0 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 AS col0 FROM tab1, tab0 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT DISTINCT + col0 * + col2 + col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + ( - col0 ) col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT ( + col0 ) + cor0.col0 * - col0 * - col0 FROM tab0 AS cor0
----
13848
42910
705058

query I rowsort
SELECT cor0.col1 * 14 * col2 FROM tab1 AS cor0
----
17472
19656
7980

query I rowsort
SELECT ALL - - col2 * + col1 - col2 * 35 FROM tab0 AS cor0
----
1683
4592
62

query I rowsort
SELECT + - ( - col2 ) * col0 + 39 FROM tab1 AS cor0
----
201
3687
7719

query I rowsort
SELECT ALL ( - col1 ) * + col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - 31 * col0 AS col0 FROM tab0 cor0
----
-1085
-2759
-744

query I rowsort
SELECT DISTINCT + + 71 * col2 FROM tab2 AS cor0
----
1846
1917
2698

query I rowsort
SELECT ALL - 84 + - 18 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 2415a631ce8606b8e4cce4f738cdf609

query I rowsort
SELECT col0 - + col2 AS col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT DISTINCT - col1 + + 31 FROM tab1 AS cor0
----
18
21
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4873
SELECT ALL - + CAST( col2 AS SIGNED ) + col0 FROM tab0 AS cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-4873
SELECT ALL - + CAST ( col2 AS INTEGER ) + col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL + col0 * - 53 AS col1 FROM tab0 AS cor0
----
-1272
-1855
-4717

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + + 23 col2 FROM tab1 AS cor0
----
-3
10
13

query I rowsort
SELECT 41 * col0 AS col1 FROM tab0 cor0
----
1435
3649
984

query I rowsort
SELECT DISTINCT + - 95 AS col2 FROM tab2 cor0
----
-95

query I rowsort
SELECT - 24 * + col1 + - col1 AS col1 FROM tab1 AS cor0
----
-250
-325
-650

query I rowsort
SELECT + - cor0.col2 - + col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL 30 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
-34
-50
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-4881
SELECT + col2 DIV col2 + col0 * + col0 FROM tab1 AS cor0
----
10
4097
6401

skipif mysql # not compatible
query I rowsort label-4881
SELECT + col2 / col2 + col0 * + col0 FROM tab1 AS cor0
----
10
4097
6401

query I rowsort
SELECT ALL - 13 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4883
SELECT ALL cor0.col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4883
SELECT ALL cor0.col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 - - cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + 43 col1 FROM tab0 AS cor0
----
132
67
78

query I rowsort
SELECT ALL + + col0 * ( - col2 * - cor0.col0 ) FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT DISTINCT - col1 * 79 * col0 - - col1 * 60 AS col2 FROM tab1 AS cor0
----
-4602
-49960
-81380

query I rowsort
SELECT - col0 * 93 + col1 FROM tab0 AS cor0
----
-2146
-3158
-8186

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4889
SELECT DISTINCT - - cor0.col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4889
SELECT DISTINCT - - cor0.col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col0 + - 54 * cor0.col0 FROM tab1 AS cor0
----
-165
-3520
-4400

query I rowsort
SELECT col1 + - ( + 34 ) AS col1 FROM tab1
----
-21
-24
-8

query I rowsort
SELECT col0 * - col2 + - col0 * col0 FROM tab1
----
-14080
-171
-7744

onlyif mysql # use DIV operator for integer division
query I rowsort label-4893
SELECT - col1 DIV col2 + + col1 * + col2 FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-4893
SELECT - col1 / col2 + + col1 * + col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT 85 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

query I rowsort
SELECT ALL - - col2 + - ( - col1 ) AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + cor0.col0 + ( col1 * + cor0.col1 ) - 72 AS col1 FROM tab0 AS cor0
----
7348
8298
9372

query I rowsort
SELECT ALL - - col1 * col1 * + 18 AS col0 FROM tab0 AS cor0
----
133128
149058
169362

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) * + col0 col0 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab2, tab1 cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT ALL - col1 * col2 * 79 AS col2 FROM tab2
----
-121186
-51034
-66123

query I rowsort
SELECT - col2 + + col0 * + col1 AS col0 FROM tab2 cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT 15 + - cor1.col2 * 5 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-255
-270
-465

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 55 * + 49 col1 FROM tab0 cor0
----
220990
2695
88935

query I rowsort
SELECT ALL - 64 * col2 + col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT col2 + col1 * col1 * - col2 FROM tab2 AS cor0
----
-10944
-25920
-90480

onlyif mysql # use DIV operator for integer division
query I rowsort label-4906
SELECT - + 72 DIV + col2 + cor0.col2 FROM tab1 AS cor0
----
53
56
96

skipif mysql # not compatible
query I rowsort label-4906
SELECT - + 72 / + col2 + cor0.col2 FROM tab1 AS cor0
----
53
56
96

query I rowsort
SELECT DISTINCT - col1 - col2 AS col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - 56 * col1 + col2 * - 18 AS col1 FROM tab1 AS cor0
----
-1586
-2428
-2456

query I rowsort
SELECT + cor0.col1 + + col2 * cor0.col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + col1 + + col0 + - col2 AS col2 FROM tab1 AS cor0
----
-25
-3
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-4911
SELECT DISTINCT col2 + col2 DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-4911
SELECT DISTINCT col2 + col2 / cor0.col2 AS col2 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT cor0.col1 * col2 + - col2 * col0 * + col2 AS col1 FROM tab1 AS cor0
----
-207366
-7344
-736032

onlyif mysql # use DIV operator for integer division
query I rowsort label-4913
SELECT + ( col2 ) DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4913
SELECT + ( col2 ) / cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + 2 * col0 + - col0 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4915
SELECT 64 DIV 89 + + tab0.col2 col0 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4915
SELECT 64 / 89 + + tab0.col2 col0 FROM tab0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4916
SELECT - + CAST( NULL AS SIGNED ) FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4916
SELECT - + CAST ( NULL AS INTEGER ) FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4917
SELECT DISTINCT ( tab1.col2 ) DIV col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4917
SELECT DISTINCT ( tab1.col2 ) / col1 FROM tab1
----
2
5
7

query I rowsort
SELECT 44 + + col2 FROM tab0
----
126
45
77

query I rowsort
SELECT 73 + - col1 FROM tab2
----
14
42
56

query I rowsort
SELECT ALL - ( 63 ) FROM tab0, tab2 cor0
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col1 * 95 * col2 col2 FROM tab2 AS cor0
----
145789
61387
79546

query I rowsort
SELECT - + col0 * col2 * 93 FROM tab2 AS cor0
----
-17577
-188604
-279186

query I rowsort
SELECT ALL + col2 - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col2 + col0 + 41 * - col1 AS col1 FROM tab1 AS cor0
----
-1009
-289
-357

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4925
SELECT - 5 * + col2 * + CAST( NULL AS DECIMAL ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4925
SELECT - 5 * + col2 * + CAST ( NULL AS REAL ) AS col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4926
SELECT DISTINCT + 45 + col2 DIV - 76 FROM tab2
----
45

skipif mysql # not compatible
query I rowsort label-4926
SELECT DISTINCT + 45 + col2 / - 76 FROM tab2
----
45

query I rowsort
SELECT - col0 + 11 * col2 AS col1 FROM tab0 AS cor0
----
-24
339
813

query I rowsort
SELECT - col2 + + 47 + col0 * tab0.col0 AS col1 FROM tab0
----
1271
590
7886

query I rowsort
SELECT DISTINCT + col2 + + 94 FROM tab0
----
127
176
95

query I rowsort
SELECT + + col2 + col2 * col1 AS col2 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT ALL + col0 * ( + ( - col1 ) ) + - 24 AS col2 FROM tab1
----
-102
-1064
-664

onlyif mysql # use DIV operator for integer division
query I rowsort label-4932
SELECT col2 * ( + tab0.col2 ) DIV tab0.col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4932
SELECT col2 * ( + tab0.col2 ) / tab0.col2 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4933
SELECT col0 + + cor0.col1 DIV col0 AS col1 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-4933
SELECT col0 + + cor0.col1 / col0 AS col1 FROM tab0 AS cor0
----
27
37
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4934
SELECT + CAST( NULL AS SIGNED ) * col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4934
SELECT + CAST ( NULL AS INTEGER ) * col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * - 57 - col1 AS col0 FROM tab0 cor0
----
1282
1898
4982

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4936
SELECT CAST( + col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4936
SELECT CAST ( + col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL col1 * col0 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT - + col0 + + col1 * col2 + - col0 AS col2 FROM tab1 AS cor0
----
1088
1398
442

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 + col2 AS col0 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT - col0 * - cor0.col0 AS col2 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4941
SELECT DISTINCT + - col1 DIV col0 AS col2 FROM tab2 cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-4941
SELECT DISTINCT + - col1 / col0 AS col2 FROM tab2 cor0
----
-4
0

query I rowsort
SELECT ALL col0 - - col0 AS col0 FROM tab0
----
178
48
70

query I rowsort
SELECT + col0 * col0 + - col1 + - col1 AS col1 FROM tab2
----
-13
5966
6207

query I rowsort
SELECT ALL + + col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + col1 * + col2 + col1 - col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + col0 * - tab0.col2 - tab0.col1 AS col2 FROM tab0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 col2 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL col0 + col0 + + col1 FROM tab0
----
134
167
269

query I rowsort
SELECT + ( + col0 ) * col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ALL col2 * ( - col1 ) FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col2 * + col2 col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT DISTINCT + 83 AS col2 FROM tab0 cor0
----
83

query I rowsort
SELECT DISTINCT + col1 + col2 * + col0 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT + 56 + - col0 AS col0 FROM tab2
----
-22
-23
49

query I rowsort
SELECT + 70 - col1 * col2 FROM tab1
----
-1178
-1334
-500

query I rowsort
SELECT col0 + + 28 FROM tab0
----
117
52
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4957
SELECT CAST( col2 AS SIGNED ) * - tab1.col2 AS col1 FROM tab1
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-4957
SELECT CAST ( col2 AS INTEGER ) * - tab1.col2 AS col1 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ( col2 ) * - tab1.col1 AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - tab1.col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT col2 * col1 + - col2 * col1 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL col1 - - col0 * col1 * col2 FROM tab0 AS cor0
----
3492
664209
68198

query I rowsort
SELECT DISTINCT - col0 + + col2 * col2 AS col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT ALL - - 65 + + col2 * - col2 FROM tab1 AS cor0
----
-2851
-3184
-9151

onlyif mysql # use DIV operator for integer division
query I rowsort label-4964
SELECT DISTINCT - - 92 DIV col1 AS col2 FROM tab0 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-4964
SELECT DISTINCT - - 92 / col1 AS col2 FROM tab0 cor0
----
0
1

query I rowsort
SELECT DISTINCT - cor0.col1 * col0 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT 6 * col1 AS col2 FROM tab1 AS cor0
----
156
60
78

query I rowsort
SELECT - cor0.col0 + cor0.col1 * - col0 FROM tab1 cor0
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4968
SELECT ALL + col1 * + col2 DIV col2 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4968
SELECT ALL + col1 * + col2 / col2 FROM tab1 cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL col0 - - col0 * - col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT DISTINCT col1 * - col2 + + col0 * + tab1.col1 AS col1 FROM tab1
----
-1326
-208
70

query I rowsort
SELECT DISTINCT col2 + col2 * col1 FROM tab0
----
2871
7544
98

query I rowsort
SELECT + col2 * tab2.col0 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + tab1.col2 AS col0 FROM tab1 WHERE NULL = NULL
----

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL > col0 + col0
----

query I rowsort
SELECT DISTINCT col2 AS col0 FROM tab2 WHERE col0 NOT IN ( + col2 )
----
26
27
38

query I rowsort
SELECT col2 - + col1 AS col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL + col0 + tab2.col1 * col0 AS col0 FROM tab2
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4979
SELECT col2 + + col1 DIV col0 AS col2 FROM tab0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-4979
SELECT col2 + + col1 / col0 AS col2 FROM tab0
----
3
36
83

query I rowsort
SELECT DISTINCT - col2 + - col0 FROM tab1 WHERE ( NULL ) >= NULL
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( - col1 ) < ( + col0 * + col2 + col2 * col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4982
SELECT col0 DIV col1 col1 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4982
SELECT col0 / col1 col1 FROM tab2
----
0
1
4

query III rowsort
SELECT ALL * FROM tab2 WHERE ( NULL ) NOT IN ( col1 )
----

query I rowsort
SELECT DISTINCT col2 + col0 * - col2 AS col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT + col2 + col0 * - col1 FROM tab1
----
-24
-583
-944

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) IN ( col1 + - col2 )
----

query I rowsort
SELECT - tab2.col2 + + col0 * + col2 + - col1 FROM tab2
----
131
1943
2947

query I rowsort
SELECT - col2 * col0 + col2 FROM tab2
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col2 col1 FROM tab0 AS cor0
----
-164
-2
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + + col1 col1 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4991
SELECT DISTINCT + col2 + col2 DIV - col1 + col0 * - cor0.col2 FROM tab2 AS cor0
----
-162
-2002
-2966

skipif mysql # not compatible
query I rowsort label-4991
SELECT DISTINCT + col2 + col2 / - col1 + col0 * - cor0.col2 FROM tab2 AS cor0
----
-162
-2002
-2966

query I rowsort
SELECT ALL + + col2 + col1 + + col1 FROM tab1 cor0
----
106
122
77

query I rowsort
SELECT + col1 + - col2 * col0 * col1 FROM tab1 AS cor0
----
-36470
-4186
-99827

onlyif mysql # use DIV operator for integer division
query I rowsort label-4994
SELECT - col2 + + col2 DIV - col2 + col0 * col0 AS col2 FROM tab0 AS cor0
----
1223
542
7838

skipif mysql # not compatible
query I rowsort label-4994
SELECT - col2 + + col2 / - col2 + col0 * col0 AS col2 FROM tab0 AS cor0
----
1223
542
7838

onlyif mysql # use DIV operator for integer division
query I rowsort label-4995
SELECT ALL - col1 DIV col0 + col2 * col2 * col2 FROM tab1 AS cor0
----
157456
185193
884736

skipif mysql # not compatible
query I rowsort label-4995
SELECT ALL - col1 / col0 + col2 * col2 * col2 FROM tab1 AS cor0
----
157456
185193
884736

onlyif mysql # use DIV operator for integer division
query I rowsort label-4996
SELECT ALL - col2 + - col0 DIV col1 FROM tab2 AS cor0
----
-27
-27
-42

skipif mysql # not compatible
query I rowsort label-4996
SELECT ALL - col2 + - col0 / col1 FROM tab2 AS cor0
----
-27
-27
-42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + col1 * cor0.col2 col2 FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - col1 col1 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT - col0 - col2 AS col2 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5000
SELECT - cor0.col0 DIV col0 + col2 * col1 FROM tab1 AS cor0
----
1247
1403
569

skipif mysql # not compatible
query I rowsort label-5000
SELECT - cor0.col0 / col0 + col2 * col1 FROM tab1 AS cor0
----
1247
1403
569

onlyif mysql # use DIV operator for integer division
query I rowsort label-5001
SELECT col2 * col1 + + col2 + col1 DIV - col1 FROM tab0 cor0
----
2870
7543
97

skipif mysql # not compatible
query I rowsort label-5001
SELECT col2 * col1 + + col2 + col1 / - col1 FROM tab0 cor0
----
2870
7543
97

query I rowsort
SELECT DISTINCT col1 + - col1 * - col0 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT - col1 + - col2 * col2 * col2 + cor0.col1 * col1 * col0 AS col2 FROM tab0 AS cor0
----
141481
185550
329217

query I rowsort
SELECT + col0 + col0 + + col0 AS col2 FROM tab0 AS cor0
----
105
267
72

query I rowsort
SELECT - col2 + + tab1.col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT - 94 AS col0 FROM tab1 cor0
----
-94
-94
-94

query I rowsort
SELECT ( - col1 ) + - col0 AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - col1 * - col1 + col1 AS col0 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + cor0.col0 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
24
35
89

query I rowsort
SELECT + col1 + ( - col1 * + tab2.col2 ) FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT col1 + ( + col1 ) * + 65 FROM tab2
----
1122
2046
3894

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5012
SELECT CAST( 57 AS SIGNED ) col1 FROM tab1 AS cor0
----
57
57
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5012
SELECT CAST ( 57 AS INTEGER ) col1 FROM tab1 AS cor0
----
57
57
57

query I rowsort
SELECT + col0 * 93 AS col2 FROM tab1 AS cor0
----
279
5952
7440

query I rowsort
SELECT ALL - 58 * + 44 * col1 AS col0 FROM tab1
----
-25520
-33176
-66352

query I rowsort
SELECT ALL + - ( + ( col0 ) ) + col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + - 0 + - col2 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + ( + 1 ) AS col0 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT DISTINCT - col0 * - cor0.col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - + col1 * - col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL col0 * 64 AS col2 FROM tab1
----
192
4096
5120

query I rowsort
SELECT + 5 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5022
SELECT - - col2 + - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5022
SELECT - - col2 + - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col1 - + col0 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + 53 col1 FROM tab0 AS cor0
----
-36
18
29

query I rowsort
SELECT DISTINCT + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT + col2 * + cor0.col2 + + ( + col0 ) + - col0 AS col1 FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5027
SELECT + - col2 - CAST( NULL AS SIGNED ) * col2 * col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5027
SELECT + - col2 - CAST ( NULL AS INTEGER ) * col2 * col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab0.col2 * 17 + col0 * tab0.col1 AS col2 FROM tab0
----
1503
3378
6705

query I rowsort
SELECT + + col2 - 20 * 17 * - col0 FROM tab0 AS cor0
----
11901
30342
8193

query I rowsort
SELECT - col2 * + ( 35 * col0 ) FROM tab0 AS cor0
----
-1225
-255430
-27720

query I rowsort
SELECT cor0.col0 + 53 + + col0 AS col0 FROM tab2 AS cor0
----
209
211
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5032
SELECT ALL - CAST( NULL AS SIGNED ) / cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5032
SELECT ALL - CAST ( NULL AS INTEGER ) / cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5033
SELECT + col1 - + col0 DIV col0 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-5033
SELECT + col1 - + col0 / col0 FROM tab0
----
85
90
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5034
SELECT - CAST( NULL AS SIGNED ) + + cor0.col0 + + col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5034
SELECT - CAST ( NULL AS INTEGER ) + + cor0.col0 + + col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 87 * col0 AS col0 FROM tab0 AS cor0
----
2088
3045
7743

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5036
SELECT CAST( NULL AS SIGNED ) + cor0.col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5036
SELECT CAST ( NULL AS INTEGER ) + cor0.col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 13 + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 4435b24edce29a2f807b74467f950755

query I rowsort
SELECT cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - 42 * - col1 col0 FROM tab0 AS cor0
----
-142590
-340158
-86688

query I rowsort
SELECT - 46 * - col0 AS col2 FROM tab2 AS cor0
----
322
3588
3634

query I rowsort
SELECT + - ( + col0 ) * - col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5042
SELECT - + col2 + col0 DIV + col0 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-5042
SELECT - + col2 + col0 / + col0 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT - col0 + - 68 FROM tab0 AS cor0
----
-103
-157
-92

query I rowsort
SELECT ALL col1 * - ( col0 ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5045
SELECT ALL + cor0.col2 DIV - cor0.col1 + + col1 AS col1 FROM tab2 AS cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-5045
SELECT ALL + cor0.col2 / - cor0.col1 + + col1 AS col1 FROM tab2 AS cor0
----
15
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5046
SELECT DISTINCT + - cor0.col2 + - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5046
SELECT DISTINCT + - cor0.col2 + - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL + + col2 * - col2 AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-5048
SELECT DISTINCT col1 DIV + col1 + + col2 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-5048
SELECT DISTINCT col1 / + col1 + + col2 FROM tab2
----
27
28
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-5049
SELECT 65 DIV - col0 FROM tab1
----
-1
-21
0

skipif mysql # not compatible
query I rowsort label-5049
SELECT 65 / - col0 FROM tab1
----
-1
-21
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + ( col0 ) * - col0 col2 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT - + col0 * col1 * col0 + + col0 + col1 * + col1 FROM tab2 AS cor0
----
-105729
-355397
-551

query I rowsort
SELECT + col0 - col1 AS col2 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + 14 - + col0 * - ( col2 ) AS col1 FROM tab1 AS cor0
----
176
3662
7694

query I rowsort
SELECT ALL + col0 + col1 * ( 12 ) FROM tab0 AS cor0
----
1056
1181
1199

query I rowsort
SELECT DISTINCT - 19 * col2 AS col0 FROM tab0 cor0
----
-1558
-19
-627

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5056
SELECT DISTINCT + 23 + + col2 * - CAST( + col0 + col2 AS SIGNED ) FROM tab1 cor0
----
-16873
-3055
-6874

skipif mysql # not compatible
query I rowsort label-5056
SELECT DISTINCT + 23 + + col2 * - CAST ( + col0 + col2 AS INTEGER ) FROM tab1 cor0
----
-16873
-3055
-6874

query I rowsort
SELECT + cor0.col2 + 74 * + 74 AS col2 FROM tab2 AS cor0
----
5502
5503
5514

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + 33 * 10 col1 FROM tab2 AS cor0
----
356
357
368

query I rowsort
SELECT ALL - - col1 * + ( + 72 ) + col1 FROM tab0 cor0
----
6278
6643
7081

onlyif mysql # use DIV operator for integer division
query I rowsort label-5060
SELECT ALL - col0 DIV col2 AS col0 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-5060
SELECT ALL - col0 / col2 AS col0 FROM tab0 cor0
----
-1
-35
0

query I rowsort
SELECT ALL + - cor0.col1 * col1 + + col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT ALL - - col1 + ( + 27 ) AS col0 FROM tab1 AS cor0
----
37
40
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-5063
SELECT - 52 DIV col1 + 20 FROM tab0
----
20
20
20

skipif mysql # not compatible
query I rowsort label-5063
SELECT - 52 / col1 + 20 FROM tab0
----
20
20
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + cor0.col0 col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL + - 17 - col2 AS col2 FROM tab1 AS cor0
----
-113
-71
-74

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + CAST ( ( + col0 ) AS REAL ) * - col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT 79 * - col2 AS col1 FROM tab1 cor0
----
-4266
-4503
-7584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5068
SELECT DISTINCT - CAST( col1 AS SIGNED ) * col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5068
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5069
SELECT DISTINCT + + CAST( col0 AS SIGNED ) + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-5069
SELECT DISTINCT + + CAST ( col0 AS INTEGER ) + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5070
SELECT - + 5 * + ( - col0 ) + + col1 * 39 DIV col2 AS col0 FROM tab0 AS cor0
----
221
3958
488

skipif mysql # not compatible
query I rowsort label-5070
SELECT - + 5 * + ( - col0 ) + + col1 * 39 / col2 AS col0 FROM tab0 AS cor0
----
221
3958
488

onlyif mysql # use DIV operator for integer division
query I rowsort label-5071
SELECT ALL - 81 DIV col2 - col1 FROM tab1 AS cor0
----
-11
-13
-27

skipif mysql # not compatible
query I rowsort label-5071
SELECT ALL - 81 / col2 - col1 FROM tab1 AS cor0
----
-11
-13
-27

query I rowsort
SELECT - + 43 * cor0.col1 + col2 * + col2 FROM tab0 AS cor0
----
-2609
-4170
2811

query I rowsort
SELECT ALL + + col0 * col0 + + col2 AS col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL - - ( + col2 ) + - col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - cor0.col0 * - col2 * col1 AS col0 FROM tab1 cor0
----
36480
4212
99840

query I rowsort
SELECT ALL + 49 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT + 62 * - col1 + col0 * 88 AS col1 FROM tab1 cor0
----
-1348
5012
6234

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 91 * - col1 col2 FROM tab2 AS cor0
----
1547
2821
5369

query I rowsort
SELECT + col1 * - 64 + col1 FROM tab0 AS cor0
----
-5418
-5733
-6111

query I rowsort
SELECT col1 + - col1 * + cor0.col0 + col0 FROM tab0 AS cor0
----
-1954
-3263
-7919

query I rowsort
SELECT + cor0.col1 + col0 + ( - col2 ) FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT + ( col1 ) + 56 FROM tab1 cor0
----
66
69
82

query I rowsort
SELECT DISTINCT 43 + + col0 * + col0 AS col0 FROM tab2
----
6127
6284
92

query I rowsort
SELECT + 46 * col0 AS col1 FROM tab2
----
322
3588
3634

query I rowsort
SELECT DISTINCT + 53 AS col1 FROM tab2, tab1, tab2 cor0
----
53

query I rowsort
SELECT DISTINCT col2 * col1 + - tab2.col2 * - col2 AS col0 FROM tab2
----
1566
2090
2210

onlyif mysql # use DIV operator for integer division
query I rowsort label-5087
SELECT + col2 DIV 40 FROM tab0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5087
SELECT + col2 / 40 FROM tab0
----
0
0
2

query I rowsort
SELECT DISTINCT + + cor0.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
86
91
97

query I rowsort
SELECT ALL + 26 AS col2 FROM tab0
----
26
26
26

query I rowsort
SELECT ALL - col1 * col2 - cor0.col2 * + 2 FROM tab0 AS cor0
----
-2904
-7626
-99

query I rowsort
SELECT ALL + cor0.col1 + col1 * + col1 * + ( - col1 ) + + 18 FROM tab1 AS cor0
----
-17532
-2166
-972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col0 * col1 - col1 * - col1 col0 FROM tab1 AS cor0
----
1196
728
730

query I rowsort
SELECT DISTINCT cor0.col0 * + col1 - col1 AS col2 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT + 65 * + cor0.col0 + - col2 + col0 AS col2 FROM tab1 AS cor0
----
144
4167
5184

onlyif mysql # use DIV operator for integer division
query I rowsort label-5095
SELECT DISTINCT cor0.col0 + col2 DIV col2 + - 33 AS col1 FROM tab0 AS cor0
----
-8
3
57

skipif mysql # not compatible
query I rowsort label-5095
SELECT DISTINCT cor0.col0 + col2 / col2 + - 33 AS col1 FROM tab0 AS cor0
----
-8
3
57

query I rowsort
SELECT ALL + col0 * cor0.col2 - + col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + + col1 + + col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT + tab0.col2 * + 49 - - ( - col0 * col2 ) FROM tab0
----
-3280
14
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-5099
SELECT DISTINCT col2 DIV col2 col0 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5099
SELECT DISTINCT col2 / col2 col0 FROM tab0
----
1

query I rowsort
SELECT col2 * 24 + col2 AS col1 FROM tab0
----
2050
25
825

query I rowsort
SELECT DISTINCT + col2 * + 79 FROM tab1 AS cor0
----
4266
4503
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-5102
SELECT + - col1 DIV cor0.col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5102
SELECT + - col1 / cor0.col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ALL - + cor0.col2 * + col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT col2 * 2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + col0 + col0 * col0 AS col2 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5106
SELECT + col2 + + 36 + col2 DIV ( - col1 ) FROM tab1 cor0
----
125
88
88

skipif mysql # not compatible
query I rowsort label-5106
SELECT + col2 + + 36 + col2 / ( - col1 ) FROM tab1 cor0
----
125
88
88

query I rowsort
SELECT ( col2 ) * col1 * 17 + col0 + + col0 FROM tab1 cor0
----
21376
23874
9818

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5108
SELECT DISTINCT + CAST( NULL AS SIGNED ) + 53 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5108
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + 53 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( + col1 ) + col1 col0 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-5110
SELECT ALL - col2 + - cor0.col0 DIV col0 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-5110
SELECT ALL - col2 + - cor0.col0 / col0 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT ALL - 63 * col2 AS col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT + + cor0.col0 + cor0.col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - 78 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to b6e4cc21599216686f0cf45b85668b2c

query I rowsort
SELECT + col0 * col0 + - 61 AS col0 FROM tab1 AS cor0
----
-52
4035
6339

query I rowsort
SELECT col2 * 42 - - 66 FROM tab1 AS cor0
----
2334
2460
4098

query I rowsort
SELECT + + col2 + 11 * ( - col1 ) AS col2 FROM tab2 AS cor0
----
-149
-314
-623

query I rowsort
SELECT + + col2 * + 27 + + 20 * + col2 FROM tab1 cor0
----
2538
2679
4512

query I rowsort
SELECT - col0 * - ( 86 ) + - cor0.col2 FROM tab1 AS cor0
----
204
5447
6784

query IIIIII rowsort
SELECT * FROM tab0, tab1 cor0 WHERE NOT NULL <= ( NULL )
----

query I rowsort
SELECT DISTINCT col1 * + col0 + col2 * + col1 AS col1 FROM tab2
----
1054
1989
6136

query III rowsort
SELECT * FROM tab0 WHERE NOT ( col2 ) <= NULL
----

query I rowsort
SELECT col2 / + col1 AS col0 FROM tab1 WHERE col2 * + col2 BETWEEN + col0 AND col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5123
SELECT col0 DIV col1 + + tab0.col1 + col0 AS col0 FROM tab0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-5123
SELECT col0 / col1 + + tab0.col1 + col0 AS col0 FROM tab0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + tab2.col2 col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT tab1.col2 + col2 FROM tab1 WHERE NOT NULL IN ( - col2 + - col1 * tab1.col1 )
----

query I rowsort
SELECT DISTINCT - col2 * + col2 * + col0 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT - ( col0 ) * - col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT 15 + + tab0.col2 AS col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 2514898ba7e6893d8b64a50c63b4b38e

query I rowsort
SELECT DISTINCT - ( 50 ) AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-50

query I rowsort
SELECT 13 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT ALL + - 93 * - col0 AS col1 FROM tab2 AS cor0
----
651
7254
7347

query I rowsort
SELECT ALL + col2 + cor0.col2 * + col1 AS col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - col2 + - cor0.col1 * + ( col1 ) FROM tab1 AS cor0
----
-157
-265
-730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 + + cor0.col0 * col0 col0 FROM tab0 AS cor0
----
-513
1197
1224

query I rowsort
SELECT DISTINCT + 29 * - col1 * + col1 AS col0 FROM tab2
----
-100949
-27869
-8381

query I rowsort
SELECT ALL + + ( cor0.col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - - col0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL + col0 + + 45 FROM tab0 cor0
----
134
69
80

query I rowsort
SELECT 76 - col1 AS col0 FROM tab0
----
-10
-15
-21

query I rowsort
SELECT 47 * + col0 AS col2 FROM tab2 cor0
----
329
3666
3713

query I rowsort
SELECT - - 37 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT ALL - col2 - tab1.col0 * - col1 FROM tab1
----
24
583
944

query I rowsort
SELECT ALL + col2 + 50 - + tab1.col1 FROM tab1
----
133
78
97

query I rowsort
SELECT ALL col2 - tab1.col1 * tab1.col1 AS col2 FROM tab1
----
-43
-622
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5145
SELECT col1 * - CAST( + col2 AS SIGNED ) + col2 * col2 AS col0 FROM tab0 AS cor0
----
-1749
-738
-96

skipif mysql # not compatible
query I rowsort label-5145
SELECT col1 * - CAST ( + col2 AS INTEGER ) + col2 * col2 AS col0 FROM tab0 AS cor0
----
-1749
-738
-96

query I rowsort
SELECT DISTINCT - col0 * + ( + col0 ) FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-5147
SELECT - + col0 - col2 DIV - 29 col1 FROM tab1 AS cor0
----
-2
-63
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5147
SELECT - + col0 - col2 / - 29 col1 FROM tab1 AS cor0
----
-2
-63
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + col1 col1 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT + ( col2 + + col2 ) AS col1 FROM tab0
----
164
2
66

query I rowsort
SELECT ALL - ( + 95 ) * col0 AS col1 FROM tab0
----
-2280
-3325
-8455

query I rowsort
SELECT - ( cor0.col1 ) + - col2 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + 92 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to cfcf012ce1a8dd60a7428b4ef6b95843

query I rowsort
SELECT + - 78 * - ( col0 ) + 43 * ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
1225
3115
840

query I rowsort
SELECT ALL - cor0.col0 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT + ( 71 ) FROM tab2 cor0
----
71
71
71

query I rowsort
SELECT col1 * - col1 * + cor0.col1 + + col1 AS col2 FROM tab2 AS cor0
----
-205320
-29760
-4896

query I rowsort
SELECT + - cor0.col1 + col0 * col2 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-5158
SELECT 42 DIV col0 FROM tab2 AS cor0
----
0
0
6

skipif mysql # not compatible
query I rowsort label-5158
SELECT 42 / col0 FROM tab2 AS cor0
----
0
0
6

query I rowsort
SELECT + - 98 + col0 AS col0 FROM tab0 AS cor0
----
-63
-74
-9

query I rowsort
SELECT ALL col2 + + col0 AS col1 FROM tab0 cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5161
SELECT ALL + col0 + + col0 DIV CAST( 69 * col0 AS SIGNED ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5161
SELECT ALL + col0 + + col0 / CAST ( 69 * col0 AS INTEGER ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - 52 AS col2 FROM tab2 AS cor0
----
-52

query I rowsort
SELECT + 20 + + 72 FROM tab0, tab1 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT + cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + col2 * col0 - ( col0 + + 47 ) FROM tab0 AS cor0
----
-47
7162
721

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5166
SELECT ALL + col2 / CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5166
SELECT ALL + col2 / CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 92 * - col1 + + col0 AS col1 FROM tab1 cor0
----
-1116
-2389
-856

query I rowsort
SELECT ALL + 45 * 7 FROM tab1 AS cor0
----
315
315
315

query I rowsort
SELECT + col0 * ( col2 ) AS col1 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 19 * cor0.col2 col0 FROM tab2, tab2 AS cor0
----
494
513
722

query I rowsort
SELECT DISTINCT + ( - 73 ) FROM tab2 cor0
----
-73

query I rowsort
SELECT DISTINCT + + ( - ( col2 ) ) * col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col0 * - 88 AS col2 FROM tab2 AS cor0
----
616
6864
6952

query I rowsort
SELECT DISTINCT - + 8 + col0 FROM tab0 AS cor0
----
16
27
81

query I rowsort
SELECT + col0 + - col0 * + col1 * - col1 + col2 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
24354
272272
7463

query I rowsort
SELECT ALL - 14 * col1 + + col1 AS col0 FROM tab1
----
-130
-169
-338

query I rowsort
SELECT ALL + tab1.col1 + col2 - - tab1.col2 FROM tab1
----
124
134
205

query I rowsort
SELECT ALL 85 * col2 AS col2 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT ALL + + 89 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1157
-2314
-890

query I rowsort
SELECT col1 + cor0.col1 + - col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - cor0.col2 + + col0 * 9 + col2 FROM tab1 AS cor0
----
27
576
720

query I rowsort
SELECT DISTINCT col0 * + col0 * 33 AS col0 FROM tab0 AS cor0
----
19008
261393
40425

query I rowsort
SELECT DISTINCT + - col2 * - 14 FROM tab1 AS cor0
----
1344
756
798

query I rowsort
SELECT + col2 * 76 AS col0 FROM tab2 AS cor0
----
1976
2052
2888

query I rowsort
SELECT + - col0 * cor0.col0 + - col1 * col1 * - ( col2 ) + col0 FROM tab0 AS cor0
----
243516
671210
8219

query I rowsort
SELECT DISTINCT + - col0 + - 63 * col0 FROM tab1 cor0
----
-192
-4096
-5120

onlyif mysql # use DIV operator for integer division
query I rowsort label-5187
SELECT col1 + + col1 DIV col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-5187
SELECT col1 + + col1 / col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT ALL + - col2 * - ( cor0.col0 ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5189
SELECT col1 DIV 39 + + col0 + col1 FROM tab1 cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-5189
SELECT col1 / 39 + + col0 + col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - col0 * col1 - - ( - col1 ) * col2 AS col0 FROM tab0
----
-15561
-3492
-4902

query I rowsort
SELECT - ( + tab2.col1 ) + 99 - tab2.col1 AS col1 FROM tab2
----
-19
37
65

query I rowsort
SELECT ALL ( - col0 ) + ( col0 ) - - col1 * - 11 FROM tab1
----
-110
-143
-286

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5193
SELECT DISTINCT col1 + - CAST( - col2 AS SIGNED ) FROM tab0 cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-5193
SELECT DISTINCT col1 + - CAST ( - col2 AS INTEGER ) FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT - col2 * col1 * 70 FROM tab2 AS cor0
----
-107380
-45220
-58590

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col1 + CAST ( col0 * cor0.col1 AS REAL ) FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-5196
SELECT col2 * CAST( + col2 AS SIGNED ) + col0 DIV ( - col1 ) AS col0 FROM tab1 AS cor0
----
2916
3243
9210

skipif mysql # not compatible
query I rowsort label-5196
SELECT col2 * CAST ( + col2 AS INTEGER ) + col0 / ( - col1 ) AS col0 FROM tab1 AS cor0
----
2916
3243
9210

query I rowsort
SELECT ALL + - col1 * - ( + 15 ) FROM tab0 AS cor0
----
1290
1365
1455

query I rowsort
SELECT ALL 5 FROM tab0, tab0 cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT - col0 * - 40 * col1 AS col2 FROM tab1
----
25600
3120
41600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5200
SELECT col2 + - CAST( NULL AS DECIMAL ) / col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5200
SELECT col2 + - CAST ( NULL AS REAL ) / col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + 1 + - cor0.col0 * 69 AS col2 FROM tab1 AS cor0
----
-203
-4351
-5439

query I rowsort
SELECT col2 * 70 + col0 + 64 * + col1 AS col2 FROM tab1 AS cor0
----
4694
5447
7632

query I rowsort
SELECT DISTINCT col1 + + 95 * col1 AS col2 FROM tab0
----
8256
8736
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-5204
SELECT + col0 + col2 DIV col0 + ( - col0 ) DIV col1 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-5204
SELECT + col0 + col2 / col0 + ( - col0 ) / col1 FROM tab0 AS cor0
----
25
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5205
SELECT - col2 / - col2 + - col2 / col1 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5205
SELECT - col2 / - col2 + - col2 / col1 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab1.col0 * + col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT col1 * 73 * col2 FROM tab0
----
207174
544726
7081

query I rowsort
SELECT DISTINCT col1 * col1 + col1 * col0 AS col0 FROM tab1
----
1209
740
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-5209
SELECT DISTINCT + tab2.col2 DIV + 80 + 27 FROM tab2
----
27

skipif mysql # not compatible
query I rowsort label-5209
SELECT DISTINCT + tab2.col2 / + 80 + 27 FROM tab2
----
27

query I rowsort
SELECT DISTINCT - - col0 * - cor0.col0 - col2 FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT - col0 + + cor0.col0 * col2 AS col1 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT - col2 * + col0 + - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT - + col1 + col2 * - col1 AS col0 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT ( - 67 ) + tab1.col0 FROM tab1
----
-3
-64
13

query I rowsort
SELECT col2 + + tab0.col0 * + col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT col1 + + 82 * - col2 * - tab0.col2 AS col2 FROM tab0
----
179
551459
89384

query I rowsort
SELECT ALL 26 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT 43 + tab0.col1 * - 57 AS col1 FROM tab0
----
-4859
-5144
-5486

query I rowsort
SELECT DISTINCT + 39 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1014
-1053
-1482

query I rowsort
SELECT ALL - - ( cor0.col0 ) * - col1 + - col0 AS col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT - cor0.col2 + + col2 * - ( col2 ) AS col1 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT DISTINCT + 42 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-1092
-420
-546

onlyif mysql # use DIV operator for integer division
query I rowsort label-5223
SELECT DISTINCT - - 71 + - col0 DIV - 17 FROM tab0 AS cor0
----
72
73
76

skipif mysql # not compatible
query I rowsort label-5223
SELECT DISTINCT - - 71 + - col0 / - 17 FROM tab0 AS cor0
----
72
73
76

query I rowsort
SELECT - 52 * + col0 AS col1 FROM tab2 AS cor0
----
-364
-4056
-4108

query I rowsort
SELECT ( 41 ) FROM tab1
----
41
41
41

query I rowsort
SELECT DISTINCT - 97 * col2 AS col1 FROM tab2
----
-2522
-2619
-3686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5227
SELECT DISTINCT CAST( - col2 AS SIGNED ) AS col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5227
SELECT DISTINCT CAST ( - col2 AS INTEGER ) AS col1 FROM tab0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5228
SELECT ( + col1 ) DIV col0 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5228
SELECT ( + col1 ) / col0 FROM tab1
----
0
0
8

query I rowsort
SELECT DISTINCT + col2 * 59 AS col1 FROM tab0
----
1947
4838
59

query I rowsort
SELECT - 62 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT 64 * + col1 FROM tab1 AS cor0
----
1664
640
832

query I rowsort
SELECT + cor0.col0 * - cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-5233
SELECT - 97 DIV + col0 + col0 * 34 col0 FROM tab1 AS cor0
----
2175
2719
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5233
SELECT - 97 / + col0 + col0 * 34 col0 FROM tab1 AS cor0
----
2175
2719
70

query I rowsort
SELECT - ( col1 ) * + ( - col2 ) + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT 93 - + col0 AS col0 FROM tab2 AS cor0
----
14
15
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5236
SELECT + + col2 * + cor0.col2 - - CAST( NULL AS DECIMAL ) 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-5236
SELECT + + col2 * + cor0.col2 - - CAST ( NULL AS REAL ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 70 FROM tab1, tab1 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT - cor0.col2 - col1 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT 44 - + cor0.col1 * - col1 AS col2 FROM tab2 AS cor0
----
1005
333
3525

query I rowsort
SELECT col1 * - col2 + col0 * cor0.col1 * + col0 FROM tab1 AS cor0
----
-1170
40390
81952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - col1 * + ( col1 ) col2 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT + col1 + col0 * cor0.col2 FROM tab0 AS cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - cor0.col0 + col0 col0 FROM tab0 AS cor0
----
-7209
-768
0

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2, tab1 cor2
----
3645 values hashing to d5761ba4e40f0c65536d1d3c9de4e566

query I rowsort
SELECT DISTINCT + + ( - col2 ) * - col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5246
SELECT DISTINCT CAST( NULL AS SIGNED ) * 23 + col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5246
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 23 + col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT col0 + 16 * + col0 FROM tab0 AS cor0
----
1513
408
595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5248
SELECT ALL + + CAST( NULL AS SIGNED ) / + col1 + - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5248
SELECT ALL + + CAST ( NULL AS INTEGER ) / + col1 + - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 76 + - 99 FROM tab0 cor0
----
-23
-23
-23

query I rowsort
SELECT DISTINCT cor0.col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + + ( 7 ) + col0 * 28 AS col0 FROM tab0 AS cor0
----
2499
679
987

query I rowsort
SELECT ALL ( 27 ) AS col2 FROM tab2 cor0
----
27
27
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col2 + + col1 + ( 56 ) col1 FROM tab2 AS cor0
----
-1419
-573
-750

query I rowsort
SELECT DISTINCT - 10 + 88 * + col2 - col0 * - col1 AS col2 FROM tab0 AS cor0
----
15305
3473
4958

query I rowsort
SELECT - - 44 * col0 * col1 AS col0 FROM tab0 AS cor0
----
149380
356356
90816

query I rowsort
SELECT 55 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * cor0.col2 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + - 26 * + col1 AS col0 FROM tab0 AS cor0
----
-2236
-2366
-2522

query I rowsort
SELECT - - 2 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT + + col0 * + 80 AS col2 FROM tab0 AS cor0
----
1920
2800
7120

query I rowsort
SELECT DISTINCT - + col1 - cor0.col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT - 94 * + tab2.col0 - + col0 FROM tab2
----
-665
-7410
-7505

query I rowsort
SELECT col0 * ( - col2 ) + + col0 AS col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT - col1 - ( - 86 + col1 ) AS col2 FROM tab2
----
-32
24
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - tab0.col0 - - tab0.col0 col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT col2 + 30 FROM tab2 cor0
----
56
57
68

query I rowsort
SELECT - cor0.col2 + col0 AS col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT - - col1 * + col0 + col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - + cor0.col0 + - ( ( - col1 ) ) FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort
SELECT + - col2 * CAST ( - col0 AS REAL ) + - col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT - col2 + ( 15 ) AS col0 FROM tab0 AS cor0
----
-18
-67
14

query I rowsort
SELECT col0 + - ( col0 ) + col0 * + 45 FROM tab2 AS cor0
----
315
3510
3555

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 93 * col2 ) + col2 col2 FROM tab2
----
2444
2538
3572

onlyif mysql # use DIV operator for integer division
query I rowsort label-5274
SELECT ALL col0 - - cor0.col1 DIV - 16 AS col1 FROM tab0 AS cor0
----
19
29
84

skipif mysql # not compatible
query I rowsort label-5274
SELECT ALL col0 - - cor0.col1 / - 16 AS col1 FROM tab0 AS cor0
----
19
29
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-5275
SELECT - + cor0.col2 + col1 * CAST( col1 AS SIGNED ) DIV col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-5275
SELECT - + cor0.col2 + col1 * CAST ( col1 AS INTEGER ) / col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 - cor0.col0 * col1 col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL col1 + - 61 FROM tab1
----
-35
-48
-51

query I rowsort
SELECT DISTINCT 90 - + tab0.col1 AS col0 FROM tab0
----
-1
-7
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col0 col0 FROM tab1
----
0

query I rowsort
SELECT col2 + col2 + ( - col0 + col2 ) FROM tab1
----
107
159
208

query I rowsort
SELECT ALL + 38 + col1 AS col2 FROM tab2 AS cor0
----
55
69
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5282
SELECT + 51 + col0 * col1 DIV col0 FROM tab2 cor0
----
110
68
82

skipif mysql # not compatible
query I rowsort label-5282
SELECT + 51 + col0 * col1 / col0 FROM tab2 cor0
----
110
68
82

query I rowsort
SELECT DISTINCT 79 * 63 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
4977

query I rowsort
SELECT DISTINCT 36 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
36

query I rowsort
SELECT DISTINCT - col1 * col2 + - cor0.col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT - - cor0.col2 + col1 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5287
SELECT col1 * - col2 + + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5287
SELECT col1 * - col2 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 * - col2 + col2 * col2 * col1 AS col0 FROM tab2 AS cor0
----
22788
27550
41912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 7 col1 FROM tab2 AS cor0
----
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5290
SELECT cor0.col1 + + col1 DIV + ( + col2 ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5290
SELECT cor0.col1 + + col1 / + ( + col2 ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - col1 * - 98 - - col0 AS col0 FROM tab2
----
1745
3045
5860

query I rowsort
SELECT col2 + ( col2 ) FROM tab0
----
164
2
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5293
SELECT DISTINCT col0 * + CAST( NULL AS SIGNED ) * - col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5293
SELECT DISTINCT col0 * + CAST ( NULL AS INTEGER ) * - col1 FROM tab0
----
NULL

query I rowsort
SELECT ALL - - col1 * + 53 * col0 FROM tab1 AS cor0
----
33920
4134
55120

query I rowsort
SELECT DISTINCT + ( 32 ) FROM tab2 cor0
----
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) * col2 col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + cor0.col0 * - col1 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT + + 90 + ( - col0 ) FROM tab1 cor0
----
10
26
87

query I rowsort
SELECT - ( - col1 ) * - cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col1 * col1 + col0 + col2 * col0 AS col2 FROM tab1 AS cor0
----
3812
7929
841

query I rowsort
SELECT DISTINCT + + cor0.col0 - + 5 * col2 * - col2 AS col2 FROM tab1 AS cor0
----
14583
16309
46160

query I rowsort
SELECT + - 59 * + col0 FROM tab2 AS cor0
----
-413
-4602
-4661

query I rowsort
SELECT ( 27 ) * + cor0.col0 AS col2 FROM tab1 AS cor0
----
1728
2160
81

query I rowsort
SELECT ALL ( - 6 ) FROM tab2 cor0
----
-6
-6
-6

query I rowsort
SELECT DISTINCT col0 * ( - col0 ) FROM tab0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5306
SELECT ( - col1 ) DIV - cor0.col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5306
SELECT ( - col1 ) / - cor0.col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - cor0.col2 * + cor0.col0 col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL 10 * col2 + col2 FROM tab1 AS cor0
----
1056
594
627

query I rowsort
SELECT ALL + + col0 * 78 + + cor0.col1 * col0 FROM tab1 AS cor0
----
312
5632
7280

onlyif mysql # use DIV operator for integer division
query I rowsort label-5310
SELECT ALL col1 * + col2 DIV - col2 AS col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5310
SELECT ALL col1 * + col2 / - col2 AS col0 FROM tab0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 65 col2 FROM tab0 AS cor0
----
-65
-65
-65

query I rowsort
SELECT DISTINCT + + col0 + + 42 FROM tab2 AS cor0
----
120
121
49

query I rowsort
SELECT ALL col2 * - ( + col1 ) AS col2 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 17 col0 FROM tab0 AS cor0
----
17

query I rowsort
SELECT DISTINCT cor0.col2 * - col2 + col2 * + col0 AS col2 FROM tab0 AS cor0
----
-297
34
574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col2 ) * col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5317
SELECT ALL CAST( col2 AS SIGNED ) + cor0.col2 FROM tab1 AS cor0
----
108
114
192

skipif mysql # not compatible
query I rowsort label-5317
SELECT ALL CAST ( col2 AS INTEGER ) + cor0.col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-5318
SELECT - + 47 + - col2 DIV ( 98 * - col0 ) AS col0 FROM tab0 AS cor0
----
-47
-47
-47

skipif mysql # not compatible
query I rowsort label-5318
SELECT - + 47 + - col2 / ( 98 * - col0 ) AS col0 FROM tab0 AS cor0
----
-47
-47
-47

query I rowsort
SELECT + + ( cor0.col1 ) + col0 FROM tab2 cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5320
SELECT DISTINCT - CAST( col0 AS SIGNED ) AS col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5320
SELECT DISTINCT - CAST ( col0 AS INTEGER ) AS col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT - 0 * - col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * - col2 + 1 col2 FROM tab0 AS cor0
----
-34
-7297
-791

query I rowsort
SELECT ALL + + col0 + col0 + + ( col2 ) FROM tab0 AS cor0
----
260
71
81

query I rowsort
SELECT col1 + 80 AS col2 FROM tab2 AS cor0
----
111
139
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5325
SELECT col1 * CAST( col2 AS SIGNED ) + - col1 FROM tab0 AS cor0
----
0
2752
7371

skipif mysql # not compatible
query I rowsort label-5325
SELECT col1 * CAST ( col2 AS INTEGER ) + - col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-5326
SELECT ALL - col1 DIV 72 + col0 AS col2 FROM tab2 cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5326
SELECT ALL - col1 / 72 + col0 AS col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL - - col0 * 76 * col0 + + col1 FROM tab0 cor0
----
43862
602087
93197

query I rowsort
SELECT DISTINCT col1 * ( + col0 ) + + col2 FROM tab0 AS cor0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 * - ( col0 ) col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL - col2 + + ( col2 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 * 13 AS col1 FROM tab0 AS cor0
----
1118
1183
1261

onlyif mysql # use DIV operator for integer division
query I rowsort label-5332
SELECT DISTINCT - col1 DIV + col1 + - 67 col0 FROM tab0 AS cor0
----
-68

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5332
SELECT DISTINCT - col1 / + col1 + - 67 col0 FROM tab0 AS cor0
----
-68

query I rowsort
SELECT ALL - col0 * col0 + + 85 AS col1 FROM tab2 AS cor0
----
-5999
-6156
36

query I rowsort
SELECT ( + col1 ) * - 20 - + col2 FROM tab2
----
-1206
-378
-647

query I rowsort
SELECT ALL + + col2 + 45 * 15 + + col1 * + 39 AS col1 FROM tab2 cor0
----
1376
1911
3002

query I rowsort
SELECT DISTINCT + cor0.col1 - + 24 * 44 FROM tab2 AS cor0
----
-1025
-1039
-997

query I rowsort
SELECT ALL + cor0.col2 - col0 * + col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT - - col0 + 22 FROM tab2 AS cor0
----
100
101
29

query I rowsort
SELECT - col0 + ( + col1 ) * + col0 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT ( tab2.col2 ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT - cor1.col0 - cor1.col1 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 822c2df270733c1079ccc0b8e544f81e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 col0 FROM tab0, tab0 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

query I rowsort
SELECT - - col0 + 85 AS col2 FROM tab2 AS cor0
----
163
164
92

query I rowsort
SELECT - col2 * 32 AS col1 FROM tab0
----
-1056
-2624
-32

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2, tab2 AS cor3
----
13122 values hashing to ab33cb63addb5f662b313e0ec6d9b2a1

query I rowsort
SELECT + 86 * + 83 + col1 * + ( + col0 ) FROM tab1 cor0
----
7216
7778
8178

query I rowsort
SELECT - col0 * - 80 AS col2 FROM tab1
----
240
5120
6400

query I rowsort
SELECT 17 * 92 AS col1 FROM tab0 AS cor0
----
1564
1564
1564

onlyif mysql # use DIV operator for integer division
query I rowsort label-5350
SELECT DISTINCT - ( col2 ) DIV col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5350
SELECT DISTINCT - ( col2 ) / col2 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT - ( 86 ) FROM tab1 AS cor0
----
-86
-86
-86

query I rowsort
SELECT ALL - ( ( col0 ) ) FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( 94 ) + - cor0.col1 col1 FROM tab0 AS cor0
----
-3
3
8

query I rowsort
SELECT - 9 * col2 * 88 FROM tab1 cor0
----
-42768
-45144
-76032

query I rowsort
SELECT + col0 * - cor0.col1 + col2 + - col0 AS col2 FROM tab0 cor0
----
-2055
-3429
-8106

query I rowsort
SELECT - - col1 * - cor0.col2 + - col2 FROM tab2 cor0
----
-1560
-684
-864

query I rowsort
SELECT 58 + col0 FROM tab1 AS cor0
----
122
138
61

query I rowsort
SELECT DISTINCT + + 35 + + col0 AS col0 FROM tab0 AS cor0
----
124
59
70

query I rowsort
SELECT - col1 * col1 + - col0 * - col1 AS col0 FROM tab2 cor0
----
-744
1054
1121

onlyif mysql # use DIV operator for integer division
query I rowsort label-5360
SELECT ALL - + 1 DIV col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5360
SELECT ALL - + 1 / col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + col1 * + col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL - col0 + - col2 * - col2 * + 84 AS col0 FROM tab0 AS cor0
----
49
564727
91452

query I rowsort
SELECT + col1 * - cor0.col0 + col1 * - col2 FROM tab2 cor0
----
-1054
-1989
-6136

onlyif mysql # use DIV operator for integer division
query I rowsort label-5364
SELECT - col1 * - col1 + - ( - col2 ) + - col2 * col2 DIV col1 FROM tab1 cor0
----
-167
-443
618

skipif mysql # not compatible
query I rowsort label-5364
SELECT - col1 * - col1 + - ( - col2 ) + - col2 * col2 / col1 FROM tab1 cor0
----
-167
-443
618

query I rowsort
SELECT + + cor0.col2 * 1 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * 96 * col0 col0 FROM tab1 cor0
----
-393216
-614400
-864

query I rowsort
SELECT 44 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT + - col0 + col0 * + col1 * col0 AS col1 FROM tab0 AS cor0
----
118790
49512
720722

query I rowsort
SELECT col1 * ( - 37 ) FROM tab2 AS cor0
----
-1147
-2183
-629

query I rowsort
SELECT + 31 * + 36 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1c415aa0d278589229ebcec4594af37e

onlyif mysql # use DIV operator for integer division
query I rowsort label-5371
SELECT + 58 - tab1.col0 DIV + ( col0 ) AS col2 FROM tab1
----
57
57
57

skipif mysql # not compatible
query I rowsort label-5371
SELECT + 58 - tab1.col0 / + ( col0 ) AS col2 FROM tab1
----
57
57
57

query I rowsort
SELECT col0 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 25 * col0 - + cor0.col0 FROM tab2 AS cor0
----
168
1872
1896

query I rowsort
SELECT ALL 95 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT DISTINCT + + col1 * col2 + col2 * ( col2 ) FROM tab2 cor0
----
1566
2090
2210

onlyif mysql # use DIV operator for integer division
query I rowsort label-5376
SELECT ALL - col2 DIV - 1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5376
SELECT ALL - col2 / - 1 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5377
SELECT + col1 * col1 DIV - tab0.col0 AS col1 FROM tab0
----
-268
-308
-93

skipif mysql # not compatible
query I rowsort label-5377
SELECT + col1 * col1 / - tab0.col0 AS col1 FROM tab0
----
-268
-308
-93

query I rowsort
SELECT DISTINCT 9 FROM tab2, tab1 AS cor0
----
9

query I rowsort
SELECT - - col2 * - col1 + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL ( - col1 ) * col2 + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL 24 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( 97 AS REAL ) AS col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

query I rowsort
SELECT + col1 + col1 - col2 AS col0 FROM tab1
----
-2
-37
-70

query I rowsort
SELECT - col2 * + ( + col0 ) + ( 40 ) FROM tab2 AS cor0
----
-149
-1988
-2962

query I rowsort
SELECT ALL + tab2.col0 - col0 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + 53 - ( - col1 * ( col0 ) ) AS col2 FROM tab2
----
1396
270
4655

query I rowsort
SELECT + + ( ( col0 ) ) * + col1 AS col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + col1 * - ( col1 ) + + 23 AS col1 FROM tab0 AS cor0
----
-7373
-8258
-9386

query I rowsort
SELECT ALL + + 95 * + col2 AS col0 FROM tab2 AS cor0
----
2470
2565
3610

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( + ( col1 ) ) * + ( cor0.col1 ) col1 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-5391
SELECT DISTINCT - 82 DIV - 27 AS col1 FROM tab1 cor0
----
3

skipif mysql # not compatible
query I rowsort label-5391
SELECT DISTINCT - 82 / - 27 AS col1 FROM tab1 cor0
----
3

query I rowsort
SELECT ALL + + ( col2 ) + - col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + cor0.col0 * + 2 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT ( col0 ) + col0 * + cor0.col0 FROM tab1 AS cor0
----
12
4160
6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5395
SELECT + + CAST( NULL AS DECIMAL ) * col1 / col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5395
SELECT + + CAST ( NULL AS REAL ) * col1 / col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5396
SELECT ALL - 86 + 91 DIV col2 AS col0 FROM tab0 AS cor0
----
-84
-85
5

skipif mysql # not compatible
query I rowsort label-5396
SELECT ALL - 86 + 91 / col2 AS col0 FROM tab0 AS cor0
----
-84
-85
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5397
SELECT ALL + - CAST( col0 AS SIGNED ) + - col0 AS col2 FROM tab1 AS cor0
----
-128
-160
-6

skipif mysql # not compatible
query I rowsort label-5397
SELECT ALL + - CAST ( col0 AS INTEGER ) + - col0 AS col2 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT + 19 * 89 AS col1 FROM tab0 AS cor0
----
1691
1691
1691

onlyif mysql # use DIV operator for integer division
query I rowsort label-5399
SELECT ALL + 63 + - col2 * col0 DIV ( + 41 ) AS col1 FROM tab0 AS cor0
----
-115
44
63

skipif mysql # not compatible
query I rowsort label-5399
SELECT ALL + 63 + - col2 * col0 / ( + 41 ) AS col1 FROM tab0 AS cor0
----
-115
44
63

query I rowsort
SELECT DISTINCT - 83 + + col1 FROM tab0 AS cor0
----
14
3
8

query I rowsort
SELECT + 48 - - cor0.col1 AS col0 FROM tab1 AS cor0
----
58
61
74

query I rowsort
SELECT 64 * col0 + col0 AS col0 FROM tab2
----
455
5070
5135

query I rowsort
SELECT DISTINCT - col2 + col1 * 63 AS col2 FROM tab2 AS cor0
----
1033
1926
3691

onlyif mysql # use DIV operator for integer division
query I rowsort label-5404
SELECT col0 + ( col2 ) DIV col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-5404
SELECT col0 + ( col2 ) / col2 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT col0 - - col2 AS col2 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL - col0 + + col2 * 19 AS col2 FROM tab2
----
416
506
643

query I rowsort
SELECT DISTINCT 78 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
78

query I rowsort
SELECT - col0 * 54 + ( + col2 ) AS col0 FROM tab1
----
-108
-3399
-4224

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5409
SELECT ALL - + col0 * + CAST( col1 AS SIGNED ) - col0 FROM tab1 AS cor0
----
-1120
-704
-81

skipif mysql # not compatible
query I rowsort label-5409
SELECT ALL - + col0 * + CAST ( col1 AS INTEGER ) - col0 FROM tab1 AS cor0
----
-1120
-704
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * col0 col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5411
SELECT - - col2 * col1 DIV col0 FROM tab0 AS cor0
----
118
2
83

skipif mysql # not compatible
query I rowsort label-5411
SELECT - - col2 * col1 / col0 FROM tab0 AS cor0
----
118
2
83

query I rowsort
SELECT + col2 + col0 * 6 AS col1 FROM tab1
----
441
576
72

query I rowsort
SELECT - - 73 + + col2 AS col0 FROM tab1 AS cor0
----
127
130
169

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5414
SELECT DISTINCT cor1.col2 + - CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5414
SELECT DISTINCT cor1.col2 + - CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
NULL

query I rowsort
SELECT 75 * - 77 + col2 AS col1 FROM tab1 AS cor0
----
-5679
-5718
-5721

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5416
SELECT DISTINCT - col1 * - CAST( NULL AS SIGNED ) * - col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-5416
SELECT DISTINCT - col1 * - CAST ( NULL AS INTEGER ) * - col1 FROM tab1
----
NULL

query I rowsort
SELECT ALL - col2 - - col2 * col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT + col1 + - 7 * col0 AS col2 FROM tab0 AS cor0
----
-148
-532
-82

query I rowsort
SELECT DISTINCT ( + 70 ) FROM tab2 AS cor0
----
70

query I rowsort
SELECT col2 * col2 * col0 AS col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT ALL + - ( col0 ) - - col2 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - col1 * col2 * col2 AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT + - col1 * - col0 + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - ( + col0 * + col2 ) FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL 36 + + col2 AS col2 FROM tab0 AS cor0
----
118
37
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-5426
SELECT + - col2 DIV col0 + col0 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-5426
SELECT + - col2 / col0 + col0 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT DISTINCT - col0 * 51 FROM tab2 AS cor0
----
-357
-3978
-4029

query I rowsort
SELECT ALL - col1 * + 14 AS col1 FROM tab2 cor0
----
-238
-434
-826

query I rowsort
SELECT DISTINCT col2 + + cor0.col2 * col0 * + col2 - + 6 FROM tab0 AS cor0
----
26163
30
598512

query I rowsort
SELECT DISTINCT + col1 + + col1 + col2 FROM tab1 AS cor0
----
106
122
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + ( col0 ) * - cor0.col2 col2 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT ALL + - col0 + - ( col1 ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL - + col2 - cor0.col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT + col0 + - 63 + - col0 * - col2 FROM tab2 AS cor0
----
133
2043
3018

query I rowsort
SELECT - cor0.col2 - ( 3 + + col0 ) AS col0 FROM tab2 AS cor0
----
-107
-120
-37

query I rowsort
SELECT ALL 22 + col2 FROM tab0
----
104
23
55

query I rowsort
SELECT ALL - 31 + + col0 FROM tab2
----
-24
47
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5438
SELECT DISTINCT col2 * col2 + CAST( col2 AS SIGNED ) * + col1 FROM tab0
----
14186
3927
98

skipif mysql # not compatible
query I rowsort label-5438
SELECT DISTINCT col2 * col2 + CAST ( col2 AS INTEGER ) * + col1 FROM tab0
----
14186
3927
98

query I rowsort
SELECT - - cor0.col2 + + 89 * col1 FROM tab0 AS cor0
----
7687
8181
8634

query I rowsort
SELECT - + cor0.col0 + 52 * + col2 AS col1 FROM tab2 AS cor0
----
1274
1397
1897

onlyif mysql # use DIV operator for integer division
query I rowsort label-5441
SELECT col1 * cor0.col1 DIV - ( - col2 ) + col0 FROM tab1 AS cor0
----
15
65
81

skipif mysql # not compatible
query I rowsort label-5441
SELECT col1 * cor0.col1 / - ( - col2 ) + col0 FROM tab1 AS cor0
----
15
65
81

query I rowsort
SELECT 72 * col1 FROM tab2 AS cor0
----
1224
2232
4248

query I rowsort
SELECT ALL col0 * + tab2.col1 + col2 * - col2 AS col0 FROM tab2
----
-101
-512
3926

query I rowsort
SELECT ALL - col0 FROM tab0 WHERE NOT NULL = + col0
----

query I rowsort
SELECT ALL 90 * + col1 FROM tab2
----
1530
2790
5310

query I rowsort
SELECT + - col2 * + 70 AS col0 FROM tab1 AS cor0
----
-3780
-3990
-6720

onlyif mysql # use DIV operator for integer division
query I rowsort label-5447
SELECT DISTINCT + cor0.col2 + col1 DIV ( col2 ) AS col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-5447
SELECT DISTINCT + cor0.col2 + col1 / ( col2 ) AS col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort
SELECT + col2 * CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * - col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT cor0.col1 * + ( cor0.col2 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + cor0.col2 + col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT col0 + - col1 * + 73 FROM tab0
----
-6254
-6554
-7046

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 * - 36 - + 40 * + col1 col0 FROM tab1
----
-1364
-147856
-230920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 + tab1.col0 col1 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT DISTINCT - tab1.col0 * - tab1.col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL col2 + col2 + + col2 FROM tab2
----
114
78
81

query I rowsort
SELECT DISTINCT tab0.col0 * col1 + tab0.col1 + + col0 AS col1 FROM tab0
----
2174
3527
8279

query I rowsort
SELECT DISTINCT + col1 + - col2 FROM tab1 WHERE NULL NOT BETWEEN ( - col2 * col0 ) AND col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5459
SELECT ALL + col2 DIV col2 + col0 * tab0.col2 DIV + col0 + col0 FROM tab0
----
172
37
58

skipif mysql # not compatible
query I rowsort label-5459
SELECT ALL + col2 / col2 + col0 * tab0.col2 / + col0 + col0 FROM tab0
----
172
37
58

query I rowsort
SELECT col1 * - col0 + col2 AS col0 FROM tab2
----
-1305
-190
-4576

query III rowsort
SELECT * FROM tab0 WHERE col0 NOT IN ( col1 - col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT ALL col0 * - col0 + + col1 * - col1 FROM tab1
----
-4196
-6569
-685

onlyif mysql # use DIV operator for integer division
query I rowsort label-5463
SELECT DISTINCT + col0 * col0 + tab2.col0 * col0 DIV tab2.col1 FROM tab2
----
50
6187
6608

skipif mysql # not compatible
query I rowsort label-5463
SELECT DISTINCT + col0 * col0 + tab2.col0 * col0 / tab2.col1 FROM tab2
----
50
6187
6608

query I rowsort
SELECT ALL - tab1.col1 * + col2 AS col2 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5465
SELECT ALL col2 * - col0 - col0 DIV + col1 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-5465
SELECT ALL col2 * - col0 - col0 / + col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col2 * - col1 - + col2 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT - col1 * - col1 + tab2.col2 AS col0 FROM tab2
----
327
3507
988

query I rowsort
SELECT DISTINCT - col2 FROM tab2 WHERE - col1 / + tab2.col0 NOT BETWEEN NULL AND col1
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col1 < - col1 + + col0 * - col0
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT * FROM tab1 WHERE NOT - col0 IN ( tab1.col0 + col1 * - tab1.col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - col1 * tab1.col0 + col1 AS col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT col0 + col1 * col0 + col0 * col0 FROM tab2
----
10764
273
7663

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col0 + col0 col1 FROM tab0
----
260
71
81

query III rowsort
SELECT * FROM tab0 WHERE NOT + col2 * - col1 * - col2 + - col0 NOT IN ( col2 )
----

query I rowsort
SELECT col2 + - col1 + + col2 FROM tab1
----
104
179
82

query I rowsort
SELECT DISTINCT col0 + - col2 + - col0 FROM tab0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5477
SELECT ALL + col1 * col1 + col0 DIV col1 + + col1 * col2 col2 FROM tab0
----
10234
15743
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5477
SELECT ALL + col1 * col1 + col0 / col1 + + col1 * col2 col2 FROM tab0
----
10234
15743
9506

query I rowsort
SELECT - col0 / tab1.col0 AS col2 FROM tab1 WHERE NOT NULL < ( col0 * - col1 )
----

query I rowsort
SELECT ALL ( - ( + col0 ) ) - + 98 * - ( + col1 ) FROM tab2
----
1587
3031
5704

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col0 - + ( col0 + - col1 ) * col0 col0 FROM tab0
----
1464
2135
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5481
SELECT DISTINCT - col0 DIV - col2 + 48 FROM tab0 AS cor0
----
48
49
83

skipif mysql # not compatible
query I rowsort label-5481
SELECT DISTINCT - col0 / - col2 + 48 FROM tab0 AS cor0
----
48
49
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5482
SELECT DISTINCT + CAST( 62 AS SIGNED ) FROM tab2
----
62

skipif mysql # not compatible
query I rowsort label-5482
SELECT DISTINCT + CAST ( 62 AS INTEGER ) FROM tab2
----
62

query I rowsort
SELECT ALL col2 - - col0 * col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT + 48 * col1 AS col0 FROM tab0
----
4128
4368
4656

query I rowsort
SELECT ALL col2 * col1 * + col1 + 24 + + col0 AS col0 FROM tab0
----
244116
679155
9468

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5486
SELECT ALL + CAST( 81 AS SIGNED ) - + col2 FROM tab1
----
-15
24
27

skipif mysql # not compatible
query I rowsort label-5486
SELECT ALL + CAST ( 81 AS INTEGER ) - + col2 FROM tab1
----
-15
24
27

query I rowsort
SELECT DISTINCT + col2 * col0 - - col1 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT 42 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT DISTINCT col2 * + cor0.col1 + col0 * + 8 AS col0 FROM tab0 AS cor0
----
3030
377
8174

query I rowsort
SELECT DISTINCT - cor0.col1 + + col2 * - col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT 13 + + cor0.col1 * 34 AS col2 FROM tab2 AS cor0
----
1067
2019
591

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5492
SELECT DISTINCT - - col2 + col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5492
SELECT DISTINCT - - col2 + col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL - 41 * + col2 AS col0 FROM tab1 cor0
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT - + 60 FROM tab0 AS cor0
----
-60

query I rowsort
SELECT DISTINCT 40 + + cor0.col2 FROM tab2 AS cor0
----
66
67
78

query I rowsort
SELECT col2 * col2 * 45 + + col0 * - cor0.col1 * col2 + col0 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
109085
126930
313840

query I rowsort
SELECT DISTINCT + col1 * - col1 * - ( - col2 ) AS col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT + 93 AS col2 FROM tab1, tab0 cor0
----
93

query I rowsort
SELECT col1 * + ( - col0 ) + - cor0.col1 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - - cor0.col0 * + col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT col1 + col2 * 36 AS col2 FROM tab2 AS cor0
----
1003
1385
995

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5502
SELECT ALL + col2 + - CAST( + col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-5502
SELECT ALL + col2 + - CAST ( + col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - col0 * + ( + col2 + + col2 ) FROM tab1 AS cor0
----
-15360
-324
-7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-5504
SELECT + col1 DIV + 39 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5504
SELECT + col1 / + 39 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5505
SELECT - + CAST( col2 AS SIGNED ) + - col2 AS col2 FROM tab0 AS cor0
----
-164
-2
-66

skipif mysql # not compatible
query I rowsort label-5505
SELECT - + CAST ( col2 AS INTEGER ) + - col2 AS col2 FROM tab0 AS cor0
----
-164
-2
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5506
SELECT DISTINCT - + CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-5506
SELECT DISTINCT - + CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + - 20 + - col0 * - col0 AS col2 FROM tab0 AS cor0
----
1205
556
7901

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( + col0 AS REAL ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT col1 + + col2 * col2 FROM tab0 cor0
----
1175
6815
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT - - ( 19 ) + - col1 * + col1 * - cor0.col1 FROM tab2 AS cor0
----
205398
29810
4932

query I rowsort
SELECT DISTINCT + col0 + + col2 * col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + ( - cor0.col2 ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT ALL 86 + + col2 FROM tab1 AS cor0
----
140
143
182

query I rowsort
SELECT - + col0 * + col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + col1 * + col0 + cor0.col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + col1 * col2 + 80 FROM tab0 AS cor0
----
177
2918
7542

query I rowsort
SELECT ALL - + col1 + + col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - col0 * - col2 + + col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL 35 * col1 AS col1 FROM tab0 AS cor0
----
3010
3185
3395

query I rowsort
SELECT ALL 26 + col1 AS col2 FROM tab1 AS cor0
----
36
39
52

query I rowsort
SELECT DISTINCT - - col2 + + cor0.col0 FROM tab2 cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5523
SELECT DISTINCT + col1 DIV col1 col2 FROM tab1 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5523
SELECT DISTINCT + col1 / col1 col2 FROM tab1 AS cor0
----
1

query I rowsort
SELECT ALL + col2 + ( 71 ) AS col1 FROM tab0 AS cor0
----
104
153
72

query I rowsort
SELECT DISTINCT - - col2 * + cor0.col2 * - col1 FROM tab2 cor0
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-5526
SELECT - + cor0.col2 DIV - col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5526
SELECT - + cor0.col2 / - col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + + col1 + col1 * + cor0.col2 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5528
SELECT DISTINCT CAST( NULL AS SIGNED ) * + 71 + - col0 * 27 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5528
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + 71 + - col0 * 27 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + 7 + col1 AS col0 FROM tab0 AS cor0
----
104
93
98

query I rowsort
SELECT DISTINCT + 90 AS col0 FROM tab2, tab2 AS cor0
----
90

query I rowsort
SELECT ALL - + ( - ( col0 ) ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - 6 + col2 FROM tab2 AS cor0
----
20
21
32

query I rowsort
SELECT ALL + - 81 AS col1 FROM tab2 AS cor0
----
-81
-81
-81

query I rowsort
SELECT ALL + 16 * + col2 + + col2 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT ALL - col1 + - 59 FROM tab1 AS cor0
----
-69
-72
-85

query I rowsort
SELECT ALL + cor0.col1 + + col0 AS col0 FROM tab0 cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 27 + col0 * + 19 col1 FROM tab0 AS cor0
----
1664
429
638

onlyif mysql # use DIV operator for integer division
query I rowsort label-5538
SELECT + col1 + + cor0.col2 DIV ( - 66 ) AS col0 FROM tab0 AS cor0
----
86
90
97

skipif mysql # not compatible
query I rowsort label-5538
SELECT + col1 + + cor0.col2 / ( - 66 ) AS col0 FROM tab0 AS cor0
----
86
90
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5539
SELECT ALL col1 + col0 * CAST( 49 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
173
3146
3933

skipif mysql # not compatible
query I rowsort label-5539
SELECT ALL col1 + col0 * CAST ( 49 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
173
3146
3933

query I rowsort
SELECT - - 31 + - col0 AS col1 FROM tab1 AS cor0
----
-33
-49
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + cor0.col0 ) col1 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5542
SELECT ALL - - ( col1 ) + CAST( 12 AS SIGNED ) AS col1 FROM tab0 cor0
----
103
109
98

skipif mysql # not compatible
query I rowsort label-5542
SELECT ALL - - ( col1 ) + CAST ( 12 AS INTEGER ) AS col1 FROM tab0 cor0
----
103
109
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5543
SELECT - 49 * cor0.col1 DIV + col2 AS col0 FROM tab0 AS cor0
----
-127
-4753
-54

skipif mysql # not compatible
query I rowsort label-5543
SELECT - 49 * cor0.col1 / + col2 AS col0 FROM tab0 AS cor0
----
-127
-4753
-54

query I rowsort
SELECT ( + col0 ) + - tab1.col0 + - tab1.col0 AS col0 FROM tab1
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5545
SELECT - col1 DIV - tab0.col1 + + col1 + + ( - col1 ) * col1 FROM tab0
----
-7309
-8189
-9311

skipif mysql # not compatible
query I rowsort label-5545
SELECT - col1 / - tab0.col1 + + col1 + + ( - col1 ) * col1 FROM tab0
----
-7309
-8189
-9311

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5546
SELECT DISTINCT - ( col0 ) + + tab2.col0 + CAST( NULL AS SIGNED ) / + col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5546
SELECT DISTINCT - ( col0 ) + + tab2.col0 + CAST ( NULL AS INTEGER ) / + col1 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT col0 * col1 + col1 AS col2 FROM tab0
----
2150
3492
8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5548
SELECT - CAST( 83 AS SIGNED ) * col1 FROM tab1
----
-1079
-2158
-830

skipif mysql # not compatible
query I rowsort label-5548
SELECT - CAST ( 83 AS INTEGER ) * col1 FROM tab1
----
-1079
-2158
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5549
SELECT ALL CAST( NULL AS DECIMAL ) * col0 + tab1.col0 * col0 * col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5549
SELECT ALL CAST ( NULL AS REAL ) * col0 + tab1.col0 * col0 * col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 71 + + col0 * - col1 col2 FROM tab2
----
-1272
-146
-4531

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 85 + col1 col2 FROM tab0 AS cor0
----
171
176
182

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 72 ) col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT ALL - col2 * col1 + col2 * 65 * + cor0.col0 FROM tab0 AS cor0
----
2178
466908
48642

query I rowsort
SELECT ALL - ( + ( tab1.col0 ) ) + - 52 FROM tab1
----
-116
-132
-55

query I rowsort
SELECT ALL 78 FROM tab0, tab2 cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query I rowsort
SELECT tab0.col0 * tab0.col2 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT 96 * + col2 + 49 * col1 AS col0 FROM tab0 AS cor0
----
12331
4849
7382

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5558
SELECT - CAST( NULL AS SIGNED ) + 51 * col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5558
SELECT - CAST ( NULL AS INTEGER ) + 51 * col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( cor0.col1 ) + col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5560
SELECT - - CAST( NULL AS DECIMAL ) * col1 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5560
SELECT - - CAST ( NULL AS REAL ) * col1 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - 16 + + tab0.col0 * - col0 * - 8 AS col0 FROM tab0
----
4678
63443
9881

query I rowsort
SELECT ALL col2 * + ( + col0 ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT ( - 98 ) + cor0.col1 * + ( col0 ) AS col1 FROM tab2 AS cor0
----
119
1245
4504

query I rowsort
SELECT ALL + - 86 * col2 AS col0 FROM tab0 AS cor0
----
-2838
-7052
-86

query I rowsort
SELECT ALL - + col0 * - col2 * cor0.col0 AS col1 FROM tab2 cor0
----
1323
158184
237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 90 + 1 col0 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT + col0 + col1 * + cor0.col1 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # use DIV operator for integer division
query I rowsort label-5568
SELECT col0 * 13 * + col1 - + 96 DIV + col2 AS col1 FROM tab1 AS cor0
----
1013
13519
8319

skipif mysql # not compatible
query I rowsort label-5568
SELECT col0 * 13 * + col1 - + 96 / + col2 AS col1 FROM tab1 AS cor0
----
1013
13519
8319

query I rowsort
SELECT DISTINCT - + ( col0 ) * col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - + 49 AS col1 FROM tab2 cor0
----
-49
-49
-49

query I rowsort
SELECT ALL - col1 - 9 FROM tab1
----
-19
-22
-35

query I rowsort
SELECT - col2 + - col2 + + 82 * col1 FROM tab0 AS cor0
----
6986
7298
7952

query I rowsort
SELECT ALL - col2 + col1 - col1 FROM tab1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + ( col0 ) * - col1 col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - - col2 * + col2 * col0 - col2 AS col1 FROM tab0 AS cor0
----
26103
34
598354

query I rowsort
SELECT 9 * + 8 FROM tab1 AS cor0
----
72
72
72

query I rowsort
SELECT - + 42 * cor0.col1 + - col2 + col0 FROM tab1 AS cor0
----
-1143
-413
-562

onlyif mysql # use DIV operator for integer division
query I rowsort label-5578
SELECT ALL 5 DIV col2 AS col1 FROM tab0 AS cor0
----
0
0
5

skipif mysql # not compatible
query I rowsort label-5578
SELECT ALL 5 / col2 AS col1 FROM tab0 AS cor0
----
0
0
5

query I rowsort
SELECT - + ( 11 ) AS col2 FROM tab0 AS cor0
----
-11
-11
-11

query I rowsort
SELECT + 87 + ( col0 ) * col0 FROM tab1 AS cor0
----
4183
6487
96

query I rowsort
SELECT - 99 + - 41 * cor0.col2 FROM tab2 AS cor0
----
-1165
-1206
-1657

query I rowsort
SELECT - col2 * 9 AS col1 FROM tab2
----
-234
-243
-342

query I rowsort
SELECT ALL col1 * + 3 * + col2 + + col1 AS col1 FROM tab1 AS cor0
----
1720
3757
4238

query I rowsort
SELECT - 99 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 64d06513850a26495bc6c2fddeb254b7

query I rowsort
SELECT - - ( col1 ) * - col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5586
SELECT ALL CAST( - col2 AS SIGNED ) * + col0 AS col0 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-5586
SELECT ALL CAST ( - col2 AS INTEGER ) * + col0 AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL + 23 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT 82 + col2 AS col1 FROM tab2 AS cor0
----
108
109
120

query I rowsort
SELECT + col1 * + cor0.col1 - - col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT col1 * + tab1.col2 * col2 + - col0 AS col0 FROM tab1
----
119728
32426
75813

query I rowsort
SELECT + cor0.col0 + 31 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 24fa8f685160021bf96af2f39a41800b

query I rowsort
SELECT col0 * + col1 AS col2 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - - col1 + col2 + 51 AS col1 FROM tab1 AS cor0
----
118
131
160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5594
SELECT ALL col2 - + CAST( col2 + col0 AS SIGNED ) AS col1 FROM tab2 cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5594
SELECT ALL col2 - + CAST ( col2 + col0 AS INTEGER ) AS col1 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5595
SELECT - col1 + - CAST( NULL AS SIGNED ) * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5595
SELECT - col1 + - CAST ( NULL AS INTEGER ) * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col0 + + ( col1 ) + + col2 AS col2 FROM tab1 AS cor0
----
131
189
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5597
SELECT ALL + col0 + CAST( + cor0.col1 * col1 AS SIGNED ) FROM tab1 AS cor0
----
164
249
679

skipif mysql # not compatible
query I rowsort label-5597
SELECT ALL + col0 + CAST ( + cor0.col1 * col1 AS INTEGER ) FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT - col2 * + col1 * col0 + col0 AS col2 FROM tab1 AS cor0
----
-36416
-4209
-99760

query I rowsort
SELECT 28 * col0 - 9 AS col0 FROM tab2
----
187
2175
2203

query I rowsort
SELECT + 62 + - col2 * col0 AS col0 FROM tab1
----
-100
-3586
-7618

query I rowsort
SELECT + cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + - col0 * - col2 - 16 AS col1 FROM tab0 AS cor0
----
19
7282
776

query I rowsort
SELECT DISTINCT + + cor0.col1 * ( 91 ) AS col2 FROM tab0 AS cor0
----
7826
8281
8827

query I rowsort
SELECT - ( - 11 ) * col2 FROM tab0 AS cor0
----
11
363
902

query I rowsort
SELECT 52 * col0 AS col0 FROM tab2
----
364
4056
4108

onlyif mysql # use DIV operator for integer division
query I rowsort label-5606
SELECT - col2 + + tab2.col1 DIV col0 FROM tab2
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-5606
SELECT - col2 + + tab2.col1 / col0 FROM tab2
----
-23
-26
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5607
SELECT ( - tab0.col1 ) * CAST( - 17 AS SIGNED ) + + col0 * + col0 FROM tab0
----
2038
2874
9468

skipif mysql # not compatible
query I rowsort label-5607
SELECT ( - tab0.col1 ) * CAST ( - 17 AS INTEGER ) + + col0 * + col0 FROM tab0
----
2038
2874
9468

query I rowsort
SELECT ALL 89 * + col2 AS col0 FROM tab1 cor0
----
4806
5073
8544

query I rowsort
SELECT ( - cor0.col2 ) FROM tab1, tab0 cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT DISTINCT - - 78 + + col1 * + col0 FROM tab0 AS cor0
----
2142
3473
8177

query I rowsort
SELECT ALL 19 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2, tab1 cor2
----
243 values hashing to 964295a09704e7eeb1758493220d9bb0

query I rowsort
SELECT - + cor0.col0 + - col0 * - 18 AS col0 FROM tab2 AS cor0
----
119
1326
1343

query I rowsort
SELECT DISTINCT + + 59 FROM tab1 cor0
----
59

query I rowsort
SELECT + ( - col2 ) * ( col0 ) FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5615
SELECT ALL col0 * + CAST( NULL AS DECIMAL ) * + tab1.col0 + col2 * + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5615
SELECT ALL col0 * + CAST ( NULL AS REAL ) * + tab1.col0 + col2 * + col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5616
SELECT - CAST( + 60 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-60
-60
-60

skipif mysql # not compatible
query I rowsort label-5616
SELECT - CAST ( + 60 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-60
-60
-60

query I rowsort
SELECT DISTINCT - col1 * - ( 25 ) * - col0 + - col0 FROM tab2
----
-115128
-33654
-5432

query I rowsort
SELECT DISTINCT col2 + + col1 + + col1 FROM tab0
----
195
205
264

query I rowsort
SELECT - tab0.col1 - - tab0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT tab1.col0 + 79 AS col2 FROM tab1
----
143
159
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5621
SELECT DISTINCT tab0.col2 DIV 30 AS col2 FROM tab0, tab0 cor0, tab2 AS cor1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5621
SELECT DISTINCT tab0.col2 / 30 AS col2 FROM tab0, tab0 cor0, tab2 AS cor1
----
0
1
2

query I rowsort
SELECT DISTINCT + + col2 + cor0.col0 * col1 AS col2 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + ( - 30 ) AS col1 FROM tab2 AS cor0
----
-30

query I rowsort
SELECT DISTINCT col0 + col0 * + col1 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL cor0.col1 * + ( col2 ) - 66 FROM tab1 AS cor0
----
1182
1338
504

query I rowsort
SELECT - - 7 * col1 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT ALL + + col0 * - col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT - ( col0 ) * + col1 + - 12 FROM tab0 AS cor0
----
-2076
-3407
-8111

onlyif mysql # use DIV operator for integer division
query I rowsort label-5629
SELECT ALL - 59 DIV + ( col1 ) AS col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5629
SELECT ALL - 59 / + ( col1 ) AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + cor0.col2 * 70 + - col2 FROM tab0 AS cor0
----
2277
5658
69

query I rowsort
SELECT - + ( - col2 ) * col1 + + col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-5632
SELECT DISTINCT ( col1 ) - col1 * - col2 DIV - col2 AS col2 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-5632
SELECT DISTINCT ( col1 ) - col1 * - col2 / - col2 AS col2 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL cor0.col1 * - col2 * col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col0 ) * + col1 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 57 + col0 FROM tab2 AS cor0
----
135
136
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-5636
SELECT DISTINCT + ( 92 ) * col0 DIV + ( col0 ) + - col2 + 20 AS col0 FROM tab1 cor0
----
16
55
58

skipif mysql # not compatible
query I rowsort label-5636
SELECT DISTINCT + ( 92 ) * col0 / + ( col0 ) + - col2 + 20 AS col0 FROM tab1 cor0
----
16
55
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 12 + + col1 * - 22 col0 FROM tab1
----
-208
-274
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-5638
SELECT DISTINCT 45 DIV + col0 - - col1 AS col0 FROM tab1
----
10
13
41

skipif mysql # not compatible
query I rowsort label-5638
SELECT DISTINCT 45 / + col0 - - col1 AS col0 FROM tab1
----
10
13
41

query I rowsort
SELECT + col1 * - tab2.col2 * - col1 + - 42 FROM tab2
----
10940
25905
90464

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + col1 * - 7 col2 FROM tab2 AS cor0
----
-157
-244
-439

query I rowsort
SELECT ALL 88 AS col1 FROM tab0 cor0
----
88
88
88

query I rowsort
SELECT + + col2 + + col1 * col2 * + col2 FROM tab2 AS cor0
----
22626
24586
39910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 43 col0 FROM tab2 AS cor0
----
43
43
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-5644
SELECT DISTINCT col0 + - col0 DIV 57 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-5644
SELECT DISTINCT col0 + - col0 / 57 FROM tab2 AS cor0
----
7
77
78

query I rowsort
SELECT ALL 96 + cor0.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ea939cc4eca7139c622cf7a576e3139

query I rowsort
SELECT + 3 * cor0.col1 * 92 AS col0 FROM tab2 AS cor0
----
16284
4692
8556

query I rowsort
SELECT ALL col1 + + cor0.col0 AS col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + cor0.col1 * ( col1 ) + - col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT ALL - - col0 - 83 * col1 FROM tab0 AS cor0
----
-7114
-7464
-8016

query I rowsort
SELECT + - col1 - + cor0.col2 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - - col1 * col1 + + ( col2 * col2 + 64 ) AS col2 FROM tab0 cor0
----
15069
8549
9474

query I rowsort
SELECT ALL 91 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * - ( - 12 ) col0 FROM tab0 AS cor0
----
1032
1092
1164

query I rowsort
SELECT DISTINCT - - col0 * + ( col2 ) + + col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT + - col1 * cor0.col0 - + 6 AS col0 FROM tab0 AS cor0
----
-2070
-3401
-8105

onlyif mysql # use DIV operator for integer division
query I rowsort label-5656
SELECT + col0 * - 98 + col0 DIV - col0 FROM tab1 AS cor0
----
-295
-6273
-7841

skipif mysql # not compatible
query I rowsort label-5656
SELECT + col0 * - 98 + col0 / - col0 FROM tab1 AS cor0
----
-295
-6273
-7841

query I rowsort
SELECT ALL cor0.col2 + + 35 AS col2 FROM tab1 cor0
----
131
89
92

query I rowsort
SELECT DISTINCT + col0 + - 48 FROM tab1 AS cor0
----
-45
16
32

query I rowsort
SELECT col1 * - col0 + col0 * + col0 - + 29 * ( - col2 + col1 ) AS col1 FROM tab1 AS cor0
----
4819
743
7767

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5660
SELECT + + col2 - - CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-5660
SELECT + + col2 - - CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + col0 + - col0 - col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT 43 + col2 * - col0 + + cor0.col1 FROM tab2 AS cor0
----
-115
-1926
-2942

onlyif mysql # use DIV operator for integer division
query I rowsort label-5663
SELECT - col1 * 95 + + col0 DIV ( col0 ) AS col1 FROM tab0 AS cor0
----
-8169
-8644
-9214

skipif mysql # not compatible
query I rowsort label-5663
SELECT - col1 * 95 + + col0 / ( col0 ) AS col1 FROM tab0 AS cor0
----
-8169
-8644
-9214

query I rowsort
SELECT ALL - col0 * + ( - ( + tab1.col2 ) ) + + 77 FROM tab1
----
239
3725
7757

query I rowsort
SELECT DISTINCT + 28 FROM tab2, tab1 AS cor0
----
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-5666
SELECT col0 * - col0 - + col2 DIV + ( col0 * - col2 + 83 ) AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-5666
SELECT col0 * - col0 - + col2 / + ( col0 * - col2 + 83 ) AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5667
SELECT - col0 DIV tab0.col0 AS col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5667
SELECT - col0 / tab0.col0 AS col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT + + 0 + - col0 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5669
SELECT ALL + - col0 + - col0 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5669
SELECT ALL + - col0 + - col0 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 80 AS col1 FROM tab1 AS cor0
----
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 61 col1 FROM tab2 AS cor0
----
-61
-61
-61

query I rowsort
SELECT ALL - 42 * tab2.col0 AS col0 FROM tab2
----
-294
-3276
-3318

query I rowsort
SELECT + tab1.col0 * - col1 + - col0 FROM tab1
----
-1120
-704
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - ( col1 ) col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5675
SELECT DISTINCT + cor0.col2 DIV 78 FROM tab0, tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5675
SELECT DISTINCT + cor0.col2 / 78 FROM tab0, tab0 AS cor0
----
0
1

query I rowsort
SELECT - ( col0 + col1 ) AS col0 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT ALL cor1.col2 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT ALL cor0.col0 + cor0.col2 AS col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5679
SELECT ALL col1 DIV + col2 + - CAST( col0 AS SIGNED ) + - col1 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-5679
SELECT ALL col1 / + col2 + - CAST ( col0 AS INTEGER ) + - col1 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + 26 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
26

query I rowsort
SELECT ( ( - col2 ) ) + 48 * 4 AS col0 FROM tab0 AS cor0
----
110
159
191

query I rowsort
SELECT - 66 FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
81 values hashing to 18b0c368baac0e3433d1e072f8b49f81

query I rowsort
SELECT + + tab1.col1 * tab0.col0 + - 14 FROM tab1, tab2, tab2 AS cor0, tab0
----
81 values hashing to ed588af0a8a5355dc18b3010aa2bdf0a

onlyif mysql # use DIV operator for integer division
query I rowsort label-5684
SELECT ALL col0 DIV col1 - ( col2 ) * + col2 FROM tab2
----
-1440
-675
-729

skipif mysql # not compatible
query I rowsort label-5684
SELECT ALL col0 / col1 - ( col2 ) * + col2 FROM tab2
----
-1440
-675
-729

query I rowsort
SELECT ALL cor0.col0 + - 35 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 35de21a935abd02c5e98bc1f6581c865

query I rowsort
SELECT ALL + + 96 * - col0 FROM tab0 cor0
----
-2304
-3360
-8544

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 + + col0 col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + cor0.col0 * col2 * - cor0.col2 + + col1 AS col1 FROM tab2 AS cor0
----
-114059
-5072
-52669

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5689
SELECT - CAST( 15 AS SIGNED ) * + cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 6e83a34c3ea3e5da94a8416a6210e75d

skipif mysql # not compatible
query I rowsort label-5689
SELECT - CAST ( 15 AS INTEGER ) * + cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 6e83a34c3ea3e5da94a8416a6210e75d

query I rowsort
SELECT + 63 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

onlyif mysql # use DIV operator for integer division
query I rowsort label-5691
SELECT col0 + cor0.col1 DIV + col0 + col0 * col2 FROM tab2 cor0
----
200
2106
3081

skipif mysql # not compatible
query I rowsort label-5691
SELECT col0 + cor0.col1 / + col0 + col0 * col2 FROM tab2 cor0
----
200
2106
3081

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab0 AS cor1, tab0 cor2
----
972 values hashing to 09b120a8ff13ebafea7af10c2152241b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5693
SELECT - col0 DIV + 82 AS col2 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5693
SELECT - col0 / + 82 AS col2 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT + col2 * ( - cor0.col1 ) + - col0 AS col0 FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT - 72 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-2376
-5904
-72

query I rowsort
SELECT DISTINCT + col0 * + ( col0 ) AS col0 FROM tab1
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5697
SELECT ALL + col1 DIV + ( col1 ) FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5697
SELECT ALL + col1 / + ( col1 ) FROM tab0
----
1
1
1

query I rowsort
SELECT - 26 + col0 * col0 AS col2 FROM tab2 cor0
----
23
6058
6215

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5699
SELECT CAST( col2 AS SIGNED ) * - col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-5699
SELECT CAST ( col2 AS INTEGER ) * - col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT col1 * ( + col2 ) * - cor0.col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT col1 * 91 FROM tab0 AS cor0
----
7826
8281
8827

query I rowsort
SELECT ALL - col1 * + 90 AS col0 FROM tab2 AS cor0
----
-1530
-2790
-5310

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5703
SELECT - - CAST( col1 AS SIGNED ) * - col0 AS col2 FROM tab2 cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-5703
SELECT - - CAST ( col1 AS INTEGER ) * - col0 AS col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col0 * 19 AS col0 FROM tab0 cor0
----
1691
456
665

onlyif mysql # use DIV operator for integer division
query I rowsort label-5705
SELECT DISTINCT + + ( - 80 ) DIV col0 + ( col0 ) FROM tab0 cor0
----
21
33
89

skipif mysql # not compatible
query I rowsort label-5705
SELECT DISTINCT + + ( - 80 ) / col0 + ( col0 ) FROM tab0 cor0
----
21
33
89

query I rowsort
SELECT ALL + ( cor0.col2 ) * col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5707
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + col1 col1 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5707
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + col1 col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL + cor0.col1 + col2 * + ( - col0 ) AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - + col0 + cor0.col1 AS col1 FROM tab0 AS cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col1 ) * + cor0.col2 * + cor0.col2 + col1 col0 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT ALL - cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + + cor0.col1 * col0 + - col1 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT ALL + + col1 + - col2 * 73 * + col1 AS col0 FROM tab2 AS cor0
----
-111923
-47141
-61070

query I rowsort
SELECT - col2 * + col2 + col1 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT 56 + col1 AS col0 FROM tab2
----
115
73
87

query I rowsort
SELECT DISTINCT - ( col2 ) * + col0 * + 67 AS col2 FROM tab1
----
-10854
-244416
-514560

query I rowsort
SELECT ALL col0 * + col1 * 38 + + col2 FROM tab0 AS cor0
----
129011
307844
78465

onlyif mysql # use DIV operator for integer division
query I rowsort label-5718
SELECT cor0.col2 * col1 + 53 DIV col1 AS col0 FROM tab2 AS cor0
----
1534
649
838

skipif mysql # not compatible
query I rowsort label-5718
SELECT cor0.col2 * col1 + 53 / col1 AS col0 FROM tab2 AS cor0
----
1534
649
838

query I rowsort
SELECT + cor0.col2 + col1 * - 28 FROM tab1 AS cor0
----
-223
-268
-674

query I rowsort
SELECT ALL - col0 + - col2 * + ( - cor0.col1 ) FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5721
SELECT - + col2 DIV col2 + - col2 AS col0 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-5721
SELECT - + col2 / col2 + - col2 AS col0 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT DISTINCT col2 + col2 * 94 AS col2 FROM tab0 AS cor0
----
3135
7790
95

query I rowsort
SELECT ALL + col0 * + col1 + col2 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-5724
SELECT + + cor0.col2 DIV - ( + 12 ) col0 FROM tab1 AS cor0
----
-4
-4
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5724
SELECT + + cor0.col2 / - ( + 12 ) col0 FROM tab1 AS cor0
----
-4
-4
-8

query I rowsort
SELECT DISTINCT col1 + - col1 * - col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT col2 * - ( + 44 ) * + col1 FROM tab2 AS cor0
----
-28424
-36828
-67496

onlyif mysql # use DIV operator for integer division
query I rowsort label-5727
SELECT + col2 * col1 DIV - cor0.col0 AS col1 FROM tab0 AS cor0
----
-118
-2
-83

skipif mysql # not compatible
query I rowsort label-5727
SELECT + col2 * col1 / - cor0.col0 AS col1 FROM tab0 AS cor0
----
-118
-2
-83

query I rowsort
SELECT DISTINCT - col1 * + col1 + cor0.col0 AS col1 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT - col2 * col2 + - 16 FROM tab2 AS cor0
----
-1460
-692
-745

query I rowsort
SELECT + 77 * col1 AS col2 FROM tab2
----
1309
2387
4543

query I rowsort
SELECT DISTINCT - 18 * - 58 FROM tab2, tab0 AS cor0
----
1044

query I rowsort
SELECT col0 * - ( - col2 ) FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + + 46 + + col0 AS col1 FROM tab2 AS cor0
----
124
125
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + cor0.col2 col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + col2 * col2 * col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT - cor0.col1 - - col0 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + col0 * - col0 * col2 + col2 * + col1 AS col0 FROM tab0 AS cor0
----
-1128
-16170
-642060

query I rowsort
SELECT ALL + + col1 * - cor0.col0 + - col1 AS col1 FROM tab1 cor0
----
-104
-1053
-650

onlyif mysql # use DIV operator for integer division
query I rowsort label-5739
SELECT - col1 DIV - col1 + col0 AS col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-5739
SELECT - col1 / - col1 + col0 AS col2 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - col0 * col1 + - col2 + col0 FROM tab1 AS cor0
----
-1056
-129
-633

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 + + col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT - 0 * col1 - col1 * + col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + 66 * + col1 + col0 FROM tab1 AS cor0
----
1719
724
938

query I rowsort
SELECT - + 96 - + cor0.col1 AS col2 FROM tab0 cor0
----
-182
-187
-193

query I rowsort
SELECT ALL - col1 * - col0 AS col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL + col1 - - col1 AS col0 FROM tab0
----
172
182
194

query I rowsort
SELECT - tab2.col0 * 58 * - col2 AS col2 FROM tab2
----
10962
117624
174116

query I rowsort
SELECT ALL - 16 - col1 AS col2 FROM tab1
----
-26
-29
-42

onlyif mysql # use DIV operator for integer division
query I rowsort label-5749
SELECT - 66 + - col1 - col1 DIV - col2 AS col0 FROM tab1
----
-76
-79
-92

skipif mysql # not compatible
query I rowsort label-5749
SELECT - 66 + - col1 - col1 / - col2 AS col0 FROM tab1
----
-76
-79
-92

query I rowsort
SELECT - 62 AS col1 FROM tab2 cor0
----
-62
-62
-62

query I rowsort
SELECT + col1 * col2 + - col1 * col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + + col0 + col1 * col1 + col1 FROM tab0 AS cor0
----
7506
8461
9541

query I rowsort
SELECT DISTINCT + ( - 62 ) AS col0 FROM tab0 AS cor0
----
-62

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - col1 AS REAL ) + col2 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col1 col1 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5757
SELECT DISTINCT + col0 DIV - col2 AS col0 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-5757
SELECT DISTINCT + col0 / - col2 AS col0 FROM tab1
----
-1
0

query I rowsort
SELECT - 40 + col2 AS col2 FROM tab2
----
-13
-14
-2

query I rowsort
SELECT DISTINCT 22 * + 84 + col0 AS col2 FROM tab0
----
1872
1883
1937

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5760
SELECT ALL CAST( NULL AS SIGNED ) * 76 + col2 / - col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5760
SELECT ALL CAST ( NULL AS INTEGER ) * 76 + col2 / - col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - ( tab0.col1 ) * col2 AS col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT ALL + - ( - 66 ) * - col1 + cor0.col0 AS col2 FROM tab1 cor0
----
-1713
-596
-778

query I rowsort
SELECT DISTINCT + ( 76 ) * col2 AS col1 FROM tab0 AS cor0
----
2508
6232
76

query I rowsort
SELECT DISTINCT ( 34 ) * + col0 + - col0 AS col1 FROM tab0 AS cor0
----
1155
2937
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 56 col2 FROM tab2 cor0
----
56
56
56

query I rowsort
SELECT DISTINCT + + 66 * cor0.col0 AS col1 FROM tab2 AS cor0
----
462
5148
5214

query I rowsort
SELECT ALL + col2 AS col2 FROM tab2 WHERE NOT NULL IN ( tab2.col0 * - tab2.col0 )
----

query I rowsort
SELECT DISTINCT - col0 + col1 + + cor0.col2 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT - col1 + col2 * + col2 AS col0 FROM tab2 cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-5770
SELECT - cor0.col1 DIV - col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5770
SELECT - cor0.col1 / - col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT ALL col2 + + col2 * col1 FROM tab0
----
2871
7544
98

query I rowsort
SELECT + tab1.col1 * tab1.col1 * + col2 + + tab1.col2 AS col0 FROM tab1
----
16320
36558
5757

query I rowsort
SELECT + cor0.col2 * + col1 + col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col2 * - col1 col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT + cor0.col0 * - tab1.col2 AS col0 FROM tab2 cor0 CROSS JOIN tab1
----
9 values hashing to 99e52647357b835698a6730896ff820d

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab0, tab0 AS cor0 WHERE NULL > NULL
----

query I rowsort
SELECT - + col0 * cor0.col0 + col1 * col2 AS col1 FROM tab2 AS cor0
----
-4550
-5595
788

query I rowsort
SELECT DISTINCT + + col2 + col0 FROM tab1 cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5779
SELECT + col2 DIV col1 + cor0.col1 FROM tab2 AS cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-5779
SELECT + col2 / col1 + cor0.col1 FROM tab2 AS cor0
----
19
31
59

query I rowsort
SELECT col0 * col1 + - col2 * - col0 * - col0 FROM tab1 AS cor0
----
-232832
-408
-613360

query I rowsort
SELECT - cor0.col1 * col1 + col2 * col0 FROM tab1 AS cor0
----
-514
3548
7511

query I rowsort
SELECT + col1 + - col1 * - col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT col2 * + tab0.col2 * - col2 FROM tab0
----
-1
-35937
-551368

query I rowsort
SELECT DISTINCT - col1 + 84 * - col2 FROM tab0 AS cor0
----
-181
-2858
-6979

query I rowsort
SELECT DISTINCT - + cor0.col1 + + ( col2 ) FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT col0 - - tab0.col1 * 70 FROM tab0
----
6044
6459
6825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 94 col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
94

query I rowsort
SELECT ALL - ( + col2 ) * + col1 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + col1 col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - + 36 AS col0 FROM tab0 AS cor0
----
-36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5791
SELECT - ( + col2 ) * + CAST( + 12 AS SIGNED ) FROM tab2 AS cor0
----
-312
-324
-456

skipif mysql # not compatible
query I rowsort label-5791
SELECT - ( + col2 ) * + CAST ( + 12 AS INTEGER ) FROM tab2 AS cor0
----
-312
-324
-456

query I rowsort
SELECT + 87 * - 27 * col2 FROM tab0
----
-192618
-2349
-77517

query I rowsort
SELECT - + cor0.col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ( col0 + + col1 ) * + ( 77 ) AS col0 FROM tab1
----
2233
5698
7161

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5795
SELECT DISTINCT CAST( NULL AS DECIMAL ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5795
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

query I rowsort
SELECT 88 + col1 + ( - col1 ) FROM tab2 AS cor0
----
88
88
88

query I rowsort
SELECT + - 51 AS col0 FROM tab1 AS cor0
----
-51
-51
-51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5798
SELECT - + col1 * col1 + + col2 + ( col0 ) DIV 47 AS col1 FROM tab2 cor0
----
-250
-3454
-934

skipif mysql # not compatible
query I rowsort label-5798
SELECT - + col1 * col1 + + col2 + ( col0 ) / 47 AS col1 FROM tab2 cor0
----
-250
-3454
-934

query I rowsort
SELECT DISTINCT tab0.col0 * - 90 AS col2 FROM tab0, tab2 AS cor0
----
-2160
-3150
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 47 col0 FROM tab2
----
47
47
47

query I rowsort
SELECT ALL col2 * col0 * + col0 + + col2 AS col0 FROM tab0
----
1226
19041
649604

onlyif mysql # use DIV operator for integer division
query I rowsort label-5802
SELECT DISTINCT + 80 DIV - col0 + col2 FROM tab1
----
28
56
95

skipif mysql # not compatible
query I rowsort label-5802
SELECT DISTINCT + 80 / - col0 + col2 FROM tab1
----
28
56
95

query I rowsort
SELECT + cor0.col2 - 10 FROM tab2, tab0 cor0
----
9 values hashing to 746d776e63661670e45b4b9d5784ad11

onlyif mysql # use DIV operator for integer division
query I rowsort label-5804
SELECT + col0 DIV - col1 - - col0 FROM tab2
----
7
75
77

skipif mysql # not compatible
query I rowsort label-5804
SELECT + col0 / - col1 - - col0 FROM tab2
----
7
75
77

query I rowsort
SELECT - 31 + + col1 * - col2 AS col0 FROM tab2
----
-1565
-677
-868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 87 * col1 + - col1 + + col1 * - col2 col1 FROM tab0 AS cor0
----
-10406
-15470
-8633

query I rowsort
SELECT - 25 + - col1 + + col1 FROM tab2 AS cor0
----
-25
-25
-25

query I rowsort
SELECT DISTINCT - + col2 * + col1 * - col2 + cor0.col1 * + cor0.col2 * - col1 FROM tab2 AS cor0
----
-3348
-50622
13566

query I rowsort
SELECT DISTINCT col2 + - col0 * cor0.col0 + - cor0.col0 FROM tab1 cor0
----
-4103
-6384
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-5810
SELECT DISTINCT col2 DIV + col1 col1 FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5810
SELECT DISTINCT col2 / + col1 col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT ALL + tab2.col2 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5812
SELECT DISTINCT + - col1 DIV col0 - col1 FROM tab2 AS cor0
----
-17
-35
-59

skipif mysql # not compatible
query I rowsort label-5812
SELECT DISTINCT + - col1 / col0 - col1 FROM tab2 AS cor0
----
-17
-35
-59

query I rowsort
SELECT ALL col1 + ( + col1 ) FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5814
SELECT ALL + col2 * CAST( cor0.col1 AS SIGNED ) FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5814
SELECT ALL + col2 * CAST ( cor0.col1 AS INTEGER ) FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + - col1 * ( - col2 ) AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL + + cor0.col0 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - col1 * col2 - ( col1 * + col0 ) AS col2 FROM tab2 AS cor0
----
-1054
-1989
-6136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5818
SELECT ALL - 77 * col2 / + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5818
SELECT ALL - 77 * col2 / + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col1 + + ( ( - col2 ) ) FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col0 * - col1 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - col0 * 43 FROM tab2 AS cor0
----
-301
-3354
-3397

query I rowsort
SELECT - col2 * + 79 FROM tab0 AS cor0
----
-2607
-6478
-79

query I rowsort
SELECT ALL + col1 * - ( + col0 ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ( col2 ) * + col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT col2 * - 64 * - tab2.col1 + col0 AS col2 FROM tab2
----
41423
53575
98254

query I rowsort
SELECT DISTINCT + + 36 FROM tab2, tab1 AS cor0, tab0, tab0 AS cor1
----
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-5827
SELECT - - col0 + + col0 * cor0.col1 + - 66 DIV + 36 FROM tab1 AS cor0
----
1119
703
80

skipif mysql # not compatible
query I rowsort label-5827
SELECT - - col0 + + col0 * cor0.col1 + - 66 / + 36 FROM tab1 AS cor0
----
1119
703
80

query I rowsort
SELECT + + cor0.col0 * + col0 - + col2 AS col1 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT ALL - - cor0.col1 * + col1 AS col0 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5830
SELECT + col0 DIV - col1 - cor0.col1 FROM tab1 AS cor0
----
-16
-19
-26

skipif mysql # not compatible
query I rowsort label-5830
SELECT + col0 / - col1 - cor0.col1 FROM tab1 AS cor0
----
-16
-19
-26

query I rowsort
SELECT DISTINCT - 84 + 73 FROM tab0 cor0
----
-11

query I rowsort
SELECT ALL 34 + - col1 AS col2 FROM tab2 AS cor0
----
-25
17
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5833
SELECT ALL + CAST( col1 AS SIGNED ) * - col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-5833
SELECT ALL + CAST ( col1 AS INTEGER ) * - col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ( - col2 ) * + col2 - + 88 FROM tab1 AS cor0
----
-3004
-3337
-9304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5835
SELECT ALL + CAST( + col0 AS SIGNED ) * - col0 + - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

skipif mysql # not compatible
query I rowsort label-5835
SELECT ALL + CAST ( + col0 AS INTEGER ) * - col0 + - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT - col2 * col0 + - col1 + col1 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - ( + 3 ) + + col2 FROM tab1
----
51
54
93

query I rowsort
SELECT ( - tab1.col0 ) - + col1 * - 82 FROM tab1
----
2129
756
986

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5839
SELECT DISTINCT + col0 + col1 * + col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5839
SELECT DISTINCT + col0 + col1 * + col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - - ( col1 ) * col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - ( - col0 ) * + col0 + + 31 FROM tab2 AS cor0
----
6115
6272
80

query I rowsort
SELECT ALL - col0 * ( col2 ) FROM tab0 cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5843
SELECT + col2 DIV col1 + col1 col0 FROM tab1 AS cor0
----
15
20
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5843
SELECT + col2 / col1 + col1 col0 FROM tab1 AS cor0
----
15
20
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - col1 - 52 col0 FROM tab0 AS cor0
----
-2116
-3447
-8151

query I rowsort
SELECT + + ( - col0 ) * + ( - col1 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + col1 - - cor0.col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT 57 + col2 * cor0.col2 * col1 FROM tab0 AS cor0
----
154
611941
93711

query I rowsort
SELECT ALL - + col1 + col2 - + cor0.col0 AS col0 FROM tab0 cor0
----
-131
-77
-98

query I rowsort
SELECT col2 * col0 - ( - col0 ) * - col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 30 * col0 + - cor0.col2 FROM tab1 cor0
----
1863
2304
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col2 col1 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5852
SELECT + - cor0.col2 * CAST( NULL AS SIGNED ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5852
SELECT + - cor0.col2 * CAST ( NULL AS INTEGER ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col2 * + ( col2 ) AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5854
SELECT - cor0.col1 + + ( 10 + col1 ) / - CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5854
SELECT - cor0.col1 + + ( 10 + col1 ) / - CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + col2 * + col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT + col2 * ( col0 ) + - col0 * col2 * col1 FROM tab0 AS cor0
----
-3360
-656820
-67320

query I rowsort
SELECT DISTINCT col1 * ( + col0 ) AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col2 + + col2 * + 73 AS col2 FROM tab0 AS cor0
----
2376
5904
72

query I rowsort
SELECT - tab1.col0 + tab1.col1 AS col1 FROM tab0, tab2, tab1 cor0, tab1
----
81 values hashing to 9ff31c10f9f45351c3058fc54f9279b3

query I rowsort
SELECT + col0 - col0 * - tab2.col0 * - col2 AS col2 FROM tab2
----
-1316
-158106
-237079

query I rowsort
SELECT DISTINCT 5 FROM tab0, tab1, tab1 AS cor0
----
5

query I rowsort
SELECT DISTINCT col0 + + 87 AS col2 FROM tab0 AS cor0
----
111
122
176

query I rowsort
SELECT DISTINCT + - col1 * 88 + + cor0.col0 FROM tab1 AS cor0
----
-1064
-2285
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5864
SELECT DISTINCT + col2 * - CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort label-5864
SELECT DISTINCT + col2 * - CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT 83 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5866
SELECT DISTINCT CAST( NULL AS DECIMAL ) FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5866
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 49 col2 FROM tab0 AS cor0
----
-49
-49
-49

query I rowsort
SELECT - ( + 43 ) + + col1 FROM tab1 AS cor0
----
-17
-30
-33

query I rowsort
SELECT + + 81 + + col0 * col1 FROM tab0 AS cor0
----
2145
3476
8180

query I rowsort
SELECT - + col0 + - 44 * - col0 * col1 FROM tab2 AS cor0
----
202410
59013
9541

query I rowsort
SELECT col0 + col0 * + col1 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - tab1.col1 + + 23 FROM tab1, tab1 AS cor0
----
9 values hashing to e628bc29206616d3425e581e915f2b6f

query I rowsort
SELECT + col2 * ( + 40 + + col1 * - col1 ) FROM tab2
----
-24867
-89466
-9462

query I rowsort
SELECT col1 * 39 FROM tab1
----
1014
390
507

query I rowsort
SELECT tab1.col1 * 30 AS col2 FROM tab1
----
300
390
780

query I rowsort
SELECT cor0.col1 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - ( col1 ) + - col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL - 92 * - col1 + - tab1.col1 * col2 FROM tab1
----
-52
350
988

query I rowsort
SELECT ALL + cor0.col0 + cor0.col0 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 10977325261681ddca962e0a5d2b348b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5880
SELECT - + cor0.col1 * col1 + - CAST( + 87 * col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-12454
-16024
-9484

skipif mysql # not compatible
query I rowsort label-5880
SELECT - + cor0.col1 * col1 + - CAST ( + 87 * col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-12454
-16024
-9484

query I rowsort
SELECT DISTINCT 61 * col2 FROM tab1 AS cor0
----
3294
3477
5856

query I rowsort
SELECT + 21 + + col1 * col1 FROM tab1 cor0
----
121
190
697

query I rowsort
SELECT DISTINCT - 19 * col1 AS col2 FROM tab2 AS cor0
----
-1121
-323
-589

query I rowsort
SELECT ALL + 27 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5885
SELECT ALL - col2 * CAST( NULL AS SIGNED ) + + ( - col1 ) / + ( 65 + cor0.col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5885
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) + + ( - col1 ) / + ( 65 + cor0.col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 11 + cor0.col0 FROM tab2, tab1 cor0
----
9 values hashing to 1dd16a424f474ddb6de21fafc3f7d79c

query I rowsort
SELECT ALL - col2 * + col2 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT - col2 * 20 FROM tab2
----
-520
-540
-760

query I rowsort
SELECT + 25 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT DISTINCT - 5 AS col1 FROM tab2, tab2 cor0, tab1 AS cor1
----
-5

query I rowsort
SELECT - + col1 * col1 + + 4 * - col2 FROM tab1 AS cor0
----
-328
-553
-892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 * + col2 col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + col2 * 76 + + col0 AS col0 FROM tab0 AS cor0
----
111
2532
6321

query I rowsort
SELECT DISTINCT 20 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 + - cor0.col0 col1 FROM tab1 cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + col2 col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5897
SELECT + col2 DIV + col0 col2 FROM tab0 cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5897
SELECT + col2 / + col0 col2 FROM tab0 cor0
----
0
0
1

query I rowsort
SELECT + cor0.col2 + + col0 + ( cor0.col2 ) AS col1 FROM tab2 AS cor0
----
130
155
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-5899
SELECT DISTINCT + ( - cor0.col0 ) + - 14 DIV 1 FROM tab2 cor0
----
-21
-92
-93

skipif mysql # not compatible
query I rowsort label-5899
SELECT DISTINCT + ( - cor0.col0 ) + - 14 / 1 FROM tab2 cor0
----
-21
-92
-93

query I rowsort
SELECT col2 * - col2 + 16 FROM tab0 AS cor0
----
-1073
-6708
15

query I rowsort
SELECT - + col1 * + col2 + + col1 * 79 FROM tab0 cor0
----
-273
3956
7566

query I rowsort
SELECT - col2 + cor0.col1 + col0 * - 76 AS col2 FROM tab2 AS cor0
----
-528
-5895
-6025

query I rowsort
SELECT DISTINCT 28 * col0 + + 75 * ( cor0.col0 + col1 ) FROM tab0 AS cor0
----
10880
15992
8922

query I rowsort
SELECT DISTINCT + cor0.col1 + 22 AS col2 FROM tab0 AS cor0
----
108
113
119

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5905
SELECT DISTINCT + + col0 * CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5905
SELECT DISTINCT + + col0 * CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col2 + col2 * col2 FROM tab0
----
0
1056
6642

query I rowsort
SELECT - 57 + cor0.col1 + - col2 FROM tab2 AS cor0
----
-24
-53
-78

query I rowsort
SELECT col2 * col0 - cor0.col2 * - 17 FROM tab0 AS cor0
----
1353
52
8692

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5909
SELECT ( col0 ) + col1 + - CAST( + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5909
SELECT ( col0 ) + col1 + - CAST ( + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL col0 * - 81 * + col1 + + col0 AS col2 FROM tab1 AS cor0
----
-51776
-6315
-84160

query I rowsort
SELECT + 97 * + 76 + col1 * - 96 + col1 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1773
3435
5451

query I rowsort
SELECT ALL 54 + col2 FROM tab2 AS cor0
----
80
81
92

query I rowsort
SELECT DISTINCT + ( - ( col2 ) ) * + ( col2 * - col0 ) FROM tab2
----
114076
5103
52728

query I rowsort
SELECT DISTINCT ( - col0 ) * col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL - + 30 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-2580
-2730
-2910

onlyif mysql # use DIV operator for integer division
query I rowsort label-5916
SELECT col0 * col0 DIV 60 + col1 AS col2 FROM tab2 AS cor0
----
121
160
31

skipif mysql # not compatible
query I rowsort label-5916
SELECT col0 * col0 / 60 + col1 AS col2 FROM tab2 AS cor0
----
121
160
31

query I rowsort
SELECT DISTINCT - + ( col1 ) + 93 AS col2 FROM tab0 AS cor0
----
-4
2
7

query I rowsort
SELECT 44 * + 90 AS col1 FROM tab0
----
3960
3960
3960

query I rowsort
SELECT - 50 * - col0 AS col2 FROM tab1
----
150
3200
4000

query I rowsort
SELECT ALL + 6 + - 6 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5921
SELECT ALL 55 + col0 * tab2.col1 DIV CAST( ( + tab2.col1 ) AS SIGNED ) AS col0 FROM tab2
----
133
134
62

skipif mysql # not compatible
query I rowsort label-5921
SELECT ALL 55 + col0 * tab2.col1 / CAST ( ( + tab2.col1 ) AS INTEGER ) AS col0 FROM tab2
----
133
134
62

query I rowsort
SELECT - + col2 * 39 + - cor0.col0 FROM tab0 cor0
----
-1311
-3287
-74

query I rowsort
SELECT ALL 57 - col1 * tab1.col2 FROM tab1
----
-1191
-1347
-513

query I rowsort
SELECT ALL col2 + col2 - col2 AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT + col0 * - cor0.col2 + - ( cor0.col1 ) FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT + + 99 - col2 AS col2 FROM tab1 AS cor0
----
3
42
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col1 ) + - col2 col0 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5928
SELECT ALL + col2 + + cor0.col1 + - col1 DIV col1 FROM tab1 cor0
----
108
66
79

skipif mysql # not compatible
query I rowsort label-5928
SELECT ALL + col2 + + cor0.col1 + - col1 / col1 FROM tab1 cor0
----
108
66
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5929
SELECT + 65 DIV - col0 AS col0 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-5929
SELECT + 65 / - col0 AS col0 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT + 39 + + col0 * 50 AS col2 FROM tab0
----
1239
1789
4489

query I rowsort
SELECT + 29 + + col2 FROM tab2
----
55
56
67

query I rowsort
SELECT ALL col1 + tab2.col0 * col0 FROM tab2
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5933
SELECT ALL + col1 DIV col2 + 35 AS col0 FROM tab1 AS cor0
----
35
35
35

skipif mysql # not compatible
query I rowsort label-5933
SELECT ALL + col1 / col2 + 35 AS col0 FROM tab1 AS cor0
----
35
35
35

query I rowsort
SELECT + - col0 * col1 + - 97 FROM tab2 AS cor0
----
-1440
-314
-4699

onlyif mysql # use DIV operator for integer division
query I rowsort label-5935
SELECT ALL + col2 * - cor0.col1 + - col2 * - cor0.col1 DIV col1 FROM tab1 AS cor0
----
-1152
-1350
-513

skipif mysql # not compatible
query I rowsort label-5935
SELECT ALL + col2 * - cor0.col1 + - col2 * - cor0.col1 / col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL ( + col2 ) * + col1 * col0 + col2 AS col2 FROM tab1 AS cor0
----
36537
4266
99936

query I rowsort
SELECT - col2 - - 4 AS col2 FROM tab2
----
-22
-23
-34

query I rowsort
SELECT - tab2.col0 - 87 AS col0 FROM tab2
----
-165
-166
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5939
SELECT DISTINCT - col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5939
SELECT DISTINCT - col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL

query I rowsort
SELECT + col0 * col2 * + 88 AS col0 FROM tab0 AS cor0
----
3080
642224
69696

query I rowsort
SELECT ALL + tab0.col2 * ( tab0.col2 + - col0 ) AS col0 FROM tab0
----
-34
-574
297

query I rowsort
SELECT DISTINCT + col2 * - col2 + - cor0.col0 + col1 AS col1 FROM tab2 AS cor0
----
-1506
-695
-705

query I rowsort
SELECT DISTINCT 89 + col0 * col2 AS col2 FROM tab2 AS cor0
----
2117
278
3091

query I rowsort
SELECT cor0.col2 - + col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT DISTINCT col2 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4039
-6304
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5946
SELECT ALL - CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5946
SELECT ALL - CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - - 50 FROM tab0 cor0
----
50
50
50

query I rowsort
SELECT - ( ( col1 ) ) + + 94 * + col2 AS col0 FROM tab1
----
5050
5348
9011

query I rowsort
SELECT - 4 - cor0.col0 * - col2 AS col1 FROM tab0 AS cor0
----
31
7294
788

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5950
SELECT ALL - CAST( NULL AS DECIMAL ) / + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5950
SELECT ALL - CAST ( NULL AS REAL ) / + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col0 * - 39 + + col0 AS col1 FROM tab0 AS cor0
----
1400
3560
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5952
SELECT - + CAST( + col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5952
SELECT - + CAST ( + col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - + 91 AS col2 FROM tab0 cor0
----
-91
-91
-91

query I rowsort
SELECT DISTINCT cor0.col1 * - col2 + + col1 + col1 AS col1 FROM tab1 AS cor0
----
-1222
-1352
-550

query I rowsort
SELECT ALL col2 + - 19 * - col2 AS col2 FROM tab1 AS cor0
----
1080
1140
1920

query I rowsort
SELECT ( 74 ) FROM tab0 AS cor0
----
74
74
74

query I rowsort
SELECT - - ( - cor0.col2 ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - 9 - + ( + col2 ) AS col2 FROM tab2 AS cor0
----
-35
-36
-47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + tab0.col0 ) * + col2 + + 16 col0 FROM tab0
----
51
7314
808

query I rowsort
SELECT DISTINCT 44 AS col1 FROM tab2, tab2 AS cor0, tab1 cor1
----
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 70 + col1 col2 FROM tab0
----
156
161
167

onlyif mysql # use DIV operator for integer division
query I rowsort label-5962
SELECT - tab1.col0 * - col1 * col2 + 30 DIV + tab1.col0 AS col0 FROM tab1
----
36480
4222
99840

skipif mysql # not compatible
query I rowsort label-5962
SELECT - tab1.col0 * - col1 * col2 + 30 / + tab1.col0 AS col0 FROM tab1
----
36480
4222
99840

query I rowsort
SELECT ALL - ( + col2 + + 40 ) FROM tab0
----
-122
-41
-73

query I rowsort
SELECT DISTINCT - + 80 FROM tab0 cor0
----
-80

query I rowsort
SELECT col2 + col0 + + 44 FROM tab1 AS cor0
----
101
165
220

query I rowsort
SELECT ALL 59 AS col1 FROM tab0
----
59
59
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5967
SELECT ALL col0 DIV 44 FROM tab1 cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-5967
SELECT ALL col0 / 44 FROM tab1 cor0
----
0
1
1

query I rowsort
SELECT DISTINCT col1 + 80 FROM tab1 AS cor0
----
106
90
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * + cor0.col2 * col0 + - col0 * 9 col0 FROM tab0 AS cor0
----
-1540
-19224
-650323

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col1 col1 FROM tab1 cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * - ( 27 ) col2 FROM tab0 AS cor0
----
2214
27
891

query I rowsort
SELECT cor0.col2 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL - col1 - + col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT cor0.col0 + - 92 AS col1 FROM tab2 cor0
----
-13
-14
-85

query I rowsort
SELECT DISTINCT - - col2 + 32 + + 71 AS col0 FROM tab0 cor0
----
104
136
185

query I rowsort
SELECT + col0 * + ( + 32 ) FROM tab2 AS cor0
----
224
2496
2528

query I rowsort
SELECT - col0 + - col2 * + cor0.col1 FROM tab2 cor0
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT cor0.col1 + 27 FROM tab0 AS cor0
----
113
118
124

query I rowsort
SELECT DISTINCT + col2 + col2 * col0 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT - + ( - col1 ) * col1 + ( + col2 ) FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT + + col1 + col0 * col1 * ( - cor0.col0 ) FROM tab1 AS cor0
----
-208
-40950
-83187

query I rowsort
SELECT DISTINCT + ( - col0 ) + - col0 + - col0 FROM tab0 AS cor0
----
-105
-267
-72

query I rowsort
SELECT + - col2 + cor0.col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
22
6058
6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5984
SELECT DISTINCT - - CAST( + col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5984
SELECT DISTINCT - - CAST ( + col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5985
SELECT DISTINCT - CAST( col1 AS SIGNED ) * - col0 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-5985
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * - col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5986
SELECT ALL + CAST( col1 AS SIGNED ) * cor0.col1 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-5986
SELECT ALL + CAST ( col1 AS INTEGER ) * cor0.col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + - 26 AS col1 FROM tab2 AS cor0
----
-26

query I rowsort
SELECT col1 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT col0 * + col0 * - cor0.col2 + col1 * + col2 FROM tab0 AS cor0
----
-1128
-16170
-642060

onlyif mysql # use DIV operator for integer division
query I rowsort label-5990
SELECT ALL - 20 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5990
SELECT ALL - 20 / col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( col1 ) + 57 - - col0 FROM tab0 AS cor0
----
167
189
237

onlyif mysql # use DIV operator for integer division
query I rowsort label-5992
SELECT + - col2 * + col2 + 32 * col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
-1097
-12
-6755

skipif mysql # not compatible
query I rowsort label-5992
SELECT + - col2 * + col2 + 32 * col0 / - col1 AS col0 FROM tab0 AS cor0
----
-1097
-12
-6755

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5993
SELECT DISTINCT 6 - + col0 * CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5993
SELECT DISTINCT 6 - + col0 * CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL ( 46 ) * col0 + ( ( col2 ) + 22 ) FROM tab2
----
3636
3694
371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5995
SELECT + col1 + - cor0.col2 * CAST( col0 AS SIGNED ) + col0 AS col2 FROM tab1 AS cor0
----
-133
-3574
-7587

skipif mysql # not compatible
query I rowsort label-5995
SELECT + col1 + - cor0.col2 * CAST ( col0 AS INTEGER ) + col0 AS col2 FROM tab1 AS cor0
----
-133
-3574
-7587

query I rowsort
SELECT + - col1 + col0 * + col1 + col2 FROM tab2 AS cor0
----
1364
213
4569

onlyif mysql # use DIV operator for integer division
query I rowsort label-5997
SELECT col1 + - cor0.col0 + + cor0.col1 DIV col1 FROM tab2 AS cor0
----
-18
-61
25

skipif mysql # not compatible
query I rowsort label-5997
SELECT col1 + - cor0.col0 + + cor0.col1 / col1 FROM tab2 AS cor0
----
-18
-61
25

query I rowsort
SELECT DISTINCT cor1.col0 FROM tab0, tab1 cor0, tab1 AS cor1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 * - col2 - cor0.col1 col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT - - tab0.col0 FROM tab0, tab0 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( + col0 AS REAL ) - cor0.col0 FROM tab2 AS cor0
----
-14
-156
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6002
SELECT + col0 * tab1.col2 DIV tab1.col1 AS col1 FROM tab1
----
364
590
6

skipif mysql # not compatible
query I rowsort label-6002
SELECT + col0 * tab1.col2 / tab1.col1 AS col1 FROM tab1
----
364
590
6

query I rowsort
SELECT ( 92 ) * col2 FROM tab0
----
3036
7544
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 87 + - 76 col1 FROM tab0
----
11

query I rowsort
SELECT DISTINCT - col1 + + col0 + col0 AS col2 FROM tab2
----
-17
141
97

query I rowsort
SELECT - 51 * tab2.col1 AS col1 FROM tab2
----
-1581
-3009
-867

query I rowsort
SELECT - cor0.col1 * - 98 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to da8d4f2a1e6c5b1716a2cfa22160974b

query I rowsort
SELECT DISTINCT - ( - col2 ) + col1 * col1 * col0 FROM tab1 AS cor0
----
13616
2082
6457

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col2 - col2 col2 FROM tab2
----
-1482
-702
-756

query I rowsort
SELECT DISTINCT - col0 * + col2 - - col1 AS col0 FROM tab1
----
-136
-3638
-7667

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to c3f17e238f07c9d20c4ee001084f26c7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6012
SELECT - col0 + + col1 DIV col1 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-6012
SELECT - col0 + + col1 / col1 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT + col1 * - 31 + + col2 + + col0 FROM tab0 AS cor0
----
-2609
-2650
-2971

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 93 + + cor0.col1 * - col0 col1 FROM tab1 AS cor0
----
-547
-947
15

query I rowsort
SELECT ALL + 99 - - col2 AS col2 FROM tab2 AS cor0
----
125
126
137

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - col1 * - col2 AS REAL ) + ( + col0 ) AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT + 11 * col1 + col0 FROM tab1 AS cor0
----
174
223
289

query I rowsort
SELECT DISTINCT - 4 - + col2 * col0 FROM tab1 AS cor0
----
-166
-3652
-7684

onlyif mysql # use DIV operator for integer division
query I rowsort label-6019
SELECT DISTINCT + cor0.col1 DIV col0 - + col1 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-6019
SELECT DISTINCT + cor0.col1 / col0 - + col1 FROM tab0 AS cor0
----
-83
-90
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 34 + - col1 * col0 col0 FROM tab0 AS cor0
----
-2030
-3361
-8065

query I rowsort
SELECT DISTINCT - 0 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + + ( - col0 ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + 79 - col2 * col1 FROM tab1
----
-1169
-1325
-491

query I rowsort
SELECT - col0 + col2 * + col2 FROM tab2
----
1365
598
722

query I rowsort
SELECT + 57 AS col1 FROM tab1 cor0
----
57
57
57

query I rowsort
SELECT 72 + col1 FROM tab2 AS cor0
----
103
131
89

query I rowsort
SELECT DISTINCT - col1 + - 53 AS col0 FROM tab1 AS cor0
----
-63
-66
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 + - col2 * - cor0.col2 col1 FROM tab0 AS cor0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-6029
SELECT DISTINCT col0 * col1 DIV + ( col1 ) AS col2 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-6029
SELECT DISTINCT col0 * col1 / + ( col1 ) AS col2 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6030
SELECT - cor0.col1 DIV + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6030
SELECT - cor0.col1 / + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT - col1 * + 45 AS col0 FROM tab2 AS cor0
----
-1395
-2655
-765

query I rowsort
SELECT ALL col2 + col1 * - col1 AS col2 FROM tab1 cor0
----
-43
-622
-73

query I rowsort
SELECT cor0.col2 * cor0.col0 + + col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL + ( tab0.col0 + col2 ) AS col0 FROM tab0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6035
SELECT ALL - col0 * - col1 * col1 + + col2 * + cor0.col2 DIV cor0.col2 FROM tab0 AS cor0
----
177537
329316
737091

skipif mysql # not compatible
query I rowsort label-6035
SELECT ALL - col0 * - col1 * col1 + + col2 * + cor0.col2 / cor0.col2 FROM tab0 AS cor0
----
177537
329316
737091

query I rowsort
SELECT ALL - tab2.col0 * col2 - col1 * + col0 AS col2 FROM tab2
----
-406
-4345
-6630

onlyif mysql # use DIV operator for integer division
query I rowsort label-6037
SELECT col0 + - col0 DIV + 47 + col1 col0 FROM tab2
----
136
38
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6037
SELECT col0 + - col0 / + 47 + col1 col0 FROM tab2
----
136
38
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 43 * - col1 col0 FROM tab1 AS cor0
----
-1118
-430
-559

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6039
SELECT - CAST( NULL AS SIGNED ) col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6039
SELECT - CAST ( NULL AS INTEGER ) col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 22 * col1 * col0 + ( + col0 ) FROM tab0 AS cor0
----
-178089
-45384
-74655

query I rowsort
SELECT - tab2.col0 * + ( - 86 ) + col2 FROM tab2
----
629
6734
6832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 73 col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT DISTINCT - col1 * - cor0.col1 * - 70 + - col2 AS col0 FROM tab2 AS cor0
----
-20268
-243696
-67297

query I rowsort
SELECT ALL - col0 * + tab2.col2 * + col2 + - col1 + + col2 AS col2 FROM tab2
----
-114055
-5107
-52761

query I rowsort
SELECT ALL col0 + col1 * col0 AS col0 FROM tab0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6046
SELECT DISTINCT col0 * - col0 + col1 * cor0.col1 * col2 + CAST( NULL AS DECIMAL ) * 92 / col1 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6046
SELECT DISTINCT col0 * - col0 + col1 * cor0.col1 * col2 + CAST ( NULL AS REAL ) * 92 / col1 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - 2 + col0 FROM tab1 cor0
----
1
62
78

query I rowsort
SELECT DISTINCT + + col1 * + cor0.col1 * - col1 + + col0 FROM tab0 AS cor0
----
-636032
-753482
-912638

query I rowsort
SELECT DISTINCT - ( + col1 * + col0 ) + + col1 AS col0 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT + col1 * + 32 FROM tab1
----
320
416
832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6052
SELECT ALL - col1 * + tab1.col2 DIV + col2 + - col1 * - col0 AS col2 FROM tab1
----
1027
52
630

skipif mysql # not compatible
query I rowsort label-6052
SELECT ALL - col1 * + tab1.col2 / + col2 + - col1 * - col0 AS col2 FROM tab1
----
1027
52
630

query I rowsort
SELECT tab0.col0 - + 90 FROM tab0
----
-1
-55
-66

query I rowsort
SELECT DISTINCT + col1 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - - 46 * - col0 + ( + col2 ) * col2 AS col2 FROM tab0 cor0
----
-15
-1609
2630

query I rowsort
SELECT ALL + + 84 * col2 AS col1 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT DISTINCT - col2 * + col2 + - col2 * col0 FROM tab0 cor0
----
-14022
-1881
-36

query I rowsort
SELECT DISTINCT - - col0 - + col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6059
SELECT ALL col0 + - col2 DIV col0 - col1 AS col1 FROM tab1 AS cor0
----
-41
54
66

skipif mysql # not compatible
query I rowsort label-6059
SELECT ALL col0 + - col2 / col0 - col1 AS col1 FROM tab1 AS cor0
----
-41
54
66

query I rowsort
SELECT DISTINCT - - col0 * - col0 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - col2 + + col0 - ( + cor0.col1 * + col0 ) FROM tab2 cor0
----
-1302
-237
-4550

query I rowsort
SELECT ALL + - col0 * + col0 + ( + col0 ) AS col2 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT - + ( col0 ) * cor0.col2 * - col0 + col2 + + col0 FROM tab2 AS cor0
----
1357
158288
237275

query I rowsort
SELECT - ( 35 ) * - col2 + col0 AS col1 FROM tab0 AS cor0
----
1179
2959
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6065
SELECT - - CAST( NULL AS SIGNED ) + ( cor0.col0 ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6065
SELECT - - CAST ( NULL AS INTEGER ) + ( cor0.col0 ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6066
SELECT CAST( NULL AS SIGNED ) / - col1 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6066
SELECT CAST ( NULL AS INTEGER ) / - col1 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col2 + cor0.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT col0 + ( - col2 ) AS col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT - + cor0.col1 AS col2 FROM tab1 cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6070
SELECT DISTINCT + col2 + + CAST( + col2 AS SIGNED ) FROM tab1
----
108
114
192

skipif mysql # not compatible
query I rowsort label-6070
SELECT DISTINCT + col2 + + CAST ( + col2 AS INTEGER ) FROM tab1
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - 76 + col1 * - col2 col1 FROM tab2
----
-1938
-3193
-6018

query I rowsort
SELECT + col1 * - col2 + col2 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT - ( 83 + - col2 ) FROM tab2
----
-45
-56
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6074
SELECT DISTINCT - col1 DIV + tab0.col1 AS col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-6074
SELECT DISTINCT - col1 / + tab0.col1 AS col0 FROM tab0
----
-1

query I rowsort
SELECT col0 * col0 * - col1 + col0 FROM tab1
----
-231
-40896
-83120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 + col1 ) col0 FROM tab2
----
55
58
85

query I rowsort
SELECT + - col1 * + col1 + + col2 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT - col2 * + 9 AS col1 FROM tab2
----
-234
-243
-342

query I rowsort
SELECT + ( tab0.col0 * col0 ) FROM tab0
----
1225
576
7921

query I rowsort
SELECT - cor0.col1 + 89 AS col2 FROM tab0 cor0
----
-2
-8
3

query I rowsort
SELECT DISTINCT + col0 + 23 * + col2 FROM tab2 cor0
----
628
676
953

query I rowsort
SELECT - col0 * - col2 + cor0.col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL + + 36 * 89 + col1 FROM tab0 AS cor0
----
3290
3295
3301

onlyif mysql # use DIV operator for integer division
query I rowsort label-6084
SELECT DISTINCT - tab2.col0 DIV + col1 AS col2 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6084
SELECT DISTINCT - tab2.col0 / + col1 AS col2 FROM tab2
----
-1
-4
0

query I rowsort
SELECT ALL 60 - - col2 FROM tab1
----
114
117
156

query I rowsort
SELECT DISTINCT col0 * - col1 + - col0 * - col2 AS col2 FROM tab1
----
3008
6640
84

query I rowsort
SELECT + + col0 - + 46 AS col1 FROM tab2 AS cor0
----
-39
32
33

query I rowsort
SELECT col0 * + tab0.col2 + tab0.col1 * col1 + col2 FROM tab0
----
15661
8221
9445

query I rowsort
SELECT ALL - 69 * tab2.col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 344ee349f2dbc876efc9b304cb580084

query I rowsort
SELECT DISTINCT - col1 * tab2.col0 AS col0 FROM tab2
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + - col2 col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT 50 FROM tab0, tab1 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT + col2 - ( col1 ) AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - - col0 + col1 * + col2 * col0 AS col0 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT ALL + cor0.col1 + - 70 + - col2 * col1 FROM tab2 cor0
----
-1545
-699
-876

query I rowsort
SELECT - col0 * - 46 FROM tab2
----
322
3588
3634

query I rowsort
SELECT cor0.col0 * - 31 - + 21 AS col1 FROM tab2 AS cor0
----
-238
-2439
-2470

query I rowsort
SELECT + + col2 * col2 - - col0 * - col0 FROM tab0 AS cor0
----
-1197
-1224
513

onlyif mysql # use DIV operator for integer division
query I rowsort label-6099
SELECT DISTINCT + cor0.col1 DIV - cor0.col0 + col1 AS col1 FROM tab0 AS cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-6099
SELECT DISTINCT + cor0.col1 / - cor0.col0 + col1 AS col1 FROM tab0 AS cor0
----
83
90
95

query I rowsort
SELECT + col2 * - ( 67 ) + col2 AS col0 FROM tab2 AS cor0
----
-1716
-1782
-2508

onlyif mysql # use DIV operator for integer division
query I rowsort label-6101
SELECT + col2 + col2 DIV ( col1 ) FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6101
SELECT + col2 + col2 / ( col1 ) FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT col0 * - ( + ( - col2 ) ) + + col1 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-6103
SELECT ALL + col2 - + col2 * col1 DIV col2 FROM tab0 AS cor0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-6103
SELECT ALL + col2 - + col2 * col1 / col2 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6104
SELECT - col1 * tab1.col1 DIV - col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6104
SELECT - col1 * tab1.col1 / - col1 FROM tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6105
SELECT + tab1.col0 DIV - col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6105
SELECT + tab1.col0 / - col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT ALL tab1.col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6107
SELECT col2 * - col0 DIV col0 AS col0 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6107
SELECT col2 * - col0 / col0 AS col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT + cor0.col2 * - col0 - col0 AS col2 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT - cor0.col0 * - cor0.col2 + + col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT col0 + col0 + - col2 FROM tab2
----
-13
120
130

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + - cor0.col2 col2 FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col1 - cor0.col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 + - col2 * col0 FROM tab1 AS cor0
----
-108
-3591
-7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col2 * - col0 col1 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-6116
SELECT - col0 * col0 DIV cor0.col0 + + col1 AS col0 FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-6116
SELECT - col0 * col0 / cor0.col0 + + col1 AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL + 43 * + col1 AS col0 FROM tab0 cor0
----
3698
3913
4171

query I rowsort
SELECT col1 + + col2 * col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + + ( + col1 ) * col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + col0 + + col0 * 71 FROM tab0 AS cor0
----
1728
2520
6408

query I rowsort
SELECT DISTINCT col2 * + col1 + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT col2 + + col1 + col0 AS col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ALL - - 52 * - col2 * + 99 FROM tab1 AS cor0
----
-277992
-293436
-494208

query I rowsort
SELECT + col2 * col2 + - col1 * col0 FROM tab2 AS cor0
----
-3926
101
512

query I rowsort
SELECT + 26 + + 63 * tab2.col0 FROM tab2
----
467
4940
5003

query I rowsort
SELECT col2 - 94 FROM tab0
----
-12
-61
-93

query I rowsort
SELECT + 83 - col2 FROM tab2
----
45
56
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6128
SELECT CAST( + col2 AS SIGNED ) + - col1 * CAST( NULL AS SIGNED ) * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6128
SELECT CAST ( + col2 AS INTEGER ) + - col1 * CAST ( NULL AS INTEGER ) * col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col1 ) col0 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT ( 39 ) AS col2 FROM tab1
----
39

query I rowsort
SELECT DISTINCT - tab2.col0 - + col0 AS col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT - col1 * col2 + - col1 AS col2 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT + col1 + + col0 * + ( + 95 ) FROM tab2
----
696
7469
7522

query I rowsort
SELECT - col0 + col0 * + col2 AS col1 FROM tab0
----
0
7209
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6135
SELECT col1 * col0 - CAST( NULL AS SIGNED ) / col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6135
SELECT col1 * col0 - CAST ( NULL AS INTEGER ) / col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 54 * col0 + + col1 + col2 FROM tab2 AS cor0
----
4297
4321
436

onlyif mysql # use DIV operator for integer division
query I rowsort label-6137
SELECT ALL 21 + - col1 DIV ( - 19 * col0 ) FROM tab0 AS cor0
----
21
21
21

skipif mysql # not compatible
query I rowsort label-6137
SELECT ALL 21 + - col1 / ( - 19 * col0 ) FROM tab0 AS cor0
----
21
21
21

query I rowsort
SELECT - col0 * ( col2 ) * col2 + col0 AS col0 FROM tab0
----
-26112
-598347
0

query I rowsort
SELECT ALL - cor1.col0 AS col1 FROM tab0 cor0 CROSS JOIN tab1, tab1 cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT - + col2 * 75 AS col0 FROM tab2 AS cor0
----
-1950
-2025
-2850

query I rowsort
SELECT + col0 + 42 * + 17 FROM tab1 AS cor0
----
717
778
794

query I rowsort
SELECT ALL + col2 + ( col1 ) * - col1 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT 32 - + cor0.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to df7cec27ecdf2969a799a636d1ff8f28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # use DIV operator for integer division
query I rowsort label-6145
SELECT DISTINCT - cor0.col2 DIV cor0.col0 FROM tab1, tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-6145
SELECT DISTINCT - cor0.col2 / cor0.col0 FROM tab1, tab2 AS cor0
----
-3
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 81 col1 FROM tab0
----
-1
48
80

query I rowsort
SELECT ALL col0 * + col0 + + col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT - 41 FROM tab1, tab1 AS cor0
----
-41

query I rowsort
SELECT 16 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT 15 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
22
93
94

query I rowsort
SELECT DISTINCT 92 * col1 FROM tab1 AS cor0
----
1196
2392
920

query I rowsort
SELECT ALL - 59 * + col1 AS col1 FROM tab2
----
-1003
-1829
-3481

query I rowsort
SELECT - col0 * + 96 FROM tab0 AS cor0
----
-2304
-3360
-8544

query I rowsort
SELECT + - col1 * + ( col1 ) + + col1 * col2 FROM tab1 AS cor0
----
1079
470
728

query I rowsort
SELECT ALL + 81 * + 29 FROM tab1 AS cor0
----
2349
2349
2349

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6156
SELECT DISTINCT + - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6156
SELECT DISTINCT + - 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-6157
SELECT DISTINCT - CAST( col0 AS SIGNED ) col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6157
SELECT DISTINCT - CAST ( col0 AS INTEGER ) col2 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6158
SELECT - - CAST( NULL AS DECIMAL ) * - cor0.col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6158
SELECT - - CAST ( NULL AS REAL ) * - cor0.col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 16 + - col1 * + col2 FROM tab0 AS cor0
----
-2822
-7446
-81

query I rowsort
SELECT DISTINCT + + 59 AS col2 FROM tab1 AS cor0
----
59

query I rowsort
SELECT + + col2 + col1 * col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL 99 * + col0 FROM tab1 AS cor0
----
297
6336
7920

query I rowsort
SELECT ALL 49 + + cor0.col2 * cor0.col2 FROM tab2 AS cor0
----
1493
725
778

query I rowsort
SELECT DISTINCT - + col2 * + col0 + 71 FROM tab2 cor0
----
-118
-1957
-2931

query I rowsort
SELECT - - 27 * col2 AS col0 FROM tab2 AS cor0
----
1026
702
729

query I rowsort
SELECT DISTINCT - + 99 + + col0 AS col0 FROM tab1 AS cor0
----
-19
-35
-96

query I rowsort
SELECT DISTINCT 88 AS col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
88

query I rowsort
SELECT 36 * + cor0.col2 + - 17 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 796f5b8a2edfdebbb5475e55b061b740

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
-7
-78
-79

query I rowsort
SELECT col0 + col0 * + col0 AS col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT 6 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
6

query I rowsort
SELECT - - col0 * cor0.col2 * col1 + cor0.col2 FROM tab2 AS cor0
----
119678
51072
5886

query I rowsort
SELECT ALL col0 * cor0.col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - col1 * - 72 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-12168
-48672
-7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-6175
SELECT - col2 * - col1 DIV - col1 + + cor0.col0 * - col2 + col0 AS col2 FROM tab1 cor0
----
-213
-3641
-7696

skipif mysql # not compatible
query I rowsort label-6175
SELECT - col2 * - col1 / - col1 + + cor0.col0 * - col2 + col0 AS col2 FROM tab1 cor0
----
-213
-3641
-7696

query I rowsort
SELECT - + cor0.col1 + + 76 AS col1 FROM tab0 AS cor0
----
-10
-15
-21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6177
SELECT ALL + CAST( NULL AS SIGNED ) col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6177
SELECT ALL + CAST ( NULL AS INTEGER ) col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-6178
SELECT DISTINCT - col0 + ( col1 ) DIV col0 AS col0 FROM tab0 AS cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-6178
SELECT DISTINCT - col0 + ( col1 ) / col0 AS col0 FROM tab0 AS cor0
----
-21
-33
-88

query I rowsort
SELECT DISTINCT tab2.col2 * 24 FROM tab2
----
624
648
912

query I rowsort
SELECT col1 + - ( 79 ) + col0 FROM tab0 AS cor0
----
101
31
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6181
SELECT DISTINCT col1 + CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6181
SELECT DISTINCT col1 + CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col1 * + 0 + col2 AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - + ( col2 ) * col1 + + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL col1 + + ( + 74 ) AS col2 FROM tab0
----
160
165
171

query I rowsort
SELECT + 35 + + col0 FROM tab1 AS cor0
----
115
38
99

query I rowsort
SELECT ALL + cor0.col2 * + col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT 6 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

query I rowsort
SELECT - + col1 * - 61 * + col1 AS col2 FROM tab1 AS cor0
----
10309
41236
6100

query I rowsort
SELECT + + cor0.col2 + + 14 * col1 * + col2 AS col1 FROM tab2 AS cor0
----
11745
21502
9082

onlyif mysql # use DIV operator for integer division
query I rowsort label-6190
SELECT DISTINCT + col0 * col0 DIV + 31 FROM tab2 AS cor0
----
1
196
201

skipif mysql # not compatible
query I rowsort label-6190
SELECT DISTINCT + col0 * col0 / + 31 FROM tab2 AS cor0
----
1
196
201

query I rowsort
SELECT cor0.col2 + + 87 + - col2 FROM tab0 AS cor0
----
87
87
87

query I rowsort
SELECT - col0 * col1 - col1 AS col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-6193
SELECT col0 DIV 36 + col0 AS col0 FROM tab2 AS cor0
----
7
80
81

skipif mysql # not compatible
query I rowsort label-6193
SELECT col0 / 36 + col0 AS col0 FROM tab2 AS cor0
----
7
80
81

query I rowsort
SELECT - + col0 + + col1 * col0 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-6195
SELECT ALL + col0 DIV + col1 + col1 FROM tab1
----
16
19
26

skipif mysql # not compatible
query I rowsort label-6195
SELECT ALL + col0 / + col1 + col1 FROM tab1
----
16
19
26

query I rowsort
SELECT DISTINCT col1 + - tab2.col0 * + 90 + col0 FROM tab2
----
-592
-6883
-7014

query I rowsort
SELECT 45 + 8 * col1 + + 12 FROM tab0 cor0
----
745
785
833

query I rowsort
SELECT + - 48 * 5 FROM tab1 AS cor0
----
-240
-240
-240

query I rowsort
SELECT DISTINCT col1 + col1 + + 63 AS col1 FROM tab1
----
115
83
89

query I rowsort
SELECT + + cor0.col1 * col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL col0 * - col1 + 28 * + 57 FROM tab2 cor0
----
-3006
1379
253

query I rowsort
SELECT 57 * - col0 * - 75 FROM tab0 AS cor0
----
102600
149625
380475

query I rowsort
SELECT ( 73 ) AS col0 FROM tab2
----
73
73
73

query I rowsort
SELECT ALL ( tab1.col2 ) + - 19 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 01af21264d7b274821b3d7e4b86fb809

query I rowsort
SELECT ( tab2.col1 + - col2 ) AS col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT + col1 - + col1 * + col0 AS col2 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT 35 FROM tab0, tab0 AS cor0
----
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-6208
SELECT col2 + col2 DIV 51 + + 5 AS col2 FROM tab2
----
31
32
43

skipif mysql # not compatible
query I rowsort label-6208
SELECT col2 + col2 / 51 + + 5 AS col2 FROM tab2
----
31
32
43

query I rowsort
SELECT DISTINCT - + ( - cor1.col1 ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
10
13
26

query I rowsort
SELECT DISTINCT + ( + col2 ) + cor0.col0 * + col2 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL + + col2 * col1 - + col1 * col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 50 * cor0.col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
1359
1381
1917

query I rowsort
SELECT DISTINCT + 94 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
94

query I rowsort
SELECT DISTINCT col2 + 67 * - col2 AS col2 FROM tab1 AS cor0
----
-3564
-3762
-6336

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 63 * col2 col2 FROM tab1
----
-3402
-3591
-6048

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * ( 88 ) col1 FROM tab2 AS cor0
----
-616
-6864
-6952

query I rowsort
SELECT + cor0.col0 * + col0 AS col1 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6218
SELECT + - cor0.col1 + - CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-6218
SELECT + - cor0.col1 + - CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + 10 * col1 * col0 FROM tab1
----
10400
6400
780

query I rowsort
SELECT + 48 * + col0 FROM tab0
----
1152
1680
4272

query I rowsort
SELECT ( - ( - col2 ) ) + col2 + - col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + + col2 * col1 + + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - col1 * col2 + + col1 + col0 col1 FROM tab2 AS cor0
----
11078
25985
90643

query I rowsort
SELECT - col0 * + 48 AS col0 FROM tab0
----
-1152
-1680
-4272

query I rowsort
SELECT DISTINCT ( 50 ) * - col2 + col1 FROM tab1 AS cor0
----
-2674
-2840
-4787

query I rowsort
SELECT col0 * col0 + col0 + 53 AS col0 FROM tab0 AS cor0
----
1313
653
8063

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6227
SELECT ALL + CAST( + cor0.col0 AS SIGNED ) * col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-6227
SELECT ALL + CAST ( + cor0.col0 AS INTEGER ) * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT 15 + + col0 FROM tab1 cor0
----
18
79
95

query I rowsort
SELECT - - col0 + + col0 * 13 FROM tab1 cor0
----
1120
42
896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 * col1 col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT + 95 AS col2 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT col1 * col1 FROM tab2 WHERE NOT NULL BETWEEN - tab2.col0 AND NULL
----

query I rowsort
SELECT col0 * tab1.col2 + tab1.col2 * + col0 + + col2 * + tab1.col2 * - col1 FROM tab1
----
-104448
-25194
-75492

query III rowsort
SELECT * FROM tab1 WHERE ( col2 ) NOT IN ( col0 + col0 + - tab1.col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL col0 * - col1 + + col2 AS col2 FROM tab0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-6236
SELECT - col2 + col2 DIV + col0 FROM tab1
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-6236
SELECT - col2 + col2 / + col0 FROM tab1
----
-36
-57
-95

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL BETWEEN col2 AND NULL
----

query I rowsort
SELECT DISTINCT col1 + col1 * col0 * col2 AS col1 FROM tab0
----
3492
664209
68198

query I rowsort
SELECT col2 + - col2 * - col2 * col0 AS col0 FROM tab0
----
26169
36
598518

query I rowsort
SELECT DISTINCT col2 * + col2 + col1 AS col0 FROM tab0
----
1175
6815
98

query I rowsort
SELECT + col1 + col0 + col1 * - col1 FROM tab2
----
-193
-3344
-923

query I rowsort
SELECT ALL + 34 * - col1 * cor0.col2 + col2 FROM tab0 AS cor0
----
-253626
-3297
-96459

query I rowsort
SELECT + cor1.col0 + - 73 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to ef67024592152784fdabea246b6a66d5

query I rowsort
SELECT 72 + - col1 FROM tab0 cor0
----
-14
-19
-25

query I rowsort
SELECT DISTINCT - col2 * - col0 + - col2 FROM tab2
----
162
2002
2964

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NULL ) IN ( col2 )
----

query I rowsort
SELECT tab2.col2 + col0 * - col1 + - col1 FROM tab2
----
-1322
-221
-4635

query I rowsort
SELECT - col1 * - tab1.col0 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT + col0 + + col1 * + col0 + + col0 AS col0 FROM tab1
----
1200
768
84

query I rowsort
SELECT tab2.col2 * + tab2.col2 FROM tab1, tab0 AS cor0 JOIN tab2 ON NOT NULL >= NULL
----

query I rowsort
SELECT ALL col2 - col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col1 * col0 - col0 AS col2 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-6253
SELECT ALL col2 DIV col1 + - col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-6253
SELECT ALL col2 / col1 + - col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + tab2.col1 * tab2.col1 * col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT - tab0.col2 AS col0 FROM tab0 WHERE ( NULL ) IN ( - col2 + col1 )
----

query I rowsort
SELECT ALL tab1.col2 * col2 + col0 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT col1 * - col2 AS col1 FROM tab1 WHERE NOT ( NULL ) NOT IN ( + col2 )
----

query I rowsort
SELECT col1 * - tab2.col2 + - col1 * + col1 FROM tab2
----
-1798
-5015
-935

query I rowsort
SELECT col0 * col0 + col0 AS col1 FROM tab2
----
56
6162
6320

query I rowsort
SELECT ALL col1 + col2 * col2 FROM tab0
----
1175
6815
98

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN ( - col1 * col1 ) AND NULL
----

query I rowsort
SELECT DISTINCT + col1 * - tab0.col2 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - cor0.col2 + + cor0.col0 FROM tab1, tab1 cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - col2 * 9 + col2 * col1 FROM tab0
----
2541
6724
88

query I rowsort
SELECT - col2 + 12 + col1 FROM tab2 AS cor0
----
-9
16
45

query I rowsort
SELECT DISTINCT + col1 * 58 FROM tab1 AS cor0
----
1508
580
754

query I rowsort
SELECT ALL - ( 81 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to d0bfe8494f52235d9fcafb5ac5de3f81

query I rowsort
SELECT - 77 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

query I rowsort
SELECT ALL - - cor0.col2 + - col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT col0 * - col0 - + col1 AS col0 FROM tab0 cor0
----
-1322
-662
-8012

query I rowsort
SELECT col2 + 79 * tab2.col2 FROM tab2
----
2080
2160
3040

query I rowsort
SELECT DISTINCT + + col0 - col0 * col0 AS col0 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT - - col0 + - col0 * - col2 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT ALL 49 AS col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

onlyif mysql # use DIV operator for integer division
query I rowsort label-6275
SELECT tab0.col1 + + col0 DIV col0 AS col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-6275
SELECT tab0.col1 + + col0 / col0 AS col1 FROM tab0
----
87
92
98

query I rowsort
SELECT + 86 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT ALL - 32 + - col1 AS col1 FROM tab1
----
-42
-45
-58

query I rowsort
SELECT + 53 + col1 AS col2 FROM tab0 AS cor0
----
139
144
150

query I rowsort
SELECT ( + col1 ) * col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6280
SELECT + - col1 + + cor0.col2 DIV - ( + cor0.col2 ) FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-6280
SELECT + - col1 + + cor0.col2 / - ( + cor0.col2 ) FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT - - col2 - col0 * ( col1 ) AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT col0 + ( - 14 ) * - col2 AS col2 FROM tab1 AS cor0
----
1424
759
862

query I rowsort
SELECT ALL + col0 * + ( - 17 ) + col2 AS col0 FROM tab1 AS cor0
----
-1031
-1264
3

query I rowsort
SELECT DISTINCT - cor0.col1 * + 50 AS col1 FROM tab1 AS cor0
----
-1300
-500
-650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6285
SELECT DISTINCT + col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6285
SELECT DISTINCT + col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6286
SELECT ALL + + col1 - col1 DIV col0 FROM tab0 cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-6286
SELECT ALL + + col1 - col1 / col0 FROM tab0 cor0
----
83
90
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col2 - col2 col1 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-6288
SELECT DISTINCT - col2 DIV ( col1 ) - + col2 FROM tab1 AS cor0
----
-103
-56
-62

skipif mysql # not compatible
query I rowsort label-6288
SELECT DISTINCT - col2 / ( col1 ) - + col2 FROM tab1 AS cor0
----
-103
-56
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6289
SELECT ALL - - col1 - - CAST( NULL AS SIGNED ) * col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6289
SELECT ALL - - col1 - - CAST ( NULL AS INTEGER ) * col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6290
SELECT - + col1 DIV CAST( col0 AS SIGNED ) + col1 AS col1 FROM tab1 AS cor0
----
10
13
18

skipif mysql # not compatible
query I rowsort label-6290
SELECT - + col1 / CAST ( col0 AS INTEGER ) + col1 AS col1 FROM tab1 AS cor0
----
10
13
18

query I rowsort
SELECT DISTINCT + + col0 + col0 * - col1 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT col2 * + col2 * 28 + col0 AS col0 FROM tab1
----
258128
81651
91036

query I rowsort
SELECT DISTINCT tab0.col1 - col2 FROM tab0
----
53
9
96

query I rowsort
SELECT ALL + 52 - - col0 AS col0 FROM tab1
----
116
132
55

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 + 35 FROM tab1, tab2 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT - 52 * + tab0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 3842ea716f23ab292cd03a9210c338fd

query I rowsort
SELECT ALL + 67 * + 88 + col0 * ( col1 ) AS col1 FROM tab1 cor0
----
5974
6536
6936

query I rowsort
SELECT - + ( cor0.col1 ) * - cor0.col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT - + ( - cor0.col2 ) - - col1 * + 36 AS col0 FROM tab2 AS cor0
----
1143
2150
650

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 AS cor2
----
3645 values hashing to b223aa53e3aafe0f3f3f59048cc7a0d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6302
SELECT + col0 DIV col1 + + 18 AS col2 FROM tab0 AS cor0
----
18
18
18

skipif mysql # not compatible
query I rowsort label-6302
SELECT + col0 / col1 + + 18 AS col2 FROM tab0 AS cor0
----
18
18
18

query I rowsort
SELECT - 38 * col0 + - col0 AS col2 FROM tab2 cor0
----
-273
-3042
-3081

query I rowsort
SELECT - - col2 * - cor0.col0 + + col1 AS col1 FROM tab0 AS cor0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * - 6 + + col1 col1 FROM tab1 AS cor0
----
350
352
589

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6306
SELECT + col0 * + CAST( NULL AS SIGNED ) + + 30 / - cor0.col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6306
SELECT + col0 * + CAST ( NULL AS INTEGER ) + + 30 / - cor0.col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 55 AS col2 FROM tab2, tab1 AS cor0
----
-55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6308
SELECT col1 * CAST( NULL AS SIGNED ) + - cor0.col2 + - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6308
SELECT col1 * CAST ( NULL AS INTEGER ) + - cor0.col2 + - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + cor0.col0 + cor0.col0 AS col2 FROM tab2 cor0
----
182
196
41

query I rowsort
SELECT ALL + col0 * 29 FROM tab2 AS cor0
----
203
2262
2291

query I rowsort
SELECT - col2 + + 50 * col0 FROM tab0 AS cor0
----
1167
1749
4368

query I rowsort
SELECT DISTINCT - col0 * 26 FROM tab1
----
-1664
-2080
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 * col0 + ( + col1 ) col0 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT 47 FROM tab1, tab1 AS cor0
----
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6315
SELECT DISTINCT + tab0.col1 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6315
SELECT DISTINCT + tab0.col1 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT col2 * col2 * - 32 FROM tab2
----
-21632
-23328
-46208

query I rowsort
SELECT - col1 * - 73 + + col2 AS col0 FROM tab0 AS cor0
----
6311
6725
7082

onlyif mysql # use DIV operator for integer division
query I rowsort label-6318
SELECT - col2 + - col0 DIV cor0.col1 AS col1 FROM tab1 AS cor0
----
-102
-54
-63

skipif mysql # not compatible
query I rowsort label-6318
SELECT - col2 + - col0 / cor0.col1 AS col1 FROM tab1 AS cor0
----
-102
-54
-63

query I rowsort
SELECT - ( 40 ) + - col0 * 55 FROM tab1 AS cor0
----
-205
-3560
-4440

query I rowsort
SELECT ALL 97 + + col1 AS col2 FROM tab0 AS cor0
----
183
188
194

query I rowsort
SELECT + 45 FROM tab2, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT ALL - 87 + - cor0.col1 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 620dff5820a669fbfdef113295c09284

query I rowsort
SELECT + 52 * + cor0.col1 FROM tab2 AS cor0
----
1612
3068
884

query I rowsort
SELECT ALL cor1.col1 * 70 + + ( cor1.col2 ) AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to f79e18abd99d05a3b2f5a7fd4f49165f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6325
SELECT - 32 DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6325
SELECT - 32 / + col2 FROM tab1 AS cor0
----
0
0
0

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab2 cor1, tab0, tab2 cor2
----
3645 values hashing to fcae6e4467f798ac88c869b8e38c6b23

query I rowsort
SELECT DISTINCT + + col0 * col1 + + cor0.col1 * + col0 AS col0 FROM tab0 AS cor0
----
16198
4128
6790

query I rowsort
SELECT ALL - 73 * + col2 FROM tab1 cor0
----
-3942
-4161
-7008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6329
SELECT col1 * + col1 / + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6329
SELECT col1 * + col1 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 - 28 FROM tab0
----
-4
61
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6331
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + tab2.col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6331
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + tab2.col0 FROM tab2
----
NULL

query I rowsort
SELECT ALL - 71 + + col2 + 22 AS col0 FROM tab1
----
47
5
8

query I rowsort
SELECT + - cor0.col0 + - cor0.col0 * - 89 FROM tab2 cor0
----
616
6864
6952

query I rowsort
SELECT - + cor0.col0 + - col1 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ( col0 ) * - ( + 38 ) AS col1 FROM tab0
----
-1330
-3382
-912

query I rowsort
SELECT - 5 AS col1 FROM tab1 cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - 76 col1 FROM tab2 AS cor0
----
-69
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 + col1 * - col1 col0 FROM tab0 cor0
----
-10634
-16202
-7972

query I rowsort
SELECT - cor0.col1 + cor0.col0 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 + - col0 + + col2 col1 FROM tab2
----
-26
-3
47

query I rowsort
SELECT - ( col1 ) * 88 + tab2.col0 FROM tab2
----
-1417
-2721
-5114

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col0 col0 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL - col0 + tab0.col0 FROM tab0
----
0
0
0

query I rowsort
SELECT 96 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

query I rowsort
SELECT ALL - col0 * col0 + 86 FROM tab2
----
-5998
-6155
37

query I rowsort
SELECT 74 + - col2 FROM tab1
----
-22
17
20

query I rowsort
SELECT ALL + col1 + tab0.col1 * col1 * - 37 AS col1 FROM tab0
----
-273566
-306306
-348036

query I rowsort
SELECT ALL 83 * col1 + + col1 FROM tab0
----
7224
7644
8148

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 35 + - col1 - 75 col1 FROM tab1 cor0
----
-50
-53
-66

query I rowsort
SELECT - col0 + col1 + cor0.col2 * + col0 AS col2 FROM tab1 AS cor0
----
185
3594
7613

query I rowsort
SELECT + 17 * + col1 + 83 * - 82 + + col0 * col0 FROM tab1 AS cor0
----
-185
-2540
-6355

onlyif mysql # use DIV operator for integer division
query I rowsort label-6352
SELECT col0 DIV col2 + 87 FROM tab1 AS cor0
----
87
87
88

skipif mysql # not compatible
query I rowsort label-6352
SELECT col0 / col2 + 87 FROM tab1 AS cor0
----
87
87
88

query I rowsort
SELECT + col1 + - col0 AS col0 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT ALL - col2 + + ( + col2 + col1 ) * 38 AS col1 FROM tab2 AS cor0
----
2052
2177
3204

query I rowsort
SELECT col0 * 13 FROM tab0 cor0
----
1157
312
455

onlyif mysql # use DIV operator for integer division
query I rowsort label-6356
SELECT ALL - col1 DIV + 76 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6356
SELECT ALL - col1 / + 76 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col2 + 68 * - col0 AS col0 FROM tab0 AS cor0
----
-1599
-2379
-5970

query I rowsort
SELECT ALL col1 + 17 FROM tab0 AS cor0
----
103
108
114

onlyif mysql # use DIV operator for integer division
query I rowsort label-6359
SELECT ALL - col2 + + col0 * col2 DIV - col0 + - col0 FROM tab2 AS cor0
----
-130
-155
-61

skipif mysql # not compatible
query I rowsort label-6359
SELECT ALL - col2 + + col0 * col2 / - col0 + - col0 FROM tab2 AS cor0
----
-130
-155
-61

query I rowsort
SELECT ALL col2 * 8 + - col0 - col1 AS col2 FROM tab0 AS cor0
----
-124
154
476

query I rowsort
SELECT DISTINCT + col1 * + 48 AS col0 FROM tab0 AS cor0
----
4128
4368
4656

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6362
SELECT ALL + col0 + CAST( NULL AS SIGNED ) * col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6362
SELECT ALL + col0 + CAST ( NULL AS INTEGER ) * col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + 71 * 63 FROM tab2 AS cor0
----
4490
4504
4532

query I rowsort
SELECT DISTINCT col2 + + 12 * 51 - - col1 * + col2 FROM tab0 AS cor0
----
3483
710
8156

query I rowsort
SELECT ALL ( col0 ) + + tab0.col2 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL tab2.col1 * col2 + + 0 AS col2 FROM tab2
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6367
SELECT - col0 + 97 DIV col1 AS col2 FROM tab0 cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-6367
SELECT - col0 + 97 / col1 AS col2 FROM tab0 cor0
----
-23
-34
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6368
SELECT DISTINCT + + col2 DIV - col0 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6368
SELECT DISTINCT + + col2 / - col0 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT + col2 + col0 * + col2 AS col2 FROM tab0 cor0
----
36
7380
825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6370
SELECT ALL + + col2 + CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6370
SELECT ALL + + col2 + CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 2 * + col2 AS col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT + - 44 * 97 AS col2 FROM tab1 AS cor0
----
-4268

query I rowsort
SELECT ALL + col0 + - 81 FROM tab1 cor0
----
-1
-17
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6374
SELECT - CAST( NULL AS DECIMAL ) + col1 + - col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6374
SELECT - CAST ( NULL AS REAL ) + col1 + - col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * 45 * col0 AS col0 FROM tab2
----
207090
60435
9765

query I rowsort
SELECT ALL - - col1 * col1 AS col1 FROM tab1 cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6377
SELECT + - col2 DIV + col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-6377
SELECT + - col2 / + col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT ALL - 27 * col0 FROM tab2 AS cor0
----
-189
-2106
-2133

query I rowsort
SELECT DISTINCT - - 37 * 2 FROM tab1 AS cor0
----
74

query I rowsort
SELECT - 50 * + cor0.col2 + + col2 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT DISTINCT 42 AS col2 FROM tab1 cor0
----
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-6382
SELECT ALL + 74 DIV - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6382
SELECT ALL + 74 / - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - col0 + - 62 AS col1 FROM tab2
----
-140
-141
-69

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 cor0 CROSS JOIN tab2, tab2 AS cor1
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT 97 - - col2 AS col1 FROM tab2
----
123
124
135

query I rowsort
SELECT ALL - cor0.col2 + col1 * 55 * + cor0.col0 + + col0 FROM tab0 AS cor0
----
113511
186759
445452

query I rowsort
SELECT - 65 * + col0 * - col0 AS col1 FROM tab1 AS cor0
----
266240
416000
585

query I rowsort
SELECT - - cor0.col0 * cor0.col2 + 2 + col2 AS col2 FROM tab1 AS cor0
----
218
3707
7778

query I rowsort
SELECT col1 + + col0 * - ( + 77 ) + - col2 FROM tab0 AS cor0
----
-1795
-2599
-6844

query I rowsort
SELECT ALL + - col2 * col0 + + ( 64 ) + col2 FROM tab0 AS cor0
----
-695
-7152
30

query I rowsort
SELECT DISTINCT - + col1 * + col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6393
SELECT ALL - col1 + col1 DIV - col2 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-6393
SELECT ALL - col1 + col1 / - col2 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col0 + - tab1.col1 col1 FROM tab1
----
-17
25
3

query I rowsort
SELECT ALL - col2 + - col2 - + tab0.col0 * - 72 FROM tab0
----
1662
2518
6244

query I rowsort
SELECT + 0 * - col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - 64 - - col0 * + col2 FROM tab2 cor0
----
2092
253
3066

query I rowsort
SELECT - - col0 + + col0 * + ( 7 ) * cor0.col1 FROM tab0 AS cor0
----
14472
23800
56782

query I rowsort
SELECT - + col2 + + col2 * col2 + ( + col2 ) * - col2 AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT 5 FROM tab2 AS cor0
----
5

query I rowsort
SELECT - - col2 * col1 + ( col2 ) + - col1 * + ( 76 * col2 ) AS col0 FROM tab1 AS cor0
----
-105246
-42693
-93504

query I rowsort
SELECT DISTINCT + 14 + cor0.col2 AS col0 FROM tab0 AS cor0
----
15
47
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 18 + col0 col2 FROM tab1 AS cor0
----
21
82
98

query I rowsort
SELECT - ( - 92 ) AS col0 FROM tab0 AS cor0
----
92
92
92

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 82e15d5967b272804e574774895a0222

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) * col1 + col1 col2 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col2 ) + - tab1.col0 col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT 28 FROM tab0, tab1, tab0 cor0
----
28

query I rowsort
SELECT DISTINCT 17 FROM tab2, tab1 AS cor0
----
17

query I rowsort
SELECT ALL + ( + col2 ) * col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ( 98 ) * col1 + + 94 AS col1 FROM tab0 AS cor0
----
8522
9012
9600

onlyif mysql # use DIV operator for integer division
query I rowsort label-6412
SELECT - col1 DIV - ( - cor0.col0 ) AS col2 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6412
SELECT - col1 / - ( - cor0.col0 ) AS col2 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT 25 * 34 FROM tab0 AS cor0
----
850

query I rowsort
SELECT + - 52 + cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5efcfa86b2d5548e037d8b8e9a282fcb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col0 col2 FROM tab1, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL 23 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT ALL - col2 * - ( - 53 * - col0 ) FROM tab0
----
1855
386794
41976

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 12 col1 FROM tab0, tab1 AS cor0
----
-12

query I rowsort
SELECT DISTINCT - - cor0.col2 * + ( - 42 ) + cor0.col2 FROM tab0 AS cor0
----
-1353
-3362
-41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6420
SELECT CAST( NULL AS SIGNED ) * col2 + - col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6420
SELECT CAST ( NULL AS INTEGER ) * col2 + - col2 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * tab1.col0 + - tab1.col0 AS col0 FROM tab1
----
576
75
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 5 col1 FROM tab2
----
5
5
5

query I rowsort
SELECT DISTINCT col2 * + col0 + - col1 FROM tab0
----
-62
706
7207

query I rowsort
SELECT col0 + + 81 FROM tab2 cor0
----
159
160
88

query I rowsort
SELECT DISTINCT + + col0 * - col2 + col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-6426
SELECT - cor0.col1 DIV col2 + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6426
SELECT - cor0.col1 / col2 + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + 15 + + col2 * cor0.col1 + - col2 AS col1 FROM tab2 AS cor0
----
1523
623
825

query I rowsort
SELECT ALL - 4 * col2 + + col2 AS col1 FROM tab0 AS cor0
----
-246
-3
-99

query I rowsort
SELECT DISTINCT + ( + col1 ) * col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT 20 + col2 * 77 AS col2 FROM tab0 AS cor0
----
2561
6334
97

query I rowsort
SELECT ALL - col0 + col2 * col2 + col2 AS col1 FROM tab2 AS cor0
----
1403
624
749

query I rowsort
SELECT DISTINCT - ( col0 ) * + 53 FROM tab2 cor0
----
-371
-4134
-4187

query I rowsort
SELECT ALL - col1 * col0 * col2 + + col1 FROM tab1
----
-36470
-4186
-99827

query I rowsort
SELECT DISTINCT col0 + 46 FROM tab2
----
124
125
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-6435
SELECT ALL + 91 + col2 DIV 71 AS col1 FROM tab1
----
91
91
92

skipif mysql # not compatible
query I rowsort label-6435
SELECT ALL + 91 + col2 / 71 AS col1 FROM tab1
----
91
91
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6436
SELECT + 3 * 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-6436
SELECT + 3 * col0 + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 4 col1 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

query I rowsort
SELECT - col2 - - col1 AS col0 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT col2 + col1 + - col0 AS col1 FROM tab0 AS cor0
----
63
84
95

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 ALL - col2 + - col1 + col0 FROM tab0 cor0
----
-63
-84
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6442
SELECT DISTINCT - col0 * col2 DIV cor0.col1 + col2 FROM tab1 AS cor0
----
-307
-494
48

skipif mysql # not compatible
query I rowsort label-6442
SELECT DISTINCT - col0 * col2 / cor0.col1 + col2 FROM tab1 AS cor0
----
-307
-494
48

query I rowsort
SELECT ALL - col0 * + 31 + 66 AS col1 FROM tab0 AS cor0
----
-1019
-2693
-678

query I rowsort
SELECT ALL + cor0.col1 - 6 AS col2 FROM tab2 AS cor0
----
11
25
53

query I rowsort
SELECT + ( 40 ) + col0 * - col1 FROM tab2 AS cor0
----
-1303
-177
-4562

query I rowsort
SELECT 57 + + col1 AS col1 FROM tab0 cor0
----
143
148
154

query I rowsort
SELECT - + col1 * - col0 + + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - 61 + cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
1383
615
668

query I rowsort
SELECT + cor0.col0 - 79 FROM tab2, tab2 AS cor0
----
9 values hashing to b729ca2055453125f9340c954ea7ec3c

query I rowsort
SELECT + 50 * - col1 FROM tab0 cor0
----
-4300
-4550
-4850

query I rowsort
SELECT tab1.col2 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6452
SELECT DISTINCT + col0 DIV + tab1.col0 AS col1 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-6452
SELECT DISTINCT + col0 / + tab1.col0 AS col1 FROM tab1
----
1

query I rowsort
SELECT ( ( col2 ) ) AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT 9 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

query I rowsort
SELECT ALL - 72 AS col2 FROM tab1 cor0
----
-72
-72
-72

query I rowsort
SELECT + col1 + col1 - 13 FROM tab0
----
159
169
181

query I rowsort
SELECT ALL - col2 - + col1 * + col0 * col2 AS col0 FROM tab2
----
-119678
-51072
-5886

query I rowsort
SELECT ALL + tab2.col0 - col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT + - ( + 25 ) * - col1 + + col2 AS col0 FROM tab2 AS cor0
----
1501
463
802

onlyif mysql # use DIV operator for integer division
query I rowsort label-6460
SELECT DISTINCT + + col0 DIV - cor0.col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-6460
SELECT DISTINCT + + col0 / - cor0.col0 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - col0 * 56 - - col1 FROM tab2 cor0
----
-361
-4309
-4407

query I rowsort
SELECT col2 + ( - cor0.col2 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 * col1 + - 84 FROM tab2
----
1259
133
4518

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6464
SELECT ALL tab0.col2 + CAST( NULL AS DECIMAL ) * 46 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6464
SELECT ALL tab0.col2 + CAST ( NULL AS REAL ) * 46 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col0 + + col0 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 + - cor0.col1 FROM tab2 cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6467
SELECT ALL - CAST( - col0 AS SIGNED ) * - col2 / - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6467
SELECT ALL - CAST ( - col0 AS INTEGER ) * - col2 / - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab0 cor1
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

onlyif mysql # use DIV operator for integer division
query I rowsort label-6469
SELECT DISTINCT - - col0 DIV + col0 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-6469
SELECT DISTINCT - - col0 / + col0 FROM tab2 AS cor0
----
1

query I rowsort
SELECT DISTINCT col2 * - 51 FROM tab0 AS cor0
----
-1683
-4182
-51

query I rowsort
SELECT ALL + ( - 31 ) + + col2 AS col0 FROM tab0 AS cor0
----
-30
2
51

query I rowsort
SELECT ALL col0 * col0 - col0 * col0 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
19584
2450
657443

query I rowsort
SELECT DISTINCT - 10 * + col2 FROM tab2 AS cor0
----
-260
-270
-380

query I rowsort
SELECT ALL + col0 * + 94 + + cor0.col1 FROM tab2 AS cor0
----
689
7391
7443

query I rowsort
SELECT DISTINCT + - ( col1 ) + col1 AS col1 FROM tab2 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6476
SELECT + 4 * - col0 + + cor0.col0 / CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6476
SELECT + 4 * - col0 + + cor0.col0 / CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + 66 AS col2 FROM tab1 AS cor0
----
-14
2
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col2 ) * - cor0.col0 col1 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col1 + - col0 + col1 * col1 col1 FROM tab2 cor0
----
1915
499
6884

query I rowsort
SELECT - + col1 - ( + col2 ) * + col0 FROM tab2 AS cor0
----
-2087
-220
-3019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6481
SELECT ALL - col0 + + CAST( + col1 AS SIGNED ) * col0 AS col2 FROM tab0 AS cor0
----
2040
3360
8010

skipif mysql # not compatible
query I rowsort label-6481
SELECT ALL - col0 + + CAST ( + col1 AS INTEGER ) * col0 AS col2 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + - col2 + + cor0.col2 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT - col0 + col0 * 9 AS col1 FROM tab1 AS cor0
----
24
512
640

query I rowsort
SELECT - col0 - col1 * 71 FROM tab0 AS cor0
----
-6130
-6550
-6922

query I rowsort
SELECT DISTINCT cor0.col1 + + col0 * col1 - - col0 FROM tab2 AS cor0
----
1439
255
4739

query I rowsort
SELECT DISTINCT + - cor0.col2 * 62 * - ( col1 ) + 27 + col2 AS col0 FROM tab1 AS cor0
----
35424
77499
87129

query I rowsort
SELECT ALL + + col0 - + cor0.col1 AS col2 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT + col2 * 24 FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT ALL col2 + 89 AS col2 FROM tab2 AS cor0
----
115
116
127

query I rowsort
SELECT ALL + col2 * 23 AS col1 FROM tab1 cor0
----
1242
1311
2208

query I rowsort
SELECT + + col1 + - 11 * 51 AS col1 FROM tab1 AS cor0
----
-535
-548
-551

query I rowsort
SELECT tab1.col2 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + - col1 * ( 60 * col2 ) AS col0 FROM tab1 AS cor0
----
-34200
-74880
-84240

query I rowsort
SELECT + + col0 + 18 AS col2 FROM tab2 cor0
----
25
96
97

query I rowsort
SELECT + cor0.col1 * 98 AS col1 FROM tab0 AS cor0
----
8428
8918
9506

query I rowsort
SELECT + col0 - + 85 FROM tab0 AS cor0
----
-50
-61
4

query I rowsort
SELECT ALL col1 + 47 * + col2 FROM tab2 AS cor0
----
1281
1300
1803

query I rowsort
SELECT + cor0.col2 * 35 - col2 FROM tab2 AS cor0
----
1292
884
918

onlyif mysql # use DIV operator for integer division
query I rowsort label-6499
SELECT DISTINCT - col0 DIV + col2 + + col2 AS col0 FROM tab1
----
54
56
96

skipif mysql # not compatible
query I rowsort label-6499
SELECT DISTINCT - col0 / + col2 + + col2 AS col0 FROM tab1
----
54
56
96

query I rowsort
SELECT - 18 * + col1 FROM tab0 cor0
----
-1548
-1638
-1746

onlyif mysql # use DIV operator for integer division
query I rowsort label-6501
SELECT + + 41 DIV - col0 + + ( cor0.col0 ) col1 FROM tab1 AS cor0
----
-10
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6501
SELECT + + 41 / - col0 + + ( cor0.col0 ) col1 FROM tab1 AS cor0
----
-10
64
80

query I rowsort
SELECT ALL - 7 * col0 AS col1 FROM tab1 cor0
----
-21
-448
-560

query I rowsort
SELECT DISTINCT - col0 + + col2 * + col2 AS col0 FROM tab2
----
1365
598
722

query I rowsort
SELECT ALL 90 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT DISTINCT 16 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
16

query I rowsort
SELECT ALL + col0 + col1 AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL 9 * col0 + - 94 * col2 FROM tab0 AS cor0
----
-2886
-6907
221

query I rowsort
SELECT 74 * + col2 + col2 AS col1 FROM tab1
----
4050
4275
7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-6509
SELECT ALL ( + col2 ) DIV - 13 AS col1 FROM tab0
----
-2
-6
0

skipif mysql # not compatible
query I rowsort label-6509
SELECT ALL ( + col2 ) / - 13 AS col1 FROM tab0
----
-2
-6
0

query I rowsort
SELECT DISTINCT col0 * + col0 * + col1 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT - - cor0.col0 + + col2 * col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT col1 + + col1 * - col2 * col0 FROM tab2 cor0
----
-119593
-51017
-5828

query I rowsort
SELECT ALL - 66 * + col1 * + col0 FROM tab0
----
-136224
-224070
-534534

query I rowsort
SELECT ( - 94 ) FROM tab0
----
-94
-94
-94

query I rowsort
SELECT + 3 * + tab0.col2 FROM tab0
----
246
3
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6516
SELECT ALL - 96 * - 11 * col0 + CAST( col0 AS SIGNED ) FROM tab2
----
7399
82446
83503

skipif mysql # not compatible
query I rowsort label-6516
SELECT ALL - 96 * - 11 * col0 + CAST ( col0 AS INTEGER ) FROM tab2
----
7399
82446
83503

onlyif mysql # use DIV operator for integer division
query I rowsort label-6517
SELECT + col0 * col0 + 65 DIV - col1 FROM tab1 AS cor0
----
4090
6395
7

skipif mysql # not compatible
query I rowsort label-6517
SELECT + col0 * col0 + 65 / - col1 FROM tab1 AS cor0
----
4090
6395
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6518
SELECT + col1 + - col0 DIV col0 AS col2 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-6518
SELECT + col1 + - col0 / col0 AS col2 FROM tab2 AS cor0
----
16
30
58

query I rowsort
SELECT DISTINCT 70 FROM tab2, tab0 cor0, tab1 AS cor1
----
70

query I rowsort
SELECT - 57 * - col1 FROM tab0
----
4902
5187
5529

onlyif mysql # use DIV operator for integer division
query I rowsort label-6521
SELECT + 30 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6521
SELECT + 30 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 6 - + 52 * + col1 AS col0 FROM tab1 AS cor0
----
-1346
-514
-670

query I rowsort
SELECT + + ( + 21 ) * col2 + col0 * cor0.col0 FROM tab1 cor0
----
1143
5293
8416

query I rowsort
SELECT + ( col1 ) + - cor0.col2 * col2 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT DISTINCT - ( - 94 ) FROM tab0
----
94

query I rowsort
SELECT ALL - 76 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT ALL 1 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6528
SELECT DISTINCT - CAST( ( - col0 ) AS SIGNED ) * - 38 FROM tab0
----
-1330
-3382
-912

skipif mysql # not compatible
query I rowsort label-6528
SELECT DISTINCT - CAST ( ( - col0 ) AS INTEGER ) * - 38 FROM tab0
----
-1330
-3382
-912

query I rowsort
SELECT - 11 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

query I rowsort
SELECT - col2 * tab1.col0 * - col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT + + 14 * col2 + col1 * + col2 + col0 FROM tab2 cor0
----
1222
1257
1976

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6532
SELECT + CAST( NULL AS SIGNED ) * col0 * col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6532
SELECT + CAST ( NULL AS INTEGER ) * col0 * col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 62 FROM tab2, tab0 cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 98946dcadb23f354040593c91d9c8559

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor2.col1 col1 FROM tab0, tab0 AS cor0, tab1 cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT ALL ( + 42 ) AS col2 FROM tab1
----
42
42
42

query I rowsort
SELECT - col2 * col2 - - 88 * - col0 AS col0 FROM tab0 AS cor0
----
-14556
-3081
-3201

onlyif mysql # use DIV operator for integer division
query I rowsort label-6537
SELECT DISTINCT - - 81 * col0 + - col1 DIV col1 FROM tab1 AS cor0
----
242
5183
6479

skipif mysql # not compatible
query I rowsort label-6537
SELECT DISTINCT - - 81 * col0 + - col1 / col1 FROM tab1 AS cor0
----
242
5183
6479

query I rowsort
SELECT ALL + - cor0.col0 - col1 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT + - 57 + + col1 AS col1 FROM tab1 AS cor0
----
-31
-44
-47

query I rowsort
SELECT ALL - col1 * + col1 + + tab0.col2 AS col2 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT + 71 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
71

query I rowsort
SELECT ALL col0 * + col1 + + col0 AS col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT + 90 + col2 FROM tab1
----
144
147
186

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6544
SELECT col2 / - cor0.col1 - CAST( NULL AS SIGNED ) / col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6544
SELECT col2 / - cor0.col1 - CAST ( NULL AS INTEGER ) / col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6545
SELECT DISTINCT 81 + + cor0.col0 DIV col2 + - col0 FROM tab1 AS cor0
----
1
18
78

skipif mysql # not compatible
query I rowsort label-6545
SELECT DISTINCT 81 + + cor0.col0 / col2 + - col0 FROM tab1 AS cor0
----
1
18
78

query I rowsort
SELECT - col1 * - col1 - + col2 AS col0 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT 34 + + col2 * - ( - col2 ) + + cor0.col0 FROM tab2 cor0
----
1557
770
788

onlyif mysql # use DIV operator for integer division
query I rowsort label-6548
SELECT col0 + + col0 + + col0 DIV col0 FROM tab2 cor0
----
15
157
159

skipif mysql # not compatible
query I rowsort label-6548
SELECT col0 + + col0 + + col0 / col0 FROM tab2 cor0
----
15
157
159

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 * + ( 42 + - col2 ) col0 FROM tab0
----
-3280
297
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 58 ) col2 FROM tab2, tab2 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT col2 * col1 + - ( - col1 ) * ( col0 ) FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT + - col1 * 9 * 44 AS col1 FROM tab2 AS cor0
----
-12276
-23364
-6732

query I rowsort
SELECT - col1 + ( ( col2 ) ) * col0 AS col2 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6554
SELECT + CAST( NULL AS DECIMAL ) + ( col0 ) * + col2 * + col1 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6554
SELECT + CAST ( NULL AS REAL ) + ( col0 ) * + col2 * + col1 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6555
SELECT + - CAST( NULL AS SIGNED ) + + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6555
SELECT + - CAST ( NULL AS INTEGER ) + + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6556
SELECT + CAST( col0 AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-6556
SELECT + CAST ( col0 AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 18 col2 FROM tab0 AS cor0
----
1476
18
594

query I rowsort
SELECT 49 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT ALL col1 * 34 FROM tab2
----
1054
2006
578

query I rowsort
SELECT DISTINCT - ( + 14 ) * col0 + ( - col0 ) FROM tab0 AS cor0
----
-1335
-360
-525

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 46 + + cor0.col1 col0 FROM tab0 AS cor0
----
132
137
143

query I rowsort
SELECT DISTINCT + 60 * + ( + col1 ) AS col0 FROM tab1 AS cor0
----
1560
600
780

query I rowsort
SELECT ALL - 64 + ( cor0.col2 + cor0.col2 ) AS col1 FROM tab0 cor0
----
-62
100
2

query I rowsort
SELECT ALL + 63 * - col1 AS col0 FROM tab0 AS cor0
----
-5418
-5733
-6111

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NULL < col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col2 col2 FROM tab2 cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6567
SELECT DISTINCT - col2 * cor0.col0 DIV + cor0.col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-6567
SELECT DISTINCT - col2 * cor0.col0 / + cor0.col0 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6568
SELECT DISTINCT + col0 * + col0 DIV col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6568
SELECT DISTINCT + col0 * + col0 / col0 FROM tab1
----
3
64
80

query I rowsort
SELECT col0 * + col0 + col1 FROM tab1
----
35
4106
6413

query I rowsort
SELECT - col2 * + col0 * - col0 AS col1 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT - col0 * + col0 * - col0 + col1 + col1 FROM tab0
----
13996
43069
705151

query I rowsort
SELECT ALL - col1 * tab1.col2 + - tab1.col2 + - col1 FROM tab1
----
-1357
-1484
-637

query I rowsort
SELECT ALL col1 + + col2 - - col0 FROM tab2
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col1 * col1 col2 FROM tab0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 * col2 * col0 col2 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-6576
SELECT ALL col2 + col0 DIV - col1 AS col1 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-6576
SELECT ALL col2 + col0 / - col1 AS col1 FROM tab1
----
51
54
90

query I rowsort
SELECT col1 + + col1 * + cor0.col1 FROM tab2 AS cor0
----
306
3540
992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - tab1.col1 * + tab1.col0 + col2 col0 FROM tab1
----
-573
-931
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6579
SELECT - col0 DIV col0 + + col2 col2 FROM tab0
----
0
32
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6579
SELECT - col0 / col0 + + col2 col2 FROM tab0
----
0
32
81

query I rowsort
SELECT col1 FROM tab2 WHERE NULL NOT IN ( col0 )
----

query I rowsort
SELECT ALL - col1 + tab2.col1 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL col2 + col0 * + tab0.col1 + + col1 FROM tab0
----
2183
3493
8272

query I rowsort
SELECT ALL + col1 * - col0 + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL col2 * + col1 * + col0 + - col2 * - col0 + col2 * - col2 FROM tab2 cor0
----
121004
52592
5319

query I rowsort
SELECT DISTINCT col0 * + cor0.col0 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + col0 col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col1 * col0 - col0 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT + col2 * tab0.col0 + - col2 * col1 FROM tab0
----
-164
-2046
-62

query I rowsort
SELECT - col2 - col0 * + col0 AS col0 FROM tab0
----
-1226
-609
-8003

query I rowsort
SELECT ALL + col0 + col0 * col0 AS col2 FROM tab1
----
12
4160
6480

query I rowsort
SELECT cor0.col1 FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT col2 * + tab2.col0 + col1 AS col2 FROM tab2
----
2087
220
3019

query I rowsort
SELECT ALL + col0 + col0 * col0 AS col1 FROM tab2 AS cor0
----
56
6162
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * col1 * col1 col2 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT - col0 * - col1 * + cor0.col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL + col2 + - col1 * cor0.col1 * col1 FROM tab2 AS cor0
----
-205353
-29764
-4875

onlyif mysql # use DIV operator for integer division
query I rowsort label-6597
SELECT + + col2 DIV + col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6597
SELECT + + col2 / + col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + + col1 + col0 * cor0.col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - cor0.col2 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT 4 + - col1 FROM tab1
----
-22
-6
-9

query I rowsort
SELECT + col1 + col2 * + ( tab0.col2 ) * col0 FROM tab0
----
132
26222
598527

query I rowsort
SELECT 25 + - col1 * col0 AS col0 FROM tab0
----
-2039
-3370
-8074

query I rowsort
SELECT col2 * + tab2.col0 + - 58 * + 9 * tab2.col1 AS col1 FROM tab2
----
-15993
-28770
-5872

query I rowsort
SELECT + col0 + + col1 * 89 AS col2 FROM tab1
----
1237
2317
954

query I rowsort
SELECT ALL 21 + + cor0.col1 - + cor0.col1 FROM tab0 AS cor0
----
21
21
21

query I rowsort
SELECT ALL - - 87 + - col1 FROM tab1 AS cor0
----
61
74
77

query I rowsort
SELECT ALL - col2 * col0 + 48 FROM tab2 AS cor0
----
-141
-1980
-2954

query I rowsort
SELECT ALL + + col2 + ( 6 ) * col1 FROM tab2 AS cor0
----
140
213
380

query I rowsort
SELECT DISTINCT col0 - + 1 FROM tab0 cor0
----
23
34
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6611
SELECT DISTINCT - cor0.col2 * ( col1 + + col0 ) DIV - col0 AS col1 FROM tab0 AS cor0
----
151
165
3

skipif mysql # not compatible
query I rowsort label-6611
SELECT DISTINCT - cor0.col2 * ( col1 + + col0 ) / - col0 AS col1 FROM tab0 AS cor0
----
151
165
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - 40 col2 FROM tab0 AS cor0
----
-1400
-3560
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6613
SELECT DISTINCT - col1 DIV + 81 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6613
SELECT DISTINCT - col1 / + 81 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - + 92 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

onlyif mysql # use DIV operator for integer division
query I rowsort label-6615
SELECT col0 DIV - ( col0 ) FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6615
SELECT col0 / - ( col0 ) FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6616
SELECT - - col0 * col0 DIV col2 col2 FROM tab1 AS cor0
----
0
66
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6616
SELECT - - col0 * col0 / col2 col2 FROM tab1 AS cor0
----
0
66
71

query I rowsort
SELECT ALL + col1 + col1 * + col2 * + col1 FROM tab0
----
244154
679133
9506

query I rowsort
SELECT + col2 * col1 * col1 + tab1.col0 FROM tab1
----
16304
36507
5764

query III rowsort
SELECT ALL * FROM tab2 WHERE col0 IN ( col1 * - tab2.col0 )
----

query I rowsort
SELECT + col0 * col1 - - col0 AS col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT + col1 * col2 + col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT col0 - col1 * - col2 AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL tab1.col1 FROM tab1 WHERE col1 * col2 <= NULL
----

query I rowsort
SELECT + col0 * + col0 + col2 AS col2 FROM tab2
----
6110
6279
76

query I rowsort
SELECT ALL col2 + - col2 * tab1.col2 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT col0 + col2 * + col0 AS col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT tab1.col1 * - col0 * col2 + col2 AS col2 FROM tab1
----
-36423
-4158
-99744

query I rowsort
SELECT ALL + 7 + - 53 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 5a5d45989dcc6a06d9ee5a08945518f9

query I rowsort
SELECT ALL col0 * col0 - + col0 AS col1 FROM tab0 cor0
----
1190
552
7832

query I rowsort
SELECT ALL col0 - col1 * col1 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT ALL + 94 * col1 - col1 * - 2 FROM tab1 AS cor0
----
1248
2496
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6632
SELECT ALL - col2 DIV col2 + - col0 AS col1 FROM tab1
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-6632
SELECT ALL - col2 / col2 + - col0 AS col1 FROM tab1
----
-4
-65
-81

query I rowsort
SELECT col1 + col0 - col1 * - col2 * col1 AS col2 FROM tab2
----
11078
25985
90643

query I rowsort
SELECT DISTINCT col1 + - col2 * col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT ALL - col1 FROM tab0 WHERE NULL BETWEEN ( + col0 ) AND NULL
----

query I rowsort
SELECT col2 + col1 + - tab0.col0 FROM tab0
----
63
84
95

query I rowsort
SELECT - col0 AS col0 FROM tab2 WHERE ( col2 + tab2.col1 * col1 ) < - col1
----

query I rowsort
SELECT DISTINCT col2 * cor0.col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - + col2 - ( col1 * col2 ) FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT - - cor0.col0 * ( - col0 + cor0.col0 ) * + cor0.col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + - col2 + 3 AS col0 FROM tab0 AS cor0
----
-30
-79
2

query I rowsort
SELECT DISTINCT + - col1 * col0 * col1 - - col0 AS col2 FROM tab0 AS cor0
----
-177480
-329280
-736920

query I rowsort
SELECT + cor0.col1 + + ( col1 ) AS col2 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6644
SELECT - CAST( - col0 AS SIGNED ) - + col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6644
SELECT - CAST ( - col0 AS INTEGER ) - + col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6645
SELECT col0 * col2 + col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6645
SELECT col0 * col2 + col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 86 + - col0 AS col0 FROM tab2 AS cor0
----
7
79
8

query I rowsort
SELECT - + 98 * + col2 FROM tab1 cor0
----
-5292
-5586
-9408

query I rowsort
SELECT DISTINCT - 47 + + col2 FROM tab2 AS cor0
----
-20
-21
-9

query I rowsort
SELECT - - cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT tab0.col1 * col1 * col2 AS col1 FROM tab0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-6651
SELECT ALL col1 DIV 20 col0 FROM tab2
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6651
SELECT ALL col1 / 20 col0 FROM tab2
----
0
1
2

query I rowsort
SELECT - col0 + col0 * - col0 AS col2 FROM tab0 cor0
----
-1260
-600
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-6653
SELECT - ( + col1 ) + - 24 DIV col1 AS col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6653
SELECT - ( + col1 ) + - 24 / col1 AS col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL + 13 * col1 AS col1 FROM tab2
----
221
403
767

query I rowsort
SELECT + - col1 + - cor0.col2 * + col2 AS col1 FROM tab2 AS cor0
----
-1461
-735
-760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6656
SELECT DISTINCT - cor0.col2 + CAST( NULL AS SIGNED ) - 60 AS col0 FROM tab1, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6656
SELECT DISTINCT - cor0.col2 + CAST ( NULL AS INTEGER ) - 60 AS col0 FROM tab1, tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + 80 * - col0 * + col0 AS col1 FROM tab2
----
-3920
-486720
-499280

query I rowsort
SELECT + 19 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT ALL + + col1 * col0 * - 32 AS col0 FROM tab0 AS cor0
----
-108640
-259168
-66048

query I rowsort
SELECT DISTINCT 39 * col1 AS col0 FROM tab2
----
1209
2301
663

query I rowsort
SELECT + - ( cor0.col1 ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT DISTINCT 57 * col2 FROM tab1
----
3078
3249
5472

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col1 * 71 * col1 col2 FROM tab0
----
525116
587951
668039

onlyif mysql # use DIV operator for integer division
query I rowsort label-6664
SELECT ALL col1 DIV - ( col0 ) FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6664
SELECT ALL col1 / - ( col0 ) FROM tab0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * 15 col0 FROM tab0 AS cor0
----
1230
15
495

query I rowsort
SELECT - ( col2 * + col0 ) AS col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL + col1 + col0 * 67 FROM tab1 AS cor0
----
227
4298
5373

query I rowsort
SELECT DISTINCT - ( + 58 ) FROM tab2
----
-58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6669
SELECT ALL - CAST( NULL AS SIGNED ) * tab0.col0 + + col0 * + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6669
SELECT ALL - CAST ( NULL AS INTEGER ) * tab0.col0 + + col0 * + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + - col0 + + ( + col0 ) AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - + 15 FROM tab0 cor0
----
-15

query I rowsort
SELECT - col2 * col0 * col1 + cor0.col2 FROM tab1 AS cor0
----
-36423
-4158
-99744

query I rowsort
SELECT 35 * col2 + + 60 AS col0 FROM tab0 AS cor0
----
1215
2930
95

query I rowsort
SELECT DISTINCT + col1 - 7 * - col1 * col1 FROM tab2 AS cor0
----
2040
24426
6758

query I rowsort
SELECT DISTINCT - 50 + 74 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
24

query I rowsort
SELECT DISTINCT - - 91 * ( col1 + 38 * + col0 ) FROM tab2 AS cor0
----
27027
274729
275093

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6677
SELECT ALL - CAST( NULL AS DECIMAL ) + ( - col2 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6677
SELECT ALL - CAST ( NULL AS REAL ) + ( - col2 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 * - ( cor0.col0 ) AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL - 32 + + col1 AS col2 FROM tab0 cor0
----
54
59
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-6680
SELECT DISTINCT - + col1 + col0 DIV + col0 FROM tab0 cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-6680
SELECT DISTINCT - + col1 + col0 / + col0 FROM tab0 cor0
----
-85
-90
-96

query I rowsort
SELECT ALL col1 * col1 + - col0 AS col1 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT DISTINCT - 68 AS col2 FROM tab2 AS cor0
----
-68

query I rowsort
SELECT DISTINCT - + col1 * + col0 * - col1 AS col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT - col1 + - col2 * col1 AS col2 FROM tab1 AS cor0
----
-1261
-1430
-580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col0 * col1 - + col2 * col1 col2 FROM tab1
----
-1326
-208
70

query I rowsort
SELECT ( - 0 * col2 ) AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT - col0 * + col1 - col1 AS col0 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT + 10 AS col2 FROM tab1
----
10

query I rowsort
SELECT ALL - 57 - 45 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 75910752776d12204fe601607ccbc028

query I rowsort
SELECT - col0 + tab2.col0 * tab2.col1 AS col2 FROM tab2
----
1264
210
4524

query I rowsort
SELECT ALL - - cor0.col1 * + col2 * cor0.col0 + cor0.col1 * col2 FROM tab1 AS cor0
----
101088
37050
5616

query I rowsort
SELECT DISTINCT - col0 + - 98 FROM tab1 AS cor0
----
-101
-162
-178

query I rowsort
SELECT ALL + cor0.col0 * 54 FROM tab1 AS cor0
----
162
3456
4320

onlyif mysql # use DIV operator for integer division
query I rowsort label-6694
SELECT ALL - + col0 DIV + 76 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6694
SELECT ALL - + col0 / + 76 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort
SELECT - col0 * + CAST ( + col1 AS REAL ) + - col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT - + col0 + + ( - col2 ) + - col2 FROM tab1 AS cor0
----
-111
-178
-272

query I rowsort
SELECT ALL - col1 + ( - ( col0 ) ) AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + col1 * - col1 + - col0 * col0 FROM tab2 AS cor0
----
-1010
-6530
-9565

query I rowsort
SELECT DISTINCT - col1 + 2 * - 30 AS col2 FROM tab0 AS cor0
----
-146
-151
-157

query I rowsort
SELECT 59 AS col1 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT 10 * - col2 AS col2 FROM tab2
----
-260
-270
-380

query I rowsort
SELECT - tab2.col0 + 13 AS col2 FROM tab2
----
-65
-66
6

query I rowsort
SELECT ALL + ( - col0 ) * - col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT 81 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - - col2 col1 FROM tab2
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6706
SELECT + - CAST( NULL AS SIGNED ) / col2 + - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6706
SELECT + - CAST ( NULL AS INTEGER ) / col2 + - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + col0 + col0 * col0 AS col1 FROM tab0
----
1261
633
8092

query I rowsort
SELECT ALL - col0 * ( + col0 ) * - col1 + - tab1.col1 * col2 * + col2 FROM tab1
----
-36608
-75582
8470

query I rowsort
SELECT + col1 * col2 * col0 + + 86 FROM tab1 cor0
----
36566
4298
99926

onlyif mysql # use DIV operator for integer division
query I rowsort label-6710
SELECT - col0 * 43 + col2 DIV 19 AS col1 FROM tab0 AS cor0
----
-1031
-1505
-3823

skipif mysql # not compatible
query I rowsort label-6710
SELECT - col0 * 43 + col2 / 19 AS col1 FROM tab0 AS cor0
----
-1031
-1505
-3823

onlyif mysql # use DIV operator for integer division
query I rowsort label-6711
SELECT - CAST( - 87 AS SIGNED ) * col2 + - cor0.col1 DIV 22 FROM tab1 cor0
----
4697
4959
8352

skipif mysql # not compatible
query I rowsort label-6711
SELECT - CAST ( - 87 AS INTEGER ) * col2 + - cor0.col1 / 22 FROM tab1 cor0
----
4697
4959
8352

query I rowsort
SELECT DISTINCT col2 + - ( 35 ) * col2 FROM tab1
----
-1836
-1938
-3264

query I rowsort
SELECT col2 * + 61 FROM tab0
----
2013
5002
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6714
SELECT ALL col2 * - CAST( NULL AS SIGNED ) + - 26 + - col2 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6714
SELECT ALL col2 * - CAST ( NULL AS INTEGER ) + - 26 + - col2 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * - 19 + - col1 AS col1 FROM tab1
----
-1052
-1093
-1837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 15 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT col2 * col1 + col1 AS col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL + ( + col2 ) + + col1 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - 13 + - ( + col0 ) * - col2 * + cor0.col2 FROM tab0 AS cor0
----
22
26123
598423

query I rowsort
SELECT DISTINCT + - col0 * + ( + cor0.col2 * col1 ) AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + - 56 * 15 + + col2 * - col2 FROM tab2 AS cor0
----
-1516
-1569
-2284

onlyif mysql # use DIV operator for integer division
query I rowsort label-6722
SELECT + 40 DIV + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6722
SELECT + 40 / + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 0 * + col0 FROM tab1 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6724
SELECT DISTINCT - col2 * 97 DIV + col1 FROM tab0 AS cor0
----
-1
-37
-87

skipif mysql # not compatible
query I rowsort label-6724
SELECT DISTINCT - col2 * 97 / + col1 FROM tab0 AS cor0
----
-1
-37
-87

query I rowsort
SELECT ALL + - ( + 50 ) * + col2 + col2 FROM tab0 AS cor0
----
-1617
-4018
-49

query I rowsort
SELECT DISTINCT + 72 * - 16 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-1152

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6727
SELECT ALL + col2 + + col2 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6727
SELECT ALL + col2 + + col2 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 - - cor0.col2 AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-6729
SELECT ALL - + col2 DIV - col2 + + ( - 59 ) * - col0 FROM tab0 AS cor0
----
1417
2066
5252

skipif mysql # not compatible
query I rowsort label-6729
SELECT ALL - + col2 / - col2 + + ( - 59 ) * - col0 FROM tab0 AS cor0
----
1417
2066
5252

onlyif mysql # use DIV operator for integer division
query I rowsort label-6730
SELECT DISTINCT + col0 DIV + col0 + + ( + 55 ) - col1 * 90 FROM tab2 AS cor0
----
-1474
-2734
-5254

skipif mysql # not compatible
query I rowsort label-6730
SELECT DISTINCT + col0 / + col0 + + ( + 55 ) - col1 * 90 FROM tab2 AS cor0
----
-1474
-2734
-5254

query I rowsort
SELECT DISTINCT + 49 + - col1 AS col1 FROM tab1
----
23
36
39

query I rowsort
SELECT ALL + col1 * col2 + col0 * - 20 + + col2 FROM tab0 AS cor0
----
-602
2391
5764

query I rowsort
SELECT DISTINCT + - 23 * - col0 FROM tab0 AS cor0
----
2047
552
805

query I rowsort
SELECT DISTINCT + + col2 * + col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - cor0.col2 + + col2 AS col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col2 + - ( 83 ) * + col0 AS col0 FROM tab2 AS cor0
----
-554
-6448
-6519

query I rowsort
SELECT DISTINCT - col2 + + 89 AS col1 FROM tab0 AS cor0
----
56
7
88

query I rowsort
SELECT DISTINCT + col1 + + cor0.col0 * - cor0.col0 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT col2 + - col1 * - 62 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-39623
-4782
-64384

query I rowsort
SELECT + col1 * col0 + - col2 AS col1 FROM tab1 cor0
----
24
583
944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6741
SELECT - col1 * - CAST( - col2 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif mysql # not compatible
query I rowsort label-6741
SELECT - col1 * - CAST ( - col2 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6742
SELECT + - cor0.col0 * + col0 + - 2 DIV col1 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-6742
SELECT + - cor0.col0 * + col0 + - 2 / col1 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 + - CAST ( - col1 + - col1 AS REAL ) * + 98 * 6 FROM tab0 AS cor0
----
101050
106925
113975

query I rowsort
SELECT ALL - 82 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ce62f59690969f4492d78eb57c3181f0

query I rowsort
SELECT ALL - ( + cor0.col0 ) * + col1 + + col2 + col2 AS col2 FROM tab1 AS cor0
----
-526
-848
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-6746
SELECT DISTINCT - + 4 DIV cor0.col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6746
SELECT DISTINCT - + 4 / cor0.col2 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6747
SELECT ALL + col1 * + col1 * + col1 + col1 DIV col1 FROM tab1 AS cor0
----
1001
17577
2198

skipif mysql # not compatible
query I rowsort label-6747
SELECT ALL + col1 * + col1 * + col1 + col1 / col1 FROM tab1 AS cor0
----
1001
17577
2198

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6748
SELECT ALL - CAST( col1 AS SIGNED ) * + col2 FROM tab2
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-6748
SELECT ALL - CAST ( col1 AS INTEGER ) * + col2 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT + - 23 * + col1 FROM tab2 AS cor0
----
-1357
-391
-713

query I rowsort
SELECT + 2 * col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT + + col1 * - col2 AS col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT col0 * - col0 * + 83 AS col1 FROM tab1
----
-339968
-531200
-747

onlyif mysql # use DIV operator for integer division
query I rowsort label-6753
SELECT col0 DIV 26 + ( col1 ) FROM tab2 AS cor0
----
20
31
62

skipif mysql # not compatible
query I rowsort label-6753
SELECT col0 / 26 + ( col1 ) FROM tab2 AS cor0
----
20
31
62

query I rowsort
SELECT col2 + + col0 * + 53 FROM tab2 AS cor0
----
398
4160
4225

query I rowsort
SELECT - col1 * - col2 * + col1 AS col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT ALL - - col0 * col0 + + ( + col0 ) AS col2 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT + + col0 + ( - col0 ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * ( + col2 ) + col2 AS col2 FROM tab0 cor0
----
1122
2
6806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6759
SELECT + - col1 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6759
SELECT + - col1 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6760
SELECT ALL - - cor0.col1 + ( + col0 ) + + col1 / CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6760
SELECT ALL - - cor0.col1 + ( + col0 ) + + col1 / CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 57 * - 56 + col0 * col0 FROM tab0 AS cor0
----
-1967
-2616
4729

query I rowsort
SELECT + + ( 30 ) * - cor0.col2 * col2 + cor0.col0 + - col0 AS col2 FROM tab0 AS cor0
----
-201720
-30
-32670

query I rowsort
SELECT ALL + ( + col2 ) + + col2 * + col0 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6764
SELECT ALL col0 + col1 DIV + col0 AS col0 FROM tab0 cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-6764
SELECT ALL col0 + col1 / + col0 AS col0 FROM tab0 cor0
----
27
37
90

query I rowsort
SELECT + 6 + - cor0.col1 AS col1 FROM tab2 cor0
----
-11
-25
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-6766
SELECT 48 + 18 DIV col2 FROM tab0 AS cor0
----
48
48
66

skipif mysql # not compatible
query I rowsort label-6766
SELECT 48 + 18 / col2 FROM tab0 AS cor0
----
48
48
66

query I rowsort
SELECT ALL 51 + - 96 AS col0 FROM tab2 AS cor0
----
-45
-45
-45

query I rowsort
SELECT - 36 * + col0 AS col2 FROM tab2 AS cor0
----
-252
-2808
-2844

query I rowsort
SELECT - ( col0 ) * - col0 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT + 78 * - col0 FROM tab1 AS cor0
----
-234
-4992
-6240

query I rowsort
SELECT DISTINCT + + col2 + + col0 AS col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL - + 85 * cor0.col1 * ( cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-24565
-295885
-81685

query I rowsort
SELECT col2 * - col1 + col0 AS col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT + col2 * - 94 + - col1 FROM tab0 AS cor0
----
-191
-3188
-7799

onlyif mysql # use DIV operator for integer division
query I rowsort label-6775
SELECT col0 DIV + col0 + - col0 * + col0 FROM tab2 AS cor0
----
-48
-6083
-6240

skipif mysql # not compatible
query I rowsort label-6775
SELECT col0 / + col0 + - col0 * + col0 FROM tab2 AS cor0
----
-48
-6083
-6240

query I rowsort
SELECT ALL + cor0.col0 * col0 + + col0 * col2 AS col2 FROM tab1 AS cor0
----
14080
171
7744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col0 * col0 col0 FROM tab1 AS cor0
----
-262144
-27
-512000

query I rowsort
SELECT + col2 - col1 * + col1 * col2 AS col2 FROM tab0
----
-244035
-678960
-9408

query I rowsort
SELECT col0 + col0 + + col0 AS col1 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT col0 * 14 AS col2 FROM tab0
----
1246
336
490

query I rowsort
SELECT DISTINCT col0 * 55 + + col0 AS col0 FROM tab2
----
392
4368
4424

onlyif mysql # use DIV operator for integer division
query I rowsort label-6782
SELECT ALL + col1 + + col1 DIV + 62 col2 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6782
SELECT ALL + col1 + + col1 / + 62 col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - col0 + ( tab1.col0 ) AS col2 FROM tab1
----
0

query I rowsort
SELECT + col0 * - col2 * col1 + col2 * col0 - col1 * col0 FROM tab0
----
-664919
-6755
-69384

query I rowsort
SELECT tab1.col2 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL - + 69 + - col0 * col0 * 25 AS col2 FROM tab1 AS cor0
----
-102469
-160069
-294

onlyif mysql # use DIV operator for integer division
query I rowsort label-6787
SELECT DISTINCT col1 + col0 DIV - cor0.col0 AS col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-6787
SELECT DISTINCT col1 + col0 / - cor0.col0 AS col1 FROM tab1 AS cor0
----
12
25
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6788
SELECT ALL - + 76 DIV col0 + col2 FROM tab1 AS cor0
----
29
56
96

skipif mysql # not compatible
query I rowsort label-6788
SELECT ALL - + 76 / col0 + col2 FROM tab1 AS cor0
----
29
56
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 87 col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT DISTINCT + col1 + + ( col0 + - col0 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - + col1 + - 71 AS col1 FROM tab2 AS cor0
----
-102
-130
-88

query I rowsort
SELECT ALL + - col2 * col1 - - col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + - col0 * ( col1 ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL - + col0 + + 54 AS col0 FROM tab1 AS cor0
----
-10
-26
51

query I rowsort
SELECT DISTINCT + - col0 + 84 FROM tab2 AS cor0
----
5
6
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6796
SELECT CAST( NULL AS SIGNED ) + 89 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6796
SELECT CAST ( NULL AS INTEGER ) + 89 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + + tab1.col0 * + col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT DISTINCT col0 + col1 * + col1 FROM tab2
----
3559
368
968

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) AS col1 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6800
SELECT ALL + col1 + col1 * col2 * - CAST( + cor0.col1 AS SIGNED ) + - col0 * + col2 * 15 FROM tab0 AS cor0
----
-255862
-788421
-9837

skipif mysql # not compatible
query I rowsort label-6800
SELECT ALL + col1 + col1 * col2 * - CAST ( + cor0.col1 AS INTEGER ) + - col0 * + col2 * 15 FROM tab0 AS cor0
----
-255862
-788421
-9837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6801
SELECT - - cor0.col0 + + col0 DIV + col0 FROM tab2 cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-6801
SELECT - - cor0.col0 + + col0 / + col0 FROM tab2 cor0
----
79
8
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6802
SELECT DISTINCT cor0.col1 * + col2 * - col0 + CAST( + col1 * col1 + + cor0.col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-60630
-655746
6111

skipif mysql # not compatible
query I rowsort label-6802
SELECT DISTINCT cor0.col1 * + col2 * - col0 + CAST ( + col1 * col1 + + cor0.col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-60630
-655746
6111

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * col1 + + col2 col2 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-6804
SELECT - col2 DIV col0 + cor0.col0 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-6804
SELECT - col2 / col0 + cor0.col0 FROM tab0 AS cor0
----
23
35
89

query I rowsort
SELECT DISTINCT col2 - - col2 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-6806
SELECT - + col1 + + cor0.col1 * cor0.col1 DIV col0 FROM tab1 AS cor0
----
-11
-9
199

skipif mysql # not compatible
query I rowsort label-6806
SELECT - + col1 + + cor0.col1 * cor0.col1 / col0 FROM tab1 AS cor0
----
-11
-9
199

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6807
SELECT DISTINCT + ( - col2 ) * CAST( col0 AS SIGNED ) + - col1 * - col0 AS col2 FROM tab0 AS cor0
----
1272
3360
801

skipif mysql # not compatible
query I rowsort label-6807
SELECT DISTINCT + ( - col2 ) * CAST ( col0 AS INTEGER ) + - col1 * - col0 AS col2 FROM tab0 AS cor0
----
1272
3360
801

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 84 col2 FROM tab1 AS cor0
----
-84

query I rowsort
SELECT - + cor0.col0 * - col1 + cor0.col0 * + col0 AS col0 FROM tab0 AS cor0
----
16020
2640
4620

onlyif mysql # use DIV operator for integer division
query I rowsort label-6810
SELECT DISTINCT + col0 * col0 DIV + cor0.col0 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6810
SELECT DISTINCT + col0 * col0 / + cor0.col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL + + col2 * - cor0.col2 * 41 + - col1 AS col1 FROM tab0 AS cor0
----
-138
-275775
-44735

query I rowsort
SELECT DISTINCT 91 AS col1 FROM tab2 AS cor0
----
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6813
SELECT DISTINCT 27 * + col2 + CAST( col0 AS SIGNED ) * + col2 FROM tab0 AS cor0
----
1683
62
9512

skipif mysql # not compatible
query I rowsort label-6813
SELECT DISTINCT 27 * + col2 + CAST ( col0 AS INTEGER ) * + col2 FROM tab0 AS cor0
----
1683
62
9512

onlyif mysql # use DIV operator for integer division
query I rowsort label-6814
SELECT ( tab2.col1 ) * col1 DIV ( + col0 ) - - col1 FROM tab2
----
103
168
20

skipif mysql # not compatible
query I rowsort label-6814
SELECT ( tab2.col1 ) * col1 / ( + col0 ) - - col1 FROM tab2
----
103
168
20

query I rowsort
SELECT DISTINCT - 99 - - col1 FROM tab2
----
-40
-68
-82

query I rowsort
SELECT DISTINCT col1 * col2 * + col0 + 22 AS col0 FROM tab0
----
3417
664140
68134

onlyif mysql # use DIV operator for integer division
query I rowsort label-6817
SELECT ALL - 45 DIV - tab1.col0 + + col1 * ( + tab1.col1 ) AS col2 FROM tab1
----
100
169
691

skipif mysql # not compatible
query I rowsort label-6817
SELECT ALL - 45 / - tab1.col0 + + col1 * ( + tab1.col1 ) AS col2 FROM tab1
----
100
169
691

query I rowsort
SELECT - cor0.col2 - col1 * 46 FROM tab0 AS cor0
----
-3989
-4268
-4463

query I rowsort
SELECT DISTINCT 62 + col2 FROM tab1 AS cor0
----
116
119
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6820
SELECT + col2 + 98 * - col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6820
SELECT + col2 + 98 * - col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col0 ) - col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL - - col2 + + col1 * col2 * - col1 FROM tab1 cor0
----
-16128
-36450
-5643

query I rowsort
SELECT + ( + col1 ) * 68 * - 85 FROM tab2
----
-179180
-341020
-98260

query I rowsort
SELECT col1 + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT col0 * cor0.col1 + + 85 AS col0 FROM tab2 AS cor0
----
1428
302
4687

onlyif mysql # use DIV operator for integer division
query I rowsort label-6826
SELECT - + col1 + + 25 DIV col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6826
SELECT - + col1 + + 25 / col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + ( col1 + 94 ) * col0 FROM tab2
----
11934
875
8769

onlyif mysql # use DIV operator for integer division
query I rowsort label-6828
SELECT - col0 DIV + 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-6828
SELECT - col0 / + col0 col2 FROM tab0 cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 95 col0 FROM tab2 AS cor0
----
95
95
95

query I rowsort
SELECT + col1 + + 64 * + cor0.col1 FROM tab2 AS cor0
----
1105
2015
3835

query I rowsort
SELECT DISTINCT - - 60 FROM tab1 AS cor0
----
60

query I rowsort
SELECT ALL col0 * 82 FROM tab0 AS cor0
----
1968
2870
7298

query I rowsort
SELECT DISTINCT - - 10 FROM tab2 cor0
----
10

query I rowsort
SELECT ALL tab2.col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT - col1 * + 25 AS col0 FROM tab0
----
-2150
-2275
-2425

query I rowsort
SELECT + - ( + 98 ) * col1 FROM tab0 AS cor0
----
-8428
-8918
-9506

query I rowsort
SELECT DISTINCT - + ( - col1 ) + col0 AS col2 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6838
SELECT DISTINCT + CAST( NULL AS SIGNED ) + 82 * - col2 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6838
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + 82 * - col2 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * col2 col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - 76 AS col2 FROM tab2 cor0
----
-76
-76
-76

query I rowsort
SELECT - - 54 + + col0 FROM tab0 AS cor0
----
143
78
89

query I rowsort
SELECT + tab1.col2 * + 84 FROM tab1, tab1 AS cor0
----
9 values hashing to a0722a95fc6c19bdf3fbe30c59084b3d

onlyif mysql # use DIV operator for integer division
query I rowsort label-6843
SELECT DISTINCT 75 DIV - col1 AS col0 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-6843
SELECT DISTINCT 75 / - col1 AS col0 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT + col1 + ( col2 ) FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT tab2.col0 * + 37 FROM tab2, tab0 AS cor0
----
9 values hashing to 73ee812132330de098318363c918c2c8

query I rowsort
SELECT ALL + 86 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT DISTINCT 54 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
54

query I rowsort
SELECT + cor0.col0 + col0 * - 43 AS col0 FROM tab1 AS cor0
----
-126
-2688
-3360

query I rowsort
SELECT ( ( col2 ) * + col1 ) + col2 FROM tab2
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 85 + col0 * - col1 col0 FROM tab2
----
-1258
-132
-4517

query I rowsort
SELECT 49 + + 13 AS col2 FROM tab0
----
62
62
62

query I rowsort
SELECT DISTINCT + 6 * 73 + + col1 FROM tab1 AS cor0
----
448
451
464

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6853
SELECT - + col1 * col2 - + col1 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6853
SELECT - + col1 * col2 - + 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-6854
SELECT + - CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6854
SELECT + - CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ( 2 ) AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT 98 + - col0 AS col1 FROM tab1 AS cor0
----
18
34
95

query I rowsort
SELECT col0 + col1 * col1 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT 59 + col0 FROM tab0
----
148
83
94

query I rowsort
SELECT DISTINCT - 93 + col2 FROM tab1
----
-36
-39
3

query I rowsort
SELECT ALL - 66 - - col1 * tab1.col2 FROM tab1
----
1182
1338
504

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * + col1 + col0 * col1 col2 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT - - col0 * + col2 AS col0 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6863
SELECT - - col0 DIV col2 + cor0.col1 * col0 FROM tab1 cor0
----
1040
641
78

skipif mysql # not compatible
query I rowsort label-6863
SELECT - - col0 / col2 + cor0.col1 * col0 FROM tab1 cor0
----
1040
641
78

query I rowsort
SELECT cor0.col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * - col2 + + col2 * - col0 col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - cor0.col0 * + col1 * col2 + - col2 FROM tab1 AS cor0
----
-36537
-4266
-99936

query I rowsort
SELECT DISTINCT col0 + col1 * + cor0.col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT - col0 + - tab1.col2 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT col1 * + col0 * + col2 + + cor0.col0 FROM tab1 AS cor0
----
36544
4215
99920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6870
SELECT DISTINCT - - col0 DIV col1 AS col1 FROM tab1 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-6870
SELECT DISTINCT - - col0 / col1 AS col1 FROM tab1 AS cor0
----
0
6

query I rowsort
SELECT + - 8 * 47 FROM tab2 AS cor0
----
-376
-376
-376

onlyif mysql # use DIV operator for integer division
query I rowsort label-6872
SELECT ( col2 ) DIV col0 AS col2 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6872
SELECT ( col2 ) / col0 AS col2 FROM tab1
----
0
1
18

query I rowsort
SELECT - ( 99 ) - + col1 FROM tab0
----
-185
-190
-196

query I rowsort
SELECT - ( + col1 * col0 ) + col2 AS col1 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT + + ( + col0 ) * col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6876
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * - col2 * - col2 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6876
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * - col2 * - col2 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6877
SELECT + CAST( - col1 AS SIGNED ) + col2 * col2 FROM tab1 AS cor0
----
2890
3239
9203

skipif mysql # not compatible
query I rowsort label-6877
SELECT + CAST ( - col1 AS INTEGER ) + col2 * col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - col1 + col2 * col2 * + col0 AS col0 FROM tab0 AS cor0
----
-62
26050
598345

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 87 col1 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT + col1 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
2
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6881
SELECT tab0.col2 DIV 63 AS col2 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6881
SELECT tab0.col2 / 63 AS col2 FROM tab0
----
0
0
1

query I rowsort
SELECT + + col2 - col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - col1 - cor0.col2 * col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT col1 * + 48 FROM tab0
----
4128
4368
4656

query I rowsort
SELECT DISTINCT col2 - tab1.col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT - 65 AS col2 FROM tab0, tab2 AS cor0
----
-65

query I rowsort
SELECT DISTINCT + 26 AS col2 FROM tab0, tab0 AS cor0
----
26

query I rowsort
SELECT ALL + col2 * col0 + col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT + + col1 * 24 + col1 + col0 * 12 AS col0 FROM tab2 AS cor0
----
1373
2411
859

query I rowsort
SELECT DISTINCT - col1 + 49 * col2 FROM tab1 AS cor0
----
2620
2783
4691

query I rowsort
SELECT DISTINCT col1 * + 86 + col0 * - 68 FROM tab0 AS cor0
----
1774
5764
5962

query I rowsort
SELECT ALL - - 49 FROM tab2 AS cor0
----
49
49
49

query I rowsort
SELECT + - 65 * - 88 + col0 FROM tab1 cor0
----
5723
5784
5800

query I rowsort
SELECT DISTINCT - 87 AS col2 FROM tab2, tab1 AS cor0
----
-87

query I rowsort
SELECT DISTINCT - col2 + ( + 45 + + col1 ) * - col0 AS col1 FROM tab2
----
-4936
-559
-8138

query I rowsort
SELECT ( - col0 ) + - col0 FROM tab1
----
-128
-160
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6897
SELECT DISTINCT col0 DIV col1 + + col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6897
SELECT DISTINCT col0 / col1 + + col0 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT ( - col2 ) * - col1 * + col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT ALL + col1 * col1 + + col0 FROM tab1
----
164
249
679

query I rowsort
SELECT ALL 29 + col2 FROM tab2
----
55
56
67

query I rowsort
SELECT ALL + ( - 56 ) + col1 * - col0 * + col0 + - col0 AS col2 FROM tab2
----
-106232
-1582
-359090

query I rowsort
SELECT ALL ( - 51 ) + - col0 FROM tab0
----
-140
-75
-86

query I rowsort
SELECT - col0 + col2 * col0 AS col0 FROM tab2
----
182
1950
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * - col0 col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - col1 + 18 + col1 FROM tab2 AS cor0
----
18
18
18

query I rowsort
SELECT DISTINCT + - cor0.col0 + col0 * col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT + col1 * - col1 + + tab2.col2 AS col0 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT - tab0.col0 * + 35 + - col0 AS col1 FROM tab0
----
-1260
-3204
-864

query I rowsort
SELECT ALL + - 86 + - col0 AS col2 FROM tab1 AS cor0
----
-150
-166
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6910
SELECT + col2 + + col1 DIV col2 AS col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6910
SELECT + col2 + + col1 / col2 AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT col1 * + cor0.col2 - - col1 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * + tab2.col2 col0 FROM tab2, tab2 AS cor0
----
1026
1444
676
702
729
988

query I rowsort
SELECT ALL - col2 + - cor0.col1 * col1 + - cor0.col0 * + col0 FROM tab0 AS cor0
----
-10635
-16284
-8005

query I rowsort
SELECT - col0 + ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + cor0.col2 - + col0 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - col1 * 35 AS col0 FROM tab2 AS cor0
----
-1085
-2065
-595

query I rowsort
SELECT ALL col2 * - 22 + + col0 + cor0.col1 FROM tab1 AS cor0
----
-1159
-1180
-2019

query I rowsort
SELECT DISTINCT - col2 - + ( col2 ) * + col2 AS col2 FROM tab2 cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL - col1 * - ( - col2 ) + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6920
SELECT + - col1 DIV col2 - col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-6920
SELECT + - col1 / col2 - col1 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6921
SELECT col2 * CAST( col2 AS SIGNED ) AS col1 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-6921
SELECT col2 * CAST ( col2 AS INTEGER ) AS col1 FROM tab0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6922
SELECT + col2 * - CAST( NULL AS SIGNED ) + col0 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6922
SELECT + col2 * - CAST ( NULL AS INTEGER ) + col0 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 63 FROM tab2, tab0 AS cor0
----
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6924
SELECT DISTINCT + + col0 + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6924
SELECT DISTINCT + + col0 + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col1 * ( ( col1 ) ) * col1 + col2 AS col1 FROM tab1 AS cor0
----
-17522
-2101
-943

query I rowsort
SELECT DISTINCT + + col1 * col1 * 25 FROM tab1 AS cor0
----
16900
2500
4225

query I rowsort
SELECT ALL - + col1 * + cor0.col0 + - col0 AS col1 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT + + col2 * 88 AS col1 FROM tab2 AS cor0
----
2288
2376
3344

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + - 25 * + col0 col0 FROM tab1 AS cor0
----
-1664
-2080
-78

query I rowsort
SELECT - col0 * ( col0 ) + + cor0.col2 + 32 AS col1 FROM tab0 cor0
----
-1192
-511
-7807

query I rowsort
SELECT DISTINCT ( - ( - tab1.col2 ) ) FROM tab1, tab2 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6932
SELECT col1 DIV - 62 + col0 DIV col2 FROM tab0
----
-1
0
34

skipif mysql # not compatible
query I rowsort label-6932
SELECT col1 / - 62 + col0 / col2 FROM tab0
----
-1
0
34

query I rowsort
SELECT DISTINCT 21 FROM tab0, tab0 cor0
----
21

query I rowsort
SELECT ALL - 60 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

query I rowsort
SELECT DISTINCT - - col0 * cor0.col0 * + col1 + + col1 * + col1 + col1 FROM tab2 AS cor0
----
106403
2511
362496

query I rowsort
SELECT col1 + + 20 FROM tab0 AS cor0
----
106
111
117

onlyif mysql # use DIV operator for integer division
query I rowsort label-6937
SELECT - + col1 DIV + 47 - col2 FROM tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6937
SELECT - + col1 / + 47 - col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + - 41 + col1 AS col0 FROM tab0 cor0
----
45
50
56

query I rowsort
SELECT + 40 + col2 FROM tab1 cor0
----
136
94
97

query I rowsort
SELECT ALL + - 5 AS col1 FROM tab0 AS cor0
----
-5
-5
-5

query I rowsort
SELECT + ( col0 ) + cor0.col1 FROM tab1 cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + ( + tab1.col0 ) col2 FROM tab1
----
128
160
6

query I rowsort
SELECT - + col1 + + col1 * col2 AS col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-6944
SELECT 93 + col2 DIV + ( 15 ) AS col2 FROM tab2 AS cor0
----
94
94
95

skipif mysql # not compatible
query I rowsort label-6944
SELECT 93 + col2 / + ( 15 ) AS col2 FROM tab2 AS cor0
----
94
94
95

query I rowsort
SELECT DISTINCT + 44 + cor0.col2 AS col1 FROM tab1 AS cor0
----
101
140
98

query I rowsort
SELECT DISTINCT + 64 FROM tab0 cor0
----
64

query I rowsort
SELECT DISTINCT cor0.col1 * col2 + ( 0 ) AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * - col2 - col2 col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT - 56 * cor0.col2 + - cor0.col0 FROM tab2 cor0
----
-1519
-1534
-2207

query I rowsort
SELECT ALL - ( col2 ) * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - + ( col1 ) AS col2 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - 3 * col0 AS col2 FROM tab0 cor0
----
-105
-267
-72

query I rowsort
SELECT + + 53 * + cor0.col1 AS col2 FROM tab2 cor0
----
1643
3127
901

query I rowsort
SELECT - 4 * + col2 FROM tab2 cor0
----
-104
-108
-152

query I rowsort
SELECT ALL 53 * + col2 FROM tab0
----
1749
4346
53

query I rowsort
SELECT DISTINCT 23 FROM tab1, tab1 cor0
----
23

query I rowsort
SELECT - - col1 * - 32 FROM tab0 AS cor0
----
-2752
-2912
-3104

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + ( col0 ) * + cor0.col2 col1 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT 56 * col1 FROM tab2
----
1736
3304
952

query I rowsort
SELECT 66 * - col1 AS col0 FROM tab1
----
-1716
-660
-858

skipif mysql # not compatible
query I rowsort
SELECT + - 94 * - col2 + CAST ( 29 + - col0 AS REAL ) FROM tab0 AS cor0
----
3107
7648
88

query I rowsort
SELECT col1 - + col2 * col2 AS col0 FROM tab1 AS cor0
----
-2890
-3239
-9203

onlyif mysql # use DIV operator for integer division
query I rowsort label-6963
SELECT + col2 DIV ( 43 ) + col0 FROM tab1 AS cor0
----
4
65
82

skipif mysql # not compatible
query I rowsort label-6963
SELECT + col2 / ( 43 ) + col0 FROM tab1 AS cor0
----
4
65
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6964
SELECT DISTINCT cor0.col0 + CAST( cor0.col2 AS SIGNED ) FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-6964
SELECT DISTINCT cor0.col0 + CAST ( cor0.col2 AS INTEGER ) FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6965
SELECT DISTINCT + + col1 DIV ( 46 ) + - col0 - ( + 25 ) AS col0 FROM tab1 AS cor0
----
-105
-28
-89

skipif mysql # not compatible
query I rowsort label-6965
SELECT DISTINCT + + col1 / ( 46 ) + - col0 - ( + 25 ) AS col0 FROM tab1 AS cor0
----
-105
-28
-89

query I rowsort
SELECT - col0 + cor0.col2 * ( + col2 ) * ( - col1 ) FROM tab2 AS cor0
----
-22606
-24627
-39962

query I rowsort
SELECT col0 * - 30 + col1 FROM tab1 AS cor0
----
-1910
-2387
-64

query I rowsort
SELECT DISTINCT + col0 * col2 + + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT DISTINCT cor0.col1 + - cor0.col2 FROM tab1, tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + col0 - ( 60 ) AS col2 FROM tab0 AS cor0
----
-25
-36
29

query I rowsort
SELECT - + col1 + ( + col1 ) FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 * ( - cor0.col2 ) AS col1 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6973
SELECT CAST( NULL AS SIGNED ) - 16 * - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6973
SELECT CAST ( NULL AS INTEGER ) - 16 * - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6974
SELECT + - CAST( col1 AS SIGNED ) * + col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-6974
SELECT + - CAST ( col1 AS INTEGER ) * + col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 53 ) * col1 col0 FROM tab0 AS cor0
----
4558
4823
5141

query I rowsort
SELECT - + 59 * col2 FROM tab1 AS cor0
----
-3186
-3363
-5664

query I rowsort
SELECT - 47 * + 52 FROM tab0 AS cor0
----
-2444
-2444
-2444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - col1 col1 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT ALL col0 * + 24 * col2 FROM tab2
----
4536
48672
72048

onlyif mysql # use DIV operator for integer division
query I rowsort label-6980
SELECT DISTINCT - - tab1.col2 DIV + 12 AS col0 FROM tab1, tab2, tab0 AS cor0
----
4
8

skipif mysql # not compatible
query I rowsort label-6980
SELECT DISTINCT - - tab1.col2 / + 12 AS col0 FROM tab1, tab2, tab0 AS cor0
----
4
8

query I rowsort
SELECT DISTINCT - - col1 - - col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT - - 9 FROM tab2 AS cor0
----
9
9
9

query I rowsort
SELECT - - col0 * - col2 + + col0 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT col2 * - col1 * 7 + - cor0.col1 FROM tab2 cor0
----
-10797
-4539
-5890

query I rowsort
SELECT ALL + 96 + + col2 FROM tab1 AS cor0
----
150
153
192

query I rowsort
SELECT DISTINCT + - col2 * col0 + - col2 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT - + 3 * col2 * + 94 FROM tab2 AS cor0
----
-10716
-7332
-7614

onlyif mysql # use DIV operator for integer division
query I rowsort label-6988
SELECT + 50 + - col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
49
49
49

skipif mysql # not compatible
query I rowsort label-6988
SELECT + 50 + - col0 / + col0 AS col1 FROM tab1 AS cor0
----
49
49
49

query I rowsort
SELECT DISTINCT - 83 FROM tab2 cor0
----
-83

query I rowsort
SELECT ALL 52 * col0 FROM tab2
----
364
4056
4108

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 73 * - cor0.col1 col0 FROM tab1, tab1 cor0
----
9 values hashing to 0949a6717a5a974cf810e495176c0516

query I rowsort
SELECT DISTINCT + ( + 23 ) FROM tab0
----
23

query I rowsort
SELECT + tab0.col2 * - cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to a811f2025e810c126c8e7210b4f3f570

query I rowsort
SELECT ALL + col2 * - 18 AS col1 FROM tab0
----
-1476
-18
-594

query I rowsort
SELECT ALL tab1.col2 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT 75 * + cor1.col0 + cor0.col0 * - 69 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 500a66b22d8b063316c0ca448947de77

query I rowsort
SELECT col0 * + col2 + + col1 * - cor0.col0 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT ALL + 79 + cor0.col2 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-713
-7219
44

query I rowsort
SELECT - col2 + + col2 * + col0 AS col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT - cor0.col2 + cor0.col1 + + cor0.col1 FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT DISTINCT - 9 FROM tab1 cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
-9

query I rowsort
SELECT + + col2 + col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT col2 * 82 AS col2 FROM tab2 AS cor0
----
2132
2214
3116

query I rowsort
SELECT ALL + + 46 AS col1 FROM tab2 cor0
----
46
46
46

query I rowsort
SELECT - cor0.col0 + col2 * - col0 * + 63 FROM tab1 AS cor0
----
-10209
-229888
-483920

query I rowsort
SELECT - cor0.col1 + 53 * col1 FROM tab2 AS cor0
----
1612
3068
884

query I rowsort
SELECT + + col2 * - col0 * col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + + col2 * + 93 FROM tab1 AS cor0
----
5022
5301
8928

query I rowsort
SELECT DISTINCT - + col1 * - ( + col1 ) AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT + col2 * 40 AS col0 FROM tab1 cor0
----
2160
2280
3840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7011
SELECT DISTINCT col1 * + CAST( NULL AS SIGNED ) + col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7011
SELECT DISTINCT col1 * + CAST ( NULL AS INTEGER ) + col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col1 + + 49 * + col1 AS col0 FROM tab1 AS cor0
----
1248
480
624

query I rowsort
SELECT ALL + + cor0.col2 * + col2 + - 39 - col2 AS col2 FROM tab1 AS cor0
----
2823
3153
9081

query I rowsort
SELECT DISTINCT col0 + ( cor0.col2 ) * col2 AS col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT + + col1 * col2 + + col0 * + cor0.col0 AS col2 FROM tab2 cor0
----
6887
7618
886

query I rowsort
SELECT DISTINCT - col1 + ( + col2 ) * cor0.col0 FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7017
SELECT CAST( - col0 AS SIGNED ) + + col1 AS col1 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-7017
SELECT CAST ( - col0 AS INTEGER ) + + col1 AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL - ( cor0.col0 ) + col1 * 82 FROM tab1 AS cor0
----
2129
756
986

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 + + col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-7020
SELECT - 50 + cor0.col0 DIV col0 AS col1 FROM tab2 AS cor0
----
-49
-49
-49

skipif mysql # not compatible
query I rowsort label-7020
SELECT - 50 + cor0.col0 / col0 AS col1 FROM tab2 AS cor0
----
-49
-49
-49

query I rowsort
SELECT - - 94 - col2 FROM tab2 AS cor0
----
56
67
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 18 * - col2 col1 FROM tab1 AS cor0
----
-1026
-1728
-972

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7023
SELECT DISTINCT + 88 * + tab1.col0 * - col1 + + CAST( col1 AS SIGNED ) col1 FROM tab1
----
-56310
-6838
-91507

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7023
SELECT DISTINCT + 88 * + tab1.col0 * - col1 + + CAST ( col1 AS INTEGER ) col1 FROM tab1
----
-56310
-6838
-91507

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 * 7 col2 FROM tab0
----
-148
-532
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - tab2.col1 col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT ALL + + ( + col0 ) * ( col0 + col1 ) AS col1 FROM tab0 AS cor0
----
16020
2640
4620

query I rowsort
SELECT ALL + 40 * + 45 + + cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to aa1cdbddf6a59c98f20cc8bfe28085e3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * col0 col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - col2 * + 79 FROM tab2 AS cor0
----
-2054
-2133
-3002

query I rowsort
SELECT ALL 5 + + 80 FROM tab2, tab0 cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7031
SELECT DISTINCT - col0 / CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7031
SELECT DISTINCT - col0 / CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT ALL tab0.col0 * + col0 * - col2 AS col0 FROM tab0
----
-1225
-19008
-649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-7033
SELECT ALL tab0.col2 * col0 DIV col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7033
SELECT ALL tab0.col2 * col0 / col0 FROM tab0
----
1
33
82

query I rowsort
SELECT - col0 + - col1 * - col1 AS col0 FROM tab2 cor0
----
210
3403
954

query I rowsort
SELECT 97 * + tab1.col0 AS col0 FROM tab1
----
291
6208
7760

query I rowsort
SELECT ALL cor0.col0 AS col2 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT col1 * + col0 + tab2.col1 + - 19 AS col0 FROM tab2
----
1341
229
4642

query I rowsort
SELECT cor0.col1 * - 8 + + col2 AS col0 FROM tab1 AS cor0
----
-154
-23
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7039
SELECT ALL + col0 DIV col0 + - col1 * 60 FROM tab2 AS cor0
----
-1019
-1859
-3539

skipif mysql # not compatible
query I rowsort label-7039
SELECT ALL + col0 / col0 + - col1 * 60 FROM tab2 AS cor0
----
-1019
-1859
-3539

query I rowsort
SELECT DISTINCT + ( col2 ) * + col0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT - ( 13 ) FROM tab2
----
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-7042
SELECT DISTINCT 9 DIV col1 col1 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7042
SELECT DISTINCT 9 / col1 col1 FROM tab1
----
0

query I rowsort
SELECT ( 38 ) * - col1 AS col0 FROM tab1
----
-380
-494
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col0 + + 97 * - col2 col2 FROM tab1 AS cor0
----
-5241
-5593
-9392

query I rowsort
SELECT ALL + col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ( + cor0.col0 ) + - 44 FROM tab2 AS cor0
----
-37
34
35

query I rowsort
SELECT col2 * - col1 + - 34 FROM tab0 AS cor0
----
-131
-2872
-7496

skipif mysql # not compatible
query I rowsort
SELECT col2 * - col0 * CAST ( + col1 AS REAL ) + + col1 FROM tab2 AS cor0
----
-119593
-51017
-5828

onlyif mysql # use DIV operator for integer division
query I rowsort label-7049
SELECT ALL + cor0.col2 DIV col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-7049
SELECT ALL + cor0.col2 / col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT - col2 + + col0 * ( + col1 + - col0 ) AS col2 FROM tab2 AS cor0
----
-1508
-4936
141

query I rowsort
SELECT DISTINCT + 72 * col2 AS col2 FROM tab2 cor0
----
1872
1944
2736

query I rowsort
SELECT ALL - + 4 * + col0 FROM tab2 AS cor0
----
-28
-312
-316

query I rowsort
SELECT - 36 AS col1 FROM tab1 cor0
----
-36
-36
-36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col1 ) * + col1 + ( col0 ) col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT 46 + col0 FROM tab2 AS cor0
----
124
125
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-7056
SELECT col2 DIV - cor0.col1 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-7056
SELECT col2 / - cor0.col1 FROM tab2 AS cor0
----
-2
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7057
SELECT col2 * tab2.col2 DIV + 77 FROM tab2
----
18
8
9

skipif mysql # not compatible
query I rowsort label-7057
SELECT col2 * tab2.col2 / + 77 FROM tab2
----
18
8
9

query I rowsort
SELECT DISTINCT 51 FROM tab1, tab0 AS cor0
----
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-7059
SELECT + col0 DIV ( + col0 ) FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7059
SELECT + col0 / ( + col0 ) FROM tab1
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7060
SELECT - col1 DIV ( - col1 ) AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7060
SELECT - col1 / ( - col1 ) AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT + 51 FROM tab0, tab0 AS cor0
----
51

query I rowsort
SELECT DISTINCT - tab0.col2 * + 5 - - 7 * + col1 FROM tab0
----
227
437
674

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7063
SELECT - col1 + + CAST( - col1 AS SIGNED ) - col1 AS col2 FROM tab1
----
-30
-39
-78

skipif mysql # not compatible
query I rowsort label-7063
SELECT - col1 + + CAST ( - col1 AS INTEGER ) - col1 AS col2 FROM tab1
----
-30
-39
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7064
SELECT DISTINCT + col2 / + CAST( NULL AS SIGNED ) - + col1 * + col1 * - col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7064
SELECT DISTINCT + col2 / + CAST ( NULL AS INTEGER ) - + col1 * + col1 * - col2 FROM tab0
----
NULL

query I rowsort
SELECT 98 * - 72 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 07991f3c4cd1a1298b8273c13b13f645

query I rowsort
SELECT - col1 - + col2 * - 55 * col0 FROM tab0
----
1828
401299
43474

query I rowsort
SELECT - 32 FROM tab1, tab1 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

query I rowsort
SELECT 62 + - col1 * + col2 AS col2 FROM tab2 AS cor0
----
-1472
-584
-775

query I rowsort
SELECT + col0 * + ( - cor0.col1 ) FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7070
SELECT col0 * 66 + - col0 * cor0.col1 DIV + col2 AS col1 FROM tab1 AS cor0
----
197
4213
5270

skipif mysql # not compatible
query I rowsort label-7070
SELECT col0 * 66 + - col0 * cor0.col1 / + col2 AS col1 FROM tab1 AS cor0
----
197
4213
5270

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 8 col0 FROM tab0 AS cor0
----
8
8
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - - 63 col0 FROM tab1 AS cor0
----
73
76
89

query I rowsort
SELECT DISTINCT - cor0.col0 + - col2 * col2 + - col1 FROM tab1 AS cor0
----
-2945
-3323
-9309

onlyif mysql # use DIV operator for integer division
query I rowsort label-7074
SELECT ALL + 21 * col2 DIV + col0 + + 18 FROM tab0 AS cor0
----
18
37
46

skipif mysql # not compatible
query I rowsort label-7074
SELECT ALL + 21 * col2 / + col0 + + 18 FROM tab0 AS cor0
----
18
37
46

query I rowsort
SELECT ALL 92 + ( - col0 ) + col2 FROM tab0 AS cor0
----
101
58
85

query I rowsort
SELECT + ( col2 ) + ( col1 ) * - cor0.col1 FROM tab0 cor0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL 61 * + col2 AS col1 FROM tab0
----
2013
5002
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 19 col1 FROM tab2 AS cor0
----
19
19
19

query I rowsort
SELECT - cor0.col2 + - col0 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + ( + 95 ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + + col1 * col0 col0 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT 12 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT col2 * - 51 FROM tab2 AS cor0
----
-1326
-1377
-1938

query I rowsort
SELECT ALL + col1 * + 15 FROM tab0 AS cor0
----
1290
1365
1455

query I rowsort
SELECT - col2 + col0 * + 76 FROM tab2 AS cor0
----
505
5902
5966

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 col2 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT - - col0 * - 36 * - 61 FROM tab0 AS cor0
----
195444
52704
76860

query I rowsort
SELECT ALL - col1 * - 6 + cor0.col0 FROM tab2 AS cor0
----
181
193
432

query I rowsort
SELECT + + cor0.col0 * ( - col1 ) * + cor0.col0 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT ALL + ( + col0 ) * + ( ( col1 ) ) * ( tab1.col1 ) AS col0 FROM tab1
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + col1 col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - col2 + ( col1 ) * col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT cor0.col1 - col0 AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - col2 + - 56 * + cor0.col1 FROM tab0 AS cor0
----
-4849
-5178
-5433

query I rowsort
SELECT DISTINCT - col0 + + 56 FROM tab1 AS cor0
----
-24
-8
53

query I rowsort
SELECT ALL 64 + col0 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
2092
253
3066

query I rowsort
SELECT + 68 * - col0 FROM tab1 AS cor0
----
-204
-4352
-5440

query I rowsort
SELECT DISTINCT + 32 AS col2 FROM tab1, tab0 AS cor0
----
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 92 col0 FROM tab1 AS cor0
----
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-7100
SELECT - col0 DIV + col0 + - col1 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-7100
SELECT - col0 / + col0 + - col1 FROM tab2 AS cor0
----
-18
-32
-60

query I rowsort
SELECT ALL - 62 + cor0.col2 * + cor0.col1 FROM tab2 cor0
----
1472
584
775

query I rowsort
SELECT + col2 + - col0 * - ( - 23 * + col0 ) AS col0 FROM tab0 AS cor0
----
-13215
-182101
-28174

query I rowsort
SELECT ALL col1 * col0 + ( col1 ) FROM tab0
----
2150
3492
8190

query I rowsort
SELECT - - tab0.col2 * + tab0.col1 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 7623ebe74018211e6a4da91fc8c37d6d

query I rowsort
SELECT + col2 * col2 * col1 FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7106
SELECT DISTINCT 73 DIV col2 FROM tab0 AS cor0
----
0
2
73

skipif mysql # not compatible
query I rowsort label-7106
SELECT DISTINCT 73 / col2 FROM tab0 AS cor0
----
0
2
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7107
SELECT + CAST( col1 AS SIGNED ) col1 FROM tab1 cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7107
SELECT + CAST ( col1 AS INTEGER ) col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - - col2 * col0 + + cor0.col2 * + col2 AS col2 FROM tab1 AS cor0
----
16896
3078
6897

query I rowsort
SELECT DISTINCT - ( col0 ) + - col0 AS col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL col0 + - 99 - col0 FROM tab2 cor0
----
-99
-99
-99

query I rowsort
SELECT ALL - - col1 * + col1 + col2 * 82 AS col0 FROM tab0 cor0
----
10102
15005
9491

query I rowsort
SELECT DISTINCT + + 49 * col2 FROM tab1 AS cor0
----
2646
2793
4704

query I rowsort
SELECT cor0.col1 + cor0.col0 AS col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-7114
SELECT ALL + + cor0.col0 DIV col1 + col1 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-7114
SELECT ALL + + cor0.col0 / col1 + col1 FROM tab2 AS cor0
----
21
31
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-7115
SELECT ALL - - 46 * + cor0.col0 * col0 + 24 DIV + col1 AS col0 FROM tab1 AS cor0
----
188418
294401
414

skipif mysql # not compatible
query I rowsort label-7115
SELECT ALL - - 46 * + cor0.col0 * col0 + 24 / + col1 AS co