sqllogictest
Artifact Content
Not logged in

Artifact fbbd6a8089fd0ba11c8edef48a1a3d5f889b19ea:


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 cor0.col1 + 50 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 8c61c5c3a1ab93eeeead10e113cfcabe

onlyif mysql # use DIV operator for integer division
query I rowsort label-1
SELECT + CAST( col0 AS SIGNED ) DIV - col2 + ( - col1 ) - + col1 AS col0 FROM tab1 AS cor0
----
-21
-26
-52

skipif mysql # not compatible
query I rowsort label-1
SELECT + CAST ( col0 AS INTEGER ) / - col2 + ( - col1 ) - + col1 AS col0 FROM tab1 AS cor0
----
-21
-26
-52

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

query I rowsort
SELECT + 72 * + tab1.col1 FROM tab1
----
1872
720
936

query I rowsort
SELECT + + 89 * + col1 + col1 - 78 * col2 FROM tab1 AS cor0
----
-1872
-3546
-6318

query I rowsort
SELECT DISTINCT + ( ( - col0 ) ) + 38 * 37 * col1 FROM tab0
----
120892
127857
136347

query I rowsort
SELECT - 65 + col2 FROM tab0 AS cor0
----
-32
-64
17

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

query I rowsort
SELECT DISTINCT 50 + - col2 FROM tab2 AS cor0
----
12
23
24

query I rowsort
SELECT ALL 53 * - col2 * 93 AS col2 FROM tab0 AS cor0
----
-162657
-404178
-4929

query I rowsort
SELECT 34 * - col2 FROM tab2 cor0
----
-1292
-884
-918

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-12
SELECT - col1 * + col2 + - col1 DIV 80 AS col2 FROM tab0 AS cor0
----
-2839
-7463
-98

skipif mysql # not compatible
query I rowsort label-12
SELECT - col1 * + col2 + - col1 / 80 AS col2 FROM tab0 AS cor0
----
-2839
-7463
-98

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

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

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

query I rowsort
SELECT + col0 * + col2 * + col2 + + col2 * col2 + col0 * + 91 AS col0 FROM tab2 AS cor0
----
122709
60502
6469

query I rowsort
SELECT ALL - - 91 AS col1 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT - 77 + col2 FROM tab1 AS cor0
----
-20
-23
19

query I rowsort
SELECT ( + col1 + + col1 ) * - tab1.col2 AS col2 FROM tab1
----
-1140
-2496
-2808

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * + col1 * - col1 col1 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT DISTINCT + + col1 + col0 * + 3 FROM tab2 AS cor0
----
254
293
52

query I rowsort
SELECT DISTINCT - + 90 * col0 FROM tab1 AS cor0
----
-270
-5760
-7200

query I rowsort
SELECT - col0 * - col1 + - 77 AS col1 FROM tab1 AS cor0
----
1
563
963

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

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

query I rowsort
SELECT - 26 * col2 + col2 FROM tab0 AS cor0
----
-2050
-25
-825

query I rowsort
SELECT ALL - cor0.col0 * - 39 AS col0 FROM tab1 cor0
----
117
2496
3120

query I rowsort
SELECT ALL cor0.col0 + 91 AS col1 FROM tab0 AS cor0
----
115
126
180

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

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

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

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

query I rowsort
SELECT - - col2 * + 29 + col2 FROM tab2 cor0
----
1140
780
810

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

skipif mysql # not compatible
query I rowsort label-33
SELECT ALL + col0 / col2 FROM tab0
----
0
1
35

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

query I rowsort
SELECT ALL 84 * - col2 AS col0 FROM tab1
----
-4536
-4788
-8064

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

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col0 + - col1 AS REAL ) FROM tab2
----
-24
19
62

query I rowsort
SELECT 15 * col0 * col1 AS col1 FROM tab0
----
121485
30960
50925

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-41
SELECT - col1 - CAST( - 53 AS SIGNED ) FROM tab2 AS cor0
----
-6
22
36

skipif mysql # not compatible
query I rowsort label-41
SELECT - col1 - CAST ( - 53 AS INTEGER ) FROM tab2 AS cor0
----
-6
22
36

query I rowsort
SELECT ( + col0 ) * - tab2.col2 + 75 * tab2.col1 - ( + col2 ) * + tab2.col0 FROM tab2
----
-4729
1947
369

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

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

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

skipif mysql # not compatible
query I rowsort label-45
SELECT ALL - + cor0.col0 + CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
2
62
62

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + tab2.col0 * 54 col2 FROM tab2
----
385
4290
4345

query I rowsort
SELECT DISTINCT + col2 + col1 * ( col2 * col0 ) FROM tab0
----
3396
664200
68145

query I rowsort
SELECT ALL + 3 * tab0.col1 * - ( - col2 ) - + col2 AS col2 FROM tab0
----
22304
290
8481

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

query I rowsort
SELECT DISTINCT - col0 + + ( - 28 ) AS col1 FROM tab2 AS cor0
----
-106
-107
-35

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

skipif mysql # not compatible
query I rowsort label-53
SELECT DISTINCT + col0 * CAST ( + col0 AS INTEGER ) + - col2 AS col2 FROM tab1 AS cor0
----
-45
4039
6304

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

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

query I rowsort
SELECT DISTINCT - col2 * 26 AS col1 FROM tab2 AS cor0
----
-676
-702
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-57
SELECT DISTINCT col2 * 65 DIV + col1 + col1 AS col2 FROM tab1 AS cor0
----
161
380
493

skipif mysql # not compatible
query I rowsort label-57
SELECT DISTINCT col2 * 65 / + col1 + col1 AS col2 FROM tab1 AS cor0
----
161
380
493

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

query I rowsort
SELECT DISTINCT + col1 * col1 + col0 * + col0 + - 38 AS col0 FROM tab0 AS cor0
----
10596
16164
7934

query I rowsort
SELECT ALL - col0 - col0 * + 52 FROM tab0 cor0
----
-1272
-1855
-4717

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-63
SELECT col0 * 66 DIV col0 AS col0 FROM tab2
----
66
66
66

skipif mysql # not compatible
query I rowsort label-63
SELECT col0 * 66 / col0 AS col0 FROM tab2
----
66
66
66

query I rowsort
SELECT + 24 * - col1 FROM tab0 AS cor0
----
-2064
-2184
-2328

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

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

query I rowsort
SELECT + 41 * col0 + col2 * + col2 AS col0 FROM tab2 AS cor0
----
1016
3874
4683

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-68
SELECT - + cor0.col2 DIV col1 + - col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-81

skipif mysql # not compatible
query I rowsort label-68
SELECT - + cor0.col2 / col1 + - col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-81

query I rowsort
SELECT - col0 * - col0 * - 57 FROM tab2
----
-2793
-346788
-355737

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

query I rowsort
SELECT DISTINCT - 72 * + 74 AS col0 FROM tab0, tab1 cor0
----
-5328

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

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

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

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

query I rowsort
SELECT ALL - cor0.col1 * 31 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to aa029d1dc144ac7ad3965e2af4e5a631

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

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

query I rowsort
SELECT - - 59 * cor0.col2 + - col0 AS col2 FROM tab0 AS cor0
----
1923
24
4749

query I rowsort
SELECT ( col1 ) * col2 + - 44 FROM tab1 AS cor0
----
1204
1360
526

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-81
SELECT - 41 DIV col0 + + col2 AS col0 FROM tab2 AS cor0
----
22
26
38

skipif mysql # not compatible
query I rowsort label-81
SELECT - 41 / col0 + + col2 AS col0 FROM tab2 AS cor0
----
22
26
38

query I rowsort
SELECT 35 + col2 AS col2 FROM tab0 AS cor0
----
117
36
68

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

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

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

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

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

query I rowsort
SELECT - 84 * + col0 AS col2 FROM tab0 AS cor0
----
-2016
-2940
-7476

query I rowsort
SELECT - col2 * col1 * 41 FROM tab2 AS cor0
----
-26486
-34317
-62894

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

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

query I rowsort
SELECT 2 FROM tab2, tab1 cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

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

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

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

skipif mysql # not compatible
query I rowsort label-95
SELECT + CAST ( - col0 AS INTEGER ) * - cor0.col1 + col0 + + ( col0 * CAST ( + ( + col0 ) AS INTEGER ) ) FROM tab1 AS cor0
----
4800
7520
90

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

query I rowsort
SELECT - - 92 + cor0.col1 AS col2 FROM tab1 AS cor0
----
102
105
118

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * cor0.col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT + 14 * - col0 AS col2 FROM tab1 AS cor0
----
-1120
-42
-896

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 * - 16 col0 FROM tab1 AS cor0
----
10816
1600
2704

query I rowsort
SELECT ALL col2 * - col2 FROM tab1 cor0
----
-2916
-3249
-9216

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 87 col0 FROM tab0 AS cor0
----
173
178
184

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

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

query I rowsort
SELECT col1 + 30 * cor0.col1 FROM tab1 AS cor0
----
310
403
806

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

query I rowsort
SELECT - ( col1 ) + + col2 * + 57 AS col2 FROM tab2 AS cor0
----
1423
1508
2149

query I rowsort
SELECT DISTINCT - 11 * - 73 AS col1 FROM tab1 cor0
----
803

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

query I rowsort
SELECT - col1 * 34 * - tab0.col1 AS col2 FROM tab0
----
251464
281554
319906

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

skipif mysql # not compatible
query I rowsort
SELECT col1 - CAST ( + col2 AS REAL ) * tab0.col1 * col2 AS col2 FROM tab0
----
-611793
-93568
0

query I rowsort
SELECT + col2 * col2 * col1 FROM tab0
----
611884
93654
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-122
SELECT ALL + + 10 * col0 + col0 * + CAST( - 84 AS SIGNED ) FROM tab2 AS cor0
----
-518
-5772
-5846

skipif mysql # not compatible
query I rowsort label-122
SELECT ALL + + 10 * col0 + col0 * + CAST ( - 84 AS INTEGER ) FROM tab2 AS cor0
----
-518
-5772
-5846

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

query I rowsort
SELECT ALL + 82 * cor0.col0 + + col1 FROM tab0 AS cor0
----
2054
2967
7389

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

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

query I rowsort
SELECT DISTINCT + cor1.col1 * - 97 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0, tab1 AS cor2
----
-1261
-2522
-970

query I rowsort
SELECT ALL - ( - 38 ) + - col0 * col1 FROM tab0 AS cor0
----
-2026
-3357
-8061

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-129
SELECT - + cor0.col1 DIV 56 - + cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to f2158c87ec6ccc80cd477f41498dfcf9

skipif mysql # not compatible
query I rowsort label-129
SELECT - + cor0.col1 / 56 - + cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to f2158c87ec6ccc80cd477f41498dfcf9

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

query I rowsort
SELECT - col0 + 1 FROM tab2
----
-6
-77
-78

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

query I rowsort
SELECT ALL 26 + 77 FROM tab2
----
103
103
103

query I rowsort
SELECT DISTINCT + col2 * 25 + col1 FROM tab2
----
706
709
967

onlyif mysql # use DIV operator for integer division
query I rowsort label-135
SELECT + 57 * col1 + 17 * 16 DIV - col1 AS col0 FROM tab0 cor0
----
4899
5185
5527

skipif mysql # not compatible
query I rowsort label-135
SELECT + 57 * col1 + 17 * 16 / - col1 AS col0 FROM tab0 cor0
----
4899
5185
5527

query I rowsort
SELECT ( tab2.col1 ) - col1 FROM tab2
----
0
0
0

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

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

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

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

query I rowsort
SELECT ALL - col2 + 69 FROM tab0
----
-13
36
68

query I rowsort
SELECT ALL + 90 + + col1 FROM tab2
----
107
121
149

query I rowsort
SELECT ALL 67 + + col0 FROM tab1
----
131
147
70

query I rowsort
SELECT ALL + col2 - - 17 * col0 FROM tab2 cor0
----
1352
1381
146

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

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

query I rowsort
SELECT ALL - col0 - cor0.col0 * col1 AS col2 FROM tab1 AS cor0
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-148
SELECT col0 + + 12 DIV ( col1 ) AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-148
SELECT col0 + + 12 / ( col1 ) AS col1 FROM tab2 AS cor0
----
7
78
79

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-150
SELECT ( col0 ) * - 87 + - col2 DIV - col2 FROM tab0
----
-2087
-3044
-7742

skipif mysql # not compatible
query I rowsort label-150
SELECT ( col0 ) * - 87 + - col2 / - col2 FROM tab0
----
-2087
-3044
-7742

query I rowsort
SELECT + 14 AS col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

query I rowsort
SELECT + 42 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

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

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

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0, tab1, tab1 cor1
----
972 values hashing to d222ba302bd1ddd1c8b2ddf1a4d0b07a

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

skipif mysql # not compatible
query I rowsort label-156
SELECT DISTINCT - cor0.col1 / - 45 FROM tab2 AS cor0
----
0
1

query I rowsort
SELECT + col0 * + 18 FROM tab1 AS cor0
----
1152
1440
54

query I rowsort
SELECT + col2 + cor0.col1 * col2 + - col1 AS col2 FROM tab1 AS cor0
----
1331
1432
617

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

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

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

query I rowsort
SELECT DISTINCT + col0 * 61 + + col1 + - col1 FROM tab1 AS cor0
----
183
3904
4880

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col0 + - 38 FROM tab1 AS cor0
----
-29
4058
6362

query I rowsort
SELECT - cor0.col1 * + 30 + col1 + col2 FROM tab2 AS cor0
----
-1685
-455
-872

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

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

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

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

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

query I rowsort
SELECT - 51 AS col0 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 27bcc31433ce90833ed76619cbd8d6a4

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

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

query I rowsort
SELECT ALL + cor0.col0 + cor0.col0 * 21 * - 74 AS col0 FROM tab0 AS cor0
----
-138217
-37272
-54355

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + cor0.col2 * + 71 col1 FROM tab0 AS cor0
----
168
2429
5913

query I rowsort
SELECT + col2 + ( + col2 ) * col1 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - cor0.col0 + + ( 8 + col0 ) * col1 AS col1 FROM tab0 AS cor0
----
2728
4136
8738

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

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

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

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

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

query I rowsort
SELECT + col1 + - cor0.col1 * 30 AS col1 FROM tab1 AS cor0
----
-290
-377
-754

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

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

query I rowsort
SELECT DISTINCT col2 * + col0 * 5 + + col0 + - col2 AS col0 FROM tab1
----
18247
38384
759

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

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

query I rowsort
SELECT ALL + col0 * ( - col1 ) + 61 FROM tab2 AS cor0
----
-1282
-156
-4541

query I rowsort
SELECT DISTINCT + - 87 * - 45 + - col1 * col2 + cor0.col1 * - col2 AS col0 FROM tab2 AS cor0
----
2241
2623
847

query I rowsort
SELECT DISTINCT - 87 * - ( - col2 ) + col0 * cor0.col0 FROM tab0 cor0
----
-2295
1138
787

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-192
SELECT ALL - + col0 + cor0.col1 * - col0 + + col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
-1422
-221
-4680

skipif mysql # not compatible
query I rowsort label-192
SELECT ALL - + col0 + cor0.col1 * - col0 + + col2 / + col0 AS col0 FROM tab2 AS cor0
----
-1422
-221
-4680

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-194
SELECT DISTINCT + 96 DIV cor0.col0 + col1 * 95 + - 90 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
8175
8646
9217

skipif mysql # not compatible
query I rowsort label-194
SELECT DISTINCT + 96 / cor0.col0 + col1 * 95 + - 90 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
8175
8646
9217

query I rowsort
SELECT - - 91 FROM tab0 cor0
----
91
91
91

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-197
SELECT DISTINCT CAST( - col2 AS SIGNED ) + + col2 + - col1 * + 18 FROM tab0 AS cor0
----
-1548
-1638
-1746

skipif mysql # not compatible
query I rowsort label-197
SELECT DISTINCT CAST ( - col2 AS INTEGER ) + + col2 + - col1 * + 18 FROM tab0 AS cor0
----
-1548
-1638
-1746

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

query I rowsort
SELECT 96 * 54 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 4c9fd7097bdce153a185760a3363af23

query I rowsort
SELECT ALL - col0 * + 59 AS col1 FROM tab2
----
-413
-4602
-4661

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

query I rowsort
SELECT ALL - 54 * col1 + + col2 + + col2 AS col0 FROM tab0 cor0
----
-4578
-4750
-5236

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

query I rowsort
SELECT + 90 * + col0 AS col2 FROM tab1
----
270
5760
7200

query I rowsort
SELECT + 29 + col0 FROM tab0 cor0
----
118
53
64

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

skipif mysql # not compatible
query I rowsort label-206
SELECT col1 / cor0.col1 AS col2 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-207
SELECT DISTINCT + col0 + col0 DIV col0 - + CAST( col2 AS SIGNED ) FROM tab1
----
-15
-50
8

skipif mysql # not compatible
query I rowsort label-207
SELECT DISTINCT + col0 + col0 / col0 - + CAST ( col2 AS INTEGER ) FROM tab1
----
-15
-50
8

query I rowsort
SELECT ALL + 3 + col0 + - col2 AS col2 FROM tab2 AS cor0
----
-17
44
55

query I rowsort
SELECT + 47 AS col0 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to 5c7a6f591fb2a38893dafe56c4b9b97f

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

skipif mysql # not compatible
query I rowsort label-210
SELECT tab0.col2 / col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + - col0 * + col1 + 74 * + col0 FROM tab2 AS cor0
----
1170
301
4503

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

query I rowsort
SELECT DISTINCT + 64 * col0 FROM tab0
----
1536
2240
5696

query I rowsort
SELECT ALL + - 81 AS col0 FROM tab1, tab1 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to bab7cb237ee73283089388c330f59598

query I rowsort
SELECT + 12 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

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

query I rowsort
SELECT ALL - 0 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

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

query I rowsort
SELECT ALL + - 20 + col2 * col1 FROM tab0 AS cor0
----
2818
7442
77

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

query I rowsort
SELECT ( cor0.col0 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

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

query I rowsort
SELECT ALL + 79 * + ( col2 ) FROM tab1
----
4266
4503
7584

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

query I rowsort
SELECT ALL + col0 * 31 + + col2 * col2 AS col0 FROM tab0 AS cor0
----
1086
1833
9483

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

query I rowsort
SELECT ALL + 63 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

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

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

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

query I rowsort
SELECT DISTINCT + col0 * - col0 + col2 + col1 AS col0 FROM tab0 AS cor0
----
-1127
-457
-7748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 + ( + col0 ) col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - 55 + - col1 FROM tab1
----
-65
-68
-81

query I rowsort
SELECT DISTINCT col1 * + col2 + + 58 FROM tab2
----
1592
704
895

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

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

query I rowsort
SELECT DISTINCT col0 + - 68 * 80 FROM tab2
----
-5361
-5362
-5433

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
1
33
82

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-241
SELECT - cor0.col0 * CAST( + 65 AS SIGNED ) * - col1 + col2 AS col0 FROM tab1 AS cor0
----
41657
5124
67696

skipif mysql # not compatible
query I rowsort label-241
SELECT - cor0.col0 * CAST ( + 65 AS INTEGER ) * - col1 + col2 AS col0 FROM tab1 AS cor0
----
41657
5124
67696

query I rowsort
SELECT DISTINCT + + col2 * ( col0 ) + col0 * col1 FROM tab0 cor0
----
15397
2856
3430

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-244
SELECT DISTINCT col1 DIV - 6 AS col0 FROM tab0 AS cor0
----
-14
-15
-16

skipif mysql # not compatible
query I rowsort label-244
SELECT DISTINCT col1 / - 6 AS col0 FROM tab0 AS cor0
----
-14
-15
-16

query I rowsort
SELECT + + col2 + 35 * 20 AS col1 FROM tab1 AS cor0
----
754
757
796

onlyif mysql # use DIV operator for integer division
query I rowsort label-246
SELECT col0 DIV 92 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-246
SELECT col0 / 92 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT - 66 * - col1 FROM tab1 cor0
----
1716
660
858

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

query I rowsort
SELECT 88 * - col1 AS col0 FROM tab2
----
-1496
-2728
-5192

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-251
SELECT - col2 + + cor0.col0 * col2 DIV col1 + + col0 AS col1 FROM tab1 AS cor0
----
-45
371
574

skipif mysql # not compatible
query I rowsort label-251
SELECT - col2 + + cor0.col0 * col2 / col1 + + col0 AS col1 FROM tab1 AS cor0
----
-45
371
574

query I rowsort
SELECT DISTINCT col2 + col1 * 25 FROM tab2 AS cor0
----
1501
463
802

query I rowsort
SELECT 35 * - col0 FROM tab0 cor0
----
-1225
-3115
-840

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 + col0 * col2 + - tab1.col0 col2 FROM tab1
----
213
3638
7654

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

query I rowsort
SELECT DISTINCT + - col2 * + col1 + - col0 + col1 FROM tab2 cor0
----
-1553
-708
-813

query I rowsort
SELECT + 34 - - col0 FROM tab1 cor0
----
114
37
98

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

query I rowsort
SELECT ALL 38 AS col1 FROM tab1 AS cor0
----
38
38
38

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * + col2 col1 FROM tab2 AS cor0
----
1560
684
864

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

query I rowsort
SELECT ALL + - cor1.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

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

query I rowsort
SELECT 19 * - tab2.col2 + + col2 FROM tab2
----
-468
-486
-684

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-272
SELECT ALL + CAST( - 87 AS SIGNED ) + col0 FROM tab1 AS cor0
----
-23
-7
-84

skipif mysql # not compatible
query I rowsort label-272
SELECT ALL + CAST ( - 87 AS INTEGER ) + col0 FROM tab1 AS cor0
----
-23
-7
-84

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

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

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

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

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

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

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

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

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

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab2, tab1 cor1
----
243 values hashing to 098e223d780e18b6582523fd6f55eec9

query I rowsort
SELECT DISTINCT ( - 55 ) AS col2 FROM tab1, tab0 AS cor0
----
-55

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - CAST ( 58 AS REAL ) + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-136
-137
-65

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

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

query I rowsort
SELECT ALL ( col1 * + col1 ) FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT + ( 78 ) * col1 * - col2 FROM tab2
----
-119652
-50388
-65286

query I rowsort
SELECT ALL ( col2 + - col0 ) * col1 * + col2 AS col2 FROM tab2
----
-26486
-79768
16740

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

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

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

query I rowsort
SELECT col2 * col1 + col2 FROM tab0
----
2871
7544
98

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

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

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

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

query I rowsort
SELECT + 18 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

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

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

query I rowsort
SELECT + - 79 + - col2 FROM tab0 AS cor0
----
-112
-161
-80

query I rowsort
SELECT ALL + col0 * - 0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT 99 + - tab2.col1 FROM tab2, tab1 AS cor0
----
40
68
82

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

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

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

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

query I rowsort
SELECT DISTINCT - 57 + + col2 FROM tab2 AS cor0
----
-19
-30
-31

query I rowsort
SELECT ALL + ( 79 ) * - cor0.col0 * - col1 FROM tab1 AS cor0
----
50560
6162
82160

query I rowsort
SELECT ALL + 64 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT + 12 AS col1 FROM tab1
----
12
12
12

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

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

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

query I rowsort
SELECT ALL - 19 * col0 FROM tab1 AS cor0
----
-1216
-1520
-57

query I rowsort
SELECT - cor0.col0 * + col2 * 33 FROM tab2 AS cor0
----
-6237
-66924
-99066

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

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

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

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

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

query I rowsort
SELECT + + col2 * + 79 AS col1 FROM tab0 AS cor0
----
2607
6478
79

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

skipif mysql # not compatible
query I rowsort label-316
SELECT + + cor0.col2 + CAST ( col1 AS INTEGER ) * - col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT + - col2 * - 11 FROM tab1 AS cor0
----
1056
594
627

query I rowsort
SELECT ALL - - cor0.col0 + + 0 - 9 AS col2 FROM tab2 AS cor0
----
-2
69
70

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

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

query I rowsort
SELECT + col2 + 98 AS col0 FROM tab0 AS cor0
----
131
180
99

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

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

query I rowsort
SELECT + col2 * + ( col1 + col0 ) AS col0 FROM tab0 AS cor0
----
132
14760
3630

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

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

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

query I rowsort
SELECT DISTINCT + + ( - col2 ) FROM tab1 cor0
----
-54
-57
-96

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

query I rowsort
SELECT + col2 * - 91 FROM tab2 cor0
----
-2366
-2457
-3458

query I rowsort
SELECT + col1 * - 37 AS col1 FROM tab2 AS cor0
----
-1147
-2183
-629

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

query I rowsort
SELECT + 83 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

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

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

query I rowsort
SELECT + 91 FROM tab1, tab0 cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-337
SELECT DISTINCT col1 DIV 3 FROM tab0
----
28
30
32

skipif mysql # not compatible
query I rowsort label-337
SELECT DISTINCT col1 / 3 FROM tab0
----
28
30
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-338
SELECT + ( + cor0.col0 ) * col1 * + col0 + col1 DIV 80 AS col2 FROM tab0 AS cor0
----
118826
49537
720812

skipif mysql # not compatible
query I rowsort label-338
SELECT + ( + cor0.col0 ) * col1 * + col0 + col1 / 80 AS col2 FROM tab0 AS cor0
----
118826
49537
720812

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

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

query I rowsort
SELECT ALL 66 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT DISTINCT + 13 + + col2 AS col1 FROM tab1
----
109
67
70

query I rowsort
SELECT ALL - 21 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to cdcb40c9e1bb9a33ce9167a0d2bac0b1

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

query I rowsort
SELECT + 50 * + 19 AS col2 FROM tab1
----
950
950
950

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

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

query I rowsort
SELECT + 9 * 66 FROM tab0
----
594
594
594

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

query I rowsort
SELECT col2 * - col2 * + 26 FROM tab1
----
-239616
-75816
-84474

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

query I rowsort
SELECT DISTINCT - - ( - 7 ) AS col1 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( 54 ) col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

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

query I rowsort
SELECT DISTINCT - - 62 * + col0 FROM tab2 AS cor0
----
434
4836
4898

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

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

query I rowsort
SELECT 40 - + col1 AS col0 FROM tab2 cor0
----
-19
23
9

query I rowsort
SELECT DISTINCT col2 + + cor0.col0 * 92 AS col2 FROM tab0 cor0
----
2241
3221
8270

query I rowsort
SELECT - col1 * col2 * col0 - col1 AS col0 FROM tab0 AS cor0
----
-3492
-664209
-68198

query I rowsort
SELECT DISTINCT - + 72 + - col0 * + cor0.col1 FROM tab1 AS cor0
----
-1112
-150
-712

query I rowsort
SELECT DISTINCT + 80 + - col1 AS col2 FROM tab2 AS cor0
----
21
49
63

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-365
SELECT - - col2 + col0 DIV + 69 AS col0 FROM tab1 AS cor0
----
54
57
97

skipif mysql # not compatible
query I rowsort label-365
SELECT - - col2 + col0 / + 69 AS col0 FROM tab1 AS cor0
----
54
57
97

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-367
SELECT + - col0 - col1 DIV - col0 AS col1 FROM tab2 AS cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-367
SELECT + - col0 - col1 / - col0 AS col1 FROM tab2 AS cor0
----
-3
-78
-79

query I rowsort
SELECT DISTINCT - col1 + + col1 * + cor0.col1 FROM tab0 cor0
----
7310
8190
9312

query I rowsort
SELECT ALL - - 99 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
2376
3465
8811

query I rowsort
SELECT ALL - cor0.col0 * - col2 + col0 * + col1 AS col2 FROM tab2 AS cor0
----
406
4345
6630

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

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

query I rowsort
SELECT DISTINCT + - 9 + cor0.col0 AS col0 FROM tab0 cor0
----
15
26
80

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col1 AS REAL ) AS col0 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-375
SELECT 89 DIV ( col2 * + col0 ) AS col0 FROM tab0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-375
SELECT 89 / ( col2 * + col0 ) AS col0 FROM tab0
----
0
0
2

query I rowsort
SELECT + - cor1.col1 * 41 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 84d5486b2a480f7d919eea0dc8b9b553

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

query I rowsort
SELECT DISTINCT cor0.col0 * - 57 FROM tab0 AS cor0
----
-1368
-1995
-5073

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

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

query I rowsort
SELECT + + 70 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

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

query I rowsort
SELECT ALL col2 * - col1 + col0 * + 13 AS col2 FROM tab0 AS cor0
----
-2526
-6305
358

query I rowsort
SELECT DISTINCT col0 + - col2 - + col1 FROM tab2 AS cor0
----
-51
-7
24

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

query I rowsort
SELECT - + 51 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

query I rowsort
SELECT ALL - ( 68 ) FROM tab1
----
-68
-68
-68

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

query I rowsort
SELECT + - 16 * + ( - cor0.col1 ) * + col2 AS col1 FROM tab0 AS cor0
----
119392
1552
45408

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

query I rowsort
SELECT ( - 44 ) * + tab2.col1 + ( - tab2.col2 ) FROM tab2
----
-1391
-2622
-786

query I rowsort
SELECT ALL + 49 * - 91 FROM tab1 AS cor0
----
-4459
-4459
-4459

query I rowsort
SELECT ALL 41 * - 35 FROM tab2 AS cor0
----
-1435
-1435
-1435

query I rowsort
SELECT DISTINCT col0 * 31 FROM tab2 cor0
----
217
2418
2449

query I rowsort
SELECT DISTINCT + col0 + - 23 AS col0 FROM tab1 AS cor0
----
-20
41
57

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col0 - 84 col1 FROM tab1 AS cor0
----
-75
4012
6316

query I rowsort
SELECT DISTINCT - 44 + cor0.col2 FROM tab0 cor0
----
-11
-43
38

query I rowsort
SELECT DISTINCT + 48 * - col0 AS col1 FROM tab2 AS cor0
----
-336
-3744
-3792

query I rowsort
SELECT DISTINCT col0 * - col0 - 73 FROM tab0 cor0
----
-1298
-649
-7994

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

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

query I rowsort
SELECT - col0 * + col0 + - 69 FROM tab2
----
-118
-6153
-6310

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

skipif mysql # not compatible
query I rowsort label-403
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / - 26 AS col1 FROM tab0, tab0 AS cor0, tab0 cor1
----
NULL

query I rowsort
SELECT + ( col0 ) + ( - col2 ) + col2 * - col0 FROM tab2
----
-1976
-209
-2961

onlyif mysql # use DIV operator for integer division
query I rowsort label-405
SELECT ALL + col0 DIV col1 + 43 FROM tab1
----
43
49
49

skipif mysql # not compatible
query I rowsort label-405
SELECT ALL + col0 / col1 + 43 FROM tab1
----
43
49
49

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

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

skipif mysql # not compatible
query I rowsort label-407
SELECT DISTINCT + cor0.col1 + col1 * + CAST ( - col0 AS INTEGER ) * col0 FROM tab1 AS cor0
----
-208
-40950
-83187

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 73 * + col2 col1 FROM tab2 AS cor0
----
1898
1971
2774

query I rowsort
SELECT ALL + - 17 * col1 FROM tab0 AS cor0
----
-1462
-1547
-1649

query I rowsort
SELECT ALL - col1 + - 95 FROM tab1
----
-105
-108
-121

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

query I rowsort
SELECT ALL - col0 + + ( 90 ) AS col1 FROM tab0 cor0
----
1
55
66

query I rowsort
SELECT ALL + + col0 * ( 78 ) * col2 + 90 * col0 FROM tab1 AS cor0
----
12906
290304
606240

query I rowsort
SELECT ALL + col2 + + 76 + cor0.col0 * - col2 FROM tab0 cor0
----
-683
-7140
42

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

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 DISTINCT + col1 * ( + 20 ) FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT ALL ( 54 ) FROM tab2 AS cor0
----
54
54
54

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

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

query I rowsort
SELECT ALL 47 AS col1 FROM tab1 cor0
----
47
47
47

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

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

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + ( + col2 ) AS REAL ) AS col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + 94 col2 FROM tab1 AS cor0
----
158
174
97

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

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

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

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

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

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

query I rowsort
SELECT col2 - - ( + col1 * col2 ) AS col0 FROM tab2
----
1560
684
864

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

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

query I rowsort
SELECT - col2 + 88 AS col0 FROM tab2
----
50
61
62

query I rowsort
SELECT tab1.col0 + cor0.col2 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to f2656d9e76ae2d6dc568bba21c85e398

query I rowsort
SELECT DISTINCT - col0 + col2 * 12 * + col2 FROM tab2
----
17249
8034
8741

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

query I rowsort
SELECT - tab0.col0 FROM tab0 WHERE NOT ( NULL ) <> NULL
----

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

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

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

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

query I rowsort
SELECT col0 * col1 FROM tab0 WHERE ( NULL ) <> NULL
----

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

query I rowsort
SELECT DISTINCT col0 + col2 * col0 - + col1 AS col0 FROM tab0 AS cor0
----
-27
7296
730

query I rowsort
SELECT + col1 + + col0 * - col0 FROM tab2
----
-18
-6025
-6224

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

query I rowsort
SELECT ALL - col2 * + col2 * + col2 + col2 AS col1 FROM tab1
----
-157410
-185136
-884640

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col2 * col1 + - col2 FROM tab0 cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL - + col0 * col1 - cor0.col0 * - cor0.col0 FROM tab0 AS cor0
----
-1488
-178
-2170

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-458
SELECT + col0 DIV col2 + cor0.col1 AS col1 FROM tab0 AS cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-458
SELECT + col0 / col2 + cor0.col1 AS col1 FROM tab0 AS cor0
----
132
86
92

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-460
SELECT - 5 DIV - col1 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-460
SELECT - 5 / - col1 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-461
SELECT ( col0 ) + col2 DIV + 6 FROM tab1 AS cor0
----
12
73
96

skipif mysql # not compatible
query I rowsort label-461
SELECT ( col0 ) + col2 / + 6 FROM tab1 AS cor0
----
12
73
96

query I rowsort
SELECT DISTINCT 59 * col1 + + ( - col2 ) * + col1 + ( 1 + col0 ) AS col1 FROM tab0
----
-2003
2261
5662

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

query I rowsort
SELECT - cor0.col1 * - 95 AS col1 FROM tab2 AS cor0
----
1615
2945
5605

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

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

query I rowsort
SELECT ALL - col2 * - col2 AS col2 FROM tab2
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 78 col2 FROM tab2 AS cor0
----
2028
2106
2964

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col0 * col1 + - col1 col0 FROM tab1
----
-107
-1133
-714

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-471
SELECT ALL col1 DIV - tab1.col1 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-471
SELECT ALL col1 / - tab1.col1 FROM tab1
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-472
SELECT - col1 DIV col2 + col1 * - col1 AS col2 FROM tab1
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-472
SELECT - col1 / col2 + col1 * - col1 AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT col1 FROM tab1 WHERE + col0 < col0
----

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

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

query I rowsort
SELECT ALL + col2 + + col2 + - col1 FROM tab0
----
-20
-95
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-477
SELECT - col0 - col2 DIV - col2 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-477
SELECT - col0 - col2 / - col2 FROM tab0
----
-23
-34
-88

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - col0 + + tab2.col0 + + col2 FROM tab2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 * + col1 col1 FROM tab0
----
636056
753571
912673

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

query I rowsort
SELECT 2 + + cor0.col1 * + col2 AS col0 FROM tab2 cor0
----
1536
648
839

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col2 + - col0 + + col0 BETWEEN col1 * - col0 AND col0 - - col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

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

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

query I rowsort
SELECT DISTINCT col2 * - col2 - col2 * - tab2.col0 FROM tab2
----
-540
1352
1558

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

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

query I rowsort
SELECT DISTINCT - tab0.col1 * - 15 AS col2 FROM tab0
----
1290
1365
1455

query I rowsort
SELECT ALL - 89 AS col1 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to c36e597b7bc5727536f5bb580e6cebbc

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

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-506
SELECT ALL - ( - cor0.col0 ) DIV - col1 + col1 + - 49 AS col0 FROM tab2 AS cor0
----
-18
-36
9

skipif mysql # not compatible
query I rowsort label-506
SELECT ALL - ( - cor0.col0 ) / - col1 + col1 + - 49 AS col0 FROM tab2 AS cor0
----
-18
-36
9

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-512
SELECT 1 / col0 - cor0.col2 col0 FROM tab0 AS cor0
----
-1
-33
-82

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

query I rowsort
SELECT DISTINCT - 13 * col1 + + col2 FROM tab2 AS cor0
----
-183
-376
-741

query I rowsort
SELECT DISTINCT + 5 + col1 * col0 FROM tab2 AS cor0
----
1348
222
4607

query I rowsort
SELECT ALL + 6 + ( col2 ) FROM tab2 AS cor0
----
32
33
44

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

query I rowsort
SELECT col0 * ( 52 ) + + col1 FROM tab2
----
395
4115
4125

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-521
SELECT DISTINCT - col0 DIV + 24 AS col0 FROM tab1 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-521
SELECT DISTINCT - col0 / + 24 AS col0 FROM tab1 AS cor0
----
-2
-3
0

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

skipif mysql # not compatible
query I rowsort label-522
SELECT - col0 + - col0 / col0 + col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - + cor0.col1 + + cor0.col0 + 33 FROM tab2 AS cor0
----
52
9
95

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

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

query I rowsort
SELECT + 81 * col1 AS col0 FROM tab2 AS cor0
----
1377
2511
4779

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

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

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

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

query I rowsort
SELECT - - col0 + col1 + col1 FROM tab2 AS cor0
----
113
196
69

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

query I rowsort
SELECT col2 * - col1 * + col2 AS col0 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT + col0 + col0 + - ( + col0 ) AS col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL ( - col0 ) + col2 FROM tab0 AS cor0
----
-34
-7
9

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-537
SELECT col2 DIV col0 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-537
SELECT col2 / col0 FROM tab0 cor0
----
0
0
1

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

query I rowsort
SELECT DISTINCT - col0 * - ( - col1 + + col0 ) FROM tab2 AS cor0
----
-168
1482
4898

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

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

query I rowsort
SELECT ALL 94 AS col0 FROM tab2
----
94
94
94

query I rowsort
SELECT ALL + ( + col0 ) + ( - ( - tab0.col0 ) ) AS col1 FROM tab0
----
178
48
70

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

skipif mysql # not compatible
query I rowsort label-543
SELECT DISTINCT + col0 / - ( 28 ) FROM tab0 AS cor0
----
-1
-3
0

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

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

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

query I rowsort
SELECT ALL - - col0 * + col2 + - col0 * + col0 FROM tab0 cor0
----
-1190
-623
216

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

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

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

skipif mysql # not compatible
query I rowsort label-549
SELECT + + col2 + CAST ( + col1 * + col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1136
132
697

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

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

query I rowsort
SELECT DISTINCT + + cor0.col2 + 34 * col0 FROM tab1 AS cor0
----
156
2233
2816

query I rowsort
SELECT 31 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

onlyif mysql # use DIV operator for integer division
query I rowsort label-554
SELECT ALL + tab0.col1 DIV 8 - col1 FROM tab0
----
-76
-80
-85

skipif mysql # not compatible
query I rowsort label-554
SELECT ALL + tab0.col1 / 8 - col1 FROM tab0
----
-76
-80
-85

query I rowsort
SELECT DISTINCT 16 * + col2 AS col1 FROM tab0 AS cor0
----
1312
16
528

query I rowsort
SELECT - 82 + - tab2.col0 - col2 AS col0 FROM tab2
----
-116
-186
-199

query I rowsort
SELECT ALL - 34 + + col2 AS col1 FROM tab0
----
-1
-33
48

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

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

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

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

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

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

query I rowsort
SELECT - col2 * - cor0.col2 + + col0 * cor0.col1 AS col1 FROM tab2 AS cor0
----
2787
5278
946

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

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

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

query I rowsort
SELECT - - 3 + + col1 FROM tab2 AS cor0
----
20
34
62

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

query I rowsort
SELECT + + cor0.col0 + 94 * col0 AS col0 FROM tab0 AS cor0
----
2280
3325
8455

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

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

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

query I rowsort
SELECT - col0 * + 86 + col1 FROM tab2 AS cor0
----
-571
-6649
-6777

query I rowsort
SELECT - col1 * ( col2 + col2 ) AS col1 FROM tab2 AS cor0
----
-1292
-1674
-3068

query I rowsort
SELECT + - cor0.col2 + + 24 * + col0 FROM tab2 AS cor0
----
141
1846
1858

query I rowsort
SELECT - - 44 * col0 AS col2 FROM tab2 AS cor0
----
308
3432
3476

query I rowsort
SELECT 47 * + col0 + 81 * col2 * cor0.col1 FROM tab1 AS cor0
----
104848
113865
49178

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

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

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

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

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

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

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

query I rowsort
SELECT ALL col0 * 14 FROM tab1 cor0
----
1120
42
896

query I rowsort
SELECT + - col2 * col1 + 22 AS col2 FROM tab2 AS cor0
----
-1512
-624
-815

query I rowsort
SELECT DISTINCT 81 + + col2 * - 72 FROM tab0
----
-2295
-5823
9

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

query I rowsort
SELECT DISTINCT + col2 * - 20 FROM tab0
----
-1640
-20
-660

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-588
SELECT - + CAST( + 95 AS SIGNED ) + - col2 FROM tab2 AS cor0
----
-121
-122
-133

skipif mysql # not compatible
query I rowsort label-588
SELECT - + CAST ( + 95 AS INTEGER ) + - col2 FROM tab2 AS cor0
----
-121
-122
-133

query I rowsort
SELECT - col1 + + 13 FROM tab2 AS cor0
----
-18
-4
-46

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

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

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

skipif mysql # not compatible
query I rowsort label-591
SELECT col2 / - col2 - - 94 FROM tab1 AS cor0
----
93
93
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-592
SELECT ALL + col0 DIV - 25 AS col1 FROM tab2
----
-3
-3
0

skipif mysql # not compatible
query I rowsort label-592
SELECT ALL + col0 / - 25 AS col1 FROM tab2
----
-3
-3
0

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

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-595
SELECT ALL col2 DIV + col1 AS col0 FROM tab2 AS cor0
----
0
0
2

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

query I rowsort
SELECT ALL + - cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT ALL - 83 FROM tab0, tab1 AS cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-599
SELECT - + 84 DIV 6 FROM tab1 AS cor0
----
-14
-14
-14

skipif mysql # not compatible
query I rowsort label-599
SELECT - + 84 / 6 FROM tab1 AS cor0
----
-14
-14
-14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 - col1 col2 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT ALL ( col1 ) + + tab1.col1 * - col2 + col1 * col0 FROM tab1
----
-1300
-195
80

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

query I rowsort
SELECT 45 * col0 FROM tab0 AS cor0
----
1080
1575
4005

query I rowsort
SELECT DISTINCT + 19 + col1 FROM tab0
----
105
110
116

query I rowsort
SELECT + 69 * col1 + + col0 FROM tab0
----
5958
6368
6728

query I rowsort
SELECT DISTINCT 76 AS col2 FROM tab2
----
76

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT 37 * + col2 AS col1 FROM tab2
----
1406
962
999

query I rowsort
SELECT - col2 - 19 * cor0.col2 FROM tab1 AS cor0
----
-1080
-1140
-1920

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

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

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

query I rowsort
SELECT - cor0.col1 * 97 FROM tab1 AS cor0
----
-1261
-2522
-970

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

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

query I rowsort
SELECT + col1 + + 71 AS col1 FROM tab2
----
102
130
88

query I rowsort
SELECT DISTINCT + col1 * 20 FROM tab1
----
200
260
520

query I rowsort
SELECT - 30 * cor0.col2 FROM tab0 cor0
----
-2460
-30
-990

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

query I rowsort
SELECT ALL - ( 65 ) AS col2 FROM tab1
----
-65
-65
-65

query I rowsort
SELECT - 67 - - tab2.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 050facb2ac21c694b9c6a559927e6a7e

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-625
SELECT + CAST ( + 17 AS INTEGER ) col0 FROM tab0
----
17
17
17

query I rowsort
SELECT + - 73 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 2931474b870c05694e446771031a6949

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

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

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

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

query I rowsort
SELECT DISTINCT 92 + + col1 * 48 FROM tab0 cor0
----
4220
4460
4748

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

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

query I rowsort
SELECT DISTINCT - col1 * col0 * 58 FROM tab2
----
-12586
-266916
-77894

skipif mysql # not compatible
query I rowsort
SELECT ALL + + CAST ( + cor1.col0 AS REAL ) FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL + + col0 * + col0 * 3 FROM tab0 AS cor0
----
1728
23763
3675

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

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

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

query I rowsort
SELECT ALL - - col0 * - cor0.col0 - 93 AS col1 FROM tab0 AS cor0
----
-1318
-669
-8014

query I rowsort
SELECT ALL + col0 + + col2 * + 86 + + 30 AS col1 FROM tab0 AS cor0
----
151
2892
7171

query I rowsort
SELECT DISTINCT + col2 + cor0.col2 * 43 AS col0 FROM tab2 AS cor0
----
1144
1188
1672

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

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

query I rowsort
SELECT ALL - col2 - col0 * - 3 FROM tab0 AS cor0
----
104
185
39

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-645
SELECT + cor0.col2 + - 3 DIV + 17 AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-645
SELECT + cor0.col2 + - 3 / + 17 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT cor0.col0 + + 84 + + col1 FROM tab2 AS cor0
----
122
180
221

onlyif mysql # use DIV operator for integer division
query I rowsort label-647
SELECT DISTINCT + col2 DIV - ( + ( + col1 ) ) + col2 AS col1 FROM tab1 AS cor0
----
52
89

skipif mysql # not compatible
query I rowsort label-647
SELECT DISTINCT + col2 / - ( + ( + col1 ) ) + col2 AS col1 FROM tab1 AS cor0
----
52
89

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

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

query I rowsort
SELECT ALL col1 * cor0.col0 + 14 AS col1 FROM tab1 AS cor0
----
1054
654
92

query I rowsort
SELECT + + col2 + 69 FROM tab1 AS cor0
----
123
126
165

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

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

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

skipif mysql # not compatible
query I rowsort label-652
SELECT + col1 + - CAST ( + col2 AS INTEGER ) - col2 AS col2 FROM tab1 AS cor0
----
-104
-179
-82

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

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

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

query I rowsort
SELECT cor0.col1 + 34 * - col2 AS col0 FROM tab1 AS cor0
----
-1810
-1928
-3251

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

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

query I rowsort
SELECT ALL col0 * - 77 AS col0 FROM tab1 cor0
----
-231
-4928
-6160

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

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

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

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

query I rowsort
SELECT - cor0.col0 * + 62 - + col1 * - col0 FROM tab1 AS cor0
----
-108
-3328
-3920

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

skipif mysql # not compatible
query I rowsort label-663
SELECT ALL - CAST ( - 24 AS INTEGER ) + col0 FROM tab0 cor0
----
113
48
59

query I rowsort
SELECT 65 + col1 FROM tab0 AS cor0
----
151
156
162

query I rowsort
SELECT + col2 * + 46 AS col0 FROM tab2 AS cor0
----
1196
1242
1748

query I rowsort
SELECT DISTINCT + ( + col0 ) + + cor0.col2 * ( - col1 + - col1 ) AS col0 FROM tab2 AS cor0
----
-1213
-1667
-2990

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

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

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

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

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

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

query I rowsort
SELECT - - 87 AS col2 FROM tab1 AS cor0
----
87
87
87

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

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

query I rowsort
SELECT col1 + - col2 * col0 * + col0 FROM tab0 AS cor0
----
-1128
-18922
-649431

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

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

query I rowsort
SELECT ALL - 26 * - col1 + + col1 * col2 FROM tab1 AS cor0
----
1586
2080
830

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

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

skipif mysql # not compatible
query I rowsort label-680
SELECT + CAST ( - 34 AS INTEGER ) FROM tab1 AS cor0
----
-34
-34
-34

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

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

query I rowsort
SELECT - ( cor0.col0 ) * - ( col1 ) + col1 + col0 FROM tab2 AS cor0
----
1439
255
4739

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

query I rowsort
SELECT ALL - col0 + col0 * + col2 * - tab2.col0 FROM tab2
----
-1330
-158262
-237237

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-686
SELECT ALL cor0.col0 - CAST( + col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-686
SELECT ALL cor0.col0 - CAST ( + col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-16
-51
7

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

query I rowsort
SELECT col1 * ( - 51 ) AS col1 FROM tab0
----
-4386
-4641
-4947

query I rowsort
SELECT ALL + 75 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

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

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

query I rowsort
SELECT col0 + + col2 + + col2 * col0 FROM tab1
----
219
3769
7856

query I rowsort
SELECT DISTINCT col0 + - ( col1 ) * col2 + col0 * + 94 FROM tab2
----
-172
5876
6859

query I rowsort
SELECT DISTINCT col1 + col0 + - 67 AS col1 FROM tab0
----
113
43
65

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

query I rowsort
SELECT col0 * 51 - 50 FROM tab0 AS cor0
----
1174
1735
4489

onlyif mysql # use DIV operator for integer division
query I rowsort label-697
SELECT DISTINCT col0 * - col1 - col1 DIV cor0.col1 FROM tab0 AS cor0
----
-2065
-3396
-8100

skipif mysql # not compatible
query I rowsort label-697
SELECT DISTINCT col0 * - col1 - col1 / cor0.col1 FROM tab0 AS cor0
----
-2065
-3396
-8100

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

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

query I rowsort
SELECT ALL + 59 AS col0 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT ALL 2 + cor0.col0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 5f3a7140bcecd8bbe7958b334a07ccfa

query I rowsort
SELECT DISTINCT tab0.col2 AS col0 FROM tab0, tab2 AS cor0
----
1
33
82

query I rowsort
SELECT col1 + - col0 * - 7 + - 60 FROM tab2
----
20
510
545

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

query I rowsort
SELECT - ( col1 ) + + ( - 7 * col0 ) - ( - 94 ) FROM tab0 AS cor0
----
-160
-248
-620

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

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

query I rowsort
SELECT + - col0 * cor0.col0 * + 50 + + col0 FROM tab2 AS cor0
----
-2443
-304122
-311971

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

query I rowsort
SELECT - 97 + col2 AS col0 FROM tab0 AS cor0
----
-15
-64
-96

query I rowsort
SELECT + col2 * + col2 * + 22 + + col2 * col2 + + 4 * col0 AS col2 FROM tab0 AS cor0
----
155008
163
25143

query I rowsort
SELECT + - 71 + col0 AS col2 FROM tab2 AS cor0
----
-64
7
8

query I rowsort
SELECT - + col0 + + col2 * 74 FROM tab1 AS cor0
----
3993
4154
7024

query I rowsort
SELECT DISTINCT + + cor0.col0 * 13 FROM tab0 AS cor0
----
1157
312
455

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

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

query I rowsort
SELECT - col2 * + 40 + - col2 FROM tab0 AS cor0
----
-1353
-3362
-41

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

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

query I rowsort
SELECT + cor0.col2 * 3 + col0 FROM tab1 AS cor0
----
165
235
368

onlyif mysql # use DIV operator for integer division
query I rowsort label-719
SELECT - 62 * col2 DIV + col2 col0 FROM tab0 AS cor0
----
-62
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-719
SELECT - 62 * col2 / + col2 col0 FROM tab0 AS cor0
----
-62
-62
-62

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

skipif mysql # not compatible
query I rowsort label-720
SELECT ALL + CAST ( col2 AS INTEGER ) + + col2 AS col2 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT - 8 AS col2 FROM tab2
----
-8
-8
-8

query I rowsort
SELECT - + 60 FROM tab2 AS cor0
----
-60
-60
-60

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

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

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

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

query I rowsort
SELECT 0 + - col2 * cor0.col2 * 97 FROM tab2 AS cor0
----
-140068
-65572
-70713

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

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

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

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

query I rowsort
SELECT - 80 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

query I rowsort
SELECT - 14 + + col1 FROM tab1
----
-1
-4
12

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

skipif mysql # not compatible
query I rowsort label-732
SELECT - + col0 / col1 FROM tab1 cor0
----
-6
-6
0

query I rowsort
SELECT 59 * col1 FROM tab1 cor0
----
1534
590
767

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 * + col0 col0 FROM tab1 AS cor0
----
104
1053
650

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-740
SELECT + 19 DIV tab1.col2 col2 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-740
SELECT + 19 / tab1.col2 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - 52 + + col0 * + col2 AS col2 FROM tab0
----
-17
7246
740

query I rowsort
SELECT ALL - col2 + 33 FROM tab1 AS cor0
----
-21
-24
-63

query I rowsort
SELECT 23 + + 95 * col0 FROM tab0 AS cor0
----
2303
3348
8478

query I rowsort
SELECT DISTINCT - 36 * - 96 FROM tab2 AS cor0
----
3456

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

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

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

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

query I rowsort
SELECT - col0 * ( - col0 ) AS col2 FROM tab2
----
49
6084
6241

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 70 * + 50 col0 FROM tab1
----
3500
3500
3500

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

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

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

query I rowsort
SELECT ( - 15 ) FROM tab0
----
-15
-15
-15

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

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

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

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

query I rowsort
SELECT + col0 * - 98 AS col2 FROM tab1
----
-294
-6272
-7840

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

query I rowsort
SELECT + 14 * 10 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to ec2e101908a0c2a3287de7292cabaa57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col1 * cor0.col1 col1 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT ALL + 48 * - col1 AS col2 FROM tab2 AS cor0
----
-1488
-2832
-816

query I rowsort
SELECT + col0 * 60 + - col0 FROM tab2 AS cor0
----
413
4602
4661

query I rowsort
SELECT ( col0 ) * col2 + - 41 AS col2 FROM tab1
----
121
3607
7639

query I rowsort
SELECT ALL 19 + + col1 * col1 FROM tab2
----
308
3500
980

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 45 * col1 + - col1 col1 FROM tab2 AS cor0
----
1364
2596
748

query I rowsort
SELECT DISTINCT col1 + - 59 FROM tab0
----
27
32
38

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

query I rowsort
SELECT 76 + - col1 FROM tab0
----
-10
-15
-21

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-774
SELECT - ( col1 + tab1.col1 ) DIV col1 FROM tab1
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-774
SELECT - ( col1 + tab1.col1 ) / col1 FROM tab1
----
-2
-2
-2

query I rowsort
SELECT DISTINCT + col2 * ( - 58 ) - col2 AS col2 FROM tab0 AS cor0
----
-1947
-4838
-59

query I rowsort
SELECT col0 * col0 - col1 AS col0 FROM tab1 AS cor0
----
-17
4086
6387

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

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

query I rowsort
SELECT - + col1 * ( 15 ) - col0 * - 60 FROM tab2 AS cor0
----
-45
3795
4485

query I rowsort
SELECT DISTINCT col2 + 32 AS col0 FROM tab1 AS cor0
----
128
86
89

query I rowsort
SELECT col0 - - cor0.col1 * 95 AS col1 FROM tab1 AS cor0
----
1014
1315
2473

query I rowsort
SELECT DISTINCT col0 - + 55 AS col1 FROM tab1 AS cor0
----
-52
25
9

query I rowsort
SELECT DISTINCT + 61 * tab1.col0 FROM tab1
----
183
3904
4880

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-784
SELECT 81 + - tab0.col1 DIV col2 AS col2 FROM tab0
----
-16
79
80

skipif mysql # not compatible
query I rowsort label-784
SELECT 81 + - tab0.col1 / col2 AS col2 FROM tab0
----
-16
79
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-785
SELECT - CAST( NULL AS SIGNED ) + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-785
SELECT - CAST ( NULL AS INTEGER ) + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT + + col2 - 90 FROM tab0 AS cor0
----
-57
-8
-89

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

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

query I rowsort
SELECT ALL - col2 - ( col2 ) AS col0 FROM tab1 cor0
----
-108
-114
-192

query I rowsort
SELECT ALL col0 * col0 + - 82 * - col2 AS col1 FROM tab2 AS cor0
----
2263
8216
9357

query I rowsort
SELECT - col0 * + 4 - col0 FROM tab1 AS cor0
----
-15
-320
-400

onlyif mysql # use DIV operator for integer division
query I rowsort label-792
SELECT ALL col1 * 87 + - col0 DIV + col1 + + col1 FROM tab1 cor0
----
1138
2288
874

skipif mysql # not compatible
query I rowsort label-792
SELECT ALL col1 * 87 + - col0 / + col1 + + col1 FROM tab1 cor0
----
1138
2288
874

query I rowsort
SELECT ALL col1 * 0 * - ( - col1 * - 89 ) + - ( col2 ) FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - - cor0.col1 * 44 FROM tab1 AS cor0
----
1144
440
572

query I rowsort
SELECT + + col1 * + ( col1 ) + col2 AS col0 FROM tab1 AS cor0
----
157
265
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-796
SELECT DISTINCT + col1 DIV + 11 + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1249
1406
570

skipif mysql # not compatible
query I rowsort label-796
SELECT DISTINCT + col1 / + 11 + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1249
1406
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-797
SELECT DISTINCT col2 * - CAST( col1 AS SIGNED ) * cor0.col0 col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-797
SELECT DISTINCT col2 * - CAST ( col1 AS INTEGER ) * cor0.col0 col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + cor0.col1 col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - col0 * col0 + + 21 AS col2 FROM tab2
----
-28
-6063
-6220

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col2 + + col2 * 71 col0 FROM tab2
----
1820
1890
2660

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

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

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

skipif mysql # not compatible
query I rowsort label-804
SELECT ALL - cor0.col2 * CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab1 cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

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

query I rowsort
SELECT col0 * - 55 AS col1 FROM tab0
----
-1320
-1925
-4895

query I rowsort
SELECT + 55 * 43 FROM tab0, tab0 AS cor0
----
9 values hashing to 63035cb874cec707311262ccabca4e56

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

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

query I rowsort
SELECT ALL col0 + - col2 + + col0 AS col0 FROM tab2 cor0
----
-13
120
130

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-810
SELECT CAST( + 99 AS SIGNED ) + col1 FROM tab1 AS cor0
----
109
112
125

skipif mysql # not compatible
query I rowsort label-810
SELECT CAST ( + 99 AS INTEGER ) + col1 FROM tab1 AS cor0
----
109
112
125

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

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

skipif mysql # not compatible
query I rowsort label-812
SELECT - ( - cor0.col0 ) * col1 - - CAST ( col0 AS INTEGER ) * + col1 AS col2 FROM tab0 AS cor0
----
16198
4128
6790

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

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

query I rowsort
SELECT 33 AS col0 FROM tab1
----
33
33
33

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

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

query I rowsort
SELECT DISTINCT + 97 * col0 + + col1 FROM tab0 AS cor0
----
2414
3492
8724

query I rowsort
SELECT col2 + 93 AS col0 FROM tab1 AS cor0
----
147
150
189

query I rowsort
SELECT - + 88 FROM tab2 cor0
----
-88
-88
-88

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

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

query I rowsort
SELECT - + 81 * + col1 - - col1 * + 59 AS col1 FROM tab1 AS cor0
----
-220
-286
-572

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

query I rowsort
SELECT + + col2 + + col0 * 89 AS col2 FROM tab0 cor0
----
2169
3116
8003

query I rowsort
SELECT DISTINCT - + 67 + - cor0.col2 AS col0 FROM tab2 cor0
----
-105
-93
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 4 col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 39ed23475412c3cbba02ecdd2d7018e6

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

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

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

query I rowsort
SELECT DISTINCT + + 14 + - col2 FROM tab0 AS cor0
----
-19
-68
13

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

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

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

query I rowsort
SELECT DISTINCT + 92 * + col0 AS col2 FROM tab2 AS cor0
----
644
7176
7268

query I rowsort
SELECT + col0 * - col2 * 48 FROM tab2 AS cor0
----
-144096
-9072
-97344

query I rowsort
SELECT ( col0 ) + + cor0.col1 * - 10 FROM tab0 cor0
----
-821
-836
-935

query I rowsort
SELECT ALL + - 77 * - col2 FROM tab2 AS cor0
----
2002
2079
2926

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

query I rowsort
SELECT - col2 + + ( 28 ) FROM tab0 cor0
----
-5
-54
27

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

query I rowsort
SELECT + col2 * + 58 AS col2 FROM tab0 AS cor0
----
1914
4756
58

query I rowsort
SELECT cor0.col0 * col1 * 39 AS col1 FROM tab2 AS cor0
----
179478
52377
8463

query I rowsort
SELECT + - col1 * col1 * col1 FROM tab2 AS cor0
----
-205379
-29791
-4913

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

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

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

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

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

query I rowsort
SELECT ALL tab0.col2 * - tab0.col0 FROM tab0 WHERE NOT - col2 - - col2 BETWEEN col0 AND NULL
----
-35
-7298
-792

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col2 - tab0.col0 col0 FROM tab0
----
-1113
-36
-6813

query I rowsort
SELECT + - col0 * col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
-4039
-6304
45

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

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

query I rowsort
SELECT col2 * - col1 + - col1 * col1 FROM tab2 AS cor0
----
-1798
-5015
-935

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

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

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

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

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

query I rowsort
SELECT ALL - col2 + col0 * col1 * col2 FROM tab2
----
119626
50996
5832

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

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

query I rowsort
SELECT ALL tab1.col1 AS col2 FROM tab1 WHERE NOT col1 * - tab1.col2 * - col1 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col1 * col2 + col2 AS col2 FROM tab0
----
2871
7544
98

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-863
SELECT col0 + col0 DIV + tab1.col2 FROM tab1
----
3
65
80

skipif mysql # not compatible
query I rowsort label-863
SELECT col0 + col0 / + tab1.col2 FROM tab1
----
3
65
80

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + 1 + col2 AS col2 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT - 18 * - 60 + cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 709b1ef91cfa56e1dfe727192c60dd4f

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 4 * + col0 + - 57 col1 FROM tab1 AS cor0
----
-313
-377
-69

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-878
SELECT col1 - col2 DIV - col2 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-878
SELECT col1 - col2 / - col2 FROM tab0
----
87
92
98

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE ( col1 - cor0.col0 ) = ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col2 + col2 + col2 col1 FROM tab2
----
1586
722
891

onlyif mysql # use DIV operator for integer division
query I rowsort label-881
SELECT col1 + - tab1.col2 - col1 DIV + col0 FROM tab1
----
-36
-47
-83

skipif mysql # not compatible
query I rowsort label-881
SELECT col1 + - tab1.col2 - col1 / + col0 FROM tab1
----
-36
-47
-83

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

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

query III rowsort
SELECT ALL * FROM tab1 cor0 WHERE NULL BETWEEN NULL AND NULL
----

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

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

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

query I rowsort
SELECT - tab0.col0 FROM tab0 WHERE col0 IN ( col0 )
----
-24
-35
-89

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

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

query I rowsort
SELECT ALL col2 - col0 * - col0 AS col0 FROM tab2
----
6110
6279
76

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - tab2.col0 - col1 * + tab2.col2 col0 FROM tab2
----
-1553
-708
-813

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-897
SELECT ALL ( col2 ) * + CAST ( 60 AS INTEGER ) FROM tab0 AS cor0
----
1980
4920
60

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-899
SELECT ALL - col2 + - col1 DIV + col1 FROM tab2 cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-899
SELECT ALL - col2 + - col1 / + col1 FROM tab2 cor0
----
-27
-28
-39

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + tab1.col1 ) + - col2 col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT col0 * + col1 + + 57 * - 91 FROM tab2
----
-3844
-4970
-585

query I rowsort
SELECT ( - tab0.col0 + 40 ) AS col1 FROM tab0
----
-49
16
5

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

query I rowsort
SELECT - 94 * col1 FROM tab0 AS cor0
----
-8084
-8554
-9118

onlyif mysql # use DIV operator for integer division
query I rowsort label-906
SELECT DISTINCT + 86 * col1 DIV - col2 AS col1 FROM tab1 AS cor0
----
-11
-15
-41

skipif mysql # not compatible
query I rowsort label-906
SELECT DISTINCT + 86 * col1 / - col2 AS col1 FROM tab1 AS cor0
----
-11
-15
-41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + 31 col0 FROM tab2 AS cor0
----
57
58
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + col2 - - col1 col2 FROM tab0
----
-1003
-6633
96

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

query I rowsort
SELECT - col0 + + 93 AS col0 FROM tab1 AS cor0
----
13
29
90

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

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

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

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

query I rowsort
SELECT DISTINCT - col1 + - 49 * + col2 - col0 AS col1 FROM tab0 AS cor0
----
-1727
-181
-4198

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

query I rowsort
SELECT DISTINCT cor0.col0 * + ( + col0 ) + + col1 * + 30 FROM tab0 AS cor0
----
10651
3156
4135

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-916
SELECT DISTINCT col0 * - tab0.col1 + CAST( col1 * col1 AS SIGNED ) + col1 FROM tab0
----
273
5418
6111

skipif mysql # not compatible
query I rowsort label-916
SELECT DISTINCT col0 * - tab0.col1 + CAST ( col1 * col1 AS INTEGER ) + col1 FROM tab0
----
273
5418
6111

query I rowsort
SELECT 48 + tab2.col0 AS col0 FROM tab2
----
126
127
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-918
SELECT DISTINCT - ( + col1 ) DIV - col1 + + col2 * + col2 AS col1 FROM tab1
----
2917
3250
9217

skipif mysql # not compatible
query I rowsort label-918
SELECT DISTINCT - ( + col1 ) / - col1 + + col2 * + col2 AS col1 FROM tab1
----
2917
3250
9217

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

query I rowsort
SELECT ( - col0 * 68 ) + col1 FROM tab2
----
-445
-5245
-5355

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

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

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

query I rowsort
SELECT ALL - col0 + col0 * + 80 + col0 FROM tab2
----
560
6240
6320

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

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

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

query I rowsort
SELECT DISTINCT - - 55 FROM tab0 cor0
----
55

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

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

query I rowsort
SELECT ALL + + 58 * 70 + - cor0.col1 FROM tab1 AS cor0
----
4034
4047
4050

query I rowsort
SELECT DISTINCT - + ( col2 ) * - col1 + + col0 * col0 + col0 FROM tab2 AS cor0
----
6966
7696
893

query I rowsort
SELECT DISTINCT 99 * + col0 AS col0 FROM tab0 AS cor0
----
2376
3465
8811

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

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

query I rowsort
SELECT ALL 19 + - 0 + + col0 FROM tab1 AS cor0
----
22
83
99

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

skipif mysql # not compatible
query I rowsort label-934
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 39 FROM tab0, tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 + - col2 * + col1 * col1 FROM tab2
----
-10903
-25940
-90428

query I rowsort
SELECT - tab2.col1 * col1 * - col0 - col2 AS col2 FROM tab2
----
22793
271492
6700

query I rowsort
SELECT + 1 AS col1 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-939
SELECT CAST( - col1 * col2 AS SIGNED ) + + col1 * + ( col1 ) * 77 FROM tab2
----
21607
266503
73160

skipif mysql # not compatible
query I rowsort label-939
SELECT CAST ( - col1 * col2 AS INTEGER ) + + col1 * + ( col1 ) * 77 FROM tab2
----
21607
266503
73160

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

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

query I rowsort
SELECT ALL 97 AS col0 FROM tab1
----
97
97
97

query I rowsort
SELECT + ( 62 ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT ALL - + 34 + col1 * + 44 FROM tab1 AS cor0
----
1110
406
538

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

query I rowsort
SELECT ALL - - 95 + - col0 AS col1 FROM tab1 cor0
----
15
31
92

query I rowsort
SELECT ALL - 60 + - col0 FROM tab0 AS cor0
----
-149
-84
-95

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

query I rowsort
SELECT - + 24 FROM tab2 AS cor0
----
-24
-24
-24

onlyif mysql # use DIV operator for integer division
query I rowsort label-950
SELECT ALL + + 58 + col1 * + col2 DIV + col2 AS col0 FROM tab0 AS cor0
----
144
149
155

skipif mysql # not compatible
query I rowsort label-950
SELECT ALL + + 58 + col1 * + col2 / + col2 AS col0 FROM tab0 AS cor0
----
144
149
155

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

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

query I rowsort
SELECT + 61 AS col2 FROM tab0 AS cor0
----
61
61
61

query I rowsort
SELECT ALL + cor0.col0 + col2 + - 20 AS col1 FROM tab0 AS cor0
----
151
16
37

query I rowsort
SELECT col1 + - col0 * 58 FROM tab0
----
-1306
-1933
-5071

query I rowsort
SELECT col0 + + ( + 28 ) * col1 FROM tab2 AS cor0
----
1730
555
875

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

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

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

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

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

query I rowsort
SELECT - + col2 * - col2 * col2 FROM tab0 cor0
----
1
35937
551368

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 col0 FROM tab2 cor0
----
-17
-31
-59

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

query I rowsort
SELECT DISTINCT + col0 + 30 FROM tab0 cor0
----
119
54
65

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

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

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

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

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

query I rowsort
SELECT + + col1 + - 67 * - col0 FROM tab0 AS cor0
----
1694
2442
6054

query I rowsort
SELECT DISTINCT 56 * + col2 AS col2 FROM tab2 AS cor0
----
1456
1512
2128

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

query I rowsort
SELECT DISTINCT + 6 + 79 * col1 FROM tab1 AS cor0
----
1033
2060
796

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

query I rowsort
SELECT - 69 AS col1 FROM tab1 cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

query I rowsort
SELECT 1 AS col1 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

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

query I rowsort
SELECT ALL 33 - col0 AS col2 FROM tab1 cor0
----
-31
-47
30

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

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

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

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

skipif mysql # not compatible
query I rowsort label-981
SELECT - col2 / - ( col1 ) AS col2 FROM tab2 AS cor0
----
0
0
2

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

query I rowsort
SELECT ALL + 76 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT + 98 * - col0 FROM tab2 AS cor0
----
-686
-7644
-7742

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 30 col2 FROM tab0, tab0 cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

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

query I rowsort
SELECT ALL - col1 * 45 FROM tab1
----
-1170
-450
-585

query I rowsort
SELECT ALL col1 * 80 + col1 AS col2 FROM tab0
----
6966
7371
7857

query I rowsort
SELECT 29 + col2 AS col2 FROM tab2 AS cor0
----
55
56
67

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

query I rowsort
SELECT ALL 84 AS col1 FROM tab2
----
84
84
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 25 * col0 * - 77 col2 FROM tab1
----
-123200
-154000
-5775

query I rowsort
SELECT ALL 39 AS col2 FROM tab1
----
39
39
39

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

query I rowsort
SELECT DISTINCT - 54 + col2 * + cor0.col0 FROM tab2 cor0
----
135
1974
2948

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

query I rowsort
SELECT + col0 * - col1 + + col0 * - col2 AS col0 FROM tab0 cor0
----
-15397
-2856
-3430

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

query I rowsort
SELECT - col1 + 66 FROM tab2
----
35
49
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * + col2 - col1 * col1 col1 FROM tab1 AS cor0
----
-3748
-7849
-838

query I rowsort
SELECT col2 + 6 FROM tab0 cor0
----
39
7
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-1002
SELECT + + cor0.col0 + + col0 DIV 14 FROM tab0 cor0
----
25
37
95

skipif mysql # not compatible
query I rowsort label-1002
SELECT + + cor0.col0 + + col0 / 14 FROM tab0 cor0
----
25
37
95

query I rowsort
SELECT DISTINCT - 68 + 70 FROM tab2, tab1, tab2 AS cor0
----
2

query I rowsort
SELECT ALL col2 * - 39 AS col2 FROM tab1
----
-2106
-2223
-3744

query I rowsort
SELECT 26 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 8b6a624eb92fb019d9664318e519f062

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1008
SELECT - 67 DIV + col1 - + col0 AS col0 FROM tab2 AS cor0
----
-79
-82
-9

skipif mysql # not compatible
query I rowsort label-1008
SELECT - 67 / + col1 - + col0 AS col0 FROM tab2 AS cor0
----
-79
-82
-9

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 64 + + col1 * col1 * + 3 col2 FROM tab0 AS cor0
----
22252
24907
28291

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

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

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

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

query I rowsort
SELECT DISTINCT + tab1.col2 * + col2 * col2 FROM tab1
----
157464
185193
884736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1018
SELECT ALL + - col2 - - CAST( 39 + + col0 AS SIGNED ) AS col1 FROM tab1 cor0
----
-12
23
46

skipif mysql # not compatible
query I rowsort label-1018
SELECT ALL + - col2 - - CAST ( 39 + + col0 AS INTEGER ) AS col1 FROM tab1 cor0
----
-12
23
46

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

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

query I rowsort
SELECT - + cor0.col0 * 25 FROM tab1 AS cor0
----
-1600
-2000
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-1021
SELECT DISTINCT col2 - + 61 DIV - 23 AS col2 FROM tab2 AS cor0
----
28
29
40

skipif mysql # not compatible
query I rowsort label-1021
SELECT DISTINCT col2 - + 61 / - 23 AS col2 FROM tab2 AS cor0
----
28
29
40

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

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

query I rowsort
SELECT + col0 - + 35 * + col1 FROM tab2 AS cor0
----
-1078
-1987
-516

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

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

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

query I rowsort
SELECT + 80 - col1 * col1 * + cor0.col1 FROM tab1 AS cor0
----
-17496
-2117
-920

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + cor0.col0 + + col1 col0 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT ALL - tab0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT DISTINCT + col1 * 99 + col0 AS col1 FROM tab0 AS cor0
----
8538
9098
9638

query I rowsort
SELECT DISTINCT + col2 * + 26 FROM tab2 AS cor0
----
676
702
988

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

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

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 I rowsort
SELECT ALL col2 * + col0 AS col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT + 24 * tab2.col1 FROM tab2
----
1416
408
744

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1042
SELECT + + cor0.col2 * col1 * + CAST( + 30 AS SIGNED ) FROM tab1 AS cor0
----
17100
37440
42120

skipif mysql # not compatible
query I rowsort label-1042
SELECT + + cor0.col2 * col1 * + CAST ( + 30 AS INTEGER ) FROM tab1 AS cor0
----
17100
37440
42120

query I rowsort
SELECT 48 * col2 FROM tab1 AS cor0
----
2592
2736
4608

query I rowsort
SELECT DISTINCT + 70 * col2 AS col0 FROM tab0 AS cor0
----
2310
5740
70

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

query I rowsort
SELECT - col0 * + 12 * col0 AS col2 FROM tab2 AS cor0
----
-588
-73008
-74892

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

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

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

skipif mysql # not compatible
query I rowsort label-1048
SELECT DISTINCT + + col2 + + col0 + + 19 / col1 FROM tab1 AS cor0
----
122
177
57

query I rowsort
SELECT DISTINCT col1 - - ( + col2 ) * col0 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT + col0 * - 1 * - 72 AS col2 FROM tab2 AS cor0
----
504
5616
5688

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

query I rowsort
SELECT 31 * col0 + - col1 * tab2.col1 FROM tab2
----
-1063
-744
2160

query I rowsort
SELECT DISTINCT col1 * tab0.col2 * - 6 + 93 FROM tab0
----
-16935
-44679
-489

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

query I rowsort
SELECT ALL col0 + tab1.col2 * 70 * - col2 AS col1 FROM tab1
----
-204117
-227366
-645040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * 14 + cor0.col0 + cor0.col0 col2 FROM tab2 AS cor0
----
-208
-364
-374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + cor0.col0 * 61 col1 FROM tab0 AS cor0
----
1378
2038
5338

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1058
SELECT + + col2 + - CAST( 33 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
21
24
63

skipif mysql # not compatible
query I rowsort label-1058
SELECT + + col2 + - CAST ( 33 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
21
24
63

query I rowsort
SELECT DISTINCT 52 * - ( + cor0.col2 ) FROM tab1, tab1 AS cor0
----
-2808
-2964
-4992

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

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

query I rowsort
SELECT - - col0 * + ( + col2 + + col1 ) FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT - ( - 32 ) * - col1 FROM tab0 AS cor0
----
-2752
-2912
-3104

query I rowsort
SELECT - ( col0 ) + - col2 * ( - 10 ) AS col2 FROM tab1 AS cor0
----
506
537
880

query I rowsort
SELECT - col0 + 44 AS col1 FROM tab1 AS cor0
----
-20
-36
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 21 ) * col2 col1 FROM tab0 AS cor0
----
1722
21
693

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 97 * col0 col0 FROM tab1
----
397312
620800
873

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

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

query I rowsort
SELECT + 13 * + col1 * 18 + + col1 * col2 FROM tab0 AS cor0
----
22795
22962
28756

query I rowsort
SELECT ALL - col1 + - col2 + col2 * - col2 * col0 AS col0 FROM tab1
----
-208003
-737389
-8828

query I rowsort
SELECT 86 * 3 AS col1 FROM tab2
----
258
258
258

query I rowsort
SELECT DISTINCT + col1 * col1 + - col2 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT - ( + col2 ) + col2 * - col1 FROM tab0 AS cor0
----
-2871
-7544
-98

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

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

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

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

query I rowsort
SELECT ( - col2 ) AS col0 FROM tab2
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1080
SELECT - 11 DIV - col0 AS col2 FROM tab1
----
0
0
3

skipif mysql # not compatible
query I rowsort label-1080
SELECT - 11 / - col0 AS col2 FROM tab1
----
0
0
3

query I rowsort
SELECT DISTINCT 21 + + col1 FROM tab0
----
107
112
118

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1083
SELECT ALL - 73 + col1 DIV col0 FROM tab0 AS cor0
----
-70
-71
-72

skipif mysql # not compatible
query I rowsort label-1083
SELECT ALL - 73 + col1 / col0 FROM tab0 AS cor0
----
-70
-71
-72

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

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

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

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

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1093
SELECT 76 + 38 DIV col2 AS col2 FROM tab1
----
76
76
76

skipif mysql # not compatible
query I rowsort label-1093
SELECT 76 + 38 / col2 AS col2 FROM tab1
----
76
76
76

query I rowsort
SELECT + - 86 + - col2 AS col2 FROM tab1 AS cor0
----
-140
-143
-182

query I rowsort
SELECT 20 * cor0.col0 AS col1 FROM tab1 AS cor0
----
1280
1600
60

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

query I rowsort
SELECT ALL col2 + + col2 * - 64 + - col1 FROM tab0 AS cor0
----
-160
-2165
-5257

query I rowsort
SELECT DISTINCT + - col1 * - col2 * + 82 - cor0.col1 AS col2 FROM tab1 AS cor0
----
102323
115102
46730

query I rowsort
SELECT DISTINCT - 16 * 34 AS col1 FROM tab1
----
-544

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * col2 + + 42 col2 FROM tab2 AS cor0
----
1576
688
879

query I rowsort
SELECT - + col1 * + cor0.col0 * + col0 + + col1 - ( - col2 ) * + col0 AS col0 FROM tab1 cor0
----
-37302
-46
-75507

query I rowsort
SELECT - + col1 * + cor0.col2 + - 7 * col1 AS col2 FROM tab1 AS cor0
----
-1339
-1586
-640

query I rowsort
SELECT + col0 * cor0.col0 + col0 - col1 AS col1 FROM tab1 AS cor0
----
-14
4150
6467

onlyif mysql # use DIV operator for integer division
query I rowsort label-1105
SELECT col0 + + ( + col0 ) DIV - col2 - + CAST( - 85 AS SIGNED ) * + cor0.col0 FROM tab0 AS cor0
----
2064
2975
7653

skipif mysql # not compatible
query I rowsort label-1105
SELECT col0 + + ( + col0 ) / - col2 - + CAST ( - 85 AS INTEGER ) * + cor0.col0 FROM tab0 AS cor0
----
2064
2975
7653

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

query I rowsort
SELECT + - col2 + col0 * 15 FROM tab1 AS cor0
----
-9
1104
903

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

query I rowsort
SELECT col1 * + 97 + col2 AS col2 FROM tab1 cor0
----
1027
1357
2576

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

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

query I rowsort
SELECT - cor0.col1 * - 85 + - cor0.col0 * + 9 AS col0 FROM tab1 cor0
----
2183
274
385

query I rowsort
SELECT ALL + col1 * col0 * col0 + col0 * + 72 * - col1 AS col2 FROM tab0 AS cor0
----
-125615
-99072
137683

query I rowsort
SELECT + 34 AS col0 FROM tab2 cor0
----
34
34
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + 19 col1 FROM tab2 AS cor0
----
26
97
98

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

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

skipif mysql # not compatible
query I rowsort label-1117
SELECT CAST ( col1 AS INTEGER ) + + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

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

query I rowsort
SELECT ( col1 ) * + col2 + 28 FROM tab0 cor0
----
125
2866
7490

query I rowsort
SELECT ALL col2 + + 8 FROM tab2 AS cor0
----
34
35
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1121
SELECT DISTINCT - CAST( col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-1121
SELECT DISTINCT - CAST ( col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

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

skipif mysql # not compatible
query I rowsort label-1122
SELECT - 58 + + col0 / + cor0.col2 AS col2 FROM tab1 AS cor0
----
-57
-58
-58

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

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

query I rowsort
SELECT ALL + 85 * col2 + cor0.col2 * 12 AS col0 FROM tab2 AS cor0
----
2522
2619
3686

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

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

query I rowsort
SELECT 5 * 45 AS col1 FROM tab1
----
225
225
225

query I rowsort
SELECT - ( - 58 ) + - col0 FROM tab1 cor0
----
-22
-6
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-1129
SELECT 12 - - col2 DIV - tab1.col2 AS col0 FROM tab1
----
11
11
11

skipif mysql # not compatible
query I rowsort label-1129
SELECT 12 - - col2 / - tab1.col2 AS col0 FROM tab1
----
11
11
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-1130
SELECT ALL col0 DIV + tab0.col0 + col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-1130
SELECT ALL col0 / + tab0.col0 + col0 FROM tab0
----
25
36
90

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1132
SELECT ALL - col2 DIV col1 + - 87 FROM tab1 AS cor0
----
-89
-92
-94

skipif mysql # not compatible
query I rowsort label-1132
SELECT ALL - col2 / col1 + - 87 FROM tab1 AS cor0
----
-89
-92
-94

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

query I rowsort
SELECT DISTINCT - col2 + 77 * col0 FROM tab0 AS cor0
----
1815
2694
6771

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

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0, tab1 AS cor0, tab0 cor1
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

query I rowsort
SELECT + col2 * 50 FROM tab0 AS cor0
----
1650
4100
50

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

query I rowsort
SELECT DISTINCT - 62 - col1 FROM tab0 cor0
----
-148
-153
-159

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

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

skipif mysql # not compatible
query I rowsort label-1141
SELECT ALL - + 7 * col2 - - CAST ( col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-123
-158
-249

query I rowsort
SELECT ALL 59 * + cor0.col2 FROM tab0 cor0
----
1947
4838
59

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1144
SELECT DISTINCT + 77 DIV + 80 + col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1144
SELECT DISTINCT + 77 / + 80 + col2 FROM tab0
----
1
33
82

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1149
SELECT DISTINCT + + 26 + col0 DIV + ( + col2 ) AS col1 FROM tab0 AS cor0
----
26
27
61

skipif mysql # not compatible
query I rowsort label-1149
SELECT DISTINCT + + 26 + col0 / + ( + col2 ) AS col1 FROM tab0 AS cor0
----
26
27
61

query I rowsort
SELECT ALL + 38 + col2 AS col1 FROM tab1 cor0
----
134
92
95

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

query I rowsort
SELECT DISTINCT + - col0 * col0 + ( - ( col0 ) ) AS col1 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT + col1 * + 27 * + tab1.col0 AS col2 FROM tab1
----
17280
2106
28080

onlyif mysql # use DIV operator for integer division
query I rowsort label-1154
SELECT ALL + col0 + + 87 DIV col2 FROM tab1
----
4
65
80

skipif mysql # not compatible
query I rowsort label-1154
SELECT ALL + col0 + + 87 / col2 FROM tab1
----
4
65
80

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - ( + 76 ) * col2 * - col0 col0 FROM tab2
----
14333
154069
228135

query I rowsort
SELECT DISTINCT tab0.col0 + 34 FROM tab0
----
123
58
69

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1161
SELECT DISTINCT col2 + - col2 DIV tab2.col0 AS col0 FROM tab2
----
24
26
38

skipif mysql # not compatible
query I rowsort label-1161
SELECT DISTINCT col2 + - col2 / tab2.col0 AS col0 FROM tab2
----
24
26
38

query I rowsort
SELECT DISTINCT col1 * - col1 * tab2.col2 + - col1 * ( - col0 ) FROM tab2
----
-25730
-85904
-9639

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

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

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

query I rowsort
SELECT ALL 48 * col0 FROM tab1 AS cor0
----
144
3072
3840

query I rowsort
SELECT ALL col1 * + cor0.col1 + + col2 * - 27 * col0 AS col2 FROM tab1 AS cor0
----
-207191
-3698
-98396

query I rowsort
SELECT DISTINCT - ( col1 ) + col2 * col2 * col0 AS col0 FROM tab2 AS cor0
----
114059
5072
52669

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

query I rowsort
SELECT DISTINCT + ( 57 ) * cor0.col1 AS col1 FROM tab2 AS cor0
----
1767
3363
969

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL + - 66 * col2 + - col0 AS col0 FROM tab1 cor0
----
-3567
-3826
-6416

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

query I rowsort
SELECT ALL cor0.col2 * + 26 + col2 + - col1 AS col0 FROM tab2 AS cor0
----
1009
643
698

query I rowsort
SELECT - 79 * + 11 AS col1 FROM tab1 AS cor0
----
-869
-869
-869

onlyif mysql # use DIV operator for integer division
query I rowsort label-1181
SELECT 62 DIV + col1 + col2 AS col1 FROM tab2 AS cor0
----
27
29
41

skipif mysql # not compatible
query I rowsort label-1181
SELECT 62 / + col1 + col2 AS col1 FROM tab2 AS cor0
----
27
29
41

query I rowsort
SELECT 17 + - 2 * + col0 AS col0 FROM tab1 AS cor0
----
-111
-143
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * col2 - - col0 col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL ( + 45 ) * - col0 FROM tab2
----
-315
-3510
-3555

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

query I rowsort
SELECT ALL 80 FROM tab2, tab2 cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT ALL ( 83 ) AS col2 FROM tab1
----
83
83
83

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

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

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

query I rowsort
SELECT 77 + - col1 FROM tab0 cor0
----
-14
-20
-9

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

skipif mysql # not compatible
query I rowsort label-1191
SELECT DISTINCT - col2 / 43 AS col2 FROM tab1 AS cor0
----
-1
-2

query I rowsort
SELECT DISTINCT ( 54 ) FROM tab2 cor0
----
54

query I rowsort
SELECT - 47 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
10
49
7

query I rowsort
SELECT + + 75 * + col0 FROM tab0 AS cor0
----
1800
2625
6675

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 51 * col1 + col2 col0 FROM tab2
----
1608
3035
905

query I rowsort
SELECT ( - col2 ) + col0 * + tab1.col0 FROM tab1
----
-45
4039
6304

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

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

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

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

query I rowsort
SELECT + col1 + 62 * - col1 AS col2 FROM tab0 AS cor0
----
-5246
-5551
-5917

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

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

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

query I rowsort
SELECT ALL + col1 + 48 * + 72 FROM tab2 AS cor0
----
3473
3487
3515

query I rowsort
SELECT + - col1 * + ( - 40 ) AS col2 FROM tab2 cor0
----
1240
2360
680

query I rowsort
SELECT 96 + - col0 FROM tab2
----
17
18
89

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1209
SELECT + + col2 + CAST( 77 AS SIGNED ) * + cor0.col1 AS col2 FROM tab2 AS cor0
----
1347
2414
4569

skipif mysql # not compatible
query I rowsort label-1209
SELECT + + col2 + CAST ( 77 AS INTEGER ) * + cor0.col1 AS col2 FROM tab2 AS cor0
----
1347
2414
4569

onlyif mysql # use DIV operator for integer division
query I rowsort label-1210
SELECT - + col0 + - col1 DIV col1 col0 FROM tab0 cor0
----
-25
-36
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1210
SELECT - + col0 + - col1 / col1 col0 FROM tab0 cor0
----
-25
-36
-90

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

query I rowsort
SELECT + 98 + col2 FROM tab2 AS cor0
----
124
125
136

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

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

query I rowsort
SELECT DISTINCT - col2 + - ( - 53 ) * - col1 AS col0 FROM tab0 AS cor0
----
-4591
-4905
-5142

query I rowsort
SELECT ALL + 41 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

onlyif mysql # use DIV operator for integer division
query I rowsort label-1217
SELECT ALL + col1 DIV 69 + 16 + tab2.col2 * - col0 FROM tab2
----
-173
-2012
-2986

skipif mysql # not compatible
query I rowsort label-1217
SELECT ALL + col1 / 69 + 16 + tab2.col2 * - col0 FROM tab2
----
-173
-2012
-2986

query I rowsort
SELECT DISTINCT + 41 * col2 AS col0 FROM tab0
----
1353
3362
41

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

query I rowsort
SELECT 45 * tab0.col1 FROM tab0
----
3870
4095
4365

query I rowsort
SELECT ALL - col1 + 97 AS col2 FROM tab1 AS cor0
----
71
84
87

query I rowsort
SELECT ALL col0 + col1 * 57 FROM tab2 AS cor0
----
1048
1774
3441

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

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

query I rowsort
SELECT - tab0.col1 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT - 96 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 cor1
----
-96

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

query I rowsort
SELECT - col1 * ( + col0 ) + + col2 * + col2 AS col1 FROM tab2 cor0
----
-3926
101
512

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

query I rowsort
SELECT + col1 * col0 + 4 FROM tab0 AS cor0
----
2068
3399
8103

query I rowsort
SELECT DISTINCT 69 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 51 * col0 col0 FROM tab1
----
-153
-3264
-4080

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

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

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

query I rowsort
SELECT + 82 * - col2 - col2 FROM tab1 cor0
----
-4482
-4731
-7968

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col1 - col1 col2 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT - 91 + col2 FROM tab2 cor0
----
-53
-64
-65

query I rowsort
SELECT ALL 79 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT DISTINCT 76 AS col0 FROM tab1, tab1 AS cor0
----
76

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

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

query I rowsort
SELECT DISTINCT 47 * - col2 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
133386
350714
4559

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

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

query I rowsort
SELECT DISTINCT - 52 AS col1 FROM tab1 AS cor0
----
-52

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

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

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

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

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

query I rowsort
SELECT + tab1.col1 * col1 AS col1 FROM tab1
----
100
169
676

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( tab2.col1 ) * - col2 * col1 col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT 87 * + col1 FROM tab1
----
1131
2262
870

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

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

query I rowsort
SELECT DISTINCT - 28 AS col2 FROM tab0, tab2 AS cor0
----
-28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 20 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

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

skipif mysql # not compatible
query I rowsort label-1258
SELECT + + ( 14 ) / col2 AS col0 FROM tab1 AS cor0
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-1259
SELECT - 70 + 95 + + col1 * - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * 49 col1 FROM tab2
----
343
3822
3871

query I rowsort
SELECT ALL 40 * col0 + - col1 FROM tab0 cor0
----
1303
3469
874

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1263
SELECT - 15 DIV 85 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1263
SELECT - 15 / 85 AS col2 FROM tab0 AS cor0
----
0
0
0

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

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

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

skipif mysql # not compatible
query I rowsort label-1266
SELECT tab0.col0 + - col0 / + col1 FROM tab0
----
24
35
89

query I rowsort
SELECT + 17 - + col0 AS col0 FROM tab0
----
-18
-7
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-1268
SELECT ( - col1 ) DIV tab1.col2 - col1 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-1268
SELECT ( - col1 ) / tab1.col2 - col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT - 61 + - col2 FROM tab0
----
-143
-62
-94

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1273
SELECT + col0 * cor0.col2 DIV - col1 AS col1 FROM tab1 AS cor0
----
-364
-590
-6

skipif mysql # not compatible
query I rowsort label-1273
SELECT + col0 * cor0.col2 / - col1 AS col1 FROM tab1 AS cor0
----
-364
-590
-6

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

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

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

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

query I rowsort
SELECT ALL col1 - 67 FROM tab1 AS cor0
----
-41
-54
-57

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - 88 ) * + col2 col1 FROM tab1 AS cor0
----
-4752
-5016
-8448

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 + col2 col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT - 77 * col2 AS col2 FROM tab0 AS cor0
----
-2541
-6314
-77

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

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

query I rowsort
SELECT 6 * + col1 FROM tab1 AS cor0
----
156
60
78

query I rowsort
SELECT ALL 31 * col2 AS col2 FROM tab0 AS cor0
----
1023
2542
31

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

skipif mysql # not compatible
query I rowsort label-1286
SELECT DISTINCT 69 + col1 / - col2 AS col1 FROM tab1 AS cor0
----
69

query I rowsort
SELECT cor0.col1 + - 53 AS col0 FROM tab1 AS cor0
----
-27
-40
-43

query I rowsort
SELECT DISTINCT - - col2 * col1 * + col2 FROM tab0 AS cor0
----
611884
93654
97

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1293
SELECT ( + col2 ) * - CAST ( + col1 * col0 AS INTEGER ) FROM tab2 AS cor0
----
-119652
-51034
-5859

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

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

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

query I rowsort
SELECT DISTINCT + col0 * ( 73 ) AS col1 FROM tab1 AS cor0
----
219
4672
5840

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1301
SELECT - 67 * + col1 + + 49 DIV + col1 FROM tab0
----
-5762
-6097
-6499

skipif mysql # not compatible
query I rowsort label-1301
SELECT - 67 * + col1 + + 49 / + col1 FROM tab0
----
-5762
-6097
-6499

query I rowsort
SELECT col2 * + 15 FROM tab1
----
1440
810
855

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

skipif mysql # not compatible
query I rowsort label-1303
SELECT tab1.col2 / + 49 FROM tab1
----
1
1
1

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

query I rowsort
SELECT ALL tab1.col1 + + col0 + col1 FROM tab1
----
106
55
84

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

query I rowsort
SELECT ALL col0 * col2 * + col0 + col0 + ( - col2 ) AS col0 FROM tab2
----
1303
158236
237199

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

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

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

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

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

query I rowsort
SELECT DISTINCT + + col1 + col1 * 92 AS col2 FROM tab1 AS cor0
----
1209
2418
930

query I rowsort
SELECT DISTINCT + col1 + - 67 * col2 FROM tab2
----
-1683
-1778
-2529

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

query I rowsort
SELECT + col1 * + 95 AS col0 FROM tab0
----
8170
8645
9215

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0, tab2, tab1 AS cor1
----
972 values hashing to 980274175fafec015a83080672486a9a

query I rowsort
SELECT - tab1.col1 * + 59 FROM tab1, tab0 AS cor0
----
9 values hashing to 45e711e5ea001a4b37a1982ea9658743

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

query I rowsort
SELECT ALL - 56 + - 1 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - 98 AS REAL ) AS col2 FROM tab0
----
-98
-98
-98

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

skipif mysql # not compatible
query I rowsort label-1323
SELECT col1 / 73 FROM tab1 AS cor0
----
0
0
0

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col0 * 91 col2 FROM tab1
----
58240
7098
94640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 74 + + col2 * + col1 + cor0.col1 * + col1 col0 FROM tab2 AS cor0
----
1724
4941
861

onlyif mysql # use DIV operator for integer division
query I rowsort label-1328
SELECT ALL 99 DIV 37 + - cor1.col1 DIV + 81 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

skipif mysql # not compatible
query I rowsort label-1328
SELECT ALL 99 / 37 + - cor1.col1 / + 81 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1334
SELECT DISTINCT + + cor0.col2 DIV col2 + cor0.col0 * - col2 FROM tab1 AS cor0
----
-161
-3647
-7679

skipif mysql # not compatible
query I rowsort label-1334
SELECT DISTINCT + + cor0.col2 / col2 + cor0.col0 * - col2 FROM tab1 AS cor0
----
-161
-3647
-7679

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

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

query I rowsort
SELECT DISTINCT + col2 * + ( - cor0.col2 ) - cor0.col0 AS col0 FROM tab2 AS cor0
----
-1523
-736
-754

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

skipif mysql # not compatible
query I rowsort label-1338
SELECT DISTINCT + col0 + CAST ( col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
14
156
158

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

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

skipif mysql # not compatible
query I rowsort
SELECT + 11 / tab0.col2 + CAST ( - 2 AS REAL ) FROM tab0
----
-2
-2
9

query I rowsort
SELECT DISTINCT + 12 AS col1 FROM tab0
----
12

query I rowsort
SELECT + col0 + 39 FROM tab1 cor0
----
103
119
42

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

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

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

query I rowsort
SELECT ALL - 1 FROM tab2, tab2 cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT ALL - cor0.col2 + + 53 FROM tab2 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 832508383e43c0c56f24341cf9f23f78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + 93 col2 FROM tab0
----
-2232
-3255
-8277

query I rowsort
SELECT + cor1.col2 + - ( - cor0.col1 ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ed0f18675169071c56b762ebcebeac71

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

skipif mysql # not compatible
query I rowsort label-1351
SELECT + ( + col2 ) + CAST ( + col0 AS INTEGER ) * col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL + 52 AS col0 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT DISTINCT + 45 * + col1 AS col2 FROM tab0
----
3870
4095
4365

onlyif mysql # use DIV operator for integer division
query I rowsort label-1354
SELECT ALL col1 * col0 DIV col2 FROM tab1
----
1
10
11

skipif mysql # not compatible
query I rowsort label-1354
SELECT ALL col1 * col0 / col2 FROM tab1
----
1
10
11

query I rowsort
SELECT DISTINCT + col0 * 37 FROM tab1 AS cor0
----
111
2368
2960

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

query I rowsort
SELECT cor0.col1 + - 69 * 4 AS col0 FROM tab0 AS cor0
----
-179
-185
-190

query I rowsort
SELECT DISTINCT - col0 + + 74 * - col0 * - col1 AS col2 FROM tab2 cor0
----
16051
340470
99303

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1361
SELECT + ( + col0 ) * CAST( - ( - tab2.col0 ) AS SIGNED ) + + col1 + + ( col0 ) AS col0 FROM tab2
----
6221
6337
87

skipif mysql # not compatible
query I rowsort label-1361
SELECT + ( + col0 ) * CAST ( - ( - tab2.col0 ) AS INTEGER ) + + col1 + + ( col0 ) AS col0 FROM tab2
----
6221
6337
87

query I rowsort
SELECT ALL ( col2 ) - 47 FROM tab1
----
10
49
7

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

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

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

query I rowsort
SELECT 32 FROM tab0, tab1 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT ALL + 83 AS col0 FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
81 values hashing to 5ced3720d5aeff0dd77d5059a38001b6

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

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

query I rowsort
SELECT + + ( + 73 ) * cor0.col0 FROM tab1 AS cor0
----
219
4672
5840

query I rowsort
SELECT - + 93 FROM tab2 AS cor0
----
-93
-93
-93

query I rowsort
SELECT + + 13 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

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

query I rowsort
SELECT DISTINCT ( 85 + + col2 ) * ( col0 ) FROM tab2
----
784
8658
9717

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

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

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

query I rowsort
SELECT - 31 FROM tab1, tab0, tab0 cor0
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

query I rowsort
SELECT - 65 FROM tab0
----
-65
-65
-65

query I rowsort
SELECT + col2 + + 98 AS col2 FROM tab2 AS cor0
----
124
125
136

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

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

query I rowsort
SELECT ALL + 44 + - col2 AS col2 FROM tab1 AS cor0
----
-10
-13
-52

query I rowsort
SELECT DISTINCT - - col0 * col2 - col1 * col1 * col1 AS col0 FROM tab2 cor0
----
-1911
-203351
-29602

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

query I rowsort
SELECT ALL col2 + + cor0.col1 + ( 94 ) * + col1 FROM tab0 cor0
----
8203
8727
9216

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 ALL + 14 * + cor0.col2 FROM tab0 AS cor0
----
1148
14
462

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

query I rowsort
SELECT + 11 * cor0.col1 AS col0 FROM tab0 AS cor0
----
1001
1067
946

query I rowsort
SELECT ALL - - ( col0 ) + 93 AS col2 FROM tab1 AS cor0
----
157
173
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1389
SELECT ALL col2 + col1 DIV col2 AS col0 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-1389
SELECT ALL col2 + col1 / col2 AS col0 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT - 19 + + col0 * - cor0.col1 FROM tab1 AS cor0
----
-1059
-659
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1391
SELECT DISTINCT + col0 + col1 DIV + CAST( - col0 + col1 * CAST( + col1 AS SIGNED ) AS SIGNED ) FROM tab1 AS cor0
----
3
64
80

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

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

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

query I rowsort
SELECT - - col2 + 15 * ( col2 + col0 * 59 ) AS col0 FROM tab1 cor0
----
3519
57552
72336

query I rowsort
SELECT ALL - col0 * + 39 * + 2 AS col1 FROM tab1 AS cor0
----
-234
-4992
-6240

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + cor0.col0 * + CAST ( col0 AS REAL ) FROM tab2 AS cor0
----
49
6084
6241

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

query I rowsort
SELECT + 41 * + col1 + col0 * cor0.col2 FROM tab1 cor0
----
1228
4058
8213

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

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

query I rowsort
SELECT DISTINCT + + col0 + + 48 * col0 AS col0 FROM tab1 AS cor0
----
147
3136
3920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - ( col2 * + ( 26 ) ) col0 FROM tab1 AS cor0
----
-1401
-1418
-2416

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( + 88 AS REAL ) * + cor0.col0 + CAST ( - col2 * col0 AS REAL ) AS col2 FROM tab0 AS cor0
----
-15130
-2904
-3115

query I rowsort
SELECT ALL + ( col1 ) * - tab2.col1 + col2 + col0 AS col1 FROM tab2
----
-172
-3377
-927

query I rowsort
SELECT ALL + + col2 + + col0 * ( + 41 ) AS col0 FROM tab0 AS cor0
----
1017
1436
3731

query I rowsort
SELECT DISTINCT + 90 * - tab1.col1 * - col0 + col2 * col2 + 35 * + 11 AS col1 FROM tab1
----
103201
10321
61234

query I rowsort
SELECT col0 * - col2 + col1 + tab1.col1 AS col1 FROM tab1
----
-110
-3628
-7654

query I rowsort
SELECT DISTINCT - 35 + - col0 * col1 FROM tab2 AS cor0
----
-1378
-252
-4637

query I rowsort
SELECT - col2 * col1 + col2 * 43 FROM tab1 AS cor0
----
1881
2880
918

query I rowsort
SELECT ALL - 78 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-6708
-7098
-7566

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

query I rowsort
SELECT DISTINCT + + 72 + + col1 FROM tab1 AS cor0
----
82
85
98

query I rowsort
SELECT + col2 * + col0 * + 20 AS col2 FROM tab1 AS cor0
----
153600
3240
72960

query I rowsort
SELECT DISTINCT col0 - - col0 AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL 69 * + col1 * cor0.col0 AS col0 FROM tab1 cor0
----
44160
5382
71760

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1418
SELECT - + col0 DIV - col1 + + col2 * 94 AS col2 FROM tab1 AS cor0
----
5076
5364
9030

skipif mysql # not compatible
query I rowsort label-1418
SELECT - + col0 / - col1 + + col2 * 94 AS col2 FROM tab1 AS cor0
----
5076
5364
9030

onlyif mysql # use DIV operator for integer division
query I rowsort label-1419
SELECT + - 25 - col0 * col2 DIV col0 FROM tab0 AS cor0
----
-107
-26
-58

skipif mysql # not compatible
query I rowsort label-1419
SELECT + - 25 - col0 * col2 / col0 FROM tab0 AS cor0
----
-107
-26
-58

query I rowsort
SELECT DISTINCT - 74 - + col1 AS col0 FROM tab1 AS cor0
----
-100
-84
-87

query I rowsort
SELECT DISTINCT + col1 * 66 AS col1 FROM tab1 AS cor0
----
1716
660
858

query I rowsort
SELECT 88 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

onlyif mysql # use DIV operator for integer division
query I rowsort label-1423
SELECT DISTINCT - 82 DIV 6 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-13

skipif mysql # not compatible
query I rowsort label-1423
SELECT DISTINCT - 82 / 6 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-13

query I rowsort
SELECT - 84 AS col0 FROM tab0, tab1 cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 6793fb74ae172572ffea747b0673b07a

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

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

query I rowsort
SELECT ALL - + ( - 41 ) FROM tab2 AS cor0
----
41
41
41

query I rowsort
SELECT DISTINCT + - ( + col0 ) + cor0.col0 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + - 30 * + ( col2 ) FROM tab1 AS cor0
----
-1620
-1710
-2880

query I rowsort
SELECT ALL - 97 FROM tab1, tab2 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 + col1 col0 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-1431
SELECT DISTINCT + + col0 DIV ( + col1 ) AS col0 FROM tab1 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-1431
SELECT DISTINCT + + col0 / ( + col1 ) AS col0 FROM tab1 AS cor0
----
0
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1432
SELECT ALL + - CAST( NULL AS SIGNED ) * 71 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1432
SELECT ALL + - CAST ( NULL AS INTEGER ) * 71 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 45 * - ( + col2 ) FROM tab0 AS cor0
----
-1485
-3690
-45

query I rowsort
SELECT DISTINCT - + col2 * col1 + + cor0.col2 * - col1 FROM tab1 AS cor0
----
-1140
-2496
-2808

query I rowsort
SELECT ALL + - ( + col0 ) * - col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - 99 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 64d06513850a26495bc6c2fddeb254b7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col2 + - 63 col0 FROM tab2
----
-101
-89
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1438
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2
----
NULL

skipif mysql # not compatible
query I rowsort label-1438
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2
----
NULL

query I rowsort
SELECT ( 18 ) * col1 FROM tab1 AS cor0
----
180
234
468

query I rowsort
SELECT DISTINCT + ( col0 ) * col2 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1441
SELECT + CAST( NULL AS SIGNED ) / 63 FROM tab2, tab2 AS cor0, tab2 cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-1441
SELECT + CAST ( NULL AS INTEGER ) / 63 FROM tab2, tab2 AS cor0, tab2 cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT DISTINCT cor0.col2 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col0 * + col1 col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + cor0.col2 FROM tab2, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT - col0 + 68 FROM tab0
----
-21
33
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - + col0 col0 FROM tab2
----
0
0
0

query I rowsort
SELECT + - cor0.col1 * cor0.col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 17 AS col0 FROM tab1
----
17
17
17

query I rowsort
SELECT DISTINCT ( - col1 ) * col2 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - 56 * col2 + + cor0.col2 FROM tab2 AS cor0
----
-1430
-1485
-2090

query I rowsort
SELECT DISTINCT 97 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
97

query I rowsort
SELECT DISTINCT - col2 * col2 + + ( 36 * - col2 ) FROM tab0 AS cor0
----
-2277
-37
-9676

onlyif mysql # use DIV operator for integer division
query I rowsort label-1453
SELECT DISTINCT - tab1.col1 DIV col2 col0 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1453
SELECT DISTINCT - tab1.col1 / col2 col0 FROM tab1
----
0

query I rowsort
SELECT DISTINCT col1 * + ( - 74 ) + col2 FROM tab1
----
-1870
-683
-866

query I rowsort
SELECT col1 * ( + 55 ) AS col1 FROM tab0
----
4730
5005
5335

query I rowsort
SELECT + col1 + 43 AS col1 FROM tab2
----
102
60
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1457
SELECT - CAST( col2 AS SIGNED ) + col2 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1457
SELECT - CAST ( col2 AS INTEGER ) + col2 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1458
SELECT col1 DIV col2 + col1 DIV + tab0.col2 FROM tab0
----
194
2
4

skipif mysql # not compatible
query I rowsort label-1458
SELECT col1 / col2 + col1 / + tab0.col2 FROM tab0
----
194
2
4

query I rowsort
SELECT - ( cor0.col0 ) FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT DISTINCT - - col1 * 55 + + col0 * + col0 FROM tab0 AS cor0
----
12926
5306
6560

query I rowsort
SELECT 63 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT col0 * + 56 FROM tab0
----
1344
1960
4984

query I rowsort
SELECT ALL - - cor0.col0 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-1464
SELECT DISTINCT 88 * col1 - - col0 DIV + 37 FROM tab0 AS cor0
----
7568
8010
8536

skipif mysql # not compatible
query I rowsort label-1464
SELECT DISTINCT 88 * col1 - - col0 / + 37 FROM tab0 AS cor0
----
7568
8010
8536

onlyif mysql # use DIV operator for integer division
query I rowsort label-1465
SELECT DISTINCT - - 52 * col1 DIV col1 AS col2 FROM tab0 AS cor0
----
52

skipif mysql # not compatible
query I rowsort label-1465
SELECT DISTINCT - - 52 * col1 / col1 AS col2 FROM tab0 AS cor0
----
52

query I rowsort
SELECT - col1 * + 22 AS col1 FROM tab2 AS cor0
----
-1298
-374
-682

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1467
SELECT ALL + col0 * ( - col2 ) + CAST( 32 AS SIGNED ) FROM tab2 AS cor0
----
-157
-1996
-2970

skipif mysql # not compatible
query I rowsort label-1467
SELECT ALL + col0 * ( - col2 ) + CAST ( 32 AS INTEGER ) FROM tab2 AS cor0
----
-157
-1996
-2970

query I rowsort
SELECT DISTINCT - ( 74 ) + + col0 FROM tab2 AS cor0
----
-67
4
5

query I rowsort
SELECT DISTINCT col0 * - col0 * col0 + - col0 FROM tab0 cor0
----
-13848
-42910
-705058

query I rowsort
SELECT - + col0 * 38 + col1 FROM tab2 cor0
----
-235
-2905
-2985

query I rowsort
SELECT ALL - col2 * ( - col1 ) AS col1 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - + 42 col2 FROM tab2
----
-101
-59
-73

query I rowsort
SELECT DISTINCT 32 AS col0 FROM tab0, tab0 AS cor0
----
32

query I rowsort
SELECT + col0 + + col2 * - col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT + col1 + cor0.col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - + col1 + + col2 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT + ( + 94 ) FROM tab2 cor0
----
94

query I rowsort
SELECT ALL - 76 * cor0.col1 + col2 AS col1 FROM tab2 AS cor0
----
-1254
-2329
-4458

query I rowsort
SELECT + 7 * col0 AS col2 FROM tab1 AS cor0
----
21
448
560

query I rowsort
SELECT DISTINCT + + col1 * + 82 + col2 AS col1 FROM tab2 AS cor0
----
1432
2569
4864

query I rowsort
SELECT col1 * - ( + col1 ) * ( + col1 ) FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT ALL tab0.col0 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT 6 + col2 FROM tab2 AS cor0
----
32
33
44

query I rowsort
SELECT - 48 + col2 FROM tab1 AS cor0
----
48
6
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1485
SELECT - col1 + col2 * CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
-132
-7389
-878

skipif mysql # not compatible
query I rowsort label-1485
SELECT - col1 + col2 * CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT - col1 * + col1 + + 71 FROM tab0 AS cor0
----
-7325
-8210
-9338

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1487
SELECT - CAST( + col1 * col0 AS SIGNED ) AS col2 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-1487
SELECT - CAST ( + col1 * col0 AS INTEGER ) AS col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col0 * - tab2.col2 * - col0 AS col1 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT DISTINCT cor0.col1 + + tab2.col2 AS col1 FROM tab2, tab1, tab0 AS cor0
----
112
113
117
118
123
124
129
135

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1490
SELECT DISTINCT CAST( + 89 AS SIGNED ) AS col2 FROM tab2
----
89

skipif mysql # not compatible
query I rowsort label-1490
SELECT DISTINCT CAST ( + 89 AS INTEGER ) AS col2 FROM tab2
----
89

query I rowsort
SELECT + 46 * cor0.col1 + - col0 + 22 AS col0 FROM tab1 AS cor0
----
1215
418
540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 * + col0 col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT - - col0 * col1 + 60 FROM tab0 cor0
----
2124
3455
8159

query I rowsort
SELECT DISTINCT - + col2 + 81 * - col1 FROM tab1 AS cor0
----
-1149
-2160
-867

onlyif mysql # use DIV operator for integer division
query I rowsort label-1495
SELECT - cor0.col1 DIV col0 + ( + col2 ) * - 58 + 61 FROM tab2 AS cor0
----
-1447
-1509
-2143

skipif mysql # not compatible
query I rowsort label-1495
SELECT - cor0.col1 / col0 + ( + col2 ) * - 58 + 61 FROM tab2 AS cor0
----
-1447
-1509
-2143

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col2 * + 27 col2 FROM tab1 AS cor0
----
1461
1603
2672

query I rowsort
SELECT DISTINCT col2 + 39 * ( col0 ) AS col1 FROM tab1 AS cor0
----
171
2553
3216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1498
SELECT - + col2 * CAST( 40 AS SIGNED ) + cor0.col2 FROM tab0 AS cor0
----
-1287
-3198
-39

skipif mysql # not compatible
query I rowsort label-1498
SELECT - + col2 * CAST ( 40 AS INTEGER ) + cor0.col2 FROM tab0 AS cor0
----
-1287
-3198
-39

query I rowsort
SELECT DISTINCT col2 * + 82 + + col0 * - col0 AS col2 FROM tab2 cor0
----
-3125
-3952
2165

query I rowsort
SELECT DISTINCT + col2 + col0 FROM tab0 cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1501
SELECT DISTINCT + col1 + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1501
SELECT DISTINCT + col1 + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT - col2 * col1 + 38 AS col0 FROM tab2 cor0
----
-1496
-608
-799

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + col2 + - col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT col2 * 64 + col2 + col1 AS col0 FROM tab0 cor0
----
162
2231
5421

query I rowsort
SELECT ALL - - tab1.col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT 25 - col2 AS col2 FROM tab0
----
-57
-8
24

query I rowsort
SELECT - ( col0 ) * + col0 + col0 FROM tab2
----
-42
-6006
-6162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1508
SELECT col1 * - col1 + - CAST( col1 AS SIGNED ) * - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1508
SELECT col1 * - col1 + - CAST ( col1 AS INTEGER ) * - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + + tab0.col0 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT 32 + tab1.col2 FROM tab1
----
128
86
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1511
SELECT ALL - ( col2 ) DIV - col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1511
SELECT ALL - ( col2 ) / - col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL tab1.col0 + tab1.col0 * tab1.col1 + col1 * col2 * ( - col0 ) AS col1 FROM tab1
----
-35776
-4131
-98720

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

query I rowsort
SELECT ALL + col1 * - col0 + col1 AS col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + col0 * - 13 + + 28 * - col2 AS col0 FROM tab1 AS cor0
----
-1551
-2428
-3728

query I rowsort
SELECT - + col2 * 84 AS col0 FROM tab0 AS cor0
----
-2772
-6888
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-1517
SELECT ALL - + cor0.col2 DIV ( col1 + + col2 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1517
SELECT ALL - + cor0.col2 / ( col1 + + col2 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col1 + col1 AS col0 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT ALL col2 + col0 * - ( - col1 ) + + 78 FROM tab0 AS cor0
----
2175
3474
8259

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 51 + + col1 * - col1 col2 FROM tab1 AS cor0
----
-105
-39
-599

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + 76 col1 FROM tab1 AS cor0
----
140
156
79

query I rowsort
SELECT - - col1 + ( 8 * + col0 ) + + 44 AS col0 FROM tab0 AS cor0
----
322
421
847

query I rowsort
SELECT col2 + ( + col2 ) + col2 AS col0 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT DISTINCT - 60 - - cor0.col2 AS col2 FROM tab1, tab0 AS cor0
----
-27
-59
22

query I rowsort
SELECT + ( 18 ) FROM tab2 AS cor0
----
18
18
18

query I rowsort
SELECT - - 58 FROM tab1 AS cor0
----
58
58
58

query I rowsort
SELECT + 81 * ( col0 ) FROM tab2 AS cor0
----
567
6318
6399

query I rowsort
SELECT 41 + - 84 + col0 AS col1 FROM tab1
----
-40
21
37

query I rowsort
SELECT - - col0 * cor0.col1 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col1 + - tab0.col1 AS col2 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1531
SELECT DISTINCT + col2 + col1 + col1 DIV cor0.col2 AS col1 FROM tab0 AS cor0
----
121
174
195

skipif mysql # not compatible
query I rowsort label-1531
SELECT DISTINCT + col2 + col1 + col1 / cor0.col2 AS col1 FROM tab0 AS cor0
----
121
174
195

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 1 + + cor0.col0 col2 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT + + 55 + + col0 FROM tab2 AS cor0
----
133
134
62

query I rowsort
SELECT ALL + 9 + + col1 * + col0 FROM tab2 AS cor0
----
1352
226
4611

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( 46 AS REAL ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT - + ( + 11 ) * - col2 * col2 AS col0 FROM tab2 AS cor0
----
15884
7436
8019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1537
SELECT - CAST( NULL AS SIGNED ) * + 88 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1537
SELECT - CAST ( NULL AS INTEGER ) * + 88 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * - 28 * - tab1.col1 + col1 AS col2 FROM tab1
----
17930
2210
29133

query I rowsort
SELECT DISTINCT - 27 AS col0 FROM tab2, tab0 AS cor0
----
-27

query I rowsort
SELECT ALL col0 * col2 * col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL 79 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT ALL + 58 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT tab2.col2 + ( + col1 ) AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL col1 * - 5 + - col1 AS col2 FROM tab0
----
-516
-546
-582

query I rowsort
SELECT - ( - 88 ) FROM tab1 cor0
----
88
88
88

query I rowsort
SELECT - ( col1 ) + col1 * col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT ALL + + ( - col0 ) FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1548
SELECT col1 DIV - cor0.col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1548
SELECT col1 / - cor0.col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - - cor0.col0 * col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - 15 * + col1 FROM tab1 AS cor0
----
-150
-195
-390

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * cor0.col0 col1 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-1552
SELECT DISTINCT + 6 DIV + col0 AS col2 FROM tab1 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-1552
SELECT DISTINCT + 6 / + col0 AS col2 FROM tab1 AS cor0
----
0
2

query I rowsort
SELECT ALL + 96 AS col0 FROM tab1 AS cor0
----
96
96
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1554
SELECT DISTINCT CAST( NULL AS SIGNED ) col2 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1554
SELECT DISTINCT CAST ( NULL AS INTEGER ) col2 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT + 84 + 41 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 2973878398e469d83385e7e06bd5af99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) + cor0.col2 col0 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + col2 - col0 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL + + col2 + col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + col0 * + col2 + - col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL + + 26 AS col0 FROM tab2 AS cor0
----
26
26
26

query I rowsort
SELECT ALL + 52 * + cor0.col1 - - col1 * - col2 FROM tab1 AS cor0
----
-50
-52
-572

onlyif mysql # use DIV operator for integer division
query I rowsort label-1562
SELECT ALL + col2 DIV - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1562
SELECT ALL + col2 / - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + cor0.col1 + - col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT ALL + + cor1.col0 + - cor1.col0 FROM tab1, tab2 cor0, tab1 cor1, tab0, tab1 AS cor2
----
243 values hashing to fa3d5b69e444df969b60da5e4c5c3507

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - + col0 col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + - col2 * - ( - 34 ) - cor0.col2 FROM tab0 AS cor0
----
-1155
-2870
-35

query I rowsort
SELECT DISTINCT + - col0 * col1 + ( + col1 ) + - col2 * 63 FROM tab0 AS cor0
----
-13174
-3361
-4057

query I rowsort
SELECT ALL col1 + ( col0 ) + col0 AS col0 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT ALL col1 * + col0 + + col1 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT DISTINCT 7 * 70 FROM tab1, tab0 AS cor0
----
490

onlyif mysql # use DIV operator for integer division
query I rowsort label-1571
SELECT ALL col0 * col1 + col0 DIV col1 AS col0 FROM tab2
----
1347
217
4603

skipif mysql # not compatible
query I rowsort label-1571
SELECT ALL col0 * col1 + col0 / col1 AS col0 FROM tab2
----
1347
217
4603

query I rowsort
SELECT DISTINCT col1 + - col2 * cor0.col0 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 75 col0 FROM tab1, tab1 AS cor0
----
75

query I rowsort
SELECT + col2 + col0 * + col0 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT col1 * + col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT 41 FROM tab0, tab0 AS cor0
----
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - 55 col1 FROM tab2 AS cor0
----
-133
-134
-62

query I rowsort
SELECT - + 14 + col1 * + col0 FROM tab0 AS cor0
----
2050
3381
8085

query I rowsort
SELECT 3 FROM tab0, tab0 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT - ( 54 ) FROM tab2 AS cor0
----
-54
-54
-54

query I rowsort
SELECT 39 + col2 FROM tab0 AS cor0
----
121
40
72

query I rowsort
SELECT ALL - ( 76 ) + + col0 * cor0.col0 * - col2 FROM tab2 AS cor0
----
-1399
-158260
-237234

query I rowsort
SELECT tab0.col0 + + 77 FROM tab0
----
101
112
166

query I rowsort
SELECT - 4 AS col2 FROM tab2 AS cor0
----
-4
-4
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-1585
SELECT 25 DIV - col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-1585
SELECT 25 / - col0 FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1586
SELECT ALL - 47 DIV + col1 FROM tab2 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-1586
SELECT ALL - 47 / + col1 FROM tab2 AS cor0
----
-1
-2
0

query I rowsort
SELECT ALL + - col1 * col0 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT ( + tab1.col0 ) + col2 * ( + col0 ) + + col2 AS col2 FROM tab1
----
219
3769
7856

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 col0 FROM tab0, tab1, tab1 AS cor0, tab0 AS cor1
----
24
35
89

query I rowsort
SELECT + tab2.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL + - cor0.col1 * - col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + col0 * + col2 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT + col2 * - tab1.col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT 10 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
10

query I rowsort
SELECT 71 * - 23 AS col2 FROM tab1
----
-1633
-1633
-1633

query I rowsort
SELECT DISTINCT - ( - tab2.col0 ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL + cor0.col0 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL 10 + + col0 FROM tab0 cor0
----
34
45
99

query I rowsort
SELECT + - ( col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - 14 AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to c2bf0e2420d22cd58d7ee3b30827afcc

query I rowsort
SELECT - col0 + col1 AS col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT - 9 AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
81 values hashing to ea2ee48b6db0ed0e9f87711d3eeef049

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1603
SELECT DISTINCT - CAST( col0 AS SIGNED ) + - col1 / CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-1603
SELECT DISTINCT - CAST ( col0 AS INTEGER ) + - col1 / CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT + 85 AS col0 FROM tab2
----
85
85
85

query I rowsort
SELECT + 45 - + col1 FROM tab1
----
19
32
35

query I rowsort
SELECT + col2 * + col0 + - col1 * col2 * col1 AS col2 FROM tab2
----
-25758
-7980
-88478

query I rowsort
SELECT DISTINCT 79 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
165
170
176

query I rowsort
SELECT - + 48 * - col1 FROM tab0 AS cor0
----
4128
4368
4656

query I rowsort
SELECT DISTINCT + col2 * col1 + - col0 AS col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT - 93 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
-93

query I rowsort
SELECT col0 + col2 * cor0.col1 + - col2 FROM tab1 AS cor0
----
1232
1353
577

query I rowsort
SELECT ALL col0 - + 74 AS col0 FROM tab0
----
-39
-50
15

query I rowsort
SELECT ALL + tab2.col0 - 0 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL col2 - ( col2 ) FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 89 col0 FROM tab2, tab1 cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT - col0 * ( + col1 ) - col0 FROM tab2 cor0
----
-1422
-224
-4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1617
SELECT - ( + col0 ) DIV - col1 + col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1617
SELECT - ( + col0 ) / - col1 + col1 FROM tab0 cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1618
SELECT ALL + - 96 DIV + col0 - col0 FROM tab1 AS cor0
----
-35
-65
-81

skipif mysql # not compatible
query I rowsort label-1618
SELECT ALL + - 96 / + col0 - col0 FROM tab1 AS cor0
----
-35
-65
-81

query I rowsort
SELECT - cor0.col1 * ( cor0.col1 ) + cor0.col0 AS col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT col2 + - col0 * col2 + cor0.col0 FROM tab1 cor0
----
-105
-3527
-7504

query I rowsort
SELECT 48 * cor0.col1 + col0 AS col1 FROM tab2 AS cor0
----
1495
2910
895

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1622
SELECT - CAST( - 40 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
40
40
40

skipif mysql # not compatible
query I rowsort label-1622
SELECT - CAST ( - 40 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
40
40
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-1623
SELECT ALL 18 DIV 35 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1623
SELECT ALL 18 / 35 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-1624
SELECT col2 DIV + col0 AS col1 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-1624
SELECT col2 / + col0 AS col1 FROM tab2
----
0
0
3

query I rowsort
SELECT ALL + - col0 * + 38 FROM tab0 AS cor0
----
-1330
-3382
-912

query I rowsort
SELECT - + 41 * col1 + col0 AS col0 FROM tab2 AS cor0
----
-1264
-2341
-618

query I rowsort
SELECT ALL + ( - ( col1 ) ) + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * 85 + + col1 AS col1 FROM tab0 AS cor0
----
182
2891
7061

query I rowsort
SELECT DISTINCT - ( - 70 ) FROM tab0 cor0
----
70

query I rowsort
SELECT ( cor0.col0 ) * + cor0.col1 + - col0 * + 45 FROM tab1 AS cor0
----
-2240
-2560
-57

query I rowsort
SELECT DISTINCT - 40 FROM tab0 AS cor0
----
-40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( 33 ) col0 FROM tab0 AS cor0
----
33
33
33

query I rowsort
SELECT + col1 + col2 - cor0.col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + ( - 18 ) FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + ( 28 ) AS col2 FROM tab1 AS cor0
----
28
28
28

query I rowsort
SELECT - cor1.col1 AS col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT ALL cor1.col2 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT 32 * 23 AS col0 FROM tab2
----
736
736
736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1639
SELECT + CAST( + cor0.col1 AS SIGNED ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1639
SELECT + CAST ( + cor0.col1 AS INTEGER ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - 80 * + cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
-15120
-162240
-240160

query I rowsort
SELECT - ( + col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT 13 AS col2 FROM tab2 cor0
----
13
13
13

query I rowsort
SELECT ALL - 37 + col1 FROM tab0 AS cor0
----
49
54
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-1644
SELECT DISTINCT + 84 DIV - col1 FROM tab1 cor0
----
-3
-6
-8

skipif mysql # not compatible
query I rowsort label-1644
SELECT DISTINCT + 84 / - col1 FROM tab1 cor0
----
-3
-6
-8

query I rowsort
SELECT DISTINCT + + 94 * col0 AS col1 FROM tab0 AS cor0
----
2256
3290
8366

query I rowsort
SELECT ALL + 47 + + col2 - col1 FROM tab0 AS cor0
----
-49
-6
38

query I rowsort
SELECT DISTINCT + + 23 * cor0.col1 + col1 FROM tab2 AS cor0
----
1416
408
744

query I rowsort
SELECT - col0 + - col0 * ( + cor0.col2 ) * col0 AS col1 FROM tab0 cor0
----
-1260
-19032
-649611

query I rowsort
SELECT ALL col2 * - col2 - + 60 AS col2 FROM tab0 AS cor0
----
-1149
-61
-6784

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * - col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col2 * + col2 + col2 AS col0 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT 42 * + 50 FROM tab1
----
2100
2100
2100

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - 66 ) + col1 col2 FROM tab1
----
-40
-53
-56

query I rowsort
SELECT DISTINCT - 98 AS col0 FROM tab0, tab2 AS cor0
----
-98

query I rowsort
SELECT DISTINCT + - col0 * + 74 + + cor0.col1 FROM tab1 AS cor0
----
-196
-4726
-5907

query I rowsort
SELECT ALL + - col2 * + col0 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - - col2 * - ( + col1 + - col0 ) FROM tab0 AS cor0
----
-164
-2046
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1658
SELECT ALL + col1 DIV + col0 AS col1 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-1658
SELECT ALL + col1 / + col0 AS col1 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT + cor0.col0 * 93 FROM tab2 AS cor0
----
651
7254
7347

query I rowsort
SELECT DISTINCT - col2 * - ( - col1 ) + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT - col1 * - col1 AS col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT + col0 + col2 * col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + col1 * + cor0.col1 + col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT + 75 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT DISTINCT 84 FROM tab2, tab0, tab1 AS cor0
----
84

query I rowsort
SELECT - col2 * + cor0.col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT col2 * cor0.col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL - col0 * 29 FROM tab2 AS cor0
----
-203
-2262
-2291

onlyif mysql # use DIV operator for integer division
query I rowsort label-1669
SELECT col2 DIV + col0 AS col2 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-1669
SELECT col2 / + col0 AS col2 FROM tab1 cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - tab0.col2 col2 FROM tab0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort
SELECT ALL - col0 * CAST ( col1 AS REAL ) AS col0 FROM tab1
----
-1040
-640
-78

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to dd5ce24448edb4b3ab62c251475d6548

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + 49 * col2 + - col2 col2 FROM tab1 AS cor0
----
2566
2726
4595

onlyif mysql # use DIV operator for integer division
query I rowsort label-1674
SELECT - col2 DIV + 55 AS col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-1674
SELECT - col2 / + 55 AS col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT cor0.col1 + 42 AS col1 FROM tab1 AS cor0
----
52
55
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-1676
SELECT DISTINCT - col1 DIV - 45 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1676
SELECT DISTINCT - col1 / - 45 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1677
SELECT - + col0 / - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1677
SELECT - + col0 / - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1678
SELECT - - col2 + + col0 DIV - col0 + - col2 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1678
SELECT - - col2 + + col0 / - col0 + - col2 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 46 * col0 col0 FROM tab0
----
1104
1610
4094

query I rowsort
SELECT - col2 + + 88 + col1 FROM tab2 AS cor0
----
121
67
92

query I rowsort
SELECT 81 + col2 * - col0 FROM tab1
----
-3567
-7599
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 * - 86 col1 FROM tab0
----
-2752
-6961
11

query I rowsort
SELECT + 68 * col2 FROM tab0 AS cor0
----
2244
5576
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 + - col0 col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL + col0 * ( - 87 ) FROM tab2 cor0
----
-609
-6786
-6873

query I rowsort
SELECT ALL - col2 + + ( col1 ) AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - cor0.col1 * - col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL col0 + col0 + + col0 FROM tab0
----
105
267
72

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL <> ( NULL )
----

query I rowsort
SELECT ALL - col2 + col0 + - col1 * + col0 AS col1 FROM tab1
----
-1056
-129
-633

query I rowsort
SELECT ALL - tab1.col1 * tab1.col2 + tab1.col0 + + col1 AS col1 FROM tab1
----
-1155
-1375
-496

query I rowsort
SELECT ALL tab0.col1 AS col2 FROM tab0 WHERE NOT ( NULL ) <> ( NULL )
----

query I rowsort
SELECT - col2 - col1 * - col0 FROM tab2
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col2 + col2 col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT col1 + + tab2.col2 + + col0 FROM tab2
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-1696
SELECT - col0 DIV col2 + col2 AS col0 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-1696
SELECT - col0 / col2 + col2 AS col0 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT DISTINCT - col1 + tab1.col1 AS col0 FROM tab1
----
0

query I rowsort
SELECT tab1.col0 * col1 * + col0 AS col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT + tab2.col0 AS col1 FROM tab2 WHERE NOT + tab2.col1 + + col2 <> NULL
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT + col2 + col1 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT - col2 * tab0.col1 * col2 FROM tab0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 + - col2 * + col0 col2 FROM tab2
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1703
SELECT DISTINCT CAST( NULL AS SIGNED ) * - 96 AS col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-1703
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - 96 AS col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1704
SELECT ALL + tab0.col2 DIV cor0.col0 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to fafedb59d241ca768828b5c52c55c208

skipif mysql # not compatible
query I rowsort label-1704
SELECT ALL + tab0.col2 / cor0.col0 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to fafedb59d241ca768828b5c52c55c208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col1 * 41 col0 FROM tab0 AS cor0
----
-303236
-339521
-385769

query I rowsort
SELECT - ( + cor0.col2 ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT + - 89 + col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
21
43
91

query I rowsort
SELECT ALL ( col0 ) - 88 AS col0 FROM tab2 AS cor0
----
-10
-81
-9

query I rowsort
SELECT + col2 * - col1 + 88 FROM tab0 AS cor0
----
-2750
-7374
-9

query I rowsort
SELECT DISTINCT + col2 + col2 * ( - cor0.col0 ) FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - col2 + col1 AS col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT 77 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT cor0.col0 - col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + ( + col0 ) * col2 + - col1 + + cor0.col0 FROM tab1 cor0
----
139
3702
7747

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1715
SELECT DISTINCT + col1 + col1 * + CAST( NULL AS SIGNED ) + + 93 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1715
SELECT DISTINCT + col1 + col1 * + CAST ( NULL AS INTEGER ) + + 93 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1716
SELECT cor0.col1 + CAST( - 47 AS SIGNED ) FROM tab0 AS cor0
----
39
44
50

skipif mysql # not compatible
query I rowsort label-1716
SELECT cor0.col1 + CAST ( - 47 AS INTEGER ) FROM tab0 AS cor0
----
39
44
50

query I rowsort
SELECT - cor0.col2 + - col1 AS col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + col1 * 79 FROM tab0 AS cor0
----
6794
7189
7663

query I rowsort
SELECT DISTINCT - 68 * 32 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
-2176

onlyif mysql # use DIV operator for integer division
query I rowsort label-1720
SELECT - col1 DIV col0 + col0 DIV + cor0.col1 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-1720
SELECT - col1 / col0 + col0 / + cor0.col1 FROM tab0 AS cor0
----
-1
-2
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1721
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1721
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL - 86 + col0 AS col0 FROM tab1 AS cor0
----
-22
-6
-83

query I rowsort
SELECT + ( - col0 ) + cor0.col1 FROM tab2 AS cor0
----
-19
-62
24

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab2 cor1, tab1, tab1 cor2
----
3645 values hashing to 199388980dc5177ebebcfdbc0408ba02

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1725
SELECT ALL + CAST( - col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-1725
SELECT ALL + CAST ( - col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 77 + tab2.col2 col0 FROM tab2, tab0 AS cor0
----
103
104
115

query I rowsort
SELECT 23 AS col2 FROM tab1
----
23
23
23

query I rowsort
SELECT DISTINCT + 7 * col0 - col2 FROM tab2 AS cor0
----
22
515
520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 * 3 - + col1 col2 FROM tab0 cor0
----
-1814
-23854
-3772

query I rowsort
SELECT + cor0.col2 + - col1 + - col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT col1 * col2 + 27 + ( - col2 + - col1 ) FROM tab2 AS cor0
----
1476
618
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-1732
SELECT - cor0.col2 DIV + col0 - + 23 AS col0 FROM tab0 AS cor0
----
-23
-23
-24

skipif mysql # not compatible
query I rowsort label-1732
SELECT - cor0.col2 / + col0 - + 23 AS col0 FROM tab0 AS cor0
----
-23
-23
-24

query I rowsort
SELECT ALL - col0 + - col0 AS col1 FROM tab0
----
-178
-48
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-1734
SELECT - col1 DIV - 95 AS col2 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1734
SELECT - col1 / - 95 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT ( - col2 ) + + col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL - 49 FROM tab2, tab2 AS cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT - 38 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1738
SELECT ALL + CAST( NULL AS SIGNED ) * col2 + col0 * - CAST( col2 + + col0 AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1738
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 + col0 * - CAST ( col2 + + col0 AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + cor0.col2 * col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT + + cor0.col0 + - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-1741
SELECT - col2 DIV + col1 AS col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-1741
SELECT - col2 / + col1 AS col1 FROM tab1
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1742
SELECT 75 DIV col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1742
SELECT 75 / col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT col1 - tab1.col0 AS col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT + tab0.col1 - - col2 FROM tab0
----
119
173
98

query I rowsort
SELECT col0 - + col0 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + col2 + - col2 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + tab1.col1 * + col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col1 + col1 * col1 FROM tab0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT + col2 * col1 + - col0 * - col0 FROM tab0
----
1322
15383
3414

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 col1 FROM tab1
----
28
47
83

query I rowsort
SELECT col1 * + col1 + col0 AS col2 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT + col2 - col1 AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT + + col0 * cor0.col1 * col1 AS col2 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT cor0.col1 FROM tab1, tab0, tab0 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - ( + 64 ) FROM tab2
----
-64

query I rowsort
SELECT 69 AS col0 FROM tab1
----
69
69
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1757
SELECT DISTINCT CAST( - col1 AS SIGNED ) FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-1757
SELECT DISTINCT CAST ( - col1 AS INTEGER ) FROM tab1
----
-10
-13
-26

query I rowsort
SELECT - 50 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT + 3 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT + 38 AS col1 FROM tab1 AS cor0
----
38
38
38

query I rowsort
SELECT - cor0.col2 + col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - 26 + col0 FROM tab0 cor0
----
-2
63
9

query I rowsort
SELECT DISTINCT col1 * + col0 * tab1.col0 - + col1 FROM tab1
----
208
40950
83187

query I rowsort
SELECT + col0 - + col2 * + col2 FROM tab1
----
-2913
-3185
-9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-1765
SELECT 27 DIV + col2 + tab0.col1 - - col1 AS col2 FROM tab0
----
172
182
221

skipif mysql # not compatible
query I rowsort label-1765
SELECT 27 / + col2 + tab0.col1 - - col1 AS col2 FROM tab0
----
172
182
221

query I rowsort
SELECT DISTINCT + col1 + cor0.col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT col0 * + col1 + cor0.col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL col1 + col2 * col0 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-1769
SELECT DISTINCT + ( + col0 ) DIV + col1 FROM tab1 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-1769
SELECT DISTINCT + ( + col0 ) / + col1 FROM tab1 AS cor0
----
0
6

query I rowsort
SELECT ALL + col2 * col0 * + col0 AS col2 FROM tab1 WHERE NOT NULL BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - tab2.col1 col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT ALL + col2 * - col2 AS col1 FROM tab0 WHERE NULL IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1773
SELECT DISTINCT - col0 DIV col2 + + col0 FROM tab0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-1773
SELECT DISTINCT - col0 / col2 + + col0 FROM tab0
----
0
24
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * tab1.col1 - col1 col2 FROM tab1
----
1235
1378
560

query I rowsort
SELECT ALL col1 * col0 AS col1 FROM tab1 WHERE NOT + col0 = ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1776
SELECT ALL + col0 DIV col1 + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1776
SELECT ALL + col0 / col1 + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL + col2 - + col1 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - col0 * - col0 - - col0 * cor0.col0 FROM tab0 AS cor0
----
1152
15842
2450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + col1 col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT col0 * col0 - col1 FROM tab1
----
-17
4086
6387

query I rowsort
SELECT + col1 * - col0 + col1 AS col1 FROM tab2 WHERE NOT NULL >= col2 + + col0 * col0
----

query I rowsort
SELECT ALL col0 * + col2 + + col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT ALL + col2 AS col0 FROM tab1 WHERE NOT ( NULL ) BETWEEN - col1 * - col2 AND + col2 * - col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1784
SELECT col2 DIV col0 + col0 * - col1 AS col1 FROM tab1
----
-1039
-60
-640

skipif mysql # not compatible
query I rowsort label-1784
SELECT col2 / col0 + col0 * - col1 AS col1 FROM tab1
----
-1039
-60
-640

query I rowsort
SELECT DISTINCT col2 AS col0 FROM tab2 WHERE ( NULL ) NOT BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1786
SELECT - col2 DIV + tab2.col0 + tab2.col2 FROM tab2
----
24
26
38

skipif mysql # not compatible
query I rowsort label-1786
SELECT - col2 / + tab2.col0 + tab2.col2 FROM tab2
----
24
26
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1787
SELECT DISTINCT col2 DIV col0 + - col2 FROM tab0
----
-1
-32
-82

skipif mysql # not compatible
query I rowsort label-1787
SELECT DISTINCT col2 / col0 + - col2 FROM tab0
----
-1
-32
-82

query I rowsort
SELECT + col0 * + col0 * col0 + tab1.col1 AS col2 FROM tab1
----
262154
512013
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-1789
SELECT ALL - col2 DIV - col0 + col1 AS col1 FROM tab2
----
17
34
59

skipif mysql # not compatible
query I rowsort label-1789
SELECT ALL - col2 / - col0 + col1 AS col1 FROM tab2
----
17
34
59

query I rowsort
SELECT + col1 - col1 * - col1 FROM tab2
----
306
3540
992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * tab2.col1 col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT + col1 + col2 + - col2 FROM tab0 WHERE - col1 < - col0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1793
SELECT col1 DIV - tab0.col1 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1793
SELECT col1 / - tab0.col1 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 * + col2 col0 FROM tab0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-1795
SELECT - col2 DIV tab2.col0 + + col0 + + col0 AS col1 FROM tab2
----
11
156
158

skipif mysql # not compatible
query I rowsort label-1795
SELECT - col2 / tab2.col0 + + col0 + + col0 AS col1 FROM tab2
----
11
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-1796
SELECT col1 DIV + col1 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1796
SELECT col1 / + col1 AS col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col1 * col1 col0 FROM tab2
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-1798
SELECT col2 DIV col0 + col0 DIV col0 FROM tab2
----
1
1
4

skipif mysql # not compatible
query I rowsort label-1798
SELECT col2 / col0 + col0 / col0 FROM tab2
----
1
1
4

query I rowsort
SELECT DISTINCT col2 FROM tab1 WHERE NOT col1 NOT IN ( col1 )
----
54
57
96

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( col2 ) NOT BETWEEN NULL AND col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 * col1 col2 FROM tab1 WHERE NOT ( NULL ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT + col2 * col1 + col1 + col0 FROM tab1 cor0
----
1341
1433
644

query I rowsort
SELECT - col1 * cor0.col0 * + col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL col1 * + col2 + cor0.col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT col1 * - col0 + - col0 AS col0 FROM tab1
----
-1120
-704
-81

query I rowsort
SELECT col2 * col1 * col2 + col2 FROM tab2 AS cor0
----
22626
24586
39910

query I rowsort
SELECT col2 + col0 * col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT ALL - - col0 * cor0.col0 + col1 + col0 AS col0 FROM tab1 AS cor0
----
38
4170
6493

query I rowsort
SELECT DISTINCT col1 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - - cor0.col1 * col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col0 * + col2 AS col0 FROM tab2 cor0
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-1812
SELECT ALL - col1 DIV cor0.col0 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-1812
SELECT ALL - col1 / cor0.col0 FROM tab2 cor0
----
-4
0
0

query I rowsort
SELECT ALL - tab1.col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT ALL tab1.col1 * col1 FROM tab1 WHERE col0 BETWEEN - col0 AND - col2 + + col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1815
SELECT DISTINCT col2 DIV + col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-1815
SELECT DISTINCT col2 / + col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT - cor0.col1 * col2 * col0 AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT col1 * cor0.col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - col0 * 14 FROM tab0
----
-1246
-336
-490

query I rowsort
SELECT ALL - 33 FROM tab1
----
-33
-33
-33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1820
SELECT + + CAST( NULL AS SIGNED ) * 97 + col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1820
SELECT + + CAST ( NULL AS INTEGER ) * 97 + col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + ( + 11 ) AS col1 FROM tab2 AS cor0
----
-11
-11
-11

query I rowsort
SELECT DISTINCT ( + col2 ) AS col1 FROM tab2 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1823
SELECT ALL - + ( col1 ) DIV - col1 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1823
SELECT ALL - + ( col1 ) / - col1 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + 40 + - ( - cor0.col1 ) FROM tab0 AS cor0
----
126
131
137

query I rowsort
SELECT + + 40 + col2 FROM tab1 AS cor0
----
136
94
97

query I rowsort
SELECT ALL 11 * - col1 + col0 FROM tab0 AS cor0
----
-1032
-912
-922

query I rowsort
SELECT 87 + + col0 * - col1 AS col0 FROM tab1
----
-553
-953
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 49 * + col2 col2 FROM tab1
----
2646
2793
4704

query I rowsort
SELECT - 93 * col2 + col1 * + col1 FROM tab1 AS cor0
----
-4346
-5201
-8759

query I rowsort
SELECT + 46 * col1 FROM tab2 AS cor0
----
1426
2714
782

query I rowsort
SELECT + tab2.col0 * + col1 FROM tab2
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1832
SELECT DISTINCT col0 / col0 + col1 / CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-1832
SELECT DISTINCT col0 / col0 + col1 / CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + col1 col2 FROM tab2 cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1834
SELECT + cor0.col2 DIV 64 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1834
SELECT + cor0.col2 / 64 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - col1 * + col1 * - col2 AS col1 FROM tab2 AS cor0
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + 3 col1 FROM tab0 AS cor0
----
105
267
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-1837
SELECT - col0 - 7 DIV col2 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-1837
SELECT - col0 - 7 / col2 col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - - col1 + - 26 * 27 FROM tab0 AS cor0
----
-605
-611
-616

query I rowsort
SELECT ALL 95 * + col0 AS col1 FROM tab2
----
665
7410
7505

query I rowsort
SELECT ALL col1 * - ( - col0 ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-1841
SELECT - col2 DIV - ( + col2 ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1841
SELECT - col2 / - ( + col2 ) FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + cor0.col0 + col0 * col1 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT - col2 + col2 + + col1 AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT col0 * 13 + col0 FROM tab0
----
1246
336
490

query I rowsort
SELECT cor1.col0 FROM tab0 cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT 0 + 35 AS col0 FROM tab0 cor0
----
35
35
35

query I rowsort
SELECT + cor0.col2 + ( col2 ) FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ( col1 ) + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT 5 FROM tab0, tab2 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT DISTINCT ( + tab2.col0 ) * - 76 FROM tab2, tab0 AS cor0
----
-532
-5928
-6004

query I rowsort
SELECT - col0 - 46 FROM tab0 cor0
----
-135
-70
-81

query I rowsort
SELECT + ( - col0 ) + col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - + ( + cor0.col1 ) + + col1 * - col0 - + ( cor0.col1 ) FROM tab2 AS cor0
----
-1377
-279
-4720

query I rowsort
SELECT - + cor0.col0 + col1 * + col2 AS col0 FROM tab0 cor0
----
2814
62
7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1855
SELECT + CAST( col0 AS SIGNED ) AS col0 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-1855
SELECT + CAST ( col0 AS INTEGER ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT ( tab1.col1 ) FROM tab1
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1857
SELECT DISTINCT - + col1 * - cor0.col2 + - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1857
SELECT DISTINCT - + col1 * - cor0.col2 + - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1858
SELECT DISTINCT + cor0.col0 DIV + col0 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-1858
SELECT DISTINCT + cor0.col0 / + col0 FROM tab1 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1859
SELECT + CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1859
SELECT + CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT 47 * - 69 FROM tab0, tab1 AS cor0
----
-3243

query I rowsort
SELECT tab2.col0 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT col2 * - 26 FROM tab2 AS cor0
----
-676
-702
-988

query I rowsort
SELECT 28 * - col0 AS col0 FROM tab1 AS cor0
----
-1792
-2240
-84

query I rowsort
SELECT ALL col2 + cor0.col1 FROM tab1 cor0
----
109
67
80

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 ALL - col1 * + col1 * + 50 FROM tab2 AS cor0
----
-14450
-174050
-48050

query I rowsort
SELECT + cor0.col2 + cor0.col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT - 13 AS col1 FROM tab1 AS cor0
----
-13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1869
SELECT DISTINCT - - cor0.col1 + + col1 / + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1869
SELECT DISTINCT - - cor0.col1 + + col1 / + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - - col2 * col2 - + col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT DISTINCT - 35 - cor0.col1 AS col1 FROM tab2 AS cor0
----
-52
-66
-94

query I rowsort
SELECT DISTINCT + 34 * col1 AS col2 FROM tab1 AS cor0
----
340
442
884

query I rowsort
SELECT - col0 + + col0 * + 80 FROM tab0 AS cor0
----
1896
2765
7031

query I rowsort
SELECT col0 * + col1 * - cor0.col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - + col0 * col2 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - + 91 + + col2 * - col2 AS col1 FROM tab0 cor0
----
-1180
-6815
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-1877
SELECT - col1 DIV cor0.col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1877
SELECT - col1 / cor0.col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - col1 * + col1 + col2 AS col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL + col1 * + col2 + + col1 * col2 AS col0 FROM tab0 AS cor0
----
14924
194
5676

query I rowsort
SELECT ALL 34 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT ALL + - col1 * + cor0.col2 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT col2 + + 9 + col0 AS col1 FROM tab1 cor0
----
130
185
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-1884
SELECT DISTINCT cor0.col2 - + cor0.col2 DIV cor0.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
26
27
36

skipif mysql # not compatible
query I rowsort label-1884
SELECT DISTINCT cor0.col2 - + cor0.col2 / cor0.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
26
27
36

query I rowsort
SELECT ALL - col0 - - col1 * 99 FROM tab1
----
1207
2571
926

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1886
SELECT ALL + CAST( NULL AS DECIMAL ) col2 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1886
SELECT ALL + CAST ( NULL AS REAL ) col2 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT col2 + + col1 * - col1 AS col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT 63 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1889
SELECT + CAST( NULL AS DECIMAL ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1889
SELECT + CAST ( NULL AS REAL ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 83 FROM tab0 cor0
----
83
83
83

query I rowsort
SELECT ALL col1 * 15 AS col1 FROM tab2 AS cor0
----
255
465
885

query I rowsort
SELECT cor0.col1 AS col2 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT + 30 AS col0 FROM tab0, tab2 AS cor0
----
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 69 + 77 + - col1 col0 FROM tab0 cor0
----
-78
-83
-89

query I rowsort
SELECT cor0.col0 - cor0.col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 40 * cor0.col1 col0 FROM tab0 AS cor0
----
3440
3640
3880

query I rowsort
SELECT col2 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - 20 FROM tab2
----
-20
-20
-20

query I rowsort
SELECT - tab1.col2 * - tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cf1383d310e5e3e19470e0b8dc064d0c

query I rowsort
SELECT + - col1 * cor0.col0 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL cor1.col1 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1902
SELECT - CAST( - col1 * col1 AS SIGNED ) + + col2 * - 13 col1 FROM tab0
----
6967
7215
9396

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1902
SELECT - CAST ( - col1 * col1 AS INTEGER ) + + col2 * - 13 col1 FROM tab0
----
6967
7215
9396

query I rowsort
SELECT DISTINCT + col1 + - col0 * - 78 AS col1 FROM tab2 AS cor0
----
577
6143
6179

onlyif mysql # use DIV operator for integer division
query I rowsort label-1904
SELECT DISTINCT col0 DIV + col2 AS col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-1904
SELECT DISTINCT col0 / + col2 AS col2 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT + col1 + col2 * - col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL 68 * - col1 FROM tab2
----
-1156
-2108
-4012

query I rowsort
SELECT ALL 33 * - tab2.col2 AS col0 FROM tab2
----
-1254
-858
-891

onlyif mysql # use DIV operator for integer division
query I rowsort label-1908
SELECT + ( + col2 ) * col2 + col2 DIV + col1 FROM tab2
----
1446
676
729

skipif mysql # not compatible
query I rowsort label-1908
SELECT + ( + col2 ) * col2 + col2 / + col1 FROM tab2
----
1446
676
729

query I rowsort
SELECT DISTINCT - - 1 AS col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT ALL - - col1 * - cor0.col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - 2 * col0 AS col2 FROM tab2 cor0
----
-14
-156
-158

query I rowsort
SELECT DISTINCT 97 AS col1 FROM tab2
----
97

query I rowsort
SELECT ALL col1 * col1 + 96 FROM tab2 AS cor0
----
1057
3577
385

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col0 * + col0 col1 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-1915
SELECT ALL col1 + col0 DIV + 56 FROM tab0
----
86
92
97

skipif mysql # not compatible
query I rowsort label-1915
SELECT ALL col1 + col0 / + 56 FROM tab0
----
86
92
97

query I rowsort
SELECT ALL + col1 + col1 * - col0 AS col2 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT ALL - col1 * + col1 + col1 AS col1 FROM tab1
----
-156
-650
-90

query I rowsort
SELECT ALL - tab2.col1 * - col2 + col1 * - tab2.col2 FROM tab2
----
0
0
0

query I rowsort
SELECT col0 + - 42 AS col0 FROM tab0 cor0
----
-18
-7
47

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0, tab0 cor2
----
3645 values hashing to 8e88b3a69c24fc01553b0c32bf7748d0

query I rowsort
SELECT col0 * + 26 AS col0 FROM tab1
----
1664
2080
78

query I rowsort
SELECT ALL col0 + + 92 FROM tab2
----
170
171
99

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * + col1 AS col2 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT + col1 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + ( cor0.col2 ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - cor0.col1 * + col0 + + col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT - col1 + + col0 + col0 AS col0 FROM tab2 AS cor0
----
-17
141
97

query I rowsort
SELECT + + 56 + + col0 * - cor0.col2 FROM tab1 AS cor0
----
-106
-3592
-7624

query I rowsort
SELECT + cor0.col0 + + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - 47 * - col1 FROM tab2 AS cor0
----
1457
2773
799

onlyif mysql # use DIV operator for integer division
query I rowsort label-1931
SELECT DISTINCT - - col2 DIV col1 + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1931
SELECT DISTINCT - - col2 / col1 + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - - col1 * - cor0.col2 - - col2 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + col0 * - 43 AS col1 FROM tab1
----
-129
-2752
-3440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1934
SELECT ALL CAST( + 53 AS SIGNED ) * col0 FROM tab1 AS cor0
----
159
3392
4240

skipif mysql # not compatible
query I rowsort label-1934
SELECT ALL CAST ( + 53 AS INTEGER ) * col0 FROM tab1 AS cor0
----
159
3392
4240

query I rowsort
SELECT + + 41 * col1 + col0 FROM tab1 AS cor0
----
1069
474
613

query I rowsort
SELECT DISTINCT - - 89 * col0 + col2 FROM tab2 AS cor0
----
650
6968
7069

query I rowsort
SELECT ALL + + ( cor0.col1 ) + col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - col0 * cor0.col2 * col0 + col2 + col2 * - col1 FROM tab1 AS cor0
----
-1836
-233985
-615552

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1939
SELECT DISTINCT CAST( cor0.col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-1939
SELECT DISTINCT CAST ( cor0.col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + + ( - 70 ) AS col0 FROM tab2 AS cor0
----
-70
-70
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1941
SELECT DISTINCT - CAST( NULL AS SIGNED ) + col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1941
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + col0 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col1 + col2 * col0 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL 2 * + 20 + col2 * col1 * col2 + + col2 AS col2 FROM tab1 cor0
----
119944
32587
75910

query I rowsort
SELECT + col0 + 30 + - col0 * 72 AS col1 FROM tab2 AS cor0
----
-467
-5508
-5579

query I rowsort
SELECT DISTINCT - ( - col1 ) * col1 AS col2 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 + - cor0.col0 * col2 col1 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT col2 * + col1 + + 77 AS col0 FROM tab2
----
1611
723
914

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2, tab2 AS cor0, tab2 AS cor1
----
972 values hashing to 163d7732097d78f1cda7f65c2cea5a08

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 * + tab1.col2 + + col1 * col0 col1 FROM tab1
----
1210
1482
2288

query I rowsort
SELECT - ( - 3 ) AS col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

onlyif mysql # use DIV operator for integer division
query I rowsort label-1951
SELECT ALL col0 + tab1.col0 DIV + col1 col2 FROM tab1
----
3
70
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1951
SELECT ALL col0 + tab1.col0 / + col1 col2 FROM tab1
----
3
70
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col1 col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT DISTINCT ( cor0.col2 ) + 72 * col0 AS col1 FROM tab0 AS cor0
----
1761
2521
6490

query I rowsort
SELECT + 73 AS col1 FROM tab2
----
73
73
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-1955
SELECT tab1.col2 DIV - col2 AS col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1955
SELECT tab1.col2 / - col2 AS col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT - ( col1 ) * 3 FROM tab0
----
-258
-273
-291

onlyif mysql # use DIV operator for integer division
query I rowsort label-1957
SELECT + - col0 + + col1 * - col0 DIV - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-1957
SELECT + - col0 + + col1 * - col0 / - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL col2 * - 23 FROM tab1 cor0
----
-1242
-1311
-2208

query I rowsort
SELECT DISTINCT - cor0.col1 + - col2 + + 78 FROM tab1 AS cor0
----
-2
-31
11

query I rowsort
SELECT ALL - - col2 + col2 AS col1 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + ( col1 ) col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col1 + - col2 * - col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT + col2 * - col0 * 6 AS col1 FROM tab2 AS cor0
----
-1134
-12168
-18012

onlyif mysql # use DIV operator for integer division
query I rowsort label-1964
SELECT col0 DIV ( 96 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1964
SELECT col0 / ( 96 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + + ( col2 ) * col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT cor0.col1 - + col0 AS col0 FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1967
SELECT cor0.col0 * CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-1967
SELECT cor0.col0 * CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 6 * + 71 col1 FROM tab0 AS cor0
----
427
459
508

query I rowsort
SELECT + col1 + - 52 * col2 FROM tab1 cor0
----
-2782
-2954
-4979

query I rowsort
SELECT 97 AS col0 FROM tab0
----
97
97
97

query I rowsort
SELECT + col2 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + col0 * ( + col1 + - col0 ) FROM tab1 AS cor0
----
-3456
-5360
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1973
SELECT + CAST( 32 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
32
32
32

skipif mysql # not compatible
query I rowsort label-1973
SELECT + CAST ( 32 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
32
32
32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1974
SELECT 6 * 37 * - col0 + - CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1974
SELECT 6 * 37 * - col0 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

query IIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
243 values hashing to 60bd71ee2159222231bb3b5819bc5dca

query I rowsort
SELECT DISTINCT - - col2 + - ( + col0 ) AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + ( ( - col2 ) ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - + col2 * 6 * col2 + col2 * col0 + col2 * + 63 AS col0 FROM tab2 AS cor0
----
-2484
-3268
-390

query I rowsort
SELECT ALL - col0 + col1 - col1 FROM tab1 cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 + - 54 * - cor0.col2 col2 FROM tab2 AS cor0
----
1378
1431
2014

onlyif mysql # use DIV operator for integer division
query I rowsort label-1981
SELECT + col1 * col1 DIV col0 AS col0 FROM tab0 AS cor0
----
268
308
93

skipif mysql # not compatible
query I rowsort label-1981
SELECT + col1 * col1 / col0 AS col0 FROM tab0 AS cor0
----
268
308
93

query I rowsort
SELECT DISTINCT - ( + 28 ) FROM tab0 cor0
----
-28

query I rowsort
SELECT ALL + - 78 AS col1 FROM tab1 AS cor0
----
-78
-78
-78

query I rowsort
SELECT + - ( + 15 ) AS col2 FROM tab0 AS cor0
----
-15
-15
-15

query I rowsort
SELECT + + ( col2 ) + - col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - 90 * col0 + col2 * col1 AS col2 FROM tab0 AS cor0
----
-3053
-548
678

query I rowsort
SELECT DISTINCT + + 38 AS col0 FROM tab0 AS cor0
----
38

query I rowsort
SELECT DISTINCT + ( + col0 ) - - col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + ( + col1 ) + - col1 * + ( + col2 ) AS col1 FROM tab0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1990
SELECT + 9 DIV - cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 1313fe5a78d4cb52a368eb751ada9cfa

skipif mysql # not compatible
query I rowsort label-1990
SELECT + 9 / - cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 1313fe5a78d4cb52a368eb751ada9cfa

query I rowsort
SELECT 43 * - col0 AS col0 FROM tab1 AS cor0
----
-129
-2752
-3440

query I rowsort
SELECT col1 * + col1 * + col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT + col1 + col0 * + cor0.col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + 0 * col1 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col0 * col2 col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT + - 4 * + col1 AS col2 FROM tab1 cor0
----
-104
-40
-52

query I rowsort
SELECT - + 75 + + col2 AS col2 FROM tab0 AS cor0
----
-42
-74
7

query I rowsort
SELECT - 1 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col1 col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL - tab1.col2 FROM tab1, tab0 cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT ( - col0 * - col0 ) AS col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL - col0 + + 50 * + 40 FROM tab2 cor0
----
1921
1922
1993

query I rowsort
SELECT ALL cor0.col1 * + ( col1 ) * col2 AS col2 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT DISTINCT 87 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
87

query I rowsort
SELECT DISTINCT 79 AS col1 FROM tab2
----
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2006
SELECT - CAST( - 0 AS SIGNED ) * - col0 + col1 * + col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-2006
SELECT - CAST ( - 0 AS INTEGER ) * - col0 + col1 * + col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ( 93 ) + - col2 + - col2 FROM tab1 AS cor0
----
-15
-21
-99

query I rowsort
SELECT cor0.col0 + col1 + col1 FROM tab2 AS cor0
----
113
196
69

query I rowsort
SELECT ALL + 94 * - tab2.col0 FROM tab2
----
-658
-7332
-7426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * 81 col0 FROM tab2
----
567
6318
6399

query I rowsort
SELECT DISTINCT + 42 FROM tab1
----
42

query I rowsort
SELECT DISTINCT 70 * col0 AS col0 FROM tab1 AS cor0
----
210
4480
5600

query I rowsort
SELECT - 32 * col1 * col2 FROM tab0 AS cor0
----
-238784
-3104
-90816

query I rowsort
SELECT DISTINCT 31 FROM tab1, tab2 AS cor0
----
31

query I rowsort
SELECT col0 + + ( col1 ) AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + col0 * col1 + - col0 * col2 AS col1 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT ALL + tab1.col0 * - 38 FROM tab1
----
-114
-2432
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2018
SELECT DISTINCT + CAST( NULL AS DECIMAL ) AS col2 FROM tab1, tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2018
SELECT DISTINCT + CAST ( NULL AS REAL ) AS col2 FROM tab1, tab1 cor0
----
NULL

query I rowsort
SELECT DISTINCT cor1.col1 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2020
SELECT ALL col1 DIV + col2 + - col2 + col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2020
SELECT ALL col1 / + col2 + - col2 + col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT + 37 AS col2 FROM tab0 AS cor0
----
37
37
37

query I rowsort
SELECT DISTINCT - + col0 - col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT - ( - col2 ) AS col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT ( - col0 ) FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2025
SELECT DISTINCT + col0 - cor0.col2 DIV col1 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-2025
SELECT DISTINCT + col0 - cor0.col2 / col1 FROM tab2 AS cor0
----
7
77
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2026
SELECT ALL CAST( NULL AS SIGNED ) col0 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2026
SELECT ALL CAST ( NULL AS INTEGER ) col0 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 71 col1 FROM tab1 AS cor0
----
71
71
71

query I rowsort
SELECT ALL + + col2 * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT cor1.col0 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - col2 * col0 * 7 FROM tab1 AS cor0
----
-1134
-25536
-53760

query I rowsort
SELECT + - 9 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-153
-279
-531

query I rowsort
SELECT - col2 * col2 * col1 AS col1 FROM tab0 AS cor0
----
-611884
-93654
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2033
SELECT DISTINCT - col2 * + col2 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2033
SELECT DISTINCT - col2 * + col2 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL

query I rowsort
SELECT ALL 83 + col1 FROM tab2 AS cor0
----
100
114
142

onlyif mysql # use DIV operator for integer division
query I rowsort label-2035
SELECT ALL cor0.col2 DIV col1 + - 37 * - col2 AS col2 FROM tab1 AS cor0
----
2000
2114
3559

skipif mysql # not compatible
query I rowsort label-2035
SELECT ALL cor0.col2 / col1 + - 37 * - col2 AS col2 FROM tab1 AS cor0
----
2000
2114
3559

query I rowsort
SELECT ALL - 31 + col2 FROM tab1 AS cor0
----
23
26
65

query I rowsort
SELECT ALL + col2 + cor0.col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-2038
SELECT DISTINCT - cor0.col0 DIV col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2038
SELECT DISTINCT - cor0.col0 / col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + col1 * col1 * col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT DISTINCT + - col1 + 56 * - 97 AS col0 FROM tab1 AS cor0
----
-5442
-5445
-5458

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col0 + cor0.col2 col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL - + col2 * col0 * col2 FROM tab1 cor0
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT - col2 + - ( + 44 ) FROM tab0 AS cor0
----
-126
-45
-77

query I rowsort
SELECT ALL col2 - + col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col0 * col0 * col2 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL + col1 * 89 * - 96 - + col1 FROM tab2 cor0
----
-145265
-264895
-504155

query I rowsort
SELECT DISTINCT - col2 + 6 + - col0 * + col1 FROM tab1 AS cor0
----
-1130
-126
-691

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - - col0 + + col1 * - 37 + - col0 FROM tab0 AS cor0
----
-3182
-3367
-3589

query I rowsort
SELECT DISTINCT + + cor0.col1 * 24 FROM tab1 AS cor0
----
240
312
624

onlyif mysql # use DIV operator for integer division
query I rowsort label-2051
SELECT - - cor0.col2 DIV - 36 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2051
SELECT - - cor0.col2 / - 36 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT - col2 + + col2 + 27 FROM tab2 AS cor0
----
27
27
27

query I rowsort
SELECT ALL - - col2 * + cor0.col0 * col1 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT col1 + col0 * 29 + + col0 * col0 FROM tab2
----
283
8405
8549

query I rowsort
SELECT DISTINCT - 86 + tab1.col2 * col0 FROM tab1
----
3562
7594
76

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab2, tab1 cor1
----
972 values hashing to 4634d10e8b6b37510bb99745aade36ab

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2057
SELECT ALL col1 + CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2057
SELECT ALL col1 + CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2058
SELECT DISTINCT - + col2 DIV col2 + + col2 FROM tab0 cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-2058
SELECT DISTINCT - + col2 / col2 + + col2 FROM tab0 cor0
----
0
32
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 * + col1 - col1 col0 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT col2 + col1 * + tab0.col2 AS col2 FROM tab0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2061
SELECT DISTINCT + col0 DIV + 13 AS col2 FROM tab1
----
0
4
6

skipif mysql # not compatible
query I rowsort label-2061
SELECT DISTINCT + col0 / + 13 AS col2 FROM tab1
----
0
4
6

query I rowsort
SELECT 23 * + ( - col0 ) AS col2 FROM tab0 AS cor0
----
-2047
-552
-805

query I rowsort
SELECT DISTINCT + col1 + col1 + col1 * + col0 FROM tab0
----
2236
3589
8281

query I rowsort
SELECT DISTINCT col0 * ( - 5 ) + - col0 FROM tab2
----
-42
-468
-474

query I rowsort
SELECT tab1.col1 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT 79 FROM tab0, tab2, tab0 AS cor0, tab1
----
79

query I rowsort
SELECT ALL tab2.col0 * ( - col2 + col1 ) AS col1 FROM tab2
----
-1659
2574
28

query I rowsort
SELECT DISTINCT tab1.col1 * col0 AS col0 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 91 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

query I rowsort
SELECT cor1.col2 AS col1 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col2 col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT 62 + - col1 - + col1 FROM tab1
----
10
36
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + col0 col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT - 23 + - col0 - - ( col1 + - col2 ) FROM tab1 AS cor0
----
-134
-186
-54

query I rowsort
SELECT DISTINCT + col0 * + col0 + + ( ( + col0 ) * col0 ) FROM tab1 cor0
----
12800
18
8192

query I rowsort
SELECT - ( - col0 ) + 12 * - col2 FROM tab0 AS cor0
----
-372
-895
23

query I rowsort
SELECT ALL - - cor0.col1 * - col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + 33 * - col2 + 22 * - col2 FROM tab1 AS cor0
----
-2970
-3135
-5280

query I rowsort
SELECT DISTINCT col2 - 75 AS col1 FROM tab0
----
-42
-74
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2080
SELECT ALL ( + 81 ) DIV - tab1.col2 - 62 DIV + col0 AS col0 FROM tab1
----
-1
-21
0

skipif mysql # not compatible
query I rowsort label-2080
SELECT ALL ( + 81 ) / - tab1.col2 - 62 / + col0 AS col0 FROM tab1
----
-1
-21
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2081
SELECT + tab0.col0 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2081
SELECT + tab0.col0 / col1 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2082
SELECT DISTINCT + ( + col1 ) * CAST( NULL AS DECIMAL ) * - col2 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2082
SELECT DISTINCT + ( + col1 ) * CAST ( NULL AS REAL ) * - col2 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col2 + - col0 * 65 FROM tab2 AS cor0
----
-428
-5044
-5097

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + + col0 * + col0 col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL + + 31 FROM tab1 AS cor0
----
31
31
31

query I rowsort
SELECT + 57 * - col0 - + col1 AS col0 FROM tab2 AS cor0
----
-430
-4505
-4520

query I rowsort
SELECT DISTINCT - col0 * col0 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT - 41 * + col1 + col2 AS col2 FROM tab2 AS cor0
----
-1244
-2393
-659

query I rowsort
SELECT ALL - col2 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - + 56 * + col0 + col2 * + 25 AS col1 FROM tab2 AS cor0
----
-3474
-3718
283

query I rowsort
SELECT DISTINCT + - cor0.col0 + cor0.col2 AS col0 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT + col0 * - tab2.col1 FROM tab2
----
-1343
-217
-4602

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col1 * + col0 * col0 = col2 / + col0
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT - col0 + - tab2.col0 * - col0 FROM tab2
----
42
6006
6162

query III rowsort
SELECT * FROM tab0 WHERE ( - col2 ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT col2 + - tab1.col1 * col2 AS col0 FROM tab1
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-2097
SELECT col2 DIV + col2 col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2097
SELECT col2 / + col2 col0 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT tab2.col0 FROM tab2, tab0 cor0
----
7
78
79

query I rowsort
SELECT ALL + 60 + + col2 FROM tab0
----
142
61
93

query I rowsort
SELECT ALL - - cor0.col2 AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT col1 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT ( col2 ) * col2 * + col1 AS col2 FROM tab2
----
22599
24548
39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2103
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2103
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 - + col1 * 44 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT DISTINCT - 9 AS col0 FROM tab2
----
-9

query I rowsort
SELECT 26 AS col1 FROM tab2
----
26
26
26

query I rowsort
SELECT - 60 AS col0 FROM tab1
----
-60
-60
-60

query I rowsort
SELECT + col2 * col0 AS col2 FROM tab1 WHERE ( - col1 ) IN ( - col0 * + col1 )
----

query I rowsort
SELECT ALL col0 - + col1 AS col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT + col0 * - col1 / - col0 FROM tab0 WHERE NOT ( NULL ) > ( NULL )
----

query I rowsort
SELECT ALL + col1 + + col0 * + col0 * col0 FROM tab1
----
262154
512013
53

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col0 + col0 > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 * tab0.col2 col0 FROM tab0
----
1
35937
551368

query I rowsort
SELECT + col2 * col1 + - col2 AS col2 FROM tab0
----
2805
7380
96

query I rowsort
SELECT col2 + tab1.col1 * + col1 FROM tab1
----
157
265
730

query I rowsort
SELECT ALL col1 - col2 AS col0 FROM tab2
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2117
SELECT DISTINCT tab1.col2 - + col2 DIV - col2 AS col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-2117
SELECT DISTINCT tab1.col2 - + col2 / - col2 AS col2 FROM tab1
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 + col0 col0 FROM tab0
----
1260
600
8010

query I rowsort
SELECT + tab0.col2 + col2 AS col1 FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT col2 * - col2 + - col0 * col1 AS col2 FROM tab2
----
-2787
-5278
-946

query I rowsort
SELECT DISTINCT col1 - - col2 * + col1 FROM tab1
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + + col0 col0 FROM tab2
----
104
117
34

query I rowsort
SELECT + col1 AS col1 FROM tab0 WHERE NOT col1 <> ( NULL )
----

query I rowsort
SELECT ALL + col1 + col2 * - tab2.col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT col0 + col1 * + col1 FROM tab0
----
7420
8370
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT col1 + col2 AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL col1 - col0 AS col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT DISTINCT col0 + col2 * - col2 AS col1 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT DISTINCT 50 FROM tab2
----
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col0 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL 1 AS col1 FROM tab2
----
1
1
1

query I rowsort
SELECT + + 48 * - col2 FROM tab0 AS cor0
----
-1584
-3936
-48

query I rowsort
SELECT ALL - - 28 * col1 AS col2 FROM tab2 AS cor0
----
1652
476
868

query I rowsort
SELECT DISTINCT + + cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT cor0.col0 * col0 AS col2 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2137
SELECT + col0 * - col1 + 35 DIV - col0 FROM tab2 AS cor0
----
-1343
-222
-4602

skipif mysql # not compatible
query I rowsort label-2137
SELECT + col0 * - col1 + 35 / - col0 FROM tab2 AS cor0
----
-1343
-222
-4602

query I rowsort
SELECT DISTINCT - - col1 * + cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - col0 * col1 - + 36 FROM tab0 AS cor0
----
-2100
-3431
-8135

query I rowsort
SELECT ALL 54 + col1 FROM tab2 cor0
----
113
71
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2141
SELECT - col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2141
SELECT - col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2142
SELECT + col1 DIV - col0 + col2 FROM tab0 AS cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-2142
SELECT + col1 / - col0 + col2 FROM tab0 AS cor0
----
-1
30
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2143
SELECT + col1 + CAST( + col0 AS SIGNED ) FROM tab1 cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-2143
SELECT + col1 + CAST ( + col0 AS INTEGER ) FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT col2 * cor0.col1 * col1 + - col0 AS col0 FROM tab1 AS cor0
----
16144
36501
5636

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2145
SELECT - cor0.col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2145
SELECT - cor0.col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2146
SELECT + col1 DIV - col1 + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-2146
SELECT + col1 / - col1 + col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT + - col1 + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2148
SELECT ALL col2 + + 58 * cor0.col2 DIV ( col1 ) FROM tab1 AS cor0
----
174
387
524

skipif mysql # not compatible
query I rowsort label-2148
SELECT ALL col2 + + 58 * cor0.col2 / ( col1 ) FROM tab1 AS cor0
----
174
387
524

query I rowsort
SELECT DISTINCT + + col2 * + col2 - col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT - 13 + ( + col1 ) AS col2 FROM tab0 AS cor0
----
73
78
84

query I rowsort
SELECT - col2 * col0 + cor0.col1 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 97 col2 FROM tab0
----
-8342
-8827
-9409

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2, tab1 AS cor3
----
3645 values hashing to 29937e0f604055b7324ce0c354a5e778

query I rowsort
SELECT ALL - cor2.col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to c569638e8a09ff819458d62ddbde994c

onlyif mysql # use DIV operator for integer division
query I rowsort label-2155
SELECT DISTINCT 76 DIV + 72 FROM tab1, tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2155
SELECT DISTINCT 76 / + 72 FROM tab1, tab1 AS cor0
----
1

query I rowsort
SELECT DISTINCT + + col2 * + col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - + col0 * col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - col1 * - col2 * + cor0.col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL + - col2 * - cor0.col2 + - cor0.col0 * + col0 FROM tab2 AS cor0
----
-4797
-5408
680

query I rowsort
SELECT - - 26 + col0 + - col0 AS col1 FROM tab0 AS cor0
----
26
26
26

query I rowsort
SELECT DISTINCT + col1 + + cor0.col0 * + cor0.col0 * + col2 FROM tab1 AS cor0
----
233482
512
614413

query I rowsort
SELECT ALL + col0 + col1 * + col0 AS col1 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT ALL col2 * - col2 * - col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT ALL 42 FROM tab2 AS cor0
----
42
42
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-2165
SELECT - + col0 DIV col1 + + col2 + - col0 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-2165
SELECT - + col0 / col1 + + col2 + - col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col1 + + 75 AS col1 FROM tab2
----
106
134
92

query I rowsort
SELECT DISTINCT 8 * - col2 * col1 + + col2 * col1 FROM tab1
----
-3990
-8736
-9828

query I rowsort
SELECT cor0.col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # use DIV operator for integer division
query I rowsort label-2169
SELECT ALL - ( col2 ) DIV col0 + + col1 AS col0 FROM tab2
----
17
28
59

skipif mysql # not compatible
query I rowsort label-2169
SELECT ALL - ( col2 ) / col0 + + col1 AS col0 FROM tab2
----
17
28
59

query I rowsort
SELECT + 71 + + col0 + + col1 * col0 AS col2 FROM tab2
----
1493
295
4751

query I rowsort
SELECT DISTINCT tab0.col0 + + col1 * tab0.col2 + + col1 * col1 FROM tab0
----
10258
15832
9541

query I rowsort
SELECT ALL - col2 + col0 AS col1 FROM tab0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2173
SELECT DISTINCT + 48 DIV 37 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-2173
SELECT DISTINCT + 48 / 37 FROM tab0
----
1

query I rowsort
SELECT DISTINCT + 36 * + col2 AS col2 FROM tab1
----
1944
2052
3456

query I rowsort
SELECT DISTINCT + - 5 * cor0.col1 + + cor0.col1 FROM tab2 AS cor0
----
-124
-236
-68

query I rowsort
SELECT col2 * - col0 + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL + + 43 AS col2 FROM tab1 AS cor0
----
43
43
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 2 col1 FROM tab0 AS cor0
----
-2
-2
-2

query I rowsort
SELECT DISTINCT - col2 + col2 * col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT - + ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + 62 * + col2 + + tab2.col1 AS col0 FROM tab2
----
1671
1705
2373

query I rowsort
SELECT tab2.col0 * + col2 * 22 - col0 FROM tab2
----
4151
44538
65965

query I rowsort
SELECT - - cor0.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT col1 * ( + col0 + col2 ) FROM tab2
----
1054
1989
6136

query I rowsort
SELECT + + 72 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

onlyif mysql # use DIV operator for integer division
query I rowsort label-2186
SELECT + cor0.col2 DIV - col0 col2 FROM tab2 cor0
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2186
SELECT + cor0.col2 / - col0 col2 FROM tab2 cor0
----
-3
0
0

query I rowsort
SELECT + - col2 + - col0 * - col2 - - col1 FROM tab1 AS cor0
----
134
3601
7597

query I rowsort
SELECT - col2 + 49 * ( col1 ) AS col0 FROM tab2 cor0
----
1492
2865
795

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 + + col0 - + col0 col2 FROM tab2
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2190
SELECT - col0 DIV col1 col2 FROM tab1
----
-6
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2190
SELECT - col0 / col1 col2 FROM tab1
----
-6
-6
0

query I rowsort
SELECT DISTINCT tab2.col0 - - col1 AS col1 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2192
SELECT + ( col0 ) DIV - col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2192
SELECT + ( col0 ) / - col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT cor0.col0 + + cor0.col0 * - col2 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2194
SELECT ALL + + CAST( + cor0.col0 AS SIGNED ) * col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-2194
SELECT ALL + + CAST ( + cor0.col0 AS INTEGER ) * col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2195
SELECT - CAST( + 0 AS SIGNED ) + + col1 AS col0 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2195
SELECT - CAST ( + 0 AS INTEGER ) + + col1 AS col0 FROM tab0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 90 * - col2 * col2 + col2 col0 FROM tab0
----
-605078
-89
-97977

onlyif mysql # use DIV operator for integer division
query I rowsort label-2197
SELECT DISTINCT - ( 81 ) DIV col0 + tab1.col0 col1 FROM tab1
----
-24
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2197
SELECT DISTINCT - ( 81 ) / col0 + tab1.col0 col1 FROM tab1
----
-24
63
79

query I rowsort
SELECT ALL - col1 + col0 * col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT - col1 * + col1 * + col0 FROM tab0 cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL + - 82 + - col2 AS col2 FROM tab1 AS cor0
----
-136
-139
-178

onlyif mysql # use DIV operator for integer division
query I rowsort label-2201
SELECT ALL - cor0.col1 DIV col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-2201
SELECT ALL - cor0.col1 / col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT - 79 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

query I rowsort
SELECT ( col0 ) * col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL - 9 + ( - col2 ) AS col1 FROM tab0 AS cor0
----
-10
-42
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-2205
SELECT + col2 DIV + tab0.col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2205
SELECT + col2 / + tab0.col1 AS col0 FROM tab0
----
0
0
0

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT BETWEEN NULL AND ( col0 )
----

query I rowsort
SELECT ALL + col1 * col2 * - tab1.col1 + + tab1.col2 AS col2 FROM tab1
----
-16128
-36450
-5643

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col2 col0 FROM tab1
----
109
67
80

query I rowsort
SELECT col2 * col0 + cor0.col0 * + col2 AS col2 FROM tab0 cor0
----
14596
1584
70

query I rowsort
SELECT - - col2 * - col2 - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT DISTINCT + col0 + - col0 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + cor0.col2 * col2 + col0 AS col0 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-2213
SELECT ALL - col2 * + col2 + + col1 DIV - col1 FROM tab1 AS cor0
----
-2917
-3250
-9217

skipif mysql # not compatible
query I rowsort label-2213
SELECT ALL - col2 * + col2 + + col1 / - col1 FROM tab1 AS cor0
----
-2917
-3250
-9217

query I rowsort
SELECT DISTINCT - col1 * col2 + col0 + col0 * + col0 FROM tab1 AS cor0
----
-1392
3590
5232

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * col1 * + cor0.col2 col0 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - - col2 - col2 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col0 col0 FROM tab2 AS cor0
----
14
156
158

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE NOT NULL IN ( - col0 + + col0 / col1 )
----

query I rowsort
SELECT DISTINCT + col1 + cor0.col0 + col1 * cor0.col1 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-16131
-36475
-5626

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + cor0.col2 col0 FROM tab0 AS cor0
----
164
2
66

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT col2 >= col1
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT - col0 * - tab2.col1 * col1 FROM tab2
----
22831
271518
6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 + col1 col1 FROM tab2
----
111
85
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + tab2.col1 * col2 + col2 AS col1 FROM tab2
----
1560
684
864

query I rowsort
SELECT DISTINCT col1 * col2 AS col2 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2227
SELECT ALL cor0.col1 + cor0.col2 DIV col0 AS col1 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-2227
SELECT ALL cor0.col1 + cor0.col2 / col0 AS col1 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT DISTINCT + + cor0.col0 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-2229
SELECT DISTINCT - col2 DIV col2 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2229
SELECT DISTINCT - col2 / col2 AS col0 FROM tab1 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2230
SELECT + cor0.col1 DIV - col2 AS col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2230
SELECT + cor0.col1 / - col2 AS col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2231
SELECT - - col0 DIV - col0 AS col0 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2231
SELECT - - col0 / - col0 AS col0 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - tab2.col2 * + col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL + col1 * cor0.col1 + - col0 AS col1 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT ALL col0 * - col1 + - col1 * + col0 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-2669
-403
-9145

query I rowsort
SELECT + tab2.col1 - col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL tab1.col0 * col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT - col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - - col0 * ( - cor0.col0 + col1 ) AS col1 FROM tab2 AS cor0
----
-1482
-4898
168

query I rowsort
SELECT + cor0.col2 + ( - 97 ) AS col1 FROM tab1 AS cor0
----
-1
-40
-43

query I rowsort
SELECT - 66 FROM tab0 AS cor0
----
-66
-66
-66

query I rowsort
SELECT - 13 + + col2 FROM tab0 AS cor0
----
-12
20
69

query I rowsort
SELECT ALL + 49 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

onlyif mysql # use DIV operator for integer division
query I rowsort label-2243
SELECT + + col2 DIV - col1 AS col0 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2243
SELECT + + col2 / - col1 AS col0 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT + col2 + - col2 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 43 * col1 FROM tab2 cor0
----
1333
2537
731

query I rowsort
SELECT col1 + col2 * 37 AS col2 FROM tab2 AS cor0
----
1021
1030
1423

onlyif mysql # use DIV operator for integer division
query I rowsort label-2247
SELECT + col2 DIV col2 col1 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2247
SELECT + col2 / col2 col1 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2248
SELECT - col0 + + 6 DIV - col0 AS col2 FROM tab1
----
-5
-64
-80

skipif mysql # not compatible
query I rowsort label-2248
SELECT - col0 + + 6 / - col0 AS col2 FROM tab1
----
-5
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2249
SELECT col0 DIV + col1 + - tab0.col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2249
SELECT col0 / + col1 + - tab0.col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT - 96 + tab2.col2 + + col2 FROM tab2
----
-20
-42
-44

onlyif mysql # use DIV operator for integer division
query I rowsort label-2251
SELECT DISTINCT + col1 + col2 DIV - col1 + col1 * + col1 * + col0 FROM tab1
----
13526
2052
6405

skipif mysql # not compatible
query I rowsort label-2251
SELECT DISTINCT + col1 + col2 / - col1 + col1 * + col1 * + col0 FROM tab1
----
13526
2052
6405

query I rowsort
SELECT ALL tab2.col1 + + 21 * col1 AS col1 FROM tab2
----
1298
374
682

query I rowsort
SELECT DISTINCT + 96 + cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
129
178
97

query I rowsort
SELECT ( - col0 ) * - 64 FROM tab2 AS cor0
----
448
4992
5056

query I rowsort
SELECT DISTINCT - 2 * col1 AS col2 FROM tab1 AS cor0
----
-20
-26
-52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2256
SELECT + + 84 * + cor0.col1 * + ( col2 + col0 * - CAST( NULL AS SIGNED ) ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2256
SELECT + + 84 * + cor0.col1 * + ( col2 + col0 * - CAST ( NULL AS INTEGER ) ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 * - cor0.col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + + cor0.col1 + col0 * 36 FROM tab2 AS cor0
----
283
2861
2867

query I rowsort
SELECT DISTINCT - col2 + col1 AS col1 FROM tab0 cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2260
SELECT 88 + - col1 DIV + col0 FROM tab2 AS cor0
----
84
88
88

skipif mysql # not compatible
query I rowsort label-2260
SELECT 88 + - col1 / + col0 FROM tab2 AS cor0
----
84
88
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2261
SELECT - col1 * + col2 + CAST( col1 AS SIGNED ) AS col0 FROM tab0
----
-2752
-7371
0

skipif mysql # not compatible
query I rowsort label-2261
SELECT - col1 * + col2 + CAST ( col1 AS INTEGER ) AS col0 FROM tab0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2262
SELECT col0 DIV + col1 col0 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2262
SELECT col0 / + col1 col0 FROM tab2
----
0
1
4

query I rowsort
SELECT col0 * - col1 * + tab1.col1 AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT + col0 * + col0 + col2 AS col2 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2265
SELECT cor0.col1 * CAST( + col0 AS SIGNED ) FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-2265
SELECT cor0.col1 * CAST ( + col0 AS INTEGER ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + - col2 + + 3 AS col2 FROM tab1 cor0
----
-51
-54
-93

query I rowsort
SELECT - col0 - + cor0.col0 * - 99 AS col0 FROM tab0 AS cor0
----
2352
3430
8722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col1 col2 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2269
SELECT ( col0 ) DIV col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2269
SELECT ( col0 ) / col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT - 22 - 49 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to 3907e0aa4f29c002120742c4abb3e23a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT + 47 FROM tab0, tab1 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT + col1 * + 48 AS col1 FROM tab2 AS cor0
----
1488
2832
816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2274
SELECT col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2274
SELECT col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab0.col2 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2276
SELECT + + CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2276
SELECT + + CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + col1 * - 63 FROM tab2 AS cor0
----
-1071
-1953
-3717

query I rowsort
SELECT ALL + ( - col1 ) * col1 - - col0 AS col0 FROM tab1 cor0
----
-36
-673
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2279
SELECT ALL - + CAST( ( col2 ) AS SIGNED ) * col0 + + cor0.col2 * - col2 FROM tab1 AS cor0
----
-16896
-3078
-6897

skipif mysql # not compatible
query I rowsort label-2279
SELECT ALL - + CAST ( ( col2 ) AS INTEGER ) * col0 + + cor0.col2 * - col2 FROM tab1 AS cor0
----
-16896
-3078
-6897

query I rowsort
SELECT - 86 * col1 FROM tab1 cor0
----
-1118
-2236
-860

query I rowsort
SELECT - 46 + + col0 * ( + 45 ) AS col2 FROM tab2 AS cor0
----
269
3464
3509

query I rowsort
SELECT DISTINCT + col1 + col2 * - tab1.col2 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT 17 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT 36 * + col0 AS col1 FROM tab2 AS cor0
----
252
2808
2844

query I rowsort
SELECT ALL + ( col2 ) * - col0 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2286
SELECT DISTINCT - col0 DIV ( - col2 + - 68 ) FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2286
SELECT DISTINCT - col0 / ( - col2 + - 68 ) FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col0 ) col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - - col0 * - col1 + col1 - - col2 * - cor0.col1 * col1 FROM tab2 cor0
----
-12308
-26133
-95049

query I rowsort
SELECT DISTINCT - 79 + cor0.col0 * - col2 AS col2 FROM tab1 AS cor0
----
-241
-3727
-7759

query I rowsort
SELECT - col0 + + cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - ( - cor0.col2 ) FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2292
SELECT + 32 DIV + 12 AS col2 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-2292
SELECT + 32 / + 12 AS col2 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT ALL + 64 AS col1 FROM tab0 AS cor0
----
64
64
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2294
SELECT DISTINCT CAST( + col2 AS SIGNED ) * + col2 col2 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2294
SELECT DISTINCT CAST ( + col2 AS INTEGER ) * + col2 col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - col0 * + cor0.col1 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT 26 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
26

query I rowsort
SELECT ALL ( 40 ) AS col0 FROM tab0 AS cor0
----
40
40
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2298
SELECT - CAST( - col2 AS SIGNED ) + col1 - 5 FROM tab2 AS cor0
----
50
53
80

skipif mysql # not compatible
query I rowsort label-2298
SELECT - CAST ( - col2 AS INTEGER ) + col1 - 5 FROM tab2 AS cor0
----
50
53
80

query I rowsort
SELECT ALL - col0 * col2 * col2 FROM tab0 cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT - col0 * 93 FROM tab0 cor0
----
-2232
-3255
-8277

query I rowsort
SELECT ALL 13 * + col1 + - col1 FROM tab0 AS cor0
----
1032
1092
1164

query I rowsort
SELECT + - ( - 7 ) + col2 + col2 FROM tab2 AS cor0
----
59
61
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + 16 ) col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 71c8b08964ab47ce12158975c0ee1fd9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2304
SELECT - 62 + col1 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2304
SELECT - 62 + col1 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * col0 * tab0.col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT ( - 89 ) + - tab2.col2 FROM tab2
----
-115
-116
-127

query I rowsort
SELECT - - col1 * - col2 * - col2 + col2 AS col0 FROM tab1 AS cor0
----
119904
32547
75870

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0 CROSS JOIN tab2, tab1 AS cor1
----
972 values hashing to 92235dbc382d83baa93d6546ed489b0c

query I rowsort
SELECT ALL - tab2.col2 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT - cor0.col1 + 80 * ( - col2 * col2 ) AS col2 FROM tab0 AS cor0
----
-177
-538011
-87206

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2311
SELECT - col0 * - CAST( 22 AS SIGNED ) FROM tab2 AS cor0
----
154
1716
1738

skipif mysql # not compatible
query I rowsort label-2311
SELECT - col0 * - CAST ( 22 AS INTEGER ) FROM tab2 AS cor0
----
154
1716
1738

query I rowsort
SELECT cor0.col0 + ( - 41 ) * col2 AS col0 FROM tab1 AS cor0
----
-2211
-2273
-3856

query I rowsort
SELECT ALL 20 * col0 FROM tab0
----
1780
480
700

query I rowsort
SELECT + col1 + + col1 * + col2 FROM tab0
----
194
2924
7553

query I rowsort
SELECT 31 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT DISTINCT - col1 + - col0 - + col2 FROM tab1
----
-131
-189
-83

query I rowsort
SELECT + 12 + 23 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT - col2 + col1 * - 2 FROM tab2 AS cor0
----
-144
-72
-89

query I rowsort
SELECT ALL col1 * ( 33 ) FROM tab2
----
1023
1947
561

onlyif mysql # use DIV operator for integer division
query I rowsort label-2320
SELECT ALL + tab1.col2 * col0 DIV 83 FROM tab1
----
1
43
92

skipif mysql # not compatible
query I rowsort label-2320
SELECT ALL + tab1.col2 * col0 / 83 FROM tab1
----
1
43
92

query I rowsort
SELECT DISTINCT + + col0 * - 24 + - col2 AS col1 FROM tab1 AS cor0
----
-126
-1593
-2016

query I rowsort
SELECT ALL - col1 * col0 + - 29 AS col2 FROM tab1 cor0
----
-1069
-107
-669

query I rowsort
SELECT DISTINCT col1 + + col0 + cor0.col2 AS col0 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT DISTINCT + ( + 43 ) FROM tab0, tab0 AS cor0
----
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-2325
SELECT DISTINCT + tab0.col2 * col1 DIV - tab0.col0 FROM tab0
----
-118
-2
-83

skipif mysql # not compatible
query I rowsort label-2325
SELECT DISTINCT + tab0.col2 * col1 / - tab0.col0 FROM tab0
----
-118
-2
-83

query I rowsort
SELECT ALL - 18 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

onlyif mysql # use DIV operator for integer division
query I rowsort label-2327
SELECT - + col0 DIV col1 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2327
SELECT - + col0 / col1 FROM tab2 cor0
----
-1
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2328
SELECT ALL cor0.col0 + col0 + col0 DIV 43 col1 FROM tab1 AS cor0
----
129
161
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2328
SELECT ALL cor0.col0 + col0 + col0 / 43 col1 FROM tab1 AS cor0
----
129
161
6

query I rowsort
SELECT DISTINCT col1 * - 75 * col1 + 53 FROM tab1 AS cor0
----
-12622
-50647
-7447

query I rowsort
SELECT + 19 * - col2 - col0 FROM tab2 AS cor0
----
-520
-572
-801

query I rowsort
SELECT DISTINCT + tab2.col2 AS col0 FROM tab2, tab0 AS cor0
----
26
27
38

query I rowsort
SELECT + ( col0 ) * + col1 + + col2 + 57 * col2 FROM tab2
----
1783
3547
6110

query I rowsort
SELECT 98 * col1 FROM tab0
----
8428
8918
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2334
SELECT DISTINCT - 7 DIV col2 AS col0 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-2334
SELECT DISTINCT - 7 / col2 AS col0 FROM tab1
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2335
SELECT + col2 + ( + col2 ) DIV - col1 col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2335
SELECT + col2 + ( + col2 ) / - col1 col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT 34 * 85 FROM tab2 AS cor0
----
2890

query I rowsort
SELECT ALL + col2 + + ( + col1 ) AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT cor0.col2 AS col2 FROM tab1, tab2, tab1 cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2339
SELECT col2 DIV - col1 + col0 AS col2 FROM tab2
----
7
77
78

skipif mysql # not compatible
query I rowsort label-2339
SELECT col2 / - col1 + col0 AS col2 FROM tab2
----
7
77
78

query I rowsort
SELECT DISTINCT - - col2 * col0 + - col2 * + col0 FROM tab1 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2341
SELECT DISTINCT + col2 * + col1 + - CAST( NULL AS SIGNED ) col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2341
SELECT DISTINCT + col2 * + col1 + - CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col0 + col1 * + col0 AS col0 FROM tab1 AS cor0
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2343
SELECT ALL + cor0.col2 DIV col1 AS col0 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2343
SELECT ALL + cor0.col2 / col1 AS col0 FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + + col2 * + col2 col0 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT - - col1 * cor0.col0 * cor0.col0 AS col0 FROM tab0 AS cor0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-2346
SELECT - col0 * - cor0.col0 + - cor0.col1 DIV - 77 AS col1 FROM tab0 AS cor0
----
1226
577
7922

skipif mysql # not compatible
query I rowsort label-2346
SELECT - col0 * - cor0.col0 + - cor0.col1 / - 77 AS col1 FROM tab0 AS cor0
----
1226
577
7922

onlyif mysql # use DIV operator for integer division
query I rowsort label-2347
SELECT ALL - + col0 DIV - CAST( col0 AS SIGNED ) + + col1 FROM tab1 cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-2347
SELECT ALL - + col0 / - CAST ( col0 AS INTEGER ) + + col1 FROM tab1 cor0
----
11
14
27

query I rowsort
SELECT ALL - col2 * col1 - col1 AS col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT + col0 - - ( - ( + col1 ) ) * - col0 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + cor0.col1 * 53 FROM tab2 AS cor0
----
1643
3127
901

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2351
SELECT ALL col1 + cor0.col2 + - 13 * - col0 * CAST( 82 AS SIGNED ) FROM tab2 AS cor0
----
7520
83233
84269

skipif mysql # not compatible
query I rowsort label-2351
SELECT ALL col1 + cor0.col2 + - 13 * - col0 * CAST ( 82 AS INTEGER ) FROM tab2 AS cor0
----
7520
83233
84269

query I rowsort
SELECT - col1 + ( 51 ) * - col1 AS col2 FROM tab0 cor0
----
-4472
-4732
-5044

query I rowsort
SELECT DISTINCT - col0 * - col0 + + 1 AS col2 FROM tab1 cor0
----
10
4097
6401

query I rowsort
SELECT ALL + + col1 * + col2 + - col2 FROM tab2 AS cor0
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-2355
SELECT DISTINCT - col1 DIV 61 + + 44 + col1 AS col0 FROM tab1 cor0
----
54
57
70

skipif mysql # not compatible
query I rowsort label-2355
SELECT DISTINCT - col1 / 61 + + 44 + col1 AS col0 FROM tab1 cor0
----
54
57
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * + col1 - + 35 col1 FROM tab1 AS cor0
----
1213
1369
535

query I rowsort
SELECT 75 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT col2 + col2 * ( - 11 * - col2 ) FROM tab0
----
12
12012
74046

query I rowsort
SELECT 93 + + col1 FROM tab2
----
110
124
152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 69 + + col2 col1 FROM tab2
----
107
95
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col1 col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT tab1.col1 FROM tab1, tab0 cor0, tab2, tab2 AS cor1
----
10
13
26

query I rowsort
SELECT - + 33 - col0 FROM tab0 cor0
----
-122
-57
-68

query I rowsort
SELECT ALL + cor0.col2 * col1 + col2 + + col0 AS col2 FROM tab2 AS cor0
----
1638
763
871

query I rowsort
SELECT - 29 * col1 FROM tab2 AS cor0
----
-1711
-493
-899

query I rowsort
SELECT + 14 * - col1 AS col1 FROM tab2 AS cor0
----
-238
-434
-826

query I rowsort
SELECT + + col2 * - cor0.col0 + col1 + col0 FROM tab2 AS cor0
----
-151
-1891
-2906

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 5 col2 FROM tab0
----
5

query I rowsort
SELECT 53 FROM tab2, tab0 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2370
SELECT + col1 * col2 + - CAST( NULL AS SIGNED ) + ( + col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2370
SELECT + col1 * col2 + - CAST ( NULL AS INTEGER ) + ( + col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * - col1 + + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT col1 * cor0.col0 AS col0 FROM tab1 cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2373
SELECT DISTINCT + col2 DIV + cor0.col0 + col2 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-2373
SELECT DISTINCT + col2 / + cor0.col0 + col2 FROM tab2 AS cor0
----
26
30
38

query I rowsort
SELECT ALL + cor0.col0 * 70 - col1 AS col2 FROM tab1 AS cor0
----
184
4470
5587

query I rowsort
SELECT ALL + 34 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

onlyif mysql # use DIV operator for integer division
query I rowsort label-2376
SELECT col0 DIV - tab2.col0 AS col1 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2376
SELECT col0 / - tab2.col0 AS col1 FROM tab2
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2377
SELECT + + col1 * CAST( - col2 AS SIGNED ) * - col1 FROM tab2 AS cor0
----
10982
25947
90506

skipif mysql # not compatible
query I rowsort label-2377
SELECT + + col1 * CAST ( - col2 AS INTEGER ) * - col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT - col1 * - col1 + - col0 AS col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT + cor0.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - col1 col2 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT ( 33 ) * cor0.col2 AS col2 FROM tab0, tab2 AS cor0
----
1254
858
891

query I rowsort
SELECT - + col0 * 69 - col2 * col1 FROM tab2 AS cor0
----
-1320
-6097
-6916

query I rowsort
SELECT - col0 * col0 * - col0 + - col0 AS col2 FROM tab2 AS cor0
----
336
474474
492960

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - col1 AS REAL ) * - col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + col2 - + 58 FROM tab2 AS cor0
----
-20
-31
-32

onlyif mysql # use DIV operator for integer division
query I rowsort label-2386
SELECT - 95 + 95 DIV col1 AS col1 FROM tab0 AS cor0
----
-94
-94
-95

skipif mysql # not compatible
query I rowsort label-2386
SELECT - 95 + 95 / col1 AS col1 FROM tab0 AS cor0
----
-94
-94
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2387
SELECT - col2 DIV + ( col0 + - col2 ) AS col2 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2387
SELECT - col2 / + ( col0 + - col2 ) AS col2 FROM tab2
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2388
SELECT col1 * - col1 * tab2.col2 + col1 DIV 82 + + col0 * tab2.col0 AS col0 FROM tab2
----
-25898
-4741
-84422

skipif mysql # not compatible
query I rowsort label-2388
SELECT col1 * - col1 * tab2.col2 + col1 / 82 + + col0 * tab2.col0 AS col0 FROM tab2
----
-25898
-4741
-84422

onlyif mysql # use DIV operator for integer division
query I rowsort label-2389
SELECT DISTINCT + 39 DIV col0 AS col1 FROM tab1 AS cor0
----
0
13

skipif mysql # not compatible
query I rowsort label-2389
SELECT DISTINCT + 39 / col0 AS col1 FROM tab1 AS cor0
----
0
13

query I rowsort
SELECT cor0.col1 * + col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + + 29 FROM tab1 AS cor0
----
29
29
29

query I rowsort
SELECT DISTINCT + - col0 + + ( col1 ) AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + cor0.col2 + + col0 * col0 AS col2 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT 75 AS col0 FROM tab2
----
75
75
75

query I rowsort
SELECT - 93 + - cor0.col0 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d5b94378377ee56942408a741b0fe3c7

query I rowsort
SELECT + - col0 * + col1 + - col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT - col2 + cor0.col0 * cor0.col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT + 92 AS col0 FROM tab2 AS cor0
----
92

query I rowsort
SELECT + - cor0.col1 - - col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + col2 + cor0.col1 * + col2 AS col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL ( col0 ) - + col1 FROM tab2
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2402
SELECT DISTINCT - col1 * tab0.col1 + + col2 / - CAST( NULL AS SIGNED ) - + col0 * col1 AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2402
SELECT DISTINCT - col1 * tab0.col1 + + col2 / - CAST ( NULL AS INTEGER ) - + col0 * col1 AS col0 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT + tab1.col2 * + 64 FROM tab1
----
3456
3648
6144

onlyif mysql # use DIV operator for integer division
query I rowsort label-2404
SELECT + ( 1 + - tab2.col2 ) DIV 14 AS col2 FROM tab2
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-2404
SELECT + ( 1 + - tab2.col2 ) / 14 AS col2 FROM tab2
----
-1
-1
-2

query I rowsort
SELECT DISTINCT col0 - col0 * col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT + col1 + ( - col1 ) * cor0.col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT tab0.col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL 16 * - col2 AS col1 FROM tab0
----
-1312
-16
-528

query I rowsort
SELECT ALL 59 AS col0 FROM tab1
----
59
59
59

query I rowsort
SELECT ALL - 16 FROM tab2, tab0, tab2 cor0
----
27 values hashing to 71c8b08964ab47ce12158975c0ee1fd9

query I rowsort
SELECT ALL 81 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT ALL - col2 * col1 AS col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - - col2 + 44 * col0 FROM tab1 AS cor0
----
186
2873
3616

query I rowsort
SELECT + cor0.col2 + 20 AS col1 FROM tab0 AS cor0
----
102
21
53

query I rowsort
SELECT + + cor0.col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 9 * col0 col0 FROM tab1
----
27
576
720

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab0 AS cor1, tab2 cor2
----
972 values hashing to 6dfb18fb846f922ba9ea60ce42b86fb0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * col1 col0 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-2419
SELECT DISTINCT + col1 DIV + col2 - - col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-2419
SELECT DISTINCT + col1 / + col2 - - col2 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT - - ( col1 ) * col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - - 37 + col1 AS col0 FROM tab1 AS cor0
----
47
50
63

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab2 AS cor1, tab1, tab2 cor2
----
3645 values hashing to 6193516da5556fc054f35e0d2f4e5372

onlyif mysql # use DIV operator for integer division
query I rowsort label-2423
SELECT DISTINCT - 83 * - col0 DIV + CAST( + col0 AS SIGNED ) + cor0.col2 FROM tab2 AS cor0
----
109
110
121

skipif mysql # not compatible
query I rowsort label-2423
SELECT DISTINCT - 83 * - col0 / + CAST ( + col0 AS INTEGER ) + cor0.col2 FROM tab2 AS cor0
----
109
110
121

query I rowsort
SELECT DISTINCT - 67 * - col1 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT ALL + + col2 + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT col0 + - col0 * col0 * col0 AS col0 FROM tab0 AS cor0
----
-13800
-42840
-704880

query I rowsort
SELECT DISTINCT + cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + col2 * 44 AS col1 FROM tab0 AS cor0
----
1452
3608
44

query I rowsort
SELECT - col0 + + ( col1 + + col0 ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - col0 * ( col2 ) AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT col0 + + ( col2 ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col0 - - col1 * - col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT - + cor0.col1 + 22 FROM tab2 AS cor0
----
-37
-9
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2434
SELECT + - col1 DIV - col1 + + ( col1 ) FROM tab0 cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-2434
SELECT + - col1 / - col1 + + ( col1 ) FROM tab0 cor0
----
87
92
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2435
SELECT 15 DIV col0 AS col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2435
SELECT 15 / col0 AS col0 FROM tab2
----
0
0
2

query I rowsort
SELECT tab0.col0 + - col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT DISTINCT + 69 FROM tab1, tab2 AS cor0, tab0 cor1
----
69

query I rowsort
SELECT DISTINCT + 48 + - col2 - col1 FROM tab2
----
-10
-37
-7

query I rowsort
SELECT - + col2 * col0 - + 39 * col2 AS col2 FROM tab2 AS cor0
----
-1242
-3042
-4484

query I rowsort
SELECT ALL - col1 * - 54 + + 17 AS col1 FROM tab0 AS cor0
----
4661
4931
5255

query I rowsort
SELECT ALL + + col0 + + ( + 26 ) FROM tab0 AS cor0
----
115
50
61

query I rowsort
SELECT col0 * col1 - cor0.col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL + col2 * col1 + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - cor0.col2 + 67 AS col1 FROM tab0 AS cor0
----
-15
34
66

query I rowsort
SELECT + 84 + col2 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1332
1488
654

query I rowsort
SELECT - + col2 + - 0 AS col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + - col2 + + col1 + col1 AS col2 FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT DISTINCT - col1 * + col2 - col1 AS col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL - - ( col0 ) * + col2 - col1 * - col0 AS col1 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT DISTINCT 82 AS col1 FROM tab0 cor0
----
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2451
SELECT ALL + 74 DIV ( col0 ) + col2 + col2 AS col0 FROM tab2 cor0
----
52
64
76

skipif mysql # not compatible
query I rowsort label-2451
SELECT ALL + 74 / ( col0 ) + col2 + col2 AS col0 FROM tab2 cor0
----
52
64
76

query I rowsort
SELECT 72 * 11 AS col2 FROM tab1 cor0
----
792
792
792

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
972 values hashing to fe55095fff3a5ecc2f113d14a8c6f823

query I rowsort
SELECT - 73 * - 17 FROM tab2 AS cor0
----
1241
1241
1241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2455
SELECT + CAST( col2 AS SIGNED ) FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2455
SELECT + CAST ( col2 AS INTEGER ) FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT + - 92 FROM tab2 AS cor0
----
-92
-92
-92

query I rowsort
SELECT ( col1 ) * cor0.col2 + 83 AS col1 FROM tab1 cor0
----
1331
1487
653

query I rowsort
SELECT DISTINCT - - ( col0 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + 58 AS col1 FROM tab2 AS cor0
----
58
58
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-2460
SELECT + ( col1 ) DIV - col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-2460
SELECT + ( col1 ) / - col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT DISTINCT - - ( - 20 ) * + cor0.col0 FROM tab1 AS cor0
----
-1280
-1600
-60

query I rowsort
SELECT - + col1 + + 33 * + col2 FROM tab2 AS cor0
----
1237
799
860

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 83 col0 FROM tab2 AS cor0
----
83
83
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2464
SELECT ALL CAST( col0 AS SIGNED ) * + col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-2464
SELECT ALL CAST ( col0 AS INTEGER ) * + col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - - col2 + - col2 * col2 * col1 FROM tab1 cor0
----
-119712
-32433
-75762

query I rowsort
SELECT ALL - - 87 * + col0 * + col1 AS col2 FROM tab1 AS cor0
----
55680
6786
90480

query I rowsort
SELECT - + ( + col2 ) * + cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - cor0.col2 + + col0 + col0 * col1 FROM tab2 cor0
----
1384
197
4654

onlyif mysql # use DIV operator for integer division
query I rowsort label-2469
SELECT + col0 + tab0.col1 * col2 DIV + col0 AS col2 FROM tab0
----
142
172
37

skipif mysql # not compatible
query I rowsort label-2469
SELECT + col0 + tab0.col1 * col2 / + col0 AS col2 FROM tab0
----
142
172
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-2470
SELECT ALL - col1 DIV col0 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-2470
SELECT ALL - col1 / col0 FROM tab2 cor0
----
-4
0
0

query I rowsort
SELECT + - col0 * col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + 99 AS col2 FROM tab2 cor0
----
99

query I rowsort
SELECT DISTINCT - - col2 - col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + 72 AS col1 FROM tab1 AS cor0
----
72

query I rowsort
SELECT - 17 * col2 * col1 + - ( col2 ) * + col2 AS col1 FROM tab0
----
-133578
-1650
-49335

query I rowsort
SELECT - 80 * 71 + col2 FROM tab1
----
-5584
-5623
-5626

onlyif mysql # use DIV operator for integer division
query I rowsort label-2477
SELECT ALL 18 DIV col1 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2477
SELECT ALL 18 / col1 FROM tab2
----
0
0
1

query I rowsort
SELECT DISTINCT - ( + ( - col1 ) ) * col2 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT - 15 FROM tab2
----
-15

query I rowsort
SELECT + 13 + col1 AS col2 FROM tab1 AS cor0
----
23
26
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-2481
SELECT + ( ( col1 ) ) + + ( col0 + col1 ) DIV ( + col0 + + col2 ) AS col0 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2481
SELECT + ( ( col1 ) ) + + ( col0 + col1 ) / ( + col0 + + col2 ) AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT - cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT - 49 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
-49

query I rowsort
SELECT ALL - + col1 * - cor0.col1 + - 28 AS col0 FROM tab0 AS cor0
----
7368
8253
9381

query I rowsort
SELECT ALL + ( col0 ) * + col0 - + col0 AS col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT DISTINCT - 39 + + col0 * - ( 39 ) - col1 AS col2 FROM tab1 cor0
----
-182
-2545
-3172

query I rowsort
SELECT + col0 + + ( col2 ) * col2 - - 59 AS col0 FROM tab0
----
1172
6872
95

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 cor1, tab1 AS cor2, tab0 AS cor3
----
3645 values hashing to 2566f3fa788816c8bfc482e730aaed74

query I rowsort
SELECT 75 FROM tab2, tab1 cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2491
SELECT + CAST( col1 AS SIGNED ) + - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2491
SELECT + CAST ( col1 AS INTEGER ) + - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col1 + - 8 * col0 FROM tab1 cor0
----
-50
-522
-653

query I rowsort
SELECT cor0.col0 + + 26 AS col2 FROM tab1 AS cor0
----
106
29
90

query I rowsort
SELECT DISTINCT + tab2.col2 + 78 + col1 AS col2 FROM tab2
----
133
136
163

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to 1b40f6ebec12e55a9e5893620c5636c7

query I rowsort
SELECT + 65 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

query I rowsort
SELECT DISTINCT - 11 AS col0 FROM tab0, tab2 AS cor0
----
-11

query I rowsort
SELECT + 2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - 33 col0 FROM tab2
----
-16
-2
26

query I rowsort
SELECT ( + 33 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT - col0 + + col2 + col2 * col2 AS col2 FROM tab1
----
2967
3242
9232

query I rowsort
SELECT ALL + col0 * + col0 AS col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - 55 + cor0.col1 * + col2 FROM tab0 AS cor0
----
2783
42
7407

query I rowsort
SELECT - 59 * 37 AS col2 FROM tab1
----
-2183
-2183
-2183

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col2 * - 96 col1 FROM tab0
----
3168
7872
96

query I rowsort
SELECT cor1.col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + col1 + col2 * + col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL - 12 * + col1 FROM tab0 AS cor0
----
-1032
-1092
-1164

query I rowsort
SELECT + cor0.col1 + 0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - - col2 * col2 + col0 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL 56 AS col0 FROM tab1 AS cor0
----
56
56
56

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab2 cor1, tab1, tab0 AS cor2
----
3645 values hashing to b225d3765f33551c12574f545c8c91eb

query I rowsort
SELECT ALL - col1 * 64 AS col0 FROM tab1 AS cor0
----
-1664
-640
-832

query I rowsort
SELECT DISTINCT tab1.col2 + - col2 AS col0 FROM tab1
----
0

query I rowsort
SELECT - col1 + ( + 86 ) AS col0 FROM tab2 AS cor0
----
27
55
69

query I rowsort
SELECT + - 7 FROM tab2, tab1 AS cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

query I rowsort
SELECT + col0 + col1 * + col2 * - col1 FROM tab0 AS cor0
----
-244044
-678953
-9374

query I rowsort
SELECT + + col0 * 5 FROM tab2 cor0
----
35
390
395

query I rowsort
SELECT ALL col1 * col1 + - 72 * - tab0.col0 AS col0 FROM tab0
----
11929
14689
9124

query I rowsort
SELECT + - 1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 71 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

onlyif mysql # use DIV operator for integer division
query I rowsort label-2522
SELECT ALL + col1 * tab0.col1 DIV - col2 AS col0 FROM tab0
----
-100
-224
-9409

skipif mysql # not compatible
query I rowsort label-2522
SELECT ALL + col1 * tab0.col1 / - col2 AS col0 FROM tab0
----
-100
-224
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2523
SELECT - col0 + col0 DIV 51 FROM tab0 AS cor0
----
-24
-35
-88

skipif mysql # not compatible
query I rowsort label-2523
SELECT - col0 + col0 / 51 FROM tab0 AS cor0
----
-24
-35
-88

query I rowsort
SELECT 10 AS col0 FROM tab0
----
10
10
10

query I rowsort
SELECT ALL + + col0 * cor0.col0 - + col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT DISTINCT 28 + col0 FROM tab2 AS cor0
----
106
107
35

query I rowsort
SELECT ALL 82 * - col1 FROM tab2 cor0
----
-1394
-2542
-4838

query I rowsort
SELECT DISTINCT - - ( col0 ) + - col1 AS col2 FROM tab0 AS cor0
----
-2
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - 77 + - col1 * + ( + col0 ) + + cor0.col2 FROM tab2 AS cor0
----
-1382
-267
-4653

query I rowsort
SELECT DISTINCT - - ( - col2 ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - 52 * col1 * col2 FROM tab1 AS cor0
----
-29640
-64896
-73008

onlyif mysql # use DIV operator for integer division
query I rowsort label-2533
SELECT ALL - col2 DIV 45 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2533
SELECT ALL - col2 / 45 FROM tab2
----
0
0
0

query I rowsort
SELECT + col2 * col2 + col0 * 52 AS col0 FROM tab1 cor0
----
13376
3072
6577

query I rowsort
SELECT tab0.col2 + tab0.col1 FROM tab0
----
119
173
98

query I rowsort
SELECT + 87 - + col1 FROM tab1
----
61
74
77

query I rowsort
SELECT + 69 FROM tab0, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT + + 1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col0 + + col2 * + col1 AS col0 FROM tab1 AS cor0
----
1168
1401
506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * - 67 col2 FROM tab1 AS cor0
----
-3564
-3762
-6336

query I rowsort
SELECT DISTINCT - ( cor1.col2 ) AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-26
-27
-38

query I rowsort
SELECT + ( - col2 ) * + col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT col1 * col2 * col1 AS col2 FROM tab1 cor0
----
16224
36504
5700

query I rowsort
SELECT ALL col0 + + 6 FROM tab1 AS cor0
----
70
86
9

query I rowsort
SELECT ALL + col0 * - col2 * - col1 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT + col0 * 54 AS col2 FROM tab0 AS cor0
----
1296
1890
4806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2547
SELECT DISTINCT + col2 DIV + ( + cor0.col1 + + col1 * + cor0.col1 ) AS col0 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2547
SELECT DISTINCT + col2 / + ( + cor0.col1 + + col1 * + cor0.col1 ) AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - col0 + - col2 AS col2 FROM tab2 cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 + 35 col2 FROM tab2 AS cor0
----
1479
711
764

query I rowsort
SELECT ALL - - col2 + - col0 * col1 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 47 col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT DISTINCT + cor0.col1 * 7 FROM tab2, tab2 AS cor0
----
119
217
413

query I rowsort
SELECT ALL + col0 * + cor0.col2 + col2 * col1 * + col1 FROM tab1 AS cor0
----
23904
36666
9348

query I rowsort
SELECT DISTINCT - col2 * - col0 * col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT + ( - col1 ) * col2 * 19 FROM tab1 AS cor0
----
-10830
-23712
-26676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2556
SELECT CAST( NULL AS SIGNED ) * 40 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2556
SELECT CAST ( NULL AS INTEGER ) * 40 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2557
SELECT - cor0.col2 + 69 DIV col0 FROM tab1 AS cor0
----
-31
-56
-96

skipif mysql # not compatible
query I rowsort label-2557
SELECT - cor0.col2 + 69 / col0 FROM tab1 AS cor0
----
-31
-56
-96

query I rowsort
SELECT col1 * 72 + - col0 FROM tab2 AS cor0
----
1145
2225
4170

query I rowsort
SELECT + + cor0.col2 * col1 * col0 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT col2 * ( - col2 ) AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col0 + - 35 FROM tab2 AS cor0
----
-28
43
44

query I rowsort
SELECT DISTINCT 40 * 58 AS col0 FROM tab0, tab0 AS cor0
----
2320

onlyif mysql # use DIV operator for integer division
query I rowsort label-2563
SELECT - col0 + col2 DIV + col0 AS col2 FROM tab0 AS cor0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-2563
SELECT - col0 + col2 / + col0 AS col2 FROM tab0 AS cor0
----
-23
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - col1 ) + - cor0.col1 * + col2 col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL - ( cor0.col1 ) * cor0.col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + 13 + 5 * col1 FROM tab1 AS cor0
----
143
63
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2567
SELECT DISTINCT - col2 - col0 * + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2567
SELECT DISTINCT - col2 - col0 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - 87 AS col0 FROM tab1 AS cor0
----
-87
-87
-87

query I rowsort
SELECT 24 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT col0 - 58 FROM tab0
----
-23
-34
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 24 col0 FROM tab0 AS cor0
----
-24

query I rowsort
SELECT + col0 + - col1 * col0 * - col2 FROM tab2 AS cor0
----
119730
51113
5866

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2573
SELECT ALL + CAST( + col1 AS SIGNED ) + + col2 AS col2 FROM tab0 cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-2573
SELECT ALL + CAST ( + col1 AS INTEGER ) + + col2 AS col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT ( - col2 ) * col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-2575
SELECT - col0 DIV + 42 - - 8 * col2 AS col0 FROM tab2
----
207
216
303

skipif mysql # not compatible
query I rowsort label-2575
SELECT - col0 / + 42 - - 8 * col2 AS col0 FROM tab2
----
207
216
303

query I rowsort
SELECT + col2 + 11 FROM tab0 AS cor0
----
12
44
93

query I rowsort
SELECT DISTINCT - + ( - col0 ) * + col2 + col0 * col0 FROM tab0 AS cor0
----
1260
1368
15219

onlyif mysql # use DIV operator for integer division
query I rowsort label-2578
SELECT col1 DIV col1 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2578
SELECT col1 / col1 AS col0 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2579
SELECT ALL + CAST( NULL AS SIGNED ) * 43 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2579
SELECT ALL + CAST ( NULL AS INTEGER ) * 43 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2580
SELECT DISTINCT + col0 * col1 DIV + col0 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2580
SELECT DISTINCT + col0 * col1 / + col0 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2581
SELECT ALL CAST( NULL AS SIGNED ) * - col2 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2581
SELECT ALL CAST ( NULL AS INTEGER ) * - col2 AS col0 FROM tab1
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 cor0 CROSS JOIN tab2, tab2 AS cor1
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

query I rowsort
SELECT ALL - col0 + col1 * + col2 * - col0 + 82 FROM tab0 AS cor0
----
-3348
-664125
-68054

onlyif mysql # use DIV operator for integer division
query I rowsort label-2584
SELECT DISTINCT col0 DIV - col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2584
SELECT DISTINCT col0 / - col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT + + cor0.col2 * - col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL ( - col0 ) * + col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 69 col2 FROM tab2 AS cor0
----
-69
-69
-69

query I rowsort
SELECT - col0 * col1 + cor0.col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT + + col1 + + 68 FROM tab0 cor0
----
154
159
165

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 + 8 + + 54 FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT + 41 * - col0 FROM tab1 AS cor0
----
-123
-2624
-3280

query I rowsort
SELECT DISTINCT + col2 * - ( + col1 ) * ( + col0 ) AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT col2 + + col2 AS col2 FROM tab0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2595
SELECT DISTINCT - col1 + + col2 DIV + col0 FROM tab0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-2595
SELECT DISTINCT - col1 + + col2 / + col0 FROM tab0
----
-85
-91
-97

query I rowsort
SELECT ALL + + 59 * cor0.col0 AS col2 FROM tab1 AS cor0
----
177
3776
4720

onlyif mysql # use DIV operator for integer division
query I rowsort label-2597
SELECT ALL + col0 DIV + col0 + + 61 FROM tab0 AS cor0
----
62
62
62

skipif mysql # not compatible
query I rowsort label-2597
SELECT ALL + col0 / + col0 + + 61 FROM tab0 AS cor0
----
62
62
62

query I rowsort
SELECT - 66 + - col0 FROM tab2 AS cor0
----
-144
-145
-73

query I rowsort
SELECT + + col0 * cor0.col2 FROM tab1 cor0
----
162
3648
7680

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to 9d746e15fdb5adcb43a7518cd9743eb3

query I rowsort
SELECT DISTINCT col1 + ( col1 ) AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + col0 + cor0.col0 * + 93 * - col2 FROM tab0 AS cor0
----
-3220
-678625
-73632

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 + + col0 col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + col0 * + ( - ( - col2 ) ) FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL + col2 + - col0 * ( - col2 ) AS col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + 53 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-2607
SELECT ALL col0 DIV + col0 - col0 DIV + col1 FROM tab1 AS cor0
----
-5
-5
1

skipif mysql # not compatible
query I rowsort label-2607
SELECT ALL col0 / + col0 - col0 / + col1 FROM tab1 AS cor0
----
-5
-5
1

query I rowsort
SELECT ALL - + col0 * + 24 * col0 FROM tab2 cor0
----
-1176
-146016
-149784

query I rowsort
SELECT 11 * + col2 * col2 FROM tab1
----
101376
32076
35739

query I rowsort
SELECT DISTINCT col1 * 80 FROM tab1 AS cor0
----
1040
2080
800

query I rowsort
SELECT ALL + - cor0.col2 * col0 + + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL - cor0.col2 * + 25 + - col0 FROM tab2 cor0
----
-1029
-682
-728

query I rowsort
SELECT ALL + + col2 - col2 * col1 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT + + col1 - 52 FROM tab2 AS cor0
----
-21
-35
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col2 * col2 col0 FROM tab1 AS cor0
----
-2942
-3259
-9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-2616
SELECT DISTINCT - col0 DIV + col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2616
SELECT DISTINCT - col0 / + col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT - + col0 * + 53 FROM tab0 AS cor0
----
-1272
-1855
-4717

onlyif mysql # use DIV operator for integer division
query I rowsort label-2618
SELECT DISTINCT + - col1 DIV 26 + - 4 AS col2 FROM tab2 AS cor0
----
-4
-5
-6

skipif mysql # not compatible
query I rowsort label-2618
SELECT DISTINCT + - col1 / 26 + - 4 AS col2 FROM tab2 AS cor0
----
-4
-5
-6

query I rowsort
SELECT ALL - + col0 - + col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT - + col2 * 31 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1140
-780
-810

skipif mysql # not compatible
query I rowsort
SELECT cor0.col1 + - CAST ( - col0 AS REAL ) * col2 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT - - col2 * - cor0.col0 + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 col2 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + + col1 * 40 AS col1 FROM tab2 cor0
----
1240
2360
680

query I rowsort
SELECT - col2 * ( col1 ) + - col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL - col2 * + ( - 56 ) AS col1 FROM tab1 AS cor0
----
3024
3192
5376

query I rowsort
SELECT DISTINCT + col0 * 65 FROM tab2 AS cor0
----
455
5070
5135

onlyif mysql # use DIV operator for integer division
query I rowsort label-2629
SELECT ALL col1 DIV ( - cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2629
SELECT ALL col1 / ( - cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2630
SELECT - col2 + CAST( NULL AS SIGNED ) * 4 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2630
SELECT - col2 + CAST ( NULL AS INTEGER ) * 4 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + ( col2 ) AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + - 85 FROM tab0 cor0
----
-85

query I rowsort
SELECT DISTINCT + col0 + col2 * col1 AS col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL cor1.col2 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif mysql # not compatible
query I rowsort
SELECT col0 + col0 / - CAST ( col0 AS REAL ) + - col0 * 48 * + col0 FROM tab0 AS cor0
----
-27625
-380120
-58766

query I rowsort
SELECT - col0 * + col0 AS col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT ALL col0 * col0 + + col1 * - col2 AS col2 FROM tab1
----
-1395
3526
5152

query I rowsort
SELECT ALL col1 + + col0 * + col2 FROM tab1
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-2639
SELECT DISTINCT tab2.col1 + - tab2.col2 DIV col0 FROM tab2
----
17
28
59

skipif mysql # not compatible
query I rowsort label-2639
SELECT DISTINCT tab2.col1 + - tab2.col2 / col0 FROM tab2
----
17
28
59

query I rowsort
SELECT DISTINCT 18 * + tab2.col0 + - 6 AS col0 FROM tab2
----
120
1398
1416

query I rowsort
SELECT 98 * col2 FROM tab1
----
5292
5586
9408

query I rowsort
SELECT DISTINCT - ( 9 ) FROM tab1, tab0 cor0, tab1 AS cor1
----
-9

query I rowsort
SELECT DISTINCT + col2 * col2 + ( + 80 ) FROM tab1 AS cor0
----
2996
3329
9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col1 + + ( tab2.col0 ) col1 FROM tab2
----
175
215
45

query I rowsort
SELECT + - 53 * cor0.col0 + + 77 AS col1 FROM tab0 AS cor0
----
-1195
-1778
-4640

query I rowsort
SELECT ALL 75 * 63 * col1 AS col0 FROM tab2
----
146475
278775
80325

query I rowsort
SELECT DISTINCT 67 FROM tab2, tab1 AS cor0
----
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + cor0.col1 * 31 col0 FROM tab0 cor0
----
105245
251069
63984

query I rowsort
SELECT - 34 + col2 * ( col2 + col0 ) FROM tab2 cor0
----
2670
4412
884

query I rowsort
SELECT + col0 + 27 FROM tab0 cor0
----
116
51
62

query I rowsort
SELECT DISTINCT - col1 * col2 + + 24 AS col1 FROM tab1 AS cor0
----
-1224
-1380
-546

query I rowsort
SELECT 61 FROM tab1 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT ALL + + cor0.col0 + col0 * - col1 * col0 FROM tab2 AS cor0
----
-106018
-1512
-358878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2654
SELECT ALL - col0 * - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2654
SELECT ALL - col0 * - CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab1.col1 + 63 * - cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to b41f07672ff77c8201b1e880f5d50dd1

query I rowsort
SELECT + col0 + - cor0.col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2657
SELECT - - 57 / - col1 + + col2 / CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2657
SELECT - - 57 / - col1 + + col2 / CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 72 + + col0 * col0 AS col2 FROM tab2 AS cor0
----
121
6156
6313

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2659
SELECT DISTINCT col2 / + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2659
SELECT DISTINCT col2 / + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT ALL ( col2 + col1 ) FROM tab1
----
109
67
80

query I rowsort
SELECT + ( + 87 ) AS col0 FROM tab2
----
87
87
87

query I rowsort
SELECT + + ( 31 ) * - col1 FROM tab2 cor0
----
-1829
-527
-961

query I rowsort
SELECT + ( col1 ) * col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - 65 * + tab2.col0 FROM tab2
----
-455
-5070
-5135

query I rowsort
SELECT cor0.col2 * + col0 * col0 AS col0 FROM tab1 AS cor0
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 95 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT DISTINCT + - 89 * col0 FROM tab1 AS cor0
----
-267
-5696
-7120

query I rowsort
SELECT - col2 + - cor0.col0 + - ( col1 ) * col2 AS col1 FROM tab1 AS cor0
----
-1424
-1461
-691

onlyif mysql # use DIV operator for integer division
query I rowsort label-2669
SELECT DISTINCT + + 10 * col0 DIV col2 FROM tab0 AS cor0
----
10
350
7

skipif mysql # not compatible
query I rowsort label-2669
SELECT DISTINCT + + 10 * col0 / col2 FROM tab0 AS cor0
----
10
350
7

query I rowsort
SELECT + 7 FROM tab1, tab1 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT - ( - col2 ) + col0 AS col2 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2672
SELECT col1 DIV col1 - - ( 7 ) * col2 * ( + col0 * col1 ) FROM tab0
----
23766
4648827
476785

skipif mysql # not compatible
query I rowsort label-2672
SELECT col1 / col1 - - ( 7 ) * col2 * ( + col0 * col1 ) FROM tab0
----
23766
4648827
476785

query I rowsort
SELECT + col0 * + cor0.col0 + - 38 + cor0.col0 FROM tab0 cor0
----
1222
562
7972

query I rowsort
SELECT DISTINCT + - col2 + - col0 + - col1 FROM tab1 AS cor0
----
-131
-189
-83

query I rowsort
SELECT DISTINCT - - col2 * + col0 + - 43 * 15 FROM tab2 AS cor0
----
-456
1383
2357

query I rowsort
SELECT - + 31 FROM tab1 AS cor0
----
-31
-31
-31

query I rowsort
SELECT - + 54 * col0 FROM tab1 AS cor0
----
-162
-3456
-4320

query I rowsort
SELECT ALL + col1 + col0 * + 40 AS col0 FROM tab1 AS cor0
----
146
2570
3213

query I rowsort
SELECT DISTINCT 67 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
67

query I rowsort
SELECT ALL + + 6 + + col0 + col2 FROM tab0 AS cor0
----
177
42
63

query I rowsort
SELECT ALL + tab0.col1 * ( - 16 ) - - col0 AS col1 FROM tab0
----
-1352
-1367
-1517

query I rowsort
SELECT ALL + 71 FROM tab0, tab1 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - tab0.col2 col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT + - col0 * 67 - 37 FROM tab0 AS cor0
----
-1645
-2382
-6000

query I rowsort
SELECT + - col0 - - cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT + col1 * 38 + col2 + ( col0 + cor0.col1 ) AS col0 FROM tab2 AS cor0
----
1243
2405
780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2687
SELECT col0 + ( col1 + CAST( NULL AS SIGNED ) ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2687
SELECT col0 + ( col1 + CAST ( NULL AS INTEGER ) ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * - ( - col1 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2689
SELECT + - col0 + cor0.col1 DIV cor0.col2 + CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
159
3
64

skipif mysql # not compatible
query I rowsort label-2689
SELECT + - col0 + cor0.col1 / cor0.col2 + CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
159
3
64

query I rowsort
SELECT ALL - 82 * 97 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
-7872
-7921
-7953

query I rowsort
SELECT col0 + 86 * - col1 FROM tab2 AS cor0
----
-1383
-2659
-4996

query I rowsort
SELECT 7 * col1 + - col0 + - col2 FROM tab2 AS cor0
----
183
2
309

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2693
SELECT col0 / + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2693
SELECT col0 / + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * - ( 64 ) * col2 AS col0 FROM tab2
----
-12096
-129792
-192128

query I rowsort
SELECT ALL + col0 + - col0 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 63 * + col1 AS col1 FROM tab1 AS cor0
----
1638
630
819

query I rowsort
SELECT DISTINCT - 26 * cor0.col2 * col1 FROM tab0 AS cor0
----
-194012
-2522
-73788

onlyif mysql # use DIV operator for integer division
query I rowsort label-2698
SELECT ALL + 3 DIV - col1 + col1 + 74 FROM tab0 AS cor0
----
160
165
171

skipif mysql # not compatible
query I rowsort label-2698
SELECT ALL + 3 / - col1 + col1 + 74 FROM tab0 AS cor0
----
160
165
171

query I rowsort
SELECT ( + cor0.col1 ) * + col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + ( col1 ) AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + - 85 + + 0 * col2 FROM tab2 AS cor0
----
-85

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col0 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - - col1 + col1 * + col1 AS col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL - - 43 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT - col2 * + col1 + col0 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT + + col0 + + cor0.col0 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2707
SELECT DISTINCT + col0 * + CAST( col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-2707
SELECT DISTINCT + col0 * + CAST ( col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - col2 * col2 + - col2 * col0 AS col2 FROM tab2 cor0
----
-2704
-4446
-918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2709
SELECT + - col2 + CAST( col2 AS SIGNED ) * - col0 FROM tab2 AS cor0
----
-2054
-216
-3040

skipif mysql # not compatible
query I rowsort label-2709
SELECT + - col2 + CAST ( col2 AS INTEGER ) * - col0 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT - + 55 * + col0 FROM tab0 AS cor0
----
-1320
-1925
-4895

query I rowsort
SELECT DISTINCT 64 FROM tab2, tab2 AS cor0
----
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col2 * 66 col1 FROM tab1
----
3564
3762
6336

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2713
SELECT - CAST( 57 AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

skipif mysql # not compatible
query I rowsort label-2713
SELECT - CAST ( 57 AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT col0 + + 24 FROM tab2
----
102
103
31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2715
SELECT - col0 * CAST( - col1 AS SIGNED ) AS col0 FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-2715
SELECT - col0 * CAST ( - col1 AS INTEGER ) AS col0 FROM tab2
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 * + col1 col0 FROM tab0
----
118825
49536
720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2717
SELECT - CAST( NULL AS DECIMAL ) * col2 + - col1 + col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2717
SELECT - CAST ( NULL AS REAL ) * col2 + - col1 + col1 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + tab2.col1 - - tab2.col2 FROM tab2
----
144
72
89

query I rowsort
SELECT ALL - 61 - + cor0.col1 FROM tab0 AS cor0
----
-147
-152
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-2720
SELECT - col0 + col0 DIV CAST( col0 * col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2720
SELECT - col0 + col0 / CAST ( col0 * col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + + col2 * col2 + - cor0.col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT + 20 * col0 FROM tab0 AS cor0
----
1780
480
700

query I rowsort
SELECT DISTINCT tab0.col0 - col1 AS col0 FROM tab0
----
-2
-62

query I rowsort
SELECT ALL col2 * - col2 + col1 * tab1.col1 - + col1 * col0 FROM tab1
----
-10087
-2318
-3789

onlyif mysql # use DIV operator for integer division
query I rowsort label-2725
SELECT + CAST( + ( col2 ) AS SIGNED ) + col0 DIV 76 + col1 FROM tab1
----
110
67
80

skipif mysql # not compatible
query I rowsort label-2725
SELECT + CAST ( + ( col2 ) AS INTEGER ) + col0 / 76 + col1 FROM tab1
----
110
67
80

query I rowsort
SELECT col1 * col0 + col1 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL - col1 * + col2 * 88 AS col2 FROM tab2 AS cor0
----
-134992
-56848
-73656

onlyif mysql # use DIV operator for integer division
query I rowsort label-2728
SELECT + 14 DIV - col0 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2728
SELECT + 14 / - col0 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT DISTINCT - 92 + + col1 FROM tab2 cor0
----
-33
-61
-75

query I rowsort
SELECT ALL - + col2 * - col1 AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT col1 + - cor0.col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL + + 61 * cor0.col2 FROM tab1 AS cor0
----
3294
3477
5856

query I rowsort
SELECT DISTINCT cor0.col0 * + col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - 33 + + cor0.col0 FROM tab1 AS cor0
----
-30
31
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-2735
SELECT ALL - ( col1 ) DIV - col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2735
SELECT ALL - ( col1 ) / - col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - ( 24 ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to f2e40f6e5cdbc2877843191cb261975f

query I rowsort
SELECT ALL - tab2.col1 + col0 + col1 AS col2 FROM tab2
----
7
78
79

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1, tab2 cor0, tab1 cor1
----
972 values hashing to 4c0813b2179303fdf58f082d81d6d03c

query I rowsort
SELECT DISTINCT 13 + col0 AS col2 FROM tab1
----
16
77
93

query I rowsort
SELECT ALL - 48 * + tab0.col0 + - ( - col2 ) * + col1 FROM tab0
----
-1583
1686
3190

query I rowsort
SELECT col1 * cor0.col2 - ( col2 ) FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL - cor0.col0 - + col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - 79 * col2 FROM tab1
----
-4266
-4503
-7584

query I rowsort
SELECT ALL 84 + + 22 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a64ba54e418231a2dbc2879c8d9fbfb0

query I rowsort
SELECT DISTINCT 47 AS col1 FROM tab1
----
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-2746
SELECT col2 * col2 + col1 * col2 DIV 30 + col2 FROM tab1 cor0
----
3016
3325
9353

skipif mysql # not compatible
query I rowsort label-2746
SELECT col2 * col2 + col1 * col2 / 30 + col2 FROM tab1 cor0
----
3016
3325
9353

query I rowsort
SELECT + - col0 * 42 FROM tab1 AS cor0
----
-126
-2688
-3360

query I rowsort
SELECT - col0 + + col1 * col1 AS col1 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT + cor0.col1 + - cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to 308a2403def70dcc4e01e3103bcd5fb8

query I rowsort
SELECT DISTINCT col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col0 * 82 AS col2 FROM tab0 AS cor0
----
1968
2870
7298

query I rowsort
SELECT - col0 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - + col2 * - cor0.col0 + - col1 AS col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - - col0 * col0 + - 41 FROM tab2 AS cor0
----
6043
6200
8

query I rowsort
SELECT - - col2 + ( - col0 + - col0 ) AS col0 FROM tab0 AS cor0
----
-15
-69
-96

query I rowsort
SELECT - col2 - + 77 AS col0 FROM tab1 AS cor0
----
-131
-134
-173

query I rowsort
SELECT col1 + + 20 * - 77 AS col0 FROM tab0 AS cor0
----
-1443
-1449
-1454

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2759
SELECT DISTINCT + 40 * + ( + col2 ) * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2759
SELECT DISTINCT + 40 * + ( + col2 ) * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - cor0.col1 + - col1 + + col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + 32 * ( - col1 ) AS col1 FROM tab1 AS cor0
----
-320
-416
-832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col1 * + cor0.col0 * 48 col0 FROM tab2 cor0
----
10409
220818
64385

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 32 col2 FROM tab2
----
32

query I rowsort
SELECT DISTINCT + + 52 + - 52 AS col2 FROM tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2765
SELECT - CAST( 16 AS SIGNED ) * cor0.col1 FROM tab1 AS cor0
----
-160
-208
-416

skipif mysql # not compatible
query I rowsort label-2765
SELECT - CAST ( 16 AS INTEGER ) * cor0.col1 FROM tab1 AS cor0
----
-160
-208
-416

query I rowsort
SELECT ALL + col0 * - 6 * - col2 - + col1 FROM tab2 AS cor0
----
1103
12109
17995

query I rowsort
SELECT cor0.col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2768
SELECT DISTINCT - ( + 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-2768
SELECT DISTINCT - ( + col1 ) / col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ALL - - 15 + col2 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT DISTINCT + + 76 - col2 FROM tab0 AS cor0
----
-6
43
75

query I rowsort
SELECT DISTINCT - + ( - cor0.col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL col0 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT cor0.col2 + - cor0.col2 + - col0 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT col2 * - 94 FROM tab1 AS cor0
----
-5076
-5358
-9024

query I rowsort
SELECT ALL + - 36 * col0 * + col1 + - col0 AS col2 FROM tab0 AS cor0
----
-122255
-291653
-74328

query I rowsort
SELECT col2 + - col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + + col0 * + col0 + - cor0.col1 - + ( + cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-43
4076
6374

query I rowsort
SELECT - - cor0.col1 + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT col2 + - ( col0 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT - col1 * 9 FROM tab1 AS cor0
----
-117
-234
-90

query I rowsort
SELECT - col0 * + 16 AS col2 FROM tab0 cor0
----
-1424
-384
-560

query I rowsort
SELECT cor0.col1 + + col1 * 89 AS col2 FROM tab0 AS cor0
----
7740
8190
8730

query I rowsort
SELECT - col1 + col0 * cor0.col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT col0 + - 44 * - col1 FROM tab2 AS cor0
----
1371
2674
827

query I rowsort
SELECT + col1 * 32 * + col1 AS col0 FROM tab2 AS cor0
----
111392
30752
9248

query I rowsort
SELECT - col2 * + ( - col2 ) FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-2788
SELECT - + ( + 13 ) + col0 DIV + cor0.col0 AS col1 FROM tab0 AS cor0
----
-12
-12
-12

skipif mysql # not compatible
query I rowsort label-2788
SELECT - + ( + 13 ) + col0 / + cor0.col0 AS col1 FROM tab0 AS cor0
----
-12
-12
-12

onlyif mysql # use DIV operator for integer division
query I rowsort label-2789
SELECT - + CAST( col2 AS SIGNED ) DIV + col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-2789
SELECT - + CAST ( col2 AS INTEGER ) / + col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col2 AS REAL ) * + col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + 89 FROM tab2, tab1 AS cor0
----
89

query I rowsort
SELECT ALL + col1 * 87 AS col1 FROM tab2 cor0
----
1479
2697
5133

query I rowsort
SELECT DISTINCT col0 + col2 * + ( - ( - cor0.col0 ) ) FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + col0 * + col0 + + col0 + col2 FROM tab2
----
6188
6358
83

query I rowsort
SELECT + ( col1 ) + ( - col1 ) FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 col0 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - tab2.col2 col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - 5 FROM tab0 AS cor0
----
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2799
SELECT DISTINCT - + col1 * - CAST( col2 AS SIGNED ) + col0 FROM tab1 AS cor0
----
1328
1407
634

skipif mysql # not compatible
query I rowsort label-2799
SELECT DISTINCT - + col1 * - CAST ( col2 AS INTEGER ) + col0 FROM tab1 AS cor0
----
1328
1407
634

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0, tab0 cor1, tab2 cor2
----
972 values hashing to 591a9a93560839231c038a1e10bd240a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2801
SELECT ALL col0 + CAST( 82 AS SIGNED ) FROM tab2 AS cor0
----
160
161
89

skipif mysql # not compatible
query I rowsort label-2801
SELECT ALL col0 + CAST ( 82 AS INTEGER ) FROM tab2 AS cor0
----
160
161
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2802
SELECT + col1 DIV 8 + + 69 AS col2 FROM tab0 AS cor0
----
79
80
81

skipif mysql # not compatible
query I rowsort label-2802
SELECT + col1 / 8 + + 69 AS col2 FROM tab0 AS cor0
----
79
80
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2803
SELECT - CAST( + 57 AS SIGNED ) AS col2 FROM tab0, tab1 cor0, tab1 cor1
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

skipif mysql # not compatible
query I rowsort label-2803
SELECT - CAST ( + 57 AS INTEGER ) AS col2 FROM tab0, tab1 cor0, tab1 cor1
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT - cor1.col0 * tab0.col1 AS col1 FROM tab0, tab2, tab2 AS cor0, tab2 AS cor1
----
81 values hashing to 04f9e446674d6e3f720f03adbdb0aac0

query I rowsort
SELECT col1 + 93 AS col1 FROM tab0
----
179
184
190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL + col0 * tab1.col2 + - 13 AS col0 FROM tab1
----
149
3635
7667

query I rowsort
SELECT tab1.col1 * 65 - + col1 * col0 FROM tab1
----
-195
10
1612

onlyif mysql # use DIV operator for integer division
query I rowsort label-2809
SELECT + - cor0.col1 DIV 23 AS col0 FROM tab0 cor0
----
-3
-3
-4

skipif mysql # not compatible
query I rowsort label-2809
SELECT + - cor0.col1 / 23 AS col0 FROM tab0 cor0
----
-3
-3
-4

query I rowsort
SELECT - col0 * - ( col1 ) + col1 AS col0 FROM tab1
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-2811
SELECT DISTINCT col1 + + 76 DIV col0 FROM tab0
----
89
91
99

skipif mysql # not compatible
query I rowsort label-2811
SELECT DISTINCT col1 + + 76 / col0 FROM tab0
----
89
91
99

query I rowsort
SELECT + - cor0.col1 * - col1 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2813
SELECT DISTINCT 60 DIV - col0 FROM tab2
----
-8
0

skipif mysql # not compatible
query I rowsort label-2813
SELECT DISTINCT 60 / - col0 FROM tab2
----
-8
0

query I rowsort
SELECT - - tab0.col1 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + 19 FROM tab1, tab0 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT DISTINCT - 69 FROM tab2, tab0 AS cor0
----
-69

query I rowsort
SELECT ALL + 98 * ( col0 ) AS col2 FROM tab0
----
2352
3430
8722

query I rowsort
SELECT cor0.col1 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 36 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT 33 + cor0.col0 - + 16 FROM tab1 AS cor0
----
20
81
97

query I rowsort
SELECT + - col1 + + col1 - ( + col1 ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + 92 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

onlyif mysql # use DIV operator for integer division
query I rowsort label-2823
SELECT DISTINCT col1 - col2 DIV - 27 AS col1 FROM tab2
----
18
32
59

skipif mysql # not compatible
query I rowsort label-2823
SELECT DISTINCT col1 - col2 / - 27 AS col1 FROM tab2
----
18
32
59

query I rowsort
SELECT ALL + col1 * + col2 + 10 FROM tab0 AS cor0
----
107
2848
7472

query I rowsort
SELECT ALL col2 * col1 + col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - 71 + col2 * col2 - 4 AS col0 FROM tab2 AS cor0
----
1369
601
654

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2827
SELECT ALL + - CAST( - col0 AS SIGNED ) FROM tab2 cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2827
SELECT ALL + - CAST ( - col0 AS INTEGER ) FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT col2 - - ( col0 ) AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT cor0.col1 - - 57 * 88 AS col1 FROM tab2, tab2 AS cor0
----
5033
5047
5075

query I rowsort
SELECT DISTINCT cor0.col2 * - col1 - col0 FROM tab0 AS cor0
----
-132
-2862
-7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2831
SELECT DISTINCT - col2 * - cor0.col2 + col0 * CAST( col1 * + col1 AS SIGNED ) FROM tab2 AS cor0
----
24275
272194
7456

skipif mysql # not compatible
query I rowsort label-2831
SELECT DISTINCT - col2 * - cor0.col2 + col0 * CAST ( col1 * + col1 AS INTEGER ) FROM tab2 AS cor0
----
24275
272194
7456

query I rowsort
SELECT 68 * - cor0.col1 * col2 + col0 AS col1 FROM tab0 AS cor0
----
-192960
-507327
-6561

query I rowsort
SELECT - 62 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT DISTINCT + cor0.col2 * 83 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
2158
2241
3154

query I rowsort
SELECT ALL - - ( + col0 ) * + col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + 0 * col0 AS col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 1 + col2 col0 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT ALL + col2 + ( + col1 ) FROM tab0 AS cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2839
SELECT + + CAST( + col1 AS SIGNED ) * col0 * col0 + + col0 col1 FROM tab2 AS cor0
----
106176
1526
359034

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2839
SELECT + + CAST ( + col1 AS INTEGER ) * col0 * col0 + + col0 col1 FROM tab2 AS cor0
----
106176
1526
359034

query I rowsort
SELECT DISTINCT + col2 + + col1 * - col1 FROM tab1 AS cor0
----
-43
-622
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - col2 col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2842
SELECT cor0.col2 DIV + col2 + - col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2842
SELECT cor0.col2 / + col2 + - col1 FROM tab0 AS cor0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2843
SELECT ( + col1 ) + ( + col1 ) DIV col1 AS col2 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-2843
SELECT ( + col1 ) + ( + col1 ) / col1 AS col2 FROM tab2 AS cor0
----
18
32
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-2844
SELECT ALL - - col0 + col1 DIV 25 AS col2 FROM tab0 cor0
----
27
38
92

skipif mysql # not compatible
query I rowsort label-2844
SELECT ALL - - col0 + col1 / 25 AS col2 FROM tab0 cor0
----
27
38
92

query I rowsort
SELECT + + cor0.col2 + col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + - col2 + col0 * col1 FROM tab2 cor0
----
1305
190
4576

query I rowsort
SELECT 80 AS col2 FROM tab0 AS cor0
----
80
80
80

query I rowsort
SELECT DISTINCT col1 + + col1 + col0 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT DISTINCT + 18 AS col1 FROM tab0 AS cor0
----
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-2850
SELECT ALL col1 * col1 + - tab2.col0 DIV + 52 FROM tab2
----
288
3480
961

skipif mysql # not compatible
query I rowsort label-2850
SELECT ALL col1 * col1 + - tab2.col0 / + 52 FROM tab2
----
288
3480
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2851
SELECT ALL CAST( NULL AS SIGNED ) * 97 + + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2851
SELECT ALL CAST ( NULL AS INTEGER ) * 97 + + col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2852
SELECT - col0 + - col2 * col2 * - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2852
SELECT - col0 + - col2 * col2 * - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2853
SELECT ALL cor0.col2 DIV 9 AS col2 FROM tab1 AS cor0
----
10
6
6

skipif mysql # not compatible
query I rowsort label-2853
SELECT ALL cor0.col2 / 9 AS col2 FROM tab1 AS cor0
----
10
6
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2854
SELECT - + col2 + CAST( col0 AS SIGNED ) AS col2 FROM tab1 cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-2854
SELECT - + col2 + CAST ( col0 AS INTEGER ) AS col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL + col1 * ( col0 * col0 ) AS col2 FROM tab1 AS cor0
----
234
40960
83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-2856
SELECT ALL - col2 DIV + 29 + + col1 FROM tab2 AS cor0
----
16
31
59

skipif mysql # not compatible
query I rowsort label-2856
SELECT ALL - col2 / + 29 + + col1 FROM tab2 AS cor0
----
16
31
59

query I rowsort
SELECT DISTINCT col1 * 74 - col0 AS col1 FROM tab2 cor0
----
1179
2287
4288

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2858
SELECT DISTINCT cor0.col2 / CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2858
SELECT DISTINCT cor0.col2 / CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + 12 col2 FROM tab2 AS cor0
----
38
39
50

query I rowsort
SELECT ALL - + col2 * col0 + col1 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT + cor0.col1 - 20 * 31 * + col2 FROM tab2 cor0
----
-16061
-16709
-23543

query I rowsort
SELECT DISTINCT col0 + - ( col0 ) * col0 FROM tab2 cor0
----
-42
-6006
-6162

query I rowsort
SELECT ALL - 22 * tab2.col1 FROM tab2
----
-1298
-374
-682

query I rowsort
SELECT - + cor0.col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT - - cor0.col0 + + col1 * - col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col1 - + ( + col2 ) * col0 col0 FROM tab0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2868
SELECT + CAST( NULL AS SIGNED ) + + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2868
SELECT + CAST ( NULL AS INTEGER ) + + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 3 - + 95 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 95b4f8d1f8c6430076327dcc6092a86c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 20 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT cor0.col1 * 43 AS col2 FROM tab2 AS cor0
----
1333
2537
731

query I rowsort
SELECT ALL - col2 + - 66 FROM tab1 AS cor0
----
-120
-123
-162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 15 col2 FROM tab2 AS cor0
----
255
465
885

query I rowsort
SELECT cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ( + 92 ) + col1 * - col2 AS col2 FROM tab0 AS cor0
----
-2746
-5
-7370

query I rowsort
SELECT col0 + ( - col1 + - tab1.col1 * + 48 ) FROM tab1
----
-1271
-426
-557

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2877
SELECT - - CAST( + col2 AS SIGNED ) AS col1 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2877
SELECT - - CAST ( + col2 AS INTEGER ) AS col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - tab2.col1 AS col2 FROM tab2, tab1, tab0 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + ( - col0 + + col1 ) * 28 AS col2 FROM tab1
----
-1512
-1876
644

query I rowsort
SELECT 63 * 34 * + cor0.col0 FROM tab1 AS cor0
----
137088
171360
6426

onlyif mysql # use DIV operator for integer division
query I rowsort label-2881
SELECT ALL - col1 DIV + 54 + col1 AS col0 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2881
SELECT ALL - col1 / + 54 + col1 AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT col2 * - 32 FROM tab1 AS cor0
----
-1728
-1824
-3072

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2883
SELECT ALL + CAST( NULL AS SIGNED ) + col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2883
SELECT ALL + CAST ( NULL AS INTEGER ) + col1 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2884
SELECT col0 * + ( col1 ) + ( - col0 ) + - col0 DIV + 68 FROM tab1 AS cor0
----
576
75
959

skipif mysql # not compatible
query I rowsort label-2884
SELECT col0 * + ( col1 ) + ( - col0 ) + - col0 / + 68 FROM tab1 AS cor0
----
576
75
959

query I rowsort
SELECT + - ( + col1 ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + + col1 * - 58 FROM tab1 AS cor0
----
-1508
-580
-754

query I rowsort
SELECT DISTINCT 2 AS col0 FROM tab2 AS cor0
----
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2888
SELECT ALL - cor0.col1 * col1 * CAST( NULL AS SIGNED ) + 90 * - cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2888
SELECT ALL - cor0.col1 * col1 * CAST ( NULL AS INTEGER ) + 90 * - cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2889
SELECT ALL + + 46 + col0 DIV ( - col2 ) - col1 FROM tab0 AS cor0
----
-40
-46
-86

skipif mysql # not compatible
query I rowsort label-2889
SELECT ALL + + 46 + col0 / ( - col2 ) - col1 FROM tab0 AS cor0
----
-40
-46
-86

query I rowsort
SELECT + + col2 * - col2 + + ( col2 * + col0 ) AS col1 FROM tab0 cor0
----
-297
34
574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 1 + col2 col0 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT DISTINCT - - col1 * col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL 14 + - col2 AS col1 FROM tab1 AS cor0
----
-40
-43
-82

query I rowsort
SELECT DISTINCT + col1 * + col1 AS col0 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT col1 + 80 AS col1 FROM tab1 AS cor0
----
106
90
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2896
SELECT DISTINCT + + col2 + CAST( col1 AS SIGNED ) * + cor0.col0 col2 FROM tab0 AS cor0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2896
SELECT DISTINCT + + col2 + CAST ( col1 AS INTEGER ) * + cor0.col0 col2 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2897
SELECT ALL - - col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2897
SELECT ALL - - col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 61 - 14 FROM tab2, tab1 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT ALL + - col2 * - ( col0 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL + + col0 * + 95 + col0 * col2 FROM tab1 cor0
----
15280
447
9728

query I rowsort
SELECT 66 - + tab2.col0 * - 37 FROM tab2, tab0 AS cor0
----
9 values hashing to 64abcf4221ab5ba9930904af19e1b66a

query I rowsort
SELECT DISTINCT ( + tab1.col1 ) * tab1.col1 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL 10 + - col2 AS col1 FROM tab0 AS cor0
----
-23
-72
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 35 * + col2 col1 FROM tab2 cor0
----
1330
910
945

query I rowsort
SELECT - col2 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2906
SELECT ALL - ( col2 ) + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2906
SELECT ALL - ( col2 ) + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + col0 * col0 * cor0.col0 FROM tab2 AS cor0
----
374
474611
493056

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2908
SELECT + CAST( col2 AS SIGNED ) AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2908
SELECT + CAST ( col2 AS INTEGER ) AS col0 FROM tab0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2909
SELECT ALL - CAST( NULL AS SIGNED ) FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2909
SELECT ALL - CAST ( NULL AS INTEGER ) FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + 98 - col1 * - col0 FROM tab1
----
1138
176
738

query I rowsort
SELECT 85 AS col0 FROM tab0
----
85
85
85

query I rowsort
SELECT ALL col2 * 18 AS col1 FROM tab1
----
1026
1728
972

query I rowsort
SELECT + 98 * col2 FROM tab2
----
2548
2646
3724

query I rowsort
SELECT col1 * 72 FROM tab1
----
1872
720
936

query I rowsort
SELECT ALL - - 54 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

onlyif mysql # use DIV operator for integer division
query I rowsort label-2916
SELECT + 77 DIV col2 - col0 AS col0 FROM tab0
----
-22
-89
42

skipif mysql # not compatible
query I rowsort label-2916
SELECT + 77 / col2 - col0 AS col0 FROM tab0
----
-22
-89
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-2917
SELECT - + col0 + cor0.col1 DIV - ( + col2 ) FROM tab0 AS cor0
----
-132
-26
-90

skipif mysql # not compatible
query I rowsort label-2917
SELECT - + col0 + cor0.col1 / - ( + col2 ) FROM tab0 AS cor0
----
-132
-26
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2918
SELECT ( col0 ) DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2918
SELECT ( col0 ) / + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 83 + col2 FROM tab2 cor0
----
109
110
121

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + cor0.col1 col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + 73 FROM tab2, tab0 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT DISTINCT 72 AS col1 FROM tab1, tab1 AS cor0
----
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2923
SELECT DISTINCT CAST( NULL AS SIGNED ) + + 88 FROM tab0, tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2923
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + 88 FROM tab0, tab2 cor0
----
NULL

query I rowsort
SELECT - - col1 * - col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL + 21 + - 16 FROM tab1, tab1 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

onlyif mysql # use DIV operator for integer division
query I rowsort label-2926
SELECT - 50 DIV + 94 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2926
SELECT - 50 / + 94 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2927
SELECT - + CAST( + col2 AS SIGNED ) FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2927
SELECT - + CAST ( + col2 AS INTEGER ) FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2928
SELECT cor0.col1 DIV col0 col2 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2928
SELECT cor0.col1 / col0 col2 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT - - col2 + - col0 * col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - 17 FROM tab0, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 cor1, tab0 AS cor2
----
972 values hashing to d522b52b67b20888d3544d25cb98f232

query I rowsort
SELECT - + col0 * 72 + + col0 FROM tab2 cor0
----
-497
-5538
-5609

query I rowsort
SELECT - + col2 * - col1 + - col1 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT 93 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

onlyif mysql # use DIV operator for integer division
query I rowsort label-2935
SELECT tab0.col2 DIV + col0 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2935
SELECT tab0.col2 / + col0 FROM tab0
----
0
0
1

query I rowsort
SELECT - col1 + col2 + - col1 FROM tab0
----
-100
-139
-193

query I rowsort
SELECT ALL + col2 * + col2 + col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-2938
SELECT ALL col0 DIV col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2938
SELECT ALL col0 / col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT + ( + col0 ) + cor0.col2 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - 3 * col0 + col1 AS col1 FROM tab1 AS cor0
----
-182
-227
17

query I rowsort
SELECT ALL + + col1 - 52 * col2 AS col0 FROM tab1 AS cor0
----
-2782
-2954
-4979

query I rowsort
SELECT + - 89 AS col2 FROM tab0 AS cor0
----
-89
-89
-89

query I rowsort
SELECT ALL col1 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2944
SELECT DISTINCT 72 DIV ( + col0 ) FROM tab1 AS cor0
----
0
1
24

skipif mysql # not compatible
query I rowsort label-2944
SELECT DISTINCT 72 / ( + col0 ) FROM tab1 AS cor0
----
0
1
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 * - col2 + - col0 col0 FROM tab0 AS cor0
----
-30
141
321

query I rowsort
SELECT DISTINCT - - col0 - + cor0.col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT ALL col0 * 21 * - col1 + + col2 FROM tab0 AS cor0
----
-169997
-43311
-71294

query I rowsort
SELECT DISTINCT 85 * col0 + - col0 FROM tab1 AS cor0
----
252
5376
6720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2949
SELECT 39 * + col0 * CAST( NULL AS SIGNED ) + 41 * + col1 * cor0.col1 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2949
SELECT 39 * + col0 * CAST ( NULL AS INTEGER ) + 41 * + col1 * cor0.col1 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + col1 ) + + 72 * - col1 + cor0.col0 AS col2 FROM tab1 AS cor0
----
-1895
-666
-869

onlyif mysql # use DIV operator for integer division
query I rowsort label-2951
SELECT DISTINCT + 32 DIV col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2951
SELECT DISTINCT + 32 / col0 FROM tab0 AS cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2952
SELECT ALL - ( col2 ) DIV + 57 col2 FROM tab1 cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2952
SELECT ALL - ( col2 ) / + 57 col2 FROM tab1 cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * + cor0.col2 * 69 col2 FROM tab1 AS cor0
----
39330
86112
96876

query I rowsort
SELECT + + 92 + col1 + col1 AS col2 FROM tab1 AS cor0
----
112
118
144

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT - 3 FROM tab2, tab2 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT DISTINCT tab1.col1 - - 74 AS col2 FROM tab1
----
100
84
87

query I rowsort
SELECT cor0.col0 + col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + + col0 + - col0 - - 24 * col2 FROM tab2 AS cor0
----
624
648
912

query I rowsort
SELECT + col2 + col2 AS col1 FROM tab2 cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 13 ) col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 50 * tab1.col1 col1 FROM tab1
----
1300
500
650

query I rowsort
SELECT col2 - ( + col1 + - col2 ) * + 44 * 62 FROM tab0
----
-144551
-24470
-261887

query I rowsort
SELECT + col2 + - cor0.col1 * - col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT + 52 FROM tab0, tab1 cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

onlyif mysql # use DIV operator for integer division
query I rowsort label-2966
SELECT col1 DIV + col1 + col0 AS col2 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-2966
SELECT col1 / + col1 + col0 AS col2 FROM tab0
----
25
36
90

query I rowsort
SELECT DISTINCT ( + 15 ) * cor0.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
255
465
885

query I rowsort
SELECT ALL col1 * col0 * - 30 FROM tab2
----
-138060
-40290
-6510

onlyif mysql # use DIV operator for integer division
query I rowsort label-2969
SELECT DISTINCT - 5 DIV + col0 AS col0 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-2969
SELECT DISTINCT - 5 / + col0 AS col0 FROM tab1
----
-1
0

query I rowsort
SELECT - + 22 FROM tab0 AS cor0
----
-22
-22
-22

query I rowsort
SELECT ALL + 82 + cor0.col0 + ( 76 ) AS col1 FROM tab0 AS cor0
----
182
193
247

query I rowsort
SELECT DISTINCT + col2 * + col1 + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT - ( + col1 ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ( - col2 * + col2 ) FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT + 16 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT col1 * - 78 + cor0.col2 - col2 FROM tab1 AS cor0
----
-1014
-2028
-780

query I rowsort
SELECT DISTINCT - col2 + + ( - col2 ) * - col2 FROM tab2 AS cor0
----
1406
650
702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 * + tab2.col1 col0 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - 11 ) col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

query I rowsort
SELECT col0 + + 17 * + col0 AS col2 FROM tab2 AS cor0
----
126
1404
1422

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2981
SELECT ALL - col1 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2981
SELECT ALL - col1 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 37 AS col2 FROM tab1
----
37

query I rowsort
SELECT ALL - + col1 + + ( + col1 ) * col1 AS col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT col1 * ( col1 * - col1 ) + col2 * col2 FROM tab0 AS cor0
----
-634967
-746847
-912672

onlyif mysql # use DIV operator for integer division
query I rowsort label-2985
SELECT ALL + - col0 * + 18 + col1 DIV - col2 FROM tab1 AS cor0
----
-1152
-1440
-54

skipif mysql # not compatible
query I rowsort label-2985
SELECT ALL + - col0 * + 18 + col1 / - col2 FROM tab1 AS cor0
----
-1152
-1440
-54

query I rowsort
SELECT DISTINCT + col0 - + col1 * - col2 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-2987
SELECT DISTINCT - - 28 DIV + 49 + - col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2987
SELECT DISTINCT - - 28 / + 49 + - col2 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2988
SELECT DISTINCT 38 * + col2 * col2 + CAST( NULL AS SIGNED ) * + 96 * + col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2988
SELECT DISTINCT 38 * + col2 * col2 + CAST ( NULL AS INTEGER ) * + 96 * + col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + 12 col1 FROM tab1 AS cor0
----
-1
-14
2

query I rowsort
SELECT DISTINCT 94 * col2 FROM tab0 AS cor0
----
3102
7708
94

query I rowsort
SELECT ALL - 19 FROM tab1 AS cor0
----
-19
-19
-19

query I rowsort
SELECT - ( + col1 ) AS col2 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + col2 * - col1 + cor0.col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL - col2 * - col0 + + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT + col1 * col2 * col1 FROM tab1 cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-2996
SELECT DISTINCT - + col0 DIV + cor0.col1 + + 41 * ( - col1 ) AS col0 FROM tab2 AS cor0
----
-1271
-2420
-701

skipif mysql # not compatible
query I rowsort label-2996
SELECT DISTINCT - + col0 / + cor0.col1 + + 41 * ( - col1 ) AS col0 FROM tab2 AS cor0
----
-1271
-2420
-701

query I rowsort
SELECT ALL - cor0.col2 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - - 2 AS col2 FROM tab1 AS cor0
----
2
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 * - col2 col1 FROM tab1 AS cor0
----
5292
5586
9408

query I rowsort
SELECT DISTINCT - col2 * - cor0.col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - - cor0.col0 * col1 * + col2 AS col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT 30 * + col1 + col2 FROM tab1
----
357
486
834

query I rowsort
SELECT ALL - - 46 * col2 AS col1 FROM tab2 AS cor0
----
1196
1242
1748

onlyif mysql # use DIV operator for integer division
query I rowsort label-3004
SELECT col0 + col0 DIV tab2.col1 FROM tab2
----
7
79
83

skipif mysql # not compatible
query I rowsort label-3004
SELECT col0 + col0 / tab2.col1 FROM tab2
----
7
79
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 45 * + col0 + 42 col2 FROM tab2 AS cor0
----
-273
-3468
-3513

query I rowsort
SELECT DISTINCT + 7 * + col2 + - 21 AS col1 FROM tab2 AS cor0
----
161
168
245

query I rowsort
SELECT 61 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 9b52d3939da22c8931e3d5a72ddfb1b1

query I rowsort
SELECT + 17 + col0 FROM tab2 cor0
----
24
95
96

query I rowsort
SELECT ALL cor0.col1 * cor1.col1 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to b80ce76f8664310580a5197b3984e0f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3010
SELECT - + cor0.col0 DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3010
SELECT - + cor0.col0 / cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT col0 - col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT - + 26 * col2 FROM tab2 AS cor0
----
-676
-702
-988

query I rowsort
SELECT - col1 + cor0.col1 * - col2 AS col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL col2 + - ( 83 ) FROM tab0
----
-1
-50
-82

query I rowsort
SELECT col1 * col1 + + ( col1 ) + 68 * - ( + col0 ) FROM tab1
----
-4242
-5258
498

query I rowsort
SELECT + col1 * + tab2.col0 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL tab2.col0 + - col1 * - ( tab2.col2 ) + col0 AS col1 FROM tab2
----
1690
804
851

query I rowsort
SELECT ALL 21 FROM tab1, tab1 cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT DISTINCT col0 + 31 * - tab0.col1 + + col1 AS col1 FROM tab0
----
-2556
-2641
-2875

query I rowsort
SELECT ALL + tab0.col0 + - col1 * - col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL col1 * - 23 + + 82 FROM tab0
----
-1896
-2011
-2149

onlyif mysql # use DIV operator for integer division
query I rowsort label-3022
SELECT DISTINCT + col1 DIV + 52 + 30 * col1 FROM tab1
----
300
390
780

skipif mysql # not compatible
query I rowsort label-3022
SELECT DISTINCT + col1 / + 52 + 30 * col1 FROM tab1
----
300
390
780

query I rowsort
SELECT DISTINCT 41 FROM tab2, tab0 AS cor0
----
41

query I rowsort
SELECT - - ( - col0 ) * + cor0.col0 * 20 FROM tab2 cor0
----
-121680
-124820
-980

query I rowsort
SELECT ALL + - col0 * - col2 + + col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT + - 54 + 76 AS col1 FROM tab2 AS cor0
----
22
22
22

query I rowsort
SELECT ALL - col0 * + 49 AS col2 FROM tab2 AS cor0
----
-343
-3822
-3871

query I rowsort
SELECT ALL + col0 * - 90 AS col1 FROM tab0 AS cor0
----
-2160
-3150
-8010

query I rowsort
SELECT - 48 + - col2 * - col1 FROM tab2 cor0
----
1486
598
789

query I rowsort
SELECT DISTINCT + col2 * 81 FROM tab0 AS cor0
----
2673
6642
81

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL <= ( + col1 * + col0 )
----

query I rowsort
SELECT col1 * + col1 * col1 + + col2 * - col1 AS col1 FROM tab1
----
16172
430
949

query I rowsort
SELECT ALL + col1 * tab1.col1 AS col1 FROM tab1
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-3035
SELECT - col0 DIV col2 + col1 FROM tab1
----
13
26
9

skipif mysql # not compatible
query I rowsort label-3035
SELECT - col0 / col2 + col1 FROM tab1
----
13
26
9

query I rowsort
SELECT ALL tab2.col2 * tab2.col0 AS col1 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + col2 * + col1 * - col0 AS col1 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - col1 * tab0.col0 * + col0 AS col1 FROM tab0
----
-118825
-49536
-720811

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL NOT IN ( + tab1.col1 )
----

query I rowsort
SELECT DISTINCT + col1 * - tab0.col1 * col1 AS col2 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT ALL + col2 + + col1 * col1 + + col1 * + col2 AS col2 FROM tab0
----
10267
15825
9507

query I rowsort
SELECT DISTINCT tab2.col1 - col2 AS col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT tab1.col0 - + col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT + col1 + col0 * + tab0.col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + tab1.col1 + col1 FROM tab1 WHERE + col1 + col2 <= NULL
----

query I rowsort
SELECT ALL - col1 FROM tab0 WHERE NOT - col0 / col1 + col1 + col0 IN ( tab0.col1 / + col1 )
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3048
SELECT col2 DIV - col2 + col1 col0 FROM tab1
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3048
SELECT col2 / - col2 + col1 col0 FROM tab1
----
12
25
9

query I rowsort
SELECT ALL + tab0.col0 * - col0 AS col1 FROM tab0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-3050
SELECT ALL + col1 DIV col2 + tab0.col0 AS col0 FROM tab0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-3050
SELECT ALL + col1 / col2 + tab0.col0 AS col0 FROM tab0
----
132
26
90

query I rowsort
SELECT col2 * + col0 - col0 AS col1 FROM tab1 WHERE NOT ( col0 ) NOT IN ( tab1.col2 + col2 )
----

query I rowsort
SELECT DISTINCT tab2.col2 + - col2 * - col1 AS col2 FROM tab2
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-3053
SELECT ALL col0 * col0 - col1 * col2 DIV col1 AS col1 FROM tab1
----
-45
4039
6304

skipif mysql # not compatible
query I rowsort label-3053
SELECT ALL col0 * col0 - col1 * col2 / col1 AS col1 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT ALL col0 + + col0 * tab0.col1 FROM tab0
----
2088
3430
8188

query III rowsort
SELECT * FROM tab0 WHERE NOT col2 NOT BETWEEN col2 + - col2 AND NULL
----

query I rowsort
SELECT - col0 * col1 * + col2 + col2 FROM tab1
----
-36423
-4158
-99744

query I rowsort
SELECT DISTINCT tab0.col1 + col2 * + col0 - + col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT col0 * + col2 * - col0 AS col2 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT col1 FROM tab2 WHERE NULL IN ( - tab2.col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * tab0.col2 * - col1 col0 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT ALL tab2.col0 * col1 + col0 + col1 AS col0 FROM tab2
----
1439
255
4739

onlyif mysql # use DIV operator for integer division
query I rowsort label-3062
SELECT col0 * col0 DIV col2 FROM tab1
----
0
66
71

skipif mysql # not compatible
query I rowsort label-3062
SELECT col0 * col0 / col2 FROM tab1
----
0
66
71

query I rowsort
SELECT col2 * + col0 + col1 * col0 AS col0 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT - col2 + tab1.col1 * + col0 + + col1 AS col0 FROM tab1 WHERE NULL NOT IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3065
SELECT ALL + col2 * col0 DIV col1 + + col2 + + col2 * col0 AS col1 FROM tab2
----
2088
222
3216

skipif mysql # not compatible
query I rowsort label-3065
SELECT ALL + col2 * col0 / col1 + + col2 + + col2 * col0 AS col1 FROM tab2
----
2088
222
3216

onlyif mysql # use DIV operator for integer division
query I rowsort label-3066
SELECT DISTINCT - col2 DIV col1 AS col2 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-3066
SELECT DISTINCT - col2 / col1 AS col2 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT - col0 * - col1 AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col1 + - col1 * col0 + + col2 FROM tab2
----
-1288
-159
-4517

query I rowsort
SELECT DISTINCT tab1.col1 FROM tab0 AS cor0 CROSS JOIN tab1
----
10
13
26

query I rowsort
SELECT DISTINCT + tab1.col0 FROM tab1 AS cor0 CROSS JOIN tab1
----
3
64
80

query I rowsort
SELECT + cor0.col0 * + col0 + + col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT + col1 * + col0 + col1 FROM tab2 AS cor0
----
1360
248
4661

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col0 / + col0 NOT IN ( + col1 - + col2 )
----

query I rowsort
SELECT ALL + col1 - col2 FROM tab2 AS cor0 WHERE + col1 IN ( cor0.col0 * - col1 )
----

query I rowsort
SELECT ALL + cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE col2 + - cor0.col2 * - cor0.col2 IN ( - col2 )
----

query I rowsort
SELECT + cor0.col2 * + col2 AS col0 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT + col1 AS col1 FROM tab0 AS cor0 WHERE + col2 * + col0 + col2 + - col1 <= NULL
----

query I rowsort
SELECT ALL + - 74 AS col0 FROM tab2 AS cor0
----
-74
-74
-74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 26 * - col0 col1 FROM tab0 AS cor0
----
-2314
-624
-910

query I rowsort
SELECT ALL - + 65 AS col1 FROM tab2 AS cor0
----
-65
-65
-65

query I rowsort
SELECT + ( col0 ) * + 86 + col1 FROM tab1 AS cor0
----
284
5514
6893

query I rowsort
SELECT DISTINCT col1 + + col1 * - col2 * - col0 FROM tab1
----
36490
4238
99853

query I rowsort
SELECT + ( cor0.col0 ) + ( 41 ) AS col1 FROM tab1 AS cor0
----
105
121
44

query I rowsort
SELECT ALL - + 52 * - cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 2f7302093825f052a60bd475237923bd

query I rowsort
SELECT DISTINCT - col1 + + ( - cor0.col2 ) AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL + cor0.col1 * ( ( - cor0.col1 ) ) * + 46 + 99 AS col2 FROM tab1 cor0
----
-30997
-4501
-7675

query I rowsort
SELECT - cor0.col0 + 29 * col1 FROM tab1 AS cor0
----
226
297
751

query I rowsort
SELECT + 41 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT DISTINCT + + col2 - - 8 AS col1 FROM tab1 AS cor0
----
104
62
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-3091
SELECT - col2 * 48 DIV ( + col2 ) FROM tab1 AS cor0
----
-48
-48
-48

skipif mysql # not compatible
query I rowsort label-3091
SELECT - col2 * 48 / ( + col2 ) FROM tab1 AS cor0
----
-48
-48
-48

query I rowsort
SELECT ALL + - col1 * - 51 + col1 AS col0 FROM tab1 cor0
----
1352
520
676

query I rowsort
SELECT DISTINCT + col0 * - 35 AS col0 FROM tab1 AS cor0
----
-105
-2240
-2800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3094
SELECT DISTINCT + col2 + + CAST( + col2 AS SIGNED ) * col1 col1 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3094
SELECT DISTINCT + col2 + + CAST ( + col2 AS INTEGER ) * col1 col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL + col2 + - 18 AS col2 FROM tab0 AS cor0
----
-17
15
64

query I rowsort
SELECT ALL - 11 * + col2 AS col2 FROM tab0
----
-11
-363
-902

query I rowsort
SELECT - 60 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 1a0b29f8e6f82c54623a665ba4af8fd1

query I rowsort
SELECT col0 * - ( - col0 ) AS col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT ALL - 17 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab2 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 77ce60d8d42550cc1b5a38c7d1dc5d13

query I rowsort
SELECT ALL - - col2 + + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT 32 * col2 FROM tab0 cor0
----
1056
2624
32

query I rowsort
SELECT ALL - + col1 * + ( col0 ) - col2 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-3926
101
512

skipif mysql # not compatible
query I rowsort
SELECT - col2 - CAST ( - 30 + col1 AS REAL ) FROM tab0
----
-143
-68
-89

query I rowsort
SELECT ALL col0 * + col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL ( + col1 ) * + col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT 71 * + tab1.col0 FROM tab1
----
213
4544
5680

query I rowsort
SELECT + - ( col0 ) * col1 * - cor0.col1 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT ALL - col0 + col2 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - - cor0.col1 * col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3111
SELECT DISTINCT CAST( NULL AS SIGNED ) * 70 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3111
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 70 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 59 AS col2 FROM tab2, tab0 AS cor0
----
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - cor0.col1 ) * col2 col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + 97 * col2 AS col1 FROM tab1 cor0
----
5238
5529
9312

query I rowsort
SELECT ALL 61 * col2 AS col2 FROM tab2
----
1586
1647
2318

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3117
SELECT ALL + 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-3117
SELECT ALL + CAST ( NULL AS INTEGER ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * - col1 + + col0 AS col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT col0 + - tab0.col0 + + col0 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT col1 * col0 + + 22 + - col0 * col1 * + col0 AS col2 FROM tab2
----
-104732
-1280
-354332

query I rowsort
SELECT ALL - cor0.col1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT tab2.col1 * tab2.col0 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3123
SELECT + col2 * - col1 DIV col1 + col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3123
SELECT + col2 * - col1 / col1 + col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL col2 + - col2 * ( ( col1 ) ) FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + col1 + 69 AS col0 FROM tab0 AS cor0
----
155
160
166

query I rowsort
SELECT DISTINCT - col0 * ( col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col0 * ( col0 ) FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3128
SELECT DISTINCT - - col0 * CAST( - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-3128
SELECT DISTINCT - - col0 * CAST ( - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - col0 + - 42 AS col2 FROM tab1 AS cor0
----
-106
-122
-45

query I rowsort
SELECT DISTINCT + + col2 * - col1 + - col2 * + col2 * - col1 AS col0 FROM tab0 AS cor0
----
0
604422
90816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col1 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - + col2 + - 12 FROM tab1 AS cor0
----
-108
-66
-69

query I rowsort
SELECT col0 + ( - col1 + - cor0.col2 ) FROM tab2 AS cor0
----
-51
-7
24

query I rowsort
SELECT DISTINCT + + col1 + ( + 33 + - col1 ) AS col1 FROM tab1 AS cor0
----
33

query I rowsort
SELECT ALL - tab1.col1 + - col1 * tab1.col1 AS col1 FROM tab1
----
-110
-182
-702

query I rowsort
SELECT ALL - cor0.col1 * + col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - col0 * 11 FROM tab2 cor0
----
-77
-858
-869

query I rowsort
SELECT - col0 + - 30 + col2 AS col1 FROM tab2 AS cor0
----
-10
-71
-82

query I rowsort
SELECT DISTINCT - + col2 + + ( 4 ) + cor0.col0 * - col0 FROM tab1 AS cor0
----
-4149
-59
-6492

query I rowsort
SELECT DISTINCT col0 * - tab2.col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - tab0.col0 * - col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT + tab1.col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - tab1.col0 * + col2 * + col0 AS col2 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT - col0 * - cor0.col2 + cor0.col0 * col2 AS col0 FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT - col2 + + col0 + col1 FROM tab0 cor0
----
131
77
98

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE ( col1 * col2 ) NOT IN ( + col2 * - col2 ) OR NOT + cor0.col1 = NULL
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT - col2 + + col0 * cor0.col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT col1 * + col1 + - col0 * + col1 FROM tab1 AS cor0
----
-540
-871
598

query I rowsort
SELECT + col1 * + tab0.col0 + col2 + + tab0.col0 FROM tab0
----
2121
3431
8270

query I rowsort
SELECT col2 * + col0 + - tab1.col0 AS col0 FROM tab1
----
159
3584
7600

query I rowsort
SELECT DISTINCT - col2 - col1 * cor0.col0 * + col1 AS col0 FROM tab0 AS cor0
----
-177537
-329316
-737091

query I rowsort
SELECT + col0 * + cor0.col0 + + col0 AS col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT - 64 * - col1 - + col1 FROM tab2 AS cor0
----
1071
1953
3717

query I rowsort
SELECT - cor0.col2 * - cor0.col1 + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL + + col2 - - col1 AS col1 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col2 + - col1 col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - cor0.col2 - cor0.col0 AS col2 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 507d0f67070240a638094d82967d5d67

query I rowsort
SELECT ALL - 93 * + col0 FROM tab0 AS cor0
----
-2232
-3255
-8277

query I rowsort
SELECT ALL + col2 * + col1 + - col0 + col2 AS col1 FROM tab2 cor0
----
1482
605
857

onlyif mysql # use DIV operator for integer division
query I rowsort label-3160
SELECT DISTINCT - - col1 + + col1 DIV cor0.col1 AS col0 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-3160
SELECT DISTINCT - - col1 + + col1 / cor0.col1 AS col0 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT 92 * + col1 AS col2 FROM tab0 AS cor0
----
7912
8372
8924

query I rowsort
SELECT col2 + + col0 + + col0 AS col1 FROM tab0
----
260
71
81

query I rowsort
SELECT + cor0.col2 - cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 81a5cd95f3bf6bcb4ae24bb35bb8df50

query I rowsort
SELECT + col1 + - cor0.col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT + cor0.col1 AS col2 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT - 0 + - col2 AS col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + col2 + - col0 * + col1 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT + col0 + - col2 * + col2 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT - - cor0.col2 + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 62 + + col1 col0 FROM tab2
----
121
79
93

query I rowsort
SELECT col0 + + col1 AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL - col1 - + col0 * + col1 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL - col2 + + col0 * ( - col1 * col2 + - 95 ) FROM tab0 cor0
----
-6721
-672655
-70425

query I rowsort
SELECT + col2 + - col0 AS col1 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT ALL col0 * + ( + 73 ) + col0 AS col1 FROM tab0 AS cor0
----
1776
2590
6586

query I rowsort
SELECT col0 + - 75 * ( - col1 ) AS col2 FROM tab2 AS cor0
----
1354
2332
4503

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 + + col2 FROM tab1 cor0
----
-2862
-3192
-9120

query I rowsort
SELECT 54 FROM tab0
----
54
54
54

query I rowsort
SELECT ALL col1 * - 9 AS col0 FROM tab0 cor0
----
-774
-819
-873

query I rowsort
SELECT DISTINCT + col0 + + ( col0 ) + col1 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT 64 * 0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + ( col1 ) AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3183
SELECT CAST( 34 AS SIGNED ) + col2 FROM tab1 AS cor0
----
130
88
91

skipif mysql # not compatible
query I rowsort label-3183
SELECT CAST ( 34 AS INTEGER ) + col2 FROM tab1 AS cor0
----
130
88
91

query I rowsort
SELECT ALL ( col0 ) * col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - + ( cor0.col1 ) * col2 + - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-3186
SELECT DISTINCT col0 - - col2 DIV - col0 FROM tab1 AS cor0
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-3186
SELECT DISTINCT col0 - - col2 / - col0 FROM tab1 AS cor0
----
-15
64
79

query I rowsort
SELECT cor1.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ( cor0.col2 ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - + ( col2 ) * col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + + 16 + col0 AS col2 FROM tab2 AS cor0
----
23
94
95

query I rowsort
SELECT - + cor0.col0 * col2 + + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - 30 FROM tab2 AS cor0
----
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 + - ( ( + col1 ) + + 99 ) col2 FROM tab0 AS cor0
----
-161
607
7108

query I rowsort
SELECT ALL + - ( + col2 ) FROM tab0 cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 col0 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-3196
SELECT + col1 DIV col1 + + 21 AS col1 FROM tab2 AS cor0
----
22
22
22

skipif mysql # not compatible
query I rowsort label-3196
SELECT + col1 / col1 + + 21 AS col1 FROM tab2 AS cor0
----
22
22
22

query I rowsort
SELECT + 57 * - col0 FROM tab0 AS cor0
----
-1368
-1995
-5073

query I rowsort
SELECT DISTINCT + col1 * - col1 + 26 * cor0.col2 * col0 + - 12 * - col2 AS col1 FROM tab1 AS cor0
----
200663
4184
95432

query I rowsort
SELECT ALL - col2 - col1 AS col2 FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * cor0.col0 col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL 53 + col1 AS col0 FROM tab0
----
139
144
150

query I rowsort
SELECT DISTINCT - ( + tab2.col0 ) * col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL col1 * col2 + col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL col0 + 22 FROM tab0
----
111
46
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3205
SELECT ALL + col1 + - 25 * + col2 + - CAST( col0 AS SIGNED ) AS col1 FROM tab1
----
-1327
-1479
-2467

skipif mysql # not compatible
query I rowsort label-3205
SELECT ALL + col1 + - 25 * + col2 + - CAST ( col0 AS INTEGER ) AS col1 FROM tab1
----
-1327
-1479
-2467

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 42 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT DISTINCT + + col0 + col2 * ( - col2 ) FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT - + 46 * col2 AS col0 FROM tab1 AS cor0
----
-2484
-2622
-4416

query I rowsort
SELECT DISTINCT - cor0.col0 * col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-3210
SELECT DISTINCT 72 DIV - col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3210
SELECT DISTINCT 72 / - col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - + 50 + + col0 * col1 FROM tab0 AS cor0
----
2014
3345
8049

query I rowsort
SELECT col0 * col1 * - col1 AS col2 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT - 99 + + cor0.col1 * 33 AS col2 FROM tab1 AS cor0
----
231
330
759

query I rowsort
SELECT col1 + 65 * - col2 * col2 + - 4 FROM tab1
----
-189518
-211179
-599031

query I rowsort
SELECT col2 * + ( + col2 ) * col2 + cor0.col0 - 64 * + col1 AS col2 FROM tab2 AS cor0
----
13878
17706
53863

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3216
SELECT - CAST( NULL AS SIGNED ) * col0 * col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3216
SELECT - CAST ( NULL AS INTEGER ) * col0 * col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col2 AS col1 FROM tab0, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + col1 * 65 FROM tab0 AS cor0
----
5590
5915
6305

query I rowsort
SELECT + col2 * 76 * col1 FROM tab0 AS cor0
----
215688
567112
7372

onlyif mysql # use DIV operator for integer division
query I rowsort label-3220
SELECT DISTINCT - + cor0.col1 DIV ( - col0 + col2 ) FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3220
SELECT DISTINCT - + cor0.col1 / ( - col0 + col2 ) FROM tab1 cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + cor0.col1 ) * col1 col1 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT ( + tab2.col2 + col1 ) * + 12 FROM tab2
----
1020
660
696

query I rowsort
SELECT DISTINCT + - 75 * + 85 AS col0 FROM tab0 cor0
----
-6375

query I rowsort
SELECT - col1 + - cor0.col0 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT - col1 + + 57 FROM tab0 AS cor0
----
-29
-34
-40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + col1 col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + col1 + col0 * col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL + ( - 5 ) FROM tab1 AS cor0
----
-5
-5
-5

query I rowsort
SELECT ALL - + ( 2 ) * col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT + 48 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT - + col0 + 30 AS col0 FROM tab1 AS cor0
----
-34
-50
27

query I rowsort
SELECT 65 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT DISTINCT + + 58 AS col2 FROM tab2 AS cor0
----
58

query I rowsort
SELECT ALL - cor0.col1 + col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + cor0.col0 * + col2 + - col1 + col0 AS col2 FROM tab1 cor0
----
139
3702
7747

query I rowsort
SELECT ALL - cor0.col0 + + col1 AS col1 FROM tab0 AS cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col2 * - col0 col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - cor0.col0 * col1 + col2 * cor0.col2 FROM tab1 AS cor0
----
2609
2838
8176

query I rowsort
SELECT - col2 + 72 AS col2 FROM tab0 AS cor0
----
-10
39
71

query I rowsort
SELECT - col0 * - col0 + + 28 + + col1 * cor0.col2 * 75 FROM tab1 AS cor0
----
100028
105337
46874

query I rowsort
SELECT ALL col2 * col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-3242
SELECT ALL col1 DIV 33 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3242
SELECT ALL col1 / 33 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT cor0.col2 + + col2 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 54 - col1 col1 FROM tab1 cor0
----
2890
3068
5171

query I rowsort
SELECT DISTINCT + col0 + - 83 * col0 AS col0 FROM tab2 AS cor0
----
-574
-6396
-6478

onlyif mysql # use DIV operator for integer division
query I rowsort label-3246
SELECT ALL cor0.col1 DIV - 11 + col1 * - col0 + col0 * - col1 AS col1 FROM tab2 AS cor0
----
-2687
-436
-9209

skipif mysql # not compatible
query I rowsort label-3246
SELECT ALL cor0.col1 / - 11 + col1 * - col0 + col0 * - col1 AS col1 FROM tab2 AS cor0
----
-2687
-436
-9209

query I rowsort
SELECT + cor0.col1 * - cor0.col0 + 36 FROM tab1 cor0
----
-1004
-42
-604

query I rowsort
SELECT ALL col2 + col1 + ( - col1 * + col0 ) AS col2 FROM tab1 AS cor0
----
-573
-931
2

query I rowsort
SELECT + ( - cor0.col0 ) * - col0 + col1 AS col0 FROM tab0 cor0
----
1322
662
8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-3250
SELECT - col1 + - col1 DIV col1 FROM tab2 cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-3250
SELECT - col1 + - col1 / col1 FROM tab2 cor0
----
-18
-32
-60

query I rowsort
SELECT + col1 * ( col1 ) * col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT ( col0 ) * col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + - col2 + col1 * col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL - col0 * + col2 * - col0 AS col1 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - - col0 * col1 + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL - 26 AS col1 FROM tab1 AS cor0
----
-26
-26
-26

query I rowsort
SELECT DISTINCT - - 33 * col0 AS col2 FROM tab1 AS cor0
----
2112
2640
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-3258
SELECT ALL + col1 * col2 + 26 DIV + col1 + col0 AS col2 FROM tab1 AS cor0
----
1330
1408
636

skipif mysql # not compatible
query I rowsort label-3258
SELECT ALL + col1 * col2 + 26 / + col1 + col0 AS col2 FROM tab1 AS cor0
----
1330
1408
636

query I rowsort
SELECT ALL - tab1.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT 74 + col2 FROM tab0
----
107
156
75

query I rowsort
SELECT ALL - col1 - + col1 AS col1 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT ALL col0 * col0 + + col2 AS col1 FROM tab0
----
1226
609
8003

query I rowsort
SELECT ALL 48 + tab1.col0 * ( + 24 ) AS col2 FROM tab1
----
120
1584
1968

query I rowsort
SELECT ALL + cor0.col1 * - cor0.col0 AS col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 09a48fec24dd5ded01e53ec00cd6a7a1

query I rowsort
SELECT + 27 * col1 FROM tab0 AS cor0
----
2322
2457
2619

query I rowsort
SELECT DISTINCT - col0 + - cor0.col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + + cor0.col2 + + col2 AS col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT 36 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT col0 * - col1 * - tab1.col1 FROM tab1
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-3270
SELECT 70 DIV + col2 FROM tab0
----
0
2
70

skipif mysql # not compatible
query I rowsort label-3270
SELECT 70 / + col2 FROM tab0
----
0
2
70

query I rowsort
SELECT DISTINCT col0 * - col2 * 10 + + col2 FROM tab2
----
-1863
-20254
-29982

query I rowsort
SELECT - - col1 * - ( + cor0.col0 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3273
SELECT ALL 63 DIV col1 FROM tab2
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3273
SELECT ALL 63 / col1 FROM tab2
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3274
SELECT col2 * col2 DIV col1 AS col1 FROM tab1
----
112
324
708

skipif mysql # not compatible
query I rowsort label-3274
SELECT col2 * col2 / col1 AS col1 FROM tab1
----
112
324
708

query I rowsort
SELECT DISTINCT + tab2.col2 FROM tab2, tab0, tab1 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT 1 * - 61 AS col0 FROM tab2, tab1 cor0
----
-61

query I rowsort
SELECT DISTINCT + col0 * + 55 AS col0 FROM tab2
----
385
4290
4345

query I rowsort
SELECT + 16 FROM tab0, tab1 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3279
SELECT + col2 + CAST( - 75 AS SIGNED ) AS col2 FROM tab1 cor0
----
-18
-21
21

skipif mysql # not compatible
query I rowsort label-3279
SELECT + col2 + CAST ( - 75 AS INTEGER ) AS col2 FROM tab1 cor0
----
-18
-21
21

query I rowsort
SELECT ALL - 38 + + 47 FROM tab2 cor0
----
9
9
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( ( + col1 ) ) + col2 * 70 col2 FROM tab1 AS cor0
----
3754
3980
6707

query I rowsort
SELECT - 66 FROM tab0, tab0 cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT DISTINCT + - col0 * + 31 FROM tab2 AS cor0
----
-217
-2418
-2449

query I rowsort
SELECT DISTINCT 67 AS col1 FROM tab2 AS cor0
----
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-3285
SELECT col2 DIV + 15 FROM tab1 AS cor0
----
3
3
6

skipif mysql # not compatible
query I rowsort label-3285
SELECT col2 / + 15 FROM tab1 AS cor0
----
3
3
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3286
SELECT DISTINCT + col1 DIV ( col1 + - col0 ) FROM tab0 AS cor0
----
1
45

skipif mysql # not compatible
query I rowsort label-3286
SELECT DISTINCT + col1 / ( col1 + - col0 ) FROM tab0 AS cor0
----
1
45

query I rowsort
SELECT ALL + ( + ( col0 ) ) + 49 AS col1 FROM tab1 AS cor0
----
113
129
52

query I rowsort
SELECT + + 3 AS col2 FROM tab0 AS cor0
----
3
3
3

query I rowsort
SELECT - - col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + - 67 * - col0 AS col0 FROM tab2 AS cor0
----
469
5226
5293

query I rowsort
SELECT ALL - - col2 + col2 * 14 * cor0.col2 AS col1 FROM tab0 AS cor0
----
15
15279
94218

query I rowsort
SELECT DISTINCT 32 * cor0.col2 + col0 AS col0 FROM tab1 AS cor0
----
1731
1888
3152

onlyif mysql # use DIV operator for integer division
query I rowsort label-3293
SELECT 27 DIV - col1 AS col1 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3293
SELECT 27 / - col1 AS col1 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT + 33 * col2 FROM tab2 AS cor0
----
1254
858
891

onlyif mysql # use DIV operator for integer division
query I rowsort label-3295
SELECT - ( - col1 ) + + cor0.col1 DIV - col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-3295
SELECT - ( - col1 ) + + cor0.col1 / - col1 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT - + 41 * col0 * + ( - col0 ) FROM tab1 AS cor0
----
167936
262400
369

query I rowsort
SELECT DISTINCT cor0.col1 - ( - 88 ) FROM tab2, tab0, tab1 AS cor0
----
101
114
98

query I rowsort
SELECT ALL 13 FROM tab0, tab2 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

onlyif mysql # use DIV operator for integer division
query I rowsort label-3299
SELECT tab0.col0 + - ( + col2 ) DIV col2 AS col1 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-3299
SELECT tab0.col0 + - ( + col2 ) / col2 AS col1 FROM tab0
----
23
34
88

query I rowsort
SELECT ALL col2 + col1 * col0 + - col1 FROM tab2
----
1364
213
4569

query I rowsort
SELECT DISTINCT col2 * col1 + col2 + - col1 * + 13 AS col0 FROM tab0
----
-1163
1753
6361

query I rowsort
SELECT 96 * 86 * col2 FROM tab2 AS cor0
----
214656
222912
313728

query I rowsort
SELECT - + col0 * - 64 FROM tab2 AS cor0
----
448
4992
5056

query I rowsort
SELECT - ( col1 ) * col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ( cor0.col0 ) * + col2 * cor0.col2 FROM tab2 AS cor0
----
114076
5103
52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-3306
SELECT + + 14 DIV - col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3306
SELECT + + 14 / - col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3307
SELECT DISTINCT - CAST( col0 AS SIGNED ) DIV col1 + col2 * col0 + col1 FROM tab0 cor0
----
132
7389
878

skipif mysql # not compatible
query I rowsort label-3307
SELECT DISTINCT - CAST ( col0 AS INTEGER ) / col1 + col2 * col0 + col1 FROM tab0 cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3308
SELECT DISTINCT - + 87 DIV cor0.col0 FROM tab1 AS cor0
----
-1
-29

skipif mysql # not compatible
query I rowsort label-3308
SELECT DISTINCT - + 87 / cor0.col0 FROM tab1 AS cor0
----
-1
-29

query I rowsort
SELECT ALL + ( - col2 ) * cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3310
SELECT - CAST( + col1 AS SIGNED ) AS col0 FROM tab2 cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-3310
SELECT - CAST ( + col1 AS INTEGER ) AS col0 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + ( - 47 ) * + col1 FROM tab2 AS cor0
----
-1457
-2773
-799

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 87 col0 FROM tab2 AS cor0
----
-87
-87
-87

query I rowsort
SELECT - col0 + + col1 AS col0 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT 54 * + col0 * + 40 - 91 AS col1 FROM tab0
----
192149
51749
75509

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3315
SELECT - - 51 + - col2 * + CAST( col0 * col0 + col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1839
-233991
-615597

skipif mysql # not compatible
query I rowsort label-3315
SELECT - - 51 + - col2 * + CAST ( col0 * col0 + col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1839
-233991
-615597

query I rowsort
SELECT - - cor0.col2 - col1 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3317
SELECT + 99 + + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3317
SELECT + 99 + + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 23 * - col1 - 15 * 2 FROM tab1 AS cor0
----
200
269
568

query I rowsort
SELECT + col2 + col0 * ( ( col0 ) ) AS col1 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3320
SELECT - col1 * - col1 + + CAST( + cor0.col1 AS SIGNED ) FROM tab2 cor0
----
306
3540
992

skipif mysql # not compatible
query I rowsort label-3320
SELECT - col1 * - col1 + + CAST ( + cor0.col1 AS INTEGER ) FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT + col1 + cor0.col0 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + + 80 AS col0 FROM tab0 cor0
----
80
80
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3323
SELECT - col0 + - CAST( NULL AS SIGNED ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3323
SELECT - col0 + - CAST ( NULL AS INTEGER ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 + cor0.col2 + + 71 AS col0 FROM tab1 AS cor0
----
179
185
263

query I rowsort
SELECT DISTINCT - col2 + + col2 + col1 * col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - cor0.col1 + - col1 + - 56 AS col2 FROM tab2 AS cor0
----
-118
-174
-90

query I rowsort
SELECT DISTINCT + - col2 + 78 + 13 FROM tab1 AS cor0
----
-5
34
37

query I rowsort
SELECT + + col2 * col0 + - col2 FROM tab1 cor0
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 47 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 6942a0d9558277afd0d00408d65cf5aa

query I rowsort
SELECT - + col2 * - 29 + col2 + col2 AS col2 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT DISTINCT 74 + + 3 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
77

query I rowsort
SELECT ALL col1 + cor0.col0 AS col1 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col1 + col2 col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + - col2 * + col0 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3336
SELECT col2 DIV cor0.col0 - + col0 FROM tab0 AS cor0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-3336
SELECT col2 / cor0.col0 - + col0 FROM tab0 AS cor0
----
-23
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - ( cor0.col0 ) col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + cor0.col2 + + 68 AS col0 FROM tab1 AS cor0
----
122
125
164

query I rowsort
SELECT + - col1 * + ( 20 ) + + col1 AS col2 FROM tab0 AS cor0
----
-1634
-1729
-1843

query I rowsort
SELECT ALL cor0.col2 + - col2 * col2 * col0 AS col0 FROM tab1 cor0
----
-207879
-737184
-8694

query I rowsort
SELECT ALL - + col2 * ( + ( col0 ) ) + ( - col2 ) * - col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 * - col2 + col0 FROM tab2 AS cor0
----
-1365
-598
-722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * - tab1.col0 col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 064f0d12f5a54890818030ba889e7e5c

query I rowsort
SELECT DISTINCT + col1 * tab0.col0 * col0 AS col1 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT ALL col0 * - col2 * 22 AS col2 FROM tab0
----
-160556
-17424
-770

query I rowsort
SELECT + + col1 * - 63 + - col1 FROM tab0 AS cor0
----
-5504
-5824
-6208

query I rowsort
SELECT ALL + + col0 * + 52 + col1 * + col0 AS col0 FROM tab0 cor0
----
12727
3312
5215

query I rowsort
SELECT DISTINCT + col1 * col1 * col0 + col1 AS col2 FROM tab0 AS cor0
----
177590
329412
737100

query I rowsort
SELECT ALL - + col2 - col1 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3350
SELECT col1 DIV cor0.col0 + col2 AS col0 FROM tab2 AS cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-3350
SELECT col1 / cor0.col0 + col2 AS col0 FROM tab2 AS cor0
----
26
31
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3351
SELECT DISTINCT - col0 + + CAST( cor0.col0 AS SIGNED ) DIV col1 FROM tab1 AS cor0
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-3351
SELECT DISTINCT - col0 + + CAST ( cor0.col0 AS INTEGER ) / col1 FROM tab1 AS cor0
----
-3
-58
-74

query I rowsort
SELECT ALL + col0 * + ( - col1 ) - cor0.col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT - - col2 * ( - col2 ) + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT DISTINCT + - col1 - col1 FROM tab0 cor0
----
-172
-182
-194

query I rowsort
SELECT ALL + cor0.col1 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT 93 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

query I rowsort
SELECT ALL 57 + col1 + ( 54 ) FROM tab2 AS cor0
----
128
142
170

query I rowsort
SELECT - 32 * col2 AS col2 FROM tab1 AS cor0
----
-1728
-1824
-3072

query I rowsort
SELECT DISTINCT + 48 AS col2 FROM tab0
----
48

query I rowsort
SELECT DISTINCT + col1 - cor0.col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - col1 + + col1 - col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL + col1 - col1 * + col0 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT + 88 * col2 * + 16 FROM tab0 AS cor0
----
115456
1408
46464

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3364
SELECT ( col1 ) * - CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-3364
SELECT ( col1 ) * - CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 57 * col2 + - ( + col2 ) col0 FROM tab2 AS cor0
----
-1508
-1566
-2204

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3366
SELECT ALL + tab2.col0 * - col0 + + CAST( NULL AS DECIMAL ) * ( - col1 ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3366
SELECT ALL + tab2.col0 * - col0 + + CAST ( NULL AS REAL ) * ( - col1 ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col2 + + ( - tab0.col0 ) * + col0 + + col0 * - col1 FROM tab0
----
-15938
-2607
-4619

query I rowsort
SELECT ALL - ( - col0 ) + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + 38 + - 94 AS col2 FROM tab0 AS cor0
----
-56

query I rowsort
SELECT DISTINCT 88 * col2 + - col0 * + ( + ( - cor0.col1 ) ) FROM tab2 AS cor0
----
2593
4687
6890

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 87 + col2 col2 FROM tab1 AS cor0
----
141
144
183

query I rowsort
SELECT - cor0.col0 - + col2 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3373
SELECT CAST( NULL AS SIGNED ) * + col0 * col1 + CAST( ( + col0 ) AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3373
SELECT CAST ( NULL AS INTEGER ) * + col0 * col1 + CAST ( ( + col0 ) AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 39 + col2 * - col1 FROM tab1 cor0
----
-1209
-1365
-531

query I rowsort
SELECT DISTINCT + col1 * + col1 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT - cor0.col2 - col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT - ( - 6 ) + + col0 AS col2 FROM tab2 AS cor0
----
13
84
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3378
SELECT CAST( NULL AS SIGNED ) - + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3378
SELECT CAST ( NULL AS INTEGER ) - + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + col1 * - 67 FROM tab1 AS cor0
----
-1739
-606
-791

query I rowsort
SELECT cor0.col2 + col0 * col2 + ( col1 * + col1 + col0 ) AS col1 FROM tab0 AS cor0
----
15750
8245
9480

query I rowsort
SELECT DISTINCT + col2 * col0 * col2 AS col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT 61 + col0 * 83 AS col2 FROM tab0 AS cor0
----
2053
2966
7448

onlyif mysql # use DIV operator for integer division
query I rowsort label-3383
SELECT col0 + + col0 + - tab2.col1 DIV tab2.col1 FROM tab2
----
13
155
157

skipif mysql # not compatible
query I rowsort label-3383
SELECT col0 + + col0 + - tab2.col1 / tab2.col1 FROM tab2
----
13
155
157

query I rowsort
SELECT + - 90 * + col2 AS col2 FROM tab0 AS cor0
----
-2970
-7380
-90

query I rowsort
SELECT ALL + col1 + - ( 93 ) * cor0.col2 * col1 + ( - col2 ) FROM tab1 cor0
----
-116147
-130600
-53057

query I rowsort
SELECT ALL col0 + col2 + + col0 FROM tab0 AS cor0
----
260
71
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3387
SELECT ALL - cor0.col1 DIV - 68 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3387
SELECT ALL - cor0.col1 / - 68 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 - col0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 * - col2 + 16 * - col1 FROM tab0 AS cor0
----
-1553
-2465
-8180

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab2 cor1, tab2 AS cor2
----
972 values hashing to 163d7732097d78f1cda7f65c2cea5a08

query I rowsort
SELECT ALL + col2 * ( - col0 ) + col0 * + col0 * - ( - cor0.col2 ) FROM tab1 AS cor0
----
229824
324
606720

query I rowsort
SELECT + col1 + + ( + 28 ) AS col1 FROM tab1 AS cor0
----
38
41
54

query I rowsort
SELECT - col0 + col1 * - col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-3394
SELECT DISTINCT - cor0.col2 + col1 * cor0.col0 - - cor0.col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
25
584
945

skipif mysql # not compatible
query I rowsort label-3394
SELECT DISTINCT - cor0.col2 + col1 * cor0.col0 - - cor0.col1 / + col1 AS col0 FROM tab1 AS cor0
----
25
584
945

query I rowsort
SELECT ALL col2 + 88 AS col2 FROM tab0 AS cor0
----
121
170
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 - col0 col1 FROM tab1 AS cor0
----
-1328
-1407
-634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 20 * col2 col2 FROM tab2 AS cor0
----
-520
-540
-760

query I rowsort
SELECT DISTINCT - col1 + 71 FROM tab0 AS cor0
----
-15
-20
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col2 * col0 + + col0 * + cor0.col0 * - col2 col0 FROM tab1 cor0
----
-25536
122880
8262

query I rowsort
SELECT + 31 + - col0 * col2 AS col0 FROM tab2 AS cor0
----
-158
-1997
-2971

onlyif mysql # use DIV operator for integer division
query I rowsort label-3401
SELECT ALL + col1 + + col1 DIV col0 - - cor0.col0 AS col1 FROM tab1 AS cor0
----
37
74
93

skipif mysql # not compatible
query I rowsort label-3401
SELECT ALL + col1 + + col1 / col0 - - cor0.col0 AS col1 FROM tab1 AS cor0
----
37
74
93

query I rowsort
SELECT - cor0.col2 + 35 AS col0 FROM tab2 AS cor0
----
-3
8
9

query I rowsort
SELECT - col0 + + 99 FROM tab2 cor0
----
20
21
92

query I rowsort
SELECT DISTINCT - 68 AS col2 FROM tab0, tab1 AS cor0
----
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3405
SELECT col2 * ( - tab2.col1 ) + col0 * CAST( NULL AS SIGNED ) * + 65 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3405
SELECT col2 * ( - tab2.col1 ) + col0 * CAST ( NULL AS INTEGER ) * + 65 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col2 - 83 FROM tab1, tab1 AS cor0
----
-26
-29
13

query I rowsort
SELECT col0 * cor0.col0 FROM tab0 cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col0 AS REAL ) * col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT - col2 * tab1.col2 AS col0 FROM tab1
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-3410
SELECT - 85 DIV ( col0 ) FROM tab0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-3410
SELECT - 85 / ( col0 ) FROM tab0
----
-2
-3
0

query I rowsort
SELECT DISTINCT + ( + 86 ) * col2 AS col0 FROM tab2
----
2236
2322
3268

query I rowsort
SELECT DISTINCT 31 AS col2 FROM tab0, tab0 AS cor0
----
31

query I rowsort
SELECT + 47 AS col0 FROM tab0
----
47
47
47

query I rowsort
SELECT DISTINCT 87 * col0 FROM tab1
----
261
5568
6960

query I rowsort
SELECT DISTINCT + 3 FROM tab1
----
3

query I rowsort
SELECT + col2 * ( - 59 * col0 ) AS col1 FROM tab1 AS cor0
----
-215232
-453120
-9558

onlyif mysql # use DIV operator for integer division
query I rowsort label-3417
SELECT ALL + col0 DIV + col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3417
SELECT ALL + col0 / + col0 FROM tab1
----
1
1
1

query I rowsort
SELECT - col2 * - 10 AS col1 FROM tab0 AS cor0
----
10
330
820

onlyif mysql # use DIV operator for integer division
query I rowsort label-3419
SELECT ALL - + col0 * - cor0.col1 DIV - col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3419
SELECT ALL - + col0 * - cor0.col1 / - col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + col0 * 31 FROM tab1 AS cor0
----
1984
2480
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3421
SELECT col0 * 63 DIV + ( cor0.col2 ) FROM tab0 AS cor0
----
2205
45
68

skipif mysql # not compatible
query I rowsort label-3421
SELECT col0 * 63 / + ( cor0.col2 ) FROM tab0 AS cor0
----
2205
45
68

query I rowsort
SELECT + + col1 + + 25 * + col0 FROM tab1 AS cor0
----
101
1610
2013

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3423
SELECT DISTINCT + cor0.col1 + CAST( 82 AS SIGNED ) AS col0 FROM tab0 cor0
----
168
173
179

skipif mysql # not compatible
query I rowsort label-3423
SELECT DISTINCT + cor0.col1 + CAST ( 82 AS INTEGER ) AS col0 FROM tab0 cor0
----
168
173
179

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + cor0.col1 + + 23 col0 FROM tab1 cor0
----
103
132
90

query I rowsort
SELECT - col2 + - cor0.col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT ALL cor0.col0 * + col2 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL cor0.col0 * - cor0.col0 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3428
SELECT col0 DIV + col0 + - col2 col0 FROM tab1 AS cor0
----
-53
-56
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3428
SELECT col0 / + col0 + - col2 col0 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT - col1 + + col0 - - col1 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL col2 + - col0 - col1 FROM tab1
----
-17
25
3

query I rowsort
SELECT DISTINCT col2 * tab0.col1 + col2 * col2 - + col1 AS col1 FROM tab0 WHERE - col2 * + col0 - col2 < ( NULL )
----

query I rowsort
SELECT + col1 * tab2.col1 AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT col1 * + col2 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL + tab1.col1 FROM tab1 WHERE + col1 + col2 > + col0 + - col1 * + col2 * col2
----
10
13
26

query I rowsort
SELECT DISTINCT col0 * tab2.col0 AS col0 FROM tab2
----
49
6084
6241

query III rowsort
SELECT * FROM tab0 WHERE NULL <> col1 + + col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3437
SELECT DISTINCT + tab0.col0 DIV col2 - tab0.col1 FROM tab0
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-3437
SELECT DISTINCT + tab0.col0 / col2 - tab0.col1 FROM tab0
----
-62
-86
-90

query I rowsort
SELECT ALL + tab0.col2 + - col2 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT col1 + + tab0.col2 * col1 FROM tab0
----
194
2924
7553

query III rowsort
SELECT * FROM tab1 WHERE NULL BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT col0 + + cor0.col1 * + col1 FROM tab0 cor0 WHERE NOT ( - col1 ) IN ( + col2 )
----
7420
8370
9444

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( - col1 + + col1 ) <> NULL
----

query I rowsort
SELECT DISTINCT tab1.col1 * col0 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3444
SELECT ALL col2 * col2 + - col2 DIV - col2 AS col2 FROM tab0
----
1090
2
6725

skipif mysql # not compatible
query I rowsort label-3444
SELECT ALL col2 * col2 + - col2 / - col2 AS col2 FROM tab0
----
1090
2
6725

query I rowsort
SELECT ALL col0 FROM tab2 WHERE NULL BETWEEN ( NULL ) AND + col2
----

query I rowsort
SELECT col1 + - col0 + + col1 AS col0 FROM tab2
----
-45
40
55

query I rowsort
SELECT - col2 * - col2 AS col2 FROM tab0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-3448
SELECT ALL tab1.col2 DIV - col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-3448
SELECT ALL tab1.col2 / - col0 FROM tab1
----
-1
-18
0

query III rowsort
SELECT * FROM tab0 WHERE - col2 * - col2 NOT BETWEEN NULL AND ( - col2 ) AND + col1 IN ( + col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT - col0 * + col1 + - cor0.col0 * col0 AS col2 FROM tab2 AS cor0
----
-10686
-266
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-3451
SELECT ALL col0 DIV + col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3451
SELECT ALL col0 / + col0 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col0 * + col2 col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT + tab0.col2 * tab0.col2 FROM tab0, tab0 cor0
----
9 values hashing to 50c4b0a13fc95d13442dcf4b04857ce8

query I rowsort
SELECT - col0 + + col1 * col0 AS col1 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT + col2 - - col2 * + col1 FROM tab2
----
1560
684
864

query I rowsort
SELECT - - col1 + + col0 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - tab0.col2 * + col0 AS col0 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3458
SELECT + col2 DIV col1 - col2 AS col0 FROM tab2 AS cor0
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-3458
SELECT + col2 / col1 - col2 AS col0 FROM tab2 AS cor0
----
-26
-27
-36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - col2 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 * - col0 + + cor0.col1 AS col1 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT + col1 * + col0 * + cor0.col1 - cor0.col2 * + col1 FROM tab2 AS cor0
----
22185
269984
5890

query I rowsort
SELECT DISTINCT tab1.col1 - - col0 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT col0 + - col1 * col0 AS col2 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT - col1 * + col0 + col1 * + col1 FROM tab2 cor0
----
-1054
-1121
744

query I rowsort
SELECT ALL col0 * col2 * + col2 AS col1 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT ALL 17 * + col0 AS col1 FROM tab0
----
1513
408
595

query I rowsort
SELECT 77 * col1 FROM tab1
----
1001
2002
770

query I rowsort
SELECT DISTINCT 55 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
55

query I rowsort
SELECT DISTINCT - + 87 * + col2 + col2 + col2 * col0 AS col2 FROM tab2 AS cor0
----
-208
-2133
-266

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 18 col2 FROM tab1 AS cor0
----
18
18
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-3471
SELECT + ( - col1 ) DIV - 63 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3471
SELECT + ( - col1 ) / - 63 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * col0 + + 73 FROM tab2 AS cor0
----
122
6157
6314

query I rowsort
SELECT col2 * - ( col2 ) AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col0 * + 56 + - ( cor0.col2 ) FROM tab1 AS cor0
----
114
3527
4384

query I rowsort
SELECT - col2 - col0 * - ( col2 ) AS col0 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3476
SELECT ALL col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3476
SELECT ALL col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col1 + 86 + 51 FROM tab0 AS cor0
----
223
228
234

query I rowsort
SELECT DISTINCT - col1 * + col0 * + ( - 8 ) - + col1 AS col2 FROM tab1
----
5110
598
8307

onlyif mysql # use DIV operator for integer division
query I rowsort label-3479
SELECT 98 DIV col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3479
SELECT 98 / col1 FROM tab0
----
1
1
1

query I rowsort
SELECT - col0 * + tab2.col1 AS col1 FROM tab2
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 * + col1 - col0 col0 FROM tab2
----
210
3403
954

query I rowsort
SELECT col0 + 99 * 94 AS col2 FROM tab2 cor0
----
9313
9384
9385

query I rowsort
SELECT + col1 + ( col1 ) - + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT col2 * ( 56 ) AS col0 FROM tab2 AS cor0
----
1456
1512
2128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 + - col1 * col1 col2 FROM tab2 AS cor0
----
-124
-1947
357

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT + col1 NOT IN ( + col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 - - col0 col2 FROM tab1
----
106
55
84

query I rowsort
SELECT ALL + tab1.col1 + tab1.col1 AS col2 FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3490
SELECT ALL - tab0.col2 DIV + col1 + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3490
SELECT ALL - tab0.col2 / + col1 + col1 FROM tab0
----
86
91
97

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL <= NULL
----

query I rowsort
SELECT DISTINCT + col1 + - col1 * col1 AS col2 FROM tab1
----
-156
-650
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3493
SELECT + col0 + tab0.col1 DIV col1 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-3493
SELECT + col0 + tab0.col1 / col1 FROM tab0
----
25
36
90

query I rowsort
SELECT DISTINCT tab1.col1 * tab1.col2 + col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT DISTINCT + col1 + - col0 * cor0.col2 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - - ( - col0 ) FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 47 col2 FROM tab2 AS cor0
----
47
47
47

query I rowsort
SELECT 35 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

query I rowsort
SELECT DISTINCT + - 91 * col2 - + ( col0 ) FROM tab0 AS cor0
----
-126
-3027
-7551

query I rowsort
SELECT ALL col2 * col0 + + col1 AS col1 FROM tab0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3501
SELECT - col0 + - col2 * tab1.col1 DIV col2 AS col1 FROM tab1
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-3501
SELECT - col0 + - col2 * tab1.col1 / col2 AS col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT - tab2.col1 FROM tab2 WHERE NULL NOT IN ( + col2 * + col2 * col1 )
----

query I rowsort
SELECT ALL - col2 * col2 * + col2 + col0 * - col0 FROM tab0
----
-1226
-36513
-559289

query I rowsort
SELECT ALL - col0 + col2 * col0 * col0 FROM tab1
----
233408
483
614320

query I rowsort
SELECT DISTINCT col1 * col0 + col1 * - tab0.col1 FROM tab0
----
-182
-5332
-6014

query I rowsort
SELECT DISTINCT + tab1.col0 + + col2 AS col0 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 col2 FROM tab0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3508
SELECT cor0.col2 + + CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3508
SELECT cor0.col2 + + CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( + col1 * col0 ) AS col2 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT 54 + col1 FROM tab0
----
140
145
151

onlyif mysql # use DIV operator for integer division
query I rowsort label-3511
SELECT - 6 DIV col1 + 25 AS col0 FROM tab2
----
25
25
25

skipif mysql # not compatible
query I rowsort label-3511
SELECT - 6 / col1 + 25 AS col0 FROM tab2
----
25
25
25

query I rowsort
SELECT + col2 + - col1 * - col1 AS col0 FROM tab1
----
157
265
730

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3513
SELECT + col2 * + CAST( - col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-3513
SELECT + col2 * + CAST ( - col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

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-3515
SELECT - col1 + - col0 * CAST( col2 AS SIGNED ) DIV - col1 FROM tab1
----
-20
354
577

skipif mysql # not compatible
query I rowsort label-3515
SELECT - col1 + - col0 * CAST ( col2 AS INTEGER ) / - col1 FROM tab1
----
-20
354
577

query I rowsort
SELECT DISTINCT - 78 * col0 AS col1 FROM tab0
----
-1872
-2730
-6942

query I rowsort
SELECT ALL + 82 AS col1 FROM tab1
----
82
82
82

query I rowsort
SELECT + 32 + col1 AS col0 FROM tab2
----
49
63
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-3519
SELECT col0 DIV ( col1 * col1 ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3519
SELECT col0 / ( col1 * col1 ) FROM tab2
----
0
0
0

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 cor1, tab2 AS cor2
----
972 values hashing to e486ce227b61d9db6f8414f9d6361094

query I rowsort
SELECT ALL + col1 * cor0.col2 - - cor0.col1 FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT col0 + - ( + 8 ) * col2 AS col2 FROM tab1 cor0
----
-392
-429
-688

query I rowsort
SELECT DISTINCT - - col1 * - ( col1 ) + cor0.col1 * col0 + + col0 * col2 FROM tab0 AS cor0
----
-4540
-5979
7116

query I rowsort
SELECT ALL - col0 - + 79 FROM tab1 AS cor0
----
-143
-159
-82

query I rowsort
SELECT col2 * ( - ( - col2 ) ) + col2 FROM tab1 cor0
----
2970
3306
9312

query I rowsort
SELECT + + col0 * 75 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT DISTINCT col2 * 50 FROM tab1 AS cor0
----
2700
2850
4800

onlyif mysql # use DIV operator for integer division
query I rowsort label-3529
SELECT - + col0 DIV - col0 - col1 AS col2 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-3529
SELECT - + col0 / - col0 - col1 AS col2 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT + 90 AS col1 FROM tab0 AS cor0
----
90
90
90

query I rowsort
SELECT DISTINCT + 26 * + ( col0 ) FROM tab2 AS cor0
----
182
2028
2054

query I rowsort
SELECT ALL - + ( 84 ) AS col0 FROM tab0 AS cor0
----
-84
-84
-84

query I rowsort
SELECT DISTINCT 58 + 68 FROM tab0 AS cor0
----
126

query I rowsort
SELECT ALL - col1 + 48 * + col1 FROM tab1 cor0
----
1222
470
611

query I rowsort
SELECT DISTINCT + ( col1 ) * - col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - + cor0.col1 + ( col2 ) FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT 38 - + col1 FROM tab0 AS cor0
----
-48
-53
-59

query I rowsort
SELECT DISTINCT col1 * + col1 + - cor0.col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT + - ( col1 ) AS col0 FROM tab0 cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 22 col2 FROM tab2 AS cor0
----
22
22
22

query I rowsort
SELECT - cor0.col2 + col2 * + ( - col0 ) AS col1 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT 90 * tab0.col0 FROM tab0, tab2 cor0
----
9 values hashing to 5d7a7151104f767615b2549d3d061db9

query I rowsort
SELECT ALL 47 AS col1 FROM tab0
----
47
47
47

query I rowsort
SELECT - cor0.col0 * + col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - 71 AS col2 FROM tab2 AS cor0
----
-71
-71
-71

query I rowsort
SELECT - 6 AS col2 FROM tab2
----
-6
-6
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * cor0.col1 col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + col0 * + col1 * + col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT col1 * col0 * - col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
-118728
-49450
-720720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col2 + 36 col0 FROM tab2 AS cor0
----
-2
10
9

query I rowsort
SELECT + + 38 * + col0 + col1 FROM tab2 AS cor0
----
297
3019
3023

query I rowsort
SELECT ALL + ( + 26 ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT - col2 + ( tab2.col1 ) * col1 + + col1 * + col2 AS col1 FROM tab2
----
1771
4989
897

query I rowsort
SELECT + 25 AS col2 FROM tab2 AS cor0
----
25
25
25

query I rowsort
SELECT cor0.col1 + - col0 * - cor0.col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ( col1 ) * col0 * col1 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT col2 * - cor0.col2 * + col1 + col0 AS col2 FROM tab1 AS cor0
----
-119728
-32426
-75813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col0 ) col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + + 10 * col0 + - col1 * col1 FROM tab2 AS cor0
----
-2701
-891
501

query I rowsort
SELECT col0 * - ( col2 + - col2 ) * - col1 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 43 col1 FROM tab1
----
43
43
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3562
SELECT - CAST( NULL AS SIGNED ) * col2 * col1 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3562
SELECT - CAST ( NULL AS INTEGER ) * col2 * col1 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - ( - col2 ) ) col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL - cor0.col1 * 6 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 4c80b2adc32af3e58d003e875ea4946c

query I rowsort
SELECT + - ( col0 ) FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * cor0.col2 * + col0 + 92 col1 FROM tab1 AS cor0
----
-36388
-4120
-99748

query I rowsort
SELECT ALL 32 + - col2 FROM tab1 AS cor0
----
-22
-25
-64

query I rowsort
SELECT 79 FROM tab0, tab0 cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT DISTINCT cor0.col1 * cor0.col1 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + ( - 39 ) col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 0c3e58c584ab8d0f3811089dba2110b1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3572
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab2, tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3572
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab2, tab0, tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3573
SELECT DISTINCT - 66 DIV 1 FROM tab0
----
-66

skipif mysql # not compatible
query I rowsort label-3573
SELECT DISTINCT - 66 / 1 FROM tab0
----
-66

query I rowsort
SELECT - ( + 90 + + col1 ) * 64 FROM tab2
----
-6848
-7744
-9536

query I rowsort
SELECT - - ( 78 ) FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT DISTINCT - - 96 + cor0.col1 + - 33 FROM tab1 AS cor0
----
73
76
89

query I rowsort
SELECT ALL - 57 AS col2 FROM tab2 AS cor0
----
-57
-57
-57

query I rowsort
SELECT DISTINCT + - cor0.col2 + + col1 * 22 FROM tab2 cor0
----
1272
336
655

onlyif mysql # use DIV operator for integer division
query I rowsort label-3579
SELECT ALL - col0 * col2 - + 40 DIV + 4 AS col0 FROM tab2 AS cor0
----
-199
-2038
-3012

skipif mysql # not compatible
query I rowsort label-3579
SELECT ALL - col0 * col2 - + 40 / + 4 AS col0 FROM tab2 AS cor0
----
-199
-2038
-3012

query I rowsort
SELECT DISTINCT 50 * col1 + - ( col1 ) FROM tab1 AS cor0
----
1274
490
637

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 63 col2 FROM tab2 AS cor0
----
63
63
63

query I rowsort
SELECT ALL tab1.col0 * col0 - - col1 FROM tab1
----
35
4106
6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-3583
SELECT - ( 65 + - col2 ) DIV + CAST( + col1 AS SIGNED ) col1 FROM tab2
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3583
SELECT - ( 65 + - col2 ) / + CAST ( + col1 AS INTEGER ) col1 FROM tab2
----
-1
-1
0

query I rowsort
SELECT DISTINCT - - col0 * cor0.col2 + + col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3585
SELECT DISTINCT + col2 + - CAST( NULL AS SIGNED ) * col2 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3585
SELECT DISTINCT + col2 + - CAST ( NULL AS INTEGER ) * col2 col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3586
SELECT ALL col1 DIV + col0 col0 FROM tab0 AS cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3586
SELECT ALL col1 / + col0 col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL - col0 * 97 * 26 - col2 AS col1 FROM tab1 AS cor0
----
-161465
-201856
-7620

query I rowsort
SELECT DISTINCT 78 FROM tab0
----
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3589
SELECT col1 * - CAST( - 45 AS SIGNED ) FROM tab0 AS cor0
----
3870
4095
4365

skipif mysql # not compatible
query I rowsort label-3589
SELECT col1 * - CAST ( - 45 AS INTEGER ) FROM tab0 AS cor0
----
3870
4095
4365

query I rowsort
SELECT + 29 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT ALL 77 AS col1 FROM tab0
----
77
77
77

query I rowsort
SELECT ALL + col2 * col0 * col2 AS col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT col2 * - col2 * 68 AS col2 FROM tab1
----
-198288
-220932
-626688

query I rowsort
SELECT - 24 FROM tab2, tab2 cor0
----
9 values hashing to 797d0f7c145f8ac623924448c714bbcc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3595
SELECT + col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3595
SELECT + col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * col1 - col1 FROM tab0
----
7310
8190
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3597
SELECT - col2 - + col0 DIV ( col0 ) AS col0 FROM tab0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-3597
SELECT - col2 - + col0 / ( col0 ) AS col0 FROM tab0
----
-2
-34
-83

query I rowsort
SELECT ALL + + 0 + cor0.col0 * col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - - col2 * - col2 + - col0 FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT - col0 * col1 - - col2 AS col1 FROM tab2
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-3601
SELECT tab0.col1 + col2 DIV col0 FROM tab0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-3601
SELECT tab0.col1 + col2 / col0 FROM tab0
----
87
91
97

query I rowsort
SELECT DISTINCT 70 FROM tab2, tab1 AS cor0
----
70

query I rowsort
SELECT tab2.col1 + + 38 AS col1 FROM tab2
----
55
69
97

query I rowsort
SELECT ALL - - col2 + col2 * + col1 * col1 FROM tab1 AS cor0
----
16320
36558
5757

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3605
SELECT CAST( + col2 AS SIGNED ) * col2 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-3605
SELECT CAST ( + col2 AS INTEGER ) * col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL + ( col1 ) * - col1 * - 42 + ( col0 ) + ( + col1 * col2 ) FROM tab2 AS cor0
----
12863
147814
41206

query I rowsort
SELECT DISTINCT + 53 - col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-2011
-3342
-8046

onlyif mysql # use DIV operator for integer division
query I rowsort label-3608
SELECT DISTINCT - 52 - + 56 DIV + col0 AS col0 FROM tab2 AS cor0
----
-52
-60

skipif mysql # not compatible
query I rowsort label-3608
SELECT DISTINCT - 52 - + 56 / + col0 AS col0 FROM tab2 AS cor0
----
-52
-60

query I rowsort
SELECT - 13 + col2 FROM tab1 AS cor0
----
41
44
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3610
SELECT ALL 78 DIV - ( col2 ) AS col1 FROM tab0 cor0
----
-2
-78
0

skipif mysql # not compatible
query I rowsort label-3610
SELECT ALL 78 / - ( col2 ) AS col1 FROM tab0 cor0
----
-2
-78
0

query I rowsort
SELECT DISTINCT - + col2 + - col0 FROM tab0 AS cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * col0 * - col0 col1 FROM tab1 AS cor0
----
233472
486
614400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3613
SELECT DISTINCT + CAST( - col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3613
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col2 col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - 73 * - col1 * + col1 AS col1 FROM tab1 AS cor0
----
12337
49348
7300

onlyif mysql # use DIV operator for integer division
query I rowsort label-3616
SELECT ALL col2 + - col1 DIV col1 FROM tab0 cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-3616
SELECT ALL col2 + - col1 / col1 FROM tab0 cor0
----
0
32
81

query I rowsort
SELECT + + col2 * - ( + col0 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + 64 * 57 AS col0 FROM tab0 AS cor0
----
3648
3648
3648

query I rowsort
SELECT col2 + 52 * col2 AS col1 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT ALL - ( col2 ) * - col0 * - col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT + - col0 + - 17 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
210
520
925

query I rowsort
SELECT ALL col2 * + 37 AS col1 FROM tab1 AS cor0
----
1998
2109
3552

onlyif mysql # use DIV operator for integer division
query I rowsort label-3623
SELECT DISTINCT + CAST( + col2 AS SIGNED ) DIV col0 AS col1 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-3623
SELECT DISTINCT + CAST ( + col2 AS INTEGER ) / col0 AS col1 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT ALL - col1 + col0 + col1 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - - col1 * col2 * col2 + col2 FROM tab2 AS cor0
----
22626
24586
39910

query I rowsort
SELECT ALL 49 AS col1 FROM tab1 AS cor0
----
49
49
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-3627
SELECT + 22 DIV col1 + - 44 FROM tab0 AS cor0
----
-44
-44
-44

skipif mysql # not compatible
query I rowsort label-3627
SELECT + 22 / col1 + - 44 FROM tab0 AS cor0
----
-44
-44
-44

onlyif mysql # use DIV operator for integer division
query I rowsort label-3628
SELECT DISTINCT + - col0 - cor0.col0 DIV + 43 AS col1 FROM tab0 AS cor0
----
-24
-35
-91

skipif mysql # not compatible
query I rowsort label-3628
SELECT DISTINCT + - col0 - cor0.col0 / + 43 AS col1 FROM tab0 AS cor0
----
-24
-35
-91

query I rowsort
SELECT ALL + - cor0.col0 * col2 FROM tab2 AS cor0
----
-189
-2028
-3002

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 DISTINCT - + col1 * 94 col1 FROM tab2 AS cor0
----
-1598
-2914
-5546

query I rowsort
SELECT + col2 + - ( + col0 ) AS col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT ALL + - col1 * + 86 FROM tab2 AS cor0
----
-1462
-2666
-5074

query I rowsort
SELECT - col0 + + cor0.col2 * col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT cor0.col0 + + 30 FROM tab0 cor0
----
119
54
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-3636
SELECT ALL + cor0.col2 DIV col1 + + col1 + col1 * col1 FROM tab2 cor0
----
308
3540
992

skipif mysql # not compatible
query I rowsort label-3636
SELECT ALL + cor0.col2 / col1 + + col1 + col1 * col1 FROM tab2 cor0
----
308
3540
992

query I rowsort
SELECT DISTINCT + 0 * tab1.col0 + + 45 FROM tab1
----
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * cor0.col1 col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col2 + 13 AS col0 FROM tab2 AS cor0
----
39
40
51

query I rowsort
SELECT ALL + cor0.col1 - 5 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 94d99bf84d85214cb25d269c876c8f7f

query I rowsort
SELECT DISTINCT 84 FROM tab1
----
84

query I rowsort
SELECT + 28 AS col0 FROM tab1 AS cor0
----
28
28
28

query I rowsort
SELECT 17 * - col0 FROM tab2 AS cor0
----
-119
-1326
-1343

query I rowsort
SELECT 53 AS col1 FROM tab1 AS cor0
----
53
53
53

query I rowsort
SELECT ALL + 4 * col0 + col1 - + col1 * - col1 AS col1 FROM tab0 AS cor0
----
7578
8728
9646

query I rowsort
SELECT + 47 FROM tab1 cor0
----
47
47
47

query I rowsort
SELECT DISTINCT - 37 FROM tab1, tab0 AS cor0
----
-37

query I rowsort
SELECT ALL ( col0 ) * tab2.col0 FROM tab2
----
49
6084
6241

query I rowsort
SELECT - col2 + col0 * + col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT - 77 + col2 FROM tab1 cor0
----
-20
-23
19

query I rowsort
SELECT - 22 AS col1 FROM tab2
----
-22
-22
-22

query I rowsort
SELECT col1 * 89 + - col2 FROM tab2 AS cor0
----
1475
2732
5225

query I rowsort
SELECT ALL + ( - col2 ) * + col2 - + col2 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT col0 * + col1 + col0 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + 3 - + col2 FROM tab1 AS cor0
----
-51
-54
-93

query I rowsort
SELECT DISTINCT + + col1 + - col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3657
SELECT ALL + 75 DIV 24 col0 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3657
SELECT ALL + 75 / 24 col0 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT col2 + - ( - col2 ) + col2 AS col0 FROM tab0
----
246
3
99

query I rowsort
SELECT ALL tab1.col2 * - 36 + ( + col0 ) FROM tab1
----
-1941
-1988
-3376

query I rowsort
SELECT + 74 * col0 FROM tab1
----
222
4736
5920

query I rowsort
SELECT - ( 24 ) FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to f2e40f6e5cdbc2877843191cb261975f

query I rowsort
SELECT + - ( - 32 ) AS col2 FROM tab1 AS cor0
----
32
32
32

query I rowsort
SELECT DISTINCT - 56 + col2 AS col2 FROM tab0 AS cor0
----
-23
-55
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( col0 ) col0 FROM tab1 cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 col2 FROM tab2 cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3666
SELECT CAST( NULL AS SIGNED ) / col0 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3666
SELECT CAST ( NULL AS INTEGER ) / col0 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( + col2 ) * - col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL - col0 * cor0.col0 + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL - - ( + col1 ) * - cor0.col0 + ( - 57 ) + + col2 FROM tab2 cor0
----
-1362
-247
-4633

query I rowsort
SELECT DISTINCT - ( + 18 ) AS col1 FROM tab1 AS cor0
----
-18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col0 FROM tab2, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ( 55 ) + col0 * col2 FROM tab0 AS cor0
----
7353
847
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3673
SELECT - CAST( + 97 AS SIGNED ) + - col0 * - col0 FROM tab2 AS cor0
----
-48
5987
6144

skipif mysql # not compatible
query I rowsort label-3673
SELECT - CAST ( + 97 AS INTEGER ) + - col0 * - col0 FROM tab2 AS cor0
----
-48
5987
6144

query I rowsort
SELECT col2 + ( col1 ) FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL - ( + 59 ) FROM tab1 AS cor0
----
-59
-59
-59

query I rowsort
SELECT ALL 50 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 6932c991110d256d3f92f3e9538f8040

query I rowsort
SELECT 92 + + col1 * - col0 FROM tab0 AS cor0
----
-1972
-3303
-8007

query I rowsort
SELECT col2 - col0 * + 48 AS col1 FROM tab0
----
-1119
-1679
-4190

query I rowsort
SELECT ALL + 63 + col2 FROM tab2
----
101
89
90

query I rowsort
SELECT col1 + - cor0.col0 + + col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + 14 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-72
-77
-83

query I rowsort
SELECT ALL + ( + col1 ) + - col2 * - cor0.col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT col0 + col0 + + col0 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT ALL - 32 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7106326ae056e78044adc0aef747ef08

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + + col1 col1 FROM tab2 cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col2 col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3687
SELECT + - cor0.col1 + + 30 DIV - 58 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-3687
SELECT + - cor0.col1 + + 30 / - 58 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + col1 + + 96 FROM tab2 AS cor0
----
113
127
155

query I rowsort
SELECT DISTINCT - col2 * col1 * + col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT 51 + + 59 AS col2 FROM tab1 AS cor0
----
110
110
110

query I rowsort
SELECT + + col1 + 32 FROM tab2 AS cor0
----
49
63
91

query I rowsort
SELECT - + 98 * col2 AS col2 FROM tab2 AS cor0
----
-2548
-2646
-3724

query I rowsort
SELECT ALL tab0.col2 + - 75 * + col2 AS col2 FROM tab0
----
-2442
-6068
-74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3694
SELECT ALL tab0.col1 * CAST( NULL AS DECIMAL ) + tab0.col1 col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3694
SELECT ALL tab0.col1 * CAST ( NULL AS REAL ) + tab0.col1 col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 22 col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT col2 * - col2 * col2 AS col1 FROM tab2 AS cor0
----
-17576
-19683
-54872

query I rowsort
SELECT ALL - col0 * + tab0.col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT - col1 * col0 - - col2 * 3 FROM tab1
----
-469
-752
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3699
SELECT col1 - col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3699
SELECT col1 - col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3700
SELECT + + col0 * col0 DIV + cor0.col0 AS col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3700
SELECT + + col0 * col0 / + cor0.col0 AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + col1 + col2 * ( - cor0.col1 ) FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT - - 17 + - col2 + 6 AS col1 FROM tab0 AS cor0
----
-10
-59
22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * col0 col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT col1 * col0 - + 62 AS col1 FROM tab2 AS cor0
----
1281
155
4540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 * - col2 col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - col0 * + 15 * col1 AS col2 FROM tab1 AS cor0
----
-1170
-15600
-9600

query I rowsort
SELECT - + cor0.col2 * + col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + 9 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

query I rowsort
SELECT - cor0.col2 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 * + 15 col1 FROM tab1 AS cor0
----
160
208
416

query I rowsort
SELECT ALL col1 + 82 FROM tab0 AS cor0
----
168
173
179

query I rowsort
SELECT - col2 + ( - col0 ) * cor0.col0 AS col2 FROM tab2 AS cor0
----
-6110
-6279
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL + tab0.col0 * 53 + + col0 * tab0.col0 AS col0 FROM tab0
----
12638
1848
3080

query I rowsort
SELECT DISTINCT col0 + + 85 FROM tab2
----
163
164
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3717
SELECT DISTINCT + + CAST( col0 AS SIGNED ) * + cor0.col1 + + ( col1 ) FROM tab0 AS cor0
----
2150
3492
8190

skipif mysql # not compatible
query I rowsort label-3717
SELECT DISTINCT + + CAST ( col0 AS INTEGER ) * + cor0.col1 + + ( col1 ) FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT - ( col1 ) * - col2 * + cor0.col2 + col1 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT DISTINCT + 92 + - col2 AS col0 FROM tab1 cor0
----
-4
35
38

query I rowsort
SELECT 15 + + 9 FROM tab0 AS cor0
----
24
24
24

query I rowsort
SELECT + cor0.col2 + - col1 + + col0 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT + col1 + col1 * col2 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL - + 87 * + 33 + - col1 FROM tab0 AS cor0
----
-2957
-2962
-2968

onlyif mysql # use DIV operator for integer division
query I rowsort label-3724
SELECT DISTINCT + col0 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-3724
SELECT DISTINCT + col0 / cor0.col0 AS col2 FROM tab2 AS cor0
----
1

query I rowsort
SELECT ALL - - col2 * + col2 * col2 + + col0 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1226
36513
559289

query I rowsort
SELECT + - 60 FROM tab1 AS cor0
----
-60
-60
-60

query I rowsort
SELECT ( col0 ) * col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL + + 65 AS col0 FROM tab0 AS cor0
----
65
65
65

query I rowsort
SELECT + 24 + + col1 * cor0.col1 AS col1 FROM tab0 cor0
----
7420
8305
9433

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 * 48 col2 FROM tab0 AS cor0
----
-4042
-4277
-4559

query I rowsort
SELECT ALL + + cor0.col1 * col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col0 * col2 + col1 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - - col1 * + col2 + + col2 * - cor0.col2 FROM tab1 AS cor0
----
-1512
-2679
-7968

query I rowsort
SELECT ALL - col0 + - col2 + ( - 4 ) AS col2 FROM tab1 cor0
----
-125
-180
-61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3735
SELECT ALL CAST( NULL AS DECIMAL ) + + 43 + col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3735
SELECT ALL CAST ( NULL AS REAL ) + + 43 + col2 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 + - col2 * - col2 FROM tab0
----
1113
36
6813

query I rowsort
SELECT DISTINCT 57 + col1 FROM tab2 AS cor0
----
116
74
88

query I rowsort
SELECT DISTINCT - + col2 + - cor0.col1 FROM tab2 cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3739
SELECT - col2 * - cor0.col2 + CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
1427
617
698

skipif mysql # not compatible
query I rowsort label-3739
SELECT - col2 * - cor0.col2 + CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT col2 + - col2 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT col2 * + col0 + + col0 * col2 FROM tab0 AS cor0
----
14596
1584
70

query I rowsort
SELECT ALL - - 37 * - col1 * 93 + + 69 * + col0 FROM tab2 AS cor0
----
-106188
-197637
-53046

query I rowsort
SELECT DISTINCT - + col0 - col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT cor0.col0 AS col2 FROM tab1, tab2 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT + ( col1 ) * col2 + 10 * + tab1.col2 AS col2 FROM tab1
----
1140
1944
2208

query I rowsort
SELECT ALL - - 93 AS col2 FROM tab0 AS cor0
----
93
93
93

query I rowsort
SELECT - + col1 + cor0.col0 AS col1 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT tab2.col2 + + col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL - tab1.col2 FROM tab0, tab2, tab2 AS cor0, tab1
----
81 values hashing to 2df272448a67587d4635afedff278dcc

query I rowsort
SELECT DISTINCT 1 * col1 FROM tab0
----
86
91
97

query I rowsort
SELECT - col0 + - 14 FROM tab0 AS cor0
----
-103
-38
-49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * + 91 col1 FROM tab2 AS cor0
----
2366
2457
3458

query I rowsort
SELECT + col1 * + tab0.col0 + + col0 AS col2 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + 75 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
75

query I rowsort
SELECT + col0 + - col1 * col2 - - 46 AS col1 FROM tab1 AS cor0
----
-1122
-1355
-460

query I rowsort
SELECT ALL + ( 41 ) * col2 FROM tab0 AS cor0
----
1353
3362
41

query I rowsort
SELECT - col0 * 74 AS col1 FROM tab1
----
-222
-4736
-5920

query I rowsort
SELECT + + 17 AS col1 FROM tab2 AS cor0
----
17
17
17

query I rowsort
SELECT DISTINCT + 65 * - col0 AS col0 FROM tab1 cor0
----
-195
-4160
-5200

query I rowsort
SELECT DISTINCT - 93 AS col2 FROM tab1 cor0
----
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3761
SELECT DISTINCT - col1 - - CAST( + col0 + col0 AS SIGNED ) AS col1 FROM tab0
----
-27
-38
87

skipif mysql # not compatible
query I rowsort label-3761
SELECT DISTINCT - col1 - - CAST ( + col0 + col0 AS INTEGER ) AS col1 FROM tab0
----
-27
-38
87

query I rowsort
SELECT col0 - col1 AS col2 FROM tab1
----
-23
54
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3763
SELECT DISTINCT tab2.col2 - - CAST( + col1 AS SIGNED ) AS col1 FROM tab2
----
55
58
85

skipif mysql # not compatible
query I rowsort label-3763
SELECT DISTINCT tab2.col2 - - CAST ( + col1 AS INTEGER ) AS col1 FROM tab2
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3764
SELECT DISTINCT + col1 - CAST( 14 + + col1 AS SIGNED ) FROM tab0
----
-14

skipif mysql # not compatible
query I rowsort label-3764
SELECT DISTINCT + col1 - CAST ( 14 + + col1 AS INTEGER ) FROM tab0
----
-14

query I rowsort
SELECT ALL tab2.col1 + 87 FROM tab2
----
104
118
146

onlyif mysql # use DIV operator for integer division
query I rowsort label-3766
SELECT col2 DIV - 79 + + col0 FROM tab0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-3766
SELECT col2 / - 79 + + col0 FROM tab0
----
24
35
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-3767
SELECT DISTINCT 56 DIV - col2 + col1 * col1 AS col0 FROM tab0
----
7395
8281
9353

skipif mysql # not compatible
query I rowsort label-3767
SELECT DISTINCT 56 / - col2 + col1 * col1 AS col0 FROM tab0
----
7395
8281
9353

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor1.col0 col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT ALL + + col1 * + col0 - col1 FROM tab2 AS cor0
----
1326
186
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 13 col2 FROM tab0 AS cor0
----
-13

query I rowsort
SELECT + col0 * - 90 - + col2 AS col2 FROM tab2 AS cor0
----
-657
-7046
-7148

query I rowsort
SELECT ALL - col2 + - col2 * col1 AS col0 FROM tab2 cor0
----
-1560
-684
-864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3773
SELECT DISTINCT + CAST( NULL AS SIGNED ) + 13 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3773
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + 13 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( - col1 AS REAL ) + col2 * + col2 / + cor0.col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - col1 * + 60 + - col1 FROM tab2 AS cor0
----
-1037
-1891
-3599

query I rowsort
SELECT ALL + - 82 AS col1 FROM tab1 AS cor0
----
-82
-82
-82

query I rowsort
SELECT DISTINCT col0 * - col1 + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-3778
SELECT ALL + + ( - col1 ) DIV - col2 - col1 DIV - 18 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3778
SELECT ALL + + ( - col1 ) / - col2 - col1 / - 18 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + cor0.col0 + + col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL - 99 * col0 - cor0.col2 AS col0 FROM tab2 AS cor0
----
-720
-7748
-7859

query I rowsort
SELECT col1 * - ( + 72 + tab1.col1 ) FROM tab1
----
-1105
-2548
-820

query I rowsort
SELECT ALL + tab1.col2 * - 12 AS col2 FROM tab1
----
-1152
-648
-684

query I rowsort
SELECT - col2 + + ( + col2 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col2 * 35 * 27 FROM tab1 AS cor0
----
51030
53865
90720

query I rowsort
SELECT ALL col2 * + 97 AS col0 FROM tab2 AS cor0
----
2522
2619
3686

query I rowsort
SELECT 15 AS col0 FROM tab1 AS cor0
----
15
15
15

query I rowsort
SELECT + col0 * col2 + - col2 AS col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT ALL - 89 FROM tab0, tab0 AS cor0
----
9 values hashing to 924a74d31360fa4301c953b423a4710e

query I rowsort
SELECT DISTINCT - + col0 + + col1 AS col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT ALL col1 + col0 * - 22 AS col1 FROM tab2 AS cor0
----
-123
-1657
-1721

onlyif mysql # use DIV operator for integer division
query I rowsort label-3791
SELECT ALL + + col2 + + col2 DIV col0 FROM tab0 AS cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-3791
SELECT ALL + + col2 + + col2 / col0 FROM tab0 AS cor0
----
1
34
82

query I rowsort
SELECT DISTINCT - col0 * col0 + col0 AS col1 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT - col0 + - col1 * - col0 * - col2 FROM tab2 AS cor0
----
-119730
-51113
-5866

query I rowsort
SELECT DISTINCT - 76 * - col2 + col1 + ( col1 ) * + col2 AS col1 FROM tab1 AS cor0
----
4912
5534
8557

query I rowsort
SELECT ALL col2 + + col1 AS col1 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col0 * col2 - - 80 * col1 col2 FROM tab0 AS cor0
----
14578
7672
7795

query I rowsort
SELECT + 16 AS col0 FROM tab0 AS cor0
----
16
16
16

query I rowsort
SELECT 83 AS col2 FROM tab0
----
83
83
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3799
SELECT 16 DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-3799
SELECT 16 / col0 AS col0 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT + + col0 - col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + 49 + col2 FROM tab2 AS cor0
----
75
76
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-3802
SELECT ALL col1 + + col2 DIV col0 FROM tab1
----
10
14
44

skipif mysql # not compatible
query I rowsort label-3802
SELECT ALL col1 + + col2 / col0 FROM tab1
----
10
14
44

query I rowsort
SELECT - col1 + col2 * cor0.col0 AS col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL col1 + - col2 + col0 * 85 AS col0 FROM tab0
----
2093
3071
7574

query I rowsort
SELECT + - col0 * col0 + - 86 * + col2 AS col0 FROM tab1 AS cor0
----
-14656
-4653
-8998

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3806
SELECT DISTINCT - col0 + - CAST( col0 AS SIGNED ) + - col0 FROM tab1 AS cor0
----
-192
-240
-9

skipif mysql # not compatible
query I rowsort label-3806
SELECT DISTINCT - col0 + - CAST ( col0 AS INTEGER ) + - col0 FROM tab1 AS cor0
----
-192
-240
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 - - col1 col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col1 * - col0 * - col2 + - col2 AS col1 FROM tab0 AS cor0
----
3394
664036
68079

query I rowsort
SELECT - col0 * 19 + col1 * - col0 * col1 FROM tab2 AS cor0
----
-24332
-273000
-6860

query I rowsort
SELECT 5 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT ALL - 56 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2, tab1 AS cor3
----
243 values hashing to 0161140c42e0e13ec8f246567b9c6f6c

query I rowsort
SELECT col0 * tab1.col2 * - col0 AS col1 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT col2 * 51 * col1 - col1 AS col0 FROM tab2 AS cor0
----
32929
42656
78175

onlyif mysql # use DIV operator for integer division
query I rowsort label-3814
SELECT col0 DIV - 79 + col2 AS col1 FROM tab0 AS cor0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-3814
SELECT col0 / - 79 + col2 AS col1 FROM tab0 AS cor0
----
1
33
81

query I rowsort
SELECT col1 + - 12 AS col1 FROM tab2
----
19
47
5

query I rowsort
SELECT 58 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab2 cor1
----
972 values hashing to caf6adb9936510208f5945a7e5c76f14

query I rowsort
SELECT ALL - 16 * col1 AS col0 FROM tab1
----
-160
-208
-416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3819
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3819
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

query I rowsort
SELECT - + ( 35 ) + - col1 * + cor0.col1 * col1 FROM tab1 AS cor0
----
-1035
-17611
-2232

query I rowsort
SELECT ALL - col0 + - 80 AS col0 FROM tab1 AS cor0
----
-144
-160
-83

query I rowsort
SELECT ( 91 ) AS col2 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 65 col2 FROM tab1
----
-65
-65
-65

query I rowsort
SELECT + cor0.col0 * col2 * 9 FROM tab2 cor0
----
1701
18252
27018

query I rowsort
SELECT - 35 * cor0.col1 * + col0 AS col2 FROM tab2 AS cor0
----
-161070
-47005
-7595

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 85 col1 FROM tab1 AS cor0
----
-85
-85
-85

query I rowsort
SELECT + cor0.col2 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL 48 * 41 AS col1 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to e6737a5cc9383749c25575c58923ec8e

query I rowsort
SELECT - + cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3830
SELECT DISTINCT col2 + + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3830
SELECT DISTINCT col2 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL

query I rowsort
SELECT col1 * - col2 + col1 + col0 FROM tab0 AS cor0
----
-2728
-7282
35

query I rowsort
SELECT ALL + ( 59 ) * - col2 FROM tab1
----
-3186
-3363
-5664

query I rowsort
SELECT col2 * - 29 - col0 FROM tab0
----
-2467
-64
-981

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2, tab1 AS cor0, tab0 cor1
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT + ( - col2 ) + col2 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 29 ) col2 FROM tab1, tab2, tab0 AS cor0
----
-29

query I rowsort
SELECT DISTINCT + col2 * 39 FROM tab0
----
1287
3198
39

query I rowsort
SELECT - col1 + + 69 * col2 AS col1 FROM tab1 AS cor0
----
3700
3923
6611

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - 53 col1 FROM tab2 AS cor0
----
-371
-4134
-4187

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col1 ) * - cor0.col2 + - ( col2 ) * col1 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ( cor0.col0 ) AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT DISTINCT - col0 * col2 * + col0 - col0 FROM tab2 AS cor0
----
-1330
-158262
-237237

query I rowsort
SELECT - 20 + cor0.col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 776df3bca0b8a9ba0df0c17c27c900f5

query I rowsort
SELECT ALL + col2 - - col0 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3845
SELECT DISTINCT 51 DIV col1 FROM tab2
----
0
1
3

skipif mysql # not compatible
query I rowsort label-3845
SELECT DISTINCT 51 / col1 FROM tab2
----
0
1
3

query I rowsort
SELECT DISTINCT 54 * cor1.col1 FROM tab1, tab2 cor0, tab0 cor1
----
4644
4914
5238

query I rowsort
SELECT DISTINCT - 54 AS col2 FROM tab2, tab1 AS cor0
----
-54

query I rowsort
SELECT 7 * + col1 AS col0 FROM tab0 AS cor0
----
602
637
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-3849
SELECT + 89 * col0 DIV + 44 FROM tab2 AS cor0
----
14
157
159

skipif mysql # not compatible
query I rowsort label-3849
SELECT + 89 * col0 / + 44 FROM tab2 AS cor0
----
14
157
159

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3850
SELECT + cor0.col2 + - col2 - CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3850
SELECT + cor0.col2 + - col2 - 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 - col0 + 90 * col1 col1 FROM tab0 AS cor0
----
7716
8101
8695

query I rowsort
SELECT - - col2 * - ( + 88 * - col1 ) AS col0 FROM tab0 AS cor0
----
249744
656656
8536

query I rowsort
SELECT DISTINCT col1 * col1 * + 49 FROM tab0 cor0
----
362404
405769
461041

query I rowsort
SELECT col0 * - 96 FROM tab1 AS cor0
----
-288
-6144
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3855
SELECT + + col2 DIV + col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3855
SELECT + + col2 / + col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT col0 * col2 * col2 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT - 59 * - col1 AS col2 FROM tab0
----
5074
5369
5723

query I rowsort
SELECT ALL col2 + col1 * + 82 FROM tab0 AS cor0
----
7085
7544
7955

query I rowsort
SELECT cor0.col2 * + cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + - col2 * - 75 AS col1 FROM tab1 AS cor0
----
4050
4275
7200

query I rowsort
SELECT DISTINCT - + col1 * col2 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 col0 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT + + col1 * 32 FROM tab0 AS cor0
----
2752
2912
3104

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3864
SELECT - col1 * - ( - col0 * col2 + + CAST( - col0 AS SIGNED ) ) FROM tab2
----
-124254
-52377
-6076

skipif mysql # not compatible
query I rowsort label-3864
SELECT - col1 * - ( - col0 * col2 + + CAST ( - col0 AS INTEGER ) ) FROM tab2
----
-124254
-52377
-6076

query I rowsort
SELECT ALL - col1 + ( col0 ) AS col2 FROM tab0
----
-2
-62
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3866
SELECT DISTINCT col2 + - CAST( - 21 AS SIGNED ) AS col0 FROM tab1
----
117
75
78

skipif mysql # not compatible
query I rowsort label-3866
SELECT DISTINCT col2 + - CAST ( - 21 AS INTEGER ) AS col0 FROM tab1
----
117
75
78

query I rowsort
SELECT ALL col0 + - col0 * col2 + + col2 FROM tab2 AS cor0
----
-155
-1924
-2885

query I rowsort
SELECT DISTINCT + - col2 * col2 + + col1 * col0 FROM tab0 AS cor0
----
1375
3394
975

query I rowsort
SELECT + col1 * col0 + 77 AS col1 FROM tab2 AS cor0
----
1420
294
4679

query I rowsort
SELECT + cor0.col2 + - cor0.col2 * col2 + col2 FROM tab0 cor0
----
-1023
-6560
1

query I rowsort
SELECT DISTINCT + col0 * 67 AS col1 FROM tab2 AS cor0
----
469
5226
5293

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 27 col0 FROM tab0, tab2 cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col2 + + col0 * - col1 AS col0 FROM tab1 cor0
----
-10256
-2994
-3889

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 43 + - col2 * + cor0.col1 col2 FROM tab0 AS cor0
----
-2795
-54
-7419

query I rowsort
SELECT ALL col2 + col2 + 83 * col0 AS col0 FROM tab2
----
635
6526
6633

query I rowsort
SELECT DISTINCT - col1 + + col0 + 38 FROM tab2
----
100
14
57

query I rowsort
SELECT + 56 AS col1 FROM tab2 AS cor0
----
56
56
56

query I rowsort
SELECT DISTINCT + - col0 * + ( col1 ) + - col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col2 ) col2 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3880
SELECT CAST( col0 AS SIGNED ) + + col1 + - ( col1 * col1 ) FROM tab1 AS cor0
----
-26
-647
-76

skipif mysql # not compatible
query I rowsort label-3880
SELECT CAST ( col0 AS INTEGER ) + + col1 + - ( col1 * col1 ) FROM tab1 AS cor0
----
-26
-647
-76

query I rowsort
SELECT DISTINCT + - 56 * + cor0.col1 FROM tab0 AS cor0
----
-4816
-5096
-5432

query I rowsort
SELECT ALL - + 83 + - col1 FROM tab2 cor0
----
-100
-114
-142

query I rowsort
SELECT ALL cor0.col0 + - col0 + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + 84 * - cor0.col0 FROM tab2 AS cor0
----
-588
-6552
-6636

query I rowsort
SELECT ALL + col1 + - 51 * - col2 FROM tab0
----
148
1769
4273

query I rowsort
SELECT tab1.col1 + - col2 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + tab2.col2 + col2 * + 71 + col1 * col1 FROM tab2
----
2905
3025
5353

query I rowsort
SELECT ALL col2 + 5 + col2 FROM tab0
----
169
7
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-3889
SELECT DISTINCT - 1 DIV - col1 FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3889
SELECT DISTINCT - 1 / - col1 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT - 54 + col2 FROM tab1 AS cor0
----
0
3
42

query I rowsort
SELECT ALL - - cor0.col0 + col0 * col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT ALL + - 54 + col2 * 11 * col0 AS col1 FROM tab2 cor0
----
2025
22254
32968

query I rowsort
SELECT ALL + col0 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT ( - col1 ) * - col1 + col1 * col2 FROM tab0 AS cor0
----
10234
15743
9506

query I rowsort
SELECT ALL - 30 * - col0 - col1 FROM tab1 AS cor0
----
1910
2387
64

query I rowsort
SELECT ALL - col1 - + cor0.col1 * col0 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT + cor0.col1 + + col0 AS col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT ALL + - col1 * + col2 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3899
SELECT ALL CAST( col0 AS SIGNED ) FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3899
SELECT ALL CAST ( col0 AS INTEGER ) FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - col2 + cor0.col0 AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - + 28 AS col1 FROM tab0 AS cor0
----
-28
-28
-28

query I rowsort
SELECT ALL + 27 * - col1 + - ( - ( - col1 ) ) * - 47 AS col2 FROM tab0 cor0
----
1720
1820
1940

onlyif mysql # use DIV operator for integer division
query I rowsort label-3903
SELECT ALL + + col2 - - col2 DIV - ( 12 + col2 ) FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3903
SELECT ALL + + col2 - - col2 / - ( 12 + col2 ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT - 38 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

query I rowsort
SELECT ( - col1 ) + - col2 + col1 AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - col0 - col2 * 3 AS col2 FROM tab0
----
-123
-335
-38

query I rowsort
SELECT tab1.col1 * + col1 + - ( + col1 * col0 ) - + 35 * + col1 FROM tab1
----
-1326
-312
-890

query I rowsort
SELECT ALL - ( + col2 ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + 88 + + col2 AS col1 FROM tab1 AS cor0
----
142
145
184

query I rowsort
SELECT DISTINCT - col0 * col2 + col0 FROM tab2 cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-3911
SELECT ALL + ( + col0 ) DIV 48 - - col2 AS col2 FROM tab2 AS cor0
----
27
27
39

skipif mysql # not compatible
query I rowsort label-3911
SELECT ALL + ( + col0 ) / 48 - - col2 AS col2 FROM tab2 AS cor0
----
27
27
39

query I rowsort
SELECT ALL col0 * col1 + - col2 FROM tab2
----
1305
190
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-3913
SELECT ALL + 84 + col2 DIV col1 FROM tab0
----
84
84
84

skipif mysql # not compatible
query I rowsort label-3913
SELECT ALL + 84 + col2 / col1 FROM tab0
----
84
84
84

query I rowsort
SELECT - - 63 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3915
SELECT ALL 44 + - col1 DIV col0 AS col1 FROM tab1
----
36
44
44

skipif mysql # not compatible
query I rowsort label-3915
SELECT ALL 44 + - col1 / col0 AS col1 FROM tab1
----
36
44
44

query I rowsort
SELECT ALL + 84 * + tab1.col0 + - col0 + + col2 AS col1 FROM tab1
----
303
5369
6736

query I rowsort
SELECT ALL - 69 * + 38 * + col2 FROM tab0 AS cor0
----
-215004
-2622
-86526

query I rowsort
SELECT DISTINCT + + col2 + col2 * + col2 FROM tab1 cor0
----
2970
3306
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 87 col0 FROM tab1 AS cor0
----
-87
-87
-87

query I rowsort
SELECT ALL - col0 * + 70 AS col2 FROM tab0
----
-1680
-2450
-6230

query I rowsort
SELECT DISTINCT - 58 FROM tab1
----
-58

query I rowsort
SELECT 27 FROM tab1, tab2 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT DISTINCT - tab2.col1 * + 15 FROM tab2
----
-255
-465
-885

query I rowsort
SELECT ALL - 74 * col0 FROM tab0 AS cor0
----
-1776
-2590
-6586

query I rowsort
SELECT DISTINCT 74 * + col1 AS col1 FROM tab1 AS cor0
----
1924
740
962

query I rowsort
SELECT DISTINCT - col0 + col2 * - ( - col0 ) AS col1 FROM tab2 cor0
----
182
1950
2923

query I rowsort
SELECT 30 + cor0.col1 FROM tab1 cor0
----
40
43
56

query I rowsort
SELECT ALL + - col0 * col2 * ( cor0.col1 ) + - col2 * cor0.col0 FROM tab0 AS cor0
----
-3430
-671416
-68904

query I rowsort
SELECT - cor0.col0 + col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3931
SELECT cor0.col1 + - col0 * CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3931
SELECT cor0.col1 + - col0 * CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3932
SELECT - col2 + + col0 - CAST( NULL AS SIGNED ) / col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3932
SELECT - col2 + + col0 - CAST ( NULL AS INTEGER ) / col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 46 * + col2 AS col2 FROM tab2 AS cor0
----
1196
1242
1748

query I rowsort
SELECT - cor0.col1 + - col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT + ( - cor0.col2 ) + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + - cor0.col1 + - col0 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + cor0.col0 * - 64 AS col2 FROM tab0 AS cor0
----
-1536
-2240
-5696

query I rowsort
SELECT ALL cor0.col0 * + 56 + cor0.col2 FROM tab1 cor0
----
222
3641
4576

query I rowsort
SELECT ALL + + cor0.col0 * + col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3940
SELECT + col1 DIV cor0.col2 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-3940
SELECT + col1 / cor0.col2 col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( - col1 AS REAL ) * col1 + col2 + - col1 FROM tab1 cor0
----
147
252
704

query I rowsort
SELECT ALL 55 AS col2 FROM tab1 AS cor0
----
55
55
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 1 + + col0 - col1 col1 FROM tab0 cor0
----
-1
-61
-61

query I rowsort
SELECT ALL - + cor0.col2 + + cor1.col2 * 66 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 15d171a34fbf1033a152bb0bfc7b23c3

query I rowsort
SELECT DISTINCT - cor0.col2 + col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL + - 35 AS col2 FROM tab2 cor0
----
-35
-35
-35

query I rowsort
SELECT cor0.col1 * + col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + col2 * - cor0.col1 + col2 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3949
SELECT + CAST( col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3949
SELECT + CAST ( col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort
SELECT ALL - ( col1 ) + CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3951
SELECT + col2 DIV - 64 AS col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3951
SELECT + col2 / - 64 AS col0 FROM tab0
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3952
SELECT CAST( col2 AS SIGNED ) * col1 AS col2 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-3952
SELECT CAST ( col2 AS INTEGER ) * col1 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT + ( - col2 ) + + ( + ( + cor0.col0 ) ) AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL + - ( - cor0.col2 ) AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - 84 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-3956
SELECT DISTINCT - col0 DIV cor0.col1 AS col0 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-3956
SELECT DISTINCT - col0 / cor0.col1 AS col0 FROM tab2 cor0
----
-1
-4
0

query I rowsort
SELECT + - col2 + + col0 * 65 AS col2 FROM tab0 AS cor0
----
1527
2274
5703

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 54 col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
54

query I rowsort
SELECT + 66 + - 67 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif mysql # not compatible
query I rowsort
SELECT ALL tab2.col2 * + CAST ( col1 * - col0 AS REAL ) AS col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - col0 * + ( - col2 ) * col2 FROM tab1
----
207936
737280
8748

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3962
SELECT + col2 + + CAST( 9 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
35
36
47

skipif mysql # not compatible
query I rowsort label-3962
SELECT + col2 + + CAST ( 9 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
35
36
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-3963
SELECT DISTINCT col0 DIV col1 + col2 FROM tab2 AS cor0
----
27
42

skipif mysql # not compatible
query I rowsort label-3963
SELECT DISTINCT col0 / col1 + col2 FROM tab2 AS cor0
----
27
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3964
SELECT ALL - - cor0.col1 * CAST( NULL AS SIGNED ) * + col2 + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3964
SELECT ALL - - cor0.col1 * CAST ( NULL AS INTEGER ) * + col2 + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * 53 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT ALL - cor0.col0 - cor0.col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - + col0 * + cor0.col2 + + cor0.col0 AS col1 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT ALL - col0 * - cor0.col1 + 62 AS col0 FROM tab2 AS cor0
----
1405
279
4664

query I rowsort
SELECT + cor0.col0 * col0 + 30 AS col2 FROM tab1 AS cor0
----
39
4126
6430

query I rowsort
SELECT + col1 + - 84 FROM tab1 AS cor0
----
-58
-71
-74

query I rowsort
SELECT + - col1 + - 81 FROM tab0 AS cor0
----
-167
-172
-178

query I rowsort
SELECT ALL + + col2 + - 68 AS col1 FROM tab1 cor0
----
-11
-14
28

query I rowsort
SELECT ALL + col1 + + 86 + - col1 AS col2 FROM tab0 cor0
----
86
86
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col0 + ( + col1 + col1 ) * + col2 col1 FROM tab2 AS cor0
----
1891
2635
7670

query I rowsort
SELECT - + col0 + + col1 * 6 + col1 FROM tab0 cor0
----
548
578
644

query I rowsort
SELECT DISTINCT col0 + ( col2 ) * cor0.col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + + cor0.col0 + + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - cor0.col0 + + col0 + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 3 * cor0.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 1df77a959b97e808dec5206239125e74

onlyif mysql # use DIV operator for integer division
query I rowsort label-3981
SELECT ALL - col0 + - col2 DIV - col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-3981
SELECT ALL - col0 + - col2 / - col2 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT col0 + 36 AS col2 FROM tab1
----
100
116
39

query I rowsort
SELECT ALL ( col2 ) FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 col1 FROM tab0
----
-98
-98
-98

query I rowsort
SELECT - 87 FROM tab0, tab2 cor0
----
9 values hashing to 84bcab58a965cc8ae97b39d2d01b3d23

query I rowsort
SELECT + cor0.col0 * + 55 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a9ac1870cd1d3b91eef55464077bbaad

onlyif mysql # use DIV operator for integer division
query I rowsort label-3987
SELECT ALL + 57 DIV - col2 FROM tab0 AS cor0
----
-1
-57
0

skipif mysql # not compatible
query I rowsort label-3987
SELECT ALL + 57 / - col2 FROM tab0 AS cor0
----
-1
-57
0

query I rowsort
SELECT + + cor0.col0 * - cor0.col2 * col0 AS col1 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT + 61 + + col1 * - 4 FROM tab2 AS cor0
----
-175
-63
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 53 col2 FROM tab2
----
53
53
53

query I rowsort
SELECT ALL col1 * - col2 - col1 AS col0 FROM tab0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-3992
SELECT + ( col2 ) DIV - col2 + + tab0.col0 AS col2 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-3992
SELECT + ( col2 ) / - col2 + + tab0.col0 AS col2 FROM tab0
----
23
34
88

query I rowsort
SELECT DISTINCT col2 * col0 + 33 * - col2 FROM tab1
----
-1620
1767
4512

query I rowsort
SELECT + col2 * - col2 AS col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT + 15 * col2 - 81 AS col2 FROM tab1
----
1359
729
774

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 88 - - col0 col0 FROM tab2
----
-10
-81
-9

query I rowsort
SELECT - - cor0.col1 - col0 * - 62 AS col2 FROM tab0 AS cor0
----
1574
2267
5609

query I rowsort
SELECT ALL - col1 * + col1 + col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL - 46 + + col0 * col0 AS col2 FROM tab0
----
1179
530
7875

query I rowsort
SELECT ALL 8 - + col0 * col0 AS col1 FROM tab1
----
-1
-4088
-6392

query I rowsort
SELECT - col1 * + col1 * ( cor0.col0 ) FROM tab1 AS cor0
----
-13520
-2028
-6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 63 col0 FROM tab1 AS cor0
----
-63
-63
-63

query I rowsort
SELECT DISTINCT 49 * col0 AS col1 FROM tab0
----
1176
1715
4361

query I rowsort
SELECT - col0 + + col1 * col2 AS col2 FROM tab2
----
1456
567
830

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT + col2 + 10 * + ( col2 ) FROM tab0 AS cor0
----
11
363
902

query I rowsort
SELECT DISTINCT + 19 FROM tab1, tab0 AS cor0
----
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-4008
SELECT col1 DIV - 33 + cor0.col2 FROM tab0 AS cor0
----
-1
31
80

skipif mysql # not compatible
query I rowsort label-4008
SELECT col1 / - 33 + cor0.col2 FROM tab0 AS cor0
----
-1
31
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4009
SELECT - - col1 DIV CAST( ( + col1 ) AS SIGNED ) + - col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-4009
SELECT - - col1 / CAST ( ( + col1 ) AS INTEGER ) + - col0 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
10
13
26

query I rowsort
SELECT DISTINCT + + col2 + col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT - - 68 FROM tab2, tab0, tab0 AS cor0, tab1
----
68

query I rowsort
SELECT ALL - 66 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT DISTINCT ( 74 + - col0 * col0 ) FROM tab0
----
-1151
-502
-7847

query I rowsort
SELECT 80 + - col1 AS col0 FROM tab2
----
21
49
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4016
SELECT DISTINCT + 18 DIV - col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-4016
SELECT DISTINCT + 18 / - col1 FROM tab0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4017
SELECT DISTINCT - + col1 * col2 + + cor0.col1 DIV col1 FROM tab2 AS cor0
----
-1533
-645
-836

skipif mysql # not compatible
query I rowsort label-4017
SELECT DISTINCT - + col1 * col2 + + cor0.col1 / col1 FROM tab2 AS cor0
----
-1533
-645
-836

onlyif mysql # use DIV operator for integer division
query I rowsort label-4018
SELECT + + 42 + - col2 DIV col0 AS col0 FROM tab0 AS cor0
----
41
42
42

skipif mysql # not compatible
query I rowsort label-4018
SELECT + + 42 + - col2 / col0 AS col0 FROM tab0 AS cor0
----
41
42
42

query I rowsort
SELECT + col0 * 95 AS col2 FROM tab0 AS cor0
----
2280
3325
8455

query I rowsort
SELECT DISTINCT - 79 + + col0 AS col2 FROM tab0 AS cor0
----
-44
-55
10

query I rowsort
SELECT ALL - + cor0.col1 * - 77 AS col0 FROM tab0 AS cor0
----
6622
7007
7469

onlyif mysql # use DIV operator for integer division
query I rowsort label-4022
SELECT DISTINCT + ( col1 ) DIV + col2 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4022
SELECT DISTINCT + ( col1 ) / + col2 AS col1 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4023
SELECT - 98 DIV + col0 FROM tab2 cor0
----
-1
-1
-14

skipif mysql # not compatible
query I rowsort label-4023
SELECT - 98 / + col0 FROM tab2 cor0
----
-1
-1
-14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + + col1 * cor0.col1 col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT 64 AS col2 FROM tab1 cor0
----
64

query I rowsort
SELECT DISTINCT - ( 85 ) * - col2 AS col0 FROM tab0
----
2805
6970
85

query I rowsort
SELECT + - 44 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-3784
-4004
-4268

query I rowsort
SELECT - 93 * col2 FROM tab1 AS cor0
----
-5022
-5301
-8928

query I rowsort
SELECT + col1 * 53 * - col1 + ( + col1 ) FROM tab0
----
-391902
-438802
-498580

query I rowsort
SELECT DISTINCT - ( 75 * col1 ) AS col0 FROM tab0
----
-6450
-6825
-7275

query I rowsort
SELECT - col2 + + cor0.col1 * col0 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4032
SELECT CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4032
SELECT CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 * + 58 AS col0 FROM tab0 AS cor0
----
4988
5278
5626

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + 32 * - 57 col1 FROM tab0
----
-1735
-1789
-1800

query I rowsort
SELECT - 14 FROM tab1, tab1 AS cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

onlyif mysql # use DIV operator for integer division
query I rowsort label-4036
SELECT ALL - col0 DIV col0 + 64 col2 FROM tab2 AS cor0
----
63
63
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4036
SELECT ALL - col0 / col0 + 64 col2 FROM tab2 AS cor0
----
63
63
63

query I rowsort
SELECT - 13 + - col2 FROM tab1 AS cor0
----
-109
-67
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4038
SELECT CAST( 3 AS SIGNED ) FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

skipif mysql # not compatible
query I rowsort label-4038
SELECT CAST ( 3 AS INTEGER ) FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 21 col1 FROM tab1
----
21
21
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4040
SELECT ALL cor0.col0 + - CAST( NULL AS SIGNED ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4040
SELECT ALL cor0.col0 + - CAST ( NULL AS INTEGER ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4041
SELECT 19 DIV - 18 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4041
SELECT 19 / - 18 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT ALL 94 * col0 AS col1 FROM tab0
----
2256
3290
8366

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4043
SELECT - col0 + + CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4043
SELECT - col0 + + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col2 + - 11 AS col1 FROM tab2 AS cor0
----
15
16
27

query I rowsort
SELECT ( col0 ) + - 26 AS col0 FROM tab2
----
-19
52
53

query I rowsort
SELECT + 63 AS col1 FROM tab0
----
63
63
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4047
SELECT 36 + col1 DIV - col1 AS col0 FROM tab2
----
35
35
35

skipif mysql # not compatible
query I rowsort label-4047
SELECT 36 + col1 / - col1 AS col0 FROM tab2
----
35
35
35

query I rowsort
SELECT ALL + col2 * - 13 AS col1 FROM tab0 cor0
----
-1066
-13
-429

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 34 col0 FROM tab2 AS cor0
----
-238
-2652
-2686

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + 0 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 * - 71 + 85 + col1 AS col1 FROM tab0 AS cor0
----
-5935
-6285
-6705

query I rowsort
SELECT col1 * + col1 + + col2 AS col0 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT + 11 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT - col2 * 79 * col2 AS col2 FROM tab0
----
-531196
-79
-86031

query I rowsort
SELECT + col1 + + 70 * col1 + col0 AS col1 FROM tab2 AS cor0
----
1286
2208
4267

skipif mysql # not compatible
query I rowsort
SELECT - - col0 * + CAST ( col2 AS REAL ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ( 96 ) FROM tab2, tab1 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

onlyif mysql # use DIV operator for integer division
query I rowsort label-4058
SELECT - col0 * col1 DIV col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-4058
SELECT - col0 * col1 / col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + - 87 * col1 * cor0.col0 FROM tab0 AS cor0
----
-179568
-295365
-704613

query I rowsort
SELECT cor0.col0 * col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - col0 + cor0.col0 * col1 * - col0 FROM tab2 AS cor0
----
-106176
-1526
-359034

query I rowsort
SELECT DISTINCT - - col2 * col1 - col2 AS col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT + 76 * + ( + cor0.col0 ) AS col1 FROM tab2 AS cor0
----
532
5928
6004

query I rowsort
SELECT DISTINCT - - col0 + cor0.col2 AS col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - + cor0.col1 * + col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + 11 * col2 AS col1 FROM tab2 AS cor0
----
286
297
418

query I rowsort
SELECT ALL - + col2 + cor0.col1 AS col1 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT 53 * col1 FROM tab2 AS cor0
----
1643
3127
901

query I rowsort
SELECT ALL + col2 - + col2 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4070
SELECT DISTINCT - + col0 DIV col2 AS col0 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4070
SELECT DISTINCT - + col0 / col2 AS col0 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT ALL + - col1 + - 41 FROM tab1 cor0
----
-51
-54
-67

query I rowsort
SELECT - 26 - col1 FROM tab2 AS cor0
----
-43
-57
-85

query I rowsort
SELECT ALL 12 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT ALL + col1 * + tab1.col0 * - col0 - 30 FROM tab1
----
-264
-40990
-83230

query I rowsort
SELECT - 32 - col1 AS col2 FROM tab0 AS cor0
----
-118
-123
-129

query I rowsort
SELECT - col1 + - cor0.col1 FROM tab1 AS cor0
----
-20
-26
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4077
SELECT col0 * + col2 + cor0.col0 DIV 36 + - col2 FROM tab2 cor0
----
162
2004
2966

skipif mysql # not compatible
query I rowsort label-4077
SELECT col0 * + col2 + cor0.col0 / 36 + - col2 FROM tab2 cor0
----
162
2004
2966

query I rowsort
SELECT - col1 * col0 * + col1 - - col0 FROM tab0 AS cor0
----
-177480
-329280
-736920

query I rowsort
SELECT + + col2 * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + col2 * cor0.col2 AS col1 FROM tab0 cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 5 * col1 * col1 - + cor0.col1 col1 FROM tab1 AS cor0
----
3354
490
832

query I rowsort
SELECT ALL + col0 + 50 * cor0.col0 AS col0 FROM tab2 AS cor0
----
357
3978
4029

query I rowsort
SELECT ALL + col1 + 67 * + col2 AS col1 FROM tab1 AS cor0
----
3644
3829
6445

query I rowsort
SELECT DISTINCT + - col2 * - 20 FROM tab1 AS cor0
----
1080
1140
1920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4085
SELECT col2 * CAST( NULL AS SIGNED ) + - 40 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4085
SELECT col2 * CAST ( NULL AS INTEGER ) + - 40 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4086
SELECT DISTINCT - col1 * + ( + col2 ) + col1 DIV col1 + - col2 FROM tab2 AS cor0
----
-1559
-683
-863

skipif mysql # not compatible
query I rowsort label-4086
SELECT DISTINCT - col1 * + ( + col2 ) + col1 / col1 + - col2 FROM tab2 AS cor0
----
-1559
-683
-863

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * + col1 col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ( + col1 ) - + col2 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + 80 * col0 AS col0 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT + + col0 + cor0.col1 * - col1 AS col0 FROM tab0 cor0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL col0 - + 90 FROM tab1
----
-10
-26
-87

query I rowsort
SELECT ALL 64 + cor0.col2 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to e0fb1bb6ea72cf94892aa85c4ae74bfc

onlyif mysql # use DIV operator for integer division
query I rowsort label-4093
SELECT DISTINCT col0 DIV + 39 + + col1 FROM tab1
----
11
15
26

skipif mysql # not compatible
query I rowsort label-4093
SELECT DISTINCT col0 / + 39 + + col1 FROM tab1
----
11
15
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4094
SELECT DISTINCT + 30 + 60 DIV col0 + col0 * col0 FROM tab1 cor0
----
4126
59
6430

skipif mysql # not compatible
query I rowsort label-4094
SELECT DISTINCT + 30 + 60 / col0 + col0 * col0 FROM tab1 cor0
----
4126
59
6430

onlyif mysql # use DIV operator for integer division
query I rowsort label-4095
SELECT + col2 + col1 DIV - col0 FROM tab0 cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-4095
SELECT + col2 + col1 / - col0 FROM tab0 cor0
----
-1
30
81

query I rowsort
SELECT DISTINCT 0 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - ( 17 ) + + cor0.col2 AS col2 FROM tab0 AS cor0
----
-16
16
65

query I rowsort
SELECT ALL - cor0.col0 * col2 + col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4099
SELECT ALL + + CAST( NULL AS DECIMAL ) + - col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4099
SELECT ALL + + CAST ( NULL AS REAL ) + - col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col1 * - col2 col2 FROM tab0 AS cor0
----
-194
-2924
-7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col0 ) col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT ( ( - col0 ) ) * + ( col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + 36 AS col1 FROM tab0 AS cor0
----
36

query I rowsort
SELECT + + col0 * + 63 AS col2 FROM tab2 AS cor0
----
441
4914
4977

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4105
SELECT DISTINCT + + CAST( NULL AS DECIMAL ) col2 FROM tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4105
SELECT DISTINCT + + CAST ( NULL AS REAL ) col2 FROM tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4106
SELECT ALL + CAST( - 43 AS SIGNED ) * + col2 AS col2 FROM tab0 AS cor0
----
-1419
-3526
-43

skipif mysql # not compatible
query I rowsort label-4106
SELECT ALL + CAST ( - 43 AS INTEGER ) * + col2 AS col2 FROM tab0 AS cor0
----
-1419
-3526
-43

query I rowsort
SELECT + + col2 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4108
SELECT + + CAST( NULL AS SIGNED ) / + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4108
SELECT + + CAST ( NULL AS INTEGER ) / + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 11 col2 FROM tab0 AS cor0
----
-11

query I rowsort
SELECT - - col2 * + cor0.col1 + + 66 AS col2 FROM tab1 AS cor0
----
1314
1470
636

query I rowsort
SELECT ALL + cor0.col0 * - col0 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT + - col2 * - col1 * col1 AS col2 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-4113
SELECT 76 DIV + col2 + cor0.col0 FROM tab0 AS cor0
----
111
26
89

skipif mysql # not compatible
query I rowsort label-4113
SELECT 76 / + col2 + cor0.col0 FROM tab0 AS cor0
----
111
26
89

query I rowsort
SELECT + + cor1.col0 * cor1.col2 AS col0 FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to 958b586547269e86b536643b26e95d81

query I rowsort
SELECT DISTINCT cor0.col0 - ( + col1 * + col1 ) FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT col1 * - 9 FROM tab0 AS cor0
----
-774
-819
-873

query I rowsort
SELECT cor2.col2 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to 39c7e653e7a493eb9c9e3dad9ba3b8c2

query I rowsort
SELECT DISTINCT + col1 - col1 AS col0 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT - col0 * 7 FROM tab0 AS cor0
----
-168
-245
-623

onlyif mysql # use DIV operator for integer division
query I rowsort label-4120
SELECT cor0.col2 DIV cor1.col0 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 46dc82396a3ef8c6a2f1d1e7bccce5f0

skipif mysql # not compatible
query I rowsort label-4120
SELECT cor0.col2 / cor1.col0 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 46dc82396a3ef8c6a2f1d1e7bccce5f0

query I rowsort
SELECT DISTINCT 33 AS col0 FROM tab1
----
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 81 col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT DISTINCT - + col1 * + ( 86 * col1 ) + + 99 * + ( + col1 ) AS col1 FROM tab1 cor0
----
-13247
-55562
-7610

query I rowsort
SELECT DISTINCT - 72 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
-72

query I rowsort
SELECT ALL - + col1 * - col0 * col0 AS col1 FROM tab0 AS cor0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-4126
SELECT + col1 DIV col0 + col0 FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-4126
SELECT + col1 / col0 + col0 FROM tab0
----
27
37
90

query I rowsort
SELECT DISTINCT col0 * 77 AS col2 FROM tab0 AS cor0
----
1848
2695
6853

query I rowsort
SELECT DISTINCT 5 AS col0 FROM tab1, tab1 AS cor0
----
5

query I rowsort
SELECT + 66 * - tab2.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to ceed856ba7b30efd902e3354de5befbc

query I rowsort
SELECT + col1 * 58 FROM tab1 AS cor0
----
1508
580
754

query I rowsort
SELECT + 0 + + 86 FROM tab2 AS cor0
----
86
86
86

query I rowsort
SELECT ALL cor1.col2 * + 44 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 77463d4e80114339c2fe4ecac3a38ead

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4133
SELECT ALL + + CAST( NULL AS DECIMAL ) * - col1 / - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4133
SELECT ALL + + CAST ( NULL AS REAL ) * - col1 / - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 7 AS col0 FROM tab0 AS cor0
----
-7
-7
-7

query I rowsort
SELECT 68 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4136
SELECT ALL CAST( + col2 AS SIGNED ) FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4136
SELECT ALL CAST ( + col2 AS INTEGER ) FROM tab0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4137
SELECT ALL CAST( NULL AS DECIMAL ) * tab2.col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4137
SELECT ALL CAST ( NULL AS REAL ) * tab2.col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4138
SELECT ALL + 78 * 14 DIV - col1 AS col0 FROM tab0 AS cor0
----
-11
-12
-12

skipif mysql # not compatible
query I rowsort label-4138
SELECT ALL + 78 * 14 / - col1 AS col0 FROM tab0 AS cor0
----
-11
-12
-12

query I rowsort
SELECT + 48 * col2 AS col2 FROM tab2 AS cor0
----
1248
1296
1824

onlyif mysql # use DIV operator for integer division
query I rowsort label-4140
SELECT DISTINCT + col0 DIV - col1 + col2 * + col2 + 17 FROM tab1 AS cor0
----
2933
3260
9227

skipif mysql # not compatible
query I rowsort label-4140
SELECT DISTINCT + col0 / - col1 + col2 * + col2 + 17 FROM tab1 AS cor0
----
2933
3260
9227

query I rowsort
SELECT DISTINCT - 62 - col0 AS col2 FROM tab2 cor0
----
-140
-141
-69

query I rowsort
SELECT DISTINCT 63 + - col2 FROM tab2 AS cor0
----
25
36
37

query I rowsort
SELECT ALL 62 + col2 FROM tab0
----
144
63
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col2 + col1 col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT + - 9 * - col2 * col0 FROM tab2 AS cor0
----
1701
18252
27018

onlyif mysql # use DIV operator for integer division
query I rowsort label-4146
SELECT + 58 + + cor0.col1 + ( col1 ) DIV - cor0.col2 AS col1 FROM tab1 AS cor0
----
68
71
84

skipif mysql # not compatible
query I rowsort label-4146
SELECT + 58 + + cor0.col1 + ( col1 ) / - cor0.col2 AS col1 FROM tab1 AS cor0
----
68
71
84

query I rowsort
SELECT ALL 30 AS col2 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4148
SELECT - + 72 DIV col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4148
SELECT - + 72 / col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT 45 * - col1 + col2 FROM tab1
----
-1116
-393
-489

query I rowsort
SELECT ALL col1 + + tab2.col1 * - col0 * col0 FROM tab2
----
-106080
-1488
-358897

query I rowsort
SELECT + col0 + - col2 + - 46 * tab0.col2 AS col1 FROM tab0
----
-12
-1527
-3765

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4152
SELECT + col2 + + CAST( 78 AS SIGNED ) + - col1 FROM tab2 AS cor0
----
45
74
99

skipif mysql # not compatible
query I rowsort label-4152
SELECT + col2 + + CAST ( 78 AS INTEGER ) + - col1 FROM tab2 AS cor0
----
45
74
99

query I rowsort
SELECT DISTINCT + cor0.col1 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL cor0.col0 * + 50 FROM tab2 AS cor0
----
350
3900
3950

query I rowsort
SELECT - col2 * col2 + 32 * col0 FROM tab1 AS cor0
----
-1201
-2820
-6656

onlyif mysql # use DIV operator for integer division
query I rowsort label-4156
SELECT ALL + col2 + 16 DIV - col0 FROM tab2 AS cor0
----
25
26
38

skipif mysql # not compatible
query I rowsort label-4156
SELECT ALL + col2 + 16 / - col0 FROM tab2 AS cor0
----
25
26
38

query I rowsort
SELECT DISTINCT - col0 - 68 FROM tab0 AS cor0
----
-103
-157
-92

query I rowsort
SELECT DISTINCT - + col2 + col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL - - col2 * - ( - 25 ) FROM tab0 AS cor0
----
2050
25
825

query I rowsort
SELECT + cor0.col1 + col2 * - col0 + col1 AS col1 FROM tab1 AS cor0
----
-110
-3628
-7654

query I rowsort
SELECT ALL + col0 + + 94 FROM tab1 AS cor0
----
158
174
97

query I rowsort
SELECT ALL - - cor0.col1 * - col2 - col0 * + col0 AS col1 FROM tab1 AS cor0
----
-1413
-4666
-7648

query I rowsort
SELECT - cor0.col0 + + ( col1 ) * col1 AS col0 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT DISTINCT + col2 - + 82 FROM tab0 AS cor0
----
-49
-81
0

query I rowsort
SELECT + + cor0.col1 * + ( col2 ) + cor0.col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL col2 * 69 + 57 + + col0 AS col2 FROM tab2 cor0
----
1927
1929
2758

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 47 col2 FROM tab0 AS cor0
----
-47
-47
-47

query I rowsort
SELECT ALL + ( - col2 ) AS col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - 67 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 + cor0.col1 col0 FROM tab2 AS cor0
----
43
57
85

query I rowsort
SELECT - cor2.col2 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0, tab0 cor2
----
243 values hashing to 3e2b81ca10484cbfc66f186955e0e920

query I rowsort
SELECT + col1 + ( - 25 ) FROM tab1 AS cor0
----
-12
-15
1

query I rowsort
SELECT - - col2 + 45 AS col0 FROM tab0 AS cor0
----
127
46
78

query I rowsort
SELECT - col2 + 97 * 22 AS col2 FROM tab0 AS cor0
----
2052
2101
2133

onlyif mysql # use DIV operator for integer division
query I rowsort label-4175
SELECT ALL col1 DIV col1 col1 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4175
SELECT ALL col1 / col1 col1 FROM tab1
----
1
1
1

query I rowsort
SELECT 67 AS col0 FROM tab1
----
67
67
67

query I rowsort
SELECT + + 98 * + col1 + - col0 * - 13 FROM tab1 AS cor0
----
1812
2314
2587

onlyif mysql # use DIV operator for integer division
query I rowsort label-4178
SELECT - col1 DIV col0 + col0 * col2 FROM tab2 AS cor0
----
185
2028
3002

skipif mysql # not compatible
query I rowsort label-4178
SELECT - col1 / col0 + col0 * col2 FROM tab2 AS cor0
----
185
2028
3002

query I rowsort
SELECT + col0 * col0 + - col2 AS col2 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT ALL - col0 + 68 * - col2 AS col1 FROM tab2
----
-1843
-1846
-2663

query I rowsort
SELECT DISTINCT + col2 + + 80 * - 83 FROM tab2
----
-6602
-6613
-6614

query I rowsort
SELECT ALL + col1 * col2 + - col1 + + col2 AS col2 FROM tab0 AS cor0
----
1
2785
7453

query I rowsort
SELECT - + col1 * - ( col2 ) + - 10 FROM tab2 AS cor0
----
1524
636
827

query I rowsort
SELECT ALL + + col1 * + 17 + - col2 AS col0 FROM tab1 cor0
----
113
125
388

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4185
SELECT ALL CAST( - col2 AS SIGNED ) * - col1 + 62 FROM tab2 AS cor0
----
1596
708
899

skipif mysql # not compatible
query I rowsort label-4185
SELECT ALL CAST ( - col2 AS INTEGER ) * - col1 + 62 FROM tab2 AS cor0
----
1596
708
899

query I rowsort
SELECT + 80 + - col0 AS col1 FROM tab1 AS cor0
----
0
16
77

query I rowsort
SELECT ALL 45 + + col0 * col1 FROM tab0 AS cor0
----
2109
3440
8144

query I rowsort
SELECT DISTINCT + + col1 + col1 - cor0.col2 AS col1 FROM tab0 AS cor0
----
100
139
193

query I rowsort
SELECT DISTINCT + - col0 + col2 * col1 AS col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT col0 * 1 FROM tab2
----
7
78
79

query I rowsort
SELECT ( + col0 ) * + col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL - 89 AS col2 FROM tab2 AS cor0
----
-89
-89
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - cor0.col0 ) col1 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4194
SELECT ALL - col2 DIV - col2 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-4194
SELECT ALL - col2 / - col2 col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - col2 + + col2 * - cor0.col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT - ( - col1 ) + col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL 65 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT DISTINCT ( + col1 ) - - col1 FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4199
SELECT ALL + ( + col2 ) DIV - col0 - - ( tab0.col0 ) * col1 AS col1 FROM tab0
----
2063
3395
8099

skipif mysql # not compatible
query I rowsort label-4199
SELECT ALL + ( + col2 ) / - col0 - - ( tab0.col0 ) * col1 AS col1 FROM tab0
----
2063
3395
8099

query I rowsort
SELECT 25 * col0 FROM tab2
----
175
1950
1975

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - tab2.col0 col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL 59 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT ALL + cor0.col2 * + 80 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 22b9425e09ee8bd0a2a63c6f914fa897

query I rowsort
SELECT DISTINCT col2 + col1 AS col0 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 + col2 * + ( + 44 ) col0 FROM tab1 AS cor0
----
2443
2575
4291

onlyif mysql # use DIV operator for integer division
query I rowsort label-4206
SELECT - ( col2 ) * col0 + - 50 DIV col1 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-4206
SELECT - ( col2 ) * col0 + - 50 / col1 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4207
SELECT + col2 * CAST( 59 AS SIGNED ) FROM tab0 cor0
----
1947
4838
59

skipif mysql # not compatible
query I rowsort label-4207
SELECT + col2 * CAST ( 59 AS INTEGER ) FROM tab0 cor0
----
1947
4838
59

query I rowsort
SELECT col1 * + ( - col2 + col1 ) FROM tab0 cor0
----
4558
819
9312

query I rowsort
SELECT + cor0.col1 + 2 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to e539bf0beb11ad56ef3c9cededc47e07

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4210
SELECT + - CAST( + ( + col1 ) AS SIGNED ) + + col0 FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-4210
SELECT + - CAST ( + ( + col1 ) AS INTEGER ) + + col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - col2 * - ( col2 * - tab2.col0 + + col0 ) FROM tab2
----
-111074
-4914
-50700

query I rowsort
SELECT - col2 * - 51 FROM tab0
----
1683
4182
51

query I rowsort
SELECT 38 + - col1 * + col1 AS col2 FROM tab1 AS cor0
----
-131
-62
-638

query I rowsort
SELECT - ( col1 ) + - col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT - tab1.col1 * - col0 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT 68 AS col1 FROM tab2
----
68

query I rowsort
SELECT - - cor0.col0 AS col1 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - col2 * col1 + 78 * col0 AS col2 FROM tab0 AS cor0
----
-520
-966
2633

query I rowsort
SELECT ALL + col2 - col1 AS col2 FROM tab0 cor0
----
-53
-9
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4220
SELECT + col0 + col2 * - CAST( NULL AS SIGNED ) * + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4220
SELECT + col0 + col2 * - CAST ( NULL AS INTEGER ) * + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * + col1 + 43 AS col2 FROM tab0
----
140
2881
7505

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4222
SELECT ALL + CAST( NULL AS DECIMAL ) FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4222
SELECT ALL + CAST ( NULL AS REAL ) FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - 26 col1 FROM tab0 cor0
----
-25
56
7

query I rowsort
SELECT DISTINCT - col0 * 87 AS col1 FROM tab0 AS cor0
----
-2088
-3045
-7743

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4225
SELECT ALL + col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4225
SELECT ALL + col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + - col1 * col2 FROM tab0 AS cor0
----
-132
-2862
-7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + 41 col1 FROM tab1
----
137
95
98

query I rowsort
SELECT DISTINCT col1 - ( col0 ) FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT ALL - col0 * 19 AS col0 FROM tab2 AS cor0
----
-133
-1482
-1501

query I rowsort
SELECT DISTINCT + + col0 * col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT + col0 * 70 + col0 AS col2 FROM tab1 AS cor0
----
213
4544
5680

query I rowsort
SELECT DISTINCT - col2 + - col1 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col0 - - CAST ( - ( col1 ) AS REAL ) FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + col2 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - - col1 * col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + - col1 * col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + 64 col2 FROM tab0 AS cor0
----
150
155
161

query I rowsort
SELECT ALL + col1 * - col1 + - col0 * - col1 FROM tab0 AS cor0
----
-182
-5332
-6014

query I rowsort
SELECT ALL col0 * cor0.col1 + col0 * col1 FROM tab1 AS cor0
----
1280
156
2080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + ( col1 ) col2 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4241
SELECT CAST( NULL AS DECIMAL ) * ( col0 ) + 2 col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4241
SELECT CAST ( NULL AS REAL ) * ( col0 ) + 2 col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - - col2 col2 FROM tab2
----
-41
-52
20

query I rowsort
SELECT - ( 38 ) AS col0 FROM tab2
----
-38
-38
-38

query I rowsort
SELECT - col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL + 43 AS col0 FROM tab2 AS cor0
----
43
43
43

query I rowsort
SELECT ALL + 82 * col2 AS col1 FROM tab1 cor0
----
4428
4674
7872

query I rowsort
SELECT col0 * col2 * col0 + 24 + + cor0.col0 * col0 FROM tab2 AS cor0
----
1396
164292
243423

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col2 ) col2 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4249
SELECT CAST( - col1 AS SIGNED ) * col0 + - col1 FROM tab1 AS cor0
----
-104
-1053
-650

skipif mysql # not compatible
query I rowsort label-4249
SELECT CAST ( - col1 AS INTEGER ) * col0 + - col1 FROM tab1 AS cor0
----
-104
-1053
-650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4250
SELECT + - ( - col2 ) + - col0 / CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4250
SELECT + - ( - col2 ) + - col0 / CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 69 AS col2 FROM tab0 AS cor0
----
69

query I rowsort
SELECT - col0 * - col2 + + col2 * col0 + ( col0 ) * + col1 AS col1 FROM tab2 AS cor0
----
595
7347
8658

query I rowsort
SELECT DISTINCT - - col2 * + col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - - 62 * - col0 * col2 AS col0 FROM tab0 AS cor0
----
-2170
-452476
-49104

query I rowsort
SELECT + col0 * + col0 + - 75 * 75 + + col2 AS col2 FROM tab1 AS cor0
----
-1472
-5562
871

query I rowsort
SELECT + 34 + + cor0.col0 + 97 * col1 * - col2 AS col2 FROM tab1 cor0
----
-120942
-136151
-55192

query I rowsort
SELECT + 28 * - col2 FROM tab2 AS cor0
----
-1064
-728
-756

query I rowsort
SELECT ALL + 7 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4259
SELECT ALL - - col0 - col0 / CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4259
SELECT ALL - - col0 - col0 / CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 2464a6f4cfabe66aeca50fcb4cd85bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 60 col0 FROM tab1 AS cor0
----
60

query I rowsort
SELECT ALL + 28 FROM tab1 AS cor0
----
28
28
28

query I rowsort
SELECT ALL - 38 * col0 + col0 + - col2 AS col2 FROM tab0 AS cor0
----
-1296
-3375
-921

onlyif mysql # use DIV operator for integer division
query I rowsort label-4264
SELECT DISTINCT - - col0 * col0 + 41 DIV col0 AS col1 FROM tab1 AS cor0
----
22
4096
6400

skipif mysql # not compatible
query I rowsort label-4264
SELECT DISTINCT - - col0 * col0 + 41 / col0 AS col1 FROM tab1 AS cor0
----
22
4096
6400

query I rowsort
SELECT DISTINCT ( - col1 + - col2 ) * + tab2.col1 FROM tab2
----
-1798
-5015
-935

query I rowsort
SELECT + + col2 + cor0.col2 + ( col0 ) FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT + + col2 * cor0.col1 + 54 FROM tab2 AS cor0
----
1588
700
891

query I rowsort
SELECT - cor0.col0 + cor0.col1 + - 94 AS col0 FROM tab1 AS cor0
----
-148
-161
-71

query I rowsort
SELECT - - col2 + col0 * + cor0.col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT ALL ( + col0 ) + - 38 AS col2 FROM tab0 AS cor0
----
-14
-3
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-4271
SELECT DISTINCT - + col2 * col2 DIV 8 + + col0 * + col0 AS col1 FROM tab2 AS cor0
----
-42
6000
6061

skipif mysql # not compatible
query I rowsort label-4271
SELECT DISTINCT - + col2 * col2 / 8 + + col0 * + col0 AS col1 FROM tab2 AS cor0
----
-42
6000
6061

query I rowsort
SELECT ALL - + col0 + col2 AS col0 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-4273
SELECT - - col1 DIV 81 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4273
SELECT - - col1 / 81 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - col1 * - col1 + col2 * + col1 + - 21 FROM tab1 AS cor0
----
1058
449
707

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4275
SELECT + col0 * CAST( + col2 AS SIGNED ) FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-4275
SELECT + col0 * CAST ( + col2 AS INTEGER ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col2 * - col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT col2 * col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT ALL + ( 67 ) * col1 + - col0 + col0 * col0 FROM tab0 AS cor0
----
13929
6314
7689

query I rowsort
SELECT ALL cor1.col2 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4280
SELECT DISTINCT - + ( 41 ) + - col0 DIV col2 AS col1 FROM tab1 AS cor0
----
-41
-42

skipif mysql # not compatible
query I rowsort label-4280
SELECT DISTINCT - + ( 41 ) + - col0 / col2 AS col1 FROM tab1 AS cor0
----
-41
-42

query I rowsort
SELECT 96 + 68 FROM tab0 AS cor0
----
164
164
164

query I rowsort
SELECT - + ( col0 ) + cor0.col1 AS col0 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4283
SELECT - col0 DIV 72 col2 FROM tab0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4283
SELECT - col0 / 72 col2 FROM tab0
----
-1
0
0

query I rowsort
SELECT ALL col0 - - 21 AS col1 FROM tab2
----
100
28
99

query I rowsort
SELECT ALL 76 + col0 AS col2 FROM tab1
----
140
156
79

query I rowsort
SELECT ALL - 20 + - 13 * + col0 FROM tab0
----
-1177
-332
-475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 11 + ( + col1 ) + - 38 * tab1.col2 col1 FROM tab1
----
-2015
-2145
-3624

onlyif mysql # use DIV operator for integer division
query I rowsort label-4288
SELECT ALL + ( col1 ) DIV col0 + col1 * col2 AS col2 FROM tab1
----
1248
1412
570

skipif mysql # not compatible
query I rowsort label-4288
SELECT ALL + ( col1 ) / col0 + col1 * col2 AS col2 FROM tab1
----
1248
1412
570

query I rowsort
SELECT col1 * + 35 AS col0 FROM tab2
----
1085
2065
595

query I rowsort
SELECT + col1 + col0 * tab2.col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ( col2 ) * - col0 + - col0 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT + - 56 AS col2 FROM tab1 AS cor0
----
-56

query I rowsort
SELECT DISTINCT cor0.col1 AS col2 FROM tab0, tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL - cor1.col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL + 17 + - 90 * + col1 FROM tab1 AS cor0
----
-1153
-2323
-883

query I rowsort
SELECT ALL - 44 + col1 * - col2 FROM tab0 cor0
----
-141
-2882
-7506

query I rowsort
SELECT ALL - 47 + + 41 FROM tab2
----
-6
-6
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4298
SELECT - 23 DIV - 61 + + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4298
SELECT - 23 / - 61 + + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT - 24 * + 93 * col1 FROM tab2
----
-131688
-37944
-69192

query I rowsort
SELECT + col1 + 48 * 5 AS col2 FROM tab2 AS cor0
----
257
271
299

query I rowsort
SELECT - - col0 + ( + cor0.col0 ) FROM tab0 AS cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 + - 27 * col0 col2 FROM tab2 AS cor0
----
-78
0
869

query I rowsort
SELECT + 89 * col2 * cor0.col1 FROM tab1 cor0
----
111072
124956
50730

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4304
SELECT CAST( NULL AS DECIMAL ) * - 73 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4304
SELECT CAST ( NULL AS REAL ) * - 73 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + cor0.col1 * col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT col0 - col1 * + col0 AS col1 FROM tab2
----
-1264
-210
-4524

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT ALL col1 * col1 - col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT - cor0.col2 * + col2 + + col2 AS col2 FROM tab0 AS cor0
----
-1056
-6642
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4310
SELECT ALL + - col1 DIV col0 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4310
SELECT ALL + - col1 / col0 FROM tab2 cor0
----
-4
0
0

query I rowsort
SELECT 49 + col2 - + ( + ( cor0.col2 ) * col1 + col0 * col0 ) AS col1 FROM tab1 AS cor0
----
-1310
-4560
-7503

onlyif mysql # use DIV operator for integer division
query I rowsort label-4312
SELECT DISTINCT 9 DIV col2 AS col0 FROM tab0
----
0
9

skipif mysql # not compatible
query I rowsort label-4312
SELECT DISTINCT 9 / col2 AS col0 FROM tab0
----
0
9

query I rowsort
SELECT ALL + 2 + cor0.col2 AS col2 FROM tab1 AS cor0
----
56
59
98

query I rowsort
SELECT ALL - 90 FROM tab2
----
-90
-90
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4315
SELECT DISTINCT col0 DIV col1 col1 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4315
SELECT DISTINCT col0 / col1 col1 FROM tab0
----
0

query I rowsort
SELECT - col2 + ( 3 ) * col0 * 6 AS col1 FROM tab1 AS cor0
----
0
1095
1344

query I rowsort
SELECT cor0.col1 * 25 + - 60 - + col2 * + col1 FROM tab0 AS cor0
----
-5247
-748
2268

query I rowsort
SELECT col2 + - 13 * + 10 FROM tab2 AS cor0
----
-103
-104
-92

query I rowsort
SELECT - col2 + 49 * 24 FROM tab0 AS cor0
----
1094
1143
1175

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4320
SELECT col1 * CAST( - 30 AS SIGNED ) FROM tab1 AS cor0
----
-300
-390
-780

skipif mysql # not compatible
query I rowsort label-4320
SELECT col1 * CAST ( - 30 AS INTEGER ) FROM tab1 AS cor0
----
-300
-390
-780

query I rowsort
SELECT + col2 * ( + col1 * col2 ) FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT - col0 + tab0.col2 + col1 FROM tab0
----
63
84
95

query I rowsort
SELECT ALL 97 + + col0 * ( + col2 ) FROM tab2
----
2125
286
3099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4324
SELECT - - col2 + CAST( + col0 AS SIGNED ) * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

skipif mysql # not compatible
query I rowsort label-4324
SELECT - - col2 + CAST ( + col0 AS INTEGER ) * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL + + col1 + + 48 AS col1 FROM tab2 AS cor0
----
107
65
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4326
SELECT + + col2 + - 13 DIV - col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4326
SELECT + + col2 + - 13 / - col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * + col0 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + - col2 + + col1 * - col1 FROM tab1 AS cor0
----
-157
-265
-730

onlyif mysql # use DIV operator for integer division
query I rowsort label-4329
SELECT DISTINCT 21 DIV - cor0.col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4329
SELECT DISTINCT 21 / - cor0.col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - col2 * 8 FROM tab0
----
-264
-656
-8

query I rowsort
SELECT col0 * col0 * - col2 AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT ALL 60 + col2 FROM tab1 AS cor0
----
114
117
156

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4333
SELECT DISTINCT + CAST( + col0 AS SIGNED ) + col1 * cor0.col1 FROM tab2 AS cor0
----
3559
368
968

skipif mysql # not compatible
query I rowsort label-4333
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) + col1 * cor0.col1 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # use DIV operator for integer division
query I rowsort label-4334
SELECT ALL - + 42 + col1 DIV - col0 FROM tab2 AS cor0
----
-42
-42
-46

skipif mysql # not compatible
query I rowsort label-4334
SELECT ALL - + 42 + col1 / - col0 FROM tab2 AS cor0
----
-42
-42
-46

onlyif mysql # use DIV operator for integer division
query I rowsort label-4335
SELECT ALL col2 DIV - col1 - + col1 * col2 AS col0 FROM tab1
----
-1255
-1406
-575

skipif mysql # not compatible
query I rowsort label-4335
SELECT ALL col2 / - col1 - + col1 * col2 AS col0 FROM tab1
----
-1255
-1406
-575

query I rowsort
SELECT ALL cor0.col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4337
SELECT col1 * CAST( ( + col0 ) AS SIGNED ) col0 FROM tab2
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4337
SELECT col1 * CAST ( ( + col0 ) AS INTEGER ) col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT + 19 AS col2 FROM tab0, tab2 cor0, tab2 cor1
----
19

query I rowsort
SELECT ALL - 78 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to b6e4cc21599216686f0cf45b85668b2c

query I rowsort
SELECT + tab1.col1 * col0 AS col2 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4341
SELECT - col0 DIV 14 AS col2 FROM tab1
----
-4
-5
0

skipif mysql # not compatible
query I rowsort label-4341
SELECT - col0 / 14 AS col2 FROM tab1
----
-4
-5
0

query I rowsort
SELECT - col2 + + tab2.col2 * + 80 * + col1 FROM tab2
----
122694
51642
66933

query I rowsort
SELECT + tab2.col2 * 47 AS col1 FROM tab2
----
1222
1269
1786

query I rowsort
SELECT ALL + 23 AS col0 FROM tab0, tab2, tab2 AS cor0, tab1 AS cor1
----
81 values hashing to d3b0357ceadb3a70da7f1649b1ef2a30

query I rowsort
SELECT DISTINCT + col1 + 83 - col0 FROM tab0
----
145
85

query I rowsort
SELECT - - ( cor0.col1 ) * col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + col1 + cor0.col2 - 93 * col0 AS col2 FROM tab2 AS cor0
----
-593
-7169
-7292

query I rowsort
SELECT ALL + 55 * cor0.col1 + 74 FROM tab0 AS cor0
----
4804
5079
5409

query I rowsort
SELECT ALL - cor1.col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4350
SELECT cor0.col0 * + col0 + - CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4350
SELECT cor0.col0 * + col0 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col1 * col0 + ( col2 ) FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL 70 FROM tab0
----
70
70
70

query I rowsort
SELECT DISTINCT + 9 AS col0 FROM tab1, tab0 AS cor0
----
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4354
SELECT DISTINCT - ( col0 + - col0 ) * CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4354
SELECT DISTINCT - ( col0 + - col0 ) * CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL

query I rowsort
SELECT + 51 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT 52 AS col2 FROM tab1
----
52
52
52

query I rowsort
SELECT - + col0 * + col1 * col1 FROM tab0 cor0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-4358
SELECT + + ( cor0.col0 ) DIV col2 col1 FROM tab1 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4358
SELECT + + ( cor0.col0 ) / col2 col1 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL + + col2 + + col0 * col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT + col2 + col1 * - col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + + col2 * col2 + col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT col0 - - col0 * col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT col1 * col1 + col2 * cor0.col0 AS col2 FROM tab1 AS cor0
----
3748
7849
838

query I rowsort
SELECT ALL + col0 - - col0 * col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT - cor0.col2 + col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT + col1 + + col0 * + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-118728
-49450
-720720

query I rowsort
SELECT ALL + col1 * col2 * col2 + col1 FROM tab2 AS cor0
----
22630
24565
39943

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 + + col2 col2 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4369
SELECT - + col0 DIV col0 + - col1 * - col0 FROM tab0 AS cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-4369
SELECT - + col0 / col0 + - col1 * - col0 FROM tab0 AS cor0
----
2063
3394
8098

query I rowsort
SELECT ALL col2 * + col1 + + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL col2 * col0 + + col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT col1 + + col1 * col1 FROM tab0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-4373
SELECT ALL - col0 + - col0 DIV tab0.col0 AS col2 FROM tab0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-4373
SELECT ALL - col0 + - col0 / tab0.col0 AS col2 FROM tab0
----
-25
-36
-90

query I rowsort
SELECT ALL - tab0.col0 + + col1 AS col2 FROM tab0
----
2
62
62

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) IN ( - tab0.col2 * tab0.col1 * - col0 )
----

query IIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0 WHERE NULL NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT + - col2 + col2 * col2 + + col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL + col1 + - col2 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL col1 * col2 + col2 * col0 FROM tab0 AS cor0
----
132
14760
3630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4380
SELECT DISTINCT - cor0.col0 DIV col0 + col0 FROM tab0 cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-4380
SELECT DISTINCT - cor0.col0 / col0 + col0 FROM tab0 cor0
----
23
34
88

query I rowsort
SELECT ALL + col0 + + col2 - + col1 FROM tab2
----
100
3
45

query I rowsort
SELECT - 55 AS col1 FROM tab2 cor0
----
-55
-55
-55

query I rowsort
SELECT + col0 + col0 * col0 AS col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT + ( + col2 ) * cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + 92 - - col1 FROM tab1
----
102
105
118

onlyif mysql # use DIV operator for integer division
query I rowsort label-4386
SELECT + col0 * col1 DIV + col2 FROM tab1
----
1
10
11

skipif mysql # not compatible
query I rowsort label-4386
SELECT + col0 * col1 / + col2 FROM tab1
----
1
10
11

query I rowsort
SELECT - 34 * col1 + col0 FROM tab0
----
-2900
-3005
-3263

query I rowsort
SELECT ALL + + col0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4389
SELECT - col1 DIV + col1 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-4389
SELECT - col1 / + col1 col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col1 + - col0 AS col0 FROM tab0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 + col2 col1 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4392
SELECT - - col2 DIV col2 + + col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-4392
SELECT - - col2 / col2 + + col2 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT DISTINCT col1 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + col2 + - cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL - + col1 - - col1 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + cor0.col1 + + col0 * col2 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + col0 + col2 AS col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - col2 * - col0 + - cor0.col2 * + col0 AS col1 FROM tab0 cor0
----
0

query I rowsort
SELECT col1 + + col2 * col2 FROM tab2 cor0
----
1461
735
760

query I rowsort
SELECT DISTINCT + tab1.col2 * - col1 * - col2 FROM tab1
----
119808
32490
75816

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL >= ( tab1.col1 * + col1 * - col1 )
----

query I rowsort
SELECT col0 + - tab1.col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL col1 * + col2 - - col2 AS col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT DISTINCT tab0.col1 * col1 + - col2 AS col2 FROM tab0
----
7363
8199
9408

query I rowsort
SELECT DISTINCT - tab2.col2 - col1 AS col2 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL - col2 + col1 * - col0 AS col0 FROM tab2
----
-1381
-244
-4628

query I rowsort
SELECT tab0.col1 * col0 + tab0.col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT col0 + - col0 * col2 AS col1 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT ALL tab1.col1 + + tab1.col0 FROM tab1
----
29
74
93

query I rowsort
SELECT - col0 + - col0 FROM tab2 WHERE NOT col2 * + col1 * col0 <= NULL
----

query I rowsort
SELECT DISTINCT - 51 * 75 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
-3825

query I rowsort
SELECT DISTINCT + col0 * col2 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - + 77 * + col2 AS col1 FROM tab2 AS cor0
----
-2002
-2079
-2926

query I rowsort
SELECT DISTINCT ( cor0.col2 ) AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + - col0 + cor0.col1 * col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL + 49 AS col2 FROM tab2 AS cor0
----
49
49
49

query I rowsort
SELECT ALL + + 63 FROM tab1 AS cor0
----
63
63
63

query I rowsort
SELECT ALL col1 * - col2 AS col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - tab0.col0 * - col1 + col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT - col2 + col0 * 98 FROM tab1 AS cor0
----
240
6215
7744

query I rowsort
SELECT + col2 - - tab0.col1 * col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT col2 * col1 + + col1 + col2 AS col2 FROM tab0 AS cor0
----
195
2957
7635

query I rowsort
SELECT - cor0.col2 / + col0 + - col0 * col0 + - cor0.col0 FROM tab0 AS cor0 WHERE NOT col0 NOT BETWEEN NULL AND NULL
----

query IIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT DISTINCT col0 * + col1 + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - col1 AS col0 FROM tab1 cor0 WHERE NULL < NULL
----

query I rowsort
SELECT + col0 * - col0 - col1 FROM tab0
----
-1322
-662
-8012

query I rowsort
SELECT ALL col2 + - col2 * - col1 - + col0 FROM tab1
----
1264
1455
563

onlyif mysql # use DIV operator for integer division
query I rowsort label-4429
SELECT DISTINCT + col0 DIV col2 AS col0 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-4429
SELECT DISTINCT + col0 / col2 AS col0 FROM tab0
----
0
1
35

query I rowsort
SELECT - tab2.col2 + + col2 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * col0 + - col1 + col0 AS col1 FROM tab1
----
-14
4150
6467

onlyif mysql # use DIV operator for integer division
query I rowsort label-4432
SELECT col2 * - col0 DIV - col0 + + col1 AS col1 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-4432
SELECT col2 * - col0 / - col0 + + col1 AS col1 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4433
SELECT ALL - col2 DIV - col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4433
SELECT ALL - col2 / - col1 FROM tab2
----
0
0
2

query I rowsort
SELECT + col0 * col1 * col0 AS col1 FROM tab1
----
234
40960
83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-4435
SELECT ALL col2 DIV col0 AS col2 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-4435
SELECT ALL col2 / col0 AS col2 FROM tab2
----
0
0
3

query I rowsort
SELECT DISTINCT col0 * + col2 + col0 - + col1 FROM tab1
----
139
3702
7747

query I rowsort
SELECT col2 * + col1 * + col0 AS col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT col1 + tab0.col2 * tab0.col2 + col1 AS col2 FROM tab0
----
1261
195
6906

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL NOT IN ( - col1 / + tab2.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4440
SELECT col2 DIV col1 + - 42 FROM tab2 AS cor0
----
-40
-42
-42

skipif mysql # not compatible
query I rowsort label-4440
SELECT col2 / col1 + - 42 FROM tab2 AS cor0
----
-40
-42
-42

query I rowsort
SELECT col1 + - col0 + col1 FROM tab0
----
148
159
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4442
SELECT col0 DIV col2 col0 FROM tab0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4442
SELECT col0 / col2 col0 FROM tab0
----
0
1
35

query I rowsort
SELECT DISTINCT - col0 * - col0 + + col0 * col2 AS col0 FROM tab1
----
14080
171
7744

query I rowsort
SELECT + + cor0.col0 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT - ( col1 ) * - col1 * + col2 FROM tab0
----
244068
679042
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4446
SELECT ALL - CAST( - tab0.col0 AS SIGNED ) FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif mysql # not compatible
query I rowsort label-4446
SELECT ALL - CAST ( - tab0.col0 AS INTEGER ) FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT 37 FROM tab2, tab2 AS cor0, tab2 cor1
----
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4448
SELECT col2 * col1 * CAST( + 64 AS SIGNED ) AS col1 FROM tab1
----
36480
79872
89856

skipif mysql # not compatible
query I rowsort label-4448
SELECT col2 * col1 * CAST ( + 64 AS INTEGER ) AS col1 FROM tab1
----
36480
79872
89856

query I rowsort
SELECT DISTINCT col1 - col2 * - col0 AS col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT 31 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 8 col0 FROM tab1 AS cor0
----
8
8
8

query I rowsort
SELECT ALL tab2.col2 * ( 23 * - tab2.col0 ) AS col1 FROM tab2
----
-4347
-46644
-69046

query I rowsort
SELECT - col1 * ( - col1 * col1 ) FROM tab1 AS cor0
----
1000
17576
2197

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4454
SELECT cor0.col1 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4454
SELECT cor0.col1 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * - ( + col0 ) + col1 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + cor0.col2 * + cor0.col0 col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4457
SELECT + - CAST( NULL AS SIGNED ) * col2 * + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4457
SELECT + - CAST ( NULL AS INTEGER ) * col2 * + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4458
SELECT 5 * 98 DIV - col2 + col0 + 86 * + col2 FROM tab0 AS cor0
----
-369
2848
7136

skipif mysql # not compatible
query I rowsort label-4458
SELECT 5 * 98 / - col2 + col0 + 86 * + col2 FROM tab0 AS cor0
----
-369
2848
7136

query I rowsort
SELECT ALL + col1 + - 82 AS col2 FROM tab2 AS cor0
----
-23
-51
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-4460
SELECT 84 DIV col0 + col0 AS col1 FROM tab2 AS cor0
----
19
79
80

skipif mysql # not compatible
query I rowsort label-4460
SELECT 84 / col0 + col0 AS col1 FROM tab2 AS cor0
----
19
79
80

query I rowsort
SELECT - col2 * cor0.col0 * - col0 AS col1 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - + 64 AS col1 FROM tab2 AS cor0
----
-64
-64
-64

query I rowsort
SELECT DISTINCT tab1.col2 * col2 AS col2 FROM tab1
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4464
SELECT - CAST( - col1 AS SIGNED ) * - cor0.col1 col1 FROM tab2 AS cor0
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4464
SELECT - CAST ( - col1 AS INTEGER ) * - cor0.col1 col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT tab2.col0 * + col2 AS col1 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4466
SELECT DISTINCT - col2 DIV - tab0.col1 col0 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4466
SELECT DISTINCT - col2 / - tab0.col1 col0 FROM tab0
----
0

query I rowsort
SELECT ALL ( 52 ) * - col0 AS col2 FROM tab2
----
-364
-4056
-4108

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 82 - - col0 col2 FROM tab1
----
146
162
85

query I rowsort
SELECT 75 + tab2.col0 FROM tab2
----
153
154
82

query I rowsort
SELECT + 52 * col1 + tab1.col1 FROM tab1
----
1378
530
689

query I rowsort
SELECT + + 28 * + col0 FROM tab1 AS cor0
----
1792
2240
84

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
86
91
97

query I rowsort
SELECT DISTINCT col2 * + 26 AS col1 FROM tab2 AS cor0
----
676
702
988

query I rowsort
SELECT DISTINCT + 82 * cor0.col1 AS col1 FROM tab1 cor0
----
1066
2132
820

query I rowsort
SELECT - 43 FROM tab0, tab1 AS cor0
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

query I rowsort
SELECT ALL col1 * - col2 + + col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT + - col2 * + col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 71 * + col2 + + cor0.col1 - col0 col0 FROM tab2 AS cor0
----
1827
1941
2636

query I rowsort
SELECT - + 17 * + cor0.col2 + - col2 + + col1 AS col1 FROM tab0 AS cor0
----
-1385
-508
79

query I rowsort
SELECT DISTINCT - + 73 FROM tab2 cor0
----
-73

query I rowsort
SELECT + - 79 * - col0 FROM tab1 cor0
----
237
5056
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-4482
SELECT ALL col0 + col0 DIV col1 AS col2 FROM tab2 AS cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-4482
SELECT ALL col0 + col0 / col1 AS col2 FROM tab2 AS cor0
----
7
79
83

query I rowsort
SELECT col2 * col0 + col1 - col1 * - col2 AS col1 FROM tab0 AS cor0
----
14851
229
3716

query I rowsort
SELECT col1 + col0 * col0 AS col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT - + 93 + cor0.col2 - col0 FROM tab2 AS cor0
----
-134
-145
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 92 + + col1 + - col2 col0 FROM tab0 AS cor0
----
-39
-83
4

query I rowsort
SELECT DISTINCT - 78 AS col2 FROM tab1 AS cor0
----
-78

query I rowsort
SELECT ( col2 + tab1.col2 ) FROM tab1
----
108
114
192

query I rowsort
SELECT ALL + 32 + + col2 AS col2 FROM tab1 AS cor0
----
128
86
89

query I rowsort
SELECT ALL + col2 + - col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 * - cor0.col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL col2 * col1 * + col1 AS col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT - - col2 + cor0.col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - col1 + - ( col1 ) AS col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT + 31 FROM tab1
----
31
31
31

query I rowsort
SELECT col2 + + ( col0 ) AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + - col1 * col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - - col0 * - col2 + col2 + - col0 AS col2 FROM tab1 AS cor0
----
-111
-3655
-7664

onlyif mysql # use DIV operator for integer division
query I rowsort label-4499
SELECT ALL + - col1 DIV 99 + col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4499
SELECT ALL + - col1 / 99 + col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 0 col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + col1 + 20 AS col0 FROM tab0 AS cor0
----
106
111
117

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4502
SELECT + + CAST( NULL AS DECIMAL ) * col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4502
SELECT + + CAST ( NULL AS REAL ) * col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab2.col0 + tab2.col1 + 43 FROM tab2
----
139
180
81

query I rowsort
SELECT DISTINCT - - 66 AS col1 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
66

query I rowsort
SELECT - 1 FROM tab1, tab2 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT ALL cor0.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4507
SELECT + col2 + CAST( NULL AS SIGNED ) * + 1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4507
SELECT + col2 + CAST ( NULL AS INTEGER ) * + 1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4508
SELECT ALL + + cor0.col2 * - CAST( NULL AS SIGNED ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4508
SELECT ALL + + cor0.col2 * - CAST ( NULL AS INTEGER ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab0.col0 * + col0 + col0 AS col1 FROM tab0
----
1260
600
8010

query I rowsort
SELECT DISTINCT col2 + col1 * - 52 AS col1 FROM tab0 AS cor0
----
-4439
-4650
-5043

query I rowsort
SELECT ALL - 58 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

query I rowsort
SELECT + + cor0.col2 * + 7 + col0 AS col1 FROM tab2 AS cor0
----
196
260
345

query I rowsort
SELECT DISTINCT + col1 * - ( + 8 ) FROM tab2 AS cor0
----
-136
-248
-472

query I rowsort
SELECT ALL col2 * ( + col0 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + + col2 + + 62 * col2 FROM tab2 AS cor0
----
1638
1701
2394

query I rowsort
SELECT ALL - cor0.col2 * 28 AS col2 FROM tab0 AS cor0
----
-2296
-28
-924

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - + ( + cor0.col0 ) * + cor0.col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - col2 + - cor0.col1 * cor0.col2 FROM tab2 AS cor0
----
-1560
-684
-864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4520
SELECT + CAST( NULL AS SIGNED ) * - col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4520
SELECT + CAST ( NULL AS INTEGER ) * - col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col2 + ( col2 ) * + col0 FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT + ( 51 ) FROM tab2 AS cor0
----
51
51
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4523
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * - col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4523
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * - col0 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL ( col1 ) + - cor0.col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - 2 + + col1 * cor0.col0 FROM tab0 cor0
----
2062
3393
8097

query I rowsort
SELECT ALL + - 43 AS col0 FROM tab1 AS cor0
----
-43
-43
-43

query I rowsort
SELECT + 85 * - col2 * - col1 FROM tab1 cor0
----
106080
119340
48450

query I rowsort
SELECT ALL tab0.col1 + ( col1 ) + - col2 * col2 AS col0 FROM tab0
----
-6542
-917
193

query I rowsort
SELECT DISTINCT 8 FROM tab1, tab0 cor0
----
8

query I rowsort
SELECT DISTINCT col1 + + col2 * 83 FROM tab1 AS cor0
----
4508
4741
7981

query I rowsort
SELECT DISTINCT - - 67 + col0 AS col0 FROM tab2 AS cor0
----
145
146
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-4532
SELECT ALL cor0.col0 DIV col0 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-4532
SELECT ALL cor0.col0 / col0 col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL 98 + - col0 AS col1 FROM tab2 cor0
----
19
20
91

query I rowsort
SELECT DISTINCT + - cor0.col0 + + col2 AS col1 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col1 + + ( + 4 * + col2 ) col1 FROM tab1 AS cor0
----
-460
128
215

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4536
SELECT DISTINCT + col0 * - col2 * ( - col1 ) + cor0.col2 + CAST( 95 AS SIGNED ) FROM tab2 cor0
----
119773
51167
5981

skipif mysql # not compatible
query I rowsort label-4536
SELECT DISTINCT + col0 * - col2 * ( - col1 ) + cor0.col2 + CAST ( 95 AS INTEGER ) FROM tab2 cor0
----
119773
51167
5981

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 96 col1 FROM tab2 cor0
----
-96
-96
-96

query I rowsort
SELECT ALL + 10 * cor0.col2 - 5 AS col2 FROM tab0 AS cor0
----
325
5
815

query I rowsort
SELECT - col1 + ( + col1 ) * + col2 AS col0 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT - col1 - col1 AS col0 FROM tab2
----
-118
-34
-62

query I rowsort
SELECT DISTINCT 41 + - col0 - + 27 FROM tab2
----
-64
-65
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4542
SELECT col0 DIV tab1.col1 AS col0 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-4542
SELECT col0 / tab1.col1 AS col0 FROM tab1
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 - + col1 col2 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT + cor0.col2 * col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4545
SELECT DISTINCT + 45 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4545
SELECT DISTINCT + 45 / cor0.col2 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - + 98 + col1 FROM tab0 AS cor0
----
-1
-12
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4547
SELECT ALL + col0 + - col1 DIV col2 + + 23 FROM tab1 AS cor0
----
103
26
87

skipif mysql # not compatible
query I rowsort label-4547
SELECT ALL + col0 + - col1 / col2 + + 23 FROM tab1 AS cor0
----
103
26
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4548
SELECT - 91 + - col2 DIV CAST( + 62 + col2 AS SIGNED ) AS col1 FROM tab1
----
-91
-91
-91

skipif mysql # not compatible
query I rowsort label-4548
SELECT - 91 + - col2 / CAST ( + 62 + col2 AS INTEGER ) AS col1 FROM tab1
----
-91
-91
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 - ( - col1 ) col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT + 87 AS col0 FROM tab0
----
87

query I rowsort
SELECT ALL 32 * + col1 FROM tab0
----
2752
2912
3104

query I rowsort
SELECT + 18 FROM tab1
----
18
18
18

query I rowsort
SELECT DISTINCT + col0 + + 40 * + col2 FROM tab1
----
2163
2344
3920

onlyif mysql # use DIV operator for integer division
query I rowsort label-4554
SELECT - + col0 * 45 DIV - col1 + col1 * - 18 col1 FROM tab2 AS cor0
----
-1003
-548
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4554
SELECT - + col0 * 45 / - col1 + col1 * - 18 col1 FROM tab2 AS cor0
----
-1003
-548
-97

query I rowsort
SELECT - col1 * col1 - + col2 AS col2 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT ALL col0 * 47 FROM tab0 AS cor0
----
1128
1645
4183

onlyif mysql # use DIV operator for integer division
query I rowsort label-4557
SELECT DISTINCT + cor0.col0 * col2 DIV - ( + col1 * 59 ) + - col2 AS col2 FROM tab1 AS cor0
----
-106
-54
-63

skipif mysql # not compatible
query I rowsort label-4557
SELECT DISTINCT + cor0.col0 * col2 / - ( + col1 * 59 ) + - col2 AS col2 FROM tab1 AS cor0
----
-106
-54
-63

query I rowsort
SELECT + col2 * col1 * 33 - col2 AS col2 FROM tab1 cor0
----
18753
41088
46278

query I rowsort
SELECT DISTINCT col2 * 55 FROM tab1 AS cor0
----
2970
3135
5280

query I rowsort
SELECT - 24 + 21 FROM tab2
----
-3
-3
-3

query I rowsort
SELECT DISTINCT 12 + 62 * - col1 FROM tab2 AS cor0
----
-1042
-1910
-3646

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) - cor0.col1 * - col1 AS col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + 85 + col1 FROM tab0 cor0
----
171
176
182

query I rowsort
SELECT ALL + - 13 - + 27 * - col2 FROM tab0 cor0
----
14
2201
878

query I rowsort
SELECT + 9 * - 2 + + col1 FROM tab0 AS cor0
----
68
73
79

query I rowsort
SELECT DISTINCT - + ( + 8 ) AS col0 FROM tab2 AS cor0
----
-8

query I rowsort
SELECT DISTINCT tab1.col2 AS col1 FROM tab1, tab0 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 3 + + col2 col0 FROM tab0 AS cor0
----
36
4
85

query I rowsort
SELECT + - ( + col0 ) + - col0 AS col2 FROM tab2 cor0
----
-14
-156
-158

query I rowsort
SELECT DISTINCT + + ( - col0 ) - cor0.col1 FROM tab0 AS cor0
----
-110
-132
-180

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 4805bcb9c04e49d1f6f82defa880d751

query I rowsort
SELECT DISTINCT - col0 - + col1 * col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT + col2 * col1 * col1 FROM tab1 AS cor0
----
16224
36504
5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 34 * + col1 col2 FROM tab0 AS cor0
----
2924
3094
3298

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - col2 * + col0 col0 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT + - col0 + cor0.col0 * 22 FROM tab1 AS cor0
----
1344
1680
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4577
SELECT ALL - - col0 + + cor0.col1 DIV ( col0 ) FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-4577
SELECT ALL - - col0 + + cor0.col1 / ( col0 ) FROM tab0 AS cor0
----
27
37
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4578
SELECT 99 DIV - cor0.col2 FROM tab0 AS cor0
----
-1
-3
-99

skipif mysql # not compatible
query I rowsort label-4578
SELECT 99 / - cor0.col2 FROM tab0 AS cor0
----
-1
-3
-99

query I rowsort
SELECT - + col2 * - ( col0 ) FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4580
SELECT DISTINCT + + 82 DIV col0 FROM tab0 AS cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-4580
SELECT DISTINCT + + 82 / col0 FROM tab0 AS cor0
----
0
2
3

query I rowsort
SELECT ALL + ( ( col2 ) ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + col0 * - col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL col0 * 51 FROM tab2 AS cor0
----
357
3978
4029

query I rowsort
SELECT - col2 * - 25 FROM tab1 cor0
----
1350
1425
2400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4585
SELECT - CAST( - 56 AS SIGNED ) col0 FROM tab2 AS cor0
----
56
56
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4585
SELECT - CAST ( - 56 AS INTEGER ) col0 FROM tab2 AS cor0
----
56
56
56

query I rowsort
SELECT - col1 * col1 + - col2 AS col1 FROM tab0 cor0
----
-7429
-8363
-9410

query I rowsort
SELECT ALL + cor0.col2 + - col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT 63 * - col1 FROM tab2 AS cor0
----
-1071
-1953
-3717

onlyif mysql # use DIV operator for integer division
query I rowsort label-4589
SELECT - col1 * col1 DIV + col0 AS col1 FROM tab0
----
-268
-308
-93

skipif mysql # not compatible
query I rowsort label-4589
SELECT - col1 * col1 / + col0 AS col1 FROM tab0
----
-268
-308
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4590
SELECT + tab1.col1 DIV + tab1.col1 col0 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4590
SELECT + tab1.col1 / + tab1.col1 col0 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL + 83 * - col2 FROM tab0 AS cor0
----
-2739
-6806
-83

query I rowsort
SELECT DISTINCT + cor1.col2 * 63 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
2079
5166
63

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab0 cor1
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

query I rowsort
SELECT ALL + ( ( - col2 ) ) * col2 * 28 AS col2 FROM tab2
----
-18928
-20412
-40432

query I rowsort
SELECT ALL 6 FROM tab2, tab1 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT - + col0 * col2 * col2 + + col0 AS col0 FROM tab1 cor0
----
-207872
-737200
-8745

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor1.col0 col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT + + col2 + - ( col1 ) AS col0 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4599
SELECT - col1 * CAST( NULL AS SIGNED ) + + 58 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4599
SELECT - col1 * CAST ( NULL AS INTEGER ) + + 58 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4600
SELECT + - 63 DIV 26 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

skipif mysql # not compatible
query I rowsort label-4600
SELECT + - 63 / 26 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT + 70 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

onlyif mysql # use DIV operator for integer division
query I rowsort label-4602
SELECT + col1 + col0 DIV - 7 FROM tab2 AS cor0
----
30
48
6

skipif mysql # not compatible
query I rowsort label-4602
SELECT + col1 + col0 / - 7 FROM tab2 AS cor0
----
30
48
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4603
SELECT - col0 DIV cor0.col2 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4603
SELECT - col0 / cor0.col2 FROM tab1 cor0
----
-1
0
0

query I rowsort
SELECT 22 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT DISTINCT - - 26 FROM tab0 AS cor0
----
26

query I rowsort
SELECT DISTINCT col2 * - 98 + + 5 FROM tab2
----
-2543
-2641
-3719

query I rowsort
SELECT - tab1.col0 - 66 AS col1 FROM tab1
----
-130
-146
-69

query I rowsort
SELECT tab1.col2 + - tab1.col0 * tab1.col1 AS col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT + 43 * + cor0.col1 FROM tab2 AS cor0
----
1333
2537
731

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4610
SELECT CAST( + col1 AS SIGNED ) - + col0 FROM tab2
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-4610
SELECT CAST ( + col1 AS INTEGER ) - + col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL - - 56 * + cor0.col1 FROM tab1, tab2, tab1 AS cor0, tab0
----
81 values hashing to 3fac07d34dc5bc853a73f9f0d260940b

query I rowsort
SELECT ALL - - cor0.col0 + cor0.col1 AS col1 FROM tab2 cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4613
SELECT - CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-4613
SELECT - CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT DISTINCT - ( - 5 ) + col1 AS col2 FROM tab1 AS cor0
----
15
18
31

query I rowsort
SELECT ALL + col1 * - 78 AS col0 FROM tab1 AS cor0
----
-1014
-2028
-780

query I rowsort
SELECT ALL + col1 * + col2 + - col2 * col2 * + cor0.col2 FROM tab2 cor0
----
-16042
-18846
-54226

query I rowsort
SELECT ALL 54 + col2 * - col2 - 25 FROM tab1 AS cor0
----
-2887
-3220
-9187

query I rowsort
SELECT DISTINCT + tab2.col2 - - col0 AS col1 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT - col0 - tab1.col2 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT col2 * col0 + - 28 FROM tab0
----
7
7270
764

query I rowsort
SELECT DISTINCT ( col2 * + ( col1 ) ) FROM tab2
----
1534
646
837

query I rowsort
SELECT 26 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

onlyif mysql # use DIV operator for integer division
query I rowsort label-4623
SELECT + ( - cor0.col1 ) DIV - 85 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4623
SELECT + ( - cor0.col1 ) / - 85 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 * - ( ( col0 ) ) + 98 AS col2 FROM tab0 cor0
----
1323
674
8019

query I rowsort
SELECT DISTINCT + + col2 * col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL col2 + - 61 AS col0 FROM tab0 AS cor0
----
-28
-60
21

skipif mysql # not compatible
query I rowsort
SELECT col2 * + CAST ( - col1 AS REAL ) + + col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4628
SELECT DISTINCT - + col2 DIV + col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-4628
SELECT DISTINCT - + col2 / + col0 FROM tab2 AS cor0
----
-3
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4629
SELECT - cor0.col2 DIV 74 AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4629
SELECT - cor0.col2 / 74 AS col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - col0 + - 24 AS col1 FROM tab1 AS cor0
----
-104
-27
-88

query I rowsort
SELECT DISTINCT - + col2 * col0 + - col0 FROM tab0 cor0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col2 * 28 col0 FROM tab0 AS cor0
----
-2296
-28
-924

skipif mysql # not compatible
query I rowsort
SELECT ALL - ( + col2 ) * col2 + - CAST ( + col0 + col1 AS REAL ) AS col2 FROM tab2
----
-1540
-767
-813

query I rowsort
SELECT col2 + col2 * col2 + 54 AS col2 FROM tab0
----
1176
56
6860

query I rowsort
SELECT DISTINCT + cor0.col0 * + col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4636
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4636
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col1 + - 95 AS col1 FROM tab2 AS cor0
----
-36
-64
-78

query I rowsort
SELECT ALL + - 49 - col1 AS col1 FROM tab2 AS cor0
----
-108
-66
-80

query I rowsort
SELECT ALL + col1 - + 28 AS col0 FROM tab0 AS cor0
----
58
63
69

query I rowsort
SELECT ALL + - 15 * - col2 FROM tab0 cor0
----
1230
15
495

query I rowsort
SELECT ALL - + 95 FROM tab0 AS cor0
----
-95
-95
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 51 col0 FROM tab0 AS cor0
----
-51
-51
-51

query I rowsort
SELECT - col1 * + col0 + + ( col2 ) * + col1 FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT ALL - col2 * + col1 * - 2 AS col1 FROM tab0 AS cor0
----
14924
194
5676

query I rowsort
SELECT ALL - - col0 * + cor0.col1 AS col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT 84 * - col2 * + 6 + col2 AS col2 FROM tab0 AS cor0
----
-16599
-41246
-503

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - col2 + + cor0.col0 * - 91 col2 FROM tab1 AS cor0
----
-16496
-3189
-9073

query I rowsort
SELECT col0 * - col2 - ( col1 ) * col2 AS col0 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT - cor0.col1 + col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - 81 * - 2 FROM tab0
----
162
162
162

query I rowsort
SELECT 41 - - 70 FROM tab2
----
111
111
111

query I rowsort
SELECT ALL - ( col2 ) - - col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - 34 * + col0 FROM tab0 AS cor0
----
-1190
-3026
-816

query I rowsort
SELECT + 88 * col2 + - col2 AS col2 FROM tab2 AS cor0
----
2262
2349
3306

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col1 ) * ( col2 ) col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + + col0 * col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - + 86 + + cor0.col0 * - 9 * + 12 AS col0 FROM tab0 AS cor0
----
-2678
-3866
-9698

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4658
SELECT DISTINCT - col1 * col2 * - CAST( NULL AS SIGNED ) + - cor0.col0 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4658
SELECT DISTINCT - col1 * col2 * - CAST ( NULL AS INTEGER ) + - cor0.col0 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 * - col1 * cor0.col1 FROM tab2 cor0
----
10982
25947
90506

query I rowsort
SELECT ALL + + col0 + 55 + col1 AS col2 FROM tab1 AS cor0
----
129
148
84

query I rowsort
SELECT ALL col0 + - col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4662
SELECT - col1 + col1 DIV - col0 FROM tab2 AS cor0
----
-17
-35
-59

skipif mysql # not compatible
query I rowsort label-4662
SELECT - col1 + col1 / - col0 FROM tab2 AS cor0
----
-17
-35
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL col0 * 61 AS col0 FROM tab0 AS cor0
----
1464
2135
5429

onlyif mysql # use DIV operator for integer division
query I rowsort label-4665
SELECT DISTINCT + col0 DIV + 61 AS col0 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-4665
SELECT DISTINCT + col0 / + 61 AS col0 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT + cor0.col2 + cor0.col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4667
SELECT + - col0 + col1 / col1 + col0 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4667
SELECT + - col0 + col1 / 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-4668
SELECT - - col2 DIV + col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4668
SELECT - - col2 / + col2 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col1 col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * + col1 + col0 col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT - + col1 + ( - col1 * col0 ) AS col0 FROM tab0 cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL - - col1 + 56 * 11 FROM tab2 AS cor0
----
633
647
675

onlyif mysql # use DIV operator for integer division
query I rowsort label-4673
SELECT cor0.col0 DIV - col1 FROM tab1 cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-4673
SELECT cor0.col0 / - col1 FROM tab1 cor0
----
-6
-6
0

query I rowsort
SELECT ALL + 16 FROM tab2 AS cor0
----
16
16
16

query I rowsort
SELECT DISTINCT - + 18 * ( - col2 ) + - cor0.col1 AS col0 FROM tab2 AS cor0
----
409
455
667

query I rowsort
SELECT ALL col2 * + ( - 12 ) FROM tab2
----
-312
-324
-456

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 * ( col2 * col1 ) col2 FROM tab2 AS cor0
----
10982
25947
90506

query IIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab1, tab2 cor1
----
243 values hashing to ea21cea53be47edd19229592e3d26141

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4679
SELECT ALL col2 * CAST( NULL AS SIGNED ) * + 1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4679
SELECT ALL col2 * CAST ( NULL AS INTEGER ) * + 1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - + ( col2 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + + cor0.col0 * col2 + + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL - 3 AS col2 FROM tab0 AS cor0
----
-3
-3
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4683
SELECT DISTINCT - CAST( col0 AS SIGNED ) + - col1 * col1 AS col0 FROM tab1 AS cor0
----
-164
-249
-679

skipif mysql # not compatible
query I rowsort label-4683
SELECT DISTINCT - CAST ( col0 AS INTEGER ) + - col1 * col1 AS col0 FROM tab1 AS cor0
----
-164
-249
-679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4684
SELECT ALL + CAST( col2 AS SIGNED ) + col2 * + col2 * col2 FROM tab1 AS cor0
----
157518
185250
884832

skipif mysql # not compatible
query I rowsort label-4684
SELECT ALL + CAST ( col2 AS INTEGER ) + col2 * + col2 * col2 FROM tab1 AS cor0
----
157518
185250
884832

query I rowsort
SELECT - 57 AS col1 FROM tab0 AS cor0
----
-57
-57
-57

query I rowsort
SELECT - 95 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to cf302b83f15b730fe35c19bdd9363c13

query I rowsort
SELECT col2 + - ( + 90 + - col1 * + ( 2 ) ) FROM tab1
----
-13
16
32

query IIIIIIIII rowsort
SELECT * FROM tab1, tab2, tab1 AS cor0 WHERE tab1.col1 = NULL
----

query I rowsort
SELECT + ( + 34 ) FROM tab2 AS cor0
----
34
34
34

query I rowsort
SELECT 12 + + col0 * col1 * col2 FROM tab1
----
36492
4224
99852

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col1 AS REAL ) AS col2 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4692
SELECT - 42 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4692
SELECT - 42 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 93 FROM tab2 AS cor0
----
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 55 * - col2 col2 FROM tab0 AS cor0
----
-1815
-4510
-55

query I rowsort
SELECT ALL - 54 + + cor0.col0 FROM tab2 AS cor0
----
-47
24
25

query I rowsort
SELECT + + col2 + - col1 * - col0 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4697
SELECT + + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4697
SELECT + + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT 14 * col2 + + 84 * - col1 AS col1 FROM tab2
----
-2226
-4592
-896

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4699
SELECT + col0 + + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4699
SELECT + col0 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 17 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4701
SELECT - cor0.col2 DIV - 96 + + col2 FROM tab1 AS cor0
----
54
57
97

skipif mysql # not compatible
query I rowsort label-4701
SELECT - cor0.col2 / - 96 + + col2 FROM tab1 AS cor0
----
54
57
97

query I rowsort
SELECT DISTINCT - col0 + + col2 AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT - 43 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col0 col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # use DIV operator for integer division
query I rowsort label-4705
SELECT DISTINCT 1 DIV 80 AS col0 FROM tab0, tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4705
SELECT DISTINCT 1 / 80 AS col0 FROM tab0, tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4706
SELECT ALL - col2 * + CAST( NULL AS SIGNED ) + + 60 * + col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4706
SELECT ALL - col2 * + CAST ( NULL AS INTEGER ) + + 60 * + col1 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4707
SELECT ALL - - col2 DIV cor0.col2 + - col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-4707
SELECT ALL - - col2 / cor0.col2 + - col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4708
SELECT DISTINCT - col2 DIV - 44 + 89 DIV - cor0.col2 FROM tab1 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-4708
SELECT DISTINCT - col2 / - 44 + 89 / - cor0.col2 FROM tab1 AS cor0
----
0
2

query I rowsort
SELECT DISTINCT 2 FROM tab2, tab0 AS cor0
----
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4710
SELECT DISTINCT col0 + - CAST( 97 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-62
-73
-8

skipif mysql # not compatible
query I rowsort label-4710
SELECT DISTINCT col0 + - CAST ( 97 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-62
-73
-8

query I rowsort
SELECT - col0 + 82 FROM tab2 AS cor0
----
3
4
75

query I rowsort
SELECT DISTINCT 72 * col0 FROM tab2
----
504
5616
5688

query I rowsort
SELECT - 76 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

onlyif mysql # use DIV operator for integer division
query I rowsort label-4714
SELECT - 21 - + col0 DIV col0 AS col1 FROM tab1
----
-22
-22
-22

skipif mysql # not compatible
query I rowsort label-4714
SELECT - 21 - + col0 / col0 AS col1 FROM tab1
----
-22
-22
-22

query I rowsort
SELECT + tab0.col2 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT DISTINCT - ( 41 ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-41

query I rowsort
SELECT ALL + 99 * - col1 FROM tab0
----
-8514
-9009
-9603

query I rowsort
SELECT - 14 + col0 FROM tab0 AS cor0
----
10
21
75

query I rowsort
SELECT + + ( col1 ) * + col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT col0 + col1 + - col0 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + col0 + + cor0.col1 * + ( col2 ) * + cor0.col2 FROM tab2 AS cor0
----
22606
24627
39962

onlyif mysql # use DIV operator for integer division
query I rowsort label-4722
SELECT - + cor0.col1 DIV col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-4722
SELECT - + cor0.col1 / col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT + - col1 + + col2 * - cor0.col0 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT ALL + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4725
SELECT DISTINCT cor0.col1 * - CAST( NULL AS DECIMAL ) + - col1 + col1 * col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4725
SELECT DISTINCT cor0.col1 * - CAST ( NULL AS REAL ) + - col1 + col1 * col0 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4726
SELECT ALL - col0 + - ( - col2 ) DIV + col2 AS col1 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4726
SELECT ALL - col0 + - ( - col2 ) / + col2 AS col1 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT + 34 * 93 AS col2 FROM tab1 AS cor0
----
3162
3162
3162

query I rowsort
SELECT - 85 * col0 FROM tab2 AS cor0
----
-595
-6630
-6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-4729
SELECT + col1 * col0 DIV cor0.col0 + ( col0 ) FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-4729
SELECT + col1 * col0 / cor0.col0 + ( col0 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - col2 * - 30 + + col1 FROM tab1
----
1646
1720
2893

query I rowsort
SELECT 8 * - col1 + - tab2.col1 AS col0 FROM tab2
----
-153
-279
-531

query I rowsort
SELECT - + col2 + + col0 * 44 FROM tab2 AS cor0
----
281
3406
3438

query I rowsort
SELECT - col1 + + col2 + col1 FROM tab2 cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4734
SELECT DISTINCT CAST( - col2 AS SIGNED ) AS col0 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4734
SELECT DISTINCT CAST ( - col2 AS INTEGER ) AS col0 FROM tab1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4735
SELECT ALL 31 DIV + col1 FROM tab2
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4735
SELECT ALL 31 / + col1 FROM tab2
----
0
1
1

query I rowsort
SELECT - col0 * 70 FROM tab2
----
-490
-5460
-5530

query I rowsort
SELECT ALL + ( 42 ) * tab2.col0 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to e7a91cd463a69ac57990acb41bbfc730

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4738
SELECT CAST( NULL AS DECIMAL ) * - col2 * - col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4738
SELECT CAST ( NULL AS REAL ) * - col2 * - col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 * col2 col1 FROM tab2
----
1092
1134
1596

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
-1
-33
-82

query I rowsort
SELECT ALL + col2 * + col1 + ( + ( col2 ) ) * + 96 AS col2 FROM tab1 AS cor0
----
10464
6042
6588

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col0 col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + 11 * - col2 + 7 FROM tab2 cor0
----
-279
-290
-411

query I rowsort
SELECT DISTINCT - cor0.col1 AS col1 FROM tab0, tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT 89 FROM tab2, tab1 cor0
----
89

query I rowsort
SELECT DISTINCT 37 * col1 + - col2 AS col0 FROM tab0 AS cor0
----
3149
3285
3588

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab1 AS cor1, tab1 cor2
----
972 values hashing to 0be13143d898cc667fe1a2dd93b34703

query I rowsort
SELECT + - col1 * - cor0.col1 * 76 + - 58 FROM tab2 AS cor0
----
21906
264498
72978

query I rowsort
SELECT ALL 48 * - col0 FROM tab1 AS cor0
----
-144
-3072
-3840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 39 + - col1 col1 FROM tab2
----
-56
-70
-98

query I rowsort
SELECT ALL col1 * col0 * col0 + - col1 * col2 FROM tab0
----
118728
46698
713349

query I rowsort
SELECT - 96 AS col1 FROM tab0, tab0 AS cor0, tab2 cor1, tab2 cor2
----
81 values hashing to 5c66f1deb3d2ed61020ac982642dd7b2

query I rowsort
SELECT + cor0.col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL col1 * col0 + col0 + + col0 * + col0 AS col0 FROM tab1
----
4800
7520
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4755
SELECT ALL - col0 * - CAST( - 88 * tab1.col2 AS SIGNED ) col2 FROM tab1
----
-14256
-321024
-675840

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4755
SELECT ALL - col0 * - CAST ( - 88 * tab1.col2 AS INTEGER ) col2 FROM tab1
----
-14256
-321024
-675840

query I rowsort
SELECT DISTINCT - col1 * - ( - col1 ) AS col1 FROM tab1
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4757
SELECT - CAST( + col2 AS SIGNED ) + col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4757
SELECT - CAST ( + col2 AS INTEGER ) + col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 80 - + 47 AS col0 FROM tab0 AS cor0
----
-127
-127
-127

onlyif mysql # use DIV operator for integer division
query I rowsort label-4759
SELECT DISTINCT + 57 * - col0 + col1 DIV + cor0.col2 + - col2 * col2 * + col0 AS col2 FROM tab1 AS cor0
----
-211584
-741840
-8919

skipif mysql # not compatible
query I rowsort label-4759
SELECT DISTINCT + 57 * - col0 + col1 / + cor0.col2 + - col2 * col2 * + col0 AS col2 FROM tab1 AS cor0
----
-211584
-741840
-8919

query I rowsort
SELECT ALL ( cor0.col2 ) FROM tab2, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT col2 - 12 AS col0 FROM tab2
----
14
15
26

query I rowsort
SELECT + col2 + + col0 * ( col0 ) FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT 6 * tab1.col1 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 0481a09faeb522b0e8329193c1c64a7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4764
SELECT - CAST( col0 AS SIGNED ) - col1 AS col0 FROM tab1 cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-4764
SELECT - CAST ( col0 AS INTEGER ) - col1 AS col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + col1 * 57 + col0 FROM tab0 AS cor0
----
4926
5276
5564

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 99 * - ( cor0.col1 ) col1 FROM tab1 AS cor0
----
-1287
-2574
-990

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * col0 * col2 + col0 AS col0 FROM tab0 cor0
----
3430
664207
68136

query I rowsort
SELECT ALL + ( - cor0.col0 ) * + col0 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ( col0 ) * col1 - cor0.col2 * 0 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + + 54 * - col2 + col1 * + 79 + col0 FROM tab1 AS cor0
----
-2224
-4077
-859

query I rowsort
SELECT ( - col1 ) - col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + 16 + - col1 AS col0 FROM tab0 cor0
----
-70
-75
-81

query I rowsort
SELECT DISTINCT - 15 + 26 AS col2 FROM tab0 AS cor0
----
11

query I rowsort
SELECT - col2 * 44 - cor0.col0 AS col1 FROM tab1 AS cor0
----
-2379
-2572
-4304

query I rowsort
SELECT col1 + col1 + cor0.col1 FROM tab0 AS cor0
----
258
273
291

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col1 + col0 col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - col1 + - cor0.col0 * + col2 AS col2 FROM tab0 AS cor0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 98 col0 FROM tab2
----
-98
-98
-98

query I rowsort
SELECT col1 * - col2 + - col0 * tab2.col2 AS col2 FROM tab2
----
-1026
-3562
-3648

query I rowsort
SELECT + tab0.col0 + - col1 AS col0 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT tab0.col0 + col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT - tab2.col1 + - col2 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT col0 * tab1.col0 + col0 * col2 AS col2 FROM tab1
----
14080
171
7744

query I rowsort
SELECT DISTINCT tab0.col1 * + col0 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col0 col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - col2 * + col2 * + col2 + col1 AS col2 FROM tab1
----
-157438
-185183
-884723

query I rowsort
SELECT ALL 54 * col1 + + col1 * col2 AS col0 FROM tab2
----
1564
2511
4720

query I rowsort
SELECT DISTINCT + 7 FROM tab0, tab0 cor0
----
7

query I rowsort
SELECT DISTINCT + 57 + col0 AS col1 FROM tab0
----
146
81
92

query I rowsort
SELECT DISTINCT - 6 + + 45 FROM tab1
----
39

query I rowsort
SELECT + col0 * 15 * col0 + col1 FROM tab1
----
161
61450
96013

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4792
SELECT ALL CAST( NULL AS DECIMAL ) + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4792
SELECT ALL CAST ( NULL AS REAL ) + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + col1 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ( + col2 ) + + col2 AS col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + cor0.col1 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col2 * + 11 * col1 FROM tab0 AS cor0
----
1067
31218
82082

query I rowsort
SELECT ALL ( + 85 ) + - col2 * - col2 AS col1 FROM tab2
----
1529
761
814

query I rowsort
SELECT DISTINCT 6 FROM tab2, tab1 cor0
----
6

query I rowsort
SELECT + 74 AS col2 FROM tab1 AS cor0
----
74
74
74

query I rowsort
SELECT DISTINCT col0 * col2 - + col2 AS col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT + - cor0.col0 * col2 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - + 68 FROM tab1 AS cor0
----
-68
-68
-68

query I rowsort
SELECT col0 * col0 + + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-788
4550
5595

query I rowsort
SELECT DISTINCT - - 95 + + col1 + col2 AS col1 FROM tab2 AS cor0
----
150
153
180

query I rowsort
SELECT + cor0.col1 * col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL ( cor0.col0 ) * col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + ( + col0 * + col1 ) AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT - col0 * + tab1.col2 FROM tab1 WHERE NOT ( NULL NOT BETWEEN + col0 * col0 * col2 AND ( col0 * - col2 * - col0 ) ) AND NULL NOT IN ( col2 )
----

query I rowsort
SELECT ALL + + col0 * + col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - ( - col1 ) + - col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col2 + + col0 col1 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT - cor0.col2 * col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL col0 * cor0.col1 - + col2 AS col0 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT col0 * col2 * + col2 AS col2 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT ALL + ( col2 ) * col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + cor0.col0 * col1 AS col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT col2 - + tab0.col0 * tab0.col0 AS col0 FROM tab0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col2 + tab1.col1 col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT col0 * col0 AS col2 FROM tab1 AS cor0 WHERE ( NULL ) IN ( - col2 )
----

query I rowsort
SELECT ALL - col0 + col2 FROM tab1 AS cor0 WHERE NOT ( NULL ) NOT BETWEEN ( - col1 - + col1 ) AND col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4821
SELECT - col0 * - col0 DIV col0 + + col0 + col1 * col2 FROM tab1 AS cor0
----
1408
1410
698

skipif mysql # not compatible
query I rowsort label-4821
SELECT - col0 * - col0 / col0 + + col0 + col1 * col2 FROM tab1 AS cor0
----
1408
1410
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-4822
SELECT + col2 + - tab0.col2 DIV + col2 AS col0 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-4822
SELECT + col2 + - tab0.col2 / + col2 AS col0 FROM tab0
----
0
32
81

query I rowsort
SELECT DISTINCT tab2.col2 + + col2 * + col2 AS col1 FROM tab2
----
1482
702
756

query I rowsort
SELECT DISTINCT col1 + col1 * col2 * + col1 FROM tab2
----
10999
25978
90565

query III rowsort
SELECT * FROM tab0 WHERE col2 = ( NULL )
----

query I rowsort
SELECT ALL col0 + + tab2.col1 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4827
SELECT tab1.col1 DIV + col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4827
SELECT tab1.col1 / + col2 FROM tab1
----
0
0
0

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 >= NULL
----

query I rowsort
SELECT + col1 * + col0 * tab2.col1 + + col0 FROM tab2
----
22910
271596
6734

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE - col0 NOT BETWEEN NULL AND col0 * col2 + col1
----

query I rowsort
SELECT DISTINCT + col1 + - col0 AS col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT col0 AS col1 FROM tab2 WHERE NULL BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT tab0.col1 - + col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col0 + col2 AS col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT - col2 FROM tab0 WHERE NULL IN ( - col1 * col2 )
----

query I rowsort
SELECT DISTINCT - col1 * + col1 * col0 + col2 FROM tab0
----
-177471
-329314
-736927

query I rowsort
SELECT + - col1 + col2 - - col0 * col1 AS col1 FROM tab1 AS cor0
----
106
1123
687

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - col1 * col2 col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + + col2 + cor0.col2 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4840
SELECT ALL + col2 DIV - col0 AS col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-4840
SELECT ALL + col2 / - col0 AS col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT - - col2 * col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col0 col2 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col1 - col2 col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT - col0 + col1 AS col2 FROM tab0 cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4845
SELECT DISTINCT - col0 DIV - col0 - col1 AS col2 FROM tab2
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-4845
SELECT DISTINCT - col0 / - col0 - col1 AS col2 FROM tab2
----
-16
-30
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col2 * + col2 - - col1 * tab1.col1 col0 FROM tab1
----
3349
3592
9385

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) <= NULL
----

query I rowsort
SELECT DISTINCT + col2 + col1 + + col0 FROM tab2
----
134
163
65

query I rowsort
SELECT ALL - col1 * col2 + col2 + + col2 FROM tab1
----
-1056
-1296
-456

query I rowsort
SELECT - tab1.col0 * - col2 * col2 + - col0 AS col1 FROM tab1
----
207872
737200
8745

query III rowsort
SELECT * FROM tab2 WHERE col0 / col1 <> NULL
----

query I rowsort
SELECT col0 * col2 + - col1 AS col1 FROM tab2
----
158
1969
2985

query I rowsort
SELECT - col1 + - col0 + + col2 AS col1 FROM tab0
----
-131
-77
-98

query I rowsort
SELECT DISTINCT - col0 + + col1 * - tab1.col2 + + col1 * tab1.col2 AS col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT cor0.col1 AS col1 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - + cor0.col2 * col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - + 27 FROM tab2 AS cor0
----
-27
-27
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + 85 + cor0.col0 * + ( - col1 ) col2 FROM tab2 AS cor0
----
-101
-1241
-4458

query I rowsort
SELECT 79 * + col1 * cor0.col1 + - col0 FROM tab2 AS cor0
----
22752
274921
75912

query I rowsort
SELECT ALL - + col1 * cor0.col1 AS col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + col0 * - tab0.col1 - + col2 FROM tab0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT tab1.col0 + col2 * tab1.col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL + col2 + + 11 AS col1 FROM tab2
----
37
38
49

query I rowsort
SELECT ALL tab2.col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - ( - ( + col2 ) ) * 92 AS col0 FROM tab0 AS cor0
----
3036
7544
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-4866
SELECT - + 50 DIV 56 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4866
SELECT - + 50 / 56 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 4 * + col0 FROM tab2 cor0
----
-28
-312
-316

query I rowsort
SELECT - - cor0.col0 + col1 + - col2 AS col0 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT ALL + - col1 * + col0 + - col0 AS col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT + ( col0 ) * + cor0.col2 * cor0.col2 + col0 FROM tab2 cor0
----
114155
5110
52806

query I rowsort
SELECT - + 98 + ( - col0 ) AS col0 FROM tab2 AS cor0
----
-105
-176
-177

onlyif mysql # use DIV operator for integer division
query I rowsort label-4872
SELECT - col0 * col2 DIV 11 AS col0 FROM tab0 AS cor0
----
-3
-663
-72

skipif mysql # not compatible
query I rowsort label-4872
SELECT - col0 * col2 / 11 AS col0 FROM tab0 AS cor0
----
-3
-663
-72

query I rowsort
SELECT + col0 + ( - ( + col1 ) ) AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - + 67 + cor0.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to c820ea85cc8e83989e761a3d41efb118

query I rowsort
SELECT + col2 * col1 + + 11 AS col2 FROM tab0 cor0
----
108
2849
7473

query I rowsort
SELECT cor0.col0 + col1 * 33 * col1 FROM tab1 AS cor0
----
22311
3364
5657

query I rowsort
SELECT ALL + col0 * - col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT - - col0 + + col0 AS col0 FROM tab1 AS cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 + + cor0.col2 - col0 col1 FROM tab0 AS cor0
----
2847
63
7455

query I rowsort
SELECT DISTINCT + + col2 + col0 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - - col0 * 9 AS col1 FROM tab0 AS cor0
----
216
315
801

query I rowsort
SELECT col0 * 35 FROM tab2 AS cor0
----
245
2730
2765

query I rowsort
SELECT ALL - + cor0.col1 * col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-4884
SELECT ALL + col0 DIV + 66 col2 FROM tab1 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4884
SELECT ALL + col0 / + 66 col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + - col0 * col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - col2 + - 18 FROM tab1 AS cor0
----
-114
-72
-75

query I rowsort
SELECT DISTINCT - col2 + cor0.col0 * + 18 AS col1 FROM tab0 AS cor0
----
1520
399
629

query I rowsort
SELECT ALL - + col2 + ( col1 ) FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT col1 - 66 AS col0 FROM tab2 AS cor0
----
-35
-49
-7

query I rowsort
SELECT 36 + + 76 AS col0 FROM tab0 AS cor0
----
112
112
112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4891
SELECT DISTINCT + - CAST( + col0 AS SIGNED ) * col2 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-4891
SELECT DISTINCT + - CAST ( + col0 AS INTEGER ) * col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + + ( ( + col1 ) ) * - col0 + + col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + 76 * + col1 * col1 + + col2 AS col2 FROM tab1 AS cor0
----
12940
51430
7657

query I rowsort
SELECT DISTINCT + + ( + cor0.col0 ) + + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - + 44 + - 84 * + col2 * + col0 AS col2 FROM tab0 AS cor0
----
-2984
-613076
-66572

query I rowsort
SELECT DISTINCT col2 + + ( col2 ) AS col0 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4897
SELECT ALL 54 * + col0 + - col2 * col1 DIV + col1 FROM tab1 cor0
----
108
3399
4224

skipif mysql # not compatible
query I rowsort label-4897
SELECT ALL 54 * + col0 + - col2 * col1 / + col1 FROM tab1 cor0
----
108
3399
4224

query I rowsort
SELECT ALL - - col2 + + 26 * - col2 AS col2 FROM tab0 AS cor0
----
-2050
-25
-825

onlyif mysql # use DIV operator for integer division
query I rowsort label-4899
SELECT ALL - col1 + + tab0.col0 DIV - col1 - + col0 AS col0 FROM tab0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-4899
SELECT ALL - col1 + + tab0.col0 / - col1 - + col0 AS col0 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT col1 + col0 * + 14 AS col2 FROM tab0 AS cor0
----
1337
422
587

query I rowsort
SELECT ALL ( - cor0.col2 ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + - col2 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col0 ) * - ( + col2 ) + - col1 * col0 col0 FROM tab1 AS cor0
----
-240
-4288
-8720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 87 col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab1, tab0 cor0, tab2 AS cor1
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4906
SELECT + - cor0.col0 DIV + col2 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-4906
SELECT + - cor0.col0 / + col2 FROM tab0 cor0
----
-1
-35
0

query I rowsort
SELECT DISTINCT + 28 FROM tab2, tab0 AS cor0
----
28

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab2 cor1, tab2 AS cor2
----
3645 values hashing to 7e572cf6967c395d92dce41dcb35c4db

query I rowsort
SELECT ALL - cor0.col1 * col2 * 33 + - 69 AS col1 FROM tab1 cor0
----
-18879
-41253
-46401

onlyif mysql # use DIV operator for integer division
query I rowsort label-4910
SELECT ALL 43 DIV - tab1.col0 FROM tab1
----
-14
0
0

skipif mysql # not compatible
query I rowsort label-4910
SELECT ALL 43 / - tab1.col0 FROM tab1
----
-14
0
0

query I rowsort
SELECT ALL col1 * - 19 AS col1 FROM tab2 AS cor0
----
-1121
-323
-589

query I rowsort
SELECT ALL col0 * + col1 * 62 AS col0 FROM tab2
----
13454
285324
83266

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4913
SELECT ALL - cor0.col0 + col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4913
SELECT ALL - cor0.col0 + col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT - cor1.col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL + + col2 * - col1 + 9 + - col0 FROM tab0 AS cor0
----
-123
-2853
-7542

query I rowsort
SELECT DISTINCT + col1 + col0 * - col1 + - col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 * cor0.col0 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4919
SELECT DISTINCT + CAST( NULL AS SIGNED ) + - tab0.col1 * + col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4919
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + - tab0.col1 * + col1 FROM tab0
----
NULL

query I rowsort
SELECT + 96 * col2 * tab2.col0 FROM tab2
----
18144
194688
288192

query I rowsort
SELECT 18 * col1 + col1 FROM tab1 cor0
----
190
247
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-4922
SELECT DISTINCT col1 DIV tab1.col1 AS col0 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-4922
SELECT DISTINCT col1 / tab1.col1 AS col0 FROM tab1
----
1

query I rowsort
SELECT DISTINCT 9 * - col0 AS col1 FROM tab2
----
-63
-702
-711

query I rowsort
SELECT - cor0.col0 + - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT + col0 * - col2 - + col1 AS col0 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT - col0 + + col2 FROM tab2
----
-41
-52
20

query I rowsort
SELECT - col0 * col1 * col1 AS col0 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT ALL - col2 * - col1 * col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-4929
SELECT DISTINCT + + col2 + + col0 DIV cor0.col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-4929
SELECT DISTINCT + + col2 + + col0 / cor0.col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT DISTINCT ( col1 ) + col2 * + ( col1 ) AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + col2 * - col0 + 85 FROM tab1
----
-3563
-7595
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4932
SELECT + col0 DIV col1 col0 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4932
SELECT + col0 / col1 col0 FROM tab2
----
0
1
4

query I rowsort
SELECT ALL col2 + - 96 AS col1 FROM tab1
----
-39
-42
0

query I rowsort
SELECT DISTINCT - col1 + + 65 * col2 AS col2 FROM tab1
----
3484
3695
6227

query I rowsort
SELECT DISTINCT tab0.col2 - 7 FROM tab0
----
-6
26
75

query I rowsort
SELECT DISTINCT col2 * + ( col0 ) - - col1 AS col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT ALL ( 96 ) + - tab1.col1 FROM tab1
----
70
83
86

query I rowsort
SELECT ( cor0.col0 * 70 ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 32e7c351ac3303feee4a21eaebb465bc

query I rowsort
SELECT DISTINCT + col2 + 77 FROM tab2
----
103
104
115

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
972 values hashing to 01a5931cccc3dad8792a1bc6df09c614

onlyif mysql # use DIV operator for integer division
query I rowsort label-4941
SELECT ALL col2 + col0 DIV - col1 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-4941
SELECT ALL col2 + col0 / - col1 FROM tab1
----
51
54
90

query I rowsort
SELECT DISTINCT + + 36 FROM tab2 AS cor0
----
36

query I rowsort
SELECT DISTINCT col2 + + col2 * + col2 AS col0 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-4944
SELECT - 84 DIV + col2 + + col0 AS col1 FROM tab1 AS cor0
----
2
63
80

skipif mysql # not compatible
query I rowsort label-4944
SELECT - 84 / + col2 + + col0 AS col1 FROM tab1 AS cor0
----
2
63
80

query I rowsort
SELECT ALL - ( - ( - col2 ) ) * ( + col2 + - col1 * - col1 ) FROM tab2 cor0
----
-12426
-26676
-91182

query I rowsort
SELECT DISTINCT + col1 * col0 + - col0 * 8 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
1958
3212
7478

query I rowsort
SELECT ALL + col1 + + col2 * - col2 AS col0 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT DISTINCT col2 + 3 FROM tab0 AS cor0
----
36
4
85

query I rowsort
SELECT col0 * - col0 + - col2 AS col0 FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT ALL + - 8 * + col0 FROM tab2 AS cor0
----
-56
-624
-632

onlyif mysql # use DIV operator for integer division
query I rowsort label-4951
SELECT ALL - CAST( col0 AS SIGNED ) * + col1 + + tab1.col0 DIV 43 col1 FROM tab1
----
-1039
-639
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4951
SELECT ALL - CAST ( col0 AS INTEGER ) * + col1 + + tab1.col0 / 43 col1 FROM tab1
----
-1039
-639
-78

query I rowsort
SELECT ALL - col0 + + 35 FROM tab0
----
-54
0
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4953
SELECT ALL + CAST( NULL AS SIGNED ) * - col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4953
SELECT ALL + CAST ( NULL AS INTEGER ) * - col1 AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4954
SELECT ALL + CAST( NULL AS SIGNED ) * col0 + + col1 / 5 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4954
SELECT ALL + CAST ( NULL AS INTEGER ) * col0 + + col1 / 5 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 87 FROM tab2, tab1 AS cor0
----
9 values hashing to 84bcab58a965cc8ae97b39d2d01b3d23

query I rowsort
SELECT DISTINCT ( col0 ) AS col0 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4957
SELECT col0 DIV 89 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4957
SELECT col0 / 89 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT - tab0.col0 * - col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + - 78 * col2 + - col2 AS col0 FROM tab2 AS cor0
----
-2054
-2133
-3002

query I rowsort
SELECT ALL - - cor0.col2 * col1 - + ( col0 * - col1 ) AS col1 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT + 54 * - cor0.col0 + - col0 AS col1 FROM tab1 AS cor0
----
-165
-3520
-4400

query I rowsort
SELECT + 3 + col1 AS col0 FROM tab0 cor0
----
100
89
94

query I rowsort
SELECT + - cor0.col2 * col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - cor0.col2 + + col2 * 58 * + cor0.col2 FROM tab1 AS cor0
----
169074
188385
534432

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4965
SELECT ALL + col1 * + CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-4965
SELECT ALL + col1 * + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4966
SELECT - - col0 * + CAST( + 60 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
1440
2100
5340

skipif mysql # not compatible
query I rowsort label-4966
SELECT - - col0 * + CAST ( + 60 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
1440
2100
5340

query I rowsort
SELECT + 82 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT DISTINCT + - col2 * 75 FROM tab0 AS cor0
----
-2475
-6150
-75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4969
SELECT - col0 * - CAST( NULL AS DECIMAL ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4969
SELECT - col0 * - CAST ( NULL AS REAL ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col0 * - cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col0 * 9 FROM tab2 AS cor0
----
63
702
711

query I rowsort
SELECT ALL col1 + + ( + col2 ) * - col2 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - col2 + 81 * - 5 AS col1 FROM tab2 AS cor0
----
-431
-432
-443

query I rowsort
SELECT DISTINCT + - col2 + ( + col1 ) AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT col1 * + ( - col0 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + cor0.col2 * - col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4977
SELECT DISTINCT col2 + ( - col1 ) DIV - col2 col1 FROM tab0 AS cor0
----
35
83
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4977
SELECT DISTINCT col2 + ( - col1 ) / - col2 col1 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT - - cor0.col1 + - col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT ALL + - col1 * CAST ( - col1 * - col1 AS REAL ) FROM tab0 AS cor0
----
-636056
-753571
-912673

query I rowsort
SELECT - 0 + cor0.col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + col1 * 22 FROM tab1 AS cor0
----
220
286
572

query I rowsort
SELECT ALL ( ( col1 ) ) * + 98 FROM tab0 cor0
----
8428
8918
9506

query I rowsort
SELECT - - 94 * ( - col1 ) - col1 AS col0 FROM tab2 AS cor0
----
-1615
-2945
-5605

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + - col2 col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - tab2.col1 * - col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT - + col1 + 55 AS col2 FROM tab2 AS cor0
----
-4
24
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4987
SELECT + col2 * CAST( - col2 AS SIGNED ) / - col1 - CAST( NULL AS SIGNED ) * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4987
SELECT + col2 * CAST ( - col2 AS INTEGER ) / - col1 - CAST ( NULL AS INTEGER ) * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * ( + col2 ) + col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL - + cor0.col2 * - 9 * + 57 FROM tab1 AS cor0
----
27702
29241
49248

query I rowsort
SELECT - cor0.col0 + ( cor0.col2 ) * + col1 AS col1 FROM tab0 AS cor0
----
2814
62
7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-4991
SELECT col1 * + col1 + - 83 DIV col0 + ( col1 ) * col1 DIV 34 col2 FROM tab2 AS cor0
----
296
3582
978

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4991
SELECT col1 * + col1 + - 83 / col0 + ( col1 ) * col1 / 34 col2 FROM tab2 AS cor0
----
296
3582
978

onlyif mysql # use DIV operator for integer division
query I rowsort label-4992
SELECT col2 DIV + 78 col2 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4992
SELECT col2 / + 78 col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT col2 + col1 * + 16 * + col0 FROM tab2 AS cor0
----
21526
3499
73658

query I rowsort
SELECT + 57 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT + col0 - + col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + cor0.col2 + 14 AS col2 FROM tab2 AS cor0
----
40
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4997
SELECT + col0 + CAST( col1 AS SIGNED ) + + col2 col0 FROM tab0 AS cor0
----
133
143
262

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4997
SELECT + col0 + CAST ( col1 AS INTEGER ) + + col2 col0 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT col0 AS col0 FROM tab1 WHERE col1 = - col2 + - col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4999
SELECT DISTINCT - col0 DIV col1 + tab0.col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4999
SELECT DISTINCT - col0 / col1 + tab0.col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + col1 + + col1 AS col0 FROM tab2
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col0 * - col2 + col0 / tab0.col0 col2 FROM tab0 WHERE ( + col1 ) = NULL
----

query I rowsort
SELECT DISTINCT + col2 AS col0 FROM tab1 WHERE NOT col1 <> NULL
----

query I rowsort
SELECT - col0 AS col1 FROM tab2 WHERE NOT - col2 NOT BETWEEN ( NULL ) AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col0 col0 FROM tab0
----
171
36
57

query I rowsort
SELECT - col2 + - col1 * + col2 AS col2 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT - col2 * + col1 * col0 + col2 AS col1 FROM tab0
----
-3394
-664036
-68079

query I rowsort
SELECT - ( col1 ) + 83 FROM tab1
----
57
70
73

query I rowsort
SELECT col1 + col2 * + col1 AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + - 6 AS col1 FROM tab2 AS cor0
----
-6
-6
-6

query I rowsort
SELECT DISTINCT - col1 - - col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - col2 * - col2 + - col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT - cor0.col2 * cor0.col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 * col1 col0 FROM tab1
----
-16224
-36504
-5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-5014
SELECT + col0 - col0 DIV + cor0.col1 FROM tab1 AS cor0
----
3
58
74

skipif mysql # not compatible
query I rowsort label-5014
SELECT + col0 - col0 / + cor0.col1 FROM tab1 AS cor0
----
3
58
74

query I rowsort
SELECT ALL + col2 * - ( ( col2 ) * col1 + col0 * - col2 ) FROM tab1 AS cor0
----
-67068
175446
617472

query I rowsort
SELECT ALL - col2 * col1 - - col2 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + col0 * 80 AS col0 FROM tab2 AS cor0
----
560
6240
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5018
SELECT ALL + col1 DIV col2 AS col1 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5018
SELECT ALL + col1 / col2 AS col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT cor0.col0 * + cor0.col1 + col2 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - cor1.col1 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL 57 * + col0 + col1 * col2 + + 73 FROM tab2
----
1309
5222
6053

query I rowsort
SELECT ALL 42 + col0 FROM tab0
----
131
66
77

query I rowsort
SELECT ALL + ( col2 ) + + col1 FROM tab0
----
119
173
98

query I rowsort
SELECT - 9 * + col0 + - col1 FROM tab0 AS cor0
----
-302
-412
-892

query I rowsort
SELECT DISTINCT - ( + cor0.col0 ) FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT cor0.col0 + col2 + col2 AS col1 FROM tab0 AS cor0
----
253
37
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor1.col0 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5028
SELECT - + cor0.col0 DIV col1 + + col2 + - ( col0 ) * + col2 * ( cor0.col1 ) FROM tab2 AS cor0
----
-119627
-51000
-5832

skipif mysql # not compatible
query I rowsort label-5028
SELECT - + cor0.col0 / col1 + + col2 + - ( col0 ) * + col2 * ( cor0.col1 ) FROM tab2 AS cor0
----
-119627
-51000
-5832

query I rowsort
SELECT - - col1 + - col1 + + cor0.col0 AS col1 FROM tab0 cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5030
SELECT DISTINCT + + col1 DIV col1 + - cor0.col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-5030
SELECT DISTINCT + + col1 / col1 + - cor0.col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col1 FROM tab1, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT + 69 + cor0.col1 FROM tab2 cor0
----
100
128
86

query I rowsort
SELECT ALL 67 AS col2 FROM tab1 AS cor0
----
67
67
67

query I rowsort
SELECT DISTINCT 64 * - col1 AS col1 FROM tab2 AS cor0
----
-1088
-1984
-3776

onlyif mysql # use DIV operator for integer division
query I rowsort label-5035
SELECT - 49 DIV col0 AS col1 FROM tab1 AS cor0
----
-16
0
0

skipif mysql # not compatible
query I rowsort label-5035
SELECT - 49 / col0 AS col1 FROM tab1 AS cor0
----
-16
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5036
SELECT DISTINCT + + 3 DIV + col0 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5036
SELECT DISTINCT + + 3 / + col0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT cor0.col0 AS col0 FROM tab0, tab1, tab2 AS cor0, tab0 AS cor1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT DISTINCT + + ( cor0.col2 ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - + 21 FROM tab1 AS cor0
----
-21
-21
-21

query I rowsort
SELECT + - 88 FROM tab2 AS cor0
----
-88
-88
-88

query I rowsort
SELECT DISTINCT 83 FROM tab2, tab2 AS cor0
----
83

query I rowsort
SELECT DISTINCT col1 * col1 + tab1.col1 AS col2 FROM tab1
----
110
182
702

query I rowsort
SELECT + 25 * tab2.col1 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 486127fb97b979df6fedac3928625e8b

query I rowsort
SELECT col1 + ( ( cor0.col1 ) ) AS col2 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5045
SELECT + - col0 + + 74 * + ( col1 ) - - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5045
SELECT + - col0 + + 74 * + ( col1 ) - - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col2 * 27 AS col1 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT DISTINCT + + col2 * + ( col0 ) AS col1 FROM tab0 cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 23 * col1 + col2 col0 FROM tab1 cor0
----
287
395
652

skipif mysql # not compatible
query I rowsort
SELECT ALL + + CAST ( cor0.col0 AS REAL ) * cor0.col0 + col0 / col0 AS col1 FROM tab1 AS cor0
----
10
4097
6401

query I rowsort
SELECT + 82 + + ( - col2 ) AS col1 FROM tab0 AS cor0
----
0
49
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5051
SELECT + + col1 DIV - 35 + - col2 AS col0 FROM tab2 cor0
----
-27
-27
-38

skipif mysql # not compatible
query I rowsort label-5051
SELECT + + col1 / - 35 + - col2 AS col0 FROM tab2 cor0
----
-27
-27
-38

query I rowsort
SELECT ALL + + 78 * + 41 + col2 FROM tab1 AS cor0
----
3252
3255
3294

query I rowsort
SELECT ALL - cor0.col2 * 3 FROM tab2 AS cor0
----
-114
-78
-81

query I rowsort
SELECT DISTINCT - 87 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab2, tab2 AS cor2
----
-87

query I rowsort
SELECT ALL - col2 + col1 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + ( + tab0.col2 ) * + 58 FROM tab0
----
1914
4756
58

query I rowsort
SELECT + - ( + col1 ) * + 10 + col0 AS col0 FROM tab2 cor0
----
-303
-512
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col1 * - cor0.col1 col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT DISTINCT + 59 + + cor0.col1 * col1 FROM tab0 AS cor0
----
7455
8340
9468

query I rowsort
SELECT DISTINCT - + ( col2 ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + - col0 * col1 + col0 FROM tab1 AS cor0
----
-576
-75
-960

skipif mysql # not compatible
query I rowsort
SELECT col1 + + col0 - + CAST ( col1 AS REAL ) FROM tab2
----
7
78
79

query I rowsort
SELECT + + col1 - col2 AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT cor0.col2 - 67 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to bbde94b77851d0996e8c23ede3026c9f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5065
SELECT DISTINCT col0 * col1 + col2 DIV - col0 FROM tab1
----
1039
60
640

skipif mysql # not compatible
query I rowsort label-5065
SELECT DISTINCT col0 * col1 + col2 / - col0 FROM tab1
----
1039
60
640

query I rowsort
SELECT - 6 * - col1 FROM tab0
----
516
546
582

query I rowsort
SELECT + ( col1 ) + + col2 + 89 AS col0 FROM tab2
----
144
147
174

onlyif mysql # use DIV operator for integer division
query I rowsort label-5068
SELECT - - col1 + - 96 DIV ( col1 ) AS col2 FROM tab2 AS cor0
----
12
28
58

skipif mysql # not compatible
query I rowsort label-5068
SELECT - - col1 + - 96 / ( col1 ) AS col2 FROM tab2 AS cor0
----
12
28
58

query I rowsort
SELECT - 37 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5070
SELECT + col2 * - 0 DIV - 90 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5070
SELECT + col2 * - 0 / - 90 FROM tab2
----
0
0
0

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5072
SELECT - CAST( NULL AS SIGNED ) + + ( cor0.col0 ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5072
SELECT - CAST ( NULL AS INTEGER ) + + ( cor0.col0 ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 66 + + col0 * col2 col2 FROM tab1 AS cor0
----
228
3714
7746

query I rowsort
SELECT ALL + tab0.col2 * - ( - col0 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT + col0 * - ( + col0 ) FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT ALL + col2 * tab0.col2 - - col2 AS col0 FROM tab0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5077
SELECT ALL col1 DIV col0 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5077
SELECT ALL col1 / col0 FROM tab1
----
0
0
8

query I rowsort
SELECT 54 + - tab0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to bede7ed395408e83332088c0abb235fc

query I rowsort
SELECT + ( ( - tab2.col0 ) ) + col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT + 25 AS col0 FROM tab1
----
25
25
25

query I rowsort
SELECT 18 + col1 AS col1 FROM tab0
----
104
109
115

query I rowsort
SELECT + ( + col1 * - col0 ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - - 95 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
95

query I rowsort
SELECT ALL + 69 * col0 AS col0 FROM tab0
----
1656
2415
6141

query I rowsort
SELECT + + 44 FROM tab0 AS cor0
----
44
44
44

query I rowsort
SELECT DISTINCT - + cor0.col2 + col2 * + col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL - col0 * - col2 + - cor0.col0 FROM tab0 AS cor0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) + 61 col0 FROM tab0 cor0
----
143
62
94

query I rowsort
SELECT - col2 + 63 FROM tab2
----
25
36
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 70 * col0 col2 FROM tab1 AS cor0
----
-210
-4480
-5600

query I rowsort
SELECT ALL 57 AS col0 FROM tab2
----
57
57
57

query I rowsort
SELECT tab2.col0 - + col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT col0 * col1 + + col2 * + col1 AS col1 FROM tab0
----
15561
3492
4902

query I rowsort
SELECT DISTINCT + - 99 - col0 * - col1 FROM tab1 AS cor0
----
-21
541
941

onlyif mysql # use DIV operator for integer division
query I rowsort label-5095
SELECT ALL col1 + col2 DIV col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5095
SELECT ALL col1 + col2 / col2 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT - + 87 * col2 FROM tab2 cor0
----
-2262
-2349
-3306

query I rowsort
SELECT + - 22 * - col0 AS col1 FROM tab0 AS cor0
----
1958
528
770

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 94 * - 61 FROM tab0 AS cor0
----
-5734
-5734
-5734

query I rowsort
SELECT DISTINCT - - 73 * - col2 AS col1 FROM tab2 AS cor0
----
-1898
-1971
-2774

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 - col2 * + col2 col1 FROM tab0 cor0
----
-1056
-6642
0

query I rowsort
SELECT + col2 * col0 + 9 AS col2 FROM tab2 AS cor0
----
198
2037
3011

query I rowsort
SELECT ALL + + 83 - col2 AS col0 FROM tab2 AS cor0
----
45
56
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + col2 * col0 col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + 89 FROM tab2 cor0
----
89
89
89

query I rowsort
SELECT - col0 * - col2 - col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT - cor0.col0 + cor0.col1 * col1 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT ALL - col0 - - cor0.col2 FROM tab0 cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5109
SELECT + - cor0.col1 DIV col1 + col0 AS col0 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-5109
SELECT + - cor0.col1 / col1 + col0 AS col0 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT DISTINCT - + ( col2 ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + + ( - col2 ) * - cor0.col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - - cor0.col1 * + col1 + col0 + - col1 FROM tab0 AS cor0
----
7334
8279
9347

query I rowsort
SELECT col2 + - 46 AS col0 FROM tab2 AS cor0
----
-19
-20
-8

query I rowsort
SELECT - + col1 + - col1 * + cor0.col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT + cor0.col2 * ( + 29 ) FROM tab0 AS cor0
----
2378
29
957

query I rowsort
SELECT ALL - + col2 + cor0.col0 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5117
SELECT + cor0.col0 DIV 21 AS col1 FROM tab1 cor0
----
0
3
3

skipif mysql # not compatible
query I rowsort label-5117
SELECT + cor0.col0 / 21 AS col1 FROM tab1 cor0
----
0
3
3

query I rowsort
SELECT DISTINCT - - col0 + - col2 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT - col2 + col1 + - col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - - col2 * - col1 + - col2 + + col2 * - col2 FROM tab2 AS cor0
----
-1593
-2128
-2236

query I rowsort
SELECT 35 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT ALL col1 + + 18 * col1 AS col2 FROM tab2 AS cor0
----
1121
323
589

query I rowsort
SELECT ALL + - 48 * col1 AS col2 FROM tab1 AS cor0
----
-1248
-480
-624

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5124
SELECT CAST( - 73 AS SIGNED ) * + col1 AS col1 FROM tab0 cor0
----
-6278
-6643
-7081

skipif mysql # not compatible
query I rowsort label-5124
SELECT CAST ( - 73 AS INTEGER ) * + col1 AS col1 FROM tab0 cor0
----
-6278
-6643
-7081

query I rowsort
SELECT + 25 AS col2 FROM tab2 cor0
----
25
25
25

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col1 AS REAL ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + col0 * col1 + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL - ( col1 ) * + col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - col0 + col0 * + col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + - col1 * - 22 + col0 FROM tab1 AS cor0
----
284
366
575

query I rowsort
SELECT ALL + - ( - col0 ) AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL 90 AS col1 FROM tab0 AS cor0
----
90
90
90

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 + col1 * col1 FROM tab1 cor0
----
1209
740
754

query I rowsort
SELECT DISTINCT - col2 * + col1 + - col2 AS col0 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT col2 + - ( col2 * col1 + 59 ) AS col2 FROM tab1
----
-1211
-1409
-572

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5136
SELECT ALL tab0.col1 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5136
SELECT ALL tab0.col1 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5137
SELECT ALL - col0 + - 63 DIV col0 FROM tab2
----
-16
-78
-79

skipif mysql # not compatible
query I rowsort label-5137
SELECT ALL - col0 + - 63 / col0 FROM tab2
----
-16
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5138
SELECT ( + ( col1 ) ) DIV col1 + - 88 AS col2 FROM tab0
----
-87
-87
-87

skipif mysql # not compatible
query I rowsort label-5138
SELECT ( + ( col1 ) ) / col1 + - 88 AS col2 FROM tab0
----
-87
-87
-87

query I rowsort
SELECT ALL 99 AS col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 79 + - col1 * - col0 col0 FROM tab1 AS cor0
----
-1
561
961

query I rowsort
SELECT DISTINCT + + 71 * col1 AS col0 FROM tab2 AS cor0
----
1207
2201
4189

query I rowsort
SELECT ALL cor0.col0 * 49 AS col1 FROM tab0 AS cor0
----
1176
1715
4361

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 20 + 26 * col1 col2 FROM tab1 AS cor0
----
280
358
696

query I rowsort
SELECT DISTINCT + col2 + - cor0.col0 * - col0 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-5145
SELECT DISTINCT - 9 DIV col2 AS col0 FROM tab0 AS cor0
----
-9
0

skipif mysql # not compatible
query I rowsort label-5145
SELECT DISTINCT - 9 / col2 AS col0 FROM tab0 AS cor0
----
-9
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL ( - col1 ) + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT 71 FROM tab0 cor0
----
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5149
SELECT - + col0 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5149
SELECT - + col0 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + ( 3 ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT ALL 91 + + col1 FROM tab2
----
108
122
150

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - col0 col2 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - col1 * 34 col2 FROM tab0
----
-2891
-3012
-3297

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0, tab0 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to bce5cbf48f4a41569415c085ae91ae7c

query I rowsort
SELECT DISTINCT - col0 + ( + col0 ) FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5156
SELECT col0 DIV - ( col0 * col1 ) + cor0.col1 AS col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-5156
SELECT col0 / - ( col0 * col1 ) + cor0.col1 AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + col2 * - ( - col2 ) FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL + + col2 * col1 + col1 AS col1 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + + col0 * 93 + col2 AS col2 FROM tab1 AS cor0
----
333
6009
7536

query I rowsort
SELECT ALL col2 + + ( + 9 ) FROM tab2 AS cor0
----
35
36
47

query I rowsort
SELECT + 49 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT + col2 * col1 + - col2 * + col0 FROM tab2 cor0
----
-2356
-494
648

query I rowsort
SELECT DISTINCT + - col2 * col1 + ( - col0 ) FROM tab0 cor0
----
-132
-2862
-7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col2 * cor0.col1 col1 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * col1 + + cor0.col0 col2 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT + cor0.col1 * - cor0.col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - 77 * col1 FROM tab1 cor0
----
-1001
-2002
-770

query I rowsort
SELECT ALL + cor0.col1 + 29 AS col1 FROM tab0, tab1, tab2 AS cor0, tab2
----
81 values hashing to 6e2e1a4432503acf55c66483db9f79ef

query I rowsort
SELECT 81 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT col2 - col0 * col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL + 62 FROM tab0
----
62
62
62

query I rowsort
SELECT + + col2 * - col2 + + 17 FROM tab2 AS cor0
----
-1427
-659
-712

query I rowsort
SELECT ALL + + 50 FROM tab2 AS cor0
----
50
50
50

query I rowsort
SELECT ALL - col2 + - col0 * col2 AS col1 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT col1 * - col1 + - col1 AS col0 FROM tab0
----
-7482
-8372
-9506

query I rowsort
SELECT - cor0.col1 + ( col2 ) FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT col0 * + 77 + col0 * - col1 - + ( col1 ) * col2 FROM tab2 AS cor0
----
-130
-515
4094

query I rowsort
SELECT + col2 * - 75 AS col0 FROM tab0 AS cor0
----
-2475
-6150
-75

query I rowsort
SELECT DISTINCT + 16 FROM tab1, tab1 AS cor0
----
16

query I rowsort
SELECT + col1 * col0 * col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT DISTINCT + col2 + - col0 * col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL + ( cor0.col0 ) - col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT col2 * + col2 + col2 FROM tab2 AS cor0
----
1482
702
756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( ( col1 ) ) * ( - cor0.col1 ) col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL + 92 - col1 * + col2 * + ( + col1 ) FROM tab2 AS cor0
----
-10890
-25855
-90414

query I rowsort
SELECT DISTINCT 55 + 51 * col0 AS col1 FROM tab2 AS cor0
----
4033
4084
412

query I rowsort
SELECT col1 * + col1 + col0 AS col1 FROM tab1 AS cor0
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-5188
SELECT ALL + 48 DIV + col0 - col1 FROM tab1 AS cor0
----
-10
-10
-13

skipif mysql # not compatible
query I rowsort label-5188
SELECT ALL + 48 / + col0 - col1 FROM tab1 AS cor0
----
-10
-10
-13

query I rowsort
SELECT DISTINCT + cor0.col1 + - col0 * col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT ( col2 ) + + col1 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col0 * + 96 * col1 AS col2 FROM tab1 AS cor0
----
61440
7488
99840

query I rowsort
SELECT ALL + cor0.col2 * col1 - col2 AS col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT - cor0.col2 * + col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + 8 FROM tab2, tab1 AS cor0
----
8

query I rowsort
SELECT + - col1 + + col1 * - col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ( 79 ) FROM tab2 AS cor0
----
79
79
79

query I rowsort
SELECT - 38 * col0 FROM tab2 AS cor0
----
-266
-2964
-3002

query I rowsort
SELECT + - ( - cor0.col0 ) + - cor0.col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + col1 + - cor0.col1 * - col2 AS col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT 97 * - col1 FROM tab1 AS cor0
----
-1261
-2522
-970

query I rowsort
SELECT ALL - tab2.col0 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT - 68 * col0 FROM tab2 cor0
----
-476
-5304
-5372

query I rowsort
SELECT + 99 * col1 AS col0 FROM tab2 cor0
----
1683
3069
5841

onlyif mysql # use DIV operator for integer division
query I rowsort label-5204
SELECT ALL - ( + col1 ) DIV col2 AS col0 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-5204
SELECT ALL - ( + col1 ) / col2 AS col0 FROM tab0
----
-1
-2
-97

query I rowsort
SELECT ALL - 53 * col1 AS col0 FROM tab0
----
-4558
-4823
-5141

query I rowsort
SELECT - ( 7 ) FROM tab1
----
-7
-7
-7

query I rowsort
SELECT + col0 * 38 + col1 AS col0 FROM tab1 AS cor0
----
140
2442
3053

query I rowsort
SELECT - cor0.col1 + - col0 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - col1 + + 57 + - 68 * + cor0.col0 FROM tab1 AS cor0
----
-173
-4305
-5396

query I rowsort
SELECT - cor0.col1 + col2 + ( col2 ) AS col0 FROM tab0 cor0
----
-20
-95
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5211
SELECT cor0.col1 + + CAST( + 4 AS SIGNED ) * col0 + - 22 AS col1 FROM tab1 AS cor0
----
16
244
311

skipif mysql # not compatible
query I rowsort label-5211
SELECT cor0.col1 + + CAST ( + 4 AS INTEGER ) * col0 + - 22 AS col1 FROM tab1 AS cor0
----
16
244
311

query I rowsort
SELECT ALL + 39 + - col1 + + col0 AS col0 FROM tab2
----
101
15
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5213
SELECT ALL + tab2.col2 * tab2.col1 DIV 23 AS col1 FROM tab2
----
28
36
66

skipif mysql # not compatible
query I rowsort label-5213
SELECT ALL + tab2.col2 * tab2.col1 / 23 AS col1 FROM tab2
----
28
36
66

query I rowsort
SELECT DISTINCT + col2 * - cor0.col0 AS col0 FROM tab0 cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5215
SELECT DISTINCT - cor0.col1 + col1 DIV + col2 FROM tab0 AS cor0
----
-84
-90
0

skipif mysql # not compatible
query I rowsort label-5215
SELECT DISTINCT - cor0.col1 + col1 / + col2 FROM tab0 AS cor0
----
-84
-90
0

query I rowsort
SELECT DISTINCT + - col0 * + col0 * col2 AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL - cor0.col2 AS col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT col0 + ( - 18 ) + col1 * col0 AS col0 FROM tab0 cor0
----
2070
3412
8170

query I rowsort
SELECT ALL + col2 * + 95 FROM tab2 AS cor0
----
2470
2565
3610

onlyif mysql # use DIV operator for integer division
query I rowsort label-5220
SELECT DISTINCT col0 DIV col0 FROM tab2 cor0
----
1

skipif mysql # not compatible
query I rowsort label-5220
SELECT DISTINCT col0 / col0 FROM tab2 cor0
----
1

query I rowsort
SELECT DISTINCT - 18 FROM tab0, tab2 AS cor0
----
-18

query I rowsort
SELECT DISTINCT + 32 + col1 FROM tab1
----
42
45
58

query I rowsort
SELECT ALL tab1.col0 * col0 + - col2 AS col1 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT tab0.col0 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT + 20 * + col2 FROM tab1
----
1080
1140
1920

query I rowsort
SELECT + col1 * + 46 AS col0 FROM tab1 AS cor0
----
1196
460
598

query I rowsort
SELECT DISTINCT - col2 + cor0.col2 + + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL col0 + - col0 * - 72 FROM tab1 AS cor0
----
219
4672
5840

query I rowsort
SELECT ALL col1 * - 63 * + col1 AS col2 FROM tab0 AS cor0
----
-465948
-521703
-592767

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + 97 * 47 - col1 col0 FROM tab1 AS cor0
----
4587
4606
4642

query I rowsort
SELECT DISTINCT - col2 + + col2 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - - col2 * ( col0 ) + - col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5233
SELECT ALL + col0 - 3 * cor0.col0 DIV + col2 AS col0 FROM tab1 AS cor0
----
3
61
78

skipif mysql # not compatible
query I rowsort label-5233
SELECT ALL + col0 - 3 * cor0.col0 / + col2 AS col0 FROM tab1 AS cor0
----
3
61
78

query I rowsort
SELECT ALL + col2 * ( col0 ) * + col0 FROM tab2 AS cor0
----
1323
158184
237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col2 col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + col0 * - cor0.col1 + - cor0.col1 AS col0 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT + col1 * - col0 + + col1 * - col0 AS col1 FROM tab1 AS cor0
----
-1280
-156
-2080

onlyif mysql # use DIV operator for integer division
query I rowsort label-5238
SELECT col1 DIV col1 - col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-5238
SELECT col1 / col1 - col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT + 1 * col2 AS col0 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5240
SELECT - col2 DIV col0 AS col2 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-5240
SELECT - col2 / col0 AS col2 FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT - col1 + + col0 * col1 AS col0 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT ALL - 81 + col2 * - col1 FROM tab1 cor0
----
-1329
-1485
-651

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5243
SELECT CAST( NULL AS DECIMAL ) + + 47 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5243
SELECT CAST ( NULL AS REAL ) + + 47 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5244
SELECT DISTINCT - 37 DIV - col0 AS col2 FROM tab1 AS cor0
----
0
12

skipif mysql # not compatible
query I rowsort label-5244
SELECT DISTINCT - 37 / - col0 AS col2 FROM tab1 AS cor0
----
0
12

query I rowsort
SELECT - cor0.col0 * 36 FROM tab2 cor0
----
-252
-2808
-2844

onlyif mysql # use DIV operator for integer division
query I rowsort label-5246
SELECT ( cor0.col0 ) DIV col2 AS col0 FROM tab0 cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5246
SELECT ( cor0.col0 ) / col2 AS col0 FROM tab0 cor0
----
0
1
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5247
SELECT + CAST( NULL AS SIGNED ) + col2 * + col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5247
SELECT + CAST ( NULL AS INTEGER ) + col2 * + col1 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5248
SELECT + col1 + col0 DIV cor0.col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5248
SELECT + col1 + col0 / cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + - 85 * col0 FROM tab0 AS cor0
----
-2040
-2975
-7565

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 + col0 col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - col2 + - col1 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
251
3455
934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 * + 70 col2 FROM tab1 AS cor0
----
213
4544
5680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5253
SELECT DISTINCT - + col2 * + 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-5253
SELECT DISTINCT - + col2 * + col0 - + CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5254
SELECT - col0 + - col0 DIV col1 AS col2 FROM tab2 AS cor0
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-5254
SELECT - col0 + - col0 / col1 AS col2 FROM tab2 AS cor0
----
-7
-79
-83

query I rowsort
SELECT ALL + 53 - cor0.col1 FROM tab1, tab2 cor0
----
9 values hashing to affa9430a531ebb6bf1d6415021cdc30

query I rowsort
SELECT - 87 + col0 FROM tab0 AS cor0
----
-52
-63
2

query I rowsort
SELECT + 27 * - cor0.col2 FROM tab0 cor0
----
-2214
-27
-891

query I rowsort
SELECT DISTINCT - ( col1 ) + col0 * + 72 AS col0 FROM tab1 AS cor0
----
190
4598
5747

query I rowsort
SELECT DISTINCT + + 3 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
246
3
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-5260
SELECT ALL + col1 DIV col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5260
SELECT ALL + col1 / col2 AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT + + cor0.col2 + - cor0.col2 * + col0 FROM tab2 cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-5262
SELECT + 30 + col0 * - col1 + - col2 DIV col1 col2 FROM tab1 AS cor0
----
-1017
-50
-615

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5262
SELECT + 30 + col0 * - col1 + - col2 / col1 col2 FROM tab1 AS cor0
----
-1017
-50
-615

query I rowsort
SELECT - cor0.col0 * col0 AS col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL 88 AS col2 FROM tab0 AS cor0
----
88
88
88

query I rowsort
SELECT + col2 + - col2 * ( - 33 ) * - col2 FROM tab1 AS cor0
----
-107160
-304032
-96174

query I rowsort
SELECT + - 0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 8 FROM tab0 AS cor0
----
8
8
8

query I rowsort
SELECT DISTINCT ( 68 ) * tab0.col2 - - 74 AS col0 FROM tab0
----
142
2318
5650

query I rowsort
SELECT ( col0 ) * tab0.col2 + col2 FROM tab0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-5270
SELECT + col2 + - col2 DIV - 41 FROM tab0 AS cor0
----
1
33
84

skipif mysql # not compatible
query I rowsort label-5270
SELECT + col2 + - col2 / - 41 FROM tab0 AS cor0
----
1
33
84

query I rowsort
SELECT ALL ( + col0 ) AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + + 8 + + col1 FROM tab1 AS cor0
----
18
21
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5273
SELECT DISTINCT + + 52 DIV - col2 + col2 DIV - col0 AS col2 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-5273
SELECT DISTINCT + + 52 / - col2 + col2 / - col0 AS col2 FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT + col2 + col0 * - ( - 95 ) FROM tab0 AS cor0
----
2313
3326
8537

query I rowsort
SELECT + - col0 + + ( + 20 ) AS col1 FROM tab0 cor0
----
-15
-4
-69

query I rowsort
SELECT ALL - col2 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT DISTINCT tab2.col1 * + tab2.col2 + 56 AS col1 FROM tab2
----
1590
702
893

query I rowsort
SELECT ( + col1 ) * 45 + - col2 * col0 FROM tab1
----
-3198
-7095
1008

onlyif mysql # use DIV operator for integer division
query I rowsort label-5280
SELECT - col2 * - col1 + CAST( + ( - tab0.col0 ) + 94 AS SIGNED ) DIV col0 AS col1 FROM tab0
----
2840
7462
98

skipif mysql # not compatible
query I rowsort label-5280
SELECT - col2 * - col1 + CAST ( + ( - tab0.col0 ) + 94 AS INTEGER ) / col0 AS col1 FROM tab0
----
2840
7462
98

query I rowsort
SELECT - 30 + - col2 FROM tab1
----
-126
-84
-87

query I rowsort
SELECT ALL + - col0 + + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + + col0 FROM tab0 cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-5284
SELECT + 59 + + col0 DIV cor0.col1 FROM tab0 AS cor0
----
59
59
59

skipif mysql # not compatible
query I rowsort label-5284
SELECT + 59 + + col0 / cor0.col1 FROM tab0 AS cor0
----
59
59
59

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
1
33
82

query I rowsort
SELECT - 25 * col2 + col2 AS col0 FROM tab2 AS cor0
----
-624
-648
-912

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 cor1, tab0 cor2
----
972 values hashing to 5342fb4caf4767cb98bd21989bad099f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5288
SELECT CAST( NULL AS SIGNED ) / - col0 + col0 * - ( 20 ) - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5288
SELECT CAST ( NULL AS INTEGER ) / - col0 + col0 * - ( 20 ) - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 42 + tab1.col2 FROM tab1
----
138
96
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + tab2.col1 ) * tab2.col2 + + tab2.col0 col1 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT + col0 + 86 - - col2 AS col2 FROM tab0
----
122
143
257

query I rowsort
SELECT - 54 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

onlyif mysql # use DIV operator for integer division
query I rowsort label-5293
SELECT DISTINCT col0 DIV + col0 - col2 AS col0 FROM tab2
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-5293
SELECT DISTINCT col0 / + col0 - col2 AS col0 FROM tab2
----
-25
-26
-37

query I rowsort
SELECT ALL - col0 - - col1 * cor0.col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT - col2 * 34 * col0 AS col2 FROM tab2 AS cor0
----
-102068
-6426
-68952

query I rowsort
SELECT + cor0.col1 * - 0 + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 5 * - 30 col2 FROM tab2 cor0
----
150
150
150

query I rowsort
SELECT ALL - - col2 * 18 AS col0 FROM tab0 AS cor0
----
1476
18
594

query I rowsort
SELECT ( col1 ) * col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + - ( - cor0.col0 ) * col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT + col2 + col2 AS col0 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-5302
SELECT DISTINCT - col0 * col1 DIV + col1 FROM tab0 cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5302
SELECT DISTINCT - col0 * col1 / + col1 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT - - col0 + cor0.col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT + tab1.col1 + - 77 FROM tab1, tab0 AS cor0
----
9 values hashing to 9424abe064c8ec2b715f1d69317e9a21

query I rowsort
SELECT + cor0.col2 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + ( col0 ) * + cor0.col0 * 54 FROM tab2 AS cor0
----
2646
328536
337014

query I rowsort
SELECT ( + cor0.col0 + cor0.col2 ) AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 00ff93cbcc751be1393f9e1fd72170f8

query I rowsort
SELECT ALL + tab0.col0 AS col1 FROM tab1, tab0 cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL + 62 + cor0.col2 FROM tab1 AS cor0
----
116
119
158

query I rowsort
SELECT ALL - ( + col0 ) * col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + col2 * + col1 + - 5 FROM tab2
----
1529
641
832

onlyif mysql # use DIV operator for integer division
query I rowsort label-5312
SELECT - col2 + 59 DIV - col1 FROM tab1 cor0
----
-100
-56
-62

skipif mysql # not compatible
query I rowsort label-5312
SELECT - col2 + 59 / - col1 FROM tab1 cor0
----
-100
-56
-62

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab1, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - tab1.col2 * col1 AS col1 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5315
SELECT ALL - tab2.col0 DIV + 38 AS col1 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 24950544d5039d1d5a57fa31a4f89f27

skipif mysql # not compatible
query I rowsort label-5315
SELECT ALL - tab2.col0 / + 38 AS col1 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 24950544d5039d1d5a57fa31a4f89f27

query I rowsort
SELECT col0 * 76 * - 87 AS col0 FROM tab0
----
-158688
-231420
-588468

query I rowsort
SELECT + col2 * col0 + col1 * - col1 * col2 AS col1 FROM tab0
----
-243276
-671744
-9374

query I rowsort
SELECT + col0 * ( + col2 ) AS col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col2 * 6 AS col0 FROM tab0
----
-198
-492
-6

query I rowsort
SELECT DISTINCT col1 + col0 * 93 AS col0 FROM tab0 AS cor0
----
2318
3352
8368

query I rowsort
SELECT - col1 + ( col1 ) * col1 AS col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT DISTINCT - - col1 * + ( + col2 ) + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT - col1 * - cor0.col2 + + col1 + - col2 AS col0 FROM tab1 AS cor0
----
1165
1376
523

query I rowsort
SELECT ALL col0 + 70 FROM tab1 AS cor0
----
134
150
73

query I rowsort
SELECT ALL col0 + + cor0.col2 AS col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL - col0 + 36 AS col0 FROM tab1 AS cor0
----
-28
-44
33

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0, tab0, tab0 cor1
----
972 values hashing to 3a31dab513390ca6bd05c71a3d9c50f0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5328
SELECT - - col1 DIV - ( + 42 ) + col2 col1 FROM tab0 AS cor0
----
-1
31
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5328
SELECT - - col1 / - ( + 42 ) + col2 col1 FROM tab0 AS cor0
----
-1
31
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 78 col1 FROM tab0 AS cor0
----
6708
7098
7566

query I rowsort
SELECT ALL - 75 * 75 FROM tab1
----
-5625
-5625
-5625

query I rowsort
SELECT - ( + col0 ) * - col0 + col0 AS col0 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5332
SELECT col1 DIV col1 + col0 DIV 35 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5332
SELECT col1 / col1 + col0 / 35 AS col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT - ( + col0 ) * 29 * col1 FROM tab0
----
-234871
-59856
-98455

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5334
SELECT col2 * + col2 + CAST( 65 AS SIGNED ) * col1 FROM tab2 cor0
----
2549
2744
4511

skipif mysql # not compatible
query I rowsort label-5334
SELECT col2 * + col2 + CAST ( 65 AS INTEGER ) * col1 FROM tab2 cor0
----
2549
2744
4511

query I rowsort
SELECT DISTINCT + 78 FROM tab2
----
78

query I rowsort
SELECT DISTINCT - 34 FROM tab0
----
-34

query I rowsort
SELECT ALL + 94 + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to db36c12522b791355be00bab9cb81c8e

query I rowsort
SELECT - col2 * col1 + + 62 * 36 AS col2 FROM tab1 cor0
----
1662
828
984

query I rowsort
SELECT + - col1 + ( - col1 ) AS col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT col0 * + 14 * + cor0.col2 + col2 FROM tab0 AS cor0
----
102254
11121
491

query I rowsort
SELECT + col0 * + col0 + - col2 * col0 AS col2 FROM tab0 AS cor0
----
-216
1190
623

onlyif mysql # use DIV operator for integer division
query I rowsort label-5342
SELECT col0 + 44 DIV - 74 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5342
SELECT col0 + 44 / - 74 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + - col1 + col0 * + 17 FROM tab2 AS cor0
----
1267
1326
88

query I rowsort
SELECT ALL + cor0.col1 FROM tab2, tab1, tab1 AS cor0, tab0 AS cor1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT DISTINCT ( + col0 + 17 ) * tab2.col1 * - col0 AS col1 FROM tab2
----
-128928
-437190
-5208

query I rowsort
SELECT + cor0.col0 * - col1 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5347
SELECT ALL - - col1 * + col2 + 3 DIV - col0 AS col0 FROM tab2 cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-5347
SELECT ALL - - col1 * + col2 + 3 / - col0 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - + 32 * - col0 + col0 AS col1 FROM tab1 AS cor0
----
2112
2640
99

query I rowsort
SELECT DISTINCT - - col1 * + cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT DISTINCT col2 * - cor0.col2 * - ( + ( - col1 ) ) FROM tab1 AS cor0
----
-119808
-32490
-75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-5351
SELECT ALL + tab2.col0 DIV + col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5351
SELECT ALL + tab2.col0 / + col0 FROM tab2
----
1
1
1

query I rowsort
SELECT col0 + + tab0.col0 + + col2 AS col1 FROM tab0
----
260
71
81

query I rowsort
SELECT - col0 FROM tab2 WHERE NULL NOT IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5354
SELECT + col1 DIV - col1 + tab2.col1 * - tab2.col0 AS col2 FROM tab2
----
-1344
-218
-4603

skipif mysql # not compatible
query I rowsort label-5354
SELECT + col1 / - col1 + tab2.col1 * - tab2.col0 AS col2 FROM tab2
----
-1344
-218
-4603

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col1 + + tab2.col1 col0 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT ALL + col0 * col0 + col1 AS col2 FROM tab0
----
1322
662
8012

query I rowsort
SELECT + col0 - + col1 AS col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL + col0 + tab1.col0 * - col2 * - 58 AS col2 FROM tab1
----
211648
445520
9399

query I rowsort
SELECT - 68 AS col0 FROM tab2
----
-68
-68
-68

query I rowsort
SELECT DISTINCT - tab0.col2 + - col2 * col0 * - 58 AS col1 FROM tab0
----
2029
423202
45903

query I rowsort
SELECT ALL col1 + col1 * col2 AS col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT - - cor0.col1 * + col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 col2 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL - 68 * + col2 * col1 + col1 FROM tab2
----
-104253
-43911
-56885

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL <= col0 + col0
----

query I rowsort
SELECT DISTINCT - col2 * + tab1.col1 + + col0 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT + col0 * tab1.col1 AS col2 FROM tab1 WHERE NOT col0 NOT IN ( - col1 + + col0 )
----

query I rowsort
SELECT DISTINCT - tab1.col0 - col2 AS col0 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT ALL + tab1.col2 + col1 * - col0 FROM tab1
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5370
SELECT + col2 + tab1.col2 DIV col1 col2 FROM tab1
----
103
56
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5370
SELECT + col2 + tab1.col2 / col1 col2 FROM tab1
----
103
56
62

query I rowsort
SELECT col1 AS col0 FROM tab0 WHERE NULL <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5372
SELECT col2 DIV - col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5372
SELECT col2 / - col1 AS col2 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5373
SELECT + col1 + tab2.col2 DIV col0 FROM tab2
----
17
34
59

skipif mysql # not compatible
query I rowsort label-5373
SELECT + col1 + tab2.col2 / col0 FROM tab2
----
17
34
59

query I rowsort
SELECT DISTINCT + col2 * tab0.col1 + - col1 * - tab0.col1 FROM tab0
----
10234
15743
9506

query I rowsort
SELECT + col0 + tab2.col0 FROM tab2
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5376
SELECT tab0.col0 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5376
SELECT tab0.col0 / col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 - + tab0.col1 col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT col0 * + col2 FROM tab0 WHERE NULL <= ( + col1 * - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - tab0.col0 + + col0 col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + tab2.col0 * - col1 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5381
SELECT ALL - col0 + + col1 DIV + col1 + col2 FROM tab1
----
-6
17
52

skipif mysql # not compatible
query I rowsort label-5381
SELECT ALL - col0 + + col1 / + col1 + col2 FROM tab1
----
-6
17
52

query I rowsort
SELECT DISTINCT + col0 * + tab0.col0 + col0 + + col1 AS col0 FROM tab0
----
1357
686
8101

query I rowsort
SELECT col2 * - tab1.col1 * + col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT - col1 * + col2 + col0 AS col1 FROM tab2
----
-1456
-567
-830

query III rowsort
SELECT ALL * FROM tab1 WHERE ( col2 + + col2 ) NOT IN ( col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL + tab2.col2 * - col0 AS col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + tab2.col1 * + col2 AS col2 FROM tab2
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5388
SELECT ALL + tab1.col1 * + col0 + + col0 DIV + col0 + col0 FROM tab1
----
1121
705
82

skipif mysql # not compatible
query I rowsort label-5388
SELECT ALL + tab1.col1 * + col0 + + col0 / + col0 + col0 FROM tab1
----
1121
705
82

query I rowsort
SELECT ALL + col2 * - col1 + + col1 + - col2 AS col0 FROM tab0
----
-1
-2785
-7453

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT IN ( col2 * + col2 )
----

query I rowsort
SELECT ALL tab0.col1 * - col1 AS col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT + col1 * col1 * - tab1.col1 AS col2 FROM tab1
----
-1000
-17576
-2197

query I rowsort
SELECT ALL + col0 * - col1 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + tab1.col2 - col0 AS col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT - tab2.col1 * col0 * - col0 - - col2 FROM tab2
----
106135
1546
358982

query I rowsort
SELECT DISTINCT + tab1.col1 + col0 + col0 * col1 AS col2 FROM tab1
----
107
1133
714

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col2 col1 FROM tab0
----
53
9
96

query III rowsort
SELECT ALL * FROM tab1 WHERE + col0 + col0 IN ( + col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * - col1 col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - col2 * + col2 * + col2 + col0 * col2 FROM tab1
----
-157302
-181545
-877056

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT col2 + col0 NOT IN ( + col0 + + col0 )
----

query I rowsort
SELECT DISTINCT col0 + + col2 * col0 FROM tab1
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5403
SELECT DISTINCT - col2 + col0 DIV col2 col0 FROM tab1
----
-54
-56
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5403
SELECT DISTINCT - col2 + col0 / col2 col0 FROM tab1
----
-54
-56
-96

query I rowsort
SELECT DISTINCT + 78 AS col2 FROM tab2, tab1, tab2 AS cor0
----
78

query I rowsort
SELECT ALL + 52 FROM tab2, tab1 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

onlyif mysql # use DIV operator for integer division
query I rowsort label-5406
SELECT 20 DIV + col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5406
SELECT 20 / + col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ( col0 ) * + col2 + + col1 + + 99 * - col1 * 19 FROM tab0
----
-160888
-163782
-182325

onlyif mysql # use DIV operator for integer division
query I rowsort label-5408
SELECT 58 + col0 DIV + col2 AS col1 FROM tab0
----
58
59
93

skipif mysql # not compatible
query I rowsort label-5408
SELECT 58 + col0 / + col2 AS col1 FROM tab0
----
58
59
93

query I rowsort
SELECT ALL - - ( + col0 ) * col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + + ( - 97 ) * - col1 AS col0 FROM tab2 cor0
----
1649
3007
5723

query I rowsort
SELECT - cor0.col1 + + cor0.col0 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 318a6997409c5decbbc3333c9d493ad3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5412
SELECT ALL - 9 * - col2 + + CAST( - col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-88
211
647

skipif mysql # not compatible
query I rowsort label-5412
SELECT ALL - 9 * - col2 + + CAST ( - col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-88
211
647

query I rowsort
SELECT - cor0.col2 * + cor0.col2 + - col1 AS col2 FROM tab1 cor0
----
-2942
-3259
-9229

query I rowsort
SELECT ALL - + col1 + col0 AS col0 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5415
SELECT DISTINCT ( col1 ) DIV + 46 + col2 col2 FROM tab0 AS cor0
----
3
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5415
SELECT DISTINCT ( col1 ) / + 46 + col2 col2 FROM tab0 AS cor0
----
3
34
83

query I rowsort
SELECT DISTINCT 39 * + col2 AS col0 FROM tab2 AS cor0
----
1014
1053
1482

query I rowsort
SELECT DISTINCT - + col0 - col2 AS col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + + col2 * col1 + + 63 FROM tab0 cor0
----
160
2901
7525

query I rowsort
SELECT DISTINCT - 74 + col0 FROM tab2 AS cor0
----
-67
4
5

query I rowsort
SELECT DISTINCT - + col1 + + col0 * col1 + + ( col1 * 56 ) AS col2 FROM tab0 cor0
----
13104
6794
8730

query I rowsort
SELECT ALL + 77 + col1 * 58 * + cor0.col0 FROM tab0 AS cor0
----
119789
196987
469819

query I rowsort
SELECT - - 27 + + cor0.col1 FROM tab1 cor0
----
37
40
53

query I rowsort
SELECT ALL ( - col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 31 * col1 * 43 + 40 col1 FROM tab0 AS cor0
----
-114598
-121263
-129261

onlyif mysql # use DIV operator for integer division
query I rowsort label-5425
SELECT - ( col2 ) DIV col1 AS col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-5425
SELECT - ( col2 ) / col1 AS col1 FROM tab1
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 84 + - col2 col2 FROM tab2 AS cor0
----
46
57
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5427
SELECT - col0 DIV + col2 - + 89 FROM tab0 AS cor0
----
-124
-89
-90

skipif mysql # not compatible
query I rowsort label-5427
SELECT - col0 / + col2 - + 89 FROM tab0 AS cor0
----
-124
-89
-90

query I rowsort
SELECT - col2 + cor0.col0 AS col0 FROM tab2 AS cor0
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - col2 col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - - cor0.col2 * 59 AS col0 FROM tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT DISTINCT - col0 * + col1 * + 74 AS col0 FROM tab1 AS cor0
----
-47360
-5772
-76960

query I rowsort
SELECT + col0 + - col0 * - col0 AS col2 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT - col1 + + 69 * 57 FROM tab1 AS cor0
----
3907
3920
3923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5434
SELECT + col1 + - CAST( 55 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-29
-42
-45

skipif mysql # not compatible
query I rowsort label-5434
SELECT + col1 + - CAST ( 55 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-29
-42
-45

query I rowsort
SELECT ALL + col2 + + 30 AS col1 FROM tab0 cor0
----
112
31
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 * + col1 col0 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * + col0 col1 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5438
SELECT ALL - col0 DIV + ( - col2 ) FROM tab0 cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5438
SELECT ALL - col0 / + ( - col2 ) FROM tab0 cor0
----
0
1
35

query I rowsort
SELECT ALL - col1 + 93 FROM tab1 AS cor0
----
67
80
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5440
SELECT DISTINCT 17 + 50 + - col1 * CAST( + col0 AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
-177437
-329248
-736942

skipif mysql # not compatible
query I rowsort label-5440
SELECT DISTINCT 17 + 50 + - col1 * CAST ( + col0 AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
-177437
-329248
-736942

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5441
SELECT - CAST( NULL AS SIGNED ) * 16 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5441
SELECT - CAST ( NULL AS INTEGER ) * 16 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( + ( col2 ) ) * col2 * + col1 FROM tab0 cor0
----
611884
93654
97

query I rowsort
SELECT ALL + - col2 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - - ( - 63 ) FROM tab1 AS cor0
----
-63
-63
-63

query I rowsort
SELECT DISTINCT - ( - col2 ) AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL - col0 * - col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + 19 + + col0 FROM tab0 AS cor0
----
108
43
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-5448
SELECT ALL col2 DIV cor0.col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5448
SELECT ALL col2 / cor0.col0 FROM tab1 AS cor0
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-5449
SELECT - + cor0.col2 * col1 * ( + col1 * - col1 ) + col1 + - col0 DIV + col0 col0 FROM tab1 AS cor0
----
210924
57009
949129

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5449
SELECT - + cor0.col2 * col1 * ( + col1 * - col1 ) + col1 + - col0 / + col0 col0 FROM tab1 AS cor0
----
210924
57009
949129

query I rowsort
SELECT ALL + cor0.col2 * col0 * 37 FROM tab0 AS cor0
----
1295
270026
29304

query I rowsort
SELECT - ( + col2 ) * col0 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + - col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + + 62 FROM tab1 cor0
----
62
62
62

query I rowsort
SELECT + col2 + col0 + - col1 AS col0 FROM tab1 cor0
----
111
163
31

query I rowsort
SELECT ALL - - cor0.col2 + col0 * + col0 * col0 AS col0 FROM tab0 cor0
----
13857
42876
705051

query I rowsort
SELECT + + 13 * col2 AS col2 FROM tab2 AS cor0
----
338
351
494

query I rowsort
SELECT + col0 * - cor0.col1 + 55 * col0 + + col1 FROM tab2 AS cor0
----
-253
199
3019

query I rowsort
SELECT - col0 * 26 FROM tab2 cor0
----
-182
-2028
-2054

query I rowsort
SELECT + col1 * + 8 + ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
153
279
531

query I rowsort
SELECT 67 * 68 FROM tab0 cor0
----
4556
4556
4556

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 + - 37 col1 FROM tab0 AS cor0
----
-13
-2
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 + + cor0.col2 * cor0.col2 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to b948721f21ab72e531668c28626c29d3

query I rowsort
SELECT + + 64 * + cor0.col0 FROM tab0 AS cor0
----
1536
2240
5696

query I rowsort
SELECT 67 + ( - col1 * + col2 ) + + col1 AS col2 FROM tab2 cor0
----
-1408
-562
-739

onlyif mysql # use DIV operator for integer division
query I rowsort label-5465
SELECT DISTINCT + - ( + col1 ) * col2 DIV + 70 AS col0 FROM tab0 AS cor0
----
-1
-106
-40

skipif mysql # not compatible
query I rowsort label-5465
SELECT DISTINCT + - ( + col1 ) * col2 / + 70 AS col0 FROM tab0 AS cor0
----
-1
-106
-40

query I rowsort
SELECT ( - col2 ) * - col2 + - 91 FROM tab0 AS cor0
----
-90
6633
998

query I rowsort
SELECT + 83 * 39 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 638e2cce52463a6393561c2050216f48

query I rowsort
SELECT + col0 * + 94 + tab2.col0 * + ( + col2 + col2 ) FROM tab2
----
1036
11388
13430

query I rowsort
SELECT - ( col0 ) + - col1 AS col2 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT ALL + ( + ( + col2 ) ) + col1 + col2 AS col2 FROM tab2
----
111
85
93

query I rowsort
SELECT ( col2 * col2 ) + col2 + - 46 AS col1 FROM tab2
----
1436
656
710

query I rowsort
SELECT - 68 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 6fbba7db5bccb533a35aa5125a231f88

query I rowsort
SELECT - 39 + cor0.col1 FROM tab0, tab0 cor0
----
9 values hashing to f4eb5a1036e5bd9f1cbd8ed824f35cab

query I rowsort
SELECT + col1 * col2 * - col0 AS col0 FROM tab2
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-5475
SELECT DISTINCT - + ( cor0.col2 ) DIV - col0 col0 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5475
SELECT DISTINCT - + ( cor0.col2 ) / - col0 col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT - - col1 * ( col0 ) AS col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5477
SELECT ALL CAST( col1 AS SIGNED ) * col2 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5477
SELECT ALL CAST ( col1 AS INTEGER ) * col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + 33 AS col1 FROM tab2
----
33

query I rowsort
SELECT ( - tab0.col2 ) FROM tab0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5480
SELECT 23 DIV col1 FROM tab1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5480
SELECT 23 / col1 FROM tab1
----
0
1
2

query I rowsort
SELECT + 29 * + col0 + - 96 * - col1 AS col1 FROM tab2 AS cor0
----
3179
3923
7926

onlyif mysql # use DIV operator for integer division
query I rowsort label-5482
SELECT col2 + col0 * - col1 * col0 + + col1 DIV 95 FROM tab2 AS cor0
----
-106059
-1492
-358930

skipif mysql # not compatible
query I rowsort label-5482
SELECT col2 + col0 * - col1 * col0 + + col1 / 95 FROM tab2 AS cor0
----
-106059
-1492
-358930

query I rowsort
SELECT DISTINCT + 57 * tab1.col2 AS col1 FROM tab1
----
3078
3249
5472

onlyif mysql # use DIV operator for integer division
query I rowsort label-5484
SELECT col1 DIV - ( col1 + 13 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5484
SELECT col1 / - ( col1 + 13 ) FROM tab0
----
0
0
0

query I rowsort
SELECT 61 * + tab0.col0 * col2 AS col1 FROM tab0
----
2135
445178
48312

query I rowsort
SELECT DISTINCT col1 + tab1.col2 AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT cor0.col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT - 38 + + col2 * col2 AS col0 FROM tab0 AS cor0
----
-37
1051
6686

query I rowsort
SELECT cor0.col1 + col0 AS col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT - 95 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT DISTINCT + cor0.col0 + 32 FROM tab1, tab0, tab0 AS cor0
----
121
56
67

query I rowsort
SELECT ALL + cor0.col0 + - col1 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT cor0.col0 + col0 * + cor0.col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT - 33 + + 0 AS col1 FROM tab2 AS cor0
----
-33
-33
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 4 col1 FROM tab2 AS cor0
----
4
4
4

query I rowsort
SELECT col1 + + 23 AS col2 FROM tab1 AS cor0
----
33
36
49

query I rowsort
SELECT + + ( col2 ) * col1 + - 91 FROM tab2 AS cor0
----
1443
555
746

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5499
SELECT cor0.col1 - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5499
SELECT cor0.col1 - CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * + cor0.col0 FROM tab2 cor0
----
49
6084
6241

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 6726a15019c52908f1f1d0df0cd4c1b8

query I rowsort
SELECT DISTINCT + - cor0.col1 * col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - - col0 * ( - cor0.col1 ) AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + 35 AS col2 FROM tab2, tab0 AS cor0
----
35

query I rowsort
SELECT DISTINCT col0 * tab2.col0 AS col2 FROM tab2
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-5507
SELECT DISTINCT - - ( col2 ) + col1 * + 48 + 95 DIV col0 AS col1 FROM tab2 AS cor0
----
1528
2859
855

skipif mysql # not compatible
query I rowsort label-5507
SELECT DISTINCT - - ( col2 ) + col1 * + 48 + 95 / col0 AS col1 FROM tab2 AS cor0
----
1528
2859
855

query I rowsort
SELECT ALL - 46 + + col2 FROM tab1 AS cor0
----
11
50
8

query I rowsort
SELECT ALL - - ( + col0 ) - cor0.col2 * 32 AS col2 FROM tab0 AS cor0
----
-1032
-2535
3

query I rowsort
SELECT DISTINCT + 45 * - col0 FROM tab1 AS cor0
----
-135
-2880
-3600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5511
SELECT DISTINCT - - 58 DIV + col1 - + col0 * + 26 AS col1 FROM tab2 AS cor0
----
-181
-2028
-2051

skipif mysql # not compatible
query I rowsort label-5511
SELECT DISTINCT - - 58 / + col1 - + col0 * + 26 AS col1 FROM tab2 AS cor0
----
-181
-2028
-2051

query I rowsort
SELECT + cor0.col0 + + col0 * + col1 * col1 FROM tab1 AS cor0
----
13600
2031
6464

query I rowsort
SELECT ALL col0 + 39 AS col1 FROM tab2 AS cor0
----
117
118
46

query I rowsort
SELECT 98 * col0 FROM tab0 AS cor0
----
2352
3430
8722

query I rowsort
SELECT + col2 + + col1 + 8 FROM tab1
----
117
75
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-5516
SELECT col0 * - col2 + col0 DIV col0 - + col2 FROM tab2
----
-2053
-215
-3039

skipif mysql # not compatible
query I rowsort label-5516
SELECT col0 * - col2 + col0 / col0 - + col2 FROM tab2
----
-2053
-215
-3039

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5517
SELECT DISTINCT + col2 * - CAST( NULL AS SIGNED ) + col2 AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5517
SELECT DISTINCT + col2 * - CAST ( NULL AS INTEGER ) + col2 AS col0 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 * + col1 col2 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab0, tab2, tab0 cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT DISTINCT - col1 - + col0 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT DISTINCT col0 - ( 5 ) FROM tab0
----
19
30
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-5522
SELECT + 66 DIV - col2 col0 FROM tab1 cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5522
SELECT + 66 / - col2 col0 FROM tab1 cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col0 col0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5524
SELECT col1 * cor0.col1 DIV col2 FROM tab0 AS cor0
----
100
224
9409

skipif mysql # not compatible
query I rowsort label-5524
SELECT col1 * cor0.col1 / col2 FROM tab0 AS cor0
----
100
224
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * + col1 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - + col1 * col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5527
SELECT DISTINCT + + col1 DIV - col1 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5527
SELECT DISTINCT + + col1 / - col1 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT + ( tab0.col0 * col0 ) AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - 20 FROM tab2
----
-20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5530
SELECT 80 DIV + col1 AS col1 FROM tab1
----
3
6
8

skipif mysql # not compatible
query I rowsort label-5530
SELECT 80 / + col1 AS col1 FROM tab1
----
3
6
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5531
SELECT ALL tab0.col2 DIV + tab0.col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5531
SELECT ALL tab0.col2 / + tab0.col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + - col0 + + col1 AS col1 FROM tab1 cor0
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5533
SELECT col0 * - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5533
SELECT col0 * - CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + ( - cor0.col0 ) FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 66 col0 FROM tab2
----
66
66
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 col0 FROM tab0
----
2
62
62

query I rowsort
SELECT ALL 8 AS col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT col0 + + col1 * col0 AS col0 FROM tab0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 + + ( - col2 ) col0 FROM tab2
----
-1482
-702
-756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 77 col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to d7b027bca5d37c67e29013904def8125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 10 col0 FROM tab1
----
10

query I rowsort
SELECT DISTINCT + col2 * 97 + + col1 + col2 FROM tab2 AS cor0
----
2607
2677
3741

query I rowsort
SELECT DISTINCT - - col1 * + col0 + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + + cor0.col1 + + 11 AS col1 FROM tab0 cor0
----
102
108
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5545
SELECT ALL col1 + + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5545
SELECT ALL col1 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + ( col0 ) + - col2 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT col0 + ( col1 * col1 ) FROM tab2
----
3559
368
968

query I rowsort
SELECT ALL - - cor0.col1 * - col0 + col0 * - col1 FROM tab0 AS cor0
----
-16198
-4128
-6790

query I rowsort
SELECT ALL - col0 * cor0.col1 + col2 * col0 * ( col0 ) FROM tab2 AS cor0
----
1106
153582
235815

onlyif mysql # use DIV operator for integer division
query I rowsort label-5550
SELECT DISTINCT - col0 DIV + 97 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5550
SELECT DISTINCT - col0 / + 97 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - col0 * - col0 + - col0 * + cor0.col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * + col1 + + ( + cor0.col2 ) FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL - cor0.col1 + col2 + 42 FROM tab0 AS cor0
----
-11
-54
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-5554
SELECT ALL + - col1 DIV + col1 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-5554
SELECT ALL + - col1 / + col1 col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col0 * + col2 + 54 AS col0 FROM tab0 AS cor0
----
7352
846
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5556
SELECT ALL + col2 + 34 DIV + col1 AS col2 FROM tab2 AS cor0
----
26
28
40

skipif mysql # not compatible
query I rowsort label-5556
SELECT ALL + col2 + 34 / + col1 AS col2 FROM tab2 AS cor0
----
26
28
40

query I rowsort
SELECT - 43 + 17 * col1 AS col2 FROM tab2
----
246
484
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 95 + col0 col0 FROM tab0
----
119
130
184

query I rowsort
SELECT - col1 * + cor0.col0 * col2 AS col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT ( + ( col0 ) ) + CAST ( - col0 AS REAL ) / cor0.col0 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT + 83 + - col1 AS col2 FROM tab2 AS cor0
----
24
52
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( - col0 ) + + col2 col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT col2 * - 67 * col1 FROM tab2 AS cor0
----
-102778
-43282
-56079

query I rowsort
SELECT ALL + ( + col0 ) * - col0 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5565
SELECT + CAST( col1 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-5565
SELECT + CAST ( col1 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + ( - col2 ) * - col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + - 81 * col2 * col1 FROM tab0 AS cor0
----
-229878
-604422
-7857

query I rowsort
SELECT DISTINCT - + 27 + col0 * col0 AS col2 FROM tab0 AS cor0
----
1198
549
7894

query I rowsort
SELECT 27 * col1 + + col1 AS col1 FROM tab1 AS cor0
----
280
364
728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col1 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 86 AS col0 FROM tab0 AS cor0
----
86
86
86

query I rowsort
SELECT DISTINCT 61 + + cor0.col1 + + col0 FROM tab2 AS cor0
----
157
198
99

query I rowsort
SELECT + + 30 AS col0 FROM tab1 AS cor0
----
30
30
30

query I rowsort
SELECT - col0 + + col1 * + col0 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5575
SELECT ALL + col1 DIV + col1 + 16 + - cor0.col1 FROM tab0 AS cor0
----
-69
-74
-80

skipif mysql # not compatible
query I rowsort label-5575
SELECT ALL + col1 / + col1 + 16 + - cor0.col1 FROM tab0 AS cor0
----
-69
-74
-80

query I rowsort
SELECT ALL - + 90 + + col1 FROM tab2 AS cor0
----
-31
-59
-73

query I rowsort
SELECT DISTINCT + 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 + + ( col2 ) * 56 + - 42 col2 FROM tab0 cor0
----
14
1806
4550

query I rowsort
SELECT ALL + 92 - - col2 * cor0.col1 FROM tab2 AS cor0
----
1626
738
929

query I rowsort
SELECT DISTINCT + 94 * cor0.col1 FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT - 15 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT DISTINCT - col1 + tab0.col2 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT col2 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL - cor0.col1 * - 81 FROM tab1 cor0
----
1053
2106
810

query I rowsort
SELECT ALL 35 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT DISTINCT 2 FROM tab1, tab2 AS cor0
----
2

query I rowsort
SELECT - - 29 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT ALL - ( + col2 ) + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ( col1 ) * + col1 + + 55 AS col0 FROM tab0 AS cor0
----
7451
8336
9464

onlyif mysql # use DIV operator for integer division
query I rowsort label-5590
SELECT - + ( 22 ) + - col1 DIV col0 FROM tab1 AS cor0
----
-22
-22
-30

skipif mysql # not compatible
query I rowsort label-5590
SELECT - + ( 22 ) + - col1 / col0 FROM tab1 AS cor0
----
-22
-22
-30

query I rowsort
SELECT + 98 * - col1 FROM tab2 AS cor0
----
-1666
-3038
-5782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 * col2 + 80 * 82 col2 FROM tab1 AS cor0
----
15308
214496
743840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5593
SELECT - + CAST( 7 AS SIGNED ) FROM tab1 AS cor0
----
-7
-7
-7

skipif mysql # not compatible
query I rowsort label-5593
SELECT - + CAST ( 7 AS INTEGER ) FROM tab1 AS cor0
----
-7
-7
-7

query I rowsort
SELECT - - col2 * col1 + col0 AS col1 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-5595
SELECT ALL + 94 DIV - col0 + - CAST( + 61 AS SIGNED ) FROM tab0 AS cor0
----
-62
-63
-64

skipif mysql # not compatible
query I rowsort label-5595
SELECT ALL + 94 / - col0 + - CAST ( + 61 AS INTEGER ) FROM tab0 AS cor0
----
-62
-63
-64

query I rowsort
SELECT ALL + col1 * - col2 - - ( 78 ) FROM tab0 AS cor0
----
-19
-2760
-7384

onlyif mysql # use DIV operator for integer division
query I rowsort label-5597
SELECT DISTINCT - 48 DIV - col1 AS col2 FROM tab1 AS cor0
----
1
3
4

skipif mysql # not compatible
query I rowsort label-5597
SELECT DISTINCT - 48 / - col1 AS col2 FROM tab1 AS cor0
----
1
3
4

query I rowsort
SELECT DISTINCT - + 98 * col0 AS col0 FROM tab0 AS cor0
----
-2352
-3430
-8722

onlyif mysql # use DIV operator for integer division
query I rowsort label-5599
SELECT ALL 17 * col2 DIV col0 AS col2 FROM tab0 AS cor0
----
0
15
23

skipif mysql # not compatible
query I rowsort label-5599
SELECT ALL 17 * col2 / col0 AS col2 FROM tab0 AS cor0
----
0
15
23

query I rowsort
SELECT + + 84 AS col0 FROM tab0 cor0
----
84
84
84

query I rowsort
SELECT - - col1 + col1 * + col2 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL 42 * col1 + col0 FROM tab1 AS cor0
----
1095
484
626

query I rowsort
SELECT ( col1 ) * col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT col0 - col0 AS col2 FROM tab2 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col1 col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - - 8 - - col0 AS col0 FROM tab0 AS cor0
----
32
43
97

query I rowsort
SELECT ALL - + col2 + col1 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - + col1 + 72 * - 45 AS col2 FROM tab2 cor0
----
-3257
-3271
-3299

query I rowsort
SELECT ALL + 86 * col0 FROM tab0
----
2064
3010
7654

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5610
SELECT ALL + - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5610
SELECT ALL + - CAST ( NULL AS REAL ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + + cor0.col0 * col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - - col1 + cor0.col1 * 53 FROM tab2 cor0
----
1674
3186
918

onlyif mysql # use DIV operator for integer division
query I rowsort label-5613
SELECT + cor0.col1 + - 22 DIV + col0 AS col1 FROM tab2 AS cor0
----
17
28
59

skipif mysql # not compatible
query I rowsort label-5613
SELECT + cor0.col1 + - 22 / + col0 AS col1 FROM tab2 AS cor0
----
17
28
59

query I rowsort
SELECT ALL - col1 * - 36 FROM tab1 AS cor0
----
360
468
936

query I rowsort
SELECT ALL + - col1 * + ( 95 * + col1 ) FROM tab2 cor0
----
-27455
-330695
-91295

query I rowsort
SELECT DISTINCT col1 + + cor0.col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - tab2.col0 + - tab2.col0 AS col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT - cor0.col0 * ( col0 ) AS col2 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + col2 * col2 + + col1 FROM tab0 AS cor0
----
1175
6815
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5620
SELECT - ( - col0 ) * + col1 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5620
SELECT - ( - col0 ) * + col1 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col1 + - col0 + + col2 FROM tab1 AS cor0
----
-17
25
3

query I rowsort
SELECT ALL - col0 * 48 FROM tab0 AS cor0
----
-1152
-1680
-4272

query I rowsort
SELECT DISTINCT - + cor0.col0 AS col0 FROM tab1 cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( cor0.col2 ) col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT DISTINCT + - 23 * ( + col1 ) + col0 * col2 FROM tab2 AS cor0
----
-524
2611
671

onlyif mysql # use DIV operator for integer division
query I rowsort label-5626
SELECT + - ( + col0 ) DIV - ( - 43 * + col2 ) FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5626
SELECT + - ( + col0 ) / - ( - 43 * + col2 ) FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5627
SELECT - + 78 + col0 DIV - col0 FROM tab2 AS cor0
----
-79
-79
-79

skipif mysql # not compatible
query I rowsort label-5627
SELECT - + 78 + col0 / - col0 FROM tab2 AS cor0
----
-79
-79
-79

query I rowsort
SELECT ALL col2 + col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT - col2 + - col2 * col2 AS col0 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL 81 * + col0 AS col2 FROM tab1
----
243
5184
6480

query I rowsort
SELECT DISTINCT 87 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
87

query I rowsort
SELECT + 16 AS col0 FROM tab0
----
16
16
16

query I rowsort
SELECT DISTINCT + 35 * col1 AS col0 FROM tab1
----
350
455
910

query I rowsort
SELECT ( + cor0.col2 ) * col2 FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-5635
SELECT ALL 22 DIV tab2.col1 AS col2 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5635
SELECT ALL 22 / tab2.col1 AS col2 FROM tab2
----
0
0
1

query I rowsort
SELECT ALL + 77 * + col2 AS col0 FROM tab2
----
2002
2079
2926

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab1 AS cor1, tab2 cor2
----
972 values hashing to bcf430f79386b43bc4077271fcd15cf0

query I rowsort
SELECT ( col2 ) + + col2 AS col0 FROM tab2
----
52
54
76

query I rowsort
SELECT - ( - col2 ) AS col2 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5640
SELECT ALL + 53 * ( + cor0.col2 ) + col1 * ( - col2 ) DIV 85 col2 FROM tab2 AS cor0
----
1360
1422
2007

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5640
SELECT ALL + 53 * ( + cor0.col2 ) + col1 * ( - col2 ) / 85 col2 FROM tab2 AS cor0
----
1360
1422
2007

query I rowsort
SELECT ALL - col2 * col2 + col2 - - cor0.col0 FROM tab1 AS cor0
----
-2859
-3128
-9040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5642
SELECT DISTINCT + CAST( NULL AS DECIMAL ) AS col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5642
SELECT DISTINCT + CAST ( NULL AS REAL ) AS col1 FROM tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5643
SELECT + + CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5643
SELECT + + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) col0 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT + - 96 AS col2 FROM tab2 AS cor0
----
-96
-96
-96

query I rowsort
SELECT DISTINCT + 74 * - col2 FROM tab1 AS cor0
----
-3996
-4218
-7104

query I rowsort
SELECT ALL + col1 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col2 col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + + 12 AS col1 FROM tab0 AS cor0
----
12
12
12

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0, tab1 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to d10b928ceb6690f7c98bfe77a5adfcac

query I rowsort
SELECT DISTINCT + cor0.col2 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5653
SELECT - col1 + + ( col0 + - col2 * - CAST( NULL AS SIGNED ) ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5653
SELECT - col1 + + ( col0 + - col2 * - CAST ( NULL AS INTEGER ) ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * 7 * - 51 + tab0.col1 * col2 + + 25 * - col2 AS col2 FROM tab0
----
32715
34701
37899

query I rowsort
SELECT ALL - col1 + cor0.col0 AS col2 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT + col1 * col1 + + 95 * + col2 FROM tab2 AS cor0
----
3526
3899
5951

query I rowsort
SELECT cor0.col1 * col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - + col0 + + col2 * - col1 AS col0 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT - + col0 * col1 + 61 + col1 * col1 AS col2 FROM tab1 AS cor0
----
-479
-810
659

query I rowsort
SELECT ALL + - col1 * - ( 75 ) AS col2 FROM tab0 AS cor0
----
6450
6825
7275

onlyif mysql # use DIV operator for integer division
query I rowsort label-5661
SELECT ALL + 28 DIV col2 + + col2 AS col2 FROM tab0 AS cor0
----
29
33
82

skipif mysql # not compatible
query I rowsort label-5661
SELECT ALL + 28 / col2 + + col2 AS col2 FROM tab0 AS cor0
----
29
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5662
SELECT DISTINCT col2 * 28 + cor0.col2 - col2 DIV + col2 FROM tab0 AS cor0
----
2377
28
956

skipif mysql # not compatible
query I rowsort label-5662
SELECT DISTINCT col2 * 28 + cor0.col2 - col2 / + col2 FROM tab0 AS cor0
----
2377
28
956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5663
SELECT ALL + CAST( NULL AS SIGNED ) * + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5663
SELECT ALL + CAST ( NULL AS INTEGER ) * + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 78 FROM tab0 AS cor0
----
78

query I rowsort
SELECT ALL - - 31 + - 87 AS col2 FROM tab0 cor0
----
-56
-56
-56

query I rowsort
SELECT DISTINCT + + 92 - col1 FROM tab0 AS cor0
----
-5
1
6

query I rowsort
SELECT + col0 * + col2 * col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT DISTINCT + col2 * + col2 AS col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT - 89 * - col1 * - cor0.col2 FROM tab0 AS cor0
----
-252582
-664118
-8633

query I rowsort
SELECT ALL - - 51 AS col0 FROM tab2 AS cor0
----
51
51
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 82 * + col1 + col2 col0 FROM tab1 AS cor0
----
1162
2186
877

query I rowsort
SELECT ALL - col0 + + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ( 88 ) AS col2 FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT col1 * - col0 - - col1 AS col2 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + ( col1 ) * + col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5676
SELECT DISTINCT ( col2 ) DIV - col0 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5676
SELECT DISTINCT ( col2 ) / - col0 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT ( col0 ) + col0 + ( cor0.col0 ) AS col2 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT ALL + col2 * 0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - 47 * col2 + + col2 + + cor0.col1 AS col2 FROM tab1 cor0
----
-2458
-2612
-4403

query I rowsort
SELECT ALL - col0 + cor0.col2 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL - + col1 - - col0 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL - col0 + - col1 AS col2 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT col0 + - 99 * + tab2.col2 FROM tab2
----
-2496
-2666
-3683

onlyif mysql # use DIV operator for integer division
query I rowsort label-5684
SELECT + ( + col0 ) DIV col2 + 69 DIV - col0 + - col1 AS col0 FROM tab0 AS cor0
----
-63
-88
-90

skipif mysql # not compatible
query I rowsort label-5684
SELECT + ( + col0 ) / col2 + 69 / - col0 + - col1 AS col0 FROM tab0 AS cor0
----
-63
-88
-90

query I rowsort
SELECT cor0.col1 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 55 * col2 * + col2 + - col1 + 58 col2 FROM tab2 AS cor0
----
-37181
-40068
-79379

query I rowsort
SELECT ALL + ( tab0.col1 + col2 * 64 ) AS col2 FROM tab0
----
161
2198
5339

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5688
SELECT CAST( NULL AS SIGNED ) + col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5688
SELECT CAST ( NULL AS INTEGER ) + col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 54 * + 50 FROM tab0
----
-2700
-2700
-2700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5690
SELECT DISTINCT CAST( - 94 AS SIGNED ) FROM tab0
----
-94

skipif mysql # not compatible
query I rowsort label-5690
SELECT DISTINCT CAST ( - 94 AS INTEGER ) FROM tab0
----
-94

query I rowsort
SELECT ALL + 86 * + col2 FROM tab0
----
2838
7052
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-5692
SELECT ALL 81 DIV 16 AS col2 FROM tab2
----
5
5
5

skipif mysql # not compatible
query I rowsort label-5692
SELECT ALL 81 / 16 AS col2 FROM tab2
----
5
5
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 65 ) col2 FROM tab2
----
-65
-65
-65

query I rowsort
SELECT ALL - - col0 * 5 + col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
1440
93
960

query I rowsort
SELECT DISTINCT - col2 + ( 8 * + col1 ) FROM tab1 cor0
----
154
23
8

query I rowsort
SELECT ALL - col2 + - ( - cor0.col1 ) + col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - col2 * ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + + cor0.col1 * - cor0.col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + col0 * + ( 91 ) * + col1 AS col0 FROM tab2 cor0
----
122213
19747
418782

query I rowsort
SELECT + col2 * - 59 AS col1 FROM tab1 AS cor0
----
-3186
-3363
-5664

query I rowsort
SELECT col1 * + tab2.col1 AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL + tab0.col1 + col0 * - 28 AS col0 FROM tab0
----
-2401
-586
-883

query I rowsort
SELECT 19 * + col0 FROM tab1
----
1216
1520
57

query I rowsort
SELECT col0 * 8 + + ( col1 * - col1 ) AS col0 FROM tab2
----
-2857
-905
343

query I rowsort
SELECT DISTINCT + + 90 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col1 + col1 col1 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT DISTINCT col1 * - ( 58 ) FROM tab2 AS cor0
----
-1798
-3422
-986

onlyif mysql # use DIV operator for integer division
query I rowsort label-5708
SELECT ALL + cor0.col1 DIV 59 + - ( - col0 ) + - col0 * col1 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

skipif mysql # not compatible
query I rowsort label-5708
SELECT ALL + cor0.col1 / 59 + - ( - col0 ) + - col0 * col1 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT + - cor0.col0 + ( - col2 * - col2 ) AS col0 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT DISTINCT - - col0 + - ( - ( col2 ) ) AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - col1 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + ( cor0.col2 ) + col2 * col1 col0 FROM tab1 AS cor0
----
1264
1455
563

query I rowsort
SELECT DISTINCT - - col2 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-5714
SELECT + col2 * col2 DIV + 61 + col0 DIV 5 FROM tab2 AS cor0
----
12
26
38

skipif mysql # not compatible
query I rowsort label-5714
SELECT + col2 * col2 / + 61 + col0 / 5 FROM tab2 AS cor0
----
12
26
38

query I rowsort
SELECT DISTINCT - + cor0.col1 * - 17 FROM tab0 AS cor0
----
1462
1547
1649

onlyif mysql # use DIV operator for integer division
query I rowsort label-5716
SELECT - - col0 DIV - col0 - - cor0.col1 AS col2 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-5716
SELECT - - col0 / - col0 - - cor0.col1 AS col2 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT DISTINCT 53 * tab0.col2 FROM tab0
----
1749
4346
53

query I rowsort
SELECT DISTINCT + 98 FROM tab0
----
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col1 col0 FROM tab0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col1 + + col1 ) col1 FROM tab2
----
0
0
0

query I rowsort
SELECT - - 44 AS col1 FROM tab0 AS cor0
----
44
44
44

query I rowsort
SELECT + + cor0.col2 * - cor0.col0 - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT 10 AS col0 FROM tab1
----
10
10
10

query I rowsort
SELECT + + col2 + col0 * col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT ALL - col0 + + col2 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL - col1 * + col0 + col1 AS col1 FROM tab1 AS cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-5727
SELECT col1 + col1 DIV + col1 AS col2 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5727
SELECT col1 + col1 / + col1 AS col2 FROM tab1
----
11
14
27

query I rowsort
SELECT ALL + + col1 - + col0 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT col1 + ( - col0 + cor0.col2 ) AS col1 FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT ALL - - col1 * + col1 AS col2 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - cor0.col2 + col0 AS col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT ALL + 74 FROM tab2, tab0 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT DISTINCT + - cor0.col1 + - cor0.col2 * col0 AS col0 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL - 31 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

query I rowsort
SELECT ALL 73 FROM tab0
----
73
73
73

query I rowsort
SELECT - 4 AS col2 FROM tab1
----
-4
-4
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5737
SELECT + CAST( col2 AS SIGNED ) DIV cor0.col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5737
SELECT + CAST ( col2 AS INTEGER ) / cor0.col0 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col1 col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5739
SELECT CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5739
SELECT CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - col2 - - col1 FROM tab0
----
53
9
96

query I rowsort
SELECT cor0.col2 * + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col2 * + col2 * col0 FROM tab0 AS cor0
----
26136
35
598436

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE + col1 > + cor0.col2 + col2 - + col2
----
7
31
27
78
59
26

query I rowsort
SELECT - col1 AS col1 FROM tab0 AS cor0 WHERE NOT - col0 / col0 BETWEEN - col2 - + col1 AND NULL
----

query I rowsort
SELECT ALL + col1 * col0 FROM tab2 AS cor0 WHERE - col2 NOT IN ( col1 / col0 + col0 + col0 )
----
1343
217
4602

query I rowsort
SELECT col2 + - col2 + - col0 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - - col2 * + col1 * col0 AS col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + 54 * + col2 FROM tab2
----
1404
1458
2052

query I rowsort
SELECT col2 + + col0 * + col1 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT col2 + col0 * + col2 AS col1 FROM tab2 AS cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col1 col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT - col1 + + col1 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 + - col0 + col0 * - col1 AS col2 FROM tab2 AS cor0
----
-1501
-231
-4758

query I rowsort
SELECT - cor0.col0 * col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col2 - cor0.col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - 39 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * + col1 + + ( col1 + col1 ) col0 FROM tab1 AS cor0
----
-143
-624
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5758
SELECT DISTINCT + - col0 + ( col0 ) DIV - col2 FROM tab1 AS cor0
----
-3
-65
-80

skipif mysql # not compatible
query I rowsort label-5758
SELECT DISTINCT + - col0 + ( col0 ) / - col2 FROM tab1 AS cor0
----
-3
-65
-80

query I rowsort
SELECT - + col1 * ( + col2 ) FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + col1 + tab2.col2 AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT DISTINCT + ( 43 ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
43

query I rowsort
SELECT - + 44 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 9 ) col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 65 col1 FROM tab2
----
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5765
SELECT DISTINCT - - CAST( NULL AS SIGNED ) FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5765
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT + 55 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
55

query I rowsort
SELECT + tab1.col0 + tab1.col1 AS col0 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5768
SELECT - - col0 DIV - col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-5768
SELECT - - col0 / - col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT tab1.col2 + + col2 AS col1 FROM tab1
----
108
114
192

query I rowsort
SELECT ALL col1 * - 16 FROM tab2
----
-272
-496
-944

query I rowsort
SELECT + col0 - tab2.col0 * 79 AS col2 FROM tab2
----
-546
-6084
-6162

query I rowsort
SELECT ALL 94 * - 91 FROM tab2, tab2 AS cor0
----
9 values hashing to 8393a63403011ce4b966063172cf0333

query I rowsort
SELECT ALL col0 * - 44 * + col0 FROM tab0
----
-25344
-348524
-53900

query I rowsort
SELECT ALL + 17 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5775
SELECT ALL + col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5775
SELECT ALL + col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 + + col1 AS col1 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - 57 col1 FROM tab0
----
-24
-56
25

query I rowsort
SELECT ALL cor1.col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-5779
SELECT DISTINCT - col0 - - col0 DIV tab2.col0 AS col2 FROM tab2
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-5779
SELECT DISTINCT - col0 - - col0 / tab2.col0 AS col2 FROM tab2
----
-6
-77
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5780
SELECT - CAST( NULL AS SIGNED ) * + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5780
SELECT - CAST ( NULL AS INTEGER ) * + col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + col2 ) + col1 FROM tab0
----
119
173
98

query I rowsort
SELECT 6 * - 92 + + tab2.col1 FROM tab2
----
-493
-521
-535

query I rowsort
SELECT + - ( col2 ) * + col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + + 27 + col2 FROM tab0 cor0
----
109
28
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 col1 FROM tab1
----
109
67
80

query I rowsort
SELECT col0 * ( + col2 ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - col2 * cor0.col2 * - col2 + - 5 FROM tab0 AS cor0
----
-4
35932
551363

query I rowsort
SELECT + col2 * + col2 + - col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT ALL 74 FROM tab2 cor0
----
74
74
74

query I rowsort
SELECT DISTINCT 89 + col2 FROM tab0 AS cor0
----
122
171
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( - col0 ) * ( - col2 ) + + col1 col0 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-5792
SELECT DISTINCT + + ( + cor0.col0 ) DIV ( + col0 ) FROM tab2 cor0
----
1

skipif mysql # not compatible
query I rowsort label-5792
SELECT DISTINCT + + ( + cor0.col0 ) / ( + col0 ) FROM tab2 cor0
----
1

query I rowsort
SELECT ALL 99 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1683
-3069
-5841

onlyif mysql # use DIV operator for integer division
query I rowsort label-5794
SELECT DISTINCT + col0 DIV col2 col0 FROM tab1 AS cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5794
SELECT DISTINCT + col0 / col2 col0 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT ALL - + col1 + cor0.col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5796
SELECT + CAST( + 21 AS SIGNED ) * + col0 FROM tab2
----
147
1638
1659

skipif mysql # not compatible
query I rowsort label-5796
SELECT + CAST ( + 21 AS INTEGER ) * + col0 FROM tab2
----
147
1638
1659

query I rowsort
SELECT DISTINCT - 12 * col0 + 43 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1085
2759
744

query I rowsort
SELECT DISTINCT - + 30 AS col2 FROM tab2 cor0
----
-30

query I rowsort
SELECT ALL + + col0 * col1 + - ( - col2 ) * col1 FROM tab0 cor0
----
15561
3492
4902

query I rowsort
SELECT ALL + - col2 * col0 + 57 * col0 FROM tab2 AS cor0
----
1501
210
2418

query I rowsort
SELECT - 77 AS col1 FROM tab2 AS cor0
----
-77
-77
-77

query I rowsort
SELECT DISTINCT - 45 * cor0.col1 FROM tab1 AS cor0
----
-1170
-450
-585

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL 28 FROM tab2 AS cor0
----
28
28
28

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2 cor2
----
-10
-13
-26

query I rowsort
SELECT + 3 + col2 AS col0 FROM tab2 AS cor0
----
29
30
41

query I rowsort
SELECT - col0 + + col0 AS col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5808
SELECT col0 + + col0 DIV - 21 FROM tab2 AS cor0
----
7
75
76

skipif mysql # not compatible
query I rowsort label-5808
SELECT col0 + + col0 / - 21 FROM tab2 AS cor0
----
7
75
76

query I rowsort
SELECT + - col0 + ( - col2 ) * + col1 FROM tab0 AS cor0
----
-132
-2862
-7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 + - cor0.col0 * + col1 col1 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT + - col1 + + 29 AS col2 FROM tab1 cor0
----
16
19
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5812
SELECT ALL + col1 * col0 + + 70 * col2 DIV col1 FROM tab0 cor0
----
2090
3395
8162

skipif mysql # not compatible
query I rowsort label-5812
SELECT ALL + col1 * col0 + + 70 * col2 / col1 FROM tab0 cor0
----
2090
3395
8162

query I rowsort
SELECT - col0 + 75 FROM tab2 cor0
----
-3
-4
68

query I rowsort
SELECT ALL + - col2 * col1 + + cor0.col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT - col2 + col2 * col1 AS col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT tab1.col0 * col1 + + 77 + + 6 * - col0 AS col1 FROM tab1
----
137
333
637

query I rowsort
SELECT ALL - 2 * col0 + - ( col2 * col0 ) FROM tab0
----
-105
-7476
-840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5818
SELECT col2 DIV - col0 + col1 FROM tab0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-5818
SELECT col2 / - col0 + col1 FROM tab0
----
85
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 61 + col0 col2 FROM tab0
----
150
85
96

query I rowsort
SELECT - ( cor0.col2 ) * col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col1 * + 52 * col0 FROM tab1 AS cor0
----
-33280
-4056
-54080

query I rowsort
SELECT DISTINCT ( + col1 ) * col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT ALL - 58 AS col1 FROM tab2 cor0
----
-58
-58
-58

query I rowsort
SELECT + - col0 + - col0 * + col2 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT ( - col2 ) + - col0 * - col2 + col1 * + col0 * col1 AS col0 FROM tab2 AS cor0
----
25795
273520
6889

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - 31 col0 FROM tab1 AS cor0
----
-18
-21
-5

query I rowsort
SELECT ALL ( col2 ) * col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-5828
SELECT - col2 * col2 - col2 DIV - 79 FROM tab1 AS cor0
----
-2916
-3249
-9215

skipif mysql # not compatible
query I rowsort label-5828
SELECT - col2 * col2 - col2 / - 79 FROM tab1 AS cor0
----
-2916
-3249
-9215

query I rowsort
SELECT + col2 * + 16 AS col1 FROM tab1 AS cor0
----
1536
864
912

query I rowsort
SELECT ALL col1 + - col1 * col2 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 * col2 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - - ( col0 ) FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 51 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

query I rowsort
SELECT - cor0.col1 * 54 FROM tab2 AS cor0
----
-1674
-3186
-918

query I rowsort
SELECT ALL + col0 + - col1 * + col2 AS col2 FROM tab2 cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5836
SELECT ALL - - CAST( - col0 AS SIGNED ) * + col1 * + ( col2 * col0 ) AS col0 FROM tab2 cor0
----
-4031686
-41013
-9332856

skipif mysql # not compatible
query I rowsort label-5836
SELECT ALL - - CAST ( - col0 AS INTEGER ) * + col1 * + ( col2 * col0 ) AS col0 FROM tab2 cor0
----
-4031686
-41013
-9332856

query I rowsort
SELECT + 19 * - 3 FROM tab1 AS cor0
----
-57
-57
-57

query I rowsort
SELECT + - 16 + + cor0.col0 * + col1 AS col0 FROM tab0 AS cor0
----
2048
3379
8083

query I rowsort
SELECT - tab0.col2 + cor0.col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 5e52e24329c96ca96802109e5c7c8bdf

query I rowsort
SELECT DISTINCT - + col2 * + 52 * + cor0.col1 + ( cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-147552
-387935
-5009

query I rowsort
SELECT - - ( col1 ) + + col1 - ( + 14 ) FROM tab2 AS cor0
----
104
20
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5842
SELECT DISTINCT + tab0.col2 + ( + col0 * CAST( NULL AS SIGNED ) ) AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5842
SELECT DISTINCT + tab0.col2 + ( + col0 * CAST ( NULL AS INTEGER ) ) AS col0 FROM tab0
----
NULL

query I rowsort
SELECT 76 FROM tab2, tab1 cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 67 * + col0 col0 FROM tab2
----
469
5226
5293

query I rowsort
SELECT - - 94 * 30 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 7b8184a0b27953c011c3006d251fc675

query IIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 WHERE NULL NOT IN ( - cor0.col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 7 col0 FROM tab0 AS cor0
----
-7
-7
-7

query I rowsort
SELECT - col2 + + col1 * + col0 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT - - 67 AS col1 FROM tab0 AS cor0
----
67
67
67

query I rowsort
SELECT - ( - ( col1 ) ) * 22 AS col1 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT ALL col1 + - col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT + - cor0.col1 * + col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - ( col0 ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 38 col2 FROM tab2, tab0 AS cor0
----
38

query I rowsort
SELECT + - col2 * col1 * ( - 93 ) AS col0 FROM tab0 AS cor0
----
263934
693966
9021

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 11 AS col0 FROM tab2
----
11
11
11

query I rowsort
SELECT + 75 AS col0 FROM tab0
----
75
75
75

query I rowsort
SELECT ( ( - col1 ) ) AS col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT col1 * + 54 FROM tab0 AS cor0
----
4644
4914
5238

query I rowsort
SELECT + + col0 + col2 * + col2 AS col2 FROM tab0 AS cor0
----
1113
36
6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + - ( 84 ) col2 FROM tab2 AS cor0
----
-110
-111
-122

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + col0 + - col1 * + col0 col2 FROM tab0 AS cor0
----
-1954
-3263
-7919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5864
SELECT col1 + CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-5864
SELECT col1 + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT col0 + col1 + + 85 * - cor0.col2 FROM tab0 AS cor0
----
-2695
-6790
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5866
SELECT - col2 + - CAST( NULL AS SIGNED ) * col2 * col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5866
SELECT - col2 + - CAST ( NULL AS INTEGER ) * col2 * col2 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * ( col2 ) AS col0 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5868
SELECT - col2 + CAST( NULL AS DECIMAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5868
SELECT - col2 + CAST ( NULL AS REAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col0 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + col1 * 1 AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT col1 * ( 9 ) FROM tab2
----
153
279
531

query I rowsort
SELECT ALL - ( cor0.col2 ) + col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT 24 * col2 AS col1 FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT DISTINCT + col1 * col2 + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + col2 * + col0 + col0 AS col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL - 17 + - ( col1 + - col0 ) * col1 FROM tab1 cor0
----
-615
523
854

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col0 + - col1 col0 FROM tab0 AS cor0
----
-133
-143
-262

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * 54 * col1 col2 FROM tab1 AS cor0
----
30780
67392
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-5879
SELECT ALL - cor0.col2 DIV + ( - cor0.col0 ) col0 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5879
SELECT ALL - cor0.col2 / + ( - cor0.col0 ) col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT + - 18 + col2 FROM tab2 AS cor0
----
20
8
9

query I rowsort
SELECT ( + 81 * cor0.col1 ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to d978491f1f731dfbcdb7a39b597dea4a

query I rowsort
SELECT - col1 + + 84 AS col1 FROM tab0
----
-13
-2
-7

query I rowsort
SELECT + 35 - tab0.col1 FROM tab0
----
-51
-56
-62

query I rowsort
SELECT - 23 FROM tab0, tab2 AS cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT DISTINCT + ( 46 ) * col2 AS col1 FROM tab2
----
1196
1242
1748

query I rowsort
SELECT 25 AS col1 FROM tab0
----
25
25
25

query I rowsort
SELECT ALL + ( - 92 ) + col0 AS col0 FROM tab0
----
-3
-57
-68

query I rowsort
SELECT - col1 + 2 + col1 FROM tab2 AS cor0
----
2
2
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5889
SELECT ALL - CAST( + 0 AS SIGNED ) FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5889
SELECT ALL - CAST ( + 0 AS INTEGER ) FROM tab0 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5890
SELECT + - ( cor0.col2 ) + + cor0.col2 * CAST( NULL AS DECIMAL ) * + 46 + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5890
SELECT + - ( cor0.col2 ) + + cor0.col2 * CAST ( NULL AS REAL ) * + 46 + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5891
SELECT + + col2 DIV cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5891
SELECT + + col2 / cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT col0 + + col2 + col2 FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT - 54 * + cor0.col0 AS col0 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 83f28bdaa83b4ed36afa1e76bda73009

onlyif mysql # use DIV operator for integer division
query I rowsort label-5894
SELECT - ( - col0 ) DIV tab1.col0 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5894
SELECT - ( - col0 ) / tab1.col0 AS col1 FROM tab1
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5895
SELECT + - col0 * + col2 + CAST( NULL AS SIGNED ) * - col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5895
SELECT + - col0 * + col2 + CAST ( NULL AS INTEGER ) * - col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col0 * col1 - - cor0.col2 * - col0 FROM tab2 AS cor0
----
-406
-4345
-6630

query I rowsort
SELECT ( col1 ) + - ( - col1 ) AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - col0 - - col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - col1 * - col0 + 75 + col1 AS col2 FROM tab1 AS cor0
----
1128
179
725

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + ( + col2 ) col2 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5901
SELECT - - col0 * + CAST( cor0.col0 * col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1323
158184
237158

skipif mysql # not compatible
query I rowsort label-5901
SELECT - - col0 * + CAST ( cor0.col0 * col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1323
158184
237158

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 61a671f1b5048e339ad9838f68ebbba4

query I rowsort
SELECT col1 + col2 + + col1 * - col0 FROM tab1
----
-573
-931
2

query I rowsort
SELECT ALL + col1 + 38 FROM tab0 AS cor0
----
124
129
135

onlyif mysql # use DIV operator for integer division
query I rowsort label-5905
SELECT + col0 DIV + col1 + - ( cor0.col2 ) DIV col1 FROM tab1 AS cor0
----
-1
-2
1

skipif mysql # not compatible
query I rowsort label-5905
SELECT + col0 / + col1 + - ( cor0.col2 ) / col1 FROM tab1 AS cor0
----
-1
-2
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5906
SELECT DISTINCT - cor0.col2 + col0 DIV - 86 AS col2 FROM tab2 cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-5906
SELECT DISTINCT - cor0.col2 + col0 / - 86 AS col2 FROM tab2 cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5907
SELECT DISTINCT + col1 + ( col0 * col1 ) + + col2 DIV + ( col1 ) FROM tab1 cor0
----
106
1060
655

skipif mysql # not compatible
query I rowsort label-5907
SELECT DISTINCT + col1 + ( col0 * col1 ) + + col2 / + ( col1 ) FROM tab1 cor0
----
106
1060
655

query I rowsort
SELECT cor0.col2 + + ( - col2 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col0 * col2 - col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT ALL - col2 + col1 + 66 AS col1 FROM tab0 cor0
----
119
162
75

query I rowsort
SELECT + 75 * col2 * - 72 + - 13 FROM tab0 AS cor0
----
-178213
-442813
-5413

onlyif mysql # use DIV operator for integer division
query I rowsort label-5912
SELECT DISTINCT cor0.col2 * + col1 * col2 + + 78 DIV + col0 AS col1 FROM tab1 cor0
----
119808
32491
75842

skipif mysql # not compatible
query I rowsort label-5912
SELECT DISTINCT cor0.col2 * + col1 * col2 + + 78 / + col0 AS col1 FROM tab1 cor0
----
119808
32491
75842

query I rowsort
SELECT DISTINCT + col1 + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + col0 + + col1 AS col2 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT + 1 + col2 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1443
-675
-728

query I rowsort
SELECT DISTINCT - col1 - col0 * 70 FROM tab0 AS cor0
----
-1766
-2547
-6321

onlyif mysql # use DIV operator for integer division
query I rowsort label-5917
SELECT + col2 + col1 DIV - col1 AS col1 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-5917
SELECT + col2 + col1 / - col1 AS col1 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT ALL - - col1 * + col2 * col2 AS col0 FROM tab1 AS cor0
----
119808
32490
75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 77 + col2 col2 FROM tab2 AS cor0
----
103
104
115

query I rowsort
SELECT ALL - - col2 * + col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-5921
SELECT DISTINCT + - col1 + + col1 DIV col2 AS col2 FROM tab0 AS cor0
----
-84
-90
0

skipif mysql # not compatible
query I rowsort label-5921
SELECT DISTINCT + - col1 + + col1 / col2 AS col2 FROM tab0 AS cor0
----
-84
-90
0

query I rowsort
SELECT - col1 * - col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL + 10 + + ( col2 ) * + 80 - col1 FROM tab0
----
-7
2564
6479

query I rowsort
SELECT DISTINCT col2 * 2 + col0 * col1 - col1 * col2 AS col0 FROM tab1
----
-1218
-16
184

onlyif mysql # use DIV operator for integer division
query I rowsort label-5925
SELECT DISTINCT 13 DIV - col0 - - tab1.col1 * 46 FROM tab1
----
1192
460
598

skipif mysql # not compatible
query I rowsort label-5925
SELECT DISTINCT 13 / - col0 - - tab1.col1 * 46 FROM tab1
----
1192
460
598

query I rowsort
SELECT - - cor0.col0 + - cor0.col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + - 97 FROM tab0 AS cor0
----
-97

query I rowsort
SELECT cor0.col0 + col0 * - 43 FROM tab1 AS cor0
----
-126
-2688
-3360

query I rowsort
SELECT ALL + col2 * - col1 + + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT - col1 + - 58 + + 29 AS col1 FROM tab1 AS cor0
----
-39
-42
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-5931
SELECT col0 + - col2 DIV col0 FROM tab0 cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-5931
SELECT col0 + - col2 / col0 FROM tab0 cor0
----
23
35
89

query I rowsort
SELECT + 72 AS col2 FROM tab0
----
72
72
72

query I rowsort
SELECT ALL + col0 * + col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT col2 + - 44 FROM tab0 AS cor0
----
-11
-43
38

query I rowsort
SELECT col1 * - ( col1 ) - + col0 AS col1 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT + 29 * col0 FROM tab0
----
1015
2581
696

query I rowsort
SELECT 28 + col1 + + col2 FROM tab0
----
126
147
201

query I rowsort
SELECT DISTINCT - ( + col0 ) + - col2 AS col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT DISTINCT tab2.col1 - 18 FROM tab2
----
-1
13
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5940
SELECT CAST( NULL AS SIGNED ) + tab0.col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5940
SELECT CAST ( NULL AS INTEGER ) + tab0.col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * col2 - col0 FROM tab0
----
2814
62
7373

query I rowsort
SELECT ALL + col2 * col0 + - col0 * + col1 + 20 * - col2 * + col2 AS col2 FROM tab0
----
-135281
-23052
-3380

query I rowsort
SELECT col2 * - 78 FROM tab0
----
-2574
-6396
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5944
SELECT - 50 DIV - col2 col1 FROM tab0 AS cor0
----
0
1
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5944
SELECT - 50 / - col2 col1 FROM tab0 AS cor0
----
0
1
50

query I rowsort
SELECT col1 - cor0.col0 * cor0.col0 FROM tab2 cor0
----
-18
-6025
-6224

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5946
SELECT ALL + CAST( - col2 AS SIGNED ) * + col1 + - 93 col0 FROM tab1 AS cor0
----
-1341
-1497
-663

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5946
SELECT ALL + CAST ( - col2 AS INTEGER ) * + col1 + - 93 col0 FROM tab1 AS cor0
----
-1341
-1497
-663

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col1 AS REAL ) + col0 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - + 73 AS col2 FROM tab2 AS cor0
----
-73

query I rowsort
SELECT + cor0.col0 + col2 * 11 FROM tab1 AS cor0
----
1136
597
691

query I rowsort
SELECT ALL ( - 20 ) FROM tab0, tab1 AS cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

onlyif mysql # use DIV operator for integer division
query I rowsort label-5951
SELECT DISTINCT + + 32 DIV + cor0.col1 FROM tab1 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5951
SELECT DISTINCT + + 32 / + cor0.col1 FROM tab1 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT + 86 * - col1 FROM tab2 AS cor0
----
-1462
-2666
-5074

query I rowsort
SELECT - + 35 + - col0 FROM tab0 AS cor0
----
-124
-59
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5954
SELECT col1 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5954
SELECT col1 / cor0.col0 AS col1 FROM tab2 AS cor0
----
0
0
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5955
SELECT + tab0.col2 + CAST( NULL AS SIGNED ) col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5955
SELECT + tab0.col2 + CAST ( NULL AS INTEGER ) col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + ( - tab0.col2 ) AS col1 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL + - col0 * ( + 3 ) - + col2 FROM tab1 AS cor0
----
-249
-336
-63

query I rowsort
SELECT + col1 + - 42 FROM tab1 AS cor0
----
-16
-29
-32

query I rowsort
SELECT ALL + col1 * - 23 * - col2 FROM tab0 AS cor0
----
171626
2231
65274

query I rowsort
SELECT col0 + + 89 AS col1 FROM tab0 AS cor0
----
113
124
178

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5961
SELECT DISTINCT - + col1 + + CAST( NULL AS SIGNED ) / - col2 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5961
SELECT DISTINCT - + col1 + + CAST ( NULL AS INTEGER ) / - col2 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - col2 - + col2 AS col1 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT + + cor0.col2 + + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + col1 * 75 + ( - cor0.col0 ) FROM tab1 cor0
----
1947
686
895

query I rowsort
SELECT ALL + col0 + 63 - + col0 AS col1 FROM tab0 AS cor0
----
63
63
63

query I rowsort
SELECT + 78 * - cor1.col2 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7c715e74d4685746aefacec754eeb08e

onlyif mysql # use DIV operator for integer division
query I rowsort label-5967
SELECT DISTINCT - col2 DIV cor0.col0 col1 FROM tab0 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5967
SELECT DISTINCT - col2 / cor0.col0 col1 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT ( 63 ) + col2 FROM tab1 AS cor0
----
117
120
159

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col2 AS REAL ) col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5970
SELECT CAST( NULL AS DECIMAL ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5970
SELECT CAST ( NULL AS REAL ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5971
SELECT DISTINCT - col0 - col1 DIV col2 AS col1 FROM tab0 cor0
----
-132
-26
-90

skipif mysql # not compatible
query I rowsort label-5971
SELECT DISTINCT - col0 - col1 / col2 AS col1 FROM tab0 cor0
----
-132
-26
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5972
SELECT DISTINCT CAST( col0 AS SIGNED ) DIV col2 AS col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5972
SELECT DISTINCT CAST ( col0 AS INTEGER ) / col2 AS col2 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT ALL + 86 + col0 * col2 AS col0 FROM tab1 cor0
----
248
3734
7766

query I rowsort
SELECT DISTINCT - 89 + col1 FROM tab0 AS cor0
----
-3
2
8

query I rowsort
SELECT DISTINCT col2 * - 51 - + col0 AS col1 FROM tab2 AS cor0
----
-1384
-1404
-2017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 34 col0 FROM tab2 AS cor0
----
34
34
34

query I rowsort
SELECT DISTINCT + + 19 FROM tab2 cor0
----
19

query I rowsort
SELECT ALL - ( + ( + col2 ) ) * col2 * - ( + col2 ) AS col2 FROM tab2 AS cor0
----
17576
19683
54872

query I rowsort
SELECT DISTINCT + 91 + - 7 FROM tab0 AS cor0
----
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5980
SELECT + CAST( - 37 AS SIGNED ) FROM tab2 AS cor0
----
-37
-37
-37

skipif mysql # not compatible
query I rowsort label-5980
SELECT + CAST ( - 37 AS INTEGER ) FROM tab2 AS cor0
----
-37
-37
-37

query I rowsort
SELECT DISTINCT + - tab0.col2 AS col0 FROM tab0, tab1, tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL 60 AS col1 FROM tab2
----
60
60
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5983
SELECT DISTINCT + col0 * - col2 + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5983
SELECT DISTINCT + col0 * - col2 + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 + col2 col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + col0 + + col1 * ( cor0.col2 ) FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT col1 + + 94 AS col0 FROM tab1 AS cor0
----
104
107
120

query I rowsort
SELECT - col2 * ( ( + col0 ) ) AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5988
SELECT + col2 + - col0 DIV - col2 col1 FROM tab0 AS cor0
----
33
36
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5988
SELECT + col2 + - col0 / - col2 col1 FROM tab0 AS cor0
----
33
36
83

query I rowsort
SELECT + + col2 * + 39 AS col1 FROM tab0 AS cor0
----
1287
3198
39

query I rowsort
SELECT ALL - 39 AS col2 FROM tab1
----
-39
-39
-39

query I rowsort
SELECT col2 * + ( col1 ) + + col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - + col2 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT + + ( - ( col0 - + col1 - - col1 - - col0 ) ) * cor0.col2 + 7 - col1 FROM tab2 cor0
----
-402
-4108
-6014

query I rowsort
SELECT DISTINCT - - col1 * 24 - cor0.col0 * + col2 AS col1 FROM tab0 AS cor0
----
-5114
1272
2293

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5995
SELECT - + CAST( NULL AS SIGNED ) * col1 + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5995
SELECT - + CAST ( NULL AS INTEGER ) * col1 + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * + 11 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-10
-330
-820

query I rowsort
SELECT - + 80 * col1 * - col2 - 30 * cor0.col0 FROM tab0 cor0
----
226320
594290
6710

onlyif mysql # use DIV operator for integer division
query I rowsort label-5998
SELECT + - 87 * - col0 DIV - col0 - ( - col0 ) AS col1 FROM tab1 cor0
----
-23
-7
-84

skipif mysql # not compatible
query I rowsort label-5998
SELECT + - 87 * - col0 / - col0 - ( - col0 ) AS col1 FROM tab1 cor0
----
-23
-7
-84

query I rowsort
SELECT ALL - col1 * col2 + cor0.col2 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6000
SELECT + + CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6000
SELECT + + CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6001
SELECT + col2 * col0 + col2 - ( + col0 + - col1 ) * CAST( 45 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
2826
3615
7470

skipif mysql # not compatible
query I rowsort label-6001
SELECT + col2 * col0 + col2 - ( + col0 + - col1 ) * CAST ( 45 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
2826
3615
7470

query I rowsort
SELECT + col2 + col2 * col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT - cor1.col2 AS col2 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT DISTINCT + col0 * 58 + 73 FROM tab1
----
247
3785
4713

query I rowsort
SELECT - 51 + + col0 * - cor0.col0 * - col0 FROM tab1 AS cor0
----
-24
262093
511949

query I rowsort
SELECT + 31 + col0 FROM tab0 AS cor0
----
120
55
66

query I rowsort
SELECT + + 18 + col1 AS col0 FROM tab0 AS cor0
----
104
109
115

query I rowsort
SELECT - col1 * col2 + + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ( 52 ) AS col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT ( + col1 ) AS col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT + 27 * + 41 FROM tab1
----
1107

query I rowsort
SELECT col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6013
SELECT DISTINCT + - 6 * col2 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6013
SELECT DISTINCT + - 6 * col2 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col2 - + cor0.col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6015
SELECT ALL - col0 DIV col1 AS col0 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6015
SELECT ALL - col0 / col1 AS col0 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT + - col1 * col1 - col1 * col2 FROM tab0 cor0
----
-10234
-15743
-9506

query I rowsort
SELECT DISTINCT + col2 * - col1 AS col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - + ( + col2 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6019
SELECT - col2 * + col1 + col0 DIV col1 col2 FROM tab2 AS cor0
----
-1533
-642
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6019
SELECT - col2 * + col1 + col0 / col1 col2 FROM tab2 AS cor0
----
-1533
-642
-837

query I rowsort
SELECT ALL ( + col0 ) * col0 FROM tab2
----
49
6084
6241

query I rowsort
SELECT DISTINCT - ( - 60 ) AS col2 FROM tab1
----
60

query I rowsort
SELECT ALL - 9 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
-153
-279
-531

query I rowsort
SELECT DISTINCT + 61 * col2 AS col2 FROM tab1
----
3294
3477
5856

query I rowsort
SELECT + cor0.col0 * 71 + cor0.col1 FROM tab0 AS cor0
----
1790
2582
6410

query I rowsort
SELECT ALL + col0 * + 29 AS col0 FROM tab2 AS cor0
----
203
2262
2291

query I rowsort
SELECT + col1 * tab0.col1 AS col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT - col2 - + col2 * - col2 AS col1 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT ALL - col1 * 95 + - cor0.col2 * cor0.col2 FROM tab2 AS cor0
----
-3059
-3674
-6281

query I rowsort
SELECT DISTINCT ( 70 ) AS col1 FROM tab2 AS cor0
----
70

query I rowsort
SELECT DISTINCT - cor0.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT col0 + - col1 - + col0 AS col2 FROM tab0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 44 col2 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 9c887509d218271b9365009eba440976

query I rowsort
SELECT - - 41 * + col0 AS col0 FROM tab2 AS cor0
----
287
3198
3239

query I rowsort
SELECT - ( col1 ) * col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT + ( - col2 ) + col1 + col1 FROM tab1
----
-2
-37
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 88 col1 FROM tab2 AS cor0
----
88
88
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 82 + cor0.col0 col1 FROM tab2 cor0
----
-567
-6318
-6399

query IIIIII rowsort
SELECT * FROM tab2, tab1 cor0 WHERE NOT NULL < NULL
----

query I rowsort
SELECT DISTINCT + col0 + + col0 * - 38 FROM tab2
----
-259
-2886
-2923

query I rowsort
SELECT + col1 * col1 + - 59 FROM tab1 AS cor0
----
110
41
617

query I rowsort
SELECT DISTINCT - col2 + ( col1 ) * col2 AS col1 FROM tab2 AS cor0
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-6042
SELECT ALL + - col2 DIV col2 + col2 + col0 FROM tab1 AS cor0
----
120
175
56

skipif mysql # not compatible
query I rowsort label-6042
SELECT ALL + - col2 / col2 + col2 + col0 FROM tab1 AS cor0
----
120
175
56

query I rowsort
SELECT col2 + 8 FROM tab0 AS cor0
----
41
9
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 * - col2 - col0 col1 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT + cor0.col0 + + cor0.col1 + col2 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT DISTINCT + col2 + - 10 * col1 AS col2 FROM tab1 AS cor0
----
-206
-34
-43

query I rowsort
SELECT ALL + cor0.col2 * 56 + - col2 AS col1 FROM tab1 AS cor0
----
2970
3135
5280

query I rowsort
SELECT ALL - col2 - 67 AS col2 FROM tab0 AS cor0
----
-100
-149
-68

query I rowsort
SELECT ALL - col1 * + 18 + + col0 FROM tab0 AS cor0
----
-1524
-1549
-1711

query I rowsort
SELECT - col2 * + 6 - col2 * cor0.col2 FROM tab0 cor0
----
-1287
-7
-7216

query I rowsort
SELECT DISTINCT - - col0 * col2 - + col0 FROM tab1 cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + col2 + 70 FROM tab0 AS cor0
----
103
152
71

query I rowsort
SELECT + col0 - 96 AS col2 FROM tab1 AS cor0
----
-16
-32
-93

query I rowsort
SELECT ALL + - col0 * 56 * ( - col0 ) AS col2 FROM tab0 AS cor0
----
32256
443576
68600

query I rowsort
SELECT DISTINCT - - col0 * ( - 92 ) AS col2 FROM tab0 AS cor0
----
-2208
-3220
-8188

query I rowsort
SELECT ALL - col0 * 21 FROM tab0 AS cor0
----
-1869
-504
-735

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6057
SELECT DISTINCT CAST( col2 AS SIGNED ) AS col0 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6057
SELECT DISTINCT CAST ( col2 AS INTEGER ) AS col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + col0 + col1 * - col1 AS col2 FROM tab1 AS cor0
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6059
SELECT ALL - col1 DIV ( col1 ) + col0 AS col2 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-6059
SELECT ALL - col1 / ( col1 ) + col0 AS col2 FROM tab2 AS cor0
----
6
77
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6060
SELECT - col0 DIV + 49 + col2 FROM tab1 AS cor0
----
54
56
95

skipif mysql # not compatible
query I rowsort label-6060
SELECT - col0 / + 49 + col2 FROM tab1 AS cor0
----
54
56
95

query I rowsort
SELECT ALL + ( + col1 ) + - col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT + col2 * - 95 + - col0 FROM tab1 AS cor0
----
-5133
-5479
-9200

query I rowsort
SELECT DISTINCT col2 + 32 * + cor0.col0 FROM tab2 cor0
----
251
2522
2566

query I rowsort
SELECT - - cor0.col0 + col2 * - cor0.col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT tab2.col1 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL - col0 + - col1 AS col2 FROM tab1
----
-29
-74
-93

query IIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0 WHERE NULL NOT BETWEEN ( NULL ) AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col0 + cor1.col1 col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
137
38
96

query I rowsort
SELECT ALL - col1 * + col1 - + col2 FROM tab1
----
-157
-265
-730

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to d6394df0309139ffe20e7d96c77e26ee

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to 04d825fa29899c3ee2704c26a542267d

query I rowsort
SELECT ALL 62 FROM tab1, tab1 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT ALL 44 * col1 AS col2 FROM tab0 AS cor0
----
3784
4004
4268

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab2 cor1, tab1, tab0 AS cor2
----
3645 values hashing to b225d3765f33551c12574f545c8c91eb

query I rowsort
SELECT ( col1 ) * - col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + 82 * col0 AS col2 FROM tab2
----
574
6396
6478

query I rowsort
SELECT + col0 + - col2 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT col2 * col0 + col1 * - col2 - + col1 FROM tab0 AS cor0
----
-159
-2132
-255

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6079
SELECT DISTINCT col2 * + CAST( NULL AS SIGNED ) * - col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6079
SELECT DISTINCT col2 * + CAST ( NULL AS INTEGER ) * - col2 FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT - tab1.col2 * tab1.col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + 33 FROM tab0, tab0 AS cor0
----
33

query I rowsort
SELECT col1 * 59 + col0 FROM tab0
----
5098
5458
5758

query I rowsort
SELECT DISTINCT col2 + + col2 + col1 AS col1 FROM tab1
----
124
134
205

query I rowsort
SELECT DISTINCT col1 + - 47 * col2 FROM tab0
----
-1465
-3763
50

query I rowsort
SELECT DISTINCT - col2 + - 22 FROM tab1 cor0
----
-118
-76
-79

query I rowsort
SELECT + + cor0.col0 + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6087
SELECT ALL - col0 + - col1 DIV col1 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-6087
SELECT ALL - col0 + - col1 / col1 FROM tab0 AS cor0
----
-25
-36
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6088
SELECT DISTINCT - - col1 + ( - col2 ) DIV col0 AS col2 FROM tab2 AS cor0
----
17
28
59

skipif mysql # not compatible
query I rowsort label-6088
SELECT DISTINCT - - col1 + ( - col2 ) / col0 AS col2 FROM tab2 AS cor0
----
17
28
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6089
SELECT DISTINCT - col2 * - CAST( ( + col1 ) AS SIGNED ) FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-6089
SELECT DISTINCT - col2 * - CAST ( ( + col1 ) AS INTEGER ) FROM tab2
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6090
SELECT DISTINCT + CAST( 5 AS SIGNED ) * tab1.col1 FROM tab1, tab0, tab1 cor0
----
130
50
65

skipif mysql # not compatible
query I rowsort label-6090
SELECT DISTINCT + CAST ( 5 AS INTEGER ) * tab1.col1 FROM tab1, tab0, tab1 cor0
----
130
50
65

query I rowsort
SELECT ALL ( - col0 ) * col2 + - col2 + 40 * - col0 * tab1.col2 FROM tab1
----
-149625
-314976
-6696

onlyif mysql # use DIV operator for integer division
query I rowsort label-6092
SELECT + tab2.col0 + - tab2.col1 DIV col0 FROM tab2
----
3
78
79

skipif mysql # not compatible
query I rowsort label-6092
SELECT + tab2.col0 + - tab2.col1 / col0 FROM tab2
----
3
78
79

query I rowsort
SELECT DISTINCT tab0.col0 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
24
35
89

query I rowsort
SELECT ALL - tab0.col0 + - 93 FROM tab0
----
-117
-128
-182

onlyif mysql # use DIV operator for integer division
query I rowsort label-6095
SELECT DISTINCT - ( 82 ) + - col1 DIV + col0 FROM tab1
----
-82
-90

skipif mysql # not compatible
query I rowsort label-6095
SELECT DISTINCT - ( 82 ) + - col1 / + col0 FROM tab1
----
-82
-90

query I rowsort
SELECT DISTINCT - 35 * col1 + + tab1.col2 FROM tab1
----
-293
-359
-856

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6097
SELECT + CAST( NULL AS SIGNED ) / + col1 - - tab2.col0 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6097
SELECT + CAST ( NULL AS INTEGER ) / + col1 - - tab2.col0 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + ( + cor0.col0 + - 69 ) FROM tab2 AS cor0
----
-55
87
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6099
SELECT ALL CAST( - col1 AS SIGNED ) DIV + col2 AS col0 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-6099
SELECT ALL CAST ( - col1 AS INTEGER ) / + col2 AS col0 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT + + ( col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6101
SELECT DISTINCT - + CAST( - 65 AS SIGNED ) + col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6101
SELECT DISTINCT - + CAST ( - 65 AS INTEGER ) + col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + + 88 FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT DISTINCT ( col0 * - col0 ) FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT tab2.col2 AS col0 FROM tab2, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - + cor0.col1 + col2 * + col1 * - 64 FROM tab2 AS cor0
----
-41361
-53599
-98235

onlyif mysql # use DIV operator for integer division
query I rowsort label-6106
SELECT + col1 + col2 DIV col0 FROM tab1 AS cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-6106
SELECT + col1 + col2 / col0 FROM tab1 AS cor0
----
10
14
44

query I rowsort
SELECT ALL - - 7 * col0 FROM tab2 AS cor0
----
49
546
553

query I rowsort
SELECT ALL - col0 * + cor0.col0 + - ( ( + col2 ) ) FROM tab1 AS cor0
----
-4153
-63
-6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-6109
SELECT DISTINCT col2 DIV + col2 AS col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-6109
SELECT DISTINCT col2 / + col2 AS col2 FROM tab1 AS cor0
----
1

query I rowsort
SELECT DISTINCT - - 22 AS col0 FROM tab2 AS cor0
----
22

query I rowsort
SELECT ALL - + 54 + - col1 * + cor0.col1 FROM tab1 cor0
----
-154
-223
-730

query I rowsort
SELECT DISTINCT - - ( col2 ) + - ( + 80 ) * col1 FROM tab1 AS cor0
----
-2026
-743
-944

query I rowsort
SELECT col0 * + col0 + - col2 * ( col1 ) FROM tab0 AS cor0
----
-2262
1128
459

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + + 44 * cor0.col2 FROM tab1 AS cor0
----
2376
2508
4224

query I rowsort
SELECT ALL col2 + col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
4153
63
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col0 col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - col2 * + col0 * - ( + 11 ) + col1 AS col1 FROM tab2 AS cor0
----
2110
22367
33039

query I rowsort
SELECT - col1 + + ( + col1 ) + - col0 AS col2 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT ALL cor0.col1 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 52 + + col0 col0 FROM tab2 AS cor0
----
-45
26
27

query I rowsort
SELECT - - col1 * 67 + col0 FROM tab0 AS cor0
----
5786
6186
6534

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6123
SELECT DISTINCT - CAST( NULL AS DECIMAL ) + 30 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6123
SELECT DISTINCT - CAST ( NULL AS REAL ) + 30 AS col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 19 * cor0.col1 + cor0.col0 col1 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
-126
-167
-491

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT DISTINCT 48 * - tab1.col0 * col1 AS col2 FROM tab1
----
-30720
-3744
-49920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6127
SELECT DISTINCT + col1 DIV - col1 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-6127
SELECT DISTINCT + col1 / - col1 FROM tab1
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6128
SELECT - CAST( + col2 AS SIGNED ) AS col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6128
SELECT - CAST ( + col2 AS INTEGER ) AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ( - col0 ) * - col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT 98 AS col2 FROM tab0
----
98
98
98

query I rowsort
SELECT ( - col2 + col2 ) AS col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6132
SELECT - col1 + - 32 DIV col0 + - col0 AS col0 FROM tab0 AS cor0
----
-111
-132
-180

skipif mysql # not compatible
query I rowsort label-6132
SELECT - col1 + - 32 / col0 + - col0 AS col0 FROM tab0 AS cor0
----
-111
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-6133
SELECT DISTINCT col1 DIV col1 + + col1 * col1 + - col1 FROM tab1
----
157
651
91

skipif mysql # not compatible
query I rowsort label-6133
SELECT DISTINCT col1 / col1 + + col1 * col1 + - col1 FROM tab1
----
157
651
91

query I rowsort
SELECT - 82 FROM tab2
----
-82
-82
-82

query I rowsort
SELECT ALL 95 * tab2.col1 AS col1 FROM tab2
----
1615
2945
5605

query I rowsort
SELECT DISTINCT - ( col0 ) AS col1 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT + - col0 + col0 AS col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - ( col2 * + ( + 59 ) ) AS col0 FROM tab1
----
-3186
-3363
-5664

query I rowsort
SELECT ALL + col2 + col2 * 99 AS col2 FROM tab2 AS cor0
----
2600
2700
3800

query I rowsort
SELECT col2 * + col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - - col0 - ( col0 ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col1 + - 84 * col0 AS col0 FROM tab0 AS cor0
----
-1930
-2843
-7385

query I rowsort
SELECT - col1 - + ( - col0 ) FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + col1 + - 2 AS col2 FROM tab2 cor0
----
15
29
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6145
SELECT + col2 * col0 + CAST( - 31 AS SIGNED ) * + tab2.col0 * col2 AS col1 FROM tab2
----
-5670
-60840
-90060

skipif mysql # not compatible
query I rowsort label-6145
SELECT + col2 * col0 + CAST ( - 31 AS INTEGER ) * + tab2.col0 * col2 AS col1 FROM tab2
----
-5670
-60840
-90060

query I rowsort
SELECT + col2 * col2 + col1 FROM tab2
----
1461
735
760

query I rowsort
SELECT ALL - col0 * col0 * - col0 AS col0 FROM tab2 AS cor0
----
343
474552
493039

query I rowsort
SELECT + - cor0.col0 + col2 * - col0 AS col1 FROM tab2 cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL col2 * col0 - + cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-6150
SELECT col2 DIV col0 + col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-6150
SELECT col2 / col0 + col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT ALL - cor0.col0 + + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + + col2 - + col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT cor0.col1 + col1 * col0 FROM tab2 AS cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * cor0.col2 + col2 + col1 col1 FROM tab0 AS cor0
----
-673
-7125
63

query I rowsort
SELECT + col1 FROM tab0 cor0 WHERE NOT cor0.col2 * col2 = ( NULL ) OR + cor0.col0 IN ( col1 )
----

query I rowsort
SELECT DISTINCT + col0 * col1 + + col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - col1 - col2 * col2 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT ALL - - cor0.col1 + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + col2 * + col2 * col1 AS col0 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - col2 * cor0.col0 * col1 + col0 + + cor0.col2 FROM tab2 AS cor0
----
-119548
-50917
-5825

query I rowsort
SELECT + col0 * col0 - - col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT ALL - col0 + - col1 * - col0 FROM tab0 AS cor0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col2 col1 FROM tab2, tab0, tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + col0 + cor0.col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL - col2 * cor0.col2 + - col1 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT - col1 * col2 * col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT + 1 + col0 AS col2 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT col2 + + col0 * col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT + col1 * 38 AS col1 FROM tab0
----
3268
3458
3686

query I rowsort
SELECT ALL - col0 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - ( - col1 + - col2 ) * - col2 AS col0 FROM tab0
----
-14186
-3927
-98

query I rowsort
SELECT ALL 89 * + col2 AS col1 FROM tab1
----
4806
5073
8544

query I rowsort
SELECT + 51 * col2 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT DISTINCT - col0 + col0 - col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - - col1 * + col2 * col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL 30 AS col1 FROM tab0 AS cor0
----
30
30
30

query I rowsort
SELECT ALL - 66 FROM tab1 AS cor0
----
-66
-66
-66

query I rowsort
SELECT col0 * col2 - col2 AS col1 FROM tab0
----
34
7216
759

query I rowsort
SELECT - + cor0.col1 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT - ( 52 ) + + cor0.col1 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 2a8fe3492a2df1e5c3fdb2330358d555

query I rowsort
SELECT + col0 * + col2 + - col1 * col0 FROM tab2 cor0
----
-2574
-28
1659

query I rowsort
SELECT 12 AS col1 FROM tab0 AS cor0
----
12
12
12

query I rowsort
SELECT DISTINCT - 85 FROM tab1
----
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6184
SELECT ALL col1 DIV - col0 AS col1 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6184
SELECT ALL col1 / - col0 AS col1 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT col0 + + ( - col1 ) FROM tab2
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + col1 * - col1 col0 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT ALL + col2 * - col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ( - col1 ) + + col0 * col1 * + col1 AS col0 FROM tab0 AS cor0
----
177418
329218
736918

query I rowsort
SELECT ALL + col0 + - col1 + col1 FROM tab0
----
24
35
89

query I rowsort
SELECT + 49 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT DISTINCT 90 + col0 + col1 FROM tab1 AS cor0
----
119
164
183

query I rowsort
SELECT ALL - cor0.col2 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6193
SELECT - 21 DIV col1 AS col2 FROM tab2 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6193
SELECT - 21 / col1 AS col2 FROM tab2 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6194
SELECT DISTINCT + col1 * col0 DIV 11 + col1 FROM tab1 AS cor0
----
107
33
68

skipif mysql # not compatible
query I rowsort label-6194
SELECT DISTINCT + col1 * col0 / 11 + col1 FROM tab1 AS cor0
----
107
33
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-6195
SELECT col1 DIV + cor0.col1 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6195
SELECT col1 / + cor0.col1 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + - cor0.col2 * col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + cor0.col2 * col1 - - col1 * col0 AS col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT DISTINCT - 35 AS col1 FROM tab0 AS cor0
----
-35

query I rowsort
SELECT ALL - 10 AS col2 FROM tab0 AS cor0
----
-10
-10
-10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - cor0.col2 col2 FROM tab0 AS cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + - col1 col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT col1 - - 37 AS col2 FROM tab2 AS cor0
----
54
68
96

query I rowsort
SELECT - cor0.col0 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT col2 + + 86 FROM tab2 AS cor0
----
112
113
124

query I rowsort
SELECT DISTINCT + col0 + cor0.col1 AS col2 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - cor0.col0 * col0 col1 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL + col1 * + col2 + + 97 FROM tab2 AS cor0
----
1631
743
934

query I rowsort
SELECT DISTINCT col0 + col0 * + col1 - col2 AS col2 FROM tab2 AS cor0
----
1384
197
4654

query I rowsort
SELECT - - col2 * col0 + - col2 * col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - cor0.col0 + 64 FROM tab1 AS cor0
----
-16
0
61

query I rowsort
SELECT ALL - 71 * col0 - col2 AS col0 FROM tab0 AS cor0
----
-1737
-2486
-6401

onlyif mysql # use DIV operator for integer division
query I rowsort label-6212
SELECT ALL + + col1 DIV - col2 + cor0.col1 + + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-6212
SELECT ALL + + col1 / - col2 + cor0.col1 + + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + + col2 * - 72 + col0 FROM tab1 AS cor0
----
-3885
-4040
-6832

query I rowsort
SELECT + col2 - col2 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 + + col2 AS col0 FROM tab1
----
0

query I rowsort
SELECT DISTINCT col2 * 70 FROM tab2 AS cor0
----
1820
1890
2660

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6217
SELECT DISTINCT + + CAST( NULL AS SIGNED ) * 19 * cor0.col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6217
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) * 19 * cor0.col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - + col1 + col1 * col1 AS col2 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT + + 56 * ( - cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-1736
-3304
-952

onlyif mysql # use DIV operator for integer division
query I rowsort label-6220
SELECT DISTINCT - - 89 * col2 + col0 DIV + col0 AS col0 FROM tab1 AS cor0
----
4807
5074
8545

skipif mysql # not compatible
query I rowsort label-6220
SELECT DISTINCT - - 89 * col2 + col0 / + col0 AS col0 FROM tab1 AS cor0
----
4807
5074
8545

query I rowsort
SELECT ALL + col2 * 84 * col0 AS col1 FROM tab1 AS cor0
----
13608
306432
645120

query I rowsort
SELECT + col1 + + 48 AS col0 FROM tab1 AS cor0
----
58
61
74

query I rowsort
SELECT ALL - 10 * - col1 FROM tab2 AS cor0
----
170
310
590

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6224
SELECT ALL CAST( NULL AS SIGNED ) - + col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6224
SELECT ALL CAST ( NULL AS INTEGER ) - + col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 + - col0 * - col0 AS col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + + 48 FROM tab1 AS cor0
----
48
48
48

query I rowsort
SELECT ALL + 3 FROM tab0
----
3
3
3

query I rowsort
SELECT + 92 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

onlyif mysql # use DIV operator for integer division
query I rowsort label-6229
SELECT col2 DIV ( col1 ) col0 FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6229
SELECT col2 / ( col1 ) col0 FROM tab1 AS cor0
----
2
5
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6230
SELECT col0 + CAST( col0 AS SIGNED ) * + col1 FROM tab1 AS cor0
----
1120
704
81

skipif mysql # not compatible
query I rowsort label-6230
SELECT col0 + CAST ( col0 AS INTEGER ) * + col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - col2 * col1 * + cor0.col0 + - col0 * + col0 AS col0 FROM tab0 cor0
----
-4620
-672039
-68688

query I rowsort
SELECT + col0 + 68 * col2 FROM tab0 AS cor0
----
103
2268
5665

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6233
SELECT + col0 + + CAST( 88 AS SIGNED ) FROM tab1 AS cor0
----
152
168
91

skipif mysql # not compatible
query I rowsort label-6233
SELECT + col0 + + CAST ( 88 AS INTEGER ) FROM tab1 AS cor0
----
152
168
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + tab1.col2 * - 99 + + col0 col1 FROM tab1
----
-5346
-5643
-9504

query I rowsort
SELECT DISTINCT col2 + + col0 + col2 AS col1 FROM tab0
----
253
37
90

query I rowsort
SELECT col1 * - col2 * col1 + col2 * 46 + col1 * col1 FROM tab1
----
-11639
-2978
-33344

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6237
SELECT - col1 * - CAST( NULL AS SIGNED ) + - tab2.col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6237
SELECT - col1 * - CAST ( NULL AS INTEGER ) + - tab2.col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * + 24 FROM tab1 AS cor0
----
240
312
624

query I rowsort
SELECT - + col1 + - ( col2 ) * col2 * ( cor0.col1 + col2 ) FROM tab2 AS cor0
----
-42313
-57519
-79437

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab2 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to b803f2d602a28da5cf35ddc7c7fa2eeb

onlyif mysql # use DIV operator for integer division
query I rowsort label-6241
SELECT ALL + col0 DIV + cor0.col1 AS col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6241
SELECT ALL + col0 / + cor0.col1 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 86 AS col2 FROM tab0, tab0 cor0, tab1 AS cor1
----
86

query I rowsort
SELECT ALL tab2.col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - col0 * 61 AS col2 FROM tab2 AS cor0
----
-427
-4758
-4819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6245
SELECT + CAST( NULL AS SIGNED ) FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6245
SELECT + CAST ( NULL AS INTEGER ) FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 46 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT + - col1 * 94 AS col2 FROM tab2 AS cor0
----
-1598
-2914
-5546

query I rowsort
SELECT DISTINCT 13 FROM tab1, tab1 AS cor0
----
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col0 col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL ( col1 ) * col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - cor0.col1 + col0 * + col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - 41 FROM tab2, tab0 cor0
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

query I rowsort
SELECT col1 * col2 + - col0 - - col0 * + col1 AS col2 FROM tab0 AS cor0
----
15472
3457
4878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6254
SELECT CAST( NULL AS SIGNED ) * - col1 + + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6254
SELECT CAST ( NULL AS INTEGER ) * - col1 + + col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ( - col1 + col0 ) FROM tab2
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 col0 FROM tab2
----
118
34
62

query I rowsort
SELECT + 90 FROM tab2, tab2 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

onlyif mysql # use DIV operator for integer division
query I rowsort label-6258
SELECT DISTINCT tab1.col2 DIV + ( col0 ) AS col2 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6258
SELECT DISTINCT tab1.col2 / + ( col0 ) AS col2 FROM tab1
----
0
1
18

query I rowsort
SELECT ALL - tab1.col2 * col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - + cor1.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - col1 + col0 * CAST ( col2 AS REAL ) col2 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT ALL + ( - col0 ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + tab2.col2 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT + + ( col0 ) * + ( - col0 + - col0 ) FROM tab2 AS cor0
----
-12168
-12482
-98

query I rowsort
SELECT - col1 + col2 * - 20 FROM tab1 AS cor0
----
-1106
-1150
-1933

query I rowsort
SELECT + - 70 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to c2a2994a4e94583683ccda2cc098c58f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6267
SELECT col0 DIV + cor0.col1 col0 FROM tab2 AS cor0
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6267
SELECT col0 / + cor0.col1 col0 FROM tab2 AS cor0
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6268
SELECT col0 + - CAST( + 4 AS SIGNED ) DIV col0 FROM tab1 AS cor0
----
2
64
80

skipif mysql # not compatible
query I rowsort label-6268
SELECT col0 + - CAST ( + 4 AS INTEGER ) / col0 FROM tab1 AS cor0
----
2
64
80

query I rowsort
SELECT ALL - cor0.col0 + 70 FROM tab2 AS cor0
----
-8
-9
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6270
SELECT ALL + cor0.col0 * - CAST( cor0.col0 AS SIGNED ) FROM tab1 cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-6270
SELECT ALL + cor0.col0 * - CAST ( cor0.col0 AS INTEGER ) FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL col0 + cor0.col1 * - col0 * + col2 FROM tab0 AS cor0
----
-3360
-664029
-68088

query I rowsort
SELECT DISTINCT col1 * - ( + 89 ) AS col0 FROM tab2 AS cor0
----
-1513
-2759
-5251

query I rowsort
SELECT ALL + col1 * + 94 + 2 FROM tab1 cor0
----
1224
2446
942

query I rowsort
SELECT ALL + col1 * + ( cor0.col2 * col2 ) + + 88 + - col0 FROM tab0 AS cor0
----
150
611883
93718

query I rowsort
SELECT DISTINCT - col0 + + 30 FROM tab0
----
-5
-59
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6276
SELECT + ( 2 ) DIV - col2 + 84 AS col0 FROM tab1 AS cor0
----
84
84
84

skipif mysql # not compatible
query I rowsort label-6276
SELECT + ( 2 ) / - col2 + 84 AS col0 FROM tab1 AS cor0
----
84
84
84

query I rowsort
SELECT col1 * + col2 + - col0 AS col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT + + col0 + col1 * + col2 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT + cor0.col1 - + 41 FROM tab0 AS cor0
----
45
50
56

query I rowsort
SELECT - - 86 + - 22 FROM tab1 AS cor0
----
64
64
64

query I rowsort
SELECT cor0.col2 * + col0 * + col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - ( cor0.col1 ) + col0 * col2 AS col1 FROM tab0 AS cor0
----
-62
706
7207

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT 40 + 37 FROM tab1 AS cor0
----
77
77
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( 57 ) * col0 col1 FROM tab0 AS cor0
----
1368
1995
5073

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6286
SELECT - CAST( - col0 AS SIGNED ) * + col0 + - col2 AS col1 FROM tab0 AS cor0
----
1224
543
7839

skipif mysql # not compatible
query I rowsort label-6286
SELECT - CAST ( - col0 AS INTEGER ) * + col0 + - col2 AS col1 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT col2 * - 41 AS col2 FROM tab1 AS cor0
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT - col1 * + col0 + col0 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT col2 + col1 * col0 * 43 AS col2 FROM tab1 AS cor0
----
27577
3408
44816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6290
SELECT + + 80 + col1 * ( - ( - col0 ) + CAST( col2 AS SIGNED ) ) FROM tab2 AS cor0
----
1134
2069
6216

skipif mysql # not compatible
query I rowsort label-6290
SELECT + + 80 + col1 * ( - ( - col0 ) + CAST ( col2 AS INTEGER ) ) FROM tab2 AS cor0
----
1134
2069
6216

query I rowsort
SELECT + col0 * cor0.col2 + - 85 * col1 AS col1 FROM tab1 AS cor0
----
-2048
2798
6575

query I rowsort
SELECT DISTINCT - - cor0.col0 + cor0.col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL + col1 + - col2 * - col1 AS col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT - cor0.col1 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT col1 + - tab0.col2 * + tab0.col1 AS col2 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT col1 + - col1 - tab1.col1 AS col0 FROM tab1 WHERE NOT NULL < ( NULL )
----

query I rowsort
SELECT ALL - col0 * - col2 + - col0 * col1 FROM tab2
----
-2574
-28
1659

query I rowsort
SELECT DISTINCT col0 - - col1 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6299
SELECT - col0 DIV col0 AS col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6299
SELECT - col0 / col0 AS col0 FROM tab1
----
-1
-1
-1

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( NULL ) BETWEEN ( NULL ) AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 * + col2 col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT - tab1.col2 + tab1.col2 AS col2 FROM tab1
----
0
0
0

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col1 IN ( col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT col1 * - tab1.col1 + + col2 FROM tab1
----
-43
-622
-73

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) IN ( - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6306
SELECT - tab0.col0 + tab0.col1 DIV + col2 - col0 * + col1 AS col0 FROM tab0
----
-2086
-3333
-8187

skipif mysql # not compatible
query I rowsort label-6306
SELECT - tab0.col0 + tab0.col1 / + col2 - col0 * + col1 AS col0 FROM tab0
----
-2086
-3333
-8187

query I rowsort
SELECT col2 + - col1 * col1 - + col1 AS col2 FROM tab2
----
-268
-3514
-965

query I rowsort
SELECT ALL col1 + col0 * col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL + col0 + + tab0.col0 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL col1 + + col0 * col0 AS col0 FROM tab1
----
35
4106
6413

query I rowsort
SELECT ALL col2 + col2 * - col1 FROM tab2
----
-1508
-608
-810

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL < NULL
----

query I rowsort
SELECT DISTINCT col2 + col2 * + col1 AS col1 FROM tab2
----
1560
684
864

query I rowsort
SELECT + col1 + col1 + + col0 FROM tab0
----
196
229
271

onlyif mysql # use DIV operator for integer division
query I rowsort label-6315
SELECT ALL + col2 DIV - col0 + col1 col1 FROM tab0 AS cor0
----
85
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6315
SELECT ALL + col2 / - col0 + col1 col1 FROM tab0 AS cor0
----
85
91
97

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT - col1 NOT BETWEEN col0 + + col1 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6317
SELECT ALL - col0 + col0 DIV - tab2.col1 FROM tab2
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-6317
SELECT ALL - col0 + col0 / - tab2.col1 FROM tab2
----
-7
-79
-83

query I rowsort
SELECT ALL - col1 + tab0.col1 * col2 * + col0 FROM tab0
----
3298
664027
68026

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NOT NULL NOT BETWEEN col2 * col0 AND NULL
----

query IIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 WHERE NOT cor0.col1 BETWEEN ( NULL ) AND NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NULL < col0
----

query I rowsort
SELECT col1 * - col0 + - col2 * col2 FROM tab0
----
-14823
-3153
-3396

query I rowsort
SELECT + col0 + - col0 + - col0 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL col0 + - col0 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT col1 + col1 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - col1 + col1 * + col1 + col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL - col2 + - col0 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL col0 * + cor0.col0 AS col1 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT col1 * col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + col0 * col1 + col1 + col0 FROM tab2 AS cor0
----
1439
255
4739

query I rowsort
SELECT ALL + + col0 * col2 + - ( - col2 ) FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT + col1 + + col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - col2 * col2 - col0 * col1 AS col1 FROM tab0 AS cor0
----
-14823
-3153
-3396

onlyif mysql # use DIV operator for integer division
query I rowsort label-6334
SELECT DISTINCT - col2 + col2 DIV col1 FROM tab1 AS cor0
----
-52
-89

skipif mysql # not compatible
query I rowsort label-6334
SELECT DISTINCT - col2 + col2 / col1 FROM tab1 AS cor0
----
-52
-89

query I rowsort
SELECT - col0 + + cor0.col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - col1 * 42 + + col2 AS col0 FROM tab2 AS cor0
----
-1275
-2452
-676

query I rowsort
SELECT DISTINCT - col2 - - ( cor0.col0 * - col1 ) AS col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT ALL - + col1 + col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT - col1 * + col1 + col2 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT + col2 + 0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + + col0 * 73 FROM tab2 AS cor0
----
511
5694
5767

query I rowsort
SELECT col2 + - 61 * + col1 FROM tab0 AS cor0
----
-5213
-5469
-5916

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6343
SELECT DISTINCT + CAST( + col0 AS SIGNED ) * - col1 + col2 col1 FROM tab0 cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6343
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) * - col1 + col2 col1 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - ( col0 ) AS col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT 20 AS col1 FROM tab2 AS cor0
----
20
20
20

query I rowsort
SELECT ALL - + 49 + - col1 AS col0 FROM tab2 AS cor0
----
-108
-66
-80

query I rowsort
SELECT ALL - col2 + ( - col2 * col2 ) FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT DISTINCT - + 96 * col0 + col1 FROM tab0 AS cor0
----
-2218
-3263
-8453

query I rowsort
SELECT + cor0.col2 * col2 + col2 * col1 FROM tab2 AS cor0
----
1566
2090
2210

query I rowsort
SELECT ALL + col1 * - col2 - col0 AS col2 FROM tab0 AS cor0
----
-132
-2862
-7551

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab1 AS cor1, tab2 cor2
----
972 values hashing to 49c8bf3e931a898ba7af63d0e377eb79

query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + + 47 AS col0 FROM tab1 AS cor0
----
47
47
47

query I rowsort
SELECT ALL - - 85 * + col2 + - col2 AS col2 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT + 56 + cor0.col0 FROM tab1 AS cor0
----
120
136
59

query I rowsort
SELECT cor0.col0 AS col1 FROM tab2, tab0 cor0, tab2 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + tab1.col0 col1 FROM tab1 WHERE NULL NOT IN ( col2 + + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col1 col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT ALL + - col0 + + col2 * 68 FROM tab0 AS cor0
----
2220
33
5487

query I rowsort
SELECT col0 + + col0 * + col1 * - col2 + col1 FROM tab1
----
-36406
-4183
-99747

query I rowsort
SELECT cor0.col2 * ( col0 ) AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col1 + - tab0.col0 * ( - col0 ) AS col0 FROM tab0
----
1128
490
7830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 + - 44 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 242de5425f187203e83571334b099b96

query I rowsort
SELECT + 13 * col2 FROM tab2
----
338
351
494

query I rowsort
SELECT DISTINCT - col1 + col0 AS col1 FROM tab0
----
-2
-62

query I rowsort
SELECT - col0 * tab1.col0 + - 64 * ( col2 ) * col0 + + col2 AS col2 FROM tab1
----
-10323
-237511
-497824

query I rowsort
SELECT + tab2.col2 + - col1 * + col0 AS col2 FROM tab2
----
-1305
-190
-4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6368
SELECT + + CAST( + col0 AS SIGNED ) * - col2 col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6368
SELECT + + CAST ( + col0 AS INTEGER ) * - col2 col1 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6369
SELECT - CAST( NULL AS SIGNED ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6369
SELECT - CAST ( NULL AS INTEGER ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 55 AS col2 FROM tab2 cor0
----
55
55
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + cor0.col1 col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - + 62 AS col1 FROM tab0 AS cor0
----
-62
-62
-62

query I rowsort
SELECT ALL + 49 FROM tab0
----
49
49
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6374
SELECT CAST( NULL AS SIGNED ) col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6374
SELECT CAST ( NULL AS INTEGER ) col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT col0 * + 14 * col2 FROM tab1 cor0
----
107520
2268
51072

query I rowsort
SELECT - col0 + ( - cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + + cor0.col1 * + 77 + col1 AS col0 FROM tab2 AS cor0
----
1326
2418
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 - + 36 col0 FROM tab2 AS cor0
----
-29
42
43

query I rowsort
SELECT tab2.col2 * - 29 AS col2 FROM tab2
----
-1102
-754
-783

query I rowsort
SELECT DISTINCT + ( - 32 ) AS col1 FROM tab2, tab2 AS cor0
----
-32

onlyif mysql # use DIV operator for integer division
query I rowsort label-6381
SELECT - + col0 * col1 + - col2 DIV - col1 AS col1 FROM tab2 AS cor0
----
-1341
-217
-4602

skipif mysql # not compatible
query I rowsort label-6381
SELECT - + col0 * col1 + - col2 / - col1 AS col1 FROM tab2 AS cor0
----
-1341
-217
-4602

query I rowsort
SELECT col0 * + cor0.col0 + col0 AS col2 FROM tab1 cor0
----
12
4160
6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6383
SELECT ALL CAST( 43 AS SIGNED ) FROM tab2 AS cor0
----
43
43
43

skipif mysql # not compatible
query I rowsort label-6383
SELECT ALL CAST ( 43 AS INTEGER ) FROM tab2 AS cor0
----
43
43
43

query I rowsort
SELECT ALL col2 - col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - 68 * - col0 FROM tab2 AS cor0
----
476
5304
5372

query I rowsort
SELECT DISTINCT 15 + 55 + cor0.col2 * col2 AS col1 FROM tab0 AS cor0
----
1159
6794
71

query I rowsort
SELECT ALL 32 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT 9 AS col2 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + 69 ) col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 95 col1 FROM tab0, tab0 AS cor0
----
-95

query I rowsort
SELECT DISTINCT - - col0 * ( + col1 ) AS col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6392
SELECT - ( col1 ) + + col0 DIV 53 FROM tab2 AS cor0
----
-16
-31
-58

skipif mysql # not compatible
query I rowsort label-6392
SELECT - ( col1 ) + + col0 / 53 FROM tab2 AS cor0
----
-16
-31
-58

query I rowsort
SELECT + 81 + + col1 AS col2 FROM tab2 AS cor0
----
112
140
98

query I rowsort
SELECT ALL col2 + - 81 * cor0.col1 FROM tab1 AS cor0
----
-2052
-753
-957

query I rowsort
SELECT - col2 * + col1 + - col2 * - col0 AS col0 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT DISTINCT + 9 * col1 AS col2 FROM tab1 AS cor0
----
117
234
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6397
SELECT + 54 + ( cor0.col2 ) * - ( - col1 ) + col0 * + CAST( - col2 AS SIGNED ) col0 FROM tab2 AS cor0
----
-2302
-440
702

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6397
SELECT + 54 + ( cor0.col2 ) * - ( - col1 ) + col0 * + CAST ( - col2 AS INTEGER ) col0 FROM tab2 AS cor0
----
-2302
-440
702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6398
SELECT + CAST( NULL AS SIGNED ) + - col0 / col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6398
SELECT + CAST ( NULL AS INTEGER ) + - col0 / col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 63 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT cor0.col2 * - 6 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 10a425095e1461e78db46c3bfe438e36

query I rowsort
SELECT ALL col1 + tab1.col2 * + col2 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT DISTINCT col0 * col2 * col2 + + col2 AS col0 FROM tab1
----
207993
737376
8802

onlyif mysql # use DIV operator for integer division
query I rowsort label-6404
SELECT DISTINCT - 82 + + col0 DIV + col2 AS col0 FROM tab0
----
-47
-81
-82

skipif mysql # not compatible
query I rowsort label-6404
SELECT DISTINCT - 82 + + col0 / + col2 AS col0 FROM tab0
----
-47
-81
-82

query I rowsort
SELECT + ( - col0 ) + + col1 AS col2 FROM tab0 AS cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 74 ) * + col1 col1 FROM tab1 AS cor0
----
-1924
-740
-962

query I rowsort
SELECT - ( - 48 ) AS col1 FROM tab0
----
48
48
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-6408
SELECT + tab1.col2 DIV - tab1.col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-6408
SELECT + tab1.col2 / - tab1.col0 FROM tab1
----
-1
-18
0

query I rowsort
SELECT ALL - 37 FROM tab1
----
-37
-37
-37

query I rowsort
SELECT DISTINCT col1 + - 83 FROM tab2 AS cor0
----
-24
-52
-66

query I rowsort
SELECT - col0 * - 54 * col0 + + col2 - - 96 FROM tab0 AS cor0
----
31233
427912
66247

onlyif mysql # use DIV operator for integer division
query I rowsort label-6412
SELECT col2 * + col0 + CAST( - 80 AS SIGNED ) DIV col1 FROM tab2
----
187
2027
2998

skipif mysql # not compatible
query I rowsort label-6412
SELECT col2 * + col0 + CAST ( - 80 AS INTEGER ) / col1 FROM tab2
----
187
2027
2998

onlyif mysql # use DIV operator for integer division
query I rowsort label-6413
SELECT ( tab0.col0 ) DIV + ( - col0 * - tab0.col1 + + 82 ) AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6413
SELECT ( tab0.col0 ) / + ( - col0 * - tab0.col1 + + 82 ) AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - + 56 FROM tab0, tab2, tab2 cor0
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

query I rowsort
SELECT - col1 + + 42 * + 58 AS col2 FROM tab0 AS cor0
----
2339
2345
2350

query I rowsort
SELECT + col1 + + ( col0 ) AS col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - + col2 + - col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL - tab1.col1 * col2 * col2 + + col1 * + col1 FROM tab1
----
-119639
-32390
-75140

query I rowsort
SELECT DISTINCT + + col0 * - col2 * col0 FROM tab2 cor0
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6420
SELECT - + col0 + - 49 DIV - 7 FROM tab1 AS cor0
----
-57
-73
4

skipif mysql # not compatible
query I rowsort label-6420
SELECT - + col0 + - 49 / - 7 FROM tab1 AS cor0
----
-57
-73
4

query I rowsort
SELECT ALL col0 * ( col2 ) FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6422
SELECT ALL col0 + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-6422
SELECT ALL col0 + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + cor0.col1 + ( + col1 ) AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT col2 + + col2 * ( + cor0.col1 * - col0 + - col0 ) AS col0 FROM tab0 AS cor0
----
-3429
-671334
-68871

query I rowsort
SELECT + cor0.col0 * + 53 - col1 AS col0 FROM tab1 cor0
----
133
3382
4227

query I rowsort
SELECT - + col1 + + 26 AS col0 FROM tab0 AS cor0
----
-60
-65
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-6427
SELECT col0 DIV 91 col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6427
SELECT col0 / 91 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 * col1 * + col1 FROM tab0 AS cor0
----
636056
753571
912673

query I rowsort
SELECT ALL - 50 FROM tab0 AS cor0
----
-50
-50
-50

query I rowsort
SELECT ALL + 82 FROM tab0
----
82
82
82

query I rowsort
SELECT ALL + col1 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( + col1 ) AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - 7 + + col1 FROM tab1 AS cor0
----
19
3
6

query I rowsort
SELECT ALL col0 * + cor0.col1 + 88 FROM tab1 AS cor0
----
1128
166
728

query I rowsort
SELECT DISTINCT + - col1 + + cor0.col2 + 64 FROM tab2 AS cor0
----
31
60
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6436
SELECT cor0.col0 + col1 DIV - col0 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-6436
SELECT cor0.col0 + col1 / - col0 FROM tab0 AS cor0
----
21
33
88

query I rowsort
SELECT + cor0.col2 * 88 AS col1 FROM tab0 cor0
----
2904
7216
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6438
SELECT ALL - col1 * 22 + col1 DIV + col2 FROM tab0 AS cor0
----
-1890
-2001
-2037

skipif mysql # not compatible
query I rowsort label-6438
SELECT ALL - col1 * 22 + col1 / + col2 FROM tab0 AS cor0
----
-1890
-2001
-2037

query I rowsort
SELECT - + col2 + 90 * ( col0 ) FROM tab0 AS cor0
----
2127
3149
7928

query I rowsort
SELECT - 62 * col0 FROM tab1
----
-186
-3968
-4960

skipif mysql # not compatible
query I rowsort
SELECT tab1.col0 + col0 * CAST ( col1 AS REAL ) FROM tab1
----
1120
704
81

query I rowsort
SELECT + col1 - - col0 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT 13 + - col1 FROM tab2
----
-18
-4
-46

query I rowsort
SELECT + col0 - + cor0.col2 * col2 * 73 FROM tab2 AS cor0
----
-105333
-49270
-53210

query I rowsort
SELECT ALL 31 * col0 FROM tab1 AS cor0
----
1984
2480
93

query I rowsort
SELECT DISTINCT 42 * col0 FROM tab2 AS cor0
----
294
3276
3318

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6447
SELECT ALL + CAST( NULL AS SIGNED ) * + col0 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6447
SELECT ALL + CAST ( NULL AS INTEGER ) * + col0 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6448
SELECT ALL + + CAST( ( - col2 ) AS SIGNED ) - 79 FROM tab2 AS cor0
----
-105
-106
-117

skipif mysql # not compatible
query I rowsort label-6448
SELECT ALL + + CAST ( ( - col2 ) AS INTEGER ) - 79 FROM tab2 AS cor0
----
-105
-106
-117

query I rowsort
SELECT - - 95 AS col2 FROM tab0 AS cor0
----
95
95
95

query I rowsort
SELECT DISTINCT + - 27 AS col2 FROM tab2 AS cor0
----
-27

query I rowsort
SELECT DISTINCT + 5 FROM tab2 AS cor0
----
5

query I rowsort
SELECT ALL + - 51 FROM tab2 cor0
----
-51
-51
-51

query I rowsort
SELECT - col0 * + cor0.col1 + + col1 * cor0.col1 FROM tab1 AS cor0
----
-540
-871
598

query I rowsort
SELECT DISTINCT - 8 + col2 AS col2 FROM tab2 AS cor0
----
18
19
30

query I rowsort
SELECT DISTINCT + ( 41 ) FROM tab1 AS cor0
----
41

query I rowsort
SELECT - - 60 + + col0 AS col0 FROM tab2 AS cor0
----
138
139
67

query I rowsort
SELECT ALL - - col2 * col1 + - col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT - col2 * col0 * cor0.col2 + cor0.col1 FROM tab2 cor0
----
-114059
-5072
-52669

query I rowsort
SELECT ALL - ( - col2 ) + + cor0.col1 + + col1 AS col0 FROM tab1 AS cor0
----
106
122
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6460
SELECT CAST( col0 AS SIGNED ) AS col2 FROM tab2 cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-6460
SELECT CAST ( col0 AS INTEGER ) AS col2 FROM tab2 cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6461
SELECT ALL cor0.col2 - - col2 DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6461
SELECT ALL cor0.col2 - - col2 / col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT 50 + - col0 FROM tab2 AS cor0
----
-28
-29
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col0 + col0 col1 FROM tab2
----
14
156
158

query I rowsort
SELECT ALL - 30 FROM tab2 cor0
----
-30
-30
-30

query I rowsort
SELECT - + ( + col1 ) - + col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + col2 * + col1 + + col1 * + 89 * - col2 FROM tab2 AS cor0
----
-134992
-56848
-73656

query I rowsort
SELECT cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

onlyif mysql # use DIV operator for integer division
query I rowsort label-6468
SELECT ( col1 ) DIV - tab0.col2 AS col1 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-6468
SELECT ( col1 ) / - tab0.col2 AS col1 FROM tab0
----
-1
-2
-97

query I rowsort
SELECT ALL - cor0.col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT 85 + col0 * 46 FROM tab1 AS cor0
----
223
3029
3765

query I rowsort
SELECT + cor0.col2 * cor0.col2 + 43 FROM tab2 AS cor0
----
1487
719
772

query I rowsort
SELECT col1 + + 68 AS col1 FROM tab2
----
127
85
99

query I rowsort
SELECT 25 FROM tab1, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col1 AS REAL ) + col0 + tab2.col2 FROM tab2
----
100
3
45

query I rowsort
SELECT DISTINCT col1 * 86 AS col0 FROM tab2
----
1462
2666
5074

query I rowsort
SELECT - col0 + col2 * + ( col0 ) AS col0 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6477
SELECT - col2 * - col2 * + CAST( col2 AS SIGNED ) + col1 - - 43 AS col0 FROM tab0 AS cor0
----
141
36066
551502

skipif mysql # not compatible
query I rowsort label-6477
SELECT - col2 * - col2 * + CAST ( col2 AS INTEGER ) + col1 - - 43 AS col0 FROM tab0 AS cor0
----
141
36066
551502

query I rowsort
SELECT ALL - 26 * + col0 * + col2 AS col1 FROM tab2 AS cor0
----
-4914
-52728
-78052

query I rowsort
SELECT DISTINCT 57 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-21
-22
50

query I rowsort
SELECT - 42 + col2 AS col1 FROM tab2 AS cor0
----
-15
-16
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 33 col2 FROM tab0 cor0
----
33
33
33

query I rowsort
SELECT + tab0.col1 * col2 + - 48 * col0 * tab0.col2 AS col0 FROM tab0
----
-1583
-342842
-35178

query I rowsort
SELECT + cor0.col2 * 3 AS col2 FROM tab0 cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 7cf1b122133b5bf555efc98e3d320346

query I rowsort
SELECT - col2 * + 72 + col0 AS col2 FROM tab0 AS cor0
----
-2352
-37
-5815

query I rowsort
SELECT DISTINCT - - col2 * - ( - cor0.col1 ) + - col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6486
SELECT - - col0 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6486
SELECT - - col0 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 65 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 4ca93c42a91c7dff917e7b7090ba9e57

query I rowsort
SELECT - 27 FROM tab2, tab0 AS cor0
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6489
SELECT ALL - + CAST( cor0.col2 AS SIGNED ) + cor0.col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6489
SELECT ALL - + CAST ( cor0.col2 AS INTEGER ) + cor0.col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - ( + 25 ) + + col1 FROM tab1 AS cor0
----
-12
-15
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 19 + tab1.col1 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 2e1c108f47beaf5e6a517b40bea55780

query I rowsort
SELECT 23 FROM tab2, tab0 cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6493
SELECT ALL + CAST( NULL AS SIGNED ) + + 97 + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6493
SELECT ALL + CAST ( NULL AS INTEGER ) + + 97 + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 82 AS col0 FROM tab2, tab1 AS cor0, tab2 cor1, tab0 cor2
----
81 values hashing to 660751b3166f5cb8964b7ef659605795

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col0 AS REAL ) FROM tab1 cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 73 col2 FROM tab1 cor0
----
-1898
-730
-949

query I rowsort
SELECT col0 * 31 AS col1 FROM tab0 AS cor0
----
1085
2759
744

query I rowsort
SELECT DISTINCT - + cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT 15 AS col0 FROM tab2
----
15

query I rowsort
SELECT tab1.col0 * - tab1.col2 - 69 * col1 FROM tab1
----
-1956
-4338
-8577

query I rowsort
SELECT DISTINCT 13 * 13 - cor0.col1 AS col0 FROM tab0, tab1 AS cor0
----
143
156
159

query I rowsort
SELECT DISTINCT + col2 * + 94 * + col2 + col0 FROM tab0 AS cor0
----
102390
129
632145

query I rowsort
SELECT - + cor0.col0 + + 61 + - col2 * col2 FROM tab2 AS cor0
----
-1462
-675
-693

query I rowsort
SELECT ALL - col0 + col0 + 97 FROM tab1 AS cor0
----
97
97
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6505
SELECT - col1 + CAST( col1 AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif mysql # not compatible
query I rowsort label-6505
SELECT - col1 + CAST ( col1 AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT + col1 + - 42 * col2 FROM tab2 AS cor0
----
-1033
-1103
-1579

query I rowsort
SELECT - col0 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ( 78 ) FROM tab1
----
78
78
78

query I rowsort
SELECT - 58 * cor0.col2 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to f9a1466854b0b966750ff846208ff7cd

query I rowsort
SELECT ALL 48 * 65 * col1 AS col2 FROM tab2
----
184080
53040
96720

query I rowsort
SELECT - cor0.col0 + - col0 AS col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT col1 * cor0.col1 - col2 * ( 14 ) * col0 FROM tab2 AS cor0
----
-1685
-24911
-41739

query I rowsort
SELECT 89 * col0 AS col0 FROM tab2 AS cor0
----
623
6942
7031

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - cor0.col0 + - 55 col0 FROM tab2 AS cor0
----
-104
-6139
-6296

query I rowsort
SELECT - - ( col2 ) * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT - 9 * - ( col1 ) FROM tab0
----
774
819
873

query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT - cor0.col0 + col2 * + col0 AS col0 FROM tab2 cor0
----
182
1950
2923

query I rowsort
SELECT ALL + - cor0.col0 * cor0.col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 27 + - col1 FROM tab2
----
-44
-58
-86

query I rowsort
SELECT DISTINCT - + ( - col1 ) + ( + col2 ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT 40 + - col0 FROM tab2
----
-38
-39
33

query I rowsort
SELECT - cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col1 + col1 * + 37 AS col1 FROM tab1 cor0
----
380
494
988

query I rowsort
SELECT ALL - col1 * + col0 * col0 AS col1 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT + - col0 * + cor0.col1 - + col0 FROM tab2 cor0
----
-1422
-224
-4680

query I rowsort
SELECT - 83 * - col1 AS col2 FROM tab1
----
1079
2158
830

query I rowsort
SELECT DISTINCT - col1 * col2 + + col1 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + 1 + - col2 * col0 FROM tab2 AS cor0
----
-188
-2027
-3001

query I rowsort
SELECT ALL col1 + 29 FROM tab1 AS cor0
----
39
42
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - col1 col1 FROM tab1
----
109
67
80

query I rowsort
SELECT col2 * - col0 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 * + col0 + - cor0.col2 * + cor0.col0 col0 FROM tab2 AS cor0
----
-238
-8112
-9243

query I rowsort
SELECT DISTINCT - col2 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL col2 - + col1 AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL col1 * + 92 FROM tab0 AS cor0
----
7912
8372
8924

query I rowsort
SELECT + col2 + - 35 * - col1 FROM tab0 AS cor0
----
3043
3267
3396

onlyif mysql # use DIV operator for integer division
query I rowsort label-6538
SELECT DISTINCT + + col2 + + col2 DIV + ( col1 ) col1 FROM tab2 AS cor0
----
26
27
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6538
SELECT DISTINCT + + col2 + + col2 / + ( col1 ) col1 FROM tab2 AS cor0
----
26
27
40

query I rowsort
SELECT DISTINCT + col0 + tab0.col2 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT col2 - tab2.col2 FROM tab2
----
0

query I rowsort
SELECT DISTINCT col1 + - col2 AS col2 FROM tab0
----
53
9
96

query I rowsort
SELECT ALL - - col2 + - ( cor0.col2 + - col0 ) * - 82 FROM tab0 AS cor0
----
-2787
-492
771

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6543
SELECT DISTINCT + CAST( col2 AS SIGNED ) * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-6543
SELECT DISTINCT + CAST ( col2 AS INTEGER ) * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - - 98 AS col1 FROM tab0 AS cor0
----
98
98
98

query I rowsort
SELECT ALL - col2 + - ( - col0 ) FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + col2 + col0 * - col0 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 53 * - col2 col0 FROM tab1 cor0
----
2862
3021
5088

onlyif mysql # use DIV operator for integer division
query I rowsort label-6548
SELECT col1 + cor0.col0 DIV - col0 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-6548
SELECT col1 + cor0.col0 / - col0 FROM tab1 AS cor0
----
12
25
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6549
SELECT ALL + col0 * + col1 + col2 DIV - ( col0 ) FROM tab1 AS cor0
----
1039
60
640

skipif mysql # not compatible
query I rowsort label-6549
SELECT ALL + col0 * + col1 + col2 / - ( col0 ) FROM tab1 AS cor0
----
1039
60
640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 + - col0 col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + col0 * col0 * - col2 AS col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + 84 * + cor0.col2 AS col2 FROM tab1 cor0
----
4536
4788
8064

query I rowsort
SELECT ALL + 94 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT ALL col2 * + 11 FROM tab0
----
11
363
902

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6555
SELECT - CAST( - ( col1 ) + - col2 AS SIGNED ) AS col0 FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-6555
SELECT - CAST ( - ( col1 ) + - col2 AS INTEGER ) AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT - col1 * col2 * + col1 FROM tab1
----
-16224
-36504
-5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-6557
SELECT col0 DIV - 38 FROM tab1
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-6557
SELECT col0 / - 38 FROM tab1
----
-1
-2
0

query I rowsort
SELECT + + col2 * - 43 FROM tab2 AS cor0
----
-1118
-1161
-1634

onlyif mysql # use DIV operator for integer division
query I rowsort label-6559
SELECT - + ( - col2 ) DIV + col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6559
SELECT - + ( - col2 ) / + col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT col2 * - col1 + + ( - col1 ) AS col0 FROM tab1
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-6561
SELECT DISTINCT - tab2.col1 DIV col1 + + col1 * + col2 * 59 FROM tab2
----
38113
49382
90505

skipif mysql # not compatible
query I rowsort label-6561
SELECT DISTINCT - tab2.col1 / col1 + + col1 * + col2 * 59 FROM tab2
----
38113
49382
90505

query I rowsort
SELECT DISTINCT col2 * col0 * - 23 + col2 * tab2.col0 FROM tab2
----
-4158
-44616
-66044

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + 98 * col2 col2 FROM tab2
----
2574
2673
3762

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 * - col1 + - 69 * - col1 col1 FROM tab2
----
-170
-531
1922

query I rowsort
SELECT + col2 * 39 + col1 * col2 FROM tab2 AS cor0
----
1890
2128
2548

query I rowsort
SELECT DISTINCT + ( - col0 ) * + col2 + ( col1 ) + cor0.col1 * - col0 AS col2 FROM tab1 AS cor0
----
-214
-4278
-8707

query I rowsort
SELECT - col2 * - cor0.col0 * col1 + - ( col2 ) * - col2 AS col1 FROM tab2 AS cor0
----
120328
52478
6588

query I rowsort
SELECT + 12 + - col2 FROM tab1 cor0
----
-42
-45
-84

query I rowsort
SELECT DISTINCT + ( 79 ) + - col2 AS col2 FROM tab0 AS cor0
----
-3
46
78

query I rowsort
SELECT - cor0.col2 - col2 * - col1 AS col1 FROM tab2 cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT - ( - col0 ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL ( - col2 ) * col1 + col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-6573
SELECT DISTINCT - - col0 * col0 DIV col1 + - cor0.col2 * + col2 col2 FROM tab2 AS cor0
----
-1077
-573
-728

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6573
SELECT DISTINCT - - col0 * col0 / col1 + - cor0.col2 * + col2 col2 FROM tab2 AS cor0
----
-1077
-573
-728

query I rowsort
SELECT - col2 + + cor0.col0 AS col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL col2 + - cor0.col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + + ( + col1 ) * col2 + + col1 AS col0 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT ALL - ( cor0.col2 ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col2 + 60 FROM tab0 AS cor0
----
142
61
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6579
SELECT ALL + CAST( col2 AS SIGNED ) * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-6579
SELECT ALL + CAST ( col2 AS INTEGER ) * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 * - cor0.col2 + + ( col1 + - col2 ) col1 FROM tab2 AS cor0
----
-119619
-51055
-5855

query I rowsort
SELECT col0 * + col2 * - col0 AS col1 FROM tab1 cor0
----
-233472
-486
-614400

query I rowsort
SELECT col0 + col2 - + 65 FROM tab0
----
-29
-8
106

onlyif mysql # use DIV operator for integer division
query I rowsort label-6583
SELECT col1 - + tab2.col1 DIV 22 AS col0 FROM tab2
----
17
30
57

skipif mysql # not compatible
query I rowsort label-6583
SELECT col1 - + tab2.col1 / 22 AS col0 FROM tab2
----
17
30
57

query I rowsort
SELECT ALL - col0 * col0 + + cor0.col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT + 43 * + col0 AS col2 FROM tab1 AS cor0
----
129
2752
3440

query I rowsort
SELECT + 0 + cor0.col1 + col1 * col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + + ( 75 ) * col1 + + col0 + 48 FROM tab0 AS cor0
----
6522
6962
7358

query I rowsort
SELECT - 13 * + cor0.col1 * - ( + col2 ) FROM tab2 AS cor0
----
10881
19942
8398

query I rowsort
SELECT DISTINCT + col0 * - col2 + col1 AS col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL + - ( col0 ) + + col2 - col2 AS col2 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - col2 * + col1 + ( + col1 ) AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL - - col0 - + cor0.col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL col1 * col2 - - col1 * - col1 AS col1 FROM tab2 AS cor0
----
-124
-1947
357

query I rowsort
SELECT 35 * + col1 FROM tab1 AS cor0
----
350
455
910

onlyif mysql # use DIV operator for integer division
query I rowsort label-6595
SELECT DISTINCT + col1 + col2 + ( - col1 ) DIV + col2 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-6595
SELECT DISTINCT + col1 + col2 + ( - col1 ) / + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + - cor0.col2 * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - - col1 + - col2 FROM tab1 cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6598
SELECT ALL - 5 - - col2 DIV - col2 FROM tab0 AS cor0
----
-6
-6
-6

skipif mysql # not compatible
query I rowsort label-6598
SELECT ALL - 5 - - col2 / - col2 FROM tab0 AS cor0
----
-6
-6
-6

query I rowsort
SELECT 4 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6600
SELECT - - cor0.col2 * CAST( + col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-6600
SELECT - - cor0.col2 * CAST ( + col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col1 + + ( col1 ) * ( col0 ) col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6602
SELECT ALL - col2 * + CAST( NULL AS SIGNED ) + - col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6602
SELECT ALL - col2 * + CAST ( NULL AS INTEGER ) + - col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * + col2 * ( + col1 ) FROM tab1
----
119808
32490
75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 col0 FROM tab0
----
2
62
62

query I rowsort
SELECT + col2 * 61 * + col1 FROM tab1 AS cor0
----
34770
76128
85644

query I rowsort
SELECT + - col1 * - col1 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6607
SELECT + + col1 + - ( + ( - col2 DIV 90 ) ) * - col0 * col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6607
SELECT + + col1 + - ( + ( - col2 / 90 ) ) * - col0 * col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT col0 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT cor0.col0 * + 25 AS col1 FROM tab1 AS cor0
----
1600
2000
75

query I rowsort
SELECT ALL + - col2 + col0 AS col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT - col0 * 51 FROM tab2 AS cor0
----
-357
-3978
-4029

query I rowsort
SELECT - - col2 + + 2 * 34 AS col0 FROM tab2 cor0
----
106
94
95

query I rowsort
SELECT ALL - 92 FROM tab2, tab0 cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

onlyif mysql # use DIV operator for integer division
query I rowsort label-6614
SELECT 89 * cor0.col1 DIV col0 + - ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
0
149
232

skipif mysql # not compatible
query I rowsort label-6614
SELECT 89 * cor0.col1 / col0 + - ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
0
149
232

query I rowsort
SELECT DISTINCT ( 34 ) FROM tab1, tab2 AS cor0
----
34

query I rowsort
SELECT - col1 * ( - col2 + col2 ) AS col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT 5 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6618
SELECT col1 DIV col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6618
SELECT col1 / col2 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6619
SELECT - col1 * col0 + CAST( NULL AS DECIMAL ) / col1 + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6619
SELECT - col1 * col0 + CAST ( NULL AS REAL ) / col1 + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( + col1 * 28 ) AS col0 FROM tab2
----
1652
476
868

query I rowsort
SELECT - ( col0 * - ( 90 ) ) FROM tab0
----
2160
3150
8010

query I rowsort
SELECT 38 FROM tab0
----
38
38
38

query I rowsort
SELECT DISTINCT - col0 * + col1 * - col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT ALL + 98 AS col1 FROM tab0 cor0
----
98
98
98

query I rowsort
SELECT ALL - 24 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to f2e40f6e5cdbc2877843191cb261975f

query I rowsort
SELECT DISTINCT + 3 FROM tab1, tab0 AS cor0, tab1 cor1
----
3

query I rowsort
SELECT DISTINCT + + 68 * col2 AS col1 FROM tab1 AS cor0
----
3672
3876
6528

query I rowsort
SELECT ALL - ( + cor0.col1 ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + 21 * col0 AS col0 FROM tab1 AS cor0
----
1344
1680
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + col0 * 51 col2 FROM tab2 AS cor0
----
330
3952
3991

query I rowsort
SELECT DISTINCT 55 AS col2 FROM tab1 cor0
----
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-6632
SELECT - - 22 DIV col0 + - col2 - - col0 FROM tab2 AS cor0
----
-17
41
52

skipif mysql # not compatible
query I rowsort label-6632
SELECT - - 22 / col0 + - col2 - - col0 FROM tab2 AS cor0
----
-17
41
52

query I rowsort
SELECT col2 * col1 + col0 AS col2 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT + col0 * col0 + ( + col2 * col2 ) AS col1 FROM tab0 cor0
----
1226
14645
1665

onlyif mysql # use DIV operator for integer division
query I rowsort label-6635
SELECT ALL - col2 * - col1 + ( - 54 ) DIV col0 FROM tab1 AS cor0
----
1248
1386
570

skipif mysql # not compatible
query I rowsort label-6635
SELECT ALL - col2 * - col1 + ( - 54 ) / col0 FROM tab1 AS cor0
----
1248
1386
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 + col1 col0 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-6637
SELECT DISTINCT - + col0 * col1 DIV col1 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-6637
SELECT DISTINCT - + col0 * col1 / col1 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + col2 * col1 AS col2 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6639
SELECT + col1 DIV 76 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6639
SELECT + col1 / 76 FROM tab2
----
0
0
0

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-6641
SELECT - - col0 * - col0 + + 54 DIV - col1 AS col1 FROM tab2 AS cor0
----
-50
-6084
-6244

skipif mysql # not compatible
query I rowsort label-6641
SELECT - - col0 * - col0 + + 54 / - col1 AS col1 FROM tab2 AS cor0
----
-50
-6084
-6244

query I rowsort
SELECT ALL + 87 * 5 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to d5cff7726eff78e42b13240a3000ab1c

query I rowsort
SELECT ALL tab2.col0 * + 27 AS col0 FROM tab2
----
189
2106
2133

query I rowsort
SELECT - col1 * - col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + ( + col2 ) + - col2 * 42 AS col0 FROM tab1 AS cor0
----
-2214
-2337
-3936

query I rowsort
SELECT - + col1 * - 41 AS col0 FROM tab0 AS cor0
----
3526
3731
3977

onlyif mysql # use DIV operator for integer division
query I rowsort label-6647
SELECT - col0 DIV + cor0.col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6647
SELECT - col0 / + cor0.col0 FROM tab2 AS cor0
----
-1
-1
-1

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to ced36882687f040e969c817b62d2e456

query I rowsort
SELECT DISTINCT col2 * ( tab2.col1 + col1 ) FROM tab2
----
1292
1674
3068

query I rowsort
SELECT ALL + tab2.col2 FROM tab2, tab1 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6651
SELECT DISTINCT - CAST( col0 AS SIGNED ) - col2 * - col2 FROM tab0
----
-34
1065
6635

skipif mysql # not compatible
query I rowsort label-6651
SELECT DISTINCT - CAST ( col0 AS INTEGER ) - col2 * - col2 FROM tab0
----
-34
1065
6635

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6652
SELECT ALL CAST( col2 AS SIGNED ) - col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6652
SELECT ALL CAST ( col2 AS INTEGER ) - col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ( - 94 ) + + col2 + + 73 AS col1 FROM tab2
----
17
5
6

query I rowsort
SELECT ALL col0 + col0 - + col1 * + 85 AS col2 FROM tab2
----
-1287
-2621
-4859

query I rowsort
SELECT 35 + tab1.col0 + + col1 * ( - col1 ) * col2 FROM tab1
----
-16109
-36466
-5601

query I rowsort
SELECT + col2 + + 76 - + col0 * col1 FROM tab1 AS cor0
----
-507
-868
52

query I rowsort
SELECT - - ( - col0 ) + col2 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ( col2 ) * col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - col1 * + cor0.col0 + - cor0.col0 * - col0 + col0 AS col0 FROM tab0 AS cor0
----
-1464
-2135
-89

query I rowsort
SELECT ALL + + 16 + - col1 AS col1 FROM tab1 AS cor0
----
-10
3
6

query I rowsort
SELECT - - 44 FROM tab0 AS cor0
----
44
44
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-6662
SELECT DISTINCT col0 * col0 DIV col0 + - col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6662
SELECT DISTINCT col0 * col0 / col0 + - col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - + col2 * - col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6664
SELECT DISTINCT + col0 * col0 DIV col1 AS col0 FROM tab2 AS cor0
----
1
103
367

skipif mysql # not compatible
query I rowsort label-6664
SELECT DISTINCT + col0 * col0 / col1 AS col0 FROM tab2 AS cor0
----
1
103
367

query I rowsort
SELECT DISTINCT + 69 FROM tab0 cor0
----
69

query I rowsort
SELECT 73 + - col1 FROM tab2 AS cor0
----
14
42
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-6667
SELECT ALL - col0 DIV col2 col0 FROM tab1 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6667
SELECT ALL - col0 / col2 col0 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT - + 28 + col0 AS col1 FROM tab2 AS cor0
----
-21
50
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-6669
SELECT ALL col0 * - col2 * col1 + col1 DIV + 49 FROM tab0 AS cor0
----
-3394
-664117
-68111

skipif mysql # not compatible
query I rowsort label-6669
SELECT ALL col0 * - col2 * col1 + col1 / + 49 FROM tab0 AS cor0
----
-3394
-664117
-68111

query I rowsort
SELECT - + col2 + col1 AS col0 FROM tab0 AS cor0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 + + col0 col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT col2 * + 24 * + ( col0 ) - 14 FROM tab0 AS cor0
----
175138
18994
826

query I rowsort
SELECT ALL col1 * col0 + col2 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-6674
SELECT ALL - col2 DIV 8 + + col0 FROM tab2 cor0
----
4
75
75

skipif mysql # not compatible
query I rowsort label-6674
SELECT ALL - col2 / 8 + + col0 FROM tab2 cor0
----
4
75
75

query I rowsort
SELECT DISTINCT - col1 * - 76 + col1 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
6655
7089
7470

query I rowsort
SELECT ( col2 ) + - col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 84 + 73 * - col1 - - col1 * - col1 * col0 FROM tab0 AS cor0
----
-183698
-336312
-743568

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - cor0.col2 AS REAL ) + - col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT 46 - 96 FROM tab1 cor0
----
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-6680
SELECT ALL + ( col1 ) DIV + col1 + + 99 DIV cor0.col0 col2 FROM tab1 AS cor0
----
2
2
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6680
SELECT ALL + ( col1 ) / + col1 + + 99 / cor0.col0 col2 FROM tab1 AS cor0
----
2
2
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6681
SELECT DISTINCT 32 DIV col1 + col2 + col1 FROM tab1 AS cor0
----
111
70
81

skipif mysql # not compatible
query I rowsort label-6681
SELECT DISTINCT 32 / col1 + col2 + col1 FROM tab1 AS cor0
----
111
70
81

query I rowsort
SELECT DISTINCT + col2 + - 22 AS col1 FROM tab0 AS cor0
----
-21
11
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-6683
SELECT ALL - col2 DIV + 35 - col2 * + col0 col0 FROM tab0 AS cor0
----
-35
-7300
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6683
SELECT ALL - col2 / + 35 - col2 * + col0 col0 FROM tab0 AS cor0
----
-35
-7300
-792

query I rowsort
SELECT col1 + - 18 FROM tab1
----
-5
-8
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6685
SELECT + col2 - + 92 * - col2 DIV col2 AS col2 FROM tab0
----
125
174
93

skipif mysql # not compatible
query I rowsort label-6685
SELECT + col2 - + 92 * - col2 / col2 AS col2 FROM tab0
----
125
174
93

query I rowsort
SELECT DISTINCT - col0 * ( - col0 * + col0 ) FROM tab2
----
343
474552
493039

query I rowsort
SELECT ALL 13 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT ALL + 62 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT col2 * + col0 * - col0 + col1 FROM tab0
----
-1128
-18922
-649431

query I rowsort
SELECT ALL + col0 * - col0 * col2 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT ALL col0 - col1 * col1 AS col0 FROM tab2
----
-210
-3403
-954

query I rowsort
SELECT ALL - col0 - col0 * + col1 AS col2 FROM tab0
----
-2088
-3430
-8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col2 * col2 col0 FROM tab0
----
1175
6815
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 - + col1 col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT col2 * col1 * col0 AS col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL - col1 * - col0 + col1 + - col0 FROM tab2
----
1281
241
4583

query I rowsort
SELECT + col2 * col1 * - col1 AS col0 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT col1 * col2 + - col1 * col0 FROM tab1
----
-70
1326
208

query I rowsort
SELECT DISTINCT - tab2.col0 + col0 FROM tab2
----
0

query I rowsort
SELECT DISTINCT + col0 - col2 * - col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1190
-18984
-649433

query I rowsort
SELECT + col1 * - col0 FROM tab2 AS cor0 WHERE col2 IN ( + col1 + col0 + col1 )
----

query I rowsort
SELECT DISTINCT col0 - col0 AS col1 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col1 + - col2 col2 FROM tab0
----
53
9
96

query I rowsort
SELECT col0 * + col0 + - tab1.col2 AS col1 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT DISTINCT - col0 + tab0.col0 AS col1 FROM tab0
----
0

query I rowsort
SELECT DISTINCT + col2 + col2 + tab1.col0 * + col0 AS col1 FROM tab1
----
117
4210
6592

query I rowsort
SELECT ALL + tab1.col2 + col2 FROM tab1
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col1 + col1 * col0 col1 FROM tab1
----
1209
740
754

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT BETWEEN NULL AND NULL AND NOT NULL > ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6710
SELECT col1 * cor0.col1 DIV col0 AS col0 FROM tab1 AS cor0
----
1
2
225

skipif mysql # not compatible
query I rowsort label-6710
SELECT col1 * cor0.col1 / col0 AS col0 FROM tab1 AS cor0
----
1
2
225

query I rowsort
SELECT ALL - - col1 * - col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL - + col0 + - col0 * col0 AS col2 FROM tab1 cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT col2 + - col0 + - col2 AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + col1 FROM tab0 WHERE NOT NULL IN ( - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 * col1 col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT + cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab0
----
3
64
80

query I rowsort
SELECT + col0 + cor0.col1 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - - col0 * - col0 AS col1 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + + col2 + + col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT col0 * + cor0.col2 * col2 FROM tab0 cor0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-6721
SELECT + cor0.col1 + - col0 DIV - col0 FROM tab1 cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6721
SELECT + cor0.col1 + - col0 / - col0 FROM tab1 cor0
----
11
14
27

query I rowsort
SELECT 44 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) col1 FROM tab1
----
54
57
96

query I rowsort
SELECT col1 + col0 * + col2 * 2 FROM tab1 AS cor0
----
15373
350
7306

query I rowsort
SELECT ALL - 47 FROM tab1 AS cor0
----
-47
-47
-47

onlyif mysql # use DIV operator for integer division
query I rowsort label-6726
SELECT - - ( + col0 ) DIV 61 AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6726
SELECT - - ( + col0 ) / 61 AS col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT 19 AS col1 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6728
SELECT - col1 + - CAST( + col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort label-6728
SELECT - col1 + - CAST ( + col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6729
SELECT + + col0 DIV ( - ( col0 ) + col1 ) AS col2 FROM tab0 AS cor0
----
0
0
44

skipif mysql # not compatible
query I rowsort label-6729
SELECT + + col0 / ( - ( col0 ) + col1 ) AS col2 FROM tab0 AS cor0
----
0
0
44

query I rowsort
SELECT + cor0.col1 + - ( - 97 ) AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to fdee160142bcfd2afc7f05ad6a2f161a

query I rowsort
SELECT - col1 * col2 * tab2.col2 - - col1 * - tab2.col1 AS col0 FROM tab2
----
-23560
-24837
-43365

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + tab2.col1 + + tab2.col1 * + col2 col1 FROM tab2
----
1671
742
875

query I rowsort
SELECT col2 * col1 * + tab0.col2 FROM tab0
----
611884
93654
97

query I rowsort
SELECT ALL - tab1.col1 + + col0 + tab1.col2 FROM tab1
----
111
163
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-6735
SELECT + col1 * col0 + col0 DIV + tab1.col2 col0 FROM tab1
----
1040
641
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6735
SELECT + col1 * col0 + col0 / + tab1.col2 col0 FROM tab1
----
1040
641
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + tab2.col1 * + col2 - + col2 col2 FROM tab2
----
1567
625
841

onlyif mysql # use DIV operator for integer division
query I rowsort label-6737
SELECT DISTINCT + col0 * col0 DIV + col2 AS col2 FROM tab1
----
0
66
71

skipif mysql # not compatible
query I rowsort label-6737
SELECT DISTINCT + col0 * col0 / + col2 AS col2 FROM tab1
----
0
66
71

query I rowsort
SELECT DISTINCT col1 - col0 AS col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT ALL - col1 * - col2 + - col1 * + col1 * - col1 FROM tab0
----
638894
761033
912770

query I rowsort
SELECT DISTINCT - col0 * col0 + col1 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT + col0 + col1 + tab2.col1 FROM tab2
----
113
196
69

query I rowsort
SELECT col0 * - col2 * col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT - col1 + - col0 - + col0 AS col0 FROM tab0
----
-134
-167
-269

query I rowsort
SELECT col1 + - col0 - + col1 AS col1 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT - col1 + - col1 + col1 AS col1 FROM tab2
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6746
SELECT DISTINCT + col2 DIV + tab2.col0 col2 FROM tab2
----
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6746
SELECT DISTINCT + col2 / + tab2.col0 col2 FROM tab2
----
0
3

query I rowsort
SELECT ALL col2 - col2 AS col2 FROM tab2 WHERE NOT col0 * col2 - col0 <> NULL
----

query I rowsort
SELECT ALL - col2 AS col0 FROM tab0 WHERE + col2 - + col0 * + col2 * col2 = ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL NOT IN ( col0 )
----

query I rowsort
SELECT - col2 + + tab2.col1 * + col2 * tab2.col2 AS col0 FROM tab2
----
22572
24510
39858

onlyif mysql # use DIV operator for integer division
query I rowsort label-6751
SELECT ALL - col2 DIV col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-6751
SELECT ALL - col2 / col1 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT DISTINCT tab0.col0 + col1 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT col2 * col2 * col2 + tab1.col1 FROM tab1
----
157490
185203
884749

query I rowsort
SELECT DISTINCT col1 + - col2 * col1 FROM tab0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6755
SELECT + col2 + + cor0.col2 DIV col2 FROM tab0 cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6755
SELECT + col2 + + cor0.col2 / col2 FROM tab0 cor0
----
2
34
83

query I rowsort
SELECT ALL + tab0.col2 + col1 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT - col1 * - col0 + tab1.col0 * - col1 AS col0 FROM tab1
----
0
0
0

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( col0 ) <= NULL
----

query I rowsort
SELECT ALL - col1 * col2 + col1 AS col0 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT - col1 * - col1 + col0 FROM tab2
----
3559
368
968

query I rowsort
SELECT col0 * tab0.col1 * - tab0.col2 FROM tab0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col2 col0 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT + col0 * - col1 + col0 AS col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT + col2 FROM tab2 WHERE NOT ( col2 ) >= col0
----
26
38

query III rowsort
SELECT ALL * FROM tab0 WHERE + col1 < NULL
----

query I rowsort
SELECT - col1 + 67 AS col0 FROM tab0 AS cor0
----
-19
-24
-30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6767
SELECT + + col1 * + CAST( + col1 AS SIGNED ) FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-6767
SELECT + + col1 * + CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
7396
8281
9409

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 8e88b3a69c24fc01553b0c32bf7748d0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6769
SELECT + + col2 * col0 - - ( col1 + - CAST( NULL AS SIGNED ) ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6769
SELECT + + col2 * col0 - - ( col1 + - CAST ( NULL AS INTEGER ) ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * cor0.col2 * col1 + - cor0.col2 col2 FROM tab0 AS cor0
----
-611966
-93687
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6771
SELECT DISTINCT + col2 * + CAST( NULL AS SIGNED ) + - col2 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6771
SELECT DISTINCT + col2 * + CAST ( NULL AS INTEGER ) + - col2 col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 * cor0.col2 - + col0 * col0 AS col2 FROM tab2 AS cor0
----
-4797
-5408
680

query I rowsort
SELECT cor0.col0 + - ( 37 ) * col1 AS col1 FROM tab0 AS cor0
----
-3158
-3278
-3554

query I rowsort
SELECT 15 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT DISTINCT 15 + cor0.col0 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1358
232
4617

onlyif mysql # use DIV operator for integer division
query I rowsort label-6776
SELECT + col0 DIV + ( + col2 ) FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6776
SELECT + col0 / + ( + col2 ) FROM tab0
----
0
1
35

query I rowsort
SELECT DISTINCT 20 AS col2 FROM tab0 AS cor0
----
20

query I rowsort
SELECT ALL col1 + - col1 * col2 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6779
SELECT ( col2 ) * - col2 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6779
SELECT ( col2 ) * - col2 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * + col2 + cor0.col0 * 45 FROM tab0 AS cor0
----
-3293
1540
288

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6781
SELECT DISTINCT + col2 * - CAST( NULL AS SIGNED ) - 44 AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6781
SELECT DISTINCT + col2 * - CAST ( NULL AS INTEGER ) - 44 AS col2 FROM tab1
----
NULL

query I rowsort
SELECT + 49 * + col1 * + col0 + col0 * col2 FROM tab1 AS cor0
----
35008
3984
58640

query I rowsort
SELECT ALL + 95 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT DISTINCT tab1.col0 * - tab1.col1 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ( cor0.col0 ) + + 0 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - col1 * tab0.col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - 9 FROM tab2
----
-9
-9
-9

query I rowsort
SELECT + - col1 * col0 + + cor0.col0 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-6789
SELECT - col1 - col2 DIV col1 AS col0 FROM tab2
----
-19
-31
-59

skipif mysql # not compatible
query I rowsort label-6789
SELECT - col1 - col2 / col1 AS col0 FROM tab2
----
-19
-31
-59

query I rowsort
SELECT DISTINCT + 90 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
90

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab2, tab1 cor1
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

query I rowsort
SELECT DISTINCT - cor0.col0 * + 9 FROM tab2, tab0 AS cor0
----
-216
-315
-801

onlyif mysql # use DIV operator for integer division
query I rowsort label-6793
SELECT + col0 + 58 DIV - col0 AS col2 FROM tab2 AS cor0
----
-1
78
79

skipif mysql # not compatible
query I rowsort label-6793
SELECT + col0 + 58 / - col0 AS col2 FROM tab2 AS cor0
----
-1
78
79

query I rowsort
SELECT ALL + cor0.col1 + - 10 FROM tab1 AS cor0
----
0
16
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 + tab0.col0 col2 FROM tab0
----
139
74
85

query I rowsort
SELECT DISTINCT col2 * + 85 AS col2 FROM tab0
----
2805
6970
85

query I rowsort
SELECT - - 43 FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to 53b2f139a07f856ac44a1158efd4e63d

query I rowsort
SELECT - tab1.col1 + 84 FROM tab1
----
58
71
74

query I rowsort
SELECT DISTINCT - col1 * col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + cor0.col1 * - col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col2 * - col2 col1 FROM tab1 cor0
----
119808
32490
75816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6802
SELECT DISTINCT + + col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6802
SELECT DISTINCT + + col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - 71 FROM tab1, tab0 AS cor0
----
-71

query I rowsort
SELECT DISTINCT 80 + + col0 FROM tab1
----
144
160
83

query I rowsort
SELECT 96 - col0 FROM tab2
----
17
18
89

query I rowsort
SELECT ALL + + cor0.col0 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT + - ( 52 ) + col2 FROM tab0 AS cor0
----
-19
-51
30

query I rowsort
SELECT - - cor0.col0 + - 74 AS col0 FROM tab0 AS cor0
----
-39
-50
15

query I rowsort
SELECT 41 + tab0.col0 FROM tab0
----
130
65
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6810
SELECT DISTINCT - col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6810
SELECT DISTINCT - col0 / - col1 AS col0 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 72 + - col1 col0 FROM tab2 AS cor0
----
13
41
55

query I rowsort
SELECT DISTINCT + cor0.col2 + - col2 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + + col2 + col1 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - - cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - + 17 * - col2 AS col1 FROM tab2 AS cor0
----
442
459
646

query I rowsort
SELECT - - col2 + cor0.col0 * col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT + 62 * cor0.col2 FROM tab2 AS cor0
----
1612
1674
2356

query I rowsort
SELECT DISTINCT + - 80 * - cor0.col2 + col1 FROM tab0 AS cor0
----
177
2726
6651

query I rowsort
SELECT - + 22 * + cor0.col1 + col2 + col2 FROM tab1 AS cor0
----
-106
-464
-94

query I rowsort
SELECT DISTINCT - 36 * + col1 FROM tab2 AS cor0
----
-1116
-2124
-612

query I rowsort
SELECT + + cor0.col2 + cor0.col2 * col2 + + col0 AS col0 FROM tab0 AS cor0
----
1146
37
6895

query I rowsort
SELECT ALL + + col2 + cor0.col1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT 15 * - col0 + + 44 + col1 * col0 * 11 FROM tab1 AS cor0
----
10284
6124
857

query I rowsort
SELECT + + ( - col1 ) + + col0 * col2 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-114093
-5134
-52787

onlyif mysql # use DIV operator for integer division
query I rowsort label-6825
SELECT ALL - col2 DIV 61 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6825
SELECT ALL - col2 / 61 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 25 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * - 78 col1 FROM tab2 AS cor0
----
2028
2106
2964

query I rowsort
SELECT ALL - - col1 * - col0 - cor0.col2 FROM tab2 cor0
----
-1381
-244
-4628

query I rowsort
SELECT + ( - col0 ) * col1 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT 64 + - col0 + + cor0.col2 FROM tab0 AS cor0
----
30
57
73

query I rowsort
SELECT cor0.col2 + 20 * col0 FROM tab0 cor0
----
1862
513
701

query I rowsort
SELECT ALL cor2.col0 * cor2.col1 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to cd698a6bd20d23f9770732b6dce94e1e

query I rowsort
SELECT col0 * - 84 + col1 FROM tab2 cor0
----
-557
-6493
-6619

query I rowsort
SELECT ALL - 14 * col2 AS col2 FROM tab0
----
-1148
-14
-462

query I rowsort
SELECT cor0.col0 * + col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6836
SELECT DISTINCT + CAST( col1 * col1 AS SIGNED ) AS col2 FROM tab1
----
100
169
676

skipif mysql # not compatible
query I rowsort label-6836
SELECT DISTINCT + CAST ( col1 * col1 AS INTEGER ) AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT + col2 + - 88 FROM tab0 AS cor0
----
-55
-6
-87

query I rowsort
SELECT col0 * - col1 + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-6839
SELECT col1 DIV - 5 AS col0 FROM tab1 AS cor0
----
-2
-2
-5

skipif mysql # not compatible
query I rowsort label-6839
SELECT col1 / - 5 AS col0 FROM tab1 AS cor0
----
-2
-2
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6840
SELECT ALL + cor0.col0 DIV - ( + col1 ) AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6840
SELECT ALL + cor0.col0 / - ( + col1 ) AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 - - col0 * - 41 AS col2 FROM tab2 AS cor0
----
-260
-3172
-3201

query I rowsort
SELECT ALL - col2 + cor0.col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT col0 + - tab1.col0 + ( 92 ) AS col2 FROM tab1
----
92
92
92

query I rowsort
SELECT + col1 + col1 * ( - col2 ) * col1 FROM tab2
----
-10965
-25916
-90447

query I rowsort
SELECT - col1 * - col2 AS col2 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6846
SELECT DISTINCT + tab2.col1 + - col2 DIV tab2.col0 AS col1 FROM tab2
----
17
28
59

skipif mysql # not compatible
query I rowsort label-6846
SELECT DISTINCT + tab2.col1 + - col2 / tab2.col0 AS col1 FROM tab2
----
17
28
59

query I rowsort
SELECT - col0 + ( col0 ) AS col1 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6848
SELECT DISTINCT + col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6848
SELECT DISTINCT + col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query I rowsort
SELECT col2 * + 2 * 9 + col0 FROM tab1
----
1090
1808
975

query I rowsort
SELECT col2 * col1 * + col1 AS col2 FROM tab1 cor0
----
16224
36504
5700

query I rowsort
SELECT ALL + col1 * + col0 + col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - col2 * + ( 16 ) AS col2 FROM tab1 cor0
----
-1536
-864
-912

query I rowsort
SELECT DISTINCT + cor0.col0 * - col1 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT col1 * 23 + - col1 * + col2 FROM tab0 AS cor0
----
-5369
-860
2134

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * - 7 + col2 * + col2 col2 FROM tab2 AS cor0
----
1325
263
512

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - 39 col0 FROM tab2 cor0
----
-22
-8
20

query I rowsort
SELECT - col1 * 97 * col0 FROM tab1 AS cor0
----
-100880
-62080
-7566

query I rowsort
SELECT - col1 + - 33 + col2 * - col0 * cor0.col2 FROM tab2 AS cor0
----
-114126
-5167
-52820

query I rowsort
SELECT + tab1.col1 * + col0 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT + + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col2 + col2 col1 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6863
SELECT + cor0.col1 DIV + CAST( col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6863
SELECT + cor0.col1 / + CAST ( col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col1 col1 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6865
SELECT + ( - col1 ) DIV col1 + col0 + col1 AS col2 FROM tab1 AS cor0
----
28
73
92

skipif mysql # not compatible
query I rowsort label-6865
SELECT + ( - col1 ) / col1 + col0 + col1 AS col2 FROM tab1 AS cor0
----
28
73
92

query I rowsort
SELECT tab0.col0 - + tab0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 4646ed87e8cc5aacb51f9b4e472c3c4b

query I rowsort
SELECT + - 4 * col0 FROM tab1 AS cor0
----
-12
-256
-320

query I rowsort
SELECT col1 + - col1 * col1 * col2 + cor0.col2 FROM tab1 cor0
----
-16115
-36424
-5633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + - col2 + col2 col2 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6870
SELECT + + 50 + - 41 * col1 + + col2 DIV + col1 FROM tab0 AS cor0
----
-3476
-3681
-3927

skipif mysql # not compatible
query I rowsort label-6870
SELECT + + 50 + - 41 * col1 + + col2 / + col1 FROM tab0 AS cor0
----
-3476
-3681
-3927

query I rowsort
SELECT col2 + 96 * + col1 FROM tab0 AS cor0
----
8289
8818
9313

query I rowsort
SELECT 80 + - col0 * col1 FROM tab1 AS cor0
----
-560
-960
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col2 col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL + 28 * col2 - 14 FROM tab1 AS cor0
----
1498
1582
2674

query I rowsort
SELECT DISTINCT + - cor0.col1 * col2 * col2 + + col1 AS col2 FROM tab0 AS cor0
----
-611793
-93568
0

query I rowsort
SELECT DISTINCT + col1 + - col0 * - ( col1 ) FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL + 7 * col2 FROM tab0 AS cor0
----
231
574
7

query I rowsort
SELECT col0 * col0 + + 66 FROM tab1 AS cor0
----
4162
6466
75

query I rowsort
SELECT col2 + + 12 * 21 AS col1 FROM tab0 AS cor0
----
253
285
334

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( - 99 * - col2 AS REAL ) AS col1 FROM tab0
----
-3267
-8118
-99

query I rowsort
SELECT ( cor0.col0 ) * 51 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to ccc3a14ecb39f25d1c0eb4d30fb3b898

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col2 AS REAL ) AS col1 FROM tab1
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6883
SELECT DISTINCT + CAST( NULL AS SIGNED ) * tab1.col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6883
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * tab1.col2 FROM tab1
----
NULL

query I rowsort
SELECT col2 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + tab2.col2 * ( - col0 ) AS col2 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col1 col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT + - col0 + col1 * 54 FROM tab0 AS cor0
----
4620
4825
5203

query I rowsort
SELECT - 99 * col1 + - ( 43 ) FROM tab2 cor0
----
-1726
-3112
-5884

query I rowsort
SELECT + 57 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT ALL tab1.col0 + - col2 * - col1 AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT col2 + ( + col0 ) * col0 AS col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT cor0.col1 * 59 FROM tab0 AS cor0
----
5074
5369
5723

query I rowsort
SELECT - + col2 * - 93 + col1 FROM tab1 AS cor0
----
5048
5311
8941

query I rowsort
SELECT ALL + - col0 + - 83 FROM tab1 cor0
----
-147
-163
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-6895
SELECT + - col2 * ( col1 ) + + col2 DIV - col0 FROM tab0 AS cor0
----
-2839
-7462
-97

skipif mysql # not compatible
query I rowsort label-6895
SELECT + - col2 * ( col1 ) + + col2 / - col0 FROM tab0 AS cor0
----
-2839
-7462
-97

query I rowsort
SELECT + - col1 * - col0 + + cor0.col2 * + col1 AS col1 FROM tab0 AS cor0
----
15561
3492
4902

onlyif mysql # use DIV operator for integer division
query I rowsort label-6897
SELECT - col1 * + ( 6 ) * col1 + - col0 DIV col1 FROM tab1 AS cor0
----
-1020
-4056
-606

skipif mysql # not compatible
query I rowsort label-6897
SELECT - col1 * + ( 6 ) * col1 + - col0 / col1 FROM tab1 AS cor0
----
-1020
-4056
-606

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 71 * col0 + + cor0.col2 col0 FROM tab2 AS cor0
----
524
5564
5647

query I rowsort
SELECT DISTINCT - col2 * + cor0.col0 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6900
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6900
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + col1 FROM tab1 cor0
----
NULL

query I rowsort
SELECT DISTINCT 60 AS col2 FROM tab0, tab2 AS cor0
----
60

query I rowsort
SELECT DISTINCT + - 8 FROM tab1 AS cor0
----
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6903
SELECT - - 82 * col0 DIV + col2 + col0 * col0 AS col1 FROM tab1 AS cor0
----
13
4188
6468

skipif mysql # not compatible
query I rowsort label-6903
SELECT - - 82 * col0 / + col2 + col0 * col0 AS col1 FROM tab1 AS cor0
----
13
4188
6468

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6904
SELECT CAST( col2 AS SIGNED ) * col0 + - col0 AS col2 FROM tab0 AS cor0
----
0
7209
768

skipif mysql # not compatible
query I rowsort label-6904
SELECT CAST ( col2 AS INTEGER ) * col0 + - col0 AS col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT - cor0.col2 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT ALL 47 + 26 AS col2 FROM tab1 cor0
----
73
73
73

query I rowsort
SELECT - 12 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT DISTINCT col2 - col2 * - col2 * col2 AS col2 FROM tab2 AS cor0
----
17602
19710
54910

query I rowsort
SELECT ALL + ( + ( - col1 ) ) * 78 FROM tab0 AS cor0
----
-6708
-7098
-7566

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6910
SELECT DISTINCT + CAST( NULL AS DECIMAL ) * 9 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6910
SELECT DISTINCT + CAST ( NULL AS REAL ) * 9 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + + 64 + - col1 * + col2 FROM tab2 AS cor0
----
-1470
-582
-773

query I rowsort
SELECT 13 + + col1 AS col2 FROM tab0 cor0
----
104
110
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-6913
SELECT ALL - col2 DIV - col0 + + col0 * col0 FROM tab2 AS cor0
----
52
6084
6241

skipif mysql # not compatible
query I rowsort label-6913
SELECT ALL - col2 / - col0 + + col0 * col0 FROM tab2 AS cor0
----
52
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 - + ( col2 * + 15 ) col2 FROM tab1 cor0
----
-1344
-756
-798

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6915
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col2 + col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6915
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col2 + col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - ( - col1 ) * - cor0.col0 - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-6917
SELECT ALL - 98 DIV col2 AS col0 FROM tab0 AS cor0
----
-1
-2
-98

skipif mysql # not compatible
query I rowsort label-6917
SELECT ALL - 98 / col2 AS col0 FROM tab0 AS cor0
----
-1
-2
-98

query I rowsort
SELECT ALL - + ( - cor0.col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + - col2 * col2 AS col1 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - - col2 * - col1 - col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT ALL + - 54 * col0 - - col0 FROM tab2 AS cor0
----
-371
-4134
-4187

query I rowsort
SELECT DISTINCT - + ( col0 ) * - col0 + cor0.col0 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-6923
SELECT ALL - tab2.col0 * 24 DIV + col1 - col0 FROM tab2
----
-109
-12
-190

skipif mysql # not compatible
query I rowsort label-6923
SELECT ALL - tab2.col0 * 24 / + col1 - col0 FROM tab2
----
-109
-12
-190

query I rowsort
SELECT DISTINCT + - 75 FROM tab1 cor0
----
-75

query I rowsort
SELECT ALL - 77 * 41 + col1 * ( col2 * - cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-19381
-39661
-8857

query I rowsort
SELECT ALL col0 + + ( col2 + 89 ) AS col2 FROM tab2 cor0
----
123
193
206

query I rowsort
SELECT DISTINCT 70 + - col0 FROM tab0 AS cor0
----
-19
35
46

query I rowsort
SELECT ALL + + col1 + - col1 * col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL cor0.col2 * tab2.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to bbf44891fdcfbe372162a2e549d3eeed

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6930
SELECT ALL + CAST( NULL AS DECIMAL ) * 15 + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6930
SELECT ALL + CAST ( NULL AS REAL ) * 15 + col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 10 + - col2 AS col2 FROM tab1 AS cor0
----
-44
-47
-86

query I rowsort
SELECT - ( cor0.col0 ) FROM tab0, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT DISTINCT - + col2 * + col2 * ( + cor0.col2 ) FROM tab0 AS cor0
----
-1
-35937
-551368

query I rowsort
SELECT DISTINCT + cor0.col2 * + col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - - col2 + col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - ( cor1.col1 ) FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT ALL - col1 * - tab2.col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT - tab2.col0 + col1 AS col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT - col0 * + 3 AS col2 FROM tab2
----
-21
-234
-237

query I rowsort
SELECT + col1 * + col1 + col1 + + col1 AS col2 FROM tab0
----
7568
8463
9603

query I rowsort
SELECT - 81 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

query I rowsort
SELECT col2 + + col2 * + col2 AS col1 FROM tab2
----
1482
702
756

query I rowsort
SELECT ALL - tab2.col1 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL + col1 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 + - col1 * + col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT col0 + - ( col1 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - col2 + col1 * - 72 * col0 AS col1 FROM tab1
----
-46137
-5670
-74976

onlyif mysql # use DIV operator for integer division
query I rowsort label-6948
SELECT + 29 + col0 * 17 + col0 DIV col1 AS col1 FROM tab1 AS cor0
----
1123
1395
80

skipif mysql # not compatible
query I rowsort label-6948
SELECT + 29 + col0 * 17 + col0 / col1 AS col1 FROM tab1 AS cor0
----
1123
1395
80

query I rowsort
SELECT + col2 + col1 * col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL - - col1 * cor0.col1 + col1 FROM tab1 cor0
----
110
182
702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * cor0.col0 + - col2 + + col2 col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - + col0 * col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6953
SELECT DISTINCT + - cor0.col1 * col2 DIV col1 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6953
SELECT DISTINCT + - cor0.col1 * col2 / col1 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL col2 * + col2 + + cor0.col1 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT - + cor0.col0 + + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + - col1 + + col1 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT - col0 + + col2 + 58 * - 79 AS col1 FROM tab2 AS cor0
----
-4562
-4623
-4634

query I rowsort
SELECT + + col0 + col1 + col1 AS col0 FROM tab2 cor0
----
113
196
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-6959
SELECT - col0 * CAST( cor0.col1 * col1 AS SIGNED ) + + col0 + + col2 DIV + col1 AS col0 FROM tab0 AS cor0
----
-177480
-329280
-736920

skipif mysql # not compatible
query I rowsort label-6959
SELECT - col0 * CAST ( cor0.col1 * col1 AS INTEGER ) + + col0 + + col2 / + col1 AS col0 FROM tab0 AS cor0
----
-177480
-329280
-736920

query I rowsort
SELECT col1 * col1 + 9 FROM tab2 AS cor0
----
298
3490
970

query I rowsort
SELECT ALL - - col0 * + 29 * - col0 AS col0 FROM tab2 AS cor0
----
-1421
-176436
-180989

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6962
SELECT - + col0 + - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6962
SELECT - + col0 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + col0 + col0 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
1501
231
4758

query I rowsort
SELECT DISTINCT - col1 * col1 - col2 * 79 FROM tab0 AS cor0
----
-10003
-14759
-9488

query I rowsort
SELECT - + cor0.col0 - + col0 FROM tab2 cor0
----
-14
-156
-158

query I rowsort
SELECT ALL + 39 FROM tab0, tab2 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT DISTINCT + ( 88 ) AS col1 FROM tab1, tab0, tab2 AS cor0
----
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6968
SELECT tab1.col1 DIV - col1 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6968
SELECT tab1.col1 / - col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT + 49 * + 54 - col1 FROM tab0 AS cor0
----
2549
2555
2560

query I rowsort
SELECT + ( cor0.col0 ) AS col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - + col2 * + 38 FROM tab1 AS cor0
----
-2052
-2166
-3648

query I rowsort
SELECT ALL + 87 FROM tab0, tab0 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

onlyif mysql # use DIV operator for integer division
query I rowsort label-6973
SELECT - - 19 DIV - cor0.col2 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-20
-33
-82

skipif mysql # not compatible
query I rowsort label-6973
SELECT - - 19 / - cor0.col2 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-20
-33
-82

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( + 23 AS REAL ) * col0 + - col0 FROM tab0
----
1958
528
770

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - 41 + col0 AS col1 FROM tab2
----
-34
37
38

query I rowsort
SELECT - 24 * col2 + col1 FROM tab0
----
-1877
-706
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-6978
SELECT - 78 DIV 75 AS col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6978
SELECT - 78 / 75 AS col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT ALL + tab2.col1 + 21 * col0 AS col1 FROM tab2
----
1676
1697
178

onlyif mysql # use DIV operator for integer division
query I rowsort label-6980
SELECT - 12 * ( tab1.col0 ) + + col0 DIV 87 AS col2 FROM tab1
----
-36
-768
-960

skipif mysql # not compatible
query I rowsort label-6980
SELECT - 12 * ( tab1.col0 ) + + col0 / 87 AS col2 FROM tab1
----
-36
-768
-960

query I rowsort
SELECT col0 * 88 * col2 AS col0 FROM tab2
----
16632
178464
264176

onlyif mysql # use DIV operator for integer division
query I rowsort label-6982
SELECT + col1 DIV + col2 AS col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-6982
SELECT + col1 / + col2 AS col2 FROM tab0
----
1
2
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6983
SELECT - 37 DIV col1 FROM tab2
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-6983
SELECT - 37 / col1 FROM tab2
----
-1
-2
0

query I rowsort
SELECT col1 * 91 AS col2 FROM tab1
----
1183
2366
910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6985
SELECT + CAST( NULL AS SIGNED ) * col1 + col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6985
SELECT + CAST ( NULL AS INTEGER ) * col1 + col2 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 87 + - col0 * col2 + + col0 FROM tab0 AS cor0
----
-681
-7122
87

query I rowsort
SELECT DISTINCT tab2.col2 AS col1 FROM tab1, tab2 AS cor0 CROSS JOIN tab2
----
26
27
38

query I rowsort
SELECT DISTINCT - 42 FROM tab0
----
-42

query I rowsort
SELECT ALL - 55 + - col0 FROM tab0 AS cor0
----
-144
-79
-90

query I rowsort
SELECT + 93 * + col1 AS col1 FROM tab1
----
1209
2418
930

query I rowsort
SELECT - 97 * - col2 * - col2 FROM tab1
----
-282852
-315153
-893952

query I rowsort
SELECT + tab0.col2 + + 12 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 2262c2f3e3d5cc56cd9d52c97ca1ab4a

query I rowsort
SELECT - tab2.col2 * ( 84 ) AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to b96fedf9fbfe88afd04ebfb12fe2505f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6994
SELECT ALL - col2 - col0 * + CAST( + col2 * + col2 AS SIGNED ) AS col2 FROM tab1
----
-207993
-737376
-8802

skipif mysql # not compatible
query I rowsort label-6994
SELECT ALL - col2 - col0 * + CAST ( + col2 * + col2 AS INTEGER ) AS col2 FROM tab1
----
-207993
-737376
-8802

onlyif mysql # use DIV operator for integer division
query I rowsort label-6995
SELECT ALL 42 DIV cor0.col0 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 91d23a8b629ea0867783bcad6f1c0085

skipif mysql # not compatible
query I rowsort label-6995
SELECT ALL 42 / cor0.col0 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 91d23a8b629ea0867783bcad6f1c0085

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 2 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT ALL + col1 * tab0.col2 * + ( + col2 ) FROM tab0
----
611884
93654
97

query I rowsort
SELECT + col0 + col1 * - col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - - 6 + 69 AS col0 FROM tab1 AS cor0
----
75
75
75

query I rowsort
SELECT + 85 * col0 AS col0 FROM tab2 cor0
----
595
6630
6715

query I rowsort
SELECT ALL + tab2.col1 * tab2.col0 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-7002
SELECT ALL + col1 DIV ( - col2 ) AS col2 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-7002
SELECT ALL + col1 / ( - col2 ) AS col2 FROM tab0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 58 col0 FROM tab2
----
-58
-58
-58

query I rowsort
SELECT - cor0.col0 * + ( - col0 ) AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ( 53 ) + col0 FROM tab2 cor0
----
131
132
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-7006
SELECT + col1 DIV + 96 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7006
SELECT + col1 / + 96 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 + 18 FROM tab2 AS cor0
----
44
45
56

query I rowsort
SELECT - col2 * col0 + + col2 + col2 FROM tab1 AS cor0
----
-3534
-54
-7488

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 80 * - col0 col1 FROM tab2
----
-560
-6240
-6320

query I rowsort
SELECT ALL + col2 + 35 * - 67 FROM tab1 AS cor0
----
-2249
-2288
-2291

onlyif mysql # use DIV operator for integer division
query I rowsort label-7011
SELECT ALL + col0 DIV - 8 AS col0 FROM tab0 AS cor0
----
-11
-3
-4

skipif mysql # not compatible
query I rowsort label-7011
SELECT ALL + col0 / - 8 AS col0 FROM tab0 AS cor0
----
-11
-3
-4

query I rowsort
SELECT + col1 * + tab2.col0 - 26 FROM tab2
----
1317
191
4576

query I rowsort
SELECT - 65 + + col0 * col2 FROM tab2
----
124
1963
2937

query I rowsort
SELECT DISTINCT - col2 + - tab1.col0 + + 81 * 28 * + col0 AS col1 FROM tab1
----
145031
181264
6747

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 87 col0 FROM tab2
----
-87
-87
-87

query I rowsort
SELECT ALL - 46 * col0 FROM tab2
----
-322
-3588
-3634

query I rowsort
SELECT DISTINCT 73 * col1 FROM tab0
----
6278
6643
7081

query I rowsort
SELECT + cor0.col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + col0 + - 70 * col0 AS col0 FROM tab2
----
-483
-5382
-5451

query I rowsort
SELECT ALL + - col2 * + 4 AS col1 FROM tab2 AS cor0
----
-104
-108
-152

query I rowsort
SELECT + + col0 * 78 * + 98 FROM tab1 AS cor0
----
22932
489216
611520

query I rowsort
SELECT ( ( + tab0.col2 ) ) AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT + ( - tab2.col0 ) AS col1 FROM tab2
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7024
SELECT ( col1 + - col0 ) DIV - col0 FROM tab1
----
-7
0
0

skipif mysql # not compatible
query I rowsort label-7024
SELECT ( col1 + - col0 ) / - col0 FROM tab1
----
-7
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7025
SELECT - 41 DIV + 32 AS col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7025
SELECT - 41 / + 32 AS col0 FROM tab1
----
-1
-1
-1

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0, tab0, tab2 AS cor1
----
972 values hashing to 591a9a93560839231c038a1e10bd240a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7027
SELECT - ( 50 + col1 ) DIV col0 AS col0 FROM tab2
----
-1
-11
0

skipif mysql # not compatible
query I rowsort label-7027
SELECT - ( 50 + col1 ) / col0 AS col0 FROM tab2
----
-1
-11
0

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( ( col1 ) AS REAL ) + - ( + col0 ) + col0 AS col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7029
SELECT col2 DIV 17 FROM tab0 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-7029
SELECT col2 / 17 FROM tab0 AS cor0
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-7030
SELECT - ( col1 ) DIV col1 - + ( - cor0.col1 ) * - col0 col1 FROM tab1 AS cor0
----
-1041
-641
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7030
SELECT - ( col1 ) / col1 - + ( - cor0.col1 ) * - col0 col1 FROM tab1 AS cor0
----
-1041
-641
-79

query I rowsort
SELECT - + col1 + cor0.col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 * - cor0.col1 + 93 + + cor0.col1 AS col1 FROM tab2 cor0
----
-1233
-4450
-93

query I rowsort
SELECT DISTINCT col1 + - col0 + 21 AS col1 FROM tab0
----
23
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7034
SELECT + 88 DIV + col0 + + col1 FROM tab1
----
11
14
55

skipif mysql # not compatible
query I rowsort label-7034
SELECT + 88 / + col0 + + col1 FROM tab1
----
11
14
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 47 col1 FROM tab1, tab1 AS cor0
----
-47

query I rowsort
SELECT + col0 + col0 + + 35 * - col0 FROM tab1 AS cor0
----
-2112
-2640
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + 91 col0 FROM tab2
----
637
7098
7189

query I rowsort
SELECT 36 * col1 + + col2 * + col0 + col2 AS col2 FROM tab2 AS cor0
----
1332
3652
4178

query I rowsort
SELECT col2 + + col2 * - ( col0 ) AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - col0 * - col2 + col2 FROM tab2 AS cor0
----
2054
216
3040

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab2 cor1, tab0 cor2
----
972 values hashing to deaaa983f771be544ffdc26f04a18657

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 + 7 col2 FROM tab2 AS cor0
----
163
165
21

query I rowsort
SELECT ALL + + cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

onlyif mysql # use DIV operator for integer division
query I rowsort label-7044
SELECT DISTINCT - - col0 DIV col0 + col2 AS col1 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-7044
SELECT DISTINCT - - col0 / col0 + col2 AS col1 FROM tab1 AS cor0
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7045
SELECT + + col0 * col1 DIV col0 + - col2 * col1 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif mysql # not compatible
query I rowsort label-7045
SELECT + + col0 * col1 / col0 + - col2 * col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT + 53 * col0 - col1 FROM tab2 AS cor0
----
340
4075
4170

query I rowsort
SELECT DISTINCT - col0 + + col0 AS col0 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7048
SELECT DISTINCT - col1 + - col0 DIV col2 FROM tab0 AS cor0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-7048
SELECT DISTINCT - col1 + - col0 / col2 FROM tab0 AS cor0
----
-132
-86
-92

query I rowsort
SELECT DISTINCT - col0 + col0 + cor0.col1 * - cor0.col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-7050
SELECT ALL - - cor0.col1 DIV col2 + col1 * + col1 AS col0 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-7050
SELECT ALL - - cor0.col1 / col2 + col1 * + col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT + col2 * col0 * col0 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT - 68 + + col1 AS col2 FROM tab1 AS cor0
----
-42
-55
-58

query I rowsort
SELECT ALL + col0 * - col2 - cor0.col2 * col0 FROM tab0 AS cor0
----
-14596
-1584
-70

query I rowsort
SELECT ALL + - col0 * + col2 - col2 * col0 FROM tab0 AS cor0
----
-14596
-1584
-70

query I rowsort
SELECT ALL - 37 AS col1 FROM tab0 AS cor0
----
-37
-37
-37

query I rowsort
SELECT + cor0.col0 - col2 * col1 * col1 AS col0 FROM tab1 AS cor0
----
-16144
-36501
-5636

query I rowsort
SELECT DISTINCT col2 + col2 + col2 AS col0 FROM tab0 AS cor0
----
246
3
99

query I rowsort
SELECT DISTINCT + + 91 + + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-701
-7207
56

query I rowsort
SELECT ALL - + 2 * + col2 * + col2 FROM tab0 cor0
----
-13448
-2
-2178

query I rowsort
SELECT DISTINCT + ( - col0 ) * cor0.col2 + - col0 + - col2 AS col2 FROM tab1 AS cor0
----
-219
-3769
-7856

query I rowsort
SELECT col2 * col2 + col0 * col2 AS col0 FROM tab0 AS cor0
----
14022
1881
36

query I rowsort
SELECT ALL + - 18 * cor0.col1 AS col0 FROM tab2 cor0
----
-1062
-306
-558

query I rowsort
SELECT DISTINCT - col1 + + col2 + - col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - - col1 * col1 + + col2 AS col0 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL - cor0.col0 * - col1 * col0 + + cor0.col0 FROM tab0 AS cor0
----
118860
49560
720900

query I rowsort
SELECT DISTINCT - cor0.col1 + - col2 * - cor0.col1 * + col1 AS col2 FROM tab1 AS cor0
----
16211
36478
5690

query I rowsort
SELECT DISTINCT - col0 * col0 - col1 AS col0 FROM tab1 cor0
----
-35
-4106
-6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-7068
SELECT col0 DIV col0 + cor0.col2 * + col0 * col2 FROM tab2 AS cor0
----
114077
5104
52729

skipif mysql # not compatible
query I rowsort label-7068
SELECT col0 / col0 + cor0.col2 * + col0 * col2 FROM tab2 AS cor0
----
114077
5104
52729

query I rowsort
SELECT ALL + col2 + col0 * col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT + col2 - col2 * + col0 FROM tab1
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-7071
SELECT ALL tab1.col1 + - col2 DIV - col1 col2 FROM tab1
----
15
20
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7071
SELECT ALL tab1.col1 + - col2 / - col1 col2 FROM tab1
----
15
20
28

query I rowsort
SELECT DISTINCT + ( + col2 ) * col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - 78 * + col0 AS col2 FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT ALL + 9 + 80 * - col0 FROM tab0 AS cor0
----
-1911
-2791
-7111

query I rowsort
SELECT ALL col0 + ( + cor0.col0 ) AS col2 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT ( cor0.col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 12 col2 FROM tab1 AS cor0
----
12
12
12

query I rowsort
SELECT DISTINCT col2 + - col2 AS col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col1 col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT ALL + col0 * - col0 * - col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT ALL + cor1.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - - ( cor0.col0 ) - - col1 * col2 FROM tab0 AS cor0
----
132
2862
7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 37 col1 FROM tab0
----
-37
-37
-37

query I rowsort
SELECT ALL - 55 * - col2 AS col0 FROM tab1
----
2970
3135
5280

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 96 * + col1 + cor0.col2 col2 FROM tab1 cor0
----
-1152
-2442
-903

query I rowsort
SELECT col1 * col2 * col0 + - cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
3298
65274
656656

query I rowsort
SELECT ALL - cor0.col0 + - col0 + - col0 FROM tab0 AS cor0
----
-105
-267
-72

query I rowsort
SELECT ALL - 33 AS col2 FROM tab0
----
-33
-33
-33

query I rowsort
SELECT ALL - 43 FROM tab1
----
-43
-43
-43

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * + ( cor0.col0 ) * + col2 col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-7092
SELECT + col0 DIV 18 AS col0 FROM tab0 AS cor0
----
1
1
4

skipif mysql # not compatible
query I rowsort label-7092
SELECT + col0 / 18 AS col0 FROM tab0 AS cor0
----
1
1
4

query I rowsort
SELECT ALL - tab0.col1 + - col1 FROM tab0
----
-172
-182
-194

query I rowsort
SELECT ALL - col2 * ( + col0 ) AS col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7095
SELECT ALL 83 DIV + 30 AS col0 FROM tab2
----
2
2
2

skipif mysql # not compatible
query I rowsort label-7095
SELECT ALL 83 / + 30 AS col0 FROM tab2
----
2
2
2

query I rowsort
SELECT + 70 + 17 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 969f31ae779866644763e8a07f1ec501

onlyif mysql # use DIV operator for integer division
query I rowsort label-7097
SELECT + + col1 * - col1 DIV + col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7097
SELECT + + col1 * - col1 / + col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + 91 * - col2 FROM tab2
----
-2366
-2457
-3458

query I rowsort
SELECT DISTINCT - col2 * col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + 40 * - col1 + col1 FROM tab0 AS cor0
----
-3354
-3549
-3783

query I rowsort
SELECT - ( col1 ) + + col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + 97 FROM tab0 AS cor0
----
-97
-97
-97

query I rowsort
SELECT + 82 * + col1 FROM tab0 AS cor0
----
7052
7462
7954

query I rowsort
SELECT DISTINCT - - 23 FROM tab2, tab0, tab0 AS cor0
----
23

query I rowsort
SELECT DISTINCT - 17 FROM tab2
----
-17

query I rowsort
SELECT 35 * col1 + + col2 AS col2 FROM tab0
----
3043
3267
3396

query I rowsort
SELECT ALL 33 + col0 AS col0 FROM tab0 AS cor0
----
122
57
68

query I rowsort
SELECT - 19 + col0 FROM tab0 cor0
----
16
5
70

query I rowsort
SELECT DISTINCT + col0 + + col1 * + 24 AS col2 FROM tab1 AS cor0
----
304
392
627

query I rowsort
SELECT ALL - 77 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT DISTINCT col1 - col1 AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7112
SELECT DISTINCT - 95 DIV col1 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7112
SELECT DISTINCT - 95 / col1 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT ALL - + 48 + col0 * 38 FROM tab1 AS cor0
----
2384
2992
66

query I rowsort
SELECT ALL + cor0.col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col2 + ( + col2 ) + - col0 AS col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + - col1 + col0 * col2 AS col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT col2 * 88 FROM tab1 AS cor0
----
4752
5016
8448

query I rowsort
SELECT ALL + col0 * + ( + col2 + - col0 ) AS col0 FROM tab0 AS cor0
----
-1190
-623
216

query I rowsort
SELECT DISTINCT col2 + - 55 FROM tab1 AS cor0
----
-1
2
41

query I rowsort
SELECT - col0 * - 56 AS col1 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT ALL - col0 * + col1 AS col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + col1 + - col2 * + col0 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL 15 * col1 AS col0 FROM tab2
----
255
465
885

onlyif mysql # use DIV operator for integer division
query I rowsort label-7124
SELECT ALL - col2 DIV - col2 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7124
SELECT ALL - col2 / - col2 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT - col1 + - ( - col2 ) * - col0 AS col1 FROM tab1 cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL - ( - cor0.col0 ) AS col1 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT cor0.col1 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT DISTINCT + - col2 + col2 * + col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT DISTINCT - ( + 77 ) + + cor0.col0 * col2 AS col1 FROM tab1 AS cor0
----
3571
7603
85

query I rowsort
SELECT ALL 99 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - 82 col1 FROM tab2
----
-574
-6396
-6478

onlyif mysql # use DIV operator for integer division
query I rowsort label-7132
SELECT + col0 * cor0.col2 DIV 61 + - col2 FROM tab0 AS cor0
----
-1
-21
37

skipif mysql # not compatible
query I rowsort label-7132
SELECT + col0 * cor0.col2 / 61 + - col2 FROM tab0 AS cor0
----
-1
-21
37

query I rowsort
SELECT ( - cor0.col1 ) * cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + + cor0.col0 + + cor0.col2 * + col2 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - col2 + + col0 * - ( col2 ) FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT + 96 * col1 FROM tab1 AS cor0
----
1248
2496
960

query I rowsort
SELECT + cor0.col2 + + col2 * + 75 FROM tab0 AS cor0
----
2508
6232
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7138
SELECT + 23 + + col0 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7138
SELECT + 23 + + col0 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * + tab0.col1 AS col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT 92 * - 35 FROM tab0
----
-3220
-3220
-3220

query I rowsort
SELECT ALL + 78 * 13 FROM tab1
----
1014
1014
1014

query I rowsort
SELECT ALL 8 FROM tab1, tab2 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT ALL 9 + + ( - col1 * col0 ) FROM tab2
----
-1334
-208
-4593

query I rowsort
SELECT 14 * - tab2.col1 AS col2 FROM tab2
----
-238
-434
-826

query I rowsort
SELECT + ( col2 * col1 ) FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7146
SELECT ALL + col2 DIV - col2 + - ( + col1 ) * - col0 AS col0 FROM tab0 AS cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-7146
SELECT ALL + col2 / - col2 + - ( + col1 ) * - col0 AS col0 FROM tab0 AS cor0
----
2063
3394
8098

query I rowsort
SELECT - col1 * cor0.col1 + col1 AS col2 FROM tab0 cor0
----
-7310
-8190
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( cor0.col2 ) * + cor0.col1 col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL 46 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT DISTINCT + 62 * + col2 + - ( + col2 ) * col1 FROM tab0 cor0
----
-2378
-35
-792

query I rowsort
SELECT ALL 84 * cor0.col2 * - ( - 4 ) + col2 FROM tab1 AS cor0
----
18198
19209
32352

query I rowsort
SELECT - col1 + - col0 + col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT - 70 AS col0 FROM tab0 AS cor0
----
-70
-70
-70

query I rowsort
SELECT + col2 * col0 + col0 * + col1 AS col1 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT ALL + 64 + + col0 AS col1 FROM tab2 AS cor0
----
142
143
71

query I rowsort
SELECT DISTINCT cor0.col2 + - col0 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - + 14 + cor0.col1 FROM tab1 AS cor0
----
-1
-4
12

query I rowsort
SELECT - - col1 + + col1 * col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col2 * + col2 + + 26 + - col0 AS col0 FROM tab1 AS cor0
----
2939
3211
9162

query I rowsort
SELECT ALL cor0.col0 * - col1 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - - col0 * - col0 + ( - col0 ) FROM tab0 AS cor0
----
-1260
-600
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 * + 54 + + col2 col2 FROM tab2 AS cor0
----
15644
188000
51921

query I rowsort
SELECT ALL - col2 + + col0 * col1 + col1 AS col0 FROM tab0 AS cor0
----
2117
3491
8108

query I rowsort
SELECT DISTINCT + col2 * col2 AS col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + col2 + - 47 AS col1 FROM tab2 AS cor0
----
-20
-21
-9

query I rowsort
SELECT DISTINCT + col0 + col1 + col2 AS col2 FROM tab0
----
133
143
262

query I rowsort
SELECT - 40 * - col2 FROM tab2
----
1040
1080
1520

query I rowsort
SELECT DISTINCT col2 * - col2 + + 59 * + col2 FROM tab1
----
-3552
114
270

query I rowsort
SELECT DISTINCT col2 + col0 * + 37 AS col0 FROM tab0
----
1296
3375
921

query I rowsort
SELECT DISTINCT - tab0.col1 + + col1 FROM tab0
----
0

query I rowsort
SELECT col0 * - col0 + col1 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT 58 AS col0 FROM tab2 AS cor0
----
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7174
SELECT ALL CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7174
SELECT ALL CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 * col0 * + col2 AS col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT - - 13 AS col1 FROM tab0 AS cor0
----
13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7177
SELECT ALL CAST( NULL AS DECIMAL ) * - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7177
SELECT ALL CAST ( NULL AS REAL ) * - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7178
SELECT ALL + ( cor0.col0 ) + + col0 DIV col0 AS col1 FROM tab0 cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-7178
SELECT ALL + ( cor0.col0 ) + + col0 / col0 AS col1 FROM tab0 cor0
----
25
36
90

query I rowsort
SELECT - + col2 + 76 FROM tab0 AS cor0
----
-6
43
75

query I rowsort
SELECT ALL + col1 - col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - + col0 * - 18 * - col1 FROM tab0 AS cor0
----
-145782
-37152
-61110

query I rowsort
SELECT DISTINCT col0 + + col0 * col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + ( + col2 ) - cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7184
SELECT ALL - ( 48 ) * col1 - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7184
SELECT ALL - ( 48 ) * col1 - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab2.col0 * col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT ( - col1 ) AS col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL + 78 AS col0 FROM tab2
----
78
78
78

query I rowsort
SELECT ( + col0 ) + + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT + + 79 AS col1 FROM tab1 AS cor0
----
79
79
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7191
SELECT col2 + col1 * - tab1.col0 - - col2 DIV + 99 AS col2 FROM tab1
----
-24
-583
-944

skipif mysql # not compatible
query I rowsort label-7191
SELECT col2 + col1 * - tab1.col0 - - col2 / + 99 AS col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT + 41 + cor0.col1 FROM tab1 cor0
----
51
54
67

query I rowsort
SELECT + + cor0.col1 + cor0.col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - 12 + - col2 * col2 AS col2 FROM tab0 AS cor0
----
-1101
-13
-6736

query I rowsort
SELECT 73 FROM tab2
----
73
73
73

query I rowsort
SELECT 60 FROM tab1, tab1 cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT ALL - - 6 + - col0 FROM tab0 AS cor0
----
-18
-29
-83

query I rowsort
SELECT + - 83 - col0 * - col2 AS col2 FROM tab2 AS cor0
----
106
1945
2919

query I rowsort
SELECT ALL col0 + col0 * ( + col0 ) FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT col0 * - col0 - + col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT + - col0 * col1 - + ( ( + col1 ) * - col0 ) AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - col2 * - col2 * col1 AS col0 FROM tab1 AS cor0
----
119808
32490
75816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7203
SELECT DISTINCT + + ( + col1 ) * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7203
SELECT DISTINCT + + ( + col1 ) * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col0 + col0 col0 FROM tab2 cor0
----
-17
141
97

query I rowsort
SELECT ALL + cor0.col0 + - col2 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7206
SELECT + col0 + + col1 * + col1 - ( col1 + + CAST( + col1 AS SIGNED ) ) FROM tab1 AS cor0
----
144
223
627

skipif mysql # not compatible
query I rowsort label-7206
SELECT + col0 + + col1 * + col1 - ( col1 + + CAST ( + col1 AS INTEGER ) ) FROM tab1 AS cor0
----
144
223
627

query I rowsort
SELECT DISTINCT 38 + col2 * 24 AS col2 FROM tab0 cor0
----
2006
62
830

query I rowsort
SELECT ALL - col2 + - col0 + col2 * - col1 FROM tab0 AS cor0
----
-133
-2895
-7633

query I rowsort
SELECT DISTINCT - + col0 * col2 * + col1 - cor0.col1 AS col0 FROM tab0 AS cor0
----
-3492
-664209
-68198

query I rowsort
SELECT 76 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT + col0 * - col0 + + tab2.col0 AS col2 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT ALL - - col1 + col2 * - col2 * + cor0.col0 FROM tab0 AS cor0
----
-26050
-598345
62

query I rowsort
SELECT ALL col1 + + ( col1 ) FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + col0 * 91 FROM tab2 AS cor0
----
637
7098
7189

query I rowsort
SELECT DISTINCT - col1 * + col0 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT - col1 + ( - col2 ) * + col2 + - col2 FROM tab1 AS cor0
----
-2996
-3316
-9325

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 * col0 + - col0 col0 FROM tab2 cor0
----
-1330
-158262
-237237

query I rowsort
SELECT ALL - col1 * - 34 + col1 AS col1 FROM tab0 AS cor0
----
3010
3185
3395

query I rowsort
SELECT + col2 + 37 AS col2 FROM tab2 AS cor0
----
63
64
75

query I rowsort
SELECT ALL col1 - - col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT - - col1 * col1 * + 73 + - col1 FROM tab0 AS cor0
----
539822
604422
686760

query I rowsort
SELECT 31 * + col2 FROM tab0 AS cor0
----
1023
2542
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * 69 * + col0 col1 FROM tab0 AS cor0
----
2415
503562
54648

query I rowsort
SELECT cor0.col0 + + 12 * + col1 FROM tab2 AS cor0
----
283
379
786

query I rowsort
SELECT + 45 * - 91 FROM tab2 AS cor0
----
-4095
-4095
-4095

onlyif mysql # use DIV operator for integer division
query I rowsort label-7226
SELECT DISTINCT + 35 DIV + col2 + + col2 FROM tab0 AS cor0
----
34
36
82

skipif mysql # not compatible
query I rowsort label-7226
SELECT DISTINCT + 35 / + col2 + + col2 FROM tab0 AS cor0
----
34
36
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7227
SELECT - - CAST( col1 AS SIGNED ) * col0 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-7227
SELECT - - CAST ( col1 AS INTEGER ) * col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + cor0.col1 * + cor0.col0 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - 48 + + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 957f4010cec8e565c841d8267fddae0b

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab0 cor1, tab1 AS cor2
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7231
SELECT ALL - CAST( col0 AS SIGNED ) AS col0 FROM tab0 cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-7231
SELECT ALL - CAST ( col0 AS INTEGER ) AS col0 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + cor1.col0 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
3
64
80

query I rowsort
SELECT ALL - + col1 * ( - col1 ) + - col2 * 57 FROM tab0 AS cor0
----
3607
5515
9352

query I rowsort
SELECT DISTINCT + cor0.col2 * ( col0 * + cor0.col1 ) AS col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + 12 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7236
SELECT - col1 * CAST( - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-7236
SELECT - col1 * CAST ( - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ( tab0.col1 ) AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT + + cor0.col0 AS col0 FROM tab0, tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT cor0.col0 + - cor0.col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL cor0.col2 * + cor0.col1 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to 16ae0e1090cb09b93854a4788f17716b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7241
SELECT ( col2 * - col0 ) + CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7241
SELECT ( col2 * - col0 ) + CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - 55 * col0 + col0 + col0 AS col0 FROM tab0 AS cor0
----
1368
1995
5073

query I rowsort
SELECT + cor0.col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 18 + - 5 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT ALL + 88 AS col2 FROM tab1
----
88
88
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7246
SELECT DISTINCT + CAST( + 54 AS SIGNED ) AS col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
54

skipif mysql # not compatible
query I rowsort label-7246
SELECT DISTINCT + CAST ( + 54 AS INTEGER ) AS col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
54

query I rowsort
SELECT + 50 AS col2 FROM tab1
----
50
50
50

query I rowsort
SELECT 60 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT - 82 + col0 FROM tab1
----
-18
-2
-79

query I rowsort
SELECT ALL ( 27 ) FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col0 FROM tab2, tab1 AS cor0, tab0 cor1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - cor0.col1 * + col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT col1 + col0 * - cor0.col0 + + ( cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-4076
-6374
43

query I rowsort
SELECT 77 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 col2 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT + col2 * - 50 FROM tab1 AS cor0
----
-2700
-2850
-4800

query I rowsort
SELECT - col2 + + col1 AS col0 FROM tab0
----
53
9
96

query I rowsort
SELECT - col1 * col1 + + col2 FROM tab1
----
-43
-622
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col0 col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT 61 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT DISTINCT cor0.col1 + 6 * + col0 - - col1 FROM tab1 AS cor0
----
404
506
70

query I rowsort
SELECT 13 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT 60 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT 26 * - col2 + - col0 * ( - col1 ) AS col1 FROM tab2 AS cor0
----
-485
355
3926

onlyif mysql # use DIV operator for integer division
query I rowsort label-7266
SELECT col0 DIV - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7266
SELECT col0 / - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col2 + - col1 AS col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT col0 * + col2 + ( cor0.col2 ) + col1 FROM tab2 AS cor0
----
2113
247
3057

query I rowsort
SELECT + 8 + - cor0.col2 * ( 17 ) FROM tab0 AS cor0
----
-1386
-553
-9

query I rowsort
SELECT 71 + col1 + ( - 27 ) * col1 FROM tab2 cor0
----
-1463
-371
-735

onlyif mysql # use DIV operator for integer division
query I rowsort label-7271
SELECT + tab2.col1 DIV + 95 AS col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7271
SELECT + tab2.col1 / + 95 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT - 92 * col0 FROM tab0
----
-2208
-3220
-8188

query I rowsort
SELECT ALL + col0 * cor0.col0 * ( - col2 ) + + col1 FROM tab0 AS cor0
----
-1128
-18922
-649431

query I rowsort
SELECT ( cor0.col0 ) + col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - + col0 * col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + col0 + 72 AS col0 FROM tab1
----
136
152
75

query I rowsort
SELECT + tab2.col2 * + col2 + + 73 FROM tab2
----
1517
749
802

onlyif mysql # use DIV operator for integer division
query I rowsort label-7278
SELECT - cor0.col0 + + 67 DIV - col1 FROM tab2 cor0
----
-79
-82
-9

skipif mysql # not compatible
query I rowsort label-7278
SELECT - cor0.col0 + + 67 / - col1 FROM tab2 cor0
----
-79
-82
-9

query I rowsort
SELECT + cor0.col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL 61 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT DISTINCT + - cor0.col0 * + cor0.col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + + cor0.col2 + + col2 * col0 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT + - ( + col1 ) * - col2 + - 73 FROM tab2 AS cor0
----
1461
573
764

query I rowsort
SELECT DISTINCT + 1 + - col1 * + col2 FROM tab2 AS cor0
----
-1533
-645
-836

query I rowsort
SELECT ALL - ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - - 78 * 90 FROM tab2 cor0
----
7020
7020
7020

query I rowsort
SELECT DISTINCT + - ( + ( + cor0.col0 ) ) FROM tab1 AS cor0
----
-3
-64