sqllogictest
Artifact Content
Not logged in

Artifact 38c6f3fdd6a28dafe8de90e3aa2a7a4b0cc089c9:


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 DISTINCT - + col1 * + col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - - ( + col2 ) + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL + + 28 * + 39 + col2 AS col1 FROM tab2 AS cor0
----
1118
1119
1130

query I rowsort
SELECT DISTINCT + + col0 * - col2 * + col0 AS col1 FROM tab1 cor0
----
-233472
-486
-614400

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4
SELECT ALL - CAST ( col2 AS INTEGER ) col0 FROM tab2 AS cor0
----
-26
-27
-38

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

query I rowsort
SELECT - col1 - + 1 FROM tab0 AS cor0
----
-87
-92
-98

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

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

query I rowsort
SELECT ALL + col2 - + 71 AS col1 FROM tab0 AS cor0
----
-38
-70
11

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

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

query I rowsort
SELECT ALL + 84 * - 65 FROM tab0 cor0
----
-5460
-5460
-5460

query I rowsort
SELECT DISTINCT cor0.col0 + - col0 * + col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT 30 + cor0.col2 + - ( - col2 ) AS col2 FROM tab1 AS cor0
----
138
144
222

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + 41 col2 FROM tab2 AS cor0
----
67
68
79

query I rowsort
SELECT ALL col1 - col0 * + 18 AS col1 FROM tab1 AS cor0
----
-1142
-1427
-28

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col0 * - CAST ( cor0.col0 AS REAL ) AS col0 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 68 * col0 * ( - col2 ) - + col1 col2 FROM tab0
----
2283
496173
53770

query I rowsort
SELECT col0 + - col2 * tab1.col2 AS col0 FROM tab1
----
-2913
-3185
-9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-21
SELECT + tab1.col1 DIV 10 + col1 * col0 * + ( - col1 ) AS col0 FROM tab1
----
-13519
-2026
-6399

skipif mysql # not compatible
query I rowsort label-21
SELECT + tab1.col1 / 10 + col1 * col0 * + ( - col1 ) AS col0 FROM tab1
----
-13519
-2026
-6399

query I rowsort
SELECT DISTINCT tab0.col1 * + ( + 91 ) - - col0 FROM tab0
----
7850
8370
8862

query I rowsort
SELECT DISTINCT col2 - col2 * + 97 FROM tab1
----
-5184
-5472
-9216

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-25
SELECT ALL col1 + - CAST( - col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-25
SELECT ALL col1 + - CAST ( - col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL + col0 + + col2 * - 88 FROM tab2 AS cor0
----
-2210
-2369
-3265

onlyif mysql # use DIV operator for integer division
query I rowsort label-27
SELECT DISTINCT + - col0 DIV 37 + + col1 * - cor0.col0 FROM tab2 cor0
----
-1345
-217
-4604

skipif mysql # not compatible
query I rowsort label-27
SELECT DISTINCT + - col0 / 37 + + col1 * - cor0.col0 FROM tab2 cor0
----
-1345
-217
-4604

query I rowsort
SELECT DISTINCT col2 * col2 * + col1 + - col1 FROM tab0 AS cor0
----
0
611793
93568

query I rowsort
SELECT ALL - col1 * 65 AS col0 FROM tab0 AS cor0
----
-5590
-5915
-6305

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

query I rowsort
SELECT ALL + col0 * + 75 AS col1 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT DISTINCT - tab1.col2 * 92 AS col1 FROM tab1
----
-4968
-5244
-8832

query I rowsort
SELECT + cor0.col0 - 32 FROM tab0 AS cor0
----
-8
3
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-34
SELECT - CAST( + 69 AS SIGNED ) DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-34
SELECT - CAST ( + 69 AS INTEGER ) / col1 FROM tab0
----
0
0
0

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 50 * col1 col2 FROM tab1 cor0
----
1300
500
650

query I rowsort
SELECT + 11 - + 35 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to ad9e2feda1bc3d52e1a836279e031a8b

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 * col1 + + 66 col0 FROM tab2
----
1616
3016
916

query I rowsort
SELECT - 13 + col0 * 44 FROM tab1
----
119
2803
3507

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

query I rowsort
SELECT DISTINCT 10 * col0 AS col2 FROM tab1
----
30
640
800

query I rowsort
SELECT DISTINCT col2 * col2 + 33 FROM tab1 AS cor0
----
2949
3282
9249

query I rowsort
SELECT 22 + col2 AS col2 FROM tab0 AS cor0
----
104
23
55

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

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

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

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

query I rowsort
SELECT DISTINCT + col0 * 76 FROM tab0 AS cor0
----
1824
2660
6764

query I rowsort
SELECT cor0.col2 * + col2 + 71 AS col2 FROM tab2 cor0
----
1515
747
800

query I rowsort
SELECT DISTINCT + col0 * 64 FROM tab2 cor0
----
448
4992
5056

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

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

query I rowsort
SELECT cor0.col0 * - cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 75a608bf2ba236d24f146ac4aff9ec52

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

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

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

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

query I rowsort
SELECT ALL - - cor0.col2 - col1 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - col1 * ( col1 + + tab2.col1 ) FROM tab2
----
-1922
-578
-6962

query I rowsort
SELECT ALL - 14 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to c2bf0e2420d22cd58d7ee3b30827afcc

query I rowsort
SELECT DISTINCT ( 91 ) * - col2 - ( col0 ) AS col1 FROM tab0 AS cor0
----
-126
-3027
-7551

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

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

query I rowsort
SELECT + ( 34 ) * + cor0.col2 AS col1 FROM tab1 cor0
----
1836
1938
3264

query I rowsort
SELECT + col0 * 64 - col2 FROM tab1
----
138
4039
5024

query I rowsort
SELECT 79 + tab0.col0 AS col0 FROM tab0
----
103
114
168

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

query I rowsort
SELECT ALL + col1 + - 29 AS col0 FROM tab0
----
57
62
68

query I rowsort
SELECT DISTINCT + 48 * 12 FROM tab2
----
576

query I rowsort
SELECT ALL - ( + 63 ) AS col2 FROM tab0
----
-63
-63
-63

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

query I rowsort
SELECT - col2 + 18 * col2 * col1 FROM tab0 AS cor0
----
134234
1745
51051

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 46 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT ALL + ( + 85 ) + col2 * col2 + 27 AS col2 FROM tab0
----
113
1201
6836

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-78
SELECT - + 52 * col0 DIV 82 FROM tab0 AS cor0
----
-15
-22
-56

skipif mysql # not compatible
query I rowsort label-78
SELECT - + 52 * col0 / 82 FROM tab0 AS cor0
----
-15
-22
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-79
SELECT ALL 53 DIV col1 + - ( - col1 ) * + col0 AS col2 FROM tab1 AS cor0
----
1044
645
80

skipif mysql # not compatible
query I rowsort label-79
SELECT ALL 53 / col1 + - ( - col1 ) * + col0 AS col2 FROM tab1 AS cor0
----
1044
645
80

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

skipif mysql # not compatible
query I rowsort label-80
SELECT DISTINCT - col1 + - col0 * CAST ( + col2 * + col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-1354
-158243
-237175

query I rowsort
SELECT - 10 * + col0 FROM tab1 AS cor0
----
-30
-640
-800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 0 col1 FROM tab2
----
0

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

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

query I rowsort
SELECT DISTINCT col1 + cor0.col1 * - ( + 48 * - col0 ) FROM tab0 AS cor0
----
163057
388843
99158

query I rowsort
SELECT DISTINCT + 40 + cor0.col1 AS col2 FROM tab2 AS cor0
----
57
71
99

query I rowsort
SELECT col1 + + cor0.col1 * 71 AS col0 FROM tab0 AS cor0
----
6192
6552
6984

query I rowsort
SELECT + col0 + ( 75 ) FROM tab2 AS cor0
----
153
154
82

query I rowsort
SELECT col2 * cor0.col2 * 37 - + cor0.col2 * + col1 FROM tab2 AS cor0
----
23478
26136
52782

query I rowsort
SELECT col1 * - cor0.col1 AS col0 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT + - col0 + 6 FROM tab1 AS cor0
----
-58
-74
3

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

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

query I rowsort
SELECT ALL + - 80 FROM tab0 AS cor0
----
-80
-80
-80

query I rowsort
SELECT ALL 30 * col0 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT cor1.col0 - + 83 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 68c76ce0ee643a0f522518aae390f164

onlyif mysql # use DIV operator for integer division
query I rowsort label-97
SELECT ALL - cor0.col1 DIV ( - cor0.col0 ) AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 0231f0ea08ef49e8e99dfb495771acf2

skipif mysql # not compatible
query I rowsort label-97
SELECT ALL - cor0.col1 / ( - cor0.col0 ) AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 0231f0ea08ef49e8e99dfb495771acf2

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

query I rowsort
SELECT DISTINCT + - ( - col2 ) + 26 * ( col2 ) * + col0 + + 54 FROM tab0 AS cor0
----
189884
20679
965

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

query I rowsort
SELECT + - 54 + + col2 FROM tab2 AS cor0
----
-16
-27
-28

query I rowsort
SELECT ALL - col2 * col2 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-104
SELECT DISTINCT - - col0 + col2 * col0 DIV + col2 FROM tab0 AS cor0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-104
SELECT DISTINCT - - col0 + col2 * col0 / + col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - col0 * col2 - 8 AS col2 FROM tab1 AS cor0
----
-170
-3656
-7688

query I rowsort
SELECT ALL + col2 + - col0 * + ( col1 + col0 ) FROM tab2 AS cor0
----
-10660
-239
-7546

query I rowsort
SELECT + - col0 * + col0 + col2 AS col0 FROM tab1 AS cor0
----
-4039
-6304
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col2 - - col2 col2 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 20 + col2 col1 FROM tab0 AS cor0
----
102
21
53

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

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

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

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

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

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

query I rowsort
SELECT - 11 * col0 AS col0 FROM tab2 AS cor0
----
-77
-858
-869

query I rowsort
SELECT DISTINCT + col2 * col0 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - 82 FROM tab2, tab1 AS cor0
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

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

skipif mysql # not compatible
query I rowsort label-118
SELECT DISTINCT + 76 / col0 FROM tab0 AS cor0
----
0
2
3

query I rowsort
SELECT ALL + + 89 * - col1 * col0 + col0 FROM tab0 AS cor0
----
-183672
-302120
-720722

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

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

query I rowsort
SELECT DISTINCT - 79 + + col0 * + col2 FROM tab1 AS cor0
----
3569
7601
83

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-124
SELECT - CAST( + 72 * + col1 AS SIGNED ) col2 FROM tab1
----
-1872
-720
-936

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-124
SELECT - CAST ( + 72 * + col1 AS INTEGER ) col2 FROM tab1
----
-1872
-720
-936

query I rowsort
SELECT - col0 + 1 AS col2 FROM tab1
----
-2
-63
-79

query I rowsort
SELECT + 49 * col2 AS col0 FROM tab0 AS cor0
----
1617
4018
49

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-129
SELECT - 84 DIV col2 + col1 AS col2 FROM tab1
----
13
25
9

skipif mysql # not compatible
query I rowsort label-129
SELECT - 84 / col2 + col1 AS col2 FROM tab1
----
13
25
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-130
SELECT DISTINCT 35 DIV - col0 FROM tab2
----
-5
0

skipif mysql # not compatible
query I rowsort label-130
SELECT DISTINCT 35 / - col0 FROM tab2
----
-5
0

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

query I rowsort
SELECT - 8 + + tab0.col0 FROM tab0
----
16
27
81

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

query I rowsort
SELECT DISTINCT + 97 * cor0.col2 + + cor0.col1 * - col0 AS col2 FROM tab1 AS cor0
----
4889
5160
8272

query I rowsort
SELECT - 1 * col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - - 20 * - col0 FROM tab0 AS cor0
----
-1780
-480
-700

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

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

query I rowsort
SELECT DISTINCT col2 + ( col1 ) + - col0 FROM tab2
----
-24
51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-140
SELECT col1 + col0 DIV - col2 AS col1 FROM tab0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-140
SELECT col1 + col0 / - col2 AS col1 FROM tab0
----
62
86
90

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

skipif mysql # not compatible
query I rowsort label-141
SELECT DISTINCT + col2 + + ( col1 ) / - col2 FROM tab0
----
-96
31
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-142
SELECT ALL col2 DIV + 18 + ( col0 ) FROM tab1
----
6
67
85

skipif mysql # not compatible
query I rowsort label-142
SELECT ALL col2 / + 18 + ( col0 ) FROM tab1
----
6
67
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + ( + tab1.col1 ) col1 FROM tab1
----
0

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

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

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

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

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

query I rowsort
SELECT ALL col2 * - col0 + + col2 * tab2.col0 * col2 AS col2 FROM tab2
----
111074
4914
50700

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

query I rowsort
SELECT ALL + col0 + col0 * + col1 + - tab0.col1 AS col1 FROM tab0
----
2002
3333
8097

query I rowsort
SELECT DISTINCT col2 * - 38 FROM tab1 AS cor0
----
-2052
-2166
-3648

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-153
SELECT ALL 42 DIV ( - col2 ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-153
SELECT ALL 42 / ( - col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 67 * col0 + col2 FROM tab1 AS cor0
----
-147
-4231
-5264

query I rowsort
SELECT ALL + + 3 * col0 FROM tab1 cor0
----
192
240
9

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

query I rowsort
SELECT - col0 + 14 FROM tab2
----
-64
-65
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-158
SELECT DISTINCT col0 DIV 18 FROM tab0 AS cor0
----
1
4

skipif mysql # not compatible
query I rowsort label-158
SELECT DISTINCT col0 / 18 FROM tab0 AS cor0
----
1
4

query I rowsort
SELECT ALL + - 49 + - col1 AS col1 FROM tab2 AS cor0
----
-108
-66
-80

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

skipif mysql # not compatible
query I rowsort label-160
SELECT + + CAST ( NULL AS INTEGER ) / 5 FROM tab2 AS cor0
----
NULL
NULL
NULL

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-162
SELECT DISTINCT - CAST( + 92 AS SIGNED ) * + col2 AS col1 FROM tab0 AS cor0
----
-3036
-7544
-92

skipif mysql # not compatible
query I rowsort label-162
SELECT DISTINCT - CAST ( + 92 AS INTEGER ) * + col2 AS col1 FROM tab0 AS cor0
----
-3036
-7544
-92

query I rowsort
SELECT ALL - ( 34 ) AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 32 ) col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

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

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

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

query I rowsort
SELECT + col2 * + 36 * - col0 AS col0 FROM tab1 AS cor0
----
-131328
-276480
-5832

query I rowsort
SELECT 46 * + tab2.col2 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 2f53a5db2c498f0c4222038921362b37

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

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

query I rowsort
SELECT + col1 * - cor0.col1 + col0 * - 66 FROM tab1 AS cor0
----
-4324
-5449
-874

query I rowsort
SELECT 5 + col0 AS col1 FROM tab0 AS cor0
----
29
40
94

query I rowsort
SELECT ALL + tab2.col0 + + col0 + - col0 * col2 FROM tab2
----
-175
-1872
-2844

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

query I rowsort
SELECT ALL col0 + 42 * - col1 * col1 FROM tab0
----
-310608
-347713
-395143

query I rowsort
SELECT ALL 81 FROM tab0, tab2 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

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

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

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

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

query I rowsort
SELECT + cor1.col1 * + 8 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 965b9ab2e2aa40fe44f1c96045c0e6f7

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

query I rowsort
SELECT ALL + 25 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 83 * col0 col2 FROM tab1 AS cor0
----
249
5312
6640

query I rowsort
SELECT + col1 + col0 + - col1 * col1 AS col0 FROM tab1 cor0
----
-26
-647
-76

query I rowsort
SELECT DISTINCT 68 * - col2 FROM tab1 AS cor0
----
-3672
-3876
-6528

query I rowsort
SELECT DISTINCT - + 74 + col0 * 26 AS col1 FROM tab0 AS cor0
----
2240
550
836

onlyif mysql # use DIV operator for integer division
query I rowsort label-188
SELECT - 79 - col0 DIV col0 AS col0 FROM tab0 AS cor0
----
-80
-80
-80

skipif mysql # not compatible
query I rowsort label-188
SELECT - 79 - col0 / col0 AS col0 FROM tab0 AS cor0
----
-80
-80
-80

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 54 * col1 col0 FROM tab0
----
4644
4914
5238

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

query I rowsort
SELECT cor0.col2 + - 92 FROM tab1 AS cor0
----
-35
-38
4

query I rowsort
SELECT ALL col2 * col1 + + 54 * - col0 AS col1 FROM tab0 AS cor0
----
-1793
1542
2656

query I rowsort
SELECT + col2 * 17 + 94 FROM tab0 cor0
----
111
1488
655

query I rowsort
SELECT - col0 * - 27 + 49 FROM tab0 AS cor0
----
2452
697
994

query I rowsort
SELECT DISTINCT - 95 + + col2 - + col2 AS col1 FROM tab2
----
-95

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-198
SELECT ( col0 ) * ( - col1 ) DIV col0 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-198
SELECT ( col0 ) * ( - col1 ) / col0 FROM tab2
----
-17
-31
-59

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-201
SELECT 61 * col2 DIV col0 FROM tab0
----
1
56
83

skipif mysql # not compatible
query I rowsort label-201
SELECT 61 * col2 / col0 FROM tab0
----
1
56
83

query I rowsort
SELECT - ( + col1 + - col0 ) * - 14 FROM tab2
----
-266
-868
336

query I rowsort
SELECT col0 + - 73 * ( + col0 * + 52 ) + col1 * col2 FROM tab0
----
-132728
-330293
-88242

query I rowsort
SELECT + + cor0.col1 * + col1 * col0 + cor0.col0 + + col1 * - col2 FROM tab1 AS cor0
----
12352
5894
627

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

query I rowsort
SELECT ALL col2 + 20 - col0 FROM tab0 AS cor0
----
-14
13
29

query I rowsort
SELECT - - col0 * 76 + 37 AS col0 FROM tab0 AS cor0
----
1861
2697
6801

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

query I rowsort
SELECT ALL + col2 * 28 + ( col2 ) * col0 * col1 FROM tab1 AS cor0
----
102528
38076
5724

query I rowsort
SELECT - col1 + + 14 * ( col2 ) FROM tab0 AS cor0
----
-83
1057
376

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

query I rowsort
SELECT ALL + 26 * tab1.col1 * - col1 FROM tab1
----
-17576
-2600
-4394

query I rowsort
SELECT - 86 * - col2 + - col0 AS col0 FROM tab0 AS cor0
----
2814
51
6963

query I rowsort
SELECT - 49 + col1 * + col2 + + ( col0 ) AS col0 FROM tab2 AS cor0
----
1563
676
795

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-215
SELECT - cor0.col0 - - col2 / + 44 col1 FROM tab0 AS cor0
----
-24
-35
-88

query I rowsort
SELECT - - col0 + - col2 + ( + 27 ) FROM tab0 AS cor0
----
18
34
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-217
SELECT - col1 - - col1 * + 93 DIV 1 AS col1 FROM tab0 AS cor0
----
7912
8372
8924

skipif mysql # not compatible
query I rowsort label-217
SELECT - col1 - - col1 * + 93 / 1 AS col1 FROM tab0 AS cor0
----
7912
8372
8924

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

query I rowsort
SELECT + col1 + col2 * 64 * - cor0.col0 FROM tab2 cor0
----
-12065
-129733
-192111

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

query I rowsort
SELECT 24 - col0 FROM tab1
----
-40
-56
21

query I rowsort
SELECT ALL - 54 * + tab1.col1 * col2 AS col0 FROM tab1
----
-30780
-67392
-75816

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

query I rowsort
SELECT - 70 + - col1 * + col1 AS col1 FROM tab1 AS cor0
----
-170
-239
-746

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

query I rowsort
SELECT DISTINCT ( ( col2 ) ) AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT col1 + - 57 * - col2 FROM tab1
----
3104
3259
5485

query I rowsort
SELECT ALL tab0.col1 * + 79 * + col1 FROM tab0
----
584284
654199
743311

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

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

query I rowsort
SELECT ALL + col0 * - cor0.col0 * col1 + 13 FROM tab1 AS cor0
----
-221
-40947
-83187

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

query I rowsort
SELECT DISTINCT - 49 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-1274
-490
-637

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

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

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

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

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

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

query I rowsort
SELECT ALL col2 + col2 * + 4 + + col1 AS col0 FROM tab1
----
295
296
493

onlyif mysql # use DIV operator for integer division
query I rowsort label-240
SELECT DISTINCT - col2 DIV 99 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-240
SELECT DISTINCT - col2 / 99 FROM tab1 AS cor0
----
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-242
SELECT col2 DIV col1 - - 49 * col0 * col1 FROM tab2 AS cor0
----
10633
225498
65809

skipif mysql # not compatible
query I rowsort label-242
SELECT col2 / col1 - - 49 * col0 * col1 FROM tab2 AS cor0
----
10633
225498
65809

query I rowsort
SELECT - - col1 * cor0.col1 + + 13 FROM tab0 AS cor0
----
7409
8294
9422

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

query I rowsort
SELECT ALL col0 + 97 FROM tab0 AS cor0
----
121
132
186

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * - ( - col0 ) + + col1 col1 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + ( + col2 ) col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-248
SELECT ALL + col1 * + col0 + col2 * col1 DIV cor0.col1 FROM tab0 AS cor0
----
2097
3396
8181

skipif mysql # not compatible
query I rowsort label-248
SELECT ALL + col1 * + col0 + col2 * col1 / cor0.col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT cor0.col0 + 41 FROM tab2 cor0
----
119
120
48

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

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

skipif mysql # not compatible
query I rowsort label-251
SELECT ALL col1 / ( col1 + cor0.col1 ) FROM tab1 AS cor0
----
0
0
0

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

query I rowsort
SELECT DISTINCT + col2 + ( + col0 ) * - 6 + col2 FROM tab0 AS cor0
----
-208
-370
-78

query I rowsort
SELECT 46 + + col0 * col1 AS col1 FROM tab1 cor0
----
1086
124
686

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * - 51 * col1 col1 FROM tab0 AS cor0
----
-105264
-173145
-413049

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-260
SELECT DISTINCT 74 DIV 89 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-260
SELECT DISTINCT 74 / 89 AS col1 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-261
SELECT DISTINCT + CAST( + 91 AS SIGNED ) * - col1 FROM tab2 AS cor0
----
-1547
-2821
-5369

skipif mysql # not compatible
query I rowsort label-261
SELECT DISTINCT + CAST ( + 91 AS INTEGER ) * - col1 FROM tab2 AS cor0
----
-1547
-2821
-5369

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

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

query I rowsort
SELECT DISTINCT + ( 83 ) + col0 AS col0 FROM tab2 AS cor0
----
161
162
90

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

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

query I rowsort
SELECT tab2.col2 * - 7 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 89ab6a32a2cc304260335e313943b041

query I rowsort
SELECT + 28 * - 47 * cor0.col2 FROM tab0 AS cor0
----
-107912
-1316
-43428

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

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

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

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

query I rowsort
SELECT ALL + col2 + - ( 90 ) FROM tab1
----
-33
-36
6

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

query I rowsort
SELECT 99 + cor0.col2 FROM tab2 AS cor0
----
125
126
137

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

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

query I rowsort
SELECT 35 + col0 * col2 FROM tab2 AS cor0
----
2063
224
3037

query I rowsort
SELECT col2 - ( 29 ) * col2 FROM tab2 cor0
----
-1064
-728
-756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * - ( + col0 ) + col2 col1 FROM tab2 AS cor0
----
6110
6279
76

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

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

query I rowsort
SELECT + 59 * + 66 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a3466da46e9b74c9efa1f48d30d797c8

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

query I rowsort
SELECT DISTINCT - col1 * - col0 + col0 * col0 AS col0 FROM tab2
----
10686
266
7584

query I rowsort
SELECT col1 * + col0 + + 30 + + col2 FROM tab1
----
1166
162
727

query I rowsort
SELECT col1 - - 90 AS col0 FROM tab2 AS cor0
----
107
121
149

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col2 AS col1 FROM tab0, tab2, tab2 AS cor0
----
1444
676
729

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

query I rowsort
SELECT ALL - + 84 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

query I rowsort
SELECT + 49 + + col1 + 61 AS col2 FROM tab0 AS cor0
----
196
201
207

query I rowsort
SELECT + - col2 * col2 + + 94 * - col1 + col1 * - col2 FROM tab1 AS cor0
----
-11686
-4759
-6764

query I rowsort
SELECT ALL + tab0.col1 * col1 * col1 + - col1 FROM tab0
----
635970
753480
912576

query I rowsort
SELECT ALL + col1 * 48 + - col1 FROM tab1
----
1222
470
611

query I rowsort
SELECT + col0 * col1 - - 78 * - col1 * + col0 AS col1 FROM tab2
----
-103411
-16709
-354354

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-293
SELECT - col2 DIV ( - col1 ) + col2 * + cor0.col2 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-26136
-35
-598436

skipif mysql # not compatible
query I rowsort label-293
SELECT - col2 / ( - col1 ) + col2 * + cor0.col2 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-26136
-35
-598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + 42 col0 FROM tab2 AS cor0
----
1302
2478
714

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

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

query I rowsort
SELECT ALL 88 FROM tab2, tab0 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT - col0 + col0 - 7 * col2 * - col0 FROM tab0 AS cor0
----
245
51086
5544

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

query I rowsort
SELECT + + col2 * col2 + + col0 * + 77 FROM tab0 AS cor0
----
13577
2696
2937

query I rowsort
SELECT + 96 - - col0 AS col2 FROM tab0 AS cor0
----
120
131
185

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-301
SELECT col1 * col1 + + CAST( 11 AS SIGNED ) + - cor0.col0 * col1 FROM tab1 cor0
----
-529
-860
609

skipif mysql # not compatible
query I rowsort label-301
SELECT col1 * col1 + + CAST ( 11 AS INTEGER ) + - cor0.col0 * col1 FROM tab1 cor0
----
-529
-860
609

query I rowsort
SELECT ALL + 28 + 34 + col2 AS col0 FROM tab1
----
116
119
158

query I rowsort
SELECT DISTINCT - 33 * + col0 + col1 FROM tab0 AS cor0
----
-1058
-2846
-706

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

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

query I rowsort
SELECT ALL - - cor0.col2 AS col2 FROM tab2 cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col2 - col2 col0 FROM tab2 cor0
----
1406
650
702

query I rowsort
SELECT 60 + col0 * + col1 FROM tab0
----
2124
3455
8159

skipif mysql # not compatible
query I rowsort
SELECT + + col0 * CAST ( + 14 AS REAL ) FROM tab0 AS cor0
----
1246
336
490

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-311
SELECT + col1 DIV col1 + 83 col1 FROM tab0 AS cor0
----
84
84
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-311
SELECT + col1 / col1 + 83 col1 FROM tab0 AS cor0
----
84
84
84

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * - col0 * + 32 + col2 + + col2 col0 FROM tab0
----
-108638
-259004
-65982

query I rowsort
SELECT DISTINCT - ( col2 ) * 39 - - 21 AS col2 FROM tab0
----
-1266
-18
-3177

query I rowsort
SELECT - 66 - + tab1.col2 AS col2 FROM tab1
----
-120
-123
-162

query I rowsort
SELECT ALL - col0 * - 35 * - col0 AS col0 FROM tab2 AS cor0
----
-1715
-212940
-218435

query I rowsort
SELECT DISTINCT ( 77 ) + - col2 FROM tab0 AS cor0
----
-5
44
76

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

query I rowsort
SELECT - + 76 + col2 AS col0 FROM tab0 AS cor0
----
-43
-75
6

query I rowsort
SELECT DISTINCT - - col1 * 84 + col1 * col2 AS col2 FROM tab2 AS cor0
----
2074
3441
6490

query I rowsort
SELECT ALL + 27 + cor0.col2 AS col2 FROM tab2 AS cor0
----
53
54
65

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

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

query I rowsort
SELECT ALL + 48 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

query I rowsort
SELECT tab2.col1 * 5 - col2 * - col0 FROM tab2
----
2323
3087
344

query I rowsort
SELECT - ( - 67 ) FROM tab1
----
67
67
67

query I rowsort
SELECT 92 + + cor0.col1 FROM tab2 AS cor0
----
109
123
151

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

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

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

query I rowsort
SELECT ALL - col0 + - 23 * - 83 * cor0.col1 - col2 FROM tab1 AS cor0
----
18969
24641
49577

onlyif mysql # use DIV operator for integer division
query I rowsort label-333
SELECT DISTINCT + - col0 DIV - col0 + ( - col0 ) FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-333
SELECT DISTINCT + - col0 / - col0 + ( - col0 ) FROM tab2 AS cor0
----
-6
-77
-78

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

query I rowsort
SELECT DISTINCT col2 + - col1 * 0 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 * col2 + - cor0.col2 * - col2 + + col2 FROM tab2 AS cor0
----
2730
4484
945

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

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

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

query I rowsort
SELECT DISTINCT + - col1 * 29 * + col1 + - col0 FROM tab2 AS cor0
----
-101027
-27876
-8460

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

query I rowsort
SELECT ALL + 16 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT col0 + col2 * ( col0 * + tab1.col0 ) FROM tab1
----
233536
489
614480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-344
SELECT DISTINCT - 5 * - tab0.col1 + + CAST( + col0 AS SIGNED ) + - col2 FROM tab0
----
421
462
519

skipif mysql # not compatible
query I rowsort label-344
SELECT DISTINCT - 5 * - tab0.col1 + + CAST ( + col0 AS INTEGER ) + - col2 FROM tab0
----
421
462
519

query I rowsort
SELECT DISTINCT - 6 + col1 * col0 FROM tab2
----
1337
211
4596

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + cor0.col0 * + col2 col0 FROM tab1 AS cor0
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * cor0.col2 + ( col1 ) col1 FROM tab2 AS cor0
----
-1475
-629
-806

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-349
SELECT ALL CAST ( NULL AS INTEGER ) + - tab1.col1 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + cor0.col0 * col0 - + ( cor0.col2 ) FROM tab1 AS cor0
----
-45
4039
6304

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

query I rowsort
SELECT ALL + col1 * + 51 FROM tab2 AS cor0
----
1581
3009
867

query I rowsort
SELECT - col2 * 5 + col2 FROM tab1 cor0
----
-216
-228
-384

onlyif mysql # use DIV operator for integer division
query I rowsort label-354
SELECT + + ( + col1 ) * col1 DIV - col0 FROM tab2 AS cor0
----
-137
-3
-44

skipif mysql # not compatible
query I rowsort label-354
SELECT + + ( + col1 ) * col1 / - col0 FROM tab2 AS cor0
----
-137
-3
-44

query I rowsort
SELECT - ( 74 ) AS col0 FROM tab0 AS cor0
----
-74
-74
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-356
SELECT ALL + 90 * 13 DIV + col2 - ( + col0 ) * - col1 AS col0 FROM tab0
----
2099
4565
8113

skipif mysql # not compatible
query I rowsort label-356
SELECT ALL + 90 * 13 / + col2 - ( + col0 ) * - col1 AS col0 FROM tab0
----
2099
4565
8113

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) + - col1 col1 FROM tab2 AS cor0
----
-33
-4
21

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-360
SELECT ALL + - 2 * + col2 + col1 + + ( cor0.col2 ) DIV - 43 FROM tab1 AS cor0
----
-105
-181
-83

skipif mysql # not compatible
query I rowsort label-360
SELECT ALL + - 2 * + col2 + col1 + + ( cor0.col2 ) / - 43 FROM tab1 AS cor0
----
-105
-181
-83

query I rowsort
SELECT DISTINCT - - cor0.col1 + col2 + col1 FROM tab0 AS cor0
----
195
205
264

onlyif mysql # use DIV operator for integer division
query I rowsort label-362
SELECT ALL - cor0.col2 * cor0.col0 + col1 * + cor0.col2 DIV - col2 FROM tab1 AS cor0
----
-188
-3658
-7693

skipif mysql # not compatible
query I rowsort label-362
SELECT ALL - cor0.col2 * cor0.col0 + col1 * + cor0.col2 / - col2 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT + 73 * - col0 - 54 FROM tab1 AS cor0
----
-273
-4726
-5894

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

query I rowsort
SELECT - - col2 * - col2 + col2 * - col1 + + col2 FROM tab0 AS cor0
----
-14104
-3894
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-366
SELECT - - col1 * col1 - + CAST( - 92 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
1053
3573
381

skipif mysql # not compatible
query I rowsort label-366
SELECT - - col1 * col1 - + CAST ( - 92 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
1053
3573
381

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-369
SELECT DISTINCT col1 * + ( + col0 ) DIV col0 AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-369
SELECT DISTINCT col1 * + ( + col0 ) / col0 AS col1 FROM tab1 AS cor0
----
10
13
26

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

query I rowsort
SELECT - col2 + cor0.col2 * 84 AS col1 FROM tab0 AS cor0
----
2739
6806
83

query I rowsort
SELECT ALL + ( col1 ) + 79 AS col1 FROM tab0
----
165
170
176

query I rowsort
SELECT DISTINCT ( col2 ) + col1 * 3 AS col2 FROM tab2 AS cor0
----
120
203
89

query I rowsort
SELECT DISTINCT + col0 + + col2 * + cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
244092
679131
9444

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

query I rowsort
SELECT ALL + 7 * col0 * + col1 AS col0 FROM tab2 AS cor0
----
1519
32214
9401

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * + col0 + - col0 col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT col1 * + ( - 12 ) AS col0 FROM tab2
----
-204
-372
-708

query I rowsort
SELECT ALL - 82 + + col1 AS col0 FROM tab1 AS cor0
----
-56
-69
-72

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

query I rowsort
SELECT ALL 69 + col1 AS col2 FROM tab1 AS cor0
----
79
82
95

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-384
SELECT - cor0.col0 DIV - 38 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to e1e0cfc6d15933eb424ade504a2163bc

skipif mysql # not compatible
query I rowsort label-384
SELECT - cor0.col0 / - 38 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to e1e0cfc6d15933eb424ade504a2163bc

query I rowsort
SELECT 83 * tab2.col0 * col0 + + col1 * col1 FROM tab2
----
5028
508453
518292

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

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

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

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

query I rowsort
SELECT - ( 56 ) + tab0.col1 AS col1 FROM tab0
----
30
35
41

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

skipif mysql # not compatible
query I rowsort label-390
SELECT DISTINCT - ( col1 ) / col2 AS col0 FROM tab1
----
0

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

skipif mysql # not compatible
query I rowsort label-391
SELECT DISTINCT CAST ( 96 AS INTEGER ) AS col1 FROM tab0
----
96

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

query I rowsort
SELECT + - 78 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b6e4cc21599216686f0cf45b85668b2c

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

query I rowsort
SELECT DISTINCT - - 54 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
54

query I rowsort
SELECT DISTINCT - col1 - + 64 AS col2 FROM tab0
----
-150
-155
-161

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 82 - - col0 col2 FROM tab1 AS cor0
----
146
162
85

query I rowsort
SELECT + ( + 25 ) + + col1 FROM tab1 AS cor0
----
35
38
51

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

query I rowsort
SELECT - tab2.col1 * 19 FROM tab2, tab2 AS cor0
----
9 values hashing to 4ffcc0543824bfd0794019f60c80ad17

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

query I rowsort
SELECT DISTINCT col1 * col1 + - col2 - col0 FROM tab1 AS cor0
----
-21
-7
619

query I rowsort
SELECT - 34 + - col0 AS col0 FROM tab0
----
-123
-58
-69

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-408
SELECT DISTINCT + tab1.col0 * col1 DIV ( col0 * + col1 ) FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-408
SELECT DISTINCT + tab1.col0 * col1 / ( col0 * + col1 ) FROM tab1
----
1

query I rowsort
SELECT - col1 + - 74 FROM tab0 AS cor0
----
-160
-165
-171

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

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

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

query I rowsort
SELECT + ( 58 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT DISTINCT + col1 * col1 + ( - col2 + + col1 * col0 ) AS col2 FROM tab0 cor0
----
12803
16298
9427

query I rowsort
SELECT DISTINCT + col1 * + 99 FROM tab0 AS cor0
----
8514
9009
9603

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

skipif mysql # not compatible
query I rowsort label-416
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / 27 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-417
SELECT - - CAST( + ( col0 ) AS SIGNED ) DIV 25 AS col2 FROM tab0 AS cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-417
SELECT - - CAST ( + ( col0 ) AS INTEGER ) / 25 AS col2 FROM tab0 AS cor0
----
0
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-418
SELECT - 77 DIV + 36 AS col1 FROM tab2 cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-418
SELECT - 77 / + 36 AS col1 FROM tab2 cor0
----
-2
-2
-2

query I rowsort
SELECT ALL + ( - 62 ) + + col0 * ( - col1 ) * + col1 FROM tab0 AS cor0
----
-177566
-329377
-737071

onlyif mysql # use DIV operator for integer division
query I rowsort label-420
SELECT ALL + 95 DIV + 41 AS col2 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-420
SELECT ALL + 95 / + 41 AS col2 FROM tab0 AS cor0
----
2
2
2

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

query I rowsort
SELECT - 74 + + 8 * col2 * + col1 FROM tab0 AS cor0
----
22630
59622
702

query I rowsort
SELECT - 23 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 9bd721f99d79dce21b1de2860fd51ed5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) + cor0.col1 col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL 74 FROM tab0, tab1, tab1 AS cor0, tab1 AS cor1
----
81 values hashing to 22fe261d6995563c0767a5087aea05b1

onlyif mysql # use DIV operator for integer division
query I rowsort label-426
SELECT DISTINCT + col1 * col1 * + cor0.col0 - col0 DIV col0 AS col0 FROM tab0 AS cor0
----
177503
329314
737008

skipif mysql # not compatible
query I rowsort label-426
SELECT DISTINCT + col1 * col1 * + cor0.col0 - col0 / col0 AS col0 FROM tab0 AS cor0
----
177503
329314
737008

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-430
SELECT DISTINCT + 90 DIV - col1 - - 18 FROM tab0 AS cor0
----
17
18

skipif mysql # not compatible
query I rowsort label-430
SELECT DISTINCT + 90 / - col1 - - 18 FROM tab0 AS cor0
----
17
18

query I rowsort
SELECT ALL 22 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

onlyif mysql # use DIV operator for integer division
query I rowsort label-432
SELECT + cor0.col0 + - cor0.col2 - col2 DIV 77 col2 FROM tab2 AS cor0
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-432
SELECT + cor0.col0 + - cor0.col2 - col2 / 77 col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - + col2 + 53 * - col2 AS col0 FROM tab0 AS cor0
----
-1782
-4428
-54

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

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

query I rowsort
SELECT ALL 18 * col2 AS col2 FROM tab0
----
1476
18
594

query I rowsort
SELECT DISTINCT + - ( - col2 ) * + col2 * + cor0.col1 + + col0 * - col2 + col2 FROM tab0 AS cor0
----
604668
63
92895

query I rowsort
SELECT + 78 - + 58 AS col2 FROM tab0 AS cor0
----
20
20
20

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

query I rowsort
SELECT ALL + cor0.col0 * - cor0.col0 * cor0.col0 + + 66 * 21 + col2 FROM tab1 AS cor0
----
-260701
-510518
1413

query I rowsort
SELECT ALL - + cor0.col0 * 87 + col2 * - col0 * + col0 FROM tab0 AS cor0
----
-21096
-4270
-657265

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

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

query I rowsort
SELECT - ( - col0 ) * col2 + col0 * col1 + col2 FROM tab1
----
294
4345
8816

query I rowsort
SELECT DISTINCT + 20 + + col0 FROM tab0 AS cor0
----
109
44
55

query I rowsort
SELECT + col2 * - col1 + + col0 * - col0 * col2 AS col2 FROM tab1 AS cor0
----
-1890
-234042
-615648

query I rowsort
SELECT + col0 * cor0.col2 * - ( 41 ) FROM tab2 AS cor0
----
-123082
-7749
-83148

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

skipif mysql # not compatible
query I rowsort label-447
SELECT DISTINCT col0 / + col0 + col2 AS col1 FROM tab0
----
2
34
83

query I rowsort
SELECT ALL - tab0.col1 * - 29 + + col0 * col2 + 59 * tab0.col1 AS col0 FROM tab0
----
15306
8360
8571

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

query I rowsort
SELECT - 36 + col2 AS col0 FROM tab2
----
-10
-9
2

query I rowsort
SELECT ALL + 79 + col2 + - tab1.col0 AS col2 FROM tab1
----
130
72
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-452
SELECT - col2 * + col1 DIV col1 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-452
SELECT - col2 * + col1 / col1 FROM tab2
----
-26
-27
-38

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

query I rowsort
SELECT ALL - - col0 + - 56 AS col2 FROM tab0 AS cor0
----
-21
-32
33

query I rowsort
SELECT DISTINCT - - col1 + 54 + - col0 FROM tab1 AS cor0
----
-13
0
77

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

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

query I rowsort
SELECT DISTINCT - col1 + 8 FROM tab1 AS cor0
----
-18
-2
-5

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

skipif mysql # not compatible
query I rowsort label-458
SELECT ALL - col2 * CAST ( - ( cor0.col0 ) AS INTEGER ) AS col2 FROM tab2 AS cor0
----
189
2028
3002

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

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

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

query I rowsort
SELECT col0 + col1 * + 44 FROM tab0 AS cor0
----
3808
4093
4303

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-467
SELECT ALL - - cor0.col0 / 29 FROM tab0 AS cor0
----
0
1
3

query I rowsort
SELECT ALL 91 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT - 86 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 9d2e1e8eda15b3b83dd7136dfc4f19af

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * + ( 8 ) col1 FROM tab0 AS cor0
----
688
728
776

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - ( col0 ) col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL - col1 + ( - 19 ) FROM tab0 AS cor0
----
-105
-110
-116

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

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

query I rowsort
SELECT tab1.col2 * 29 + + col2 FROM tab1
----
1620
1710
2880

query I rowsort
SELECT + 77 * 12 FROM tab2
----
924
924
924

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

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

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

skipif mysql # not compatible
query I rowsort label-480
SELECT ALL + - CAST ( 27 AS INTEGER ) + + col0 - + 27 FROM tab1 AS cor0
----
-51
10
26

query I rowsort
SELECT ALL - + col0 * col0 + - col1 - + ( - col0 ) * cor0.col1 FROM tab2 cor0
----
-1541
-4915
137

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

query I rowsort
SELECT ALL 96 + - col1 AS col2 FROM tab0 AS cor0
----
-1
10
5

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

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

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

query I rowsort
SELECT - 81 + col0 * 43 AS col1 FROM tab2 AS cor0
----
220
3273
3316

onlyif mysql # use DIV operator for integer division
query I rowsort label-487
SELECT ALL - 16 DIV - col1 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-487
SELECT ALL - 16 / - col1 FROM tab1 AS cor0
----
0
1
1

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

skipif mysql # not compatible
query I rowsort label-488
SELECT DISTINCT - col0 / cor0.col0 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT + - 66 + col2 * col1 AS col2 FROM tab1 cor0
----
1182
1338
504

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

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

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 # support for MySQL specific system types and syntax
query I rowsort label-492
SELECT DISTINCT CAST( NULL AS DECIMAL ) * 17 FROM tab1, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-492
SELECT DISTINCT CAST ( NULL AS REAL ) * 17 FROM tab1, tab2 AS cor0
----
NULL

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-495
SELECT - 15 DIV col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-495
SELECT - 15 / col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 55 * col1 - + 37 FROM tab0 AS cor0
----
4693
4968
5298

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-498
SELECT DISTINCT + col2 * cor0.col2 DIV col2 + ( - col0 ) * CAST( + col1 AS SIGNED ) AS col2 FROM tab1 cor0
----
-24
-583
-944

skipif mysql # not compatible
query I rowsort label-498
SELECT DISTINCT + col2 * cor0.col2 / col2 + ( - col0 ) * CAST ( + col1 AS INTEGER ) AS col2 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT ALL col1 * + 34 FROM tab1 AS cor0
----
340
442
884

onlyif mysql # use DIV operator for integer division
query I rowsort label-500
SELECT DISTINCT + 42 DIV + 18 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
2

skipif mysql # not compatible
query I rowsort label-500
SELECT DISTINCT + 42 / + 18 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
2

query I rowsort
SELECT DISTINCT - 17 * - col0 FROM tab2
----
119
1326
1343

query I rowsort
SELECT + 12 + + col2 * + col2 FROM tab0 AS cor0
----
1101
13
6736

query I rowsort
SELECT col1 + 21 * + col2 FROM tab0
----
118
1813
779

query I rowsort
SELECT ALL + + 43 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

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

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

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

query I rowsort
SELECT + ( - ( - col0 ) ) * ( - col2 * + col0 ) + + col0 * + col1 AS col1 FROM tab0 cor0
----
-16944
-641423
2170

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

query I rowsort
SELECT 80 + - col2 * - cor0.col2 + + 63 * + col1 FROM tab1 AS cor0
----
10115
3959
4634

onlyif mysql # use DIV operator for integer division
query I rowsort label-510
SELECT DISTINCT - 42 + + tab0.col0 DIV col2 + col0 AS col0 FROM tab0
----
-18
28
48

skipif mysql # not compatible
query I rowsort label-510
SELECT DISTINCT - 42 + + tab0.col0 / col2 + col0 AS col0 FROM tab0
----
-18
28
48

query I rowsort
SELECT DISTINCT col2 * col0 + ( col0 * + col1 ) AS col2 FROM tab2 cor0
----
406
4345
6630

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-516
SELECT ALL ( col1 ) + ( + col2 ) DIV col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-516
SELECT ALL ( col1 ) + ( + col2 ) / col2 FROM tab1 AS cor0
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + 81 + + 1 col1 FROM tab2
----
113
141
99

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-519
SELECT col1 * + cor0.col2 + col0 DIV + col0 - ( + col1 ) FROM tab1 AS cor0
----
1236
1379
561

skipif mysql # not compatible
query I rowsort label-519
SELECT col1 * + cor0.col2 + col0 / + col0 - ( + col1 ) FROM tab1 AS cor0
----
1236
1379
561

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * 84 + + cor0.col0 * - col1 col1 FROM tab2 AS cor0
----
2387
354
85

query I rowsort
SELECT - col0 - col2 * - col2 AS col2 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT ALL + 67 * col0 + - col0 - - 33 * + 14 AS col1 FROM tab1 AS cor0
----
4686
5742
660

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 53 ) + + col1 col0 FROM tab2 AS cor0
----
-22
-36
6

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

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

query I rowsort
SELECT DISTINCT + ( + 35 ) + + col0 * + col0 FROM tab1 AS cor0
----
4131
44
6435

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

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

query I rowsort
SELECT + 78 + + 2 * col2 AS col1 FROM tab1 AS cor0
----
186
192
270

query I rowsort
SELECT ALL - 76 * col2 + col2 FROM tab2 AS cor0
----
-1950
-2025
-2850

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

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

query I rowsort
SELECT 48 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-532
SELECT + CAST( NULL AS DECIMAL ) * 91 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-532
SELECT + CAST ( NULL AS REAL ) * 91 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - 2 * col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ( 16 ) + col1 FROM tab1 AS cor0
----
26
29
42

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 55 + col2 col2 FROM tab0 AS cor0
----
137
56
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-537
SELECT 55 * - col1 DIV + col1 FROM tab2 AS cor0
----
-55
-55
-55

skipif mysql # not compatible
query I rowsort label-537
SELECT 55 * - col1 / + col1 FROM tab2 AS cor0
----
-55
-55
-55

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

query III rowsort
SELECT * FROM tab2 WHERE NOT - col0 IN ( col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT - col2 FROM tab0 WHERE NULL < - col1
----

query I rowsort
SELECT - col1 - col2 AS col1 FROM tab1 WHERE NOT ( NULL ) >= NULL
----

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

query I rowsort
SELECT - col0 FROM tab1 WHERE - col0 >= NULL
----

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

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT NULL = NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-546
SELECT ALL cor0.col0 DIV col1 + + col2 * + col0 * cor0.col0 col2 FROM tab1 AS cor0
----
233478
486
614406

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-546
SELECT ALL cor0.col0 / col1 + + col2 * + col0 * cor0.col0 col2 FROM tab1 AS cor0
----
233478
486
614406

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NULL < col2 - col0
----

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

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

query I rowsort
SELECT col1 * - col0 + + tab2.col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT + col2 AS col1 FROM tab1 WHERE + col1 NOT BETWEEN - col1 AND + col2 / - col1
----
54
57
96

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL + cor0.col2 * + col0 + col2 + col1 AS col1 FROM tab0 AS cor0
----
133
7471
911

query I rowsort
SELECT - cor0.col2 + col2 * col2 + - col0 FROM tab0 AS cor0
----
-35
1032
6553

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

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

query I rowsort
SELECT ALL + tab1.col2 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 WHERE NOT NULL NOT IN ( tab1.col1 )
----

query I rowsort
SELECT DISTINCT + - col1 * + col1 * + col0 + col2 AS col2 FROM tab0 AS cor0
----
-177471
-329314
-736927

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-565
SELECT DISTINCT - col1 DIV col1 + + col1 * cor0.col2 + col2 FROM tab2 AS cor0
----
1559
683
863

skipif mysql # not compatible
query I rowsort label-565
SELECT DISTINCT - col1 / col1 + + col1 * cor0.col2 + col2 FROM tab2 AS cor0
----
1559
683
863

query I rowsort
SELECT DISTINCT col0 + col2 + col2 AS col0 FROM tab0 AS cor0
----
253
37
90

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-569
SELECT - col0 DIV col0 + + col1 * tab2.col2 FROM tab2
----
1533
645
836

skipif mysql # not compatible
query I rowsort label-569
SELECT - col0 / col0 + + col1 * tab2.col2 FROM tab2
----
1533
645
836

query I rowsort
SELECT col2 * - col1 + col1 * - tab1.col1 AS col2 FROM tab1
----
-1417
-2080
-670

onlyif mysql # use DIV operator for integer division
query I rowsort label-571
SELECT DISTINCT - col0 * - col2 + col0 DIV + col2 AS col1 FROM tab1 AS cor0
----
162
3649
7680

skipif mysql # not compatible
query I rowsort label-571
SELECT DISTINCT - col0 * - col2 + col0 / + col2 AS col1 FROM tab1 AS cor0
----
162
3649
7680

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

query I rowsort
SELECT + ( col1 + - ( + 61 ) ) * + col0 FROM tab1
----
-105
-3264
-3840

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-575
SELECT DISTINCT col0 + + 20 DIV col1 FROM tab2 AS cor0
----
7
78
80

skipif mysql # not compatible
query I rowsort label-575
SELECT DISTINCT col0 + + 20 / col1 FROM tab2 AS cor0
----
7
78
80

query I rowsort
SELECT ALL - cor0.col0 - + 3 AS col0 FROM tab2 AS cor0
----
-10
-81
-82

query I rowsort
SELECT ALL + cor0.col2 * 83 - + cor0.col1 FROM tab0 AS cor0
----
-14
2653
6715

query I rowsort
SELECT col1 * - 34 FROM tab2 AS cor0
----
-1054
-2006
-578

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

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

query I rowsort
SELECT DISTINCT col2 * col1 + col1 + - col0 * + col1 AS col0 FROM tab0
----
-3201
-546
860

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 1 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-588
SELECT + col1 DIV col2 + col0 FROM tab0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-588
SELECT + col1 / col2 + col0 FROM tab0
----
132
26
90

query I rowsort
SELECT col0 * + col1 + + col1 AS col2 FROM tab2 WHERE NOT ( col1 * col1 * col0 + col0 ) BETWEEN ( col0 ) AND ( + col2 )
----
1360
248
4661

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col1 - col0 col0 FROM tab1
----
-164
-249
-679

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

query I rowsort
SELECT ALL + ( 32 ) FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

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

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

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

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

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

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

query I rowsort
SELECT ALL cor0.col1 * + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ae5946db6904798b8afac35f5777bb79

query I rowsort
SELECT - - col2 + 16 AS col0 FROM tab0 cor0
----
17
49
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-602
SELECT - col1 DIV + 19 AS col0 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-602
SELECT - col1 / + 19 AS col0 FROM tab1 cor0
----
-1
0
0

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

query I rowsort
SELECT ALL + ( - 18 ) * col0 AS col1 FROM tab2 AS cor0
----
-126
-1404
-1422

query I rowsort
SELECT col1 + + col2 * cor0.col2 * - col1 FROM tab0 AS cor0
----
-611793
-93568
0

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

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

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

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

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

query I rowsort
SELECT ALL - ( - cor0.col2 ) * - cor0.col1 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 6bd277b8320ae6f8c3fe593411d2dcf6

onlyif mysql # use DIV operator for integer division
query I rowsort label-612
SELECT DISTINCT + + 67 DIV + cor0.col0 FROM tab1, tab0, tab2 AS cor0
----
0
9

skipif mysql # not compatible
query I rowsort label-612
SELECT DISTINCT + + 67 / + cor0.col0 FROM tab1, tab0, tab2 AS cor0
----
0
9

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

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

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

query I rowsort
SELECT ALL col0 * col1 - col0 * col0 * col0 FROM tab1
----
-261504
-510960
51

query I rowsort
SELECT DISTINCT - tab2.col2 + - col1 * - col1 * - col2 FROM tab2
----
-11020
-25974
-90532

onlyif mysql # use DIV operator for integer division
query I rowsort label-618
SELECT tab0.col1 + + tab0.col1 DIV col0 AS col0 FROM tab0
----
89
92
99

skipif mysql # not compatible
query I rowsort label-618
SELECT tab0.col1 + + tab0.col1 / col0 AS col0 FROM tab0
----
89
92
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-619
SELECT col2 + + tab0.col0 DIV col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-619
SELECT col2 + + tab0.col0 / col2 FROM tab0
----
33
36
83

query I rowsort
SELECT col2 * + col2 + - col1 AS col2 FROM tab0
----
-96
1003
6633

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

skipif mysql # not compatible
query I rowsort label-621
SELECT col2 / + tab0.col2 - - col0 AS col1 FROM tab0
----
25
36
90

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-625
SELECT - - col1 * + col0 + col1 DIV - cor0.col2 FROM tab0 cor0
----
2062
3298
8098

skipif mysql # not compatible
query I rowsort label-625
SELECT - - col1 * + col0 + col1 / - cor0.col2 FROM tab0 cor0
----
2062
3298
8098

query I rowsort
SELECT ALL - ( + col0 + tab2.col2 ) * tab2.col1 * - col1 AS col2 FROM tab2
----
32674
33813
362024

query I rowsort
SELECT DISTINCT 27 * col1 FROM tab0
----
2322
2457
2619

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 74 - tab1.col0 col2 FROM tab1
----
-6
10
71

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

query I rowsort
SELECT - + ( - col1 ) + + cor0.col2 * col1 * - col2 AS col1 FROM tab1 AS cor0
----
-119795
-32480
-75790

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

query I rowsort
SELECT 78 * - col1 - col0 FROM tab2 AS cor0
----
-1405
-2425
-4680

query I rowsort
SELECT - - 60 + + col2 FROM tab1 AS cor0
----
114
117
156

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

query I rowsort
SELECT ALL col1 * - ( - col1 ) * 40 AS col1 FROM tab0
----
295840
331240
376360

query I rowsort
SELECT 38 * - col2 + + ( - col2 ) * + tab2.col2 * 14 AS col1 FROM tab2
----
-10452
-11232
-21660

query I rowsort
SELECT ALL col2 * col1 + + col2 * + col1 + col0 * - col0 * - 85 FROM tab0 AS cor0
----
104319
54636
688209

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

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

query I rowsort
SELECT col0 + - 32 FROM tab0
----
-8
3
57

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

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

query I rowsort
SELECT DISTINCT + col1 * + 99 + - col2 FROM tab2
----
1645
3042
5815

onlyif mysql # use DIV operator for integer division
query I rowsort label-642
SELECT + cor0.col0 DIV col2 + - ( cor0.col1 ) + + 99 AS col2 FROM tab0 AS cor0
----
13
37
9

skipif mysql # not compatible
query I rowsort label-642
SELECT + cor0.col0 / col2 + - ( cor0.col1 ) + + 99 AS col2 FROM tab0 AS cor0
----
13
37
9

query I rowsort
SELECT DISTINCT + col2 * + 97 AS col2 FROM tab2 AS cor0
----
2522
2619
3686

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

query I rowsort
SELECT ALL cor0.col2 + cor1.col2 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 557f58b0437448d5f4b4d34aad060bc5

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

skipif mysql # not compatible
query I rowsort label-646
SELECT + col0 / - col2 + col1 AS col2 FROM tab0 cor0
----
62
86
90

query I rowsort
SELECT DISTINCT ( 54 ) + col2 AS col2 FROM tab2 cor0
----
80
81
92

query I rowsort
SELECT DISTINCT + col0 * - col1 + col2 * ( - col2 ) * + cor0.col0 AS col0 FROM tab0 AS cor0
----
-28200
-3430
-606535

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

query I rowsort
SELECT ALL - col1 + col2 * col2 - col1 FROM tab0 AS cor0
----
-193
6542
917

query I rowsort
SELECT DISTINCT - 41 * + col0 FROM tab0 AS cor0
----
-1435
-3649
-984

query I rowsort
SELECT + col0 * - 16 AS col0 FROM tab1 AS cor0
----
-1024
-1280
-48

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - col1 col2 FROM tab0
----
-172
-182
-194

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

skipif mysql # not compatible
query I rowsort label-657
SELECT ALL + + cor0.col2 + - col2 / col0 FROM tab2 AS cor0
----
24
26
38

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

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

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

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

query I rowsort
SELECT - 99 * col2 FROM tab2
----
-2574
-2673
-3762

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

query I rowsort
SELECT DISTINCT - 72 * 93 FROM tab2 AS cor0
----
-6696

query I rowsort
SELECT ALL - ( 73 * col1 ) FROM tab2
----
-1241
-2263
-4307

query I rowsort
SELECT DISTINCT 50 * + 24 AS col1 FROM tab0
----
1200

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-668
SELECT + - 98 * - col1 DIV cor0.col1 AS col1 FROM tab2 cor0
----
98
98
98

skipif mysql # not compatible
query I rowsort label-668
SELECT + - 98 * - col1 / cor0.col1 AS col1 FROM tab2 cor0
----
98
98
98

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

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

query I rowsort
SELECT - - 87 + col1 * col1 AS col2 FROM tab1 AS cor0
----
187
256
763

query I rowsort
SELECT - + 72 + col2 AS col1 FROM tab0 AS cor0
----
-39
-71
10

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

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

query I rowsort
SELECT DISTINCT 29 FROM tab1, tab0 cor0
----
29

query I rowsort
SELECT ALL - ( 61 ) AS col1 FROM tab1
----
-61
-61
-61

query I rowsort
SELECT + + col1 + col1 * - ( - col1 ) * - col0 AS col0 FROM tab2 AS cor0
----
-22814
-271459
-6696

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * + 79 + col0 * col0 * col0 col1 FROM tab0 cor0
----
20618
50538
712158

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-679
SELECT DISTINCT + - col0 + - col1 * 41 DIV col0 AS col2 FROM tab1 cor0
----
-358
-70
-86

skipif mysql # not compatible
query I rowsort label-679
SELECT DISTINCT + - col0 + - col1 * 41 / col0 AS col2 FROM tab1 cor0
----
-358
-70
-86

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

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

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

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

skipif mysql # not compatible
query I rowsort label-682
SELECT col2 / 49 FROM tab0
----
0
0
1

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

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

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

query I rowsort
SELECT DISTINCT 91 - col1 AS col0 FROM tab2
----
32
60
74

query I rowsort
SELECT + col2 * + col1 + ( - col2 * col0 ) - col1 * + col1 FROM tab0
----
-5350
-8117
-9347

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 * - 68 col2 FROM tab0
----
502928
563108
639812

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-691
SELECT - col2 - + 6 DIV 48 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-691
SELECT - col2 - + 6 / 48 FROM tab1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + ( + col0 ) * col2 - - col2 * + col1 col2 FROM tab0 AS cor0
----
14851
229
3716

query I rowsort
SELECT DISTINCT - col0 * + 4 * - col2 + + col1 AS col2 FROM tab0 cor0
----
237
29283
3254

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

query I rowsort
SELECT DISTINCT + col2 + - 86 * + cor0.col2 + + col2 * - 51 AS col2 FROM tab1 AS cor0
----
-13056
-7344
-7752

query I rowsort
SELECT ALL col1 - 4 FROM tab1 AS cor0
----
22
6
9

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-698
SELECT ALL - + col1 * + col2 * 16 - col0 DIV col1 col2 FROM tab0 AS cor0
----
-119392
-1552
-45408

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-698
SELECT ALL - + col1 * + col2 * 16 - col0 / col1 col2 FROM tab0 AS cor0
----
-119392
-1552
-45408

query I rowsort
SELECT + col1 + 78 FROM tab0 cor0
----
164
169
175

query I rowsort
SELECT + 78 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * cor0.col1 * col0 - cor0.col0 col2 FROM tab0 AS cor0
----
3360
664029
68088

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 76 - + col0 * col0 * cor0.col0 col1 FROM tab1 AS cor0
----
-262068
-511924
49

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

query I rowsort
SELECT ALL 89 * + cor0.col2 * + 54 FROM tab0 AS cor0
----
158598
394092
4806

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

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

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

query I rowsort
SELECT + col0 + cor0.col2 * - 6 AS col2 FROM tab2 AS cor0
----
-149
-155
-78

query I rowsort
SELECT DISTINCT - 77 + + col1 * + col1 FROM tab1 AS cor0
----
23
599
92

query I rowsort
SELECT DISTINCT + 70 * col1 FROM tab0 AS cor0
----
6020
6370
6790

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-713
SELECT ALL + 63 DIV col0 FROM tab2 cor0
----
0
0
9

skipif mysql # not compatible
query I rowsort label-713
SELECT ALL + 63 / col0 FROM tab2 cor0
----
0
0
9

query I rowsort
SELECT DISTINCT - 67 + col0 FROM tab1 AS cor0
----
-3
-64
13

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

query I rowsort
SELECT + + 16 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
112
1248
1264

query I rowsort
SELECT ALL 2 * col2 * + ( + col0 ) FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT DISTINCT + col1 * - col2 + - 67 FROM tab2 AS cor0
----
-1601
-713
-904

query I rowsort
SELECT ALL cor1.col0 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 46 col0 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab2 cor2
----
81 values hashing to 086e8f56201fbf4c0ce74087e710811d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 16 * - 84 col0 FROM tab1 AS cor0
----
1344
1344
1344

query I rowsort
SELECT ALL - col1 * - 85 * cor0.col2 + + col0 AS col2 FROM tab1 cor0
----
106160
119343
48514

query I rowsort
SELECT DISTINCT - 25 * - 60 + col0 AS col2 FROM tab1 AS cor0
----
1503
1564
1580

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

query I rowsort
SELECT ALL + 61 FROM tab2, tab2 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT DISTINCT - + cor0.col0 * 29 FROM tab1, tab2, tab0 cor0
----
-1015
-2581
-696

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

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

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

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

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

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

query I rowsort
SELECT + 55 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT + cor0.col2 + 2 FROM tab1 AS cor0
----
56
59
98

query I rowsort
SELECT + col1 * ( 8 ) FROM tab0 AS cor0
----
688
728
776

query I rowsort
SELECT ALL col0 * + col0 - 41 FROM tab1 cor0
----
-32
4055
6359

query I rowsort
SELECT DISTINCT - col2 + + 11 * - col2 AS col0 FROM tab1 AS cor0
----
-1152
-648
-684

query I rowsort
SELECT DISTINCT + 37 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
37

query I rowsort
SELECT ALL 65 + col0 FROM tab1
----
129
145
68

query I rowsort
SELECT - col2 * - col1 + + tab2.col0 * col1 * - col0 FROM tab2
----
-105451
-357422
-682

query I rowsort
SELECT tab1.col0 * + 57 FROM tab1
----
171
3648
4560

query I rowsort
SELECT ALL col1 + cor0.col2 + col0 AS col0 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT col0 * + col0 * + col0 + + col2 AS col0 FROM tab0
----
13857
42876
705051

query I rowsort
SELECT tab2.col1 + - 5 FROM tab2
----
12
26
54

query I rowsort
SELECT col2 * + col2 * col0 + + 84 FROM tab0
----
119
26220
598520

query I rowsort
SELECT DISTINCT - col1 * 10 - - col1 FROM tab1
----
-117
-234
-90

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

query I rowsort
SELECT col1 + col0 * col2 * - 73 AS col0 FROM tab0 cor0
----
-2458
-532663
-57730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * tab0.col2 + + col0 col2 FROM tab0
----
-2814
-62
-7373

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

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

query I rowsort
SELECT DISTINCT - ( + 25 ) * + tab0.col1 FROM tab0
----
-2150
-2275
-2425

query I rowsort
SELECT col2 + col2 + 27 FROM tab0
----
191
29
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-758
SELECT 80 DIV cor0.col2 - + col2 FROM tab1 AS cor0
----
-53
-56
-96

skipif mysql # not compatible
query I rowsort label-758
SELECT 80 / cor0.col2 - + col2 FROM tab1 AS cor0
----
-53
-56
-96

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

query I rowsort
SELECT - 79 * col1 + + 47 * col1 * col2 AS col0 FROM tab1 cor0
----
26000
57629
63934

query I rowsort
SELECT DISTINCT + - 77 * cor0.col1 + col2 AS col1 FROM tab2 cor0
----
-1271
-2360
-4517

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

skipif mysql # not compatible
query I rowsort label-762
SELECT DISTINCT ( col0 ) * col2 + col0 + - col0 * CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
-1155
-534
240

onlyif mysql # use DIV operator for integer division
query I rowsort label-763
SELECT + 15 + + col0 * ( col2 ) DIV + col1 col0 FROM tab2 AS cor0
----
191
21
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-763
SELECT + 15 + + col0 * ( col2 ) / + col1 col0 FROM tab2 AS cor0
----
191
21
49

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

query I rowsort
SELECT ALL - col1 * cor0.col1 + + 71 * col0 AS col1 FROM tab2 cor0
----
-464
2057
5320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col0 + col1 col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + 34 + - cor0.col0 FROM tab2 AS cor0
----
-44
-45
27

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

query I rowsort
SELECT - - col0 * + col2 + col0 * 47 FROM tab1 cor0
----
11440
303
6656

query I rowsort
SELECT cor0.col1 * col1 - 2 FROM tab1 AS cor0
----
167
674
98

query I rowsort
SELECT ALL - col0 * + col0 - 1 * + 21 FROM tab0 AS cor0
----
-1246
-597
-7942

query I rowsort
SELECT DISTINCT col2 * col1 + col2 * 83 AS col2 FROM tab0
----
14268
180
5577

query I rowsort
SELECT ALL col2 * - col1 + 56 FROM tab1
----
-1192
-1348
-514

query I rowsort
SELECT + + cor0.col0 * - col0 + 42 * col0 AS col2 FROM tab2 AS cor0
----
-2808
-2923
245

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-775
SELECT col1 * - CAST( col2 AS SIGNED ) * + col1 FROM tab2
----
-10982
-25947
-90506

skipif mysql # not compatible
query I rowsort label-775
SELECT col1 * - CAST ( col2 AS INTEGER ) * + col1 FROM tab2
----
-10982
-25947
-90506

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - cor0.col0 + + 66 col2 FROM tab0 cor0
----
-1998
-3329
-8033

query I rowsort
SELECT - col0 * - 58 + + col2 * - cor0.col1 FROM tab2 AS cor0
----
-431
2990
3936

query I rowsort
SELECT + + col0 + cor0.col1 + - ( col2 ) FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT col0 + tab2.col1 + + col0 * + 2 * - tab2.col1 AS col0 FROM tab2
----
-2590
-396
-9067

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

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

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

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

query I rowsort
SELECT - col2 * col0 * col0 AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT - + ( ( col2 ) ) + 98 FROM tab0 AS cor0
----
16
65
97

query I rowsort
SELECT ALL + + 27 * col2 FROM tab0 AS cor0
----
2214
27
891

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 62 * + cor0.col2 col0 FROM tab0 AS cor0
----
2046
5084
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + cor0.col2 ) col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT - 29 * 78 FROM tab1 AS cor0
----
-2262
-2262
-2262

query I rowsort
SELECT - 48 * col2 AS col1 FROM tab2 AS cor0
----
-1248
-1296
-1824

query I rowsort
SELECT DISTINCT 33 + + col0 AS col0 FROM tab2 AS cor0
----
111
112
40

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

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

query I rowsort
SELECT - 25 + tab1.col2 AS col0 FROM tab1
----
29
32
71

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

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

query I rowsort
SELECT DISTINCT + - 79 * - 83 + - cor0.col1 FROM tab0 AS cor0
----
6460
6466
6471

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-801
SELECT DISTINCT - col1 * - cor0.col0 + - col1 DIV + col0 AS col2 FROM tab1 cor0
----
1040
640
70

skipif mysql # not compatible
query I rowsort label-801
SELECT DISTINCT - col1 * - cor0.col0 + - col1 / + col0 AS col2 FROM tab1 cor0
----
1040
640
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-802
SELECT DISTINCT cor0.col0 * col1 + + col1 DIV + col1 + col1 AS col0 FROM tab2 AS cor0
----
1361
249
4662

skipif mysql # not compatible
query I rowsort label-802
SELECT DISTINCT cor0.col0 * col1 + + col1 / + col1 + col1 AS col0 FROM tab2 AS cor0
----
1361
249
4662

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - col2 AS REAL ) * col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

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

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

query I rowsort
SELECT + col0 + + 60 * + col0 FROM tab0 AS cor0
----
1464
2135
5429

query I rowsort
SELECT ALL ( 34 ) AS col0 FROM tab1 AS cor0
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-808
SELECT - col1 DIV + 39 AS col0 FROM tab0 AS cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-808
SELECT - col1 / + 39 AS col0 FROM tab0 AS cor0
----
-2
-2
-2

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

query I rowsort
SELECT 65 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 65 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-812
SELECT ALL - tab2.col1 + - CAST( NULL AS DECIMAL ) AS col0 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-812
SELECT ALL - tab2.col1 + - CAST ( NULL AS REAL ) AS col0 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 50 * - col0 AS col1 FROM tab0
----
-1200
-1750
-4450

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( - 23 ) - - col2 col2 FROM tab0 AS cor0
----
-22
10
59

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

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

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

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

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

query I rowsort
SELECT col2 * - 46 AS col0 FROM tab0 AS cor0
----
-1518
-3772
-46

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-824
SELECT tab1.col0 + + 99 * col2 DIV col2 FROM tab1
----
102
163
179

skipif mysql # not compatible
query I rowsort label-824
SELECT tab1.col0 + + 99 * col2 / col2 FROM tab1
----
102
163
179

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

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

skipif mysql # not compatible
query I rowsort label-826
SELECT ALL - col2 + col1 / col0 AS col2 FROM tab2 AS cor0
----
-23
-26
-38

query I rowsort
SELECT ALL 11 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

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

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

query I rowsort
SELECT DISTINCT - col0 + - col0 * col2 * + 51 FROM tab2 AS cor0
----
-103506
-153181
-9646

query I rowsort
SELECT + 31 * - 87 FROM tab1 AS cor0
----
-2697
-2697
-2697

query I rowsort
SELECT DISTINCT col1 + - 85 FROM tab2 cor0
----
-26
-54
-68

query I rowsort
SELECT 29 * + col1 AS col0 FROM tab2 AS cor0
----
1711
493
899

query I rowsort
SELECT ALL - - cor0.col0 * 88 AS col1 FROM tab2 AS cor0
----
616
6864
6952

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

query I rowsort
SELECT col1 * col0 + 17 * + col0 * col2 FROM tab2 AS cor0
----
3430
39078
52377

query I rowsort
SELECT + + col1 * cor0.col1 + 76 FROM tab1 cor0
----
176
245
752

query I rowsort
SELECT + 66 * col2 FROM tab1 cor0
----
3564
3762
6336

query I rowsort
SELECT DISTINCT 79 * cor0.col1 * col1 AS col1 FROM tab1 AS cor0
----
13351
53404
7900

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 96 * + 6 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0b2fee7da0fe5c2df44f38139823103e

query I rowsort
SELECT ALL - cor0.col0 * - 37 * cor0.col2 FROM tab0 AS cor0
----
1295
270026
29304

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

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

skipif mysql # not compatible
query I rowsort label-843
SELECT cor0.col2 + + 95 / col2 FROM tab1 AS cor0
----
55
58
96

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-846
SELECT DISTINCT - 9 DIV - col0 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-846
SELECT DISTINCT - 9 / - col0 FROM tab2
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * tab2.col0 * - 45 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 02f15fb62a7bb180cd345694891b9ae8

onlyif mysql # use DIV operator for integer division
query I rowsort label-848
SELECT + - col1 * col1 DIV - 30 + - col2 AS col0 FROM tab0 AS cor0
----
194
213
312

skipif mysql # not compatible
query I rowsort label-848
SELECT + - col1 * col1 / - 30 + - col2 AS col0 FROM tab0 AS cor0
----
194
213
312

query I rowsort
SELECT ALL 51 + - col0 + ( - col0 ) AS col1 FROM tab0
----
-127
-19
3

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

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

skipif mysql # not compatible
query I rowsort label-851
SELECT DISTINCT - tab1.col2 + + col1 / + col2 FROM tab1
----
-54
-57
-96

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

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

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

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

query I rowsort
SELECT + col1 + col1 * - col0 + col2 AS col0 FROM tab2 AS cor0
----
-1288
-159
-4517

onlyif mysql # use DIV operator for integer division
query I rowsort label-857
SELECT ALL - - col0 DIV - col1 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-857
SELECT ALL - - col0 / - col1 FROM tab1 AS cor0
----
-6
-6
0

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

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT ( - col1 ) <= + col1 * cor0.col1
----

query I rowsort
SELECT ALL - col1 * - col1 + cor0.col1 AS col0 FROM tab0 AS cor0
----
7482
8372
9506

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-862
SELECT ALL - + col1 * + col2 + + cor0.col0 DIV + col0 FROM tab0 AS cor0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-862
SELECT ALL - + col1 * + col2 + + cor0.col0 / + col0 FROM tab0 AS cor0
----
-2837
-7461
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 * - col0 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 + col2 + col0 * + col2 col0 FROM tab2 AS cor0
----
-3201
-4030
167

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

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

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

query IIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1, tab1 cor0 WHERE NOT NULL = ( NULL )
----

query I rowsort
SELECT - 85 AS col2 FROM tab2 AS cor0
----
-85
-85
-85

query I rowsort
SELECT + col2 * + col0 + 90 FROM tab2 AS cor0
----
2118
279
3092

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col2 col0 FROM tab2
----
189
2028
3002

query III rowsort
SELECT * FROM tab2 WHERE + col2 >= ( - col1 * + col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL col1 FROM tab1 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

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

query I rowsort
SELECT col2 AS col2 FROM tab1 WHERE NULL < col0
----

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

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

query I rowsort
SELECT col1 * col2 * - col2 + - col2 * col2 AS col0 FROM tab1
----
-129024
-35739
-78732

onlyif mysql # use DIV operator for integer division
query I rowsort label-881
SELECT col1 DIV col1 + - col0 * - col2 AS col1 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-881
SELECT col1 / col1 + - col0 * - col2 AS col1 FROM tab0 AS cor0
----
36
7299
793

onlyif mysql # use DIV operator for integer division
query I rowsort label-882
SELECT - col2 + + col2 DIV + col2 AS col2 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-882
SELECT - col2 + + col2 / + col2 AS col2 FROM tab0
----
-32
-81
0

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

query I rowsort
SELECT ALL - col0 - + col0 AS col1 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT col1 FROM tab0 WHERE NOT ( - col1 ) IN ( col1 )
----
86
91
97

query III rowsort
SELECT ALL * FROM tab1 WHERE + col0 IN ( col0 - col1 )
----

query I rowsort
SELECT DISTINCT col0 * col1 FROM tab1 WHERE ( NULL ) BETWEEN ( col0 ) AND NULL
----

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

query I rowsort
SELECT ALL col2 + col1 * - col1 AS col1 FROM tab2
----
-251
-3455
-934

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

query I rowsort
SELECT DISTINCT col2 * - col2 + tab1.col2 FROM tab1
----
-2862
-3192
-9120

query III rowsort
SELECT ALL * FROM tab2 WHERE ( col2 ) = ( col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

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

skipif mysql # not compatible
query I rowsort label-893
SELECT tab2.col1 / + col1 AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT ALL - col2 * + col0 + + col0 AS col1 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT col2 FROM tab1 WHERE col1 > NULL
----

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-901
SELECT DISTINCT - col1 DIV col1 + + col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-901
SELECT DISTINCT - col1 / col1 + + col2 FROM tab1
----
53
56
95

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

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

query I rowsort
SELECT - + cor0.col2 * cor0.col2 * - 81 AS col2 FROM tab1 AS cor0
----
236196
263169
746496

query I rowsort
SELECT ALL - + 81 * + col1 FROM tab0 AS cor0
----
-6966
-7371
-7857

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 67 * col0 + + col2 * - col0 + + col0 * - col2 col1 FROM tab0 cor0
----
-20559
-2415
-3192

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

query I rowsort
SELECT ALL + col1 * 75 AS col2 FROM tab1 AS cor0
----
1950
750
975

query I rowsort
SELECT + - col0 + 31 * - col1 AS col1 FROM tab0 AS cor0
----
-2690
-2910
-3042

query I rowsort
SELECT ALL - col1 - 47 AS col0 FROM tab1 cor0
----
-57
-60
-73

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

query I rowsort
SELECT + + col1 + - 44 * 41 AS col1 FROM tab2 AS cor0
----
-1745
-1773
-1787

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

query I rowsort
SELECT - col2 * - 12 AS col0 FROM tab2 AS cor0
----
312
324
456

query I rowsort
SELECT 61 * tab1.col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to dde162369fdd4ffd02de7289eed7ce6f

query I rowsort
SELECT - 64 AS col0 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 100c625e45715c20368551989514ba64

onlyif mysql # use DIV operator for integer division
query I rowsort label-917
SELECT + col0 DIV + 55 + + cor0.col2 * cor0.col0 FROM tab1 AS cor0
----
162
3649
7681

skipif mysql # not compatible
query I rowsort label-917
SELECT + col0 / + 55 + + cor0.col2 * cor0.col0 FROM tab1 AS cor0
----
162
3649
7681

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

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

query I rowsort
SELECT col0 + - 76 FROM tab0 AS cor0
----
-41
-52
13

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

query I rowsort
SELECT + col2 + 19 FROM tab2 AS cor0
----
45
46
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-922
SELECT DISTINCT CAST( col0 AS SIGNED ) + col1 * col0 * col1 FROM tab0 AS cor0
----
177528
329350
737098

skipif mysql # not compatible
query I rowsort label-922
SELECT DISTINCT CAST ( col0 AS INTEGER ) + col1 * col0 * col1 FROM tab0 AS cor0
----
177528
329350
737098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + 6 col0 FROM tab2 AS cor0
----
23
37
65

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 38 * cor0.col1 + col2 col0 FROM tab1 AS cor0
----
1042
437
590

onlyif mysql # use DIV operator for integer division
query I rowsort label-926
SELECT DISTINCT - + 35 + - 88 * col1 DIV - col0 AS col0 FROM tab2 AS cor0
----
-17
31
354

skipif mysql # not compatible
query I rowsort label-926
SELECT DISTINCT - + 35 + - 88 * col1 / - col0 AS col0 FROM tab2 AS cor0
----
-17
31
354

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

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

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

query I rowsort
SELECT + cor0.col0 + 76 FROM tab1, tab1 cor0
----
9 values hashing to 30940ee530cd31b53aa36e0f5086f044

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - ( + tab1.col2 * - 92 ) col0 FROM tab1
----
4971
5308
8912

query I rowsort
SELECT DISTINCT + 76 + - ( col0 * - 15 ) + + col2 AS col2 FROM tab2
----
1272
1299
208

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

query I rowsort
SELECT ALL + - 53 + col1 * + col1 AS col1 FROM tab1 AS cor0
----
116
47
623

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

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

query I rowsort
SELECT DISTINCT + 47 + col2 * col0 AS col1 FROM tab2
----
2075
236
3049

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

query I rowsort
SELECT ALL 60 + + col1 - col1 * col0 * + col0 AS col1 FROM tab1 AS cor0
----
-148
-40890
-83127

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

query I rowsort
SELECT DISTINCT + ( + 80 ) * + tab1.col1 * + col0 + - col2 AS col2 FROM tab1
----
51143
6186
83104

query I rowsort
SELECT 75 * col0 - col1 FROM tab0
----
1714
2528
6584

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

query I rowsort
SELECT col1 + - 90 + col2 * col1 FROM tab0
----
104
2834
7463

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

query I rowsort
SELECT DISTINCT - col2 + + 76 * col0 AS col2 FROM tab1
----
174
4807
5984

query I rowsort
SELECT DISTINCT + col0 + + 77 AS col0 FROM tab0
----
101
112
166

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - 99 * - tab1.col2 col0 FROM tab1
----
5343
5579
9424

query I rowsort
SELECT ( col2 ) * tab1.col2 + + col1 * + col1 + + col2 FROM tab1
----
3406
3646
9481

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col0 + col0 + col1 col1 FROM tab2 AS cor0
----
1439
255
4739

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

skipif mysql # not compatible
query I rowsort label-951
SELECT DISTINCT - col2 * col1 * col2 + col0 / col0 + - col2 FROM tab0 AS cor0
----
-611965
-93686
-97

query I rowsort
SELECT ALL - + 62 FROM tab1 cor0
----
-62
-62
-62

query I rowsort
SELECT DISTINCT + 38 + cor0.col1 FROM tab0 AS cor0
----
124
129
135

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

query I rowsort
SELECT col1 + + 54 + + tab1.col1 AS col1 FROM tab1
----
106
74
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-956
SELECT ALL col1 * - ( - col1 ) - - col0 DIV - col0 FROM tab2
----
288
3480
960

skipif mysql # not compatible
query I rowsort label-956
SELECT ALL col1 * - ( - col1 ) - - col0 / - col0 FROM tab2
----
288
3480
960

query I rowsort
SELECT - col1 + + 55 FROM tab0 AS cor0
----
-31
-36
-42

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-959
SELECT ALL col0 + 50 DIV col1 AS col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-959
SELECT ALL col0 + 50 / col1 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT + + 85 * ( col1 ) FROM tab1 AS cor0
----
1105
2210
850

query I rowsort
SELECT ALL - ( 61 ) * - col0 + col1 FROM tab0 AS cor0
----
1550
2232
5520

query I rowsort
SELECT DISTINCT + 92 + - col1 AS col2 FROM tab1 AS cor0
----
66
79
82

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

query I rowsort
SELECT + - 41 + - col1 FROM tab0 AS cor0
----
-127
-132
-138

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 31 * - 8 * + col0 + - col2 col1 FROM tab0
----
-22154
-5985
-8681

query I rowsort
SELECT ALL col0 * + col1 + col0 * col0 AS col2 FROM tab1
----
4736
7440
87

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

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

query I rowsort
SELECT DISTINCT col2 + col2 + - cor0.col1 * col2 FROM tab0 AS cor0
----
-2772
-7298
-95

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

query I rowsort
SELECT - ( 69 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

query I rowsort
SELECT ALL col2 * + ( - 27 * - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
5103
54756
81054

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * 9 col0 FROM tab0 AS cor0
----
774
819
873

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

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

query I rowsort
SELECT ALL - 39 * col2 + + col0 * - col0 FROM tab1 AS cor0
----
-10144
-2115
-6319

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

query I rowsort
SELECT DISTINCT + + col1 * col1 + col2 + 54 * + ( + col1 ) FROM tab0 AS cor0
----
12073
13277
14648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-981
SELECT - - CAST( - col1 AS SIGNED ) - - cor0.col2 FROM tab2 AS cor0
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-981
SELECT - - CAST ( - col1 AS INTEGER ) - - cor0.col2 FROM tab2 AS cor0
----
-33
-4
21

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

query I rowsort
SELECT + 24 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT DISTINCT tab0.col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
86
91
97

query I rowsort
SELECT 29 * + col0 AS col2 FROM tab0 AS cor0
----
1015
2581
696

query I rowsort
SELECT + 45 * - col2 AS col1 FROM tab1 AS cor0
----
-2430
-2565
-4320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 * + col0 col0 FROM tab2 AS cor0
----
-35
-390
-395

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

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

query I rowsort
SELECT col1 - + 9 FROM tab2 AS cor0
----
22
50
8

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

query I rowsort
SELECT col1 + + col1 * ( - col2 ) * col2 AS col2 FROM tab2 AS cor0
----
-22568
-24531
-39825

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

query I rowsort
SELECT + + 20 * col0 AS col1 FROM tab0 AS cor0
----
1780
480
700

query I rowsort
SELECT ALL - 25 + col2 * + 36 AS col0 FROM tab2 AS cor0
----
1343
911
947

onlyif mysql # use DIV operator for integer division
query I rowsort label-996
SELECT DISTINCT + 71 DIV col1 AS col2 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-996
SELECT DISTINCT + 71 / col1 AS col2 FROM tab2 AS cor0
----
1
2
4

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

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

query I rowsort
SELECT - + cor0.col1 + col0 * 35 AS col1 FROM tab0 AS cor0
----
1128
3024
754

query I rowsort
SELECT DISTINCT - col0 + + 35 * - col0 FROM tab0 AS cor0
----
-1260
-3204
-864

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

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

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

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

query I rowsort
SELECT ALL - col0 + 30 AS col1 FROM tab2 AS cor0
----
-48
-49
23

query I rowsort
SELECT DISTINCT - col1 * + 22 FROM tab1 AS cor0
----
-220
-286
-572

query I rowsort
SELECT ALL 52 * + col0 * 91 FROM tab0
----
113568
165620
421148

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1005
SELECT + col1 + + CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-1005
SELECT + col1 + + CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT 30 * col1 * - 13 AS col0 FROM tab1
----
-10140
-3900
-5070

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1007
SELECT CAST( + 82 AS SIGNED ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

skipif mysql # not compatible
query I rowsort label-1007
SELECT CAST ( + 82 AS INTEGER ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT + col2 * + ( 73 * cor0.col1 ) FROM tab1 AS cor0
----
102492
41610
91104

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1012
SELECT - 82 DIV col1 AS col0 FROM tab1 AS cor0
----
-3
-6
-8

skipif mysql # not compatible
query I rowsort label-1012
SELECT - 82 / col1 AS col0 FROM tab1 AS cor0
----
-3
-6
-8

query I rowsort
SELECT 51 * cor0.col1 + + col2 AS col2 FROM tab2 AS cor0
----
1608
3035
905

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1019
SELECT 22 DIV col1 FROM tab1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1019
SELECT 22 / col1 FROM tab1
----
0
1
2

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

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

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

query I rowsort
SELECT ( - col0 ) * col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT 76 - + tab1.col0 * + cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 70f3693f9b3bb84321063fbda5b358a9

query I rowsort
SELECT + 30 * col1 FROM tab0
----
2580
2730
2910

query I rowsort
SELECT - 4 + col2 AS col2 FROM tab1
----
50
53
92

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

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

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

query I rowsort
SELECT DISTINCT col2 * + col0 + col1 * 29 FROM tab1 AS cor0
----
3938
8057
916

query I rowsort
SELECT 52 + + col0 * cor0.col0 AS col2 FROM tab0 cor0
----
1277
628
7973

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

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

query I rowsort
SELECT DISTINCT + 42 * + col2 FROM tab1 cor0
----
2268
2394
4032

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

query I rowsort
SELECT - 14 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

query I rowsort
SELECT 21 FROM tab1, tab2 cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT col0 * 35 + col1 * + 16 FROM tab1
----
2400
3008
521

query I rowsort
SELECT ALL 54 + + 61 FROM tab0
----
115
115
115

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

query I rowsort
SELECT 99 * cor0.col2 FROM tab1 AS cor0
----
5346
5643
9504

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

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

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

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

query I rowsort
SELECT - + 61 * - col2 + - col1 FROM tab0 AS cor0
----
-36
1927
4911

query I rowsort
SELECT - 12 * col0 AS col2 FROM tab2 AS cor0
----
-84
-936
-948

query I rowsort
SELECT DISTINCT - + ( col0 ) * - 98 + col1 + - col1 AS col1 FROM tab2 AS cor0
----
686
7644
7742

query I rowsort
SELECT ALL + ( + col2 ) * col0 + col2 * col0 AS col2 FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT ALL - 99 - - col0 AS col1 FROM tab0 AS cor0
----
-10
-64
-75

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

query I rowsort
SELECT + col2 - - col0 * - col0 * - cor0.col1 FROM tab0 AS cor0
----
118826
49569
720893

skipif mysql # not compatible
query I rowsort
SELECT + + col1 * CAST ( col0 AS REAL ) + + col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + + col0 * col0 + - 90 AS col1 FROM tab2 AS cor0
----
-41
5994
6151

onlyif mysql # use DIV operator for integer division
query I rowsort label-1054
SELECT + col2 DIV + col0 + col2 - cor0.col0 col2 FROM tab1 AS cor0
----
-7
17
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1054
SELECT + col2 / + col0 + col2 - cor0.col0 col2 FROM tab1 AS cor0
----
-7
17
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * ( - ( + col1 ) ) + ( col2 ) col0 FROM tab0 AS cor0
----
-7363
-8199
-9408

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

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

query I rowsort
SELECT + col1 * + 87 FROM tab1 AS cor0
----
1131
2262
870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 3 - - ( col2 ) col1 FROM tab1 AS cor0
----
112
70
83

query I rowsort
SELECT + + 5 + - cor0.col0 * col0 FROM tab2 AS cor0
----
-44
-6079
-6236

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

query I rowsort
SELECT - + 53 + 17 FROM tab2 AS cor0
----
-36
-36
-36

query I rowsort
SELECT col0 * + 60 AS col0 FROM tab2
----
420
4680
4740

onlyif mysql # use DIV operator for integer division
query I rowsort label-1064
SELECT - CAST( col0 AS SIGNED ) * col0 - - 66 DIV - 73 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-1064
SELECT - CAST ( col0 AS INTEGER ) * col0 - - 66 / - 73 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT 38 * + col1 + cor0.col1 FROM tab1 cor0
----
1014
390
507

query I rowsort
SELECT 40 + - col2 AS col0 FROM tab0 AS cor0
----
-42
39
7

query I rowsort
SELECT ALL - + col1 * + col1 AS col2 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-1068
SELECT col2 + - 40 - cor0.col1 DIV col0 FROM tab2 AS cor0
----
-14
-17
-2

skipif mysql # not compatible
query I rowsort label-1068
SELECT col2 + - 40 - cor0.col1 / col0 FROM tab2 AS cor0
----
-14
-17
-2

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1070
SELECT - 51 DIV + col0 + col1 AS col1 FROM tab1 AS cor0
----
10
13
9

skipif mysql # not compatible
query I rowsort label-1070
SELECT - 51 / + col0 + col1 AS col1 FROM tab1 AS cor0
----
10
13
9

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

query I rowsort
SELECT ( - cor0.col2 ) * col1 - col2 AS col0 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT - 68 + col1 * - col2 FROM tab2 AS cor0
----
-1602
-714
-905

query I rowsort
SELECT DISTINCT + + col2 + + 40 AS col2 FROM tab1 AS cor0
----
136
94
97

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

query I rowsort
SELECT 91 + cor0.col2 FROM tab2 AS cor0
----
117
118
129

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

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

skipif mysql # not compatible
query I rowsort label-1078
SELECT ALL - 74 / - cor0.col1 FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT DISTINCT cor0.col0 + 50 FROM tab2 cor0
----
128
129
57

query I rowsort
SELECT + 80 + col0 AS col1 FROM tab1 AS cor0
----
144
160
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1081
SELECT col2 - CAST( col0 AS SIGNED ) * col1 FROM tab1
----
-24
-583
-944

skipif mysql # not compatible
query I rowsort label-1081
SELECT col2 - CAST ( col0 AS INTEGER ) * col1 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT DISTINCT - tab1.col0 - + 60 FROM tab1
----
-124
-140
-63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1083
SELECT - CAST( 64 AS SIGNED ) + + col1 AS col2 FROM tab0 AS cor0
----
22
27
33

skipif mysql # not compatible
query I rowsort label-1083
SELECT - CAST ( 64 AS INTEGER ) + + col1 AS col2 FROM tab0 AS cor0
----
22
27
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col2 ) + col2 * - 58 col1 FROM tab1 AS cor0
----
-3186
-3363
-5664

query I rowsort
SELECT ALL + + 75 + col2 FROM tab0 AS cor0
----
108
157
76

query I rowsort
SELECT ALL + col1 + + col1 * + col0 * col1 + - 2 AS col1 FROM tab2
----
22846
271575
6756

query I rowsort
SELECT ALL 30 + - tab2.col1 * + col2 AS col2 FROM tab2
----
-1504
-616
-807

query I rowsort
SELECT DISTINCT + ( - 14 ) + cor0.col2 FROM tab1 AS cor0
----
40
43
82

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

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

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

skipif mysql # not compatible
query I rowsort label-1090
SELECT ( + 1 ) + col0 / col1 AS col1 FROM tab2 AS cor0
----
1
2
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 52 * col1 * - col2 + - tab1.col0 + - ( col0 ) col2 FROM tab1
----
-29768
-65056
-73014

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

query I rowsort
SELECT col0 * - col0 + - 28 AS col2 FROM tab2
----
-6112
-6269
-77

query I rowsort
SELECT DISTINCT col1 + 3 + tab2.col1 AS col2 FROM tab2
----
121
37
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-1095
SELECT ALL - col2 + - 19 + 57 DIV tab0.col1 AS col0 FROM tab0
----
-101
-20
-52

skipif mysql # not compatible
query I rowsort label-1095
SELECT ALL - col2 + - 19 + 57 / tab0.col1 AS col0 FROM tab0
----
-101
-20
-52

query I rowsort
SELECT DISTINCT tab0.col1 + + ( - 77 ) FROM tab0
----
14
20
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1097
SELECT col2 + col2 + ( - col1 ) DIV - ( 68 + col1 ) FROM tab2
----
52
54
76

skipif mysql # not compatible
query I rowsort label-1097
SELECT col2 + col2 + ( - col1 ) / - ( 68 + col1 ) FROM tab2
----
52
54
76

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

query I rowsort
SELECT ALL col1 * col1 * col1 - col2 FROM tab1
----
17522
2101
943

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

skipif mysql # not compatible
query I rowsort label-1100
SELECT - col1 + + CAST ( NULL AS REAL ) + - ( col0 ) * 80 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col0 * col0 * + col2 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1226
-19041
-649604

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

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

query I rowsort
SELECT ALL col0 * - ( col0 ) + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1105
SELECT DISTINCT + col0 + CAST( col0 AS SIGNED ) AS col2 FROM tab1 cor0
----
128
160
6

skipif mysql # not compatible
query I rowsort label-1105
SELECT DISTINCT + col0 + CAST ( col0 AS INTEGER ) AS col2 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + - cor0.col1 * - col1 + ( 64 ) FROM tab1 AS cor0
----
164
233
740

query I rowsort
SELECT + - col1 * + col1 + + 46 + + 89 FROM tab2 cor0
----
-154
-3346
-826

query I rowsort
SELECT + - ( col1 ) + 61 AS col0 FROM tab2 AS cor0
----
2
30
44

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

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

query I rowsort
SELECT DISTINCT - 11 + 12 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
1

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

query I rowsort
SELECT ALL + 74 FROM tab1, tab0 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1114
SELECT DISTINCT + col0 + ( - col1 + tab0.col2 ) * CAST( - col0 AS SIGNED ) AS col2 FROM tab0
----
1296
3395
890

skipif mysql # not compatible
query I rowsort label-1114
SELECT DISTINCT + col0 + ( - col1 + tab0.col2 ) * CAST ( - col0 AS INTEGER ) AS col2 FROM tab0
----
1296
3395
890

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

query I rowsort
SELECT - 61 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 80442609e72d8c1c7f1c6175b1d2eac8

query I rowsort
SELECT + col2 + - 29 * col2 * - col1 FROM tab2 AS cor0
----
18772
24300
44512

query I rowsort
SELECT DISTINCT - + ( 26 ) + - col0 AS col0 FROM tab1 AS cor0
----
-106
-29
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1119
SELECT + 69 DIV 97 + col0 * - 49 FROM tab2 AS cor0
----
-343
-3822
-3871

skipif mysql # not compatible
query I rowsort label-1119
SELECT + 69 / 97 + col0 * - 49 FROM tab2 AS cor0
----
-343
-3822
-3871

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

onlyif mysql # use DIV operator for integer division
query I rowsort label-1121
SELECT DISTINCT - cor0.col2 DIV 69 FROM tab2, tab0 AS cor0, tab1 cor1
----
-1
0

skipif mysql # not compatible
query I rowsort label-1121
SELECT DISTINCT - cor0.col2 / 69 FROM tab2, tab0 AS cor0, tab1 cor1
----
-1
0

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

query I rowsort
SELECT - 84 + - cor0.col1 FROM tab0 AS cor0
----
-170
-175
-181

onlyif mysql # use DIV operator for integer division
query I rowsort label-1124
SELECT ALL - 12 DIV col0 + col2 * + 79 FROM tab2
----
2054
2132
3002

skipif mysql # not compatible
query I rowsort label-1124
SELECT ALL - 12 / col0 + col2 * + 79 FROM tab2
----
2054
2132
3002

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

query I rowsort
SELECT DISTINCT - 59 * col0 + cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
-3206
-3472
1227

onlyif mysql # use DIV operator for integer division
query I rowsort label-1127
SELECT ALL + + cor0.col2 * - col2 + - col0 DIV + 25 AS col2 FROM tab1 AS cor0
----
-2916
-3251
-9219

skipif mysql # not compatible
query I rowsort label-1127
SELECT ALL + + cor0.col2 * - col2 + - col0 / + 25 AS col2 FROM tab1 AS cor0
----
-2916
-3251
-9219

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1128
SELECT ALL col2 * CAST( 19 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
1558
19
627

skipif mysql # not compatible
query I rowsort label-1128
SELECT ALL col2 * CAST ( 19 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
1558
19
627

query I rowsort
SELECT ALL + col0 * ( - tab0.col2 * + tab0.col2 ) FROM tab0
----
-26136
-35
-598436

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

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

query I rowsort
SELECT ALL col1 * col1 - - cor0.col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL col2 * 60 + + col1 FROM tab0 cor0
----
157
2066
5011

query I rowsort
SELECT 6 * - ( + col2 ) FROM tab1 AS cor0
----
-324
-342
-576

query I rowsort
SELECT col1 + 7 FROM tab1 cor0
----
17
20
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-1135
SELECT ALL - 2 + 83 + tab0.col0 DIV + ( 89 ) FROM tab0, tab2 AS cor0
----
9 values hashing to 19644d47c1188b50b1d80204c92f228e

skipif mysql # not compatible
query I rowsort label-1135
SELECT ALL - 2 + 83 + tab0.col0 / + ( 89 ) FROM tab0, tab2 AS cor0
----
9 values hashing to 19644d47c1188b50b1d80204c92f228e

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1136
SELECT tab1.col2 / + 87 col1 FROM tab1
----
0
0
1

query I rowsort
SELECT + col2 * 9 * 32 AS col0 FROM tab0
----
23616
288
9504

query I rowsort
SELECT DISTINCT - col0 * - col0 + + col2 * - col0 + + ( col1 ) * - col1 FROM tab2 AS cor0
----
-1101
2950
575

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1140
SELECT ALL - col1 * - CAST( 94 AS SIGNED ) col1 FROM tab2 AS cor0
----
1598
2914
5546

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1140
SELECT ALL - col1 * - CAST ( 94 AS INTEGER ) col1 FROM tab2 AS cor0
----
1598
2914
5546

onlyif mysql # use DIV operator for integer division
query I rowsort label-1141
SELECT ALL - - col2 DIV + 47 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1141
SELECT ALL - - col2 / + 47 FROM tab0 cor0
----
0
0
1

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

query I rowsort
SELECT ALL + 41 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col1 - + 42 col1 FROM tab1 AS cor0
----
1206
1362
528

query I rowsort
SELECT - 32 FROM tab1 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1147
SELECT + tab0.col0 DIV ( - col2 ) + tab0.col2 * col1 + col0 col2 FROM tab0
----
2862
7550
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1147
SELECT + tab0.col0 / ( - col2 ) + tab0.col2 * col1 + col0 col2 FROM tab0
----
2862
7550
97

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

query I rowsort
SELECT DISTINCT col1 + ( col0 ) * col2 * + tab2.col1 AS col2 FROM tab2
----
119711
51051
5890

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

query I rowsort
SELECT + col1 * ( - 38 ) - tab0.col0 AS col0 FROM tab0
----
-3292
-3547
-3721

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

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

query I rowsort
SELECT DISTINCT col0 * tab2.col2 + 6 * col2 AS col2 FROM tab2
----
2184
3230
351

query I rowsort
SELECT ALL col0 + + 92 AS col0 FROM tab2
----
170
171
99

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1159
SELECT - cor0.col1 / - cor0.col1 - ( col2 ) AS col1 FROM tab1 AS cor0
----
-53
-56
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-1160
SELECT ALL 51 + col0 DIV 41 col2 FROM tab1 AS cor0
----
51
52
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1160
SELECT ALL 51 + col0 / 41 col2 FROM tab1 AS cor0
----
51
52
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 94 + cor0.col1 col0 FROM tab2 AS cor0
----
-35
-63
-77

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

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

query I rowsort
SELECT ALL + + 5 * col0 AS col0 FROM tab1 AS cor0
----
15
320
400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 36 * col1 + + col2 col0 FROM tab1 AS cor0
----
417
564
990

query I rowsort
SELECT - 95 + col2 AS col2 FROM tab2 AS cor0
----
-57
-68
-69

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

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

query I rowsort
SELECT ALL - + 30 + col0 FROM tab2 cor0
----
-23
48
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-1169
SELECT + + col2 + + col1 DIV 3 AS col2 FROM tab2 AS cor0
----
37
43
45

skipif mysql # not compatible
query I rowsort label-1169
SELECT + + col2 + + col1 / 3 AS col2 FROM tab2 AS cor0
----
37
43
45

query I rowsort
SELECT - ( + col1 + 92 ) AS col2 FROM tab2
----
-109
-123
-151

query I rowsort
SELECT DISTINCT + + 18 AS col1 FROM tab1 AS cor0
----
18

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

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

query I rowsort
SELECT DISTINCT col1 * col0 + 48 * col2 FROM tab2 AS cor0
----
1513
3167
5850

query I rowsort
SELECT DISTINCT - - 82 + - cor0.col0 * - 98 * cor0.col1 FROM tab1 AS cor0
----
102002
62802
7726

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

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

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

query I rowsort
SELECT + col0 + ( col1 ) + - col2 FROM tab1 cor0
----
-25
-3
17

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + - 30 * + col1 + - col2 col1 FROM tab2 AS cor0
----
-1874
-627
-964

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

query I rowsort
SELECT cor0.col0 - 84 AS col2 FROM tab1 AS cor0
----
-20
-4
-81

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

query I rowsort
SELECT + col1 * col1 * + cor0.col2 - col1 AS col2 FROM tab0 AS cor0
----
243982
678951
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - - ( - col2 ) col1 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1187
SELECT - + col1 * + col1 + 82 DIV - col2 col0 FROM tab0 AS cor0
----
-7398
-8282
-9491

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1187
SELECT - + col1 * + col1 + 82 / - col2 col0 FROM tab0 AS cor0
----
-7398
-8282
-9491

query I rowsort
SELECT DISTINCT + ( + 56 ) * + col0 + ( col1 ) FROM tab0 AS cor0
----
1430
2057
5075

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

query I rowsort
SELECT DISTINCT - ( + ( - col2 ) ) * + 57 FROM tab0 AS cor0
----
1881
4674
57

query I rowsort
SELECT DISTINCT + + 67 * - 40 AS col1 FROM tab2 cor0
----
-2680

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

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

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

query I rowsort
SELECT + - col0 * + ( - cor0.col1 + 32 ) * + col2 FROM tab0 AS cor0
----
2275
42768
430582

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1195
SELECT - CAST( + 99 AS SIGNED ) * col2 + + 59 AS col2 FROM tab0 AS cor0
----
-3208
-40
-8059

skipif mysql # not compatible
query I rowsort label-1195
SELECT - CAST ( + 99 AS INTEGER ) * col2 + + 59 AS col2 FROM tab0 AS cor0
----
-3208
-40
-8059

query I rowsort
SELECT ALL + - 65 FROM tab0 AS cor0
----
-65
-65
-65

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

skipif mysql # not compatible
query I rowsort label-1197
SELECT CAST ( col1 AS INTEGER ) + + col2 * - col0 * 3 AS col2 FROM tab2 AS cor0
----
-536
-6025
-8989

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT DISTINCT ( + 51 ) * col0 * + 2 FROM tab2
----
714
7956
8058

query I rowsort
SELECT 24 + - cor0.col2 * + ( + 81 ) FROM tab1 AS cor0
----
-4350
-4593
-7752

query I rowsort
SELECT DISTINCT + 81 + - cor0.col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-1008
-6643
80

query I rowsort
SELECT 99 * col0 FROM tab0 AS cor0
----
2376
3465
8811

onlyif mysql # use DIV operator for integer division
query I rowsort label-1203
SELECT DISTINCT + col0 + - col0 DIV + 63 AS col0 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-1203
SELECT DISTINCT + col0 + - col0 / + 63 AS col0 FROM tab2 AS cor0
----
7
77
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1204
SELECT CAST( - col0 AS SIGNED ) + - tab0.col0 FROM tab0
----
-178
-48
-70

skipif mysql # not compatible
query I rowsort label-1204
SELECT CAST ( - col0 AS INTEGER ) + - tab0.col0 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT - 15 AS col0 FROM tab1
----
-15
-15
-15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 49 * + cor0.col2 + + 27 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 7cb16a91be095ff98342616ec51a5af2

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

query I rowsort
SELECT DISTINCT col2 * + 72 AS col0 FROM tab0 AS cor0
----
2376
5904
72

query I rowsort
SELECT - col0 * 8 + 56 FROM tab2 cor0
----
-568
-576
0

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

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

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

skipif mysql # not compatible
query I rowsort label-1212
SELECT + + col0 + ( - col0 ) / col2 FROM tab0 AS cor0
----
0
24
88

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1217
SELECT - + ( col1 ) * col1 DIV 2 FROM tab1 AS cor0
----
-338
-50
-84

skipif mysql # not compatible
query I rowsort label-1217
SELECT - + ( col1 ) * col1 / 2 FROM tab1 AS cor0
----
-338
-50
-84

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1219
SELECT - 26 + col1 DIV col1 FROM tab1 AS cor0
----
-25
-25
-25

skipif mysql # not compatible
query I rowsort label-1219
SELECT - 26 + col1 / col1 FROM tab1 AS cor0
----
-25
-25
-25

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1222
SELECT 76 * + col2 * + col1 + col1 + + tab0.col0 DIV col2 FROM tab0
----
215774
567204
7504

skipif mysql # not compatible
query I rowsort label-1222
SELECT 76 * + col2 * + col1 + col1 + + tab0.col0 / col2 FROM tab0
----
215774
567204
7504

query I rowsort
SELECT col2 * tab0.col1 + ( col2 ) + - col1 * - col2 FROM tab0
----
15006
195
5709

query I rowsort
SELECT DISTINCT - - col1 + + col2 + + col0 * col2 FROM tab2 cor0
----
2113
247
3057

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 88 * col1 - ( col1 ) * col2 col0 FROM tab0 AS cor0
----
4730
546
8439

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

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

query I rowsort
SELECT ALL col2 + ( 79 ) * + col2 FROM tab1 AS cor0
----
4320
4560
7680

query I rowsort
SELECT - 61 * col0 FROM tab0
----
-1464
-2135
-5429

onlyif mysql # use DIV operator for integer division
query I rowsort label-1230
SELECT DISTINCT + col2 - col1 DIV - col2 FROM tab0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-1230
SELECT DISTINCT + col2 - col1 / - col2 FROM tab0
----
35
83
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1231
SELECT DISTINCT col2 DIV col1 - tab1.col1 * + col0 * col2 AS col1 FROM tab1
----
-36475
-4210
-99833

skipif mysql # not compatible
query I rowsort label-1231
SELECT DISTINCT col2 / col1 - tab1.col1 * + col0 * col2 AS col1 FROM tab1
----
-36475
-4210
-99833

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

query I rowsort
SELECT - col2 - col1 * col1 FROM tab1 AS cor0
----
-157
-265
-730

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - 80 FROM tab0, tab2 cor0
----
-80

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) * col2 + + cor0.col0 * col1 * col0 col2 FROM tab0 AS cor0
----
118824
48447
714087

query I rowsort
SELECT 31 * cor0.col0 FROM tab0 AS cor0
----
1085
2759
744

query I rowsort
SELECT - + col1 + + col1 * col1 AS col1 FROM tab1 cor0
----
156
650
90

query I rowsort
SELECT DISTINCT ( - 44 ) FROM tab1
----
-44

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

query I rowsort
SELECT + 2 - cor0.col1 FROM tab0 cor0
----
-84
-89
-95

query I rowsort
SELECT DISTINCT + col1 + + 55 * + col2 FROM tab2 AS cor0
----
1489
1516
2107

onlyif mysql # use DIV operator for integer division
query I rowsort label-1246
SELECT col2 + 47 DIV col0 FROM tab2
----
26
33
38

skipif mysql # not compatible
query I rowsort label-1246
SELECT col2 + 47 / col0 FROM tab2
----
26
33
38

query I rowsort
SELECT 8 + - 88 + + col1 FROM tab2 AS cor0
----
-21
-49
-63

query I rowsort
SELECT ALL - 98 * col2 * + col0 AS col1 FROM tab0 cor0
----
-3430
-715204
-77616

query I rowsort
SELECT + - 82 + + col1 * + col0 AS col0 FROM tab0 AS cor0
----
1982
3313
8017

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1252
SELECT + cor0.col0 * col2 DIV + CAST( + 97 AS SIGNED ) + col1 * col2 AS col1 FROM tab1 cor0
----
1327
1405
607

skipif mysql # not compatible
query I rowsort label-1252
SELECT + cor0.col0 * col2 / + CAST ( + 97 AS INTEGER ) + col1 * col2 AS col1 FROM tab1 cor0
----
1327
1405
607

query I rowsort
SELECT + col0 + 51 FROM tab0
----
140
75
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-1254
SELECT col1 * col0 DIV + col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1254
SELECT col1 * col0 / + col1 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT col2 - - 92 AS col0 FROM tab2
----
118
119
130

query I rowsort
SELECT + ( + col1 ) * + col1 - + col0 AS col2 FROM tab1
----
36
673
89

query I rowsort
SELECT ALL - - cor0.col2 * ( col0 ) - col1 * ( + cor0.col2 * col1 ) FROM tab2 AS cor0
----
-25758
-7980
-88478

query I rowsort
SELECT DISTINCT - 16 * - cor0.col2 FROM tab1, tab2, tab1 cor0
----
1536
864
912

query I rowsort
SELECT - 44 + + tab1.col1 FROM tab1, tab0, tab0 cor0
----
27 values hashing to b15c941aab1bd33b3609d368a474111e

query I rowsort
SELECT ALL + col2 + - 73 * col1 AS col0 FROM tab1 AS cor0
----
-1844
-673
-853

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) - 61 * 89 col1 FROM tab1
----
-5432
-5493
-5509

query I rowsort
SELECT + 18 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 903ac227935c1532300db45a8537c595

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

query I rowsort
SELECT + col1 * 83 AS col2 FROM tab2 AS cor0
----
1411
2573
4897

query I rowsort
SELECT cor0.col1 * col1 * col1 FROM tab2 AS cor0
----
205379
29791
4913

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

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

query I rowsort
SELECT DISTINCT col0 * + 44 FROM tab1
----
132
2816
3520

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1270
SELECT - col0 * 86 + col1 DIV col1 AS col0 FROM tab0
----
-2063
-3009
-7653

skipif mysql # not compatible
query I rowsort label-1270
SELECT - col0 * 86 + col1 / col1 AS col0 FROM tab0
----
-2063
-3009
-7653

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

skipif mysql # not compatible
query I rowsort label-1271
SELECT - col1 / ( col1 ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + ( ( + cor0.col0 ) ) * + 26 FROM tab0 AS cor0
----
2314
624
910

query I rowsort
SELECT DISTINCT + + 97 * col2 + cor0.col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
18528
8154
8778

query I rowsort
SELECT ALL - 92 + col0 * col0 FROM tab1 cor0
----
-83
4004
6308

query I rowsort
SELECT ALL + 92 + + col2 AS col2 FROM tab1 AS cor0
----
146
149
188

query I rowsort
SELECT ALL + col1 + 29 FROM tab1 AS cor0
----
39
42
55

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

query I rowsort
SELECT - ( 78 ) * - col1 AS col0 FROM tab1 AS cor0
----
1014
2028
780

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

query I rowsort
SELECT ALL - - col1 * - col2 + + col1 + + 24 * - 97 AS col1 FROM tab0 cor0
----
-2328
-5080
-9699

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

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

query I rowsort
SELECT ( 55 ) * + col0 FROM tab1 AS cor0
----
165
3520
4400

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

query I rowsort
SELECT DISTINCT + ( col0 ) * col0 + col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL - ( col0 ) * + col2 + - 53 * 88 + - col2 AS col2 FROM tab1 cor0
----
-12440
-4880
-8369

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

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

skipif mysql # not compatible
query I rowsort label-1288
SELECT DISTINCT + col0 / - 9 FROM tab1 AS cor0
----
-7
-8
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 45 * - cor0.col2 col2 FROM tab1 AS cor0
----
2430
2565
4320

query I rowsort
SELECT DISTINCT tab1.col1 * col1 + 35 + - col1 FROM tab1
----
125
191
685

onlyif mysql # use DIV operator for integer division
query I rowsort label-1292
SELECT DISTINCT col1 * - col0 + + col0 + ( col0 ) DIV + col1 FROM tab2
----
-1260
-210
-4523

skipif mysql # not compatible
query I rowsort label-1292
SELECT DISTINCT col1 * - col0 + + col0 + ( col0 ) / + col1 FROM tab2
----
-1260
-210
-4523

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

skipif mysql # not compatible
query I rowsort label-1293
SELECT - col1 * + col2 + + CAST ( - col0 AS INTEGER ) AS col2 FROM tab2
----
-1612
-725
-844

query I rowsort
SELECT ( + col1 ) * + 12 AS col2 FROM tab2 AS cor0
----
204
372
708

query I rowsort
SELECT + col2 + col0 + ( col0 ) AS col0 FROM tab0 AS cor0
----
260
71
81

query I rowsort
SELECT DISTINCT 69 * col2 * ( - col0 * col2 ) FROM tab0 AS cor0
----
-1803384
-2415
-41292084

query I rowsort
SELECT - 32 + + col2 AS col2 FROM tab1 cor0
----
22
25
64

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

query I rowsort
SELECT ALL + 52 - col0 * col0 FROM tab2 AS cor0
----
-6032
-6189
3

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

query I rowsort
SELECT DISTINCT + 57 * col1 FROM tab1 AS cor0
----
1482
570
741

query I rowsort
SELECT - 51 - + col0 AS col2 FROM tab0 AS cor0
----
-140
-75
-86

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

query I rowsort
SELECT col2 + - 52 * - cor0.col0 FROM tab0 AS cor0
----
1281
1821
4710

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

skipif mysql # not compatible
query I rowsort label-1305
SELECT DISTINCT + col1 / 56 + col0 AS col2 FROM tab0 cor0
----
25
36
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1306
SELECT DISTINCT + col2 * - CAST( col1 + - col0 AS SIGNED ) * + ( col0 ) FROM tab0 AS cor0
----
-14596
-2170
-49104

skipif mysql # not compatible
query I rowsort label-1306
SELECT DISTINCT + col2 * - CAST ( col1 + - col0 AS INTEGER ) * + ( col0 ) FROM tab0 AS cor0
----
-14596
-2170
-49104

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

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

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

query I rowsort
SELECT 50 AS col0 FROM tab2
----
50
50
50

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1311
SELECT DISTINCT + 67 + col1 DIV + ( col0 + - col1 ) AS col2 FROM tab0 AS cor0
----
22
66

skipif mysql # not compatible
query I rowsort label-1311
SELECT DISTINCT + 67 + col1 / + ( col0 + - col1 ) AS col2 FROM tab0 AS cor0
----
22
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 57 * - ( - col1 ) + - 42 * + col0 col1 FROM tab2 AS cor0
----
-40140
-48003
-90714

query I rowsort
SELECT + col1 * - cor0.col1 + - cor0.col1 AS col1 FROM tab1 cor0
----
-110
-182
-702

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

query I rowsort
SELECT + cor0.col2 * 91 + - ( col2 ) FROM tab2 AS cor0
----
2340
2430
3420

query I rowsort
SELECT col0 * 78 * col1 AS col2 FROM tab2 AS cor0
----
104754
16926
358956

query I rowsort
SELECT + col2 + + 20 * col0 FROM tab1 AS cor0
----
114
1337
1696

query I rowsort
SELECT - col2 * + 43 - + col1 AS col2 FROM tab1 AS cor0
----
-2348
-2461
-4141

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

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

query I rowsort
SELECT + - col1 + 30 AS col2 FROM tab2 AS cor0
----
-1
-29
13

query I rowsort
SELECT + + 42 AS col2 FROM tab1 AS cor0
----
42
42
42

query I rowsort
SELECT DISTINCT - + 43 + - col2 AS col1 FROM tab1 AS cor0
----
-100
-139
-97

query I rowsort
SELECT DISTINCT col0 * col0 - col2 AS col0 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT - - 62 AS col2 FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT - 62 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
1612
620
806

query I rowsort
SELECT 80 - col2 AS col2 FROM tab0 AS cor0
----
-2
47
79

query I rowsort
SELECT 82 - - col0 AS col1 FROM tab0 cor0
----
106
117
171

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

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

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

query I rowsort
SELECT 52 * col1 FROM tab0 cor0
----
4472
4732
5044

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

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

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

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

query I rowsort
SELECT DISTINCT - col0 * 81 FROM tab1 AS cor0
----
-243
-5184
-6480

query I rowsort
SELECT DISTINCT - col0 + + ( - col0 * 97 ) FROM tab2 AS cor0
----
-686
-7644
-7742

query I rowsort
SELECT ALL cor0.col2 * + 49 FROM tab1, tab0 AS cor0
----
9 values hashing to 44c333e6d83e71e6e5b17720a5120882

query I rowsort
SELECT ALL + 88 FROM tab1, tab0 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT DISTINCT - col1 * + col2 * + col2 AS col0 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT ALL - 53 AS col0 FROM tab1, tab0 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 639c30ad80f8147eddb1a5f768a0a5ec

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 92 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 8 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT 64 * 11 + + col1 * col1 AS col1 FROM tab0
----
10113
8100
8985

query I rowsort
SELECT ALL + ( 93 ) AS col2 FROM tab0
----
93
93
93

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

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

query I rowsort
SELECT - 28 + + col2 * + col1 FROM tab2 AS cor0
----
1506
618
809

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

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

skipif mysql # not compatible
query I rowsort label-1349
SELECT DISTINCT CAST ( - col1 AS INTEGER ) + - col1 + - col2 FROM tab2
----
-144
-72
-89

query I rowsort
SELECT ALL 20 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 64 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ALL 34 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 cor1, tab0 AS cor2
----
81 values hashing to 6cda47a564e8ee9e9e7915815a3a7769

query I rowsort
SELECT ALL + cor0.col0 + + ( cor0.col1 ) + col1 * 23 FROM tab2 AS cor0
----
1494
487
751

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

skipif mysql # not compatible
query I rowsort label-1354
SELECT DISTINCT + col0 / - col2 - col0 AS col0 FROM tab1 AS cor0
----
-3
-65
-80

query I rowsort
SELECT + col1 * - 84 AS col2 FROM tab0 AS cor0
----
-7224
-7644
-8148

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1358
SELECT + col1 + CAST( 27 AS SIGNED ) FROM tab2 AS cor0
----
44
58
86

skipif mysql # not compatible
query I rowsort label-1358
SELECT + col1 + CAST ( 27 AS INTEGER ) FROM tab2 AS cor0
----
44
58
86

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1360
SELECT ALL col0 - col2 DIV col1 AS col1 FROM tab1 AS cor0
----
1
59
73

skipif mysql # not compatible
query I rowsort label-1360
SELECT ALL col0 - col2 / col1 AS col1 FROM tab1 AS cor0
----
1
59
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-1361
SELECT + 83 DIV cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to e20226eceab2b4fc27f279b881729973

skipif mysql # not compatible
query I rowsort label-1361
SELECT + 83 / cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to e20226eceab2b4fc27f279b881729973

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col2 FROM tab1, tab0 cor0
----
35
7298
792

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

query I rowsort
SELECT ALL + + col1 * 7 AS col1 FROM tab2 AS cor0
----
119
217
413

query I rowsort
SELECT 64 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT DISTINCT + - 25 + 93 FROM tab1 AS cor0
----
68

query I rowsort
SELECT DISTINCT - ( + col2 * col2 ) FROM tab1
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 93 + + 34 col2 FROM tab2 cor0
----
-59

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

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

skipif mysql # not compatible
query I rowsort label-1370
SELECT DISTINCT - 97 + - cor0.col1 / - col0 AS col1 FROM tab1 AS cor0
----
-89
-97

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

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

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

query I rowsort
SELECT DISTINCT 13 FROM tab0, tab0 AS cor0
----
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-1374
SELECT - col1 + col0 DIV - 54 AS col0 FROM tab0 cor0
----
-86
-92
-97

skipif mysql # not compatible
query I rowsort label-1374
SELECT - col1 + col0 / - 54 AS col0 FROM tab0 cor0
----
-86
-92
-97

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1377
SELECT - + col0 * CAST ( col0 + col0 * cor0.col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-266240
-36
-518400

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * ( cor0.col2 ) col2 FROM tab2 AS cor0
----
189
2028
3002

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

query I rowsort
SELECT DISTINCT col1 + + col1 * + 98 AS col0 FROM tab1
----
1287
2574
990

query I rowsort
SELECT - col0 * + col2 * - col2 + 16 FROM tab2
----
114092
5119
52744

query I rowsort
SELECT DISTINCT 30 * - col1 AS col2 FROM tab2
----
-1770
-510
-930

query I rowsort
SELECT - col0 - + col0 * + col0 FROM tab1
----
-12
-4160
-6480

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

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

query I rowsort
SELECT ALL - col1 * - ( 37 ) FROM tab0 AS cor0
----
3182
3367
3589

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

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

query I rowsort
SELECT + col1 + - col0 * cor0.col1 + col0 FROM tab1 cor0
----
-49
-566
-947

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

query I rowsort
SELECT ALL 94 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

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

query I rowsort
SELECT + - ( + cor0.col0 ) + col0 * + 82 * - col2 FROM tab1 AS cor0
----
-13287
-299200
-629840

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

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

query I rowsort
SELECT + 93 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT ALL col0 * 45 * col0 - 75 AS col2 FROM tab2
----
2130
273705
280770

onlyif mysql # use DIV operator for integer division
query I rowsort label-1400
SELECT DISTINCT + 76 DIV 61 - col2 AS col0 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-1400
SELECT DISTINCT + 76 / 61 - col2 AS col0 FROM tab0
----
-32
-81
0

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

query I rowsort
SELECT DISTINCT - - col1 + col2 + + ( ( - col0 ) ) FROM tab0 AS cor0
----
63
84
95

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

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

query I rowsort
SELECT - 30 + col0 AS col1 FROM tab0 cor0
----
-6
5
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1406
SELECT DISTINCT + 46 + - col0 DIV - col2 AS col2 FROM tab0
----
46
47
81

skipif mysql # not compatible
query I rowsort label-1406
SELECT DISTINCT + 46 + - col0 / - col2 AS col2 FROM tab0
----
46
47
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + 90 col0 FROM tab0
----
2970
7380
90

query I rowsort
SELECT DISTINCT - tab1.col1 * tab1.col0 + col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT 9 + + col2 * col2 FROM tab2
----
1453
685
738

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

query I rowsort
SELECT ALL + col2 * - col1 * + col1 + + cor0.col2 FROM tab2 AS cor0
----
-10944
-25920
-90480

onlyif mysql # use DIV operator for integer division
query I rowsort label-1412
SELECT ALL - - col1 + - col0 DIV + 14 FROM tab0 AS cor0
----
85
85
95

skipif mysql # not compatible
query I rowsort label-1412
SELECT ALL - - col1 + - col0 / + 14 FROM tab0 AS cor0
----
85
85
95

query I rowsort
SELECT 10 - col1 * + cor0.col0 AS col1 FROM tab0 cor0
----
-2054
-3385
-8089

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1416
SELECT - + 49 DIV col0 + col0 AS col1 FROM tab0 cor0
----
22
34
89

skipif mysql # not compatible
query I rowsort label-1416
SELECT - + 49 / col0 + col0 AS col1 FROM tab0 cor0
----
22
34
89

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL + - col2 * - 87 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
2838
7052
86

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

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

query I rowsort
SELECT ALL - - 97 + + col2 FROM tab2 cor0
----
123
124
135

query I rowsort
SELECT ALL cor0.col1 + + col2 * + ( col1 * col0 ) FROM tab1 AS cor0
----
36490
4238
99853

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 + + 5 col2 FROM tab1 AS cor0
----
1253
1409
575

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + col1 col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL col2 + col2 * 75 FROM tab1 AS cor0
----
4104
4332
7296

query I rowsort
SELECT DISTINCT + col1 + 47 + 67 AS col2 FROM tab1 cor0
----
124
127
140

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

query I rowsort
SELECT - cor1.col1 AS col2 FROM tab2, tab0 cor0, tab2 cor1, tab2 AS cor2
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1435
SELECT ALL + col0 * - 81 + - 69 * cor0.col0 DIV col0 col2 FROM tab2 AS cor0
----
-636
-6387
-6468

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1435
SELECT ALL + col0 * - 81 + - 69 * cor0.col0 / col0 col2 FROM tab2 AS cor0
----
-636
-6387
-6468

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

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

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

query I rowsort
SELECT - + col1 * 55 FROM tab0 AS cor0
----
-4730
-5005
-5335

query I rowsort
SELECT + - col2 * - 86 FROM tab1 AS cor0
----
4644
4902
8256

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + cor0.col2 + + 19 col0 FROM tab0 AS cor0
----
-1070
-6705
18

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

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

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

query I rowsort
SELECT - col1 * 72 AS col1 FROM tab1 cor0
----
-1872
-720
-936

query I rowsort
SELECT ALL - + ( - 95 ) FROM tab1 cor0
----
95
95
95

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

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

skipif mysql # not compatible
query I rowsort label-1447
SELECT CAST ( col2 AS INTEGER ) * + col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + 7 * - 54 - + col1 * - cor0.col1 FROM tab1 AS cor0
----
-209
-278
298

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

query I rowsort
SELECT DISTINCT col0 * + 63 FROM tab2
----
441
4914
4977

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

query I rowsort
SELECT - 38 * col1 + - ( col0 ) AS col1 FROM tab2 AS cor0
----
-1185
-2320
-725

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

query I rowsort
SELECT DISTINCT cor1.col1 * 91 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
1183
2366
910

query I rowsort
SELECT - col1 * + col2 + + col2 * + col0 AS col2 FROM tab2 AS cor0
----
-648
2356
494

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

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

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

query I rowsort
SELECT - 35 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 6d967b3bac2e01a0318865f682f9a97b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1460
SELECT - col2 * + 59 * ( - col1 ) + + ( - col2 ) DIV col0 FROM tab1 AS cor0
----
33630
73631
82818

skipif mysql # not compatible
query I rowsort label-1460
SELECT - col2 * + 59 * ( - col1 ) + + ( - col2 ) / col0 FROM tab1 AS cor0
----
33630
73631
82818

onlyif mysql # use DIV operator for integer division
query I rowsort label-1461
SELECT - - col2 + cor0.col1 DIV 35 AS col1 FROM tab0 AS cor0
----
3
35
84

skipif mysql # not compatible
query I rowsort label-1461
SELECT - - col2 + cor0.col1 / 35 AS col1 FROM tab0 AS cor0
----
3
35
84

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

query I rowsort
SELECT DISTINCT tab2.col1 * cor0.col2 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 1d94ea086ff4b04d01d3c46ff83c5c3d

query I rowsort
SELECT DISTINCT - 66 * col0 AS col2 FROM tab0
----
-1584
-2310
-5874

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

query I rowsort
SELECT + - ( + 10 ) + col2 * col1 FROM tab1 AS cor0
----
1238
1394
560

query I rowsort
SELECT ALL 81 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT DISTINCT 47 + - col1 * - 93 AS col2 FROM tab2 AS cor0
----
1628
2930
5534

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

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

skipif mysql # not compatible
query I rowsort label-1470
SELECT DISTINCT + cor0.col0 * + col2 * + CAST ( cor0.col1 AS INTEGER ) + col2 AS col0 FROM tab2 cor0
----
119678
51072
5886

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

query I rowsort
SELECT col2 * col2 * - col2 - + tab2.col1 FROM tab2
----
-17635
-19714
-54889

query I rowsort
SELECT + col2 + + 86 + + col2 AS col2 FROM tab1
----
194
200
278

onlyif mysql # use DIV operator for integer division
query I rowsort label-1474
SELECT DISTINCT col0 DIV + tab0.col2 + col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-1474
SELECT DISTINCT col0 / + tab0.col2 + col2 FROM tab0
----
33
36
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1475
SELECT DISTINCT col1 DIV - ( ( col2 ) ) + col2 + col0 FROM tab1
----
121
176
57

skipif mysql # not compatible
query I rowsort label-1475
SELECT DISTINCT col1 / - ( ( col2 ) ) + col2 + col0 FROM tab1
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1476
SELECT tab2.col2 * CAST( 65 AS SIGNED ) + + col0 * + tab2.col2 + tab2.col1 FROM tab2
----
1975
3777
5489

skipif mysql # not compatible
query I rowsort label-1476
SELECT tab2.col2 * CAST ( 65 AS INTEGER ) + + col0 * + tab2.col2 + tab2.col1 FROM tab2
----
1975
3777
5489

onlyif mysql # use DIV operator for integer division
query I rowsort label-1477
SELECT col2 DIV + tab1.col0 + + col0 col2 FROM tab1
----
21
64
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1477
SELECT col2 / + tab1.col0 + + col0 col2 FROM tab1
----
21
64
81

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

query I rowsort
SELECT DISTINCT - col0 + col2 - + 92 FROM tab2
----
-133
-144
-72

query I rowsort
SELECT DISTINCT col1 * + 12 - + col2 * tab0.col1 AS col2 FROM tab0
----
-1806
-6370
1067

query I rowsort
SELECT ALL - + col2 * - 60 FROM tab1 AS cor0
----
3240
3420
5760

query I rowsort
SELECT - col2 * col1 - ( col1 + + col1 ) AS col1 FROM tab2 AS cor0
----
-1652
-680
-899

query I rowsort
SELECT - col0 + ( 69 ) * col0 FROM tab1 AS cor0
----
204
4352
5440

query I rowsort
SELECT - ( - 80 ) FROM tab0 AS cor0
----
80
80
80

query I rowsort
SELECT ALL + 99 * + ( + col0 + 65 ) AS col2 FROM tab0 AS cor0
----
15246
8811
9900

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

skipif mysql # not compatible
query I rowsort label-1486
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-1487
SELECT ALL 62 - col1 DIV - col0 FROM tab2 AS cor0
----
62
62
66

skipif mysql # not compatible
query I rowsort label-1487
SELECT ALL 62 - col1 / - col0 FROM tab2 AS cor0
----
62
62
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-1488
SELECT DISTINCT + cor0.col0 DIV - ( col2 ) + col1 - 53 FROM tab1 AS cor0
----
-27
-40
-44

skipif mysql # not compatible
query I rowsort label-1488
SELECT DISTINCT + cor0.col0 / - ( col2 ) + col1 - 53 FROM tab1 AS cor0
----
-27
-40
-44

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

query I rowsort
SELECT ALL col2 * 65 FROM tab0
----
2145
5330
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1491
SELECT - CAST( ( col1 ) AS SIGNED ) + 77 FROM tab0 AS cor0
----
-14
-20
-9

skipif mysql # not compatible
query I rowsort label-1491
SELECT - CAST ( ( col1 ) AS INTEGER ) + 77 FROM tab0 AS cor0
----
-14
-20
-9

query I rowsort
SELECT ALL + ( + 12 ) + - col0 FROM tab0 AS cor0
----
-12
-23
-77

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

query I rowsort
SELECT ALL - + 34 + cor0.col2 * col1 AS col1 FROM tab2 cor0
----
1500
612
803

onlyif mysql # use DIV operator for integer division
query I rowsort label-1495
SELECT DISTINCT 65 + ( col1 ) DIV + ( col2 ) + + col0 FROM tab1 AS cor0
----
129
145
68

skipif mysql # not compatible
query I rowsort label-1495
SELECT DISTINCT 65 + ( col1 ) / + ( col2 ) + + col0 FROM tab1 AS cor0
----
129
145
68

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

query I rowsort
SELECT DISTINCT + + ( + col2 ) + col2 * 48 AS col1 FROM tab0 AS cor0
----
1617
4018
49

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

query I rowsort
SELECT ALL col2 * 66 FROM tab1
----
3564
3762
6336

query I rowsort
SELECT - ( col1 ) * col1 - 90 AS col1 FROM tab1 cor0
----
-190
-259
-766

query I rowsort
SELECT ALL + col0 + col1 - - cor0.col2 FROM tab0 AS cor0
----
133
143
262

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1503
SELECT - + col0 * col2 DIV + col1 AS col2 FROM tab1 AS cor0
----
-364
-590
-6

skipif mysql # not compatible
query I rowsort label-1503
SELECT - + col0 * col2 / + col1 AS col2 FROM tab1 AS cor0
----
-364
-590
-6

query I rowsort
SELECT col0 + + col0 * col2 + col1 AS col2 FROM tab0 cor0
----
167
7478
902

query I rowsort
SELECT + 15 * col0 FROM tab2 AS cor0
----
105
1170
1185

query I rowsort
SELECT col2 * 61 AS col0 FROM tab2
----
1586
1647
2318

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( 62 ) col2 FROM tab1, tab0, tab2 AS cor0
----
62

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1512
SELECT ALL + col2 / col1 + + col2 col2 FROM tab0 AS cor0
----
1
33
82

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

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1519
SELECT + col2 * 71 DIV + ( + col0 * 13 ) FROM tab0 cor0
----
0
5
7

skipif mysql # not compatible
query I rowsort label-1519
SELECT + col2 * 71 / + ( + col0 * 13 ) FROM tab0 cor0
----
0
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * + 42 + col2 col1 FROM tab0 AS cor0
----
-1353
-3362
-41

query I rowsort
SELECT DISTINCT col2 + 77 * 16 FROM tab0 AS cor0
----
1233
1265
1314

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

query I rowsort
SELECT + col0 * + 81 FROM tab0 AS cor0
----
1944
2835
7209

onlyif mysql # use DIV operator for integer division
query I rowsort label-1524
SELECT + + col2 * col2 DIV - col1 FROM tab0 AS cor0
----
-12
-73
0

skipif mysql # not compatible
query I rowsort label-1524
SELECT + + col2 * col2 / - col1 FROM tab0 AS cor0
----
-12
-73
0

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1528
SELECT - + col1 / - CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
1
2
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1529
SELECT - col2 * - CAST( - col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-1529
SELECT - col2 * - CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

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

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

query I rowsort
SELECT - - ( - cor0.col0 ) + + col2 * + 7 AS col1 FROM tab1 AS cor0
----
335
375
592

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - ( 90 ) col2 FROM tab1 AS cor0
----
-4860
-5130
-8640

query I rowsort
SELECT - - col2 * - 32 FROM tab1 AS cor0
----
-1728
-1824
-3072

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1537
SELECT + CAST( col2 AS SIGNED ) * + col1 + + col2 DIV col2 AS col0 FROM tab0 AS cor0
----
2839
7463
98

skipif mysql # not compatible
query I rowsort label-1537
SELECT + CAST ( col2 AS INTEGER ) * + col1 + + col2 / col2 AS col0 FROM tab0 AS cor0
----
2839
7463
98

query I rowsort
SELECT + col2 * + col1 * col2 + + 91 AS col2 FROM tab1 AS cor0
----
119899
32581
75907

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

query I rowsort
SELECT - 86 * - 96 + + col0 * col2 FROM tab0 AS cor0
----
15554
8291
9048

query I rowsort
SELECT ALL col2 + 33 AS col2 FROM tab0
----
115
34
66

query I rowsort
SELECT DISTINCT tab0.col0 + col0 + + col0 FROM tab0
----
105
267
72

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1544
SELECT col0 DIV CAST( - col2 AS SIGNED ) col2 FROM tab0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1544
SELECT col0 / CAST ( - col2 AS INTEGER ) col2 FROM tab0
----
-1
-35
0

query I rowsort
SELECT DISTINCT - col2 * ( 95 * - col0 ) + - 17 + col0 FROM tab2
----
17945
192721
285252

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

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

query I rowsort
SELECT + col0 + - cor0.col1 * + col1 * - col1 FROM tab0 AS cor0
----
636080
753660
912708

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

skipif mysql # not compatible
query I rowsort label-1549
SELECT + col0 / - 99 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1550
SELECT DISTINCT + col0 DIV 22 AS col2 FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-1550
SELECT DISTINCT + col0 / 22 AS col2 FROM tab2 AS cor0
----
0
3

query I rowsort
SELECT ALL 7 * + col1 + + 0 * col2 FROM tab0 AS cor0
----
602
637
679

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

query I rowsort
SELECT ALL + 32 + col2 * 51 FROM tab0 AS cor0
----
1715
4214
83

query I rowsort
SELECT ALL - 97 + col2 AS col1 FROM tab0 AS cor0
----
-15
-64
-96

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1556
SELECT DISTINCT - 64 DIV 37 - - col0 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-1556
SELECT DISTINCT - 64 / 37 - - col0 FROM tab2
----
6
77
78

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

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

query I rowsort
SELECT 48 + cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to baa3880a16e4ff665796379a71bd1bd1

query I rowsort
SELECT col0 * + 15 FROM tab2
----
105
1170
1185

query I rowsort
SELECT ALL + 9 - col2 FROM tab0
----
-24
-73
8

query I rowsort
SELECT - 48 AS col2 FROM tab2
----
-48
-48
-48

query I rowsort
SELECT + 30 + - col0 FROM tab0
----
-5
-59
6

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col0 * col2 col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - 49 * col0 FROM tab1 AS cor0
----
-147
-3136
-3920

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

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

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

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

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

query I rowsort
SELECT + cor0.col2 + + col1 * col0 + 28 FROM tab2 AS cor0
----
1409
272
4656

query I rowsort
SELECT 86 FROM tab1, tab2 cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT - 38 - - col1 AS col2 FROM tab2 AS cor0
----
-21
-7
21

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

query I rowsort
SELECT - 21 * - ( col0 ) - 44 AS col2 FROM tab2 AS cor0
----
103
1594
1615

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

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

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

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

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

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

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

query I rowsort
SELECT + col1 + cor0.col2 - col0 AS col0 FROM tab0 AS cor0
----
63
84
95

query I rowsort
SELECT - - col0 * + cor0.col1 + + col0 * + col1 AS col0 FROM tab2 AS cor0
----
2686
434
9204

query I rowsort
SELECT ( 9 ) FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

onlyif mysql # use DIV operator for integer division
query I rowsort label-1585
SELECT - col0 DIV col0 - + 60 * col1 * col2 FROM tab0
----
-170281
-447721
-5821

skipif mysql # not compatible
query I rowsort label-1585
SELECT - col0 / col0 - + 60 * col1 * col2 FROM tab0
----
-170281
-447721
-5821

query I rowsort
SELECT ALL + - col1 + + 0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - col1 * - 5 FROM tab1 AS cor0
----
130
50
65

query I rowsort
SELECT DISTINCT - col2 + col0 * + col0 * col1 AS col0 FROM tab2 AS cor0
----
106059
1492
358930

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

query I rowsort
SELECT DISTINCT - tab2.col2 + - 59 + - col0 FROM tab2
----
-163
-176
-93

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

query I rowsort
SELECT DISTINCT + 2 * col0 AS col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL - 95 + col2 AS col0 FROM tab1 AS cor0
----
-38
-41
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1594
SELECT ALL col2 + col1 DIV - 17 + cor0.col1 col0 FROM tab0 AS cor0
----
114
168
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1594
SELECT ALL col2 + col1 / - 17 + cor0.col1 col0 FROM tab0 AS cor0
----
114
168
93

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

query I rowsort
SELECT DISTINCT + col0 * + col0 + col2 * - 61 - col1 FROM tab2
----
-1629
3906
4439

query I rowsort
SELECT - 19 + + tab2.col2 + - 40 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to a7effad3ceefd0b6a2485fdfcb368b4d

query I rowsort
SELECT - col0 + col1 - - ( col2 ) * col2 AS col1 FROM tab1
----
2939
3195
9149

query I rowsort
SELECT + 89 * - col1 - col0 FROM tab0 cor0
----
-7678
-8188
-8668

onlyif mysql # use DIV operator for integer division
query I rowsort label-1600
SELECT ALL - + col0 * cor0.col1 DIV CAST( cor0.col0 AS SIGNED ) FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-1600
SELECT ALL - + col0 * cor0.col1 / CAST ( cor0.col0 AS INTEGER ) FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1601
SELECT - 30 DIV col0 AS col0 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-1601
SELECT - 30 / col0 AS col0 FROM tab2 cor0
----
-4
0
0

query I rowsort
SELECT + col1 * col1 - 68 FROM tab1 AS cor0
----
101
32
608

onlyif mysql # use DIV operator for integer division
query I rowsort label-1603
SELECT + ( col0 ) + - 1 DIV - 24 AS col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-1603
SELECT + ( col0 ) + - 1 / - 24 AS col2 FROM tab1
----
3
64
80

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-1605
SELECT DISTINCT - ( - cor0.col2 ) + 40 DIV col1 FROM tab2 cor0
----
26
28
40

skipif mysql # not compatible
query I rowsort label-1605
SELECT DISTINCT - ( - cor0.col2 ) + 40 / col1 FROM tab2 cor0
----
26
28
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-1606
SELECT DISTINCT + col1 DIV + col2 + col0 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-1606
SELECT DISTINCT + col1 / + col2 + col0 FROM tab0 AS cor0
----
132
26
90

query I rowsort
SELECT - + 84 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

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

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

query I rowsort
SELECT - - col1 * + col1 + col0 * + col1 AS col2 FROM tab1 AS cor0
----
1209
740
754

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

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

skipif mysql # not compatible
query I rowsort label-1611
SELECT ALL - - cor0.col1 + CAST ( - col0 AS INTEGER ) * - cor0.col1 - col0 FROM tab0 cor0
----
2126
3457
8101

query I rowsort
SELECT ALL - + col2 + 45 AS col1 FROM tab2 AS cor0
----
18
19
7

query I rowsort
SELECT ALL - + 80 FROM tab2, tab2 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

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

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

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

query I rowsort
SELECT - 61 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 51f53697966a79d306a4570537cd91a1

query I rowsort
SELECT - col2 * - ( - col0 + 26 ) AS col0 FROM tab2 cor0
----
-1352
-2014
513

query I rowsort
SELECT DISTINCT + 65 * - ( + cor0.col0 ) FROM tab1 AS cor0
----
-195
-4160
-5200

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

query I rowsort
SELECT + ( + 81 ) AS col1 FROM tab2
----
81
81
81

query I rowsort
SELECT ALL - col2 * 77 + col1 FROM tab2 AS cor0
----
-1943
-2048
-2909

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

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

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

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

query I rowsort
SELECT + col0 * col0 * - col0 + + 18 AS col2 FROM tab1 AS cor0
----
-262126
-511982
-9

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

query I rowsort
SELECT DISTINCT - + 11 - + cor0.col0 * col0 FROM tab2 AS cor0
----
-60
-6095
-6252

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1628
SELECT ALL + 43 + 27 DIV - col1 AS col0 FROM tab2 AS cor0
----
42
43
43

skipif mysql # not compatible
query I rowsort label-1628
SELECT ALL + 43 + 27 / - col1 AS col0 FROM tab2 AS cor0
----
42
43
43

query I rowsort
SELECT + + 17 * - 86 FROM tab0 AS cor0
----
-1462
-1462
-1462

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1630
SELECT DISTINCT cor0.col0 + + cor0.col1 + CAST( 37 AS SIGNED ) * - col2 col0 FROM tab2 AS cor0
----
-1310
-825
-961

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

query I rowsort
SELECT DISTINCT - 67 + col1 AS col1 FROM tab0 AS cor0
----
19
24
30

query I rowsort
SELECT ALL + col2 * col0 - 34 AS col0 FROM tab0 cor0
----
1
7264
758

query I rowsort
SELECT + - col0 + col1 * - 45 FROM tab1 AS cor0
----
-1173
-514
-665

query I rowsort
SELECT DISTINCT + 70 + col0 FROM tab2 AS cor0
----
148
149
77

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

query I rowsort
SELECT + + col2 + - col2 + + col0 FROM tab2 cor0
----
7
78
79

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

query III rowsort
SELECT * FROM tab2 WHERE NOT col0 * col0 BETWEEN ( col0 + col0 ) AND - col0 + + col0 * col2 AND - col1 / col0 NOT IN ( - col0 )
----
78
59
26
79
17
38

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

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

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

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

query I rowsort
SELECT 71 * + col1 FROM tab0 AS cor0
----
6106
6461
6887

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

query I rowsort
SELECT - cor0.col2 * - col2 - + col2 * + col2 * - cor0.col0 FROM tab1 AS cor0
----
11664
211185
746496

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

query I rowsort
SELECT - ( + col1 ) + + col1 * - col1 * col0 FROM tab0 AS cor0
----
-177590
-329412
-737100

onlyif mysql # use DIV operator for integer division
query I rowsort label-1648
SELECT cor0.col2 + - col2 DIV - col1 + + col1 AS col0 FROM tab1 AS cor0
----
116
72
82

skipif mysql # not compatible
query I rowsort label-1648
SELECT cor0.col2 + - col2 / - col1 + + col1 AS col0 FROM tab1 AS cor0
----
116
72
82

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

query I rowsort
SELECT + 96 + col0 * - col2 FROM tab0 AS cor0
----
-696
-7202
61

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

query I rowsort
SELECT + 66 * col0 + - col1 FROM tab0
----
1498
2213
5783

query I rowsort
SELECT ALL + col2 + col0 * col2 + - col1 FROM tab2
----
185
1995
3023

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1655
SELECT DISTINCT tab2.col2 + col2 * col2 DIV - col0 FROM tab2
----
-77
18
20

skipif mysql # not compatible
query I rowsort label-1655
SELECT DISTINCT tab2.col2 + col2 * col2 / - col0 FROM tab2
----
-77
18
20

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

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

skipif mysql # not compatible
query I rowsort label-1657
SELECT + col2 / - col1 + - col0 AS col1 FROM tab1
----
-5
-69
-87

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

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

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

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

query I rowsort
SELECT + col2 * col2 * - col2 - col1 * - tab1.col1 FROM tab1
----
-156788
-185093
-884567

onlyif mysql # use DIV operator for integer division
query I rowsort label-1663
SELECT + col2 * col2 + col0 DIV - col0 FROM tab1
----
2915
3248
9215

skipif mysql # not compatible
query I rowsort label-1663
SELECT + col2 * col2 + col0 / - col0 FROM tab1
----
2915
3248
9215

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

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

query I rowsort
SELECT ALL + col0 + - col1 + col0 * + tab2.col2 FROM tab2
----
165
2047
3064

query I rowsort
SELECT col1 * col1 - - col2 AS col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT col1 * col0 + + col1 * - tab1.col2 * col0 + col0 FROM tab1
----
-35776
-4131
-98720

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

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

skipif mysql # not compatible
query I rowsort label-1670
SELECT DISTINCT - col1 + - col1 / col1 AS col2 FROM tab0
----
-87
-92
-98

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

query I rowsort
SELECT DISTINCT col0 + col0 * col0 + col0 FROM tab0
----
1295
624
8099

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

query I rowsort
SELECT DISTINCT - col0 * col0 * col0 FROM tab0
----
-13824
-42875
-704969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 + + col1 col0 FROM tab1
----
188
3658
7693

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

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

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

query I rowsort
SELECT DISTINCT + col0 + col1 * cor0.col1 * - col0 FROM tab1 AS cor0
----
-13440
-2025
-6336

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

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

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

query IIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0 WHERE NULL <> ( NULL )
----

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

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

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

query I rowsort
SELECT ALL + ( col1 * - col2 ) + tab2.col2 + col2 FROM tab2
----
-1482
-570
-783

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1687
SELECT DISTINCT - - CAST ( col1 AS INTEGER ) col1 FROM tab2 AS cor0
----
17
31
59

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

query I rowsort
SELECT + - ( - 24 ) * - col2 FROM tab1 AS cor0
----
-1296
-1368
-2304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1690
SELECT CAST( + col2 AS SIGNED ) col2 FROM tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1690
SELECT CAST ( + col2 AS INTEGER ) col2 FROM tab0 cor0
----
1
33
82

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

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

query I rowsort
SELECT 53 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
159
3392
4240

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

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

skipif mysql # not compatible
query I rowsort label-1695
SELECT DISTINCT - ( + col1 ) / + cor0.col0 AS col2 FROM tab2 AS cor0
----
-4
0

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

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

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

query I rowsort
SELECT DISTINCT - 20 * col2 + ( cor0.col2 ) AS col0 FROM tab0 AS cor0
----
-1558
-19
-627

query I rowsort
SELECT ALL cor0.col2 * 80 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 18be62fcf077a215de3809ceafb814a9

query I rowsort
SELECT - 54 AS col1 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 71e27a12767d3a987ce05e4d6edad211

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

query I rowsort
SELECT DISTINCT - 63 * col2 AS col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT ALL + col2 * col0 - + col1 * ( + col0 * - col2 ) AS col1 FROM tab0 AS cor0
----
3430
671416
68904

query I rowsort
SELECT + cor0.col1 * - col2 - 90 AS col0 FROM tab1 AS cor0
----
-1338
-1494
-660

query I rowsort
SELECT DISTINCT + 57 - - tab0.col2 AS col2 FROM tab0
----
139
58
90

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

query I rowsort
SELECT ALL - 23 + col1 FROM tab0
----
63
68
74

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1709
SELECT - col2 * cor0.col2 DIV col1 AS col2 FROM tab1 AS cor0
----
-112
-324
-708

skipif mysql # not compatible
query I rowsort label-1709
SELECT - col2 * cor0.col2 / col1 AS col2 FROM tab1 AS cor0
----
-112
-324
-708

query I rowsort
SELECT + cor0.col2 * + 39 FROM tab2 AS cor0
----
1014
1053
1482

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col0 * + 27 + - col1 col2 FROM tab0 AS cor0
----
2221
476
751

query I rowsort
SELECT ALL - - col0 + 23 FROM tab0 AS cor0
----
112
47
58

query I rowsort
SELECT DISTINCT - - col0 * 11 AS col2 FROM tab1 AS cor0
----
33
704
880

query I rowsort
SELECT ALL 25 * - tab2.col2 + tab2.col0 + 99 FROM tab2
----
-473
-569
-772

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

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

skipif mysql # not compatible
query I rowsort label-1718
SELECT DISTINCT col1 + + CAST ( 6 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
16
19
32

query I rowsort
SELECT - col2 * col2 * ( - 38 ) FROM tab1
----
110808
123462
350208

query I rowsort
SELECT cor0.col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1721
SELECT ALL col0 * CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1721
SELECT ALL col0 * CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT ALL + col1 * + CAST ( col0 AS REAL ) / col1 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - 57 AS col1 FROM tab1 cor0
----
-57

query I rowsort
SELECT + 19 * col0 * + col0 AS col0 FROM tab2 AS cor0
----
115596
118579
931

onlyif mysql # use DIV operator for integer division
query I rowsort label-1725
SELECT DISTINCT tab2.col0 DIV 74 AS col0 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-1725
SELECT DISTINCT tab2.col0 / 74 AS col0 FROM tab2
----
0
1

query I rowsort
SELECT ALL - col0 * 71 AS col2 FROM tab2
----
-497
-5538
-5609

query I rowsort
SELECT + tab2.col0 * 31 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 4a0cf49c2135fc224646191a4a736cc8

query I rowsort
SELECT DISTINCT + 72 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
72

query I rowsort
SELECT col0 * 87 + 91 FROM tab2
----
6877
6964
700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1730
SELECT CAST( - 84 * - col2 AS SIGNED ) FROM tab1
----
4536
4788
8064

skipif mysql # not compatible
query I rowsort label-1730
SELECT CAST ( - 84 * - col2 AS INTEGER ) FROM tab1
----
4536
4788
8064

query I rowsort
SELECT DISTINCT - 20 * col0 AS col1 FROM tab1
----
-1280
-1600
-60

query I rowsort
SELECT - 43 FROM tab0, tab1 cor0
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

query I rowsort
SELECT ( - col0 ) + - col2 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT DISTINCT ( + col0 ) + - col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT + col1 * - ( + col0 ) + - col2 AS col1 FROM tab0 cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-1736
SELECT ALL CAST( col0 AS SIGNED ) DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1736
SELECT ALL CAST ( col0 AS INTEGER ) / col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 64 + - col0 + col2 FROM tab2
----
12
23
84

query I rowsort
SELECT DISTINCT + cor0.col2 * - 30 FROM tab0, tab0 AS cor0
----
-2460
-30
-990

query I rowsort
SELECT + tab0.col2 * + col1 * - tab0.col0 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT tab1.col0 + col1 AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT 30 + col1 AS col1 FROM tab1
----
40
43
56

query I rowsort
SELECT DISTINCT - ( + col2 ) + - 93 * col2 FROM tab0
----
-3102
-7708
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col2 + col0 + + col0 col0 FROM tab2
----
182
196
41

query I rowsort
SELECT ALL + col2 * col0 * col0 + 12 * + col2 FROM tab2
----
158496
1647
237614

query I rowsort
SELECT DISTINCT + + cor0.col2 + - 94 FROM tab1 AS cor0
----
-37
-40
2

query I rowsort
SELECT ALL cor0.col0 * col1 + 81 FROM tab0 AS cor0
----
2145
3476
8180

query I rowsort
SELECT - - col0 + + 4 * - col1 FROM tab2 cor0
----
-117
-158
11

query I rowsort
SELECT DISTINCT + col1 * col1 - + 7 * + cor0.col1 FROM tab0 AS cor0
----
6794
7644
8730

query I rowsort
SELECT col1 + + ( 19 ) AS col0 FROM tab0 AS cor0
----
105
110
116

query I rowsort
SELECT ALL + col0 + - col2 * 92 * - col2 AS col2 FROM tab0 AS cor0
----
100212
127
618697

onlyif mysql # use DIV operator for integer division
query I rowsort label-1751
SELECT DISTINCT - cor0.col1 DIV col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-1751
SELECT DISTINCT - cor0.col1 / col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT - col1 + + 64 AS col0 FROM tab2 AS cor0
----
33
47
5

query I rowsort
SELECT DISTINCT + col2 - col2 * - col0 FROM tab0 cor0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 88 col2 FROM tab2 AS cor0
----
-1496
-2728
-5192

query I rowsort
SELECT ALL + cor0.col2 + + col2 + + col0 AS col0 FROM tab2 cor0
----
130
155
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-1756
SELECT + col1 + - col1 DIV + col0 AS col1 FROM tab0 AS cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-1756
SELECT + col1 + - col1 / + col0 AS col1 FROM tab0 AS cor0
----
83
90
95

query I rowsort
SELECT ALL - 51 AS col0 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 27bcc31433ce90833ed76619cbd8d6a4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1758
SELECT - CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1758
SELECT - CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + 91 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT ALL + col1 * 29 * col2 + col1 - + 47 * + tab2.col2 * - col1 FROM tab2
----
116643
49113
63643

query I rowsort
SELECT DISTINCT + col0 - - ( col2 ) FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT - 73 + + cor0.col2 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
-16
-19
23

query I rowsort
SELECT ( + 16 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT cor0.col2 * + ( + col1 * - col0 ) AS col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT col1 + + 74 * + 63 FROM tab1 AS cor0
----
4672
4675
4688

onlyif mysql # use DIV operator for integer division
query I rowsort label-1766
SELECT + col1 - 49 DIV - col1 FROM tab2 AS cor0
----
19
32
59

skipif mysql # not compatible
query I rowsort label-1766
SELECT + col1 - 49 / - col1 FROM tab2 AS cor0
----
19
32
59

query I rowsort
SELECT DISTINCT + col1 * + 21 FROM tab0
----
1806
1911
2037

query I rowsort
SELECT ALL - 25 + + cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 3b202344844d385030ca34883ee5e6ae

query I rowsort
SELECT ALL cor0.col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + 71 * cor0.col2 AS col0 FROM tab0 AS cor0
----
2343
5822
71

query I rowsort
SELECT 86 * + col1 AS col0 FROM tab1 AS cor0
----
1118
2236
860

query I rowsort
SELECT DISTINCT + 16 + + cor0.col0 FROM tab0 AS cor0
----
105
40
51

query I rowsort
SELECT ALL col1 - - col2 FROM tab0 cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1774
SELECT ALL - - col0 DIV col0 + - col0 * + cor0.col1 + col2 FROM tab2 AS cor0
----
-1304
-189
-4575

skipif mysql # not compatible
query I rowsort label-1774
SELECT ALL - - col0 / col0 + - col0 * + cor0.col1 + col2 FROM tab2 AS cor0
----
-1304
-189
-4575

query I rowsort
SELECT DISTINCT - - col0 * - cor0.col2 - + 96 * ( - col1 ) AS col0 FROM tab2 AS cor0
----
-1370
2787
3636

query I rowsort
SELECT ALL col0 * col1 + col1 * col2 AS col0 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT cor0.col2 * ( ( cor0.col1 ) ) FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-1778
SELECT DISTINCT cor0.col1 + + 36 DIV - cor0.col2 FROM tab0 AS cor0
----
61
85
91

skipif mysql # not compatible
query I rowsort label-1778
SELECT DISTINCT cor0.col1 + + 36 / - cor0.col2 FROM tab0 AS cor0
----
61
85
91

query I rowsort
SELECT DISTINCT col2 * col0 + 52 * + cor0.col0 FROM tab2 AS cor0
----
553
6084
7110

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - + col2 col0 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1781
SELECT ALL - + col1 DIV col1 + 21 FROM tab2 AS cor0
----
20
20
20

skipif mysql # not compatible
query I rowsort label-1781
SELECT ALL - + col1 / col1 + 21 FROM tab2 AS cor0
----
20
20
20

query I rowsort
SELECT DISTINCT + + cor0.col2 * + col2 + cor0.col1 * col2 AS col0 FROM tab0 cor0
----
14186
3927
98

query I rowsort
SELECT - - col0 - 93 * - col0 AS col0 FROM tab0 AS cor0
----
2256
3290
8366

query I rowsort
SELECT DISTINCT + cor0.col2 + - 35 AS col2 FROM tab2 AS cor0
----
-8
-9
3

query I rowsort
SELECT ALL col1 * col0 - - col0 * col0 FROM tab0 AS cor0
----
16020
2640
4620

query I rowsort
SELECT + col1 * 37 AS col1 FROM tab0 AS cor0
----
3182
3367
3589

query I rowsort
SELECT ALL + + col1 * ( col0 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - col2 * col1 + + col2 * + ( + col2 ) FROM tab2 AS cor0
----
-108
-858
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-1789
SELECT - + cor0.col0 DIV - 79 col1 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1789
SELECT - + cor0.col0 / - 79 col1 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT - + 66 * + col1 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-19074
-229746
-63426

query I rowsort
SELECT + - 63 + col0 AS col1 FROM tab2 cor0
----
-56
15
16

query I rowsort
SELECT + ( cor0.col1 ) + col2 * + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL - col0 * 61 FROM tab2
----
-427
-4758
-4819

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 57 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1795
SELECT - 15 DIV + ( - cor0.col0 ) AS col2 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-1795
SELECT - 15 / + ( - cor0.col0 ) AS col2 FROM tab2 AS cor0
----
0
0
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1796
SELECT DISTINCT + CAST( NULL AS SIGNED ) + cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1796
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col2 * - col1 * col0 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT - 66 * + col2 AS col1 FROM tab1 AS cor0
----
-3564
-3762
-6336

query I rowsort
SELECT ALL 51 * 47 FROM tab1 AS cor0
----
2397
2397
2397

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col2 col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT ALL + col0 * col0 + 79 * + 98 * - cor0.col1 FROM tab0 AS cor0
----
-665236
-696601
-749749

query I rowsort
SELECT - - col2 * col2 * - col1 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL + col0 * col1 * col0 AS col1 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT ALL + ( - col0 ) * + col2 + - col2 FROM tab0 cor0
----
-36
-7380
-825

onlyif mysql # use DIV operator for integer division
query I rowsort label-1805
SELECT ALL + - ( - col2 ) DIV col1 AS col0 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-1805
SELECT ALL + - ( - col2 ) / col1 AS col0 FROM tab1 AS cor0
----
2
5
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1806
SELECT DISTINCT + CAST( 16 AS SIGNED ) + + col2 * CAST( col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
178
3664
7696

skipif mysql # not compatible
query I rowsort label-1806
SELECT DISTINCT + CAST ( 16 AS INTEGER ) + + col2 * CAST ( col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
178
3664
7696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1807
SELECT DISTINCT - CAST( 54 AS SIGNED ) + col0 AS col1 FROM tab2 AS cor0
----
-47
24
25

skipif mysql # not compatible
query I rowsort label-1807
SELECT DISTINCT - CAST ( 54 AS INTEGER ) + col0 AS col1 FROM tab2 AS cor0
----
-47
24
25

query I rowsort
SELECT ALL - ( + 67 ) + + col2 FROM tab2 cor0
----
-29
-40
-41

query I rowsort
SELECT ALL + col2 * - 55 * - col1 AS col1 FROM tab2
----
35530
46035
84370

query I rowsort
SELECT ALL + - col1 * + 17 AS col2 FROM tab0 AS cor0
----
-1462
-1547
-1649

query I rowsort
SELECT ALL + + 64 * - col1 AS col2 FROM tab2 AS cor0
----
-1088
-1984
-3776

query I rowsort
SELECT DISTINCT + + 24 AS col0 FROM tab1 AS cor0
----
24

query I rowsort
SELECT - cor0.col0 + + col1 * + col0 FROM tab2 cor0
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1814
SELECT + CAST( col2 AS SIGNED ) * + col1 col0 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1814
SELECT + CAST ( col2 AS INTEGER ) * + col1 col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col1 + - 79 FROM tab0 AS cor0
----
-165
-170
-176

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col1 ) * + col0 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL col0 * - 77 * col1 AS col0 FROM tab2 cor0
----
-103411
-16709
-354354

query I rowsort
SELECT DISTINCT - - col2 * - col1 + col2 + - col0 AS col2 FROM tab0 AS cor0
----
-131
-2829
-7469

onlyif mysql # use DIV operator for integer division
query I rowsort label-1819
SELECT DISTINCT + tab0.col0 + 38 DIV - 38 col2 FROM tab0, tab0 AS cor0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1819
SELECT DISTINCT + tab0.col0 + 38 / - 38 col2 FROM tab0, tab0 AS cor0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col1 + 45 col2 FROM tab2 AS cor0
----
1579
691
882

query I rowsort
SELECT + + 45 * 74 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5c669028ba85d02fed28b1fb2c87a471

query I rowsort
SELECT ALL + - 69 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1823
SELECT DISTINCT + col0 DIV col1 + 97 FROM tab0 AS cor0
----
97

skipif mysql # not compatible
query I rowsort label-1823
SELECT DISTINCT + col0 / col1 + 97 FROM tab0 AS cor0
----
97

query I rowsort
SELECT - + 97 * cor0.col1 + - col1 * - col0 FROM tab2 AS cor0
----
-1121
-2790
-306

query I rowsort
SELECT DISTINCT - col1 + + col2 AS col0 FROM tab0 cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1826
SELECT DISTINCT + col1 DIV col0 + cor0.col2 * col1 AS col2 FROM tab2 AS cor0
----
1534
646
841

skipif mysql # not compatible
query I rowsort label-1826
SELECT DISTINCT + col1 / col0 + cor0.col2 * col1 AS col2 FROM tab2 AS cor0
----
1534
646
841

onlyif mysql # use DIV operator for integer division
query I rowsort label-1827
SELECT ALL + + col1 DIV cor0.col1 + cor0.col0 * col2 * - cor0.col2 - col0 AS col2 FROM tab1 AS cor0
----
-207999
-737359
-8750

skipif mysql # not compatible
query I rowsort label-1827
SELECT ALL + + col1 / cor0.col1 + cor0.col0 * col2 * - cor0.col2 - col0 AS col2 FROM tab1 AS cor0
----
-207999
-737359
-8750

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1828
SELECT DISTINCT - col2 + col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1828
SELECT DISTINCT - col2 + col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 ) col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT - col2 * cor0.col0 + + col1 AS col2 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + + 86 + cor0.col0 * - cor0.col0 FROM tab1 AS cor0
----
-4010
-6314
77

query I rowsort
SELECT DISTINCT - - 5 AS col2 FROM tab1 AS cor0
----
5

query I rowsort
SELECT ALL + + cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1834
SELECT ALL + col1 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1834
SELECT ALL + col1 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1835
SELECT DISTINCT col1 + + CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-1835
SELECT DISTINCT col1 + + CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - - col2 * - ( cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - cor0.col2 * ( - 77 ) * - cor0.col0 FROM tab2 AS cor0
----
-14553
-156156
-231154

query I rowsort
SELECT ALL cor0.col0 * ( ( - col0 ) ) + col2 AS col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 + - 37 AS col2 FROM tab1 AS cor0
----
1211
1367
533

onlyif mysql # use DIV operator for integer division
query I rowsort label-1840
SELECT DISTINCT + + col2 - cor0.col1 * 64 DIV - cor0.col0 AS col0 FROM tab0 cor0
----
147
178
262

skipif mysql # not compatible
query I rowsort label-1840
SELECT DISTINCT + + col2 - cor0.col1 * 64 / - cor0.col0 AS col0 FROM tab0 cor0
----
147
178
262

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1841
SELECT ALL - col1 * - CAST( NULL AS SIGNED ) + - col2 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1841
SELECT ALL - col1 * - CAST ( NULL AS INTEGER ) + - col2 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * cor0.col1 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - - cor0.col1 * + 83 AS col1 FROM tab2 AS cor0
----
1411
2573
4897

query I rowsort
SELECT + col1 * + 20 + col2 AS col2 FROM tab0 AS cor0
----
1753
1902
1941

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1845
SELECT - - col0 + + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1845
SELECT - - col0 + + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 + + 58 AS col0 FROM tab0 AS cor0
----
144
149
155

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1847
SELECT + + col1 * CAST( cor0.col1 AS SIGNED ) col0 FROM tab2 AS cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1847
SELECT + + col1 * CAST ( cor0.col1 AS INTEGER ) col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - col1 * col1 + + col2 AS col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT + 55 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col0 ) col1 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 95 * 65 col2 FROM tab1 AS cor0
----
6175
6175
6175

query I rowsort
SELECT DISTINCT - cor1.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - col0 * 9 FROM tab0
----
-216
-315
-801

query I rowsort
SELECT + 84 + + col2 FROM tab2 AS cor0
----
110
111
122

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col2 * + col0 * + 71 col0 FROM tab1 AS cor0
----
-11502
-259008
-545280

query I rowsort
SELECT - ( 13 ) AS col0 FROM tab1
----
-13
-13
-13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 98 col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

onlyif mysql # use DIV operator for integer division
query I rowsort label-1858
SELECT ALL - 78 * col0 DIV 45 FROM tab1
----
-110
-138
-5

skipif mysql # not compatible
query I rowsort label-1858
SELECT ALL - 78 * col0 / 45 FROM tab1
----
-110
-138
-5

query I rowsort
SELECT + ( + col0 ) * + col0 * 41 + + col1 FROM tab0
----
23702
324852
50322

query I rowsort
SELECT DISTINCT - 30 + - col2 AS col1 FROM tab0
----
-112
-31
-63

query I rowsort
SELECT DISTINCT - col0 * + col0 + 0 AS col1 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT 66 + col1 FROM tab0
----
152
157
163

query I rowsort
SELECT - col1 * + col0 + 63 FROM tab0 AS cor0
----
-2001
-3332
-8036

query I rowsort
SELECT DISTINCT - 50 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-1865
SELECT DISTINCT + 41 + col2 * - 75 DIV 75 FROM tab1 AS cor0
----
-13
-16
-55

skipif mysql # not compatible
query I rowsort label-1865
SELECT DISTINCT + 41 + col2 * - 75 / 75 FROM tab1 AS cor0
----
-13
-16
-55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1866
SELECT + CAST( NULL AS SIGNED ) * cor0.col0 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1866
SELECT + CAST ( NULL AS INTEGER ) * cor0.col0 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 67 * 84 + col2 AS col1 FROM tab0 cor0
----
5629
5661
5710

query I rowsort
SELECT + 4 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + 34 * - 61 AS col2 FROM tab1 cor0
----
-2074
-2074
-2074

query I rowsort
SELECT ALL + 11 FROM tab0, tab1 cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 36 + col1 col1 FROM tab2 AS cor0
----
53
67
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1872
SELECT DISTINCT - ( 21 ) + col2 * CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1872
SELECT DISTINCT - ( 21 ) + col2 * CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT - - 80 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
80

query I rowsort
SELECT ALL col1 * + 16 * - col1 FROM tab2
----
-15376
-4624
-55696

query I rowsort
SELECT + 13 * cor0.col0 + col2 FROM tab2 cor0
----
1040
1065
118

query I rowsort
SELECT - col0 * tab1.col0 * - tab1.col2 AS col1 FROM tab1
----
233472
486
614400

query I rowsort
SELECT 27 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1878
SELECT ALL CAST( NULL AS DECIMAL ) * 25 col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1878
SELECT ALL CAST ( NULL AS REAL ) * 25 col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - 28 AS col0 FROM tab2, tab0 cor0, tab2 cor1
----
27 values hashing to eac00a95d734c7071360ed392c3f39bc

query I rowsort
SELECT - 84 * col0 AS col0 FROM tab2
----
-588
-6552
-6636

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - tab1.col0 * tab1.col0 ) col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 4829ede06f586935ff95a5b0dfdb9199

query I rowsort
SELECT ALL 54 - 42 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab1 cor1, tab0 AS cor2
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1884
SELECT - - col1 * - CAST( 42 * col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-28392
-4200
-7098

skipif mysql # not compatible
query I rowsort label-1884
SELECT - - col1 * - CAST ( 42 * col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-28392
-4200
-7098

query I rowsort
SELECT + - cor0.col2 * + col2 + - col2 * cor0.col2 AS col1 FROM tab1 cor0
----
-18432
-5832
-6498

onlyif mysql # use DIV operator for integer division
query I rowsort label-1886
SELECT + col2 + col1 DIV col0 FROM tab0 cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-1886
SELECT + col2 + col1 / col0 FROM tab0 cor0
----
3
36
83

query I rowsort
SELECT + col1 * + 45 FROM tab2 AS cor0
----
1395
2655
765

onlyif mysql # use DIV operator for integer division
query I rowsort label-1888
SELECT + col0 DIV col0 + tab1.col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1888
SELECT + col0 / col0 + tab1.col2 FROM tab1
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col2 col0 FROM tab2
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-1890
SELECT ALL col1 DIV + col1 + - col1 DIV + col0 AS col0 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-1890
SELECT ALL col1 / + col1 + - col1 / + col0 AS col0 FROM tab0
----
-1
-2
0

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab0, tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 + - col0 * - col2 col1 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT + - col2 + + 0 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - - ( col0 ) AS col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL - col0 * - ( + cor0.col0 ) FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-1896
SELECT DISTINCT 59 * + col1 - col2 DIV cor0.col1 col0 FROM tab0 cor0
----
5074
5369
5723

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1896
SELECT DISTINCT 59 * + col1 - col2 / cor0.col1 col0 FROM tab0 cor0
----
5074
5369
5723

query I rowsort
SELECT DISTINCT + 7 * + col0 * + col2 - 17 AS col2 FROM tab2 AS cor0
----
1306
14179
20997

query I rowsort
SELECT - col1 * col0 + col1 AS col0 FROM tab1
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-1899
SELECT DISTINCT - ( - col1 ) DIV col1 + col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-1899
SELECT DISTINCT - ( - col1 ) / col1 + col2 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL - col2 * + cor0.col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + 27 + cor0.col1 AS col2 FROM tab0 AS cor0
----
113
118
124

query I rowsort
SELECT DISTINCT ( - col1 ) * + col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-1903
SELECT ALL CAST( col2 AS SIGNED ) DIV col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1903
SELECT ALL CAST ( col2 AS INTEGER ) / col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL 46 * + col2 FROM tab1 AS cor0
----
2484
2622
4416

query I rowsort
SELECT ALL - col0 + cor0.col0 * col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT + + 89 + + col0 * col0 - col2 AS col0 FROM tab2 AS cor0
----
111
6147
6292

query I rowsort
SELECT + - ( + col1 ) - + col2 * - col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT ALL + 9 * - col0 - + col0 FROM tab2
----
-70
-780
-790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1909
SELECT + 37 * col0 - + CAST( - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
165
2425
3056

skipif mysql # not compatible
query I rowsort label-1909
SELECT + 37 * col0 - + CAST ( - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
165
2425
3056

query I rowsort
SELECT - - col2 * - col0 + - ( + cor0.col2 ) FROM tab2 cor0
----
-2054
-216
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * col0 + - col2 * 29 col2 FROM tab1 AS cor0
----
-1575
-5749
-9184

query I rowsort
SELECT ( col2 ) + col0 AS col1 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-1913
SELECT DISTINCT col2 + col2 DIV - cor0.col0 AS col2 FROM tab0 cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-1913
SELECT DISTINCT col2 + col2 / - cor0.col0 AS col2 FROM tab0 cor0
----
1
32
82

query I rowsort
SELECT col2 + col0 + + col1 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT - + 6 + col1 AS col1 FROM tab2 AS cor0
----
11
25
53

query I rowsort
SELECT col1 - col2 * - col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT + col2 * + 85 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT ALL + col2 * - 30 AS col1 FROM tab2 AS cor0
----
-1140
-780
-810

query I rowsort
SELECT DISTINCT cor0.col2 * 87 + - cor0.col0 FROM tab2 AS cor0
----
2184
2342
3227

onlyif mysql # use DIV operator for integer division
query I rowsort label-1920
SELECT 54 + + col1 DIV + col2 FROM tab0 AS cor0
----
151
55
56

skipif mysql # not compatible
query I rowsort label-1920
SELECT 54 + + col1 / + col2 FROM tab0 AS cor0
----
151
55
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-1921
SELECT col0 DIV - col1 + 59 * - col0 * + col1 AS col2 FROM tab1 AS cor0
----
-37766
-4602
-61366

skipif mysql # not compatible
query I rowsort label-1921
SELECT col0 / - col1 + 59 * - col0 * + col1 AS col2 FROM tab1 AS cor0
----
-37766
-4602
-61366

query I rowsort
SELECT - col2 * - col1 + + ( - col0 ) * - col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT ALL - + ( - col2 ) + + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col1 + col0 * - 79 AS col1 FROM tab2 AS cor0
----
-522
-6103
-6224

query I rowsort
SELECT - col2 + cor0.col2 + + col0 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT col0 * ( + col0 ) + tab0.col1 * + 46 AS col1 FROM tab0
----
12107
4532
5687

query I rowsort
SELECT - col1 * ( + col1 + + ( 66 ) ) FROM tab1
----
-1027
-2392
-760

query I rowsort
SELECT + tab1.col0 + col2 AS col0 FROM tab1
----
121
176
57

query I rowsort
SELECT col0 * 76 AS col0 FROM tab0
----
1824
2660
6764

query I rowsort
SELECT col2 * 93 + col2 * 60 + - col1 FROM tab2
----
3919
4100
5797

query I rowsort
SELECT DISTINCT + 27 + col1 * col2 FROM tab2
----
1561
673
864

query I rowsort
SELECT ALL 46 * + col1 AS col0 FROM tab2 AS cor0
----
1426
2714
782

query I rowsort
SELECT ALL - + col1 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + ( col1 ) * col0 * 45 AS col1 FROM tab1 AS cor0
----
28800
3510
46800

query I rowsort
SELECT 32 * - cor0.col0 AS col2 FROM tab2 cor0
----
-224
-2496
-2528

query I rowsort
SELECT ALL - 31 * + col1 AS col2 FROM tab1 AS cor0
----
-310
-403
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-1937
SELECT + 27 DIV 52 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-1937
SELECT + 27 / 52 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + 84 col1 FROM tab2
----
-2184
-2268
-3192

query I rowsort
SELECT col1 * col2 * + 99 + - cor0.col2 * 97 FROM tab0 AS cor0
----
277761
730784
9506

query I rowsort
SELECT - cor0.col2 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT ALL - - col1 + ( col1 ) FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - col1 * - 16 - col2 FROM tab1 AS cor0
----
103
112
362

query I rowsort
SELECT ALL - col0 + - 61 AS col1 FROM tab1 AS cor0
----
-125
-141
-64

query I rowsort
SELECT DISTINCT ( col1 ) * col2 + + tab2.col2 FROM tab2
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1945
SELECT DISTINCT CAST( NULL AS SIGNED ) / col0 + col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1945
SELECT DISTINCT CAST ( NULL AS INTEGER ) / col0 + col0 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col0 * + cor0.col0 + col0 FROM tab1 AS cor0
----
12
4160
6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1947
SELECT ALL CAST( NULL AS SIGNED ) + - cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1947
SELECT ALL CAST ( NULL AS INTEGER ) + - cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + col2 ) + - col1 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + ( col0 ) * + tab2.col0 + col0 + + col1 AS col1 FROM tab2
----
6221
6337
87

query I rowsort
SELECT ALL - col0 - col0 * col2 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT + col1 - + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + 89 + col0 * - col2 FROM tab2 AS cor0
----
-100
-1939
-2913

query I rowsort
SELECT + 15 + ( col2 ) * + 9 FROM tab0 AS cor0
----
24
312
753

query I rowsort
SELECT DISTINCT + 69 + - col1 FROM tab2 AS cor0
----
10
38
52

query I rowsort
SELECT DISTINCT - 55 * + cor0.col2 + + col0 * - 45 * cor0.col0 FROM tab0 AS cor0
----
-27735
-360955
-55180

query I rowsort
SELECT - 29 * + 0 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + 64 * col0 + - ( col1 ) * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1302
-1766
2143

query I rowsort
SELECT + 69 + - col0 FROM tab1 AS cor0
----
-11
5
66

query I rowsort
SELECT + - 19 + col2 FROM tab2 cor0
----
19
7
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 82 * col2 col1 FROM tab0 AS cor0
----
2706
6724
82

query I rowsort
SELECT DISTINCT tab0.col0 + + tab0.col1 * 17 FROM tab0, tab1 AS cor0
----
1486
1636
1684

query I rowsort
SELECT DISTINCT - col1 * - ( col0 ) + - cor0.col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT + + cor0.col1 * - cor0.col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - - col2 * col2 + col1 FROM tab1 AS cor0
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * + col0 col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + col1 - 17 * - col2 FROM tab0 AS cor0
----
114
1485
647

query I rowsort
SELECT - - ( - 17 ) FROM tab2 cor0
----
-17
-17
-17

query I rowsort
SELECT ALL 23 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query I rowsort
SELECT col0 + 23 AS col2 FROM tab0
----
112
47
58

query I rowsort
SELECT + ( - cor0.col2 ) + + cor0.col0 AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT 74 + cor0.col1 AS col1 FROM tab0 AS cor0
----
160
165
171

query I rowsort
SELECT - 96 + + col0 * col0 FROM tab1 AS cor0
----
-87
4000
6304

onlyif mysql # use DIV operator for integer division
query I rowsort label-1973
SELECT ALL col0 + col1 DIV col2 + - col2 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-1973
SELECT ALL col0 + col1 / col2 + - col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL - col0 * col0 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT ALL - col0 + col2 * col2 AS col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT DISTINCT col0 - col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT + + 65 + + col2 * col1 FROM tab2 AS cor0
----
1599
711
902

query I rowsort
SELECT ALL - col0 + 72 FROM tab2
----
-6
-7
65

query I rowsort
SELECT cor0.col2 * - col0 + - col1 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL col0 * tab1.col1 * col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT ALL - 14 - col1 * col2 AS col2 FROM tab2 AS cor0
----
-1548
-660
-851

query I rowsort
SELECT ALL - 15 * col1 FROM tab2 cor0
----
-255
-465
-885

onlyif mysql # use DIV operator for integer division
query I rowsort label-1983
SELECT DISTINCT + col2 DIV col1 + col2 * col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-1983
SELECT DISTINCT + col2 / col1 + col2 * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + col2 * - col2 * col0 AS col1 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT - col2 * 94 - col2 * col0 AS col0 FROM tab0
----
-129
-15006
-3894

query I rowsort
SELECT DISTINCT 6 + - 64 FROM tab1
----
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-1987
SELECT DISTINCT + col0 DIV 17 + - col0 FROM tab2
----
-7
-74
-75

skipif mysql # not compatible
query I rowsort label-1987
SELECT DISTINCT + col0 / 17 + - col0 FROM tab2
----
-7
-74
-75

query I rowsort
SELECT ALL + ( - col2 ) * col2 * col1 AS col2 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT + ( + tab2.col0 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT - ( 69 ) AS col0 FROM tab2
----
-69

query I rowsort
SELECT ALL + col0 * + col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT DISTINCT + col2 - tab1.col0 * tab1.col2 FROM tab1
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-1993
SELECT tab1.col2 DIV col2 + col0 - tab1.col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1993
SELECT tab1.col2 / col2 + col0 - tab1.col0 FROM tab1
----
1
1
1

query I rowsort
SELECT - col1 + + col2 - col0 * col1 AS col1 FROM tab0
----
-2117
-3491
-8108

query I rowsort
SELECT ALL col0 - - col0 * tab1.col1 * col2 FROM tab1
----
36544
4215
99920

query I rowsort
SELECT DISTINCT - col2 - col1 * - col0 FROM tab0
----
2031
3394
8017

query III rowsort
SELECT * FROM tab1 WHERE ( col0 * - col0 + col2 ) BETWEEN NULL AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col2 col0 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT ALL + tab0.col0 - + col1 FROM tab0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2000
SELECT ALL col0 DIV + cor0.col2 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2000
SELECT ALL col0 / + cor0.col2 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT - col1 * + tab0.col1 AS col2 FROM tab0
----
-7396
-8281
-9409

query III rowsort
SELECT * FROM tab0 WHERE NULL IN ( + col1 - + col0 * tab0.col0 )
----

query I rowsort
SELECT DISTINCT - col0 * col0 * col2 AS col1 FROM tab1
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col2 + - cor0.col1 + col1 col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT col2 + col0 * + col2 + col1 AS col1 FROM tab1 AS cor0
----
242
3715
7789

query I rowsort
SELECT col1 * cor0.col1 + col2 * + col2 AS col0 FROM tab1 cor0
----
3349
3592
9385

query I rowsort
SELECT ALL col2 + - col0 + tab2.col2 FROM tab2
----
-26
-3
47

query I rowsort
SELECT ALL - col2 + col1 + - col1 * tab2.col1 FROM tab2
----
-310
-3448
-957

query I rowsort
SELECT DISTINCT + cor0.col1 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT cor0.col1 + cor0.col1 - + cor0.col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT + col1 + + col1 - col1 * col1 FROM tab2 AS cor0
----
-255
-3363
-899

query I rowsort
SELECT DISTINCT col0 + + col0 * col2 AS col2 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-2013
SELECT + - col0 DIV col1 - col0 AS col2 FROM tab2 AS cor0
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-2013
SELECT + - col0 / col1 - col0 AS col2 FROM tab2 AS cor0
----
-7
-79
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2014
SELECT DISTINCT + + col2 + col0 DIV + cor0.col1 FROM tab2 AS cor0
----
27
42

skipif mysql # not compatible
query I rowsort label-2014
SELECT DISTINCT + + col2 + col0 / + cor0.col1 FROM tab2 AS cor0
----
27
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-2015
SELECT + col0 - + col1 DIV col1 AS col2 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-2015
SELECT + col0 - + col1 / col1 AS col2 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT DISTINCT + col0 - ( + col2 * + col1 + - ( col0 ) * col1 ) FROM tab0 AS cor0
----
-750
3333
726

onlyif mysql # use DIV operator for integer division
query I rowsort label-2017
SELECT + col2 DIV - 12 FROM tab1
----
-4
-4
-8

skipif mysql # not compatible
query I rowsort label-2017
SELECT + col2 / - 12 FROM tab1
----
-4
-4
-8

query I rowsort
SELECT - cor0.col2 * - 91 FROM tab1 AS cor0
----
4914
5187
8736

query I rowsort
SELECT DISTINCT col0 * 94 FROM tab1 AS cor0
----
282
6016
7520

query I rowsort
SELECT - - cor0.col1 + + 58 AS col2 FROM tab1 AS cor0
----
68
71
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2021
SELECT + CAST( col1 AS SIGNED ) * col2 + + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

skipif mysql # not compatible
query I rowsort label-2021
SELECT + CAST ( col1 AS INTEGER ) * col2 + + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + - ( col0 ) * col0 + ( - 54 ) FROM tab0 AS cor0
----
-1279
-630
-7975

query I rowsort
SELECT col2 * 42 + + col0 * - ( col2 ) AS col0 FROM tab1 AS cor0
----
-1254
-3648
2106

query I rowsort
SELECT DISTINCT + tab0.col1 * + tab0.col0 * - tab0.col2 + tab0.col2 FROM tab0
----
-3394
-664036
-68079

query I rowsort
SELECT col1 + - 54 + col2 FROM tab1
----
13
26
55

query I rowsort
SELECT col0 + 70 AS col0 FROM tab2
----
148
149
77

query I rowsort
SELECT DISTINCT + col2 + 64 + + col1 FROM tab2
----
119
122
149

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 * + col1 col1 FROM tab0 cor0
----
118825
49536
720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col2 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - 15 + - col0 AS col2 FROM tab1 AS cor0
----
-18
-79
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2031
SELECT ALL ( + col0 ) + col1 DIV + col2 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-2031
SELECT ALL ( + col0 ) + col1 / + col2 FROM tab0 AS cor0
----
132
26
90

query I rowsort
SELECT DISTINCT + 85 * + col2 AS col2 FROM tab0 AS cor0
----
2805
6970
85

query I rowsort
SELECT ALL + 92 * cor0.col2 FROM tab0 AS cor0
----
3036
7544
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col0 * col0 col1 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT DISTINCT ( col1 ) * - col0 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT + - 39 AS col2 FROM tab2 AS cor0
----
-39
-39
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-2037
SELECT CAST( - col0 AS SIGNED ) - - col1 DIV ( 74 * col2 + + 53 ) FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2037
SELECT CAST ( - col0 AS INTEGER ) - - col1 / ( 74 * col2 + + 53 ) FROM tab1
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2038
SELECT DISTINCT 69 DIV - tab0.col1 AS col2 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-2038
SELECT DISTINCT 69 / - tab0.col1 AS col2 FROM tab0
----
0

query I rowsort
SELECT DISTINCT - 21 * + col1 AS col1 FROM tab1
----
-210
-273
-546

query I rowsort
SELECT ( col1 ) * ( col2 * + col0 ) FROM tab0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2041
SELECT - CAST( NULL AS SIGNED ) * cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2041
SELECT - CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - + col0 + - cor0.col2 * col0 * + 35 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-1295
-255608
-27768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * col1 - - col0 col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT tab0.col0 AS col1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col1 * col1 * + col1 AS col0 FROM tab2
----
205379
29791
4913

query I rowsort
SELECT - + col0 * col0 AS col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT - col1 * + col0 * - col0 AS col2 FROM tab1 cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT - ( + col2 * ( + col0 ) ) AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT 99 FROM tab1, tab0, tab1 cor0
----
99

query I rowsort
SELECT ( + col2 + + ( - 81 ) * - col1 ) FROM tab1
----
1149
2160
867

query I rowsort
SELECT + col2 * col2 * col1 FROM tab1
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2052
SELECT tab0.col2 * col0 DIV col2 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2052
SELECT tab0.col2 * col0 / col2 FROM tab0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2053
SELECT + col0 * CAST( col0 AS SIGNED ) AS col1 FROM tab2
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-2053
SELECT + col0 * CAST ( col0 AS INTEGER ) AS col1 FROM tab2
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2054
SELECT ALL + CAST( 53 AS SIGNED ) * cor0.col2 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 54bc9cd654df586cce96f5e2b7733b13

skipif mysql # not compatible
query I rowsort label-2054
SELECT ALL + CAST ( 53 AS INTEGER ) * cor0.col2 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 54bc9cd654df586cce96f5e2b7733b13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2055
SELECT - + col0 * CAST( + col1 * - col0 AS SIGNED ) - - col1 * col2 FROM tab2 AS cor0
----
106743
2356
360490

skipif mysql # not compatible
query I rowsort label-2055
SELECT - + col0 * CAST ( + col1 * - col0 AS INTEGER ) - - col1 * col2 FROM tab2 AS cor0
----
106743
2356
360490

query I rowsort
SELECT col0 * + 48 AS col0 FROM tab1 AS cor0
----
144
3072
3840

query I rowsort
SELECT - col0 - ( ( - col0 ) ) AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2058
SELECT + + col2 + + col1 * - col2 + col2 DIV - col1 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif mysql # not compatible
query I rowsort label-2058
SELECT + + col2 + + col1 * - col2 + col2 / - col1 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT col0 * ( col0 ) - + col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT ( + 72 ) FROM tab2
----
72
72
72

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 + col1 * 27 AS col2 FROM tab1 AS cor0
----
-370
-689
624

query I rowsort
SELECT ALL ( - col2 ) + col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - ( col2 ) * cor0.col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + 25 + - col1 FROM tab2 AS cor0
----
-34
-6
8

query I rowsort
SELECT ALL - 87 * col0 - cor0.col2 AS col0 FROM tab2 AS cor0
----
-636
-6812
-6911

query I rowsort
SELECT DISTINCT - + ( col0 ) + + cor0.col2 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + cor1.col1 - - 55 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 70d0bccb2d55c423358c1381a3225405

query I rowsort
SELECT DISTINCT + col1 * - col1 * + ( - col2 ) AS col1 FROM tab0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2069
SELECT ALL tab1.col1 DIV + col0 col0 FROM tab1
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2069
SELECT ALL tab1.col1 / + col0 col0 FROM tab1
----
0
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2070
SELECT DISTINCT + - 81 DIV col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-2070
SELECT DISTINCT + - 81 / col2 FROM tab1 AS cor0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2071
SELECT - 62 DIV col1 col1 FROM tab1 AS cor0
----
-2
-4
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2071
SELECT - 62 / col1 col1 FROM tab1 AS cor0
----
-2
-4
-6

query I rowsort
SELECT - 53 + col1 AS col1 FROM tab1 AS cor0
----
-27
-40
-43

query I rowsort
SELECT + col0 * - col0 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT DISTINCT + 33 AS col0 FROM tab2
----
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 96 col1 FROM tab0 AS cor0
----
-2304
-3360
-8544

query I rowsort
SELECT DISTINCT - 23 AS col0 FROM tab1, tab2 AS cor0 CROSS JOIN tab2
----
-23

query I rowsort
SELECT + + col0 * col0 * - cor0.col2 + 11 + - col0 FROM tab1 AS cor0
----
-233525
-478
-614469

query I rowsort
SELECT DISTINCT + col0 + col0 * 28 FROM tab1 AS cor0
----
1856
2320
87

query I rowsort
SELECT col0 * - col0 * + tab1.col0 AS col1 FROM tab1
----
-262144
-27
-512000

query I rowsort
SELECT ALL tab1.col0 AS col2 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2081
SELECT ALL - col1 * - CAST( - col2 AS SIGNED ) AS col0 FROM tab0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-2081
SELECT ALL - col1 * - CAST ( - col2 AS INTEGER ) AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - col0 * col2 - - cor0.col1 * + col0 AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT - col2 * + ( + col0 ) * col0 + + col0 * col2 AS col0 FROM tab0 AS cor0
----
-1190
-18216
-642224

query I rowsort
SELECT DISTINCT - - ( col0 ) + - col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT tab2.col1 + tab2.col2 FROM tab2, tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - + tab1.col2 AS col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT DISTINCT - tab2.col0 * + tab2.col2 AS col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT 46 * 5 + + tab0.col1 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 3435c724610ae44ab217cb7932895b1b

query I rowsort
SELECT DISTINCT + cor1.col2 + 43 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
69
70
81

query I rowsort
SELECT DISTINCT - ( + cor1.col2 + + cor0.col1 ) AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab0 AS cor2
----
-113
-116
-127
-155
-71
-74
-85
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2091
SELECT ALL - cor1.col2 * + CAST( NULL AS SIGNED ) * 11 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 76933ee8cce600e48802fbdea2376d45

skipif mysql # not compatible
query I rowsort label-2091
SELECT ALL - cor1.col2 * + CAST ( NULL AS INTEGER ) * 11 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 76933ee8cce600e48802fbdea2376d45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 6 * col1 + col2 col1 FROM tab0 AS cor0
----
-464
-483
-581

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2093
SELECT DISTINCT + CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2093
SELECT DISTINCT + CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - + col1 + 38 FROM tab2 AS cor0
----
-21
21
7

query I rowsort
SELECT ALL - col0 * + 99 FROM tab2 cor0
----
-693
-7722
-7821

query I rowsort
SELECT ALL + ( + 13 ) + - col1 AS col1 FROM tab0 AS cor0
----
-73
-78
-84

query I rowsort
SELECT - - cor0.col1 * + 99 FROM tab2 AS cor0
----
1683
3069
5841

query I rowsort
SELECT ALL - - col2 * col2 - - ( 38 ) FROM tab1 AS cor0
----
2954
3287
9254

query I rowsort
SELECT DISTINCT 28 AS col2 FROM tab2 AS cor0
----
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col2 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 21 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

onlyif mysql # use DIV operator for integer division
query I rowsort label-2102
SELECT - col1 * col0 + - col2 - CAST( + col1 AS SIGNED ) DIV col2 FROM tab0
----
-2099
-3493
-8182

skipif mysql # not compatible
query I rowsort label-2102
SELECT - col1 * col0 + - col2 - CAST ( + col1 AS INTEGER ) / col2 FROM tab0
----
-2099
-3493
-8182

query I rowsort
SELECT ALL 99 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT ALL tab2.col0 - + tab2.col1 * + col0 FROM tab2
----
-1264
-210
-4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2105
SELECT ALL CAST( NULL AS SIGNED ) - col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2105
SELECT ALL CAST ( NULL AS INTEGER ) - col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - 12 col1 FROM tab1
----
-22
-25
-38

query I rowsort
SELECT DISTINCT + col2 * + ( col2 ) * - cor0.col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-2108
SELECT - col2 + - ( 17 ) * - cor0.col1 DIV col1 AS col2 FROM tab2 cor0
----
-10
-21
-9

skipif mysql # not compatible
query I rowsort label-2108
SELECT - col2 + - ( 17 ) * - cor0.col1 / col1 AS col2 FROM tab2 cor0
----
-10
-21
-9

query I rowsort
SELECT DISTINCT - cor0.col2 + col0 * - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT - - col2 * cor0.col2 FROM tab0 cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-2111
SELECT - - col1 DIV + 41 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2111
SELECT - - col1 / + 41 FROM tab2 AS cor0
----
0
0
1

query I rowsort
SELECT ALL + col0 + tab2.col0 AS col2 FROM tab2
----
14
156
158

query I rowsort
SELECT DISTINCT + col0 * + col0 + 34 FROM tab0
----
1259
610
7955

query I rowsort
SELECT cor0.col0 + 17 * tab1.col1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 1c960db68dbb8514047ad38a9901df50

query I rowsort
SELECT - tab1.col0 + col0 + col0 * + col1 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT col0 * - col1 + col1 * col0 FROM tab2
----
0

query I rowsort
SELECT - + cor0.col0 + + col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL ( col0 * 47 ) AS col0 FROM tab2
----
329
3666
3713

query I rowsort
SELECT ALL + + col0 * col2 * - 44 AS col1 FROM tab2 AS cor0
----
-132088
-8316
-89232

query I rowsort
SELECT + col0 + col0 * col2 AS col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT col2 + + cor0.col2 * + col1 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - col1 * + cor0.col2 + - col1 AS col1 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2123
SELECT DISTINCT + col2 + CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2123
SELECT DISTINCT + col2 + CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col2 + 57 * - 67 * - col1 AS col1 FROM tab1 AS cor0
----
38133
49551
99240

onlyif mysql # use DIV operator for integer division
query I rowsort label-2125
SELECT + col1 DIV 12 - col0 AS col2 FROM tab1 AS cor0
----
-1
-64
-79

skipif mysql # not compatible
query I rowsort label-2125
SELECT + col1 / 12 - col0 AS col2 FROM tab1 AS cor0
----
-1
-64
-79

query I rowsort
SELECT DISTINCT col2 * cor0.col2 + - col1 * col2 FROM tab0 AS cor0
----
-1749
-738
-96

query I rowsort
SELECT + col0 - 45 * col1 AS col2 FROM tab2 AS cor0
----
-1388
-2577
-686

query I rowsort
SELECT DISTINCT - col0 + 90 * col2 AS col2 FROM tab1 AS cor0
----
4857
5066
8560

query I rowsort
SELECT - col1 + + ( col1 ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * 94 AS col1 FROM tab1 AS cor0
----
5076
5358
9024

query I rowsort
SELECT ALL col2 * ( cor0.col2 ) FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - - cor0.col1 * col1 + ( col2 ) * - ( - col2 ) FROM tab1 AS cor0
----
3349
3592
9385

query I rowsort
SELECT ALL - 85 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 91e44ead5e72fa22f87a57243e232ede

query I rowsort
SELECT - col1 + + col2 * tab2.col2 FROM tab2
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-2135
SELECT DISTINCT + col2 DIV col2 + col2 AS col0 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-2135
SELECT DISTINCT + col2 / col2 + col2 AS col0 FROM tab1
----
55
58
97

query I rowsort
SELECT ALL + col2 * - col0 + + col0 AS col1 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT ALL - col1 * + col0 + tab1.col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT - col0 FROM tab0 WHERE col0 < NULL
----

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL <= + col2
----

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT IN ( + col2 * col0 * - col2 - - col1 )
----

query I rowsort
SELECT DISTINCT + col0 * col2 * col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT ALL + col0 + + col1 AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT + col0 + + col2 * - col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT + col1 + tab0.col2 * col2 AS col2 FROM tab0
----
1175
6815
98

query I rowsort
SELECT ALL ( 42 ) AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query III rowsort
SELECT * FROM tab0 WHERE NOT + col0 * col0 * col1 NOT IN ( + col1 * - col2 )
----

query I rowsort
SELECT DISTINCT col1 * - tab1.col2 * - col2 + - col1 * - tab1.col0 AS col2 FROM tab1
----
120848
33130
75894

query I rowsort
SELECT - col2 * tab1.col0 AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - 80 * 71 FROM tab0, tab2 AS cor0, tab0 cor1
----
-5680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2150
SELECT DISTINCT + col0 * col0 + ( - 89 ) / cor0.col1 + CAST( NULL AS SIGNED ) * 14 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2150
SELECT DISTINCT + col0 * col0 + ( - 89 ) / cor0.col1 + CAST ( NULL AS INTEGER ) * 14 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - 28 + - col0 AS col1 FROM tab1 cor0
----
-108
-31
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 col1 FROM tab2 WHERE ( col2 ) BETWEEN + col2 AND NULL
----

query I rowsort
SELECT ALL col2 FROM tab1 WHERE + col1 >= col2 + - col0 * - col1
----

query I rowsort
SELECT DISTINCT + col0 - col1 FROM tab0 WHERE NULL NOT IN ( - col1 + col0 - - col1 )
----

query I rowsort
SELECT ALL col0 + - col0 * col2 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT ALL - col0 + - col2 * - col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT 56 * col2 * + col1 AS col0 FROM tab2 cor0
----
36176
46872
85904

query I rowsort
SELECT - col2 * + col1 + 15 AS col0 FROM tab0 AS cor0
----
-2823
-7447
-82

query I rowsort
SELECT col0 * - cor0.col0 * col0 AS col0 FROM tab1 AS cor0
----
-262144
-27
-512000

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 col1 FROM tab1 cor0
----
87
87
87

query I rowsort
SELECT ALL - 72 * - col0 AS col0 FROM tab1
----
216
4608
5760

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab2, tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT + 46 * + col0 AS col2 FROM tab2 AS cor0
----
322
3588
3634

query I rowsort
SELECT DISTINCT - tab1.col2 * + cor0.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 6e831ce95b59398818a720c8e9b6e293

query I rowsort
SELECT - ( cor1.col0 ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to f94a4a64ac54a61fc21f78e2b831ebee

query I rowsort
SELECT ALL + + 31 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT 97 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT + tab1.col1 + cor0.col1 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 2f77cea6077a88e4a9b3780ac7a48644

query I rowsort
SELECT ALL col2 + 50 * col2 AS col0 FROM tab2
----
1326
1377
1938

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0, tab2, tab1 cor1
----
972 values hashing to 92235dbc382d83baa93d6546ed489b0c

query I rowsort
SELECT DISTINCT + tab0.col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
86
91
97

query I rowsort
SELECT - + tab1.col1 AS col1 FROM tab1, tab0, tab1 cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT - 76 * - col0 * col2 FROM tab0 cor0
----
2660
554648
60192

query I rowsort
SELECT DISTINCT + - 98 * tab1.col2 + tab1.col2 AS col0 FROM tab1, tab0, tab1 AS cor0
----
-5238
-5529
-9312

query I rowsort
SELECT ALL ( + 73 ) FROM tab0
----
73
73
73

query I rowsort
SELECT + col2 * col1 * col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT + + 11 * - col0 AS col0 FROM tab2 AS cor0
----
-77
-858
-869

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2179
SELECT + CAST( NULL AS SIGNED ) * col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2179
SELECT + CAST ( NULL AS INTEGER ) * col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( col1 ) + + cor0.col0 * + col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL + + col2 + - ( - col2 ) * - col1 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT + col1 - + cor0.col2 * col0 AS col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - + col2 + - 13 AS col1 FROM tab0 AS cor0
----
-14
-46
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2184
SELECT ALL col0 * 20 DIV + col0 AS col2 FROM tab0 AS cor0
----
20
20
20

skipif mysql # not compatible
query I rowsort label-2184
SELECT ALL col0 * 20 / + col0 AS col2 FROM tab0 AS cor0
----
20
20
20

query I rowsort
SELECT DISTINCT - cor0.col1 * - 35 AS col2 FROM tab0 AS cor0
----
3010
3185
3395

onlyif mysql # use DIV operator for integer division
query I rowsort label-2186
SELECT 72 DIV - col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-2186
SELECT 72 / - col1 FROM tab1
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2187
SELECT col2 + + col2 DIV col0 - + col2 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-2187
SELECT col2 + + col2 / col0 - + col2 FROM tab2 AS cor0
----
0
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2188
SELECT 82 DIV col0 AS col0 FROM tab0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-2188
SELECT 82 / col0 AS col0 FROM tab0
----
0
2
3

query I rowsort
SELECT - 92 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a0e6b76227d870d10c4d9f46545a7c83

query I rowsort
SELECT col2 + - tab1.col0 + - tab1.col0 FROM tab1
----
-64
-71
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-2191
SELECT - tab1.col2 * ( ( - tab1.col0 ) ) DIV tab1.col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2191
SELECT - tab1.col2 * ( ( - tab1.col0 ) ) / tab1.col0 FROM tab1
----
54
57
96

query I rowsort
SELECT ALL - - 43 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1118
1161
1634

query I rowsort
SELECT + 22 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT - cor0.col2 * - col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL ( col2 ) * + col1 + ( - col0 ) AS col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT + 85 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2040
2975
7565

query I rowsort
SELECT - 84 + - col2 FROM tab0
----
-117
-166
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2198
SELECT DISTINCT - col0 * col1 + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2198
SELECT DISTINCT - col0 * col1 + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - + col0 - cor0.col1 AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + - col0 * + cor0.col2 * - ( - col2 ) FROM tab1 cor0
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT - + 5 + + col0 FROM tab2 AS cor0
----
2
73
74

query I rowsort
SELECT DISTINCT + col1 * + col1 * + cor0.col2 + col0 FROM tab0 AS cor0
----
244092
679131
9444

query I rowsort
SELECT DISTINCT tab1.col0 + - 41 + 55 FROM tab1
----
17
78
94

query I rowsort
SELECT - - col0 + + col1 - + col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - - col1 + - col2 * - col0 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2206
SELECT + cor0.col0 + CAST( NULL AS SIGNED ) / - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2206
SELECT + cor0.col0 + CAST ( NULL AS INTEGER ) / - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + cor0.col1 * + col1 + col1 + cor0.col0 FROM tab2 cor0
----
3618
385
999

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2208
SELECT col2 * + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2208
SELECT col2 * + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * 7 AS col1 FROM tab2 AS cor0
----
119
217
413

query I rowsort
SELECT ALL + cor0.col0 - 35 * 81 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-232381
-2800
-93531

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 34 * col1 * col0 - - 23 col0 FROM tab1
----
21783
2675
35383

query I rowsort
SELECT DISTINCT - + cor0.col0 * 2 + 71 FROM tab2 AS cor0
----
-85
-87
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2213
SELECT DISTINCT - cor0.col1 * + col0 + col1 DIV col1 AS col1 FROM tab0 AS cor0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-2213
SELECT DISTINCT - cor0.col1 * + col0 + col1 / col1 AS col1 FROM tab0 AS cor0
----
-2063
-3394
-8098

query I rowsort
SELECT DISTINCT - col2 * - col1 + col2 AS col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT cor1.col1 + 98 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 93353a08055f5d9fda266a854f605619

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2216
SELECT + + CAST( - col1 AS SIGNED ) * - col1 FROM tab0 cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-2216
SELECT + + CAST ( - col1 AS INTEGER ) * - col1 FROM tab0 cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2217
SELECT ALL + CAST( - ( - col2 ) AS SIGNED ) AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2217
SELECT ALL + CAST ( - ( - col2 ) AS INTEGER ) AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + col1 * 80 FROM tab0 AS cor0
----
6880
7280
7760

query I rowsort
SELECT DISTINCT - 28 + - 88 AS col1 FROM tab0 AS cor0
----
-116

query I rowsort
SELECT ALL + ( col0 ) + + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + col2 * + 90 AS col0 FROM tab2 AS cor0
----
2340
2430
3420

query I rowsort
SELECT + - col0 * 23 + col2 * - 39 FROM tab2 cor0
----
-1214
-2808
-3299

query I rowsort
SELECT - col1 * - col2 + + col0 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - 24 * + cor0.col1 AS col0 FROM tab2 cor0
----
-1416
-408
-744

query I rowsort
SELECT DISTINCT col1 * + col2 * 63 AS col0 FROM tab1 AS cor0
----
35910
78624
88452

query I rowsort
SELECT ALL - - col1 * - col2 + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2227
SELECT ALL col1 + col0 * - CAST( 35 + col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-10467
-241
-5878

skipif mysql # not compatible
query I rowsort label-2227
SELECT ALL col1 + col0 * - CAST ( 35 + col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-10467
-241
-5878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col1 ) * - col0 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + + 38 * col1 * 98 + col1 FROM tab1 AS cor0
----
37250
48425
96850

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 11 col0 FROM tab2 AS cor0
----
-11
-11
-11

query I rowsort
SELECT + 45 * - col1 FROM tab2
----
-1395
-2655
-765

query I rowsort
SELECT - ( 43 ) - - col2 AS col2 FROM tab2
----
-16
-17
-5

query I rowsort
SELECT ALL col2 + 12 * + col0 AS col0 FROM tab0
----
1150
321
421

query I rowsort
SELECT col1 * - ( - col0 ) + + col1 AS col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT 19 * - 8 * - col1 AS col1 FROM tab1 AS cor0
----
1520
1976
3952

query I rowsort
SELECT col0 * 33 AS col0 FROM tab2 AS cor0
----
231
2574
2607

onlyif mysql # use DIV operator for integer division
query I rowsort label-2237
SELECT ALL + col1 * col2 DIV + col1 AS col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2237
SELECT ALL + col1 * col2 / + col1 AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT + ( - 66 ) + + col2 * - col2 * ( + col2 ) AS col0 FROM tab1
----
-157530
-185259
-884802

query I rowsort
SELECT ALL + 93 * + tab0.col1 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 79bdc4bc0043e88c9582a9e486fc1834

query I rowsort
SELECT ALL col0 * - 35 FROM tab2
----
-245
-2730
-2765

query I rowsort
SELECT ALL col1 * 88 FROM tab2 AS cor0
----
1496
2728
5192

query I rowsort
SELECT - 15 + col1 * col0 FROM tab1 AS cor0
----
1025
625
63

query I rowsort
SELECT ALL + col1 + 70 * col2 AS col0 FROM tab0 AS cor0
----
167
2396
5831

query I rowsort
SELECT ALL - - cor0.col2 + col2 * col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT col2 * - tab0.col0 + col2 AS col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT ( + tab2.col0 ) + - 14 AS col0 FROM tab2
----
-7
64
65

query I rowsort
SELECT col2 * col1 + + 38 + ( - col0 ) FROM tab2
----
1494
605
868

query I rowsort
SELECT - ( - tab2.col1 ) + ( - col1 ) AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT 56 * col1 + 1 * + col0 AS col1 FROM tab0
----
4840
5185
5467

onlyif mysql # use DIV operator for integer division
query I rowsort label-2250
SELECT DISTINCT col2 * col2 + - col2 DIV - col1 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-2250
SELECT DISTINCT col2 * col2 + - col2 / - col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL ( + col1 * tab0.col2 ) + col1 AS col0 FROM tab0
----
194
2924
7553

query I rowsort
SELECT + 30 + - col1 * ( col1 ) AS col1 FROM tab0
----
-7366
-8251
-9379

query I rowsort
SELECT DISTINCT + 48 * + col1 - col0 * col1 FROM tab2 AS cor0
----
-1770
-527
1271

query I rowsort
SELECT col0 + + col0 * + ( - col1 ) AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT + col1 * col0 - - col2 * col1 FROM tab2 AS cor0
----
1054
1989
6136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2256
SELECT - tab0.col0 * + col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2256
SELECT - tab0.col0 * + col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 + 27 + 42 * col0 FROM tab2 AS cor0
----
3329
3383
348

query I rowsort
SELECT DISTINCT col2 + + ( - col0 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL + - col0 + 91 AS col2 FROM tab0 AS cor0
----
2
56
67

query I rowsort
SELECT DISTINCT + col1 * ( + col0 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT cor0.col2 * col1 AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - + col2 * 49 FROM tab2 AS cor0
----
-1274
-1323
-1862

query I rowsort
SELECT ALL + + col2 + 66 FROM tab0 AS cor0
----
148
67
99

query I rowsort
SELECT + 65 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

query I rowsort
SELECT col2 * 34 * col0 AS col2 FROM tab0 AS cor0
----
1190
248132
26928

onlyif mysql # use DIV operator for integer division
query I rowsort label-2266
SELECT ALL + col2 * ( + col0 ) + col2 DIV + 30 FROM tab2 AS cor0
----
189
2028
3003

skipif mysql # not compatible
query I rowsort label-2266
SELECT ALL + col2 * ( + col0 ) + col2 / + 30 FROM tab2 AS cor0
----
189
2028
3003

query I rowsort
SELECT + 79 - - cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to da59ffd39b157b6bbaf72bc11c04a13b

query I rowsort
SELECT + ( + tab0.col1 ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-2269
SELECT 19 DIV - 30 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-2269
SELECT 19 / - 30 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + col1 * ( + col1 ) AS col1 FROM tab0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * + ( col0 ) col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2272
SELECT cor0.col1 + col2 DIV col1 AS col0 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-2272
SELECT cor0.col1 + col2 / col1 AS col0 FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT + 52 + col2 FROM tab1 AS cor0
----
106
109
148

query I rowsort
SELECT 46 + - 22 AS col2 FROM tab2 AS cor0
----
24
24
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-2275
SELECT - - ( + ( - cor0.col2 ) ) + 40 DIV - col0 AS col0 FROM tab1 cor0
----
-57
-67
-96

skipif mysql # not compatible
query I rowsort label-2275
SELECT - - ( + ( - cor0.col2 ) ) + 40 / - col0 AS col0 FROM tab1 cor0
----
-57
-67
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2276
SELECT - 82 + col1 DIV col0 AS col0 FROM tab1 AS cor0
----
-74
-82
-82

skipif mysql # not compatible
query I rowsort label-2276
SELECT - 82 + col1 / col0 AS col0 FROM tab1 AS cor0
----
-74
-82
-82

query I rowsort
SELECT - - ( 26 ) FROM tab2 AS cor0
----
26
26
26

query I rowsort
SELECT - - ( - cor0.col0 ) + - col2 * - 68 FROM tab0 AS cor0
----
2220
33
5487

query I rowsort
SELECT ALL - + 38 - - col0 FROM tab2 AS cor0
----
-31
40
41

query I rowsort
SELECT DISTINCT - + ( cor0.col2 ) + - col0 AS col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + - col0 + cor0.col0 * cor0.col1 AS col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT - 48 - col1 * + col2 FROM tab1 AS cor0
----
-1296
-1452
-618

query I rowsort
SELECT + 95 + + col2 + + col1 * col2 AS col2 FROM tab2 AS cor0
----
1655
779
959

query I rowsort
SELECT + - col1 - + col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT + + col0 * col2 * col2 AS col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT - 90 * col2 FROM tab1 AS cor0
----
-4860
-5130
-8640

query I rowsort
SELECT ALL - cor0.col0 + + cor0.col2 * 5 AS col1 FROM tab1 AS cor0
----
221
267
400

query I rowsort
SELECT - col0 * - col1 - + ( col0 ) AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT 13 + col1 * col2 AS col1 FROM tab0
----
110
2851
7475

query I rowsort
SELECT + 49 + col0 * + ( 52 ) * + cor0.col0 FROM tab1 AS cor0
----
213041
332849
517

query I rowsort
SELECT + tab0.col0 * + col2 * + col2 AS col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT - - col0 * + 0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 + - 35 AS col2 FROM tab0 AS cor0
----
-121
-126
-132

onlyif mysql # use DIV operator for integer division
query I rowsort label-2294
SELECT col0 + - col0 DIV - col1 AS col1 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-2294
SELECT col0 + - col0 / - col1 AS col1 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT ALL 44 * 87 AS col0 FROM tab0 AS cor0
----
3828
3828
3828

onlyif mysql # use DIV operator for integer division
query I rowsort label-2296
SELECT col2 DIV + 21 FROM tab1 AS cor0
----
2
2
4

skipif mysql # not compatible
query I rowsort label-2296
SELECT col2 / + 21 FROM tab1 AS cor0
----
2
2
4

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2, tab0 AS cor3
----
13122 values hashing to ac865a3c0802d2cd419dc818e6aee316

query I rowsort
SELECT DISTINCT col1 * - col2 - + 12 FROM tab1 AS cor0
----
-1260
-1416
-582

query I rowsort
SELECT tab1.col0 + col0 * - col1 AS col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ( 94 * tab1.col0 ) FROM tab1
----
282
6016
7520

query I rowsort
SELECT - 6 AS col2 FROM tab1
----
-6
-6
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2302
SELECT - cor0.col2 * col2 DIV + col0 FROM tab0 AS cor0
----
-45
-75
0

skipif mysql # not compatible
query I rowsort label-2302
SELECT - cor0.col2 * col2 / + col0 FROM tab0 AS cor0
----
-45
-75
0

query I rowsort
SELECT DISTINCT + cor0.col1 * 65 AS col2 FROM tab0 AS cor0
----
5590
5915
6305

query I rowsort
SELECT + col1 + col2 * col2 * col0 FROM tab1 AS cor0
----
207946
737293
8774

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2305
SELECT + - CAST( NULL AS SIGNED ) + - 68 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2305
SELECT + - CAST ( NULL AS INTEGER ) + - 68 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col2 - - 20 * 51 FROM tab2
----
1046
1047
1058

onlyif mysql # use DIV operator for integer division
query I rowsort label-2307
SELECT DISTINCT - 5 DIV 44 col0 FROM tab1, tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2307
SELECT DISTINCT - 5 / 44 col0 FROM tab1, tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - col2 * + 8 * - tab2.col0 FROM tab2
----
1512
16224
24016

query I rowsort
SELECT ALL - ( col2 ) * + col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT cor0.col2 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + col2 * - tab2.col0 * - col1 AS col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL - col0 * tab0.col0 + col2 * + col2 * col1 AS col0 FROM tab0
----
-1128
603963
93078

query I rowsort
SELECT + cor1.col0 * + ( + 18 ) FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 6eb4db65594b193ce9925754ca28baa0

query I rowsort
SELECT DISTINCT cor0.col0 * - 80 AS col0 FROM tab2 AS cor0
----
-560
-6240
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col2 FROM tab2, tab1, tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2317
SELECT ALL + + cor0.col2 DIV + col0 + col2 AS col0 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-2317
SELECT ALL + + cor0.col2 / + col0 + col2 AS col0 FROM tab2 AS cor0
----
26
30
38

query I rowsort
SELECT ALL + 93 * - col1 * - col1 FROM tab0 AS cor0
----
687828
770133
875037

query I rowsort
SELECT DISTINCT + + 66 * + col0 FROM tab1 AS cor0
----
198
4224
5280

onlyif mysql # use DIV operator for integer division
query I rowsort label-2320
SELECT tab2.col2 + + col0 DIV col0 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-2320
SELECT tab2.col2 + + col0 / col0 FROM tab2
----
27
28
39

query I rowsort
SELECT DISTINCT col0 * tab0.col2 + + tab0.col1 AS col2 FROM tab0
----
132
7389
878

query I rowsort
SELECT tab0.col1 AS col0 FROM tab1, tab2, tab2 cor0, tab0
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT col2 + - col0 * - ( col0 ) + tab0.col2 FROM tab0
----
1227
642
8085

onlyif mysql # use DIV operator for integer division
query I rowsort label-2324
SELECT + 35 DIV + 34 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

skipif mysql # not compatible
query I rowsort label-2324
SELECT + 35 / + 34 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * + cor0.col1 * col0 col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - col1 col0 FROM tab1 AS cor0
----
-20
-26
-52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 46 col2 FROM tab1 cor0
----
-46
-46
-46

query I rowsort
SELECT ALL + - col1 + - col0 FROM tab2 cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col0 * - col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - + 13 FROM tab1, tab2 AS cor0
----
-13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2331
SELECT DISTINCT col0 * CAST( NULL AS SIGNED ) + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2331
SELECT DISTINCT col0 * CAST ( NULL AS INTEGER ) + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - - col2 * - 28 AS col1 FROM tab0 AS cor0
----
-2296
-28
-924

query I rowsort
SELECT - col2 * + ( col1 ) + + cor0.col1 * + 25 AS col0 FROM tab2 AS cor0
----
-221
-59
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col2 * col0 + col1 col1 FROM tab1 AS cor0
----
-36470
-4186
-99827

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2335
SELECT DISTINCT col0 + - CAST( col2 AS SIGNED ) FROM tab2 cor0
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-2335
SELECT DISTINCT col0 + - CAST ( col2 AS INTEGER ) FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 + 81 + col2 AS col0 FROM tab1 AS cor0
----
-2781
-3111
-9039

query I rowsort
SELECT ALL - - cor0.col2 + ( + ( col2 ) ) * ( 40 ) * col0 AS col0 FROM tab2 AS cor0
----
120118
7587
81146

query I rowsort
SELECT DISTINCT cor0.col0 * col2 + + cor0.col2 AS col2 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT ALL + col0 - ( + col0 * + cor0.col1 ) FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - col1 + col2 * col0 * - col1 FROM tab2 AS cor0
----
-119711
-51051
-5890

onlyif mysql # use DIV operator for integer division
query I rowsort label-2341
SELECT ALL - col1 DIV + ( 85 ) + + col2 + col0 * + col1 AS col0 FROM tab2 AS cor0
----
1381
244
4628

skipif mysql # not compatible
query I rowsort label-2341
SELECT ALL - col1 / + ( 85 ) + + col2 + col0 * + col1 AS col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - 66 * col1 FROM tab0 AS cor0
----
-5676
-6006
-6402

query I rowsort
SELECT DISTINCT - 97 * col1 AS col1 FROM tab2 cor0
----
-1649
-3007
-5723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 33 col1 FROM tab1, tab2 cor0, tab0 AS cor1
----
-33

query I rowsort
SELECT ALL + - 91 * - col1 AS col2 FROM tab0 AS cor0
----
7826
8281
8827

query I rowsort
SELECT + col0 + col1 * + 65 FROM tab1 AS cor0
----
1693
714
925

query I rowsort
SELECT - + col2 * + col1 + - ( col2 ) FROM tab0 AS cor0
----
-2871
-7544
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) + col1 * col2 col1 FROM tab0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-2349
SELECT col0 DIV col2 + - col0 FROM tab1
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-2349
SELECT col0 / col2 + - col0 FROM tab1
----
-3
-63
-80

query I rowsort
SELECT DISTINCT 60 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2351
SELECT ALL + col0 + CAST( 70 AS SIGNED ) - col0 AS col1 FROM tab0
----
70
70
70

skipif mysql # not compatible
query I rowsort label-2351
SELECT ALL + col0 + CAST ( 70 AS INTEGER ) - col0 AS col1 FROM tab0
----
70
70
70

query I rowsort
SELECT - col1 * 53 + - col1 AS col0 FROM tab0 AS cor0
----
-4644
-4914
-5238

query I rowsort
SELECT - - 15 + - col2 AS col1 FROM tab0 AS cor0
----
-18
-67
14

query I rowsort
SELECT DISTINCT tab1.col0 * col1 + + col0 AS col2 FROM tab1
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2355
SELECT col1 * 81 DIV - 9 AS col1 FROM tab2
----
-153
-279
-531

skipif mysql # not compatible
query I rowsort label-2355
SELECT col1 * 81 / - 9 AS col1 FROM tab2
----
-153
-279
-531

query I rowsort
SELECT - col1 + col2 + 29 AS col1 FROM tab1
----
112
57
76

query I rowsort
SELECT 66 * tab2.col2 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to a51772a0f3f89a84175b3afd1cea6249

query I rowsort
SELECT + 82 + + 88 + - col1 * col0 AS col2 FROM tab1
----
-470
-870
92

query I rowsort
SELECT DISTINCT + 51 AS col2 FROM tab2, tab1 cor0
----
51

query I rowsort
SELECT ALL - 26 + col2 FROM tab0
----
-25
56
7

query I rowsort
SELECT + ( col1 ) + + col0 * - 15 FROM tab0 AS cor0
----
-1244
-274
-428

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * cor0.col0 + col1 + + 22 col0 FROM tab0 AS cor0
----
-1956
-3276
-7986

query I rowsort
SELECT - - col1 * col0 * + col0 + col1 FROM tab2 AS cor0
----
106114
1550
359015

query I rowsort
SELECT ALL - + 32 FROM tab0 AS cor0
----
-32
-32
-32

query I rowsort
SELECT DISTINCT - + ( - col2 ) + col1 * ( col0 ) FROM tab2 cor0
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2366
SELECT DISTINCT CAST( 68 AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
5848
6188
6596

skipif mysql # not compatible
query I rowsort label-2366
SELECT DISTINCT CAST ( 68 AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
5848
6188
6596

query I rowsort
SELECT ALL - + 17 AS col1 FROM tab0 AS cor0
----
-17
-17
-17

query I rowsort
SELECT DISTINCT col1 * 57 FROM tab0 AS cor0
----
4902
5187
5529

onlyif mysql # use DIV operator for integer division
query I rowsort label-2369
SELECT 43 + col1 DIV + col1 AS col2 FROM tab0 AS cor0
----
44
44
44

skipif mysql # not compatible
query I rowsort label-2369
SELECT 43 + col1 / + col1 AS col2 FROM tab0 AS cor0
----
44
44
44

query I rowsort
SELECT DISTINCT cor0.col1 + + col0 AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + 51 + col0 + col0 * - col1 AS col1 FROM tab0 cor0
----
-1989
-3309
-7959

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2372
SELECT DISTINCT CAST( NULL AS DECIMAL ) / + cor0.col2 + + cor0.col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2372
SELECT DISTINCT CAST ( NULL AS REAL ) / + cor0.col2 + + cor0.col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + + col2 * ( col2 ) AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + col2 + + col1 * + 3 FROM tab0 cor0
----
291
292
355

query I rowsort
SELECT - 52 * col0 FROM tab0
----
-1248
-1820
-4628

query I rowsort
SELECT DISTINCT - col2 + - col1 + col1 * 1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT + - col1 - - cor0.col1 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 + 20 AS col2 FROM tab1 cor0
----
100
23
84

query I rowsort
SELECT ALL ( col1 * col0 ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT col1 + + col1 + - ( - col2 ) AS col1 FROM tab2 AS cor0
----
144
72
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2381
SELECT - + cor0.col2 * - col1 + + CAST( + 45 AS SIGNED ) * col1 AS col1 FROM tab0 cor0
----
11557
4462
6708

skipif mysql # not compatible
query I rowsort label-2381
SELECT - + cor0.col2 * - col1 + + CAST ( + 45 AS INTEGER ) * col1 AS col1 FROM tab0 cor0
----
11557
4462
6708

query I rowsort
SELECT - + 33 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
53
58
64

query I rowsort
SELECT - col1 - - col0 * - ( + ( + col2 ) ) AS col0 FROM tab2 AS cor0
----
-2087
-220
-3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 4 * col2 col0 FROM tab2 AS cor0
----
104
108
152

query I rowsort
SELECT + ( col2 ) * ( col1 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - col2 * col1 - + 96 FROM tab2 AS cor0
----
-1630
-742
-933

query I rowsort
SELECT ALL cor0.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2388
SELECT ALL - col2 * CAST( NULL AS SIGNED ) + col0 * + cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2388
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) + col0 * + cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - 66 AS col0 FROM tab0 AS cor0
----
-2178
-5412
-66

query I rowsort
SELECT DISTINCT + + col2 + col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT ALL col1 * cor0.col0 + + col0 - col1 * col1 AS col1 FROM tab0 AS cor0
----
-5308
-5979
-93

query I rowsort
SELECT ALL - col0 + - cor0.col1 * ( col2 ) AS col1 FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT - col1 - ( + col2 + + cor0.col1 ) FROM tab1 AS cor0
----
-106
-122
-77

query I rowsort
SELECT - col2 * 52 AS col2 FROM tab2 AS cor0
----
-1352
-1404
-1976

query I rowsort
SELECT - 91 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2396
SELECT - CAST( + 74 AS SIGNED ) * col2 - col1 AS col1 FROM tab2 AS cor0
----
-1983
-2029
-2829

skipif mysql # not compatible
query I rowsort label-2396
SELECT - CAST ( + 74 AS INTEGER ) * col2 - col1 AS col1 FROM tab2 AS cor0
----
-1983
-2029
-2829

query I rowsort
SELECT ( + 77 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT + col0 + + ( - ( tab0.col1 ) ) * 35 * col2 FROM tab0
----
-261081
-3360
-99306

query I rowsort
SELECT + tab1.col0 * - ( - col2 ) + - col0 FROM tab1
----
159
3584
7600

query I rowsort
SELECT DISTINCT col1 * + col0 * + col1 + col1 * ( col2 ) AS col2 FROM tab1
----
14768
3432
6970

query I rowsort
SELECT 92 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT - col1 - col0 * col2 AS col1 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT tab0.col0 * 43 * 22 AS col0 FROM tab0
----
22704
33110
84194

query I rowsort
SELECT ALL - col0 * + col1 * col0 AS col2 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT + 84 * + cor0.col0 FROM tab0 AS cor0
----
2016
2940
7476

query I rowsort
SELECT ALL - 44 * - col1 FROM tab2 AS cor0
----
1364
2596
748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 46 * 50 col2 FROM tab0 AS cor0
----
2300

query I rowsort
SELECT - - 96 * + col1 AS col0 FROM tab1 AS cor0
----
1248
2496
960

query I rowsort
SELECT + ( - ( - col1 ) ) * ( 57 ) FROM tab0 AS cor0
----
4902
5187
5529

query I rowsort
SELECT + 90 + - col2 AS col0 FROM tab0
----
57
8
89

query I rowsort
SELECT - - ( - col2 ) * col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT cor0.col1 * + col1 * cor0.col2 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT - 46 * col0 AS col2 FROM tab0 AS cor0
----
-1104
-1610
-4094

query I rowsort
SELECT ALL col1 * + cor0.col2 + - col2 AS col0 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT ( 46 ) FROM tab2 AS cor0
----
46

query I rowsort
SELECT + - 57 * - 70 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to 25b082a75864ec489af2641072297ee9

query I rowsort
SELECT ALL + 64 + col0 AS col0 FROM tab0 cor0
----
153
88
99

query I rowsort
SELECT ALL ( - ( col0 ) ) + col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL + col2 * + cor0.col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT 92 + col0 AS col2 FROM tab1 AS cor0
----
156
172
95

query I rowsort
SELECT + + 75 - cor0.col0 FROM tab2 cor0
----
-3
-4
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-2422
SELECT ALL - 25 DIV + col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-2422
SELECT ALL - 25 / + col0 FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2423
SELECT DISTINCT col0 DIV col0 + - col1 * + col0 AS col0 FROM tab0 AS cor0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-2423
SELECT DISTINCT col0 / col0 + - col1 * + col0 AS col0 FROM tab0 AS cor0
----
-2063
-3394
-8098

query I rowsort
SELECT DISTINCT col0 * 57 + 55 * - col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT - - cor0.col2 + ( + col0 + + cor0.col2 ) FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT col0 + tab0.col2 * - 67 - ( col0 ) * - col0 AS col2 FROM tab0
----
-1611
1193
2516

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2427
SELECT DISTINCT col1 + - CAST( NULL AS SIGNED ) - 69 * - col2 * 5 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2427
SELECT DISTINCT col1 + - CAST ( NULL AS INTEGER ) - 69 * - col2 * 5 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2428
SELECT ALL + col2 - - CAST( ( + col0 ) AS SIGNED ) * ( col0 + col1 ) * 39 FROM tab1 AS cor0
----
184761
290256
3447

skipif mysql # not compatible
query I rowsort label-2428
SELECT ALL + col2 - - CAST ( ( + col0 ) AS INTEGER ) * ( col0 + col1 ) * 39 FROM tab1 AS cor0
----
184761
290256
3447

query I rowsort
SELECT - col0 * - col2 * - col1 + - col2 * col1 * col1 AS col2 FROM tab0 AS cor0
----
-12804
-1343160
-312180

query I rowsort
SELECT DISTINCT + col2 * - col0 * + 34 + - col1 * + col2 AS col1 FROM tab0 AS cor0
----
-1287
-255594
-29766

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2431
SELECT ALL - col1 + - CAST( col2 * col1 AS SIGNED ) - col0 AS col1 FROM tab1 AS cor0
----
-1341
-1433
-644

skipif mysql # not compatible
query I rowsort label-2431
SELECT ALL - col1 + - CAST ( col2 * col1 AS INTEGER ) - col0 AS col1 FROM tab1 AS cor0
----
-1341
-1433
-644

query I rowsort
SELECT - col1 * ( 84 ) + - cor0.col0 AS col1 FROM tab2 cor0
----
-1507
-2611
-5034

query I rowsort
SELECT DISTINCT - col1 * col2 + col0 * + col2 AS col1 FROM tab0 AS cor0
----
-164
-2046
-62

query I rowsort
SELECT ALL + + col1 * - 16 + - 23 AS col1 FROM tab2 AS cor0
----
-295
-519
-967

query I rowsort
SELECT ALL - col0 - 25 FROM tab1 AS cor0
----
-105
-28
-89

query I rowsort
SELECT col1 + - ( + 35 ) AS col0 FROM tab0 AS cor0
----
51
56
62

query I rowsort
SELECT cor0.col2 + cor0.col1 AS col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2438
SELECT DISTINCT cor0.col2 DIV - col0 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-2438
SELECT DISTINCT cor0.col2 / - col0 FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT + cor0.col1 * - ( + col2 + col1 ) AS col1 FROM tab1 AS cor0
----
-1417
-2080
-670

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * cor0.col2 + col1 * col2 col0 FROM tab0 AS cor0
----
1749
738
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2441
SELECT + cor0.col1 * + CAST( col0 AS SIGNED ) * + cor0.col2 + - col1 DIV + col0 FROM tab1 AS cor0
----
36480
4204
99840

skipif mysql # not compatible
query I rowsort label-2441
SELECT + cor0.col1 * + CAST ( col0 AS INTEGER ) * + cor0.col2 + - col1 / + col0 FROM tab1 AS cor0
----
36480
4204
99840

query I rowsort
SELECT DISTINCT + col2 + - 9 AS col1 FROM tab1
----
45
48
87

query I rowsort
SELECT - 48 + col1 FROM tab1 AS cor0
----
-22
-35
-38

query I rowsort
SELECT + 93 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 cor1, tab1 AS cor2
----
81 values hashing to bed80270d2bd273301f8ff63d7ef9f43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col2 col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - col1 + + col0 * - 57 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-12400
-262373
-76568

query I rowsort
SELECT - 88 + - cor0.col1 * col0 * - col2 FROM tab2 AS cor0
----
119564
50946
5771

query I rowsort
SELECT DISTINCT + - col2 * col1 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2449
SELECT ( ( - col0 ) ) * + CAST( col2 AS SIGNED ) + + col2 AS col2 FROM tab0
----
-34
-7216
-759

skipif mysql # not compatible
query I rowsort label-2449
SELECT ( ( - col0 ) ) * + CAST ( col2 AS INTEGER ) + + col2 AS col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT col0 * + 7 FROM tab0
----
168
245
623

query I rowsort
SELECT 19 * - tab2.col1 * col2 - - ( tab2.col2 ) AS col2 FROM tab2
----
-12236
-15876
-29120

query I rowsort
SELECT 8 + col1 AS col2 FROM tab2
----
25
39
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2453
SELECT tab1.col1 + tab1.col0 + + CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2453
SELECT tab1.col1 + tab1.col0 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2454
SELECT DISTINCT col1 DIV - col1 + + col2 AS col0 FROM tab2
----
25
26
37

skipif mysql # not compatible
query I rowsort label-2454
SELECT DISTINCT col1 / - col1 + + col2 AS col0 FROM tab2
----
25
26
37

query I rowsort
SELECT col2 * col2 * + 36 FROM tab1
----
104976
116964
331776

query I rowsort
SELECT + ( + col1 ) * col0 + + col0 AS col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT ALL + + 39 + col2 AS col0 FROM tab0 AS cor0
----
121
40
72

query I rowsort
SELECT + col2 * col1 * - 88 AS col2 FROM tab2 AS cor0
----
-134992
-56848
-73656

query I rowsort
SELECT + col0 + + col1 + + col0 AS col2 FROM tab0 cor0
----
134
167
269

query I rowsort
SELECT ALL - 87 * - col0 AS col1 FROM tab1 AS cor0
----
261
5568
6960

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) BETWEEN + col1 * + col2 / col0 AND ( col2 )
----

query I rowsort
SELECT - tab0.col0 * + col0 * tab0.col2 FROM tab0 WHERE - col2 * + col0 NOT BETWEEN col0 AND NULL
----
-1225
-19008
-649522

query I rowsort
SELECT tab1.col0 + - col1 AS col0 FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT tab0.col1 FROM tab0 WHERE NOT + col2 NOT IN ( tab0.col1 )
----

query I rowsort
SELECT col0 * col1 + + col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + col1 + - col2 - col1 FROM tab2
----
-26
-27
-38

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL NOT IN ( - col0 )
----

query I rowsort
SELECT - col0 * + tab1.col2 + col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT ALL col0 * - col0 + col2 AS col1 FROM tab0
----
-1224
-543
-7839

query I rowsort
SELECT col2 FROM tab0 WHERE NOT col2 IN ( - col2 )
----
1
33
82

query I rowsort
SELECT + col2 * col0 + + col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT - col1 * - col1 - + col2 * col0 AS col0 FROM tab2
----
-2713
1453
772

query I rowsort
SELECT + - 84 * col0 AS col0 FROM tab0 AS cor0
----
-2016
-2940
-7476

query I rowsort
SELECT ALL - cor0.col2 * cor0.col2 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 42bf3b8f2bb865dbe16abdf6d3d647fc

query I rowsort
SELECT ALL + col2 + - cor0.col1 * 30 AS col2 FROM tab2 AS cor0
----
-1744
-472
-903

query I rowsort
SELECT 43 + - col1 * + col0 AS col2 FROM tab0 cor0
----
-2021
-3352
-8056

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2477
SELECT col1 * + col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2477
SELECT col1 * + col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * - col1 * + col0 + + col0 AS col0 FROM tab0
----
-177480
-329280
-736920

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL NOT IN ( - col1 * - tab1.col0 )
----

query I rowsort
SELECT ALL - col2 + - col0 * + tab2.col1 FROM tab2
----
-1381
-244
-4628

query I rowsort
SELECT ALL tab2.col1 - col2 AS col2 FROM tab2 WHERE NOT NULL IN ( + col2 )
----

query I rowsort
SELECT ALL - cor0.col2 + + cor0.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 5fc5fcec216468c99d1c0eaf371b3149

query I rowsort
SELECT DISTINCT col2 * cor0.col0 + cor0.col0 FROM tab2 AS cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + tab2.col0 * col2 col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT ALL col2 * - col2 + cor0.col1 - - col0 FROM tab2 AS cor0
----
-1348
-539
-691

query I rowsort
SELECT + col0 AS col0 FROM tab2 AS cor0 WHERE NOT col0 >= NULL
----

query I rowsort
SELECT + col2 * col0 * col2 AS col2 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT DISTINCT tab1.col2 + col0 * - col2 * tab1.col2 + - tab1.col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT col1 + col2 + col1 FROM tab0
----
195
205
264

onlyif mysql # use DIV operator for integer division
query I rowsort label-2490
SELECT ALL - col2 * col2 DIV col1 AS col1 FROM tab1
----
-112
-324
-708

skipif mysql # not compatible
query I rowsort label-2490
SELECT ALL - col2 * col2 / col1 AS col1 FROM tab1
----
-112
-324
-708

query I rowsort
SELECT col2 * tab1.col2 * col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT ALL col1 + - col2 + - col0 FROM tab1
----
-111
-163
-31

onlyif mysql # use DIV operator for integer division
query I rowsort label-2493
SELECT ALL col0 DIV - col0 col2 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2493
SELECT ALL col0 / - col0 col2 FROM tab0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2494
SELECT DISTINCT col0 DIV col0 - - tab1.col0 AS col2 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-2494
SELECT DISTINCT col0 / col0 - - tab1.col0 AS col2 FROM tab1
----
4
65
81

query I rowsort
SELECT col1 - col0 * + col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL tab1.col2 - col1 AS col0 FROM tab1
----
28
47
83

query I rowsort
SELECT col1 * col2 * + col0 FROM tab2
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 col1 FROM tab1
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2499
SELECT DISTINCT col2 DIV col0 - - tab1.col0 col1 FROM tab1
----
21
64
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2499
SELECT DISTINCT col2 / col0 - - tab1.col0 col1 FROM tab1
----
21
64
81

query I rowsort
SELECT ALL - 89 * cor0.col0 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to f942ebf2fa8fbc72afeeb4a58f36427d

query I rowsort
SELECT DISTINCT 93 FROM tab2, tab0, tab2 AS cor0
----
93

query I rowsort
SELECT DISTINCT + ( + col0 ) * - col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT + col1 + col2 * + col0 - - col2 AS col0 FROM tab0
----
133
7471
911

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2504
SELECT ALL CAST( + 52 AS SIGNED ) - + col0 FROM tab1
----
-12
-28
49

skipif mysql # not compatible
query I rowsort label-2504
SELECT ALL CAST ( + 52 AS INTEGER ) - + col0 FROM tab1
----
-12
-28
49

query I rowsort
SELECT ALL - col1 - col2 AS col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT DISTINCT 55 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
55

query I rowsort
SELECT ALL 36 * + col0 FROM tab0
----
1260
3204
864

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 DISTINCT + tab2.col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
17
31
59

query I rowsort
SELECT 88 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col2 + - col0 col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-2512
SELECT ALL - tab1.col2 DIV - col0 AS col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-2512
SELECT ALL - tab1.col2 / - col0 AS col0 FROM tab1
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-2513
SELECT cor0.col2 DIV col1 + + ( + col1 ) FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-2513
SELECT cor0.col2 / col1 + + ( + col1 ) FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT - 93 + col2 AS col2 FROM tab0 cor0
----
-11
-60
-92

query I rowsort
SELECT ALL + ( col0 ) + - col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT 41 + col2 + - tab2.col2 * 11 FROM tab2
----
-219
-229
-339

query I rowsort
SELECT 3 + - col0 FROM tab2
----
-4
-75
-76

query I rowsort
SELECT 54 + col1 - + col2 FROM tab2
----
33
58
87

query I rowsort
SELECT ALL + ( + col1 ) * col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT col1 + - col0 - - col2 FROM tab0
----
63
84
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2521
SELECT + + 38 DIV - col1 AS col1 FROM tab1 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2521
SELECT + + 38 / - col1 AS col1 FROM tab1 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ALL - ( col0 ) + + 18 * 21 FROM tab0 AS cor0
----
289
343
354

onlyif mysql # use DIV operator for integer division
query I rowsort label-2523
SELECT DISTINCT + + 51 DIV cor0.col1 col1 FROM tab0 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2523
SELECT DISTINCT + + 51 / cor0.col1 col1 FROM tab0 cor0
----
0

query I rowsort
SELECT + col2 * + col0 + ( col2 ) FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT - 93 + col2 FROM tab2 AS cor0
----
-55
-66
-67

query I rowsort
SELECT + 86 + col0 AS col0 FROM tab0 AS cor0
----
110
121
175

query I rowsort
SELECT + ( col0 ) * + 37 AS col2 FROM tab2 AS cor0
----
259
2886
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-2528
SELECT + cor0.col1 DIV cor0.col0 + - col0 AS col2 FROM tab0 AS cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-2528
SELECT + cor0.col1 / cor0.col0 + - col0 AS col2 FROM tab0 AS cor0
----
-21
-33
-88

query I rowsort
SELECT ALL + 86 * + col1 AS col0 FROM tab2 cor0
----
1462
2666
5074

query I rowsort
SELECT col1 * 1 * + 67 FROM tab2
----
1139
2077
3953

onlyif mysql # use DIV operator for integer division
query I rowsort label-2531
SELECT - + col2 DIV col0 AS col1 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-2531
SELECT - + col2 / col0 AS col1 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT ALL + 45 AS col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2533
SELECT - - CAST( cor0.col0 AS SIGNED ) + cor0.col2 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-2533
SELECT - - CAST ( cor0.col0 AS INTEGER ) + cor0.col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + col0 * + ( - col0 ) - + col2 FROM tab1 AS cor0
----
-4153
-63
-6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-2535
SELECT - + 67 DIV col0 + + cor0.col1 FROM tab2 AS cor0
----
17
22
59

skipif mysql # not compatible
query I rowsort label-2535
SELECT - + 67 / col0 + + cor0.col1 FROM tab2 AS cor0
----
17
22
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2536
SELECT + + 88 - col1 DIV col2 FROM tab1 AS cor0
----
88
88
88

skipif mysql # not compatible
query I rowsort label-2536
SELECT + + 88 - col1 / col2 FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT - - col1 - - 47 AS col2 FROM tab2 AS cor0
----
106
64
78

query I rowsort
SELECT ALL col0 + - 2 FROM tab2 AS cor0
----
5
76
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-2539
SELECT ALL 99 DIV - cor0.col0 AS col2 FROM tab0 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-2539
SELECT ALL 99 / - cor0.col0 AS col2 FROM tab0 AS cor0
----
-1
-2
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2540
SELECT DISTINCT col2 * - col1 * - col1 + cor0.col2 DIV + col0 AS col1 FROM tab1 AS cor0
----
16225
36522
5700

skipif mysql # not compatible
query I rowsort label-2540
SELECT DISTINCT col2 * - col1 * - col1 + cor0.col2 / + col0 AS col1 FROM tab1 AS cor0
----
16225
36522
5700

query I rowsort
SELECT cor0.col0 + - 58 FROM tab2 AS cor0
----
-51
20
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2542
SELECT - + CAST( - col2 AS SIGNED ) - + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2542
SELECT - + CAST ( - col2 AS INTEGER ) - + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( col2 ) + cor0.col0 AS col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - 33 * col0 + - col0 FROM tab1 AS cor0
----
-102
-2176
-2720

query I rowsort
SELECT DISTINCT + 32 * + col2 AS col1 FROM tab1 AS cor0
----
1728
1824
3072

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 51 * + col1 col2 FROM tab0 AS cor0
----
4386
4641
4947

query I rowsort
SELECT ALL 37 * col0 AS col1 FROM tab2 AS cor0
----
259
2886
2923

query I rowsort
SELECT - + col1 * ( col0 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2549
SELECT ALL - col1 - - col2 DIV - col1 AS col1 FROM tab2 AS cor0
----
-19
-31
-59

skipif mysql # not compatible
query I rowsort label-2549
SELECT ALL - col1 - - col2 / - col1 AS col1 FROM tab2 AS cor0
----
-19
-31
-59

query I rowsort
SELECT ALL 96 + + col2 FROM tab0 cor0
----
129
178
97

query I rowsort
SELECT DISTINCT col0 * + col1 - + col0 AS col2 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT + + cor0.col2 * 87 FROM tab0 AS cor0
----
2871
7134
87

query I rowsort
SELECT DISTINCT - - col1 * col1 + col1 * + cor0.col0 FROM tab1 cor0
----
1209
740
754

query I rowsort
SELECT 6 * ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT ALL + col0 + col2 * 48 AS col2 FROM tab2 cor0
----
1303
1326
1903

query I rowsort
SELECT + col2 + col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT - - col1 * col0 + - col1 * col1 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
-1157
-17498
-360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col0 ) * + 45 col1 FROM tab2 AS cor0
----
-315
-3510
-3555

query I rowsort
SELECT - 79 * cor0.col0 * 86 AS col2 FROM tab0 AS cor0
----
-163056
-237790
-604666

query I rowsort
SELECT + col0 + col1 * col0 + - 12 FROM tab1
----
1108
69
692

query I rowsort
SELECT ALL - col2 * col2 + tab2.col1 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT ALL + 31 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0 CROSS JOIN tab1, tab0 cor1
----
972 values hashing to e84152c0bf436177d3b3d80e42832d4f

query I rowsort
SELECT DISTINCT - - col1 + + ( - col0 ) * + col0 FROM tab1 cor0
----
-4086
-6387
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - 52 col0 FROM tab1 AS cor0
----
2
44
5

query I rowsort
SELECT DISTINCT col1 + + col0 * 77 AS col0 FROM tab0 AS cor0
----
1934
2792
6944

query I rowsort
SELECT - 60 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1a0b29f8e6f82c54623a665ba4af8fd1

query I rowsort
SELECT ALL - - col1 * 47 + - col1 + col2 AS col1 FROM tab1 AS cor0
----
1250
517
694

query I rowsort
SELECT DISTINCT + col1 * ( - col0 ) + + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + + col0 * - ( + col2 ) * col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT ALL - tab1.col0 * - ( tab1.col1 * + col2 ) FROM tab1
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col0 ) col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * - col0 * - col2 + col0 * col0 col1 FROM tab0 AS cor0
----
-2170
-656197
-67536

query I rowsort
SELECT ALL + - ( 2 ) * col1 AS col0 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT 32 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT DISTINCT + 38 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
38

query I rowsort
SELECT col0 * + col2 + tab0.col0 AS col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL - 48 * cor0.col0 + 47 FROM tab1 AS cor0
----
-3025
-3793
-97

query I rowsort
SELECT ALL - cor0.col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - col1 * - ( col2 * + col1 ) FROM tab0
----
244068
679042
9409

query I rowsort
SELECT - col2 * + col2 + - col1 - + col2 FROM tab1 AS cor0
----
-2996
-3316
-9325

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - tab0.col2 ) col2 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * + col0 + col0 * + 37 col1 FROM tab0 cor0
----
11214
1464
2520

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2584
SELECT DISTINCT - cor0.col1 / CAST( NULL AS DECIMAL ) AS col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2584
SELECT DISTINCT - cor0.col1 / CAST ( NULL AS REAL ) AS col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
NULL

query I rowsort
SELECT DISTINCT col2 * col0 * cor0.col0 + cor0.col2 AS col1 FROM tab2 AS cor0
----
1350
158210
237196

query I rowsort
SELECT DISTINCT - - 20 + + 45 FROM tab1 AS cor0
----
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2587
SELECT + CAST( col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2587
SELECT + CAST ( col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT 16 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 9ffb4aaf972de606a4957894645b6216

onlyif mysql # use DIV operator for integer division
query I rowsort label-2589
SELECT ALL - col1 DIV - 54 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2589
SELECT ALL - col1 / - 54 FROM tab0 cor0
----
1
1
1

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0, tab2 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to 199388980dc5177ebebcfdbc0408ba02

onlyif mysql # use DIV operator for integer division
query I rowsort label-2591
SELECT cor0.col0 DIV cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2591
SELECT cor0.col0 / cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + ( - col1 ) + 69 * 90 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
105553
192479
366331

query I rowsort
SELECT ALL + - col2 + cor0.col1 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2594
SELECT ALL + CAST( + col2 + col2 AS SIGNED ) FROM tab2
----
52
54
76

skipif mysql # not compatible
query I rowsort label-2594
SELECT ALL + CAST ( + col2 + col2 AS INTEGER ) FROM tab2
----
52
54
76

query I rowsort
SELECT ALL + 22 * + col0 FROM tab0
----
1958
528
770

query I rowsort
SELECT - 13 + col0 AS col2 FROM tab0 AS cor0
----
11
22
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 82 * + 4 col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
328

query I rowsort
SELECT DISTINCT - 51 AS col0 FROM tab2, tab2 AS cor0, tab0 cor1
----
-51

query I rowsort
SELECT ALL 79 AS col2 FROM tab1
----
79
79
79

query I rowsort
SELECT ALL - cor0.col0 FROM tab1, tab2, tab0 cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - col2 * 41 col1 FROM tab2
----
-1040
-1080
-1520

query I rowsort
SELECT DISTINCT + - col1 * ( + cor0.col0 ) + - cor0.col1 + - col2 AS col0 FROM tab0 AS cor0
----
-2183
-3493
-8272

query I rowsort
SELECT ALL - - cor0.col2 * 78 + 73 AS col0 FROM tab1 AS cor0
----
4285
4519
7561

query I rowsort
SELECT DISTINCT - + col0 * - 29 AS col0 FROM tab1 cor0
----
1856
2320
87

query I rowsort
SELECT + 29 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT ALL tab1.col2 * - col2 * - col1 AS col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT ALL - 54 + + cor0.col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to fb6b3fa4d562ee0a52b5c51c498092ce

query I rowsort
SELECT + col2 * - 4 AS col0 FROM tab0 AS cor0
----
-132
-328
-4

query I rowsort
SELECT + cor0.col1 * + col0 * + col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT - tab1.col2 * - ( - 84 * + tab1.col0 ) FROM tab1
----
-13608
-306432
-645120

query I rowsort
SELECT - col1 * + tab1.col2 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - tab1.col0 + ( col2 ) * - tab1.col0 AS col1 FROM tab1
----
-165
-3712
-7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2613
SELECT tab2.col2 / CAST( NULL AS SIGNED ) + ( + col2 ) * 35 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2613
SELECT tab2.col2 / CAST ( NULL AS INTEGER ) + ( + col2 ) * 35 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * ( - col2 * col2 ) FROM tab2
----
-17576
-19683
-54872

query I rowsort
SELECT + 56 + - col0 FROM tab0
----
-33
21
32

query I rowsort
SELECT - col1 + 35 * col2 FROM tab0 AS cor0
----
-62
1069
2779

query I rowsort
SELECT DISTINCT - + ( - col0 ) AS col2 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2618
SELECT col1 DIV + 81 col1 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2618
SELECT col1 / + 81 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 - 91 AS col1 FROM tab1 AS cor0
----
-145
-148
-187

onlyif mysql # use DIV operator for integer division
query I rowsort label-2620
SELECT DISTINCT - + col0 DIV 51 + col1 FROM tab2 AS cor0
----
16
31
58

skipif mysql # not compatible
query I rowsort label-2620
SELECT DISTINCT - + col0 / 51 + col1 FROM tab2 AS cor0
----
16
31
58

query I rowsort
SELECT DISTINCT + col1 * - 84 * - col0 - col2 AS col0 FROM tab0 cor0
----
173343
285179
680234

query I rowsort
SELECT DISTINCT 50 FROM tab1, tab1 cor0
----
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-2623
SELECT + + col2 + 0 DIV + ( col1 ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2623
SELECT + + col2 + 0 / + ( col1 ) FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2624
SELECT DISTINCT col0 * - CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2624
SELECT DISTINCT col0 * - CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2625
SELECT ALL + col1 - + CAST( + col0 AS SIGNED ) * col0 * - ( 42 + cor0.col2 ) FROM tab0 cor0
----
43286
52772
982295

skipif mysql # not compatible
query I rowsort label-2625
SELECT ALL + col1 - + CAST ( + col0 AS INTEGER ) * col0 * - ( 42 + cor0.col2 ) FROM tab0 cor0
----
43286
52772
982295

query I rowsort
SELECT ALL col2 * - 50 AS col2 FROM tab1 AS cor0
----
-2700
-2850
-4800

query I rowsort
SELECT DISTINCT + cor0.col0 + - ( - cor0.col0 ) FROM tab2 AS cor0
----
14
156
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2628
SELECT DISTINCT col2 + + CAST( NULL AS SIGNED ) * col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2628
SELECT DISTINCT col2 + + CAST ( NULL AS INTEGER ) * col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - col2 - - 52 AS col1 FROM tab0
----
-30
19
51

query I rowsort
SELECT ALL - col2 - 37 AS col0 FROM tab0
----
-119
-38
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2631
SELECT ALL tab2.col1 - CAST( col2 AS SIGNED ) * col2 AS col2 FROM tab2
----
-1427
-617
-698

skipif mysql # not compatible
query I rowsort label-2631
SELECT ALL tab2.col1 - CAST ( col2 AS INTEGER ) * col2 AS col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT - + ( col0 ) + col1 AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL col1 + + ( cor0.col1 ) FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + + col2 - col1 AS col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT - 80 * col0 AS col1 FROM tab0 AS cor0
----
-1920
-2800
-7120

onlyif mysql # use DIV operator for integer division
query I rowsort label-2636
SELECT + - col2 * 34 + - col1 DIV col1 AS col2 FROM tab1 AS cor0
----
-1837
-1939
-3265

skipif mysql # not compatible
query I rowsort label-2636
SELECT + - col2 * 34 + - col1 / col1 AS col2 FROM tab1 AS cor0
----
-1837
-1939
-3265

query I rowsort
SELECT ALL - + 44 + col0 * col2 AS col2 FROM tab0 AS cor0
----
-9
7254
748

onlyif mysql # use DIV operator for integer division
query I rowsort label-2638
SELECT col0 DIV + 87 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2638
SELECT col0 / + 87 FROM tab0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2639
SELECT col0 + + 82 DIV + col0 FROM tab0
----
27
37
89

skipif mysql # not compatible
query I rowsort label-2639
SELECT col0 + + 82 / + col0 FROM tab0
----
27
37
89

skipif mysql # not compatible
query I rowsort
SELECT ALL col2 + + CAST ( + 68 AS REAL ) * + tab1.col2 AS col1 FROM tab1
----
3726
3933
6624

query I rowsort
SELECT DISTINCT + col0 * + 55 + + col1 FROM tab1
----
191
3530
4413

query I rowsort
SELECT DISTINCT col1 * + col0 + col2 AS col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL + col2 - col1 * col1 FROM tab0
----
-7363
-8199
-9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + 13 col2 FROM tab2
----
-18
-4
-46

query I rowsort
SELECT ALL - col2 + - ( - col2 ) * col2 FROM tab0
----
0
1056
6642

onlyif mysql # use DIV operator for integer division
query I rowsort label-2646
SELECT DISTINCT col1 DIV col2 + col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2646
SELECT DISTINCT col1 / col2 + col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT + - col0 - col2 AS col1 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT ( - col0 ) * col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + 50 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
1650
4100
50

query I rowsort
SELECT + 10 * col1 FROM tab2 cor0
----
170
310
590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * col1 + col0 * col1 col0 FROM tab1 cor0
----
-598
540
871

query I rowsort
SELECT DISTINCT ( + 18 ) FROM tab1
----
18

query I rowsort
SELECT ALL - + col1 * + col1 * 67 FROM tab2 cor0
----
-19363
-233227
-64387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 88 * col0 col1 FROM tab2 AS cor0
----
616
6864
6952

query I rowsort
SELECT col2 * - cor0.col2 * + col1 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT 2 AS col1 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL + + col2 + + 93 * ( - col1 + 1 ) AS col2 FROM tab1 AS cor0
----
-1020
-2271
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-2659
SELECT ALL - col1 DIV col1 + - col2 * - col1 AS col1 FROM tab2
----
1533
645
836

skipif mysql # not compatible
query I rowsort label-2659
SELECT ALL - col1 / col1 + - col2 * - col1 AS col1 FROM tab2
----
1533
645
836

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2660
SELECT DISTINCT + col1 + CAST( NULL AS SIGNED ) / + col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2660
SELECT DISTINCT + col1 + CAST ( NULL AS INTEGER ) / + col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - 96 col2 FROM tab0 AS cor0
----
-2304
-3360
-8544

onlyif mysql # use DIV operator for integer division
query I rowsort label-2662
SELECT col0 * 55 DIV - col1 FROM tab2 AS cor0
----
-12
-255
-72

skipif mysql # not compatible
query I rowsort label-2662
SELECT col0 * 55 / - col1 FROM tab2 AS cor0
----
-12
-255
-72

query I rowsort
SELECT DISTINCT - + col0 + col0 * col1 AS col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL col1 * col0 + + col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL - - col1 + + col1 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT - 38 * col1 + col0 FROM tab0 AS cor0
----
-3244
-3369
-3651

query I rowsort
SELECT ALL col2 + + col0 * col1 AS col1 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-2668
SELECT DISTINCT - cor0.col1 DIV col1 - cor0.col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
-1
-4

skipif mysql # not compatible
query I rowsort label-2668
SELECT DISTINCT - cor0.col1 / col1 - cor0.col2 / + col0 AS col0 FROM tab2 AS cor0
----
-1
-4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2669
SELECT DISTINCT + col1 * + col2 + + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2669
SELECT DISTINCT + col1 * + col2 + + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + - cor0.col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + col1 + + 49 * col0 FROM tab0 AS cor0
----
1262
1812
4452

query I rowsort
SELECT DISTINCT col0 + - 41 FROM tab0 AS cor0
----
-17
-6
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-2673
SELECT ALL - col0 DIV - col2 + cor0.col1 * col1 col1 FROM tab0 cor0
----
7396
8282
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2673
SELECT ALL - col0 / - col2 + cor0.col1 * col1 col1 FROM tab0 cor0
----
7396
8282
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-2674
SELECT ALL - 18 + cor0.col0 DIV col1 FROM tab2 AS cor0
----
-14
-17
-18

skipif mysql # not compatible
query I rowsort label-2674
SELECT ALL - 18 + cor0.col0 / col1 FROM tab2 AS cor0
----
-14
-17
-18

query I rowsort
SELECT col2 + - col2 * cor0.col1 FROM tab1 AS cor0
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col0 * col0 col1 FROM tab0 cor0
----
1260
600
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 14 * - col2 col1 FROM tab1 cor0
----
1344
756
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-2678
SELECT ALL - tab1.col1 DIV + col1 + col1 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-2678
SELECT ALL - tab1.col1 / + col1 + col1 FROM tab1
----
12
25
9

query I rowsort
SELECT cor0.col2 * col2 * 33 AS col0 FROM tab0 AS cor0
----
221892
33
35937

query I rowsort
SELECT DISTINCT - col2 * - cor0.col0 + col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL col0 * col2 + col1 AS col0 FROM tab0
----
132
7389
878

query I rowsort
SELECT - ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - + 55 * - 91 AS col1 FROM tab0 cor0
----
5005
5005
5005

query I rowsort
SELECT ALL tab0.col2 + - tab0.col0 FROM tab0, tab0 cor0
----
9 values hashing to 3b143560120db39ddcee311b43b28291

query I rowsort
SELECT + + col1 * 48 * + col1 AS col1 FROM tab2 cor0
----
13872
167088
46128

query I rowsort
SELECT DISTINCT + col0 * 40 FROM tab2
----
280
3120
3160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2687
SELECT DISTINCT - tab1.col0 * - tab1.col1 + + CAST( NULL AS DECIMAL ) * + 54 AS col2 FROM tab1, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2687
SELECT DISTINCT - tab1.col0 * - tab1.col1 + + CAST ( NULL AS REAL ) * + 54 AS col2 FROM tab1, tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2688
SELECT DISTINCT + + col0 DIV + col2 AS col1 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2688
SELECT DISTINCT + + col0 / + col2 AS col1 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT ALL + col0 + col2 * - 45 * + tab1.col1 FROM tab1
----
-25586
-56080
-63177

query I rowsort
SELECT + col2 + 68 * - 42 AS col2 FROM tab0 AS cor0
----
-2774
-2823
-2855

query I rowsort
SELECT col2 * - 3 FROM tab1 AS cor0
----
-162
-171
-288

query I rowsort
SELECT + + 57 + cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a54dea750a95ecb8337624650a32199e

query I rowsort
SELECT DISTINCT - col0 * 37 AS col0 FROM tab0
----
-1295
-3293
-888

query I rowsort
SELECT ALL + col0 * ( - col0 ) AS col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT + 57 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2696
SELECT + col1 / CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2696
SELECT + col1 / CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * - 63 AS col0 FROM tab2 AS cor0
----
-441
-4914
-4977

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2698
SELECT col2 * CAST( col0 AS SIGNED ) FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-2698
SELECT col2 * CAST ( col0 AS INTEGER ) FROM tab1
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2699
SELECT + + col1 * CAST( NULL AS SIGNED ) + + 72 * + col2 * + col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2699
SELECT + + col1 * CAST ( NULL AS INTEGER ) + + 72 * + col2 * + col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * col2 + col1 AS col0 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-2701
SELECT + - col2 DIV col1 + col0 col2 FROM tab1 AS cor0
----
1
59
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2701
SELECT + - col2 / col1 + col0 col2 FROM tab1 AS cor0
----
1
59
73

query I rowsort
SELECT DISTINCT - cor1.col0 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
-3
-64
-80

query I rowsort
SELECT + col1 + + 60 * col2 AS col2 FROM tab2 AS cor0
----
1619
1651
2297

onlyif mysql # use DIV operator for integer division
query I rowsort label-2704
SELECT - 88 * tab2.col2 DIV 51 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to b3477b9575bac8b11bf665cdf681f41a

skipif mysql # not compatible
query I rowsort label-2704
SELECT - 88 * tab2.col2 / 51 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to b3477b9575bac8b11bf665cdf681f41a

query I rowsort
SELECT 83 + + 34 AS col2 FROM tab2
----
117
117
117

query I rowsort
SELECT ALL col1 * - 22 FROM tab1 AS cor0
----
-220
-286
-572

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * + col1 + ( 22 ) AS col0 FROM tab1 AS cor0
----
122
191
698

query I rowsort
SELECT ( col1 ) * col0 * + 9 FROM tab1 AS cor0
----
5760
702
9360

query I rowsort
SELECT + ( 11 ) + col0 * col2 FROM tab2 AS cor0
----
200
2039
3013

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2710
SELECT CAST( + col2 AS SIGNED ) * col0 col1 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2710
SELECT CAST ( + col2 AS INTEGER ) * col0 col1 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 52 * 81 + col1 col2 FROM tab0 AS cor0
----
-4115
-4121
-4126

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 + - tab0.col1 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - - 59 * cor0.col1 AS col2 FROM tab0 AS cor0
----
5074
5369
5723

query I rowsort
SELECT - + col0 * - col1 * col1 + + col2 AS col0 FROM tab1 AS cor0
----
13616
2082
6457

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2715
SELECT - col1 + CAST( col0 * - col0 AS SIGNED ) FROM tab2 AS cor0
----
-6143
-6258
-80

skipif mysql # not compatible
query I rowsort label-2715
SELECT - col1 + CAST ( col0 * - col0 AS INTEGER ) FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT DISTINCT col1 * - 5 AS col2 FROM tab0 AS cor0
----
-430
-455
-485

query I rowsort
SELECT ALL col0 + - col2 * - ( col2 + col2 ) AS col2 FROM tab0 cor0
----
13537
2202
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-2718
SELECT + - col1 * col1 + + 46 DIV + col0 FROM tab2 cor0
----
-289
-3481
-955

skipif mysql # not compatible
query I rowsort label-2718
SELECT + - col1 * col1 + + 46 / + col0 FROM tab2 cor0
----
-289
-3481
-955

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col0 * 72 col0 FROM tab1 AS cor0
----
-216
-4608
-5760

query I rowsort
SELECT ( tab2.col0 * + ( col2 ) ) AS col2 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2721
SELECT ALL - col0 DIV + ( - col1 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2721
SELECT ALL - col0 / + ( - col1 ) FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT 88 + col2 AS col0 FROM tab0 AS cor0
----
121
170
89

query I rowsort
SELECT + ( + 83 ) * col2 AS col1 FROM tab2 AS cor0
----
2158
2241
3154

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2724
SELECT ALL + CAST( NULL AS SIGNED ) - - col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2724
SELECT ALL + CAST ( NULL AS INTEGER ) - - col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col1 - + col2 * - col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT col0 + + col1 + + col0 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT ALL - - ( - col2 ) * - col0 + col2 * + col2 FROM tab0 AS cor0
----
14022
1881
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-2728
SELECT - - cor0.col2 DIV + col0 + + col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-2728
SELECT - - cor0.col2 / + col0 + + col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT ALL - col0 + + col2 + + col2 AS col0 FROM tab0 cor0
----
-33
42
75

query I rowsort
SELECT ( col2 ) + col0 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + 10 + + col2 FROM tab0 AS cor0
----
11
43
92

query I rowsort
SELECT - col0 + - col1 - - col2 FROM tab2 AS cor0
----
-11
-111
-58

query I rowsort
SELECT ALL col2 + - col2 + cor0.col1 * col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - ( tab1.col2 ) - col2 FROM tab1
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-2735
SELECT col2 - 43 DIV + col0 col0 FROM tab1
----
40
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2735
SELECT col2 - 43 / + col0 col0 FROM tab1
----
40
57
96

query I rowsort
SELECT - col2 * col2 * - col0 + col1 FROM tab0
----
132
26222
598527

query I rowsort
SELECT ALL + ( - col0 ) + col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT col2 - + 82 AS col1 FROM tab0
----
-49
-81
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2739
SELECT ALL + + cor0.col2 * CAST( NULL AS SIGNED ) + + col0 * col2 * col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2739
SELECT ALL + + cor0.col2 * CAST ( NULL AS INTEGER ) + + col0 * col2 * col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + 79 AS col2 FROM tab2 AS cor0
----
0
1
72

query I rowsort
SELECT ALL - col1 * col1 + col0 AS col2 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT DISTINCT + col0 - - 82 * - 67 AS col2 FROM tab2 AS cor0
----
-5415
-5416
-5487

query I rowsort
SELECT DISTINCT col2 * 66 * 10 FROM tab2 AS cor0
----
17160
17820
25080

query I rowsort
SELECT - col2 * - col0 + 81 FROM tab1 AS cor0
----
243
3729
7761

query I rowsort
SELECT + col0 * 91 FROM tab0 AS cor0
----
2184
3185
8099

query I rowsort
SELECT + + cor0.col1 + 68 * col1 * - col0 FROM tab1 AS cor0
----
-43510
-5278
-70707

onlyif mysql # use DIV operator for integer division
query I rowsort label-2747
SELECT ALL col2 * col1 DIV ( - col1 ) AS col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2747
SELECT ALL col2 * col1 / ( - col1 ) AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - cor0.col2 * + col2 AS col0 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT - col0 + ( + col2 ) * col1 AS col2 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-2750
SELECT + + col2 + col1 DIV + cor0.col0 AS col2 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-2750
SELECT + + col2 + col1 / + cor0.col0 AS col2 FROM tab1 AS cor0
----
57
62
96

query I rowsort
SELECT ALL - col2 * cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT + col2 * 52 + cor0.col2 * col0 AS col0 FROM tab2 cor0
----
1593
3380
4978

query I rowsort
SELECT DISTINCT - 40 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-40

query I rowsort
SELECT 40 * ( cor0.col1 ) FROM tab1, tab2 AS cor0
----
9 values hashing to 64f3ea7789613fe9445277e8480f6b00

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2755
SELECT DISTINCT + - CAST( - 37 AS SIGNED ) + cor0.col1 FROM tab1 cor0
----
47
50
63

skipif mysql # not compatible
query I rowsort label-2755
SELECT DISTINCT + - CAST ( - 37 AS INTEGER ) + cor0.col1 FROM tab1 cor0
----
47
50
63

query I rowsort
SELECT ( - 15 ) AS col0 FROM tab0 AS cor0
----
-15
-15
-15

query I rowsort
SELECT + - col1 * col1 * col0 AS col2 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT ALL - + cor0.col1 + col1 * col2 + - col0 FROM tab1 AS cor0
----
1155
1375
496

query I rowsort
SELECT + col2 + + col0 * col2 * - col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

onlyif mysql # use DIV operator for integer division
query I rowsort label-2760
SELECT col1 DIV + col1 + col2 AS col0 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-2760
SELECT col1 / + col1 + col2 AS col0 FROM tab1
----
55
58
97

query I rowsort
SELECT tab1.col2 * - col0 + - col0 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT - col2 * col2 + - col1 * col1 FROM tab0
----
-15005
-8485
-9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col1 * col2 + col2 * - col2 col2 FROM tab2
----
118976
49590
5130

query I rowsort
SELECT DISTINCT col1 * col2 + + col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT col2 * - col1 - + tab0.col0 FROM tab0
----
-132
-2862
-7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-2766
SELECT + col2 - + col1 DIV col1 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-2766
SELECT + col2 - + col1 / col1 FROM tab0
----
0
32
81

query I rowsort
SELECT ALL col1 + col0 + col0 * + col2 AS col0 FROM tab2
----
2165
227
3098

onlyif mysql # use DIV operator for integer division
query I rowsort label-2768
SELECT DISTINCT + tab0.col0 + col0 DIV col1 AS col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2768
SELECT DISTINCT + tab0.col0 + col0 / col1 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT col0 / col1 FROM tab1 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT col1 * tab2.col1 + col0 * - tab2.col0 FROM tab2
----
-2603
-5952
912

query I rowsort
SELECT col1 + - col2 * col2 * tab1.col1 FROM tab1
----
-119795
-32480
-75790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col2 col2 FROM tab1
----
109
67
80

query I rowsort
SELECT - col0 * tab1.col2 AS col1 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col0 + - col2 + col2 FROM tab0
----
24
35
89

query I rowsort
SELECT + col0 - + col1 AS col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT + col0 - - col0 * + col0 AS col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT - col0 * - col1 * + col1 + - col2 AS col1 FROM tab2 AS cor0
----
22793
271492
6700

query I rowsort
SELECT 4 * col0 + + col2 FROM tab0 AS cor0
----
129
141
438

query I rowsort
SELECT DISTINCT ( col1 ) + + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + cor1.col0 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT col1 + col0 * + col2 AS col2 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-2782
SELECT - col1 DIV - col0 + + col0 + + col2 AS col2 FROM tab1
----
121
176
65

skipif mysql # not compatible
query I rowsort label-2782
SELECT - col1 / - col0 + + col0 + + col2 AS col2 FROM tab1
----
121
176
65

query I rowsort
SELECT ALL col2 * - tab0.col1 AS col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT + tab1.col0 + col2 * - col2 + col0 AS col2 FROM tab1
----
-2910
-3121
-9056

query I rowsort
SELECT ALL + + col0 * cor0.col0 + - col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT ALL + ( cor0.col1 ) * 84 + col1 FROM tab1 cor0
----
1105
2210
850

query I rowsort
SELECT - 20 + col1 FROM tab2 cor0
----
-3
11
39

query I rowsort
SELECT + - 29 AS col2 FROM tab1 AS cor0
----
-29
-29
-29

query I rowsort
SELECT ALL - + col2 * col1 + - 52 + - col0 AS col1 FROM tab0 AS cor0
----
-184
-2914
-7603

query I rowsort
SELECT DISTINCT 25 + + col1 FROM tab0 AS cor0
----
111
116
122

query I rowsort
SELECT - 0 * col0 * - ( col2 ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - 1 * - col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + 35 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
35

query I rowsort
SELECT + - col0 * col1 + col1 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT 36 * col0 FROM tab0
----
1260
3204
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-2796
SELECT - - col0 DIV col2 - col1 * col1 AS col2 FROM tab1 AS cor0
----
-169
-676
-99

skipif mysql # not compatible
query I rowsort label-2796
SELECT - - col0 / col2 - col1 * col1 AS col2 FROM tab1 AS cor0
----
-169
-676
-99

query I rowsort
SELECT DISTINCT + col1 + - 56 AS col1 FROM tab1
----
-30
-43
-46

query I rowsort
SELECT + col1 * 26 * + col2 FROM tab1
----
14820
32448
36504

query I rowsort
SELECT + + 89 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT DISTINCT + 14 AS col0 FROM tab0, tab0 AS cor0
----
14

query I rowsort
SELECT DISTINCT col2 + ( + col0 ) FROM tab1
----
121
176
57

query I rowsort
SELECT - col1 * - col1 * + col0 AS col0 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT - tab0.col0 + col2 AS col1 FROM tab0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 1 col0 FROM tab2
----
7
78
79

query I rowsort
SELECT - ( ( - col1 ) ) + - 71 FROM tab0
----
15
20
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2806
SELECT ALL CAST( NULL AS DECIMAL ) * + 35 + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2806
SELECT ALL CAST ( NULL AS REAL ) * + 35 + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2807
SELECT - ( + cor0.col0 ) DIV 76 + tab1.col2 FROM tab1, tab0 cor0
----
9 values hashing to ea32a811a416c4f9b9098d43c164e326

skipif mysql # not compatible
query I rowsort label-2807
SELECT - ( + cor0.col0 ) / 76 + tab1.col2 FROM tab1, tab0 cor0
----
9 values hashing to ea32a811a416c4f9b9098d43c164e326

query I rowsort
SELECT 80 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT - - col2 - - col0 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - 52 * - 62 FROM tab1
----
3224
3224
3224

query I rowsort
SELECT ALL + 1 * + col1 FROM tab2
----
17
31
59

query I rowsort
SELECT 63 + + col2 FROM tab2 AS cor0
----
101
89
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2813
SELECT + col0 * 17 DIV tab1.col0 AS col2 FROM tab1
----
17
17
17

skipif mysql # not compatible
query I rowsort label-2813
SELECT + col0 * 17 / tab1.col0 AS col2 FROM tab1
----
17
17
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2814
SELECT CAST( NULL AS DECIMAL ) AS col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2814
SELECT CAST ( NULL AS REAL ) AS col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT ( col2 ) * tab2.col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT col0 * - col2 + + col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT ALL + 34 + + col2 AS col2 FROM tab2
----
60
61
72

query I rowsort
SELECT 47 - col0 * - col0 FROM tab1
----
4143
56
6447

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2819
SELECT - ( + tab1.col0 ) * + CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2819
SELECT - ( + tab1.col0 ) * + CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2820
SELECT col0 * - col1 * CAST( col0 AS SIGNED ) + + col0 - + col1 * - cor0.col1 FROM tab1 AS cor0
----
-40796
-82951
445

skipif mysql # not compatible
query I rowsort label-2820
SELECT col0 * - col1 * CAST ( col0 AS INTEGER ) + + col0 - + col1 * - cor0.col1 FROM tab1 AS cor0
----
-40796
-82951
445

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2821
SELECT - CAST( tab2.col0 AS SIGNED ) AS col2 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to adaea38eae032c1639715f21831dd376

skipif mysql # not compatible
query I rowsort label-2821
SELECT - CAST ( tab2.col0 AS INTEGER ) AS col2 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to adaea38eae032c1639715f21831dd376

query I rowsort
SELECT DISTINCT col0 * col0 * + 76 FROM tab2
----
3724
462384
474316

query I rowsort
SELECT + 8 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to a42c42e56e75960d97c09dd731d99c01

query I rowsort
SELECT - col1 + 4 AS col2 FROM tab1 cor0
----
-22
-6
-9

query I rowsort
SELECT 22 AS col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT 76 + cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 6eb06975d1c20d9170e94643546f316a

query I rowsort
SELECT + col0 * - ( 47 ) AS col0 FROM tab2 AS cor0
----
-329
-3666
-3713

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col0 ) + + col2 * col2 col0 FROM tab1 AS cor0
----
2913
3185
9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2829
SELECT DISTINCT CAST( NULL AS SIGNED ) - col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2829
SELECT DISTINCT CAST ( NULL AS INTEGER ) - col0 FROM tab0
----
NULL

query I rowsort
SELECT - cor0.col2 + 64 AS col1 FROM tab0 cor0
----
-18
31
63

query I rowsort
SELECT 58 + - 52 AS col1 FROM tab1 AS cor0
----
6
6
6

query I rowsort
SELECT DISTINCT - - ( + cor0.col2 ) FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( 54 ) * col1 col1 FROM tab1 AS cor0
----
-1404
-540
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-2834
SELECT col2 DIV 80 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-2834
SELECT col2 / 80 col1 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT 81 + + cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to eb7e09d56aeb6b294bc773efb05e889c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 41 ) * col1 * col1 col1 FROM tab2 AS cor0
----
11849
142721
39401

query I rowsort
SELECT - 50 * cor0.col0 FROM tab0 AS cor0
----
-1200
-1750
-4450

query I rowsort
SELECT ALL + + 0 * 19 + col1 AS col2 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2839
SELECT DISTINCT - col2 + col1 DIV col0 AS col1 FROM tab0 AS cor0
----
-30
-81
1

skipif mysql # not compatible
query I rowsort label-2839
SELECT DISTINCT - col2 + col1 / col0 AS col1 FROM tab0 AS cor0
----
-30
-81
1

query I rowsort
SELECT ALL 59 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT ALL + ( 61 ) + cor0.col0 * - 46 AS col0 FROM tab1 AS cor0
----
-2883
-3619
-77

query I rowsort
SELECT - + col2 * + 33 FROM tab0 AS cor0
----
-1089
-2706
-33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2843
SELECT DISTINCT CAST( + 20 AS SIGNED ) FROM tab0 AS cor0
----
20

skipif mysql # not compatible
query I rowsort label-2843
SELECT DISTINCT CAST ( + 20 AS INTEGER ) FROM tab0 AS cor0
----
20

query I rowsort
SELECT - - col1 * - ( col0 ) * + 33 AS col2 FROM tab2 AS cor0
----
-151866
-44319
-7161

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col0 ) + col0 col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + col0 * ( + 15 ) AS col2 FROM tab2
----
1111
1168
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-2847
SELECT ALL col1 + col2 * + col1 + 33 DIV col0 AS col1 FROM tab2
----
1593
663
872

skipif mysql # not compatible
query I rowsort label-2847
SELECT ALL col1 + col2 * + col1 + 33 / col0 AS col1 FROM tab2
----
1593
663
872

query I rowsort
SELECT + 36 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT ALL + ( + tab2.col0 ) + col0 * tab2.col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT DISTINCT - 11 + - col0 AS col1 FROM tab1 AS cor0
----
-14
-75
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 41 + col1 col0 FROM tab0 AS cor0
----
127
132
138

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2852
SELECT + + cor0.col2 * + col0 * CAST( NULL AS SIGNED ) - - 4 * cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2852
SELECT + + cor0.col2 * + col0 * CAST ( NULL AS INTEGER ) - - 4 * cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 + col0 * - 94 * + col0 FROM tab1 AS cor0
----
-385014
-601587
-820

query I rowsort
SELECT DISTINCT ( + col1 ) * ( 2 ) + tab0.col2 FROM tab0
----
195
205
264

query I rowsort
SELECT DISTINCT - 33 FROM tab0, tab2 cor0, tab2 AS cor1
----
-33

query I rowsort
SELECT - col2 * col1 - - 83 * + col1 FROM tab2 AS cor0
----
1736
3363
765

query I rowsort
SELECT + - col1 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + - col1 + col2 * col2 FROM tab2 AS cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-2859
SELECT DISTINCT - col0 DIV col1 AS col0 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2859
SELECT DISTINCT - col0 / col1 AS col0 FROM tab2 cor0
----
-1
-4
0

query I rowsort
SELECT cor0.col2 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 * + col2 + - cor0.col2 * 77 col1 FROM tab1 AS cor0
----
203547
4590
729888

query I rowsort
SELECT + col1 * + col2 * + 73 AS col0 FROM tab2 AS cor0
----
111982
47158
61101

query I rowsort
SELECT + + cor0.col1 * ( + ( cor0.col2 ) ) AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + col1 * + 13 AS col2 FROM tab1 AS cor0
----
130
169
338

query I rowsort
SELECT DISTINCT - col2 * 77 AS col1 FROM tab2 cor0
----
-2002
-2079
-2926

onlyif mysql # use DIV operator for integer division
query I rowsort label-2866
SELECT ALL col1 + ( + col2 ) DIV col1 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-2866
SELECT ALL col1 + ( + col2 ) / col1 FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT ALL col1 * col1 * + col0 AS col2 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT + - col2 * col1 + - col0 AS col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT ALL - cor0.col2 + - 49 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1650
-4100
-50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * cor0.col1 * - col2 col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT 13 * + col2 + col1 + - col1 AS col1 FROM tab0 AS cor0
----
1066
13
429

query I rowsort
SELECT + ( col1 ) * col1 AS col2 FROM tab1 cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2873
SELECT 82 DIV + col0 + col0 + col0 col1 FROM tab0 AS cor0
----
178
51
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2873
SELECT 82 / + col0 + col0 + col0 col1 FROM tab0 AS cor0
----
178
51
72

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( col2 AS REAL ) + - col0 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT tab1.col1 + ( 50 + - col1 ) * col0 FROM tab1
----
2570
2973
98

query I rowsort
SELECT col2 * - col1 * + 68 FROM tab1
----
-38760
-84864
-95472

query I rowsort
SELECT DISTINCT - - col1 + + col2 * - ( + col0 ) AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL - + 2 * col0 AS col2 FROM tab0 cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col0 - col2 col0 FROM tab1 AS cor0
----
-25
-3
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 11 + cor0.col1 col0 FROM tab0 AS cor0
----
75
80
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + cor0.col2 col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - 52 + - col0 AS col2 FROM tab2 AS cor0
----
-130
-131
-59

query I rowsort
SELECT DISTINCT + 55 + + col2 FROM tab0 AS cor0
----
137
56
88

query I rowsort
SELECT DISTINCT - - ( col1 ) * + col1 AS col0 FROM tab1 cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2885
SELECT ALL + ( - col1 ) DIV + col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-2885
SELECT ALL + ( - col1 ) / + col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT + 94 AS col2 FROM tab2
----
94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2887
SELECT DISTINCT col2 / + col1 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2887
SELECT DISTINCT col2 / + col1 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT + cor0.col1 * + col0 + + 72 FROM tab2 AS cor0
----
1415
289
4674

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2889
SELECT + + 33 - + col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2889
SELECT + + 33 - + col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * + col1 - + 93 * col0 FROM tab1 cor0
----
-5852
-7271
397

query I rowsort
SELECT ALL ( col1 ) + 93 AS col2 FROM tab1 AS cor0
----
103
106
119

query I rowsort
SELECT - + col1 * - col2 - 59 AS col0 FROM tab0 AS cor0
----
2779
38
7403

onlyif mysql # use DIV operator for integer division
query I rowsort label-2893
SELECT + 67 DIV col0 AS col2 FROM tab1
----
0
1
22

skipif mysql # not compatible
query I rowsort label-2893
SELECT + 67 / col0 AS col2 FROM tab1
----
0
1
22

query I rowsort
SELECT ALL tab2.col2 + + col2 * tab2.col1 AS col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT + ( 49 ) * col1 FROM tab0
----
4214
4459
4753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2896
SELECT + CAST( NULL AS SIGNED ) + - col0 * - col1 + ( 92 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2896
SELECT + CAST ( NULL AS INTEGER ) + - col0 * - col1 + ( 92 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + 56 ) AS col0 FROM tab0
----
-56
-56
-56

query I rowsort
SELECT + 47 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1222
-1269
-1786

query I rowsort
SELECT - ( - col2 ) * + col0 * + col2 AS col0 FROM tab1 cor0
----
207936
737280
8748

query I rowsort
SELECT DISTINCT - col2 * + col0 + - 5 FROM tab1
----
-167
-3653
-7685

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 + col1 col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT + + col0 * + cor0.col1 * + 1 + + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - + col0 * col2 * + 85 + + col2 FROM tab1 AS cor0
----
-13716
-310023
-652704

onlyif mysql # use DIV operator for integer division
query I rowsort label-2904
SELECT ALL - + col0 + - cor0.col1 DIV + 64 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2904
SELECT ALL - + col0 + - cor0.col1 / + 64 FROM tab1 AS cor0
----
-3
-64
-80

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 cor0, tab0, tab0 cor1
----
972 values hashing to 8b4fcda7f1ca76bad7c7d728f54a51e0

query I rowsort
SELECT - col0 * + ( - 21 ) + + col1 * col2 AS col2 FROM tab1 cor0
----
1467
1914
2928

query I rowsort
SELECT DISTINCT - + col0 * col0 + + col1 * col2 AS col0 FROM tab0 AS cor0
----
-1128
-459
2262

query I rowsort
SELECT - col0 + - 8 AS col1 FROM tab1 AS cor0
----
-11
-72
-88

query I rowsort
SELECT - cor0.col2 - col2 AS col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT + ( + cor0.col1 ) + + col0 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT cor0.col0 AS col2 FROM tab2, tab2 cor0, tab1, tab0 AS cor1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab1 cor1
----
972 values hashing to f8fe28681e8720551e1ec173631fc529

query I rowsort
SELECT + + 11 * col0 + - col0 FROM tab0 AS cor0
----
240
350
890

query I rowsort
SELECT - - 61 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1586
610
793

query I rowsort
SELECT DISTINCT + + col1 * - col2 - + col1 AS col0 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-2916
SELECT ALL + ( 77 ) + cor0.col2 DIV col2 FROM tab0 AS cor0
----
78
78
78

skipif mysql # not compatible
query I rowsort label-2916
SELECT ALL + ( 77 ) + cor0.col2 / col2 FROM tab0 AS cor0
----
78
78
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2917
SELECT ALL + CAST( - col0 AS SIGNED ) + - col0 * 60 FROM tab1 AS cor0
----
-183
-3904
-4880

skipif mysql # not compatible
query I rowsort label-2917
SELECT ALL + CAST ( - col0 AS INTEGER ) + - col0 * 60 FROM tab1 AS cor0
----
-183
-3904
-4880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2918
SELECT DISTINCT - CAST( 73 AS SIGNED ) - col2 * col2 FROM tab0 AS cor0
----
-1162
-6797
-74

skipif mysql # not compatible
query I rowsort label-2918
SELECT DISTINCT - CAST ( 73 AS INTEGER ) - col2 * col2 FROM tab0 AS cor0
----
-1162
-6797
-74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + 66 col0 FROM tab0 AS cor0
----
148
67
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2920
SELECT ALL + CAST( NULL AS SIGNED ) * + col0 + + col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2920
SELECT ALL + CAST ( NULL AS INTEGER ) * + col0 + + col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 86 * - col1 FROM tab0 AS cor0
----
-7396
-7826
-8342

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 + - col0 + col0 col1 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2923
SELECT DISTINCT - - cor0.col0 DIV + col0 AS col1 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-2923
SELECT DISTINCT - - cor0.col0 / + col0 AS col1 FROM tab1 cor0
----
1

query I rowsort
SELECT ALL - ( 61 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 51f53697966a79d306a4570537cd91a1

query I rowsort
SELECT ALL 63 FROM tab1, tab0 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT DISTINCT col1 * ( col0 ) + col2 * + 89 + cor0.col2 * col0 AS col1 FROM tab2 AS cor0
----
2809
7727
8944

query I rowsort
SELECT ALL col0 * + ( - col0 ) + col2 AS col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT 64 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
64

query I rowsort
SELECT DISTINCT tab0.col2 * - tab0.col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT 60 + 64 FROM tab0, tab1 AS cor0
----
9 values hashing to f95a510ef7a720583a4639131b2cccc3

query I rowsort
SELECT + col0 * 60 AS col2 FROM tab2 AS cor0
----
420
4680
4740

query I rowsort
SELECT DISTINCT - 97 + + col2 * + 45 AS col1 FROM tab1 cor0
----
2333
2468
4223

query I rowsort
SELECT DISTINCT + col1 * + cor0.col1 + - col2 * - 68 * cor0.col2 AS col0 FROM tab0 cor0
----
465513
81448
9477

query I rowsort
SELECT DISTINCT + 95 * col1 + - ( cor0.col1 ) AS col0 FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT DISTINCT + ( + ( + col0 ) ) * col1 * + col1 + col2 + tab0.col0 AS col1 FROM tab0
----
177561
329351
737180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 98 + col0 * ( tab2.col0 ) * col2 col2 FROM tab2
----
1421
158282
237256

query I rowsort
SELECT - + col1 * - cor0.col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT col1 * col2 + - col2 AS col2 FROM tab1
----
1152
1350
513

query I rowsort
SELECT - 88 * col1 FROM tab0
----
-7568
-8008
-8536

query I rowsort
SELECT ALL 82 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT DISTINCT col1 * 71 * col2 AS col1 FROM tab2
----
108914
45866
59427

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col2 ) * + col1 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + 94 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT ALL col2 * 97 AS col2 FROM tab0
----
3201
7954
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2945
SELECT ALL - CAST( NULL AS SIGNED ) * + 37 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2945
SELECT ALL - CAST ( NULL AS INTEGER ) * + 37 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + - col2 + col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT 77 + - 35 * + col2 FROM tab1 AS cor0
----
-1813
-1918
-3283

query I rowsort
SELECT + col2 * cor0.col2 AS col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + - ( - ( col0 ) ) * col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-2950
SELECT - ( + col0 ) DIV + col0 + col1 + - col1 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2950
SELECT - ( + col0 ) / + col0 + col1 + - col1 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + + col2 * col1 AS col1 FROM tab2 cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * 38 + col1 col2 FROM tab1 AS cor0
----
-2422
-3027
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-2953
SELECT - 15 DIV + col0 + col0 + col2 col1 FROM tab2 AS cor0
----
104
117
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2953
SELECT - 15 / + col0 + col0 + col2 col1 FROM tab2 AS cor0
----
104
117
32

query I rowsort
SELECT DISTINCT - 9 + 22 * - col1 * + 24 AS col0 FROM tab2 cor0
----
-16377
-31161
-8985

query I rowsort
SELECT ALL + ( + col0 ) * - col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - - col1 * ( - col2 ) AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2957
SELECT DISTINCT col0 DIV + 33 AS col1 FROM tab1 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2957
SELECT DISTINCT col0 / + 33 AS col1 FROM tab1 AS cor0
----
0
1
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2958
SELECT CAST( NULL AS SIGNED ) * - 16 + - col1 - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2958
SELECT CAST ( NULL AS INTEGER ) * - 16 + - col1 - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 * + 78 * - col1 + col1 * col2 AS col1 FROM tab1 AS cor0
----
14430
54132
8370

query I rowsort
SELECT ALL - + 33 + + col0 AS col1 FROM tab0 AS cor0
----
-9
2
56

query I rowsort
SELECT DISTINCT + ( - tab2.col0 * + col0 ) + 40 FROM tab2
----
-6044
-6201
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2962
SELECT 43 DIV - tab0.col1 + - tab0.col0 + tab0.col2 col0 FROM tab0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2962
SELECT 43 / - tab0.col1 + - tab0.col0 + tab0.col2 col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + ( - 75 ) + - col2 + col0 * - 5 * + col0 FROM tab0
----
-2988
-39762
-6201

onlyif mysql # use DIV operator for integer division
query I rowsort label-2964
SELECT DISTINCT + col0 * col0 * - cor0.col1 + + col1 DIV col0 AS col0 FROM tab0 cor0
----
-118823
-49533
-720810

skipif mysql # not compatible
query I rowsort label-2964
SELECT DISTINCT + col0 * col0 * - cor0.col1 + + col1 / col0 AS col0 FROM tab0 cor0
----
-118823
-49533
-720810

query I rowsort
SELECT DISTINCT + + cor0.col1 + cor0.col0 FROM tab0 cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + 43 col0 FROM tab1 AS cor0
----
100
139
97

query I rowsort
SELECT ALL + col0 + - 64 AS col2 FROM tab1 AS cor0
----
-61
0
16

query I rowsort
SELECT ALL + - 35 * + col2 + col0 AS col0 FROM tab2 AS cor0
----
-1251
-832
-938

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 + - col1 + - col0 col0 FROM tab1
----
-24
-43
21

query I rowsort
SELECT DISTINCT - col2 * 66 + col0 AS col2 FROM tab1 AS cor0
----
-3561
-3698
-6256

query I rowsort
SELECT + + 99 * + col0 * + col0 + - col0 FROM tab1 AS cor0
----
405440
633520
888

query I rowsort
SELECT ALL - 18 + cor0.col0 * + 21 AS col2 FROM tab2 AS cor0
----
129
1620
1641

query I rowsort
SELECT ALL + 9 + col2 * + ( - ( + col1 ) ) * - cor0.col2 AS col0 FROM tab1 AS cor0
----
119817
32499
75825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2974
SELECT ALL + col1 + - cor0.col1 + + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2974
SELECT ALL + col1 + - cor0.col1 + + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2975
SELECT ALL + col2 + col2 DIV 23 AS col2 FROM tab1 AS cor0
----
100
56
59

skipif mysql # not compatible
query I rowsort label-2975
SELECT ALL + col2 + col2 / 23 AS col2 FROM tab1 AS cor0
----
100
56
59

query I rowsort
SELECT + + 12 + col2 AS col2 FROM tab2 AS cor0
----
38
39
50

query I rowsort
SELECT ALL - + 86 + col2 FROM tab1 AS cor0
----
-29
-32
10

query I rowsort
SELECT ALL 89 + col2 FROM tab0
----
122
171
90

query I rowsort
SELECT ALL + col0 * ( col1 ) + + col0 FROM tab1
----
1120
704
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2980
SELECT - col0 * + col2 * CAST( + col1 AS SIGNED ) + col2 - col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

skipif mysql # not compatible
query I rowsort label-2980
SELECT - col0 * + col2 * CAST ( + col1 AS INTEGER ) + col2 - col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT 77 AS col2 FROM tab1 cor0
----
77
77
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + + cor0.col1 col2 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 * - 18 col1 FROM tab0 AS cor0
----
1548
1638
1746

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - 28 col0 FROM tab0 AS cor0
----
-4
61
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2985
SELECT ALL + - col0 + - col1 DIV + col0 AS col1 FROM tab0 cor0
----
-27
-37
-90

skipif mysql # not compatible
query I rowsort label-2985
SELECT ALL + - col0 + - col1 / + col0 AS col1 FROM tab0 cor0
----
-27
-37
-90

query I rowsort
SELECT - col0 * + 77 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT ALL col2 + 30 FROM tab0 cor0
----
112
31
63

query I rowsort
SELECT DISTINCT + + col2 - + 58 * col0 AS col0 FROM tab1 AS cor0
----
-120
-3655
-4544

query I rowsort
SELECT ALL col0 + - col1 * + ( + col1 ) FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL + cor0.col2 * + 24 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 34f703c7deea980a49ff48de24d80e35

query I rowsort
SELECT ALL - - col1 + - 49 * col0 AS col1 FROM tab1 AS cor0
----
-121
-3126
-3907

query I rowsort
SELECT DISTINCT col1 * col2 - + col1 AS col2 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-2993
SELECT col0 DIV + col1 + - col0 * col2 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-2993
SELECT col0 / + col1 + - col0 * col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL + ( col2 ) * 68 AS col2 FROM tab2
----
1768
1836
2584

query I rowsort
SELECT + 22 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT DISTINCT + 95 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
95

query I rowsort
SELECT ALL 64 * cor0.col2 + - 22 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to c401837d67cb45947523b9b902d80b2c

query I rowsort
SELECT 94 * 29 + tab1.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 23778dbcbe1db007de5251bd036b898b

query I rowsort
SELECT + col2 + + col1 * ( - col1 ) FROM tab2 AS cor0
----
-251
-3455
-934

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3000
SELECT col1 * - CAST( - col2 AS SIGNED ) - col1 * cor0.col1 FROM tab0 cor0
----
-4558
-819
-9312

skipif mysql # not compatible
query I rowsort label-3000
SELECT col1 * - CAST ( - col2 AS INTEGER ) - col1 * cor0.col1 FROM tab0 cor0
----
-4558
-819
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3001
SELECT - col2 * CAST( 39 AS SIGNED ) FROM tab2 AS cor0
----
-1014
-1053
-1482

skipif mysql # not compatible
query I rowsort label-3001
SELECT - col2 * CAST ( 39 AS INTEGER ) FROM tab2 AS cor0
----
-1014
-1053
-1482

query I rowsort
SELECT + tab2.col2 + col0 * + col1 FROM tab2
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-3003
SELECT ALL - ( 34 ) DIV - col0 + + 64 + col1 FROM tab0 AS cor0
----
151
155
161

skipif mysql # not compatible
query I rowsort label-3003
SELECT ALL - ( 34 ) / - col0 + + 64 + col1 FROM tab0 AS cor0
----
151
155
161

query I rowsort
SELECT DISTINCT 21 * col1 FROM tab2 AS cor0
----
1239
357
651

query I rowsort
SELECT ALL - 23 * col1 AS col2 FROM tab2 cor0
----
-1357
-391
-713

query I rowsort
SELECT DISTINCT + ( 42 ) FROM tab1 AS cor0
----
42

query I rowsort
SELECT cor0.col1 * + col1 + cor0.col2 * 86 AS col1 FROM tab2 AS cor0
----
3283
3557
5717

query I rowsort
SELECT ALL + - ( col0 ) * col1 * 25 + + 22 + - col2 * 8 AS col0 FROM tab1 AS cor0
----
-16434
-2360
-26746

query I rowsort
SELECT + cor0.col0 * cor0.col0 + col2 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT - 52 * + col2 + col2 FROM tab0 AS cor0
----
-1683
-4182
-51

query I rowsort
SELECT - 21 + - col0 * col1 FROM tab2 AS cor0
----
-1364
-238
-4623

query I rowsort
SELECT + - col0 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - 65 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
-27
-38
-39

query I rowsort
SELECT ALL 30 + cor0.col1 AS col2 FROM tab1 AS cor0
----
40
43
56

query I rowsort
SELECT + + 36 FROM tab1 AS cor0
----
36
36
36

query I rowsort
SELECT ALL - 39 FROM tab2, tab1 AS cor0, tab2 cor1, tab0, tab2 AS cor2
----
243 values hashing to f858e77b142533ef12769a6216157632

query I rowsort
SELECT DISTINCT - cor0.col1 + 39 AS col1 FROM tab2, tab2 AS cor0
----
-20
22
8

query I rowsort
SELECT - col1 * ( - 71 ) * + col1 AS col2 FROM tab0 AS cor0
----
525116
587951
668039

query I rowsort
SELECT DISTINCT - col0 * ( col1 ) + + col0 FROM tab1 AS cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - 81 + col0 col1 FROM tab0 AS cor0
----
-6942
-7282
-7822

query I rowsort
SELECT - col0 * cor0.col2 * - ( + col2 ) FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT + 42 * - col1 + - cor0.col0 + col1 FROM tab0 AS cor0
----
-3550
-3820
-4012

query I rowsort
SELECT ( 5 ) * col0 + col1 AS col2 FROM tab1 cor0
----
330
41
413

query I rowsort
SELECT + + col0 * 56 + col2 AS col1 FROM tab0 AS cor0
----
1377
1961
5066

query I rowsort
SELECT - 42 * + 45 FROM tab0
----
-1890
-1890
-1890

query I rowsort
SELECT DISTINCT - col1 - col1 * col1 AS col0 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT DISTINCT 40 * col1 AS col2 FROM tab0 AS cor0
----
3440
3640
3880

onlyif mysql # use DIV operator for integer division
query I rowsort label-3028
SELECT DISTINCT + col2 + - col0 DIV col2 AS col2 FROM tab0 AS cor0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-3028
SELECT DISTINCT + col2 + - col0 / col2 AS col2 FROM tab0 AS cor0
----
-34
33
81

query I rowsort
SELECT ALL + - 69 * col0 + + col2 AS col2 FROM tab1 AS cor0
----
-153
-4359
-5424

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + col0 - 81 * col1 col1 FROM tab1 AS cor0
----
-13
-170
-2028

query I rowsort
SELECT DISTINCT 99 * - col2 + + col2 AS col0 FROM tab0
----
-3234
-8036
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3032
SELECT ALL - + col2 + 87 + col0 DIV col1 FROM tab1 AS cor0
----
-3
33
36

skipif mysql # not compatible
query I rowsort label-3032
SELECT ALL - + col2 + 87 + col0 / col1 FROM tab1 AS cor0
----
-3
33
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-3033
SELECT - col0 DIV - 7 FROM tab0 cor0
----
12
3
5

skipif mysql # not compatible
query I rowsort label-3033
SELECT - col0 / - 7 FROM tab0 cor0
----
12
3
5

query I rowsort
SELECT col0 * ( 64 ) + + col0 AS col0 FROM tab1 AS cor0
----
195
4160
5200

query I rowsort
SELECT DISTINCT + col0 + - 41 * + col2 * + col0 FROM tab2 AS cor0
----
-123003
-7742
-83070

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3036
SELECT ALL - col1 + + CAST( - col2 AS SIGNED ) FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-3036
SELECT ALL - col1 + + CAST ( - col2 AS INTEGER ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL - col1 * 30 + cor0.col0 + cor0.col2 FROM tab1 AS cor0
----
-179
-214
-723

query I rowsort
SELECT DISTINCT + cor0.col0 + + col2 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - + col0 * col2 + - col2 * - col0 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL cor0.col2 * 70 FROM tab0 AS cor0
----
2310
5740
70

query I rowsort
SELECT + col1 + 20 * + 7 * col2 - cor0.col0 AS col2 FROM tab0 AS cor0
----
11482
202
4682

query I rowsort
SELECT DISTINCT + col2 * + col2 + - cor0.col2 + col1 * + col0 AS col1 FROM tab2 AS cor0
----
2749
5252
919

query I rowsort
SELECT DISTINCT cor0.col0 * + col0 + + 84 FROM tab1 AS cor0
----
4180
6484
93

query I rowsort
SELECT - col2 - + col2 * - ( + col2 ) AS col0 FROM tab0 cor0
----
0
1056
6642

query I rowsort
SELECT - col1 + ( + col2 + col1 * cor0.col1 ) AS col2 FROM tab1 cor0
----
147
252
704

query I rowsort
SELECT + 27 * col1 + + cor0.col1 FROM tab2 AS cor0
----
1652
476
868

query I rowsort
SELECT ALL + 22 * + col1 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT DISTINCT col0 * ( + col0 ) AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL col2 + col1 * col0 + - col2 * col0 AS col0 FROM tab2
----
-1621
2600
55

query I rowsort
SELECT col0 + col1 * col1 + col0 AS col1 FROM tab2
----
3637
447
975

onlyif mysql # use DIV operator for integer division
query I rowsort label-3051
SELECT col1 DIV - ( col1 ) col2 FROM tab2
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3051
SELECT col1 / - ( col1 ) col2 FROM tab2
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3052
SELECT col1 DIV col0 AS col0 FROM tab1 cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-3052
SELECT col1 / col0 AS col0 FROM tab1 cor0
----
0
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3053
SELECT + tab2.col2 - col1 DIV - col1 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-3053
SELECT + tab2.col2 - col1 / - col1 FROM tab2
----
27
28
39

query I rowsort
SELECT DISTINCT + + 80 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1920
2800
7120

query I rowsort
SELECT ALL - + col2 + + col0 * + col0 * + col2 FROM tab2 AS cor0
----
1296
158158
237120

query I rowsort
SELECT ALL 59 + - col0 * 8 + 5 * col2 AS col0 FROM tab1 AS cor0
----
-101
-168
305

query I rowsort
SELECT DISTINCT col2 + + col2 * col0 * 0 AS col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3058
SELECT ALL 44 DIV + col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3058
SELECT ALL 44 / + col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 * cor0.col0 + 17 FROM tab1 cor0
----
-1023
-61
-623

query I rowsort
SELECT ALL - + col1 + - ( - col0 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT col1 * - tab2.col1 + col2 AS col2 FROM tab2
----
-251
-3455
-934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL 37 * + col0 * - col0 FROM tab1
----
-151552
-236800
-333

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + tab1.col2 * col0 col1 FROM tab1
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col2 col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL + + col0 + - col1 * col1 AS col2 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT + ( col1 ) * tab2.col1 * col0 AS col2 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT + col2 + 47 FROM tab0
----
129
48
80

query I rowsort
SELECT col2 * 55 FROM tab2
----
1430
1485
2090

query I rowsort
SELECT + ( 0 ) + + col2 FROM tab0
----
1
33
82

query I rowsort
SELECT col1 * + ( col1 ) + col2 FROM tab2
----
327
3507
988

query I rowsort
SELECT + 61 + 31 AS col1 FROM tab2
----
92
92
92

query I rowsort
SELECT + 8 * + col2 + + col0 AS col1 FROM tab0
----
288
43
745

query I rowsort
SELECT ALL - col0 * - 35 + col0 * - col0 + col0 AS col2 FROM tab0
----
-4717
288
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-3075
SELECT col2 * col0 + col1 DIV tab0.col0 FROM tab0
----
37
7299
795

skipif mysql # not compatible
query I rowsort label-3075
SELECT col2 * col0 + col1 / tab0.col0 FROM tab0
----
37
7299
795

onlyif mysql # use DIV operator for integer division
query I rowsort label-3076
SELECT DISTINCT + col1 DIV - col1 + tab2.col0 + col1 FROM tab2
----
136
37
95

skipif mysql # not compatible
query I rowsort label-3076
SELECT DISTINCT + col1 / - col1 + tab2.col0 + col1 FROM tab2
----
136
37
95

query I rowsort
SELECT ALL col1 + - col2 * col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3078
SELECT - - CAST( + col0 AS SIGNED ) + + col0 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-3078
SELECT - - CAST ( + col0 AS INTEGER ) + + col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL - - cor0.col2 + + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - 78 + + 9 FROM tab0 cor0
----
-69
-69
-69

query I rowsort
SELECT DISTINCT - col0 * + col2 + cor0.col1 * cor0.col2 - - col1 AS col0 FROM tab0 AS cor0
----
159
2132
255

onlyif mysql # use DIV operator for integer division
query I rowsort label-3082
SELECT DISTINCT - col2 DIV + col1 + col0 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-3082
SELECT DISTINCT - col2 / + col1 + col0 FROM tab2 AS cor0
----
7
77
78

query I rowsort
SELECT 58 * col2 AS col2 FROM tab0 AS cor0
----
1914
4756
58

query I rowsort
SELECT + 18 + + col1 AS col1 FROM tab0 AS cor0
----
104
109
115

query I rowsort
SELECT - + col0 * + col0 + col0 FROM tab2 AS cor0
----
-42
-6006
-6162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3086
SELECT + CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3086
SELECT + CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 21 + - col2 AS col1 FROM tab1 AS cor0
----
-33
-36
-75

query I rowsort
SELECT 20 + cor1.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 15131b2f8a8fbb3498fea021d1cfc917

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3089
SELECT ALL CAST( + 21 AS SIGNED ) + col1 AS col2 FROM tab0 AS cor0
----
107
112
118

skipif mysql # not compatible
query I rowsort label-3089
SELECT ALL CAST ( + 21 AS INTEGER ) + col1 AS col2 FROM tab0 AS cor0
----
107
112
118

query I rowsort
SELECT 91 + col1 FROM tab2 cor0
----
108
122
150

query I rowsort
SELECT DISTINCT col1 * col2 + - col0 * 75 AS col2 FROM tab1 AS cor0
----
-4230
-4752
1179

query I rowsort
SELECT DISTINCT + - col2 * col0 + - col2 * 75 * + col0 AS col1 FROM tab0 cor0
----
-2660
-554648
-60192

query I rowsort
SELECT + + col1 * - col0 * - col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - 77 * 65 FROM tab2
----
-5005

query I rowsort
SELECT col0 * + col0 * col2 + col1 * - ( - col0 ) FROM tab0 cor0
----
21072
4620
657621

query I rowsort
SELECT col0 * - col2 + + 94 * cor0.col1 FROM tab2 AS cor0
----
-1404
2725
3518

query I rowsort
SELECT DISTINCT + tab2.col2 * col2 * - 70 AS col0 FROM tab2
----
-101080
-47320
-51030

query I rowsort
SELECT + 30 + + col1 AS col0 FROM tab0
----
116
121
127

query I rowsort
SELECT - cor0.col1 + cor0.col1 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 + - col2 ) col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT tab0.col2 * + col0 * tab0.col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT + 78 * - col0 AS col0 FROM tab1
----
-234
-4992
-6240

query I rowsort
SELECT - col0 * 35 AS col2 FROM tab2
----
-245
-2730
-2765

query I rowsort
SELECT ALL - + ( cor0.col0 ) * - col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT col1 * - col1 + + col1 * + col1 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3106
SELECT ALL - CAST( + 82 AS SIGNED ) col1 FROM tab1 cor0
----
-82
-82
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3106
SELECT ALL - CAST ( + 82 AS INTEGER ) col1 FROM tab1 cor0
----
-82
-82
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3107
SELECT - + col2 DIV + cor0.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-3107
SELECT - + col2 / + cor0.col0 + col1 col1 FROM tab0 AS cor0
----
85
91
97

query I rowsort
SELECT DISTINCT - 58 * - 53 AS col0 FROM tab0 AS cor0
----
3074

query I rowsort
SELECT - + 8 + - ( col1 ) FROM tab2 cor0
----
-25
-39
-67

query I rowsort
SELECT ALL - - 27 AS col0 FROM tab0 AS cor0
----
27
27
27

query I rowsort
SELECT col1 * + ( + col1 ) * - col1 - col2 FROM tab0
----
-636089
-753653
-912674

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3112
SELECT ALL tab1.col1 + CAST( NULL AS SIGNED ) col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3112
SELECT ALL tab1.col1 + CAST ( NULL AS INTEGER ) col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 + - ( - ( col1 ) ) * col0 * - col1 AS col0 FROM tab1
----
-13507
-2002
-6390

onlyif mysql # use DIV operator for integer division
query I rowsort label-3114
SELECT ALL col1 + - col2 * - tab0.col0 DIV col0 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-3114
SELECT ALL col1 + - col2 * - tab0.col0 / col0 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL - ( + col2 * + col1 ) AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL + - cor0.col1 * - cor0.col1 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4a2f25e7025075a0ce048be425c35957

query I rowsort
SELECT DISTINCT 13 * col2 * + cor0.col1 FROM tab1 AS cor0
----
16224
18252
7410

query I rowsort
SELECT - - ( - col1 ) * col0 * 15 FROM tab1 AS cor0
----
-1170
-15600
-9600

query I rowsort
SELECT ALL 45 + - col1 * col1 AS col0 FROM tab1 AS cor0
----
-124
-55
-631

query I rowsort
SELECT + 70 + cor0.col1 * col1 AS col1 FROM tab1 AS cor0
----
170
239
746

query I rowsort
SELECT + + 75 * + col2 * col1 + 65 FROM tab0 AS cor0
----
212915
559715
7340

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3122
SELECT ALL CAST( NULL AS SIGNED ) * - 58 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3122
SELECT ALL CAST ( NULL AS INTEGER ) * - 58 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * 11 + - col2 + - 18 col2 FROM tab0 AS cor0
----
1048
895
901

query I rowsort
SELECT - 27 * + col2 FROM tab2 AS cor0
----
-1026
-702
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-3125
SELECT 28 DIV - col1 AS col1 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3125
SELECT 28 / - col1 AS col1 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT + + cor0.col2 * + 99 * + col0 + + col0 - col2 FROM tab0 AS cor0
----
3499
722509
78399

query I rowsort
SELECT DISTINCT + col2 + 2 AS col0 FROM tab0 AS cor0
----
3
35
84

query I rowsort
SELECT - col1 + - ( col2 ) FROM tab2
----
-55
-58
-85

query I rowsort
SELECT col2 * + ( - col2 ) * col2 + 63 + tab2.col1 FROM tab2
----
-17454
-19589
-54792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3130
SELECT - cor0.col0 DIV - ( cor0.col0 ) FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3130
SELECT - cor0.col0 / - ( cor0.col0 ) FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT cor0.col2 + col0 + + col1 AS col0 FROM tab2 AS cor0
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-3132
SELECT DISTINCT col1 + col1 DIV 68 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3132
SELECT DISTINCT col1 + col1 / 68 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT ALL - + col2 + ( - col0 ) FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 51 + - col0 col0 FROM tab1
----
-13
-29
48

query I rowsort
SELECT cor1.col1 AS col2 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT - 66 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
1716
1782
2508

onlyif mysql # use DIV operator for integer division
query I rowsort label-3137
SELECT ALL col2 DIV col0 + - ( - col0 + + col2 ) col2 FROM tab0 AS cor0
----
-8
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3137
SELECT ALL col2 / col0 + - ( - col0 + + col2 ) col2 FROM tab0 AS cor0
----
-8
34
7

query I rowsort
SELECT DISTINCT + 12 * - col1 AS col1 FROM tab1 AS cor0
----
-120
-156
-312

query I rowsort
SELECT ALL + 15 * col2 AS col1 FROM tab2 AS cor0
----
390
405
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 65 * + cor0.col0 col2 FROM tab0 cor0
----
1560
2275
5785

query I rowsort
SELECT ALL col2 * col2 + col2 * 66 * cor0.col2 FROM tab2 AS cor0
----
45292
48843
96748

query I rowsort
SELECT ALL + + col2 + + cor0.col2 * + 21 FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT 62 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT ALL - ( - col2 ) + - col2 * ( col2 ) AS col1 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT + col2 * + tab1.col2 + col0 * col2 * + ( + 1 ) FROM tab1
----
16896
3078
6897

onlyif mysql # use DIV operator for integer division
query I rowsort label-3146
SELECT DISTINCT - + col2 DIV 5 + ( col0 ) * - col0 FROM tab2 AS cor0
----
-54
-6089
-6248

skipif mysql # not compatible
query I rowsort label-3146
SELECT DISTINCT - + col2 / 5 + ( col0 ) * - col0 FROM tab2 AS cor0
----
-54
-6089
-6248

query I rowsort
SELECT - col0 * ( + col1 ) - - col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - - col2 + cor0.col2 * 64 FROM tab2 AS cor0
----
1690
1755
2470

query I rowsort
SELECT 15 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT cor1.col2 * 27 * + 93 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 17f373fab3e58f10522ae97682625bf8

query I rowsort
SELECT + col0 * 8 + col0 AS col1 FROM tab1
----
27
576
720

query I rowsort
SELECT + 44 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT DISTINCT + - 67 + cor0.col0 * + col0 FROM tab0 AS cor0
----
1158
509
7854

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3154
SELECT ALL CAST( 71 AS SIGNED ) + - col2 AS col1 FROM tab1 AS cor0
----
-25
14
17

skipif mysql # not compatible
query I rowsort label-3154
SELECT ALL CAST ( 71 AS INTEGER ) + - col2 AS col1 FROM tab1 AS cor0
----
-25
14
17

query I rowsort
SELECT DISTINCT + + 28 AS col1 FROM tab1 AS cor0
----
28

query I rowsort
SELECT ALL + col2 * - cor0.col1 - col2 * - col2 FROM tab2 AS cor0
----
-108
-858
798

query I rowsort
SELECT ALL + col0 * - col1 * ( col1 ) FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT + - 4 * col2 AS col0 FROM tab0 cor0
----
-132
-328
-4

query I rowsort
SELECT DISTINCT + + ( + col1 ) AS col0 FROM tab2 cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 * col0 col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - col0 + - col1 * ( col2 ) AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT 72 * col1 FROM tab2 AS cor0
----
1224
2232
4248

query I rowsort
SELECT ALL col2 * + cor0.col1 + 15 AS col0 FROM tab0 AS cor0
----
112
2853
7477

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3164
SELECT CAST( NULL AS SIGNED ) + - 30 / tab0.col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3164
SELECT CAST ( NULL AS INTEGER ) + - 30 / tab0.col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * col2 - + tab2.col2 AS col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT DISTINCT + col2 * - col1 + - col2 AS col2 FROM tab0
----
-2871
-7544
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3167
SELECT DISTINCT - col1 * + col1 * col2 + - 83 DIV + 67 col2 FROM tab2
----
-10983
-25948
-90507

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3167
SELECT DISTINCT - col1 * + col1 * col2 + - 83 / + 67 col2 FROM tab2
----
-10983
-25948
-90507

query I rowsort
SELECT DISTINCT cor1.col0 AS col2 FROM tab2, tab0, tab0 cor0, tab1 AS cor1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col0 col2 FROM tab1
----
29
74
93

query I rowsort
SELECT - ( col1 + + col0 ) AS col2 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT - col0 * - col0 * - col2 FROM tab1
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-3172
SELECT ALL - ( col2 ) + + col0 DIV 41 AS col2 FROM tab2
----
-25
-27
-37

skipif mysql # not compatible
query I rowsort label-3172
SELECT ALL - ( col2 ) + + col0 / 41 AS col2 FROM tab2
----
-25
-27
-37

query I rowsort
SELECT DISTINCT 26 * - col0 + col0 FROM tab0
----
-2225
-600
-875

onlyif mysql # use DIV operator for integer division
query I rowsort label-3174
SELECT DISTINCT - col1 * col0 DIV 89 FROM tab0 AS cor0
----
-23
-38
-91

skipif mysql # not compatible
query I rowsort label-3174
SELECT DISTINCT - col1 * col0 / 89 FROM tab0 AS cor0
----
-23
-38
-91

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 WHERE NOT ( NULL ) < ( NULL )
----

query I rowsort
SELECT + - col2 * col2 * - 87 FROM tab2 AS cor0
----
125628
58812
63423

query I rowsort
SELECT ALL - 52 * + col2 + + col1 + 28 * + col0 FROM tab1 cor0
----
-1162
-2698
-2739

query I rowsort
SELECT - col1 * - col1 + - ( + col0 ) FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT col0 + - col0 * + col0 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT + col1 * - col2 * - 43 + col2 AS col1 FROM tab2
----
27816
36018
65988

query I rowsort
SELECT ALL + cor0.col2 + cor1.col1 AS col0 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to 0cb793b50a400e8b905f92ad22c8878f

query I rowsort
SELECT ALL col0 + + ( + col2 ) AS col0 FROM tab0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3183
SELECT ALL - col1 * CAST( NULL AS SIGNED ) + 47 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3183
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) + 47 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + + col0 - + cor0.col0 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3185
SELECT DISTINCT 46 DIV - col0 FROM tab2 AS cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-3185
SELECT DISTINCT 46 / - col0 FROM tab2 AS cor0
----
-6
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3186
SELECT + CAST( NULL AS SIGNED ) * col2 * + col2 + col0 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3186
SELECT + CAST ( NULL AS INTEGER ) * col2 * + col2 + col0 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + 28 + + col0 * - col2 * col2 AS col0 FROM tab2
----
-114010
-5048
-52674

query I rowsort
SELECT + col1 + + 57 * + col2 * col2 FROM tab2
----
38591
41584
82325

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
3645 values hashing to 2270901c73a658a63f841c68db8155ba

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( col1 AS REAL ) AS col0 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3191
SELECT ALL + - cor0.col1 DIV + 82 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3191
SELECT ALL + - cor0.col1 / + 82 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + 0 + - col1 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - 58 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-147
-82
-93

query I rowsort
SELECT ALL - 59 * col2 AS col0 FROM tab0 AS cor0
----
-1947
-4838
-59

query I rowsort
SELECT DISTINCT - - ( col0 ) * - col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL 44 + 19 * col1 * - ( - cor0.col1 * + col2 ) AS col0 FROM tab0 AS cor0
----
12901842
178815
4637336

query I rowsort
SELECT DISTINCT + 99 * - 1 - + col2 FROM tab0 AS cor0
----
-100
-132
-181

query I rowsort
SELECT ALL ( col1 ) * + col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - ( - 7 ) - col0 AS col0 FROM tab2 AS cor0
----
-71
-72
0

query I rowsort
SELECT ALL - ( + 20 ) + - col2 FROM tab2 cor0
----
-46
-47
-58

query I rowsort
SELECT DISTINCT + col0 + - 50 * col2 * + col1 AS col0 FROM tab1 AS cor0
----
-28436
-62320
-70197

query I rowsort
SELECT DISTINCT + col2 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col2 + col1 * - tab1.col1 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT col1 * - col1 * - col1 - - col0 AS col1 FROM tab0
----
636080
753660
912708

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL BETWEEN col2 * + col0 AND ( col0 + col2 )
----

query I rowsort
SELECT ALL col2 * - col1 * - col0 AS col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT col1 * - col1 + + col2 FROM tab1 WHERE NOT NULL NOT IN ( col0 )
----

query I rowsort
SELECT ALL - col2 * col1 + col0 AS col2 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT ALL - col2 - - col1 * + tab0.col0 AS col2 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT col0 * + col1 * col1 + - tab1.col2 * col1 AS col0 FROM tab1
----
12272
5830
624

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE ( NULL ) NOT IN ( col2 * - col2 )
----

query I rowsort
SELECT ALL - tab1.col2 + col2 * col0 AS col0 FROM tab1
----
108
3591
7584

query I rowsort
SELECT ALL tab2.col1 * col2 + tab2.col0 * - col0 AS col2 FROM tab2
----
-4550
-5595
788

query I rowsort
SELECT + tab0.col0 + + col1 FROM tab0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3215
SELECT ALL tab0.col0 - tab0.col0 DIV + tab0.col2 AS col1 FROM tab0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-3215
SELECT ALL tab0.col0 - tab0.col0 / + tab0.col2 AS col1 FROM tab0
----
0
24
88

query I rowsort
SELECT DISTINCT + col0 - + col2 FROM tab0
----
-9
34
7

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) BETWEEN col0 / - col1 AND tab1.col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + cor0.col1 * - col0 + - cor0.col2 AS col2 FROM tab1 cor0
----
-1136
-132
-697

query I rowsort
SELECT ALL + + cor0.col1 * - cor0.col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT - col1 * - col1 + + cor0.col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT DISTINCT col1 * - col0 + col1 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL - col0 + tab1.col0 * col0 FROM tab1
----
4032
6
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 * col1 col2 FROM tab1
----
36480
4212
99840

query III rowsort
SELECT * FROM tab1 WHERE NOT + col2 <= - col2
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT * FROM tab1 WHERE col1 + col1 IN ( col0 + + col2 * - col0 + col1 )
----

query I rowsort
SELECT DISTINCT + - col1 * - col2 - col0 AS col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT cor0.col0 * col0 + + col0 * col0 AS col2 FROM tab2 AS cor0
----
12168
12482
98

query I rowsort
SELECT ALL - col2 + 60 * 24 FROM tab0 AS cor0
----
1358
1407
1439

query I rowsort
SELECT + - col1 - - col2 * - ( + cor0.col2 * - cor0.col2 ) FROM tab1 cor0
----
157438
185183
884723

onlyif mysql # use DIV operator for integer division
query I rowsort label-3231
SELECT DISTINCT + col1 + + 19 DIV - col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3231
SELECT DISTINCT + col1 + + 19 / - col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - - col0 * - 65 + - col0 AS col2 FROM tab0 AS cor0
----
-1584
-2310
-5874

query I rowsort
SELECT + + cor0.col0 * ( - col2 ) - col2 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT - col2 + ( - 2 ) + col1 AS col0 FROM tab1 AS cor0
----
-30
-49
-85

query I rowsort
SELECT col0 + - col0 * - col0 AS col0 FROM tab0 cor0
----
1260
600
8010

query I rowsort
SELECT ( + col0 + + 3 ) FROM tab2
----
10
81
82

query I rowsort
SELECT 94 * col2 * 79 FROM tab1
----
401004
423282
712896

query I rowsort
SELECT col2 + col2 - - col0 AS col0 FROM tab1
----
111
178
272

query I rowsort
SELECT - col0 - + 33 FROM tab1 AS cor0
----
-113
-36
-97

query I rowsort
SELECT DISTINCT + col0 * col1 + col2 + col1 FROM tab0 AS cor0
----
2183
3493
8272

query I rowsort
SELECT ALL + 82 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

onlyif mysql # use DIV operator for integer division
query I rowsort label-3242
SELECT DISTINCT tab2.col0 DIV + col0 + + col1 FROM tab2
----
18
32
60

skipif mysql # not compatible
query I rowsort label-3242
SELECT DISTINCT tab2.col0 / + col0 + + col1 FROM tab2
----
18
32
60

query I rowsort
SELECT + 10 * 86 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to deacf763707b3668c9b19e426e81a4e2

query I rowsort
SELECT DISTINCT + col0 * 57 * - col2 AS col0 FROM tab1
----
-207936
-437760
-9234

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 cor1, tab2 AS cor2
----
972 values hashing to 591a9a93560839231c038a1e10bd240a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 - col1 col1 FROM tab1
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3247
SELECT DISTINCT + tab0.col1 DIV + col1 + col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-3247
SELECT DISTINCT + tab0.col1 / + col1 + col2 FROM tab0
----
2
34
83

query I rowsort
SELECT ALL - col1 FROM tab0 WHERE NOT NULL < - col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor2.col1 col1 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

query I rowsort
SELECT - tab0.col0 FROM tab0 WHERE - col2 / + col0 < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + col0 col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL + tab0.col0 + col1 AS col1 FROM tab0 WHERE col1 BETWEEN ( NULL ) AND + col2
----

query I rowsort
SELECT DISTINCT + col1 + + col2 * col2 AS col0 FROM tab0
----
1175
6815
98

query I rowsort
SELECT ALL + col2 + col2 - 62 FROM tab0
----
-60
102
4

query I rowsort
SELECT + + 42 * + 89 FROM tab1, tab0 cor0
----
9 values hashing to c63e2f395f9f085592e40d2df11086d4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * - col0 col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT - 35 + + 61 FROM tab0 AS cor0
----
26
26
26

query I rowsort
SELECT ALL ( 46 ) + + col0 AS col0 FROM tab0 AS cor0
----
135
70
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - cor0.col1 col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL 29 - - col0 * + cor0.col0 FROM tab2 AS cor0
----
6113
6270
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3261
SELECT ALL + CAST( col1 AS SIGNED ) - + cor0.col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-3261
SELECT ALL + CAST ( col1 AS INTEGER ) - + cor0.col2 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3262
SELECT ALL ( ( col0 - col2 DIV + col0 ) ) * + col1 * - cor0.col2 + ( + col0 ) + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-36426
-98525
21037

skipif mysql # not compatible
query I rowsort label-3262
SELECT ALL ( ( col0 - col2 / + col0 ) ) * + col1 * - cor0.col2 + ( + col0 ) + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-36426
-98525
21037

query I rowsort
SELECT 56 AS col0 FROM tab0 cor0
----
56
56
56

query I rowsort
SELECT ALL - 2 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT col2 * - ( - ( tab1.col0 ) * tab1.col2 ) + - 73 FROM tab1
----
207863
737207
8675

onlyif mysql # use DIV operator for integer division
query I rowsort label-3266
SELECT - col1 DIV ( col1 ) + col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3266
SELECT - col1 / ( col1 ) + col0 FROM tab1
----
2
63
79

query I rowsort
SELECT DISTINCT ( - cor0.col2 ) AS col0 FROM tab0, tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - col2 + + ( col0 ) * - col1 AS col1 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT col2 + + ( - col1 ) * - ( tab2.col1 ) AS col0 FROM tab2
----
327
3507
988

query I rowsort
SELECT ALL ( - 46 ) FROM tab2
----
-46
-46
-46

query I rowsort
SELECT DISTINCT - 45 + col2 * + col2 AS col0 FROM tab1 cor0
----
2871
3204
9171

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3272
SELECT ALL CAST( NULL AS SIGNED ) - + ( cor0.col1 ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3272
SELECT ALL CAST ( NULL AS INTEGER ) - + ( cor0.col1 ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - ( - 96 ) * - col1 + - col1 * 93 + col1 AS col2 FROM tab2 AS cor0
----
-11092
-3196
-5828

query I rowsort
SELECT ALL + col0 - cor0.col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3276
SELECT + CAST( + col2 AS SIGNED ) FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3276
SELECT + CAST ( + col2 AS INTEGER ) FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT + 41 + col0 AS col1 FROM tab2 AS cor0
----
119
120
48

query I rowsort
SELECT 12 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d4f5a8e032294c3b9342821617800972

onlyif mysql # use DIV operator for integer division
query I rowsort label-3279
SELECT + 78 DIV tab1.col0 + + tab1.col1 - col2 FROM tab1
----
-2
-46
-83

skipif mysql # not compatible
query I rowsort label-3279
SELECT + 78 / tab1.col0 + + tab1.col1 - col2 FROM tab1
----
-2
-46
-83

query I rowsort
SELECT 75 * col1 AS col2 FROM tab1
----
1950
750
975

query I rowsort
SELECT - - 54 + col2 FROM tab0 AS cor0
----
136
55
87

query I rowsort
SELECT + 19 * - col1 AS col1 FROM tab2 AS cor0
----
-1121
-323
-589

query I rowsort
SELECT ALL col0 * - 53 AS col2 FROM tab1
----
-159
-3392
-4240

query I rowsort
SELECT ALL 66 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3285
SELECT - cor0.col2 * CAST( + col0 AS SIGNED ) + + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

skipif mysql # not compatible
query I rowsort label-3285
SELECT - cor0.col2 * CAST ( + col0 AS INTEGER ) + + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - col0 + - 72 FROM tab0 AS cor0
----
-107
-161
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + 1 col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3288
SELECT DISTINCT - col1 + CAST( col1 + cor0.col0 AS SIGNED ) DIV col0 FROM tab1 AS cor0
----
-12
-17
-9

skipif mysql # not compatible
query I rowsort label-3288
SELECT DISTINCT - col1 + CAST ( col1 + cor0.col0 AS INTEGER ) / col0 FROM tab1 AS cor0
----
-12
-17
-9

query I rowsort
SELECT + cor0.col2 * ( 87 ) + + col2 AS col0 FROM tab2 AS cor0
----
2288
2376
3344

onlyif mysql # use DIV operator for integer division
query I rowsort label-3290
SELECT - + cor0.col1 DIV col1 + + 54 AS col2 FROM tab0 AS cor0
----
53
53
53

skipif mysql # not compatible
query I rowsort label-3290
SELECT - + cor0.col1 / col1 + + 54 AS col2 FROM tab0 AS cor0
----
53
53
53

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to 6726a15019c52908f1f1d0df0cd4c1b8

query I rowsort
SELECT + + col0 * 79 FROM tab0 AS cor0
----
1896
2765
7031

query I rowsort
SELECT ALL - col2 * 58 AS col2 FROM tab1 AS cor0
----
-3132
-3306
-5568

query I rowsort
SELECT ALL - - col2 + - 48 FROM tab2 cor0
----
-10
-21
-22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * - 54 col1 FROM tab0 AS cor0
----
4644
4914
5238

query I rowsort
SELECT DISTINCT cor0.col0 * 0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT 22 * + col0 FROM tab2 cor0
----
154
1716
1738

query I rowsort
SELECT + col0 + - 89 * col1 * col2 FROM tab0 AS cor0
----
-252558
-664029
-8598

query I rowsort
SELECT - 71 * + col1 FROM tab0 AS cor0
----
-6106
-6461
-6887

query I rowsort
SELECT ( cor0.col0 ) * + cor0.col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + + ( 47 ) + + col2 AS col1 FROM tab2 cor0
----
73
74
85

query I rowsort
SELECT ALL + 23 AS col2 FROM tab1 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col2 FROM tab1, tab0 cor0, tab0 AS cor1, tab2 cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT DISTINCT - + cor0.col1 + + cor0.col1 - col0 * 64 AS col0 FROM tab2 AS cor0
----
-448
-4992
-5056

query I rowsort
SELECT DISTINCT - cor0.col0 * col1 + col1 * col2 AS col1 FROM tab0 AS cor0
----
-3298
-637
774

onlyif mysql # use DIV operator for integer division
query I rowsort label-3306
SELECT ALL - 24 * + col2 DIV + col2 FROM tab0 AS cor0
----
-24
-24
-24

skipif mysql # not compatible
query I rowsort label-3306
SELECT ALL - 24 * + col2 / + col2 FROM tab0 AS cor0
----
-24
-24
-24

query I rowsort
SELECT ALL - + 71 * + cor0.col2 + col0 AS col1 FROM tab0 cor0
----
-2319
-36
-5733

query I rowsort
SELECT ALL + - col2 + - col2 * + col1 * col2 AS col0 FROM tab0 AS cor0
----
-611966
-93687
-98

query I rowsort
SELECT - col2 * 63 FROM tab2 cor0
----
-1638
-1701
-2394

skipif mysql # not compatible
query I rowsort
SELECT - col1 + - CAST ( 58 * col1 AS REAL ) AS col2 FROM tab2 AS cor0
----
-1003
-1829
-3481

query I rowsort
SELECT - 92 FROM tab0, tab2, tab2 cor0
----
27 values hashing to a0e6b76227d870d10c4d9f46545a7c83

query I rowsort
SELECT ALL 69 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + tab2.col1 col1 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 92 + col1 col0 FROM tab0
----
178
183
189

query I rowsort
SELECT DISTINCT + col2 + - col2 * 92 + + col2 FROM tab1
----
-4860
-5130
-8640

query I rowsort
SELECT DISTINCT + 47 + cor0.col1 * + ( ( col0 ) ) FROM tab1 AS cor0
----
1087
125
687

query I rowsort
SELECT ALL - - 38 FROM tab1 AS cor0
----
38
38
38

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab1 cor1, tab2, tab1 cor2
----
3645 values hashing to 1c1b1a313871216b88e662d7d3078b12

query I rowsort
SELECT ALL ( col0 ) + + ( 99 * col0 + + col1 ) FROM tab2
----
731
7859
7917

onlyif mysql # use DIV operator for integer division
query I rowsort label-3320
SELECT DISTINCT col0 * + col0 + - 0 * col0 DIV col2 FROM tab0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-3320
SELECT DISTINCT col0 * + col0 + - 0 * col0 / col2 FROM tab0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 47 col1 FROM tab2, tab2 cor0, tab0 cor1
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

query I rowsort
SELECT ALL col2 * 79 FROM tab0
----
2607
6478
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3323
SELECT - + col0 DIV + CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3323
SELECT - + col0 / + CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * ( + 74 ) FROM tab0 AS cor0
----
-2442
-6068
-74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3325
SELECT + col0 * col2 + col1 + - CAST( col1 AS SIGNED ) * col1 FROM tab1 AS cor0
----
-488
3558
7524

skipif mysql # not compatible
query I rowsort label-3325
SELECT + col0 * col2 + col1 + - CAST ( col1 AS INTEGER ) * col1 FROM tab1 AS cor0
----
-488
3558
7524

onlyif mysql # use DIV operator for integer division
query I rowsort label-3326
SELECT col1 * + col1 + - col2 DIV - ( cor0.col2 * - col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
7372
8192
9374

skipif mysql # not compatible
query I rowsort label-3326
SELECT col1 * + col1 + - col2 / - ( cor0.col2 * - col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT - 57 * - col1 - - col1 AS col0 FROM tab0 cor0
----
4988
5278
5626

query I rowsort
SELECT - - ( + col2 ) - + col1 AS col0 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3329
SELECT + CAST( NULL AS SIGNED ) - - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3329
SELECT + CAST ( NULL AS INTEGER ) - - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + + col2 + + col1 * - 20 AS col2 FROM tab0 AS cor0
----
-1649
-1663
-1904

query I rowsort
SELECT - col0 * - 17 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT + - 84 AS col1 FROM tab2 cor0
----
-84
-84
-84

query I rowsort
SELECT - col2 * 78 * col2 AS col2 FROM tab1 AS cor0
----
-227448
-253422
-718848

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - cor0.col2 ) col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + + 23 + 78 FROM tab1 AS cor0
----
101
101
101

query I rowsort
SELECT ALL ( - col2 ) + - col1 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3337
SELECT ALL - col1 DIV - 55 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3337
SELECT ALL - col1 / - 55 FROM tab2 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3338
SELECT ALL - ( - ( + col2 ) ) * CAST( NULL AS SIGNED ) + cor0.col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3338
SELECT ALL - ( - ( + col2 ) ) * CAST ( NULL AS INTEGER ) + cor0.col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( + col2 ) + + col2 * col0 AS col0 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-3340
SELECT - 13 + - col0 + - 38 DIV col0 AS col1 FROM tab1 cor0
----
-28
-77
-93

skipif mysql # not compatible
query I rowsort label-3340
SELECT - 13 + - col0 + - 38 / col0 AS col1 FROM tab1 cor0
----
-28
-77
-93

query I rowsort
SELECT 70 * - col1 + - ( - col0 ) FROM tab2 AS cor0
----
-1111
-2163
-4052

query I rowsort
SELECT DISTINCT - 23 * col2 FROM tab2 AS cor0
----
-598
-621
-874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 + cor0.col2 col0 FROM tab0 cor0
----
120
169
88

query I rowsort
SELECT ALL 35 * col0 FROM tab2 AS cor0
----
245
2730
2765

query I rowsort
SELECT + - col2 * - col0 + ( col2 ) - col1 AS col1 FROM tab0 AS cor0
----
-61
7289
739

query I rowsort
SELECT + 1 - col1 AS col0 FROM tab0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3347
SELECT DISTINCT + col0 DIV + ( + col2 * + 46 ) AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-3347
SELECT DISTINCT + col0 / + ( + col2 * + 46 ) AS col2 FROM tab1
----
0

query I rowsort
SELECT DISTINCT - 10 * + col1 FROM tab2
----
-170
-310
-590

query I rowsort
SELECT ALL col2 * ( + tab0.col2 ) AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT - col2 * - cor0.col2 + ( - 43 ) + col1 AS col0 FROM tab2 AS cor0
----
1418
692
717

onlyif mysql # use DIV operator for integer division
query I rowsort label-3351
SELECT + col0 DIV col1 - ( 54 ) * col0 FROM tab1 AS cor0
----
-162
-3450
-4314

skipif mysql # not compatible
query I rowsort label-3351
SELECT + col0 / col1 - ( 54 ) * col0 FROM tab1 AS cor0
----
-162
-3450
-4314

query I rowsort
SELECT ( col1 * - col2 ) - col2 * ( col1 ) AS col0 FROM tab2
----
-1292
-1674
-3068

query I rowsort
SELECT + + col0 + 91 AS col2 FROM tab2 AS cor0
----
169
170
98

query I rowsort
SELECT DISTINCT - cor0.col0 + - ( 67 + - col1 ) * - 57 FROM tab0 cor0
----
-1107
-1457
-1745

query I rowsort
SELECT ALL cor0.col0 - + 16 AS col2 FROM tab1 AS cor0
----
-13
48
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3356
SELECT DISTINCT - col1 * - CAST( NULL AS SIGNED ) * - 64 + + col0 * ( col1 ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3356
SELECT DISTINCT - col1 * - CAST ( NULL AS INTEGER ) * - 64 + + col0 * ( col1 ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - + col2 * 91 - cor0.col1 * - col2 FROM tab2 AS cor0
----
-1620
-2812
-832

onlyif mysql # use DIV operator for integer division
query I rowsort label-3358
SELECT DISTINCT col0 DIV ( - 94 ) + col1 col0 FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3358
SELECT DISTINCT col0 / ( - 94 ) + col1 col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - col0 + 52 FROM tab1 cor0
----
-12
-28
49

query I rowsort
SELECT + - col2 * col0 + 23 AS col2 FROM tab2 cor0
----
-166
-2005
-2979

query I rowsort
SELECT 77 * col2 FROM tab2
----
2002
2079
2926

query I rowsort
SELECT + cor0.col1 + - 62 * + col2 AS col1 FROM tab2 AS cor0
----
-1553
-1643
-2339

query I rowsort
SELECT DISTINCT + col2 * - col0 + + 44 FROM tab0 AS cor0
----
-7254
-748
9

query I rowsort
SELECT ALL + - col2 * + cor0.col2 + 45 FROM tab2 AS cor0
----
-1399
-631
-684

query I rowsort
SELECT DISTINCT - + col0 + - 90 AS col1 FROM tab1 AS cor0
----
-154
-170
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3366
SELECT ALL - - CAST( 6 AS SIGNED ) + col2 FROM tab0 AS cor0
----
39
7
88

skipif mysql # not compatible
query I rowsort label-3366
SELECT ALL - - CAST ( 6 AS INTEGER ) + col2 FROM tab0 AS cor0
----
39
7
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 49 col1 FROM tab0 AS cor0
----
49
49
49

query I rowsort
SELECT DISTINCT + col1 + col2 * col0 * + 44 FROM tab2 AS cor0
----
132105
8347
89291

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - col0 AS REAL ) * - cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL 72 AS col0 FROM tab1 cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2, tab1 AS cor3
----
243 values hashing to 512fe086cc46e8ac6353c0d32befbe4a

query I rowsort
SELECT ALL - 49 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT DISTINCT - 90 + col2 FROM tab0 AS cor0
----
-57
-8
-89

query I rowsort
SELECT ALL - col1 - cor0.col0 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + cor0.col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + 56 * col0 FROM tab1 AS cor0
----
168
3584
4480

query I rowsort
SELECT DISTINCT cor0.col1 + + col0 * - col0 + col1 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-4186
-6556
-659

query I rowsort
SELECT + cor0.col0 + col1 * + 51 AS col0 FROM tab2 AS cor0
----
1588
3087
946

query I rowsort
SELECT + 15 + cor0.col0 FROM tab2 cor0
----
22
93
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 1 * - col2 col1 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3380
SELECT 33 * - col0 + + CAST( NULL AS DECIMAL ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3380
SELECT 33 * - col0 + + CAST ( NULL AS REAL ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 84 + col1 AS col1 FROM tab0 AS cor0
----
13
2
7

query I rowsort
SELECT + - cor0.col0 * col2 + - ( 3 ) AS col1 FROM tab2 cor0
----
-192
-2031
-3005

query I rowsort
SELECT DISTINCT - - cor0.col0 * col1 * 41 + col1 FROM tab1 AS cor0
----
26250
3224
42653

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3384
SELECT DISTINCT + col2 * col0 + CAST( + col2 AS SIGNED ) * - col0 col0 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3384
SELECT DISTINCT + col2 * col0 + CAST ( + col2 AS INTEGER ) * - col0 col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + col1 * 16 + col1 AS col1 FROM tab2 AS cor0
----
1003
289
527

query I rowsort
SELECT + col1 * - col1 * - col2 AS col2 FROM tab0 AS cor0
----
244068
679042
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3387
SELECT + + CAST( NULL AS SIGNED ) - + col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3387
SELECT + + CAST ( NULL AS INTEGER ) - + col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 96 FROM tab0, tab2 cor0
----
96

query I rowsort
SELECT ALL - 90 * 85 FROM tab1, tab0 cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 8088c841e0aefaa7ea85a0f598b932b2

query I rowsort
SELECT - ( + col0 ) + + col0 + + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + 15 + - 80 FROM tab2
----
-65

query I rowsort
SELECT ALL + col0 + col1 * col1 AS col1 FROM tab1
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-3393
SELECT ALL + ( tab2.col0 ) DIV col1 + + col2 FROM tab2
----
27
27
42

skipif mysql # not compatible
query I rowsort label-3393
SELECT ALL + ( tab2.col0 ) / col1 + + col2 FROM tab2
----
27
27
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-3394
SELECT col1 DIV + 50 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3394
SELECT col1 / + 50 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT 23 * col1 - - col2 FROM tab1 cor0
----
287
395
652

query I rowsort
SELECT - 82 - - 43 AS col1 FROM tab2 cor0
----
-39
-39
-39

query I rowsort
SELECT ALL - 37 + col0 AS col1 FROM tab1 AS cor0
----
-34
27
43

query I rowsort
SELECT DISTINCT - col2 + - col0 * - col0 AS col2 FROM tab2
----
22
6058
6203

query I rowsort
SELECT ALL - - 36 * - col1 - col2 * col0 FROM tab0 AS cor0
----
-10574
-3527
-3888

query I rowsort
SELECT DISTINCT col0 + 97 FROM tab1
----
100
161
177

query I rowsort
SELECT 88 * col0 AS col0 FROM tab1
----
264
5632
7040

query I rowsort
SELECT DISTINCT - ( - col0 ) + col1 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT - cor1.col2 + - ( cor0.col0 ) * + cor1.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9b4cb1454efc99b2a281fcb6731eb263

query I rowsort
SELECT - 33 * - col1 * - col0 AS col1 FROM tab0 AS cor0
----
-112035
-267267
-68112

query I rowsort
SELECT DISTINCT col2 * - col2 * cor0.col1 FROM tab0 AS cor0
----
-611884
-93654
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3406
SELECT ALL - - 14 + + 78 DIV col0 AS col1 FROM tab0 AS cor0
----
14
16
17

skipif mysql # not compatible
query I rowsort label-3406
SELECT ALL - - 14 + + 78 / col0 AS col1 FROM tab0 AS cor0
----
14
16
17

query I rowsort
SELECT - 18 - + col0 AS col2 FROM tab0 cor0
----
-107
-42
-53

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab0, tab1 cor0, tab1 cor1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + + col2 * + col1 col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT + 27 * tab1.col2 AS col1 FROM tab1
----
1458
1539
2592

query I rowsort
SELECT ALL 42 * col1 AS col0 FROM tab0
----
3612
3822
4074

query I rowsort
SELECT + 31 - col1 * col2 FROM tab1 AS cor0
----
-1217
-1373
-539

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 66 col2 FROM tab0, tab1 AS cor0
----
66

query I rowsort
SELECT ALL - 21 * 18 FROM tab2, tab2 AS cor0
----
9 values hashing to d4eb14663371284a43201c028a7773e8

query I rowsort
SELECT + 15 * ( - cor0.col2 ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 21bb369fcca3759468c13c9b8474545b

query I rowsort
SELECT ALL + 3 FROM tab2, tab0 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

onlyif mysql # use DIV operator for integer division
query I rowsort label-3417
SELECT ALL - + col2 DIV + col1 + col2 AS col1 FROM tab1 cor0
----
52
52
89

skipif mysql # not compatible
query I rowsort label-3417
SELECT ALL - + col2 / + col1 + col2 AS col1 FROM tab1 cor0
----
52
52
89

query I rowsort
SELECT ALL - col1 * col1 * col0 AS col0 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT - 9 * + 31 FROM tab0 AS cor0
----
-279
-279
-279

query I rowsort
SELECT DISTINCT 74 * cor0.col0 FROM tab2 AS cor0
----
518
5772
5846

query I rowsort
SELECT - + ( col2 ) + cor0.col0 * - 49 FROM tab2 AS cor0
----
-370
-3848
-3909

query I rowsort
SELECT 7 * 99 FROM tab0 AS cor0
----
693
693
693

query I rowsort
SELECT + 22 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT col1 + + col1 * ( col2 ) * col0 FROM tab0
----
3492
664209
68198

query I rowsort
SELECT DISTINCT + col1 * 67 AS col1 FROM tab1
----
1742
670
871

onlyif mysql # use DIV operator for integer division
query I rowsort label-3426
SELECT 91 DIV - col1 col0 FROM tab1 AS cor0
----
-3
-7
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3426
SELECT 91 / - col1 col0 FROM tab1 AS cor0
----
-3
-7
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3427
SELECT + - CAST( - 87 AS SIGNED ) FROM tab2 AS cor0
----
87
87
87

skipif mysql # not compatible
query I rowsort label-3427
SELECT + - CAST ( - 87 AS INTEGER ) FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT - col2 + ( ( + col1 ) * + col0 + col0 ) FROM tab2
----
1384
197
4654

query I rowsort
SELECT + - col1 + 84 AS col0 FROM tab2 AS cor0
----
25
53
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-3430
SELECT DISTINCT + - col0 + + 41 DIV 81 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3430
SELECT DISTINCT + - col0 + + 41 / 81 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col1 * - ( 49 ) AS col1 FROM tab2
----
-1519
-2891
-833

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3432
SELECT ALL + CAST( 26 AS SIGNED ) + + col0 FROM tab1 cor0
----
106
29
90

skipif mysql # not compatible
query I rowsort label-3432
SELECT ALL + CAST ( 26 AS INTEGER ) + + col0 FROM tab1 cor0
----
106
29
90

query I rowsort
SELECT DISTINCT - col2 * + col1 * + col1 + 69 FROM tab1 AS cor0
----
-16155
-36435
-5631

query I rowsort
SELECT col2 * + col0 + - col2 FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT + 66 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT col0 + 88 * + col1 * + col2 AS col2 FROM tab2
----
135070
56927
73663

query I rowsort
SELECT - col1 * col2 * + col2 - + col2 FROM tab1 AS cor0
----
-119904
-32547
-75870

query I rowsort
SELECT col0 * + 54 FROM tab0
----
1296
1890
4806

query I rowsort
SELECT DISTINCT 64 * 58 AS col0 FROM tab2
----
3712

query I rowsort
SELECT - - ( - col0 ) * col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL 87 * col0 FROM tab0 cor0
----
2088
3045
7743

query I rowsort
SELECT ALL col1 * + ( col0 * 53 + + col2 ) AS col0 FROM tab2
----
12338
245440
71825

query I rowsort
SELECT - ( col0 ) * - col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + 6 FROM tab1, tab2, tab1 AS cor0
----
6

query I rowsort
SELECT col1 + + cor0.col0 * + col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL - 72 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

query I rowsort
SELECT 81 + + col2 AS col0 FROM tab0
----
114
163
82

query I rowsort
SELECT + tab1.col1 + + col2 * col1 AS col0 FROM tab1
----
1261
1430
580

query I rowsort
SELECT 37 AS col1 FROM tab0 cor0
----
37
37
37

query I rowsort
SELECT ALL col1 + 15 * col0 FROM tab2 AS cor0
----
1202
1229
136

onlyif mysql # use DIV operator for integer division
query I rowsort label-3451
SELECT - cor0.col1 DIV + 67 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3451
SELECT - cor0.col1 / + 67 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * + col0 - col0 * col2 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT tab2.col2 AS col0 FROM tab2, tab2 cor0, tab0 cor1
----
26
27
38

query I rowsort
SELECT - col0 + - cor0.col1 * + col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT col1 + - ( + col2 ) FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - - cor0.col2 * - col2 - col2 FROM tab1 cor0
----
-2970
-3306
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3457
SELECT ALL - col0 * CAST( - ( - col0 ) AS SIGNED ) * 70 FROM tab0 AS cor0
----
-40320
-554470
-85750

skipif mysql # not compatible
query I rowsort label-3457
SELECT ALL - col0 * CAST ( - ( - col0 ) AS INTEGER ) * 70 FROM tab0 AS cor0
----
-40320
-554470
-85750

query I rowsort
SELECT col0 * - 93 * col0 FROM tab0 AS cor0
----
-113925
-53568
-736653

query I rowsort
SELECT ALL + cor0.col0 * col1 + - col2 AS col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + - 89 AS col0 FROM tab0 AS cor0
----
-89
-89
-89

query I rowsort
SELECT + col1 + + cor0.col1 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
195
205
264

query I rowsort
SELECT - ( + 85 ) * col2 * col0 + 29 * col1 * col2 AS col1 FROM tab2 AS cor0
----
-127894
-236436
8208

onlyif mysql # use DIV operator for integer division
query I rowsort label-3463
SELECT ALL - cor0.col0 DIV col1 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-3463
SELECT ALL - cor0.col0 / col1 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
25
27
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3464
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + col0 + + col2 * col2 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3464
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + col0 + + col2 * col2 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT ( 38 ) * - col0 + col1 AS col2 FROM tab2 AS cor0
----
-235
-2905
-2985

query I rowsort
SELECT - col2 + - 49 FROM tab0 AS cor0
----
-131
-50
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 - col0 col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - cor0.col2 + 72 * cor0.col0 AS col2 FROM tab2 AS cor0
----
477
5590
5650

query I rowsort
SELECT + col2 + cor0.col2 * - cor0.col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT 76 - 29 AS col2 FROM tab2 cor0
----
47
47
47

query I rowsort
SELECT + 85 + + 42 FROM tab2 AS cor0
----
127
127
127

onlyif mysql # use DIV operator for integer division
query I rowsort label-3472
SELECT ALL - 18 + + col1 DIV - 75 FROM tab0 cor0
----
-19
-19
-19

skipif mysql # not compatible
query I rowsort label-3472
SELECT ALL - 18 + + col1 / - 75 FROM tab0 cor0
----
-19
-19
-19

query I rowsort
SELECT ALL - - col2 * + cor0.col1 + 0 + col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-3474
SELECT DISTINCT 50 DIV - col0 AS col0 FROM tab1 AS cor0
----
-16
0

skipif mysql # not compatible
query I rowsort label-3474
SELECT DISTINCT 50 / - col0 AS col0 FROM tab1 AS cor0
----
-16
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 83 + - col1 * + 78 * col1 col1 FROM tab2 AS cor0
----
-22459
-271435
-74875

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3476
SELECT ALL CAST( NULL AS SIGNED ) + + col1 + + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3476
SELECT ALL CAST ( NULL AS INTEGER ) + + col1 + + col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + cor0.col2 ) * - col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - 81 * col2 AS col1 FROM tab1 AS cor0
----
-4374
-4617
-7776

query I rowsort
SELECT + 49 + + cor0.col0 FROM tab1 cor0
----
113
129
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3480
SELECT - col2 + + 66 - + col0 DIV col2 FROM tab1 AS cor0
----
-30
12
8

skipif mysql # not compatible
query I rowsort label-3480
SELECT - col2 + + 66 - + col0 / col2 FROM tab1 AS cor0
----
-30
12
8

query I rowsort
SELECT DISTINCT + - col2 * - ( col2 ) AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + col0 * - col2 + - col2 * - col2 FROM tab2 AS cor0
----
-1352
-1558
540

query I rowsort
SELECT + - 9 * col2 + - col2 + col1 AS col1 FROM tab2 AS cor0
----
-201
-239
-363

query I rowsort
SELECT 48 AS col1 FROM tab1 cor0
----
48
48
48

query I rowsort
SELECT col0 + col0 * col1 - 56 * col1 FROM tab2 AS cor0
----
-1512
1376
470

query I rowsort
SELECT ALL - - 46 + + col0 * ( + col1 * col0 ) FROM tab1 AS cor0
----
280
41006
83246

query I rowsort
SELECT - + ( col2 ) + col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3488
SELECT DISTINCT + col2 * col2 DIV 59 AS col0 FROM tab1 AS cor0
----
156
49
55

skipif mysql # not compatible
query I rowsort label-3488
SELECT DISTINCT + col2 * col2 / 59 AS col0 FROM tab1 AS cor0
----
156
49
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-3489
SELECT ALL col0 * - 43 + + col1 * 96 DIV - col0 + col0 * + col2 * + 71 FROM tab2
----
12693
140562
209725

skipif mysql # not compatible
query I rowsort label-3489
SELECT ALL col0 * - 43 + + col1 * 96 / - col0 + col0 * + col2 * + 71 FROM tab2
----
12693
140562
209725

query I rowsort
SELECT - + col2 * col1 - + ( + cor0.col1 ) FROM tab1 AS cor0
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-3491
SELECT - col1 - - col1 * col1 DIV col0 AS col2 FROM tab0 AS cor0
----
171
2
222

skipif mysql # not compatible
query I rowsort label-3491
SELECT - col1 - - col1 * col1 / col0 AS col2 FROM tab0 AS cor0
----
171
2
222

query I rowsort
SELECT + - col1 * col0 + + col2 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT ALL - col1 * - col1 + + col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT + col0 + - ( - 18 ) AS col2 FROM tab0 cor0
----
107
42
53

query I rowsort
SELECT ALL - - col1 + - 18 FROM tab2 cor0
----
-1
13
41

query I rowsort
SELECT DISTINCT + - cor0.col2 + 34 AS col2 FROM tab1 AS cor0
----
-20
-23
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3497
SELECT ALL + col2 DIV - col1 + ( cor0.col2 ) AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3497
SELECT ALL + col2 / - col1 + ( cor0.col2 ) AS col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3498
SELECT DISTINCT col2 * + CAST( + col2 AS SIGNED ) AS col1 FROM tab2
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-3498
SELECT DISTINCT col2 * + CAST ( + col2 AS INTEGER ) AS col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT DISTINCT + + col0 + col1 * + ( + col0 + + col1 ) AS col0 FROM tab1 AS cor0
----
1289
757
804

query I rowsort
SELECT ALL - + col0 * col0 * - 54 FROM tab2 AS cor0
----
2646
328536
337014

query I rowsort
SELECT ALL cor0.col2 * 23 FROM tab1 AS cor0
----
1242
1311
2208

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3502
SELECT + cor0.col1 / CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3502
SELECT + cor0.col1 / CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * + col0 + - col0 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + + cor0.col0 * - cor0.col0 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-13824
-42875
-704969

query I rowsort
SELECT ALL + - col1 * 95 * - col2 AS col1 FROM tab0 cor0
----
269610
708890
9215

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 cor1, tab0 AS cor2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT ( + 92 ) AS col1 FROM tab2 AS cor0
----
92
92
92

query I rowsort
SELECT + col2 * col1 + + col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 2 ) col0 FROM tab0 cor0
----
-2
-2
-2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3510
SELECT + CAST( ( col1 ) AS SIGNED ) FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3510
SELECT + CAST ( ( col1 ) AS INTEGER ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT 33 + - ( col2 ) FROM tab2 AS cor0
----
-5
6
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3512
SELECT - col1 + + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3512
SELECT - col1 + + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * - col2 + + col2 AS col1 FROM tab0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 22 col0 FROM tab2 AS cor0
----
-22
-22
-22

query I rowsort
SELECT - 63 * + 91 FROM tab0 AS cor0
----
-5733
-5733
-5733

query I rowsort
SELECT 91 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3517
SELECT DISTINCT - CAST( + 71 + col1 AS SIGNED ) FROM tab2
----
-102
-130
-88

skipif mysql # not compatible
query I rowsort label-3517
SELECT DISTINCT - CAST ( + 71 + col1 AS INTEGER ) FROM tab2
----
-102
-130
-88

query I rowsort
SELECT ALL ( + cor0.col2 ) * col1 + col1 * + col2 FROM tab0 AS cor0
----
14924
194
5676

query I rowsort
SELECT - col0 * - ( col2 ) + - col1 * + 2 FROM tab2 AS cor0
----
127
1910
2968

query I rowsort
SELECT ALL + + 49 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT ALL + 96 FROM tab0, tab0 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * cor0.col0 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col2 * + ( + col2 ) + - col1 * - ( + col0 ) * + col2 FROM tab2 AS cor0
----
120328
52478
6588

onlyif mysql # use DIV operator for integer division
query I rowsort label-3524
SELECT col0 + col0 + col1 DIV col0 FROM tab1 AS cor0
----
128
14
160

skipif mysql # not compatible
query I rowsort label-3524
SELECT col0 + col0 + col1 / col0 FROM tab1 AS cor0
----
128
14
160

query I rowsort
SELECT ALL + col0 * + col0 + - cor0.col2 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT + col0 * + cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-3527
SELECT ALL col2 * col0 + col0 DIV col2 AS col2 FROM tab1 AS cor0
----
162
3649
7680

skipif mysql # not compatible
query I rowsort label-3527
SELECT ALL col2 * col0 + col0 / col2 AS col2 FROM tab1 AS cor0
----
162
3649
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 col2 FROM tab2 AS cor0 WHERE NULL = col2
----

query I rowsort
SELECT DISTINCT tab0.col2 FROM tab2 AS cor0 CROSS JOIN tab0
----
1
33
82

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0 WHERE NOT NULL BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT ALL + cor0.col2 - + col0 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + - col0 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + col0 * - col2 + + col0 * col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + col2 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + ( + col1 * - col1 ) FROM tab2
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + cor0.col0 + - col1 + col1 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + col1 + col2 + col2 AS col0 FROM tab0 cor0
----
152
255
99

query I rowsort
SELECT - - col0 + + col0 * col2 FROM tab2 AS cor0
----
196
2106
3081

query III rowsort
SELECT * FROM tab0 WHERE - col0 * - col0 <> + col1 AND NULL IN ( + col0 )
----

query I rowsort
SELECT ALL col0 + tab0.col2 * tab0.col1 + - col1 FROM tab0
----
2776
35
7460

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col1 + - col1 col2 FROM tab1
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3543
SELECT ALL col1 * tab2.col1 DIV col0 AS col1 FROM tab2
----
137
3
44

skipif mysql # not compatible
query I rowsort label-3543
SELECT ALL col1 * tab2.col1 / col0 AS col1 FROM tab2
----
137
3
44

query I rowsort
SELECT ALL + col1 * + tab0.col1 * + col1 FROM tab0
----
636056
753571
912673

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3545
SELECT DISTINCT col0 + - col0 * - CAST( - col0 AS SIGNED ) FROM tab2 AS cor0
----
-42
-6006
-6162

skipif mysql # not compatible
query I rowsort label-3545
SELECT DISTINCT col0 + - col0 * - CAST ( - col0 AS INTEGER ) FROM tab2 AS cor0
----
-42
-6006
-6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-3546
SELECT DISTINCT - col1 DIV + col0 + - col0 * + 89 FROM tab1 AS cor0
----
-275
-5696
-7120

skipif mysql # not compatible
query I rowsort label-3546
SELECT DISTINCT - col1 / + col0 + - col0 * + 89 FROM tab1 AS cor0
----
-275
-5696
-7120

query I rowsort
SELECT + 16 + cor0.col1 FROM tab0 AS cor0
----
102
107
113

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 8 col1 FROM tab1 AS cor0
----
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3549
SELECT ALL + + cor0.col1 * col2 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3549
SELECT ALL + + cor0.col1 * col2 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 + col2 + + col0 AS col2 FROM tab2
----
182
196
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 * + col2 col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT - - 12 FROM tab0 cor0
----
12
12
12

query I rowsort
SELECT DISTINCT col1 + col0 * col2 + - col2 FROM tab2
----
193
2061
2981

onlyif mysql # use DIV operator for integer division
query I rowsort label-3554
SELECT - col0 * col1 DIV + col2 FROM tab1
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-3554
SELECT - col0 * col1 / + col2 FROM tab1
----
-1
-10
-11

query I rowsort
SELECT - col1 + + col0 * - tab1.col1 AS col1 FROM tab1
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT 60 * - col0 FROM tab2
----
-420
-4680
-4740

query I rowsort
SELECT - 66 * col2 * + col0 FROM tab0
----
-2310
-481668
-52272

query I rowsort
SELECT ALL tab0.col2 + col2 * col2 AS col0 FROM tab0
----
1122
2
6806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3559
SELECT ALL - col1 + col0 * CAST( ( col2 ) * - col2 + + 77 AS SIGNED ) FROM tab2 AS cor0
----
-108010
-4595
-46781

skipif mysql # not compatible
query I rowsort label-3559
SELECT ALL - col1 + col0 * CAST ( ( col2 ) * - col2 + + 77 AS INTEGER ) FROM tab2 AS cor0
----
-108010
-4595
-46781

onlyif mysql # use DIV operator for integer division
query I rowsort label-3560
SELECT DISTINCT + cor0.col1 * col1 DIV col2 FROM tab0 AS cor0
----
100
224
9409

skipif mysql # not compatible
query I rowsort label-3560
SELECT DISTINCT + cor0.col1 * col1 / col2 FROM tab0 AS cor0
----
100
224
9409

query I rowsort
SELECT ALL + col2 + col0 * - col2 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 93 col2 FROM tab1
----
93

query I rowsort
SELECT - tab2.col1 + col2 AS col1 FROM tab2
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-3564
SELECT - col0 DIV col0 - col2 * col1 * tab0.col0 FROM tab0
----
-3396
-664119
-68113

skipif mysql # not compatible
query I rowsort label-3564
SELECT - col0 / col0 - col2 * col1 * tab0.col0 FROM tab0
----
-3396
-664119
-68113

query I rowsort
SELECT ALL - col0 + col1 - + col2 FROM tab1
----
-111
-163
-31

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL IN ( col0 * col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 + col0 * tab2.col0 - col1 * + col0 col0 FROM tab2
----
-137
1541
4915

query I rowsort
SELECT - col0 * tab0.col1 * - col2 AS col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL - col0 * + col2 + tab0.col0 * col2 + col1 * - col0 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3570
SELECT + col0 DIV col0 - + col2 AS col1 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-3570
SELECT + col0 / col0 - + col2 AS col1 FROM tab1
----
-53
-56
-95

query I rowsort
SELECT DISTINCT + col0 + + col0 - + col1 * - col1 FROM tab1
----
228
329
682

query I rowsort
SELECT col1 * + col2 * tab2.col0 FROM tab2
----
119652
51034
5859

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL NOT IN ( col2 * col2 * col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3574
SELECT - col2 * tab0.col2 DIV col0 + col0 * col0 + - tab0.col1 AS col2 FROM tab0
----
1128
445
7755

skipif mysql # not compatible
query I rowsort label-3574
SELECT - col2 * tab0.col2 / col0 + col0 * col0 + - tab0.col1 AS col2 FROM tab0
----
1128
445
7755

query I rowsort
SELECT - col2 / + tab0.col0 - col2 AS col0 FROM tab0 WHERE NULL IN ( + col0 + + tab0.col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3576
SELECT ALL + col2 + col2 DIV col0 AS col1 FROM tab0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-3576
SELECT ALL + col2 + col2 / col0 AS col1 FROM tab0
----
1
34
82

query I rowsort
SELECT + col1 AS col2 FROM tab0 WHERE NULL BETWEEN ( NULL ) AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 - col1 * + col2 col0 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT + col0 * - tab0.col0 * - tab0.col1 FROM tab0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-3580
SELECT ALL col0 + col0 DIV col0 + col1 col2 FROM tab0
----
111
133
181

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3580
SELECT ALL col0 + col0 / col0 + col1 col2 FROM tab0
----
111
133
181

onlyif mysql # use DIV operator for integer division
query I rowsort label-3581
SELECT ALL col0 DIV col1 + + col0 * col1 + - col1 * col1 FROM tab2
----
-744
1058
1122

skipif mysql # not compatible
query I rowsort label-3581
SELECT ALL col0 / col1 + + col0 * col1 + - col1 * col1 FROM tab2
----
-744
1058
1122

query I rowsort
SELECT - col2 + col1 * - col0 * col1 AS col0 FROM tab0
----
-177537
-329316
-737091

onlyif mysql # use DIV operator for integer division
query I rowsort label-3583
SELECT DISTINCT col1 DIV + col1 + col2 DIV col2 AS col1 FROM tab0
----
2

skipif mysql # not compatible
query I rowsort label-3583
SELECT DISTINCT col1 / + col1 + col2 / col2 AS col1 FROM tab0
----
2

query III rowsort
SELECT * FROM tab2 WHERE NOT + col1 < NULL
----

query I rowsort
SELECT + col0 * - col2 * col1 + tab2.col2 * col1 AS col0 FROM tab2
----
-118118
-5022
-50388

onlyif mysql # use DIV operator for integer division
query I rowsort label-3586
SELECT DISTINCT col2 DIV - col2 + + col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3586
SELECT DISTINCT col2 / - col2 + + col0 FROM tab1
----
2
63
79

query I rowsort
SELECT ALL col2 * col1 FROM tab0 WHERE NOT ( + col2 ) BETWEEN - col0 + col2 * - col1 * col2 AND + col2
----

query I rowsort
SELECT DISTINCT tab1.col0 * - col2 * col1 + + col0 AS col0 FROM tab1
----
-36416
-4209
-99760

query I rowsort
SELECT + col0 * tab0.col2 * col0 + tab0.col0 FROM tab0
----
1260
19032
649611

onlyif mysql # use DIV operator for integer division
query I rowsort label-3590
SELECT + col0 DIV + col1 + col2 AS col0 FROM tab2
----
27
27
42

skipif mysql # not compatible
query I rowsort label-3590
SELECT + col0 / + col1 + col2 AS col0 FROM tab2
----
27
27
42

query I rowsort
SELECT + - col2 * col0 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT 80 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
80

query I rowsort
SELECT ALL col2 * - col0 * + 84 FROM tab1
----
-13608
-306432
-645120

query I rowsort
SELECT - col1 * 71 AS col0 FROM tab2 AS cor0
----
-1207
-2201
-4189

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - 11 col2 FROM tab2 AS cor0
----
286
297
418

query I rowsort
SELECT - col0 * + 43 FROM tab2 cor0
----
-301
-3354
-3397

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - 69 col2 FROM tab0 AS cor0
----
-34
-45
20

query I rowsort
SELECT ALL + col2 + ( 26 ) * col2 AS col1 FROM tab2 AS cor0
----
1026
702
729

query I rowsort
SELECT DISTINCT + - col0 * 32 * - col2 AS col1 FROM tab1 AS cor0
----
116736
245760
5184

query I rowsort
SELECT ALL + tab0.col2 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT 86 AS col2 FROM tab2, tab1 cor0, tab0, tab1 cor1
----
81 values hashing to e219687f6f4ab6f7ee442792edcebca9

query I rowsort
SELECT 89 * cor0.col0 + - tab0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 0e41329f1bbe84129137a3b5e9b6f092

query I rowsort
SELECT DISTINCT + 85 * cor1.col1 AS col0 FROM tab1, tab1 cor0, tab2, tab1 AS cor1
----
1105
2210
850

onlyif mysql # use DIV operator for integer division
query I rowsort label-3604
SELECT ALL - col0 DIV + 49 FROM tab2
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-3604
SELECT ALL - col0 / + 49 FROM tab2
----
-1
-1
0

query I rowsort
SELECT ALL cor0.col2 * col0 * - col2 AS col1 FROM tab2 AS cor0
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-3606
SELECT ALL - 77 DIV - 35 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-3606
SELECT ALL - 77 / - 35 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT ALL + 77 * + col2 FROM tab0 cor0
----
2541
6314
77

query I rowsort
SELECT DISTINCT + cor0.col2 + - col0 * col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT ALL - + 57 * col0 AS col2 FROM tab1 AS cor0
----
-171
-3648
-4560

query I rowsort
SELECT col0 * + col0 + - col0 AS col1 FROM tab0 AS cor0
----
1190
552
7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-3611
SELECT ALL + CAST( - cor0.col1 AS SIGNED ) DIV col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3611
SELECT ALL + CAST ( - cor0.col1 AS INTEGER ) / col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - + cor0.col1 * col1 + col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT ALL - - ( cor0.col2 ) AS col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - - col2 * col1 + - col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT - 95 FROM tab2, tab1 AS cor0, tab0 cor1
----
-95

query I rowsort
SELECT - col0 + - 40 FROM tab0
----
-129
-64
-75

query I rowsort
SELECT col0 + + cor0.col0 * 26 * - 77 AS col1 FROM tab1 AS cor0
----
-128064
-160080
-6003

query I rowsort
SELECT ALL + + ( col2 ) * 26 * 61 + + cor0.col2 * - col1 * - cor0.col1 + - col1 FROM tab1 AS cor0
----
122122
168467
96092

query I rowsort
SELECT - - 45 * col1 AS col1 FROM tab2 cor0
----
1395
2655
765

query I rowsort
SELECT 32 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

onlyif mysql # use DIV operator for integer division
query I rowsort label-3621
SELECT + col2 + col1 DIV col1 AS col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-3621
SELECT + col2 + col1 / col1 AS col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT DISTINCT ( - cor0.col2 ) FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
-1
-33
-82

query I rowsort
SELECT - + col2 + + ( col0 ) * col2 * col0 FROM tab0 AS cor0
----
1224
18975
649440

query I rowsort
SELECT DISTINCT ( + 3 ) AS col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
3

query I rowsort
SELECT col1 * - col2 + + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3626
SELECT CAST( NULL AS SIGNED ) / col0 - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3626
SELECT CAST ( NULL AS INTEGER ) / col0 - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * - 98 FROM tab2
----
-1666
-3038
-5782

query I rowsort
SELECT + cor1.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 cor2, tab2 AS cor3
----
243 values hashing to 291cdf20f55dc7bbcb55f561dc0b74d8

query I rowsort
SELECT DISTINCT col1 * - 32 + 87 FROM tab0
----
-2665
-2825
-3017

query I rowsort
SELECT col1 + 12 AS col2 FROM tab2
----
29
43
71

query I rowsort
SELECT DISTINCT ( - tab1.col0 + col2 ) FROM tab1
----
-7
16
51

query I rowsort
SELECT col1 + 61 * - col2 FROM tab0
----
-1927
-4911
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3633
SELECT CAST( + col0 AS SIGNED ) * + col0 col2 FROM tab0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3633
SELECT CAST ( + col0 AS INTEGER ) * + col0 col2 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + 65 + - 19 FROM tab0
----
46

query I rowsort
SELECT ALL - + col1 + + col2 * col0 AS col2 FROM tab2 AS cor0
----
158
1969
2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col2 - col2 col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT ( - ( - col0 ) ) FROM tab0
----
24
35
89

query I rowsort
SELECT - ( cor0.col2 ) AS col0 FROM tab1, tab0 cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT + 93 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT + col1 + + cor0.col0 * 25 AS col0 FROM tab0 AS cor0
----
2316
686
972

query I rowsort
SELECT - - col0 + 98 * col0 AS col2 FROM tab0 AS cor0
----
2376
3465
8811

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2, tab0 cor3
----
3645 values hashing to ac17da4547aa356439ff11568174588c

query I rowsort
SELECT DISTINCT - 14 * - ( + col1 * 63 ) FROM tab1
----
11466
22932
8820

query I rowsort
SELECT DISTINCT + col0 + col1 + - col2 FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT ALL - 38 FROM tab0, tab1 AS cor0
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

query I rowsort
SELECT + col2 * - 54 FROM tab1 AS cor0
----
-2916
-3078
-5184

onlyif mysql # use DIV operator for integer division
query I rowsort label-3647
SELECT ALL - - ( - col1 ) + col0 DIV - col2 AS col1 FROM tab1 AS cor0
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-3647
SELECT ALL - - ( - col1 ) + col0 / - col2 AS col1 FROM tab1 AS cor0
----
-11
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3648
SELECT DISTINCT + - col0 - + ( col0 + - CAST( NULL AS SIGNED ) ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3648
SELECT DISTINCT + - col0 - + ( col0 + - CAST ( NULL AS INTEGER ) ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * cor0.col1 + cor0.col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT 45 FROM tab0, tab2, tab0 AS cor0
----
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + tab1.col2 col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT 16 * - col0 FROM tab0
----
-1424
-384
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3653
SELECT ALL + col1 DIV + col0 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-3653
SELECT ALL + col1 / + col0 FROM tab2
----
0
0
4

query I rowsort
SELECT DISTINCT 72 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
72

query I rowsort
SELECT - col0 + col1 - ( ( - col0 ) ) FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3656
SELECT col2 * col1 + - col1 DIV col0 + 4 FROM tab2 AS cor0
----
1538
650
837

skipif mysql # not compatible
query I rowsort label-3656
SELECT col2 * col1 + - col1 / col0 + 4 FROM tab2 AS cor0
----
1538
650
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3657
SELECT - col2 DIV ( col0 ) + col0 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-3657
SELECT - col2 / ( col0 ) + col0 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT - col0 + col1 * ( col1 ) FROM tab0 AS cor0
----
7372
8192
9374

onlyif mysql # use DIV operator for integer division
query I rowsort label-3659
SELECT col1 DIV 19 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3659
SELECT col1 / 19 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3660
SELECT + - col1 + - CAST( NULL AS SIGNED ) * - col2 * - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3660
SELECT + - col1 + - CAST ( NULL AS INTEGER ) * - col2 * - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 79 * col2 AS col0 FROM tab0
----
-2607
-6478
-79

query I rowsort
SELECT + 98 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT DISTINCT 28 * - col0 FROM tab2
----
-196
-2184
-2212

query I rowsort
SELECT ALL + col0 * - ( 91 + + col0 ) * cor0.col0 FROM tab2 cor0
----
-1028196
-1060970
-4802

query I rowsort
SELECT ALL - col0 * - ( - col0 ) - - col1 FROM tab0 AS cor0
----
-1128
-490
-7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-3666
SELECT DISTINCT + col2 DIV ( 80 ) FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3666
SELECT DISTINCT + col2 / ( 80 ) FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT - col0 * ( + col1 * col0 ) FROM tab2 AS cor0
----
-106097
-1519
-358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-3668
SELECT - + col2 DIV col0 AS col0 FROM tab2 cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-3668
SELECT - + col2 / col0 AS col0 FROM tab2 cor0
----
-3
0
0

query I rowsort
SELECT DISTINCT + col0 * - 16 * - col2 FROM tab2 AS cor0
----
3024
32448
48032

query I rowsort
SELECT + - cor0.col0 - - col1 * - col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT cor0.col1 * 60 + + col0 * cor0.col1 + - col1 FROM tab2 AS cor0
----
2046
2346
8083

query I rowsort
SELECT ALL 47 - - cor1.col2 AS col1 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 396e4307689f81abc5cd855df9fb02a1

query I rowsort
SELECT DISTINCT + col2 - ( - 84 ) * + col0 AS col0 FROM tab1
----
306
5433
6816

query I rowsort
SELECT DISTINCT + ( ( - col1 ) ) + - 78 AS col2 FROM tab1 AS cor0
----
-104
-88
-91

query I rowsort
SELECT DISTINCT - 84 + col0 FROM tab0 AS cor0
----
-49
-60
5

query I rowsort
SELECT ALL cor0.col1 + - col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3677
SELECT - col2 DIV col2 + - col2 * col1 FROM tab1 AS cor0
----
-1249
-1405
-571

skipif mysql # not compatible
query I rowsort label-3677
SELECT - col2 / col2 + - col2 * col1 FROM tab1 AS cor0
----
-1249
-1405
-571

query I rowsort
SELECT ALL + col0 * - 7 AS col0 FROM tab1 AS cor0
----
-21
-448
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3679
SELECT DISTINCT ( + cor0.col1 ) DIV - col0 AS col0 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-3679
SELECT DISTINCT ( + cor0.col1 ) / - col0 AS col0 FROM tab2 AS cor0
----
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3680
SELECT ALL ( cor0.col1 ) + col1 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3680
SELECT ALL ( cor0.col1 ) + col1 / cor0.col2 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - + col2 + + 17 FROM tab1 AS cor0
----
-37
-40
-79

query I rowsort
SELECT ALL - col0 + col0 * cor0.col1 AS col2 FROM tab0 cor0
----
2040
3360
8010

query I rowsort
SELECT + ( col0 ) * col1 * col2 + col2 FROM tab1 AS cor0
----
36537
4266
99936

onlyif mysql # use DIV operator for integer division
query I rowsort label-3684
SELECT DISTINCT col0 * + col2 + col2 DIV col0 AS col0 FROM tab1
----
180
3648
7681

skipif mysql # not compatible
query I rowsort label-3684
SELECT DISTINCT col0 * + col2 + col2 / col0 AS col0 FROM tab1
----
180
3648
7681

query I rowsort
SELECT ALL + col1 * - col2 + col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT ALL col1 * - tab1.col0 + + tab1.col0 + + col2 AS col1 FROM tab1
----
-21
-519
-864

query I rowsort
SELECT + 35 + col2 FROM tab2 AS cor0
----
61
62
73

query I rowsort
SELECT DISTINCT + + 45 * - cor0.col2 AS col2 FROM tab2 cor0
----
-1170
-1215
-1710

query I rowsort
SELECT DISTINCT + - 20 AS col2 FROM tab2 cor0
----
-20

query I rowsort
SELECT DISTINCT - col0 * + col0 + + col2 AS col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT ALL - col1 - col2 * + 27 FROM tab1 AS cor0
----
-1484
-1549
-2605

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 50 * col2 col1 FROM tab2 cor0
----
1300
1350
1900

onlyif mysql # use DIV operator for integer division
query I rowsort label-3693
SELECT + col1 DIV col1 - col2 * + ( - col0 ) AS col0 FROM tab2
----
190
2029
3003

skipif mysql # not compatible
query I rowsort label-3693
SELECT + col1 / col1 - col2 * + ( - col0 ) AS col0 FROM tab2
----
190
2029
3003

query I rowsort
SELECT tab2.col2 + - col1 * + col2 * col0 FROM tab2
----
-119626
-50996
-5832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col2 col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - - ( + col0 ) AS col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3697
SELECT DISTINCT + col1 + col0 DIV col2 col0 FROM tab1 AS cor0
----
11
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3697
SELECT DISTINCT + col1 + col0 / col2 col0 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT DISTINCT - - 66 * cor0.col1 + col2 AS col2 FROM tab2 AS cor0
----
1160
2073
3920

onlyif mysql # use DIV operator for integer division
query I rowsort label-3699
SELECT DISTINCT col1 - + col1 DIV 94 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3699
SELECT DISTINCT col1 - + col1 / 94 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - 83 * - cor0.col2 FROM tab2 cor0
----
2158
2241
3154

query I rowsort
SELECT ALL + col1 * - col0 + col1 * - ( col1 ) FROM tab0 AS cor0
----
-12804
-16380
-9460

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 49 col2 FROM tab1 cor0
----
-49
-49
-49

query I rowsort
SELECT ALL + cor0.col2 * + col2 * col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT - 53 + col0 FROM tab0 AS cor0
----
-18
-29
36

query I rowsort
SELECT DISTINCT col2 + col0 + - col1 FROM tab1
----
111
163
31

query I rowsort
SELECT col1 + cor0.col2 * - col2 + - col0 AS col1 FROM tab1 AS cor0
----
-2893
-3303
-9283

query I rowsort
SELECT ALL - cor0.col0 + + cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 3b143560120db39ddcee311b43b28291

query I rowsort
SELECT 89 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3709
SELECT DISTINCT + CAST( + col0 AS SIGNED ) * col0 FROM tab0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-3709
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) * col0 FROM tab0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-3710
SELECT ALL col0 DIV - tab1.col0 AS col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3710
SELECT ALL col0 / - tab1.col0 AS col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT 31 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3712
SELECT - + col0 * CAST( col2 AS SIGNED ) + - col2 FROM tab0 AS cor0
----
-36
-7380
-825

skipif mysql # not compatible
query I rowsort label-3712
SELECT - + col0 * CAST ( col2 AS INTEGER ) + - col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT - col2 + 86 AS col2 FROM tab0 AS cor0
----
4
53
85

query I rowsort
SELECT DISTINCT - col1 + col1 * ( - col0 ) FROM tab1
----
-104
-1053
-650

query I rowsort
SELECT ALL + col0 * + col0 + + 23 FROM tab0
----
1248
599
7944

query I rowsort
SELECT ALL + cor0.col0 + 39 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1763677971ed517e8ab23621b1e2a094

query I rowsort
SELECT tab0.col0 * 18 FROM tab0
----
1602
432
630

query I rowsort
SELECT ALL + col1 + + 97 * 8 AS col0 FROM tab2 AS cor0
----
793
807
835

onlyif mysql # use DIV operator for integer division
query I rowsort label-3719
SELECT ALL col1 + - 82 DIV - col0 + col0 FROM tab2 AS cor0
----
138
49
97

skipif mysql # not compatible
query I rowsort label-3719
SELECT ALL col1 + - 82 / - col0 + col0 FROM tab2 AS cor0
----
138
49
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3720
SELECT DISTINCT col0 * col2 DIV 41 - - col0 FROM tab0 AS cor0
----
267
35
43

skipif mysql # not compatible
query I rowsort label-3720
SELECT DISTINCT col0 * col2 / 41 - - col0 FROM tab0 AS cor0
----
267
35
43

query I rowsort
SELECT DISTINCT + col0 * 0 FROM tab0 cor0
----
0

query I rowsort
SELECT ( + 48 ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3723
SELECT + col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3723
SELECT + col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3724
SELECT ALL + col2 + col1 + + cor0.col2 DIV col1 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-3724
SELECT ALL + col2 + col1 + + cor0.col2 / col1 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3725
SELECT - col0 + CAST( - col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-14
-156
-158

skipif mysql # not compatible
query I rowsort label-3725
SELECT - col0 + CAST ( - col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL - + col1 + - col0 * col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT + + col1 + + ( col2 ) FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - col1 * + ( + col0 ) AS col1 FROM tab1
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3729
SELECT DISTINCT - CAST( NULL AS SIGNED ) / + cor0.col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3729
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / + cor0.col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3730
SELECT DISTINCT - CAST( 90 AS SIGNED ) FROM tab0, tab1 cor0
----
-90

skipif mysql # not compatible
query I rowsort label-3730
SELECT DISTINCT - CAST ( 90 AS INTEGER ) FROM tab0, tab1 cor0
----
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3731
SELECT DISTINCT CAST( NULL AS SIGNED ) / tab0.col0 AS col1 FROM tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3731
SELECT DISTINCT CAST ( NULL AS INTEGER ) / tab0.col0 AS col1 FROM tab0, tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 8 + 98 AS col1 FROM tab1, tab2 AS cor0
----
106

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3733
SELECT - col1 * CAST( NULL AS SIGNED ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3733
SELECT - col1 * CAST ( NULL AS INTEGER ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( 22 ) * + cor0.col1 + 11 col0 FROM tab2 AS cor0
----
-1287
-363
-671

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 29 + col0 * cor0.col1 col2 FROM tab0 AS cor0
----
2093
3424
8128

query I rowsort
SELECT + cor0.col1 * + 84 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 1ff3e722835b8bcfd8482f4633931910

query I rowsort
SELECT - tab2.col0 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT - ( col1 ) * col1 * col1 + + col0 * - col2 AS col2 FROM tab0
----
-636848
-760869
-912708

query I rowsort
SELECT + - col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + + ( + col0 ) + + cor0.col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL + + 42 * col2 + col1 FROM tab2 AS cor0
----
1151
1165
1613

query I rowsort
SELECT - - col0 + - col2 * ( - col1 ) * col1 FROM tab1 cor0
----
16304
36507
5764

query I rowsort
SELECT col1 * + col1 - cor0.col1 * col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + + col0 * col1 * col1 FROM tab2 AS cor0
----
22910
271596
6734

query I rowsort
SELECT DISTINCT - + cor0.col1 * - col1 + col1 + cor0.col0 * col0 AS col2 FROM tab2 cor0
----
1041
6547
9624

query I rowsort
SELECT ALL + 40 + col2 AS col0 FROM tab1 cor0
----
136
94
97

query I rowsort
SELECT ALL 63 - - col0 FROM tab0 AS cor0
----
152
87
98

query I rowsort
SELECT DISTINCT + - col2 * + col2 * - col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT ALL - col0 + cor0.col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - + 97 + col2 AS col1 FROM tab0 cor0
----
-15
-64
-96

query I rowsort
SELECT DISTINCT + - col0 * - col1 * - col2 - + ( col2 ) AS col0 FROM tab1 AS cor0
----
-36537
-4266
-99936

query I rowsort
SELECT ALL col0 * + col0 * ( col0 * - col0 ) FROM tab1 AS cor0
----
-16777216
-40960000
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + col0 col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ( col2 ) * + 42 + col1 AS col0 FROM tab1 AS cor0
----
2294
2404
4045

query I rowsort
SELECT DISTINCT ( + 14 ) AS col1 FROM tab1, tab0, tab0 AS cor0
----
14

query I rowsort
SELECT + tab1.col1 + + col0 + col1 AS col0 FROM tab1
----
106
55
84

query I rowsort
SELECT + col1 * + col0 + cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT 19 * col0 AS col2 FROM tab0
----
1691
456
665

query I rowsort
SELECT - 40 - + col2 AS col0 FROM tab0
----
-122
-41
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3760
SELECT tab2.col1 * - col2 + CAST( - 58 AS SIGNED ) * + col1 + + col1 FROM tab2
----
-1615
-2604
-4897

skipif mysql # not compatible
query I rowsort label-3760
SELECT tab2.col1 * - col2 + CAST ( - 58 AS INTEGER ) * + col1 + + col1 FROM tab2
----
-1615
-2604
-4897

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3761
SELECT + - col1 * - col1 - - CAST( ( - col2 ) AS SIGNED ) FROM tab1 AS cor0
----
43
622
73

skipif mysql # not compatible
query I rowsort label-3761
SELECT + - col1 * - col1 - - CAST ( ( - col2 ) AS INTEGER ) FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT - 76 * - col2 FROM tab1 cor0
----
4104
4332
7296

query I rowsort
SELECT - 94 FROM tab0, tab2 cor0
----
9 values hashing to a95bfa539191d3f72f6548147d7efb9e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3764
SELECT DISTINCT CAST( NULL AS SIGNED ) - + col2 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3764
SELECT DISTINCT CAST ( NULL AS INTEGER ) - + col2 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 - - 63 FROM tab2
----
122
80
94

query I rowsort
SELECT ALL - 73 - tab2.col1 AS col0 FROM tab2
----
-104
-132
-90

query I rowsort
SELECT + 92 + - cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 108e6e88825e945098adc209136b4e60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3768
SELECT DISTINCT CAST( NULL AS SIGNED ) + col1 * col1 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3768
SELECT DISTINCT CAST ( NULL AS INTEGER ) + col1 * col1 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ( - 99 ) AS col2 FROM tab0 AS cor0
----
-99
-99
-99

query I rowsort
SELECT cor0.col2 AS col2 FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

onlyif mysql # use DIV operator for integer division
query I rowsort label-3771
SELECT DISTINCT - + 83 DIV - ( - col0 * col0 ) FROM tab2 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-3771
SELECT DISTINCT - + 83 / - ( - col0 * col0 ) FROM tab2 cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 99 ) * + col1 col2 FROM tab0 cor0
----
8514
9009
9603

query I rowsort
SELECT ALL - - ( + col2 ) * col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 99 col2 FROM tab1 AS cor0
----
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - 80 * - cor0.col1 col0 FROM tab0 cor0
----
6966
7371
7857

query I rowsort
SELECT ALL 93 * col0 + - col1 * + cor0.col0 FROM tab2 cor0
----
2652
434
6004

query I rowsort
SELECT ALL + 62 * col2 AS col2 FROM tab1 AS cor0
----
3348
3534
5952

query I rowsort
SELECT DISTINCT cor0.col1 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - 98 * + cor0.col1 - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1704
-3065
-5808

query I rowsort
SELECT 62 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3781
SELECT - col2 * col0 * - CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3781
SELECT - col2 * col0 * - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 87 * col2 + col0 * - 87 * col2 + col1 FROM tab0 AS cor0
----
-2861
-627701
-65947

query I rowsort
SELECT DISTINCT 29 + col1 AS col2 FROM tab1
----
39
42
55

query I rowsort
SELECT DISTINCT + - col2 * + col0 - - col0 * col0 AS col2 FROM tab1 AS cor0
----
-1280
-153
448

query I rowsort
SELECT DISTINCT 8 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
8

query I rowsort
SELECT 9 + col1 FROM tab0 AS cor0
----
100
106
95

query I rowsort
SELECT + + 31 * col0 FROM tab1 cor0
----
1984
2480
93

query I rowsort
SELECT DISTINCT 40 + cor0.col0 AS col1 FROM tab2 AS cor0
----
118
119
47

query I rowsort
SELECT ALL - + 97 * - col1 - - 91 AS col2 FROM tab1 AS cor0
----
1061
1352
2613

query I rowsort
SELECT - col2 * + 47 FROM tab1 AS cor0
----
-2538
-2679
-4512

query I rowsort
SELECT col0 * + 9 + - col1 AS col1 FROM tab2
----
32
643
694

query I rowsort
SELECT col1 + + 62 FROM tab2
----
121
79
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3793
SELECT + col1 + ( col2 ) * + col2 DIV + col2 AS col1 FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-3793
SELECT + col1 + ( col2 ) * + col2 / + col2 AS col1 FROM tab1
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 3 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + ( col1 ) col0 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3796
SELECT ALL + col1 * + CAST( NULL AS SIGNED ) * 8 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-3796
SELECT ALL + col1 * + CAST ( NULL AS INTEGER ) * 8 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col0 * - col1 + 3 * - col0 FROM tab2 AS cor0
----
-1580
-238
-4836

onlyif mysql # use DIV operator for integer division
query I rowsort label-3798
SELECT 60 DIV - col1 AS col1 FROM tab2 AS cor0
----
-1
-1
-3

skipif mysql # not compatible
query I rowsort label-3798
SELECT 60 / - col1 AS col1 FROM tab2 AS cor0
----
-1
-1
-3

query I rowsort
SELECT DISTINCT - 90 * col2 AS col2 FROM tab2 AS cor0
----
-2340
-2430
-3420

onlyif mysql # use DIV operator for integer division
query I rowsort label-3800
SELECT ALL - + col0 * col1 DIV + col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3800
SELECT ALL - + col0 * col1 / + col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + 21 * col2 AS col2 FROM tab0 AS cor0
----
1722
21
693

query I rowsort
SELECT ALL + + 96 AS col0 FROM tab0 AS cor0
----
96
96
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 79 col2 FROM tab2 cor0
----
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3804
SELECT ALL - + CAST( - cor0.col1 AS SIGNED ) * - col0 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3804
SELECT ALL - + CAST ( - cor0.col1 AS INTEGER ) * - col0 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + + col1 + cor0.col0 * + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - ( + col1 ) * col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-3807
SELECT col0 - + 40 DIV + col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3807
SELECT col0 - + 40 / + col2 FROM tab1
----
3
64
80

query I rowsort
SELECT col2 * + col0 * + col1 + col0 AS col0 FROM tab2
----
119730
51113
5866

query I rowsort
SELECT col0 + col2 * - col0 AS col2 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT - col2 * 49 FROM tab0
----
-1617
-4018
-49

onlyif mysql # use DIV operator for integer division
query I rowsort label-3811
SELECT - tab2.col0 - - 2 DIV + ( col0 * - col0 ) FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3811
SELECT - tab2.col0 - - 2 / + ( col0 * - col0 ) FROM tab2
----
-7
-78
-79

query I rowsort
SELECT DISTINCT ( + col1 ) * + 94 AS col1 FROM tab0
----
8084
8554
9118

query I rowsort
SELECT col2 * cor0.col0 - + col2 * col0 * col2 FROM tab1 cor0
----
-204288
-729600
-8586

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3814
SELECT - cor0.col1 + + CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3814
SELECT - cor0.col1 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + + 81 FROM tab0 cor0
----
81
81
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 95 * + col2 col2 FROM tab0 AS cor0
----
3135
7790
95

query I rowsort
SELECT col1 + ( col0 ) FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3818
SELECT + cor0.col0 DIV + col0 + + 99 FROM tab0 AS cor0
----
100
100
100

skipif mysql # not compatible
query I rowsort label-3818
SELECT + cor0.col0 / + col0 + + 99 FROM tab0 AS cor0
----
100
100
100

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3819
SELECT col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3819
SELECT col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * + cor0.col2 * + col1 AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT - col0 * - col2 * col1 + col0 FROM tab1
----
36544
4215
99920

query I rowsort
SELECT DISTINCT - 78 * + col1 * - ( tab2.col0 ) AS col1 FROM tab2
----
104754
16926
358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 * + ( 24 ) col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 2fdd9195e0c03d0b6ef1aaa26277ba72

query I rowsort
SELECT + - ( + cor0.col0 ) AS col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3825
SELECT DISTINCT + col1 * col0 DIV 35 + - ( + col1 ) * - tab1.col0 AS col2 FROM tab1
----
1069
658
80

skipif mysql # not compatible
query I rowsort label-3825
SELECT DISTINCT + col1 * col0 / 35 + - ( + col1 ) * - tab1.col0 AS col2 FROM tab1
----
1069
658
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3826
SELECT - ( col1 ) DIV 79 + col0 * col2 + + col0 FROM tab1
----
165
3712
7760

skipif mysql # not compatible
query I rowsort label-3826
SELECT - ( col1 ) / 79 + col0 * col2 + + col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT - 17 * cor0.col2 FROM tab0 AS cor0
----
-1394
-17
-561

query I rowsort
SELECT ALL + - ( + col1 ) + - cor0.col2 AS col0 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT + col0 * - col0 + col1 - - col0 AS col0 FROM tab2 AS cor0
----
-11
-5947
-6145

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3830
SELECT CAST( + col2 AS SIGNED ) * col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-3830
SELECT CAST ( + col2 AS INTEGER ) * col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-3831
SELECT DISTINCT - + col1 DIV col0 + col0 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-3831
SELECT DISTINCT - + col1 / col0 + col0 FROM tab0 AS cor0
----
21
33
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 84 + - col0 * col2 col1 FROM tab0 AS cor0
----
-119
-7382
-876

query I rowsort
SELECT - col0 * col0 + + col1 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT ALL - 48 + - col1 * cor0.col2 AS col2 FROM tab2 AS cor0
----
-1582
-694
-885

query I rowsort
SELECT ALL - col0 * + col0 + col1 * - col0 * + col2 AS col2 FROM tab0 AS cor0
----
-4620
-672039
-68688

query I rowsort
SELECT DISTINCT - - 94 + - 40 * + col1 FROM tab0 AS cor0
----
-3346
-3546
-3786

query I rowsort
SELECT - col2 * + col0 + + tab0.col2 * - col0 AS col1 FROM tab0
----
-14596
-1584
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 + col1 * - col2 col2 FROM tab2
----
-648
2356
494

query I rowsort
SELECT ALL 16 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3840
SELECT - 23 DIV - col2 FROM tab0 AS cor0
----
0
0
23

skipif mysql # not compatible
query I rowsort label-3840
SELECT - 23 / - col2 FROM tab0 AS cor0
----
0
0
23

query I rowsort
SELECT - col1 - + 63 FROM tab2
----
-122
-80
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3842
SELECT - CAST( NULL AS DECIMAL ) * - tab1.col0 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3842
SELECT - CAST ( NULL AS REAL ) * - tab1.col0 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + + 19 AS col0 FROM tab0
----
101
20
52

query I rowsort
SELECT - + col1 + + col1 * 16 AS col1 FROM tab0 AS cor0
----
1290
1365
1455

onlyif mysql # use DIV operator for integer division
query I rowsort label-3845
SELECT ALL + col0 + col0 DIV + col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-3845
SELECT ALL + col0 + col0 / + col2 FROM tab0
----
24
70
90

query I rowsort
SELECT + + tab1.col0 FROM tab1, tab2 cor0, tab0, tab2 AS cor1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

onlyif mysql # use DIV operator for integer division
query I rowsort label-3847
SELECT DISTINCT - ( col2 ) + - col2 DIV 19 FROM tab0
----
-1
-34
-86

skipif mysql # not compatible
query I rowsort label-3847
SELECT DISTINCT - ( col2 ) + - col2 / 19 FROM tab0
----
-1
-34
-86

query I rowsort
SELECT DISTINCT - - col2 + - 86 AS col0 FROM tab0 AS cor0
----
-4
-53
-85

query I rowsort
SELECT + 6 + 1 * col2 AS col0 FROM tab2 AS cor0
----
32
33
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-3850
SELECT col2 * 15 DIV + col0 AS col1 FROM tab1
----
13
18
270

skipif mysql # not compatible
query I rowsort label-3850
SELECT col2 * 15 / + col0 AS col1 FROM tab1
----
13
18
270

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 96 * cor0.col1 * + col1 col1 FROM tab2 AS cor0
----
27744
334176
92256

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( + col2 + col0 AS REAL ) * - col0 FROM tab1
----
-14080
-171
-7744

query I rowsort
SELECT col2 - cor0.col0 * + col0 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT - 85 + - col0 * + col1 FROM tab0 cor0
----
-2149
-3480
-8184

query I rowsort
SELECT + + 85 + col2 FROM tab2 AS cor0
----
111
112
123

query I rowsort
SELECT DISTINCT - ( 92 ) AS col0 FROM tab0
----
-92

query I rowsort
SELECT ( tab1.col0 * - col2 ) FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ( + 97 ) FROM tab2
----
97
97
97

query I rowsort
SELECT - 6 * col2 + col1 AS col2 FROM tab0 AS cor0
----
-112
-401
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 - + col2 col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT 54 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT col1 + + ( + col0 ) AS col2 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3864
SELECT DISTINCT - cor0.col0 DIV + ( + col0 ) FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3864
SELECT DISTINCT - cor0.col0 / + ( + col0 ) FROM tab1 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3865
SELECT + col1 + col0 DIV 26 FROM tab1 cor0
----
12
16
26

skipif mysql # not compatible
query I rowsort label-3865
SELECT + col1 + col0 / 26 FROM tab1 cor0
----
12
16
26

query I rowsort
SELECT ALL - cor0.col2 * - 90 AS col0 FROM tab1 AS cor0
----
4860
5130
8640

query I rowsort
SELECT DISTINCT cor0.col0 * 24 FROM tab1 AS cor0
----
1536
1920
72

query I rowsort
SELECT - col2 * cor0.col1 * 76 FROM tab2 AS cor0
----
-116584
-49096
-63612

query I rowsort
SELECT + col2 * 28 AS col1 FROM tab1 AS cor0
----
1512
1596
2688

query I rowsort
SELECT - cor0.col0 * 38 + 46 + + cor0.col2 FROM tab1 cor0
----
-14
-2329
-2898

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0, tab0 cor2
----
3645 values hashing to a5677c50b23f70287df35c2388a1c9bf

query I rowsort
SELECT - cor0.col1 * + col0 + - 15 + cor0.col1 FROM tab2 AS cor0
----
-1341
-201
-4558

query I rowsort
SELECT ALL col0 * ( - col2 ) AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + 29 * tab0.col1 FROM tab0
----
2494
2639
2813

query I rowsort
SELECT DISTINCT 51 * - ( col1 ) FROM tab1
----
-1326
-510
-663

query I rowsort
SELECT ALL + - cor0.col0 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT - ( + ( cor0.col2 ) ) * col1 + col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT - col1 * col0 + col2 * cor0.col1 FROM tab2 cor0
----
-3068
-697
620

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 2 col1 FROM tab0 AS cor0
----
3
35
84

query I rowsort
SELECT col0 * ( 39 ) FROM tab0 AS cor0
----
1365
3471
936

query I rowsort
SELECT DISTINCT col2 * + col1 * + col0 AS col1 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT + cor0.col2 * 46 FROM tab1 AS cor0
----
2484
2622
4416

query I rowsort
SELECT DISTINCT + + col2 + col0 + col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT col0 * ( col2 ) AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + col2 + ( + 82 + + col0 ) FROM tab0 AS cor0
----
118
139
253

query I rowsort
SELECT ALL - col2 * cor0.col0 * col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3887
SELECT DISTINCT + col0 + - col1 DIV col0 AS col2 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-3887
SELECT DISTINCT + col0 + - col1 / col0 AS col2 FROM tab0 AS cor0
----
21
33
88

query I rowsort
SELECT ALL col1 + 50 * + col2 FROM tab0 AS cor0
----
147
1736
4191

onlyif mysql # use DIV operator for integer division
query I rowsort label-3889
SELECT DISTINCT col1 DIV + 91 AS col1 FROM tab0 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3889
SELECT DISTINCT col1 / + 91 AS col1 FROM tab0 cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3890
SELECT ALL + CAST( - col1 AS SIGNED ) * - col1 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-3890
SELECT ALL + CAST ( - col1 AS INTEGER ) * - col1 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-3891
SELECT + + col1 + + col0 DIV col0 AS col0 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3891
SELECT + + col1 + + col0 / col0 AS col0 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col2 * col0 * + col1 + - col1 FROM tab2 cor0
----
119593
51017
5828

query I rowsort
SELECT - - 92 + col1 AS col2 FROM tab2 AS cor0
----
109
123
151

query I rowsort
SELECT DISTINCT ( - cor0.col1 ) + cor0.col0 FROM tab0 AS cor0
----
-2
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3896
SELECT DISTINCT 92 - col0 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3896
SELECT DISTINCT 92 - col0 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT DISTINCT + + col1 * col2 DIV - col1 + col2 * - col0 FROM tab2 cor0
----
-2054
-216
-3040

skipif mysql # not compatible
query I rowsort label-3897
SELECT DISTINCT + + col1 * col2 / - col1 + col2 * - col0 FROM tab2 cor0
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT - 2 AS col0 FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
-2

query I rowsort
SELECT ALL - 86 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 9d2e1e8eda15b3b83dd7136dfc4f19af

query I rowsort
SELECT - + 49 * col2 + - col2 FROM tab0 AS cor0
----
-1650
-4100
-50

query I rowsort
SELECT col2 + col0 * col1 AS col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT cor0.col2 * + 29 + - col2 * col2 * ( - col1 * col2 ) FROM tab2 cor0
----
1037738
610956
933926

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 54 col1 FROM tab2 AS cor0
----
-378
-4212
-4266

query I rowsort
SELECT ALL col1 * 38 - - 1 AS col1 FROM tab0 AS cor0
----
3269
3459
3687

query I rowsort
SELECT ALL + 70 + 80 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e82c94b49ed2abae0dd33f4964a22998

query I rowsort
SELECT - col1 + + col0 * + col0 AS col2 FROM tab1 AS cor0
----
-17
4086
6387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - col2 * col0 + col2 * - col2 AS col0 FROM tab2
----
-2704
-4446
-918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3910
SELECT DISTINCT + col1 * CAST( NULL AS DECIMAL ) + - cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3910
SELECT DISTINCT + col1 * CAST ( NULL AS REAL ) + - cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col0 + ( - cor0.col1 ) + col2 * ( - 39 ) AS col0 FROM tab0 cor0
----
-101
-1349
-3200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3912
SELECT - cor0.col1 * CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-3912
SELECT - cor0.col1 * CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-3913
SELECT ALL + - cor0.col1 + + col1 DIV col2 FROM tab0 AS cor0
----
-84
-90
0

skipif mysql # not compatible
query I rowsort label-3913
SELECT ALL + - cor0.col1 + + col1 / col2 FROM tab0 AS cor0
----
-84
-90
0

query I rowsort
SELECT ALL + ( + tab2.col0 ) + col2 * + 35 * + col1 FROM tab2
----
22689
29302
53768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3915
SELECT + CAST( col0 AS SIGNED ) * tab1.col0 * + col1 FROM tab1
----
234
40960
83200

skipif mysql # not compatible
query I rowsort label-3915
SELECT + CAST ( col0 AS INTEGER ) * tab1.col0 * + col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT DISTINCT ( col0 ) + col0 * - ( - col0 ) + col1 FROM tab0
----
1357
686
8101

query I rowsort
SELECT - col2 * - ( tab0.col0 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL - col0 + col1 + + col2 FROM tab0
----
63
84
95

query I rowsort
SELECT ALL - col0 * col2 + + col1 AS col1 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT ALL 9 FROM tab2, tab2 cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT ALL ( col0 ) * col2 * + col1 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT ALL - col0 + + col0 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 + col1 col0 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-3924
SELECT DISTINCT - col2 + + col2 DIV - col1 AS col2 FROM tab2
----
-26
-27
-40

skipif mysql # not compatible
query I rowsort label-3924
SELECT DISTINCT - col2 + + col2 / - col1 AS col2 FROM tab2
----
-26
-27
-40

onlyif mysql # use DIV operator for integer division
query I rowsort label-3925
SELECT - col0 * 50 * col1 - - cor0.col1 DIV col1 FROM tab0 AS cor0
----
-103199
-169749
-404949

skipif mysql # not compatible
query I rowsort label-3925
SELECT - col0 * 50 * col1 - - cor0.col1 / col1 FROM tab0 AS cor0
----
-103199
-169749
-404949

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - cor0.col1 col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - 44 * - col2 AS col0 FROM tab0 AS cor0
----
1452
3608
44

query I rowsort
SELECT ALL - col0 * col1 * + col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3929
SELECT + col0 * + col2 + CAST( col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
188
3658
7693

skipif mysql # not compatible
query I rowsort label-3929
SELECT + col0 * + col2 + CAST ( col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT col2 * + cor0.col2 * - 35 FROM tab1 AS cor0
----
-102060
-113715
-322560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3931
SELECT ALL 19 DIV col1 col2 FROM tab1 AS cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3931
SELECT ALL 19 / col1 col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT - cor0.col2 * col2 * col0 AS col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT - col1 + + col2 * col1 AS col1 FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT - 8 * - col1 FROM tab2 cor0
----
136
248
472

query I rowsort
SELECT ALL - ( 11 ) AS col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

onlyif mysql # use DIV operator for integer division
query I rowsort label-3936
SELECT - - col1 * col0 DIV ( - col2 ) FROM tab1 AS cor0
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-3936
SELECT - - col1 * col0 / ( - col2 ) FROM tab1 AS cor0
----
-1
-10
-11

query I rowsort
SELECT ALL - - cor0.col0 + col2 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + - col2 * - col0 + + col0 * + col0 * col0 AS col1 FROM tab1 AS cor0
----
189
265792
519680

query I rowsort
SELECT ALL + cor0.col1 * col0 + col2 * col0 FROM tab2 AS cor0
----
406
4345
6630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - + col1 * col2 col0 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL - col2 + + col0 * + col0 FROM tab2
----
22
6058
6203

query I rowsort
SELECT tab0.col1 + + col1 + - col1 AS col1 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3943
SELECT ALL - - col0 * col1 DIV col1 - col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3943
SELECT ALL - - col0 * col1 / col1 - col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - col2 ) col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + cor0.col1 + tab1.col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 1862f595915606d50db23af568ede954

query I rowsort
SELECT - col2 + - cor0.col0 * col0 FROM tab0 AS cor0
----
-1226
-609
-8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-3947
SELECT ALL - tab2.col1 DIV - col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3947
SELECT ALL - tab2.col1 / - col1 FROM tab2
----
1
1
1

query I rowsort
SELECT col0 * 42 + col0 FROM tab0
----
1032
1505
3827

query I rowsort
SELECT + col1 + 68 * 31 AS col0 FROM tab2
----
2125
2139
2167

query I rowsort
SELECT ALL - ( cor0.col2 ) * cor0.col2 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 42bf3b8f2bb865dbe16abdf6d3d647fc

query I rowsort
SELECT ALL - - col1 * col1 * col2 AS col2 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT ALL + + col0 * 57 FROM tab2 AS cor0
----
399
4446
4503

query I rowsort
SELECT - - cor0.col0 * - ( 31 ) * col2 AS col1 FROM tab2 AS cor0
----
-5859
-62868
-93062

query I rowsort
SELECT 62 * - cor0.col2 * cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 70f8931f04ab1fd3c59193a0fee204df

query I rowsort
SELECT ALL col0 + + ( 66 ) * col0 FROM tab2 AS cor0
----
469
5226
5293

query I rowsort
SELECT 48 * - 43 AS col0 FROM tab2 AS cor0
----
-2064
-2064
-2064

query I rowsort
SELECT ALL - 69 * col2 + + cor0.col0 FROM tab0 AS cor0
----
-2253
-34
-5569

onlyif mysql # use DIV operator for integer division
query I rowsort label-3958
SELECT DISTINCT ( + cor0.col0 ) DIV - col1 - 68 FROM tab0 AS cor0
----
-68

skipif mysql # not compatible
query I rowsort label-3958
SELECT DISTINCT ( + cor0.col0 ) / - col1 - 68 FROM tab0 AS cor0
----
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-3959
SELECT DISTINCT - col1 * + cor0.col2 + - col2 DIV 92 AS col0 FROM tab1 AS cor0
----
-1249
-1404
-570

skipif mysql # not compatible
query I rowsort label-3959
SELECT DISTINCT - col1 * + cor0.col2 + - col2 / 92 AS col0 FROM tab1 AS cor0
----
-1249
-1404
-570

query I rowsort
SELECT - + ( cor0.col2 ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL ( - col2 ) + col1 * 21 AS col2 FROM tab2 AS cor0
----
1213
319
624

onlyif mysql # use DIV operator for integer division
query I rowsort label-3962
SELECT - col1 DIV - tab0.col0 + 91 AS col2 FROM tab0
----
92
93
94

skipif mysql # not compatible
query I rowsort label-3962
SELECT - col1 / - tab0.col0 + 91 AS col2 FROM tab0
----
92
93
94

query I rowsort
SELECT - 48 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 31c94943c073954e4ca20b170ab61f8c

query I rowsort
SELECT - 15 * col2 AS col1 FROM tab2 AS cor0
----
-390
-405
-570

query I rowsort
SELECT + 45 * - col1 * col1 FROM tab0 AS cor0
----
-332820
-372645
-423405

query I rowsort
SELECT + 51 * col2 FROM tab2 AS cor0
----
1326
1377
1938

query I rowsort
SELECT DISTINCT + 30 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab0 AS cor2
----
30

query I rowsort
SELECT + 77 + 35 FROM tab2
----
112
112
112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + cor0.col0 * - ( + cor0.col0 ) col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-3970
SELECT DISTINCT 97 DIV + col0 AS col1 FROM tab2 AS cor0
----
1
13

skipif mysql # not compatible
query I rowsort label-3970
SELECT DISTINCT 97 / + col0 AS col1 FROM tab2 AS cor0
----
1
13

query I rowsort
SELECT + 82 * col0 FROM tab2 AS cor0
----
574
6396
6478

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + + col0 * - col0 col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL 36 * 29 AS col2 FROM tab0
----
1044
1044
1044

query I rowsort
SELECT DISTINCT + col2 * 80 AS col0 FROM tab0
----
2640
6560
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + 33 col2 FROM tab1
----
-2112
-2640
-99

query I rowsort
SELECT col2 + 72 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1818
-663
-840

query I rowsort
SELECT + col0 * 31 AS col1 FROM tab0 AS cor0
----
1085
2759
744

query I rowsort
SELECT - - col1 * + col1 * col0 + col2 * - col1 * 37 FROM tab1 AS cor0
----
-14690
-32656
-49920

query I rowsort
SELECT + col0 + col1 * - cor0.col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT - col1 * - col2 * col2 AS col2 FROM tab1
----
119808
32490
75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 1 col0 FROM tab1
----
10
13
26

query I rowsort
SELECT - col1 + + col1 * + col1 AS col2 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT - col1 + 75 + cor0.col2 FROM tab1 AS cor0
----
103
122
158

query I rowsort
SELECT 68 - + col0 * - tab0.col2 * - col1 AS col2 FROM tab0
----
-3327
-664050
-68044

query I rowsort
SELECT ALL + col2 * - col2 * ( 48 ) FROM tab0
----
-322752
-48
-52272

query I rowsort
SELECT DISTINCT - + col0 + - col0 * 44 + col2 * col1 AS col2 FROM tab0 AS cor0
----
-1478
1758
3457

query I rowsort
SELECT + col1 + col1 * + ( col2 + - col2 ) * - col2 FROM tab0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + 68 ) col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1, tab2 cor0, tab2 cor1
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT 64 + - col0 FROM tab0
----
-25
29
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-3991
SELECT DISTINCT - - col0 + 47 DIV col1 AS col2 FROM tab1 cor0
----
4
68
83

skipif mysql # not compatible
query I rowsort label-3991
SELECT DISTINCT - - col0 + 47 / col1 AS col2 FROM tab1 cor0
----
4
68
83

query I rowsort
SELECT + - col2 * 32 FROM tab0 AS cor0
----
-1056
-2624
-32

query I rowsort
SELECT ALL + + col0 - col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL col0 * - 59 + col1 FROM tab0 AS cor0
----
-1330
-1968
-5160

onlyif mysql # use DIV operator for integer division
query I rowsort label-3995
SELECT DISTINCT + - col2 DIV - ( - 61 ) - - col0 * 17 FROM tab0 AS cor0
----
1512
408
595

skipif mysql # not compatible
query I rowsort label-3995
SELECT DISTINCT + - col2 / - ( - 61 ) - - col0 * 17 FROM tab0 AS cor0
----
1512
408
595

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * cor0.col2 col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + cor0.col2 + cor0.col0 * col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL col2 + ( col2 ) AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL - cor0.col1 + + ( - col0 ) AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT + + col1 * 24 FROM tab0 AS cor0
----
2064
2184
2328

query I rowsort
SELECT DISTINCT - col0 * col0 + - col0 * col1 FROM tab0 AS cor0
----
-16020
-2640
-4620

query I rowsort
SELECT DISTINCT col2 + + 89 AS col2 FROM tab2 cor0
----
115
116
127

query I rowsort
SELECT ALL - col0 + 11 FROM tab2 AS cor0
----
-67
-68
4

query I rowsort
SELECT DISTINCT - - cor0.col0 * 62 FROM tab0 AS cor0
----
1488
2170
5518

query I rowsort
SELECT + - col1 + + col0 * + col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT - ( 93 ) + cor0.col2 AS col0 FROM tab0 AS cor0
----
-11
-60
-92

query I rowsort
SELECT ( - col0 ) - + col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + 75 * + tab0.col1 + col2 AS col2 FROM tab0
----
6483
6907
7276

query I rowsort
SELECT ALL + - ( + 49 ) AS col2 FROM tab1 AS cor0
----
-49
-49
-49

query I rowsort
SELECT ( - cor0.col0 ) * col2 + 6 * col1 AS col0 FROM tab2 AS cor0
----
-1674
-2900
-3

query I rowsort
SELECT DISTINCT ( ( + col1 ) ) AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT 18 * 63 + - col0 FROM tab0 AS cor0
----
1045
1099
1110

query I rowsort
SELECT + 3 + - ( - col1 * ( - col2 ) ) FROM tab2 AS cor0
----
-1531
-643
-834

query I rowsort
SELECT DISTINCT 88 + col1 FROM tab2 AS cor0
----
105
119
147

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col0 ) + + col2 + col0 col0 FROM tab2 AS cor0
----
182
196
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-4016
SELECT DISTINCT + - ( - col2 ) DIV + col0 FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-4016
SELECT DISTINCT + - ( - col2 ) / + col0 FROM tab2 AS cor0
----
0
3

query I rowsort
SELECT ALL - cor0.col2 + cor0.col1 * + col1 * cor0.col0 FROM tab2 AS cor0
----
22793
271492
6700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4018
SELECT DISTINCT col2 * col2 + CAST( 17 AS SIGNED ) FROM tab2 AS cor0
----
1461
693
746

skipif mysql # not compatible
query I rowsort label-4018
SELECT DISTINCT col2 * col2 + CAST ( 17 AS INTEGER ) FROM tab2 AS cor0
----
1461
693
746

query I rowsort
SELECT - col2 + + col2 * - ( 15 ) FROM tab2 cor0
----
-416
-432
-608

query I rowsort
SELECT DISTINCT 12 * + col1 * + col1 AS col0 FROM tab0 AS cor0
----
112908
88752
99372

query I rowsort
SELECT - cor0.col1 FROM tab2, tab1 AS cor0, tab0, tab2 AS cor1
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4022
SELECT DISTINCT 79 DIV - col0 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-4022
SELECT DISTINCT 79 / - col0 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT + col0 * + col0 + - 45 * + 91 + + cor0.col2 AS col1 FROM tab2 cor0
----
-4019
2015
2184

query I rowsort
SELECT DISTINCT + - col0 * + col0 AS col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL 14 * - col1 * + col0 + + col0 FROM tab1 AS cor0
----
-1089
-14480
-8896

query I rowsort
SELECT ALL col1 + col0 * ( - col1 ) AS col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT col2 + + col1 + col1 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT ALL 14 * col1 FROM tab1 cor0
----
140
182
364

query I rowsort
SELECT DISTINCT - ( col2 ) * ( - 69 ) FROM tab2 AS cor0
----
1794
1863
2622

query I rowsort
SELECT + - 17 * col0 + ( ( col2 ) ) AS col1 FROM tab1 AS cor0
----
-1031
-1264
3

query I rowsort
SELECT + col0 + col2 * col2 AS col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT + - col0 + + col0 AS col1 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * - col0 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 48 * col0 + + ( col2 * col0 + - cor0.col2 ) col1 FROM tab1 AS cor0
----
-36
3744
519

query I rowsort
SELECT ALL + col2 * + col2 + 16 * col1 FROM tab1 AS cor0
----
3332
3409
9424

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + cor0.col1 + 12 col1 FROM tab0 AS cor0
----
7408
8293
9421

query I rowsort
SELECT - - col0 + - ( 46 ) + col2 AS col1 FROM tab1 AS cor0
----
11
130
75

query I rowsort
SELECT + col2 * col0 * col1 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + 99 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

query I rowsort
SELECT - col0 * 84 * col2 AS col1 FROM tab1 AS cor0
----
-13608
-306432
-645120

query I rowsort
SELECT ALL 49 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT ALL + + 40 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT - + 76 AS col0 FROM tab1 AS cor0
----
-76
-76
-76

query I rowsort
SELECT DISTINCT - - 86 * + 5 * col1 AS col1 FROM tab1 AS cor0
----
11180
4300
5590

query I rowsort
SELECT col0 - + col1 * - tab1.col2 AS col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL - + col1 + + 88 FROM tab2 AS cor0
----
29
57
71

query I rowsort
SELECT DISTINCT cor0.col1 * col2 * + col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL col2 + 80 FROM tab1
----
134
137
176

query I rowsort
SELECT DISTINCT + col2 * 83 + col0 FROM tab2
----
2236
2248
3233

onlyif mysql # use DIV operator for integer division
query I rowsort label-4050
SELECT tab1.col0 DIV 68 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4050
SELECT tab1.col0 / 68 FROM tab1
----
0
0
1

query I rowsort
SELECT DISTINCT + 54 + col2 AS col1 FROM tab0
----
136
55
87

query I rowsort
SELECT ALL tab2.col0 + - col0 + col0 * col0 * - col1 AS col0 FROM tab2
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - ( + col2 ) col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 + col1 AS col0 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT + 66 - - col0 * col1 AS col1 FROM tab1 AS cor0
----
1106
144
706

query I rowsort
SELECT DISTINCT - + col2 + col0 * + col0 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT + 36 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT ALL - col0 + - 18 * col1 AS col1 FROM tab2 cor0
----
-1140
-385
-565

query I rowsort
SELECT ALL col0 * 13 AS col0 FROM tab1 cor0
----
1040
39
832

query I rowsort
SELECT + ( - col1 + col1 ) * 0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4061
SELECT + 60 + col2 DIV - col0 AS col0 FROM tab0
----
59
60
60

skipif mysql # not compatible
query I rowsort label-4061
SELECT + 60 + col2 / - col0 AS col0 FROM tab0
----
59
60
60

query I rowsort
SELECT 10 - + col2 * col1 AS col1 FROM tab1 AS cor0
----
-1238
-1394
-560

query I rowsort
SELECT DISTINCT + col0 - 15 * col2 * ( - col1 ) FROM tab2 AS cor0
----
12562
23088
9769

query I rowsort
SELECT ALL col0 - + col1 * + col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL - 75 * + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 639efcf95382c0e4655b8e9bec96eac3

query I rowsort
SELECT ALL 16 + + cor0.col2 + 84 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to db36630964f2830d566a1fe09868d27b

query I rowsort
SELECT DISTINCT cor0.col1 * ( - col2 ) + - col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-15561
-3492
-4902

query I rowsort
SELECT - + col1 * - col2 + 7 FROM tab1 AS cor0
----
1255
1411
577

query I rowsort
SELECT + ( 49 ) FROM tab1
----
49
49
49

query I rowsort
SELECT - 86 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 9ac806793c03d3a6b5e3a3029d20e4da

query I rowsort
SELECT DISTINCT + ( + col2 ) * - col1 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4072
SELECT col0 DIV tab0.col2 + col0 AS col0 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-4072
SELECT col0 / tab0.col2 + col0 AS col0 FROM tab0
----
24
70
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4073
SELECT ALL ( col2 ) DIV + tab0.col1 + - 8 FROM tab0
----
-8
-8
-8

skipif mysql # not compatible
query I rowsort label-4073
SELECT ALL ( col2 ) / + tab0.col1 + - 8 FROM tab0
----
-8
-8
-8

query I rowsort
SELECT ALL - cor0.col0 * - cor0.col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + - 81 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
567
6318
6399

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( + col1 ) + + col2 * - ( 22 * + col1 ) col2 FROM tab2 cor0
----
-14229
-18445
-33807

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4077
SELECT ALL col0 + - col2 + - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4077
SELECT ALL col0 + - col2 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 95 + + col1 * - col2 FROM tab1 AS cor0
----
-1343
-1499
-665

query I rowsort
SELECT DISTINCT - 13 - + col2 FROM tab0 AS cor0
----
-14
-46
-95

query I rowsort
SELECT ALL - 17 * col1 AS col2 FROM tab2 AS cor0
----
-1003
-289
-527

query I rowsort
SELECT + + 67 + col1 AS col2 FROM tab0 AS cor0
----
153
158
164

query I rowsort
SELECT - col0 + - col0 * + col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT - 44 * col0 * + tab1.col1 - + col1 FROM tab1
----
-28170
-3458
-45773

query I rowsort
SELECT 59 * - col0 * col0 FROM tab2
----
-2891
-358956
-368219

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - tab0.col0 AS REAL ) AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-24
-35
-89

query I rowsort
SELECT + + col2 * + ( + col1 ) AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 col2 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4088
SELECT + + col0 DIV col2 AS col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4088
SELECT + + col0 / col2 AS col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT - col0 * - 44 + + col1 FROM tab2 AS cor0
----
339
3491
3493

query I rowsort
SELECT col1 * cor0.col0 * + col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + col0 * + 8 + cor0.col2 AS col1 FROM tab2 AS cor0
----
650
670
83

query I rowsort
SELECT + col2 * - col1 - cor0.col0 AS col0 FROM tab2 cor0
----
-1612
-725
-844

query I rowsort
SELECT + col0 * - 30 + col2 AS col2 FROM tab0 cor0
----
-1049
-2588
-687

onlyif mysql # use DIV operator for integer division
query I rowsort label-4094
SELECT - - 4 DIV col1 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4094
SELECT - - 4 / col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + + 8 + + col0 - cor0.col0 AS col1 FROM tab0 AS cor0
----
8
8
8

query I rowsort
SELECT + ( - 71 ) + - cor0.col2 FROM tab1 AS cor0
----
-125
-128
-167

onlyif mysql # use DIV operator for integer division
query I rowsort label-4097
SELECT - col1 DIV 78 + - col2 AS col2 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-4097
SELECT - col1 / 78 + - col2 AS col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT + col0 + 44 FROM tab0 AS cor0
----
133
68
79

query I rowsort
SELECT col2 * + 18 - col0 * col0 FROM tab2 cor0
----
-5557
-5616
437

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab0, tab2 AS cor1, tab2 AS cor2
----
13122 values hashing to 4dd814f6bbd95689305ee732ff27fb1c

onlyif mysql # use DIV operator for integer division
query I rowsort label-4101
SELECT + col2 * col0 DIV - 66 AS col2 FROM tab0 AS cor0
----
-110
-12
0

skipif mysql # not compatible
query I rowsort label-4101
SELECT + col2 * col0 / - 66 AS col2 FROM tab0 AS cor0
----
-110
-12
0

query I rowsort
SELECT ALL + + col1 + - col1 * col2 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + cor0.col1 * - col2 - col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT - col0 * 68 AS col1 FROM tab0
----
-1632
-2380
-6052

query I rowsort
SELECT ALL col1 + + col1 * cor0.col0 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT - + ( + 26 ) * col0 + + col2 AS col2 FROM tab1 AS cor0
----
-1607
-1984
-24

query I rowsort
SELECT DISTINCT - - cor0.col1 * 36 - - col0 FROM tab0 AS cor0
----
3120
3365
3527

query I rowsort
SELECT - 9 * col2 + - col0 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-1153
-1904
-564

query I rowsort
SELECT ALL - col2 + 52 * col1 AS col1 FROM tab0 AS cor0
----
4439
4650
5043

query I rowsort
SELECT ALL + - ( 75 ) FROM tab1 cor0
----
-75
-75
-75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4111
SELECT + - CAST( NULL AS SIGNED ) * + col0 + - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4111
SELECT + - CAST ( NULL AS INTEGER ) * + col0 + - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 83 AS col2 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT ALL - col0 + - col0 * col1 AS col2 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT col2 - ( - col1 * col1 ) FROM tab0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-4115
SELECT ALL col2 DIV - col0 + 78 AS col2 FROM tab2
----
75
78
78

skipif mysql # not compatible
query I rowsort label-4115
SELECT ALL col2 / - col0 + 78 AS col2 FROM tab2
----
75
78
78

query I rowsort
SELECT ALL col1 * + tab2.col0 + + 29 FROM tab2
----
1372
246
4631

query I rowsort
SELECT ALL 87 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col1 col0 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + 99 * col0 FROM tab2 cor0
----
693
7722
7821

query I rowsort
SELECT DISTINCT + col2 + - col2 * col0 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - ( - col0 ) * + col0 + - col2 AS col2 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT ALL - + ( - col1 ) + col1 * - col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL - col1 * col1 + + col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT - col2 * - 38 * col0 AS col0 FROM tab0 AS cor0
----
1330
277324
30096

query I rowsort
SELECT ALL + 4 + + col2 AS col0 FROM tab1 cor0
----
100
58
61

query I rowsort
SELECT DISTINCT - 2 * + col1 AS col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT col2 * + ( + cor0.col0 ) AS col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4128
SELECT + CAST( - 17 AS SIGNED ) * + col1 * - col1 AS col0 FROM tab0 AS cor0
----
125732
140777
159953

skipif mysql # not compatible
query I rowsort label-4128
SELECT + CAST ( - 17 AS INTEGER ) * + col1 * - col1 AS col0 FROM tab0 AS cor0
----
125732
140777
159953

query I rowsort
SELECT + - cor0.col2 * - col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + - 77 * col0 - - col1 FROM tab0 AS cor0
----
-1762
-2598
-6762

query I rowsort
SELECT DISTINCT - col0 * col0 + ( col0 ) * + col0 - - col0 FROM tab1
----
3
64
80

query I rowsort
SELECT - col0 * - col2 + ( 77 ) FROM tab2 AS cor0
----
2105
266
3079

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 8 + - col1 col2 FROM tab1 AS cor0
----
-18
-2
-5

query I rowsort
SELECT + 25 - - col2 * ( - col1 * col2 ) AS col0 FROM tab1 AS cor0
----
-119783
-32465
-75791

onlyif mysql # use DIV operator for integer division
query I rowsort label-4135
SELECT ALL + col1 DIV + 77 + col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4135
SELECT ALL + col1 / + 77 + col1 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL + col2 + tab1.col0 * 30 FROM tab1
----
144
1977
2496

query I rowsort
SELECT col0 * + 63 FROM tab1 cor0
----
189
4032
5040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col1 * + col0 col2 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4139
SELECT ALL - col2 + + ( col1 ) DIV tab2.col0 + + 10 FROM tab2
----
-13
-16
-28

skipif mysql # not compatible
query I rowsort label-4139
SELECT ALL - col2 + + ( col1 ) / tab2.col0 + + 10 FROM tab2
----
-13
-16
-28

query I rowsort
SELECT col0 + + ( 19 * - col1 ) + + ( ( + col2 ) ) FROM tab1 AS cor0
----
-437
-69
-71

query I rowsort
SELECT ALL cor0.col2 + 13 * - col1 FROM tab2 AS cor0
----
-183
-376
-741

query I rowsort
SELECT DISTINCT - col2 * + 78 + col2 * col0 AS col1 FROM tab0 AS cor0
----
-1782
-43
902

query I rowsort
SELECT ALL - 46 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 491ad1fb79fec0b5715ea54949d1aa2d

onlyif mysql # use DIV operator for integer division
query I rowsort label-4144
SELECT DISTINCT - col0 DIV col2 + tab1.col0 + + tab1.col2 AS col0 FROM tab1
----
120
176
57

skipif mysql # not compatible
query I rowsort label-4144
SELECT DISTINCT - col0 / col2 + tab1.col0 + + tab1.col2 AS col0 FROM tab1
----
120
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 + - cor0.col0 * 39 col1 FROM tab0 AS cor0
----
-1364
-3389
-903

query I rowsort
SELECT + col1 * + cor0.col0 + col0 + col1 AS col0 FROM tab2 AS cor0
----
1439
255
4739

query I rowsort
SELECT - - col2 * - 82 * col2 + col1 * - col0 FROM tab1 AS cor0
----
-239190
-267058
-756752

query I rowsort
SELECT ALL + col1 * 63 FROM tab1 AS cor0
----
1638
630
819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4149
SELECT - - col2 / CAST( NULL AS SIGNED ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4149
SELECT - - col2 / CAST ( NULL AS INTEGER ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col1 * ( - 8 * col2 ) + + col1 * col0 FROM tab2 AS cor0
----
-3825
-6479
-7670

query I rowsort
SELECT DISTINCT + cor0.col1 * col0 + + col2 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL - - col1 + + 77 * col0 FROM tab2 AS cor0
----
570
6065
6100

query I rowsort
SELECT ALL + col1 * - 5 FROM tab0 AS cor0
----
-430
-455
-485

query I rowsort
SELECT - col2 * 19 FROM tab1 AS cor0
----
-1026
-1083
-1824

query I rowsort
SELECT + 33 + + col1 * col1 FROM tab0 AS cor0
----
7429
8314
9442

query I rowsort
SELECT + col1 * - ( col1 + + col2 ) FROM tab2 AS cor0
----
-1798
-5015
-935

query I rowsort
SELECT DISTINCT - col2 + + 10 * - col0 FROM tab2 cor0
----
-806
-828
-97

query I rowsort
SELECT - - col2 + 82 * + cor0.col1 FROM tab1 AS cor0
----
1162
2186
877

query I rowsort
SELECT ALL + + ( + col1 ) AS col0 FROM tab0 AS cor0
----
86
91
97

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to d222ba302bd1ddd1c8b2ddf1a4d0b07a

query I rowsort
SELECT ALL - + col0 * + col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col0 * + col2 + 16 FROM tab1 AS cor0
----
-146
-3632
-7664

query I rowsort
SELECT DISTINCT + col1 + + col2 * ( col1 ) + col1 AS col1 FROM tab0 AS cor0
----
291
3010
7644

query I rowsort
SELECT DISTINCT - - col1 * col0 + + 18 FROM tab0 AS cor0
----
2082
3413
8117

query I rowsort
SELECT DISTINCT + + col0 - cor0.col0 * - col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - 16 * + col2 - + 81 AS col1 FROM tab1 cor0
----
-1617
-945
-993

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4167
SELECT ALL col2 * - CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4167
SELECT ALL col2 * - CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4168
SELECT + col1 DIV ( - cor0.col0 ) FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4168
SELECT + col1 / ( - cor0.col0 ) FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT ( col2 ) * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - + col0 + - col1 + col1 * ( col2 + - col1 ) AS col0 FROM tab2 AS cor0
----
-162
-2084
261

query I rowsort
SELECT + + 14 + cor0.col0 AS col0 FROM tab2 AS cor0
----
21
92
93

query I rowsort
SELECT - col1 * - col2 * col1 + col1 AS col2 FROM tab0 AS cor0
----
244154
679133
9506

query I rowsort
SELECT col0 + + ( + cor0.col0 + cor0.col1 ) AS col1 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT - 13 AS col1 FROM tab2
----
-13
-13
-13

query I rowsort
SELECT - col2 + 63 AS col1 FROM tab1 AS cor0
----
-33
6
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4176
SELECT ALL + col2 * - CAST( NULL AS DECIMAL ) + + 59 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4176
SELECT ALL + col2 * - CAST ( NULL AS REAL ) + + 59 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( 78 ) FROM tab0, tab2 AS cor0
----
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4178
SELECT DISTINCT - col1 DIV - 84 AS col1 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-4178
SELECT DISTINCT - col1 / - 84 AS col1 FROM tab1
----
0

query I rowsort
SELECT 31 * + 33 FROM tab2 AS cor0
----
1023
1023
1023

query I rowsort
SELECT + 80 + + col0 FROM tab2 cor0
----
158
159
87

query I rowsort
SELECT col0 + col2 * - tab0.col2 * + col0 AS col2 FROM tab0
----
-26112
-598347
0

query I rowsort
SELECT DISTINCT col0 + col0 * 41 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT + - col2 * + 87 * col2 + cor0.col1 * col1 FROM tab0 AS cor0
----
-576707
-87347
9322

query I rowsort
SELECT ALL col1 * + 35 AS col0 FROM tab0 AS cor0
----
3010
3185
3395

query I rowsort
SELECT DISTINCT + 4 + 95 AS col0 FROM tab1 AS cor0
----
99

query I rowsort
SELECT - 50 * - 31 + + col1 AS col2 FROM tab0 AS cor0
----
1636
1641
1647

query I rowsort
SELECT - col2 * + col0 * + col0 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT ALL + col0 + - 47 AS col1 FROM tab0 AS cor0
----
-12
-23
42

query I rowsort
SELECT ALL + 54 * + col0 + col2 AS col1 FROM tab2 AS cor0
----
405
4238
4304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4190
SELECT ALL CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-4190
SELECT ALL CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - 28 AS col1 FROM tab0, tab2 AS cor0
----
-28

query I rowsort
SELECT ALL ( 82 ) * col2 + + col2 FROM tab1
----
4482
4731
7968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 99 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 64d06513850a26495bc6c2fddeb254b7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4194
SELECT DISTINCT + col0 * - col0 DIV + col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-4194
SELECT DISTINCT + col0 * - col0 / + col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT + col0 * col2 * + col0 FROM tab2
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-4196
SELECT + + ( col1 ) DIV - cor0.col0 + col2 AS col1 FROM tab1 AS cor0
----
46
57
96

skipif mysql # not compatible
query I rowsort label-4196
SELECT + + ( col1 ) / - cor0.col0 + col2 AS col1 FROM tab1 AS cor0
----
46
57
96

query I rowsort
SELECT DISTINCT - ( + col0 ) * - col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ( col0 ) * + col0 * tab1.col1 - col1 FROM tab1
----
208
40950
83187

query I rowsort
SELECT - - col1 + + ( col1 ) FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT - - col1 + - 51 AS col2 FROM tab1 AS cor0
----
-25
-38
-41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 + col0 * col1 col0 FROM tab1 cor0
----
1280
156
2080

query I rowsort
SELECT + col0 * 11 - 79 FROM tab1 AS cor0
----
-46
625
801

query I rowsort
SELECT - col2 * - ( - col1 ) FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT col1 - col2 AS col0 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT - col0 + + col0 * col2 AS col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT col2 + - col1 - + 49 AS col2 FROM tab0 AS cor0
----
-102
-145
-58

query I rowsort
SELECT + + col2 * + col1 + 89 - col0 FROM tab2 AS cor0
----
1545
656
919

query I rowsort
SELECT ALL - - ( - col2 ) + - ( 71 ) * col1 AS col1 FROM tab2 AS cor0
----
-1245
-2228
-4215

query I rowsort
SELECT + + 18 * - col1 * - col0 AS col1 FROM tab0 AS cor0
----
145782
37152
61110

query I rowsort
SELECT DISTINCT + 30 * col0 FROM tab0 cor0
----
1050
2670
720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4212
SELECT - 12 * col0 + - CAST( - 66 AS SIGNED ) FROM tab0 AS cor0
----
-1002
-222
-354

skipif mysql # not compatible
query I rowsort label-4212
SELECT - 12 * col0 + - CAST ( - 66 AS INTEGER ) FROM tab0 AS cor0
----
-1002
-222
-354

query I rowsort
SELECT ALL + - cor0.col1 * col1 * 40 FROM tab0 AS cor0
----
-295840
-331240
-376360

query I rowsort
SELECT - cor0.col2 * 64 AS col0 FROM tab0 AS cor0
----
-2112
-5248
-64

query I rowsort
SELECT ( + col2 ) * 27 AS col1 FROM tab0
----
2214
27
891

query I rowsort
SELECT + 64 - col1 AS col0 FROM tab1
----
38
51
54

query I rowsort
SELECT + cor0.col2 * 52 FROM tab1 AS cor0
----
2808
2964
4992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4218
SELECT ALL - + col0 + CAST( - col2 AS SIGNED ) FROM tab0 AS cor0
----
-171
-36
-57

skipif mysql # not compatible
query I rowsort label-4218
SELECT ALL - + col0 + CAST ( - col2 AS INTEGER ) FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + col0 * 72 * 63 FROM tab0 AS cor0
----
108864
158760
403704

query I rowsort
SELECT cor0.col0 + - col1 * col0 AS col1 FROM tab1 cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT + - col0 * - ( 85 ) FROM tab0 AS cor0
----
2040
2975
7565

query I rowsort
SELECT ALL 38 + - col2 FROM tab0
----
-44
37
5

query I rowsort
SELECT - 57 * + col2 + - col1 * + col2 + + col1 AS col0 FROM tab0
----
-12045
-4633
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4224
SELECT ALL - ( - col0 ) + + CAST( NULL AS SIGNED ) * ( col0 ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4224
SELECT ALL - ( - col0 ) + + CAST ( NULL AS INTEGER ) * ( col0 ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 3 + col2 + + col2 FROM tab1
----
111
117
195

query I rowsort
SELECT DISTINCT - + 4 FROM tab1 AS cor0
----
-4

query I rowsort
SELECT DISTINCT 54 + - col2 FROM tab2 AS cor0
----
16
27
28

query I rowsort
SELECT DISTINCT - col2 + + col0 + - col0 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - + 2 * + ( col0 ) + col1 FROM tab2 AS cor0
----
-141
-97
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-4230
SELECT ALL ( - col2 ) DIV - col1 + ( + col1 ) AS col2 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4230
SELECT ALL ( - col2 ) / - col1 + ( + col1 ) AS col2 FROM tab0 cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4231
SELECT DISTINCT + CAST( col0 AS SIGNED ) * col1 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-4231
SELECT DISTINCT + CAST ( col0 AS INTEGER ) * col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4232
SELECT ALL - cor0.col0 DIV + 94 AS col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4232
SELECT ALL - cor0.col0 / + 94 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + + col1 + 56 * col0 FROM tab2 AS cor0
----
423
4427
4441

onlyif mysql # use DIV operator for integer division
query I rowsort label-4234
SELECT ALL + - 40 DIV + col0 + + col2 FROM tab2 AS cor0
----
22
26
38

skipif mysql # not compatible
query I rowsort label-4234
SELECT ALL + - 40 / + col0 + + col2 FROM tab2 AS cor0
----
22
26
38

query I rowsort
SELECT ALL 44 AS col1 FROM tab0
----
44
44
44

query I rowsort
SELECT + + 95 AS col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT ALL col0 + + col1 - - col1 FROM tab0
----
196
229
271

query I rowsort
SELECT ALL - - 69 + - 43 FROM tab0 AS cor0
----
26
26
26

query I rowsort
SELECT + ( - col0 ) * + cor0.col2 + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-4240
SELECT DISTINCT + + ( 54 ) + + cor0.col1 DIV cor0.col0 AS col0 FROM tab2 AS cor0
----
54
58

skipif mysql # not compatible
query I rowsort label-4240
SELECT DISTINCT + + ( 54 ) + + cor0.col1 / cor0.col0 AS col0 FROM tab2 AS cor0
----
54
58

query I rowsort
SELECT + - 40 * + cor0.col0 FROM tab1 AS cor0
----
-120
-2560
-3200

query I rowsort
SELECT ( ( + col1 ) ) AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - col2 + tab1.col1 * + col1 * + col0 FROM tab1
----
13424
1974
6343

query I rowsort
SELECT - col0 + col2 * ( 99 ) FROM tab1 AS cor0
----
5343
5579
9424

query I rowsort
SELECT 37 * - col2 + + col1 FROM tab2
----
-1389
-903
-968

query I rowsort
SELECT + + 52 * + 54 AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 6734ccfbc6e49da19c1af3a8e15ff7b2

query I rowsort
SELECT DISTINCT col1 * - col2 + 52 FROM tab1 AS cor0
----
-1196
-1352
-518

query I rowsort
SELECT DISTINCT + - ( - col0 ) * - col1 + 91 FROM tab0 cor0
----
-1973
-3304
-8008

query I rowsort
SELECT DISTINCT + - col1 + - 70 AS col2 FROM tab0 cor0
----
-156
-161
-167

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4250
SELECT DISTINCT + col2 * - CAST( NULL AS SIGNED ) - - cor0.col2 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4250
SELECT DISTINCT + col2 * - CAST ( NULL AS INTEGER ) - - cor0.col2 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col0 * 41 + col1 AS col1 FROM tab1 AS cor0
----
-2614
-3267
-97

query I rowsort
SELECT ALL + col0 * 89 FROM tab1 AS cor0
----
267
5696
7120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4253
SELECT col2 + CAST( NULL AS SIGNED ) * + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4253
SELECT col2 + CAST ( NULL AS INTEGER ) * + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + 98 * - cor0.col2 + - col1 * - col2 FROM tab2 AS cor0
----
-1778
-3061
-955

query I rowsort
SELECT DISTINCT + - cor0.col0 + 21 FROM tab1 cor0
----
-43
-59
18

query I rowsort
SELECT + - col1 * 10 AS col1 FROM tab0 AS cor0
----
-860
-910
-970

query I rowsort
SELECT ALL - col1 * 14 FROM tab0 cor0
----
-1204
-1274
-1358

onlyif mysql # use DIV operator for integer division
query I rowsort label-4258
SELECT col0 DIV - 4 AS col0 FROM tab0 AS cor0
----
-22
-6
-8

skipif mysql # not compatible
query I rowsort label-4258
SELECT col0 / - 4 AS col0 FROM tab0 AS cor0
----
-22
-6
-8

query I rowsort
SELECT ALL - 77 - + cor0.col1 FROM tab0 cor0
----
-163
-168
-174

query I rowsort
SELECT DISTINCT + col2 - + col2 * + col0 * ( + col2 * + col1 ) FROM tab1 AS cor0
----
-2079303
-227394
-9584544

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4261
SELECT ALL - CAST( NULL AS SIGNED ) + col2 + - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4261
SELECT ALL - CAST ( NULL AS INTEGER ) + col2 + - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( + 49 ) AS col2 FROM tab0 AS cor0
----
49
49
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-4263
SELECT DISTINCT - col1 DIV + col0 + col1 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-21
0
33

skipif mysql # not compatible
query I rowsort label-4263
SELECT DISTINCT - col1 / + col0 + col1 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-21
0
33

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 cor1, tab1 cor2, tab2 cor3
----
3645 values hashing to 4805bcb9c04e49d1f6f82defa880d751

query I rowsort
SELECT - col1 * col1 + col1 - col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + + col2 + ( - 60 ) AS col0 FROM tab0 AS cor0
----
-27
-59
22

query I rowsort
SELECT + col2 + + 65 AS col0 FROM tab1 cor0
----
119
122
161

query I rowsort
SELECT ALL cor0.col0 * 76 FROM tab2 AS cor0
----
532
5928
6004

query I rowsort
SELECT - + 29 * - col2 FROM tab2 AS cor0
----
1102
754
783

query I rowsort
SELECT - - 83 AS col0 FROM tab2 AS cor0
----
83
83
83

query I rowsort
SELECT ALL + 97 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * 45 col0 FROM tab1 AS cor0
----
-135
-2880
-3600

onlyif mysql # use DIV operator for integer division
query I rowsort label-4273
SELECT - ( col0 ) DIV col2 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4273
SELECT - ( col0 ) / col2 FROM tab1 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4274
SELECT + cor0.col2 + col0 DIV + col0 col1 FROM tab2 cor0
----
27
28
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4274
SELECT + cor0.col2 + col0 / + col0 col1 FROM tab2 cor0
----
27
28
39

query I rowsort
SELECT DISTINCT 6 + + col1 * col0 AS col1 FROM tab1 cor0
----
1046
646
84

query I rowsort
SELECT - 43 + - cor0.col0 * cor0.col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to e16f60d1e1830338dc2a05f95c9957c6

query I rowsort
SELECT ALL col0 * + col1 * col1 FROM tab2 AS cor0
----
22831
271518
6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col1 col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4279
SELECT ALL + col2 DIV cor0.col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4279
SELECT ALL + col2 / cor0.col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - - col2 + col0 * col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL col1 * - col0 + ( + tab0.col2 ) + tab0.col1 AS col2 FROM tab0
----
-1945
-3297
-7926

query I rowsort
SELECT ALL 66 + - col2 FROM tab0
----
-16
33
65

query I rowsort
SELECT + col2 + 89 * col2 AS col1 FROM tab0 AS cor0
----
2970
7380
90

query I rowsort
SELECT - col2 * 52 + 84 - - col1 FROM tab2 AS cor0
----
-1209
-1289
-1875

query I rowsort
SELECT + col2 + 3 FROM tab0 AS cor0
----
36
4
85

query I rowsort
SELECT DISTINCT + col1 - - 38 FROM tab2 AS cor0
----
55
69
97

query I rowsort
SELECT DISTINCT + ( 78 ) * - cor1.col2 AS col2 FROM tab0, tab0 AS cor0, tab1 cor1
----
-4212
-4446
-7488

query I rowsort
SELECT DISTINCT - ( + col2 ) * - col0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT - tab0.col2 * tab0.col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - 34 * + col0 FROM tab2 AS cor0
----
-238
-2652
-2686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4291
SELECT DISTINCT col1 * CAST( col1 AS SIGNED ) FROM tab0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-4291
SELECT DISTINCT col1 * CAST ( col1 AS INTEGER ) FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL - + col0 * + 60 FROM tab1 cor0
----
-180
-3840
-4800

query I rowsort
SELECT col1 + + 62 AS col1 FROM tab1
----
72
75
88

query I rowsort
SELECT - tab2.col2 + ( - col2 * col1 ) AS col1 FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT + + col0 * + col1 - col1 * col1 AS col0 FROM tab1 AS cor0
----
-598
540
871

query I rowsort
SELECT DISTINCT col1 - col1 * col0 AS col2 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - col0 - 50 * - 40 FROM tab1
----
1920
1936
1997

query I rowsort
SELECT DISTINCT col0 * - col2 - col0 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT + + 44 + col0 FROM tab1 AS cor0
----
108
124
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 25 + col2 + col1 col1 FROM tab1 AS cor0
----
105
134
92

query I rowsort
SELECT DISTINCT - col2 - - col1 * col0 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL col2 * - 97 AS col1 FROM tab0
----
-3201
-7954
-97

query I rowsort
SELECT ALL + ( col0 ) * - col1 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4304
SELECT ALL - cor0.col2 DIV + 65 FROM tab1, tab1 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-4304
SELECT ALL - cor0.col2 / + 65 FROM tab1, tab1 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

query I rowsort
SELECT + 26 AS col0 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT - + col1 + + col2 * col1 AS col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT - col0 * col2 + + col0 AS col1 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT - - cor0.col2 + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + + col0 * + cor0.col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL + + col0 + - col1 * col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT + col0 + col0 * + col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + col1 * col1 + + col0 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT + col2 + + cor0.col2 - col1 FROM tab1 AS cor0
----
104
179
82

query I rowsort
SELECT + col1 * + col1 + - col1 AS col2 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT + col2 + + col2 * col0 * + cor0.col0 FROM tab0 AS cor0
----
1226
19041
649604

query I rowsort
SELECT DISTINCT - tab1.col2 FROM tab1, tab2, tab0 cor0
----
-54
-57
-96

query I rowsort
SELECT + col1 * + col1 + col1 - - col0 FROM tab1
----
174
262
705

onlyif mysql # use DIV operator for integer division
query I rowsort label-4318
SELECT + tab0.col1 DIV + col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-4318
SELECT + tab0.col1 / + col0 FROM tab0
----
1
2
3

query I rowsort
SELECT + col0 + col2 * + col0 - - col0 AS col0 FROM tab0
----
105
7476
840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - + col0 * col0 col0 FROM tab1
----
-4039
-6304
45

query I rowsort
SELECT col2 * - cor0.col0 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT cor0.col1 + col2 * col0 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT col0 + col2 + - col0 AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL + - cor0.col1 + col1 + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - col1 * col2 * col2 AS col0 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL - col2 * - col2 + - cor0.col0 AS col0 FROM tab1 cor0
----
2913
3185
9136

query I rowsort
SELECT ALL - - 83 + col2 FROM tab2 AS cor0
----
109
110
121

query I rowsort
SELECT + col0 + + col0 * - col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT + + cor0.col2 * + cor0.col2 + - col1 + + col0 AS col1 FROM tab0 AS cor0
----
-61
1027
6722

query I rowsort
SELECT col2 * + cor0.col0 AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + - 78 * - col0 FROM tab2 AS cor0
----
546
6084
6162

query I rowsort
SELECT ALL col1 * 52 * + col0 FROM tab2
----
11284
239304
69836

onlyif mysql # use DIV operator for integer division
query I rowsort label-4333
SELECT DISTINCT 6 DIV col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4333
SELECT DISTINCT 6 / col0 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4334
SELECT ALL - ( - col1 ) * col0 + col2 DIV - col0 + col1 FROM tab1 AS cor0
----
1052
650
86

skipif mysql # not compatible
query I rowsort label-4334
SELECT ALL - ( - col1 ) * col0 + col2 / - col0 + col1 FROM tab1 AS cor0
----
1052
650
86

query I rowsort
SELECT DISTINCT + col1 * col1 + cor0.col2 AS col1 FROM tab2 cor0
----
327
3507
988

query I rowsort
SELECT + + cor0.col2 + + cor0.col1 * col0 FROM tab2 AS cor0
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * cor0.col0 + col2 col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT col2 - + col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col0 + - col0 AS col1 FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4340
SELECT - col2 * col0 + + col2 DIV col2 AS col0 FROM tab0
----
-34
-7297
-791

skipif mysql # not compatible
query I rowsort label-4340
SELECT - col2 * col0 + + col2 / col2 AS col0 FROM tab0
----
-34
-7297
-791

query I rowsort
SELECT ALL + col2 * - col0 + col2 FROM tab2
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col2 col0 FROM tab1 WHERE col2 + col1 NOT BETWEEN - tab1.col0 AND NULL
----

query I rowsort
SELECT ALL - col1 * col1 + + col1 FROM tab2
----
-272
-3422
-930

query I rowsort
SELECT ALL col2 * tab0.col0 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT - col1 * + col1 + - col0 AS col1 FROM tab2
----
-3559
-368
-968

query I rowsort
SELECT - tab2.col2 * col1 + col2 * col0 + + col2 FROM tab2
----
-621
2394
520

query III rowsort
SELECT ALL * FROM tab0 WHERE ( NULL ) IN ( - col0 + - col0 )
----

query I rowsort
SELECT DISTINCT col1 AS col0 FROM tab0 WHERE NOT NULL <= + col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * tab0.col2 col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - col1 - - col1 FROM tab1
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4351
SELECT ALL col2 DIV col0 - col0 AS col0 FROM tab0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-4351
SELECT ALL col2 / col0 - col0 AS col0 FROM tab0
----
-23
-35
-89

query I rowsort
SELECT - tab2.col2 * - col0 + col2 AS col0 FROM tab2
----
2054
216
3040

query I rowsort
SELECT - col2 - - col1 * + col2 * + col0 AS col0 FROM tab0 WHERE NOT ( NULL ) NOT IN ( col1 )
----

query I rowsort
SELECT DISTINCT + col2 FROM tab0 WHERE NOT NULL NOT IN ( tab0.col1 )
----

query I rowsort
SELECT ALL - col0 - col0 * tab1.col0 FROM tab1
----
-12
-4160
-6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col1 + col2 col2 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT + col2 FROM tab0 WHERE NOT ( col2 * col1 * col0 ) NOT BETWEEN - col1 * col2 AND - col0
----

query I rowsort
SELECT + col1 - - tab0.col2 * col2 * + col2 AS col2 FROM tab0
----
36023
551459
98

query III rowsort
SELECT ALL * FROM tab2 WHERE - col2 IN ( + tab2.col0 * - col0 )
----

query I rowsort
SELECT ALL + col0 * - col1 + - tab2.col0 * + col1 AS col1 FROM tab2
----
-2686
-434
-9204

query I rowsort
SELECT col0 + col0 * - col0 AS col0 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT + col0 + + col0 + + col2 FROM tab1
----
185
256
60

query I rowsort
SELECT DISTINCT - col0 * col0 * + tab0.col0 + col0 FROM tab0
----
-13800
-42840
-704880

onlyif mysql # use DIV operator for integer division
query I rowsort label-4364
SELECT DISTINCT - col2 DIV col0 + - col1 AS col1 FROM tab2
----
-17
-34
-59

skipif mysql # not compatible
query I rowsort label-4364
SELECT DISTINCT - col2 / col0 + - col1 AS col1 FROM tab2
----
-17
-34
-59

query I rowsort
SELECT + col1 + - tab0.col1 + col2 * - col2 AS col2 FROM tab0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-4366
SELECT DISTINCT + tab1.col2 DIV - col2 + tab1.col2 col1 FROM tab1
----
53
56
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4366
SELECT DISTINCT + tab1.col2 / - col2 + tab1.col2 col1 FROM tab1
----
53
56
95

query I rowsort
SELECT tab1.col2 * - col0 + col1 + col0 * col1 FROM tab1
----
-2998
-58
-6627

query I rowsort
SELECT DISTINCT + + col1 + col2 * + col2 FROM tab0 AS cor0
----
1175
6815
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4369
SELECT ALL - - col2 + cor0.col2 DIV col0 FROM tab0 AS cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-4369
SELECT ALL - - col2 + cor0.col2 / col0 FROM tab0 AS cor0
----
1
34
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4370
SELECT DISTINCT + col0 DIV col0 - col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4370
SELECT DISTINCT + col0 / col0 - col0 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT ALL col1 + + col0 + - col0 AS col1 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4372
SELECT ALL + col1 DIV col0 AS col1 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-4372
SELECT ALL + col1 / col0 AS col1 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT ALL col0 FROM tab0 cor0 WHERE NULL = ( - col1 )
----

query I rowsort
SELECT ALL + cor0.col2 * + col1 FROM tab2 AS cor0 WHERE NOT NULL = NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT + col0 > ( col1 * col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4376
SELECT col1 DIV - cor0.col2 + ( + ( col2 ) ) AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4376
SELECT col1 / - cor0.col2 + ( + ( col2 ) ) AS col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4377
SELECT + + 35 + col2 * + CAST( col0 + - col2 AS SIGNED ) FROM tab2 AS cor0
----
-505
1387
1593

skipif mysql # not compatible
query I rowsort label-4377
SELECT + + 35 + col2 * + CAST ( col0 + - col2 AS INTEGER ) FROM tab2 AS cor0
----
-505
1387
1593

query I rowsort
SELECT - ( - col0 ) * - ( ( col2 ) ) * + ( - col2 ) - col1 FROM tab2 AS cor0
----
114059
5072
52669

query I rowsort
SELECT ALL 57 FROM tab0, tab2 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( 39 AS REAL ) + col2 * - col1 FROM tab1
----
-1287
-1443
-609

onlyif mysql # use DIV operator for integer division
query I rowsort label-4381
SELECT ALL + 20 DIV tab1.col1 FROM tab1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4381
SELECT ALL + 20 / tab1.col1 FROM tab1
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * cor1.col2 col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 21856088ba874ad1439062daed37ef79

query I rowsort
SELECT DISTINCT 77 * + tab2.col1 AS col2 FROM tab2
----
1309
2387
4543

query I rowsort
SELECT col1 * col2 + + ( 39 + - col2 ) AS col0 FROM tab1 AS cor0
----
1191
1389
552

query I rowsort
SELECT + col0 * col2 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT + 5 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
5

query I rowsort
SELECT ALL - col1 * + col0 + cor0.col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT + + col1 * col1 * + col0 FROM tab0 cor0
----
177504
329315
737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-4389
SELECT DISTINCT - + col0 DIV 6 FROM tab2 AS cor0
----
-1
-13

skipif mysql # not compatible
query I rowsort label-4389
SELECT DISTINCT - + col0 / 6 FROM tab2 AS cor0
----
-1
-13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - 42 * - 53 col2 FROM tab2 AS cor0
----
2243
2257
2285

query I rowsort
SELECT ALL 52 * 27 + + col0 FROM tab0 AS cor0
----
1428
1439
1493

query I rowsort
SELECT - ( 86 ) AS col2 FROM tab1 AS cor0
----
-86
-86
-86

query I rowsort
SELECT - 52 * - col0 + cor0.col2 AS col0 FROM tab1 cor0
----
210
3385
4256

onlyif mysql # use DIV operator for integer division
query I rowsort label-4394
SELECT ALL - 50 DIV + col0 + - col0 + col1 * ( col0 ) AS col2 FROM tab0 AS cor0
----
2038
3359
8010

skipif mysql # not compatible
query I rowsort label-4394
SELECT ALL - 50 / + col0 + - col0 + col1 * ( col0 ) AS col2 FROM tab0 AS cor0
----
2038
3359
8010

query I rowsort
SELECT 15 * - col0 FROM tab1 cor0
----
-1200
-45
-960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4396
SELECT DISTINCT col0 * + 10 + - cor0.col0 - CAST( NULL AS SIGNED ) * - 63 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4396
SELECT DISTINCT col0 * + 10 + - cor0.col0 - CAST ( NULL AS INTEGER ) * - 63 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col2 * + 88 AS col2 FROM tab1 AS cor0
----
4752
5016
8448

query I rowsort
SELECT - ( 39 ) * col2 AS col0 FROM tab0 AS cor0
----
-1287
-3198
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-4399
SELECT - + col0 DIV + col1 col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4399
SELECT - + col0 / + col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - ( col2 ) - col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT + + 5 + - col2 * 58 FROM tab1 AS cor0
----
-3127
-3301
-5563

query I rowsort
SELECT + - 17 * - col0 AS col1 FROM tab0 AS cor0
----
1513
408
595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4403
SELECT DISTINCT col0 * + col2 / - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4403
SELECT DISTINCT col0 * + col2 / - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 + col2 * 6 FROM tab1 AS cor0
----
350
352
589

query I rowsort
SELECT ALL - 83 * - 73 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 98aabe19a2956aacf3862a7fb0faf0be

query I rowsort
SELECT - + 23 * col1 FROM tab0 AS cor0
----
-1978
-2093
-2231

query I rowsort
SELECT DISTINCT + + col2 + + col0 * - col0 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT - - col0 * + col1 * col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT cor0.col2 * col0 + - col0 AS col1 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT + + cor0.col1 * 31 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
2666
2821
3007

query I rowsort
SELECT + cor2.col2 * 63 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 6cf2292f2027599c9cff298d2d14fd13

query I rowsort
SELECT col2 + - ( - 63 ) FROM tab1 AS cor0
----
117
120
159

query I rowsort
SELECT tab0.col2 * + ( tab0.col2 + col1 ) * + col0 AS col1 FROM tab0
----
1262554
3430
94248

query I rowsort
SELECT ALL - + col1 * col2 * col0 - + 94 FROM tab0 AS cor0
----
-3489
-664212
-68206

query I rowsort
SELECT DISTINCT + - cor0.col2 + cor0.col1 + col1 * - col1 AS col0 FROM tab0 cor0
----
-7343
-8272
-9313

query I rowsort
SELECT DISTINCT - col0 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( col2 AS REAL ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT col2 * - 22 AS col2 FROM tab0 AS cor0
----
-1804
-22
-726

query I rowsort
SELECT DISTINCT + col1 + - col0 AS col1 FROM tab0 cor0
----
2
62

query I rowsort
SELECT 96 * + cor0.col2 AS col2 FROM tab1 cor0
----
5184
5472
9216

query I rowsort
SELECT ALL - cor0.col1 * - col1 * col1 FROM tab0 AS cor0
----
636056
753571
912673

skipif mysql # not compatible
query I rowsort
SELECT col0 * CAST ( - 31 AS REAL ) + col0 AS col0 FROM tab0
----
-1050
-2670
-720

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + tab1.col1 * - CAST ( 36 AS REAL ) + tab1.col1 col2 FROM tab1
----
-350
-455
-910

query I rowsort
SELECT ALL col1 + + 64 * col2 FROM tab1
----
3482
3658
6157

query I rowsort
SELECT + col0 * ( - tab2.col0 ) AS col1 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT - 68 + + col0 AS col1 FROM tab0
----
-33
-44
21

query I rowsort
SELECT ALL - cor0.col2 * - ( - 88 * + col1 ) FROM tab0 AS cor0
----
-249744
-656656
-8536

query I rowsort
SELECT - col0 * ( 78 ) FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT ALL cor0.col2 + 57 * - 0 AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + 13 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
13

query I rowsort
SELECT cor0.col0 * - ( col0 ) AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + col1 * + 84 * col0 + - col2 + - 93 FROM tab1 AS cor0
----
53610
6405
87171

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4433
SELECT DISTINCT - - col2 * + CAST( NULL AS SIGNED ) - - col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4433
SELECT DISTINCT - - col2 * + CAST ( NULL AS INTEGER ) - - col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT cor1.col0 AS col2 FROM tab2, tab1 AS cor0, tab1 cor1
----
3
64
80

query I rowsort
SELECT + col2 * 17 AS col2 FROM tab2 AS cor0
----
442
459
646

query I rowsort
SELECT DISTINCT 95 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
95

query I rowsort
SELECT ALL col2 + - cor0.col0 + - col1 AS col0 FROM tab2 cor0
----
-11
-111
-58

query I rowsort
SELECT - 45 FROM tab1, tab1 AS cor0
----
9 values hashing to 71160abf09589695379a70558726f0ba

onlyif mysql # use DIV operator for integer division
query I rowsort label-4439
SELECT DISTINCT + 61 DIV 55 + col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-4439
SELECT DISTINCT + 61 / 55 + col1 FROM tab0
----
87
92
98

query I rowsort
SELECT DISTINCT - ( col2 ) * - col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + - 93 AS col2 FROM tab0 AS cor0
----
-93

query I rowsort
SELECT ALL - 73 + col1 AS col0 FROM tab2 AS cor0
----
-14
-42
-56

query I rowsort
SELECT ALL + 81 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 50d500b1082f81e0b02096b2afac91cd

query I rowsort
SELECT + + ( - col1 ) * - col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-4445
SELECT DISTINCT - 90 DIV cor0.col1 + cor0.col0 col0 FROM tab2 cor0
----
5
74
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4445
SELECT DISTINCT - 90 / cor0.col1 + cor0.col0 col0 FROM tab2 cor0
----
5
74
77

query I rowsort
SELECT DISTINCT + col2 * col0 + + 3 FROM tab1 AS cor0
----
165
3651
7683

query I rowsort
SELECT ALL + + 95 - - cor0.col0 AS col2 FROM tab2 AS cor0
----
102
173
174

query I rowsort
SELECT - ( col2 ) * + ( - col1 ) FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - - 58 + + col2 FROM tab1 AS cor0
----
112
115
154

query I rowsort
SELECT DISTINCT + col2 + + col2 * - col2 * 58 AS col0 FROM tab2 AS cor0
----
-39182
-42255
-83714

query I rowsort
SELECT - col0 * col1 + - col1 AS col1 FROM tab1 cor0
----
-104
-1053
-650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 35 col0 FROM tab0, tab0 AS cor0
----
35

query I rowsort
SELECT ALL + 29 * col1 - - col2 AS col1 FROM tab1 AS cor0
----
347
473
808

query I rowsort
SELECT - col2 + col0 * - 22 * col1 AS col0 FROM tab0 AS cor0
----
-178260
-45441
-74691

query I rowsort
SELECT DISTINCT - 73 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-2409
-5986
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4456
SELECT DISTINCT + col2 DIV + col1 + ( + col2 + col2 ) FROM tab1 AS cor0
----
110
119
199

skipif mysql # not compatible
query I rowsort label-4456
SELECT DISTINCT + col2 / + col1 + ( + col2 + col2 ) FROM tab1 AS cor0
----
110
119
199

query I rowsort
SELECT DISTINCT + col1 * + col0 + 44 AS col1 FROM tab2 AS cor0
----
1387
261
4646

query I rowsort
SELECT ALL col0 * + col0 - - cor0.col2 AS col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL 53 + cor0.col1 * + 2 AS col2 FROM tab1 AS cor0
----
105
73
79

query I rowsort
SELECT 4 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 3347a3237b37ed63205e9440d8818a46

query I rowsort
SELECT ALL + - col2 + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 31 * - col2 AS col0 FROM tab0
----
-1023
-2542
-31

query I rowsort
SELECT - 11 * tab2.col2 FROM tab2
----
-286
-297
-418

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 30 col1 FROM tab1
----
-30
-30
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 61 col1 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 50 * col0 col0 FROM tab1 AS cor0
----
150
3200
4000

query I rowsort
SELECT + + col1 * 63 + - col1 AS col2 FROM tab0 AS cor0
----
5332
5642
6014

query I rowsort
SELECT - col2 + 43 FROM tab1 AS cor0
----
-11
-14
-53

query I rowsort
SELECT + col1 * + ( + col0 ) + - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
-26
-27
-38

query I rowsort
SELECT - + tab1.col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4472
SELECT DISTINCT 70 DIV col1 AS col2 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4472
SELECT DISTINCT 70 / col1 AS col2 FROM tab1
----
2
5
7

query I rowsort
SELECT + tab1.col0 * col1 AS col2 FROM tab1
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4474
SELECT + + col1 * col0 + - cor0.col1 - - CAST( - col2 + + col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
1978
3298
8008

skipif mysql # not compatible
query I rowsort label-4474
SELECT + + col1 * col0 + - cor0.col1 - - CAST ( - col2 + + col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT + + 96 * 12 + col1 AS col2 FROM tab0 AS cor0
----
1238
1243
1249

onlyif mysql # use DIV operator for integer division
query I rowsort label-4476
SELECT 88 DIV col0 col1 FROM tab2 cor0
----
1
1
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4476
SELECT 88 / col0 col1 FROM tab2 cor0
----
1
1
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * col2 * col1 + 86 col2 FROM tab2 AS cor0
----
-119566
-50948
-5773

query I rowsort
SELECT + tab0.col0 + + ( tab0.col0 * col0 ) FROM tab0
----
1260
600
8010

query I rowsort
SELECT col0 * - ( + col2 ) + col2 AS col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - col0 + - tab1.col0 + + col1 FROM tab1
----
-118
-147
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 31 + 12 + - tab1.col1 * + col1 col1 FROM tab1
----
-126
-57
-633

query I rowsort
SELECT ALL + ( 74 ) AS col0 FROM tab0
----
74
74
74

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( + 21 AS REAL ) FROM tab0 AS cor0
----
-21
-21
-21

query I rowsort
SELECT DISTINCT - col1 + + col0 + + col2 FROM tab2
----
100
3
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4485
SELECT CAST( 13 AS SIGNED ) + col1 * tab0.col2 DIV + col0 + + col1 * 59 AS col1 FROM tab0
----
5205
5465
5738

skipif mysql # not compatible
query I rowsort label-4485
SELECT CAST ( 13 AS INTEGER ) + col1 * tab0.col2 / + col0 + + col1 * 59 AS col1 FROM tab0
----
5205
5465
5738

onlyif mysql # use DIV operator for integer division
query I rowsort label-4486
SELECT + col0 * col0 DIV 52 FROM tab0 AS cor0
----
11
152
23

skipif mysql # not compatible
query I rowsort label-4486
SELECT + col0 * col0 / 52 FROM tab0 AS cor0
----
11
152
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4487
SELECT + - cor0.col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4487
SELECT + - cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + 75 AS col0 FROM tab2 AS cor0
----
101
102
113

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 79 col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT DISTINCT 91 * + col2 FROM tab0
----
3003
7462
91

query I rowsort
SELECT + col1 + tab0.col0 AS col2 FROM tab0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4492
SELECT + cor0.col2 * - CAST( + 78 AS SIGNED ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 4504c9ef562931c1434e7dfbf2f73e33

skipif mysql # not compatible
query I rowsort label-4492
SELECT + cor0.col2 * - CAST ( + 78 AS INTEGER ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 4504c9ef562931c1434e7dfbf2f73e33

query I rowsort
SELECT DISTINCT - col0 + ( col2 ) AS col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col2 - 34 * col0 * - ( - col2 ) AS col1 FROM tab2 AS cor0
----
-102030
-6399
-68926

query I rowsort
SELECT - 31 - col1 FROM tab0 AS cor0
----
-117
-122
-128

query I rowsort
SELECT + col2 * + 8 AS col0 FROM tab2 AS cor0
----
208
216
304

query I rowsort
SELECT ALL + 95 * col1 AS col0 FROM tab2
----
1615
2945
5605

query I rowsort
SELECT + 95 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4499
SELECT + CAST( 34 AS SIGNED ) FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

skipif mysql # not compatible
query I rowsort label-4499
SELECT + CAST ( 34 AS INTEGER ) FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT DISTINCT 45 + - col1 FROM tab2 AS cor0
----
-14
14
28

query I rowsort
SELECT 23 * - col2 * col2 FROM tab1
----
-211968
-67068
-74727

query I rowsort
SELECT 34 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT ALL + 91 + - col2 FROM tab0
----
58
9
90

query I rowsort
SELECT 60 * - col1 FROM tab1 AS cor0
----
-1560
-600
-780

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col1 * - 58 col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5f970ec08b581307a0cd5feb2954cccf

query I rowsort
SELECT + tab1.col1 + tab1.col0 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL col2 * - col2 + col2 * col0 FROM tab0 AS cor0
----
-297
34
574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + cor0.col2 col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - - col2 + - col0 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - 38 * - tab1.col1 AS col0 FROM tab1
----
380
494
988

query I rowsort
SELECT col2 - ( + col0 ) * ( + col0 * tab0.col1 ) FROM tab0
----
-118824
-49503
-720729

query I rowsort
SELECT - col0 + - 69 - cor0.col1 AS col0 FROM tab1 AS cor0
----
-143
-162
-98

query I rowsort
SELECT DISTINCT - col1 + + 31 - - col2 * col0 AS col2 FROM tab0
----
-31
7238
737

query I rowsort
SELECT + ( 19 ) FROM tab0 AS cor0
----
19
19
19

query I rowsort
SELECT DISTINCT 68 AS col0 FROM tab2, tab2 AS cor0
----
68

query I rowsort
SELECT 12 * col2 + + col0 FROM tab2 AS cor0
----
331
390
535

query I rowsort
SELECT col2 * + cor0.col0 + - ( + col1 + col0 ) AS col0 FROM tab1 AS cor0
----
133
3574
7587

query I rowsort
SELECT + col2 * col0 + + col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT + col2 + + col0 * 7 FROM tab1 cor0
----
505
656
75

query I rowsort
SELECT ALL + + 53 * col0 FROM tab2 AS cor0
----
371
4134
4187

query I rowsort
SELECT DISTINCT - 68 * - col1 AS col2 FROM tab0 cor0
----
5848
6188
6596

query I rowsort
SELECT + - col0 + col0 * ( col2 ) FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT col2 * + col0 * col0 AS col2 FROM tab1
----
233472
486
614400

query I rowsort
SELECT - 18 * col2 AS col1 FROM tab0
----
-1476
-18
-594

query I rowsort
SELECT DISTINCT + col2 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + 18 * + 33 AS col0 FROM tab1
----
594
594
594

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4527
SELECT DISTINCT CAST( - col2 * + col0 AS SIGNED ) col2 FROM tab1
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4527
SELECT DISTINCT CAST ( - col2 * + col0 AS INTEGER ) col2 FROM tab1
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4528
SELECT - CAST( col2 AS SIGNED ) * + col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-4528
SELECT - CAST ( col2 AS INTEGER ) * + col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - cor0.col0 * 61 AS col0 FROM tab2 AS cor0
----
-427
-4758
-4819

query I rowsort
SELECT ALL + ( col0 ) * - col1 * - cor0.col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT DISTINCT 19 * - 66 FROM tab1
----
-1254

query I rowsort
SELECT - 68 + ( col2 * - col1 ) FROM tab0
----
-165
-2906
-7530

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - ( - col2 ) col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + 23 + - col2 AS col0 FROM tab2 AS cor0
----
-15
-3
-4

query I rowsort
SELECT cor1.col1 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT 27 * col2 + - col2 AS col2 FROM tab0
----
2132
26
858

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) * - col0 * 58 + col2 col1 FROM tab2
----
10989
117650
174154

query I rowsort
SELECT tab2.col2 * col2 - - col1 FROM tab2
----
1461
735
760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col0 * - tab1.col1 - col2 col1 FROM tab1
----
180
40903
83104

onlyif mysql # use DIV operator for integer division
query I rowsort label-4540
SELECT - 28 DIV tab1.col1 AS col2 FROM tab1
----
-1
-2
-2

skipif mysql # not compatible
query I rowsort label-4540
SELECT - 28 / tab1.col1 AS col2 FROM tab1
----
-1
-2
-2

query I rowsort
SELECT - + col0 - + 94 * col0 AS col0 FROM tab2 AS cor0
----
-665
-7410
-7505

query I rowsort
SELECT DISTINCT - col2 + 4 * col2 AS col2 FROM tab1 AS cor0
----
162
171
288

onlyif mysql # use DIV operator for integer division
query I rowsort label-4543
SELECT ALL + + col1 * 20 * - col0 + - col0 DIV CAST( col1 + col2 AS SIGNED ) FROM tab2 AS cor0
----
-26861
-4340
-92040

skipif mysql # not compatible
query I rowsort label-4543
SELECT ALL + + col1 * 20 * - col0 + - col0 / CAST ( col1 + col2 AS INTEGER ) FROM tab2 AS cor0
----
-26861
-4340
-92040

query I rowsort
SELECT DISTINCT - col1 * col1 - - col1 AS col0 FROM tab1
----
-156
-650
-90

query I rowsort
SELECT ALL + col2 - + col1 AS col2 FROM tab0
----
-53
-9
-96

query IIIIIIIII rowsort
SELECT * FROM tab0, tab2, tab1 AS cor0 WHERE NOT ( NULL ) NOT IN ( tab0.col0 )
----

query I rowsort
SELECT ( - col2 ) * col1 + col2 AS col0 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT 26 - - tab2.col1 AS col1 FROM tab2
----
43
57
85

query I rowsort
SELECT ALL + col2 * 22 * - col0 + - col2 * - col2 AS col0 FROM tab0 cor0
----
-153832
-16335
-769

query I rowsort
SELECT - - col0 - + col2 * - col2 * col0 AS col2 FROM tab0 AS cor0
----
26160
598525
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4551
SELECT - col2 + + CAST( NULL AS SIGNED ) + col2 * + col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4551
SELECT - col2 + + CAST ( NULL AS INTEGER ) + col2 * + col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * 44 AS col2 FROM tab2
----
308
3432
3476

query I rowsort
SELECT ALL - - col2 - - col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + col0 + + 84 * col2 FROM tab2 AS cor0
----
2262
2275
3271

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - 10 - + col2 col2 FROM tab2 AS cor0
----
132
283
564

query I rowsort
SELECT DISTINCT - col0 * + ( - col1 ) + - col2 AS col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT + col2 + ( cor0.col1 * + cor0.col2 ) AS col0 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4558
SELECT ALL + - col2 / - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4558
SELECT ALL + - col2 / - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4559
SELECT ALL - col0 * - CAST( col1 * col2 AS SIGNED ) FROM tab2 AS cor0
----
119652
51034
5859

skipif mysql # not compatible
query I rowsort label-4559
SELECT ALL - col0 * - CAST ( col1 * col2 AS INTEGER ) FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL - col1 + - 16 + - ( - col0 * 25 ) AS col0 FROM tab2 AS cor0
----
128
1875
1942

query I rowsort
SELECT DISTINCT + col2 - - col0 * - 69 AS col0 FROM tab2 cor0
----
-456
-5356
-5413

onlyif mysql # use DIV operator for integer division
query I rowsort label-4562
SELECT DISTINCT + - col0 DIV 68 + - cor0.col1 * - col1 FROM tab0 AS cor0
----
7396
8280
9409

skipif mysql # not compatible
query I rowsort label-4562
SELECT DISTINCT + - col0 / 68 + - cor0.col1 * - col1 FROM tab0 AS cor0
----
7396
8280
9409

query I rowsort
SELECT ALL - - col2 * - col0 * cor0.col2 + col0 * + col1 FROM tab2 AS cor0
----
-112733
-48126
-4886

query I rowsort
SELECT ALL - col0 + - tab2.col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT + col0 * col0 - - col0 AS col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT - col0 * + 5 AS col1 FROM tab2 AS cor0
----
-35
-390
-395

query I rowsort
SELECT tab0.col2 * 7 FROM tab0
----
231
574
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4568
SELECT - col0 * - ( - 66 ) - - cor0.col0 DIV col0 FROM tab0 AS cor0
----
-1583
-2309
-5873

skipif mysql # not compatible
query I rowsort label-4568
SELECT - col0 * - ( - 66 ) - - cor0.col0 / col0 FROM tab0 AS cor0
----
-1583
-2309
-5873

onlyif mysql # use DIV operator for integer division
query I rowsort label-4569
SELECT DISTINCT - 3 DIV + col0 + col2 * - col0 FROM tab0 cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-4569
SELECT DISTINCT - 3 / + col0 + col2 * - col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT col2 * + 82 + col2 FROM tab1 AS cor0
----
4482
4731
7968

query I rowsort
SELECT DISTINCT + ( col1 ) * - col2 + + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL - 75 + - cor0.col2 AS col0 FROM tab1 cor0
----
-129
-132
-171

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) + col2 * col2 AS col1 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT + + cor0.col2 * - 29 + col2 AS col0 FROM tab2 AS cor0
----
-1064
-728
-756

query I rowsort
SELECT ALL + col1 * col0 + col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT tab2.col1 + col0 + - ( col2 + - ( + 55 ) ) * - col2 * - 50 FROM tab2
----
32396
37837
37838

query I rowsort
SELECT 50 + - 55 FROM tab2 AS cor0
----
-5
-5
-5

query I rowsort
SELECT ( 33 ) - - col0 * + ( + 89 * - col1 ) AS col1 FROM tab1 cor0
----
-56927
-6909
-92527

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 96 col1 FROM tab1 cor0
----
96
96
96

query I rowsort
SELECT - + 85 * + cor0.col0 FROM tab0 AS cor0
----
-2040
-2975
-7565

query I rowsort
SELECT + 53 * + col1 AS col1 FROM tab0 AS cor0
----
4558
4823
5141

query I rowsort
SELECT + + 6 * col2 AS col0 FROM tab1 AS cor0
----
324
342
576

query I rowsort
SELECT ALL ( 4 + + col0 ) * 64 FROM tab2
----
5248
5312
704

onlyif mysql # use DIV operator for integer division
query I rowsort label-4584
SELECT - - cor0.col2 DIV - col1 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-4584
SELECT - - cor0.col2 / - col1 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT - ( + cor0.col1 ) + col2 * col0 AS col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT - col2 + + col0 * col2 AS col1 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT col0 * 26 AS col1 FROM tab1 AS cor0
----
1664
2080
78

query I rowsort
SELECT DISTINCT + 98 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4589
SELECT 7 + col2 * col0 DIV col2 AS col2 FROM tab0
----
31
42
96

skipif mysql # not compatible
query I rowsort label-4589
SELECT 7 + col2 * col0 / col2 AS col2 FROM tab0
----
31
42
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 + - col2 * col0 col2 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4591
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-4591
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
NULL

query I rowsort
SELECT ALL - col2 * - ( 42 ) - + col1 AS col1 FROM tab2 AS cor0
----
1033
1103
1579

query I rowsort
SELECT ALL + col1 + ( - 57 ) AS col2 FROM tab2 AS cor0
----
-26
-40
2

query I rowsort
SELECT DISTINCT + + col2 + col1 + - ( col0 + - col1 ) FROM tab0 AS cor0
----
160
175
181

query I rowsort
SELECT - col1 + col1 * cor0.col0 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL col1 * 76 - + col2 * cor0.col2 * + col0 AS col0 FROM tab2 cor0
----
-112784
-2747
-48244

query I rowsort
SELECT + col0 * + 8 FROM tab0 AS cor0
----
192
280
712

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT col1 - - col1 NOT BETWEEN col0 * - col0 + col1 + tab1.col1 AND - col2 + + col2 * - col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col0 + + col0 * + col1 col2 FROM tab0
----
2174
3527
8279

onlyif mysql # use DIV operator for integer division
query I rowsort label-4600
SELECT ALL + col1 DIV col1 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4600
SELECT ALL + col1 / col1 AS col0 FROM tab1
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4601
SELECT - col0 DIV + col0 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4601
SELECT - col0 / + col0 AS col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT ALL - col1 FROM tab1 WHERE + col2 + col0 IN ( - col2 - col1 * col2 )
----

query I rowsort
SELECT col1 + - col2 * + col2 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT DISTINCT col1 * col0 + col1 + + col1 * + col2 FROM tab0
----
15652
3589
4988

query I rowsort
SELECT + col0 * - col2 - tab0.col1 FROM tab0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-4606
SELECT ALL - col2 DIV col0 AS col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-4606
SELECT ALL - col2 / col0 AS col0 FROM tab1
----
-1
-18
0

query I rowsort
SELECT DISTINCT - col2 * col1 * col2 + col1 + + tab0.col2 FROM tab0
----
-611711
-93535
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + col1 + - col2 * - col1 col0 FROM tab0
----
229
2948
7642

query I rowsort
SELECT col2 * - col0 + tab1.col2 * - col0 AS col1 FROM tab1
----
-15360
-324
-7296

query I rowsort
SELECT DISTINCT + col2 * + col1 * col0 - - col2 FROM tab2
----
119678
51072
5886

query I rowsort
SELECT - col1 * col2 * col2 AS col0 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT - col1 + + col0 * col0 FROM tab0 WHERE + col0 + col1 NOT IN ( col1 )
----
1128
490
7830

query I rowsort
SELECT ALL col2 + col2 + - col1 AS col2 FROM tab0
----
-20
-95
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4614
SELECT + col1 DIV - col0 + - col0 col1 FROM tab1
----
-11
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4614
SELECT + col1 / - col0 + - col0 col1 FROM tab1
----
-11
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * + col2 + col0 * tab0.col2 col2 FROM tab0
----
132
14760
3630

query I rowsort
SELECT ALL cor0.col2 * - col0 + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col1 col0 FROM tab1
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col2 col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL + 3 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT - col0 * tab1.col1 - col0 FROM tab1
----
-1120
-704
-81

query I rowsort
SELECT ALL - col0 + tab0.col0 * col0 FROM tab0
----
1190
552
7832

query I rowsort
SELECT ALL col2 + + tab0.col1 AS col2 FROM tab0
----
119
173
98

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT + col1 IN ( - col0 * col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT col2 + col2 * - col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + ( col1 ) * col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col1 + - col2 * ( col1 + + col2 ) FROM tab0 AS cor0
----
-1
-14095
-3841

query I rowsort
SELECT DISTINCT - 71 AS col1 FROM tab0 cor0
----
-71

query I rowsort
SELECT DISTINCT + 91 * - col1 FROM tab2 AS cor0
----
-1547
-2821
-5369

onlyif mysql # use DIV operator for integer division
query I rowsort label-4629
SELECT - ( col2 ) DIV - 19 AS col1 FROM tab1 AS cor0
----
2
3
5

skipif mysql # not compatible
query I rowsort label-4629
SELECT - ( col2 ) / - 19 AS col1 FROM tab1 AS cor0
----
2
3
5

query I rowsort
SELECT DISTINCT + + 77 * - cor0.col2 FROM tab2 AS cor0
----
-2002
-2079
-2926

query I rowsort
SELECT DISTINCT + 52 AS col1 FROM tab0
----
52

query I rowsort
SELECT - 62 + - col0 FROM tab1 AS cor0
----
-126
-142
-65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4633
SELECT DISTINCT + col1 * cor0.col2 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4633
SELECT DISTINCT + col1 * cor0.col2 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 + col0 + + 6 FROM tab1
----
35
80
99

query I rowsort
SELECT - col1 + - 0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + ( col1 ) * - ( col1 ) FROM tab1
----
-100
-169
-676

query I rowsort
SELECT ( col1 ) + col1 AS col1 FROM tab0 AS cor0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 23 col1 FROM tab1 AS cor0
----
23
23
23

query I rowsort
SELECT + col0 * col2 + - 15 + - col0 FROM tab1
----
144
3569
7585

query I rowsort
SELECT + col1 * - col1 + + 85 * - col0 AS col2 FROM tab1
----
-5540
-6969
-931

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( col0 ) + col0 * col2 col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - col1 * cor0.col1 + - cor0.col2 * col1 + - 54 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-12016
-20171
-9560

query I rowsort
SELECT col1 * - col2 + + tab0.col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT 80 - - 70 FROM tab1
----
150

query I rowsort
SELECT DISTINCT + 53 - col0 FROM tab2
----
-25
-26
46

query I rowsort
SELECT DISTINCT + 69 - col2 FROM tab0
----
-13
36
68

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0, tab0 cor1, tab0 cor2
----
972 values hashing to 04d825fa29899c3ee2704c26a542267d

query I rowsort
SELECT 40 * col2 - col1 FROM tab1 AS cor0
----
2134
2270
3827

onlyif mysql # use DIV operator for integer division
query I rowsort label-4649
SELECT + - ( col1 ) DIV col2 - ( col0 + col1 ) AS col0 FROM tab0 AS cor0
----
-112
-181
-229

skipif mysql # not compatible
query I rowsort label-4649
SELECT + - ( col1 ) / col2 - ( col0 + col1 ) AS col0 FROM tab0 AS cor0
----
-112
-181
-229

query I rowsort
SELECT col1 * col2 + - cor0.col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT col0 * col0 * - col0 + col0 FROM tab1 AS cor0
----
-24
-262080
-511920

query I rowsort
SELECT - - 95 - col1 * - col2 FROM tab1 AS cor0
----
1343
1499
665

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col2 ) + col2 + col2 * col0 * + cor0.col2 col0 FROM tab2 cor0
----
114152
5157
52780

query I rowsort
SELECT DISTINCT 62 * + col2 + col0 * col2 AS col1 FROM tab1
----
13632
3510
7182

query I rowsort
SELECT ALL + - ( col1 ) + col0 * + col2 AS col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT + ( 36 ) * - cor0.col1 FROM tab1 AS cor0
----
-360
-468
-936

query I rowsort
SELECT ALL + + 28 FROM tab2 AS cor0
----
28
28
28

query I rowsort
SELECT + ( 41 ) + - col1 * col2 FROM tab0 AS cor0
----
-2797
-56
-7421

query I rowsort
SELECT - 4 * - col2 FROM tab0 AS cor0
----
132
328
4

query I rowsort
SELECT DISTINCT col1 * + col0 + + col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - 83 + col1 FROM tab0
----
14
3
8

query I rowsort
SELECT 47 + tab0.col0 AS col2 FROM tab0
----
136
71
82

query I rowsort
SELECT col0 + + col2 + - col1 AS col0 FROM tab1 AS cor0
----
111
163
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + + col0 - col0 col2 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4665
SELECT + - col1 * - col0 - + cor0.col1 DIV + col0 FROM tab1 AS cor0
----
1040
640
70

skipif mysql # not compatible
query I rowsort label-4665
SELECT + - col1 * - col0 - + cor0.col1 / + col0 FROM tab1 AS cor0
----
1040
640
70

query I rowsort
SELECT + col1 * col2 + col0 AS col2 FROM tab1
----
1328
1407
634

query I rowsort
SELECT DISTINCT col1 * 57 + + col2 FROM tab2 AS cor0
----
1007
1794
3389

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4668
SELECT DISTINCT + CAST( 1 AS SIGNED ) * col1 * col1 AS col1 FROM tab2
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-4668
SELECT DISTINCT + CAST ( 1 AS INTEGER ) * col1 * col1 AS col1 FROM tab2
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-4669
SELECT ALL col2 DIV 96 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4669
SELECT ALL col2 / 96 FROM tab0
----
0
0
0

query I rowsort
SELECT cor0.col2 FROM tab0 cor0 CROSS JOIN tab1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT DISTINCT + tab2.col1 + col2 * - col2 AS col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT DISTINCT col2 AS col2 FROM tab1 WHERE NULL = NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4673
SELECT + col1 DIV - tab2.col0 + + col0 FROM tab2
----
3
78
79

skipif mysql # not compatible
query I rowsort label-4673
SELECT + col1 / - tab2.col0 + + col0 FROM tab2
----
3
78
79

query I rowsort
SELECT col2 * - tab2.col2 FROM tab2 WHERE ( col0 ) NOT IN ( col2 / col0 )
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT col2 AS col2 FROM tab0 WHERE NOT NULL < ( NULL )
----

query I rowsort
SELECT DISTINCT col0 * - col0 * col2 FROM tab2
----
-1323
-158184
-237158

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT - col0 + + col0 IN ( + col0 * + col0 + col2 + - col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL - cor0.col0 + - col0 AS col0 FROM tab0 AS cor0
----
-178
-48
-70

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL IN ( col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4680
SELECT ALL - col0 + col0 DIV - col1 col2 FROM tab2
----
-7
-79
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4680
SELECT ALL - col0 + col0 / - col1 col2 FROM tab2
----
-7
-79
-83

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab1, tab0, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT col2 * + col2 * col2 FROM tab2 AS cor0
----
17576
19683
54872

onlyif mysql # use DIV operator for integer division
query I rowsort label-4683
SELECT - col2 DIV + col2 + col2 AS col2 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-4683
SELECT - col2 / + col2 + col2 AS col2 FROM tab0
----
0
32
81

query I rowsort
SELECT DISTINCT - col1 * cor0.col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4685
SELECT DISTINCT + + col1 * + col0 + - col2 DIV + col0 col1 FROM tab1 AS cor0
----
1039
60
640

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4685
SELECT DISTINCT + + col1 * + col0 + - col2 / + col0 col1 FROM tab1 AS cor0
----
1039
60
640

query I rowsort
SELECT DISTINCT col0 * col0 * col1 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT ALL - tab0.col1 FROM tab1 AS cor0 CROSS JOIN tab0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * tab1.col0 * col1 col0 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT - - 61 AS col0 FROM tab1 AS cor0
----
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-4690
SELECT 17 DIV 76 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-4690
SELECT 17 / 76 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL + col0 - - col0 AS col2 FROM tab1
----
128
160
6

query I rowsort
SELECT - cor0.col0 + + 99 + + col0 FROM tab2 AS cor0
----
99
99
99

query I rowsort
SELECT - col2 * ( col2 ) FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT + - col0 * col0 + col2 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ( 74 ) * col1 + col1 AS col2 FROM tab1
----
1950
750
975

query I rowsort
SELECT - ( + col0 ) + col0 * col2 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT col1 + ( + col1 ) AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT - cor0.col2 * + col0 - col1 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT 93 + + col0 * col2 FROM tab2 AS cor0
----
2121
282
3095

query I rowsort
SELECT 50 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT - cor0.col0 * + col0 + 79 AS col1 FROM tab1 AS cor0
----
-4017
-6321
70

query I rowsort
SELECT DISTINCT - 45 * col0 AS col2 FROM tab2 AS cor0
----
-315
-3510
-3555

query I rowsort
SELECT col2 * cor0.col2 - + cor0.col1 * - col1 FROM tab0 AS cor0
----
15005
8485
9410

query I rowsort
SELECT DISTINCT + col1 * tab0.col1 + col0 * col1 FROM tab0
----
12804
16380
9460

query I rowsort
SELECT + col2 * + ( col2 ) * + col1 FROM tab1 AS cor0
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-4706
SELECT ALL col2 + col1 DIV + ( - cor0.col1 * col2 ) FROM tab0 AS cor0
----
0
33
82

skipif mysql # not compatible
query I rowsort label-4706
SELECT ALL col2 + col1 / + ( - cor0.col1 * col2 ) FROM tab0 AS cor0
----
0
33
82

query I rowsort
SELECT - + cor0.col2 * col1 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-4708
SELECT - + col1 + col2 * + 7 - - cor0.col0 DIV - col0 AS col0 FROM tab0 AS cor0
----
-91
144
482

skipif mysql # not compatible
query I rowsort label-4708
SELECT - + col1 + col2 * + 7 - - cor0.col0 / - col0 AS col0 FROM tab0 AS cor0
----
-91
144
482

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( - col1 ) * + col2 col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT DISTINCT + - col0 * 20 + - col0 AS col1 FROM tab0 AS cor0
----
-1869
-504
-735

query I rowsort
SELECT DISTINCT - col2 * 7 FROM tab1 AS cor0
----
-378
-399
-672

query I rowsort
SELECT + + cor0.col1 * - col2 * 77 AS col2 FROM tab2 AS cor0
----
-118118
-49742
-64449

query I rowsort
SELECT ALL + col0 + + ( col2 ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col1 * - 32 FROM tab0 AS cor0
----
2752
2912
3104

query I rowsort
SELECT + - cor0.col0 * col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col2 * + col2 + col2 AS col0 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT + + col2 + ( col0 ) FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL + col2 - tab1.col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT - - ( col1 ) + ( - col0 ) * col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - 9 * 22 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a1649caef64269e1483d5d2ade0b20d5

query I rowsort
SELECT - + 42 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 56f86ff01cd96a3511acd46e0e811e27

query I rowsort
SELECT + 33 + tab2.col2 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 3e6d233e55d9ef6fb3d420000d6856b1

query I rowsort
SELECT - 78 * - 45 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to b289c2a826649d433c18a3de02c90a0d

query I rowsort
SELECT - + 83 + cor0.col1 AS col2 FROM tab2 AS cor0
----
-24
-52
-66

query I rowsort
SELECT - 61 - col2 FROM tab0
----
-143
-62
-94

query I rowsort
SELECT col1 * col1 - - tab2.col2 AS col2 FROM tab2
----
327
3507
988

query I rowsort
SELECT ALL + ( - col2 ) + - col1 * - col2 AS col0 FROM tab0 AS cor0
----
2805
7380
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4728
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * 48 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4728
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * 48 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + 13 * 83 AS col2 FROM tab1 AS cor0
----
-1079

query I rowsort
SELECT - 68 * col2 FROM tab0 cor0
----
-2244
-5576
-68

query I rowsort
SELECT ALL + - 76 * 37 AS col2 FROM tab2 AS cor0
----
-2812
-2812
-2812

query I rowsort
SELECT ALL col2 + col1 * 43 FROM tab2 AS cor0
----
1360
2563
769

query I rowsort
SELECT ( col1 ) - - col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT + col0 * + col1 + - 97 FROM tab2 AS cor0
----
120
1246
4505

query I rowsort
SELECT DISTINCT + 30 * col1 - + col2 FROM tab0 AS cor0
----
2547
2648
2909

query I rowsort
SELECT ALL + col2 * - cor0.col1 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - col1 * - cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - + 23 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to ef919ea6037591a6f09aab2a0b91bc31

query I rowsort
SELECT - col2 * ( 25 ) FROM tab1
----
-1350
-1425
-2400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4740
SELECT DISTINCT + col1 * CAST( + col2 AS SIGNED ) AS col2 FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-4740
SELECT DISTINCT + col1 * CAST ( + col2 AS INTEGER ) AS col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT col1 * col1 * col0 AS col2 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT - col2 * 96 * col0 FROM tab1 AS cor0
----
-15552
-350208
-737280

query I rowsort
SELECT DISTINCT 20 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
20

query I rowsort
SELECT cor0.col1 * + ( - 30 ) FROM tab1 AS cor0
----
-300
-390
-780

query I rowsort
SELECT ALL - col1 + + col2 * col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT col0 + + 81 + - 81 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4747
SELECT DISTINCT CAST( - 74 AS SIGNED ) FROM tab1 AS cor0
----
-74

skipif mysql # not compatible
query I rowsort label-4747
SELECT DISTINCT CAST ( - 74 AS INTEGER ) FROM tab1 AS cor0
----
-74

query I rowsort
SELECT ALL - 21 * - ( - col0 ) + col0 FROM tab1 AS cor0
----
-1280
-1600
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 38 ) col2 FROM tab1 AS cor0
----
38
38
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * 29 + col0 col1 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT ALL cor1.col2 AS col1 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 74 col2 FROM tab1 cor0
----
-74

query I rowsort
SELECT ALL 9 * + cor0.col1 + + col2 FROM tab1 AS cor0
----
147
213
288

query I rowsort
SELECT DISTINCT col1 * + col0 + - col0 AS col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT DISTINCT 10 + + col2 FROM tab2 AS cor0
----
36
37
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * - col1 + + col2 col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT - col2 - + ( - tab1.col0 + - col2 ) * + tab1.col0 FROM tab1
----
117
13984
7687

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * 22 col1 FROM tab1 AS cor0
----
1408
1760
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 2 + col1 col2 FROM tab1 AS cor0
----
11
24
8

query I rowsort
SELECT DISTINCT col1 * 25 + - col0 FROM tab0 AS cor0
----
2126
2186
2390

onlyif mysql # use DIV operator for integer division
query I rowsort label-4761
SELECT + ( - col2 ) DIV + col1 AS col2 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-4761
SELECT + ( - col2 ) / + col1 AS col2 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT 79 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT DISTINCT 30 * + col1 AS col0 FROM tab1
----
300
390
780

query I rowsort
SELECT - col1 + - tab1.col0 AS col1 FROM tab1
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4765
SELECT DISTINCT col2 DIV + 74 AS col1 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-4765
SELECT DISTINCT col2 / + 74 AS col1 FROM tab0
----
0
1

query I rowsort
SELECT - + col2 + cor0.col2 + col0 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * + 5 col2 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT - 42 * col2 AS col0 FROM tab0
----
-1386
-3444
-42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4769
SELECT + - col1 - - CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4769
SELECT + - col1 - - CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4770
SELECT - col0 DIV + col1 + 64 + + cor0.col2 col2 FROM tab1 cor0
----
115
118
154

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4770
SELECT - col0 / + col1 + 64 + + cor0.col2 col2 FROM tab1 cor0
----
115
118
154

query I rowsort
SELECT ALL col1 * + col2 + + col2 FROM tab0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4772
SELECT ALL col1 * col1 + + CAST( col0 * col1 AS SIGNED ) FROM tab0
----
12804
16380
9460

skipif mysql # not compatible
query I rowsort label-4772
SELECT ALL col1 * col1 + + CAST ( col0 * col1 AS INTEGER ) FROM tab0
----
12804
16380
9460

onlyif mysql # use DIV operator for integer division
query I rowsort label-4773
SELECT + col2 DIV + col0 + col0 AS col0 FROM tab1
----
21
64
81

skipif mysql # not compatible
query I rowsort label-4773
SELECT + col2 / + col0 + col0 AS col0 FROM tab1
----
21
64
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4774
SELECT ALL col0 DIV ( + 76 ) FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4774
SELECT ALL col0 / ( + 76 ) FROM tab0
----
0
0
1

query I rowsort
SELECT DISTINCT - col0 + 28 AS col2 FROM tab0 AS cor0
----
-61
-7
4

query I rowsort
SELECT col0 * - col2 + - 39 * col0 AS col2 FROM tab2 AS cor0
----
-462
-5070
-6083

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col0 + CAST ( col1 AS REAL ) * + col1 FROM tab1 AS cor0
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-4778
SELECT DISTINCT + col0 DIV col0 + ( col1 ) + + col2 FROM tab0 AS cor0
----
120
174
99

skipif mysql # not compatible
query I rowsort label-4778
SELECT DISTINCT + col0 / col0 + ( col1 ) + + col2 FROM tab0 AS cor0
----
120
174
99

query I rowsort
SELECT ALL - col1 * + col2 - - col2 * cor0.col0 FROM tab0 AS cor0
----
-164
-2046
-62

query I rowsort
SELECT + cor0.col2 + 27 FROM tab2 AS cor0
----
53
54
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-4781
SELECT + col2 DIV - col0 + col2 * col1 AS col2 FROM tab2 AS cor0
----
1534
646
834

skipif mysql # not compatible
query I rowsort label-4781
SELECT + col2 / - col0 + col2 * col1 AS col2 FROM tab2 AS cor0
----
1534
646
834

query I rowsort
SELECT DISTINCT col2 + - col2 * col1 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT col1 + + 22 * cor0.col0 FROM tab0 AS cor0
----
2049
614
867

query I rowsort
SELECT ALL + col2 * + col1 * + col2 FROM tab2 cor0
----
22599
24548
39884

query I rowsort
SELECT - - col1 + col2 - + col1 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col1 * col1 + col2 - col2 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT + + col1 * col1 + 37 * + col0 FROM tab1 AS cor0
----
2468
3129
787

query I rowsort
SELECT 91 * - 11 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 3667bb5a646be23b1723c72afb70e5c6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4789
SELECT - + col1 DIV - 28 + + ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
17
32
61

skipif mysql # not compatible
query I rowsort label-4789
SELECT - + col1 / - 28 + + ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
17
32
61

query I rowsort
SELECT DISTINCT - col2 * 32 AS col2 FROM tab0 AS cor0
----
-1056
-2624
-32

query I rowsort
SELECT col0 + + tab2.col0 * + ( tab2.col2 ) + - tab2.col2 FROM tab2
----
169
2080
3043

onlyif mysql # use DIV operator for integer division
query I rowsort label-4792
SELECT ALL - tab2.col0 DIV + 6 FROM tab2, tab0 cor0
----
9 values hashing to a19be59c4f7a0e06f0829b3d2cdf3902

skipif mysql # not compatible
query I rowsort label-4792
SELECT ALL - tab2.col0 / + 6 FROM tab2, tab0 cor0
----
9 values hashing to a19be59c4f7a0e06f0829b3d2cdf3902

query I rowsort
SELECT + 78 * - col1 + - cor0.col2 - col2 * + col2 AS col0 FROM tab2 AS cor0
----
-2808
-3174
-5304

query I rowsort
SELECT + 99 - col0 FROM tab2
----
20
21
92

query I rowsort
SELECT 62 + col1 - - ( col0 ) FROM tab0
----
172
194
242

onlyif mysql # use DIV operator for integer division
query I rowsort label-4796
SELECT DISTINCT - col0 * - tab1.col2 + - ( col0 ) DIV + col0 - + ( 16 ) * col1 FROM tab1
----
-255
3487
7471

skipif mysql # not compatible
query I rowsort label-4796
SELECT DISTINCT - col0 * - tab1.col2 + - ( col0 ) / + col0 - + ( 16 ) * col1 FROM tab1
----
-255
3487
7471

query I rowsort
SELECT DISTINCT ( tab2.col1 ) - - 53 * col0 * - col1 AS col2 FROM tab2
----
-11470
-243847
-71162

query I rowsort
SELECT 15 * + tab2.col2 * col1 + - col0 + + col0 FROM tab2
----
12555
23010
9690

query I rowsort
SELECT ALL col0 - - tab2.col2 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4800
SELECT DISTINCT col2 + col0 DIV col1 - - 55 * + col2 FROM tab0
----
1848
4592
56

skipif mysql # not compatible
query I rowsort label-4800
SELECT DISTINCT col2 + col0 / col1 - - 55 * + col2 FROM tab0
----
1848
4592
56

query I rowsort
SELECT DISTINCT tab0.col2 * 60 FROM tab0
----
1980
4920
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4802
SELECT - + CAST( NULL AS SIGNED ) * - 8 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4802
SELECT - + CAST ( NULL AS INTEGER ) * - 8 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( + col0 * col2 ) FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT + - col0 * col2 * col0 AS col2 FROM tab2 cor0
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-4805
SELECT + col2 DIV - 77 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4805
SELECT + col2 / - 77 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - col1 - + ( col2 ) AS col1 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT col0 * - col0 + col0 FROM tab0
----
-1190
-552
-7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col1 ) + + col2 * ( col2 ) col1 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - ( + 58 * + col2 ) FROM tab1
----
-3132
-3306
-5568

query I rowsort
SELECT ALL - + cor0.col2 * - col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * - ( + col1 ) FROM tab0 AS cor0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-4812
SELECT + + col2 + + col2 DIV 30 AS col0 FROM tab0 cor0
----
1
34
84

skipif mysql # not compatible
query I rowsort label-4812
SELECT + + col2 + + col2 / 30 AS col0 FROM tab0 cor0
----
1
34
84

query I rowsort
SELECT DISTINCT + 29 * col0 + + col1 FROM tab0 AS cor0
----
1112
2672
782

query I rowsort
SELECT ALL + 62 * col1 AS col0 FROM tab0 AS cor0
----
5332
5642
6014

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4815
SELECT ALL - col1 * col0 + + CAST( NULL AS DECIMAL ) + - 50 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4815
SELECT ALL - col1 * col0 + + CAST ( NULL AS REAL ) + - 50 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 - col1 * + 79 FROM tab0 AS cor0
----
-6880
-7280
-7760

query I rowsort
SELECT 95 AS col0 FROM tab2 AS cor0
----
95
95
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4818
SELECT ALL + + col2 * col2 + + CAST( NULL AS SIGNED ) * - col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4818
SELECT ALL + + col2 * col2 + + CAST ( NULL AS INTEGER ) * - col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 97 + - col1 * col0 AS col0 FROM tab1 AS cor0
----
-543
-943
19

query I rowsort
SELECT DISTINCT - 80 - + col2 AS col2 FROM tab0 AS cor0
----
-113
-162
-81

query I rowsort
SELECT - + col2 + + col2 * + col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL - + cor0.col0 * col2 * 18 AS col0 FROM tab1 AS cor0
----
-138240
-2916
-65664

query I rowsort
SELECT DISTINCT cor0.col2 + col2 * - col0 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-4824
SELECT DISTINCT + col1 DIV cor0.col0 + + 83 + - col1 FROM tab2 AS cor0
----
24
56
66

skipif mysql # not compatible
query I rowsort label-4824
SELECT DISTINCT + col1 / cor0.col0 + + 83 + - col1 FROM tab2 AS cor0
----
24
56
66

query I rowsort
SELECT DISTINCT - - ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + col1 + - col1 * - col1 * + ( - col1 ) FROM tab1 AS cor0
----
-17550
-2184
-990

query I rowsort
SELECT ALL + 35 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT - col1 * - col2 * 24 AS col0 FROM tab1 AS cor0
----
13680
29952
33696

query I rowsort
SELECT DISTINCT - col0 * - col0 + + col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT - - col1 * - cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + col0 + col1 * col2 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT cor0.col1 + col1 + + col2 AS col0 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT - col0 * + ( + 91 ) + col1 FROM tab2 AS cor0
----
-606
-7039
-7172

query I rowsort
SELECT DISTINCT - - 99 + col2 AS col2 FROM tab2 AS cor0
----
125
126
137

query I rowsort
SELECT DISTINCT - - 60 - + cor0.col0 FROM tab2 AS cor0
----
-18
-19
53

query I rowsort
SELECT + - cor0.col0 + 67 FROM tab0 AS cor0
----
-22
32
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-4837
SELECT ALL + CAST( - col1 AS SIGNED ) DIV + col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4837
SELECT ALL + CAST ( - col1 AS INTEGER ) / + col0 FROM tab2 AS cor0
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 61 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT DISTINCT + - ( cor0.col0 ) FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT ALL + - ( 15 ) * cor0.col1 + - 56 * col0 AS col2 FROM tab0 AS cor0
----
-2634
-3415
-6349

query I rowsort
SELECT ( 12 ) FROM tab1, tab0 cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 43 * 21 - col2 col1 FROM tab0 AS cor0
----
821
870
902

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + - col0 * col1 col0 FROM tab1 cor0
----
-24
-583
-944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4844
SELECT - col0 * - CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-4844
SELECT - col0 * - CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-4845
SELECT col2 DIV col1 + + 44 FROM tab2
----
44
44
46

skipif mysql # not compatible
query I rowsort label-4845
SELECT col2 / col1 + + 44 FROM tab2
----
44
44
46

query I rowsort
SELECT - 75 AS col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to c0722b1d77ac0ed13c0f2691a5751c59

query I rowsort
SELECT + 51 + col1 FROM tab1
----
61
64
77

query I rowsort
SELECT col2 * tab0.col2 + - ( - 84 * col2 ) AS col2 FROM tab0
----
13612
3861
85

query I rowsort
SELECT - - col2 * 96 AS col1 FROM tab2 AS cor0
----
2496
2592
3648

query I rowsort
SELECT ALL + - col0 + cor0.col2 * + 39 AS col1 FROM tab2 AS cor0
----
1046
1403
936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + 32 * col0 col1 FROM tab0 AS cor0
----
1119
2766
735

query I rowsort
SELECT ALL - cor0.col1 * - ( + 28 ) + col0 AS col2 FROM tab0 AS cor0
----
2432
2637
2751

query I rowsort
SELECT DISTINCT ( ( - col1 ) ) + col2 + 2 FROM tab2
----
-2
-31
23

query I rowsort
SELECT col2 + ( + col0 * - col0 ) + ( - col0 ) FROM tab1
----
-4103
-6384
42

query I rowsort
SELECT 74 * - tab1.col1 AS col2 FROM tab1
----
-1924
-740
-962

query I rowsort
SELECT + + 34 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-25
17
3

query I rowsort
SELECT DISTINCT ( - col1 ) * col2 * ( - col0 ) FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL - 67 - col0 AS col2 FROM tab0 cor0
----
-102
-156
-91

query I rowsort
SELECT - col0 * col0 + 66 AS col2 FROM tab2 AS cor0
----
-6018
-6175
17

query I rowsort
SELECT + - col0 * - col1 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + cor0.col1 + - col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL + 25 * + col2 + - 99 * col0 AS col0 FROM tab1 AS cor0
----
-4911
-5520
1053

query I rowsort
SELECT ( col0 ) + + 8 FROM tab2 AS cor0
----
15
86
87

query I rowsort
SELECT col1 * col2 + 53 FROM tab0 AS cor0
----
150
2891
7515

query I rowsort
SELECT cor0.col1 * col0 + - cor0.col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT - col0 + col0 * 1 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * + col2 + col0 * - cor0.col2 col1 FROM tab2 cor0
----
-378
-4056
-6004

query I rowsort
SELECT DISTINCT 58 AS col1 FROM tab2, tab2 AS cor0
----
58

query I rowsort
SELECT DISTINCT + - cor0.col0 + - col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT ALL - - cor0.col0 * + col2 - - col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - col0 + - 94 FROM tab2 cor0
----
-101
-172
-173

onlyif mysql # use DIV operator for integer division
query I rowsort label-4872
SELECT 4 + + col1 DIV 21 + col0 AS col0 FROM tab0 AS cor0
----
32
43
97

skipif mysql # not compatible
query I rowsort label-4872
SELECT 4 + + col1 / 21 + col0 AS col0 FROM tab0 AS cor0
----
32
43
97

query I rowsort
SELECT + 68 AS col1 FROM tab2 AS cor0
----
68
68
68

query I rowsort
SELECT ALL ( - 83 ) * + tab2.col0 AS col2 FROM tab2
----
-581
-6474
-6557

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab1, tab2, tab2 cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT 77 AS col2 FROM tab0, tab0 AS cor0
----
77

query I rowsort
SELECT + 80 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT col1 * + 58 AS col1 FROM tab2 AS cor0
----
1798
3422
986

query I rowsort
SELECT ALL - - col0 + col1 * col2 + col2 FROM tab2 AS cor0
----
1638
763
871

query I rowsort
SELECT + + col0 + - 17 * + 15 AS col1 FROM tab1 AS cor0
----
-175
-191
-252

query I rowsort
SELECT DISTINCT 71 + cor0.col0 AS col0 FROM tab2 cor0
----
149
150
78

query I rowsort
SELECT col1 + 67 * - col1 AS col0 FROM tab2 AS cor0
----
-1122
-2046
-3894

query I rowsort
SELECT DISTINCT - - 45 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1170
450
585

query I rowsort
SELECT DISTINCT col2 * - 9 + col1 AS col0 FROM tab2 AS cor0
----
-175
-212
-325

query I rowsort
SELECT ALL + col0 + - col1 * - col2 AS col2 FROM tab2 cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 85 + - cor0.col0 col0 FROM tab2 AS cor0
----
-163
-164
-92

query I rowsort
SELECT - + ( cor0.col0 ) * - col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4888
SELECT - CAST( - col1 + - col2 AS SIGNED ) * - 46 AS col0 FROM tab1
----
-3082
-3680
-5014

skipif mysql # not compatible
query I rowsort label-4888
SELECT - CAST ( - col1 + - col2 AS INTEGER ) * - 46 AS col0 FROM tab1
----
-3082
-3680
-5014

onlyif mysql # use DIV operator for integer division
query I rowsort label-4889
SELECT ALL - ( col2 ) * ( + col1 ) DIV - col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4889
SELECT ALL - ( col2 ) * ( + col1 ) / - col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col2 * col1 * col2 AS col0 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT - 17 * col0 AS col0 FROM tab1
----
-1088
-1360
-51

query I rowsort
SELECT DISTINCT - 20 * - cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
1780
480
700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4893
SELECT - col2 * - CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4893
SELECT - col2 * - CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 - + ( col0 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL + col0 + ( + col1 ) FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4896
SELECT + - col2 + 74 DIV - col1 FROM tab1 AS cor0
----
-101
-56
-64

skipif mysql # not compatible
query I rowsort label-4896
SELECT + - col2 + 74 / - col1 FROM tab1 AS cor0
----
-101
-56
-64

query I rowsort
SELECT + + tab1.col0 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col1 + - 78 col0 FROM tab2
----
-1039
-3559
-367

query I rowsort
SELECT + ( - col0 ) - col1 AS col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT 82 + col2 * col1 FROM tab0
----
179
2920
7544

query I rowsort
SELECT DISTINCT tab2.col2 + + 97 AS col0 FROM tab2, tab1 AS cor0
----
123
124
135

query I rowsort
SELECT DISTINCT col2 * col2 + - 64 FROM tab1 cor0
----
2852
3185
9152

query I rowsort
SELECT + col0 * 80 + + col2 AS col0 FROM tab0 cor0
----
1953
2801
7202

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4904
SELECT DISTINCT + col1 + CAST( - col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-4904
SELECT DISTINCT + col1 + CAST ( - col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - col0 * + 67 AS col0 FROM tab0 AS cor0
----
-1608
-2345
-5963

query I rowsort
SELECT - col1 * - ( 23 ) FROM tab1 AS cor0
----
230
299
598

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 + + col1 col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + col0 + - ( + col0 ) + + col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + col2 * - 39 FROM tab2 AS cor0
----
-1014
-1053
-1482

query I rowsort
SELECT DISTINCT + + cor0.col2 * + col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ( - 42 + col0 ) * - col2 FROM tab2
----
-1406
-936
945

query I rowsort
SELECT + 85 FROM tab2, tab2 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to 5e8deeabad7bbbaf313fcdcb4adc75eb

query I rowsort
SELECT ALL tab2.col2 - + col2 FROM tab2
----
0
0
0

query I rowsort
SELECT - col0 + + ( + col0 ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - 29 - ( col2 ) AS col0 FROM tab0 AS cor0
----
-111
-30
-62

query I rowsort
SELECT + col0 + 87 * - col1 + 71 FROM tab1 AS cor0
----
-2188
-735
-980

query I rowsort
SELECT - col0 * ( + col1 ) * 31 FROM tab2 cor0
----
-142662
-41633
-6727

query I rowsort
SELECT - col2 * + col0 - + col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT - col2 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT 85 + + col0 + - 61 * - col1 * col0 FROM tab0 AS cor0
----
126013
207215
494213

query I rowsort
SELECT DISTINCT - + cor0.col1 * + col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col1 + + col0 * - col0 FROM tab2 AS cor0
----
-18
-6025
-6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col2 col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4924
SELECT - CAST( NULL AS SIGNED ) + + col0 / col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4924
SELECT - CAST ( NULL AS INTEGER ) + + col0 / col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4925
SELECT DISTINCT CAST( NULL AS SIGNED ) + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4925
SELECT DISTINCT CAST ( NULL AS INTEGER ) + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * - cor0.col2 - col2 AS col0 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT - + ( col0 ) * col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + 38 + 32 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
124
127
166

onlyif mysql # use DIV operator for integer division
query I rowsort label-4929
SELECT + + ( col1 ) DIV - col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4929
SELECT + + ( col1 ) / - col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col2 + + col2 * + col0 + col0 * + ( + col0 * + col2 ) FROM tab0
----
1259
19767
656738

query I rowsort
SELECT - col0 * 71 AS col1 FROM tab2
----
-497
-5538
-5609

query I rowsort
SELECT - + ( cor0.col2 ) * - col1 + - 70 FROM tab0 AS cor0
----
27
2768
7392

query I rowsort
SELECT col1 * - 6 + col0 * + ( 58 ) FROM tab0 AS cor0
----
1448
4616
876

onlyif mysql # use DIV operator for integer division
query I rowsort label-4934
SELECT + 9 DIV + 79 + col2 col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4934
SELECT + 9 / + 79 + col2 col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + cor0.col0 col1 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT - - col0 + + col1 * col1 FROM tab0 AS cor0
----
7420
8370
9444

query IIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0 WHERE NULL < NULL
----

query I rowsort
SELECT ALL ( tab1.col1 + + col1 ) AS col1 FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4939
SELECT + col2 DIV col0 - - col0 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-4939
SELECT + col2 / col0 - - col0 FROM tab1 AS cor0
----
21
64
81

query I rowsort
SELECT DISTINCT - col2 + 42 FROM tab0 AS cor0
----
-40
41
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4941
SELECT + col1 + CAST( NULL AS DECIMAL ) * + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4941
SELECT + col1 + CAST ( NULL AS REAL ) * + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * col2 + + col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT cor0.col2 * 40 AS col1 FROM tab1 AS cor0
----
2160
2280
3840

query I rowsort
SELECT DISTINCT + 84 AS col1 FROM tab1
----
84

query I rowsort
SELECT ALL - col0 * 12 + 54 * - col2 + - col2 FROM tab1
----
-3006
-3903
-6240

query I rowsort
SELECT DISTINCT - col1 + col0 + - col0 AS col2 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT ALL + col0 * - col0 + tab2.col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT - col2 * + 16 AS col2 FROM tab1
----
-1536
-864
-912

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4949
SELECT ALL - - col0 * CAST( NULL AS SIGNED ) + + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4949
SELECT ALL - - col0 * CAST ( NULL AS INTEGER ) + + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + 75 FROM tab1 AS cor0
----
49
62
65

query I rowsort
SELECT cor0.col0 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL + + col0 + 55 * - col0 FROM tab2 AS cor0
----
-378
-4212
-4266

query I rowsort
SELECT + col2 * - 84 AS col1 FROM tab0
----
-2772
-6888
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4954
SELECT + CAST( col1 AS SIGNED ) + - col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4954
SELECT + CAST ( col1 AS INTEGER ) + - col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 81 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 cor1, tab1 cor2
----
81 values hashing to 50d500b1082f81e0b02096b2afac91cd

query I rowsort
SELECT - col0 * 26 FROM tab1 AS cor0
----
-1664
-2080
-78

query I rowsort
SELECT ALL - col0 + ( col1 ) * col0 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4958
SELECT ALL - col0 / - CAST( NULL AS SIGNED ) - - ( col0 * + cor0.col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4958
SELECT ALL - col0 / - CAST ( NULL AS INTEGER ) - - ( col0 * + cor0.col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4959
SELECT col1 DIV 59 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4959
SELECT col1 / 59 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT ( - ( + col0 ) ) * + col2 + 17 AS col1 FROM tab1 AS cor0
----
-145
-3631
-7663

onlyif mysql # use DIV operator for integer division
query I rowsort label-4961
SELECT DISTINCT ( 13 ) DIV col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-4961
SELECT DISTINCT ( 13 ) / col1 FROM tab0
----
0

query I rowsort
SELECT - 55 * 69 AS col2 FROM tab1
----
-3795
-3795
-3795

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - cor0.col1 ) col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT 92 + - col0 FROM tab2
----
13
14
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4965
SELECT CAST( NULL AS DECIMAL ) + - 57 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4965
SELECT CAST ( NULL AS REAL ) + - 57 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - col1 + col2 + col1 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + - ( col0 ) * col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + 43 * col1 FROM tab1 cor0
----
1118
430
559

query I rowsort
SELECT DISTINCT - col2 * + col1 - - 7 FROM tab1 AS cor0
----
-1241
-1397
-563

query I rowsort
SELECT - + cor0.col2 + + col0 * 47 AS col1 FROM tab2 AS cor0
----
302
3640
3675

query I rowsort
SELECT DISTINCT - cor0.col2 + col0 * col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + col2 + - 3 FROM tab0 AS cor0
----
-2
30
79

query I rowsort
SELECT + 47 + + col1 * + col1 FROM tab1
----
147
216
723

query I rowsort
SELECT DISTINCT - 17 + col1 FROM tab2
----
0
14
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-4975
SELECT + + col1 * col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4975
SELECT + + col1 * col0 / - col1 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + col1 + 50 AS col0 FROM tab2 cor0
----
109
67
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + ( + cor0.col1 ) col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL col1 + col0 * + col0 AS col2 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT + col0 + - col1 * col2 AS col0 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT - cor0.col0 * - col0 * ( col0 ) + - ( col2 + col2 * ( ( col1 ) ) ) AS col1 FROM tab2 AS cor0
----
-521
472992
492355

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + col0 * + col0 col1 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT DISTINCT + col1 + ( 49 + col1 ) * + col0 FROM tab2 AS cor0
----
5231
591
8483

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4983
SELECT ALL CAST( NULL AS SIGNED ) - - col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4983
SELECT ALL CAST ( NULL AS INTEGER ) - - col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 87 * - col1 + tab0.col2 - col1 AS col0 FROM tab0
----
-7535
-7926
-8535

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4985
SELECT - CAST( col2 AS SIGNED ) * - col0 + + tab1.col1 * + col1 FROM tab1
----
3748
7849
838

skipif mysql # not compatible
query I rowsort label-4985
SELECT - CAST ( col2 AS INTEGER ) * - col0 + + tab1.col1 * + col1 FROM tab1
----
3748
7849
838

onlyif mysql # use DIV operator for integer division
query I rowsort label-4986
SELECT + col0 DIV 61 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4986
SELECT + col0 / 61 FROM tab1
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4987
SELECT CAST( ( col1 ) AS SIGNED ) * 73 AS col0 FROM tab0
----
6278
6643
7081

skipif mysql # not compatible
query I rowsort label-4987
SELECT CAST ( ( col1 ) AS INTEGER ) * 73 AS col0 FROM tab0
----
6278
6643
7081

query I rowsort
SELECT DISTINCT col1 + col2 * + col0 - - 40 FROM tab1
----
228
3698
7733

onlyif mysql # use DIV operator for integer division
query I rowsort label-4989
SELECT DISTINCT - col1 * col0 - - col2 DIV ( + col1 ) col0 FROM tab2
----
-1341
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4989
SELECT DISTINCT - col1 * col0 - - col2 / ( + col1 ) col0 FROM tab2
----
-1341
-217
-4602

query I rowsort
SELECT DISTINCT 47 + - col2 * - col2 * - col0 FROM tab1 AS cor0
----
-207889
-737233
-8701

query I rowsort
SELECT - - 95 AS col0 FROM tab1 AS cor0
----
95
95
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-4992
SELECT + col1 DIV col1 + + col0 AS col0 FROM tab1 cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-4992
SELECT + col1 / col1 + + col0 AS col0 FROM tab1 cor0
----
4
65
81

query I rowsort
SELECT 18 * col0 FROM tab1
----
1152
1440
54

query I rowsort
SELECT DISTINCT + col0 * - col2 * + tab1.col2 AS col1 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT + col1 * - col1 + - col0 AS col2 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT + - cor0.col2 * col0 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + - col2 * col0 + - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT 76 AS col0 FROM tab2
----
76

query I rowsort
SELECT - col2 * col2 * cor0.col1 + + 62 * col0 AS col1 FROM tab2 AS cor0
----
-19650
-22165
-35048

query I rowsort
SELECT DISTINCT + ( - col2 ) * 15 - 59 FROM tab2 AS cor0
----
-449
-464
-629

onlyif mysql # use DIV operator for integer division
query I rowsort label-5001
SELECT ALL ( + col1 ) DIV - cor0.col1 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5001
SELECT ALL ( + col1 ) / - cor0.col1 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT cor0.col2 + + 76 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 6eb06975d1c20d9170e94643546f316a

query I rowsort
SELECT DISTINCT + col1 - cor0.col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL col1 - 11 * col2 AS col2 FROM tab2
----
-227
-266
-401

query I rowsort
SELECT + + col1 * - 40 AS col0 FROM tab1 AS cor0
----
-1040
-400
-520

query I rowsort
SELECT DISTINCT col1 + + col0 * + col2 FROM tab2
----
2087
220
3019

query I rowsort
SELECT - col1 + - tab2.col2 + - col0 AS col2 FROM tab2
----
-134
-163
-65

query I rowsort
SELECT ALL - 53 + - col0 AS col1 FROM tab0
----
-142
-77
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - col0 * + ( tab0.col1 * - col0 ) col0 FROM tab0
----
118824
49503
720729

onlyif mysql # use DIV operator for integer division
query I rowsort label-5010
SELECT - col2 * - col2 + + 9 DIV - tab2.col0 FROM tab2
----
1444
676
728

skipif mysql # not compatible
query I rowsort label-5010
SELECT - col2 * - col2 + + 9 / - tab2.col0 FROM tab2
----
1444
676
728

query I rowsort
SELECT + - col2 + + ( + col2 ) FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5012
SELECT ALL - col2 DIV - col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5012
SELECT ALL - col2 / - col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - + col2 + 94 FROM tab2 AS cor0
----
56
67
68

query I rowsort
SELECT ALL - col2 + col2 * col1 * + 98 + + col0 * col1 FROM tab1
----
123248
137616
56443

query I rowsort
SELECT 59 - col2 FROM tab1
----
-37
2
5

query I rowsort
SELECT ALL + 86 + col0 FROM tab0
----
110
121
175

query I rowsort
SELECT DISTINCT 21 FROM tab1, tab0, tab1 AS cor0
----
21

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col1 AS REAL ) * col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + col0 * - ( cor0.col0 * col2 ) FROM tab2 AS cor0
----
-1323
-158184
-237158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5020
SELECT ALL + CAST( + 13 AS SIGNED ) + cor0.col1 FROM tab1 AS cor0
----
23
26
39

skipif mysql # not compatible
query I rowsort label-5020
SELECT ALL + CAST ( + 13 AS INTEGER ) + cor0.col1 FROM tab1 AS cor0
----
23
26
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5021
SELECT DISTINCT CAST( col2 AS SIGNED ) AS col1 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5021
SELECT DISTINCT CAST ( col2 AS INTEGER ) AS col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - ( + 29 ) * col2 FROM tab2 AS cor0
----
-1102
-754
-783

query I rowsort
SELECT - ( col1 ) * - col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + ( 91 ) FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT DISTINCT - 99 + col1 * + col1 AS col0 FROM tab2 AS cor0
----
190
3382
862

onlyif mysql # use DIV operator for integer division
query I rowsort label-5026
SELECT - col1 * col0 DIV + col2 FROM tab1 cor0
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-5026
SELECT - col1 * col0 / + col2 FROM tab1 cor0
----
-1
-10
-11

query I rowsort
SELECT ALL + 0 * 73 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - cor0.col2 * col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - 5 * + col0 AS col1 FROM tab2 AS cor0
----
-35
-390
-395

query I rowsort
SELECT ALL - - col1 + - 69 + col0 * 4 FROM tab2 AS cor0
----
-10
264
302

query I rowsort
SELECT - 37 * + 28 AS col1 FROM tab1 cor0
----
-1036
-1036
-1036

query I rowsort
SELECT ALL col2 * ( col2 * col1 ) AS col2 FROM tab2
----
22599
24548
39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-5033
SELECT col2 * col1 DIV - tab2.col0 FROM tab2
----
-119
-19
-8

skipif mysql # not compatible
query I rowsort label-5033
SELECT col2 * col1 / - tab2.col0 FROM tab2
----
-119
-19
-8

query I rowsort
SELECT ALL col2 * 60 AS col2 FROM tab2 AS cor0
----
1560
1620
2280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5035
SELECT ALL - + CAST( col0 AS SIGNED ) * - col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-5035
SELECT ALL - + CAST ( col0 AS INTEGER ) * - col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-5036
SELECT DISTINCT + ( ( + col2 ) ) DIV + ( col0 * + col2 ) FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5036
SELECT DISTINCT + ( ( + col2 ) ) / + ( col0 * + col2 ) FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 24 col2 FROM tab2, tab2 AS cor0
----
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 50 col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
-50

query I rowsort
SELECT DISTINCT - tab2.col2 + + tab2.col0 * - col0 AS col0 FROM tab2
----
-6110
-6279
-76

query I rowsort
SELECT ALL - col0 * tab0.col1 + col1 * + col2 AS col2 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT DISTINCT ( 81 ) AS col2 FROM tab1, tab2 AS cor0
----
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5042
SELECT ALL col0 DIV - col1 + col2 AS col2 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-5042
SELECT ALL col0 / - col1 + col2 AS col2 FROM tab1
----
51
54
90

query I rowsort
SELECT - + cor0.col2 * + 68 - - col2 AS col1 FROM tab0 AS cor0
----
-2211
-5494
-67

query I rowsort
SELECT ALL - + col1 - 98 FROM tab0 cor0
----
-184
-189
-195

query I rowsort
SELECT - tab1.col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT + - col0 - col2 * - col2 AS col0 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT DISTINCT - col2 + + 23 FROM tab1 AS cor0
----
-31
-34
-73

query I rowsort
SELECT DISTINCT - + 14 * - col1 AS col2 FROM tab1 AS cor0
----
140
182
364

onlyif mysql # use DIV operator for integer division
query I rowsort label-5049
SELECT ALL - col2 DIV - col1 + col2 AS col0 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-5049
SELECT ALL - col2 / - col1 + col2 AS col0 FROM tab2 AS cor0
----
26
27
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * - col0 + - col1 + col0 col2 FROM tab1 AS cor0
----
139
3702
7747

query I rowsort
SELECT + 94 * col0 * + col2 FROM tab2 AS cor0
----
17766
190632
282188

query I rowsort
SELECT col2 * 59 AS col1 FROM tab0 AS cor0
----
1947
4838
59

query I rowsort
SELECT ALL + col2 * 41 - + col1 AS col0 FROM tab2 AS cor0
----
1007
1076
1541

query I rowsort
SELECT col0 + 42 FROM tab0 AS cor0
----
131
66
77

query I rowsort
SELECT ALL col0 + col2 * + col2 AS col2 FROM tab1
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-5056
SELECT ALL - col1 DIV + col0 + col1 FROM tab0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-5056
SELECT ALL - col1 / + col0 + col1 FROM tab0
----
83
90
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5057
SELECT - tab1.col0 DIV + 3 + - col2 AS col1 FROM tab1
----
-122
-55
-78

skipif mysql # not compatible
query I rowsort label-5057
SELECT - tab1.col0 / + 3 + - col2 AS col1 FROM tab1
----
-122
-55
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5058
SELECT - CAST( - col0 AS SIGNED ) * col1 + + col2 FROM tab1 cor0
----
1136
132
697

skipif mysql # not compatible
query I rowsort label-5058
SELECT - CAST ( - col0 AS INTEGER ) * col1 + + col2 FROM tab1 cor0
----
1136
132
697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5059
SELECT + 33 + - col1 * CAST( - col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
130
2871
7495

skipif mysql # not compatible
query I rowsort label-5059
SELECT + 33 + - col1 * CAST ( - col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
130
2871
7495

query I rowsort
SELECT ALL - 77 * col2 + 9 FROM tab2 AS cor0
----
-1993
-2070
-2917

query I rowsort
SELECT DISTINCT + + 22 AS col2 FROM tab1 AS cor0
----
22

query I rowsort
SELECT DISTINCT - 7 + cor0.col1 AS col0 FROM tab0 cor0
----
79
84
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * col0 col2 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL - col2 * + col0 * col2 + + 72 AS col2 FROM tab2 AS cor0
----
-114004
-5031
-52656

query I rowsort
SELECT DISTINCT - + ( + col0 ) - + col1 * + col2 AS col1 FROM tab2 AS cor0
----
-1612
-725
-844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + col2 * - 68 col0 FROM tab2 cor0
----
-1843
-1846
-2663

query I rowsort
SELECT DISTINCT + + col0 + cor0.col1 - - col2 FROM tab0 cor0
----
133
143
262

onlyif mysql # use DIV operator for integer division
query I rowsort label-5068
SELECT ALL - - col0 + + col2 DIV col1 AS col2 FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-5068
SELECT ALL - - col0 + + col2 / col1 AS col2 FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT ALL + - col0 * cor0.col2 + 2 * col1 AS col1 FROM tab2 AS cor0
----
-127
-1910
-2968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - col1 col0 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT - - col2 * + 46 * - col0 FROM tab0 AS cor0
----
-1610
-335708
-36432

query I rowsort
SELECT cor0.col1 + + col2 * + col2 AS col1 FROM tab0 AS cor0
----
1175
6815
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5073
SELECT - col1 * - CAST( col1 AS SIGNED ) - - col1 AS col2 FROM tab1 AS cor0
----
110
182
702

skipif mysql # not compatible
query I rowsort label-5073
SELECT - col1 * - CAST ( col1 AS INTEGER ) - - col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT - + col2 + + col2 * - col1 FROM tab2 AS cor0
----
-1560
-684
-864

onlyif mysql # use DIV operator for integer division
query I rowsort label-5075
SELECT + + col1 + 10 DIV col0 AS col2 FROM tab1 AS cor0
----
10
13
29

skipif mysql # not compatible
query I rowsort label-5075
SELECT + + col1 + 10 / col0 AS col2 FROM tab1 AS cor0
----
10
13
29

query I rowsort
SELECT + ( - tab1.col1 ) FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT + col0 * 47 AS col0 FROM tab0 AS cor0
----
1128
1645
4183

onlyif mysql # use DIV operator for integer division
query I rowsort label-5078
SELECT ALL cor0.col2 DIV + 16 FROM tab0, tab1 AS cor0
----
9 values hashing to 60bc15e591a821db8d6b181033144514

skipif mysql # not compatible
query I rowsort label-5078
SELECT ALL cor0.col2 / + 16 FROM tab0, tab1 AS cor0
----
9 values hashing to 60bc15e591a821db8d6b181033144514

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5079
SELECT - - ( col2 ) + col0 + - CAST( cor0.col0 + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-5079
SELECT - - ( col2 ) + col0 + - CAST ( cor0.col0 + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL col2 * + tab1.col1 * + col0 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT + 37 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT + 86 + col2 FROM tab2 AS cor0
----
112
113
124

query I rowsort
SELECT ALL 98 * tab2.col1 FROM tab2
----
1666
3038
5782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 * + 58 col1 FROM tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT DISTINCT + - 42 * 28 AS col1 FROM tab2 AS cor0
----
-1176

query I rowsort
SELECT - 21 FROM tab2, tab0 AS cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

onlyif mysql # use DIV operator for integer division
query I rowsort label-5087
SELECT ALL - - 8 DIV + col0 FROM tab1 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5087
SELECT ALL - - 8 / + col0 FROM tab1 AS cor0
----
0
0
2

query I rowsort
SELECT + 25 FROM tab0, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5089
SELECT DISTINCT + CAST( - 93 AS SIGNED ) FROM tab2 AS cor0
----
-93

skipif mysql # not compatible
query I rowsort label-5089
SELECT DISTINCT + CAST ( - 93 AS INTEGER ) FROM tab2 AS cor0
----
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5090
SELECT ALL 71 * - col2 DIV col2 + + 82 FROM tab1 AS cor0
----
11
11
11

skipif mysql # not compatible
query I rowsort label-5090
SELECT ALL 71 * - col2 / col2 + + 82 FROM tab1 AS cor0
----
11
11
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-5091
SELECT ALL - 82 DIV - cor0.col1 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8a9b55ac3cd2c8021c4ebaa64b4d7df4

skipif mysql # not compatible
query I rowsort label-5091
SELECT ALL - 82 / - cor0.col1 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8a9b55ac3cd2c8021c4ebaa64b4d7df4

query I rowsort
SELECT ALL col0 - - ( - col0 ) * + col1 * + col2 FROM tab2
----
-119574
-50955
-5852

query I rowsort
SELECT DISTINCT 34 AS col1 FROM tab1, tab2 AS cor0
----
34

query I rowsort
SELECT ALL + ( tab2.col2 ) + - col2 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL 51 * col0 + col2 FROM tab0
----
1257
1786
4621

query I rowsort
SELECT 6 + - cor0.col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to c9ffbe7fb19cb48e697a12ed33ff1581

query I rowsort
SELECT 57 * - 69 FROM tab1 AS cor0
----
-3933
-3933
-3933

query I rowsort
SELECT DISTINCT 30 AS col1 FROM tab0, tab1 AS cor0
----
30

query I rowsort
SELECT - cor1.col0 FROM tab2, tab0, tab0 AS cor0, tab1 AS cor1
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT DISTINCT 68 AS col0 FROM tab0, tab1, tab2 AS cor0
----
68

query I rowsort
SELECT ALL + ( col2 ) * 17 * col2 FROM tab0
----
114308
17
18513

query I rowsort
SELECT ALL 37 * col0 FROM tab1
----
111
2368
2960

query I rowsort
SELECT 11 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1523
-635
-826

onlyif mysql # use DIV operator for integer division
query I rowsort label-5104
SELECT + col2 + 39 DIV - col0 FROM tab1 AS cor0
----
41
57
96

skipif mysql # not compatible
query I rowsort label-5104
SELECT + col2 + 39 / - col0 FROM tab1 AS cor0
----
41
57
96

query I rowsort
SELECT + col2 + + 53 * + col1 FROM tab1 AS cor0
----
1432
587
785

query I rowsort
SELECT DISTINCT + + col2 * 83 AS col2 FROM tab0 AS cor0
----
2739
6806
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5107
SELECT ALL - - col0 + CAST( - col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5107
SELECT ALL - - col0 + CAST ( - col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5108
SELECT DISTINCT + col2 * - col1 + 64 DIV col2 col1 FROM tab1 AS cor0
----
-1248
-1403
-569

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5108
SELECT DISTINCT + col2 * - col1 + 64 / col2 col1 FROM tab1 AS cor0
----
-1248
-1403
-569

query I rowsort
SELECT ALL + cor0.col0 - - col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - + col1 + + col2 * - col0 AS col1 FROM tab2 AS cor0
----
-2087
-220
-3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-5111
SELECT DISTINCT - col0 DIV - ( col2 ) AS col0 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5111
SELECT DISTINCT - col0 / - ( col2 ) AS col0 FROM tab1 cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5112
SELECT DISTINCT + CAST( NULL AS SIGNED ) / cor1.col2 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5112
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / cor1.col2 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
NULL

query I rowsort
SELECT - - col2 - + 15 FROM tab1 AS cor0
----
39
42
81

query I rowsort
SELECT + cor0.col1 * - 78 + col1 AS col2 FROM tab2 AS cor0
----
-1309
-2387
-4543

query I rowsort
SELECT ALL + 17 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT + col2 + col1 * col2 + + col2 FROM tab1
----
1440
1512
684

query I rowsort
SELECT - col2 + - ( tab1.col2 ) FROM tab1
----
-108
-114
-192

query I rowsort
SELECT ALL + col2 * + ( - col0 ) AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT col0 + ( col1 * - col1 ) AS col2 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - + cor0.col2 * ( + col1 ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 18 col2 FROM tab0 cor0
----
-18
-18
-18

query I rowsort
SELECT 18 * ( + col2 ) AS col2 FROM tab1 AS cor0
----
1026
1728
972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col1 + col1 col1 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5124
SELECT DISTINCT + 33 DIV col2 FROM tab0 AS cor0
----
0
1
33

skipif mysql # not compatible
query I rowsort label-5124
SELECT DISTINCT + 33 / col2 FROM tab0 AS cor0
----
0
1
33

query I rowsort
SELECT DISTINCT + 24 AS col2 FROM tab2 AS cor0
----
24

query I rowsort
SELECT + ( col1 ) * col0 - col2 * - col2 FROM tab0 cor0
----
14823
3153
3396

onlyif mysql # use DIV operator for integer division
query I rowsort label-5127
SELECT ALL + + col2 + + col1 DIV col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5127
SELECT ALL + + col2 + + col1 / col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + col1 + 50 AS col1 FROM tab0 AS cor0
----
136
141
147

query I rowsort
SELECT DISTINCT 49 * col2 + - cor0.col1 * 74 FROM tab1 AS cor0
----
2053
3742
722

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5130
SELECT ALL + - CAST( NULL AS SIGNED ) - + 19 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5130
SELECT ALL + - CAST ( NULL AS INTEGER ) - + 19 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 15 * - col0 + - col1 FROM tab0 cor0
----
-1426
-446
-622

query I rowsort
SELECT col1 + col0 - + 52 FROM tab1
----
-23
22
41

query I rowsort
SELECT col2 * 90 + - tab2.col1 + tab2.col1 FROM tab2
----
2340
2430
3420

query I rowsort
SELECT ALL - 82 * col0 + col1 FROM tab0 AS cor0
----
-1882
-2773
-7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5135
SELECT DISTINCT + CAST( + cor0.col2 AS SIGNED ) FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5135
SELECT DISTINCT + CAST ( + cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL 74 * col2 FROM tab0 AS cor0
----
2442
6068
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5137
SELECT DISTINCT col1 * CAST( col2 AS SIGNED ) * - col2 - + 5 * ( - tab1.col0 * + ( - col2 ) ) FROM tab1
----
-158208
-50730
-76626

skipif mysql # not compatible
query I rowsort label-5137
SELECT DISTINCT col1 * CAST ( col2 AS INTEGER ) * - col2 - + 5 * ( - tab1.col0 * + ( - col2 ) ) FROM tab1
----
-158208
-50730
-76626

query I rowsort
SELECT ALL + ( col0 ) * ( col1 ) - - col2 * + 28 * + col1 FROM tab1 cor0
----
16600
35984
39390

query I rowsort
SELECT ALL cor0.col2 * cor0.col0 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5140
SELECT + 8 DIV - cor0.col0 AS col1 FROM tab1 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-5140
SELECT + 8 / - cor0.col0 AS col1 FROM tab1 AS cor0
----
-2
0
0

query I rowsort
SELECT + col1 * - col2 + col2 * - col0 * - col0 + col1 AS col2 FROM tab2 AS cor0
----
156709
236529
517

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 5 col2 FROM tab0 AS cor0
----
5
5
5

query I rowsort
SELECT DISTINCT + + col0 * - col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - col0 * 43 FROM tab0
----
-1032
-1505
-3827

query I rowsort
SELECT DISTINCT - 95 + col1 AS col1 FROM tab2 AS cor0
----
-36
-64
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5146
SELECT col2 + - col1 + CAST( 49 AS SIGNED ) * col2 FROM tab2 AS cor0
----
1241
1319
1883

skipif mysql # not compatible
query I rowsort label-5146
SELECT col2 + - col1 + CAST ( 49 AS INTEGER ) * col2 FROM tab2 AS cor0
----
1241
1319
1883

onlyif mysql # use DIV operator for integer division
query I rowsort label-5147
SELECT - 37 DIV col0 - + ( + col1 ) * tab2.col1 * + col0 FROM tab2
----
-22831
-271518
-6732

skipif mysql # not compatible
query I rowsort label-5147
SELECT - 37 / col0 - + ( + col1 ) * tab2.col1 * + col0 FROM tab2
----
-22831
-271518
-6732

query I rowsort
SELECT DISTINCT + - cor0.col0 * 25 AS col1 FROM tab0 cor0
----
-2225
-600
-875

query I rowsort
SELECT - + cor0.col1 * + 88 FROM tab0 AS cor0
----
-7568
-8008
-8536

onlyif mysql # use DIV operator for integer division
query I rowsort label-5150
SELECT ALL - col0 * 48 - col0 DIV col0 FROM tab1 cor0
----
-145
-3073
-3841

skipif mysql # not compatible
query I rowsort label-5150
SELECT ALL - col0 * 48 - col0 / col0 FROM tab1 cor0
----
-145
-3073
-3841

query I rowsort
SELECT DISTINCT - 30 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
-30

onlyif mysql # use DIV operator for integer division
query I rowsort label-5152
SELECT DISTINCT 95 * - col0 DIV - col0 AS col1 FROM tab2
----
95

skipif mysql # not compatible
query I rowsort label-5152
SELECT DISTINCT 95 * - col0 / - col0 AS col1 FROM tab2
----
95

query I rowsort
SELECT DISTINCT + col0 * 21 AS col1 FROM tab1
----
1344
1680
63

query I rowsort
SELECT DISTINCT 58 + + 28 FROM tab1 AS cor0
----
86

query I rowsort
SELECT DISTINCT 7 * - 91 * col1 FROM tab0
----
-54782
-57967
-61789

query I rowsort
SELECT 3 + 62 * col0 AS col0 FROM tab2
----
437
4839
4901

query I rowsort
SELECT ALL - 77 * - col0 FROM tab2
----
539
6006
6083

query I rowsort
SELECT - 52 + col0 FROM tab1 AS cor0
----
-49
12
28

query I rowsort
SELECT + 79 * col1 AS col1 FROM tab2
----
1343
2449
4661

query I rowsort
SELECT - - col0 + col0 * - col2 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT - 80 AS col2 FROM tab1 cor0
----
-80
-80
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5162
SELECT col2 DIV - col1 + 45 FROM tab1 AS cor0
----
38
40
43

skipif mysql # not compatible
query I rowsort label-5162
SELECT col2 / - col1 + 45 FROM tab1 AS cor0
----
38
40
43

query I rowsort
SELECT ALL + + 55 + col2 + - 33 AS col1 FROM tab1 cor0
----
118
76
79

query I rowsort
SELECT - col1 + + col0 + + ( col0 ) FROM tab2 AS cor0
----
-17
141
97

query I rowsort
SELECT ALL col2 * col0 - + 43 FROM tab2 AS cor0
----
146
1985
2959

query I rowsort
SELECT ALL - + cor0.col1 + ( + 93 * + col1 ) AS col1 FROM tab0 AS cor0
----
7912
8372
8924

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5167
SELECT DISTINCT + - col2 - + CAST( NULL AS DECIMAL ) * + col0 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5167
SELECT DISTINCT + - col2 - + CAST ( NULL AS REAL ) * + col0 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col0 + - col1 * 41 FROM tab0 AS cor0
----
-3502
-3642
-3942

query I rowsort
SELECT ALL - + col2 - + col2 AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL - col0 + 68 FROM tab0 cor0
----
-21
33
44

query I rowsort
SELECT DISTINCT - col1 + - col0 * - ( col2 ) FROM tab1 AS cor0
----
136
3638
7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * + ( - col2 ) col0 FROM tab2 cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * ( - col2 ) + - 38 * - col2 col1 FROM tab0 AS cor0
----
10578
135
4092

query I rowsort
SELECT ALL - - cor0.col0 + 18 AS col1 FROM tab1 AS cor0
----
21
82
98

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( ( col0 ) AS REAL ) * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - + 58 + col2 AS col0 FROM tab2 cor0
----
-20
-31
-32

query I rowsort
SELECT + 68 + + cor0.col1 AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
27 values hashing to bca993ba9d857a7a46c1b6cf19fcd097

query I rowsort
SELECT 88 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1496
2728
5192

query I rowsort
SELECT + 18 + col1 AS col2 FROM tab0 AS cor0
----
104
109
115

query I rowsort
SELECT - 27 + 83 FROM tab0 AS cor0
----
56
56
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - col0 col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col1 + 67 FROM tab2 cor0
----
126
84
98

query I rowsort
SELECT - 37 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
-259
-2886
-2923

query I rowsort
SELECT + + col1 * - 52 FROM tab0 AS cor0
----
-4472
-4732
-5044

query I rowsort
SELECT 14 + cor0.col0 FROM tab0 AS cor0
----
103
38
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 10 * + col0 col1 FROM tab0 AS cor0
----
240
350
890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5187
SELECT DISTINCT + cor0.col1 + CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5187
SELECT DISTINCT + cor0.col1 + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

query I rowsort
SELECT + col1 + 61 * ( + col0 ) FROM tab2 AS cor0
----
458
4817
4836

onlyif mysql # use DIV operator for integer division
query I rowsort label-5189
SELECT tab1.col2 * col0 + tab1.col0 DIV + 58 + col1 FROM tab1
----
188
3659
7694

skipif mysql # not compatible
query I rowsort label-5189
SELECT tab1.col2 * col0 + tab1.col0 / + 58 + col1 FROM tab1
----
188
3659
7694

query I rowsort
SELECT col0 * col2 + - cor0.col0 AS col1 FROM tab2 cor0
----
182
1950
2923

query I rowsort
SELECT ALL 15 + + col1 FROM tab0
----
101
106
112

query I rowsort
SELECT + 55 FROM tab1, tab1 cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT + col0 + + 87 * col0 AS col2 FROM tab0 AS cor0
----
2112
3080
7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-5194
SELECT + + col0 DIV 18 FROM tab2 cor0
----
0
4
4

skipif mysql # not compatible
query I rowsort label-5194
SELECT + + col0 / 18 FROM tab2 cor0
----
0
4
4

query I rowsort
SELECT 3 * col1 AS col2 FROM tab1 cor0
----
30
39
78

query I rowsort
SELECT ALL + 32 * cor0.col1 + ( col2 * cor0.col2 ) AS col2 FROM tab1 AS cor0
----
3569
3748
9632

query I rowsort
SELECT + col2 + - col1 * + col0 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL - 83 + + col2 FROM tab1 AS cor0
----
-26
-29
13

query I rowsort
SELECT DISTINCT 76 + tab2.col2 + - tab2.col1 * - col2 FROM tab2
----
1636
760
940

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col2 ) * 94 col0 FROM tab0 AS cor0
----
-3102
-7708
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-5201
SELECT + - 8 DIV - col2 + + col1 DIV + 69 + - col2 * - col2 AS col1 FROM tab0 cor0
----
10
1090
6725

skipif mysql # not compatible
query I rowsort label-5201
SELECT + - 8 / - col2 + + col1 / + 69 + - col2 * - col2 AS col1 FROM tab0 cor0
----
10
1090
6725

query I rowsort
SELECT ALL - + col2 * + col1 * - col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + col2 - - col1 AS col0 FROM tab0 cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5204
SELECT DISTINCT + + col1 - col0 * col0 DIV - col2 AS col0 FROM tab1 AS cor0
----
26
79
81

skipif mysql # not compatible
query I rowsort label-5204
SELECT DISTINCT + + col1 - col0 * col0 / - col2 AS col0 FROM tab1 AS cor0
----
26
79
81

query I rowsort
SELECT DISTINCT + ( - col2 ) - 90 FROM tab0 AS cor0
----
-123
-172
-91

query I rowsort
SELECT ALL - cor0.col1 + - col1 FROM tab0 cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-5207
SELECT ALL 7 DIV - 65 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-5207
SELECT ALL 7 / - 65 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT cor0.col1 * - cor0.col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * 3 + - 16 + - cor0.col1 col0 FROM tab1 AS cor0
----
-120
-56
-68

query I rowsort
SELECT - cor0.col0 + col2 * col2 AS col1 FROM tab1 cor0
----
2913
3185
9136

query I rowsort
SELECT DISTINCT - col0 + + col2 AS col0 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + col2 * 60 + col2 FROM tab1 AS cor0
----
3294
3477
5856

query I rowsort
SELECT DISTINCT 79 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5214
SELECT 68 + col2 * - CAST( NULL AS SIGNED ) + + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5214
SELECT 68 + col2 * - CAST ( NULL AS INTEGER ) + + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * col1 * + col0 + cor0.col2 FROM tab2 cor0
----
119678
51072
5886

query I rowsort
SELECT - 69 * ( - col1 ) FROM tab0 cor0
----
5934
6279
6693

query I rowsort
SELECT ALL - + 44 * col2 FROM tab1 AS cor0
----
-2376
-2508
-4224

query I rowsort
SELECT 71 * 80 + cor1.col0 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to eea85a57a989a23c70178d52e68a2427

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 6 ) * + col1 + - 19 col1 FROM tab0 cor0
----
-535
-565
-601

query I rowsort
SELECT DISTINCT - cor0.col0 * 76 * + col0 AS col0 FROM tab0 AS cor0
----
-43776
-601996
-93100

query I rowsort
SELECT ALL - - 83 AS col2 FROM tab0 AS cor0
----
83
83
83

query I rowsort
SELECT - 74 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5a567947d14593676e3825756f8e6130

query I rowsort
SELECT ALL + 95 * tab0.col1 FROM tab0
----
8170
8645
9215

query I rowsort
SELECT ALL ( + col1 ) * - col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT + - cor0.col2 AS col1 FROM tab1, tab2 AS cor0, tab1 cor1, tab0, tab2 AS cor2
----
243 values hashing to b98cc07e6d63e3c0583ed19f9e9ad2be

query I rowsort
SELECT + 25 + + col0 AS col0 FROM tab1
----
105
28
89

query I rowsort
SELECT + col1 * col0 - - col0 * + tab0.col0 AS col0 FROM tab0
----
16020
2640
4620

query I rowsort
SELECT col1 * + ( col2 ) * - col0 + - col0 AS col0 FROM tab2
----
-119730
-51113
-5866

query I rowsort
SELECT 70 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT DISTINCT cor0.col0 + col2 * ( col2 ) FROM tab2 AS cor0
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-5231
SELECT ALL - cor0.col0 + + col1 DIV ( - 77 + col2 * + col2 ) FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5231
SELECT ALL - cor0.col0 + + col1 / ( - 77 + col2 * + col2 ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT 14 * - col2 * - col0 FROM tab2
----
2646
28392
42028

onlyif mysql # use DIV operator for integer division
query I rowsort label-5233
SELECT ALL + tab1.col2 DIV + col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5233
SELECT ALL + tab1.col2 / + col0 FROM tab1
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 65 * col0 col0 FROM tab2 AS cor0
----
455
5070
5135

query I rowsort
SELECT 17 AS col0 FROM tab0 cor0
----
17
17
17

query I rowsort
SELECT ALL 64 AS col0 FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5237
SELECT ALL col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5237
SELECT ALL col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ( + cor0.col1 ) AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 * + ( + tab1.col2 + col2 ) col1 FROM tab1
----
199680
72960
8424

query I rowsort
SELECT tab2.col0 * ( + col1 ) FROM tab2
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col1 col1 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 + CAST ( + ( col2 ) AS REAL ) * col0 col1 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT tab0.col1 * - tab0.col2 + + col2 * + col2 * col1 FROM tab0
----
0
604422
90816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5244
SELECT ALL ( - col2 ) * cor0.col2 + - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5244
SELECT ALL ( - col2 ) * cor0.col2 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 71 + - col1 FROM tab1 AS cor0
----
-81
-84
-97

query I rowsort
SELECT ALL ( - col2 ) + - col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + ( col0 ) + - col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - col2 + 35 FROM tab1 AS cor0
----
-19
-22
-61

query I rowsort
SELECT DISTINCT ( - 95 ) * - col0 AS col0 FROM tab2 AS cor0
----
665
7410
7505

query I rowsort
SELECT ALL - col1 * - col0 - + cor0.col2 AS col2 FROM tab2 cor0
----
1305
190
4576

query I rowsort
SELECT ALL col0 + col2 * col0 * - col2 AS col1 FROM tab1 AS cor0
----
-207872
-737200
-8745

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5252
SELECT DISTINCT ( - 39 ) * col1 + CAST( NULL AS SIGNED ) + cor0.col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5252
SELECT DISTINCT ( - 39 ) * col1 + CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5253
SELECT ALL - + col1 DIV 12 FROM tab0 AS cor0
----
-7
-7
-8

skipif mysql # not compatible
query I rowsort label-5253
SELECT ALL - + col1 / 12 FROM tab0 AS cor0
----
-7
-7
-8

query I rowsort
SELECT ALL + cor0.col0 + + col2 + col1 AS col2 FROM tab2 AS cor0
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5255
SELECT - - col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5255
SELECT - - col1 / - col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL cor0.col2 * cor0.col0 + - col0 + 50 AS col2 FROM tab1 AS cor0
----
209
3634
7650

query I rowsort
SELECT - - cor0.col2 * 82 FROM tab2 AS cor0
----
2132
2214
3116

query I rowsort
SELECT ALL - col0 + + 18 FROM tab2 cor0
----
-60
-61
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5259
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + col2 * col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5259
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + col2 * col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col2 + - 5 FROM tab2 AS cor0
----
21
22
33

query I rowsort
SELECT col1 * - ( ( - col2 ) ) FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + - col2 * col2 * cor0.col2 FROM tab0 AS cor0
----
-1
-35937
-551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-5263
SELECT col0 + - tab0.col0 DIV + col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5263
SELECT col0 + - tab0.col0 / + col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 71 * + 20 col0 FROM tab0 AS cor0
----
1420
1420
1420

query I rowsort
SELECT 62 * 97 FROM tab1 AS cor0
----
6014
6014
6014

query I rowsort
SELECT DISTINCT - 86 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-86

query I rowsort
SELECT ALL - 88 FROM tab1, tab2 AS cor0
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

query I rowsort
SELECT DISTINCT ( col1 ) * + col1 * col1 + col1 FROM tab2
----
205438
29822
4930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col2 ) + - ( col2 ) col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT - 17 * col0 * - col1 + cor0.col1 FROM tab0 cor0
----
137774
35174
57812

query I rowsort
SELECT + 30 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT ALL 48 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5273
SELECT col0 DIV ( tab1.col2 * col2 ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5273
SELECT col0 / ( tab1.col2 * col2 ) FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col1 + col2 + col2 AS col0 FROM tab1
----
104
179
82

query I rowsort
SELECT DISTINCT cor1.col0 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
24
35
89

query I rowsort
SELECT 81 + + col2 AS col1 FROM tab0
----
114
163
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 68 * col1 col2 FROM tab0 cor0
----
5848
6188
6596

query I rowsort
SELECT - - ( - col2 ) + col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5279
SELECT DISTINCT + col0 DIV - cor0.col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-5279
SELECT DISTINCT + col0 / - cor0.col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT - col1 + col2 * col0 * col0 FROM tab0 AS cor0
----
1128
18922
649431

query I rowsort
SELECT - col0 * col0 + 59 FROM tab0 cor0
----
-1166
-517
-7862

query I rowsort
SELECT col1 * + col2 * 16 AS col0 FROM tab0
----
119392
1552
45408

query I rowsort
SELECT DISTINCT - col1 - tab1.col2 AS col1 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT + col0 * + col1 * + col1 AS col2 FROM tab0
----
177504
329315
737009

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2, tab1 AS cor3
----
3645 values hashing to 8d4d13f65f86e1b26b6004a6bdc662b3

query I rowsort
SELECT - col2 + 51 FROM tab2 AS cor0
----
13
24
25

query I rowsort
SELECT col2 + - 63 AS col1 FROM tab2 AS cor0
----
-25
-36
-37

query I rowsort
SELECT col2 + cor0.col1 * col0 * + col0 + + col1 AS col2 FROM tab0 AS cor0
----
118923
49655
720984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * ( - 29 ) * col0 + 50 + ( + col0 ) col1 FROM tab0 AS cor0
----
-211503
-22894
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-5290
SELECT col2 DIV - col0 + col0 * - col2 AS col1 FROM tab2 cor0
----
-192
-2028
-3002

skipif mysql # not compatible
query I rowsort label-5290
SELECT col2 / - col0 + col0 * - col2 AS col1 FROM tab2 cor0
----
-192
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5291
SELECT col2 * ( col1 ) + col2 + - CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
133
2895
7633

skipif mysql # not compatible
query I rowsort label-5291
SELECT col2 * ( col1 ) + col2 + - CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
133
2895
7633

query I rowsort
SELECT DISTINCT + cor0.col0 * ( - col1 ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + ( col0 ) * + col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5294
SELECT - CAST( 9 AS SIGNED ) * - col0 FROM tab2
----
63
702
711

skipif mysql # not compatible
query I rowsort label-5294
SELECT - CAST ( 9 AS INTEGER ) * - col0 FROM tab2
----
63
702
711

query I rowsort
SELECT - ( 71 ) * cor0.col2 * 8 FROM tab1 AS cor0
----
-30672
-32376
-54528

query I rowsort
SELECT - 70 * + col0 FROM tab1 cor0
----
-210
-4480
-5600

query I rowsort
SELECT + 10 * col2 AS col2 FROM tab1
----
540
570
960

query I rowsort
SELECT - + cor0.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5299
SELECT CAST( NULL AS DECIMAL ) FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5299
SELECT CAST ( NULL AS REAL ) FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - col1 * col0 + col0 * - col1 AS col0 FROM tab1
----
-1280
-156
-2080

query I rowsort
SELECT col0 * col2 FROM tab1 WHERE NOT NULL > - col0
----

query I rowsort
SELECT col0 + col0 * col0 + - col1 FROM tab0
----
1163
514
7919

query I rowsort
SELECT DISTINCT + col0 * + col1 + col1 AS col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT col0 * + col1 FROM tab1 WHERE - col0 NOT IN ( col0 )
----
1040
640
78

query I rowsort
SELECT - col0 + + col1 * + col1 AS col0 FROM tab2
----
210
3403
954

query I rowsort
SELECT tab1.col1 FROM tab1 WHERE NULL BETWEEN col1 AND NULL
----

query I rowsort
SELECT col1 + col1 - - col2 AS col0 FROM tab0
----
195
205
264

query I rowsort
SELECT ALL + col2 * + col1 * col0 + + col0 AS col1 FROM tab0
----
3430
664207
68136

query III rowsort
SELECT ALL * FROM tab2 WHERE tab2.col0 < col1 / + col0 + - col0
----

query I rowsort
SELECT ALL col0 + col1 * col2 AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT - + col0 + + cor0.col2 FROM tab0 cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5312
SELECT DISTINCT - - col1 / - col0 + - CAST( NULL AS DECIMAL ) * + ( col0 ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5312
SELECT DISTINCT - - col1 / - col0 + - CAST ( NULL AS REAL ) * + ( col0 ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + col0 * cor0.col0 - - ( + col2 ) * cor0.col1 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT DISTINCT col2 + - col1 * + tab1.col0 FROM tab1
----
-24
-583
-944

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col1 = NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5316
SELECT ALL col2 DIV col0 + + ( col1 * + col2 ) + cor0.col1 DIV col1 AS col2 FROM tab1 AS cor0
----
1250
1423
571

skipif mysql # not compatible
query I rowsort label-5316
SELECT ALL col2 / col0 + + ( col1 * + col2 ) + cor0.col1 / col1 AS col2 FROM tab1 AS cor0
----
1250
1423
571

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col2 IN ( - col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-5318
SELECT - col1 DIV - col1 AS col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5318
SELECT - col1 / - col1 AS col1 FROM tab2 AS cor0
----
1
1
1

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND + col1 + col0
----

query I rowsort
SELECT col0 AS col0 FROM tab1 cor0 WHERE ( + col2 + - cor0.col1 + col0 ) NOT IN ( + col0 )
----
3
64
80

query I rowsort
SELECT - col0 * - col0 + - col2 AS col2 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT + col0 * col1 * + cor0.col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL col2 FROM tab1 WHERE ( col0 ) NOT IN ( col0 )
----

query I rowsort
SELECT col2 - + col0 AS col0 FROM tab2
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + tab1.col1 col1 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL - col1 - col2 * - col2 AS col2 FROM tab1
----
2890
3239
9203

onlyif mysql # use DIV operator for integer division
query I rowsort label-5327
SELECT + tab1.col2 DIV - col1 AS col2 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-5327
SELECT + tab1.col2 / - col1 AS col2 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT col1 - col1 * tab2.col1 * col1 AS col0 FROM tab2
----
-205320
-29760
-4896

query I rowsort
SELECT + col1 + + col1 * - col0 AS col0 FROM tab0
----
-1978
-3298
-8008

query III rowsort
SELECT ALL * FROM tab1 WHERE col1 + + col2 < ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 19 * + col1 col1 FROM tab2 AS cor0
----
1121
323
589

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5332
SELECT + + CAST( NULL AS SIGNED ) + col2 * - col1 * 1 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5332
SELECT + + CAST ( NULL AS INTEGER ) + col2 * - col1 * 1 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * col2 * - col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT - col0 + col1 * - 73 AS col1 FROM tab2
----
-1320
-2270
-4385

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to 4406ccc71f02ae9c1e947ffcd89b0db7

query I rowsort
SELECT DISTINCT - tab1.col0 + cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to f8c8144a1e750f938e34a2795af6b4c2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5337
SELECT DISTINCT + 59 DIV tab0.col2 FROM tab0
----
0
1
59

skipif mysql # not compatible
query I rowsort label-5337
SELECT DISTINCT + 59 / tab0.col2 FROM tab0
----
0
1
59

query I rowsort
SELECT DISTINCT ( - ( tab2.col0 ) + col0 ) * col0 AS col1 FROM tab2
----
0

query I rowsort
SELECT DISTINCT - col1 * ( + col1 ) AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + 7 * cor0.col1 FROM tab1 AS cor0
----
182
70
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 92 col1 FROM tab0 AS cor0
----
-92

query I rowsort
SELECT + - ( col2 ) + cor0.col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + - ( - 45 ) * col0 FROM tab1 AS cor0
----
135
2880
3600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5344
SELECT ALL CAST( col2 AS SIGNED ) * + col2 FROM tab0 cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-5344
SELECT ALL CAST ( col2 AS INTEGER ) * + col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 10 AS col2 FROM tab2 AS cor0
----
10

query I rowsort
SELECT col0 + col0 - - col2 * - col2 AS col1 FROM tab2
----
-1286
-520
-715

query I rowsort
SELECT 61 AS col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT DISTINCT - + col0 + + col1 * - 3 FROM tab1 AS cor0
----
-119
-81
-94

query I rowsort
SELECT ALL col0 + 86 FROM tab2 cor0
----
164
165
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5350
SELECT DISTINCT + col1 DIV + col2 + + col1 FROM tab0 AS cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-5350
SELECT DISTINCT + col1 / + col2 + + col1 FROM tab0 AS cor0
----
194
88
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 29 col2 FROM tab0
----
-29

onlyif mysql # use DIV operator for integer division
query I rowsort label-5352
SELECT ALL - col2 + col1 DIV + col2 AS col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5352
SELECT ALL - col2 + col1 / + col2 AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL + tab1.col1 + + col2 * + col2 - - col2 * col0 AS col2 FROM tab1
----
16909
3104
6907

query I rowsort
SELECT DISTINCT col1 + + tab0.col0 - col1 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT 41 - - col1 FROM tab1
----
51
54
67

query I rowsort
SELECT DISTINCT col2 + 6 * + col1 FROM tab0
----
549
583
628

query I rowsort
SELECT DISTINCT - col0 * 18 FROM tab2 AS cor0
----
-126
-1404
-1422

query I rowsort
SELECT - col0 * ( 19 + col2 ) AS col2 FROM tab0 AS cor0
----
-1248
-700
-8989

query I rowsort
SELECT ALL + + col2 + col1 * col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT col0 + + 3 AS col1 FROM tab2 AS cor0
----
10
81
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5361
SELECT + + cor0.col0 * CAST( cor0.col1 AS SIGNED ) + + cor0.col0 col1 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5361
SELECT + + cor0.col0 * CAST ( cor0.col1 AS INTEGER ) + + cor0.col0 col1 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + ( - 8 ) * + col0 + col0 col1 FROM tab1 AS cor0
----
5184
627
8400

query I rowsort
SELECT col0 + + cor0.col1 * + ( col0 * cor0.col0 ) FROM tab1 AS cor0
----
237
41024
83280

query I rowsort
SELECT DISTINCT - cor0.col2 * 29 AS col2 FROM tab0 AS cor0
----
-2378
-29
-957

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5365
SELECT + col0 * CAST( col1 * - cor0.col2 AS SIGNED ) FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif mysql # not compatible
query I rowsort label-5365
SELECT + col0 * CAST ( col1 * - cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-5366
SELECT + col1 * col2 + + col0 DIV col0 + col1 AS col2 FROM tab2 AS cor0
----
1594
664
869

skipif mysql # not compatible
query I rowsort label-5366
SELECT + col1 * col2 + + col0 / col0 + col1 AS col2 FROM tab2 AS cor0
----
1594
664
869

query I rowsort
SELECT - - col0 + + ( col2 * col1 ) FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + col0 * ( + col1 ) * col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT - col0 * - tab0.col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - ( + col0 ) * - col1 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 13 * + col1 col1 FROM tab1
----
130
169
338

query I rowsort
SELECT - 73 * cor0.col0 FROM tab0 AS cor0
----
-1752
-2555
-6497

query I rowsort
SELECT + 13 * col0 FROM tab2 AS cor0
----
1014
1027
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5374
SELECT - CAST( col0 AS SIGNED ) + tab1.col2 * col0 FROM tab1
----
159
3584
7600

skipif mysql # not compatible
query I rowsort label-5374
SELECT - CAST ( col0 AS INTEGER ) + tab1.col2 * col0 FROM tab1
----
159
3584
7600

query I rowsort
SELECT 26 * - 82 + tab0.col2 AS col1 FROM tab0
----
-2050
-2099
-2131

query I rowsort
SELECT tab0.col2 AS col2 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT tab0.col0 + 64 FROM tab0
----
153
88
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5378
SELECT DISTINCT col1 + CAST( - col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
2
62

skipif mysql # not compatible
query I rowsort label-5378
SELECT DISTINCT col1 + CAST ( - col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5379
SELECT col0 - - CAST( col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-5379
SELECT col0 - - CAST ( col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col0 + - col1 * + cor0.col2 col1 FROM tab2 AS cor0
----
-1482
-605
-857

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5381
SELECT - col2 * + CAST( 83 AS SIGNED ) + col2 * - col1 FROM tab0 AS cor0
----
-14268
-180
-5577

skipif mysql # not compatible
query I rowsort label-5381
SELECT - col2 * + CAST ( 83 AS INTEGER ) + col2 * - col1 FROM tab0 AS cor0
----
-14268
-180
-5577

query I rowsort
SELECT DISTINCT cor0.col1 * + 70 * col2 FROM tab0 AS cor0
----
198660
522340
6790

query I rowsort
SELECT + col2 - col2 * ( col1 ) AS col1 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT + tab2.col1 * col2 + + tab2.col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT col1 * col1 + - 2 * - col2 * - tab0.col0 FROM tab0
----
-6315
5812
9339

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 + - col1 col2 FROM tab1 cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT - tab2.col0 + 14 FROM tab2
----
-64
-65
7

query I rowsort
SELECT + col2 + col1 * + col1 + + col2 AS col0 FROM tab1
----
214
361
784

query I rowsort
SELECT col2 * - col0 * 42 + + col0 - col2 AS col0 FROM tab2 AS cor0
----
-126043
-7958
-85124

query I rowsort
SELECT - + col0 + + ( col2 ) * + col2 * col0 - + col0 AS col1 FROM tab0 AS cor0
----
-35
26088
598258

onlyif mysql # use DIV operator for integer division
query I rowsort label-5391
SELECT - + col0 - + col0 DIV col2 AS col0 FROM tab0 AS cor0
----
-24
-70
-90

skipif mysql # not compatible
query I rowsort label-5391
SELECT - + col0 - + col0 / col2 AS col0 FROM tab0 AS cor0
----
-24
-70
-90

query I rowsort
SELECT ALL + col2 + col1 * tab2.col1 AS col1 FROM tab2
----
327
3507
988

query I rowsort
SELECT + cor0.col2 + - col2 * col1 - + cor0.col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col0 + + col1 col1 FROM tab2 AS cor0
----
-18
-6025
-6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col0 col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + col1 FROM tab2 WHERE + col1 = col1 / col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5397
SELECT + col2 * col2 DIV + col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5397
SELECT + col2 * col2 / + col2 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - - col2 * cor0.col2 + col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT - cor0.col0 * - cor0.col1 + - col2 * - col2 - col1 AS col2 FROM tab2 AS cor0
----
2770
5219
915

query I rowsort
SELECT ALL col2 * col0 - - tab2.col0 AS col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT DISTINCT - col2 * + col2 + - col0 AS col0 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT ALL + 39 + - col1 AS col0 FROM tab2 cor0
----
-20
22
8

query I rowsort
SELECT DISTINCT - 2 AS col2 FROM tab2
----
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col0 col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col2 * - cor0.col2 AS col2 FROM tab2 cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5406
SELECT DISTINCT col1 * - 60 + ( col1 * + CAST( NULL AS SIGNED ) ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5406
SELECT DISTINCT col1 * - 60 + ( col1 * + CAST ( NULL AS INTEGER ) ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col0 + - 47 FROM tab2 AS cor0
----
-125
-126
-54

query I rowsort
SELECT ALL + col1 * + ( + cor0.col0 + col2 ) * 93 FROM tab0 AS cor0
----
1447173
324756
455886

query I rowsort
SELECT DISTINCT - col2 + - 27 + - col0 FROM tab0 AS cor0
----
-198
-63
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * tab1.col0 + - col2 col1 FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT DISTINCT + col1 + + col1 * - 25 AS col0 FROM tab1
----
-240
-312
-624

query I rowsort
SELECT + tab0.col2 * - col1 + + ( col1 + col1 ) * tab0.col1 AS col1 FROM tab0
----
11954
18721
9100

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab1, tab0 cor1, tab0 AS cor2
----
972 values hashing to 8420206d6932c454f05a38de634b3cb5

query I rowsort
SELECT 21 - - 71 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT ALL + + col1 * ( - cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - col1 + col0 + col0 * col0 FROM tab1 AS cor0
----
-14
4150
6467

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 col1 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT col2 * 74 AS col1 FROM tab0 AS cor0
----
2442
6068
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-5419
SELECT DISTINCT + - col0 DIV ( + ( + col0 ) ) AS col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5419
SELECT DISTINCT + - col0 / ( + ( + col0 ) ) AS col2 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT ALL + col1 - ( + col0 ) FROM tab0
----
2
62
62

query I rowsort
SELECT ALL col2 - + ( - col0 ) * ( 77 ) AS col2 FROM tab2
----
566
6032
6121

query I rowsort
SELECT DISTINCT - 62 * + col2 - - col2 * 1 * + 20 FROM tab0
----
-1386
-3444
-42

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0 CROSS JOIN tab0, tab1 AS cor1
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * col0 + cor0.col0 col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + ( tab2.col0 * + col1 ) + 26 + 35 * + tab2.col1 FROM tab2
----
1328
1964
6693

query I rowsort
SELECT col1 * col2 + col2 * + 22 * - col2 FROM tab0 AS cor0
----
-140466
-21120
75

query I rowsort
SELECT DISTINCT - 8 * col1 + col1 * - col2 FROM tab0 cor0
----
-3526
-8190
-873

query I rowsort
SELECT - 3 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 65b7e16aaa7821ace3a45a9846ffa166

query I rowsort
SELECT + 41 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5430
SELECT DISTINCT - + cor0.col2 DIV - col0 AS col2 FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-5430
SELECT DISTINCT - + cor0.col2 / - col0 AS col2 FROM tab2 AS cor0
----
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5431
SELECT + - 97 + col2 DIV 74 + cor0.col2 AS col0 FROM tab0 AS cor0
----
-14
-64
-96

skipif mysql # not compatible
query I rowsort label-5431
SELECT + - 97 + col2 / 74 + cor0.col2 AS col0 FROM tab0 AS cor0
----
-14
-64
-96

query I rowsort
SELECT ALL + - col2 * + col2 AS col1 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT + col2 * - col1 + - col0 AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT - col1 * - col2 + + ( - col1 ) AS col1 FROM tab0 AS cor0
----
0
2752
7371

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 19 col2 FROM tab2 AS cor0
----
-19
-19
-19

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
3645 values hashing to f7d7f8e55c3be4391aa225222961d676

query I rowsort
SELECT DISTINCT - + col2 * - col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT ALL 14 AS col1 FROM tab2 cor0
----
14
14
14

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5439
SELECT ALL CAST( NULL AS DECIMAL ) * + cor0.col0 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5439
SELECT ALL CAST ( NULL AS REAL ) * + cor0.col0 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT ( tab1.col2 ) * + 17 FROM tab1
----
1632
918
969

query I rowsort
SELECT + + ( col0 ) * ( - 47 ) + col0 FROM tab0 AS cor0
----
-1104
-1610
-4094

onlyif mysql # use DIV operator for integer division
query I rowsort label-5442
SELECT 35 DIV cor0.col1 + col2 FROM tab2 AS cor0
----
26
28
40

skipif mysql # not compatible
query I rowsort label-5442
SELECT 35 / cor0.col1 + col2 FROM tab2 AS cor0
----
26
28
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + cor0.col0 ) * col0 + + cor0.col0 col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL 21 + cor0.col0 + col0 FROM tab0 AS cor0
----
199
69
91

query I rowsort
SELECT + - col2 - + cor0.col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5446
SELECT + col2 * col0 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5446
SELECT + col2 * col0 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 62 * - col1 + col2 AS col1 FROM tab2 AS cor0
----
1092
1949
3684

onlyif mysql # use DIV operator for integer division
query I rowsort label-5448
SELECT + col1 + col1 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-5448
SELECT + col1 + col1 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
85
90
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5449
SELECT DISTINCT - col2 * col0 + col2 DIV - ( + col0 * col2 ) FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-5449
SELECT DISTINCT - col2 * col0 + col2 / - ( + col0 * col2 ) FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col0 col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + 16 * col0 + 66 FROM tab2 AS cor0
----
1314
1330
178

query I rowsort
SELECT + + 41 - col2 AS col2 FROM tab2 AS cor0
----
14
15
3

query I rowsort
SELECT ALL - 38 * cor0.col2 + + col2 * - col0 FROM tab0 AS cor0
----
-10414
-2046
-73

query I rowsort
SELECT ALL 82 FROM tab2 cor0
----
82
82
82

query I rowsort
SELECT + col0 + col1 * 37 AS col1 FROM tab1 AS cor0
----
434
561
965

onlyif mysql # use DIV operator for integer division
query I rowsort label-5456
SELECT DISTINCT - + col2 DIV col0 + cor0.col0 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-5456
SELECT DISTINCT - + col2 / col0 + cor0.col0 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT DISTINCT - + 61 AS col1 FROM tab0, tab1 AS cor0
----
-61

query I rowsort
SELECT col2 + + ( cor0.col2 ) * col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT col1 + ( + col2 ) FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5460
SELECT - - col1 + - col1 DIV 96 FROM tab0 AS cor0
----
86
91
96

skipif mysql # not compatible
query I rowsort label-5460
SELECT - - col1 + - col1 / 96 FROM tab0 AS cor0
----
86
91
96

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 cor0, tab1 AS cor1, tab0 cor2
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT col0 + - col2 + + 62 AS col1 FROM tab2
----
103
114
42

query I rowsort
SELECT DISTINCT - - col0 + - 30 * col0 FROM tab1 AS cor0
----
-1856
-2320
-87

query I rowsort
SELECT + col2 * + 49 FROM tab1 AS cor0
----
2646
2793
4704

query I rowsort
SELECT DISTINCT + + col0 * - 46 AS col1 FROM tab0 AS cor0
----
-1104
-1610
-4094

query I rowsort
SELECT DISTINCT + 91 + + col2 AS col0 FROM tab2 cor0
----
117
118
129

query I rowsort
SELECT ALL - cor0.col2 * + 32 FROM tab2 AS cor0
----
-1216
-832
-864

query I rowsort
SELECT DISTINCT + 61 + col1 FROM tab1 AS cor0
----
71
74
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5469
SELECT ALL + col1 - cor0.col1 DIV - col0 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-5469
SELECT ALL + col1 - cor0.col1 / - col0 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT DISTINCT cor0.col2 - col1 AS col0 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT ( 53 ) + col2 AS col2 FROM tab1 AS cor0
----
107
110
149

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5472
SELECT + CAST( col1 AS SIGNED ) * col0 AS col1 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-5472
SELECT + CAST ( col1 AS INTEGER ) * col0 AS col1 FROM tab1
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5473
SELECT + CAST( col2 AS SIGNED ) + col2 + - tab0.col1 * - col1 AS col1 FROM tab0
----
7462
8445
9411

skipif mysql # not compatible
query I rowsort label-5473
SELECT + CAST ( col2 AS INTEGER ) + col2 + - tab0.col1 * - col1 AS col1 FROM tab0
----
7462
8445
9411

query I rowsort
SELECT DISTINCT col0 * col2 - - col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT - 51 + cor0.col0 FROM tab1 AS cor0
----
-48
13
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col1 + + col0 * col2 - col0 col0 FROM tab1
----
1563
4154
8848

query I rowsort
SELECT col0 - 47 FROM tab0
----
-12
-23
42

query I rowsort
SELECT + ( + col2 ) + col0 FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT + 97 AS col1 FROM tab0, tab2, tab0 AS cor0
----
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5480
SELECT + CAST( NULL AS DECIMAL ) + + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5480
SELECT + CAST ( NULL AS REAL ) + + col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5481
SELECT DISTINCT - CAST( - col0 AS SIGNED ) col1 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5481
SELECT DISTINCT - CAST ( - col0 AS INTEGER ) col1 FROM tab1
----
3
64
80

query I rowsort
SELECT + 98 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT ALL 66 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 36 col1 FROM tab2 AS cor0
----
1116
2124
612

query I rowsort
SELECT - tab2.col1 * + cor1.col2 AS col2 FROM tab2, tab1 AS cor0, tab0, tab2 AS cor1
----
81 values hashing to bb4b7ebd7441403fe388681c754965d0

query I rowsort
SELECT + + 81 * col0 FROM tab0 cor0
----
1944
2835
7209

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col2 FROM tab0, tab1 cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT 99 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT + ( + ( + col1 ) ) * col2 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5490
SELECT - CAST( + 91 AS SIGNED ) * + col2 + - col2 FROM tab0 AS cor0
----
-3036
-7544
-92

skipif mysql # not compatible
query I rowsort label-5490
SELECT - CAST ( + 91 AS INTEGER ) * + col2 + - col2 FROM tab0 AS cor0
----
-3036
-7544
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5491
SELECT + 16 DIV + 61 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5491
SELECT + 16 / + 61 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5492
SELECT - - ( - 2 ) DIV + col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5492
SELECT - - ( - 2 ) / + col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT col1 * - col0 + tab1.col0 AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT + 37 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT ALL - col1 + - col2 + - 1 AS col2 FROM tab1 AS cor0
----
-110
-68
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5496
SELECT DISTINCT cor0.col2 DIV + col1 col1 FROM tab2 AS cor0
----
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5496
SELECT DISTINCT cor0.col2 / + col1 col1 FROM tab2 AS cor0
----
0
2

query I rowsort
SELECT DISTINCT + + col1 * + col0 + - col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT + + col0 + 71 * col0 FROM tab0 AS cor0
----
1728
2520
6408

query I rowsort
SELECT - + col1 + 84 FROM tab0 AS cor0
----
-13
-2
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5500
SELECT - col0 + tab0.col2 * CAST( col1 + + col2 AS SIGNED ) * CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5500
SELECT - col0 + tab0.col2 * CAST ( col1 + + col2 AS INTEGER ) * CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 46 + - col1 AS col1 FROM tab2
----
-13
15
29

query I rowsort
SELECT - col1 * - 44 AS col0 FROM tab0 AS cor0
----
3784
4004
4268

onlyif mysql # use DIV operator for integer division
query I rowsort label-5503
SELECT + col0 DIV - ( 59 ) AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5503
SELECT + col0 / - ( 59 ) AS col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - + col2 * - ( + col1 ) FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 61 + + 32 FROM tab0, tab1 AS cor0
----
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5506
SELECT + col2 DIV 12 + col1 * col2 * - ( + col2 * - col2 ) AS col2 FROM tab1
----
11501576
1851934
4094068

skipif mysql # not compatible
query I rowsort label-5506
SELECT + col2 / 12 + col1 * col2 * - ( + col2 * - col2 ) AS col2 FROM tab1
----
11501576
1851934
4094068

query I rowsort
SELECT tab2.col2 - - 10 FROM tab2
----
36
37
48

query I rowsort
SELECT ALL + col0 + + 93 AS col0 FROM tab0 AS cor0
----
117
128
182

query I rowsort
SELECT + + col2 * - 15 AS col1 FROM tab2 AS cor0
----
-390
-405
-570

query I rowsort
SELECT ALL - col2 * - 55 - + 60 * col0 * + col2 AS col1 FROM tab1 AS cor0
----
-215745
-455520
-6750

onlyif mysql # use DIV operator for integer division
query I rowsort label-5511
SELECT ALL + col2 + - col0 DIV cor0.col1 FROM tab2 AS cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-5511
SELECT ALL + col2 + - col0 / cor0.col1 FROM tab2 AS cor0
----
25
27
34

query I rowsort
SELECT + ( col0 ) - col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ( 3 ) - col2 * col2 AS col2 FROM tab2 AS cor0
----
-1441
-673
-726

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5514
SELECT ALL - CAST( NULL AS DECIMAL ) + cor0.col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5514
SELECT ALL - CAST ( NULL AS REAL ) + cor0.col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 - + col1 col0 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( col2 ) col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + 85 * + col2 FROM tab0 AS cor0
----
2805
6970
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * - 31 col2 FROM tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT DISTINCT + + 65 + col1 AS col1 FROM tab2 AS cor0
----
124
82
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 + col2 * cor0.col1 col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - + ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - col2 + col0 * + col1 AS col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL - col2 * 13 FROM tab2 cor0
----
-338
-351
-494

query I rowsort
SELECT DISTINCT - + cor0.col0 * + col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * - ( col0 ) - ( 99 ) col0 FROM tab2 AS cor0
----
-1442
-316
-4701

query I rowsort
SELECT + + col0 * col0 + - col0 AS col2 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT col2 * + col2 * 49 + col1 FROM tab2 AS cor0
----
33183
35752
70773

query I rowsort
SELECT DISTINCT - 8 * + 14 FROM tab2
----
-112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 col0 FROM tab0
----
72
72
72

query I rowsort
SELECT - + 73 * col2 * + 99 + 51 FROM tab0 AS cor0
----
-238440
-592563
-7176

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 48 - col0 col1 FROM tab2 AS cor0
----
-126
-127
-55

query I rowsort
SELECT - - col1 * - col2 * col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5533
SELECT - col1 * col0 * CAST( NULL AS SIGNED ) - col2 * col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5533
SELECT - col1 * col0 * CAST ( NULL AS INTEGER ) - col2 * col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col0 ) * + 72 FROM tab2 AS cor0
----
-504
-5616
-5688

query I rowsort
SELECT ALL + + col2 * - 37 AS col1 FROM tab1 AS cor0
----
-1998
-2109
-3552

query I rowsort
SELECT + col2 * col2 + col0 FROM tab0 cor0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-5537
SELECT - ( - 1 ) DIV col1 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5537
SELECT - ( - 1 ) / col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + col0 + - 33 FROM tab0 AS cor0
----
-122
-57
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-5539
SELECT ALL ( - cor0.col0 ) * - col0 DIV - col0 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5539
SELECT ALL ( - cor0.col0 ) * - col0 / - col0 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5540
SELECT + CAST( NULL AS SIGNED ) + 67 / + cor0.col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5540
SELECT + CAST ( NULL AS INTEGER ) + 67 / + cor0.col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 39 * - col0 * col1 AS col0 FROM tab1 AS cor0
----
24960
3042
40560

query I rowsort
SELECT col0 * - 18 + + col0 AS col1 FROM tab0 AS cor0
----
-1513
-408
-595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5543
SELECT + - CAST( NULL AS SIGNED ) - col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5543
SELECT + - CAST ( NULL AS INTEGER ) - col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5544
SELECT DISTINCT - CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5544
SELECT DISTINCT - CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL ( + cor0.col2 ) AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT 2 * + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to e205c60b0806256e15ecb6a115a429b3

query I rowsort
SELECT - col1 + ( + col1 + - col1 ) FROM tab0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5548
SELECT tab1.col1 * - col0 DIV + col0 AS col1 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5548
SELECT tab1.col1 * - col0 / + col0 AS col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT + - col1 * - cor0.col1 + col0 * - col2 AS col1 FROM tab0 AS cor0
----
6604
9374
983

query I rowsort
SELECT DISTINCT 11 * + ( - cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-110
-143
-286

onlyif mysql # use DIV operator for integer division
query I rowsort label-5551
SELECT + tab0.col2 DIV 21 col0 FROM tab0
----
0
1
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5551
SELECT + tab0.col2 / 21 col0 FROM tab0
----
0
1
3

query I rowsort
SELECT ALL + col0 * + col2 AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT 67 + 56 AS col0 FROM tab1
----
123
123
123

query I rowsort
SELECT ALL ( col0 ) + tab2.col1 AS col0 FROM tab2
----
137
38
96

query I rowsort
SELECT ( + ( col0 ) ) * col1 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT col0 * + col1 + + col1 * + ( ( + col2 ) ) + col1 * + col1 AS col0 FROM tab1
----
1310
2158
2457

query I rowsort
SELECT + col0 + 81 AS col0 FROM tab1
----
145
161
84

query I rowsort
SELECT 59 * + cor1.col2 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 480e5281eb7ad5a17f369ba6b37b1b54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 40 col1 FROM tab1 AS cor0
----
104
120
43

query I rowsort
SELECT DISTINCT + cor0.col2 + 41 * col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
123120
7776
83174

query I rowsort
SELECT 38 * - 8 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 031809b7ba4424248f09bd6dc6c4d6ee

query I rowsort
SELECT DISTINCT col1 + 17 * + col1 FROM tab2
----
1062
306
558

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 - - col0 col1 FROM tab0
----
178
48
70

query I rowsort
SELECT DISTINCT + col2 - col1 * + tab0.col0 AS col2 FROM tab0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-5565
SELECT ALL 79 DIV + 95 FROM tab2, tab1 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-5565
SELECT ALL 79 / + 95 FROM tab2, tab1 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL + col1 - 34 FROM tab2
----
-17
-3
25

query I rowsort
SELECT DISTINCT col0 - col1 AS col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT - col1 * col1 + col0 * + col1 FROM tab2 AS cor0
----
-744
1054
1121

query I rowsort
SELECT DISTINCT - cor0.col1 + cor0.col2 FROM tab0, tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + col1 * - 9 AS col1 FROM tab2 AS cor0
----
-153
-279
-531

query I rowsort
SELECT ALL + col0 + 52 AS col2 FROM tab2 cor0
----
130
131
59

query I rowsort
SELECT ALL col2 * ( col1 ) + col1 AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + col2 * + col1 + - col0 + - col0 FROM tab2 cor0
----
1378
488
823

query I rowsort
SELECT ( tab1.col2 ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT DISTINCT + 72 + - 96 FROM tab0 AS cor0
----
-24

query IIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0 WHERE NOT NULL IN ( cor0.col2 )
----

query I rowsort
SELECT DISTINCT + + cor0.col0 * 67 FROM tab0 AS cor0
----
1608
2345
5963

onlyif mysql # use DIV operator for integer division
query I rowsort label-5578
SELECT 75 DIV + 60 - + col2 AS col1 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-5578
SELECT 75 / + 60 - + col2 AS col1 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT - 11 + col0 * col0 AS col2 FROM tab2 AS cor0
----
38
6073
6230

query I rowsort
SELECT ALL + ( col1 ) * - col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - col1 + + 45 AS col1 FROM tab0 AS cor0
----
-41
-46
-52

query I rowsort
SELECT ALL 4 * col0 * col1 FROM tab2 cor0
----
18408
5372
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + tab1.col1 col2 FROM tab1
----
109
67
80

query I rowsort
SELECT - - cor0.col1 * - col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT 98 * col1 FROM tab1 AS cor0
----
1274
2548
980

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 86 col2 FROM tab1 AS cor0
----
86
86
86

query I rowsort
SELECT + 10 + - col0 FROM tab1
----
-54
-70
7

query I rowsort
SELECT 49 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5589
SELECT ALL + + ( + cor0.col0 ) - CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5589
SELECT ALL + + ( + cor0.col0 ) - CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col2 * + col0 * col0 + 8 FROM tab0 AS cor0
----
1233
19016
649530

query I rowsort
SELECT DISTINCT + + 54 + + col0 + - col0 AS col1 FROM tab0 AS cor0
----
54

query I rowsort
SELECT + 87 AS col1 FROM tab1 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT + col2 * - col2 + cor0.col1 * - col0 * col0 AS col1 FROM tab1 AS cor0
----
-3150
-44209
-92416

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL - col1 + 39 * - 45 FROM tab2 cor0
----
-1772
-1786
-1814

query I rowsort
SELECT - cor0.col0 + 2 AS col0 FROM tab2 AS cor0
----
-5
-76
-77

query I rowsort
SELECT DISTINCT + - col2 * + 22 - col1 * col0 * + 56 AS col1 FROM tab2 AS cor0
----
-12746
-258284
-76044

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 - col0 col2 FROM tab1 AS cor0
----
-128
-160
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5599
SELECT DISTINCT col0 DIV 8 + 59 + + col1 * - 24 AS col1 FROM tab1 AS cor0
----
-173
-243
-565

skipif mysql # not compatible
query I rowsort label-5599
SELECT DISTINCT col0 / 8 + 59 + + col1 * - 24 AS col1 FROM tab1 AS cor0
----
-173
-243
-565

query I rowsort
SELECT 19 * col0 + col1 FROM tab0
----
1782
542
762

query I rowsort
SELECT 67 * - col0 + ( + col0 + col2 ) FROM tab1
----
-144
-4167
-5184

query I rowsort
SELECT - 98 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 9b0655947ad21e0b95a137a474fa6a1f

query I rowsort
SELECT + 61 * col0 * col0 + col1 FROM tab0
----
35222
483272
74822

query I rowsort
SELECT ALL - tab2.col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT 87 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT DISTINCT + 32 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 61 col0 FROM tab1
----
61
61
61

query I rowsort
SELECT ALL 10 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT DISTINCT + 94 AS col1 FROM tab1
----
94

query I rowsort
SELECT ALL - 69 * col0 AS col0 FROM tab1
----
-207
-4416
-5520

query I rowsort
SELECT DISTINCT col1 * - col0 + - col0 AS col2 FROM tab2
----
-1422
-224
-4680

query I rowsort
SELECT - 87 + cor0.col1 FROM tab1 AS cor0
----
-61
-74
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-5613
SELECT - col0 * col1 DIV + CAST( - col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5613
SELECT - col0 * col1 / + CAST ( - col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - 81 + + col1 * ( + cor0.col2 ) FROM tab2 AS cor0
----
1453
565
756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + + col1 col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + 92 col1 FROM tab1
----
1196
2392
920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + 77 ) * col2 col2 FROM tab0 AS cor0
----
2541
6314
77

query I rowsort
SELECT ALL + col1 + - 95 FROM tab0 AS cor0
----
-4
-9
2

query I rowsort
SELECT - - 25 + col1 AS col2 FROM tab0 cor0
----
111
116
122

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col2 ) col0 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + + cor0.col2 * col0 + col1 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5622
SELECT ALL + CAST( - ( + col0 ) AS SIGNED ) FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5622
SELECT ALL + CAST ( - ( + col0 ) AS INTEGER ) FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5623
SELECT ALL + - cor0.col1 * 32 DIV - col1 AS col0 FROM tab2 AS cor0
----
32
32
32

skipif mysql # not compatible
query I rowsort label-5623
SELECT ALL + - cor0.col1 * 32 / - col1 AS col0 FROM tab2 AS cor0
----
32
32
32

query I rowsort
SELECT - 20 FROM tab0, tab0 AS cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query I rowsort
SELECT + - cor0.col2 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort
SELECT + ( ( - col2 ) ) * CAST ( + 0 AS REAL ) FROM tab0 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5627
SELECT - ( + col1 ) * - col0 * CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5627
SELECT - ( + col1 ) * - col0 * CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5628
SELECT + + col0 DIV - col2 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-5628
SELECT + + col0 / - col2 FROM tab0 cor0
----
-1
-35
0

query I rowsort
SELECT + + 45 + + col0 * - col1 + col0 * col2 FROM tab2 AS cor0
----
-2529
17
1704

query I rowsort
SELECT - - tab2.col1 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 55 ) col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

query I rowsort
SELECT + 80 AS col2 FROM tab1 cor0
----
80
80
80

query I rowsort
SELECT + cor1.col2 AS col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ( - col2 ) * ( - ( col2 ) ) FROM tab0 cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5635
SELECT ALL - - ( + col2 ) * - CAST( NULL AS SIGNED ) + + 19 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5635
SELECT ALL - - ( + col2 ) * - CAST ( NULL AS INTEGER ) + + 19 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5636
SELECT - + col1 + col2 DIV col0 FROM tab2 AS cor0
----
-17
-28
-59

skipif mysql # not compatible
query I rowsort label-5636
SELECT - + col1 + col2 / col0 FROM tab2 AS cor0
----
-17
-28
-59

query I rowsort
SELECT DISTINCT + - 37 FROM tab2 cor0
----
-37

query I rowsort
SELECT ALL + 19 + + col1 FROM tab2 AS cor0
----
36
50
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5639
SELECT - - col0 * + CAST( col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-5639
SELECT - - col0 * + CAST ( col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + col1 + col0 * + ( - col2 ) AS col2 FROM tab0 cor0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5642
SELECT + - cor0.col0 * CAST( col2 * col1 AS SIGNED ) - col2 * + col2 * + col1 AS col1 FROM tab0 AS cor0
----
-1276002
-161766
-3492

skipif mysql # not compatible
query I rowsort label-5642
SELECT + - cor0.col0 * CAST ( col2 * col1 AS INTEGER ) - col2 * + col2 * + col1 AS col1 FROM tab0 AS cor0
----
-1276002
-161766
-3492

onlyif mysql # use DIV operator for integer division
query I rowsort label-5643
SELECT + col2 + col1 DIV 23 FROM tab1 AS cor0
----
55
57
96

skipif mysql # not compatible
query I rowsort label-5643
SELECT + col2 + col1 / 23 FROM tab1 AS cor0
----
55
57
96

query I rowsort
SELECT - col2 + + col0 * + col1 * col2 + col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT - 50 * col1 + tab0.col2 AS col0 FROM tab0
----
-4267
-4468
-4849

query I rowsort
SELECT - col2 + ( col1 ) * + cor0.col0 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT + 60 * col1 + col2 FROM tab2 AS cor0
----
1058
1887
3566

query I rowsort
SELECT + 72 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1224
-2232
-4248

query I rowsort
SELECT - + 73 + + col1 AS col0 FROM tab1 AS cor0
----
-47
-60
-63

query I rowsort
SELECT - - col0 + 99 FROM tab2 AS cor0
----
106
177
178

query I rowsort
SELECT DISTINCT 41 AS col1 FROM tab2, tab0 AS cor0
----
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5652
SELECT DISTINCT + + CAST( NULL AS DECIMAL ) * cor0.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5652
SELECT DISTINCT + + CAST ( NULL AS REAL ) * cor0.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT col2 + col1 - + col2 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col2 * - col0 col2 FROM tab1
----
-162
-3648
-7680

query IIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0 WHERE NOT NULL > NULL
----

query I rowsort
SELECT ALL - col2 + col2 * tab1.col0 * col0 FROM tab1 WHERE NULL IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5657
SELECT ALL tab2.col0 * col2 + col0 * tab2.col1 * + tab2.col0 - col1 * col1 DIV - col0 FROM tab2
----
109102
1845
361028

skipif mysql # not compatible
query I rowsort label-5657
SELECT ALL tab2.col0 * col2 + col0 * tab2.col1 * + tab2.col0 - col1 * col1 / - col0 FROM tab2
----
109102
1845
361028

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col2 col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL + col2 * - col1 + + col1 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT + col2 * + col2 + + col1 * + col0 AS col0 FROM tab0 AS cor0
----
14823
3153
3396

query I rowsort
SELECT cor0.col0 * - col1 * col0 AS col1 FROM tab2 AS cor0
----
-106097
-1519
-358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-5662
SELECT cor0.col0 * - col0 DIV + col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5662
SELECT cor0.col0 * - col0 / + col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT cor0.col0 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + col0 * + col2 - col1 FROM tab2
----
158
1969
2985

query I rowsort
SELECT ALL + col0 * col1 - col2 FROM tab2
----
1305
190
4576

query I rowsort
SELECT DISTINCT tab1.col2 * - col1 + - col2 FROM tab1
----
-1344
-1458
-627

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) NOT IN ( - col0 / col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5668
SELECT DISTINCT + col1 * col1 DIV - col1 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-5668
SELECT DISTINCT + col1 * col1 / - col1 FROM tab2
----
-17
-31
-59

query III rowsort
SELECT * FROM tab0 WHERE - col1 - - col1 BETWEEN col1 AND ( - col0 )
----

query I rowsort
SELECT DISTINCT col1 / - tab1.col1 AS col2 FROM tab1 WHERE NOT ( col2 - - col1 ) NOT BETWEEN NULL AND - col2
----

query I rowsort
SELECT - col2 * + col1 * + tab1.col1 AS col0 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT tab2.col0 * col2 + col1 * col2 AS col0 FROM tab2 WHERE ( + col0 * col0 - col0 * + col0 / - col1 ) BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT tab1.col0 * col0 + col2 * col1 FROM tab1
----
1413
4666
7648

query I rowsort
SELECT ALL col0 * tab0.col2 + - col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT col0 + - col1 + + col0 AS col0 FROM tab1
----
-20
118
147

query I rowsort
SELECT ALL + col1 + col0 + + col1 * col2 AS col2 FROM tab2
----
1671
742
875

query I rowsort
SELECT - col1 + + cor0.col0 * + col1 AS col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT DISTINCT col1 + col1 * - col2 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + cor0.col0 * - cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col1 + cor0.col0 * - col2 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-5681
SELECT DISTINCT cor0.col0 * + col1 DIV + col1 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5681
SELECT DISTINCT cor0.col0 * + col1 / + col1 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL - col1 * col0 - col1 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL - + col0 * col2 + + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - col0 - col2 * col1 AS col0 FROM tab0
----
-132
-2862
-7551

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT col2 + - col2 BETWEEN cor0.col2 AND col0 + col2 + + col0
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col0 col2 FROM tab0 cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-5687
SELECT DISTINCT - col2 DIV col0 - cor0.col0 AS col2 FROM tab2 AS cor0
----
-10
-78
-79

skipif mysql # not compatible
query I rowsort label-5687
SELECT DISTINCT - col2 / col0 - cor0.col0 AS col2 FROM tab2 AS cor0
----
-10
-78
-79

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT col1 <= NULL
----

query I rowsort
SELECT col2 * - tab2.col0 + col2 * col1 FROM tab2
----
-2356
-494
648

query I rowsort
SELECT - col2 + - col0 * - col2 AS col0 FROM tab0
----
34
7216
759

query I rowsort
SELECT + + cor0.col0 + - col2 * + col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT - col2 * - col1 * col0 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL col0 * - 13 AS col2 FROM tab1 cor0
----
-1040
-39
-832

onlyif mysql # use DIV operator for integer division
query I rowsort label-5694
SELECT DISTINCT + cor0.col1 DIV 99 col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5694
SELECT DISTINCT + cor0.col1 / 99 col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + + col2 + ( col2 ) FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - cor0.col2 + 13 * col2 * + col2 AS col2 FROM tab2 AS cor0
----
18734
8762
9450

query I rowsort
SELECT ALL col0 * + ( - col0 ) AS col1 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT cor0.col2 + - cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 cor1
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5699
SELECT DISTINCT + cor0.col1 * - 38 + cor0.col1 DIV - col1 AS col0 FROM tab0 AS cor0
----
-3269
-3459
-3687

skipif mysql # not compatible
query I rowsort label-5699
SELECT DISTINCT + cor0.col1 * - 38 + cor0.col1 / - col1 AS col0 FROM tab0 AS cor0
----
-3269
-3459
-3687

query I rowsort
SELECT DISTINCT + col0 + - 35 * + col2 AS col2 FROM tab1 AS cor0
----
-1887
-1931
-3280

onlyif mysql # use DIV operator for integer division
query I rowsort label-5701
SELECT ALL col1 DIV - cor0.col1 AS col1 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5701
SELECT ALL col1 / - cor0.col1 AS col1 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - + col0 * - col2 + col1 FROM tab2 cor0
----
2087
220
3019

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL > ( NULL )
----

query I rowsort
SELECT - tab2.col0 * + col0 + - col1 * + tab2.col1 + tab2.col2 AS col2 FROM tab2
----
-6492
-9539
-983

query I rowsort
SELECT tab1.col1 * - col2 + col1 + - col1 FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col0 + + col2 col2 FROM tab2
----
6110
6279
76

query I rowsort
SELECT ALL - col0 + col2 * col0 * tab2.col0 + col2 FROM tab2
----
1343
158132
237117

query I rowsort
SELECT col0 + + col0 AS col2 FROM tab0 WHERE NOT + col2 + - col2 + col2 = NULL
----

query I rowsort
SELECT + col0 + col2 * col1 - col0 * - tab0.col0 FROM tab0
----
1357
15472
3438

onlyif mysql # use DIV operator for integer division
query I rowsort label-5710
SELECT + tab1.col1 DIV + col2 + col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5710
SELECT + tab1.col1 / + col2 + col0 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + 12 AS col2 FROM tab1 AS cor0
----
12
12
12

query I rowsort
SELECT + col2 * + col0 * 64 FROM tab1 AS cor0
----
10368
233472
491520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * ( + 40 ) col1 FROM tab2, tab2 AS cor0
----
9 values hashing to e4fd78a366a8ff8c665c624ac16afe2c

query I rowsort
SELECT ALL 59 * - col2 FROM tab1
----
-3186
-3363
-5664

query I rowsort
SELECT - col0 * col0 * - col1 AS col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT DISTINCT + - col0 + + col1 * 43 AS col0 FROM tab0 AS cor0
----
3674
3824
4136

query I rowsort
SELECT 81 + col0 * + col0 + ( - col0 ) * - 29 AS col1 FROM tab1 AS cor0
----
177
6033
8801

query I rowsort
SELECT DISTINCT + 26 * col0 FROM tab0 AS cor0
----
2314
624
910

query I rowsort
SELECT + cor0.col1 * cor0.col1 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 4a2f25e7025075a0ce048be425c35957

query I rowsort
SELECT + col0 * col0 + - col1 + 6 AS col2 FROM tab2 cor0
----
24
6031
6230

query I rowsort
SELECT - tab0.col0 * - col0 - + col0 AS col2 FROM tab0
----
1190
552
7832

query I rowsort
SELECT col2 * 89 + - col2 AS col1 FROM tab0 cor0
----
2904
7216
88

query I rowsort
SELECT - col2 + + 40 FROM tab0 AS cor0
----
-42
39
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 68 col2 FROM tab0 AS cor0
----
68
68
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL tab2.col0 - + 68 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 7b0b6d99397753168e63bbac8313c729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5727
SELECT DISTINCT + CAST( ( col1 ) AS SIGNED ) + - col2 * col0 * - col0 AS col0 FROM tab1
----
233482
512
614413

skipif mysql # not compatible
query I rowsort label-5727
SELECT DISTINCT + CAST ( ( col1 ) AS INTEGER ) + - col2 * col0 * - col0 AS col0 FROM tab1
----
233482
512
614413

query I rowsort
SELECT 51 * + cor0.col2 FROM tab2 AS cor0
----
1326
1377
1938

query I rowsort
SELECT ALL + ( - 48 ) FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT DISTINCT + 64 - - col1 AS col2 FROM tab2 AS cor0
----
123
81
95

query I rowsort
SELECT ALL - tab2.col0 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT DISTINCT ( col2 + col1 ) AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT - + col2 + col0 * col1 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT ALL - col2 * col2 * - col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT ALL - + col0 * - col2 + - col0 AS col1 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT col1 * - col0 + + col0 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-10686
-266
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-5737
SELECT - cor0.col0 DIV - col1 + + col1 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-5737
SELECT - cor0.col0 / - col1 + + col1 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT ALL col0 + + col2 - + col2 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5739
SELECT col2 - tab0.col1 DIV col1 col1 FROM tab0
----
0
32
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5739
SELECT col2 - tab0.col1 / col1 col1 FROM tab0
----
0
32
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5740
SELECT ALL - col1 DIV col2 + col0 + tab0.col2 AS col1 FROM tab0
----
-61
170
55

skipif mysql # not compatible
query I rowsort label-5740
SELECT ALL - col1 / col2 + col0 + tab0.col2 AS col1 FROM tab0
----
-61
170
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-5741
SELECT ALL tab1.col1 + col0 DIV tab1.col2 AS col0 FROM tab1
----
11
13
26

skipif mysql # not compatible
query I rowsort label-5741
SELECT ALL tab1.col1 + col0 / tab1.col2 AS col0 FROM tab1
----
11
13
26

query I rowsort
SELECT ALL + col1 * + tab2.col1 + col2 FROM tab2
----
327
3507
988

query I rowsort
SELECT ALL + - col1 + + cor0.col2 * + col1 * - col1 AS col2 FROM tab1 AS cor0
----
-16237
-36530
-5710

onlyif mysql # use DIV operator for integer division
query I rowsort label-5744
SELECT ALL col0 DIV col0 + col0 + col0 * col0 AS col1 FROM tab2
----
57
6163
6321

skipif mysql # not compatible
query I rowsort label-5744
SELECT ALL col0 / col0 + col0 + col0 * col0 AS col1 FROM tab2
----
57
6163
6321

onlyif mysql # use DIV operator for integer division
query I rowsort label-5745
SELECT + 4 DIV - 65 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5745
SELECT + 4 / - 65 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 89 + col0 FROM tab0
----
113
124
178

query I rowsort
SELECT + col0 * col2 + - col0 AS col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT 10 * + col1 - col1 * col0 AS col2 FROM tab2
----
-1173
-4012
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5749
SELECT + ( col0 ) DIV + col1 - col2 AS col0 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5749
SELECT + ( col0 ) / + col1 - col2 AS col0 FROM tab0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5750
SELECT + 78 DIV col2 + col1 * + col1 AS col2 FROM tab1 AS cor0
----
101
169
677

skipif mysql # not compatible
query I rowsort label-5750
SELECT + 78 / col2 + col1 * + col1 AS col2 FROM tab1 AS cor0
----
101
169
677

onlyif mysql # use DIV operator for integer division
query I rowsort label-5751
SELECT ( col2 ) + - col2 * + col0 - col2 DIV col2 FROM tab1 AS cor0
----
-109
-3592
-7585

skipif mysql # not compatible
query I rowsort label-5751
SELECT ( col2 ) + - col2 * + col0 - col2 / col2 FROM tab1 AS cor0
----
-109
-3592
-7585

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 + + col1 col1 FROM tab1 AS cor0
----
21
5
8

query I rowsort
SELECT DISTINCT + col2 * - col2 * cor0.col2 FROM tab1 AS cor0
----
-157464
-185193
-884736

query I rowsort
SELECT - 53 + - col0 * - col2 - col0 FROM tab0 AS cor0
----
-53
715
7156

onlyif mysql # use DIV operator for integer division
query I rowsort label-5755
SELECT col1 DIV col1 + col0 AS col2 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5755
SELECT col1 / col1 + col0 AS col2 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT col0 - - cor0.col2 FROM tab1 cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5757
SELECT ALL - + col0 DIV - cor0.col2 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5757
SELECT ALL - + col0 / - cor0.col2 FROM tab1 cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 6 col2 FROM tab0
----
6
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5759
SELECT DISTINCT col2 DIV 78 AS col0 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-5759
SELECT DISTINCT col2 / 78 AS col0 FROM tab1
----
0
1

query I rowsort
SELECT ALL - 18 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

query I rowsort
SELECT DISTINCT cor0.col1 * + col2 + + col2 * - col2 FROM tab0 AS cor0
----
1749
738
96

query I rowsort
SELECT DISTINCT col1 * 68 FROM tab1
----
1768
680
884

query I rowsort
SELECT - col1 * col0 + + col2 * col1 AS col1 FROM tab2
----
-3068
-697
620

query I rowsort
SELECT - 16 + + 39 * - col1 FROM tab0
----
-3370
-3565
-3799

query I rowsort
SELECT 1 * - col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 9 col1 FROM tab1 AS cor0
----
9

query I rowsort
SELECT ALL 9 * col2 FROM tab1
----
486
513
864

query I rowsort
SELECT DISTINCT + + col0 * col2 * 66 FROM tab0 AS cor0
----
2310
481668
52272

query I rowsort
SELECT - cor1.col2 AS col1 FROM tab0, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 2df272448a67587d4635afedff278dcc

query I rowsort
SELECT + - 77 * col0 AS col1 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT DISTINCT + + 30 FROM tab1 cor0
----
30

query I rowsort
SELECT - + 68 * + col0 AS col2 FROM tab1 AS cor0
----
-204
-4352
-5440

query I rowsort
SELECT ALL - - cor0.col0 * col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL + 21 * col0 FROM tab1 AS cor0
----
1344
1680
63

query I rowsort
SELECT - col2 * + col1 * col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT col2 + ( 6 ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
177
211
616

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - - cor0.col1 * - CAST ( + col1 * - col2 AS REAL ) col2 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT DISTINCT + 24 + - 67 FROM tab1, tab1 AS cor0
----
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + 1 col1 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT DISTINCT - + cor0.col2 + 55 * - col1 AS col2 FROM tab2 cor0
----
-1732
-3271
-973

onlyif mysql # use DIV operator for integer division
query I rowsort label-5781
SELECT ALL - + col0 + - col1 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-5781
SELECT ALL - + col0 + - col1 / cor0.col1 AS col1 FROM tab2 AS cor0
----
-79
-8
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5782
SELECT DISTINCT cor0.col0 DIV col1 - + col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5782
SELECT DISTINCT cor0.col0 / col1 - + col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL col2 + ( - ( - cor0.col0 ) ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT - - col2 + + 91 FROM tab1 cor0
----
145
148
187

query I rowsort
SELECT ALL - col2 + - ( col0 ) FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + - col2 * 83 AS col2 FROM tab2 cor0
----
-2158
-2241
-3154

query I rowsort
SELECT DISTINCT + col2 * - col0 - 44 AS col1 FROM tab0 AS cor0
----
-7342
-79
-836

query I rowsort
SELECT ALL - col1 + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT ALL + - cor0.col1 + ( col0 * ( - col2 ) + - col1 ) AS col2 FROM tab1 AS cor0
----
-214
-3668
-7706

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5790
SELECT DISTINCT - CAST( NULL AS SIGNED ) - ( col0 ) * + col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5790
SELECT DISTINCT - CAST ( NULL AS INTEGER ) - ( col0 ) * + col0 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 24 + col2 FROM tab2 AS cor0
----
50
51
62

query I rowsort
SELECT - - 74 * + 6 AS col0 FROM tab0 AS cor0
----
444
444
444

query I rowsort
SELECT ALL + 28 + ( col2 * col0 ) FROM tab0 AS cor0
----
63
7326
820

query I rowsort
SELECT DISTINCT - col1 * + cor0.col1 + - col0 AS col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT ALL + + col1 + - ( col0 ) * 4 FROM tab1 AS cor0
----
-246
-307
14

query I rowsort
SELECT DISTINCT + col0 + - col2 * + col2 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT - 62 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
-62

query I rowsort
SELECT - 66 + - col1 AS col2 FROM tab1 cor0
----
-76
-79
-92

query I rowsort
SELECT DISTINCT + - cor0.col2 * ( + cor0.col1 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL col0 * + 22 FROM tab2 AS cor0
----
154
1716
1738

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * 63 col0 FROM tab1 cor0
----
1638
630
819

query I rowsort
SELECT DISTINCT - + col0 * - cor0.col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL + col0 + - 8 AS col1 FROM tab1 cor0
----
-5
56
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5804
SELECT + CAST( NULL AS SIGNED ) + col1 * col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5804
SELECT + CAST ( NULL AS INTEGER ) + col1 * col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 17 * - col2 FROM tab2 AS cor0
----
-442
-459
-646

query I rowsort
SELECT col1 + + col0 * cor0.col1 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-36470
-4186
-99827

onlyif mysql # use DIV operator for integer division
query I rowsort label-5807
SELECT - col1 DIV col1 + + col1 AS col2 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-5807
SELECT - col1 / col1 + + col1 AS col2 FROM tab1
----
12
25
9

query I rowsort
SELECT ALL + 62 - cor0.col1 AS col0 FROM tab1 AS cor0
----
36
49
52

query I rowsort
SELECT + + 12 + 62 FROM tab0 AS cor0
----
74
74
74

query I rowsort
SELECT DISTINCT - + 1 + - col2 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT 55 + + cor0.col0 AS col2 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to d548b7d478e46f293983a3195fb7ee95

query I rowsort
SELECT - ( col0 * col2 ) + tab2.col1 AS col1 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT - col1 * - col0 * - col1 + - col0 - ( col1 ) FROM tab2 cor0
----
-22927
-271655
-6765

onlyif mysql # use DIV operator for integer division
query I rowsort label-5814
SELECT ALL + col2 DIV - cor0.col1 col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5814
SELECT ALL + col2 / - cor0.col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col1 + ( col1 ) FROM tab1 AS cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5816
SELECT - col0 * + cor0.col2 * - col0 + col0 DIV 15 AS col1 FROM tab0 AS cor0
----
1227
19009
649527

skipif mysql # not compatible
query I rowsort label-5816
SELECT - col0 * + cor0.col2 * - col0 + col0 / 15 AS col1 FROM tab0 AS cor0
----
1227
19009
649527

query I rowsort
SELECT col2 * - col1 * + tab1.col1 + col0 + col1 * - col2 FROM tab1
----
-17392
-37905
-6206

query I rowsort
SELECT DISTINCT col2 + + col1 + + col0 * - col0 FROM tab2
----
-5999
-6186
9

query I rowsort
SELECT + 25 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT ALL + col1 + 86 FROM tab2
----
103
117
145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col1 FROM tab0, tab2 cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT ALL col1 * - col2 + 35 + - col0 AS col2 FROM tab1
----
-1293
-1372
-599

query I rowsort
SELECT DISTINCT - col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5824
SELECT ALL + CAST( NULL AS SIGNED ) / + 58 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5824
SELECT ALL + CAST ( NULL AS INTEGER ) / + 58 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5825
SELECT DISTINCT + col1 DIV - ( + col1 ) AS col2 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5825
SELECT DISTINCT + col1 / - ( + col1 ) AS col2 FROM tab1 cor0
----
-1

query I rowsort
SELECT ALL - col2 - + col2 FROM tab1 AS cor0
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-5827
SELECT + - cor0.col1 * col1 + + 33 DIV + cor0.col0 FROM tab2 AS cor0
----
-289
-3481
-957

skipif mysql # not compatible
query I rowsort label-5827
SELECT + - cor0.col1 * col1 + + 33 / + cor0.col0 FROM tab2 AS cor0
----
-289
-3481
-957

onlyif mysql # use DIV operator for integer division
query I rowsort label-5828
SELECT - col2 DIV - col2 + col2 * - cor0.col1 + - col1 AS col0 FROM tab0 cor0
----
-193
-2923
-7552

skipif mysql # not compatible
query I rowsort label-5828
SELECT - col2 / - col2 + col2 * - cor0.col1 + - col1 AS col0 FROM tab0 cor0
----
-193
-2923
-7552

query I rowsort
SELECT + - col1 + - ( - 44 + col0 ) AS col1 FROM tab0 AS cor0
----
-136
-66
-88

query I rowsort
SELECT DISTINCT - col2 * - ( - col1 ) + col2 AS col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT 19 * - cor1.col2 + 32 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 82176dac55c13653be1124a41ca011c3

query I rowsort
SELECT - cor0.col0 + - 98 + 64 AS col2 FROM tab0 AS cor0
----
-123
-58
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 + col2 col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT - col1 - 17 AS col0 FROM tab1 cor0
----
-27
-30
-43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5835
SELECT DISTINCT + CAST( - 76 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-76

skipif mysql # not compatible
query I rowsort label-5835
SELECT DISTINCT + CAST ( - 76 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 61 + cor0.col1 col1 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
71
74
87

query I rowsort
SELECT DISTINCT + + col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + 73 - - 8 FROM tab1 AS cor0
----
81
81
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5839
SELECT CAST( + 3 AS SIGNED ) FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

skipif mysql # not compatible
query I rowsort label-5839
SELECT CAST ( + 3 AS INTEGER ) FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT + col1 - + cor0.col2 * col1 AS col1 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT + col0 + 0 AS col1 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5842
SELECT CAST( cor0.col2 AS SIGNED ) - col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5842
SELECT CAST ( cor0.col2 AS INTEGER ) - col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5843
SELECT ALL - col1 DIV 89 + tab1.col0 AS col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5843
SELECT ALL - col1 / 89 + tab1.col0 AS col0 FROM tab1
----
3
64
80

query I rowsort
SELECT col2 - + col1 * col1 * + col1 FROM tab0 AS cor0
----
-636023
-753489
-912672

query I rowsort
SELECT ( col2 ) * + col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - ( + col0 ) + - cor0.col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - tab2.col1 * tab2.col1 * col2 AS col0 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT ALL + ( - col2 ) + - col1 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT - col2 + + col0 + - col2 * 34 FROM tab0
----
-1131
-2781
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 62 * col2 col1 FROM tab2 cor0
----
1612
1674
2356

query I rowsort
SELECT 28 * - col0 AS col1 FROM tab0 AS cor0
----
-2492
-672
-980

query I rowsort
SELECT ( - ( - col2 ) ) FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT col1 * cor0.col2 + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT + 52 * col1 FROM tab1 AS cor0
----
1352
520
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5855
SELECT - col0 * col1 / CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5855
SELECT - col0 * col1 / CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col2 ) * 41 * tab2.col1 FROM tab2
----
-26486
-34317
-62894

onlyif mysql # use DIV operator for integer division
query I rowsort label-5857
SELECT + col2 + - ( col1 ) DIV - col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-5857
SELECT + col2 + - ( col1 ) / - col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT DISTINCT col2 + 80 AS col1 FROM tab2 AS cor0
----
106
107
118

query I rowsort
SELECT DISTINCT - + col0 * col2 + col1 + - col0 AS col1 FROM tab0 AS cor0
----
-7296
-730
27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5860
SELECT col1 + + CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-5860
SELECT col1 + + CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - 58 * - tab1.col1 FROM tab1
----
1508
580
754

query I rowsort
SELECT - 14 + col2 FROM tab2
----
12
13
24

query I rowsort
SELECT tab0.col0 + col1 + - 53 FROM tab0
----
127
57
79

query I rowsort
SELECT - col0 + - col2 + col1 AS col1 FROM tab2
----
-100
-3
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-5865
SELECT DISTINCT - col0 DIV col2 + CAST( + ( + col0 ) AS SIGNED ) * ( + col1 ) AS col1 FROM tab0
----
2064
3360
8098

skipif mysql # not compatible
query I rowsort label-5865
SELECT DISTINCT - col0 / col2 + CAST ( + ( + col0 ) AS INTEGER ) * ( + col1 ) AS col1 FROM tab0
----
2064
3360
8098

query I rowsort
SELECT ALL ( 3 ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT tab0.col0 - col0 * + col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT + 53 + - col0 - - col1 FROM tab2
----
-9
34
77

query I rowsort
SELECT DISTINCT + tab0.col1 - - col0 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT + + 10 * - col2 AS col1 FROM tab1 AS cor0
----
-540
-570
-960

query I rowsort
SELECT + col0 + - ( + tab1.col1 ) AS col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL - + col2 * cor0.col0 * - col2 + + col2 * + col1 AS col0 FROM tab2 cor0
----
114722
54262
5940

query I rowsort
SELECT DISTINCT + 56 * col1 AS col2 FROM tab1 AS cor0
----
1456
560
728

onlyif mysql # use DIV operator for integer division
query I rowsort label-5874
SELECT DISTINCT - 25 DIV - col1 + col0 DIV CAST( + 91 AS SIGNED ) FROM tab2 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5874
SELECT DISTINCT - 25 / - col1 + col0 / CAST ( + 91 AS INTEGER ) FROM tab2 AS cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5875
SELECT ALL - col1 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5875
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab2.col0 - + 42 FROM tab2
----
-120
-121
-49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 17 + ( + col1 ) * col2 col1 FROM tab1 AS cor0
----
1231
1387
553

query I rowsort
SELECT + - col1 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5879
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-5879
SELECT + + ( col2 ) / - col2 col1 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5880
SELECT + - CAST( + col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5880
SELECT + - CAST ( + col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT col2 * - 6 AS col1 FROM tab2 AS cor0
----
-156
-162
-228

query I rowsort
SELECT + - 88 * + ( - col0 ) FROM tab0 AS cor0
----
2112
3080
7832

query I rowsort
SELECT DISTINCT - col0 * + ( - 23 ) AS col2 FROM tab2 AS cor0
----
161
1794
1817

onlyif mysql # use DIV operator for integer division
query I rowsort label-5884
SELECT DISTINCT + col2 - 67 DIV col0 FROM tab0 cor0
----
0
31
82

skipif mysql # not compatible
query I rowsort label-5884
SELECT DISTINCT + col2 - 67 / col0 FROM tab0 cor0
----
0
31
82

query I rowsort
SELECT + col1 + + 26 AS col1 FROM tab2 AS cor0
----
43
57
85

query I rowsort
SELECT ALL - + col0 + col1 AS col2 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT col0 * - 93 FROM tab0 AS cor0
----
-2232
-3255
-8277

query I rowsort
SELECT ALL 65 + col2 AS col0 FROM tab0
----
147
66
98

query I rowsort
SELECT cor0.col0 + 38 AS col1 FROM tab1 cor0
----
102
118
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * + 51 col1 FROM tab0 AS cor0
----
-4386
-4641
-4947

query I rowsort
SELECT ALL - col2 * - col1 + col2 * col2 + + 83 FROM tab1 cor0
----
10547
3902
4403

onlyif mysql # use DIV operator for integer division
query I rowsort label-5892
SELECT DISTINCT 56 DIV col2 - col0 * 19 AS col2 FROM tab0
----
-1691
-455
-609

skipif mysql # not compatible
query I rowsort label-5892
SELECT DISTINCT 56 / col2 - col0 * 19 AS col2 FROM tab0
----
-1691
-455
-609

query I rowsort
SELECT - col1 + + tab1.col1 * + col2 FROM tab1
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-5894
SELECT - 12 DIV + 10 + col0 * - ( 35 ) FROM tab2
----
-246
-2731
-2766

skipif mysql # not compatible
query I rowsort label-5894
SELECT - 12 / + 10 + col0 * - ( 35 ) FROM tab2
----
-246
-2731
-2766

query I rowsort
SELECT - 13 * + col0 AS col1 FROM tab1
----
-1040
-39
-832

query I rowsort
SELECT DISTINCT 48 AS col2 FROM tab1, tab2, tab2 AS cor0
----
48

query I rowsort
SELECT ALL + - 83 FROM tab1 AS cor0
----
-83
-83
-83

query I rowsort
SELECT DISTINCT + 32 * + col0 AS col1 FROM tab2 AS cor0
----
224
2496
2528

query I rowsort
SELECT - 69 + col0 * - ( col2 + + col2 ) FROM tab1 AS cor0
----
-15429
-393
-7365

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5900
SELECT ALL CAST( NULL AS DECIMAL ) FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5900
SELECT ALL CAST ( NULL AS REAL ) FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 46 * + tab1.col0 FROM tab1
----
138
2944
3680

query I rowsort
SELECT DISTINCT col1 - + 96 * - col2 AS col2 FROM tab0
----
193
3254
7963

query I rowsort
SELECT 58 * col1 + tab2.col0 + 72 FROM tab2
----
1137
1877
3572

query I rowsort
SELECT + ( 26 ) * col2 + - col2 + - col0 FROM tab2
----
572
668
871

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5905
SELECT - + 6 + - col2 * CAST( NULL AS DECIMAL ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5905
SELECT - + 6 + - col2 * CAST ( NULL AS REAL ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 46 * + col0 AS col0 FROM tab1 AS cor0
----
138
2944
3680

query I rowsort
SELECT col0 * col1 * + 21 + + col2 FROM tab2
----
28241
4584
96668

query I rowsort
SELECT - col2 * col0 + col2 * 93 + - col0 * + col0 AS col0 FROM tab2
----
-5694
-5709
2273

query I rowsort
SELECT DISTINCT - col0 + col1 * + 17 AS col2 FROM tab2 AS cor0
----
210
520
925

query I rowsort
SELECT - 37 + + col0 * col2 AS col0 FROM tab1 AS cor0
----
125
3611
7643

query I rowsort
SELECT DISTINCT - ( + col0 ) * 57 FROM tab0 AS cor0
----
-1368
-1995
-5073

query I rowsort
SELECT DISTINCT 73 + - col2 AS col1 FROM tab2 AS cor0
----
35
46
47

query I rowsort
SELECT - col2 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT 10 + + cor0.col1 * - col2 FROM tab1 AS cor0
----
-1238
-1394
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-5915
SELECT col2 + - col0 DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5915
SELECT col2 + - col0 / col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col2 * col1 + - cor0.col2 + col0 * - col1 * + ( - col2 ) AS col2 FROM tab2 cor0
----
121160
51642
6669

query I rowsort
SELECT DISTINCT col2 + + col2 * - ( - col2 ) AS col1 FROM tab1 cor0
----
2970
3306
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 19 * + col0 * - cor0.col0 col2 FROM tab2 AS cor0
----
115596
118579
931

query I rowsort
SELECT ALL 72 * col2 + - tab1.col0 * 10 * - col0 FROM tab1
----
3978
45064
70912

query I rowsort
SELECT - 32 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 7106326ae056e78044adc0aef747ef08

query I rowsort
SELECT - + 79 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c9cc9510604e093bd158ca33928acaed

query I rowsort
SELECT ALL - + cor0.col0 * + col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + + col2 * col1 * 50 FROM tab0 AS cor0
----
141900
373100
4850

onlyif mysql # use DIV operator for integer division
query I rowsort label-5924
SELECT - - 46 DIV col1 AS col2 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5924
SELECT - - 46 / col1 AS col2 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT - col1 * - col0 + + col2 AS col0 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-5926
SELECT col0 * 68 DIV - col0 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
-30
-41
-42

skipif mysql # not compatible
query I rowsort label-5926
SELECT col0 * 68 / - col0 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
-30
-41
-42

query I rowsort
SELECT col2 + col0 * + 35 FROM tab2 AS cor0
----
272
2756
2803

query I rowsort
SELECT DISTINCT col2 + ( + cor0.col2 ) FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + col2 * ( cor0.col0 + col1 * ( + 62 ) ) FROM tab1 AS cor0
----
38988
85056
87210

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5930
SELECT - - col0 * CAST( col1 AS SIGNED ) * col0 + - col0 AS col0 FROM tab1 AS cor0
----
231
40896
83120

skipif mysql # not compatible
query I rowsort label-5930
SELECT - - col0 * CAST ( col1 AS INTEGER ) * col0 + - col0 AS col0 FROM tab1 AS cor0
----
231
40896
83120

query I rowsort
SELECT + col2 * 59 + col2 + col0 FROM tab0 AS cor0
----
2004
5009
95

query I rowsort
SELECT - cor0.col2 + - ( col1 ) AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT + - col0 + 10 AS col2 FROM tab1 AS cor0
----
-54
-70
7

query I rowsort
SELECT ALL - + 92 - 84 AS col1 FROM tab2 AS cor0
----
-176
-176
-176

query I rowsort
SELECT + 85 + + cor0.col0 FROM tab2 AS cor0
----
163
164
92

query I rowsort
SELECT ALL + - col1 - 61 AS col1 FROM tab1 AS cor0
----
-71
-74
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col0 + col1 col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT ALL - col2 * col0 + col2 AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL - - col1 - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 1 * col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col0 + 45 AS col0 FROM tab2 AS cor0
----
123
124
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5942
SELECT DISTINCT - CAST( cor0.col1 AS SIGNED ) + cor0.col2 AS col1 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-5942
SELECT DISTINCT - CAST ( cor0.col1 AS INTEGER ) + cor0.col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + + 49 - - col0 FROM tab1 AS cor0
----
113
129
52

query I rowsort
SELECT col1 - + cor0.col1 * ( 26 ) * col2 FROM tab2 cor0
----
-16779
-21731
-39825

query I rowsort
SELECT 42 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

onlyif mysql # use DIV operator for integer division
query I rowsort label-5946
SELECT ALL - + 10 DIV - 13 col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5946
SELECT ALL - + 10 / - 13 col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5947
SELECT DISTINCT + CAST( + col1 AS SIGNED ) + col1 FROM tab2 AS cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-5947
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) + col1 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 56 col2 FROM tab2 AS cor0
----
-1736
-3304
-952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5949
SELECT DISTINCT - col0 + CAST( + 69 AS SIGNED ) * col1 * + ( col2 ) AS col2 FROM tab0
----
195798
514789
6658

skipif mysql # not compatible
query I rowsort label-5949
SELECT DISTINCT - col0 + CAST ( + 69 AS INTEGER ) * col1 * + ( col2 ) AS col2 FROM tab0
----
195798
514789
6658

onlyif mysql # use DIV operator for integer division
query I rowsort label-5950
SELECT DISTINCT col1 + col1 + - col1 DIV col0 FROM tab2
----
118
34
58

skipif mysql # not compatible
query I rowsort label-5950
SELECT DISTINCT col1 + col1 + - col1 / col0 FROM tab2
----
118
34
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5951
SELECT - 70 + col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
-70
-70
-70

skipif mysql # not compatible
query I rowsort label-5951
SELECT - 70 + col0 / - col1 AS col0 FROM tab0 AS cor0
----
-70
-70
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 30 + col0 * - 67 col1 FROM tab0 AS cor0
----
-3233
565
972

query I rowsort
SELECT ( cor0.col0 ) FROM tab0, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 17 col2 FROM tab2 cor0
----
17
17
17

query I rowsort
SELECT - 28 * col1 - - cor0.col0 * + 16 FROM tab0 AS cor0
----
-1124
-2024
-2156

query I rowsort
SELECT + - cor0.col1 - + col1 * - col0 * + ( col1 + + col1 ) AS col0 FROM tab2 AS cor0
----
13423
45645
542977

query I rowsort
SELECT ALL - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT 96 * - col0 AS col1 FROM tab2 AS cor0
----
-672
-7488
-7584

query I rowsort
SELECT cor0.col0 * cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to e1120e7b687b32270ef70393236e7341

query I rowsort
SELECT + col0 * 73 FROM tab0 cor0
----
1752
2555
6497

query I rowsort
SELECT col2 * + 51 + 22 AS col2 FROM tab1 AS cor0
----
2776
2929
4918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5962
SELECT cor0.col0 + CAST( NULL AS DECIMAL ) * + col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5962
SELECT cor0.col0 + CAST ( NULL AS REAL ) * + col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 + 7 FROM tab0 cor0
----
40
8
89

query I rowsort
SELECT ALL cor0.col0 * + cor0.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 815fccd4c3d372b28d3f3fb103025775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 42 col0 FROM tab0 AS cor0
----
1008
1470
3738

query I rowsort
SELECT ALL cor0.col1 * cor0.col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL col1 * + col2 + - cor0.col1 FROM tab2 AS cor0
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5968
SELECT ALL + col0 + 95 * col2 + CAST( col1 * col2 AS SIGNED ) col2 FROM tab1 AS cor0
----
10448
6049
6537

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5968
SELECT ALL + col0 + 95 * col2 + CAST ( col1 * col2 AS INTEGER ) col2 FROM tab1 AS cor0
----
10448
6049
6537

query I rowsort
SELECT - + 79 + col0 AS col2 FROM tab1 cor0
----
-15
-76
1

query I rowsort
SELECT - ( - ( - col2 ) ) + + col0 - ( col0 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5971
SELECT DISTINCT col0 DIV col2 AS col2 FROM tab0 cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5971
SELECT DISTINCT col0 / col2 AS col2 FROM tab0 cor0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + 52 col0 FROM tab2 AS cor0
----
-1352
-1404
-1976

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5973
SELECT + + col0 * - col0 + - col2 * ( col2 ) * col1 - CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5973
SELECT + + col0 * - col0 + - col2 * ( col2 ) * col1 - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 83 * + cor0.col0 + + col2 FROM tab1 AS cor0
----
-195
-5255
-6544

query I rowsort
SELECT ALL - col1 + + cor0.col2 * + col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT ALL - + cor0.col1 + cor0.col0 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + ( - col0 + - tab2.col2 * col2 ) AS col1 FROM tab2
----
-1523
-736
-754

query I rowsort
SELECT DISTINCT col1 * - col1 + col1 AS col2 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL - + col1 - - 32 AS col1 FROM tab2 AS cor0
----
-27
1
15

query I rowsort
SELECT DISTINCT - - col0 * 2 AS col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - tab1.col0 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5982
SELECT DISTINCT - col2 * + CAST( NULL AS SIGNED ) + cor0.col0 AS col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5982
SELECT DISTINCT - col2 * + CAST ( NULL AS INTEGER ) + cor0.col0 AS col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT + + col1 + col2 * col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + col1 + 74 FROM tab0 AS cor0
----
160
165
171

query I rowsort
SELECT ALL cor0.col0 + 99 AS col1 FROM tab0 AS cor0
----
123
134
188

query I rowsort
SELECT ALL cor0.col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL 22 + + col1 AS col2 FROM tab0
----
108
113
119

onlyif mysql # use DIV operator for integer division
query I rowsort label-5988
SELECT ALL + CAST( 91 AS SIGNED ) DIV cor0.col2 - - col2 col0 FROM tab1 AS cor0
----
55
58
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5988
SELECT ALL + CAST ( 91 AS INTEGER ) / cor0.col2 - - col2 col0 FROM tab1 AS cor0
----
55
58
96

query I rowsort
SELECT + 73 * col2 - col0 AS col2 FROM tab0 AS cor0
----
2385
38
5897

query I rowsort
SELECT - + col2 * - col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 96 + col2 col0 FROM tab0 AS cor0
----
129
178
97

query I rowsort
SELECT ( 80 ) FROM tab2 AS cor0
----
80
80
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5993
SELECT ALL + - CAST( col1 AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-5993
SELECT ALL + - CAST ( col1 AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - - 77 + + 67 FROM tab0 cor0
----
144

query I rowsort
SELECT DISTINCT - 54 * - col1 + col0 FROM tab2 AS cor0
----
1681
3264
997

query I rowsort
SELECT ALL - ( 48 ) + - col1 FROM tab0 cor0
----
-134
-139
-145

query I rowsort
SELECT - col0 * - col2 * col2 + - ( + 29 ) AS col1 FROM tab0 AS cor0
----
26107
598407
6

query I rowsort
SELECT ALL - - cor0.col0 + - 95 FROM tab2 AS cor0
----
-16
-17
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - 62 col2 FROM tab0 AS cor0
----
2046
5084
62

query I rowsort
SELECT - ( col2 ) * + col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + col2 + col2 * col1 * + col2 + + cor0.col2 * col2 AS col2 FROM tab2 AS cor0
----
23355
26030
40586

query I rowsort
SELECT DISTINCT - col1 * col2 + cor0.col2 FROM tab0 cor0
----
-2805
-7380
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - col2 * col1 col2 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6004
SELECT ALL - ( col1 ) DIV + tab0.col2 + 72 FROM tab0
----
-25
70
71

skipif mysql # not compatible
query I rowsort label-6004
SELECT ALL - ( col1 ) / + tab0.col2 + 72 FROM tab0
----
-25
70
71

query I rowsort
SELECT + 29 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL col2 * col2 + + tab0.col1 FROM tab0
----
1175
6815
98

query I rowsort
SELECT DISTINCT 62 + + 66 AS col1 FROM tab1
----
128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + 19 col1 FROM tab1
----
29
32
45

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + + col2 + - 51 AS col1 FROM tab2 AS cor0
----
-13
-24
-25

query I rowsort
SELECT - col0 * + 86 AS col1 FROM tab1 AS cor0
----
-258
-5504
-6880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 + col0 col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL + col1 + ( col0 ) AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - col0 + 67 * - col1 FROM tab2 AS cor0
----
-1218
-2084
-4031

query I rowsort
SELECT + + col2 * - col2 * - col2 AS col0 FROM tab1 AS cor0
----
157464
185193
884736

onlyif mysql # use DIV operator for integer division
query I rowsort label-6016
SELECT ALL + cor0.col0 DIV 73 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-6016
SELECT ALL + cor0.col0 / 73 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

onlyif mysql # use DIV operator for integer division
query I rowsort label-6017
SELECT ALL + 32 DIV col0 FROM tab1
----
0
0
10

skipif mysql # not compatible
query I rowsort label-6017
SELECT ALL + 32 / col0 FROM tab1
----
0
0
10

query I rowsort
SELECT ALL 36 FROM tab1, tab0 cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6019
SELECT ALL col2 + + CAST( NULL AS SIGNED ) / + cor0.col2 + col0 / + 45 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6019
SELECT ALL col2 + + CAST ( NULL AS INTEGER ) / + cor0.col2 + col0 / + 45 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col1 * - 78 - col1 AS col0 FROM tab1 cor0
----
-1027
-2054
-790

query I rowsort
SELECT col1 * - col1 - 79 FROM tab2 AS cor0
----
-1040
-3560
-368

query I rowsort
SELECT DISTINCT cor0.col2 * - ( col0 ) * col2 + + col2 * 9 * - col2 AS col1 FROM tab2 AS cor0
----
-11664
-127072
-58812

query I rowsort
SELECT DISTINCT - - cor0.col1 - col2 AS col2 FROM tab1 cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 + CAST ( + cor0.col0 AS REAL ) FROM tab0 AS cor0
----
171
36
57

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 cor1, tab1 AS cor2
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

onlyif mysql # use DIV operator for integer division
query I rowsort label-6026
SELECT col1 * ( + 43 ) DIV + col0 + - 53 FROM tab0
----
-10
101
66

skipif mysql # not compatible
query I rowsort label-6026
SELECT col1 * ( + 43 ) / + col0 + - 53 FROM tab0
----
-10
101
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-6027
SELECT + col1 + + col1 DIV col0 col1 FROM tab0
----
89
92
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6027
SELECT + col1 + + col1 / col0 col1 FROM tab0
----
89
92
99

query I rowsort
SELECT - - ( col0 ) + cor0.col1 + col2 FROM tab1 AS cor0
----
131
189
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6029
SELECT + ( cor0.col0 ) DIV col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6029
SELECT + ( cor0.col0 ) / col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + col2 * ( tab2.col2 + - col0 ) * - 32 AS col0 FROM tab2
----
-17280
43264
49856

query I rowsort
SELECT - - col0 * 19 FROM tab1 AS cor0
----
1216
1520
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) * - col2 col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL - + col1 * - col2 * - col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT 94 * - 69 * col2 AS col2 FROM tab1
----
-350244
-369702
-622656

onlyif mysql # use DIV operator for integer division
query I rowsort label-6035
SELECT - + 38 DIV col0 + - col2 - - col1 * - ( - col2 ) FROM tab1 AS cor0
----
1152
1338
513

skipif mysql # not compatible
query I rowsort label-6035
SELECT - + 38 / col0 + - col2 - - col1 * - ( - col2 ) FROM tab1 AS cor0
----
1152
1338
513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6036
SELECT + CAST( NULL AS SIGNED ) * + col1 - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6036
SELECT + CAST ( NULL AS INTEGER ) * + col1 - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6037
SELECT + CAST( + col1 AS SIGNED ) * + col1 - + 14 * - col0 AS col1 FROM tab0 AS cor0
----
7732
9527
9899

skipif mysql # not compatible
query I rowsort label-6037
SELECT + CAST ( + col1 AS INTEGER ) * + col1 - + 14 * - col0 AS col1 FROM tab0 AS cor0
----
7732
9527
9899

query I rowsort
SELECT DISTINCT + - 32 + + 72 AS col2 FROM tab2 AS cor0
----
40

query I rowsort
SELECT DISTINCT col0 * ( cor0.col1 ) + - ( ( + col2 ) ) * col1 AS col2 FROM tab1 cor0
----
-1326
-208
70

query I rowsort
SELECT col2 + 60 * - col1 - 69 AS col0 FROM tab1 AS cor0
----
-1575
-612
-753

query I rowsort
SELECT ALL + cor0.col2 + 85 FROM tab2 AS cor0
----
111
112
123

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - 18 - col1 col0 FROM tab2 AS cor0
----
-42
1
44

query I rowsort
SELECT - - ( 75 ) * col2 AS col0 FROM tab2 cor0
----
1950
2025
2850

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( cor0.col2 ) col0 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - 93 + col1 AS col0 FROM tab0 cor0
----
-2
-7
4

query I rowsort
SELECT ALL - cor0.col2 + - cor0.col1 * - col2 AS col0 FROM tab1 cor0
----
1152
1350
513

query I rowsort
SELECT ALL - - col0 * col1 + + col1 * col2 AS col2 FROM tab1 AS cor0
----
1210
1482
2288

onlyif mysql # use DIV operator for integer division
query I rowsort label-6048
SELECT ALL + col2 DIV + col0 + col1 FROM tab1 AS cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-6048
SELECT ALL + col2 / + col0 + col1 FROM tab1 AS cor0
----
10
14
44

query I rowsort
SELECT - cor0.col1 + + ( 89 ) * - col0 AS col0 FROM tab1 AS cor0
----
-293
-5706
-7133

query I rowsort
SELECT col2 * + col2 + - 56 FROM tab0 AS cor0
----
-55
1033
6668

onlyif mysql # use DIV operator for integer division
query I rowsort label-6051
SELECT DISTINCT - col1 + + col0 DIV + 59 col1 FROM tab2 AS cor0
----
-16
-31
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6051
SELECT DISTINCT - col1 + + col0 / + 59 col1 FROM tab2 AS cor0
----
-16
-31
-58

query I rowsort
SELECT DISTINCT + col2 - + col2 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT tab0.col2 * tab0.col1 * - col0 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT - col1 + ( + col1 ) AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 78 col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6056
SELECT ALL + CAST( NULL AS SIGNED ) + 23 + + cor1.col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6056
SELECT ALL + CAST ( NULL AS INTEGER ) + 23 + + cor1.col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - 66 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 cor2
----
81 values hashing to 18b0c368baac0e3433d1e072f8b49f81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 20 * - cor0.col0 col1 FROM tab2 cor0
----
-140
-1560
-1580

query I rowsort
SELECT + - col0 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-6060
SELECT DISTINCT + col1 DIV 90 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-6060
SELECT DISTINCT + col1 / 90 FROM tab1
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6061
SELECT + CAST( NULL AS SIGNED ) * col0 + + col0 / - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6061
SELECT + CAST ( NULL AS INTEGER ) * col0 + + col0 / - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 94 col2 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT DISTINCT 61 * - col1 * col2 FROM tab0
----
-173118
-455182
-5917

query I rowsort
SELECT ALL 19 * col0 FROM tab0
----
1691
456
665

query I rowsort
SELECT DISTINCT - col2 * col1 * + col2 AS col2 FROM tab0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col1 * - col0 ) col0 FROM tab1
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6067
SELECT + ( - col1 ) * + col2 + + CAST( NULL AS SIGNED ) * - 68 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6067
SELECT + ( - col1 ) * + col2 + + CAST ( NULL AS INTEGER ) * - 68 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 32 * col0 FROM tab0 AS cor0
----
1120
2848
768

query I rowsort
SELECT + 55 * + 83 FROM tab0 AS cor0
----
4565
4565
4565

query I rowsort
SELECT - ( - col2 ) + - col1 * + col1 + 95 * - col1 AS col0 FROM tab0 AS cor0
----
-15533
-16844
-18623

query I rowsort
SELECT + - 36 + col1 * col0 AS col1 FROM tab1 AS cor0
----
1004
42
604

query I rowsort
SELECT + col2 + ( tab0.col1 ) * + col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT 90 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT DISTINCT col2 + + 43 AS col2 FROM tab0
----
125
44
76

query I rowsort
SELECT ALL + 83 AS col1 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT 5 * cor0.col2 * - col2 AS col1 FROM tab2 AS cor0
----
-3380
-3645
-7220

query I rowsort
SELECT DISTINCT + 26 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
26

query I rowsort
SELECT DISTINCT 41 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
14
15
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 31 * + cor0.col1 * + col0 col0 FROM tab0 AS cor0
----
105245
251069
63984

query I rowsort
SELECT DISTINCT - col1 - 72 AS col0 FROM tab2
----
-103
-131
-89

query I rowsort
SELECT ALL + tab0.col0 + + col1 * - col1 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT - ( 86 ) FROM tab2, tab1 AS cor0
----
9 values hashing to 9ac806793c03d3a6b5e3a3029d20e4da

query I rowsort
SELECT + col2 + - col2 - + ( tab1.col0 ) AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + col0 - ( - col2 ) FROM tab2
----
104
117
34

query I rowsort
SELECT col1 * 50 + ( col0 * 67 ) FROM tab1
----
1501
4788
6010

query I rowsort
SELECT - cor0.col0 * - col1 - - col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL - col0 + - 77 AS col0 FROM tab2 AS cor0
----
-155
-156
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col1 ) + col1 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 82 * 39 + col2 * col2 * - col0 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-204748
-5576
-734095

query I rowsort
SELECT DISTINCT - 25 + - 64 * col1 AS col2 FROM tab1 AS cor0
----
-1689
-665
-857

query I rowsort
SELECT - cor0.col0 + col0 * - col1 AS col2 FROM tab1 cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL ( col0 ) * - col2 FROM tab2 cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 68 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT col1 * + col2 * ( col1 * + col0 ) AS col2 FROM tab1
----
109512
1297920
364800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6095
SELECT - - CAST( NULL AS SIGNED ) * col0 + col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6095
SELECT - - CAST ( NULL AS INTEGER ) * col0 + col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col2 * - 94 FROM tab2, tab0, tab0 cor0
----
-3102
-7708
-94

query I rowsort
SELECT DISTINCT + 54 FROM tab2, tab2 AS cor0
----
54

query I rowsort
SELECT ALL - 5 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 263f0eb7d5dfd4076c74918bc141bd9b

query I rowsort
SELECT col0 + 96 FROM tab0 AS cor0
----
120
131
185

onlyif mysql # use DIV operator for integer division
query I rowsort label-6101
SELECT ALL cor0.col0 DIV 59 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6101
SELECT ALL cor0.col0 / 59 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + 0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 cor2
----
0

query I rowsort
SELECT ALL - col0 * - 57 FROM tab1 AS cor0
----
171
3648
4560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6104
SELECT - + ( 82 ) DIV col1 AS col1 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-6104
SELECT - + ( 82 ) / col1 AS col1 FROM tab2 AS cor0
----
-1
-2
-4

query I rowsort
SELECT DISTINCT + 37 + 46 * + col2 FROM tab2 AS cor0
----
1233
1279
1785

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6106
SELECT DISTINCT + + col1 + col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6106
SELECT DISTINCT + + col1 + col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 + col0 * col0 col2 FROM tab2 cor0
----
22
6058
6203

query I rowsort
SELECT ALL - 0 * + cor0.col1 + + ( col2 ) * col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6109
SELECT DISTINCT + + 60 + + col1 DIV - col2 AS col0 FROM tab1 AS cor0
----
60

skipif mysql # not compatible
query I rowsort label-6109
SELECT DISTINCT + + 60 + + col1 / - col2 AS col0 FROM tab1 AS cor0
----
60

query I rowsort
SELECT ALL - 99 + - col2 AS col2 FROM tab1 AS cor0
----
-153
-156
-195

query I rowsort
SELECT 42 + col0 FROM tab0 AS cor0
----
131
66
77

query I rowsort
SELECT DISTINCT + + col0 * - col0 + 80 * col1 * - col1 AS col2 FROM tab1 AS cor0
----
-12096
-19920
-54089

query I rowsort
SELECT ALL 28 + col2 FROM tab2 cor0
----
54
55
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-6114
SELECT ALL col2 DIV - col2 + - 11 * - col1 AS col2 FROM tab1 AS cor0
----
109
142
285

skipif mysql # not compatible
query I rowsort label-6114
SELECT ALL col2 / - col2 + - 11 * - col1 AS col2 FROM tab1 AS cor0
----
109
142
285

query I rowsort
SELECT DISTINCT + col0 * col0 * col0 + - 23 AS col0 FROM tab2 AS cor0
----
320
474529
493016

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6116
SELECT col1 + - CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6116
SELECT col1 + - CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + - col2 col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT col0 * 38 AS col2 FROM tab2 cor0
----
266
2964
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6119
SELECT - col2 * 48 DIV col1 AS col1 FROM tab1 AS cor0
----
-273
-354
-99

skipif mysql # not compatible
query I rowsort label-6119
SELECT - col2 * 48 / col1 AS col1 FROM tab1 AS cor0
----
-273
-354
-99

query I rowsort
SELECT ALL + col1 + - 84 AS col0 FROM tab1 AS cor0
----
-58
-71
-74

query I rowsort
SELECT + col1 + cor0.col1 AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + cor0.col0 * + 78 AS col1 FROM tab0 AS cor0
----
1872
2730
6942

query I rowsort
SELECT ALL col0 + ( + cor0.col1 ) * + col2 * - cor0.col1 AS col2 FROM tab2 cor0
----
-10903
-25940
-90428

onlyif mysql # use DIV operator for integer division
query I rowsort label-6124
SELECT + + col1 * 17 DIV - 82 AS col0 FROM tab1 cor0
----
-2
-2
-5

skipif mysql # not compatible
query I rowsort label-6124
SELECT + + col1 * 17 / - 82 AS col0 FROM tab1 cor0
----
-2
-2
-5

query I rowsort
SELECT - col2 + - 12 FROM tab1
----
-108
-66
-69

query I rowsort
SELECT 5 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT + col1 * + col1 + + ( - cor0.col1 ) * col0 FROM tab0 AS cor0
----
182
5332
6014

query I rowsort
SELECT + cor0.col1 + + cor0.col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - ( col1 ) + cor0.col2 * + col1 FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT + col2 + - col0 + tab2.col1 AS col1 FROM tab2
----
-24
51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6131
SELECT CAST( col0 AS SIGNED ) * - col2 AS col2 FROM tab1
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-6131
SELECT CAST ( col0 AS INTEGER ) * - col2 AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT + col1 * - col1 + col2 * 14 * - col2 FROM tab0 AS cor0
----
-102417
-22642
-9423

onlyif mysql # use DIV operator for integer division
query I rowsort label-6133
SELECT 86 DIV col1 + col0 AS col1 FROM tab1 cor0
----
6
72
86

skipif mysql # not compatible
query I rowsort label-6133
SELECT 86 / col1 + col0 AS col1 FROM tab1 cor0
----
6
72
86

query I rowsort
SELECT - + 93 * - col1 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
1660
2890
5565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6135
SELECT DISTINCT - CAST( NULL AS SIGNED ) + tab1.col2 * - tab1.col2 * - col1 AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6135
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + tab1.col2 * - tab1.col2 * - col1 AS col2 FROM tab1
----
NULL

query I rowsort
SELECT ALL - ( - col1 ) + - col1 * - tab2.col0 AS col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL col2 * + 17 + col0 * ( - col1 ) AS col0 FROM tab2
----
-4160
-697
242

onlyif mysql # use DIV operator for integer division
query I rowsort label-6138
SELECT ( - ( col2 ) ) + - 96 DIV col1 AS col0 FROM tab0
----
-1
-34
-83

skipif mysql # not compatible
query I rowsort label-6138
SELECT ( - ( col2 ) ) + - 96 / col1 AS col0 FROM tab0
----
-1
-34
-83

query I rowsort
SELECT ALL - - cor0.col2 + col2 AS col2 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col1 col0 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + col0 - - col1 * + col1 AS col1 FROM tab0 cor0
----
7420
8370
9444

query I rowsort
SELECT + 74 + col1 AS col2 FROM tab2 AS cor0
----
105
133
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6143
SELECT + + CAST( NULL AS SIGNED ) * 11 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6143
SELECT + + CAST ( NULL AS INTEGER ) * 11 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + 63 + + col2 * 43 FROM tab1 AS cor0
----
2385
2514
4191

query I rowsort
SELECT + col2 * + col0 * - col1 + ( - tab0.col0 ) * col0 * tab0.col1 FROM tab0
----
-117648
-122220
-1384929

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - + col1 * col1 col1 FROM tab0
----
-7482
-8372
-9506

query I rowsort
SELECT DISTINCT - 22 AS col2 FROM tab2, tab1 cor0
----
-22

query I rowsort
SELECT - 89 * cor0.col2 + 53 FROM tab0, tab1 AS cor0
----
9 values hashing to 1ceed7cade83616a3905ff6f451cf0f5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col0 * + cor0.col1 col2 FROM tab1 AS cor0
----
24
583
944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col1 ) col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT + col1 + - cor0.col2 * 78 AS col1 FROM tab1 cor0
----
-4186
-4436
-7475

query I rowsort
SELECT + + col2 + + col0 * + 7 * + 41 AS col1 FROM tab2 AS cor0
----
2036
22412
22711

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - cor0.col0 col1 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT - - 54 * col0 FROM tab1 AS cor0
----
162
3456
4320

query I rowsort
SELECT - 92 + col2 * + col1 FROM tab1 cor0
----
1156
1312
478

query I rowsort
SELECT ALL + ( - col2 ) * - cor0.col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - + 16 FROM tab2 AS cor0
----
-16
-16
-16

onlyif mysql # use DIV operator for integer division
query I rowsort label-6158
SELECT col0 + - col1 DIV col0 FROM tab1 AS cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-6158
SELECT col0 + - col1 / col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT ALL - 85 + + col2 FROM tab2 AS cor0
----
-47
-58
-59

query I rowsort
SELECT ALL + - ( - 7 ) * col1 AS col2 FROM tab1 AS cor0
----
182
70
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-6161
SELECT ALL + 12 * - col2 + col1 DIV + cor0.col2 + + cor0.col2 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-486
2964
6528

skipif mysql # not compatible
query I rowsort label-6161
SELECT ALL + 12 * - col2 + col1 / + cor0.col2 + + cor0.col2 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-486
2964
6528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) col1 FROM tab2, tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6163
SELECT DISTINCT CAST( NULL AS SIGNED ) + + 16 FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6163
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + 16 FROM tab0, tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL 86 * - col0 + - col0 FROM tab1 AS cor0
----
-261
-5568
-6960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6165
SELECT DISTINCT + CAST( col1 AS SIGNED ) * - col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-6165
SELECT DISTINCT + CAST ( col1 AS INTEGER ) * - col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6166
SELECT + + CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6166
SELECT + + CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( col1 ) * col1 + - 81 FROM tab0 AS cor0
----
7315
8200
9328

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 + - col2 col0 FROM tab1 AS cor0
----
-29
10
13

query I rowsort
SELECT ALL - 46 - 90 FROM tab0 AS cor0
----
-136
-136
-136

query I rowsort
SELECT ( cor0.col1 ) + + col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL col1 * + col2 + - cor0.col1 AS col0 FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT + + 0 + 11 FROM tab0 AS cor0
----
11
11
11

query I rowsort
SELECT DISTINCT + 49 + cor0.col0 FROM tab1 AS cor0
----
113
129
52

query I rowsort
SELECT DISTINCT 79 FROM tab1, tab1 AS cor0
----
79

query I rowsort
SELECT DISTINCT + col2 * 86 AS col1 FROM tab1 cor0
----
4644
4902
8256

onlyif mysql # use DIV operator for integer division
query I rowsort label-6176
SELECT col0 * 51 + + col1 DIV col0 + + col0 FROM tab2 AS cor0
----
368
4056
4108

skipif mysql # not compatible
query I rowsort label-6176
SELECT col0 * 51 + + col1 / col0 + + col0 FROM tab2 AS cor0
----
368
4056
4108

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 49 col0 FROM tab0 cor0
----
49
49
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-6178
SELECT DISTINCT - 90 DIV - col0 + 95 FROM tab1 AS cor0
----
125
96

skipif mysql # not compatible
query I rowsort label-6178
SELECT DISTINCT - 90 / - col0 + 95 FROM tab1 AS cor0
----
125
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6179
SELECT + ( - col0 ) * col2 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6179
SELECT + ( - col0 ) * col2 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 22 + + col0 * col1 AS col2 FROM tab1 AS cor0
----
100
1062
662

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col0 + + cor0.col1 * + col2 + CAST ( - col2 AS REAL ) * - col1 AS col1 FROM tab1 AS cor0
----
1204
2576
2811

onlyif mysql # use DIV operator for integer division
query I rowsort label-6182
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-6182
SELECT ALL + col2 / col2 col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - col1 * - 74 + + cor0.col0 FROM tab0 AS cor0
----
6388
6823
7213

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + 1 col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT col2 + ( - ( - col0 ) ) * col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + 10 * cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 41bb55132a35faf7962d281277863aaa

onlyif mysql # use DIV operator for integer division
query I rowsort label-6187
SELECT col2 DIV 4 FROM tab1
----
13
14
24

skipif mysql # not compatible
query I rowsort label-6187
SELECT col2 / 4 FROM tab1
----
13
14
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-6188
SELECT - col2 * + col0 + col2 DIV col2 + col0 * tab0.col0 AS col2 FROM tab0
----
-215
1191
624

skipif mysql # not compatible
query I rowsort label-6188
SELECT - col2 * + col0 + col2 / col2 + col0 * tab0.col0 AS col2 FROM tab0
----
-215
1191
624

query I rowsort
SELECT + - cor0.col2 - + col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT + col1 - + 0 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT col0 - ( col2 + + tab1.col1 ) AS col1 FROM tab1
----
-29
-3
-77

skipif mysql # not compatible
query I rowsort
SELECT - tab2.col0 + - CAST ( + col1 AS REAL ) + + col0 AS col1 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT col1 - + col1 * col0 FROM tab2 AS cor0
----
-1326
-186
-4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * 75 col0 FROM tab0 AS cor0
----
2475
6150
75

query I rowsort
SELECT ALL - 30 * - col0 AS col0 FROM tab0 AS cor0
----
1050
2670
720

query I rowsort
SELECT + 20 * col1 * col2 FROM tab2 AS cor0
----
12920
16740
30680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 + col0 col1 FROM tab0
----
147
82
93

query I rowsort
SELECT DISTINCT 41 * + col2 FROM tab1
----
2214
2337
3936

query I rowsort
SELECT DISTINCT 0 * + col2 AS col1 FROM tab2
----
0

query I rowsort
SELECT ALL + cor0.col2 * - 36 FROM tab2, tab2 AS cor0
----
9 values hashing to de5cdc6ee0be92ea33d4167656eb2de6

query I rowsort
SELECT DISTINCT - - 46 * - col0 * col0 AS col2 FROM tab2 AS cor0
----
-2254
-279864
-287086

query I rowsort
SELECT DISTINCT 24 - col0 AS col2 FROM tab0 AS cor0
----
-11
-65
0

query I rowsort
SELECT ALL - + col1 + + col0 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL - 41 AS col2 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 47b9ef972839428f4f71d9f5b0944edf

query I rowsort
SELECT ALL - col1 + 24 AS col2 FROM tab2
----
-35
-7
7

query I rowsort
SELECT + 77 AS col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT col1 * 87 AS col2 FROM tab0
----
7482
7917
8439

query I rowsort
SELECT ALL - 81 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

query I rowsort
SELECT DISTINCT cor0.col1 * ( - col1 ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL col0 * 59 AS col1 FROM tab2 AS cor0
----
413
4602
4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6211
SELECT DISTINCT - CAST( NULL AS SIGNED ) * - col1 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6211
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * - col1 AS col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6212
SELECT DISTINCT - - cor0.col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-6212
SELECT DISTINCT - - cor0.col1 / - col1 AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT ALL - - ( + 10 ) FROM tab1 AS cor0
----
10
10
10

query I rowsort
SELECT ALL col2 * 45 * col0 FROM tab0 AS cor0
----
1575
328410
35640

query I rowsort
SELECT - - 39 * - cor0.col2 + cor0.col2 + 55 FROM tab0 AS cor0
----
-1199
-3061
17

query I rowsort
SELECT ( col1 ) * col2 + col2 + - col1 FROM tab2 AS cor0
----
1501
667
833

query I rowsort
SELECT + 90 * + col0 AS col1 FROM tab1 AS cor0
----
270
5760
7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-6218
SELECT ALL + 17 DIV 65 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6218
SELECT ALL + 17 / 65 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * col0 + + col2 * - cor0.col0 col2 FROM tab0 AS cor0
----
1272
3360
801

query I rowsort
SELECT DISTINCT + - col0 + ( cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6221
SELECT CAST( NULL AS SIGNED ) * - col2 + - col2 + 99 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6221
SELECT CAST ( NULL AS INTEGER ) * - col2 + - col2 + 99 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * + ( + col0 * - ( - cor0.col2 ) ) FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT tab1.col1 + ( col1 ) * + col2 AS col2 FROM tab1
----
1261
1430
580

query I rowsort
SELECT DISTINCT + cor0.col0 * col1 + + col1 * + col2 AS col2 FROM tab1 AS cor0
----
1210
1482
2288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * ( cor0.col0 ) * col2 col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT ALL cor0.col2 * + col0 + + cor0.col0 + 44 AS col0 FROM tab2 AS cor0
----
2150
240
3125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * + ( + col0 ) col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - - ( + 88 ) FROM tab2 AS cor0
----
88
88
88

query I rowsort
SELECT 57 * col0 + - col2 + 82 FROM tab1 AS cor0
----
199
3673
4546

query I rowsort
SELECT ALL + col2 * + cor0.col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL 33 AS col1 FROM tab1 AS cor0
----
33
33
33

query I rowsort
SELECT DISTINCT + cor0.col0 + + cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
110
132
180

query I rowsort
SELECT cor0.col0 + - 39 * - col1 AS col2 FROM tab2 AS cor0
----
1216
2379
742

query I rowsort
SELECT + 83 + 9 FROM tab2 cor0
----
92
92
92

query I rowsort
SELECT ALL + 55 AS col1 FROM tab0 AS cor0
----
55
55
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + 27 + col2 FROM tab1 AS cor0
----
123
81
84

query I rowsort
SELECT 54 * cor0.col1 + col2 AS col2 FROM tab2 AS cor0
----
1701
3212
956

onlyif mysql # use DIV operator for integer division
query I rowsort label-6239
SELECT ALL col1 * col0 DIV col0 AS col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6239
SELECT ALL col1 * col0 / col0 AS col1 FROM tab2
----
17
31
59

query I rowsort
SELECT - col0 - - col1 AS col2 FROM tab1 cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-6241
SELECT - + col2 - col1 DIV - col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6241
SELECT - + col2 - col1 / - col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + cor0.col0 * + 69 + + cor0.col1 FROM tab1 AS cor0
----
233
4426
5533

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - 95 + col0 col1 FROM tab0 cor0
----
-3111
-60
-7701

query I rowsort
SELECT ALL + + col0 + - 70 AS col0 FROM tab0 AS cor0
----
-35
-46
19

query I rowsort
SELECT + col0 + + ( + col0 ) FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL - col1 - 39 FROM tab2 AS cor0
----
-56
-70
-98

query I rowsort
SELECT DISTINCT - tab0.col0 - + tab0.col1 AS col1 FROM tab0
----
-110
-132
-180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6248
SELECT DISTINCT col2 - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6248
SELECT DISTINCT col2 - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query I rowsort
SELECT cor0.col1 * + ( col0 ) + - col2 + - col2 AS col1 FROM tab0 AS cor0
----
1998
3393
7935

query I rowsort
SELECT + col1 * col1 + - col1 * - col0 + - col1 FROM tab2 AS cor0
----
1147
1615
8024

query I rowsort
SELECT ALL - col0 - + col1 * col2 AS col1 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT + col0 - ( col2 ) * + col2 AS col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 + CAST ( + col0 * col2 AS REAL ) + col1 FROM tab0 cor0
----
133
7471
911

onlyif mysql # use DIV operator for integer division
query I rowsort label-6254
SELECT ALL + - col0 - + 68 DIV col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-6254
SELECT ALL + - col0 - + 68 / col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + col1 + - 72 FROM tab2 AS cor0
----
-13
-41
-55

query I rowsort
SELECT DISTINCT - col1 + - 86 * 80 * col1 FROM tab2
----
-116977
-213311
-405979

query I rowsort
SELECT col1 * + ( ( col1 ) + - col0 ) FROM tab2
----
-1054
-1121
744

query I rowsort
SELECT - col2 + 19 * col1 FROM tab0 AS cor0
----
1601
1647
1842

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6259
SELECT ALL col0 * + CAST( - col2 AS SIGNED ) FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-6259
SELECT ALL col0 * + CAST ( - col2 AS INTEGER ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col0 * + tab0.col1 AS col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + col2 * col0 * 55 FROM tab2 AS cor0
----
10395
111540
165110

query I rowsort
SELECT 51 * - col1 AS col2 FROM tab2
----
-1581
-3009
-867

query I rowsort
SELECT - - col0 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - cor0.col1 * ( 88 ) FROM tab2 AS cor0
----
-1496
-2728
-5192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - + tab0.col2 col1 FROM tab0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6266
SELECT ALL - - cor0.col2 DIV 27 AS col1 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6266
SELECT ALL - - cor0.col2 / 27 AS col1 FROM tab2 AS cor0
----
0
1
1

query I rowsort
SELECT + col2 * + 41 FROM tab0 AS cor0
----
1353
3362
41

query I rowsort
SELECT - - cor0.col1 * ( - col2 ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + cor0.col2 * + 77 AS col2 FROM tab2 AS cor0
----
2002
2079
2926

query I rowsort
SELECT - col2 + cor0.col1 * + 56 FROM tab1 cor0
----
1402
503
632

query I rowsort
SELECT + col0 + col2 * - col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT - 77 * - col0 AS col0 FROM tab2
----
539
6006
6083

query I rowsort
SELECT - col1 * col0 * - col2 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + + 62 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-18
-2
59

query I rowsort
SELECT + ( + col1 ) - col2 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - + 52 * col0 FROM tab1 AS cor0
----
-156
-3328
-4160

query I rowsort
SELECT col1 * col0 + 80 AS col2 FROM tab2 AS cor0
----
1423
297
4682

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6278
SELECT - col2 * - col1 - CAST( 3 AS SIGNED ) * col2 AS col0 FROM tab1 AS cor0
----
1242
399
960

skipif mysql # not compatible
query I rowsort label-6278
SELECT - col2 * - col1 - CAST ( 3 AS INTEGER ) * col2 AS col0 FROM tab1 AS cor0
----
1242
399
960

query I rowsort
SELECT ALL + + cor0.col2 * col0 - col2 AS col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT 40 + col2 AS col2 FROM tab0 AS cor0
----
122
41
73

query I rowsort
SELECT - ( + col2 ) + col2 AS col0 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6282
SELECT 93 DIV tab0.col1 AS col2 FROM tab0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6282
SELECT 93 / tab0.col1 AS col2 FROM tab0
----
0
1
1

query I rowsort
SELECT cor0.col0 * - col1 + 39 AS col1 FROM tab2 AS cor0
----
-1304
-178
-4563

query I rowsort
SELECT ALL - 90 * col2 + 1 AS col1 FROM tab2 AS cor0
----
-2339
-2429
-3419

query I rowsort
SELECT - - 32 AS col1 FROM tab0 AS cor0
----
32
32
32

query I rowsort
SELECT DISTINCT col2 * col0 + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6287
SELECT + 16 - col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6287
SELECT + 16 - col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( - cor0.col1 ) * cor0.col0 * - col2 + col1 * col1 AS col0 FROM tab0 AS cor0
----
-60716
-655837
6014

onlyif mysql # use DIV operator for integer division
query I rowsort label-6289
SELECT DISTINCT 61 + + col0 DIV - ( col1 ) FROM tab2 cor0
----
57
60
61

skipif mysql # not compatible
query I rowsort label-6289
SELECT DISTINCT 61 + + col0 / - ( col1 ) FROM tab2 cor0
----
57
60
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6290
SELECT ALL 1 - col0 * CAST( NULL AS SIGNED ) * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6290
SELECT ALL 1 - col0 * CAST ( NULL AS INTEGER ) * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 42 + - col0 * + col0 AS col1 FROM tab0 AS cor0
----
-1183
-534
-7879

query I rowsort
SELECT ALL - 95 - + col2 AS col1 FROM tab0 AS cor0
----
-128
-177
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6293
SELECT DISTINCT + cor0.col2 DIV cor0.col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6293
SELECT DISTINCT + cor0.col2 / cor0.col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - + col2 * col1 + 38 FROM tab0 cor0
----
-2800
-59
-7424

query I rowsort
SELECT col1 * - col1 + 91 * + cor0.col0 + + col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-275
13141
9701

query I rowsort
SELECT ALL - cor0.col1 * 81 FROM tab1 AS cor0
----
-1053
-2106
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-6297
SELECT ALL + col0 + 8 DIV col1 + col2 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-6297
SELECT ALL + col0 + 8 / col1 + col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL 50 + col1 - 8 AS col2 FROM tab2
----
101
59
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6299
SELECT ALL ( + col1 ) - + CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6299
SELECT ALL ( + col1 ) - + CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + - col2 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL 67 + - col2 * - col0 AS col1 FROM tab2 AS cor0
----
2095
256
3069

query I rowsort
SELECT + 52 * col2 FROM tab1 AS cor0
----
2808
2964
4992

query I rowsort
SELECT DISTINCT - - ( - cor0.col1 ) * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 98 col0 FROM tab1 AS cor0
----
-98
-98
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + + 66 * col2 col1 FROM tab0 AS cor0
----
101
2202
5501

query I rowsort
SELECT - + ( 63 ) FROM tab0 AS cor0
----
-63
-63
-63

query I rowsort
SELECT DISTINCT 93 AS col2 FROM tab0, tab0 AS cor0
----
93

query I rowsort
SELECT ALL - - col0 + 22 FROM tab0 AS cor0
----
111
46
57

query I rowsort
SELECT DISTINCT col1 + + ( col2 ) AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT col0 * - ( col0 ) FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-6311
SELECT DISTINCT col1 DIV - 46 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6311
SELECT DISTINCT col1 / - 46 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT ALL cor0.col1 * 82 + - 74 AS col0 FROM tab2 AS cor0
----
1320
2468
4764

query I rowsort
SELECT DISTINCT - col0 + - 73 FROM tab1 AS cor0
----
-137
-153
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 76 col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

onlyif mysql # use DIV operator for integer division
query I rowsort label-6315
SELECT DISTINCT - ( - col1 ) DIV ( + col0 ) + col1 * - tab0.col0 FROM tab0
----
-2061
-3393
-8098

skipif mysql # not compatible
query I rowsort label-6315
SELECT DISTINCT - ( - col1 ) / ( + col0 ) + col1 * - tab0.col0 FROM tab0
----
-2061
-3393
-8098

query I rowsort
SELECT - col1 + - 27 * - col1 AS col1 FROM tab2 AS cor0
----
1534
442
806

query I rowsort
SELECT + col2 * + col0 + 88 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-2126
2768
6536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * ( col2 ) + + col2 col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT cor0.col0 + - col1 * + col1 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT 17 + 75 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT DISTINCT + 76 * - 9 AS col1 FROM tab2, tab1 AS cor0
----
-684

query I rowsort
SELECT DISTINCT - - col1 * - col2 + - 21 * col2 AS col0 FROM tab1 AS cor0
----
-1767
-2538
-3264

query I rowsort
SELECT + col0 * - col2 + - col1 AS col2 FROM tab0 cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL + col0 * - col1 - col0 FROM tab1 AS cor0
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6325
SELECT + col1 + col1 DIV + 97 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6325
SELECT + col1 + col1 / + 97 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT 60 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
60

query I rowsort
SELECT col2 + 93 * col2 + col1 FROM tab1
----
5102
5368
9037

query I rowsort
SELECT DISTINCT col2 - + 38 * - col2 * + col2 FROM tab2
----
25714
27729
54910

query I rowsort
SELECT DISTINCT + col0 + + col2 * - col2 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT + 30 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + col0 * 37 col1 FROM tab2
----
290
2940
2945

query I rowsort
SELECT + + 10 AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6333
SELECT ALL - col2 * cor0.col2 + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6333
SELECT ALL - col2 * cor0.col2 + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 5 * + col2 AS col0 FROM tab0
----
165
410
5

query I rowsort
SELECT + 37 * - col0 AS col1 FROM tab2
----
-259
-2886
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 + + col2 col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT tab1.col2 * + col0 * 11 FROM tab1
----
1782
40128
84480

query I rowsort
SELECT DISTINCT col1 + - ( - 79 ) FROM tab2
----
110
138
96

query I rowsort
SELECT - ( col2 * + col2 ) AS col0 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL 52 * - col0 * col1 FROM tab2
----
-11284
-239304
-69836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 93 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6342
SELECT DISTINCT CAST( 67 AS SIGNED ) AS col0 FROM tab2
----
67

skipif mysql # not compatible
query I rowsort label-6342
SELECT DISTINCT CAST ( 67 AS INTEGER ) AS col0 FROM tab2
----
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( tab0.col2 ) col1 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL 46 FROM tab1, tab0 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT ALL - + col2 + col2 + - col2 * - col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT + - cor0.col1 + - col2 + col0 AS col1 FROM tab0 AS cor0
----
-63
-84
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6348
SELECT - col2 + + col0 * - CAST( + col1 * col0 AS SIGNED ) col2 FROM tab2 AS cor0
----
-106135
-1546
-358982

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6348
SELECT - col2 + + col0 * - CAST ( + col1 * col0 AS INTEGER ) col2 FROM tab2 AS cor0
----
-106135
-1546
-358982

query I rowsort
SELECT col2 + + col2 * - ( + col2 ) * col2 - + 49 * + col0 AS col2 FROM tab0 AS cor0
----
-1715
-37080
-555647

onlyif mysql # use DIV operator for integer division
query I rowsort label-6350
SELECT - - col0 * col2 + - col2 DIV - col1 FROM tab2 AS cor0
----
189
2028
3004

skipif mysql # not compatible
query I rowsort label-6350
SELECT - - col0 * col2 + - col2 / - col1 FROM tab2 AS cor0
----
189
2028
3004

query I rowsort
SELECT - 26 * - col0 + + 91 - - col0 AS col0 FROM tab1 AS cor0
----
172
1819
2251

onlyif mysql # use DIV operator for integer division
query I rowsort label-6352
SELECT + 25 DIV col1 + - cor0.col2 FROM tab0 cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6352
SELECT + 25 / col1 + - cor0.col2 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6353
SELECT cor0.col1 DIV 51 FROM tab1, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-6353
SELECT cor0.col1 / 51 FROM tab1, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT ALL + 22 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT - col2 * 71 + col1 AS col1 FROM tab1 AS cor0
----
-3808
-4037
-6803

query I rowsort
SELECT DISTINCT cor0.col0 + - col0 * cor0.col0 AS col2 FROM tab1 cor0
----
-4032
-6
-6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6357
SELECT col2 * + ( - col1 ) + - CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
-1560
-684
-864

skipif mysql # not compatible
query I rowsort label-6357
SELECT col2 * + ( - col1 ) + - CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT DISTINCT + ( col0 ) - col2 * - col2 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT + 85 * + cor0.col1 FROM tab0 cor0
----
7310
7735
8245

query I rowsort
SELECT ALL - col0 * col0 + 20 * + col2 * + cor0.col1 FROM tab0 AS cor0
----
141319
56184
715

query I rowsort
SELECT 3 + col2 * ( - col1 ) AS col1 FROM tab2 AS cor0
----
-1531
-643
-834

query I rowsort
SELECT DISTINCT - 72 FROM tab0, tab1, tab0 cor0
----
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-6363
SELECT + tab2.col1 DIV - col0 AS col0 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-6363
SELECT + tab2.col1 / - col0 AS col0 FROM tab2
----
-4
0
0

query I rowsort
SELECT + col1 + + col1 - col1 FROM tab1
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6365
SELECT col0 * + tab0.col1 + col2 * CAST( col0 AS SIGNED ) FROM tab0
----
15397
2856
3430

skipif mysql # not compatible
query I rowsort label-6365
SELECT col0 * + tab0.col1 + col2 * CAST ( col0 AS INTEGER ) FROM tab0
----
15397
2856
3430

query I rowsort
SELECT DISTINCT 78 FROM tab0, tab0 AS cor0
----
78

query I rowsort
SELECT tab2.col0 * col2 + + col1 FROM tab2
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT ALL ( ( - col0 ) ) - 82 AS col0 FROM tab0
----
-106
-117
-171

query I rowsort
SELECT 62 * 54 - - col0 AS col2 FROM tab2
----
3355
3426
3427

query I rowsort
SELECT DISTINCT col0 * + col0 - - col0 FROM tab1
----
12
4160
6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6372
SELECT DISTINCT CAST( NULL AS SIGNED ) / - tab2.col2 - col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6372
SELECT DISTINCT CAST ( NULL AS INTEGER ) / - tab2.col2 - col2 FROM tab2
----
NULL

query I rowsort
SELECT - col2 * 71 - col0 FROM tab0
----
-106
-2367
-5911

query I rowsort
SELECT DISTINCT ( col2 ) + tab0.col1 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL col1 * + col0 - - 77 * + col2 FROM tab1 cor0
----
4236
5029
8432

onlyif mysql # use DIV operator for integer division
query I rowsort label-6376
SELECT DISTINCT + - col1 + - 90 DIV col1 FROM tab0 AS cor0
----
-87
-91
-97

skipif mysql # not compatible
query I rowsort label-6376
SELECT DISTINCT + - col1 + - 90 / col1 FROM tab0 AS cor0
----
-87
-91
-97

query I rowsort
SELECT ALL - col2 + ( 0 ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT col0 - col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT col1 * col0 * + col1 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6380
SELECT + - col1 * CAST( col1 + + col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1417
-2080
-670

skipif mysql # not compatible
query I rowsort label-6380
SELECT + - col1 * CAST ( col1 + + col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1417
-2080
-670

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6381
SELECT ALL - col0 * - CAST( + col2 AS SIGNED ) FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-6381
SELECT ALL - col0 * - CAST ( + col2 AS INTEGER ) FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6382
SELECT col1 DIV col0 + col1 * tab2.col2 AS col2 FROM tab2
----
1534
646
841

skipif mysql # not compatible
query I rowsort label-6382
SELECT col1 / col0 + col1 * tab2.col2 AS col2 FROM tab2
----
1534
646
841

query I rowsort
SELECT tab0.col1 - tab0.col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + col1 * 40 FROM tab1
----
1040
400
520

query I rowsort
SELECT col0 + 27 FROM tab0
----
116
51
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6386
SELECT ALL col2 * CAST( col0 AS SIGNED ) FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-6386
SELECT ALL col2 * CAST ( col0 AS INTEGER ) FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT - 56 FROM tab1, tab1 cor0
----
-56

query I rowsort
SELECT col0 * + tab0.col2 + + tab0.col2 * col2 AS col0 FROM tab0
----
14022
1881
36

query I rowsort
SELECT ALL 22 FROM tab0 AS cor0
----
22
22
22

query I rowsort
SELECT + ( cor0.col1 ) AS col1 FROM tab0 cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6391
SELECT ALL + - CAST( NULL AS SIGNED ) + col0 * + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6391
SELECT ALL + - CAST ( NULL AS INTEGER ) + col0 * + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6392
SELECT ALL - 22 DIV col2 FROM tab0 AS cor0
----
-22
0
0

skipif mysql # not compatible
query I rowsort label-6392
SELECT ALL - 22 / col2 FROM tab0 AS cor0
----
-22
0
0

query I rowsort
SELECT ALL col2 + col0 * col0 AS col1 FROM tab2
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6394
SELECT 99 DIV + col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6394
SELECT 99 / + col1 FROM tab0
----
1
1
1

query I rowsort
SELECT + col2 * - 10 FROM tab1 AS cor0
----
-540
-570
-960

query I rowsort
SELECT - col0 * 28 FROM tab0 AS cor0
----
-2492
-672
-980

query I rowsort
SELECT DISTINCT + + 12 - + col2 AS col0 FROM tab0 AS cor0
----
-21
-70
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6398
SELECT ALL + + CAST( ( - col0 ) AS SIGNED ) * col1 * + col1 AS col2 FROM tab0 AS cor0
----
-177504
-329315
-737009

skipif mysql # not compatible
query I rowsort label-6398
SELECT ALL + + CAST ( ( - col0 ) AS INTEGER ) * col1 * + col1 AS col2 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT col1 + 74 FROM tab1 AS cor0
----
100
84
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6400
SELECT ALL + ( + col1 ) + + col0 + CAST( col0 * - col1 AS SIGNED ) FROM tab0 AS cor0
----
-1954
-3263
-7919

skipif mysql # not compatible
query I rowsort label-6400
SELECT ALL + ( + col1 ) + + col0 + CAST ( col0 * - col1 AS INTEGER ) FROM tab0 AS cor0
----
-1954
-3263
-7919

query I rowsort
SELECT DISTINCT - - 79 + col0 FROM tab1 AS cor0
----
143
159
82

query I rowsort
SELECT + 9 * - cor0.col0 + col0 AS col2 FROM tab0 cor0
----
-192
-280
-712

query I rowsort
SELECT + - col1 * col2 * - cor0.col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT DISTINCT + + 6 * col0 AS col0 FROM tab0 AS cor0
----
144
210
534

onlyif mysql # use DIV operator for integer division
query I rowsort label-6405
SELECT - CAST( - 70 AS SIGNED ) DIV - col0 FROM tab0 AS cor0
----
-2
-2
0

skipif mysql # not compatible
query I rowsort label-6405
SELECT - CAST ( - 70 AS INTEGER ) / - col0 FROM tab0 AS cor0
----
-2
-2
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6406
SELECT DISTINCT + 51 + + col2 DIV col1 AS col2 FROM tab2 AS cor0
----
51
53

skipif mysql # not compatible
query I rowsort label-6406
SELECT DISTINCT + 51 + + col2 / col1 AS col2 FROM tab2 AS cor0
----
51
53

query I rowsort
SELECT - 35 * cor0.col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to b92df373a33b589aa8d3933ecf32178c

query I rowsort
SELECT + col0 * col1 + 44 * cor0.col2 FROM tab0 cor0
----
11707
3439
3516

onlyif mysql # use DIV operator for integer division
query I rowsort label-6409
SELECT col0 DIV cor0.col2 + col2 AS col0 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-6409
SELECT col0 / cor0.col2 + col2 AS col0 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT ALL - ( col0 ) + col2 + col1 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT DISTINCT - - 25 AS col0 FROM tab0 AS cor0
----
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 + 76 * - ( - col2 ) + ( + 89 ) col2 FROM tab0 cor0
----
13783
262
5435

query I rowsort
SELECT DISTINCT + - 0 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + cor0.col1 ) col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - + cor0.col1 * - col0 + col1 + col2 * col0 AS col0 FROM tab2 AS cor0
----
4362
437
6689

query I rowsort
SELECT ALL + - 25 + col0 FROM tab2 AS cor0
----
-18
53
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-6417
SELECT ALL + + 46 DIV + col0 - col1 AS col1 FROM tab1 AS cor0
----
-10
-11
-13

skipif mysql # not compatible
query I rowsort label-6417
SELECT ALL + + 46 / + col0 - col1 AS col1 FROM tab1 AS cor0
----
-10
-11
-13

query I rowsort
SELECT DISTINCT + col1 * - col2 + col1 FROM tab0 cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6419
SELECT + col1 * + CAST( + col0 AS SIGNED ) col0 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6419
SELECT + col1 * + CAST ( + col0 AS INTEGER ) col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col2 + + 26 * col0 + col1 AS col1 FROM tab0 AS cor0
----
1006
2323
677

query I rowsort
SELECT DISTINCT - col1 * 43 + col2 * - col2 FROM tab2 AS cor0
----
-2062
-2175
-3213

query I rowsort
SELECT DISTINCT cor0.col2 * - 31 AS col2 FROM tab0 AS cor0
----
-1023
-2542
-31

query I rowsort
SELECT + col1 + + ( + col1 ) AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT - cor0.col1 + - ( + col1 ) * - col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL + col0 + 42 * col0 * - col0 FROM tab2 AS cor0
----
-2051
-255450
-262043

query I rowsort
SELECT + 89 + - 1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

onlyif mysql # use DIV operator for integer division
query I rowsort label-6427
SELECT - tab2.col1 DIV + tab2.col1 AS col2 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6427
SELECT - tab2.col1 / + tab2.col1 AS col2 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + - col1 + col0 AS col2 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6429
SELECT col1 DIV - col0 + col1 AS col2 FROM tab0 AS cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-6429
SELECT col1 / - col0 + col1 AS col2 FROM tab0 AS cor0
----
83
90
95

query I rowsort
SELECT DISTINCT - col0 + col0 * col1 AS col1 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT ALL col0 * col0 + cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
4217
6576
66

query I rowsort
SELECT - col2 * + cor0.col2 + - col2 AS col2 FROM tab0 cor0
----
-1122
-2
-6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-6433
SELECT + col0 + col1 DIV col1 FROM tab1 cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6433
SELECT + col0 + col1 / col1 FROM tab1 cor0
----
4
65
81

query I rowsort
SELECT DISTINCT - col1 + - cor0.col2 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - cor0.col2 * + col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - cor0.col0 * col1 + col0 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL + cor0.col1 * - col0 + col1 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NOT ( NULL ) NOT IN ( cor0.col0 * - cor0.col1 )
----

query I rowsort
SELECT - col2 + + col2 * + col1 + col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - col0 - - col2 * + col1 AS col0 FROM tab2 WHERE NULL NOT IN ( col0 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL <= + col2 + col2 * col0
----

query I rowsort
SELECT col2 + tab0.col0 * tab0.col0 + - col2 FROM tab0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6443
SELECT cor0.col2 DIV col1 + - col1 col2 FROM tab1 AS cor0
----
-24
-5
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6443
SELECT cor0.col2 / col1 + - col1 col2 FROM tab1 AS cor0
----
-24
-5
-6

query I rowsort
SELECT ALL tab0.col0 * col1 + col0 AS col2 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + + col2 * col2 + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1197
-1224
513

query I rowsort
SELECT - cor0.col0 + cor0.col1 AS col0 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT + col2 + col0 * col2 * cor0.col1 FROM tab0 cor0
----
3396
664200
68145

query I rowsort
SELECT 51 + + col2 FROM tab1
----
105
108
147

query I rowsort
SELECT ALL + + cor0.col2 * col2 - - col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT - tab2.col1 + col1 * + col2 - col0 * col0 AS col2 FROM tab2
----
-4609
-5612
757

query I rowsort
SELECT ALL + col0 - col1 * col2 AS col1 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - col2 * col2 - - col1 * tab2.col1 FROM tab2
----
-1155
232
2805

onlyif mysql # use DIV operator for integer division
query I rowsort label-6453
SELECT DISTINCT col2 DIV col2 - - col0 * - tab0.col0 AS col1 FROM tab0
----
-1224
-575
-7920

skipif mysql # not compatible
query I rowsort label-6453
SELECT DISTINCT col2 / col2 - - col0 * - tab0.col0 AS col1 FROM tab0
----
-1224
-575
-7920

query I rowsort
SELECT DISTINCT + col0 + col0 * col0 AS col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT + col0 + + col1 + - col1 * - col2 * + col1 AS col2 FROM tab0 AS cor0
----
244178
679222
9541

query I rowsort
SELECT - - col2 + - col1 * + col2 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-6457
SELECT + col2 * tab2.col0 + col0 DIV col0 FROM tab2
----
190
2029
3003

skipif mysql # not compatible
query I rowsort label-6457
SELECT + col2 * tab2.col0 + col0 / col0 FROM tab2
----
190
2029
3003

query I rowsort
SELECT DISTINCT col1 + col0 * tab0.col0 * col2 AS col1 FROM tab0
----
1322
19094
649613

query I rowsort
SELECT DISTINCT - tab0.col0 * col0 * - col2 + col0 AS col1 FROM tab0
----
1260
19032
649611

query I rowsort
SELECT col0 * col0 + + col1 AS col1 FROM tab2
----
6143
6258
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col2 col0 FROM tab1
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6462
SELECT ALL + tab0.col1 + + col0 DIV - col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6462
SELECT ALL + tab0.col1 + + col0 / - col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + + 53 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT + cor0.col1 FROM tab2, tab2 cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT cor0.col1 * + cor0.col2 AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + col2 + + col0 * + col1 AS col0 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL - col1 * col1 + - tab0.col0 AS col2 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT - col2 FROM tab1 WHERE NOT - col1 > + col0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6469
SELECT DISTINCT col1 * col0 + col0 DIV - col1 AS col2 FROM tab1
----
1034
634
78

skipif mysql # not compatible
query I rowsort label-6469
SELECT DISTINCT col1 * col0 + col0 / - col1 AS col2 FROM tab1
----
1034
634
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 col1 FROM tab1 WHERE NOT NULL BETWEEN NULL AND + col1 * col1
----

query I rowsort
SELECT ALL tab1.col2 + + col2 * col0 AS col1 FROM tab1
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-6472
SELECT - cor0.col2 + 92 DIV - cor0.col1 - + cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 3208ba9a2f8f47531122d1b58b2b5e22

skipif mysql # not compatible
query I rowsort label-6472
SELECT - cor0.col2 + 92 / - cor0.col1 - + cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 3208ba9a2f8f47531122d1b58b2b5e22

query I rowsort
SELECT ALL - tab2.col0 * tab2.col0 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to bfa29ac72730a1b8452f6f2702fbe6b9

query I rowsort
SELECT DISTINCT - col1 + col1 * - col1 FROM tab2
----
-306
-3540
-992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col2 col1 FROM tab2
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - tab0.col2 col2 FROM tab0
----
53
9
96

query III rowsort
SELECT * FROM tab2 WHERE NULL >= col1 * - col2 * col0 + + col0
----

query I rowsort
SELECT DISTINCT + col2 * col1 FROM tab1 WHERE NOT ( NULL ) >= NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE col0 + - col2 < NULL
----

query I rowsort
SELECT col0 * col0 * cor0.col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT ALL - col2 + col1 * - col2 FROM tab2
----
-1560
-684
-864

query III rowsort
SELECT * FROM tab0 WHERE NULL < col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6483
SELECT DISTINCT - col2 + + col0 DIV + tab0.col0 AS col0 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-6483
SELECT DISTINCT - col2 + + col0 / + tab0.col0 AS col0 FROM tab0
----
-32
-81
0

query III rowsort
SELECT * FROM tab0 WHERE - col2 * + col1 IN ( col1 + - col2 * col0 + col1 )
----

query I rowsort
SELECT ALL - col1 + col1 * - tab1.col2 AS col1 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - col2 * - col0 + + col0 AS col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL col2 * col2 + - col0 AS col0 FROM tab0
----
-34
1065
6635

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * tab1.col1 + + tab1.col0 * - col2 col1 FROM tab1
----
-3078
-6432
1242

query I rowsort
SELECT - col0 * - col1 FROM tab0 WHERE NOT NULL NOT IN ( col2 )
----

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) <= col0 + col2
----

query I rowsort
SELECT DISTINCT - col1 + col0 * col0 AS col1 FROM tab2
----
18
6025
6224

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT IN ( + col2 + + col0 * + col2 )
----

query I rowsort
SELECT col1 - + col1 AS col0 FROM tab1 WHERE NOT ( NULL ) IN ( - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6494
SELECT col0 + - col2 DIV + col0 FROM tab1
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-6494
SELECT col0 + - col2 / + col0 FROM tab1
----
-15
64
79

query I rowsort
SELECT DISTINCT tab2.col2 * - col1 FROM tab2 WHERE NULL NOT IN ( - col0 + - col1 )
----

query I rowsort
SELECT 23 * col0 + cor0.col1 AS col0 FROM tab2 AS cor0
----
1834
1853
192

query I rowsort
SELECT + 52 - - col2 FROM tab2
----
78
79
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6498
SELECT DISTINCT 86 DIV - col0 + + 60 AS col0 FROM tab2 AS cor0
----
48
59

skipif mysql # not compatible
query I rowsort label-6498
SELECT DISTINCT 86 / - col0 + + 60 AS col0 FROM tab2 AS cor0
----
48
59

query I rowsort
SELECT DISTINCT + - 47 * - col0 FROM tab2 AS cor0
----
329
3666
3713

query I rowsort
SELECT DISTINCT 3 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + + col0 * col0 col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT 99 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
109
112
125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + col1 col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT col1 + + col0 * col1 * cor0.col2 AS col1 FROM tab0 cor0
----
3492
664209
68198

query I rowsort
SELECT ALL + col1 + - 69 * + 74 AS col2 FROM tab0 AS cor0
----
-5009
-5015
-5020

onlyif mysql # use DIV operator for integer division
query I rowsort label-6506
SELECT - col1 + - 3 DIV + 76 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-6506
SELECT - col1 + - 3 / + 76 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6507
SELECT ALL - cor0.col2 DIV - 34 AS col0 FROM tab0 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6507
SELECT ALL - cor0.col2 / - 34 AS col0 FROM tab0 AS cor0
----
0
0
2

query I rowsort
SELECT ALL - - cor0.col1 + 62 FROM tab2 AS cor0
----
121
79
93

query I rowsort
SELECT - 19 * tab0.col1 FROM tab0
----
-1634
-1729
-1843

query I rowsort
SELECT DISTINCT - cor0.col1 * + col1 AS col1 FROM tab2 cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-6511
SELECT ALL col2 + - ( + col1 ) DIV col1 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-6511
SELECT ALL col2 + - ( + col1 ) / col1 FROM tab2 AS cor0
----
25
26
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-6512
SELECT + + col1 + + ( 3 * + col1 ) - col2 DIV col2 FROM tab0 cor0
----
343
363
387

skipif mysql # not compatible
query I rowsort label-6512
SELECT + + col1 + + ( 3 * + col1 ) - col2 / col2 FROM tab0 cor0
----
343
363
387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 + 90 - col1 col2 FROM tab2 AS cor0
----
-6053
-6168
10

query I rowsort
SELECT DISTINCT + col1 * + col1 + + col1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT - cor0.col1 + - 85 FROM tab2 AS cor0
----
-102
-116
-144

query I rowsort
SELECT - col0 * - 18 FROM tab1 AS cor0
----
1152
1440
54

query I rowsort
SELECT ALL - 49 + - col1 AS col2 FROM tab1 cor0
----
-59
-62
-75

query I rowsort
SELECT - + 99 * ( cor0.col0 ) FROM tab0 AS cor0
----
-2376
-3465
-8811

query I rowsort
SELECT - - 7 AS col1 FROM tab1 AS cor0
----
7
7
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) * col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT col0 * 61 FROM tab2 AS cor0
----
427
4758
4819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6522
SELECT DISTINCT + - CAST( NULL AS DECIMAL ) + - col1 * - col0 / - col0 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6522
SELECT DISTINCT + - CAST ( NULL AS REAL ) + - col1 * - col0 / - col0 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - col1 * col0 + col1 * 15 AS col0 FROM tab2 AS cor0
----
1598
5487
682

query I rowsort
SELECT + col0 * col2 + col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT - + 77 + + col2 * + col1 FROM tab1 AS cor0
----
1171
1327
493

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 col2 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - 12 + + col2 * + col1 AS col0 FROM tab1 AS cor0
----
1236
1392
558

onlyif mysql # use DIV operator for integer division
query I rowsort label-6528
SELECT ( - col0 ) - col1 DIV - col0 AS col0 FROM tab1
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-6528
SELECT ( - col0 ) - col1 / - col0 AS col0 FROM tab1
----
-64
-80
5

query I rowsort
SELECT - 5 - 75 AS col2 FROM tab0
----
-80
-80
-80

query I rowsort
SELECT DISTINCT + ( + 24 ) * - col0 * col0 AS col1 FROM tab2
----
-1176
-146016
-149784

query I rowsort
SELECT ALL 26 * col0 FROM tab2 AS cor0
----
182
2028
2054

onlyif mysql # use DIV operator for integer division
query I rowsort label-6532
SELECT DISTINCT + col0 - + col2 DIV col1 col0 FROM tab1 AS cor0
----
1
59
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6532
SELECT DISTINCT + col0 - + col2 / col1 col0 FROM tab1 AS cor0
----
1
59
73

query I rowsort
SELECT DISTINCT - col0 * + col2 - - col2 * - col0 FROM tab0 AS cor0
----
-14596
-1584
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * - col1 * - col1 col2 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT + + 28 AS col2 FROM tab1 AS cor0
----
28
28
28

query I rowsort
SELECT ALL + 13 + col0 AS col0 FROM tab0
----
102
37
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col1 + col1 col1 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT + 41 + col1 + col0 * - col2 AS col2 FROM tab2
----
-117
-1928
-2944

query I rowsort
SELECT - col1 + - col1 * - col0 FROM tab1
----
1027
52
630

query I rowsort
SELECT DISTINCT col1 + - ( col0 ) AS col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL 12 AS col0 FROM tab0
----
12
12
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-6542
SELECT + col1 * - col2 * col2 + - col0 DIV + col0 FROM tab0
----
-611885
-93655
-98

skipif mysql # not compatible
query I rowsort label-6542
SELECT + col1 * - col2 * col2 + - col0 / + col0 FROM tab0
----
-611885
-93655
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - cor0.col2 + col1 * + col2 col1 FROM tab0 cor0
----
1749
738
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 95 + - col1 col1 FROM tab2 AS cor0
----
36
64
78

query I rowsort
SELECT ALL col0 * cor0.col1 * cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
288
41017
83296

query I rowsort
SELECT ALL + - cor0.col2 * col0 + col2 AS col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT - 33 AS col1 FROM tab1 cor0
----
-33

query I rowsort
SELECT ALL + col2 + col0 * col0 AS col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL + col0 + + 79 - 33 AS col2 FROM tab1
----
110
126
49

query I rowsort
SELECT ALL col0 + - col2 - + col1 FROM tab0
----
-63
-84
-95

query I rowsort
SELECT - - cor1.col1 * cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to f5605ce6cbd6ecc79a4a887488bb6947

query I rowsort
SELECT - col2 * + 42 + cor0.col0 FROM tab2 AS cor0
----
-1014
-1127
-1517

query I rowsort
SELECT col2 * ( - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6554
SELECT - - col0 + CAST( NULL AS SIGNED ) * - 59 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6554
SELECT - - col0 + CAST ( NULL AS INTEGER ) * - 59 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + - col1 * + col0 - col1 * cor0.col0 AS col0 FROM tab1 cor0
----
-1337
-210
-2176

query I rowsort
SELECT - 56 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6557
SELECT - col1 DIV + CAST( + col1 AS SIGNED ) + col0 * - col2 + + tab2.col2 AS col0 FROM tab2
----
-163
-2003
-2965

skipif mysql # not compatible
query I rowsort label-6557
SELECT - col1 / + CAST ( + col1 AS INTEGER ) + col0 * - col2 + + tab2.col2 AS col0 FROM tab2
----
-163
-2003
-2965

query I rowsort
SELECT + - 71 * col2 * - col1 AS col1 FROM tab0 AS cor0
----
201498
529802
6887

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + cor0.col1 col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT ( + 37 ) * col2 FROM tab0 AS cor0
----
1221
3034
37

query I rowsort
SELECT ALL + 86 * - 57 + col0 FROM tab1
----
-4822
-4838
-4899

query I rowsort
SELECT ALL + ( cor0.col1 ) * - col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - ( + 16 ) + - col2 FROM tab2 AS cor0
----
-42
-43
-54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 59 col2 FROM tab1
----
3186
3363
5664

onlyif mysql # use DIV operator for integer division
query I rowsort label-6565
SELECT col1 + col0 DIV col0 AS col0 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-6565
SELECT col1 + col0 / col0 AS col0 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT col1 * 48 + 30 FROM tab1
----
1278
510
654

query I rowsort
SELECT 49 * 77 + - col2 FROM tab0 cor0
----
3691
3740
3772

onlyif mysql # use DIV operator for integer division
query I rowsort label-6568
SELECT DISTINCT - col2 DIV 84 AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-6568
SELECT DISTINCT - col2 / 84 AS col0 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6569
SELECT DISTINCT + - ( col0 ) DIV + cor0.col0 + col0 * + col2 FROM tab2 AS cor0
----
188
2027
3001

skipif mysql # not compatible
query I rowsort label-6569
SELECT DISTINCT + - ( col0 ) / + cor0.col0 + col0 * + col2 FROM tab2 AS cor0
----
188
2027
3001

query I rowsort
SELECT + col2 * - col0 * cor0.col1 + - ( + col1 ) FROM tab0 AS cor0
----
-3492
-664209
-68198

query I rowsort
SELECT + - col1 + col1 * - col2 AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT - cor0.col1 - col0 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL ( col0 ) + cor0.col0 * + cor0.col0 FROM tab1 AS cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 38 * col2 - col0 col2 FROM tab1 AS cor0
----
2049
2102
3568

query I rowsort
SELECT - ( - col1 ) + + cor0.col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + + 80 - cor0.col2 FROM tab1 AS cor0
----
-16
23
26

query I rowsort
SELECT ALL - 31 + - col2 FROM tab0 AS cor0
----
-113
-32
-64

query I rowsort
SELECT col0 + col1 + col2 AS col0 FROM tab2 AS cor0
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 41 col1 FROM tab2 AS cor0
----
41

query I rowsort
SELECT DISTINCT - cor0.col1 + cor0.col0 FROM tab0 cor0
----
-2
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6581
SELECT ALL + + col0 * col0 + col0 DIV - 70 AS col0 FROM tab1 AS cor0
----
4096
6399
9

skipif mysql # not compatible
query I rowsort label-6581
SELECT ALL + + col0 * col0 + col0 / - 70 AS col0 FROM tab1 AS cor0
----
4096
6399
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 6 + cor0.col0 * ( - col1 ) col1 FROM tab0 AS cor0
----
-2070
-3401
-8105

onlyif mysql # use DIV operator for integer division
query I rowsort label-6583
SELECT ALL - + 32 DIV col1 + + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6583
SELECT ALL - + 32 / col1 + + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + col2 * 21 * - col1 FROM tab2 AS cor0
----
-13566
-17577
-32214

onlyif mysql # use DIV operator for integer division
query I rowsort label-6585
SELECT DISTINCT col2 DIV cor0.col0 + - 59 * col0 FROM tab1 AS cor0
----
-159
-3776
-4719

skipif mysql # not compatible
query I rowsort label-6585
SELECT DISTINCT col2 / cor0.col0 + - 59 * col0 FROM tab1 AS cor0
----
-159
-3776
-4719

query I rowsort
SELECT ALL - + col1 * + ( ( - col2 ) ) - col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT + col0 * + col2 + tab1.col1 AS col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT col1 + + 63 FROM tab1 AS cor0
----
73
76
89

query I rowsort
SELECT ALL - cor1.col1 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT col0 * 93 + + col0 * tab0.col0 AS col0 FROM tab0
----
16198
2808
4480

query I rowsort
SELECT + col2 + ( + col1 ) * col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT - col0 + - 19 * - col2 FROM tab2 AS cor0
----
416
506
643

query I rowsort
SELECT - 18 * 12 AS col2 FROM tab0 cor0
----
-216
-216
-216

query I rowsort
SELECT - col2 * ( + cor0.col1 * + cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - 56 AS col0 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

query I rowsort
SELECT - 83 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT - col0 * + 57 * + cor0.col2 FROM tab1 AS cor0
----
-207936
-437760
-9234

query I rowsort
SELECT DISTINCT + 95 * col1 + - col0 AS col0 FROM tab0 AS cor0
----
8146
8556
9180

query I rowsort
SELECT - 52 * - 97 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to e249296c8989a0d0bfe871a09711e3fb

query I rowsort
SELECT DISTINCT 78 * - tab2.col0 AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
-546
-6084
-6162

query I rowsort
SELECT 88 + col0 * 69 AS col1 FROM tab1 AS cor0
----
295
4504
5608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col2 + - 35 col1 FROM tab0 AS cor0
----
-117
-36
-68

query I rowsort
SELECT - cor0.col2 * + ( + col2 ) AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT col1 * - col2 * - col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT DISTINCT 93 + - ( col2 * col0 ) FROM tab2
----
-1935
-2909
-96

query I rowsort
SELECT ALL + 79 + - 43 AS col1 FROM tab1
----
36
36
36

query I rowsort
SELECT ALL - col1 * - col2 - + cor0.col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT 30 FROM tab2, tab2 cor0
----
30

query I rowsort
SELECT DISTINCT 26 + - col2 FROM tab0
----
-56
-7
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6610
SELECT CAST( + 26 AS SIGNED ) + - cor0.col2 FROM tab1 cor0
----
-28
-31
-70

skipif mysql # not compatible
query I rowsort label-6610
SELECT CAST ( + 26 AS INTEGER ) + - cor0.col2 FROM tab1 cor0
----
-28
-31
-70

query I rowsort
SELECT - col0 + col2 * + col1 AS col2 FROM tab2 cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-6612
SELECT - col2 * cor0.col0 DIV + 65 AS col2 FROM tab0 AS cor0
----
-112
-12
0

skipif mysql # not compatible
query I rowsort label-6612
SELECT - col2 * cor0.col0 / + 65 AS col2 FROM tab0 AS cor0
----
-112
-12
0

query I rowsort
SELECT - 60 + + col1 * ( - col0 * + col2 ) FROM tab1 cor0
----
-36540
-4272
-99900

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6614
SELECT - + 10 * + col2 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6614
SELECT - + 10 * + col2 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * - ( col0 ) + col1 + col2 FROM tab1
----
-573
-931
2

query I rowsort
SELECT ALL - - tab1.col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT col2 + - 80 + tab2.col2 AS col1 FROM tab2
----
-26
-28
-4

query I rowsort
SELECT DISTINCT col0 * - col2 + - ( - col1 ) AS col0 FROM tab2
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-6619
SELECT col1 - - ( tab1.col2 ) DIV - col2 col2 FROM tab1
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6619
SELECT col1 - - ( tab1.col2 ) / - col2 col2 FROM tab1
----
12
25
9

query I rowsort
SELECT + col1 * col1 + + 19 FROM tab0
----
7415
8300
9428

query I rowsort
SELECT col2 + - col1 * col0 + - col2 * + col1 FROM tab1
----
-1153
-1428
-2192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col0 col1 FROM tab0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 - col1 col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT ALL + col0 + col0 * - col2 FROM tab0 cor0
----
-7209
-768
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6625
SELECT - + col2 - CAST( cor0.col0 AS SIGNED ) * col0 FROM tab0 AS cor0
----
-1226
-609
-8003

skipif mysql # not compatible
query I rowsort label-6625
SELECT - + col2 - CAST ( cor0.col0 AS INTEGER ) * col0 FROM tab0 AS cor0
----
-1226
-609
-8003

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col2 + col0 col0 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT ALL cor0.col2 * 91 FROM tab2 AS cor0
----
2366
2457
3458

query I rowsort
SELECT col1 * col0 + col0 * + col0 FROM tab1 AS cor0
----
4736
7440
87

query I rowsort
SELECT - + 67 * 54 + col2 FROM tab2 AS cor0
----
-3580
-3591
-3592

query I rowsort
SELECT DISTINCT + ( 89 ) AS col0 FROM tab1 AS cor0
----
89

query I rowsort
SELECT col0 + 0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6632
SELECT - CAST( 57 AS SIGNED ) AS col2 FROM tab0 cor0
----
-57
-57
-57

skipif mysql # not compatible
query I rowsort label-6632
SELECT - CAST ( 57 AS INTEGER ) AS col2 FROM tab0 cor0
----
-57
-57
-57

query I rowsort
SELECT + - col2 + - ( cor0.col0 ) FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6634
SELECT + + col2 DIV cor0.col1 + col2 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-6634
SELECT + + col2 / cor0.col1 + col2 FROM tab2 AS cor0
----
26
27
40

query I rowsort
SELECT ALL col0 * 42 * col0 AS col1 FROM tab2
----
2058
255528
262122

query I rowsort
SELECT + col1 * + col1 * + ( - col2 * tab0.col0 ) AS col1 FROM tab0
----
-329315
-5857632
-60434738

query I rowsort
SELECT DISTINCT - cor0.col0 * ( cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6638
SELECT ALL 6 DIV + col0 col1 FROM tab1 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6638
SELECT ALL 6 / + col0 col1 FROM tab1 AS cor0
----
0
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6639
SELECT - 10 DIV 94 + - col1 * + 93 + - 41 FROM tab2 AS cor0
----
-1622
-2924
-5528

skipif mysql # not compatible
query I rowsort label-6639
SELECT - 10 / 94 + - col1 * + 93 + - 41 FROM tab2 AS cor0
----
-1622
-2924
-5528

query I rowsort
SELECT DISTINCT 42 + + ( + col1 ) FROM tab2 AS cor0
----
101
59
73

query I rowsort
SELECT ALL + + 93 * + col2 AS col1 FROM tab2 AS cor0
----
2418
2511
3534

query I rowsort
SELECT + - col1 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT 79 * 93 + - cor0.col0 FROM tab0 AS cor0
----
7258
7312
7323

query I rowsort
SELECT ALL - 61 + col0 * + col1 + + col1 FROM tab2 AS cor0
----
1299
187
4600

query I rowsort
SELECT ALL + cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6646
SELECT ALL CAST( 99 AS SIGNED ) * - cor1.col0 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6646
SELECT ALL CAST ( 99 AS INTEGER ) * - cor1.col0 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6647
SELECT - col1 + - col2 * cor0.col0 DIV col0 col1 FROM tab0 AS cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6647
SELECT - col1 + - col2 * cor0.col0 / col0 col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT - - ( col2 ) * - col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - cor0.col0 * col1 + + col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + + col2 + - col1 + 32 * col2 FROM tab2 cor0
----
1237
799
860

query I rowsort
SELECT - col1 + col0 + - col1 * + col2 AS col0 FROM tab0
----
-159
-2900
-7464

query I rowsort
SELECT + 41 AS col0 FROM tab1, tab2, tab1 cor0
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT ALL - - 82 AS col1 FROM tab1 AS cor0
----
82
82
82

query I rowsort
SELECT DISTINCT 33 AS col0 FROM tab2 AS cor0
----
33

query I rowsort
SELECT ALL ( col2 ) AS col0 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6656
SELECT 31 DIV col0 AS col1 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6656
SELECT 31 / col0 AS col1 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + + 8 * + col1 AS col1 FROM tab0 AS cor0
----
688
728
776

query I rowsort
SELECT ALL col2 * + col2 + + col1 * + col1 AS col2 FROM tab0
----
15005
8485
9410

query I rowsort
SELECT ALL - col2 * col1 * + tab0.col1 AS col2 FROM tab0
----
-244068
-679042
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-6660
SELECT DISTINCT + col1 + col2 DIV col1 col0 FROM tab1
----
15
20
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6660
SELECT DISTINCT + col1 + col2 / col1 col0 FROM tab1
----
15
20
28

query I rowsort
SELECT - col1 * col2 * col1 + col1 AS col2 FROM tab1
----
-16211
-36478
-5690

query I rowsort
SELECT ALL col2 + + 96 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1594
-2949
-5638

onlyif mysql # use DIV operator for integer division
query I rowsort label-6663
SELECT DISTINCT - col1 DIV 2 AS col0 FROM tab2 AS cor0
----
-15
-29
-8

skipif mysql # not compatible
query I rowsort label-6663
SELECT DISTINCT - col1 / 2 AS col0 FROM tab2 AS cor0
----
-15
-29
-8

query I rowsort
SELECT DISTINCT - + col0 - + 31 AS col0 FROM tab0 cor0
----
-120
-55
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - 43 col2 FROM tab2 AS cor0
----
-16
-17
-5

query I rowsort
SELECT - - col2 + col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + col2 + - ( ( - col0 ) + 1 ) AS col2 FROM tab2 AS cor0
----
103
116
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - ( cor0.col2 ) * + cor0.col2 col0 FROM tab2 AS cor0
----
-17576
-19683
-54872

query I rowsort
SELECT DISTINCT - + cor0.col1 * ( + col2 ) FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6670
SELECT ALL - col1 * 69 + + col2 DIV - col0 FROM tab2 AS cor0
----
-1173
-2142
-4071

skipif mysql # not compatible
query I rowsort label-6670
SELECT ALL - col1 * 69 + + col2 / - col0 FROM tab2 AS cor0
----
-1173
-2142
-4071

query I rowsort
SELECT ALL + - col1 * ( - col1 ) + - col2 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT col0 * - col0 * - col0 FROM tab0 AS cor0
----
13824
42875
704969

query I rowsort
SELECT ALL + - col0 * col2 * - col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT 49 * - tab0.col2 * 30 AS col1 FROM tab0
----
-120540
-1470
-48510

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6675
SELECT + CAST( NULL AS SIGNED ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6675
SELECT + CAST ( NULL AS INTEGER ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6676
SELECT - 96 * + col0 * CAST( col2 AS SIGNED ) + + tab0.col1 FROM tab0
----
-3263
-700517
-75946

skipif mysql # not compatible
query I rowsort label-6676
SELECT - 96 * + col0 * CAST ( col2 AS INTEGER ) + + tab0.col1 FROM tab0
----
-3263
-700517
-75946

query I rowsort
SELECT - 55 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

query I rowsort
SELECT - + 8 AS col2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 852581644118629bf652b1aa4b8f4363

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col0 * + col0 col2 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT - + col0 + col1 * col1 + - col0 FROM tab2 AS cor0
----
131
3325
947

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2, tab2 cor3
----
3645 values hashing to 773bb916e463ebc075d701108532badb

query I rowsort
SELECT ALL col2 * cor0.col2 + col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL + ( cor0.col2 ) FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT - col2 * col1 + col2 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + + ( col2 ) * col1 + + cor0.col2 * + col1 AS col0 FROM tab1 cor0
----
1140
2496
2808

onlyif mysql # use DIV operator for integer division
query I rowsort label-6686
SELECT DISTINCT - + col0 DIV cor0.col2 - col1 AS col1 FROM tab1 AS cor0
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-6686
SELECT DISTINCT - + col0 / cor0.col2 - col1 AS col1 FROM tab1 AS cor0
----
-11
-13
-26

query I rowsort
SELECT DISTINCT + - 24 * - col1 AS col0 FROM tab2 AS cor0
----
1416
408
744

query I rowsort
SELECT ALL cor0.col2 * col1 + col1 + col2 FROM tab2 AS cor0
----
1619
701
895

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 17 col2 FROM tab1 cor0
----
17
17
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - col1 col1 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT DISTINCT + col2 + + 66 + col0 * - col1 FROM tab2
----
-1239
-124
-4510

query I rowsort
SELECT DISTINCT - + col1 * 85 - + col0 FROM tab1 AS cor0
----
-1185
-2213
-914

onlyif mysql # use DIV operator for integer division
query I rowsort label-6693
SELECT DISTINCT - col1 DIV cor0.col2 + 72 FROM tab1 AS cor0
----
72

skipif mysql # not compatible
query I rowsort label-6693
SELECT DISTINCT - col1 / cor0.col2 + 72 FROM tab1 AS cor0
----
72

query I rowsort
SELECT ALL col2 * - 75 - - col2 FROM tab2 cor0
----
-1924
-1998
-2812

query I rowsort
SELECT - 44 FROM tab2, tab1 cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6696
SELECT col1 * col2 + - col0 + + col0 DIV ( col0 ) FROM tab0
----
2815
63
7374

skipif mysql # not compatible
query I rowsort label-6696
SELECT col1 * col2 + - col0 + + col0 / ( col0 ) FROM tab0
----
2815
63
7374

query I rowsort
SELECT DISTINCT 77 AS col1 FROM tab1, tab0 AS cor0
----
77

query I rowsort
SELECT DISTINCT - ( col1 ) + + col1 FROM tab1 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6699
SELECT + CAST( - 37 AS SIGNED ) * col0 AS col2 FROM tab0 cor0
----
-1295
-3293
-888

skipif mysql # not compatible
query I rowsort label-6699
SELECT + CAST ( - 37 AS INTEGER ) * col0 AS col2 FROM tab0 cor0
----
-1295
-3293
-888

query I rowsort
SELECT DISTINCT + - 84 * col2 FROM tab0 AS cor0
----
-2772
-6888
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6701
SELECT DISTINCT - col1 + + 86 DIV + col1 FROM tab2 AS cor0
----
-12
-29
-58

skipif mysql # not compatible
query I rowsort label-6701
SELECT DISTINCT - col1 + + 86 / + col1 FROM tab2 AS cor0
----
-12
-29
-58

query I rowsort
SELECT 95 * + tab2.col2 * + ( 99 + cor0.col1 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 2e3ee56ef8146aca45f3612123a7c5e3

query I rowsort
SELECT - 56 * col0 + + col1 FROM tab1 AS cor0
----
-142
-3574
-4467

query I rowsort
SELECT col2 * ( + col2 ) + col1 FROM tab2 AS cor0
----
1461
735
760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col0 col0 FROM tab0 cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * + col1 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6707
SELECT ALL + col2 DIV cor0.col0 col2 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6707
SELECT ALL + col2 / cor0.col0 col2 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT ALL + 94 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT - 87 * col1 AS col1 FROM tab0 AS cor0
----
-7482
-7917
-8439

query I rowsort
SELECT col1 + 33 * + col1 FROM tab0 AS cor0
----
2924
3094
3298

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 * - col0 col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT - col2 + col0 * - 10 AS col0 FROM tab2 AS cor0
----
-806
-828
-97

query I rowsort
SELECT DISTINCT - - col0 + - col2 + ( col0 ) * col1 AS col2 FROM tab1 AS cor0
----
1024
27
647

query I rowsort
SELECT DISTINCT + col0 + + col2 * - 22 AS col2 FROM tab0 AS cor0
----
-1715
-702
13

query I rowsort
SELECT - tab2.col1 * + ( col0 ) AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col0 + ( 36 ) AS col2 FROM tab2 AS cor0
----
114
115
43

query I rowsort
SELECT + col2 - col0 * + col2 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT + cor0.col0 * ( col0 ) + - col2 AS col2 FROM tab0 AS cor0
----
1224
543
7839

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6719
SELECT - + CAST( NULL AS SIGNED ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6719
SELECT - + CAST ( NULL AS INTEGER ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6720
SELECT - CAST( - col1 AS SIGNED ) * col1 + col1 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
174
262
705

skipif mysql # not compatible
query I rowsort label-6720
SELECT - CAST ( - col1 AS INTEGER ) * col1 + col1 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
174
262
705

query I rowsort
SELECT + tab0.col0 * + col1 + - col1 AS col0 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT ALL + tab1.col1 * 79 + col2 * col2 AS col0 FROM tab1
----
10243
4039
4970

query I rowsort
SELECT 13 * col2 * + col2 AS col0 FROM tab2 AS cor0
----
18772
8788
9477

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + + col2 col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6725
SELECT DISTINCT + tab0.col2 DIV 63 FROM tab0, tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-6725
SELECT DISTINCT + tab0.col2 / 63 FROM tab0, tab1 AS cor0
----
0
1

query I rowsort
SELECT tab2.col1 + col0 + col2 * + col0 AS col1 FROM tab2
----
2165
227
3098

query I rowsort
SELECT DISTINCT col0 + + 10 AS col1 FROM tab1
----
13
74
90

query I rowsort
SELECT ALL col1 * + col2 - col0 AS col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT + col1 * + 45 + col1 * + cor0.col2 FROM tab1 AS cor0
----
1020
1833
2574

query I rowsort
SELECT - col1 * 63 + col0 FROM tab1 AS cor0
----
-1635
-566
-739

query I rowsort
SELECT DISTINCT - col1 + 71 FROM tab1 AS cor0
----
45
58
61

query I rowsort
SELECT DISTINCT + tab1.col0 * + col2 AS col1 FROM tab1
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6733
SELECT DISTINCT + col2 + - CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6733
SELECT DISTINCT + col2 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL

query I rowsort
SELECT ALL + col2 * ( + col0 * col2 ) + col0 * 77 FROM tab2
----
120159
5642
58734

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6735
SELECT ALL col0 * - CAST( + col1 * - col0 AS SIGNED ) + + tab2.col0 FROM tab2
----
106176
1526
359034

skipif mysql # not compatible
query I rowsort label-6735
SELECT ALL col0 * - CAST ( + col1 * - col0 AS INTEGER ) + + tab2.col0 FROM tab2
----
106176
1526
359034

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - 57 + col0 col0 FROM tab1
----
-168
-3584
-4480

query I rowsort
SELECT ALL + 4 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT - col1 - 79 AS col0 FROM tab2
----
-110
-138
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6739
SELECT col0 + + 19 DIV - 3 AS col1 FROM tab0 AS cor0
----
18
29
83

skipif mysql # not compatible
query I rowsort label-6739
SELECT col0 + + 19 / - 3 AS col1 FROM tab0 AS cor0
----
18
29
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6740
SELECT DISTINCT - CAST( NULL AS SIGNED ) + 26 AS col2 FROM tab1, tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6740
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + 26 AS col2 FROM tab1, tab0, tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6741
SELECT ALL - CAST( col0 AS SIGNED ) * col0 FROM tab0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-6741
SELECT ALL - CAST ( col0 AS INTEGER ) * col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT 99 + + 33 AS col1 FROM tab2
----
132
132
132

query I rowsort
SELECT ALL + col2 * 0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6744
SELECT + - col2 + - cor0.col2 DIV - col2 AS col0 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-6744
SELECT + - col2 + - cor0.col2 / - col2 AS col0 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT DISTINCT + cor0.col2 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
26
27
38

query I rowsort
SELECT + ( - col0 * + col0 ) + + col1 FROM tab0
----
-1128
-490
-7830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6747
SELECT + 32 + + col2 * - CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6747
SELECT + 32 + + col2 * - CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 + - 69 col1 FROM tab1
----
-1109
-147
-709

query I rowsort
SELECT + + cor1.col2 AS col1 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT col2 * col2 * + col2 + + col2 AS col0 FROM tab1 cor0
----
157518
185250
884832

query I rowsort
SELECT + + 19 * col0 + - ( col0 ) - col2 * - col2 FROM tab1 AS cor0
----
10656
2970
4401

onlyif mysql # use DIV operator for integer division
query I rowsort label-6752
SELECT DISTINCT - + cor0.col0 DIV + col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-6752
SELECT DISTINCT - + cor0.col0 / + col2 FROM tab0 AS cor0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6753
SELECT ALL + col0 + - col0 DIV - cor0.col1 AS col0 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-6753
SELECT ALL + col0 + - col0 / - cor0.col1 AS col0 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT + ( + col1 ) + - col2 + - col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL 72 * col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
3914
4114
6925

query I rowsort
SELECT - col1 + col1 - + 64 AS col0 FROM tab1 AS cor0
----
-64
-64
-64

query I rowsort
SELECT ALL + - 48 FROM tab1 cor0
----
-48
-48
-48

query I rowsort
SELECT + 63 * col0 FROM tab0
----
1512
2205
5607

onlyif mysql # use DIV operator for integer division
query I rowsort label-6759
SELECT col2 * - col2 DIV col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6759
SELECT col2 * - col2 / col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT ( + col1 ) + + col0 * 98 + + col2 AS col1 FROM tab1 AS cor0
----
374
6339
7949

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 89 + col1 col1 FROM tab0 AS cor0
----
-3
2
8

query I rowsort
SELECT ALL + ( col0 ) + col1 * - 49 + col0 FROM tab0 AS cor0
----
-4166
-4281
-4683

query I rowsort
SELECT DISTINCT - 85 + col0 FROM tab1 AS cor0
----
-21
-5
-82

query I rowsort
SELECT + col1 * col1 - + col1 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
4558
819
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * col2 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + cor0.col0 + + 80 * + col0 * + col1 AS col2 FROM tab1 AS cor0
----
51264
6243
83280

query I rowsort
SELECT DISTINCT col0 * col2 + 76 FROM tab2 AS cor0
----
2104
265
3078

query I rowsort
SELECT - col2 * + col1 + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6769
SELECT + col2 DIV + 1 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6769
SELECT + col2 / + 1 AS col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6770
SELECT + col1 + - 20 DIV col0 FROM tab1 AS cor0
----
10
13
20

skipif mysql # not compatible
query I rowsort label-6770
SELECT + col1 + - 20 / col0 FROM tab1 AS cor0
----
10
13
20

query I rowsort
SELECT col0 + - col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6772
SELECT DISTINCT + - col2 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6772
SELECT DISTINCT + - col2 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6773
SELECT - col2 * cor0.col0 + + ( - cor0.col0 ) DIV + 12 AS col2 FROM tab0 AS cor0
----
-37
-7305
-794

skipif mysql # not compatible
query I rowsort label-6773
SELECT - col2 * cor0.col0 + + ( - cor0.col0 ) / + 12 AS col2 FROM tab0 AS cor0
----
-37
-7305
-794

onlyif mysql # use DIV operator for integer division
query I rowsort label-6774
SELECT col1 DIV + col0 + + col0 AS col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-6774
SELECT col1 / + col0 + + col0 AS col0 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT ALL - - col2 * ( + 76 ) FROM tab0 AS cor0
----
2508
6232
76

query I rowsort
SELECT DISTINCT + cor0.col1 * ( 58 ) * col1 AS col1 FROM tab0 AS cor0
----
428968
480298
545722

onlyif mysql # use DIV operator for integer division
query I rowsort label-6777
SELECT + + col1 DIV 57 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6777
SELECT + + col1 / 57 FROM tab2 cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6778
SELECT + - col0 DIV - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6778
SELECT + - col0 / - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - cor0.col2 + - 31 AS col0 FROM tab2 cor0
----
-4
-5
7

query I rowsort
SELECT ALL col1 * col1 + col2 AS col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ( + ( col2 ) ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + ( + col0 ) + + cor0.col1 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT 91 * - col2 FROM tab0 cor0
----
-3003
-7462
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col1 * col2 col2 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6785
SELECT - + CAST( - col1 AS SIGNED ) FROM tab2 cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6785
SELECT - + CAST ( - col1 AS INTEGER ) FROM tab2 cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 9 ) col0 FROM tab2 AS cor0
----
9
9
9

query I rowsort
SELECT DISTINCT 11 + col2 FROM tab2 AS cor0
----
37
38
49

query I rowsort
SELECT ALL + + ( + col2 ) * col1 + + ( 40 ) * col0 AS col1 FROM tab1 AS cor0
----
1524
3130
4448

query I rowsort
SELECT DISTINCT - col0 - + col2 AS col0 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6790
SELECT ALL + + col1 + + col1 + - col2 DIV - col0 col0 FROM tab1 AS cor0
----
20
27
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6790
SELECT ALL + + col1 + + col1 + - col2 / - col0 col0 FROM tab1 AS cor0
----
20
27
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6791
SELECT DISTINCT + + col0 DIV col2 - + cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
-169
-676
-99

skipif mysql # not compatible
query I rowsort label-6791
SELECT DISTINCT + + col0 / col2 - + cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
-169
-676
-99

query I rowsort
SELECT DISTINCT + 61 + 10 AS col0 FROM tab2 AS cor0
----
71

query I rowsort
SELECT DISTINCT + - ( + col1 ) - + col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - 37 + + col1 FROM tab0 AS cor0
----
49
54
60

query I rowsort
SELECT ALL + + col2 * + 39 FROM tab2 AS cor0
----
1014
1053
1482

query I rowsort
SELECT DISTINCT - 2 * col2 FROM tab1
----
-108
-114
-192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + - cor0.col2 col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + col0 + col0 + - col2 * - col1 FROM tab1 AS cor0
----
1408
1410
698

query I rowsort
SELECT ALL 82 * + col1 FROM tab2 AS cor0
----
1394
2542
4838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 32 * + col1 ) col1 FROM tab0
----
-2752
-2912
-3104

query I rowsort
SELECT - tab0.col2 * col2 * + col0 AS col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL + - col2 * - col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT col2 * - col0 * + col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-6804
SELECT col0 * + col2 DIV + col2 + - col0 DIV col2 + col0 FROM tab0 AS cor0
----
177
35
48

skipif mysql # not compatible
query I rowsort label-6804
SELECT col0 * + col2 / + col2 + - col0 / col2 + col0 FROM tab0 AS cor0
----
177
35
48

query I rowsort
SELECT col1 * - col1 * col1 AS col0 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT - col2 * - col2 * + col2 AS col0 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT + + ( col0 ) + col2 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT + cor0.col0 - col2 * + col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT ALL - + 26 * - col1 AS col2 FROM tab2 AS cor0
----
1534
442
806

query I rowsort
SELECT + col1 - + col0 AS col1 FROM tab0 cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + col2 * - col0 col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT - col1 + - cor0.col2 * col0 AS col0 FROM tab0 AS cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-6813
SELECT ALL - col1 + col2 DIV + col0 AS col0 FROM tab0 cor0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-6813
SELECT ALL - col1 + col2 / + col0 AS col0 FROM tab0 cor0
----
-85
-91
-97

query I rowsort
SELECT DISTINCT + - cor0.col0 * col0 + col1 * cor0.col0 FROM tab0 cor0
----
1488
178
2170

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6815
SELECT - CAST( - tab0.col2 AS SIGNED ) * + col2 AS col0 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-6815
SELECT - CAST ( - tab0.col2 AS INTEGER ) * + col2 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT 30 * col1 * col1 AS col1 FROM tab2
----
104430
28830
8670

query I rowsort
SELECT col1 * + col2 + - col1 FROM tab2
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6818
SELECT CAST( NULL AS DECIMAL ) / + tab0.col1 col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6818
SELECT CAST ( NULL AS REAL ) / + tab0.col1 col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + cor0.col1 * + col0 col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT + ( - col2 ) * cor0.col2 + - cor0.col0 FROM tab0 AS cor0
----
-1113
-36
-6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-6821
SELECT ALL 4 + + col0 + + col2 DIV + col0 FROM tab1 AS cor0
----
25
68
85

skipif mysql # not compatible
query I rowsort label-6821
SELECT ALL 4 + + col0 + + col2 / + col0 FROM tab1 AS cor0
----
25
68
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6822
SELECT + 54 DIV - tab0.col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6822
SELECT + 54 / - tab0.col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6823
SELECT + col1 * col1 * col0 + - col1 DIV + tab0.col1 FROM tab0
----
177503
329314
737008

skipif mysql # not compatible
query I rowsort label-6823
SELECT + col1 * col1 * col0 + - col1 / + tab0.col1 FROM tab0
----
177503
329314
737008

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL > ( col1 / - col2 )
----

query I rowsort
SELECT + col2 * + col0 * - col2 AS col0 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT col1 * col1 * - col2 AS col1 FROM tab1
----
-16224
-36504
-5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-6827
SELECT col0 * col2 + - col0 DIV - tab1.col2 FROM tab1
----
162
3649
7680

skipif mysql # not compatible
query I rowsort label-6827
SELECT col0 * col2 + - col0 / - tab1.col2 FROM tab1
----
162
3649
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6828
SELECT col0 DIV + col0 + col2 AS col1 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-6828
SELECT col0 / + col0 + col2 AS col1 FROM tab1
----
55
58
97

query I rowsort
SELECT - col0 * + col1 - col1 FROM tab0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL tab0.col0 * col1 - - tab0.col1 * - col2 FROM tab0
----
-774
3298
637

query III rowsort
SELECT * FROM tab1 WHERE + col2 >= ( NULL )
----

query I rowsort
SELECT DISTINCT + tab2.col0 - - col0 * tab2.col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT ALL tab1.col2 * - col0 + - col1 AS col0 FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT - col1 FROM tab0 WHERE NOT - col1 IN ( + col2 * col2 )
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + tab0.col2 * - col0 * col2 + - col2 FROM tab0
----
-26169
-36
-598518

query I rowsort
SELECT ALL col0 + + tab1.col2 + col1 AS col1 FROM tab1
----
131
189
83

query I rowsort
SELECT col0 * col2 + + tab2.col1 AS col1 FROM tab2
----
2087
220
3019

query III rowsort
SELECT * FROM tab1 WHERE + col0 * - col2 NOT BETWEEN col1 * col2 - col0 AND NULL
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

onlyif mysql # use DIV operator for integer division
query I rowsort label-6839
SELECT DISTINCT col2 + col2 DIV col1 AS col1 FROM tab1
----
103
56
62

skipif mysql # not compatible
query I rowsort label-6839
SELECT DISTINCT col2 + col2 / col1 AS col1 FROM tab1
----
103
56
62

query I rowsort
SELECT ALL col1 + col0 * + tab0.col0 FROM tab0 WHERE NULL >= - col1
----

query I rowsort
SELECT col0 * + tab0.col1 AS col2 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6842
SELECT - tab0.col0 DIV col2 + - col2 FROM tab0
----
-33
-36
-83

skipif mysql # not compatible
query I rowsort label-6842
SELECT - tab0.col0 / col2 + - col2 FROM tab0
----
-33
-36
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6843
SELECT ALL + col2 + col1 * + col0 + col0 DIV col1 FROM tab1
----
1142
132
703

skipif mysql # not compatible
query I rowsort label-6843
SELECT ALL + col2 + col1 * + col0 + col0 / col1 FROM tab1
----
1142
132
703

onlyif mysql # use DIV operator for integer division
query I rowsort label-6844
SELECT DISTINCT + col1 DIV col2 + col0 * col1 * - col0 + + col2 DIV - col0 FROM tab0
----
-118728
-49535
-720810

skipif mysql # not compatible
query I rowsort label-6844
SELECT DISTINCT + col1 / col2 + col0 * col1 * - col0 + + col2 / - col0 FROM tab0
----
-118728
-49535
-720810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 col1 FROM tab0 WHERE ( NULL ) IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6846
SELECT ALL - col2 DIV col0 + - col0 DIV + col1 + col0 AS col0 FROM tab1
----
-15
58
73

skipif mysql # not compatible
query I rowsort label-6846
SELECT ALL - col2 / col0 + - col0 / + col1 + col0 AS col0 FROM tab1
----
-15
58
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 col2 FROM tab2 WHERE NULL < ( NULL )
----

query I rowsort
SELECT ALL - col1 + tab1.col2 + + col1 AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT col0 FROM tab0 AS cor0 WHERE NOT col0 / cor0.col0 BETWEEN NULL AND + col2 - col2
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6850
SELECT + - col1 DIV cor0.col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-6850
SELECT + - col1 / cor0.col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT ALL + tab0.col0 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - col2 * - col0 * + col0 + col2 * - col1 AS col1 FROM tab2
----
156650
236512
486

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL = col1 * + col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6854
SELECT ALL col2 DIV - tab1.col2 AS col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6854
SELECT ALL col2 / - tab1.col2 AS col2 FROM tab1
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6855
SELECT + col0 DIV - col1 FROM tab1 WHERE NOT col1 - + col1 <= col1 + - col0
----
-6
-6

skipif mysql # not compatible
query I rowsort label-6855
SELECT + col0 / - col1 FROM tab1 WHERE NOT col1 - + col1 <= col1 + - col0
----
-6
-6

query I rowsort
SELECT tab0.col1 * col0 + - col1 * + col0 + col2 AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT col0 * + col0 * cor0.col2 AS col1 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT ALL + 69 * 82 + col1 * - col1 FROM tab0 cor0
----
-1738
-2623
-3751

query I rowsort
SELECT ALL - ( 24 ) FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT DISTINCT + col0 * col2 + col2 AS col0 FROM tab1
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6861
SELECT DISTINCT + + ( col0 ) / col0 + CAST( NULL AS SIGNED ) * 87 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6861
SELECT DISTINCT + + ( col0 ) / col0 + CAST ( NULL AS INTEGER ) * 87 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - + col2 * - col1 - + col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT + 99 * 19 + - col2 * col2 AS col2 FROM tab0 AS cor0
----
-4843
1880
792

query I rowsort
SELECT col0 + col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL col0 * 48 AS col1 FROM tab0 AS cor0
----
1152
1680
4272

query I rowsort
SELECT ALL + - 93 + 58 AS col1 FROM tab0 AS cor0
----
-35
-35
-35

onlyif mysql # use DIV operator for integer division
query I rowsort label-6867
SELECT ALL 51 DIV col2 + col1 AS col2 FROM tab0 cor0
----
148
87
91

skipif mysql # not compatible
query I rowsort label-6867
SELECT ALL 51 / col2 + col1 AS col2 FROM tab0 cor0
----
148
87
91

query I rowsort
SELECT 21 - + 89 * - col0 AS col1 FROM tab0 AS cor0
----
2157
3136
7942

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( cor0.col0 ) col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL 17 * - col0 + col1 FROM tab1 AS cor0
----
-1078
-1347
-25

query I rowsort
SELECT ALL - col0 * cor0.col1 + + col0 FROM tab0 cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 + - cor0.col2 * col2 * cor0.col2 col0 FROM tab1 cor0
----
-157410
-185136
-884640

onlyif mysql # use DIV operator for integer division
query I rowsort label-6873
SELECT DISTINCT - 19 * col2 DIV - col2 AS col0 FROM tab1 AS cor0
----
19

skipif mysql # not compatible
query I rowsort label-6873
SELECT DISTINCT - 19 * col2 / - col2 AS col0 FROM tab1 AS cor0
----
19

query I rowsort
SELECT - 20 + + col1 FROM tab1 AS cor0
----
-10
-7
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6875
SELECT DISTINCT - 92 + + col2 DIV 54 FROM tab2 AS cor0
----
-92

skipif mysql # not compatible
query I rowsort label-6875
SELECT DISTINCT - 92 + + col2 / 54 FROM tab2 AS cor0
----
-92

query I rowsort
SELECT ( - col1 ) * - col1 AS col0 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL col1 * col2 + col0 * + ( col0 ) - - col0 * col2 FROM tab0
----
1357
22681
4206

query I rowsort
SELECT ALL - col1 + - tab1.col2 * col0 - col2 AS col2 FROM tab1
----
-242
-3715
-7789

query I rowsort
SELECT - 98 * col1 AS col2 FROM tab2
----
-1666
-3038
-5782

query I rowsort
SELECT ALL col2 + col0 * 94 * col1 AS col2 FROM tab1 AS cor0
----
60217
7386
97856

query I rowsort
SELECT DISTINCT - col1 * + 97 * - 57 + + col1 + col0 FROM tab0 AS cor0
----
475604
503319
536445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col1 * + ( col1 ) col0 FROM tab0 AS cor0
----
244068
679042
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6883
SELECT DISTINCT col2 + + CAST( NULL AS SIGNED ) + - 30 col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6883
SELECT DISTINCT col2 + + CAST ( NULL AS INTEGER ) + - 30 col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL ( tab1.col2 ) + - col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col0 * - col0 + + col0 AS col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT col0 + - col1 * + ( + col1 ) FROM tab2 AS cor0
----
-210
-3403
-954

onlyif mysql # use DIV operator for integer division
query I rowsort label-6887
SELECT ALL col1 DIV ( col2 * + col0 ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6887
SELECT ALL col1 / ( col2 * + col0 ) FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + + 20 - 16 FROM tab1 AS cor0
----
4
4
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6889
SELECT ALL tab1.col0 DIV tab1.col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6889
SELECT ALL tab1.col0 / tab1.col0 FROM tab1
----
1
1
1

query I rowsort
SELECT + ( + col2 ) + + col1 * - col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT - ( + tab0.col0 + + col0 ) AS col1 FROM tab0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 29 col1 FROM tab0
----
-29

query I rowsort
SELECT DISTINCT - tab1.col2 + - col0 * + col2 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT 61 + - col1 * col2 AS col1 FROM tab1
----
-1187
-1343
-509

query I rowsort
SELECT ALL col2 * - col0 + col2 * + col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * - 46 * + col0 FROM tab0 AS cor0
----
1610
335708
36432

query I rowsort
SELECT DISTINCT + 29 * col0 AS col2 FROM tab1 AS cor0
----
1856
2320
87

query I rowsort
SELECT ALL - ( + 70 ) - + col1 AS col0 FROM tab1 AS cor0
----
-80
-83
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6899
SELECT ALL + ( - col0 ) + + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6899
SELECT ALL + ( - col0 ) + + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 + + col0 * + 74 + 30 FROM tab1
----
198
4709
5854

query I rowsort
SELECT DISTINCT + tab1.col0 + + col1 * + col1 + col1 AS col0 FROM tab1
----
174
262
705

query I rowsort
SELECT ( col1 ) * 88 * col2 FROM tab2
----
134992
56848
73656

query I rowsort
SELECT ( col0 ) - col2 AS col2 FROM tab1
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6904
SELECT ALL tab2.col1 * tab2.col1 * + CAST( NULL AS DECIMAL ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6904
SELECT ALL tab2.col1 * tab2.col1 * + CAST ( NULL AS REAL ) FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6905
SELECT ALL + 0 DIV - col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6905
SELECT ALL + 0 / - col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT 98 * + col0 FROM tab1 AS cor0
----
294
6272
7840

query I rowsort
SELECT DISTINCT - 56 + + col1 * - col1 AS col1 FROM tab1 AS cor0
----
-156
-225
-732

query I rowsort
SELECT DISTINCT - col1 * 22 - col2 * + col2 * + col2 AS col1 FROM tab2 AS cor0
----
-18874
-20365
-55246

query I rowsort
SELECT DISTINCT + + col2 * + col1 + 54 AS col1 FROM tab0 cor0
----
151
2892
7516

query I rowsort
SELECT + col2 + 78 FROM tab0 AS cor0
----
111
160
79

query I rowsort
SELECT col0 + 73 FROM tab2 cor0
----
151
152
80

query I rowsort
SELECT - 62 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to d2579f9395350eda865ff3a2d38a74f6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col2 col1 FROM tab0
----
119
173
98

query I rowsort
SELECT + col1 + + col2 * + 24 FROM tab1 cor0
----
1322
1378
2317

query I rowsort
SELECT + + col1 * - 32 + col2 AS col0 FROM tab1 AS cor0
----
-263
-320
-778

query I rowsort
SELECT DISTINCT + col1 * 90 FROM tab2 AS cor0
----
1530
2790
5310

query I rowsort
SELECT - 88 * + col0 + + col1 * ( - col0 ) FROM tab1
----
-342
-6272
-8080

query I rowsort
SELECT + - 67 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 95c9eba643f6489e03be4d5e83f1ef99

query I rowsort
SELECT + col1 * - col0 + - cor0.col0 - + col0 * + col1 FROM tab0 AS cor0
----
-16287
-4152
-6825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6920
SELECT DISTINCT ( - col2 ) DIV + 57 + col2 * col0 col2 FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6920
SELECT DISTINCT ( - col2 ) / + 57 + col2 * col0 col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + col0 + + cor0.col2 * cor0.col1 AS col0 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT + col2 * 34 + 63 FROM tab1 AS cor0
----
1899
2001
3327

query I rowsort
SELECT 51 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT ALL - - col2 * + ( col0 ) AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + col2 - cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 + col1 col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - + col1 * col1 + - col2 * + col2 * - col2 FROM tab1 AS cor0
----
156788
185093
884567

onlyif mysql # use DIV operator for integer division
query I rowsort label-6928
SELECT DISTINCT 32 DIV col1 + col2 AS col0 FROM tab1
----
55
60
98

skipif mysql # not compatible
query I rowsort label-6928
SELECT DISTINCT 32 / col1 + col2 AS col0 FROM tab1
----
55
60
98

query I rowsort
SELECT DISTINCT + + 77 AS col0 FROM tab2, tab1, tab2 AS cor0
----
77

query I rowsort
SELECT col1 * 57 AS col2 FROM tab1 AS cor0
----
1482
570
741

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col2 col1 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6932
SELECT - col0 / + CAST( NULL AS SIGNED ) + - col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6932
SELECT - col0 / + CAST ( NULL AS INTEGER ) + - col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6933
SELECT ALL + + 85 + col0 DIV + col1 AS col1 FROM tab1 AS cor0
----
85
91
91

skipif mysql # not compatible
query I rowsort label-6933
SELECT ALL + + 85 + col0 / + col1 AS col1 FROM tab1 AS cor0
----
85
91
91

query I rowsort
SELECT DISTINCT + - 20 * 97 AS col2 FROM tab1 AS cor0
----
-1940

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 89 * cor0.col0 col0 FROM tab1 cor0
----
-267
-5696
-7120

query I rowsort
SELECT ALL 47 * + 87 + - cor0.col2 * + col2 * + col1 FROM tab0 AS cor0
----
-607795
-89565
3992

query I rowsort
SELECT col1 * col2 * - col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL + 53 FROM tab1, tab1 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT + cor0.col1 * + col1 + + col0 AS col2 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT ALL + ( col2 ) * - col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + + cor0.col0 + col1 + + cor0.col0 FROM tab0 cor0
----
134
167
269

query I rowsort
SELECT - + 12 * - 11 FROM tab0 AS cor0
----
132
132
132

query I rowsort
SELECT DISTINCT - - cor0.col0 + + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - - cor0.col0 * col2 + cor0.col2 AS col2 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT + - ( - col0 ) - 12 FROM tab1 AS cor0
----
-9
52
68

query I rowsort
SELECT ALL 36 + tab0.col2 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 02e74cc85484ebef95d60e4d930018a3

query I rowsort
SELECT ( + col1 ) + col0 + + col0 FROM tab1
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-6948
SELECT DISTINCT + 67 DIV + cor0.col1 FROM tab0, tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-6948
SELECT DISTINCT + 67 / + cor0.col1 FROM tab0, tab1 AS cor0
----
2
5
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6949
SELECT - - cor0.col0 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6949
SELECT - - cor0.col0 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - ( 56 * + col1 ) FROM tab1
----
-1456
-560
-728

query I rowsort
SELECT ALL + 49 + + col2 * - ( col0 ) AS col0 FROM tab0 AS cor0
----
-7249
-743
14

query I rowsort
SELECT 22 * col1 AS col0 FROM tab2
----
1298
374
682

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6953
SELECT ALL - col2 * + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6953
SELECT ALL - col2 * + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * + 71 AS col2 FROM tab2 AS cor0
----
497
5538
5609

onlyif mysql # use DIV operator for integer division
query I rowsort label-6955
SELECT 57 DIV col0 AS col0 FROM tab1
----
0
0
19

skipif mysql # not compatible
query I rowsort label-6955
SELECT 57 / col0 AS col0 FROM tab1
----
0
0
19

query I rowsort
SELECT DISTINCT + tab2.col0 * - col2 * 48 - + col1 AS col2 FROM tab2
----
-144113
-9103
-97403

query I rowsort
SELECT - cor0.col2 AS col2 FROM tab1 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
1
33
82

query I rowsort
SELECT - ( - 58 ) * - col2 AS col2 FROM tab1 AS cor0
----
-3132
-3306
-5568

query I rowsort
SELECT + col1 * - col2 * - col2 + + col1 * col0 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-319072
-81549
21080

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + 81 AS REAL ) FROM tab1 AS cor0
----
81
81
81

query I rowsort
SELECT - 37 FROM tab0, tab2 cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6963
SELECT DISTINCT - CAST( 70 AS SIGNED ) AS col2 FROM tab1
----
-70

skipif mysql # not compatible
query I rowsort label-6963
SELECT DISTINCT - CAST ( 70 AS INTEGER ) AS col2 FROM tab1
----
-70

query I rowsort
SELECT 3 FROM tab2, tab2 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + tab0.col1 ) col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( 75 AS REAL ) col0 FROM tab1
----
75
75
75

query I rowsort
SELECT DISTINCT + 40 AS col0 FROM tab1
----
40

query I rowsort
SELECT - ( col0 ) + col0 * - col1 FROM tab1 cor0
----
-1120
-704
-81

query I rowsort
SELECT - ( + col1 ) * col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + 2 FROM tab0, tab1 AS cor0
----
2

query I rowsort
SELECT DISTINCT + tab0.col0 * - tab0.col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + 19 FROM tab2, tab2 AS cor0
----
19

query I rowsort
SELECT + col0 + - 53 AS col2 FROM tab1
----
-50
11
27

query I rowsort
SELECT DISTINCT + + col1 + col2 * col1 * col1 AS col0 FROM tab2 AS cor0
----
10999
25978
90565

onlyif mysql # use DIV operator for integer division
query I rowsort label-6975
SELECT + - col2 DIV - 50 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6975
SELECT + - col2 / - 50 AS col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - col0 * ( col1 ) + col1 * + ( + 2 + col1 * cor0.col1 ) FROM tab0 cor0
----
634164
745654
909472

query I rowsort
SELECT + + col2 * + 19 FROM tab0 AS cor0
----
1558
19
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-6978
SELECT - - col0 * cor0.col2 DIV 75 FROM tab1 cor0
----
102
2
48

skipif mysql # not compatible
query I rowsort label-6978
SELECT - - col0 * cor0.col2 / 75 FROM tab1 cor0
----
102
2
48

query I rowsort
SELECT DISTINCT + + 92 - - col2 * + col0 AS col1 FROM tab1 AS cor0
----
254
3740
7772

onlyif mysql # use DIV operator for integer division
query I rowsort label-6980
SELECT ALL - ( + col1 ) * + col2 - 81 DIV - cor0.col0 col1 FROM tab2 AS cor0
----
-1533
-645
-826

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6980
SELECT ALL - ( + col1 ) * + col2 - 81 / - cor0.col0 col1 FROM tab2 AS cor0
----
-1533
-645
-826

query I rowsort
SELECT ALL 66 + - col1 AS col0 FROM tab2 AS cor0
----
35
49
7

query I rowsort
SELECT ALL + + col0 - cor0.col2 * + col1 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + ( cor0.col2 ) + + col2 * - 58 FROM tab2 AS cor0
----
-1482
-1539
-2166

onlyif mysql # use DIV operator for integer division
query I rowsort label-6984
SELECT DISTINCT + 7 DIV 90 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
0

skipif mysql # not compatible
query I rowsort label-6984
SELECT DISTINCT + 7 / 90 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 12 col1 FROM tab2 cor0
----
12
12
12

query I rowsort
SELECT DISTINCT - 74 * col2 + + cor0.col0 * 15 FROM tab0 cor0
----
-2082
-4733
451

query I rowsort
SELECT ALL col1 * - col2 + cor0.col0 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - col1 * + col1 + - col2 FROM tab0
----
-7429
-8363
-9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col0 * col2 + col0 col0 FROM tab0 AS cor0
----
105
7476
840

query I rowsort
SELECT - col0 * - col1 + - col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL - col2 * ( 75 ) + - col0 AS col2 FROM tab2 AS cor0
----
-2028
-2032
-2929

query I rowsort
SELECT DISTINCT + - col2 * ( - col1 ) * col2 AS col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT - - col0 * + 28 + ( col2 ) * 27 AS col0 FROM tab0 AS cor0
----
1007
1563
4706

query I rowsort
SELECT DISTINCT - col0 + col1 * + 93 FROM tab0
----
7974
8374
8986

query I rowsort
SELECT ALL + + col1 * col1 * 21 + + col1 FROM tab0 cor0
----
155402
173992
197686

query I rowsort
SELECT + 20 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT ALL - - col1 + + 47 * 26 FROM tab2 AS cor0
----
1239
1253
1281

query I rowsort
SELECT ALL col2 * + ( + col2 ) AS col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6999
SELECT DISTINCT + + col0 + CAST( - 83 AS SIGNED ) AS col1 FROM tab0 cor0
----
-48
-59
6

skipif mysql # not compatible
query I rowsort label-6999
SELECT DISTINCT + + col0 + CAST ( - 83 AS INTEGER ) AS col1 FROM tab0 cor0
----
-48
-59
6

query I rowsort
SELECT ALL col0 + + col0 * 13 FROM tab0
----
1246
336
490

query I rowsort
SELECT - - col2 * 15 AS col2 FROM tab0 AS cor0
----
1230
15
495

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor1.col0 col0 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab2, tab2 AS cor2
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col1 + + 58 col0 FROM tab0 AS cor0
----
7454
8339
9467

query I rowsort
SELECT DISTINCT + col1 * ( + 56 ) AS col2 FROM tab2 AS cor0
----
1736
3304
952

query I rowsort
SELECT - col0 * 55 AS col2 FROM tab2 AS cor0
----
-385
-4290
-4345

query I rowsort
SELECT + tab0.col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL 64 - + col1 FROM tab2
----
33
47
5

query I rowsort
SELECT - ( col1 ) + col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT col2 + - col2 + tab2.col1 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 21 - 61 col1 FROM tab2
----
-40
-40
-40

query I rowsort
SELECT col2 + 10 FROM tab0
----
11
43
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-7012
SELECT ( - col1 ) + - col1 DIV - col0 FROM tab2
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-7012
SELECT ( - col1 ) + - col1 / - col0 FROM tab2
----
-17
-27
-59

query I rowsort
SELECT 70 FROM tab0, tab2 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT DISTINCT col0 + 9 + - col1 * - col1 AS col1 FROM tab2
----
3568
377
977

query I rowsort
SELECT DISTINCT - ( - col2 * col0 ) + tab0.col1 * + 28 * tab0.col1 AS col2 FROM tab0
----
207880
239166
263487

query I rowsort
SELECT 68 * - col2 AS col1 FROM tab1
----
-3672
-3876
-6528

onlyif mysql # use DIV operator for integer division
query I rowsort label-7017
SELECT DISTINCT ( tab0.col1 ) DIV - col1 - ( - col1 ) col1 FROM tab0
----
85
90
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7017
SELECT DISTINCT ( tab0.col1 ) / - col1 - ( - col1 ) col1 FROM tab0
----
85
90
96

query I rowsort
SELECT + col2 - + col1 * - col2 * tab0.col1 FROM tab0
----
244101
679124
9410

query I rowsort
SELECT + cor0.col0 + col2 * + col2 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT col2 * - col2 - + ( 76 ) * col1 FROM tab1 AS cor0
----
-10204
-4009
-4892

query I rowsort
SELECT - ( + 32 ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 + col2 col2 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL + + ( col0 ) + + ( col1 ) * - col1 * ( - col1 * + col2 + - col0 * + col0 ) AS col0 FROM tab2 cor0
----
1990422
26518336
851453

query I rowsort
SELECT DISTINCT + - ( col1 ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * cor0.col2 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - - col2 - - col1 AS col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7027
SELECT DISTINCT cor0.col0 * - cor0.col1 + + col0 DIV + 54 - col2 * + col0 * - col0 FROM tab1 AS cor0
----
232833
408
613361

skipif mysql # not compatible
query I rowsort label-7027
SELECT DISTINCT cor0.col0 * - cor0.col1 + + col0 / + 54 - col2 * + col0 * - col0 FROM tab1 AS cor0
----
232833
408
613361

query I rowsort
SELECT ALL ( + col0 ) + 14 FROM tab0 AS cor0
----
103
38
49

query I rowsort
SELECT + + 72 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
105
154
73

query I rowsort
SELECT DISTINCT 32 AS col1 FROM tab2 AS cor0
----
32

query I rowsort
SELECT - col0 * col2 + - col0 * col1 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT + col2 + + 53 * col0 AS col0 FROM tab1 AS cor0
----
213
3449
4336

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
54
57
96

query I rowsort
SELECT - col1 - + ( col2 ) * + 67 FROM tab0 AS cor0
----
-164
-2297
-5585

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7035
SELECT CAST( col1 + + col2 AS SIGNED ) AS col1 FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-7035
SELECT CAST ( col1 + + col2 AS INTEGER ) AS col1 FROM tab1
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7036
SELECT + col2 * + col1 * + CAST( + col0 AS SIGNED ) + - tab1.col2 AS col1 FROM tab1
----
36423
4158
99744

skipif mysql # not compatible
query I rowsort label-7036
SELECT + col2 * + col1 * + CAST ( + col0 AS INTEGER ) + - tab1.col2 AS col1 FROM tab1
----
36423
4158
99744

query I rowsort
SELECT + col1 * - tab1.col1 * - col0 + + col2 FROM tab1
----
13616
2082
6457

query I rowsort
SELECT col1 * ( col1 ) * - col1 AS col2 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT 58 + + cor0.col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to a6cc78aea0ca29cf31cdef56fbe5963b

query I rowsort
SELECT DISTINCT - 18 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
-18

query I rowsort
SELECT - cor1.col1 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7042
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab2, tab1 cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-7042
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab2, tab1 cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT ALL - col0 + ( - col1 ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL - col2 + + col2 * col2 * col1 - 68 * - col0 AS col1 FROM tab0 AS cor0
----
2476
617854
95253

query I rowsort
SELECT - col2 + - ( 47 ) FROM tab0 AS cor0
----
-129
-48
-80

query I rowsort
SELECT col0 * col2 * col1 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT cor0.col1 * - cor0.col0 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-7048
SELECT + tab2.col1 + - 40 DIV + tab2.col0 col2 FROM tab2
----
17
26
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7048
SELECT + tab2.col1 + - 40 / + tab2.col0 col2 FROM tab2
----
17
26
59

query I rowsort
SELECT ALL + col0 * + col1 * - 33 FROM tab1
----
-21120
-2574
-34320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7050
SELECT + - CAST( NULL AS SIGNED ) + - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7050
SELECT + - CAST ( NULL AS INTEGER ) + - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col2 + 30 FROM tab2 cor0
----
56
57
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7052
SELECT - ( + col0 ) + - col1 * - CAST( 82 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1315
2535
4760

skipif mysql # not compatible
query I rowsort label-7052
SELECT - ( + col0 ) + - col1 * - CAST ( 82 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1315
2535
4760

onlyif mysql