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 - 11 + col2 AS col0 FROM tab0 AS cor0
----
-10
22
71

query I rowsort
SELECT DISTINCT + 57 * col0 FROM tab1 AS cor0
----
171
3648
4560

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

query I rowsort
SELECT ALL col1 + + ( + tab0.col1 ) * col1 AS col2 FROM tab0
----
7482
8372
9506

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

query I rowsort
SELECT ALL 55 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-8
SELECT cor0.col1 DIV ( + 95 ) + col1 AS col1 FROM tab0 AS cor0
----
86
91
98

skipif mysql # not compatible
query I rowsort label-8
SELECT cor0.col1 / ( + 95 ) + col1 AS col1 FROM tab0 AS cor0
----
86
91
98

query I rowsort
SELECT - + cor0.col0 + - cor0.col0 * 86 * col2 AS col2 FROM tab1 AS cor0
----
-13935
-313792
-660560

query I rowsort
SELECT DISTINCT + - 99 + 85 + col2 AS col1 FROM tab1 cor0
----
40
43
82

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

query I rowsort
SELECT ALL + col0 + col1 * + col2 * col1 FROM tab1 AS cor0
----
16304
36507
5764

query I rowsort
SELECT ALL - col2 + col2 * + col1 * col2 FROM tab2 AS cor0
----
22572
24510
39858

query I rowsort
SELECT DISTINCT - 89 FROM tab1 cor0
----
-89

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

query I rowsort
SELECT DISTINCT 98 AS col0 FROM tab1 cor0
----
98

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col2 * - col0 + - cor0.col1 col2 FROM tab2 AS cor0
----
-2009
-213
-2940

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

query I rowsort
SELECT ALL + 32 - + col1 AS col2 FROM tab1 cor0
----
19
22
6

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

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

query I rowsort
SELECT tab1.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

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

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

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

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL NOT BETWEEN - col1 + col0 AND NULL
----

query I rowsort
SELECT ALL col1 * + cor0.col2 FROM tab1 AS cor0 WHERE NOT NULL <> NULL
----

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL 5 - + col2 FROM tab1
----
-49
-52
-91

query I rowsort
SELECT DISTINCT - col2 * col0 + tab2.col0 * - col1 + col1 AS col0 FROM tab2
----
-375
-4328
-6571

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

query I rowsort
SELECT - col1 + col0 * tab0.col0 FROM tab0
----
1128
490
7830

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

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

query I rowsort
SELECT ALL + tab1.col1 * + col0 * tab1.col0 + col0 FROM tab1
----
237
41024
83280

query I rowsort
SELECT - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

skipif mysql # not compatible
query I rowsort
SELECT col0 - + CAST ( col2 AS REAL ) FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL 5 AS col2 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col2 AS REAL ) FROM tab2
----
26
27
38

query I rowsort
SELECT - + col0 * 79 + cor0.col2 + - col2 * - col1 FROM tab0 cor0
----
-2667
513
975

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

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

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

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

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

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

query I rowsort
SELECT + 97 + + 79 * col1 AS col1 FROM tab0
----
6891
7286
7760

query I rowsort
SELECT - tab2.col2 + - col1 + - ( col2 ) FROM tab2
----
-111
-85
-93

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col1 * + col0 col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 + - ( cor0.col1 + col0 ) AS col1 FROM tab1 cor0
----
-20
-26
-52

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-61
SELECT DISTINCT col1 DIV col0 + + ( + 36 ) AS col1 FROM tab1 AS cor0
----
36
44

skipif mysql # not compatible
query I rowsort label-61
SELECT DISTINCT col1 / col0 + + ( + 36 ) AS col1 FROM tab1 AS cor0
----
36
44

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

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

skipif mysql # not compatible
query I rowsort label-63
SELECT ALL + + col1 / ( 7 ) AS col2 FROM tab1 AS cor0
----
1
1
3

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

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

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

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

query I rowsort
SELECT DISTINCT - - col1 * 46 AS col1 FROM tab1 AS cor0
----
1196
460
598

query I rowsort
SELECT + - col1 * col2 + 87 * - col2 FROM tab0 AS cor0
----
-14596
-184
-5709

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - cor0.col1 - + CAST ( col2 AS REAL ) AS col2 FROM tab2 AS cor0
----
-55
-58
-85

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-72
SELECT DISTINCT col1 DIV + col0 + col2 * col2 * col2 FROM tab0 AS cor0
----
3
35940
551369

skipif mysql # not compatible
query I rowsort label-72
SELECT DISTINCT col1 / + col0 + col2 * col2 * col2 FROM tab0 AS cor0
----
3
35940
551369

query I rowsort
SELECT ALL - + col0 + cor0.col0 * - 24 - + col0 FROM tab1 AS cor0
----
-1664
-2080
-78

query I rowsort
SELECT DISTINCT 84 + + col0 - col0 * - col0 FROM tab2
----
140
6246
6404

query I rowsort
SELECT ALL - 73 * + col1 AS col2 FROM tab2
----
-1241
-2263
-4307

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 13 * - col2 col1 FROM tab1
----
-1248
-702
-741

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

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

query I rowsort
SELECT - col2 + + ( col2 ) * + col2 * col1 AS col0 FROM tab2 AS cor0
----
22572
24510
39858

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

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

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

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

query I rowsort
SELECT 41 * 91 FROM tab0, tab2 AS cor0
----
9 values hashing to f844d64cac1899373f3f01b6715a9b7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col1 col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT ALL - col0 + col0 * cor0.col0 + + 38 AS col0 FROM tab0 cor0
----
1228
590
7870

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col2 ) * + col2 col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL - 90 + + cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 496bf2a6317b6d3f1a2b04ff7899c0ba

query I rowsort
SELECT DISTINCT ( col1 + col0 ) * - tab2.col1 AS col2 FROM tab2
----
-1178
-1632
-8083

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

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

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

query I rowsort
SELECT ALL + ( col2 ) * + col0 + + 3 FROM tab0 AS cor0
----
38
7301
795

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

query I rowsort
SELECT + 53 * col2 FROM tab1 AS cor0
----
2862
3021
5088

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-99
SELECT - col2 DIV - 57 + col1 * + 34 * col0 AS col2 FROM tab2
----
156468
45662
7378

skipif mysql # not compatible
query I rowsort label-99
SELECT - col2 / - 57 + col1 * + 34 * col0 AS col2 FROM tab2
----
156468
45662
7378

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

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

query I rowsort
SELECT + 71 + col1 * cor0.col2 AS col0 FROM tab1 AS cor0
----
1319
1475
641

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-104
SELECT DISTINCT CAST( 42 * col1 + + col0 AS SIGNED ) AS col1 FROM tab1
----
1095
484
626

skipif mysql # not compatible
query I rowsort label-104
SELECT DISTINCT CAST ( 42 * col1 + + col0 AS INTEGER ) AS col1 FROM tab1
----
1095
484
626

query I rowsort
SELECT - + 84 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 02f1688b8610806ca28739b1735f6ae4

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-107
SELECT - col1 + ( + col2 ) DIV - cor0.col1 AS col1 FROM tab1 AS cor0
----
-15
-20
-28

skipif mysql # not compatible
query I rowsort label-107
SELECT - col1 + ( + col2 ) / - cor0.col1 AS col1 FROM tab1 AS cor0
----
-15
-20
-28

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

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

query I rowsort
SELECT col0 * - 34 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1225
-3115
-840

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + 33 col1 FROM tab0 AS cor0
----
-49
0
32

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

query I rowsort
SELECT ALL - cor0.col1 + - col0 * - ( + col0 ) AS col2 FROM tab1 AS cor0
----
-17
4086
6387

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

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

skipif mysql # not compatible
query I rowsort label-120
SELECT cor0.col2 / - 97 + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + 73 + - tab1.col2 AS col1 FROM tab1
----
-23
16
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-122
SELECT DISTINCT col0 + + col2 * 15 DIV - col1 AS col1 FROM tab2
----
-6
46
72

skipif mysql # not compatible
query I rowsort label-122
SELECT DISTINCT col0 + + col2 * 15 / - col1 AS col1 FROM tab2
----
-6
46
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-123
SELECT ALL col2 DIV + col2 + ( tab1.col0 ) AS col1 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-123
SELECT ALL col2 / + col2 + ( tab1.col0 ) AS col1 FROM tab1
----
4
65
81

query I rowsort
SELECT ALL + ( col2 ) * - col1 * - col0 + - col1 - col0 AS col0 FROM tab0
----
3263
663938
68002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 96 - col1 * 23 col2 FROM tab2
----
-1261
-295
-617

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-126
SELECT ALL col1 / - col2 - - col0 col2 FROM tab0
----
-62
22
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-127
SELECT ALL - col1 DIV 23 + ( col0 ) * 74 FROM tab0
----
1773
2586
6583

skipif mysql # not compatible
query I rowsort label-127
SELECT ALL - col1 / 23 + ( col0 ) * 74 FROM tab0
----
1773
2586
6583

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

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

skipif mysql # not compatible
query I rowsort label-129
SELECT ALL + col0 + + CAST ( - col0 + - col0 AS INTEGER ) * ( col1 ) * - col2 FROM tab2 AS cor0
----
102147
11725
239382

query I rowsort
SELECT DISTINCT + + col0 * - col2 + col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

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

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

query I rowsort
SELECT ALL + cor0.col2 * - ( + 22 ) AS col2 FROM tab0 AS cor0
----
-1804
-22
-726

onlyif mysql # use DIV operator for integer division
query I rowsort label-134
SELECT + - col0 + - col0 DIV + 46 FROM tab0 AS cor0
----
-24
-35
-90

skipif mysql # not compatible
query I rowsort label-134
SELECT + - col0 + - col0 / + 46 FROM tab0 AS cor0
----
-24
-35
-90

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

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

query I rowsort
SELECT + col1 * 23 FROM tab2 AS cor0
----
1357
391
713

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

skipif mysql # not compatible
query I rowsort label-137
SELECT tab0.col0 + - col1 + - col1 / - col2 AS col2 FROM tab0
----
-1
-60
35

query I rowsort
SELECT DISTINCT + tab1.col2 + + 78 FROM tab1
----
132
135
174

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + 3 * - col2 * - col0 + - CAST ( - col1 AS REAL ) col2 FROM tab0 AS cor0
----
202
21985
2462

query I rowsort
SELECT DISTINCT - 71 + + cor0.col1 AS col0 FROM tab2, tab2 AS cor0
----
-12
-40
-54

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

query I rowsort
SELECT 99 AS col0 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

query I rowsort
SELECT + 80 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

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

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

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

query I rowsort
SELECT DISTINCT col1 * - cor0.col0 + col2 + - 67 * - 20 AS col1 FROM tab0 cor0
----
-2054
-6677
-691

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

query I rowsort
SELECT + 21 * + cor0.col2 FROM tab0 AS cor0
----
1722
21
693

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

query I rowsort
SELECT cor0.col1 * cor0.col0 - + 13 FROM tab2, tab1 AS cor0
----
9 values hashing to 582f9de58e3053ef2b7136f16ce62fe9

onlyif mysql # use DIV operator for integer division
query I rowsort label-151
SELECT DISTINCT - ( + col1 ) DIV + ( col1 ) AS col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-151
SELECT DISTINCT - ( + col1 ) / + ( col1 ) AS col0 FROM tab0 AS cor0
----
-1

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

query I rowsort
SELECT + - 51 * col2 FROM tab2 AS cor0
----
-1326
-1377
-1938

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

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

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

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

query I rowsort
SELECT + col2 - - col1 * 7 FROM tab1 AS cor0
----
127
187
236

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

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

query I rowsort
SELECT - - col2 * ( col2 ) * + col2 - + 29 * - col2 AS col0 FROM tab0 AS cor0
----
30
36894
553746

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

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

query I rowsort
SELECT + + col1 + col2 * 20 + cor0.col1 FROM tab2 AS cor0
----
602
638
794

query I rowsort
SELECT - - col0 - - col2 * - 23 FROM tab2 AS cor0
----
-520
-614
-795

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

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

skipif mysql # not compatible
query I rowsort label-164
SELECT - + col1 + - cor0.col2 / - 39 FROM tab1 AS cor0
----
-11
-25
-9

query I rowsort
SELECT + col1 * - col2 + + ( 99 ) FROM tab1 AS cor0
----
-1149
-1305
-471

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

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

query I rowsort
SELECT 7 + col2 AS col2 FROM tab1 AS cor0
----
103
61
64

query I rowsort
SELECT + 80 * - col2 FROM tab0
----
-2640
-6560
-80

query I rowsort
SELECT ALL - 27 * + cor0.col1 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to d43cb5ec49d07ed28abf45a3dad5bd4d

query I rowsort
SELECT - col2 * + 43 FROM tab1
----
-2322
-2451
-4128

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-174
SELECT + col1 + - col0 DIV - 54 FROM tab1 AS cor0
----
11
14
26

skipif mysql # not compatible
query I rowsort label-174
SELECT + col1 + - col0 / - 54 FROM tab1 AS cor0
----
11
14
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-175
SELECT DISTINCT + - 17 DIV col0 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-175
SELECT DISTINCT + - 17 / col0 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL 46 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-177
SELECT DISTINCT + - col2 + CAST( col0 AS SIGNED ) * - col2 * - 40 FROM tab2 cor0
----
120042
7533
81094

skipif mysql # not compatible
query I rowsort label-177
SELECT DISTINCT + - col2 + CAST ( col0 AS INTEGER ) * - col2 * - 40 FROM tab2 cor0
----
120042
7533
81094

query I rowsort
SELECT 49 FROM tab0, tab0 cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to e587c122dea39a2488ff88b884cea462

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

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

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

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

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

query I rowsort
SELECT DISTINCT + - col1 + + col1 - 21 * - col0 * col2 FROM tab2 AS cor0
----
3969
42588
63042

query I rowsort
SELECT ALL - 26 FROM tab1, tab1 AS cor0
----
9 values hashing to 47d0574274146de273829785364ada39

query I rowsort
SELECT + ( 11 ) + col0 * + col0 AS col1 FROM tab0
----
1236
587
7932

query I rowsort
SELECT + col2 * + 85 AS col2 FROM tab2 cor0
----
2210
2295
3230

query I rowsort
SELECT + tab0.col0 * + cor0.col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to aeeeb4bec4be16eaf92fcfb414a1ef1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 61 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT + + 57 * col0 - col2 AS col2 FROM tab0 cor0
----
1335
1994
4991

query I rowsort
SELECT DISTINCT + 11 + + col2 * + col1 FROM tab2 AS cor0
----
1545
657
848

query I rowsort
SELECT 64 * - cor0.col1 - 71 FROM tab2 cor0
----
-1159
-2055
-3847

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

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

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

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

query I rowsort
SELECT - + 83 - col2 FROM tab2 AS cor0
----
-109
-110
-121

onlyif mysql # use DIV operator for integer division
query I rowsort label-196
SELECT DISTINCT ( + col2 ) - col2 DIV col2 AS col2 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-196
SELECT DISTINCT ( + col2 ) - col2 / col2 AS col2 FROM tab1 AS cor0
----
53
56
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-197
SELECT DISTINCT col0 * - col1 + - col2 DIV 5 AS col1 FROM tab2 AS cor0
----
-1350
-222
-4607

skipif mysql # not compatible
query I rowsort label-197
SELECT DISTINCT col0 * - col1 + - col2 / 5 AS col1 FROM tab2 AS cor0
----
-1350
-222
-4607

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

query I rowsort
SELECT + 8 FROM tab0, tab2, tab0 AS cor0, tab1
----
81 values hashing to a42c42e56e75960d97c09dd731d99c01

query I rowsort
SELECT - tab1.col2 + - 21 FROM tab1
----
-117
-75
-78

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-201
SELECT - col2 - CAST ( NULL AS INTEGER ) col1 FROM tab0
----
NULL
NULL
NULL

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-203
SELECT + col1 * ( col0 ) + col0 DIV col2 col2 FROM tab1
----
1040
641
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-203
SELECT + col1 * ( col0 ) + col0 / col2 col2 FROM tab1
----
1040
641
78

query I rowsort
SELECT tab0.col0 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * 47 col1 FROM tab1 AS cor0
----
1222
470
611

onlyif mysql # use DIV operator for integer division
query I rowsort label-207
SELECT - - col1 DIV col1 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-207
SELECT - - col1 / col1 FROM tab1 cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-208
SELECT + - col2 * CAST( ( col0 ) AS SIGNED ) * - 47 FROM tab2 AS cor0
----
141094
8883
95316

skipif mysql # not compatible
query I rowsort label-208
SELECT + - col2 * CAST ( ( col0 ) AS INTEGER ) * - 47 FROM tab2 AS cor0
----
141094
8883
95316

query I rowsort
SELECT DISTINCT - + ( col1 ) * cor0.col0 - 63 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-6320
-658
-9516

query I rowsort
SELECT - col0 * 95 AS col2 FROM tab1 AS cor0
----
-285
-6080
-7600

query I rowsort
SELECT DISTINCT 30 + 67 FROM tab2 AS cor0
----
97

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

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

query I rowsort
SELECT ALL - - col0 * + 7 FROM tab2 AS cor0
----
49
546
553

query I rowsort
SELECT col2 * - 22 AS col1 FROM tab0 AS cor0
----
-1804
-22
-726

onlyif mysql # use DIV operator for integer division
query I rowsort label-216
SELECT ALL + + ( - cor0.col1 ) * col0 + col1 DIV + 77 col0 FROM tab0 AS cor0
----
-2063
-3394
-8098

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-216
SELECT ALL + + ( - cor0.col1 ) * col0 + col1 / + 77 col0 FROM tab0 AS cor0
----
-2063
-3394
-8098

query I rowsort
SELECT + col2 * 99 AS col0 FROM tab2 AS cor0
----
2574
2673
3762

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

query I rowsort
SELECT DISTINCT - 93 FROM tab1, tab1 cor0
----
-93

query I rowsort
SELECT col2 + 13 FROM tab2
----
39
40
51

query I rowsort
SELECT DISTINCT - 89 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-63
-76
-79

query I rowsort
SELECT ALL 71 - + col2 FROM tab1 AS cor0
----
-25
14
17

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * tab1.col1 + - 15 * + col1 + + col2 * + col1 col1 FROM tab1
----
1060
1092
2093

query I rowsort
SELECT DISTINCT 11 * - col0 + + 33 FROM tab2
----
-44
-825
-836

query I rowsort
SELECT DISTINCT + col0 + col1 * col0 * + 67 FROM tab1
----
42944
5229
69760

query I rowsort
SELECT 47 * + col0 + + col2 * cor0.col1 FROM tab1 AS cor0
----
1545
3578
5008

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col0 * + col0 + + col1 * col0 AS col1 FROM tab1 AS cor0
----
-3456
-5360
69

query I rowsort
SELECT ALL + col1 - 30 FROM tab0 AS cor0
----
56
61
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 42 col1 FROM tab1 AS cor0
----
-1092
-420
-546

query I rowsort
SELECT ALL col0 * ( - 88 ) * cor0.col2 AS col0 FROM tab2 AS cor0
----
-16632
-178464
-264176

query I rowsort
SELECT + col2 + col2 * col1 + tab1.col0 FROM tab1
----
1424
1461
691

query I rowsort
SELECT col0 * col2 + 71 * col0 AS col2 FROM tab1
----
13360
375
8192

query I rowsort
SELECT - 23 * - tab1.col1 - + 8 * + col1 FROM tab1
----
150
195
390

query I rowsort
SELECT DISTINCT + 50 + col0 FROM tab1 AS cor0
----
114
130
53

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-246
SELECT ALL - 57 DIV - col0 FROM tab2 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-246
SELECT ALL - 57 / - col0 FROM tab2 AS cor0
----
0
0
8

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

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

query I rowsort
SELECT DISTINCT + col1 * 63 FROM tab1 AS cor0
----
1638
630
819

query I rowsort
SELECT + col2 + + ( col2 * col2 ) FROM tab0 AS cor0
----
1122
2
6806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 65 ) * col2 * cor0.col2 col0 FROM tab0 AS cor0
----
437060
65
70785

query I rowsort
SELECT DISTINCT + col1 * + cor0.col2 + col0 * col0 + col1 AS col1 FROM tab0 AS cor0
----
1419
15474
3500

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

query I rowsort
SELECT - - col0 + 88 - col0 AS col2 FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT DISTINCT 17 + - col2 AS col2 FROM tab0 AS cor0
----
-16
-65
16

query I rowsort
SELECT ALL ( col2 ) + - col0 * 71 AS col1 FROM tab1 AS cor0
----
-159
-4487
-5584

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

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

query I rowsort
SELECT DISTINCT - 3 * + col1 FROM tab0 cor0
----
-258
-273
-291

query I rowsort
SELECT ( + cor0.col1 ) AS col2 FROM tab0 AS cor0
----
86
91
97

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

query I rowsort
SELECT ( 88 ) * - col0 FROM tab0
----
-2112
-3080
-7832

query I rowsort
SELECT - 29 * col0 + - tab2.col2 FROM tab2
----
-2288
-230
-2329

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

query I rowsort
SELECT col2 + cor0.col1 - - 82 FROM tab2 AS cor0
----
137
140
167

query I rowsort
SELECT + 12 * col2 + ( - col1 ) FROM tab0 AS cor0
----
-85
310
893

onlyif mysql # use DIV operator for integer division
query I rowsort label-267
SELECT - 38 DIV - cor0.col0 FROM tab1 AS cor0
----
0
0
12

skipif mysql # not compatible
query I rowsort label-267
SELECT - 38 / - cor0.col0 FROM tab1 AS cor0
----
0
0
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-268
SELECT col0 + - col0 DIV - ( + ( col1 ) ) FROM tab1 cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-268
SELECT col0 + - col0 / - ( + ( col1 ) ) FROM tab1 cor0
----
3
70
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-269
SELECT ( + col1 ) + ( col0 ) DIV col0 - 69 * ( - col2 ) FROM tab2 AS cor0
----
1854
1895
2640

skipif mysql # not compatible
query I rowsort label-269
SELECT ( + col1 ) + ( col0 ) / col0 - 69 * ( - col2 ) FROM tab2 AS cor0
----
1854
1895
2640

query I rowsort
SELECT - 10 FROM tab2, tab0 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

onlyif mysql # use DIV operator for integer division
query I rowsort label-271
SELECT col2 + - 96 DIV - col1 AS col0 FROM tab0
----
1
34
83

skipif mysql # not compatible
query I rowsort label-271
SELECT col2 + - 96 / - col1 AS col0 FROM tab0
----
1
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-272
SELECT ALL - col1 + + col0 DIV col1 FROM tab2
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-272
SELECT ALL - col1 + + col0 / col1 FROM tab2
----
-13
-31
-58

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

query I rowsort
SELECT DISTINCT - + col1 * + cor0.col0 + - 50 * + col0 AS col2 FROM tab2 AS cor0
----
-5293
-567
-8502

query I rowsort
SELECT + 83 - col1 FROM tab1 cor0
----
57
70
73

query I rowsort
SELECT DISTINCT - 71 + + col0 * + ( col2 * col0 ) AS col2 FROM tab0 cor0
----
1154
18937
649451

onlyif mysql # use DIV operator for integer division
query I rowsort label-277
SELECT DISTINCT - + col1 + col2 + cor0.col2 DIV cor0.col0 FROM tab0 AS cor0
----
-52
-9
-96

skipif mysql # not compatible
query I rowsort label-277
SELECT DISTINCT - + col1 + col2 + cor0.col2 / cor0.col0 FROM tab0 AS cor0
----
-52
-9
-96

query I rowsort
SELECT - 43 + + col0 FROM tab2 cor0
----
-36
35
36

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

query I rowsort
SELECT cor0.col1 + cor0.col1 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 1a063bfb694f348122cd0739295ca641

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

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

query I rowsort
SELECT + col2 * - 32 FROM tab2 AS cor0
----
-1216
-832
-864

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

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

query I rowsort
SELECT + col2 * - col0 + 29 AS col0 FROM tab2
----
-160
-1999
-2973

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-287
SELECT DISTINCT + CAST ( NULL AS INTEGER ) col1 FROM tab0 cor0 CROSS JOIN tab2, tab1 cor1, tab2 AS cor2
----
NULL

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-289
SELECT DISTINCT ( 75 + col0 ) DIV - col2 AS col0 FROM tab1
----
-1
-2

skipif mysql # not compatible
query I rowsort label-289
SELECT DISTINCT ( 75 + col0 ) / - col2 AS col0 FROM tab1
----
-1
-2

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

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

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

query I rowsort
SELECT ALL + - cor0.col1 + - col1 + + col0 FROM tab0 AS cor0
----
-148
-159
-93

query I rowsort
SELECT cor1.col0 AS col1 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT - col1 * 8 * - col2 FROM tab1 AS cor0
----
11232
4560
9984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * ( col2 ) + 85 col2 FROM tab2 AS cor0
----
1529
761
814

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

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

query I rowsort
SELECT col1 + ( col1 ) + - col0 AS col2 FROM tab1
----
-44
-54
49

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

query I rowsort
SELECT - col0 + - 11 FROM tab2 AS cor0
----
-18
-89
-90

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

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

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

query I rowsort
SELECT 94 FROM tab2, tab0 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

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

query I rowsort
SELECT col0 * 66 * + ( tab0.col2 ) AS col0 FROM tab0
----
2310
481668
52272

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

query I rowsort
SELECT - ( col1 ) + + col1 * + ( - 98 ) FROM tab1
----
-1287
-2574
-990

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

query I rowsort
SELECT - ( - col0 * col2 + + col1 * col2 ) FROM tab0
----
-164
-2046
-62

query I rowsort
SELECT DISTINCT + - col0 + col0 * col0 AS col1 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT + col1 * + 34 * - col2 AS col1 FROM tab0 AS cor0
----
-253708
-3298
-96492

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-314
SELECT DISTINCT + ( col2 ) DIV + 47 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-314
SELECT DISTINCT + ( col2 ) / + 47 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort
SELECT ALL + - col2 * CAST ( col2 AS REAL ) + + cor0.col2 FROM tab0 AS cor0
----
-1056
-6642
0

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

query I rowsort
SELECT + cor0.col1 + + col0 * 22 AS col2 FROM tab2 AS cor0
----
1755
1775
185

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

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

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

query I rowsort
SELECT + col1 - + 39 FROM tab0
----
47
52
58

query I rowsort
SELECT DISTINCT cor0.col2 + ( 51 ) AS col2 FROM tab2 AS cor0
----
77
78
89

query I rowsort
SELECT DISTINCT - col0 * + 2 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT cor0.col0 * - cor0.col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 064f0d12f5a54890818030ba889e7e5c

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 * col2 + - col0 * col2 / CAST ( cor0.col0 AS REAL ) AS col1 FROM tab0 AS cor0
----
0
1056
6642

skipif mysql # not compatible
query I rowsort
SELECT ALL - col2 + + CAST ( + col2 AS REAL ) * col0 FROM tab2 AS cor0
----
162
2002
2964

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

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

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

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

query I rowsort
SELECT col1 + 86 + col1 AS col2 FROM tab2
----
120
148
204

query I rowsort
SELECT DISTINCT - col0 + 69 AS col1 FROM tab0
----
-20
34
45

query I rowsort
SELECT 93 * tab2.col2 + + 50 FROM tab2, tab2 AS cor0
----
9 values hashing to 8f349018a31bc84a8fb564744e4a2dbc

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-334
SELECT DISTINCT - - col0 * col2 * - CAST( col0 AS SIGNED ) + + col0 FROM tab0 cor0
----
-1190
-18984
-649433

skipif mysql # not compatible
query I rowsort label-334
SELECT DISTINCT - - col0 * col2 * - CAST ( col0 AS INTEGER ) + + col0 FROM tab0 cor0
----
-1190
-18984
-649433

query I rowsort
SELECT ALL col0 + col2 * - col1 - - 2 FROM tab1 AS cor0
----
-1166
-1399
-504

onlyif mysql # use DIV operator for integer division
query I rowsort label-336
SELECT DISTINCT col1 DIV + col0 + 44 - col2 AS col0 FROM tab2 AS cor0
----
18
21
6

skipif mysql # not compatible
query I rowsort label-336
SELECT DISTINCT col1 / + col0 + 44 - col2 AS col0 FROM tab2 AS cor0
----
18
21
6

query I rowsort
SELECT ALL - col1 * - col0 + - 22 * + col2 FROM tab2 AS cor0
----
-377
4030
507

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

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

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

query I rowsort
SELECT ALL + tab0.col1 * + col0 + - 54 AS col0 FROM tab0
----
2010
3341
8045

onlyif mysql # use DIV operator for integer division
query I rowsort label-342
SELECT ALL - 83 DIV + 81 col1 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-342
SELECT ALL - 83 / + 81 col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT ALL - 49 FROM tab1
----
-49
-49
-49

query I rowsort
SELECT + 73 * + col2 FROM tab0
----
2409
5986
73

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

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

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

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

query I rowsort
SELECT ALL - 26 + + col0 FROM tab1 AS cor0
----
-23
38
54

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

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

query I rowsort
SELECT tab2.col2 * col1 - 97 * + col2 AS col1 FROM tab2
----
-1782
-3040
-988

query I rowsort
SELECT + tab0.col2 + - 93 * 63 FROM tab0, tab0 AS cor0
----
9 values hashing to f5105f7430630048e6c38259e1354739

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-352
SELECT ALL 3 * + col0 * CAST( + 18 AS SIGNED ) AS col1 FROM tab1
----
162
3456
4320

skipif mysql # not compatible
query I rowsort label-352
SELECT ALL 3 * + col0 * CAST ( + 18 AS INTEGER ) AS col1 FROM tab1
----
162
3456
4320

query I rowsort
SELECT ALL + ( col0 ) * + 35 + 98 AS col2 FROM tab0 AS cor0
----
1323
3213
938

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 * + 72 * - col2 col0 FROM tab1 AS cor0
----
-101062
-41030
-89843

query I rowsort
SELECT DISTINCT - + 47 + cor0.col0 FROM tab1 AS cor0
----
-44
17
33

query I rowsort
SELECT + col1 * 80 FROM tab0 AS cor0
----
6880
7280
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-358
SELECT ALL + cor0.col1 * 64 DIV + 16 col2 FROM tab2 AS cor0
----
124
236
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-358
SELECT ALL + cor0.col1 * 64 / + 16 col2 FROM tab2 AS cor0
----
124
236
68

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

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

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

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

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

query I rowsort
SELECT ALL - cor0.col1 * - cor0.col1 - ( col2 ) AS col2 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT ALL col1 * 75 AS col0 FROM tab0 AS cor0
----
6450
6825
7275

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-365
SELECT ALL + col0 + + ( 44 ) * cor0.col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
133
68
79

skipif mysql # not compatible
query I rowsort label-365
SELECT ALL + col0 + + ( 44 ) * cor0.col0 / + col0 AS col0 FROM tab0 AS cor0
----
133
68
79

skipif mysql # not compatible
query I rowsort
SELECT ALL + cor0.col2 * - CAST ( col0 AS REAL ) + + col0 AS col2 FROM tab0 cor0
----
-7209
-768
0

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

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

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

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

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

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

query I rowsort
SELECT - 86 + col2 AS col1 FROM tab2 AS cor0
----
-48
-59
-60

query I rowsort
SELECT DISTINCT + 61 + col2 * col2 AS col2 FROM tab1
----
2977
3310
9277

onlyif mysql # use DIV operator for integer division
query I rowsort label-375
SELECT DISTINCT + col2 DIV + 19 + - col0 + col0 * col2 FROM tab0
----
0
7213
769

skipif mysql # not compatible
query I rowsort label-375
SELECT DISTINCT + col2 / + 19 + - col0 + col0 * col2 FROM tab0
----
0
7213
769

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

query I rowsort
SELECT col2 + + tab1.col1 * + tab1.col1 FROM tab1
----
157
265
730

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

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

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-382
SELECT col1 + + col2 / - col0 col1 FROM tab1 AS cor0
----
10
12
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-383
SELECT - col2 * + col1 DIV + col1 + col1 * col1 FROM tab0 AS cor0
----
7363
8199
9408

skipif mysql # not compatible
query I rowsort label-383
SELECT - col2 * + col1 / + col1 + col1 * col1 FROM tab0 AS cor0
----
7363
8199
9408

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

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0, tab0 AS cor0, tab0 cor1
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col1 + 18 col0 FROM tab2 cor0
----
1552
664
855

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

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

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

query I rowsort
SELECT DISTINCT + 15 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
104
39
50

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 20 * cor0.col2 col1 FROM tab0 AS cor0
----
1640
20
660

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

query I rowsort
SELECT 14 * + col1 AS col0 FROM tab1 cor0
----
140
182
364

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

query I rowsort
SELECT DISTINCT - col2 * ( + 88 ) FROM tab2
----
-2288
-2376
-3344

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

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

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

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

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

query I rowsort
SELECT - + 44 * - col1 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-149380
-356356
-90816

query I rowsort
SELECT - ( 77 ) * - col2 FROM tab2 AS cor0
----
2002
2079
2926

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

query I rowsort
SELECT DISTINCT + 38 * - ( col1 ) * 44 + - col1 * - col2 AS col2 FROM tab0 cor0
----
-140954
-144690
-162087

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-405
SELECT + 68 DIV 76 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-405
SELECT + 68 / 76 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 89 * - col1 AS col0 FROM tab2 AS cor0
----
1513
2759
5251

query I rowsort
SELECT DISTINCT + 42 + - 42 FROM tab2 AS cor0
----
0

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

query I rowsort
SELECT ALL 19 * cor0.col0 FROM tab2 AS cor0
----
133
1482
1501

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

query I rowsort
SELECT DISTINCT - ( + col2 ) * col0 + - 78 + + ( + col0 ) FROM tab1 AS cor0
----
-237
-3662
-7678

query I rowsort
SELECT + - 69 + col1 * + cor0.col1 FROM tab2 cor0
----
220
3412
892

query I rowsort
SELECT ALL + 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-414
SELECT CAST( 70 AS SIGNED ) * - col1 AS col2 FROM tab0 AS cor0
----
-6020
-6370
-6790

skipif mysql # not compatible
query I rowsort label-414
SELECT CAST ( 70 AS INTEGER ) * - col1 AS col2 FROM tab0 AS cor0
----
-6020
-6370
-6790

query I rowsort
SELECT DISTINCT 29 - ( cor0.col2 ) * + 50 * - col2 FROM tab1 AS cor0
----
145829
162479
460829

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-416
SELECT CAST( + 45 AS SIGNED ) * + col0 AS col0 FROM tab2
----
315
3510
3555

skipif mysql # not compatible
query I rowsort label-416
SELECT CAST ( + 45 AS INTEGER ) * + col0 AS col0 FROM tab2
----
315
3510
3555

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

query I rowsort
SELECT DISTINCT 46 AS col2 FROM tab0 cor0
----
46

query I rowsort
SELECT ALL + 61 * 68 AS col2 FROM tab2 AS cor0
----
4148
4148
4148

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + 73 * - col0 col1 FROM tab2 AS cor0
----
-538
-5720
-5805

query I rowsort
SELECT - col2 * 79 AS col0 FROM tab2 AS cor0
----
-2054
-2133
-3002

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

query I rowsort
SELECT DISTINCT + 57 + col1 FROM tab2 AS cor0
----
116
74
88

query I rowsort
SELECT ALL 67 * col1 * ( - col0 ) FROM tab0 AS cor0
----
-138288
-227465
-542633

query I rowsort
SELECT DISTINCT + - 33 * - col2 FROM tab2 AS cor0
----
1254
858
891

query I rowsort
SELECT ALL 19 * + col2 + tab0.col2 FROM tab0
----
1640
20
660

query I rowsort
SELECT ALL + 13 + col2 * - col0 AS col2 FROM tab1
----
-149
-3635
-7667

query I rowsort
SELECT ALL col1 * - 8 FROM tab2 AS cor0
----
-136
-248
-472

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

query I rowsort
SELECT ALL + - col0 + ( col1 + + col2 * - col1 ) FROM tab1 AS cor0
----
-1315
-1381
-624

onlyif mysql # use DIV operator for integer division
query I rowsort label-432
SELECT ALL - col0 DIV 75 FROM tab2 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-432
SELECT ALL - col0 / 75 FROM tab2 cor0
----
-1
-1
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 + - tab0.col2 col2 FROM tab0
----
-80
29
61

query I rowsort
SELECT DISTINCT col1 * - col1 + col2 AS col2 FROM tab0
----
-7363
-8199
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-436
SELECT tab0.col0 + - col0 DIV + col2 FROM tab0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-436
SELECT tab0.col0 + - col0 / + col2 FROM tab0
----
0
24
88

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

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

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

query I rowsort
SELECT + col0 + col0 - 18 FROM tab1 AS cor0
----
-12
110
142

query I rowsort
SELECT cor0.col0 + ( + 24 ) AS col2 FROM tab2 AS cor0
----
102
103
31

query I rowsort
SELECT DISTINCT - col1 + ( - 11 ) FROM tab2 AS cor0
----
-28
-42
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-443
SELECT col2 + - col2 DIV - col0 + - col2 * - col0 col2 FROM tab2
----
2054
219
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-443
SELECT col2 + - col2 / - col0 + - col2 * - col0 col2 FROM tab2
----
2054
219
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-444
SELECT DISTINCT - col1 * CAST( 36 AS SIGNED ) + col0 DIV - CAST( - 36 AS SIGNED ) FROM tab0
----
-3096
-3274
-3492

skipif mysql # not compatible
query I rowsort label-444
SELECT DISTINCT - col1 * CAST ( 36 AS INTEGER ) + col0 / - CAST ( - 36 AS INTEGER ) FROM tab0
----
-3096
-3274
-3492

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - 89 * col0 col2 FROM tab1
----
-241
-5686
-7107

onlyif mysql # use DIV operator for integer division
query I rowsort label-447
SELECT DISTINCT - - col2 * col2 DIV cor0.col1 FROM tab2 AS cor0
----
11
23
84

skipif mysql # not compatible
query I rowsort label-447
SELECT DISTINCT - - col2 * col2 / cor0.col1 FROM tab2 AS cor0
----
11
23
84

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * 48 + 14 * + tab1.col0 + - tab1.col0 col0 FROM tab1
----
-1904
-2553
-3568

onlyif mysql # use DIV operator for integer division
query I rowsort label-453
SELECT col0 DIV + 89 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-453
SELECT col0 / + 89 FROM tab1 cor0
----
0
0
0

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

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

skipif mysql # not compatible
query I rowsort label-455
SELECT col2 + + 68 / - col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + - col2 * - 92 FROM tab1 AS cor0
----
4968
5244
8832

onlyif mysql # use DIV operator for integer division
query I rowsort label-457
SELECT + tab1.col0 * col2 DIV + ( col0 ) AS col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-457
SELECT + tab1.col0 * col2 / + ( col0 ) AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT + col0 * ( 14 ) + col1 AS col1 FROM tab1
----
1133
68
906

query I rowsort
SELECT - tab0.col0 + 40 FROM tab0
----
-49
16
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-460
SELECT ALL - CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-460
SELECT ALL - CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

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

query I rowsort
SELECT - col0 + - ( - col1 * - col0 + col1 * col0 ) AS col0 FROM tab2
----
-2765
-441
-9282

query I rowsort
SELECT DISTINCT 15 + - col1 FROM tab2
----
-16
-2
-44

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-465
SELECT - tab2.col2 DIV 52 + col2 * ( col2 ) FROM tab2
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-465
SELECT - tab2.col2 / 52 + col2 * ( col2 ) FROM tab2
----
1444
676
729

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) * col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-469
SELECT DISTINCT + 89 DIV tab0.col1 FROM tab0, tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-469
SELECT DISTINCT + 89 / tab0.col1 FROM tab0, tab1 AS cor0
----
0
1

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

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

query I rowsort
SELECT + 63 + col1 * col2 * + 70 FROM tab2
----
107443
45283
58653

query I rowsort
SELECT - 72 * - col1 + col0 AS col1 FROM tab0
----
6216
6641
7019

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

query I rowsort
SELECT + 14 * col2 + + col1 AS col2 FROM tab2 AS cor0
----
409
423
549

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

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

query I rowsort
SELECT + + col2 * col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

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

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

query I rowsort
SELECT - - 69 * col1 AS col0 FROM tab0 AS cor0
----
5934
6279
6693

query I rowsort
SELECT ALL + 18 + col2 FROM tab1 AS cor0
----
114
72
75

query I rowsort
SELECT DISTINCT + 21 + + col1 * + ( cor0.col1 ) AS col0 FROM tab0 AS cor0
----
7417
8302
9430

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

query I rowsort
SELECT ALL + 4 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

query I rowsort
SELECT ALL - 54 * 89 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 79b7ac0af63dcebb7b1f72f17578206d

onlyif mysql # use DIV operator for integer division
query I rowsort label-485
SELECT ALL 97 * col1 DIV col0 AS col1 FROM tab2 AS cor0
----
20
429
73

skipif mysql # not compatible
query I rowsort label-485
SELECT ALL 97 * col1 / col0 AS col1 FROM tab2 AS cor0
----
20
429
73

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-489
SELECT DISTINCT - 34 * col1 - col2 DIV + col0 FROM tab1 AS cor0
----
-340
-443
-902

skipif mysql # not compatible
query I rowsort label-489
SELECT DISTINCT - 34 * col1 - col2 / + col0 FROM tab1 AS cor0
----
-340
-443
-902

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

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

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

query I rowsort
SELECT - col0 * 56 AS col2 FROM tab2 AS cor0
----
-392
-4368
-4424

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-495
SELECT ALL + 80 * + col0 DIV col0 - + ( + col2 ) * + cor0.col2 FROM tab1 AS cor0
----
-2836
-3169
-9136

skipif mysql # not compatible
query I rowsort label-495
SELECT ALL + 80 * + col0 / col0 - + ( + col2 ) * + cor0.col2 FROM tab1 AS cor0
----
-2836
-3169
-9136

query I rowsort
SELECT ALL - + ( 70 ) + cor0.col1 - + 79 * - ( col0 ) FROM tab2 AS cor0
----
514
6151
6188

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-498
SELECT DISTINCT CAST( NULL AS DECIMAL ) / 96 AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-498
SELECT DISTINCT CAST ( NULL AS REAL ) / 96 AS col1 FROM tab1
----
NULL

query I rowsort
SELECT ALL + cor0.col2 + - 91 * 23 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 378f6b6cebaa9699274427339fe628d9

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

skipif mysql # not compatible
query I rowsort label-500
SELECT col2 * col2 / col0 AS col1 FROM tab2
----
104
18
8

query I rowsort
SELECT + + col2 + + col2 - col1 AS col0 FROM tab2 AS cor0
----
-7
23
59

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

skipif mysql # not compatible
query I rowsort label-502
SELECT - col0 + - 80 + col0 / - CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 11 + ( + col2 ) - - col2 AS col1 FROM tab1 AS cor0
----
119
125
203

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-506
SELECT + 24 * - col2 * col0 + - CAST( + col0 AS SIGNED ) - col1 AS col2 FROM tab1 AS cor0
----
-184413
-3917
-87626

skipif mysql # not compatible
query I rowsort label-506
SELECT + 24 * - col2 * col0 + - CAST ( + col0 AS INTEGER ) - col1 AS col2 FROM tab1 AS cor0
----
-184413
-3917
-87626

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

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

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

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

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

query III rowsort
SELECT ALL * FROM tab0 WHERE ( NULL ) > NULL
----

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

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

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

query I rowsort
SELECT DISTINCT + col0 FROM tab0 WHERE NOT + col2 < NULL
----

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

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

query III rowsort
SELECT * FROM tab1 WHERE NULL > col0 - + col2
----

query I rowsort
SELECT col0 FROM tab2 WHERE NULL = NULL
----

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

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

query I rowsort
SELECT DISTINCT tab2.col2 * col1 - col1 * + col2 FROM tab2
----
0

query I rowsort
SELECT col2 FROM tab1 WHERE - col1 * col2 / col2 IN ( tab1.col2 )
----

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

query I rowsort
SELECT DISTINCT tab2.col0 AS col2 FROM tab2 WHERE + col2 / col1 IN ( + col2 )
----

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

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

query I rowsort
SELECT + col2 + col1 * tab0.col0 + + col0 FROM tab0
----
2121
3431
8270

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

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

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

query I rowsort
SELECT col1 * col2 * col2 + col2 - + col0 * - tab2.col0 AS col2 FROM tab2
----
22675
30827
45994

query I rowsort
SELECT ALL col0 + col1 + + col1 FROM tab0
----
196
229
271

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

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

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

skipif mysql # not compatible
query I rowsort label-536
SELECT cor0.col2 + + col1 / col0 FROM tab0 AS cor0
----
3
36
83

query I rowsort
SELECT ALL col0 FROM tab2 AS cor0 WHERE ( + col2 ) = - col0 * col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * 75 + + col0 col0 FROM tab1
----
-4047
-4211
-7120

query I rowsort
SELECT 0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-543
SELECT DISTINCT - cor0.col2 - col2 * - col1 / cor0.col1 AS col1 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-544
SELECT - col0 DIV - 50 + 13 FROM tab2 cor0
----
13
14
14

skipif mysql # not compatible
query I rowsort label-544
SELECT - col0 / - 50 + 13 FROM tab2 cor0
----
13
14
14

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

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

query I rowsort
SELECT DISTINCT - cor0.col0 + - 1 AS col2 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT ALL 17 * + col2 * col0 FROM tab1 AS cor0
----
130560
2754
62016

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

query I rowsort
SELECT ALL col2 - + col0 * col0 * + ( col1 ) AS col0 FROM tab0 AS cor0
----
-118824
-49503
-720729

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0, tab1 cor1, tab0 cor2
----
972 values hashing to 43f0c51511c8642d19190fd4dfcf905a

query I rowsort
SELECT + col0 * - col1 * - col2 + + col2 AS col1 FROM tab1
----
36537
4266
99936

query I rowsort
SELECT ALL 72 * - cor0.col1 FROM tab0 AS cor0
----
-6192
-6552
-6984

onlyif mysql # use DIV operator for integer division
query I rowsort label-553
SELECT ALL + CAST( - 46 AS SIGNED ) DIV + col1 + ( - col1 * + col2 ) FROM tab2 AS cor0
----
-1534
-648
-838

skipif mysql # not compatible
query I rowsort label-553
SELECT ALL + CAST ( - 46 AS INTEGER ) / + col1 + ( - col1 * + col2 ) FROM tab2 AS cor0
----
-1534
-648
-838

query I rowsort
SELECT DISTINCT - col1 * - 43 * + col0 + - 94 FROM tab1 AS cor0
----
27426
3260
44626

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

query I rowsort
SELECT DISTINCT + 53 + + col1 AS col0 FROM tab2 AS cor0
----
112
70
84

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

query I rowsort
SELECT + + col1 * + col0 - col2 * + col0 * col0 AS col1 FROM tab2 cor0
----
-1106
-153582
-235815

query I rowsort
SELECT ALL - - col1 + 40 FROM tab1 AS cor0
----
50
53
66

query I rowsort
SELECT + + col2 - - col0 * 8 AS col0 FROM tab1 AS cor0
----
569
736
78

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

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

query I rowsort
SELECT ALL 15 * col0 + col2 FROM tab0 AS cor0
----
1417
393
526

onlyif mysql # use DIV operator for integer division
query I rowsort label-564
SELECT ALL 98 DIV + col2 + - col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-564
SELECT ALL 98 / + col2 + - col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

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

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

query I rowsort
SELECT 22 AS col0 FROM tab0
----
22
22
22

query I rowsort
SELECT ALL - 66 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT + + cor0.col2 * - col1 + - cor0.col1 * cor0.col1 * - ( col2 ) AS col1 FROM tab2 AS cor0
----
10336
25110
88972

query I rowsort
SELECT DISTINCT - col2 + col1 * - cor0.col2 + + 21 * col0 AS col2 FROM tab2 AS cor0
----
-717
78
975

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

query I rowsort
SELECT ALL 91 * col1 + - col0 * - col1 AS col1 FROM tab2 cor0
----
2890
3038
9971

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

query I rowsort
SELECT DISTINCT + + 35 - col0 AS col2 FROM tab0 AS cor0
----
-54
0
11

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

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

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

query I rowsort
SELECT ALL - cor0.col0 * 14 AS col0 FROM tab0 AS cor0
----
-1246
-336
-490

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

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

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

query I rowsort
SELECT DISTINCT col0 * 47 AS col1 FROM tab0 AS cor0
----
1128
1645
4183

query I rowsort
SELECT - col1 * 93 FROM tab2 AS cor0
----
-1581
-2883
-5487

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

query I rowsort
SELECT - col0 * - 58 FROM tab2 AS cor0
----
406
4524
4582

onlyif mysql # use DIV operator for integer division
query I rowsort label-583
SELECT DISTINCT - col0 + + col1 * col2 + col2 DIV 45 FROM tab0
----
2814
62
7374

skipif mysql # not compatible
query I rowsort label-583
SELECT DISTINCT - col0 + + col1 * col2 + col2 / 45 FROM tab0
----
2814
62
7374

query I rowsort
SELECT col0 * + 86 AS col2 FROM tab1
----
258
5504
6880

query I rowsort
SELECT + tab0.col2 + col1 * - col1 + + tab0.col0 AS col0 FROM tab0
----
-7339
-8110
-9373

query I rowsort
SELECT + 38 * cor0.col1 AS col1 FROM tab0 AS cor0
----
3268
3458
3686

query I rowsort
SELECT 4 * - col1 FROM tab1 AS cor0
----
-104
-40
-52

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-589
SELECT - col2 DIV + 76 + - 34 col0 FROM tab0
----
-34
-34
-35

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-589
SELECT - col2 / + 76 + - 34 col0 FROM tab0
----
-34
-34
-35

query I rowsort
SELECT DISTINCT + col0 * + 89 FROM tab2
----
623
6942
7031

query I rowsort
SELECT ALL + col0 * + 94 AS col1 FROM tab2
----
658
7332
7426

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

query I rowsort
SELECT 54 * + 32 + col0 + + cor0.col0 FROM tab1 AS cor0
----
1734
1856
1888

query I rowsort
SELECT col1 * + 44 FROM tab0
----
3784
4004
4268

query I rowsort
SELECT col1 * - 48 AS col0 FROM tab2
----
-1488
-2832
-816

onlyif mysql # use DIV operator for integer division
query I rowsort label-596
SELECT ALL col2 DIV + 28 FROM tab1
----
1
2
3

skipif mysql # not compatible
query I rowsort label-596
SELECT ALL col2 / + 28 FROM tab1
----
1
2
3

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-598
SELECT ALL col2 DIV 17 FROM tab2
----
1
1
2

skipif mysql # not compatible
query I rowsort label-598
SELECT ALL col2 / 17 FROM tab2
----
1
1
2

query I rowsort
SELECT + ( cor0.col1 ) + - col2 * - ( cor0.col0 ) * - col1 AS col1 FROM tab2 AS cor0
----
-119593
-51017
-5828

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-601
SELECT ALL CAST( col0 AS SIGNED ) * col0 FROM tab0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-601
SELECT ALL CAST ( col0 AS INTEGER ) * col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - 59 + - col2 AS col2 FROM tab2
----
-85
-86
-97

query I rowsort
SELECT DISTINCT col0 * 77 + + tab1.col2 FROM tab1
----
285
4985
6256

query I rowsort
SELECT ALL - 81 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to d0bfe8494f52235d9fcafb5ac5de3f81

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

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

query I rowsort
SELECT - tab1.col2 * + cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 5c440a304f6abc2ed68f0784f7d7d3bf

query I rowsort
SELECT DISTINCT col0 * + col0 * + col0 + - col0 + col1 FROM tab1 AS cor0
----
262090
50
511933

query I rowsort
SELECT - ( + col1 * 59 + + 60 ) AS col1 FROM tab0
----
-5134
-5429
-5783

query I rowsort
SELECT - col1 + - 56 AS col1 FROM tab0 AS cor0
----
-142
-147
-153

query I rowsort
SELECT - 76 - + 60 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 08f97f97b745950752b9b99b9639317a

query I rowsort
SELECT 47 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT - - col1 * - cor0.col0 - + ( - col1 ) * - col1 FROM tab0 AS cor0
----
-12804
-16380
-9460

query I rowsort
SELECT - + col2 * - cor0.col2 * - ( col2 * 17 ) - + col1 * col0 AS col0 FROM tab1 AS cor0
----
-15041552
-2676966
-3148921

query I rowsort
SELECT col2 * - 77 + + col0 AS col2 FROM tab1 cor0
----
-4155
-4325
-7312

onlyif mysql # use DIV operator for integer division
query I rowsort label-615
SELECT - + col2 DIV + 18 AS col0 FROM tab2 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-615
SELECT - + col2 / + 18 AS col0 FROM tab2 AS cor0
----
-1
-1
-2

query I rowsort
SELECT - col2 * 69 + + col1 - col1 AS col2 FROM tab1 AS cor0
----
-3726
-3933
-6624

query I rowsort
SELECT - col1 * ( 86 ) AS col1 FROM tab1 AS cor0
----
-1118
-2236
-860

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

query I rowsort
SELECT + 12 AS col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 - col2 * + tab0.col0 * - col2 col0 FROM tab0
----
26160
598525
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 53 + 7 col1 FROM tab2, tab1 cor0, tab2 cor1
----
27 values hashing to 5a5d45989dcc6a06d9ee5a08945518f9

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

query I rowsort
SELECT DISTINCT col2 * col1 + - 46 - + 66 * - col1 * - cor0.col2 AS col2 FROM tab1 cor0
----
-37096
-81166
-91306

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - 20 col2 FROM tab0 AS cor0
----
1720
1820
1940

query I rowsort
SELECT + + col0 * + 74 AS col2 FROM tab1 AS cor0
----
222
4736
5920

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-628
SELECT ALL + col1 * - CAST ( cor0.col0 AS INTEGER ) + cor0.col1 FROM tab1 cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT + col1 * - 46 FROM tab0 AS cor0
----
-3956
-4186
-4462

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

query I rowsort
SELECT ALL cor0.col0 - 36 AS col2 FROM tab0 AS cor0
----
-1
-12
53

query I rowsort
SELECT ALL + + col2 + + 51 FROM tab1 cor0
----
105
108
147

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

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

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

query I rowsort
SELECT ALL - ( + col1 ) + - ( 95 ) * - col1 AS col1 FROM tab1
----
1222
2444
940

query I rowsort
SELECT ALL - col0 + tab1.col0 * col0 AS col0 FROM tab1
----
4032
6
6320

query I rowsort
SELECT ( 20 ) + + col1 * col1 FROM tab0 AS cor0
----
7416
8301
9429

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

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

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

query I rowsort
SELECT ALL - ( 59 ) * + col1 AS col0 FROM tab1 AS cor0
----
-1534
-590
-767

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

query I rowsort
SELECT cor0.col1 + + 99 * col2 AS col0 FROM tab2 AS cor0
----
2633
2704
3779

query I rowsort
SELECT - 27 + - cor0.col1 * + col0 FROM tab1 AS cor0
----
-105
-1067
-667

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 69 col1 FROM tab0, tab1 cor0
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

query I rowsort
SELECT - col2 * col2 + tab0.col2 AS col2 FROM tab0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT col1 - + 78 * - col0 AS col2 FROM tab2
----
577
6143
6179

query I rowsort
SELECT col1 + tab2.col1 * col1 * 76 - - ( - col1 ) AS col0 FROM tab2
----
21964
264556
73036

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

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

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

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

query I rowsort
SELECT DISTINCT col0 + + cor0.col0 * 85 * + col1 FROM tab1 cor0
----
54464
6633
88480

onlyif mysql # use DIV operator for integer division
query I rowsort label-653
SELECT ALL + col1 + col0 + col0 DIV cor0.col0 FROM tab1 AS cor0
----
30
75
94

skipif mysql # not compatible
query I rowsort label-653
SELECT ALL + col1 + col0 + col0 / cor0.col0 FROM tab1 AS cor0
----
30
75
94

query I rowsort
SELECT ALL + col1 * col1 + + 50 FROM tab1
----
150
219
726

query I rowsort
SELECT 87 * + col0 AS col0 FROM tab2
----
609
6786
6873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + + col2 + + col0 col1 FROM tab2 AS cor0
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col2 * col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT cor0.col1 * - col2 + 99 + - 49 * col0 * col2 AS col0 FROM tab2 AS cor0
----
-100807
-147645
-9999

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

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

query I rowsort
SELECT ALL + col0 * - col0 + col1 AS col1 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT - 20 FROM tab1 cor0
----
-20
-20
-20

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

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

query I rowsort
SELECT ALL tab0.col2 + - ( + col2 ) AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * + ( col0 ) + + col0 * col0 AS col0 FROM tab1 AS cor0
----
4736
7440
87

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

skipif mysql # not compatible
query I rowsort label-667
SELECT ALL col1 / cor0.col0 - col0 AS col2 FROM tab1 cor0
----
-64
-80
5

query I rowsort
SELECT ALL + col1 + ( ( cor0.col2 ) ) * col2 AS col0 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT ALL col2 + cor0.col1 * 49 - - col2 * col0 AS col1 FROM tab0 AS cor0
----
11839
4789
5039

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

query I rowsort
SELECT DISTINCT col0 + + 33 FROM tab0 AS cor0
----
122
57
68

query I rowsort
SELECT tab1.col1 * col1 + 77 * col1 FROM tab1
----
1170
2678
870

query I rowsort
SELECT ALL 59 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 22 * cor0.col2 col0 FROM tab1 AS cor0
----
-1188
-1254
-2112

onlyif mysql # use DIV operator for integer division
query I rowsort label-675
SELECT col2 + + cor0.col0 DIV - col2 AS col0 FROM tab0 AS cor0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-675
SELECT col2 + + cor0.col0 / - col2 AS col0 FROM tab0 AS cor0
----
-34
33
81

query I rowsort
SELECT ALL - col2 + + 1 + col1 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
1153
1351
514

query I rowsort
SELECT ALL + ( - 9 ) * - col1 + col0 FROM tab2 cor0
----
232
286
609

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

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

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

query I rowsort
SELECT DISTINCT + 23 + - cor0.col0 + col0 * ( + col1 ) FROM tab2 AS cor0
----
1287
233
4547

query I rowsort
SELECT ALL 1 + - col1 + 10 * col2 * - col1 FROM tab2 AS cor0
----
-15398
-6476
-8400

query I rowsort
SELECT DISTINCT + 90 + col2 AS col1 FROM tab0 AS cor0
----
123
172
91

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

query I rowsort
SELECT - col1 * col2 * + ( - col2 ) + col0 AS col0 FROM tab1 AS cor0
----
119888
32554
75819

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

query I rowsort
SELECT DISTINCT 45 + - col0 FROM tab2 AS cor0
----
-33
-34
38

query I rowsort
SELECT ALL - + col2 + cor0.col0 + + 1 AS col2 FROM tab2 AS cor0
----
-19
42
53

query I rowsort
SELECT - 49 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

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

query I rowsort
SELECT DISTINCT - ( col2 ) * col2 + + col0 + + col2 AS col0 FROM tab1
----
-2859
-3128
-9040

query I rowsort
SELECT 65 * - cor0.col0 FROM tab2, tab1 cor0
----
9 values hashing to ae25c919704741460cde5aa94bd634f2

query I rowsort
SELECT DISTINCT ( + col1 ) * col2 * tab1.col2 + - col1 AS col0 FROM tab1
----
119795
32480
75790

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

query I rowsort
SELECT ALL - col0 * + col0 + col1 FROM tab0 AS cor0
----
-1128
-490
-7830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-696
SELECT + CAST( - 41 AS SIGNED ) - - cor0.col1 FROM tab2 AS cor0
----
-10
-24
18

skipif mysql # not compatible
query I rowsort label-696
SELECT + CAST ( - 41 AS INTEGER ) - - cor0.col1 FROM tab2 AS cor0
----
-10
-24
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-697
SELECT + ( col0 ) * col1 DIV - col1 - 89 FROM tab0 AS cor0
----
-113
-124
-178

skipif mysql # not compatible
query I rowsort label-697
SELECT + ( col0 ) * col1 / - col1 - 89 FROM tab0 AS cor0
----
-113
-124
-178

query I rowsort
SELECT ALL - - 10 + + 23 AS col1 FROM tab2 AS cor0
----
33
33
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col1 + - tab0.col1 + - col0 col0 FROM tab0
----
-7506
-8461
-9541

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

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

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

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

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

query I rowsort
SELECT DISTINCT col2 * col1 - + col2 * + col1 * - 77 AS col1 FROM tab2 cor0
----
119652
50388
65286

query I rowsort
SELECT ALL + 63 + col0 * - cor0.col2 - col1 AS col0 FROM tab0 AS cor0
----
-69
-7326
-815

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-707
SELECT ALL - 11 * col2 * + 49 + + col2 * - col2 * + CAST( + col0 AS SIGNED ) FROM tab2 cor0
----
-134558
-19656
-66742

skipif mysql # not compatible
query I rowsort label-707
SELECT ALL - 11 * col2 * + 49 + + col2 * - col2 * + CAST ( + col0 AS INTEGER ) FROM tab2 cor0
----
-134558
-19656
-66742

query I rowsort
SELECT DISTINCT - + 21 - - col0 FROM tab1 cor0
----
-18
43
59

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

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

query I rowsort
SELECT col2 - col1 * 17 FROM tab1 AS cor0
----
-113
-125
-388

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

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

query I rowsort
SELECT 36 * + col0 AS col1 FROM tab2
----
252
2808
2844

query I rowsort
SELECT tab2.col0 * 55 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to b19fd216dfa330e434e3d951022bc36d

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

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

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

query I rowsort
SELECT DISTINCT col0 * + col0 * - col0 FROM tab1
----
-262144
-27
-512000

query I rowsort
SELECT ALL 53 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

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

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

query I rowsort
SELECT + - cor0.col0 + 65 * + col0 FROM tab2 AS cor0
----
448
4992
5056

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

query I rowsort
SELECT 27 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

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

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

skipif mysql # not compatible
query I rowsort label-726
SELECT ALL - col0 / - col1 AS col1 FROM tab1
----
0
6
6

query I rowsort
SELECT - 63 FROM tab1 cor0
----
-63
-63
-63

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-730
SELECT 86 DIV 27 FROM tab1 AS cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-730
SELECT 86 / 27 FROM tab1 AS cor0
----
3
3
3

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

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

query I rowsort
SELECT + col0 * 54 AS col1 FROM tab1
----
162
3456
4320

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-734
SELECT + col1 DIV 25 col1 FROM tab1
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-734
SELECT + col1 / 25 col1 FROM tab1
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 33 - 77 * tab2.col2 col0 FROM tab2
----
-1848
-319
572

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

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

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

query I rowsort
SELECT + ( + col0 ) * - col2 * col2 AS col1 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT ALL + + 38 FROM tab1 cor0
----
38
38
38

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-742
SELECT 27 DIV - col2 + col1 * 68 * + col2 FROM tab1 AS cor0
----
38760
84864
95472

skipif mysql # not compatible
query I rowsort label-742
SELECT 27 / - col2 + col1 * 68 * + col2 FROM tab1 AS cor0
----
38760
84864
95472

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-743
SELECT ALL - CAST( col2 AS SIGNED ) * - col0 * 49 col2 FROM tab0 AS cor0
----
1715
357602
38808

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-743
SELECT ALL - CAST ( col2 AS INTEGER ) * - col0 * 49 col2 FROM tab0 AS cor0
----
1715
357602
38808

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

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

skipif mysql # not compatible
query I rowsort label-745
SELECT - CAST ( - 14 AS INTEGER ) FROM tab1 AS cor0
----
14
14
14

query I rowsort
SELECT + ( col0 ) * - col0 - 81 * col1 FROM tab0 AS cor0
----
-15292
-7542
-9082

onlyif mysql # use DIV operator for integer division
query I rowsort label-747
SELECT col2 * col2 + - col2 DIV + col2 FROM tab1 AS cor0
----
2915
3248
9215

skipif mysql # not compatible
query I rowsort label-747
SELECT col2 * col2 + - col2 / + col2 FROM tab1 AS cor0
----
2915
3248
9215

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-752
SELECT ALL + + ( 35 ) DIV col2 + - 87 FROM tab1 AS cor0
----
-87
-87
-87

skipif mysql # not compatible
query I rowsort label-752
SELECT ALL + + ( 35 ) / col2 + - 87 FROM tab1 AS cor0
----
-87
-87
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-753
SELECT + col0 DIV 37 + col2 FROM tab0 AS cor0
----
1
33
84

skipif mysql # not compatible
query I rowsort label-753
SELECT + col0 / 37 + col2 FROM tab0 AS cor0
----
1
33
84

query I rowsort
SELECT DISTINCT 15 * - col2 AS col1 FROM tab1 AS cor0
----
-1440
-810
-855

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

query I rowsort
SELECT - 83 - col0 AS col2 FROM tab1
----
-147
-163
-86

query I rowsort
SELECT - 6 * + col1 FROM tab0 AS cor0
----
-516
-546
-582

query I rowsort
SELECT - col2 * col2 + col0 * + cor0.col2 + - col1 AS col2 FROM tab2 AS cor0
----
-571
1293
1541

query I rowsort
SELECT 87 * - col1 * - col0 FROM tab2 AS cor0
----
116841
18879
400374

query I rowsort
SELECT + 5 * + col2 FROM tab1 AS cor0
----
270
285
480

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

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

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

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

query I rowsort
SELECT + 45 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

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

query I rowsort
SELECT DISTINCT + col1 * col2 * 70 AS col2 FROM tab2 AS cor0
----
107380
45220
58590

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

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

query I rowsort
SELECT DISTINCT cor0.col2 + + col2 + + ( col2 * 31 ) FROM tab1 AS cor0
----
1782
1881
3168

query I rowsort
SELECT ALL - col0 * 54 FROM tab0 AS cor0
----
-1296
-1890
-4806

query I rowsort
SELECT - 51 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 27bcc31433ce90833ed76619cbd8d6a4

onlyif mysql # use DIV operator for integer division
query I rowsort label-771
SELECT col0 DIV col1 + - col0 FROM tab1
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-771
SELECT col0 / col1 + - col0 FROM tab1
----
-3
-58
-74

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + ( col2 ) col2 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * col1 + 74 col1 FROM tab1 cor0
----
174
243
750

query I rowsort
SELECT col1 * - tab0.col2 + 2 * + col1 * 25 FROM tab0
----
-2912
1462
4753

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-778
SELECT col2 * 21 DIV - 42 FROM tab1 cor0
----
-27
-28
-48

skipif mysql # not compatible
query I rowsort label-778
SELECT col2 * 21 / - 42 FROM tab1 cor0
----
-27
-28
-48

query IIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab0, tab2 cor1
----
243 values hashing to ce53c0e8839c969b0513568da6eb2c4b

query I rowsort
SELECT + col2 * 67 FROM tab0
----
2211
5494
67

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

query I rowsort
SELECT DISTINCT + - cor0.col1 * - col1 AS col2 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-783
SELECT - ( col0 ) DIV - 29 + col1 * cor0.col1 FROM tab1 AS cor0
----
102
171
676

skipif mysql # not compatible
query I rowsort label-783
SELECT - ( col0 ) / - 29 + col1 * cor0.col1 FROM tab1 AS cor0
----
102
171
676

query I rowsort
SELECT + 33 + col1 * 76 * 97 FROM tab2
----
125357
228565
434981

query I rowsort
SELECT col0 + cor0.col0 + - ( + col2 + col2 * - col0 ) FROM tab0 AS cor0
----
104
7394
807

query I rowsort
SELECT DISTINCT - col2 + + col0 + 32 AS col1 FROM tab2
----
12
73
84

query I rowsort
SELECT 9 * col1 FROM tab2
----
153
279
531

query I rowsort
SELECT - tab2.col1 * - 12 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 26fdf305ff6a398050c9cff846877117

query I rowsort
SELECT ALL - 96 AS col0 FROM tab1 AS cor0
----
-96
-96
-96

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

query I rowsort
SELECT + 95 + - col1 * + col0 - + col1 AS col1 FROM tab0 AS cor0
----
-2055
-3397
-8095

query I rowsort
SELECT DISTINCT 55 AS col2 FROM tab0, tab0 AS cor0
----
55

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

query I rowsort
SELECT ALL + 9 FROM tab1, tab0 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

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

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

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

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

query I rowsort
SELECT ALL 68 AS col1 FROM tab1 cor0
----
68
68
68

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

skipif mysql # not compatible
query I rowsort
SELECT cor0.col2 * col1 - - CAST ( - col2 + cor0.col1 AS REAL ) AS col2 FROM tab0 AS cor0
----
193
2891
7471

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col1 * - 81 col2 FROM tab1 AS cor0
----
-2052
-753
-957

query I rowsort
SELECT DISTINCT - col1 * - col0 * 53 AS col0 FROM tab2
----
11501
243906
71179

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

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

skipif mysql # not compatible
query I rowsort label-806
SELECT - 54 / + 78 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * 54 + - 62 * col0 FROM tab2 AS cor0
----
-1650
-3980
1240

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - 74 ) col1 FROM tab1
----
74

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

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

skipif mysql # not compatible
query I rowsort label-811
SELECT ALL CAST ( - col0 AS INTEGER ) + - cor0.col2 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-815
SELECT DISTINCT ( - 63 ) DIV col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-815
SELECT DISTINCT ( - 63 ) / col1 AS col0 FROM tab0
----
0

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

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

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

skipif mysql # not compatible
query I rowsort label-818
SELECT col1 / + 22 FROM tab2 AS cor0
----
0
1
2

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

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

query I rowsort
SELECT cor0.col1 + + 61 FROM tab1 AS cor0
----
71
74
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-822
SELECT ALL - col1 DIV + col1 - col0 col0 FROM tab1
----
-4
-65
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-822
SELECT ALL - col1 / + col1 - col0 col0 FROM tab1
----
-4
-65
-81

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

skipif mysql # not compatible
query I rowsort label-823
SELECT - + cor0.col1 - col1 * CAST ( - col0 * col1 AS INTEGER ) FROM tab2 AS cor0
----
22814
271459
6696

query I rowsort
SELECT col1 * col2 + 24 AS col1 FROM tab1 AS cor0
----
1272
1428
594

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-829
SELECT + col1 * + CAST ( ( col0 ) AS INTEGER ) + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col2 * + 4 AS col2 FROM tab0 cor0
----
132
328
4

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

query I rowsort
SELECT 57 + + col0 * col0 * + col0 AS col2 FROM tab2 cor0
----
400
474609
493096

query I rowsort
SELECT - col1 * 41 AS col2 FROM tab1 AS cor0
----
-1066
-410
-533

query I rowsort
SELECT - - 24 * col1 FROM tab1 AS cor0
----
240
312
624

query I rowsort
SELECT + - 97 FROM tab2 cor0
----
-97
-97
-97

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

skipif mysql # not compatible
query I rowsort label-836
SELECT DISTINCT CAST ( NULL AS REAL ) AS col2 FROM tab2, tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 97 AS col2 FROM tab1, tab0 AS cor0
----
97

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

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

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NULL BETWEEN NULL AND NULL
----

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

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

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

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

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

query I rowsort
SELECT - col2 + - col2 + + col1 * - col0 FROM tab0
----
-2130
-3397
-8263

query I rowsort
SELECT col2 + + col1 * + col1 * col1 AS col1 FROM tab1
----
1057
17630
2293

query I rowsort
SELECT ALL col0 + col0 FROM tab0 cor0 WHERE NOT col1 NOT IN ( col1 + cor0.col0 / col0 + col0 )
----

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

query I rowsort
SELECT + col1 AS col1 FROM tab2 cor0 WHERE NOT NULL <= - col0
----

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-854
SELECT DISTINCT - col0 + col2 DIV col1 FROM tab2
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-854
SELECT DISTINCT - col0 + col2 / col1 FROM tab2
----
-7
-77
-78

query I rowsort
SELECT - col0 * - col0 * - tab2.col0 AS col0 FROM tab2
----
-343
-474552
-493039

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

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

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

query I rowsort
SELECT - - col1 + + col0 * col0 * - col0 FROM tab2 AS cor0
----
-312
-474493
-493022

query I rowsort
SELECT ALL + cor0.col2 + cor0.col1 + col2 * col2 AS col1 FROM tab2 AS cor0
----
1499
761
787

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - col1 * + col1 col1 FROM tab2 AS cor0
----
-272
-3422
-930

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

skipif mysql # not compatible
query I rowsort label-863
SELECT DISTINCT cor0.col2 * col0 / + col0 AS col1 FROM tab1 AS cor0
----
54
57
96

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

query I rowsort
SELECT col1 * col2 + + col0 + col1 AS col1 FROM tab0 AS cor0
----
229
2948
7642

query I rowsort
SELECT 86 + tab1.col2 FROM tab1
----
140
143
182

onlyif mysql # use DIV operator for integer division
query I rowsort label-867
SELECT ALL + 85 DIV col1 + 21 AS col1 FROM tab0
----
21
21
21

skipif mysql # not compatible
query I rowsort label-867
SELECT ALL + 85 / col1 + 21 AS col1 FROM tab0
----
21
21
21

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

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

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

query I rowsort
SELECT DISTINCT col2 * col0 + + 0 + 7 FROM tab2 AS cor0
----
196
2035
3009

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

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

query I rowsort
SELECT + 3 * col2 + 18 * col1 FROM tab0 AS cor0
----
1647
1749
1884

query I rowsort
SELECT ALL + 97 * col1 * - 52 FROM tab2 AS cor0
----
-156364
-297596
-85748

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

query I rowsort
SELECT DISTINCT + col2 * 70 + + col2 AS col0 FROM tab2 AS cor0
----
1846
1917
2698

query I rowsort
SELECT - - cor0.col0 * - cor0.col2 + - 79 AS col2 FROM tab2 cor0
----
-2107
-268
-3081

query I rowsort
SELECT ALL + col1 + - 45 FROM tab1 AS cor0
----
-19
-32
-35

query I rowsort
SELECT + col1 + ( 42 ) FROM tab0 AS cor0
----
128
133
139

query I rowsort
SELECT ALL - col0 + + cor0.col0 * col0 * - col1 FROM tab1 AS cor0
----
-237
-41024
-83280

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

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

query I rowsort
SELECT ALL + col0 + 67 FROM tab2 AS cor0
----
145
146
74

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-886
SELECT DISTINCT + col2 * ( ( col1 ) ) DIV - 48 FROM tab0 cor0
----
-155
-2
-59

skipif mysql # not compatible
query I rowsort label-886
SELECT DISTINCT + col2 * ( ( col1 ) ) / - 48 FROM tab0 cor0
----
-155
-2
-59

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

query I rowsort
SELECT DISTINCT - ( + col1 ) + col1 * tab0.col2 AS col1 FROM tab0
----
0
2752
7371

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 37 * - col2 + 59 * - col2 col2 FROM tab1
----
-5184
-5472
-9216

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

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

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

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

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

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

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

query I rowsort
SELECT + col0 * + col1 * + col1 + col2 AS col0 FROM tab1
----
13616
2082
6457

query I rowsort
SELECT DISTINCT col1 * col1 + col2 - - col0 FROM tab1
----
221
345
733

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

query I rowsort
SELECT + col1 + + col2 + col2 AS col0 FROM tab0
----
152
255
99

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT col0 + col2 + col1 FROM tab0
----
133
143
262

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

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

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

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

query I rowsort
SELECT col0 * - col1 + - col2 + - tab1.col2 AS col2 FROM tab1
----
-1232
-186
-754

query I rowsort
SELECT ALL + + col1 * 23 AS col1 FROM tab2 AS cor0
----
1357
391
713

query I rowsort
SELECT - col1 * - 25 FROM tab2 AS cor0
----
1475
425
775

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

query I rowsort
SELECT + col0 + + 88 AS col1 FROM tab0 AS cor0
----
112
123
177

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

query I rowsort
SELECT ALL + col2 * 14 AS col2 FROM tab0 AS cor0
----
1148
14
462

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

query I rowsort
SELECT ALL 42 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * 58 + cor0.col1 col1 FROM tab2, tab2 cor0
----
9 values hashing to 357693b172d59024ea9037c9f7541e99

query I rowsort
SELECT col2 * 88 AS col2 FROM tab0 AS cor0
----
2904
7216
88

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

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

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

query I rowsort
SELECT + - col2 * - col2 + + cor0.col1 FROM tab0 AS cor0
----
1175
6815
98

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 90 + col1 * + col2 col1 FROM tab2
----
1444
556
747

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 # use DIV operator for integer division
query I rowsort label-931
SELECT ALL + 7 + col0 + - tab1.col2 DIV col0 AS col1 FROM tab1
----
-8
71
86

skipif mysql # not compatible
query I rowsort label-931
SELECT ALL + 7 + col0 + - tab1.col2 / col0 AS col1 FROM tab1
----
-8
71
86

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

query I rowsort
SELECT DISTINCT - ( col0 ) + - 48 AS col1 FROM tab1 AS cor0
----
-112
-128
-51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 99 * col0 col2 FROM tab0
----
-2376
-3465
-8811

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-936
SELECT DISTINCT - col0 + + 79 DIV - col0 AS col2 FROM tab0 AS cor0
----
-27
-37
-89

skipif mysql # not compatible
query I rowsort label-936
SELECT DISTINCT - col0 + + 79 / - col0 AS col2 FROM tab0 AS cor0
----
-27
-37
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-937
SELECT - + col1 DIV 58 + col2 * - col1 FROM tab2 AS cor0
----
-1535
-646
-837

skipif mysql # not compatible
query I rowsort label-937
SELECT - + col1 / 58 + col2 * - col1 FROM tab2 AS cor0
----
-1535
-646
-837

query I rowsort
SELECT ALL col0 + 13 AS col1 FROM tab1 cor0
----
16
77
93

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

query I rowsort
SELECT + col2 * - 83 + + tab2.col2 * - col0 AS col1 FROM tab2
----
-2430
-4186
-6156

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

query I rowsort
SELECT 61 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

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

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0 WHERE NULL IN ( + cor0.col2 * + cor0.col1 )
----

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

query I rowsort
SELECT - ( tab2.col2 ) AS col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + - 13 + + col2 AS col2 FROM tab0 AS cor0
----
-12
20
69

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-949
SELECT - col1 DIV - col1 + col1 AS col1 FROM tab1 AS cor0
----
11
14
27

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

query I rowsort
SELECT - cor0.col0 + col1 * - col2 + col0 * - col2 FROM tab1 cor0
----
-1569
-4282
-9008

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

query I rowsort
SELECT 47 * + col2 FROM tab2
----
1222
1269
1786

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

query I rowsort
SELECT + col2 * cor0.col1 * ( - col1 ) + - col0 AS col2 FROM tab1 AS cor0
----
-16304
-36507
-5764

query I rowsort
SELECT - + col0 * - 51 AS col1 FROM tab0 AS cor0
----
1224
1785
4539

onlyif mysql # use DIV operator for integer division
query I rowsort label-956
SELECT - CAST( - 49 AS SIGNED ) DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-956
SELECT - CAST ( - 49 AS INTEGER ) / + col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 + - 85 * - col2 col2 FROM tab2 AS cor0
----
2269
2326
3247

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

query I rowsort
SELECT 66 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1122
2046
3894

query I rowsort
SELECT 4 FROM tab1, tab2 cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT DISTINCT col1 + - col2 * - col2 FROM tab0 AS cor0
----
1175
6815
98

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

query I rowsort
SELECT - - 68 * col2 FROM tab0 AS cor0
----
2244
5576
68

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-966
SELECT - CAST( 80 AS SIGNED ) FROM tab1
----
-80
-80
-80

skipif mysql # not compatible
query I rowsort label-966
SELECT - CAST ( 80 AS INTEGER ) FROM tab1
----
-80
-80
-80

query I rowsort
SELECT ALL + - 99 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 761f5f1a166a00db99360141565a85da

query I rowsort
SELECT ALL - 20 AS col2 FROM tab1, tab2 cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 3d45fa4e6631691e5f0e0ca86982e9c2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-970
SELECT CAST( col1 AS SIGNED ) * col1 - col1 AS col0 FROM tab1
----
156
650
90

skipif mysql # not compatible
query I rowsort label-970
SELECT CAST ( col1 AS INTEGER ) * col1 - col1 AS col0 FROM tab1
----
156
650
90

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

skipif mysql # not compatible
query I rowsort label-971
SELECT col2 / + col2 AS col2 FROM tab0
----
1
1
1

query I rowsort
SELECT + ( - col0 ) * - 89 FROM tab2
----
623
6942
7031

query I rowsort
SELECT + col0 * - ( 3 * cor0.col2 ) + col2 AS col1 FROM tab1 AS cor0
----
-10887
-22944
-432

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

query I rowsort
SELECT DISTINCT col0 * ( - ( col1 ) ) + col0 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL col0 * + col1 + col1 * - col0 * 68 FROM tab1 AS cor0
----
-42880
-5226
-69680

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

query I rowsort
SELECT ALL - - col2 * col2 + 97 AS col2 FROM tab2 AS cor0
----
1541
773
826

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

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

query I rowsort
SELECT ALL - tab1.col0 - - col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-981
SELECT 30 DIV - col1 - col0 FROM tab2
----
-7
-78
-80

skipif mysql # not compatible
query I rowsort label-981
SELECT 30 / - col1 - col0 FROM tab2
----
-7
-78
-80

query IIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1, tab1 AS cor0 WHERE NOT ( cor0.col2 ) >= NULL
----

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

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

query I rowsort
SELECT + 32 FROM tab1, tab0 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT cor0.col0 * + cor1.col2 FROM tab1 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to d678abade8bf70a0dcfdc79d6219306c

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

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

query I rowsort
SELECT col0 * col1 * cor0.col1 - col2 FROM tab2 cor0
----
22793
271492
6700

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-992
SELECT + - col2 DIV 38 + col2 AS col2 FROM tab0 AS cor0
----
1
33
80

skipif mysql # not compatible
query I rowsort label-992
SELECT + - col2 / 38 + col2 AS col2 FROM tab0 AS cor0
----
1
33
80

query I rowsort
SELECT - col0 * 37 FROM tab2 AS cor0
----
-259
-2886
-2923

query I rowsort
SELECT + col2 + + 86 * col1 FROM tab0 AS cor0
----
7429
7908
8343

query I rowsort
SELECT col1 + ( 12 ) * col0 AS col0 FROM tab0 AS cor0
----
1159
374
517

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-997
SELECT ALL col0 DIV - 85 + - col0 * tab2.col2 * col2 AS col0 FROM tab2
----
-114076
-5103
-52728

skipif mysql # not compatible
query I rowsort label-997
SELECT ALL col0 / - 85 + - col0 * tab2.col2 * col2 AS col0 FROM tab2
----
-114076
-5103
-52728

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

query I rowsort
SELECT col2 * + 0 + tab0.col0 * col0 + col0 * col0 AS col2 FROM tab0
----
1152
15842
2450

onlyif mysql # use DIV operator for integer division
query I rowsort label-1000
SELECT ALL + tab1.col2 DIV 60 + col2 AS col2 FROM tab1
----
54
57
97

skipif mysql # not compatible
query I rowsort label-1000
SELECT ALL + tab1.col2 / 60 + col2 AS col2 FROM tab1
----
54
57
97

query I rowsort
SELECT ALL col1 + - 16 * col0 AS col1 FROM tab0 AS cor0
----
-1333
-298
-463

query I rowsort
SELECT DISTINCT + col1 + - 76 AS col2 FROM tab1 AS cor0
----
-50
-63
-66

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1005
SELECT DISTINCT cor0.col0 + - col2 * col2 DIV col1 FROM tab0 AS cor0
----
12
16
35

skipif mysql # not compatible
query I rowsort label-1005
SELECT DISTINCT cor0.col0 + - col2 * col2 / col1 FROM tab0 AS cor0
----
12
16
35

query I rowsort
SELECT DISTINCT col2 - + ( ( col0 ) ) * col2 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col0 + - 65 + col2 col1 FROM tab2 AS cor0
----
-106
-117
-45

query I rowsort
SELECT 43 + col0 * col1 FROM tab1 AS cor0
----
1083
121
683

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1013
SELECT DISTINCT + col0 + + 27 * + col0 DIV col0 AS col1 FROM tab2 AS cor0
----
105
106
34

skipif mysql # not compatible
query I rowsort label-1013
SELECT DISTINCT + col0 + + 27 * + col0 / col0 AS col1 FROM tab2 AS cor0
----
105
106
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * 58 col0 FROM tab2 AS cor0
----
406
4524
4582

query I rowsort
SELECT - 3 + - col1 + cor0.col2 FROM tab1 cor0
----
25
44
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 34 * col2 col1 FROM tab2 cor0
----
1292
884
918

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

query I rowsort
SELECT DISTINCT 97 + - col0 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
146
6181
6338

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1021
SELECT + 11 * - cor0.col1 + cor0.col2 DIV col2 + col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1065
144
5724

skipif mysql # not compatible
query I rowsort label-1021
SELECT + 11 * - cor0.col1 + cor0.col2 / col2 + col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1065
144
5724

query I rowsort
SELECT ALL ( - 78 ) AS col2 FROM tab2 cor0
----
-78
-78
-78

query I rowsort
SELECT + 40 + + col1 + col1 AS col0 FROM tab2 AS cor0
----
102
158
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-1024
SELECT ALL - + 48 + - col0 DIV cor0.col0 FROM tab1 AS cor0
----
-49
-49
-49

skipif mysql # not compatible
query I rowsort label-1024
SELECT ALL - + 48 + - col0 / cor0.col0 FROM tab1 AS cor0
----
-49
-49
-49

query I rowsort
SELECT ALL - col0 * 33 + + col1 FROM tab0 AS cor0
----
-1058
-2846
-706

query I rowsort
SELECT + 82 + cor0.col0 FROM tab1 AS cor0
----
146
162
85

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

query I rowsort
SELECT ALL + col1 + - cor0.col1 * + 15 FROM tab2 cor0
----
-238
-434
-826

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

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

query I rowsort
SELECT ( + col1 ) + ( - 10 ) * col0 FROM tab1 AS cor0
----
-4
-630
-787

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

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

query I rowsort
SELECT DISTINCT + 1 AS col2 FROM tab2 cor0
----
1

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

query I rowsort
SELECT DISTINCT 42 + - cor0.col2 FROM tab1 cor0
----
-12
-15
-54

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

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

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

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

query I rowsort
SELECT + + cor0.col1 * ( 42 ) - - col1 * - col2 AS col2 FROM tab0 AS cor0
----
-3640
3977
774

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

query I rowsort
SELECT col1 * - 45 - col2 FROM tab1 AS cor0
----
-1224
-507
-681

onlyif mysql # use DIV operator for integer division
query I rowsort label-1043
SELECT DISTINCT cor0.col1 + + col2 * col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
-354
-577
20

skipif mysql # not compatible
query I rowsort label-1043
SELECT DISTINCT cor0.col1 + + col2 * col0 / - col1 AS col2 FROM tab1 AS cor0
----
-354
-577
20

query I rowsort
SELECT - + col1 + + 73 * + col2 AS col2 FROM tab2 AS cor0
----
1839
1940
2757

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

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

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

query I rowsort
SELECT + col1 + 91 FROM tab2 AS cor0
----
108
122
150

query I rowsort
SELECT + ( col2 ) + col0 FROM tab2 cor0
----
104
117
34

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

query I rowsort
SELECT - - col2 * + col1 - + 48 * col2 AS col1 FROM tab0 AS cor0
----
1254
3526
49

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

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

query I rowsort
SELECT col1 * - ( col1 ) + col1 AS col1 FROM tab1 cor0
----
-156
-650
-90

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

query I rowsort
SELECT - col2 * col2 + - col2 + - col0 FROM tab2 AS cor0
----
-1561
-763
-780

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + 71 col2 FROM tab1 AS cor0
----
-1846
-710
-923

query I rowsort
SELECT + - col1 * col1 + 33 * col0 AS col2 FROM tab1 AS cor0
----
-577
2012
2471

query I rowsort
SELECT + col2 * 85 + col0 FROM tab2 AS cor0
----
2288
2302
3309

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

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

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

query I rowsort
SELECT + col1 + + 74 FROM tab1 AS cor0
----
100
84
87

query I rowsort
SELECT + + col0 * + 9 + + col0 FROM tab1 AS cor0
----
30
640
800

onlyif mysql # use DIV operator for integer division
query I rowsort label-1063
SELECT + + col2 DIV 34 + col2 FROM tab2 AS cor0
----
26
27
39

skipif mysql # not compatible
query I rowsort label-1063
SELECT + + col2 / 34 + col2 FROM tab2 AS cor0
----
26
27
39

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

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

skipif mysql # not compatible
query I rowsort label-1065
SELECT col0 + col2 / - col1 AS col2 FROM tab1 AS cor0
----
1
59
73

query I rowsort
SELECT + + 28 + + col0 AS col0 FROM tab2 AS cor0
----
106
107
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1067
SELECT ALL - + CAST( 78 AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab1, tab2 cor1
----
27 values hashing to c4f3c63f98c3c08f2848f46850a476d4

skipif mysql # not compatible
query I rowsort label-1067
SELECT ALL - + CAST ( 78 AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab1, tab2 cor1
----
27 values hashing to c4f3c63f98c3c08f2848f46850a476d4

query I rowsort
SELECT + cor0.col2 * 50 + + col2 FROM tab2 cor0
----
1326
1377
1938

query I rowsort
SELECT - - col2 + col2 * col1 + + ( col0 ) AS col2 FROM tab0 AS cor0
----
133
2895
7633

query I rowsort
SELECT 98 * 18 + - col1 FROM tab1 AS cor0
----
1738
1751
1754

query I rowsort
SELECT + + col1 * + 70 + col0 * col0 * col1 FROM tab0 AS cor0
----
125615
55556
727181

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

query I rowsort
SELECT DISTINCT - col1 * col0 * + cor0.col1 - ( 28 ) * col1 FROM tab0 AS cor0
----
-179912
-332031
-739557

query I rowsort
SELECT + + 67 * col2 + col0 FROM tab1 AS cor0
----
3621
3883
6512

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

skipif mysql # not compatible
query I rowsort label-1075
SELECT + col0 / + col2 AS col2 FROM tab0
----
0
1
35

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

query I rowsort
SELECT DISTINCT 9 * - col1 + + cor0.col0 - col2 AS col0 FROM tab1 cor0
----
-133
-285
-83

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 1 * col0 + - col0 * 46 col0 FROM tab0 AS cor0
----
-1080
-1575
-4005

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col0 + - col1 AS REAL ) * - col2 FROM tab0
----
164
2046
62

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

query I rowsort
SELECT DISTINCT + - ( + col0 ) + + col2 + 89 FROM tab1 AS cor0
----
105
140
82

query I rowsort
SELECT DISTINCT 46 * col2 + 68 FROM tab2 AS cor0
----
1264
1310
1816

query I rowsort
SELECT + 79 * ( + col1 * + col0 ) + - col2 - - col2 FROM tab2
----
106097
17143
363558

query I rowsort
SELECT DISTINCT ( 39 ) * col2 + col0 AS col1 FROM tab2
----
1060
1092
1561

query I rowsort
SELECT tab0.col2 * + 24 * tab0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to d51b7a8eab49fd70f9f8bce3af852c67

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

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

query I rowsort
SELECT ALL col0 * col0 - + col0 AS col2 FROM tab0
----
1190
552
7832

query I rowsort
SELECT DISTINCT tab0.col1 + + col0 * col1 * tab0.col0 - + col2 AS col0 FROM tab0
----
118921
49589
720820

query I rowsort
SELECT - 19 + 88 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

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

query I rowsort
SELECT - col1 * col1 + col1 + cor0.col2 FROM tab2 cor0
----
-234
-3396
-903

query I rowsort
SELECT ALL col2 * + col2 * + col0 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
114038
5076
52702

query I rowsort
SELECT + col1 + - col0 * - 92 FROM tab0 AS cor0
----
2294
3317
8279

query I rowsort
SELECT DISTINCT 96 * col2 AS col2 FROM tab1 AS cor0
----
5184
5472
9216

query I rowsort
SELECT cor0.col2 - + col0 * 6 AS col2 FROM tab2 AS cor0
----
-15
-436
-442

query I rowsort
SELECT ALL col2 * col2 + + 0 * - 84 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-1102
SELECT ALL col1 DIV col1 + + 72 FROM tab2 AS cor0
----
73
73
73

skipif mysql # not compatible
query I rowsort label-1102
SELECT ALL col1 / col1 + + 72 FROM tab2 AS cor0
----
73
73
73

query I rowsort
SELECT ALL + - 35 FROM tab0 cor0
----
-35
-35
-35

query I rowsort
SELECT DISTINCT + col0 * - 9 + col1 + + col1 * + col2 FROM tab0 cor0
----
-121
2708
6752

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

query I rowsort
SELECT - tab1.col0 - col2 * + 5 AS col1 FROM tab1
----
-273
-349
-560

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col0 col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
24
35
89

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

query I rowsort
SELECT + 70 * cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to be00591f9886d7eb84584586c1406373

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

query I rowsort
SELECT ALL - - cor0.col0 * + 81 - + col2 AS col0 FROM tab2 AS cor0
----
540
6292
6361

query I rowsort
SELECT ALL - col1 - - col0 * + 59 FROM tab1 AS cor0
----
151
3766
4707

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

skipif mysql # not compatible
query I rowsort label-1116
SELECT ALL 61 + - col0 / - col2 AS col1 FROM tab1 AS cor0
----
61
61
62

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

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

query I rowsort
SELECT ALL - 60 * col2 FROM tab0
----
-1980
-4920
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 41 + col1 * col2 col2 FROM tab1 AS cor0
----
1207
1363
529

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

skipif mysql # not compatible
query I rowsort label-1120
SELECT ALL - + ( col1 ) / CAST ( NULL AS INTEGER ) + 98 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * + col1 - + 63 AS col2 FROM tab2 AS cor0
----
-1597
-709
-900

query I rowsort
SELECT DISTINCT + - 34 - col2 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
1500
612
803

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 * ( col1 ) col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - col0 * + col0 + 55 AS col2 FROM tab0 AS cor0
----
-1170
-521
-7866

query I rowsort
SELECT DISTINCT 39 - - col0 AS col2 FROM tab1
----
103
119
42

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

query I rowsort
SELECT - 88 + col1 FROM tab0
----
-2
3
9

query I rowsort
SELECT 78 + col0 AS col0 FROM tab1
----
142
158
81

query I rowsort
SELECT ALL 94 * + col2 * 64 + - col1 * col2 FROM tab2
----
154882
161595
227962

query I rowsort
SELECT tab0.col2 + + col2 * col1 AS col2 FROM tab0
----
2871
7544
98

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

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

query I rowsort
SELECT + + 92 * col0 + - ( col2 ) FROM tab0 AS cor0
----
2175
3219
8106

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

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

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

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

query I rowsort
SELECT - ( - 0 ) AS col0 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

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

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

query I rowsort
SELECT - 85 + col1 AS col2 FROM tab1
----
-59
-72
-75

query I rowsort
SELECT DISTINCT 34 + col1 AS col0 FROM tab0
----
120
125
131

query I rowsort
SELECT - col2 + ( - 84 * - tab2.col1 ) FROM tab2
----
1390
2577
4930

query I rowsort
SELECT col1 - - 26 * + col0 * - col1 FROM tab0
----
-210483
-53578
-88173

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

query I rowsort
SELECT + col2 * + col0 + col0 * ( 31 ) + cor0.col1 AS col0 FROM tab1 AS cor0
----
10173
281
5642

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

skipif mysql # not compatible
query I rowsort label-1146
SELECT - col2 / 83 FROM tab0 AS cor0
----
0
0
0

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

query I rowsort
SELECT ALL col2 * - 45 + tab2.col2 * + col2 * - 65 FROM tab2
----
-45110
-48600
-95570

query I rowsort
SELECT col1 * + 10 * + tab0.col0 AS col2 FROM tab0
----
20640
33950
80990

query I rowsort
SELECT DISTINCT - col2 * 63 FROM tab0
----
-2079
-5166
-63

query I rowsort
SELECT + tab0.col2 + 78 * + col2 AS col1 FROM tab0
----
2607
6478
79

query I rowsort
SELECT 66 FROM tab1, tab1 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT ALL col1 * 11 + col2 AS col0 FROM tab1 AS cor0
----
167
239
340

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

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

query I rowsort
SELECT ALL + + 73 + + col2 FROM tab0 cor0
----
106
155
74

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

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

skipif mysql # not compatible
query I rowsort label-1158
SELECT - - 37 / col0 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT ALL + 87 * col2 FROM tab2 AS cor0
----
2262
2349
3306

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

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

query I rowsort
SELECT DISTINCT + - col1 + + 30 AS col1 FROM tab0 AS cor0
----
-56
-61
-67

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

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

query I rowsort
SELECT - 34 + col1 FROM tab0
----
52
57
63

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

query I rowsort
SELECT + cor0.col2 * + 34 + + 76 AS col1 FROM tab2 AS cor0
----
1368
960
994

onlyif mysql # use DIV operator for integer division
query I rowsort label-1167
SELECT DISTINCT + 99 DIV tab0.col0 FROM tab0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-1167
SELECT DISTINCT + 99 / tab0.col0 FROM tab0
----
1
2
4

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

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

skipif mysql # not compatible
query I rowsort label-1169
SELECT DISTINCT - 65 / - col0 FROM tab0
----
0
1
2

query I rowsort
SELECT DISTINCT + col1 * + 44 + col2 AS col2 FROM tab0 cor0
----
3817
4086
4269

query I rowsort
SELECT - 52 FROM tab1, tab2 cor0
----
9 values hashing to 9500afe5646d620d5e8943351a29d082

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

query I rowsort
SELECT + col1 + 8 * - col0 FROM tab2 AS cor0
----
-25
-565
-615

query I rowsort
SELECT cor0.col0 + + ( - 24 * cor0.col2 ) FROM tab2 AS cor0
----
-546
-641
-833

query I rowsort
SELECT col1 + ( 99 * col0 ) + + col1 * cor0.col0 FROM tab2 AS cor0
----
12383
9181
941

query I rowsort
SELECT DISTINCT 0 + col1 FROM tab0
----
86
91
97

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

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

query I rowsort
SELECT ALL + + col1 + 17 AS col2 FROM tab1 cor0
----
27
30
43

query I rowsort
SELECT ALL - col1 + col0 * - col0 * col0 FROM tab1 AS cor0
----
-262154
-512013
-53

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

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

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

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

query I rowsort
SELECT - 90 + - ( col0 ) * col1 FROM tab1 AS cor0
----
-1130
-168
-730

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1186
SELECT DISTINCT + 49 DIV - 63 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1186
SELECT DISTINCT + 49 / - 63 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL ( - 99 ) + cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 05e98cac72bbdd779ba16fd426e5e4c8

query I rowsort
SELECT DISTINCT + ( + col1 ) + + col1 FROM tab1 AS cor0
----
20
26
52

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

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

skipif mysql # not compatible
query I rowsort label-1190
SELECT DISTINCT 28 / cor0.col0 + cor0.col2 AS col2 FROM tab2 AS cor0
----
26
31
38

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

query I rowsort
SELECT - col2 * col1 + - 84 FROM tab2 AS cor0
----
-1618
-730
-921

query I rowsort
SELECT 69 + ( col2 ) AS col1 FROM tab2
----
107
95
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1194
SELECT DISTINCT + col1 DIV col1 + + col1 DIV + 84 col0 FROM tab2
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1194
SELECT DISTINCT + col1 / col1 + + col1 / + 84 col0 FROM tab2
----
1

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

skipif mysql # not compatible
query I rowsort label-1195
SELECT - 21 / col2 AS col2 FROM tab1 AS cor0
----
0
0
0

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 72 + + col1 col2 FROM tab1 AS cor0
----
-46
-59
-62

query I rowsort
SELECT + 15 * col2 FROM tab1
----
1440
810
855

onlyif mysql # use DIV operator for integer division
query I rowsort label-1199
SELECT tab2.col0 + col0 DIV + col0 - - col1 FROM tab2
----
138
39
97

skipif mysql # not compatible
query I rowsort label-1199
SELECT tab2.col0 + col0 / + col0 - - col1 FROM tab2
----
138
39
97

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 84 + - col1 col0 FROM tab2 AS cor0
----
25
53
67

query I rowsort
SELECT + - ( + col1 ) * cor0.col0 * - col0 AS col1 FROM tab1 AS cor0
----
234
40960
83200

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1206
SELECT DISTINCT - - col0 - col0 DIV col0 AS col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-1206
SELECT DISTINCT - - col0 - col0 / col0 AS col0 FROM tab0 AS cor0
----
23
34
88

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

query I rowsort
SELECT DISTINCT - cor0.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-1
-33
-82

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

query I rowsort
SELECT + ( 70 ) FROM tab1 cor0
----
70
70
70

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

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

query I rowsort
SELECT + cor0.col0 * 31 AS col1 FROM tab0 AS cor0
----
1085
2759
744

query I rowsort
SELECT col2 * - ( 57 + - col0 ) * + col2 FROM tab2
----
-36450
14196
31768

query I rowsort
SELECT DISTINCT - col2 * + 65 FROM tab2
----
-1690
-1755
-2470

query I rowsort
SELECT ALL - 16 * + ( + tab1.col1 ) FROM tab1
----
-160
-208
-416

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

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

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

query I rowsort
SELECT ALL - 13 + col1 * - cor0.col1 FROM tab0 AS cor0
----
-7409
-8294
-9422

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1221
SELECT ALL CAST( + 66 AS SIGNED ) AS col2 FROM tab1
----
66
66
66

skipif mysql # not compatible
query I rowsort label-1221
SELECT ALL CAST ( + 66 AS INTEGER ) AS col2 FROM tab1
----
66
66
66

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

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

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

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

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

query I rowsort
SELECT - col1 + 58 AS col1 FROM tab2
----
-1
27
41

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 14 + col0 col1 FROM tab2 AS cor0
----
-7
64
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-1228
SELECT DISTINCT - col0 DIV + col1 + - col1 * - col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-1228
SELECT DISTINCT - col0 / + col1 + - col1 * - col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

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

query I rowsort
SELECT 62 - col2 FROM tab0 AS cor0
----
-20
29
61

query I rowsort
SELECT DISTINCT - 62 + tab2.col0 AS col0 FROM tab2
----
-55
16
17

query I rowsort
SELECT DISTINCT - col2 + - col2 + - col0 AS col2 FROM tab0
----
-253
-37
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1233
SELECT DISTINCT + col1 DIV - 49 + col2 * - CAST( - col0 + + col1 AS SIGNED ) AS col2 FROM tab1
----
-1242
3078
6432

skipif mysql # not compatible
query I rowsort label-1233
SELECT DISTINCT + col1 / - 49 + col2 * - CAST ( - col0 + + col1 AS INTEGER ) AS col2 FROM tab1
----
-1242
3078
6432

query I rowsort
SELECT 89 + col0 + + tab2.col1 AS col2 FROM tab2
----
127
185
226

query I rowsort
SELECT - cor0.col2 * cor0.col2 + col0 - - col0 AS col1 FROM tab0 AS cor0
----
-1041
-6546
69

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

query I rowsort
SELECT DISTINCT - cor0.col2 * col0 + col1 * - col1 FROM tab2 AS cor0
----
-1150
-3291
-5509

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - col0 AS REAL ) * + col0 + + col2 * + cor0.col1 FROM tab0 AS cor0
----
-1128
-459
2262

query I rowsort
SELECT - 75 + - 78 * - cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
221289
581961
7491

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col1 ) col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ( - col1 ) - ( 45 ) FROM tab1
----
-55
-58
-71

query I rowsort
SELECT - col2 * + col0 * ( + 67 ) - + col0 AS col1 FROM tab1
----
-10857
-244480
-514640

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

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

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

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

query I rowsort
SELECT ALL - cor0.col2 * col2 * col1 + - cor0.col1 FROM tab2 AS cor0
----
-22630
-24565
-39943

query I rowsort
SELECT ALL + col1 * cor0.col1 + + cor0.col0 * - col1 FROM tab0 AS cor0
----
182
5332
6014

query I rowsort
SELECT DISTINCT + col2 * - 15 * col1 - col2 FROM tab2 AS cor0
----
-12582
-23036
-9728

query I rowsort
SELECT ALL - + col2 + - col2 + - col0 FROM tab0 AS cor0
----
-253
-37
-90

query I rowsort
SELECT + col2 * ( + 33 ) + col1 AS col1 FROM tab0 AS cor0
----
1175
130
2797

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1256
SELECT ALL col0 * col2 / col0 col1 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - 93 * - 80 col1 FROM tab1 AS cor0
----
7450
7453
7466

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1259
SELECT 59 DIV - tab2.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 973e472c5ae2518db782943f7057c46a

skipif mysql # not compatible
query I rowsort label-1259
SELECT 59 / - tab2.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 973e472c5ae2518db782943f7057c46a

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

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

query I rowsort
SELECT + - cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT 4 - col0 FROM tab0
----
-20
-31
-85

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

query I rowsort
SELECT ALL - col2 + col1 + - col2 AS col2 FROM tab2 AS cor0
----
-23
-59
7

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

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

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

query I rowsort
SELECT col0 * + 23 + col1 FROM tab1
----
1482
1853
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-1270
SELECT - tab1.col0 + + 9 DIV col1 col2 FROM tab1
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1270
SELECT - tab1.col0 + + 9 / col1 col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT + col1 + + 15 AS col1 FROM tab1
----
25
28
41

query I rowsort
SELECT cor0.col0 + - 45 AS col0 FROM tab1 AS cor0
----
-42
19
35

query I rowsort
SELECT ALL 61 * - 87 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to e07aaeb92d818f46b9293fec50e0729c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1274
SELECT + CAST( NULL AS DECIMAL ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1274
SELECT + CAST ( NULL AS REAL ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

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

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

skipif mysql # not compatible
query I rowsort label-1277
SELECT + 88 + col2 / - cor0.col0 FROM tab0 AS cor0
----
87
88
88

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

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

query I rowsort
SELECT ALL + col0 + cor0.col1 * + 25 FROM tab2 AS cor0
----
1553
504
782

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1283
SELECT + 89 + - cor0.col1 DIV + CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
86
87
88

skipif mysql # not compatible
query I rowsort label-1283
SELECT + 89 + - cor0.col1 / + CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
86
87
88

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

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

query I rowsort
SELECT ALL + 0 FROM tab1, tab1 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

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

query I rowsort
SELECT ( + col0 ) * tab0.col2 + + ( + 35 ) FROM tab0
----
70
7333
827

query I rowsort
SELECT ALL 37 - + 49 AS col0 FROM tab0
----
-12
-12
-12

query I rowsort
SELECT ALL 9 - col1 AS col1 FROM tab2
----
-22
-50
-8

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1291
SELECT ALL - 16 DIV + col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1291
SELECT ALL - 16 / + col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 + cor0.col0 * ( col2 * col0 ) FROM tab0 AS cor0
----
1190
18984
649433

query I rowsort
SELECT + + 58 + col0 * cor0.col1 FROM tab2 AS cor0
----
1401
275
4660

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

skipif mysql # not compatible
query I rowsort label-1294
SELECT ALL cor0.col2 + col2 / - 77 AS col1 FROM tab2 AS cor0
----
26
27
38

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

query I rowsort
SELECT - col1 * + col0 + - 10 AS col1 FROM tab2 AS cor0
----
-1353
-227
-4612

query I rowsort
SELECT - 17 * - col1 + ( col2 ) AS col0 FROM tab1
----
227
317
496

query I rowsort
SELECT ALL - 45 * 47 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 8162f10c1ba7feb6a04fff4973e3e22b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 8 + cor0.col2 col0 FROM tab0 AS cor0
----
-7
25
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-1300
SELECT - 85 * col1 - - col1 DIV + 12 AS col2 FROM tab2 AS cor0
----
-1444
-2633
-5011

skipif mysql # not compatible
query I rowsort label-1300
SELECT - 85 * col1 - - col1 / + 12 AS col2 FROM tab2 AS cor0
----
-1444
-2633
-5011

query I rowsort
SELECT ALL - col2 * col1 - - col0 * tab2.col1 AS col2 FROM tab2
----
-620
3068
697

query I rowsort
SELECT + col1 * col1 * 81 FROM tab1
----
13689
54756
8100

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1304
SELECT - cor0.col1 * - CAST( col0 AS SIGNED ) + col0 * + 66 FROM tab2 AS cor0
----
6557
679
9750

skipif mysql # not compatible
query I rowsort label-1304
SELECT - cor0.col1 * - CAST ( col0 AS INTEGER ) + col0 * + 66 FROM tab2 AS cor0
----
6557
679
9750

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + 43 col0 FROM tab0 AS cor0
----
125
44
76

query I rowsort
SELECT - 99 * col2 FROM tab0
----
-3267
-8118
-99

query I rowsort
SELECT + 87 + - col1 * - col2 AS col0 FROM tab2 AS cor0
----
1621
733
924

query I rowsort
SELECT ( 6 ) * col0 AS col0 FROM tab1 cor0
----
18
384
480

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

query I rowsort
SELECT col1 + + 13 FROM tab1 AS cor0
----
23
26
39

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

query I rowsort
SELECT - 68 * cor0.col1 AS col1 FROM tab1 cor0
----
-1768
-680
-884

query I rowsort
SELECT ALL col2 * + 65 FROM tab1
----
3510
3705
6240

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

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

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

query I rowsort
SELECT DISTINCT + - 8 * + col0 FROM tab1 AS cor0
----
-24
-512
-640

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

skipif mysql # not compatible
query I rowsort label-1317
SELECT DISTINCT + col2 / 67 FROM tab1
----
0
1

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

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

query I rowsort
SELECT ALL 42 * 32 AS col0 FROM tab1
----
1344
1344
1344

query I rowsort
SELECT ALL ( col1 + - tab0.col0 ) * col0 AS col0 FROM tab0
----
1488
178
2170

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

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

query I rowsort
SELECT - 54 * tab0.col1 - + tab0.col0 AS col0 FROM tab0
----
-4668
-5003
-5273

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1325
SELECT DISTINCT - 2 DIV cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
0

skipif mysql # not compatible
query I rowsort label-1325
SELECT DISTINCT - 2 / cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
0

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

query I rowsort
SELECT DISTINCT - col1 + + cor0.col1 * + col1 * + col1 FROM tab0 cor0
----
635970
753480
912576

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

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

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

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

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

query I rowsort
SELECT ALL 1 + col2 AS col0 FROM tab0 AS cor0
----
2
34
83

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

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

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

query I rowsort
SELECT + cor0.col2 * 22 FROM tab2 AS cor0
----
572
594
836

query I rowsort
SELECT col2 + col2 * + 45 FROM tab0 AS cor0
----
1518
3772
46

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1339
SELECT col2 + - cor0.col0 * - col2 DIV - col2 AS col2 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-1339
SELECT col2 + - cor0.col0 * - col2 / - col2 AS col2 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1340
SELECT + col1 * - 46 + + col2 + + col0 DIV - 64 FROM tab2 AS cor0
----
-1399
-2689
-745

skipif mysql # not compatible
query I rowsort label-1340
SELECT + col1 * - 46 + + col2 + + col0 / - 64 FROM tab2 AS cor0
----
-1399
-2689
-745

query I rowsort
SELECT DISTINCT - + ( - ( - cor0.col1 ) ) + ( 92 ) * + col1 AS col1 FROM tab0 AS cor0
----
7826
8281
8827

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

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

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

query I rowsort
SELECT DISTINCT + + col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
100
169
676

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1348
SELECT ALL col0 + - CAST ( cor0.col1 AS INTEGER ) FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL col0 * + 98 * - col2 + + col0 FROM tab1 AS cor0
----
-15873
-357440
-752560

onlyif mysql # use DIV operator for integer division
query I rowsort label-1350
SELECT DISTINCT col2 * cor0.col2 - + col0 DIV - col1 FROM tab1 AS cor0
----
2916
3255
9222

skipif mysql # not compatible
query I rowsort label-1350
SELECT DISTINCT col2 * cor0.col2 - + col0 / - col1 FROM tab1 AS cor0
----
2916
3255
9222

query I rowsort
SELECT ALL - col1 * 37 FROM tab2 AS cor0
----
-1147
-2183
-629

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - col2 * + ( 47 + col0 * ( - tab2.col0 ) ) col0 FROM tab2
----
156988
235410
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-1354
SELECT DISTINCT + col2 DIV + 2 FROM tab2 cor0
----
13
19

skipif mysql # not compatible
query I rowsort label-1354
SELECT DISTINCT + col2 / + 2 FROM tab2 cor0
----
13
19

query I rowsort
SELECT - col1 * col1 + + col1 * - tab2.col0 AS col0 FROM tab2
----
-1178
-1632
-8083

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * 11 col2 FROM tab0 AS cor0
----
1001
1067
946

query I rowsort
SELECT + cor0.col0 + - 3 FROM tab2 AS cor0
----
4
75
76

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

query I rowsort
SELECT DISTINCT - + cor0.col1 * ( 89 ) + col1 - - col0 FROM tab1 AS cor0
----
-1064
-2285
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1361
SELECT + tab2.col1 + - CAST( + 86 AS SIGNED ) FROM tab2
----
-27
-55
-69

skipif mysql # not compatible
query I rowsort label-1361
SELECT + tab2.col1 + - CAST ( + 86 AS INTEGER ) FROM tab2
----
-27
-55
-69

onlyif mysql # use DIV operator for integer division
query I rowsort label-1362
SELECT 38 DIV cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-1362
SELECT 38 / cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1365
SELECT - col0 DIV + col2 + cor0.col1 * - col0 + - col1 FROM tab0 AS cor0
----
-2150
-3527
-8191

skipif mysql # not compatible
query I rowsort label-1365
SELECT - col0 / + col2 + cor0.col1 * - col0 + - col1 FROM tab0 AS cor0
----
-2150
-3527
-8191

query I rowsort
SELECT 28 * col2 AS col2 FROM tab0 AS cor0
----
2296
28
924

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1367
SELECT ALL CAST( 52 * col2 AS SIGNED ) + - tab1.col0 AS col1 FROM tab1
----
2805
2900
4912

skipif mysql # not compatible
query I rowsort label-1367
SELECT ALL CAST ( 52 * col2 AS INTEGER ) + - tab1.col0 AS col1 FROM tab1
----
2805
2900
4912

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

query I rowsort
SELECT DISTINCT 17 + + col0 * + col2 * - col0 AS col0 FROM tab2
----
-1306
-158167
-237141

query I rowsort
SELECT + 61 AS col2 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT - 90 + col0 * - 84 FROM tab2
----
-6642
-6726
-678

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

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

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

query I rowsort
SELECT - 64 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 100c625e45715c20368551989514ba64

query I rowsort
SELECT - 75 FROM tab1 cor0
----
-75
-75
-75

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

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

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

query I rowsort
SELECT DISTINCT - - col2 * - col2 + 96 * cor0.col1 AS col0 FROM tab0 AS cor0
----
2012
7167
9311

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

query I rowsort
SELECT DISTINCT - 49 * col0 AS col2 FROM tab1 AS cor0
----
-147
-3136
-3920

query I rowsort
SELECT ALL + col1 + - col0 * - 79 FROM tab1 AS cor0
----
263
5066
6333

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

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

query I rowsort
SELECT + 42 * + ( col2 + 57 ) FROM tab2
----
3486
3528
3990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1386
SELECT DISTINCT - - CAST( col1 AS SIGNED ) * + col2 + 46 FROM tab0 AS cor0
----
143
2884
7508

skipif mysql # not compatible
query I rowsort label-1386
SELECT DISTINCT - - CAST ( col1 AS INTEGER ) * + col2 + 46 FROM tab0 AS cor0
----
143
2884
7508

query I rowsort
SELECT ALL - + 64 - col0 AS col1 FROM tab2 AS cor0
----
-142
-143
-71

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1389
SELECT DISTINCT - col0 DIV 25 + - tab1.col2 * 1 AS col2 FROM tab1
----
-54
-59
-99

skipif mysql # not compatible
query I rowsort label-1389
SELECT DISTINCT - col0 / 25 + - tab1.col2 * 1 AS col2 FROM tab1
----
-54
-59
-99

query I rowsort
SELECT DISTINCT + tab2.col0 + + 48 FROM tab2
----
126
127
55

query I rowsort
SELECT DISTINCT + col2 * + 42 * tab1.col2 + + ( 7 * - col0 ) AS col2 FROM tab1
----
122451
136010
386512

query I rowsort
SELECT DISTINCT - ( - tab2.col1 * tab2.col1 ) + ( tab2.col0 ) * col0 FROM tab2
----
1010
6530
9565

query I rowsort
SELECT + col1 * + 23 AS col2 FROM tab2
----
1357
391
713

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

query I rowsort
SELECT DISTINCT col1 + 77 FROM tab2 AS cor0
----
108
136
94

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 DISTINCT + 55 - col2 AS col1 FROM tab0 AS cor0
----
-27
22
54

query I rowsort
SELECT + - 6 - 33 FROM tab2 AS cor0
----
-39
-39
-39

query I rowsort
SELECT DISTINCT - 58 * - col2 FROM tab2 AS cor0
----
1508
1566
2204

onlyif mysql # use DIV operator for integer division
query I rowsort label-1400
SELECT col0 * col1 DIV + col2 + + cor0.col2 * + col1 AS col1 FROM tab0 AS cor0
----
2900
3492
7560

skipif mysql # not compatible
query I rowsort label-1400
SELECT col0 * col1 / + col2 + + cor0.col2 * + col1 AS col1 FROM tab0 AS cor0
----
2900
3492
7560

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1402
SELECT - cor0.col1 * - col0 + 80 DIV 4 FROM tab2 AS cor0
----
1363
237
4622

skipif mysql # not compatible
query I rowsort label-1402
SELECT - cor0.col1 * - col0 + 80 / 4 FROM tab2 AS cor0
----
1363
237
4622

query I rowsort
SELECT ALL + col0 + col0 * - 15 FROM tab0 AS cor0
----
-1246
-336
-490

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 56 * col0 col2 FROM tab2 cor0
----
392
4368
4424

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 32 * - col1 + 75 * 50 col0 FROM tab1 AS cor0
----
4070
4166
4582

query I rowsort
SELECT + col2 * + col0 + ( + col2 ) * col2 * - 15 AS col1 FROM tab0 AS cor0
----
-15543
-93562
20

query I rowsort
SELECT - + col1 * + col0 + col2 * - col2 FROM tab2 AS cor0
----
-2787
-5278
-946

query I rowsort
SELECT DISTINCT + col1 * - 51 + col0 * - 86 AS col1 FROM tab1
----
-1584
-6014
-7543

query I rowsort
SELECT DISTINCT 85 * tab1.col0 AS col0 FROM tab1, tab0, tab1 AS cor0, tab1 AS cor1
----
255
5440
6800

onlyif mysql # use DIV operator for integer division
query I rowsort label-1410
SELECT DISTINCT - col0 DIV + ( + col2 ) + col1 * - col2 AS col0 FROM tab0
----
-132
-2838
-7463

skipif mysql # not compatible
query I rowsort label-1410
SELECT DISTINCT - col0 / + ( + col2 ) + col1 * - col2 AS col0 FROM tab0
----
-132
-2838
-7463

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

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

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

query I rowsort
SELECT - 59 * col0 * - col2 + 30 * + cor0.col1 * col2 FROM tab1 AS cor0
----
232332
490560
51678

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1416
SELECT ALL - + CAST( cor0.col1 AS SIGNED ) * - col2 + 74 FROM tab2 cor0
----
1608
720
911

skipif mysql # not compatible
query I rowsort label-1416
SELECT ALL - + CAST ( cor0.col1 AS INTEGER ) * - col2 + 74 FROM tab2 cor0
----
1608
720
911

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

query I rowsort
SELECT ALL - col1 * + 85 FROM tab1
----
-1105
-2210
-850

query I rowsort
SELECT - - 86 + - col1 FROM tab1 AS cor0
----
60
73
76

query I rowsort
SELECT - 21 * - col1 + + 84 FROM tab1 AS cor0
----
294
357
630

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

query I rowsort
SELECT + - 39 * col2 * col1 AS col1 FROM tab1 AS cor0
----
-22230
-48672
-54756

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1424
SELECT - - 92 + - col0 DIV ( cor0.col2 ) AS col1 FROM tab1 cor0
----
91
92
92

skipif mysql # not compatible
query I rowsort label-1424
SELECT - - 92 + - col0 / ( cor0.col2 ) AS col1 FROM tab1 cor0
----
91
92
92

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + cor0.col2 col1 FROM tab0 AS cor0
----
171
36
57

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

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

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

query I rowsort
SELECT DISTINCT + - cor0.col0 + + 83 AS col1 FROM tab1 AS cor0
----
19
3
80

query I rowsort
SELECT col1 + col0 * - 57 FROM tab0 AS cor0
----
-1282
-1898
-4982

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * 75 + + cor0.col1 col1 FROM tab1 AS cor0
----
1976
760
988

query I rowsort
SELECT DISTINCT + + col2 + + 27 FROM tab1 AS cor0
----
123
81
84

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 35 * col2 col0 FROM tab2
----
-1330
-910
-945

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

query I rowsort
SELECT DISTINCT + + 71 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
71

query I rowsort
SELECT + col0 + - 76 FROM tab1
----
-12
-73
4

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

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

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

skipif mysql # not compatible
query I rowsort label-1445
SELECT CAST ( + 45 AS INTEGER ) * col2 AS col1 FROM tab0 AS cor0
----
1485
3690
45

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

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

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

query I rowsort
SELECT DISTINCT + col2 + - col0 * + ( col2 * col2 ) AS col1 FROM tab1 AS cor0
----
-207879
-737184
-8694

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

skipif mysql # not compatible
query I rowsort label-1450
SELECT ALL - 75 / + cor0.col2 FROM tab0 AS cor0
----
-2
-75
0

query I rowsort
SELECT + 58 + - col0 FROM tab2 AS cor0
----
-20
-21
51

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

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

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

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

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

query I rowsort
SELECT ALL + 48 * col0 AS col0 FROM tab0 AS cor0
----
1152
1680
4272

query I rowsort
SELECT DISTINCT + 49 * col1 FROM tab1 AS cor0
----
1274
490
637

query I rowsort
SELECT ALL + 50 * 8 FROM tab2 AS cor0
----
400
400
400

query I rowsort
SELECT + col2 * + ( - col1 ) + + col2 * 10 FROM tab0 cor0
----
-2508
-6642
-87

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

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

query I rowsort
SELECT DISTINCT col1 + 82 AS col2 FROM tab1 AS cor0
----
108
92
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-1463
SELECT ALL - - col1 DIV - 75 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1463
SELECT ALL - - col1 / - 75 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 89 + - col2 AS col1 FROM tab0 AS cor0
----
56
7
88

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

query I rowsort
SELECT DISTINCT col0 * + col0 + col2 FROM tab2 AS cor0
----
6110
6279
76

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

query I rowsort
SELECT ALL 9 AS col1 FROM tab1 cor0
----
9
9
9

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

skipif mysql # not compatible
query I rowsort label-1469
SELECT - - col2 + + col0 / col1 AS col2 FROM tab0 cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1470
SELECT DISTINCT CAST( + col2 AS SIGNED ) * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort label-1470
SELECT DISTINCT CAST ( + col2 AS INTEGER ) * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + - col1 * col2 * - col0 + - col1 FROM tab2 AS cor0
----
119593
51017
5828

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

query I rowsort
SELECT 64 + - cor0.col0 FROM tab1 AS cor0
----
-16
0
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-1474
SELECT ALL 49 DIV col1 + + 52 FROM tab0 AS cor0
----
52
52
52

skipif mysql # not compatible
query I rowsort label-1474
SELECT ALL 49 / col1 + + 52 FROM tab0 AS cor0
----
52
52
52

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

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

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

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

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

query I rowsort
SELECT ALL - 42 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 56f86ff01cd96a3511acd46e0e811e27

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1483
SELECT ALL + col2 * col1 DIV + col1 AS col2 FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-1483
SELECT ALL + col2 * col1 / + col1 AS col2 FROM tab2 cor0
----
26
27
38

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

query I rowsort
SELECT ALL + col0 + + col1 + + 48 * col1 AS col1 FROM tab1
----
1277
554
717

query I rowsort
SELECT ALL - ( + 50 ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

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

skipif mysql # not compatible
query I rowsort label-1487
SELECT ALL - col0 * CAST ( col0 * col2 AS INTEGER ) + ( col2 * col0 ) FROM tab2
----
-1134
-156156
-234156

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

query I rowsort
SELECT - + col1 * 82 + 95 AS col1 FROM tab2 AS cor0
----
-1299
-2447
-4743

onlyif mysql # use DIV operator for integer division
query I rowsort label-1490
SELECT + col1 * col0 + col2 DIV col0 FROM tab1 AS cor0
----
1041
640
96

skipif mysql # not compatible
query I rowsort label-1490
SELECT + col1 * col0 + col2 / col0 FROM tab1 AS cor0
----
1041
640
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1491
SELECT ALL + + cor0.col2 - CAST( col1 + col0 AS SIGNED ) FROM tab1 AS cor0
----
-17
25
3

skipif mysql # not compatible
query I rowsort label-1491
SELECT ALL + + cor0.col2 - CAST ( col1 + col0 AS INTEGER ) FROM tab1 AS cor0
----
-17
25
3

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

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

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

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

query I rowsort
SELECT 59 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT + - col2 * 44 + col0 FROM tab2 AS cor0
----
-1066
-1181
-1593

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

skipif mysql # not compatible
query I rowsort label-1497
SELECT + - col1 / 85 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor1.col1 * cor0.col1 col0 FROM tab0 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 601c129c54e49286b9ededa8928121fc

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

query I rowsort
SELECT 86 * + col0 FROM tab0
----
2064
3010
7654

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

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

query I rowsort
SELECT - 56 + ( + col1 ) FROM tab0
----
30
35
41

query I rowsort
SELECT + 12 * - col0 FROM tab2
----
-84
-936
-948

query I rowsort
SELECT - 56 * 81 FROM tab0 AS cor0
----
-4536
-4536
-4536

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

query I rowsort
SELECT 38 * - 33 - col1 FROM tab0 AS cor0
----
-1340
-1345
-1351

query I rowsort
SELECT DISTINCT - + 54 + col2 * + col1 * + 53 FROM tab0 AS cor0
----
150360
395432
5087

query I rowsort
SELECT + 20 * 87 + + cor0.col2 * ( + col0 * - col2 ) FROM tab1 AS cor0
----
-206196
-7008
-735540

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1511
SELECT - - 0 * + col1 / - col0 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 45 * cor0.col2 AS col1 FROM tab0 cor0
----
1485
3690
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col2 col1 FROM tab2 AS cor0
----
-1444
-676
-729

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

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

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

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

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

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

query I rowsort
SELECT ALL cor0.col1 + - 34 AS col1 FROM tab2 cor0
----
-17
-3
25

query I rowsort
SELECT ALL col1 + + 91 AS col1 FROM tab0 cor0
----
177
182
188

query I rowsort
SELECT col1 + 87 + 48 AS col1 FROM tab1 AS cor0
----
145
148
161

query I rowsort
SELECT DISTINCT + - cor0.col2 + 84 AS col0 FROM tab2 AS cor0
----
46
57
58

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

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

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1527
SELECT - col0 + - col0 / - 94 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + 90 AS col1 FROM tab1
----
90
90
90

query I rowsort
SELECT 50 * - col1 * - col0 AS col2 FROM tab1
----
32000
3900
52000

query I rowsort
SELECT - 57 * col0 FROM tab1 cor0
----
-171
-3648
-4560

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

query I rowsort
SELECT DISTINCT - 70 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-1820
-1890
-2660

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

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab2 cor1
----
972 values hashing to 01a5931cccc3dad8792a1bc6df09c614

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

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

query I rowsort
SELECT + 29 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 82 * cor0.col0 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5ed674b86bc66220451666145bcd25fd

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

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

query I rowsort
SELECT - - col2 * + 34 + col0 * + cor0.col2 AS col0 FROM tab0 cor0
----
10086
1914
69

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

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

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

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

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

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

query I rowsort
SELECT + col1 * - col1 + col0 + 42 FROM tab2 AS cor0
----
-168
-3361
-912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 57 * cor0.col1 col0 FROM tab1 cor0
----
-1482
-570
-741

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

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

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

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

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

query I rowsort
SELECT DISTINCT - 32 + col0 FROM tab2
----
-25
46
47

query I rowsort
SELECT ( col0 ) + - tab0.col1 * col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT - ( col2 ) * col1 * + col1 FROM tab0
----
-244068
-679042
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-1553
SELECT ALL - ( + col0 ) * + col2 + + col0 DIV + col2 FROM tab0
----
-7297
-792
0

skipif mysql # not compatible
query I rowsort label-1553
SELECT ALL - ( + col0 ) * + col2 + + col0 / + col2 FROM tab0
----
-7297
-792
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1554
SELECT - CAST( - col0 AS SIGNED ) + tab0.col0 FROM tab0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-1554
SELECT - CAST ( - col0 AS INTEGER ) + tab0.col0 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL + 80 AS col1 FROM tab0 AS cor0
----
80
80
80

query I rowsort
SELECT - - col1 * - col2 + + cor0.col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT col2 + + 97 AS col2 FROM tab0 cor0
----
130
179
98

query I rowsort
SELECT ALL + 49 * - col2 - + col0 FROM tab2 AS cor0
----
-1330
-1352
-1941

query I rowsort
SELECT DISTINCT ( - 62 ) FROM tab1 cor0
----
-62

query I rowsort
SELECT + - col1 * - col0 + cor0.col0 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-1561
SELECT 1 DIV + col2 + + col1 col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1561
SELECT 1 / + col2 + + col1 col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + + 63 + col0 FROM tab0 AS cor0
----
152
87
98

query I rowsort
SELECT ALL + + col0 + col1 * cor0.col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - 95 AS col2 FROM tab0 cor0
----
-95
-95
-95

query I rowsort
SELECT DISTINCT - col1 + col2 * - cor0.col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT - - col0 + + col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL 20 * col0 FROM tab0 AS cor0
----
1780
480
700

query I rowsort
SELECT DISTINCT - - col1 * + col1 + - col0 + - col1 AS col2 FROM tab0 AS cor0
----
7286
8101
9277

query I rowsort
SELECT + col2 - col1 * col0 * - col0 AS col1 FROM tab0
----
118826
49569
720893

query I rowsort
SELECT ALL col2 + - 75 AS col1 FROM tab0
----
-42
-74
7

query I rowsort
SELECT ALL ( tab1.col0 ) + + tab1.col2 FROM tab1
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1572
SELECT ALL CAST( 76 AS SIGNED ) FROM tab2
----
76
76
76

skipif mysql # not compatible
query I rowsort label-1572
SELECT ALL CAST ( 76 AS INTEGER ) FROM tab2
----
76
76
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( - col0 ) + cor0.col2 col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT - col0 * - ( cor0.col1 * + cor0.col0 ) FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT - 77 + + cor0.col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 28899d80467fe81b50e24d2684077652

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1577
SELECT CAST( NULL AS SIGNED ) - col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1577
SELECT CAST ( NULL AS INTEGER ) - col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 19 col1 FROM tab0 AS cor0
----
-14
-63
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-1579
SELECT tab0.col2 DIV - ( 47 ) FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1579
SELECT tab0.col2 / - ( 47 ) FROM tab0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1580
SELECT + col2 + 70 - + col0 DIV col0 AS col1 FROM tab2
----
107
95
96

skipif mysql # not compatible
query I rowsort label-1580
SELECT + col2 + 70 - + col0 / col0 AS col1 FROM tab2
----
107
95
96

query I rowsort
SELECT DISTINCT + col2 + col1 + + ( + 56 ) * col1 FROM tab2
----
1007
1794
3389

query I rowsort
SELECT - 75 + - col2 AS col2 FROM tab2 AS cor0
----
-101
-102
-113

query I rowsort
SELECT - col0 + cor0.col0 - col0 * + 74 FROM tab0 AS cor0
----
-1776
-2590
-6586

query I rowsort
SELECT DISTINCT - 37 + cor0.col0 AS col2 FROM tab1 AS cor0
----
-34
27
43

query I rowsort
SELECT ALL cor0.col2 * col1 * + col2 AS col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT col1 * col2 + - 65 * + col0 FROM tab0 cor0
----
-2178
1278
1677

query I rowsort
SELECT ALL col2 + + ( + col2 ) FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT 83 + tab0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 228804e0e067777ecfe5c0bff9232326

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1589
SELECT DISTINCT - cor0.col1 / + CAST( NULL AS SIGNED ) + + 2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1589
SELECT DISTINCT - cor0.col1 / + CAST ( NULL AS INTEGER ) + + 2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - col2 + cor0.col0 * + 95 FROM tab0 AS cor0
----
2247
3324
8373

query I rowsort
SELECT ALL - col1 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - - col0 * - col2 + - col2 AS col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT col0 + + 78 AS col1 FROM tab0 AS cor0
----
102
113
167

query I rowsort
SELECT DISTINCT - cor0.col1 + + col1 * col2 * col2 FROM tab1 cor0
----
119795
32480
75790

query I rowsort
SELECT ALL - col0 + col2 * 3 AS col0 FROM tab0 AS cor0
----
-32
157
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * + ( col1 ) col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + col0 * 73 + + col0 AS col0 FROM tab2 AS cor0
----
518
5772
5846

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - 17 col0 FROM tab0 AS cor0
----
-106
-41
-52

query I rowsort
SELECT ALL col1 + 22 FROM tab0 AS cor0
----
108
113
119

query I rowsort
SELECT + col2 + 93 * - cor0.col0 FROM tab2 cor0
----
-624
-7228
-7309

query I rowsort
SELECT DISTINCT + + cor0.col2 * col0 + + ( col2 ) FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + col0 + + ( + col0 ) AS col1 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT - + ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - - 12 + - col0 FROM tab0 AS cor0
----
-12
-23
-77

query I rowsort
SELECT DISTINCT + + col1 + 51 FROM tab0 AS cor0
----
137
142
148

query I rowsort
SELECT + - 90 AS col0 FROM tab0 AS cor0
----
-90
-90
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 8 + cor0.col2 * col2 col1 FROM tab0 AS cor0
----
1097
6732
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 58 * col1 col1 FROM tab1 cor0
----
1508
580
754

query I rowsort
SELECT DISTINCT cor0.col2 * col0 * col1 + - ( + cor0.col0 ) FROM tab0 AS cor0
----
3360
664029
68088

query I rowsort
SELECT + ( 36 ) AS col1 FROM tab1 AS cor0
----
36
36
36

query I rowsort
SELECT ALL - - col2 + + ( col2 + + col2 ) * + col0 FROM tab0 AS cor0
----
14678
1617
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1612
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + col2 / col0 - col1 * - 15 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1612
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + col2 / col0 - col1 * - 15 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + - 43 - col2 FROM tab0 AS cor0
----
-125
-44
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-1614
SELECT DISTINCT + 50 DIV 13 - - cor0.col2 * + col0 FROM tab1 cor0
----
165
3651
7683

skipif mysql # not compatible
query I rowsort label-1614
SELECT DISTINCT + 50 / 13 - - cor0.col2 * + col0 FROM tab1 cor0
----
165
3651
7683

query I rowsort
SELECT ALL + col2 + - col2 * + col0 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-1616
SELECT ALL - + col1 * - cor0.col1 + + cor0.col2 DIV + col1 FROM tab2 AS cor0
----
291
3481
961

skipif mysql # not compatible
query I rowsort label-1616
SELECT ALL - + col1 * - cor0.col1 + + cor0.col2 / + col1 FROM tab2 AS cor0
----
291
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col1 + 60 col2 FROM tab1 AS cor0
----
134
153
89

query I rowsort
SELECT DISTINCT - 88 AS col2 FROM tab1 AS cor0
----
-88

query I rowsort
SELECT col1 * col0 - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT col2 - cor0.col1 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL - col0 + col2 + 19 * 98 FROM tab2 AS cor0
----
1810
1821
1882

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1622
SELECT CAST( NULL AS SIGNED ) - col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1622
SELECT CAST ( NULL AS INTEGER ) - col1 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 12 + tab2.col2 AS col0 FROM tab2
----
38
39
50

query I rowsort
SELECT - 83 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT - col2 * - cor0.col2 - + 4 * 23 * - col2 AS col1 FROM tab1 AS cor0
----
18048
7884
8493

query I rowsort
SELECT DISTINCT + - 81 * cor0.col1 + + col0 * - col1 AS col1 FROM tab0 AS cor0
----
-11252
-15470
-9030

query I rowsort
SELECT - + 74 * - col2 FROM tab0 AS cor0
----
2442
6068
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 28 col1 FROM tab2 AS cor0
----
28
28
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-1629
SELECT DISTINCT - col2 + col1 DIV cor0.col0 FROM tab0 AS cor0
----
-30
-81
1

skipif mysql # not compatible
query I rowsort label-1629
SELECT DISTINCT - col2 + col1 / cor0.col0 FROM tab0 AS cor0
----
-30
-81
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1630
SELECT ALL + - col1 DIV col2 col0 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1630
SELECT ALL + - col1 / col2 col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + 12 + + col2 FROM tab2 AS cor0
----
38
39
50

query I rowsort
SELECT + col2 + + col2 * ( - col2 ) AS col2 FROM tab0 cor0
----
-1056
-6642
0

query I rowsort
SELECT + col2 * col2 * cor0.col1 AS col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT - col1 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-1635
SELECT DISTINCT + col1 DIV - col0 + 12 FROM tab0
----
10
11
9

skipif mysql # not compatible
query I rowsort label-1635
SELECT DISTINCT + col1 / - col0 + 12 FROM tab0
----
10
11
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1636
SELECT - col1 * col2 - ( cor0.col1 + + CAST( cor0.col1 AS SIGNED ) ) FROM tab0 AS cor0
----
-291
-3010
-7644

skipif mysql # not compatible
query I rowsort label-1636
SELECT - col1 * col2 - ( cor0.col1 + + CAST ( cor0.col1 AS INTEGER ) ) FROM tab0 AS cor0
----
-291
-3010
-7644

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 41 + col2 col2 FROM tab2
----
-14
-15
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1638
SELECT + col0 * col0 * - col0 + ( - col2 + CAST( NULL AS SIGNED ) ) col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1638
SELECT + col0 * col0 * - col0 + ( - col2 + CAST ( NULL AS INTEGER ) ) col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + 4 ) * + col0 FROM tab2 cor0
----
-28
-312
-316

query I rowsort
SELECT DISTINCT + col0 * 24 + - cor0.col2 * + col1 + + cor0.col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1173
1398
744

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab2, tab2 cor1, tab0 cor2
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

query I rowsort
SELECT 96 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT cor0.col1 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT col0 + - 98 * + col1 AS col0 FROM tab1
----
-1194
-2545
-916

onlyif mysql # use DIV operator for integer division
query I rowsort label-1645
SELECT ( - col0 ) * col1 + CAST( + col2 AS SIGNED ) DIV + col2 FROM tab0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-1645
SELECT ( - col0 ) * col1 + CAST ( + col2 AS INTEGER ) / + col2 FROM tab0
----
-2063
-3394
-8098

query I rowsort
SELECT ALL - ( - col1 ) * col2 + + 15 AS col1 FROM tab2 AS cor0
----
1549
661
852

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab0, tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + tab0.col1 * 70 AS col2 FROM tab0
----
6020
6370
6790

query I rowsort
SELECT - cor0.col1 * 57 AS col1 FROM tab1 cor0
----
-1482
-570
-741

query I rowsort
SELECT 52 + - cor0.col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
-137
-1976
-2950

query I rowsort
SELECT + - 51 * + col2 AS col0 FROM tab1 AS cor0
----
-2754
-2907
-4896

query I rowsort
SELECT DISTINCT - ( + cor1.col1 ) FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
-86
-91
-97

query I rowsort
SELECT ALL + ( + 90 ) * + col2 FROM tab1
----
4860
5130
8640

query I rowsort
SELECT DISTINCT 58 FROM tab0, tab1 AS cor0
----
58

query I rowsort
SELECT - col0 * + col1 * col1 + ( - cor0.col2 + col0 ) FROM tab1 AS cor0
----
-13536
-2079
-6393

onlyif mysql # use DIV operator for integer division
query I rowsort label-1656
SELECT + cor0.col0 * col0 + + cor0.col2 DIV 96 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-1656
SELECT + cor0.col0 * col0 + + cor0.col2 / 96 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL ( - 27 ) + - col0 * - 9 AS col2 FROM tab2
----
36
675
684

query I rowsort
SELECT ALL col0 + col1 + + ( + col1 ) * - col1 FROM tab1
----
-26
-647
-76

query I rowsort
SELECT ALL - + 85 * cor0.col0 * 19 + + 23 * tab2.col1 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 18fec4b2ae0c34d89b59e6c61ac5f10b

query I rowsort
SELECT ALL + tab2.col0 + col2 + col0 FROM tab2
----
182
196
41

query I rowsort
SELECT ALL + 37 + col2 FROM tab0
----
119
38
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-1662
SELECT DISTINCT - col2 DIV + tab0.col0 col0 FROM tab0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1662
SELECT DISTINCT - col2 / + tab0.col0 col0 FROM tab0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1663
SELECT DISTINCT + + cor0.col0 DIV - cor0.col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1663
SELECT DISTINCT + + cor0.col0 / - cor0.col1 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1664
SELECT - - cor0.col2 DIV col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-1664
SELECT - - cor0.col2 / col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ( col1 ) + - col2 * + col2 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT 53 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

query I rowsort
SELECT col2 + col2 - 88 FROM tab1 AS cor0
----
104
20
26

query I rowsort
SELECT DISTINCT tab0.col0 * - ( - 15 * - col1 ) FROM tab0
----
-121485
-30960
-50925

onlyif mysql # use DIV operator for integer division
query I rowsort label-1669
SELECT - - col1 DIV cor0.col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1669
SELECT - - col1 / cor0.col0 AS col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT - col1 * - col0 + - ( - col1 ) + col2 * - col2 * col1 FROM tab1 AS cor0
----
-118755
-31840
-75712

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1671
SELECT ALL - + CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-1671
SELECT ALL - + CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1672
SELECT ALL + CAST( NULL AS SIGNED ) * cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1672
SELECT ALL + CAST ( NULL AS INTEGER ) * cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + + col1 * + col0 - 54 FROM tab2 AS cor0
----
1289
163
4548

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col1 + col2 - col1 col2 FROM tab1 AS cor0
----
-50
-593
-957

query I rowsort
SELECT - - col0 + + 31 * - col0 FROM tab1 AS cor0
----
-1920
-2400
-90

query I rowsort
SELECT + col1 + - col1 * + col0 - col1 * 30 AS col2 FROM tab0 cor0
----
-10738
-4558
-6208

onlyif mysql # use DIV operator for integer division
query I rowsort label-1677
SELECT - + cor0.col0 + col0 DIV + col1 AS col2 FROM tab1 AS cor0
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-1677
SELECT - + cor0.col0 + col0 / + col1 AS col2 FROM tab1 AS cor0
----
-3
-58
-74

query I rowsort
SELECT + col0 + 32 AS col1 FROM tab2 AS cor0
----
110
111
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1679
SELECT - col0 + + CAST( + ( - col2 ) AS SIGNED ) * - 91 FROM tab1 AS cor0
----
4911
5123
8656

skipif mysql # not compatible
query I rowsort label-1679
SELECT - col0 + + CAST ( + ( - col2 ) AS INTEGER ) * - 91 FROM tab1 AS cor0
----
4911
5123
8656

query I rowsort
SELECT tab1.col1 + + ( col0 ) * - col2 + - 81 * col1 AS col1 FROM tab1
----
-2242
-4448
-8720

onlyif mysql # use DIV operator for integer division
query I rowsort label-1681
SELECT - tab0.col0 DIV ( col0 * col2 ) FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1681
SELECT - tab0.col0 / ( col0 * col2 ) FROM tab0
----
-1
0
0

query I rowsort
SELECT ALL + 49 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 col0 FROM tab2
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-1684
SELECT DISTINCT + tab0.col2 DIV col2 - col1 DIV - col1 AS col2 FROM tab0
----
2

skipif mysql # not compatible
query I rowsort label-1684
SELECT DISTINCT + tab0.col2 / col2 - col1 / - col1 AS col2 FROM tab0
----
2

query I rowsort
SELECT ALL + ( + cor0.col0 ) AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL + + col1 + col0 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - + ( + ( - col2 ) ) AS col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1688
SELECT col0 DIV 63 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-1688
SELECT col0 / 63 FROM tab1 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1689
SELECT DISTINCT - cor0.col1 DIV 26 AS col1 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-1689
SELECT DISTINCT - cor0.col1 / 26 AS col1 FROM tab1 AS cor0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1690
SELECT DISTINCT + col2 DIV - 43 AS col2 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1690
SELECT DISTINCT + col2 / - 43 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT + + col2 * + col2 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT + ( 98 ) + col2 AS col2 FROM tab0 AS cor0
----
131
180
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-1693
SELECT - - cor0.col1 DIV + 70 AS col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1693
SELECT - - cor0.col1 / + 70 AS col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT 48 * col0 FROM tab1 AS cor0
----
144
3072
3840

query I rowsort
SELECT DISTINCT - col2 * - ( col0 ) AS col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1696
SELECT DISTINCT + col1 * 97 DIV col2 FROM tab1
----
13
17
46

skipif mysql # not compatible
query I rowsort label-1696
SELECT DISTINCT + col1 * 97 / col2 FROM tab1
----
13
17
46

query I rowsort
SELECT ALL 2 + 10 AS col2 FROM tab1 AS cor0
----
12
12
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1698
SELECT DISTINCT CAST( NULL AS DECIMAL ) + col0 * col0 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1698
SELECT DISTINCT CAST ( NULL AS REAL ) + col0 * col0 AS col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col1 ) * cor0.col0 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 37 - - cor0.col2 FROM tab0 AS cor0
----
119
38
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-1701
SELECT + + 36 + + col2 DIV col1 FROM tab1 AS cor0
----
38
41
43

skipif mysql # not compatible
query I rowsort label-1701
SELECT + + 36 + + col2 / col1 FROM tab1 AS cor0
----
38
41
43

query I rowsort
SELECT ALL - 87 + - col1 AS col2 FROM tab0 AS cor0
----
-173
-178
-184

query I rowsort
SELECT 1 * col0 AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - 87 + ( - col2 ) * - 10 FROM tab0 AS cor0
----
-77
243
733

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1705
SELECT DISTINCT - CAST( cor0.col2 AS SIGNED ) * col0 + col2 * ( + col1 ) FROM tab1 AS cor0
----
-3078
-6432
1242

skipif mysql # not compatible
query I rowsort label-1705
SELECT DISTINCT - CAST ( cor0.col2 AS INTEGER ) * col0 + col2 * ( + col1 ) FROM tab1 AS cor0
----
-3078
-6432
1242

query I rowsort
SELECT DISTINCT - col1 * + 69 FROM tab0 cor0
----
-5934
-6279
-6693

query I rowsort
SELECT + 33 * - col1 FROM tab0 AS cor0
----
-2838
-3003
-3201

query I rowsort
SELECT + 93 + - col2 * - col0 AS col0 FROM tab1 AS cor0
----
255
3741
7773

query I rowsort
SELECT ALL + cor0.col2 + col1 + 93 FROM tab1 AS cor0
----
160
173
202

query I rowsort
SELECT DISTINCT cor0.col1 + col1 FROM tab0 AS cor0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 * + col1 col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT + col2 * - col1 + cor0.col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT cor0.col1 + cor0.col2 * 28 AS col2 FROM tab2 AS cor0
----
1081
787
787

query I rowsort
SELECT + + 97 * col1 AS col0 FROM tab2 AS cor0
----
1649
3007
5723

query I rowsort
SELECT ALL - col0 + col0 * - col2 FROM tab1 AS cor0
----
-165
-3712
-7760

skipif mysql # not compatible
query I rowsort
SELECT ALL - - col1 * ( - cor0.col2 ) - + col2 * CAST ( + 76 AS REAL ) AS col1 FROM tab2 cor0
----
-2889
-3510
-3534

query I rowsort
SELECT ALL - - col2 * - 77 + col1 AS col0 FROM tab0 AS cor0
----
-2455
-6223
20

query I rowsort
SELECT DISTINCT - + col2 + ( col2 + col0 * col2 ) AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT 56 AS col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

query I rowsort
SELECT ALL + col2 + - col1 + + col1 * + col0 AS col1 FROM tab0 AS cor0
----
2011
3299
8090

query I rowsort
SELECT - col2 * col2 + col2 FROM tab2
----
-1406
-650
-702

query I rowsort
SELECT + col0 * + col0 - - col0 FROM tab0
----
1260
600
8010

query I rowsort
SELECT DISTINCT - col1 * - col1 * + col2 AS col2 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT - - col2 + - cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - + col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - tab1.col1 + - tab1.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 5f7b5c5678d2f6f42d8763f44ca95184

query I rowsort
SELECT + tab2.col2 + col0 AS col1 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL col1 * + tab2.col0 + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT + col0 + + col0 * + tab2.col2 + tab2.col0 * - col2 FROM tab2
----
7
78
79

query I rowsort
SELECT - col2 + tab0.col0 * + col1 AS col1 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT col0 * tab2.col1 + tab2.col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 + col1 + col2 AS col0 FROM tab2 AS cor0
----
107
6169
6296

query I rowsort
SELECT - col2 + col2 * - col0 AS col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT - - col2 * - col0 - col2 AS col0 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT ALL - col1 - + col2 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT - col2 FROM tab2 WHERE ( NULL ) NOT IN ( + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1737
SELECT ALL tab1.col0 * - col0 + col0 DIV + col1 + + col0 FROM tab1
----
-4026
-6
-6314

skipif mysql # not compatible
query I rowsort label-1737
SELECT ALL tab1.col0 * - col0 + col0 / + col1 + + col0 FROM tab1
----
-4026
-6
-6314

query I rowsort
SELECT cor0.col1 + + col1 AS col1 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT col2 - + col2 * tab1.col2 * - col0 AS col1 FROM tab1
----
207993
737376
8802

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 32 * + col2 col1 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT ALL - col2 + col2 + col0 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - - col0 + + col1 * - col2 AS col0 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + col0 + col2 * - col2 AS col2 FROM tab0 AS cor0
----
-1065
-6635
34

query IIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 WHERE NOT ( NULL ) NOT IN ( cor0.col1 )
----

query I rowsort
SELECT ALL cor0.col0 * col1 + + col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1209
740
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-1746
SELECT ALL + col2 * col2 + col1 DIV - col2 FROM tab1 cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-1746
SELECT ALL + col2 * col2 + col1 / - col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + col2 AS col2 FROM tab0 WHERE NULL >= col2 + col2
----

query I rowsort
SELECT DISTINCT - tab1.col1 AS col1 FROM tab1 WHERE NOT + col1 = NULL
----

query I rowsort
SELECT col2 FROM tab0 WHERE NOT NULL >= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1750
SELECT + col1 DIV tab1.col1 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1750
SELECT + col1 / tab1.col1 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL + tab1.col0 * + tab1.col2 * - col0 FROM tab1
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 col2 FROM tab1 WHERE NOT NULL < NULL
----

query I rowsort
SELECT DISTINCT + col2 - col2 AS col1 FROM tab1
----
0

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab0 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 04ab51615fd2c7e492de6a59e98226e1

query I rowsort
SELECT - 77 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT DISTINCT + col2 * col0 AS col0 FROM tab2 WHERE ( NULL ) BETWEEN + col0 * col0 + + col1 AND NULL
----

query III rowsort
SELECT * FROM tab2 WHERE NOT + col2 / col0 < col2 * col1
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( + col0 / - tab0.col0 ) IN ( + col2 )
----

query I rowsort
SELECT ALL - 79 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c9cc9510604e093bd158ca33928acaed

query I rowsort
SELECT DISTINCT + tab2.col2 - col1 * + col2 AS col2 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT - col0 * col2 * cor0.col1 AS col2 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL col1 * col0 - + col0 AS col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT - col1 AS col0 FROM tab0 AS cor0 WHERE - col2 > NULL
----

query I rowsort
SELECT + col2 + col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT col0 FROM tab1 AS cor0 WHERE NOT + col2 * + col2 > ( NULL )
----

query I rowsort
SELECT col2 + tab2.col1 AS col2 FROM tab2 WHERE ( + col2 * col2 + - col1 ) = ( NULL )
----

query I rowsort
SELECT col2 * - col0 * + col2 + col1 * + col0 FROM tab1
----
-207296
-736240
-8670

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 col0 FROM tab1 WHERE ( NULL ) IN ( - col0 + + col2 + tab1.col2 )
----

query I rowsort
SELECT tab2.col2 * col0 + + col2 FROM tab2
----
2054
216
3040

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL IN ( - col1 * col2 + - col1 )
----

query I rowsort
SELECT - col1 FROM tab2 WHERE + col1 + col1 <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - tab1.col2 * col0 col1 FROM tab1
----
-188
-3658
-7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-1773
SELECT DISTINCT col2 DIV col2 FROM tab2 WHERE NOT col1 * tab2.col1 + col2 NOT BETWEEN col1 * + col1 AND col1 * + col0
----
1

skipif mysql # not compatible
query I rowsort label-1773
SELECT DISTINCT col2 / col2 FROM tab2 WHERE NOT col1 * tab2.col1 + col2 NOT BETWEEN col1 * + col1 AND col1 * + col0
----
1

query I rowsort
SELECT col0 + - col0 - col0 * + col0 FROM tab0 WHERE + tab0.col2 + - col0 NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT col1 * col0 + col0 * col2 FROM tab0
----
15397
2856
3430

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL = + col2
----

query I rowsort
SELECT - col0 AS col1 FROM tab2 WHERE NOT - col0 >= ( - col1 )
----
-78
-79

query I rowsort
SELECT tab1.col1 - + col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT col1 * - col1 + col1 + col1 FROM tab0
----
-7224
-8099
-9215

onlyif mysql # use DIV operator for integer division
query I rowsort label-1780
SELECT - - cor0.col0 + - col0 DIV - col0 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-1780
SELECT - - cor0.col0 + - col0 / - col0 FROM tab0 AS cor0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1781
SELECT cor0.col2 DIV + col0 - - col0 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-1781
SELECT cor0.col2 / + col0 - - col0 FROM tab1 AS cor0
----
21
64
81

query I rowsort
SELECT cor0.col2 + - col1 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT 66 + col2 AS col0 FROM tab0 AS cor0
----
148
67
99

query I rowsort
SELECT ALL + + cor0.col0 AS col1 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT + col0 - col0 * col0 AS col0 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1786
SELECT + ( col2 ) * + CAST( NULL AS SIGNED ) - - col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1786
SELECT + ( col2 ) * + CAST ( NULL AS INTEGER ) - - col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * 9 FROM tab2 AS cor0
----
234
243
342

onlyif mysql # use DIV operator for integer division
query I rowsort label-1788
SELECT + col2 + - col2 DIV 19 FROM tab1 AS cor0
----
52
54
91

skipif mysql # not compatible
query I rowsort label-1788
SELECT + col2 + - col2 / 19 FROM tab1 AS cor0
----
52
54
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-1789
SELECT DISTINCT col1 DIV + cor0.col1 AS col0 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-1789
SELECT DISTINCT col1 / + cor0.col1 AS col0 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort
SELECT ALL - col2 + + CAST ( - col1 AS REAL ) AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL + 65 + 79 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a9cc77a5f1bc643a947b8c416f454170

query I rowsort
SELECT + 22 * col1 AS col1 FROM tab0 AS cor0
----
1892
2002
2134

query I rowsort
SELECT - 53 * - col2 AS col2 FROM tab0 AS cor0
----
1749
4346
53

query I rowsort
SELECT DISTINCT + 7 * 40 AS col2 FROM tab2 AS cor0
----
280

query I rowsort
SELECT DISTINCT col0 + + col2 * + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - 1 + col0 * col2 AS col1 FROM tab0 AS cor0
----
34
7297
791

query I rowsort
SELECT + 53 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

onlyif mysql # use DIV operator for integer division
query I rowsort label-1798
SELECT col1 - + ( - tab1.col2 ) DIV ( + 76 ) AS col2 FROM tab1
----
10
14
26

skipif mysql # not compatible
query I rowsort label-1798
SELECT col1 - + ( - tab1.col2 ) / ( + 76 ) AS col2 FROM tab1
----
10
14
26

query I rowsort
SELECT - ( + col0 ) - col0 AS col1 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT DISTINCT - col1 * 46 * col1 AS col1 FROM tab0
----
-340216
-380926
-432814

query I rowsort
SELECT DISTINCT 87 + + col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1161
-1317
-483

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1802
SELECT ALL cor0.col2 + - col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1802
SELECT ALL cor0.col2 + - 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-1803
SELECT + CAST( col1 * - tab1.col2 AS SIGNED ) AS col1 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-1803
SELECT + CAST ( col1 * - tab1.col2 AS INTEGER ) AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL 98 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT ALL + 73 + + col2 FROM tab2 AS cor0
----
100
111
99

query I rowsort
SELECT ALL + 4 * + col1 AS col0 FROM tab1
----
104
40
52

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1, tab1 cor0, tab0 cor1
----
972 values hashing to b51b4342db121ebc2d3d353dcd8ed521

query I rowsort
SELECT ALL 95 * col1 FROM tab2
----
1615
2945
5605

onlyif mysql # use DIV operator for integer division
query I rowsort label-1809
SELECT 93 + - col2 DIV col0 AS col2 FROM tab1
----
75
92
93

skipif mysql # not compatible
query I rowsort label-1809
SELECT 93 + - col2 / col0 AS col2 FROM tab1
----
75
92
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1810
SELECT ALL cor0.col2 DIV col0 + col2 FROM tab2 cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-1810
SELECT ALL cor0.col2 / col0 + col2 FROM tab2 cor0
----
26
30
38

query I rowsort
SELECT ALL + + col0 * col1 + 42 FROM tab0 AS cor0
----
2106
3437
8141

query I rowsort
SELECT ALL - col1 - - cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * - tab2.col1 * ( + col0 ) AS col0 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT 84 FROM tab0, tab1 AS cor0, tab2 cor1
----
84

query I rowsort
SELECT ALL col2 + col0 + + ( col2 ) FROM tab2
----
130
155
61

query I rowsort
SELECT DISTINCT 20 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
20

query I rowsort
SELECT DISTINCT + col1 + tab2.col2 * + 79 AS col2 FROM tab2
----
2113
2164
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-1818
SELECT DISTINCT col0 + col0 DIV col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-1818
SELECT DISTINCT col0 + col0 / col2 FROM tab0
----
24
70
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 72 * - 76 col2 FROM tab0 cor0
----
5472
5472
5472

query I rowsort
SELECT - col0 * 18 AS col2 FROM tab2 AS cor0
----
-126
-1404
-1422

query I rowsort
SELECT + col2 + col1 * - col0 * - ( + col1 ) + + col2 FROM tab1 AS cor0
----
13712
2136
6514

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( 53 AS REAL ) * col0 col0 FROM tab0 cor0
----
1272
1855
4717

query I rowsort
SELECT ALL 6 * - col2 FROM tab2 AS cor0
----
-156
-162
-228

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1824
SELECT DISTINCT - CAST( NULL AS SIGNED ) * cor0.col0 + + col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1824
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * cor0.col0 + + col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + 91 * col2 AS col2 FROM tab2 AS cor0
----
2366
2457
3458

query I rowsort
SELECT ALL col1 * col2 AS col1 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-1827
SELECT ALL + + 86 DIV col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-1827
SELECT ALL + + 86 / col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT ALL - col1 * + col1 * + col1 FROM tab0 AS cor0
----
-636056
-753571
-912673

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1829
SELECT DISTINCT - + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1829
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 76 * cor0.col0 FROM tab2 AS cor0
----
532
5928
6004

query I rowsort
SELECT col2 * cor0.col2 + + col1 * + ( - ( - col1 ) + 30 ) AS col0 FROM tab1 AS cor0
----
3649
4372
9775

query I rowsort
SELECT ALL - col0 + + col2 * col2 AS col1 FROM tab0 cor0
----
-34
1065
6635

query I rowsort
SELECT - ( - cor0.col2 ) * - col2 + ( col1 ) + - col0 FROM tab2 cor0
----
-1506
-695
-705

query I rowsort
SELECT DISTINCT + cor0.col0 + 42 + + col0 AS col2 FROM tab2 AS cor0
----
198
200
56

query I rowsort
SELECT ALL + + ( - col1 ) AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL col0 + - col0 + + col2 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + + col0 * 80 FROM tab0 AS cor0
----
1920
2800
7120

query I rowsort
SELECT ALL col2 + ( col1 ) AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT 43 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT cor0.col0 * + ( col2 ) * col1 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 + col1 + col2 col2 FROM tab0 AS cor0
----
195
2957
7635

query I rowsort
SELECT cor0.col0 + - 77 AS col0 FROM tab0 AS cor0
----
-42
-53
12

query I rowsort
SELECT DISTINCT + - col2 + + col1 + col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + col0 * 6 * col2 FROM tab1 AS cor0
----
21888
46080
972

query I rowsort
SELECT + ( ( col0 ) ) * 59 * col0 AS col1 FROM tab1 AS cor0
----
241664
377600
531

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1846
SELECT - CAST( NULL AS DECIMAL ) * + 39 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1846
SELECT - CAST ( NULL AS REAL ) * + 39 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col0 * - 47 FROM tab0 AS cor0
----
-1128
-1645
-4183

query I rowsort
SELECT DISTINCT 91 * - 37 AS col1 FROM tab1, tab1 AS cor0
----
-3367

query I rowsort
SELECT DISTINCT - 54 FROM tab1, tab0, tab1 AS cor0, tab2
----
-54

onlyif mysql # use DIV operator for integer division
query I rowsort label-1850
SELECT ALL col1 DIV 43 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1850
SELECT ALL col1 / 43 FROM tab2
----
0
0
1

query I rowsort
SELECT DISTINCT 75 * col2 - - col2 FROM tab0 cor0
----
2508
6232
76

query I rowsort
SELECT ALL + - ( col0 ) + col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1853
SELECT DISTINCT + col2 + cor0.col1 DIV 42 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1853
SELECT DISTINCT + col2 + cor0.col1 / 42 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col1 * ( + 23 ) col2 FROM tab1 AS cor0
----
287
395
652

query I rowsort
SELECT - 91 * cor0.col2 FROM tab0 cor0
----
-3003
-7462
-91

query I rowsort
SELECT ALL + col1 * col2 - cor0.col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT 36 * - col2 FROM tab0 AS cor0
----
-1188
-2952
-36

query I rowsort
SELECT ALL + col1 + cor0.col0 * - 67 FROM tab0 AS cor0
----
-1522
-2248
-5872

query I rowsort
SELECT ALL + + col2 * col0 + col2 * + ( - col1 + 79 ) FROM tab1 AS cor0
----
14016
3024
7581

query I rowsort
SELECT DISTINCT ( - col1 ) + col2 * - tab0.col2 AS col0 FROM tab0
----
-1175
-6815
-98

query I rowsort
SELECT - 98 FROM tab1, tab0 cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT - 75 - - col0 * tab0.col2 FROM tab0
----
-40
717
7223

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + - col0 col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT col0 * col2 + + col1 AS col2 FROM tab2
----
2087
220
3019

query I rowsort
SELECT ALL + 40 AS col0 FROM tab1 AS cor0
----
40
40
40

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL + - cor0.col0 * col0 * + col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT 46 * col0 FROM tab2 AS cor0
----
322
3588
3634

query I rowsort
SELECT ALL - + 72 + col2 * + 30 AS col1 FROM tab0 AS cor0
----
-42
2388
918

query I rowsort
SELECT DISTINCT col1 * col0 + 79 AS col0 FROM tab0 AS cor0
----
2143
3474
8178

query I rowsort
SELECT ALL + tab1.col1 + - 84 FROM tab1, tab2 AS cor0
----
9 values hashing to e9e352a769504bbf3d7c60efae6b2ab5

query I rowsort
SELECT - 23 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT + ( - tab2.col0 * + col0 ) AS col2 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT + col2 * 98 AS col0 FROM tab2 AS cor0
----
2548
2646
3724

query I rowsort
SELECT cor0.col2 * + col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT col0 + cor0.col1 * col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + 97 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 cor1
----
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1878
SELECT + col0 DIV 80 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1878
SELECT + col0 / 80 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1879
SELECT + col2 + - col0 DIV + 80 AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-1879
SELECT + col2 + - col0 / + 80 AS col1 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1880
SELECT col1 DIV + 41 + col1 AS col0 FROM tab0 AS cor0
----
88
93
99

skipif mysql # not compatible
query I rowsort label-1880
SELECT col1 / + 41 + col1 AS col0 FROM tab0 AS cor0
----
88
93
99

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 DISTINCT 34 + 76 col2 FROM tab0
----
110

query I rowsort
SELECT + 77 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

onlyif mysql # use DIV operator for integer division
query I rowsort label-1884
SELECT DISTINCT - - 65 * col2 + col1 DIV - col1 + 44 FROM tab2 AS cor0
----
1733
1798
2513

skipif mysql # not compatible
query I rowsort label-1884
SELECT DISTINCT - - 65 * col2 + col1 / - col1 + 44 FROM tab2 AS cor0
----
1733
1798
2513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1885
SELECT DISTINCT - CAST( - col0 AS SIGNED ) + + cor0.col1 col1 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1885
SELECT DISTINCT - CAST ( - col0 AS INTEGER ) + + cor0.col1 col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1886
SELECT ALL CAST( - col2 AS SIGNED ) FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-1886
SELECT ALL CAST ( - col2 AS INTEGER ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT ( - cor0.col0 ) * + cor0.col1 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL cor0.col1 + cor0.col0 + col0 FROM tab1 AS cor0
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-1889
SELECT + - col2 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1889
SELECT + - col2 / col0 AS col1 FROM tab0 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1890
SELECT col1 + col0 DIV col0 AS col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-1890
SELECT col1 + col0 / col0 AS col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT + - col2 * col1 AS col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - - col2 + col1 * col0 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-1893
SELECT + - ( + cor0.col0 ) DIV - 26 + + cor0.col2 * col1 col0 FROM tab0 AS cor0
----
2838
7465
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1893
SELECT + - ( + cor0.col0 ) / - 26 + + cor0.col2 * col1 col0 FROM tab0 AS cor0
----
2838
7465
98

query I rowsort
SELECT col0 + + col1 * col1 AS col0 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # use DIV operator for integer division
query I rowsort label-1895
SELECT - + col2 DIV 90 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1895
SELECT - + col2 / 90 AS col2 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1896
SELECT - - 21 DIV - 33 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1896
SELECT - - 21 / - 33 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1897
SELECT - col1 * ( + col0 ) DIV + col0 + - col1 FROM tab2 AS cor0
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-1897
SELECT - col1 * ( + col0 ) / + col0 + - col1 FROM tab2 AS cor0
----
-118
-34
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1898
SELECT ALL + col1 * - 68 * - col2 + CAST( - col1 AS SIGNED ) + + col0 * ( + 84 ) AS col1 FROM tab0 AS cor0
----
194914
514801
9439

skipif mysql # not compatible
query I rowsort label-1898
SELECT ALL + col1 * - 68 * - col2 + CAST ( - col1 AS INTEGER ) + + col0 * ( + 84 ) AS col1 FROM tab0 AS cor0
----
194914
514801
9439

query I rowsort
SELECT DISTINCT 95 + 46 AS col0 FROM tab1 AS cor0
----
141

query I rowsort
SELECT ALL + - col2 * + col2 + col0 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT + 80 * 82 + - col0 AS col0 FROM tab1 cor0
----
6480
6496
6557

query I rowsort
SELECT 66 * - col0 + col2 * col0 FROM tab1
----
-36
-576
2400

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab0, tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT + 44 FROM tab0 cor0
----
44
44
44

query I rowsort
SELECT col1 * - col1 * - col2 AS col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT + - cor0.col1 + + col1 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + - cor0.col1 + 47 * - 43 FROM tab0 AS cor0
----
-2107
-2112
-2118

query I rowsort
SELECT DISTINCT col0 + cor0.col2 * col0 AS col0 FROM tab1 cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-1909
SELECT - cor0.col1 DIV col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1909
SELECT - cor0.col1 / col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL 55 * tab1.col1 AS col1 FROM tab1
----
1430
550
715

query I rowsort
SELECT ALL col0 * col0 + 7 FROM tab2 AS cor0
----
56
6091
6248

query I rowsort
SELECT DISTINCT + col2 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT col0 + + ( + col0 ) + - col2 AS col0 FROM tab0 AS cor0
----
15
69
96

query I rowsort
SELECT 1 * + col2 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT + col1 + + ( col0 ) AS col2 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL col0 + - cor0.col1 * - col1 AS col2 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT - col0 * + col2 + col1 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT col2 + cor0.col1 + + col0 * col2 AS col2 FROM tab2 cor0
----
2113
247
3057

query I rowsort
SELECT DISTINCT + 12 * col1 AS col0 FROM tab1 AS cor0
----
120
156
312

query I rowsort
SELECT - + 64 + 75 * col0 AS col1 FROM tab1 AS cor0
----
161
4736
5936

onlyif mysql # use DIV operator for integer division
query I rowsort label-1921
SELECT 20 DIV 73 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-1921
SELECT 20 / 73 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + col0 * 83 + - col1 FROM tab1
----
223
5302
6627

query I rowsort
SELECT 16 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT 40 * 9 FROM tab2
----
360
360
360

query I rowsort
SELECT 29 + + col1 AS col0 FROM tab2 AS cor0
----
46
60
88

query I rowsort
SELECT ALL + + 73 + cor0.col1 * col2 FROM tab1 AS cor0
----
1321
1477
643

query I rowsort
SELECT col1 * + col1 + 35 * col1 FROM tab1 AS cor0
----
1586
450
624

query I rowsort
SELECT DISTINCT + col1 * - col1 * tab1.col0 + - ( - 93 ) - col2 * col0 FROM tab1
----
-2097
-21107
-9955

onlyif mysql # use DIV operator for integer division
query I rowsort label-1929
SELECT - col1 * tab2.col1 + col1 DIV 82 - 48 col2 FROM tab2
----
-1009
-337
-3529

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1929
SELECT - col1 * tab2.col1 + col1 / 82 - 48 col2 FROM tab2
----
-1009
-337
-3529

query I rowsort
SELECT + col0 + 25 * + col0 - + 86 AS col2 FROM tab0
----
2228
538
824

query I rowsort
SELECT ALL 2 - 13 AS col0 FROM tab2
----
-11
-11
-11

query I rowsort
SELECT DISTINCT + 97 * col1 FROM tab0
----
8342
8827
9409

query I rowsort
SELECT DISTINCT - 17 + 71 - col1 AS col0 FROM tab0
----
-32
-37
-43

query I rowsort
SELECT + tab0.col0 * col2 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 91 + col1 col0 FROM tab0
----
177
182
188

query I rowsort
SELECT DISTINCT col2 + col2 * col0 FROM tab2
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-1937
SELECT ( col1 ) * col2 + ( + col0 ) DIV - col1 FROM tab2 AS cor0
----
1533
642
837

skipif mysql # not compatible
query I rowsort label-1937
SELECT ( col1 ) * col2 + ( + col0 ) / - col1 FROM tab2 AS cor0
----
1533
642
837

query I rowsort
SELECT - 58 + + col0 FROM tab1 AS cor0
----
-55
22
6

query I rowsort
SELECT DISTINCT - 65 + col0 * 15 AS col1 FROM tab2 AS cor0
----
1105
1120
40

query I rowsort
SELECT DISTINCT + 5 * col2 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-92
319
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1941
SELECT - 66 / col1 + - 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-1941
SELECT - 66 / col1 + - CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * cor0.col2 + - 67 AS col0 FROM tab2 AS cor0
----
-1601
-713
-904

query I rowsort
SELECT + - col2 * col0 + ( + 44 ) FROM tab2 cor0
----
-145
-1984
-2958

query I rowsort
SELECT + col0 + - 44 * + col0 AS col1 FROM tab2
----
-301
-3354
-3397

query I rowsort
SELECT - col1 * + 66 AS col0 FROM tab2
----
-1122
-2046
-3894

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1946
SELECT DISTINCT CAST( tab2.col2 AS SIGNED ) FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-1946
SELECT DISTINCT CAST ( tab2.col2 AS INTEGER ) FROM tab2
----
26
27
38

query I rowsort
SELECT + + ( + col1 ) * + cor0.col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL + - cor0.col1 + - col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1949
SELECT ALL + + CAST( - col2 AS SIGNED ) * col1 + ( - col1 ) + + col2 FROM tab1 AS cor0
----
-1165
-1376
-523

skipif mysql # not compatible
query I rowsort label-1949
SELECT ALL + + CAST ( - col2 AS INTEGER ) * col1 + ( - col1 ) + + col2 FROM tab1 AS cor0
----
-1165
-1376
-523

query I rowsort
SELECT DISTINCT - + ( cor0.col1 ) * - col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL 61 AS col2 FROM tab1 AS cor0
----
61
61
61

query I rowsort
SELECT DISTINCT + ( col2 ) + 37 FROM tab2 AS cor0
----
63
64
75

query I rowsort
SELECT DISTINCT - col2 * - col0 + col2 * 49 + col2 FROM tab0 AS cor0
----
11398
2442
85

query I rowsort
SELECT DISTINCT - 41 * + col2 FROM tab0 AS cor0
----
-1353
-3362
-41

query I rowsort
SELECT DISTINCT col0 * + col1 * + 34 FROM tab1 cor0
----
21760
2652
35360

onlyif mysql # use DIV operator for integer division
query I rowsort label-1956
SELECT DISTINCT + + col2 DIV col1 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1956
SELECT DISTINCT + + col2 / col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL 71 + - col2 AS col0 FROM tab1 AS cor0
----
-25
14
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1958
SELECT ( - col1 + + col1 ) * + CAST( - col0 AS SIGNED ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1958
SELECT ( - col1 + + col1 ) * + CAST ( - col0 AS INTEGER ) FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1959
SELECT DISTINCT + CAST( NULL AS SIGNED ) * ( col2 + col2 ) AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-1959
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * ( col2 + col2 ) AS col0 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1960
SELECT ALL ( + col0 ) DIV col1 AS col0 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-1960
SELECT ALL ( + col0 ) / col1 AS col0 FROM tab1
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 + - 73 col1 FROM tab1 AS cor0
----
5
567
967

query I rowsort
SELECT DISTINCT + + cor0.col2 + - col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + col0 * col0 - col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT DISTINCT - col0 + col0 * 89 FROM tab0 AS cor0
----
2112
3080
7832

query I rowsort
SELECT DISTINCT + - cor0.col2 + - col0 + col2 * col0 FROM tab1 cor0
----
105
3527
7504

query I rowsort
SELECT ALL - col0 * 7 FROM tab0 AS cor0
----
-168
-245
-623

query I rowsort
SELECT DISTINCT - - cor0.col1 * + col0 + + col2 FROM tab1 AS cor0
----
1136
132
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + 42 col0 FROM tab0 AS cor0
----
-44
-49
-55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col0 + + col0 col2 FROM tab2
----
182
196
41

query I rowsort
SELECT + cor0.col1 - - 69 FROM tab0 AS cor0
----
155
160
166

query I rowsort
SELECT col2 + + col2 - 10 FROM tab1
----
104
182
98

query I rowsort
SELECT col1 * - col1 + + 53 - 21 FROM tab0
----
-7364
-8249
-9377

query I rowsort
SELECT DISTINCT - 23 - col0 FROM tab1
----
-103
-26
-87

query I rowsort
SELECT - col0 * - col0 + 57 AS col1 FROM tab2
----
106
6141
6298

query I rowsort
SELECT + - col1 * col2 + + 33 AS col0 FROM tab1 AS cor0
----
-1215
-1371
-537

query I rowsort
SELECT ALL + + col0 - - ( - 21 ) FROM tab0 AS cor0
----
14
3
68

query I rowsort
SELECT col2 - + col1 * 47 FROM tab0 AS cor0
----
-4009
-4195
-4558

query I rowsort
SELECT DISTINCT - - col2 + col0 * + 64 FROM tab2 AS cor0
----
475
5018
5094

onlyif mysql # use DIV operator for integer division
query I rowsort label-1979
SELECT ALL - + col0 DIV - ( 60 ) FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1979
SELECT ALL - + col0 / - ( 60 ) FROM tab0 cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + 35 AS col1 FROM tab2, tab2 AS cor0
----
35

query I rowsort
SELECT + tab0.col1 * col2 + + tab0.col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT + cor0.col2 * - col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor2.col2 col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2, tab2 AS cor3
----
243 values hashing to 291cdf20f55dc7bbcb55f561dc0b74d8

query I rowsort
SELECT + col0 * + col2 * col1 AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT ( - col1 ) * - col1 + + 58 FROM tab0 AS cor0
----
7454
8339
9467

query I rowsort
SELECT col1 + 4 AS col0 FROM tab0 cor0
----
101
90
95

query I rowsort
SELECT - ( ( + col2 ) ) - col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - 41 - - col1 FROM tab2 AS cor0
----
-10
-24
18

query I rowsort
SELECT ALL tab0.col1 + col0 * - 78 * col1 AS col0 FROM tab0
----
-160906
-264713
-631631

query I rowsort
SELECT col2 * ( - col0 + - col1 * + 0 ) FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT - - col0 * + col0 + col0 * + col0 + col0 AS col2 FROM tab2 AS cor0
----
105
12246
12561

query I rowsort
SELECT ALL 15 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT ALL col1 + tab2.col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL - ( - col1 ) * - col1 + - col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT 46 + 37 AS col2 FROM tab0 AS cor0
----
83
83
83

query I rowsort
SELECT - + 90 * + col0 FROM tab1 AS cor0
----
-270
-5760
-7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-1997
SELECT + col0 DIV ( + col1 ) FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1997
SELECT + col0 / ( + col1 ) FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - - col1 * 13 FROM tab2 AS cor0
----
221
403
767

onlyif mysql # use DIV operator for integer division
query I rowsort label-1999
SELECT + tab0.col2 DIV 59 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1999
SELECT + tab0.col2 / 59 FROM tab0
----
0
0
1

query I rowsort
SELECT DISTINCT 42 * cor0.col2 AS col1 FROM tab0, tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT col1 + 83 * + 3 FROM tab2 cor0
----
266
280
308

query I rowsort
SELECT DISTINCT + col2 + - 44 * col2 + + cor0.col2 FROM tab0 AS cor0
----
-1386
-3444
-42

query I rowsort
SELECT DISTINCT col2 * + col0 * 12 AS col2 FROM tab0 cor0
----
420
87576
9504

query I rowsort
SELECT ALL + col0 * - col2 - cor0.col1 AS col1 FROM tab1 cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL + col1 * cor0.col0 + + col0 * - col2 AS col2 FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT col0 * + 24 AS col2 FROM tab2 cor0
----
168
1872
1896

query I rowsort
SELECT DISTINCT + + cor0.col1 * ( 7 ) - + col1 * - col2 AS col0 FROM tab0 cor0
----
3440
776
8099

query I rowsort
SELECT ALL - + col2 * - 47 FROM tab0 AS cor0
----
1551
3854
47

query I rowsort
SELECT DISTINCT + cor0.col0 + 14 AS col2 FROM tab0 AS cor0
----
103
38
49

query I rowsort
SELECT ALL - col0 * col0 - 28 FROM tab2 AS cor0
----
-6112
-6269
-77

query I rowsort
SELECT - col0 * 9 AS col1 FROM tab2 AS cor0
----
-63
-702
-711

query I rowsort
SELECT - col2 + col0 * - col1 FROM tab0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT 30 * - col0 FROM tab0
----
-1050
-2670
-720

query I rowsort
SELECT + 18 FROM tab1, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT - + col0 * - col0 * - col2 AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT - col1 * - ( + cor0.col2 ) AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT col1 * + 91 AS col1 FROM tab0 AS cor0
----
7826
8281
8827

onlyif mysql # use DIV operator for integer division
query I rowsort label-2018
SELECT col0 DIV col1 - col0 * col1 * + col2 FROM tab2
----
-119651
-51030
-5859

skipif mysql # not compatible
query I rowsort label-2018
SELECT col0 / col1 - col0 * col1 * + col2 FROM tab2
----
-119651
-51030
-5859

query I rowsort
SELECT + col1 * + col2 + + col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT - col0 - - col2 AS col2 FROM tab1 WHERE NOT NULL NOT BETWEEN NULL AND col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2021
SELECT + col2 * + col0 DIV col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2021
SELECT + col2 * + col0 / col0 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2022
SELECT col1 DIV + tab2.col1 AS col2 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2022
SELECT col1 / + tab2.col1 AS col2 FROM tab2
----
1
1
1

query I rowsort
SELECT col1 * tab2.col1 - col0 AS col0 FROM tab2
----
210
3403
954

onlyif mysql # use DIV operator for integer division
query I rowsort label-2024
SELECT DISTINCT - col2 DIV tab2.col0 col0 FROM tab2
----
-3
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2024
SELECT DISTINCT - col2 / tab2.col0 col0 FROM tab2
----
-3
0

query I rowsort
SELECT ALL col1 * col1 * col1 + + col1 - - col1 FROM tab0
----
636228
753753
912867

query I rowsort
SELECT - col2 * col1 + col2 AS col1 FROM tab1
----
-1152
-1350
-513

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col1 * - col2 BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT + col2 + + col1 + tab0.col0 AS col0 FROM tab0
----
133
143
262

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) NOT IN ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 + - col0 * + col0 col0 FROM tab0
----
-1226
-609
-8003

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( - col0 ) * + ( - col2 * - col2 ) col1 FROM tab2 AS cor0
----
-114076
-5103
-52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 + - 79 col2 FROM tab2
----
1455
567
758

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col1 col2 FROM tab1
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2034
SELECT ( col1 ) DIV + ( - 16 ) FROM tab0 AS cor0
----
-5
-5
-6

skipif mysql # not compatible
query I rowsort label-2034
SELECT ( col1 ) / + ( - 16 ) FROM tab0 AS cor0
----
-5
-5
-6

query I rowsort
SELECT + ( 51 ) FROM tab0, tab0 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT DISTINCT 63 * - tab0.col1 + + 45 FROM tab0
----
-5373
-5688
-6066

query I rowsort
SELECT + 86 * - col2 AS col2 FROM tab1
----
-4644
-4902
-8256

query I rowsort
SELECT - - 31 * col1 + col1 FROM tab1 cor0
----
320
416
832

query I rowsort
SELECT ALL col2 + + col2 * + col0 AS col1 FROM tab2 AS cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 16 * col0 + - ( col1 ) col2 FROM tab1 AS cor0
----
-1034
-1293
-74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col2 + - col2 * - 77 col0 FROM tab2 cor0
----
1976
2052
2888

query I rowsort
SELECT DISTINCT + + 77 + cor0.col0 FROM tab2 AS cor0
----
155
156
84

query I rowsort
SELECT - 44 * col1 - 41 * col0 AS col1 FROM tab0 AS cor0
----
-4768
-5703
-7653

query I rowsort
SELECT DISTINCT col0 * + col2 + 62 AS col2 FROM tab2 AS cor0
----
2090
251
3064

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) * - 28 + 88 col2 FROM tab2 AS cor0
----
-108
-2096
-2124

query I rowsort
SELECT DISTINCT - - col2 * + col2 + - 54 AS col0 FROM tab1 AS cor0
----
2862
3195
9162

query I rowsort
SELECT DISTINCT - - col1 * + 41 FROM tab2 AS cor0
----
1271
2419
697

query I rowsort
SELECT - cor0.col0 + + col0 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + col2 * ( col1 ) + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT - cor0.col0 + + ( - col1 ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT + 19 + - col0 FROM tab1
----
-45
-61
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + cor0.col2 col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT + 90 FROM tab2, tab1 AS cor0, tab0 cor1, tab1 AS cor2
----
81 values hashing to 3b4644ef0734ed220952cae7e0648c4b

query I rowsort
SELECT ALL + col2 + 81 * - col1 - - ( col0 ) FROM tab0 cor0
----
-6909
-7200
-7821

query I rowsort
SELECT DISTINCT cor0.col2 * - col2 + + col1 * col1 - col1 FROM tab1 AS cor0
----
-2266
-3159
-9060

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2056
SELECT DISTINCT 47 * 4 + cor0.col2 * CAST( NULL AS SIGNED ) + - col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2056
SELECT DISTINCT 47 * 4 + cor0.col2 * CAST ( NULL AS INTEGER ) + - col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + 44 AS col0 FROM tab1 cor0
----
44
44
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-2058
SELECT 63 * col2 + col0 DIV - 57 AS col2 FROM tab2 AS cor0
----
1637
1701
2393

skipif mysql # not compatible
query I rowsort label-2058
SELECT 63 * col2 + col0 / - 57 AS col2 FROM tab2 AS cor0
----
1637
1701
2393

query I rowsort
SELECT ( tab2.col1 * col0 ) AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT - col1 * - col2 + col1 - + col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - col2 + 68 - col1 AS col0 FROM tab2
----
-17
10
13

query I rowsort
SELECT ( col0 ) * - 99 + + col0 FROM tab1 AS cor0
----
-294
-6272
-7840

query I rowsort
SELECT - - col1 * - col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - - col0 * - col2 + 34 * cor0.col1 FROM tab1 cor0
----
-3308
-7238
722

query I rowsort
SELECT ALL - - 24 + col1 * ( - cor0.col1 ) FROM tab1 AS cor0
----
-145
-652
-76

query I rowsort
SELECT ALL cor0.col1 + - col1 + - 78 AS col0 FROM tab2 AS cor0
----
-78
-78
-78

query I rowsort
SELECT + 6 + - col1 AS col1 FROM tab1 AS cor0
----
-20
-4
-7

query I rowsort
SELECT DISTINCT - 10 * col2 AS col2 FROM tab2 AS cor0
----
-260
-270
-380

query I rowsort
SELECT - col2 * - 18 AS col0 FROM tab2
----
468
486
684

onlyif mysql # use DIV operator for integer division
query I rowsort label-2070
SELECT ( tab0.col2 ) DIV col2 + + col0 AS col1 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-2070
SELECT ( tab0.col2 ) / col2 + + col0 AS col1 FROM tab0
----
25
36
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2071
SELECT ALL CAST( NULL AS SIGNED ) - - 22 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2071
SELECT ALL CAST ( NULL AS INTEGER ) - - 22 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 - + col2 * col2 * + col1 AS col0 FROM tab0
----
-611793
-93568
0

query I rowsort
SELECT cor1.col0 * - ( 37 ) AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 280bea3cc4394b022d2934d713f2712f

onlyif mysql # use DIV operator for integer division
query I rowsort label-2074
SELECT - ( + col1 ) DIV - col0 + 64 - + col2 AS col2 FROM tab2
----
26
38
41

skipif mysql # not compatible
query I rowsort label-2074
SELECT - ( + col1 ) / - col0 + 64 - + col2 AS col2 FROM tab2
----
26
38
41

query I rowsort
SELECT DISTINCT - col2 + tab1.col1 * col1 AS col1 FROM tab1
----
43
622
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-2076
SELECT - 44 * col2 DIV col1 + + col1 * col0 * col0 + col0 AS col2 FROM tab0
----
118860
49544
720861

skipif mysql # not compatible
query I rowsort label-2076
SELECT - 44 * col2 / col1 + + col1 * col0 * col0 + col0 AS col2 FROM tab0
----
118860
49544
720861

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 * + col2 col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col0 * col2 + + tab1.col0 AS col2 FROM tab1
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * col2 col2 FROM tab1 AS cor0
----
1248
1404
570

query IIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 WHERE NOT NULL < NULL
----

query I rowsort
SELECT col0 + - col2 - col0 * col1 FROM tab1 AS cor0
----
-1056
-129
-633

query I rowsort
SELECT DISTINCT + col0 - - col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL - - cor0.col2 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT col1 * col2 + - tab1.col1 * - col1 * col1 AS col2 FROM tab1
----
1570
18980
3445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 91 * col2 + - col1 col1 FROM tab1
----
4888
5177
8723

query I rowsort
SELECT DISTINCT - 48 * + col0 AS col2 FROM tab0 AS cor0
----
-1152
-1680
-4272

query I rowsort
SELECT ALL - - 4 + - 74 * col1 AS col1 FROM tab2 AS cor0
----
-1254
-2290
-4362

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - 89 col2 FROM tab0
----
-2937
-7298
-89

query I rowsort
SELECT - 51 FROM tab2, tab2 AS cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2090
SELECT + col2 DIV col1 col1 FROM tab2 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2090
SELECT + col2 / col1 col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT DISTINCT col0 * col0 * col0 FROM tab0 AS cor0
----
13824
42875
704969

query I rowsort
SELECT col0 * cor0.col2 + col1 - col2 AS col2 FROM tab0 AS cor0
----
131
7307
845

query I rowsort
SELECT ALL - - cor0.col2 + - col0 * cor0.col2 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-2094
SELECT DISTINCT col1 * col1 DIV - cor0.col0 AS col1 FROM tab1 AS cor0
----
-1
-2
-225

skipif mysql # not compatible
query I rowsort label-2094
SELECT DISTINCT col1 * col1 / - cor0.col0 AS col1 FROM tab1 AS cor0
----
-1
-2
-225

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 - col0 * + col2 col0 FROM tab2 cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - 47 * + col0 FROM tab1 AS cor0
----
-141
-3008
-3760

query I rowsort
SELECT + 71 + col2 * + col1 + - col2 * col1 AS col0 FROM tab0 AS cor0
----
71
71
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 1 * - col2 col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT cor0.col2 + col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT - ( + 14 ) + + col0 * tab2.col1 AS col1 FROM tab2
----
1329
203
4588

query I rowsort
SELECT 85 + + tab0.col1 FROM tab0
----
171
176
182

onlyif mysql # use DIV operator for integer division
query I rowsort label-2102
SELECT DISTINCT + + col1 DIV col2 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2102
SELECT DISTINCT + + col1 / col2 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT + - col2 + col1 * col1 AS col0 FROM tab1 AS cor0
----
43
622
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-2104
SELECT + col1 DIV col0 AS col1 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-2104
SELECT + col1 / col0 AS col1 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT DISTINCT + + 86 + cor0.col1 * col0 AS col1 FROM tab0 AS cor0
----
2150
3481
8185

onlyif mysql # use DIV operator for integer division
query I rowsort label-2106
SELECT DISTINCT col0 + col0 DIV + col0 FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-2106
SELECT DISTINCT col0 + col0 / + col0 FROM tab2
----
79
8
80

query III rowsort
SELECT ALL * FROM tab0 WHERE ( col1 ) NOT BETWEEN + col0 AND col2
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT ALL - col0 * col0 AS col0 FROM tab0 WHERE NULL > NULL
----

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT NULL <> NULL
----

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE - col0 NOT BETWEEN NULL AND col2 + - col2 * col1
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL BETWEEN ( NULL ) AND + cor0.col2 * - col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2112
SELECT col1 DIV tab0.col1 + col2 * - col1 FROM tab0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-2112
SELECT col1 / tab0.col1 + col2 * - col1 FROM tab0
----
-2837
-7461
-96

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL IN ( - col1 / - col1 )
----

query I rowsort
SELECT ALL + col1 * - col0 AS col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col2 / - col1 + - col0 AS col0 FROM tab0 WHERE NULL NOT IN ( - tab0.col0 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT - col2 + - col0 BETWEEN NULL AND col2 + col2
----

query I rowsort
SELECT ALL tab1.col2 * - col2 + + col2 AS col1 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT - tab0.col2 - - col1 FROM tab0
----
53
9
96

query I rowsort
SELECT - col1 + - col2 * col2 FROM tab2
----
-1461
-735
-760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col1 - - col0 col0 FROM tab1 WHERE col1 + + col1 * col0 NOT IN ( - col2 / - col2 + col2 )
----
1328
1407
634

query I rowsort
SELECT DISTINCT + col0 * + col1 * col2 + + col0 FROM tab2
----
119730
51113
5866

query I rowsort
SELECT DISTINCT tab1.col0 * + col1 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT col1 * - col0 + cor0.col1 FROM tab1 AS cor0
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - cor0.col1 + col1 col0 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL + col0 * cor0.col2 + col0 * col2 FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT - col2 * - col0 + col1 AS col1 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT - cor0.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0
----
-86
-91
-97

query I rowsort
SELECT + col1 + + col0 * + col0 AS col0 FROM tab2
----
6143
6258
80

query I rowsort
SELECT ALL col1 + col0 * + col2 * col2 FROM tab1 AS cor0
----
207946
737293
8774

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + cor0.col1 * col0 + - cor0.col0 col2 FROM tab0 cor0
----
118790
49512
720722

query I rowsort
SELECT + cor0.col2 * - col2 + - col0 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT - 54 + col0 * - col1 FROM tab0 AS cor0
----
-2118
-3449
-8153

query I rowsort
SELECT + 17 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2134
SELECT DISTINCT - CAST( + 30 AS SIGNED ) * - cor0.col1 * - 28 AS col0 FROM tab0, tab1 AS cor0
----
-10920
-21840
-8400

skipif mysql # not compatible
query I rowsort label-2134
SELECT DISTINCT - CAST ( + 30 AS INTEGER ) * - cor0.col1 * - 28 AS col0 FROM tab0, tab1 AS cor0
----
-10920
-21840
-8400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2135
SELECT tab0.col2 * + CAST( + col2 AS SIGNED ) AS col1 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-2135
SELECT tab0.col2 * + CAST ( + col2 AS INTEGER ) AS col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - 81 FROM tab1, tab2 AS cor0
----
-81

query I rowsort
SELECT DISTINCT - - 52 * - col1 + col0 FROM tab0 cor0
----
-4448
-4643
-5009

query I rowsort
SELECT - 4 * + col0 AS col0 FROM tab1 AS cor0
----
-12
-256
-320

query I rowsort
SELECT DISTINCT + - col1 + - 38 AS col1 FROM tab1 AS cor0
----
-48
-51
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2140
SELECT CAST( ( + col0 ) AS SIGNED ) AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2140
SELECT CAST ( ( + col0 ) AS INTEGER ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL 60 * col1 FROM tab0 AS cor0
----
5160
5460
5820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2142
SELECT CAST( - col0 AS SIGNED ) * - col0 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-2142
SELECT CAST ( - col0 AS INTEGER ) * - col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - + col1 * col2 + - col2 - - 46 FROM tab2 AS cor0
----
-1514
-638
-818

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2144
SELECT DISTINCT + + CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2144
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL

query I rowsort
SELECT tab0.col1 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT ALL - 54 FROM tab0 AS cor0
----
-54
-54
-54

query I rowsort
SELECT ALL - 5 + cor0.col2 AS col2 FROM tab1 AS cor0
----
49
52
91

query I rowsort
SELECT ALL + col2 * + col2 + + tab0.col2 FROM tab0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2149
SELECT - col2 DIV + col0 + col1 * + col0 AS col1 FROM tab0
----
2063
3395
8099

skipif mysql # not compatible
query I rowsort label-2149
SELECT - col2 / + col0 + col1 * + col0 AS col1 FROM tab0
----
2063
3395
8099

query I rowsort
SELECT 92 - + ( col2 ) AS col2 FROM tab2
----
54
65
66

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2
----
3645 values hashing to 731e4a6549b312ba21c2e61ca9bede27

query I rowsort
SELECT + col0 - 28 * col1 AS col0 FROM tab0 AS cor0
----
-2384
-2459
-2681

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * cor0.col0 * + 28 - col1 * col2 col2 FROM tab2 AS cor0
----
127322
36958
5239

query I rowsort
SELECT DISTINCT + tab2.col0 - - ( + 67 ) AS col2 FROM tab2
----
145
146
74

query I rowsort
SELECT DISTINCT - col0 - - 15 AS col2 FROM tab0
----
-20
-74
-9

query I rowsort
SELECT + col1 * + ( - col1 ) AS col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - 7 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2158
SELECT + col2 + CAST( NULL AS DECIMAL ) + col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2158
SELECT + col2 + 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-2159
SELECT + col1 DIV + 18 col1 FROM tab1
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2159
SELECT + col1 / + 18 col1 FROM tab1
----
0
0
1

query I rowsort
SELECT 95 * col2 AS col0 FROM tab2 AS cor0
----
2470
2565
3610

query I rowsort
SELECT DISTINCT - 46 + col0 FROM tab1 AS cor0
----
-43
18
34

query I rowsort
SELECT DISTINCT + 85 AS col2 FROM tab1, tab1 cor0
----
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2163
SELECT CAST( NULL AS SIGNED ) * - col2 col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2163
SELECT CAST ( NULL AS INTEGER ) * - col2 col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - 6 * col0 FROM tab2
----
-42
-468
-474

query I rowsort
SELECT DISTINCT + - col2 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2166
SELECT DISTINCT - - CAST( col0 AS SIGNED ) DIV col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2166
SELECT DISTINCT - - CAST ( col0 AS INTEGER ) / col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT + col2 + + col1 - col1 * - col0 * + col0 AS col2 FROM tab1 cor0
----
314
41027
83309

query I rowsort
SELECT ALL - col0 + col0 * col1 AS col1 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + ( col1 ) * + col2 + col0 FROM tab1
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 82 col0 FROM tab1 AS cor0
----
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2171
SELECT - - CAST( NULL AS DECIMAL ) * 18 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2171
SELECT - - CAST ( NULL AS REAL ) * 18 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 31 + + col0 + + col2 FROM tab1 cor0
----
152
207
88

query I rowsort
SELECT ALL + + 67 * col1 FROM tab0 AS cor0
----
5762
6097
6499

onlyif mysql # use DIV operator for integer division
query I rowsort label-2174
SELECT ALL col1 DIV - ( col0 + + col0 ) AS col2 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2174
SELECT ALL col1 / - ( col0 + + col0 ) AS col2 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT + 51 + + tab1.col1 AS col2 FROM tab1
----
61
64
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2176
SELECT + col2 * col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2176
SELECT + col2 * col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 78 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c4f3c63f98c3c08f2848f46850a476d4

query I rowsort
SELECT 29 + col2 FROM tab2
----
55
56
67

query I rowsort
SELECT + ( col2 ) + + col2 AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL + 25 * + col2 * + col0 + col1 FROM tab1 cor0
----
192013
4076
91210

query I rowsort
SELECT ( - cor1.col2 ) AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL + col0 + col0 * + col1 AS col1 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2183
SELECT ALL - col2 + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2183
SELECT ALL - col2 + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + cor0.col1 * 42 * col1 FROM tab1 AS cor0
----
28418
4210
7111

query I rowsort
SELECT ALL - col2 * ( ( col1 ) ) AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + col0 * 84 FROM tab2 AS cor0
----
588
6552
6636

query I rowsort
SELECT col2 * 5 FROM tab0 AS cor0
----
165
410
5

query I rowsort
SELECT DISTINCT - - col1 * cor0.col1 * + col1 AS col1 FROM tab2 AS cor0
----
205379
29791
4913

query I rowsort
SELECT + + col1 + col0 * cor0.col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT ALL + col0 + col0 * cor0.col1 AS col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT + col1 * - 53 FROM tab1 AS cor0
----
-1378
-530
-689

onlyif mysql # use DIV operator for integer division
query I rowsort label-2192
SELECT DISTINCT - - col1 DIV + ( + col0 ) FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-2192
SELECT DISTINCT - - col1 / + ( + col0 ) FROM tab2 AS cor0
----
0
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2193
SELECT DISTINCT - + 87 + col2 DIV - 55 FROM tab1 AS cor0
----
-87
-88

skipif mysql # not compatible
query I rowsort label-2193
SELECT DISTINCT - + 87 + col2 / - 55 FROM tab1 AS cor0
----
-87
-88

query I rowsort
SELECT DISTINCT - + 36 + col1 FROM tab1 cor0
----
-10
-23
-26

query I rowsort
SELECT DISTINCT + tab1.col0 * 74 AS col0 FROM tab1, tab2 AS cor0
----
222
4736
5920

query I rowsort
SELECT ALL 74 * tab1.col0 + - tab1.col1 AS col2 FROM tab1
----
196
4726
5907

query I rowsort
SELECT DISTINCT + col1 + - col0 * + col1 * 0 FROM tab0
----
86
91
97

query I rowsort
SELECT col1 * 96 FROM tab1 AS cor0
----
1248
2496
960

query I rowsort
SELECT ALL + 77 * col1 + col1 FROM tab2
----
1326
2418
4602

query I rowsort
SELECT DISTINCT - 49 FROM tab1, tab2, tab2 AS cor0
----
-49

query I rowsort
SELECT + 68 AS col1 FROM tab1
----
68
68
68

query I rowsort
SELECT - - 1 * + col0 + 47 * + col2 * - col2 AS col1 FROM tab1 cor0
----
-137049
-152639
-433072

query I rowsort
SELECT - + col0 - + col2 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT - cor0.col0 * + col2 - - ( col2 ) FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - col1 * col2 + col2 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT + col2 * - col2 * 95 AS col1 FROM tab0
----
-103455
-638780
-95

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-2208
SELECT + CAST( 17 AS SIGNED ) FROM tab0 AS cor0
----
17
17
17

skipif mysql # not compatible
query I rowsort label-2208
SELECT + CAST ( 17 AS INTEGER ) FROM tab0 AS cor0
----
17
17
17

query I rowsort
SELECT ALL col1 * col0 * col2 AS col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT col2 * 23 * col2 FROM tab2
----
15548
16767
33212

query I rowsort
SELECT + 87 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT col0 * + 67 AS col2 FROM tab2
----
469
5226
5293

query I rowsort
SELECT ( cor0.col1 ) FROM tab1, tab0, tab2 AS cor0, tab2
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT - col0 + + ( + col0 ) AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + 30 + cor0.col2 * + col2 AS col1 FROM tab0 cor0
----
1119
31
6754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2216
SELECT ALL + CAST( NULL AS SIGNED ) + + cor0.col0 * + col0 / col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2216
SELECT ALL + CAST ( NULL AS INTEGER ) + + cor0.col0 * + col0 / col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 97 + - ( - col1 ) * + col2 FROM tab0 AS cor0
----
194
2935
7559

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col2 * tab2.col1 col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT - ( + 48 + col2 * - col1 ) FROM tab1
----
1200
1356
522

query I rowsort
SELECT DISTINCT + cor0.col2 * - 17 FROM tab0 AS cor0
----
-1394
-17
-561

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + + CAST ( cor0.col2 AS REAL ) + + cor0.col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL + col2 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + col2 + col0 * + col2 * - col0 FROM tab0 AS cor0
----
-1224
-18975
-649440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2224
SELECT DISTINCT + - CAST( - col0 AS SIGNED ) * col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-2224
SELECT DISTINCT + - CAST ( - col0 AS INTEGER ) * col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2225
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2225
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL

query I rowsort
SELECT + col0 * - col0 + + col2 FROM tab2 cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-2227
SELECT DISTINCT cor0.col2 DIV - col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-2227
SELECT DISTINCT cor0.col2 / - col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT + ( col0 * col0 ) AS col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT ALL + ( ( - col2 ) ) * col0 FROM tab2
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2230
SELECT ALL ( col2 ) * + tab0.col0 / CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2230
SELECT ALL ( col2 ) * + tab0.col0 / CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 * col2 + 12 AS col2 FROM tab1 AS cor0
----
2928
3261
9228

onlyif mysql # use DIV operator for integer division
query I rowsort label-2232
SELECT col0 DIV - cor0.col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2232
SELECT col0 / - cor0.col0 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2233
SELECT 5 DIV col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2233
SELECT 5 / col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL tab0.col0 * ( col1 ) AS col1 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2235
SELECT + + 15 DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2235
SELECT + + 15 / col0 AS col0 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT - col0 + 46 FROM tab2 AS cor0
----
-32
-33
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-2237
SELECT ALL - col0 + CAST( - col1 AS SIGNED ) + col2 DIV + 6 AS col2 FROM tab2 AS cor0
----
-133
-34
-90

skipif mysql # not compatible
query I rowsort label-2237
SELECT ALL - col0 + CAST ( - col1 AS INTEGER ) + col2 / + 6 AS col2 FROM tab2 AS cor0
----
-133
-34
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2238
SELECT ALL + col2 * CAST( NULL AS SIGNED ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2238
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + + col1 * - col1 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT + 53 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT + col1 * 25 + col2 AS col1 FROM tab0 AS cor0
----
2183
2357
2426

query I rowsort
SELECT + - cor0.col0 - - col1 * col1 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT - ( cor0.col1 ) * col2 * 22 AS col0 FROM tab1 AS cor0
----
-12540
-27456
-30888

query I rowsort
SELECT - + cor0.col2 * - ( + col1 ) AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 43 + 29 AS col0 FROM tab1, tab0 AS cor0
----
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2246
SELECT DISTINCT + CAST( NULL AS DECIMAL ) AS col1 FROM tab0, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2246
SELECT DISTINCT + CAST ( NULL AS REAL ) AS col1 FROM tab0, tab1 AS cor0
----
NULL

query I rowsort
SELECT col2 - col2 * col2 FROM tab0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT ( - col1 ) - + 48 AS col0 FROM tab0
----
-134
-139
-145

query I rowsort
SELECT ALL col1 + col2 + col2 AS col2 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT DISTINCT col0 * - col0 + - ( ( cor0.col2 ) + + ( col1 ) * cor0.col2 ) FROM tab0 AS cor0
----
-1323
-15465
-3447

query I rowsort
SELECT DISTINCT - 96 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2252
SELECT + - CAST( NULL AS DECIMAL ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2252
SELECT + - CAST ( NULL AS REAL ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col0 + col1 + col1 FROM tab0 AS cor0
----
196
229
271

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - cor0.col1 col2 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - - cor0.col2 * - 27 FROM tab1 AS cor0
----
-1458
-1539
-2592

query I rowsort
SELECT cor0.col1 * ( + col1 ) * + col0 + 34 FROM tab0 AS cor0
----
177538
329349
737043

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2257
SELECT - col0 * + CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2257
SELECT - col0 * + CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2258
SELECT DISTINCT + + col2 DIV + col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-2258
SELECT DISTINCT + + col2 / + col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT ALL - - col2 + col0 * + col1 AS col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT col2 + 82 AS col2 FROM tab0 AS cor0
----
115
164
83

query I rowsort
SELECT ALL cor0.col0 + - ( + col1 ) + + col0 FROM tab0 AS cor0
----
-27
-38
87

query I rowsort
SELECT DISTINCT + ( + col1 ) AS col1 FROM tab2
----
17
31
59

query I rowsort
SELECT 90 * col2 AS col2 FROM tab2
----
2340
2430
3420

query I rowsort
SELECT DISTINCT + + cor0.col0 * + col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - col2 * + 67 + col1 * + col0 FROM tab0 AS cor0
----
-147
2605
3328

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * col0 * - ( + col0 ) + - 97 col0 FROM tab1 cor0
----
-124
-262241
-512097

query I rowsort
SELECT 46 * - 99 FROM tab1 AS cor0
----
-4554
-4554
-4554

query I rowsort
SELECT - - 43 + + col2 AS col2 FROM tab0 AS cor0
----
125
44
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 * + col2 col0 FROM tab0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2270
SELECT + - CAST( NULL AS SIGNED ) * - col2 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2270
SELECT + - CAST ( NULL AS INTEGER ) * - col2 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 93 * cor0.col1 col2 FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT ALL - col0 + + ( col2 ) AS col2 FROM tab2 cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - 81 AS REAL ) + + cor0.col0 AS col1 FROM tab1 AS cor0
----
-1
-17
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2274
SELECT ALL col0 DIV + col1 - col1 AS col1 FROM tab1 AS cor0
----
-26
-4
-7

skipif mysql # not compatible
query I rowsort label-2274
SELECT ALL col0 / + col1 - col1 AS col1 FROM tab1 AS cor0
----
-26
-4
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2275
SELECT ALL 86 DIV + col2 + col1 * - col1 + col2 FROM tab0 AS cor0
----
-7361
-8198
-9322

skipif mysql # not compatible
query I rowsort label-2275
SELECT ALL 86 / + col2 + col1 * - col1 + col2 FROM tab0 AS cor0
----
-7361
-8198
-9322

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col1 col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL col0 * - col1 - - col2 AS col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT 79 AS col0 FROM tab0 AS cor0
----
79

query I rowsort
SELECT + 37 * - col0 FROM tab0 AS cor0
----
-1295
-3293
-888

onlyif mysql # use DIV operator for integer division
query I rowsort label-2280
SELECT - - ( col1 ) DIV + col1 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2280
SELECT - - ( col1 ) / + col1 AS col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - col1 * col2 + - col2 AS col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT + + col2 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - 23 * col0 + col2 * + col0 FROM tab1 AS cor0
----
2176
5840
93

query I rowsort
SELECT + - ( col1 ) + + 24 FROM tab2 AS cor0
----
-35
-7
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2285
SELECT ALL - col2 + - col1 * CAST( - col2 AS SIGNED ) FROM tab0 AS cor0
----
2805
7380
96

skipif mysql # not compatible
query I rowsort label-2285
SELECT ALL - col2 + - col1 * CAST ( - col2 AS INTEGER ) FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL + ( col1 ) * + ( + ( + col1 ) ) + + cor0.col0 * ( cor0.col0 ) + col1 * 57 FROM tab2 AS cor0
----
12928
2777
7499

query I rowsort
SELECT ALL + + 21 + cor0.col0 * col2 AS col0 FROM tab2 cor0
----
2049
210
3023

query I rowsort
SELECT ALL + 72 * - col2 * 9 + - 75 * - col1 - col1 FROM tab2 cor0
----
-12482
-15202
-23366

query I rowsort
SELECT DISTINCT + - ( + col0 ) * 61 * col0 AS col0 FROM tab0 AS cor0
----
-35136
-483181
-74725

query I rowsort
SELECT ALL - col1 + cor0.col1 * + 13 AS col0 FROM tab2 AS cor0
----
204
372
708

onlyif mysql # use DIV operator for integer division
query I rowsort label-2291
SELECT - col2 * col2 DIV 41 FROM tab0 AS cor0
----
-164
-26
0

skipif mysql # not compatible
query I rowsort label-2291
SELECT - col2 * col2 / 41 FROM tab0 AS cor0
----
-164
-26
0

query I rowsort
SELECT ALL + + cor0.col0 * cor0.col2 + ( - ( col2 ) ) AS col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ( - col2 ) * col2 + 25 * + col0 AS col2 FROM tab1
----
-1649
-2841
-7216

query I rowsort
SELECT + 57 + tab0.col1 AS col1 FROM tab0
----
143
148
154

query I rowsort
SELECT - 13 - col2 AS col0 FROM tab2
----
-39
-40
-51

query I rowsort
SELECT DISTINCT + col2 * col0 + ( + col0 ) FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - + 87 - - col0 FROM tab2 AS cor0
----
-8
-80
-9

query I rowsort
SELECT ( - col0 ) * - col1 * col2 - - 22 AS col0 FROM tab1
----
36502
4234
99862

query I rowsort
SELECT cor0.col1 + col0 * ( - col2 ) FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT ALL - col2 + - col2 * 94 FROM tab2 AS cor0
----
-2470
-2565
-3610

query I rowsort
SELECT col1 - col1 AS col1 FROM tab1
----
0
0
0

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 cor0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to 2507aa9f48c3db94de9fec065edf3731

query I rowsort
SELECT - + 86 + col1 AS col2 FROM tab2 AS cor0
----
-27
-55
-69

query I rowsort
SELECT ALL + col2 + - 67 FROM tab0 AS cor0
----
-34
-66
15

skipif mysql # not compatible
query I rowsort
SELECT + col1 + + CAST ( col1 AS REAL ) * + col2 + col1 FROM tab0
----
291
3010
7644

query I rowsort
SELECT DISTINCT 25 + 95 AS col2 FROM tab2, tab2 AS cor0, tab0, tab1 AS cor1
----
120

query I rowsort
SELECT 47 AS col0 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

onlyif mysql # use DIV operator for integer division
query I rowsort label-2308
SELECT + col0 DIV ( + col0 ) + + col0 + 30 AS col2 FROM tab1
----
111
34
95

skipif mysql # not compatible
query I rowsort label-2308
SELECT + col0 / ( + col0 ) + + col0 + 30 AS col2 FROM tab1
----
111
34
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col1 col2 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL - + col1 * - 46 AS col2 FROM tab1 AS cor0
----
1196
460
598

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * + 2 + col2 col0 FROM tab0 AS cor0
----
-15
-69
-96

query I rowsort
SELECT 9 * - col1 + col2 AS col1 FROM tab2
----
-115
-252
-505

query I rowsort
SELECT ALL cor1.col2 AS col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL + 51 AS col2 FROM tab1
----
51
51
51

query I rowsort
SELECT ALL - cor0.col1 * 82 FROM tab2 AS cor0
----
-1394
-2542
-4838

onlyif mysql # use DIV operator for integer division
query I rowsort label-2316
SELECT DISTINCT + 81 DIV cor0.col2 FROM tab0 AS cor0
----
0
2
81

skipif mysql # not compatible
query I rowsort label-2316
SELECT DISTINCT + 81 / cor0.col2 FROM tab0 AS cor0
----
0
2
81

query I rowsort
SELECT DISTINCT - col1 + 6 AS col1 FROM tab2 cor0
----
-11
-25
-53

query I rowsort
SELECT ALL + 24 * cor0.col1 * col0 + + col1 FROM tab0 AS cor0
----
194467
49622
81577

query I rowsort
SELECT ALL 39 * - 69 AS col1 FROM tab1 AS cor0
----
-2691
-2691
-2691

query I rowsort
SELECT DISTINCT + ( col1 ) + + col1 + col0 AS col1 FROM tab1 AS cor0
----
106
55
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2321
SELECT - - CAST( NULL AS SIGNED ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2321
SELECT - - CAST ( NULL AS INTEGER ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col2 + col2 * col2 AS col1 FROM tab0 AS cor0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2323
SELECT + col2 DIV + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2323
SELECT + col2 / + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col2 * - col0 + 9 + col0 * - col1 FROM tab2 cor0
----
-397
-4336
-6621

query I rowsort
SELECT ALL col0 * 19 AS col0 FROM tab0 AS cor0
----
1691
456
665

onlyif mysql # use DIV operator for integer division
query I rowsort label-2326
SELECT - col1 DIV 87 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2326
SELECT - col1 / 87 FROM tab0 AS cor0
----
-1
-1
0

query I rowsort
SELECT + cor0.col0 * cor0.col0 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to d2e5241c58e367013a1a203910e000c0

query I rowsort
SELECT DISTINCT cor1.col1 * 50 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
1550
2950
850

query I rowsort
SELECT 50 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT DISTINCT - - col2 * cor0.col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT 29 * - cor0.col2 FROM tab2 AS cor0
----
-1102
-754
-783

query I rowsort
SELECT + col0 * - col1 + ( + col0 ) + col2 * - ( 59 ) AS col2 FROM tab0 AS cor0
----
-12848
-3419
-3987

query I rowsort
SELECT + + 29 AS col0 FROM tab1 AS cor0
----
29
29
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) + col0 col2 FROM tab2
----
104
117
34

query I rowsort
SELECT 68 + ( - col2 ) FROM tab1
----
-28
11
14

query I rowsort
SELECT - 56 + col1 AS col2 FROM tab1 AS cor0
----
-30
-43
-46

query I rowsort
SELECT - ( col1 ) + 5 * 6 AS col0 FROM tab0
----
-56
-61
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-2338
SELECT ALL + col1 DIV col1 col2 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2338
SELECT ALL + col1 / col1 col2 FROM tab0
----
1
1
1

query I rowsort
SELECT + col2 * + cor0.col1 + - col0 AS col2 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT col2 * 59 AS col2 FROM tab0 AS cor0
----
1947
4838
59

query I rowsort
SELECT + + 2 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT ( col2 * + col0 ) + - 3 FROM tab1
----
159
3645
7677

onlyif mysql # use DIV operator for integer division
query I rowsort label-2343
SELECT DISTINCT + + col0 DIV 61 + + col0 * cor0.col2 AS col1 FROM tab0 cor0
----
35
7299
792

skipif mysql # not compatible
query I rowsort label-2343
SELECT DISTINCT + + col0 / 61 + + col0 * cor0.col2 AS col1 FROM tab0 cor0
----
35
7299
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2344
SELECT DISTINCT CAST( tab0.col1 AS SIGNED ) AS col2 FROM tab0, tab1 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2344
SELECT DISTINCT CAST ( tab0.col1 AS INTEGER ) AS col2 FROM tab0, tab1 AS cor0
----
86
91
97

query I rowsort
SELECT col0 * 85 + col0 * - col1 FROM tab0 AS cor0
----
-24
-420
-534

query I rowsort
SELECT ALL 21 * 90 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to d81f882a1aefd8be671b30eb0e21007d

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1, tab1 AS cor2 WHERE NULL < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * + cor0.col2 * + ( col2 ) col1 FROM tab0 AS cor0
----
-1
-35937
-551368

query I rowsort
SELECT ALL - col2 * col0 + col1 AS col2 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT ALL - col0 + tab2.col0 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + ( col0 ) col2 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT + col0 * tab0.col1 * - col1 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT + + col1 * 68 + col1 AS col2 FROM tab1 cor0
----
1794
690
897

onlyif mysql # use DIV operator for integer division
query I rowsort label-2354
SELECT ALL + + 30 + 94 DIV - col1 AS col2 FROM tab1 cor0
----
21
23
27

skipif mysql # not compatible
query I rowsort label-2354
SELECT ALL + + 30 + 94 / - col1 AS col2 FROM tab1 cor0
----
21
23
27

query I rowsort
SELECT - + cor0.col0 * + cor0.col1 AS col2 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 064f0d12f5a54890818030ba889e7e5c

query I rowsort
SELECT cor0.col1 + col2 * 93 FROM tab1 cor0
----
5048
5311
8941

query I rowsort
SELECT + + col2 * col2 + col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT + ( - col0 + col0 ) * - col1 FROM tab1
----
0
0
0

query I rowsort
SELECT - 94 * - col0 + ( col0 ) + col0 AS col0 FROM tab0 cor0
----
2304
3360
8544

query I rowsort
SELECT col0 - + col0 * 12 FROM tab2 AS cor0
----
-77
-858
-869

query I rowsort
SELECT + + col1 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + col1 * col2 * col2 AS col0 FROM tab2 AS cor0
----
22572
24510
39858

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2363
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + ( tab0.col2 * 31 ) AS col1 FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2363
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + ( tab0.col2 * 31 ) AS col1 FROM tab0, tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2364
SELECT ALL - - ( col2 ) DIV col2 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2364
SELECT ALL - - ( col2 ) / col2 AS col1 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2365
SELECT ALL + 36 DIV + 80 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2365
SELECT ALL + 36 / + 80 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 62 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT ALL col0 * 53 FROM tab2
----
371
4134
4187

onlyif mysql # use DIV operator for integer division
query I rowsort label-2368
SELECT - col1 DIV + col2 - + tab1.col0 * col0 FROM tab1
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-2368
SELECT - col1 / + col2 - + tab1.col0 * col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT - col1 + tab0.col0 * 89 AS col1 FROM tab0
----
2050
3018
7830

query I rowsort
SELECT col0 - col2 * tab0.col2 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT - ( + tab2.col2 ) - + col0 AS col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT + col0 * - 27 AS col1 FROM tab1 cor0
----
-1728
-2160
-81

query I rowsort
SELECT col0 * - 54 * tab2.col1 FROM tab2
----
-11718
-248508
-72522

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2374
SELECT DISTINCT + CAST( + col0 AS SIGNED ) * tab1.col2 * 98 - 48 AS col0 FROM tab1
----
15828
357456
752592

skipif mysql # not compatible
query I rowsort label-2374
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) * tab1.col2 * 98 - 48 AS col0 FROM tab1
----
15828
357456
752592

query I rowsort
SELECT + + col0 * 47 * + col1 FROM tab1 AS cor0
----
30080
3666
48880

query I rowsort
SELECT DISTINCT + - 99 AS col2 FROM tab2 cor0
----
-99

query I rowsort
SELECT ALL - cor0.col1 * - col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT col1 * ( col2 ) * 90 AS col2 FROM tab1 cor0
----
112320
126360
51300

query I rowsort
SELECT DISTINCT - col0 * 60 AS col1 FROM tab1 AS cor0
----
-180
-3840
-4800

query I rowsort
SELECT ( col2 ) * + col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + + ( col0 ) * col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT - + ( + col1 ) * + col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - tab1.col0 * + tab1.col2 * tab1.col2 AS col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT + + 48 * + col0 * col0 + col2 * - col2 FROM tab2 AS cor0
----
1623
291356
298124

query I rowsort
SELECT - + 78 FROM tab2 AS cor0
----
-78
-78
-78

query I rowsort
SELECT - 8 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 47f43f23dcd23959d97d8e3b0aab692e

query I rowsort
SELECT ALL col1 * 30 AS col1 FROM tab1 AS cor0
----
300
390
780

query I rowsort
SELECT DISTINCT col1 * ( + col1 ) + + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-3996
-6231
667

query I rowsort
SELECT + - col0 + 14 FROM tab1 AS cor0
----
-50
-66
11

query I rowsort
SELECT DISTINCT + cor0.col2 + 53 * - col1 AS col0 FROM tab2 AS cor0
----
-1616
-3101
-863

query I rowsort
SELECT cor0.col0 + + ( col0 ) AS col1 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-2392
SELECT DISTINCT + col2 DIV - 13 + col0 col0 FROM tab1 AS cor0
----
-1
60
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2392
SELECT DISTINCT + col2 / - 13 + col0 col0 FROM tab1 AS cor0
----
-1
60
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2393
SELECT ALL - cor0.col2 * - CAST( NULL AS SIGNED ) + col2 / - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2393
SELECT ALL - cor0.col2 * - CAST ( NULL AS INTEGER ) + col2 / - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - ( - 46 ) AS col2 FROM tab2 AS cor0
----
1196
1242
1748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * + cor0.col0 col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col1 + - 45 - - col1 AS col0 FROM tab2 cor0
----
-11
17
73

query I rowsort
SELECT - col2 + col2 * 55 FROM tab1 AS cor0
----
2916
3078
5184

query I rowsort
SELECT ALL + + col2 + col1 * cor0.col0 * cor0.col1 AS col0 FROM tab2 cor0
----
22869
271544
6754

query I rowsort
SELECT DISTINCT - - col1 - col0 AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + col1 * + col2 + 89 FROM tab2 AS cor0
----
1623
735
926

query I rowsort
SELECT ALL + cor0.col0 * cor0.col1 + ( - col1 * cor0.col2 ) FROM tab2 AS cor0
----
-620
3068
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-2402
SELECT ALL - - col1 DIV + cor0.col0 + 76 * - col2 col2 FROM tab2 cor0
----
-1976
-2048
-2888

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2402
SELECT ALL - - col1 / + cor0.col0 + 76 * - col2 col2 FROM tab2 cor0
----
-1976
-2048
-2888

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 + col0 * + col1 col1 FROM tab0 AS cor0
----
2131
3462
8166

query I rowsort
SELECT DISTINCT - cor1.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-7
-78
-79

query I rowsort
SELECT ALL 78 - col1 AS col1 FROM tab1 AS cor0
----
52
65
68

query I rowsort
SELECT DISTINCT - - 97 + col1 * 17 * col1 AS col1 FROM tab2 AS cor0
----
16434
5010
59274

query I rowsort
SELECT ALL + - ( col1 ) AS col0 FROM tab2 cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col2 * - col0 - + 68 col0 FROM tab1 AS cor0
----
-176
-3659
-7652

onlyif mysql # use DIV operator for integer division
query I rowsort label-2409
SELECT + col2 DIV col0 - + col0 FROM tab1 AS cor0
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-2409
SELECT + col2 / col0 - + col0 FROM tab1 AS cor0
----
-64
-79
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 72 col1 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT ALL - - 49 AS col2 FROM tab1 AS cor0
----
49
49
49

query I rowsort
SELECT DISTINCT + + col0 + + col2 + 2 FROM tab1 AS cor0
----
123
178
59

query I rowsort
SELECT ALL 97 * - col2 + col2 AS col0 FROM tab2
----
-2496
-2592
-3648

query I rowsort
SELECT ALL 79 + col1 AS col1 FROM tab0
----
165
170
176

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 31 + col2 col0 FROM tab2
----
57
58
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-2416
SELECT col2 + + col0 * + tab0.col2 * - col1 + - col0 DIV - tab0.col1 FROM tab0
----
-3394
-664036
-68079

skipif mysql # not compatible
query I rowsort label-2416
SELECT col2 + + col0 * + tab0.col2 * - col1 + - col0 / - tab0.col1 FROM tab0
----
-3394
-664036
-68079

query I rowsort
SELECT ALL - tab1.col1 + col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + 7 + - col2 AS col0 FROM tab1 AS cor0
----
-47
-50
-89

query I rowsort
SELECT - col2 * + col0 + col2 * - col0 FROM tab2 AS cor0
----
-378
-4056
-6004

query I rowsort
SELECT DISTINCT col2 + + cor0.col0 * col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL + 30 + col0 AS col0 FROM tab2
----
108
109
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2422
SELECT - col2 * col2 + - CAST( NULL AS SIGNED ) * col0 * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2422
SELECT - col2 * col2 + - CAST ( NULL AS INTEGER ) * col0 * col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + - tab0.col2 AS col1 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL col1 * + col2 + + 4 AS col2 FROM tab1
----
1252
1408
574

query I rowsort
SELECT ALL + 72 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT ALL tab1.col1 * ( - col0 ) AS col1 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - 78 col2 FROM tab0
----
-102
-113
-167

query I rowsort
SELECT + ( - col0 ) * + col1 + + ( - cor0.col0 ) + - cor0.col0 * ( col2 ) AS col0 FROM tab0 AS cor0
----
-15486
-2880
-3465

query I rowsort
SELECT + col2 * - 19 FROM tab2 AS cor0
----
-494
-513
-722

query I rowsort
SELECT ALL + 50 + cor0.col2 AS col2 FROM tab0 AS cor0
----
132
51
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 53 + col2 col2 FROM tab2 cor0
----
-15
-26
-27

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab2 cor1
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

query I rowsort
SELECT + - col0 + + col0 + col1 * + col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col1 * - ( + col1 ) AS col1 FROM tab2
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + - col1 * + ( col0 ) col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-2436
SELECT ALL col2 * - col1 + - ( col1 ) - - col0 DIV - col0 AS col0 FROM tab2 AS cor0
----
-1594
-664
-869

skipif mysql # not compatible
query I rowsort label-2436
SELECT ALL col2 * - col1 + - ( col1 ) - - col0 / - col0 AS col0 FROM tab2 AS cor0
----
-1594
-664
-869

query I rowsort
SELECT - + col0 - + col1 * + cor0.col2 FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT + col0 + col2 * - 25 FROM tab2 AS cor0
----
-572
-668
-871

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 1 col1 FROM tab2, tab2 AS cor0
----
1

query I rowsort
SELECT DISTINCT cor0.col1 + - 41 + + col0 AS col0 FROM tab0 AS cor0
----
139
69
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2441
SELECT + col2 * col2 + ( col0 + CAST( NULL AS SIGNED ) ) * - col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2441
SELECT + col2 * col2 + ( col0 + CAST ( NULL AS INTEGER ) ) * - col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2442
SELECT col1 - col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-2442
SELECT col1 - col0 / - col1 AS col2 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT ALL + + col1 + + 45 FROM tab0 AS cor0
----
131
136
142

query I rowsort
SELECT 50 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2445
SELECT - CAST( - col2 AS SIGNED ) * col0 - - ( - 97 ) * col2 FROM tab1 AS cor0
----
-1632
-1881
-5076

skipif mysql # not compatible
query I rowsort label-2445
SELECT - CAST ( - col2 AS INTEGER ) * col0 - - ( - 97 ) * col2 FROM tab1 AS cor0
----
-1632
-1881
-5076

onlyif mysql # use DIV operator for integer division
query I rowsort label-2446
SELECT - col0 DIV - col0 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2446
SELECT - col0 / - col0 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - - cor0.col2 + col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT - + cor0.col0 + ( cor0.col2 ) * - ( + 12 ) AS col0 FROM tab2 cor0
----
-331
-390
-535

onlyif mysql # use DIV operator for integer division
query I rowsort label-2449
SELECT ALL - col0 DIV 88 AS col1 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2449
SELECT ALL - col0 / 88 AS col1 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT 61 * 66 FROM tab0 AS cor0
----
4026
4026
4026

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + ( + tab1.col2 ) col1 FROM tab1
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + 66 col2 FROM tab0
----
2178
5412
66

query I rowsort
SELECT DISTINCT 36 FROM tab2, tab2 AS cor0
----
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2454
SELECT DISTINCT + col0 + + CAST( + col0 AS SIGNED ) AS col1 FROM tab1
----
128
160
6

skipif mysql # not compatible
query I rowsort label-2454
SELECT DISTINCT + col0 + + CAST ( + col0 AS INTEGER ) AS col1 FROM tab1
----
128
160
6

query I rowsort
SELECT - ( + col1 ) * col2 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2456
SELECT DISTINCT col2 * ( 17 ) + tab0.col0 DIV - col1 + col1 * + col1 AS col1 FROM tab0
----
7957
9426
9675

skipif mysql # not compatible
query I rowsort label-2456
SELECT DISTINCT col2 * ( 17 ) + tab0.col0 / - col1 + col1 * + col1 AS col1 FROM tab0
----
7957
9426
9675

query I rowsort
SELECT ALL + cor0.col1 FROM tab2, tab2 cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 60 * + col0 * col1 + + col1 AS col1 FROM tab1 AS cor0
----
38410
4706
62413

onlyif mysql # use DIV operator for integer division
query I rowsort label-2459
SELECT - - 91 * + 22 - - col0 DIV - 11 col2 FROM tab1 AS cor0
----
1995
1997
2002

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2459
SELECT - - 91 * + 22 - - col0 / - 11 col2 FROM tab1 AS cor0
----
1995
1997
2002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col1 + + col1 col1 FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT - - 68 * col1 - + cor0.col2 * - ( 37 + - col1 ) * ( + col1 ) AS col1 FROM tab2 AS cor0
----
-29736
14076
7130

query I rowsort
SELECT ALL col0 * 45 * col2 FROM tab2 AS cor0
----
135090
8505
91260

query I rowsort
SELECT col1 * 50 + col1 AS col0 FROM tab1 AS cor0
----
1326
510
663

onlyif mysql # use DIV operator for integer division
query I rowsort label-2464
SELECT - 13 * + col1 + + 57 DIV col1 AS col1 FROM tab2 AS cor0
----
-218
-402
-767

skipif mysql # not compatible
query I rowsort label-2464
SELECT - 13 * + col1 + + 57 / col1 AS col1 FROM tab2 AS cor0
----
-218
-402
-767

onlyif mysql # use DIV operator for integer division
query I rowsort label-2465
SELECT DISTINCT - col1 DIV + col2 AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-2465
SELECT DISTINCT - col1 / + col2 AS col2 FROM tab1
----
0

query I rowsort
SELECT - - col2 * + col1 + + ( ( + col0 ) + + 59 ) FROM tab2 AS cor0
----
1671
784
903

query I rowsort
SELECT + + 43 + + col1 AS col1 FROM tab2 cor0
----
102
60
74

query I rowsort
SELECT ALL ( - col0 ) * col1 * - col0 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-2469
SELECT - col1 + cor0.col2 DIV + col0 + + cor0.col1 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-2469
SELECT - col1 + cor0.col2 / + col0 + + cor0.col1 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) * col0 col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL col2 - - col2 FROM tab2
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2472
SELECT + col1 * - ( - col0 + + CAST( - col1 AS SIGNED ) ) col0 FROM tab0
----
12804
16380
9460

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2472
SELECT + col1 * - ( - col0 + + CAST ( - col1 AS INTEGER ) ) col0 FROM tab0
----
12804
16380
9460

query I rowsort
SELECT - tab1.col2 * + 58 AS col0 FROM tab1
----
-3132
-3306
-5568

onlyif mysql # use DIV operator for integer division
query I rowsort label-2474
SELECT 51 DIV 80 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2474
SELECT 51 / 80 FROM tab0
----
0
0
0

query I rowsort
SELECT col0 + ( 19 ) * col0 FROM tab2 AS cor0
----
140
1560
1580

query I rowsort
SELECT - col2 * 79 AS col1 FROM tab0 AS cor0
----
-2607
-6478
-79

query I rowsort
SELECT - + col1 + ( + 92 ) AS col1 FROM tab0 AS cor0
----
-5
1
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2478
SELECT + - col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2478
SELECT + - col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 12 * col0 FROM tab2
----
-84
-936
-948

query I rowsort
SELECT + col2 + col1 * - 0 AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT cor0.col0 + - col0 * col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT - ( - ( cor0.col2 ) ) + 27 FROM tab2, tab1 AS cor0
----
9 values hashing to 1e9059db3beed2ccbd08179e5e7e0280

query I rowsort
SELECT col0 * - tab2.col1 * 14 FROM tab2
----
-18802
-3038
-64428

query I rowsort
SELECT ALL col2 * col2 + tab1.col2 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT ALL - 11 + + ( cor0.col0 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 1ec099dd62862fdeee2672e7a991f5aa

query I rowsort
SELECT cor0.col1 + + 0 * col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col1 * - 67 + col1 AS col2 FROM tab0 AS cor0
----
-5676
-6006
-6402

query I rowsort
SELECT DISTINCT 73 * - 13 FROM tab1, tab1 AS cor0
----
-949

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2489
SELECT col0 * CAST( NULL AS SIGNED ) + + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2489
SELECT col0 * CAST ( NULL AS INTEGER ) + + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * 38 - - 59 AS col1 FROM tab2
----
1237
2301
705

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 79 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT ALL + 8 FROM tab1, tab0 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT + col0 + col1 * + col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL + 34 + col2 AS col0 FROM tab2 AS cor0
----
60
61
72

query I rowsort
SELECT DISTINCT - col1 + + cor0.col2 AS col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT tab0.col0 * 55 AS col0 FROM tab0
----
1320
1925
4895

query I rowsort
SELECT ALL col1 + col2 * 39 FROM tab2 AS cor0
----
1073
1084
1499

query I rowsort
SELECT ALL - + 22 AS col0 FROM tab1 cor0
----
-22
-22
-22

query I rowsort
SELECT ALL cor0.col0 * - col0 + 22 * cor0.col1 FROM tab1 AS cor0
----
-3876
-6114
563

query I rowsort
SELECT DISTINCT - 30 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
-6
5
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2501
SELECT DISTINCT ( - col1 ) - - col0 DIV col0 FROM tab0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2501
SELECT DISTINCT ( - col1 ) - - col0 / col0 FROM tab0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT 13 - + col1 AS col2 FROM tab0
----
-73
-78
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 30 + - col1 - + col1 * + 48 col1 FROM tab0
----
-4184
-4429
-4723

onlyif mysql # use DIV operator for integer division
query I rowsort label-2504
SELECT + col1 DIV 65 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2504
SELECT + col1 / 65 FROM tab1
----
0
0
0

query I rowsort
SELECT col1 * ( col1 ) * col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT - ( ( col0 ) ) * - ( + 58 * col0 ) FROM tab0
----
33408
459418
71050

query I rowsort
SELECT ( 94 ) FROM tab2
----
94
94
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-2508
SELECT - 54 DIV + col2 FROM tab0
----
-1
-54
0

skipif mysql # not compatible
query I rowsort label-2508
SELECT - 54 / + col2 FROM tab0
----
-1
-54
0

query I rowsort
SELECT DISTINCT + col2 - - tab1.col1 FROM tab1
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col2 + ( + col0 ) col2 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT + - 26 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 47d0574274146de273829785364ada39

query I rowsort
SELECT tab2.col1 * - col1 - col1 * 86 FROM tab2
----
-1751
-3627
-8555

query I rowsort
SELECT DISTINCT - + cor0.col0 + col0 - - col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - ( - col1 ) * 45 AS col0 FROM tab1 cor0
----
1170
450
585

query I rowsort
SELECT DISTINCT - cor0.col2 * col0 - col2 FROM tab0 AS cor0
----
-36
-7380
-825

onlyif mysql # use DIV operator for integer division
query I rowsort label-2516
SELECT col2 DIV + col2 + col2 + tab1.col2 FROM tab1
----
109
115
193

skipif mysql # not compatible
query I rowsort label-2516
SELECT col2 / + col2 + col2 + tab1.col2 FROM tab1
----
109
115
193

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 87 - + col0 col1 FROM tab2
----
8
80
9

query I rowsort
SELECT ALL col0 * col1 * col1 FROM tab1
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-2519
SELECT DISTINCT + + 57 DIV + col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2519
SELECT DISTINCT + + 57 / + col2 FROM tab1 AS cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2520
SELECT - ( cor0.col2 ) DIV cor0.col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2520
SELECT - ( cor0.col2 ) / cor0.col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - 3 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 65b7e16aaa7821ace3a45a9846ffa166

onlyif mysql # use DIV operator for integer division
query I rowsort label-2522
SELECT ALL + col2 DIV + col0 + col2 FROM tab2 cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-2522
SELECT ALL + col2 / + col0 + col2 FROM tab2 cor0
----
26
30
38

query I rowsort
SELECT DISTINCT col0 - ( + 47 ) AS col1 FROM tab1 AS cor0
----
-44
17
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2524
SELECT ALL - cor0.col1 * ( 78 ) + - col2 * CAST( NULL AS SIGNED ) * + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2524
SELECT ALL - cor0.col1 * ( 78 ) + - col2 * CAST ( NULL AS INTEGER ) * + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2525
SELECT ALL + - col2 + ( + 73 ) DIV - col0 AS col2 FROM tab2 cor0
----
-26
-37
-38

skipif mysql # not compatible
query I rowsort label-2525
SELECT ALL + - col2 + ( + 73 ) / - col0 AS col2 FROM tab2 cor0
----
-26
-37
-38

query I rowsort
SELECT DISTINCT - col0 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT cor0.col0 * - col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - col0 + - ( 86 ) * col0 FROM tab2 AS cor0
----
-609
-6786
-6873

onlyif mysql # use DIV operator for integer division
query I rowsort label-2529
SELECT col2 DIV - ( cor0.col0 ) + col1 * ( + col0 ) DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-2529
SELECT col2 / - ( cor0.col0 ) + col1 * ( + col0 ) / cor0.col1 AS col1 FROM tab2 AS cor0
----
4
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2530
SELECT ALL + col0 + + 98 DIV col1 AS col1 FROM tab1 AS cor0
----
6
73
87

skipif mysql # not compatible
query I rowsort label-2530
SELECT ALL + col0 + + 98 / col1 AS col1 FROM tab1 AS cor0
----
6
73
87

query I rowsort
SELECT DISTINCT col0 - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * ( ( - col0 ) ) * + col1 col2 FROM tab2 cor0
----
22831
271518
6727

query I rowsort
SELECT cor0.col2 + 53 FROM tab1 AS cor0
----
107
110
149

query I rowsort
SELECT cor0.col2 * col2 + + col0 * - col1 AS col0 FROM tab2 AS cor0
----
-3926
101
512

onlyif mysql # use DIV operator for integer division
query I rowsort label-2535
SELECT DISTINCT - - col1 + + col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-2535
SELECT DISTINCT - - col1 + + col0 / - col1 AS col2 FROM tab1 AS cor0
----
26
4
7

query I rowsort
SELECT ALL + tab2.col1 FROM tab2, tab1 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

onlyif mysql # use DIV operator for integer division
query I rowsort label-2537
SELECT col1 DIV + col2 AS col2 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2537
SELECT col1 / + col2 AS col2 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT - 99 + col2 AS col1 FROM tab2 AS cor0
----
-61
-72
-73

query I rowsort
SELECT DISTINCT ( 5 ) * col2 FROM tab1 cor0
----
270
285
480

query I rowsort
SELECT - 90 + + col0 FROM tab0 cor0
----
-1
-55
-66

query I rowsort
SELECT ALL - - col2 + col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT col1 + 62 AS col1 FROM tab0 AS cor0
----
148
153
159

query I rowsort
SELECT ( 15 ) FROM tab0 cor0
----
15
15
15

query I rowsort
SELECT DISTINCT - + ( + col1 ) * + col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 99 * cor0.col2 FROM tab0 AS cor0
----
-3267
-8118
-99

query I rowsort
SELECT DISTINCT - - col2 * col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + 17 AS col1 FROM tab1 cor0
----
17

query I rowsort
SELECT - - 17 * col1 + - col0 FROM tab2 AS cor0
----
210
520
925

query I rowsort
SELECT ALL - cor0.col0 * col2 + col1 * col0 AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-2550
SELECT - - col1 DIV cor0.col0 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2550
SELECT - - col1 / cor0.col0 FROM tab0 cor0
----
1
2
3

query I rowsort
SELECT col1 * + 77 AS col2 FROM tab1 AS cor0
----
1001
2002
770

query I rowsort
SELECT ALL + - 89 + + 5 * col0 FROM tab0 AS cor0
----
31
356
86

query I rowsort
SELECT + col0 + + col2 - + 79 AS col2 FROM tab1 AS cor0
----
-22
42
97

query I rowsort
SELECT + col1 + - col2 - cor0.col0 FROM tab2 AS cor0
----
-100
-3
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2555
SELECT 49 DIV col0 + + ( col0 ) - col1 col1 FROM tab2 AS cor0
----
-17
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2555
SELECT 49 / col0 + + ( col0 ) - col1 col1 FROM tab2 AS cor0
----
-17
19
62

query I rowsort
SELECT DISTINCT col1 * col1 + col0 * col0 AS col2 FROM tab1 AS cor0
----
4196
6569
685

query I rowsort
SELECT ALL 11 + - 42 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2558
SELECT col0 * - col0 + CAST( + 85 * col0 AS SIGNED ) - + col2 AS col2 FROM tab1 AS cor0
----
1287
192
304

skipif mysql # not compatible
query I rowsort label-2558
SELECT col0 * - col0 + CAST ( + 85 * col0 AS INTEGER ) - + col2 AS col2 FROM tab1 AS cor0
----
1287
192
304

query I rowsort
SELECT DISTINCT col1 + - col1 * col2 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2560
SELECT + 77 * - col0 - CAST( NULL AS SIGNED ) * - 84 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2560
SELECT + 77 * - col0 - CAST ( NULL AS INTEGER ) * - 84 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 97 + col2 * + col1 + col0 FROM tab2 AS cor0
----
1709
822
941

onlyif mysql # use DIV operator for integer division
query I rowsort label-2562
SELECT - col1 * + cor0.col0 DIV col0 + + col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
0
2752
7371

skipif mysql # not compatible
query I rowsort label-2562
SELECT - col1 * + cor0.col0 / col0 + + col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2563
SELECT - CAST( NULL AS DECIMAL ) + 1 * col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2563
SELECT - CAST ( NULL AS REAL ) + 1 * col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col0 + col2 * - col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT + 49 + cor0.col0 AS col2 FROM tab0 cor0
----
138
73
84

query I rowsort
SELECT col1 * + 93 + col1 AS col0 FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT + - ( - 34 ) AS col1 FROM tab2 AS cor0
----
34
34
34

query I rowsort
SELECT + ( col1 ) * col0 + - ( cor0.col1 * - col1 ) AS col2 FROM tab2 AS cor0
----
1178
1632
8083

query I rowsort
SELECT ALL + col2 * col2 + - col1 AS col2 FROM tab2
----
1427
617
698

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2570
SELECT tab1.col2 * + 94 + cor0.col0 + + CAST( NULL AS SIGNED ) FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2570
SELECT tab1.col2 * + 94 + cor0.col0 + + CAST ( NULL AS INTEGER ) FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ( - cor0.col0 ) FROM tab1, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT DISTINCT cor0.col0 * - col2 + + col1 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2573
SELECT CAST( - col0 AS SIGNED ) * col0 FROM tab0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-2573
SELECT CAST ( - col0 AS INTEGER ) * col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL 62 * + col0 FROM tab0
----
1488
2170
5518

query I rowsort
SELECT - ( + ( + cor0.col1 ) ) * - 13 * 52 + col2 AS col0 FROM tab0 AS cor0
----
58169
61598
65573

query I rowsort
SELECT - 18 + col2 FROM tab0 AS cor0
----
-17
15
64

query I rowsort
SELECT + + col0 * 60 AS col0 FROM tab0 AS cor0
----
1440
2100
5340

query I rowsort
SELECT - - ( - col1 ) * - col2 * + 75 AS col0 FROM tab1 AS cor0
----
105300
42750
93600

onlyif mysql # use DIV operator for integer division
query I rowsort label-2579
SELECT - col2 + 48 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
-21
-26
-38

skipif mysql # not compatible
query I rowsort label-2579
SELECT - col2 + 48 / cor0.col0 AS col2 FROM tab2 AS cor0
----
-21
-26
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2580
SELECT ALL + - cor0.col0 DIV + col1 + ( col1 ) AS col1 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-2580
SELECT ALL + - cor0.col0 / + col1 + ( col1 ) AS col1 FROM tab2 AS cor0
----
13
31
58

query I rowsort
SELECT ALL - - cor0.col1 * ( ( cor0.col0 ) ) + + col0 * - col0 AS col2 FROM tab0 AS cor0
----
1488
178
2170

query I rowsort
SELECT ALL - col1 + + col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col0 * + ( col2 ) AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - cor0.col1 * + 80 FROM tab1 AS cor0
----
-1040
-2080
-800

query I rowsort
SELECT + col0 * 55 - col0 FROM tab1 cor0
----
162
3456
4320

query I rowsort
SELECT col2 - col0 * + col1 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL tab0.col2 - col1 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + 37 * col1 AS col0 FROM tab2 AS cor0
----
1147
2183
629

query I rowsort
SELECT 26 * + col1 AS col2 FROM tab1 AS cor0
----
260
338
676

query I rowsort
SELECT ALL - - 59 FROM tab1 cor0
----
59
59
59

query I rowsort
SELECT - - col2 + + ( col0 ) AS col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL ( col2 ) * + col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + cor0.col0 * + cor0.col0 AS col1 FROM tab2 cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2594
SELECT col2 + col0 * CAST( col1 AS SIGNED ) AS col2 FROM tab0
----
2097
3396
8181

skipif mysql # not compatible
query I rowsort label-2594
SELECT col2 + col0 * CAST ( col1 AS INTEGER ) AS col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT - cor0.col1 * + 92 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 3f3a5de57fe29f0bbd60295659c92a43

query I rowsort
SELECT + + cor0.col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 34 col1 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT - col1 * ( col0 ) + col1 * 41 FROM tab2 AS cor0
----
-2183
-646
1054

onlyif mysql # use DIV operator for integer division
query I rowsort label-2599
SELECT ALL + col0 DIV + col0 AS col2 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2599
SELECT ALL + col0 / + col0 AS col2 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT cor0.col1 + 76 AS col2 FROM tab1 AS cor0
----
102
86
89

query I rowsort
SELECT + col2 + 41 * - 96 FROM tab0 AS cor0
----
-3854
-3903
-3935

query I rowsort
SELECT - cor0.col2 * cor0.col2 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 34c958561bd6b2ab014ab6e0643406fa

query I rowsort
SELECT + - ( + col1 ) AS col1 FROM tab0 cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2604
SELECT ALL 41 + - ( - col0 ) DIV - 88 FROM tab0
----
40
41
41

skipif mysql # not compatible
query I rowsort label-2604
SELECT ALL 41 + - ( - col0 ) / - 88 FROM tab0
----
40
41
41

query I rowsort
SELECT + col0 * col1 + col0 * col2 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT + col0 + ( col0 * 15 ) AS col2 FROM tab0
----
1424
384
560

query I rowsort
SELECT ALL - cor0.col1 * + col0 * col2 AS col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - - 4 FROM tab0 AS cor0
----
4
4
4

query I rowsort
SELECT - 90 * + 24 AS col1 FROM tab0 cor0
----
-2160
-2160
-2160

query I rowsort
SELECT DISTINCT + ( + cor0.col2 ) * + col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - 0 + - col1 AS col2 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT - 9 * + col1 + - col1 AS col1 FROM tab0 cor0
----
-860
-910
-970

query I rowsort
SELECT - 75 * cor0.col2 + col1 FROM tab2 AS cor0
----
-1891
-1994
-2833

query I rowsort
SELECT DISTINCT - - col2 + - ( - col0 + + col1 ) * col0 FROM tab0 AS cor0
----
-1455
-2169
-96

query I rowsort
SELECT 70 + - col1 FROM tab2 AS cor0
----
11
39
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-2616
SELECT + col2 DIV + col2 + + col2 + - 32 FROM tab0 AS cor0
----
-30
2
51

skipif mysql # not compatible
query I rowsort label-2616
SELECT + col2 / + col2 + + col2 + - 32 FROM tab0 AS cor0
----
-30
2
51

query I rowsort
SELECT - 19 * + col1 FROM tab1 AS cor0
----
-190
-247
-494

onlyif mysql # use DIV operator for integer division
query I rowsort label-2618
SELECT ALL col1 * col0 * 42 + col0 DIV - col1 FROM tab1 cor0
----
26874
3276
43674

skipif mysql # not compatible
query I rowsort label-2618
SELECT ALL col1 * col0 * 42 + col0 / - col1 FROM tab1 cor0
----
26874
3276
43674

query I rowsort
SELECT ALL - ( + col2 ) + + tab1.col0 + col1 * col2 FROM tab1
----
1232
1353
577

query I rowsort
SELECT tab2.col1 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col2 * - 69 - col0 AS col2 FROM tab1
----
-3729
-3997
-6704

onlyif mysql # use DIV operator for integer division
query I rowsort label-2622
SELECT ALL col1 DIV - 75 + col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2622
SELECT ALL col1 / - 75 + col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * ( - cor0.col1 ) col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + col0 + - cor0.col1 * + 91 FROM tab2 cor0
----
-1468
-2814
-5291

query I rowsort
SELECT ALL - cor0.col1 + + col2 * - 99 AS col1 FROM tab1 AS cor0
----
-5372
-5653
-9517

query I rowsort
SELECT - col0 * ( + cor0.col1 ) AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - col0 * 92 + col1 FROM tab2 AS cor0
----
-613
-7117
-7251

query I rowsort
SELECT + + col1 * + col2 + + 76 FROM tab1 AS cor0
----
1324
1480
646

query I rowsort
SELECT DISTINCT + 21 AS col1 FROM tab0
----
21

query I rowsort
SELECT ALL col1 * ( + ( col2 ) ) + - ( 48 ) AS col0 FROM tab2 cor0
----
1486
598
789

query I rowsort
SELECT ALL - col1 * - 29 + 99 AS col0 FROM tab2 AS cor0
----
1810
592
998

query I rowsort
SELECT DISTINCT col0 + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-2633
SELECT DISTINCT - cor0.col2 DIV + tab0.col0 FROM tab0, tab1 AS cor0
----
-1
-2
-4
0

skipif mysql # not compatible
query I rowsort label-2633
SELECT DISTINCT - cor0.col2 / + tab0.col0 FROM tab0, tab1 AS cor0
----
-1
-2
-4
0

query I rowsort
SELECT ALL - cor0.col0 * + col1 * col0 AS col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT col0 * ( + 24 ) + + col2 FROM tab0 AS cor0
----
2218
609
841

onlyif mysql # use DIV operator for integer division
query I rowsort label-2636
SELECT + - col2 * - 27 - - cor0.col2 DIV - col2 AS col2 FROM tab0 AS cor0
----
2213
26
890

skipif mysql # not compatible
query I rowsort label-2636
SELECT + - col2 * - 27 - - cor0.col2 / - col2 AS col2 FROM tab0 AS cor0
----
2213
26
890

onlyif mysql # use DIV operator for integer division
query I rowsort label-2637
SELECT + CAST( ( - col1 ) AS SIGNED ) * - col0 - col1 DIV + col2 FROM tab0 AS cor0
----
2062
3298
8098

skipif mysql # not compatible
query I rowsort label-2637
SELECT + CAST ( ( - col1 ) AS INTEGER ) * - col0 - col1 / + col2 FROM tab0 AS cor0
----
2062
3298
8098

onlyif mysql # use DIV operator for integer division
query I rowsort label-2638
SELECT + 23 + col0 * cor0.col0 DIV + col1 FROM tab1 AS cor0
----
23
432
515

skipif mysql # not compatible
query I rowsort label-2638
SELECT + 23 + col0 * cor0.col0 / + col1 FROM tab1 AS cor0
----
23
432
515

query I rowsort
SELECT DISTINCT col0 - tab2.col0 AS col2 FROM tab2
----
0

query IIIIIIIII rowsort
SELECT * FROM tab0, tab2, tab0 AS cor0 WHERE ( NULL ) BETWEEN cor0.col0 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 85 * - cor0.col0 col0 FROM tab1 AS cor0
----
-255
-5440
-6800

query I rowsort
SELECT - 91 + cor0.col1 + - col0 FROM tab1 AS cor0
----
-145
-158
-68

query I rowsort
SELECT DISTINCT - 88 * - col0 AS col0 FROM tab2 AS cor0
----
616
6864
6952

query I rowsort
SELECT + - ( 86 ) AS col1 FROM tab0 AS cor0
----
-86
-86
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 * - 86 + col0 col2 FROM tab2 AS cor0
----
-595
-6630
-6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-2646
SELECT 4 - - col0 DIV col2 col0 FROM tab1 AS cor0
----
4
4
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2646
SELECT 4 - - col0 / col2 col0 FROM tab1 AS cor0
----
4
4
5

query I rowsort
SELECT - 71 AS col0 FROM tab0, tab2, tab1 AS cor0, tab1
----
81 values hashing to ac364708ef97c5cf80f126fc088b952e

query I rowsort
SELECT tab2.col1 + - ( ( col1 ) ) AS col2 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2649
SELECT ALL 76 DIV col0 + - tab2.col2 AS col2 FROM tab2
----
-17
-26
-38

skipif mysql # not compatible
query I rowsort label-2649
SELECT ALL 76 / col0 + - tab2.col2 AS col2 FROM tab2
----
-17
-26
-38

query I rowsort
SELECT DISTINCT - col1 - 66 * col0 * - 17 AS col2 FROM tab1 AS cor0
----
3340
71798
89747

query I rowsort
SELECT + + 97 * 96 - - col1 * + ( - col2 ) FROM tab0 AS cor0
----
1850
6474
9215

query I rowsort
SELECT ALL + col2 - 14 AS col1 FROM tab1 AS cor0
----
40
43
82

query I rowsort
SELECT ALL 92 + col1 + col1 AS col1 FROM tab0 AS cor0
----
264
274
286

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 95 col2 FROM tab2 AS cor0
----
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2655
SELECT - col1 DIV cor0.col1 - - col2 AS col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-2655
SELECT - col1 / cor0.col1 - - col2 AS col0 FROM tab0 AS cor0
----
0
32
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2656
SELECT DISTINCT 50 DIV col0 FROM tab2
----
0
7

skipif mysql # not compatible
query I rowsort label-2656
SELECT DISTINCT 50 / col0 FROM tab2
----
0
7

query I rowsort
SELECT + 73 + col0 + ( 13 ) * + col2 * 23 FROM tab1 AS cor0
----
16222
17180
28857

query I rowsort
SELECT ALL + - ( + col2 ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT 48 * + col2 + 63 + col1 * + col1 AS col0 FROM tab0 cor0
----
12280
9043
9520

query I rowsort
SELECT + ( - col1 ) * 54 FROM tab0 AS cor0
----
-4644
-4914
-5238

onlyif mysql # use DIV operator for integer division
query I rowsort label-2661
SELECT ALL - col2 + + cor0.col0 DIV col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-2661
SELECT ALL - col2 + + cor0.col0 / col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - - cor0.col1 + - col1 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2663
SELECT + col0 * - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2663
SELECT + col0 * - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * 19 FROM tab1 cor0
----
-1216
-1520
-57

query I rowsort
SELECT 82 * - cor1.col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 9407a5cb6cd5969cd3bac57de31d084b

query I rowsort
SELECT - col1 * - 91 FROM tab1 AS cor0
----
1183
2366
910

query I rowsort
SELECT 92 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT - + 22 AS col1 FROM tab0 cor0
----
-22
-22
-22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 81 col0 FROM tab0 AS cor0
----
81

query I rowsort
SELECT + - 21 * col0 AS col1 FROM tab2 AS cor0
----
-147
-1638
-1659

onlyif mysql # use DIV operator for integer division
query I rowsort label-2671
SELECT ALL + - cor0.col1 + col1 DIV 49 AS col2 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-2671
SELECT ALL + - cor0.col1 + col1 / 49 AS col2 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT + ( - cor0.col0 ) FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT ( - col2 ) + + col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT - col1 + tab0.col0 * + ( col1 * col1 ) FROM tab0
----
177418
329218
736918

query I rowsort
SELECT - + col0 * - col1 + 51 * col2 * ( - col1 ) AS col2 FROM tab1 AS cor0
----
-28430
-62608
-71526

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 60 col1 FROM tab1 cor0
----
60

query I rowsort
SELECT DISTINCT - ( tab2.col2 * col2 ) AS col1 FROM tab2
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 2 col2 FROM tab1
----
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 25 col2 FROM tab2 cor0
----
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-2680
SELECT ALL col2 DIV 96 + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2680
SELECT ALL col2 / 96 + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT ( + 99 ) AS col0 FROM tab2 AS cor0
----
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2682
SELECT ALL + CAST( NULL AS SIGNED ) * - ( - col2 ) * ( - ( - col0 ) ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2682
SELECT ALL + CAST ( NULL AS INTEGER ) * - ( - col2 ) * ( - ( - col0 ) ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + 89 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0 cor2
----
81 values hashing to bb5bb13eab35a33bb4641905f5e7c9b6

query I rowsort
SELECT DISTINCT + cor1.col1 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
10
13
26

query I rowsort
SELECT 68 * + col0 FROM tab1
----
204
4352
5440

query I rowsort
SELECT DISTINCT + 25 * tab0.col0 AS col2 FROM tab0, tab1, tab2 AS cor0
----
2225
600
875

query I rowsort
SELECT DISTINCT ( col0 ) * + tab1.col2 * + 34 FROM tab1
----
124032
261120
5508

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 92 col1 FROM tab1
----
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - col1 col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - 68 FROM tab0, tab1 cor0
----
-68

query I rowsort
SELECT - col1 + 60 * col2 FROM tab1 AS cor0
----
3214
3410
5747

query I rowsort
SELECT 54 * 49 FROM tab1 AS cor0
----
2646
2646
2646

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2693
SELECT - + CAST( + ( cor0.col0 ) AS SIGNED ) * ( 57 ) + + col1 FROM tab2 AS cor0
----
-368
-4387
-4486

skipif mysql # not compatible
query I rowsort label-2693
SELECT - + CAST ( + ( cor0.col0 ) AS INTEGER ) * ( 57 ) + + col1 FROM tab2 AS cor0
----
-368
-4387
-4486

query I rowsort
SELECT - cor0.col1 * + cor0.col1 * + col0 AS col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT - + 11 * - col1 FROM tab0 AS cor0
----
1001
1067
946

onlyif mysql # use DIV operator for integer division
query I rowsort label-2696
SELECT ALL col0 DIV ( col1 + + col2 ) AS col2 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2696
SELECT ALL col0 / ( col1 + + col2 ) AS col2 FROM tab2
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 53 col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

query I rowsort
SELECT + ( + 69 ) + col0 AS col0 FROM tab1 AS cor0
----
133
149
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-2699
SELECT cor0.col1 * col2 + col0 DIV ( col0 ) FROM tab1 AS cor0
----
1249
1405
571

skipif mysql # not compatible
query I rowsort label-2699
SELECT cor0.col1 * col2 + col0 / ( col0 ) FROM tab1 AS cor0
----
1249
1405
571

query I rowsort
SELECT + + cor0.col1 + cor0.col2 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col1 - + col2 col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL col0 * tab0.col0 * - tab0.col0 - 68 * - col0 FROM tab0
----
-12192
-40495
-698917

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2703
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0 CROSS JOIN tab2 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2703
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0 CROSS JOIN tab2 cor1
----
NULL

query I rowsort
SELECT - ( - ( 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-2705
SELECT col1 * tab2.col2 + - CAST( 24 AS SIGNED ) FROM tab2
----
1510
622
813

skipif mysql # not compatible
query I rowsort label-2705
SELECT col1 * tab2.col2 + - CAST ( 24 AS INTEGER ) FROM tab2
----
1510
622
813

query I rowsort
SELECT ( - cor0.col1 ) + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT tab1.col2 * col1 - col2 FROM tab1
----
1152
1350
513

query I rowsort
SELECT col0 * - col1 * + col0 AS col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT - col1 * + col1 + - col0 + col1 * - col1 AS col2 FROM tab0 AS cor0
----
-14816
-16651
-18853

query I rowsort
SELECT + col0 * ( - col0 ) - - col0 AS col2 FROM tab0 AS cor0
----
-1190
-552
-7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col1 * col2 col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL col2 * - col0 + - col2 FROM tab2
----
-2054
-216
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + ( - 91 ) * col2 + col1 col2 FROM tab1
----
-4862
-5167
-8710

query I rowsort
SELECT + cor0.col2 - + 28 AS col0 FROM tab0 AS cor0
----
-27
5
54

query I rowsort
SELECT ALL - col0 + 21 + - col1 * - col2 * 82 FROM tab2 AS cor0
----
125731
52914
68648

query I rowsort
SELECT ALL - col0 + + ( + col0 ) FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 7 col0 FROM tab2 AS cor0
----
19
20
31

query I rowsort
SELECT ALL - - cor0.col1 * + col1 - col0 AS col2 FROM tab1 cor0
----
36
673
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2719
SELECT DISTINCT col1 DIV + col2 AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-2719
SELECT DISTINCT col1 / + col2 AS col2 FROM tab1
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2720
SELECT - col1 * + col0 + - col2 DIV ( 22 ) AS col1 FROM tab2
----
-1344
-218
-4603

skipif mysql # not compatible
query I rowsort label-2720
SELECT - col1 * + col0 + - col2 / ( 22 ) AS col1 FROM tab2
----
-1344
-218
-4603

query I rowsort
SELECT - ( - col2 ) * col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT col1 + + col0 * col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT - 82 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

query I rowsort
SELECT + col1 + col0 * + col0 AS col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT + cor0.col0 * + cor1.col2 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 3308937e73f3503fa2b2a0ef235eb3c1

query I rowsort
SELECT - 91 * 16 AS col1 FROM tab2 AS cor0
----
-1456
-1456
-1456

query I rowsort
SELECT DISTINCT + - ( cor0.col1 ) * - col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col2 - col2 AS col2 FROM tab2 cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL 16 + col2 * col0 FROM tab2 AS cor0
----
2044
205
3018

onlyif mysql # use DIV operator for integer division
query I rowsort label-2730
SELECT DISTINCT + col2 DIV cor0.col0 + - cor0.col1 * col2 AS col0 FROM tab0 AS cor0
----
-2837
-7462
-97

skipif mysql # not compatible
query I rowsort label-2730
SELECT DISTINCT + col2 / cor0.col0 + - cor0.col1 * col2 AS col0 FROM tab0 AS cor0
----
-2837
-7462
-97

query I rowsort
SELECT ALL col2 - cor0.col2 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 62 col1 FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT DISTINCT - col1 * - cor0.col0 + - ( col0 ) * - col1 FROM tab2 AS cor0
----
2686
434
9204

query I rowsort
SELECT ALL + col2 + col0 * col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + 46 * - col1 FROM tab2 AS cor0
----
-1426
-2714
-782

query I rowsort
SELECT ALL + ( - 46 * col2 ) FROM tab1
----
-2484
-2622
-4416

query I rowsort
SELECT DISTINCT 89 * col1 FROM tab2
----
1513
2759
5251

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2738
SELECT CAST( NULL AS SIGNED ) + - ( - col1 ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2738
SELECT CAST ( NULL AS INTEGER ) + - ( - col1 ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 64 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT DISTINCT + col0 * - col2 + + col2 AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - ( + col0 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - col2 * - col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-2743
SELECT - 75 DIV tab0.col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-2743
SELECT - 75 / tab0.col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT + 42 AS col1 FROM tab1 cor0
----
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + 70 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 2e4b0341591600f2cc3d947ab4b409d9

query I rowsort
SELECT - cor0.col0 * ( col2 ) AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + 49 * - col1 AS col0 FROM tab0
----
-4214
-4459
-4753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2748
SELECT + CAST( cor0.col0 AS SIGNED ) * col2 + col0 + + col2 FROM tab0 AS cor0
----
71
7469
849

skipif mysql # not compatible
query I rowsort label-2748
SELECT + CAST ( cor0.col0 AS INTEGER ) * col2 + col0 + + col2 FROM tab0 AS cor0
----
71
7469
849

query I rowsort
SELECT ALL - - 20 FROM tab1 cor0
----
20
20
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + col1 col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + ( + 28 ) * col1 FROM tab1 AS cor0
----
280
364
728

query I rowsort
SELECT - col2 * + cor0.col1 + + col1 * 7 FROM tab1 AS cor0
----
-1157
-1222
-500

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2753
SELECT CAST( NULL AS DECIMAL ) + + 4 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2753
SELECT CAST ( NULL AS REAL ) + + 4 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - ( + col2 ) + col1 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2755
SELECT DISTINCT - 76 + col1 * col2 * - CAST( NULL AS SIGNED ) - - cor0.col0 col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2755
SELECT DISTINCT - 76 + col1 * col2 * - CAST ( NULL AS INTEGER ) - - cor0.col0 col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - + col2 * col1 + col2 FROM tab1 cor0
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 81 col2 FROM tab2 AS cor0
----
159
160
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2758
SELECT DISTINCT - + CAST( NULL AS SIGNED ) - 55 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2758
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) - 55 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2759
SELECT DISTINCT + col2 + 46 DIV 60 AS col1 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2759
SELECT DISTINCT + col2 + 46 / 60 AS col1 FROM tab2
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2760
SELECT ALL col1 * CAST( NULL AS SIGNED ) + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2760
SELECT ALL col1 * CAST ( NULL AS INTEGER ) + col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * col0 + col2 * tab1.col2 AS col2 FROM tab1
----
16896
3078
6897

query I rowsort
SELECT col0 * col2 * + col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT ALL col0 + + 27 * + 78 AS col1 FROM tab2
----
2113
2184
2185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col1 + - ( 68 ) * - col2 col0 FROM tab1
----
3698
3886
6541

query I rowsort
SELECT ALL 18 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT ( - col2 ) + col0 * - ( col1 ) FROM tab2
----
-1381
-244
-4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2767
SELECT ALL CAST( NULL AS SIGNED ) * col0 + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2767
SELECT ALL CAST ( NULL AS INTEGER ) * col0 + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2768
SELECT DISTINCT + CAST( - 90 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-90

skipif mysql # not compatible
query I rowsort label-2768
SELECT DISTINCT + CAST ( - 90 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-90

query I rowsort
SELECT - col2 + + 86 FROM tab2 AS cor0
----
48
59
60

query I rowsort
SELECT ALL - 71 + col1 AS col2 FROM tab2 AS cor0
----
-12
-40
-54

query I rowsort
SELECT ALL ( 66 ) * col2 + - col0 FROM tab1 AS cor0
----
3561
3698
6256

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col1 col0 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - + col2 * ( col1 * col2 ) + - col2 FROM tab2 cor0
----
-22626
-24586
-39910

onlyif mysql # use DIV operator for integer division
query I rowsort label-2774
SELECT ALL - 74 + cor0.col0 DIV col2 FROM tab0 AS cor0
----
-39
-73
-74

skipif mysql # not compatible
query I rowsort label-2774
SELECT ALL - 74 + cor0.col0 / col2 FROM tab0 AS cor0
----
-39
-73
-74

query I rowsort
SELECT tab2.col1 + col1 * 55 AS col0 FROM tab2
----
1736
3304
952

query I rowsort
SELECT ( - tab0.col1 ) FROM tab0, tab2 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT + - col1 * - col2 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL col2 * 49 AS col0 FROM tab2
----
1274
1323
1862

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( 67 ) * - col0 col0 FROM tab0 AS cor0
----
-1608
-2345
-5963

query I rowsort
SELECT ( 50 ) + col0 FROM tab0 AS cor0
----
139
74
85

query I rowsort
SELECT ( - tab1.col1 ) + - col2 FROM tab1
----
-109
-67
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2782
SELECT CAST( NULL AS SIGNED ) * col0 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2782
SELECT CAST ( NULL AS INTEGER ) * col0 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( 89 ) FROM tab2 cor0
----
89
89
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2784
SELECT - CAST( NULL AS DECIMAL ) * 19 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2784
SELECT - CAST ( NULL AS REAL ) * 19 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 63 * col0 col2 FROM tab2
----
-441
-4914
-4977

query I rowsort
SELECT DISTINCT + 71 * - col1 FROM tab2 AS cor0
----
-1207
-2201
-4189

query I rowsort
SELECT 36 + + col0 FROM tab2 AS cor0
----
114
115
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-2788
SELECT - col2 + - col1 DIV col0 AS col1 FROM tab1 AS cor0
----
-57
-62
-96

skipif mysql # not compatible
query I rowsort label-2788
SELECT - col2 + - col1 / col0 AS col1 FROM tab1 AS cor0
----
-57
-62
-96

query I rowsort
SELECT + - col2 * col0 + + col0 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT cor0.col1 * ( + 32 ) FROM tab2 cor0
----
1888
544
992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2791
SELECT - cor0.col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2791
SELECT - cor0.col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 66 ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT + col0 * 55 AS col2 FROM tab2 AS cor0
----
385
4290
4345

query I rowsort
SELECT + col2 + col1 + 97 AS col2 FROM tab1 AS cor0
----
164
177
206

query I rowsort
SELECT + + cor0.col2 * + cor0.col2 * cor0.col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT col1 + ( cor0.col1 ) * col0 FROM tab0 AS cor0
----
2150
3492
8190

skipif mysql # not compatible
query I rowsort
SELECT ALL - - col0 * + CAST ( + col0 AS REAL ) AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - col1 * - col1 AS col1 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL col0 * col0 * col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT ALL - col1 * + 48 + 4 + - col0 FROM tab2 AS cor0
----
-1491
-2906
-891

query I rowsort
SELECT ALL col2 * + ( col2 ) + col0 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT + col0 * 82 + + cor0.col2 FROM tab0 AS cor0
----
2001
2871
7380

query I rowsort
SELECT DISTINCT - 74 AS col1 FROM tab2, tab2 AS cor0
----
-74

query I rowsort
SELECT DISTINCT cor0.col1 * + col0 + + col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - 81 FROM tab2 cor0
----
-81
-81
-81

query I rowsort
SELECT DISTINCT 28 * ( + col0 ) AS col2 FROM tab2 AS cor0
----
196
2184
2212

onlyif mysql # use DIV operator for integer division
query I rowsort label-2807
SELECT ALL col1 * col2 + col1 DIV col2 AS col2 FROM tab0 cor0
----
194
2840
7463

skipif mysql # not compatible
query I rowsort label-2807
SELECT ALL col1 * col2 + col1 / col2 AS col2 FROM tab0 cor0
----
194
2840
7463

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2808
SELECT CAST( - cor0.col0 AS SIGNED ) * - col2 FROM tab1 cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-2808
SELECT CAST ( - cor0.col0 AS INTEGER ) * - col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT col2 * col0 - - col2 AS col1 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT tab1.col0 + tab1.col2 * - tab1.col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT - - 73 + col0 FROM tab0 AS cor0
----
108
162
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 16 col1 FROM tab1
----
16
16
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 78 * - col1 - + col0 col1 FROM tab2
----
-1405
-2425
-4680

query I rowsort
SELECT ( cor0.col1 ) FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col0 * - col2 * + col0 - 6 * col1 FROM tab0 AS cor0
----
-1807
-19524
-650068

query I rowsort
SELECT col2 - - tab1.col0 AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL + 35 + + col2 * cor0.col2 FROM tab2 cor0
----
1479
711
764

query I rowsort
SELECT ALL + - col0 * col1 + - col1 * - 86 * col2 AS col0 FROM tab0 AS cor0
----
242004
4947
633633

query I rowsort
SELECT ALL - col1 * col2 + - 38 - - col2 * col2 AS col2 FROM tab2 AS cor0
----
-146
-896
760

query I rowsort
SELECT ALL col0 + col2 * + col1 - - col1 AS col0 FROM tab0 AS cor0
----
229
2948
7642

query I rowsort
SELECT DISTINCT - - 69 * - col1 AS col0 FROM tab1 cor0
----
-1794
-690
-897

onlyif mysql # use DIV operator for integer division
query I rowsort label-2822
SELECT ALL col0 * + col1 - - col2 * col1 DIV - col1 AS col2 FROM tab2
----
1305
190
4576

skipif mysql # not compatible
query I rowsort label-2822
SELECT ALL col0 * + col1 - - col2 * col1 / - col1 AS col2 FROM tab2
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col0 col1 FROM tab0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2824
SELECT col0 DIV col2 + col0 * col0 + col0 FROM tab1
----
12
4161
6480

skipif mysql # not compatible
query I rowsort label-2824
SELECT col0 / col2 + col0 * col0 + col0 FROM tab1
----
12
4161
6480

query I rowsort
SELECT DISTINCT 95 * - col1 AS col0 FROM tab2
----
-1615
-2945
-5605

query I rowsort
SELECT - cor0.col1 * tab0.col1 AS col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to cf1f1787c87e3eb0ada93179d2b556c3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2827
SELECT ALL - col0 * tab2.col2 - - CAST( col2 + col1 AS SIGNED ) FROM tab2
----
-131
-1943
-2947

skipif mysql # not compatible
query I rowsort label-2827
SELECT ALL - col0 * tab2.col2 - - CAST ( col2 + col1 AS INTEGER ) FROM tab2
----
-131
-1943
-2947

query I rowsort
SELECT col1 + - col1 + col2 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT - tab0.col0 * col1 + col2 + - col2 FROM tab0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 97 + + cor0.col0 col2 FROM tab2 cor0
----
104
175
176

query I rowsort
SELECT DISTINCT + cor0.col2 + + col2 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) * - 47 - col1 col1 FROM tab0 AS cor0
----
-144
-1637
-3945

query I rowsort
SELECT ALL - col1 * col1 * col2 AS col2 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT ALL + tab1.col2 * + col2 AS col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT + col0 * col0 + col2 + tab0.col1 AS col0 FROM tab0
----
1323
695
8094

query III rowsort
SELECT * FROM tab0 WHERE + col0 + + col1 IN ( col2 * - tab0.col2 + col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col2 + - col0 NOT IN ( col0 + - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * tab1.col1 + col2 * + col2 col0 FROM tab1
----
10464
3819
4320

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN NULL AND ( + col0 / - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 + col1 col1 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT col1 * col1 + tab1.col0 AS col1 FROM tab1
----
164
249
679

query I rowsort
SELECT DISTINCT col1 + - tab0.col0 * - col0 AS col2 FROM tab0
----
1322
662
8012

query III rowsort
SELECT * FROM tab1 WHERE NOT col0 + col1 = col2 + col1 * col2
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL tab1.col2 + - col2 * + col2 FROM tab1
----
-2862
-3192
-9120

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( + col0 + - col0 * col0 * col2 ) IN ( - col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT + col0 * col0 FROM tab2 WHERE NOT NULL NOT IN ( tab2.col2 )
----

query I rowsort
SELECT + col0 AS col2 FROM tab0 WHERE NULL IN ( + col1 * col1 + col2 )
----

query I rowsort
SELECT col0 AS col2 FROM tab2 WHERE NOT NULL <= - col1
----

query I rowsort
SELECT ALL - col1 FROM tab0 WHERE NOT NULL IN ( + col1 )
----

query I rowsort
SELECT ALL - col0 * col1 * col0 + col1 * col2 AS col1 FROM tab1
----
-40390
-81952
1170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - + col2 col0 FROM tab2
----
-20
41
52

query III rowsort
SELECT * FROM tab1 WHERE NOT + col0 NOT IN ( - tab1.col1 * - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 - col1 col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 AS col2 FROM tab2 WHERE NOT col2 * col2 NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT 21 * + col0 FROM tab0
----
1869
504
735

query I rowsort
SELECT - 47 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

query I rowsort
SELECT + 22 * - col2 FROM tab2 AS cor0
----
-572
-594
-836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 51 * col2 col1 FROM tab1 AS cor0
----
-2754
-2907
-4896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + 95 col1 FROM tab0 AS cor0
----
-2
4
9

query I rowsort
SELECT DISTINCT + ( + col1 ) + - col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT - - col2 * - 70 FROM tab1 AS cor0
----
-3780
-3990
-6720

query I rowsort
SELECT ALL - ( - col1 ) FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - 6 + - col0 FROM tab2 AS cor0
----
-13
-84
-85

query I rowsort
SELECT ALL - - cor0.col2 * col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ( + col2 ) * 42 AS col0 FROM tab2 AS cor0
----
1092
1134
1596

query I rowsort
SELECT DISTINCT - col2 * col2 * 84 + col0 FROM tab1 AS cor0
----
-244941
-272852
-774064

query I rowsort
SELECT ALL cor0.col1 * + col2 - ( + col2 ) FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL + ( cor0.col2 ) * col2 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-2869
SELECT ALL + col1 * col2 DIV ( ( + col0 ) ) AS col2 FROM tab2 AS cor0
----
119
19
8

skipif mysql # not compatible
query I rowsort label-2869
SELECT ALL + col1 * col2 / ( ( + col0 ) ) AS col2 FROM tab2 AS cor0
----
119
19
8

query I rowsort
SELECT - 6 + ( + col0 ) FROM tab0
----
18
29
83

query I rowsort
SELECT DISTINCT - tab2.col1 * + col1 * col0 AS col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT ( col0 ) * - col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + 73 * col2 + cor0.col1 + - 11 FROM tab2 AS cor0
----
1946
1991
2780

onlyif mysql # use DIV operator for integer division
query I rowsort label-2874
SELECT DISTINCT + + col0 DIV cor0.col2 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2874
SELECT DISTINCT + + col0 / cor0.col2 FROM tab1 cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2875
SELECT + col1 + + 17 DIV 2 AS col2 FROM tab0 cor0
----
105
94
99

skipif mysql # not compatible
query I rowsort label-2875
SELECT + col1 + + 17 / 2 AS col2 FROM tab0 cor0
----
105
94
99

query I rowsort
SELECT ALL + col2 * + col1 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col1 + - cor0.col0 * + ( - col2 ) * - col2 AS col2 FROM tab1 AS cor0
----
-207926
-737267
-8722

query I rowsort
SELECT DISTINCT col1 * 10 * - ( - col1 ) FROM tab1 cor0
----
1000
1690
6760

query I rowsort
SELECT DISTINCT + - col1 + - col1 * col2 AS col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL col1 + col0 * + col0 + col0 AS col1 FROM tab0 cor0
----
1357
686
8101

query I rowsort
SELECT ALL - col1 * col0 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT - + col1 + - col0 * - 60 FROM tab2 AS cor0
----
389
4621
4723

onlyif mysql # use DIV operator for integer division
query I rowsort label-2883
SELECT - 49 DIV tab2.col1 AS col2 FROM tab2
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-2883
SELECT - 49 / tab2.col1 AS col2 FROM tab2
----
-1
-2
0

query I rowsort
SELECT DISTINCT + col0 * + ( + col0 ) + - cor0.col2 AS col1 FROM tab2 cor0
----
22
6058
6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 57 col0 FROM tab1 cor0
----
171
3648
4560

query I rowsort
SELECT ALL + - cor0.col1 + + col2 * col1 AS col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT - col2 + col1 + - col2 FROM tab0 AS cor0
----
-73
20
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2888
SELECT DISTINCT + col0 + + CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2888
SELECT DISTINCT + col0 + + CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT - col1 * 23 + - col2 FROM tab0 cor0
----
-2011
-2175
-2232

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 * col0 * col2 col0 FROM tab0 AS cor0
----
1260
19032
649611

query I rowsort
SELECT DISTINCT col2 + ( + col1 * col1 + 65 ) FROM tab0
----
7494
8428
9475

query I rowsort
SELECT - 50 - + 99 * tab0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 46a46b82d50bb29fc350617b9d4ec79c

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab1, tab2 cor1, tab0 cor2
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

query I rowsort
SELECT col1 * ( - col0 ) AS col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - tab2.col0 * + ( col1 ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + 24 * col0 + tab2.col0 AS col2 FROM tab2
----
175
1950
1975

query I rowsort
SELECT - col2 * - col0 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - ( + 87 ) FROM tab0
----
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2899
SELECT CAST( 85 * tab2.col0 AS SIGNED ) AS col0 FROM tab2
----
595
6630
6715

skipif mysql # not compatible
query I rowsort label-2899
SELECT CAST ( 85 * tab2.col0 AS INTEGER ) AS col0 FROM tab2
----
595
6630
6715

query I rowsort
SELECT ( + 36 ) * - col0 FROM tab0
----
-1260
-3204
-864

query I rowsort
SELECT - 84 AS col1 FROM tab1
----
-84
-84
-84

query I rowsort
SELECT - ( + col2 ) * col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT - 35 + - col2 * col0 AS col2 FROM tab1 AS cor0
----
-197
-3683
-7715

query I rowsort
SELECT - cor0.col1 + col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 49 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT DISTINCT 51 FROM tab1, tab2 cor0
----
51

query I rowsort
SELECT col1 * ( 40 ) * col0 AS col2 FROM tab0
----
135800
323960
82560

query I rowsort
SELECT ALL col1 * col0 * - col2 + + col0 FROM tab2
----
-119574
-50955
-5852

query I rowsort
SELECT - col2 * - cor0.col2 - + col1 AS col1 FROM tab0 AS cor0
----
-96
1003
6633

onlyif mysql # use DIV operator for integer division
query I rowsort label-2910
SELECT - - cor0.col0 DIV ( col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2910
SELECT - - cor0.col0 / ( col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col2 * 70 AS col1 FROM tab2 AS cor0
----
-1820
-1890
-2660

query I rowsort
SELECT ALL + col2 * + tab2.col0 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT 73 - + cor0.col1 AS col1 FROM tab0 AS cor0
----
-13
-18
-24

query I rowsort
SELECT - - 63 * - col0 FROM tab2 AS cor0
----
-441
-4914
-4977

query I rowsort
SELECT + + col2 + + col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT + col2 * - 81 + + col0 * col0 FROM tab1
----
-1376
-4365
-521

query I rowsort
SELECT col2 + col2 * col2 + + col2 FROM tab1
----
3024
3363
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-2918
SELECT - col0 + - col1 - col2 * col1 DIV col1 FROM tab0 cor0
----
-133
-143
-262

skipif mysql # not compatible
query I rowsort label-2918
SELECT - col0 + - col1 - col2 * col1 / col1 FROM tab0 cor0
----
-133
-143
-262

onlyif mysql # use DIV operator for integer division
query I rowsort label-2919
SELECT + col0 + col2 DIV - col0 + - col0 * col0 FROM tab1
----
-24
-4032
-6321

skipif mysql # not compatible
query I rowsort label-2919
SELECT + col0 + col2 / - col0 + - col0 * col0 FROM tab1
----
-24
-4032
-6321

query I rowsort
SELECT DISTINCT col0 - tab0.col1 * col1 FROM tab0
----
-7372
-8192
-9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + - cor0.col1 col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - col1 * col1 * col0 + + col1 FROM tab1 AS cor0
----
-13507
-2002
-6390

query I rowsort
SELECT DISTINCT col1 * col0 + - col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT col1 * col0 + - col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT + + col0 + + col0 - cor0.col1 * + col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-228
-40832
-83040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * - cor0.col0 col1 FROM tab2 cor0
----
-49
-6084
-6241

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT ( + col0 + - col0 * - col2 ) IN ( - col2 + col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col0 + col2 BETWEEN + col2 + - col2 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2929
SELECT ALL tab0.col2 DIV - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2929
SELECT ALL tab0.col2 / - col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + cor0.col1 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT cor0.col2 * + col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL + col0 FROM tab1 WHERE + col1 >= NULL
----

query I rowsort
SELECT + + col0 * + col2 + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + cor0.col2 + cor0.col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT - col1 * + col2 - - col1 FROM tab1 cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-2936
SELECT DISTINCT - - col2 + col2 + col1 DIV - col1 AS col1 FROM tab2 AS cor0
----
51
53
75

skipif mysql # not compatible
query I rowsort label-2936
SELECT DISTINCT - - col2 + col2 + col1 / - col1 AS col1 FROM tab2 AS cor0
----
51
53
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-2937
SELECT ALL col2 * - col1 + col2 DIV - cor0.col0 + col2 FROM tab1 AS cor0
----
-1153
-1368
-513

skipif mysql # not compatible
query I rowsort label-2937
SELECT ALL col2 * - col1 + col2 / - cor0.col0 + col2 FROM tab1 AS cor0
----
-1153
-1368
-513

query I rowsort
SELECT tab0.col2 * col1 + col1 AS col2 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ALL - col2 * - col0 * - col0 FROM tab1
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col2 col0 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT + + col0 * + 49 AS col0 FROM tab0 AS cor0
----
1176
1715
4361

query I rowsort
SELECT DISTINCT - + col0 * col0 AS col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL col2 * + col1 AS col2 FROM tab0 cor0
----
2838
7462
97

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 cor1, tab1 AS cor2
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

query I rowsort
SELECT col1 + 91 + - col1 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT ALL - - col0 * cor0.col2 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT col0 * col1 + - 27 + col1 FROM tab2 AS cor0
----
1333
221
4634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + 39 + + ( col2 ) * - col0 col2 FROM tab1 AS cor0
----
-1152
-45
-4560

onlyif mysql # use DIV operator for integer division
query I rowsort label-2949
SELECT DISTINCT + cor0.col2 DIV ( - col2 ) AS col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2949
SELECT DISTINCT + cor0.col2 / ( - col2 ) AS col1 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL + col1 + - cor0.col0 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-2951
SELECT DISTINCT - cor0.col2 * col1 + + cor0.col0 * + col1 DIV + col1 AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

skipif mysql # not compatible
query I rowsort label-2951
SELECT DISTINCT - cor0.col2 * col1 + + cor0.col0 * + col1 / + col1 AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - col0 + - col0 + - col2 AS col1 FROM tab1 AS cor0
----
-185
-256
-60

query I rowsort
SELECT DISTINCT + col1 * - 34 FROM tab0 AS cor0
----
-2924
-3094
-3298

query I rowsort
SELECT ALL - 17 * + cor0.col1 FROM tab0 AS cor0
----
-1462
-1547
-1649

query I rowsort
SELECT - - 40 AS col0 FROM tab0 AS cor0
----
40
40
40

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2, tab0 AS cor3
----
3645 values hashing to a02dd7564e9916176c021434a3977a05

query I rowsort
SELECT + 57 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

onlyif mysql # use DIV operator for integer division
query I rowsort label-2958
SELECT + cor0.col0 * + col2 - 39 DIV + cor0.col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-2958
SELECT + cor0.col0 * + col2 - 39 / + cor0.col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - cor0.col0 + - col2 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT ALL + 7 FROM tab1 AS cor0
----
7
7
7

query I rowsort
SELECT ALL + 49 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT 65 * col1 FROM tab0 AS cor0
----
5590
5915
6305

query I rowsort
SELECT + col1 - + ( + col0 ) AS col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL + 68 + tab2.col1 * ( ( - col2 ) ) FROM tab2
----
-1466
-578
-769

query I rowsort
SELECT ALL + col0 * col1 + ( tab0.col1 + - col0 * - col1 ) FROM tab0
----
16289
4214
6887

query I rowsort
SELECT - col0 + ( + ( - col2 ) ) + col0 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT col0 * - col1 + 45 * + 66 FROM tab0
----
-425
-5129
906

query I rowsort
SELECT ALL + - 25 AS col0 FROM tab2 cor0
----
-25
-25
-25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) * ( col0 ) + + col1 col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL 90 AS col2 FROM tab1 AS cor0
----
90
90
90

query I rowsort
SELECT + + col2 * + cor0.col1 + + ( + col1 * col1 ) AS col2 FROM tab0 AS cor0
----
10234
15743
9506

query I rowsort
SELECT DISTINCT + ( - col0 ) + - ( 76 ) FROM tab1 AS cor0
----
-140
-156
-79

query I rowsort
SELECT ALL - 24 + - col1 FROM tab1
----
-34
-37
-50

query I rowsort
SELECT cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL col1 + - ( + cor0.col1 * col0 ) + ( + col1 ) * - col1 AS col0 FROM tab1 AS cor0
----
-1196
-728
-730

query I rowsort
SELECT + + cor0.col0 * col2 + - col1 AS col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL + - col2 + + cor0.col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - ( + tab2.col2 ) FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL col2 * - 57 AS col1 FROM tab0
----
-1881
-4674
-57

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab2, tab0 cor0, tab0 cor1
----
-1
-33
-82

query I rowsort
SELECT + cor1.col1 * - cor1.col0 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a95320dbb4fb4aa98e2920d866f19abe

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 7 col1 FROM tab0 AS cor0
----
7
7
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 15 * col0 + col1 col2 FROM tab0 cor0
----
-1244
-274
-428

query I rowsort
SELECT ALL - - 50 + - col2 AS col0 FROM tab0 AS cor0
----
-32
17
49

query I rowsort
SELECT cor0.col2 + col0 + - 19 * col2 AS col1 FROM tab1 cor0
----
-1648
-962
-969

onlyif mysql # use DIV operator for integer division
query I rowsort label-2986
SELECT ALL - + cor0.col1 DIV col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-2986
SELECT ALL - + cor0.col1 / col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT col0 * + col0 + col1 + + col0 * - col2 FROM tab0 AS cor0
----
-130
1287
714

query I rowsort
SELECT ALL - ( + col0 ) * cor0.col0 AS col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT col0 * - col0 + + 90 * - 55 * + cor0.col0 FROM tab1 cor0
----
-14859
-320896
-402400

query I rowsort
SELECT + 74 + cor0.col2 FROM tab0 AS cor0
----
107
156
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-2991
SELECT + + col1 DIV - col0 + + ( col0 + - col1 ) FROM tab2 AS cor0
----
-28
19
62

skipif mysql # not compatible
query I rowsort label-2991
SELECT + + col1 / - col0 + + ( col0 + - col1 ) FROM tab2 AS cor0
----
-28
19
62

query I rowsort
SELECT col2 * + 77 + - col2 AS col1 FROM tab2 AS cor0
----
1976
2052
2888

query I rowsort
SELECT 66 + col0 + col0 AS col2 FROM tab0
----
114
136
244

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2994
SELECT ALL 35 + col2 * - col1 - + CAST( NULL AS SIGNED ) * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2994
SELECT ALL 35 + col2 * - col1 - + CAST ( NULL AS INTEGER ) * col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 36 * - 52 - - col1 * ( 26 ) FROM tab2 AS cor0
----
-1066
-1430
-338

query I rowsort
SELECT ALL + - ( cor0.col1 ) + + col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + + col0 * col1 + cor0.col0 * + col1 FROM tab1 cor0
----
1280
156
2080

query I rowsort
SELECT 84 * - col2 AS col0 FROM tab2 AS cor0
----
-2184
-2268
-3192

query I rowsort
SELECT - col1 + col0 - col2 AS col2 FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT ALL - 4 + - col1 AS col0 FROM tab2 cor0
----
-21
-35
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-3001
SELECT + + 55 + - col0 * 29 DIV + 64 FROM tab0 AS cor0
----
15
40
45

skipif mysql # not compatible
query I rowsort label-3001
SELECT + + 55 + - col0 * 29 / + 64 FROM tab0 AS cor0
----
15
40
45

query I rowsort
SELECT + col2 * + col0 * + ( col0 + + col0 ) FROM tab0 AS cor0
----
1299044
2450
38016

query I rowsort
SELECT DISTINCT + 2 + - col1 * - col0 AS col1 FROM tab1 AS cor0
----
1042
642
80

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col1 * 38 AS col2 FROM tab0 AS cor0
----
-107844
-283556
-3686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3005
SELECT + CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3005
SELECT + CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * 58 FROM tab2
----
1798
3422
986

query I rowsort
SELECT DISTINCT 27 - 83 AS col1 FROM tab1
----
-56

query I rowsort
SELECT DISTINCT 12 * + 10 AS col0 FROM tab1
----
120

onlyif mysql # use DIV operator for integer division
query I rowsort label-3009
SELECT col0 DIV + ( - col1 * + 65 ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3009
SELECT col0 / + ( - col1 * + 65 ) FROM tab2
----
0
0
0

query I rowsort
SELECT + 27 * - col0 AS col2 FROM tab0
----
-2403
-648
-945

query I rowsort
SELECT - col0 * + 35 AS col0 FROM tab1 AS cor0
----
-105
-2240
-2800

query I rowsort
SELECT + - col1 * + 46 FROM tab1 AS cor0
----
-1196
-460
-598

query I rowsort
SELECT + col2 * + 67 AS col0 FROM tab1
----
3618
3819
6432

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3014
SELECT ALL + tab2.col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3014
SELECT ALL + tab2.col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col0 - + col1 * col1 AS col2 FROM tab1 AS cor0
----
-164
-249
-679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( + cor0.col2 ) * + col1 col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + cor0.col1 col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT col2 * - col1 + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + + col0 - col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL + - 77 + col0 - col1 FROM tab0 cor0
----
-139
-139
-79

query I rowsort
SELECT ALL - col2 * ( col2 * tab0.col2 ) AS col1 FROM tab0
----
-1
-35937
-551368

query I rowsort
SELECT - col1 * - tab0.col2 + - 56 FROM tab0
----
2782
41
7406

onlyif mysql # use DIV operator for integer division
query I rowsort label-3024
SELECT tab1.col0 DIV col0 + tab1.col1 DIV - tab1.col0 FROM tab1
----
-7
1
1

skipif mysql # not compatible
query I rowsort label-3024
SELECT tab1.col0 / col0 + tab1.col1 / - tab1.col0 FROM tab1
----
-7
1
1

query I rowsort
SELECT ALL cor0.col2 + - col1 * col0 * 54 FROM tab0 AS cor0
----
-111423
-183329
-437264

query I rowsort
SELECT cor0.col1 * + col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT col2 + cor0.col0 * cor0.col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT - col2 + + 44 FROM tab1 AS cor0
----
-10
-13
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3029
SELECT DISTINCT CAST( col0 AS SIGNED ) + col1 DIV + 55 AS col1 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-3029
SELECT DISTINCT CAST ( col0 AS INTEGER ) + col1 / + 55 AS col1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT - - 71 AS col0 FROM tab1 cor0
----
71
71
71

query I rowsort
SELECT + 76 - + 79 AS col1 FROM tab0 AS cor0
----
-3
-3
-3

query I rowsort
SELECT DISTINCT + 23 * - cor0.col0 FROM tab2 AS cor0
----
-161
-1794
-1817

query I rowsort
SELECT 53 * + col2 FROM tab1 AS cor0
----
2862
3021
5088

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3034
SELECT ALL + CAST( NULL AS SIGNED ) * + col2 * col2 + col2 * + col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3034
SELECT ALL + CAST ( NULL AS INTEGER ) * + col2 * col2 + col2 * + col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 + + 66 * col2 * + col1 FROM tab1 AS cor0
----
37684
82448
92667

query I rowsort
SELECT DISTINCT ( - col2 ) + - col0 * - 72 AS col2 FROM tab1 AS cor0
----
162
4551
5664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 col0 FROM tab2, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT - 24 * col1 * - 58 FROM tab2
----
23664
43152
82128

query I rowsort
SELECT - 16 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 71c8b08964ab47ce12158975c0ee1fd9

query I rowsort
SELECT - 20 + - col1 + + col2 FROM tab1 AS cor0
----
27
63
8

query I rowsort
SELECT 24 + col2 FROM tab1 cor0
----
120
78
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3042
SELECT + col2 DIV + col2 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3042
SELECT + col2 / + col2 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT - - 32 + col0 AS col2 FROM tab1 cor0
----
112
35
96

query I rowsort
SELECT - cor0.col2 * 24 AS col1 FROM tab0 cor0
----
-1968
-24
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + ( + col1 ) * - col1 + col0 - + cor0.col1 col0 FROM tab2 AS cor0
----
-205360
-29815
-4851

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3046
SELECT col2 + - CAST( + 88 AS SIGNED ) * col1 AS col0 FROM tab0 AS cor0
----
-7535
-7926
-8535

skipif mysql # not compatible
query I rowsort label-3046
SELECT col2 + - CAST ( + 88 AS INTEGER ) * col1 AS col0 FROM tab0 AS cor0
----
-7535
-7926
-8535

query I rowsort
SELECT ALL - col1 + 9 AS col0 FROM tab0 cor0
----
-77
-82
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - cor0.col2 - col2 col0 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3049
SELECT col0 + 85 DIV - col1 AS col2 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3049
SELECT col0 + 85 / - col1 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT cor1.col1 AS col2 FROM tab2 cor0 CROSS JOIN tab2 cor1
----
17
31
59

query I rowsort
SELECT - - cor1.col0 + 59 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7da17431b64d1a1072cd32279f5a6d6c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + ( col0 ) col1 FROM tab1 cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3053
SELECT ALL - + CAST( col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3053
SELECT ALL - + CAST ( col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3054
SELECT DISTINCT + - col1 * col2 DIV - col0 FROM tab2 AS cor0
----
119
19
8

skipif mysql # not compatible
query I rowsort label-3054
SELECT DISTINCT + - col1 * col2 / - col0 FROM tab2 AS cor0
----
119
19
8

query I rowsort
SELECT ( col0 ) + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + cor0.col0 + + cor0.col0 * cor0.col1 * - col0 AS col2 FROM tab2 AS cor0
----
-106018
-1512
-358878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3057
SELECT ALL + CAST( + 99 AS SIGNED ) DIV cor0.col1 col1 FROM tab0 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3057
SELECT ALL + CAST ( + 99 AS INTEGER ) / cor0.col1 col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT - 29 * col1 * col2 + ( + col2 ) FROM tab2 AS cor0
----
-18696
-24246
-44460

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3059
SELECT DISTINCT cor0.col2 + col0 * CAST( col2 * col1 AS SIGNED ) FROM tab0 AS cor0
----
3396
664200
68145

skipif mysql # not compatible
query I rowsort label-3059
SELECT DISTINCT cor0.col2 + col0 * CAST ( col2 * col1 AS INTEGER ) FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT ALL col0 + col2 + - 69 AS col0 FROM tab0 cor0
----
-12
-33
102

query I rowsort
SELECT 87 * - col1 + col1 FROM tab0 AS cor0
----
-7396
-7826
-8342

query I rowsort
SELECT + 54 + - col2 AS col1 FROM tab2 AS cor0
----
16
27
28

query I rowsort
SELECT col0 + - 73 + col0 FROM tab2
----
-59
83
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3064
SELECT + col1 DIV ( 37 * col0 + 92 ) AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3064
SELECT + col1 / ( 37 * col0 + 92 ) AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 + CAST ( ( col2 ) AS INTEGER ) * + CAST ( - col1 AS REAL ) FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT - col1 * - ( tab2.col2 ) * tab2.col1 + 87 + - col0 FROM tab2
----
10990
26027
90515

onlyif mysql # use DIV operator for integer division
query I rowsort label-3067
SELECT ALL col2 DIV col1 + col2 col2 FROM tab2
----
26
27
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3067
SELECT ALL col2 / col1 + col2 col2 FROM tab2
----
26
27
40

query I rowsort
SELECT DISTINCT + col0 * + col0 * + col0 AS col2 FROM tab0 AS cor0
----
13824
42875
704969

query I rowsort
SELECT ALL + + col2 * - ( col0 ) + col1 + col0 AS col1 FROM tab1 AS cor0
----
-133
-3574
-7587

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab0 cor1, tab2 cor2
----
972 values hashing to 6dfb18fb846f922ba9ea60ce42b86fb0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3071
SELECT DISTINCT - + cor0.col1 + col0 DIV cor0.col0 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-3071
SELECT DISTINCT - + cor0.col1 + col0 / cor0.col0 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3072
SELECT ALL + col2 DIV col1 + - col2 FROM tab1 AS cor0
----
-52
-52
-89

skipif mysql # not compatible
query I rowsort label-3072
SELECT ALL + col2 / col1 + - col2 FROM tab1 AS cor0
----
-52
-52
-89

query I rowsort
SELECT + 47 + 62 FROM tab1, tab2 AS cor0
----
9 values hashing to 75d8c4a7dcf2a4283954a2a59f1d80d6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3074
SELECT DISTINCT + col0 * col1 DIV col2 AS col0 FROM tab1 AS cor0
----
1
10
11

skipif mysql # not compatible
query I rowsort label-3074
SELECT DISTINCT + col0 * col1 / col2 AS col0 FROM tab1 AS cor0
----
1
10
11

query I rowsort
SELECT - col2 + - ( col1 + cor0.col2 ) AS col2 FROM tab2 AS cor0
----
-111
-85
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3076
SELECT 30 DIV + ( col0 * - 20 ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3076
SELECT 30 / + ( col0 * - 20 ) FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3077
SELECT - ( col2 ) + col2 DIV + col0 FROM tab2 AS cor0
----
-24
-26
-38

skipif mysql # not compatible
query I rowsort label-3077
SELECT - ( col2 ) + col2 / + col0 FROM tab2 AS cor0
----
-24
-26
-38

query I rowsort
SELECT ALL 97 AS col0 FROM tab0 AS cor0
----
97
97
97

query I rowsort
SELECT ( - col2 ) * - cor0.col0 + + 3 * + 19 * col0 - - col2 AS col2 FROM tab1 AS cor0
----
12336
387
7353

query I rowsort
SELECT ALL col2 * cor0.col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col2 - tab2.col2 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT col2 * - col0 + + 75 * col1 + + col2 * + col2 FROM tab1
----
2511
351
4704

query I rowsort
SELECT DISTINCT col1 - col1 * - col0 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT tab2.col0 - 28 FROM tab2
----
-21
50
51

query I rowsort
SELECT DISTINCT - tab1.col0 * - col1 + col2 - col1 * - 52 AS col1 FROM tab1
----
1217
1484
1812

query I rowsort
SELECT + 82 - 4 FROM tab1, tab2 cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query I rowsort
SELECT - col0 + - 11 FROM tab2
----
-18
-89
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3088
SELECT + + ( + cor0.col2 ) DIV col0 FROM tab2 cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-3088
SELECT + + ( + cor0.col2 ) / col0 FROM tab2 cor0
----
0
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3089
SELECT ALL - + col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3089
SELECT ALL - + col0 / + col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + - ( - col0 ) + + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - - ( + col1 ) + - col0 AS col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT + ( ( + col0 ) ) - + col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 11 * - ( cor0.col2 ) - + col0 * ( cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-1267
-2096
-672

query I rowsort
SELECT ( + 5 ) FROM tab2 cor0
----
5
5
5

query I rowsort
SELECT + - col1 * - col1 + - col0 AS col2 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT cor0.col1 * 53 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 37456969eb11021f866aeaf03e248be1

query I rowsort
SELECT cor1.col1 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - 3 + col2 * col1 + - tab0.col1 FROM tab0
----
-3
2749
7368

query I rowsort
SELECT - col1 + - col1 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT ( tab1.col0 * + col1 ) + - 89 * + col0 + + col0 FROM tab1
----
-186
-4992
-6000

query I rowsort
SELECT tab1.col0 * + ( + col1 ) + + ( 60 ) FROM tab1
----
1100
138
700

query I rowsort
SELECT DISTINCT + + cor0.col0 * + cor0.col1 + cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - ( + col2 ) * col1 + - col2 AS col0 FROM tab0 cor0
----
-2871
-7544
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 44 col2 FROM tab0
----
44
44
44

query I rowsort
SELECT + 24 * + 12 AS col0 FROM tab1
----
288
288
288

query I rowsort
SELECT ALL ( col1 ) * ( ( - tab0.col2 ) * + 24 ) AS col1 FROM tab0
----
-179088
-2328
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3107
SELECT cor0.col0 DIV 49 + + 28 FROM tab2, tab0 AS cor0
----
9 values hashing to 91315c3d5e9b12b9f188ffe0a05ba8e8

skipif mysql # not compatible
query I rowsort label-3107
SELECT cor0.col0 / 49 + + 28 FROM tab2, tab0 AS cor0
----
9 values hashing to 91315c3d5e9b12b9f188ffe0a05ba8e8

query I rowsort
SELECT DISTINCT col2 * tab1.col2 AS col0 FROM tab1
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - tab2.col0 * - col1 + 72 ) col0 FROM tab2
----
-1415
-289
-4674

onlyif mysql # use DIV operator for integer division
query I rowsort label-3110
SELECT col0 + tab2.col2 * col0 DIV col0 AS col2 FROM tab2
----
104
117
34

skipif mysql # not compatible
query I rowsort label-3110
SELECT col0 + tab2.col2 * col0 / col0 AS col2 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT ( + tab2.col1 ) AS col0 FROM tab2, tab1 cor0, tab0 cor1
----
17
31
59

query I rowsort
SELECT DISTINCT + 15 AS col1 FROM tab0, tab0 AS cor0
----
15

query I rowsort
SELECT col1 + + ( - col2 ) AS col1 FROM tab0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 21 col0 FROM tab1 AS cor0
----
117
75
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3115
SELECT DISTINCT col0 * CAST( NULL AS SIGNED ) + 67 + cor0.col1 col1 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3115
SELECT DISTINCT col0 * CAST ( NULL AS INTEGER ) + 67 + cor0.col1 col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT - col2 * col0 + 57 FROM tab1 AS cor0
----
-105
-3591
-7623

query I rowsort
SELECT ALL cor0.col0 * 24 - cor0.col1 AS col2 FROM tab1 AS cor0
----
1526
1907
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3118
SELECT col2 + + CAST( - col2 AS SIGNED ) FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3118
SELECT col2 + + CAST ( - col2 AS INTEGER ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 + ( ( col2 ) ) AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + col1 + ( col0 ) * col1 + - col2 * col0 FROM tab1 cor0
----
-2998
-58
-6627

query I rowsort
SELECT + + cor0.col1 * - ( 80 ) AS col0 FROM tab1 AS cor0
----
-1040
-2080
-800

query I rowsort
SELECT DISTINCT 1 * + col1 AS col0 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + col0 * tab1.col0 FROM tab1
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 18 col1 FROM tab1 cor0
----
18
18
18

query I rowsort
SELECT 29 * col1 AS col1 FROM tab2 AS cor0
----
1711
493
899

query I rowsort
SELECT + - 28 * - col1 FROM tab0 AS cor0
----
2408
2548
2716

query I rowsort
SELECT + col1 + ( - cor0.col2 ) + + col0 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT col2 * col1 + 58 * - col0 * + ( cor0.col0 * col2 ) AS col1 FROM tab2 cor0
----
-13754518
-75897
-9173138

query I rowsort
SELECT col0 * 93 - + col1 FROM tab0 AS cor0
----
2146
3158
8186

query I rowsort
SELECT DISTINCT + + col1 + + col0 * col2 AS col1 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-3131
SELECT + col0 * col0 + col2 DIV - col1 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-3131
SELECT + col0 * col0 + col2 / - col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - col2 + - 9 - + 31 * + cor0.col2 FROM tab0 AS cor0
----
-1065
-2633
-41

query I rowsort
SELECT col1 + cor0.col1 + col2 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT ALL + + col0 + - ( - col2 ) - col1 AS col0 FROM tab0 cor0
----
-29
-61
80

query I rowsort
SELECT - col0 + ( - col2 ) FROM tab2 cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3136
SELECT DISTINCT - col0 DIV - col1 FROM tab1 cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-3136
SELECT DISTINCT - col0 / - col1 FROM tab1 cor0
----
0
6

query I rowsort
SELECT ALL + col0 + - col0 AS col2 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3138
SELECT ALL 11 * col1 + - col2 DIV ( + col2 ) FROM tab0
----
1000
1066
945

skipif mysql # not compatible
query I rowsort label-3138
SELECT ALL 11 * col1 + - col2 / ( + col2 ) FROM tab0
----
1000
1066
945

query I rowsort
SELECT - + col2 * 92 AS col0 FROM tab1 AS cor0
----
-4968
-5244
-8832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 78 + - 89 col2 FROM tab1 AS cor0
----
-11

query I rowsort
SELECT ALL - col1 + - ( - cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col0 * col1 col2 FROM tab0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( - col0 ) + - col2 col2 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3144
SELECT - col0 * 67 DIV col2 FROM tab1 AS cor0
----
-3
-55
-75

skipif mysql # not compatible
query I rowsort label-3144
SELECT - col0 * 67 / col2 FROM tab1 AS cor0
----
-3
-55
-75

query I rowsort
SELECT DISTINCT 67 * 34 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
2278

query I rowsort
SELECT DISTINCT - col1 * + col2 - col2 AS col0 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT + col1 * + col1 AS col2 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT ALL cor0.col2 - - col1 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT 27 + - col1 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-25
1
7

query I rowsort
SELECT DISTINCT col1 * + col0 + col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - col0 + col2 * col0 AS col0 FROM tab2 cor0
----
182
1950
2923

query I rowsort
SELECT col2 + cor0.col1 * col1 AS col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL + + 51 FROM tab1 AS cor0
----
51
51
51

query I rowsort
SELECT ALL - - cor0.col1 * col2 + col2 + - col1 FROM tab0 AS cor0
----
1
2785
7453

query I rowsort
SELECT DISTINCT + + 51 - col1 FROM tab0 cor0
----
-35
-40
-46

query I rowsort
SELECT + - col2 * col0 + 55 AS col0 FROM tab2 AS cor0
----
-134
-1973
-2947

query I rowsort
SELECT + col0 * - col2 + col2 AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL - - col1 * + cor0.col0 * col0 + - col1 FROM tab0 AS cor0
----
118728
49450
720720

query I rowsort
SELECT DISTINCT + 64 AS col2 FROM tab0
----
64

query I rowsort
SELECT 63 * - col1 AS col1 FROM tab1
----
-1638
-630
-819

query I rowsort
SELECT col1 + + col1 * + 44 AS col2 FROM tab2
----
1395
2655
765

query I rowsort
SELECT ALL - - 93 + 53 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 708ab89da52f5539ae8cc2b28295d0f9

query I rowsort
SELECT + ( + col1 ) + + col1 * col1 FROM tab0 AS cor0
----
7482
8372
9506

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 cor2
----
972 values hashing to e486ce227b61d9db6f8414f9d6361094

query I rowsort
SELECT ALL + col1 * + 18 FROM tab1 AS cor0
----
180
234
468

query I rowsort
SELECT - col0 + + 8 AS col1 FROM tab0 AS cor0
----
-16
-27
-81

query I rowsort
SELECT col2 + + ( col2 ) - col2 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL tab1.col2 * - col2 + + tab1.col2 AS col2 FROM tab1
----
-2862
-3192
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 61 + col0 col2 FROM tab0 AS cor0
----
150
85
96

query I rowsort
SELECT + col2 * 44 AS col0 FROM tab1 AS cor0
----
2376
2508
4224

query I rowsort
SELECT DISTINCT col2 * - 32 AS col1 FROM tab0 AS cor0
----
-1056
-2624
-32

query I rowsort
SELECT ALL - col0 + col0 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - col2 * col0 + col1 - col0 FROM tab1
----
-139
-3702
-7747

query I rowsort
SELECT col0 * + col2 * + col1 AS col1 FROM tab0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3175
SELECT ALL col2 * col2 + + col1 + - tab1.col2 DIV + col1 FROM tab1
----
2940
3254
9222

skipif mysql # not compatible
query I rowsort label-3175
SELECT ALL col2 * col2 + + col1 + - tab1.col2 / + col1 FROM tab1
----
2940
3254
9222

query I rowsort
SELECT - tab1.col0 * - col2 + tab1.col2 * tab1.col0 + col2 AS col1 FROM tab1
----
15456
378
7353

onlyif mysql # use DIV operator for integer division
query I rowsort label-3177
SELECT DISTINCT col2 * + tab2.col1 + - col2 DIV - col0 + + tab2.col1 FROM tab2
----
1593
663
871

skipif mysql # not compatible
query I rowsort label-3177
SELECT DISTINCT col2 * + tab2.col1 + - col2 / - col0 + + tab2.col1 FROM tab2
----
1593
663
871

query I rowsort
SELECT ALL - col1 * col1 + - tab1.col1 FROM tab1
----
-110
-182
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-3179
SELECT DISTINCT - tab2.col2 * + col0 DIV col0 AS col1 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-3179
SELECT DISTINCT - tab2.col2 * + col0 / col0 AS col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL + tab0.col2 * + col2 + - col1 FROM tab0
----
-96
1003
6633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 + tab0.col1 * + tab0.col0 col1 FROM tab0
----
1488
178
2170

onlyif mysql # use DIV operator for integer division
query I rowsort label-3182
SELECT col2 DIV - col0 + - col1 FROM tab2
----
-17
-34
-59

skipif mysql # not compatible
query I rowsort label-3182
SELECT col2 / - col0 + - col1 FROM tab2
----
-17
-34
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3183
SELECT DISTINCT - tab1.col1 + - col2 DIV - col1 + col1 AS col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-3183
SELECT DISTINCT - tab1.col1 + - col2 / - col1 + col1 AS col1 FROM tab1
----
2
5
7

query I rowsort
SELECT col1 AS col2 FROM tab0 WHERE NOT ( - col2 * - col2 + col0 - + col1 ) > NULL
----

query I rowsort
SELECT + col0 * + col0 * tab1.col0 AS col0 FROM tab1
----
262144
27
512000

query III rowsort
SELECT * FROM tab2 WHERE NOT col1 NOT IN ( - col2 * tab2.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3187
SELECT ALL col0 DIV - tab1.col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3187
SELECT ALL col0 / - tab1.col0 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col2 + + col0 col2 FROM tab2
----
182
196
41

query I rowsort
SELECT col1 * + col0 + col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT + tab1.col2 - - tab1.col0 FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT - col2 * col0 - - col2 AS col0 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT - col1 - col2 AS col1 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT + tab2.col1 * col1 * col0 + col0 AS col2 FROM tab2
----
22910
271596
6734

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL NOT BETWEEN + col0 + - col1 AND NULL
----

query I rowsort
SELECT ALL tab2.col1 / + col0 - tab2.col0 FROM tab2 WHERE NULL < NULL
----

query III rowsort
SELECT * FROM tab2 WHERE NOT col2 / - col0 NOT IN ( col1 * col2 )
----

query I rowsort
SELECT DISTINCT col1 - col2 * col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT - col1 + col1 * + col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT col0 + - col0 * + cor0.col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT cor0.col2 * - cor0.col0 + col1 * + col1 FROM tab2 AS cor0
----
-2713
1453
772

query I rowsort
SELECT DISTINCT + + col0 * cor0.col1 + col2 * col2 FROM tab1 AS cor0
----
10256
2994
3889

query I rowsort
SELECT col0 * - col2 * col2 AS col0 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT ALL + col2 * col2 * - col0 + col2 AS col0 FROM tab2 AS cor0
----
-114038
-5076
-52702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 * - col1 col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + col0 - - col1 AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT col0 AS col0 FROM tab2 WHERE NULL <= NULL
----

query I rowsort
SELECT ALL col1 * col0 + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - cor0.col1 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT tab2.col1 FROM tab0 AS cor0 CROSS JOIN tab2
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL - col1 * col0 + col1 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col1 col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + - col0 * col0 * cor0.col2 - col1 FROM tab1 AS cor0
----
-233482
-512
-614413

query I rowsort
SELECT DISTINCT col2 * col1 + - col2 AS col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL - col1 * + col0 + 25 AS col2 FROM tab2 AS cor0
----
-1318
-192
-4577

query I rowsort
SELECT DISTINCT - - cor0.col1 * ( - col2 ) FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3216
SELECT CAST( 54 AS SIGNED ) * - col0 AS col1 FROM tab1 AS cor0
----
-162
-3456
-4320

skipif mysql # not compatible
query I rowsort label-3216
SELECT CAST ( 54 AS INTEGER ) * - col0 AS col1 FROM tab1 AS cor0
----
-162
-3456
-4320

query I rowsort
SELECT + 83 * + 80 + - col1 FROM tab0 AS cor0
----
6543
6549
6554

query I rowsort
SELECT DISTINCT cor0.col1 + - col1 * 34 AS col0 FROM tab0 AS cor0
----
-2838
-3003
-3201

query I rowsort
SELECT - - 29 + + col1 AS col1 FROM tab2 AS cor0
----
46
60
88

query I rowsort
SELECT ALL - tab0.col1 * col1 AS col2 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT col0 * col1 + - col1 AS col0 FROM tab2
----
1326
186
4543

query I rowsort
SELECT ALL 64 * col0 AS col1 FROM tab2
----
448
4992
5056

query I rowsort
SELECT + - col1 * 58 FROM tab0 cor0
----
-4988
-5278
-5626

query I rowsort
SELECT + col0 + col0 * - col2 AS col2 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT - 21 * + col0 AS col0 FROM tab0
----
-1869
-504
-735

query I rowsort
SELECT DISTINCT 64 * col1 FROM tab2
----
1088
1984
3776

query I rowsort
SELECT ALL + col2 * + 53 + col2 FROM tab1 AS cor0
----
2916
3078
5184

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0, tab0 cor1, tab0 AS cor2
----
972 values hashing to 3a31dab513390ca6bd05c71a3d9c50f0

query I rowsort
SELECT ALL ( col2 ) * col0 + - col0 + col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3230
SELECT DISTINCT - col1 * col0 + - col0 DIV + col0 AS col0 FROM tab2 cor0
----
-1344
-218
-4603

skipif mysql # not compatible
query I rowsort label-3230
SELECT DISTINCT - col1 * col0 + - col0 / + col0 AS col0 FROM tab2 cor0
----
-1344
-218
-4603

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col2 col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + - 92 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT 83 + + 51 * col0 AS col2 FROM tab2
----
4061
4112
440

query I rowsort
SELECT ( col1 ) + col0 * + col2 * - col2 AS col1 FROM tab2
----
-114059
-5072
-52669

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3235
SELECT - + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3235
SELECT - + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( - 46 ) AS col0 FROM tab2
----
-46
-46
-46

onlyif mysql # use DIV operator for integer division
query I rowsort label-3237
SELECT col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3237
SELECT col1 / - col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + ( - col0 ) + col0 AS col2 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 29 * + tab2.col0 col2 FROM tab2
----
203
2262
2291

query I rowsort
SELECT DISTINCT + 22 * col2 FROM tab2
----
572
594
836

query I rowsort
SELECT 16 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

onlyif mysql # use DIV operator for integer division
query I rowsort label-3242
SELECT + col1 * col2 * + col2 + - col0 DIV cor0.col0 col2 FROM tab1 AS cor0
----
119807
32489
75815

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3242
SELECT + col1 * col2 * + col2 + - col0 / cor0.col0 col2 FROM tab1 AS cor0
----
119807
32489
75815

query I rowsort
SELECT col1 + - col0 * 86 * + col2 FROM tab2 cor0
----
-16223
-174349
-258155

query I rowsort
SELECT col1 + + cor0.col1 * - col0 FROM tab1 AS cor0
----
-1027
-52
-630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3245
SELECT + col0 * CAST( NULL AS DECIMAL ) / cor0.col0 + - cor0.col0 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3245
SELECT + col0 * CAST ( NULL AS REAL ) / cor0.col0 + - cor0.col0 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * ( - col1 ) FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL 78 AS col0 FROM tab1
----
78
78
78

query I rowsort
SELECT + cor0.col2 * - col1 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + col0 * + col1 + - 21 FROM tab0 AS cor0
----
2043
3374
8078

query I rowsort
SELECT - + col2 * + 27 + - col2 AS col1 FROM tab2 AS cor0
----
-1064
-728
-756

query I rowsort
SELECT ALL + - col2 * 63 FROM tab0 AS cor0
----
-2079
-5166
-63

query I rowsort
SELECT ALL col2 * + col0 + col2 AS col1 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL + tab0.col0 * - col1 + col0 AS col2 FROM tab0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-3254
SELECT DISTINCT + cor0.col1 DIV - col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3254
SELECT DISTINCT + cor0.col1 / - col1 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL - col2 + col1 * + col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT + + col2 + - col0 * + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT cor0.col2 * - col1 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col1 - + cor0.col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + col1 * - cor0.col1 * - col0 FROM tab1 cor0
----
13507
2002
6390

onlyif mysql # use DIV operator for integer division
query I rowsort label-3260
SELECT + + col1 + cor0.col0 DIV col2 FROM tab1 AS cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-3260
SELECT + + col1 + cor0.col0 / col2 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT ALL - col0 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col2 - col1 * + col2 * col2 FROM tab0
----
-611966
-93687
-98

query I rowsort
SELECT ALL col1 * + col2 + - tab1.col0 AS col1 FROM tab1
----
1168
1401
506

query I rowsort
SELECT ALL col2 + - col1 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col2 * col0 + col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT + col0 + col1 * col0 FROM tab1
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - - col2 col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col0 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - + ( - col1 ) + - col2 + col0 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT + ( - col1 ) - + col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - - col0 * cor0.col1 * + cor0.col2 + col1 AS col1 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT col2 * - col0 + col0 AS col2 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + + 8 AS col2 FROM tab2 AS cor0
----
8
8
8

query I rowsort
SELECT DISTINCT - - col1 + + col0 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + col1 + col1 * col0 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + + col2 + col1 * col2 * + col1 - col0 * - col0 AS col0 FROM tab0 AS cor0
----
10635
244677
687045

query I rowsort
SELECT 8 * col0 - col1 AS col0 FROM tab2 AS cor0
----
25
565
615

query I rowsort
SELECT - col2 * - col1 * cor0.col1 FROM tab2 cor0
----
10982
25947
90506

query I rowsort
SELECT ALL - 23 * + col1 FROM tab0 AS cor0
----
-1978
-2093
-2231

query I rowsort
SELECT + + 76 * col0 FROM tab0 cor0
----
1824
2660
6764

query I rowsort
SELECT ALL + 26 * cor0.col2 FROM tab2 AS cor0
----
676
702
988

query I rowsort
SELECT ( - col0 ) + col2 * + col2 AS col0 FROM tab0 cor0
----
-34
1065
6635

query I rowsort
SELECT ALL col0 - - col1 * + col1 * col2 FROM tab2
----
11061
25954
90584

onlyif mysql # use DIV operator for integer division
query I rowsort label-3284
SELECT + col1 DIV - tab2.col0 AS col0 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-3284
SELECT + col1 / - tab2.col0 AS col0 FROM tab2
----
-4
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3285
SELECT DISTINCT tab1.col2 + - col2 DIV + col0 - - col2 AS col2 FROM tab1
----
114
191
90

skipif mysql # not compatible
query I rowsort label-3285
SELECT DISTINCT tab1.col2 + - col2 / + col0 - - col2 AS col2 FROM tab1
----
114
191
90

query I rowsort
SELECT DISTINCT - cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3287
SELECT - col0 * col1 + CAST( col2 AS SIGNED ) col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3287
SELECT - col0 * col1 + CAST ( col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT 57 AS col2 FROM tab2 AS cor0
----
57

query I rowsort
SELECT ALL + + 27 + cor0.col2 FROM tab2 cor0
----
53
54
65

query I rowsort
SELECT + - 84 AS col0 FROM tab2 AS cor0
----
-84
-84
-84

query I rowsort
SELECT DISTINCT cor0.col2 * col1 + + col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3292
SELECT DISTINCT - + col1 + cor0.col2 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3292
SELECT DISTINCT - + col1 + cor0.col2 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + 59 + - col0 * col1 * + 84 AS col1 FROM tab2 AS cor0
----
-112753
-18169
-386509

query I rowsort
SELECT + + ( - col0 ) + col2 AS col1 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT ALL col2 * + col0 - col2 FROM tab2
----
162
2002
2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 + - col2 col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT col2 + + col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT + 98 * - 51 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 379373398d517c15d64a35139cc22c50

query I rowsort
SELECT DISTINCT + tab2.col1 + tab2.col1 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL - cor0.col0 * cor0.col0 + col2 AS col0 FROM tab1 AS cor0
----
-4039
-6304
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-3301
SELECT ALL 84 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
1
1
12

skipif mysql # not compatible
query I rowsort label-3301
SELECT ALL 84 / cor0.col0 AS col2 FROM tab2 AS cor0
----
1
1
12

query I rowsort
SELECT DISTINCT - col1 + 94 AS col1 FROM tab2 AS cor0
----
35
63
77

query I rowsort
SELECT DISTINCT col1 * + ( - col0 ) + col1 AS col2 FROM tab2
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-3304
SELECT + ( col0 ) DIV col1 + - col2 FROM tab2
----
-25
-27
-34

skipif mysql # not compatible
query I rowsort label-3304
SELECT + ( col0 ) / col1 + - col2 FROM tab2
----
-25
-27
-34

query I rowsort
SELECT DISTINCT - ( + 69 ) FROM tab1
----
-69

query I rowsort
SELECT ( 15 ) + col1 AS col1 FROM tab0
----
101
106
112

query I rowsort
SELECT col2 * 25 FROM tab1 cor0
----
1350
1425
2400

query I rowsort
SELECT + + cor0.col2 + + cor0.col2 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-3309
SELECT ALL col2 DIV - ( + col1 ) + cor0.col1 FROM tab2 AS cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-3309
SELECT ALL col2 / - ( + col1 ) + cor0.col1 FROM tab2 AS cor0
----
15
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3310
SELECT ALL + ( col2 ) DIV - col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3310
SELECT ALL + ( col2 ) / - col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + + 74 + - col1 AS col1 FROM tab1 AS cor0
----
48
61
64

query I rowsort
SELECT ALL - 22 FROM tab1, tab1 AS cor0
----
9 values hashing to fae46f8148b02964f7145eb6ed5819f9

query I rowsort
SELECT ALL - 37 * + 11 + col2 FROM tab2 AS cor0
----
-369
-380
-381

query I rowsort
SELECT - 16 FROM tab1, tab0 cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

query I rowsort
SELECT ALL + 25 * + ( + col2 + - col2 ) FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 5 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 74665fbb47d5b17da011bca567195b21

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-1
-33
-82

query I rowsort
SELECT DISTINCT 30 + + col1 FROM tab2 AS cor0
----
47
61
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 40 + col2 * - col1 col1 FROM tab0 AS cor0
----
-137
-2878
-7502

query I rowsort
SELECT ALL - col0 * + cor0.col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3321
SELECT DISTINCT - CAST( NULL AS SIGNED ) / col0 AS col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3321
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / col0 AS col1 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col1 ) + + col2 col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3323
SELECT ALL + cor0.col0 * - col0 + + ( col1 ) * + col2 DIV + cor0.col2 + - col1 * col0 * 74 AS col2 FROM tab1 cor0
----
-51446
-5755
-83347

skipif mysql # not compatible
query I rowsort label-3323
SELECT ALL + cor0.col0 * - col0 + + ( col1 ) * + col2 / + cor0.col2 + - col1 * col0 * 74 AS col2 FROM tab1 cor0
----
-51446
-5755
-83347

query I rowsort
SELECT + col0 * + col1 * - col0 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3325
SELECT tab2.col2 * CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3325
SELECT tab2.col2 * CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + 15 + + cor1.col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
18
79
95

query I rowsort
SELECT ALL + tab2.col1 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - ( - col2 ) * - col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - - 64 + + col1 AS col2 FROM tab1 AS cor0
----
74
77
90

query I rowsort
SELECT DISTINCT + col2 * col0 + 80 * + col0 FROM tab1 AS cor0
----
14080
402
8768

query I rowsort
SELECT + - col0 * - ( 98 * col2 ) + - 97 * - cor0.col0 + col1 AS col2 FROM tab2 AS cor0
----
19232
206369
301876

query I rowsort
SELECT DISTINCT + col1 + 44 * col1 AS col1 FROM tab1
----
1170
450
585

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT col2 * + 83 AS col0 FROM tab0
----
2739
6806
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3335
SELECT ALL tab1.col1 * - CAST( col0 AS SIGNED ) FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3335
SELECT ALL tab1.col1 * - CAST ( col0 AS INTEGER ) FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + col0 * - 8 + 16 FROM tab2 AS cor0
----
-40
-608
-616

onlyif mysql # use DIV operator for integer division
query I rowsort label-3337
SELECT + + cor0.col1 * + ( cor0.col0 ) DIV + cor0.col0 col0 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3337
SELECT + + cor0.col1 * + ( cor0.col0 ) / + cor0.col0 col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + 84 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3339
SELECT + col2 - + CAST( + ( - col1 ) AS SIGNED ) AS col1 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-3339
SELECT + col2 - + CAST ( + ( - col1 ) AS INTEGER ) AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + + col0 + + 80 * col2 AS col0 FROM tab1 cor0
----
4323
4624
7760

query I rowsort
SELECT ALL + col2 * 32 FROM tab2 AS cor0
----
1216
832
864

query I rowsort
SELECT 98 + 48 FROM tab2 AS cor0
----
146
146
146

query I rowsort
SELECT - cor0.col1 + 76 FROM tab0 cor0
----
-10
-15
-21

query I rowsort
SELECT - 57 + 54 FROM tab0 AS cor0
----
-3
-3
-3

query I rowsort
SELECT + - cor0.col1 + 18 * col0 FROM tab2 AS cor0
----
1345
1405
95

query I rowsort
SELECT col0 + - 46 * + col1 FROM tab0 AS cor0
----
-3932
-4097
-4427

query I rowsort
SELECT + col0 * + 71 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT DISTINCT - col2 * 35 AS col2 FROM tab0 AS cor0
----
-1155
-2870
-35

query I rowsort
SELECT - 76 + col0 FROM tab2 AS cor0
----
-69
2
3

query I rowsort
SELECT + + 65 * 3 FROM tab0 cor0
----
195
195
195

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3351
SELECT ALL + col2 + CAST( NULL AS SIGNED ) * 67 * + col2 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3351
SELECT ALL + col2 + CAST ( NULL AS INTEGER ) * 67 * + col2 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * ( 26 ) + - tab1.col1 * 36 AS col0 FROM tab1
----
-100
-130
-260

query I rowsort
SELECT - col0 + - 13 FROM tab0 AS cor0
----
-102
-37
-48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col1 + 25 * col2 * 27 col0 FROM tab1 AS cor0
----
37126
38575
64969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 83 col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT - - 10 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT ALL + 52 AS col2 FROM tab2
----
52
52
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3358
SELECT col0 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3358
SELECT col0 * - CAST ( NULL AS REAL ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + + ( col1 * + col2 ) AS col0 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3360
SELECT col2 - CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3360
SELECT col2 - CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 + - col0 * 6 FROM tab0
----
-120
-175
-445

query I rowsort
SELECT 76 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3363
SELECT ALL + 51 + - 4 DIV col2 FROM tab1
----
51
51
51

skipif mysql # not compatible
query I rowsort label-3363
SELECT ALL + 51 + - 4 / col2 FROM tab1
----
51
51
51

query I rowsort
SELECT ALL 44 - - col2 AS col1 FROM tab0 AS cor0
----
126
45
77

query I rowsort
SELECT ALL + - col2 + + col1 * + col0 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT ALL col0 + - 42 AS col2 FROM tab0
----
-18
-7
47

query I rowsort
SELECT - - 46 + col0 * col1 * + 35 AS col1 FROM tab0 AS cor0
----
118871
283511
72286

onlyif mysql # use DIV operator for integer division
query I rowsort label-3368
SELECT CAST( - col1 AS SIGNED ) DIV tab1.col1 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3368
SELECT CAST ( - col1 AS INTEGER ) / tab1.col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT + - 83 * col2 + cor0.col2 * cor0.col2 FROM tab2 AS cor0
----
-1482
-1512
-1710

query I rowsort
SELECT col1 * - col2 * ( + ( col0 ) ) FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT - col0 * col0 - + col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + + col2 col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT + tab0.col2 * tab0.col0 AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT + 69 + col0 + col1 AS col1 FROM tab1
----
143
162
98

query I rowsort
SELECT + 38 + col0 AS col2 FROM tab1
----
102
118
41

query I rowsort
SELECT DISTINCT + col2 * - tab2.col1 + - col2 * 44 * + col0 FROM tab2
----
-132734
-90766
-9153

query I rowsort
SELECT + 84 + + col2 FROM tab1 AS cor0
----
138
141
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3378
SELECT ALL + + cor0.col0 DIV - col0 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3378
SELECT ALL + + cor0.col0 / - col0 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + + col0 * - 66 col1 FROM tab1 AS cor0
----
-224
-4234
-5293

query I rowsort
SELECT + + col2 * col1 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col0 * ( + col1 ) + col1 AS col0 FROM tab0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-3382
SELECT + col0 DIV - col0 + 83 AS col0 FROM tab1
----
82
82
82

skipif mysql # not compatible
query I rowsort label-3382
SELECT + col0 / - col0 + 83 AS col0 FROM tab1
----
82
82
82

query I rowsort
SELECT + + col2 * - col1 - col2 AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL - - cor0.col1 + - 77 AS col1 FROM tab2 AS cor0
----
-18
-46
-60

query I rowsort
SELECT DISTINCT + + col1 + - col0 * col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + col1 + 89 * 68 AS col1 FROM tab0 AS cor0
----
6138
6143
6149

query I rowsort
SELECT ALL + col2 * 22 + + col1 - - cor0.col2 * + col0 AS col2 FROM tab2 cor0
----
2659
3855
814

query I rowsort
SELECT - + col0 * 22 AS col2 FROM tab1 AS cor0
----
-1408
-1760
-66

query I rowsort
SELECT ALL 88 * 15 AS col1 FROM tab2
----
1320
1320
1320

onlyif mysql # use DIV operator for integer division
query I rowsort label-3390
SELECT + col0 DIV ( + col1 * - col0 + col0 ) AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3390
SELECT + col0 / ( + col1 * - col0 + col0 ) AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3391
SELECT DISTINCT ( ( + cor0.col1 DIV - col1 ) ) * + col1 DIV col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-3391
SELECT DISTINCT ( ( + cor0.col1 / - col1 ) ) * + col1 / col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ALL + 62 * + col0 FROM tab2 AS cor0
----
434
4836
4898

query I rowsort
SELECT + 22 * 39 FROM tab1 cor0
----
858
858
858

query I rowsort
SELECT DISTINCT col2 + + 92 AS col2 FROM tab1 AS cor0
----
146
149
188

query I rowsort
SELECT ALL + col0 * ( + col0 ) AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - cor0.col1 * col2 * - col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT - 56 * col2 FROM tab2 AS cor0
----
-1456
-1512
-2128

query I rowsort
SELECT - + 6 * cor0.col2 FROM tab1 cor0
----
-324
-342
-576

query I rowsort
SELECT ALL col2 * cor0.col2 + cor0.col2 * 30 AS col1 FROM tab1 cor0
----
12096
4536
4959

query I rowsort
SELECT DISTINCT 89 AS col1 FROM tab1, tab2 cor0
----
89

query I rowsort
SELECT ALL - 91 AS col2 FROM tab2
----
-91
-91
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3402
SELECT DISTINCT - CAST( - col1 + col2 AS SIGNED ) FROM tab0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-3402
SELECT DISTINCT - CAST ( - col1 + col2 AS INTEGER ) FROM tab0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 53 col2 FROM tab1
----
159
3392
4240

onlyif mysql # use DIV operator for integer division
query I rowsort label-3404
SELECT col2 + 22 DIV - tab0.col0 col2 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3404
SELECT col2 + 22 / - tab0.col0 col2 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 92 + - col1 col1 FROM tab1
----
1183
2366
910

query I rowsort
SELECT + col1 * - ( - 46 + + cor0.col2 ) AS col1 FROM tab1 cor0
----
-110
-208
-650

query I rowsort
SELECT ALL + col2 + - col1 * + 71 FROM tab1 AS cor0
----
-1792
-653
-827

query I rowsort
SELECT + col0 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3409
SELECT DISTINCT col0 DIV ( 31 ) FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3409
SELECT DISTINCT col0 / ( 31 ) FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT ALL + - col1 * col1 + cor0.col1 FROM tab0 cor0
----
-7310
-8190
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3411
SELECT DISTINCT 95 * - col2 + + col1 DIV - col2 - col0 AS col0 FROM tab1 AS cor0
----
-5133
-5479
-9200

skipif mysql # not compatible
query I rowsort label-3411
SELECT DISTINCT 95 * - col2 + + col1 / - col2 - col0 AS col0 FROM tab1 AS cor0
----
-5133
-5479
-9200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3412
SELECT + + CAST( col0 AS SIGNED ) * col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-3412
SELECT + + CAST ( col0 AS INTEGER ) * col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - col0 + 99 * col2 AS col1 FROM tab1 AS cor0
----
5343
5579
9424

query I rowsort
SELECT ALL - - cor0.col1 + col2 + col1 AS col0 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT + + col0 + col1 * col0 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 3 - - col2 col0 FROM tab1 cor0
----
51
54
93

query I rowsort
SELECT ALL - col0 + - 51 + cor0.col0 FROM tab0 AS cor0
----
-51
-51
-51

query I rowsort
SELECT tab0.col0 + col2 * - col2 * - col2 AS col2 FROM tab0
----
35961
36
551457

query I rowsort
SELECT + 61 FROM tab0 cor0
----
61
61
61

query I rowsort
SELECT ALL 60 + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-2004
-3335
-8039

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3421
SELECT + col0 - - col0 / CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3421
SELECT + col0 - - col0 / CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + + col1 * - ( 95 ) * cor0.col2 FROM tab1 AS cor0
----
-118480
-133377
-54086

onlyif mysql # use DIV operator for integer division
query I rowsort label-3423
SELECT ALL + + cor0.col1 + col2 DIV - col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3423
SELECT ALL + + cor0.col1 + col2 / - col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + col2 + col0 * col0 AS col0 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-3425
SELECT DISTINCT - + cor0.col1 + col0 DIV - ( ( col0 ) ) FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-3425
SELECT DISTINCT - + cor0.col1 + col0 / - ( ( col0 ) ) FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT + + 13 + - col1 FROM tab0 cor0
----
-73
-78
-84

query I rowsort
SELECT - col0 * + col0 * - 91 FROM tab0 AS cor0
----
111475
52416
720811

query I rowsort
SELECT ALL - 62 * + col0 AS col0 FROM tab1 cor0
----
-186
-3968
-4960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + col1 * 97 col0 FROM tab0 AS cor0
----
8366
8916
9444

query I rowsort
SELECT ALL cor0.col1 + - col1 * + col1 AS col0 FROM tab1 cor0
----
-156
-650
-90

query I rowsort
SELECT - col0 - + col0 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT + 97 * - ( + col1 ) + - col2 * - col1 * + col1 AS col2 FROM tab0
----
0
235726
670215

skipif mysql # not compatible
query I rowsort
SELECT ALL col2 * col0 + - CAST ( col0 AS REAL ) AS col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-3434
SELECT - col0 + + col2 DIV 19 AS col0 FROM tab0 AS cor0
----
-23
-35
-85

skipif mysql # not compatible
query I rowsort label-3434
SELECT - col0 + + col2 / 19 AS col0 FROM tab0 AS cor0
----
-23
-35
-85

query I rowsort
SELECT ALL - col1 + + cor0.col2 * + col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ( col2 ) + col1 * + col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT + + 73 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT col0 * - 28 FROM tab2 cor0
----
-196
-2184
-2212

query I rowsort
SELECT - col2 * 53 AS col2 FROM tab1 AS cor0
----
-2862
-3021
-5088

query I rowsort
SELECT DISTINCT - col0 + col0 AS col0 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - cor0.col2 * 85 col0 FROM tab0 AS cor0
----
-2781
-50
-6881

query I rowsort
SELECT col0 + ( - cor0.col0 ) * col1 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-3443
SELECT cor0.col0 DIV 31 AS col0 FROM tab2 AS cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-3443
SELECT cor0.col0 / 31 AS col0 FROM tab2 AS cor0
----
0
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 12 * + 11 col0 FROM tab0 cor0
----
-11748
-3168
-4620

query I rowsort
SELECT cor0.col0 - + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col0 * + col0 + - 8 * col2 * cor0.col2 FROM tab2 cor0
----
-11492
-17793
-5881

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( tab2.col1 ) col0 FROM tab2, tab2 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT - 43 + - cor1.col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 0a484f643105547365b57b5a57de1746

query I rowsort
SELECT + col1 * col0 + 93 * - col2 + ( col1 ) * col0 FROM tab0 cor0
----
1059
6697
8572

query I rowsort
SELECT - cor1.col1 * - 99 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 38ca14fdacf10be67b4f865763130121

query I rowsort
SELECT ( 98 ) FROM tab0, tab2 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

onlyif mysql # use DIV operator for integer division
query I rowsort label-3452
SELECT 51 DIV + tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to da1cd3e60e41d35ecc866bedaeb8c02c

skipif mysql # not compatible
query I rowsort label-3452
SELECT 51 / + tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to da1cd3e60e41d35ecc866bedaeb8c02c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3453
SELECT ALL - CAST( - col2 AS SIGNED ) FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3453
SELECT ALL - CAST ( - col2 AS INTEGER ) FROM tab1
----
54
57
96

query I rowsort
SELECT ALL 60 AS col1 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT 58 + - tab2.col2 FROM tab2
----
20
31
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-3456
SELECT DISTINCT + 99 + cor0.col2 DIV + col1 AS col2 FROM tab2 AS cor0
----
101
99

skipif mysql # not compatible
query I rowsort label-3456
SELECT DISTINCT + 99 + cor0.col2 / + col1 AS col2 FROM tab2 AS cor0
----
101
99

query IIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 2464a6f4cfabe66aeca50fcb4cd85bf5

query I rowsort
SELECT + cor0.col2 + - col2 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * - col0 + + col0 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-3460
SELECT DISTINCT - col1 DIV col0 - + col0 * + col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-86

skipif mysql # not compatible
query I rowsort label-3460
SELECT DISTINCT - col1 / col0 - + col0 * + col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-86

query I rowsort
SELECT cor0.col0 - + col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT col0 * + col1 + ( col1 ) * - col1 - ( col0 ) * col0 FROM tab0 AS cor0
----
-5908
-7239
-8103

onlyif mysql # use DIV operator for integer division
query I rowsort label-3463
SELECT + 77 DIV + col1 - + cor0.col0 FROM tab1 AS cor0
----
-1
-57
-75

skipif mysql # not compatible
query I rowsort label-3463
SELECT + 77 / + col1 - + cor0.col0 FROM tab1 AS cor0
----
-1
-57
-75

query I rowsort
SELECT DISTINCT - tab0.col1 AS col1 FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 AS cor2
----
-86
-91
-97

query I rowsort
SELECT + col1 + 21 * + cor0.col0 * cor0.col0 FROM tab2 AS cor0
----
1060
127823
131078

query I rowsort
SELECT - + col2 + + 27 AS col1 FROM tab1 AS cor0
----
-27
-30
-69

query I rowsort
SELECT ALL + + ( - col0 ) + col2 * - 55 FROM tab2 AS cor0
----
-1492
-1508
-2169

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3468
SELECT DISTINCT - - CAST( col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3468
SELECT DISTINCT - - CAST ( col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3469
SELECT DISTINCT - col2 DIV + 66 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-3469
SELECT DISTINCT - col2 / + 66 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT ALL + - cor0.col1 * - col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT + - 42 + + col2 AS col2 FROM tab0 AS cor0
----
-41
-9
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3472
SELECT + CAST( NULL AS SIGNED ) + - ( col1 * 16 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3472
SELECT + CAST ( NULL AS INTEGER ) + - ( col1 * 16 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 95 AS col2 FROM tab2 AS cor0
----
-95

query I rowsort
SELECT ALL + 15 * cor0.col0 + - 6 FROM tab2 AS cor0
----
1164
1179
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col2 FROM tab2, tab2 cor0 CROSS JOIN tab0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT + col2 * + col0 + col0 AS col0 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT 93 * cor1.col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to f4eeb2d2bf692021f3b80eb37cb53359

query I rowsort
SELECT ALL + ( - 7 ) AS col2 FROM tab2 AS cor0
----
-7
-7
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3479
SELECT + col1 - cor0.col2 * col2 DIV - col1 AS col2 FROM tab0 AS cor0
----
164
97
98

skipif mysql # not compatible
query I rowsort label-3479
SELECT + col1 - cor0.col2 * col2 / - col1 AS col2 FROM tab0 AS cor0
----
164
97
98

query I rowsort
SELECT + col2 + 91 - + col0 FROM tab1 AS cor0
----
107
142
84

query I rowsort
SELECT ALL + 80 AS col2 FROM tab0 AS cor0
----
80
80
80

query I rowsort
SELECT ALL - 82 AS col1 FROM tab1 cor0
----
-82
-82
-82

query I rowsort
SELECT DISTINCT - ( - col1 ) * col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3484
SELECT DISTINCT - col1 * - CAST( + col0 AS SIGNED ) * + col1 AS col2 FROM tab0
----
177504
329315
737009

skipif mysql # not compatible
query I rowsort label-3484
SELECT DISTINCT - col1 * - CAST ( + col0 AS INTEGER ) * + col1 AS col2 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT + col1 - col0 * - tab1.col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT ALL + col1 * + tab1.col2 AS col1 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3487
SELECT DISTINCT - col0 * CAST( - col2 AS SIGNED ) * col1 FROM tab2
----
119652
51034
5859

skipif mysql # not compatible
query I rowsort label-3487
SELECT DISTINCT - col0 * CAST ( - col2 AS INTEGER ) * col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL col1 * + ( cor0.col0 ) * - col1 AS col2 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL + 16 * 30 + - col0 FROM tab2 AS cor0
----
401
402
473

query I rowsort
SELECT DISTINCT - 31 + col1 * + cor0.col0 FROM tab1 AS cor0
----
1009
47
609

query I rowsort
SELECT DISTINCT col1 + + col0 * + col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT tab0.col2 + - col2 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 + - col1 * col2 AS col2 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT 77 + col0 AS col0 FROM tab2
----
155
156
84

query I rowsort
SELECT tab1.col1 + + col2 + - col1 * col0 FROM tab1
----
-573
-931
2

query I rowsort
SELECT ALL - col1 - - ( col0 + tab1.col0 ) FROM tab1
----
-20
118
147

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 76 - ( - col1 + + 92 ) col2 FROM tab0
----
70
75
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col1 - + col0 col0 FROM tab2
----
-24
51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) * - tab2.col0 col0 FROM tab2
----
-1343
-217
-4602

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 - ( col0 ) * col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + 52 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT DISTINCT - col0 * col0 * - cor0.col1 FROM tab2 AS cor0
----
106097
1519
358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-3504
SELECT - col0 DIV + col2 - + col1 FROM tab1
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-3504
SELECT - col0 / + col2 - + col1 FROM tab1
----
-11
-13
-26

query I rowsort
SELECT ALL + col2 + + 19 FROM tab2 AS cor0
----
45
46
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3506
SELECT DISTINCT col2 DIV col0 + + col1 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-3506
SELECT DISTINCT col2 / col0 + + col1 FROM tab2 AS cor0
----
17
34
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 71 col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
-71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3508
SELECT ALL col2 * col2 + + CAST( - col0 AS SIGNED ) FROM tab1
----
2913
3185
9136

skipif mysql # not compatible
query I rowsort label-3508
SELECT ALL col2 * col2 + + CAST ( - col0 AS INTEGER ) FROM tab1
----
2913
3185
9136

query I rowsort
SELECT col0 * - tab1.col0 + + col2 AS col0 FROM tab1
----
-4039
-6304
45

query I rowsort
SELECT + tab1.col2 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + + cor0.col1 + col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3512
SELECT DISTINCT + col0 + col2 DIV col1 + - col1 AS col2 FROM tab1 AS cor0
----
-21
59
74

skipif mysql # not compatible
query I rowsort label-3512
SELECT DISTINCT + col0 + col2 / col1 + - col1 AS col2 FROM tab1 AS cor0
----
-21
59
74

query I rowsort
SELECT ALL + 1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT ALL + cor0.col2 + - ( 78 + - col2 ) * + ( 76 ) AS col1 FROM tab1 AS cor0
----
-1539
-1770
1464

query I rowsort
SELECT ALL + cor0.col0 * 93 + - col0 FROM tab2 AS cor0
----
644
7176
7268

query I rowsort
SELECT DISTINCT + col0 * + 52 AS col2 FROM tab2 cor0
----
364
4056
4108

query I rowsort
SELECT ALL col1 + - 54 AS col2 FROM tab2 AS cor0
----
-23
-37
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3518
SELECT + col2 * CAST( - col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-3518
SELECT + col2 * CAST ( - col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + + col1 + + col2 AS col0 FROM tab2 cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3520
SELECT DISTINCT - cor0.col0 + - CAST( - col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3520
SELECT DISTINCT - cor0.col0 + - CAST ( - col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort
SELECT ALL - - col0 * CAST ( - col1 AS REAL ) - col1 AS col1 FROM tab2 AS cor0
----
-1360
-248
-4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3522
SELECT DISTINCT col1 + + CAST( NULL AS SIGNED ) * ( + col2 ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3522
SELECT DISTINCT col1 + + CAST ( NULL AS INTEGER ) * ( + col2 ) AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3523
SELECT ALL + col2 - + col0 DIV col1 AS col0 FROM tab2 AS cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-3523
SELECT ALL + col2 - + col0 / col1 AS col0 FROM tab2 AS cor0
----
25
27
34

query I rowsort
SELECT DISTINCT - + cor0.col2 + - 3 AS col0 FROM tab2 AS cor0
----
-29
-30
-41

query I rowsort
SELECT - + col0 * col0 + col1 FROM tab1 cor0
----
-4086
-6387
17

query I rowsort
SELECT - tab0.col1 * - col0 + col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL ( - 78 ) + tab2.col2 FROM tab2
----
-40
-51
-52

query I rowsort
SELECT + 9 + col2 * col1 AS col0 FROM tab1 AS cor0
----
1257
1413
579

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3529
SELECT + 50 * + col1 + col2 + CAST( col2 AS SIGNED ) * - col1 FROM tab0
----
-2830
1495
4754

skipif mysql # not compatible
query I rowsort label-3529
SELECT + 50 * + col1 + col2 + CAST ( col2 AS INTEGER ) * - col1 FROM tab0
----
-2830
1495
4754

query I rowsort
SELECT ALL ( + col1 ) + col2 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL 72 * 71 * col2 + col0 AS col1 FROM tab1
----
276051
291448
490832

query I rowsort
SELECT col1 * 91 * + col0 FROM tab1
----
58240
7098
94640

query I rowsort
SELECT ALL + ( cor0.col0 ) * - col1 + 64 FROM tab1 AS cor0
----
-14
-576
-976

query I rowsort
SELECT DISTINCT - 6 FROM tab2, tab1 AS cor0
----
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3535
SELECT - + ( col0 ) * CAST( NULL AS SIGNED ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3535
SELECT - + ( col0 ) * CAST ( NULL AS INTEGER ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( - col1 ) * - cor0.col0 AS col0 FROM tab1 cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3537
SELECT DISTINCT + col2 * col2 + - ( - 41 ) DIV + col1 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-3537
SELECT DISTINCT + col2 * col2 + - ( - 41 ) / + col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL - 94 + cor0.col0 * - 17 - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1446
-1475
-240

query I rowsort
SELECT DISTINCT - + ( col1 ) + col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT + - cor0.col0 * + cor0.col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - 45 - cor0.col2 FROM tab1 cor0
----
-102
-141
-99

query I rowsort
SELECT ALL - col1 * col1 + 66 AS col2 FROM tab2 cor0
----
-223
-3415
-895

query I rowsort
SELECT col2 * cor0.col0 + - col1 AS col1 FROM tab1 cor0
----
136
3638
7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3544
SELECT DISTINCT - CAST( NULL AS SIGNED ) * cor0.col0 AS col0 FROM tab2, tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3544
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * cor0.col0 AS col0 FROM tab2, tab2 cor0
----
NULL

query I rowsort
SELECT ALL - col1 * - 46 FROM tab1
----
1196
460
598

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + ( col0 ) col1 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 71 col2 FROM tab0 AS cor0
----
1704
2485
6319

query I rowsort
SELECT ALL - col0 - + col0 FROM tab0 cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT + + col0 * col2 + ( col2 ) * 43 AS col1 FROM tab0 AS cor0
----
10824
2211
78

query I rowsort
SELECT ALL + col1 - 60 FROM tab1 AS cor0
----
-34
-47
-50

query I rowsort
SELECT - + col0 * 57 AS col0 FROM tab0 AS cor0
----
-1368
-1995
-5073

query I rowsort
SELECT DISTINCT - col2 * - 50 AS col2 FROM tab2 cor0
----
1300
1350
1900

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col1 + + cor0.col2 * col2 col1 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT ( col2 ) * - col1 - - col0 AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-3555
SELECT DISTINCT + col1 + - cor0.col2 DIV - cor0.col2 - + col0 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-1977
-3297
-8007

skipif mysql # not compatible
query I rowsort label-3555
SELECT DISTINCT + col1 + - cor0.col2 / - cor0.col2 - + col0 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-1977
-3297
-8007

query I rowsort
SELECT - + col2 + cor0.col2 * col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - ( 43 ) * + col0 - 1 AS col2 FROM tab0 cor0
----
-1033
-1506
-3828

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * - col0 + col2 - - col2 col0 FROM tab1 AS cor0
----
-3982
-6208
99

query I rowsort
SELECT 18 * cor0.col1 + - col2 AS col2 FROM tab0 AS cor0
----
1515
1556
1745

query I rowsort
SELECT - col0 + + col2 * - cor0.col1 - + col0 * col1 FROM tab1 AS cor0
----
-1274
-1485
-2368

query I rowsort
SELECT - + 36 + + 80 AS col1 FROM tab2 AS cor0
----
44
44
44

query I rowsort
SELECT DISTINCT 48 * tab0.col0 FROM tab0
----
1152
1680
4272

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3563
SELECT DISTINCT + + CAST( - col1 AS SIGNED ) + - cor0.col0 FROM tab2 AS cor0
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-3563
SELECT DISTINCT + + CAST ( - col1 AS INTEGER ) + - cor0.col0 FROM tab2 AS cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - ( col2 ) ) col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - col0 * col1 + + col2 - col0 * cor0.col2 FROM tab0 cor0
----
-15315
-2823
-3429

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3566
SELECT CAST( NULL AS SIGNED ) * col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3566
SELECT CAST ( NULL AS INTEGER ) * col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + col0 * - col2 FROM tab2
----
-2054
-216
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3568
SELECT - CAST( NULL AS SIGNED ) * + col2 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-3568
SELECT - CAST ( NULL AS INTEGER ) * + col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + - col0 * col0 AS col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT ALL 16 FROM tab1, tab0 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT + col0 * - ( - col0 ) AS col1 FROM tab1 AS cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 96 col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT ALL - 73 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2931474b870c05694e446771031a6949

onlyif mysql # use DIV operator for integer division
query I rowsort label-3574
SELECT DISTINCT - col2 DIV + 9 AS col2 FROM tab2
----
-2
-3
-4

skipif mysql # not compatible
query I rowsort label-3574
SELECT DISTINCT - col2 / + 9 AS col2 FROM tab2
----
-2
-3
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3575
SELECT - col1 DIV + cor0.col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3575
SELECT - col1 / + cor0.col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col0 * 66 AS col2 FROM tab1 AS cor0
----
-198
-4224
-5280

onlyif mysql # use DIV operator for integer division
query I rowsort label-3577
SELECT - - col1 DIV + col0 col2 FROM tab0 AS cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3577
SELECT - - col1 / + col0 col2 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3578
SELECT ALL + col1 DIV + col1 col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3578
SELECT ALL + col1 / + col1 col0 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3579
SELECT ALL + col0 DIV col0 AS col2 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3579
SELECT ALL + col0 / col0 AS col2 FROM tab2
----
1
1
1

query I rowsort
SELECT ALL - 44 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 19 - cor0.col0 col0 FROM tab2 AS cor0
----
1043
244
582

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3582
SELECT col2 + + CAST( + col0 AS SIGNED ) AS col1 FROM tab0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-3582
SELECT col2 + + CAST ( + col0 AS INTEGER ) AS col1 FROM tab0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col2 col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - col2 * + 84 - cor0.col1 FROM tab1 AS cor0
----
-4562
-4798
-8077

query I rowsort
SELECT + - col0 * - 25 - cor0.col2 * - col2 * cor0.col2 FROM tab0 AS cor0
----
36537
553593
876

query I rowsort
SELECT ALL 38 FROM tab2, tab1 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT + cor0.col2 * + cor0.col1 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 16ae0e1090cb09b93854a4788f17716b

query I rowsort
SELECT ALL 31 + col0 + col1 * 79 FROM tab0
----
6849
7309
7729

onlyif mysql # use DIV operator for integer division
query I rowsort label-3589
SELECT + - col2 + - cor0.col2 DIV col1 + col1 AS col1 FROM tab1 AS cor0
----
-30
-52
-90

skipif mysql # not compatible
query I rowsort label-3589
SELECT + - col2 + - cor0.col2 / col1 + col1 AS col1 FROM tab1 AS cor0
----
-30
-52
-90

query I rowsort
SELECT - - ( col1 ) * - col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 65 * col0 col0 FROM tab1 cor0
----
-195
-4160
-5200

query I rowsort
SELECT + - col0 + - cor0.col0 * + col1 AS col0 FROM tab1 AS cor0
----
-1120
-704
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3593
SELECT DISTINCT - + 35 * col1 + CAST( - ( + col0 ) AS SIGNED ) FROM tab0 AS cor0
----
-3034
-3274
-3430

skipif mysql # not compatible
query I rowsort label-3593
SELECT DISTINCT - + 35 * col1 + CAST ( - ( + col0 ) AS INTEGER ) FROM tab0 AS cor0
----
-3034
-3274
-3430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * cor0.col2 col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - + ( + col0 ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + 87 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT - + ( 76 ) FROM tab2, tab0, tab0 cor0
----
27 values hashing to d90b4aa5f03b4a149aa925c4a88acca0

query I rowsort
SELECT DISTINCT 51 * + col0 * col1 FROM tab1 AS cor0
----
32640
3978
53040

query I rowsort
SELECT ALL + + 78 + col0 * + 9 FROM tab0 AS cor0
----
294
393
879

query I rowsort
SELECT - - col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + + col1 + cor0.col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 30 * 30 + tab0.col1 + - ( col2 ) * + tab0.col0 col2 FROM tab0
----
-1606
-8107
-838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + + cor0.col0 col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + 79 AS col1 FROM tab0 AS cor0
----
79
79
79

query I rowsort
SELECT ALL + 59 AS col1 FROM tab2
----
59
59
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3606
SELECT DISTINCT - col0 * + CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3606
SELECT DISTINCT - col0 * + CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - col0 * + 9 * - col1 col0 FROM tab1 AS cor0
----
5817
756
9456

skipif mysql # not compatible
query I rowsort
SELECT cor0.col2 * - CAST ( + col1 AS REAL ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT tab0.col1 + - tab0.col0 FROM tab0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3610
SELECT tab0.col2 DIV - col2 + 20 AS col2 FROM tab0
----
19
19
19

skipif mysql # not compatible
query I rowsort label-3610
SELECT tab0.col2 / - col2 + 20 AS col2 FROM tab0
----
19
19
19

query I rowsort
SELECT + 99 + tab0.col0 FROM tab0
----
123
134
188

query I rowsort
SELECT DISTINCT - 16 FROM tab2
----
-16

query I rowsort
SELECT DISTINCT - col2 + 13 AS col2 FROM tab2 cor0
----
-13
-14
-25

query I rowsort
SELECT + + col1 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - col1 * - tab2.col0 * - col2 FROM tab2
----
-119652
-51034
-5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3616
SELECT DISTINCT - col1 * - ( - col2 ) * + ( 36 * col1 ) + - CAST( NULL AS SIGNED ) + col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3616
SELECT DISTINCT - col1 * - ( - col2 ) * + ( 36 * col1 ) + - CAST ( NULL AS INTEGER ) + col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - cor0.col2 + col2 * + col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL - 31 + ( col2 + 20 ) FROM tab2 AS cor0
----
15
16
27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3619
SELECT - - CAST( + 44 AS SIGNED ) * + col1 + 76 FROM tab1 cor0
----
1220
516
648

skipif mysql # not compatible
query I rowsort label-3619
SELECT - - CAST ( + 44 AS INTEGER ) * + col1 + 76 FROM tab1 cor0
----
1220
516
648

query I rowsort
SELECT + cor0.col0 * 42 AS col2 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT - 39 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

query I rowsort
SELECT - col2 * 5 * - col2 FROM tab0
----
33620
5
5445

query I rowsort
SELECT DISTINCT col2 - + 77 * col0 AS col0 FROM tab2
----
-512
-5980
-6045

query I rowsort
SELECT col1 * col2 - col0 AS col2 FROM tab0
----
2814
62
7373

query I rowsort
SELECT tab2.col0 + tab2.col1 AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT ( 1 ) FROM tab0, tab1 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3627
SELECT + tab2.col2 DIV + 50 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3627
SELECT + tab2.col2 / + 50 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3628
SELECT + col1 + col2 DIV + 41 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3628
SELECT + col1 + col2 / + 41 FROM tab2
----
17
31
59

query I rowsort
SELECT + 16 + tab2.col2 FROM tab2
----
42
43
54

query I rowsort
SELECT DISTINCT col0 * ( - col1 ) + + 36 AS col0 FROM tab2 AS cor0
----
-1307
-181
-4566

query I rowsort
SELECT ALL + - ( + 83 ) FROM tab2 AS cor0
----
-83
-83
-83

query I rowsort
SELECT + col1 * col0 + col2 AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - + col2 * ( - col0 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - - ( - col1 ) + col2 - 43 * - col0 FROM tab0 AS cor0
----
1409
3818
979

onlyif mysql # use DIV operator for integer division
query I rowsort label-3635
SELECT - ( - col1 ) DIV cor0.col2 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3635
SELECT - ( - col1 ) / cor0.col2 FROM tab0 cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 63 col1 FROM tab1 AS cor0
----
127
143
66

query I rowsort
SELECT DISTINCT + - cor0.col2 * - col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - 4 + 50 - + cor0.col2 FROM tab1 AS cor0
----
-11
-50
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3639
SELECT CAST( + 39 AS SIGNED ) * + col2 + 85 * - 75 - col2 FROM tab0 AS cor0
----
-3259
-5121
-6337

skipif mysql # not compatible
query I rowsort label-3639
SELECT CAST ( + 39 AS INTEGER ) * + col2 + 85 * - 75 - col2 FROM tab0 AS cor0
----
-3259
-5121
-6337

query I rowsort
SELECT - ( 31 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

query I rowsort
SELECT + - 28 FROM tab2 AS cor0
----
-28
-28
-28

query I rowsort
SELECT ALL col0 * - col1 + col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT - 19 AS col1 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

query I rowsort
SELECT 51 + tab0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to c3b814593fecf7f741e46c66e5608a6b

query I rowsort
SELECT DISTINCT 91 + col1 * col0 * 83 AS col1 FROM tab1
----
53211
6565
86411

query I rowsort
SELECT - col0 * col2 - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT + col2 + + col2 * col1 AS col0 FROM tab2
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-3648
SELECT ALL 59 DIV col0 + col2 col0 FROM tab0
----
2
35
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3648
SELECT ALL 59 / col0 + col2 col0 FROM tab0
----
2
35
82

query I rowsort
SELECT - 39 * + col2 AS col1 FROM tab1
----
-2106
-2223
-3744

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( col2 AS REAL ) + + col2 * col1 FROM tab0 AS cor0
----
2871
7544
98

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( col2 AS REAL ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL - 2 * + col0 AS col2 FROM tab2
----
-14
-156
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3653
SELECT CAST( - col2 AS SIGNED ) * col2 DIV ( 34 ) FROM tab0
----
-197
-32
0

skipif mysql # not compatible
query I rowsort label-3653
SELECT CAST ( - col2 AS INTEGER ) * col2 / ( 34 ) FROM tab0
----
-197
-32
0

query I rowsort
SELECT col0 * 66 FROM tab1
----
198
4224
5280

query I rowsort
SELECT + col0 + 1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - 89 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to c36e597b7bc5727536f5bb580e6cebbc

query I rowsort
SELECT DISTINCT ( + col1 + col2 ) AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT DISTINCT + 44 FROM tab0, tab1, tab0 AS cor0
----
44

query I rowsort
SELECT col1 * col1 * - col2 + 75 FROM tab0
----
-243993
-678967
-9334

query I rowsort
SELECT col1 * + col1 * - col2 + - col0 * - col0 AS col1 FROM tab0
----
-243492
-671121
-8184

query I rowsort
SELECT ALL + - cor0.col2 + ( + col1 * col2 + col1 ) FROM tab0 AS cor0
----
193
2891
7471

query I rowsort
SELECT - - col1 + col0 AS col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - 84 AS col1 FROM tab1, tab0 AS cor0
----
-84

query I rowsort
SELECT DISTINCT + - col0 * ( - col2 ) AS col1 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3665
SELECT ALL - col1 DIV - cor0.col1 col0 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3665
SELECT ALL - col1 / - cor0.col1 col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT col1 * 6 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT DISTINCT - - col2 + - col1 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT col1 * + ( + ( - col1 ) ) * 44 AS col2 FROM tab1 AS cor0
----
-29744
-4400
-7436

query I rowsort
SELECT + + cor0.col2 + + col2 * 76 AS col2 FROM tab0 AS cor0
----
2541
6314
77

query I rowsort
SELECT ALL - cor0.col0 + - ( col1 ) + col2 AS col2 FROM tab0 AS cor0
----
-131
-77
-98

query I rowsort
SELECT DISTINCT + col2 * + col2 * cor0.col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL 51 * cor0.col1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 98c668e36be52a824d29bbc0004a3f1b

query I rowsort
SELECT ALL - col2 * ( + 24 ) * col0 FROM tab2
----
-4536
-48672
-72048

query I rowsort
SELECT - - ( - col2 ) * col0 + 97 AS col0 FROM tab0 AS cor0
----
-695
-7201
62

query I rowsort
SELECT cor0.col0 * col1 + col2 * col2 FROM tab2 cor0
----
2787
5278
946

query I rowsort
SELECT + + 31 * + col1 AS col2 FROM tab0 AS cor0
----
2666
2821
3007

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 41 ) + col0 + - col0 col0 FROM tab0 AS cor0
----
-41
-41
-41

query I rowsort
SELECT ALL - 84 + col1 AS col1 FROM tab0 AS cor0
----
13
2
7

query I rowsort
SELECT DISTINCT - + col2 + cor0.col1 + col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - + 89 * col0 AS col0 FROM tab2 AS cor0
----
-623
-6942
-7031

query I rowsort
SELECT DISTINCT cor0.col2 + - col2 * col0 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * col2 col1 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) * col2 * - ( + col2 ) col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT col0 * col1 + + 79 FROM tab1 AS cor0
----
1119
157
719

query I rowsort
SELECT DISTINCT + - 64 + col0 FROM tab0 AS cor0
----
-29
-40
25

query I rowsort
SELECT - 38 + col2 AS col0 FROM tab2 AS cor0
----
-11
-12
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * - col0 + + col1 col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT + - 94 AS col2 FROM tab2 AS cor0
----
-94
-94
-94

query I rowsort
SELECT 97 + - col2 * col2 AS col0 FROM tab2 AS cor0
----
-1347
-579
-632

query I rowsort
SELECT + col0 * ( - col2 * col0 ) AS col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - - col1 + - 68 * 15 FROM tab1 AS cor0
----
-1007
-1010
-994

query I rowsort
SELECT ALL + 35 * tab2.col1 FROM tab2
----
1085
2065
595

query I rowsort
SELECT - 64 * + 56 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 864dbbcdddaf8bf457680af4f0317188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 58 * - col1 + col1 * col2 col0 FROM tab1 AS cor0
----
-10
-104
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 * + col2 col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + 43 AS col0 FROM tab1 AS cor0
----
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-3697
SELECT DISTINCT - - cor0.col2 DIV col0 AS col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3697
SELECT DISTINCT - - cor0.col2 / col0 AS col0 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT ALL 5 * col0 * col2 + ( col2 ) FROM tab0 cor0
----
176
36572
3993

query I rowsort
SELECT + cor0.col2 + - col0 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + + col2 * - col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL 38 * cor0.col2 FROM tab1 AS cor0
----
2052
2166
3648

query I rowsort
SELECT DISTINCT + + 99 FROM tab1 AS cor0
----
99

query I rowsort
SELECT DISTINCT + col0 + col1 + col0 FROM tab0
----
134
167
269

query I rowsort
SELECT - 94 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a95bfa539191d3f72f6548147d7efb9e

query I rowsort
SELECT + cor0.col0 * + cor0.col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - ( 89 ) FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-89

query I rowsort
SELECT col0 + col2 * - ( + 44 ) * col2 AS col0 FROM tab1 AS cor0
----
-128301
-142892
-405424

query I rowsort
SELECT + col2 * 3 AS col1 FROM tab2
----
114
78
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3709
SELECT - CAST( NULL AS SIGNED ) * 19 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3709
SELECT - CAST ( NULL AS INTEGER ) * 19 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col1 * - ( col1 ) - col0 AS col1 FROM tab1 cor0
----
-164
-249
-679

query I rowsort
SELECT ALL + col2 + 22 FROM tab2
----
48
49
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3712
SELECT ALL - CAST( col1 * col0 AS SIGNED ) + - col2 FROM tab0
----
-2097
-3396
-8181

skipif mysql # not compatible
query I rowsort label-3712
SELECT ALL - CAST ( col1 * col0 AS INTEGER ) + - col2 FROM tab0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL 48 + col1 * - col0 FROM tab1
----
-30
-592
-992

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col1 AS REAL ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - cor0.col0 + + 27 * col0 * - cor0.col0 FROM tab0 AS cor0
----
-15576
-213956
-33110

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 cor0, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 263f0eb7d5dfd4076c74918bc141bd9b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col2 + + tab2.col2 col0 FROM tab2
----
114
78
81

query I rowsort
SELECT DISTINCT 65 + - ( + col2 ) AS col0 FROM tab2
----
27
38
39

query I rowsort
SELECT DISTINCT - col0 + tab1.col1 AS col2 FROM tab1
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-3720
SELECT col0 DIV + col1 + cor0.col0 FROM tab2 cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-3720
SELECT col0 / + col1 + cor0.col0 FROM tab2 cor0
----
7
79
83

query I rowsort
SELECT DISTINCT + col0 * col1 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT - - ( + col0 ) + cor0.col1 AS col1 FROM tab1 cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3723
SELECT ALL - 41 DIV + col0 + + col0 * + col1 AS col1 FROM tab0 AS cor0
----
2063
3394
8099

skipif mysql # not compatible
query I rowsort label-3723
SELECT ALL - 41 / + col0 + + col0 * + col1 AS col1 FROM tab0 AS cor0
----
2063
3394
8099

query I rowsort
SELECT - ( + col1 ) + + col0 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3725
SELECT ALL + cor0.col0 + - col0 - col1 DIV - ( ( col0 ) ) FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-3725
SELECT ALL + cor0.col0 + - col0 - col1 / - ( ( col0 ) ) FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT ALL 59 AS col1 FROM tab1 AS cor0
----
59
59
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3727
SELECT + - CAST( NULL AS SIGNED ) * col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3727
SELECT + - CAST ( NULL AS INTEGER ) * col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col1 * + 98 + - col0 FROM tab0 AS cor0
----
-8452
-9007
-9541

onlyif mysql # use DIV operator for integer division
query I rowsort label-3729
SELECT + ( cor0.col0 ) DIV + col1 + col1 DIV + ( - col1 ) FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3729
SELECT + ( cor0.col0 ) / + col1 + col1 / + ( - col1 ) FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT 86 * + 63 FROM tab2 AS cor0
----
5418

query I rowsort
SELECT ALL + col1 + ( - col1 ) FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + 71 * + col1 FROM tab2 AS cor0
----
1207
2201
4189

query I rowsort
SELECT DISTINCT col0 * 75 FROM tab2 AS cor0
----
525
5850
5925

query I rowsort
SELECT DISTINCT + 21 + col1 + ( - col2 ) AS col0 FROM tab1 AS cor0
----
-26
-62
-7

query I rowsort
SELECT + + col0 * + col1 + ( col1 ) * + col1 FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT + - col1 * - col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT 46 + - col1 FROM tab0 AS cor0
----
-40
-45
-51

query I rowsort
SELECT DISTINCT - - 15 AS col1 FROM tab0 AS cor0
----
15

query I rowsort
SELECT ALL + 96 * + col1 AS col1 FROM tab0 cor0
----
8256
8736
9312

query I rowsort
SELECT - 56 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

query I rowsort
SELECT DISTINCT col2 * col2 + col1 + 99 AS col0 FROM tab0 AS cor0
----
1274
197
6914

query I rowsort
SELECT DISTINCT + + col2 * + col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL - col2 + ( col0 ) FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - col2 * - col1 + 68 + - col1 AS col0 FROM tab1 AS cor0
----
1303
1446
628

query I rowsort
SELECT ALL col1 * ( col1 ) AS col2 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3746
SELECT DISTINCT - col2 DIV - col2 + col1 AS col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-3746
SELECT DISTINCT - col2 / - col2 + col1 AS col2 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT DISTINCT + + 43 AS col2 FROM tab0 cor0
----
43

query I rowsort
SELECT ALL cor0.col2 * - 69 AS col1 FROM tab1 AS cor0
----
-3726
-3933
-6624

query I rowsort
SELECT DISTINCT col0 - - 11 AS col0 FROM tab1
----
14
75
91

query I rowsort
SELECT DISTINCT 95 * + 16 - col1 FROM tab2 AS cor0
----
1461
1489
1503

query I rowsort
SELECT - col2 + + col2 * cor0.col0 * col1 FROM tab1 AS cor0
----
36423
4158
99744

query I rowsort
SELECT ALL + + ( 69 ) + - col0 * - 67 AS col2 FROM tab2 AS cor0
----
5295
5362
538

query I rowsort
SELECT + 8 - - 93 FROM tab2 cor0
----
101
101
101

onlyif mysql # use DIV operator for integer division
query I rowsort label-3754
SELECT DISTINCT - + ( - col1 ) * col2 * - 97 + + col0 DIV - col1 - + 83 * 56 FROM tab0 cor0
----
-14057
-279934
-728462

skipif mysql # not compatible
query I rowsort label-3754
SELECT DISTINCT - + ( - col1 ) * col2 * - 97 + + col0 / - col1 - + 83 * 56 FROM tab0 cor0
----
-14057
-279934
-728462

query I rowsort
SELECT + - ( 6 ) + - col0 FROM tab1 AS cor0
----
-70
-86
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3756
SELECT - col0 - - tab1.col1 DIV col1 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-3756
SELECT - col0 - - tab1.col1 / col1 FROM tab1
----
-2
-63
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 + tab2.col2 col2 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT col2 + + col1 + ( + col1 ) AS col1 FROM tab1
----
106
122
77

query I rowsort
SELECT col0 * 46 FROM tab2
----
322
3588
3634

query I rowsort
SELECT DISTINCT col1 * col0 * 65 + + tab0.col1 * tab0.col0 - col2 FROM tab0
----
136191
224069
534452

query I rowsort
SELECT DISTINCT ( + col0 ) * + 4 FROM tab1 AS cor0
----
12
256
320

query I rowsort
SELECT ALL ( col0 ) * - cor0.col0 + cor0.col0 * - col2 FROM tab2 AS cor0
----
-238
-8112
-9243

query I rowsort
SELECT DISTINCT - + 31 AS col1 FROM tab2 AS cor0
----
-31

query I rowsort
SELECT + col2 + + col0 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - cor0.col1 * + col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT 83 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT DISTINCT - - 86 * + col2 FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT + + col0 * + 39 AS col1 FROM tab1 AS cor0
----
117
2496
3120

query I rowsort
SELECT - - col1 * - ( + 80 ) FROM tab0 AS cor0
----
-6880
-7280
-7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + cor0.col2 col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL - ( col2 ) * tab0.col0 AS col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3772
SELECT col0 DIV col1 + col1 AS col2 FROM tab1
----
16
19
26

skipif mysql # not compatible
query I rowsort label-3772
SELECT col0 / col1 + col1 AS col2 FROM tab1
----
16
19
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3773
SELECT ALL 41 * col1 + col1 + CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
1118
430
559

skipif mysql # not compatible
query I rowsort label-3773
SELECT ALL 41 * col1 + col1 + CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
1118
430
559

query I rowsort
SELECT DISTINCT - 34 AS col1 FROM tab2 AS cor0
----
-34

query I rowsort
SELECT + - 0 * col2 + - col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + - 56 + - col0 AS col2 FROM tab0 AS cor0
----
-145
-80
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + 2 col1 FROM tab1 AS cor0
----
56
59
98

query I rowsort
SELECT + - 83 * - col1 FROM tab0 cor0
----
7138
7553
8051

query I rowsort
SELECT + col0 * col1 + + col1 + col2 FROM tab0 AS cor0
----
2183
3493
8272

onlyif mysql # use DIV operator for integer division
query I rowsort label-3780
SELECT ALL + 94 * col2 + - col0 DIV - col0 AS col2 FROM tab0 AS cor0
----
3103
7709
95

skipif mysql # not compatible
query I rowsort label-3780
SELECT ALL + 94 * col2 + - col0 / - col0 AS col2 FROM tab0 AS cor0
----
3103
7709
95

query I rowsort
SELECT DISTINCT 13 AS col0 FROM tab0 AS cor0
----
13

query I rowsort
SELECT - 74 + - 72 FROM tab0 AS cor0
----
-146
-146
-146

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * ( col0 ) + col0 + - 10 * + 40 col1 FROM tab0
----
-330
416
6987

query I rowsort
SELECT - col0 + ( col1 ) AS col2 FROM tab0
----
2
62
62

query I rowsort
SELECT DISTINCT col1 * 56 + + col2 * + col1 AS col0 FROM tab1
----
1130
1976
2860

onlyif mysql # use DIV operator for integer division
query I rowsort label-3786
SELECT DISTINCT - 45 + - tab1.col0 DIV - 62 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-44
-45

skipif mysql # not compatible
query I rowsort label-3786
SELECT DISTINCT - 45 + - tab1.col0 / - 62 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-44
-45

query I rowsort
SELECT DISTINCT - cor0.col2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT + tab0.col0 + 3 * tab0.col0 FROM tab0
----
140
356
96

query I rowsort
SELECT + col2 * col1 * + col1 + ( + col2 + col1 ) AS col1 FROM tab1 AS cor0
----
16333
36584
5767

onlyif mysql # use DIV operator for integer division
query I rowsort label-3790
SELECT + 40 + + 1 + col1 DIV - col1 AS col1 FROM tab0 AS cor0
----
40
40
40

skipif mysql # not compatible
query I rowsort label-3790
SELECT + 40 + + 1 + col1 / - col1 AS col1 FROM tab0 AS cor0
----
40
40
40

query I rowsort
SELECT DISTINCT - col2 * - col2 * col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT DISTINCT + ( - col0 ) * col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - 93 * - 20 FROM tab1 AS cor0
----
1860
1860
1860

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3794
SELECT ALL - CAST( col1 AS SIGNED ) AS col2 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-3794
SELECT ALL - CAST ( col1 AS INTEGER ) AS col2 FROM tab1
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col2 ) + + col0 col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL 87 * cor0.col1 AS col2 FROM tab0 AS cor0
----
7482
7917
8439

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 col0 FROM tab2
----
67
67
67

query I rowsort
SELECT + col0 + + col0 * 61 FROM tab0 AS cor0
----
1488
2170
5518

onlyif mysql # use DIV operator for integer division
query I rowsort label-3799
SELECT cor0.col2 * col1 + col1 DIV + col0 FROM tab2 cor0
----
1534
646
841

skipif mysql # not compatible
query I rowsort label-3799
SELECT cor0.col2 * col1 + col1 / + col0 FROM tab2 cor0
----
1534
646
841

query I rowsort
SELECT + + 52 * + col0 + col0 FROM tab0 AS cor0
----
1272
1855
4717

query I rowsort
SELECT DISTINCT + ( + 46 ) FROM tab1
----
46

query I rowsort
SELECT - col0 * 37 FROM tab2
----
-259
-2886
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * tab0.col1 col1 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - col2 + ( + col2 ) col0 FROM tab0 cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3805
SELECT - col2 DIV cor0.col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3805
SELECT - col2 / cor0.col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT + 91 + + col2 FROM tab2 AS cor0
----
117
118
129

query I rowsort
SELECT DISTINCT - col0 + 53 AS col0 FROM tab2
----
-25
-26
46

query I rowsort
SELECT + + col2 + + col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - col1 * col1 + col1 + - col2 FROM tab1 AS cor0
----
-147
-252
-704

query I rowsort
SELECT - col0 * col2 - col1 AS col2 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT - col1 * col2 + + col0 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3812
SELECT ALL CAST( NULL AS DECIMAL ) * 89 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3812
SELECT ALL CAST ( NULL AS REAL ) * 89 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - 20 + + 48 AS col0 FROM tab2 AS cor0
----
28
28
28

query I rowsort
SELECT + + col1 * col2 + - col2 * col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 * - col2 + - col2 AS col0 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT + col0 + + col1 + + col0 FROM tab2 AS cor0
----
175
215
45

query I rowsort
SELECT - col0 + + col0 * + 41 AS col1 FROM tab1
----
120
2560
3200

query I rowsort
SELECT + cor0.col1 * 96 FROM tab0 AS cor0
----
8256
8736
9312

query I rowsort
SELECT - col1 * - 81 AS col1 FROM tab1 AS cor0
----
1053
2106
810

query I rowsort
SELECT col0 * 38 * - col2 AS col1 FROM tab1 AS cor0
----
-138624
-291840
-6156

query I rowsort
SELECT ALL - col0 * 46 AS col0 FROM tab2 AS cor0
----
-322
-3588
-3634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3822
SELECT ALL - col1 * CAST( col1 * + col0 AS SIGNED ) FROM tab0 AS cor0
----
-177504
-329315
-737009

skipif mysql # not compatible
query I rowsort label-3822
SELECT ALL - col1 * CAST ( col1 * + col0 AS INTEGER ) FROM tab0 AS cor0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-3823
SELECT + + col1 * col1 + + col2 * col0 DIV + ( col0 ) FROM tab2 AS cor0
----
327
3507
988

skipif mysql # not compatible
query I rowsort label-3823
SELECT + + col1 * col1 + + col2 * col0 / + ( col0 ) FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT col2 + ( ( col0 ) ) * + 22 + + col0 AS col1 FROM tab0 AS cor0
----
2129
585
806

query I rowsort
SELECT ALL col2 * 43 AS col2 FROM tab2 AS cor0
----
1118
1161
1634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3826
SELECT ALL + col2 * CAST( - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-3826
SELECT ALL + col2 * CAST ( - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - 45 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 71160abf09589695379a70558726f0ba

query I rowsort
SELECT DISTINCT + 43 AS col2 FROM tab1, tab2 AS cor0
----
43

query I rowsort
SELECT ALL - 71 + - col0 * col1 FROM tab1 AS cor0
----
-1111
-149
-711

query I rowsort
SELECT 85 * cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 0f5bdae12cc44fbaa4d67f7b41a774b8

query I rowsort
SELECT DISTINCT + - col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col2 + col1 + col1 AS col1 FROM tab1 AS cor0
----
106
122
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3833
SELECT ALL CAST( NULL AS DECIMAL ) * + col1 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3833
SELECT ALL CAST ( NULL AS REAL ) * + col1 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 84 + 29 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2
----
113

query I rowsort
SELECT DISTINCT + tab2.col2 + 94 FROM tab2
----
120
121
132

onlyif mysql # use DIV operator for integer division
query I rowsort label-3836
SELECT DISTINCT - tab0.col1 + col1 + col0 DIV - tab0.col0 AS col1 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-3836
SELECT DISTINCT - tab0.col1 + col1 + col0 / - tab0.col0 AS col1 FROM tab0
----
-1

query I rowsort
SELECT col0 + + ( 14 ) FROM tab0
----
103
38
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-3838
SELECT DISTINCT - 28 DIV col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3838
SELECT DISTINCT - 28 / col1 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT - 72 AS col1 FROM tab2, tab1 AS cor0
----
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-3840
SELECT 47 DIV col0 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3840
SELECT 47 / col0 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT ( + col1 ) AS col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + - 82 + col2 * 99 FROM tab2 AS cor0
----
2492
2591
3680

query I rowsort
SELECT 47 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 29 - + col0 * col0 * tab0.col2 col2 FROM tab0
----
-1196
-18979
-649493

query I rowsort
SELECT ALL + tab1.col0 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT 80 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 - + 14 col0 FROM tab2 AS cor0
----
175
2014
2988

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3848
SELECT ALL - col0 - - col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3848
SELECT ALL - col0 - - col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 37 * + col1 * tab1.col1 - - col2 * col2 AS col0 FROM tab1
----
15469
27928
6949

query I rowsort
SELECT - cor0.col1 + - 90 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8460464eaf730a0c496582c508a09693

query I rowsort
SELECT ALL + 32 - col1 AS col1 FROM tab0
----
-54
-59
-65

query I rowsort
SELECT col1 + - col0 * ( col2 * + tab1.col0 ) + - ( 41 ) AS col0 FROM tab1
----
-233503
-501
-614428

onlyif mysql # use DIV operator for integer division
query I rowsort label-3853
SELECT DISTINCT 33 + + col1 DIV col0 FROM tab2 AS cor0
----
33
37

skipif mysql # not compatible
query I rowsort label-3853
SELECT DISTINCT 33 + + col1 / col0 FROM tab2 AS cor0
----
33
37

query I rowsort
SELECT ALL - + col2 * col1 - - col2 AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT - col0 * - col0 + - col0 FROM tab0 cor0
----
1190
552
7832

query I rowsort
SELECT ALL - col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3857
SELECT + col0 * CAST( 9 + col2 AS SIGNED ) FROM tab2
----
252
2730
3713

skipif mysql # not compatible
query I rowsort label-3857
SELECT + col0 * CAST ( 9 + col2 AS INTEGER ) FROM tab2
----
252
2730
3713

onlyif mysql # use DIV operator for integer division
query I rowsort label-3858
SELECT - + col2 * col1 + + 59 DIV - col0 col0 FROM tab0 AS cor0
----
-2840
-7462
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3858
SELECT - + col2 * col1 + + 59 / - col0 col0 FROM tab0 AS cor0
----
-2840
-7462
-98

query I rowsort
SELECT + col1 - + col0 AS col0 FROM tab1 cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 9 col2 FROM tab0 AS cor0
----
-774
-819
-873

query I rowsort
SELECT DISTINCT cor2.col1 FROM tab0, tab2 cor0, tab0 AS cor1, tab1 AS cor2
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3862
SELECT DISTINCT + col2 - - ( + col0 ) DIV col0 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-3862
SELECT DISTINCT + col2 - - ( + col0 ) / col0 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT DISTINCT - cor0.col1 + ( - col0 ) AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT - col1 * - ( 47 ) AS col1 FROM tab0 AS cor0
----
4042
4277
4559

onlyif mysql # use DIV operator for integer division
query I rowsort label-3865
SELECT - cor0.col1 * 61 DIV + col1 - col2 * ( - col2 * cor0.col1 ) AS col0 FROM tab2 AS cor0
----
22538
24487
39823

skipif mysql # not compatible
query I rowsort label-3865
SELECT - cor0.col1 * 61 / + col1 - col2 * ( - col2 * cor0.col1 ) AS col0 FROM tab2 AS cor0
----
22538
24487
39823

query I rowsort
SELECT + col0 + + col1 AS col1 FROM tab1
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 1 * col2 col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + 52 - + col0 FROM tab1 cor0
----
-12
-28
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3869
SELECT DISTINCT - CAST( 94 AS SIGNED ) * col1 * - col2 + cor0.col1 FROM tab1 AS cor0
----
117325
132002
53590

skipif mysql # not compatible
query I rowsort label-3869
SELECT DISTINCT - CAST ( 94 AS INTEGER ) * col1 * - col2 + cor0.col1 FROM tab1 AS cor0
----
117325
132002
53590

query I rowsort
SELECT ( 81 ) FROM tab2 cor0
----
81
81
81

query I rowsort
SELECT - ( col1 ) * col0 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT ALL + - ( col2 ) * + col1 + + 53 AS col0 FROM tab2 AS cor0
----
-1481
-593
-784

query I rowsort
SELECT ALL + + 14 + col2 FROM tab2 AS cor0
----
40
41
52

query I rowsort
SELECT DISTINCT - + 21 + col2 * - 11 AS col0 FROM tab2 AS cor0
----
-307
-318
-439

query I rowsort
SELECT ALL + - ( + col0 ) + + ( col1 + cor0.col1 ) FROM tab2 AS cor0
----
-45
40
55

query I rowsort
SELECT DISTINCT 97 AS col1 FROM tab1 cor0
----
97

query I rowsort
SELECT DISTINCT 43 FROM tab2 AS cor0
----
43

query I rowsort
SELECT DISTINCT cor0.col2 + - col1 AS col1 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3879
SELECT ALL - 72 DIV col1 - - 22 AS col0 FROM tab2 AS cor0
----
18
20
21

skipif mysql # not compatible
query I rowsort label-3879
SELECT ALL - 72 / col1 - - 22 AS col0 FROM tab2 AS cor0
----
18
20
21

query I rowsort
SELECT DISTINCT + + 65 + + col2 FROM tab2 AS cor0
----
103
91
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-3881
SELECT ALL - col1 DIV - col2 + + col2 col0 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3881
SELECT ALL - col1 / - col2 + + col2 col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL - + col0 * + col1 - + col2 * ( col2 ) FROM tab0 AS cor0
----
-14823
-3153
-3396

query I rowsort
SELECT ALL - 26 AS col2 FROM tab1
----
-26
-26
-26

query I rowsort
SELECT - tab1.col0 * tab1.col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 064f0d12f5a54890818030ba889e7e5c

query I rowsort
SELECT ALL - - col2 + col1 * col1 AS col2 FROM tab0 cor0
----
7429
8363
9410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3886
SELECT ALL + col2 * + col2 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3886
SELECT ALL + col2 * + col2 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3887
SELECT DISTINCT col1 DIV cor0.col2 + + ( col2 ) * + col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-3887
SELECT DISTINCT col1 / cor0.col2 + + ( col2 ) * + col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab1, tab1 AS cor0, tab0, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT ALL cor0.col2 * - col1 + col0 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 + + cor0.col2 * + 10 col1 FROM tab0 AS cor0
----
-25
306
731

query I rowsort
SELECT ALL - + cor0.col0 + ( cor0.col0 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 5 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

onlyif mysql # use DIV operator for integer division
query I rowsort label-3893
SELECT + ( - col1 ) DIV col1 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-3893
SELECT + ( - col1 ) / col1 col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - 26 AS col2 FROM tab2
----
-26
-26
-26

query I rowsort
SELECT ALL 43 AS col2 FROM tab0
----
43
43
43

query I rowsort
SELECT ALL col0 * + col0 + + col0 AS col1 FROM tab0
----
1260
600
8010

query I rowsort
SELECT ALL tab0.col0 * - col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT + + 83 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 002a717a3d902d97220759065fb107c3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3899
SELECT DISTINCT cor0.col2 DIV col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3899
SELECT DISTINCT cor0.col2 / col0 FROM tab0 AS cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 18 col0 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to a13db73ec93475d2821cb4a6d0eff298

query I rowsort
SELECT - 59 * col1 + col2 * col0 - - cor0.col2 FROM tab2 AS cor0
----
-1427
-1613
2037

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3902
SELECT + col2 * - col2 + CAST( NULL AS SIGNED ) * col2 - col0 * + col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3902
SELECT + col2 * - col2 + CAST ( NULL AS INTEGER ) * col2 - col0 * + col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3903
SELECT ALL + 76 + + col1 DIV + col0 AS col0 FROM tab2 cor0
----
76
76
80

skipif mysql # not compatible
query I rowsort label-3903
SELECT ALL + 76 + + col1 / + col0 AS col0 FROM tab2 cor0
----
76
76
80

query I rowsort
SELECT + + 75 AS col2 FROM tab0 AS cor0
----
75
75
75

query I rowsort
SELECT + + col0 * col1 + + 15 AS col0 FROM tab2 AS cor0
----
1358
232
4617

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 * - col0 col2 FROM tab2 cor0
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3907
SELECT + col1 + cor0.col2 - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3907
SELECT + col1 + cor0.col2 - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

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 col0 * 50 + col2 FROM tab0 AS cor0
----
1233
1751
4532

onlyif mysql # use DIV operator for integer division
query I rowsort label-3910
SELECT ALL + cor0.col2 DIV - col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-3910
SELECT ALL + cor0.col2 / - col1 FROM tab1 AS cor0
----
-2
-5
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3911
SELECT + col2 * CAST( + col2 AS SIGNED ) + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-96
1003
6633

skipif mysql # not compatible
query I rowsort label-3911
SELECT + col2 * CAST ( + col2 AS INTEGER ) + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT ALL - col1 + 13 FROM tab2 AS cor0
----
-18
-4
-46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * 36 + + col2 col2 FROM tab1 AS cor0
----
1998
2109
3552

onlyif mysql # use DIV operator for integer division
query I rowsort label-3914
SELECT + col2 DIV col2 + col2 * col2 FROM tab0 AS cor0
----
1090
2
6725

skipif mysql # not compatible
query I rowsort label-3914
SELECT + col2 / col2 + col2 * col2 FROM tab0 AS cor0
----
1090
2
6725

query I rowsort
SELECT + + 31 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT + cor0.col0 + + 27 FROM tab0 AS cor0
----
116
51
62

query I rowsort
SELECT cor0.col0 AS col2 FROM tab2, tab2 AS cor0 WHERE NOT NULL <= NULL
----

query I rowsort
SELECT tab1.col1 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 - cor0.col1 col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT - - col0 * col0 * col1 AS col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT col0 * - cor0.col0 + col2 AS col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT - col0 * ( col0 ) FROM tab1 cor0
----
-4096
-6400
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3923
SELECT + - col1 / + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3923
SELECT + - col1 / + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 81 FROM tab0 cor0
----
-81

query I rowsort
SELECT ALL col0 * 85 AS col2 FROM tab0
----
2040
2975
7565

query I rowsort
SELECT DISTINCT - col0 - + 17 * - col1 * + col1 FROM tab2 AS cor0
----
16330
4834
59099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 89 ) col1 FROM tab2 AS cor0
----
-89
-89
-89

query I rowsort
SELECT ALL + 52 + col2 AS col1 FROM tab1 AS cor0
----
106
109
148

onlyif mysql # use DIV operator for integer division
query I rowsort label-3929
SELECT ALL + col0 DIV col2 + - col2 DIV + col2 + 8 FROM tab0 AS cor0
----
42
7
8

skipif mysql # not compatible
query I rowsort label-3929
SELECT ALL + col0 / col2 + - col2 / + col2 + 8 FROM tab0 AS cor0
----
42
7
8

query I rowsort
SELECT DISTINCT - col1 * 95 AS col1 FROM tab2 AS cor0
----
-1615
-2945
-5605

onlyif mysql # use DIV operator for integer division
query I rowsort label-3931
SELECT + + 5 + col2 DIV col0 col2 FROM tab0 AS cor0
----
5
5
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3931
SELECT + + 5 + col2 / col0 col2 FROM tab0 AS cor0
----
5
5
6

query I rowsort
SELECT DISTINCT - + col2 * cor0.col2 * col2 - col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-19732
-23660
-61113

query I rowsort
SELECT - col2 * 46 FROM tab2
----
-1196
-1242
-1748

query I rowsort
SELECT DISTINCT - col2 - - 79 * 64 FROM tab0
----
4974
5023
5055

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3935
SELECT DISTINCT col0 * CAST( 93 * - col2 AS SIGNED ) - ( + col2 * - col2 + + tab1.col0 ) AS col2 FROM tab1
----
-12153
-336079
-705104

skipif mysql # not compatible
query I rowsort label-3935
SELECT DISTINCT col0 * CAST ( 93 * - col2 AS INTEGER ) - ( + col2 * - col2 + + tab1.col0 ) AS col2 FROM tab1
----
-12153
-336079
-705104

query I rowsort
SELECT - tab0.col1 - + col0 FROM tab0
----
-110
-132
-180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3937
SELECT col2 * CAST( + col0 * col0 AS SIGNED ) AS col1 FROM tab2
----
1323
158184
237158

skipif mysql # not compatible
query I rowsort label-3937
SELECT col2 * CAST ( + col0 * col0 AS INTEGER ) AS col1 FROM tab2
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3938
SELECT + 44 DIV - col2 col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3938
SELECT + 44 / - col2 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - col1 + + col0 * cor0.col1 * col2 FROM tab0 AS cor0
----
3492
664209
68198

onlyif mysql # use DIV operator for integer division
query I rowsort label-3940
SELECT - - 69 + col1 * col2 DIV - 6 AS col1 FROM tab2 AS cor0
----
-186
-38
-70

skipif mysql # not compatible
query I rowsort label-3940
SELECT - - 69 + col1 * col2 / - 6 AS col1 FROM tab2 AS cor0
----
-186
-38
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3941
SELECT ALL - CAST( - 34 AS SIGNED ) * tab1.col0 AS col1 FROM tab1
----
102
2176
2720

skipif mysql # not compatible
query I rowsort label-3941
SELECT ALL - CAST ( - 34 AS INTEGER ) * tab1.col0 AS col1 FROM tab1
----
102
2176
2720

query I rowsort
SELECT DISTINCT + 73 * + col1 FROM tab0
----
6278
6643
7081

query I rowsort
SELECT 3 + + cor0.col1 - 16 FROM tab2, tab0 AS cor0
----
9 values hashing to c1b00775411f410c5309cc275ba378c2

query I rowsort
SELECT ALL + ( tab0.col0 ) * - col1 AS col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ( 31 ) AS col2 FROM tab1
----
31
31
31

query I rowsort
SELECT + tab2.col2 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col2 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + 99 * col1 AS col0 FROM tab0
----
8514
9009
9603

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * + col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - col2 * + 71 FROM tab2
----
-1846
-1917
-2698

query I rowsort
SELECT ALL + col0 + + col0 AS col0 FROM tab0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-3952
SELECT + tab0.col2 DIV + ( col0 + col0 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3952
SELECT + tab0.col2 / + ( col0 + col0 ) FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col1 col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-3954
SELECT - 28 - - 91 DIV + col1 FROM tab0 AS cor0
----
-27
-27
-28

skipif mysql # not compatible
query I rowsort label-3954
SELECT - 28 - - 91 / + col1 FROM tab0 AS cor0
----
-27
-27
-28

query I rowsort
SELECT cor0.col0 * - col1 - col2 AS col2 FROM tab2 cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL - ( col1 ) - + col2 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ( + col2 * + col0 ) + tab0.col0 + + ( col0 ) * + col1 AS col1 FROM tab0
----
15486
2880
3465

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3958
SELECT ALL CAST( NULL AS SIGNED ) + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3958
SELECT ALL CAST ( NULL AS INTEGER ) + col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 44 AS col1 FROM tab0 AS cor0
----
44

query I rowsort
SELECT ALL + + col2 + + col2 * 42 AS col0 FROM tab0 cor0
----
1419
3526
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-3961
SELECT ALL 77 DIV + cor0.col1 + - col1 AS col0 FROM tab1 AS cor0
----
-24
-3
-8

skipif mysql # not compatible
query I rowsort label-3961
SELECT ALL 77 / + cor0.col1 + - col1 AS col0 FROM tab1 AS cor0
----
-24
-3
-8

query I rowsort
SELECT ALL + col0 * col0 + cor0.col1 + col2 AS col2 FROM tab1 AS cor0
----
4163
6509
89

query I rowsort
SELECT ALL 2 + + cor0.col2 * - 11 + col1 * + col0 AS col1 FROM tab0 AS cor0
----
1703
3386
7199

query I rowsort
SELECT DISTINCT cor0.col2 * cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col2 * col1 + - 60 * - col0 col0 FROM tab1 AS cor0
----
1638
4467
6144

query I rowsort
SELECT ALL - 7 - col0 FROM tab2 AS cor0
----
-14
-85
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3967
SELECT 98 + - cor0.col1 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3967
SELECT 98 + - cor0.col1 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( col2 ) - - ( 91 + + col0 ) FROM tab0 AS cor0
----
127
148
262

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col1 * 51 col2 FROM tab1 AS cor0
----
1329
574
743

query I rowsort
SELECT ALL - 3 + + col1 FROM tab0 AS cor0
----
83
88
94

query I rowsort
SELECT - 64 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-102
-90
-91

query I rowsort
SELECT + cor0.col2 * 49 FROM tab0 AS cor0
----
1617
4018
49

query I rowsort
SELECT + col2 * + 5 AS col1 FROM tab2 AS cor0
----
130
135
190

query I rowsort
SELECT + col1 + + ( col0 ) * col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT - + col0 * - cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3976
SELECT DISTINCT + col1 - cor0.col2 DIV 14 AS col2 FROM tab1 AS cor0
----
23
6
7

skipif mysql # not compatible
query I rowsort label-3976
SELECT DISTINCT + col1 - cor0.col2 / 14 AS col2 FROM tab1 AS cor0
----
23
6
7

query I rowsort
SELECT ALL + + col1 * - 57 AS col0 FROM tab2 AS cor0
----
-1767
-3363
-969

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3978
SELECT ALL col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3978
SELECT ALL col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + + cor0.col1 col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL col2 * ( + col2 ) + col1 - 92 FROM tab0 AS cor0
----
1083
6
6723

query I rowsort
SELECT DISTINCT col1 * + ( 57 ) AS col2 FROM tab2 cor0
----
1767
3363
969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( col2 ) * + col0 col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3983
SELECT - CAST( NULL AS SIGNED ) - + cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3983
SELECT - CAST ( NULL AS INTEGER ) - + cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col0 - col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - + 54 AS col0 FROM tab2 AS cor0
----
-54

query I rowsort
SELECT - col0 + ( col2 ) * + col2 FROM tab0
----
-34
1065
6635

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3987
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - ( col1 ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3987
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - ( col1 ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT + 46 * + ( col1 ) FROM tab1 AS cor0
----
1196
460
598

query I rowsort
SELECT DISTINCT + col1 * + ( + col1 ) AS col2 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-3990
SELECT ( + ( col1 ) ) DIV 36 col1 FROM tab0 cor0
----
2
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3990
SELECT ( + ( col1 ) ) / 36 col1 FROM tab0 cor0
----
2
2
2

query I rowsort
SELECT ALL + ( ( + col0 ) ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - - ( + ( + cor0.col1 ) ) + col2 * col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT 70 * + 0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( ( col0 ) ) AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + cor0.col2 + - col2 * col0 FROM tab2 cor0
----
-2054
-216
-3040

query I rowsort
SELECT ALL + 21 * col0 AS col1 FROM tab1 AS cor0
----
1344
1680
63

query I rowsort
SELECT ALL ( + col1 ) * + col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - 51 AS col2 FROM tab2 AS cor0
----
-51

query I rowsort
SELECT - ( - col1 ) * col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + - col2 + 23 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1965
519
804

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4001
SELECT + CAST( - col0 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-4001
SELECT + CAST ( - col0 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4002
SELECT ALL - CAST( 7 AS SIGNED ) * + col1 - col2 FROM tab0
----
-635
-680
-719

skipif mysql # not compatible
query I rowsort label-4002
SELECT ALL - CAST ( 7 AS INTEGER ) * + col1 - col2 FROM tab0
----
-635
-680
-719

query I rowsort
SELECT + col1 * 73 + + col1 AS col1 FROM tab1 cor0
----
1924
740
962

query I rowsort
SELECT + col0 + - 10 + col1 AS col0 FROM tab1 AS cor0
----
19
64
83

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col2 * - 26 col0 FROM tab1
----
-199680
-4212
-94848

query I rowsort
SELECT col1 * + col1 + 51 + - col2 AS col1 FROM tab1
----
124
673
94

query I rowsort
SELECT + 0 * col1 AS col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 39 col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 68 + + col1 * + col0 col2 FROM tab2
----
-1241
-1619
2834

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 * col0 col1 FROM tab1
----
35
4106
6413

query I rowsort
SELECT + col0 * col0 + col1 * + tab2.col0 AS col0 FROM tab2
----
10686
266
7584

query I rowsort
SELECT ALL + tab1.col1 * - 37 FROM tab1
----
-370
-481
-962

query I rowsort
SELECT ALL 18 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 903ac227935c1532300db45a8537c595

query I rowsort
SELECT ALL - 97 FROM tab0, tab2, tab2 AS cor0, tab2 AS cor1
----
81 values hashing to a85708f93e08f0a017b33cd7912642fd

query I rowsort
SELECT - 42 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 9894093f29c0defae91347934f060329

onlyif mysql # use DIV operator for integer division
query I rowsort label-4017
SELECT DISTINCT col1 DIV + 72 + + col1 col2 FROM tab0 AS cor0
----
87
92
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4017
SELECT DISTINCT col1 / + 72 + + col1 col2 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT ALL + + cor0.col2 * ( - col2 ) FROM tab1 cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + 43 col2 FROM tab1 AS cor0
----
53
56
69

query IIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 WHERE ( NULL ) >= NULL
----

query I rowsort
SELECT + col1 * - col2 FROM tab2 cor0 WHERE NOT ( - col0 ) > NULL
----

query I rowsort
SELECT - col1 * + col2 * col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT + cor0.col0 + col1 * - col0 + - col2 AS col2 FROM tab0 AS cor0
----
-2073
-3361
-8092

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE ( NULL ) NOT IN ( + col1 + col0 * - col0 * col2 )
----

query I rowsort
SELECT DISTINCT col1 * - tab0.col1 * col1 AS col0 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT col1 * + col1 * col0 FROM tab1
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-4027
SELECT DISTINCT col1 DIV + col0 AS col1 FROM tab1
----
0
8

skipif mysql # not compatible
query I rowsort label-4027
SELECT DISTINCT col1 / + col0 AS col1 FROM tab1
----
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4028
SELECT col0 * + col1 + col1 DIV - col1 FROM tab2
----
1342
216
4601

skipif mysql # not compatible
query I rowsort label-4028
SELECT col0 * + col1 + col1 / - col1 FROM tab2
----
1342
216
4601

query I rowsort
SELECT DISTINCT col1 + col2 * col2 * col0 FROM tab1
----
207946
737293
8774

query III rowsort
SELECT * FROM tab2 WHERE NOT + col0 * - col2 > NULL
----

query I rowsort
SELECT ALL col0 + + tab2.col0 AS col0 FROM tab2
----
14
156
158

query I rowsort
SELECT DISTINCT col2 + col1 * - col0 FROM tab0 cor0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-4033
SELECT tab1.col2 DIV + tab1.col1 + tab1.col0 AS col1 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-4033
SELECT tab1.col2 / + tab1.col1 + tab1.col0 AS col1 FROM tab1
----
5
69
87

query I rowsort
SELECT DISTINCT col2 + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL col1 * - cor0.col2 + + col2 AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT + + col1 * col0 - - col2 * col1 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT + cor0.col2 * col0 - + col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-4038
SELECT - - col0 DIV cor0.col2 + + col2 * + col2 * col1 AS col0 FROM tab0 AS cor0
----
132
611885
93654

skipif mysql # not compatible
query I rowsort label-4038
SELECT - - col0 / cor0.col2 + + col2 * + col2 * col1 AS col0 FROM tab0 AS cor0
----
132
611885
93654

query I rowsort
SELECT ALL - cor0.col1 AS col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT - 50 AS col0 FROM tab0, tab1, tab1 AS cor0
----
-50

query I rowsort
SELECT - 40 AS col2 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 01aad4539198a6509248e086869f90a6

query I rowsort
SELECT 18 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to 162ac04886543cfd80f55de959076e4e

query I rowsort
SELECT 52 * + col1 AS col2 FROM tab2 AS cor0
----
1612
3068
884

query I rowsort
SELECT col1 * - col1 + - col0 AS col2 FROM tab1 AS cor0
----
-164
-249
-679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4045
SELECT - - col0 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4045
SELECT - - col0 * - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col0 * col1 col0 FROM tab2 cor0
----
-1422
-224
-4680

query I rowsort
SELECT col2 * ( - col1 * - col0 ) + col1 FROM tab1 cor0
----
36490
4238
99853

onlyif mysql # use DIV operator for integer division
query I rowsort label-4048
SELECT + - col1 DIV col1 + col2 col1 FROM tab2 cor0
----
25
26
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4048
SELECT + - col1 / col1 + col2 col1 FROM tab2 cor0
----
25
26
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-4049
SELECT + col1 * - CAST( - col2 AS SIGNED ) - + col1 DIV + col1 FROM tab2 AS cor0
----
1533
645
836

skipif mysql # not compatible
query I rowsort label-4049
SELECT + col1 * - CAST ( - col2 AS INTEGER ) - + col1 / + col1 FROM tab2 AS cor0
----
1533
645
836

query I rowsort
SELECT ALL + col2 * - 31 AS col1 FROM tab0 AS cor0
----
-1023
-2542
-31

query I rowsort
SELECT ALL cor0.col0 * + 72 FROM tab2 AS cor0
----
504
5616
5688

query I rowsort
SELECT - col1 - col2 * col1 AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-4053
SELECT DISTINCT - cor0.col2 DIV + col1 FROM tab2 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-4053
SELECT DISTINCT - cor0.col2 / + col1 FROM tab2 AS cor0
----
-2
0

query I rowsort
SELECT DISTINCT + 72 AS col0 FROM tab1, tab0, tab1 AS cor0
----
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 + col2 col1 FROM tab2
----
182
196
41

query III rowsort
SELECT * FROM tab2 WHERE + col2 < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - tab0.col2 * + col2 - col2 col1 FROM tab0
----
-1036
-6715
95

query I rowsort
SELECT + tab2.col0 + + col0 + tab2.col2 FROM tab2
----
182
196
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-4059
SELECT DISTINCT + col0 + + tab0.col0 DIV - col1 AS col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4059
SELECT DISTINCT + col0 + + tab0.col0 / - col1 AS col0 FROM tab0
----
24
35
89

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL IN ( - col1 * + tab0.col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4061
SELECT col2 DIV + col0 + + col1 * + tab0.col2 + + col2 FROM tab0
----
2872
7544
98

skipif mysql # not compatible
query I rowsort label-4061
SELECT col2 / + col0 + + col1 * + tab0.col2 + + col2 FROM tab0
----
2872
7544
98

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL BETWEEN col0 * col2 - - col1 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4063
SELECT tab2.col2 - - col0 DIV col1 FROM tab2
----
27
27
42

skipif mysql # not compatible
query I rowsort label-4063
SELECT tab2.col2 - - col0 / col1 FROM tab2
----
27
27
42

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT BETWEEN NULL AND col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4065
SELECT - col1 + col0 - - col0 DIV - col1 AS col0 FROM tab0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-4065
SELECT - col1 + col0 - - col0 / - col1 AS col0 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + col2 - + tab0.col2 FROM tab0
----
0

query I rowsort
SELECT col2 - tab0.col2 * col2 FROM tab0
----
-1056
-6642
0

query I rowsort
SELECT - col0 + + col2 AS col0 FROM tab1 WHERE - col2 BETWEEN NULL AND + col2 + + col0
----

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL NOT BETWEEN NULL AND col2
----

query I rowsort
SELECT DISTINCT - tab0.col0 - col2 AS col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT col1 FROM tab1 WHERE NULL BETWEEN NULL AND col2
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4072
SELECT ALL + + col0 * - CAST( NULL AS DECIMAL ) + - 90 * col0 * cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4072
SELECT ALL + + col0 * - CAST ( NULL AS REAL ) + - 90 * col0 * cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4073
SELECT col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4073
SELECT col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col1 * ( + col2 ) + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL col1 + + 0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL + 48 * col2 FROM tab1
----
2592
2736
4608

onlyif mysql # use DIV operator for integer division
query I rowsort label-4077
SELECT DISTINCT + col1 * col2 * - ( + col1 ) + - col2 DIV - col0 + + col0 AS col2 FROM tab2
----
-10903
-25937
-90428

skipif mysql # not compatible
query I rowsort label-4077
SELECT DISTINCT + col1 * col2 * - ( + col1 ) + - col2 / - col0 + + col0 AS col2 FROM tab2
----
-10903
-25937
-90428

query I rowsort
SELECT + col1 + + 96 FROM tab1 cor0
----
106
109
122

query I rowsort
SELECT - col1 * + 88 - col2 FROM tab1 AS cor0
----
-1240
-2342
-937

query I rowsort
SELECT ALL + col2 + - col0 * - col2 AS col1 FROM tab0
----
36
7380
825

query I rowsort
SELECT + col0 * col1 + + col1 - + col1 AS col0 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4082
SELECT ALL + + cor0.col1 + CAST( + col0 AS SIGNED ) * col0 FROM tab2 AS cor0
----
6143
6258
80

skipif mysql # not compatible
query I rowsort label-4082
SELECT ALL + + cor0.col1 + CAST ( + col0 AS INTEGER ) * col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + col1 * - 1 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - - col2 + 48 AS col0 FROM tab0 AS cor0
----
130
49
81

query I rowsort
SELECT ALL col1 * - 4 AS col0 FROM tab0 AS cor0
----
-344
-364
-388

query I rowsort
SELECT DISTINCT col0 + - ( col2 ) FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - col0 * - col0 + 98 AS col0 FROM tab0 AS cor0
----
1323
674
8019

query I rowsort
SELECT ALL col2 * - col2 + - col2 + col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - col2 + - ( + ( col0 ) ) FROM tab0 AS cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + cor0.col2 * + col2 col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT ( - col0 ) * - col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - 86 * 69 * + col2 FROM tab1 AS cor0
----
-320436
-338238
-569664

query I rowsort
SELECT - + ( + cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - ( col1 ) + col0 AS col1 FROM tab2 AS cor0
----
-24
19
62

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0 CROSS JOIN tab2, tab0 cor1
----
972 values hashing to 95de14c88adc44eda4adb5267fe9ebd1

query I rowsort
SELECT ALL + + col1 - col0 * 45 FROM tab0 cor0
----
-1478
-3914
-994

query I rowsort
SELECT ALL cor0.col2 + - col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + col1 col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + ( col1 ) + + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - col0 * - cor0.col2 - + col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL + col2 * + cor0.col1 + - col2 AS col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT 71 + + cor0.col1 FROM tab1 AS cor0
----
81
84
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4103
SELECT ALL + + col1 - col0 DIV col2 AS col1 FROM tab1 AS cor0
----
13
26
9

skipif mysql # not compatible
query I rowsort label-4103
SELECT ALL + + col1 - col0 / col2 AS col1 FROM tab1 AS cor0
----
13
26
9

query I rowsort
SELECT + - cor0.col1 * - col0 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL ( + col0 ) + cor0.col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + col1 + - col1 * + col2 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL - col1 + cor0.col1 * + col2 AS col2 FROM tab2 cor0
----
1475
629
806

query I rowsort
SELECT + col1 + col2 * + col2 AS col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL + + col2 - col0 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL - col2 + col1 * + col1 AS col0 FROM tab0 cor0
----
7363
8199
9408

query I rowsort
SELECT ALL cor0.col0 - col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col2 + col2 * col1 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - tab2.col1 + + col1 * col0 FROM tab2
----
1326
186
4543

query I rowsort
SELECT ALL + + 60 + - col0 * col0 AS col2 FROM tab0 AS cor0
----
-1165
-516
-7861

query I rowsort
SELECT + 85 * + 78 FROM tab1 AS cor0
----
6630
6630
6630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4116
SELECT ALL + + col1 DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4116
SELECT ALL + + col1 / col0 AS col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT col2 * 85 FROM tab2 cor0
----
2210
2295
3230

query I rowsort
SELECT ALL - col1 * ( col1 ) + cor0.col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT - - 73 * - 11 FROM tab1 AS cor0
----
-803
-803
-803

query I rowsort
SELECT cor1.col1 + + cor1.col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 0a66faf44289070d88fd26bbc9bf34e3

query I rowsort
SELECT DISTINCT - - col2 * - 67 AS col0 FROM tab0 cor0
----
-2211
-5494
-67

query I rowsort
SELECT DISTINCT - col0 * + 96 FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT ALL col0 - tab2.col2 * col0 AS col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL - col2 + - col0 - - col0 AS col2 FROM tab0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4125
SELECT + - CAST( NULL AS SIGNED ) * + col2 + - col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4125
SELECT + - CAST ( NULL AS INTEGER ) * + col2 + - col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - ( 65 ) + + col2 * col1 FROM tab2 AS cor0
----
1469
581
772

onlyif mysql # use DIV operator for integer division
query I rowsort label-4127
SELECT DISTINCT col1 + - cor0.col1 DIV + col1 AS col1 FROM tab2 cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-4127
SELECT DISTINCT col1 + - cor0.col1 / + col1 AS col1 FROM tab2 cor0
----
16
30
58

query I rowsort
SELECT ALL col1 * + col0 * col2 - col2 FROM tab0
----
3394
664036
68079

query I rowsort
SELECT + ( + col0 * - col2 ) + col2 * + col2 * col0 FROM tab0
----
0
25344
591138

query I rowsort
SELECT DISTINCT - col0 + - ( col2 ) + + col1 * col1 AS col2 FROM tab1
----
-21
-7
619

query I rowsort
SELECT ALL - ( col1 ) + + col0 + col0 AS col2 FROM tab1
----
-20
118
147

query I rowsort
SELECT DISTINCT - col2 + + 98 AS col0 FROM tab0
----
16
65
97

query I rowsort
SELECT ALL ( + ( col1 ) ) + col2 AS col2 FROM tab1
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( col2 ) col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT 2 * + col0 FROM tab2
----
14
156
158

query I rowsort
SELECT ALL 20 AS col2 FROM tab2 AS cor0
----
20
20
20

query I rowsort
SELECT ALL col2 + + col1 * - col2 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 8 * col0 + col1 * col1 col0 FROM tab2
----
-343
2857
905

query I rowsort
SELECT + + col1 * col1 * cor0.col0 + - ( cor0.col1 ) * + cor0.col1 AS col0 FROM tab2 AS cor0
----
22542
268037
5766

query I rowsort
SELECT DISTINCT ( col2 + - col0 ) AS col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL - ( tab2.col1 ) FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT + - cor0.col2 + 86 AS col1 FROM tab0 AS cor0
----
4
53
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4143
SELECT - ( - col1 ) DIV + col2 col1 FROM tab0 cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4143
SELECT - ( - col1 ) / + col2 col1 FROM tab0 cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 31 col2 FROM tab2 AS cor0
----
-31
-31
-31

query I rowsort
SELECT - cor0.col2 * - 89 FROM tab2 AS cor0
----
2314
2403
3382

query I rowsort
SELECT ALL col2 + 4 FROM tab0
----
37
5
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-4147
SELECT - - cor0.col0 + col0 DIV - col2 FROM tab1 cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-4147
SELECT - - cor0.col0 + col0 / - col2 FROM tab1 cor0
----
3
63
80

query I rowsort
SELECT - 7 * - col2 * col0 AS col0 FROM tab1
----
1134
25536
53760

query I rowsort
SELECT DISTINCT - 16 AS col1 FROM tab1, tab2 AS cor0
----
-16

query I rowsort
SELECT 50 AS col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT tab1.col2 * ( - tab1.col0 ) * ( tab1.col1 ) AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT col1 * 21 AS col2 FROM tab1 AS cor0
----
210
273
546

query I rowsort
SELECT - cor1.col0 FROM tab1, tab2 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT DISTINCT + cor0.col2 AS col0 FROM tab0, tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col2 * + ( - col2 + col1 ) AS col1 FROM tab1
----
-1512
-2679
-7968

onlyif mysql # use DIV operator for integer division
query I rowsort label-4156
SELECT + + col2 DIV ( col2 ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4156
SELECT + + col2 / ( col2 ) FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + ( 49 ) + col1 AS col2 FROM tab0 AS cor0
----
135
140
146

query I rowsort
SELECT + col0 + + cor0.col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + 0 col1 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4160
SELECT cor0.col1 + + cor0.col0 * - col0 DIV + col0 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-4160
SELECT cor0.col1 + + cor0.col0 * - col0 / + col0 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-4161
SELECT col0 * - ( col0 ) + - col0 DIV + ( - col2 ) FROM tab0
----
-1190
-576
-7920

skipif mysql # not compatible
query I rowsort label-4161
SELECT col0 * - ( col0 ) + - col0 / + ( - col2 ) FROM tab0
----
-1190
-576
-7920

query I rowsort
SELECT + tab2.col0 + - ( col1 ) FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT + - cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4164
SELECT CAST( - col0 AS SIGNED ) * col0 + - ( ( + col0 ) ) * 75 FROM tab2
----
-11934
-12166
-574

skipif mysql # not compatible
query I rowsort label-4164
SELECT CAST ( - col0 AS INTEGER ) * col0 + - ( ( + col0 ) ) * 75 FROM tab2
----
-11934
-12166
-574

query I rowsort
SELECT DISTINCT - col1 * col2 * col1 FROM tab1
----
-16224
-36504
-5700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4166
SELECT - CAST( + col0 AS SIGNED ) * - col1 + + col2 FROM tab2 AS cor0
----
1381
244
4628

skipif mysql # not compatible
query I rowsort label-4166
SELECT - CAST ( + col0 AS INTEGER ) * - col1 + + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT + 83 FROM tab2
----
83

query I rowsort
SELECT + 36 * - col0 * - col0 FROM tab2
----
1764
219024
224676

query I rowsort
SELECT DISTINCT + ( - col0 * tab2.col2 ) AS col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL - cor0.col2 - 82 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 387e1ef896a07e6b614cbcc35f62efa9

query I rowsort
SELECT - 92 * col2 AS col2 FROM tab2 AS cor0
----
-2392
-2484
-3496

query I rowsort
SELECT + - col0 * col0 + 75 * 57 FROM tab0 AS cor0
----
-3646
3050
3699

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4173
SELECT + col0 * CAST( NULL AS SIGNED ) + col0 * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4173
SELECT + col0 * CAST ( NULL AS INTEGER ) + col0 * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 + - col1 * col2 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + col1 * + col2 + 25 FROM tab1 AS cor0
----
1273
1429
595

query I rowsort
SELECT - ( col2 ) * col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT col1 + - ( - col0 ) AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col1 + 80 AS col2 FROM tab0 AS cor0
----
166
171
177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4179
SELECT DISTINCT cor0.col0 - CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4179
SELECT DISTINCT cor0.col0 - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - cor0.col0 * - 20 FROM tab0 AS cor0
----
1780
480
700

onlyif mysql # use DIV operator for integer division
query I rowsort label-4181
SELECT ALL - col1 DIV 72 + - ( + col0 ) FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4181
SELECT ALL - col1 / 72 + - ( + col0 ) FROM tab1 cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4182
SELECT DISTINCT - col2 * + col0 + - ( + col2 ) DIV - col1 FROM tab1 AS cor0
----
-160
-3643
-7673

skipif mysql # not compatible
query I rowsort label-4182
SELECT DISTINCT - col2 * + col0 + - ( + col2 ) / - col1 FROM tab1 AS cor0
----
-160
-3643
-7673

query I rowsort
SELECT ALL 8 AS col0 FROM tab2 cor0
----
8
8
8

query I rowsort
SELECT + 58 * - col0 AS col0 FROM tab2 AS cor0
----
-406
-4524
-4582

query I rowsort
SELECT ALL 23 * col2 FROM tab0 AS cor0
----
1886
23
759

query I rowsort
SELECT DISTINCT + ( col0 ) + col2 * - 50 FROM tab2 AS cor0
----
-1222
-1343
-1821

onlyif mysql # use DIV operator for integer division
query I rowsort label-4187
SELECT ( col1 ) DIV col1 + ( col2 ) AS col0 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-4187
SELECT ( col1 ) / col1 + ( col2 ) AS col0 FROM tab0
----
2
34
83

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
26
27
38

query I rowsort
SELECT DISTINCT 44 * col0 FROM tab1 AS cor0
----
132
2816
3520

query I rowsort
SELECT DISTINCT + - col0 * - col1 + - col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT + + ( + col2 ) * - 34 AS col2 FROM tab2 AS cor0
----
-1292
-884
-918

query I rowsort
SELECT ALL - 9 * - col2 FROM tab1
----
486
513
864

query I rowsort
SELECT DISTINCT - - col2 + - 68 AS col0 FROM tab1 AS cor0
----
-11
-14
28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4194
SELECT ALL - col2 - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4194
SELECT ALL - col2 - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * col1 + col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT 4 * + col1 FROM tab2
----
124
236
68

query I rowsort
SELECT ( + cor0.col1 ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4198
SELECT tab2.col2 * + tab2.col0 + CAST( NULL AS SIGNED ) * 88 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4198
SELECT tab2.col2 * + tab2.col0 + CAST ( NULL AS INTEGER ) * 88 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT 63 * + tab0.col0 + - CAST ( - col1 AS REAL ) FROM tab0
----
1598
2302
5698

query I rowsort
SELECT 43 * - 91 + - cor0.col1 * - col0 FROM tab0 cor0
----
-1849
-518
4186

query I rowsort
SELECT DISTINCT + 93 + cor0.col2 * + col1 FROM tab2 cor0
----
1627
739
930

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4202
SELECT ALL + CAST( col1 AS SIGNED ) * - cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-4202
SELECT ALL + CAST ( col1 AS INTEGER ) * - cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + 7 FROM tab2 cor0
----
7
7
7

query I rowsort
SELECT ALL col2 + col1 * cor0.col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT + 75 * 79 AS col1 FROM tab1 AS cor0
----
5925
5925
5925

query I rowsort
SELECT DISTINCT + 28 * + col2 * col2 AS col0 FROM tab0 AS cor0
----
188272
28
30492

query I rowsort
SELECT ALL - ( 9 ) * col0 AS col0 FROM tab1 AS cor0
----
-27
-576
-720

query I rowsort
SELECT col2 * ( + 10 ) + - col0 + ( col0 ) FROM tab2
----
260
270
380

query I rowsort
SELECT col1 * ( - col1 ) AS col0 FROM tab1
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4210
SELECT col2 * 76 + tab1.col1 * + col0 - + CAST( NULL AS SIGNED ) col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4210
SELECT col2 * 76 + tab1.col1 * + col0 - + CAST ( NULL AS INTEGER ) col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4211
SELECT + ( + col1 * col0 ) + ( 24 ) DIV + col0 FROM tab2
----
1343
220
4602

skipif mysql # not compatible
query I rowsort label-4211
SELECT + ( + col1 * col0 ) + ( 24 ) / + col0 FROM tab2
----
1343
220
4602

query I rowsort
SELECT + 18 + col0 FROM tab2 AS cor0
----
25
96
97

query I rowsort
SELECT DISTINCT - - 60 + col1 FROM tab0 AS cor0
----
146
151
157

query I rowsort
SELECT ALL - + cor0.col2 + - col2 AS col0 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT + + col0 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col2 * 5 AS col0 FROM tab1 cor0
----
-270
-285
-480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4217
SELECT - CAST( 58 AS SIGNED ) + col0 AS col1 FROM tab0 AS cor0
----
-23
-34
31

skipif mysql # not compatible
query I rowsort label-4217
SELECT - CAST ( 58 AS INTEGER ) + col0 AS col1 FROM tab0 AS cor0
----
-23
-34
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + 7 col0 FROM tab2 cor0
----
-49
-546
-553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4219
SELECT - CAST( col1 AS SIGNED ) + col2 + + 60 FROM tab2 AS cor0
----
27
56
81

skipif mysql # not compatible
query I rowsort label-4219
SELECT - CAST ( col1 AS INTEGER ) + col2 + + 60 FROM tab2 AS cor0
----
27
56
81

query I rowsort
SELECT ALL + tab1.col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - 0 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - cor0.col0 + col1 + - col2 FROM tab2 AS cor0
----
-100
-3
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4223
SELECT ALL col1 + - ( col2 ) + + 18 * tab0.col1 DIV col0 col2 FROM tab0
----
117
145
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4223
SELECT ALL col1 + - ( col2 ) + + 18 * tab0.col1 / col0 col2 FROM tab0
----
117
145
27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4224
SELECT ALL + CAST( NULL AS SIGNED ) * + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4224
SELECT ALL + CAST ( NULL AS INTEGER ) * + col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + col0 + cor0.col2 FROM tab2 AS cor0
----
182
196
41

query I rowsort
SELECT - 16 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 6a726f8493b62c5d4e1dd657007160c3

query I rowsort
SELECT DISTINCT + cor0.col0 + col0 * col2 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - 72 + - col0 FROM tab0
----
-107
-161
-96

query I rowsort
SELECT ALL 80 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

onlyif mysql # use DIV operator for integer division
query I rowsort label-4230
SELECT ALL - + 9 + col1 DIV + col0 FROM tab2 AS cor0
----
-5
-9
-9

skipif mysql # not compatible
query I rowsort label-4230
SELECT ALL - + 9 + col1 / + col0 FROM tab2 AS cor0
----
-5
-9
-9

query I rowsort
SELECT DISTINCT + - 70 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-63
8
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4232
SELECT ALL + - ( + col2 ) + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4232
SELECT ALL + - ( + col2 ) + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 40 * - col1 + + cor0.col2 AS col1 FROM tab0 cor0
----
3473
3722
3881

query I rowsort
SELECT + - col2 + + col1 + - col1 AS col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - cor0.col1 + col1 + col2 * - col2 * - col2 FROM tab2 AS cor0
----
17576
19683
54872

query I rowsort
SELECT - 96 + col0 AS col2 FROM tab1 AS cor0
----
-16
-32
-93

query I rowsort
SELECT col0 + + 29 AS col2 FROM tab0 cor0
----
118
53
64

query I rowsort
SELECT ALL + + col0 + ( col1 ) + - col2 FROM tab2 cor0
----
11
111
58

query I rowsort
SELECT DISTINCT col1 * - col2 - cor0.col2 AS col0 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT - col1 + 8 + col0 FROM tab0
----
-54
-54
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4241
SELECT ALL + CAST( NULL AS SIGNED ) * cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4241
SELECT ALL + CAST ( NULL AS INTEGER ) * cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - col1 * - ( - col2 ) + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT + + col2 * - 10 AS col2 FROM tab0 AS cor0
----
-10
-330
-820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col1 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - + col2 * + ( - col1 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL col2 + + ( + col2 ) AS col2 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT DISTINCT + - col1 - col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + col2 * + 77 AS col0 FROM tab2 AS cor0
----
2002
2079
2926

query I rowsort
SELECT - col0 * 19 FROM tab1 AS cor0
----
-1216
-1520
-57

query I rowsort
SELECT ALL col2 + cor0.col0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) + col0 col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - col1 - + 66 AS col0 FROM tab2 AS cor0
----
-125
-83
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( cor0.col0 ) + col1 * col0 col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - + 6 AS col0 FROM tab2 AS cor0
----
-6
-6
-6

query I rowsort
SELECT + + ( 14 ) AS col2 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT ALL - ( col0 ) + + col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + 37 AS col0 FROM tab2 cor0
----
37
37
37

query I rowsort
SELECT ALL - col0 + ( col0 ) AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + + 98 AS col2 FROM tab0 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT ALL col2 - - col0 * col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT col0 + col0 + ( + col2 + cor0.col1 * col1 ) FROM tab1 cor0
----
285
425
736

query I rowsort
SELECT + - 83 AS col1 FROM tab2 AS cor0
----
-83
-83
-83

query I rowsort
SELECT + col1 + ( + col0 ) * + col0 AS col1 FROM tab1 AS cor0
----
35
4106
6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 59 col2 FROM tab0 AS cor0
----
-23
26
58

query I rowsort
SELECT cor0.col0 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * col2 col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col0 * 85 FROM tab0 AS cor0
----
2040
2975
7565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4268
SELECT - - CAST( + col1 AS SIGNED ) * + col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-4268
SELECT - - CAST ( + col1 AS INTEGER ) * + col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT 32 * col1 FROM tab0 AS cor0
----
2752
2912
3104

query I rowsort
SELECT col2 * ( cor0.col2 ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 88 FROM tab2, tab1, tab1 AS cor0
----
88

query I rowsort
SELECT - - 72 FROM tab1 AS cor0
----
72
72
72

query I rowsort
SELECT col1 + 54 * col1 AS col0 FROM tab0
----
4730
5005
5335

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) col2 FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 11 + 54 col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

query I rowsort
SELECT DISTINCT ( - col1 ) * + col2 AS col2 FROM tab1
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4277
SELECT + col0 + + col2 + - CAST( - 66 AS SIGNED ) FROM tab2 AS cor0
----
100
170
183

skipif mysql # not compatible
query I rowsort label-4277
SELECT + col0 + + col2 + - CAST ( - 66 AS INTEGER ) FROM tab2 AS cor0
----
100
170
183

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4278
SELECT + + CAST( NULL AS DECIMAL ) * - 95 * - cor0.col0 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4278
SELECT + + CAST ( NULL AS REAL ) * - 95 * - cor0.col0 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - 35 AS col2 FROM tab1
----
-35
-35
-35

query I rowsort
SELECT + 37 * + col0 * - tab0.col2 FROM tab0
----
-1295
-270026
-29304

query I rowsort
SELECT DISTINCT + + cor0.col0 + - col1 * - 22 FROM tab2 AS cor0
----
1376
453
689

query I rowsort
SELECT ALL 93 + + tab2.col1 AS col1 FROM tab2
----
110
124
152

onlyif mysql # use DIV operator for integer division
query I rowsort label-4283
SELECT DISTINCT + ( cor0.col0 ) DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4283
SELECT DISTINCT + ( cor0.col0 ) / cor0.col0 AS col0 FROM tab1 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4284
SELECT ALL 91 * col1 + - col0 DIV 53 FROM tab1 AS cor0
----
1182
2366
909

skipif mysql # not compatible
query I rowsort label-4284
SELECT ALL 91 * col1 + - col0 / 53 FROM tab1 AS cor0
----
1182
2366
909

query I rowsort
SELECT + 21 + - col1 + col2 * col2 FROM tab0 AS cor0
----
-75
1024
6654

onlyif mysql # use DIV operator for integer division
query I rowsort label-4286
SELECT + col0 DIV + col0 col2 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4286
SELECT + col0 / + col0 col2 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL + 35 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT + tab1.col0 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * 2 + col1 col2 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT - col2 * + col1 + - col0 * 74 FROM tab0 AS cor0
----
-14048
-2687
-4614

query I rowsort
SELECT - - col2 - 76 FROM tab2 AS cor0
----
-38
-49
-50

query I rowsort
SELECT - + 92 * col1 + col0 * + col0 FROM tab1 AS cor0
----
-2383
3176
5204

query I rowsort
SELECT ALL - col0 + - 29 * - 99 AS col1 FROM tab0
----
2782
2836
2847

query I rowsort
SELECT col0 * - 48 AS col2 FROM tab2 AS cor0
----
-336
-3744
-3792

query I rowsort
SELECT col0 * tab0.col2 * + col0 + col2 FROM tab0
----
1226
19041
649604

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab2 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to ca91d1f523a87017f672304548e91a77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4298
SELECT DISTINCT + cor0.col1 DIV - ( + 81 ) AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4298
SELECT DISTINCT + cor0.col1 / - ( + 81 ) AS col1 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4299
SELECT DISTINCT col1 DIV + col1 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4299
SELECT DISTINCT col1 / + col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT ALL col0 + + 77 AS col0 FROM tab1 AS cor0
----
141
157
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4301
SELECT DISTINCT - col0 DIV 90 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4301
SELECT DISTINCT - col0 / 90 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + col1 * + ( cor0.col2 ) AS col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4303
SELECT - col2 * CAST( col2 AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
-611884
-93654
-97

skipif mysql # not compatible
query I rowsort label-4303
SELECT - col2 * CAST ( col2 AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT col0 + + col1 * col2 AS col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT ( col2 ) + col0 * + ( col0 ) FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - cor0.col1 + - col1 * col0 * cor0.col2 FROM tab2 AS cor0
----
-119711
-51051
-5890

query I rowsort
SELECT ALL - 63 * - cor0.col2 FROM tab1 AS cor0
----
3402
3591
6048

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4308
SELECT ALL ( 34 ) + col0 + - CAST( + 9 + + col0 AS SIGNED ) * 35 FROM tab1 AS cor0
----
-2457
-3001
-383

skipif mysql # not compatible
query I rowsort label-4308
SELECT ALL ( 34 ) + col0 + - CAST ( + 9 + + col0 AS INTEGER ) * 35 FROM tab1 AS cor0
----
-2457
-3001
-383

query I rowsort
SELECT ALL + + 36 AS col0 FROM tab0 AS cor0
----
36
36
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-4310
SELECT DISTINCT ( - cor0.col0 ) * col0 + 56 DIV col1 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-4310
SELECT DISTINCT ( - cor0.col0 ) * col0 + 56 / col1 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( + col1 AS REAL ) - + col0 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4312
SELECT ALL + CAST( col2 AS SIGNED ) - - col1 col2 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4312
SELECT ALL + CAST ( col2 AS INTEGER ) - - col1 col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - col1 + cor0.col1 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
272
3422
930

onlyif mysql # use DIV operator for integer division
query I rowsort label-4314
SELECT ALL + ( col2 ) * col2 DIV + 51 AS col2 FROM tab0 cor0
----
0
131
21

skipif mysql # not compatible
query I rowsort label-4314
SELECT ALL + ( col2 ) * col2 / + 51 AS col2 FROM tab0 cor0
----
0
131
21

query I rowsort
SELECT ALL - + ( + ( col1 ) ) * 63 + col0 AS col1 FROM tab1 AS cor0
----
-1635
-566
-739

query I rowsort
SELECT DISTINCT + 58 + col2 FROM tab2 AS cor0
----
84
85
96

query I rowsort
SELECT ALL + col0 * 83 FROM tab0 cor0
----
1992
2905
7387

query I rowsort
SELECT DISTINCT col2 * 83 + - tab2.col0 FROM tab2
----
2080
2234
3075

query I rowsort
SELECT DISTINCT + col2 + - 67 AS col1 FROM tab0
----
-34
-66
15

query I rowsort
SELECT ALL + cor0.col1 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT + ( 29 ) AS col2 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT DISTINCT col0 + + ( cor0.col0 ) * - 48 FROM tab1 AS cor0
----
-141
-3008
-3760

query I rowsort
SELECT DISTINCT + col1 + - 84 AS col2 FROM tab2 AS cor0
----
-25
-53
-67

query I rowsort
SELECT DISTINCT col1 * + 57 + col0 * col1 FROM tab2
----
1984
2312
7965

query I rowsort
SELECT - 27 + col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
162
2001
2975

query I rowsort
SELECT - col1 * - col1 + 25 AS col0 FROM tab1 AS cor0
----
125
194
701

query I rowsort
SELECT DISTINCT col0 * + col0 * + col2 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT col2 + col1 * col0 FROM tab2 AS cor0
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 43 col2 FROM tab0 AS cor0
----
43
43
43

query I rowsort
SELECT - col2 + - col0 - + 77 FROM tab1 AS cor0
----
-134
-198
-253

query I rowsort
SELECT + 7 * - col0 + col1 FROM tab2 AS cor0
----
-18
-487
-536

query I rowsort
SELECT DISTINCT - + col0 + - col2 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT - cor0.col0 - - col0 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL + ( 89 ) AS col0 FROM tab2
----
89
89
89

query I rowsort
SELECT ALL cor0.col0 + col1 * + cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL col1 + - col2 * cor0.col1 * 30 FROM tab0 AS cor0
----
-223769
-2813
-85054

query I rowsort
SELECT DISTINCT + - 93 FROM tab0 AS cor0
----
-93

query I rowsort
SELECT col1 + - col0 - + 67 * + ( - col2 + col0 ) FROM tab2 AS cor0
----
-2809
-3503
1364

onlyif mysql # use DIV operator for integer division
query I rowsort label-4339
SELECT DISTINCT + col0 DIV + col0 AS col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-4339
SELECT DISTINCT + col0 / + col0 AS col2 FROM tab0
----
1

query I rowsort
SELECT ALL + 2 * col2 AS col0 FROM tab0
----
164
2
66

query I rowsort
SELECT ALL - tab0.col1 - col1 AS col2 FROM tab0
----
-172
-182
-194

query I rowsort
SELECT ALL + col2 * 89 + col2 AS col2 FROM tab1 AS cor0
----
4860
5130
8640

query I rowsort
SELECT ALL 33 + col1 - - col1 AS col1 FROM tab0
----
205
215
227

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + ( - 89 ) - col1 col1 FROM tab2 AS cor0
----
-123
-151
-207

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) + - ( - col2 ) col2 FROM tab2
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4346
SELECT - col1 * + CAST( col0 AS SIGNED ) * + col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

skipif mysql # not compatible
query I rowsort label-4346
SELECT - col1 * + CAST ( col0 AS INTEGER ) * + col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT - + col2 + + ( 89 ) AS col2 FROM tab2 AS cor0
----
51
62
63

query I rowsort
SELECT + col1 * ( col2 ) - + col1 AS col1 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4349
SELECT + col1 + col0 DIV + col2 FROM tab1 cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-4349
SELECT + col1 + col0 / + col2 FROM tab1 cor0
----
11
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4350
SELECT ALL col1 * - col2 + - col2 DIV - ( + col2 ) AS col2 FROM tab0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-4350
SELECT ALL col1 * - col2 + - col2 / - ( + col2 ) AS col2 FROM tab0
----
-2837
-7461
-96

query I rowsort
SELECT + col0 * + col1 + + 78 + col1 AS col0 FROM tab2
----
1438
326
4739

query I rowsort
SELECT 72 + - col0 FROM tab1
----
-8
69
8

query I rowsort
SELECT - col2 * - col1 + col0 AS col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT 79 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4355
SELECT DISTINCT + col2 + 76 DIV - 85 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4355
SELECT DISTINCT + col2 + 76 / - 85 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + - col0 + 56 AS col1 FROM tab2 AS cor0
----
-22
-23
49

query I rowsort
SELECT - 93 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to ea79c61f7a02d25805171f5e85229fba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4358
SELECT cor0.col0 + + CAST( NULL AS SIGNED ) / 68 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4358
SELECT cor0.col0 + + CAST ( NULL AS INTEGER ) / 68 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * - 85 + - col2 AS col0 FROM tab1 AS cor0
----
1009
2156
793

query I rowsort
SELECT DISTINCT + - col1 + + 18 * cor0.col0 AS col0 FROM tab1 AS cor0
----
1142
1427
28

query I rowsort
SELECT ALL col0 + - col2 AS col1 FROM tab2 cor0
----
-20
41
52

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 9ed1a6a444254225f040123c46b7f70c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4363
SELECT DISTINCT - CAST( col1 AS SIGNED ) - cor0.col0 FROM tab2 AS cor0
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-4363
SELECT DISTINCT - CAST ( col1 AS INTEGER ) - cor0.col0 FROM tab2 AS cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( - col2 ) * + col2 + ( - col1 ) col2 FROM tab1 AS cor0
----
2890
3239
9203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4365
SELECT ALL - CAST( NULL AS SIGNED ) + + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4365
SELECT ALL - CAST ( NULL AS INTEGER ) + + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( col2 ) * - col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + + 60 col1 FROM tab1 AS cor0
----
124
140
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4368
SELECT DISTINCT + + ( col0 ) DIV - ( + col1 ) + + col2 AS col1 FROM tab2 cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-4368
SELECT DISTINCT + + ( col0 ) / - ( + col1 ) + + col2 AS col1 FROM tab2 cor0
----
25
27
34

query I rowsort
SELECT + - 86 * col2 + col0 * 67 FROM tab0 cor0
----
-1089
-1230
2259

query I rowsort
SELECT DISTINCT + 7 - - col2 AS col1 FROM tab1 AS cor0
----
103
61
64

query I rowsort
SELECT - + 0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 4 + cor0.col1 AS col1 FROM tab1 AS cor0
----
22
6
9

query I rowsort
SELECT ALL - - col1 * - col2 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + col2 + + col1 * + col2 * - col2 FROM tab1 AS cor0
----
-119712
-32433
-75762

query I rowsort
SELECT ALL col2 FROM tab0 WHERE NULL IN ( col0 ) AND + col1 NOT BETWEEN - col0 AND ( NULL )
----

query I rowsort
SELECT - col1 * col1 * tab1.col1 AS col0 FROM tab1
----
-1000
-17576
-2197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 * - col1 col0 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT col0 * col0 * col2 FROM tab1
----
233472
486
614400

query I rowsort
SELECT col1 - col2 * col2 AS col1 FROM tab0
----
-1003
-6633
96

query III rowsort
SELECT * FROM tab0 WHERE NOT col2 / + col2 >= NULL
----

query I rowsort
SELECT + tab0.col1 AS col1 FROM tab1 cor0 CROSS JOIN tab0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT NULL = + col1 OR ( NULL ) = NULL
----

query I rowsort
SELECT + col2 + col2 * cor0.col1 + col1 FROM tab0 AS cor0
----
195
2957
7635

onlyif mysql # use DIV operator for integer division
query I rowsort label-4384
SELECT - col2 DIV col0 col0 FROM tab2
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4384
SELECT - col2 / col0 col0 FROM tab2
----
-3
0
0

query I rowsort
SELECT ALL 34 + + col1 * col1 AS col2 FROM tab2
----
323
3515
995

query I rowsort
SELECT DISTINCT - col0 + col2 * col0 * - col2 FROM tab0 AS cor0
----
-26160
-598525
-70

query I rowsort
SELECT ALL + cor0.col2 * col1 * - col2 - col1 AS col1 FROM tab1 cor0
----
-119821
-32500
-75842

query I rowsort
SELECT + col2 * - col0 + col0 * - col1 FROM tab2 AS cor0
----
-406
-4345
-6630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4389
SELECT 90 DIV col0 FROM tab2
----
1
1
12

skipif mysql # not compatible
query I rowsort label-4389
SELECT 90 / col0 FROM tab2
----
1
1
12

query I rowsort
SELECT - - col2 * col0 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT - col1 * col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT col2 * tab1.col0 AS col0 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4393
SELECT DISTINCT 18 DIV col1 + col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4393
SELECT DISTINCT 18 / col1 + col2 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 col0 FROM tab0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col1 * col1 col0 FROM tab0
----
244068
679042
9409

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT + col0 + tab1.col0 < NULL
----

query I rowsort
SELECT DISTINCT col0 * tab2.col0 + col0 AS col1 FROM tab2 WHERE col0 + col2 * col1 IN ( - col2 )
----

query I rowsort
SELECT DISTINCT + tab0.col1 + - col0 + col1 * tab0.col0 AS col2 FROM tab0
----
2126
3457
8101

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + col0 - - col0 * col0 col1 FROM tab1
----
38
4170
6493

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL NOT IN ( + col0 / col1 + col1 )
----

query I rowsort
SELECT col2 * - col0 * - col1 AS col0 FROM tab1
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 * col1 col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT col2 * + col0 * - col0 FROM tab1 WHERE NULL IN ( - col1 )
----

query I rowsort
SELECT - col2 * - col2 * col1 + - tab0.col1 + col2 AS col2 FROM tab0
----
1
611875
93601

query I rowsort
SELECT + col2 + + col0 FROM tab2 WHERE NULL > ( - col2 + + col1 )
----

query I rowsort
SELECT ALL col0 - col2 * tab1.col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT + col0 FROM tab1 WHERE NOT NULL IN ( - col0 * col2 + - col0 )
----

query I rowsort
SELECT + tab0.col1 * col0 + col2 * - col2 AS col2 FROM tab0
----
1375
3394
975

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( NULL ) NOT IN ( col2 )
----

query I rowsort
SELECT DISTINCT + 54 * + col0 FROM tab2 AS cor0
----
378
4212
4266

query I rowsort
SELECT + + 60 AS col1 FROM tab2 AS cor0
----
60
60
60

query I rowsort
SELECT ALL 78 + col1 AS col0 FROM tab1 AS cor0
----
104
88
91

query I rowsort
SELECT ALL + 46 FROM tab2 cor0
----
46
46
46

query I rowsort
SELECT col2 * col0 + - col0 + col2 * col0 FROM tab2
----
371
3978
5925

query I rowsort
SELECT ALL + cor0.col1 * - cor0.col0 + 22 * - 25 AS col0 FROM tab2 AS cor0
----
-1893
-5152
-767

query I rowsort
SELECT ALL tab0.col0 * + tab0.col1 FROM tab0 WHERE NULL <> NULL
----

query I rowsort
SELECT ALL col2 * col0 * col1 + - col0 AS col1 FROM tab0
----
3360
664029
68088

onlyif mysql # use DIV operator for integer division
query I rowsort label-4418
SELECT tab0.col0 - col1 DIV + col1 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-4418
SELECT tab0.col0 - col1 / + col1 FROM tab0
----
23
34
88

query I rowsort
SELECT DISTINCT - col0 * tab0.col1 + col0 * col2 AS col0 FROM tab0
----
-1272
-3360
-801

onlyif mysql # use DIV operator for integer division
query I rowsort label-4420
SELECT col0 DIV col1 + + col0 AS col2 FROM tab1
----
3
70
86

skipif mysql # not compatible
query I rowsort label-4420
SELECT col0 / col1 + + col0 AS col2 FROM tab1
----
3
70
86

query I rowsort
SELECT DISTINCT col0 - + col2 FROM tab1 WHERE - col0 IN ( col1 * col2 )
----

query I rowsort
SELECT col0 FROM tab0 WHERE NOT NULL IN ( col0 + + col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * tab2.col1 col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL + ( col1 ) + + col2 * - 73 - col2 AS col1 FROM tab1
----
-3970
-4208
-7091

query I rowsort
SELECT - 74 * col2 FROM tab0 cor0
----
-2442
-6068
-74

query I rowsort
SELECT + col1 * ( col1 ) - - ( - col1 + col1 ) AS col1 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-4427
SELECT + col0 + col0 DIV + 56 AS col0 FROM tab0 AS cor0
----
24
35
90

skipif mysql # not compatible
query I rowsort label-4427
SELECT + col0 + col0 / + 56 AS col0 FROM tab0 AS cor0
----
24
35
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4428
SELECT DISTINCT col0 * tab0.col0 + tab0.col1 DIV tab0.col1 FROM tab0
----
1226
577
7922

skipif mysql # not compatible
query I rowsort label-4428
SELECT DISTINCT col0 * tab0.col0 + tab0.col1 / tab0.col1 FROM tab0
----
1226
577
7922

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( cor0.col1 ) col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT - 88 * + col0 AS col0 FROM tab0 AS cor0
----
-2112
-3080
-7832

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to b6efe6f7ec1a3daa3cc6ea9dd7d13455

query I rowsort
SELECT ALL - 93 * + col1 FROM tab2 AS cor0
----
-1581
-2883
-5487

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - + 60 + - col0 FROM tab0 cor0
----
-149
-84
-95

query I rowsort
SELECT col0 * ( - col1 ) + col0 * - col2 AS col2 FROM tab2
----
-406
-4345
-6630

query I rowsort
SELECT DISTINCT - - col0 + + 32 FROM tab1 AS cor0
----
112
35
96

query I rowsort
SELECT ALL + col2 + + col2 * + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL - cor0.col0 - - 66 FROM tab2 AS cor0
----
-12
-13
59

query I rowsort
SELECT + + col0 * 34 AS col2 FROM tab1 AS cor0
----
102
2176
2720

onlyif mysql # use DIV operator for integer division
query I rowsort label-4440
SELECT ALL col2 DIV 93 + + col0 * col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-4440
SELECT ALL col2 / 93 + + col0 * col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - + cor0.col2 * ( + col0 ) * + col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT - + cor0.col0 * cor0.col0 + col0 * + col0 * - cor0.col1 FROM tab2 AS cor0
----
-112338
-1568
-365040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4443
SELECT ALL - - CAST( col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4443
SELECT ALL - - CAST ( col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + col2 + + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + ( + cor0.col0 ) + + col0 AS col2 FROM tab0 cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + ( - cor0.col2 ) col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ( + col2 ) + - cor0.col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT col2 + + 40 AS col2 FROM tab0 AS cor0
----
122
41
73

query I rowsort
SELECT ALL + + ( + col1 ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT 94 * + cor0.col1 + col1 * cor0.col1 * + col0 AS col2 FROM tab2 cor0
----
24429
277064
9641

query I rowsort
SELECT + 63 * + 90 FROM tab1 AS cor0
----
5670
5670
5670

query I rowsort
SELECT 89 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT ALL - + 96 * 62 AS col1 FROM tab2 AS cor0
----
-5952
-5952
-5952

query I rowsort
SELECT DISTINCT + 5 * - col1 + + col1 FROM tab2 AS cor0
----
-124
-236
-68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 64 * col0 col0 FROM tab0 cor0
----
1536
2240
5696

query I rowsort
SELECT ALL + 65 + - col0 AS col1 FROM tab1 AS cor0
----
-15
1
62

query I rowsort
SELECT DISTINCT + - ( 64 ) FROM tab2 AS cor0
----
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-4458
SELECT DISTINCT ( - col0 ) + - col0 DIV + 64 FROM tab2 AS cor0
----
-7
-79
-80

skipif mysql # not compatible
query I rowsort label-4458
SELECT DISTINCT ( - col0 ) + - col0 / + 64 FROM tab2 AS cor0
----
-7
-79
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4459
SELECT ALL - + CAST( - col0 AS SIGNED ) * - col1 + + 81 DIV col0 FROM tab2 AS cor0
----
-1342
-206
-4601

skipif mysql # not compatible
query I rowsort label-4459
SELECT ALL - + CAST ( - col0 AS INTEGER ) * - col1 + + 81 / col0 FROM tab2 AS cor0
----
-1342
-206
-4601

onlyif mysql # use DIV operator for integer division
query I rowsort label-4460
SELECT ALL col0 DIV - col2 + - col1 AS col0 FROM tab0 AS cor0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-4460
SELECT ALL col0 / - col2 + - col1 AS col0 FROM tab0 AS cor0
----
-132
-86
-92

query I rowsort
SELECT ALL - - col1 * col1 + col1 AS col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + - 65 - cor0.col0 * col2 AS col0 FROM tab0 AS cor0
----
-100
-7363
-857

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 32 col0 FROM tab0
----
32
32
32

query I rowsort
SELECT cor0.col1 * 94 FROM tab0 AS cor0
----
8084
8554
9118

onlyif mysql # use DIV operator for integer division
query I rowsort label-4465
SELECT DISTINCT - 1 * 94 + + col1 * cor0.col1 DIV col0 AS col1 FROM tab1 cor0
----
-92
-93
131

skipif mysql # not compatible
query I rowsort label-4465
SELECT DISTINCT - 1 * 94 + + col1 * cor0.col1 / col0 AS col1 FROM tab1 cor0
----
-92
-93
131

onlyif mysql # use DIV operator for integer division
query I rowsort label-4466
SELECT + 42 DIV col2 + - cor0.col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4466
SELECT + 42 / col2 + - cor0.col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - col2 * col0 + - col1 * + cor0.col0 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT - ( col2 * col1 ) + - col2 * col0 * col1 FROM tab2
----
-121186
-51680
-6696

query I rowsort
SELECT + col0 + 55 AS col1 FROM tab1
----
119
135
58

query I rowsort
SELECT - 59 + col1 AS col0 FROM tab2
----
-28
-42
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 47 col1 FROM tab2, tab2 cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT + 44 + + 14 * col0 FROM tab0
----
1290
380
534

query I rowsort
SELECT - col2 * 56 + - 48 * col0 AS col1 FROM tab0 AS cor0
----
-1736
-3000
-8864

query I rowsort
SELECT ALL cor0.col0 + ( + col2 ) * col0 AS col1 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT col0 + col2 * - 3 + - col1 FROM tab0 AS cor0
----
-161
-248
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 12 col1 FROM tab1 AS cor0
----
15
76
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-4477
SELECT ALL - col2 + ( cor0.col0 ) DIV col0 - + col0 * col1 FROM tab1 cor0
----
-1135
-131
-696

skipif mysql # not compatible
query I rowsort label-4477
SELECT ALL - col2 + ( cor0.col0 ) / col0 - + col0 * col1 FROM tab1 cor0
----
-1135
-131
-696

query I rowsort
SELECT DISTINCT + col2 + - 19 FROM tab2 AS cor0
----
19
7
8

query I rowsort
SELECT DISTINCT - tab0.col2 + col0 * - ( 88 * col2 ) + - col0 FROM tab0
----
-3116
-642395
-69753

query I rowsort
SELECT ALL + col2 * + col1 + col0 AS col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL tab2.col0 + + tab2.col2 + - 22 FROM tab2
----
12
82
95

query I rowsort
SELECT - col1 + ( cor0.col1 ) * + col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT - tab1.col0 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT DISTINCT 91 + - tab1.col2 FROM tab1
----
-5
34
37

query I rowsort
SELECT ALL - 49 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT DISTINCT + col2 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - col1 + + col1 * cor0.col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT ALL - col0 * + 43 FROM tab2 AS cor0
----
-301
-3354
-3397

query I rowsort
SELECT DISTINCT + col0 * + cor0.col2 AS col0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4490
SELECT + CAST( NULL AS DECIMAL ) * - tab2.col0 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4490
SELECT + CAST ( NULL AS REAL ) * - tab2.col0 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4491
SELECT + col1 * cor0.col2 + - 14 DIV col0 AS col2 FROM tab2 AS cor0
----
1534
646
835

skipif mysql # not compatible
query I rowsort label-4491
SELECT + col1 * cor0.col2 + - 14 / col0 AS col2 FROM tab2 AS cor0
----
1534
646
835

query I rowsort
SELECT - + col1 * + ( - col0 + - col2 ) AS col1 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT col1 + - col1 * 94 AS col0 FROM tab0 AS cor0
----
-7998
-8463
-9021

query I rowsort
SELECT - col2 + col2 * - col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT + col0 + ( + col0 ) * cor0.col0 * col2 AS col2 FROM tab0 cor0
----
1260
19032
649611

query I rowsort
SELECT ALL col0 + col0 + - col2 AS col2 FROM tab2
----
-13
120
130

query I rowsort
SELECT + 33 * col1 FROM tab1
----
330
429
858

query I rowsort
SELECT - - col0 + col0 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + - cor0.col2 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + 12 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT ALL tab1.col1 * tab1.col1 + - col0 FROM tab1
----
36
673
89

query I rowsort
SELECT cor0.col2 + + col0 FROM tab0 cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4503
SELECT - - col2 * cor0.col0 DIV - col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-4503
SELECT - - col2 * cor0.col0 / - col0 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4504
SELECT ALL 97 DIV + col0 FROM tab0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-4504
SELECT ALL 97 / + col0 FROM tab0
----
1
2
4

query I rowsort
SELECT 90 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT + 36 - col2 * ( cor0.col1 + cor0.col1 ) * + col0 FROM tab0 AS cor0
----
-1328200
-136188
-6754

query I rowsort
SELECT - 14 + cor0.col2 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 0dd73e1900a6e303ac8d0aff2b170c56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 63 col0 FROM tab1
----
63
63
63

query I rowsort
SELECT - + 60 * - col0 FROM tab2 AS cor0
----
420
4680
4740

query I rowsort
SELECT + col0 * col0 - + col2 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT DISTINCT + 15 FROM tab0, tab2 AS cor0
----
15

query I rowsort
SELECT col1 - col1 * - 15 AS col1 FROM tab2 AS cor0
----
272
496
944

query I rowsort
SELECT col1 * - cor0.col0 - col2 * + col1 FROM tab0 AS cor0
----
-15561
-3492
-4902

query I rowsort
SELECT ALL - ( + 76 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT ALL + cor0.col1 - + 42 * cor0.col1 FROM tab0 AS cor0
----
-3526
-3731
-3977

query I rowsort
SELECT ALL + col2 * ( + col1 ) * + col0 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT tab1.col1 FROM tab1, tab2 AS cor0, tab1 cor1
----
10
13
26

query I rowsort
SELECT + - 3 * col2 AS col1 FROM tab0 cor0
----
-246
-3
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4519
SELECT 8 * 63 + cor0.col2 * CAST( 52 AS SIGNED ) * + col1 AS col0 FROM tab0 AS cor0
----
148080
388528
5548

skipif mysql # not compatible
query I rowsort label-4519
SELECT 8 * 63 + cor0.col2 * CAST ( 52 AS INTEGER ) * + col1 AS col0 FROM tab0 AS cor0
----
148080
388528
5548

onlyif mysql # use DIV operator for integer division
query I rowsort label-4520
SELECT DISTINCT + col2 DIV + col2 + col0 + ( - 55 + + col2 ) * col1 AS col0 FROM tab0 AS cor0
----
-1867
-5202
2547

skipif mysql # not compatible
query I rowsort label-4520
SELECT DISTINCT + col2 / + col2 + col0 + ( - 55 + + col2 ) * col1 AS col0 FROM tab0 AS cor0
----
-1867
-5202
2547

query I rowsort
SELECT - col1 * 73 AS col0 FROM tab0 AS cor0
----
-6278
-6643
-7081

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 4805bcb9c04e49d1f6f82defa880d751

query I rowsort
SELECT DISTINCT col1 + - col0 - + col0 FROM tab1 AS cor0
----
-118
-147
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-4524
SELECT ALL + + 46 * col1 DIV - col0 + + 65 FROM tab1 AS cor0
----
-333
58
58

skipif mysql # not compatible
query I rowsort label-4524
SELECT ALL + + 46 * col1 / - col0 + + 65 FROM tab1 AS cor0
----
-333
58
58

query I rowsort
SELECT - col2 + - col2 AS col2 FROM tab1 cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT - + col1 * + col2 + + 6 AS col0 FROM tab2 AS cor0
----
-1528
-640
-831

query I rowsort
SELECT DISTINCT - 46 * - col0 - ( col1 ) FROM tab1 AS cor0
----
112
2934
3667

query I rowsort
SELECT DISTINCT ( col0 + col2 ) * col2 * ( col2 ) AS col0 FROM tab2
----
168948
24786
70304

query I rowsort
SELECT ALL + 84 + cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 3f730adb0125410b47de9f7c299042ec

query I rowsort
SELECT + 4 AS col1 FROM tab0
----
4
4
4

query I rowsort
SELECT ALL - 94 + - col0 FROM tab1 cor0
----
-158
-174
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4532
SELECT ALL + - CAST( NULL AS DECIMAL ) 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-4532
SELECT ALL + - CAST ( NULL AS REAL ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab1 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to f464d40c605db608927f2c4d66190a23

query I rowsort
SELECT - 25 + col2 AS col0 FROM tab2 AS cor0
----
1
13
2

query I rowsort
SELECT + col2 - ( - 22 ) FROM tab0
----
104
23
55

query I rowsort
SELECT ALL + 78 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4537
SELECT CAST( NULL AS SIGNED ) * + col1 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4537
SELECT CAST ( NULL AS INTEGER ) * + col1 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 74 * col2 FROM tab0
----
-2442
-6068
-74

query I rowsort
SELECT DISTINCT - col0 * col0 + tab2.col0 * 86 AS col2 FROM tab2
----
553
624

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - 93 col0 FROM tab0
----
-4
-58
-69

query I rowsort
SELECT DISTINCT + ( col2 ) + col2 FROM tab2
----
52
54
76

query I rowsort
SELECT - ( - 34 ) + col0 FROM tab1
----
114
37
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4543
SELECT col2 DIV 75 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4543
SELECT col2 / 75 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + 24 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT DISTINCT + - 48 * + ( cor0.col2 ) FROM tab0 AS cor0
----
-1584
-3936
-48

query I rowsort
SELECT ALL col2 + + 3 FROM tab0
----
36
4
85

query I rowsort
SELECT - col0 * - col1 - + 61 AS col0 FROM tab2
----
1282
156
4541

query I rowsort
SELECT 28 * col2 AS col1 FROM tab0
----
2296
28
924

onlyif mysql # use DIV operator for integer division
query I rowsort label-4549
SELECT ALL + 42 DIV col2 + - col1 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4549
SELECT ALL + 42 / col2 + - col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT tab0.col2 * - col2 + + 54 FROM tab0
----
-1035
-6670
53

query I rowsort
SELECT ALL + + cor0.col1 * - col0 + col1 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT + col0 + + ( - col0 * + cor0.col1 ) FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT - + col0 + 67 * + col2 FROM tab0 cor0
----
2187
32
5405

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4554
SELECT - col1 * CAST( NULL AS SIGNED ) + + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4554
SELECT - col1 * CAST ( NULL AS INTEGER ) + + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4555
SELECT ALL col2 * - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4555
SELECT ALL col2 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4556
SELECT - col0 + - CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4556
SELECT - col0 + - CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * ( + col0 ) FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + col2 + + ( col0 ) AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + col0 + - ( - 39 ) FROM tab1 cor0
----
103
119
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4560
SELECT ALL col2 * - CAST( + col1 AS SIGNED ) + col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

skipif mysql # not compatible
query I rowsort label-4560
SELECT ALL col2 * - CAST ( + col1 AS INTEGER ) + col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-4561
SELECT ALL cor0.col2 DIV col1 AS col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4561
SELECT ALL cor0.col2 / col1 AS col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT ALL + col2 + 2 FROM tab1 cor0
----
56
59
98

query I rowsort
SELECT DISTINCT cor1.col0 FROM tab2, tab1 cor0, tab0 AS cor1
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4564
SELECT ALL tab1.col2 DIV ( + 52 ) AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4564
SELECT ALL tab1.col2 / ( + 52 ) AS col0 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 1 col1 FROM tab1
----
4
65
81

query I rowsort
SELECT ALL + - cor0.col1 + col2 * + col2 AS col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT ALL cor0.col0 * + ( 67 + - col0 ) AS col0 FROM tab2 AS cor0
----
-858
-948
420

query I rowsort
SELECT DISTINCT - col1 + col2 * col0 FROM tab1 cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT col1 * + ( + col0 ) AS col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL + + col1 + - col2 + col0 AS col0 FROM tab2 AS cor0
----
11
111
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4571
SELECT - CAST( ( - col0 ) AS SIGNED ) * col2 FROM tab1 cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-4571
SELECT - CAST ( ( - col0 ) AS INTEGER ) * col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT 90 * cor0.col1 + cor0.col2 AS col0 FROM tab2 AS cor0
----
1568
2817
5336

query I rowsort
SELECT ALL + + 34 * col2 FROM tab0 AS cor0
----
1122
2788
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4574
SELECT ALL + + ( ( + col0 ) ) * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4574
SELECT ALL + + ( ( + col0 ) ) * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4575
SELECT - + ( + 24 ) DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4575
SELECT - + ( + 24 ) / col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + ( col0 ) + col2 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT col1 + ( col1 ) AS col0 FROM tab1
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4578
SELECT DISTINCT - tab0.col2 * CAST( - col2 AS SIGNED ) * - col2 AS col0 FROM tab0
----
-1
-35937
-551368

skipif mysql # not compatible
query I rowsort label-4578
SELECT DISTINCT - tab0.col2 * CAST ( - col2 AS INTEGER ) * - col2 AS col0 FROM tab0
----
-1
-35937
-551368

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - ( tab1.col1 ) col0 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT DISTINCT 64 + - col2 AS col0 FROM tab0 AS cor0
----
-18
31
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4581
SELECT ALL - - col1 + - col0 * 39 DIV cor0.col2 - col2 AS col1 FROM tab0 AS cor0
----
-1269
-33
25

skipif mysql # not compatible
query I rowsort label-4581
SELECT ALL - - col1 + - col0 * 39 / cor0.col2 - col2 AS col1 FROM tab0 AS cor0
----
-1269
-33
25

query I rowsort
SELECT - ( + col0 ) + col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - + col0 - - col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT 76 * - col0 + 82 AS col1 FROM tab0 AS cor0
----
-1742
-2578
-6682

query I rowsort
SELECT - ( - col0 ) * + col0 + 42 FROM tab1 AS cor0
----
4138
51
6442

query I rowsort
SELECT DISTINCT + col1 * + col0 * 20 FROM tab0 AS cor0
----
161980
41280
67900

query I rowsort
SELECT ALL + col0 * col0 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL cor0.col1 * col1 * cor0.col1 AS col0 FROM tab1 cor0
----
1000
17576
2197

query I rowsort
SELECT col1 * col0 + col1 * ( cor0.col1 ) FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT ALL + - cor0.col2 * cor0.col1 + + 74 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
-1182
4166
4672

query I rowsort
SELECT DISTINCT - - col0 - col0 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + col0 + - cor0.col1 - + col0 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + col0 * 95 * - col2 FROM tab0
----
-3325
-693310
-75240

query I rowsort
SELECT ALL 18 - - tab0.col2 * + col0 FROM tab0
----
53
7316
810

query I rowsort
SELECT - tab1.col2 + + ( col1 ) AS col2 FROM tab1
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col1 * cor0.col0 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + col0 * + col0 * 12 + - 86 - - col1 AS col0 FROM tab1 AS cor0
----
48
49076
76727

onlyif mysql # use DIV operator for integer division
query I rowsort label-4598
SELECT 9 DIV + col2 AS col1 FROM tab0 AS cor0
----
0
0
9

skipif mysql # not compatible
query I rowsort label-4598
SELECT 9 / + col2 AS col1 FROM tab0 AS cor0
----
0
0
9

query I rowsort
SELECT + cor0.col2 * col1 + 79 FROM tab0 AS cor0
----
176
2917
7541

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4600
SELECT col2 * + CAST( col0 AS SIGNED ) + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

skipif mysql # not compatible
query I rowsort label-4600
SELECT col2 * + CAST ( col0 AS INTEGER ) + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT 34 + - col2 * - col0 FROM tab1
----
196
3682
7714

query I rowsort
SELECT col2 + col1 * - 31 FROM tab1 AS cor0
----
-253
-307
-752

query I rowsort
SELECT - 94 * + col2 FROM tab2 AS cor0
----
-2444
-2538
-3572

query I rowsort
SELECT 22 * col2 FROM tab1 cor0
----
1188
1254
2112

query I rowsort
SELECT - ( col1 ) * col1 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT + - 78 * col1 - - 3 * + 65 FROM tab0 AS cor0
----
-6513
-6903
-7371

query I rowsort
SELECT cor0.col1 * - col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + + ( - col2 ) + ( + col2 ) * - col2 + cor0.col0 * - 25 * col1 FROM tab1 AS cor0
----
-19306
-35312
-4920

query I rowsort
SELECT - + 88 * + col0 AS col0 FROM tab2 cor0
----
-616
-6864
-6952

query I rowsort
SELECT DISTINCT - 55 FROM tab0, tab0 AS cor0
----
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-4611
SELECT col0 * - col1 + + 79 DIV col0 AS col1 FROM tab2 cor0
----
-1342
-206
-4601

skipif mysql # not compatible
query I rowsort label-4611
SELECT col0 * - col1 + + 79 / col0 AS col1 FROM tab2 cor0
----
-1342
-206
-4601

query I rowsort
SELECT col0 * col0 - ( - col1 + col2 ) * 16 FROM tab2 AS cor0
----
113
5905
6612

query I rowsort
SELECT DISTINCT 56 * - cor0.col1 + - col1 AS col1 FROM tab0 AS cor0
----
-4902
-5187
-5529

onlyif mysql # use DIV operator for integer division
query I rowsort label-4614
SELECT - col0 DIV - col2 + ( col2 * + col0 + + 60 * - ( - cor0.col1 ) ) AS col1 FROM tab0 AS cor0
----
12759
5890
5952

skipif mysql # not compatible
query I rowsort label-4614
SELECT - col0 / - col2 + ( col2 * + col0 + + 60 * - ( - cor0.col1 ) ) AS col1 FROM tab0 AS cor0
----
12759
5890
5952

query I rowsort
SELECT ALL - ( - col1 ) * - col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - + col0 + - ( 46 ) * - col2 AS col2 FROM tab2 cor0
----
1118
1235
1669

query I rowsort
SELECT + cor0.col2 * - 35 FROM tab1 AS cor0
----
-1890
-1995
-3360

query I rowsort
SELECT + + col1 * + cor0.col1 AS col1 FROM tab2 cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 col2 FROM tab1 cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 36 col0 FROM tab1 AS cor0
----
36
36
36

query I rowsort
SELECT ALL - - col1 * cor0.col0 + + cor0.col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT - col0 + + cor0.col0 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4623
SELECT DISTINCT CAST( NULL AS SIGNED ) * col1 * - col2 col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4623
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col1 * - col2 col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + ( 70 ) FROM tab0 cor0
----
70
70
70

query I rowsort
SELECT col1 * + 1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - cor0.col1 + col0 * - col2 FROM tab0 AS cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-4627
SELECT DISTINCT 87 DIV ( + cor0.col1 ) FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-4627
SELECT DISTINCT 87 / ( + cor0.col1 ) FROM tab1 AS cor0
----
3
6
8

query I rowsort
SELECT DISTINCT col0 * - col1 + + col0 * + col2 AS col2 FROM tab1 cor0
----
3008
6640
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-4629
SELECT + + ( - col2 ) + - cor0.col1 DIV cor0.col0 FROM tab1 AS cor0
----
-57
-62
-96

skipif mysql # not compatible
query I rowsort label-4629
SELECT + + ( - col2 ) + - cor0.col1 / cor0.col0 FROM tab1 AS cor0
----
-57
-62
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4630
SELECT DISTINCT + + col0 + col2 DIV + cor0.col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4630
SELECT DISTINCT + + col0 + col2 / + cor0.col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 79 + col2 FROM tab0 AS cor0
----
112
161
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4632
SELECT ALL - 81 - - col1 DIV - col2 FROM tab1 cor0
----
-81
-81
-81

skipif mysql # not compatible
query I rowsort label-4632
SELECT ALL - 81 - - col1 / - col2 FROM tab1 cor0
----
-81
-81
-81

query I rowsort
SELECT - + 31 * col2 FROM tab2 cor0
----
-1178
-806
-837

query I rowsort
SELECT DISTINCT tab0.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
86
91
97

query I rowsort
SELECT DISTINCT + col1 + + ( col0 ) * col0 AS col0 FROM tab1
----
35
4106
6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-4636
SELECT + col1 DIV 56 + 0 AS col0 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4636
SELECT + col1 / 56 + 0 AS col0 FROM tab2
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col1 + col0 * - tab1.col2 col1 FROM tab1
----
-188
-3658
-7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4638
SELECT DISTINCT + CAST( + col2 AS SIGNED ) + col1 FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-4638
SELECT DISTINCT + CAST ( + col2 AS INTEGER ) + col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + - 13 AS col0 FROM tab0 AS cor0
----
-13

query I rowsort
SELECT - + col0 * - 93 * + col1 FROM tab1 AS cor0
----
59520
7254
96720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( tab0.col2 ) col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
1
33
82

query I rowsort
SELECT + col2 * col1 - tab1.col0 FROM tab1
----
1168
1401
506

query I rowsort
SELECT DISTINCT 7 AS col1 FROM tab1, tab1 AS cor0
----
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4644
SELECT + - ( col2 ) DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4644
SELECT + - ( col2 ) / + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 95 * col0 * 55 FROM tab0
----
125400
182875
465025

query I rowsort
SELECT + + cor1.col2 AS col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT DISTINCT + + 7 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4648
SELECT - - col0 * + CAST( 46 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
1104
1610
4094

skipif mysql # not compatible
query I rowsort label-4648
SELECT - - col0 * + CAST ( 46 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
1104
1610
4094

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - + col1 * - ( col0 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - cor0.col1 * - ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT - col1 + - col2 + + ( col2 ) * col0 FROM tab2 AS cor0
----
131
1943
2947

query I rowsort
SELECT 21 + col0 * - col1 AS col1 FROM tab2 cor0
----
-1322
-196
-4581

query I rowsort
SELECT ALL - col1 + - col1 * + cor0.col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL + cor0.col2 + - col0 + 26 FROM tab2 AS cor0
----
-15
-26
46

query I rowsort
SELECT ALL - - 58 FROM tab1 AS cor0
----
58
58
58

query I rowsort
SELECT - 44 * - col1 AS col1 FROM tab1 AS cor0
----
1144
440
572

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + + cor0.col0 * 29 col2 FROM tab1 cor0
----
1920
2400
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * - col1 - - col0 * + col1 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + cor0.col0 - + col1 * - col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL + - cor0.col1 + + col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col2 + 10 FROM tab2 AS cor0
----
-16
-17
-28

query I rowsort
SELECT DISTINCT + col1 + 31 AS col2 FROM tab0 AS cor0
----
117
122
128

query I rowsort
SELECT DISTINCT + + col0 + - cor0.col1 * - col2 AS col2 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-4665
SELECT + col0 DIV col0 AS col0 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4665
SELECT + col0 / col0 AS col0 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL 54 * - col1 FROM tab2 AS cor0
----
-1674
-3186
-918

query I rowsort
SELECT ALL + cor0.col0 + + col0 FROM tab1 AS cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 94 col2 FROM tab2 AS cor0
----
94
94
94

query I rowsort
SELECT ALL + - cor0.col1 * - 72 FROM tab2 AS cor0
----
1224
2232
4248

query I rowsort
SELECT + 68 FROM tab2, tab0 cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT col1 + col0 * col0 AS col0 FROM tab1
----
35
4106
6413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4672
SELECT DISTINCT CAST( - col2 AS SIGNED ) * col1 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4672
SELECT DISTINCT CAST ( - col2 AS INTEGER ) * col1 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + ( - col2 ) * col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + col2 * col0 + + col1 AS col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT - tab1.col2 - - 68 AS col0 FROM tab1
----
-28
11
14

query I rowsort
SELECT - 72 * - col2 FROM tab1 AS cor0
----
3888
4104
6912

onlyif mysql # use DIV operator for integer division
query I rowsort label-4677
SELECT ALL - col0 DIV ( col1 ) FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-4677
SELECT ALL - col0 / ( col1 ) FROM tab1 AS cor0
----
-6
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 28 + cor0.col2 col2 FROM tab2 AS cor0
----
-169
-2158
-2174

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4679
SELECT - CAST( NULL AS SIGNED ) * ( - col0 * col1 ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4679
SELECT - CAST ( NULL AS INTEGER ) * ( - col0 * col1 ) AS col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4680
SELECT CAST( 31 AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

skipif mysql # not compatible
query I rowsort label-4680
SELECT CAST ( 31 AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4681
SELECT CAST( 91 AS SIGNED ) * - col0 AS col0 FROM tab1
----
-273
-5824
-7280

skipif mysql # not compatible
query I rowsort label-4681
SELECT CAST ( 91 AS INTEGER ) * - col0 AS col0 FROM tab1
----
-273
-5824
-7280

query I rowsort
SELECT DISTINCT + col1 + 19 + col1 FROM tab1
----
39
45
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-4683
SELECT DISTINCT 14 DIV + tab2.col1 AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-4683
SELECT DISTINCT 14 / + tab2.col1 AS col0 FROM tab2
----
0

query I rowsort
SELECT DISTINCT + col1 * - tab2.col1 * col1 AS col2 FROM tab2
----
-205379
-29791
-4913

query I rowsort
SELECT + 90 * - col1 FROM tab0 AS cor0
----
-7740
-8190
-8730

query I rowsort
SELECT - - col2 + + col1 * + col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT 96 * cor0.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 49fba294aa3c5cff273a0c332a91d3dc

query I rowsort
SELECT ALL - - cor0.col2 * + cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 33 * col1 col2 FROM tab1 cor0
----
330
429
858

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 99 col2 FROM tab0 AS cor0
----
99
99
99

query I rowsort
SELECT 44 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT DISTINCT col2 + - ( - col1 ) * - col1 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT tab0.col1 + + col1 + col0 FROM tab0
----
196
229
271

query I rowsort
SELECT col2 + tab0.col0 + + 70 FROM tab0
----
106
127
241

query I rowsort
SELECT ALL col2 * + col1 + 93 * cor0.col0 FROM tab1 AS cor0
----
1683
6522
8688

query I rowsort
SELECT ALL col0 + col0 + col0 * col2 FROM tab0 AS cor0
----
105
7476
840

query I rowsort
SELECT ALL col1 * + 25 FROM tab0 cor0
----
2150
2275
2425

query I rowsort
SELECT + ( + 21 ) - + col2 * - col0 FROM tab0 AS cor0
----
56
7319
813

query I rowsort
SELECT ALL + 89 AS col0 FROM tab2 AS cor0
----
89
89
89

query I rowsort
SELECT DISTINCT + + 31 AS col1 FROM tab1 AS cor0
----
31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4701
SELECT DISTINCT - CAST( col1 AS SIGNED ) * - col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-4701
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * - col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT ( 30 ) * - col1 AS col2 FROM tab0 AS cor0
----
-2580
-2730
-2910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4703
SELECT CAST( NULL AS DECIMAL ) * - 85 + cor0.col1 * - 68 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-4703
SELECT CAST ( NULL AS REAL ) * - 85 + cor0.col1 * - 68 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + ( + ( col1 ) ) AS col2 FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 9 * + col2 col2 FROM tab0 AS cor0
----
10
330
820

query I rowsort
SELECT + - col2 + + col2 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT 53 - + col1 FROM tab1 AS cor0
----
27
40
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4708
SELECT - CAST( - col2 AS SIGNED ) - - col2 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-4708
SELECT - CAST ( - col2 AS INTEGER ) - - col2 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + ( + cor0.col1 ) * + cor0.col1 col2 FROM tab1 AS cor0
----
43
622
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4710
SELECT - ( - col0 ) DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4710
SELECT - ( - col0 ) / cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 61 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4712
SELECT - CAST( + tab2.col2 AS SIGNED ) FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

skipif mysql # not compatible
query I rowsort label-4712
SELECT - CAST ( + tab2.col2 AS INTEGER ) FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT 5 AS col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT - - col0 * + 59 FROM tab2 cor0
----
413
4602
4661

query I rowsort
SELECT + col1 * + 90 AS col2 FROM tab0 AS cor0
----
7740
8190
8730

onlyif mysql # use DIV operator for integer division
query I rowsort label-4716
SELECT DISTINCT col1 + ( col2 ) DIV - col1 AS col1 FROM tab1 AS cor0
----
24
5
6

skipif mysql # not compatible
query I rowsort label-4716
SELECT DISTINCT col1 + ( col2 ) / - col1 AS col1 FROM tab1 AS cor0
----
24
5
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4717
SELECT - col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4717
SELECT - col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * col2 + cor0.col2 + - col0 AS col1 FROM tab2 AS cor0
----
-1485
-709
-728

query I rowsort
SELECT DISTINCT cor0.col2 + + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT col0 * + ( + col0 ) FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT col0 * ( + 94 ) FROM tab2 AS cor0
----
658
7332
7426

query I rowsort
SELECT DISTINCT - 36 FROM tab0
----
-36

query I rowsort
SELECT ALL ( col1 ) * col2 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 0 col2 FROM tab0, tab1 AS cor0
----
0

query I rowsort
SELECT - ( + ( col1 ) ) + cor0.col2 * 55 FROM tab0 AS cor0
----
-42
1729
4419

query I rowsort
SELECT cor0.col2 + - col1 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - col2 * - ( col0 + ( - col2 ) ) FROM tab2 cor0
----
-540
1352
1558

query I rowsort
SELECT + col2 * + col2 * ( col2 * col0 ) FROM tab0 AS cor0
----
35
49071752
862488

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 47 col0 FROM tab1 AS cor0
----
47
47
47

query I rowsort
SELECT + cor1.col1 - cor1.col0 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e97278a6bb7007ec367f7fc7917bd1c7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 6 ) + cor0.col2 col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to c4665dda7e37a24aa64e0535687e3a1c

query I rowsort
SELECT cor1.col1 AS col0 FROM tab2, tab1 cor0 CROSS JOIN tab1, tab0 AS cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 2 col2 FROM tab0
----
2

query I rowsort
SELECT ALL + col1 * + col0 - ( + 51 ) FROM tab2 AS cor0
----
1292
166
4551

query I rowsort
SELECT ( cor0.col1 ) + - col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * col2 + ( + cor0.col0 ) * cor0.col0 AS col1 FROM tab0 AS cor0
----
1226
14645
1665

onlyif mysql # use DIV operator for integer division
query I rowsort label-4737
SELECT - col0 * + col1 + ( col1 ) DIV col0 FROM tab2
----
-1343
-213
-4602

skipif mysql # not compatible
query I rowsort label-4737
SELECT - col0 * + col1 + ( col1 ) / col0 FROM tab2
----
-1343
-213
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4738
SELECT ALL ( col1 ) * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4738
SELECT ALL ( col1 ) * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 51 * + col0 AS col2 FROM tab1 AS cor0
----
-153
-3264
-4080

onlyif mysql # use DIV operator for integer division
query I rowsort label-4740
SELECT DISTINCT - col1 DIV - tab1.col1 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-4740
SELECT DISTINCT - col1 / - tab1.col1 FROM tab1
----
1

query I rowsort
SELECT DISTINCT + 21 * cor0.col0 FROM tab0 AS cor0
----
1869
504
735

query I rowsort
SELECT 38 * col0 FROM tab1 AS cor0
----
114
2432
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 25 + + cor0.col0 col0 FROM tab1 AS cor0
----
-22
39
55

query I rowsort
SELECT ALL - col1 + - col2 + col2 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col2 + - ( + col1 ) AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT + + col0 + - ( - col0 ) AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - + cor0.col0 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL + - col1 * - ( 41 ) + col0 * 6 FROM tab1 cor0
----
1013
1084
794

query I rowsort
SELECT DISTINCT - 24 + - tab0.col0 AS col0 FROM tab0
----
-113
-48
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4750
SELECT ALL + CAST( 4 AS SIGNED ) FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

skipif mysql # not compatible
query I rowsort label-4750
SELECT ALL + CAST ( 4 AS INTEGER ) FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4751
SELECT ALL - CAST( ( - col1 DIV - ( + col0 ) ) AS SIGNED ) * col1 * + col1 AS col0 FROM tab0 AS cor0
----
-18818
-22188
-8281

skipif mysql # not compatible
query I rowsort label-4751
SELECT ALL - CAST ( ( - col1 / - ( + col0 ) ) AS INTEGER ) * col1 * + col1 AS col0 FROM tab0 AS cor0
----
-18818
-22188
-8281

query I rowsort
SELECT ALL - col0 + 87 AS col1 FROM tab1 AS cor0
----
23
7
84

query I rowsort
SELECT ALL 72 FROM tab0, tab1 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT DISTINCT + 74 + col1 * col2 AS col0 FROM tab2 cor0
----
1608
720
911

query I rowsort
SELECT ALL - 77 * ( + col2 ) AS col0 FROM tab0 AS cor0
----
-2541
-6314
-77

query I rowsort
SELECT + ( - 21 ) - - col0 AS col0 FROM tab1 AS cor0
----
-18
43
59

query I rowsort
SELECT DISTINCT + 44 * cor0.col2 * col0 AS col1 FROM tab0 AS cor0
----
1540
321112
34848

query I rowsort
SELECT - col2 - + tab1.col2 AS col2 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT col0 * tab0.col1 + col2 AS col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT + 4 * - 94 + + col1 - 1 * + col1 * col0 AS col2 FROM tab0 AS cor0
----
-2354
-3674
-8384

query I rowsort
SELECT ( + col1 ) * + col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col2 + + col2 * + col2 AS col0 FROM tab0
----
0
1056
6642

query I rowsort
SELECT - + col0 * 55 AS col2 FROM tab0 AS cor0
----
-1320
-1925
-4895

query I rowsort
SELECT + col2 + + tab0.col1 + col1 AS col0 FROM tab0
----
195
205
264

query I rowsort
SELECT DISTINCT col1 + col0 + - col1 * col2 FROM tab0
----
-2728
-7282
35

query I rowsort
SELECT tab0.col0 + 78 + - col2 FROM tab0
----
112
69
85

query I rowsort
SELECT ALL + col1 * col2 + + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - + col0 + - 68 FROM tab1 cor0
----
-132
-148
-71

query I rowsort
SELECT + + col1 + - 82 FROM tab2 AS cor0
----
-23
-51
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-4770
SELECT + col2 DIV col0 + col1 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-4770
SELECT + col2 / col0 + col1 FROM tab0 AS cor0
----
87
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4771
SELECT ALL - + cor0.col1 * - 3 + + cor0.col1 - + col0 DIV col1 col0 FROM tab0 AS cor0
----
344
364
388

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4771
SELECT ALL - + cor0.col1 * - 3 + + cor0.col1 - + col0 / col1 col0 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT DISTINCT - col0 * ( ( col2 ) ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + col0 + + cor0.col2 + - col0 AS col2 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4774
SELECT - col2 + - CAST( NULL AS SIGNED ) * - cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4774
SELECT - col2 + - CAST ( NULL AS INTEGER ) * - cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + 59 + 56 FROM tab2 cor0
----
1590
1649
2298

query I rowsort
SELECT DISTINCT 49 * - 34 FROM tab0 AS cor0
----
-1666

onlyif mysql # use DIV operator for integer division
query I rowsort label-4777
SELECT DISTINCT - CAST( col1 AS SIGNED ) DIV - col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-4777
SELECT DISTINCT - CAST ( col1 AS INTEGER ) / - col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL - cor1.col0 AS col2 FROM tab1, tab0 cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to adaea38eae032c1639715f21831dd376

onlyif mysql # use DIV operator for integer division
query I rowsort label-4779
SELECT + ( 31 ) DIV cor0.col0 FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4779
SELECT + ( 31 ) / cor0.col0 FROM tab2 cor0
----
0
0
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4780
SELECT ALL - 49 DIV - col0 AS col2 FROM tab1 AS cor0
----
0
0
16

skipif mysql # not compatible
query I rowsort label-4780
SELECT ALL - 49 / - col0 AS col2 FROM tab1 AS cor0
----
0
0
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 10 * + col2 + col0 col0 FROM tab2 AS cor0
----
277
338
459

query I rowsort
SELECT ALL + - ( 18 ) AS col0 FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT DISTINCT + - cor0.col1 + col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + col2 * col0 - col0 AS col0 FROM tab1 cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-4785
SELECT DISTINCT - tab1.col1 + col0 + - 44 DIV - ( col1 ) FROM tab1
----
-22
58
70

skipif mysql # not compatible
query I rowsort label-4785
SELECT DISTINCT - tab1.col1 + col0 + - 44 / - ( col1 ) FROM tab1
----
-22
58
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4786
SELECT 17 DIV + col1 AS col0 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4786
SELECT 17 / + col1 AS col0 FROM tab2
----
0
0
1

query I rowsort
SELECT - 8 + + col2 AS col1 FROM tab2
----
18
19
30

query I rowsort
SELECT ALL tab2.col2 AS col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4789
SELECT ALL - col0 DIV col0 + - col1 col1 FROM tab2 AS cor0
----
-18
-32
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4789
SELECT ALL - col0 / col0 + - col1 col1 FROM tab2 AS cor0
----
-18
-32
-60

query I rowsort
SELECT ALL + col0 + + col2 * ( col2 ) AS col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL + col1 + col0 * - ( - col0 ) FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT - 43 * - cor0.col0 FROM tab1 cor0
----
129
2752
3440

query I rowsort
SELECT - cor0.col2 * - cor0.col0 - - col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - col2 * - col0 - - ( cor0.col1 ) * col2 AS col0 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT + 2 * - col1 AS col0 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL - col2 + + col1 * + 35 + col1 FROM tab2 AS cor0
----
1089
2098
574

query I rowsort
SELECT col0 * col0 + 29 AS col1 FROM tab2 AS cor0
----
6113
6270
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4798
SELECT ALL + - cor0.col2 - + CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4798
SELECT ALL + - cor0.col2 - + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col0 + col2 * - ( + col0 + col2 ) FROM tab2 AS cor0
----
-2626
-4367
-911

query I rowsort
SELECT DISTINCT + col1 + - 45 AS col1 FROM tab2 AS cor0
----
-14
-28
14

query I rowsort
SELECT DISTINCT col0 * col0 + cor0.col2 * + col0 FROM tab0 AS cor0
----
1260
1368
15219

query I rowsort
SELECT - tab2.col1 * col2 + - col2 + + 19 AS col0 FROM tab2
----
-1541
-665
-845

query I rowsort
SELECT - col1 * + col0 * - 36 AS col1 FROM tab1
----
23040
2808
37440

query I rowsort
SELECT DISTINCT + 42 * col2 * col1 - - col1 * - col1 AS col2 FROM tab1
----
23840
52247
58292

query I rowsort
SELECT + ( - col1 ) * + 35 AS col1 FROM tab2
----
-1085
-2065
-595

query I rowsort
SELECT DISTINCT col1 * col0 - col2 AS col2 FROM tab2
----
1305
190
4576

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab1 cor1, tab0 cor2
----
972 values hashing to e84152c0bf436177d3b3d80e42832d4f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4808
SELECT ALL col2 * CAST( - 70 AS SIGNED ) + + col0 FROM tab1 AS cor0
----
-3777
-3926
-6640

skipif mysql # not compatible
query I rowsort label-4808
SELECT ALL col2 * CAST ( - 70 AS INTEGER ) + + col0 FROM tab1 AS cor0
----
-3777
-3926
-6640

query I rowsort
SELECT + col2 - - col1 * + col1 AS col1 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-4810
SELECT + + col2 DIV col0 - col0 * col1 AS col0 FROM tab1 AS cor0
----
-1039
-60
-640

skipif mysql # not compatible
query I rowsort label-4810
SELECT + + col2 / col0 - col0 * col1 AS col0 FROM tab1 AS cor0
----
-1039
-60
-640

query I rowsort
SELECT ALL + 63 * col2 AS col0 FROM tab0
----
2079
5166
63

query I rowsort
SELECT - - col2 * col2 + col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL col1 + + col0 * + col0 FROM tab0
----
1322
662
8012

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4814
SELECT - - ( - col1 ) + col2 * + CAST( NULL AS SIGNED ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4814
SELECT - - ( - col1 ) + col2 * + CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor1.col0 FROM tab0, tab1 cor0, tab0 AS cor1
----
24
35
89

query I rowsort
SELECT DISTINCT + col2 * col1 * col0 AS col1 FROM tab2
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4817
SELECT ALL col0 / + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4817
SELECT ALL col0 / + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 + - col0 * - col1 AS col2 FROM tab1 cor0
----
104
1053
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4819
SELECT ALL + tab1.col0 * CAST( - col1 AS SIGNED ) AS col0 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-4819
SELECT ALL + tab1.col0 * CAST ( - col1 AS INTEGER ) AS col0 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col2 col1 FROM tab1, tab2 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + col1 * - 18 AS col1 FROM tab1
----
-180
-234
-468

onlyif mysql # use DIV operator for integer division
query I rowsort label-4822
SELECT ALL col0 DIV 64 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4822
SELECT ALL col0 / 64 FROM tab1
----
0
1
1

query I rowsort
SELECT + 5 * col1 FROM tab0 AS cor0
----
430
455
485

query I rowsort
SELECT ( col2 ) + - col1 * - 66 FROM tab0
----
5709
6088
6403

query I rowsort
SELECT ALL col2 * 1 AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT + tab2.col0 AS col2 FROM tab2, tab1 AS cor0
----
7
78
79

query I rowsort
SELECT ALL cor0.col2 * + cor0.col0 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 41d4c126bfd4bfab59ba5e83427c98e0

query I rowsort
SELECT ALL + + col1 * col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 27 col1 FROM tab1 AS cor0
----
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-4830
SELECT - + col1 DIV cor0.col1 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4830
SELECT - + col1 / cor0.col1 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + - 83 AS col0 FROM tab0 AS cor0
----
-83

query I rowsort
SELECT DISTINCT + ( col2 ) + + col2 * col2 FROM tab1 AS cor0
----
2970
3306
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - col1 * - col2 col2 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT ALL - - col1 + col1 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ALL + col1 + - col0 + col1 AS col1 FROM tab1 AS cor0
----
-44
-54
49

query I rowsort
SELECT - 11 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 31 * + col2 * - 76 col1 FROM tab2 AS cor0
----
-61256
-63612
-89528

query I rowsort
SELECT - cor0.col0 + 33 FROM tab2, tab2 AS cor0
----
9 values hashing to d091a00fe100c7933c850b9647dd8d09

query I rowsort
SELECT DISTINCT + + 80 * + col1 FROM tab1 AS cor0
----
1040
2080
800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 44 - col2 * col0 col1 FROM tab0
----
-7342
-79
-836

query I rowsort
SELECT - tab2.col0 - col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT - 28 FROM tab1, tab2 AS cor0
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL 44 * col2 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-160512
-337920
-7128

query I rowsort
SELECT + + 34 * - 97 AS col0 FROM tab2 AS cor0
----
-3298
-3298
-3298

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + + col0 col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT ALL + col2 DIV col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4847
SELECT ALL + col2 / col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 * 18 AS col2 FROM tab0
----
-1548
-1638
-1746

onlyif mysql # use DIV operator for integer division
query I rowsort label-4849
SELECT ALL + col2 - - col1 * 95 DIV + col2 col2 FROM tab1
----
108
73
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4849
SELECT ALL + col2 - - col1 * 95 / + col2 col2 FROM tab1
----
108
73
99

query I rowsort
SELECT - 22 AS col1 FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

query I rowsort
SELECT ALL + col2 * 37 FROM tab1
----
1998
2109
3552

query I rowsort
SELECT + col2 * - ( col2 * + col2 ) AS col1 FROM tab2
----
-17576
-19683
-54872

query I rowsort
SELECT - 0 * + tab1.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-4854
SELECT ( 25 ) + - col1 + col0 DIV col0 FROM tab1 cor0
----
0
13
16

skipif mysql # not compatible
query I rowsort label-4854
SELECT ( 25 ) + - col1 + col0 / col0 FROM tab1 cor0
----
0
13
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - 21 col0 FROM tab2 AS cor0
----
-546
-567
-798

query I rowsort
SELECT - col2 - + col0 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + + 29 - col2 AS col2 FROM tab0 AS cor0
----
-4
-53
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + cor0.col1 + - col2 col2 FROM tab2 AS cor0
----
-23
-59
7

query I rowsort
SELECT + col0 + - 45 * col0 FROM tab0 AS cor0
----
-1056
-1540
-3916

onlyif mysql # use DIV operator for integer division
query I rowsort label-4860
SELECT + col0 + col1 DIV - cor0.col2 AS col1 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-4860
SELECT + col0 + col1 / - cor0.col2 AS col1 FROM tab1 cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4861
SELECT DISTINCT CAST( NULL AS DECIMAL ) * - 34 * + col2 + col2 + col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4861
SELECT DISTINCT CAST ( NULL AS REAL ) * - 34 * + col2 + col2 + col0 FROM tab0
----
NULL

query I rowsort
SELECT 49 + - col2 * - col1 FROM tab2
----
1583
695
886

onlyif mysql # use DIV operator for integer division
query I rowsort label-4863
SELECT + col0 + ( tab0.col0 ) + + col2 DIV col0 FROM tab0
----
178
49
70

skipif mysql # not compatible
query I rowsort label-4863
SELECT + col0 + ( tab0.col0 ) + + col2 / col0 FROM tab0
----
178
49
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4864
SELECT - 65 + col0 DIV col0 - - col2 FROM tab1
----
-10
-7
32

skipif mysql # not compatible
query I rowsort label-4864
SELECT - 65 + col0 / col0 - - col2 FROM tab1
----
-10
-7
32

query I rowsort
SELECT DISTINCT col0 - 20 AS col2 FROM tab1
----
-17
44
60

query I rowsort
SELECT ALL 61 - col0 AS col2 FROM tab0
----
-28
26
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-4867
SELECT DISTINCT col0 DIV col1 + col2 * - CAST( - col0 AS SIGNED ) AS col1 FROM tab2
----
189
2029
3006

skipif mysql # not compatible
query I rowsort label-4867
SELECT DISTINCT col0 / col1 + col2 * - CAST ( - col0 AS INTEGER ) AS col1 FROM tab2
----
189
2029
3006

query I rowsort
SELECT DISTINCT - - ( - col2 ) - col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + col1 * col1 - - cor0.col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT + 25 + + col1 AS col2 FROM tab1
----
35
38
51

query I rowsort
SELECT ALL - 59 + + tab0.col1 AS col0 FROM tab0
----
27
32
38

query I rowsort
SELECT DISTINCT 40 + col2 FROM tab0
----
122
41
73

query I rowsort
SELECT ALL - + 57 * col0 AS col0 FROM tab1 AS cor0
----
-171
-3648
-4560

query I rowsort
SELECT - - ( - col1 ) * - col1 + 84 + col2 FROM tab1 AS cor0
----
241
349
814

query I rowsort
SELECT ALL - 46 * - col2 FROM tab0 cor0
----
1518
3772
46

query I rowsort
SELECT - cor0.col0 + - col0 AS col1 FROM tab0 AS cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - cor0.col2 ) col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - cor0.col2 + col2 * - cor0.col0 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL col0 * + col0 + + 71 FROM tab1 AS cor0
----
4167
6471
80

query I rowsort
SELECT DISTINCT + col2 + - col2 * col1 FROM tab2 cor0
----
-1508
-608
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4881
SELECT + col2 + col2 * - CAST( + 65 AS SIGNED ) + col0 * col2 AS col2 FROM tab1 AS cor0
----
-3294
0
1536

skipif mysql # not compatible
query I rowsort label-4881
SELECT + col2 + col2 * - CAST ( + 65 AS INTEGER ) + col0 * col2 AS col2 FROM tab1 AS cor0
----
-3294
0
1536

query I rowsort
SELECT ( col2 ) + + 63 * + ( col2 ) AS col1 FROM tab0 AS cor0
----
2112
5248
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4884
SELECT col2 DIV col1 + - 67 * - col1 + col1 AS col2 FROM tab1 AS cor0
----
1770
685
891

skipif mysql # not compatible
query I rowsort label-4884
SELECT col2 / col1 + - 67 * - col1 + col1 AS col2 FROM tab1 AS cor0
----
1770
685
891

query I rowsort
SELECT DISTINCT + col2 + col1 * - cor0.col2 * + col0 AS col1 FROM tab0 AS cor0
----
-3394
-664036
-68079

query I rowsort
SELECT + cor0.col1 * - 65 AS col1 FROM tab2 AS cor0
----
-1105
-2015
-3835

onlyif mysql # use DIV operator for integer division
query I rowsort label-4887
SELECT ALL - - col2 + - col1 - - col2 DIV + cor0.col2 FROM tab0 AS cor0
----
-52
-8
-95

skipif mysql # not compatible
query I rowsort label-4887
SELECT ALL - - col2 + - col1 - - col2 / + cor0.col2 FROM tab0 AS cor0
----
-52
-8
-95

query I rowsort
SELECT + - col1 * col1 + col2 AS col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT - - col0 + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - + col0 col2 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT - col1 * col0 * + 8 FROM tab1 AS cor0
----
-5120
-624
-8320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + 41 col2 FROM tab1 AS cor0
----
-13
-16
-55

query I rowsort
SELECT ALL cor0.col1 + + col2 * col1 - + cor0.col0 AS col1 FROM tab2 AS cor0
----
1515
584
861

query I rowsort
SELECT DISTINCT col2 * col1 + col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-4895
SELECT DISTINCT 8 DIV col2 AS col0 FROM tab0 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-4895
SELECT DISTINCT 8 / col2 AS col0 FROM tab0 AS cor0
----
0
8

query I rowsort
SELECT col1 * 5 FROM tab1 cor0
----
130
50
65

query I rowsort
SELECT DISTINCT + col2 + - col0 * + col1 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - 19 + + col0 FROM tab2 AS cor0
----
-12
59
60

query I rowsort
SELECT + - col1 - col0 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4900
SELECT + 23 DIV - cor0.col2 AS col1 FROM tab0 AS cor0
----
-23
0
0

skipif mysql # not compatible
query I rowsort label-4900
SELECT + 23 / - cor0.col2 AS col1 FROM tab0 AS cor0
----
-23
0
0

query I rowsort
SELECT ALL + ( 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-4902
SELECT col0 - - CAST( NULL AS SIGNED ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4902
SELECT col0 - - CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 + + col0 * - col0 * col0 AS col0 FROM tab2 AS cor0
----
-316
-474526
-493001

onlyif mysql # use DIV operator for integer division
query I rowsort label-4904
SELECT + + col2 + 11 DIV - col2 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4904
SELECT + + col2 + 11 / - col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT + col2 + + 49 * col2 AS col2 FROM tab2 AS cor0
----
1300
1350
1900

query I rowsort
SELECT col1 + col2 * + col0 * + col2 FROM tab1 AS cor0
----
207946
737293
8774

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + cor0.col0 col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT ( 61 ) AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
61

query I rowsort
SELECT 4 * tab2.col1 + - col2 + - ( col1 ) * + 22 AS col0 FROM tab2
----
-1088
-344
-585

onlyif mysql # use DIV operator for integer division
query I rowsort label-4910
SELECT ALL 98 DIV - col0 + - col2 + - col1 FROM tab1
----
-110
-112
-68

skipif mysql # not compatible
query I rowsort label-4910
SELECT ALL 98 / - col0 + - col2 + - col1 FROM tab1
----
-110
-112
-68

query I rowsort
SELECT DISTINCT + 58 * + col0 + + col0 FROM tab0
----
1416
2065
5251

onlyif mysql # use DIV operator for integer division
query I rowsort label-4912
SELECT col1 + col2 DIV + 48 AS col2 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4912
SELECT col1 + col2 / + 48 AS col2 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4913
SELECT + tab0.col1 + col1 + 21 DIV col0 AS col1 FROM tab0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-4913
SELECT + tab0.col1 + col1 + 21 / col0 AS col1 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT tab2.col0 * - ( col1 ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT col1 * ( col2 ) AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + col0 + ( ( + col1 ) ) FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + ( + col0 ) col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT col1 + + col1 - - col2 * - col2 AS col2 FROM tab0 cor0
----
-6542
-917
193

query I rowsort
SELECT col2 * + ( - col1 * + col2 ) FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT + col0 * - ( col0 ) FROM tab1 AS cor0
----
-4096
-6400
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col1 col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 * col2 - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT tab2.col2 AS col1 FROM tab2 WHERE NULL IN ( tab2.col1 )
----

query I rowsort
SELECT col2 * col1 FROM tab0 WHERE NOT ( NULL ) NOT IN ( + col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 col2 FROM tab0 WHERE col2 BETWEEN ( NULL ) AND + tab0.col1 * - col1 + - col2
----

query I rowsort
SELECT tab2.col1 + tab2.col1 * + tab2.col1 + col1 * - col0 * + col0 FROM tab2
----
-105791
-355416
-527

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( NULL ) BETWEEN NULL AND - col0 + col1
----

query I rowsort
SELECT ALL tab2.col2 FROM tab2 WHERE NOT col1 * - col1 > NULL
----

query I rowsort
SELECT col2 + + col0 + + tab0.col2 FROM tab0
----
253
37
90

query I rowsort
SELECT + col2 - + col2 AS col0 FROM tab2
----
0
0
0

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT - col1 IN ( tab2.col2 / col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT tab2.col1 + - col2 * - col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT DISTINCT + - 89 + col2 * - 31 FROM tab1 AS cor0
----
-1763
-1856
-3065

query I rowsort
SELECT 42 * - col1 AS col2 FROM tab2 AS cor0
----
-1302
-2478
-714

onlyif mysql # use DIV operator for integer division
query I rowsort label-4935
SELECT DISTINCT - 38 DIV col0 FROM tab1
----
-12
0

skipif mysql # not compatible
query I rowsort label-4935
SELECT DISTINCT - 38 / col0 FROM tab1
----
-12
0

query I rowsort
SELECT DISTINCT + + 57 * - col1 AS col1 FROM tab1 AS cor0
----
-1482
-570
-741

onlyif mysql # use DIV operator for integer division
query I rowsort label-4937
SELECT ( col2 ) + - col0 DIV 78 AS col0 FROM tab0 AS cor0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-4937
SELECT ( col2 ) + - col0 / 78 AS col0 FROM tab0 AS cor0
----
1
33
81

query I rowsort
SELECT ALL - + col1 + col1 * 71 FROM tab2 AS cor0
----
1190
2170
4130

query I rowsort
SELECT ALL + 81 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT + + ( - col0 ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - + col2 * + col2 * col2 - - col0 FROM tab0 AS cor0
----
-35913
-551279
34

query I rowsort
SELECT col1 * ( + cor0.col1 ) - + col0 AS col0 FROM tab0 cor0
----
7372
8192
9374

query I rowsort
SELECT - + col0 - + col0 * col0 AS col1 FROM tab0 cor0
----
-1260
-600
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 19 col2 FROM tab0
----
19
19
19

query I rowsort
SELECT - + 50 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT DISTINCT ( + col1 * + col0 ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT 80 AS col1 FROM tab2, tab1 AS cor0
----
80

query I rowsort
SELECT + + col2 + col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ( tab0.col2 ) * col2 AS col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT - 85 * 6 FROM tab2
----
-510
-510
-510

query I rowsort
SELECT - + col2 * 18 + - col2 AS col1 FROM tab1 AS cor0
----
-1026
-1083
-1824

query I rowsort
SELECT ALL col2 * + ( 58 ) + - col1 AS col1 FROM tab2
----
1449
1535
2187

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4954
SELECT DISTINCT + col0 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4954
SELECT DISTINCT + col0 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT ALL col0 + ( col1 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - col2 + 53 AS col2 FROM tab1 cor0
----
-1
-4
-43

query I rowsort
SELECT col1 * + 8 FROM tab0 AS cor0
----
688
728
776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 72 + col2 col1 FROM tab2 AS cor0
----
-34
-45
-46

query I rowsort
SELECT DISTINCT - 15 + - col0 AS col1 FROM tab1 AS cor0
----
-18
-79
-95

query I rowsort
SELECT 59 * - cor0.col0 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 825f14fbaed56793f9f0ee11c660b3c7

query I rowsort
SELECT - 26 * col0 AS col2 FROM tab2 AS cor0
----
-182
-2028
-2054

onlyif mysql # use DIV operator for integer division
query I rowsort label-4962
SELECT DISTINCT - - col1 + - col2 * col1 DIV - 9 col0 FROM tab2 cor0
----
124
229
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4962
SELECT DISTINCT - - col1 + - col2 * col1 / - 9 col0 FROM tab2 cor0
----
124
229
88

query I rowsort
SELECT + 76 * 46 AS col0 FROM tab0 AS cor0
----
3496
3496
3496

query I rowsort
SELECT ALL + - 74 - 87 AS col1 FROM tab2 AS cor0
----
-161
-161
-161

query I rowsort
SELECT DISTINCT col1 + 74 FROM tab2 AS cor0
----
105
133
91

query I rowsort
SELECT ALL - 74 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 5a567947d14593676e3825756f8e6130

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - tab0.col1 * - col0 col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT + - col1 * - col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 67 ) col2 FROM tab1
----
67
67
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-4970
SELECT ALL 49 DIV 2 AS col1 FROM tab1
----
24
24
24

skipif mysql # not compatible
query I rowsort label-4970
SELECT ALL 49 / 2 AS col1 FROM tab1
----
24
24
24

query I rowsort
SELECT + 21 + + col2 - 77 * + col0 AS col1 FROM tab2 AS cor0
----
-491
-5959
-6024

onlyif mysql # use DIV operator for integer division
query I rowsort label-4972
SELECT - - col1 + cor0.col0 + + 29 DIV cor0.col0 FROM tab1 AS cor0
----
38
74
93

skipif mysql # not compatible
query I rowsort label-4972
SELECT - - col1 + cor0.col0 + + 29 / cor0.col0 FROM tab1 AS cor0
----
38
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 87 * - col1 - col2 col0 FROM tab1 cor0
----
-1227
-2316
-927

onlyif mysql # use DIV operator for integer division
query I rowsort label-4974
SELECT + 22 DIV + col1 AS col2 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4974
SELECT + 22 / + col1 AS col2 FROM tab2 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 45 * + col0 col2 FROM tab2
----
315
3510
3555

query I rowsort
SELECT DISTINCT + col0 + + col0 * - 84 AS col2 FROM tab0 AS cor0
----
-1992
-2905
-7387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * ( + col2 ) + cor0.col1 * col0 col0 FROM tab1 AS cor0
----
10256
2994
3889

query I rowsort
SELECT col0 * ( + col1 * col1 ) FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT + - 5 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

query I rowsort
SELECT col0 * col2 + 0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT + 43 AS col2 FROM tab2
----
43

skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 * + col0 / + CAST ( col0 AS REAL ) FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT tab2.col1 * col1 * - 41 AS col2 FROM tab2
----
-11849
-142721
-39401

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 - + col2 * col0 col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT - col0 + 64 AS col0 FROM tab1 AS cor0
----
-16
0
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-4986
SELECT ALL col2 + + col2 + col1 DIV - tab1.col1 FROM tab1
----
107
113
191

skipif mysql # not compatible
query I rowsort label-4986
SELECT ALL col2 + + col2 + col1 / - tab1.col1 FROM tab1
----
107
113
191

query I rowsort
SELECT ALL - + col1 * - 86 AS col1 FROM tab2 cor0
----
1462
2666
5074

query I rowsort
SELECT - col1 + 71 - + ( + col0 + + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-13
-35
16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4989
SELECT DISTINCT col2 + - ( + col0 ) * cor0.col0 * - CAST( col0 AS SIGNED ) + col0 FROM tab0 AS cor0
----
13881
42911
705140

skipif mysql # not compatible
query I rowsort label-4989
SELECT DISTINCT col2 + - ( + col0 ) * cor0.col0 * - CAST ( col0 AS INTEGER ) + col0 FROM tab0 AS cor0
----
13881
42911
705140

query I rowsort
SELECT + col2 * 43 * + ( - col0 ) + cor0.col0 - + col0 AS col1 FROM tab2 AS cor0
----
-129086
-8127
-87204

query I rowsort
SELECT + + col1 + col2 - col0 FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT ALL cor0.col2 * - 51 FROM tab1 AS cor0
----
-2754
-2907
-4896

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4993
SELECT - - col0 * ( 54 ) + - col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4993
SELECT - - col0 * ( 54 ) + - col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * + ( cor0.col0 ) AS col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - col1 + - col1 * + col0 * + col2 - 53 * col1 AS col1 FROM tab2 AS cor0
----
-122838
-51952
-7533

query I rowsort
SELECT DISTINCT col2 * + col2 * - col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ( col0 * col2 ) AS col1 FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4998
SELECT + - CAST( 55 AS SIGNED ) DIV - cor0.col0 + col0 col2 FROM tab0 AS cor0
----
26
36
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4998
SELECT + - CAST ( 55 AS INTEGER ) / - cor0.col0 + col0 col2 FROM tab0 AS cor0
----
26
36
89

query I rowsort
SELECT - cor0.col2 + 67 * - col1 FROM tab2 AS cor0
----
-1177
-2104
-3979

query I rowsort
SELECT ALL - - 41 AS col2 FROM tab2 AS cor0
----
41
41
41

query I rowsort
SELECT + col0 * 37 + - tab0.col2 AS col2 FROM tab0
----
1294
3211
855

query I rowsort
SELECT DISTINCT - cor0.col0 - ( + 52 ) FROM tab2, tab2 AS cor0, tab2 AS cor1
----
-130
-131
-59

query I rowsort
SELECT + 46 AS col1 FROM tab2 AS cor0
----
46
46
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-5004
SELECT + col1 DIV - col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5004
SELECT + col1 / - col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ALL 78 * - col0 + + 8 AS col2 FROM tab1 AS cor0
----
-226
-4984
-6232

onlyif mysql # use DIV operator for integer division
query I rowsort label-5006
SELECT DISTINCT - - col1 + col1 DIV + col0 AS col1 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-5006
SELECT DISTINCT - - col1 + col1 / + col0 AS col1 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT - ( col2 ) * - ( - col0 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col2 AS REAL ) AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL + col1 + + col2 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT 65 + - cor0.col1 FROM tab1 AS cor0
----
39
52
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5011
SELECT ALL - + CAST( NULL AS SIGNED ) * col1 - - col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5011
SELECT ALL - + CAST ( NULL AS INTEGER ) * col1 - - col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5012
SELECT DISTINCT + + col0 DIV + col1 AS col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5012
SELECT DISTINCT + + col0 / + col1 AS col1 FROM tab2 AS cor0
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 90 * col1 col1 FROM tab1 AS cor0
----
-1170
-2340
-900

query I rowsort
SELECT ALL - col1 + - 96 FROM tab1 AS cor0
----
-106
-109
-122

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5015
SELECT ALL - CAST( NULL AS DECIMAL ) * 75 + col2 * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5015
SELECT ALL - CAST ( NULL AS REAL ) * 75 + col2 * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5016
SELECT - + CAST( 95 AS SIGNED ) * col0 FROM tab0 AS cor0
----
-2280
-3325
-8455

skipif mysql # not compatible
query I rowsort label-5016
SELECT - + CAST ( 95 AS INTEGER ) * col0 FROM tab0 AS cor0
----
-2280
-3325
-8455

query I rowsort
SELECT + col0 * - ( col0 ) * - ( 98 ) FROM tab1 cor0
----
401408
627200
882

query I rowsort
SELECT DISTINCT + ( - ( - col2 ) ) * + col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + 51 + 8 * - cor0.col2 FROM tab0 AS cor0
----
-213
-605
43

query I rowsort
SELECT - 54 * - col2 FROM tab2 AS cor0
----
1404
1458
2052

query I rowsort
SELECT ALL + - col2 + - 37 * - col1 AS col0 FROM tab0 AS cor0
----
3149
3285
3588

query I rowsort
SELECT DISTINCT - + 72 * - col1 FROM tab1 cor0
----
1872
720
936

query I rowsort
SELECT + col1 + ( - tab2.col2 + + col2 ) FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 ) * col2 col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - ( cor0.col0 ) FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT + + 99 FROM tab0 AS cor0
----
99
99
99

query I rowsort
SELECT 34 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT + 72 FROM tab2, tab1 cor0, tab2 cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT + 37 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5030
SELECT col1 / CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5030
SELECT col1 / CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col1 + cor0.col1 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL 4 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + ( col2 ) * + col2 + 73 + col0 AS col2 FROM tab2
----
1596
809
827

query I rowsort
SELECT - 56 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

query I rowsort
SELECT + col2 * + 13 + col1 * col0 FROM tab1
----
1381
2288
780

query I rowsort
SELECT - + col0 * - ( - 59 ) FROM tab1 AS cor0
----
-177
-3776
-4720

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 + + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + 68 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT DISTINCT + + col2 * - ( - 6 ) + + cor0.col0 FROM tab1 AS cor0
----
327
406
656

query I rowsort
SELECT ( - 61 ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 51f53697966a79d306a4570537cd91a1

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 cor1
----
26
27
38

query I rowsort
SELECT ALL + col1 * cor0.col2 + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + 44 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5044
SELECT + CAST( NULL AS SIGNED ) * + col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5044
SELECT + CAST ( NULL AS INTEGER ) * + col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5045
SELECT + CAST( NULL AS SIGNED ) * + col2 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5045
SELECT + CAST ( NULL AS INTEGER ) * + col2 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor1.col2 + - ( 97 * cor0.col0 ) FROM tab1, tab0 AS cor0, tab1 AS cor1
----
9 values hashing to 42929b1bc92b3719432e14fd1515a331

query I rowsort
SELECT ALL - cor0.col0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT DISTINCT + col0 + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1190
-552
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-5049
SELECT + 15 DIV col2 col2 FROM tab0
----
0
0
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5049
SELECT + 15 / col2 col2 FROM tab0
----
0
0
15

query I rowsort
SELECT DISTINCT + 30 - + col1 FROM tab2 AS cor0
----
-1
-29
13

query I rowsort
SELECT - 95 * - col2 AS col2 FROM tab2 AS cor0
----
2470
2565
3610

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5052
SELECT 87 * + 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-5052
SELECT 87 * + col0 + + CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 15 * - col0 - - col1 * - 9 FROM tab0 AS cor0
----
-348
-414
516

query I rowsort
SELECT - 32 * cor0.col1 - col2 AS col0 FROM tab2 AS cor0
----
-1019
-1914
-582

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - + cor0.col2 * - 49 col2 FROM tab2 AS cor0
----
1330
1352
1941

query I rowsort
SELECT col2 * - 14 AS col1 FROM tab0 AS cor0
----
-1148
-14
-462

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5057
SELECT - - cor0.col2 * CAST( - 48 AS SIGNED ) * - col2 + - 25 * ( + col2 ) + col1 * ( col2 ) AS col2 FROM tab0 AS cor0
----
120
328164
54285

skipif mysql # not compatible
query I rowsort label-5057
SELECT - - cor0.col2 * CAST ( - 48 AS INTEGER ) * - col2 + - 25 * ( + col2 ) + col1 * ( col2 ) AS col2 FROM tab0 AS cor0
----
120
328164
54285

query I rowsort
SELECT DISTINCT - col0 + - 48 AS col0 FROM tab1 AS cor0
----
-112
-128
-51

query I rowsort
SELECT col0 * + 11 FROM tab0 cor0
----
264
385
979

skipif mysql # not compatible
query I rowsort
SELECT - cor0.col1 + - CAST ( + ( col2 ) AS REAL ) + cor0.col0 * cor0.col1 FROM tab2 AS cor0
----
1288
159
4517

query I rowsort
SELECT + 6 AS col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

query I rowsort
SELECT DISTINCT 71 - tab2.col2 FROM tab2
----
33
44
45

query I rowsort
SELECT ( ( col1 ) ) + + col1 * + 76 FROM tab2
----
1309
2387
4543

query I rowsort
SELECT ( col1 ) * col1 AS col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT ( ( col0 ) + - ( col1 ) ) FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL + 82 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * 57 col0 FROM tab1
----
1482
570
741

query I rowsort
SELECT + + cor0.col1 * - col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - cor0.col2 + col2 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL ( col2 ) * col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT 85 + col0 AS col0 FROM tab1
----
149
165
88

query I rowsort
SELECT ALL - - 83 * + cor0.col1 AS col2 FROM tab1 cor0
----
1079
2158
830

query I rowsort
SELECT DISTINCT 32 AS col2 FROM tab1 AS cor0
----
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-5074
SELECT DISTINCT + - col1 DIV - col1 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5074
SELECT DISTINCT + - col1 / - col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT ALL + col0 + col1 + col2 AS col0 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT col0 - - cor0.col0 * - col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - - col2 + 83 FROM tab1 AS cor0
----
137
140
179

query I rowsort
SELECT + + col2 * 46 AS col2 FROM tab1 AS cor0
----
2484
2622
4416

query I rowsort
SELECT DISTINCT 37 * - 38 + - col0 AS col1 FROM tab1 cor0
----
-1409
-1470
-1486

query I rowsort
SELECT ALL - col2 + cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 57 * col2 * + col0 AS col0 FROM tab0 AS cor0
----
1995
415986
45144

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-5083
SELECT - 86 * 19 DIV - col2 FROM tab1 cor0
----
17
28
30

skipif mysql # not compatible
query I rowsort label-5083
SELECT - 86 * 19 / - col2 FROM tab1 cor0
----
17
28
30

query I rowsort
SELECT DISTINCT + - cor0.col1 * ( col1 ) FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5085
SELECT + + CAST( - col2 AS SIGNED ) * col0 FROM tab1 cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-5085
SELECT + + CAST ( - col2 AS INTEGER ) * col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT col2 * - 91 AS col1 FROM tab2 AS cor0
----
-2366
-2457
-3458

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col0 * - col0 col0 FROM tab1 AS cor0
----
-4039
-6304
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-5088
SELECT ALL - col0 DIV - col2 + col0 DIV - ( - col0 * col0 ) FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5088
SELECT ALL - col0 / - col2 + col0 / - ( - col0 * col0 ) FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ( cor0.col1 ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT + ( - cor0.col2 ) * + col1 * + 34 FROM tab2 AS cor0
----
-21964
-28458
-52156

query I rowsort
SELECT DISTINCT - 8 AS col0 FROM tab0 AS cor0
----
-8

query I rowsort
SELECT DISTINCT + - 30 + + ( col0 ) AS col0 FROM tab1 AS cor0
----
-27
34
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * + col0 col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT ALL + - 7 AS col2 FROM tab2 AS cor0
----
-7
-7
-7

query I rowsort
SELECT DISTINCT ( col1 ) + col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL col1 * + cor0.col2 * - cor0.col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT - - 4 AS col1 FROM tab0 AS cor0
----
4
4
4

query I rowsort
SELECT ALL + 80 + + 94 - + col2 * 29 FROM tab1 AS cor0
----
-1392
-1479
-2610

onlyif mysql # use DIV operator for integer division
query I rowsort label-5099
SELECT ALL col1 + + col0 * - col1 + + col0 DIV col0 col2 FROM tab0
----
-1977
-3297
-8007

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5099
SELECT ALL col1 + + col0 * - col1 + + col0 / col0 col2 FROM tab0
----
-1977
-3297
-8007

query I rowsort
SELECT ALL - + ( 18 ) + col0 AS col1 FROM tab0 AS cor0
----
17
6
71

query I rowsort
SELECT ALL col0 * col1 * + col1 + + col2 FROM tab1 cor0
----
13616
2082
6457

query I rowsort
SELECT - - cor0.col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL 22 * cor0.col2 FROM tab2 AS cor0
----
572
594
836

query I rowsort
SELECT ( + col0 ) * + ( - 66 ) + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-252
-4281
-5376

query I rowsort
SELECT col2 + + 12 FROM tab0
----
13
45
94

query I rowsort
SELECT DISTINCT tab1.col2 AS col1 FROM tab1, tab2, tab0 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5107
SELECT - col2 DIV col2 col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5107
SELECT - col2 / col2 col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + cor0.col0 + + 25 * 34 AS col0 FROM tab2 AS cor0
----
857
928
929

query I rowsort
SELECT col2 + + 55 * - cor0.col2 FROM tab0 AS cor0
----
-1782
-4428
-54

query I rowsort
SELECT ( col0 ) * 33 FROM tab1
----
2112
2640
99

query I rowsort
SELECT ALL cor0.col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL - + cor0.col1 + 14 AS col0 FROM tab2 AS cor0
----
-17
-3
-45

query I rowsort
SELECT DISTINCT - - col0 * - ( - col1 ) FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - 98 * - col0 * - col1 + + ( + col0 ) * + col1 FROM tab2
----
-130271
-21049
-446394

onlyif mysql # use DIV operator for integer division
query I rowsort label-5115
SELECT DISTINCT col1 + tab1.col1 DIV + col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5115
SELECT DISTINCT col1 + tab1.col1 / + col1 FROM tab1
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5116
SELECT 11 DIV - col0 FROM tab2
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5116
SELECT 11 / - col0 FROM tab2
----
-1
0
0

query I rowsort
SELECT + 38 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT DISTINCT tab1.col0 * + col1 - - col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT + - 74 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 5a477330c946251f814fbbfd08e77c28

query I rowsort
SELECT + col0 * - col1 + col0 FROM tab2
----
-1264
-210
-4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5121
SELECT ( + col0 ) * CAST( NULL AS SIGNED ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5121
SELECT ( + col0 ) * CAST ( NULL AS INTEGER ) col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5122
SELECT ALL col0 + CAST( + col2 AS SIGNED ) FROM tab1
----
121
176
57

skipif mysql # not compatible
query I rowsort label-5122
SELECT ALL col0 + CAST ( + col2 AS INTEGER ) FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5123
SELECT ALL cor0.col2 DIV 54 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5123
SELECT ALL cor0.col2 / 54 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + + col0 * col1 * + col0 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT + - col2 + col1 AS col0 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + col2 + cor0.col1 * + col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col0 * 81 FROM tab2 AS cor0
----
567
6318
6399

query I rowsort
SELECT cor0.col2 * - 91 AS col0 FROM tab2 AS cor0
----
-2366
-2457
-3458

query I rowsort
SELECT DISTINCT + cor0.col1 AS col1 FROM tab0, tab1, tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col0 col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5131
SELECT ALL + col1 DIV col0 AS col1 FROM tab1 cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5131
SELECT ALL + col1 / col0 AS col1 FROM tab1 cor0
----
0
0
8

query I rowsort
SELECT + - col0 * + col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + 16 - - 99 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
115

query I rowsort
SELECT DISTINCT + 49 AS col0 FROM tab0 AS cor0
----
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-5135
SELECT DISTINCT - - col0 + col2 DIV col0 AS col0 FROM tab2 AS cor0
----
10
78
79

skipif mysql # not compatible
query I rowsort label-5135
SELECT DISTINCT - - col0 + col2 / col0 AS col0 FROM tab2 AS cor0
----
10
78
79

query I rowsort
SELECT DISTINCT - 80 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( + 34 + - col1 ) col2 FROM tab2 AS cor0
----
-650
646
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5138
SELECT + + col1 / - CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5138
SELECT + + col1 / - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * 67 FROM tab2 AS cor0
----
469
5226
5293

query I rowsort
SELECT ALL col1 + 16 FROM tab1 AS cor0
----
26
29
42

query I rowsort
SELECT DISTINCT + + cor0.col1 * 48 AS col2 FROM tab0 AS cor0
----
4128
4368
4656

query I rowsort
SELECT ALL + - col1 + + col0 * + col1 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-5143
SELECT ALL - ( col2 ) DIV ( - 69 ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5143
SELECT ALL - ( col2 ) / ( - 69 ) FROM tab2
----
0
0
0

query I rowsort
SELECT - + 70 * cor0.col1 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 02590a07a0da6f350b68e7c1ffcc4a1b

query I rowsort
SELECT + col2 * + ( - col1 * + col1 ) AS col0 FROM tab2 cor0
----
-10982
-25947
-90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5146
SELECT + + 91 * 72 DIV col1 + - col0 col2 FROM tab1 AS cor0
----
249
424
591

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5146
SELECT + + 91 * 72 / col1 + - col0 col2 FROM tab1 AS cor0
----
249
424
591

query I rowsort
SELECT ALL - + col2 + - col0 * col1 AS col1 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL + ( col2 ) * col0 + 5 FROM tab0 AS cor0
----
40
7303
797

onlyif mysql # use DIV operator for integer division
query I rowsort label-5149
SELECT DISTINCT col1 DIV 12 AS col2 FROM tab1 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5149
SELECT DISTINCT col1 / 12 AS col2 FROM tab1 AS cor0
----
0
1
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5150
SELECT DISTINCT CAST( NULL AS DECIMAL ) col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5150
SELECT DISTINCT CAST ( NULL AS REAL ) col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + ( 37 ) AS col2 FROM tab1 AS cor0
----
37

query I rowsort
SELECT ALL col1 * + ( + col1 ) + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + col2 - cor0.col1 * col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT + col2 + - 3 * - col1 AS col2 FROM tab0 AS cor0
----
291
292
355

query I rowsort
SELECT col2 * + 92 + col0 FROM tab0 AS cor0
----
127
3060
7633

query I rowsort
SELECT DISTINCT - + cor0.col0 + 48 + col2 AS col2 FROM tab0 AS cor0
----
14
41
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5157
SELECT ALL + 46 DIV + 7 + + col1 FROM tab0 AS cor0
----
103
92
97

skipif mysql # not compatible
query I rowsort label-5157
SELECT ALL + 46 / + 7 + + col1 FROM tab0 AS cor0
----
103
92
97

query I rowsort
SELECT ( + col2 ) - - col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5159
SELECT ALL 10 * + col2 + col2 * CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
10176
3456
3819

skipif mysql # not compatible
query I rowsort label-5159
SELECT ALL 10 * + col2 + col2 * CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
10176
3456
3819

query I rowsort
SELECT + 79 + col0 AS col2 FROM tab1 AS cor0
----
143
159
82

query I rowsort
SELECT + + 53 FROM tab2 cor0
----
53
53
53

query I rowsort
SELECT - col1 * 13 * + col1 FROM tab0
----
-107653
-122317
-96148

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5163
SELECT DISTINCT + CAST( col1 * col1 AS SIGNED ) AS col1 FROM tab1
----
100
169
676

skipif mysql # not compatible
query I rowsort label-5163
SELECT DISTINCT + CAST ( col1 * col1 AS INTEGER ) AS col1 FROM tab1
----
100
169
676

query I rowsort
SELECT + + col1 + col0 * col0 FROM tab0 AS cor0
----
1322
662
8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + cor0.col0 col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT 56 + - col0 * + cor0.col2 FROM tab0 cor0
----
-7242
-736
21

query I rowsort
SELECT - 67 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to fbe03b15d6b951410b38f7e98895006f

query I rowsort
SELECT ALL ( - col1 ) AS col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL - + 88 * - col1 - + cor0.col2 FROM tab0 AS cor0
----
7535
7926
8535

query I rowsort
SELECT ALL + - 11 + col1 * + cor0.col2 FROM tab0 cor0
----
2827
7451
86

query I rowsort
SELECT 17 * col0 FROM tab1
----
1088
1360
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5172
SELECT DISTINCT col1 DIV ( + col2 ) + col1 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5172
SELECT DISTINCT col1 / ( + col2 ) + col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL + col0 * - col1 - - cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
-3926
101
512

query I rowsort
SELECT DISTINCT col1 * - cor0.col2 + col0 AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + 90 + 26 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 1b203c14e07bd085fccb96893918131a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5176
SELECT ALL col1 + - col1 * - CAST( - col1 * - col1 AS SIGNED ) FROM tab2
----
205438
29822
4930

skipif mysql # not compatible
query I rowsort label-5176
SELECT ALL col1 + - col1 * - CAST ( - col1 * - col1 AS INTEGER ) FROM tab2
----
205438
29822
4930

query I rowsort
SELECT + col1 * + col1 * - col1 + + 50 AS col1 FROM tab0 AS cor0
----
-636006
-753521
-912623

query I rowsort
SELECT ( tab0.col2 ) FROM tab0, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5179
SELECT - CAST( NULL AS SIGNED ) / + 69 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5179
SELECT - CAST ( NULL AS INTEGER ) / + 69 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 55 FROM tab0, tab2 AS cor0
----
-55

query I rowsort
SELECT DISTINCT 46 * col1 AS col1 FROM tab2
----
1426
2714
782

query I rowsort
SELECT + col1 + + col1 - col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT + col1 * - col0 + cor0.col1 * col2 - - ( cor0.col0 + ( + col0 ) ) FROM tab2 AS cor0
----
-2912
-539
634

query I rowsort
SELECT ALL + col0 * col2 * + col2 - - col1 AS col1 FROM tab1 AS cor0
----
207946
737293
8774

query I rowsort
SELECT ALL + ( col0 * + col0 ) AS col1 FROM tab1
----
4096
6400
9

query I rowsort
SELECT 26 - col0 * - col0 FROM tab2
----
6110
6267
75

query I rowsort
SELECT tab2.col1 * + col0 - col0 AS col0 FROM tab2
----
1264
210
4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 col2 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 * + col0 col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT cor0.col2 AS col0 FROM tab2, tab1, tab0 cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - 71 * + 8 * col0 - + col2 AS col1 FROM tab1
----
-1758
-36409
-45536

query I rowsort
SELECT col1 * 4 * + col0 FROM tab1
----
2560
312
4160

query I rowsort
SELECT + cor0.col0 + cor0.col2 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 00ff93cbcc751be1393f9e1fd72170f8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5194
SELECT + + CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5194
SELECT + + CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - col0 + + col0 + - col2 FROM tab2
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col0 + - col2 * tab0.col1 col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT 74 + + tab0.col2 FROM tab0
----
107
156
75

query I rowsort
SELECT col0 * - 15 + - col1 * cor0.col0 * - col1 FROM tab1 AS cor0
----
12320
1983
5440

query I rowsort
SELECT DISTINCT - col0 + col1 * + col0 AS col2 FROM tab1 AS cor0
----
576
75
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 7 col2 FROM tab0
----
7
7
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5201
SELECT - col0 + col0 DIV + col0 AS col0 FROM tab1 cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-5201
SELECT - col0 + col0 / + col0 AS col0 FROM tab1 cor0
----
-2
-63
-79

query I rowsort
SELECT DISTINCT + 42 * + col1 FROM tab1 AS cor0
----
1092
420
546

onlyif mysql # use DIV operator for integer division
query I rowsort label-5203
SELECT 91 + col1 + col1 DIV + col0 FROM tab2 AS cor0
----
108
126
150

skipif mysql # not compatible
query I rowsort label-5203
SELECT 91 + col1 + col1 / + col0 FROM tab2 AS cor0
----
108
126
150

onlyif mysql # use DIV operator for integer division
query I rowsort label-5204
SELECT + + 95 DIV - cor0.col2 AS col2 FROM tab1 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-5204
SELECT + + 95 / - cor0.col2 AS col2 FROM tab1 cor0
----
-1
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5205
SELECT ALL ( col2 ) DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5205
SELECT ALL ( col2 ) / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * + col0 AS col1 FROM tab0 WHERE NULL >= NULL
----

query III rowsort
SELECT DISTINCT * FROM tab1 cor0 WHERE NOT NULL BETWEEN NULL AND NULL
----

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT + col1 * + col2 + - cor0.col1 NOT IN ( + cor0.col0 )
----

query I rowsort
SELECT + col2 FROM tab1 WHERE NOT NULL <> ( NULL )
----

query I rowsort
SELECT ALL + col2 AS col1 FROM tab1 WHERE NOT NULL IN ( - col1 * - tab1.col1 * col0 )
----

query I rowsort
SELECT ALL col1 + tab2.col2 FROM tab2 WHERE NOT NULL BETWEEN - col1 - - col0 AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5212
SELECT ALL col0 * cor0.col2 DIV col2 + + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-5212
SELECT ALL col0 * cor0.col2 / col2 + + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE col2 IN ( col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - cor0.col0 + - cor0.col0 * - cor0.col1 FROM tab1 AS cor0 WHERE NOT NULL BETWEEN cor0.col1 + + col1 AND + col2
----

query I rowsort
SELECT - col2 + col0 * col0 + + col0 FROM tab2 AS cor0 WHERE + col0 / col1 > NULL
----

query I rowsort
SELECT DISTINCT cor0.col2 * col2 + - col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT ALL col2 + tab1.col0 FROM tab1 WHERE NOT ( NULL ) <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col0 col1 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT col0 FROM tab0 WHERE NOT NULL <= col0 + + col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5220
SELECT + col2 + col1 DIV col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5220
SELECT + col2 + col1 / col2 FROM tab1
----
54
57
96

query I rowsort
SELECT ALL - col0 + tab2.col1 FROM tab2 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT DISTINCT + col0 - - col0 AS col1 FROM tab1
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5223
SELECT ALL tab0.col2 DIV + col0 - - col0 * col0 FROM tab0
----
1225
577
7921

skipif mysql # not compatible
query I rowsort label-5223
SELECT ALL tab0.col2 / + col0 - - col0 * col0 FROM tab0
----
1225
577
7921

query I rowsort
SELECT + col2 + - tab2.col2 + col0 FROM tab2
----
7
78
79

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-5226
SELECT DISTINCT col0 DIV col1 + - col1 DIV + col2 AS col1 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-5226
SELECT DISTINCT col0 / col1 + - col1 / + col2 AS col1 FROM tab0
----
-1
-2
-97

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL NOT BETWEEN ( col0 ) AND ( NULL )
----

query I rowsort
SELECT DISTINCT + col2 FROM tab0 WHERE col0 + col2 NOT IN ( col1 * + col2 )
----
1
33
82

query I rowsort
SELECT ALL - col1 + col2 * + col2 FROM tab1
----
2890
3239
9203

query I rowsort
SELECT DISTINCT tab1.col1 * col1 AS col1 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL col1 + col1 + - col0 FROM tab2 AS cor0
----
-45
40
55

query I rowsort
SELECT DISTINCT + col0 * + col0 + - col1 AS col0 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT DISTINCT - + col2 + col2 + + col1 AS col0 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 - - col1 * + col0 col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL + col2 + + col1 * col0 FROM tab2 AS cor0
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col0 col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - col0 + + col2 AS col0 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5238
SELECT ALL + col0 + + col1 DIV - cor0.col0 - col0 AS col1 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-5238
SELECT ALL + col0 + + col1 / - cor0.col0 - col0 AS col1 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT - - col2 - + col1 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + col2 + col1 + col2 AS col1 FROM tab2 cor0
----
111
85
93

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-5242
SELECT - col1 * + col2 + cor0.col1 DIV - col0 AS col2 FROM tab2 AS cor0
----
-1534
-646
-841

skipif mysql # not compatible
query I rowsort label-5242
SELECT - col1 * + col2 + cor0.col1 / - col0 AS col2 FROM tab2 AS cor0
----
-1534
-646
-841

query I rowsort
SELECT + + col1 - col1 * - col0 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT col1 * - col2 + col2 * - col0 - tab2.col0 FROM tab2
----
-1033
-3640
-3727

query IIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2 WHERE NOT NULL BETWEEN NULL AND ( - cor0.col0 * + tab2.col0 )
----

query I rowsort
SELECT DISTINCT col2 * - col1 + col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ALL + col2 + + col0 * col0 FROM tab0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-5248
SELECT DISTINCT col2 DIV - 67 + - 9 * col0 AS col0 FROM tab1
----
-27
-576
-721

skipif mysql # not compatible
query I rowsort label-5248
SELECT DISTINCT col2 / - 67 + - 9 * col0 AS col0 FROM tab1
----
-27
-576
-721

query I rowsort
SELECT 77 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT col0 * - 32 AS col1 FROM tab0 cor0
----
-1120
-2848
-768

query I rowsort
SELECT tab2.col2 * - col0 + 92 * - col0 AS col2 FROM tab2
----
-10270
-833
-9204

query I rowsort
SELECT col2 * + col2 * + col2 FROM tab0
----
1
35937
551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-5253
SELECT ALL + tab1.col1 DIV 2 AS col0 FROM tab1
----
13
5
6

skipif mysql # not compatible
query I rowsort label-5253
SELECT ALL + tab1.col1 / 2 AS col0 FROM tab1
----
13
5
6

query I rowsort
SELECT DISTINCT + 5 AS col1 FROM tab1, tab1 AS cor0
----
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5255
SELECT ALL - tab2.col0 DIV tab2.col1 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-5255
SELECT ALL - tab2.col0 / tab2.col1 FROM tab2
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + cor0.col1 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 993162448d72b066e1ac9ba4caa8d8d7

query I rowsort
SELECT + col2 + - col2 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL - + 99 + + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-20
-21
-92

query I rowsort
SELECT DISTINCT + + ( + 93 ) FROM tab1 AS cor0
----
93

query I rowsort
SELECT 74 * col1 AS col2 FROM tab0 AS cor0
----
6364
6734
7178

query I rowsort
SELECT + col1 * - 30 + col1 FROM tab2 AS cor0
----
-1711
-493
-899

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 55 * col2 col0 FROM tab2 cor0
----
-1430
-1485
-2090

onlyif mysql # use DIV operator for integer division
query I rowsort label-5263
SELECT + - col2 + - 84 DIV - col0 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-46
-54
-84

skipif mysql # not compatible
query I rowsort label-5263
SELECT + - col2 + - 84 / - col0 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-46
-54
-84

query I rowsort
SELECT + - 12 * 87 AS col1 FROM tab1 cor0
----
-1044
-1044
-1044

query I rowsort
SELECT + + 11 * col2 FROM tab0 cor0
----
11
363
902

query I rowsort
SELECT 92 * col2 AS col1 FROM tab0
----
3036
7544
92

query I rowsort
SELECT + ( - cor0.col0 ) + 5 * col0 AS col2 FROM tab1 AS cor0
----
12
256
320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5268
SELECT DISTINCT 51 DIV col2 AS col1 FROM tab0 AS cor0
----
0
1
51

skipif mysql # not compatible
query I rowsort label-5268
SELECT DISTINCT 51 / col2 AS col1 FROM tab0 AS cor0
----
0
1
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5269
SELECT ALL - col1 * col2 + CAST( - 34 AS SIGNED ) FROM tab0 AS cor0
----
-131
-2872
-7496

skipif mysql # not compatible
query I rowsort label-5269
SELECT ALL - col1 * col2 + CAST ( - 34 AS INTEGER ) FROM tab0 AS cor0
----
-131
-2872
-7496

query I rowsort
SELECT 62 * - col1 - + 45 AS col0 FROM tab0 AS cor0
----
-5377
-5687
-6059

query I rowsort
SELECT DISTINCT - 11 + col1 * 90 FROM tab1 AS cor0
----
1159
2329
889

query I rowsort
SELECT - col0 * col2 + col0 * 34 AS col1 FROM tab0 AS cor0
----
-4272
1155
24

query I rowsort
SELECT ALL - 15 + col1 * col0 FROM tab0 AS cor0
----
2049
3380
8084

query I rowsort
SELECT DISTINCT col2 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col0 * + col2 + + col0 * 44 FROM tab1 AS cor0
----
11200
294
6464

onlyif mysql # use DIV operator for integer division
query I rowsort label-5276
SELECT ALL ( - col1 ) DIV - 72 AS col0 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5276
SELECT ALL ( - col1 ) / - 72 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * 4 FROM tab1 AS cor0
----
216
228
384

query I rowsort
SELECT ALL + 45 FROM tab0, tab1 cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5279
SELECT col1 + CAST( NULL AS SIGNED ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5279
SELECT col1 + CAST ( NULL AS INTEGER ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5280
SELECT DISTINCT - + col0 * - 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-5280
SELECT DISTINCT - + col0 * - CAST ( NULL AS INTEGER ) + - col1 col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - - col0 - col2 FROM tab2 cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5282
SELECT ALL ( tab1.col0 ) * - col1 DIV col1 + col2 * + col2 FROM tab1
----
2913
3185
9136

skipif mysql # not compatible
query I rowsort label-5282
SELECT ALL ( tab1.col0 ) * - col1 / col1 + col2 * + col2 FROM tab1
----
2913
3185
9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-5283
SELECT - col1 + - ( col1 ) DIV - col0 AS col1 FROM tab1 AS cor0
----
-10
-13
-18

skipif mysql # not compatible
query I rowsort label-5283
SELECT - col1 + - ( col1 ) / - col0 AS col1 FROM tab1 AS cor0
----
-10
-13
-18

query I rowsort
SELECT + col0 * 70 + - col2 FROM tab0 AS cor0
----
1647
2449
6148

onlyif mysql # use DIV operator for integer division
query I rowsort label-5285
SELECT - col2 DIV 4 AS col2 FROM tab1
----
-13
-14
-24

skipif mysql # not compatible
query I rowsort label-5285
SELECT - col2 / 4 AS col2 FROM tab1
----
-13
-14
-24

onlyif mysql # use DIV operator for integer division
query I rowsort label-5286
SELECT - col1 DIV - col2 + - col0 AS col0 FROM tab0 cor0
----
-22
-88
62

skipif mysql # not compatible
query I rowsort label-5286
SELECT - col1 / - col2 + - col0 AS col0 FROM tab0 cor0
----
-22
-88
62

query I rowsort
SELECT col2 * 6 - col2 * - col2 FROM tab0 cor0
----
1287
7
7216

query I rowsort
SELECT cor0.col2 - + col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 * - col0 col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT - 74 * - col2 AS col1 FROM tab2 AS cor0
----
1924
1998
2812

query I rowsort
SELECT + - 55 * - col0 AS col1 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT - col2 * col2 + col1 FROM tab1
----
-2890
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 56 col1 FROM tab0
----
-56

query I rowsort
SELECT 23 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query I rowsort
SELECT ( col2 ) + - 15 * + tab0.col0 FROM tab0
----
-1253
-327
-524

query I rowsort
SELECT DISTINCT + ( tab2.col0 + col2 ) AS col2 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 31 col0 FROM tab2 AS cor0
----
31

query I rowsort
SELECT DISTINCT - ( + col2 ) * col2 - 17 AS col0 FROM tab1 AS cor0
----
-2933
-3266
-9233

query I rowsort
SELECT DISTINCT 97 AS col2 FROM tab0
----
97

query I rowsort
SELECT DISTINCT 22 AS col1 FROM tab2
----
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-5301
SELECT DISTINCT + 17 DIV col0 FROM tab2 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-5301
SELECT DISTINCT + 17 / col0 FROM tab2 AS cor0
----
0
2

query I rowsort
SELECT - col2 * col2 + col2 * + col2 * col1 FROM tab1 AS cor0
----
110592
29241
72900

query I rowsort
SELECT ALL + cor0.col2 * + col0 + col1 * - col1 * - col2 FROM tab0 cor0
----
244860
686340
9444

query I rowsort
SELECT + col0 + cor0.col0 * - col1 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL 39 * + col2 * + col0 AS col1 FROM tab2 AS cor0
----
117078
7371
79092

onlyif mysql # use DIV operator for integer division
query I rowsort label-5306
SELECT DISTINCT + col1 + + col1 DIV col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-5306
SELECT DISTINCT + col1 + + col1 / col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT DISTINCT - 70 + + col1 AS col1 FROM tab2 AS cor0
----
-11
-39
-53

query I rowsort
SELECT 38 + - col2 * - col0 FROM tab1
----
200
3686
7718

query I rowsort
SELECT - - col1 * col1 AS col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT + 7 * + col0 FROM tab1 AS cor0
----
21
448
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-5311
SELECT ALL + col1 + - col1 DIV - ( 75 + - col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5311
SELECT ALL + col1 + - col1 / - ( 75 + - col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + ( col2 ) * 0 * col1 + - cor0.col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT col2 * col2 + + col0 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL - cor0.col2 * col1 + CAST ( - 24 AS REAL ) col0 FROM tab1 AS cor0
----
-1272
-1428
-594

query I rowsort
SELECT + col2 + + col2 * col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL + + col2 + cor0.col0 AS col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5317
SELECT ALL 14 DIV col2 + CAST( 25 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
25
25
25

skipif mysql # not compatible
query I rowsort label-5317
SELECT ALL 14 / col2 + CAST ( 25 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
25
25
25

query I rowsort
SELECT ALL + col2 - col1 * col0 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT tab0.col2 + col1 * + col0 * col1 FROM tab0
----
177537
329316
737091

query I rowsort
SELECT ALL - 51 * col1 + - col0 FROM tab0 AS cor0
----
-4410
-4730
-4982

query I rowsort
SELECT + 25 * col2 FROM tab0 AS cor0
----
2050
25
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * 10 - col2 col2 FROM tab2
----
43
752
754

query I rowsort
SELECT 76 * col2 FROM tab0
----
2508
6232
76

skipif mysql # not compatible
query I rowsort
SELECT ALL 83 + + col2 * col0 + - CAST ( 51 AS REAL ) AS col2 FROM tab2
----
2060
221
3034

query I rowsort
SELECT + col1 * + col2 - col2 AS col0 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL + cor0.col1 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT + cor0.col0 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab2, tab2 AS cor2
----
7
78
79

query I rowsort
SELECT ALL 98 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 6624b1f09c0594f5576803ac29f4499d

query I rowsort
SELECT tab0.col0 + col2 + col1 * + col0 AS col0 FROM tab0
----
2121
3431
8270

query I rowsort
SELECT 5 + ( col2 + col2 ) AS col1 FROM tab1
----
113
119
197

query I rowsort
SELECT ALL - 73 FROM tab2, tab2 AS cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

query I rowsort
SELECT - - ( - 43 ) + + cor0.col1 AS col1 FROM tab0 cor0
----
43
48
54

query I rowsort
SELECT DISTINCT - 27 + + col2 + - col2 FROM tab2
----
-27

query I rowsort
SELECT - col2 * + col1 * col1 + col1 AS col0 FROM tab0 AS cor0
----
-243982
-678951
-9312

query I rowsort
SELECT ALL col0 + + 78 + + col0 FROM tab0
----
126
148
256

onlyif mysql # use DIV operator for integer division
query I rowsort label-5336
SELECT 3 DIV - col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5336
SELECT 3 / - col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5337
SELECT + ( + col0 ) DIV + col0 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5337
SELECT + ( + col0 ) / + col0 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + - col2 + + 17 * + col1 FROM tab2 AS cor0
----
251
500
977

query I rowsort
SELECT ALL 31 + - ( col2 ) * + 47 FROM tab2
----
-1191
-1238
-1755

onlyif mysql # use DIV operator for integer division
query I rowsort label-5340
SELECT DISTINCT ( - col2 ) - ( col1 ) * col2 DIV + col1 AS col1 FROM tab0 AS cor0
----
-164
-2
-66

skipif mysql # not compatible
query I rowsort label-5340
SELECT DISTINCT ( - col2 ) - ( col1 ) * col2 / + col1 AS col1 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT ALL + col2 * + col2 * col1 AS col0 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT + 4 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT - col2 + + col0 * - cor0.col1 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL - 27 FROM tab1, tab2 cor0, tab1 AS cor1, tab1 cor2
----
81 values hashing to 96d69a44243853624f324b296563e205

onlyif mysql # use DIV operator for integer division
query I rowsort label-5345
SELECT - - col1 * col0 DIV ( col1 ) AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5345
SELECT - - col1 * col0 / ( col1 ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - - col0 * col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + + cor0.col1 + cor0.col2 * col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT cor0.col1 + 66 FROM tab0 AS cor0
----
152
157
163

query I rowsort
SELECT DISTINCT + col1 + - 60 FROM tab1 AS cor0
----
-34
-47
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-5350
SELECT ALL - col2 + - col1 DIV col0 FROM tab1 AS cor0
----
-57
-62
-96

skipif mysql # not compatible
query I rowsort label-5350
SELECT ALL - col2 + - col1 / col0 FROM tab1 AS cor0
----
-57
-62
-96

query I rowsort
SELECT ALL 42 * cor1.col1 + 57 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 988b8a6f733c5e99badc2869187af890

query I rowsort
SELECT col0 + col1 * + col0 * + 70 AS col1 FROM tab0 AS cor0
----
144504
237685
567019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 55 + col1 col1 FROM tab1 AS cor0
----
-29
-42
-45

query I rowsort
SELECT + + 6 + col1 AS col2 FROM tab2 cor0
----
23
37
65

query I rowsort
SELECT ALL ( col1 ) * + col2 + + 85 AS col0 FROM tab2 AS cor0
----
1619
731
922

onlyif mysql # use DIV operator for integer division
query I rowsort label-5356
SELECT DISTINCT - - col0 DIV - cor0.col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-5356
SELECT DISTINCT - - col0 / - cor0.col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT ALL - 60 + + col2 FROM tab0 AS cor0
----
-27
-59
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-5358
SELECT ALL ( - col2 ) DIV cor0.col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5358
SELECT ALL ( - col2 ) / cor0.col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT + ( + col0 ) AS col1 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( col1 AS REAL ) * cor0.col0 + - ( col0 ) + col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col0 * + col2 + cor0.col2 col0 FROM tab2 AS cor0
----
2113
247
3057

onlyif mysql # use DIV operator for integer division
query I rowsort label-5362
SELECT DISTINCT col2 DIV + tab0.col0 AS col1 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-5362
SELECT DISTINCT col2 / + tab0.col0 AS col1 FROM tab0
----
0
1

query I rowsort
SELECT - ( 97 ) * col0 AS col2 FROM tab2 AS cor0
----
-679
-7566
-7663

query I rowsort
SELECT ALL - + col0 * 84 AS col2 FROM tab2 AS cor0
----
-588
-6552
-6636

query I rowsort
SELECT - 8 + - col0 FROM tab2 AS cor0
----
-15
-86
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5366
SELECT ALL + + col0 DIV + col2 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5366
SELECT ALL + + col0 / + col2 FROM tab1 cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5367
SELECT - col0 DIV + ( col1 ) - - col0 FROM tab2 AS cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-5367
SELECT - col0 / + ( col1 ) - - col0 FROM tab2 AS cor0
----
7
75
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5368
SELECT ALL - + col0 + CAST( + col1 AS SIGNED ) - col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5368
SELECT ALL - + col0 + CAST ( + col1 AS INTEGER ) - col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 53 col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT DISTINCT - cor0.col0 + 66 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
-23
31
42

skipif mysql # not compatible
query I rowsort
SELECT ALL 21 / col0 + - CAST ( + col0 AS REAL ) / + col0 AS col0 FROM tab1
----
-1
-1
6

query I rowsort
SELECT + col0 * - 26 + col2 AS col2 FROM tab2 AS cor0
----
-155
-2002
-2016

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 68 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query I rowsort
SELECT col0 * - ( 68 + tab2.col2 ) AS col2 FROM tab2
----
-665
-7332
-8374

onlyif mysql # use DIV operator for integer division
query I rowsort label-5375
SELECT - col2 + 91 DIV col1 FROM tab2 AS cor0
----
-25
-25
-33

skipif mysql # not compatible
query I rowsort label-5375
SELECT - col2 + 91 / col1 FROM tab2 AS cor0
----
-25
-25
-33

query I rowsort
SELECT + 59 FROM tab2, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT - col1 + col2 * col1 AS col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT + col1 * + tab2.col1 AS col0 FROM tab2
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 25 col0 FROM tab0
----
25
25
25

query I rowsort
SELECT + ( - col0 ) + - col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT ALL - - col2 * - col1 + + ( col0 ) + col1 * col0 FROM tab0 AS cor0
----
-750
3333
726

query I rowsort
SELECT DISTINCT col1 - col1 AS col0 FROM tab1 cor0
----
0

query I rowsort
SELECT - 93 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-7998
-8463
-9021

query I rowsort
SELECT ALL - 56 * col0 FROM tab1 AS cor0
----
-168
-3584
-4480

query I rowsort
SELECT - - 9 * cor0.col0 AS col1 FROM tab1 AS cor0
----
27
576
720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 49 col1 FROM tab1 AS cor0
----
-49
-49
-49

query I rowsort
SELECT DISTINCT - col0 * - col2 + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + - cor0.col0 * + col2 + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT 97 - col0 * 79 FROM tab1 AS cor0
----
-140
-4959
-6223

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( cor0.col0 ) * 30 col1 FROM tab0 AS cor0
----
-1050
-2670
-720

query I rowsort
SELECT DISTINCT + tab2.col1 * - col0 * - col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT + tab2.col0 * + col1 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5393
SELECT - + cor0.col0 DIV col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5393
SELECT - + cor0.col0 / col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + 2 * + col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT col2 + col1 * + col2 * - 37 AS col1 FROM tab0
----
-104973
-276012
-3588

query I rowsort
SELECT - col1 + - ( col2 ) AS col2 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT + tab1.col0 FROM tab1, tab2 cor0
----
3
64
80

query I rowsort
SELECT ALL col0 + 31 * 72 AS col2 FROM tab2 AS cor0
----
2239
2310
2311

query I rowsort
SELECT - col1 * + 42 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT + col2 * - 83 * - 24 AS col1 FROM tab0 AS cor0
----
163344
1992
65736

query I rowsort
SELECT - 77 * + col0 + + col1 FROM tab1 AS cor0
----
-205
-4918
-6147

query I rowsort
SELECT + col1 * 89 + cor0.col2 + - ( + 11 ) AS col2 FROM tab0 cor0
----
7676
8170
8623

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5403
SELECT + col1 * col0 / - col1 + + CAST( NULL AS SIGNED ) / col1 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5403
SELECT + col1 * col0 / - col1 + + CAST ( NULL AS INTEGER ) / col1 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5404
SELECT + col1 * col0 + col1 DIV - 71 FROM tab2 cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-5404
SELECT + col1 * col0 + col1 / - 71 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5405
SELECT 49 DIV + 4 + + col1 * 56 * - col1 AS col1 FROM tab0 AS cor0
----
-414164
-463724
-526892

skipif mysql # not compatible
query I rowsort label-5405
SELECT 49 / + 4 + + col1 * 56 * - col1 AS col1 FROM tab0 AS cor0
----
-414164
-463724
-526892

query I rowsort
SELECT + 27 * + col1 FROM tab0 AS cor0
----
2322
2457
2619

query I rowsort
SELECT - - 21 AS col1 FROM tab1 AS cor0
----
21
21
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-5408
SELECT - 20 DIV + col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5408
SELECT - 20 / + col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 99 ) col1 FROM tab2
----
-99
-99
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col1 ) * - col1 col2 FROM tab1
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5411
SELECT ALL col1 + + 41 DIV 15 AS col1 FROM tab0
----
88
93
99

skipif mysql # not compatible
query I rowsort label-5411
SELECT ALL col1 + + 41 / 15 AS col1 FROM tab0
----
88
93
99

query I rowsort
SELECT DISTINCT col0 * ( col1 ) + col2 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-5413
SELECT + - col2 DIV 89 + col1 * col1 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-5413
SELECT + - col2 / 89 + col1 * col1 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5414
SELECT DISTINCT + col2 + CAST( col0 AS SIGNED ) * col0 FROM tab1 AS cor0
----
4153
63
6496

skipif mysql # not compatible
query I rowsort label-5414
SELECT DISTINCT + col2 + CAST ( col0 AS INTEGER ) * col0 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5415
SELECT DISTINCT + - col1 + CAST( NULL AS DECIMAL ) + 71 / - col2 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5415
SELECT DISTINCT + - col1 + CAST ( NULL AS REAL ) + 71 / - col2 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col2 * - 42 + + col0 FROM tab2 AS cor0
----
-1014
-1127
-1517

query I rowsort
SELECT + col1 + 54 FROM tab2 AS cor0
----
113
71
85

query I rowsort
SELECT ALL - col1 * + col0 - col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT + cor0.col2 * + ( - 21 ) - - col1 AS col2 FROM tab0 cor0
----
-1631
-607
76

query I rowsort
SELECT + + col2 * col2 * - col0 + col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-204687
-5832
-728064

query I rowsort
SELECT 4 * - col1 + col1 FROM tab2 cor0
----
-177
-51
-93

query I rowsort
SELECT DISTINCT - col0 * + 74 FROM tab2
----
-518
-5772
-5846

query I rowsort
SELECT ( - col0 ) * cor0.col0 + col1 + - cor0.col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5424
SELECT ALL + + CAST( + col1 AS SIGNED ) col1 FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5424
SELECT ALL + + CAST ( + col1 AS INTEGER ) col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - + 84 FROM tab0 AS cor0
----
-84
-84
-84

query I rowsort
SELECT 89 + col1 FROM tab1 AS cor0
----
102
115
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-5427
SELECT DISTINCT - + col1 * col0 + col2 DIV col0 FROM tab0 AS cor0
----
-2063
-3395
-8099

skipif mysql # not compatible
query I rowsort label-5427
SELECT DISTINCT - + col1 * col0 + col2 / col0 FROM tab0 AS cor0
----
-2063
-3395
-8099

query I rowsort
SELECT - col0 + - col2 * + col1 FROM tab0 cor0
----
-132
-2862
-7551

query I rowsort
SELECT ALL + + cor0.col1 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5430
SELECT ALL - 93 * col0 - CAST( NULL AS SIGNED ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5430
SELECT ALL - 93 * col0 - CAST ( NULL AS INTEGER ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5431
SELECT DISTINCT + col2 DIV col0 col0 FROM tab2
----
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5431
SELECT DISTINCT + col2 / col0 col0 FROM tab2
----
0
3

query I rowsort
SELECT DISTINCT col1 + + col0 AS col0 FROM tab1 cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5433
SELECT cor0.col2 * - CAST( + col2 AS SIGNED ) - + col0 FROM tab0 AS cor0
----
-1113
-36
-6813

skipif mysql # not compatible
query I rowsort label-5433
SELECT cor0.col2 * - CAST ( + col2 AS INTEGER ) - + col0 FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT ALL - col2 + - col1 * 36 AS col1 FROM tab0 AS cor0
----
-3129
-3358
-3493

query I rowsort
SELECT ALL - col2 + 56 AS col2 FROM tab2 AS cor0
----
18
29
30

query I rowsort
SELECT DISTINCT + 18 * + ( - cor0.col1 * - 24 ) AS col1 FROM tab2, tab0 AS cor0, tab2 cor1
----
37152
39312
41904

onlyif mysql # use DIV operator for integer division
query I rowsort label-5437
SELECT ALL + - col2 + + col1 + - col2 DIV col2 FROM tab1 AS cor0
----
-29
-48
-84

skipif mysql # not compatible
query I rowsort label-5437
SELECT ALL + - col2 + + col1 + - col2 / col2 FROM tab1 AS cor0
----
-29
-48
-84

query I rowsort
SELECT 14 + tab1.col1 AS col0 FROM tab1
----
24
27
40

query I rowsort
SELECT ALL col0 * col1 - 62 * - col1 * col2 FROM tab0
----
178020
470743
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5440
SELECT ALL - col2 * CAST( cor0.col0 AS SIGNED ) - col1 AS col1 FROM tab2 cor0
----
-2087
-220
-3019

skipif mysql # not compatible
query I rowsort label-5440
SELECT ALL - col2 * CAST ( cor0.col0 AS INTEGER ) - col1 AS col1 FROM tab2 cor0
----
-2087
-220
-3019

query I rowsort
SELECT ALL + 33 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT DISTINCT - cor0.col1 + + col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT + - cor0.col1 * - 47 AS col0 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT + 77 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT ALL + cor0.col2 AS col2 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT tab2.col0 * + col1 + + ( - col2 + col2 ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL + 73 AS col0 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT ALL tab0.col2 + + col1 * - 42 FROM tab0
----
-3579
-3740
-4073

query I rowsort
SELECT ALL + ( 50 ) FROM tab2, tab2 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT + col2 + tab0.col2 + - 23 AS col1 FROM tab0
----
-21
141
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5451
SELECT col2 + CAST( - col1 AS SIGNED ) + - col0 FROM tab0
----
-131
-77
-98

skipif mysql # not compatible
query I rowsort label-5451
SELECT col2 + CAST ( - col1 AS INTEGER ) + - col0 FROM tab0
----
-131
-77
-98

query I rowsort
SELECT + col2 * - col2 * 49 + + col1 FROM tab0
----
-329385
-53275
48

query I rowsort
SELECT DISTINCT col1 + col2 * + tab2.col1 AS col0 FROM tab2
----
1593
663
868

query I rowsort
SELECT DISTINCT cor0.col1 - - col2 AS col0 FROM tab2 cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5455
SELECT - + col2 * - CAST( NULL AS SIGNED ) + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5455
SELECT - + col2 * - CAST ( NULL AS INTEGER ) + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 * - 83 - col0 FROM tab0 AS cor0
----
7114
7464
8016

query I rowsort
SELECT DISTINCT 51 AS col2 FROM tab2, tab1 AS cor0
----
51

query I rowsort
SELECT - - col0 * col2 - + col2 * col0 * col0 AS col0 FROM tab0 cor0
----
-1190
-18216
-642224

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 + col1 + + col0 * col0 AS col0 FROM tab1 AS cor0
----
-1267
-127
458

query I rowsort
SELECT 0 * + 72 FROM tab0
----
0
0
0

query I rowsort
SELECT - col0 - 15 * + col0 FROM tab2
----
-112
-1248
-1264

query I rowsort
SELECT DISTINCT - ( tab0.col0 ) + col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL col1 + col2 + - col0 AS col2 FROM tab2
----
-24
51
7

query I rowsort
SELECT DISTINCT - col2 + + 11 FROM tab1
----
-43
-46
-85

query I rowsort
SELECT ( + 37 * - col2 ) - ( 61 ) * col2 FROM tab0
----
-3234
-8036
-98

query I rowsort
SELECT DISTINCT + - 98 * col0 FROM tab2 AS cor0
----
-686
-7644
-7742

query I rowsort
SELECT ALL + cor0.col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - cor0.col0 * - col2 * + cor0.col0 AS col2 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT ALL - - col2 * col0 - - 33 FROM tab0 AS cor0
----
68
7331
825

query I rowsort
SELECT + 33 * - cor0.col0 * ( - col2 * col1 ) AS col1 FROM tab0 AS cor0
----
112035
21915894
2247696

query I rowsort
SELECT ALL - col1 * col1 * 0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 61 * + cor0.col1 col0 FROM tab1 AS cor0
----
-1586
-610
-793

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col0 ) col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col0 * - 14 AS col0 FROM tab0 AS cor0
----
102172
11088
490

query I rowsort
SELECT DISTINCT - cor0.col1 + + col2 * col1 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT - 46 * cor0.col0 FROM tab1 AS cor0
----
-138
-2944
-3680

query I rowsort
SELECT ( 23 ) AS col2 FROM tab0 AS cor0
----
23
23
23

query I rowsort
SELECT DISTINCT col1 + + 92 AS col0 FROM tab0 AS cor0
----
178
183
189

query I rowsort
SELECT DISTINCT + + col2 * + cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT cor0.col1 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + col2 + + col2 * col0 AS col0 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-5482
SELECT + col1 * col2 + + ( + 85 ) DIV cor0.col0 - + CAST( 79 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
1170
1353
492

skipif mysql # not compatible
query I rowsort label-5482
SELECT + col1 * col2 + + ( + 85 ) / cor0.col0 - + CAST ( 79 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
1170
1353
492

query I rowsort
SELECT - - col2 * + col0 - ( col1 ) AS col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT + 19 - + col0 * + ( + col0 ) AS col0 FROM tab1 AS cor0
----
-4077
-6381
10

query I rowsort
SELECT ALL - 17 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT DISTINCT col0 + - col2 * - col0 + - col0 AS col0 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-5487
SELECT + CAST( + 37 AS SIGNED ) DIV - col2 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5487
SELECT + CAST ( + 37 AS INTEGER ) / - col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT + col0 + 42 * col0 + col2 AS col2 FROM tab0
----
1065
1506
3909

query I rowsort
SELECT + col0 * 57 + + col0 FROM tab2 AS cor0
----
406
4524
4582

query I rowsort
SELECT col2 * ( 98 + col2 ) * col0 FROM tab0 AS cor0
----
103752
1313640
3465

query I rowsort
SELECT ALL col0 * col1 * - col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT ALL - cor0.col0 * - 39 FROM tab0 AS cor0
----
1365
3471
936

query I rowsort
SELECT DISTINCT col0 + - tab2.col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL + 12 + col1 * + tab0.col1 FROM tab0
----
7408
8293
9421

query I rowsort
SELECT ALL + ( col2 ) * - tab2.col1 + col2 AS col0 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT col2 + 47 * 74 FROM tab1
----
3532
3535
3574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col1 + + 86 col1 FROM tab0 AS cor0
----
7482
8367
9495

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5498
SELECT DISTINCT - + cor0.col0 * CAST( 23 AS SIGNED ) - col0 * col0 FROM tab1 AS cor0
----
-5568
-78
-8240

skipif mysql # not compatible
query I rowsort label-5498
SELECT DISTINCT - + cor0.col0 * CAST ( 23 AS INTEGER ) - col0 * col0 FROM tab1 AS cor0
----
-5568
-78
-8240

query I rowsort
SELECT DISTINCT cor0.col2 - - 41 * + 4 FROM tab0 AS cor0
----
165
197
246

query I rowsort
SELECT - 74 * col0 FROM tab1 cor0
----
-222
-4736
-5920

query I rowsort
SELECT ALL 18 AS col1 FROM tab0 AS cor0
----
18
18
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-5502
SELECT - cor0.col1 + + col2 DIV col0 AS col1 FROM tab2 AS cor0
----
-17
-28
-59

skipif mysql # not compatible
query I rowsort label-5502
SELECT - cor0.col1 + + col2 / col0 AS col1 FROM tab2 AS cor0
----
-17
-28
-59

query I rowsort
SELECT DISTINCT + 86 * col2 FROM tab0 cor0
----
2838
7052
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5504
SELECT + - CAST( NULL AS SIGNED ) * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5504
SELECT + - CAST ( NULL AS INTEGER ) * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 16 + + 96 * - col1 + + col1 FROM tab2 AS cor0
----
-1599
-2929
-5589

query I rowsort
SELECT ALL 89 + - col0 FROM tab2 AS cor0
----
10
11
82

query I rowsort
SELECT DISTINCT col1 * - 11 * col1 AS col2 FROM tab2 AS cor0
----
-10571
-3179
-38291

query I rowsort
SELECT tab0.col2 * - 76 AS col2 FROM tab0
----
-2508
-6232
-76

query I rowsort
SELECT ALL - 35 FROM tab0, tab2, tab1 AS cor0, tab1
----
81 values hashing to 7fbbc209618bf287c81172ef2c617496

query I rowsort
SELECT ALL col1 * tab2.col1 AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT col2 - col1 * col0 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT 85 AS col1 FROM tab0, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 5e8deeabad7bbbaf313fcdcb4adc75eb

query I rowsort
SELECT - - col1 + - 76 AS col1 FROM tab2 AS cor0
----
-17
-45
-59

query I rowsort
SELECT ALL ( + tab0.col1 + - ( - col2 ) * col1 ) FROM tab0
----
194
2924
7553

query I rowsort
SELECT cor0.col0 AS col2 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT col1 + + col1 * + col2 * col0 AS col1 FROM tab2 AS cor0
----
119711
51051
5890

onlyif mysql # use DIV operator for integer division
query I rowsort label-5517
SELECT col2 DIV col1 AS col2 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5517
SELECT col2 / col1 AS col2 FROM tab1 cor0
----
2
5
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5518
SELECT ALL cor0.col2 * - col2 + CAST( NULL AS SIGNED ) / - col1 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-5518
SELECT ALL cor0.col2 * - col2 + CAST ( NULL AS INTEGER ) / - col1 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5519
SELECT + 38 DIV + col0 FROM tab2 cor0
----
0
0
5

skipif mysql # not compatible
query I rowsort label-5519
SELECT + 38 / + col0 FROM tab2 cor0
----
0
0
5

query I rowsort
SELECT + + col2 * col0 * col0 + col2 - - col1 * - 30 FROM tab2 AS cor0
----
156440
236686
420

query I rowsort
SELECT - + 26 AS col2 FROM tab1 AS cor0
----
-26
-26
-26

query I rowsort
SELECT + 25 * col0 - - 37 AS col1 FROM tab1 AS cor0
----
112
1637
2037

onlyif mysql # use DIV operator for integer division
query I rowsort label-5523
SELECT ALL - col2 DIV col0 AS col1 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-5523
SELECT ALL - col2 / col0 AS col1 FROM tab2
----
-3
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5524
SELECT - col0 DIV + col1 + - col1 FROM tab2
----
-21
-31
-60

skipif mysql # not compatible
query I rowsort label-5524
SELECT - col0 / + col1 + - col1 FROM tab2
----
-21
-31
-60

query I rowsort
SELECT DISTINCT 4 - 30 * cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
-296
-386
-776

query I rowsort
SELECT - col2 * + 21 AS col0 FROM tab2 AS cor0
----
-546
-567
-798

query I rowsort
SELECT DISTINCT 55 * tab2.col0 FROM tab2
----
385
4290
4345

query I rowsort
SELECT tab0.col1 - col1 * + col0 * col1 FROM tab0
----
-177418
-329218
-736918

query I rowsort
SELECT - - col2 + cor0.col2 AS col0 FROM tab1 cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-5530
SELECT DISTINCT 99 DIV - col1 FROM tab0 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5530
SELECT DISTINCT 99 / - col1 FROM tab0 cor0
----
-1

query I rowsort
SELECT ALL col2 + - col0 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-24
-583
-944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - col1 col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL - - col0 * cor0.col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + + 99 AS col0 FROM tab0 AS cor0
----
99

query I rowsort
SELECT ALL ( tab1.col1 * + col1 ) FROM tab1
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 31 col0 FROM tab2
----
-31

query I rowsort
SELECT ALL col2 * 24 FROM tab0
----
1968
24
792

query I rowsort
SELECT ALL - tab1.col1 * - col0 + tab1.col2 * + tab1.col0 FROM tab1
----
240
4288
8720

query I rowsort
SELECT DISTINCT - col1 + col2 + - tab0.col1 * col1 * + col0 FROM tab0
----
-177557
-329411
-737018

query I rowsort
SELECT cor0.col2 * col2 - col0 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT + - 6 + + col1 + cor0.col2 AS col1 FROM tab1 AS cor0
----
103
61
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col2 col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - ( + col2 ) * + col1 + - col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

onlyif mysql # use DIV operator for integer division
query I rowsort label-5544
SELECT ALL - cor0.col0 DIV - cor0.col2 + - cor0.col2 FROM tab0 AS cor0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-5544
SELECT ALL - cor0.col0 / - cor0.col2 + - cor0.col2 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT DISTINCT col0 * - col1 - - col2 FROM tab0 cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col2 col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + cor0.col1 - col0 * + col2 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * col0 * - col0 + - col1 * + col2 + col2 col1 FROM tab0 AS cor0
----
1129
16203
642142

query I rowsort
SELECT + cor0.col0 * - col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col2 * + col1 + - col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT + ( - col0 ) - cor0.col1 * - col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT ALL - col1 * - col2 + - col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT 78 AS col2 FROM tab1 AS cor0
----
78
78
78

query I rowsort
SELECT DISTINCT - 35 + + col0 - - col2 FROM tab0 AS cor0
----
1
136
22

query I rowsort
SELECT + 51 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT - col0 * + 35 AS col1 FROM tab0 AS cor0
----
-1225
-3115
-840

skipif mysql # not compatible
query I rowsort
SELECT + col0 * + CAST ( + col2 AS REAL ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - + ( col2 ) * - col1 + - col2 FROM tab1 AS cor0
----
1152
1350
513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5559
SELECT DISTINCT - CAST( NULL AS DECIMAL ) + col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5559
SELECT DISTINCT - CAST ( NULL AS REAL ) + col1 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + ( - cor0.col1 ) + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - col0 * col0 * col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT + 34 AS col1 FROM tab2 AS cor0
----
34

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT ALL + + col2 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col2 * col2 + + col2 AS col1 FROM tab1 AS cor0
----
2970
3306
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + col2 col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5567
SELECT col0 DIV col0 + col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5567
SELECT col0 / col0 + col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ALL - - col1 * + col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-5569
SELECT col0 DIV col0 col2 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5569
SELECT col0 / col0 col2 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT col1 * - col2 * cor0.col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * + col1 col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL cor0.col2 * cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to b2e5b025b1c725661248b0f29aaef908

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab0, tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL cor0.col2 + cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to e5ee086d16e1b2450d3f7ac8d26a0f7b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5575
SELECT col0 * col0 + col0 DIV col0 col1 FROM tab2
----
50
6085
6242

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5575
SELECT col0 * col0 + col0 / col0 col1 FROM tab2
----
50
6085
6242

query I rowsort
SELECT + tab1.col1 * col1 AS col1 FROM tab1 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT - col0 + tab2.col2 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT + col1 * + cor0.col1 * col1 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT ALL + cor0.col0 + + col1 * - col0 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT + col1 * - col2 + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL cor0.col0 + + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL ( col0 ) + + col0 FROM tab2
----
14
156
158

query I rowsort
SELECT DISTINCT col0 * + col0 + col1 AS col0 FROM tab2
----
6143
6258
80

query I rowsort
SELECT ALL - - col2 + + col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT col0 * + col1 - + tab1.col2 FROM tab1
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5586
SELECT DISTINCT col2 DIV + col2 + + col0 col0 FROM tab1
----
4
65
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5586
SELECT DISTINCT col2 / + col2 + + col0 col0 FROM tab1
----
4
65
81

query I rowsort
SELECT ALL - col1 + tab2.col0 AS col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab0, tab1, tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col2 + - col2 * + col1 AS col2 FROM tab1
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 + col0 col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT ALL - ( - ( - cor1.col1 ) ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT - - ( cor0.col0 ) FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col0 ) col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + - 42 * + cor0.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d878f2d5a4eb729b88a774e1cbc05cf8

query I rowsort
SELECT col2 * - col2 - col2 * + col1 FROM tab2
----
-1566
-2090
-2210

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5597
SELECT CAST( - col1 AS SIGNED ) + - col0 FROM tab2 AS cor0
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-5597
SELECT CAST ( - col1 AS INTEGER ) + - col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT 37 * + col2 AS col1 FROM tab1 AS cor0
----
1998
2109
3552

query I rowsort
SELECT col1 + - col2 + col2 AS col1 FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 8 * + col0 + 48 col0 FROM tab0 AS cor0
----
-144
-232
-664

query I rowsort
SELECT - - 39 + col2 + 25 AS col2 FROM tab0 AS cor0
----
146
65
97

query I rowsort
SELECT col0 * + cor0.col0 + + 83 + - ( - col1 ) FROM tab0 AS cor0
----
1405
745
8095

query I rowsort
SELECT - col0 + + 80 AS col0 FROM tab2
----
1
2
73

query I rowsort
SELECT + + ( col1 ) * - col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col2 + + col0 + ( 14 + + col0 ) AS col2 FROM tab1 AS cor0
----
199
270
74

query I rowsort
SELECT DISTINCT + 23 + col1 AS col1 FROM tab0
----
109
114
120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5607
SELECT DISTINCT + ( + tab2.col2 ) + CAST( NULL AS DECIMAL ) FROM tab2, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5607
SELECT DISTINCT + ( + tab2.col2 ) + CAST ( NULL AS REAL ) FROM tab2, tab2 AS cor0
----
NULL

query I rowsort
SELECT col0 * col2 + col0 AS col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT 2 + - col1 FROM tab1
----
-11
-24
-8

query I rowsort
SELECT DISTINCT - 31 + + col0 AS col1 FROM tab1
----
-28
33
49

query I rowsort
SELECT DISTINCT + + cor0.col2 + + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-5612
SELECT ALL col1 + ( - col0 ) DIV - col2 FROM tab0 cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-5612
SELECT ALL col1 + ( - col0 ) / - col2 FROM tab0 cor0
----
132
86
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5613
SELECT DISTINCT + col0 DIV 96 AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5613
SELECT DISTINCT + col0 / 96 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT 34 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT - 53 * col0 AS col1 FROM tab2
----
-371
-4134
-4187

query I rowsort
SELECT 76 + col1 AS col0 FROM tab0
----
162
167
173

query I rowsort
SELECT - col1 * - col0 * - col0 AS col1 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT col2 * - col0 * col2 AS col0 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT ALL tab1.col1 AS col1 FROM tab1, tab0, tab1 cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5620
SELECT ALL + CAST( col1 AS SIGNED ) + - col2 * col2 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

skipif mysql # not compatible
query I rowsort label-5620
SELECT ALL + CAST ( col1 AS INTEGER ) + - col2 * col2 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - ( 21 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

query I rowsort
SELECT - ( - col0 + - col2 ) * 80 FROM tab0
----
13680
2880
4560

onlyif mysql # use DIV operator for integer division
query I rowsort label-5623
SELECT tab0.col2 DIV - col2 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5623
SELECT tab0.col2 / - col2 AS col2 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 * 3 col0 FROM tab2
----
78
78
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5625
SELECT - - col1 DIV + 40 + + col0 AS col1 FROM tab2 cor0
----
7
79
79

skipif mysql # not compatible
query I rowsort label-5625
SELECT - - col1 / + 40 + + col0 AS col1 FROM tab2 cor0
----
7
79
79

query I rowsort
SELECT - + cor0.col0 * 78 + + cor0.col2 FROM tab2 AS cor0
----
-519
-6058
-6124

query I rowsort
SELECT 77 + col1 + + col2 * col2 AS col1 FROM tab2
----
1538
812
837

query I rowsort
SELECT + col2 * - col1 - - col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL 71 * + col1 FROM tab2 cor0
----
1207
2201
4189

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - ( + cor0.col2 ) * + ( - col2 ) col2 FROM tab0 cor0
----
1113
36
6813

query I rowsort
SELECT - ( + col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5632
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5632
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5633
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * + col0 + - col1 * + col0 * - col0 AS col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5633
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * + col0 + - col1 * + col0 * - col0 AS col1 FROM tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col0 col1 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5635
SELECT ALL + cor0.col1 DIV + col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5635
SELECT ALL + cor0.col1 / + col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT - - col0 * 12 AS col1 FROM tab1 AS cor0
----
36
768
960

query I rowsort
SELECT DISTINCT - + ( - col1 ) + + cor0.col0 AS col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-5638
SELECT ALL - CAST( 81 AS SIGNED ) DIV + col1 FROM tab1 AS cor0
----
-3
-6
-8

skipif mysql # not compatible
query I rowsort label-5638
SELECT ALL - CAST ( 81 AS INTEGER ) / + col1 FROM tab1 AS cor0
----
-3
-6
-8

query I rowsort
SELECT col0 * 8 + col2 AS col0 FROM tab0
----
225
281
794

query I rowsort
SELECT ALL col0 + - 5 * + col1 AS col2 FROM tab2 AS cor0
----
-148
-217
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - cor0.col2 ) * + col0 * col1 + + 41 * col0 + col0 col2 FROM tab0 AS cor0
----
-1925
-660380
-67104

query I rowsort
SELECT ALL 56 FROM tab2, tab1 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5643
SELECT - CAST( NULL AS SIGNED ) + col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5643
SELECT - CAST ( NULL AS INTEGER ) + col0 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5644
SELECT ALL CAST( NULL AS SIGNED ) + + cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5644
SELECT ALL CAST ( NULL AS INTEGER ) + + cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + + col1 * col1 - col2 FROM tab0 AS cor0
----
7339
8110
9373

query I rowsort
SELECT - 85 + 42 AS col2 FROM tab1
----
-43
-43
-43

query I rowsort
SELECT ALL col0 * + ( + col1 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT 51 - col0 * ( - col2 ) AS col2 FROM tab1 AS cor0
----
213
3699
7731

query I rowsort
SELECT + ( col2 ) * + 28 + + col2 FROM tab0 AS cor0
----
2378
29
957

query I rowsort
SELECT ALL tab2.col2 * - col2 + - ( ( + col1 ) ) * tab2.col2 + col2 AS col1 FROM tab2
----
-1539
-2052
-2184

onlyif mysql # use DIV operator for integer division
query I rowsort label-5651
SELECT ALL - tab1.col2 DIV + col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5651
SELECT ALL - tab1.col2 / + col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT - col0 + - 2 AS col1 FROM tab1 AS cor0
----
-5
-66
-82

query I rowsort
SELECT DISTINCT col2 * + 73 AS col1 FROM tab1 AS cor0
----
3942
4161
7008

query I rowsort
SELECT - + cor0.col2 + - 3 AS col1 FROM tab1 AS cor0
----
-57
-60
-99

query I rowsort
SELECT ALL - + col2 * 98 FROM tab1 cor0
----
-5292
-5586
-9408

query I rowsort
SELECT + tab1.col2 * 42 AS col1 FROM tab1
----
2268
2394
4032

onlyif mysql # use DIV operator for integer division
query I rowsort label-5657
SELECT + cor0.col0 DIV 43 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

skipif mysql # not compatible
query I rowsort label-5657
SELECT + cor0.col0 / 43 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5658
SELECT tab2.col2 DIV + 73 + + col2 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5658
SELECT tab2.col2 / + 73 + + col2 FROM tab2
----
26
27
38

query I rowsort
SELECT + + col1 * cor0.col1 FROM tab2 cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 col2 FROM tab0 cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL - + cor0.col0 * CAST ( + 92 AS REAL ) col1 FROM tab2 AS cor0
----
-644
-7176
-7268

query I rowsort
SELECT ALL col1 * ( - col2 ) + col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + - col0 + col2 + 37 FROM tab0 AS cor0
----
3
30
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT col2 * - ( + col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT col1 + ( col1 ) * + col1 + + 44 AS col2 FROM tab0 AS cor0
----
7526
8416
9550

query I rowsort
SELECT DISTINCT + 31 FROM tab2, tab0 AS cor0
----
31

query I rowsort
SELECT ALL + ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + ( 72 ) + + col1 AS col2 FROM tab1 AS cor0
----
82
85
98

query I rowsort
SELECT DISTINCT - - cor0.col0 * - col2 - 39 AS col1 FROM tab0 AS cor0
----
-7337
-74
-831

query I rowsort
SELECT ALL - + col2 - - col1 * col0 AS col1 FROM tab2 AS cor0
----
1305
190
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-5672
SELECT ALL col2 DIV col2 - - col0 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-5672
SELECT ALL col2 / col2 - - col0 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT - col1 * + cor0.col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col2 * col0 * + col1 FROM tab2
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col1 col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL - + col0 * col2 - - ( 74 ) * cor0.col2 FROM tab1 AS cor0
----
-576
3834
570

query I rowsort
SELECT DISTINCT - ( col0 ) + + cor0.col2 * - cor0.col0 * col2 FROM tab1 AS cor0
----
-208000
-737360
-8751

query I rowsort
SELECT DISTINCT cor0.col0 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - cor0.col2 * col2 - + col1 AS col0 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT col0 * + cor0.col1 + cor0.col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5681
SELECT cor0.col2 * + CAST( NULL AS SIGNED ) + - 29 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5681
SELECT cor0.col2 * + CAST ( NULL AS INTEGER ) + - 29 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 * col1 + - col2 * - col1 AS col2 FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT - tab1.col0 + + 85 AS col2 FROM tab1, tab2, tab2 AS cor0, tab0
----
81 values hashing to 64e29651b0bc06eff849c704490191b1

query I rowsort
SELECT DISTINCT + tab0.col0 - + col2 * + ( col1 ) FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + col2 * + col2 + col0 + cor0.col0 AS col2 FROM tab2 AS cor0
----
1602
743
832

query I rowsort
SELECT ALL + col2 * col1 + - col0 * col1 AS col0 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT ALL + col1 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - - cor0.col2 * + col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col0 + ( 61 ) AS col2 FROM tab2 AS cor0
----
-17
-18
54

query I rowsort
SELECT tab2.col1 * col0 + + 99 FROM tab2
----
1442
316
4701

query I rowsort
SELECT + col1 + col1 * + col0 * - col1 AS col2 FROM tab1
----
-13507
-2002
-6390

query I rowsort
SELECT DISTINCT + tab0.col0 + + col0 FROM tab0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5693
SELECT + col0 DIV + col1 + ( + 50 ) + - col0 FROM tab2
----
-25
-27
43

skipif mysql # not compatible
query I rowsort label-5693
SELECT + col0 / + col1 + ( + 50 ) + - col0 FROM tab2
----
-25
-27
43

query I rowsort
SELECT + ( - col1 ) * - col0 - - col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL - col0 + + tab1.col1 * 76 + 54 * col0 AS col1 FROM tab1
----
2135
4152
5228

query I rowsort
SELECT + 95 * col1 AS col2 FROM tab2 AS cor0
----
1615
2945
5605

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * - col1 + col1 col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT - 31 + cor0.col2 + + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to fc69a561199b600feaa4da2ed65ace04

query I rowsort
SELECT ALL - col1 * + col2 * tab2.col1 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT 38 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
38

query I rowsort
SELECT + col0 + col0 * col2 * - col0 FROM tab2
----
-1316
-158106
-237079

query I rowsort
SELECT DISTINCT tab1.col0 AS col1 FROM tab1 WHERE NOT + col1 NOT IN ( - col0 * + col2 )
----

query I rowsort
SELECT DISTINCT 2 * col0 FROM tab0
----
178
48
70

query I rowsort
SELECT 83 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT 71 * - tab0.col2 FROM tab0
----
-2343
-5822
-71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5706
SELECT cor0.col1 + - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5706
SELECT cor0.col1 + - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( col2 ) * + col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - col2 + + tab1.col1 * tab1.col1 FROM tab1
----
43
622
73

query I rowsort
SELECT - col2 * + col1 - col1 * + col0 FROM tab1
----
-1210
-1482
-2288

onlyif mysql # use DIV operator for integer division
query I rowsort label-5710
SELECT ALL col1 * col1 * col2 + col1 DIV col0 + + col2 * tab2.col1 col0 FROM tab2
----
11628
26788
92040

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5710
SELECT ALL col1 * col1 * col2 + col1 / col0 + + col2 * tab2.col1 col0 FROM tab2
----
11628
26788
92040

query I rowsort
SELECT ALL col0 * + col2 * + col0 AS col2 FROM tab1
----
233472
486
614400

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( NULL ) < ( col2 * col2 * + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5713
SELECT DISTINCT col1 * col2 DIV cor0.col0 FROM tab0 AS cor0
----
118
2
83

skipif mysql # not compatible
query I rowsort label-5713
SELECT DISTINCT col1 * col2 / cor0.col0 FROM tab0 AS cor0
----
118
2
83

query I rowsort
SELECT DISTINCT col0 * - cor0.col0 AS col2 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + col2 * + col0 AS col0 FROM tab2 WHERE ( NULL ) < NULL
----

query I rowsort
SELECT + col1 * - col0 + col0 AS col2 FROM tab0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5717
SELECT ALL col2 DIV col1 AS col0 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5717
SELECT ALL col2 / col1 AS col0 FROM tab1
----
2
5
7

query I rowsort
SELECT tab1.col2 AS col0 FROM tab1 WHERE + col1 < NULL
----

query I rowsort
SELECT col2 * col0 + col1 AS col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT ALL col2 - - tab1.col2 * col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT - col1 * - col0 + - col2 * tab2.col0 FROM tab2
----
-1659
2574
28

query I rowsort
SELECT ALL col2 AS col0 FROM tab1 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT col1 * col0 * col0 FROM tab2
----
106097
1519
358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-5724
SELECT DISTINCT col2 DIV + col2 AS col2 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-5724
SELECT DISTINCT col2 / + col2 AS col2 FROM tab1
----
1

query I rowsort
SELECT col2 + + col1 + col2 AS col2 FROM tab1
----
124
134
205

query I rowsort
SELECT DISTINCT - - ( - 75 ) AS col2 FROM tab1, tab2, tab2 AS cor0
----
-75

query I rowsort
SELECT col1 + - col0 AS col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT + ( 7 ) AS col1 FROM tab0
----
7
7
7

query I rowsort
SELECT ( - cor0.col0 ) - cor0.col1 FROM tab2, tab0, tab2 cor0
----
27 values hashing to 822c2df270733c1079ccc0b8e544f81e

query I rowsort
SELECT ALL ( - col1 ) - - col0 AS col2 FROM tab0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5731
SELECT ( col0 ) DIV col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-5731
SELECT ( col0 ) / col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT - 37 - col2 AS col0 FROM tab2 cor0
----
-63
-64
-75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 4 * col2 + + 9 col2 FROM tab0 AS cor0
----
-123
-319
5

query I rowsort
SELECT + - 97 * col2 FROM tab2 AS cor0
----
-2522
-2619
-3686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5735
SELECT ALL col1 * col1 + - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5735
SELECT ALL col1 * col1 + - CAST ( NULL AS REAL ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 50 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
1300
1350
1900

query I rowsort
SELECT ALL 8 + col0 AS col2 FROM tab2 AS cor0
----
15
86
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col2 * - ( 38 ) col0 FROM tab0 AS cor0
----
-1287
-3198
-39

query I rowsort
SELECT + ( - col1 ) + + ( + 57 ) * col1 FROM tab0 AS cor0
----
4816
5096
5432

onlyif mysql # use DIV operator for integer division
query I rowsort label-5740
SELECT + col1 * - col1 + + CAST( col0 AS SIGNED ) DIV + col0 + + col2 * - col1 AS col1 FROM tab2 AS cor0
----
-1797
-5014
-934

skipif mysql # not compatible
query I rowsort label-5740
SELECT + col1 * - col1 + + CAST ( col0 AS INTEGER ) / + col0 + + col2 * - col1 AS col1 FROM tab2 AS cor0
----
-1797
-5014
-934

onlyif mysql # use DIV operator for integer division
query I rowsort label-5741
SELECT 67 DIV col0 AS col1 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5741
SELECT 67 / col0 AS col1 FROM tab0
----
0
1
2

query I rowsort
SELECT DISTINCT 3 AS col2 FROM tab0, tab1 AS cor0
----
3

query I rowsort
SELECT + col2 * col0 * cor0.col2 + + 47 FROM tab0 AS cor0
----
26183
598483
82

query I rowsort
SELECT DISTINCT + 4 + + col2 AS col2 FROM tab2 AS cor0
----
30
31
42

query I rowsort
SELECT DISTINCT - - col0 * col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - col0 + col1 * + 57 FROM tab1 AS cor0
----
1479
506
661

query I rowsort
SELECT ALL - 6 * - cor0.col2 FROM tab0 AS cor0
----
198
492
6

query I rowsort
SELECT + + col2 + cor0.col1 * 23 FROM tab2 AS cor0
----
1383
429
740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col2 ) col2 FROM tab1
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5750
SELECT CAST( - 54 AS SIGNED ) AS col2 FROM tab2
----
-54
-54
-54

skipif mysql # not compatible
query I rowsort label-5750
SELECT CAST ( - 54 AS INTEGER ) AS col2 FROM tab2
----
-54
-54
-54

query I rowsort
SELECT col0 + 6 FROM tab1 AS cor0
----
70
86
9

query I rowsort
SELECT + col2 * - 7 AS col2 FROM tab2 AS cor0
----
-182
-189
-266

query I rowsort
SELECT + + 93 FROM tab1 AS cor0
----
93
93
93

query I rowsort
SELECT 80 - - 52 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 69360870b63ae94631fff59de0c8f582

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5755
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab0 AS cor0, tab1 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5755
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab0 AS cor0, tab1 cor1
----
NULL

query I rowsort
SELECT ALL + 8 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT ALL - col0 * + col2 + ( - col2 ) FROM tab0 cor0
----
-36
-7380
-825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 77 * + col0 col0 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT + + 26 * - col1 AS col1 FROM tab1 AS cor0
----
-260
-338
-676

query I rowsort
SELECT DISTINCT + 78 * + col0 FROM tab1 AS cor0
----
234
4992
6240

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - col2 + - col2 * col0 col0 FROM tab0 AS cor0
----
-133
-7471
-911

query I rowsort
SELECT 44 AS col1 FROM tab0 AS cor0
----
44
44
44

query I rowsort
SELECT ALL + ( col2 ) + col0 * col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT col0 * + col2 + - 55 FROM tab1 AS cor0
----
107
3593
7625

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + col1 col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + - cor0.col1 + - 85 AS col2 FROM tab0 AS cor0
----
-171
-176
-182

query I rowsort
SELECT ALL - col1 * 85 AS col1 FROM tab0 AS cor0
----
-7310
-7735
-8245

query I rowsort
SELECT DISTINCT + - col2 + + ( + 87 ) * cor0.col2 FROM tab1 AS cor0
----
4644
4902
8256

query I rowsort
SELECT col2 * + 66 * + col0 FROM tab2 AS cor0
----
12474
133848
198132

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5770
SELECT col2 + - col0 / CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5770
SELECT col2 + - col0 / CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5771
SELECT ALL - 49 DIV - col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5771
SELECT ALL - 49 / - col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT - ( + tab1.col2 * - 50 ) - col2 AS col0 FROM tab1
----
2646
2793
4704

onlyif mysql # use DIV operator for integer division
query I rowsort label-5773
SELECT DISTINCT + col2 DIV col2 + + ( - col0 ) DIV - tab1.col2 + 52 * + 6 AS col1 FROM tab1
----
313
314

skipif mysql # not compatible
query I rowsort label-5773
SELECT DISTINCT + col2 / col2 + + ( - col0 ) / - tab1.col2 + 52 * + 6 AS col1 FROM tab1
----
313
314

onlyif mysql # use DIV operator for integer division
query I rowsort label-5774
SELECT + - col1 DIV 53 - + col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5774
SELECT + - col1 / 53 - + col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5775
SELECT ALL + - CAST( NULL AS SIGNED ) + + 71 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5775
SELECT ALL + - CAST ( NULL AS INTEGER ) + + 71 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 79 + + 79 AS col1 FROM tab2 AS cor0
----
158
158
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5777
SELECT ALL - ( col1 ) * col0 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5777
SELECT ALL - ( col1 ) * col0 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5778
SELECT ALL + col2 - + col2 DIV col0 AS col2 FROM tab2 AS cor0
----
24
26
38

skipif mysql # not compatible
query I rowsort label-5778
SELECT ALL + col2 - + col2 / col0 AS col2 FROM tab2 AS cor0
----
24
26
38

query I rowsort
SELECT - col0 * + col1 + + cor0.col1 * 16 * cor0.col2 FROM tab0 AS cor0
----
-1843
111293
43344

query I rowsort
SELECT ALL - - ( cor0.col2 ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - - ( 94 ) * col2 + + col0 + - col1 * cor0.col2 AS col1 FROM tab2 cor0
----
1708
3005
988

query I rowsort
SELECT ( col1 ) - + col2 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + ( col1 ) + + col0 * - 79 + 83 FROM tab0 AS cor0
----
-1727
-2585
-6857

query I rowsort
SELECT DISTINCT + ( + cor0.col0 ) * + cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - 70 AS REAL ) + - col1 FROM tab2 AS cor0
----
-101
-129
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5786
SELECT col1 DIV ( ( col2 ) ) col2 FROM tab0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5786
SELECT col1 / ( ( col2 ) ) col2 FROM tab0
----
1
2
97

query I rowsort
SELECT DISTINCT + col0 + - col2 * col0 * - col0 AS col2 FROM tab2 AS cor0
----
1330
158262
237237

query I rowsort
SELECT DISTINCT ( + col1 ) + cor0.col1 * ( - col1 ) AS col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL 27 * col1 - col0 * - col1 FROM tab2 AS cor0
----
1054
1802
6195

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5790
SELECT CAST( - col0 AS SIGNED ) * - cor0.col0 + - ( + 42 ) * col1 FROM tab0 AS cor0
----
-2849
-3036
4099

skipif mysql # not compatible
query I rowsort label-5790
SELECT CAST ( - col0 AS INTEGER ) * - cor0.col0 + - ( + 42 ) * col1 FROM tab0 AS cor0
----
-2849
-3036
4099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5791
SELECT col2 - - col1 DIV - col2 FROM tab0 AS cor0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-5791
SELECT col2 - - col1 / - col2 FROM tab0 AS cor0
----
-96
31
81

query I rowsort
SELECT DISTINCT + col1 + - col0 + + col1 FROM tab2 AS cor0
----
-45
40
55

query I rowsort
SELECT - cor0.col2 * - cor0.col2 * cor0.col2 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT + col1 * + 55 AS col1 FROM tab0
----
4730
5005
5335

query I rowsort
SELECT DISTINCT - 11 * + col1 + tab0.col2 FROM tab0
----
-1066
-913
-919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5796
SELECT CAST( NULL AS SIGNED ) * - 91 + - col0 * + cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5796
SELECT CAST ( NULL AS INTEGER ) * - 91 + - col0 * + cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( col1 ) + col1 FROM tab1
----
0
0
0

query I rowsort
SELECT cor0.col2 - - col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5799
SELECT - CAST( NULL AS SIGNED ) - 70 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5799
SELECT - CAST ( NULL AS INTEGER ) - 70 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ( 38 ) + - col1 FROM tab0
----
-48
-53
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5801
SELECT ALL col1 - + col1 * + CAST( 84 AS SIGNED ) * col1 FROM tab2 AS cor0
----
-24259
-292345
-80693

skipif mysql # not compatible
query I rowsort label-5801
SELECT ALL col1 - + col1 * + CAST ( 84 AS INTEGER ) * col1 FROM tab2 AS cor0
----
-24259
-292345
-80693

query I rowsort
SELECT + col2 * + cor0.col1 + cor0.col0 * 57 AS col2 FROM tab0 AS cor0
----
12535
2092
4206

onlyif mysql # use DIV operator for integer division
query I rowsort label-5803
SELECT DISTINCT - col2 + + col0 DIV col0 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-5803
SELECT DISTINCT - col2 + + col0 / col0 FROM tab0
----
-32
-81
0

query I rowsort
SELECT col0 + tab2.col1 + + tab2.col1 AS col2 FROM tab2
----
113
196
69

query I rowsort
SELECT DISTINCT - col2 + - col0 AS col2 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT col2 + + col0 * col0 FROM tab1
----
4153
63
6496

query I rowsort
SELECT col2 + - col2 + col0 FROM tab1
----
3
64
80

query I rowsort
SELECT + tab2.col0 + ( + col1 ) FROM tab2
----
137
38
96

query I rowsort
SELECT ALL + + 99 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT + 3 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT - 19 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col2 + 23 col2 FROM tab2 AS cor0
----
1467
699
752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 52 col0 FROM tab2 AS cor0
----
52
52
52

query I rowsort
SELECT DISTINCT + - col0 + col1 * - 34 FROM tab1 AS cor0
----
-404
-522
-887

query I rowsort
SELECT ( - col0 ) + - ( col0 + col0 ) AS col0 FROM tab0 AS cor0
----
-105
-267
-72

query I rowsort
SELECT 61 + cor0.col0 FROM tab2 AS cor0
----
139
140
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( - col1 ) col0 FROM tab0 cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 98 + col1 col2 FROM tab1 cor0
----
-72
-85
-88

query I rowsort
SELECT DISTINCT + + col0 + + col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL 66 + col0 - + col2 FROM tab1 AS cor0
----
15
50
73

query I rowsort
SELECT DISTINCT + col0 + col1 + - col2 * - 37 AS col2 FROM tab2 AS cor0
----
1037
1099
1502

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor2.col0 col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2, tab0 AS cor3
----
7
78
79

query I rowsort
SELECT DISTINCT col1 * tab1.col0 * - tab1.col2 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5824
SELECT DISTINCT + + col1 + cor0.col2 DIV col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5824
SELECT DISTINCT + + col1 + cor0.col2 / col2 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5825
SELECT + CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5825
SELECT + CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 25 * col0 FROM tab1 AS cor0
----
1600
2000
75

query I rowsort
SELECT ALL 91 + cor0.col0 AS col0 FROM tab2 AS cor0
----
169
170
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5828
SELECT ( cor0.col2 ) DIV - col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5828
SELECT ( cor0.col2 ) / - col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col1 * col0 - - col0 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT - - col2 + col1 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT col1 + ( - col2 * col0 ) AS col0 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5832
SELECT - col2 * col0 DIV + cor0.col2 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5832
SELECT - col2 * col0 / + cor0.col2 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + col2 * 90 AS col0 FROM tab2 AS cor0
----
2340
2430
3420

query I rowsort
SELECT + col2 * + col1 + 40 AS col0 FROM tab0 AS cor0
----
137
2878
7502

query I rowsort
SELECT - + ( col0 ) + - col2 + col1 AS col0 FROM tab2 AS cor0
----
-100
-3
-45

query I rowsort
SELECT ALL - 7 * col2 AS col0 FROM tab1 AS cor0
----
-378
-399
-672

onlyif mysql # use DIV operator for integer division
query I rowsort label-5837
SELECT DISTINCT col2 DIV - col1 FROM tab1 cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-5837
SELECT DISTINCT col2 / - col1 FROM tab1 cor0
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + 87 col2 FROM tab1 AS cor0
----
100
113
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5839
SELECT - - cor0.col0 * + col1 + cor0.col2 DIV + 43 + cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

skipif mysql # not compatible
query I rowsort label-5839
SELECT - - cor0.col0 * + col1 + cor0.col2 / + 43 + cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5840
SELECT - CAST( ( col1 ) AS SIGNED ) AS col0 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-5840
SELECT - CAST ( ( col1 ) AS INTEGER ) AS col0 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT 62 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 72 col0 FROM tab2
----
72

query I rowsort
SELECT ALL - ( tab1.col1 * - col2 ) FROM tab1
----
1248
1404
570

query I rowsort
SELECT - 61 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to c91d7b51e91f33d302e697913fb438b6

query I rowsort
SELECT DISTINCT 99 FROM tab2, tab0 AS cor0
----
99

query I rowsort
SELECT ALL col1 * col0 * 38 - col2 FROM tab0 AS cor0
----
129009
307680
78399

query I rowsort
SELECT DISTINCT - + col0 - + cor0.col0 AS col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT DISTINCT - col0 * ( - cor0.col2 * - col2 ) AS col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT col2 * col2 + + 76 * 3 FROM tab2
----
1672
904
957

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 84 col0 FROM tab0
----
84

query I rowsort
SELECT ALL + col0 - col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL col1 * - tab2.col0 - + 66 AS col0 FROM tab2
----
-1409
-283
-4668

query I rowsort
SELECT - tab1.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT ALL + - col2 * ( col0 ) + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT - col2 * 60 * + 83 FROM tab2 AS cor0
----
-129480
-134460
-189240

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5856
SELECT ALL - ( 91 + + col2 ) * + CAST( - col1 AS SIGNED ) * col1 FROM tab1
----
14800
31603
98020

skipif mysql # not compatible
query I rowsort label-5856
SELECT ALL - ( 91 + + col2 ) * + CAST ( - col1 AS INTEGER ) * col1 FROM tab1
----
14800
31603
98020

query I rowsort
SELECT - 26 * 20 FROM tab1
----
-520
-520
-520

onlyif mysql # use DIV operator for integer division
query I rowsort label-5858
SELECT + tab1.col0 + col1 DIV - col0 - - tab1.col2 AS col0 FROM tab1
----
121
176
49

skipif mysql # not compatible
query I rowsort label-5858
SELECT + tab1.col0 + col1 / - col0 - - tab1.col2 AS col0 FROM tab1
----
121
176
49

query I rowsort
SELECT 5 * col0 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT + + 42 + col1 AS col1 FROM tab1 AS cor0
----
52
55
68

query I rowsort
SELECT ALL + cor0.col1 + + 83 FROM tab2, tab1 AS cor0
----
9 values hashing to 47dab5b5a76245bf04f8d92d033f9af6

query I rowsort
SELECT DISTINCT col2 * + col2 + + col1 AS col2 FROM tab2
----
1461
735
760

query I rowsort
SELECT DISTINCT - col0 + - tab0.col1 AS col0 FROM tab0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 55 * + col1 col2 FROM tab1 cor0
----
-1430
-550
-715

query I rowsort
SELECT - + ( cor0.col0 ) * - 67 FROM tab1 AS cor0
----
201
4288
5360

query I rowsort
SELECT + 24 * + col1 FROM tab1 AS cor0
----
240
312
624

query I rowsort
SELECT - - 83 * - col1 FROM tab2 AS cor0
----
-1411
-2573
-4897

query I rowsort
SELECT ALL - col1 * col2 * - col2 AS col0 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT DISTINCT - cor0.col2 + col1 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * - 92 col2 FROM tab1 AS cor0
----
-4994
-5254
-8845

query I rowsort
SELECT ALL 97 * - col2 * col0 - 65 AS col0 FROM tab0 AS cor0
----
-3460
-707971
-76889

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5872
SELECT DISTINCT col0 + + CAST( NULL AS SIGNED ) + 64 * + col0 AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-5872
SELECT DISTINCT col0 + + CAST ( NULL AS INTEGER ) + 64 * + col0 AS col0 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT - col1 + 14 AS col1 FROM tab1
----
-12
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5874
SELECT DISTINCT col2 + + col2 DIV - col0 FROM tab2
----
24
26
38

skipif mysql # not compatible
query I rowsort label-5874
SELECT DISTINCT col2 + + col2 / - col0 FROM tab2
----
24
26
38

query I rowsort
SELECT + col0 * - 31 * + col2 AS col2 FROM tab0
----
-1085
-226238
-24552

query I rowsort
SELECT + col1 * + cor0.col0 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + 97 * + 44 col2 FROM tab1 AS cor0
----
4278
4281
4294

onlyif mysql # use DIV operator for integer division
query I rowsort label-5878
SELECT DISTINCT col2 + + ( - col2 ) DIV - col0 col1 FROM tab1 AS cor0
----
57
72
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5878
SELECT DISTINCT col2 + + ( - col2 ) / - col0 col1 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort
SELECT col1 * - CAST ( + col2 AS REAL ) - - col2 AS col2 FROM tab2 cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + 42 * col1 col0 FROM tab2
----
1275
2452
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5881
SELECT DISTINCT col0 * - CAST( NULL AS DECIMAL ) + col2 * col1 AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5881
SELECT DISTINCT col0 * - CAST ( NULL AS REAL ) + col2 * col1 AS col1 FROM tab2
----
NULL

query I rowsort
SELECT + cor0.col2 * 96 FROM tab2, tab1 AS cor0
----
9 values hashing to 19c7ed22afd5c2bc0716e97bd608270e

query I rowsort
SELECT - - 96 * - cor0.col2 FROM tab0 AS cor0
----
-3168
-7872
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5884
SELECT - CAST( NULL AS SIGNED ) * + col0 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5884
SELECT - CAST ( NULL AS INTEGER ) * + col0 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 60 + col2 FROM tab0 cor0
----
142
61
93

query I rowsort
SELECT + 25 * 49 FROM tab1 AS cor0
----
1225
1225
1225

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5887
SELECT ALL + CAST( - col2 AS SIGNED ) col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5887
SELECT ALL + CAST ( - col2 AS INTEGER ) col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - col2 + 8 * col2 FROM tab1 AS cor0
----
378
399
672

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5889
SELECT - + CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5889
SELECT - + CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 30 FROM tab1 AS cor0
----
30
30
30

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( + 75 AS REAL ) * col1 FROM tab1 AS cor0
----
1950
750
975

query I rowsort
SELECT DISTINCT - 43 * col0 FROM tab0 cor0
----
-1032
-1505
-3827

query I rowsort
SELECT + col1 * col2 + + cor0.col1 + + col0 AS col2 FROM tab1 AS cor0
----
1341
1433
644

query I rowsort
SELECT ALL - 44 * 47 AS col0 FROM tab0 AS cor0
----
-2068
-2068
-2068

query I rowsort
SELECT ALL 36 + 78 AS col1 FROM tab0 AS cor0
----
114
114
114

onlyif mysql # use DIV operator for integer division
query I rowsort label-5896
SELECT ALL - + col2 DIV + col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5896
SELECT ALL - + col2 / + col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT col2 * + 16 FROM tab0 AS cor0
----
1312
16
528

query I rowsort
SELECT ALL col0 * + ( tab1.col0 ) + - col2 - - col1 AS col2 FROM tab1
----
-19
4049
6317

query I rowsort
SELECT ALL - col1 + - col2 * + col1 AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT - + 91 * - col2 * - cor0.col0 + - col1 + 46 * col1 * + cor0.col2 FROM tab0 cor0
----
-320957
1180
58390

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5901
SELECT ALL + col0 * - cor0.col2 - col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5901
SELECT ALL + col0 * - cor0.col2 - col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col1 ) + - cor0.col2 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT tab1.col1 * col1 + - col0 FROM tab1
----
36
673
89

query I rowsort
SELECT + + 73 AS col0 FROM tab0 AS cor0
----
73
73
73

query I rowsort
SELECT DISTINCT + col2 * col2 * col2 + + col0 AS col2 FROM tab1 AS cor0
----
157467
185257
884816

query I rowsort
SELECT DISTINCT + 74 * col1 FROM tab0 AS cor0
----
6364
6734
7178

query I rowsort
SELECT ALL + 35 + + cor0.col1 * col2 AS col2 FROM tab2 AS cor0
----
1569
681
872

query I rowsort
SELECT DISTINCT - - col2 + cor0.col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT col2 * - col2 + + col1 - + col0 FROM tab0 AS cor0
----
-1027
-6722
61

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) * - ( col2 ) AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + col1 * - col2 + + col2 + cor0.col2 FROM tab1 AS cor0
----
-1056
-1296
-456

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5912
SELECT ALL col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5912
SELECT ALL col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * + ( 55 ) * cor0.col0 AS col2 FROM tab1 AS cor0
----
-225280
-352000
-495

onlyif mysql # use DIV operator for integer division
query I rowsort label-5914
SELECT ALL col1 DIV + ( col0 ) FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5914
SELECT ALL col1 / + ( col0 ) FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL - col0 * ( + 92 ) AS col2 FROM tab2 AS cor0
----
-644
-7176
-7268

query I rowsort
SELECT col0 * col0 - - 74 AS col2 FROM tab0
----
1299
650
7995

query I rowsort
SELECT 53 * 82 AS col2 FROM tab1 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 0027516f69134e214982ce4c5c6a5226

query I rowsort
SELECT DISTINCT + - cor0.col0 + col0 AS col1 FROM tab2 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5919
SELECT ALL + + col0 DIV col1 - col1 * + col1 * - col2 FROM tab2 AS cor0
----
10986
25947
90507

skipif mysql # not compatible
query I rowsort label-5919
SELECT ALL + + col0 / col1 - col1 * + col1 * - col2 FROM tab2 AS cor0
----
10986
25947
90507

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5920
SELECT DISTINCT - cor0.col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5920
SELECT DISTINCT - cor0.col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5921
SELECT DISTINCT - cor0.col2 + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5921
SELECT DISTINCT - cor0.col2 + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort
SELECT - + col0 * - CAST ( + col2 AS REAL ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT cor0.col1 + + cor0.col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - col0 * + 10 FROM tab1 AS cor0
----
-30
-640
-800

query I rowsort
SELECT ALL - col0 * + col0 + - ( + col2 ) * ( 22 ) AS col1 FROM tab0 AS cor0
----
-1247
-1302
-9725

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * cor0.col1 + ( col1 + cor0.col0 ) * 18 col1 FROM tab0 AS cor0
----
11521
11785
9376

query I rowsort
SELECT DISTINCT + col2 * + col2 - - col2 * - col2 AS col2 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 10 col2 FROM tab2
----
10
10
10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 47 col2 FROM tab1 AS cor0
----
2538
2679
4512

query I rowsort
SELECT col1 * + 82 FROM tab2
----
1394
2542
4838

query I rowsort
SELECT tab1.col2 + col0 + 32 * col2 FROM tab1
----
1785
1945
3248

query I rowsort
SELECT DISTINCT col2 * col2 + col0 * col2 FROM tab1
----
16896
3078
6897

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5933
SELECT + col0 * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5933
SELECT + col0 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5934
SELECT ALL - + col1 DIV + col1 + + cor0.col1 * 68 * + col0 AS col1 FROM tab2 cor0
----
14755
312935
91323

skipif mysql # not compatible
query I rowsort label-5934
SELECT ALL - + col1 / + col1 + + cor0.col1 * 68 * + col0 AS col1 FROM tab2 cor0
----
14755
312935
91323

query I rowsort
SELECT DISTINCT - col0 * col2 * + 34 - - col0 * col2 AS col2 FROM tab1 AS cor0
----
-120384
-253440
-5346

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 3 ) col0 FROM tab1
----
-3
-3
-3

query I rowsort
SELECT DISTINCT - col0 + + 79 AS col2 FROM tab2
----
0
1
72

query I rowsort
SELECT + tab1.col0 + 0 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 71 col2 FROM tab0
----
71

query I rowsort
SELECT ALL 39 + col2 * col1 FROM tab2 AS cor0
----
1573
685
876

query I rowsort
SELECT ALL + col1 + col0 * col0 AS col0 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT - 39 + + col1 FROM tab2 AS cor0
----
-22
-8
20

query I rowsort
SELECT ALL 22 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT - ( - 87 ) AS col2 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT - - ( col2 ) AS col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT 35 + col2 * col1 FROM tab2 cor0
----
1569
681
872

query I rowsort
SELECT + - 8 * col2 + col1 FROM tab2 AS cor0
----
-149
-185
-287

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + col2 col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT cor0.col1 + cor0.col1 - cor0.col2 AS col2 FROM tab2 AS cor0
----
-4
35
92

query I rowsort
SELECT 80 + + 26 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to e3a970c661a05070afa8a3ed8dca742e

query I rowsort
SELECT DISTINCT - cor0.col2 * + col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT + + col2 + ( + col0 ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL 18 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5954
SELECT - CAST( - cor0.col0 AS SIGNED ) DIV col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5954
SELECT - CAST ( - cor0.col0 AS INTEGER ) / col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL 55 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT - col2 * + 38 FROM tab0
----
-1254
-3116
-38

query I rowsort
SELECT DISTINCT 67 FROM tab1, tab0 AS cor0
----
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5958
SELECT ALL + col0 * - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5958
SELECT ALL + col0 * - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + ( - col2 ) * col2 - 17 FROM tab2 cor0
----
1427
659
712

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5960
SELECT + CAST( NULL AS SIGNED ) + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5960
SELECT + CAST ( NULL AS INTEGER ) + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + 10 * + col1 AS col0 FROM tab2 AS cor0
----
15340
6460
8370

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5962
SELECT DISTINCT CAST( NULL AS SIGNED ) + 3 * - col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5962
SELECT DISTINCT CAST ( NULL AS INTEGER ) + 3 * - col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + 87 + col0 AS col1 FROM tab2 AS cor0
----
165
166
94

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab2 cor2
----
972 values hashing to caf6adb9936510208f5945a7e5c76f14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 23 col1 FROM tab0
----
1978
2093
2231

query I rowsort
SELECT ALL col0 + - 19 FROM tab1 AS cor0
----
-16
45
61

query I rowsort
SELECT - 24 * - col2 FROM tab2 AS cor0
----
624
648
912

query I rowsort
SELECT DISTINCT ( 71 ) AS col0 FROM tab1
----
71

query I rowsort
SELECT 69 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT DISTINCT col0 + - cor0.col2 * - col2 AS col1 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL - 57 * col1 + 59 FROM tab0 AS cor0
----
-4843
-5128
-5470

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5972
SELECT DISTINCT CAST( - col0 * col1 AS SIGNED ) FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-5972
SELECT DISTINCT CAST ( - col0 * col1 AS INTEGER ) FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT col0 - col1 * tab0.col2 AS col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT + col0 * 50 + + col1 FROM tab2
----
381
3959
3967

query I rowsort
SELECT + col2 + - tab0.col0 * tab0.col1 * - ( col0 + - col0 ) AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT 67 * tab1.col2 AS col1 FROM tab1
----
3618
3819
6432

onlyif mysql # use DIV operator for integer division
query I rowsort label-5977
SELECT 8 * col2 DIV 37 AS col0 FROM tab2
----
5
5
8

skipif mysql # not compatible
query I rowsort label-5977
SELECT 8 * col2 / 37 AS col0 FROM tab2
----
5
5
8

query I rowsort
SELECT ALL col1 + ( - col2 ) * cor0.col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - col1 * 6 + col2 * col0 AS col1 FROM tab1 AS cor0
----
3588
6
7602

query I rowsort
SELECT + col1 + col2 * col0 * + col0 FROM tab0 AS cor0
----
1322
19094
649613

query I rowsort
SELECT DISTINCT + col2 * 55 + col0 AS col0 FROM tab1 AS cor0
----
2973
3199
5360

query I rowsort
SELECT DISTINCT - tab2.col2 * - col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT cor0.col1 * - 31 + cor0.col0 * - col0 FROM tab0 AS cor0
----
-10742
-3242
-4232

query I rowsort
SELECT + - cor0.col0 - ( col1 ) * col1 AS col0 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT DISTINCT - col1 - 95 FROM tab2 cor0
----
-112
-126
-154

onlyif mysql # use DIV operator for integer division
query I rowsort label-5986
SELECT - + col0 * col2 + - col1 DIV col0 FROM tab1 AS cor0
----
-170
-3648
-7680

skipif mysql # not compatible
query I rowsort label-5986
SELECT - + col0 * col2 + - col1 / col0 FROM tab1 AS cor0
----
-170
-3648
-7680

query I rowsort
SELECT + - cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL - col0 * + col2 * - col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - + cor0.col2 + - 70 FROM tab0 AS cor0
----
-103
-152
-71

query I rowsort
SELECT - cor0.col1 - col2 * - 85 AS col1 FROM tab2 AS cor0
----
2151
2264
3213

query I rowsort
SELECT DISTINCT + col0 * 13 FROM tab1 cor0
----
1040
39
832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5992
SELECT + col2 - + CAST( + col0 AS SIGNED ) * col2 AS col1 FROM tab0 cor0
----
-34
-7216
-759

skipif mysql # not compatible
query I rowsort label-5992
SELECT + col2 - + CAST ( + col0 AS INTEGER ) * col2 AS col1 FROM tab0 cor0
----
-34
-7216
-759

query I rowsort
SELECT tab1.col2 + - 25 FROM tab1, tab2 AS cor0
----
9 values hashing to 7f9a7ee2e73bc3484272558995d404bb

onlyif mysql # use DIV operator for integer division
query I rowsort label-5994
SELECT col0 DIV - col0 + + col0 * + col0 AS col2 FROM tab2
----
48
6083
6240

skipif mysql # not compatible
query I rowsort label-5994
SELECT col0 / - col0 + + col0 * + col0 AS col2 FROM tab2
----
48
6083
6240

query I rowsort
SELECT DISTINCT cor0.col0 + + cor0.col2 AS col2 FROM tab2, tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT 11 AS col0 FROM tab0, tab0 AS cor0
----
11

query I rowsort
SELECT DISTINCT tab1.col2 + + tab1.col0 AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT + 20 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5999
SELECT ALL col1 * col0 DIV 35 + - col2 FROM tab1
----
-39
-52
-67

skipif mysql # not compatible
query I rowsort label-5999
SELECT ALL col1 * col0 / 35 + - col2 FROM tab1
----
-39
-52
-67

query I rowsort
SELECT - - col1 * ( + col0 ) + col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - col1 * - col1 + 39 * col1 AS col1 FROM tab2 AS cor0
----
2170
5782
952

query I rowsort
SELECT ALL + - col0 * + 31 AS col2 FROM tab0 cor0
----
-1085
-2759
-744

query I rowsort
SELECT ALL - + col2 + col2 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 79 + - 65 * col0 col1 FROM tab0
----
1246
336
490

query I rowsort
SELECT DISTINCT - col0 + - 76 + col0 AS col2 FROM tab2
----
-76

query I rowsort
SELECT - 40 - 3 FROM tab1
----
-43
-43
-43

query I rowsort
SELECT tab2.col1 - - 7 * col0 FROM tab2
----
570
605
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6008
SELECT ALL - cor0.col0 * - col2 + + col2 + - col2 DIV col0 AS col2 FROM tab2 AS cor0
----
2054
213
3040

skipif mysql # not compatible
query I rowsort label-6008
SELECT ALL - cor0.col0 * - col2 + + col2 + - col2 / col0 AS col2 FROM tab2 AS cor0
----
2054
213
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-6009
SELECT DISTINCT cor0.col2 DIV - col0 - - col2 AS col2 FROM tab2 AS cor0
----
24
26
38

skipif mysql # not compatible
query I rowsort label-6009
SELECT DISTINCT cor0.col2 / - col0 - - col2 AS col2 FROM tab2 AS cor0
----
24
26
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6010
SELECT + ( col2 ) + col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6010
SELECT + ( col2 ) + col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + - 39 FROM tab2 AS cor0
----
-56
-70
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 38 col1 FROM tab1, tab0 cor0
----
38

query I rowsort
SELECT DISTINCT + 0 * + ( col1 ) AS col2 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6014
SELECT col0 DIV - tab1.col0 + col1 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-6014
SELECT col0 / - tab1.col0 + col1 FROM tab1
----
12
25
9

query I rowsort
SELECT DISTINCT 96 * col1 FROM tab1
----
1248
2496
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6016
SELECT ALL - CAST( col1 AS SIGNED ) DIV + col1 AS col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6016
SELECT ALL - CAST ( col1 AS INTEGER ) / + col1 AS col0 FROM tab2
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6017
SELECT ALL + 41 DIV + col2 AS col0 FROM tab0 AS cor0
----
0
1
41

skipif mysql # not compatible
query I rowsort label-6017
SELECT ALL + 41 / + col2 AS col0 FROM tab0 AS cor0
----
0
1
41

query I rowsort
SELECT DISTINCT - + col2 + - col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT - 44 * col2 FROM tab2 AS cor0
----
-1144
-1188
-1672

query I rowsort
SELECT DISTINCT 89 * col1 FROM tab2 AS cor0
----
1513
2759
5251

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 29 + + col2 col0 FROM tab2 AS cor0
----
55
56
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + cor0.col2 col2 FROM tab2 cor0
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6023
SELECT ALL - col2 DIV - cor0.col2 + col1 * col0 * col1 - col0 * - col0 AS col0 FROM tab1 AS cor0
----
10497
19921
2038

skipif mysql # not compatible
query I rowsort label-6023
SELECT ALL - col2 / - cor0.col2 + col1 * col0 * col1 - col0 * - col0 AS col0 FROM tab1 AS cor0
----
10497
19921
2038

query I rowsort
SELECT ALL col2 * cor0.col0 * col0 AS col1 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT 87 AS col0 FROM tab0 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT - col1 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - - 33 AS col2 FROM tab0 AS cor0
----
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-6028
SELECT ALL tab2.col0 * col0 DIV + tab2.col1 AS col2 FROM tab2
----
1
103
367

skipif mysql # not compatible
query I rowsort label-6028
SELECT ALL tab2.col0 * col0 / + tab2.col1 AS col2 FROM tab2
----
1
103
367

query I rowsort
SELECT ALL col2 + + col1 * 66 AS col2 FROM tab2 AS cor0
----
1160
2073
3920

query I rowsort
SELECT + + col2 * 24 * ( col0 ) AS col2 FROM tab1 AS cor0
----
184320
3888
87552

onlyif mysql # use DIV operator for integer division
query I rowsort label-6031
SELECT + + col2 DIV 31 AS col0 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6031
SELECT + + col2 / 31 AS col0 FROM tab2 cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - ( 86 ) * + col0 * col0 + - col0 AS col2 FROM tab0 AS cor0
----
-105385
-49560
-681295

query I rowsort
SELECT ALL + ( - col2 ) + - col0 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - 24 * - col2 + - col2 AS col1 FROM tab0 AS cor0
----
1886
23
759

query I rowsort
SELECT ALL - 85 * - col2 AS col1 FROM tab1 cor0
----
4590
4845
8160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6036
SELECT + CAST( NULL AS SIGNED ) + + 46 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6036
SELECT + CAST ( NULL AS INTEGER ) + + 46 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( + ( - col1 ) ) + - 6 AS col1 FROM tab1 cor0
----
20
4
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * col2 + - col1 col0 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT DISTINCT + ( + col2 ) + + col2 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT col2 + - col2 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) * col1 + col2 + col0 FROM tab1 AS cor0
----
-21
-519
-864

query I rowsort
SELECT ALL ( col1 ) * col0 - ( col0 ) AS col2 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT col1 * col2 + + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + col0 + 94 FROM tab2 AS cor0
----
101
172
173

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6045
SELECT ALL + CAST( NULL AS SIGNED ) * - cor0.col2 + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6045
SELECT ALL + CAST ( NULL AS INTEGER ) * - cor0.col2 + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT - + 55 * + col0 + - col2 + + CAST ( ( col0 ) AS REAL ) AS col1 FROM tab1 cor0
----
-216
-3513
-4416

query I rowsort
SELECT - col2 + cor0.col0 * - 11 * ( cor0.col1 ) + - 30 FROM tab0 AS cor0
----
-22767
-37376
-89201

query I rowsort
SELECT ALL col2 * + tab0.col0 * + col0 + - tab0.col2 AS col1 FROM tab0
----
1224
18975
649440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6049
SELECT CAST( NULL AS DECIMAL ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6049
SELECT CAST ( NULL AS REAL ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT 39 FROM tab0, tab1 cor0
----
39

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 cor0, tab0, tab1 cor1
----
972 values hashing to 7942394eb7766dfb9ea95b7805ff595d

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT col1 BETWEEN col2 AND - col2 / col0
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

onlyif mysql # use DIV operator for integer division
query I rowsort label-6053
SELECT + col1 + + col1 DIV tab1.col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6053
SELECT + col1 + + col1 / tab1.col1 FROM tab1
----
11
14
27

query I rowsort
SELECT + col0 + tab2.col2 + + col1 AS col0 FROM tab2 WHERE col1 >= NULL
----

query I rowsort
SELECT - col1 * - col0 + col2 AS col1 FROM tab1
----
1136
132
697

query I rowsort
SELECT DISTINCT col2 + col1 * col2 AS col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT ALL col1 AS col2 FROM tab0 WHERE NOT NULL BETWEEN col1 AND - col0 * col1 * - col1
----

query III rowsort
SELECT ALL * FROM tab2 WHERE - col0 < col2
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6059
SELECT DISTINCT col0 - col0 DIV + col1 AS col0 FROM tab2
----
7
75
77

skipif mysql # not compatible
query I rowsort label-6059
SELECT DISTINCT col0 - col0 / + col1 AS col0 FROM tab2
----
7
75
77

query I rowsort
SELECT - tab0.col0 * tab0.col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col2 FROM tab0 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT + col1 * col0 * + col2 FROM tab1 WHERE + col2 IN ( col0 + col2 - tab1.col0 )
----
36480
4212
99840

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN NULL AND - col0
----

query III rowsort
SELECT * FROM tab2 WHERE ( - col0 ) >= ( NULL )
----

query I rowsort
SELECT DISTINCT - col1 FROM tab2 WHERE NOT ( NULL ) NOT IN ( col0 )
----

query I rowsort
SELECT - tab2.col2 + col0 + col1 * - tab2.col1 FROM tab2
----
-248
-3429
-981

onlyif mysql # use DIV operator for integer division
query I rowsort label-6067
SELECT DISTINCT col2 DIV tab1.col0 - + col1 AS col1 FROM tab1
----
-10
-12
-8

skipif mysql # not compatible
query I rowsort label-6067
SELECT DISTINCT col2 / tab1.col0 - + col1 AS col1 FROM tab1
----
-10
-12
-8

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( NULL ) BETWEEN + col1 AND col2 / + col0 + - col1
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col0 + col1 NOT IN ( col0 * + col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT tab2.col1 FROM tab0 AS cor0 CROSS JOIN tab2
----
17
31
59

query I rowsort
SELECT + col0 * - tab2.col2 * col2 AS col1 FROM tab2 WHERE NOT - col2 < col2
----

query I rowsort
SELECT ALL - col2 * - tab0.col1 + + col2 * col0 * tab0.col2 AS col0 FROM tab0 WHERE NULL NOT IN ( - tab0.col1 * col0 )
----

query I rowsort
SELECT DISTINCT + col1 * col0 + col1 FROM tab1 WHERE NOT ( NULL ) <= NULL
----

query I rowsort
SELECT - col2 - + cor0.col1 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + col1 + cor0.col0 - + col0 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6076
SELECT DISTINCT + tab0.col1 DIV col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-6076
SELECT DISTINCT + tab0.col1 / col2 FROM tab0
----
1
2
97

query I rowsort
SELECT col1 * cor0.col0 AS col0 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6078
SELECT ALL col2 DIV - col2 + + col0 AS col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-6078
SELECT ALL col2 / - col2 + + col0 AS col0 FROM tab1
----
2
63
79

query I rowsort
SELECT ALL + col1 FROM tab1 AS cor0 WHERE ( - col0 / col0 ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT - cor0.col2 FROM tab0 AS cor0 WHERE ( NULL ) >= NULL
----

query I rowsort
SELECT col1 * - cor0.col2 * col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT col2 + - cor0.col0 * - cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + 12 ) col1 FROM tab1, tab2 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT ALL col0 * + col2 + - col1 + - col0 AS col2 FROM tab2
----
151
1891
2906

query I rowsort
SELECT ALL - col1 + col2 AS col0 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT col0 * - col1 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6087
SELECT col0 * + CAST( 74 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
222
4736
5920

skipif mysql # not compatible
query I rowsort label-6087
SELECT col0 * + CAST ( 74 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
222
4736
5920

query I rowsort
SELECT DISTINCT + + cor0.col0 * 40 AS col1 FROM tab1 AS cor0
----
120
2560
3200

query I rowsort
SELECT col2 * ( col2 ) - + col1 AS col1 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT cor0.col0 * + 86 FROM tab2 AS cor0
----
602
6708
6794

query I rowsort
SELECT col1 - cor0.col2 * 30 * - cor0.col0 FROM tab1 AS cor0
----
109450
230413
4886

query I rowsort
SELECT DISTINCT + ( 1 ) FROM tab1 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + + col1 + - col0 col2 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT 93 * col0 FROM tab1 AS cor0
----
279
5952
7440

query I rowsort
SELECT DISTINCT - 16 * + col0 AS col0 FROM tab1 AS cor0
----
-1024
-1280
-48

query I rowsort
SELECT ALL cor0.col2 + cor0.col1 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 5484e660e65aa37f29a1eca3fc30f5cc

query I rowsort
SELECT ALL col0 * - cor0.col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT + - col1 * - ( cor0.col1 + - col0 ) AS col2 FROM tab1 AS cor0
----
-540
-871
598

query I rowsort
SELECT col0 + + 53 - tab2.col1 FROM tab2
----
115
29
72

query I rowsort
SELECT ALL + ( col2 ) * col0 * - col2 + col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

query I rowsort
SELECT + 40 * col2 AS col0 FROM tab2 AS cor0
----
1040
1080
1520

query I rowsort
SELECT + 29 - - col1 AS col2 FROM tab0 cor0
----
115
120
126

query I rowsort
SELECT DISTINCT - 76 * - col2 AS col2 FROM tab1 AS cor0
----
4104
4332
7296

query I rowsort
SELECT cor0.col2 + + cor0.col1 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL 56 + col1 AS col2 FROM tab1 AS cor0
----
66
69
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6106
SELECT DISTINCT + col1 DIV col2 + 61 * - ( - cor0.col1 ) - ( cor0.col1 * col0 ) AS col1 FROM tab0 AS cor0
----
-2547
2619
3184

skipif mysql # not compatible
query I rowsort label-6106
SELECT DISTINCT + col1 / col2 + 61 * - ( - cor0.col1 ) - ( cor0.col1 * col0 ) AS col1 FROM tab0 AS cor0
----
-2547
2619
3184

query I rowsort
SELECT ALL - col0 + cor0.col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 - + col0 * - col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT ALL col2 + 27 AS col0 FROM tab1 AS cor0
----
123
81
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col0 col2 FROM tab1 cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-6111
SELECT ALL + cor0.col2 DIV - col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-6111
SELECT ALL + cor0.col2 / - col0 FROM tab2 AS cor0
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 + 56 * 6 col1 FROM tab1 AS cor0
----
390
393
432

query I rowsort
SELECT ALL col0 * 84 * ( + col2 ) AS col0 FROM tab0 AS cor0
----
2940
613032
66528

query I rowsort
SELECT + - col2 * col1 - col0 AS col1 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT - col0 + 10 * col1 FROM tab1 cor0
----
257
36
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-6116
SELECT + col0 DIV ( - cor0.col1 ) + col0 AS col1 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6116
SELECT + col0 / ( - cor0.col1 ) + col0 AS col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + - 94 AS col0 FROM tab1, tab0, tab2 AS cor0
----
-94

query I rowsort
SELECT ALL col2 * - col2 - - tab2.col0 FROM tab2
----
-1365
-598
-722

query I rowsort
SELECT tab0.col1 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

onlyif mysql # use DIV operator for integer division
query I rowsort label-6120
SELECT ALL - col1 * + col2 + - col2 DIV + 43 + 56 FROM tab0 AS cor0
----
-2782
-41
-7407

skipif mysql # not compatible
query I rowsort label-6120
SELECT ALL - col1 * + col2 + - col2 / + 43 + 56 FROM tab0 AS cor0
----
-2782
-41
-7407

query I rowsort
SELECT ALL - col2 * 26 + col2 AS col0 FROM tab2 AS cor0
----
-650
-675
-950

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab1 AS cor1, tab2, tab1 cor2
----
3645 values hashing to 35707ade138fec4b370f5140a4cd2963

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6123
SELECT ALL + CAST( NULL AS SIGNED ) * + cor0.col0 * + col2 + - 67 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6123
SELECT ALL + CAST ( NULL AS INTEGER ) * + cor0.col0 * + col2 + - 67 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + col1 ) * + col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 32 col0 FROM tab0 cor0
----
32

query I rowsort
SELECT DISTINCT col2 * + col0 + col0 FROM tab0 AS cor0
----
70
7387
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 74 col1 FROM tab1 cor0
----
74

query I rowsort
SELECT ALL - - col0 + + col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT col1 + - ( - col0 ) * + col0 FROM tab1
----
35
4106
6413

query I rowsort
SELECT DISTINCT - + col0 + ( cor0.col1 ) FROM tab0 AS cor0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6131
SELECT + CAST( - col0 AS SIGNED ) + - col2 FROM tab0 cor0
----
-171
-36
-57

skipif mysql # not compatible
query I rowsort label-6131
SELECT + CAST ( - col0 AS INTEGER ) + - col2 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT ALL + + col1 + 30 + col0 FROM tab2 AS cor0
----
126
167
68

query I rowsort
SELECT col2 + col0 * + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT - + col2 * col1 - + col2 AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL 56 AS col2 FROM tab2
----
56
56
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 75 col2 FROM tab0 AS cor0
----
-75
-75
-75

query I rowsort
SELECT DISTINCT cor0.col0 * - col0 AS col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - 79 - tab0.col0 AS col2 FROM tab0, tab1, tab2 AS cor0, tab0 AS cor1
----
81 values hashing to 45a7383825a1c717aff508d24e473985

query I rowsort
SELECT 26 * col1 * + col2 + + col1 FROM tab0
----
194103
2619
73874

query I rowsort
SELECT ALL + col0 * 38 FROM tab0
----
1330
3382
912

query I rowsort
SELECT ALL + + col2 * col0 + col0 AS col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT col0 * col2 + col2 * col1 AS col2 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT DISTINCT - col2 + + col0 * col2 AS col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT 68 * tab2.col0 AS col2 FROM tab2
----
476
5304
5372

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6145
SELECT DISTINCT + col0 * CAST( + 71 AS SIGNED ) + - col0 AS col0 FROM tab0 AS cor0
----
1680
2450
6230

skipif mysql # not compatible
query I rowsort label-6145
SELECT DISTINCT + col0 * CAST ( + 71 AS INTEGER ) + - col0 AS col0 FROM tab0 AS cor0
----
1680
2450
6230

query I rowsort
SELECT - cor0.col2 * col0 + col0 * - col2 AS col2 FROM tab1 AS cor0
----
-15360
-324
-7296

query I rowsort
SELECT ALL col0 + ( ( col1 ) ) * - col1 * 24 AS col2 FROM tab2 cor0
----
-23057
-6857
-83466

query I rowsort
SELECT DISTINCT - col1 * ( + ( col2 ) ) AS col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + col0 - + col1 * col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6150
SELECT ALL - CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6150
SELECT ALL - CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + ( col0 ) + - col1 FROM tab0
----
-2
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6152
SELECT - col2 DIV col1 + + ( col0 ) * - col0 FROM tab1
----
-11
-4101
-6407

skipif mysql # not compatible
query I rowsort label-6152
SELECT - col2 / col1 + + ( col0 ) * - col0 FROM tab1
----
-11
-4101
-6407

query I rowsort
SELECT ALL 82 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 + 18 * col0 col1 FROM tab2 AS cor0
----
2765
343
6006

query I rowsort
SELECT ALL - col2 + + 38 * + col0 FROM tab2 cor0
----
239
2938
2964

query I rowsort
SELECT + cor0.col2 * 71 AS col1 FROM tab2 AS cor0
----
1846
1917
2698

query I rowsort
SELECT DISTINCT - col1 + + col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT col0 + + col0 * 90 AS col0 FROM tab2 AS cor0
----
637
7098
7189

query I rowsort
SELECT DISTINCT ( + tab0.col1 ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
86
91
97

query I rowsort
SELECT col2 * + 10 * + col0 + col0 FROM tab2 AS cor0
----
1897
20358
30099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6161
SELECT ALL - col1 DIV ( 23 * col1 ) AS col2 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6161
SELECT ALL - col1 / ( 23 * col1 ) AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL col2 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6163
SELECT - tab2.col2 + 89 DIV - col1 AS col0 FROM tab2
----
-27
-29
-43

skipif mysql # not compatible
query I rowsort label-6163
SELECT - tab2.col2 + 89 / - col1 AS col0 FROM tab2
----
-27
-29
-43

query I rowsort
SELECT DISTINCT col1 + + ( + tab0.col0 ) AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT col1 * 52 FROM tab1
----
1352
520
676

query I rowsort
SELECT - col2 + - col0 * + col1 * col0 AS col1 FROM tab2 AS cor0
----
-106135
-1546
-358982

query I rowsort
SELECT + 63 * 62 + col1 FROM tab1 AS cor0
----
3916
3919
3932

onlyif mysql # use DIV operator for integer division
query I rowsort label-6168
SELECT DISTINCT - col2 + + col0 DIV + ( - col0 ) FROM tab0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-6168
SELECT DISTINCT - col2 + + col0 / + ( - col0 ) FROM tab0
----
-2
-34
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( + col0 ) col0 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * - 0 col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - - 22 AS col1 FROM tab0 AS cor0
----
22
22
22

query I rowsort
SELECT 36 * ( col1 ) AS col0 FROM tab0 AS cor0
----
3096
3276
3492

query I rowsort
SELECT - cor0.col0 + col2 * - col0 AS col1 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT - - 84 * col0 AS col1 FROM tab2 cor0
----
588
6552
6636

query I rowsort
SELECT - 38 * col0 AS col2 FROM tab2 AS cor0
----
-266
-2964
-3002

query I rowsort
SELECT ALL - ( col0 ) * 3 AS col0 FROM tab1 AS cor0
----
-192
-240
-9

query I rowsort
SELECT DISTINCT - - 75 * + col1 AS col2 FROM tab0 AS cor0
----
6450
6825
7275

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 99 * - col0 col2 FROM tab1 AS cor0
----
-297
-6336
-7920

query I rowsort
SELECT ALL - 80 * col1 AS col2 FROM tab1 AS cor0
----
-1040
-2080
-800

query I rowsort
SELECT DISTINCT - - col0 * - col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col1 * cor0.col0 * + cor0.col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT + col2 + col2 * col1 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT - 44 - col0 AS col1 FROM tab1 AS cor0
----
-108
-124
-47

query I rowsort
SELECT ALL col2 + col1 * - col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT ( col0 ) * - col1 - + 43 FROM tab0 AS cor0
----
-2107
-3438
-8142

query I rowsort
SELECT DISTINCT - col0 * + col1 * - 8 AS col1 FROM tab1 AS cor0
----
5120
624
8320

onlyif mysql # use DIV operator for integer division
query I rowsort label-6187
SELECT - - col1 DIV cor0.col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-6187
SELECT - - col1 / cor0.col0 AS col2 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6188
SELECT DISTINCT - col2 + col0 DIV + ( + col1 ) FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6188
SELECT DISTINCT - col2 + col0 / + ( + col1 ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - col0 * ( - ( - col1 ) ) + - 83 * col1 FROM tab1 AS cor0
----
-1470
-2119
-2236

onlyif mysql # use DIV operator for integer division
query I rowsort label-6190
SELECT + - col2 DIV + col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-6190
SELECT + - col2 / + col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 * col1 col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6192
SELECT cor0.col2 + - CAST( NULL AS SIGNED ) / - 78 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-6192
SELECT cor0.col2 + - CAST ( NULL AS INTEGER ) / - 78 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + 44 FROM tab1 cor0
----
108
124
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-6194
SELECT cor0.col2 DIV - 31 FROM tab0, tab2 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-6194
SELECT cor0.col2 / - 31 FROM tab0, tab2 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

query I rowsort
SELECT - col0 * - col2 + + cor0.col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - cor0.col1 * col2 + + 72 AS col2 FROM tab2 AS cor0
----
-1462
-574
-765

query I rowsort
SELECT + - col1 * col2 + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT 44 AS col2 FROM tab2
----
44

query I rowsort
SELECT ALL + 33 AS col0 FROM tab1
----
33
33
33

query I rowsort
SELECT col0 * - ( col1 ) AS col2 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6201
SELECT 25 DIV + col1 + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6201
SELECT 25 / + col1 + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - tab1.col2 * + col1 * + col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT + 21 * - col0 FROM tab0
----
-1869
-504
-735

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 25 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6205
SELECT DISTINCT + CAST( NULL AS SIGNED ) - - cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6205
SELECT DISTINCT + CAST ( NULL AS INTEGER ) - - cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6206
SELECT ALL col2 * - col1 * CAST( NULL AS SIGNED ) + - col0 col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6206
SELECT ALL col2 * - col1 * CAST ( NULL AS INTEGER ) + - col0 col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 49 + - col0 AS col0 FROM tab1 AS cor0
----
-15
-31
46

query I rowsort
SELECT ALL + 70 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT ALL + 81 FROM tab0, tab2 cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT DISTINCT 84 AS col1 FROM tab2, tab1 AS cor0
----
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6211
SELECT - col0 DIV - 53 AS col2 FROM tab2
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6211
SELECT - col0 / - 53 AS col2 FROM tab2
----
0
1
1

query I rowsort
SELECT + + 18 * col1 - - col2 FROM tab1 AS cor0
----
237
330
522

query I rowsort
SELECT 20 * - col1 FROM tab1 cor0
----
-200
-260
-520

onlyif mysql # use DIV operator for integer division
query I rowsort label-6214
SELECT ( + 39 ) * col2 DIV - 20 FROM tab0
----
-1
-159
-64

skipif mysql # not compatible
query I rowsort label-6214
SELECT ( + 39 ) * col2 / - 20 FROM tab0
----
-1
-159
-64

query I rowsort
SELECT col1 + + col1 + tab2.col2 * - col2 AS col1 FROM tab2
----
-1410
-558
-667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 41 * col2 col2 FROM tab2 AS cor0
----
1066
1107
1558

query I rowsort
SELECT + cor0.col2 - - col1 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + ( col1 ) * + ( - 56 ) FROM tab2
----
-1736
-3304
-952

query I rowsort
SELECT - 28 + tab2.col1 * col1 AS col0 FROM tab2
----
261
3453
933

query I rowsort
SELECT ALL + cor0.col2 * ( + 79 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 0351101cf0b00edc13cdaa144db558f9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6221
SELECT col2 * col0 + CAST( 92 AS SIGNED ) - - col1 AS col1 FROM tab2 AS cor0
----
2179
3111
312

skipif mysql # not compatible
query I rowsort label-6221
SELECT col2 * col0 + CAST ( 92 AS INTEGER ) - - col1 AS col1 FROM tab2 AS cor0
----
2179
3111
312

query I rowsort
SELECT DISTINCT + + col2 * - cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT 49 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT DISTINCT col2 * + ( + 65 ) * col2 FROM tab0
----
437060
65
70785

query I rowsort
SELECT DISTINCT + cor0.col2 * - ( - 71 ) AS col1 FROM tab2 AS cor0
----
1846
1917
2698

onlyif mysql # use DIV operator for integer division
query I rowsort label-6226
SELECT ALL - col0 DIV - col2 + + col1 FROM tab0 AS cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-6226
SELECT ALL - col0 / - col2 + + col1 FROM tab0 AS cor0
----
132
86
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6227
SELECT DISTINCT CAST( - col1 AS SIGNED ) + col2 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-6227
SELECT DISTINCT CAST ( - col1 AS INTEGER ) + col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + ( - 84 ) * col1 FROM tab1 cor0
----
-1092
-2184
-840

query I rowsort
SELECT ALL col2 + 95 AS col2 FROM tab2 AS cor0
----
121
122
133

query I rowsort
SELECT DISTINCT - col2 * + col0 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT - col1 * - 59 AS col1 FROM tab1 AS cor0
----
1534
590
767

query I rowsort
SELECT - 64 + 9 * - col0 AS col0 FROM tab2 AS cor0
----
-127
-766
-775

query I rowsort
SELECT ALL col1 * - col2 * col0 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + 71 AS col2 FROM tab2 AS cor0
----
71
71
71

query I rowsort
SELECT ALL + tab1.col0 - 98 FROM tab1, tab2 AS cor0
----
9 values hashing to f6c3645ce8a2fcc589e5171b95a9db92

query I rowsort
SELECT + + 65 + col1 * - col0 AS col0 FROM tab2 cor0
----
-1278
-152
-4537

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * cor0.col0 col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + - cor0.col1 * - col2 + ( ( cor0.col1 ) ) * + col1 AS col1 FROM tab1 AS cor0
----
1417
2080
670

query I rowsort
SELECT ALL + + col2 - col1 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + - ( + col2 ) + - col0 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT ALL - 67 + col0 * cor0.col2 FROM tab2 AS cor0
----
122
1961
2935

onlyif mysql # use DIV operator for integer division
query I rowsort label-6242
SELECT DISTINCT - col0 DIV + col0 + col1 AS col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6242
SELECT DISTINCT - col0 / + col0 + col1 AS col0 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT DISTINCT + col0 + col2 AS col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT + + col2 * + 43 FROM tab0 AS cor0
----
1419
3526
43

query I rowsort
SELECT - col1 + col1 * - 33 FROM tab1 AS cor0
----
-340
-442
-884

query I rowsort
SELECT + 60 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT - - col2 + col1 * + col0 + cor0.col1 FROM tab0 AS cor0
----
2183
3493
8272

query I rowsort
SELECT ALL ( ( col1 ) ) * - col2 + 59 FROM tab1 cor0
----
-1189
-1345
-511

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 58 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT ( + col2 ) * - tab2.col0 * col1 AS col0 FROM tab2
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - tab0.col1 + col1 * tab0.col2 col1 FROM tab0
----
2776
35
7460

query I rowsort
SELECT DISTINCT - - ( - col0 ) * cor0.col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6253
SELECT DISTINCT + 97 DIV cor0.col1 col0 FROM tab1, tab2 AS cor0
----
1
3
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6253
SELECT DISTINCT + 97 / cor0.col1 col0 FROM tab1, tab2 AS cor0
----
1
3
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6254
SELECT DISTINCT - 43 DIV col2 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6254
SELECT DISTINCT - 43 / col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + + 94 * 26 AS col2 FROM tab2 cor0
----
2444
2444
2444

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6256
SELECT ALL CAST( 10 AS SIGNED ) + col1 AS col0 FROM tab1 AS cor0
----
20
23
36

skipif mysql # not compatible
query I rowsort label-6256
SELECT ALL CAST ( 10 AS INTEGER ) + col1 AS col0 FROM tab1 AS cor0
----
20
23
36

query I rowsort
SELECT - - 52 FROM tab1 AS cor0
----
52
52
52

query I rowsort
SELECT DISTINCT - + ( col1 ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - - ( col2 ) * cor0.col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + col0 * - cor0.col2 + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-6261
SELECT ALL 28 DIV - col2 AS col0 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6261
SELECT ALL 28 / - col2 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT cor0.col1 + col2 * ( - col2 ) FROM tab0 AS cor0
----
-1003
-6633
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6263
SELECT col0 + col2 DIV + 95 AS col2 FROM tab1 AS cor0
----
3
64
81

skipif mysql # not compatible
query I rowsort label-6263
SELECT col0 + col2 / + 95 AS col2 FROM tab1 AS cor0
----
3
64
81

query I rowsort
SELECT DISTINCT + ( col2 ) * + col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6265
SELECT - + ( col0 ) + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6265
SELECT - + ( col0 ) + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6266
SELECT DISTINCT col0 + + ( + col2 ) DIV + col2 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-6266
SELECT DISTINCT col0 + + ( + col2 ) / + col2 FROM tab0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6267
SELECT col2 + - col0 * - col0 * col1 + col0 DIV + col2 AS col1 FROM tab1
----
288
41018
83296

skipif mysql # not compatible
query I rowsort label-6267
SELECT col2 + - col0 * - col0 * col1 + col0 / + col2 AS col1 FROM tab1
----
288
41018
83296

query I rowsort
SELECT - col1 * ( tab2.col0 ) AS col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + tab2.col1 + tab2.col2 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6270
SELECT 57 DIV 83 + col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6270
SELECT 57 / 83 + col0 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT ( col2 ) * - 57 FROM tab2 AS cor0
----
-1482
-1539
-2166

query I rowsort
SELECT + col1 + + col2 * - ( - 85 ) AS col1 FROM tab0 AS cor0
----
182
2891
7061

query I rowsort
SELECT - cor0.col1 * + col2 - - 9 * 20 AS col1 FROM tab1 AS cor0
----
-1068
-1224
-390

query I rowsort
SELECT 72 + ( - col0 ) * ( col0 ) FROM tab2
----
-6012
-6169
23

query I rowsort
SELECT - col1 * col1 + - 25 AS col1 FROM tab2 AS cor0
----
-314
-3506
-986

onlyif mysql # use DIV operator for integer division
query I rowsort label-6276
SELECT DISTINCT + ( - tab2.col0 ) DIV + 43 FROM tab2
----
-1
0

skipif mysql # not compatible
query I rowsort label-6276
SELECT DISTINCT + ( - tab2.col0 ) / + 43 FROM tab2
----
-1
0

query I rowsort
SELECT - col1 * - 55 AS col1 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT col1 * cor0.col0 + + col1 * + col1 AS col2 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT ALL + 29 AS col0 FROM tab1
----
29
29
29

query I rowsort
SELECT - cor1.col0 AS col0 FROM tab1, tab2, tab0 cor0, tab1 AS cor1
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6281
SELECT col2 * - col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6281
SELECT col2 * - col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col0 * 97 col0 FROM tab1 AS cor0
----
317
6218
7773

query I rowsort
SELECT - - ( - 12 ) AS col2 FROM tab1 AS cor0
----
-12
-12
-12

query I rowsort
SELECT - - ( cor0.col1 ) AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - - col0 * + col2 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ( 98 ) AS col2 FROM tab1 AS cor0
----
98
98
98

query I rowsort
SELECT 44 AS col2 FROM tab1 AS cor0
----
44
44
44

query I rowsort
SELECT - col1 + - col1 AS col0 FROM tab2
----
-118
-34
-62

query I rowsort
SELECT col2 + - ( col2 ) AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL 88 FROM tab1, tab1 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6291
SELECT ALL col1 * - CAST( NULL AS SIGNED ) * col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6291
SELECT ALL col1 * - CAST ( NULL AS INTEGER ) * col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 71 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT DISTINCT - 59 * - 82 AS col2 FROM tab1 AS cor0
----
4838

query I rowsort
SELECT ALL - 59 + 34 FROM tab1 AS cor0
----
-25
-25
-25

query I rowsort
SELECT + 41 * ( col1 ) FROM tab0 AS cor0
----
3526
3731
3977

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6296
SELECT + CAST( NULL AS SIGNED ) + col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6296
SELECT + CAST ( NULL AS INTEGER ) + col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 20 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-109
-44
-55

query I rowsort
SELECT ALL + + ( col1 ) - col2 AS col2 FROM tab0 cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6299
SELECT ALL - ( - col0 ) DIV - col1 + - ( - col0 ) * + col1 FROM tab1 AS cor0
----
1034
634
78

skipif mysql # not compatible
query I rowsort label-6299
SELECT ALL - ( - col0 ) / - col1 + - ( - col0 ) * + col1 FROM tab1 AS cor0
----
1034
634
78

query I rowsort
SELECT ( col0 ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - 12 * col2 + + col2 FROM tab0 cor0
----
-11
-363
-902

query I rowsort
SELECT DISTINCT cor0.col2 * - 0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - ( - ( col0 ) ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - col1 + + 25 + col2 * col2 AS col2 FROM tab2
----
1452
642
723

query I rowsort
SELECT + + col1 * col0 + col1 * col2 - - ( - col2 ) FROM tab0 AS cor0
----
15479
3491
4869

query I rowsort
SELECT col1 * ( - col2 ) - + cor0.col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT + cor0.col0 * ( + col0 ) + + col2 - ( 9 ) FROM tab0 AS cor0
----
1217
600
7994

query I rowsort
SELECT - cor0.col0 * + 91 + + col0 AS col2 FROM tab2 AS cor0
----
-630
-7020
-7110

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( col1 ) col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + col2 * + 68 FROM tab0 AS cor0
----
2244
5576
68

query I rowsort
SELECT 95 + col1 FROM tab0 AS cor0
----
181
186
192

query I rowsort
SELECT ( + col2 ) + cor0.col1 * + col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + 96 * cor0.col0 AS col1 FROM tab2 AS cor0
----
672
7488
7584

query I rowsort
SELECT col1 * + 12 AS col2 FROM tab0 AS cor0
----
1032
1092
1164

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6315
SELECT ALL - CAST( NULL AS SIGNED ) + - ( - col2 ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6315
SELECT ALL - CAST ( NULL AS INTEGER ) + - ( - col2 ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6316
SELECT + col2 - - 76 DIV col1 FROM tab2 AS cor0
----
27
29
42

skipif mysql # not compatible
query I rowsort label-6316
SELECT + col2 - - 76 / col1 FROM tab2 AS cor0
----
27
29
42

query I rowsort
SELECT ALL col1 * - col1 * col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT 54 + - 62 AS col0 FROM tab0 AS cor0
----
-8
-8
-8

query I rowsort
SELECT ALL + 88 AS col2 FROM tab2 AS cor0
----
88
88
88

query I rowsort
SELECT DISTINCT - col2 * 0 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - - col2 * + col0 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + - col1 + - cor0.col2 * ( + 18 ) FROM tab1 AS cor0
----
-1036
-1741
-998

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + - cor0.col2 * - col1 col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + - ( + col1 ) * cor0.col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( cor0.col1 ) * + 46 col2 FROM tab1 AS cor0
----
1196
460
598

query I rowsort
SELECT DISTINCT + + 73 * col1 + col1 * 91 AS col0 FROM tab1 AS cor0
----
1640
2132
4264

query I rowsort
SELECT ALL - 63 * - col1 * col1 FROM tab1 AS cor0
----
10647
42588
6300

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col1 * 79 col2 FROM tab2
----
-1343
-2449
-4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 10 + + col2 col0 FROM tab1
----
106
64
67

query I rowsort
SELECT + 13 + col0 AS col2 FROM tab2 AS cor0
----
20
91
92

query I rowsort
SELECT DISTINCT col0 + + ( col0 ) AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT cor0.col0 * 75 AS col2 FROM tab2 AS cor0
----
525
5850
5925

query I rowsort
SELECT ALL - + cor0.col0 * + col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL col1 * col2 * col0 AS col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT + - col0 + + col1 AS col2 FROM tab2 cor0
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6336
SELECT ALL - - cor0.col1 + - CAST( 27 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-1
-14
-17

skipif mysql # not compatible
query I rowsort label-6336
SELECT ALL - - cor0.col1 + - CAST ( 27 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-1
-14
-17

query I rowsort
SELECT ALL - col1 * + col0 * - ( + col1 ) + + ( + col2 ) * col2 + + 34 FROM tab0 AS cor0
----
178627
329350
743767

onlyif mysql # use DIV operator for integer division
query I rowsort label-6338
SELECT ALL cor0.col0 * 8 + - ( col2 ) DIV - cor0.col0 + col1 * + cor0.col2 FROM tab2 AS cor0
----
1278
2158
896

skipif mysql # not compatible
query I rowsort label-6338
SELECT ALL cor0.col0 * 8 + - ( col2 ) / - cor0.col0 + col1 * + cor0.col2 FROM tab2 AS cor0
----
1278
2158
896

onlyif mysql # use DIV operator for integer division
query I rowsort label-6339
SELECT ALL + col0 DIV col2 + + col2 AS col2 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-6339
SELECT ALL + col0 / col2 + + col2 AS col2 FROM tab1 AS cor0
----
54
58
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6340
SELECT - col2 * col2 DIV col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6340
SELECT - col2 * col2 / col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + - cor0.col1 + col2 + col2 FROM tab1 cor0
----
104
179
82

query I rowsort
SELECT DISTINCT + col2 + - 32 AS col2 FROM tab0 AS cor0
----
-31
1
50

query I rowsort
SELECT + ( - col2 ) + tab0.col2 * col1 AS col1 FROM tab0
----
2805
7380
96

query I rowsort
SELECT DISTINCT ( - col2 * ( ( - col1 ) ) ) FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 - + col1 * - col0 * + tab1.col1 AS col0 FROM tab1
----
13616
2082
6457

query I rowsort
SELECT ALL - + col0 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6347
SELECT ALL + - col2 + + cor0.col2 DIV + col1 FROM tab2 AS cor0
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-6347
SELECT ALL + - col2 + + cor0.col2 / + col1 FROM tab2 AS cor0
----
-26
-27
-36

query I rowsort
SELECT - col2 + + col2 * + 39 FROM tab0
----
1254
3116
38

query I rowsort
SELECT col0 + - 13 FROM tab2
----
-6
65
66

query I rowsort
SELECT - + cor0.col2 * + ( - col2 ) AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT col2 * 70 FROM tab1 cor0
----
3780
3990
6720

query I rowsort
SELECT - + 55 * col0 + + ( cor0.col0 ) FROM tab0 AS cor0
----
-1296
-1890
-4806

query I rowsort
SELECT DISTINCT + 4 + - col0 FROM tab2 AS cor0
----
-3
-74
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-6354
SELECT DISTINCT col1 DIV + col1 + - col1 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-6354
SELECT DISTINCT col1 / + col1 + - col1 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT 85 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
85

query I rowsort
SELECT 86 FROM tab0, tab0 AS cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT + col2 * col2 + + col1 AS col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL + 84 AS col2 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

query I rowsort
SELECT + 66 + tab1.col2 FROM tab1
----
120
123
162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6360
SELECT DISTINCT - col2 * col1 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6360
SELECT DISTINCT - col2 * col1 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6361
SELECT cor0.col0 + + col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6361
SELECT cor0.col0 + + col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col0 col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL col1 * 80 + 61 FROM tab0
----
6941
7341
7821

query I rowsort
SELECT ALL + tab2.col0 * ( ( + col2 ) ) + + col1 * + col0 FROM tab2
----
406
4345
6630

onlyif mysql # use DIV operator for integer division
query I rowsort label-6365
SELECT col0 + + col2 DIV + 72 AS col1 FROM tab1
----
3
64
81

skipif mysql # not compatible
query I rowsort label-6365
SELECT col0 + + col2 / + 72 AS col1 FROM tab1
----
3
64
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + 39 + col1 + + col0 col1 FROM tab2
----
1091
1151
1578

query I rowsort
SELECT DISTINCT 1 AS col0 FROM tab1, tab0 cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6368
SELECT - + CAST( NULL AS SIGNED ) * + 56 + + col0 / col2 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6368
SELECT - + CAST ( NULL AS INTEGER ) * + 56 + + col0 / col2 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 7 * - tab2.col2 AS col0 FROM tab2
----
-182
-189
-266

query I rowsort
SELECT ALL 14 * col2 AS col2 FROM tab2 AS cor0
----
364
378
532

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) - col0 * col0 FROM tab2 cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + ( - col0 * - col2 ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT + - col2 + - ( - col0 ) FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - 76 + col2 * + col0 AS col2 FROM tab2 AS cor0
----
113
1952
2926

query I rowsort
SELECT + + ( - col2 ) * col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL + 56 * + col1 AS col0 FROM tab2
----
1736
3304
952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 57 + col1 col0 FROM tab2 AS cor0
----
116
74
88

query I rowsort
SELECT - 88 AS col2 FROM tab2 AS cor0
----
-88
-88
-88

query I rowsort
SELECT DISTINCT + + 16 AS col2 FROM tab2 cor0
----
16

query I rowsort
SELECT - col1 * col2 * + col1 + - col1 AS col2 FROM tab1
----
-16237
-36530
-5710

query I rowsort
SELECT DISTINCT - col2 * 95 AS col2 FROM tab0 AS cor0
----
-3135
-7790
-95

query I rowsort
SELECT - + cor0.col1 * 30 FROM tab2 AS cor0
----
-1770
-510
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-6383
SELECT - col0 * - col1 + + col0 DIV + col1 FROM tab2 AS cor0
----
1347
217
4603

skipif mysql # not compatible
query I rowsort label-6383
SELECT - col0 * - col1 + + col0 / + col1 FROM tab2 AS cor0
----
1347
217
4603

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * + col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6385
SELECT + + col0 DIV + cor0.col2 + - col1 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
-23
55
67

skipif mysql # not compatible
query I rowsort label-6385
SELECT + + col0 / + cor0.col2 + - col1 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
-23
55
67

query I rowsort
SELECT ALL col1 + - 60 * 28 FROM tab2 AS cor0
----
-1621
-1649
-1663

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6387
SELECT ALL col1 + CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-6387
SELECT ALL col1 + CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT col0 + - 20 * + ( col1 ) * col1 FROM tab2 AS cor0
----
-19213
-5701
-69542

query I rowsort
SELECT - + col2 + - ( + col2 ) AS col0 FROM tab0 AS cor0
----
-164
-2
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 - col0 * - col1 * - col0 col1 FROM tab0 AS cor0
----
-115430
-47472
-712712

query I rowsort
SELECT ALL + col0 * col2 - + 54 FROM tab0 AS cor0
----
-19
7244
738

query I rowsort
SELECT + col0 + + 15 AS col2 FROM tab2 AS cor0
----
22
93
94

query I rowsort
SELECT DISTINCT - col0 + 3 FROM tab1 AS cor0
----
-61
-77
0

query I rowsort
SELECT ALL - - col0 + + ( + 88 ) * + col1 FROM tab2 AS cor0
----
1575
2735
5270

query I rowsort
SELECT + col1 + ( col1 ) - cor0.col2 FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT DISTINCT - - col1 * - 44 FROM tab0 AS cor0
----
-3784
-4004
-4268

query I rowsort
SELECT - + col0 * col1 * - col1 + col0 FROM tab2 cor0
----
22910
271596
6734

query I rowsort
SELECT ALL cor0.col2 + - col2 AS col2 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col0 * + col2 col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT + + col1 + col2 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-6401
SELECT + col0 + col0 * col1 DIV - col0 col0 FROM tab2 cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6401
SELECT + col0 + col0 * col1 / - col0 col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - cor0.col1 AS col1 FROM tab0 AS cor0 WHERE ( NULL ) BETWEEN NULL AND NULL OR NOT col0 NOT BETWEEN col0 + col2 AND col0
----

query I rowsort
SELECT col0 * + col1 + cor0.col0 * + col1 FROM tab0 AS cor0
----
16198
4128
6790

query I rowsort
SELECT col1 - + col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + tab0.col2 + - col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT - col0 + + tab0.col2 * col0 FROM tab0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col1 col1 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT tab2.col2 + tab2.col0 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6409
SELECT DISTINCT - + col0 DIV col0 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-6409
SELECT DISTINCT - + col0 / col0 AS col0 FROM tab1 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6410
SELECT ALL + col1 DIV col1 + + col2 DIV + col2 AS col1 FROM tab1 cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-6410
SELECT ALL + col1 / col1 + + col2 / + col2 AS col1 FROM tab1 cor0
----
2
2
2

query I rowsort
SELECT ALL + + 54 * col2 + col1 AS col0 FROM tab0 AS cor0
----
151
1868
4519

query I rowsort
SELECT DISTINCT - 59 + - 72 AS col2 FROM tab1
----
-131

query I rowsort
SELECT DISTINCT col2 + + 35 AS col2 FROM tab1
----
131
89
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 * + col1 ) - - col1 col1 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT ( - 70 ) + - col0 * col1 * + tab0.col1 AS col0 FROM tab0
----
-177574
-329385
-737079

query I rowsort
SELECT + 70 AS col0 FROM tab2
----
70
70
70

query I rowsort
SELECT DISTINCT + 16 AS col1 FROM tab2
----
16

query I rowsort
SELECT 82 + + tab1.col0 FROM tab1
----
146
162
85

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
24
35
89

query I rowsort
SELECT DISTINCT - col2 + + col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6421
SELECT cor0.col1 * col2 DIV + cor0.col1 AS col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6421
SELECT cor0.col1 * col2 / + cor0.col1 AS col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6422
SELECT DISTINCT + - col2 * col2 + + col1 DIV - cor0.col1 FROM tab1 cor0
----
-2917
-3250
-9217

skipif mysql # not compatible
query I rowsort label-6422
SELECT DISTINCT + - col2 * col2 + + col1 / - cor0.col1 FROM tab1 cor0
----
-2917
-3250
-9217

query I rowsort
SELECT DISTINCT ( col0 ) * ( 13 ) + - col0 + ( + col1 + - col1 ) * - col1 AS col2 FROM tab2 AS cor0
----
84
936
948

query I rowsort
SELECT DISTINCT + cor0.col1 AS col0 FROM tab0, tab1, tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - ( col0 ) * - col1 AS col1 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 78 col2 FROM tab1
----
78

query I rowsort
SELECT - ( - col1 ) - + col1 * ( col0 ) AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - ( col1 ) * - col0 + - col0 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT + 3 * col1 - - 89 * - 47 FROM tab0 AS cor0
----
-3892
-3910
-3925

query I rowsort
SELECT - 86 * col2 - + ( col2 ) FROM tab1 AS cor0
----
-4698
-4959
-8352

query I rowsort
SELECT DISTINCT col1 * col0 + + col2 * + col0 AS col0 FROM tab2 cor0
----
406
4345
6630

query I rowsort
SELECT DISTINCT cor0.col0 * - col2 + col1 * 18 FROM tab0 AS cor0
----
-5660
1711
756

query I rowsort
SELECT ALL 40 + col2 * col1 FROM tab0 AS cor0
----
137
2878
7502

query I rowsort
SELECT DISTINCT - - col0 + + col2 * + 65 AS col2 FROM tab0 AS cor0
----
100
2169
5419

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6435
SELECT ( col1 ) * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6435
SELECT ( col1 ) * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT - col2 + + ( col2 ) * - col1 AS col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT - - 47 * ( col1 ) AS col2 FROM tab2 cor0
----
1457
2773
799

query I rowsort
SELECT col1 * 86 AS col1 FROM tab1 AS cor0
----
1118
2236
860

query I rowsort
SELECT + col0 * + col0 AS col1 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT - ( - 73 ) AS col1 FROM tab2, tab0 AS cor0
----
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-6442
SELECT + 41 DIV col0 AS col1 FROM tab1 AS cor0
----
0
0
13

skipif mysql # not compatible
query I rowsort label-6442
SELECT + 41 / col0 AS col1 FROM tab1 AS cor0
----
0
0
13

query I rowsort
SELECT + col0 * col0 + - col2 * col1 FROM tab2 cor0
----
-788
4550
5595

query I rowsort
SELECT ALL - + 26 AS col0 FROM tab1 cor0
----
-26
-26
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6445
SELECT DISTINCT + 19 DIV col0 + col0 AS col1 FROM tab2 AS cor0
----
78
79
9

skipif mysql # not compatible
query I rowsort label-6445
SELECT DISTINCT + 19 / col0 + col0 AS col1 FROM tab2 AS cor0
----
78
79
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6446
SELECT - - CAST( NULL AS SIGNED ) + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6446
SELECT - - CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 53 + + ( col1 + + col2 ) FROM tab0 AS cor0
----
120
45
66

query I rowsort
SELECT 14 * + col2 * cor0.col0 FROM tab2 AS cor0
----
2646
28392
42028

onlyif mysql # use DIV operator for integer division
query I rowsort label-6449
SELECT + - ( + col1 ) DIV col2 + col2 * - col0 * + col1 AS col2 FROM tab0 AS cor0
----
-3492
-664119
-68114

skipif mysql # not compatible
query I rowsort label-6449
SELECT + - ( + col1 ) / col2 + col2 * - col0 * + col1 AS col2 FROM tab0 AS cor0
----
-3492
-664119
-68114

query I rowsort
SELECT DISTINCT - 86 * cor0.col1 FROM tab2 AS cor0
----
-1462
-2666
-5074

query I rowsort
SELECT + cor0.col2 * 91 * - col0 + 34 + col1 * col2 * col0 AS col0 FROM tab1 AS cor0
----
-10496
-295454
-599006

query I rowsort
SELECT ( + 58 ) AS col1 FROM tab1 AS cor0
----
58
58
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6453
SELECT ALL + + CAST( NULL AS SIGNED ) * col2 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6453
SELECT ALL + + CAST ( NULL AS INTEGER ) * col2 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( 89 ) + - col1 * - col0 AS col2 FROM tab2 cor0
----
1432
306
4691

query I rowsort
SELECT + - ( + col1 ) + col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT 68 + 13 FROM tab0 AS cor0
----
81

query I rowsort
SELECT ALL - ( - col2 ) - - col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col0 + cor0.col1 * + col1 AS col2 FROM tab1 AS cor0
----
36
673
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 92 col0 FROM tab1 cor0
----
92
92
92

query I rowsort
SELECT + 2 * col1 AS col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6461
SELECT - CAST( NULL AS SIGNED ) FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6461
SELECT - CAST ( NULL AS INTEGER ) FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - - 87 FROM tab0, tab1 cor0 CROSS JOIN tab1 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT - 73 * 66 + col2 FROM tab2
----
-4780
-4791
-4792

query I rowsort
SELECT + + cor0.col2 * ( + col2 ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL col2 * + ( col1 * col0 ) AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + col2 + 8 * - 36 FROM tab0 AS cor0
----
-206
-255
-287

query I rowsort
SELECT - col0 + + col0 - ( 67 ) FROM tab0
----
-67
-67
-67

query I rowsort
SELECT - 65 * - col0 FROM tab2
----
455
5070
5135

query I rowsort
SELECT DISTINCT 54 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
54

query I rowsort
SELECT ALL col0 * - col1 + 8 * - col1 FROM tab0
----
-2752
-4171
-8827

query I rowsort
SELECT col1 - - ( col1 ) AS col0 FROM tab2
----
118
34
62

query I rowsort
SELECT col2 * - ( - col1 ) + col1 + ( + col0 ) FROM tab1
----
1341
1433
644

query I rowsort
SELECT col2 + + tab1.col1 AS col2 FROM tab1
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6474
SELECT + col1 DIV 15 FROM tab2
----
1
2
3

skipif mysql # not compatible
query I rowsort label-6474
SELECT + col1 / 15 FROM tab2
----
1
2
3

query I rowsort
SELECT cor0.col2 + + ( + col0 ) * col0 - + ( + 53 ) * cor0.col1 AS col1 FROM tab0 AS cor0
----
-3915
-3949
3180

query I rowsort
SELECT - - col1 * + col0 + col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT - col2 * tab0.col2 + col2 * + 48 * - col1 AS col2 FROM tab0
----
-137313
-364900
-4657

query I rowsort
SELECT + + col1 + ( - col2 ) AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT cor2.col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1 cor2
----
54
57
96

query I rowsort
SELECT - col0 + col1 + tab2.col0 * col2 AS col0 FROM tab2
----
2009
213
2940

query I rowsort
SELECT ALL + cor0.col0 AS col0 FROM tab2, tab0, tab0 AS cor0, tab0 AS cor1
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT ALL ( tab2.col1 ) * - 6 FROM tab2
----
-102
-186
-354

query I rowsort
SELECT + 39 AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT - cor0.col0 AS col2 FROM tab0, tab1, tab2 cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT ( 24 ) FROM tab2, tab1 AS cor0, tab2 AS cor1
----
24

query I rowsort
SELECT DISTINCT col0 * col0 + + col1 + - col1 AS col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - 72 * - col1 + col0 AS col2 FROM tab0 AS cor0
----
6216
6641
7019

query I rowsort
SELECT DISTINCT 88 + col2 FROM tab2 AS cor0
----
114
115
126

onlyif mysql # use DIV operator for integer division
query I rowsort label-6489
SELECT DISTINCT + 53 + + col0 DIV cor0.col2 FROM tab1 AS cor0
----
53
54

skipif mysql # not compatible
query I rowsort label-6489
SELECT DISTINCT + 53 + + col0 / cor0.col2 FROM tab1 AS cor0
----
53
54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 73 + col2 col2 FROM tab2 AS cor0
----
100
111
99

query I rowsort
SELECT ALL - - col1 * - col1 + - ( + col2 ) AS col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT - cor0.col1 * + col1 * ( 58 * + cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-117624
-371200
-784160

query I rowsort
SELECT DISTINCT - 85 AS col2 FROM tab1 cor0
----
-85

query I rowsort
SELECT 90 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT - col2 - 14 FROM tab2
----
-40
-41
-52

query I rowsort
SELECT DISTINCT - 70 AS col1 FROM tab0, tab2 cor0, tab1 AS cor1
----
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + col1 col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT col1 * - 41 FROM tab0 AS cor0
----
-3526
-3731
-3977

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - ( col1 ) col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + + col0 * 29 FROM tab1 cor0
----
1856
2320
87

query I rowsort
SELECT 96 + + col0 * col2 FROM tab2 AS cor0
----
2124
285
3098

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6502
SELECT - CAST( col0 AS SIGNED ) * cor0.col0 AS col0 FROM tab1 cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-6502
SELECT - CAST ( col0 AS INTEGER ) * cor0.col0 AS col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - - 1 AS col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT 77 * - col2 AS col2 FROM tab1 cor0
----
-4158
-4389
-7392

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col1 col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col1 * - tab2.col1 * col1 FROM tab2
----
-205379
-29791
-4913

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col2 + + col2 col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL + cor1.col0 AS col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6509
SELECT + 31 DIV - col1 FROM tab1 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6509
SELECT + 31 / - col1 FROM tab1 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 93 * - ( - col1 ) + - col1 col2 FROM tab2 AS cor0
----
1564
2852
5428

query I rowsort
SELECT DISTINCT + 43 + 86 FROM tab2 cor0
----
129

query I rowsort
SELECT DISTINCT + col2 * col1 * + col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT + + 87 * col0 AS col1 FROM tab2 AS cor0
----
609
6786
6873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * cor0.col0 col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - 37 + - col0 AS col2 FROM tab0 AS cor0
----
-126
-61
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-6516
SELECT + - cor0.col2 DIV + col1 FROM tab2 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-6516
SELECT + - cor0.col2 / + col1 FROM tab2 cor0
----
-2
0
0

query I rowsort
SELECT DISTINCT - - 98 + + col2 * - 37 FROM tab0 AS cor0
----
-1123
-2936
61

query IIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 WHERE NOT ( NULL ) IN ( + cor0.col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6519
SELECT tab0.col2 DIV col2 + + tab0.col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-6519
SELECT tab0.col2 / col2 + + tab0.col0 FROM tab0
----
25
36
90

query I rowsort
SELECT + 29 - 18 FROM tab0
----
11
11
11

query I rowsort
SELECT ( 14 ) + + tab2.col1 AS col0 FROM tab2
----
31
45
73

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( 10 AS REAL ) FROM tab1
----
10

query I rowsort
SELECT ALL col2 * col1 + col0 * col1 AS col2 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT DISTINCT - col2 + col2 * - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT ALL + col0 * col0 + 89 * - col1 * - col2 + - col0 * cor0.col0 FROM tab1 AS cor0
----
111072
124956
50730

query I rowsort
SELECT ALL col0 * col1 - col1 AS col1 FROM tab1
----
1027
52
630

query I rowsort
SELECT DISTINCT + tab1.col2 * tab1.col0 - + col0 AS col2 FROM tab1
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - 80 ) col2 FROM tab2, tab1 AS cor0, tab1 cor1
----
80

query I rowsort
SELECT ALL 66 * - 58 FROM tab1, tab2 AS cor0
----
9 values hashing to 8ec83db22c3182523d9a8d847af0aff3

query I rowsort
SELECT cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL col0 * + col1 * col0 + col2 AS col0 FROM tab1
----
288
41017
83296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6532
SELECT ALL + col1 / + CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6532
SELECT ALL + col1 / + CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + - 79 * col0 FROM tab2 cor0
----
-526
-6136
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-6534
SELECT DISTINCT col2 + 59 + col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
110
113
149

skipif mysql # not compatible
query I rowsort label-6534
SELECT DISTINCT col2 + 59 + col0 / - col1 AS col2 FROM tab1 AS cor0
----
110
113
149

query I rowsort
SELECT + col1 * - cor0.col1 + cor0.col2 * cor0.col0 FROM tab1 cor0
----
-514
3548
7511

query I rowsort
SELECT DISTINCT col1 + - 69 AS col2 FROM tab2
----
-10
-38
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6537
SELECT DISTINCT + col2 * ( 28 * col0 ) + 88 DIV + 70 - col2 FROM tab0 AS cor0
----
204263
22144
980

skipif mysql # not compatible
query I rowsort label-6537
SELECT DISTINCT + col2 * ( 28 * col0 ) + 88 / + 70 - col2 FROM tab0 AS cor0
----
204263
22144
980

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6538
SELECT CAST( NULL AS SIGNED ) / 53 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6538
SELECT CAST ( NULL AS INTEGER ) / 53 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 55 col2 FROM tab2, tab2 AS cor0
----
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6540
SELECT DISTINCT + CAST( NULL AS DECIMAL ) FROM tab1, tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6540
SELECT DISTINCT + CAST ( NULL AS REAL ) FROM tab1, tab2 cor0
----
NULL

query I rowsort
SELECT - 32 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

query I rowsort
SELECT + 78 * + cor0.col0 FROM tab0 AS cor0
----
1872
2730
6942

query I rowsort
SELECT ALL - cor0.col0 * col0 + col2 AS col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT ALL + 6 - - col2 AS col2 FROM tab0 AS cor0
----
39
7
88

query I rowsort
SELECT col1 + - ( cor0.col0 ) AS col2 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT - col1 + - col2 * col0 AS col2 FROM tab2 AS cor0
----
-2087
-220
-3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-6547
SELECT ALL col2 DIV + 49 + cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-6547
SELECT ALL col2 / + 49 + cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1247
-1403
-569

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6548
SELECT DISTINCT CAST( col1 AS SIGNED ) + + col2 AS col0 FROM tab0 cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-6548
SELECT DISTINCT CAST ( col1 AS INTEGER ) + + col2 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL + + 93 FROM tab0 AS cor0
----
93
93
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6550
SELECT + + ( + col1 ) * + cor0.col1 + - 26 DIV col1 AS col0 FROM tab2 AS cor0
----
288
3481
961

skipif mysql # not compatible
query I rowsort label-6550
SELECT + + ( + col1 ) * + cor0.col1 + - 26 / col1 AS col0 FROM tab2 AS cor0
----
288
3481
961

query I rowsort
SELECT - - ( - col0 ) * + col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + - col2 * col2 + + col0 AS col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT + + 61 + 13 * col0 AS col1 FROM tab1 AS cor0
----
100
1101
893

query I rowsort
SELECT DISTINCT col0 * - col1 - cor0.col0 AS col0 FROM tab1 AS cor0
----
-1120
-704
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + 2 * col2 + + 63 * col1 col1 FROM tab2 AS cor0
----
1068
2000
3691

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6556
SELECT DISTINCT - CAST( NULL AS SIGNED ) * cor0.col0 * - cor0.col2 - CAST( 18 AS SIGNED ) * col1 * + ( 99 + + col0 ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6556
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * cor0.col0 * - cor0.col2 - CAST ( 18 AS INTEGER ) * col1 * + ( 99 + + col0 ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col0 + + col2 * col0 AS col1 FROM tab1 AS cor0
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col0 * cor0.col1 col2 FROM tab2 AS cor0
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6559
SELECT 80 + + ( + col2 ) * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6559
SELECT 80 + + ( + col2 ) * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 67 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
67

query I rowsort
SELECT ALL - cor0.col0 * col1 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - - 36 * + col2 AS col0 FROM tab2 AS cor0
----
1368
936
972

query I rowsort
SELECT + col2 * + cor0.col0 + - 93 AS col2 FROM tab0 cor0
----
-58
699
7205

onlyif mysql # use DIV operator for integer division
query I rowsort label-6564
SELECT - col2 DIV col2 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6564
SELECT - col2 / col2 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - + col2 * + col0 + ( cor0.col0 * + col1 ) FROM tab0 AS cor0
----
1272
3360
801

query I rowsort
SELECT ALL - - 26 * + col2 AS col1 FROM tab2 cor0
----
676
702
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-6567
SELECT + - col0 DIV + cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6567
SELECT + - col0 / + cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - ( - col0 ) * - col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - + col0 * ( - col2 ) AS col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col1 + - 51 FROM tab0 AS cor0
----
35
40
46

query I rowsort
SELECT - + col0 * col2 + col1 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - col1 * + 84 FROM tab2 AS cor0
----
-1428
-2604
-4956

query I rowsort
SELECT - col1 + + 59 AS col2 FROM tab0 AS cor0
----
-27
-32
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6574
SELECT ALL + + col1 DIV 86 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6574
SELECT ALL + + col1 / 86 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * - col1 * tab1.col0 + - col2 - col0 FROM tab1
----
-13696
-2085
-6521

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
3645 values hashing to 9aea36b1adc82580fae09bf05c24fd77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6577
SELECT CAST( NULL AS SIGNED ) * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6577
SELECT CAST ( NULL AS INTEGER ) * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + ( col2 ) + col2 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6579
SELECT DISTINCT + cor0.col1 DIV col0 AS col0 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-6579
SELECT DISTINCT + cor0.col1 / col0 AS col0 FROM tab2 AS cor0
----
0
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6580
SELECT ALL 22 * + ( + col0 ) + + CAST( cor0.col2 * col0 AS SIGNED ) FROM tab2 AS cor0
----
343
3744
4740

skipif mysql # not compatible
query I rowsort label-6580
SELECT ALL 22 * + ( + col0 ) + + CAST ( cor0.col2 * col0 AS INTEGER ) FROM tab2 AS cor0
----
343
3744
4740

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6581
SELECT ALL + CAST( col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6581
SELECT ALL + 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-6582
SELECT ALL + ( 70 ) + col0 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6582
SELECT ALL + ( 70 ) + col0 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - tab1.col2 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ( 77 * + col1 ) FROM tab2
----
1309
2387
4543

query I rowsort
SELECT DISTINCT - col2 * ( col0 ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + cor2.col2 * - cor0.col1 AS col2 FROM tab0, tab1 AS cor0, tab1 cor1, tab2, tab0 AS cor2
----
9 values hashing to a811f2025e810c126c8e7210b4f3f570

query I rowsort
SELECT DISTINCT + col0 + - 99 AS col2 FROM tab1 cor0
----
-19
-35
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6588
SELECT - - col2 + - 14 DIV col0 FROM tab1 AS cor0
----
50
57
96

skipif mysql # not compatible
query I rowsort label-6588
SELECT - - col2 + - 14 / col0 FROM tab1 AS cor0
----
50
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6589
SELECT DISTINCT + 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-6589
SELECT DISTINCT + col1 * CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - col2 + + 20 FROM tab1 AS cor0
----
-34
-37
-76

query I rowsort
SELECT DISTINCT + col1 + - col1 * - col2 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * col2 + - col2 * - col0 col0 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT + ( 84 ) AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6594
SELECT col0 * - CAST( NULL AS SIGNED ) + col0 * col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6594
SELECT col0 * - CAST ( NULL AS INTEGER ) + col0 * col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * ( - col0 ) * tab0.col1 AS col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT - tab0.col0 FROM tab0, tab2, tab0 cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6597
SELECT + 92 DIV 54 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6597
SELECT + 92 / 54 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT col2 * + col0 + col2 * - col1 AS col0 FROM tab0
----
-164
-2046
-62

query I rowsort
SELECT + 43 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT + col1 + 17 AS col0 FROM tab1
----
27
30
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-6601
SELECT - 79 + col0 DIV col1 AS col2 FROM tab0 AS cor0
----
-79
-79
-79

skipif mysql # not compatible
query I rowsort label-6601
SELECT - 79 + col0 / col1 AS col2 FROM tab0 AS cor0
----
-79
-79
-79

query I rowsort
SELECT - - col2 * 23 + col2 AS col2 FROM tab1 AS cor0
----
1296
1368
2304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 col2 FROM tab2, tab0 AS cor0
----
17
31
59

query I rowsort
SELECT 54 * 87 FROM tab1
----
4698
4698
4698

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6605
SELECT - CAST( - 7 AS SIGNED ) FROM tab1 cor0
----
7
7
7

skipif mysql # not compatible
query I rowsort label-6605
SELECT - CAST ( - 7 AS INTEGER ) FROM tab1 cor0
----
7
7
7

query I rowsort
SELECT DISTINCT + 89 + - col2 FROM tab2
----
51
62
63

query I rowsort
SELECT DISTINCT 11 + col1 AS col0 FROM tab0
----
102
108
97

query I rowsort
SELECT DISTINCT col2 * + col0 + + col1 * 48 FROM tab1
----
1410
4128
8304

onlyif mysql # use DIV operator for integer division
query I rowsort label-6609
SELECT ALL + + cor0.col0 DIV - col0 FROM tab2 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6609
SELECT ALL + + cor0.col0 / - col0 FROM tab2 cor0
----
-1
-1
-1

query I rowsort
SELECT - 54 * col0 FROM tab0 AS cor0
----
-1296
-1890
-4806

query I rowsort
SELECT DISTINCT + col1 * + col2 + - ( col2 ) + - col2 * 65 AS col0 FROM tab2 AS cor0
----
-182
-1862
-945

onlyif mysql # use DIV operator for integer division
query I rowsort label-6612
SELECT col1 DIV - col1 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6612
SELECT col1 / - col1 AS col2 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 col2 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6614
SELECT ALL col1 DIV 91 + col0 FROM tab0 cor0
----
24
36
90

skipif mysql # not compatible
query I rowsort label-6614
SELECT ALL col1 / 91 + col0 FROM tab0 cor0
----
24
36
90

query I rowsort
SELECT DISTINCT - col0 * col1 + - col0 - col0 FROM tab1 AS cor0
----
-1200
-768
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6616
SELECT - + col1 * + CAST( 19 AS SIGNED ) - col1 AS col0 FROM tab0 AS cor0
----
-1720
-1820
-1940

skipif mysql # not compatible
query I rowsort label-6616
SELECT - + col1 * + CAST ( 19 AS INTEGER ) - col1 AS col0 FROM tab0 AS cor0
----
-1720
-1820
-1940

query I rowsort
SELECT ALL cor0.col0 * col0 + cor0.col2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
6887
7618
886

query I rowsort
SELECT + + col1 + 90 * - ( cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-244
-5750
-7187

query I rowsort
SELECT + col2 * col2 * - 94 FROM tab2 cor0
----
-135736
-63544
-68526

query I rowsort
SELECT cor0.col1 * col1 + 20 FROM tab1 AS cor0
----
120
189
696

query I rowsort
SELECT + cor0.col2 * col1 * col2 + + col2 AS col1 FROM tab2 AS cor0
----
22626
24586
39910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6622
SELECT col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6622
SELECT col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + + 76 FROM tab0 AS cor0
----
109
158
77

query I rowsort
SELECT - - col0 * ( col1 ) AS col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 * col0 col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + col1 + 89 * col0 FROM tab2 AS cor0
----
654
7001
7048

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6627
SELECT ALL + col1 * - col2 * + CAST( - col1 AS SIGNED ) FROM tab0
----
244068
679042
9409

skipif mysql # not compatible
query I rowsort label-6627
SELECT ALL + col1 * - col2 * + CAST ( - col1 AS INTEGER ) FROM tab0
----
244068
679042
9409

query I rowsort
SELECT col0 * 60 FROM tab0 AS cor0
----
1440
2100
5340

query I rowsort
SELECT - col0 * col1 + col2 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT - col1 * + 47 + 64 + + col1 AS col1 FROM tab0 AS cor0
----
-3892
-4122
-4398

query I rowsort
SELECT ALL + cor0.col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT 19 * - col1 AS col0 FROM tab2
----
-1121
-323
-589

query I rowsort
SELECT col0 * + tab1.col2 - 35 FROM tab1
----
127
3613
7645

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 * + col1 col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

onlyif mysql # use DIV operator for integer division
query I rowsort label-6636
SELECT + ( cor0.col2 ) DIV col0 - col1 FROM tab0 AS cor0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-6636
SELECT + ( cor0.col2 ) / col0 - col1 FROM tab0 AS cor0
----
-85
-91
-97

query I rowsort
SELECT DISTINCT - - col1 * + col1 + - col0 * col2 * col1 AS col2 FROM tab2 AS cor0
----
-116171
-4898
-50745

query I rowsort
SELECT ALL - - col2 * col1 * - cor0.col0 - 85 * - col1 FROM tab0 AS cor0
----
-60802
-656383
4850

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6639
SELECT + CAST( ( col1 ) AS SIGNED ) * + col1 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-6639
SELECT + CAST ( ( col1 ) AS INTEGER ) * + col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT col2 - col2 * + cor0.col2 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-207879
-737184
-8694

query I rowsort
SELECT ALL + 24 + cor0.col0 AS col2 FROM tab1, tab2, tab0 cor0, tab0
----
81 values hashing to 2cfc479b8757491bb21717e1ef36822f

query I rowsort
SELECT DISTINCT col0 * 75 AS col1 FROM tab2
----
525
5850
5925

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 32 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT ALL + 45 + - cor1.col0 AS col0 FROM tab2, tab2 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to e63798e40deff86fa111de7c0e8c204a

query I rowsort
SELECT DISTINCT - 54 * + col1 * + col0 AS col1 FROM tab2
----
-11718
-248508
-72522

query I rowsort
SELECT - ( 18 ) + + col1 FROM tab2 AS cor0
----
-1
13
41

query I rowsort
SELECT col2 * col2 * col2 - + col0 FROM tab2 AS cor0
----
17498
19676
54793

query I rowsort
SELECT 15 * col1 - col1 FROM tab1 cor0
----
140
182
364

query I rowsort
SELECT + - col1 * cor0.col0 * - col1 AS col2 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT 68 + 6 + - col0 * col0 AS col2 FROM tab1 AS cor0
----
-4022
-6326
65

query I rowsort
SELECT DISTINCT - col2 - col1 AS col2 FROM tab1
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6652
SELECT col0 * tab1.col0 * - col2 + - tab1.col2 - + 29 DIV col2 AS col1 FROM tab1
----
-233529
-540
-614496

skipif mysql # not compatible
query I rowsort label-6652
SELECT col0 * tab1.col0 * - col2 + - tab1.col2 - + 29 / col2 AS col1 FROM tab1
----
-233529
-540
-614496

query I rowsort
SELECT DISTINCT + 77 - 3 FROM tab0
----
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-6654
SELECT DISTINCT - col1 DIV + col2 + + ( + ( - col0 ) * col1 ) FROM tab0 AS cor0
----
-2066
-3492
-8100

skipif mysql # not compatible
query I rowsort label-6654
SELECT DISTINCT - col1 / + col2 + + ( + ( - col0 ) * col1 ) FROM tab0 AS cor0
----
-2066
-3492
-8100

query I rowsort
SELECT DISTINCT - 80 - tab2.col2 AS col0 FROM tab2
----
-106
-107
-118

query I rowsort
SELECT - 27 * cor0.col1 + col0 FROM tab0 AS cor0
----
-2298
-2368
-2584

query I rowsort
SELECT DISTINCT + 5 + col1 * 97 AS col0 FROM tab1 AS cor0
----
1266
2527
975

query I rowsort
SELECT ALL - 5 + - col1 FROM tab1 AS cor0
----
-15
-18
-31

query I rowsort
SELECT - - 16 AS col0 FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT DISTINCT - col0 * + cor0.col0 + col1 AS col0 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT ALL - - col2 * cor0.col0 + col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT - - col1 + + col1 * + cor0.col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - + cor0.col0 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + 85 + + col2 FROM tab2
----
111
112
123

query I rowsort
SELECT ALL 44 - 6 FROM tab0
----
38
38
38

query I rowsort
SELECT + 60 + col0 * col0 FROM tab1 cor0
----
4156
6460
69

query I rowsort
SELECT DISTINCT 87 * col1 FROM tab0 AS cor0
----
7482
7917
8439

query I rowsort
SELECT ALL 32 * + col0 + col1 - - 76 FROM tab0 AS cor0
----
1293
3015
930

query I rowsort
SELECT DISTINCT col1 + - col2 * + 84 FROM tab0 AS cor0
----
-2686
-6797
13

query I rowsort
SELECT DISTINCT col0 * cor0.col2 + ( + col1 ) + + col2 AS col2 FROM tab1 AS cor0
----
242
3715
7789

query I rowsort
SELECT ALL + 21 AS col2 FROM tab1 AS cor0
----
21
21
21

query I rowsort
SELECT + ( col0 ) * col0 + + cor0.col0 * col0 AS col2 FROM tab1 cor0
----
12800
18
8192

query I rowsort
SELECT DISTINCT - - col1 * - cor0.col2 + + col1 FROM tab2 cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 25 col1 FROM tab1 AS cor0
----
-25
-25
-25

query I rowsort
SELECT ALL - - col0 + + col1 AS col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL + ( + col1 ) + col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ( - 68 ) * + col2 FROM tab0 AS cor0
----
-2244
-5576
-68

query I rowsort
SELECT DISTINCT + 4 - + 55 FROM tab0 AS cor0
----
-51

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT col1 * 92 FROM tab0 AS cor0
----
7912
8372
8924

query I rowsort
SELECT ALL 48 FROM tab0 cor0
----
48
48
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6682
SELECT DISTINCT CAST( + cor0.col1 AS SIGNED ) + + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-6682
SELECT DISTINCT CAST ( + cor0.col1 AS INTEGER ) + + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - col0 * + col0 * col0 AS col2 FROM tab2 AS cor0
----
-343
-474552
-493039

query I rowsort
SELECT - + col1 * - 40 FROM tab0 AS cor0
----
3440
3640
3880

query I rowsort
SELECT - cor0.col0 * + cor0.col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ( col0 * col0 + + col0 ) FROM tab1
----
12
4160
6480

query I rowsort
SELECT - cor0.col1 * ( col2 ) FROM tab2 cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 58 col2 FROM tab0
----
-58
-58
-58

query I rowsort
SELECT ALL 64 * + col0 AS col0 FROM tab2
----
448
4992
5056

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 cor1, tab2, tab2 cor2
----
3645 values hashing to 8e89a67df0eeeac4bb0eedb403f6bb3e

query I rowsort
SELECT ALL col2 * cor0.col0 + + 78 FROM tab1 AS cor0
----
240
3726
7758

query I rowsort
SELECT ALL + - cor0.col1 * + col2 * + 44 AS col0 FROM tab0 AS cor0
----
-124872
-328328
-4268

query I rowsort
SELECT col2 * 43 FROM tab2 AS cor0
----
1118
1161
1634

query I rowsort
SELECT - col0 * + ( col2 ) + cor0.col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - cor0.col1 + - col1 * 96 FROM tab0 cor0
----
-8342
-8827
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-6696
SELECT ALL col1 DIV - 44 + + col0 + col2 * col2 AS col1 FROM tab2 cor0
----
1523
736
753

skipif mysql # not compatible
query I rowsort label-6696
SELECT ALL col1 / - 44 + + col0 + col2 * col2 AS col1 FROM tab2 cor0
----
1523
736
753

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 * + 8 col1 FROM tab2 AS cor0
----
-392
-48672
-49928

query I rowsort
SELECT + - col0 * 71 + col0 * col1 FROM tab2 AS cor0
----
-280
-4266
-936

query I rowsort
SELECT + col2 * - cor0.col1 + 86 FROM tab2 AS cor0
----
-1448
-560
-751

query I rowsort
SELECT ALL + col1 * col2 * + col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT ALL 61 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT DISTINCT 64 FROM tab2, tab0 AS cor0
----
64

query I rowsort
SELECT ALL ( col2 ) * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - ( 22 ) AS col1 FROM tab0 AS cor0
----
-22

query I rowsort
SELECT ( - col1 ) * cor0.col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6706
SELECT ALL CAST( NULL AS SIGNED ) + cor0.col1 * - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6706
SELECT ALL CAST ( NULL AS INTEGER ) + cor0.col1 * - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - ( - ( col1 ) ) + col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - 39 + cor0.col1 FROM tab1 AS cor0
----
-13
-26
-29

query I rowsort
SELECT ALL cor0.col2 * - 66 AS col0 FROM tab0 AS cor0
----
-2178
-5412
-66

query I rowsort
SELECT + col2 * ( col1 ) + + cor0.col2 * - col2 - cor0.col1 AS col0 FROM tab0 cor0
----
-1
1663
647

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6711
SELECT DISTINCT + + CAST( NULL AS SIGNED ) * + 51 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6711
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) * + 51 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ( col2 ) * col2 + cor0.col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT - ( - ( cor0.col1 ) ) * - col2 + + col0 - - col0 AS col0 FROM tab0 cor0
----
-27
-2790
-7284

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6714
SELECT + CAST( NULL AS SIGNED ) + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6714
SELECT + CAST ( NULL AS INTEGER ) + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col2 * + ( col1 ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - 77 * col0 AS col2 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT ALL + ( - col0 ) - col0 AS col2 FROM tab2 cor0
----
-14
-156
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6718
SELECT DISTINCT col1 DIV + col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-6718
SELECT DISTINCT col1 / + col0 AS col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL tab0.col2 + col0 * col1 AS col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT - - col1 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT + 91 + col0 + + col0 AS col0 FROM tab1
----
219
251
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + col0 col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - cor0.col2 * + col1 + - col0 * - col1 AS col0 FROM tab1 cor0
----
-1326
-208
70

query I rowsort
SELECT col1 + col2 - + col0 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT - 13 * col0 * + col2 + col1 * + col2 AS col1 FROM tab0 AS cor0
----
-358
-7458
-87412

onlyif mysql # use DIV operator for integer division
query I rowsort label-6726
SELECT + + col0 + col0 DIV - col1 - col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-6726
SELECT + + col0 + col0 / - col1 - col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + col0 * cor0.col1 + - col0 * col1 - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + cor0.col2 * + cor0.col2 * col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT 42 * + col1 FROM tab1
----
1092
420
546

query I rowsort
SELECT ( + 34 ) FROM tab2 AS cor0
----
34
34
34

query I rowsort
SELECT 0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - cor0.col1 + cor1.col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 9988d482f94d4a436a2fe6e0568c1c30

onlyif mysql # use DIV operator for integer division
query I rowsort label-6733
SELECT ( 59 ) + - cor0.col0 DIV - col2 FROM tab1 AS cor0
----
59
59
60

skipif mysql # not compatible
query I rowsort label-6733
SELECT ( 59 ) + - cor0.col0 / - col2 FROM tab1 AS cor0
----
59
59
60

query I rowsort
SELECT ALL + tab1.col1 * 85 FROM tab1
----
1105
2210
850

onlyif mysql # use DIV operator for integer division
query I rowsort label-6735
SELECT DISTINCT col0 * 90 DIV - col2 AS col0 FROM tab1
----
-101
-5
-75

skipif mysql # not compatible
query I rowsort label-6735
SELECT DISTINCT col0 * 90 / - col2 AS col0 FROM tab1
----
-101
-5
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-6736
SELECT - ( col1 ) DIV col1 AS col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6736
SELECT - ( col1 ) / col1 AS col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT ALL col2 + + 6 + tab1.col1 FROM tab1
----
115
73
86

query I rowsort
SELECT DISTINCT - col0 * col0 * col1 + + col1 * - col2 * col0 FROM tab2 AS cor0
----
-157131
-478608
-7378

query I rowsort
SELECT + - cor0.col1 + + cor0.col2 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 92ef426526338653e88acd4aba639c47

query I rowsort
SELECT + 2 AS col0 FROM tab2
----
2
2
2

query I rowsort
SELECT ALL + 7 * + tab0.col2 AS col0 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 78842a90a157a59490ffd43288254f32

query I rowsort
SELECT tab1.col2 * - col1 * col2 AS col2 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT - 14 * + cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 0dbc7fa35f58dcd884d0d48d75ba2937

query I rowsort
SELECT col0 * + 1 + col0 AS col0 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6745
SELECT col1 * + CAST( col1 AS SIGNED ) * - col2 AS col0 FROM tab0 cor0
----
-244068
-679042
-9409

skipif mysql # not compatible
query I rowsort label-6745
SELECT col1 * + CAST ( col1 AS INTEGER ) * - col2 AS col0 FROM tab0 cor0
----
-244068
-679042
-9409

query I rowsort
SELECT - col2 + + col2 + - col1 AS col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT col1 + col1 * - col1 + - col0 FROM tab1
----
-154
-236
-653

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6748
SELECT CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6748
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 14 col1 FROM tab2
----
-14
-14
-14

onlyif mysql # use DIV operator for integer division
query I rowsort label-6750
SELECT - 31 + col0 DIV tab0.col0 + - col1 DIV col1 AS col1 FROM tab0
----
-31
-31
-31

skipif mysql # not compatible
query I rowsort label-6750
SELECT - 31 + col0 / tab0.col0 + - col1 / col1 AS col1 FROM tab0
----
-31
-31
-31

query I rowsort
SELECT - col0 * - col2 - + col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT - col1 + col2 * - col0 AS col2 FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT - col2 * col2 + col0 * - col2 AS col2 FROM tab2 cor0
----
-2704
-4446
-918

query I rowsort
SELECT ALL - col2 + col1 - col1 * 33 FROM tab2 AS cor0
----
-1019
-1914
-582

query I rowsort
SELECT ALL + cor0.col0 + - col0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + + col2 - + cor0.col1 AS col1 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT col0 * + col1 + col2 * col0 AS col2 FROM tab2 cor0
----
406
4345
6630

query I rowsort
SELECT ALL 85 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

query I rowsort
SELECT DISTINCT 58 * - col1 FROM tab2
----
-1798
-3422
-986

query I rowsort
SELECT col1 + + col2 * - ( col1 ) AS col1 FROM tab1
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6761
SELECT + tab1.col1 DIV - col2 + col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6761
SELECT + tab1.col1 / - col2 + col1 FROM tab1
----
10
13
26

query I rowsort
SELECT 30 * col1 AS col1 FROM tab1 AS cor0
----
300
390
780

query I rowsort
SELECT DISTINCT col0 * col1 + + 74 * 2 FROM tab0 AS cor0
----
2212
3543
8247

query I rowsort
SELECT - - ( col0 ) AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + ( cor1.col2 ) AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL col2 + - col2 * col0 FROM tab2 cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT - col1 * - ( - 36 ) + - cor0.col2 FROM tab1 AS cor0
----
-417
-564
-990

query I rowsort
SELECT ALL col1 + col2 + - col0 FROM tab2 cor0
----
-24
51
7

query I rowsort
SELECT DISTINCT + + col2 - - col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - + cor0.col1 * - col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col0 * 84 + - col1 * + col0 FROM tab0 AS cor0
----
-455
-48
-623

query I rowsort
SELECT tab0.col0 * + 11 FROM tab0, tab0 AS cor0
----
9 values hashing to d5f019c64d99542fd05343b7d7073c98

query I rowsort
SELECT DISTINCT 17 * col2 FROM tab1
----
1632
918
969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 * + 98 ) col1 FROM tab2
----
-2548
-2646
-3724

query I rowsort
SELECT DISTINCT 99 * - col2 FROM tab2
----
-2574
-2673
-3762

query I rowsort
SELECT - col2 * - ( - 14 ) AS col1 FROM tab0 AS cor0
----
-1148
-14
-462

query I rowsort
SELECT DISTINCT + col0 * 93 FROM tab0 AS cor0
----
2232
3255
8277

query I rowsort
SELECT 80 - - cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 187baf1077bdd4e6dd8c8df53c3ece94

query I rowsort
SELECT ALL - - col1 * col2 + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - col2 + 55 AS col2 FROM tab1
----
-2
-41
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6781
SELECT + 44 * ( col2 ) + CAST( - col1 AS SIGNED ) AS col2 FROM tab1 cor0
----
2350
2498
4211

skipif mysql # not compatible
query I rowsort label-6781
SELECT + 44 * ( col2 ) + CAST ( - col1 AS INTEGER ) AS col2 FROM tab1 cor0
----
2350
2498
4211

query I rowsort
SELECT + - ( - 97 ) + cor0.col0 * - 76 AS col0 FROM tab0 AS cor0
----
-1727
-2563
-6667

query I rowsort
SELECT 82 * - 92 FROM tab2, tab0 cor0
----
9 values hashing to 7f02aa021e0977d86304820e097b64d5

query I rowsort
SELECT ALL ( ( - cor0.col2 ) ) AS col1 FROM tab0, tab2 cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6785
SELECT - tab0.col1 + + CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6785
SELECT - tab0.col1 + + CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 1 * - 27 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

query I rowsort
SELECT - - col1 + - col2 + - col0 AS col0 FROM tab2 AS cor0
----
-100
-3
-45

query I rowsort
SELECT DISTINCT - col1 * col1 + + ( 82 ) FROM tab1 AS cor0
----
-18
-594
-87

query I rowsort
SELECT DISTINCT col2 + - col2 * + col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT + - 59 + cor0.col0 * - col2 FROM tab0 AS cor0
----
-7357
-851
-94

query I rowsort
SELECT ALL - - cor0.col2 * + col1 + - col1 * ( + col0 ) AS col0 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT cor0.col2 * + col1 + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT col2 * - col2 + - col0 * + col2 - + col0 AS col2 FROM tab0 AS cor0
----
-14111
-1905
-71

query I rowsort
SELECT + ( + col2 ) + col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + col0 col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL 8 + col2 FROM tab2
----
34
35
46

query I rowsort
SELECT col0 + + ( col0 ) FROM tab1
----
128
160
6

query I rowsort
SELECT ALL tab0.col0 * - col1 + col1 AS col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - tab1.col2 + + col0 * col2 AS col2 FROM tab1
----
108
3591
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-6800
SELECT ALL ( col1 ) + col1 DIV + col0 AS col2 FROM tab2
----
17
35
59

skipif mysql # not compatible
query I rowsort label-6800
SELECT ALL ( col1 ) + col1 / + col0 AS col2 FROM tab2
----
17
35
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6801
SELECT - col2 DIV tab0.col2 + + col0 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6801
SELECT - col2 / tab0.col2 + + col0 FROM tab0
----
23
34
88

query I rowsort
SELECT DISTINCT + - 54 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-54

query I rowsort
SELECT DISTINCT + 37 + - col2 AS col0 FROM tab2 AS cor0
----
-1
10
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-6804
SELECT ALL + col2 + - cor0.col0 + ( + col2 ) DIV col2 FROM tab1 cor0
----
-6
17
52

skipif mysql # not compatible
query I rowsort label-6804
SELECT ALL + col2 + - cor0.col0 + ( + col2 ) / col2 FROM tab1 cor0
----
-6
17
52

query I rowsort
SELECT ALL 69 + col0 AS col2 FROM tab0 AS cor0
----
104
158
93

query I rowsort
SELECT + + 27 FROM tab1 AS cor0
----
27
27
27

query I rowsort
SELECT ALL + col1 + - col2 * 80 FROM tab1 cor0
----
-4294
-4550
-7667

query I rowsort
SELECT ALL - cor0.col0 * - col2 + 8 FROM tab1 AS cor0
----
170
3656
7688

query I rowsort
SELECT ALL 19 * col2 + + ( col0 ) AS col2 FROM tab2 AS cor0
----
520
572
801

onlyif mysql # use DIV operator for integer division
query I rowsort label-6810
SELECT - 62 DIV col2 - + col0 AS col2 FROM tab1 AS cor0
----
-4
-65
-80

skipif mysql # not compatible
query I rowsort label-6810
SELECT - 62 / col2 - + col0 AS col2 FROM tab1 AS cor0
----
-4
-65
-80

query I rowsort
SELECT + ( + cor0.col1 ) * ( col2 ) + - col2 AS col0 FROM tab1 AS cor0
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 39 + - 91 * col1 col2 FROM tab2
----
-1586
-2860
-5408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + ( col0 ) + - col2 + - col1 col1 FROM tab2
----
-9
5999
6186

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) * tab2.col2 * col2 + col0 col2 FROM tab2
----
-17498
-19676
-54793

query I rowsort
SELECT + ( + ( tab2.col1 ) ) * + tab2.col1 + col0 * + col1 + col0 AS col0 FROM tab2
----
1185
1711
8161

query I rowsort
SELECT 64 * col1 * + col1 AS col1 FROM tab2
----
18496
222784
61504

query I rowsort
SELECT DISTINCT + col0 + - col0 - - col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + 54 * col0 FROM tab1 AS cor0
----
162
3456
4320

onlyif mysql # use DIV operator for integer division
query I rowsort label-6819
SELECT ( col0 ) DIV - col1 + cor0.col1 * - col2 FROM tab2 AS cor0
----
-1535
-650
-837

skipif mysql # not compatible
query I rowsort label-6819
SELECT ( col0 ) / - col1 + cor0.col1 * - col2 FROM tab2 AS cor0
----
-1535
-650
-837

query I rowsort
SELECT ALL + 26 * col0 + + col0 FROM tab0 AS cor0
----
2403
648
945

query I rowsort
SELECT DISTINCT 38 * col0 FROM tab1 AS cor0
----
114
2432
3040

query I rowsort
SELECT - - col1 * - ( - ( - col0 ) ) * 65 FROM tab1 AS cor0
----
-41600
-5070
-67600

query I rowsort
SELECT DISTINCT + - col0 + - 98 AS col0 FROM tab1 AS cor0
----
-101
-162
-178

query I rowsort
SELECT ALL - + cor0.col1 * - 86 AS col0 FROM tab1 AS cor0
----
1118
2236
860

query I rowsort
SELECT - ( + 97 ) AS col1 FROM tab2, tab2 cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT DISTINCT + - col1 + - col2 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6827
SELECT - col0 - col0 DIV + col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-6827
SELECT - col0 - col0 / + col0 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT DISTINCT + 6 + col0 * - col1 AS col0 FROM tab2 AS cor0
----
-1337
-211
-4596

query I rowsort
SELECT + ( - col2 ) * col1 - - col1 AS col2 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL + 10 - + col0 * col0 FROM tab1 AS cor0
----
-4086
-6390
1

query I rowsort
SELECT DISTINCT + 18 FROM tab2, tab2 AS cor0
----
18

query I rowsort
SELECT DISTINCT - cor0.col0 + + tab2.col1 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to dbfc6e14a516b2f4a3bad04409a815fc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6833
SELECT - - CAST( - col1 AS SIGNED ) * + col0 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-6833
SELECT - - CAST ( - col1 AS INTEGER ) * + col0 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 94 col0 FROM tab1 AS cor0
----
1222
2444
940

query I rowsort
SELECT ALL - 13 + + 60 AS col1 FROM tab2 cor0
----
47
47
47

query I rowsort
SELECT ALL + - col2 * + ( col0 * 48 ) FROM tab2 AS cor0
----
-144096
-9072
-97344

query I rowsort
SELECT ALL + col1 * + col0 - - col2 AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT cor0.col0 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6839
SELECT - + col2 DIV + 95 col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6839
SELECT - + col2 / + 95 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ( - col0 ) + - col2 * + 3 FROM tab0 AS cor0
----
-123
-335
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6841
SELECT - CAST( NULL AS SIGNED ) + + col1 * + col0 / + ( col2 * + col0 ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6841
SELECT - CAST ( NULL AS INTEGER ) + + col1 * + col0 / + ( col2 * + col0 ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 41 + col1 * 56 AS col2 FROM tab2 AS cor0
----
1777
3345
993

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + cor0.col1 col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - 70 AS col1 FROM tab2 cor0
----
-70
-70
-70

query I rowsort
SELECT - - col2 * 88 AS col0 FROM tab0 cor0
----
2904
7216
88

query I rowsort
SELECT 21 * - ( - col0 ) FROM tab1 cor0
----
1344
1680
63

query I rowsort
SELECT + ( 4 ) * col1 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT - ( + 74 ) * + col1 FROM tab1 cor0
----
-1924
-740
-962

query I rowsort
SELECT - col0 + 50 * col1 * + 13 AS col1 FROM tab0 AS cor0
----
55876
59061
63015

onlyif mysql # use DIV operator for integer division
query I rowsort label-6850
SELECT ALL col2 DIV - 46 FROM tab1
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-6850
SELECT ALL col2 / - 46 FROM tab1
----
-1
-1
-2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6851
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6851
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - col0 * col1 AS col2 FROM tab1 WHERE ( + col0 ) <> NULL
----

query I rowsort
SELECT - col1 * cor0.col1 * col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT col1 + col1 + col0 * + col1 FROM tab1 AS cor0
----
1066
130
660

query I rowsort
SELECT + col0 * - tab1.col2 AS col2 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6856
SELECT ALL - tab0.col2 DIV col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6856
SELECT ALL - tab0.col2 / col0 FROM tab0
----
-1
0
0

query III rowsort
SELECT ALL * FROM tab1 WHERE col2 + + col0 - + col1 NOT IN ( + col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL + col1 + + tab1.col0 + col0 AS col2 FROM tab1
----
138
173
32

query I rowsort
SELECT col1 + col2 + + col1 FROM tab0
----
195
205
264

query I rowsort
SELECT - col2 * + col2 * col0 FROM tab1
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-6861
SELECT + col2 * + col1 DIV col1 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6861
SELECT + col2 * + col1 / col1 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT col0 * - col0 + col1 * + col1 + col1 * col1 FROM tab1
----
-3896
-6062
1343

query I rowsort
SELECT DISTINCT - col0 + + col0 * col0 AS col2 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT ALL - cor0.col0 * - cor0.col1 FROM tab2 AS cor0
----
1343
217
4602

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT - col0 IN ( col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6866
SELECT col0 DIV + tab1.col1 + col0 AS col1 FROM tab1
----
3
70
86

skipif mysql # not compatible
query I rowsort label-6866
SELECT col0 / + tab1.col1 + col0 AS col1 FROM tab1
----
3
70
86

query I rowsort
SELECT col0 * + col2 - col2 FROM tab1
----
108
3591
7584

query I rowsort
SELECT - tab1.col0 * col1 * + col2 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6869
SELECT + + col2 DIV + col2 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6869
SELECT + + col2 / + col2 FROM tab0 cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6870
SELECT DISTINCT - col0 * col2 + - col0 DIV - col2 FROM tab0
----
-7297
-792
0

skipif mysql # not compatible
query I rowsort label-6870
SELECT DISTINCT - col0 * col2 + - col0 / - col2 FROM tab0
----
-7297
-792
0

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NULL > NULL OR NOT NULL BETWEEN - col0 * col2 AND NULL
----

query I rowsort
SELECT ALL col1 * + col0 + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL cor0.col0 + cor0.col1 * - col1 + - col1 FROM tab1 AS cor0
----
-102
-46
-699

onlyif mysql # use DIV operator for integer division
query I rowsort label-6874
SELECT DISTINCT col0 DIV + cor0.col0 - col2 FROM tab2 cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-6874
SELECT DISTINCT col0 / + cor0.col0 - col2 FROM tab2 cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT - 47 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-47

query I rowsort
SELECT DISTINCT + 67 * col2 * - tab0.col2 FROM tab0
----
-450508
-67
-72963

query I rowsort
SELECT - ( + tab2.col1 ) FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL 42 * + col2 FROM tab0 AS cor0
----
1386
3444
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col1 ) + 79 col1 FROM tab1 AS cor0
----
53
66
69

query I rowsort
SELECT DISTINCT - 3 + col1 * - col2 AS col1 FROM tab2 cor0
----
-1537
-649
-840

query I rowsort
SELECT ALL + ( col1 ) * - ( 56 ) FROM tab0 AS cor0
----
-4816
-5096
-5432

query I rowsort
SELECT DISTINCT - + 1 AS col1 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT - col0 * 46 FROM tab1 cor0
----
-138
-2944
-3680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6884
SELECT ALL col1 + CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-6884
SELECT ALL col1 + CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - + col1 - + 95 * 20 FROM tab0 AS cor0
----
-1986
-1991
-1997

query I rowsort
SELECT ALL col2 * 84 AS col1 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT ALL - + col0 + ( col2 ) FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-6888
SELECT ALL cor0.col2 DIV 90 + + col1 AS col1 FROM tab1 AS cor0
----
10
14
26

skipif mysql # not compatible
query I rowsort label-6888
SELECT ALL cor0.col2 / 90 + + col1 AS col1 FROM tab1 AS cor0
----
10
14
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 43 * - tab0.col0 col2 FROM tab0
----
1032
1505
3827

query I rowsort
SELECT ( - cor0.col1 ) AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6891
SELECT tab0.col0 + col0 DIV - 51 col0 FROM tab0
----
24
35
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6891
SELECT tab0.col0 + col0 / - 51 col0 FROM tab0
----
24
35
88

query I rowsort
SELECT - + col0 * - col0 * cor0.col1 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT - ( + col1 * ( col2 ) ) - tab0.col1 FROM tab0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-6894
SELECT DISTINCT col0 + + tab2.col0 DIV + col1 FROM tab2
----
7
79
83

skipif mysql # not compatible
query I rowsort label-6894
SELECT DISTINCT col0 + + tab2.col0 / + col1 FROM tab2
----
7
79
83

query I rowsort
SELECT - col2 * + col2 + + col1 FROM tab2
----
-1427
-617
-698

query III rowsort
SELECT * FROM tab2 WHERE NOT col0 * + col2 + col0 + col1 >= NULL
----

query I rowsort
SELECT ALL - col1 * - col0 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL + col2 * tab2.col2 AS col1 FROM tab2
----
1444
676
729

query III rowsort
SELECT * FROM tab1 WHERE col2 IN ( - col2 )
----

query I rowsort
SELECT ALL - tab0.col0 + col0 * col0 * col0 AS col1 FROM tab0
----
13800
42840
704880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col1 col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col1 * col0 * - col2 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-6903
SELECT ALL - + 86 DIV col0 AS col1 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-6903
SELECT ALL - + 86 / col0 AS col1 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT col1 + col1 + + tab2.col0 FROM tab2
----
113
196
69

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL NOT BETWEEN ( NULL ) AND col0 + col0
----

query I rowsort
SELECT DISTINCT + tab0.col1 * - col2 - col1 AS col2 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT - col0 - + col1 * col0 AS col2 FROM tab2
----
-1422
-224
-4680

query I rowsort
SELECT - col2 * - col1 + col2 * tab2.col2 AS col2 FROM tab2
----
1566
2090
2210

query I rowsort
SELECT tab0.col2 * + tab0.col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT - col2 + col1 - + col2 AS col1 FROM tab2
----
-23
-59
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6911
SELECT + col2 DIV - tab1.col0 AS col2 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-6911
SELECT + col2 / - tab1.col0 AS col2 FROM tab1
----
-1
-18
0

query I rowsort
SELECT ALL - col1 * + col1 - - col1 AS col2 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT col2 * tab1.col0 * + tab1.col2 AS col1 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT ALL col1 * col1 * col0 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6915
SELECT ALL col0 / - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6915
SELECT ALL col0 / - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col0 col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col0 * ( col1 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - col2 * ( col0 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + cor0.col0 * ( - col1 ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT 53 - col2 FROM tab1 AS cor0
----
-1
-4
-43

query I rowsort
SELECT - - 8 - col0 FROM tab2 AS cor0
----
-70
-71
1

query I rowsort
SELECT - 33 + + col2 - col2 AS col0 FROM tab0 cor0
----
-33
-33
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 97 * + col2 col0 FROM tab0 AS cor0
----
3201
7954
97

query I rowsort
SELECT + 6 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT ALL + col1 * - col1 + tab1.col2 AS col2 FROM tab1
----
-43
-622
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col0 col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - - 62 FROM tab0 AS cor0
----
62
62
62

query I rowsort
SELECT DISTINCT - 89 * + cor0.col2 * + ( 45 + col1 * col0 ) FROM tab1 cor0
----
-3475005
-591138
-9270240

query I rowsort
SELECT - 32 * col1 * col0 FROM tab0 cor0
----
-108640
-259168
-66048

query I rowsort
SELECT DISTINCT - 37 FROM tab2
----
-37

query I rowsort
SELECT DISTINCT 59 AS col2 FROM tab0
----
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6932
SELECT - col2 + - col1 DIV 24 AS col0 FROM tab0 AS cor0
----
-36
-5
-85

skipif mysql # not compatible
query I rowsort label-6932
SELECT - col2 + - col1 / 24 AS col0 FROM tab0 AS cor0
----
-36
-5
-85

query I rowsort
SELECT tab0.col1 * + col2 + 81 * ( col1 ) AS col0 FROM tab0
----
14833
7954
9804

query I rowsort
SELECT - col1 + - cor0.col0 * - col0 AS col0 FROM tab1 AS cor0
----
-17
4086
6387

onlyif mysql # use DIV operator for integer division
query I rowsort label-6935
SELECT DISTINCT + + 95 DIV col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-6935
SELECT DISTINCT + + 95 / col2 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT - 77 * + col2 AS col2 FROM tab0 cor0
----
-2541
-6314
-77

query I rowsort
SELECT ALL - col1 * ( col2 ) * col2 + + ( col2 + col0 ) * col0 FROM tab1 AS cor0
----
-105728
-24746
-75645

onlyif mysql # use DIV operator for integer division
query I rowsort label-6938
SELECT col2 + - 5 DIV + col1 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6938
SELECT col2 + - 5 / + col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + cor0.col0 * ( col0 ) FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6940
SELECT + + col0 DIV 17 AS col1 FROM tab0 cor0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-6940
SELECT + + col0 / 17 AS col1 FROM tab0 cor0
----
1
2
5

query I rowsort
SELECT 17 AS col0 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT ALL + 14 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col0 col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT - 40 + 37 AS col2 FROM tab1 AS cor0
----
-3
-3
-3

query I rowsort
SELECT + 85 FROM tab2 cor0
----
85
85
85

query I rowsort
SELECT + - 78 AS col1 FROM tab2 AS cor0
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6947
SELECT ALL - - col1 + cor0.col2 DIV col0 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-6947
SELECT ALL - - col1 + cor0.col2 / col0 FROM tab0 AS cor0
----
87
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + + col2 col0 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col0 ) + col1 col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + 24 * + col0 FROM tab0 AS cor0
----
2136
576
840

query I rowsort
SELECT DISTINCT - col2 * + 10 * col1 FROM tab1 cor0
----
-12480
-14040
-5700

query I rowsort
SELECT DISTINCT - 26 * 20 AS col0 FROM tab1 AS cor0
----
-520

query I rowsort
SELECT 77 AS col2 FROM tab2 cor0
----
77
77
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-6954
SELECT ALL - 15 + + 60 DIV - col0 FROM tab2 AS cor0
----
-15
-15
-23

skipif mysql # not compatible
query I rowsort label-6954
SELECT ALL - 15 + + 60 / - col0 FROM tab2 AS cor0
----
-15
-15
-23

query I rowsort
SELECT - 9 * cor0.col2 FROM tab0 AS cor0
----
-297
-738
-9

query I rowsort
SELECT + col1 * + ( - col1 * + col1 ) FROM tab0 AS cor0
----
-636056
-753571
-912673

onlyif mysql # use DIV operator for integer division
query I rowsort label-6957
SELECT - col0 DIV cor0.col0 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6957
SELECT - col0 / cor0.col0 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6958
SELECT - + col0 + - col2 DIV col2 + col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
35
672
88

skipif mysql # not compatible
query I rowsort label-6958
SELECT - + col0 + - col2 / col2 + col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
35
672
88

skipif mysql # not compatible
query I rowsort
SELECT ALL - - CAST ( 63 AS REAL ) AS col2 FROM tab0 AS cor0
----
63
63
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( + cor0.col1 AS REAL ) col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - ( + col2 ) + + col1 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - 6 AS col1 FROM tab1 AS cor0
----
-6
-6
-6

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 + col2 AS col1 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT ALL + col2 * - cor0.col0 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6965
SELECT DISTINCT - - cor0.col1 + - 6 DIV + col1 AS col0 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6965
SELECT DISTINCT - - cor0.col1 + - 6 / + col1 AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL + + cor0.col1 + col0 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + col2 - col1 AS col0 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - 80 * - col1 AS col0 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT DISTINCT - 33 - col1 FROM tab2 cor0
----
-50
-64
-92

query I rowsort
SELECT - cor0.col0 + ( - cor0.col1 ) + col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - col0 + 97 + + col0 FROM tab1 AS cor0
----
97
97
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * + col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + - col0 + 34 AS col2 FROM tab1 AS cor0
----
-30
-46
31

query I rowsort
SELECT DISTINCT - col2 * 69 FROM tab0 cor0
----
-2277
-5658
-69

query I rowsort
SELECT - col0 * - 0 + - col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + tab1.col2 + ( cor0.col0 * 86 ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 98a4e1162f8bae34236778decba5b506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col0 * + col2 * - col1 col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL col1 + + ( - tab1.col2 * + col0 ) AS col1 FROM tab1
----
-136
-3638
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6979
SELECT + tab1.col1 + CAST( NULL AS SIGNED ) * tab1.col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6979
SELECT + tab1.col1 + CAST ( NULL AS INTEGER ) * tab1.col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * + col0 + col1 + - col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT cor0.col0 * - 69 + + 39 AS col1 FROM tab1 AS cor0
----
-168
-4377
-5481

onlyif mysql # use DIV operator for integer division
query I rowsort label-6982
SELECT tab1.col1 DIV + 34 + + 77 DIV - col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-6982
SELECT tab1.col1 / + 34 + + 77 / - col1 FROM tab1
----
-2
-5
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6983
SELECT col1 + + CAST( NULL AS SIGNED ) * - tab1.col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6983
SELECT col1 + + CAST ( NULL AS INTEGER ) * - tab1.col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col2 + - col0 col0 FROM tab1
----
-2919
-3313
-9296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6985
SELECT - CAST( NULL AS SIGNED ) + + 20 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6985
SELECT - CAST ( NULL AS INTEGER ) + + 20 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6986
SELECT + tab0.col2 DIV ( col0 ) FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6986
SELECT + tab0.col2 / ( col0 ) FROM tab0
----
0
0
1

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2, tab1 AS cor3
----
3645 values hashing to f464d40c605db608927f2c4d66190a23

query I rowsort
SELECT ALL + 3 AS col1 FROM tab1 cor0
----
3
3
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 82 + col1 col2 FROM tab0
----
168
173
179

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 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT ALL col0 * + 71 FROM tab2
----
497
5538
5609

query I rowsort
SELECT DISTINCT - ( 8 ) AS col0 FROM tab0 AS cor0
----
-8

query I rowsort
SELECT 33 FROM tab2, tab1 cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT ALL - - col1 + + 70 FROM tab0 AS cor0
----
156
161
167

query I rowsort
SELECT DISTINCT - col0 + 91 FROM tab0 AS cor0
----
2
56
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-6996
SELECT - col2 DIV col0 + + ( - col0 ) AS col1 FROM tab1
----
-21
-64
-81

skipif mysql # not compatible
query I rowsort label-6996
SELECT - col2 / col0 + + ( - col0 ) AS col1 FROM tab1
----
-21
-64
-81

query I rowsort
SELECT + 41 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT ALL - - 16 + col0 FROM tab1 AS cor0
----
19
80
96

query I rowsort
SELECT DISTINCT + + 87 * - col0 AS col2 FROM tab1 AS cor0
----
-261
-5568
-6960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7000
SELECT DISTINCT - cor0.col0 + col2 * CAST( 21 AS SIGNED ) col2 FROM tab0 AS cor0
----
-14
1633
669

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7000
SELECT DISTINCT - cor0.col0 + col2 * CAST ( 21 AS INTEGER ) col2 FROM tab0 AS cor0
----
-14
1633
669

query I rowsort
SELECT DISTINCT - cor0.col2 * - 26 AS col0 FROM tab2 AS cor0
----
676
702
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + + col2 + + col1 * col1 col0 FROM tab1 AS cor0
----
147
252
704

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7003
SELECT DISTINCT - col2 * + CAST( NULL AS SIGNED ) + - col1 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7003
SELECT DISTINCT - col2 * + CAST ( NULL AS INTEGER ) + - col1 AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7004
SELECT ALL - + col0 * CAST( NULL AS DECIMAL ) + col0 + col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7004
SELECT ALL - + col0 * CAST ( NULL AS REAL ) + col0 + col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + col1 * + col1 AS col1 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT + col2 + + cor0.col2 * col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + col0 * - ( + 27 ) - - cor0.col0 * + 90 AS col0 FROM tab1 cor0
----
189
4032
5040

query I rowsort
SELECT - col1 * col0 - + col1 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL - col2 * + ( + col0 ) FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT col0 - + ( + 1 ) AS col2 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT + + col0 + + 88 AS col2 FROM tab2 AS cor0
----
166
167
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-7012
SELECT + col2 DIV col1 + - col1 * - col0 FROM tab0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-7012
SELECT + col2 / col1 + - col1 * - col0 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-7013
SELECT - col1 DIV col2 col2 FROM tab0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7013
SELECT - col1 / col2 col2 FROM tab0
----
-1
-2
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7014
SELECT DISTINCT + col0 + + CAST( col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-7014
SELECT DISTINCT + col0 + + CAST ( col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + col1 * - ( + col1 ) AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL col2 * - col2 + col1 FROM tab2 cor0
----
-1427
-617
-698

query I rowsort
SELECT col0 * + col1 + - 52 AS col1 FROM tab0 AS cor0
----
2012
3343
8047

query I rowsort
SELECT + col0 + 30 AS col1 FROM tab2 AS cor0
----
108
109
37

query I rowsort
SELECT cor0.col1 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + 77 AS col1 FROM tab0
----
77
77
77

query I rowsort
SELECT DISTINCT - 81 * + ( col0 ) AS col0 FROM tab2 AS cor0
----
-567
-6318
-6399

query I rowsort
SELECT + 92 + + cor0.col2 * col2 AS col2 FROM tab2 cor0
----
1536
768
821

query I rowsort
SELECT DISTINCT + + 3 + + col0 * col1 FROM tab1 AS cor0
----
1043
643
81

query I rowsort
SELECT + 40 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1040
400
520

query I rowsort
SELECT ALL 35 * - 10 AS col1 FROM tab1
----
-350
-350
-350

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - 88 ) col2 FROM tab1 AS cor0
----
-88
-88
-88

query I rowsort
SELECT + - col0 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * col0 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 * - col1 + + 58 FROM tab2 AS cor0
----
-231
-3423
-903

query I rowsort
SELECT DISTINCT + col2 * - 51 FROM tab0
----
-1683
-4182
-51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + cor0.col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7032
SELECT + - col0 DIV - 13 + - col1 * col2 * + col1 + - col2 FROM tab0 AS cor0
----
-244100
-679118
-9408

skipif mysql # not compatible
query I rowsort label-7032
SELECT + - col0 / - 13 + - col1 * col2 * + col1 + - col2 FROM tab0 AS cor0
----
-244100
-679118
-9408

query I rowsort
SELECT ALL + col0 * ( - 46 ) AS col0 FROM tab1 AS cor0
----
-138
-2944
-3680

query I rowsort
SELECT DISTINCT + col0 * - col1 * + col0 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT - col1 * - 93 FROM tab1 cor0
----
1209
2418
930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - cor0.col1 + - 86 + col1 col2 FROM tab1 AS cor0
----
-1113
-138
-716

query I rowsort
SELECT + col0 * 50 FROM tab0 cor0
----
1200
1750
4450

query I rowsort
SELECT + col1 * + cor0.col2 + + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT - cor0.col1 * col1 + col1 FROM tab0 cor0
----
-7310
-8190
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7040
SELECT + - col1 * CAST( NULL AS SIGNED ) - - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7040
SELECT + - col1 * CAST ( NULL AS INTEGER ) - - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col1 + + cor0.col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL col1 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7043
SELECT - cor0.col0 * CAST( + 87 AS SIGNED ) FROM tab0 cor0
----
-2088
-3045
-7743

skipif mysql # not compatible
query I rowsort label-7043
SELECT - cor0.col0 * CAST ( + 87 AS INTEGER ) FROM tab0 cor0
----
-2088
-3045
-7743

query I rowsort
SELECT cor0.col0 * + 77 + + cor0.col0 AS col1 FROM tab1 cor0
----
234
4992
6240

query I rowsort
SELECT - col1 + 80 * col0 * - col1 AS col2 FROM tab0
----
-165206
-271697
-648011

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7046
SELECT - CAST( NULL AS DECIMAL ) * 83 + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7046
SELECT - CAST ( NULL AS REAL ) * 83 + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - ( + col2 ) + col1 + cor0.col0 * + 25 * - col0 AS col0 FROM tab0 cor0
----
-14347
-198016
-30529

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * - col0 + + col1 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col0 * 43 * + 92 FROM tab2
----
27692
308568
312524

query I rowsort
SELECT - col1 * 4 FROM tab0
----
-344
-364
-388

query I rowsort
SELECT + + 4 * - cor0.col1 + - col2 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-124
-236
-68

query I rowsort
SELECT DISTINCT 37 AS col2 FROM tab2 cor0
----
37

query I rowsort
SELECT ALL - + ( col1 ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + col1 * 45 + - col0 AS col2 FROM tab0 AS cor0
----
3846
4006
4330

query I rowsort
SELECT - - 9 * - 22 + + cor0.col2 FROM tab2 AS cor0
----
-160
-171
-172

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col0 AS REAL ) + + col0 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7057
SELECT ALL + ( ( - col1 ) ) + + CAST( + col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-7057
SELECT ALL + ( ( - col1 ) ) + + CAST ( + col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 * 41 col1 FROM tab0 AS cor0
----
139195
332059
84624

onlyif mysql # use DIV operator for integer division
query I rowsort label-7059
SELECT - col2 DIV - col1 + col2 + 18 FROM tab0 AS cor0
----
100
19
51

skipif mysql # not compatible
query I rowsort label-7059
SELECT - col2 / - col1 + col2 + 18 FROM tab0 AS cor0
----
100
19
51

query I rowsort
SELECT DISTINCT 11 * - col2 + cor0.col1 AS col1 FROM tab1 AS cor0
----
-1043
-568
-617

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - tab1.col1 + col0 AS col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT + 90 AS col0 FROM tab1
----
90
90
90

query I rowsort
SELECT ALL 2 + - col0 FROM tab1
----
-1
-62
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7065
SELECT + - col2 * col1 + - col1 DIV + col0 FROM tab0 AS cor0
----
-2841
-7463
-99

skipif mysql # not compatible
query I rowsort label-7065
SELECT + - col2 * col1 + - col1 / + col0 FROM tab0 AS cor0
----
-2841
-7463
-99

query I rowsort
SELECT ALL - tab2.col0 - ( - ( + col1 ) ) FROM tab2
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-7067
SELECT cor0.col0 DIV - col0 - - 11 FROM tab1 AS cor0
----
10
10
10

skipif mysql # not compatible
query I rowsort label-7067
SELECT cor0.col0 / - col0 - - 11 FROM tab1 AS cor0
----
10
10
10

query I rowsort
SELECT ALL + 72 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT - cor0.col2 * cor0.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 42bf3b8f2bb865dbe16abdf6d3d647fc

query I rowsort
SELECT DISTINCT - - 3 AS col1 FROM tab0 AS cor0
----
3

query I rowsort
SELECT ALL - 46 + - col0 * + 9 AS col2 FROM tab1 AS cor0
----
-622
-73
-766

onlyif mysql # use DIV operator for integer division
query I rowsort label-7072
SELECT ALL col0 + col2 DIV 87 AS col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-7072
SELECT ALL col0 + col2 / 87 AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - 75 + col2 FROM tab1 AS cor0
----
-18
-21
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-7074
SELECT + col0 DIV - cor0.col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7074
SELECT + col0 / - cor0.col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT 2 FROM tab2 AS cor0
----
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7076
SELECT col1 * col0 + + CAST( - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
24
583
944

skipif mysql # not compatible
query I rowsort label-7076
SELECT col1 * col0 + + CAST ( - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL - col0 + + col0 + - 11 FROM tab2 AS cor0
----
-11
-11
-11

query IIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0 WHERE NOT ( NULL ) = NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7079
SELECT DISTINCT + col1 DIV col2 + col2 * + col2 * CAST( 84 AS SIGNED ) + col2 FROM tab1 AS cor0
----
244998
272973
774240

skipif mysql # not compatible
query I rowsort label-7079
SELECT DISTINCT + col1 / col2 + col2 * + col2 * CAST ( 84 AS INTEGER ) + col2 FROM tab1 AS cor0
----
244998
272973
774240

query I rowsort
SELECT 15 * col0 AS col1 FROM tab2
----
105
1170
1185

query I rowsort
SELECT ALL + + 92 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7082
SELECT ALL + col2 + col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-7082
SELECT ALL + col2 + col1 / - col1 AS col0 FROM tab1 AS cor0
----
53
56
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7083
SELECT DISTINCT cor0.col0 - + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7083
SELECT DISTINCT cor0.col0 - + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 88 + + col0 * - col0 AS col1 FROM tab1 AS cor0
----
-4008
-6312
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7085
SELECT 25 DIV + 59 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7085
SELECT 25 / + 59 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 82 * + 24 + + col2 FROM tab1 AS cor0
----
-1872
-1911
-1914

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 cor0, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to f94a4a64ac54a61fc21f78e2b831ebee

query I rowsort
SELECT - 85 FROM tab1, tab0 AS cor0
----
9 values hashing to 8ebc8ffafb1517ea04e3a6fc4059d88a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7089
SELECT DISTINCT - col1 + ( col2 ) DIV + ( 80 * + col2 ) FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-7089
SELECT DISTINCT - col1 + ( col2 ) / + ( 80 * + col2 ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + ( col0 + col2 ) * tab1.col1 FROM tab1
----
1210
1482
2288

query I rowsort
SELECT + cor0.col2 - + col0 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-7092
SELECT ALL col1 DIV + cor0.col1 - + col0 * col2 AS col2 FROM tab0 AS cor0
----
-34
-7297
-791

skipif mysql # not compatible
query I rowsort label-7092
SELECT ALL col1 / + cor0.col1 - + col0 * col2 AS col2 FROM tab0 AS cor0
----
-34
-7297
-791

query I rowsort
SELECT - - col0 * cor0.col2 + col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT - ( + 31 ) * cor0.col1 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 9b2182fe30f9049d8dcd205490f55de4

query I rowsort
SELECT ALL col0 - - col0 * + col2 * + 58 FROM tab1
----
211648
445520
9399

query I rowsort
SELECT ALL - 13 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

query I rowsort
SELECT ALL - ( - col2 ) * - ( col1 ) AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL col2 * - col0 - ( - col2 ) FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - cor0.col0 * + cor0.col2 * 58 FROM tab0 AS cor0
----
-2030
-423284
-45936

query I rowsort
SELECT + 44 * + col1 - - cor0.col0 FROM tab0 AS cor0
----
3808
4093
4303

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
26
27
38

query I rowsort
SELECT DISTINCT ( col1 + col1 ) AS col0 FROM tab1
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7103
SELECT + col0 + col1 * + CAST( - col2 AS SIGNED ) FROM tab0 AS cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort label-7103
SELECT + col0 + col1 * + CAST ( - col2 AS INTEGER ) FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT tab0.col2 + - col2 * + col2 FROM tab0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT + col0 + - col2 + ( 28 * + col1 ) AS col2 FROM tab2
----
1704
517
848

query I rowsort
SELECT DISTINCT 38 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
38

query I rowsort
SELECT ALL cor0.col2 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL - ( tab1.col1 ) * - 10 + - col0 AS col0 FROM tab1
----
257
36
50

query I rowsort
SELECT DISTINCT + 59 + col2 AS col2 FROM tab2
----
85
86
97

query I rowsort
SELECT DISTINCT col2 * + col2 + - 39 * - col1 FROM tab2 AS cor0
----
1938
2107
2977

query I rowsort
SELECT + col2 * - col1 + + ( - col0 ) FROM tab0 cor0
----
-132
-2862
-7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col0 + - col0 col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT - cor0.col0 - col1 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + cor0.col2 - col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - 7 + col2 * - 68 AS col0 FROM tab2 AS cor0
----
-1775
-1843
-2591

onlyif mysql # use DIV operator for integer division
query I rowsort label-7116
SELECT 37 DIV - col2 col2 FROM tab0
----
-1
-37
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7116
SELECT 37 / - col2 col2 FROM tab0
----
-1
-37
0

query I rowsort
SELECT - ( - col1 ) * + 28 FROM tab0
----
2408
2548
2716

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7118
SELECT CAST( NULL AS DECIMAL ) * 64 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-7118
SELECT CAST ( NULL AS REAL ) * 64 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * col2 - col0 FROM tab2
----
1365
598
722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - + tab1.col2 col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL + col1 * + col0 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT + col1 + + 5 * + col0 * col0 FROM tab0
----
2966
39696
6222

onlyif mysql # use DIV operator for integer division
query I rowsort label-7123
SELECT DISTINCT col1 DIV 82 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-7123
SELECT DISTINCT col1 / 82 FROM tab0
----
1

query I rowsort
SELECT DISTINCT - cor0.col0 * 82 AS col2 FROM tab2 AS cor0
----
-574
-6396
-6478

query I rowsort
SELECT ALL - 60 * col0 + col0 AS col2 FROM tab0 AS cor0
----
-1416
-2065
-5251

onlyif mysql # use DIV operator for integer division
query I rowsort label-7126
SELECT DISTINCT - cor0.col1 + col1 DIV + col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7126
SELECT DISTINCT - cor0.col1 + col1 / + col2 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7127
SELECT DISTINCT col2 * col1 + col0 - + 61 DIV 94 col2 FROM tab0 AS cor0
----
132
2862
7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7127
SELECT DISTINCT col2 * col1 + col0 - + 61 / 94 col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT cor0.col0 * - 23 + col0 FROM tab2 AS cor0
----
-154
-1716
-1738

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7129
SELECT ALL CAST( NULL AS SIGNED ) - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7129
SELECT ALL CAST ( NULL AS INTEGER ) - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + col2 col2 FROM tab1 cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + cor0.col2 + cor0.col2 * + 16 + - col2 col1 FROM tab2 AS cor0
----
-1144
-432
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7132
SELECT + CAST( - col2 AS SIGNED ) * + col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-7132
SELECT + CAST ( - col2 AS INTEGER ) * + col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL col0 + cor0.col2 + col0 AS col2 FROM tab0 AS cor0
----
260
71
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-7134
SELECT DISTINCT cor0.col0 * + 60 + col1 * col2 DIV 30 AS col1 FROM tab2 AS cor0
----
447
4731
4761

skipif mysql # not compatible
query I rowsort label-7134
SELECT DISTINCT cor0.col0 * + 60 + col1 * col2 / 30 AS col1 FROM tab2 AS cor0
----
447
4731
4761

query I rowsort
SELECT - 69 + 9 + + col0 * - cor0.col0 FROM tab1 AS cor0
----
-4156
-6460
-69

query I rowsort
SELECT DISTINCT + 79 AS col1 FROM tab1, tab2 AS cor0
----
79

query I rowsort
SELECT DISTINCT - ( tab0.col1 ) FROM tab0, tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT - col0 * + 6 + 48 AS col1 FROM tab0
----
-162
-486
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7139
SELECT - CAST( NULL AS DECIMAL ) * + 82 AS col2 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7139
SELECT - CAST ( NULL AS REAL ) * + 82 AS col2 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7140
SELECT + CAST( 72 AS SIGNED ) DIV + col2 AS col1 FROM tab0 AS cor0
----
0
2
72

skipif mysql # not compatible
query I rowsort label-7140
SELECT + CAST ( 72 AS INTEGER ) / + col2 AS col1 FROM tab0 AS cor0
----
0
2
72

query I rowsort
SELECT + 7 + col0 AS col2 FROM tab1
----
10
71
87

query I rowsort
SELECT ALL - 20 * 17 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to d5faacaa1e54ca1fddf15365f9396fb3

query I rowsort
SELECT - 34 + - col1 * - 50 AS col2 FROM tab0
----
4266
4516
4816

query I rowsort
SELECT col0 * - tab1.col2 AS col1 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT col1 + + 17 FROM tab1 cor0
----
27
30
43

query I rowsort
SELECT ALL - col1 * - col1 + tab1.col2 * + 78 FROM tab1
----
4546
4888
7657

query I rowsort
SELECT - 83 * col1 FROM tab2
----
-1411
-2573
-4897

query I rowsort
SELECT DISTINCT - col1 - - col0 FROM tab0 cor0
----
-2
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 - - 16 col0 FROM tab2 cor0
----
1359
233
4618

query I rowsort
SELECT ALL cor0.col0 * + col1 + - col2 AS col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT col0 - - col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT ALL ( + tab2.col1 + col0 ) FROM tab2
----
137
38
96

query I rowsort
SELECT ALL + + cor0.col1 * ( + cor0.col0 ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + cor0.col1 + col1 + + 47 AS col0 FROM tab0 AS cor0
----
219
229
241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7155
SELECT col2 + - CAST( NULL AS SIGNED ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7155
SELECT col2 + - CAST ( NULL AS INTEGER ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - cor0.col0 + + col1 + 19 FROM tab0 cor0
----
21
81
81

query I rowsort
SELECT - cor0.col0 * 34 + - col2 + col1 FROM tab0 cor0
----
-1094
-3017
-763

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT cor0.col2 + CAST ( col0 AS REAL ) col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - + col2 - + col0 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7160
SELECT col1 + + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7160
SELECT col1 + + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + - 7 AS col2 FROM tab2 AS cor0
----
19
20
31

query I rowsort
SELECT - cor0.col0 * ( + cor0.col1 ) + - cor0.col1 * ( 76 + col0 * + col2 ) FROM tab0 AS cor0
----
-14162
-679133
-76712

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7163
SELECT ALL - col2 * CAST( + col1 AS SIGNED ) - col0 * + col0 AS col0 FROM tab0
----
-1322
-15383
-3414

skipif mysql # not compatible
query I rowsort label-7163
SELECT ALL - col2 * CAST ( + col1 AS INTEGER ) - col0 * + col0 AS col0 FROM tab0
----
-1322
-15383
-3414

query I rowsort
SELECT - col0 - + col2 AS col1 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT 36 + col2 AS col0 FROM tab2 AS cor0
----
62
63
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-7166
SELECT DISTINCT - ( + cor0.col2 ) + col2 DIV - col1 AS col2 FROM tab1 cor0
----
-103
-56
-62

skipif mysql # not compatible
query I rowsort label-7166
SELECT DISTINCT - ( + cor0.col2 ) + col2 / - col1 AS col2 FROM tab1 cor0
----
-103
-56
-62

query I rowsort
SELECT ALL + col1 + + col1 + + col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT DISTINCT + + ( col1 ) * col2 + + col2 AS col0 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT - 60 + - col1 FROM tab2 AS cor0
----
-119
-77
-91

query I rowsort
SELECT - - 62 * - col0 * - col1 AS col2 FROM tab0 AS cor0
----
127968
210490
502138

query I rowsort
SELECT - + 13 - col2 AS col2 FROM tab0 AS cor0
----
-14
-46
-95

query I rowsort
SELECT DISTINCT + col2 * col1 + col2 * - col1 + - 27 AS col2 FROM tab1 cor0
----
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-7173
SELECT ALL + col2 + col0 DIV + col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7173
SELECT ALL + col2 + col0 / + col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - 64 * ( - col2 ) + - col0 * col1 FROM tab2 AS cor0
----
-2938
1089
1511

query I rowsort
SELECT - - col0 * - col0 + col1 FROM tab0 AS cor0
----
-1128
-490
-7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-7176
SELECT + col2 + + col2 DIV + CAST( 79 AS SIGNED ) FROM tab1 AS cor0
----
54
57
97

skipif mysql # not compatible
query I rowsort label-7176
SELECT + col2 + + col2 / + CAST ( 79 AS INTEGER ) FROM tab1 AS cor0
----
54
57
97

query I rowsort
SELECT DISTINCT col1 + - col0 * ( 88 + col1 ) * - col1 FROM tab1 AS cor0
----
105053
62730
8918

onlyif mysql # use DIV operator for integer division
query I rowsort label-7178
SELECT - ( col0 ) * col2 DIV + col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-7178
SELECT - ( col0 ) * col2 / + col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + 35 * + cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 04fa8aa97a6e2e14eade6aa358239d6b

query I rowsort
SELECT + + col0 - 14 AS col1 FROM tab1 AS cor0
----
-11
50
66

query I rowsort
SELECT ( - 44 + cor0.col0 ) FROM tab1, tab0 AS cor0
----
9 values hashing to d6dbf0a8a3b3d0e172ef55ef1678b39d

query I rowsort
SELECT - ( 18 ) * - cor1.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f3762691e4a423c4281dd8ce8a25a896

query I rowsort
SELECT ALL + col1 * col2 * + col1 FROM tab2
----
10982
25947
90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-7185
SELECT DISTINCT + col2 DIV col0 + - col2 * col1 - + tab2.col1 * + col0 AS col1 FROM tab2
----
-1051
-1989
-6136

skipif mysql # not compatible
query I rowsort label-7185
SELECT DISTINCT + col2 / col0 + - col2 * col1 - + tab2.col1 * + col0 AS col1 FROM tab2
----
-1051
-1989
-6136

query I rowsort
SELECT col1 + + col0 * col2 + + tab0.col1 FROM tab0
----
229
7480
964

onlyif mysql # use DIV operator for integer division
query I rowsort label-7187
SELECT col1 DIV col0 + - col2 * tab0.col2 FROM tab0
----
-1086
-6723
1

skipif mysql # not compatible
query I rowsort label-7187
SELECT col1 / col0 + - col2 * tab0.col2 FROM tab0
----
-1086
-6723
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col0 col1 FROM tab1, tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col1 * + col2 * - col1 + col1 * - col0 + - col1 FROM tab1
----
-17277
-36608
-6350

query I rowsort
SELECT DISTINCT col0 * col1 - col2 FROM tab1
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-7191
SELECT DISTINCT + col0 + - col1 DIV col2 FROM tab0 cor0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-7191
SELECT DISTINCT + col0 + - col1 / col2 FROM tab0 cor0
----
-62
22
88

query I rowsort
SELECT col2 * + col2 + col1 AS col1 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT DISTINCT + cor0.col0 * - col1 * cor0.col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT + col0 + col2 + - cor0.col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + col1 * col1 + col1 * + col1 FROM tab1 cor0
----
1352
200
338

query I rowsort
SELECT ALL + col1 - col0 AS col0 FROM tab0
----
2
62
62

query I rowsort
SELECT DISTINCT - tab0.col1 - col0 AS col0 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT ALL col0 - col1 * - col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL + col2 * col0 - col0 FROM tab1
----
159
3584
7600

query I rowsort
SELECT ALL col0 * - col1 + - col2 AS col1 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT ALL col0 + - col1 + col0 * col2 AS col0 FROM tab2
----
165
2047
3064

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 + col0 * - col1 + col0 col2 FROM tab1
----
-4672
-7360
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-7203
SELECT ALL - col0 + col1 DIV col1 AS col1 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-7203
SELECT ALL - col0 + col1 / col1 AS col1 FROM tab1 AS cor0
----
-2
-63
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7204
SELECT + - col2 DIV col1 + col1 * col1 AS col2 FROM tab1 AS cor0
----
162
674
95

skipif mysql # not compatible
query I rowsort label-7204
SELECT + - col2 / col1 + col1 * col1 AS col2 FROM tab1 AS cor0
----
162
674
95

query I rowsort
SELECT DISTINCT - col1 + - col0 * + cor0.col0 AS col2 FROM tab0 cor0
----
-1322
-662
-8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-7206
SELECT DISTINCT + - col2 DIV col1 AS col2 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-7206
SELECT DISTINCT + - col2 / col1 AS col2 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT col0 * - col1 - col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT cor0.col0 * - col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - - cor0.col1 * col0 * col2 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL col2 AS col2 FROM tab2 AS cor0 WHERE NULL IN ( col2 + - col2 / + col0 ) OR ( NULL ) <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7211
SELECT - col1 * cor0.col2 + + col2 DIV - col1 + + col0 DIV + col2 FROM tab0 AS cor0
----
-2838
-62
-7461

skipif mysql # not compatible
query I rowsort label-7211
SELECT - col1 * cor0.col2 + + col2 / - col1 + + col0 / + col2 FROM tab0 AS cor0
----
-2838
-62
-7461

query I rowsort
SELECT DISTINCT cor0.col2 + + cor0.col1 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT - col2 * col2 * col2 AS col2 FROM tab2 AS cor0
----
-17576
-19683
-54872

query I rowsort
SELECT + + cor0.col2 + cor1.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c2f36d52ae4f05bff875d8467d8b2161

query I rowsort
SELECT ALL ( + tab1.col2 ) FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
7
78
79

query I rowsort
SELECT - col1 + col1 * col1 * col0 FROM tab1 cor0
----
13507
2002
6390

query I rowsort
SELECT - col2 + + col0 * + col0 * + col1 FROM tab1 AS cor0
----
180
40903
83104

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * cor0.col0 col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-7220
SELECT ALL col0 DIV + col0 + + col0 DIV col2 AS col0 FROM tab0 AS cor0
----
1
2
36

skipif mysql # not compatible
query I rowsort label-7220
SELECT ALL col0 / + col0 + + col0 / col2 AS col0 FROM tab0 AS cor0
----
1
2
36

query I rowsort
SELECT ALL - + col0 * col2 + - col0 - col2 * + col2 FROM tab0 AS cor0
----
-14111
-1905
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-7222
SELECT DISTINCT - col1 + - col2 - col1 DIV + col1 FROM tab0 AS cor0
----
-120
-174
-99

skipif mysql # not compatible
query I rowsort label-7222
SELECT DISTINCT - col1 + - col2 - col1 / + col1 FROM tab0 AS cor0
----
-120
-174
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col1 + cor0.col2 col1 FROM tab1 AS cor0
----
-43
-622
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-7224
SELECT ALL - cor0.col0 + col1 DIV + cor0.col0 AS col0 FROM tab0 cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-7224
SELECT ALL - cor0.col0 + col1 / + cor0.col0 AS col0 FROM tab0 cor0
----
-21
-33
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-7225
SELECT DISTINCT - col1 DIV + col2 + + col0 col1 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7225
SELECT DISTINCT - col1 / + col2 + + col0 col1 FROM tab1 AS cor0
----
3
64
80

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( NULL ) <= + col2
----

query I rowsort
SELECT DISTINCT col0 + - col2 FROM tab0 WHERE NOT NULL IN ( + tab0.col0 * col2 + col1 )
----

query I rowsort
SELECT DISTINCT - col1 * - col0 + col1 * col2 AS col1 FROM tab0 WHERE NOT col2 IN ( + col2 )
----

query I rowsort
SELECT DISTINCT - 82 * + col2 AS col2 FROM tab2 AS cor0
----
-2132
-2214
-3116

query III rowsort
SELECT * FROM tab0 WHERE NOT ( + col2 ) BETWEEN + col1 * - col2 AND ( NULL )
----

query I rowsort
SELECT tab0.col1 + col1 AS col2 FROM tab0
----
172
182
194

query I rowsort
SELECT ALL + col0 + col0 * - col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT col0 * col1 + - col2 FROM tab0 cor0
----
2031
3394
8017

query IIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0 WHERE NULL NOT BETWEEN NULL AND ( NULL )
----

query III rowsort
SELECT * FROM tab2 cor0 WHERE NOT NULL NOT IN ( + col2 + - col2 )
----

query I rowsort
SELECT DISTINCT col1 + + col0 + + col2 * col1 * + col0 FROM tab2
----
119789
51130
5897

onlyif mysql # use DIV operator for integer division
query I rowsort label-7237
SELECT - col2 DIV col0 + - col1 FROM tab1
----
-10
-14
-44

skipif mysql # not compatible
query I rowsort label-7237
SELECT - col2 / col0 + - col1 FROM tab1
----
-10
-14
-44

query I rowsort
SELECT DISTINCT + col2 + - col2 + col0 * - col1 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 col0 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT - col0 * + col0 * - col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT col0 FROM tab0 WHERE NOT col0 IN ( - col0 )
----
24
35
89

query I rowsort
SELECT tab1.col0 FROM tab1 WHERE NOT ( NULL ) >= NULL
----

query I rowsort
SELECT col2 + - col2 + + col2 FROM tab0
----
1
33
82

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( col2 * - col1 * col1 ) NOT IN ( col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col2 + col0 - - tab0.col2 AS col2 FROM tab0
----
253
37
90

query I rowsort
SELECT + col1 * col0 + + tab0.col0 FROM tab0
----
2088
3430
8188

query III rowsort
SELECT * FROM tab2 WHERE NOT col0 * col2 IN ( + col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT + col2 FROM tab0 WHERE NOT col2 * - col2 / col2 = NULL
----

query I rowsort
SELECT ALL col0 + col2 * col2 AS col1 FROM tab2
----
1523
736
754

query I rowsort
SELECT col2 * tab0.col0 + - col1 * - col2 AS col2 FROM tab0
----
132
14760
3630

query I rowsort
SELECT 72 * - col1 * col1 FROM tab1 AS cor0
----
-12168
-48672
-7200

query I rowsort
SELECT col2 * cor0.col1 FROM tab2 cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * - ( - 7 + cor0.col0 ) * 5 col2 FROM tab1 AS cor0
----
-520
2850
4745

query I rowsort
SELECT - cor0.col1 * 78 + + col2 + - col1 * col2 AS col0 FROM tab1 AS cor0
----
-1293
-2166
-3378

query I rowsort
SELECT - cor0.col2 * - 56 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to dc8adb5a22835a3499bc74e2304fbcb9

query I rowsort
SELECT + tab0.col2 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7257
SELECT - CAST( NULL AS SIGNED ) + - col1 * - col1 * 9 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7257
SELECT - CAST ( NULL AS INTEGER ) + - col1 * - col1 * 9 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * col0 + + 91 * + col0 * 2 AS col2 FROM tab1
----
384
6880
8000

query I rowsort
SELECT - cor0.col0 * 50 FROM tab0 AS cor0
----
-1200
-1750
-4450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( 92 ) col0 FROM tab1 cor0
----
-92
-92
-92

query I rowsort
SELECT col2 + 35 * col2 FROM tab0
----
1188
2952
36

query I rowsort
SELECT ( tab1.col2 ) AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL + 11 + tab1.col0 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 1dd16a424f474ddb6de21fafc3f7d79c

query I rowsort
SELECT ALL 88 * - 37 FROM tab1
----
-3256
-3256
-3256

query I rowsort
SELECT ALL - tab0.col1 + ( - tab0.col2 ) FROM tab0
----
-119
-173
-98

query I rowsort
SELECT + ( col0 ) * - cor0.col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col2 + 66 * - col2 AS col1 FROM tab1 AS cor0
----
-3510
-3705
-6240

query I rowsort
SELECT ALL + col0 + 40 AS col1 FROM tab0 AS cor0
----
129
64
75

query I rowsort
SELECT col1 * col1 * + col1 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT ALL - + col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + - col2 * cor0.col1 + + col0 * col0 FROM tab2 AS cor0
----
-788
4550
5595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7272
SELECT DISTINCT cor0.col2 * - col1 * CAST( + col2 AS SIGNED ) - - col1 FROM tab2 AS cor0
----
-22568
-24531
-39825

skipif mysql # not compatible
query I rowsort label-7272
SELECT DISTINCT cor0.col2 * - col1 * CAST ( + col2 AS INTEGER ) - - col1 FROM tab2 AS cor0
----
-22568
-24531
-39825

query I rowsort
SELECT + col1 + + col2 * tab2.col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT 33 * col2 + - 61 FROM tab1 AS cor0
----
1721
1820
3107

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col2 + + col1 col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - col2 + - col0 AS col1 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT col0 - + col2 * - col0 AS col0 FROM tab1
----
165
3712
7760

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 cor0, tab1, tab1 cor1
----
972 values hashing to 635619591835474e6aa6acdff4ab166c

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - - col2 - - col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7281
SELECT DISTINCT col1 * + cor0.col2 - + 0 DIV + col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-7281
SELECT DISTINCT col1 * + cor0.col2 - + 0 / + col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-7283
SELECT ALL col2 DIV + col0 + + col1 * 96 AS col0 FROM tab2 AS cor0
----
1632
2979
5664

skipif mysql # not compatible
query I rowsort label-7283
SELECT ALL col2 / + col0 + + col1 * 96 AS col0 FROM tab2 AS cor0
----
1632
2979
5664

query I rowsort
SELECT col2 * + col0 + + ( col1 ) FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-7285
SELECT ALL 98 * + col2 + 70 DIV 85 FROM tab0 AS cor0
----
3234
8036
98

skipif mysql # not compatible
query I rowsort label-7285
SELECT ALL 98 * + col2 + 70 / 85 FROM tab0 AS cor0
----
3234
8036
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7286
SELECT + - col2 + ( + col2 ) * col1 DIV 47 + col1 FROM tab2 cor0
----
-8
21
65

skipif mysql # not compatible
query I rowsort label-7286
SELECT + - col2 + ( + col2 ) * col1 / 47 + col1 FROM tab2 cor0
----
-8
21
65

query I rowsort
SELECT cor0.col0 * col2 + col2 + col1 FROM tab1 AS cor0
----
242
3715
7789

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7288
SELECT - col0 * CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7288
SELECT - col0 * CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 6 + cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 039a5a2cf4fe53aa7312d55832b7ebd4

query I rowsort
SELECT 30 + - col2 FROM tab1 AS cor0
----
-24
-27
-66

query I rowsort
SELECT ALL - 59 + - 69 * - col0 AS col0 FROM tab0 AS cor0
----
1597
2356
6082

query I rowsort
SELECT - cor0.col0 * + 1 + 56 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 3b8b15d6cbac7e4904fb1559ed1b9e55

query I rowsort
SELECT 50 FROM tab2 cor0
----
50
50
50

query I rowsort
SELECT + ( col2 ) + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL 74 - cor0.col0 FROM tab2 AS cor0
----
-4
-5
67

query I rowsort
SELECT ALL + cor0.col0 * - col2 FROM tab1 cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - 93 col1 FROM tab1 AS cor0
----
-13
-29
-90

query I rowsort
SELECT DISTINCT + - cor0.col1 + - ( + col1 ) AS col2 FROM tab0 cor0
----
-172
-182
-194

query I rowsort
SELECT - col0 * - ( - cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT + col1 + - col2 * - ( + col1 ) FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL col0 * col2 * + ( col2 ) FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT - col1 * - col2 + tab0.col2 AS col0 FROM tab0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7303
SELECT - col0 DIV ( col2 + + col2 * + 21 ) AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7303
SELECT - col0 / ( col2 + + col2 * + 21 ) AS col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL col1 * + 52 FROM tab1 AS cor0
----
1352
520
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + cor0.col1 + col1 col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL - col0 * - cor0.col0 * + col2 FROM tab0 AS cor0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col0 * 12 + + 12 col2 FROM tab1
----
48
780
972

query I rowsort
SELECT 81 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7309
SELECT col2 + CAST( col2 AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
2871
7544
98

skipif mysql # not compatible
query I rowsort label-7309
SELECT col2 + CAST ( col2 AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - col1 * + 38 + + 75 FROM tab1 AS cor0
----
-305
-419
-913

query I rowsort
SELECT ALL - col2 + 42 FROM tab0 AS cor0
----
-40
41
9

query I rowsort
SELECT + + cor0.col0 * - col0 FROM tab1 cor0
----
-4096
-6400
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * cor0.col2 col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - 76 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-76

query I rowsort
SELECT + 32 * + cor0.col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b021124a67f03bd690bf85089039c654

query I rowsort
SELECT tab2.col0 * - 46 AS col0 FROM tab2
----
-322
-3588
-3634

query I rowsort
SELECT - col0 * - 31 FROM tab1
----
1984
2480
93

query I rowsort
SELECT ALL + 9 + + cor0.col2 FROM tab0 AS cor0
----
10
42
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-7319
SELECT DISTINCT + col1 - + col0 * ( col2 ) DIV - cor0.col2 FROM tab0 cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-7319
SELECT DISTINCT + col1 - + col0 * ( col2 ) / - cor0.col2 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT 41 + cor0.col2 FROM tab0 AS cor0
----
123
42
74

query I rowsort
SELECT ALL col1 * col0 * tab0.col1 + + 94 AS col2 FROM tab0
----
177598
329409
737103

query I rowsort
SELECT DISTINCT 69 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
69

query I rowsort
SELECT ALL + col1 * + col1 + tab2.col1 FROM tab2
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-7324
SELECT - col1 DIV col2 + col1 AS col0 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7324
SELECT - col1 / col2 + col1 AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT + col1 - col2 AS col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT + + 41 * + col1 FROM tab1 AS cor0
----
1066
410
533

query I rowsort
SELECT DISTINCT + 93 + col2 FROM tab1 AS cor0
----
147
150
189

onlyif mysql # use DIV operator for integer division
query I rowsort label-7328
SELECT DISTINCT cor0.col1 DIV + col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-7328
SELECT DISTINCT cor0.col1 / + col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL - cor0.col2 + + col2 * + 67 * - cor0.col2 AS col1 FROM tab0 cor0
----
-450590
-68
-72996

query I rowsort
SELECT DISTINCT + 7 + - col2 + 3 AS col2 FROM tab0 AS cor0
----
-23
-72
9

query I rowsort
SELECT ALL - col1 + + col2 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - + col2 * - col0 + - cor0.col0 * - cor0.col0 FROM tab0 AS cor0
----
1260
1368
15219

query I rowsort
SELECT DISTINCT col1 - col1 * - 67 FROM tab2 AS cor0
----
1156
2108
4012

onlyif mysql # use DIV operator for integer division
query I rowsort label-7334
SELECT DISTINCT col2 DIV col0 + + col2 * col0 FROM tab2 AS cor0
----
192
2028
3002

skipif mysql # not compatible
query I rowsort label-7334
SELECT DISTINCT col2 / col0 + + col2 * col0 FROM tab2 AS cor0
----
192
2028
3002

query I rowsort
SELECT ALL + + col2 + + cor0.col0 * + col2 * col0 AS col2 FROM tab2 AS cor0
----
1350
158210
237196

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7336
SELECT DISTINCT + CAST( 4 AS SIGNED ) col0 FROM tab1, tab1 AS cor0
----
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7336
SELECT DISTINCT + CAST ( 4 AS INTEGER ) col0 FROM tab1, tab1 AS cor0
----
4

query I rowsort
SELECT col1 * 42 FROM tab0 AS cor0
----
3612
3822
4074

onlyif mysql # use DIV operator for integer division
query I rowsort label-7338
SELECT - col1 * + ( cor0.col1 ) DIV col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-7338
SELECT - col1 * + ( cor0.col1 ) / col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT 31 FROM tab2, tab1 AS cor0
----
31

query I rowsort
SELECT ( - 22 ) FROM tab0, tab2 AS cor0
----
9 values hashing to fae46f8148b02964f7145eb6ed5819f9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col2 - col1 col0 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT + cor0.col2 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT + col2 * - 13 AS col0 FROM tab1 AS cor0
----
-1248
-702
-741

query I rowsort
SELECT - col1 + - col1 * + col1 AS col1 FROM tab1 AS cor0
----
-110
-182
-702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7345
SELECT 68 + col0 + + col0 / + CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7345
SELECT 68 + col0 + + col0 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + tab2.col2 * col2 FROM tab2
----
1461
735
760

query I rowsort
SELECT ( col0 ) + + col2 AS col1 FROM tab0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7348
SELECT DISTINCT 71 DIV - cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7348
SELECT DISTINCT 71 / - cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * tab1.col0 col2 FROM tab1
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7350
SELECT CAST( NULL AS SIGNED ) / + col1 + + col2 - col0 / 23 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7350
SELECT CAST ( NULL AS INTEGER ) / + col1 + + col2 - col0 / 23 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 98 * col1 * + col2 AS col1 FROM tab2 AS cor0
----
150332
63308
82026

query I rowsort
SELECT ALL + 81 + col1 AS col2 FROM tab2 AS cor0
----
112
140
98

query I rowsort
SELECT DISTINCT - 84 * col1 AS col2 FROM tab0 AS cor0
----
-7224
-7644
-8148

query I rowsort
SELECT 10 + col1 FROM tab2 AS cor0
----
27
41
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-7355
SELECT DISTINCT - - col1 + - cor0.col1 * - col0 DIV col0 AS col0 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-7355
SELECT DISTINCT - - col1 + - cor0.col1 * - col0 / col0 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + col1 * col2 * cor0.col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT 97 * - col0 + + col0 FROM tab1
----
-288
-6144
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7358
SELECT CAST( NULL AS SIGNED ) * + col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7358
SELECT CAST ( NULL AS INTEGER ) * + col1 AS col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7359
SELECT - CAST( NULL AS DECIMAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7359
SELECT - CAST ( NULL AS REAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( - 82 ) + col0 FROM tab0
----
106
117
171

query I rowsort
SELECT ( + col1 * col1 ) + 59 FROM tab1
----
159
228
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-7362
SELECT 44 DIV + col1 + + col1 * col0 * col1 + - tab2.col1 AS col2 FROM tab2
----
22816
271459
6697

skipif mysql # not compatible
query I rowsort label-7362
SELECT 44 / + col1 + + col1 * col0 * col1 + - tab2.col1 AS col2 FROM tab2
----
22816
271459
6697

query I rowsort
SELECT + 13 FROM tab0, tab0 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT col2 * + col0 AS col1 FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col0 ) + + col0 col1 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7366
SELECT ALL col0 + + cor0.col2 * - col1 * CAST( col0 AS SIGNED ) AS col2 FROM tab0 cor0
----
-3360
-664029
-68088

skipif mysql # not compatible
query I rowsort label-7366
SELECT ALL col0 + + cor0.col2 * - col1 * CAST ( col0 AS INTEGER ) AS col2 FROM tab0 cor0
----
-3360
-664029
-68088

onlyif mysql # use DIV operator for integer division
query I rowsort label-7367
SELECT - col1 DIV - col1 + - col0 * col0 FROM tab1 cor0
----
-4095
-6399
-8

skipif mysql # not compatible
query I rowsort label-7367
SELECT - col1 / - col1 + - col0 * col0 FROM tab1 cor0
----
-4095
-6399
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7368
SELECT - cor0.col0 + - CAST( + 51 AS SIGNED ) FROM tab2, tab1 cor0
----
9 values hashing to 674494f13e541ec2834a7dfe1c6d00e1

skipif mysql # not compatible
query I rowsort label-7368
SELECT - cor0.col0 + - CAST ( + 51 AS INTEGER ) FROM tab2, tab1 cor0
----
9 values hashing to 674494f13e541ec2834a7dfe1c6d00e1

query I rowsort
SELECT DISTINCT ( + 22 ) FROM tab0, tab2 AS cor0
----
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-7370
SELECT + 1 + + col1 + ( + cor0.col1 ) * - col1 DIV col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7370
SELECT + 1 + + col1 + ( + cor0.col1 ) * - col1 / col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + 4 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

query I rowsort
SELECT + cor0.col1 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT col0 + + col0 * col2 FROM tab0 cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-7374
SELECT DISTINCT - col2 * col1 DIV 87 AS col2 FROM tab0
----
-1
-32
-85

skipif mysql # not compatible
query I rowsort label-7374
SELECT DISTINCT - col2 * col1 / 87 AS col2 FROM tab0
----
-1
-32
-85

query I rowsort
SELECT ALL + ( - 35 ) * cor0.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 17f5eca9d4d632167d9b17b94d4bee66

onlyif mysql # use DIV operator for integer division
query I rowsort label-7376
SELECT DISTINCT tab0.col1 DIV tab0.col0 AS col2 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-7376
SELECT DISTINCT tab0.col1 / tab0.col0 AS col2 FROM tab0
----
1
2
3

query I rowsort
SELECT DISTINCT + tab1.col2 * - ( + ( col2 ) ) FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT + col2 * col1 + + col2 FROM tab0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7379
SELECT - col0 + - col2 DIV tab2.col1 FROM tab2
----
-7
-78
-81

skipif mysql # not compatible
query I rowsort label-7379
SELECT - col0 + - col2 / tab2.col1 FROM tab2
----
-7
-78
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + 62 + - ( + tab2.col1 ) * 84 col0 FROM tab2
----
-120
-2170
3470

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7381
SELECT CAST( NULL AS SIGNED ) * cor0.col1 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7381
SELECT CAST ( NULL AS INTEGER ) * cor0.col1 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT 48 * 87 AS col1 FROM tab0
----
4176
4176
4176

query I rowsort
SELECT + col1 * 67 FROM tab1
----
1742
670
871

onlyif mysql # use DIV operator for integer division
query I rowsort label-7384
SELECT - 94 DIV - col0 AS col0 FROM tab2
----
1
1
13

skipif mysql # not compatible
query I rowsort label-7384
SELECT - 94 / - col0 AS col0 FROM tab2
----
1
1
13

query I rowsort
SELECT 8 * + 71 * - col1 FROM tab1
----
-14768
-5680
-7384

query I rowsort
SELECT + - col0 * + col2 + + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT ( + col0 ) + 21 FROM tab1 AS cor0
----
101
24
85

query I rowsort
SELECT - 7 * col2 + - 95 AS col1 FROM tab0 AS cor0
----
-102
-326
-669

query I rowsort
SELECT ALL + col1 * - col2 - + col0 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT tab2.col0 * 22 AS col2 FROM tab2
----
154
1716
1738

query I rowsort
SELECT ALL col1 - + tab1.col1 * + tab1.col0 * col1 FROM tab1
----
-13507
-2002
-6390

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7392
SELECT DISTINCT CAST( + col2 AS SIGNED ) - - col0 * tab0.col2 FROM tab0
----
36
7380
825

skipif mysql # not compatible
query I rowsort label-7392
SELECT DISTINCT CAST ( + col2 AS INTEGER ) - - col0 * tab0.col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT ALL + ( - cor0.col0 ) * - cor1.col2 - - 69 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 37a847a9f5503e61b6f00161ea4c95ee

query I rowsort
SELECT DISTINCT - ( - cor0.col1 ) - + cor0.col2 * 62 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-3322
-3524
-5939

onlyif mysql # use DIV operator for integer division
query I rowsort label-7395
SELECT + col0 DIV + col0 + 43 FROM tab1 cor0
----
44
44
44

skipif mysql # not compatible
query I rowsort label-7395
SELECT + col0 / + col0 + 43 FROM tab1 cor0
----
44
44
44

query I rowsort
SELECT + 6 + col2 FROM tab2 AS cor0
----
32
33
44

query I rowsort
SELECT ALL - cor0.col0 + + col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + ( col2 ) + + col1 FROM tab0
----
119
173
98

query I rowsort
SELECT - col1 + + 55 AS col0 FROM tab1
----
29
42
45

query I rowsort
SELECT DISTINCT col1 + ( col0 ) * - col1 + - 68 * - col2 FROM tab0 AS cor0
----
-2432
-3230
266

query I rowsort
SELECT 89 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT - - col0 * col0 + - col2 + - 73 AS col2 FROM tab0 AS cor0
----
1151
470
7766

query I rowsort
SELECT DISTINCT - + ( - ( col0 ) ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + - 96 + ( col0 ) * col0 FROM tab2 AS cor0
----
-47
5988
6145

query I rowsort
SELECT ALL + 37 + - col0 + col0 FROM tab2 AS cor0
----
37
37
37

query I rowsort
SELECT ALL col2 * - ( + cor0.col1 ) FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - + col1 + cor0.col2 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + cor0.col0 + + col1 * col2 FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT + cor0.col2 + col0 * ( 78 ) AS col2 FROM tab0 AS cor0
----
1905
2731
7024

query I rowsort
SELECT DISTINCT - 46 + - col1 * 38 + col1 * + col2 FROM tab1 AS cor0
----
144
370
708

query I rowsort
SELECT ALL - 70 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-80
-83
-96

query I rowsort
SELECT ALL - cor0.col2 * - col1 - - 5 FROM tab0 AS cor0
----
102
2843
7467

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7413
SELECT DISTINCT - ( col2 ) * - CAST( NULL AS SIGNED ) + col1 * col0 AS col2 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7413
SELECT DISTINCT - ( col2 ) * - CAST ( NULL AS INTEGER ) + col1 * col0 AS col2 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT 77 * + col1 + col1 FROM tab2 cor0
----
1326
2418
4602

query I rowsort
SELECT - 25 + + col0 FROM tab0 AS cor0
----
-1
10
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-7416
SELECT ALL + + col0 + + col2 DIV col1 - col2 col2 FROM tab1 AS cor0
----
-49
-9
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7416
SELECT ALL + + col0 + + col2 / col1 - col2 col2 FROM tab1 AS cor0
----
-49
-9
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7417
SELECT + col1 * col1 / col2 + - CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7417
SELECT + col1 * col1 / col2 + - CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 80 + - col2 * + col1 AS col0 FROM tab0
----
-17
-2758
-7382

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col0 col1 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-7420
SELECT ALL + - col2 DIV cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7420
SELECT ALL + - col2 / cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col1 * - col0 + cor0.col1 + - col1 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-7422
SELECT ALL col0 - + col2 DIV 99 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-7422
SELECT ALL col0 - + col2 / 99 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7423
SELECT DISTINCT - col1 + cor0.col0 DIV + cor0.col1 FROM tab1 AS cor0
----
-26
-4
-7

skipif mysql # not compatible
query I rowsort label-7423
SELECT DISTINCT - col1 + cor0.col0 / + cor0.col1 FROM tab1 AS cor0
----
-26
-4
-7

query I rowsort
SELECT DISTINCT - cor0.col2 * + ( col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - cor0.col0 * 26 AS col1 FROM tab0 AS cor0
----
-2314
-624
-910

query I rowsort
SELECT ALL col0 * ( + col1 ) AS col2 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7427
SELECT col2 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7427
SELECT col2 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + + ( - ( col0 ) ) * - col1 FROM tab2 cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + tab2.col1 - col1 * - tab2.col2 col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT - cor0.col1 + + col2 * col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT - + col2 * - col2 - - col0 * - col1 AS col2 FROM tab2 AS cor0
----
-3926
101
512

query I rowsort
SELECT col1 * 22 AS col1 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT ALL + cor0.col1 + 29 * - ( + col0 ) AS col1 FROM tab2 AS cor0
----
-172
-2203
-2274

query I rowsort
SELECT - col1 - + col2 * col2 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT DISTINCT - col1 + col1 * - col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ( cor0.col2 ) * + cor0.col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - 22 * + col0 FROM tab0 AS cor0
----
-1958
-528
-770

query I rowsort
SELECT ALL 78 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

onlyif mysql # use DIV operator for integer division
query I rowsort label-7439
SELECT ALL - col0 * col2 + col2 DIV col0 FROM tab0
----
-35
-7298
-791

skipif mysql # not compatible
query I rowsort label-7439
SELECT ALL - col0 * col2 + col2 / col0 FROM tab0
----
-35
-7298
-791

query I rowsort
SELECT + col2 * 10 - col0 FROM tab1
----
506
537
880

query I rowsort
SELECT + cor1.col1 FROM tab2 cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + col0 * 71 AS col0 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT + cor0.col0 + + 83 * + col0 * - col0 FROM tab2 AS cor0
----
-4060
-504894
-517924

query I rowsort
SELECT - 61 + col1 * - col0 FROM tab0 AS cor0
----
-2125
-3456
-8160

query I rowsort
SELECT 29 + cor0.col1 + col0 * - col1 FROM tab1 AS cor0
----
-23
-601
-998

query I rowsort
SELECT + 45 * col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
164160
345600
7290

query I rowsort
SELECT - ( col0 ) + - col2 + ( col2 ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col2 AS REAL ) + - col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + ( + 61 ) + col2 FROM tab0 AS cor0
----
143
62
94

query I rowsort
SELECT DISTINCT + col1 + col1 + 74 FROM tab2
----
108
136
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-7451
SELECT DISTINCT tab0.col0 DIV + col1 + + col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7451
SELECT DISTINCT tab0.col0 / + col1 + + col2 FROM tab0
----
1
33
82

query I rowsort
SELECT - tab0.col2 * - ( tab0.col0 + + col1 ) FROM tab0
----
132
14760
3630

onlyif mysql # use DIV operator for integer division
query I rowsort label-7453
SELECT DISTINCT tab0.col2 DIV tab0.col1 AS col2 FROM tab0, tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7453
SELECT DISTINCT tab0.col2 / tab0.col1 AS col2 FROM tab0, tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7454
SELECT ALL col2 + + col1 DIV - col1 + + tab2.col2 FROM tab2
----
51
53
75

skipif mysql # not compatible
query I rowsort label-7454
SELECT ALL col2 + + col1 / - col1 + + tab2.col2 FROM tab2
----
51
53
75

query I rowsort
SELECT 42 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT ALL - cor0.col1 + col1 * - col2 AS col2 FROM tab2 cor0
----
-1593
-663
-868

query I rowsort
SELECT + - col0 * col2 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-7458
SELECT ALL + cor1.col2 DIV - 61 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-7458
SELECT ALL + cor1.col2 / - 61 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 721682d0719de924079c33bd72eef789

onlyif mysql # use DIV operator for integer division
query I rowsort label-7459
SELECT col2 DIV - col0 + - 66 FROM tab1
----
-66
-67
-84

skipif mysql # not compatible
query I rowsort label-7459
SELECT col2 / - col0 + - 66 FROM tab1
----
-66
-67
-84

query I rowsort
SELECT DISTINCT ( + tab2.col2 + col0 ) * + col2 AS col0 FROM tab2
----
2704
4446
918

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 66 + - col2 col1 FROM tab2 cor0
----
-104
-92
-93

query I rowsort
SELECT ALL 79 * + col0 FROM tab0 AS cor0
----
1896
2765
7031

query I rowsort
SELECT col0 + - col1 * + 20 FROM tab1 AS cor0
----
-136
-180
-517

query I rowsort
SELECT col0 * + 35 AS col2 FROM tab0
----
1225
3115
840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col2 col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + col2 - 47 AS col2 FROM tab1 AS cor0
----
10
49
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 87 col2 FROM tab0, tab2 AS cor0
----
-87

query I rowsort
SELECT DISTINCT col0 * - ( cor0.col0 * + col0 ) AS col0 FROM tab1 AS cor0
----
-262144
-27
-512000

query I rowsort
SELECT ALL + col1 * ( - col1 ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + + col0 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - 18 FROM tab2, tab1 cor0 CROSS JOIN tab0, tab0 AS cor1
----
81 values hashing to 4b8f1109b78a52c6ee572810d1973a42

onlyif mysql # use DIV operator for integer division
query I rowsort label-7472
SELECT col0 * col2 DIV + col2 - col1 AS col0 FROM tab1
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-7472
SELECT col0 * col2 / + col2 - col1 AS col0 FROM tab1
----
-23
54
67

query I rowsort
SELECT 38 + tab2.col1 * - 63 AS col2 FROM tab2
----
-1033
-1915
-3679

query I rowsort
SELECT + col2 + - col2 * col2 AS col1 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT + cor0.col0 * ( + 63 ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to ba45810a663baade9fea50f5266ad33e

query I rowsort
SELECT ALL tab2.col1 * - tab2.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 9b23e5e74ef3405a4dbf05cceb18c8a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7477
SELECT + ( col1 ) + col2 DIV 74 FROM tab1
----
10
14
26

skipif mysql # not compatible
query I rowsort label-7477
SELECT + ( col1 ) + col2 / 74 FROM tab1
----
10
14
26

query I rowsort
SELECT + + 39 * cor0.col2 AS col0 FROM tab1 cor0
----
2106
2223
3744

query I rowsort
SELECT ALL + ( + cor0.col0 ) AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT col2 + + col1 * + 3 FROM tab1 AS cor0
----
132
135
87

query I rowsort
SELECT DISTINCT col2 * 18 - + col1 * - col0 FROM tab0 AS cor0
----
2658
3413
9575

onlyif mysql # use DIV operator for integer division
query I rowsort label-7482
SELECT ALL - - col0 DIV ( cor0.col0 + col0 ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7482
SELECT ALL - - col0 / ( cor0.col0 + col0 ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 60 + - 16 FROM tab1 AS cor0
----
-76
-76
-76

query I rowsort
SELECT - 34 FROM tab0, tab0 AS cor0
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

onlyif mysql # use DIV operator for integer division
query I rowsort label-7485
SELECT col1 DIV + col1 + col1 * - col2 FROM tab0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-7485
SELECT col1 / + col1 + col1 * - col2 FROM tab0
----
-2837
-7461
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7486
SELECT - + col2 + - col2 DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-7486
SELECT - + col2 + - col2 / cor0.col2 AS col2 FROM tab0 AS cor0
----
-2
-34
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7487
SELECT - + CAST( NULL AS DECIMAL ) + 48 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7487
SELECT - + CAST ( NULL AS REAL ) + 48 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 27 + - col1 FROM tab0 AS cor0
----
-59
-64
-70

query I rowsort
SELECT ALL + cor0.col0 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT col2 + - col0 * - col0 + col2 FROM tab1
----
117
4210
6592

query I rowsort
SELECT DISTINCT - col1 * col1 + - col2 FROM tab0
----
-7429
-8363
-9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-7492
SELECT + ( tab1.col1 ) * - col1 DIV - col1 + - tab1.col1 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7492
SELECT + ( tab1.col1 ) * - col1 / - col1 + - tab1.col1 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT 3 FROM tab2, tab1 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT + 78 * - cor0.col2 FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT DISTINCT - 34 * - col1 FROM tab1 cor0
----
340
442
884

query I rowsort
SELECT + - 86 + + col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
1162
1318
484

query I rowsort
SELECT - 87 * + 23 FROM tab2 cor0
----
-2001
-2001
-2001

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col0 FROM tab0, tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + col2 * 65 FROM tab2 AS cor0
----
1690
1755
2470

query I rowsort
SELECT ALL - col1 + col0 * + col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL - - col1 - - col0 * + col2 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - 29 + col0 * col1 FROM tab0 AS cor0
----
2035
3366
8070

query I rowsort
SELECT DISTINCT - 30 + + col2 AS col2 FROM tab0 cor0
----
-29
3
52

query I rowsort
SELECT ALL - 34 * + cor0.col2 + - cor0.col1 FROM tab2 AS cor0
----
-1309
-943
-949

query I rowsort
SELECT DISTINCT 40 + - col0 * col2 FROM tab0 AS cor0
----
-7258
-752
5

query I rowsort
SELECT + 42 * cor0.col2 AS col1 FROM tab2 AS cor0
----
1092
1134
1596

query I rowsort
SELECT DISTINCT - - 87 AS col2 FROM tab2 AS cor0
----
87

query I rowsort
SELECT - - ( + col0 ) + + cor0.col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL 67 + - col0 * col0 FROM tab2 AS cor0
----
-6017
-6174
18

query I rowsort
SELECT DISTINCT - ( col1 ) * - col2 + - col2 + col0 AS col2 FROM tab0
----
131
2829
7469

query I rowsort
SELECT + 57 AS col1 FROM tab0
----
57
57
57

query I rowsort
SELECT + col2 * 21 + col0 FROM tab0 AS cor0
----
1811
56
717

query I rowsort
SELECT ALL - cor0.col2 * - 13 AS col2 FROM tab1 cor0
----
1248
702
741

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7514
SELECT + cor0.col2 + - CAST( + 78 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-21
-24
18

skipif mysql # not compatible
query I rowsort label-7514
SELECT + cor0.col2 + - CAST ( + 78 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-21
-24
18

query I rowsort
SELECT col2 * - 26 - + col0 AS col2 FROM tab0 AS cor0
----
-2221
-61
-882

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 2 col2 FROM tab0
----
-2

query I rowsort
SELECT DISTINCT + 58 AS col1 FROM tab2
----
58

query I rowsort
SELECT col1 + - 19 * + 8 FROM tab1 AS cor0
----
-126
-139
-142

query I rowsort
SELECT ALL + col1 * col2 * - 19 AS col2 FROM tab0 AS cor0
----
-141778
-1843
-53922

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7520
SELECT DISTINCT + cor0.col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7520
SELECT DISTINCT + cor0.col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col0 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT tab2.col0 * col2 + col2 - col1 FROM tab2
----
185
1995
3023

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col1 - - 45 col0 FROM tab2 AS cor0
----
-244
-3436
-916

query I rowsort
SELECT - + col0 + + col1 * 21 FROM tab1 AS cor0
----
146
193
543

query I rowsort
SELECT + col0 + ( - col0 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col0 - col1 * 62 FROM tab2
----
-1915
-3580
-975

query I rowsort
SELECT ALL + 34 + col1 + + col2 AS col0 FROM tab0
----
132
153
207

query I rowsort
SELECT ALL + col0 + - col1 * - tab0.col1 * - 44 AS col2 FROM tab0
----
-325400
-364275
-413961

query I rowsort
SELECT ALL - cor0.col0 + - col1 + + col2 AS col1 FROM tab0 AS cor0
----
-131
-77
-98

query I rowsort
SELECT ALL + - col2 - - cor0.col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 42 col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT DISTINCT + 19 * col2 - - col2 FROM tab0 cor0
----
1640
20
660

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) - + ( col0 ) * cor0.col0 * col2 col0 FROM tab1 AS cor0
----
-233529
-540
-614496

query I rowsort
SELECT ( col0 ) + col1 * col1 AS col2 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT 52 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + ( - col1 + col0 ) col2 FROM tab1 AS cor0
----
-20
118
147

onlyif mysql # use DIV operator for integer division
query I rowsort label-7537
SELECT col0 + + ( - col1 ) DIV - col1 AS col1 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-7537
SELECT col0 + + ( - col1 ) / - col1 AS col1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT DISTINCT - + col0 * 96 + col1 AS col0 FROM tab0 AS cor0
----
-2218
-3263
-8453

query I rowsort
SELECT ALL - cor0.col0 * ( + col2 ) AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - col2 * + ( - 23 * + col0 ) + col1 + col0 * - col2 AS col0 FROM tab1 AS cor0
----
168973
3590
80266

onlyif mysql # use DIV operator for integer division
query I rowsort label-7541
SELECT col1 + - cor0.col2 DIV + col0 AS col2 FROM tab1 AS cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-7541
SELECT col1 + - cor0.col2 / + col0 AS col2 FROM tab1 AS cor0
----
10
12
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7542
SELECT + + col0 * - ( col2 ) + + col1 DIV cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-7542
SELECT + + col0 * - ( col2 ) + + col1 / cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT cor0.col2 * ( + col2 ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + col0 * ( col2 ) AS col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7545
SELECT + cor0.col0 * CAST( col2 AS SIGNED ) + - cor0.col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

skipif mysql # not compatible
query I rowsort label-7545
SELECT + cor0.col0 * CAST ( col2 AS INTEGER ) + - cor0.col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + - 60 * col0 col2 FROM tab0 cor0
----
-1464
-2135
-5429

query I rowsort
SELECT DISTINCT - cor0.col1 + ( col2 + - col0 ) * col0 FROM tab1 AS cor0
----
-458
1267
127

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7548
SELECT ALL - col0 + - CAST( - ( col2 ) AS SIGNED ) * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-165
-3712
-7760

skipif mysql # not compatible
query I rowsort label-7548
SELECT ALL - col0 + - CAST ( - ( col2 ) AS INTEGER ) * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT ALL - col2 + 70 * - col2 * - ( col1 ) AS col0 FROM tab0 AS cor0
----
198627
522258
6789

query I rowsort
SELECT - + ( ( - col0 ) ) * col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL 94 * col0 FROM tab2 AS cor0
----
658
7332
7426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * - 14 * - col0 col1 FROM tab1 AS cor0
----
-1092
-14560
-8960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7553
SELECT - + CAST( + 85 AS SIGNED ) * + col0 FROM tab2 cor0
----
-595
-6630
-6715

skipif mysql # not compatible
query I rowsort label-7553
SELECT - + CAST ( + 85 AS INTEGER ) * + col0 FROM tab2 cor0
----
-595
-6630
-6715

query I rowsort
SELECT DISTINCT 83 - col0 AS col0 FROM tab0 cor0
----
-6
48
59

query I rowsort
SELECT ALL col0 * + 24 - + col0 FROM tab2 AS cor0
----
161
1794
1817

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 38 col1 FROM tab0 AS cor0
----
38
38
38

query I rowsort
SELECT DISTINCT col0 + cor0.col0 + col0 AS col1 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT DISTINCT + - ( + ( - col2 ) ) * + col0 * col2 AS col2 FROM tab0 AS cor0
----
26136
35
598436

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7559
SELECT DISTINCT + col2 * + ( - col2 ) + CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7559
SELECT DISTINCT + col2 * + ( - col2 ) + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 9 * - col2 col0 FROM tab2 AS cor0
----
234
243
342

query I rowsort
SELECT - cor0.col1 * col1 + + col0 * col1 AS col0 FROM tab0 AS cor0
----
-182
-5332
-6014

query I rowsort
SELECT cor1.col1 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab0, tab0 AS cor2
----
243 values hashing to de2705ff0bb8b4f714dafb07497c6119

onlyif mysql # use DIV operator for integer division
query I rowsort label-7563
SELECT ALL - - cor0.col2 * col0 + + col2 DIV + col2 AS col0 FROM tab1 AS cor0
----
163
3649
7681

skipif mysql # not compatible
query I rowsort label-7563
SELECT ALL - - cor0.col2 * col0 + + col2 / + col2 AS col0 FROM tab1 AS cor0
----
163
3649
7681

query I rowsort
SELECT - + 56 * - col2 AS col0 FROM tab2 AS cor0
----
1456
1512
2128

query I rowsort
SELECT DISTINCT col1 * - col1 + 8 FROM tab1 AS cor0
----
-161
-668
-92

query I rowsort
SELECT col1 + col0 - ( - col0 ) AS col1 FROM tab2 AS cor0
----
175
215
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7567
SELECT ALL CAST( NULL AS SIGNED ) / + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7567
SELECT ALL CAST ( NULL AS INTEGER ) / + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * col1 * col0 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT ALL + 29 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL col0 + + 36 * - col2 FROM tab2 cor0
----
-1289
-858
-965

query I rowsort
SELECT DISTINCT + - cor0.col1 + 19 FROM tab2 AS cor0
----
-12
-40
2

query I rowsort
SELECT ALL cor1.col0 AS col2 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT 0 - 0 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 + col0 * + col1 col1 FROM tab1 AS cor0
----
-1326
-208
70

query I rowsort
SELECT DISTINCT 83 * 5 + cor0.col2 FROM tab0, tab0 cor0
----
416
448
497

onlyif mysql # use DIV operator for integer division
query I rowsort label-7576
SELECT + 56 DIV + 63 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7576
SELECT + 56 / + 63 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 6 * - 32 FROM tab0 cor0
----
-192

query I rowsort
SELECT ALL - - col2 + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 18 * 87 col0 FROM tab1 AS cor0
----
-1566

query I rowsort
SELECT + cor0.col0 * col0 + - col1 AS col0 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT + ( + 52 ) FROM tab0 AS cor0
----
52
52
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-7582
SELECT - - 19 + 68 DIV + col1 + - col0 col1 FROM tab0 AS cor0
----
-16
-5
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7582
SELECT - - 19 + 68 / + col1 + - col0 col1 FROM tab0 AS cor0
----
-16
-5
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 col2 FROM tab0 cor0
----
67

query I rowsort
SELECT ALL - 87 * + col1 FROM tab1 AS cor0
----
-1131
-2262
-870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7585
SELECT ALL CAST( NULL AS SIGNED ) * col0 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7585
SELECT ALL CAST ( NULL AS INTEGER ) * col0 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * - cor0.col0 * - ( col2 ) AS col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT ALL col2 + col0 * 3 FROM tab2 cor0
----
260
275
48

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab0 cor1, tab0 cor2
----
3645 values hashing to 87d4c8f6b827823252b140738d532e5c

query I rowsort
SELECT + col0 + ( + col0 ) + + 47 AS col0 FROM tab2 AS cor0
----
203
205
61

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col0 + - CAST ( + col1 AS REAL ) AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT 65 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT DISTINCT - ( - 90 ) FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7593
SELECT col2 + - cor0.col2 * col0 * - col0 + + col2 DIV col1 col2 FROM tab2 AS cor0
----
1350
158210
237198

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7593
SELECT col2 + - cor0.col2 * col0 * - col0 + + col2 / col1 col2 FROM tab2 AS cor0
----
1350
158210
237198

onlyif mysql # use DIV operator for integer division
query I rowsort label-7594
SELECT ALL + col0 DIV - 4 - col0 FROM tab2
----
-8
-97
-98

skipif mysql # not compatible
query I rowsort label-7594
SELECT ALL + col0 / - 4 - col0 FROM tab2
----
-8
-97
-98

query I rowsort
SELECT tab2.col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ( + 24 ) FROM tab1, tab2 cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

onlyif mysql # use DIV operator for integer division
query I rowsort label-7597
SELECT - col2 DIV 45 AS col0 FROM tab1
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-7597
SELECT - col2 / 45 AS col0 FROM tab1
----
-1
-1
-2

query I rowsort
SELECT ALL col1 * col1 - - col1 FROM tab2
----
306
3540
992

query I rowsort
SELECT ALL col1 * + 87 - tab2.col0 FROM tab2
----
1400
2690
5055

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 94 col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

onlyif mysql # use DIV operator for integer division
query I rowsort label-7601
SELECT col0 DIV ( tab1.col0 ) AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7601
SELECT col0 / ( tab1.col0 ) AS col1 FROM tab1
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7602
SELECT - - cor0.col2 DIV col2 - col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-7602
SELECT - - cor0.col2 / col2 - col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT + col2 - ( col2 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + col1 + + col1 FROM tab2
----
177
51
93

query I rowsort
SELECT DISTINCT col0 * + col0 + - col0 FROM tab1
----
4032
6
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7606
SELECT DISTINCT CAST( + col2 AS SIGNED ) AS col1 FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-7606
SELECT DISTINCT CAST ( + col2 AS INTEGER ) AS col1 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT col0 * - ( + col2 + - col2 ) AS col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 99 * + 70 FROM tab1 AS cor0
----
6930

query I rowsort
SELECT + - col2 * col2 * - col1 AS col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - 24 AS col1 FROM tab0 AS cor0
----
-24
-24
-24

query I rowsort
SELECT DISTINCT + 29 AS col2 FROM tab2 cor0
----
29

query I rowsort
SELECT + col2 * col2 + + tab1.col1 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT + col2 * 42 * + col0 FROM tab2 AS cor0
----
126084
7938
85176

query I rowsort
SELECT DISTINCT + col0 * cor0.col2 + + 1 FROM tab1 cor0
----
163
3649
7681

query I rowsort
SELECT + col2 * - col1 - + col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT + - col1 + + 22 * + col0 FROM tab2 AS cor0
----
123
1657
1721

query I rowsort
SELECT DISTINCT col2 + + col2 AS col1 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT + + col0 * 55 FROM tab2 AS cor0
----
385
4290
4345

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7619
SELECT ALL col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7619
SELECT ALL col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7620
SELECT DISTINCT + col1 * + col0 DIV col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7620
SELECT DISTINCT + col1 * + col0 / col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - 23 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT 82 * + cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to e4acaae5615ebaee69e7ffc4cb1824a4

query I rowsort
SELECT ALL col2 - + col1 AS col0 FROM tab2
----
-33
-4
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7624
SELECT + col1 + - col1 + - CAST( NULL AS DECIMAL ) * - 32 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7624
SELECT + col1 + - col1 + - CAST ( NULL AS REAL ) * - 32 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7625
SELECT + col1 + - cor0.col0 DIV col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-7625
SELECT + col1 + - cor0.col0 / col0 FROM tab0 AS cor0
----
85
90
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col0 ) + cor0.col1 * 43 col2 FROM tab2 cor0
----
1340
2615
810

query I rowsort
SELECT DISTINCT - 79 AS col0 FROM tab1 cor0
----
-79

query I rowsort
SELECT - + col0 * + col1 + + col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT + cor0.col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT 8 * + col2 FROM tab1
----
432
456
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-7631
SELECT + 41 DIV + tab1.col1 FROM tab1
----
1
3
4

skipif mysql # not compatible
query I rowsort label-7631
SELECT + 41 / + tab1.col1 FROM tab1
----
1
3
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 77 col0 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT col0 - - 39 * - col2 FROM tab0
----
-1263
-3109
-4

query I rowsort
SELECT ALL - + ( 51 ) * + col1 + - cor0.col0 FROM tab0 AS cor0
----
-4410
-4730
-4982

query I rowsort
SELECT col1 - 87 FROM tab2
----
-28
-56
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7636
SELECT - tab1.col1 + + CAST( col1 AS SIGNED ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7636
SELECT - tab1.col1 + + CAST ( col1 AS INTEGER ) FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7637
SELECT tab0.col2 + - CAST( NULL AS SIGNED ) * col1 * + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7637
SELECT tab0.col2 + - CAST ( NULL AS INTEGER ) * col1 * + col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col1 - + 32 FROM tab0, tab2 AS cor0
----
-49
-63
-91

query I rowsort
SELECT DISTINCT + 51 * + 52 AS col0 FROM tab0, tab0 AS cor0
----
2652

query I rowsort
SELECT + ( + col2 ) + col1 * ( ( col0 ) ) FROM tab2 AS cor0
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) + + col0 * + col2 * 49 col1 FROM tab1 AS cor0
----
178742
376307
7912

query I rowsort
SELECT DISTINCT col1 * + 85 AS col0 FROM tab1 AS cor0
----
1105
2210
850

query I rowsort
SELECT ALL + ( - 88 ) AS col2 FROM tab2 AS cor0
----
-88
-88
-88

query I rowsort
SELECT + ( - col0 ) * + col2 AS col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT cor0.col0 * + col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - + ( cor0.col1 ) * col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - + 56 + - 29 FROM tab2 cor0
----
-85

query I rowsort
SELECT ALL - 57 * col0 FROM tab2 AS cor0
----
-399
-4446
-4503

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7649
SELECT ALL + CAST( - cor0.col2 AS SIGNED ) FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7649
SELECT ALL + CAST ( - cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7650
SELECT col0 + + ( col1 ) DIV ( col2 + col1 ) AS col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-7650
SELECT col0 + + ( col1 ) / ( col2 + col1 ) AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - 62 * - 71 FROM tab2 AS cor0
----
4402

query I rowsort
SELECT - 46 * cor0.col2 FROM tab0 AS cor0
----
-1518
-3772
-46

query I rowsort
SELECT ALL - - col2 + 75 + + col1 AS col1 FROM tab1 AS cor0
----
142
155
184

query I rowsort
SELECT DISTINCT cor0.col2 * - 40 + cor0.col1 FROM tab0 AS cor0
----
-1234
-3189
57

query I rowsort
SELECT ALL + + ( + 75 ) FROM tab2 AS cor0
----
75
75
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( + col1 ) + + col2 col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT + 81 * 72 FROM tab0, tab2, tab0 AS cor0
----
5832

query I rowsort
SELECT DISTINCT 72 + + col2 FROM tab2 AS cor0
----
110
98
99

query I rowsort
SELECT ALL - 30 * - col0 + col0 FROM tab2 cor0
----
217
2418
2449

onlyif mysql # use DIV operator for integer division
query I rowsort label-7660
SELECT - 13 DIV - col1 AS col1 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-7660
SELECT - 13 / - col1 AS col1 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT - + cor0.col0 + + col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 + - 87 col0 FROM tab1 AS cor0
----
-141
-144
-183

query I rowsort
SELECT col2 + + 86 AS col1 FROM tab0 cor0
----
119
168
87

query I rowsort
SELECT ALL cor0.col0 + 74 * + ( + col0 ) * + col2 FROM tab1 AS cor0
----
11991
270016
568400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * + cor0.col2 col1 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT DISTINCT - - col1 * - 59 FROM tab1 AS cor0
----
-1534
-590
-767

query I rowsort
SELECT DISTINCT - col0 + 44 * col2 AS col1 FROM tab1 cor0
----
2373
2444
4144

query I rowsort
SELECT col2 + - ( col1 ) * - col0 * col1 FROM tab0 AS cor0
----
177537
329316
737091

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 29 + - col1 * col2 * + 57 col0 FROM tab2 AS cor0
----
-39113
-47912
-89700

query I rowsort
SELECT + col2 * - cor0.col1 + + ( + col2 ) FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT - cor0.col0 + ( 74 ) AS col0 FROM tab2 AS cor0
----
-4
-5
67

query I rowsort
SELECT - col1 + col1 * ( - col0 ) FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT ALL - col2 - - col2 * col2 * col0 AS col1 FROM tab1 AS cor0
----
207879
737184
8694

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7675
SELECT + col0 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7675
SELECT + col0 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col2 + + 23 FROM tab0 cor0
----
105
24
56

query I rowsort
SELECT col0 + col1 + col2 FROM tab0 AS cor0
----
133
143
262

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7678
SELECT + + CAST( NULL AS SIGNED ) + cor0.col2 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-7678
SELECT + + CAST ( NULL AS INTEGER ) + cor0.col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( - ( + col1 ) ) * cor0.col2 + - col0 AS col2 FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL - 54 + 15 FROM tab0, tab0 AS cor0
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( 51 ) col1 FROM tab1, tab1 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to 006d860fc40bbb38cbb649ba917d74a9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7682
SELECT - CAST( NULL AS DECIMAL ) FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7682
SELECT - CAST ( NULL AS REAL ) FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + - col1 * - col2 + - ( - col0 * - col1 ) AS col1 FROM tab0 AS cor0
----
-3298
-637
774

onlyif mysql # use DIV operator for integer division
query I rowsort label-7684
SELECT + - col0 DIV cor0.col2 + ( + ( col1 ) * ( ( col0 ) ) ) AS col0 FROM tab1 AS cor0
----
1040
639
78

skipif mysql # not compatible
query I rowsort label-7684
SELECT + - col0 / cor0.col2 + ( + ( col1 ) * ( ( col0 ) ) ) AS col0 FROM tab1 AS cor0
----
1040
639
78

query I rowsort
SELECT + col2 + - cor0.col0 * 26 * - col0 FROM tab2 AS cor0
----
1301
158210
162304

query I rowsort
SELECT - - 58 - - col2 FROM tab2 cor0
----
84
85
96

query I rowsort
SELECT - + cor0.col1 * col1 AS col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ( - col1 ) * - col2 + col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - col1 * col0 - col0 * col1 AS col0 FROM tab2 AS cor0
----
-2686
-434
-9204

query I rowsort
SELECT - - cor0.col1 + - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7691
SELECT ALL + col0 DIV + 35 FROM tab1 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-7691
SELECT ALL + col0 / + 35 FROM tab1 AS cor0
----
0
1
2

query I rowsort
SELECT ALL + - cor0.col2 + 62 * 19 FROM tab1 AS cor0
----
1082
1121
1124

onlyif mysql # use DIV operator for integer division
query I rowsort label-7693
SELECT DISTINCT + col1 + - ( col0 + + col0 ) DIV - col2 AS col1 FROM tab0 AS cor0
----
167
87
93

skipif mysql # not compatible
query I rowsort label-7693
SELECT DISTINCT + col1 + - ( col0 + + col0 ) / - col2 AS col1 FROM tab0 AS cor0
----
167
87
93

query I rowsort
SELECT DISTINCT + 58 FROM tab0, tab0 AS cor0
----
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-7695
SELECT - CAST( - col2 AS SIGNED ) DIV col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-7695
SELECT - CAST ( - col2 AS INTEGER ) / col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ( - 68 ) AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 3a5c3d9872a8a4148ab98ed0ab0a6c62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col1 col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 * 83 col2 FROM tab2, tab0 AS cor0
----
581
6474
6557

query I rowsort
SELECT + col2 * col1 * - col2 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT + ( col0 ) * - col0 FROM tab0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7701
SELECT CAST( NULL AS DECIMAL ) * ( - cor0.col0 + - ( - col2 ) ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7701
SELECT CAST ( NULL AS REAL ) * ( - cor0.col0 + - ( - col2 ) ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 48 + - cor0.col1 * col1 FROM tab1 AS cor0
----
-121
-52
-628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT - col0 * + col0 + col0 - + ( + col0 ) * - col0 AS col0 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7705
SELECT ALL 8 DIV + col0 - 95 AS col1 FROM tab2
----
-94
-95
-95

skipif mysql # not compatible
query I rowsort label-7705
SELECT ALL 8 / + col0 - 95 AS col1 FROM tab2
----
-94
-95
-95

query I rowsort
SELECT ALL + 55 * col0 + 91 FROM tab2 AS cor0
----
4381
4436
476

query I rowsort
SELECT DISTINCT col0 * - col0 * - cor0.col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT DISTINCT col2 * + col2 + - ( + 13 + col0 ) * col2 FROM tab2
----
-1690
-2052
189

query I rowsort
SELECT + col0 - - col0 * ( - col2 + col2 ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + - 21 + - cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
-1364
-238
-4623

query I rowsort
SELECT 59 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7712
SELECT col1 * + 95 * tab1.col1 + col0 DIV + tab1.col2 col2 FROM tab1
----
16055
64220
9501

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7712
SELECT col1 * + 95 * tab1.col1 + col0 / + tab1.col2 col2 FROM tab1
----
16055
64220
9501

query I rowsort
SELECT DISTINCT + col2 + 89 AS col2 FROM tab0
----
122
171
90

query I rowsort
SELECT + - ( col2 ) + - col2 FROM tab1 cor0
----
-108
-114
-192

query I rowsort
SELECT - col2 + 37 FROM tab1 AS cor0
----
-17
-20
-59

query I rowsort
SELECT - - 1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + 76 * col1 FROM tab1 AS cor0
----
1976
760
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( 14 ) col1 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT DISTINCT 90 * 70 + - col1 * - col2 AS col2 FROM tab2 AS cor0
----
6946
7137
7834

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7720
SELECT ALL - + CAST( - col1 AS SIGNED ) FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-7720
SELECT ALL - + CAST ( - col1 AS INTEGER ) FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + 98 * - col1 + col0 + cor0.col1 * ( + col1 ) AS col0 FROM tab1 AS cor0
----
-1025
-1869
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7722
SELECT CAST( col0 AS SIGNED ) * - col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-7722
SELECT CAST ( col0 AS INTEGER ) * - col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT 68 * - col1 FROM tab1 AS cor0
----
-1768
-680
-884

onlyif mysql # use DIV operator for integer division
query I rowsort label-7724
SELECT ALL + + 46 * 69 DIV col0 AS col2 FROM tab2 cor0
----
40
40
453

skipif mysql # not compatible
query I rowsort label-7724
SELECT ALL + + 46 * 69 / col0 AS col2 FROM tab2 cor0
----
40
40
453

query I rowsort
SELECT DISTINCT + col2 + cor0.col2 * + col0 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + + 15 AS col2 FROM tab0 AS cor0
----
15
15
15

query I rowsort
SELECT DISTINCT - col0 * cor0.col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT 74 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT DISTINCT + - col1 - + col1 AS col2 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT + 90 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
90

query I rowsort
SELECT + - col1 * - 93 FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT DISTINCT col0 + - col1 * col0 * col2 AS col2 FROM tab1 cor0
----
-36416
-4209
-99760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * + col0 col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL + cor0.col2 - col0 AS col0 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT ALL + + col1 * + ( col1 ) FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL - col1 * + 64 AS col2 FROM tab2 AS cor0
----
-1088
-1984
-3776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 13 * col0 col1 FROM tab0 cor0
----
1157
312
455

query I rowsort
SELECT - 53 - col2 AS col1 FROM tab2 cor0
----
-79
-80
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7739
SELECT ALL tab2.col0 * CAST( col0 AS SIGNED ) FROM tab2
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-7739
SELECT ALL tab2.col0 * CAST ( col0 AS INTEGER ) FROM tab2
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-7740
SELECT - + 92 - col0 DIV + col1 FROM tab1 cor0
----
-92
-98
-98

skipif mysql # not compatible
query I rowsort label-7740
SELECT - + 92 - col0 / + col1 FROM tab1 cor0
----
-92
-98
-98

query I rowsort
SELECT ALL - col1 + 29 FROM tab0 AS cor0
----
-57
-62
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7742
SELECT + - CAST( NULL AS SIGNED ) * cor0.col1 - col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7742
SELECT + - CAST ( NULL AS INTEGER ) * cor0.col1 - col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 + - 17 AS col0 FROM tab0 cor0
----
-18
-50
-99

query I rowsort
SELECT + col2 + col2 * 54 AS col2 FROM tab0
----
1815
4510
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7745
SELECT - tab2.col2 + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7745
SELECT - tab2.col2 + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7746
SELECT ALL cor0.col1 DIV - col2 + - col0 FROM tab0 AS cor0
----
-132
-26
-90

skipif mysql # not compatible
query I rowsort label-7746
SELECT ALL cor0.col1 / - col2 + - col0 FROM tab0 AS cor0
----
-132
-26
-90

query I rowsort
SELECT ALL ( + col2 ) * cor0.col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL col0 * col0 + + col2 * col0 * + col0 FROM tab2 AS cor0
----
1372
164268
243399

query I rowsort
SELECT DISTINCT ( col2 ) * - ( col2 ) * + col1 + col2 FROM tab2 AS cor0
----
-22572
-24510
-39858

query I rowsort
SELECT + col0 * - col0 + + col2 * + col1 AS col0 FROM tab0 AS cor0
----
-1128
-459
2262

query I rowsort
SELECT ALL + ( - col0 ) + + col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + col2 * + col0 + - col2 * col1 + col0 AS col0 FROM tab1 AS cor0
----
-1239
3142
6512

query I rowsort
SELECT DISTINCT - - col1 * cor0.col1 + col2 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-7754
SELECT DISTINCT + - col0 + - col1 * + col0 DIV col0 AS col0 FROM tab2 AS cor0
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-7754
SELECT DISTINCT + - col0 + - col1 * + col0 / col0 AS col0 FROM tab2 AS cor0
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7755
SELECT + - col0 DIV + col0 + + col0 + col0 FROM tab1 AS cor0
----
127
159
5

skipif mysql # not compatible
query I rowsort label-7755
SELECT + - col0 / + col0 + + col0 + col0 FROM tab1 AS cor0
----
127
159
5

query I rowsort
SELECT ALL ( - col0 ) * - col1 + col0 * col1 + col2 * + col0 * - col1 FROM tab0
----
-63984
-647920
3395

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 72 col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 col1 FROM tab0 AS cor0
----
58
58
58

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7760
SELECT DISTINCT + 33 + col1 DIV - col1 FROM tab0 AS cor0
----
32

skipif mysql # not compatible
query I rowsort label-7760
SELECT DISTINCT + 33 + col1 / - col1 FROM tab0 AS cor0
----
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-7761
SELECT - + 46 + + col2 DIV - 85 FROM tab2 AS cor0
----
-46
-46
-46

skipif mysql # not compatible
query I rowsort label-7761
SELECT - + 46 + + col2 / - 85 FROM tab2 AS cor0
----
-46
-46
-46

query I rowsort
SELECT DISTINCT + 69 AS col1 FROM tab2 AS cor0
----
69

query I rowsort
SELECT DISTINCT - cor1.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + + 2 AS col0 FROM tab0 AS cor0
----
2

query I rowsort
SELECT DISTINCT 19 AS col1 FROM tab1, tab2, tab1 AS cor0
----
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-7766
SELECT col1 DIV cor0.col0 + + col1 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-7766
SELECT col1 / cor0.col0 + + col1 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT DISTINCT ( col0 ) * + tab1.col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL tab2.col2 AS col2 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT + ( col1 ) * - col2 FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 + - col0 * - col1 col2 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-7771
SELECT - col0 DIV 19 AS col1 FROM tab1 AS cor0
----
-3
-4
0

skipif mysql # not compatible
query I rowsort label-7771
SELECT - col0 / 19 AS col1 FROM tab1 AS cor0
----
-3
-4
0

query I rowsort
SELECT - col1 + cor0.col2 * col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + 48 * - 83 FROM tab1
----
-3984
-3984
-3984

query I rowsort
SELECT ALL + col0 + col2 * col0 - ( cor0.col1 ) FROM tab1 AS cor0
----
139
3702
7747

query I rowsort
SELECT 2 + - col1 FROM tab1 AS cor0
----
-11
-24
-8

query I rowsort
SELECT ALL - col0 - + col0 AS col0 FROM tab0 cor0
----
-178
-48
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-7777
SELECT ALL + col1 DIV 69 + col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7777
SELECT ALL + col1 / 69 + col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - - 84 + - col1 AS col0 FROM tab1 cor0
----
58
71
74

query I rowsort
SELECT ALL - + ( col2 ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT col0 + + cor0.col2 * col2 + ( 8 ) AS col1 FROM tab1 AS cor0
----
2927
3321
9304

onlyif mysql # use DIV operator for integer division
query I rowsort label-7781
SELECT + - col0 DIV 2 + - col0 * col2 FROM tab1 AS cor0
----
-163
-3680
-7720

skipif mysql # not compatible
query I rowsort label-7781
SELECT + - col0 / 2 + - col0 * col2 FROM tab1 AS cor0
----
-163
-3680
-7720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7782
SELECT DISTINCT + CAST( NULL AS SIGNED ) + 66 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7782
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + 66 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + cor0.col2 + + col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT 82 * 73 FROM tab1
----
5986
5986
5986

query I rowsort
SELECT - 62 + col0 * col1 AS col1 FROM tab0 AS cor0
----
2002
3333
8037

onlyif mysql # use DIV operator for integer division
query I rowsort label-7786
SELECT + - col0 DIV + col2 + + 25 FROM tab1 AS cor0
----
24
25
25

skipif mysql # not compatible
query I rowsort label-7786
SELECT + - col0 / + col2 + + 25 FROM tab1 AS cor0
----
24
25
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-7787
SELECT + + col0 DIV col2 AS col1 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7787
SELECT + + col0 / col2 AS col1 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7788
SELECT CAST( col1 AS SIGNED ) + col1 FROM tab0 cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-7788
SELECT CAST ( col1 AS INTEGER ) + col1 FROM tab0 cor0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-7789
SELECT DISTINCT col1 DIV 3 col0 FROM tab1
----
3
4
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7789
SELECT DISTINCT col1 / 3 col0 FROM tab1
----
3
4
8

query I rowsort
SELECT col2 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-7791
SELECT DISTINCT + col2 DIV col1 AS col1 FROM tab2
----
0
2

skipif mysql # not compatible
query I rowsort label-7791
SELECT DISTINCT + col2 / col1 AS col1 FROM tab2
----
0
2

query I rowsort
SELECT DISTINCT - col1 * + tab1.col1 AS col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - - ( - col1 ) AS col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT + - col0 * - col2 - cor0.col0 * - ( col1 ) AS col1 FROM tab0 AS cor0
----
15397
2856
3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-7795
SELECT ALL + ( col2 ) DIV - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7795
SELECT ALL + ( col2 ) / - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7796
SELECT + col0 * + col0 - + col1 DIV - 15 AS col2 FROM tab2 AS cor0
----
51
6087
6242

skipif mysql # not compatible
query I rowsort label-7796
SELECT + col0 * + col0 - + col1 / - 15 AS col2 FROM tab2 AS cor0
----
51
6087
6242

query I rowsort
SELECT DISTINCT - col0 + col0 * col0 FROM tab1 AS cor0
----
4032
6
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-7798
SELECT - cor0.col0 DIV 98 + cor0.col2 AS col2 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7798
SELECT - cor0.col0 / 98 + cor0.col2 AS col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + 27 + 39 AS col2 FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT DISTINCT 52 * - col2 AS col2 FROM tab1 AS cor0
----
-2808
-2964
-4992

query I rowsort
SELECT - - 9 - col1 AS col2 FROM tab2 AS cor0
----
-22
-50
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7802
SELECT DISTINCT - CAST( + col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7802
SELECT DISTINCT - CAST ( + col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7803
SELECT + CAST( - col1 AS SIGNED ) + cor0.col1 * + col0 AS col0 FROM tab2 AS cor0
----
1326
186
4543

skipif mysql # not compatible
query I rowsort label-7803
SELECT + CAST ( - col1 AS INTEGER ) + cor0.col1 * + col0 AS col0 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT - col2 - + 87 AS col1 FROM tab0 cor0
----
-120
-169
-88

query I rowsort
SELECT ALL - - col0 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - - ( - 96 ) * col2 AS col2 FROM tab0 AS cor0
----
-3168
-7872
-96

query I rowsort
SELECT DISTINCT col2 * col1 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - - cor0.col2 * - col0 * + col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - 22 + + col2 AS col2 FROM tab2 AS cor0
----
16
4
5

query I rowsort
SELECT cor0.col2 * col2 + 77 AS col1 FROM tab0 cor0
----
1166
6801
78

query I rowsort
SELECT - col0 * + ( 98 ) FROM tab1 AS cor0
----
-294
-6272
-7840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + ( + col1 ) - col2 * - 85 col2 FROM tab2 AS cor0
----
2333
2347
3326

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 37 col0 FROM tab0 AS cor0
----
-1221
-3034
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col0 + col0 col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT cor0.col2 + col2 + col1 AS col2 FROM tab2 cor0
----
111
85
93

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 * - col2 AS col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT DISTINCT cor0.col0 - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + + col2 + 99 * 64 FROM tab2 AS cor0
----
6362
6363
6374

query I rowsort
SELECT - cor0.col0 * + col0 + + 57 AS col2 FROM tab0 AS cor0
----
-1168
-519
-7864

query I rowsort
SELECT ALL - col1 + + ( col2 ) * col2 AS col2 FROM tab1 cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT - + col1 + 26 - col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
-194
-2061
-2993

query I rowsort
SELECT - 42 * - col1 AS col0 FROM tab2
----
1302
2478
714

query I rowsort
SELECT DISTINCT + - cor0.col0 * - cor0.col0 * 35 + cor0.col1 * - cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
-476336
-615896
-869798

query I rowsort
SELECT + + cor0.col0 + 84 * ( col1 ) AS col0 FROM tab2 cor0
----
1507
2611
5034

query I rowsort
SELECT ALL - + col0 + - 39 - + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-33
3993
6281

query I rowsort
SELECT ALL + - col2 + - 80 AS col0 FROM tab2 AS cor0
----
-106
-107
-118

query I rowsort
SELECT + - 93 * 41 FROM tab1 AS cor0
----
-3813
-3813
-3813

query I rowsort
SELECT DISTINCT - col2 + cor0.col1 FROM tab1 cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7829
SELECT ALL col2 DIV 95 AS col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7829
SELECT ALL col2 / 95 AS col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL + - col2 - col0 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 22 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col0 ) * - ( + col1 ) col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT + 72 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to e1618abfe12be6a950cc575d695639b7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7834
SELECT ALL + - col1 DIV + col2 AS col0 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-7834
SELECT ALL + - col1 / + col2 AS col0 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT - + col0 + cor0.col0 + col2 * - col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT col1 + - col0 * + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - cor0.col2 * - 79 FROM tab1, tab0 AS cor0
----
9 values hashing to 0351101cf0b00edc13cdaa144db558f9

query I rowsort
SELECT DISTINCT - col1 * col0 * ( col0 * - col0 ) AS col0 FROM tab2 AS cor0
----
10633
27998568
8381663

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * col2 col2 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-7840
SELECT DISTINCT + col0 DIV ( col1 ) + col1 - col1 AS col0 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-7840
SELECT DISTINCT + col0 / ( col1 ) + col1 - col1 AS col0 FROM tab2
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-7841
SELECT + tab0.col2 DIV col2 AS col2 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7841
SELECT + tab0.col2 / col2 AS col2 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL + 24 AS col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT ALL - tab1.col0 + col0 * 80 AS col0 FROM tab1
----
237
5056
6320

query I rowsort
SELECT ALL + col2 * + col0 * col0 AS col1 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT ( - tab2.col1 ) + + ( col2 * col2 ) AS col0 FROM tab2
----
1427
617
698

query I rowsort
SELECT 81 * - col2 + tab0.col2 AS col0 FROM tab0
----
-2640
-6560
-80

query I rowsort
SELECT DISTINCT col0 + + col1 * - 51 * col2 FROM tab2
----
-32867
-42680
-78156

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL + 25 * - 65 FROM tab2 AS cor0
----
-1625
-1625
-1625

query I rowsort
SELECT ALL ( col0 ) * col1 * col0 + + cor0.col0 * col1 * col0 AS col2 FROM tab0 AS cor0
----
1441622
237650
99072

query I rowsort
SELECT - ( 32 ) AS col1 FROM tab2 AS cor0
----
-32
-32
-32

query I rowsort
SELECT DISTINCT - col2 * + 2 FROM tab0 AS cor0
----
-164
-2
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-7853
SELECT ALL + col2 * - col2 + - col2 DIV - cor0.col0 FROM tab1 cor0
----
-2898
-3249
-9215

skipif mysql # not compatible
query I rowsort label-7853
SELECT ALL + col2 * - col2 + - col2 / - cor0.col0 FROM tab1 cor0
----
-2898
-3249
-9215

query I rowsort
SELECT DISTINCT 70 * col0 AS col0 FROM tab2 AS cor0
----
490
5460
5530

query I rowsort
SELECT DISTINCT - + col2 * cor0.col2 + - col1 FROM tab0 cor0
----
-1175
-6815
-98

query I rowsort
SELECT ALL 33 + - col0 * cor0.col0 FROM tab0 AS cor0
----
-1192
-543
-7888

query I rowsort
SELECT ( col2 ) + 54 FROM tab0 AS cor0
----
136
55
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-7858
SELECT DISTINCT cor0.col1 DIV col0 + - 55 * col1 FROM tab0 AS cor0
----
-4727
-5004
-5333

skipif mysql # not compatible
query I rowsort label-7858
SELECT DISTINCT cor0.col1 / col0 + - 55 * col1 FROM tab0 AS cor0
----
-4727
-5004
-5333

query I rowsort
SELECT ALL + + col0 + - col1 * - 51 AS col1 FROM tab1 AS cor0
----
1329
574
743

query I rowsort
SELECT + 12 * - tab2.col1 FROM tab2
----
-204
-372
-708

query I rowsort
SELECT ALL - col1 + 20 * cor0.col0 FROM tab0 AS cor0
----
1689
394
603

query I rowsort
SELECT DISTINCT - col0 + + 6 * + 78 AS col2 FROM tab1
----
388
404
465

query I rowsort
SELECT + tab1.col1 * ( + col2 ) FROM tab1
----
1248
1404
570

query I rowsort
SELECT col1 + 44 AS col1 FROM tab0 AS cor0
----
130
135
141

query I rowsort
SELECT - col0 * ( - col1 ) - - col2 * - 32 AS col0 FROM tab2 AS cor0
----
-647
127
3770

query I rowsort
SELECT ALL + col1 + col1 - col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - 92 * col2 + col1 FROM tab1 AS cor0
----
-4942
-5234
-8819

query I rowsort
SELECT - 57 + + cor0.col1 FROM tab1 AS cor0
----
-31
-44
-47

query I rowsort
SELECT ALL 86 * + col1 + + col0 FROM tab1 cor0
----
1198
2239
924

query I rowsort
SELECT ALL + col0 + 53 AS col2 FROM tab0 AS cor0
----
142
77
88

query I rowsort
SELECT DISTINCT - col0 * col1 - cor0.col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL + 94 + cor0.col1 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1440
-552
-743

onlyif mysql # use DIV operator for integer division
query I rowsort label-7873
SELECT + col1 * ( col2 ) DIV + ( + 66 ) + + col2 AS col0 FROM tab1 AS cor0
----
114
65
75

skipif mysql # not compatible
query I rowsort label-7873
SELECT + col1 * ( col2 ) / + ( + 66 ) + + col2 AS col0 FROM tab1 AS cor0
----
114
65
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-7874
SELECT ALL - col0 + + col0 DIV - col0 AS col1 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-7874
SELECT ALL - col0 + + col0 / - col0 AS col1 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT + col0 + - cor0.col0 * - col1 * 45 FROM tab2 AS cor0
----
207168
60514
9772

query I rowsort
SELECT DISTINCT + col2 + - 97 * + 14 FROM tab2
----
-1320
-1331
-1332

onlyif mysql # use DIV operator for integer division
query I rowsort label-7877
SELECT ALL col2 + + col2 DIV + 42 AS col1 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-7877
SELECT ALL col2 + + col2 / + 42 AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT + 60 FROM tab0, tab1, tab0 AS cor0, tab1 AS cor1
----
81 values hashing to 1ef27a1d2784b3ab642571630db70349

query I rowsort
SELECT - + 65 * col2 FROM tab0 cor0
----
-2145
-5330
-65

query I rowsort
SELECT + 35 * 96 * - col2 FROM tab0 AS cor0
----
-110880
-275520
-3360

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7881
SELECT CAST( NULL AS SIGNED ) * + 95 + - col2 * + ( + col2 * + col2 ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7881
SELECT CAST ( NULL AS INTEGER ) * + 95 + - col2 * + ( + col2 * + col2 ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab1.col0 + - col1 * ( col2 + + col1 ) AS col1 FROM tab1
----
-1497
-2083
-734

onlyif mysql # use DIV operator for integer division
query I rowsort label-7883
SELECT + tab0.col2 * - col0 * - col1 + - col1 * - col1 * - col1 + col0 DIV col2 AS col0 FROM tab0
----
-567944
-89452
-909243

skipif mysql # not compatible
query I rowsort label-7883
SELECT + tab0.col2 * - col0 * - col1 + - col1 * - col1 * - col1 + col0 / col2 AS col0 FROM tab0
----
-567944
-89452
-909243

query I rowsort
SELECT ( + ( + tab1.col2 ) ) * col0 AS col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT 30 * + col1 FROM tab2
----
1770
510
930

query I rowsort
SELECT col2 * + ( col0 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT + col0 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + + cor0.col2 * cor0.col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL col2 * - cor0.col2 + ( col1 ) * col1 FROM tab1 cor0
----
-2240
-3149
-9047

query I rowsort
SELECT - 23 AS col2 FROM tab2 AS cor0
----
-23
-23
-23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 10 * - col0 col0 FROM tab2
----
-70
-780
-790

query I rowsort
SELECT DISTINCT - 65 * col1 AS col1 FROM tab0
----
-5590
-5915
-6305

query I rowsort
SELECT 20 * 63 FROM tab1
----
1260
1260
1260

query I rowsort
SELECT + col1 * ( + col2 ) FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7895
SELECT + col2 + col1 DIV col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-7895
SELECT + col2 + col1 / col2 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT - 2 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 20c9213316527d507e26425041e08387

query I rowsort
SELECT - - col0 * - ( + col1 ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 * 19 FROM tab0 AS cor0
----
1634
1729
1843

onlyif mysql # use DIV operator for integer division
query I rowsort label-7899
SELECT DISTINCT + col0 + - col2 * 54 DIV col0 FROM tab0 AS cor0
----
-50
34
40

skipif mysql # not compatible
query I rowsort label-7899
SELECT DISTINCT + col0 + - col2 * 54 / col0 FROM tab0 AS cor0
----
-50
34
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * + cor0.col1 + + cor0.col1 * cor0.col1 col1 FROM tab0 AS cor0
----
12804
16380
9460

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7901
SELECT col0 - CAST( NULL AS SIGNED ) * col0 * - 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-7901
SELECT col0 - CAST ( NULL AS INTEGER ) * col0 * - col0 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - col1 - - 4 FROM tab0 AS cor0
----
-2834
-7458
-93

query I rowsort
SELECT ALL + + col1 + - 40 * - col0 FROM tab1 AS cor0
----
146
2570
3213

onlyif mysql # use DIV operator for integer division
query I rowsort label-7904
SELECT col1 * 92 DIV + col2 FROM tab0 AS cor0
----
102
239
8924

skipif mysql # not compatible
query I rowsort label-7904
SELECT col1 * 92 / + col2 FROM tab0 AS cor0
----
102
239
8924

query I rowsort
SELECT ALL - col0 + 13 AS col0 FROM tab0 AS cor0
----
-11
-22
-76

query I rowsort
SELECT cor0.col0 + + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col2 * ( + cor0.col1 ) + - col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL + - col2 + 54 * - col0 FROM tab0 AS cor0
----
-1329
-1891
-4888

query I rowsort
SELECT + col1 * 20 FROM tab2 AS cor0
----
1180
340
620

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + ( + 31 ) col1 FROM tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT ALL - - col1 * 34 FROM tab1 AS cor0
----
340
442
884

query I rowsort
SELECT col1 * ( + 17 ) FROM tab0 cor0
----
1462
1547
1649

onlyif mysql # use DIV operator for integer division
query I rowsort label-7913
SELECT DISTINCT - + col2 DIV col0 + - 70 FROM tab0 AS cor0
----
-70
-71

skipif mysql # not compatible
query I rowsort label-7913
SELECT DISTINCT - + col2 / col0 + - 70 FROM tab0 AS cor0
----
-70
-71

query I rowsort
SELECT DISTINCT col2 * - 71 AS col1 FROM tab0
----
-2343
-5822
-71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7915
SELECT col0 * + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7915
SELECT col0 * + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * 29 FROM tab2 AS cor0
----
-1102
-754
-783

query I rowsort
SELECT col1 * - ( + col2 + col2 ) AS col0 FROM tab0 AS cor0
----
-14924
-194
-5676

query I rowsort
SELECT col1 * + col2 + + 10 AS col0 FROM tab2
----
1544
656
847

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col2 * col0 - col0 * - col2 col0 FROM tab1
----
0
0
0

query I rowsort
SELECT col1 FROM tab2 WHERE NULL < NULL
----

query I rowsort
SELECT tab0.col0 * + col0 + col1 * + col0 AS col0 FROM tab0
----
16020
2640
4620

query I rowsort
SELECT DISTINCT col2 - - tab0.col1 AS col2 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7923
SELECT + col2 * + tab0.col2 * col1 + + col1 DIV col0 AS col1 FROM tab0
----
611885
93657
99

skipif mysql # not compatible
query I rowsort label-7923
SELECT + col2 * + tab0.col2 * col1 + + col1 / col0 AS col1 FROM tab0
----
611885
93657
99

query I rowsort
SELECT + col0 - - col0 FROM tab1 WHERE col2 <= col0
----
128

query III rowsort
SELECT ALL * FROM tab2 WHERE + col1 = ( NULL )
----

query I rowsort
SELECT DISTINCT - col0 FROM tab2 WHERE col1 NOT IN ( col1 )
----

query I rowsort
SELECT + col2 * - col2 * col1 + - col0 FROM tab1
----
-119888
-32554
-75819

onlyif mysql # use DIV operator for integer division
query I rowsort label-7928
SELECT ALL + col2 DIV tab1.col2 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7928
SELECT ALL + col2 / tab1.col2 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL tab2.col1 * + tab2.col2 FROM tab2
----
1534
646
837

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( col0 * - col1 ) IN ( col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col0 * col2 + + tab1.col2 FROM tab1
----
216
3705
7776

query I rowsort
SELECT col1 FROM tab1 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT tab1.col0 - tab1.col0 * tab1.col0 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT ALL col2 + + tab2.col2 FROM tab2
----
52
54
76

query I rowsort
SELECT - 14 + - col0 FROM tab0 cor0
----
-103
-38
-49

query I rowsort
SELECT - + ( + col0 ) * cor0.col0 + col0 AS col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT + col1 * tab1.col1 + 84 FROM tab1
----
184
253
760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col1 col0 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * + cor0.col2 - col1 col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT - + cor0.col0 + col0 * ( col2 ) FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - col0 - col2 * 32 FROM tab1 AS cor0
----
-1731
-1888
-3152

query I rowsort
SELECT - + 63 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-56
15
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - ( - col1 * cor0.col0 ) col0 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-7944
SELECT + - col1 DIV col1 + - cor0.col2 FROM tab2 cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-7944
SELECT + - col1 / col1 + - cor0.col2 FROM tab2 cor0
----
-27
-28
-39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7945
SELECT col0 + + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7945
SELECT col0 + + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7946
SELECT ALL + cor0.col2 DIV + col0 + - col0 AS col1 FROM tab0 AS cor0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-7946
SELECT ALL + cor0.col2 / + col0 + - col0 AS col1 FROM tab0 AS cor0
----
-23
-35
-89

query I rowsort
SELECT 46 AS col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - col2 col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * col0 + + col2 col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT - 8 + - col1 AS col2 FROM tab0
----
-105
-94
-99

query I rowsort
SELECT + col2 - + tab2.col0 FROM tab2
----
-41
-52
20

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0, tab0, tab0 AS cor1
----
972 values hashing to b2fa3f9d060540fe1eb4ad1c0754e163

onlyif mysql # use DIV operator for integer division
query I rowsort label-7953
SELECT ALL 66 DIV cor0.col0 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

skipif mysql # not compatible
query I rowsort label-7953
SELECT ALL 66 / cor0.col0 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

query I rowsort
SELECT - col2 + - ( - cor0.col2 ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * 83 + col1 FROM tab1 AS cor0
----
1092
2184
840

query I rowsort
SELECT + + col0 + col0 - col0 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col2 * + col2 col1 FROM tab0
----
1175
6815
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 42 col0 FROM tab1 AS cor0
----
-42
-42
-42

query I rowsort
SELECT + + col0 * 71 AS col2 FROM tab0 cor0
----
1704
2485
6319

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2, tab0 AS cor3
----
3645 values hashing to 625894990bdb8a9e41da1ea8f0cabaa3

query I rowsort
SELECT DISTINCT + 89 - ( + col1 ) FROM tab2 cor0
----
30
58
72

query I rowsort
SELECT + col1 * - 29 FROM tab2 AS cor0
----
-1711
-493
-899

query I rowsort
SELECT ALL + col2 * 94 FROM tab0 AS cor0
----
3102
7708
94

query I rowsort
SELECT + 44 * - 97 FROM tab2
----
-4268
-4268
-4268

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 93 - - col2 * 46 col1 FROM tab0 AS cor0
----
139
1611
3865

query I rowsort
SELECT DISTINCT col0 * 71 FROM tab0
----
1704
2485
6319

query I rowsort
SELECT ALL - - col1 * + col0 - + ( + col0 ) AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT DISTINCT - col0 + - col0 * - col0 AS col1 FROM tab1 cor0
----
4032
6
6320

query I rowsort
SELECT ALL col2 * - col2 + 24 FROM tab1 AS cor0
----
-2892
-3225
-9192

query I rowsort
SELECT + + 86 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
112
96
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 3 * + col1 col2 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT + col2 * col2 + + col1 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT ALL - col0 * col2 - col1 * 54 AS col2 FROM tab2
----
-1863
-3920
-5214

query I rowsort
SELECT ALL + tab2.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 tab2.col0 * col2 + col0 col0 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-7976
SELECT DISTINCT - ( col2 ) DIV - col0 + - col2 * + tab2.col0 AS col0 FROM tab2
----
-186
-2028
-3002

skipif mysql # not compatible
query I rowsort label-7976
SELECT DISTINCT - ( col2 ) / - col0 + - col2 * + tab2.col0 AS col0 FROM tab2
----
-186
-2028
-3002

query I rowsort
SELECT - col2 + col1 * col1 + - cor0.col2 AS col0 FROM tab0 AS cor0
----
7330
8117
9407

onlyif mysql # use DIV operator for integer division
query I rowsort label-7978
SELECT + + col2 + - col2 DIV + col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7978
SELECT + + col2 + - col2 / + col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL col1 * - col1 + col2 + col0 FROM tab0
----
-7339
-8110
-9373

query I rowsort
SELECT - ( + col0 ) * col1 AS col2 FROM tab2
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 6 * col1 + col2 + col2 col1 FROM tab1
----
-48
114
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-7982
SELECT ALL + col1 DIV + col2 col1 FROM tab0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7982
SELECT ALL + col1 / + col2 col1 FROM tab0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col2 * col0 col2 FROM tab0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-7984
SELECT + cor0.col0 DIV cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-7984
SELECT + cor0.col0 / cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - cor0.col2 ) col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT DISTINCT ( 96 ) - + col1 FROM tab1
----
70
83
86

query I rowsort
SELECT ALL 92 * + col0 - col0 FROM tab2
----
637
7098
7189

query I rowsort
SELECT - ( + tab0.col1 ) + + col2 * - col0 AS col0 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT DISTINCT - col0 * - cor0.col2 + col2 AS col0 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT ALL + ( col0 ) * col1 * col0 + + col0 FROM tab1 AS cor0
----
237
41024
83280

query I rowsort
SELECT DISTINCT - col2 * + 32 + cor0.col0 * col1 AS col2 FROM tab1 cor0
----
-1184
-1650
-2032

query I rowsort
SELECT ALL + cor0.col2 + col2 * cor0.col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT + cor0.col0 + 16 FROM tab1 AS cor0
----
19
80
96

query I rowsort
SELECT DISTINCT 69 + col2 FROM tab2 AS cor0
----
107
95
96

query I rowsort
SELECT col0 * - col1 + col2 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT ALL + col2 + - col2 * + col2 * - col1 FROM tab1 cor0
----
119904
32547
75870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 3 + + col2 + cor0.col2 col1 FROM tab2 AS cor0
----
55
57
79

query I rowsort
SELECT + col1 * col1 * + col1 - - col2 FROM tab2 AS cor0
----
205405
29818
4951

query I rowsort
SELECT - col2 * - col0 + col0 * col0 FROM tab2 AS cor0
----
238
8112
9243

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 63 + - col2 * - cor0.col1 col0 FROM tab0 AS cor0
----
2775
34
7399

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - cor0.col2 * - col2 + - col2 * - col2 col0 FROM tab2 AS cor0
----
23328
25992
40560

query I rowsort
SELECT + - 18 * col0 FROM tab1 AS cor0
----
-1152
-1440
-54

query I rowsort
SELECT ALL - + ( col2 ) * - col1 + - col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-8004
SELECT DISTINCT col2 * - 68 - tab0.col2 DIV col2 FROM tab0
----
-2245
-5577
-69

skipif mysql # not compatible
query I rowsort label-8004
SELECT DISTINCT col2 * - 68 - tab0.col2 / col2 FROM tab0
----
-2245
-5577
-69

query I rowsort
SELECT + - col2 * - col1 + col1 + col2 AS col1 FROM tab2 AS cor0
----
1619
701
895

query I rowsort
SELECT - 94 - col0 * col1 AS col1 FROM tab2 AS cor0
----
-1437
-311
-4696

query I rowsort
SELECT DISTINCT tab2.col1 + col0 * - tab2.col1 * - col2 AS col1 FROM tab2
----
119711
51051
5890

query I rowsort
SELECT col1 * col2 * + col2 - + col2 * - col1 AS col2 FROM tab1
----
121056
33060
77220

query I rowsort
SELECT DISTINCT - tab1.col2 AS col0 FROM tab1 WHERE NULL < ( col2 )
----

query I rowsort
SELECT DISTINCT - tab2.col0 + col2 - + col2 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT + col2 * col0 * tab2.col2 FROM tab2
----
114076
5103
52728

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL NOT BETWEEN ( - col2 ) AND + col2
----

query I rowsort
SELECT DISTINCT tab1.col1 AS col1 FROM tab1 WHERE NOT NULL NOT BETWEEN ( + col1 * col0 ) AND NULL
----

query I rowsort
SELECT - col0 * - col2 * - col2 + col2 FROM tab0
----
-26103
-34
-598354

query I rowsort
SELECT ALL col0 FROM tab2 WHERE NULL < ( NULL )
----

query I rowsort
SELECT DISTINCT col0 * + col1 * - tab0.col0 AS col2 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT col2 * + col1 * - col1 FROM tab2 WHERE NOT NULL = ( - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 * + col2 col1 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * + col1 col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8020
SELECT - col2 + + col0 DIV col2 AS col2 FROM tab1
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-8020
SELECT - col2 + + col0 / col2 AS col2 FROM tab1
----
-54
-56
-96

query I rowsort
SELECT ALL cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL 15 + col1 FROM tab0
----
101
106
112

query I rowsort
SELECT DISTINCT 33 + + 14 AS col0 FROM tab1
----
47

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + 6 AS REAL ) * - col0 FROM tab1 cor0
----
-18
-384
-480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) * col1 + - col2 col0 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL 26 * - col1 + col2 FROM tab2 AS cor0
----
-1508
-404
-779

query I rowsort
SELECT - col1 * 48 AS col0 FROM tab1 cor0
----
-1248
-480
-624

query I rowsort
SELECT DISTINCT - cor0.col1 + - col2 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8029
SELECT ALL 13 DIV col1 + - col1 + 38 FROM tab2 AS cor0
----
-21
21
7

skipif mysql # not compatible
query I rowsort label-8029
SELECT ALL 13 / col1 + - col1 + 38 FROM tab2 AS cor0
----
-21
21
7

query I rowsort
SELECT DISTINCT - col1 * col2 - col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT - - col0 + - cor0.col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL 35 AS col1 FROM tab1 AS cor0
----
35
35
35

query I rowsort
SELECT - 96 * - col1 + - col2 * col0 FROM tab0 AS cor0
----
1438
7464
9277

query I rowsort
SELECT cor1.col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + col0 * - col0 + - col2 FROM tab0 AS cor0
----
-1226
-609
-8003

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - cor0.col1 col2 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 27 + col2 col0 FROM tab0 AS cor0
----
109
28
60

query I rowsort
SELECT ALL - - 95 + + col1 * - ( 94 * - col1 ) FROM tab1 AS cor0
----
15981
63639
9495

query I rowsort
SELECT ALL - 49 * + col2 + col1 AS col2 FROM tab2
----
-1215
-1292
-1845

query I rowsort
SELECT DISTINCT + - cor0.col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + + col0 + - col0 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + col2 + col0 - + col1 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT + - col0 * + 38 FROM tab2 AS cor0
----
-266
-2964
-3002

query I rowsort
SELECT - col2 * + ( - col0 ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - col0 * + col1 + + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 46 col1 FROM tab1, tab2, tab0 cor0
----
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8047
SELECT ALL cor0.col2 * CAST( 32 AS SIGNED ) col2 FROM tab2 cor0
----
1216
832
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8047
SELECT ALL cor0.col2 * CAST ( 32 AS INTEGER ) col2 FROM tab2 cor0
----
1216
832
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8048
SELECT col1 * CAST( col0 AS SIGNED ) + col0 + + CAST( 51 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1171
132
755

skipif mysql # not compatible
query I rowsort label-8048
SELECT col1 * CAST ( col0 AS INTEGER ) + col0 + + CAST ( 51 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1171
132
755

skipif mysql # not compatible
query I rowsort
SELECT ALL + + col0 * CAST ( ( col1 ) * 75 AS REAL ) FROM tab1 AS cor0
----
48000
5850
78000

query I rowsort
SELECT 69 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT ALL 26 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT col2 * + cor0.col0 + + col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-8053
SELECT + col0 + + col0 DIV + 51 FROM tab1 AS cor0
----
3
65
81

skipif mysql # not compatible
query I rowsort label-8053
SELECT + col0 + + col0 / + 51 FROM tab1 AS cor0
----
3
65
81

query I rowsort
SELECT - - cor1.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

onlyif mysql # use DIV operator for integer division
query I rowsort label-8055
SELECT - 33 * 14 DIV + col2 - col2 FROM tab1 cor0
----
-100
-62
-65

skipif mysql # not compatible
query I rowsort label-8055
SELECT - 33 * 14 / + col2 - col2 FROM tab1 cor0
----
-100
-62
-65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8056
SELECT - col1 * - ( col1 + + CAST( NULL AS SIGNED ) ) * ( + col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8056
SELECT - col1 * - ( col1 + + CAST ( NULL AS INTEGER ) ) * ( + col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col0 col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - col1 + ( cor0.col2 ) AS col0 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8059
SELECT ALL col2 + 39 * + col0 * - tab1.col2 + + CAST( + 84 AS SIGNED ) col0 FROM tab1
----
-142131
-299340
-6180

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8059
SELECT ALL col2 + 39 * + col0 * - tab1.col2 + + CAST ( + 84 AS INTEGER ) col0 FROM tab1
----
-142131
-299340
-6180

onlyif mysql # use DIV operator for integer division
query I rowsort label-8060
SELECT DISTINCT + col0 DIV col1 - col0 * col0 AS col2 FROM tab0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-8060
SELECT DISTINCT + col0 / col1 - col0 * col0 AS col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT - col1 - + tab0.col2 AS col2 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT 70 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8063
SELECT ALL - CAST( NULL AS SIGNED ) * 11 FROM tab2, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8063
SELECT ALL - CAST ( NULL AS INTEGER ) * 11 FROM tab2, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT col2 * col2 * + col0 + 98 * + 19 AS col1 FROM tab2
----
115938
54590
6965

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2, tab1 AS cor3
----
13122 values hashing to 11b7a9a87da0088d23991542300883c3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8067
SELECT + col2 + - 95 + col0 DIV - 39 AS col1 FROM tab2
----
-59
-68
-71

skipif mysql # not compatible
query I rowsort label-8067
SELECT + col2 + - 95 + col0 / - 39 AS col1 FROM tab2
----
-59
-68
-71

query I rowsort
SELECT ( - col0 ) * + col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT ALL - + ( col0 ) * + col2 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - + 4 AS col0 FROM tab1 AS cor0
----
-4

query I rowsort
SELECT - ( col1 ) + - col1 AS col2 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT 42 + + col0 AS col1 FROM tab1 AS cor0
----
106
122
45

query I rowsort
SELECT + 93 + - 10 AS col0 FROM tab0 AS cor0
----
83
83
83

query I rowsort
SELECT DISTINCT - - ( + col2 ) + + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT - + cor0.col2 * 83 + col2 AS col1 FROM tab1 AS cor0
----
-4428
-4674
-7872

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8076
SELECT DISTINCT - ( col2 ) + col1 * CAST( NULL AS SIGNED ) col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8076
SELECT DISTINCT - ( col2 ) + col1 * CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col2 ) + cor0.col2 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 89 FROM tab1 cor0
----
89
89
89

query I rowsort
SELECT 62 * col2 FROM tab0 AS cor0
----
2046
5084
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8080
SELECT DISTINCT + + CAST( + 75 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
75

skipif mysql # not compatible
query I rowsort label-8080
SELECT DISTINCT + + CAST ( + 75 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
75

query I rowsort
SELECT 89 + col2 AS col1 FROM tab0
----
122
171
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-8082
SELECT 25 DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8082
SELECT 25 / + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + cor0.col0 + + cor0.col2 * + 54 FROM tab2 cor0
----
1465
1482
2131

query I rowsort
SELECT ALL + - col2 + - col1 + + col0 * - 83 FROM tab0 cor0
----
-2111
-3003
-7560

query I rowsort
SELECT ALL - col0 * col0 + + col2 FROM tab0 cor0
----
-1224
-543
-7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-8086
SELECT DISTINCT col0 + + col2 DIV - ( col0 ) AS col2 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-8086
SELECT DISTINCT col0 + + col2 / - ( col0 ) AS col2 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT DISTINCT - + col0 * - col1 + + col1 AS col1 FROM tab1 AS cor0
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 13 col2 FROM tab0, tab0 AS cor0
----
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-8089
SELECT DISTINCT col2 DIV 85 AS col1 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8089
SELECT DISTINCT col2 / 85 AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8090
SELECT - col1 + + col2 DIV ( - col0 ) AS col2 FROM tab0 cor0
----
-87
-91
-97

skipif mysql # not compatible
query I rowsort label-8090
SELECT - col1 + + col2 / ( - col0 ) AS col2 FROM tab0 cor0
----
-87
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8091
SELECT ALL + - col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8091
SELECT ALL + - col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * - 98 AS col1 FROM tab0 cor0
----
-8428
-8918
-9506

query I rowsort
SELECT ALL - + col0 + ( col0 ) * col0 AS col2 FROM tab0 cor0
----
1190
552
7832

query I rowsort
SELECT - col1 * - col2 * + 77 AS col1 FROM tab1 AS cor0
----
108108
43890
96096

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * + ( col2 + - col0 ) col0 FROM tab0 AS cor0
----
-34
-574
297

query I rowsort
SELECT ALL col2 + cor0.col0 * col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL - ( cor0.col1 ) - col0 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort
SELECT ALL - ( + cor0.col1 ) * - CAST ( - 86 AS REAL ) + col0 FROM tab0 cor0
----
-7372
-7737
-8307

query I rowsort
SELECT ALL + - ( - col0 ) + - ( col2 ) * + col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( cor0.col1 ) + - 21 col0 FROM tab2 AS cor0
----
-4
10
38

query I rowsort
SELECT DISTINCT + 54 * col0 + ( + cor0.col2 ) * col1 - + col0 * - col1 * - col1 FROM tab2 AS cor0
----
-17919
-265772
-5512

query I rowsort
SELECT + + 59 AS col0 FROM tab0 AS cor0
----
59
59
59

query I rowsort
SELECT - 27 - col0 * + col2 FROM tab1
----
-189
-3675
-7707

query I rowsort
SELECT + cor0.col1 + - ( - col2 ) FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - cor1.col2 * - 50 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4d7afd25215a425cd08c88d7b6124676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8106
SELECT ALL - CAST( - 54 AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

skipif mysql # not compatible
query I rowsort label-8106
SELECT ALL - CAST ( - 54 AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT DISTINCT + 70 + - tab2.col2 FROM tab2
----
32
43
44

query I rowsort
SELECT + 73 * tab0.col1 AS col1 FROM tab0
----
6278
6643
7081

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to 2e3240e8d3c0c7c6ff427f9572ba362d

query I rowsort
SELECT ALL - cor0.col0 + ( - col1 ) AS col1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-8111
SELECT + cor0.col1 DIV 22 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to eff82df49d5880477456e4901e030e04

skipif mysql # not compatible
query I rowsort label-8111
SELECT + cor0.col1 / 22 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to eff82df49d5880477456e4901e030e04

query I rowsort
SELECT ALL 27 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col2 * - col1 col1 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT - tab2.col0 AS col0 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col2 AS REAL ) AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - + ( + col1 ) AS col2 FROM tab2 cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col0 col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + + ( 51 ) * cor0.col2 + col0 * - ( - cor0.col1 + col1 ) FROM tab2 AS cor0
----
1326
1377
1938

query I rowsort
SELECT - cor0.col0 + col1 * - 12 * + col2 AS col2 FROM tab2 cor0
----
-10051
-18486
-7831

query I rowsort
SELECT + + col2 + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8121
SELECT DISTINCT - - col1 + - col2 * + CAST( NULL AS SIGNED ) * + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8121
SELECT DISTINCT - - col1 + - col2 * + CAST ( NULL AS INTEGER ) * + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 80 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 + 82 * - 18 col1 FROM tab0, tab2 cor0
----
9 values hashing to 00608eb27375096b6c6dcae99430b6ac

query I rowsort
SELECT + 98 * col2 AS col1 FROM tab0 AS cor0
----
3234
8036
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8125
SELECT 34 + col0 DIV - cor0.col2 FROM tab0 AS cor0
----
-1
33
34

skipif mysql # not compatible
query I rowsort label-8125
SELECT 34 + col0 / - cor0.col2 FROM tab0 AS cor0
----
-1
33
34

query I rowsort
SELECT DISTINCT 53 AS col2 FROM tab2, tab1 AS cor0
----
53

query I rowsort
SELECT DISTINCT - + col0 + + 78 AS col1 FROM tab2 AS cor0
----
-1
0
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8128
SELECT - col2 * - CAST( 18 AS SIGNED ) AS col1 FROM tab0 cor0
----
1476
18
594

skipif mysql # not compatible
query I rowsort label-8128
SELECT - col2 * - CAST ( 18 AS INTEGER ) AS col1 FROM tab0 cor0
----
1476
18
594

query I rowsort
SELECT DISTINCT 39 AS col2 FROM tab2, tab2 AS cor0
----
39

query I rowsort
SELECT + ( - col2 ) * + col2 + + col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT - 84 AS col1 FROM tab0 AS cor0
----
-84
-84
-84

query I rowsort
SELECT + col1 * + 66 FROM tab0 AS cor0
----
5676
6006
6402

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab0, tab1 cor0, tab2 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL - 59 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 582c5aa5e5b4fc3f2ea27e7637992d1f

onlyif mysql # use DIV operator for integer division
query I rowsort label-8135
SELECT col0 * ( - col2 * + col2 ) + - ( 80 + col2 ) DIV + col2 AS col1 FROM tab1
----
-207938
-737281
-8750

skipif mysql # not compatible
query I rowsort label-8135
SELECT col0 * ( - col2 * + col2 ) + - ( 80 + col2 ) / + col2 AS col1 FROM tab1
----
-207938
-737281
-8750

query I rowsort
SELECT + col0 * - 40 * 31 + + col0 + - 62 * 7 AS col1 FROM tab0
----
-110705
-30170
-43799

query I rowsort
SELECT 9 * col0 + - col0 * ( + col1 ) * cor0.col2 FROM tab0 AS cor0
----
-3080
-663317
-67896

query I rowsort
SELECT - col0 + + col1 * - col2 FROM tab0 AS cor0
----
-132
-2862
-7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-8139
SELECT - - 59 DIV - col0 + col2 * col0 FROM tab0 AS cor0
----
34
7298
790

skipif mysql # not compatible
query I rowsort label-8139
SELECT - - 59 / - col0 + col2 * col0 FROM tab0 AS cor0
----
34
7298
790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 70 - tab0.col2 * - col2 col0 FROM tab0
----
1159
6794
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-8141
SELECT ( col0 ) * col2 * 85 + - col1 DIV - 61 FROM tab0
----
2976
620331
67321

skipif mysql # not compatible
query I rowsort label-8141
SELECT ( col0 ) * col2 * 85 + - col1 / - 61 FROM tab0
----
2976
620331
67321

query I rowsort
SELECT ALL - col2 * col2 - 9 AS col1 FROM tab2
----
-1453
-685
-738

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - - col1 col0 FROM tab0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-8144
SELECT + 19 DIV + col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-8144
SELECT + 19 / + col0 FROM tab2
----
0
0
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8145
SELECT ALL + col2 * + col1 - CAST( 57 * col2 AS SIGNED ) col0 FROM tab0
----
2788
40
957

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8145
SELECT ALL + col2 * + col1 - CAST ( 57 * col2 AS INTEGER ) col0 FROM tab0
----
2788
40
957

query I rowsort
SELECT - + 67 - cor0.col0 AS col2 FROM tab1 AS cor0
----
-131
-147
-70

query I rowsort
SELECT col0 * + ( - col0 ) + + col1 FROM tab2 cor0
----
-18
-6025
-6224

query I rowsort
SELECT ALL col1 * + col0 + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + col0 * 47 + - col0 AS col1 FROM tab0 cor0
----
1104
1610
4094

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col0 * + col2 col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT col2 * - tab0.col2 * col0 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL - - col2 * - col1 + 35 + + col1 * col2 FROM tab2 AS cor0
----
35
35
35

query I rowsort
SELECT ( + col2 ) * - tab2.col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + col2 - - col2 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-8155
SELECT + col0 DIV 69 + - col0 + - col2 AS col1 FROM tab0 AS cor0
----
-170
-36
-57

skipif mysql # not compatible
query I rowsort label-8155
SELECT + col0 / 69 + - col0 + - col2 AS col1 FROM tab0 AS cor0
----
-170
-36
-57

query I rowsort
SELECT ALL col2 + 35 AS col2 FROM tab0 cor0
----
117
36
68

query I rowsort
SELECT col0 + - col2 * - ( - col1 ) * col0 AS col0 FROM tab2 AS cor0
----
-119574
-50955
-5852

query I rowsort
SELECT + col1 * - 14 AS col2 FROM tab2 AS cor0
----
-238
-434
-826

query I rowsort
SELECT + + col0 + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL 62 * col0 + + col1 FROM tab1 cor0
----
212
3978
4973

query I rowsort
SELECT + ( - col0 ) * - col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL + col2 - + ( col0 ) * + 85 AS col0 FROM tab0 AS cor0
----
-2007
-2974
-7483

query I rowsort
SELECT DISTINCT + + col1 + + col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL + + ( + cor0.col1 ) * cor0.col1 + - col1 * + 47 AS col1 FROM tab2 AS cor0
----
-496
-510
708

query I rowsort
SELECT + col2 * 37 FROM tab0 AS cor0
----
1221
3034
37

query I rowsort
SELECT - - 78 FROM tab1 cor0
----
78
78
78

query I rowsort
SELECT + 72 FROM tab0 cor0
----
72
72
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * - col1 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL 79 * col2 AS col2 FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT - - 64 * col0 - ( + col2 + + col1 ) AS col2 FROM tab2 AS cor0
----
390
4907
5001

query I rowsort
SELECT ALL + - 19 * col2 + - ( - col0 ) AS col0 FROM tab2 AS cor0
----
-416
-506
-643

query I rowsort
SELECT ALL 62 AS col2 FROM tab2
----
62
62
62

query I rowsort
SELECT ALL + 72 FROM tab0, tab1 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT DISTINCT cor0.col1 * + col2 * + col1 AS col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-8175
SELECT + + col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-8175
SELECT + + col0 / - col1 AS col2 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT DISTINCT - ( + cor0.col1 ) * - col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - 53 AS col1 FROM tab1 AS cor0
----
-53
-53
-53

query I rowsort
SELECT DISTINCT + + 56 AS col2 FROM tab0 AS cor0
----
56

query I rowsort
SELECT ALL ( - col1 ) * - 7 AS col2 FROM tab2 AS cor0
----
119
217
413

query I rowsort
SELECT ALL + + 48 + - col0 * + col1 AS col1 FROM tab1 AS cor0
----
-30
-592
-992

query I rowsort
SELECT ALL 54 * - col2 FROM tab2
----
-1404
-1458
-2052

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8182
SELECT tab1.col2 * ( - col0 ) - - CAST( - col0 AS SIGNED ) * + col1 AS col0 FROM tab1
----
-240
-4288
-8720

skipif mysql # not compatible
query I rowsort label-8182
SELECT tab1.col2 * ( - col0 ) - - CAST ( - col0 AS INTEGER ) * + col1 AS col0 FROM tab1
----
-240
-4288
-8720

query I rowsort
SELECT ALL - cor0.col2 * col1 * col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + 40 * - cor0.col2 + col0 * - col1 AS col2 FROM tab2 AS cor0
----
-1297
-2863
-5642

query I rowsort
SELECT + - 25 * - cor1.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 486127fb97b979df6fedac3928625e8b

onlyif mysql # use DIV operator for integer division
query I rowsort label-8186
SELECT 12 DIV - 53 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-8186
SELECT 12 / - 53 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - 87 + col1 FROM tab1 AS cor0
----
-61
-74
-77

query I rowsort
SELECT DISTINCT + ( - tab0.col0 ) FROM tab0, tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8189
SELECT col1 * + CAST( NULL AS SIGNED ) * col1 - + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8189
SELECT col1 * + CAST ( NULL AS INTEGER ) * col1 - + col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 + + 8 FROM tab1 AS cor0
----
11
72
88

query I rowsort
SELECT - cor0.col2 + - col0 * col1 + col2 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - 66 * col1 FROM tab0 AS cor0
----
-5676
-6006
-6402

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + + col2 col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT tab2.col2 * + 95 + - tab2.col0 AS col2 FROM tab2
----
2392
2558
3531

query I rowsort
SELECT DISTINCT 33 * 2 AS col2 FROM tab1, tab2 AS cor0
----
66

query I rowsort
SELECT DISTINCT tab1.col1 + - col2 AS col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT - ( + ( + col2 ) ) FROM tab1
----
-54
-57
-96

query I rowsort
SELECT tab1.col1 * + col2 + - col1 * + col2 * + tab1.col2 FROM tab1
----
-118560
-31920
-74412

query I rowsort
SELECT + ( - cor0.col1 ) FROM tab1, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT ALL tab0.col0 + + tab0.col0 FROM tab0, tab1 cor0
----
9 values hashing to b8cf3a0d946da15d11bb8abf87d58a6b

query I rowsort
SELECT DISTINCT + + 14 + col2 * - col0 AS col2 FROM tab0 AS cor0
----
-21
-7284
-778

query I rowsort
SELECT ALL - ( + 58 ) * col0 AS col1 FROM tab1 AS cor0
----
-174
-3712
-4640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8203
SELECT CAST( - cor0.col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-8203
SELECT CAST ( - cor0.col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + - 82 AS col2 FROM tab1 AS cor0
----
-82

query I rowsort
SELECT ALL - - col0 * 52 + col2 * - cor0.col1 * + col2 AS col2 FROM tab2 AS cor0
----
-20440
-22235
-35828

query I rowsort
SELECT - - col2 * - col1 * - col0 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL - - col0 * + col0 + cor0.col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT ALL - cor0.col0 + col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + col1 + 18 * - col1 AS col0 FROM tab2 AS cor0
----
-1003
-289
-527

query I rowsort
SELECT + - cor0.col2 + - col1 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8211
SELECT - CAST( - col0 AS SIGNED ) col1 FROM tab2 cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8211
SELECT - CAST ( - col0 AS INTEGER ) col1 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT + cor0.col1 - - col0 * col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0, tab0 cor1, tab2 AS cor2
----
972 values hashing to e486ce227b61d9db6f8414f9d6361094

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8214
SELECT ALL ( + col0 ) * - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8214
SELECT ALL ( + col0 ) * - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 23 FROM tab2 cor0
----
-23
-23
-23

query I rowsort
SELECT DISTINCT - 79 FROM tab1 cor0
----
-79

query I rowsort
SELECT - ( + col0 ) AS col1 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8218
SELECT + col1 * + col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8218
SELECT + col1 * + col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 90 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
90

query I rowsort
SELECT 74 * 45 + col2 + tab1.col2 FROM tab1
----
3438
3444
3522

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8221
SELECT + CAST( NULL AS SIGNED ) FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8221
SELECT + CAST ( NULL AS INTEGER ) FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + col0 * col1 + col2 * + col0 FROM tab2
----
406
4345
6630

query I rowsort
SELECT col1 * col2 * - 57 FROM tab0
----
-161766
-425334
-5529

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 23 col1 FROM tab2
----
23
23
23

query I rowsort
SELECT DISTINCT 46 + cor0.col2 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
128
47
79

query I rowsort
SELECT col0 + - 84 FROM tab2 cor0
----
-5
-6
-77

query I rowsort
SELECT - + col2 * + ( + col1 ) AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col2 * 90 AS col2 FROM tab2 AS cor0
----
-2340
-2430
-3420

query I rowsort
SELECT + 53 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 70 * - tab2.col0 * 26 col1 FROM tab2
----
12740
141960
143780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8231
SELECT cor0.col1 + CAST( NULL AS SIGNED ) FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8231
SELECT cor0.col1 + CAST ( NULL AS INTEGER ) FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - col2 + 70 * col0 FROM tab1 AS cor0
----
156
4423
5504

onlyif mysql # use DIV operator for integer division
query I rowsort label-8233
SELECT + 47 DIV col2 FROM tab0
----
0
1
47

skipif mysql # not compatible
query I rowsort label-8233
SELECT + 47 / col2 FROM tab0
----
0
1
47

query I rowsort
SELECT ALL - col0 + col2 * col0 AS col2 FROM tab0
----
0
7209
768

query I rowsort
SELECT 16 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT 1 * + ( col0 ) FROM tab0
----
24
35
89

query I rowsort
SELECT ALL 32 + col0 AS col2 FROM tab1
----
112
35
96

query I rowsort
SELECT - 55 - + col0 AS col0 FROM tab1 AS cor0
----
-119
-135
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 55 col2 FROM tab0 AS cor0
----
141
146
152

query I rowsort
SELECT DISTINCT + + col2 + 4 FROM tab0 AS cor0
----
37
5
86

query I rowsort
SELECT col0 * - col0 + col1 AS col0 FROM tab2 cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT - col2 + 66 * col0 AS col0 FROM tab2 AS cor0
----
435
5122
5176

query I rowsort
SELECT ALL - 33 * - col0 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT - col0 * - 24 AS col1 FROM tab2
----
168
1872
1896

query I rowsort
SELECT ( col0 * + tab0.col1 ) FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + - ( col1 ) * + 45 FROM tab1 cor0
----
-1170
-450
-585

query I rowsort
SELECT ALL - - 4 + col1 AS col2 FROM tab0 AS cor0
----
101
90
95

query I rowsort
SELECT + - col0 + - col2 + - ( - col0 ) FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( + col0 ) col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8250
SELECT - + col1 * col0 DIV - 43 - ( + col1 + 8 ) FROM tab1 AS cor0
----
-33
-4
3

skipif mysql # not compatible
query I rowsort label-8250
SELECT - + col1 * col0 / - 43 - ( + col1 + 8 ) FROM tab1 AS cor0
----
-33
-4
3

query I rowsort
SELECT + 27 * - cor0.col2 - + 13 FROM tab0 AS cor0
----
-2227
-40
-904

query I rowsort
SELECT - + 32 + col2 FROM tab0 AS cor0
----
-31
1
50

query I rowsort
SELECT cor0.col0 * - col1 * - 52 FROM tab0 AS cor0
----
107328
176540
421148

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 56 * + col1 col1 FROM tab1 AS cor0
----
1456
560
728

query I rowsort
SELECT DISTINCT - col2 - tab0.col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT ALL - 58 * col2 FROM tab1 AS cor0
----
-3132
-3306
-5568

query I rowsort
SELECT ALL col0 AS col1 FROM tab1 WHERE NOT NULL NOT IN ( - col0 )
----

query I rowsort
SELECT ALL - 56 * - col1 - + 64 * + col2 FROM tab0
----
-152
2704
5368

query I rowsort
SELECT 91 + col0 * col0 - 42 AS col0 FROM tab2
----
6133
6290
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8260
SELECT col0 * tab2.col2 DIV 26 FROM tab2
----
115
7
78

skipif mysql # not compatible
query I rowsort label-8260
SELECT col0 * tab2.col2 / 26 FROM tab2
----
115
7
78

query I rowsort
SELECT ALL + col2 - col2 * col0 AS col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT 2 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 6d1be3904d6870ba21bc766b979d1110

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col1 col1 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8264
SELECT - tab0.col0 DIV - col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8264
SELECT - tab0.col0 / - col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 / col1 + col0 FROM tab2 WHERE col0 * tab2.col1 + col1 NOT BETWEEN + col1 * - col2 AND NULL
----

query I rowsort
SELECT + col0 * col0 + col2 + col0 * col1 AS col0 FROM tab2
----
10712
293
7622

query I rowsort
SELECT DISTINCT col1 + - col2 - col1 FROM tab0 WHERE NULL NOT IN ( - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col1 col1 FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8269
SELECT col2 DIV + col0 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-8269
SELECT col2 / + col0 FROM tab1 cor0
----
0
1
18

query I rowsort
SELECT - col1 * + col2 * col1 AS col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT + col1 * col0 + - col0 FROM tab2 AS cor0 WHERE NOT + col0 * + col2 + col1 < ( NULL )
----

query I rowsort
SELECT - tab1.col0 * + col1 AS col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + col1 - - tab2.col1 * col0 AS col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL col2 FROM tab2 WHERE NULL IN ( col2 / + col2 )
----

query I rowsort
SELECT col1 + + col2 + tab2.col1 * + tab2.col0 AS col2 FROM tab2
----
1398
275
4687

query I rowsort
SELECT col2 - - col1 * col2 FROM tab0
----
2871
7544
98

query III rowsort
SELECT * FROM tab1 WHERE col0 * + col1 < + col1
----

query I rowsort
SELECT ALL col2 * - col1 AS col1 FROM tab1 WHERE NOT NULL = NULL
----

query I rowsort
SELECT - col2 + + col2 * - col0 FROM tab0
----
-36
-7380
-825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8280
SELECT + CAST( NULL AS SIGNED ) * - col1 + + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8280
SELECT + CAST ( NULL AS INTEGER ) * - col1 + + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8281
SELECT DISTINCT + - col1 + col2 DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8281
SELECT DISTINCT + - col1 + col2 / cor0.col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + ( + col1 ) + + col0 FROM tab2
----
137
38
96

query I rowsort
SELECT 13 AS col1 FROM tab1
----
13
13
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-8284
SELECT tab1.col0 + col0 DIV tab1.col2 col1 FROM tab1
----
3
65
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8284
SELECT tab1.col0 + col0 / tab1.col2 col1 FROM tab1
----
3
65
80

query I rowsort
SELECT ALL + 68 + cor0.col0 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 83057b1e970711dce5e1a947d65526be

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8286
SELECT + CAST( + col1 AS SIGNED ) + + col1 FROM tab2 cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-8286
SELECT + CAST ( + col1 AS INTEGER ) + + col1 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT 19 FROM tab0, tab2 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8288
SELECT DISTINCT - CAST( + col1 AS SIGNED ) + - col0 * - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8288
SELECT DISTINCT - CAST ( + col1 AS INTEGER ) + - col0 * - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL + ( col0 ) + - cor0.col1 * - 58 FROM tab1 AS cor0
----
1511
644
834

query I rowsort
SELECT DISTINCT col2 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ( - cor0.col1 ) * col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - + col1 * - 57 FROM tab0 AS cor0
----
4902
5187
5529

query I rowsort
SELECT ALL + - 57 * col1 + - col0 FROM tab0 AS cor0
----
-4926
-5276
-5564

query I rowsort
SELECT ALL - + 24 FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT ( col2 ) + col0 * 95 FROM tab0 AS cor0
----
2313
3326
8537

query I rowsort
SELECT DISTINCT - 25 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
1350
1425
2400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8297
SELECT ALL + + col0 + + col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8297
SELECT ALL + + col0 + + col2 * + 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-8298
SELECT + 78 DIV + col1 AS col0 FROM tab1 cor0
----
3
6
7

skipif mysql # not compatible
query I rowsort label-8298
SELECT + 78 / + col1 AS col0 FROM tab1 cor0
----
3
6
7

query I rowsort
SELECT ALL col0 * - col1 + - col0 * + col0 AS col2 FROM tab1 AS cor0
----
-4736
-7440
-87

query I rowsort
SELECT ( - 85 ) * col0 + + 24 FROM tab1
----
-231
-5416
-6776

query I rowsort
SELECT ALL + - col1 * ( - col2 ) * col1 + col0 FROM tab1 AS cor0
----
16304
36507
5764

query I rowsort
SELECT DISTINCT - col1 - 92 AS col1 FROM tab2 AS cor0
----
-109
-123
-151

query I rowsort
SELECT col0 * ( + col1 * + col2 ) - - col2 * - cor0.col0 FROM tab1 cor0
----
32832
4050
92160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + + col0 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + cor0.col0 * ( cor0.col1 ) FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col2 * col0 * + 79 - cor0.col0 AS col2 FROM tab0 AS cor0
----
2730
576453
62544

query I rowsort
SELECT ALL + cor0.col2 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col1 + 59 FROM tab2 AS cor0
----
0
28
42

query I rowsort
SELECT DISTINCT + cor0.col0 * 92 - ( + cor0.col0 ) * - ( 44 * + col0 ) FROM tab0 AS cor0
----
27552
356712
57120

query I rowsort
SELECT DISTINCT + col0 * 54 + + col0 AS col2 FROM tab2 AS cor0
----
385
4290
4345

query I rowsort
SELECT - 46 * - col1 FROM tab2
----
1426
2714
782

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8312
SELECT DISTINCT + col0 * + CAST( ( - col2 ) AS SIGNED ) FROM tab0 cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-8312
SELECT DISTINCT + col0 * + CAST ( ( - col2 ) AS INTEGER ) FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL col1 + + 55 AS col2 FROM tab0 AS cor0
----
141
146
152

query I rowsort
SELECT DISTINCT + col2 + + ( - col1 ) FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + + cor0.col0 * ( + col1 ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - tab0.col2 * 46 AS col0 FROM tab0
----
-1518
-3772
-46

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2, tab1 AS cor3
----
3645 values hashing to def82b52aa9c83b91991d7d043276abe

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8318
SELECT DISTINCT col0 * + CAST( col0 AS SIGNED ) + - col1 * - col1 FROM tab2
----
1010
6530
9565

skipif mysql # not compatible
query I rowsort label-8318
SELECT DISTINCT col0 * + CAST ( col0 AS INTEGER ) + - col1 * - col1 FROM tab2
----
1010
6530
9565

query I rowsort
SELECT - 36 + tab1.col1 FROM tab1
----
-10
-23
-26

query I rowsort
SELECT - + cor0.col0 * col2 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ( + cor0.col2 ) + + cor0.col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL 21 * + tab1.col0 * col2 FROM tab1
----
161280
3402
76608

query I rowsort
SELECT tab2.col1 * - col2 + - col0 AS col0 FROM tab2
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-8324
SELECT DISTINCT ( col1 ) DIV - col2 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-8324
SELECT DISTINCT ( col1 ) / - col2 FROM tab0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT - ( col1 * + col2 ) FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - tab1.col2 * + tab1.col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + 70 * - cor0.col1 FROM tab0 AS cor0
----
-6020
-6370
-6790

query I rowsort
SELECT DISTINCT - + col2 + col0 * col0 AS col0 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT + col1 + col1 * + col0 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - 1 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT + col1 * col0 - col0 * - col0 AS col2 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT DISTINCT col2 * ( - col1 ) + cor0.col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col1 + col2 * col0 col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT col0 * - 32 - + 36 FROM tab0 cor0
----
-1156
-2884
-804

onlyif mysql # use DIV operator for integer division
query I rowsort label-8335
SELECT DISTINCT - col2 + + 78 DIV + 25 AS col0 FROM tab1 AS cor0
----
-51
-54
-93

skipif mysql # not compatible
query I rowsort label-8335
SELECT DISTINCT - col2 + + 78 / + 25 AS col0 FROM tab1 AS cor0
----
-51
-54
-93

query I rowsort
SELECT + 40 * - col0 FROM tab1 cor0
----
-120
-2560
-3200

query I rowsort
SELECT - - 92 + col0 AS col2 FROM tab1 AS cor0
----
156
172
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8338
SELECT ALL + CAST( NULL AS SIGNED ) + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8338
SELECT ALL + CAST ( NULL AS INTEGER ) + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 54 * 29 AS col1 FROM tab1 AS cor0
----
1566

onlyif mysql # use DIV operator for integer division
query I rowsort label-8340
SELECT + cor0.col2 DIV 59 + + col0 * + col1 FROM tab0 cor0
----
2064
3395
8100

skipif mysql # not compatible
query I rowsort label-8340
SELECT + cor0.col2 / 59 + + col0 * + col1 FROM tab0 cor0
----
2064
3395
8100

query I rowsort
SELECT ALL cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0, tab0 AS cor2
----
243 values hashing to 455e4df3bf7b0fa681c56e89df1a761f

query I rowsort
SELECT DISTINCT + col2 + + ( + col0 ) * + col1 + col1 AS col2 FROM tab0
----
2183
3493
8272

query I rowsort
SELECT DISTINCT col2 + 15 + col0 AS col2 FROM tab1
----
136
191
72

query I rowsort
SELECT - col1 + - col2 * col1 * + col0 FROM tab0 cor0
----
-3492
-664209
-68198

query I rowsort
SELECT - col1 * col0 + - col1 AS col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT + col1 - col2 FROM tab2 AS cor0 WHERE NOT ( NULL ) < NULL OR ( NULL ) > ( - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8347
SELECT - col1 + - col0 * + tab0.col2 * - col0 - + col1 * - col1 DIV col1 FROM tab0
----
1225
19008
649522

skipif mysql # not compatible
query I rowsort label-8347
SELECT - col1 + - col0 * + tab0.col2 * - col0 - + col1 * - col1 / col1 FROM tab0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 - - col2 * + tab0.col2 * col0 col1 FROM tab0
----
26169
36
598518

query I rowsort
SELECT + cor0.col2 * + cor0.col0 * col0 + - col2 * col1 * - col0 AS col2 FROM tab1 AS cor0
----
269952
4698
714240

query I rowsort
SELECT cor0.col0 - + col1 * col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT cor0.col0 * col2 + col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - col2 * col0 + - cor0.col0 * col0 FROM tab1 AS cor0
----
-14080
-171
-7744

query I rowsort
SELECT DISTINCT col1 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - + col2 * col2 AS col0 FROM tab0 cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-8355
SELECT ALL cor0.col1 DIV - cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cbfa8de8feb212fe31a1528b9e5261db

skipif mysql # not compatible
query I rowsort label-8355
SELECT ALL cor0.col1 / - cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cbfa8de8feb212fe31a1528b9e5261db

query I rowsort
SELECT ALL col0 * col0 * + col0 FROM tab0
----
13824
42875
704969

onlyif mysql # use DIV operator for integer division
query I rowsort label-8357
SELECT ALL col2 + col1 DIV - col2 FROM tab0 cor0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-8357
SELECT ALL col2 + col1 / - col2 FROM tab0 cor0
----
-96
31
81

query I rowsort
SELECT ALL - col0 + + col2 AS col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT + col1 * - col0 - col0 AS col0 FROM tab0
----
-2088
-3430
-8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col2 + - col1 col2 FROM tab2
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-8361
SELECT + col1 * tab1.col2 DIV - col1 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-8361
SELECT + col1 * tab1.col2 / - col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL cor0.col0 * col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - col1 * - ( + 26 + - cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-155
-1947
153

query I rowsort
SELECT DISTINCT col1 * 79 FROM tab2 cor0
----
1343
2449
4661

query I rowsort
SELECT + + cor1.col0 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab2, tab0 AS cor2
----
243 values hashing to ee8b23a58dda2d92e14ed437e06ed8d2

query I rowsort
SELECT ALL col1 * - ( + 85 ) AS col0 FROM tab2 cor0
----
-1445
-2635
-5015

query I rowsort
SELECT col2 + 45 + col2 AS col0 FROM tab1 AS cor0
----
153
159
237

onlyif mysql # use DIV operator for integer division
query I rowsort label-8368
SELECT ALL 54 DIV 24 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif mysql # not compatible
query I rowsort label-8368
SELECT ALL 54 / 24 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT + col0 + 6 AS col0 FROM tab2
----
13
84
85

query I rowsort
SELECT - 49 FROM tab1, tab2 cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT DISTINCT + + col1 * - 62 + cor0.col0 FROM tab1 AS cor0
----
-1609
-556
-726

query I rowsort
SELECT DISTINCT - ( + 24 ) + col0 + + 11 AS col0 FROM tab0 AS cor0
----
11
22
76

query I rowsort
SELECT col2 + + col0 * - col2 AS col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT - 63 * + cor0.col2 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 72326fd2073505f6b210f8597713fe8d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8375
SELECT + CAST( NULL AS SIGNED ) * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8375
SELECT + CAST ( NULL AS INTEGER ) * col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 8 ) AS col1 FROM tab2
----
-8
-8
-8

query I rowsort
SELECT + - col2 + - col1 + - ( - col0 ) FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT - + cor0.col2 * col1 + + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + col2 + - col1 + + col2 FROM tab0 AS cor0
----
-20
-95
73

query I rowsort
SELECT DISTINCT - + 65 * col1 AS col2 FROM tab1 AS cor0
----
-1690
-650
-845

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8381
SELECT - CAST( - 63 AS SIGNED ) * + col0 - tab2.col0 FROM tab2
----
434
4836
4898

skipif mysql # not compatible
query I rowsort label-8381
SELECT - CAST ( - 63 AS INTEGER ) * + col0 - tab2.col0 FROM tab2
----
434
4836
4898

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8382
SELECT - ( 83 ) * col2 * - CAST( NULL AS SIGNED ) - tab2.col2 * col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8382
SELECT - ( 83 ) * col2 * - CAST ( NULL AS INTEGER ) - tab2.col2 * col0 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( col0 + col1 ) FROM tab0
----
110
132
180

query I rowsort
SELECT 70 * col1 AS col0 FROM tab2
----
1190
2170
4130

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8385
SELECT + CAST( - 18 + col1 AS SIGNED ) * col2 AS col2 FROM tab1
----
-456
-480
432

skipif mysql # not compatible
query I rowsort label-8385
SELECT + CAST ( - 18 + col1 AS INTEGER ) * col2 AS col2 FROM tab1
----
-456
-480
432

query I rowsort
SELECT ALL - 82 AS col1 FROM tab0
----
-82
-82
-82

query I rowsort
SELECT ALL 88 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT DISTINCT 59 * - col2 + col0 AS col2 FROM tab0
----
-1923
-24
-4749

query I rowsort
SELECT + tab2.col2 * + 35 FROM tab2, tab2 AS cor0
----
9 values hashing to af4a3869a089cb943e738c530ee1a2b9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8390
SELECT ALL + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8390
SELECT ALL + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - 39 * + col2 FROM tab2 cor0
----
-1014
-1053
-1482

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col1 + + col2 col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col1 + - col0 + 25 * - cor0.col0 FROM tab0 AS cor0
----
-2223
-538
-813

query I rowsort
SELECT - ( - col2 ) * ( + col2 ) + + col1 + + col2 FROM tab2 AS cor0
----
1499
761
787

query I rowsort
SELECT 37 + cor0.col2 + - col0 AS col1 FROM tab1 cor0
----
30
53
88

query I rowsort
SELECT ALL col2 + + col1 * col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT col1 + col1 * col1 + - col2 AS col1 FROM tab0
----
7449
8290
9505

onlyif mysql # use DIV operator for integer division
query I rowsort label-8398
SELECT ALL col2 DIV col2 + - tab1.col2 + col1 AS col2 FROM tab1
----
-27
-46
-82

skipif mysql # not compatible
query I rowsort label-8398
SELECT ALL col2 / col2 + - tab1.col2 + col1 AS col2 FROM tab1
----
-27
-46
-82

query I rowsort
SELECT DISTINCT - col1 + - col1 * col2 AS col0 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT + + ( - col0 ) - - 72 FROM tab0 AS cor0
----
-17
37
48

query I rowsort
SELECT DISTINCT 0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + cor2.col2 AS col1 FROM tab2, tab0 AS cor0, tab1 cor1, tab2 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL - + 11 FROM tab0 cor0
----
-11
-11
-11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8404
SELECT DISTINCT 78 * - col1 + - CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-8404
SELECT DISTINCT 78 * - col1 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL

query I rowsort
SELECT 75 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT + col2 * + 1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL col1 * col0 + col2 * - col2 AS col1 FROM tab1 AS cor0
----
-2609
-2838
-8176

onlyif mysql # use DIV operator for integer division
query I rowsort label-8408
SELECT ALL - col1 DIV - 26 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8408
SELECT ALL - col1 / - 26 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8409
SELECT ALL + - col1 + - 54 DIV col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8409
SELECT ALL + - col1 + - 54 / col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8410
SELECT - col1 DIV + 25 + - ( - col0 ) AS col0 FROM tab2 AS cor0
----
6
76
79

skipif mysql # not compatible
query I rowsort label-8410
SELECT - col1 / + 25 + - ( - col0 ) AS col0 FROM tab2 AS cor0
----
6
76
79

query I rowsort
SELECT ALL - cor0.col2 * col2 + col2 AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT ALL - col2 + + 48 * 18 FROM tab0 AS cor0
----
782
831
863

onlyif mysql # use DIV operator for integer division
query I rowsort label-8413
SELECT ALL - col1 DIV + cor0.col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8413
SELECT ALL - col1 / + cor0.col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + cor0.col0 + + 42 FROM tab1 AS cor0
----
106
122
45

query I rowsort
SELECT + cor0.col2 * 95 + col1 + - col0 AS col1 FROM tab0 AS cor0
----
157
3197
7792

onlyif mysql # use DIV operator for integer division
query I rowsort label-8416
SELECT DISTINCT + col1 DIV - 66 AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8416
SELECT DISTINCT + col1 / - 66 AS col2 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL - col0 * ( + col2 ) + cor0.col0 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT + col1 * + 36 + col1 * + col1 FROM tab2 AS cor0
----
2077
5605
901

query I rowsort
SELECT ALL + + col0 * + col1 + 97 AS col0 FROM tab1 AS cor0
----
1137
175
737

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
3645 values hashing to 5acb69cde71208fe580e10b8b669428e

query I rowsort
SELECT + cor0.col2 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - ( col2 ) + col0 * col1 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8423
SELECT + CAST( NULL AS SIGNED ) + + 85 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8423
SELECT + CAST ( NULL AS INTEGER ) + + 85 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col1 ) + col1 - col0 FROM tab2
----
-45
40
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 58 + - col1 col1 FROM tab2
----
-1
27
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8426
SELECT DISTINCT - CAST( col0 AS SIGNED ) * - cor0.col1 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-8426
SELECT DISTINCT - CAST ( col0 AS INTEGER ) * - cor0.col1 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 + col0 col1 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 14 * col1 - - col1 col1 FROM tab1 AS cor0
----
150
195
390

query I rowsort
SELECT - + ( col1 ) * col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + 28 - col1 FROM tab1 AS cor0
----
15
18
2

query I rowsort
SELECT ALL col1 + col0 * col0 AS col0 FROM tab2 cor0
----
6143
6258
80

query I rowsort
SELECT ALL 64 * + col2 * col2 AS col2 FROM tab0 AS cor0
----
430336
64
69696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8433
SELECT DISTINCT CAST( NULL AS SIGNED ) + col2 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8433
SELECT DISTINCT CAST ( NULL AS INTEGER ) + col2 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - ( col2 ) * col0 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT + 13 * col1 FROM tab2 cor0
----
221
403
767

onlyif mysql # use DIV operator for integer division
query I rowsort label-8436
SELECT + col0 DIV + col2 + + 26 FROM tab1 AS cor0
----
26
26
27

skipif mysql # not compatible
query I rowsort label-8436
SELECT + col0 / + col2 + + 26 FROM tab1 AS cor0
----
26
26
27

query I rowsort
SELECT ALL cor0.col0 * + cor0.col2 + 15 + col0 AS col1 FROM tab0 cor0
----
7402
831
85

query I rowsort
SELECT col0 + tab0.col0 * - col2 + - col1 AS col0 FROM tab0
----
-7300
-854
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 41 - col2 col2 FROM tab1 AS cor0
----
2160
2280
3840

query I rowsort
SELECT col1 * ( - col0 * - col2 ) + + ( + col2 ) * - col0 FROM tab1 AS cor0
----
32832
4050
92160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8441
SELECT ALL + col0 * CAST( NULL AS SIGNED ) + 93 / col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8441
SELECT ALL + col0 * CAST ( NULL AS INTEGER ) + 93 / col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8442
SELECT col1 DIV + ( + col1 ) FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8442
SELECT col1 / + ( + col1 ) FROM tab1
----
1
1
1

query I rowsort
SELECT tab0.col1 * ( - col0 ) AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col2 + 0 AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL + col1 + 49 + - col1 * col1 AS col1 FROM tab2
----
-223
-3373
-881

query I rowsort
SELECT ALL tab0.col0 * - 2 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to f8529b710dc613df309e90c94e8a2770

query I rowsort
SELECT ( tab1.col0 ) + 59 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 1d386c637527e4dccb8028d8af9c2f7a

query I rowsort
SELECT DISTINCT 61 * col0 + - col0 FROM tab2 AS cor0
----
420
4680
4740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 27 - col2 col2 FROM tab1 cor0
----
-27
-30
-69

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col0 AS REAL ) * col2 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT + col1 + ( col1 ) AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ALL + col2 * cor0.col2 + col1 + - cor0.col1 * col0 FROM tab0 AS cor0
----
-1284
-3297
-889

query I rowsort
SELECT DISTINCT + 72 * col2 + col1 FROM tab2 AS cor0
----
1931
1975
2753

onlyif mysql # use DIV operator for integer division
query I rowsort label-8454
SELECT cor0.col1 + - cor0.col1 DIV col2 AS col1 FROM tab0 AS cor0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-8454
SELECT cor0.col1 + - cor0.col1 / col2 AS col1 FROM tab0 AS cor0
----
0
84
90

query I rowsort
SELECT + + col1 * col2 + col0 AS col0 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT ALL - cor0.col1 - - 84 AS col1 FROM tab2 AS cor0
----
25
53
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT - ( + col0 ) + col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 * - tab0.col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - 9 * col1 AS col1 FROM tab0
----
-774
-819
-873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor1.col1 col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

onlyif mysql # use DIV operator for integer division
query I rowsort label-8462
SELECT cor0.col0 * col2 + cor0.col1 * col1 DIV col0 - + cor0.col1 FROM tab1 cor0
----
361
3639
7669

skipif mysql # not compatible
query I rowsort label-8462
SELECT cor0.col0 * col2 + cor0.col1 * col1 / col0 - + cor0.col1 FROM tab1 cor0
----
361
3639
7669

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8463
SELECT ALL - col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8463
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8464
SELECT - col0 / CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8464
SELECT - col0 / CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8465
SELECT ALL - cor0.col0 + cor0.col1 DIV + col0 FROM tab2 AS cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-8465
SELECT ALL - cor0.col0 + cor0.col1 / + col0 FROM tab2 AS cor0
----
-3
-78
-79

query I rowsort
SELECT - col1 * 78 + cor0.col1 * - col1 - col1 AS col1 FROM tab1 cor0
----
-1196
-2730
-890

query I rowsort
SELECT ALL + - col1 + + 27 FROM tab1 AS cor0
----
1
14
17

query I rowsort
SELECT - col1 * + ( + 76 ) FROM tab2 AS cor0
----
-1292
-2356
-4484

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0, tab1 AS cor2, tab2
----
13122 values hashing to 28876ec2f59616c599f06373bf36fe0d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8470
SELECT + cor0.col2 * - CAST( + col1 AS SIGNED ) * - cor0.col2 AS col2 FROM tab0 AS cor0
----
611884
93654
97

skipif mysql # not compatible
query I rowsort label-8470
SELECT + cor0.col2 * - CAST ( + col1 AS INTEGER ) * - cor0.col2 AS col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT 25 FROM tab2 AS cor0 CROSS JOIN tab2, tab1 cor1, tab0 AS cor2
----
81 values hashing to 68fc0eecd4f434589f3ec576bbd0c540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - ( + col2 ) * + col0 * - 73 AS col1 FROM tab0 AS cor0
----
2555
532754
57816

query I rowsort
SELECT DISTINCT - 4 FROM tab1, tab2 AS cor0
----
-4

query I rowsort
SELECT 12 * + 76 AS col0 FROM tab1 AS cor0
----
912
912
912

onlyif mysql # use DIV operator for integer division
query I rowsort label-8476
SELECT ALL + - col0 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8476
SELECT ALL + - col0 / col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + col0 * + 8 AS col0 FROM tab0 AS cor0
----
-192
-280
-712

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * 65 col2 FROM tab1 AS cor0
----
195
4160
5200

query I rowsort
SELECT ALL - 13 * - col2 AS col1 FROM tab1 AS cor0
----
1248
702
741

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 cor0, tab2 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 6a08afba67ce3272fad6d766e76c67f0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8481
SELECT ALL 93 / cor0.col0 + CAST( NULL AS SIGNED ) + - 93 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8481
SELECT ALL 93 / cor0.col0 + CAST ( NULL AS INTEGER ) + - 93 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - 46 AS REAL ) FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col1 col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - cor0.col1 + + col2 * 88 AS col0 FROM tab2 AS cor0
----
2229
2345
3327

query I rowsort
SELECT + - 69 * col2 AS col1 FROM tab0 cor0
----
-2277
-5658
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col1 col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT 7 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT + + 68 AS col1 FROM tab1 AS cor0
----
68
68
68

query I rowsort
SELECT DISTINCT - col0 + 60 FROM tab0 AS cor0
----
-29
25
36

query I rowsort
SELECT ALL + 29 * - col0 + + col2 FROM tab1 cor0
----
-1799
-2224
-33

query I rowsort
SELECT ALL + 72 AS col0 FROM tab1 AS cor0
----
72
72
72

query I rowsort
SELECT + - col2 + - col0 * - col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT ALL - ( - cor0.col2 ) AS col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8494
SELECT + col2 * + col1 DIV + col1 + - col2 + - 78 * col0 AS col1 FROM tab0 AS cor0
----
-1872
-2730
-6942

skipif mysql # not compatible
query I rowsort label-8494
SELECT + col2 * + col1 / + col1 + - col2 + - 78 * col0 AS col1 FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT DISTINCT + + 45 FROM tab1 AS cor0
----
45

query I rowsort
SELECT cor0.col2 * - col1 + - col1 AS col2 FROM tab2 cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-8497
SELECT - ( col1 ) DIV - col0 + + col2 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-8497
SELECT - ( col1 ) / - col0 + + col2 FROM tab1 AS cor0
----
57
62
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 - + col1 * + col0 col0 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT 7 AS col1 FROM tab2 AS cor0
----
7

query I rowsort
SELECT DISTINCT - 93 AS col1 FROM tab1 AS cor0
----
-93

query I rowsort
SELECT ALL + col0 * col0 + ( - col2 ) * + col0 FROM tab2 AS cor0
----
-140
3239
4056

query I rowsort
SELECT + 50 * 7 AS col2 FROM tab1
----
350
350
350

query I rowsort
SELECT ALL + ( col0 ) * col2 + - 56 FROM tab0
----
-21
7242
736

query I rowsort
SELECT ALL + col1 + + cor0.col2 * 96 FROM tab1 AS cor0
----
5210
5482
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 + + col0 col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8506
SELECT DISTINCT col2 * cor0.col0 + - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8506
SELECT DISTINCT col2 * cor0.col0 + - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

query I rowsort
SELECT - cor0.col0 * col1 - col2 AS col1 FROM tab0 cor0
----
-2097
-3396
-8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 60 col1 FROM tab2, tab2 cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT DISTINCT tab2.col0 + + tab2.col1 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL - col1 * tab0.col1 + ( col0 ) AS col0 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT - col1 * + col1 - - col1 AS col1 FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL + col2 + + col2 * 23 FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT DISTINCT + ( + 93 ) + col1 * + 28 + col0 * + col1 FROM tab1 AS cor0
----
1013
1497
899

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8514
SELECT + col0 * - CAST( NULL AS SIGNED ) * + 49 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8514
SELECT + col0 * - CAST ( NULL AS INTEGER ) * + 49 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + 39 FROM tab0
----
1287
3198
39

query I rowsort
SELECT DISTINCT - col1 - 71 FROM tab0
----
-157
-162
-168

query I rowsort
SELECT ALL - + 33 * - 94 AS col1 FROM tab0 AS cor0
----
3102
3102
3102

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8518
SELECT DISTINCT + + CAST( 66 AS SIGNED ) * col2 + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8518
SELECT DISTINCT + + CAST ( 66 AS INTEGER ) * col2 + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8519
SELECT + - 69 DIV 58 + cor0.col0 * 44 AS col2 FROM tab0 AS cor0
----
1055
1539
3915

skipif mysql # not compatible
query I rowsort label-8519
SELECT + - 69 / 58 + cor0.col0 * 44 AS col2 FROM tab0 AS cor0
----
1055
1539
3915

query I rowsort
SELECT DISTINCT - ( 74 ) + col0 * col1 + col1 FROM tab2 cor0
----
1286
174
4587

query I rowsort
SELECT ALL ( tab2.col2 ) FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT + col1 * + cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT col0 - + 35 FROM tab0 AS cor0
----
-11
0
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-8524
SELECT DISTINCT - col2 + - col1 - col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
-110
-68
-81

skipif mysql # not compatible
query I rowsort label-8524
SELECT DISTINCT - col2 + - col1 - col1 / + col1 AS col0 FROM tab1 AS cor0
----
-110
-68
-81

query I rowsort
SELECT DISTINCT - + ( - cor0.col0 ) * col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL ( + col0 ) AS col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL - col2 * - 44 - ( col2 ) FROM tab0
----
1419
3526
43

query I rowsort
SELECT - ( col2 ) + + col2 * + col0 FROM tab0
----
34
7216
759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * 26 + col1 col1 FROM tab2
----
1593
459
837

query I rowsort
SELECT DISTINCT + + 26 + - 88 FROM tab2, tab1, tab2 AS cor0
----
-62

query I rowsort
SELECT ALL - 51 + - ( - col1 ) * ( col0 ) AS col0 FROM tab2 AS cor0
----
1292
166
4551

query I rowsort
SELECT DISTINCT + - 19 + col2 AS col2 FROM tab0 AS cor0
----
-18
14
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 23 ) col1 FROM tab2 AS cor0
----
23
23
23

query I rowsort
SELECT - ( + col2 ) * + col1 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT ALL 86 AS col0 FROM tab1
----
86
86
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-8537
SELECT 2 DIV 10 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8537
SELECT 2 / 10 FROM tab0
----
0
0
0

query I rowsort
SELECT - col0 * - 87 FROM tab1
----
261
5568
6960

query I rowsort
SELECT ALL + col2 * tab0.col1 * col1 AS col0 FROM tab0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-8540
SELECT DISTINCT + ( cor0.col1 ) DIV 93 col1 FROM tab0, tab2, tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8540
SELECT DISTINCT + ( cor0.col1 ) / 93 col1 FROM tab0, tab2, tab2 AS cor0
----
0

query I rowsort
SELECT tab2.col1 AS col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col2 + 40 FROM tab0 cor0
----
122
41
73

query I rowsort
SELECT ALL + - 90 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c0d96679aba507520916e8654e5a6618

query I rowsort
SELECT ( tab2.col1 ) + - 78 FROM tab2
----
-19
-47
-61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 * col2 ) col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL + 13 * col0 AS col0 FROM tab0 AS cor0
----
1157
312
455

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + col1 col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL - tab1.col1 FROM tab0, tab2, tab1 AS cor0, tab1
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT DISTINCT + 8 * col1 AS col2 FROM tab0
----
688
728
776

query I rowsort
SELECT DISTINCT + tab2.col0 * - 38 * - 54 AS col1 FROM tab2
----
14364
160056
162108

query I rowsort
SELECT ALL - + col2 + ( col1 ) FROM tab0 AS cor0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8552
SELECT DISTINCT - + col0 * - CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-8552
SELECT DISTINCT - + col0 * - CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT cor0.col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL col0 + col1 * + col2 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + cor0.col0 * - col0 + 76 FROM tab0 AS cor0
----
-1149
-500
-7845

query I rowsort
SELECT DISTINCT - - cor0.col1 * col1 + - cor0.col0 * + col1 AS col0 FROM tab0 AS cor0
----
182
5332
6014

onlyif mysql # use DIV operator for integer division
query I rowsort label-8557
SELECT ALL cor0.col0 DIV 31 FROM tab2 AS cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-8557
SELECT ALL cor0.col0 / 31 FROM tab2 AS cor0
----
0
2
2

query I rowsort
SELECT DISTINCT + col2 * + ( + 45 ) + - col0 FROM tab0 AS cor0
----
10
1461
3601

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col2 col1 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col1 ) + - col1 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 51 * col0 - 6 * ( - cor0.col2 ) FROM tab2 AS cor0
----
4134
4257
519

query I rowsort
SELECT 46 * + tab2.col0 AS col0 FROM tab2
----
322
3588
3634

onlyif mysql # use DIV operator for integer division
query I rowsort label-8563
SELECT 58 DIV - col0 col0 FROM tab0
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8563
SELECT 58 / - col0 col0 FROM tab0
----
-1
-2
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8564
SELECT - col0 * col1 * CAST( cor0.col2 AS SIGNED ) FROM tab2 AS cor0
----
-119652
-51034
-5859

skipif mysql # not compatible
query I rowsort label-8564
SELECT - col0 * col1 * CAST ( cor0.col2 AS INTEGER ) FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + col0 * col2 * - col0 - col0 * col0 FROM tab1 AS cor0
----
-237568
-495
-620800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8566
SELECT + col1 + - CAST( - col2 AS SIGNED ) + col1 AS col2 FROM tab2 AS cor0
----
144
72
89

skipif mysql # not compatible
query I rowsort label-8566
SELECT + col1 + - CAST ( - col2 AS INTEGER ) + col1 AS col2 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT col1 + + col2 + 93 FROM tab1 cor0
----
160
173
202

query I rowsort
SELECT - - col0 - - ( + col2 ) * + col0 AS col0 FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT - + col1 * 64 + + col0 + - col1 AS col2 FROM tab2 AS cor0
----
-1026
-2008
-3757

onlyif mysql # use DIV operator for integer division
query I rowsort label-8570
SELECT 68 DIV - col2 col0 FROM tab1
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8570
SELECT 68 / - col2 col0 FROM tab1
----
-1
-1
0

query I rowsort
SELECT - + col2 + + 59 * col1 AS col2 FROM tab0 cor0
----
5041
5287
5722

query I rowsort
SELECT 17 * col0 AS col1 FROM tab1 AS cor0
----
1088
1360
51

query I rowsort
SELECT ALL - - ( cor0.col1 ) + col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT + - 8 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
78
83
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8575
SELECT DISTINCT - + CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8575
SELECT DISTINCT - + CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT + + 73 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-7
70
9

query I rowsort
SELECT ALL col1 * ( + tab1.col0 ) FROM tab1
----
1040
640
78

query I rowsort
SELECT - col0 * 86 FROM tab0 AS cor0
----
-2064
-3010
-7654

query I rowsort
SELECT ALL - 27 FROM tab1, tab2 AS cor0
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

query I rowsort
SELECT ALL cor0.col0 * - 59 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 45ab40e26cca69ea8ca7efa1e590d71c

query I rowsort
SELECT DISTINCT + 54 + col0 AS col2 FROM tab2 AS cor0
----
132
133
61

query I rowsort
SELECT DISTINCT - 55 + - col0 AS col1 FROM tab0 AS cor0
----
-144
-79
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col1 ) col1 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL + 53 + + col0 * + 83 FROM tab0 AS cor0
----
2045
2958
7440

query I rowsort
SELECT DISTINCT - - 28 * - col1 AS col0 FROM tab0 AS cor0
----
-2408
-2548
-2716

onlyif mysql # use DIV operator for integer division
query I rowsort label-8586
SELECT DISTINCT - col2 DIV - col0 FROM tab2 cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-8586
SELECT DISTINCT - col2 / - col0 FROM tab2 cor0
----
0
3

query I rowsort
SELECT DISTINCT - 45 + col1 FROM tab0 AS cor0
----
41
46
52

query I rowsort
SELECT ALL - - 1 - + col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * cor0.col1 * 79 + + col0 * - cor0.col0 col1 FROM tab2 AS cor0
----
17094
357474
99856

query I rowsort
SELECT ALL ( 13 ) * col2 FROM tab2
----
338
351
494

query I rowsort
SELECT ALL + ( col0 ) * + col1 AS col2 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8592
SELECT DISTINCT - 87 DIV cor0.col2 col2 FROM tab2, tab0 cor0
----
-1
-2
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8592
SELECT DISTINCT - 87 / cor0.col2 col2 FROM tab2, tab0 cor0
----
-1
-2
-87

query I rowsort
SELECT + ( col2 * + col1 ) + - col0 * col2 AS col0 FROM tab1
----
-3078
-6432
1242

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( + cor1.col0 AS REAL ) AS col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - ( - col2 ) AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT + 96 * col1 FROM tab0 cor0
----
8256
8736
9312

query I rowsort
SELECT - + cor0.col2 * - col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + cor0.col2 + + 83 AS col2 FROM tab1 AS cor0
----
137
140
179

query I rowsort
SELECT + col0 + - 99 * col2 * col1 AS col1 FROM tab2 AS cor0
----
-151788
-63875
-82856

query I rowsort
SELECT + col1 + ( + col2 ) + + 1 * col1 * col2 AS col0 FROM tab2 AS cor0
----
1619
701
895

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8601
SELECT DISTINCT + CAST( col2 AS SIGNED ) * + col1 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-8601
SELECT DISTINCT + CAST ( col2 AS INTEGER ) * + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + ( - col2 ) + col1 + col2 * col1 FROM tab2 AS cor0
----
1567
625
841

query I rowsort
SELECT 71 + col0 FROM tab0 AS cor0
----
106
160
95

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL - ( + ( col1 ) ) * ( + cor0.col0 * + cor0.col2 ) FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + col1 * + col0 * col1 + + col1 FROM tab2 AS cor0
----
22848
271577
6758

query I rowsort
SELECT + col1 + - col0 + - col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - ( + col0 ) + ( - col0 ) * col1 - - col0 AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - 44 + col0 + col2 FROM tab2
----
-10
60
73

query I rowsort
SELECT ALL + ( - 93 ) + cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 4aaa54e31c29cf3023ce85f168ddcc97

query I rowsort
SELECT col1 - - col2 * + col0 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT - cor0.col1 * - 68 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT DISTINCT - col1 * 61 + - cor0.col2 * cor0.col0 FROM tab2 AS cor0
----
-2080
-4039
-5627

query I rowsort
SELECT ALL 39 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT + col1 + - col1 * 99 AS col2 FROM tab2
----
-1666
-3038
-5782

query I rowsort
SELECT tab2.col0 * + col0 + col2 * - col1 * col0 + tab2.col0 FROM tab2
----
-113490
-44714
-5803

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 + cor1.col2 col2 FROM tab0, tab2, tab1 AS cor0, tab0 cor1
----
81 values hashing to 4ab832bde8c0f993189addf651f11513

query I rowsort
SELECT DISTINCT col0 + + 62 + col2 AS col0 FROM tab0
----
119
233
98

query I rowsort
SELECT ALL 46 * - 17 FROM tab2, tab2 AS cor0
----
9 values hashing to 92d61ff6ad50f2f7762ed51567f01894

query I rowsort
SELECT DISTINCT - - col2 * col0 + 24 + col2 FROM tab1 AS cor0
----
240
3729
7800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + cor0.col0 * - col0 col0 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT ALL col2 + + cor0.col2 * - cor0.col2 * col0 AS col1 FROM tab1 AS cor0
----
-207879
-737184
-8694

query I rowsort
SELECT - cor0.col1 + + 26 + + col1 FROM tab1 cor0
----
26
26
26

query I rowsort
SELECT + col0 * 7 + + 80 * col0 * - col1 FROM tab1 AS cor0
----
-50752
-6219
-82640

query I rowsort
SELECT + 20 FROM tab2, tab2 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT ALL - 44 FROM tab0, tab1 AS cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8627
SELECT DISTINCT - CAST( NULL AS DECIMAL ) / - col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-8627
SELECT DISTINCT - CAST ( NULL AS REAL ) / - col0 FROM tab0
----
NULL

query I rowsort
SELECT + ( 36 * - col0 ) + + col2 FROM tab0
----
-1259
-3122
-831

query I rowsort
SELECT - 30 - tab2.col0 FROM tab2
----
-108
-109
-37

query I rowsort
SELECT DISTINCT - ( - col0 ) + + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8631
SELECT ALL - + col1 * col2 + col1 + CAST( 78 AS SIGNED ) * col2 * col0 AS col0 FROM tab2 AS cor0
----
13936
156709
233527

skipif mysql # not compatible
query I rowsort label-8631
SELECT ALL - + col1 * col2 + col1 + CAST ( 78 AS INTEGER ) * col2 * col0 AS col0 FROM tab2 AS cor0
----
13936
156709
233527

query I rowsort
SELECT - col0 + + 99 * col2 AS col1 FROM tab1 AS cor0
----
5343
5579
9424

query I rowsort
SELECT DISTINCT + col1 + + col1 * col0 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT 87 * + col2 AS col1 FROM tab1 AS cor0
----
4698
4959
8352

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col2 * + col0 + ( col0 ) FROM tab2 AS cor0
----
119730
51113
5866

onlyif mysql # use DIV operator for integer division
query I rowsort label-8636
SELECT ALL - 28 DIV col2 AS col2 FROM tab0 AS cor0
----
-28
0
0

skipif mysql # not compatible
query I rowsort label-8636
SELECT ALL - 28 / col2 AS col2 FROM tab0 AS cor0
----
-28
0
0

query I rowsort
SELECT + + 91 * col0 + col1 FROM tab2 AS cor0
----
668
7157
7206

query I rowsort
SELECT ALL col0 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + + 43 FROM tab2 cor0
----
43
43
43

query I rowsort
SELECT ALL + col0 * + col0 + 32 AS col2 FROM tab1 AS cor0
----
41
4128
6432

onlyif mysql # use DIV operator for integer division
query I rowsort label-8641
SELECT DISTINCT - col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-8641
SELECT DISTINCT - col0 / - col1 AS col2 FROM tab1 AS cor0
----
0
6

query I rowsort
SELECT ( - tab1.col2 ) - col0 * 55 AS col2 FROM tab1
----
-219
-3577
-4496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + - col2 col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + 30 + col1 FROM tab1 AS cor0
----
40
43
56

query I rowsort
SELECT ALL + 93 + col1 FROM tab1 AS cor0
----
103
106
119

query I rowsort
SELECT ALL col0 - col0 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL - + 32 + - col2 FROM tab0 AS cor0
----
-114
-33
-65

query I rowsort
SELECT DISTINCT - col1 * col2 - + 69 AS col1 FROM tab2 AS cor0
----
-1603
-715
-906

query I rowsort
SELECT ALL cor0.col1 * - col1 - 14 FROM tab0 AS cor0
----
-7410
-8295
-9423

query I rowsort
SELECT + 7 * - col1 FROM tab0 AS cor0
----
-602
-637
-679

query I rowsort
SELECT col2 * + cor0.col0 + - col0 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-8652
SELECT 59 DIV col1 AS col1 FROM tab2
----
1
1
3

skipif mysql # not compatible
query I rowsort label-8652
SELECT 59 / col1 AS col1 FROM tab2
----
1
1
3

query I rowsort
SELECT col2 * - cor0.col2 - col0 * + col0 AS col0 FROM tab1 AS cor0
----
-15616
-2925
-7345

onlyif mysql # use DIV operator for integer division
query I rowsort label-8654
SELECT + col1 DIV 99 + col2 * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort label-8654
SELECT + col1 / 99 + col2 * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT tab1.col0 * + col2 * - 57 AS col0 FROM tab1
----
-207936
-437760
-9234

query I rowsort
SELECT + 0 * - tab1.col2 + col2 * + col0 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8657
SELECT ALL + 66 + + col2 DIV col0 FROM tab0 AS cor0
----
66
66
67

skipif mysql # not compatible
query I rowsort label-8657
SELECT ALL + 66 + + col2 / col0 FROM tab0 AS cor0
----
66
66
67

query I rowsort
SELECT DISTINCT 92 AS col0 FROM tab2 cor0
----
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 23 + + ( - col2 ) * col1 * - cor0.col0 col1 FROM tab2 cor0
----
119629
51011
5836

query I rowsort
SELECT 20 + 49 + col1 AS col0 FROM tab2 AS cor0
----
100
128
86

query I rowsort
SELECT DISTINCT 17 + col0 AS col2 FROM tab2 AS cor0
----
24
95
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8662
SELECT DISTINCT - + 35 DIV + col2 + - col0 AS col0 FROM tab0 cor0
----
-25
-70
-89

skipif mysql # not compatible
query I rowsort label-8662
SELECT DISTINCT - + 35 / + col2 + - col0 AS col0 FROM tab0 cor0
----
-25
-70
-89

query I rowsort
SELECT tab0.col2 AS col0 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-8664
SELECT ALL + tab0.col1 + - ( + ( col0 ) ) DIV ( col1 + + col2 ) FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8664
SELECT ALL + tab0.col1 + - ( + ( col0 ) ) / ( col1 + + col2 ) FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + col2 + 2 + col0 FROM tab2
----
106
119
36

query I rowsort
SELECT ALL ( + col1 + col1 * col1 ) AS col0 FROM tab0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-8667
SELECT + 24 DIV + cor0.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-8667
SELECT + 24 / + cor0.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT 76 AS col1 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT DISTINCT + - 42 * - col1 + col1 FROM tab2 AS cor0
----
1333
2537
731

query I rowsort
SELECT ALL ( ( + col1 ) ) * 26 + + col0 FROM tab0 AS cor0
----
2260
2455
2557

query I rowsort
SELECT 36 + ( + col2 ) AS col1 FROM tab2 AS cor0
----
62
63
74

query I rowsort
SELECT ALL - 80 * cor0.col0 + - cor0.col0 FROM tab0 AS cor0
----
-1944
-2835
-7209

query I rowsort
SELECT DISTINCT + 52 - + cor0.col1 FROM tab0 AS cor0
----
-34
-39
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-8674
SELECT DISTINCT - ( col1 ) DIV col2 AS col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8674
SELECT DISTINCT - ( col1 ) / col2 AS col0 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 62 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-8676
SELECT DISTINCT col2 DIV - col2 AS col1 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-8676
SELECT DISTINCT col2 / - col2 AS col1 FROM tab0
----
-1

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab1 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to d2c0c94b38e721d8cf9f7df226475a2f

onlyif mysql # use DIV operator for integer division
query I rowsort label-8678
SELECT - + col2 DIV + col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-8678
SELECT - + col2 / + col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8679
SELECT + CAST( + col1 AS SIGNED ) + + col0 * col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

skipif mysql # not compatible
query I rowsort label-8679
SELECT + CAST ( + col1 AS INTEGER ) + + col0 * col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor1.col2 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT - col1 * - cor0.col0 * - col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL + 13 FROM tab2, tab0 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT + 97 * 80 * + col0 FROM tab1 AS cor0
----
23280
496640
620800

query I rowsort
SELECT cor0.col1 + cor0.col1 * - col1 AS col0 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT - ( col0 ) - col2 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8686
SELECT - col0 DIV col1 + col2 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8686
SELECT - col0 / col1 + col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + - 92 AS col1 FROM tab0 AS cor0
----
-92
-92
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + - col1 * + col0 col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT + col0 * col0 + col2 * + 65 + col1 FROM tab0 AS cor0
----
13342
1387
2807

query I rowsort
SELECT + 56 AS col1 FROM tab0 cor0
----
56
56
56

query I rowsort
SELECT cor1.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT + + col1 + - col0 * + col1 * - 62 FROM tab0 AS cor0
----
128054
210587
502229

query I rowsort
SELECT - - 60 FROM tab1 AS cor0
----
60
60
60

query I rowsort
SELECT DISTINCT + - col2 * col1 + col1 * + col1 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-206913
-30628
-5559

onlyif mysql # use DIV operator for integer division
query I rowsort label-8695
SELECT ALL cor0.col1 DIV + col1 - + col2 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-8695
SELECT ALL cor0.col1 / + col1 - + col2 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT + + col0 * col2 + col0 * - col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col2 + col0 * col0 FROM tab0 cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-8698
SELECT + col0 DIV cor0.col0 + col0 AS col1 FROM tab0 cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-8698
SELECT + col0 / cor0.col0 + col0 AS col1 FROM tab0 cor0
----
25
36
90

query I rowsort
SELECT - col0 * ( 3 ) FROM tab1 AS cor0
----
-192
-240
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8700
SELECT + + col2 + + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8700
SELECT + + col2 + + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 6 AS col2 FROM tab1
----
-6
-6
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8702
SELECT + col1 + + CAST( + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-8702
SELECT + col1 + + CAST ( + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL + col1 * 77 FROM tab0 AS cor0
----
6622
7007
7469

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col1 col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col2 * + ( col2 ) AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - col0 * ( - col1 * - col0 ) AS col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL - ( + 76 ) + + col0 * ( cor0.col1 ) + col2 FROM tab2 AS cor0
----
1305
168
4552

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col2 col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - + col2 + - col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT - - col2 + - cor0.col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8711
SELECT ALL + - CAST( - col1 AS SIGNED ) + col2 col0 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8711
SELECT ALL + - CAST ( - col1 AS INTEGER ) + col2 col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL 34 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - + 94 * + col0 AS col2 FROM tab2 AS cor0
----
-658
-7332
-7426

query I rowsort
SELECT ALL - 42 * + col2 AS col1 FROM tab1
----
-2268
-2394
-4032

onlyif mysql # use DIV operator for integer division
query I rowsort label-8716
SELECT ( 53 ) DIV tab2.col1 AS col1 FROM tab2
----
0
1
3

skipif mysql # not compatible
query I rowsort label-8716
SELECT ( 53 ) / tab2.col1 AS col1 FROM tab2
----
0
1
3

query I rowsort
SELECT DISTINCT - 26 * - tab2.col2 AS col1 FROM tab2
----
676
702
988

query I rowsort
SELECT ALL + 53 + + col2 AS col0 FROM tab2
----
79
80
91

query I rowsort
SELECT - 21 * col0 AS col2 FROM tab0
----
-1869
-504
-735

query I rowsort
SELECT 53 * + col1 FROM tab2
----
1643
3127
901

query I rowsort
SELECT DISTINCT + 98 AS col2 FROM tab2, tab1, tab1 AS cor0
----
98

query I rowsort
SELECT - 43 FROM tab2, tab1 AS cor0, tab2 cor1, tab2 cor2
----
81 values hashing to 4f17f941ddb7d7f35d93196515cfe0f2

query I rowsort
SELECT DISTINCT 28 + + col2 FROM tab2
----
54
55
66

query I rowsort
SELECT DISTINCT + - ( - 61 ) * + cor0.col0 AS col2 FROM tab0, tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT DISTINCT + col1 * col0 + - col0 + col1 * + cor0.col2 * + col2 FROM tab0 AS cor0
----
3457
619894
95694

query I rowsort
SELECT ALL - + col2 - col0 * - 85 AS col0 FROM tab1 cor0
----
201
5383
6704

query I rowsort
SELECT ALL + cor0.col2 - col0 FROM tab1 cor0
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 97 + + cor0.col1 col2 FROM tab0 AS cor0
----
-11
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 97 * col2 col2 FROM tab1 AS cor0
----
5238
5529
9312

query I rowsort
SELECT DISTINCT + - col0 + col0 * col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + 46 * col1 + + col1 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT ALL cor0.col2 * col1 * 38 FROM tab1 AS cor0
----
21660
47424
53352

query I rowsort
SELECT ALL - 53 * col2 FROM tab2 AS cor0
----
-1378
-1431
-2014

query I rowsort
SELECT ALL - col1 + - col1 + col1 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - + 7 * - col2 FROM tab0 AS cor0
----
231
574
7

query I rowsort
SELECT + 87 * cor0.col2 FROM tab1 AS cor0
----
4698
4959
8352

query I rowsort
SELECT DISTINCT + - 46 - - col2 AS col0 FROM tab2 AS cor0
----
-19
-20
-8

query I rowsort
SELECT ALL 70 - col0 AS col1 FROM tab1
----
-10
6
67

query I rowsort
SELECT + 29 * cor0.col1 FROM tab2 AS cor0
----
1711
493
899

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col1 ) * + col0 col2 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-8741
SELECT + 34 DIV - tab0.col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8741
SELECT + 34 / - tab0.col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL cor1.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT + col1 * + col0 * col1 + col0 AS col0 FROM tab1
----
13600
2031
6464

skipif mysql # not compatible
query I rowsort
SELECT ALL + - CAST ( ( - col2 ) AS REAL ) + 93 * + col1 - - cor0.col0 FROM tab2 AS cor0
----
1698
2917
5591

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8745
SELECT + CAST( col1 AS SIGNED ) + col0 * col2 FROM tab0 AS cor0
----
132
7389
878

skipif mysql # not compatible
query I rowsort label-8745
SELECT + CAST ( col1 AS INTEGER ) + col0 * col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT + col2 + - col2 FROM tab1 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8747
SELECT DISTINCT col1 DIV 35 - - col0 * + col2 FROM tab0 AS cor0
----
37
7300
794

skipif mysql # not compatible
query I rowsort label-8747
SELECT DISTINCT col1 / 35 - - col0 * + col2 FROM tab0 AS cor0
----
37
7300
794

query I rowsort
SELECT DISTINCT ( tab0.col2 ) FROM tab0, tab1 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + 23 AS col0 FROM tab1, tab0 AS cor0
----
23

query I rowsort
SELECT - 95 + - col2 AS col2 FROM tab1
----
-149
-152
-191

query I rowsort
SELECT + cor1.col0 AS col0 FROM tab0, tab1 cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT 36 AS col2 FROM tab2
----
36

query I rowsort
SELECT DISTINCT + ( - 9 ) AS col1 FROM tab2 AS cor0
----
-9

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( 15 AS REAL ) + col1 * + 59 AS col2 FROM tab1 AS cor0
----
1519
575
752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 3 + + cor0.col1 * - ( cor0.col1 ) col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 247e99c0f4b67d2565b1ebf7960a5166

query I rowsort
SELECT DISTINCT + col1 * + ( col2 ) + ( col1 ) AS col2 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8757
SELECT DISTINCT + CAST( NULL AS DECIMAL ) + - col0 AS col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8757
SELECT DISTINCT + CAST ( NULL AS REAL ) + - col0 AS col0 FROM tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8758
SELECT CAST( NULL AS SIGNED ) * cor0.col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8758
SELECT CAST ( NULL AS INTEGER ) * cor0.col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 87 - - ( + col1 ) * 95 * - col2 AS col1 FROM tab0
----
-269697
-708977
-9302

query I rowsort
SELECT - 55 * + col0 * + col0 FROM tab2 AS cor0
----
-2695
-334620
-343255

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8761
SELECT ALL - col2 * ( col1 ) + - col2 * CAST( 86 AS SIGNED ) + col0 AS col0 FROM tab2 AS cor0
----
-3152
-3692
-3835

skipif mysql # not compatible
query I rowsort label-8761
SELECT ALL - col2 * ( col1 ) + - col2 * CAST ( 86 AS INTEGER ) + col0 AS col0 FROM tab2 AS cor0
----
-3152
-3692
-3835

query I rowsort
SELECT - 95 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT + col1 * 42 + - 28 FROM tab0 AS cor0
----
3584
3794
4046

onlyif mysql # use DIV operator for integer division
query I rowsort label-8764
SELECT DISTINCT - col0 + - col0 DIV col0 + col2 * - col0 FROM tab2
----
-197
-2107
-3082

skipif mysql # not compatible
query I rowsort label-8764
SELECT DISTINCT - col0 + - col0 / col0 + col2 * - col0 FROM tab2
----
-197
-2107
-3082

query I rowsort
SELECT ALL - col2 + col2 * col0 AS col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT col0 + + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + col0 * - col2 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT - ( col2 ) * col2 + col1 + - col0 AS col0 FROM tab2 cor0
----
-1506
-695
-705

query I rowsort
SELECT - 40 * - col1 + col2 FROM tab1 cor0
----
1094
457
616

query I rowsort
SELECT 41 + col2 + - col0 FROM tab2 AS cor0
----
-11
0
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8771
SELECT DISTINCT + - CAST( NULL AS SIGNED ) * col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8771
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) * col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - 93 * 66 FROM tab2 cor0
----
-6138

query I rowsort
SELECT col1 + 88 FROM tab1 AS cor0
----
101
114
98

query I rowsort
SELECT ALL col1 * + col2 * - col2 + - col2 FROM tab2
----
-22626
-24586
-39910

query I rowsort
SELECT ALL + col1 + + 65 FROM tab1
----
75
78
91

query I rowsort
SELECT - + ( + col0 ) * - col1 + col0 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT col2 * + 60 * 90 + cor0.col1 * + col0 * col2 AS col2 FROM tab1 AS cor0
----
295812
344280
618240

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 46 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

onlyif mysql # use DIV operator for integer division
query I rowsort label-8779
SELECT DISTINCT col0 DIV + 28 - - col0 col1 FROM tab1 cor0
----
3
66
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8779
SELECT DISTINCT col0 / + 28 - - col0 col1 FROM tab1 cor0
----
3
66
82

query I rowsort
SELECT DISTINCT + + 98 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
98

query I rowsort
SELECT - + cor1.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT col0 + col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL col0 + + 53 AS col1 FROM tab1
----
117
133
56

query I rowsort
SELECT + col0 * ( col2 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT + - col2 * + col1 * - cor0.col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL + 15 * - col1 + col1 FROM tab0
----
-1204
-1274
-1358

query I rowsort
SELECT + 40 FROM tab2, tab0 cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col1 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT 93 + - col0 AS col1 FROM tab1 AS cor0
----
13
29
90

query I rowsort
SELECT - 68 * col1 + - 24 AS col1 FROM tab0 AS cor0
----
-5872
-6212
-6620

query I rowsort
SELECT cor0.col0 * 60 FROM tab2, tab2 AS cor0
----
9 values hashing to bcace913b02f67b9596380ee1965ba58

query I rowsort
SELECT + col0 * - col2 - ( + 2 ) * col1 FROM tab0 AS cor0
----
-229
-7480
-964

onlyif mysql # use DIV operator for integer division
query I rowsort label-8794
SELECT + + col1 DIV - col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-8794
SELECT + + col1 / - col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT col2 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col0 ) + - ( - col0 ) * + col0 + - ( col0 ) col0 FROM tab0 AS cor0
----
1155
528
7743

query I rowsort
SELECT + - col0 + + cor0.col0 * + 98 * col0 AS col2 FROM tab1 AS cor0
----
401344
627120
879

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 92 + + cor0.col2 col2 FROM tab1 AS cor0
----
146
149
188

onlyif mysql # use DIV operator for integer division
query I rowsort label-8799
SELECT DISTINCT 45 + col2 DIV 82 - col1 AS col1 FROM tab2
----
-14
14
28

skipif mysql # not compatible
query I rowsort label-8799
SELECT DISTINCT 45 + col2 / 82 - col1 AS col1 FROM tab2
----
-14
14
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-8800
SELECT - tab0.col0 DIV + 83 FROM tab0, tab1 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-8800
SELECT - tab0.col0 / + 83 FROM tab0, tab1 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

query I rowsort
SELECT ALL 15 * + col0 * ( ( col2 ) ) AS col2 FROM tab2 AS cor0
----
2835
30420
45030

query I rowsort
SELECT - col1 - col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - col1 + tab1.col2 AS col1 FROM tab1
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8804
SELECT ALL col2 * CAST( col2 + - col0 AS SIGNED ) FROM tab0 AS cor0
----
-34
-574
297

skipif mysql # not compatible
query I rowsort label-8804
SELECT ALL col2 * CAST ( col2 + - col0 AS INTEGER ) FROM tab0 AS cor0
----
-34
-574
297

query I rowsort
SELECT DISTINCT + - cor0.col0 + 80 FROM tab2 AS cor0
----
1
2
73

query I rowsort
SELECT - col2 + - col1 + 34 * col2 FROM tab1 AS cor0
----
1756
1871
3155

query I rowsort
SELECT DISTINCT col0 + 80 AS col2 FROM tab0 cor0
----
104
115
169

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - cor0.col0 * 52 * cor0.col2 col0 FROM tab1 AS cor0
----
-189632
-399280
-8421

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col2 col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - + col0 + + col1 FROM tab0 cor0
----
2
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8811
SELECT col1 * - col1 + + cor0.col2 + + col1 DIV + ( col0 ) FROM tab1 cor0
----
-43
-614
-73

skipif mysql # not compatible
query I rowsort label-8811
SELECT col1 * - col1 + + cor0.col2 + + col1 / + ( col0 ) FROM tab1 cor0
----
-43
-614
-73

query I rowsort
SELECT col1 * + col0 * - col2 AS col1 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + - cor0.col2 * + col2 + + col1 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8814
SELECT ALL ( + col2 ) DIV + col2 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8814
SELECT ALL ( + col2 ) / + col2 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT + col1 + - 86 FROM tab2 AS cor0
----
-27
-55
-69

query I rowsort
SELECT DISTINCT - ( col2 ) * + col2 * 55 AS col0 FROM tab1 AS cor0
----
-160380
-178695
-506880

query I rowsort
SELECT DISTINCT + col2 + col1 * + cor0.col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + 30 * col0 AS col1 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT ALL - + cor0.col1 + col1 - - col0 * col0 FROM tab1 cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) * + cor0.col2 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - 86 + col0 FROM tab1 AS cor0
----
-22
-6
-83

query I rowsort
SELECT DISTINCT + col2 * col1 * col1 + col2 * col0 FROM tab1 AS cor0
----
23904
36666
9348

query I rowsort
SELECT ( - col2 ) * - col2 AS col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT col1 + col2 + col1 AS col2 FROM tab0 AS cor0
----
195
205
264

query I rowsort
SELECT ALL + + ( + col2 ) * ( + col0 * + cor0.col0 ) FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-8826
SELECT DISTINCT ( - col0 ) DIV cor0.col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-8826
SELECT DISTINCT ( - col0 ) / cor0.col2 FROM tab1 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 12 col1 FROM tab2
----
12
12
12

query I rowsort
SELECT ALL - col1 * - col2 + col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT ALL - + col2 * + col1 + 92 * col1 AS col2 FROM tab2 AS cor0
----
2015
3894
918

query I rowsort
SELECT ALL col0 * - cor0.col0 AS col1 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - + col0 + - ( - col2 * col1 ) + col1 FROM tab1 AS cor0
----
1181
1427
516

query I rowsort
SELECT ALL cor0.col2 + 28 AS col0 FROM tab2 AS cor0
----
54
55
66

query I rowsort
SELECT + - col1 * 44 AS col0 FROM tab1 AS cor0
----
-1144
-440
-572

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8834
SELECT DISTINCT + col2 * + CAST( col2 AS SIGNED ) + - cor0.col0 FROM tab1 AS cor0
----
2913
3185
9136

skipif mysql # not compatible
query I rowsort label-8834
SELECT DISTINCT + col2 * + CAST ( col2 AS INTEGER ) + - cor0.col0 FROM tab1 AS cor0
----
2913
3185
9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-8835
SELECT DISTINCT + - col1 + - col1 * 93 DIV + col1 FROM tab1 AS cor0
----
-103
-106
-119

skipif mysql # not compatible
query I rowsort label-8835
SELECT DISTINCT + - col1 + - col1 * 93 / + col1 FROM tab1 AS cor0
----
-103
-106
-119

query I rowsort
SELECT ALL - col1 * + 32 FROM tab0 AS cor0
----
-2752
-2912
-3104

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * 62 * + col1 + + col1 col0 FROM tab2 cor0
----
17935
215881
59613

query I rowsort
SELECT ALL - col1 + 46 * col0 AS col1 FROM tab0 AS cor0
----
1018
1513
4003

query I rowsort
SELECT ALL - col0 * col1 + 44 AS col0 FROM tab2 AS cor0
----
-1299
-173
-4558

query I rowsort
SELECT DISTINCT - col1 + + 96 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
1235
2470
950

query I rowsort
SELECT ALL col2 - + 39 FROM tab2 AS cor0
----
-1
-12
-13

query I rowsort
SELECT - col0 + - ( + cor0.col0 ) FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT cor0.col2 * - 34 FROM tab2 AS cor0
----
-1292
-884
-918

query I rowsort
SELECT DISTINCT - + col1 + 64 + col2 FROM tab0 AS cor0
----
-32
11
55

query I rowsort
SELECT ALL + - ( ( - col0 ) ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + - 40 + col1 AS col1 FROM tab2 AS cor0
----
-23
-9
19

query I rowsort
SELECT ALL + cor0.col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col0 + - col2 * + ( 17 ) AS col0 FROM tab0 cor0
----
-1305
-537
18

query I rowsort
SELECT col2 * col1 * 49 + col2 FROM tab2 AS cor0
----
31692
41040
75192

query I rowsort
SELECT DISTINCT - col2 * + cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT + 74 + col0 * - 89 AS col2 FROM tab0 cor0
----
-2062
-3041
-7847

query I rowsort
SELECT ALL + + col1 + col1 + 18 * 99 AS col1 FROM tab0 AS cor0
----
1954
1964
1976

query I rowsort
SELECT + col1 + + col1 + col0 FROM tab0
----
196
229
271

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - - 31 FROM tab2, tab2 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to 0bb6d1445d82a11417f7bb2ec248ca9c

query I rowsort
SELECT ALL 99 + tab1.col0 AS col0 FROM tab1
----
102
163
179

query I rowsort
SELECT ALL tab1.col1 * - tab1.col0 + + col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL cor0.col0 + - 39 FROM tab0, tab0 AS cor0
----
9 values hashing to 619228f6c459e8b55ab693a23d79ace1

query I rowsort
SELECT DISTINCT + cor0.col0 + + col2 + + cor0.col2 * col0 * + col1 FROM tab1 AS cor0
----
100016
36601
4269

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8860
SELECT DISTINCT 18 * + col1 + CAST( 4 AS SIGNED ) * tab2.col1 col0 FROM tab2
----
1298
374
682

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8860
SELECT DISTINCT 18 * + col1 + CAST ( 4 AS INTEGER ) * tab2.col1 col0 FROM tab2
----
1298
374
682

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - tab0.col1 col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL 40 + - col1 FROM tab0
----
-46
-51
-57

query I rowsort
SELECT DISTINCT + tab2.col2 * + 21 FROM tab2, tab0, tab1 AS cor0, tab1
----
546
567
798

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8864
SELECT ALL + 81 * - col2 + - CAST( NULL AS DECIMAL ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8864
SELECT ALL + 81 * - col2 + - CAST ( NULL AS REAL ) FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8865
SELECT + col2 * col2 + + CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8865
SELECT + col2 * col2 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col0 + + 46 col2 FROM tab2 AS cor0
----
-143
-1982
-2956

query I rowsort
SELECT 78 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query I rowsort
SELECT DISTINCT - tab0.col1 * ( 34 * cor0.col1 ) AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 09ae41c668046c7a894924ced6c10ba5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 36 * - cor1.col2 col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 0da32bfb31f76d0ebd996ce5c88fcdb8

query I rowsort
SELECT ALL + 46 + 33 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to da0116d31b8af0da9f685c090d378baf

query I rowsort
SELECT + col0 * col1 + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT col2 * - col1 * + 38 FROM tab0
----
-107844
-283556
-3686

query I rowsort
SELECT DISTINCT + + col0 * - ( 10 ) * col1 FROM tab0 AS cor0
----
-20640
-33950
-80990

query I rowsort
SELECT + + col1 * cor0.col1 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8875
SELECT ALL - + cor0.col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8875
SELECT ALL - + cor0.col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 71 + col1 AS col1 FROM tab2
----
-12
-40
-54

query I rowsort
SELECT ALL - 98 + - 64 + - col0 * - col0 FROM tab1
----
-153
3934
6238

query I rowsort
SELECT - tab1.col0 + - col1 + col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT col0 + + col0 * - col1 AS col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT ( 63 ) FROM tab0, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
63

query I rowsort
SELECT DISTINCT - ( - col0 ) * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8882
SELECT ALL - + CAST( col1 AS SIGNED ) * - col1 FROM tab2 cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-8882
SELECT ALL - + CAST ( col1 AS INTEGER ) * - col1 FROM tab2 cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-8883
SELECT ALL + + col1 + col0 DIV + cor0.col1 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-8883
SELECT ALL + + col1 + col0 / + cor0.col1 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT ALL col2 * ( col1 ) AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - col0 + - col2 * col1 AS col0 FROM tab2 cor0
----
-1612
-725
-844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8886
SELECT col2 + cor0.col2 * CAST( 99 AS SIGNED ) AS col1 FROM tab1 cor0
----
5400
5700
9600

skipif mysql # not compatible
query I rowsort label-8886
SELECT col2 + cor0.col2 * CAST ( 99 AS INTEGER ) AS col1 FROM tab1 cor0
----
5400
5700
9600

query I rowsort
SELECT cor0.col1 + - col0 * + col1 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + - col2 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - + col2 - - col1 * ( col0 ) AS col0 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT - 92 * col1 - 55 * + col2 * col0 FROM tab1 AS cor0
----
-11302
-201560
-423596

query I rowsort
SELECT + - col1 * col2 + col2 + col1 * col1 AS col0 FROM tab0 cor0
----
4591
901
9313

query I rowsort
SELECT ALL col1 + col0 * col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-8894
SELECT + col1 DIV + 8 FROM tab0
----
10
11
12

skipif mysql # not compatible
query I rowsort label-8894
SELECT + col1 / + 8 FROM tab0
----
10
11
12

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT col2 + + col2 * col1 * - col0 FROM tab2 AS cor0
----
-119626
-50996
-5832

query I rowsort
SELECT - + col1 * + col1 + - 32 * + ( - col2 ) * + cor0.col1 AS col2 FROM tab0 AS cor0
----
-6305
230503
83420

query I rowsort
SELECT + 92 - + col0 * - 99 AS col2 FROM tab1 AS cor0
----
389
6428
8012

query I rowsort
SELECT - + col0 * + col0 * + ( - col0 ) + col2 * 65 AS col0 FROM tab2 cor0
----
2098
476242
495509

skipif mysql # not compatible
query I rowsort
SELECT col1 * CAST ( col0 AS REAL ) FROM tab0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8901
SELECT CAST( - col1 AS SIGNED ) * tab0.col2 FROM tab0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-8901
SELECT CAST ( - col1 AS INTEGER ) * tab0.col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT 38 AS col2 FROM tab2, tab2 AS cor0
----
38

query I rowsort
SELECT col1 * cor0.col1 + col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + ( + col2 ) * - cor0.col0 + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT - 77 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-18
-46
-60

query I rowsort
SELECT - col2 * 2 * col0 AS col2 FROM tab2
----
-378
-4056
-6004

query I rowsort
SELECT DISTINCT + ( col1 ) AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT col2 + + col0 * col2 FROM tab1
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8909
SELECT DISTINCT - CAST( 70 AS SIGNED ) AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
-70

skipif mysql # not compatible
query I rowsort label-8909
SELECT DISTINCT - CAST ( 70 AS INTEGER ) AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
-70

query I rowsort
SELECT + col1 + + col0 * - col1 * - col2 AS col1 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT DISTINCT + tab1.col2 AS col2 FROM tab1, tab0, tab0 AS cor0
----
54
57
96

query I rowsort
SELECT 31 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT + col0 * + 5 * - col1 FROM tab1
----
-3200
-390
-5200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8914
SELECT - col1 * + CAST( col2 AS SIGNED ) + col1 - 16 FROM tab0 AS cor0
----
-16
-2768
-7387

skipif mysql # not compatible
query I rowsort label-8914
SELECT - col1 * + CAST ( col2 AS INTEGER ) + col1 - 16 FROM tab0 AS cor0
----
-16
-2768
-7387

query I rowsort
SELECT ALL col2 * + 16 FROM tab1
----
1536
864
912

query I rowsort
SELECT ALL cor0.col2 * 62 AS col0 FROM tab0 AS cor0
----
2046
5084
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8917
SELECT DISTINCT col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8917
SELECT DISTINCT col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT cor0.col1 - - col1 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + tab1.col0 - - cor0.col0 AS col0 FROM tab1, tab1 cor0
----
128
144
160
6
67
83

query I rowsort
SELECT DISTINCT - ( + cor0.col0 ) + col0 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - - col1 * ( + col2 ) AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col1 * + ( ( + col2 ) * col2 + - col2 ) AS col0 FROM tab2 AS cor0
----
21762
23902
38350

query I rowsort
SELECT 35 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 41 col1 FROM tab1
----
137
95
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - col2 ) + + col0 * col2 col0 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT col2 - ( - col1 + + col2 ) FROM tab0 AS cor0
----
86
91
97

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
3645 values hashing to 42d854e4c33cb5afd5528228bff9250d

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0 CROSS JOIN tab2, tab1 AS cor1
----
972 values hashing to 92235dbc382d83baa93d6546ed489b0c

onlyif mysql # use DIV operator for integer division
query I rowsort label-8929
SELECT + + col1 + - col1 - col0 DIV 58 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8929
SELECT + + col1 + - col1 - col0 / 58 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL 46 * cor0.col0 + + col0 AS col0 FROM tab2 AS cor0
----
329
3666
3713

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 36 ) col1 FROM tab0 AS cor0
----
-36
-36
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-8932
SELECT cor0.col2 DIV col1 AS col0 FROM tab2 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-8932
SELECT cor0.col2 / col1 AS col0 FROM tab2 cor0
----
0
0
2

query I rowsort
SELECT DISTINCT - col1 * col1 + cor0.col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT ALL + + 10 AS col0 FROM tab0 cor0
----
10
10
10

query I rowsort
SELECT ALL - col2 * - cor0.col1 - + col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT + ( col2 ) * + col0 + cor0.col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - 53 * 29 FROM tab2 AS cor0
----
-1537
-1537
-1537

query I rowsort
SELECT DISTINCT - - ( 72 ) + col1 AS col2 FROM tab0 AS cor0
----
158
163
169

onlyif mysql # use DIV operator for integer division
query I rowsort label-8939
SELECT - col0 DIV - col1 AS col2 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-8939
SELECT - col0 / - col1 AS col2 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL + col0 * + 98 FROM tab0 AS cor0
----
2352
3430
8722

onlyif mysql # use DIV operator for integer division
query I rowsort label-8941
SELECT col1 DIV col0 + tab0.col1 AS col2 FROM tab0
----
89
92
99

skipif mysql # not compatible
query I rowsort label-8941
SELECT col1 / col0 + tab0.col1 AS col2 FROM tab0
----
89
92
99

query I rowsort
SELECT - 97 * col0 AS col2 FROM tab1 cor0
----
-291
-6208
-7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-8943
SELECT + + 80 DIV cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
4
65
80

skipif mysql # not compatible
query I rowsort label-8943
SELECT + + 80 / cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
4
65
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8944
SELECT + cor0.col0 DIV - col1 AS col2 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-8944
SELECT + cor0.col0 / - col1 AS col2 FROM tab2 AS cor0
----
-1
-4
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8945
SELECT ALL - - col0 * CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8945
SELECT ALL - - col0 * CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + - ( cor0.col1 ) * + col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL - cor1.col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8948
SELECT ALL - cor0.col0 DIV + ( cor0.col1 ) + cor0.col1 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-8948
SELECT ALL - cor0.col0 / + ( cor0.col1 ) + cor0.col1 FROM tab2 AS cor0
----
13
31
58

query I rowsort
SELECT ALL col1 * + col0 + col1 AS col0 FROM tab1
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-8950
SELECT DISTINCT - 23 + + col2 DIV tab2.col1 + col0 FROM tab2
----
-16
55
58

skipif mysql # not compatible
query I rowsort label-8950
SELECT DISTINCT - 23 + + col2 / tab2.col1 + col0 FROM tab2
----
-16
55
58

query I rowsort
SELECT ALL + 98 + col0 + - col2 FROM tab2
----
139
150
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-8952
SELECT ALL ( col0 ) * col1 * col1 + tab0.col0 DIV col2 AS col1 FROM tab0
----
177504
329350
737010

skipif mysql # not compatible
query I rowsort label-8952
SELECT ALL ( col0 ) * col1 * col1 + tab0.col0 / col2 AS col1 FROM tab0
----
177504
329350
737010

query I rowsort
SELECT + 50 + col2 - - col0 * 37 AS col1 FROM tab1
----
215
2475
3106

query I rowsort
SELECT ALL + 22 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-16
-4
-5

query I rowsort
SELECT ALL - 56 + + 3 + - col1 FROM tab1
----
-63
-66
-79

query I rowsort
SELECT DISTINCT + 89 FROM tab1, tab2 AS cor0
----
89

query I rowsort
SELECT ALL - + col2 - + col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + col1 * cor0.col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT col1 + cor0.col1 * ( ( col2 ) + col1 ) * col2 AS col0 FROM tab2 AS cor0
----
130449
35547
48577

query I rowsort
SELECT ALL - 19 * - col1 AS col2 FROM tab1 AS cor0
----
190
247
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-8961
SELECT DISTINCT - col2 + - col0 DIV 81 AS col2 FROM tab0 AS cor0
----
-1
-33
-83

skipif mysql # not compatible
query I rowsort label-8961
SELECT DISTINCT - col2 + - col0 / 81 AS col2 FROM tab0 AS cor0
----
-1
-33
-83

query I rowsort
SELECT col2 + col0 * col0 * - col1 FROM tab1 AS cor0
----
-180
-40903
-83104

query I rowsort
SELECT - - col0 + col1 + - 81 AS col2 FROM tab1 AS cor0
----
-52
-7
12

query I rowsort
SELECT ALL + 24 * col0 FROM tab1 AS cor0
----
1536
1920
72

query I rowsort
SELECT 94 * + col0 * ( + 89 ) + - cor0.col1 + + col2 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
26476
535984
670515

query I rowsort
SELECT col2 + - col2 + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - col0 * col1 * 54 AS col0 FROM tab1 AS cor0
----
-34560
-4212
-56160

onlyif mysql # use DIV operator for integer division
query I rowsort label-8968
SELECT ALL + - ( - col1 ) + col0 DIV - col1 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-8968
SELECT ALL + - ( - col1 ) + col0 / - col1 FROM tab1 AS cor0
----
26
4
7

query I rowsort
SELECT col1 + 96 * + 69 + col2 * ( - 29 ) AS col2 FROM tab0
----
4337
5753
6692

onlyif mysql # use DIV operator for integer division
query I rowsort label-8970
SELECT tab0.col1 + - 65 DIV + col0 + + col2 * 74 FROM tab0
----
170
2526
6159

skipif mysql # not compatible
query I rowsort label-8970
SELECT tab0.col1 + - 65 / + col0 + + col2 * 74 FROM tab0
----
170
2526
6159

query I rowsort
SELECT col0 - - col0 * col1 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT ALL - col0 + + ( + 3 ) * - col1 AS col2 FROM tab1 AS cor0
----
-119
-81
-94

query I rowsort
SELECT + cor1.col2 AS col0 FROM tab2 cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 7eb416b97f0ed263f6364cf59aa64c2b

onlyif mysql # use DIV operator for integer division
query I rowsort label-8975
SELECT ALL - cor0.col1 DIV + cor0.col1 + col1 * col2 AS col2 FROM tab2 AS cor0
----
1533
645
836

skipif mysql # not compatible
query I rowsort label-8975
SELECT ALL - cor0.col1 / + cor0.col1 + col1 * col2 AS col2 FROM tab2 AS cor0
----
1533
645
836

query I rowsort
SELECT ALL col0 * - 99 * + col2 AS col0 FROM tab2 AS cor0
----
-18711
-200772
-297198

onlyif mysql # use DIV operator for integer division
query I rowsort label-8977
SELECT DISTINCT - cor0.col2 + - col2 DIV + 85 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8977
SELECT DISTINCT - cor0.col2 + - col2 / + 85 FROM tab0 AS cor0
----
-1
-33
-82

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-8979
SELECT DISTINCT cor0.col1 DIV 74 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8979
SELECT DISTINCT cor0.col1 / 74 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + cor0.col2 * + 44 * col2 AS col0 FROM tab0 AS cor0
----
295856
44
47916

query I rowsort
SELECT col0 - col0 AS col0 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8982
SELECT cor0.col2 DIV CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8982
SELECT cor0.col2 / CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + - col2 + col2 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT cor0.col2 * - 83 FROM tab1 AS cor0
----
-4482
-4731
-7968

onlyif mysql # use DIV operator for integer division
query I rowsort label-8985
SELECT DISTINCT + col1 * ( - 42 ) + col0 * - cor0.col1 DIV + col1 FROM tab2 AS cor0
----
-1309
-2556
-793

skipif mysql # not compatible
query I rowsort label-8985
SELECT DISTINCT + col1 * ( - 42 ) + col0 * - cor0.col1 / + col1 FROM tab2 AS cor0
----
-1309
-2556
-793

query I rowsort
SELECT - + cor0.col1 * ( col1 * - col1 ) + col0 AS col1 FROM tab0 AS cor0
----
636080
753660
912708

onlyif mysql # use DIV operator for integer division
query I rowsort label-8987
SELECT ALL col1 DIV col0 AS col2 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-8987
SELECT ALL col1 / col0 AS col2 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT DISTINCT - + cor0.col1 * ( + cor0.col2 ) + + col0 AS col0 FROM tab0 cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL - col1 + 47 AS col2 FROM tab0 AS cor0
----
-39
-44
-50

query I rowsort
SELECT - col1 * + col0 * + 90 - - cor0.col1 FROM tab2 AS cor0
----
-120853
-19499
-414121

query I rowsort
SELECT 66 * - 51 AS col0 FROM tab0 AS cor0
----
-3366
-3366
-3366

query I rowsort
SELECT ALL - ( + 23 ) * col1 FROM tab0 AS cor0
----
-1978
-2093
-2231

query I rowsort
SELECT DISTINCT + ( + 52 ) * col1 * col1 FROM tab2 AS cor0
----
15028
181012
49972

query I rowsort
SELECT - + col2 * 47 FROM tab1 cor0
----
-2538
-2679
-4512

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) + - col0 * + cor0.col2 FROM tab0 cor0
----
-34
-7216
-759

query I rowsort
SELECT - + 78 * - 65 AS col1 FROM tab0 AS cor0
----
5070
5070
5070

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * + col2 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col1 + + col2 * + col2 AS col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT ALL + col0 - tab1.col0 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + 32 + cor0.col0 AS col0 FROM tab2 AS cor0
----
110
111
39

query I rowsort
SELECT + 85 + cor0.col1 AS col0 FROM tab2 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to e4c1291c249f1da56499b2fd9f6aa618

query I rowsort
SELECT + col2 * - col2 + col0 AS col0 FROM tab2 cor0
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT - ( - col2 ) * col0 + + 10 * col2 FROM tab1 AS cor0
----
4218
702
8640

query I rowsort
SELECT ( + cor0.col2 ) * - col2 + + col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT col0 * col0 - - col2 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT + + col2 * - col0 + col2 AS col1 FROM tab2 cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-9007
SELECT + col1 * 51 DIV col0 + col2 * 97 AS col0 FROM tab2
----
2560
2844
3696

skipif mysql # not compatible
query I rowsort label-9007
SELECT + col1 * 51 / col0 + col2 * 97 AS col0 FROM tab2
----
2560
2844
3696

query I rowsort
SELECT + + 16 AS col1 FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT + + col2 - - col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT 21 + 76 FROM tab2 AS cor0
----
97
97
97

query I rowsort
SELECT + col1 * + col0 + - ( + cor0.col2 + col1 ) AS col1 FROM tab0 AS cor0
----
1945
3297
7926

onlyif mysql # use DIV operator for integer division
query I rowsort label-9012
SELECT col1 + - col0 + - col2 DIV col2 AS col2 FROM tab0
----
1
61
61

skipif mysql # not compatible
query I rowsort label-9012
SELECT col1 + - col0 + - col2 / col2 AS col2 FROM tab0
----
1
61
61

query I rowsort
SELECT - 71 * col1 + col2 + col1 * col0 FROM tab2 AS cor0
----
-1957
174
439

query I rowsort
SELECT 85 * - col2 * col2 FROM tab2
----
-122740
-57460
-61965

onlyif mysql # use DIV operator for integer division
query I rowsort label-9015
SELECT - 30 DIV 40 col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9015
SELECT - 30 / 40 col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9016
SELECT + CAST( + 49 + col2 AS SIGNED ) DIV + ( - 92 ) col1 FROM tab0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9016
SELECT + CAST ( + 49 + col2 AS INTEGER ) / + ( - 92 ) col1 FROM tab0
----
-1
0
0

query I rowsort
SELECT DISTINCT cor0.col0 + + 92 FROM tab0, tab2 AS cor0
----
170
171
99

query I rowsort
SELECT ALL cor0.col1 * - ( + 29 ) AS col2 FROM tab1 AS cor0
----
-290
-377
-754

query I rowsort
SELECT DISTINCT col1 * 74 + - col1 AS col0 FROM tab2 cor0
----
1241
2263
4307

query I rowsort
SELECT + - col2 * - col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col0 + cor0.col2 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + - col0 + - cor0.col2 * 55 AS col2 FROM tab1 AS cor0
----
-2973
-3199
-5360

query I rowsort
SELECT col1 * 50 AS col2 FROM tab1 AS cor0
----
1300
500
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9024
SELECT + + col1 * CAST( + 71 * col0 AS SIGNED ) FROM tab1 AS cor0
----
45440
5538
73840

skipif mysql # not compatible
query I rowsort label-9024
SELECT + + col1 * CAST ( + 71 * col0 AS INTEGER ) FROM tab1 AS cor0
----
45440
5538
73840

onlyif mysql # use DIV operator for integer division
query I rowsort label-9025
SELECT - - cor0.col1 DIV col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9025
SELECT - - cor0.col1 / col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9026
SELECT col1 * CAST( - cor0.col0 AS SIGNED ) + cor0.col1 FROM tab1 cor0
----
-1027
-52
-630

skipif mysql # not compatible
query I rowsort label-9026
SELECT col1 * CAST ( - cor0.col0 AS INTEGER ) + cor0.col1 FROM tab1 cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-9027
SELECT ALL - col0 + - col2 DIV 75 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-9027
SELECT ALL - col0 + - col2 / 75 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 17 + col0 col1 FROM tab2 AS cor0
----
24
95
96

query I rowsort
SELECT + col1 + 59 FROM tab2 AS cor0
----
118
76
90

query I rowsort
SELECT ALL + - ( - col0 ) AS col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT ALL ( - col0 ) * + col1 FROM tab2
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9032
SELECT CAST( col2 * + col2 AS SIGNED ) + 93 FROM tab0
----
1182
6817
94

skipif mysql # not compatible
query I rowsort label-9032
SELECT CAST ( col2 * + col2 AS INTEGER ) + 93 FROM tab0
----
1182
6817
94

query I rowsort
SELECT ALL - 75 * - col1 + - col0 FROM tab2 AS cor0
----
1196
2318
4347

onlyif mysql # use DIV operator for integer division
query I rowsort label-9034
SELECT DISTINCT - col2 DIV col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9034
SELECT DISTINCT - col2 / col1 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + col0 * col0 * + col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT ALL - cor0.col0 * - cor0.col2 + - col1 + col0 FROM tab2 AS cor0
----
165
2047
3064

query I rowsort
SELECT DISTINCT 23 AS col2 FROM tab2
----
23

query I rowsort
SELECT DISTINCT - + col2 * + col2 + - 80 AS col0 FROM tab2 AS cor0
----
-1524
-756
-809

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL 43 - col0 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
1386
260
4645

query I rowsort
SELECT ALL ( - col0 + - 13 * tab0.col2 ) FROM tab0
----
-1155
-453
-48

query I rowsort
SELECT - + col0 + - cor0.col0 * + 89 AS col2 FROM tab2 AS cor0
----
-630
-7020
-7110

onlyif mysql # use DIV operator for integer division
query I rowsort label-9043
SELECT - col1 - col1 DIV - col0 FROM tab1
----
-10
-13
-18

skipif mysql # not compatible
query I rowsort label-9043
SELECT - col1 - col1 / - col0 FROM tab1
----
-10
-13
-18

query I rowsort
SELECT + 32 + - col2 AS col0 FROM tab2
----
-6
5
6

query I rowsort
SELECT ALL + cor0.col2 * cor0.col0 + col0 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9046
SELECT DISTINCT CAST( - col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-9046
SELECT DISTINCT CAST ( - col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - col1 * 71 AS col0 FROM tab1
----
-1846
-710
-923

query I rowsort
SELECT - + 6 * col0 AS col2 FROM tab0 AS cor0
----
-144
-210
-534

query I rowsort
SELECT DISTINCT - + col2 + col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9050
SELECT DISTINCT CAST( NULL AS SIGNED ) * + col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9050
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col0 - - col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - - 94 AS col2 FROM tab0 AS cor0
----
94
94
94

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col0 + + CAST ( col0 AS REAL ) FROM tab1
----
128
160
6

query I rowsort
SELECT ALL - col2 + + 77 * tab0.col1 FROM tab0
----
6589
6925
7468

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + ( 50 ) col2 FROM tab0
----
-36
-41
-47

onlyif mysql # use DIV operator for integer division
query I rowsort label-9056
SELECT ALL + col0 + ( tab1.col1 ) * col0 DIV - 49 + + 21 * - tab1.col2 FROM tab1
----
-1132
-1146
-1957

skipif mysql # not compatible
query I rowsort label-9056
SELECT ALL + col0 + ( tab1.col1 ) * col0 / - 49 + + 21 * - tab1.col2 FROM tab1
----
-1132
-1146
-1957

query I rowsort
SELECT DISTINCT 38 + + tab1.col2 AS col0 FROM tab1
----
134
92
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-9058
SELECT - 31 + col0 DIV + col0 FROM tab1
----
-30
-30
-30

skipif mysql # not compatible
query I rowsort label-9058
SELECT - 31 + col0 / + col0 FROM tab1
----
-30
-30
-30

onlyif mysql # use DIV operator for integer division
query I rowsort label-9059
SELECT ALL - 2 + col1 DIV - col1 FROM tab0
----
-3
-3
-3

skipif mysql # not compatible
query I rowsort label-9059
SELECT ALL - 2 + col1 / - col1 FROM tab0
----
-3
-3
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9060
SELECT CAST( NULL AS SIGNED ) + - col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9060
SELECT CAST ( NULL AS INTEGER ) + - col2 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT tab1.col0 + col1 * - col1 AS col0 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT + ( col2 ) * col1 * + ( - col1 * col2 ) FROM tab2 AS cor0
----
-2353156
-417316
-700569

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9063
SELECT - - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9063
SELECT - - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 48 * + 6 col0 FROM tab1 AS cor0
----
-288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - 63 col2 FROM tab1 AS cor0
----
-189
-4032
-5040

onlyif mysql # use DIV operator for integer division
query I rowsort label-9066
SELECT + CAST( col1 AS SIGNED ) * - col1 + col2 DIV + col2 AS col1 FROM tab1 AS cor0
----
-168
-675
-99

skipif mysql # not compatible
query I rowsort label-9066
SELECT + CAST ( col1 AS INTEGER ) * - col1 + col2 / + col2 AS col1 FROM tab1 AS cor0
----
-168
-675
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9067
SELECT DISTINCT col2 * col0 DIV - tab1.col2 AS col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-9067
SELECT DISTINCT col2 * col0 / - tab1.col2 AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT + col2 * col2 + - col1 * col0 * col1 + col1 FROM tab0
----
-176329
-329217
-730194

query I rowsort
SELECT DISTINCT + col1 FROM tab2 WHERE ( + col0 - + col2 * col1 ) IN ( + col1 + + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9070
SELECT DISTINCT col1 DIV tab1.col2 col1 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9070
SELECT DISTINCT col1 / tab1.col2 col1 FROM tab1
----
0

query I rowsort
SELECT col2 * tab0.col2 * - col2 AS col0 FROM tab0 WHERE NOT tab0.col0 * + col2 - col2 NOT BETWEEN ( col2 + col1 ) AND NULL
----

query I rowsort
SELECT + col2 + + col2 AS col0 FROM tab0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-9073
SELECT col0 * + col0 DIV + col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-9073
SELECT col0 * + col0 / + col0 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9074
SELECT ALL col0 DIV - col1 col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9074
SELECT ALL col0 / - col1 col1 FROM tab0
----
0
0
0

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL IN ( - col0 * - col0 / - col2 )
----

query I rowsort
SELECT ALL col0 + col1 + col2 FROM tab1
----
131
189
83

query I rowsort
SELECT DISTINCT tab1.col2 + col1 + col0 * col1 AS col1 FROM tab1
----
1149
158
707

query I rowsort
SELECT ALL - col0 + col1 + tab0.col0 AS col0 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9079
SELECT col0 + - col0 * col0 DIV - col2 FROM tab1
----
135
146
3

skipif mysql # not compatible
query I rowsort label-9079
SELECT col0 + - col0 * col0 / - col2 FROM tab1
----
135
146
3

query I rowsort
SELECT col1 + - col2 + col1 AS col2 FROM tab1
----
-2
-37
-70

query I rowsort
SELECT ALL col1 * tab2.col1 * col1 FROM tab2
----
205379
29791
4913

query I rowsort
SELECT tab2.col0 FROM tab2 WHERE - col2 + col2 NOT BETWEEN + col1 AND col1
----
7
78
79

query I rowsort
SELECT col1 FROM tab0 WHERE NULL IN ( + tab0.col1 )
----

query I rowsort
SELECT DISTINCT col2 * col1 + tab1.col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT - col1 * - col2 + - col2 AS col1 FROM tab2
----
1508
608
810

query I rowsort
SELECT DISTINCT col2 * + tab2.col0 AS col2 FROM tab2
----
189
2028
3002

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) NOT IN ( + col1 * col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( NULL ) IN ( col0 * col0 + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 col0 FROM tab0
----
172
182
194

query I rowsort
SELECT col2 FROM tab2 WHERE NOT NULL NOT IN ( tab2.col2 - col1 )
----

query I rowsort
SELECT ALL - col2 - - col0 * col2 AS col1 FROM tab0
----
34
7216
759

query I rowsort
SELECT - col1 * col1 + + col1 AS col1 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT col0 * col2 + - col2 AS col1 FROM tab1
----
108
3591
7584

query I rowsort
SELECT DISTINCT + col2 + col2 * + col1 + - col0 AS col0 FROM tab0 AS cor0 WHERE col2 IN ( col0 ) OR ( NULL ) IN ( + col0 + col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col2 col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - - col0 * + col1 + + col0 * col0 * + col1 FROM tab0 cor0
----
122220
51600
728910

query III rowsort
SELECT * FROM tab2 WHERE - col1 + - col2 * col0 NOT BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 col2 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9099
SELECT col1 DIV - col0 + - col0 * col1 - + col0 AS col2 FROM tab0 cor0
----
-2091
-3432
-8189

skipif mysql # not compatible
query I rowsort label-9099
SELECT col1 / - col0 + - col0 * col1 - + col0 AS col2 FROM tab0 cor0
----
-2091
-3432
-8189

query I rowsort
SELECT DISTINCT + cor0.col0 * - col1 AS col1 FROM tab1 cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

onlyif mysql # use DIV operator for integer division
query I rowsort label-9102
SELECT col1 DIV - cor0.col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-9102
SELECT col1 / - cor0.col0 FROM tab0 AS cor0
----
-1
-2
-3

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT col0 * + col2 BETWEEN ( NULL ) AND ( NULL )
----

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 cor2
----
972 values hashing to 7942394eb7766dfb9ea95b7805ff595d

query I rowsort
SELECT ALL + cor0.col1 + 41 FROM tab2 AS cor0
----
100
58
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-9106
SELECT DISTINCT + cor0.col2 + col1 DIV + ( col1 + + 54 ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-9106
SELECT DISTINCT + cor0.col2 + col1 / + ( col1 + + 54 ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + col0 * 22 + + cor0.col1 * + col1 + 48 FROM tab1 cor0
----
1556
1977
790

query I rowsort
SELECT DISTINCT cor0.col0 * + ( col1 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - col0 * 45 + col0 AS col0 FROM tab2 AS cor0
----
-308
-3432
-3476

onlyif mysql # use DIV operator for integer division
query I rowsort label-9110
SELECT + 16 DIV col1 + cor0.col2 - col1 * + cor0.col2 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif mysql # not compatible
query I rowsort label-9110
SELECT + 16 / col1 + cor0.col2 - col1 * + cor0.col2 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9111
SELECT ALL + - CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-9111
SELECT ALL + - CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + - 45 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1080
-1575
-4005

query I rowsort
SELECT 38 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT - 71 + + 54 FROM tab1, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT col0 * col1 + - col2 AS col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + cor0.col0 * + col1 + + 1 AS col0 FROM tab2 AS cor0
----
1344
218
4603

onlyif mysql # use DIV operator for integer division
query I rowsort label-9117
SELECT + cor1.col1 DIV cor1.col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

skipif mysql # not compatible
query I rowsort label-9117
SELECT + cor1.col1 / cor1.col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT ALL col0 - col2 * col0 * col1 AS col0 FROM tab1
----
-36416
-4209
-99760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9119
SELECT col1 + col1 DIV col1 AS col1 FROM tab2
----
18
32
60

skipif mysql # not compatible
query I rowsort label-9119
SELECT col1 + col1 / col1 AS col1 FROM tab2
----
18
32
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9120
SELECT + col2 + col2 * CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9120
SELECT + col2 + col2 * CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( - col2 ) + - col2 FROM tab2
----
-52
-54
-76

query I rowsort
SELECT + col2 + col2 * + tab2.col0 AS col1 FROM tab2
----
2054
216
3040

query I rowsort
SELECT - col1 * + col2 + - 75 FROM tab2
----
-1609
-721
-912

query I rowsort
SELECT DISTINCT 53 AS col2 FROM tab1
----
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 col1 FROM tab1, tab2 cor0, tab1 cor1
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

query I rowsort
SELECT col1 * - col2 + col0 * + tab0.col1 AS col0 FROM tab0
----
-774
3298
637

query I rowsort
SELECT ALL + tab0.col1 + - 48 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 957f4010cec8e565c841d8267fddae0b

query I rowsort
SELECT ALL 4 + cor0.col0 * + col0 FROM tab2 AS cor0
----
53
6088
6245

query I rowsort
SELECT DISTINCT col0 - 70 FROM tab0 AS cor0
----
-35
-46
19

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab0, tab1 AS cor0, tab0 cor1
----
1
33
82

query I rowsort
SELECT ALL col2 * + col0 * col0 AS col0 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT - ( - 95 ) FROM tab1 AS cor0
----
95
95
95

query I rowsort
SELECT col2 * - col2 * col0 - - col0 * tab1.col1 FROM tab1
----
-207296
-736240
-8670

query I rowsort
SELECT + - tab0.col0 AS col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT - 44 + - col1 * - col2 AS col0 FROM tab1
----
1204
1360
526

query I rowsort
SELECT - 3 * + col0 AS col1 FROM tab2
----
-21
-234
-237

onlyif mysql # use DIV operator for integer division
query I rowsort label-9137
SELECT - ( tab0.col2 ) DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9137
SELECT - ( tab0.col2 ) / col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - - cor0.col2 * col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + 98 FROM tab0
----
98
98
98

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT 38 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT DISTINCT - tab0.col0 * + 70 FROM tab0, tab0 AS cor0
----
-1680
-2450
-6230

query I rowsort
SELECT + - 59 * col1 AS col1 FROM tab2 AS cor0
----
-1003
-1829
-3481

onlyif mysql # use DIV operator for integer division
query I rowsort label-9144
SELECT DISTINCT + cor0.col1 DIV - col1 AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9144
SELECT DISTINCT + cor0.col1 / - col1 AS col2 FROM tab0 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9145
SELECT col0 + col2 DIV CAST( - 25 + col2 AS SIGNED ) FROM tab2 AS cor0
----
104
20
81

skipif mysql # not compatible
query I rowsort label-9145
SELECT col0 + col2 / CAST ( - 25 + col2 AS INTEGER ) FROM tab2 AS cor0
----
104
20
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-9146
SELECT DISTINCT + col1 DIV col0 AS col2 FROM tab1
----
0
8

skipif mysql # not compatible
query I rowsort label-9146
SELECT DISTINCT + col1 / col0 AS col2 FROM tab1
----
0
8

query I rowsort
SELECT col2 * col0 * 37 FROM tab0 AS cor0
----
1295
270026
29304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * col1 * 13 col2 FROM tab0 AS cor0
----
105287
26832
44135

query I rowsort
SELECT ALL col2 + + col0 * col2 + col0 * col2 FROM tab0
----
14678
1617
71

query I rowsort
SELECT DISTINCT - col0 * - col1 + tab1.col2 AS col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT DISTINCT - col0 * - col1 * - col2 - + col2 * col2 FROM tab0 AS cor0
----
-3396
-670842
-69201

query I rowsort
SELECT DISTINCT - col1 * + col2 + col0 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL - - col2 * + cor0.col1 * col0 + + cor0.col0 FROM tab1 cor0
----
36544
4215
99920

query I rowsort
SELECT ALL - + col1 * - col2 * col2 AS col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT ALL - col1 * + col1 + col1 AS col0 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT DISTINCT cor0.col1 * col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

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-9158
SELECT ALL + col0 + col0 * col2 DIV + col2 FROM tab0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-9158
SELECT ALL + col0 + col0 * col2 / + col2 FROM tab0
----
178
48
70

query I rowsort
SELECT col1 - + tab2.col2 * col0 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - - col0 * - cor0.col0 + col2 * cor0.col1 * - col0 + - col1 * + cor0.col1 FROM tab1 cor0
----
-106409
-40676
-4897

query I rowsort
SELECT - 95 * col1 + col1 AS col0 FROM tab2 AS cor0
----
-1598
-2914
-5546

query I rowsort
SELECT DISTINCT col0 * - col2 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL + ( col2 ) - - cor0.col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT 19 + + col0 * col1 FROM tab1 AS cor0
----
1059
659
97

query I rowsort
SELECT DISTINCT + col0 + - cor0.col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT - ( - cor0.col1 ) * - col2 - - col1 * col2 * - col1 AS col1 FROM tab1 AS cor0
----
-17472
-37908
-6270

query I rowsort
SELECT - 60 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-53
18
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-9168
SELECT - col0 DIV + col1 + - col2 FROM tab2 AS cor0
----
-27
-27
-42

skipif mysql # not compatible
query I rowsort label-9168
SELECT - col0 / + col1 + - col2 FROM tab2 AS cor0
----
-27
-27
-42

query I rowsort
SELECT + cor0.col2 - - col1 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - cor0.col1 - + col0 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-9171
SELECT col2 + col0 DIV - col2 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-9171
SELECT col2 + col0 / - col2 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT ALL ( col0 ) * - col2 * col0 FROM tab1
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col2 FROM tab0, tab1, tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - col1 * cor0.col0 + col2 - col0 FROM tab2 AS cor0
----
-1384
-197
-4654

query I rowsort
SELECT ALL 48 AS col2 FROM tab2
----
48
48
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-9176
SELECT + 88 DIV ( tab0.col1 ) FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9176
SELECT + 88 / ( tab0.col1 ) FROM tab0
----
0
0
1

query I rowsort
SELECT - ( + col2 ) * col2 AS col1 FROM tab2
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 27 - col1 * cor0.col2 col2 FROM tab2 AS cor0
----
-1507
-619
-810

query I rowsort
SELECT col2 * col1 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT + tab1.col2 * col0 * - col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + col1 * col1 * tab1.col2 + col2 FROM tab1
----
16320
36558
5757

onlyif mysql # use DIV operator for integer division
query I rowsort label-9182
SELECT + cor0.col1 DIV - col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-9182
SELECT + cor0.col1 / - col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT - - 27 + cor0.col1 + col0 * - col2 AS col2 FROM tab1 AS cor0
----
-109
-3611
-7640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + + col0 * col0 * col1 + + col2 col2 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT + col0 + ( col2 ) * + col0 * + 65 FROM tab2 AS cor0
----
12292
131898
195209

query I rowsort
SELECT ALL - 59 AS col2 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 582c5aa5e5b4fc3f2ea27e7637992d1f

skipif mysql # not compatible
query I rowsort
SELECT + col0 * CAST ( + col0 AS REAL ) * + col0 - - col2 AS col1 FROM tab2 AS cor0
----
370
474578
493077

query I rowsort
SELECT col2 * + ( 56 ) - col2 AS col2 FROM tab2 AS cor0
----
1430
1485
2090

query I rowsort
SELECT cor0.col1 * + 59 FROM tab2 AS cor0
----
1003
1829
3481

query I rowsort
SELECT DISTINCT + col0 * col1 + + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT ( tab2.col0 ) * col0 AS col2 FROM tab2
----
49
6084
6241

query I rowsort
SELECT col1 + col0 + - ( ( + col1 ) + - col1 ) * - col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT + col1 * - col0 + col1 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-9194
SELECT ALL - cor0.col2 + cor0.col0 + col2 DIV col0 FROM tab2 AS cor0
----
-17
41
52

skipif mysql # not compatible
query I rowsort label-9194
SELECT ALL - cor0.col2 + cor0.col0 + col2 / col0 FROM tab2 AS cor0
----
-17
41
52

query I rowsort
SELECT + ( col0 ) + + col1 * col2 AS col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9196
SELECT ALL + col1 * - col0 * col1 + col2 * - ( col1 * CAST( NULL AS SIGNED ) ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9196
SELECT ALL + col1 * - col0 * col1 + col2 * - ( col1 * CAST ( NULL AS INTEGER ) ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * ( cor0.col1 ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + 62 * col1 FROM tab0 AS cor0
----
5332
5642
6014

query I rowsort
SELECT ALL + - 7 + + 22 + + col1 FROM tab0 cor0
----
101
106
112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9200
SELECT - CAST( NULL AS DECIMAL ) + ( col1 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9200
SELECT - CAST ( NULL AS REAL ) + ( col1 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col1 * - 24 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to cac8976e86a80df9f79fe0a19c4247fb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9202
SELECT ALL - col1 / + CAST( NULL AS SIGNED ) + col0 * col2 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9202
SELECT ALL - col1 / + CAST ( NULL AS INTEGER ) + col0 * col2 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 + 91 * col1 FROM tab0
----
7912
8372
8924

query I rowsort
SELECT ALL col0 * + ( + col2 ) + col2 FROM tab1
----
216
3705
7776

query I rowsort
SELECT 42 - + col0 AS col0 FROM tab1
----
-22
-38
39

query I rowsort
SELECT - col0 + + 77 FROM tab2 AS cor0
----
-1
-2
70

query I rowsort
SELECT ALL - + 13 + col1 + + col0 FROM tab2 AS cor0
----
124
25
83

query I rowsort
SELECT DISTINCT + col2 + - 12 * + col0 FROM tab2 cor0
----
-57
-910

query I rowsort
SELECT ALL - + cor0.col2 * - 24 - col2 * + col1 AS col2 FROM tab0 AS cor0
----
-2046
-5494
-73

query I rowsort
SELECT + col2 * - ( - cor0.col2 ) FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT + 81 FROM tab1, tab1 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT - cor1.col1 FROM tab1, tab1 cor0, tab0, tab1 AS cor1
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT ALL + col2 - col2 * cor0.col0 AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - ( col2 * col2 ) + col0 FROM tab1
----
-2913
-3185
-9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9215
SELECT + CAST( - 20 AS SIGNED ) * col1 FROM tab1
----
-200
-260
-520

skipif mysql # not compatible
query I rowsort label-9215
SELECT + CAST ( - 20 AS INTEGER ) * col1 FROM tab1
----
-200
-260
-520

query I rowsort
SELECT DISTINCT + 62 * + col1 AS col1 FROM tab0
----
5332
5642
6014

query I rowsort
SELECT col2 * + tab0.col0 * tab0.col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT - ( - col0 ) * - col1 * - col1 AS col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT + 24 * - col0 FROM tab2 cor0
----
-168
-1872
-1896

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9220
SELECT + cor0.col1 - CAST( NULL AS SIGNED ) / + 88 FROM tab1, tab1 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-9220
SELECT + cor0.col1 - CAST ( NULL AS INTEGER ) / + 88 FROM tab1, tab1 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT ALL - cor0.col2 + 56 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5dc815336c379945dcfdae0956a704a6

query I rowsort
SELECT + ( - cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + 70 * - col0 * col1 FROM tab2 AS cor0
----
-15190
-322140
-94010

query I rowsort
SELECT + col2 + cor0.col0 * + col0 AS col1 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-9225
SELECT - col0 DIV + col2 + col0 * - col0 col0 FROM tab0
----
-1260
-576
-7922

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9225
SELECT - col0 / + col2 + col0 * - col0 col0 FROM tab0
----
-1260
-576
-7922

query I rowsort
SELECT ALL + col1 + col2 * + 17 FROM tab1 AS cor0
----
1645
944
979

onlyif mysql # use DIV operator for integer division
query I rowsort label-9227
SELECT DISTINCT + col1 + ( + col0 ) * - cor0.col0 DIV col0 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-9227
SELECT DISTINCT + col1 + ( + col0 ) * - cor0.col0 / col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL + col0 * 29 + col2 FROM tab1 AS cor0
----
141
1913
2416

query I rowsort
SELECT col2 * + col1 + col1 * col1 + - 48 * col2 AS col0 FROM tab0 AS cor0
----
11807
8650
9458

query I rowsort
SELECT ALL + cor0.col0 + - 73 * 32 AS col1 FROM tab0 AS cor0
----
-2247
-2301
-2312

query I rowsort
SELECT + + col0 + 12 * col2 FROM tab2 AS cor0
----
331
390
535

query I rowsort
SELECT + col0 * - ( 78 ) + cor0.col1 AS col2 FROM tab0 AS cor0
----
-1786
-2633
-6851

query I rowsort
SELECT DISTINCT - + col2 + - ( col2 ) FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - ( 8 ) * col1 FROM tab2 AS cor0
----
-136
-248
-472

query I rowsort
SELECT ALL + - cor0.col2 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT ALL + ( 57 ) AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 23b62d6905061dab566f3a9e15667302

query I rowsort
SELECT col1 * ( + col1 ) * - col1 FROM tab2
----
-205379
-29791
-4913

query I rowsort
SELECT DISTINCT 63 * col1 FROM tab2 AS cor0
----
1071
1953
3717

query I rowsort
SELECT DISTINCT + col1 + col1 * + col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT col1 + col0 + col2 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT - ( + col0 ) + col1 + ( col1 ) AS col0 FROM tab1 AS cor0
----
-44
-54
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-9242
SELECT col2 DIV + 62 + + col2 DIV col0 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9242
SELECT col2 / + 62 + + col2 / col0 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT col2 * col1 + + col1 AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL - col0 + - col2 * col2 * + col2 AS col2 FROM tab0 AS cor0
----
-35961
-36
-551457

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9245
SELECT ALL - col0 + CAST( col2 AS SIGNED ) * col2 FROM tab0 AS cor0
----
-34
1065
6635

skipif mysql # not compatible
query I rowsort label-9245
SELECT ALL - col0 + CAST ( col2 AS INTEGER ) * col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT - + cor0.col0 * col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL col2 * 89 + 73 AS col2 FROM tab1 AS cor0
----
4879
5146
8617

query I rowsort
SELECT DISTINCT + col2 + col2 * col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT - + col2 + col2 + + col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL - cor0.col0 AS col2 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT + + ( - 60 ) + col2 * + col2 FROM tab0 AS cor0
----
-59
1029
6664

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 47906197307eee6829150d762058792a

query I rowsort
SELECT ALL + 47 AS col2 FROM tab0 AS cor0
----
47
47
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-9254
SELECT 43 DIV 72 AS col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9254
SELECT 43 / 72 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - 83 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT DISTINCT - col1 + + tab1.col0 * - 84 FROM tab1
----
-278
-5386
-6733

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 64 col1 FROM tab2, tab0, tab0 cor0
----
-64

query I rowsort
SELECT + 95 * + col1 AS col2 FROM tab2
----
1615
2945
5605

query I rowsort
SELECT ALL + col0 * + col2 + + ( - col2 * + col1 ) AS col1 FROM tab2
----
-648
2356
494

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9260
SELECT DISTINCT cor1.col1 * CAST( NULL AS SIGNED ) - - 44 col2 FROM tab2, tab1 AS cor0, tab1, tab2 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9260
SELECT DISTINCT cor1.col1 * CAST ( NULL AS INTEGER ) - - 44 col2 FROM tab2, tab1 AS cor0, tab1, tab2 AS cor1
----
NULL

query I rowsort
SELECT ( col0 ) * - col0 - 49 AS col2 FROM tab1 AS cor0
----
-4145
-58
-6449

query I rowsort
SELECT + 39 + col0 * 70 - - col0 FROM tab2 AS cor0
----
536
5577
5648

onlyif mysql # use DIV operator for integer division
query I rowsort label-9263
SELECT DISTINCT - 6 DIV + tab1.col1 AS col1 FROM tab1, tab1 cor0, tab1 cor1
----
0

skipif mysql # not compatible
query I rowsort label-9263
SELECT DISTINCT - 6 / + tab1.col1 AS col1 FROM tab1, tab1 cor0, tab1 cor1
----
0

query I rowsort
SELECT ALL + tab0.col0 * ( col1 * col0 ) + 43 FROM tab0
----
118868
49579
720854

query I rowsort
SELECT - cor0.col1 * + 25 FROM tab1 AS cor0
----
-250
-325
-650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9266
SELECT - + cor0.col2 * + CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-9266
SELECT - + cor0.col2 * + CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9267
SELECT ALL col0 / + CAST( NULL AS SIGNED ) + col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9267
SELECT ALL col0 / + CAST ( NULL AS INTEGER ) + col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col2 + + col1 * + col1 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT - col2 + 9 AS col0 FROM tab0 AS cor0
----
-24
-73
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9270
SELECT + col1 + + CAST( NULL AS SIGNED ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9270
SELECT + col1 + + CAST ( NULL AS INTEGER ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 3 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT DISTINCT + 58 * 21 * col0 FROM tab2
----
8526
95004
96222

query I rowsort
SELECT + - ( + col0 ) * cor0.col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col2 * 1 + - col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT + 94 + ( col2 ) * ( col2 ) AS col2 FROM tab1
----
3010
3343
9310

query I rowsort
SELECT + col0 * - col0 + - tab0.col1 * - col2 FROM tab0
----
-1128
-459
2262

query I rowsort
SELECT ALL ( - 39 ) + + col0 + cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
-39
-7248
-807

query I rowsort
SELECT cor0.col0 * - col2 * - col1 + col0 * - col0 - - col1 * + col0 AS col0 FROM tab1 cor0
----
33024
4281
94480

query I rowsort
SELECT + - col2 * cor0.col1 - - col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + col2 * col2 - col2 AS col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT col1 + - col1 - + col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - - col0 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + - 76 * + col2 FROM tab1 AS cor0
----
-4104
-4332
-7296

query I rowsort
SELECT col0 * col1 - - col1 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT 6 + + col0 AS col0 FROM tab1
----
70
86
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9286
SELECT + col1 * col2 DIV col2 + 78 FROM tab1 AS cor0
----
104
88
91

skipif mysql # not compatible
query I rowsort label-9286
SELECT + col1 * col2 / col2 + 78 FROM tab1 AS cor0
----
104
88
91

query I rowsort
SELECT ALL - col1 * - 40 FROM tab1
----
1040
400
520

query I rowsort
SELECT 75 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT ALL + tab0.col0 FROM tab0, tab2 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL tab0.col1 * 96 * - col1 FROM tab0
----
-710016
-794976
-903264

query I rowsort
SELECT col2 + 55 AS col2 FROM tab2
----
81
82
93

query I rowsort
SELECT 75 FROM tab0, tab0 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT DISTINCT 45 FROM tab1, tab2, tab1 AS cor0, tab1 AS cor1
----
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + ( col0 ) + + col1 col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9295
SELECT DISTINCT + col0 * CAST( NULL AS SIGNED ) + + col0 * col0 * + col0 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9295
SELECT DISTINCT + col0 * CAST ( NULL AS INTEGER ) + + col0 * col0 * + col0 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col1 + - 51 FROM tab2 AS cor0
----
-20
-34
8

query I rowsort
SELECT DISTINCT - cor0.col2 * + col2 FROM tab0 cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-9298
SELECT - - col1 DIV 78 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9298
SELECT - - col1 / 78 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL col0 * col1 + col0 * - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - 21 + - col1 FROM tab1 cor0
----
-31
-34
-47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 * - 64 + + col2 col2 FROM tab1 AS cor0
----
-138
-4039
-5024

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 79 * col2 col0 FROM tab2 AS cor0
----
2054
2133
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9303
SELECT DISTINCT - - CAST( col0 AS SIGNED ) * - col2 FROM tab1 cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-9303
SELECT DISTINCT - - CAST ( col0 AS INTEGER ) * - col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + + 11 + col1 FROM tab1 AS cor0
----
21
24
37

query I rowsort
SELECT DISTINCT + + 70 * 26 + + col2 FROM tab1 AS cor0
----
1874
1877
1916

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - col1 ) col0 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9307
SELECT DISTINCT CAST( NULL AS DECIMAL ) * + ( col0 * - ( col1 ) + + col2 ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9307
SELECT DISTINCT CAST ( NULL AS REAL ) * + ( col0 * - ( col1 ) + + col2 ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col2 + cor0.col1 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - - 6 + col1 AS col2 FROM tab2 AS cor0
----
23
37
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-9310
SELECT ALL + col1 * col1 DIV - col2 AS col1 FROM tab0 cor0
----
-100
-224
-9409

skipif mysql # not compatible
query I rowsort label-9310
SELECT ALL + col1 * col1 / - col2 AS col1 FROM tab0 cor0
----
-100
-224
-9409

query I rowsort
SELECT + - 38 + + col0 * 86 AS col0 FROM tab0 cor0
----
2026
2972
7616

onlyif mysql # use DIV operator for integer division
query I rowsort label-9312
SELECT ALL 96 * + col1 DIV col1 FROM tab2 AS cor0
----
96
96
96

skipif mysql # not compatible
query I rowsort label-9312
SELECT ALL 96 * + col1 / col1 FROM tab2 AS cor0
----
96
96
96

query I rowsort
SELECT col0 + col1 + col2 FROM tab1 AS cor0
----
131
189
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9314
SELECT ALL - col1 * col2 + col2 DIV + col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-9314
SELECT ALL - col1 * col2 + col2 / + col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + + cor0.col2 * col1 - col0 * - 10 FROM tab0 AS cor0
----
3078
447
8352

query I rowsort
SELECT + - 13 + col1 FROM tab2 cor0
----
18
4
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9317
SELECT DISTINCT CAST( NULL AS DECIMAL ) * - col0 - + col1 * tab0.col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-9317
SELECT DISTINCT CAST ( NULL AS REAL ) * - col0 - + col1 * tab0.col1 FROM tab0
----
NULL

query I rowsort
SELECT 30 + - col0 AS col2 FROM tab2
----
-48
-49
23

query I rowsort
SELECT ALL + col2 * - col1 + 44 AS col2 FROM tab2 AS cor0
----
-1490
-602
-793

query I rowsort
SELECT - - col1 * + col1 + - col2 FROM tab0 AS cor0
----
7363
8199
9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 57 + - col1 * col0 col2 FROM tab0 AS cor0
----
-2007
-3338
-8042

onlyif mysql # use DIV operator for integer division
query I rowsort label-9322
SELECT DISTINCT + col1 DIV col0 + col2 - - col1 FROM tab0 AS cor0
----
100
122
174

skipif mysql # not compatible
query I rowsort label-9322
SELECT DISTINCT + col1 / col0 + col2 - - col1 FROM tab0 AS cor0
----
100
122
174

query I rowsort
SELECT ALL + col0 + + col2 + col1 AS col0 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT + col1 + - 94 * col1 FROM tab1 AS cor0
----
-1209
-2418
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-9325
SELECT - - cor0.col0 DIV col2 + + col1 DIV col0 FROM tab1 AS cor0
----
0
1
8

skipif mysql # not compatible
query I rowsort label-9325
SELECT - - cor0.col0 / col2 + + col1 / col0 FROM tab1 AS cor0
----
0
1
8

query I rowsort
SELECT col0 + + 65 * col1 AS col1 FROM tab0 AS cor0
----
5614
6004
6340

query I rowsort
SELECT + + col0 + ( + col2 ) AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT cor0.col2 * + ( col0 ) + - col1 AS col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT + col2 * 38 + ( - col2 ) * col1 FROM tab1 AS cor0
----
1596
2400
648

query I rowsort
SELECT DISTINCT + tab0.col0 * col2 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL - col0 * tab2.col1 + - 31 AS col1 FROM tab2
----
-1374
-248
-4633

query I rowsort
SELECT DISTINCT + cor0.col2 * + 38 FROM tab1 AS cor0
----
2052
2166
3648

query I rowsort
SELECT - col2 + 55 FROM tab0 AS cor0
----
-27
22
54

query I rowsort
SELECT ALL + + col2 * - col0 + + col2 * + col2 * - 86 FROM tab2 cor0
----
-127186
-60164
-62883

query I rowsort
SELECT DISTINCT - col0 * - col1 - cor0.col1 * col2 * 81 FROM tab2 AS cor0
----
-119652
-50983
-67580

query I rowsort
SELECT DISTINCT col1 * + col2 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - cor0.col1 * col1 + - cor0.col2 FROM tab2 AS cor0
----
-327
-3507
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 32 col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT DISTINCT + tab0.col1 + tab0.col2 AS col2 FROM tab0, tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + 29 FROM tab0, tab1 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL - 26 * - cor0.col0 FROM tab0 cor0
----
2314
624
910

query I rowsort
SELECT cor0.col0 * + 18 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 3c4ff08df58a5604bd56394a0465a92c

query I rowsort
SELECT DISTINCT 13 * cor2.col0 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
1040
39
832

onlyif mysql # use DIV operator for integer division
query I rowsort label-9344
SELECT ALL + col0 DIV - col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9344
SELECT ALL + col0 / - col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - cor0.col0 * cor0.col2 + + 96 AS col0 FROM tab2 AS cor0
----
-1932
-2906
-93

query I rowsort
SELECT DISTINCT + + 71 FROM tab2 cor0
----
71

query I rowsort
SELECT - col1 * + 64 + - col1 * col1 FROM tab2 AS cor0
----
-1377
-2945
-7257

onlyif mysql # use DIV operator for integer division
query I rowsort label-9348
SELECT + - col2 DIV cor0.col2 - - col0 AS col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-9348
SELECT + - col2 / cor0.col2 - - col0 AS col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT - 61 * col2 AS col2 FROM tab2 AS cor0
----
-1586
-1647
-2318

query I rowsort
SELECT col0 + col0 + - col2 FROM tab0
----
15
69
96

query I rowsort
SELECT - col2 + ( col0 * + col2 ) AS col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT - - 84 + col2 * col2 FROM tab2 cor0
----
1528
760
813

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( - col0 AS REAL ) + - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT - col0 * - 64 + col1 FROM tab0 AS cor0
----
1622
2337
5787

onlyif mysql # use DIV operator for integer division
query I rowsort label-9355
SELECT ALL + 85 DIV 39 - - col1 AS col0 FROM tab0 AS cor0
----
88
93
99

skipif mysql # not compatible
query I rowsort label-9355
SELECT ALL + 85 / 39 - - col1 AS col0 FROM tab0 AS cor0
----
88
93
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9356
SELECT + col0 * col2 + + col2 DIV - cor0.col1 AS col0 FROM tab1 AS cor0
----
160
3643
7673

skipif mysql # not compatible
query I rowsort label-9356
SELECT + col0 * col2 + + col2 / - cor0.col1 AS col0 FROM tab1 AS cor0
----
160
3643
7673

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 * + col0 + cor0.col2 col2 FROM tab1 AS cor0
----
-36423
-4158
-99744

onlyif mysql # use DIV operator for integer division
query I rowsort label-9358
SELECT + - col1 DIV - 81 + col1 AS col0 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-9358
SELECT + - col1 / - 81 + col1 AS col0 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT + col1 * + col1 - cor0.col0 AS col2 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT - 71 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-45
-58
-61

query I rowsort
SELECT DISTINCT 17 * + col0 AS col0 FROM tab1 AS cor0
----
1088
1360
51

query I rowsort
SELECT ALL - col0 * + col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + 54 + 6 FROM tab2, tab1 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT - 3 FROM tab2, tab1 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT ALL col2 * + ( col0 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + ( - col2 ) * cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + + 94 + 6 AS col1 FROM tab1 cor0
----
100

query I rowsort
SELECT + ( tab0.col1 ) + tab0.col2 AS col2 FROM tab0, tab1, tab2 AS cor0, tab2
----
81 values hashing to 0bfb8754a07bc9682424fdc2450a2e7a

query I rowsort
SELECT + tab0.col0 + col0 - - ( col0 ) FROM tab0
----
105
267
72

query I rowsort
SELECT col0 * col0 * col2 AS col1 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT ALL - col1 * 89 AS col0 FROM tab2 AS cor0
----
-1513
-2759
-5251

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9372
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9372
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col0 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 85 AS col1 FROM tab1, tab0 AS cor0
----
85

query I rowsort
SELECT ALL - ( + ( col0 ) ) + 27 FROM tab2 AS cor0
----
-51
-52
20

query I rowsort
SELECT - col2 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - + 61 - ( + col0 ) FROM tab1 AS cor0
----
-125
-141
-64

query I rowsort
SELECT DISTINCT - 60 * 31 FROM tab0 AS cor0
----
-1860

query I rowsort
SELECT + 41 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL ( + col0 ) + + col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL + col1 * 28 AS col1 FROM tab1
----
280
364
728

query I rowsort
SELECT ALL col1 * 86 + - col0 FROM tab2
----
1383
2659
4996

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9382
SELECT ALL - CAST( NULL AS SIGNED ) + ( col2 * 10 + + col1 ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9382
SELECT ALL - CAST ( NULL AS INTEGER ) + ( col2 * 10 + + col1 ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 - col0 * + col0 * 38 AS col0 FROM tab1
----
-155658
-243213
-368

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9384
SELECT DISTINCT + ( - col0 ) * col0 + CAST( NULL AS SIGNED ) col1 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9384
SELECT DISTINCT + ( - col0 ) * col0 + CAST ( NULL AS INTEGER ) col1 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9385
SELECT ALL ( - col2 ) DIV col2 + - col1 AS col2 FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-9385
SELECT ALL ( - col2 ) / col2 + - col1 AS col2 FROM tab0
----
-87
-92
-98

query I rowsort
SELECT ALL + 71 + col0 FROM tab1
----
135
151
74

query I rowsort
SELECT DISTINCT - 52 FROM tab1, tab2 cor0, tab1 AS cor1
----
-52

query I rowsort
SELECT ALL - tab1.col1 + + col1 + + col0 * 33 AS col1 FROM tab1
----
2112
2640
99

query I rowsort
SELECT + ( - col1 * + 67 ) FROM tab2
----
-1139
-2077
-3953

query I rowsort
SELECT - ( col2 ) * - 41 FROM tab0 AS cor0
----
1353
3362
41

query I rowsort
SELECT + col1 * - 91 AS col0 FROM tab1 AS cor0
----
-1183
-2366
-910

query I rowsort
SELECT DISTINCT col0 * 34 + col2 + + col2 FROM tab0 cor0
----
1192
3190
882

query I rowsort
SELECT - cor0.col2 * - 72 AS col1 FROM tab1 AS cor0
----
3888
4104
6912

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9395
SELECT ALL - col0 * + CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9395
SELECT ALL - col0 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 3 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT DISTINCT + 64 * + col2 FROM tab2
----
1664
1728
2432

query I rowsort
SELECT DISTINCT col1 + ( + col0 ) * col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
207946
737293
8774

query I rowsort
SELECT + - col1 * col2 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - - col1 + - ( col0 ) FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9401
SELECT ALL + col2 * - CAST( 76 AS SIGNED ) FROM tab1 AS cor0
----
-4104
-4332
-7296

skipif mysql # not compatible
query I rowsort label-9401
SELECT ALL + col2 * - CAST ( 76 AS INTEGER ) FROM tab1 AS cor0
----
-4104
-4332
-7296

query I rowsort
SELECT + col0 + col2 * + cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
244092
679131
9444

query I rowsort
SELECT cor0.col1 + - col1 * col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT col0 + col1 FROM tab2 AS cor0 WHERE ( NULL ) = ( + col1 )
----

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT ( NULL ) NOT IN ( col0 )
----

query I rowsort
SELECT + tab0.col1 * - col0 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT tab2.col0 * col0 AS col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT ALL - col1 / - col1 FROM tab2 WHERE NOT NULL NOT BETWEEN NULL AND ( col2 )
----

query I rowsort
SELECT DISTINCT col2 + - tab1.col2 FROM tab1
----
0

query I rowsort
SELECT ALL - col1 FROM tab0 WHERE NULL NOT IN ( - tab0.col0 )
----

query I rowsort
SELECT col0 + col1 + col0 * - col1 FROM tab1
----
-49
-566
-947

query I rowsort
SELECT + tab2.col0 + + col1 AS col1 FROM tab2
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 * col0 col2 FROM tab2
----
1360
248
4661

query I rowsort
SELECT col0 AS col1 FROM tab1 WHERE NOT + col2 IN ( col0 + - col0 )
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * + tab1.col2 + col2 col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT col1 + + col1 * col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT col0 * col1 FROM tab1 cor0 WHERE ( NULL ) NOT IN ( col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col1 FROM tab2, tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - col2 + - col0 + col1 AS col1 FROM tab0 AS cor0
----
-80
29
61

query I rowsort
SELECT ALL col1 + col1 * + col0 AS col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT DISTINCT + tab1.col1 * col2 + col0 AS col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT tab2.col1 * + col1 + col2 * - col1 * + col2 + col2 FROM tab2
----
-21611
-24221
-36377

query I rowsort
SELECT col0 + + col0 * col2 + - tab1.col1 AS col0 FROM tab1
----
139
3702
7747

query I rowsort
SELECT DISTINCT + col2 + + col2 * + col2 + + tab1.col2 FROM tab1
----
3024
3363
9408

query I rowsort
SELECT - col2 + + col1 * col1 AS col1 FROM tab2
----
251
3455
934

query I rowsort
SELECT DISTINCT col0 + + col0 * tab1.col0 FROM tab1
----
12
4160
6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-9427
SELECT col0 * tab0.col1 DIV col0 AS col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9427
SELECT col0 * tab0.col1 / col0 AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT tab2.col0 + - col1 * tab2.col0 AS col1 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT tab1.col2 + - col1 FROM tab1
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9430
SELECT tab0.col2 DIV + tab0.col2 + - col1 DIV - col1 AS col2 FROM tab0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-9430
SELECT tab0.col2 / + tab0.col2 + - col1 / - col1 AS col2 FROM tab0
----
2
2
2

query I rowsort
SELECT ALL tab2.col2 * col2 + tab2.col2 * col2 + tab2.col1 AS col0 FROM tab2
----
1411
1489
2905

query I rowsort
SELECT ALL + col0 + - col0 * + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT + + col2 * col1 + + col2 AS col1 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT ALL - col0 + - cor0.col1 AS col1 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT + col0 * col1 + + col2 * cor0.col2 FROM tab2 AS cor0
----
2787
5278
946

query I rowsort
SELECT col1 - col1 * col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL - cor0.col0 * col1 + col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - + cor0.col1 * - col1 - - col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT col0 / col0 FROM tab1 WHERE NOT ( - col2 * + col0 ) NOT IN ( + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9440
SELECT ALL + col2 * col1 DIV - col0 FROM tab0 AS cor0
----
-118
-2
-83

skipif mysql # not compatible
query I rowsort label-9440
SELECT ALL + col2 * col1 / - col0 FROM tab0 AS cor0
----
-118
-2
-83

query I rowsort
SELECT + col2 * + col0 - cor0.col1 AS col2 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-9442
SELECT - + col0 DIV + col0 + + col2 AS col0 FROM tab0 cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-9442
SELECT - + col0 / + col0 + + col2 AS col0 FROM tab0 cor0
----
0
32
81

query I rowsort
SELECT ALL + col2 + col2 * col2 - col2 AS col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT DISTINCT col1 - + col0 * - tab0.col2 FROM tab0
----
132
7389
878

query I rowsort
SELECT DISTINCT tab0.col0 - col2 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL cor0.col2 + + col1 AS col0 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - + cor0.col0 * - col2 * - col1 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + 35 AS col2 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

query I rowsort
SELECT DISTINCT tab0.col2 + col0 - col2 AS col0 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col2 * + col1 - 26 col0 FROM tab1 AS cor0
----
-119834
-32516
-75842

query I rowsort
SELECT ALL cor0.col0 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - 42 - + col1 FROM tab2 AS cor0
----
-101
-59
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9453
SELECT - + col2 + CAST( col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-9453
SELECT - + col2 + CAST ( col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9454
SELECT - col1 * CAST( + ( + col1 ) AS SIGNED ) * + 68 + 44 FROM tab1 cor0
----
-11448
-45924
-6756

skipif mysql # not compatible
query I rowsort label-9454
SELECT - col1 * CAST ( + ( + col1 ) AS INTEGER ) * + 68 + 44 FROM tab1 cor0
----
-11448
-45924
-6756

query I rowsort
SELECT - col1 * - col1 + - ( col0 ) FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT ALL 49 * tab1.col2 FROM tab1
----
2646
2793
4704

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9457
SELECT ALL + col2 * CAST( NULL AS SIGNED ) * - 90 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9457
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) * - 90 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 - 30 FROM tab2 AS cor0
----
-13
1
29

query III rowsort
SELECT * FROM tab0 WHERE + col1 * - col1 * + col2 IN ( - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9460
SELECT + col2 + - col1 DIV + col1 FROM tab2
----
25
26
37

skipif mysql # not compatible
query I rowsort label-9460
SELECT + col2 + - col1 / + col1 FROM tab2
----
25
26
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 * col2 * col1 - col0 * col2 col0 FROM tab2
----
117624
48032
5670

onlyif mysql # use DIV operator for integer division
query I rowsort label-9462
SELECT ALL col1 DIV col2 - - col0 AS col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-9462
SELECT ALL col1 / col2 - - col0 AS col0 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT col0 * - col0 - - tab2.col2 AS col1 FROM tab2
----
-22
-6058
-6203

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col1 NOT IN ( col0 + - col1 )
----

query I rowsort
SELECT DISTINCT + col0 * + col1 + + tab2.col1 FROM tab2 WHERE ( NULL ) NOT IN ( col2 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT - tab1.col1 IN ( col0 / col0 - + col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

onlyif mysql # use DIV operator for integer division
query I rowsort label-9467
SELECT + col0 + + tab1.col1 DIV + col0 AS col1 FROM tab1
----
11
64
80

skipif mysql # not compatible
query I rowsort label-9467
SELECT + col0 + + tab1.col1 / + col0 AS col1 FROM tab1
----
11
64
80

query I rowsort
SELECT - 32 FROM tab2 cor0
----
-32
-32
-32

query I rowsort
SELECT col1 + + col2 * col2 AS col1 FROM tab0
----
1175
6815
98

query I rowsort
SELECT ALL col0 * - tab2.col1 + tab2.col0 AS col1 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT + tab1.col1 - - tab1.col0 AS col2 FROM tab1 WHERE NOT col2 NOT BETWEEN ( col2 ) AND col1 + col1 + + col2
----
29
74
93

query I rowsort
SELECT ALL col2 FROM tab0 WHERE + col1 BETWEEN ( - col1 * col1 ) AND NULL
----

query I rowsort
SELECT + col2 + col0 + - tab2.col1 FROM tab2 WHERE ( NULL ) < - col1
----

query I rowsort
SELECT ALL tab0.col0 + + col2 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT col0 + - col2 * - col0 FROM tab1
----
165
3712
7760

query III rowsort
SELECT * FROM tab2 WHERE NOT ( col2 * + col1 ) NOT IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9477
SELECT DISTINCT col1 + col1 DIV - col2 AS col1 FROM tab0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-9477
SELECT DISTINCT col1 + col1 / - col2 AS col1 FROM tab0
----
0
84
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9478
SELECT - - col1 + cor0.col2 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-9478
SELECT - - col1 + cor0.col2 / cor0.col2 AS col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT + col0 - col0 * 5 AS col0 FROM tab2
----
-28
-312
-316

query I rowsort
SELECT 96 + - col2 FROM tab1
----
0
39
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 13 col1 FROM tab0
----
13
13
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 38 col0 FROM tab0
----
38
38
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 94 col0 FROM tab1
----
94

query I rowsort
SELECT col2 + - ( col0 ) * col1 AS col2 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT cor0.col2 - + col2 * - 45 * - col1 AS col1 FROM tab1 AS cor0
----
-25593
-56064
-63126

query I rowsort
SELECT col0 * - ( - cor0.col2 * - col0 ) + - col0 * col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
-2646
-316368
-474316

query I rowsort
SELECT DISTINCT + col1 * 63 + + tab2.col2 FROM tab2
----
1109
1980
3743

query I rowsort
SELECT 24 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 cor1, tab1 AS cor2
----
972 values hashing to 92235dbc382d83baa93d6546ed489b0c

query I rowsort
SELECT col1 - + 63 FROM tab1 AS cor0
----
-37
-50
-53

query I rowsort
SELECT ALL - col2 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * col2 - + col2 AS col1 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT + - col0 * + col0 + - ( - col2 ) AS col1 FROM tab0 cor0
----
-1224
-543
-7839

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9494
SELECT DISTINCT - col2 / CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9494
SELECT DISTINCT - col2 / CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9495
SELECT col2 - - cor0.col2 * col1 DIV col1 AS col2 FROM tab1 AS cor0
----
108
114
192

skipif mysql # not compatible
query I rowsort label-9495
SELECT col2 - - cor0.col2 * col1 / col1 AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT col1 * ( col0 ) FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + 36 col1 FROM tab0 AS cor0
----
118
37
69

query I rowsort
SELECT DISTINCT + col0 * - ( col2 ) AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9499
SELECT cor0.col2 + CAST( NULL AS SIGNED ) * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9499
SELECT cor0.col2 + CAST ( NULL AS INTEGER ) * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9500
SELECT ALL + col1 + + CAST( NULL AS SIGNED ) * - ( + col1 + col1 ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9500
SELECT ALL + col1 + + CAST ( NULL AS INTEGER ) * - ( + col1 + col1 ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + + col1 * 56 * - col2 - col2 AS col1 FROM tab2 cor0
----
-36176
-46872
-85904

query I rowsort
SELECT 58 * col1 AS col0 FROM tab2 AS cor0
----
1798
3422
986

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9503
SELECT CAST( col1 AS SIGNED ) * + col1 AS col1 FROM tab0 cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-9503
SELECT CAST ( col1 AS INTEGER ) * + col1 AS col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT + - col1 * + 19 FROM tab2 cor0
----
-1121
-323
-589

onlyif mysql # use DIV operator for integer division
query I rowsort label-9505
SELECT + col1 * 60 + - col2 * 30 DIV - cor0.col0 AS col0 FROM tab0 AS cor0
----
5201
5487
5820

skipif mysql # not compatible
query I rowsort label-9505
SELECT + col1 * 60 + - col2 * 30 / - cor0.col0 AS col0 FROM tab0 AS cor0
----
5201
5487
5820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 88 ) + cor0.col1 col2 FROM tab1 AS cor0
----
-62
-75
-78

query I rowsort
SELECT - 24 + col2 AS col2 FROM tab0 cor0
----
-23
58
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9508
SELECT ALL cor0.col2 * - col1 - - CAST( 29 AS SIGNED ) AS col2 FROM tab2 cor0
----
-1505
-617
-808

skipif mysql # not compatible
query I rowsort label-9508
SELECT ALL cor0.col2 * - col1 - - CAST ( 29 AS INTEGER ) AS col2 FROM tab2 cor0
----
-1505
-617
-808

onlyif mysql # use DIV operator for integer division
query I rowsort label-9509
SELECT - - cor0.col0 DIV col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9509
SELECT - - cor0.col0 / col0 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9510
SELECT DISTINCT + 36 DIV - 3 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-12

skipif mysql # not compatible
query I rowsort label-9510
SELECT DISTINCT + 36 / - 3 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col1 ) * - col0 col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col1 * col2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL - 42 * col1 FROM tab1 AS cor0
----
-1092
-420
-546

query I rowsort
SELECT ALL - + col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + - 11 * + col1 AS col0 FROM tab1 AS cor0
----
-110
-143
-286

query I rowsort
SELECT ALL - ( - col0 ) * - col2 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT col2 * col2 + + col0 AS col1 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL + ( + col2 ) + col2 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT - col2 * col2 + col0 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT + + col0 * col1 + col0 * - col0 AS col1 FROM tab1 AS cor0
----
-3456
-5360
69

query I rowsort
SELECT DISTINCT - 61 + + cor0.col2 AS col1 FROM tab1 cor0
----
-4
-7
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-9522
SELECT + 92 DIV - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1
-1
-30

skipif mysql # not compatible
query I rowsort label-9522
SELECT + 92 / - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1
-1
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 46 * col1 col0 FROM tab0 AS cor0
----
3956
4186
4462

query I rowsort
SELECT + 52 * + col0 FROM tab1 AS cor0
----
156
3328
4160

query I rowsort
SELECT ALL cor0.col2 * + col1 + + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT 37 * col1 FROM tab1 AS cor0
----
370
481
962

query I rowsort
SELECT - col0 * + col2 * col0 AS col2 FROM tab1 AS cor0
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-9528
SELECT col0 DIV col1 AS col0 FROM tab1 cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-9528
SELECT col0 / col1 AS col0 FROM tab1 cor0
----
0
6
6

query I rowsort
SELECT DISTINCT + col2 * + col1 + cor0.col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + col2 + col1 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT col1 + 41 * col2 FROM tab2 AS cor0
----
1125
1138
1575

query I rowsort
SELECT - col2 + + col2 * col2 * col1 FROM tab2 AS cor0
----
22572
24510
39858

query I rowsort
SELECT DISTINCT - + 63 * col2 * - col2 + + cor0.col2 AS col2 FROM tab1 cor0
----
183762
204744
580704

query I rowsort
SELECT DISTINCT + ( + 13 ) + col1 AS col0 FROM tab0 AS cor0
----
104
110
99

query I rowsort
SELECT DISTINCT - - col1 + - col2 * cor0.col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + 89 + col0 AS col0 FROM tab1 AS cor0
----
153
169
92

query I rowsort
SELECT ALL col2 * - 82 AS col0 FROM tab0 AS cor0
----
-2706
-6724
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 57 col1 FROM tab1 AS cor0
----
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col0 col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - + 34 FROM tab1 AS cor0
----
-34

query I rowsort
SELECT + + 46 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT ALL + col2 * - 40 + + col1 FROM tab1
----
-2134
-2270
-3827

query I rowsort
SELECT ( - col0 ) + tab2.col2 * - col0 FROM tab2
----
-196
-2106
-3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9544
SELECT ALL CAST( NULL AS SIGNED ) + ( - col1 * col1 ) + col0 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9544
SELECT ALL CAST ( NULL AS INTEGER ) + ( - col1 * col1 ) + col0 AS col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9545
SELECT ALL col2 DIV col1 + - col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-9545
SELECT ALL col2 / col1 + - col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - 68 + - 16 FROM tab2
----
-84

query I rowsort
SELECT DISTINCT 73 + - col1 * - col2 FROM tab2
----
1607
719
910

query I rowsort
SELECT - tab2.col2 + + ( - col0 ) * - col2 AS col2 FROM tab2
----
162
2002
2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - ( + col1 ) * col1 col2 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT 70 + + col2 AS col0 FROM tab2
----
108
96
97

query I rowsort
SELECT DISTINCT - ( + 50 + + col1 * col0 ) AS col2 FROM tab2
----
-1393
-267
-4652

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 94 col2 FROM tab1, tab2 AS cor0
----
94

query I rowsort
SELECT ALL + - col1 * col0 + - cor0.col1 * cor0.col2 FROM tab1 AS cor0
----
-1210
-1482
-2288

query I rowsort
SELECT ALL - 46 + cor0.col0 FROM tab1 AS cor0
----
-43
18
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9555
SELECT ALL + col2 + tab1.col1 * col0 DIV tab1.col1 + - tab1.col2 * col2 FROM tab1
----
-2859
-3128
-9040

skipif mysql # not compatible
query I rowsort label-9555
SELECT ALL + col2 + tab1.col1 * col0 / tab1.col1 + - tab1.col2 * col2 FROM tab1
----
-2859
-3128
-9040

query I rowsort
SELECT + col0 * + col1 + + col1 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-9557
SELECT ALL + col1 * cor0.col2 DIV col1 - - col0 col2 FROM tab2 cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9557
SELECT ALL + col1 * cor0.col2 / col1 - - col0 col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT DISTINCT col1 + - 77 FROM tab0 AS cor0
----
14
20
9

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab0 AS cor1, tab1 cor2
----
972 values hashing to 88213a0de4c0a44aaefe8bbffbcaf44a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 32 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2, tab2 cor3
----
3645 values hashing to b6efe6f7ec1a3daa3cc6ea9dd7d13455

query I rowsort
SELECT DISTINCT ( 6 ) FROM tab0, tab2 AS cor0, tab2, tab2 AS cor1
----
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9563
SELECT ALL - tab2.col1 - CAST( - 66 AS SIGNED ) AS col0 FROM tab2
----
35
49
7

skipif mysql # not compatible
query I rowsort label-9563
SELECT ALL - tab2.col1 - CAST ( - 66 AS INTEGER ) AS col0 FROM tab2
----
35
49
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9564
SELECT DISTINCT col1 - 1 DIV + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9564
SELECT DISTINCT col1 - 1 / + col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9565
SELECT DISTINCT - CAST( 24 * col1 AS SIGNED ) FROM tab1
----
-240
-312
-624

skipif mysql # not compatible
query I rowsort label-9565
SELECT DISTINCT - CAST ( 24 * col1 AS INTEGER ) FROM tab1
----
-240
-312
-624

query I rowsort
SELECT - 62 * col0 AS col0 FROM tab0
----
-1488
-2170
-5518

query I rowsort
SELECT DISTINCT - 56 AS col1 FROM tab0
----
-56

query I rowsort
SELECT + col1 + col2 * - col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT tab0.col0 + - col1 * col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - 36 * col0 AS col0 FROM tab1
----
-108
-2304
-2880

query I rowsort
SELECT DISTINCT - col2 + + col0 + col2 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col2 * col2 AS col1 FROM tab2 cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-9573
SELECT ALL - col2 * - ( col0 ) - col0 DIV - 58 FROM tab0 cor0
----
35
7299
792

skipif mysql # not compatible
query I rowsort label-9573
SELECT ALL - col2 * - ( col0 ) - col0 / - 58 FROM tab0 cor0
----
35
7299
792

query I rowsort
SELECT - - cor0.col0 AS col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - cor0.col1 * - ( 50 ) FROM tab2 AS cor0
----
1550
2950
850

query I rowsort
SELECT DISTINCT - col1 - 71 FROM tab0 AS cor0
----
-157
-162
-168

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col1 AS col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + col2 + ( 61 ) * + col0 FROM tab2 AS cor0
----
454
4784
4857

query I rowsort
SELECT DISTINCT - col0 * 84 AS col0 FROM tab0 AS cor0
----
-2016
-2940
-7476

query I rowsort
SELECT ALL + col1 * - col1 + col0 + + col1 FROM tab1 AS cor0
----
-26
-647
-76

query I rowsort
SELECT DISTINCT + col2 - - ( - col0 ) AS col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT col1 * + col1 - 90 * col1 AS col1 FROM tab2 cor0
----
-1241
-1829

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 22 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to fae46f8148b02964f7145eb6ed5819f9

query I rowsort
SELECT DISTINCT 38 FROM tab2, tab2 cor0
----
38

query I rowsort
SELECT col2 + 83 * 83 * col1 AS col0 FROM tab1
----
179168
68947
89653

query I rowsort
SELECT DISTINCT - tab2.col0 FROM tab2, tab0, tab1 AS cor0, tab0 cor1
----
-7
-78
-79

query I rowsort
SELECT - - col0 + - col0 * col1 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9588
SELECT CAST( NULL AS SIGNED ) + + col0 / + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9588
SELECT CAST ( NULL AS INTEGER ) + + col0 / + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 9 + 74 * col1 AS col2 FROM tab2 AS cor0
----
1249
2285
4357

query I rowsort
SELECT + 46 * + 1 FROM tab2 AS cor0
----
46
46
46

query I rowsort
SELECT + ( 55 ) AS col2 FROM tab1 cor0
----
55
55
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-9592
SELECT ALL 45 DIV - col0 AS col2 FROM tab1 AS cor0
----
-15
0
0

skipif mysql # not compatible
query I rowsort label-9592
SELECT ALL 45 / - col0 AS col2 FROM tab1 AS cor0
----
-15
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9593
SELECT 15 DIV col2 + - col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-9593
SELECT 15 / col2 + - col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + 72 + col0 FROM tab0 AS cor0
----
107
161
96

query I rowsort
SELECT - - col2 * - col0 + - ( + 95 ) FROM tab1 AS cor0
----
-257
-3743
-7775

query I rowsort
SELECT + - cor0.col1 * cor0.col2 + - 63 FROM tab0 AS cor0
----
-160
-2901
-7525

onlyif mysql # use DIV operator for integer division
query I rowsort label-9597
SELECT + col1 DIV - col2 col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9597
SELECT + col1 / - col2 col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 38 * cor0.col2 - + cor1.col2 col1 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 28a71d35075bdc9cbaab5657b41e4fb9

query I rowsort
SELECT ALL + - col2 + cor0.col0 + col1 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT DISTINCT - - cor0.col0 + + col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + 10 + col2 AS col1 FROM tab1 AS cor0
----
106
64
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + - col1 * + col0 col2 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL - 57 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT ALL 11 * - col1 - - 57 * 12 AS col0 FROM tab0 AS cor0
----
-262
-317
-383

query I rowsort
SELECT DISTINCT col1 * + col2 * 47 AS col1 FROM tab2 AS cor0
----
30362
39339
72098

query I rowsort
SELECT col0 * col1 * + ( col2 ) AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - 5 + + col2 FROM tab2 AS cor0
----
21
22
33

query I rowsort
SELECT ALL + ( col0 ) * col2 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 10 col2 FROM tab0
----
10
10
10

query I rowsort
SELECT + 75 * col1 + col0 * + col1 FROM tab0 AS cor0
----
10670
14924
8514

query I rowsort
SELECT - - col2 * + col2 + - col2 AS col1 FROM tab0 cor0
----
0
1056
6642

query I rowsort
SELECT DISTINCT - col0 * - col0 * - 63 AS col0 FROM tab1
----
-258048
-403200
-567

onlyif mysql # use DIV operator for integer division
query I rowsort label-9613
SELECT DISTINCT + col0 DIV 99 AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-9613
SELECT DISTINCT + col0 / 99 AS col0 FROM tab2
----
0

query I rowsort
SELECT - col1 * - ( + col0 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - 18 * 75 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to fe8a09e095e1af9da7a5062a372478a3

query I rowsort
SELECT ALL col2 * col0 + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT + - 61 * 93 FROM tab2 AS cor0
----
-5673
-5673
-5673

query I rowsort
SELECT 62 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 0bc652564a158b9c0f7952026f90b60a

query I rowsort
SELECT DISTINCT + - cor0.col1 * col2 * col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL col2 + cor0.col1 * - cor0.col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT - 47 * - cor0.col0 FROM tab2 AS cor0
----
329
3666
3713

query I rowsort
SELECT - + col1 + + 31 * - col2 AS col2 FROM tab1 AS cor0
----
-1700
-1777
-2989

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9623
SELECT - CAST( ( col2 ) * + 3 AS SIGNED ) - col0 FROM tab2
----
-156
-193
-88

skipif mysql # not compatible
query I rowsort label-9623
SELECT - CAST ( ( col2 ) * + 3 AS INTEGER ) - col0 FROM tab2
----
-156
-193
-88

query I rowsort
SELECT 4 * - 12 FROM tab1 AS cor0
----
-48
-48
-48

query I rowsort
SELECT ALL + - ( + col0 ) * cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + - col2 + col1 + col2 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + 5 AS col2 FROM tab2 AS cor0
----
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9628
SELECT DISTINCT - col2 DIV + col2 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-9628
SELECT DISTINCT - col2 / + col2 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT ALL - cor0.col0 + cor0.col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * 91 + col0 + + col0 AS col2 FROM tab2 AS cor0
----
-2210
-2443
-3300

query I rowsort
SELECT ALL - cor0.col0 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9632
SELECT ALL + CAST( + col1 AS SIGNED ) + cor0.col1 FROM tab2 AS cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-9632
SELECT ALL + CAST ( + col1 AS INTEGER ) + cor0.col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT 1 * cor0.col0 + - col2 * col1 + + col2 * col2 FROM tab2 AS cor0
----
-101
-780
877

query I rowsort
SELECT ALL - 75 * cor0.col2 FROM tab2 cor0
----
-1950
-2025
-2850

onlyif mysql # use DIV operator for integer division
query I rowsort label-9635
SELECT - 29 DIV - col2 + + col1 + 2 * col1 col2 FROM tab1 AS cor0
----
30
39
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9635
SELECT - 29 / - col2 + + col1 + 2 * col1 col2 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT DISTINCT - 79 * + 81 FROM tab1 AS cor0
----
-6399

query I rowsort
SELECT DISTINCT + 33 AS col0 FROM tab1 AS cor0
----
33

query I rowsort
SELECT 29 + + 53 * col0 + col2 * col2 FROM tab2 AS cor0
----
1129
4839
5660

onlyif mysql # use DIV operator for integer division
query I rowsort label-9639
SELECT DISTINCT - + 30 + col2 DIV col0 AS col2 FROM tab2 AS cor0
----
-27
-30

skipif mysql # not compatible
query I rowsort label-9639
SELECT DISTINCT - + 30 + col2 / col0 AS col2 FROM tab2 AS cor0
----
-27
-30

query I rowsort
SELECT ALL + - ( + col2 ) - + cor0.col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT - 54 * cor0.col0 FROM tab2 AS cor0
----
-378
-4212
-4266

query I rowsort
SELECT ALL + - 40 * col1 FROM tab2 cor0
----
-1240
-2360
-680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col2 + ( 4 ) col1 FROM tab1 AS cor0
----
2920
3253
9220

query I rowsort
SELECT DISTINCT - col0 * - col1 + col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL - cor0.col0 + cor0.col2 AS col0 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT col0 + ( - col2 ) AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + cor0.col2 * - ( col1 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - - col2 + col0 * col1 AS col2 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT ALL ( cor0.col2 ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + col2 * ( + 84 ) * col1 AS col2 FROM tab0 AS cor0
----
238392
626808
8148

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9651
SELECT - col2 + CAST( NULL AS SIGNED ) + 47 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9651
SELECT - col2 + CAST ( NULL AS INTEGER ) + 47 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * col0 + 76 FROM tab0
----
2140
3471
8175

query I rowsort
SELECT ALL - + 35 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to 223032c91a0743bba135d21d13b89ec0

query I rowsort
SELECT + col2 * - col2 - col1 AS col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT DISTINCT - - col2 * + col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT col0 + col2 * - 95 FROM tab0 cor0
----
-3111
-60
-7701

query I rowsort
SELECT ALL + - cor0.col2 + - col1 * col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9658
SELECT + CAST( NULL AS DECIMAL ) * + 10 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9658
SELECT + CAST ( NULL AS REAL ) * + 10 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9659
SELECT + CAST( NULL AS DECIMAL ) + + 82 * + col2 + col2 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9659
SELECT + CAST ( NULL AS REAL ) + + 82 * + col2 + col2 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9660
SELECT ALL + + ( + col2 ) * - col1 + + 49 DIV + col1 + col1 FROM tab0 AS cor0
----
-2752
-7371
0

skipif mysql # not compatible
query I rowsort label-9660
SELECT ALL + + ( + col2 ) * - col1 + + 49 / + col1 + col1 FROM tab0 AS cor0
----
-2752
-7371
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 90 col0 FROM tab2 AS cor0
----
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9662
SELECT - col1 DIV col0 + cor0.col0 col0 FROM tab1 AS cor0
----
-5
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9662
SELECT - col1 / col0 + cor0.col0 col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT ALL + ( - cor0.col1 ) * - col0 + + col0 * - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col0 + + col1 * col0 AS col2 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + 47 * + col1 FROM tab2 AS cor0
----
1457
2773
799

query I rowsort
SELECT ALL + col1 + + tab1.col2 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT col1 * + col2 + col0 * - tab2.col2 AS col1 FROM tab2
----
-2356
-494
648

query I rowsort
SELECT - col0 * ( tab2.col0 * tab2.col2 ) FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT - tab1.col0 + col2 * col1 + col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT col0 + - tab0.col1 - col1 * - col2 FROM tab0
----
2776
35
7460

query I rowsort
SELECT - col2 + col0 - tab1.col0 * col2 AS col1 FROM tab1
----
-213
-3641
-7696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9672
SELECT - col1 * ( + 74 ) * col1 + + CAST( NULL AS SIGNED ) - tab0.col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9672
SELECT - col1 * ( + 74 ) * col1 + + CAST ( NULL AS INTEGER ) - tab0.col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9673
SELECT + col1 * col0 * col0 - col0 DIV - col1 AS col0 FROM tab1
----
234
40966
83206

skipif mysql # not compatible
query I rowsort label-9673
SELECT + col1 * col0 * col0 - col0 / - col1 AS col0 FROM tab1
----
234
40966
83206

onlyif mysql # use DIV operator for integer division
query I rowsort label-9674
SELECT ALL - 46 DIV - col1 FROM tab1 AS cor0
----
1
3
4

skipif mysql # not compatible
query I rowsort label-9674
SELECT ALL - 46 / - col1 FROM tab1 AS cor0
----
1
3
4

query I rowsort
SELECT + ( - col1 ) * 84 AS col1 FROM tab2 AS cor0
----
-1428
-2604
-4956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9676
SELECT DISTINCT col2 * + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9676
SELECT DISTINCT col2 * + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 50 * col1 * 0 AS col0 FROM tab0
----
0

query I rowsort
SELECT DISTINCT + - col0 + col2 * + col2 AS col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT ALL 99 * - col1 FROM tab1 AS cor0
----
-1287
-2574
-990

onlyif mysql # use DIV operator for integer division
query I rowsort label-9680
SELECT col1 DIV col1 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-9680
SELECT col1 / col1 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT + - cor0.col1 + - 90 * col1 - cor0.col0 AS col0 FROM tab2 cor0
----
-1626
-2828
-5447

query I rowsort
SELECT ALL + + col1 * + 79 + + cor0.col2 FROM tab1 AS cor0
----
1123
2108
847

query I rowsort
SELECT ALL - - 17 + cor0.col0 FROM tab2 AS cor0
----
24
95
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9684
SELECT CAST( NULL AS SIGNED ) + col0 * + col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9684
SELECT CAST ( NULL AS INTEGER ) + col0 * + col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - - ( cor0.col2 ) + col0 AS col0 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 col2 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to 455e4df3bf7b0fa681c56e89df1a761f

query I rowsort
SELECT ALL col1 * 76 FROM tab2
----
1292
2356
4484

query I rowsort
SELECT ALL + 32 * 5 AS col0 FROM tab0
----
160
160
160

onlyif mysql # use DIV operator for integer division
query I rowsort label-9690
SELECT DISTINCT 2 DIV - 42 col1 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9690
SELECT DISTINCT 2 / - 42 col1 FROM tab1
----
0

query I rowsort
SELECT - 96 * col0 + col2 * - col1 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-12769
-246372
-687586

query I rowsort
SELECT DISTINCT - - 72 * + col1 + + col2 FROM tab0 AS cor0
----
6225
6634
6985

query I rowsort
SELECT col1 + - col2 * 31 * col1 AS col1 FROM tab1 AS cor0
----
-17660
-38675
-43498

query I rowsort
SELECT + 92 + col1 * ( col2 ) FROM tab2 cor0
----
1626
738
929

query I rowsort
SELECT + + col2 * col0 + - ( - 67 ) FROM tab1 AS cor0
----
229
3715
7747

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9696
SELECT - col1 * col2 * CAST( + ( col2 ) AS SIGNED ) FROM tab2 AS cor0
----
-22599
-24548
-39884

skipif mysql # not compatible
query I rowsort label-9696
SELECT - col1 * col2 * CAST ( + ( col2 ) AS INTEGER ) FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT col2 * col1 + - cor0.col1 + col0 AS col1 FROM tab1 AS cor0
----
1315
1381
624

query I rowsort
SELECT ( - col0 * col1 + - col2 ) FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT ALL 30 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT DISTINCT 97 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9701
SELECT col1 + 7 DIV cor0.col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9701
SELECT col1 + 7 / cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + col2 + + 79 * - 85 AS col1 FROM tab2
----
-6677
-6688
-6689

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 15 col0 FROM tab2, tab0 cor0, tab1 cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT DISTINCT col1 + col2 + - 90 FROM tab0
----
29
8
83

query I rowsort
SELECT DISTINCT col1 + - col0 * ( col0 ) FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT + col1 + 14 AS col1 FROM tab2 AS cor0
----
31
45
73

query I rowsort
SELECT + cor0.col2 * col0 + + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + col0 * cor0.col0 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT - 39 * + col1 AS col2 FROM tab1 AS cor0
----
-1014
-390
-507

query I rowsort
SELECT + 89 * + col1 FROM tab0 AS cor0
----
7654
8099
8633

query I rowsort
SELECT + - 42 + 11 FROM tab1 AS cor0
----
-31
-31
-31

query I rowsort
SELECT - 89 * col1 + col0 AS col2 FROM tab0 AS cor0
----
-7630
-8010
-8598

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * 11 col2 FROM tab2 AS cor0
----
-286
-297
-418

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9714
SELECT tab2.col1 * + ( col2 * - col0 ) + CAST( + ( - col1 ) + CAST( - 61 AS SIGNED ) AS SIGNED ) FROM tab2
----
-119772
-51112
-5951

skipif mysql # not compatible
query I rowsort label-9714
SELECT tab2.col1 * + ( col2 * - col0 ) + CAST ( + ( - col1 ) + CAST ( - 61 AS INTEGER ) AS INTEGER ) FROM tab2
----
-119772
-51112
-5951

query I rowsort
SELECT col2 + 85 AS col1 FROM tab2 AS cor0
----
111
112
123

query I rowsort
SELECT cor0.col1 + col1 + + col0 * - col0 AS col2 FROM tab1 AS cor0
----
-4076
-6374
43

query I rowsort
SELECT DISTINCT + col0 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL + col0 + - ( - col2 ) AS col0 FROM tab0 cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * ( + col0 ) * col0 + 81 col1 FROM tab2 AS cor0
----
424
474633
493120

query I rowsort
SELECT ALL - + ( 18 ) FROM tab2 AS cor0
----
-18
-18
-18

onlyif mysql # use DIV operator for integer division
query I rowsort label-9721
SELECT - 8 DIV cor0.col2 AS col1 FROM tab0 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-9721
SELECT - 8 / cor0.col2 AS col1 FROM tab0 AS cor0
----
-8
0
0

query I rowsort
SELECT DISTINCT - cor0.col2 + - 21 * - col2 AS col1 FROM tab0 cor0
----
1640
20
660

query I rowsort
SELECT ALL - col1 * - cor0.col2 - col0 FROM tab0 AS cor0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + 38 col1 FROM tab1 AS cor0
----
102
118
41

query I rowsort
SELECT DISTINCT - + 61 * - col0 FROM tab0 AS cor0
----
1464
2135
5429

query I rowsort
SELECT - - ( - col1 ) * + col1 AS col1 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + ( ( - col2 ) ) * col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col1 + cor0.col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-9729
SELECT 33 + + col0 DIV col1 AS col2 FROM tab0 AS cor0
----
33
33
33

skipif mysql # not compatible
query I rowsort label-9729
SELECT 33 + + col0 / col1 AS col2 FROM tab0 AS cor0
----
33
33
33

query I rowsort
SELECT DISTINCT + 84 + col1 * col0 FROM tab2 AS cor0
----
1427
301
4686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9731
SELECT - CAST( NULL AS SIGNED ) * ( - col2 * - CAST( + 79 AS SIGNED ) ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9731
SELECT - CAST ( NULL AS INTEGER ) * ( - col2 * - CAST ( + 79 AS INTEGER ) ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) * + col2 * - col0 AS col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT - 31 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

query I rowsort
SELECT + col0 - 61 FROM tab2
----
-54
17
18

query I rowsort
SELECT ALL 41 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT DISTINCT col2 * col2 * col2 + col0 FROM tab1
----
157467
185257
884816

query I rowsort
SELECT ALL + 59 * - col1 + + col2 * col0 AS col2 FROM tab1 AS cor0
----
-1372
3058
6913

query I rowsort
SELECT - + col0 * col1 - + 39 AS col1 FROM tab1 AS cor0
----
-1079
-117
-679

query I rowsort
SELECT ALL ( + col2 ) + - ( col0 ) AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + col0 * + col1 - 81 * 64 FROM tab2 AS cor0
----
-3841
-4967
-582

query I rowsort
SELECT ALL + cor0.col1 + + col2 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + - col2 + col1 + col2 AS col2 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9743
SELECT + col2 DIV col2 - col2 AS col1 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-9743
SELECT + col2 / col2 - col2 AS col1 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT + + 92 + - col1 AS col1 FROM tab0 AS cor0
----
-5
1
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9745
SELECT ( + 18 ) DIV + col0 AS col1 FROM tab1
----
0
0
6

skipif mysql # not compatible
query I rowsort label-9745
SELECT ( + 18 ) / + col0 AS col1 FROM tab1
----
0
0
6

query I rowsort
SELECT - 16 + col2 + - 15 AS col1 FROM tab0 AS cor0
----
-30
2
51

query I rowsort
SELECT DISTINCT + col0 * + col2 + 94 FROM tab0 AS cor0
----
129
7392
886

query I rowsort
SELECT - + 35 * + cor0.col0 + col0 * + col2 AS col0 FROM tab2 cor0
----
-56
-702
237

query I rowsort
SELECT - 27 * col2 AS col0 FROM tab1
----
-1458
-1539
-2592

query I rowsort
SELECT tab0.col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9751
SELECT ALL + col1 - - CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-9751
SELECT ALL + col1 - - CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col2 + + 9 FROM tab2 AS cor0
----
35
36
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9753
SELECT ALL + - col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9753
SELECT ALL + - col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9754
SELECT ALL col1 / CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9754
SELECT ALL col1 / CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * col2 + - col1 - + col2 FROM tab0 cor0
----
-63
673
7125

query I rowsort
SELECT 19 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT DISTINCT 53 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
53

query I rowsort
SELECT + col1 * col2 * tab0.col0 AS col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT 47 AS col1 FROM tab1, tab1 AS cor0
----
47

query I rowsort
SELECT ALL 49 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

onlyif mysql # use DIV operator for integer division
query I rowsort label-9761
SELECT 35 DIV 60 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-9761
SELECT 35 / 60 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-9762
SELECT col1 DIV - col1 - 17 * col2 FROM tab1 AS cor0
----
-1633
-919
-970

skipif mysql # not compatible
query I rowsort label-9762
SELECT col1 / - col1 - 17 * col2 FROM tab1 AS cor0
----
-1633
-919
-970

query I rowsort
SELECT ALL + col2 * - col1 + - ( col2 ) AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT + col1 + col2 * 93 FROM tab2 AS cor0
----
2477
2542
3551

query I rowsort
SELECT DISTINCT + col1 * + col2 + + ( col0 * - col0 ) + 14 FROM tab1 AS cor0
----
-3512
-5138
1409

query I rowsort
SELECT + - col0 * + 78 + + cor0.col2 FROM tab1 AS cor0
----
-180
-4935
-6144

onlyif mysql # use DIV operator for integer division
query I rowsort label-9767
SELECT DISTINCT - col2 + 47 DIV + col1 col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9767
SELECT DISTINCT - col2 + 47 / + col1 col2 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9768
SELECT DISTINCT col2 - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9768
SELECT DISTINCT col2 - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 * col1 col0 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-9770
SELECT DISTINCT - + col0 DIV - col2 AS col1 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-9770
SELECT DISTINCT - + col0 / - col2 AS col1 FROM tab0 AS cor0
----
0
1
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-9771
SELECT ALL + cor0.col1 DIV + ( - col0 ) + col0 col2 FROM tab1 cor0
----
-5
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9771
SELECT ALL + cor0.col1 / + ( - col0 ) + col0 col2 FROM tab1 cor0
----
-5
64
80

query I rowsort
SELECT DISTINCT + col0 + 68 AS col0 FROM tab1 AS cor0
----
132
148
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + 80 ) col2 FROM tab0 AS cor0
----
-80
-80
-80

query I rowsort
SELECT DISTINCT + + col2 + 17 * col1 AS col1 FROM tab0 AS cor0
----
1495
1629
1650

query I rowsort
SELECT ( - cor0.col2 ) * - col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + col0 * + ( cor0.col0 + + col0 ) FROM tab2 AS cor0
----
12168
12482
98

query I rowsort
SELECT cor1.col0 AS col2 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT + 34 * 66 AS col0 FROM tab1, tab0 cor0 CROSS JOIN tab2
----
27 values hashing to e708dd5c8a6c048c9b50247212bacf15

query I rowsort
SELECT ALL + - col2 + - col2 * 76 AS col2 FROM tab0 AS cor0
----
-2541
-6314
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( cor0.col2 ) * + col0 col1 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 - - 23 * - col1 FROM tab1 AS cor0
----
-520
410
741

query I rowsort
SELECT ALL + 88 + + col2 * col2 FROM tab0 AS cor0
----
1177
6812
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9783
SELECT + col1 DIV ( col1 * + cor0.col1 ) + ( 98 + + col2 ) AS col1 FROM tab0 AS cor0
----
131
180
99

skipif mysql # not compatible
query I rowsort label-9783
SELECT + col1 / ( col1 * + cor0.col1 ) + ( 98 + + col2 ) AS col1 FROM tab0 AS cor0
----
131
180
99

query I rowsort
SELECT + col2 * - ( col0 * + col2 ) AS col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT DISTINCT + cor0.col1 * - cor0.col2 AS col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - - 28 + col0 FROM tab2 AS cor0
----
106
107
35

query I rowsort
SELECT ALL - ( - col0 ) + cor0.col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + 92 * - col1 AS col0 FROM tab1 AS cor0
----
-1196
-2392
-920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col1 col0 FROM tab0, tab1, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + col2 + + col2 + - col0 * + ( - col0 ) FROM tab1
----
117
4210
6592

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9791
SELECT + col0 * - col2 + + CAST( + 46 * col1 AS SIGNED ) + + col0 AS col0 FROM tab2 AS cor0
----
-2141
1244
764

skipif mysql # not compatible
query I rowsort label-9791
SELECT + col0 * - col2 + + CAST ( + 46 * col1 AS INTEGER ) + + col0 AS col0 FROM tab2 AS cor0
----
-2141
1244
764

query I rowsort
SELECT col1 * col1 * - ( - col0 * col0 + col0 ) AS col1 FROM tab1 AS cor0
----
1068080
403200
4056

onlyif mysql # use DIV operator for integer division
query I rowsort label-9793
SELECT - + col0 DIV col1 + - col2 FROM tab2 AS cor0
----
-27
-27
-42

skipif mysql # not compatible
query I rowsort label-9793
SELECT - + col0 / col1 + - col2 FROM tab2 AS cor0
----
-27
-27
-42

query I rowsort
SELECT 19 * cor0.col2 AS col0 FROM tab1 AS cor0
----
1026
1083
1824

query I rowsort
SELECT ALL + 75 * col0 * 88 AS col0 FROM tab2 AS cor0
----
46200
514800
521400

query I rowsort
SELECT ALL - - 48 AS col0 FROM tab2 AS cor0
----
48
48
48

query I rowsort
SELECT DISTINCT + 52 AS col2 FROM tab1, tab0 AS cor0
----
52

query I rowsort
SELECT + + col2 + 30 AS col0 FROM tab0 AS cor0
----
112
31
63

query I rowsort
SELECT - - cor0.col1 AS col2 FROM tab2 cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9800
SELECT col2 * 64 + - cor0.col2 / - col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9800
SELECT col2 * 64 + - cor0.col2 / - col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * ( + col2 ) col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL + col2 + col0 + tab2.col0 AS col1 FROM tab2
----
182
196
41

query I rowsort
SELECT + col0 + - col2 * col0 AS col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT - col2 + - 46 AS col2 FROM tab2 cor0
----
-72
-73
-84

query I rowsort
SELECT - cor0.col2 * - col0 + + 82 * col2 AS col0 FROM tab0 cor0
----
117
14022
3498

query I rowsort
SELECT ALL 41 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

onlyif mysql # use DIV operator for integer division
query I rowsort label-9807
SELECT tab2.col1 * col0 + ( + tab2.col1 ) DIV tab2.col1 FROM tab2
----
1344
218
4603

skipif mysql # not compatible
query I rowsort label-9807
SELECT tab2.col1 * col0 + ( + tab2.col1 ) / tab2.col1 FROM tab2
----
1344
218
4603

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9808
SELECT DISTINCT + + CAST( NULL AS SIGNED ) * ( + col1 ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9808
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) * ( + col1 ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT 41 AS col0 FROM tab2 cor0
----
41
41
41

query I rowsort
SELECT DISTINCT + 80 * col1 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT ALL - + 77 * col1 + col0 FROM tab2 AS cor0
----
-1230
-2380
-4465

query I rowsort
SELECT ALL + + col2 + - 1 AS col1 FROM tab2 AS cor0
----
25
26
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9813
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9813
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + tab2.col0 * 4 AS col1 FROM tab2
----
28
312
316

onlyif mysql # use DIV operator for integer division
query I rowsort label-9815
SELECT DISTINCT col2 DIV ( - tab0.col1 + col2 ) AS col0 FROM tab0
----
-9
0

skipif mysql # not compatible
query I rowsort label-9815
SELECT DISTINCT col2 / ( - tab0.col1 + col2 ) AS col0 FROM tab0
----
-9
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 col0 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * + ( + col0 ) * + col2 col2 FROM tab1
----
207936
737280
8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( - tab2.col2 ) col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + - 35 * + col1 * ( 60 ) AS col1 FROM tab0 AS cor0
----
-180600
-191100
-203700

query I rowsort
SELECT + 10 AS col1 FROM tab0
----
10
10
10

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9821
SELECT - CAST( - col1 AS SIGNED ) FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9821
SELECT - CAST ( - col1 AS INTEGER ) FROM tab0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 52 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 9500afe5646d620d5e8943351a29d082

query I rowsort
SELECT DISTINCT 45 FROM tab2, tab2 AS cor0
----
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-9824
SELECT ALL + col0 DIV + tab0.col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9824
SELECT ALL + col0 / + tab0.col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + 7 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT 95 * - col1 * + col0 FROM tab0
----
-196080
-322525
-769405

query I rowsort
SELECT + col1 * cor0.col2 * col1 + + 3 FROM tab0 AS cor0
----
244071
679045
9412

query I rowsort
SELECT + col0 * col2 * + col2 - - col2 FROM tab1 AS cor0
----
207993
737376
8802

query I rowsort
SELECT ALL - + col1 + + cor0.col0 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-9830
SELECT + - col0 DIV col1 + - col2 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-9830
SELECT + - col0 / col1 + - col2 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9831
SELECT ALL ( + 76 ) DIV col2 + - col1 + col2 FROM tab1
----
29
48
83

skipif mysql # not compatible
query I rowsort label-9831
SELECT ALL ( + 76 ) / col2 + - col1 + col2 FROM tab1
----
29
48
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 13 col1 FROM tab1
----
-13
-13
-13

query I rowsort
SELECT DISTINCT + 4 * col2 - col2 FROM tab2
----
114
78
81

query I rowsort
SELECT DISTINCT + col0 - col0 * col1 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT - ( + ( - col1 ) ) AS col1 FROM tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9836
SELECT col1 DIV + 50 + col0 col0 FROM tab2
----
7
79
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9836
SELECT col1 / + 50 + col0 col0 FROM tab2
----
7
79
79

query I rowsort
SELECT + + ( ( + cor0.col2 ) ) * + ( col1 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + col2 + col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT ALL - 49 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT ALL ( col2 ) + cor0.col0 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + ( col1 ) + - col2 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + col0 * - col0 - + col2 FROM tab2 AS cor0
----
-6110
-6279
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col0 ) + - ( + col1 ) * - col2 col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-9844
SELECT DISTINCT + + col0 + col2 DIV cor0.col1 FROM tab2 AS cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-9844
SELECT DISTINCT + + col0 + col2 / cor0.col1 FROM tab2 AS cor0
----
7
78
81

query I rowsort
SELECT 23 AS col1 FROM tab2
----
23
23
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-9846
SELECT DISTINCT + ( + col2 ) DIV + ( + col1 ) - col2 DIV - col2 AS col2 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-9846
SELECT DISTINCT + ( + col2 ) / + ( + col1 ) - col2 / - col2 AS col2 FROM tab0 AS cor0
----
1

query I rowsort
SELECT 31 * + cor0.col2 * col1 AS col0 FROM tab1 AS cor0
----
17670
38688
43524

query I rowsort
SELECT ALL 41 * - col1 AS col2 FROM tab0 AS cor0
----
-3526
-3731
-3977

query I rowsort
SELECT DISTINCT - + 81 * - col2 AS col1 FROM tab0 AS cor0
----
2673
6642
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-9850
SELECT + - col1 + - 52 DIV col1 col0 FROM tab1 AS cor0
----
-15
-17
-28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9850
SELECT + - col1 + - 52 / col1 col0 FROM tab1 AS cor0
----
-15
-17
-28

query I rowsort
SELECT ALL + - col1 + - col1 * + col1 + col2 AS col1 FROM tab2 AS cor0
----
-268
-3514
-965

query I rowsort
SELECT DISTINCT + col1 + + col0 AS col2 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL col2 + 35 AS col1 FROM tab1 AS cor0
----
131
89
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + cor0.col1 * col1 col0 FROM tab2 cor0
----
327
3507
988

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9855
SELECT + - col0 * CAST( NULL AS DECIMAL ) * - cor0.col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9855
SELECT + - col0 * CAST ( NULL AS REAL ) * - cor0.col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9856
SELECT ALL - col2 DIV - 65 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9856
SELECT ALL - col2 / - 65 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 63 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT 8 * 82 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 5cdbc1743cae77aa83a5d5701433ca71

query I rowsort
SELECT ALL - 7 * - col2 + + col2 AS col0 FROM tab2 AS cor0
----
208
216
304

query I rowsort
SELECT + 77 * 98 AS col0 FROM tab1 AS cor0
----
7546
7546
7546

query I rowsort
SELECT ALL ( - col1 ) * col2 * - col0 FROM tab0 cor0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 * col1 col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT + col2 * + ( 62 ) FROM tab0
----
2046
5084
62

query I rowsort
SELECT ALL + 49 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT - cor0.col1 * + col1 + col1 AS col0 FROM tab2 AS cor0
----
-272
-3422
-930

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9866
SELECT DISTINCT - CAST( 11 AS SIGNED ) + + col2 FROM tab1 AS cor0
----
43
46
85

skipif mysql # not compatible
query I rowsort label-9866
SELECT DISTINCT - CAST ( 11 AS INTEGER ) + + col2 FROM tab1 AS cor0
----
43
46
85

query I rowsort
SELECT DISTINCT col2 - + col1 AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL col1 * - cor0.col2 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - 83 AS col2 FROM tab1 AS cor0
----
-83
-83
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9870
SELECT DISTINCT - col0 DIV + cor0.col0 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9870
SELECT DISTINCT - col0 / + cor0.col0 FROM tab1 cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9871
SELECT - cor0.col2 DIV col1 FROM tab1 cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-9871
SELECT - cor0.col2 / col1 FROM tab1 cor0
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9872
SELECT ALL - + col0 + - col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-9872
SELECT ALL - + col0 + - col1 / - col1 AS col0 FROM tab2 AS cor0
----
-6
-77
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9873
SELECT CAST( - ( + col2 ) AS SIGNED ) FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-9873
SELECT CAST ( - ( + col2 ) AS INTEGER ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - 50 + col2 AS col1 FROM tab2 AS cor0
----
-12
-23
-24

query I rowsort
SELECT ALL + + ( + 36 ) AS col0 FROM tab1 AS cor0
----
36
36
36

query I rowsort
SELECT ALL 53 * - col0 + - col2 * - col0 AS col2 FROM tab1 AS cor0
----
256
3
3440

query I rowsort
SELECT DISTINCT - col2 * - 7 FROM tab1 AS cor0
----
378
399
672

query I rowsort
SELECT + 44 + col2 AS col2 FROM tab1 AS cor0
----
101
140
98

query I rowsort
SELECT ALL + 77 * 3 + - col0 * 74 AS col2 FROM tab2 AS cor0
----
-287
-5541
-5615

query I rowsort
SELECT DISTINCT + - 19 + + col1 FROM tab0 AS cor0
----
67
72
78

query I rowsort
SELECT DISTINCT - col1 * - col0 + col1 * 61 * - col2 FROM tab1 AS cor0
----
-34130
-75088
-85566

query I rowsort
SELECT ALL + 60 AS col0 FROM tab1 cor0
----
60
60
60

query I rowsort
SELECT + 80 * - 94 AS col1 FROM tab1 AS cor0
----
-7520
-7520
-7520

query I rowsort
SELECT DISTINCT - - ( col0 ) + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - + cor0.col2 + col1 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT col2 + 70 AS col2 FROM tab0 AS cor0
----
103
152
71

query I rowsort
SELECT DISTINCT + 48 * col1 FROM tab1 AS cor0
----
1248
480
624

query I rowsort
SELECT + 59 + + col2 * - col1 + + ( - tab1.col1 ) * - col1 FROM tab1
----
-1020
-411
-669

query I rowsort
SELECT DISTINCT - 58 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-58

query I rowsort
SELECT DISTINCT 7 + col1 FROM tab2
----
24
38
66

query I rowsort
SELECT DISTINCT + 85 AS col2 FROM tab2, tab0 AS cor0
----
85

query I rowsort
SELECT ( 8 * - cor0.col2 ) FROM tab1, tab1 AS cor0
----
9 values hashing to d9b44f7f2a2467e9e6012706de9d198c

skipif mysql # not compatible
query I rowsort
SELECT - cor0.col0 * CAST ( col0 AS REAL ) FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-9894
SELECT DISTINCT + - cor0.col1 * 47 DIV + col1 AS col1 FROM tab1 AS cor0
----
-47

skipif mysql # not compatible
query I rowsort label-9894
SELECT DISTINCT + - cor0.col1 * 47 / + col1 AS col1 FROM tab1 AS cor0
----
-47

query I rowsort
SELECT tab2.col0 - col2 * - ( - 89 * + col2 ) AS col0 FROM tab2
----
-128437
-60086
-64874

query I rowsort
SELECT + 92 + - tab1.col1 * + col1 * col1 FROM tab1
----
-17484
-2105
-908

query I rowsort
SELECT tab0.col0 + - col1 * ( col1 * 22 ) FROM tab0
----
-162688
-182093
-206963

query I rowsort
SELECT col2 * + 0 + - col0 AS col2 FROM tab2
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9899
SELECT col2 + - CAST( + 17 AS SIGNED ) FROM tab1
----
37
40
79

skipif mysql # not compatible
query I rowsort label-9899
SELECT col2 + - CAST ( + 17 AS INTEGER ) FROM tab1
----
37
40
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-9900
SELECT col0 DIV - ( - 96 * col0 ) + 32 * - col2 FROM tab1
----
-1728
-1824
-3072

skipif mysql # not compatible
query I rowsort label-9900
SELECT col0 / - ( - 96 * col0 ) + 32 * - col2 FROM tab1
----
-1728
-1824
-3072

query I rowsort
SELECT - col1 + 69 * - col1 FROM tab0
----
-6020
-6370
-6790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * 42 col1 FROM tab1
----
-126
-2688
-3360

query I rowsort
SELECT DISTINCT col2 * ( - col1 ) * + col0 + ( cor0.col2 ) FROM tab2 AS cor0
----
-119626
-50996
-5832

query I rowsort
SELECT ALL - col2 * + ( + col0 ) - + cor0.col1 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL + col1 + - col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col0 + col1 * + col0 - col0 FROM tab0 AS cor0
----
2016
3325
7921

query I rowsort
SELECT ALL + col2 + + ( + ( + col2 ) ) * col0 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT - col1 + + ( - col0 ) FROM tab2 AS cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - col1 col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + - col2 * - ( + col1 ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + 91 col0 FROM tab1 AS cor0
----
-5
34
37

query I rowsort
SELECT ALL + col0 * col2 + - tab2.col2 + - col2 FROM tab2
----
135
1976
2926

query I rowsort
SELECT - ( - tab2.col1 ) * + ( col2 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 * + cor0.col1 + + 77 FROM tab0 AS cor0
----
174
2915
7539

query I rowsort
SELECT + col0 * col2 + ( + cor0.col2 ) FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT - 42 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-42

query I rowsort
SELECT DISTINCT 15 FROM tab0, tab0 AS cor0, tab1, tab0 cor1
----
15

query I rowsort
SELECT ( + col0 ) + ( 81 + + col1 * + col1 ) FROM tab0 AS cor0
----
7501
8451
9525

query I rowsort
SELECT DISTINCT - 68 FROM tab1, tab0 AS cor0
----
-68

query I rowsort
SELECT - 87 * tab0.col2 AS col1 FROM tab0
----
-2871
-7134
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-9921
SELECT - ( - col2 ) DIV ( + col0 ) - col2 * - cor0.col0 * 74 AS col2 FROM tab1 cor0
----
12006
269952
568321

skipif mysql # not compatible
query I rowsort label-9921
SELECT - ( - col2 ) / ( + col0 ) - col2 * - cor0.col0 * 74 AS col2 FROM tab1 cor0
----
12006
269952
568321

query I rowsort
SELECT 20 + col1 AS col0 FROM tab2 AS cor0
----
37
51
79

query I rowsort
SELECT + - 13 * col0 FROM tab0 AS cor0
----
-1157
-312
-455

query I rowsort
SELECT + - col0 * ( + 77 ) FROM tab1 AS cor0
----
-231
-4928
-6160

query I rowsort
SELECT + col0 + 61 * - 23 AS col2 FROM tab1 AS cor0
----
-1323
-1339
-1400

query I rowsort
SELECT - col1 + + col0 + - tab2.col2 AS col0 FROM tab2
----
-51
-7
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-9927
SELECT + 47 DIV + 66 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-9927
SELECT + 47 / + 66 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT col2 * col0 + ( + col2 ) AS col0 FROM tab1
----
216
3705
7776

query I rowsort
SELECT DISTINCT - col0 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL col2 + cor0.col0 AS col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - cor0.col2 * 36 FROM tab1 AS cor0
----
-1944
-2052
-3456

query I rowsort
SELECT ALL 37 FROM tab0, tab1 cor0, tab2 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to 1835c9740560ff03895a32b149517568

query I rowsort
SELECT ALL col2 * + col0 + - col0 AS col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT + ( - col0 ) * col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT 70 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT - ( col1 ) + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - cor0.col2 * 86 FROM tab2 cor0
----
-2236
-2322
-3268

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
26
27
38

query I rowsort
SELECT DISTINCT - 79 + col0 * col2 AS col0 FROM tab0 AS cor0
----
-44
713
7219

query I rowsort
SELECT ALL - 81 * col0 FROM tab1 AS cor0
----
-243
-5184
-6480

query I rowsort
SELECT - - 31 * col2 AS col2 FROM tab0 AS cor0
----
1023
2542
31

query I rowsort
SELECT + - col0 * - cor0.col1 * 19 FROM tab1 AS cor0
----
12160
1482
19760

query I rowsort
SELECT - col1 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + - 70 * + col1 AS col2 FROM tab1 AS cor0
----
-1820
-700
-910

query I rowsort
SELECT ALL - 23 * col2 FROM tab0 AS cor0
----
-1886
-23
-759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9946
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9946
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col2 - col0 * + col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab1 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to f464d40c605db608927f2c4d66190a23

query I rowsort
SELECT DISTINCT + - 18 FROM tab0 AS cor0
----
-18

query I rowsort
SELECT ALL - - col1 + - col2 FROM tab2 cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 21 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT DISTINCT - 46 + tab1.col0 FROM tab1
----
-43
18
34

query I rowsort
SELECT ALL - + col1 + + ( + col2 ) FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL col2 + - col1 * - col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT DISTINCT - col0 * col2 + col0 * col0 AS col0 FROM tab2 AS cor0
----
-140
3239
4056

query I rowsort
SELECT ALL - - cor0.col1 + 3 FROM tab2 AS cor0
----
20
34
62

query I rowsort
SELECT + - col0 * + col0 - + col0 * 45 FROM tab0 AS cor0
----
-11926
-1656
-2800

query I rowsort
SELECT DISTINCT + 43 FROM tab1, tab0, tab0 AS cor0
----
43

query I rowsort
SELECT DISTINCT - 21 AS col0 FROM tab2
----
-21

query I rowsort
SELECT ALL col2 + ( - col1 ) FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL - col2 * ( col0 ) * col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-9962
SELECT DISTINCT - col2 DIV 53 + - col0 * col1 * - ( col2 ) AS col0 FROM tab2 AS cor0
----
119652
51034
5859

skipif mysql # not compatible
query I rowsort label-9962
SELECT DISTINCT - col2 / 53 + - col0 * col1 * - ( col2 ) AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + cor0.col2 - cor0.col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * cor0.col2 col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col2 + ( + 0 ) AS col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - col1 * 4 + + 16 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-1588
-952
-968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9967
SELECT DISTINCT + cor0.col1 * + CAST( NULL AS SIGNED ) + col2 * col1 / + col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9967
SELECT DISTINCT + cor0.col1 * + CAST ( NULL AS INTEGER ) + col2 * col1 / + col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + cor0.col1 * ( - col0 ) * col1 + - ( col2 ) AS col1 FROM tab2 AS cor0
----
-22869
-271544
-6754

query I rowsort
SELECT DISTINCT + + col2 + - 6 + - col2 AS col0 FROM tab1 AS cor0
----
-6

query I rowsort
SELECT - col1 + 42 AS col1 FROM tab2 cor0
----
-17
11
25

query I rowsort
SELECT ALL + col0 + 1 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT DISTINCT 64 AS col0 FROM tab2, tab2 cor0
----
64

query I rowsort
SELECT DISTINCT col1 * ( + col1 ) FROM tab2
----
289
3481
961

query I rowsort
SELECT - col0 + + 12 AS col2 FROM tab1
----
-52
-68
9

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 * CAST ( + col0 AS REAL ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - + col1 + - ( - col1 * - cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 41 * + col0 col1 FROM tab2 cor0
----
287
3198
3239

query I rowsort
SELECT DISTINCT + 25 * ( - col0 ) * - col0 AS col2 FROM tab1 AS cor0
----
102400
160000
225

query I rowsort
SELECT DISTINCT - cor0.col0 + col2 * + cor0.col2 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT + ( + col2 ) * col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - 10 * 95 FROM tab0 AS cor0
----
-950
-950
-950

query I rowsort
SELECT col1 * ( col0 + cor0.col1 ) FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT - + 9 FROM tab2 AS cor0
----
-9
-9
-9

query I rowsort
SELECT 48 FROM tab2 cor0
----
48
48
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9985
SELECT - + CAST( NULL AS SIGNED ) * 7 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9985
SELECT - + CAST ( NULL AS INTEGER ) * 7 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + + col2 * ( col0 ) * + col0 AS col1 FROM tab2 AS cor0
----
1354
158243
237175

query I rowsort
SELECT ALL - col0 * - cor0.col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col2 * + col2 + 4 FROM tab0 cor0
----
-1085
-6720
3

query I rowsort
SELECT ALL - + 16 * + col2 FROM tab0 AS cor0
----
-1312
-16
-528

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9990
SELECT ALL col1 + - col0 + + CAST( + col0 + col1 AS SIGNED ) * col2 FROM tab0 AS cor0
----
14762
194
3692

skipif mysql # not compatible
query I rowsort label-9990
SELECT ALL col1 + - col0 + + CAST ( + col0 + col1 AS INTEGER ) * col2 FROM tab0 AS cor0
----
14762
194
3692

query I rowsort
SELECT ALL - + 8 FROM tab2 AS cor0
----
-8
-8
-8

query I rowsort
SELECT + 73 + cor0.col0 + - ( col0 ) AS col2 FROM tab1 AS cor0
----
73
73
73

query I rowsort
SELECT + - col1 * + col1 + + col2 + - 3 FROM tab2 AS cor0
----
-254
-3458
-937

query I rowsort
SELECT DISTINCT + col0 * - 56 + + col1 - col0 AS col1 FROM tab0
----
-1282
-1898
-4982

query I rowsort
SELECT DISTINCT 59 - tab0.col1 * - col1 AS col0 FROM tab0
----
7455
8340
9468

query I rowsort
SELECT DISTINCT - 88 + + col0 - tab1.col0 FROM tab1
----
-88

query I rowsort
SELECT ALL - col2 + col0 * + 99 AS col0 FROM tab0 cor0
----
2343
3464
8729

onlyif mysql # use DIV operator for integer division
query I rowsort label-9998
SELECT DISTINCT ( - col0 ) DIV 11 col0 FROM tab2 AS cor0
----
-7
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9998
SELECT DISTINCT ( - col0 ) / 11 col0 FROM tab2 AS cor0
----
-7
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9999
SELECT 9 * + col2 + - col2 DIV - col1 + col1 FROM tab0 AS cor0
----
106
383
829

skipif mysql # not compatible
query I rowsort label-9999
SELECT 9 * + col2 + - col2 / - col1 + col1 FROM tab0 AS cor0
----
106
383
829

