hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - ( col1 ) + + col2 + + col0 * - col2 AS col0 FROM tab2 AS cor0
----
-193
-2061
-2981

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

query I rowsort
SELECT 62 AS col1 FROM tab1 cor0
----
62
62
62

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

query I rowsort
SELECT - tab2.col0 * + ( + col0 ) AS col1 FROM tab2
----
-49
-6084
-6241

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

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

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

query I rowsort
SELECT ALL + 28 AS col0 FROM tab0, tab1 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 423726553d33e100432ebde49ddd31b5

query I rowsort
SELECT 43 + col2 FROM tab1 AS cor0
----
100
139
97

query I rowsort
SELECT - + col0 + + 44 AS col1 FROM tab2 AS cor0
----
-34
-35
37

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

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

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

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

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

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

query I rowsort
SELECT + 59 + - col0 * col2 FROM tab1 AS cor0
----
-103
-3589
-7621

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

query I rowsort
SELECT + cor0.col1 + ( - 8 ) FROM tab2 AS cor0
----
23
51
9

query I rowsort
SELECT + - col1 * - ( + 51 * col1 ) AS col0 FROM tab1 AS cor0
----
34476
5100
8619

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

query I rowsort
SELECT col0 + - 87 * col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
106610
50136
689216

query I rowsort
SELECT ALL + - col1 * 22 FROM tab2 AS cor0
----
-1298
-374
-682

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

query I rowsort
SELECT DISTINCT col2 - + 95 AS col2 FROM tab2 AS cor0
----
-57
-68
-69

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

query I rowsort
SELECT col1 + 55 * col0 * - cor0.col2 FROM tab1 cor0
----
-200630
-422387
-8884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-28
SELECT col1 * - CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-28
SELECT col1 * - CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
7396
8281
9409

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

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

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

query I rowsort
SELECT ALL + - 56 AS col1 FROM tab2 AS cor0
----
-56
-56
-56

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

skipif mysql # not compatible
query I rowsort label-33
SELECT ALL - CAST ( - col1 AS INTEGER ) AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT - 53 * tab1.col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e0a39d35203463b8c42df1a3a6ebd578

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col0 - 63 * col1 col2 FROM tab0
----
-4842
-4886
2188

query I rowsort
SELECT 63 + + col2 * col0 FROM tab2 AS cor0
----
2091
252
3065

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

skipif mysql # not compatible
query I rowsort label-37
SELECT DISTINCT + - cor0.col1 * col2 + + CAST ( 12 AS INTEGER ) * col1 FROM tab1 AS cor0
----
-1092
-450

query I rowsort
SELECT ALL + cor0.col0 * 33 FROM tab0, tab1 AS cor0
----
9 values hashing to 7e0d2a47db33b3b5192fb8f9e5efb1a9

query I rowsort
SELECT DISTINCT 63 + col0 AS col1 FROM tab1 AS cor0
----
127
143
66

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

query I rowsort
SELECT + 83 * cor0.col1 + col1 FROM tab0 AS cor0
----
7224
7644
8148

onlyif mysql # use DIV operator for integer division
query I rowsort label-42
SELECT DISTINCT - col0 + + cor0.col0 DIV + ( col1 ) AS col1 FROM tab0 cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-42
SELECT DISTINCT - col0 + + cor0.col0 / + ( col1 ) AS col1 FROM tab0 cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col1 + + col2 ) * tab2.col1 col0 FROM tab2
----
-124
-1947
357

onlyif mysql # use DIV operator for integer division
query I rowsort label-44
SELECT 56 + col0 * col2 DIV - col0 FROM tab0 AS cor0
----
-26
23
55

skipif mysql # not compatible
query I rowsort label-44
SELECT 56 + col0 * col2 / - col0 FROM tab0 AS cor0
----
-26
23
55

query I rowsort
SELECT col2 * + col2 * - col2 FROM tab2 AS cor0
----
-17576
-19683
-54872

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

query I rowsort
SELECT col2 * col0 * - col0 AS col2 FROM tab0
----
-1225
-19008
-649522

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

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

query I rowsort
SELECT ALL + 42 + - 95 * + col2 AS col2 FROM tab0 AS cor0
----
-3093
-53
-7748

query I rowsort
SELECT ALL - - 36 + + cor0.col2 * - col0 AS col0 FROM tab1 AS cor0
----
-126
-3612
-7644

query I rowsort
SELECT DISTINCT - + cor0.col0 * 58 FROM tab1 AS cor0
----
-174
-3712
-4640

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

query I rowsort
SELECT - 61 + col1 FROM tab0 cor0
----
25
30
36

query I rowsort
SELECT ALL 26 + + col0 AS col2 FROM tab2 AS cor0
----
104
105
33

query I rowsort
SELECT ALL - ( 65 ) FROM tab0 AS cor0
----
-65
-65
-65

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

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

skipif mysql # not compatible
query I rowsort label-57
SELECT DISTINCT + + col1 + - col2 / col1 AS col0 FROM tab1 AS cor0
----
24
5
6

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

query I rowsort
SELECT ALL 70 * 37 + col0 FROM tab2 AS cor0
----
2597
2668
2669

query I rowsort
SELECT DISTINCT - - 9 + + col2 FROM tab2 AS cor0
----
35
36
47

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

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

query I rowsort
SELECT DISTINCT + + 12 * + cor0.col2 + - col2 FROM tab0 AS cor0
----
11
363
902

query I rowsort
SELECT ALL - + 85 - col1 * col1 FROM tab0 AS cor0
----
-7481
-8366
-9494

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

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

query I rowsort
SELECT ALL + col0 + - col2 * 67 * col2 FROM tab2 cor0
----
-45214
-48836
-96669

query I rowsort
SELECT - 46 AS col1 FROM tab1 AS cor0
----
-46
-46
-46

query I rowsort
SELECT - cor0.col0 + 90 FROM tab0 AS cor0
----
1
55
66

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

query I rowsort
SELECT ALL col1 * + 20 + tab0.col1 AS col1 FROM tab0
----
1806
1911
2037

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

query I rowsort
SELECT - col0 * + 90 * - 46 + - col1 AS col0 FROM tab1
----
12394
264950
331187

query I rowsort
SELECT DISTINCT - col0 + + ( + 53 ) AS col0 FROM tab1 AS cor0
----
-11
-27
50

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 30 col1 FROM tab1 AS cor0
----
-300
-390
-780

skipif mysql # not compatible
query I rowsort
SELECT + + col1 + CAST ( 97 AS REAL ) * - cor0.col0 - + col0 FROM tab0 AS cor0
----
-2266
-3333
-8631

query I rowsort
SELECT - 32 FROM tab1, tab2 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

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

query I rowsort
SELECT ALL - cor0.col0 + - col2 + col0 FROM tab1 AS cor0
----
-54
-57
-96

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

query I rowsort
SELECT - + 11 * - ( - col2 ) AS col1 FROM tab2 cor0
----
-286
-297
-418

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-87
SELECT ALL 7 DIV - 81 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-87
SELECT ALL 7 / - 81 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 58 * - col2 FROM tab2 AS cor0
----
-1508
-1566
-2204

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

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

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

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

query I rowsort
SELECT DISTINCT - col1 + 34 FROM tab2
----
-25
17
3

query I rowsort
SELECT + 87 * - col0 + col2 * - col1 * col0 AS col1 FROM tab0 cor0
----
-6440
-671861
-70200

query I rowsort
SELECT 85 + - col0 AS col0 FROM tab1 AS cor0
----
21
5
82

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 + col1 * col1 col2 FROM tab1 AS cor0
----
-3996
-6231
667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 * col2 ) + ( + col2 + col1 ) col1 FROM tab1
----
2996
3316
9325

query I rowsort
SELECT + 97 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT ALL + tab0.col1 * 2 AS col1 FROM tab0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-100
SELECT - 60 DIV col2 + + col1 * + 24 * - col2 AS col2 FROM tab1 AS cor0
----
-13681
-29952
-33697

skipif mysql # not compatible
query I rowsort label-100
SELECT - 60 / col2 + + col1 * + 24 * - col2 AS col2 FROM tab1 AS cor0
----
-13681
-29952
-33697

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

query I rowsort
SELECT - cor0.col2 * - cor0.col1 + 98 - - col2 FROM tab0 AS cor0
----
196
2969
7642

query I rowsort
SELECT ALL + + col2 + 9 * + cor0.col1 FROM tab2 AS cor0
----
191
306
557

query I rowsort
SELECT + col2 * ( 42 ) + col1 AS col1 FROM tab2 AS cor0
----
1151
1165
1613

query I rowsort
SELECT - col2 * + 50 * - col1 + + col0 FROM tab0 AS cor0
----
141924
373189
4885

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

query I rowsort
SELECT ALL col0 + tab0.col0 - tab0.col1 AS col1 FROM tab0
----
-27
-38
87

query I rowsort
SELECT ALL + - cor0.col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # use DIV operator for integer division
query I rowsort label-109
SELECT - col1 DIV ( col0 * col0 ) + + col2 * col2 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-109
SELECT - col1 / ( col0 * col0 ) + + col2 * col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL - + col0 + 34 * 36 FROM tab0 AS cor0
----
1135
1189
1200

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

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

query I rowsort
SELECT col1 + 61 - col0 FROM tab2 AS cor0
----
-1
42
85

query I rowsort
SELECT DISTINCT + col1 * col2 + col0 + col1 FROM tab1 AS cor0
----
1341
1433
644

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

query I rowsort
SELECT ALL cor0.col0 * - 69 AS col2 FROM tab2 cor0
----
-483
-5382
-5451

onlyif mysql # use DIV operator for integer division
query I rowsort label-117
SELECT + col1 DIV + 7 + cor0.col1 FROM tab0 AS cor0
----
104
110
98

skipif mysql # not compatible
query I rowsort label-117
SELECT + col1 / + 7 + cor0.col1 FROM tab0 AS cor0
----
104
110
98

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

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

query I rowsort
SELECT - ( - 79 ) AS col2 FROM tab1
----
79
79
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-121
SELECT DISTINCT ( + col0 ) DIV col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-121
SELECT DISTINCT ( + col0 ) / col2 FROM tab0
----
0
1
35

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-123
SELECT DISTINCT col0 DIV tab1.col2 col0 FROM tab1
----
0
1

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

query I rowsort
SELECT - cor0.col1 AS col1 FROM tab2, tab1 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-125
SELECT DISTINCT CAST( NULL AS DECIMAL ) * - 96 FROM tab2, tab2 AS cor0
----
NULL

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-128
SELECT DISTINCT col0 + 3 DIV + col0 - - col1 FROM tab1 AS cor0
----
30
74
93

skipif mysql # not compatible
query I rowsort label-128
SELECT DISTINCT col0 + 3 / + col0 - - col1 FROM tab1 AS cor0
----
30
74
93

query I rowsort
SELECT col0 + 64 AS col2 FROM tab2 AS cor0
----
142
143
71

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

query I rowsort
SELECT col0 * - 25 FROM tab0 AS cor0
----
-2225
-600
-875

query I rowsort
SELECT DISTINCT + + col2 + 59 + - col0 * col0 FROM tab1 AS cor0
----
-3980
-6245
104

query I rowsort
SELECT DISTINCT + col0 * - ( + col2 ) - col0 * - 12 FROM tab0 AS cor0
----
-504
-6230
385

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

query I rowsort
SELECT ALL ( + ( - col0 ) ) - + col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

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

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

query I rowsort
SELECT + col1 * - 50 FROM tab2 cor0
----
-1550
-2950
-850

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

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

query I rowsort
SELECT ALL - col0 * - 37 + col2 FROM tab2 cor0
----
286
2912
2961

query I rowsort
SELECT ALL 90 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 52 + 7 col0 FROM tab1
----
59
59
59

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-145
SELECT - 47 + col1 DIV col1 AS col1 FROM tab0 AS cor0
----
-46
-46
-46

skipif mysql # not compatible
query I rowsort label-145
SELECT - 47 + col1 / col1 AS col1 FROM tab0 AS cor0
----
-46
-46
-46

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

skipif mysql # not compatible
query I rowsort label-146
SELECT + CAST ( - col1 AS INTEGER ) * - col1 * ( - 99 + + cor0.col1 ) AS col2 FROM tab0 AS cor0
----
-18818
-66248
-96148

onlyif mysql # use DIV operator for integer division
query I rowsort label-147
SELECT - 29 + - col2 DIV + col0 AS col2 FROM tab1 AS cor0
----
-29
-30
-47

skipif mysql # not compatible
query I rowsort label-147
SELECT - 29 + - col2 / + col0 AS col2 FROM tab1 AS cor0
----
-29
-30
-47

query I rowsort
SELECT + col1 * + ( - col0 ) + - 49 FROM tab0 AS cor0
----
-2113
-3444
-8148

query I rowsort
SELECT - cor0.col2 * + 66 AS col2 FROM tab1 cor0
----
-3564
-3762
-6336

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

query I rowsort
SELECT - - ( + col1 ) * - col0 + - ( 37 ) FROM tab1 cor0
----
-1077
-115
-677

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

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

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

query I rowsort
SELECT + col1 * col0 * ( 32 ) FROM tab0 cor0
----
108640
259168
66048

query I rowsort
SELECT - + 31 + col0 FROM tab1 AS cor0
----
-28
33
49

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

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

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

query I rowsort
SELECT - col0 * col1 + 65 AS col1 FROM tab0 cor0
----
-1999
-3330
-8034

query I rowsort
SELECT ALL col1 + + col0 - tab1.col0 FROM tab1
----
10
13
26

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

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

query I rowsort
SELECT DISTINCT tab1.col0 * - 94 - 29 AS col0 FROM tab1
----
-311
-6045
-7549

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

query I rowsort
SELECT + col0 * col1 * 81 AS col1 FROM tab2 AS cor0
----
108783
17577
372762

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

skipif mysql # not compatible
query I rowsort label-165
SELECT ALL + col0 * col2 / ( col2 ) AS col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT 52 + 15 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-167
SELECT - tab1.col0 DIV col1 AS col2 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-167
SELECT - tab1.col0 / col1 AS col2 FROM tab1
----
-6
-6
0

query I rowsort
SELECT + - col0 * col0 + col1 * + col2 * col1 AS col1 FROM tab0 AS cor0
----
243492
671121
8184

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

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

query I rowsort
SELECT DISTINCT ( 82 ) FROM tab2 AS cor0
----
82

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-172
SELECT ALL - + CAST ( - col2 AS INTEGER ) * + cor0.col2 * col2 col1 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL + + ( + col0 ) + col2 * - ( + 17 * - cor0.col0 ) FROM tab1 AS cor0
----
130640
2757
62080

query I rowsort
SELECT - + 3 + ( col1 + 27 ) FROM tab0 AS cor0
----
110
115
121

query I rowsort
SELECT 5 * col0 + - col1 FROM tab1 AS cor0
----
-11
310
387

query I rowsort
SELECT DISTINCT tab0.col0 * - ( 18 ) * tab0.col0 FROM tab0
----
-10368
-142578
-22050

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

query I rowsort
SELECT col1 + 20 - 45 * + col0 FROM tab1
----
-2850
-3567
-89

query I rowsort
SELECT ALL ( + 32 ) * cor0.col0 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to a99aad3e0094b5be675580f56b55052d

onlyif mysql # use DIV operator for integer division
query I rowsort label-180
SELECT ALL col0 + col0 DIV 29 AS col0 FROM tab2
----
7
80
81

skipif mysql # not compatible
query I rowsort label-180
SELECT ALL col0 + col0 / 29 AS col0 FROM tab2
----
7
80
81

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

query I rowsort
SELECT ALL - + cor0.col1 * + 75 + col1 FROM tab2 AS cor0
----
-1258
-2294
-4366

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

query I rowsort
SELECT col0 * + 20 * + 11 AS col1 FROM tab2
----
1540
17160
17380

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

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

query I rowsort
SELECT DISTINCT + col1 * col2 + + col2 * col1 + - col2 FROM tab0 AS cor0
----
14842
193
5643

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

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

query I rowsort
SELECT DISTINCT + cor0.col1 + cor0.col0 * col1 + col2 * 53 * - cor0.col0 FROM tab2 cor0
----
-102823
-157746
-9769

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 * + col1 + col2 * - 31 AS col0 FROM tab0 AS cor0
----
-637079
-756113
-912704

query I rowsort
SELECT DISTINCT col1 * 63 + col2 AS col1 FROM tab0 AS cor0
----
5451
5815
6112

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-194
SELECT col0 + - 67 DIV cor0.col2 + col2 * - col2 AS col2 FROM tab1 cor0
----
-2914
-3186
-9136

skipif mysql # not compatible
query I rowsort label-194
SELECT col0 + - 67 / cor0.col2 + col2 * - col2 AS col2 FROM tab1 cor0
----
-2914
-3186
-9136

query I rowsort
SELECT - col1 + - 44 * col1 AS col2 FROM tab1
----
-1170
-450
-585

query I rowsort
SELECT ALL - col2 * col2 + col1 * - col0 - + 95 FROM tab2
----
-1041
-2882
-5373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 78 * - cor0.col0 col0 FROM tab2, tab2 cor0
----
-546
-6084
-6162

query I rowsort
SELECT DISTINCT 27 * col0 - - col2 * col1 FROM tab0
----
1042
3486
9865

query I rowsort
SELECT ALL + 94 + - col1 * - col1 FROM tab1 AS cor0
----
194
263
770

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

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

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

query I rowsort
SELECT - 10 * - col2 FROM tab2 AS cor0
----
260
270
380

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 67 + col0 + col1 col1 FROM tab2
----
105
163
204

query I rowsort
SELECT ( 69 ) + tab1.col1 FROM tab1
----
79
82
95

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

query I rowsort
SELECT - 53 * + 3 AS col0 FROM tab0
----
-159
-159
-159

query I rowsort
SELECT - 79 - + col2 * + col1 * col2 FROM tab0 AS cor0
----
-176
-611963
-93733

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 96 * + col2 + - col2 * + col2 + col1 col1 FROM tab2 AS cor0
----
-3113
-3290
-5075

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

query I rowsort
SELECT DISTINCT + + ( + col1 ) * + col1 - + col2 AS col0 FROM tab2 cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT + - 58 - + col0 AS col1 FROM tab1 cor0
----
-122
-138
-61

query I rowsort
SELECT 35 + - col0 FROM tab2 AS cor0
----
-43
-44
28

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

query I rowsort
SELECT ALL - + 21 - col1 AS col1 FROM tab2 AS cor0
----
-38
-52
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * - col1 + - ( - cor0.col0 ) col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT ALL + - col2 + - col0 * + 22 AS col2 FROM tab2 AS cor0
----
-1742
-1776
-181

query I rowsort
SELECT col1 + col1 * ( col1 ) * cor0.col2 AS col1 FROM tab2 AS cor0
----
10999
25978
90565

query I rowsort
SELECT ALL col2 + col2 * 29 * ( col1 ) + col1 AS col0 FROM tab1 AS cor0
----
16597
36301
40796

query I rowsort
SELECT - 61 - - cor0.col1 FROM tab1 AS cor0
----
-35
-48
-51

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

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

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

query I rowsort
SELECT col0 * + 25 FROM tab0
----
2225
600
875

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

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

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

query I rowsort
SELECT - 15 + col2 AS col1 FROM tab1 AS cor0
----
39
42
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col1 col2 FROM tab2 cor0
----
-289
-3481
-961

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

query I rowsort
SELECT ALL - 57 * - cor0.col0 + col1 * - col0 + + col2 * + col0 * + col1 AS col1 FROM tab1 AS cor0
----
103360
39488
4305

query I rowsort
SELECT ALL 66 + col2 * col1 AS col1 FROM tab1 AS cor0
----
1314
1470
636

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * cor0.col1 col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + 68 * + col1 + 54 AS col0 FROM tab0 AS cor0
----
5902
6242
6650

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 12 * cor0.col1 col1 FROM tab2 AS cor0
----
-204
-372
-708

onlyif mysql # use DIV operator for integer division
query I rowsort label-236
SELECT + col0 * col0 + ( - col0 ) DIV cor0.col0 + col1 FROM tab0 cor0
----
1321
661
8011

skipif mysql # not compatible
query I rowsort label-236
SELECT + col0 * col0 + ( - col0 ) / cor0.col0 + col1 FROM tab0 cor0
----
1321
661
8011

query I rowsort
SELECT ALL + - col2 * - col1 + + 71 + - cor0.col2 FROM tab0 cor0
----
167
2876
7451

onlyif mysql # use DIV operator for integer division
query I rowsort label-238
SELECT - col1 * col1 + 40 DIV + cor0.col2 + ( col2 + - col2 ) FROM tab1 AS cor0
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-238
SELECT - col1 * col1 + 40 / + cor0.col2 + ( col2 + - col2 ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - + col0 - col0 AS col1 FROM tab1 AS cor0
----
-128
-160
-6

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

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

skipif mysql # not compatible
query I rowsort label-241
SELECT + tab1.col0 / tab1.col0 AS col1 FROM tab1
----
1
1
1

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

query I rowsort
SELECT DISTINCT 29 * - cor0.col1 + col1 * col2 AS col0 FROM tab2 AS cor0
----
-177
-62
153

query I rowsort
SELECT DISTINCT - 28 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-280
-364
-728

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-248
SELECT + + 75 + + col1 * col1 DIV col0 FROM tab2 AS cor0
----
119
212
78

skipif mysql # not compatible
query I rowsort label-248
SELECT + + 75 + + col1 * col1 / col0 FROM tab2 AS cor0
----
119
212
78

query I rowsort
SELECT ALL - + cor0.col2 + - 30 FROM tab2 cor0
----
-56
-57
-68

query I rowsort
SELECT col2 + 93 FROM tab0 AS cor0
----
126
175
94

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-252
SELECT ALL + col1 DIV cor0.col2 + col1 FROM tab0 AS cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-252
SELECT ALL + col1 / cor0.col2 + col1 FROM tab0 AS cor0
----
194
88
92

query I rowsort
SELECT - 1 * 29 FROM tab2, tab2 cor0
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

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

query I rowsort
SELECT tab2.col0 + col1 + col1 * col1 FROM tab2
----
3618
385
999

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

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

query I rowsort
SELECT ALL 86 * col0 AS col1 FROM tab0
----
2064
3010
7654

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

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

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE ( NULL ) <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + tab1.col2 col2 FROM tab1
----
109
67
80

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

query I rowsort
SELECT ALL + col1 + - col2 + + col1 * col2 AS col0 FROM tab1
----
1165
1376
523

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

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

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

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

skipif mysql # not compatible
query I rowsort label-268
SELECT DISTINCT + cor0.col0 / - cor0.col1 AS col0 FROM tab0, tab1 AS cor0
----
-6
0

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

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

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

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

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

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

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

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

query I rowsort
SELECT 51 + + col2 - - cor0.col0 * cor0.col2 FROM tab0 AS cor0
----
7431
87
876

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-278
SELECT 75 * 77 DIV + col0 FROM tab0
----
165
240
64

skipif mysql # not compatible
query I rowsort label-278
SELECT 75 * 77 / + col0 FROM tab0
----
165
240
64

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

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

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

query I rowsort
SELECT DISTINCT ( 68 ) + + tab2.col2 FROM tab2
----
106
94
95

query I rowsort
SELECT DISTINCT + col0 + + 42 FROM tab2
----
120
121
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-283
SELECT col1 DIV 76 col0 FROM tab0
----
1
1
1

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

query I rowsort
SELECT cor0.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col1 - col0 col2 FROM tab1
----
576
75
960

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-288
SELECT ALL - col0 * col2 + + tab2.col1 DIV col1 AS col1 FROM tab2
----
-188
-2027
-3001

skipif mysql # not compatible
query I rowsort label-288
SELECT ALL - col0 * col2 + + tab2.col1 / col1 AS col1 FROM tab2
----
-188
-2027
-3001

query I rowsort
SELECT col1 * - tab2.col2 + col0 * col2 FROM tab2
----
-648
2356
494

query I rowsort
SELECT ALL + col1 * - col1 + - col2 + col2 * col0 AS col1 FROM tab0
----
-1065
-6637
-9375

onlyif mysql # use DIV operator for integer division
query I rowsort label-291
SELECT - col0 * - col1 DIV col1 AS col1 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-291
SELECT - col0 * - col1 / col1 AS col1 FROM tab2
----
7
78
79

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-293
SELECT DISTINCT - col2 DIV + col1 + - col0 * tab2.col1 + col2 col2 FROM tab2
----
-1307
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-293
SELECT DISTINCT - col2 / + col1 + - col0 * tab2.col1 + col2 col2 FROM tab2
----
-1307
-190
-4576

query I rowsort
SELECT + col1 + + col0 FROM tab0 WHERE NOT NULL <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-295
SELECT ALL tab0.col2 + col1 DIV + col1 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-295
SELECT ALL tab0.col2 + col1 / + col1 FROM tab0
----
2
34
83

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-298
SELECT col2 DIV + col0 + - col0 AS col1 FROM tab1
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-298
SELECT col2 / + col0 + - col0 AS col1 FROM tab1
----
-64
-79
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-299
SELECT + col0 DIV - col2 + tab1.col1 * col0 FROM tab1
----
1040
639
78

skipif mysql # not compatible
query I rowsort label-299
SELECT + col0 / - col2 + tab1.col1 * col0 FROM tab1
----
1040
639
78

query I rowsort
SELECT col2 * tab1.col0 - tab1.col0 FROM tab1
----
159
3584
7600

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-302
SELECT col2 / + col1 col0 FROM tab1
----
2
5
7

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

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

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

skipif mysql # not compatible
query I rowsort label-305
SELECT ALL - tab2.col2 + + col0 * col0 / + col0 AS col0 FROM tab2
----
-20
41
52

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

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

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

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

query I rowsort
SELECT DISTINCT col0 * col0 FROM tab2 WHERE NOT ( - col2 ) NOT BETWEEN col2 * col1 AND col2
----

query I rowsort
SELECT - col1 * - col0 * col0 - col2 * + col1 FROM tab2
----
105451
357422
682

query I rowsort
SELECT tab2.col0 FROM tab2 AS cor0 CROSS JOIN tab2
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

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

query I rowsort
SELECT - col2 * + col1 + + cor0.col2 * cor0.col2 FROM tab0 AS cor0
----
-1749
-738
-96

query I rowsort
SELECT ALL + cor0.col2 + + cor0.col1 FROM tab0 AS cor0 WHERE ( cor0.col1 ) IN ( + col1 * - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + - cor0.col0 col2 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 + - col1 col0 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT tab0.col0 + - col2 + col2 * + col1 FROM tab0
----
131
2829
7469

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

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

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

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

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

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

query I rowsort
SELECT + ( + cor0.col2 ) + - col2 * 11 FROM tab1 AS cor0
----
-540
-570
-960

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * 59 col2 FROM tab2 AS cor0
----
1003
1829
3481

onlyif mysql # use DIV operator for integer division
query I rowsort label-327
SELECT ALL col1 * col1 DIV - col2 AS col0 FROM tab1 AS cor0
----
-1
-1
-12

skipif mysql # not compatible
query I rowsort label-327
SELECT ALL col1 * col1 / - col2 AS col0 FROM tab1 AS cor0
----
-1
-1
-12

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 31 * + col0 col2 FROM tab1 AS cor0
----
1984
2480
93

query I rowsort
SELECT DISTINCT 10 FROM tab2 AS cor0
----
10

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

query I rowsort
SELECT ALL 45 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
104
62
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-334
SELECT + - ( 3 ) * col2 + + 86 DIV col2 col0 FROM tab1 AS cor0
----
-161
-170
-288

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-334
SELECT + - ( 3 ) * col2 + + 86 / col2 col0 FROM tab1 AS cor0
----
-161
-170
-288

query I rowsort
SELECT DISTINCT - col2 * + 85 AS col0 FROM tab0 AS cor0
----
-2805
-6970
-85

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 51 * - col0 - - col1 col0 FROM tab2 AS cor0
----
-326
-3919
-4012

query I rowsort
SELECT ALL + 13 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT ALL + col2 * ( + col2 ) + col1 - + 31 AS col1 FROM tab1
----
2911
3228
9198

onlyif mysql # use DIV operator for integer division
query I rowsort label-342
SELECT ALL col1 DIV col2 - + tab1.col2 DIV + col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-342
SELECT ALL col1 / col2 - + tab1.col2 / + col0 FROM tab1
----
-1
-18
0

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

query I rowsort
SELECT DISTINCT + - 41 + + col0 AS col0 FROM tab1 AS cor0
----
-38
23
39

query I rowsort
SELECT ( - col0 ) - col0 AS col1 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT 44 * + col2 + cor0.col2 + 39 * - col1 * col0 FROM tab1 cor0
----
-22395
-36240
-612

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

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

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

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

query I rowsort
SELECT - + 77 + col0 FROM tab2 AS cor0
----
-70
1
2

query I rowsort
SELECT ALL - 84 + - 54 AS col2 FROM tab2
----
-138
-138
-138

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

skipif mysql # not compatible
query I rowsort label-352
SELECT ALL + CAST ( NULL AS INTEGER ) + - 21 FROM tab2
----
NULL
NULL
NULL

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

query I rowsort
SELECT + 83 AS col1 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col0 * + 74 col2 FROM tab1 AS cor0
----
168
4679
5824

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

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-362
SELECT col1 DIV ( + col0 ) + tab1.col0 + col2 * tab1.col2 * col2 FROM tab1
----
157475
185257
884816

skipif mysql # not compatible
query I rowsort label-362
SELECT col1 / ( + col0 ) + tab1.col0 + col2 * tab1.col2 * col2 FROM tab1
----
157475
185257
884816

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

skipif mysql # not compatible
query I rowsort label-363
SELECT ALL col1 / tab1.col2 + - col0 - - col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT ALL - col1 * col1 - - col1 AS col2 FROM tab2
----
-272
-3422
-930

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

query I rowsort
SELECT - col0 * + 61 * + col2 FROM tab1 AS cor0
----
-222528
-468480
-9882

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

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

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

skipif mysql # not compatible
query I rowsort label-369
SELECT ALL col0 * CAST ( col0 * col0 + - cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
13032
42840
697671

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 13 ) col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

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

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

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

query I rowsort
SELECT + 45 * ( - col1 ) FROM tab1 AS cor0
----
-1170
-450
-585

query I rowsort
SELECT col0 + col0 * + col2 * col0 FROM tab0 AS cor0
----
1260
19032
649611

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + cor0.col1 * + ( + 6 ) col0 FROM tab2 AS cor0
----
159
328
64

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-382
SELECT ( + col2 ) * CAST( 17 * col2 AS SIGNED ) + col2 AS col2 FROM tab1 AS cor0
----
156768
49626
55290

skipif mysql # not compatible
query I rowsort label-382
SELECT ( + col2 ) * CAST ( 17 * col2 AS INTEGER ) + col2 AS col2 FROM tab1 AS cor0
----
156768
49626
55290

query I rowsort
SELECT DISTINCT - - 39 * col2 FROM tab0 AS cor0
----
1287
3198
39

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

query I rowsort
SELECT DISTINCT - cor0.col0 * + col0 + col1 + + col2 FROM tab1 AS cor0
----
-4029
-6291
71

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

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

query I rowsort
SELECT 82 * + col0 + + ( + tab0.col2 ) AS col1 FROM tab0
----
2001
2871
7380

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-392
SELECT - + col0 * cor0.col2 * 17 + + col1 DIV col2 FROM tab0 AS cor0
----
-124065
-13462
-498

skipif mysql # not compatible
query I rowsort label-392
SELECT - + col0 * cor0.col2 * 17 + + col1 / col2 FROM tab0 AS cor0
----
-124065
-13462
-498

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-396
SELECT + + col1 * CAST ( - col2 AS INTEGER ) col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - col1 + ( col1 + + col2 ) * col2 FROM tab2 AS cor0
----
1535
2073
2151

query I rowsort
SELECT ALL - col2 * - col2 + + ( col1 ) * ( - 39 + col0 ) * ( + 97 * cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-4899852
1385499
4972512

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-401
SELECT 81 * - col0 - + col2 * col1 DIV - 68 AS col0 FROM tab2 AS cor0
----
-555
-6296
-6390

skipif mysql # not compatible
query I rowsort label-401
SELECT 81 * - col0 - + col2 * col1 / - 68 AS col0 FROM tab2 AS cor0
----
-555
-6296
-6390

query I rowsort
SELECT + + 49 + + cor0.col1 + - col1 AS col1 FROM tab0 cor0
----
49
49
49

query I rowsort
SELECT + ( - 35 ) * - col2 AS col1 FROM tab1 AS cor0
----
1890
1995
3360

query I rowsort
SELECT - - 87 * col1 FROM tab2 AS cor0
----
1479
2697
5133

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

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

query I rowsort
SELECT - cor0.col1 + cor0.col0 FROM tab0 cor0
----
-2
-62
-62

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

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

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

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

skipif mysql # not compatible
query I rowsort label-410
SELECT - - col2 - + col0 * CAST ( + col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 cor0 CROSS JOIN tab0 AS cor1
----
243 values hashing to 3581f59ff9574f9d6290fc6bca0b5e4d

query I rowsort
SELECT + + 68 * col0 AS col2 FROM tab1 AS cor0
----
204
4352
5440

query I rowsort
SELECT ( col1 ) * col1 + + col2 + col0 AS col0 FROM tab1 AS cor0
----
221
345
733

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

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

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

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

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

query I rowsort
SELECT + - 6 * col0 * col1 - - 15 AS col2 FROM tab0 cor0
----
-12369
-20355
-48579

onlyif mysql # use DIV operator for integer division
query I rowsort label-418
SELECT + + col1 + col1 + - cor0.col0 DIV + 53 FROM tab1 AS cor0
----
19
25
52

skipif mysql # not compatible
query I rowsort label-418
SELECT + + col1 + col1 + - cor0.col0 / + 53 FROM tab1 AS cor0
----
19
25
52

query I rowsort
SELECT DISTINCT - - col2 + + col2 * + 40 * col1 AS col0 FROM tab0 AS cor0
----
113553
298562
3881

query I rowsort
SELECT col2 + - col2 * + col2 + ( cor0.col2 ) FROM tab0 AS cor0
----
-1023
-6560
1

query I rowsort
SELECT ALL + 15 * + col0 AS col0 FROM tab1 AS cor0
----
1200
45
960

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

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

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

query I rowsort
SELECT DISTINCT - col2 + - col1 * 62 FROM tab1 AS cor0
----
-1666
-677
-902

query I rowsort
SELECT - col0 + + 30 AS col1 FROM tab1 AS cor0
----
-34
-50
27

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

query I rowsort
SELECT DISTINCT ( tab0.col2 ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
1
33
82

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT - cor1.col2 + - CAST ( + 8 AS REAL ) AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 72326482febee3297bfe1fe359959234

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-434
SELECT 66 + col2 * tab1.col1 DIV + col0 AS col0 FROM tab1
----
534
74
81

skipif mysql # not compatible
query I rowsort label-434
SELECT 66 + col2 * tab1.col1 / + col0 AS col0 FROM tab1
----
534
74
81

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

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

query I rowsort
SELECT DISTINCT - ( + 39 ) * col0 + col0 AS col0 FROM tab0 AS cor0
----
-1330
-3382
-912

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

query I rowsort
SELECT ALL ( 80 ) * + cor0.col0 + - col2 FROM tab0 AS cor0
----
1887
2799
7038

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

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

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

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

query I rowsort
SELECT ALL col2 + 88 FROM tab1
----
142
145
184

query I rowsort
SELECT ALL - + col2 * 71 AS col2 FROM tab2 cor0
----
-1846
-1917
-2698

query I rowsort
SELECT DISTINCT cor0.col2 * 88 + + col1 * - col2 FROM tab2 AS cor0
----
1539
2698
754

query I rowsort
SELECT ALL col1 * cor0.col1 - - 40 * col0 * + col0 FROM tab0 AS cor0
----
30436
325121
58409

onlyif mysql # use DIV operator for integer division
query I rowsort label-448
SELECT ALL col0 * col0 + col2 - col1 DIV - ( 55 + + col2 ) FROM tab1 cor0
----
4153
63
6496

skipif mysql # not compatible
query I rowsort label-448
SELECT ALL col0 * col0 + col2 - col1 / - ( 55 + + col2 ) FROM tab1 cor0
----
4153
63
6496

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-451
SELECT + + col2 + + CAST ( NULL AS REAL ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-454
SELECT ALL + 76 DIV col0 + + col2 + - 12 * ( col1 ) AS col0 FROM tab2 AS cor0
----
-166
-335
-682

skipif mysql # not compatible
query I rowsort label-454
SELECT ALL + 76 / col0 + + col2 + - 12 * ( col1 ) AS col0 FROM tab2 AS cor0
----
-166
-335
-682

query I rowsort
SELECT ALL - + cor0.col1 + 21 AS col2 FROM tab1 AS cor0
----
-5
11
8

query I rowsort
SELECT - - col0 * ( col2 ) + + 3 * + 66 FROM tab1 AS cor0
----
360
3846
7878

query I rowsort
SELECT + - col2 + 76 * - col1 FROM tab0 AS cor0
----
-6569
-6998
-7373

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

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

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

query I rowsort
SELECT ALL + ( + col2 ) + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - 26 + - col0 FROM tab0 AS cor0
----
-115
-50
-61

query I rowsort
SELECT + 63 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query III rowsort
SELECT ALL * FROM tab1 WHERE + col2 * + col2 + col1 BETWEEN col0 AND + col0
----

query I rowsort
SELECT col0 + + tab0.col0 + + col0 AS col2 FROM tab0
----
105
267
72

query I rowsort
SELECT ALL + col1 AS col2 FROM tab0 WHERE NULL BETWEEN ( NULL ) AND NULL
----

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

skipif mysql # not compatible
query I rowsort label-473
SELECT ALL + col0 * col2 + CAST ( + col2 AS INTEGER ) * cor0.col1 FROM tab2 AS cor0
----
1026
3562
3648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 80 col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

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

query I rowsort
SELECT DISTINCT + 69 AS col0 FROM tab0, tab0 AS cor0, tab2 cor1
----
69

query I rowsort
SELECT + col2 * ( - 95 ) AS col1 FROM tab0 AS cor0
----
-3135
-7790
-95

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-479
SELECT DISTINCT col2 / + col0 col0 FROM tab2
----
0
3

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

query I rowsort
SELECT - + col1 * - 66 * col2 AS col2 FROM tab0 AS cor0
----
187308
492492
6402

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-486
SELECT DISTINCT - col0 / - col2 AS col0 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT col2 * + 9 AS col2 FROM tab2
----
234
243
342

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

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

query I rowsort
SELECT DISTINCT - - 90 * + col2 FROM tab2 AS cor0
----
2340
2430
3420

query I rowsort
SELECT ALL 8 + col0 FROM tab0 AS cor0
----
32
43
97

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-493
SELECT DISTINCT + col1 DIV col0 + col2 AS col0 FROM tab1
----
57
62
96

skipif mysql # not compatible
query I rowsort label-493
SELECT DISTINCT + col1 / col0 + col2 AS col0 FROM tab1
----
57
62
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-494
SELECT ALL 36 DIV + tab0.col1 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-494
SELECT ALL 36 / + tab0.col1 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-495
SELECT + col1 DIV + cor0.col2 + + 21 AS col1 FROM tab0 AS cor0
----
118
22
23

skipif mysql # not compatible
query I rowsort label-495
SELECT + col1 / + cor0.col2 + + 21 AS col1 FROM tab0 AS cor0
----
118
22
23

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

query I rowsort
SELECT + + 44 + col1 FROM tab2 cor0
----
103
61
75

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

query I rowsort
SELECT + + col2 + col1 * - ( + 92 ) AS col0 FROM tab1 AS cor0
----
-1100
-2338
-863

query I rowsort
SELECT DISTINCT + 93 + col1 FROM tab0 AS cor0
----
179
184
190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + cor0.col1 + col1 * + ( col1 ) * - 74 col2 FROM tab2 AS cor0
----
-21331
-257509
-71056

query I rowsort
SELECT - 26 * + cor0.col1 + col1 + 32 * col0 AS col0 FROM tab0 AS cor0
----
-1305
-1382
573

query I rowsort
SELECT ALL 97 FROM tab0 cor0
----
97
97
97

query I rowsort
SELECT DISTINCT - col2 * + col1 * + 12 + 43 * - col0 AS col2 FROM tab0 AS cor0
----
-2669
-35088
-93371

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

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

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

query I rowsort
SELECT 29 * - col0 + col2 AS col0 FROM tab0 AS cor0
----
-1014
-2499
-663

onlyif mysql # use DIV operator for integer division
query I rowsort label-508
SELECT 90 DIV + col0 + + col2 + + col0 FROM tab1 cor0
----
122
177
87

skipif mysql # not compatible
query I rowsort label-508
SELECT 90 / + col0 + + col2 + + col0 FROM tab1 cor0
----
122
177
87

query I rowsort
SELECT DISTINCT - 81 * - col0 FROM tab2 AS cor0
----
567
6318
6399

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

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

query I rowsort
SELECT DISTINCT + - col1 + 82 AS col2 FROM tab1 AS cor0
----
56
69
72

query I rowsort
SELECT DISTINCT - col1 * 86 FROM tab2 AS cor0
----
-1462
-2666
-5074

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

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

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

query I rowsort
SELECT - 92 + + col2 + + col0 * 77 AS col1 FROM tab1 AS cor0
----
193
4893
6164

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-519
SELECT tab1.col1 * CAST( 21 AS SIGNED ) DIV + tab1.col0 FROM tab1
----
182
3
3

skipif mysql # not compatible
query I rowsort label-519
SELECT tab1.col1 * CAST ( 21 AS INTEGER ) / + tab1.col0 FROM tab1
----
182
3
3

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

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

query I rowsort
SELECT ALL 12 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT DISTINCT 95 * + col2 + - col2 * 82 * 17 + col2 * - 20 AS col2 FROM tab0
----
-108158
-1319
-43527

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-524
SELECT DISTINCT CAST( + col2 AS SIGNED ) + - tab0.col1 * - 6 FROM tab0
----
549
583
628

skipif mysql # not compatible
query I rowsort label-524
SELECT DISTINCT CAST ( + col2 AS INTEGER ) + - tab0.col1 * - 6 FROM tab0
----
549
583
628

query I rowsort
SELECT + + cor0.col1 + 43 FROM tab2 AS cor0
----
102
60
74

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 76 col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
-76

query I rowsort
SELECT 55 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT + 13 * + col1 FROM tab0 AS cor0
----
1118
1183
1261

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

query I rowsort
SELECT - - 17 + + col2 * cor0.col2 FROM tab0 AS cor0
----
1106
18
6741

query I rowsort
SELECT 55 * col1 - - 94 FROM tab0
----
4824
5099
5429

query I rowsort
SELECT - col1 + 21 FROM tab1 AS cor0
----
-5
11
8

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

skipif mysql # not compatible
query I rowsort label-534
SELECT col0 + + CAST ( col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT 46 * + 55 * tab1.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to ac3f216bddebf81332b4fcd0ffa0dc30

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

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

skipif mysql # not compatible
query I rowsort label-537
SELECT DISTINCT + col1 * - CAST ( - col2 AS INTEGER ) + - col1 FROM tab1 cor0
----
1235
1378
560

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

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

query I rowsort
SELECT ALL - cor0.col1 * col0 * col0 + + col2 FROM tab1 cor0
----
-180
-40903
-83104

query I rowsort
SELECT col1 + + cor0.col2 * + col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT DISTINCT - col2 - + col2 * 12 AS col2 FROM tab2 AS cor0
----
-338
-351
-494

query I rowsort
SELECT + col0 * + 58 FROM tab1 AS cor0
----
174
3712
4640

query I rowsort
SELECT ALL + - 40 * - 30 FROM tab0 AS cor0
----
1200
1200
1200

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

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

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

query I rowsort
SELECT DISTINCT 6 * cor0.col0 + cor0.col2 AS col1 FROM tab2 AS cor0
----
494
512
69

query I rowsort
SELECT ALL - - 50 - - col0 FROM tab0 cor0
----
139
74
85

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( + 97 AS REAL ) + + col2 AS col2 FROM tab0 AS cor0
----
130
179
98

query I rowsort
SELECT ALL - + 3 * col1 AS col2 FROM tab2 AS cor0
----
-177
-51
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col2 * + ( cor0.col2 ) + + col1 * - ( col1 ) * cor0.col0 col1 FROM tab0 AS cor0
----
-176415
-329314
-730285

query I rowsort
SELECT ALL 74 * cor0.col0 + col2 FROM tab2 AS cor0
----
545
5798
5884

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

query I rowsort
SELECT + col1 * 22 + + col1 * col1 FROM tab0
----
10283
11543
9288

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

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

query I rowsort
SELECT ALL - 20 + + col2 + col2 AS col1 FROM tab1 AS cor0
----
172
88
94

query I rowsort
SELECT ALL - cor0.col2 * + col1 * col0 - 61 AS col0 FROM tab0 AS cor0
----
-3456
-664179
-68173

query I rowsort
SELECT ALL - ( 70 ) + col2 AS col0 FROM tab0 AS cor0
----
-37
-69
12

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

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

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

query I rowsort
SELECT + + 52 * + col1 * + col2 + col0 FROM tab0 AS cor0
----
147600
388113
5079

query I rowsort
SELECT ALL + + 42 - col1 FROM tab1 cor0
----
16
29
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 36 * ( - col2 ) * - col1 col1 FROM tab2
----
-23256
-30132
-55224

query I rowsort
SELECT DISTINCT 71 * col2 FROM tab1
----
3834
4047
6816

query I rowsort
SELECT + 66 * col0 * - 84 AS col1 FROM tab2 AS cor0
----
-38808
-432432
-437976

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

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

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

skipif mysql # not compatible
query I rowsort label-568
SELECT DISTINCT + ( + col1 ) * - col0 + - col2 / cor0.col0 + cor0.col0 * col1 AS col0 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT ALL col0 * col1 + - 60 FROM tab1 AS cor0
----
18
580
980

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

skipif mysql # not compatible
query I rowsort label-570
SELECT col2 * cor0.col1 + CAST ( + col2 AS INTEGER ) + cor0.col0 FROM tab2 AS cor0
----
1638
763
871

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

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

query I rowsort
SELECT ALL - col0 + ( - 91 ) * + col0 FROM tab0 AS cor0
----
-2208
-3220
-8188

query I rowsort
SELECT + cor0.col2 + + col0 * col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT 85 + col1 FROM tab2
----
102
116
144

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 29794915b585eea848ad670075452c88

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-582
SELECT ALL + 13 DIV col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-582
SELECT ALL + 13 / col2 FROM tab1
----
0
0
0

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-584
SELECT DISTINCT - 99 * - col2 + CAST( - col0 AS SIGNED ) * col2 col0 FROM tab0 cor0
----
2475
64
820

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-584
SELECT DISTINCT - 99 * - col2 + CAST ( - col0 AS INTEGER ) * col2 col0 FROM tab0 cor0
----
2475
64
820

query I rowsort
SELECT ALL - cor0.col2 + - col0 * - 0 AS col2 FROM tab1 AS cor0
----
-54
-57
-96

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

query I rowsort
SELECT DISTINCT + ( + col0 ) + ( - 3 ) AS col1 FROM tab1 AS cor0
----
0
61
77

query I rowsort
SELECT ALL + 94 + col1 AS col2 FROM tab2 cor0
----
111
125
153

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 95 + - col0 col2 FROM tab0 cor0
----
-119
-130
-184

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

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

query I rowsort
SELECT ALL - col1 + - col0 * col2 * col2 FROM tab1
----
-207946
-737293
-8774

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

query I rowsort
SELECT + + col0 * 0 + + 19 * col2 FROM tab2 cor0
----
494
513
722

query I rowsort
SELECT DISTINCT col2 + - col0 * 69 + - col2 FROM tab0 cor0
----
-1656
-2415
-6141

query I rowsort
SELECT + col1 * - col0 + + 4 FROM tab1 AS cor0
----
-1036
-636
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-598
SELECT DISTINCT col1 DIV - cor0.col0 + cor0.col1 * + col1 AS col1 FROM tab1 AS cor0
----
100
169
668

skipif mysql # not compatible
query I rowsort label-598
SELECT DISTINCT col1 / - cor0.col0 + cor0.col1 * + col1 AS col1 FROM tab1 AS cor0
----
100
169
668

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

skipif mysql # not compatible
query I rowsort
SELECT ALL - col2 + CAST ( 34 AS REAL ) FROM tab0 cor0
----
-48
1
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * ( 49 ) * - col0 + col0 * - col1 col2 FROM tab0 AS cor0
----
-365701
-40872
-5110

query I rowsort
SELECT ALL + col0 - + col1 FROM tab0 cor0
----
-2
-62
-62

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + col1 * col2 col2 FROM tab1 AS cor0
----
1328
1407
634

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

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

query I rowsort
SELECT ALL - col0 * - cor0.col2 + col2 + + ( + col2 ) AS col2 FROM tab0 cor0
----
37
7462
858

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

query I rowsort
SELECT - 47 + + col2 FROM tab2 AS cor0
----
-20
-21
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + + 97 col1 FROM tab1 AS cor0
----
100
161
177

query I rowsort
SELECT DISTINCT - 3 + col0 - col0 FROM tab0 AS cor0
----
-3

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

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

query I rowsort
SELECT ALL - 48 + + col0 * - col1 FROM tab1 cor0
----
-1088
-126
-688

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 + cor0.col0 col0 FROM tab2, tab2 AS cor0
----
137
38
96

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

query I rowsort
SELECT col2 * 7 AS col2 FROM tab1 AS cor0
----
378
399
672

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

query I rowsort
SELECT cor0.col0 * cor0.col1 * col0 + - ( ( col0 ) ) FROM tab2 AS cor0
----
106018
1512
358878

query I rowsort
SELECT col0 * - 2 + col2 * ( - 15 ) FROM tab0 AS cor0
----
-1408
-543
-85

query I rowsort
SELECT + 86 * + col1 + col2 AS col2 FROM tab2 cor0
----
1500
2693
5100

query I rowsort
SELECT - 84 + 10 FROM tab2 AS cor0
----
-74
-74
-74

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

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

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

query I rowsort
SELECT ( 74 ) AS col1 FROM tab0
----
74
74
74

query I rowsort
SELECT DISTINCT + 64 AS col2 FROM tab1
----
64

query I rowsort
SELECT ALL + 65 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

onlyif mysql # use DIV operator for integer division
query I rowsort label-629
SELECT - cor0.col1 DIV + ( + 97 ) + col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-629
SELECT - cor0.col1 / + ( + 97 ) + col1 FROM tab1 AS cor0
----
10
13
26

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

query I rowsort
SELECT + col1 + + col0 * 8 AS col2 FROM tab2 cor0
----
649
683
87

query I rowsort
SELECT - col0 + - col0 * - col0 * col1 FROM tab1 AS cor0
----
231
40896
83120

query I rowsort
SELECT + col1 * cor0.col1 + + col1 + col0 FROM tab0 AS cor0
----
7506
8461
9541

query I rowsort
SELECT col1 * col2 * - tab2.col0 + tab2.col2 * - ( - ( col0 ) ) FROM tab2
----
-117624
-48032
-5670

onlyif mysql # use DIV operator for integer division
query I rowsort label-635
SELECT - tab2.col0 DIV - 60 AS col2 FROM tab2
----
0
1
1

skipif mysql # not compatible
query I rowsort label-635
SELECT - tab2.col0 / - 60 AS col2 FROM tab2
----
0
1
1

query I rowsort
SELECT col0 * - tab2.col2 + 80 + - col1 * + col0 FROM tab2
----
-326
-4265
-6550

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

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

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

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

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

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

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

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

query I rowsort
SELECT 88 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT - + 48 * col0 FROM tab1 AS cor0
----
-144
-3072
-3840

query I rowsort
SELECT ALL + col0 * + cor0.col2 * - 6 AS col1 FROM tab0 cor0
----
-210
-43788
-4752

query I rowsort
SELECT 82 * col0 FROM tab2
----
574
6396
6478

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

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

query I rowsort
SELECT DISTINCT + col2 + - 31 * 93 FROM tab0 AS cor0
----
-2801
-2850
-2882

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + cor0.col1 * + col2 col0 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT + 88 FROM tab1, tab2, tab1 cor0
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT - + col0 * - 81 FROM tab0 AS cor0
----
1944
2835
7209

query I rowsort
SELECT + col1 * - 17 * col0 FROM tab0 AS cor0
----
-137683
-35088
-57715

query I rowsort
SELECT ALL + ( col0 ) + + cor0.col1 * cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
221
345
733

query I rowsort
SELECT 25 * col2 + col0 FROM tab1 AS cor0
----
1353
1489
2480

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

skipif mysql # not compatible
query I rowsort label-655
SELECT ALL + CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-656
SELECT ALL + col2 DIV + 99 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-656
SELECT ALL + col2 / + 99 AS col2 FROM tab0
----
0
0
0

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

query I rowsort
SELECT ALL - col1 * - 2 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL col2 * - 8 FROM tab1
----
-432
-456
-768

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

query I rowsort
SELECT + + col1 * 2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - col1 + - col1 + - col1 * col2 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-119834
-32510
-75868

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 51 + 96 * - col0 * ( + col0 ) col1 FROM tab0
----
-117651
-55347
-760467

onlyif mysql # use DIV operator for integer division
query I rowsort label-667
SELECT ALL 27 + - col0 * col2 DIV - ( + col2 ) FROM tab0
----
116
51
62

skipif mysql # not compatible
query I rowsort label-667
SELECT ALL 27 + - col0 * col2 / - ( + col2 ) FROM tab0
----
116
51
62

query I rowsort
SELECT col1 * - 52 * - tab0.col0 + col1 AS col1 FROM tab0
----
107414
176637
421239

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

query I rowsort
SELECT ALL - col1 + + 4 AS col0 FROM tab2
----
-13
-27
-55

query I rowsort
SELECT DISTINCT 50 + - 37 FROM tab1
----
13

query I rowsort
SELECT ALL ( col1 ) * col1 * - col2 + + col1 * col0 FROM tab2
----
-25730
-85904
-9639

onlyif mysql # use DIV operator for integer division
query I rowsort label-673
SELECT ALL 68 + ( - col2 ) DIV 74 AS col0 FROM tab2
----
68
68
68

skipif mysql # not compatible
query I rowsort label-673
SELECT ALL 68 + ( - col2 ) / 74 AS col0 FROM tab2
----
68
68
68

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

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

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

query I rowsort
SELECT DISTINCT 33 * - cor0.col0 + + 27 AS col2 FROM tab1 AS cor0
----
-2085
-2613
-72

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

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

query I rowsort
SELECT ALL 12 + + col2 * + ( 45 * + col1 + col2 ) FROM tab2 AS cor0
----
30526
38406
69718

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

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

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

query I rowsort
SELECT DISTINCT 98 * + col2 + - col2 * 91 FROM tab0 AS cor0
----
231
574
7

query I rowsort
SELECT - 98 * col1 FROM tab1 AS cor0
----
-1274
-2548
-980

query I rowsort
SELECT ALL 26 * + col1 + + 88 FROM tab2 AS cor0
----
1622
530
894

query I rowsort
SELECT DISTINCT + 82 * col0 - + 63 FROM tab0 AS cor0
----
1905
2807
7235

query I rowsort
SELECT + cor0.col0 - 17 AS col2 FROM tab2 AS cor0
----
-10
61
62

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

query I rowsort
SELECT ALL tab2.col0 + - col1 * col2 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT col1 * + col2 + col2 * col0 * ( col1 ) FROM tab1 AS cor0
----
101088
37050
5616

query I rowsort
SELECT DISTINCT + col0 - + col1 * 52 AS col1 FROM tab0 AS cor0
----
-4448
-4643
-5009

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-692
SELECT ALL col1 DIV - col0 - - col2 * - col0 FROM tab2 AS cor0
----
-193
-2028
-3002

skipif mysql # not compatible
query I rowsort label-692
SELECT ALL col1 / - col0 - - col2 * - col0 FROM tab2 AS cor0
----
-193
-2028
-3002

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

query I rowsort
SELECT ALL - cor0.col0 + 19 * col1 FROM tab2 AS cor0
----
1043
244
582

query I rowsort
SELECT + col2 + col0 + - col1 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT col2 - - col1 * - 73 AS col0 FROM tab2 AS cor0
----
-1203
-2236
-4281

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

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

query I rowsort
SELECT DISTINCT 9 - col2 AS col2 FROM tab2 AS cor0
----
-17
-18
-29

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

query I rowsort
SELECT DISTINCT - - ( - 52 ) + + cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
-50
112
14

query I rowsort
SELECT ALL + col1 * - cor0.col1 * - col1 + cor0.col2 FROM tab2 AS cor0
----
205405
29818
4951

query I rowsort
SELECT ALL - - 86 - ( cor0.col2 ) FROM tab2 AS cor0
----
48
59
60

query I rowsort
SELECT DISTINCT + col2 - ( - 72 * tab2.col0 ) FROM tab2
----
531
5642
5726

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-708
SELECT col1 / 77 AS col0 FROM tab0 AS cor0
----
1
1
1

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

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

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

query I rowsort
SELECT col1 + + ( + col2 + cor0.col0 ) * col0 AS col1 FROM tab0 AS cor0
----
1357
1454
15310

query I rowsort
SELECT ALL - - col1 * 47 FROM tab0 AS cor0
----
4042
4277
4559

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-714
SELECT - col1 DIV col0 + col1 AS col1 FROM tab1
----
10
13
18

skipif mysql # not compatible
query I rowsort label-714
SELECT - col1 / col0 + col1 AS col1 FROM tab1
----
10
13
18

query I rowsort
SELECT + ( col0 ) + 10 FROM tab1
----
13
74
90

query I rowsort
SELECT DISTINCT - 15 + + col1 * col2 FROM tab2
----
1519
631
822

query I rowsort
SELECT + col2 * ( - col2 ) + + col2 AS col2 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT + 51 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

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

query I rowsort
SELECT + + col1 * - ( col2 + col0 ) * - col0 AS col2 FROM tab2 cor0
----
157131
478608
7378

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

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

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

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

query I rowsort
SELECT col0 * col2 + col0 + ( + 50 ) FROM tab0
----
120
7437
866

query I rowsort
SELECT ALL ( ( - col2 ) * col0 ) + + 57 FROM tab2
----
-132
-1971
-2945

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col1 ) col2 FROM tab1, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + cor0.col1 * + cor0.col1 col0 FROM tab0 AS cor0
----
7363
8199
9408

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

skipif mysql # not compatible
query I rowsort label-728
SELECT ALL CAST ( NULL AS INTEGER ) * 22 + tab2.col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + - col0 * col0 + + 96 * tab1.col1 * col1 AS col0 FROM tab1
----
5568
64890
9904

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

query I rowsort
SELECT DISTINCT 36 FROM tab2 AS cor0
----
36

query I rowsort
SELECT col1 * - col1 + cor0.col2 * + 94 AS col1 FROM tab0 AS cor0
----
-4294
-573
-9315

query I rowsort
SELECT ALL col0 * col2 + - col1 + - col2 * col2 * ( tab1.col2 * col1 ) FROM tab1
----
-11493901
-1848292
-4093928

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

query I rowsort
SELECT ALL + 47 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
1128
1645
4183

query I rowsort
SELECT ALL 35 FROM tab0 cor0
----
35
35
35

query I rowsort
SELECT DISTINCT - 20 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-20

query I rowsort
SELECT ALL 56 * col0 FROM tab1 AS cor0
----
168
3584
4480

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

query I rowsort
SELECT + 32 + col2 AS col1 FROM tab2 AS cor0
----
58
59
70

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

skipif mysql # not compatible
query I rowsort label-741
SELECT ALL + col1 * col1 * + CAST ( - col2 AS INTEGER ) FROM tab0 cor0
----
-244068
-679042
-9409

query I rowsort
SELECT - 30 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a96370a8187089b6b83ce9bfbade5142

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT tab1.col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
54
57
96

query I rowsort
SELECT ALL col0 + col0 * 63 FROM tab1
----
192
4096
5120

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

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

query I rowsort
SELECT + 89 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to bb5bb13eab35a33bb4641905f5e7c9b6

query I rowsort
SELECT DISTINCT + 78 AS col1 FROM tab1 cor0
----
78

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

query I rowsort
SELECT ALL + ( - 11 ) AS col0 FROM tab2 AS cor0
----
-11
-11
-11

query I rowsort
SELECT + 72 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT DISTINCT - col1 * 74 * col0 FROM tab1
----
-47360
-5772
-76960

query I rowsort
SELECT - - 68 * + col0 AS col1 FROM tab2 AS cor0
----
476
5304
5372

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

query I rowsort
SELECT ( cor0.col1 ) * - cor2.col1 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to bf1e0f66faa88c65bd30f110fcaed0e4

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

query I rowsort
SELECT - - 84 * + col2 AS col2 FROM tab2 cor0
----
2184
2268
3192

query I rowsort
SELECT ALL - 11 * + col2 FROM tab0
----
-11
-363
-902

query I rowsort
SELECT - + 93 * 90 AS col1 FROM tab0 AS cor0
----
-8370
-8370
-8370

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

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

query I rowsort
SELECT DISTINCT + 0 + col1 FROM tab0 cor0
----
86
91
97

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

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

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 ALL 68 AS col2 FROM tab0 AS cor0
----
68
68
68

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

query I rowsort
SELECT + col2 * 90 + + col0 * 15 * col0 AS col2 FROM tab1 AS cor0
----
104640
4995
66570

query I rowsort
SELECT - 7 * - 20 * + col1 AS col0 FROM tab2 AS cor0
----
2380
4340
8260

query I rowsort
SELECT - ( col0 ) + + col2 * - ( - 19 * + cor0.col0 ) FROM tab0 AS cor0
----
138573
15024
630

query I rowsort
SELECT DISTINCT - - cor0.col0 + + col0 FROM tab2 AS cor0
----
14
156
158

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

skipif mysql # not compatible
query I rowsort label-776
SELECT DISTINCT + 11 / col1 + + col0 * col1 / col0 AS col0 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT DISTINCT + col2 * - col0 * 82 AS col1 FROM tab1 AS cor0
----
-13284
-299136
-629760

query I rowsort
SELECT 89 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT - 87 * col0 * 97 AS col1 FROM tab0 AS cor0
----
-202536
-295365
-751071

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

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 - + 21 FROM tab2 AS cor0
----
1322
196
4581

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 91 + col1 col0 FROM tab1 cor0
----
-65
-78
-81

query I rowsort
SELECT - tab2.col1 * + 46 + col2 + - col1 FROM tab2
----
-1430
-2747
-761

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

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

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

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

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

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

query I rowsort
SELECT + col0 * - ( - ( col1 ) ) + - col0 + - col2 FROM tab0 cor0
----
2007
3359
7928

query I rowsort
SELECT col0 * - ( + ( col0 ) ) * 97 AS col0 FROM tab0
----
-118825
-55872
-768337

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

query I rowsort
SELECT + 28 * col0 + - col0 FROM tab0 AS cor0
----
2403
648
945

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

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

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

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

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

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

query I rowsort
SELECT ALL - col1 * - 39 * 86 AS col0 FROM tab0
----
288444
305214
325338

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

query I rowsort
SELECT ( + 11 ) * - col0 + 46 AS col0 FROM tab2 AS cor0
----
-31
-812
-823

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-806
SELECT DISTINCT col1 * - col0 - 19 / + col0 AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 + col1 + col1 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT + col1 - + 13 FROM tab1
----
-3
0
13

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-813
SELECT - tab2.col2 DIV col0 - ( col1 ) * tab2.col0 AS col1 FROM tab2
----
-1343
-220
-4602

skipif mysql # not compatible
query I rowsort label-813
SELECT - tab2.col2 / col0 - ( col1 ) * tab2.col0 AS col1 FROM tab2
----
-1343
-220
-4602

query I rowsort
SELECT 92 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT ALL - col2 * - col2 * 94 AS col1 FROM tab1 AS cor0
----
274104
305406
866304

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

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

skipif mysql # not compatible
query I rowsort label-817
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col1 * col2 + col1 + col2 AS col2 FROM tab2 AS cor0
----
-1449
-591
-779

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

skipif mysql # not compatible
query I rowsort label-819
SELECT DISTINCT cor0.col1 * CAST ( col0 AS INTEGER ) + col0 AS col2 FROM tab2 cor0
----
1422
224
4680

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

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

query I rowsort
SELECT DISTINCT col2 + 10 AS col0 FROM tab2
----
36
37
48

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

query I rowsort
SELECT col1 + 85 FROM tab1 AS cor0
----
111
95
98

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

query I rowsort
SELECT DISTINCT - + cor0.col0 + 42 * + col1 + col2 FROM tab2 AS cor0
----
1322
2426
673

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

query I rowsort
SELECT - col1 + - 27 FROM tab2 AS cor0
----
-44
-58
-86

query I rowsort
SELECT + - col1 * col2 - col0 * col0 FROM tab2 AS cor0
----
-6887
-7618
-886

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

query I rowsort
SELECT ALL - 99 FROM tab0
----
-99
-99
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-831
SELECT + + col1 * col1 + col0 DIV col1 AS col0 FROM tab1 cor0
----
106
175
676

skipif mysql # not compatible
query I rowsort label-831
SELECT + + col1 * col1 + col0 / col1 AS col0 FROM tab1 cor0
----
106
175
676

query I rowsort
SELECT col1 * cor0.col1 + - 86 AS col2 FROM tab0 AS cor0
----
7310
8195
9323

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

query I rowsort
SELECT col2 * cor0.col2 + - col2 FROM tab1 AS cor0
----
2862
3192
9120

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-837
SELECT - - col1 + + col0 * cor0.col1 DIV col1 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-837
SELECT - - col1 + + col0 * cor0.col1 / col1 FROM tab0 AS cor0
----
110
132
180

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

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

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

query I rowsort
SELECT 63 * col2 + col0 FROM tab1
----
3405
3655
6128

query I rowsort
SELECT 53 * - col2 FROM tab0
----
-1749
-4346
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-843
SELECT ALL 5 + col2 DIV ( + col2 ) FROM tab0
----
6
6
6

skipif mysql # not compatible
query I rowsort label-843
SELECT ALL 5 + col2 / ( + col2 ) FROM tab0
----
6
6
6

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 * + col2 * 53 col2 FROM tab2
----
35828
38637
76532

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col2 FROM tab1 WHERE col2 NOT IN ( tab1.col0 * col1 + + col1 + + tab1.col0 )
----
-54
-57
-96

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-853
SELECT DISTINCT + col2 * col0 + - col2 DIV col1 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-853
SELECT DISTINCT + col2 * col0 + - col2 / col1 FROM tab0
----
35
7298
792

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

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

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

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL < - col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-857
SELECT col1 DIV col2 + tab0.col1 DIV + col2 AS col0 FROM tab0
----
194
2
4

skipif mysql # not compatible
query I rowsort label-857
SELECT col1 / col2 + tab0.col1 / + col2 AS col0 FROM tab0
----
194
2
4

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

query I rowsort
SELECT ALL 46 * - 98 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to a67a7f1d737854bbd0583e4dfa92f332

query I rowsort
SELECT 46 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 086e8f56201fbf4c0ce74087e710811d

onlyif mysql # use DIV operator for integer division
query I rowsort label-861
SELECT ALL - col1 DIV col1 + col2 + col1 FROM tab1
----
108
66
79

skipif mysql # not compatible
query I rowsort label-861
SELECT ALL - col1 / col1 + col2 + col1 FROM tab1
----
108
66
79

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

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

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

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

query I rowsort
SELECT - - cor0.col0 * - cor0.col0 * - 93 FROM tab2 AS cor0
----
4557
565812
580413

query I rowsort
SELECT ( 67 ) AS col1 FROM tab2
----
67
67
67

query I rowsort
SELECT 10 * col0 * ( + col2 ) FROM tab2 AS cor0
----
1890
20280
30020

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

query I rowsort
SELECT DISTINCT 28 + cor1.col0 FROM tab1, tab2, tab2 AS cor0, tab2 AS cor1
----
106
107
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-871
SELECT - cor0.col1 DIV + 26 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to ccd77e2770d5a834e59c1674defa88fa

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-871
SELECT - cor0.col1 / + 26 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to ccd77e2770d5a834e59c1674defa88fa

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-873
SELECT - col1 + col1 DIV - col0 FROM tab1 AS cor0
----
-10
-13
-34

skipif mysql # not compatible
query I rowsort label-873
SELECT - col1 + col1 / - col0 FROM tab1 AS cor0
----
-10
-13
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-874
SELECT + cor0.col1 * col1 DIV + 81 FROM tab1 AS cor0
----
1
2
8

skipif mysql # not compatible
query I rowsort label-874
SELECT + cor0.col1 * col1 / + 81 FROM tab1 AS cor0
----
1
2
8

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

query I rowsort
SELECT DISTINCT - col0 + 39 AS col1 FROM tab1 AS cor0
----
-25
-41
36

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

query I rowsort
SELECT + + col2 * + ( 57 * - col2 ) + 97 + - col2 FROM tab2 AS cor0
----
-38461
-41483
-82249

query I rowsort
SELECT cor0.col1 * ( + cor0.col1 ) FROM tab1 AS cor0
----
100
169
676

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

skipif mysql # not compatible
query I rowsort label-880
SELECT + - 9 / col0 FROM tab0 cor0
----
0
0
0

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

query I rowsort
SELECT ( + 94 ) AS col2 FROM tab2
----
94
94
94

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

query I rowsort
SELECT - cor0.col0 * - 74 FROM tab0, tab1 AS cor0, tab0 cor1, tab1 AS cor2
----
81 values hashing to 17a3b84a91bea64454db0d4a6ca64d92

query I rowsort
SELECT - cor0.col1 FROM tab0, tab2 AS cor0, tab0 cor1, tab2, tab0 AS cor2
----
243 values hashing to aad6a39cc782d0570960622f04a07424

onlyif mysql # use DIV operator for integer division
query I rowsort label-886
SELECT + + 65 DIV col2 + col1 FROM tab1 cor0
----
11
13
27

skipif mysql # not compatible
query I rowsort label-886
SELECT + + 65 / col2 + col1 FROM tab1 cor0
----
11
13
27

query I rowsort
SELECT ALL 48 - - col2 AS col0 FROM tab0
----
130
49
81

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

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

query I rowsort
SELECT - col2 * - ( + 49 ) + + col1 FROM tab1 AS cor0
----
2672
2803
4717

query I rowsort
SELECT tab1.col1 + 58 FROM tab1
----
68
71
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-891
SELECT - tab1.col0 DIV col2 + ( + col0 ) AS col2 FROM tab1
----
3
63
80

skipif mysql # not compatible
query I rowsort label-891
SELECT - tab1.col0 / col2 + ( + col0 ) AS col2 FROM tab1
----
3
63
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col0 + + tab2.col2 + ( + col1 * col1 ) col2 FROM tab2
----
3585
406
995

query I rowsort
SELECT ALL tab0.col0 + - col1 * + col2 * col1 FROM tab0
----
-244044
-678953
-9374

query I rowsort
SELECT + col0 + 50 * + 13 + col0 * + col1 FROM tab0 AS cor0
----
2738
4080
8838

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

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

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

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

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

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

query I rowsort
SELECT ALL ( 52 ) AS col0 FROM tab0
----
52
52
52

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

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

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

query I rowsort
SELECT DISTINCT col2 * col1 * + col1 + - cor0.col0 FROM tab0 AS cor0
----
244044
678953
9374

query I rowsort
SELECT + ( + col0 ) * + 26 + col1 FROM tab2 AS cor0
----
2071
2087
213

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

query I rowsort
SELECT DISTINCT + col2 * col1 + 70 * 32 FROM tab1 AS cor0
----
2810
3488
3644

query I rowsort
SELECT - 95 - col1 * + col1 FROM tab1 cor0
----
-195
-264
-771

query I rowsort
SELECT + 9 * + col1 AS col2 FROM tab2
----
153
279
531

query I rowsort
SELECT ALL + 79 * - cor0.col0 - col2 FROM tab2 AS cor0
----
-580
-6188
-6279

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-910
SELECT ALL + col0 - col1 / + col1 col2 FROM tab0 AS cor0
----
23
34
88

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

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

query I rowsort
SELECT DISTINCT 52 + - col1 * - ( cor0.col2 ) FROM tab0 AS cor0
----
149
2890
7514

query I rowsort
SELECT + 27 * + col0 - - 62 FROM tab0 AS cor0
----
1007
2465
710

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + - col0 * col2 + 12 AS col0 FROM tab0 cor0
----
-23
-7286
-780

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

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

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

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

query I rowsort
SELECT ALL + 58 + col2 + - col2 AS col2 FROM tab0
----
58
58
58

query I rowsort
SELECT DISTINCT tab0.col1 * + col1 + 76 FROM tab0
----
7472
8357
9485

query I rowsort
SELECT + 48 + col1 * 54 FROM tab1
----
1452
588
750

query I rowsort
SELECT col0 + - col0 * 78 * 48 + - col1 * col0 AS col0 FROM tab2
----
-26418
-296556
-297040

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-929
SELECT ALL + - CAST( + 81 AS SIGNED ) * col1 FROM tab2 cor0
----
-1377
-2511
-4779

skipif mysql # not compatible
query I rowsort label-929
SELECT ALL + - CAST ( + 81 AS INTEGER ) * col1 FROM tab2 cor0
----
-1377
-2511
-4779

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

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

query I rowsort
SELECT ALL + cor0.col2 * + 11 + cor0.col0 FROM tab2 AS cor0
----
304
364
497

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

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

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

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

query I rowsort
SELECT DISTINCT + cor0.col1 * 74 AS col0 FROM tab2 AS cor0
----
1258
2294
4366

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

query I rowsort
SELECT 31 + tab2.col0 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 546c51ad14975a9479b8fc88bc9261dd

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

query I rowsort
SELECT DISTINCT col2 * col2 + - col2 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT ALL + 34 + tab1.col2 * - tab1.col2 AS col1 FROM tab2, tab0, tab1 cor0, tab1
----
81 values hashing to 3acbf332d6a89ab237ed7fb6bf044278

query I rowsort
SELECT - ( 10 ) FROM tab1, tab1 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

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

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

query I rowsort
SELECT - 49 FROM tab2, tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
27 values hashing to adfccb10c9468825d9961e3613140f89

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

query I rowsort
SELECT ALL + - 73 AS col1 FROM tab2 AS cor0
----
-73
-73
-73

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-948
SELECT DISTINCT col1 DIV 41 FROM tab0
----
2

skipif mysql # not compatible
query I rowsort label-948
SELECT DISTINCT col1 / 41 FROM tab0
----
2

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

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

query I rowsort
SELECT + col0 * + 28 + - tab0.col1 FROM tab0
----
2401
586
883

query I rowsort
SELECT ALL col1 + 75 * - col2 FROM tab0 AS cor0
----
-2389
-6059
22

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

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

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

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

query I rowsort
SELECT DISTINCT + + col0 * - col0 - col2 AS col2 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT ALL - 52 * cor0.col0 AS col2 FROM tab2 AS cor0
----
-364
-4056
-4108

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 82 + col1 - col2 col2 FROM tab1 AS cor0
----
2104
773
983

query I rowsort
SELECT DISTINCT - 56 * cor0.col2 FROM tab1 AS cor0
----
-3024
-3192
-5376

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

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

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

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

query I rowsort
SELECT DISTINCT + 50 * + col2 FROM tab1 AS cor0
----
2700
2850
4800

query I rowsort
SELECT 87 - col1 FROM tab1 cor0
----
61
74
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-966
SELECT + col1 + + ( 25 ) * + col0 + + CAST( 20 AS SIGNED ) FROM tab1
----
121
1630
2033

skipif mysql # not compatible
query I rowsort label-966
SELECT + col1 + + ( 25 ) * + col0 + + CAST ( 20 AS INTEGER ) FROM tab1
----
121
1630
2033

query I rowsort
SELECT - + col0 + - 2 FROM tab2 AS cor0
----
-80
-81
-9

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

query I rowsort
SELECT - 99 - col0 FROM tab0 AS cor0
----
-123
-134
-188

onlyif mysql # use DIV operator for integer division
query I rowsort label-970
SELECT DISTINCT + cor0.col0 + col2 DIV - ( + col2 ) AS col2 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-970
SELECT DISTINCT + cor0.col0 + col2 / - ( + col2 ) AS col2 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT DISTINCT - col1 * + col2 + - ( + col1 ) FROM tab0 cor0
----
-194
-2924
-7553

query I rowsort
SELECT + + 62 * col1 FROM tab2 AS cor0
----
1054
1922
3658

query I rowsort
SELECT ALL - 12 - col2 AS col2 FROM tab0 AS cor0
----
-13
-45
-94

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

skipif mysql # not compatible
query I rowsort label-974
SELECT DISTINCT + col2 / col2 + 30 AS col2 FROM tab1 AS cor0
----
31

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

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - 37 * - cor1.col0 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to bdb0b04c6f55ca65ec0cc7083b4febfb

query I rowsort
SELECT ALL + col0 * + 71 FROM tab1 AS cor0
----
213
4544
5680

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 79 col0 FROM tab0 AS cor0
----
-6794
-7189
-7663

query I rowsort
SELECT + col0 + + cor0.col1 * col0 * col0 AS col0 FROM tab0 AS cor0
----
118860
49560
720900

query I rowsort
SELECT col1 + 4 * - col0 FROM tab0 cor0
----
-10
-265
-43

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-995
SELECT - 38 DIV cor1.col2 col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e5eefcd71fd078d50bbc31247ea7c490

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-995
SELECT - 38 / cor1.col2 col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e5eefcd71fd078d50bbc31247ea7c490

query I rowsort
SELECT + 29 + + col2 FROM tab1 cor0
----
125
83
86

query I rowsort
SELECT col0 + - col2 * + col2 * 4 AS col2 FROM tab2 AS cor0
----
-2626
-2909
-5697

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

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

query I rowsort
SELECT 48 + col1 AS col1 FROM tab2 AS cor0
----
107
65
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1000
SELECT - 92 DIV col1 FROM tab1 cor0
----
-3
-7
-9

skipif mysql # not compatible
query I rowsort label-1000
SELECT - 92 / col1 FROM tab1 cor0
----
-3
-7
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1001
SELECT ALL CAST( col0 AS SIGNED ) DIV - col0 + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-1001
SELECT ALL CAST ( col0 AS INTEGER ) / - col0 + col0 FROM tab1 AS cor0
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 62 * col2 col0 FROM tab0 cor0
----
2046
5084
62

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1004
SELECT + - col2 - col0 DIV col1 FROM tab1 AS cor0
----
-102
-54
-63

skipif mysql # not compatible
query I rowsort label-1004
SELECT + - col2 - col0 / col1 FROM tab1 AS cor0
----
-102
-54
-63

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

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

query I rowsort
SELECT DISTINCT - col0 * - 21 AS col2 FROM tab1 AS cor0
----
1344
1680
63

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

query I rowsort
SELECT DISTINCT - 66 * col2 FROM tab2 cor0
----
-1716
-1782
-2508

query I rowsort
SELECT DISTINCT - + col0 + + 97 + + col1 AS col1 FROM tab1 AS cor0
----
120
30
43

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

skipif mysql # not compatible
query I rowsort label-1010
SELECT ALL CAST ( NULL AS REAL ) - cor0.col0 / col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * + 7 + col1 FROM tab1 AS cor0
----
-352
-389
-659

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

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

skipif mysql # not compatible
query I rowsort label-1013
SELECT + cor0.col0 / col2 - - col1 AS col0 FROM tab1 AS cor0
----
11
13
26

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

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

query I rowsort
SELECT ALL + 45 + col1 * - cor0.col1 FROM tab1 AS cor0
----
-124
-55
-631

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

query I rowsort
SELECT ( 73 ) * col1 + - 23 AS col2 FROM tab0 cor0
----
6255
6620
7058

query I rowsort
SELECT + ( tab2.col1 ) FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab1 cor1
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT - tab1.col1 * - col1 + + col0 * - col1 AS col2 FROM tab1
----
-540
-871
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-1020
SELECT + cor0.col2 DIV - cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-1020
SELECT + cor0.col2 / - cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

onlyif mysql # use DIV operator for integer division
query I rowsort label-1021
SELECT - col0 DIV - 83 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1021
SELECT - col0 / - 83 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1022
SELECT - CAST( - col1 AS SIGNED ) * col2 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-1022
SELECT - CAST ( - col1 AS INTEGER ) * col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ( - 44 ) FROM tab0
----
-44
-44
-44

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

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

query I rowsort
SELECT + + col1 * 65 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
134160
220675
526435

query I rowsort
SELECT col0 - - 28 * + col1 * - col1 FROM tab0
----
-207064
-231779
-263417

query I rowsort
SELECT ALL - col0 + col0 * 35 + col0 * - col1 FROM tab0 AS cor0
----
-1248
-2205
-5073

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

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

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

query I rowsort
SELECT col1 + + 36 AS col2 FROM tab2
----
53
67
95

query I rowsort
SELECT DISTINCT col1 + 98 AS col1 FROM tab1 cor0
----
108
111
124

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

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

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

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

query I rowsort
SELECT ALL - col2 - 1 * + 42 FROM tab2 AS cor0
----
-68
-69
-80

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

skipif mysql # not compatible
query I rowsort label-1037
SELECT ALL + cor0.col2 + CAST ( col2 AS INTEGER ) * + col1 * CAST ( col2 * col1 AS INTEGER ) FROM tab0 AS cor0
----
55681526
8054277
9410

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

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

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

query I rowsort
SELECT 9 * + 73 AS col0 FROM tab2 AS cor0
----
657
657
657

query I rowsort
SELECT ALL - + ( ( col2 ) ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + - 30 * 75 AS col0 FROM tab2 cor0
----
-2250

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

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

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

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

query I rowsort
SELECT ALL + 55 * - 20 FROM tab1 AS cor0
----
-1100
-1100
-1100

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

query I rowsort
SELECT ALL + cor0.col2 * col2 * - ( + ( + col2 ) ) + + 9 + + col1 AS col0 FROM tab0 AS cor0
----
-35842
-551268
105

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

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT ALL col0 * - col2 + + CAST ( - 96 * + col1 AS REAL ) + 96 * + col0 FROM tab1 cor0
----
-1248
-2370
1536

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

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

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

query I rowsort
SELECT ALL col0 * 61 + col2 * col2 + + ( 5 * cor0.col1 + col1 * + col2 ) FROM tab0 AS cor0
----
20070
2718
5821

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

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

query I rowsort
SELECT DISTINCT + col2 + - 74 FROM tab2 AS cor0
----
-36
-47
-48

query I rowsort
SELECT DISTINCT + col1 * + 35 + col2 AS col2 FROM tab1 AS cor0
----
407
551
964

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

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

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

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

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

query I rowsort
SELECT ALL + - col0 + - 12 * + 1 AS col1 FROM tab0 cor0
----
-101
-36
-47

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

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

query I rowsort
SELECT 37 * col2 * - col0 + 44 FROM tab0
----
-1251
-269982
-29260

query I rowsort
SELECT tab2.col2 * + col0 + + 79 AS col0 FROM tab2
----
2107
268
3081

query I rowsort
SELECT DISTINCT 96 + - col0 FROM tab2
----
17
18
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1073
SELECT + ( - col1 ) * + ( col0 ) - + col2 DIV tab1.col1 FROM tab1
----
-1047
-645
-80

skipif mysql # not compatible
query I rowsort label-1073
SELECT + ( - col1 ) * + ( col0 ) - + col2 / tab1.col1 FROM tab1
----
-1047
-645
-80

query I rowsort
SELECT - col2 + - cor0.col0 * ( col0 ) * col2 AS col1 FROM tab0 AS cor0
----
-1226
-19041
-649604

query I rowsort
SELECT + 84 * 29 * - col2 + - 5 AS col0 FROM tab2
----
-63341
-65777
-92573

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

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

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

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

query I rowsort
SELECT DISTINCT tab2.col1 * + col1 * ( 20 + + col2 ) FROM tab2
----
160126
16762
45167

query I rowsort
SELECT ALL + 88 * col1 AS col2 FROM tab0 AS cor0
----
7568
8008
8536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + 77 * + col0 * col0 + col2 col2 FROM tab0
----
44409
610088
94361

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 70 col2 FROM tab2
----
-1820
-1890
-2660

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

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

query I rowsort
SELECT DISTINCT - col0 * + 10 * 37 + - col0 * col2 AS col2 FROM tab1
----
-1272
-27328
-37280

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 + - 13 + col1 * - col0 col1 FROM tab0
----
-2110
-3409
-8194

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1087
SELECT DISTINCT + cor0.col1 DIV - cor0.col0 AS col2 FROM tab1, tab0, tab2 cor0, tab2 AS cor1
----
-4
0

skipif mysql # not compatible
query I rowsort label-1087
SELECT DISTINCT + cor0.col1 / - cor0.col0 AS col2 FROM tab1, tab0, tab2 cor0, tab2 AS cor1
----
-4
0

query I rowsort
SELECT + col1 * + 95 FROM tab0
----
8170
8645
9215

onlyif mysql # use DIV operator for integer division
query I rowsort label-1089
SELECT ALL - - col2 DIV cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
2

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

query I rowsort
SELECT ALL - col1 * 2 FROM tab0 AS cor0
----
-172
-182
-194

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1092
SELECT DISTINCT + - 18 DIV - col1 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-1092
SELECT DISTINCT + - 18 / - col1 FROM tab1 AS cor0
----
0
1

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1094
SELECT - 50 DIV - 18 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-1094
SELECT - 50 / - 18 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT ALL + + 45 + col0 FROM tab0 AS cor0
----
134
69
80

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

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

skipif mysql # not compatible
query I rowsort label-1097
SELECT - CAST ( col1 AS INTEGER ) + col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT 86 * + col2 FROM tab1 AS cor0
----
4644
4902
8256

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1100
SELECT col0 + + ( col1 ) DIV 68 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-1100
SELECT col0 + + ( col1 ) / 68 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT DISTINCT + 76 + + 70 FROM tab0
----
146

onlyif mysql # use DIV operator for integer division
query I rowsort label-1102
SELECT ALL + ( - col0 ) * - col1 DIV - col1 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-1102
SELECT ALL + ( - col0 ) * - col1 / - col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT - + cor0.col2 + col0 + col0 * col2 FROM tab2 AS cor0
----
169
2080
3043

query I rowsort
SELECT col2 + - col1 * - 70 * - 3 FROM tab2 AS cor0
----
-12364
-3532
-6483

query I rowsort
SELECT + - ( + col2 ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT col1 * - cor0.col1 + + 5 + cor0.col0 FROM tab0 AS cor0
----
-7367
-8187
-9369

query I rowsort
SELECT ALL 35 * col0 * - col2 + + 49 * col2 + - ( - 92 ) FROM tab0 cor0
----
-1084
-251320
-26011

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1109
SELECT - ( col2 ) * col2 + + col2 DIV col1 AS col1 FROM tab1 AS cor0
----
-2914
-3244
-9209

skipif mysql # not compatible
query I rowsort label-1109
SELECT - ( col2 ) * col2 + + col2 / col1 AS col1 FROM tab1 AS cor0
----
-2914
-3244
-9209

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

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

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

query I rowsort
SELECT ALL + cor0.col0 + col2 + ( - col1 ) AS col2 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT DISTINCT + col0 * - col0 * + col2 AS col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT cor0.col1 - - 79 * col2 FROM tab2 AS cor0
----
2113
2164
3019

query I rowsort
SELECT - col1 + 13 * + cor0.col1 AS col2 FROM tab2 cor0
----
204
372
708

query I rowsort
SELECT - col1 * + 7 AS col1 FROM tab0 AS cor0
----
-602
-637
-679

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

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

query I rowsort
SELECT + col0 * 55 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT - col2 * 45 * + col1 FROM tab0 cor0
----
-127710
-335790
-4365

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

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

query I rowsort
SELECT ALL + 37 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT - col2 + + 41 AS col1 FROM tab2 AS cor0
----
14
15
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * 60 col1 FROM tab2
----
1020
1860
3540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + - cor0.col2 * col2 col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

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

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

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

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

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

query I rowsort
SELECT DISTINCT - 3 AS col1 FROM tab1 AS cor0
----
-3

query I rowsort
SELECT ALL + 10 + col2 AS col2 FROM tab0 AS cor0
----
11
43
92

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1133
SELECT DISTINCT - col2 + + col0 * col2 DIV - col1 AS col2 FROM tab1 AS cor0
----
-421
-60
-686

skipif mysql # not compatible
query I rowsort label-1133
SELECT DISTINCT - col2 + + col0 * col2 / - col1 AS col2 FROM tab1 AS cor0
----
-421
-60
-686

query I rowsort
SELECT ALL - col1 * col1 + col1 FROM tab1 AS cor0
----
-156
-650
-90

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

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

query I rowsort
SELECT ALL 73 * col1 * col1 AS col2 FROM tab2 cor0
----
21097
254113
70153

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + 33 col1 FROM tab0 AS cor0
----
122
57
68

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col1 ) col1 FROM tab0
----
86
91
97

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

query I rowsort
SELECT DISTINCT - col2 * col1 + + col0 * + col0 AS col2 FROM tab1
----
-1395
3526
5152

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

query I rowsort
SELECT DISTINCT + col1 * col0 + col2 + - col1 FROM tab2
----
1364
213
4569

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

query I rowsort
SELECT + ( 47 ) + col0 AS col1 FROM tab0 AS cor0
----
136
71
82

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1149
SELECT ALL + col0 DIV - col0 FROM tab1 AS cor0 WHERE NOT + col0 NOT IN ( col0 )
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1149
SELECT ALL + col0 / - col0 FROM tab1 AS cor0 WHERE NOT + col0 NOT IN ( col0 )
----
-1
-1
-1

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1151
SELECT ALL col0 * - col0 + col1 DIV col0 AS col0 FROM tab2
----
-45
-6084
-6241

skipif mysql # not compatible
query I rowsort label-1151
SELECT ALL col0 * - col0 + col1 / col0 AS col0 FROM tab2
----
-45
-6084
-6241

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - tab1.col1 + col0 col1 FROM tab1 WHERE + col2 * col1 >= + col0
----
-576
-75
-960

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

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND col1
----

query I rowsort
SELECT - col2 AS col2 FROM tab0 WHERE NULL >= col1 * col1 / + col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1157
SELECT col1 + col1 * col0 DIV col0 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-1157
SELECT col1 + col1 * col0 / col0 FROM tab1
----
20
26
52

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1159
SELECT ALL - col1 DIV col0 + cor0.col2 + + col1 AS col2 FROM tab2 AS cor0
----
54
55
85

skipif mysql # not compatible
query I rowsort label-1159
SELECT ALL - col1 / col0 + cor0.col2 + + col1 AS col2 FROM tab2 AS cor0
----
54
55
85

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1163
SELECT + col0 DIV + tab1.col1 + - col2 + col0 FROM tab1
----
-10
-51
13

skipif mysql # not compatible
query I rowsort label-1163
SELECT + col0 / + tab1.col1 + - col2 + col0 FROM tab1
----
-10
-51
13

query I rowsort
SELECT tab0.col0 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL - col1 + + col0 - col1 FROM tab2
----
-40
-55
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + tab1.col1 + col2 + - col1 * col0 col1 FROM tab1
----
-483
-775
652

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 col1 FROM tab1
----
-23
54
67

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 + - col1 * col2 col0 FROM tab1 AS cor0
----
-1261
-1430
-580

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

query I rowsort
SELECT ALL + col2 * col2 * + col2 AS col2 FROM tab0 AS cor0
----
1
35937
551368

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 - - col1 col0 FROM tab0 AS cor0
----
53
9
96

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col2 + - col0 * + col0 col0 FROM tab0 AS cor0
----
-1322
-15383
-3414

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + col1 * - col1 col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 77 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

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

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

query I rowsort
SELECT DISTINCT + 44 FROM tab1, tab0 cor0
----
44

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

query I rowsort
SELECT - col0 + 48 AS col2 FROM tab1
----
-16
-32
45

query I rowsort
SELECT + 65 FROM tab2, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

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

query I rowsort
SELECT + 56 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT ALL col1 * 55 AS col1 FROM tab1
----
1430
550
715

query I rowsort
SELECT tab0.col0 * - 32 FROM tab0
----
-1120
-2848
-768

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

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

query I rowsort
SELECT - col0 + col1 - cor0.col0 * + cor0.col0 FROM tab2 AS cor0
----
-25
-6103
-6303

query I rowsort
SELECT - - 1 + col1 FROM tab1 AS cor0
----
11
14
27

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col2 col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL + col2 + 48 - col1 * col2 FROM tab2
----
-1460
-560
-762

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

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

query I rowsort
SELECT ALL + 28 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

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

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

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

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

query I rowsort
SELECT col0 * col0 + - col2 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
1223
510
7757

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

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

query I rowsort
SELECT + 25 * - col0 + + col2 * ( col2 ) + col2 AS col0 FROM tab2 AS cor0
----
-1248
-493
581

query I rowsort
SELECT DISTINCT - col2 + col0 * 89 AS col2 FROM tab0 AS cor0
----
2103
3114
7839

query I rowsort
SELECT DISTINCT - 86 + col1 AS col1 FROM tab0 AS cor0
----
0
11
5

query I rowsort
SELECT + col0 + + col2 + + col2 FROM tab2 AS cor0
----
130
155
61

query I rowsort
SELECT - 86 * - col1 + col0 - 15 AS col1 FROM tab1 AS cor0
----
1183
2224
909

query I rowsort
SELECT DISTINCT - ( - ( - tab2.col0 ) ) - cor1.col2 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
9 values hashing to b882d9857ad9baf559454a3a48269a6d

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

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

query I rowsort
SELECT DISTINCT - col0 * + 97 AS col2 FROM tab2 AS cor0
----
-679
-7566
-7663

onlyif mysql # use DIV operator for integer division
query I rowsort label-1222
SELECT DISTINCT col2 DIV - 35 AS col1 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-1222
SELECT DISTINCT col2 / - 35 AS col1 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT ALL + col2 * ( + 52 ) FROM tab2 AS cor0
----
1352
1404
1976

query I rowsort
SELECT 84 + - col2 * tab1.col2 * + col0 + tab1.col2 FROM tab1
----
-207795
-737100
-8610

query I rowsort
SELECT - + 76 + + col2 - - col1 FROM tab0 AS cor0
----
22
43
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 40 + col0 col2 FROM tab1 cor0
----
104
120
43

query I rowsort
SELECT DISTINCT cor1.col2 * cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
1
1089
2706
33
6724
82

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

skipif mysql # not compatible
query I rowsort label-1228
SELECT col1 * CAST ( - col2 AS INTEGER ) + + col0 FROM tab2 AS cor0
----
-1456
-567
-830

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1230
SELECT - col2 * + col2 + - col0 DIV col1 - - col2 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-16902
-3078
-6903

skipif mysql # not compatible
query I rowsort label-1230
SELECT - col2 * + col2 + - col0 / col1 - - col2 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-16902
-3078
-6903

query I rowsort
SELECT ALL col0 * col1 + col1 + - col0 AS col2 FROM tab2 AS cor0
----
1281
241
4583

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

skipif mysql # not compatible
query I rowsort label-1232
SELECT ALL + col1 / ( col2 * - col0 ) - 1 FROM tab0 AS cor0
----
-1
-1
-3

query I rowsort
SELECT - cor0.col0 + - 40 AS col0 FROM tab2 AS cor0
----
-118
-119
-47

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

query I rowsort
SELECT + - col0 * col1 * col2 - col0 * col0 * - col2 FROM tab2 AS cor0
----
-4536
186124
38532

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

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

query I rowsort
SELECT DISTINCT col2 + - 38 FROM tab1
----
16
19
58

query I rowsort
SELECT DISTINCT tab1.col2 + + 67 + col2 AS col1 FROM tab1
----
175
181
259

query I rowsort
SELECT - ( - tab2.col2 ) FROM tab2
----
26
27
38

query I rowsort
SELECT ALL + 24 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT + col2 * 77 * col2 AS col1 FROM tab2
----
111188
52052
56133

query I rowsort
SELECT DISTINCT 51 + - col0 AS col2 FROM tab1
----
-13
-29
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-1244
SELECT DISTINCT 93 + + 14 + + col0 DIV col0 FROM tab2
----
108

skipif mysql # not compatible
query I rowsort label-1244
SELECT DISTINCT 93 + + 14 + + col0 / col0 FROM tab2
----
108

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

query I rowsort
SELECT DISTINCT + ( - col1 ) * col0 + col1 FROM tab1
----
-1027
-52
-630

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

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

query I rowsort
SELECT 96 * col0 AS col1 FROM tab2 AS cor0
----
672
7488
7584

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

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

query I rowsort
SELECT col0 * + col0 * col2 AS col2 FROM tab0 cor0
----
1225
19008
649522

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

query I rowsort
SELECT + 57 * tab0.col2 * 65 + - col2 FROM tab0
----
122232
303728
3704

query I rowsort
SELECT + col0 * col0 * + 52 AS col0 FROM tab2 AS cor0
----
2548
316368
324532

query I rowsort
SELECT ALL - 63 * 55 AS col0 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c62a32fae9a58b9127f3b38984c5ceaa

query I rowsort
SELECT ALL + cor0.col0 * - col1 + - 81 AS col0 FROM tab0 AS cor0
----
-2145
-3476
-8180

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

query I rowsort
SELECT - - 90 AS col1 FROM tab2 AS cor0
----
90
90
90

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 49 * cor0.col2 col1 FROM tab0 AS cor0
----
1617
4018
49

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

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

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

query I rowsort
SELECT + col2 - - col0 * 85 AS col2 FROM tab0 AS cor0
----
2073
2976
7647

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

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

skipif mysql # not compatible
query I rowsort label-1265
SELECT DISTINCT - col0 + CAST ( ( - col2 ) AS INTEGER ) FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - cor0.col2 * 32 FROM tab1 AS cor0
----
-1728
-1824
-3072

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

query I rowsort
SELECT + + col0 - - 22 * + cor0.col2 FROM tab1 AS cor0
----
1191
1318
2192

query I rowsort
SELECT ALL + col2 + 41 AS col0 FROM tab2 AS cor0
----
67
68
79

query I rowsort
SELECT DISTINCT - col1 * + col2 - - 31 * + col1 FROM tab2 AS cor0
----
-119
124
295

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

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

query I rowsort
SELECT + col1 * ( - col2 ) + col2 * 91 AS col2 FROM tab2 AS cor0
----
1620
2812
832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - - ( - col2 ) col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - col0 + 30 FROM tab2 AS cor0
----
-48
-49
23

query I rowsort
SELECT ALL col2 * col2 - - ( + col1 ) FROM tab2 AS cor0
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-1276
SELECT ALL + col0 DIV + 20 FROM tab2 AS cor0
----
0
3
3

skipif mysql # not compatible
query I rowsort label-1276
SELECT ALL + col0 / + 20 FROM tab2 AS cor0
----
0
3
3

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

query I rowsort
SELECT 55 * + col0 + - cor0.col1 * col0 * + 13 AS col0 FROM tab2 AS cor0
----
-13114
-2436
-55536

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

query I rowsort
SELECT DISTINCT + - col0 + 10 + col2 FROM tab0 cor0
----
-24
19
3

query I rowsort
SELECT + + ( 6 ) + col2 FROM tab0 AS cor0
----
39
7
88

query I rowsort
SELECT DISTINCT - col0 * - ( col2 ) - tab0.col1 FROM tab0
----
-62
706
7207

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 59 - - col1 * col1 col2 FROM tab1 cor0
----
159
228
735

query I rowsort
SELECT DISTINCT - 74 * col1 AS col0 FROM tab1 AS cor0
----
-1924
-740
-962

query I rowsort
SELECT DISTINCT + ( - 98 ) * + col2 + 90 FROM tab2 AS cor0
----
-2458
-2556
-3634

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

query I rowsort
SELECT ALL + 79 + + 27 FROM tab0 AS cor0
----
106
106
106

query I rowsort
SELECT DISTINCT cor0.col1 + - 49 AS col1 FROM tab1 AS cor0
----
-23
-36
-39

query I rowsort
SELECT - 51 * cor0.col2 + cor0.col0 * 50 FROM tab0 AS cor0
----
-483
1699
268

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

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

query I rowsort
SELECT DISTINCT - 91 + tab2.col0 + + 79 FROM tab2, tab0 AS cor0
----
-5
66
67

query I rowsort
SELECT ALL + col0 + + 73 FROM tab1 AS cor0
----
137
153
76

query I rowsort
SELECT - - ( - 42 ) FROM tab1 AS cor0
----
-42
-42
-42

query I rowsort
SELECT ALL - ( 34 ) + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-51
-65
-93

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

query I rowsort
SELECT ALL - 31 * cor0.col0 + col2 + ( - col1 ) AS col0 FROM tab1 AS cor0
----
-1937
-2397
-65

query I rowsort
SELECT + col0 + + 14 FROM tab2 AS cor0
----
21
92
93

query I rowsort
SELECT 70 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

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

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

query I rowsort
SELECT ALL 64 + 11 * + col1 + - ( - cor0.col0 ) FROM tab2 AS cor0
----
330
412
791

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1306
SELECT ALL - + 23 DIV col2 - - col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-1306
SELECT ALL - + 23 / col2 - - col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL 91 * + ( + cor0.col1 ) AS col2 FROM tab0 cor0
----
7826
8281
8827

query I rowsort
SELECT - col0 * - ( - cor0.col0 ) + - 98 AS col2 FROM tab0 AS cor0
----
-1323
-674
-8019

onlyif mysql # use DIV operator for integer division
query I rowsort label-1309
SELECT + 27 DIV col0 + col1 * + col1 FROM tab1 AS cor0
----
100
169
685

skipif mysql # not compatible
query I rowsort label-1309
SELECT + 27 / col0 + col1 * + col1 FROM tab1 AS cor0
----
100
169
685

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

query I rowsort
SELECT cor0.col1 * col0 * + 90 AS col2 FROM tab1 AS cor0
----
57600
7020
93600

query I rowsort
SELECT - col2 * - 96 AS col2 FROM tab1 cor0
----
5184
5472
9216

query I rowsort
SELECT col2 + 37 FROM tab2 cor0
----
63
64
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-1314
SELECT DISTINCT + - col2 + + col0 DIV + col2 FROM tab1 AS cor0
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-1314
SELECT DISTINCT + - col2 + + col0 / + col2 FROM tab1 AS cor0
----
-54
-56
-96

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

skipif mysql # not compatible
query I rowsort label-1315
SELECT ALL - col2 + + CAST ( col1 AS INTEGER ) * - col1 AS col0 FROM tab1 cor0
----
-157
-265
-730

query I rowsort
SELECT col2 * + ( - 44 + + col0 ) * col0 FROM tab0
----
-15840
-315
328410

query I rowsort
SELECT + col2 * col2 + 55 AS col1 FROM tab1
----
2971
3304
9271

query I rowsort
SELECT DISTINCT ( - 20 ) FROM tab2, tab1, tab1 AS cor0, tab0 AS cor1
----
-20

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + ( + 77 ) col0 FROM tab1
----
103
87
90

query I rowsort
SELECT DISTINCT - 38 * + 85 * - tab0.col0 - 96 FROM tab0, tab0 AS cor0
----
112954
287374
77424

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

query I rowsort
SELECT ALL + col0 + - col2 * - 96 * col2 AS col1 FROM tab2
----
138703
64974
69991

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

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

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

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

query I rowsort
SELECT DISTINCT - cor0.col1 * - cor0.col2 FROM tab0 AS cor0
----
2838
7462
97

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

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

query I rowsort
SELECT col1 + cor0.col2 * + 69 * - col1 FROM tab0 AS cor0
----
-195736
-514787
-6596

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1331
SELECT - col0 DIV 98 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1331
SELECT - col0 / 98 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL col0 * 12 FROM tab0 AS cor0
----
1068
288
420

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

query I rowsort
SELECT ALL - 67 * cor0.col0 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 8e81cba09bc594618d54e53134dd1b22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-17
-31
-59

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

query I rowsort
SELECT 75 * - col0 + + col0 FROM tab2 AS cor0
----
-518
-5772
-5846

query I rowsort
SELECT + col1 - + col0 * + 8 FROM tab0 AS cor0
----
-106
-183
-621

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

skipif mysql # not compatible
query I rowsort label-1339
SELECT ALL - col2 / col1 + + ( col1 ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + - col1 * col1 + ( - cor0.col1 ) * col0 * + col1 FROM tab1 AS cor0
----
-13689
-2704
-6500

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

query I rowsort
SELECT + - col0 + - 32 FROM tab1 AS cor0
----
-112
-35
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1343
SELECT cor0.col1 DIV - 3 FROM tab0 AS cor0
----
-28
-30
-32

skipif mysql # not compatible
query I rowsort label-1343
SELECT cor0.col1 / - 3 FROM tab0 AS cor0
----
-28
-30
-32

query I rowsort
SELECT col1 * - 25 + cor0.col1 AS col2 FROM tab0 AS cor0
----
-2064
-2184
-2328

query I rowsort
SELECT ALL cor0.col0 + + tab0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 727cf91885da1564b9eb8c57fe9a5d27

onlyif mysql # use DIV operator for integer division
query I rowsort label-1346
SELECT - + col0 DIV 49 + col2 AS col2 FROM tab1 AS cor0
----
54
56
95

skipif mysql # not compatible
query I rowsort label-1346
SELECT - + col0 / 49 + col2 AS col2 FROM tab1 AS cor0
----
54
56
95

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

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

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

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE NOT cor0.col0 > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1351
SELECT DISTINCT - 68 DIV + cor2.col1 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
-2
-5
-6

skipif mysql # not compatible
query I rowsort label-1351
SELECT DISTINCT - 68 / + cor2.col1 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
-2
-5
-6

query I rowsort
SELECT - 27 - col2 FROM tab2 cor0
----
-53
-54
-65

query I rowsort
SELECT + - ( - col2 ) + + 60 * col1 FROM tab0 AS cor0
----
5193
5542
5821

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

query I rowsort
SELECT - cor0.col2 + cor0.col0 - col1 FROM tab0 cor0
----
-63
-84
-95

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

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

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

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

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

query I rowsort
SELECT ALL ( col1 ) * - 79 * + col0 AS col0 FROM tab0 AS cor0
----
-163056
-268205
-639821

query I rowsort
SELECT + 28 * + col2 FROM tab1 AS cor0
----
1512
1596
2688

query I rowsort
SELECT - ( + cor0.col1 ) + + 58 AS col0 FROM tab2 cor0
----
-1
27
41

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

query I rowsort
SELECT col0 * + cor0.col0 + 97 FROM tab0 cor0
----
1322
673
8018

query I rowsort
SELECT 64 * col1 AS col1 FROM tab0
----
5504
5824
6208

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

query I rowsort
SELECT ALL col1 * 1 FROM tab1
----
10
13
26

query I rowsort
SELECT + 90 * - col1 AS col2 FROM tab2 AS cor0
----
-1530
-2790
-5310

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

query I rowsort
SELECT ALL - col1 * + col1 * 8 FROM tab0
----
-59168
-66248
-75272

query I rowsort
SELECT + col2 * 58 FROM tab0
----
1914
4756
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * ( 33 ) col2 FROM tab0
----
2838
3003
3201

query I rowsort
SELECT + col1 * 19 AS col0 FROM tab1 cor0
----
190
247
494

query I rowsort
SELECT - - ( col1 ) * - col1 AS col1 FROM tab1 AS cor0
----
-100
-169
-676

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

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

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

query I rowsort
SELECT ALL - col1 + 27 AS col0 FROM tab0 AS cor0
----
-59
-64
-70

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1378
SELECT - col1 DIV cor0.col1 + col0 AS col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-1378
SELECT - col1 / cor0.col1 + col0 AS col0 FROM tab1 AS cor0
----
2
63
79

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

query I rowsort
SELECT col2 + 86 FROM tab0 cor0
----
119
168
87

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1382
SELECT col2 DIV + col0 - - col0 * col2 FROM tab2
----
192
2028
3002

skipif mysql # not compatible
query I rowsort label-1382
SELECT col2 / + col0 - - col0 * col2 FROM tab2
----
192
2028
3002

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

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

query I rowsort
SELECT ALL col0 + ( + 72 ) FROM tab2
----
150
151
79

query I rowsort
SELECT ALL - col2 * col1 * col1 + - tab0.col1 FROM tab0
----
-244154
-679133
-9506

query I rowsort
SELECT ALL col1 * + col2 * - 26 FROM tab1 AS cor0
----
-14820
-32448
-36504

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

query I rowsort
SELECT DISTINCT - + col2 + col0 + 61 FROM tab0 AS cor0
----
52
68
95

query I rowsort
SELECT - col1 * - col1 + col0 AS col1 FROM tab1 AS cor0
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-1391
SELECT col2 * 63 * 65 + cor0.col2 DIV col1 FROM tab0 AS cor0
----
135135
335790
4095

skipif mysql # not compatible
query I rowsort label-1391
SELECT col2 * 63 * 65 + cor0.col2 / col1 FROM tab0 AS cor0
----
135135
335790
4095

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1394
SELECT ALL ( + 84 ) DIV col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1394
SELECT ALL ( + 84 ) / col1 AS col1 FROM tab0
----
0
0
0

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

query I rowsort
SELECT ALL 90 FROM tab2, tab0 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

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

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

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

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

query I rowsort
SELECT - 49 + cor0.col1 FROM tab0 AS cor0
----
37
42
48

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

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

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

query I rowsort
SELECT DISTINCT 88 + - col0 * 38 AS col1 FROM tab1
----
-2344
-26
-2952

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + col1 col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col2 + col1 * + ( + col0 + col0 ) * 27 FROM tab0 AS cor0
----
111489
183331
437428

query I rowsort
SELECT DISTINCT - - col0 + + col0 * - 54 FROM tab2 AS cor0
----
-371
-4134
-4187

onlyif mysql # use DIV operator for integer division
query I rowsort label-1408
SELECT ALL + 20 DIV col1 + - ( + ( tab2.col2 ) * + ( + col2 ) ) + - col0 FROM tab2
----
-1522
-736
-754

skipif mysql # not compatible
query I rowsort label-1408
SELECT ALL + 20 / col1 + - ( + ( tab2.col2 ) * + ( + col2 ) ) + - col0 FROM tab2
----
-1522
-736
-754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 * + col2 col2 FROM tab1 AS cor0
----
3888
4104
6912

query I rowsort
SELECT DISTINCT col1 - cor0.col1 * 57 AS col0 FROM tab2 AS cor0
----
-1736
-3304
-952

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

query I rowsort
SELECT DISTINCT + 22 - + col1 AS col2 FROM tab1 AS cor0
----
-4
12
9

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

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

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

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

query I rowsort
SELECT DISTINCT - + 72 FROM tab2 AS cor0
----
-72

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

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

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

skipif mysql # not compatible
query I rowsort label-1420
SELECT cor0.col0 + CAST ( + 39 AS INTEGER ) FROM tab2 AS cor0
----
117
118
46

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1422
SELECT + col2 * 24 DIV - col1 AS col1 FROM tab0 AS cor0
----
-21
-9
0

skipif mysql # not compatible
query I rowsort label-1422
SELECT + col2 * 24 / - col1 AS col1 FROM tab0 AS cor0
----
-21
-9
0

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

query I rowsort
SELECT col2 + col0 * - col1 - + col1 AS col0 FROM tab2
----
-1322
-221
-4635

query I rowsort
SELECT + + cor0.col0 + + 78 AS col0 FROM tab2 cor0
----
156
157
85

query I rowsort
SELECT - 31 AS col2 FROM tab2, tab2 cor0, tab1 cor1
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

query I rowsort
SELECT + col1 + col1 + col2 AS col0 FROM tab1
----
106
122
77

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

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

query I rowsort
SELECT ALL + ( + 41 ) + - cor0.col2 + - col0 FROM tab0 AS cor0
----
-130
-16
5

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

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

skipif mysql # not compatible
query I rowsort label-1432
SELECT DISTINCT + cor0.col0 / + col0 - + col2 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-1433
SELECT - col0 * 44 - col1 DIV + col0 AS col1 FROM tab1
----
-140
-2816
-3520

skipif mysql # not compatible
query I rowsort label-1433
SELECT - col0 * 44 - col1 / + col0 AS col1 FROM tab1
----
-140
-2816
-3520

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 50 + + col0 * col1 col2 FROM tab1 AS cor0
----
1090
128
690

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

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

skipif mysql # not compatible
query I rowsort label-1437
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 13 * col2 col0 FROM tab2 AS cor0
----
-338
-351
-494

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

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

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

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

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

query I rowsort
SELECT 73 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT + 4 FROM tab1, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 75 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 258bc565c64924d905a55eaaa6e57547

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

query I rowsort
SELECT 15 * - ( col1 ) FROM tab1
----
-150
-195
-390

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

query I rowsort
SELECT + 64 * + col1 + + col2 + - 65 FROM tab1 AS cor0
----
1653
632
863

query I rowsort
SELECT col0 + 57 * + col1 AS col1 FROM tab0 AS cor0
----
4926
5276
5564

query I rowsort
SELECT 17 + - col2 + cor0.col2 AS col2 FROM tab0 AS cor0
----
17
17
17

query I rowsort
SELECT ALL 17 * tab1.col2 AS col2 FROM tab1
----
1632
918
969

query I rowsort
SELECT ALL - 76 * - col1 AS col1 FROM tab0
----
6536
6916
7372

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

skipif mysql # not compatible
query I rowsort label-1456
SELECT + 69 * col1 + CAST ( NULL AS REAL ) FROM tab2
----
NULL
NULL
NULL

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

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

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

query I rowsort
SELECT DISTINCT col1 * - col2 + + ( + col0 ) * - col1 AS col2 FROM tab2 AS cor0
----
-1054
-1989
-6136

query I rowsort
SELECT - + cor0.col1 * col0 * col2 + col1 * col1 * + col2 FROM tab2 cor0
----
-29146
-40052
20088

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 14 * cor0.col0 + - ( col2 ) + - cor0.col1 col2 FROM tab1 cor0
----
-122
-1229
-963

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

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

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

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

query I rowsort
SELECT ALL - col2 * - 31 FROM tab1 AS cor0
----
1674
1767
2976

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

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

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

query I rowsort
SELECT ALL col0 * + col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
1323
158184
237158

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

query I rowsort
SELECT - 2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 20c9213316527d507e26425041e08387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - ( col0 ) + col0 col2 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT - col0 + - ( col0 ) FROM tab2
----
-14
-156
-158

query I rowsort
SELECT col1 + 22 AS col0 FROM tab0 cor0
----
108
113
119

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

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

query I rowsort
SELECT ALL - 4 + col0 FROM tab0 AS cor0
----
20
31
85

query I rowsort
SELECT DISTINCT tab0.col1 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
86
91
97

query I rowsort
SELECT - + col1 + cor0.col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT cor0.col0 * + col1 + col2 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - + ( - cor0.col0 ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + ( col0 ) + - col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT DISTINCT - - col0 * + 20 * - col1 AS col2 FROM tab2 AS cor0
----
-26860
-4340
-92040

query I rowsort
SELECT DISTINCT + 69 AS col1 FROM tab1, tab0 AS cor0
----
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1483
SELECT ALL - CAST( + 72 AS SIGNED ) FROM tab0, tab2 AS cor0
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

skipif mysql # not compatible
query I rowsort label-1483
SELECT ALL - CAST ( + 72 AS INTEGER ) FROM tab0, tab2 AS cor0
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 12 + col2 col1 FROM tab1 AS cor0
----
42
45
84

query I rowsort
SELECT ( - col0 ) * ( + col1 ) + - col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - 4 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT DISTINCT ( - col2 ) * col2 AS col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL - 70 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

query I rowsort
SELECT - col1 + col2 + 48 AS col2 FROM tab0 cor0
----
-48
-5
39

query I rowsort
SELECT tab1.col0 * - tab1.col1 * col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT - + col2 * - col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL 81 + - col1 AS col0 FROM tab0
----
-10
-16
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1493
SELECT DISTINCT + CAST( + 37 AS SIGNED ) + col0 * + col0 AS col0 FROM tab1 AS cor0
----
4133
46
6437

skipif mysql # not compatible
query I rowsort label-1493
SELECT DISTINCT + CAST ( + 37 AS INTEGER ) + col0 * + col0 AS col0 FROM tab1 AS cor0
----
4133
46
6437

query I rowsort
SELECT 21 * - col0 * - col0 + col0 + + col1 * - tab2.col2 AS col0 FROM tab2
----
126308
130494
199

onlyif mysql # use DIV operator for integer division
query I rowsort label-1495
SELECT tab0.col1 DIV - 60 AS col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1495
SELECT tab0.col1 / - 60 AS col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col2 + + 42 AS col2 FROM tab1
----
138
96
99

query I rowsort
SELECT DISTINCT 60 + - col1 AS col2 FROM tab1
----
34
47
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-1498
SELECT ALL ( + 58 ) * col1 + col0 DIV col1 AS col0 FROM tab2 AS cor0
----
1798
3423
990

skipif mysql # not compatible
query I rowsort label-1498
SELECT ALL ( + 58 ) * col1 + col0 / col1 AS col0 FROM tab2 AS cor0
----
1798
3423
990

query I rowsort
SELECT ALL 43 + 8 FROM tab0 cor0
----
51
51
51

query I rowsort
SELECT DISTINCT - ( - col0 ) + col1 * col1 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT ( - 93 ) AS col1 FROM tab1 AS cor0
----
-93

query I rowsort
SELECT - ( 84 ) + + col1 AS col1 FROM tab2 AS cor0
----
-25
-53
-67

query I rowsort
SELECT - - 29 AS col2 FROM tab0 AS cor0
----
29
29
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 33 col1 FROM tab0 AS cor0
----
33

query I rowsort
SELECT + 77 + col2 AS col0 FROM tab0 AS cor0
----
110
159
78

query I rowsort
SELECT ALL + ( + col2 ) * col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT cor0.col2 + + cor0.col2 + col2 FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT DISTINCT + 74 + col0 * + col1 FROM tab2 AS cor0
----
1417
291
4676

query I rowsort
SELECT ALL - cor0.col0 * + col0 - cor0.col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT + col1 + - col1 * col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL - - col2 + col0 * - col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL + 61 + - cor0.col0 * + col2 FROM tab0 AS cor0
----
-7237
-731
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 48 ) + tab0.col2 * + col0 col1 FROM tab0
----
7346
83
840

query I rowsort
SELECT col2 + col1 * col2 + col1 FROM tab0
----
195
2957
7635

query I rowsort
SELECT ALL ( - 31 ) - - tab1.col1 * - tab1.col1 AS col0 FROM tab1
----
-131
-200
-707

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 - + 10 col1 FROM tab0 cor0
----
76
81
87

query I rowsort
SELECT cor0.col2 + + col2 * - col0 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + col0 + + col1 + 96 FROM tab2 AS cor0
----
134
192
233

query I rowsort
SELECT col2 * col2 + - col2 FROM tab2 cor0
----
1406
650
702

query I rowsort
SELECT ALL + col1 - + 23 * + col2 FROM tab2 AS cor0
----
-539
-590
-857

query I rowsort
SELECT DISTINCT + col1 * - col0 + col1 FROM tab1 AS cor0
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * col1 - cor0.col2 col2 FROM tab0 cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-1523
SELECT col0 DIV CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-1523
SELECT col0 / CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT + - col2 * col1 * + col1 FROM tab1 cor0
----
-16224
-36504
-5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-1525
SELECT DISTINCT + col1 + + CAST( 15 AS SIGNED ) DIV col0 AS col0 FROM tab2 AS cor0
----
17
33
59

skipif mysql # not compatible
query I rowsort label-1525
SELECT DISTINCT + col1 + + CAST ( 15 AS INTEGER ) / col0 AS col0 FROM tab2 AS cor0
----
17
33
59

query I rowsort
SELECT col2 * col1 + + col1 AS col0 FROM tab1
----
1261
1430
580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1527
SELECT ALL - col2 * tab2.col2 + - CAST( col1 * col0 AS SIGNED ) AS col2 FROM tab2
----
-2787
-5278
-946

skipif mysql # not compatible
query I rowsort label-1527
SELECT ALL - col2 * tab2.col2 + - CAST ( col1 * col0 AS INTEGER ) AS col2 FROM tab2
----
-2787
-5278
-946

query I rowsort
SELECT - col1 + + col1 * - 13 FROM tab1
----
-140
-182
-364

query I rowsort
SELECT ALL col2 + tab0.col1 + - tab0.col1 AS col2 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col1 col0 FROM tab2, tab0 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - col2 + col2 * - ( ( col2 ) ) AS col1 FROM tab1
----
-2970
-3306
-9312

query I rowsort
SELECT ALL 94 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

skipif mysql # not compatible
query I rowsort
SELECT + col2 * + CAST ( + 70 AS REAL ) AS col2 FROM tab0 AS cor0
----
2310
5740
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1534
SELECT ALL - + cor0.col0 + CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-1534
SELECT ALL - + cor0.col0 + CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL + - col2 * + cor0.col0 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1536
SELECT DISTINCT - + col2 DIV - cor0.col1 AS col0 FROM tab2 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-1536
SELECT DISTINCT - + col2 / - cor0.col1 AS col0 FROM tab2 AS cor0
----
0
2

query I rowsort
SELECT DISTINCT col2 * col0 * - col1 AS col0 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-1538
SELECT ALL + col0 DIV - tab1.col1 col1 FROM tab1
----
-6
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1538
SELECT ALL + col0 / - tab1.col1 col1 FROM tab1
----
-6
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 col0 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL + col2 * + col2 * + col0 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col1 > NULL
----

query I rowsort
SELECT ALL + cor0.col0 + tab0.col2 * cor0.col1 * cor0.col0 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to c69404dd6ef9c4ad947abe6ee9cf445d

query I rowsort
SELECT - + col1 * - col2 * col2 FROM tab1 cor0
----
119808
32490
75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col1 col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col0 * - col2 + col1 * + col1 AS col0 FROM tab0
----
15579
8188
9444

query I rowsort
SELECT ALL - tab0.col0 + - col1 AS col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT - col1 * + col1 AS col0 FROM tab0 cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-1549
SELECT ALL - col1 + col1 DIV col0 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-1549
SELECT ALL - col1 + col1 / col0 FROM tab0 AS cor0
----
-83
-90
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col1 + col1 col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL - - 91 + + cor0.col2 * col0 AS col1 FROM tab1 AS cor0
----
253
3739
7771

onlyif mysql # use DIV operator for integer division
query I rowsort label-1552
SELECT ALL - - col0 * col2 + - col2 DIV col1 FROM tab2 AS cor0
----
189
2028
3000

skipif mysql # not compatible
query I rowsort label-1552
SELECT ALL - - col0 * col2 + - col2 / col1 FROM tab2 AS cor0
----
189
2028
3000

query I rowsort
SELECT - 83 * + col0 + - col0 * col1 FROM tab1 AS cor0
----
-327
-5952
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1554
SELECT ALL - 4 + col1 * + cor0.col2 DIV - col2 FROM tab0 AS cor0
----
-101
-90
-95

skipif mysql # not compatible
query I rowsort label-1554
SELECT ALL - 4 + col1 * + cor0.col2 / - col2 FROM tab0 AS cor0
----
-101
-90
-95

query I rowsort
SELECT DISTINCT - col0 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT col1 * + col0 + + col2 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + - col2 * col2 + col2 + col0 FROM tab2 AS cor0
----
-1327
-572
-695

query I rowsort
SELECT ALL col2 * + col0 + - col1 AS col1 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT ALL - - col1 + cor0.col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + cor0.col0 * + cor0.col1 + + col1 AS col1 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT 22 AS col2 FROM tab1 AS cor0
----
22
22
22

query I rowsort
SELECT - 9 * col1 FROM tab1 AS cor0
----
-117
-234
-90

query I rowsort
SELECT DISTINCT - 21 * - col0 FROM tab2
----
147
1638
1659

query I rowsort
SELECT + ( 24 ) * + col2 AS col1 FROM tab0
----
1968
24
792

query I rowsort
SELECT - + ( + cor0.col0 ) + + col2 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT 21 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1567
SELECT DISTINCT cor0.col0 / CAST( NULL AS SIGNED ) + - col2 * col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1567
SELECT DISTINCT cor0.col0 / CAST ( NULL AS INTEGER ) + - col2 * col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT cor1.col1 - + 81 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-55
-68
-71

query I rowsort
SELECT ALL - tab2.col0 * + col1 AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL ( col2 + col2 ) FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT - ( 9 ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-9

query I rowsort
SELECT ALL 61 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT cor0.col1 * cor0.col0 + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + 90 + + tab0.col1 AS col1 FROM tab0
----
176
181
187

query I rowsort
SELECT ALL + 10 AS col1 FROM tab1
----
10
10
10

query I rowsort
SELECT - col2 + + cor0.col1 * - col1 AS col1 FROM tab2 AS cor0
----
-327
-3507
-988

query I rowsort
SELECT - 6 + 9 FROM tab2 AS cor0
----
3
3
3

query I rowsort
SELECT ALL - 13 * - col2 FROM tab0
----
1066
13
429

query I rowsort
SELECT + ( 58 * col2 ) AS col2 FROM tab1
----
3132
3306
5568

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 2 col0 FROM tab2
----
2

query I rowsort
SELECT DISTINCT 19 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
19

query I rowsort
SELECT ALL + - col1 * - col1 + - col2 AS col2 FROM tab2 cor0
----
251
3455
934

query I rowsort
SELECT ALL + ( - 96 ) * col0 + ( col1 ) * - col1 FROM tab0
----
-12769
-16825
-9700

query I rowsort
SELECT + ( col1 * col2 ) FROM tab1
----
1248
1404
570

query I rowsort
SELECT + + cor0.col0 + - col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + - ( cor0.col0 ) * col0 * col1 FROM tab2 cor0
----
-106097
-1519
-358956

query I rowsort
SELECT tab2.col2 - col0 * 6 AS col2 FROM tab2
----
-15
-436
-442

query I rowsort
SELECT 81 + + col1 AS col1 FROM tab2
----
112
140
98

query I rowsort
SELECT DISTINCT 21 * - col0 AS col2 FROM tab2
----
-147
-1638
-1659

query I rowsort
SELECT DISTINCT + 70 AS col2 FROM tab1
----
70

query I rowsort
SELECT - ( col0 ) * + col1 + - col2 FROM tab1 AS cor0
----
-1136
-132
-697

onlyif mysql # use DIV operator for integer division
query I rowsort label-1592
SELECT col1 DIV - col0 + - col1 FROM tab0 AS cor0
----
-89
-92
-99

skipif mysql # not compatible
query I rowsort label-1592
SELECT col1 / - col0 + - col1 FROM tab0 AS cor0
----
-89
-92
-99

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
3
64
80

query I rowsort
SELECT ALL - col1 - + 96 FROM tab0
----
-182
-187
-193

query I rowsort
SELECT ALL col2 - 30 FROM tab0
----
-29
3
52

query I rowsort
SELECT col1 * - 65 FROM tab2 AS cor0
----
-1105
-2015
-3835

query I rowsort
SELECT col0 * col2 * col1 AS col2 FROM tab1
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 0 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + col1 * - col2 + + col1 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - - 42 + + col1 AS col0 FROM tab1 AS cor0
----
52
55
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-1601
SELECT + cor0.col1 DIV col1 + - col0 AS col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-1601
SELECT + cor0.col1 / col1 + - col0 AS col0 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT ALL - + col2 + - 54 * + col1 AS col0 FROM tab0 AS cor0
----
-4677
-4996
-5239

onlyif mysql # use DIV operator for integer division
query I rowsort label-1603
SELECT ALL - + 33 DIV + col2 AS col1 FROM tab0 cor0
----
-1
-33
0

skipif mysql # not compatible
query I rowsort label-1603
SELECT ALL - + 33 / + col2 AS col1 FROM tab0 cor0
----
-1
-33
0

query I rowsort
SELECT DISTINCT - cor0.col2 + + cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
7363
8199
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-1605
SELECT + ( - cor0.col0 ) DIV col1 FROM tab1 cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-1605
SELECT + ( - cor0.col0 ) / col1 FROM tab1 cor0
----
-6
-6
0

query I rowsort
SELECT - cor0.col2 * + cor0.col0 + col0 AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col2 col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL - 16 * 72 FROM tab1, tab0 AS cor0
----
9 values hashing to 15b8d8db368604ae48543fabf3fda4c7

query I rowsort
SELECT - 28 AS col2 FROM tab0 AS cor0
----
-28
-28
-28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1610
SELECT ALL - CAST( NULL AS SIGNED ) + col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1610
SELECT ALL - CAST ( NULL AS INTEGER ) + col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( col0 ) + col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + 64 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT 28 * 58 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 9f66381084b53c4513467c40170b6859

onlyif mysql # use DIV operator for integer division
query I rowsort label-1614
SELECT DISTINCT cor0.col0 * col1 + - cor0.col0 DIV - col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-1614
SELECT DISTINCT cor0.col0 * col1 + - cor0.col0 / - col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1615
SELECT ALL + - cor0.col2 * - ( + col1 ) - col0 * CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1615
SELECT ALL + - cor0.col2 * - ( + col1 ) - col0 * CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1616
SELECT DISTINCT + + col2 + 74 DIV - 7 FROM tab0 AS cor0
----
-9
23
72

skipif mysql # not compatible
query I rowsort label-1616
SELECT DISTINCT + + col2 + 74 / - 7 FROM tab0 AS cor0
----
-9
23
72

query I rowsort
SELECT - cor2.col0 * - cor1.col0 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 04f88c53da1ccbc3b901792896e5cdd4

query I rowsort
SELECT col1 + - col0 * 27 FROM tab0 AS cor0
----
-2312
-562
-848

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1619
SELECT ALL CAST( NULL AS SIGNED ) + - 79 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-1619
SELECT ALL CAST ( NULL AS INTEGER ) + - 79 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 47 AS col2 FROM tab2 AS cor0
----
-47

query I rowsort
SELECT - - 59 * 96 AS col2 FROM tab0 AS cor0
----
5664
5664
5664

query I rowsort
SELECT + 70 + + col1 * col1 FROM tab1 cor0
----
170
239
746

query I rowsort
SELECT DISTINCT + + col1 * - col2 AS col1 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1624
SELECT ALL + ( 73 ) * col2 + - col1 + 74 DIV - col2 FROM tab0 AS cor0
----
-98
2321
5895

skipif mysql # not compatible
query I rowsort label-1624
SELECT ALL + ( 73 ) * col2 + - col1 + 74 / - col2 FROM tab0 AS cor0
----
-98
2321
5895

query I rowsort
SELECT + col1 + - ( col0 ) FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + ( 14 ) FROM tab0 AS cor0
----
14

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col1 AS REAL ) + col2 * - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1628
SELECT DISTINCT + ( + 37 ) DIV - col0 FROM tab1 AS cor0
----
-12
0

skipif mysql # not compatible
query I rowsort label-1628
SELECT DISTINCT + ( + 37 ) / - col0 FROM tab1 AS cor0
----
-12
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1629
SELECT + ( col2 ) + + col1 DIV - col1 AS col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-1629
SELECT + ( col2 ) + + col1 / - col1 AS col0 FROM tab0 AS cor0
----
0
32
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-1630
SELECT DISTINCT - cor0.col0 DIV col1 + col1 * ( col1 + col2 ) * - ( + col0 ) FROM tab0 cor0
----
-1401127
-245616
-332710

skipif mysql # not compatible
query I rowsort label-1630
SELECT DISTINCT - cor0.col0 / col1 + col1 * ( col1 + col2 ) * - ( + col0 ) FROM tab0 cor0
----
-1401127
-245616
-332710

query I rowsort
SELECT DISTINCT - 13 + + col2 AS col1 FROM tab0 AS cor0
----
-12
20
69

query I rowsort
SELECT ALL + col0 + + cor0.col0 * + cor0.col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL + col0 + - col0 * col2 AS col1 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - col1 + + col1 AS col2 FROM tab0 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 83 col0 FROM tab0 cor0
----
83
83
83

query I rowsort
SELECT DISTINCT 48 * col1 + + ( col2 ) FROM tab2 AS cor0
----
1515
2858
854

query I rowsort
SELECT ALL + 25 * col1 - + 42 FROM tab0 AS cor0
----
2108
2233
2383

query I rowsort
SELECT 16 * - col0 + col2 AS col0 FROM tab2 AS cor0
----
-1222
-1226
-85

query I rowsort
SELECT ALL col0 + cor0.col0 * ( + col2 ) FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + 69 * + col0 AS col1 FROM tab2 AS cor0
----
483
5382
5451

query I rowsort
SELECT DISTINCT 32 * - col0 FROM tab2 AS cor0
----
-224
-2496
-2528

query I rowsort
SELECT ALL ( col2 ) * - col2 * + col0 FROM tab2
----
-114076
-5103
-52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + col2 + col2 * col2 * + cor0.col2 - col2 * - col2 col2 FROM tab0 AS cor0
----
39864
565554
99

query I rowsort
SELECT DISTINCT + - 51 AS col1 FROM tab1 cor0
----
-51

query I rowsort
SELECT 14 + + cor0.col1 FROM tab2 AS cor0
----
31
45
73

query I rowsort
SELECT ALL - + 58 * - col2 + + 1 FROM tab1 AS cor0
----
3133
3307
5569

query I rowsort
SELECT + col1 * - cor0.col2 + + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT 61 + col0 * col2 * col0 AS col1 FROM tab2 AS cor0
----
1384
158245
237219

query I rowsort
SELECT 25 * - col1 + + 60 AS col2 FROM tab1 AS cor0
----
-190
-265
-590

query I rowsort
SELECT ALL + cor0.col1 * + col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT + 46 + col0 AS col1 FROM tab2 AS cor0
----
124
125
53

query I rowsort
SELECT 87 + 20 FROM tab1, tab0 cor0
----
9 values hashing to 6f26a03989006af44e1b70d584e50047

query I rowsort
SELECT + 9 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT ALL + ( 80 ) FROM tab0, tab1 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT ALL + col1 * - col1 + + col1 AS col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT - - col1 + + 15 FROM tab2 AS cor0
----
32
46
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-1657
SELECT DISTINCT + + col2 + 88 DIV col1 AS col2 FROM tab2 cor0
----
27
29
43

skipif mysql # not compatible
query I rowsort label-1657
SELECT DISTINCT + + col2 + 88 / col1 AS col2 FROM tab2 cor0
----
27
29
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + col0 col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL col2 * col2 * col1 + col2 * + col2 AS col1 FROM tab1 cor0
----
129024
35739
78732

query I rowsort
SELECT 25 * - col2 * - col2 + - col0 FROM tab1
----
230320
72897
81161

onlyif mysql # use DIV operator for integer division
query I rowsort label-1661
SELECT + col0 DIV + col2 + + col1 AS col2 FROM tab1
----
11
13
26

skipif mysql # not compatible
query I rowsort label-1661
SELECT + col0 / + col2 + + col1 AS col2 FROM tab1
----
11
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col1 * + col2 * col1 col1 FROM tab0 AS cor0
----
244101
679124
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-1663
SELECT + ( + col2 ) + - tab0.col0 DIV - col2 AS col1 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-1663
SELECT + ( + col2 ) + - tab0.col0 / - col2 AS col1 FROM tab0
----
33
36
83

query I rowsort
SELECT DISTINCT - col1 + col2 + - col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL col2 * - ( col1 * + col1 ) FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL + col0 * - 39 * + col0 FROM tab2 AS cor0
----
-1911
-237276
-243399

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * 86 + col2 + 78 col2 FROM tab1
----
4776
5037
8430

query I rowsort
SELECT - 91 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

query I rowsort
SELECT + + 63 + col1 FROM tab0 cor0
----
149
154
160

query I rowsort
SELECT DISTINCT 83 FROM tab0, tab2 AS cor0
----
83

query I rowsort
SELECT + 18 * col0 * + col1 + - 38 FROM tab0 AS cor0
----
145744
37114
61072

query I rowsort
SELECT DISTINCT - + cor0.col0 * - col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col2 + col2 * + 82 FROM tab1 AS cor0
----
4482
4731
7968

query I rowsort
SELECT + - 11 FROM tab0 AS cor0
----
-11
-11
-11

onlyif mysql # use DIV operator for integer division
query I rowsort label-1675
SELECT col0 DIV - tab0.col2 + + ( 25 ) + col0 * 71 FROM tab0
----
1729
2475
6343

skipif mysql # not compatible
query I rowsort label-1675
SELECT col0 / - tab0.col2 + + ( 25 ) + col0 * 71 FROM tab0
----
1729
2475
6343

query I rowsort
SELECT DISTINCT + col1 + col0 + tab2.col1 FROM tab2
----
113
196
69

query I rowsort
SELECT col0 + col2 * col1 AS col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL - cor0.col2 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT - - col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT col0 + + col0 * - col1 + ( col0 + - col0 ) AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL + 81 * - col0 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-297
-5241
-6576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col0 col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL + 14 AS col1 FROM tab2 AS cor0
----
14
14
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-1684
SELECT - cor0.col0 DIV 69 FROM tab1, tab2 AS cor0
----
9 values hashing to b2e225572af74ba853e10fb5414ea67f

skipif mysql # not compatible
query I rowsort label-1684
SELECT - cor0.col0 / 69 FROM tab1, tab2 AS cor0
----
9 values hashing to b2e225572af74ba853e10fb5414ea67f

query I rowsort
SELECT col0 * - col2 + tab1.col0 AS col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT ALL tab0.col0 * - tab0.col1 AS col0 FROM tab0 WHERE NOT NULL IN ( col1 * - col2 )
----

query I rowsort
SELECT - tab1.col2 - + col0 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT - tab0.col0 * tab0.col1 * + tab0.col0 + tab0.col0 AS col1 FROM tab0
----
-118790
-49512
-720722

query I rowsort
SELECT DISTINCT + col1 * + col2 + - tab1.col0 * col1 FROM tab1
----
-70
1326
208

query I rowsort
SELECT ALL col1 FROM tab1 WHERE ( NULL ) = ( NULL )
----

query I rowsort
SELECT - col1 + - tab0.col0 * tab0.col0 + + col2 * col1 * - col2 AS col1 FROM tab0
----
-1419
-619896
-94316

query I rowsort
SELECT - tab2.col2 * tab2.col1 + col1 + col2 AS col0 FROM tab2
----
-1449
-591
-779

onlyif mysql # use DIV operator for integer division
query I rowsort label-1693
SELECT DISTINCT col2 * col0 + col2 + col0 DIV col1 AS col0 FROM tab1
----
216
3711
7782

skipif mysql # not compatible
query I rowsort label-1693
SELECT DISTINCT col2 * col0 + col2 + col0 / col1 AS col0 FROM tab1
----
216
3711
7782

query I rowsort
SELECT + col2 * + col1 * - col2 + col0 - col0 FROM tab2
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-1695
SELECT - 49 + + col1 + + CAST( - 32 AS SIGNED ) DIV col0 FROM tab0 AS cor0
----
36
42
48

skipif mysql # not compatible
query I rowsort label-1695
SELECT - 49 + + col1 + + CAST ( - 32 AS INTEGER ) / col0 FROM tab0 AS cor0
----
36
42
48

query I rowsort
SELECT DISTINCT + - 6 + col1 AS col2 FROM tab0 cor0
----
80
85
91

query I rowsort
SELECT - + 50 AS col1 FROM tab1 AS cor0
----
-50
-50
-50

query I rowsort
SELECT - tab2.col2 - + col2 FROM tab2
----
-52
-54
-76

query I rowsort
SELECT - col1 - + col0 * + col2 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT + col2 * + col0 + - col1 AS col0 FROM tab2
----
158
1969
2985

query I rowsort
SELECT - col1 * col1 * col2 FROM tab2 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT ALL - col1 + + col2 * + col0 FROM tab1 WHERE ( + col2 ) IN ( + col2 * + tab1.col1 )
----

query I rowsort
SELECT DISTINCT col1 * + col0 / col0 FROM tab2 AS cor0 WHERE NULL IN ( + col1 * - col2 + col2 + + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1704
SELECT DISTINCT col2 + col1 DIV col1 + + tab0.col2 FROM tab0
----
165
3
67

skipif mysql # not compatible
query I rowsort label-1704
SELECT DISTINCT col2 + col1 / col1 + + tab0.col2 FROM tab0
----
165
3
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 * tab2.col2 col0 FROM tab2 WHERE NOT ( NULL ) NOT IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1706
SELECT - col0 - + col1 DIV + col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-1706
SELECT - col0 - + col1 / + col2 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1707
SELECT tab0.col1 DIV + tab0.col0 AS col1 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1707
SELECT tab0.col1 / + tab0.col0 AS col1 FROM tab0
----
1
2
3

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT ( NULL ) NOT IN ( col0 - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1709
SELECT ALL col2 + col0 DIV col1 FROM tab2
----
27
27
42

skipif mysql # not compatible
query I rowsort label-1709
SELECT ALL col2 + col0 / col1 FROM tab2
----
27
27
42

query III rowsort
SELECT * FROM tab1 WHERE ( col2 ) > ( NULL )
----

query I rowsort
SELECT DISTINCT - col1 * col1 + col1 AS col1 FROM tab2
----
-272
-3422
-930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 * col1 col0 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT DISTINCT - col1 * col0 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - col2 * + tab2.col0 + - col2 FROM tab2
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT + tab1.col1 + + col0 FROM tab1 WHERE NULL = NULL
----

query I rowsort
SELECT col2 * - col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT col0 * col1 FROM tab2 AS cor0 WHERE - col1 - + col0 * - col1 IN ( col1 )
----

query I rowsort
SELECT ALL col0 * - col0 * col2 + col0 * - col1 * col0 FROM tab2
----
-2842
-343255
-517140

query I rowsort
SELECT DISTINCT col0 * col2 + col2 * col2 FROM tab0
----
14022
1881
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-1720
SELECT - col1 DIV col2 + tab0.col1 FROM tab0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-1720
SELECT - col1 / col2 + tab0.col1 FROM tab0
----
0
84
90

query I rowsort
SELECT DISTINCT col2 * ( cor0.col0 ) + + 29 FROM tab1 AS cor0
----
191
3677
7709

onlyif mysql # use DIV operator for integer division
query I rowsort label-1722
SELECT - 48 DIV cor2.col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

skipif mysql # not compatible
query I rowsort label-1722
SELECT - 48 / cor2.col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

query I rowsort
SELECT ALL col2 * ( - col1 + + col2 ) AS col0 FROM tab2
----
-108
-858
798

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 cor0, tab0 AS cor1, tab2, tab2 cor2
----
3645 values hashing to f8426cd4d01ba96a72d7348574fbbc8e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1725
SELECT DISTINCT + - CAST( - col2 AS SIGNED ) + + col0 + - ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1725
SELECT DISTINCT + - CAST ( - col2 AS INTEGER ) + + col0 + - ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + - 51 - + cor0.col0 AS col2 FROM tab0 AS cor0
----
-140
-75
-86

query I rowsort
SELECT - 81 * - col2 + col1 * 54 FROM tab1 AS cor0
----
5157
5778
8478

query I rowsort
SELECT DISTINCT + col0 + + 46 AS col1 FROM tab2 AS cor0
----
124
125
53

query I rowsort
SELECT + 70 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT ALL + ( - tab1.col0 ) + - col2 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT DISTINCT col2 + - tab2.col2 AS col1 FROM tab2
----
0

query I rowsort
SELECT - + ( + col2 ) + + col2 * + cor0.col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT + + cor0.col2 + + col2 + col0 FROM tab2 AS cor0
----
130
155
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1734
SELECT - ( col0 * + CAST( 54 AS SIGNED ) ) FROM tab0
----
-1296
-1890
-4806

skipif mysql # not compatible
query I rowsort label-1734
SELECT - ( col0 * + CAST ( 54 AS INTEGER ) ) FROM tab0
----
-1296
-1890
-4806

query I rowsort
SELECT DISTINCT ( col1 ) * ( tab2.col0 ) AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT + 41 * col1 AS col0 FROM tab1
----
1066
410
533

query I rowsort
SELECT - col0 * col2 * 1 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - col0 * 57 AS col2 FROM tab1 AS cor0
----
-171
-3648
-4560

query I rowsort
SELECT col2 * col0 + tab0.col1 + col1 * - ( col2 * + col0 ) FROM tab0
----
-3263
-656729
-67234

query I rowsort
SELECT - - col1 + + col0 * + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-1741
SELECT + col0 DIV - 65 AS col2 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1741
SELECT + col0 / - 65 AS col2 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - - cor0.col0 * 61 AS col2 FROM tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT ALL + col1 * col1 + 19 FROM tab2 AS cor0
----
308
3500
980

query I rowsort
SELECT DISTINCT col0 + 51 * - 95 * col0 AS col0 FROM tab0 cor0
----
-116256
-169540
-431116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 col2 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-1746
SELECT - col0 DIV + col0 AS col1 FROM tab2 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1746
SELECT - col0 / + col0 AS col1 FROM tab2 cor0
----
-1
-1
-1

query I rowsort
SELECT 47 FROM tab2, tab1 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 5c7a6f591fb2a38893dafe56c4b9b97f

query I rowsort
SELECT DISTINCT ( + col2 ) + - col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL + + 62 AS col1 FROM tab0 AS cor0
----
62
62
62

query I rowsort
SELECT + + col1 * col1 AS col2 FROM tab0 cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 93 * col2 col1 FROM tab0
----
-3069
-7626
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1752
SELECT DISTINCT col2 + col0 DIV col1 FROM tab1
----
102
54
63

skipif mysql # not compatible
query I rowsort label-1752
SELECT DISTINCT col2 + col0 / col1 FROM tab1
----
102
54
63

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 7e12d99d8ab63d9fd10e95cef9d78998

query I rowsort
SELECT ALL - tab2.col0 * col1 * + ( ( col2 ) ) FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - cor0.col0 * + 63 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to e98d72559b8b24c59a844d803a968582

query I rowsort
SELECT DISTINCT 71 + col2 AS col2 FROM tab0 AS cor0
----
104
153
72

query I rowsort
SELECT DISTINCT col0 * - col0 AS col1 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + 89 AS col2 FROM tab2 AS cor0
----
89

query I rowsort
SELECT - cor0.col2 + col2 * - col1 FROM tab2 AS cor0
----
-1560
-684
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 - + col2 * + col0 col2 FROM tab0 AS cor0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + 32 ) col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
32

query I rowsort
SELECT ALL 98 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT - 86 + + col2 AS col1 FROM tab1 cor0
----
-29
-32
10

query I rowsort
SELECT ALL - col0 + col0 * col0 * + col1 FROM tab2
----
106018
1512
358878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + 88 * col2 col1 FROM tab2
----
2210
2369
3265

query I rowsort
SELECT ALL col2 * 56 * col2 - + col1 FROM tab2
----
37797
40793
80847

query I rowsort
SELECT ALL - 69 FROM tab0, tab0 cor0
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1768
SELECT + cor0.col2 * col2 DIV col2 AS col1 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1768
SELECT + cor0.col2 * col2 / col2 AS col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL + col1 * cor0.col1 + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL col2 + + 8 * cor0.col1 * - col0 AS col0 FROM tab1 AS cor0
----
-5063
-570
-8224

query I rowsort
SELECT - col1 + + 35 FROM tab1 AS cor0
----
22
25
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1772
SELECT + - 94 DIV 97 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1772
SELECT + - 94 / 97 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - ( col1 ) * col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - 98 * col1 FROM tab1 AS cor0
----
-1274
-2548
-980

query I rowsort
SELECT ALL + 97 * 42 AS col1 FROM tab0 AS cor0
----
4074
4074
4074

query I rowsort
SELECT col1 * + 8 + col0 AS col0 FROM tab0 AS cor0
----
712
811
817

query I rowsort
SELECT ALL - + cor0.col2 + - cor0.col2 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT ALL + 2 AS col1 FROM tab1, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 6d1be3904d6870ba21bc766b979d1110

query I rowsort
SELECT ALL - 29 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
81 values hashing to eb8b36589592eb8217153525a5c8d606

query I rowsort
SELECT DISTINCT - ( 48 ) FROM tab1 AS cor0
----
-48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1781
SELECT + CAST( NULL AS SIGNED ) / col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1781
SELECT + CAST ( NULL AS INTEGER ) / col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 42 * ( + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT - - col1 * col0 + - col2 - - 69 * + col1 AS col0 FROM tab1 AS cor0
----
1273
1818
1841

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 + col1 + col2 col1 FROM tab2
----
-131
-1943
-2947

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col0 col2 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col0 ) col1 FROM tab2 cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col1 * col0 col0 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT + 38 * - 13 + col1 * + 30 AS col1 FROM tab2 AS cor0
----
1276
16
436

query I rowsort
SELECT ALL ( col2 ) * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - - ( + col2 ) * col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT cor0.col2 + + col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT ( col0 + col0 ) AS col0 FROM tab2
----
14
156
158

query I rowsort
SELECT + col1 + 25 * col1 AS col1 FROM tab2 AS cor0
----
1534
442
806

query I rowsort
SELECT - col0 + 13 FROM tab2 AS cor0
----
-65
-66
6

query I rowsort
SELECT DISTINCT 84 * - col1 FROM tab0 cor0
----
-7224
-7644
-8148

query I rowsort
SELECT + - 35 + col0 FROM tab1 AS cor0
----
-32
29
45

query I rowsort
SELECT cor0.col0 * - col0 + - cor0.col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT DISTINCT + 34 * - col2 + - col0 * col0 FROM tab2
----
-6968
-7533
-967

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) col1 FROM tab0
----
86
91
97

query I rowsort
SELECT 36 * + col1 FROM tab1
----
360
468
936

query I rowsort
SELECT + col1 * + tab1.col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL tab1.col0 + col0 + + col0 FROM tab1
----
192
240
9

query I rowsort
SELECT DISTINCT - col2 + - col0 + - col1 AS col1 FROM tab0 AS cor0
----
-133
-143
-262

query I rowsort
SELECT DISTINCT + - col1 + col0 + col2 AS col2 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT DISTINCT + + cor0.col2 + + ( col0 * col0 + cor0.col1 * + col2 ) AS col1 FROM tab1 AS cor0
----
1467
4723
7744

query I rowsort
SELECT - cor0.col1 + 80 FROM tab0 AS cor0
----
-11
-17
-6

query I rowsort
SELECT DISTINCT cor0.col2 * - ( + col0 ) + col1 AS col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT + + col2 * cor0.col2 + - col2 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - + col1 + col0 AS col1 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1810
SELECT - col2 DIV - col0 + - 84 AS col2 FROM tab0
----
-83
-84
-84

skipif mysql # not compatible
query I rowsort label-1810
SELECT - col2 / - col0 + - 84 AS col2 FROM tab0
----
-83
-84
-84

query I rowsort
SELECT cor0.col2 + ( - col0 ) * + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT + - col1 + + ( - col1 ) FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT ALL tab0.col0 * - col1 + col2 * - col2 FROM tab0
----
-14823
-3153
-3396

query I rowsort
SELECT - - col1 * - 63 + + col2 * ( 88 ) FROM tab2 AS cor0
----
-1429
2273
423

query I rowsort
SELECT + col1 + + 52 + 76 FROM tab1
----
138
141
154

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 cor1, tab2 AS cor2
----
972 values hashing to caf6adb9936510208f5945a7e5c76f14

query I rowsort
SELECT DISTINCT + 19 FROM tab0, tab2 AS cor0
----
19

query I rowsort
SELECT DISTINCT + cor0.col2 - - col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT 14 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) * 72 * col1 col0 FROM tab1
----
46080
5616
74880

query I rowsort
SELECT 57 * col1 FROM tab0
----
4902
5187
5529

query I rowsort
SELECT DISTINCT + tab0.col1 * col0 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-1823
SELECT 92 DIV + col1 AS col2 FROM tab1
----
3
7
9

skipif mysql # not compatible
query I rowsort label-1823
SELECT 92 / + col1 AS col2 FROM tab1
----
3
7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1824
SELECT ALL + col2 + + ( + col0 ) DIV - col0 AS col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-1824
SELECT ALL + col2 + + ( + col0 ) / - col0 AS col0 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT - 29 AS col2 FROM tab0
----
-29
-29
-29

query I rowsort
SELECT - 80 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 26dbcc98d4b4e864ffa31be685a5dfbd

query I rowsort
SELECT - col0 + - col0 * + col1 AS col2 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT - col0 * + col2 * - col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT ( - col2 ) * - 83 FROM tab2
----
2158
2241
3154

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col0 * 18 col2 FROM tab2 AS cor0
----
-3402
-36504
-54036

query I rowsort
SELECT + - cor0.col1 AS col2 FROM tab2, tab1 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT + + col0 * 44 + - ( - col1 ) * col2 AS col2 FROM tab2 AS cor0
----
1145
4122
4966

query I rowsort
SELECT col2 + + 67 FROM tab0 AS cor0
----
100
149
68

query I rowsort
SELECT cor0.col2 * cor0.col1 + col1 * - col0 * col1 FROM tab0 AS cor0
----
-174666
-329218
-729547

query I rowsort
SELECT ALL ( - 34 ) AS col1 FROM tab1
----
-34
-34
-34

query I rowsort
SELECT 66 FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
81 values hashing to dc112f70fecc29a6e605a39541192f43

query I rowsort
SELECT + 36 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT - + 47 AS col1 FROM tab0 cor0
----
-47
-47
-47

query I rowsort
SELECT + 29 * + col2 * + col1 FROM tab1 AS cor0
----
16530
36192
40716

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1840
SELECT ALL - CAST( + col2 AS SIGNED ) + cor0.col0 * col0 col1 FROM tab2 AS cor0
----
22
6058
6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1840
SELECT ALL - CAST ( + col2 AS INTEGER ) + cor0.col0 * col0 col1 FROM tab2 AS cor0
----
22
6058
6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col0 col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - 96 * - col1 - col2 FROM tab0 AS cor0
----
8223
8654
9311

onlyif mysql # use DIV operator for integer division
query I rowsort label-1843
SELECT col0 + - col1 DIV col1 AS col1 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-1843
SELECT col0 + - col1 / col1 AS col1 FROM tab2 AS cor0
----
6
77
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1844
SELECT col0 DIV col1 AS col0 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-1844
SELECT col0 / col1 AS col0 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT DISTINCT + col1 + col2 * ( - 79 ) * col0 FROM tab2 AS cor0
----
-14900
-160153
-237141

query I rowsort
SELECT ALL - 66 * + col0 + col2 AS col0 FROM tab0 AS cor0
----
-1551
-2309
-5792

query I rowsort
SELECT + - 50 + cor0.col2 AS col2 FROM tab1 AS cor0
----
4
46
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1848
SELECT DISTINCT - 28 DIV col0 + - CAST( ( - cor0.col0 ) AS SIGNED ) AS col1 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-1848
SELECT DISTINCT - 28 / col0 + - CAST ( ( - cor0.col0 ) AS INTEGER ) AS col1 FROM tab0 AS cor0
----
23
35
89

query I rowsort
SELECT ALL col0 * cor0.col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1850
SELECT DISTINCT - + cor0.col0 + cor0.col0 * col1 + cor0.col1 DIV + cor0.col2 AS col1 FROM tab1 cor0
----
576
75
960

skipif mysql # not compatible
query I rowsort label-1850
SELECT DISTINCT - + cor0.col0 + cor0.col0 * col1 + cor0.col1 / + cor0.col2 AS col1 FROM tab1 cor0
----
576
75
960

query I rowsort
SELECT - ( + cor0.col2 ) * + 69 FROM tab0 AS cor0
----
-2277
-5658
-69

query I rowsort
SELECT ALL cor0.col0 + + col2 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-1853
SELECT ALL - col1 DIV col1 + 89 + cor0.col1 FROM tab0 cor0
----
174
179
185

skipif mysql # not compatible
query I rowsort label-1853
SELECT ALL - col1 / col1 + 89 + cor0.col1 FROM tab0 cor0
----
174
179
185

query I rowsort
SELECT DISTINCT 87 * + col0 + 63 * + col2 AS col1 FROM tab0 AS cor0
----
12909
3108
4167

query I rowsort
SELECT - cor0.col1 + - 82 + col2 FROM tab0 AS cor0
----
-135
-178
-91

query I rowsort
SELECT + 2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT ALL - col1 + 1 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT - col1 * + col2 + + 99 AS col0 FROM tab1 cor0
----
-1149
-1305
-471

query I rowsort
SELECT DISTINCT - col2 * ( + 43 ) * col1 AS col0 FROM tab0 AS cor0
----
-122034
-320866
-4171

query I rowsort
SELECT + 64 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT - col0 * - col2 + + col0 AS col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL - 23 * cor0.col2 + - col2 FROM tab1 AS cor0
----
-1296
-1368
-2304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + cor0.col0 col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - + ( 9 ) * col2 AS col2 FROM tab0 AS cor0
----
-297
-738
-9

query I rowsort
SELECT - 68 + + col2 AS col2 FROM tab1
----
-11
-14
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-1866
SELECT - col0 + col1 DIV col0 AS col2 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-1866
SELECT - col0 + col1 / col0 AS col2 FROM tab1 AS cor0
----
-64
-80
5

query I rowsort
SELECT col0 * 6 FROM tab0 AS cor0
----
144
210
534

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col2 ) col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + 51 AS REAL ) FROM tab0
----
-51
-51
-51

query I rowsort
SELECT col1 + - col0 * - col0 FROM tab2
----
6143
6258
80

query I rowsort
SELECT ALL col0 * ( cor0.col0 ) + col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT + col2 - - col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL col0 + - col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col0 - - col0 * - col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT ALL - 66 FROM tab0, tab0 AS cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT ALL col0 + ( + col2 ) * - col1 * ( ( col0 ) ) AS col2 FROM tab0
----
-3360
-664029
-68088

query I rowsort
SELECT col2 + + 82 + + col1 AS col2 FROM tab0
----
180
201
255

onlyif mysql # use DIV operator for integer division
query I rowsort label-1878
SELECT DISTINCT - + col0 DIV 48 + + col2 FROM tab0 AS cor0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-1878
SELECT DISTINCT - + col0 / 48 + + col2 FROM tab0 AS cor0
----
1
33
81

query I rowsort
SELECT - - 17 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT DISTINCT + cor0.col0 * - ( - 90 ) AS col1 FROM tab2 AS cor0
----
630
7020
7110

query I rowsort
SELECT ALL + tab2.col0 + - col2 FROM tab2
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 * col1 col0 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT - + cor0.col1 FROM tab1, tab0, tab0 AS cor0, tab2
----
-86
-91
-97

query I rowsort
SELECT + 28 AS col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

query I rowsort
SELECT + 40 - + 7 FROM tab1
----
33
33
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 16 - col0 col0 FROM tab1 AS cor0
----
-48
-64
13

query I rowsort
SELECT col1 + + col1 * 12 FROM tab1 AS cor0
----
130
169
338

query I rowsort
SELECT DISTINCT + col0 * col2 + 78 * - 67 * + col1 AS col2 FROM tab0 AS cor0
----
-448644
-468268
-506887

query I rowsort
SELECT - + col2 * + col2 * 6 AS col1 FROM tab2 AS cor0
----
-4056
-4374
-8664

query I rowsort
SELECT ALL + col1 * - col2 * col2 FROM tab0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - 43 col2 FROM tab1
----
-100
-139
-97

query I rowsort
SELECT ALL col0 * - tab1.col1 AS col2 FROM tab1
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1893
SELECT - - 48 * col2 - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1893
SELECT - - 48 * col2 - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 - col1 AS col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT ALL ( - col1 ) + 39 FROM tab1
----
13
26
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1896
SELECT + col1 * + col2 + + col1 * - ( + col1 ) + - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1896
SELECT + col1 * + col2 + + col1 * - ( + col1 ) + - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 17 * col0 + cor0.col1 + col2 FROM tab1 AS cor0
----
1155
131
1469

query I rowsort
SELECT + 19 * col2 * col0 FROM tab2 AS cor0
----
3591
38532
57038

query I rowsort
SELECT + cor0.col2 - + col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 55 * col2 + - col0 * col2 AS col2 FROM tab2 AS cor0
----
-598
-912
1296

query I rowsort
SELECT - col0 * col0 - + col2 * + col0 FROM tab0 AS cor0
----
-1260
-1368
-15219

query I rowsort
SELECT ALL - + col1 * - cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + ( col1 ) + + col2 + col1 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT tab1.col1 * - 33 FROM tab1, tab2 AS cor0
----
9 values hashing to bcb5016983759dc54f253fcc5835d0ad

onlyif mysql # use DIV operator for integer division
query I rowsort label-1905
SELECT DISTINCT col1 DIV - col1 + + col0 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-1905
SELECT DISTINCT col1 / - col1 + + col0 FROM tab2
----
6
77
78

query I rowsort
SELECT DISTINCT col0 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-2
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 12 * - col2 col1 FROM tab0 AS cor0
----
-12
-396
-984

onlyif mysql # use DIV operator for integer division
query I rowsort label-1908
SELECT ALL cor0.col1 DIV col0 + - 90 AS col1 FROM tab1 AS cor0
----
-82
-90
-90

skipif mysql # not compatible
query I rowsort label-1908
SELECT ALL cor0.col1 / col0 + - 90 AS col1 FROM tab1 AS cor0
----
-82
-90
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1909
SELECT DISTINCT + ( + col1 ) DIV - col2 AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-1909
SELECT DISTINCT + ( + col1 ) / - col2 AS col2 FROM tab1
----
0

query I rowsort
SELECT ALL - - col2 * - ( col0 ) * col0 AS col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT col0 * - 83 + - 93 * col0 * + col1 FROM tab1 AS cor0
----
-103360
-64832
-7503

query I rowsort
SELECT col1 + 50 FROM tab2 AS cor0
----
109
67
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1913
SELECT CAST( NULL AS SIGNED ) * 61 FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1913
SELECT CAST ( NULL AS INTEGER ) * 61 FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT col2 + + col1 - col0 AS col0 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT ALL + col0 + + col2 * col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + col1 * - 86 + 80 FROM tab2 AS cor0
----
-1382
-2586
-4994

query I rowsort
SELECT + + col0 * col2 + + cor0.col0 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-1918
SELECT col1 * col2 + ( - cor0.col0 ) + CAST( - col0 + - col0 AS SIGNED ) DIV ( col0 ) FROM tab0 AS cor0
----
2812
60
7371

skipif mysql # not compatible
query I rowsort label-1918
SELECT col1 * col2 + ( - cor0.col0 ) + CAST ( - col0 + - col0 AS INTEGER ) / ( col0 ) FROM tab0 AS cor0
----
2812
60
7371

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + ( 83 ) + + col1 col2 FROM tab1 AS cor0
----
150
163
192

query I rowsort
SELECT col1 + + col2 - + col2 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL ( 52 ) + col1 AS col1 FROM tab2 AS cor0
----
111
69
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1922
SELECT + 67 DIV col0 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1922
SELECT + 67 / col0 FROM tab0 AS cor0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * col0 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - ( col1 ) AS col2 FROM tab2 cor0
----
-17
-31
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1925
SELECT ALL - + ( - 22 ) + + col1 / - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1925
SELECT ALL - + ( - 22 ) + + col1 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 col0 FROM tab2
----
26
26
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1927
SELECT DISTINCT - ( - col2 ) DIV + col0 AS col2 FROM tab2
----
0
3

skipif mysql # not compatible
query I rowsort label-1927
SELECT DISTINCT - ( - col2 ) / + col0 AS col2 FROM tab2
----
0
3

query I rowsort
SELECT ALL ( - 93 ) * col0 - col0 FROM tab1 AS cor0
----
-282
-6016
-7520

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( 18 AS REAL ) FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + col1 * + cor0.col2 + col1 FROM tab2 cor0
----
1593
663
868

query I rowsort
SELECT ALL - - col1 + 0 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1932
SELECT DISTINCT 0 DIV col2 + - col2 * 30 FROM tab0 cor0
----
-2460
-30
-990

skipif mysql # not compatible
query I rowsort label-1932
SELECT DISTINCT 0 / col2 + - col2 * 30 FROM tab0 cor0
----
-2460
-30
-990

query I rowsort
SELECT DISTINCT - ( col0 ) * - cor0.col2 - - 31 AS col1 FROM tab1 AS cor0
----
193
3679
7711

query I rowsort
SELECT - 98 * 45 FROM tab0 AS cor0
----
-4410
-4410
-4410

query I rowsort
SELECT ALL ( 48 ) FROM tab2 AS cor0
----
48
48
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-1936
SELECT ALL + 24 + + 26 DIV + col1 FROM tab0 AS cor0
----
24
24
24

skipif mysql # not compatible
query I rowsort label-1936
SELECT ALL + 24 + + 26 / + col1 FROM tab0 AS cor0
----
24
24
24

query I rowsort
SELECT - ( - cor0.col0 ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

onlyif mysql # use DIV operator for integer division
query I rowsort label-1938
SELECT ALL 8 * - cor0.col0 DIV col0 FROM tab0 AS cor0
----
-8
-8
-8

skipif mysql # not compatible
query I rowsort label-1938
SELECT ALL 8 * - cor0.col0 / col0 FROM tab0 AS cor0
----
-8
-8
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1939
SELECT + CAST( + 91 AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
2366
2457
3458

skipif mysql # not compatible
query I rowsort label-1939
SELECT + CAST ( + 91 AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
2366
2457
3458

query I rowsort
SELECT 9 * col1 AS col1 FROM tab1 AS cor0
----
117
234
90

query I rowsort
SELECT + 98 + - col2 FROM tab2 AS cor0
----
60
71
72

query I rowsort
SELECT - 27 AS col1 FROM tab0 AS cor0
----
-27
-27
-27

query I rowsort
SELECT 5 FROM tab1, tab1 cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

onlyif mysql # use DIV operator for integer division
query I rowsort label-1944
SELECT ( + col2 ) DIV tab2.col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-1944
SELECT ( + col2 ) / tab2.col1 FROM tab2
----
0
0
2

query I rowsort
SELECT + 17 * col1 FROM tab1 AS cor0
----
170
221
442

query I rowsort
SELECT col0 * 57 AS col1 FROM tab0 AS cor0
----
1368
1995
5073

query I rowsort
SELECT + 66 + + col2 * - col2 * - 61 FROM tab1
----
177942
198255
562242

query I rowsort
SELECT 24 * - 32 AS col0 FROM tab1 AS cor0
----
-768
-768
-768

query I rowsort
SELECT ( - col1 ) + + col1 * - col2 AS col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT 9 AS col0 FROM tab2
----
9
9
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1951
SELECT + col0 + + col0 * + tab1.col1 DIV - col1 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1951
SELECT + col0 + + col0 * + tab1.col1 / - col1 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col0 + + col0 * ( - col2 ) FROM tab1 AS cor0
----
-165
-3712
-7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-1953
SELECT + - col0 DIV + col2 + CAST( col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-1953
SELECT + - col0 / + col2 + CAST ( col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
3
63
80

query I rowsort
SELECT + + col1 * 60 FROM tab0 AS cor0
----
5160
5460
5820

query I rowsort
SELECT + - col2 * col2 AS col0 FROM tab2 cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1956
SELECT DISTINCT - CAST( NULL AS DECIMAL ) AS col1 FROM tab1, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1956
SELECT DISTINCT - CAST ( NULL AS REAL ) AS col1 FROM tab1, tab2 AS cor0
----
NULL

query I rowsort
SELECT col1 * - 47 FROM tab2 AS cor0
----
-1457
-2773
-799

query I rowsort
SELECT - col1 * + 22 * - col2 FROM tab0 AS cor0
----
164164
2134
62436

query I rowsort
SELECT + 50 + - 4 FROM tab2, tab0 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT col1 + 0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL col0 + 7 + col0 FROM tab0 AS cor0
----
185
55
77

query I rowsort
SELECT ALL + col2 + col2 + + col1 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT DISTINCT - col2 * - 52 AS col0 FROM tab0 AS cor0
----
1716
4264
52

query I rowsort
SELECT col2 + + col2 + + col1 * - col1 FROM tab1 AS cor0
----
-568
14
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1965
SELECT DISTINCT CAST( NULL AS DECIMAL ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1965
SELECT DISTINCT CAST ( NULL AS REAL ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + 10 * 67 FROM tab2 AS cor0
----
670
670
670

query I rowsort
SELECT - col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 76 col2 FROM tab2 AS cor0
----
76
76
76

query I rowsort
SELECT DISTINCT - 41 + 39 FROM tab0 AS cor0
----
-2

query I rowsort
SELECT - + cor0.col0 AS col2 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT 27 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 21 + + col1 * - col2 * 74 col1 FROM tab2 AS cor0
----
-113495
-47783
-61917

query I rowsort
SELECT ALL 16 * col0 AS col2 FROM tab0 AS cor0
----
1424
384
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-1974
SELECT ALL + ( 92 ) DIV col1 FROM tab1 AS cor0
----
3
7
9

skipif mysql # not compatible
query I rowsort label-1974
SELECT ALL + ( 92 ) / col1 FROM tab1 AS cor0
----
3
7
9

query I rowsort
SELECT - cor1.col0 FROM tab1, tab0 cor0, tab1 AS cor1, tab0, tab2 AS cor2
----
243 values hashing to f74ca4a9760ae5a015b067d560a14502

query I rowsort
SELECT - col0 + + col0 * 87 FROM tab0 cor0
----
2064
3010
7654

query I rowsort
SELECT + 47 + col0 AS col0 FROM tab2 AS cor0
----
125
126
54

query I rowsort
SELECT ( - col1 ) * - ( 61 ) + col0 FROM tab0 AS cor0
----
5270
5640
5952

query I rowsort
SELECT ALL - 54 * + col0 - + 18 AS col0 FROM tab0 cor0
----
-1314
-1908
-4824

query I rowsort
SELECT - col2 * + col0 + + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL + cor0.col1 + + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + + col0 + - cor0.col0 + + 76 FROM tab0 AS cor0
----
76

query I rowsort
SELECT DISTINCT + col0 + 92 AS col1 FROM tab1 AS cor0
----
156
172
95

query I rowsort
SELECT + col2 + + 30 AS col0 FROM tab0 AS cor0
----
112
31
63

query I rowsort
SELECT ALL - - col0 + 82 FROM tab1 AS cor0
----
146
162
85

query I rowsort
SELECT DISTINCT + col1 * col0 - col1 FROM tab1 cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT col1 * - ( + 24 * col0 ) + + ( - col0 ) + + col0 AS col0 FROM tab0 AS cor0
----
-194376
-49536
-81480

query I rowsort
SELECT col1 + 41 * col1 AS col0 FROM tab2 AS cor0
----
1302
2478
714

query I rowsort
SELECT ALL + col1 + 54 * - cor0.col2 + - cor0.col0 FROM tab1 AS cor0
----
-2893
-3132
-5251

query I rowsort
SELECT DISTINCT + - col1 + col1 - + 42 AS col0 FROM tab1 cor0
----
-42

query I rowsort
SELECT ALL - col2 * + ( + col2 ) AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + col1 + + col2 AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
10
13
26

query I rowsort
SELECT + 80 * col1 AS col2 FROM tab1 AS cor0
----
1040
2080
800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - col0 * col0 col2 FROM tab2 AS cor0
----
106097
1519
358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-1996
SELECT DISTINCT 37 + - col1 DIV 70 AS col2 FROM tab2 AS cor0
----
37

skipif mysql # not compatible
query I rowsort label-1996
SELECT DISTINCT 37 + - col1 / 70 AS col2 FROM tab2 AS cor0
----
37

query I rowsort
SELECT ALL + + col2 * + col0 * 64 AS col2 FROM tab0 AS cor0
----
2240
467072
50688

query I rowsort
SELECT col0 - + col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL + col1 + + col0 * + 10 * col0 AS col0 FROM tab1 AS cor0
----
116
40970
64013

query I rowsort
SELECT DISTINCT + - ( + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 56 * - col1 col0 FROM tab1 AS cor0
----
-1456
-560
-728

query I rowsort
SELECT ALL - col0 + col2 * - col1 AS col1 FROM tab2 cor0
----
-1612
-725
-844

query I rowsort
SELECT + ( + col0 ) + + col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-2004
SELECT ALL cor0.col2 DIV - col0 AS col2 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-2004
SELECT ALL cor0.col2 / - col0 AS col2 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT DISTINCT - + col1 * col1 + 75 * + col0 FROM tab1 AS cor0
----
-451
4700
5831

query I rowsort
SELECT ALL - col2 * col0 + col0 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT + + col1 * + 53 + col1 * + col2 AS col0 FROM tab0 AS cor0
----
12285
5238
7396

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col0 col2 FROM tab2 cor0
----
0

query I rowsort
SELECT DISTINCT col1 * 21 AS col2 FROM tab2 AS cor0
----
1239
357
651

query I rowsort
SELECT + 32 AS col2 FROM tab1 cor0
----
32
32
32

query I rowsort
SELECT DISTINCT - 53 + - col2 * col0 AS col2 FROM tab1 AS cor0
----
-215
-3701
-7733

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2012
SELECT ALL CAST( NULL AS SIGNED ) + - col0 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2012
SELECT ALL CAST ( NULL AS INTEGER ) + - col0 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 - - col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2014
SELECT CAST( NULL AS SIGNED ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2014
SELECT CAST ( NULL AS INTEGER ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2015
SELECT ALL + CAST( + col2 AS SIGNED ) + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-2015
SELECT ALL + CAST ( + col2 AS INTEGER ) + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + ( col0 ) * - col2 - 23 FROM tab1 AS cor0
----
-185
-3671
-7703

query I rowsort
SELECT DISTINCT + col1 + col0 * 47 * col0 FROM tab2
----
2334
286007
293344

query I rowsort
SELECT DISTINCT - - 65 + ( cor0.col0 ) AS col2 FROM tab2 cor0
----
143
144
72

query I rowsort
SELECT DISTINCT + - col1 * 50 FROM tab0 AS cor0
----
-4300
-4550
-4850

query I rowsort
SELECT DISTINCT 31 * 92 - col0 AS col2 FROM tab1 cor0
----
2772
2788
2849

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2021
SELECT ALL - col1 * - ( + col2 + - CAST( NULL AS SIGNED ) ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2021
SELECT ALL - col1 * - ( + col2 + - CAST ( NULL AS INTEGER ) ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 4 * col0 + col1 * + col0 FROM tab2
----
1659
245
4914

query I rowsort
SELECT DISTINCT col2 * + col1 * col0 AS col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL - + 66 + col0 AS col1 FROM tab2 AS cor0
----
-59
12
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col0 + + 43 col2 FROM tab1 AS cor0
----
-119
-3605
-7637

query I rowsort
SELECT - 2 AS col0 FROM tab1 AS cor0
----
-2
-2
-2

query I rowsort
SELECT + 33 * 62 * - col0 + col2 FROM tab1
----
-130887
-163584
-6084

onlyif mysql # use DIV operator for integer division
query I rowsort label-2028
SELECT ALL 30 DIV tab0.col2 FROM tab0
----
0
0
30

skipif mysql # not compatible
query I rowsort label-2028
SELECT ALL 30 / tab0.col2 FROM tab0
----
0
0
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 74 col1 FROM tab0
----
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2030
SELECT - CAST( + col2 AS SIGNED ) + + col2 * + col1 * + tab2.col2 FROM tab2
----
22572
24510
39858

skipif mysql # not compatible
query I rowsort label-2030
SELECT - CAST ( + col2 AS INTEGER ) + + col2 * + col1 * + tab2.col2 FROM tab2
----
22572
24510
39858

query I rowsort
SELECT 4 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 3347a3237b37ed63205e9440d8818a46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 21 col1 FROM tab0
----
-21
-21
-21

query I rowsort
SELECT - col1 * col0 + col2 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT - 39 + col2 * col0 FROM tab0 AS cor0
----
-4
7259
753

onlyif mysql # use DIV operator for integer division
query I rowsort label-2035
SELECT DISTINCT - - 34 * col1 - col1 DIV 10 AS col2 FROM tab1 AS cor0
----
339
441
882

skipif mysql # not compatible
query I rowsort label-2035
SELECT DISTINCT - - 34 * col1 - col1 / 10 AS col2 FROM tab1 AS cor0
----
339
441
882

query I rowsort
SELECT ALL + - col0 + + col0 * + col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT - tab0.col2 * - ( + 12 + + col0 * tab0.col1 ) FROM tab0
----
3407
665102
68508

query I rowsort
SELECT DISTINCT + cor0.col1 AS col0 FROM tab0, tab2, tab2 cor0
----
17
31
59

query I rowsort
SELECT - 26 + - col0 FROM tab2 AS cor0
----
-104
-105
-33

query I rowsort
SELECT ALL + tab1.col0 * - 53 AS col2 FROM tab1
----
-159
-3392
-4240

query I rowsort
SELECT - tab2.col1 * - tab2.col0 AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL cor1.col0 AS col0 FROM tab2, tab2 AS cor0, tab2 cor1, tab0 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT + col1 * col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT 97 FROM tab2, tab1 AS cor0
----
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - ( - col2 + col0 ) col0 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT DISTINCT col0 * + 12 AS col0 FROM tab1 AS cor0
----
36
768
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2047
SELECT - CAST( NULL AS SIGNED ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2047
SELECT - CAST ( NULL AS INTEGER ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 * + col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-2049
SELECT DISTINCT col2 * - ( col0 ) + 44 DIV col2 + col0 AS col0 FROM tab0 AS cor0
----
-7209
-767
44

skipif mysql # not compatible
query I rowsort label-2049
SELECT DISTINCT col2 * - ( col0 ) + 44 / col2 + col0 AS col0 FROM tab0 AS cor0
----
-7209
-767
44

query I rowsort
SELECT + + 57 * + col2 AS col0 FROM tab2 AS cor0
----
1482
1539
2166

query I rowsort
SELECT DISTINCT col1 * + tab2.col1 + - col0 FROM tab2
----
210
3403
954

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL NOT BETWEEN NULL AND + col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2053
SELECT ALL - cor0.col2 * col1 + + col1 + - col2 DIV - col2 AS col2 FROM tab0 AS cor0
----
-2751
-7370
1

skipif mysql # not compatible
query I rowsort label-2053
SELECT ALL - cor0.col2 * col1 + + col1 + - col2 / - col2 AS col2 FROM tab0 AS cor0
----
-2751
-7370
1

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE + col1 / + col1 + - col2 NOT IN ( - col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL - cor0.col0 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL NOT BETWEEN col2 * + col0 AND col1
----

query I rowsort
SELECT DISTINCT - col2 + col1 * col0 FROM tab0
----
2031
3394
8017

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL NOT BETWEEN - col1 + col1 + col2 * col0 * col0 AND col0 * + col0 + - col1 * col2
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT - col1 <= + col1
----

query I rowsort
SELECT DISTINCT + tab2.col0 + - col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE NOT - col1 NOT BETWEEN ( NULL ) AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2062
SELECT ALL + col1 + col0 DIV + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2062
SELECT ALL + col1 + col0 / + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT col0 + - col0 * col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL col2 + + col2 * col0 * col0 AS col2 FROM tab0
----
1226
19041
649604

query I rowsort
SELECT - tab1.col1 FROM tab1 WHERE NOT + col0 < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + tab2.col0 * col2 col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT col1 * col0 + col0 + + col1 * col0 AS col2 FROM tab2 AS cor0
----
2765
441
9282

onlyif mysql # use DIV operator for integer division
query I rowsort label-2068
SELECT col2 + - col1 DIV - col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-2068
SELECT col2 + - col1 / - col2 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT - col2 + cor0.col1 * + col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT tab1.col0 * - col2 * - col1 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-2071
SELECT + col0 + col2 * col2 DIV - col1 AS col0 FROM tab1 AS cor0
----
-109
-260
-628

skipif mysql # not compatible
query I rowsort label-2071
SELECT + col0 + col2 * col2 / - col1 AS col0 FROM tab1 AS cor0
----
-109
-260
-628

query I rowsort
SELECT + tab1.col2 * tab1.col1 AS col1 FROM tab1
----
1248
1404
570

query III rowsort
SELECT * FROM tab1 WHERE NOT col1 < - col1 * - col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 * tab2.col0 col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT col0 * col0 + + col1 AS col2 FROM tab2 cor0
----
6143
6258
80

query I rowsort
SELECT tab2.col1 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL col2 * + col1 + col0 * + col2 AS col2 FROM tab1
----
1566
4218
8928

query I rowsort
SELECT + cor0.col1 + col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT tab1.col2 * + tab1.col0 + col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT DISTINCT col1 AS col0 FROM tab2 AS cor0 WHERE ( NULL ) NOT IN ( + col2 ) OR col0 NOT IN ( + col1 )
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + ( 59 ) col0 FROM tab0 cor0
----
145
150
156

query I rowsort
SELECT DISTINCT + col0 + cor0.col1 * col2 AS col0 FROM tab1 AS cor0
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + 25 * - col2 col0 FROM tab0 cor0
----
-182450
-19800
-875

query I rowsort
SELECT DISTINCT + - col2 * cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - col2 * - tab2.col0 * col0 + col1 AS col0 FROM tab2
----
1354
158243
237175

onlyif mysql # use DIV operator for integer division
query I rowsort label-2086
SELECT + - cor0.col2 + 60 * 74 DIV cor0.col2 FROM tab0 cor0
----
-28
101
4439

skipif mysql # not compatible
query I rowsort label-2086
SELECT + - cor0.col2 + 60 * 74 / cor0.col2 FROM tab0 cor0
----
-28
101
4439

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2087
SELECT DISTINCT - col2 * - CAST( NULL AS DECIMAL ) - - 94 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2087
SELECT DISTINCT - col2 * - CAST ( NULL AS REAL ) - - 94 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - col2 * - 86 AS col2 FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT - col1 + 37 * col1 AS col2 FROM tab2 AS cor0
----
1116
2124
612

query I rowsort
SELECT DISTINCT - col1 + cor0.col0 * + 14 AS col1 FROM tab1 cor0
----
1107
16
886

query I rowsort
SELECT col2 + + ( - col0 ) AS col1 FROM tab0 cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2092
SELECT ALL col1 / CAST( NULL AS SIGNED ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2092
SELECT ALL col1 / CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col1 * - 99 + + 14 AS col0 FROM tab2 AS cor0
----
1697
3083
5855

onlyif mysql # use DIV operator for integer division
query I rowsort label-2094
SELECT DISTINCT - col0 DIV tab2.col0 AS col0 FROM tab2
----
-1

skipif mysql # not compatible
query I rowsort label-2094
SELECT DISTINCT - col0 / tab2.col0 AS col0 FROM tab2
----
-1

query I rowsort
SELECT ALL - col2 * col2 + + col2 - col1 FROM tab1
----
-2888
-3202
-9133

query I rowsort
SELECT - col2 + tab1.col0 + + col2 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT col1 + col2 FROM tab1 WHERE NOT + col0 = ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - col2 * col0 col1 FROM tab1
----
-108
-3591
-7584

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( NULL ) IN ( - col0 )
----

query I rowsort
SELECT ALL - col1 FROM tab2 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL - + 35 * col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1122
-2788
-34

query I rowsort
SELECT - col2 + col1 * col0 + - col1 FROM tab0
----
1945
3297
7926

query I rowsort
SELECT ALL - + 84 * - cor0.col1 FROM tab2 cor0
----
1428
2604
4956

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT ALL - 95 * col1 AS col0 FROM tab2 AS cor0
----
-1615
-2945
-5605

query I rowsort
SELECT DISTINCT 59 + cor0.col1 FROM tab0 AS cor0
----
145
150
156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 47 + col2 + cor0.col0 col1 FROM tab2 AS cor0
----
151
164
81

query I rowsort
SELECT ALL + col1 * ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - col0 * 30 FROM tab1 AS cor0
----
-1920
-2400
-90

query I rowsort
SELECT DISTINCT + + col1 + ( + col2 ) FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2111
SELECT col1 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2111
SELECT col1 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2112
SELECT + cor0.col1 DIV col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2112
SELECT + cor0.col1 / col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - 99 * ( col2 ) AS col2 FROM tab0 AS cor0
----
-3267
-8118
-99

query I rowsort
SELECT + 71 AS col0 FROM tab2 AS cor0
----
71
71
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 - cor0.col2 col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - 62 FROM tab0, tab2 cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-2117
SELECT col1 DIV - tab0.col0 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2117
SELECT col1 / - tab0.col0 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT ( 46 ) * + col2 AS col2 FROM tab2 AS cor0
----
1196
1242
1748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 22 ) * + tab0.col2 col1 FROM tab0
----
-1804
-22
-726

query I rowsort
SELECT ( + col0 + + col2 ) FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2121
SELECT - + cor0.col0 DIV 58 col0 FROM tab0 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2121
SELECT - + cor0.col0 / 58 col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT 40 + col0 * + col0 AS col1 FROM tab2 AS cor0
----
6124
6281
89

query I rowsort
SELECT ALL - cor0.col2 AS col1 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2124
SELECT - 45 DIV + col2 FROM tab0 AS cor0
----
-1
-45
0

skipif mysql # not compatible
query I rowsort label-2124
SELECT - 45 / + col2 FROM tab0 AS cor0
----
-1
-45
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * col2 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - - col0 * + 12 AS col0 FROM tab0 AS cor0
----
1068
288
420

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 5 col1 FROM tab0 cor0
----
5
5
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2128
SELECT ALL col0 + col0 DIV - col0 AS col0 FROM tab2 cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-2128
SELECT ALL col0 + col0 / - col0 AS col0 FROM tab2 cor0
----
6
77
78

query I rowsort
SELECT - 57 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * col0 col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL + 41 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT + + col2 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-2133
SELECT DISTINCT cor0.col0 DIV - col2 AS col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-2133
SELECT DISTINCT cor0.col0 / - col2 AS col2 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT - col2 + col2 + col1 AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + cor0.col2 + + col2 * + 22 + col1 AS col0 FROM tab1 cor0
----
1268
1321
2221

query I rowsort
SELECT + 46 AS col1 FROM tab2
----
46
46
46

query I rowsort
SELECT tab1.col0 + - col0 * tab1.col0 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT ALL 75 + + col1 * + ( - col0 ) FROM tab2 AS cor0
----
-1268
-142
-4527

query I rowsort
SELECT ALL - col0 + - cor0.col0 * + col0 AS col1 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT DISTINCT - col1 + col1 * col0 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT + col0 + + col0 + col2 AS col2 FROM tab0 AS cor0
----
260
71
81

query I rowsort
SELECT DISTINCT col1 * + 11 + + col1 AS col0 FROM tab2 AS cor0
----
204
372
708

query I rowsort
SELECT + col0 + + 86 * - col1 AS col2 FROM tab1 cor0
----
-1038
-2233
-796

query I rowsort
SELECT + col1 + col0 + - col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - - col0 + - col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + 83 + + 58 * col2 AS col0 FROM tab2 AS cor0
----
1532
1618
2270

query I rowsort
SELECT + - cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + col2 + - ( 59 ) AS col1 FROM tab1 AS cor0
----
-2
-5
37

query I rowsort
SELECT DISTINCT col2 + + col2 * - col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT col1 + - tab0.col2 AS col0 FROM tab0
----
53
9
96

query I rowsort
SELECT + col1 * + col1 - 26 FROM tab1
----
143
650
74

query I rowsort
SELECT col1 + - col2 * - col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT + 63 + + col2 * - col0 FROM tab0
----
-7235
-729
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-2154
SELECT col0 DIV - col0 - col0 AS col0 FROM tab1
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-2154
SELECT col0 / - col0 - col0 AS col0 FROM tab1
----
-4
-65
-81

query I rowsort
SELECT ALL col2 + + 74 FROM tab1 cor0
----
128
131
170

query I rowsort
SELECT DISTINCT - cor0.col0 * col0 * - col0 - col1 FROM tab2 AS cor0
----
312
474493
493022

query I rowsort
SELECT col0 * + ( + 17 ) + cor0.col1 FROM tab1 AS cor0
----
1098
1373
77

query I rowsort
SELECT ALL 81 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2159
SELECT - - col1 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2159
SELECT - - col1 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 53 AS col1 FROM tab2, tab0 AS cor0
----
-53

query I rowsort
SELECT 55 FROM tab1, tab0 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + - cor0.col0 col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + - 27 FROM tab1 AS cor0
----
-27
-27
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-2164
SELECT - - col0 + + col1 + col1 DIV + col2 FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-2164
SELECT - - col0 + + col1 + col1 / + col2 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2165
SELECT - - col1 * + col2 - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2165
SELECT - - col1 * + 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-2166
SELECT col2 DIV col1 + 55 AS col2 FROM tab1 AS cor0
----
57
60
62

skipif mysql # not compatible
query I rowsort label-2166
SELECT col2 / col1 + 55 AS col2 FROM tab1 AS cor0
----
57
60
62

query I rowsort
SELECT + col0 - - col1 AS col2 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL ( + col2 ) + - col0 * ( 38 ) + col0 FROM tab2
----
-232
-2860
-2885

query I rowsort
SELECT + 27 * 16 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 48b71d232f6aafe607354db08bd58d2a

query I rowsort
SELECT - - cor0.col2 AS col0 FROM tab0, tab1 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT DISTINCT - col1 * + col0 + 42 AS col0 FROM tab0 AS cor0
----
-2022
-3353
-8057

query I rowsort
SELECT + - 93 * + col0 FROM tab2 AS cor0
----
-651
-7254
-7347

query I rowsort
SELECT DISTINCT - 45 + cor0.col0 AS col2 FROM tab1 cor0
----
-42
19
35

query I rowsort
SELECT ALL + 46 - - col1 FROM tab2 AS cor0
----
105
63
77

query I rowsort
SELECT + 51 * col1 + - col0 AS col0 FROM tab0 cor0
----
4362
4552
4912

query I rowsort
SELECT ALL col1 * - col1 * 69 AS col0 FROM tab0 AS cor0
----
-510324
-571389
-649221

query I rowsort
SELECT DISTINCT - 63 + - col1 + ( col1 ) AS col0 FROM tab1 cor0
----
-63

query I rowsort
SELECT ALL col1 * - col0 - + ( col2 + + col2 ) * col0 FROM tab2 AS cor0
----
-595
-7347
-8658

query I rowsort
SELECT + col2 + + cor0.col0 * + 25 AS col1 FROM tab0 cor0
----
2307
633
876

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2180
SELECT ALL CAST( col2 AS SIGNED ) * col2 FROM tab1
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-2180
SELECT ALL CAST ( col2 AS INTEGER ) * col2 FROM tab1
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - col1 col2 FROM tab0
----
0

query I rowsort
SELECT ALL 6 * tab1.col1 AS col1 FROM tab1
----
156
60
78

query I rowsort
SELECT 20 + + ( + col0 * + 50 ) AS col2 FROM tab1 AS cor0
----
170
3220
4020

query I rowsort
SELECT - - 44 + - col1 FROM tab2 AS cor0
----
-15
13
27

query I rowsort
SELECT + - 43 + - col0 * cor0.col0 FROM tab2 AS cor0
----
-6127
-6284
-92

query I rowsort
SELECT + + 37 * - col2 FROM tab1 cor0
----
-1998
-2109
-3552

query I rowsort
SELECT 87 + col1 FROM tab2 AS cor0
----
104
118
146

query I rowsort
SELECT + - 62 * cor0.col2 * col0 FROM tab1 AS cor0
----
-10044
-226176
-476160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - col0 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 50 col1 FROM tab2 AS cor0
----
50

query I rowsort
SELECT DISTINCT - 96 * col0 FROM tab0 AS cor0
----
-2304
-3360
-8544

onlyif mysql # use DIV operator for integer division
query I rowsort label-2192
SELECT ALL + + col0 + cor0.col1 DIV col2 AS col0 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-2192
SELECT ALL + + col0 + cor0.col1 / col2 AS col0 FROM tab0 AS cor0
----
132
26
90

query I rowsort
SELECT + + 46 * col1 AS col1 FROM tab2 AS cor0
----
1426
2714
782

query I rowsort
SELECT - - col0 + - 47 - col2 FROM tab0 AS cor0
----
-13
-40
-56

query I rowsort
SELECT - - col1 + 95 FROM tab1 AS cor0
----
105
108
121

onlyif mysql # use DIV operator for integer division
query I rowsort label-2196
SELECT col2 DIV col2 + + 16 AS col2 FROM tab1 AS cor0
----
17
17
17

skipif mysql # not compatible
query I rowsort label-2196
SELECT col2 / col2 + + 16 AS col2 FROM tab1 AS cor0
----
17
17
17

query I rowsort
SELECT + + col1 - - col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL cor0.col0 * - 30 + col2 FROM tab1 AS cor0
----
-1863
-2304
-36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2199
SELECT ALL - CAST( NULL AS SIGNED ) - - 89 * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2199
SELECT ALL - CAST ( NULL AS INTEGER ) - - 89 * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 * 50 FROM tab1, tab0 AS cor0
----
9 values hashing to 332185024a608e83cd9cb357cb48bdf6

query I rowsort
SELECT + 33 + + cor0.col1 FROM tab1 AS cor0
----
43
46
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2202
SELECT ALL - col0 DIV - 16 AS col0 FROM tab0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-2202
SELECT ALL - col0 / - 16 AS col0 FROM tab0
----
1
2
5

query I rowsort
SELECT + 44 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( 71 ) * - col2 col2 FROM tab2 cor0
----
1846
1917
2698

query I rowsort
SELECT ALL + ( + col0 ) + col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT 77 + col0 FROM tab1 AS cor0
----
141
157
80

query I rowsort
SELECT DISTINCT - - col0 * + col0 + cor0.col2 * col1 AS col0 FROM tab2 AS cor0
----
6887
7618
886

query I rowsort
SELECT DISTINCT - col0 * ( cor0.col2 ) + - ( + col0 ) FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT + 15 * - col2 + + col1 * - ( - cor0.col0 ) FROM tab1 AS cor0
----
-215
-400
-732

query I rowsort
SELECT DISTINCT + + col1 * + col2 - col0 * + col2 * col2 FROM tab1 cor0
----
-207366
-7344
-736032

query I rowsort
SELECT ALL - - ( col0 ) * col2 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + 67 + col0 col1 FROM tab0 AS cor0
----
103
124
238

query I rowsort
SELECT - col1 - col0 * - col0 AS col2 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT - col1 * - ( - col0 ) FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2215
SELECT + col1 DIV + 33 FROM tab0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-2215
SELECT + col1 / + 33 FROM tab0
----
2
2
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-2216
SELECT col0 DIV + ( + 47 * + col1 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2216
SELECT col0 / + ( + 47 * + col1 ) FROM tab0
----
0
0
0

query I rowsort
SELECT + cor0.col1 + - 13 * - col1 * 80 AS col2 FROM tab0 cor0
----
100977
89526
94731

query I rowsort
SELECT ALL - col2 * + ( col2 ) - col2 FROM tab0 AS cor0
----
-1122
-2
-6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2219
SELECT ALL + 36 DIV col1 AS col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2219
SELECT ALL + 36 / col1 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col2 * + 88 + - col1 FROM tab0 AS cor0
----
-9
2818
7125

query I rowsort
SELECT DISTINCT col1 - + tab2.col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT + col0 * - col2 + + col2 AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT + 83 + + col1 AS col2 FROM tab1 AS cor0
----
109
93
96

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0 CROSS JOIN tab0, tab0 cor1
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

query I rowsort
SELECT 92 - + cor0.col0 AS col1 FROM tab1 AS cor0
----
12
28
89

query I rowsort
SELECT DISTINCT 11 + col0 AS col2 FROM tab1
----
14
75
91

query I rowsort
SELECT ALL - col0 * col1 + - tab0.col2 AS col0 FROM tab0
----
-2097
-3396
-8181

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0, tab2 cor1, tab1 AS cor2
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col0 * col0 col2 FROM tab1
----
-262144
-27
-512000

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 * + col1 col2 FROM tab1
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 51 col0 FROM tab0, tab1 AS cor0
----
51

query I rowsort
SELECT + col2 + col0 * + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - + cor0.col0 * + col0 * - col1 FROM tab2 AS cor0
----
106097
1519
358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + ( col1 ) col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + + col2 * cor0.col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL col2 + + col2 * col2 AS col1 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL + col0 - col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT 6 * col2 AS col0 FROM tab1 AS cor0
----
324
342
576

query I rowsort
SELECT col0 + + cor0.col1 * col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT + ( - col0 ) + cor0.col0 * col1 AS col2 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT + 10 + + col0 AS col1 FROM tab1
----
13
74
90

query I rowsort
SELECT - 51 + - 38 + - tab1.col2 AS col0 FROM tab1
----
-143
-146
-185

query I rowsort
SELECT cor0.col0 * col0 + col0 * col0 FROM tab1 AS cor0
----
12800
18
8192

query I rowsort
SELECT ALL + 36 + 47 AS col0 FROM tab2
----
83
83
83

query I rowsort
SELECT - ( + col0 * col2 ) FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2246
SELECT DISTINCT 33 * tab0.col2 * - col1 + - col1 DIV + col1 AS col0 FROM tab0
----
-246247
-3202
-93655

skipif mysql # not compatible
query I rowsort label-2246
SELECT DISTINCT 33 * tab0.col2 * - col1 + - col1 / + col1 AS col0 FROM tab0
----
-246247
-3202
-93655

query I rowsort
SELECT - + col1 * - col2 + 69 FROM tab2 AS cor0
----
1603
715
906

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + col0 col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + 2 * - col2 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2250
SELECT DISTINCT - col2 * col0 + + col0 DIV - cor0.col0 FROM tab0 AS cor0
----
-36
-7299
-793

skipif mysql # not compatible
query I rowsort label-2250
SELECT DISTINCT - col2 * col0 + + col0 / - cor0.col0 FROM tab0 AS cor0
----
-36
-7299
-793

query I rowsort
SELECT ALL - + col2 - - col0 FROM tab1 cor0
----
-16
-51
7

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 489b7b2b5c4980d50e86e51be30361c3

query I rowsort
SELECT + col0 + + ( col0 ) FROM tab1
----
128
160
6

query I rowsort
SELECT + ( 99 ) AS col1 FROM tab0 AS cor0
----
99
99
99

query I rowsort
SELECT - 16 FROM tab1, tab1 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2256
SELECT DISTINCT col2 * + CAST( 40 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
1320
3280
40

skipif mysql # not compatible
query I rowsort label-2256
SELECT DISTINCT col2 * + CAST ( 40 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT DISTINCT + tab1.col2 + - ( col2 * col1 ) FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT + ( cor0.col2 ) * + col0 + - col2 * - 47 FROM tab1 AS cor0
----
12192
2700
6327

query I rowsort
SELECT ALL 53 AS col2 FROM tab0 cor0
----
53
53
53

query I rowsort
SELECT + col0 + - 68 * - col0 AS col1 FROM tab0 AS cor0
----
1656
2415
6141

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 19 * col2 col2 FROM tab0
----
1558
19
627

query I rowsort
SELECT DISTINCT ( 51 ) * + col2 * + tab2.col0 FROM tab2
----
103428
153102
9639

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 7 + + 20 col0 FROM tab0 AS cor0
----
27

query I rowsort
SELECT DISTINCT - 9 + - col0 FROM tab1 cor0
----
-12
-73
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 37 + col0 * + cor0.col0 col1 FROM tab1 AS cor0
----
4133
46
6437

query I rowsort
SELECT DISTINCT + cor0.col1 + col0 * col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT + 47 + cor0.col1 AS col1 FROM tab2 cor0
----
106
64
78

query I rowsort
SELECT - 41 + cor0.col2 - col1 * col0 AS col0 FROM tab0 AS cor0
----
-2072
-3435
-8058

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + cor0.col1 ) * + cor0.col2 + - 34 * col1 + - col2 col0 FROM tab0 AS cor0
----
-10638
-3396
-5795

query I rowsort
SELECT - col2 * col2 + col0 - col1 AS col0 FROM tab2 cor0
----
-1382
-657
-753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2271
SELECT 96 * col1 + + col0 + CAST( + 52 * + col1 AS SIGNED ) AS col0 FROM tab0 cor0
----
12752
13557
14391

skipif mysql # not compatible
query I rowsort label-2271
SELECT 96 * col1 + + col0 + CAST ( + 52 * + col1 AS INTEGER ) AS col0 FROM tab0 cor0
----
12752
13557
14391

query I rowsort
SELECT ALL - + ( col2 ) * + col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2273
SELECT - ( col1 ) * - col1 + col0 * - cor0.col0 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2273
SELECT - ( col1 ) * - col1 + col0 * - cor0.col0 * - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 42 * + col0 + ( 43 ) * cor0.col1 FROM tab0 cor0
----
4706
5641
7651

query I rowsort
SELECT ALL - 51 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

query I rowsort
SELECT col2 * + col0 + - col1 AS col1 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT cor1.col2 + 10 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
11
43
92

query I rowsort
SELECT DISTINCT - col2 * col2 + col2 FROM tab1 cor0
----
-2862
-3192
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + 60 * + col2 * + col1 col1 FROM tab0 AS cor0
----
170366
447811
5917

query I rowsort
SELECT col2 * - 5 FROM tab2 AS cor0
----
-130
-135
-190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2281
SELECT - CAST( 31 AS SIGNED ) AS col2 FROM tab2 cor0
----
-31
-31
-31

skipif mysql # not compatible
query I rowsort label-2281
SELECT - CAST ( 31 AS INTEGER ) AS col2 FROM tab2 cor0
----
-31
-31
-31

query I rowsort
SELECT + 20 * + col2 + col2 FROM tab1 AS cor0
----
1134
1197
2016

query I rowsort
SELECT ALL + 27 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT + 34 + cor0.col2 + + col0 FROM tab0 AS cor0
----
205
70
91

query I rowsort
SELECT - 5 * col2 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-189
-40
-499

onlyif mysql # use DIV operator for integer division
query I rowsort label-2286
SELECT ALL col2 + - col2 DIV col0 AS col2 FROM tab2
----
24
26
38

skipif mysql # not compatible
query I rowsort label-2286
SELECT ALL col2 + - col2 / col0 AS col2 FROM tab2
----
24
26
38

query I rowsort
SELECT ALL - 70 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

query I rowsort
SELECT + col1 * ( - col1 ) + cor0.col1 AS col0 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT - col1 * 85 AS col2 FROM tab2 AS cor0
----
-1445
-2635
-5015

query I rowsort
SELECT ALL - 28 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

query I rowsort
SELECT ALL + col2 * - cor0.col2 + + 89 FROM tab1 AS cor0
----
-2827
-3160
-9127

query I rowsort
SELECT DISTINCT - + col0 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + - col2 + 89 AS col2 FROM tab1 cor0
----
-7
32
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2294
SELECT ALL col1 + + CAST( NULL AS SIGNED ) + col2 * cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2294
SELECT ALL col1 + + CAST ( NULL AS INTEGER ) + col2 * cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 57 - + col0 AS col1 FROM tab2
----
-21
-22
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-2296
SELECT DISTINCT col0 DIV + col0 + col0 * tab0.col2 AS col1 FROM tab0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-2296
SELECT DISTINCT col0 / + col0 + col0 * tab0.col2 AS col1 FROM tab0
----
36
7299
793

query I rowsort
SELECT ALL - ( 32 * - col1 ) AS col2 FROM tab0
----
2752
2912
3104

onlyif mysql # use DIV operator for integer division
query I rowsort label-2298
SELECT DISTINCT + ( - col0 ) DIV col0 AS col0 FROM tab2
----
-1

skipif mysql # not compatible
query I rowsort label-2298
SELECT DISTINCT + ( - col0 ) / col0 AS col0 FROM tab2
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2299
SELECT + CAST( - col0 + - col0 AS SIGNED ) FROM tab0
----
-178
-48
-70

skipif mysql # not compatible
query I rowsort label-2299
SELECT + CAST ( - col0 + - col0 AS INTEGER ) FROM tab0
----
-178
-48
-70

query I rowsort
SELECT ALL ( ( + col0 ) ) FROM tab2
----
7
78
79

query I rowsort
SELECT - 1 * col0 - - col1 AS col2 FROM tab0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col0 ) + + col1 * + col1 * + col0 col2 FROM tab1 cor0
----
13440
2025
6336

query I rowsort
SELECT 62 * + col2 AS col2 FROM tab1 AS cor0
----
3348
3534
5952

query I rowsort
SELECT 72 * + col0 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
1761
2521
6490

query I rowsort
SELECT DISTINCT + cor0.col2 + - col0 AS col1 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2306
SELECT DISTINCT - 94 DIV - col1 FROM tab1 AS cor0
----
3
7
9

skipif mysql # not compatible
query I rowsort label-2306
SELECT DISTINCT - 94 / - col1 FROM tab1 AS cor0
----
3
7
9

query I rowsort
SELECT ALL + col1 + col1 * col2 AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + 7 AS col1 FROM tab1 AS cor0
----
7
7
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2309
SELECT DISTINCT + tab1.col1 DIV col1 AS col2 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-2309
SELECT DISTINCT + tab1.col1 / col1 AS col2 FROM tab1
----
1

query I rowsort
SELECT + col0 + - col2 AS col1 FROM tab1
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2311
SELECT ALL + col1 * + col1 * + CAST( - 3 AS SIGNED ) FROM tab2 AS cor0
----
-10443
-2883
-867

skipif mysql # not compatible
query I rowsort label-2311
SELECT ALL + col1 * + col1 * + CAST ( - 3 AS INTEGER ) FROM tab2 AS cor0
----
-10443
-2883
-867

query I rowsort
SELECT ALL - 66 * col1 AS col0 FROM tab0 cor0
----
-5676
-6006
-6402

query I rowsort
SELECT ALL + ( + cor1.col2 ) AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab1, tab2 cor2
----
243 values hashing to 3dcd863493ac16ce594c62d4ac8b0412

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + 19 col1 FROM tab0 cor0
----
-67
-72
-78

query I rowsort
SELECT DISTINCT - col2 * - 38 FROM tab0 cor0
----
1254
3116
38

query I rowsort
SELECT - col2 * + 82 - col2 AS col0 FROM tab0 AS cor0
----
-2739
-6806
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2317
SELECT + + col0 DIV - col2 AS col0 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2317
SELECT + + col0 / - col2 AS col0 FROM tab1 cor0
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2318
SELECT ALL col1 * + ( ( col0 ) * CAST( col2 AS SIGNED ) ) FROM tab0 AS cor0
----
3395
664118
68112

skipif mysql # not compatible
query I rowsort label-2318
SELECT ALL col1 * + ( ( col0 ) * CAST ( col2 AS INTEGER ) ) FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT + cor0.col1 * cor0.col2 AS col2 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2320
SELECT + cor0.col2 DIV + col1 - + col1 FROM tab1 cor0
----
-24
-5
-6

skipif mysql # not compatible
query I rowsort label-2320
SELECT + cor0.col2 / + col1 - + col1 FROM tab1 cor0
----
-24
-5
-6

query I rowsort
SELECT ALL - - col2 * + col2 + - col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT + - col2 + col0 * 76 FROM tab2 AS cor0
----
505
5902
5966

query I rowsort
SELECT ALL - cor0.col0 * + ( - col0 ) * col2 AS col1 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - col0 * - col0 + col1 * - col1 AS col0 FROM tab2
----
-912
2603
5952

query I rowsort
SELECT 64 + col2 AS col2 FROM tab1
----
118
121
160

query I rowsort
SELECT DISTINCT - + cor0.col2 * 94 AS col2 FROM tab0 AS cor0
----
-3102
-7708
-94

query I rowsort
SELECT DISTINCT - col0 * 35 AS col1 FROM tab2 AS cor0
----
-245
-2730
-2765

query I rowsort
SELECT - 8 AS col2 FROM tab1
----
-8
-8
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2329
SELECT DISTINCT - col2 + - col2 * col0 + - col0 DIV + col0 FROM tab0 AS cor0
----
-37
-7381
-826

skipif mysql # not compatible
query I rowsort label-2329
SELECT DISTINCT - col2 + - col2 * col0 + - col0 / + col0 FROM tab0 AS cor0
----
-37
-7381
-826

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( 8 ) * + col0 + col0 - 23 * - col0 * col1 col1 FROM tab1 AS cor0
----
15296
1821
24640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - cor0.col0 col1 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2332
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * 43 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2332
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * 43 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) * + col2 + + cor0.col1 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT + + ( - col0 ) + - col2 * - 95 FROM tab0 AS cor0
----
3111
60
7701

query I rowsort
SELECT - col1 * cor0.col1 + - col0 * + 31 FROM tab0 AS cor0
----
-10494
-11040
-8140

query I rowsort
SELECT + 80 * - col2 FROM tab2 cor0
----
-2080
-2160
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2337
SELECT ALL CAST( NULL AS SIGNED ) + + col0 * cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2337
SELECT ALL CAST ( NULL AS INTEGER ) + + col0 * cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( cor0.col0 ) * - cor0.col2 * - col0 + col2 AS col2 FROM tab0 cor0
----
1226
19041
649604

query I rowsort
SELECT + + 29 + + col1 + - col2 FROM tab1 AS cor0
----
-18
-54
1

query I rowsort
SELECT col2 * 63 FROM tab0 AS cor0
----
2079
5166
63

query I rowsort
SELECT ALL + cor0.col0 * - col2 + + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-2342
SELECT DISTINCT col0 + + cor0.col2 DIV + col1 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2342
SELECT DISTINCT col0 + + cor0.col2 / + col1 FROM tab0 cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * 29 * + col2 col1 FROM tab2 AS cor0
----
19604
21141
41876

query I rowsort
SELECT + col2 * col0 + + col2 * - col0 + - col0 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + 36 * + col2 + col2 * + 39 * col2 FROM tab2 AS cor0
----
27300
29403
57684

query I rowsort
SELECT + 15 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT DISTINCT - 72 * - col1 * col0 AS col0 FROM tab1 AS cor0
----
46080
5616
74880

query I rowsort
SELECT + + 57 + + cor0.col2 AS col0 FROM tab0, tab0 cor0, tab1, tab0 AS cor1
----
81 values hashing to 6f029df09e328f7576e7b338d27865c8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2349
SELECT - tab2.col1 + 40 DIV tab2.col1 FROM tab2
----
-15
-30
-59

skipif mysql # not compatible
query I rowsort label-2349
SELECT - tab2.col1 + 40 / tab2.col1 FROM tab2
----
-15
-30
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2350
SELECT ALL - - col0 - + CAST( NULL AS SIGNED ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2350
SELECT ALL - - col0 - + CAST ( NULL AS INTEGER ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * + col0 * - 8 FROM tab2 AS cor0
----
-1512
-16224
-24016

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2352
SELECT DISTINCT col1 * CAST( col0 * + col0 AS SIGNED ) + col0 FROM tab1 AS cor0
----
237
41024
83280

skipif mysql # not compatible
query I rowsort label-2352
SELECT DISTINCT col1 * CAST ( col0 * + col0 AS INTEGER ) + col0 FROM tab1 AS cor0
----
237
41024
83280

onlyif mysql # use DIV operator for integer division
query I rowsort label-2353
SELECT DISTINCT col1 * col1 DIV col2 FROM tab1 AS cor0
----
1
12

skipif mysql # not compatible
query I rowsort label-2353
SELECT DISTINCT col1 * col1 / col2 FROM tab1 AS cor0
----
1
12

query I rowsort
SELECT DISTINCT + col1 * 51 + col2 AS col0 FROM tab1 AS cor0
----
1380
567
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2355
SELECT ALL col2 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2355
SELECT ALL col2 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 61 * col2 + + col2 col1 FROM tab1 AS cor0
----
-177822
-198132
-562080

query I rowsort
SELECT DISTINCT + col2 + ( col2 * + col0 ) AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL col2 + + 1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT col0 * - 89 - col0 FROM tab2 AS cor0
----
-630
-7020
-7110

query I rowsort
SELECT 87 * - col0 * ( - col2 * + col0 ) + + col1 AS col2 FROM tab1
----
20312074
42308
53452813

query I rowsort
SELECT ALL 32 + col2 * - 47 FROM tab1
----
-2506
-2647
-4480

query I rowsort
SELECT col2 + - col1 + - col1 FROM tab0 AS cor0
----
-100
-139
-193

query I rowsort
SELECT col2 * ( + col0 ) AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + + 42 + col2 AS col2 FROM tab2 AS cor0
----
68
69
80

query I rowsort
SELECT 28 + + col0 FROM tab1 AS cor0
----
108
31
92

query I rowsort
SELECT - - col2 * - col0 FROM tab2 cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - cor0.col2 ) + col2 col2 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2368
SELECT ALL - col2 DIV - col1 AS col2 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2368
SELECT ALL - col2 / - col1 AS col2 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT DISTINCT tab1.col1 AS col0 FROM tab2, tab2 AS cor0 CROSS JOIN tab1
----
10
13
26

query I rowsort
SELECT ALL - tab1.col1 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT ALL + 55 + col1 * col2 AS col2 FROM tab1
----
1303
1459
625

query I rowsort
SELECT DISTINCT col0 * + tab2.col1 + 48 * + col1 AS col2 FROM tab2
----
1705
2159
7434

query I rowsort
SELECT ALL 33 * tab2.col0 + col0 FROM tab2
----
238
2652
2686

query I rowsort
SELECT - + 83 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-2158
-2241
-3154

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9b0655947ad21e0b95a137a474fa6a1f

query I rowsort
SELECT - 79 + + col2 FROM tab0 cor0
----
-46
-78
3

query I rowsort
SELECT DISTINCT + 33 + col2 FROM tab1 AS cor0
----
129
87
90

query I rowsort
SELECT ALL 64 + col1 FROM tab2 AS cor0
----
123
81
95

query I rowsort
SELECT DISTINCT + 35 + col2 FROM tab1
----
131
89
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-2380
SELECT DISTINCT tab2.col1 DIV col0 + - tab2.col0 AS col0 FROM tab2
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-2380
SELECT DISTINCT tab2.col1 / col0 + - tab2.col0 AS col0 FROM tab2
----
-3
-78
-79

query I rowsort
SELECT DISTINCT tab2.col2 + + col2 AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT - col1 * col1 * + col2 + - col1 * + col2 FROM tab1
----
-17472
-37908
-6270

query I rowsort
SELECT ALL + 30 - + col1 AS col1 FROM tab0 AS cor0
----
-56
-61
-67

query I rowsort
SELECT + 90 + + tab1.col1 FROM tab1
----
100
103
116

query I rowsort
SELECT ALL 12 * + col0 * + col1 FROM tab2
----
16116
2604
55224

query I rowsort
SELECT + 26 * + col1 AS col2 FROM tab1 AS cor0
----
260
338
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) * col2 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT col0 AS col0 FROM tab2 WHERE ( col1 ) = NULL AND NOT NULL < + col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 61 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

onlyif mysql # use DIV operator for integer division
query I rowsort label-2390
SELECT + col1 + col2 DIV - col2 AS col0 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-2390
SELECT + col1 + col2 / - col2 AS col0 FROM tab0
----
85
90
96

query I rowsort
SELECT - 18 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

query I rowsort
SELECT 39 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col2 ) * col0 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - - 20 * + 66 AS col1 FROM tab0 AS cor0
----
1320
1320
1320

query I rowsort
SELECT 10 FROM tab0, tab0 cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2396
SELECT DISTINCT CAST( col0 AS SIGNED ) * + col0 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
4032
6
6320

skipif mysql # not compatible
query I rowsort label-2396
SELECT DISTINCT CAST ( col0 AS INTEGER ) * + col0 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT - + 71 * col1 FROM tab0 AS cor0
----
-6106
-6461
-6887

query I rowsort
SELECT 73 * col0 * + col2 FROM tab2 AS cor0
----
13797
148044
219146

query I rowsort
SELECT - + ( col1 ) * + col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col0 * col1 + + col2 FROM tab2 cor0
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - cor0.col1 ) * - cor0.col1 col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ( tab0.col1 ) + + col0 * - tab0.col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT + col1 + - 32 AS col0 FROM tab2
----
-1
-15
27

query I rowsort
SELECT + tab0.col0 * col2 + - col0 * col2 * + col2 FROM tab0
----
-25344
-591138
0

query I rowsort
SELECT DISTINCT + 58 * + col1 AS col0 FROM tab0
----
4988
5278
5626

query I rowsort
SELECT + 61 AS col2 FROM tab0 cor0
----
61
61
61

query I rowsort
SELECT - + 16 FROM tab2 cor0
----
-16
-16
-16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2409
SELECT DISTINCT CAST( NULL AS DECIMAL ) AS col0 FROM tab1, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2409
SELECT DISTINCT CAST ( NULL AS REAL ) AS col0 FROM tab1, tab2 AS cor0
----
NULL

query I rowsort
SELECT + 98 * + ( col0 ) AS col1 FROM tab1 AS cor0
----
294
6272
7840

query I rowsort
SELECT DISTINCT - cor0.col1 * ( cor0.col0 ) * 25 AS col0 FROM tab2 AS cor0
----
-115050
-33575
-5425

query I rowsort
SELECT ALL + 73 AS col1 FROM tab1 AS cor0
----
73
73
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + cor0.col2 col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - - col2 * + 8 FROM tab2 AS cor0
----
208
216
304

query I rowsort
SELECT ALL ( col1 ) + + col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - 24 FROM tab1, tab0 AS cor0
----
-24

query I rowsort
SELECT DISTINCT + ( 71 * - col1 + 19 ) AS col1 FROM tab1
----
-1827
-691
-904

query I rowsort
SELECT col2 * - tab2.col1 AS col2 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT - + col0 + col1 AS col2 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT ALL + 89 * col0 + + col1 FROM tab2 AS cor0
----
654
7001
7048

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col1 col1 FROM tab0, tab2 cor0, tab0 AS cor1
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 + ( + cor0.col0 + col0 ) * col2 col0 FROM tab1 AS cor0
----
16400
402
7936

onlyif mysql # use DIV operator for integer division
query I rowsort label-2423
SELECT ALL + + col1 DIV + col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-2423
SELECT ALL + + col1 / + col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT - 98 + - col0 FROM tab0
----
-122
-133
-187

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col1 * 87 col2 FROM tab0
----
7482
7917
8439

onlyif mysql # use DIV operator for integer division
query I rowsort label-2426
SELECT col1 + 74 DIV + col1 FROM tab1
----
17
18
28

skipif mysql # not compatible
query I rowsort label-2426
SELECT col1 + 74 / + col1 FROM tab1
----
17
18
28

query I rowsort
SELECT + col1 + 19 + + tab2.col1 FROM tab2
----
137
53
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2428
SELECT ALL - col2 + + col2 DIV + col1 FROM tab1 AS cor0
----
-52
-52
-89

skipif mysql # not compatible
query I rowsort label-2428
SELECT ALL - col2 + + col2 / + col1 FROM tab1 AS cor0
----
-52
-52
-89

query I rowsort
SELECT - - col1 + col1 * - col0 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2430
SELECT - + col2 * CAST( col2 + col2 AS SIGNED ) col1 FROM tab2 AS cor0
----
-1352
-1458
-2888

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2430
SELECT - + col2 * CAST ( col2 + col2 AS INTEGER ) col1 FROM tab2 AS cor0
----
-1352
-1458
-2888

query I rowsort
SELECT - + col0 * cor0.col1 * cor0.col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col0 col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col1 * ( - col2 + col1 ) AS col0 FROM tab2 AS cor0
----
-357
124
1947

query I rowsort
SELECT ALL col2 * 82 AS col0 FROM tab1
----
4428
4674
7872

query I rowsort
SELECT - cor0.col0 * 47 FROM tab0 AS cor0
----
-1128
-1645
-4183

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2436
SELECT DISTINCT - col0 + CAST( col1 * col2 AS SIGNED ) FROM tab1
----
1168
1401
506

skipif mysql # not compatible
query I rowsort label-2436
SELECT DISTINCT - col0 + CAST ( col1 * col2 AS INTEGER ) FROM tab1
----
1168
1401
506

query I rowsort
SELECT DISTINCT - col0 * - col2 + - 94 + col1 FROM tab2
----
126
1993
2925

query I rowsort
SELECT ALL - col0 + + col0 + + col1 * tab1.col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT - col2 + - 83 AS col0 FROM tab0
----
-116
-165
-84

query I rowsort
SELECT DISTINCT 48 AS col1 FROM tab1, tab1 cor0
----
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-2441
SELECT DISTINCT col0 DIV + col1 + + 38 + tab1.col1 FROM tab1
----
54
57
64

skipif mysql # not compatible
query I rowsort label-2441
SELECT DISTINCT col0 / + col1 + + 38 + tab1.col1 FROM tab1
----
54
57
64

query I rowsort
SELECT ALL col0 * + ( col1 ) + col2 AS col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT col0 * 24 + ( + col1 ) * + col2 FROM tab2
----
1005
2542
3406

onlyif mysql # use DIV operator for integer division
query I rowsort label-2444
SELECT - - col1 DIV + col0 AS col0 FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-2444
SELECT - - col1 / + col0 AS col0 FROM tab2 cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + 3 * - col0 col0 FROM tab2
----
-567
-6084
-9006

query I rowsort
SELECT DISTINCT - - ( col2 ) AS col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - col0 + 72 FROM tab0 AS cor0
----
-17
37
48

query I rowsort
SELECT DISTINCT + col2 * - 59 * + col1 FROM tab0 cor0
----
-167442
-440258
-5723

query I rowsort
SELECT ALL ( col2 ) * - col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( col0 AS REAL ) + col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2451
SELECT ALL - CAST( NULL AS SIGNED ) / - col0 - + col1 * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2451
SELECT ALL - CAST ( NULL AS INTEGER ) / - col0 - + col1 * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2452
SELECT ALL CAST( NULL AS SIGNED ) * - col2 * + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2452
SELECT ALL CAST ( NULL AS INTEGER ) * - col2 * + col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * + tab0.col0 AS col2 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 * col1 col0 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT 59 + - cor0.col0 * + col1 AS col2 FROM tab0 AS cor0
----
-2005
-3336
-8040

query I rowsort
SELECT + col0 * - col1 * col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT - + 20 + + 17 * - col2 + col0 AS col2 FROM tab1 AS cor0
----
-1572
-925
-935

query I rowsort
SELECT DISTINCT col2 + col0 * col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL - - 38 - col1 AS col1 FROM tab0 AS cor0
----
-48
-53
-59

query I rowsort
SELECT ALL col1 * - col2 - col1 AS col2 FROM tab1 cor0
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-2461
SELECT ALL col0 DIV - col2 + col1 col1 FROM tab1 AS cor0
----
13
26
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2461
SELECT ALL col0 / - col2 + col1 col1 FROM tab1 AS cor0
----
13
26
9

query I rowsort
SELECT + 45 - + col2 FROM tab2 AS cor0
----
18
19
7

query I rowsort
SELECT DISTINCT + tab1.col2 * - col1 + + 5 AS col2 FROM tab1
----
-1243
-1399
-565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2464
SELECT + col2 * - col2 / CAST( NULL AS SIGNED ) + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2464
SELECT + col2 * - col2 / CAST ( NULL AS INTEGER ) + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 41 FROM tab2 AS cor0
----
41
41
41

query I rowsort
SELECT DISTINCT + col1 * col0 * + cor0.col0 + + ( + col2 ) AS col2 FROM tab0 AS cor0
----
118826
49569
720893

query I rowsort
SELECT DISTINCT - 67 + cor0.col0 FROM tab2 AS cor0
----
-60
11
12

query I rowsort
SELECT ALL + 18 AS col1 FROM tab2 AS cor0
----
18
18
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-2469
SELECT + - 8 DIV cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2469
SELECT + - 8 / cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - col1 * + col0 + + ( col2 ) * + 23 AS col0 FROM tab0 AS cor0
----
2823
3418
9985

query I rowsort
SELECT DISTINCT + col1 * + cor0.col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT ALL col2 + 21 AS col0 FROM tab2 cor0
----
47
48
59

query I rowsort
SELECT DISTINCT cor0.col0 + 7 AS col2 FROM tab2 AS cor0
----
14
85
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-2474
SELECT col0 + 84 * col0 DIV - cor0.col1 FROM tab2 AS cor0
----
-11
-311
-33

skipif mysql # not compatible
query I rowsort label-2474
SELECT col0 + 84 * col0 / - cor0.col1 FROM tab2 AS cor0
----
-11
-311
-33

onlyif mysql # use DIV operator for integer division
query I rowsort label-2475
SELECT + cor0.col2 + - 90 DIV - 63 AS col0 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-2475
SELECT + cor0.col2 + - 90 / - 63 AS col0 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2476
SELECT DISTINCT ( col1 * - CAST( 7 AS SIGNED ) ) + - col0 * - ( col0 ) AS col2 FROM tab1
----
-173
4026
6309

skipif mysql # not compatible
query I rowsort label-2476
SELECT DISTINCT ( col1 * - CAST ( 7 AS INTEGER ) ) + - col0 * - ( col0 ) AS col2 FROM tab1
----
-173
4026
6309

query I rowsort
SELECT ALL - tab0.col2 + - col0 AS col1 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT ALL - col2 * col0 + + ( col1 ) AS col0 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT + 0 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

query I rowsort
SELECT ALL - - 80 AS col1 FROM tab0 AS cor0
----
80
80
80

query I rowsort
SELECT + + col0 * - col1 * + 50 AS col1 FROM tab0 AS cor0
----
-103200
-169750
-404950

query I rowsort
SELECT DISTINCT + 72 * col1 FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT - + cor0.col1 * col2 + - col0 + + col0 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT col1 * - col2 - 61 * - col0 FROM tab2 AS cor0
----
-410
3224
4173

query I rowsort
SELECT cor0.col0 * + 11 + col2 + - col2 FROM tab1 AS cor0
----
33
704
880

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to 3a31dab513390ca6bd05c71a3d9c50f0

query I rowsort
SELECT ALL + col0 + ( col2 ) * col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT + cor0.col2 * 74 + - col1 FROM tab0 AS cor0
----
-23
2356
5977

query I rowsort
SELECT - col2 * 23 + col1 AS col0 FROM tab2 cor0
----
-539
-590
-857

onlyif mysql # use DIV operator for integer division
query I rowsort label-2490
SELECT DISTINCT col2 DIV col2 + 77 col2 FROM tab0
----
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2490
SELECT DISTINCT col2 / col2 + 77 col2 FROM tab0
----
78

query I rowsort
SELECT + cor0.col0 + col0 + - col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2492
SELECT col1 * - col2 - col0 DIV col1 FROM tab2 cor0
----
-1535
-650
-837

skipif mysql # not compatible
query I rowsort label-2492
SELECT col1 * - col2 - col0 / col1 FROM tab2 cor0
----
-1535
-650
-837

query I rowsort
SELECT - col0 * + 63 + - cor0.col2 FROM tab0 AS cor0
----
-1545
-2206
-5689

query I rowsort
SELECT DISTINCT - ( col0 + - tab0.col0 ) AS col0 FROM tab0
----
0

query I rowsort
SELECT DISTINCT + + ( col2 ) + + col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL col0 + 66 FROM tab2 AS cor0
----
144
145
73

query I rowsort
SELECT + 51 AS col1 FROM tab0 cor0
----
51
51
51

query I rowsort
SELECT DISTINCT + - 71 AS col1 FROM tab0 AS cor0
----
-71

skipif mysql # not compatible
query I rowsort
SELECT ALL - - CAST ( - col2 AS REAL ) * cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-2500
SELECT - col2 + col1 DIV cor0.col0 FROM tab1 cor0
----
-46
-57
-96

skipif mysql # not compatible
query I rowsort label-2500
SELECT - col2 + col1 / cor0.col0 FROM tab1 cor0
----
-46
-57
-96

query I rowsort
SELECT DISTINCT + - col2 + - 37 * col1 FROM tab0 AS cor0
----
-3215
-3449
-3590

query I rowsort
SELECT + cor0.col2 * - col2 AS col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT - - col1 * + 6 AS col0 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT DISTINCT + 75 * col2 AS col2 FROM tab0 cor0
----
2475
6150
75

query I rowsort
SELECT + ( + col1 ) * cor0.col1 AS col0 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT ALL 24 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to dfdfceb3acab6f866df9d676c07043ad

query I rowsort
SELECT - cor0.col0 * col1 * col1 FROM tab1 cor0
----
-13520
-2028
-6400

query I rowsort
SELECT ALL + 80 AS col0 FROM tab2, tab0 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 2815a2e064e1815ac3a10bcd8b0ab19c

query I rowsort
SELECT - + 75 AS col0 FROM tab0 AS cor0
----
-75
-75
-75

query I rowsort
SELECT - ( cor0.col2 ) + 37 FROM tab2 AS cor0
----
-1
10
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 86 col1 FROM tab1 AS cor0
----
-86
-86
-86

query I rowsort
SELECT - cor0.col2 + - col1 * - col0 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT + 39 * + cor0.col2 + - col0 FROM tab1 cor0
----
2103
2159
3664

query I rowsort
SELECT DISTINCT 11 AS col2 FROM tab1
----
11

query I rowsort
SELECT - cor0.col0 + col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT 94 * col1 FROM tab2 AS cor0
----
1598
2914
5546

query I rowsort
SELECT DISTINCT col0 * col2 + col2 FROM tab1 cor0
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2518
SELECT CAST( col2 AS SIGNED ) * col0 + col0 col2 FROM tab1 cor0
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2518
SELECT CAST ( col2 AS INTEGER ) * col0 + col0 col2 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT + - col2 + - col1 * col0 FROM tab1 cor0
----
-1136
-132
-697

query I rowsort
SELECT - 31 + 20 FROM tab2 AS cor0
----
-11
-11
-11

query I rowsort
SELECT DISTINCT - 33 * cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-231
-2574
-2607

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + col0 AS REAL ) + col1 AS col2 FROM tab0 AS cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 27 + 83 col0 FROM tab2
----
-106
-2023
-2050

query I rowsort
SELECT DISTINCT + + cor0.col1 * 73 + - col1 FROM tab1 AS cor0
----
1872
720
936

onlyif mysql # use DIV operator for integer division
query I rowsort label-2525
SELECT - col1 DIV + col1 + + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-2525
SELECT - col1 / + col1 + + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT ALL - col0 + - cor0.col0 * col0 FROM tab0 cor0
----
-1260
-600
-8010

query I rowsort
SELECT - + 13 AS col0 FROM tab0 AS cor0
----
-13
-13
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-2528
SELECT - col1 * 85 DIV cor0.col2 FROM tab1 cor0
----
-11
-14
-40

skipif mysql # not compatible
query I rowsort label-2528
SELECT - col1 * 85 / cor0.col2 FROM tab1 cor0
----
-11
-14
-40

query I rowsort
SELECT DISTINCT - + cor0.col1 AS col2 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT - col1 * 80 FROM tab0
----
-6880
-7280
-7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2531
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2531
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
NULL

query I rowsort
SELECT - + 69 + - col1 * col0 FROM tab0 AS cor0
----
-2133
-3464
-8168

query I rowsort
SELECT ALL - cor0.col0 + - 93 AS col2 FROM tab2 AS cor0
----
-100
-171
-172

query I rowsort
SELECT DISTINCT + col1 * + 84 * ( + col0 * + col0 ) FROM tab0 AS cor0
----
4161024
60548124
9981300

query I rowsort
SELECT ALL col1 * - cor0.col0 * - col2 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-2536
SELECT DISTINCT - + col0 + - col2 * 71 DIV + col0 AS col1 FROM tab1 AS cor0
----
-127
-1281
-165

skipif mysql # not compatible
query I rowsort label-2536
SELECT DISTINCT - + col0 + - col2 * 71 / + col0 AS col1 FROM tab1 AS cor0
----
-127
-1281
-165

query I rowsort
SELECT col2 + + col0 * + cor0.col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col0 * + col1 + col1 * - cor0.col0 * col0 FROM tab1 AS cor0
----
-156
-40320
-82160

onlyif mysql # use DIV operator for integer division
query I rowsort label-2539
SELECT - + col1 DIV - 40 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2539
SELECT - + col1 / - 40 FROM tab2 AS cor0
----
0
0
1

query I rowsort
SELECT ALL - col0 * + 94 FROM tab1 AS cor0
----
-282
-6016
-7520

query I rowsort
SELECT ALL - tab0.col1 * + col2 + - 60 AS col2 FROM tab0
----
-157
-2898
-7522

query I rowsort
SELECT ALL 87 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT ALL 98 * + tab0.col2 FROM tab0
----
3234
8036
98

query I rowsort
SELECT DISTINCT col1 - + col0 FROM tab0 AS cor0
----
2
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 + - ( col2 ) col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT col2 + + cor0.col1 * col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT - + col2 * 53 + - col0 * + col2 * - col0 + col1 AS col2 FROM tab2 AS cor0
----
-77
156865
235161

query I rowsort
SELECT ALL - col1 + - 43 * col0 + cor0.col2 AS col0 FROM tab0 AS cor0
----
-1085
-1601
-3836

query I rowsort
SELECT DISTINCT + - col2 * col1 + 71 FROM tab2 AS cor0
----
-1463
-575
-766

query I rowsort
SELECT + - cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2551
SELECT DISTINCT - col1 DIV col1 + col0 * col2 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1224
19007
649521

skipif mysql # not compatible
query I rowsort label-2551
SELECT DISTINCT - col1 / col1 + col0 * col2 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1224
19007
649521

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2552
SELECT ALL + col2 + - CAST( NULL AS SIGNED ) * - col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2552
SELECT ALL + col2 + - CAST ( NULL AS INTEGER ) * - col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 2 * - cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 66e198acca624efd182aa551bb5de4c7

query I rowsort
SELECT col0 + + col1 + col1 AS col0 FROM tab2
----
113
196
69

query I rowsort
SELECT DISTINCT col1 * col1 + col1 * col2 FROM tab1
----
1417
2080
670

query I rowsort
SELECT + 80 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT - col2 * - 61 * - col0 FROM tab2
----
-11529
-123708
-183122

query I rowsort
SELECT + ( + 1 ) * + col0 + cor0.col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - tab2.col1 + col0 AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT col1 + ( + col1 ) AS col1 FROM tab2
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2561
SELECT - col0 DIV 68 + col0 DIV tab0.col0 FROM tab0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2561
SELECT - col0 / 68 + col0 / tab0.col0 FROM tab0
----
0
1
1

query I rowsort
SELECT DISTINCT + col0 * 51 AS col1 FROM tab0
----
1224
1785
4539

onlyif mysql # use DIV operator for integer division
query I rowsort label-2563
SELECT DISTINCT col2 * col0 DIV - col1 FROM tab1 AS cor0
----
-364
-590
-6

skipif mysql # not compatible
query I rowsort label-2563
SELECT DISTINCT col2 * col0 / - col1 FROM tab1 AS cor0
----
-364
-590
-6

query I rowsort
SELECT - + 53 - - col0 FROM tab2 AS cor0
----
-46
25
26

query I rowsort
SELECT + + 21 * col0 - 16 FROM tab1 cor0
----
1328
1664
47

query I rowsort
SELECT DISTINCT - 6 + col0 FROM tab2 AS cor0
----
1
72
73

query I rowsort
SELECT DISTINCT + + col2 - col2 * - col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL 65 * cor0.col1 FROM tab1 AS cor0
----
1690
650
845

query I rowsort
SELECT - 30 - cor0.col1 * - col1 AS col1 FROM tab2 AS cor0
----
259
3451
931

query I rowsort
SELECT ( - ( + col2 ) ) - 96 FROM tab2
----
-122
-123
-134

onlyif mysql # use DIV operator for integer division
query I rowsort label-2571
SELECT DISTINCT + col0 + col2 DIV + col1 FROM tab2 AS cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-2571
SELECT DISTINCT + col0 + col2 / + col1 FROM tab2 AS cor0
----
7
78
81

query I rowsort
SELECT ALL col2 * + col1 + - col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT ALL - col0 - col0 * - 62 FROM tab0 AS cor0
----
1464
2135
5429

query I rowsort
SELECT ALL 84 + + col0 AS col0 FROM tab2 cor0
----
162
163
91

query I rowsort
SELECT + col0 + col0 * 21 AS col1 FROM tab1 cor0
----
1408
1760
66

query I rowsort
SELECT ALL + + col0 - - col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL ( + col0 ) + + ( - col0 ) AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - 35 * + col1 FROM tab1 cor0
----
-350
-455
-910

query I rowsort
SELECT - col1 + col2 * - col1 FROM tab2 cor0
----
-1593
-663
-868

query I rowsort
SELECT - col1 * - col0 + 11 FROM tab0 AS cor0
----
2075
3406
8110

query I rowsort
SELECT + tab0.col1 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL col1 * 34 FROM tab1
----
340
442
884

query I rowsort
SELECT - tab2.col0 + col1 * col0 AS col1 FROM tab2
----
1264
210
4524

query I rowsort
SELECT - 15 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2585
SELECT CAST( + col2 AS SIGNED ) col1 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2585
SELECT CAST ( + col2 AS INTEGER ) col1 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + ( 49 ) AS col2 FROM tab0 AS cor0
----
49
49
49

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( col2 AS REAL ) + + col1 * col1 AS col0 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT DISTINCT - ( + col2 ) + - col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT - col1 + col1 - col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT 56 * - 57 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
-3192

query I rowsort
SELECT + + 14 * + col1 FROM tab0 AS cor0
----
1204
1274
1358

query I rowsort
SELECT DISTINCT 69 * + col0 AS col1 FROM tab1 AS cor0
----
207
4416
5520

query I rowsort
SELECT ALL - 64 * cor0.col2 FROM tab2 AS cor0
----
-1664
-1728
-2432

query I rowsort
SELECT + cor0.col0 * - col0 + 47 FROM tab2 cor0
----
-2
-6037
-6194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 79 col1 FROM tab0 cor0
----
-79
-79
-79

query I rowsort
SELECT DISTINCT - 70 * col1 AS col2 FROM tab1 AS cor0
----
-1820
-700
-910

onlyif mysql # use DIV operator for integer division
query I rowsort label-2598
SELECT + col2 * col1 DIV + col0 + col0 FROM tab0 AS cor0
----
142
172
37

skipif mysql # not compatible
query I rowsort label-2598
SELECT + col2 * col1 / + col0 + col0 FROM tab0 AS cor0
----
142
172
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * col0 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - 71 + - col0 FROM tab2 AS cor0
----
-149
-150
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 23 * col1 col2 FROM tab1 AS cor0
----
230
299
598

query I rowsort
SELECT + + col2 * col2 * ( col0 * + col1 ) FROM tab2 cor0
----
158193
1939292
3110952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2603
SELECT ALL - + col2 + + CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2603
SELECT ALL - + col2 + + CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 + - 38 FROM tab1 AS cor0
----
-134
-92
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 69 col2 FROM tab1, tab2 cor0
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * + col2 col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - - col0 + - col2 AS col0 FROM tab2 cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2608
SELECT + CAST( - col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-2608
SELECT + CAST ( - col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab0 AS cor1, tab2 cor2
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT - + 58 * col1 * - col0 FROM tab0 AS cor0
----
119712
196910
469742

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2611
SELECT + 2 + col1 / CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2611
SELECT + 2 + col1 / CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 * + col1 + + col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-2613
SELECT ( - 78 ) DIV col0 FROM tab0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-2613
SELECT ( - 78 ) / col0 FROM tab0
----
-2
-3
0

query I rowsort
SELECT + col1 * col0 + col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT cor0.col2 + 5 * + col2 AS col1 FROM tab0 AS cor0
----
198
492
6

query I rowsort
SELECT ALL col0 + col0 * 22 AS col2 FROM tab2
----
161
1794
1817

query I rowsort
SELECT 63 AS col2 FROM tab2
----
63
63
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-2618
SELECT + col1 DIV col0 col1 FROM tab1
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2618
SELECT + col1 / col0 col1 FROM tab1
----
0
0
8

query I rowsort
SELECT 85 FROM tab2, tab1 cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

onlyif mysql # use DIV operator for integer division
query I rowsort label-2620
SELECT DISTINCT - 2 DIV + col0 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2620
SELECT DISTINCT - 2 / + col0 AS col1 FROM tab1 AS cor0
----
0

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0 cor1, tab2 AS cor2
----
3645 values hashing to da83d3eeaeb9e24a3cb14bb7058757dd

query I rowsort
SELECT - 16 + col1 AS col2 FROM tab1 cor0
----
-3
-6
10

query I rowsort
SELECT ( ( + col1 ) ) + 62 FROM tab0 AS cor0
----
148
153
159

query I rowsort
SELECT col0 * + col1 + - cor0.col0 FROM tab1 cor0
----
576
75
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 - + col0 * - col1 col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT col0 * + col0 + - 98 AS col1 FROM tab2 AS cor0
----
-49
5986
6143

query I rowsort
SELECT DISTINCT - col0 - col1 AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT cor0.col0 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to 63f734facb33901524f6f2c799118db4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 90 * - col1 + ( + cor0.col0 ) col0 FROM tab1 AS cor0
----
-1090
-2337
-836

query I rowsort
SELECT ALL - col2 * - col2 * - 60 + + col1 AS col0 FROM tab2 AS cor0
----
-40501
-43709
-86623

onlyif mysql # use DIV operator for integer division
query I rowsort label-2631
SELECT DISTINCT 42 + col2 * ( col2 ) DIV - col0 FROM tab1 cor0
----
-73
-8
-930

skipif mysql # not compatible
query I rowsort label-2631
SELECT DISTINCT 42 + col2 * ( col2 ) / - col0 FROM tab1 cor0
----
-73
-8
-930

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2632
SELECT col2 * + CAST( NULL AS DECIMAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2632
SELECT col2 * + CAST ( NULL AS REAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 - - tab0.col0 * 94 * + col1 AS col0 FROM tab0
----
194040
319165
761395

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col1 - - 81 col2 FROM tab2
----
112
140
98

query I rowsort
SELECT col0 * col1 - - col2 FROM tab0 AS cor0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 * - 91 * - col2 col1 FROM tab0
----
-258258
-679042
-8827

query I rowsort
SELECT - col0 * 91 FROM tab0
----
-2184
-3185
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + ( ( col1 ) ) col2 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2639
SELECT ALL - + CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2639
SELECT ALL - + CAST ( NULL AS INTEGER ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2640
SELECT ( ( col2 ) ) + - ( cor0.col1 ) + col1 DIV + col0 AS col2 FROM tab0 AS cor0
----
-50
-8
-94

skipif mysql # not compatible
query I rowsort label-2640
SELECT ( ( col2 ) ) + - ( cor0.col1 ) + col1 / + col0 AS col2 FROM tab0 AS cor0
----
-50
-8
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-2641
SELECT - col0 + col0 DIV col0 - ( - 19 ) FROM tab0 AS cor0
----
-15
-4
-69

skipif mysql # not compatible
query I rowsort label-2641
SELECT - col0 + col0 / col0 - ( - 19 ) FROM tab0 AS cor0
----
-15
-4
-69

query I rowsort
SELECT DISTINCT + col0 + + col2 * + col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT 54 + cor0.col2 - + col1 * 65 FROM tab2 AS cor0
----
-1013
-1934
-3755

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * + col1 col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - 86 + col2 * col1 + + col1 AS col2 FROM tab1 cor0
----
1175
1344
494

query I rowsort
SELECT DISTINCT col1 * ( + ( col2 ) ) * - col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT col2 * 95 * col0 FROM tab0
----
3325
693310
75240

query I rowsort
SELECT DISTINCT + col0 + col0 + - col2 FROM tab1 AS cor0
----
-48
64
71

query I rowsort
SELECT col0 + - cor0.col1 + col0 * - ( - cor0.col1 ) AS col1 FROM tab0 AS cor0
----
2002
3333
8097

query I rowsort
SELECT + cor0.col2 + + cor0.col2 * cor0.col2 * cor0.col1 - col1 * - col1 AS col0 FROM tab0 AS cor0
----
101083
620247
9507

query I rowsort
SELECT DISTINCT - 70 * - 39 FROM tab0 AS cor0
----
2730

onlyif mysql # use DIV operator for integer division
query I rowsort label-2652
SELECT ALL + CAST( - 63 AS SIGNED ) + + col1 DIV + col2 AS col0 FROM tab0
----
-61
-62
34

skipif mysql # not compatible
query I rowsort label-2652
SELECT ALL + CAST ( - 63 AS INTEGER ) + + col1 / + col2 AS col0 FROM tab0
----
-61
-62
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2653
SELECT DISTINCT tab1.col2 DIV col1 + tab1.col2 FROM tab1
----
103
56
62

skipif mysql # not compatible
query I rowsort label-2653
SELECT DISTINCT tab1.col2 / col1 + tab1.col2 FROM tab1
----
103
56
62

query I rowsort
SELECT ALL + 4 FROM tab0 cor0
----
4
4
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2655
SELECT ALL - CAST( NULL AS SIGNED ) * - col2 + col0 * + CAST( + col2 * col2 AS SIGNED ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2655
SELECT ALL - CAST ( NULL AS INTEGER ) * - col2 + col0 * + CAST ( + col2 * col2 AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2656
SELECT ALL CAST( NULL AS SIGNED ) + + col0 * + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2656
SELECT ALL CAST ( NULL AS INTEGER ) + + col0 * + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 71 AS col1 FROM tab0 cor0
----
71
71
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2658
SELECT DISTINCT + - CAST( + col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-2658
SELECT DISTINCT + - CAST ( + col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 9 col1 FROM tab1, tab2 cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2660
SELECT ALL - CAST( NULL AS DECIMAL ) * - col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2660
SELECT ALL - CAST ( NULL AS REAL ) * - col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col1 col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - 86 AS col0 FROM tab1 cor0
----
-86
-86
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2663
SELECT DISTINCT CAST( NULL AS SIGNED ) * + tab2.col0 + + col1 AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2663
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + tab2.col0 + + col1 AS col2 FROM tab2
----
NULL

query I rowsort
SELECT ALL + 90 * 17 + + col1 FROM tab0
----
1616
1621
1627

query I rowsort
SELECT - - 23 + col2 AS col2 FROM tab2 AS cor0
----
49
50
61

query I rowsort
SELECT ALL 2 + + cor0.col0 * + col2 FROM tab0 AS cor0
----
37
7300
794

onlyif mysql # use DIV operator for integer division
query I rowsort label-2667
SELECT - - col0 DIV col0 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2667
SELECT - - col0 / col0 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT ALL - 72 * col2 + col0 FROM tab0 AS cor0
----
-2352
-37
-5815

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2669
SELECT ALL - CAST( NULL AS SIGNED ) * col0 + - col2 + 68 * col0 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2669
SELECT ALL - CAST ( NULL AS INTEGER ) * col0 + - col2 + 68 * col0 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * + col1 + col1 * + tab0.col1 - - col1 * tab0.col0 AS col1 FROM tab0
----
12298
12901
23842

query I rowsort
SELECT ALL ( - 8 ) + + col0 AS col2 FROM tab0
----
16
27
81

query I rowsort
SELECT ALL + - col2 * cor0.col1 - - col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL + col2 * 96 + + 11 + col1 FROM tab2 cor0
----
2566
2634
3676

query I rowsort
SELECT ALL + col1 * ( - 86 ) * - col1 AS col1 FROM tab1 AS cor0
----
14534
58136
8600

query I rowsort
SELECT DISTINCT + - col1 * - 75 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
1237
2298
4399

query I rowsort
SELECT DISTINCT + col0 + + 93 + 27 * col1 FROM tab1 AS cor0
----
427
524
798

query I rowsort
SELECT ALL col1 - + ( + ( + col2 ) ) * 9 FROM tab1 AS cor0
----
-460
-503
-851

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 * - col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT - cor0.col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT - 52 - col2 * + tab2.col1 AS col0 FROM tab2
----
-1586
-698
-889

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2, tab1 cor3
----
3645 values hashing to d5761ba4e40f0c65536d1d3c9de4e566

query I rowsort
SELECT DISTINCT - col0 + col1 + col0 * + col0 AS col0 FROM tab2 AS cor0
----
6065
6179
73

query I rowsort
SELECT ALL + col1 * 95 * + col0 AS col0 FROM tab0 AS cor0
----
196080
322525
769405

query I rowsort
SELECT DISTINCT - col2 + + cor0.col2 + + col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT + col1 + 14 AS col1 FROM tab1
----
24
27
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-2686
SELECT 8 + - col2 * ( col1 ) DIV col1 AS col2 FROM tab1 AS cor0
----
-46
-49
-88

skipif mysql # not compatible
query I rowsort label-2686
SELECT 8 + - col2 * ( col1 ) / col1 AS col2 FROM tab1 AS cor0
----
-46
-49
-88

query I rowsort
SELECT + col1 + + col1 + + 71 AS col2 FROM tab0 AS cor0
----
243
253
265

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - 89 col2 FROM tab1 AS cor0
----
4806
5073
8544

onlyif mysql # use DIV operator for integer division
query I rowsort label-2689
SELECT col2 * ( + col2 ) DIV cor0.col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2689
SELECT col2 * ( + col2 ) / cor0.col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL 37 AS col2 FROM tab0
----
37
37
37

query I rowsort
SELECT ALL - 88 AS col1 FROM tab0
----
-88
-88
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2692
SELECT ALL CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2692
SELECT ALL CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 63 * - col1 AS col1 FROM tab1 AS cor0
----
-1638
-630
-819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2694
SELECT - CAST( - col1 AS SIGNED ) * col0 + - 6 FROM tab2 AS cor0
----
1337
211
4596

skipif mysql # not compatible
query I rowsort label-2694
SELECT - CAST ( - col1 AS INTEGER ) * col0 + - 6 FROM tab2 AS cor0
----
1337
211
4596

query I rowsort
SELECT col2 + 69 * col2 FROM tab0 AS cor0
----
2310
5740
70

query I rowsort
SELECT + + 34 * - col1 + col1 * + 64 AS col2 FROM tab0 cor0
----
2580
2730
2910

query I rowsort
SELECT + 16 * + ( col2 ) + + 92 AS col1 FROM tab2 AS cor0
----
508
524
700

query I rowsort
SELECT + tab2.col2 + col0 + - 22 AS col1 FROM tab2
----
12
82
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2699
SELECT + col2 + col2 * - col1 + + col0 DIV + 60 FROM tab2
----
-1507
-607
-810

skipif mysql # not compatible
query I rowsort label-2699
SELECT + col2 + col2 * - col1 + + col0 / + 60 FROM tab2
----
-1507
-607
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2700
SELECT ALL tab2.col0 * CAST( NULL AS DECIMAL ) * 68 + - col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2700
SELECT ALL tab2.col0 * CAST ( NULL AS REAL ) * 68 + - col0 AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2701
SELECT col2 DIV - 35 AS col1 FROM tab0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2701
SELECT col2 / - 35 AS col1 FROM tab0
----
-2
0
0

query I rowsort
SELECT ALL col1 * - col0 + tab0.col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - 75 + - cor0.col1 * 37 FROM tab1, tab1 AS cor0
----
-1037
-445
-556

query I rowsort
SELECT - 43 AS col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT DISTINCT - + 43 * + 46 AS col0 FROM tab0 AS cor0
----
-1978

query I rowsort
SELECT + col2 * 14 FROM tab2 AS cor0
----
364
378
532

query I rowsort
SELECT ALL + 99 + col2 AS col0 FROM tab0 cor0
----
100
132
181

onlyif mysql # use DIV operator for integer division
query I rowsort label-2708
SELECT ALL + col0 DIV + ( + col0 ) AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2708
SELECT ALL + col0 / + ( + col0 ) AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT col0 * + col0 + - col2 FROM tab2 cor0
----
22
6058
6203

query I rowsort
SELECT - 31 - 50 AS col2 FROM tab2 AS cor0
----
-81
-81
-81

query I rowsort
SELECT + - 37 * cor0.col0 + col0 AS col1 FROM tab0 AS cor0
----
-1260
-3204
-864

query I rowsort
SELECT DISTINCT - col2 * - col2 - col1 AS col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT col0 + - col2 * - col2 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT - + 55 AS col2 FROM tab1 AS cor0
----
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-2715
SELECT - + 46 DIV - col2 FROM tab0 AS cor0
----
0
1
46

skipif mysql # not compatible
query I rowsort label-2715
SELECT - + 46 / - col2 FROM tab0 AS cor0
----
0
1
46

query I rowsort
SELECT + 65 * col2 + - col1 + + col0 FROM tab0 AS cor0
----
2083
3
5328

query I rowsort
SELECT + 33 * 39 FROM tab0
----
1287
1287
1287

query I rowsort
SELECT DISTINCT 71 AS col0 FROM tab0
----
71

query I rowsort
SELECT - 56 * - col2 FROM tab1
----
3024
3192
5376

onlyif mysql # use DIV operator for integer division
query I rowsort label-2720
SELECT ALL + col1 * col1 + col0 * - col0 + + col1 DIV + col0 AS col2 FROM tab2 AS cor0
----
-2603
-5952
916

skipif mysql # not compatible
query I rowsort label-2720
SELECT ALL + col1 * col1 + col0 * - col0 + + col1 / + col0 AS col2 FROM tab2 AS cor0
----
-2603
-5952
916

query I rowsort
SELECT + col0 * col2 AS col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL - 70 * col1 - - col0 AS col0 FROM tab2 AS cor0
----
-1111
-2163
-4052

query I rowsort
SELECT DISTINCT ( - col2 ) * + col2 + + col1 AS col0 FROM tab2 cor0
----
-1427
-617
-698

query I rowsort
SELECT - col2 * - 90 FROM tab2
----
2340
2430
3420

query I rowsort
SELECT + col2 + col2 * - col1 FROM tab0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2726
SELECT col0 + + col2 DIV + col0 + - col2 col1 FROM tab2
----
-17
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2726
SELECT col0 + + col2 / + col0 + - col2 col1 FROM tab2
----
-17
41
52

query I rowsort
SELECT 30 * col2 AS col0 FROM tab0
----
2460
30
990

onlyif mysql # use DIV operator for integer division
query I rowsort label-2728
SELECT 64 DIV col1 AS col1 FROM tab1
----
2
4
6

skipif mysql # not compatible
query I rowsort label-2728
SELECT 64 / col1 AS col1 FROM tab1
----
2
4
6

query I rowsort
SELECT + 92 * + tab2.col1 * tab2.col2 - - col0 AS col1 FROM tab2
----
141206
59511
77011

onlyif mysql # use DIV operator for integer division
query I rowsort label-2730
SELECT - col2 + col1 DIV col0 AS col2 FROM tab0 cor0
----
-30
-81
1

skipif mysql # not compatible
query I rowsort label-2730
SELECT - col2 + col1 / col0 AS col2 FROM tab0 cor0
----
-30
-81
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 + col0 col1 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL + 23 + + col0 + col1 AS col0 FROM tab0 AS cor0
----
133
155
203

onlyif mysql # use DIV operator for integer division
query I rowsort label-2733
SELECT DISTINCT col2 DIV + 78 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-2733
SELECT DISTINCT col2 / + 78 FROM tab0
----
0
1

query I rowsort
SELECT cor0.col2 + 2 FROM tab2 AS cor0
----
28
29
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-2735
SELECT + cor0.col0 * col2 DIV - 57 FROM tab2 cor0
----
-3
-35
-52

skipif mysql # not compatible
query I rowsort label-2735
SELECT + cor0.col0 * col2 / - 57 FROM tab2 cor0
----
-3
-35
-52

query I rowsort
SELECT - - 99 + - cor0.col1 * - col0 + + col1 AS col1 FROM tab2 AS cor0
----
1459
347
4760

query I rowsort
SELECT - - ( + col2 ) * + col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL cor0.col1 AS col2 FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 42 ) col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 9894093f29c0defae91347934f060329

query I rowsort
SELECT col0 * + 29 + cor0.col0 AS col0 FROM tab1 AS cor0
----
1920
2400
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2741
SELECT + 97 * cor0.col1 DIV - col0 FROM tab2 cor0
----
-20
-429
-73

skipif mysql # not compatible
query I rowsort label-2741
SELECT + 97 * cor0.col1 / - col0 FROM tab2 cor0
----
-20
-429
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2742
SELECT + CAST( + col0 AS SIGNED ) * + col1 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-2742
SELECT + CAST ( + col0 AS INTEGER ) * + col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col2 + - ( ( - col1 ) ) * + col2 AS col2 FROM tab1 cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-2744
SELECT - col2 * - col0 + col0 DIV col0 AS col2 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-2744
SELECT - col2 * - col0 + col0 / col0 AS col2 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT DISTINCT - - cor0.col1 * 74 + - col2 AS col2 FROM tab0 AS cor0
----
6331
6652
7177

query I rowsort
SELECT - - col0 * + ( cor0.col2 ) + col0 - 35 FROM tab2 AS cor0
----
161
2071
3046

query I rowsort
SELECT DISTINCT col1 + - 70 * - 94 FROM tab0 AS cor0
----
6666
6671
6677

query I rowsort
SELECT - + cor0.col1 + - col2 * 91 AS col1 FROM tab1 AS cor0
----
-4940
-5197
-8749

query I rowsort
SELECT + + col2 * col2 * - col2 + + col1 AS col1 FROM tab0 AS cor0
----
-35851
-551277
96

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 + CAST ( col0 AS REAL ) * cor0.col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL col0 + ( - col1 + - cor0.col1 * - ( - col1 ) ) FROM tab0 AS cor0
----
-7458
-8283
-9471

query I rowsort
SELECT 98 * + ( cor0.col2 ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 955a20ecd6f2a10a9bc6a1cf70f173e7

query I rowsort
SELECT - 89 + - col2 - - col2 FROM tab1
----
-89
-89
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 - cor0.col0 * cor0.col0 col1 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 col1 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + ( col1 * col1 ) col0 FROM tab1 cor0
----
36
673
89

query I rowsort
SELECT DISTINCT + + col1 * col2 + + 92 * col2 - + 20 FROM tab1 AS cor0
----
10060
5794
6352

query I rowsort
SELECT DISTINCT + col1 + col2 AS col2 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2759
SELECT col0 * ( + 39 ) * tab0.col0 + 63 DIV - col0 AS col1 FROM tab0
----
22462
308919
47774

skipif mysql # not compatible
query I rowsort label-2759
SELECT col0 * ( + 39 ) * tab0.col0 + 63 / - col0 AS col1 FROM tab0
----
22462
308919
47774

query I rowsort
SELECT DISTINCT 1 * + 67 FROM tab2, tab1 AS cor0
----
67

query I rowsort
SELECT ALL - + col1 * + 60 AS col2 FROM tab0 AS cor0
----
-5160
-5460
-5820

query I rowsort
SELECT + ( col0 ) * col1 + col0 * col0 AS col0 FROM tab1 AS cor0
----
4736
7440
87

query I rowsort
SELECT - cor1.col0 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2764
SELECT - col1 + CAST( NULL AS DECIMAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2764
SELECT - col1 + CAST ( NULL AS REAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2765
SELECT + + col0 DIV 8 + col2 DIV + col2 FROM tab0 AS cor0
----
12
4
5

skipif mysql # not compatible
query I rowsort label-2765
SELECT + + col0 / 8 + col2 / + col2 FROM tab0 AS cor0
----
12
4
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 + col1 * + col1 col2 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT - col0 + - col2 * 52 FROM tab2 AS cor0
----
-1411
-1430
-2055

query I rowsort
SELECT ALL col1 * - 34 * col2 FROM tab2
----
-21964
-28458
-52156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 22 + + col1 + 23 * 7 col2 FROM tab1
----
193
196
209

query I rowsort
SELECT + 1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2771
SELECT + 84 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2771
SELECT + 84 / col1 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2772
SELECT DISTINCT col2 * + col1 - - CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2772
SELECT DISTINCT col2 * + col1 - - CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab1
----
NULL

query I rowsort
SELECT 38 * - col2 + + col0 * tab0.col1 + + col1 FROM tab0
----
3454
5074
896

query I rowsort
SELECT - cor0.col1 * + col1 + - ( + 0 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + ( - col0 ) * cor0.col0 + - col1 * - col1 AS col0 FROM tab1 AS cor0
----
-3996
-6231
667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * col2 col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + 62 * col1 * ( 58 ) FROM tab2
----
111476
212164
61132

query I rowsort
SELECT ALL - col2 * col1 * + ( col2 ) FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT + - 5 * col2 FROM tab1 cor0
----
-270
-285
-480

query I rowsort
SELECT ALL + col0 * + col2 + 8 * + col1 * - col2 AS col2 FROM tab2 cor0
----
-10244
-2166
-6507

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 * 18 col0 FROM tab2 AS cor0
----
-11628
-15066
-27612

query I rowsort
SELECT ALL + + 67 + col0 FROM tab1 AS cor0
----
131
147
70

query I rowsort
SELECT - 27 * col1 FROM tab2 AS cor0
----
-1593
-459
-837

query I rowsort
SELECT DISTINCT - - 28 - col0 FROM tab1 AS cor0
----
-36
-52
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col2 col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + 24 AS col1 FROM tab1
----
24
24
24

query I rowsort
SELECT - 96 AS col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to a7b3e5dd01c8929180b7ffda67f79798

query I rowsort
SELECT ALL + 24 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT col2 + - cor0.col1 * + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + col0 * 7 AS col0 FROM tab0 AS cor0
----
168
245
623

onlyif mysql # use DIV operator for integer division
query I rowsort label-2791
SELECT DISTINCT col0 DIV col1 + + col0 * - col1 AS col0 FROM tab0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-2791
SELECT DISTINCT col0 / col1 + + col0 * - col1 AS col0 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2792
SELECT col2 DIV - 35 AS col0 FROM tab2
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2792
SELECT col2 / - 35 AS col0 FROM tab2
----
-1
0
0

query I rowsort
SELECT DISTINCT col1 * - 49 FROM tab2 AS cor0
----
-1519
-2891
-833

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2794
SELECT + - col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2794
SELECT + - col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 36 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
-36

query I rowsort
SELECT DISTINCT - - 97 * col0 AS col1 FROM tab2 AS cor0
----
679
7566
7663

query I rowsort
SELECT ALL ( - 20 ) * - col0 + + col0 * + cor0.col0 * col2 FROM tab0 AS cor0
----
1925
19488
651302

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2798
SELECT + CAST( + col0 AS SIGNED ) + col1 AS col0 FROM tab2
----
137
38
96

skipif mysql # not compatible
query I rowsort label-2798
SELECT + CAST ( + col0 AS INTEGER ) + col1 AS col0 FROM tab2
----
137
38
96

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col0 AS REAL ) AS col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL + ( 43 ) FROM tab1 AS cor0
----
43
43
43

query I rowsort
SELECT + cor0.col1 + - col0 * col2 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2802
SELECT + CAST( NULL AS SIGNED ) + 75 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2802
SELECT + CAST ( NULL AS INTEGER ) + 75 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( - col2 ) * col1 + + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT - - 24 + - col0 AS col0 FROM tab1 AS cor0
----
-40
-56
21

query I rowsort
SELECT + - col2 + ( + col1 ) AS col0 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2806
SELECT + col0 DIV col0 + - col2 DIV + 94 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2806
SELECT + col0 / col0 + - col2 / + 94 FROM tab1 AS cor0
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2807
SELECT col0 + + col1 * CAST( - ( col0 ) * - col0 + cor0.col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
106465
2487
362515

skipif mysql # not compatible
query I rowsort label-2807
SELECT col0 + + col1 * CAST ( - ( col0 ) * - col0 + cor0.col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
106465
2487
362515

query I rowsort
SELECT ALL + - 38 + - col0 * - ( col2 ) AS col1 FROM tab0 AS cor0
----
-3
7260
754

query I rowsort
SELECT col0 * + col0 AS col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT ALL - 45 * - col0 * col0 AS col2 FROM tab2 AS cor0
----
2205
273780
280845

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col0 col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - - col2 * col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT 45 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT col1 * 42 FROM tab1
----
1092
420
546

query I rowsort
SELECT - 27 * - col0 * col1 - col2 * col2 FROM tab1
----
-810
14031
18864

query I rowsort
SELECT DISTINCT + 75 * + 50 AS col2 FROM tab1 AS cor0
----
3750

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2817
SELECT ALL - - CAST( ( col2 ) AS SIGNED ) * CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2817
SELECT ALL - - CAST ( ( col2 ) AS INTEGER ) * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2818
SELECT + col2 DIV - 9 col0 FROM tab0 cor0
----
-3
-9
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2818
SELECT + col2 / - 9 col0 FROM tab0 cor0
----
-3
-9
0

query I rowsort
SELECT DISTINCT ( + col1 + + col2 ) AS col1 FROM tab2
----
55
58
85

query I rowsort
SELECT ( col0 ) + cor0.col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - col2 + col0 * ( 81 ) FROM tab1 AS cor0
----
189
5127
6384

onlyif mysql # use DIV operator for integer division
query I rowsort label-2822
SELECT col1 + col0 * + col1 DIV col1 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-2822
SELECT col1 + col0 * + col1 / col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + 44 * col2 + col1 AS col1 FROM tab1 AS cor0
----
2402
2518
4237

onlyif mysql # use DIV operator for integer division
query I rowsort label-2824
SELECT col2 * col2 DIV - col2 + - col1 + - 63 * tab0.col0 FROM tab0
----
-1631
-2303
-5780

skipif mysql # not compatible
query I rowsort label-2824
SELECT col2 * col2 / - col2 + - col1 + - 63 * tab0.col0 FROM tab0
----
-1631
-2303
-5780

onlyif mysql # use DIV operator for integer division
query I rowsort label-2825
SELECT ALL - - cor0.col2 + + ( - col1 ) DIV col2 FROM tab0 AS cor0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-2825
SELECT ALL - - cor0.col2 + + ( - col1 ) / col2 FROM tab0 AS cor0
----
-96
31
81

query I rowsort
SELECT - cor0.col0 * + 43 FROM tab2 AS cor0
----
-301
-3354
-3397

onlyif mysql # use DIV operator for integer division
query I rowsort label-2827
SELECT DISTINCT col1 DIV 97 + col1 AS col1 FROM tab0 AS cor0
----
86
91
98

skipif mysql # not compatible
query I rowsort label-2827
SELECT DISTINCT col1 / 97 + col1 AS col1 FROM tab0 AS cor0
----
86
91
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + - col2 + col0 col2 FROM tab2 AS cor0
----
-47
26
3

query I rowsort
SELECT ALL - + col1 + + 14 FROM tab2 AS cor0
----
-17
-3
-45

query I rowsort
SELECT DISTINCT col0 + 5 * col0 AS col1 FROM tab0 AS cor0
----
144
210
534

onlyif mysql # use DIV operator for integer division
query I rowsort label-2831
SELECT ALL + - col1 + 3 DIV col1 + - cor0.col0 FROM tab0 AS cor0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-2831
SELECT ALL + - col1 + 3 / col1 + - cor0.col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - col1 + - 92 FROM tab2 AS cor0
----
-109
-123
-151

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2833
SELECT - col1 / col2 + + CAST( NULL AS SIGNED ) * + tab0.col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2833
SELECT - col1 / col2 + + CAST ( NULL AS INTEGER ) * + tab0.col0 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 72 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT ( col2 * 47 ) AS col1 FROM tab1
----
2538
2679
4512

query I rowsort
SELECT - col0 * col1 - + 69 FROM tab0
----
-2133
-3464
-8168

query I rowsort
SELECT + col1 * col1 + - col0 AS col2 FROM tab0
----
7372
8192
9374

query I rowsort
SELECT - col0 * cor0.col2 AS col2 FROM tab0 cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2839
SELECT + col2 + 19 DIV + cor0.col1 AS col2 FROM tab2 AS cor0
----
26
27
39

skipif mysql # not compatible
query I rowsort label-2839
SELECT + col2 + 19 / + cor0.col1 AS col2 FROM tab2 AS cor0
----
26
27
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-2840
SELECT + col0 * col1 DIV - 22 + + col1 * col1 + + col0 FROM tab1
----
135
202
676

skipif mysql # not compatible
query I rowsort label-2840
SELECT + col0 * col1 / - 22 + + col1 * col1 + + col0 FROM tab1
----
135
202
676

query I rowsort
SELECT DISTINCT - 27 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2
----
-27

query I rowsort
SELECT - ( ( - col2 ) ) + + col2 AS col0 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT ALL - 39 * - cor0.col0 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 3a348112fdd91fe2b3539c63b529c830

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to c04c36412775e8805d6b3befa2f52917

query I rowsort
SELECT DISTINCT col0 * tab0.col2 + col1 + - col0 FROM tab0
----
7300
854
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2846
SELECT + CAST( NULL AS SIGNED ) * - col2 * + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2846
SELECT + CAST ( NULL AS INTEGER ) * - col2 * + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( - ( - col1 ) ) AS col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col1 + - col0 col2 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT ALL + col0 * col0 + col0 - + col1 FROM tab0 AS cor0
----
1163
514
7919

query I rowsort
SELECT - 13 * + 89 AS col0 FROM tab0 AS cor0
----
-1157
-1157
-1157

query I rowsort
SELECT - col1 * ( + col0 ) + - cor0.col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT - - col1 * + col2 - - col2 AS col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT - cor0.col1 * + 22 AS col0 FROM tab0 cor0
----
-1892
-2002
-2134

onlyif mysql # use DIV operator for integer division
query I rowsort label-2854
SELECT DISTINCT + 22 + - cor0.col1 DIV CAST( 77 AS SIGNED ) FROM tab2, tab0 AS cor0
----
21

skipif mysql # not compatible
query I rowsort label-2854
SELECT DISTINCT + 22 + - cor0.col1 / CAST ( 77 AS INTEGER ) FROM tab2, tab0 AS cor0
----
21

query I rowsort
SELECT DISTINCT + 39 * tab1.col1 AS col0 FROM tab1, tab1 AS cor0
----
1014
390
507

query I rowsort
SELECT col0 * - col2 - - col2 AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT + 1 - + col0 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT 66 * 61 - col2 AS col0 FROM tab0 AS cor0
----
3944
3993
4025

query I rowsort
SELECT DISTINCT - col2 - + col2 AS col0 FROM tab0 AS cor0
----
-164
-2
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2860
SELECT DISTINCT 7 DIV col1 - col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2860
SELECT DISTINCT 7 / col1 - col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT 22 * col1 + + col0 FROM tab2 AS cor0
----
1376
453
689

query I rowsort
SELECT 48 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

query I rowsort
SELECT cor1.col2 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col2 * - col2 col1 FROM tab0
----
1
35937
551368

query I rowsort
SELECT col0 * cor0.col0 + - col0 AS col2 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT DISTINCT + + col2 + col1 * - col0 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT - col0 + - col0 * - col1 * col2 AS col1 FROM tab1
----
36416
4209
99760

query I rowsort
SELECT DISTINCT - col2 * col0 * + col2 AS col1 FROM tab0 WHERE NOT NULL = NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col1 col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL + - col0 * col1 + + col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL + cor0.col0 + col1 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL col0 + col1 AS col1 FROM tab0 cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-2873
SELECT DISTINCT + col0 DIV + col0 col0 FROM tab2 cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2873
SELECT DISTINCT + col0 / + col0 col0 FROM tab2 cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col0 - col1 col0 FROM tab1 cor0
----
111
163
31

query I rowsort
SELECT ALL col0 * col2 * + col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT col0 * cor0.col2 + - cor0.col2 + col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + cor0.col2 - col0 * - col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT col0 + + col1 * + col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT + col1 + cor0.col0 * - cor0.col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 + - col1 + + col2 FROM tab2 AS cor0 WHERE NULL IN ( col1 )
----

query I rowsort
SELECT ALL - cor0.col2 * + col1 * - col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL - col2 * col0 - + col0 FROM tab0
----
-70
-7387
-816

query I rowsort
SELECT ALL col1 - + tab2.col2 * - col2 AS col2 FROM tab2
----
1461
735
760

query I rowsort
SELECT + - col1 * col0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + - col0 + + col0 * col2 - - col1 * + cor0.col2 * + col0 FROM tab0 AS cor0
----
3395
671327
68880

query I rowsort
SELECT + col1 * col2 + col0 AS col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - + col2 + col1 * + col0 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT - tab0.col1 - - col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - tab2.col2 - col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT - col1 - - col1 * col2 AS col0 FROM tab0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-2891
SELECT col2 + - tab2.col2 DIV col0 FROM tab2
----
24
26
38

skipif mysql # not compatible
query I rowsort label-2891
SELECT col2 + - tab2.col2 / col0 FROM tab2
----
24
26
38

query I rowsort
SELECT - col1 * col1 + col1 FROM tab1 cor0
----
-156
-650
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2893
SELECT - col0 + - col0 DIV tab2.col0 AS col2 FROM tab2
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-2893
SELECT - col0 + - col0 / tab2.col0 AS col2 FROM tab2
----
-79
-8
-80

query I rowsort
SELECT ALL - tab0.col1 * col0 * + col1 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL ( col1 ) - 58 FROM tab0 AS cor0
----
28
33
39

query I rowsort
SELECT 63 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2897
SELECT DISTINCT col1 DIV col2 + - col0 AS col0 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2897
SELECT DISTINCT col1 / col2 + - col0 AS col0 FROM tab1
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col0 * col0 col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL + col0 + + col1 AS col2 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2900
SELECT col2 + col1 * col1 + - tab0.col0 DIV col2 col2 FROM tab0
----
7429
8362
9375

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2900
SELECT col2 + col1 * col1 + - tab0.col0 / col2 col2 FROM tab0
----
7429
8362
9375

query I rowsort
SELECT - tab1.col1 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT col2 * col0 + + 32 AS col0 FROM tab0
----
67
7330
824

query I rowsort
SELECT - 6 + + col1 FROM tab0
----
80
85
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-2904
SELECT DISTINCT + cor0.col2 + col1 DIV 18 AS col0 FROM tab0 AS cor0
----
37
6
87

skipif mysql # not compatible
query I rowsort label-2904
SELECT DISTINCT + cor0.col2 + col1 / 18 AS col0 FROM tab0 AS cor0
----
37
6
87

query I rowsort
SELECT ALL - - 35 AS col2 FROM tab0 cor0
----
35
35
35

query I rowsort
SELECT - - col2 + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + col1 * - col0 + 8 AS col2 FROM tab2 AS cor0
----
-1335
-209
-4594

query I rowsort
SELECT ALL + col2 * cor0.col2 AS col0 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT 49 * + col1 - col0 FROM tab0 AS cor0
----
4190
4370
4718

onlyif mysql # use DIV operator for integer division
query I rowsort label-2910
SELECT DISTINCT ( - col2 ) DIV + col1 + col1 AS col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2910
SELECT DISTINCT ( - col2 ) / + col1 + col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + + ( - col2 ) * col2 + - col2 AS col1 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT - tab1.col2 * + tab1.col2 - - tab1.col1 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT - col2 * col2 + - col2 * col1 FROM tab2
----
-1566
-2090
-2210

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL IN ( - col2 * tab1.col1 + + col0 )
----

query I rowsort
SELECT DISTINCT + col0 + + col0 + + col0 AS col0 FROM tab0
----
105
267
72

query I rowsort
SELECT DISTINCT tab1.col2 * col0 * + col2 AS col1 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT tab1.col1 * + tab1.col0 * + tab1.col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT DISTINCT col2 * col1 * tab0.col1 AS col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT - tab2.col0 * - col1 AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT tab1.col1 * - col0 * col0 AS col0 FROM tab1
----
-234
-40960
-83200

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col0 + col1 * + col1 NOT BETWEEN col1 AND NULL
----

query I rowsort
SELECT + col2 * col0 * tab0.col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT ALL - col0 + col0 + + col0 * + col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL + col0 + cor0.col0 AS col1 FROM tab2 AS cor0 WHERE ( NULL ) = ( NULL )
----

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT ( NULL ) NOT IN ( col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE ( + col2 * + col2 ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT cor0.col0 * - col1 + col1 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-2928
SELECT ALL col1 DIV - col2 + col0 AS col1 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2928
SELECT ALL col1 / - col2 + col0 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + col2 * col0 * tab0.col2 + - col2 * col1 FROM tab0
----
-62
23298
590974

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL IN ( + col2 + + col1 * + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2931
SELECT DISTINCT - col0 DIV + col2 + col1 FROM tab0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-2931
SELECT DISTINCT - col0 / + col2 + col1 FROM tab0
----
62
86
90

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE ( - col0 * col0 / col2 ) NOT IN ( + col0 / col1 + col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL col0 * cor0.col1 + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - col1 * tab1.col0 + col2 * col2 AS col2 FROM tab1
----
2609
2838
8176

query III rowsort
SELECT ALL * FROM tab0 WHERE ( col0 ) BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT col1 * col2 + tab2.col0 AS col2 FROM tab2
----
1612
725
844

query III rowsort
SELECT * FROM tab1 WHERE - col0 BETWEEN NULL AND - col2 / - col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col2 * - col1 col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT ALL col2 * + tab2.col0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT + tab2.col2 * col0 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col0 * tab1.col0 - - col2 FROM tab1
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-2942
SELECT DISTINCT col2 DIV + col2 + - col2 AS col0 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-2942
SELECT DISTINCT col2 / + col2 + - col2 AS col0 FROM tab1
----
-53
-56
-95

query I rowsort
SELECT ALL col0 FROM tab2 WHERE ( + col1 ) NOT BETWEEN NULL AND + col2
----
7
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2944
SELECT col1 + 70 DIV col1 AS col2 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2944
SELECT col1 + 70 / col1 AS col2 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT ALL - cor0.col2 + - ( 68 ) AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 8fe07dd635a84786c952e83ccdb0e86e

query I rowsort
SELECT col0 * ( col0 ) FROM tab0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 * + cor0.col0 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 458b4c13e6825f9686b15a38663930f4

query I rowsort
SELECT ALL + ( col0 + col1 ) * col0 FROM tab2
----
10686
266
7584

query I rowsort
SELECT ALL ( - tab1.col2 ) * - tab1.col0 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 84 col2 FROM tab1
----
84

query I rowsort
SELECT + cor0.col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2952
SELECT ALL 59 DIV - col1 + col1 + 60 FROM tab1 AS cor0
----
65
69
84

skipif mysql # not compatible
query I rowsort label-2952
SELECT ALL 59 / - col1 + col1 + 60 FROM tab1 AS cor0
----
65
69
84

query I rowsort
SELECT + - ( + 64 ) AS col1 FROM tab1 AS cor0
----
-64
-64
-64

query I rowsort
SELECT + col1 + - 43 AS col1 FROM tab2 AS cor0
----
-12
-26
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-2955
SELECT DISTINCT col0 + cor0.col2 DIV - cor0.col0 AS col2 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-2955
SELECT DISTINCT col0 + cor0.col2 / - cor0.col0 AS col2 FROM tab2 AS cor0
----
4
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2956
SELECT - 11 DIV col0 FROM tab2 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2956
SELECT - 11 / col0 FROM tab2 cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 26 col1 FROM tab0 AS cor0
----
26
26
26

query I rowsort
SELECT ALL - 11 * + col0 + ( cor0.col0 ) FROM tab0 AS cor0
----
-240
-350
-890

query I rowsort
SELECT - col1 + - 52 FROM tab0
----
-138
-143
-149

query I rowsort
SELECT + col2 + col1 AS col0 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT + + col2 + col2 * - cor0.col2 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT 95 * col0 AS col2 FROM tab1 cor0
----
285
6080
7600

query I rowsort
SELECT DISTINCT ( tab2.col0 ) * col1 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2964
SELECT + ( col2 ) DIV + tab1.col1 - + col1 FROM tab1
----
-24
-5
-6

skipif mysql # not compatible
query I rowsort label-2964
SELECT + ( col2 ) / + tab1.col1 - + col1 FROM tab1
----
-24
-5
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2965
SELECT + 38 DIV cor0.col1 col2 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2965
SELECT + 38 / cor0.col1 col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL - col0 * 83 FROM tab2 AS cor0
----
-581
-6474
-6557

query I rowsort
SELECT + col0 + ( 3 ) FROM tab1 cor0
----
6
67
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2968
SELECT ALL + col0 DIV 40 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2968
SELECT ALL + col0 / 40 FROM tab2 AS cor0
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2969
SELECT ALL + col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2969
SELECT ALL + col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * - 41 AS col0 FROM tab0 AS cor0
----
-1435
-3649
-984

query I rowsort
SELECT ALL + 69 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT ALL + 12 * + col0 FROM tab2
----
84
936
948

query I rowsort
SELECT ALL 92 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT 72 * col1 + cor0.col2 * col0 AS col2 FROM tab2 AS cor0
----
2421
4226
6276

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 70 ) + col2 col1 FROM tab2 AS cor0
----
-32
-43
-44

query I rowsort
SELECT - ( - col0 ) + + col0 + - 58 * 84 FROM tab1 AS cor0
----
-4712
-4744
-4866

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2977
SELECT CAST( col2 AS SIGNED ) * col2 + 55 col1 FROM tab1 AS cor0
----
2971
3304
9271

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2977
SELECT CAST ( col2 AS INTEGER ) * col2 + 55 col1 FROM tab1 AS cor0
----
2971
3304
9271

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col1 * - cor0.col0 * cor0.col1 col0 FROM tab2 AS cor0
----
-22848
-271577
-6758

query I rowsort
SELECT DISTINCT - 57 AS col1 FROM tab0, tab1 cor0
----
-57

query I rowsort
SELECT ALL + 64 + + col2 * col1 FROM tab1 cor0
----
1312
1468
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 66 * - col2 col2 FROM tab0 AS cor0
----
2178
5412
66

query I rowsort
SELECT DISTINCT - - 30 * col2 AS col1 FROM tab1 AS cor0
----
1620
1710
2880

query I rowsort
SELECT - + cor0.col0 + col2 + cor0.col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - col0 * + ( - col1 ) + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT - ( + 33 ) * cor0.col0 + - col0 * col2 FROM tab2 AS cor0
----
-420
-4602
-5609

query I rowsort
SELECT ( + col0 ) + cor0.col0 * 18 * col2 AS col1 FROM tab0 AS cor0
----
131453
14280
665

query I rowsort
SELECT - col2 + 31 FROM tab1 AS cor0
----
-23
-26
-65

query I rowsort
SELECT DISTINCT - tab1.col0 AS col0 FROM tab1, tab0 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col0 * + 1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT tab0.col0 + col1 * tab0.col2 * col2 AS col1 FROM tab0
----
132
611973
93678

query I rowsort
SELECT col2 + col1 * - 1 AS col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT cor0.col2 * + col2 + - 64 AS col0 FROM tab0 AS cor0
----
-63
1025
6660

query I rowsort
SELECT + 57 AS col1 FROM tab0 AS cor0
----
57
57
57

query I rowsort
SELECT ALL - + cor0.col0 + col0 * + col2 + + 82 FROM tab1 AS cor0
----
241
3666
7682

query I rowsort
SELECT - 52 * + col0 + + col0 FROM tab1 AS cor0
----
-153
-3264
-4080

query I rowsort
SELECT ALL + 96 + + 1 FROM tab0 AS cor0
----
97
97
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2998
SELECT DISTINCT CAST( NULL AS SIGNED ) * - col2 - - col2 col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2998
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - col2 - - col2 col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT cor0.col1 + - 19 * - col1 FROM tab0 AS cor0
----
1720
1820
1940

query I rowsort
SELECT 16 * 99 AS col1 FROM tab1 cor0
----
1584
1584
1584

query I rowsort
SELECT - + ( - col0 ) + col2 * + col1 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - - col2 + + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + - 20 FROM tab1 AS cor0
----
-20
-20
-20

query I rowsort
SELECT DISTINCT + ( col2 ) * + col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + ( + col2 ) * col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT 48 * + col2 * - col2 FROM tab0 cor0
----
-322752
-48
-52272

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3007
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + col2 + col1 + + ( - col1 ) * + col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3007
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + col2 + col1 + + ( - col1 ) * + col0 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3008
SELECT CAST( col2 AS SIGNED ) * + cor0.col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-3008
SELECT CAST ( col2 AS INTEGER ) * + cor0.col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL col2 + + cor0.col1 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
63
84
95

query I rowsort
SELECT + - col1 * + cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL 29 * col1 AS col1 FROM tab1 AS cor0
----
290
377
754

query I rowsort
SELECT + + col2 * - cor0.col2 + col1 AS col2 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT DISTINCT col1 + col2 * ( - col2 * + col1 ) FROM tab0
----
-611793
-93568
0

query I rowsort
SELECT 74 + - col1 FROM tab2
----
15
43
57

query I rowsort
SELECT + 9 * col1 + + col1 FROM tab1 AS cor0
----
100
130
260

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 5 col1 FROM tab0 AS cor0
----
5

query I rowsort
SELECT ALL cor0.col1 * col2 + + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - col2 * - col0 + ( - 12 ) + col1 FROM tab0 AS cor0
----
120
7377
866

onlyif mysql # use DIV operator for integer division
query I rowsort label-3019
SELECT - col2 DIV cor0.col0 + + col0 FROM tab1 AS cor0
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-3019
SELECT - col2 / cor0.col0 + + col0 FROM tab1 AS cor0
----
-15
64
79

query I rowsort
SELECT ALL - - col0 - + col2 * col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT col0 * ( col2 ) FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col2 * 79 FROM tab0 AS cor0
----
-2607
-6478
-79

query I rowsort
SELECT ALL - cor0.col2 * + col0 * cor0.col0 + - cor0.col0 * 14 AS col2 FROM tab1 AS cor0
----
-234368
-528
-615520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * + ( - cor0.col2 ) col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + - cor0.col0 + 76 AS col2 FROM tab0 AS cor0
----
-13
41
52

query I rowsort
SELECT ALL - + col2 * - ( + col2 ) FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - col0 + 89 AS col0 FROM tab0 AS cor0
----
0
54
65

query I rowsort
SELECT col1 * - cor0.col2 + - cor0.col0 FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT - - col2 * 74 AS col2 FROM tab1 AS cor0
----
3996
4218
7104

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3030
SELECT DISTINCT - col2 * + col2 + ( col0 * - col1 ) + + CAST( NULL AS SIGNED ) * col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3030
SELECT DISTINCT - col2 * + col2 + ( col0 * - col1 ) + + CAST ( NULL AS INTEGER ) * col0 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3031
SELECT ALL col0 DIV - ( col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3031
SELECT ALL col0 / - ( col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + 89 FROM tab1 AS cor0
----
63
76
79

query I rowsort
SELECT col0 * - ( col1 ) - col0 * 12 AS col2 FROM tab2 AS cor0
----
-2291
-301
-5538

query I rowsort
SELECT + + cor0.col0 + - col0 * 75 FROM tab0 AS cor0
----
-1776
-2590
-6586

query I rowsort
SELECT + - col1 * - col1 + ( col2 ) * - col0 FROM tab1 AS cor0
----
-3548
-7511
514

query I rowsort
SELECT ALL - - col1 * col2 * 37 + cor0.col2 FROM tab0 AS cor0
----
105039
276176
3590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 57 col1 FROM tab1 AS cor0
----
-57
-57
-57

query I rowsort
SELECT 19 - - 96 AS col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 6c283896387f7b811ffd29c508bbde86

query I rowsort
SELECT + col0 * + col2 + 38 * - 21 FROM tab1 AS cor0
----
-636
2850
6882

query I rowsort
SELECT col2 * col1 + cor0.col2 * + col2 FROM tab2 cor0
----
1566
2090
2210

query I rowsort
SELECT ALL 39 + col2 FROM tab1
----
135
93
96

query I rowsort
SELECT + 98 * tab2.col0 AS col2 FROM tab2
----
686
7644
7742

query I rowsort
SELECT - tab1.col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT ALL 6 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

query I rowsort
SELECT DISTINCT + 2 + col2 FROM tab1
----
56
59
98

query I rowsort
SELECT ALL - cor0.col2 * - 91 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 45285ffa439708fe5215b7a3a1f4aef8

query I rowsort
SELECT ALL col0 + + col0 + + col2 AS col1 FROM tab2
----
182
196
41

query I rowsort
SELECT ALL - col0 - + col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + - col1 * + col0 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3050
SELECT + col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3050
SELECT + col0 / - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 52 col0 FROM tab2 AS cor0
----
52
52
52

query I rowsort
SELECT DISTINCT - col2 * - col1 * + ( col2 ) + + col2 FROM tab2
----
22626
24586
39910

onlyif mysql # use DIV operator for integer division
query I rowsort label-3053
SELECT ALL - col2 DIV - tab2.col0 + + 12 FROM tab2
----
12
12
15

skipif mysql # not compatible
query I rowsort label-3053
SELECT ALL - col2 / - tab2.col0 + + 12 FROM tab2
----
12
12
15

query I rowsort
SELECT 99 FROM tab2, tab1 cor0, tab2 cor1
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

query I rowsort
SELECT DISTINCT 73 AS col0 FROM tab1, tab0 AS cor0
----
73

query I rowsort
SELECT - 44 AS col0 FROM tab1 AS cor0
----
-44
-44
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( + col0 ) col1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3058
SELECT - - CAST( col1 AS SIGNED ) FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3058
SELECT - - CAST ( col1 AS INTEGER ) FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT ALL + col0 * 0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL ( col2 ) AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL 58 FROM tab0, tab0 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3062
SELECT - CAST( 33 AS SIGNED ) AS col2 FROM tab0, tab1, tab1 cor0
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

skipif mysql # not compatible
query I rowsort label-3062
SELECT - CAST ( 33 AS INTEGER ) AS col2 FROM tab0, tab1, tab1 cor0
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

onlyif mysql # use DIV operator for integer division
query I rowsort label-3063
SELECT ALL col1 DIV - col0 col0 FROM tab0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3063
SELECT ALL col1 / - col0 col0 FROM tab0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT 38 AS col0 FROM tab0 cor0
----
38

query I rowsort
SELECT - ( col0 ) + col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT 89 + cor0.col0 * + 92 FROM tab1, tab2 AS cor0
----
7265
733
7357

query I rowsort
SELECT - ( - col0 + col1 ) FROM tab2
----
-24
19
62

query I rowsort
SELECT col1 + col1 * + ( + col2 ) AS col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT 61 * - col2 AS col1 FROM tab2
----
-1586
-1647
-2318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - tab2.col2 col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT 23 * + col1 * 69 AS col0 FROM tab1
----
15870
20631
41262

query I rowsort
SELECT - + col2 + - col0 AS col0 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT - col2 + 85 FROM tab0 AS cor0
----
3
52
84

query I rowsort
SELECT - col0 + ( - 97 ) FROM tab0 AS cor0
----
-121
-132
-186

query I rowsort
SELECT + col1 * - 10 + - cor0.col0 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-284
255
7011

query I rowsort
SELECT - + cor0.col1 + col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3079
SELECT ALL + col1 + + CAST( + col2 AS SIGNED ) * - col1 + + 1 * tab2.col1 * col1 AS col2 FROM tab2
----
-340
155
2006

skipif mysql # not compatible
query I rowsort label-3079
SELECT ALL + col1 + + CAST ( + col2 AS INTEGER ) * - col1 + + 1 * tab2.col1 * col1 AS col2 FROM tab2
----
-340
155
2006

query I rowsort
SELECT + + col2 * col0 + col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab0 cor1, tab2, tab1 AS cor2
----
3645 values hashing to 5e27196f2932b25a5297ddec46b8b8f1

query I rowsort
SELECT - col1 + 55 * - col2 AS col0 FROM tab0 cor0
----
-152
-1901
-4601

query I rowsort
SELECT - 70 * cor0.col0 FROM tab1 AS cor0
----
-210
-4480
-5600

query I rowsort
SELECT ALL - 61 + col0 * - col1 + - col2 FROM tab2 AS cor0
----
-1442
-305
-4689

query I rowsort
SELECT DISTINCT 42 - + col0 AS col1 FROM tab2 cor0
----
-36
-37
35

query I rowsort
SELECT DISTINCT 82 * + col1 FROM tab2 AS cor0
----
1394
2542
4838

query I rowsort
SELECT col2 * - 82 + + col0 FROM tab1 cor0
----
-4425
-4610
-7792

query I rowsort
SELECT + ( + col2 ) + cor0.col2 AS col0 FROM tab2 AS cor0
----
52
54
76

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - 10 AS REAL ) AS col0 FROM tab2 cor0
----
-10

query I rowsort
SELECT ALL - - cor0.col1 + - ( + col1 ) * col2 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3091
SELECT + + ( - 95 ) + col2 * CAST( col2 + + col0 AS SIGNED ) FROM tab1 AS cor0
----
16801
2983
6802

skipif mysql # not compatible
query I rowsort label-3091
SELECT + + ( - 95 ) + col2 * CAST ( col2 + + col0 AS INTEGER ) FROM tab1 AS cor0
----
16801
2983
6802

query I rowsort
SELECT + col1 * - col0 + col2 - 56 AS col2 FROM tab1 AS cor0
----
-1000
-639
-80

query I rowsort
SELECT + 77 - col2 FROM tab2 AS cor0
----
39
50
51

query I rowsort
SELECT + - col1 * cor0.col2 + col1 - 58 FROM tab1 AS cor0
----
-1293
-1436
-618

query I rowsort
SELECT - 6 * col2 + col0 * + cor0.col2 FROM tab0 AS cor0
----
29
594
6806

query I rowsort
SELECT - cor0.col0 + col1 - - col1 FROM tab1 AS cor0
----
-44
-54
49

query I rowsort
SELECT - - cor0.col0 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - cor0.col2 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3099
SELECT ALL ( col2 ) + + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3099
SELECT ALL ( col2 ) + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + ( - 38 ) FROM tab2 AS cor0
----
-55
-69
-97

query I rowsort
SELECT ALL - + col0 + col1 AS col2 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT col2 * + 95 + + col1 * col2 FROM tab0 AS cor0
----
15252
192
5973

query I rowsort
SELECT DISTINCT + col2 + cor0.col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT - - col0 * col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT + 20 * col0 + - ( - col2 ) * - cor0.col2 FROM tab1 AS cor0
----
-1969
-2856
-7616

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 28 col1 FROM tab0
----
-28
-28
-28

query I rowsort
SELECT DISTINCT + 94 + col2 AS col2 FROM tab1 cor0
----
148
151
190

query I rowsort
SELECT DISTINCT - - col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - 94 + col2 AS col1 FROM tab1 AS cor0
----
-37
-40
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3110
SELECT ALL - ( - cor0.col2 ) * + col1 + + 22 DIV + cor0.col2 FROM tab0 AS cor0
----
119
2838
7462

skipif mysql # not compatible
query I rowsort label-3110
SELECT ALL - ( - cor0.col2 ) * + col1 + + 22 / + cor0.col2 FROM tab0 AS cor0
----
119
2838
7462

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 * col0 + - CAST ( col0 AS REAL ) + col2 * col1 FROM tab1 AS cor0
----
-3142
-6512
1239

query I rowsort
SELECT 44 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT ALL cor0.col1 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ( col0 ) - - col1 FROM tab1
----
29
74
93

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - ( col0 + + CAST ( + col0 AS REAL ) ) AS col2 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT - tab0.col2 AS col1 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3117
SELECT DISTINCT + + ( - col0 ) * - CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-3117
SELECT DISTINCT + + ( - col0 ) * - CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + cor0.col0 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT 66 * - col2 AS col2 FROM tab0 AS cor0
----
-2178
-5412
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + col1 + ( col2 + col1 ) * cor0.col0 col1 FROM tab0 AS cor0
----
15406
2909
3526

query I rowsort
SELECT ALL - + cor0.col2 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + col1 * + col0 - ( ( col1 ) ) AS col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL tab2.col0 - col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT col2 * ( col1 ) AS col1 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + ( - col2 ) col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL col1 * + col1 + + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + + col0 + - col0 + col2 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 94 + - cor0.col2 col2 FROM tab2 AS cor0
----
-685
-7358
-7464

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3129
SELECT ALL + CAST( NULL AS DECIMAL ) col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3129
SELECT ALL + CAST ( NULL AS REAL ) col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT cor0.col2 + - ( + cor0.col1 ) * col2 FROM tab0 cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3131
SELECT ALL + + 55 * - col1 + - col2 DIV - col0 FROM tab0 AS cor0
----
-4729
-5005
-5335

skipif mysql # not compatible
query I rowsort label-3131
SELECT ALL + + 55 * - col1 + - col2 / - col0 FROM tab0 AS cor0
----
-4729
-5005
-5335

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * + cor0.col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - col1 * col2 * col1 AS col0 FROM tab0 AS cor0
----
-244068
-679042
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3134
SELECT ALL - CAST( NULL AS SIGNED ) / - col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3134
SELECT ALL - CAST ( NULL AS INTEGER ) / - col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab1.col1 * - col0 + col0 FROM tab1
----
-576
-75
-960

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 CROSS JOIN tab2, tab1, tab1 AS cor1
----
3645 values hashing to ca91d1f523a87017f672304548e91a77

query I rowsort
SELECT DISTINCT - 28 * col2 FROM tab1 AS cor0
----
-1512
-1596
-2688

query I rowsort
SELECT DISTINCT - + col0 * 41 FROM tab2 AS cor0
----
-287
-3198
-3239

query I rowsort
SELECT - 85 + + 30 AS col1 FROM tab0 AS cor0
----
-55
-55
-55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3140
SELECT - CAST( NULL AS SIGNED ) * - ( col2 * - CAST( + col1 AS SIGNED ) ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3140
SELECT - CAST ( NULL AS INTEGER ) * - ( col2 * - CAST ( + col1 AS INTEGER ) ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3141
SELECT - - CAST( NULL AS SIGNED ) * col2 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3141
SELECT - - CAST ( NULL AS INTEGER ) * col2 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * + col0 + col2 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT 24 * + col1 AS col1 FROM tab2 AS cor0
----
1416
408
744

query I rowsort
SELECT ALL + col2 + + col1 FROM tab0 cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3145
SELECT col2 DIV col1 + - cor0.col0 + + col2 * col0 * col2 col1 FROM tab2 AS cor0
----
113999
5096
52650

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3145
SELECT col2 / col1 + - cor0.col0 + + col2 * col0 * col2 col1 FROM tab2 AS cor0
----
113999
5096
52650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3146
SELECT + col2 + + col1 + + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3146
SELECT + col2 + + col1 + + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3147
SELECT - col0 + - cor0.col1 * CAST( NULL AS SIGNED ) * - col2 + 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-3147
SELECT - col0 + - cor0.col1 * CAST ( NULL AS INTEGER ) * - col2 + col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + - col2 * - 85 FROM tab2 AS cor0
----
2288
2302
3309

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 48 * + cor0.col2 + - 99 col0 FROM tab1 AS cor0
----
2493
2637
4509

query I rowsort
SELECT DISTINCT 56 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
56

query I rowsort
SELECT ALL - ( col2 ) * 88 AS col0 FROM tab1 AS cor0
----
-4752
-5016
-8448

query I rowsort
SELECT + cor0.col0 + - col0 + col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - + cor0.col0 + - 65 * - ( col1 ) * + col1 AS col2 FROM tab0 AS cor0
----
480716
538176
611550

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3154
SELECT - col2 * + CAST( col2 AS SIGNED ) * - cor0.col2 FROM tab2 AS cor0
----
17576
19683
54872

skipif mysql # not compatible
query I rowsort label-3154
SELECT - col2 * + CAST ( col2 AS INTEGER ) * - cor0.col2 FROM tab2 AS cor0
----
17576
19683
54872

query I rowsort
SELECT + - col1 * - col0 AS col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT 27 * + cor0.col1 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 76752ba52faf3bacb41bd22ac5cf8352

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col2 col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL - - col2 + col2 + - col1 AS col1 FROM tab0 AS cor0
----
-20
-95
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * col0 + + 86 col2 FROM tab1 cor0
----
-4010
-6314
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col0 * - ( tab1.col0 + col2 ) col0 FROM tab1
----
-14080
-171
-7744

query I rowsort
SELECT DISTINCT + 22 FROM tab0, tab2 cor0
----
22

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3162
SELECT CAST( NULL AS DECIMAL ) * + col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3162
SELECT CAST ( NULL AS REAL ) * + col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - col1 * - col1 + - col2 AS col1 FROM tab0
----
636023
753489
912672

query I rowsort
SELECT + col1 * col1 + - col2 * col2 AS col2 FROM tab1
----
-2240
-3149
-9047

query I rowsort
SELECT + - col2 * + 21 * col0 + col1 FROM tab2 cor0
----
-3938
-42529
-63025

query I rowsort
SELECT 40 FROM tab0, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT DISTINCT tab1.col0 * col0 * - tab1.col0 AS col1 FROM tab1
----
-262144
-27
-512000

onlyif mysql # use DIV operator for integer division
query I rowsort label-3168
SELECT col1 DIV cor0.col1 + + col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3168
SELECT col1 / cor0.col1 + + col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT - col2 * + col2 * - cor0.col1 AS col0 FROM tab1 cor0
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-3170
SELECT + + col0 DIV + col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3170
SELECT + + col0 / + col1 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * - col2 * - col2 AS col1 FROM tab0
----
26136
35
598436

query I rowsort
SELECT ALL col2 * tab1.col1 AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT col2 + + col1 * col0 + col1 * col2 FROM tab1
----
1267
1536
2384

query I rowsort
SELECT - col2 FROM tab2 WHERE col1 + - col1 * col1 IN ( - col0 + - col1 )
----

query III rowsort
SELECT * FROM tab2 WHERE - col1 + col1 + + col2 > ( - col2 + + col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT col2 * - tab1.col0 AS col1 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col2 + col2 - col2 * col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT + - col2 * col1 * + col0 + col2 * col2 AS col2 FROM tab2 AS cor0
----
-118976
-49590
-5130

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL NOT IN ( col2 * - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * tab0.col1 col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT 56 * - col0 FROM tab2
----
-392
-4368
-4424

query I rowsort
SELECT + + col2 + ( col1 ) * col1 * cor0.col1 FROM tab2 AS cor0
----
205405
29818
4951

query I rowsort
SELECT cor0.col0 * col2 + ( - col0 ) AS col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL - 75 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to c0722b1d77ac0ed13c0f2691a5751c59

query I rowsort
SELECT DISTINCT ( + col2 * col0 ) AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT - cor0.col1 * - 66 + - 67 FROM tab0, tab0 AS cor0
----
9 values hashing to 43ced3dc3af41a0ef0d0ecf5b03df557

onlyif mysql # use DIV operator for integer division
query I rowsort label-3187
SELECT DISTINCT + col1 DIV col2 col0 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3187
SELECT DISTINCT + col1 / col2 col0 FROM tab1
----
0

query I rowsort
SELECT DISTINCT - + col1 * - 16 FROM tab1 AS cor0
----
160
208
416

query I rowsort
SELECT ALL + cor0.col2 + col1 AS col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3190
SELECT - col2 + col2 DIV 47 FROM tab0 AS cor0
----
-1
-33
-81

skipif mysql # not compatible
query I rowsort label-3190
SELECT - col2 + col2 / 47 FROM tab0 AS cor0
----
-1
-33
-81

query I rowsort
SELECT ALL - + col2 * - ( - cor0.col1 ) * - col0 + + 28 * 9 FROM tab2 AS cor0
----
119904
51286
6111

onlyif mysql # use DIV operator for integer division
query I rowsort label-3192
SELECT + + col2 + - 96 DIV - col0 FROM tab1 AS cor0
----
58
86
97

skipif mysql # not compatible
query I rowsort label-3192
SELECT + + col2 + - 96 / - col0 FROM tab1 AS cor0
----
58
86
97

query I rowsort
SELECT DISTINCT - + cor0.col1 * - ( col1 ) * - cor0.col0 + - col2 FROM tab2 AS cor0
----
-22869
-271544
-6754

query I rowsort
SELECT ALL - cor1.col2 FROM tab0, tab0 cor0, tab1, tab1 AS cor1
----
81 values hashing to 2df272448a67587d4635afedff278dcc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3195
SELECT ALL + col2 * + col0 * - tab1.col0 + col0 * CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3195
SELECT ALL + col2 * + col0 * - tab1.col0 + col0 * CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( col2 ) col2 FROM tab1
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-3197
SELECT DISTINCT + tab1.col1 + + 7 * col1 + col2 DIV col1 FROM tab1
----
111
210
85

skipif mysql # not compatible
query I rowsort label-3197
SELECT DISTINCT + tab1.col1 + + 7 * col1 + col2 / col1 FROM tab1
----
111
210
85

query I rowsort
SELECT ALL - tab2.col1 + col2 AS col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT col0 + - 13 AS col1 FROM tab0 AS cor0
----
11
22
76

query I rowsort
SELECT ALL + col1 + ( col0 ) AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL 51 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT ALL ( col2 * col2 + - 91 ) FROM tab1
----
2825
3158
9125

query I rowsort
SELECT ALL ( col0 ) * - col1 * + col1 AS col1 FROM tab2
----
-22831
-271518
-6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col1 ) col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL + ( col1 + - col2 ) AS col0 FROM tab0
----
53
9
96

query I rowsort
SELECT + 65 + 84 * col1 FROM tab0 AS cor0
----
7289
7709
8213

query I rowsort
SELECT 56 - + col2 * col1 AS col2 FROM tab1
----
-1192
-1348
-514

query I rowsort
SELECT + ( col1 ) + - col0 * + col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT - 62 FROM tab1, tab2 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT ALL ( + 93 ) FROM tab0
----
93
93
93

query I rowsort
SELECT col0 - - col2 * + col1 AS col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT - cor1.col2 FROM tab0, tab0 AS cor0, tab2, tab2 cor1
----
81 values hashing to c569638e8a09ff819458d62ddbde994c

query I rowsort
SELECT ALL - + 92 * + col1 + - col2 AS col0 FROM tab1 AS cor0
----
-1292
-2446
-977

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + col0 col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - ( - col1 ) * col0 * col1 AS col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 + - col2 * 3 FROM tab1 cor0
----
-84
469
752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 63 col0 FROM tab1 AS cor0
----
63
63
63

query I rowsort
SELECT + - 44 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-1144
-440
-572

query I rowsort
SELECT ALL - cor0.col0 + col0 AS col0 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3220
SELECT col2 * col1 DIV col1 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3220
SELECT col2 * col1 / col1 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT + tab0.col1 + + col2 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL col2 + col1 * + col1 AS col0 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT ALL - + col1 * col0 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col0 * cor0.col1 + + col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + col0 * col1 + - col0 * + col0 + + cor0.col2 * - col2 FROM tab2 AS cor0
----
-2158
-561
-6342

query I rowsort
SELECT + col1 + + col2 + + col2 AS col2 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT ALL - - col0 + col1 * - col2 + cor0.col1 FROM tab0 cor0
----
-2728
-7282
35

query I rowsort
SELECT + col0 + col1 + + col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT DISTINCT + col0 + + col2 + col1 * + col0 * tab2.col2 FROM tab2
----
119756
51151
5893

query I rowsort
SELECT ALL + cor0.col1 * col2 - col0 * + col2 FROM tab0 AS cor0
----
164
2046
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3231
SELECT + col2 * - col2 + - col2 DIV - col2 FROM tab1 AS cor0
----
-2915
-3248
-9215

skipif mysql # not compatible
query I rowsort label-3231
SELECT + col2 * - col2 + - col2 / - col2 FROM tab1 AS cor0
----
-2915
-3248
-9215

query I rowsort
SELECT ALL - - cor0.col2 * - col1 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL + + cor0.col1 + - col1 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3234
SELECT ALL col2 DIV - col0 + + col0 + col0 AS col0 FROM tab2
----
11
156
158

skipif mysql # not compatible
query I rowsort label-3234
SELECT ALL col2 / - col0 + + col0 + col0 AS col0 FROM tab2
----
11
156
158

query I rowsort
SELECT ALL + col1 + col2 * + col0 + + col1 * - tab0.col0 FROM tab0
----
-1186
-3263
-710

onlyif mysql # use DIV operator for integer division
query I rowsort label-3236
SELECT col2 + col1 * + col1 DIV - col1 FROM tab2
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-3236
SELECT col2 + col1 * + col1 / - col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT + ( + col0 ) * col0 + col2 * col0 AS col1 FROM tab0 cor0
----
1260
1368
15219

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col2 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - 65 * col1 AS col2 FROM tab2 AS cor0
----
-1105
-2015
-3835

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col2 col0 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 63 col0 FROM tab2 AS cor0
----
63
63
63

query I rowsort
SELECT DISTINCT + + 52 + col1 AS col2 FROM tab2 AS cor0
----
111
69
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + cor0.col1 col1 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT + + 62 AS col2 FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT col1 * col2 * col1 FROM tab2 cor0
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * cor0.col0 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 35 * col0 AS col1 FROM tab2 cor0
----
245
2730
2765

query I rowsort
SELECT ALL - + col2 + col1 * col1 FROM tab2 AS cor0
----
251
3455
934

onlyif mysql # use DIV operator for integer division
query I rowsort label-3249
SELECT ALL ( 17 ) DIV col1 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3249
SELECT ALL ( 17 ) / col1 FROM tab2
----
0
0
1

query I rowsort
SELECT - 16 + 7 * + col2 * + col2 AS col2 FROM tab1
----
20396
22727
64496

onlyif mysql # use DIV operator for integer division
query I rowsort label-3251
SELECT DISTINCT col0 DIV - 63 FROM tab0
----
-1
0

skipif mysql # not compatible
query I rowsort label-3251
SELECT DISTINCT col0 / - 63 FROM tab0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 47 ) col1 FROM tab0
----
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-3253
SELECT ALL - 68 DIV - col1 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-3253
SELECT ALL - 68 / - col1 FROM tab2
----
1
2
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3254
SELECT DISTINCT + tab0.col0 DIV - col0 AS col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-3254
SELECT DISTINCT + tab0.col0 / - col0 AS col0 FROM tab0
----
-1

query I rowsort
SELECT DISTINCT - 26 + + col1 AS col2 FROM tab2 AS cor0
----
-9
33
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3256
SELECT ALL col1 * col0 + - col2 DIV col2 AS col2 FROM tab0 AS cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-3256
SELECT ALL col1 * col0 + - col2 / col2 AS col2 FROM tab0 AS cor0
----
2063
3394
8098

query I rowsort
SELECT DISTINCT + col1 + col2 * col2 FROM tab1 cor0
----
2942
3259
9229

query I rowsort
SELECT + - col0 * - col0 AS col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT + - col1 * col0 * col2 FROM tab2 cor0
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 9 + col2 col1 FROM tab2
----
17
18
29

query I rowsort
SELECT ALL - ( + col0 * tab2.col1 ) AS col0 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3262
SELECT - col1 + col0 * col2 DIV col2 FROM tab0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-3262
SELECT - col1 + col0 * col2 / col2 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT col1 + - tab1.col0 AS col2 FROM tab1
----
-54
-67
23

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL = col1
----

query I rowsort
SELECT DISTINCT - col1 * - col1 + - col1 FROM tab2
----
272
3422
930

query I rowsort
SELECT ALL col0 + + col0 FROM tab2 WHERE NOT NULL < - col0
----

query I rowsort
SELECT ALL - col1 * - col0 + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT ALL col0 AS col0 FROM tab1 WHERE NOT col1 >= ( NULL )
----

query I rowsort
SELECT DISTINCT - col1 + col2 * + col2 AS col1 FROM tab2
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-3270
SELECT ALL tab2.col1 DIV col0 + col0 AS col2 FROM tab2
----
11
78
79

skipif mysql # not compatible
query I rowsort label-3270
SELECT ALL tab2.col1 / col0 + col0 AS col2 FROM tab2
----
11
78
79

query I rowsort
SELECT DISTINCT col1 + tab1.col2 * tab1.col2 * - col2 FROM tab1
----
-157438
-185183
-884723

query I rowsort
SELECT + col1 - tab0.col1 * col2 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT + col0 - + col0 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL col2 - - col1 FROM tab0 WHERE NOT NULL < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3275
SELECT col0 DIV - col2 + col0 FROM tab0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-3275
SELECT col0 / - col2 + col0 FROM tab0
----
0
24
88

query III rowsort
SELECT * FROM tab2 WHERE + col1 IN ( - col0 )
----

query I rowsort
SELECT DISTINCT - col1 * + col1 * + col2 + + col2 * col1 * + col2 FROM tab0 WHERE NOT + col0 IN ( col1 )
----
-150414
-67158
-9312

query I rowsort
SELECT - col2 - - col2 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 + + tab2.col1 * col0 * - col0 FROM tab2
----
-106018
-1512
-358878

query I rowsort
SELECT DISTINCT col0 * col1 * - col2 FROM tab1
----
-36480
-4212
-99840

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) >= ( - col0 )
----

query I rowsort
SELECT ALL tab2.col0 + - tab2.col1 AS col0 FROM tab2
----
-24
19
62

query III rowsort
SELECT * FROM tab1 WHERE NOT col0 NOT IN ( col2 * col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL < col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3285
SELECT + col1 + + tab2.col2 DIV col1 AS col1 FROM tab2
----
19
31
59

skipif mysql # not compatible
query I rowsort label-3285
SELECT + col1 + + tab2.col2 / col1 AS col1 FROM tab2
----
19
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3286
SELECT + col2 - col1 DIV col1 AS col1 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-3286
SELECT + col2 - col1 / col1 AS col1 FROM tab0
----
0
32
81

query I rowsort
SELECT - col0 / + col2 FROM tab0 WHERE NOT NULL < NULL
----

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab1
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + col2 * + col1 AS col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - + col2 + col0 * col1 * + col0 FROM tab2 AS cor0
----
106059
1492
358930

query I rowsort
SELECT + col2 + col1 + - col0 FROM tab0 AS cor0
----
63
84
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-3292
SELECT ALL cor0.col1 + cor0.col1 * col2 DIV col2 AS col0 FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-3292
SELECT ALL cor0.col1 + cor0.col1 * col2 / col2 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT col0 * + col0 AS col2 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ALL - cor0.col2 + - col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - col2 * col0 + col1 * + col2 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT DISTINCT - col1 - - col1 * + col1 AS col0 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT col1 * + col0 - - col0 * col1 * col1 FROM tab1 AS cor0
----
14560
2106
7040

query I rowsort
SELECT ALL + col0 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - col1 - + cor0.col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT - cor0.col0 - cor0.col1 AS col1 FROM tab2, tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL cor0.col0 + col2 * - col0 FROM tab1 AS cor0
----
-159
-3584
-7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * - col1 * - col0 col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT - col2 - col0 * tab2.col1 FROM tab2
----
-1381
-244
-4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 5 ) col0 FROM tab1
----
-5
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3305
SELECT + - ( cor0.col0 ) - + col1 DIV 78 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-3305
SELECT + - ( cor0.col0 ) - + col1 / 78 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT + cor0.col1 * + 18 FROM tab0 AS cor0
----
1548
1638
1746

query I rowsort
SELECT - - cor0.col2 * 20 + col2 AS col0 FROM tab2 AS cor0
----
546
567
798

query I rowsort
SELECT - ( 84 ) FROM tab2 cor0
----
-84
-84
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * col0 + 94 col1 FROM tab1 AS cor0
----
256
3742
7774

query I rowsort
SELECT - - 34 + col1 FROM tab0 AS cor0
----
120
125
131

onlyif mysql # use DIV operator for integer division
query I rowsort label-3311
SELECT - col2 * col0 + 97 DIV cor0.col1 FROM tab1 AS cor0
----
-159
-3639
-7673

skipif mysql # not compatible
query I rowsort label-3311
SELECT - col2 * col0 + 97 / cor0.col1 FROM tab1 AS cor0
----
-159
-3639
-7673

query I rowsort
SELECT - 74 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2, tab0 AS cor2
----
243 values hashing to aae90a3693940d37cdb51d5e4f1c7ac8

query I rowsort
SELECT 62 * cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 02562728855dd6ce29b773e142e96a87

query I rowsort
SELECT DISTINCT tab0.col0 * + ( tab0.col1 ) AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + - col1 * + 69 AS col1 FROM tab2 AS cor0
----
-1173
-2139
-4071

onlyif mysql # use DIV operator for integer division
query I rowsort label-3316
SELECT - - col2 * 72 DIV - 20 col1 FROM tab1 AS cor0
----
-194
-205
-345

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3316
SELECT - - col2 * 72 / - 20 col1 FROM tab1 AS cor0
----
-194
-205
-345

query I rowsort
SELECT + cor0.col0 * - 84 FROM tab2 cor0
----
-588
-6552
-6636

query I rowsort
SELECT 24 FROM tab2, tab1 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT - col2 * + 4 + - col1 * 20 * 40 + col1 FROM tab0 AS cor0
----
-68846
-73037
-77507

query I rowsort
SELECT ALL - cor0.col2 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3321
SELECT col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3321
SELECT col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3322
SELECT + CAST( NULL AS DECIMAL ) * + col2 * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3322
SELECT + CAST ( NULL AS REAL ) * + col2 * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 54 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
54

query I rowsort
SELECT DISTINCT 18 + + cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
25
96
97

query I rowsort
SELECT + 95 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT ALL - 31 * col1 AS col1 FROM tab1 AS cor0
----
-310
-403
-806

query I rowsort
SELECT + 67 * - col2 FROM tab2 AS cor0
----
-1742
-1809
-2546

query I rowsort
SELECT DISTINCT 52 + col2 FROM tab2 AS cor0
----
78
79
90

query I rowsort
SELECT - ( col1 ) * - tab2.col0 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT 13 + + cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to e921e0e42794a07c2713c40a63f683f4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 74 * + cor0.col1 + - 74 col0 FROM tab1 AS cor0
----
1850
666
888

query I rowsort
SELECT DISTINCT + 89 AS col1 FROM tab2 AS cor0
----
89

query I rowsort
SELECT - - 77 + - col0 FROM tab2 cor0
----
-1
-2
70

query I rowsort
SELECT ALL + col1 + col2 * col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT 21 * + col1 * tab2.col1 FROM tab2
----
20181
6069
73101

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3336
SELECT - + CAST( NULL AS SIGNED ) col1 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3336
SELECT - + CAST ( NULL AS INTEGER ) col1 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - col1 * tab2.col1 - col2 AS col0 FROM tab2
----
-327
-3507
-988

query I rowsort
SELECT DISTINCT 27 + - col1 - + col1 FROM tab0
----
-145
-155
-167

onlyif mysql # use DIV operator for integer division
query I rowsort label-3339
SELECT col0 * col1 DIV col2 + tab1.col1 * col0 + col1 DIV + col0 AS col0 FROM tab1
----
1050
651
87

skipif mysql # not compatible
query I rowsort label-3339
SELECT col0 * col1 / col2 + tab1.col1 * col0 + col1 / + col0 AS col0 FROM tab1
----
1050
651
87

query I rowsort
SELECT + 65 + col2 AS col1 FROM tab1
----
119
122
161

query I rowsort
SELECT DISTINCT - col0 + + 88 * + col2 AS col0 FROM tab1 AS cor0
----
4749
4952
8368

onlyif mysql # use DIV operator for integer division
query I rowsort label-3342
SELECT DISTINCT - col2 DIV - 88 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3342
SELECT DISTINCT - col2 / - 88 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT - + col1 + 44 * cor0.col1 FROM tab0 AS cor0
----
3698
3913
4171

query I rowsort
SELECT ALL + col1 * - 74 + - col1 FROM tab1 AS cor0
----
-1950
-750
-975

query I rowsort
SELECT ALL + col0 * col1 + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL + - 94 * cor0.col0 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 49363f4a1dbacccddb60ad7767d86d5a

query I rowsort
SELECT ALL + 60 AS col2 FROM tab0
----
60
60
60

query I rowsort
SELECT col0 * + col2 * + 59 AS col0 FROM tab1
----
215232
453120
9558

query I rowsort
SELECT cor1.col0 AS col0 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT - 71 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 3907e0aa4f29c002120742c4abb3e23a

query I rowsort
SELECT + - col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - tab1.col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT ALL - 85 * col1 FROM tab2
----
-1445
-2635
-5015

query I rowsort
SELECT + col2 * - col0 + + 93 FROM tab1
----
-3555
-69
-7587

query I rowsort
SELECT + ( + col0 * col1 ) + col2 FROM tab0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT col2 + - col1 * col0 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT - cor0.col0 * - cor0.col1 - + col0 FROM tab1 AS cor0
----
576
75
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-3359
SELECT - col2 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3359
SELECT - col2 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3360
SELECT - col0 * + col0 + col0 * - col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3360
SELECT - col0 * + col0 + col0 * - col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col0 + - 39 + 66 FROM tab0 cor0
----
116
51
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3362
SELECT DISTINCT col0 DIV + col2 - - col2 FROM tab0 AS cor0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-3362
SELECT DISTINCT col0 / + col2 - - col2 FROM tab0 AS cor0
----
33
36
83

query I rowsort
SELECT ALL cor0.col0 * 55 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT ALL - + col0 + ( - ( col2 ) ) * - col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT + + col2 + col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + col0 * col2 * + col0 + col1 + + 78 * col2 FROM tab2 AS cor0
----
160271
240139
3460

query I rowsort
SELECT - col2 + 20 AS col0 FROM tab1 AS cor0
----
-34
-37
-76

query I rowsort
SELECT ALL col0 * 1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - - col1 + ( - col0 ) AS col1 FROM tab0 AS cor0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3370
SELECT DISTINCT + + col0 * + CAST( ( col2 ) * col1 AS SIGNED ) - - col0 * + col2 FROM tab0 AS cor0
----
3430
671416
68904

skipif mysql # not compatible
query I rowsort label-3370
SELECT DISTINCT + + col0 * + CAST ( ( col2 ) * col1 AS INTEGER ) - - col0 * + col2 FROM tab0 AS cor0
----
3430
671416
68904

query I rowsort
SELECT DISTINCT + - col2 + 32 * - col1 AS col0 FROM tab1 AS cor0
----
-377
-512
-886

onlyif mysql # use DIV operator for integer division
query I rowsort label-3372
SELECT DISTINCT + 45 DIV col2 FROM tab0
----
0
1
45

skipif mysql # not compatible
query I rowsort label-3372
SELECT DISTINCT + 45 / col2 FROM tab0
----
0
1
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 col1 FROM tab2, tab2 cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT ( + col1 ) * col2 + - col2 AS col2 FROM tab0
----
2805
7380
96

query I rowsort
SELECT DISTINCT - - col1 * + col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + col0 * + col1 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - + 30 + 11 * - col2 AS col0 FROM tab2 AS cor0
----
-316
-327
-448

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 4 col0 FROM tab1 AS cor0
----
-4
-4
-4

query I rowsort
SELECT ( + ( - col1 ) ) * col1 * - col0 FROM tab2 cor0
----
22831
271518
6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * col1 + col2 col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT 53 * 18 AS col2 FROM tab2 AS cor0
----
954

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3382
SELECT DISTINCT - CAST( NULL AS DECIMAL ) / col2 AS col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3382
SELECT DISTINCT - CAST ( NULL AS REAL ) / col2 AS col0 FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3383
SELECT - + CAST( + col0 AS SIGNED ) DIV + cor0.col0 col0 FROM tab2 cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3383
SELECT - + CAST ( + col0 AS INTEGER ) / + cor0.col0 col0 FROM tab2 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - - ( ( - col0 ) ) + + 71 * col2 + col2 * - 65 FROM tab1 AS cor0
----
278
321
496

query I rowsort
SELECT DISTINCT col0 * 50 * col1 + col1 * - col1 AS col0 FROM tab2 AS cor0
----
226619
66861
9889

query I rowsort
SELECT + + 29 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT + ( + col1 ) + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL 23 + col2 + - col1 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-1282
-167
-4553

query I rowsort
SELECT + - 81 + 17 * col0 FROM tab2 AS cor0
----
1245
1262
38

query I rowsort
SELECT - 48 + - col1 * - col1 AS col0 FROM tab1 AS cor0
----
121
52
628

query I rowsort
SELECT ALL - col1 + + 12 AS col2 FROM tab2 AS cor0
----
-19
-47
-5

query I rowsort
SELECT DISTINCT + 99 * col2 + cor0.col2 FROM tab2 AS cor0
----
2600
2700
3800

query I rowsort
SELECT DISTINCT + + col0 + col0 AS col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT cor0.col2 + ( + col2 ) FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( cor0.col2 ) col2 FROM tab1, tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + + 75 * - cor0.col0 AS col1 FROM tab0 cor0
----
-1800
-2625
-6675

onlyif mysql # use DIV operator for integer division
query I rowsort label-3397
SELECT DISTINCT + 28 DIV col2 AS col0 FROM tab0 AS cor0
----
0
28

skipif mysql # not compatible
query I rowsort label-3397
SELECT DISTINCT + 28 / col2 AS col0 FROM tab0 AS cor0
----
0
28

query I rowsort
SELECT - col2 * ( + col1 * 8 ) - 15 FROM tab0
----
-22719
-59711
-791

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + 96 + col0 AS col0 FROM tab1 AS cor0
----
160
176
99

query I rowsort
SELECT ( col0 ) * + 44 FROM tab2 cor0
----
308
3432
3476

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col1 + col0 * - cor0.col1 + col0 FROM tab1 AS cor0
----
-1146
-1479
-2208

query I rowsort
SELECT ALL + col0 * + col0 * - ( + 88 ) FROM tab2 AS cor0
----
-4312
-535392
-549208

onlyif mysql # use DIV operator for integer division
query I rowsort label-3404
SELECT DISTINCT - - cor0.col1 DIV + col1 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-3404
SELECT DISTINCT - - cor0.col1 / + col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT 50 + - col1 * + col1 AS col2 FROM tab1 AS cor0
----
-119
-50
-626

onlyif mysql # use DIV operator for integer division
query I rowsort label-3406
SELECT - col2 DIV col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-3406
SELECT - col2 / col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT 56 + + col2 AS col2 FROM tab1
----
110
113
152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 * 48 col0 FROM tab2
----
528
528
528

query I rowsort
SELECT DISTINCT ( col0 ) + + col2 FROM tab2
----
104
117
34

query I rowsort
SELECT col1 + col2 + 58 * - 55 FROM tab2 AS cor0
----
-3105
-3132
-3135

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3411
SELECT DISTINCT - tab2.col1 + - CAST( + ( + col2 ) AS SIGNED ) FROM tab2
----
-55
-58
-85

skipif mysql # not compatible
query I rowsort label-3411
SELECT DISTINCT - tab2.col1 + - CAST ( + ( + col2 ) AS INTEGER ) FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL + 80 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT + col0 * + 61 - col2 FROM tab1 AS cor0
----
129
3847
4784

onlyif mysql # use DIV operator for integer division
query I rowsort label-3414
SELECT + col2 DIV col1 + + cor0.col0 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3414
SELECT + col2 / col1 + + cor0.col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT tab1.col0 * - 27 + col2 * col2 AS col0 FROM tab1
----
1521
2835
7056

query I rowsort
SELECT col2 * + col0 + col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL + ( - 44 ) AS col1 FROM tab0
----
-44
-44
-44

query I rowsort
SELECT - col2 * + 4 * col0 FROM tab1
----
-14592
-30720
-648

onlyif mysql # use DIV operator for integer division
query I rowsort label-3419
SELECT + col2 DIV - cor0.col0 + + col2 AS col1 FROM tab1 AS cor0
----
36
57
95

skipif mysql # not compatible
query I rowsort label-3419
SELECT + col2 / - cor0.col0 + + col2 AS col1 FROM tab1 AS cor0
----
36
57
95

query I rowsort
SELECT DISTINCT + 97 * col0 AS col2 FROM tab0 AS cor0
----
2328
3395
8633

query I rowsort
SELECT DISTINCT + col1 + - 77 FROM tab2 AS cor0
----
-18
-46
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + col1 * col1 + col2 col1 FROM tab1 AS cor0
----
221
345
733

query I rowsort
SELECT DISTINCT 44 FROM tab2, tab2 AS cor0
----
44

query I rowsort
SELECT + 15 * 24 FROM tab1
----
360
360
360

onlyif mysql # use DIV operator for integer division
query I rowsort label-3425
SELECT ALL + col2 + col0 + col1 DIV col0 FROM tab0 AS cor0
----
172
38
60

skipif mysql # not compatible
query I rowsort label-3425
SELECT ALL + col2 + col0 + col1 / col0 FROM tab0 AS cor0
----
172
38
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col2 ) * + col2 + + 44 * col0 col0 FROM tab2 AS cor0
----
1037
4108
4920

query I rowsort
SELECT DISTINCT + col0 + col1 + - col2 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT ALL - - 75 + - col0 - + col0 FROM tab0 AS cor0
----
-103
27
5

query I rowsort
SELECT ALL + col2 + + col0 * + cor0.col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT col0 + ( col2 ) * + col1 AS col1 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3431
SELECT ALL + + cor0.col1 + - CAST( col1 AS SIGNED ) * - col0 col2 FROM tab2 AS cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3431
SELECT ALL + + cor0.col1 + - CAST ( col1 AS INTEGER ) * - col0 col2 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3432
SELECT DISTINCT - col0 + + CAST( NULL AS SIGNED ) + 50 * + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3432
SELECT DISTINCT - col0 + + CAST ( NULL AS INTEGER ) + 50 * + col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + col2 * - col2 + 35 * cor0.col0 AS col0 FROM tab1 AS cor0
----
12016
3021
5489

query I rowsort
SELECT + col1 + ( 41 ) AS col1 FROM tab0 AS cor0
----
127
132
138

query I rowsort
SELECT - cor0.col0 FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3436
SELECT + col1 * CAST( NULL AS DECIMAL ) + col2 * col1 * cor0.col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3436
SELECT + col1 * CAST ( NULL AS REAL ) + col2 * col1 * cor0.col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + 70 FROM tab1, tab0 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 44 + + col0 col1 FROM tab1 AS cor0
----
108
124
47

query I rowsort
SELECT 93 * col1 FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT + col1 + - col0 * col2 FROM tab1 AS cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 98 col2 FROM tab2 AS cor0
----
-98

query I rowsort
SELECT DISTINCT + 78 AS col0 FROM tab0 AS cor0
----
78

query I rowsort
SELECT ALL - - col1 * cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - cor0.col2 * - col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3446
SELECT ALL col1 * CAST( NULL AS SIGNED ) + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3446
SELECT ALL col1 * CAST ( NULL AS INTEGER ) + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col2 + col0 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL cor0.col1 + ( col1 ) AS col0 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT + col2 + - 98 * 75 FROM tab0 AS cor0
----
-7268
-7317
-7349

query I rowsort
SELECT ALL - + col2 + - 40 FROM tab1 AS cor0
----
-136
-94
-97

query I rowsort
SELECT ALL - col1 + - tab2.col2 * + col0 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT - ( cor0.col1 ) * col1 AS col0 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT - + col1 + col2 AS col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT ALL + - col2 + 21 FROM tab2 cor0
----
-17
-5
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3455
SELECT ALL + - cor0.col1 DIV cor0.col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3455
SELECT ALL + - cor0.col1 / cor0.col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + col1 * 2 + cor0.col1 AS col2 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT ALL - ( ( - cor0.col1 ) ) + + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT cor0.col1 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - tab1.col0 * ( - col0 ) AS col1 FROM tab1
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3460
SELECT + + 53 DIV + col1 + col0 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3460
SELECT + + 53 / + col1 + col0 AS col1 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3461
SELECT ALL - - col1 + + col1 * col2 DIV - col2 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3461
SELECT ALL - - col1 + + col1 * col2 / - col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - col1 + col0 * col2 AS col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL - + 50 FROM tab0, tab1, tab1 cor0
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

onlyif mysql # use DIV operator for integer division
query I rowsort label-3464
SELECT ALL + 15 DIV + col2 col1 FROM tab0 AS cor0
----
0
0
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3464
SELECT ALL + 15 / + col2 col1 FROM tab0 AS cor0
----
0
0
15

query I rowsort
SELECT + 62 AS col1 FROM tab2 AS cor0
----
62
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col2 * 58 + col2 col0 FROM tab0 AS cor0
----
390074
59
63195

query I rowsort
SELECT DISTINCT - + col0 + cor0.col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + + col1 - - col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT col0 * + col2 * col2 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT - col0 + - col1 * 23 * col0 + - col1 FROM tab0 cor0
----
-186457
-47582
-78217

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 94 + - col2 col2 FROM tab2
----
56
67
68

query I rowsort
SELECT ALL ( - ( + col1 ) ) * + 27 AS col2 FROM tab0
----
-2322
-2457
-2619

onlyif mysql # use DIV operator for integer division
query I rowsort label-3473
SELECT - 64 DIV col1 FROM tab2 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-3473
SELECT - 64 / col1 FROM tab2 cor0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT 29 * + 10 AS col2 FROM tab1 AS cor0
----
290

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3475
SELECT - + CAST( NULL AS SIGNED ) / 51 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-3475
SELECT - + CAST ( NULL AS INTEGER ) / 51 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2, tab1 AS cor2, tab1
----
13122 values hashing to 11b7a9a87da0088d23991542300883c3

query I rowsort
SELECT col1 + 70 AS col2 FROM tab0
----
156
161
167

query I rowsort
SELECT + + 54 + 76 FROM tab1 AS cor0
----
130
130
130

query I rowsort
SELECT DISTINCT + - col1 * col2 - cor0.col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT cor1.col2 FROM tab0, tab1, tab2 AS cor0, tab2 AS cor1
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL - 18 * - tab1.col0 + col2 AS col1 FROM tab1
----
108
1209
1536

query I rowsort
SELECT ALL - ( + tab1.col0 ) + - 40 FROM tab1
----
-104
-120
-43

query I rowsort
SELECT ALL col0 * - col0 + - 96 AS col0 FROM tab1
----
-105
-4192
-6496

query I rowsort
SELECT ALL ( + col1 ) * + col1 + 71 AS col1 FROM tab2
----
1032
3552
360

onlyif mysql # use DIV operator for integer division
query I rowsort label-3485
SELECT ALL + col2 + - col2 DIV 16 FROM tab1 AS cor0
----
51
54
90

skipif mysql # not compatible
query I rowsort label-3485
SELECT ALL + col2 + - col2 / 16 FROM tab1 AS cor0
----
51
54
90

query I rowsort
SELECT + col2 + + col1 + col0 * + ( col2 ) FROM tab1 AS cor0
----
242
3715
7789

onlyif mysql # use DIV operator for integer division
query I rowsort label-3487
SELECT col2 DIV + col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3487
SELECT col2 / + col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + - col1 + - ( + col1 * col1 ) AS col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT DISTINCT + + cor0.col0 + col1 + + ( cor0.col1 ) * + 93 FROM tab1 AS cor0
----
1004
1302
2447

query I rowsort
SELECT ALL - col2 * 38 FROM tab2 AS cor0
----
-1026
-1444
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * 13 + - 36 * col1 col1 FROM tab2 cor0
----
-118
-1786
-765

query I rowsort
SELECT ALL col2 * - cor0.col2 - + col2 AS col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT DISTINCT col2 + - col0 * ( + cor0.col2 ) AS col2 FROM tab2 cor0
----
-162
-2002
-2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3494
SELECT DISTINCT + col1 * + CAST( - ( + col2 ) AS SIGNED ) + col2 * col0 AS col2 FROM tab1 AS cor0
----
-1242
3078
6432

skipif mysql # not compatible
query I rowsort label-3494
SELECT DISTINCT + col1 * + CAST ( - ( + col2 ) AS INTEGER ) + col2 * col0 AS col2 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT + + col0 * col1 + ( + cor0.col0 ) FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + - col2 * cor0.col0 col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL + col0 * 18 + cor0.col0 AS col2 FROM tab1 AS cor0
----
1216
1520
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3498
SELECT DISTINCT + col1 DIV - col1 + + 70 * col1 FROM tab2 cor0
----
1189
2169
4129

skipif mysql # not compatible
query I rowsort label-3498
SELECT DISTINCT + col1 / - col1 + + 70 * col1 FROM tab2 cor0
----
1189
2169
4129

query I rowsort
SELECT ALL + cor0.col1 + - ( 27 ) - col0 AS col2 FROM tab2 AS cor0
----
-3
-46
-89

query I rowsort
SELECT DISTINCT - cor0.col2 - cor0.col2 FROM tab1 AS cor0
----
-108
-114
-192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3501
SELECT ALL - col1 * - CAST( NULL AS SIGNED ) * cor0.col0 + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3501
SELECT ALL - col1 * - CAST ( NULL AS INTEGER ) * cor0.col0 + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * ( col2 ) AS col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT col2 * 91 FROM tab1
----
4914
5187
8736

query I rowsort
SELECT + col2 * ( tab1.col2 + tab1.col2 ) AS col2 FROM tab1
----
18432
5832
6498

query I rowsort
SELECT + ( ( - cor0.col2 ) ) FROM tab1, tab0 cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT - + col2 * 8 + col2 AS col2 FROM tab1 AS cor0
----
-378
-399
-672

query I rowsort
SELECT - cor0.col1 * + 38 FROM tab2 AS cor0
----
-1178
-2242
-646

query I rowsort
SELECT col2 + 81 AS col1 FROM tab1 AS cor0
----
135
138
177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3509
SELECT + CAST( NULL AS SIGNED ) + + col0 * - cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3509
SELECT + CAST ( NULL AS INTEGER ) + + col0 * - cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 * + col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + + cor0.col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + col1 * - 59 AS col0 FROM tab0
----
-5074
-5369
-5723

query I rowsort
SELECT DISTINCT 22 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
22

query I rowsort
SELECT col2 * 75 AS col2 FROM tab0
----
2475
6150
75

query I rowsort
SELECT ( - col2 ) + 73 FROM tab2 AS cor0
----
35
46
47

query I rowsort
SELECT - - col0 * - col2 + 63 FROM tab0 AS cor0
----
-7235
-729
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-3517
SELECT col2 * col2 + col0 * ( col0 + col0 ) DIV - col1 AS col1 FROM tab1 AS cor0
----
2430
2916
8232

skipif mysql # not compatible
query I rowsort label-3517
SELECT col2 * col2 + col0 * ( col0 + col0 ) / - col1 AS col1 FROM tab1 AS cor0
----
2430
2916
8232

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3518
SELECT + col2 + - col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3518
SELECT + col2 + - col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - col1 col1 FROM tab0
----
-110
-132
-180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3520
SELECT ( tab2.col2 ) + col0 * - CAST( col0 AS SIGNED ) AS col2 FROM tab2
----
-22
-6058
-6203

skipif mysql # not compatible
query I rowsort label-3520
SELECT ( tab2.col2 ) + col0 * - CAST ( col0 AS INTEGER ) AS col2 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT 14 AS col0 FROM tab0
----
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-3522
SELECT - - 57 DIV + cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3522
SELECT - - 57 / + cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3523
SELECT + col2 + col0 DIV - ( col2 ) FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-3523
SELECT + col2 + col0 / - ( col2 ) FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT DISTINCT 95 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
95

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT col1 + 63 AS col1 FROM tab0 AS cor0
----
149
154
160

query I rowsort
SELECT - + 4 AS col2 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col1 AS REAL ) * cor0.col2 * + col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3529
SELECT CAST( NULL AS SIGNED ) * col1 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-3529
SELECT CAST ( NULL AS INTEGER ) * col1 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( col1 ) + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + col0 + - 18 * col1 + + col2 FROM tab2 cor0
----
-189
-524
-958

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3532
SELECT + - CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3532
SELECT + - CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + - col2 * + 59 FROM tab1 AS cor0
----
-3186
-3363
-5664

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3534
SELECT CAST( cor0.col0 AS SIGNED ) AS col1 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif mysql # not compatible
query I rowsort label-3534
SELECT CAST ( cor0.col0 AS INTEGER ) AS col1 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # use DIV operator for integer division
query I rowsort label-3535
SELECT DISTINCT col1 DIV - col0 AS col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-3535
SELECT DISTINCT col1 / - col0 AS col0 FROM tab0 AS cor0
----
-1
-2
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3536
SELECT ALL col2 DIV - col1 + - ( 9 ) FROM tab0 AS cor0
----
-9
-9
-9

skipif mysql # not compatible
query I rowsort label-3536
SELECT ALL col2 / - col1 + - ( 9 ) FROM tab0 AS cor0
----
-9
-9
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3537
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - tab1.col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3537
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - tab1.col1 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3538
SELECT - col0 + col2 DIV - col0 + cor0.col2 FROM tab2 AS cor0
----
-41
-52
17

skipif mysql # not compatible
query I rowsort label-3538
SELECT - col0 + col2 / - col0 + cor0.col2 FROM tab2 AS cor0
----
-41
-52
17

query I rowsort
SELECT ALL + 98 FROM tab2
----
98
98
98

query I rowsort
SELECT col1 * - ( col0 ) * col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT 48 FROM tab0, tab0 AS cor0
----
48

query I rowsort
SELECT DISTINCT cor0.col0 * 46 FROM tab1, tab2 cor0
----
322
3588
3634

query I rowsort
SELECT DISTINCT col1 * - ( col2 ) FROM tab0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3544
SELECT - col1 + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3544
SELECT - col1 + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col0 + 93 AS col1 FROM tab2 AS cor0
----
100
171
172

query I rowsort
SELECT cor0.col2 * - col1 + + col0 * col0 FROM tab0 AS cor0
----
-2262
1128
459

onlyif mysql # use DIV operator for integer division
query I rowsort label-3547
SELECT DISTINCT 67 DIV cor0.col1 FROM tab0, tab2 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3547
SELECT DISTINCT 67 / cor0.col1 FROM tab0, tab2 AS cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3548
SELECT DISTINCT - ( + cor0.col1 ) + 93 DIV + cor0.col2 FROM tab1, tab1 AS cor0
----
-13
-25
-9

skipif mysql # not compatible
query I rowsort label-3548
SELECT DISTINCT - ( + cor0.col1 ) + 93 / + cor0.col2 FROM tab1, tab1 AS cor0
----
-13
-25
-9

query I rowsort
SELECT ALL col0 * - ( col2 ) + col1 FROM tab1
----
-136
-3638
-7667

query IIIIII rowsort
SELECT * FROM tab0, tab1 cor0 WHERE NULL > NULL
----

query I rowsort
SELECT ALL - 56 * cor0.col0 * col1 + + col2 FROM tab1 AS cor0
----
-35783
-4314
-58144

query I rowsort
SELECT DISTINCT - tab2.col1 * + col2 * col2 + + col0 * - col2 AS col0 FROM tab2
----
-22788
-27550
-41912

query I rowsort
SELECT + col0 + ( 84 ) * - col0 AS col1 FROM tab0
----
-1992
-2905
-7387

query I rowsort
SELECT DISTINCT - 7 AS col1 FROM tab2
----
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col2 FROM tab0, tab0 cor0
----
1
33
82

query I rowsort
SELECT - - ( + cor0.col2 ) AS col2 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3557
SELECT CAST( NULL AS SIGNED ) / cor0.col2 + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3557
SELECT CAST ( NULL AS INTEGER ) / cor0.col2 + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 86 + cor0.col2 AS col2 FROM tab0 AS cor0
----
-4
-53
-85

query I rowsort
SELECT + - 52 * + col0 FROM tab1 AS cor0
----
-156
-3328
-4160

onlyif mysql # use DIV operator for integer division
query I rowsort label-3560
SELECT ALL 56 DIV + 24 FROM tab2 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-3560
SELECT ALL 56 / + 24 FROM tab2 AS cor0
----
2
2
2

query I rowsort
SELECT ALL 80 - + ( col0 ) * col2 FROM tab2 AS cor0
----
-109
-1948
-2922

query I rowsort
SELECT ALL - 42 FROM tab2, tab1 AS cor0
----
9 values hashing to 9894093f29c0defae91347934f060329

query I rowsort
SELECT ALL + ( col1 ) + + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3564
SELECT ALL - col0 - + 44 DIV + col1 FROM tab2 AS cor0
----
-78
-8
-81

skipif mysql # not compatible
query I rowsort label-3564
SELECT ALL - col0 - + 44 / + col1 FROM tab2 AS cor0
----
-78
-8
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3565
SELECT 31 * + col1 + - col1 DIV - col0 - col2 FROM tab0
----
2636
2740
3008

skipif mysql # not compatible
query I rowsort label-3565
SELECT 31 * + col1 + - col1 / - col0 - col2 FROM tab0
----
2636
2740
3008

query I rowsort
SELECT + tab2.col1 + col0 - + col2 FROM tab2
----
11
111
58

query I rowsort
SELECT cor0.col0 * cor0.col2 + + 48 AS col0 FROM tab0 AS cor0
----
7346
83
840

query I rowsort
SELECT - col0 + - cor0.col0 + - ( + col2 ) AS col0 FROM tab2 cor0
----
-182
-196
-41

query I rowsort
SELECT + col1 * + 37 - + 65 FROM tab1 AS cor0
----
305
416
897

query I rowsort
SELECT DISTINCT + + col0 * cor0.col2 + - col1 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT col0 + 29 AS col1 FROM tab2 AS cor0
----
107
108
36

query I rowsort
SELECT DISTINCT col2 + + 84 - 94 AS col1 FROM tab1 AS cor0
----
44
47
86

query I rowsort
SELECT ALL cor0.col0 * col2 - + col1 AS col0 FROM tab0 cor0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3574
SELECT + col0 + CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3574
SELECT + col0 + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3575
SELECT DISTINCT + + col0 * cor0.col2 DIV col1 + + col2 + col1 FROM tab0 AS cor0
----
128
253
98

skipif mysql # not compatible
query I rowsort label-3575
SELECT DISTINCT + + col0 * cor0.col2 / col1 + + col2 + col1 FROM tab0 AS cor0
----
128
253
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3576
SELECT ALL - col1 + + CAST( 36 AS SIGNED ) * + cor0.col0 AS col2 FROM tab2 AS cor0
----
221
2749
2827

skipif mysql # not compatible
query I rowsort label-3576
SELECT ALL - col1 + + CAST ( 36 AS INTEGER ) * + cor0.col0 AS col2 FROM tab2 AS cor0
----
221
2749
2827

query I rowsort
SELECT ALL - + col1 * ( col1 ) * col1 FROM tab0 cor0
----
-636056
-753571
-912673

query I rowsort
SELECT ALL ( + col1 ) * col0 AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT - 17 * col0 FROM tab1
----
-1088
-1360
-51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 12 col1 FROM tab0
----
-12
-12
-12

onlyif mysql # use DIV operator for integer division
query I rowsort label-3581
SELECT DISTINCT 1 DIV - col0 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3581
SELECT DISTINCT 1 / - col0 FROM tab0 cor0
----
0

query I rowsort
SELECT - col2 * + col1 + col0 + 22 * col0 FROM tab0 AS cor0
----
-2286
-5415
708

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3583
SELECT DISTINCT CAST( + 21 AS SIGNED ) col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3583
SELECT DISTINCT CAST ( + 21 AS INTEGER ) col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
21

query I rowsort
SELECT ALL 30 * col0 + - col2 FROM tab2 AS cor0
----
183
2314
2332

onlyif mysql # use DIV operator for integer division
query I rowsort label-3585
SELECT col1 DIV + col1 AS col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3585
SELECT col1 / + col1 AS col1 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3586
SELECT DISTINCT + CAST( + 42 AS SIGNED ) + + col2 FROM tab1
----
138
96
99

skipif mysql # not compatible
query I rowsort label-3586
SELECT DISTINCT + CAST ( + 42 AS INTEGER ) + + col2 FROM tab1
----
138
96
99

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab0, tab0 cor1
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

query I rowsort
SELECT ALL 69 + col0 * - col1 AS col1 FROM tab0
----
-1995
-3326
-8030

onlyif mysql # use DIV operator for integer division
query I rowsort label-3589
SELECT 95 DIV 15 AS col1 FROM tab2
----
6
6
6

skipif mysql # not compatible
query I rowsort label-3589
SELECT 95 / 15 AS col1 FROM tab2
----
6
6
6

query I rowsort
SELECT - - col2 * col2 + col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT 5 + - col1 * col0 * - col1 AS col1 FROM tab1
----
13525
2033
6405

query I rowsort
SELECT DISTINCT - 18 AS col0 FROM tab0, tab1 AS cor0
----
-18

query I rowsort
SELECT DISTINCT cor0.col2 AS col1 FROM tab2, tab1, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col0 + - cor0.col0 * - col2 + col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col1 * cor0.col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - 31 + - col2 AS col0 FROM tab0 AS cor0
----
-113
-32
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3597
SELECT + CAST( NULL AS SIGNED ) + + 11 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3597
SELECT + CAST ( NULL AS INTEGER ) + + 11 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - 93 AS col0 FROM tab0, tab2, tab0 AS cor0
----
-93

query I rowsort
SELECT - col2 * col0 + - col0 FROM tab2
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT + col1 * + col2 - col1 FROM tab0
----
0
2752
7371

query I rowsort
SELECT DISTINCT - - ( + col2 ) + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + ( col0 ) * - col0 * ( 37 * col2 ) + + col2 FROM tab2 cor0
----
-48924
-5852782
-8774808

onlyif mysql # use DIV operator for integer division
query I rowsort label-3603
SELECT DISTINCT - ( 81 ) DIV + col1 + - ( + col0 ) AS col2 FROM tab2 AS cor0
----
-79
-83
-9

skipif mysql # not compatible
query I rowsort label-3603
SELECT DISTINCT - ( 81 ) / + col1 + - ( + col0 ) AS col2 FROM tab2 AS cor0
----
-79
-83
-9

query I rowsort
SELECT + + col2 - - 88 FROM tab1 AS cor0
----
142
145
184

query I rowsort
SELECT ALL + col2 * - col1 AS col0 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3606
SELECT - col1 DIV + 35 + tab2.col2 * - col1 AS col2 FROM tab2
----
-1535
-646
-837

skipif mysql # not compatible
query I rowsort label-3606
SELECT - col1 / + 35 + tab2.col2 * - col1 AS col2 FROM tab2
----
-1535
-646
-837

query I rowsort
SELECT col0 + col1 + + col1 * - col2 AS col1 FROM tab1
----
-1155
-1375
-496

query I rowsort
SELECT + col2 - col1 * + col1 * + col0 AS col0 FROM tab2
----
-22793
-271492
-6700

query I rowsort
SELECT DISTINCT - + col1 * - col1 + - col0 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT ALL + cor0.col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT DISTINCT 60 * col2 + + col0 AS col1 FROM tab1 AS cor0
----
3243
3484
5840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3612
SELECT ALL - 99 DIV - col2 AS col0 FROM tab0 AS cor0
----
1
3
99

skipif mysql # not compatible
query I rowsort label-3612
SELECT ALL - 99 / - col2 AS col0 FROM tab0 AS cor0
----
1
3
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-3613
SELECT + col1 + col2 DIV cor0.col2 FROM tab0 cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3613
SELECT + col1 + col2 / cor0.col2 FROM tab0 cor0
----
87
92
98

query I rowsort
SELECT DISTINCT - - 6 * 22 + col0 AS col0 FROM tab2 AS cor0
----
139
210
211

query I rowsort
SELECT ALL 32 + col1 FROM tab2 AS cor0
----
49
63
91

query I rowsort
SELECT ALL + - 18 AS col0 FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + col1 + + 87 - col1 FROM tab1 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT + 6 + 31 AS col0 FROM tab1 AS cor0
----
37

query I rowsort
SELECT DISTINCT 41 * + cor0.col1 AS col0 FROM tab2 cor0
----
1271
2419
697

query I rowsort
SELECT 28 - + col2 FROM tab0 AS cor0
----
-5
-54
27

query I rowsort
SELECT ALL - 16 * 36 + + cor0.col0 FROM tab2 AS cor0
----
-497
-498
-569

query I rowsort
SELECT + 26 + col1 AS col0 FROM tab2 AS cor0
----
43
57
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3623
SELECT DISTINCT + CAST( + 67 AS SIGNED ) + col0 * ( col0 ) FROM tab1 AS cor0
----
4163
6467
76

skipif mysql # not compatible
query I rowsort label-3623
SELECT DISTINCT + CAST ( + 67 AS INTEGER ) + col0 * ( col0 ) FROM tab1 AS cor0
----
4163
6467
76

query I rowsort
SELECT + col2 + - ( col1 ) AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + - col1 * 48 AS col1 FROM tab2 AS cor0
----
-1488
-2832
-816

query I rowsort
SELECT cor0.col1 - 77 FROM tab0 AS cor0
----
14
20
9

query I rowsort
SELECT DISTINCT ( col1 ) - - col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL 56 * col0 + col2 * - 64 FROM tab0
----
-264
-768
1896

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3629
SELECT ALL - CAST( 86 AS SIGNED ) * - tab0.col2 + 8 AS col0 FROM tab0
----
2846
7060
94

skipif mysql # not compatible
query I rowsort label-3629
SELECT ALL - CAST ( 86 AS INTEGER ) * - tab0.col2 + 8 AS col0 FROM tab0
----
2846
7060
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + 94 col0 FROM tab0
----
127
176
95

query I rowsort
SELECT DISTINCT ( - 6 ) + col1 * ( - col2 + col2 ) FROM tab2 cor0
----
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3632
SELECT ALL - col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3632
SELECT ALL - col0 / + col0 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - 64 * 90 FROM tab1 cor0
----
-5760
-5760
-5760

query I rowsort
SELECT ALL - + 49 AS col2 FROM tab1 AS cor0
----
-49
-49
-49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + + col0 col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col0 + col1 * cor0.col2 FROM tab0 AS cor0
----
2814
62
7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-3637
SELECT DISTINCT + + col1 DIV + 64 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3637
SELECT DISTINCT + + col1 / + 64 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3638
SELECT col2 DIV - 98 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3638
SELECT col2 / - 98 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - 35 * tab1.col0 AS col2 FROM tab1
----
-105
-2240
-2800

query I rowsort
SELECT + + col1 + - cor0.col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + cor0.col1 col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 20 * + col2 col0 FROM tab2 AS cor0
----
520
540
760

query I rowsort
SELECT - 44 + col0 FROM tab1 AS cor0
----
-41
20
36

query I rowsort
SELECT DISTINCT + + col2 * + col2 * - col2 + 92 FROM tab0 AS cor0
----
-35845
-551276
91

query I rowsort
SELECT - - 15 + col1 FROM tab2 cor0
----
32
46
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-3646
SELECT + col1 DIV cor0.col2 + + col1 FROM tab0 AS cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-3646
SELECT + col1 / cor0.col2 + + col1 FROM tab0 AS cor0
----
194
88
92

query I rowsort
SELECT + + 37 - - col1 AS col0 FROM tab1 AS cor0
----
47
50
63

query I rowsort
SELECT - col1 * cor0.col0 + col1 * col2 AS col2 FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT - - col2 * col2 - + col1 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT ALL - col0 + col2 * cor0.col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT - + 25 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 40ac8fd000b2e49317aed2411077839e

onlyif mysql # use DIV operator for integer division
query I rowsort label-3652
SELECT - - cor0.col0 DIV + 62 AS col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3652
SELECT - - cor0.col0 / + 62 AS col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT + + col0 * - col1 + - col2 FROM tab1 AS cor0
----
-1136
-132
-697

onlyif mysql # use DIV operator for integer division
query I rowsort label-3654
SELECT - col0 * - col0 DIV + cor0.col0 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3654
SELECT - col0 * - col0 / + cor0.col0 FROM tab1 cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3655
SELECT + + cor0.col1 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3655
SELECT + + cor0.col1 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * + 46 FROM tab0 AS cor0
----
1104
1610
4094

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3657
SELECT DISTINCT + col2 * CAST( NULL AS DECIMAL ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3657
SELECT DISTINCT + col2 * CAST ( NULL AS REAL ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - cor0.col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + cor0.col0 * col0 AS col0 FROM tab2 cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 71 col2 FROM tab2 AS cor0
----
71
71
71

query I rowsort
SELECT ALL + col2 * col0 * tab0.col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT ALL + col1 + ( - 26 * + col1 ) FROM tab2
----
-1475
-425
-775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * col2 + 66 col1 FROM tab1 AS cor0
----
-2850
-3183
-9150

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT - 90 FROM tab1 cor0
----
-90
-90
-90

query I rowsort
SELECT DISTINCT + - col2 + ( + col0 + cor0.col2 ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - col0 * - 15 AS col2 FROM tab2 AS cor0
----
105
1170
1185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col0 ) col1 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3670
SELECT ALL + cor0.col2 DIV + 33 + col0 * col0 * 51 FROM tab0 AS cor0
----
29377
403973
62475

skipif mysql # not compatible
query I rowsort label-3670
SELECT ALL + cor0.col2 / + 33 + col0 * col0 * 51 FROM tab0 AS cor0
----
29377
403973
62475

query I rowsort
SELECT - 46 * col0 AS col1 FROM tab2 AS cor0
----
-322
-3588
-3634

query I rowsort
SELECT ALL - col2 - - ( + col2 ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 * col2 + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL col0 * col1 - + col1 AS col0 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-3675
SELECT ALL - col0 + - 60 DIV + col1 AS col1 FROM tab2 cor0
----
-79
-8
-82

skipif mysql # not compatible
query I rowsort label-3675
SELECT ALL - col0 + - 60 / + col1 AS col1 FROM tab2 cor0
----
-79
-8
-82

query I rowsort
SELECT DISTINCT ( col0 ) + - col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - 57 + - col1 * - col2 - - 22 * cor0.col0 AS col0 FROM tab2 AS cor0
----
2327
3193
934

query I rowsort
SELECT 73 * - col1 * + col2 + 9 * col2 FROM tab1 AS cor0
----
-102006
-41097
-90240

query I rowsort
SELECT DISTINCT + - cor0.col0 * + col1 + 53 * - col0 AS col0 FROM tab2 AS cor0
----
-5530
-588
-8736

query I rowsort
SELECT ALL + col1 + + col1 + + col0 FROM tab1
----
106
55
84

query I rowsort
SELECT - col2 + col1 + 39 AS col2 FROM tab2 AS cor0
----
18
43
72

query I rowsort
SELECT DISTINCT + col0 * + col1 - + col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT - col1 * 21 + + ( - col1 ) FROM tab1 AS cor0
----
-220
-286
-572

query I rowsort
SELECT + cor0.col2 + + col2 * + col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL col2 * ( - col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort
SELECT col0 * - CAST ( col0 AS REAL ) + col2 * - col2 AS col1 FROM tab2 AS cor0
----
-6760
-7685
-778

query I rowsort
SELECT DISTINCT - 46 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
-46

query I rowsort
SELECT ALL 64 AS col1 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT - - col2 + col1 - col0 AS col0 FROM tab0 AS cor0
----
63
84
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * - 57 col1 FROM tab2 cor0
----
-1482
-1539
-2166

onlyif mysql # use DIV operator for integer division
query I rowsort label-3691
SELECT col1 * 65 DIV + cor0.col0 FROM tab1 AS cor0
----
10
10
563

skipif mysql # not compatible
query I rowsort label-3691
SELECT col1 * 65 / + cor0.col0 FROM tab1 AS cor0
----
10
10
563

query I rowsort
SELECT ALL - - col0 * 41 FROM tab0 AS cor0
----
1435
3649
984

query I rowsort
SELECT + col2 + 26 * col0 + - col1 * - col0 AS col0 FROM tab2 AS cor0
----
3435
426
6656

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col2 * - cor0.col2 col1 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT DISTINCT col2 * + ( col0 ) + col2 AS col2 FROM tab1 cor0
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3696
SELECT DISTINCT - col0 + CAST( 62 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-27
27
38

skipif mysql # not compatible
query I rowsort label-3696
SELECT DISTINCT - col0 + CAST ( 62 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-27
27
38

query I rowsort
SELECT + col0 * ( - col1 * - col1 ) + 53 * + col0 FROM tab1 cor0
----
17760
2187
9792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3698
SELECT col0 + CAST( + col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-3698
SELECT col0 + CAST ( + col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3699
SELECT - col1 DIV tab0.col1 AS col1 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3699
SELECT - col1 / tab0.col1 AS col1 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT 84 + col1 FROM tab1
----
110
94
97

query I rowsort
SELECT ALL col0 * col0 * - ( 48 ) - col0 * + col0 AS col2 FROM tab1
----
-200704
-313600
-441

query I rowsort
SELECT DISTINCT - 8 - - col1 AS col2 FROM tab2
----
23
51
9

query I rowsort
SELECT DISTINCT col0 + + col0 * - 0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + col2 + 60 FROM tab0 AS cor0
----
142
61
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col2 + col1 col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL cor0.col1 + 6 * - col1 AS col1 FROM tab2 AS cor0
----
-155
-295
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3707
SELECT - col2 * + 48 + col2 DIV col2 - col0 DIV + col1 FROM tab1 AS cor0
----
-2591
-2741
-4613

skipif mysql # not compatible
query I rowsort label-3707
SELECT - col2 * + 48 + col2 / col2 - col0 / + col1 FROM tab1 AS cor0
----
-2591
-2741
-4613

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * - ( col2 ) col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - - col1 * col1 AS col2 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT + 99 + tab0.col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to dc5ad96a0ef423f9871d425cd2b21272

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3711
SELECT ALL col2 + - CAST( + col0 AS SIGNED ) * col2 * - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3711
SELECT ALL col2 + - CAST ( + col0 AS INTEGER ) * col2 * - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 - - col0 * col1 * + tab0.col1 FROM tab0
----
177528
329350
737098

query I rowsort
SELECT ALL 99 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3714
SELECT - CAST( + col1 AS SIGNED ) * - col2 * col1 FROM tab1 AS cor0
----
16224
36504
5700

skipif mysql # not compatible
query I rowsort label-3714
SELECT - CAST ( + col1 AS INTEGER ) * - col2 * col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT - 39 * - 36 FROM tab2 AS cor0
----
1404

onlyif mysql # use DIV operator for integer division
query I rowsort label-3716
SELECT col1 + 95 DIV - col2 FROM tab0
----
2
84
90

skipif mysql # not compatible
query I rowsort label-3716
SELECT col1 + 95 / - col2 FROM tab0
----
2
84
90

query I rowsort
SELECT - - 2 * + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT 67 * + tab0.col1 - col0 FROM tab0
----
5738
6008
6464

query I rowsort
SELECT ALL col1 + col1 - 30 AS col2 FROM tab0
----
142
152
164

query I rowsort
SELECT + tab0.col1 + - tab0.col2 * col0 + - col2 * col1 AS col1 FROM tab0
----
-14669
-35
-3544

query I rowsort
SELECT ( + col2 ) + tab0.col0 FROM tab0
----
171
36
57

query I rowsort
SELECT - + 92 AS col0 FROM tab0 AS cor0
----
-92
-92
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 89 col0 FROM tab0 AS cor0
----
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT 90 - + cor1.col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 304011b3523fdadeef34e4837ec29188

query I rowsort
SELECT DISTINCT - 44 + 12 AS col2 FROM tab0
----
-32

query I rowsort
SELECT - tab2.col2 * 82 AS col1 FROM tab2
----
-2132
-2214
-3116

query I rowsort
SELECT ALL + - 53 * col2 - col0 FROM tab2 AS cor0
----
-1438
-1456
-2093

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 * - 73 + cor0.col0 col2 FROM tab1 cor0
----
-5176
-5192
-5253

query I rowsort
SELECT DISTINCT - 17 + + col1 FROM tab0
----
69
74
80

query I rowsort
SELECT + col1 - 29 * + col1 FROM tab0 AS cor0
----
-2408
-2548
-2716

query I rowsort
SELECT DISTINCT ( 86 ) FROM tab2 AS cor0
----
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 + cor0.col0 col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - col1 * + ( + col2 ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - 34 * col2 - - cor0.col2 * col2 FROM tab2 AS cor0
----
-189
-208
152

query I rowsort
SELECT + cor0.col2 - - 86 * col1 AS col1 FROM tab0 AS cor0
----
7429
7908
8343

query I rowsort
SELECT ALL + 25 + - col0 * col2 FROM tab0 AS cor0
----
-10
-7273
-767

query I rowsort
SELECT ALL - 25 - + col2 FROM tab1 AS cor0
----
-121
-79
-82

query I rowsort
SELECT DISTINCT - 29 * + 51 FROM tab2 AS cor0
----
-1479

query I rowsort
SELECT ALL + col1 * 42 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT col2 * col0 + ( - col1 ) FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT + + col0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT col0 + col0 + 70 * - col2 AS col1 FROM tab0 AS cor0
----
-2262
-5562
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 + + 57 col0 FROM tab1 AS cor0
----
-4039
-6343
48

query I rowsort
SELECT ALL col0 * + 14 * col2 AS col1 FROM tab2 cor0
----
2646
28392
42028

query I rowsort
SELECT DISTINCT + col2 * 51 * 69 FROM tab1 AS cor0
----
190026
200583
337824

query I rowsort
SELECT 46 + col1 AS col0 FROM tab1
----
56
59
72

query I rowsort
SELECT DISTINCT + + cor0.col1 * col0 AS col1 FROM tab1 cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3749
SELECT + col1 DIV - 42 AS col1 FROM tab0 AS cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-3749
SELECT + col1 / - 42 AS col1 FROM tab0 AS cor0
----
-2
-2
-2

query I rowsort
SELECT ALL + + ( + tab0.col2 ) AS col2 FROM tab1, tab2, tab0 cor0, tab0
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT - + 94 * 98 AS col2 FROM tab2 AS cor0
----
-9212
-9212
-9212

query I rowsort
SELECT DISTINCT + tab2.col1 * - 0 FROM tab2
----
0

query I rowsort
SELECT - 19 FROM tab2, tab0 AS cor0
----
9 values hashing to 339c9d62143bf2f7566b89a1b56eeeb4

query I rowsort
SELECT + cor0.col1 * + cor0.col0 * + col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL - 92 * + ( - tab2.col2 ) FROM tab2
----
2392
2484
3496

query I rowsort
SELECT ALL 18 * ( col2 ) FROM tab1
----
1026
1728
972

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3757
SELECT + col1 + col0 * + cor0.col0 * - CAST( ( + col2 ) AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-233462
-460
-614387

skipif mysql # not compatible
query I rowsort label-3757
SELECT + col1 + col0 * + cor0.col0 * - CAST ( ( + col2 ) AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-233462
-460
-614387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 52 ) + cor0.col1 col0 FROM tab0 AS cor0
----
138
143
149

query I rowsort
SELECT - col1 * - col2 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + 44 AS col0 FROM tab0
----
44
44
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3761
SELECT - col1 + CAST( - 62 * col2 AS SIGNED ) col0 FROM tab1 AS cor0
----
-3374
-3544
-5965

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3761
SELECT - col1 + CAST ( - 62 * col2 AS INTEGER ) col0 FROM tab1 AS cor0
----
-3374
-3544
-5965

query I rowsort
SELECT ALL - - cor0.col1 FROM tab2, tab1, tab1 cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 75 + - col0 col0 FROM tab2 cor0
----
-153
-154
-82

query I rowsort
SELECT DISTINCT + + col0 + col2 - - 6 AS col0 FROM tab2 AS cor0
----
110
123
40

query I rowsort
SELECT DISTINCT - 29 AS col2 FROM tab0
----
-29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + 82 col2 FROM tab0 AS cor0
----
106
117
171

query I rowsort
SELECT col0 * 75 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT + 75 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT + - col2 * + 45 FROM tab0 cor0
----
-1485
-3690
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-3770
SELECT - col0 + col2 DIV + 51 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-3770
SELECT - col0 + col2 / + 51 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT ( col1 ) * col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL + 95 + col0 * - col0 FROM tab2 AS cor0
----
-5989
-6146
46

query I rowsort
SELECT DISTINCT - + 79 + + col2 + col0 AS col2 FROM tab2 cor0
----
-45
25
38

query I rowsort
SELECT ALL - 48 * col2 AS col2 FROM tab2 AS cor0
----
-1248
-1296
-1824

query I rowsort
SELECT DISTINCT + col1 + - cor0.col1 * 1 AS col0 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3776
SELECT - cor0.col1 * - col1 + col1 DIV col1 col2 FROM tab0 AS cor0
----
7397
8282
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3776
SELECT - cor0.col1 * - col1 + col1 / col1 col2 FROM tab0 AS cor0
----
7397
8282
9410

query I rowsort
SELECT col0 + + tab0.col2 + col1 * ( 41 ) FROM tab0
----
3583
3902
4013

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3778
SELECT ALL + col2 * col2 - + col1 * - CAST( + col2 AS SIGNED ) AS col0 FROM tab1
----
10464
3819
4320

skipif mysql # not compatible
query I rowsort label-3778
SELECT ALL + col2 * col2 - + col1 * - CAST ( + col2 AS INTEGER ) AS col0 FROM tab1
----
10464
3819
4320

query I rowsort
SELECT - col1 * - col2 + - col1 FROM tab2
----
1475
629
806

query I rowsort
SELECT + tab0.col0 * col0 AS col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + ( + ( - col0 ) ) AS col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT ALL + col0 * col0 + col2 * col0 AS col1 FROM tab0
----
1260
1368
15219

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - - col1 col1 FROM tab0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3784
SELECT ( + col1 ) + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3784
SELECT ( + col1 ) + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL 8 AS col2 FROM tab1 AS cor0
----
8
8
8

query I rowsort
SELECT DISTINCT - cor0.col0 + col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + 61 FROM tab1, tab2 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to 9b52d3939da22c8931e3d5a72ddfb1b1

query I rowsort
SELECT - + col1 * 10 AS col2 FROM tab1 AS cor0
----
-100
-130
-260

query I rowsort
SELECT - cor0.col2 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - - 49 * 5 + col2 FROM tab1 AS cor0
----
299
302
341

query I rowsort
SELECT + ( - col2 ) * - col2 + + col1 * col1 FROM tab2 AS cor0
----
1690
1733
4157

query I rowsort
SELECT - - 96 + col1 AS col0 FROM tab1 AS cor0
----
106
109
122

query I rowsort
SELECT DISTINCT - - ( cor0.col0 ) - col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - ( col0 ) * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - col1 * 52 FROM tab1 AS cor0
----
-1352
-520
-676

query I rowsort
SELECT 66 * + col2 FROM tab0 AS cor0
----
2178
5412
66

query I rowsort
SELECT ALL col1 * col1 * + col0 FROM tab1 AS cor0
----
13520
2028
6400

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0 CROSS JOIN tab1, tab0 cor1
----
972 values hashing to 5342fb4caf4767cb98bd21989bad099f

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 cor2
----
3645 values hashing to 53ea9df66efbebef5063fb0b15c25baa

query I rowsort
SELECT DISTINCT - col1 + col1 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT - - col2 * 53 * col2 AS col1 FROM tab0 AS cor0
----
356372
53
57717

query I rowsort
SELECT - + col0 + - ( col0 ) * - ( cor0.col0 ) FROM tab1 AS cor0
----
4032
6
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 62 * 85 col0 FROM tab0 AS cor0
----
5270
5270
5270

query I rowsort
SELECT DISTINCT + 27 FROM tab1 cor0
----
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-3806
SELECT DISTINCT - 33 + 2 DIV col2 + + ( 63 ) col1 FROM tab1 AS cor0
----
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3806
SELECT DISTINCT - 33 + 2 / col2 + + ( 63 ) col1 FROM tab1 AS cor0
----
30

query I rowsort
SELECT ( + 53 ) FROM tab0 AS cor0
----
53
53
53

query I rowsort
SELECT ALL - 20 * - col2 AS col0 FROM tab0 cor0
----
1640
20
660

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3809
SELECT + CAST( NULL AS SIGNED ) + - col2 * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3809
SELECT + CAST ( NULL AS INTEGER ) + - col2 * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( col2 ) * - col0 * 52 AS col1 FROM tab0 AS cor0
----
-1820
-379496
-41184

query I rowsort
SELECT 46 * col0 FROM tab1 AS cor0
----
138
2944
3680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3812
SELECT ( - col2 ) DIV cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-3812
SELECT ( - col2 ) / cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + 68 col1 FROM tab0 AS cor0
----
-1632
-2380
-6052

onlyif mysql # use DIV operator for integer division
query I rowsort label-3814
SELECT DISTINCT col2 + 88 DIV + col2 FROM tab0 AS cor0
----
35
83
89

skipif mysql # not compatible
query I rowsort label-3814
SELECT DISTINCT col2 + 88 / + col2 FROM tab0 AS cor0
----
35
83
89

query I rowsort
SELECT DISTINCT - col2 * - col2 + + col0 FROM tab2 cor0
----
1523
736
754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3816
SELECT DISTINCT + - col0 - - col2 / + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3816
SELECT DISTINCT + - col0 - - col2 / + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3817
SELECT + - col1 DIV col2 + col1 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3817
SELECT + - col1 / col2 + col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + col2 - col1 * col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT - - col0 + cor0.col1 * col2 + col1 FROM tab1 AS cor0
----
1341
1433
644

query I rowsort
SELECT DISTINCT 86 FROM tab1, tab1 AS cor0, tab1 cor1
----
86

query I rowsort
SELECT - - col0 + col2 + - col1 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT ALL - - col1 + + cor0.col2 + - col2 * + 7 FROM tab2 cor0
----
-131
-211
-97

query I rowsort
SELECT 77 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT ALL col0 * - ( - col0 ) - col2 AS col0 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT DISTINCT - 94 + - tab1.col1 AS col0 FROM tab1, tab1 AS cor0
----
-104
-107
-120

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2
----
3645 values hashing to a87c024a0045fd44371c9b28640799d7

query I rowsort
SELECT ALL tab1.col2 + + col2 - - col1 * col2 FROM tab1
----
1440
1512
684

skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 * CAST ( 86 AS REAL ) AS col0 FROM tab0 AS cor0
----
-7396
-7826
-8342

onlyif mysql # use DIV operator for integer division
query I rowsort label-3829
SELECT ALL - - col2 DIV ( + 76 ) AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3829
SELECT ALL - - col2 / ( + 76 ) AS col0 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3830
SELECT ALL + col0 + CAST( + col1 AS SIGNED ) FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-3830
SELECT ALL + col0 + CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - + col1 * - 99 * + cor0.col2 AS col0 FROM tab2 cor0
----
151866
63954
82863

onlyif mysql # use DIV operator for integer division
query I rowsort label-3832
SELECT col0 * col0 DIV + cor0.col1 AS col1 FROM tab0 AS cor0
----
12
6
87

skipif mysql # not compatible
query I rowsort label-3832
SELECT col0 * col0 / + cor0.col1 AS col1 FROM tab0 AS cor0
----
12
6
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3833
SELECT - col1 * CAST( - 93 AS SIGNED ) AS col1 FROM tab1 cor0
----
1209
2418
930

skipif mysql # not compatible
query I rowsort label-3833
SELECT - col1 * CAST ( - 93 AS INTEGER ) AS col1 FROM tab1 cor0
----
1209
2418
930

query I rowsort
SELECT - tab0.col0 * + 17 - - col0 AS col1 FROM tab0
----
-1424
-384
-560

query I rowsort
SELECT ALL col1 * 22 FROM tab1
----
220
286
572

query I rowsort
SELECT DISTINCT + + ( 40 ) FROM tab0 AS cor0
----
40

query I rowsort
SELECT ALL - col2 * ( + col1 ) AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT tab1.col2 * + 65 FROM tab1
----
3510
3705
6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-3839
SELECT DISTINCT col1 * 66 DIV + 2 FROM tab1
----
330
429
858

skipif mysql # not compatible
query I rowsort label-3839
SELECT DISTINCT col1 * 66 / + 2 FROM tab1
----
330
429
858

onlyif mysql # use DIV operator for integer division
query I rowsort label-3840
SELECT DISTINCT col0 * ( - col1 ) DIV - col1 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3840
SELECT DISTINCT col0 * ( - col1 ) / - col1 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT cor0.col2 * 80 + 74 FROM tab0, tab2 AS cor0
----
2154
2234
3114

query I rowsort
SELECT DISTINCT + - 10 AS col0 FROM tab1 AS cor0
----
-10

query I rowsort
SELECT ALL + ( col1 ) - col2 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - + 14 + col1 AS col0 FROM tab0 AS cor0
----
72
77
83

query I rowsort
SELECT DISTINCT + + 48 + col0 FROM tab2 AS cor0
----
126
127
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-3846
SELECT ALL cor0.col2 * + col1 DIV + cor0.col1 AS col2 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3846
SELECT ALL cor0.col2 * + col1 / + cor0.col1 AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + col2 * - col0 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL col2 * - 75 + + cor0.col0 * col0 AS col1 FROM tab1 AS cor0
----
-179
-4041
-800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 95 col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-3850
SELECT DISTINCT - col1 * cor0.col1 DIV 15 AS col1 FROM tab0 AS cor0
----
-493
-552
-627

skipif mysql # not compatible
query I rowsort label-3850
SELECT DISTINCT - col1 * cor0.col1 / 15 AS col1 FROM tab0 AS cor0
----
-493
-552
-627

onlyif mysql # use DIV operator for integer division
query I rowsort label-3851
SELECT ALL - col2 + - ( cor0.col1 ) DIV - col1 col2 FROM tab2 AS cor0
----
-25
-26
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3851
SELECT ALL - col2 + - ( cor0.col1 ) / - col1 col2 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT - + col1 + 90 FROM tab2 AS cor0
----
31
59
73

query IIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1, tab1 AS cor0 WHERE NULL <> NULL
----

query I rowsort
SELECT col2 * - 39 FROM tab1
----
-2106
-2223
-3744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 84 ) - col2 col1 FROM tab1 AS cor0
----
-138
-141
-180

query I rowsort
SELECT + - col2 * + 61 + - col0 AS col1 FROM tab1 AS cor0
----
-3297
-3541
-5936

query I rowsort
SELECT - cor1.col0 AS col1 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT 98 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT ALL + - 28 FROM tab2 AS cor0
----
-28
-28
-28

query I rowsort
SELECT + 81 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab1, tab2 cor0, tab0 AS cor1
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3862
SELECT ALL + CAST( + 9 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
9
9
9

skipif mysql # not compatible
query I rowsort label-3862
SELECT ALL + CAST ( + 9 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
9
9
9

query I rowsort
SELECT DISTINCT + 22 * col2 FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT + cor0.col1 * + col0 + col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL + col0 + 35 * col0 FROM tab2 AS cor0
----
252
2808
2844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 + + 77 col1 FROM tab1 AS cor0
----
103
87
90

query I rowsort
SELECT ALL - col1 * cor0.col2 + + 14 AS col1 FROM tab1 AS cor0
----
-1234
-1390
-556

query I rowsort
SELECT ALL col0 * + col1 + + 24 FROM tab2 AS cor0
----
1367
241
4626

onlyif mysql # use DIV operator for integer division
query I rowsort label-3869
SELECT ALL col2 DIV - col0 col0 FROM tab0 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3869
SELECT ALL col2 / - col0 col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT - - 20 * - col0 + ( - 13 ) * col1 FROM tab1 AS cor0
----
-1410
-1769
-398

query I rowsort
SELECT DISTINCT - - cor0.col1 * col1 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT ALL + col0 * col1 * cor0.col0 + + 87 + + col2 FROM tab2 AS cor0
----
106222
1633
359069

query I rowsort
SELECT 72 * tab1.col0 - - 58 FROM tab1, tab2 AS cor0
----
9 values hashing to ad8ad9dfa02e5c29fa13edf0065967b6

query I rowsort
SELECT + cor0.col1 * - col0 * col0 FROM tab1 cor0
----
-234
-40960
-83200

query I rowsort
SELECT - col1 * tab1.col1 + col2 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT ALL 55 * tab1.col2 AS col2 FROM tab1
----
2970
3135
5280

query I rowsort
SELECT DISTINCT - col2 + - col2 - - col2 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3878
SELECT ( - col0 ) + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3878
SELECT ( - col0 ) + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 5 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
5

query I rowsort
SELECT + col2 + - 83 FROM tab0 AS cor0
----
-1
-50
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3881
SELECT + CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3881
SELECT + CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3882
SELECT + 46 DIV col0 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3882
SELECT + 46 / col0 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT + - col0 + col2 AS col1 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + col1 * + col0 * col1 + + col1 * - cor0.col1 FROM tab0 AS cor0
----
170108
319906
728728

query I rowsort
SELECT ALL - ( 62 ) FROM tab1, tab0 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query IIIIIIIII rowsort
SELECT * FROM tab2, tab1, tab1 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL 40 + + tab2.col1 + + cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to f106d104c1fe31243b4922bc40335062

query I rowsort
SELECT - 19 * - col0 FROM tab2 AS cor0
----
133
1482
1501

query I rowsort
SELECT ALL - ( - col1 ) * col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + 89 * - cor0.col2 + - col1 * + col0 AS col0 FROM tab2 AS cor0
----
-2620
-4725
-6916

query I rowsort
SELECT 55 * + col2 + + col2 FROM tab0 AS cor0
----
1848
4592
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col0 * col0 col1 FROM tab2 cor0
----
343
474552
493039

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - ( col1 ) AS REAL ) AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - 9 + - 30 AS col2 FROM tab0 AS cor0
----
-39
-39
-39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 7 col0 FROM tab1 cor0
----
7

query I rowsort
SELECT - col0 * col2 * col1 + - 69 AS col1 FROM tab0 cor0
----
-3464
-664187
-68181

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT ALL - - 53 DIV - ( - col0 ) AS col2 FROM tab2 AS cor0
----
0
0
7

skipif mysql # not compatible
query I rowsort label-3897
SELECT ALL - - 53 / - ( - col0 ) AS col2 FROM tab2 AS cor0
----
0
0
7

query I rowsort
SELECT ALL - col2 * ( col0 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col0 * ( + 10 ) AS col2 FROM tab2 cor0
----
70
780
790

query I rowsort
SELECT + cor0.col2 + col1 + col0 AS col2 FROM tab2 cor0
----
134
163
65

query I rowsort
SELECT + col0 + - 5 * + ( cor0.col2 ) * ( col1 ) FROM tab1 AS cor0
----
-2786
-6160
-7017

query I rowsort
SELECT + col1 * ( col1 + col1 ) AS col1 FROM tab1 AS cor0
----
1352
200
338

query I rowsort
SELECT - col2 + col0 * - 16 - - tab2.col1 AS col1 FROM tab2
----
-108
-1215
-1285

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3904
SELECT ALL - CAST( NULL AS DECIMAL ) + 87 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3904
SELECT ALL - CAST ( NULL AS REAL ) + 87 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 4 + col2 - col1 AS col0 FROM tab1 AS cor0
----
24
43
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3906
SELECT DISTINCT + col1 + - CAST( col2 AS SIGNED ) - col1 AS col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3906
SELECT DISTINCT + col1 + - CAST ( col2 AS INTEGER ) - col1 AS col2 FROM tab1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3907
SELECT + col1 DIV + ( ( + col1 ) ) col1 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3907
SELECT + col1 / + ( ( + col1 ) ) col1 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT tab0.col0 * + 19 - col1 FROM tab0
----
1600
370
568

query I rowsort
SELECT + tab2.col0 AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT - col1 - - ( col0 + + col1 ) FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT tab0.col1 - + 7 AS col0 FROM tab0
----
79
84
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3912
SELECT + col0 / + CAST( NULL AS SIGNED ) + col2 - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3912
SELECT + col0 / + CAST ( NULL AS INTEGER ) + col2 - col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + tab2.col2 + - 90 * + col1 * col2 FROM tab2
----
-138034
-58102
-75303

query I rowsort
SELECT + 17 * - col1 FROM tab1 AS cor0
----
-170
-221
-442

query I rowsort
SELECT - 4 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT - 31 AS col0 FROM tab1
----
-31
-31
-31

query I rowsort
SELECT DISTINCT + cor0.col0 + - col0 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL cor0.col2 + col0 AS col0 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 6 col2 FROM tab2 AS cor0
----
6

query I rowsort
SELECT - - cor0.col0 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - ( 91 ) FROM tab2
----
-91
-91
-91

query I rowsort
SELECT - 95 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT DISTINCT 81 AS col2 FROM tab2, tab0 AS cor0
----
81

query I rowsort
SELECT ALL + tab1.col0 * 8 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 573bc067461be7628fb0d33837b2d5e7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3925
SELECT + col2 * col2 DIV CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3925
SELECT + col2 * col2 / CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - - 30 * col0 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT - 60 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-5160
-5460
-5820

skipif mysql # not compatible
query I rowsort
SELECT + - 2 + col1 * + CAST ( col1 AS REAL ) AS col2 FROM tab0 AS cor0
----
7394
8279
9407

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 74 * + col2 + + col2 * col2 col0 FROM tab2 AS cor0
----
2600
2727
4256

query I rowsort
SELECT ALL 42 + - col1 * + 18 AS col2 FROM tab0 AS cor0
----
-1506
-1596
-1704

query I rowsort
SELECT DISTINCT 35 * - col0 - - 37 AS col2 FROM tab0 AS cor0
----
-1188
-3078
-803

query I rowsort
SELECT ( - col1 ) * tab0.col2 + - 69 * col0 AS col0 FROM tab0
----
-13603
-2512
-4494

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3933
SELECT DISTINCT CAST( NULL AS DECIMAL ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-3933
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
NULL

query I rowsort
SELECT - - col1 * + ( 98 ) * col0 FROM tab2 AS cor0
----
131614
21266
450996

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col0 col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL - col2 * + col0 * 55 FROM tab2 AS cor0
----
-10395
-111540
-165110

query I rowsort
SELECT DISTINCT - + cor0.col2 * 50 + col0 AS col0 FROM tab0 AS cor0
----
-15
-1626
-4011

query I rowsort
SELECT ALL col1 + 93 FROM tab0 AS cor0
----
179
184
190

query I rowsort
SELECT ALL + col1 + + 87 AS col2 FROM tab1 AS cor0
----
100
113
97

query I rowsort
SELECT ALL - col1 + - col1 + + cor0.col0 * col0 FROM tab0 AS cor0
----
1031
404
7739

query I rowsort
SELECT DISTINCT + col2 + 50 AS col0 FROM tab1 AS cor0
----
104
107
146

query I rowsort
SELECT - - col0 * ( 76 ) FROM tab1 AS cor0
----
228
4864
6080

query I rowsort
SELECT ALL + col2 + 53 FROM tab1 cor0
----
107
110
149

query I rowsort
SELECT DISTINCT + cor0.col1 + + col0 * 81 + col0 FROM tab1 AS cor0
----
272
5258
6573

query I rowsort
SELECT ALL + 85 + 50 * - tab1.col0 AS col0 FROM tab1
----
-3115
-3915
-65

query I rowsort
SELECT col1 + + 66 * - col2 * col1 FROM tab0
----
-187222
-492401
-6305

onlyif mysql # use DIV operator for integer division
query I rowsort label-3947
SELECT DISTINCT + col2 + + col0 DIV + col0 AS col1 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-3947
SELECT DISTINCT + col2 + + col0 / + col0 AS col1 FROM tab0
----
2
34
83

query I rowsort
SELECT DISTINCT + + cor0.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3949
SELECT DISTINCT + 23 DIV - 91 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3949
SELECT DISTINCT + 23 / - 91 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - 21 * + col0 AS col0 FROM tab2 AS cor0
----
-147
-1638
-1659

query I rowsort
SELECT - - ( col0 ) + + col2 + + col2 FROM tab2 cor0
----
130
155
61

query I rowsort
SELECT ALL + 27 + 20 FROM tab2 AS cor0
----
47
47
47

query I rowsort
SELECT DISTINCT 43 AS col1 FROM tab2 AS cor0
----
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + col1 * col1 col0 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3955
SELECT CAST( 58 AS SIGNED ) * col0 + 28 * + 11 FROM tab0 AS cor0
----
1700
2338
5470

skipif mysql # not compatible
query I rowsort label-3955
SELECT CAST ( 58 AS INTEGER ) * col0 + 28 * + 11 FROM tab0 AS cor0
----
1700
2338
5470

query I rowsort
SELECT DISTINCT ( ( + col0 ) ) AS col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - - ( + 1 ) + + col0 + col0 FROM tab2 AS cor0
----
15
157
159

query I rowsort
SELECT DISTINCT + col2 * col0 * + 44 FROM tab1 cor0
----
160512
337920
7128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 + col1 * 5 col2 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT DISTINCT - cor0.col0 * + col0 + + 13 AS col2 FROM tab2 cor0
----
-36
-6071
-6228

onlyif mysql # use DIV operator for integer division
query I rowsort label-3961
SELECT ALL col0 DIV + col2 AS col0 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-3961
SELECT ALL col0 / + col2 AS col0 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT DISTINCT - 23 + col1 FROM tab1 cor0
----
-10
-13
3

query I rowsort
SELECT DISTINCT + col1 * + col0 * - 41 - 32 FROM tab1 AS cor0
----
-26272
-3230
-42672

query I rowsort
SELECT DISTINCT - col0 - + col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + + col0 * - cor0.col2 + col0 * + col0 AS col2 FROM tab2 AS cor0
----
-140
3239
4056

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 68 * + cor0.col1 + - 30 col1 FROM tab2 AS cor0
----
-1186
-2138
-4042

query I rowsort
SELECT ALL + col0 + cor0.col1 * + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - tab2.col1 + - 4 * col2 AS col2 FROM tab2
----
-139
-163
-169

query I rowsort
SELECT DISTINCT ( col1 + + col1 ) FROM tab1
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( - col2 ) * cor0.col1 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT cor0.col1 * + col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT 8 + + col2 AS col0 FROM tab2 AS cor0
----
34
35
46

query I rowsort
SELECT - 93 * - cor0.col0 FROM tab2 cor0
----
651
7254
7347

query I rowsort
SELECT col0 * + col0 + + 2 AS col2 FROM tab1
----
11
4098
6402

query I rowsort
SELECT ALL cor1.col2 * 77 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 84c67bfcf6ffc1aa6329b92a89560023

query I rowsort
SELECT ALL - tab1.col1 * 68 FROM tab1
----
-1768
-680
-884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3977
SELECT DISTINCT + CAST( - col0 AS SIGNED ) * col0 * + ( + col1 * + col2 + col2 ) FROM tab1
----
-13122
-2568192
-8601600

skipif mysql # not compatible
query I rowsort label-3977
SELECT DISTINCT + CAST ( - col0 AS INTEGER ) * col0 * + ( + col1 * + col2 + col2 ) FROM tab1
----
-13122
-2568192
-8601600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 46 * - 52 col0 FROM tab0 AS cor0
----
-2392
-2392
-2392

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3979
SELECT ALL - CAST( ( col0 ) AS SIGNED ) FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3979
SELECT ALL - CAST ( ( col0 ) AS INTEGER ) FROM tab2 AS cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 12 * col1 col0 FROM tab1 AS cor0
----
120
156
312

query I rowsort
SELECT - 34 * + 39 * cor0.col2 FROM tab2 AS cor0
----
-34476
-35802
-50388

query I rowsort
SELECT DISTINCT - 0 * 48 AS col0 FROM tab1 cor0
----
0

query I rowsort
SELECT ALL 97 + 20 AS col2 FROM tab0 cor0
----
117
117
117

query I rowsort
SELECT DISTINCT 9 * - 11 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 83 + - 69 col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
-152

onlyif mysql # use DIV operator for integer division
query I rowsort label-3986
SELECT ALL + + col0 DIV + 48 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3986
SELECT ALL + + col0 / + 48 AS col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + tab0.col2 * - 88 FROM tab0
----
-2904
-7216
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + 90 col2 FROM tab1
----
100
103
116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - 85 col0 FROM tab1 AS cor0
----
-111
-95
-98

query I rowsort
SELECT ALL col0 + + cor0.col1 * col0 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3992
SELECT DISTINCT - col0 * col2 + col2 DIV cor0.col0 col2 FROM tab0 AS cor0
----
-35
-7298
-791

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3992
SELECT DISTINCT - col0 * col2 + col2 / cor0.col0 col2 FROM tab0 AS cor0
----
-35
-7298
-791

onlyif mysql # use DIV operator for integer division
query I rowsort label-3993
SELECT DISTINCT - - cor0.col2 DIV col2 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-3993
SELECT DISTINCT - - cor0.col2 / col2 FROM tab1 cor0
----
1

query I rowsort
SELECT - ( - 93 ) FROM tab1, tab2 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3995
SELECT - col0 - CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3995
SELECT - col0 - CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * + col1 + + col2 * + col2 FROM tab0 AS cor0
----
14823
3153
3396

query I rowsort
SELECT - cor0.col2 + + 56 * cor0.col0 FROM tab2 AS cor0
----
365
4342
4386

query I rowsort
SELECT col0 * + col0 + col2 AS col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT + col1 + + col1 + + col2 FROM tab2 AS cor0
----
144
72
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4000
SELECT 87 DIV 42 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
19
33
61

skipif mysql # not compatible
query I rowsort label-4000
SELECT 87 / 42 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
19
33
61

query I rowsort
SELECT ALL col0 * - 45 * + tab2.col0 + 21 * + 24 FROM tab2
----
-1701
-273276
-280341

query I rowsort
SELECT + 70 FROM tab2, tab0 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT - col1 * cor0.col0 + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT + 77 AS col2 FROM tab0 cor0
----
77

query I rowsort
SELECT - col1 + 30 * - col1 AS col2 FROM tab2 cor0
----
-1829
-527
-961

query I rowsort
SELECT + col0 + - ( cor0.col2 ) FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + col0 * 75 * + col2 - col1 AS col1 FROM tab1 AS cor0
----
12124
273590
575987

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
54
57
96

query I rowsort
SELECT ( col0 ) * - 66 AS col1 FROM tab1
----
-198
-4224
-5280

query I rowsort
SELECT - col0 + - cor0.col0 * col1 * col1 FROM tab2 AS cor0
----
-22910
-271596
-6734

query I rowsort
SELECT 59 * + col1 FROM tab1 AS cor0
----
1534
590
767

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * 65 * 35 + col0 col2 FROM tab0 AS cor0
----
202564
54624
79660

query I rowsort
SELECT + col2 * ( col1 ) - cor0.col2 AS col2 FROM tab0 AS cor0
----
2805
7380
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4014
SELECT - col2 + + CAST( 38 + - col2 AS SIGNED ) * + ( - col2 ) * col1 FROM tab2 AS cor0
----
-18434
-38
-9234

skipif mysql # not compatible
query I rowsort label-4014
SELECT - col2 + + CAST ( 38 + - col2 AS INTEGER ) * + ( - col2 ) * col1 FROM tab2 AS cor0
----
-18434
-38
-9234

onlyif mysql # use DIV operator for integer division
query I rowsort label-4015
SELECT + col2 + - cor0.col1 DIV col0 FROM tab0 AS cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-4015
SELECT + col2 + - cor0.col1 / col0 FROM tab0 AS cor0
----
-1
30
81

query I rowsort
SELECT col1 * + 81 + + col2 AS col1 FROM tab2 AS cor0
----
1415
2538
4805

query I rowsort
SELECT cor0.col2 * ( - 12 + + col1 ) FROM tab2 cor0
----
1222
190
513

query I rowsort
SELECT - - cor0.col2 * col0 + + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL - 41 * + tab2.col0 + - 8 * + col0 AS col1 FROM tab2
----
-343
-3822
-3871

query I rowsort
SELECT + col0 * col2 + col0 * - col0 AS col2 FROM tab0
----
-1190
-623
216

query I rowsort
SELECT DISTINCT 67 FROM tab2, tab1, tab1 AS cor0
----
67

query I rowsort
SELECT + 31 * + col1 FROM tab0 AS cor0
----
2666
2821
3007

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * + col1 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL - - col0 + col0 * - ( col0 ) FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT cor0.col1 * col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL + + col1 * col2 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - col2 + - 37 FROM tab0 AS cor0
----
-119
-38
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4028
SELECT ALL col0 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4028
SELECT ALL col0 + + 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-4029
SELECT ALL col1 / CAST( NULL AS SIGNED ) + - col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4029
SELECT ALL col1 / CAST ( NULL AS INTEGER ) + - col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * ( col0 ) AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col1 * - col0 - col2 AS col2 FROM tab2 cor0
----
1305
190
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-4032
SELECT ALL - cor0.col0 DIV + col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4032
SELECT ALL - cor0.col0 / + col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col0 + 13 AS col2 FROM tab2 AS cor0
----
20
91
92

query I rowsort
SELECT DISTINCT + col1 * 45 AS col0 FROM tab0 AS cor0
----
3870
4095
4365

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4035
SELECT ALL - - col1 / CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4035
SELECT ALL - - col1 / CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * ( + col2 ) + col0 * col0 AS col2 FROM tab0 AS cor0
----
-513
1197
1224

query I rowsort
SELECT ALL col2 * - col1 * col2 AS col2 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT ALL + col0 * tab2.col1 AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL col2 FROM tab1 WHERE NULL > ( NULL )
----

query I rowsort
SELECT ALL + col0 + col0 * col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT col2 * - col2 + - col2 AS col2 FROM tab1
----
-2970
-3306
-9312

query I rowsort
SELECT - col2 * col2 + col2 * col0 * col2 FROM tab1
----
204687
5832
728064

query I rowsort
SELECT ALL col0 AS col0 FROM tab1 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT col0 + - tab2.col2 * + col0 AS col1 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT col0 * + col0 * col2 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT + col0 * + col0 - + col2 FROM tab0
----
1224
543
7839

query I rowsort
SELECT DISTINCT - col1 * col2 + col0 * - col2 FROM tab2
----
-1026
-3562
-3648

query I rowsort
SELECT DISTINCT col2 * - col0 AS col2 FROM tab1 WHERE NOT ( NULL ) > + col0 + - col0 + col2 / + col2
----

query I rowsort
SELECT tab1.col0 + col0 FROM tab1 WHERE NOT col0 * col0 < NULL
----

query I rowsort
SELECT col1 * + col2 + - tab0.col2 FROM tab0
----
2805
7380
96

query III rowsort
SELECT * FROM tab2 WHERE NOT ( - col2 * - col0 ) NOT IN ( - col0 )
----

query I rowsort
SELECT tab0.col1 + col2 AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT - 50 * col1 * + col1 FROM tab2 AS cor0
----
-14450
-174050
-48050

query I rowsort
SELECT DISTINCT - - cor0.col1 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4055
SELECT ALL col1 - + col2 DIV col1 FROM tab2
----
15
31
59

skipif mysql # not compatible
query I rowsort label-4055
SELECT ALL col1 - + col2 / col1 FROM tab2
----
15
31
59

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE - col0 * - col2 NOT IN ( + col2 / tab0.col1 )
----
24
35
89

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT + col0 + col0 < NULL
----

query I rowsort
SELECT ALL - tab2.col0 * - col2 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - tab1.col1 + col0 + + col0 FROM tab1
----
-20
118
147

query I rowsort
SELECT - col1 FROM tab2 WHERE ( NULL ) > ( col2 + + col2 )
----

query I rowsort
SELECT col0 + col0 - col0 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT + col2 * col1 + + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT 94 * col2 AS col1 FROM tab0 AS cor0
----
3102
7708
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-4064
SELECT DISTINCT - + col2 DIV - col1 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4064
SELECT DISTINCT - + col2 / - col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL 39 + col2 * + 94 FROM tab0 AS cor0
----
133
3141
7747

onlyif mysql # use DIV operator for integer division
query I rowsort label-4066
SELECT - 47 DIV tab1.col0 col2 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to ce8118829944cc748e070b882ac5d7f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4066
SELECT - 47 / tab1.col0 col2 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to ce8118829944cc748e070b882ac5d7f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col2 + col1 col1 FROM tab0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4068
SELECT DISTINCT 25 + - col1 DIV + 19 AS col0 FROM tab2 AS cor0
----
22
24
25

skipif mysql # not compatible
query I rowsort label-4068
SELECT DISTINCT 25 + - col1 / + 19 AS col0 FROM tab2 AS cor0
----
22
24
25

query I rowsort
SELECT - + 82 AS col1 FROM tab1 AS cor0
----
-82
-82
-82

query I rowsort
SELECT + 11 * + cor0.col2 FROM tab1 AS cor0
----
1056
594
627

query I rowsort
SELECT DISTINCT 16 * - col0 + tab2.col2 + - col0 * - 37 AS col2 FROM tab2
----
1664
1697
174

query I rowsort
SELECT ALL + col2 + tab2.col2 FROM tab2
----
52
54
76

query I rowsort
SELECT + 30 * col0 FROM tab0 AS cor0
----
1050
2670
720

query I rowsort
SELECT DISTINCT - 75 * - col2 * 11 + + col1 * + col1 AS col0 FROM tab2 AS cor0
----
23236
24931
31639

query I rowsort
SELECT ALL - + col2 * col1 + col2 * - cor0.col0 + - col1 FROM tab1 AS cor0
----
-1592
-4228
-8941

query I rowsort
SELECT ALL - + ( - col2 ) AS col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL - cor0.col1 * cor0.col1 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-4078
SELECT col1 + col0 + + col1 DIV + col1 FROM tab1 AS cor0
----
30
75
94

skipif mysql # not compatible
query I rowsort label-4078
SELECT col1 + col0 + + col1 / + col1 FROM tab1 AS cor0
----
30
75
94

query I rowsort
SELECT ALL - + 14 AS col2 FROM tab0 AS cor0
----
-14
-14
-14

query I rowsort
SELECT DISTINCT + col1 + + col1 * 61 + - col1 AS col2 FROM tab2 AS cor0
----
1037
1891
3599

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2, tab1 cor3
----
3645 values hashing to a8d2ba8b8eb568b0a9a1771ccb0a8f23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 - col1 col1 FROM tab0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-4083
SELECT + tab1.col1 DIV - ( 18 ) col0 FROM tab1
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4083
SELECT + tab1.col1 / - ( 18 ) col0 FROM tab1
----
-1
0
0

query I rowsort
SELECT cor0.col0 * col1 - col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL col0 * col1 - - col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT - col1 + col1 * col0 AS col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4087
SELECT DISTINCT CAST( - col2 AS SIGNED ) * + col0 col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4087
SELECT DISTINCT CAST ( - col2 AS INTEGER ) * + col0 col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - 73 FROM tab0, tab0 AS cor0, tab2 cor1, tab2 AS cor2
----
81 values hashing to b6d4a8c1826477f660e7b977a0d1fdd7

query I rowsort
SELECT - + ( 62 ) + + col1 FROM tab0 cor0
----
24
29
35

query I rowsort
SELECT ALL ( ( col1 ) ) + 75 * 74 FROM tab0 AS cor0
----
5636
5641
5647

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( cor0.col0 ) col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - tab2.col1 * 11 * col0 AS col0 FROM tab2
----
-14773
-2387
-50622

query I rowsort
SELECT ALL 73 FROM tab0, tab0 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT ( col1 ) + + col2 AS col1 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - - ( col0 ) - - col0 AS col0 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT ( + col2 ) + col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT 25 * - 95 + - col0 AS col2 FROM tab0 AS cor0
----
-2399
-2410
-2464

query I rowsort
SELECT + col2 + - col0 AS col0 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT col1 * + 91 + col0 AS col1 FROM tab2 AS cor0
----
1626
2828
5447

query I rowsort
SELECT ALL + 54 + cor0.col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1390
-622
-675

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1, tab0 cor2
----
3645 values hashing to b803f2d602a28da5cf35ddc7c7fa2eeb

query I rowsort
SELECT DISTINCT - col0 + 29 AS col2 FROM tab0 AS cor0
----
-6
-60
5

query I rowsort
SELECT col2 * - 38 * + cor0.col1 + - col1 * col1 AS col1 FROM tab1 AS cor0
----
-21760
-47593
-54028

query I rowsort
SELECT - col0 - col0 AS col2 FROM tab0 cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 59 + cor0.col1 col1 FROM tab2 AS cor0
----
-28
-42
0

query I rowsort
SELECT 38 * - col1 + + col2 AS col0 FROM tab2 AS cor0
----
-1151
-2216
-608

query I rowsort
SELECT ALL 20 * col0 + col0 FROM tab1 AS cor0
----
1344
1680
63

query I rowsort
SELECT DISTINCT + 89 * - col0 FROM tab1 AS cor0
----
-267
-5696
-7120

query I rowsort
SELECT DISTINCT + - col0 * + cor0.col1 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4110
SELECT DISTINCT - + 47 DIV - col1 AS col0 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4110
SELECT DISTINCT - + 47 / - col1 AS col0 FROM tab2 AS cor0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL + 86 - col1 FROM tab2 AS cor0
----
27
55
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-4113
SELECT - - col1 DIV col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4113
SELECT - - col1 / col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 20 * - cor0.col2 + - col0 FROM tab1 AS cor0
----
-1083
-1204
-2000

query I rowsort
SELECT DISTINCT + col1 + + 42 + col1 * + col2 * col0 AS col0 FROM tab1
----
36532
4280
99895

query I rowsort
SELECT - 2 * + col1 FROM tab2 cor0
----
-118
-34
-62

query I rowsort
SELECT col1 + - col1 * - col0 * col0 FROM tab2 AS cor0
----
106114
1550
359015

onlyif mysql # use DIV operator for integer division
query I rowsort label-4118
SELECT - col2 * + col0 + - col2 DIV - col2 AS col0 FROM tab1
----
-161
-3647
-7679

skipif mysql # not compatible
query I rowsort label-4118
SELECT - col2 * + col0 + - col2 / - col2 AS col0 FROM tab1
----
-161
-3647
-7679

query I rowsort
SELECT + col2 + + col2 * - col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - col1 * - 33 FROM tab1 cor0
----
330
429
858

query I rowsort
SELECT DISTINCT 21 AS col0 FROM tab1, tab2 AS cor0
----
21

query I rowsort
SELECT ALL col1 * 22 * + col0 FROM tab1 AS cor0
----
14080
1716
22880

query I rowsort
SELECT - col1 + col0 + col2 FROM tab2
----
100
3
45

query I rowsort
SELECT col2 * - 38 AS col2 FROM tab1
----
-2052
-2166
-3648

query I rowsort
SELECT DISTINCT - 42 * 22 + - tab1.col1 + - col1 FROM tab1
----
-944
-950
-976

query I rowsort
SELECT ALL col1 * - ( - tab1.col2 ) * col0 + - col0 FROM tab1
----
36416
4209
99760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4127
SELECT DISTINCT + CAST( + cor0.col1 AS SIGNED ) FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4127
SELECT DISTINCT + CAST ( + cor0.col1 AS INTEGER ) FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT + col1 * 62 FROM tab0 AS cor0
----
5332
5642
6014

query I rowsort
SELECT ALL + ( col1 ) + + col0 * col1 AS col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT DISTINCT col2 * 3 FROM tab2
----
114
78
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4131
SELECT + tab0.col1 DIV - col1 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4131
SELECT + tab0.col1 / - col1 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - col2 * col1 * - col1 + col0 + + col0 FROM tab2
----
11140
25961
90662

onlyif mysql # use DIV operator for integer division
query I rowsort label-4133
SELECT - tab0.col1 * col0 DIV col1 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-4133
SELECT - tab0.col1 * col0 / col1 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT col2 + - cor0.col2 * - col0 FROM tab0 AS cor0
----
36
7380
825

query III rowsort
SELECT * FROM tab0 WHERE NOT col2 / col2 - - col2 IN ( - tab0.col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT + tab2.col2 AS col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4137
SELECT col2 DIV - col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-4137
SELECT col2 / - col0 FROM tab1
----
-1
-18
0

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( col0 / col0 ) IN ( tab1.col0 + col2 / - col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

onlyif mysql # use DIV operator for integer division
query I rowsort label-4139
SELECT col1 DIV + col1 + col2 * + col0 FROM tab2
----
190
2029
3003

skipif mysql # not compatible
query I rowsort label-4139
SELECT col1 / + col1 + col2 * + col0 FROM tab2
----
190
2029
3003

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL IN ( + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4141
SELECT DISTINCT - tab2.col2 DIV - col0 FROM tab2
----
0
3

skipif mysql # not compatible
query I rowsort label-4141
SELECT DISTINCT - tab2.col2 / - col0 FROM tab2
----
0
3

query I rowsort
SELECT + col0 * + col1 + col1 AS col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL + col1 * tab2.col0 + col1 * - col0 AS col1 FROM tab2
----
0
0
0

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL BETWEEN col2 + + col1 * col1 AND col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4145
SELECT DISTINCT - col0 + - col0 DIV - col0 AS col2 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-4145
SELECT DISTINCT - col0 + - col0 / - col0 AS col2 FROM tab1
----
-2
-63
-79

query III rowsort
SELECT * FROM tab2 WHERE NOT ( col1 * - col2 ) = NULL
----

query I rowsort
SELECT cor0.col0 FROM tab0, tab2 AS cor0 WHERE ( cor0.col2 ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT col1 AS col0 FROM tab0 AS cor0 WHERE NOT ( NULL ) <> col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 * col0 col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT col2 * col2 - + col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT - tab2.col0 * col1 + col2 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT + cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL - cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab2 cor1, tab0 cor2
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

query I rowsort
SELECT ALL ( col0 ) + - col2 * + col2 + 14 AS col2 FROM tab1 AS cor0
----
-2899
-3171
-9122

query I rowsort
SELECT + col0 * col0 + col2 AS col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT - - col0 + ( + col1 ) * col0 FROM tab0 AS cor0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 95 col2 FROM tab2
----
95

query I rowsort
SELECT 64 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

onlyif mysql # use DIV operator for integer division
query I rowsort label-4160
SELECT ALL + 84 * 68 DIV + cor0.col0 AS col1 FROM tab1 cor0
----
1904
71
89

skipif mysql # not compatible
query I rowsort label-4160
SELECT ALL + 84 * 68 / + cor0.col0 AS col1 FROM tab1 cor0
----
1904
71
89

query I rowsort
SELECT DISTINCT + 54 * col1 FROM tab2
----
1674
3186
918

query I rowsort
SELECT + ( + col1 * - col2 ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT 5 + col2 AS col1 FROM tab0
----
38
6
87

query I rowsort
SELECT DISTINCT + ( - col2 ) + + col0 * 41 * col0 + + col1 FROM tab2 AS cor0
----
2013
249477
255860

query I rowsort
SELECT - 76 AS col0 FROM tab2, tab1 cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 30b3ee36c95bb84d1f6a640c4d41cf15

query I rowsort
SELECT 2 * - cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 27b4e0878ffa5c5df119ac6cfa79ea07

query I rowsort
SELECT ALL - - ( + col0 ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4168
SELECT - ( cor0.col2 ) DIV + cor0.col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-4168
SELECT - ( cor0.col2 ) / + cor0.col0 FROM tab2 AS cor0
----
-3
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4169
SELECT ( - col1 ) DIV CAST( + col1 AS SIGNED ) FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4169
SELECT ( - col1 ) / CAST ( + col1 AS INTEGER ) FROM tab1
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - 86 * col0 - + ( + ( col1 ) + - ( col0 ) ) * col0 FROM tab2
----
-1896
-5226
-770

query I rowsort
SELECT - 66 * + col2 FROM tab0
----
-2178
-5412
-66

query I rowsort
SELECT DISTINCT - 25 - col1 * ( col2 ) * tab2.col0 FROM tab2
----
-119677
-51059
-5884

query I rowsort
SELECT DISTINCT tab0.col1 - + col0 AS col1 FROM tab0
----
2
62

query I rowsort
SELECT DISTINCT col1 * col2 - + col0 AS col0 FROM tab1
----
1168
1401
506

query I rowsort
SELECT + - 23 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT + + col2 * col0 * - ( col2 ) + - cor0.col0 FROM tab0 AS cor0
----
-26160
-598525
-70

query I rowsort
SELECT - - ( col0 ) + ( - 28 + - col1 ) FROM tab1 cor0
----
-51
26
39

query I rowsort
SELECT - - 55 * col1 FROM tab2 cor0
----
1705
3245
935

query I rowsort
SELECT ALL + - col2 - col2 * 59 FROM tab0 AS cor0
----
-1980
-4920
-60

query I rowsort
SELECT DISTINCT - - col0 * 40 FROM tab0 AS cor0
----
1400
3560
960

query I rowsort
SELECT + - col0 * - col1 + col0 * - col0 + + col0 AS col2 FROM tab1 AS cor0
----
-3392
-5280
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * col1 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4183
SELECT ALL - + col2 + CAST( NULL AS SIGNED ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4183
SELECT ALL - + col2 + CAST ( NULL AS INTEGER ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4184
SELECT ALL - col0 * CAST( NULL AS SIGNED ) + ( col1 ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4184
SELECT ALL - col0 * CAST ( NULL AS INTEGER ) + ( col1 ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col2 * + 13 + - 30 FROM tab0 AS cor0
----
-17
1036
399

query I rowsort
SELECT ALL + col2 * 20 + + col0 * col0 + 58 FROM tab2 AS cor0
----
647
6662
7059

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + tab0.col2 ) * + col2 col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT + col2 + 59 * - ( + col1 ) * - ( + col2 ) AS col2 FROM tab1 AS cor0
----
33687
73728
82890

query I rowsort
SELECT ALL - - col2 * + ( - 97 ) + - col0 + - 4 AS col1 FROM tab2 AS cor0
----
-2604
-2630
-3769

query I rowsort
SELECT DISTINCT col0 + 51 * - 59 AS col0 FROM tab1 AS cor0
----
-2929
-2945
-3006

onlyif mysql # use DIV operator for integer division
query I rowsort label-4191
SELECT DISTINCT cor0.col0 + - col0 DIV col1 FROM tab2 AS cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-4191
SELECT DISTINCT cor0.col0 + - col0 / col1 FROM tab2 AS cor0
----
7
75
77

query I rowsort
SELECT DISTINCT - cor0.col1 + 5 FROM tab0 AS cor0
----
-81
-86
-92

query I rowsort
SELECT - cor0.col2 * 79 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 781a47a666b0e97655a5b19d853bc693

query I rowsort
SELECT DISTINCT + cor0.col0 * cor0.col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
4096
6400
9

query I rowsort
SELECT ALL + col1 * + 31 FROM tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT col0 + col2 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT col2 * + col2 + - 43 AS col0 FROM tab0 AS cor0
----
-42
1046
6681

query I rowsort
SELECT DISTINCT cor0.col2 + + 80 FROM tab2 AS cor0
----
106
107
118

query I rowsort
SELECT ALL - cor0.col2 * col2 + + col2 + - cor0.col2 AS col0 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT - col1 + - 45 * 94 AS col0 FROM tab2 cor0
----
-4247
-4261
-4289

query I rowsort
SELECT 69 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4202
SELECT - col2 * cor0.col1 + + col2 DIV + col2 AS col1 FROM tab0 AS cor0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-4202
SELECT - col2 * cor0.col1 + + col2 / + col2 AS col1 FROM tab0 AS cor0
----
-2837
-7461
-96

query I rowsort
SELECT + - cor0.col1 * + col1 + - col0 AS col2 FROM tab1 AS cor0
----
-164
-249
-679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + cor0.col1 col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + ( 64 ) * cor0.col2 + ( + cor0.col0 ) FROM tab0 cor0
----
2136
5337
99

query I rowsort
SELECT DISTINCT tab1.col1 + col2 AS col2 FROM tab1
----
109
67
80

query I rowsort
SELECT + cor0.col0 + cor0.col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL + - 6 + + col1 FROM tab0 cor0
----
80
85
91

query I rowsort
SELECT + ( col1 ) * + col1 + col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT + 52 FROM tab2 AS cor0
----
52

query I rowsort
SELECT + 98 * + ( col2 ) AS col1 FROM tab1 cor0
----
5292
5586
9408

query I rowsort
SELECT DISTINCT - col2 * - col0 + 94 FROM tab1
----
256
3742
7774

query I rowsort
SELECT ALL col0 + - 56 FROM tab2
----
-49
22
23

query I rowsort
SELECT ALL tab0.col2 + - 30 FROM tab0
----
-29
3
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - ( col2 ) + + ( - 15 ) * col1 AS col0 FROM tab2 AS cor0
----
-293
-492
-911

query I rowsort
SELECT + ( + col2 ) * ( col1 ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT col0 * + col2 * 41 FROM tab0 AS cor0
----
1435
299218
32472

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 8 + col2 * - 92 col1 FROM tab2 AS cor0
----
-2384
-2476
-3488

query I rowsort
SELECT ALL col0 * col1 * - col0 AS col2 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT ALL cor0.col2 * + col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL cor0.col1 + col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT 48 * 22 + col0 * - col1 FROM tab1
----
16
416
978

query I rowsort
SELECT ALL + 57 * col0 FROM tab0 AS cor0
----
1368
1995
5073

query I rowsort
SELECT ALL - 21 * col0 FROM tab0
----
-1869
-504
-735

onlyif mysql # use DIV operator for integer division
query I rowsort label-4226
SELECT ALL 76 DIV - col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4226
SELECT ALL 76 / - col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - 51 + 9 AS col0 FROM tab0
----
-42

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col0 AS REAL ) + col2 FROM tab1
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4229
SELECT DISTINCT + CAST( col0 AS SIGNED ) AS col0 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4229
SELECT DISTINCT + CAST ( col0 AS INTEGER ) AS col0 FROM tab0 cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4230
SELECT + CAST( NULL AS SIGNED ) + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4230
SELECT + CAST ( NULL AS INTEGER ) + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + col2 * 81 FROM tab1 cor0
----
4377
4681
7856

query I rowsort
SELECT - + ( col2 ) * - ( - cor0.col2 ) AS col2 FROM tab2 cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-4233
SELECT - col1 DIV + col0 AS col2 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4233
SELECT - col1 / + col0 AS col2 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT ALL 73 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT ALL 51 AS col2 FROM tab1 AS cor0
----
51
51
51

query I rowsort
SELECT + - col1 + - col1 * cor0.col1 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT - 99 + + col2 FROM tab1 cor0
----
-3
-42
-45

query I rowsort
SELECT - col1 + col0 * - 40 FROM tab1 AS cor0
----
-146
-2570
-3213

query I rowsort
SELECT - + 87 + - col2 AS col2 FROM tab1 cor0
----
-141
-144
-183

query I rowsort
SELECT - col1 + - col1 * - col0 AS col0 FROM tab1 AS cor0
----
1027
52
630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + 86 + col1 col2 FROM tab2 AS cor0
----
110
24
67

query I rowsort
SELECT ALL - - col1 + ( cor0.col2 ) FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL + - col2 + + ( col0 ) AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT col1 + - 4 * col1 FROM tab0 AS cor0
----
-258
-273
-291

query I rowsort
SELECT - + col2 * - 80 FROM tab1 AS cor0
----
4320
4560
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4246
SELECT ALL col1 + - col0 DIV - cor0.col0 AS col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-4246
SELECT ALL col1 + - col0 / - cor0.col0 AS col1 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT DISTINCT - col1 - + ( col0 ) AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 - col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL - + col2 * + 99 AS col2 FROM tab0 cor0
----
-3267
-8118
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4250
SELECT DISTINCT - + cor0.col0 * + 40 * col1 + col2 * - CAST( + col2 AS SIGNED ) + col1 col1 FROM tab0 AS cor0
----
-135704
-330593
-83563

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4250
SELECT DISTINCT - + cor0.col0 * + 40 * col1 + col2 * - CAST ( + col2 AS INTEGER ) + col1 col1 FROM tab0 AS cor0
----
-135704
-330593
-83563

query I rowsort
SELECT col1 * + ( - col2 ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4252
SELECT - + CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4252
SELECT - + CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 87 * col1 FROM tab0 AS cor0
----
-7482
-7917
-8439

query I rowsort
SELECT col2 * - col1 + + col2 * + col2 AS col2 FROM tab0
----
-1749
-738
-96

query I rowsort
SELECT 19 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT - 5 * + ( col1 ) AS col0 FROM tab0 AS cor0
----
-430
-455
-485

onlyif mysql # use DIV operator for integer division
query I rowsort label-4257
SELECT - - col1 DIV - col2 AS col0 FROM tab0 cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-4257
SELECT - - col1 / - col2 AS col0 FROM tab0 cor0
----
-1
-2
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4258
SELECT DISTINCT - CAST( col1 AS SIGNED ) * - cor0.col1 + - 44 FROM tab0 AS cor0
----
7352
8237
9365

skipif mysql # not compatible
query I rowsort label-4258
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * - cor0.col1 + - 44 FROM tab0 AS cor0
----
7352
8237
9365

query I rowsort
SELECT + 13 * cor0.col2 AS col2 FROM tab0 AS cor0
----
1066
13
429

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col1 col1 FROM tab0
----
119
173
98

query I rowsort
SELECT col0 + col0 * col1 * col1 FROM tab2 AS cor0
----
22910
271596
6734

query I rowsort
SELECT 92 + ( col0 ) FROM tab0 AS cor0
----
116
127
181

query I rowsort
SELECT DISTINCT - 77 * - col0 AS col0 FROM tab2 AS cor0
----
539
6006
6083

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 32 col0 FROM tab0 AS cor0
----
-1056
-2624
-32

query I rowsort
SELECT + col2 + cor0.col0 * - cor0.col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT 58 * + 10 AS col2 FROM tab0, tab0 cor0 CROSS JOIN tab1
----
27 values hashing to 7df5ba3e478a5836b729aba9629af1b1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4267
SELECT DISTINCT + col1 DIV - col1 AS col2 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4267
SELECT DISTINCT + col1 / - col1 AS col2 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT - col0 + col2 + + ( col0 ) AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT 87 FROM tab0, tab1 AS cor0
----
87

query I rowsort
SELECT tab0.col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL - 74 FROM tab1, tab2 AS cor0
----
9 values hashing to 5a567947d14593676e3825756f8e6130

query I rowsort
SELECT - col0 + + ( col2 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + - col2 + - 84 FROM tab2 AS cor0
----
-110
-111
-122

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col0 + 31 ) * 71 col1 FROM tab2
----
-2698
-7739
-7810

onlyif mysql # use DIV operator for integer division
query I rowsort label-4275
SELECT ALL - 35 DIV - cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-4275
SELECT ALL - 35 / - cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ( cor0.col1 ) FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # use DIV operator for integer division
query I rowsort label-4277
SELECT ALL + col0 DIV col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4277
SELECT ALL + col0 / col0 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4278
SELECT + - col0 DIV col0 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4278
SELECT + - col0 / col0 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - - 23 + col2 * col1 FROM tab0 AS cor0
----
120
2861
7485

query I rowsort
SELECT 13 - cor0.col0 AS col0 FROM tab2 AS cor0
----
-65
-66
6

query I rowsort
SELECT DISTINCT + ( cor0.col0 ) * col2 + - col1 * col1 * + col1 AS col0 FROM tab2 AS cor0
----
-1911
-203351
-29602

query I rowsort
SELECT 4 + - col2 AS col0 FROM tab1 cor0
----
-50
-53
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 73 col1 FROM tab0, tab2 cor0 CROSS JOIN tab2
----
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4284
SELECT ALL tab1.col1 DIV + 10 AS col2 FROM tab1
----
1
1
2

skipif mysql # not compatible
query I rowsort label-4284
SELECT ALL tab1.col1 / + 10 AS col2 FROM tab1
----
1
1
2

query I rowsort
SELECT + 43 * + tab2.col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 4df48b292225a1849da2c64bdc5f078e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 2 * + col0 - 40 * + col0 col2 FROM tab2
----
-294
-3276
-3318

query I rowsort
SELECT 76 * - col1 + col1 AS col2 FROM tab0
----
-6450
-6825
-7275

query I rowsort
SELECT DISTINCT 46 + tab0.col2 AS col0 FROM tab0
----
128
47
79

query I rowsort
SELECT col0 + - col0 * col0 * + col1 AS col2 FROM tab1 AS cor0
----
-231
-40896
-83120

onlyif mysql # use DIV operator for integer division
query I rowsort label-4290
SELECT cor0.col0 DIV + cor0.col2 AS col0 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-4290
SELECT cor0.col0 / + cor0.col2 AS col0 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT ALL - + ( + col1 ) + + col0 FROM tab0 AS cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 90 col2 FROM tab1 AS cor0
----
-90

query I rowsort
SELECT ALL col0 * col0 * - col1 + col2 + col1 FROM tab1
----
-154
-40893
-83091

onlyif mysql # use DIV operator for integer division
query I rowsort label-4294
SELECT ALL col0 DIV col1 + col0 AS col1 FROM tab1
----
3
70
86

skipif mysql # not compatible
query I rowsort label-4294
SELECT ALL col0 / col1 + col0 AS col1 FROM tab1
----
3
70
86

query I rowsort
SELECT - ( + cor0.col2 ) AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT ALL 11 * 94 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to d336dd583905a195b7d069e70324a308

query I rowsort
SELECT col2 + + 82 FROM tab0
----
115
164
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 77 col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT 85 * col0 + - col2 * col0 AS col0 FROM tab0 cor0
----
1248
267
2940

onlyif mysql # use DIV operator for integer division
query I rowsort label-4300
SELECT ( col2 ) DIV - col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-4300
SELECT ( col2 ) / - col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT DISTINCT + col1 * col0 - col2 AS col2 FROM tab1
----
24
583
944

query I rowsort
SELECT ALL - 68 + 39 + + col1 * + 62 FROM tab0 cor0
----
5303
5613
5985

query I rowsort
SELECT DISTINCT + col0 + col0 * col1 FROM tab0 AS cor0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col0 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - ( ( + col0 ) ) + + col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + 62 AS col2 FROM tab2 AS cor0
----
62

query I rowsort
SELECT - + col1 + + 35 FROM tab0 AS cor0
----
-51
-56
-62

query I rowsort
SELECT DISTINCT + + 4 AS col1 FROM tab0 AS cor0
----
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 + col2 * + ( - col0 ) - col1 col2 FROM tab1 AS cor0
----
-110
-3018
-6653

query I rowsort
SELECT + - 95 * + 97 + - cor0.col2 * col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
-12799
-16815
-9374

query I rowsort
SELECT + 11 * col1 - - col0 AS col1 FROM tab2 cor0
----
266
348
727

query I rowsort
SELECT DISTINCT - col1 * + cor0.col1 + - col0 AS col1 FROM tab1 cor0
----
-164
-249
-679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 25 col2 FROM tab1
----
-25

query I rowsort
SELECT + ( - col2 ) + - col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - col2 * tab0.col0 * col0 + + col2 AS col2 FROM tab0
----
-1224
-18975
-649440

query I rowsort
SELECT DISTINCT + col2 * 19 - - cor0.col1 FROM tab2 cor0
----
544
553
739

query I rowsort
SELECT + 75 * - ( cor0.col1 + - 75 ) FROM tab1 AS cor0
----
3675
4650
4875

query I rowsort
SELECT + 56 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT ALL + + col0 * col2 AS col1 FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4320
SELECT ALL + col0 + col1 * CAST( 14 + + col2 * + 76 AS SIGNED ) AS col2 FROM tab1 cor0
----
107071
43524
95110

skipif mysql # not compatible
query I rowsort label-4320
SELECT ALL + col0 + col1 * CAST ( 14 + + col2 * + 76 AS INTEGER ) AS col2 FROM tab1 cor0
----
107071
43524
95110

query I rowsort
SELECT + col0 + + col2 * col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - col2 + - col2 * col0 AS col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT ( col2 ) + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT - 53 AS col0 FROM tab2 cor0
----
-53

query I rowsort
SELECT ALL cor0.col2 * - col1 + col2 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT - - cor0.col2 * + col0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4327
SELECT ALL - + col0 DIV col1 - - col1 AS col0 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4327
SELECT ALL - + col0 / col1 - - col1 AS col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT ALL col0 + - col0 * col0 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4329
SELECT DISTINCT CAST( NULL AS SIGNED ) - col2 * col2 AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4329
SELECT DISTINCT CAST ( NULL AS INTEGER ) - col2 * col2 AS col1 FROM tab1
----
NULL

query I rowsort
SELECT cor0.col2 * cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 41d4c126bfd4bfab59ba5e83427c98e0

query I rowsort
SELECT ALL - col0 + + col0 * + col0 * cor0.col0 AS col1 FROM tab0 AS cor0
----
13800
42840
704880

query I rowsort
SELECT DISTINCT 82 + col1 * col2 * col0 FROM tab0 AS cor0
----
3477
664200
68194

onlyif mysql # use DIV operator for integer division
query I rowsort label-4333
SELECT - 73 * col0 - + col0 DIV + col2 FROM tab1 AS cor0
----
-219
-4673
-5840

skipif mysql # not compatible
query I rowsort label-4333
SELECT - 73 * col0 - + col0 / + col2 FROM tab1 AS cor0
----
-219
-4673
-5840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4334
SELECT DISTINCT + col2 DIV 54 + - col0 AS col1 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-4334
SELECT DISTINCT + col2 / 54 + - col0 AS col1 FROM tab1 AS cor0
----
-2
-63
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4335
SELECT - - col1 * CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4335
SELECT - - col1 * CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 - + 99 AS col0 FROM tab2 cor0
----
-40
-68
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4337
SELECT ALL - col2 * col1 + col2 + col0 DIV 87 col1 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4337
SELECT ALL - col2 * col1 + col2 + col0 / 87 col1 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL - col0 - 57 FROM tab1 cor0
----
-121
-137
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4339
SELECT ALL - col2 * ( 97 ) + col2 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4339
SELECT ALL - col2 * ( 97 ) + col2 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * + ( 37 ) + col1 AS col0 FROM tab2 cor0
----
1178
2242
646

query I rowsort
SELECT col2 * - 89 AS col2 FROM tab2 AS cor0
----
-2314
-2403
-3382

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + col0 col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + col1 + + ( 8 ) * col0 FROM tab2 cor0
----
649
683
87

query I rowsort
SELECT + col2 * + cor0.col0 + + col1 * - col1 AS col0 FROM tab2 AS cor0
----
-1453
-772
2713

query I rowsort
SELECT DISTINCT + 89 * col0 FROM tab1
----
267
5696
7120

onlyif mysql # use DIV operator for integer division
query I rowsort label-4346
SELECT - cor0.col0 DIV 21 + col2 FROM tab1 AS cor0
----
54
54
93

skipif mysql # not compatible
query I rowsort label-4346
SELECT - cor0.col0 / 21 + col2 FROM tab1 AS cor0
----
54
54
93

query I rowsort
SELECT ALL - - col2 * + 17 AS col1 FROM tab2 AS cor0
----
442
459
646

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4348
SELECT ALL - col0 + CAST( NULL AS SIGNED ) * 28 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4348
SELECT ALL - col0 + CAST ( NULL AS INTEGER ) * 28 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + 93 AS col0 FROM tab2 AS cor0
----
110
124
152

query I rowsort
SELECT DISTINCT + cor0.col2 * ( - cor0.col1 ) AS col0 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-4351
SELECT ALL col2 DIV CAST( + 49 AS SIGNED ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4351
SELECT ALL col2 / CAST ( + 49 AS INTEGER ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + 34 FROM tab1 AS cor0
----
21
24
8

query IIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab2, tab1 cor1
----
243 values hashing to 4fe4780e49e612b93957f575d9b3e89f

query I rowsort
SELECT ( + col1 ) AS col2 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - 32 * col0 FROM tab0 AS cor0
----
-1120
-2848
-768

query I rowsort
SELECT tab0.col0 + - ( + 82 ) * - col2 AS col2 FROM tab0
----
117
2730
6813

query I rowsort
SELECT cor0.col2 * 62 FROM tab0 AS cor0
----
2046
5084
62

query I rowsort
SELECT DISTINCT + tab1.col0 * tab1.col0 * + col1 FROM tab1
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col1 col2 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4360
SELECT - 65 + tab0.col1 * CAST( col1 + - col2 AS SIGNED ) AS col0 FROM tab0
----
4493
754
9247

skipif mysql # not compatible
query I rowsort label-4360
SELECT - 65 + tab0.col1 * CAST ( col1 + - col2 AS INTEGER ) AS col0 FROM tab0
----
4493
754
9247

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col0 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT ALL + 74 AS col1 FROM tab0
----
74
74
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-4363
SELECT - tab2.col0 DIV - 41 FROM tab2
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4363
SELECT - tab2.col0 / - 41 FROM tab2
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * ( + cor0.col0 ) * + col1 col1 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-4365
SELECT - + col1 DIV + cor0.col0 + col2 FROM tab2 AS cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-4365
SELECT - + col1 / + cor0.col0 + col2 FROM tab2 AS cor0
----
23
26
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4366
SELECT ALL - + col0 * CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-4366
SELECT ALL - + col0 * CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT col0 * 45 - - 31 AS col1 FROM tab2 AS cor0
----
346
3541
3586

query I rowsort
SELECT col0 + ( col1 + + col1 ) AS col2 FROM tab1
----
106
55
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4369
SELECT ALL + - ( + cor0.col1 ) * - cor0.col2 + + CAST( + col0 AS SIGNED ) col1 FROM tab1 AS cor0
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4369
SELECT ALL + - ( + cor0.col1 ) * - cor0.col2 + + CAST ( + col0 AS INTEGER ) col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL + col0 + col1 - cor0.col0 * ( - col2 + col2 ) * ( col2 ) FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - ( + 37 ) - - col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1262
-613
-7958

onlyif mysql # use DIV operator for integer division
query I rowsort label-4372
SELECT - ( - col2 ) + - col2 DIV col1 FROM tab1 AS cor0
----
52
52
89

skipif mysql # not compatible
query I rowsort label-4372
SELECT - ( - col2 ) + - col2 / col1 FROM tab1 AS cor0
----
52
52
89

query I rowsort
SELECT ALL col1 + - 39 AS col0 FROM tab0 cor0
----
47
52
58

query I rowsort
SELECT DISTINCT + 16 * + col0 * - col1 AS col1 FROM tab1 AS cor0
----
-10240
-1248
-16640

query I rowsort
SELECT ALL 40 * col0 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
117
2496
3120

query I rowsort
SELECT + - 80 * - col2 AS col1 FROM tab0 AS cor0
----
2640
6560
80

query I rowsort
SELECT ALL col2 * - col1 * col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col0 * cor0.col1 col0 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4379
SELECT ALL + CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4379
SELECT ALL + CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 + ( - col1 ) FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT DISTINCT + col1 - + col0 * - 28 FROM tab2 cor0
----
2229
2243
227

query I rowsort
SELECT DISTINCT 48 * - col0 + + col0 FROM tab1 AS cor0
----
-141
-3008
-3760

query I rowsort
SELECT + 18 * - col1 FROM tab0 AS cor0
----
-1548
-1638
-1746

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 40 col0 FROM tab0 AS cor0
----
40
40
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4385
SELECT DISTINCT - + CAST( NULL AS SIGNED ) FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-4385
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT cor0.col0 + - col1 * col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - + 59 AS col0 FROM tab0 AS cor0
----
-59
-59
-59

query I rowsort
SELECT + col1 * - col0 + 18 FROM tab2 cor0
----
-1325
-199
-4584

query I rowsort
SELECT - - 47 + col1 * 45 FROM tab1 AS cor0
----
1217
497
632

query I rowsort
SELECT - 96 * - col0 * 90 FROM tab0 AS cor0
----
207360
302400
768960

onlyif mysql # use DIV operator for integer division
query I rowsort label-4391
SELECT ALL + + col2 DIV - cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-4391
SELECT ALL + + col2 / - cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT ( col0 + 58 ) FROM tab0
----
147
82
93

query I rowsort
SELECT DISTINCT - 83 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-83

query I rowsort
SELECT - 0 - + cor0.col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - 15 * ( + col2 * 79 ) + - col2 AS col2 FROM tab2 AS cor0
----
-30836
-32022
-45068

query I rowsort
SELECT DISTINCT 85 AS col2 FROM tab1, tab2 AS cor0
----
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4397
SELECT DISTINCT col0 + 77 DIV - 6 + + tab0.col0 * col0 FROM tab0
----
1248
588
7998

skipif mysql # not compatible
query I rowsort label-4397
SELECT DISTINCT col0 + 77 / - 6 + + tab0.col0 * col0 FROM tab0
----
1248
588
7998

query I rowsort
SELECT DISTINCT tab0.col0 * tab0.col2 + - tab0.col2 * - tab0.col0 + col0 FROM tab0
----
105
14685
1608

onlyif mysql # use DIV operator for integer division
query I rowsort label-4399
SELECT - tab2.col0 * col0 DIV col0 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-4399
SELECT - tab2.col0 * col0 / col0 FROM tab2
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - ( col0 ) * - tab1.col1 AS col2 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col1 * - col1 * + cor0.col0 col1 FROM tab2 AS cor0
----
-22752
-271440
-6720

query I rowsort
SELECT - 74 * col0 FROM tab2
----
-518
-5772
-5846

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( NULL ) NOT IN ( + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4405
SELECT ALL + tab2.col1 DIV + col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4405
SELECT ALL + tab2.col1 / + col1 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4406
SELECT col2 DIV + col0 + + col1 - - col0 FROM tab2
----
137
41
96

skipif mysql # not compatible
query I rowsort label-4406
SELECT col2 / + col0 + + col1 - - col0 FROM tab2
----
137
41
96

query I rowsort
SELECT ALL tab2.col2 * + col1 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL - col1 * col0 + col2 - - col0 * col1 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT tab1.col1 + - tab1.col1 FROM tab1
----
0

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( - col0 ) >= col0
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL - 33 + + col1 FROM tab0 AS cor0
----
53
58
64

query I rowsort
SELECT ALL + - col1 - - cor0.col1 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - col1 * + col2 + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT - 85 + + col1 * - col0 FROM tab2 AS cor0
----
-1428
-302
-4687

query I rowsort
SELECT ALL - col0 + - col0 * - col2 AS col2 FROM tab0 cor0
----
0
7209
768

query I rowsort
SELECT + 65 + + col0 FROM tab1 cor0
----
129
145
68

query I rowsort
SELECT DISTINCT + + col2 + cor0.col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT + 16 * 97 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 3bdcbc8f9066bf88895658b5da2bb229

query I rowsort
SELECT ALL col2 * col0 * ( ( - cor0.col1 ) ) + ( 36 ) FROM tab0 AS cor0
----
-3359
-664082
-68076

onlyif mysql # use DIV operator for integer division
query I rowsort label-4420
SELECT ALL - col0 DIV - col2 AS col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-4420
SELECT ALL - col0 / - col2 AS col2 FROM tab0
----
0
1
35

query III rowsort
SELECT * FROM tab2 WHERE NOT - col2 * col1 * - col1 - col1 / - col0 <= + col1 - + col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT col1 + + col1 + col0 FROM tab1
----
106
55
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-4423
SELECT ALL + tab1.col1 DIV - col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4423
SELECT ALL + tab1.col1 / - col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + tab2.col1 * - col1 * + col2 AS col2 FROM tab2
----
-10982
-25947
-90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-4425
SELECT ALL + col1 DIV tab0.col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4425
SELECT ALL + col1 / tab0.col1 FROM tab0
----
1
1
1

query I rowsort
SELECT + tab2.col0 * - col1 + + col0 * col2 + + col2 FROM tab2
----
-1
-2548
1697

onlyif mysql # use DIV operator for integer division
query I rowsort label-4427
SELECT DISTINCT cor0.col0 DIV col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4427
SELECT DISTINCT cor0.col0 / col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL cor0.col2 * + col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT col0 * cor0.col0 + + col0 * cor0.col1 * + col2 AS col0 FROM tab1 AS cor0
----
106240
40576
4221

query I rowsort
SELECT DISTINCT - col1 + cor0.col1 * + col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT cor0.col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # use DIV operator for integer division
query I rowsort label-4432
SELECT DISTINCT col2 + + col1 DIV - col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4432
SELECT DISTINCT col2 + + col1 / - col2 FROM tab1
----
54
57
96

query I rowsort
SELECT ALL + col2 * col2 + - col1 AS col2 FROM tab0
----
-96
1003
6633

query I rowsort
SELECT + col2 + - col2 + col2 FROM tab1
----
54
57
96

query III rowsort
SELECT * FROM tab0 WHERE col2 = - col2
----

query I rowsort
SELECT ALL col1 + tab2.col1 * col1 AS col1 FROM tab2
----
306
3540
992

query I rowsort
SELECT + tab2.col0 AS col2 FROM tab2 WHERE NOT NULL IN ( col1 + col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col1 BETWEEN NULL AND col1 / - col0
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT NULL NOT BETWEEN NULL AND col0
----

query IIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0 WHERE ( NULL ) <> ( NULL )
----

query I rowsort
SELECT DISTINCT col0 + - tab0.col2 * col1 AS col0 FROM tab0
----
-2814
-62
-7373

query III rowsort
SELECT ALL * FROM tab1 WHERE col2 NOT BETWEEN col2 AND ( NULL )
----

query I rowsort
SELECT + col1 + + col0 FROM tab0 WHERE NULL NOT IN ( + tab0.col1 * + tab0.col2 * col0 + - col1 - + col2 )
----

query I rowsort
SELECT - col0 AS col0 FROM tab1 WHERE NOT ( NULL ) IN ( + col2 )
----

query I rowsort
SELECT - + 47 AS col0 FROM tab0 AS cor0
----
-47
-47
-47

query I rowsort
SELECT ALL 14 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col1 col0 FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT - 99 AS col1 FROM tab2, tab1 AS cor0
----
-99

query I rowsort
SELECT ALL + ( 65 + - col1 ) * + tab2.col1 FROM tab2
----
1054
354
816

query I rowsort
SELECT DISTINCT + 89 AS col0 FROM tab0, tab2 cor0
----
89

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab1 AS cor1, tab0, tab2 cor2
----
3645 values hashing to d2c0c94b38e721d8cf9f7df226475a2f

query I rowsort
SELECT - - col0 * col0 * col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT + cor1.col1 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( 31 AS REAL ) * col1 AS col1 FROM tab0 AS cor0
----
-2666
-2821
-3007

query I rowsort
SELECT DISTINCT - - 3 * col0 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT ALL - 78 * + tab1.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 417989dda1c8e28639bb31d9f39cc256

query I rowsort
SELECT ( + ( + col2 ) ) * + 51 FROM tab1 AS cor0
----
2754
2907
4896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT + col1 * col0 AS col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL + + cor0.col1 * - 80 AS col1 FROM tab0 AS cor0
----
-6880
-7280
-7760

query I rowsort
SELECT ALL 28 + - col1 AS col2 FROM tab1
----
15
18
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4462
SELECT 51 + + col0 DIV + ( + col0 ) FROM tab0
----
52
52
52

skipif mysql # not compatible
query I rowsort label-4462
SELECT 51 + + col0 / + ( + col0 ) FROM tab0
----
52
52
52

query I rowsort
SELECT col1 * col0 * tab2.col0 + tab2.col1 * + col1 + col1 FROM tab2
----
106403
2511
362496

query I rowsort
SELECT - tab2.col2 - tab2.col2 AS col0 FROM tab2
----
-52
-54
-76

query I rowsort
SELECT DISTINCT + col1 * col2 + + col2 AS col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 + + 49 * cor0.col2 * + col0 AS col1 FROM tab1 AS cor0
----
178652
376151
7262

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4467
SELECT + - 92 * col1 + + CAST( ( - col2 ) AS SIGNED ) * CAST( col0 * - col2 AS SIGNED ) col0 FROM tab1 AS cor0
----
207016
6356
736084

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4467
SELECT + - 92 * col1 + + CAST ( ( - col2 ) AS INTEGER ) * CAST ( col0 * - col2 AS INTEGER ) col0 FROM tab1 AS cor0
----
207016
6356
736084

query I rowsort
SELECT ALL + 72 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT ALL + col1 * col1 + + 15 * - col0 * + col1 AS col2 FROM tab1 AS cor0
----
-15431
-494
-9500

query I rowsort
SELECT - col2 + 79 * - col2 FROM tab2 AS cor0
----
-2080
-2160
-3040

query I rowsort
SELECT ALL + col0 * - ( + col2 ) + + col0 * col2 * - col0 + col1 AS col1 FROM tab0 AS cor0
----
-1163
-19714
-656729

query I rowsort
SELECT ALL - cor0.col2 + 41 AS col0 FROM tab2 AS cor0
----
14
15
3

query I rowsort
SELECT + + col1 + + col0 * + ( - col1 ) AS col0 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + + col0 * + 92 AS col0 FROM tab1 AS cor0
----
276
5888
7360

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4475
SELECT cor0.col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4475
SELECT cor0.col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + + tab0.col1 FROM tab0
----
172
182
194

query I rowsort
SELECT - - col1 * 99 AS col1 FROM tab1 AS cor0
----
1287
2574
990

query I rowsort
SELECT ALL - col1 + ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col0 + col1 col2 FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4480
SELECT DISTINCT col2 DIV CAST( + ( + col0 ) AS SIGNED ) + cor0.col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-4480
SELECT DISTINCT col2 / CAST ( + ( + col0 ) AS INTEGER ) + cor0.col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT col1 + - col2 * col1 AS col2 FROM tab1 cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( - col2 ) col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + col0 + col1 * col1 * col2 FROM tab1
----
16304
36507
5764

query I rowsort
SELECT - cor0.col0 * - col0 + col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT + 19 * - col2 AS col2 FROM tab1 AS cor0
----
-1026
-1083
-1824

query I rowsort
SELECT + ( + tab0.col0 ) AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT + ( + col1 ) + - cor0.col2 * col1 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT - col1 + 6 * col1 AS col1 FROM tab0 cor0
----
430
455
485

query I rowsort
SELECT - col1 * + col0 + + col2 - + col2 * col1 AS col0 FROM tab0 AS cor0
----
-15479
-3491
-4869

query I rowsort
SELECT col0 * - ( + col1 ) + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - cor0.col2 * col2 * - col2 FROM tab1 cor0
----
157464
185193
884736

query I rowsort
SELECT + + col1 * - 5 * - ( + col2 ) AS col2 FROM tab1 AS cor0
----
2850
6240
7020

query I rowsort
SELECT col1 + 99 * col0 + + col1 AS col0 FROM tab1 AS cor0
----
349
6356
7946

query I rowsort
SELECT DISTINCT col0 + col0 + + ( - 88 ) * col2 FROM tab2
----
-2132
-2362
-3186

query I rowsort
SELECT ALL - 44 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 38f05fdaaf15e64b62f27cd96f73fb79

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort
SELECT ALL - - col2 * CAST ( + 40 AS REAL ) AS col2 FROM tab2 cor0
----
1040
1080
1520

query I rowsort
SELECT col0 * + 77 + col1 FROM tab2 AS cor0
----
570
6065
6100

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + col2 * CAST ( - col1 AS REAL ) col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - - col0 * + cor0.col2 + - col1 AS col0 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-4501
SELECT DISTINCT - col1 DIV - col1 AS col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-4501
SELECT DISTINCT - col1 / - col1 AS col2 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * + col0 col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL - col0 + - col0 * col1 FROM tab2 cor0
----
-1422
-224
-4680

query I rowsort
SELECT + + cor0.col0 * cor0.col2 + col2 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + col1 * tab2.col1 - - col0 * tab2.col0 AS col1 FROM tab2
----
1010
6530
9565

query I rowsort
SELECT - tab2.col0 + col1 + col1 AS col1 FROM tab2
----
-45
40
55

query I rowsort
SELECT col2 + - col0 * - col1 AS col2 FROM tab0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + + tab2.col0 col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to d40e76ad3ecba1cdc513f741425fe08a

query I rowsort
SELECT DISTINCT col0 * + col0 + + col2 - + col1 AS col0 FROM tab1
----
37
4143
6483

onlyif mysql # use DIV operator for integer division
query I rowsort label-4510
SELECT col2 DIV + col0 + - col1 * - col0 FROM tab1
----
1041
640
96

skipif mysql # not compatible
query I rowsort label-4510
SELECT col2 / + col0 + - col1 * - col0 FROM tab1
----
1041
640
96

query I rowsort
SELECT + col1 * col0 + col1 + + col2 FROM tab2 AS cor0
----
1398
275
4687

query I rowsort
SELECT col2 * + cor0.col0 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL + col1 + - col2 * col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL - col0 * cor0.col0 * col2 FROM tab1 AS cor0
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-4515
SELECT - cor0.col1 DIV + col1 + - col1 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-4515
SELECT - cor0.col1 / + col1 + - col1 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT cor0.col1 + - col0 * + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * - col0 + col1 col2 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT - col2 * col0 * - tab1.col2 - + col1 AS col2 FROM tab1
----
207926
737267
8722

query I rowsort
SELECT DISTINCT + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
7
78
79

query I rowsort
SELECT + + col0 + col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - col2 + col1 * - col1 + col2 * - col2 AS col2 FROM tab1
----
-3406
-3646
-9481

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + col2 + col1 col1 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-4523
SELECT col0 DIV col1 - 99 FROM tab1
----
-93
-93
-99

skipif mysql # not compatible
query I rowsort label-4523
SELECT col0 / col1 - 99 FROM tab1
----
-93
-93
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 32 + col0 col1 FROM tab0 cor0
----
121
56
67

query I rowsort
SELECT + ( col0 ) + + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT - + col1 * - ( ( col2 ) ) + - col2 AS col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT + col2 + - 91 AS col0 FROM tab1 AS cor0
----
-34
-37
5

query I rowsort
SELECT ALL cor0.col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col0 * 67 AS col2 FROM tab1 AS cor0
----
201
4288
5360

query I rowsort
SELECT DISTINCT col2 + ( - col2 ) * col1 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT + - col0 + col0 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ( + col0 ) * col1 + + 90 AS col2 FROM tab0 AS cor0
----
2154
3485
8189

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col1 * - tab0.col1 ) + + col2 * - ( col0 ) + + 59 * - col0 col1 FROM tab0
----
-11509
-20830
-9604

query I rowsort
SELECT - col0 + 62 AS col2 FROM tab0 cor0
----
-27
27
38

query I rowsort
SELECT cor1.col1 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - col0 + - 94 AS col1 FROM tab2 cor0
----
-101
-172
-173

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( - ( + col0 ) ) + - col2 col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL - cor0.col2 + col1 - col2 FROM tab1 AS cor0
----
-104
-179
-82

query I rowsort
SELECT DISTINCT - + col0 * col1 + - col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL - - ( 24 ) * + col0 * col0 - 9 AS col0 FROM tab0 AS cor0
----
13815
190095
29391

query I rowsort
SELECT ALL + col0 + cor0.col2 * col2 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
208000
737360
8751

query I rowsort
SELECT ALL cor0.col1 + col2 * - 84 AS col2 FROM tab1 AS cor0
----
-4510
-4778
-8051

query I rowsort
SELECT 30 * cor0.col1 + 13 FROM tab2, tab2 AS cor0
----
9 values hashing to 49bb39f8de98b1a5baa0b2a41a77a3bc

query I rowsort
SELECT DISTINCT - ( col2 ) * - col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + col0 - + col1 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + 24 + col0 AS col2 FROM tab0 AS cor0
----
113
48
59

query I rowsort
SELECT + - 75 + - col2 FROM tab1 AS cor0
----
-129
-132
-171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * + col1 + - ( col1 ) col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT col0 + 85 FROM tab2
----
163
164
92

query I rowsort
SELECT DISTINCT + ( - col0 ) * col0 + col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 AS col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT 40 + + col2 FROM tab1 AS cor0
----
136
94
97

query I rowsort
SELECT + col0 * + cor0.col2 + - col2 AS col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT - 77 AS col0 FROM tab2, tab2 AS cor0
----
-77

query I rowsort
SELECT DISTINCT - tab1.col1 * - tab1.col2 + - col1 AS col0 FROM tab1
----
1235
1378
560

query I rowsort
SELECT + + col1 + + col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - 92 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to a0e6b76227d870d10c4d9f46545a7c83

query I rowsort
SELECT DISTINCT - 6 + 90 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
84

query I rowsort
SELECT ALL 59 * col0 AS col0 FROM tab2
----
413
4602
4661

query I rowsort
SELECT 75 AS col1 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT DISTINCT tab1.col1 - - tab1.col0 * col0 FROM tab1
----
35
4106
6413

query I rowsort
SELECT - + 57 AS col1 FROM tab2 AS cor0
----
-57
-57
-57

query I rowsort
SELECT DISTINCT - 20 * + col1 + col1 * - 41 FROM tab1 AS cor0
----
-1586
-610
-793

query I rowsort
SELECT DISTINCT - + 86 AS col1 FROM tab0 AS cor0
----
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-4565
SELECT - cor0.col2 * col0 + col1 * 43 - col1 DIV col1 AS col1 FROM tab2 AS cor0
----
-2272
1143
508

skipif mysql # not compatible
query I rowsort label-4565
SELECT - cor0.col2 * col0 + col1 * 43 - col1 / col1 AS col1 FROM tab2 AS cor0
----
-2272
1143
508

query I rowsort
SELECT ALL ( col0 ) * + col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - + 79 * 48 + - col0 AS col1 FROM tab2 AS cor0
----
-3799
-3870
-3871

query I rowsort
SELECT DISTINCT + 65 + 84 FROM tab2 AS cor0
----
149

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4569
SELECT col1 - - CAST( NULL AS SIGNED ) * - 53 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4569
SELECT col1 - - CAST ( NULL AS INTEGER ) * - 53 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + 99 - + col2 AS col1 FROM tab2
----
99

query I rowsort
SELECT ALL 51 + col2 FROM tab1
----
105
108
147

query I rowsort
SELECT + 77 * col1 - + col0 FROM tab2 AS cor0
----
1230
2380
4465

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col0 + col0 col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT - - 49 + col2 AS col0 FROM tab0 AS cor0
----
131
50
82

query I rowsort
SELECT ALL + col2 * + col1 * - col0 + - col1 + - col1 AS col1 FROM tab2 AS cor0
----
-119770
-51068
-5921

onlyif mysql # use DIV operator for integer division
query I rowsort label-4576
SELECT 96 DIV - col0 + col2 * col1 AS col1 FROM tab0 AS cor0
----
2834
7461
95

skipif mysql # not compatible
query I rowsort label-4576
SELECT 96 / - col0 + col2 * col1 AS col1 FROM tab0 AS cor0
----
2834
7461
95

query I rowsort
SELECT - cor0.col2 - + col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + + col1 + col2 * col1 AS col1 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - - 39 * + col0 AS col0 FROM tab1 AS cor0
----
117
2496
3120

onlyif mysql # use DIV operator for integer division
query I rowsort label-4580
SELECT ALL - - col0 + col2 DIV col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-4580
SELECT ALL - - col0 + col2 / col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT + cor0.col2 * + ( col0 ) + - col1 AS col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT - - col2 * 6 + - col1 * + col2 AS col0 FROM tab2 AS cor0
----
-1378
-418
-675

query I rowsort
SELECT - col2 * 0 FROM tab0
----
0
0
0

query I rowsort
SELECT + - col2 * - 96 + + 53 * + col2 AS col0 FROM tab1 cor0
----
14304
8046
8493

onlyif mysql # use DIV operator for integer division
query I rowsort label-4585
SELECT - col1 * 33 + - 80 DIV - col0 AS col1 FROM tab1 cor0
----
-329
-428
-832

skipif mysql # not compatible
query I rowsort label-4585
SELECT - col1 * 33 + - 80 / - col0 AS col1 FROM tab1 cor0
----
-329
-428
-832

query I rowsort
SELECT DISTINCT + - cor0.col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - col1 * - col2 + - col2 * - col0 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT col1 + - 19 FROM tab0 AS cor0
----
67
72
78

query I rowsort
SELECT - + col0 + + 80 * cor0.col2 AS col1 FROM tab1 AS cor0
----
4317
4496
7600

query I rowsort
SELECT - + 16 AS col0 FROM tab0 AS cor0
----
-16
-16
-16

query I rowsort
SELECT - - cor0.col0 * ( + col1 ) FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + - col0 col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 12 * - col2 + col2 * col1 col1 FROM tab1 cor0
----
1254
2052
2400

query I rowsort
SELECT ALL + ( - 76 ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT col0 * col2 * + 7 FROM tab0
----
245
51086
5544

query I rowsort
SELECT col1 * col0 + - col0 * col0 AS col2 FROM tab1
----
-3456
-5360
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT col0 + + col0 + 91 AS col0 FROM tab0 AS cor0
----
139
161
269

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4599
SELECT col2 + + col1 * - CAST( ( col1 ) * col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-244035
-678960
-9408

skipif mysql # not compatible
query I rowsort label-4599
SELECT col2 + + col1 * - CAST ( ( col1 ) * col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-244035
-678960
-9408

query I rowsort
SELECT + col1 * col1 + col2 * col1 + - col1 * 24 FROM tab2 AS cor0
----
1054
3599
527

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4601
SELECT ALL + col2 * + col1 + CAST( 30 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
127
2868
7492

skipif mysql # not compatible
query I rowsort label-4601
SELECT ALL + col2 * + col1 + CAST ( 30 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
127
2868
7492

query I rowsort
SELECT + 69 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 78 * + tab0.col0 col0 FROM tab0
----
1872
2730
6942

query I rowsort
SELECT - col1 + - 47 FROM tab0
----
-133
-138
-144

query I rowsort
SELECT - - col0 * - col1 * + col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT + 63 * col0 FROM tab1 AS cor0
----
189
4032
5040

query I rowsort
SELECT + - 11 + 27 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT col1 + 82 AS col0 FROM tab0 AS cor0
----
168
173
179

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - ( + col1 ) + + col2 col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT 12 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT ALL - + col0 + + 85 + + col0 AS col0 FROM tab2 AS cor0
----
85
85
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4612
SELECT + + col2 + + CAST( NULL AS SIGNED ) + 43 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4612
SELECT + + col2 + + CAST ( NULL AS INTEGER ) + 43 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + col2 * ( - col2 * + col2 ) AS col1 FROM tab2 AS cor0
----
-17550
-19656
-54834

query I rowsort
SELECT DISTINCT col1 * ( - ( - col1 ) ) FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + col2 + - 52 AS col2 FROM tab2 AS cor0
----
-14
-25
-26

query I rowsort
SELECT cor0.col1 * - col1 - + 12 FROM tab0 AS cor0
----
-7408
-8293
-9421

query I rowsort
SELECT + + col2 * + col1 + col0 + col1 * col0 FROM tab2 AS cor0
----
1061
2068
6214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 + + col2 - col1 col0 FROM tab2 AS cor0
----
1364
213
4569

query I rowsort
SELECT - col1 + ( + col2 ) + - cor0.col2 FROM tab0 cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4620
SELECT + col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4620
SELECT + col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * col1 + col1 + cor0.col0 FROM tab2 AS cor0
----
3618
385
999

onlyif mysql # use DIV operator for integer division
query I rowsort label-4622
SELECT DISTINCT + - col1 DIV 54 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4622
SELECT DISTINCT + - col1 / 54 AS col1 FROM tab1 AS cor0
----
0

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 1713adaf687595322d888d4eeefdbbc8

query I rowsort
SELECT - + col2 * - 51 - col2 AS col2 FROM tab2 AS cor0
----
1300
1350
1900

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 + + 50 + col2 col1 FROM tab0 AS cor0
----
-1174
-493
-7789

query I rowsort
SELECT + col1 + + 49 FROM tab1 AS cor0
----
59
62
75

query I rowsort
SELECT ALL + - 31 + + cor0.col0 AS col2 FROM tab2 cor0
----
-24
47
48

query I rowsort
SELECT tab0.col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + 79 + col2 FROM tab2 AS cor0
----
105
106
117

onlyif mysql # use DIV operator for integer division
query I rowsort label-4630
SELECT ALL + col2 DIV 58 AS col2 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4630
SELECT ALL + col2 / 58 AS col2 FROM tab2
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4631
SELECT + CAST( tab1.col2 AS SIGNED ) AS col1 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

skipif mysql # not compatible
query I rowsort label-4631
SELECT + CAST ( tab1.col2 AS INTEGER ) AS col1 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + 86 + - col2 * - col0 FROM tab2 AS cor0
----
2114
275
3088

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * - col1 col2 FROM tab2 AS cor0
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 * + col2 col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - - 54 + col0 AS col1 FROM tab0 AS cor0
----
143
78
89

query I rowsort
SELECT ALL + + ( - col2 ) * - col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + - ( cor0.col2 ) + + col1 AS col0 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4638
SELECT - + col1 + 58 DIV col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-4638
SELECT - + col1 + 58 / col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT col0 + - ( col0 ) FROM tab0
----
0
0
0

query I rowsort
SELECT 3 * - 82 * - col2 FROM tab0 AS cor0
----
20172
246
8118

query I rowsort
SELECT ALL - 54 + col1 FROM tab1 AS cor0
----
-28
-41
-44

query I rowsort
SELECT DISTINCT - 54 * + col0 FROM tab2 AS cor0
----
-378
-4212
-4266

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( + 79 ) * - cor0.col0 col0 FROM tab1 cor0
----
-237
-5056
-6320

query I rowsort
SELECT + - 7 * + col2 FROM tab1 AS cor0
----
-378
-399
-672

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * - 8 col0 FROM tab0 AS cor0
----
192
280
712

query I rowsort
SELECT ( col1 ) + + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + col2 + - 14 * ( col0 ) AS col1 FROM tab0
----
-1164
-303
-489

query I rowsort
SELECT ALL col1 + ( col0 ) + - col0 * col2 * tab0.col0 FROM tab0
----
-1093
-18898
-649342

onlyif mysql # use DIV operator for integer division
query I rowsort label-4649
SELECT DISTINCT + col0 DIV ( - tab0.col1 ) + col0 DIV 84 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-4649
SELECT DISTINCT + col0 / ( - tab0.col1 ) + col0 / 84 FROM tab0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 60 col1 FROM tab1
----
60
60
60

query I rowsort
SELECT DISTINCT + 78 AS col0 FROM tab2
----
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4652
SELECT ALL - CAST( NULL AS SIGNED ) * - 23 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4652
SELECT ALL - CAST ( NULL AS INTEGER ) * - 23 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 71 AS col0 FROM tab0, tab2 cor0
----
71

query I rowsort
SELECT - ( - cor0.col1 ) * - col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - ( - col0 ) * cor0.col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - col1 * - 57 AS col1 FROM tab0 AS cor0
----
4902
5187
5529

onlyif mysql # use DIV operator for integer division
query I rowsort label-4657
SELECT DISTINCT + + 85 DIV + cor0.col1 AS col0 FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-4657
SELECT DISTINCT + + 85 / + cor0.col1 AS col0 FROM tab1 AS cor0
----
3
6
8

query I rowsort
SELECT DISTINCT + - col0 * 15 FROM tab2 AS cor0
----
-105
-1170
-1185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( tab0.col2 ) col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT col2 * 64 + col0 FROM tab0 AS cor0
----
2136
5337
99

query I rowsort
SELECT DISTINCT 77 AS col1 FROM tab2 AS cor0
----
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4662
SELECT - tab0.col0 DIV col0 AS col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4662
SELECT - tab0.col0 / col0 AS col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT + - ( + col2 ) + ( + col1 * + col1 ) FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT ALL col1 * + col0 * 61 FROM tab0 AS cor0
----
125904
207095
494039

query I rowsort
SELECT - col1 * col2 + - col1 AS col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT + col0 + ( + col2 ) AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + cor0.col1 + cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 882fef197e3b41358c58e24f2db2f2e1

query I rowsort
SELECT ALL ( tab1.col2 ) * + cor0.col1 FROM tab1, tab1 cor0
----
9 values hashing to e15c44d5a431966f2851e6bf4041b374

query I rowsort
SELECT - col0 + - 56 FROM tab0 cor0
----
-145
-80
-91

query I rowsort
SELECT ALL - - col2 * + 50 + col2 AS col2 FROM tab1 AS cor0
----
2754
2907
4896

query I rowsort
SELECT + 51 + - cor1.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 0ff9a7beb7adcdaadcf9f0b9352fe556

query I rowsort
SELECT col2 * ( col2 ) + + col1 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT col0 * + ( - col2 ) + - col1 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT - col2 * col1 + + col2 * col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col1 - + 88 FROM tab2 AS cor0
----
-29
-57
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-4676
SELECT DISTINCT + col1 * + col0 + + col2 * cor0.col0 DIV + col1 AS col0 FROM tab1 AS cor0
----
1004
1630
84

skipif mysql # not compatible
query I rowsort label-4676
SELECT DISTINCT + col1 * + col0 + + col2 * cor0.col0 / + col1 AS col0 FROM tab1 AS cor0
----
1004
1630
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4677
SELECT DISTINCT - col0 * - CAST( col2 AS SIGNED ) + - col0 AS col1 FROM tab2 AS cor0
----
182
1950
2923

skipif mysql # not compatible
query I rowsort label-4677
SELECT DISTINCT - col0 * - CAST ( col2 AS INTEGER ) + - col0 AS col1 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT + col0 - col1 * + 73 * + cor0.col2 FROM tab2 AS cor0
----
-111904
-47079
-61094

query I rowsort
SELECT ALL col0 + 3 AS col1 FROM tab2 AS cor0
----
10
81
82

query I rowsort
SELECT ALL + col1 * + ( 64 ) AS col1 FROM tab0 AS cor0
----
5504
5824
6208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * col0 + + col0 * + col0 * col1 col1 FROM tab1 AS cor0
----
156
40320
82160

query I rowsort
SELECT ( col1 ) * + col0 + - col2 * - col2 FROM tab0 AS cor0
----
14823
3153
3396

query I rowsort
SELECT + col1 + 65 AS col1 FROM tab2 AS cor0
----
124
82
96

query I rowsort
SELECT DISTINCT ( col0 ) * - col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

skipif mysql # not compatible
query I rowsort
SELECT ALL + + CAST ( + col0 AS REAL ) * + col0 + ( - col2 * + col1 ) + + ( - 48 ) * + col2 AS col1 FROM tab2 AS cor0
----
-2084
3302
3771

query I rowsort
SELECT ALL ( - 68 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 3a5c3d9872a8a4148ab98ed0ab0a6c62

query I rowsort
SELECT DISTINCT + ( - 3 ) AS col2 FROM tab0, tab1 AS cor0
----
-3

query I rowsort
SELECT + col2 * col2 * col2 + ( + col0 ) * + cor0.col2 AS col1 FROM tab2 AS cor0
----
19604
19872
57874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col2 col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + ( + cor0.col0 ) * + col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT 76 + + col2 * ( col2 ) AS col0 FROM tab1 cor0
----
2992
3325
9292

query I rowsort
SELECT ALL + cor0.col1 * col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - - 49 FROM tab2, tab2 cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT - 92 + col1 * - 84 FROM tab0
----
-7316
-7736
-8240

query I rowsort
SELECT 22 - - col0 FROM tab2
----
100
101
29

query I rowsort
SELECT + - col1 + + 31 AS col0 FROM tab1 AS cor0
----
18
21
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * - ( - col2 * + col0 ) col2 FROM tab2 cor0
----
114076
5103
52728

query I rowsort
SELECT col0 * col0 + - 37 AS col1 FROM tab1
----
-28
4059
6363

query I rowsort
SELECT ALL - ( - col0 * col1 ) FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4701
SELECT DISTINCT - - ( col0 ) + col0 DIV + col0 + col1 FROM tab1 AS cor0
----
30
75
94

skipif mysql # not compatible
query I rowsort label-4701
SELECT DISTINCT - - ( col0 ) + col0 / + col0 + col1 FROM tab1 AS cor0
----
30
75
94

query I rowsort
SELECT - + col2 + col1 + + 6 FROM tab0 AS cor0
----
102
15
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4703
SELECT ALL CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4703
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-3
-64
-80

query I rowsort
SELECT - ( + 83 * - col1 ) AS col0 FROM tab0
----
7138
7553
8051

onlyif mysql # use DIV operator for integer division
query I rowsort label-4706
SELECT + 82 DIV + col2 FROM tab0
----
1
2
82

skipif mysql # not compatible
query I rowsort label-4706
SELECT + 82 / + col2 FROM tab0
----
1
2
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4707
SELECT CAST( NULL AS SIGNED ) * col2 / col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4707
SELECT CAST ( NULL AS INTEGER ) * col2 / col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 89 AS col1 FROM tab0
----
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 30 * - col0 col1 FROM tab1
----
1920
2400
90

query I rowsort
SELECT DISTINCT col1 + - col0 - + ( + col0 ) AS col2 FROM tab2
----
-141
-97
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-4711
SELECT - col2 DIV col1 - - 0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4711
SELECT - col2 / col1 - - 0 FROM tab0
----
0
0
0

query I rowsort
SELECT col2 * col0 + - col0 + - tab1.col0 * - col2 AS col0 FROM tab1
----
15280
321
7232

query I rowsort
SELECT - ( - col0 * 99 + col2 ) FROM tab1
----
243
6279
7824

query I rowsort
SELECT cor1.col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT + + 73 + - col2 * col1 FROM tab1 AS cor0
----
-1175
-1331
-497

query I rowsort
SELECT - ( col0 ) + + col1 AS col0 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4717
SELECT col1 * col2 + - col2 DIV + col2 col2 FROM tab1 AS cor0
----
1247
1403
569

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4717
SELECT col1 * col2 + - col2 / + col2 col2 FROM tab1 AS cor0
----
1247
1403
569

query I rowsort
SELECT - - col2 * col2 + 31 AS col1 FROM tab1 AS cor0
----
2947
3280
9247

query I rowsort
SELECT + col1 * + 68 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT cor0.col1 + - cor0.col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4721
SELECT - ( + col0 ) + col1 DIV + col2 FROM tab0 AS cor0
----
-22
-88
62

skipif mysql # not compatible
query I rowsort label-4721
SELECT - ( + col0 ) + col1 / + col2 FROM tab0 AS cor0
----
-22
-88
62

query I rowsort
SELECT - 29 * + 61 AS col1 FROM tab0 AS cor0
----
-1769
-1769
-1769

query I rowsort
SELECT DISTINCT cor0.col1 AS col1 FROM tab0, tab2, tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL 0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL col0 + - 4 FROM tab1 AS cor0
----
-1
60
76

query I rowsort
SELECT + + 76 AS col1 FROM tab2 AS cor0
----
76
76
76

query I rowsort
SELECT - col2 * - ( - col2 ) AS col1 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - - col2 * - col2 - col0 AS col1 FROM tab2 AS cor0
----
-1523
-736
-754

onlyif mysql # use DIV operator for integer division
query I rowsort label-4729
SELECT DISTINCT + col2 + - col2 DIV cor0.col0 FROM tab0 AS cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-4729
SELECT DISTINCT + col2 + - col2 / cor0.col0 FROM tab0 AS cor0
----
1
32
82

query I rowsort
SELECT - - col2 + col1 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) + - col0 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL - col2 + col2 - 96 AS col0 FROM tab2 AS cor0
----
-96
-96
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 79 col0 FROM tab0 AS cor0
----
-79
-79
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - - 64 + col1 AS col1 FROM tab1 AS cor0
----
74
77
90

query I rowsort
SELECT DISTINCT col2 + col0 * - col2 + - ( col0 ) AS col0 FROM tab0 AS cor0
----
-69
-7305
-783

query I rowsort
SELECT ALL + + col0 + col2 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL 46 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4739
SELECT + 97 DIV col0 FROM tab0 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-4739
SELECT + 97 / col0 FROM tab0 AS cor0
----
1
2
4

query I rowsort
SELECT ALL + + col2 + col0 * + cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + - col1 + col2 AS col1 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4742
SELECT ALL - col2 * CAST( NULL AS SIGNED ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4742
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4743
SELECT - col0 * col1 DIV + 66 AS col1 FROM tab0 AS cor0
----
-122
-31
-51

skipif mysql # not compatible
query I rowsort label-4743
SELECT - col0 * col1 / + 66 AS col1 FROM tab0 AS cor0
----
-122
-31
-51

query I rowsort
SELECT col0 * - col1 + - cor0.col1 * - col2 AS col1 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT - + col2 + col2 * + col2 FROM tab0 cor0
----
0
1056
6642

query I rowsort
SELECT col2 * - cor0.col1 + 89 * - col1 FROM tab1 AS cor0
----
-1460
-2405
-3718

query I rowsort
SELECT - col1 * - col2 + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT 88 * + col1 AS col1 FROM tab0
----
7568
8008
8536

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4749
SELECT DISTINCT - col1 - + CAST( - col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4749
SELECT DISTINCT - col1 - + CAST ( - col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - col2 * - 62 + - col1 FROM tab1 cor0
----
3322
3524
5939

query I rowsort
SELECT ALL + col2 * ( col2 * col1 ) AS col0 FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4752
SELECT + + col0 * col0 + - col1 DIV + cor0.col2 AS col2 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-4752
SELECT + + col0 * col0 + - col1 / + cor0.col2 AS col2 FROM tab1 AS cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - 25 + + col2 col2 FROM tab1 AS cor0
----
-1296
-1368
-2304

query I rowsort
SELECT tab1.col1 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT col2 * + 66 + + cor0.col2 FROM tab0 AS cor0
----
2211
5494
67

query I rowsort
SELECT DISTINCT - + ( + col1 ) + + col2 * 15 AS col0 FROM tab2 cor0
----
331
374
553

query I rowsort
SELECT ALL + col2 * cor0.col0 + + col1 * - ( + col1 ) * cor0.col0 + + col0 AS col1 FROM tab1 cor0
----
-1863
-2688
-5760

query I rowsort
SELECT + col0 * + 84 FROM tab0 cor0
----
2016
2940
7476

query I rowsort
SELECT - 97 + cor0.col0 AS col2 FROM tab0 AS cor0
----
-62
-73
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 12 col2 FROM tab1 AS cor0
----
-12

query I rowsort
SELECT ALL - + ( + col1 ) + 91 FROM tab2 AS cor0
----
32
60
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4762
SELECT DISTINCT - + ( col0 ) * - CAST( NULL AS SIGNED ) col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4762
SELECT DISTINCT - + ( col0 ) * - CAST ( NULL AS INTEGER ) col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + 8 * col0 + 94 FROM tab1 cor0
----
118
606
734

query I rowsort
SELECT ALL + - 51 AS col1 FROM tab0 AS cor0
----
-51
-51
-51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4765
SELECT col0 + + col1 * - CAST( + 37 AS SIGNED ) * - col1 - col1 FROM tab1 AS cor0
----
24989
3754
6320

skipif mysql # not compatible
query I rowsort label-4765
SELECT col0 + + col1 * - CAST ( + 37 AS INTEGER ) * - col1 - col1 FROM tab1 AS cor0
----
24989
3754
6320

query I rowsort
SELECT DISTINCT - - 22 * + col0 AS col1 FROM tab0 AS cor0
----
1958
528
770

query I rowsort
SELECT - col1 * cor0.col0 + cor0.col2 * + col0 FROM tab0 AS cor0
----
-1272
-3360
-801

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 71 * col2 col2 FROM tab2 AS cor0
----
-1846
-1917
-2698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( cor0.col2 ) * + 42 col2 FROM tab0 AS cor0
----
1386
3444
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4770
SELECT CAST( NULL AS SIGNED ) / col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4770
SELECT CAST ( NULL AS INTEGER ) / col1 AS col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4771
SELECT ALL col1 DIV col2 - - col2 * + col0 FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-4771
SELECT ALL col1 / col2 - - col2 * + col0 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + 50 - - col2 * + CAST ( - col2 + col1 AS REAL ) col1 FROM tab2 AS cor0
----
-748
158
908

onlyif mysql # use DIV operator for integer division
query I rowsort label-4773
SELECT col0 + + col1 DIV - 26 FROM tab1 cor0
----
2
64
80

skipif mysql # not compatible
query I rowsort label-4773
SELECT col0 + + col1 / - 26 FROM tab1 cor0
----
2
64
80

query I rowsort
SELECT DISTINCT - 52 + col0 FROM tab0 AS cor0
----
-17
-28
37

query I rowsort
SELECT ALL + 1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - + col1 * ( - 94 ) FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT DISTINCT + col2 - 36 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
279
2834
2882

query I rowsort
SELECT col2 * 19 + + col2 FROM tab1 AS cor0
----
1080
1140
1920

query I rowsort
SELECT 77 + - 71 AS col2 FROM tab2 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT + + 27 + col2 AS col2 FROM tab0 AS cor0
----
109
28
60

query I rowsort
SELECT ALL tab1.col2 + + col2 AS col0 FROM tab1
----
108
114
192

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 cor2
----
972 values hashing to 6dfb18fb846f922ba9ea60ce42b86fb0

query I rowsort
SELECT - ( - cor0.col2 ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT DISTINCT col2 * - 9 AS col2 FROM tab0
----
-297
-738
-9

query I rowsort
SELECT ( 29 ) FROM tab1 AS cor0
----
29
29
29

query I rowsort
SELECT ALL ( 36 ) + + col0 * - col0 FROM tab0 AS cor0
----
-1189
-540
-7885

query I rowsort
SELECT cor0.col0 * + 77 AS col1 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to 40f6f27f1de51a2ed0ae4dc0c8d1786d

query I rowsort
SELECT DISTINCT - - 0 * - 72 FROM tab2 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4789
SELECT + col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4789
SELECT + col0 / + col0 AS col0 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4790
SELECT DISTINCT - col1 DIV - CAST( 26 AS SIGNED ) AS col2 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-4790
SELECT DISTINCT - col1 / - CAST ( 26 AS INTEGER ) AS col2 FROM tab1
----
0
1

query I rowsort
SELECT tab2.col0 + - col2 + + col0 * ( col0 + col1 ) AS col1 FROM tab2
----
10738
246
7625

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4792
SELECT DISTINCT - CAST( NULL AS SIGNED ) + col0 * col0 - col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-4792
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + col0 * col0 - col2 FROM tab2
----
NULL

query I rowsort
SELECT ALL 33 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4794
SELECT tab0.col2 * + col2 DIV + tab0.col2 AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4794
SELECT tab0.col2 * + col2 / + tab0.col2 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT + 70 - - 20 AS col1 FROM tab1
----
90

query I rowsort
SELECT DISTINCT col1 + - col0 * col1 - tab2.col1 * col0 FROM tab2
----
-2669
-403
-9145

query I rowsort
SELECT DISTINCT col1 - - col0 AS col0 FROM tab2
----
137
38
96

query I rowsort
SELECT ( col1 ) * col2 * col2 AS col0 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT + ( - 47 ) + + col1 AS col2 FROM tab0 AS cor0
----
39
44
50

query I rowsort
SELECT ALL + ( col0 ) * - col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - 49 * + ( col2 ) AS col2 FROM tab0 AS cor0
----
-1617
-4018
-49

query I rowsort
SELECT + - col2 + - col1 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4803
SELECT - CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4803
SELECT - CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( + 50 AS REAL ) * col0 AS col0 FROM tab1
----
-150
-3200
-4000

query I rowsort
SELECT ( 86 ) + col1 FROM tab2 AS cor0
----
103
117
145

query I rowsort
SELECT DISTINCT - 18 + 63 * col2 FROM tab1 AS cor0
----
3384
3573
6030

onlyif mysql # use DIV operator for integer division
query I rowsort label-4807
SELECT ALL col1 DIV - col1 + col0 AS col0 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-4807
SELECT ALL col1 / - col1 + col0 AS col0 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT DISTINCT + + col1 + col1 FROM tab2 cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4809
SELECT - CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4809
SELECT - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4810
SELECT DISTINCT 71 DIV + ( - col0 ) AS col1 FROM tab0
----
-2
0

skipif mysql # not compatible
query I rowsort label-4810
SELECT DISTINCT 71 / + ( - col0 ) AS col1 FROM tab0
----
-2
0

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0 CROSS JOIN tab1, tab1 AS cor1
----
972 values hashing to 635619591835474e6aa6acdff4ab166c

query I rowsort
SELECT ALL - 61 + + col1 FROM tab0 AS cor0
----
25
30
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col1 col1 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - 36 AS col1 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 3bcd07d22b62d2042b499253b1c13d9e

query I rowsort
SELECT + - 37 * cor0.col2 + + col2 AS col2 FROM tab2 AS cor0
----
-1368
-936
-972

query I rowsort
SELECT + col0 + - col0 * - 74 + + 61 AS col1 FROM tab0 cor0
----
1861
2686
6736

query I rowsort
SELECT DISTINCT - col2 * + col0 + 33 FROM tab1 AS cor0
----
-129
-3615
-7647

query I rowsort
SELECT + 99 FROM tab2, tab2 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT ALL - + col2 + + col2 * col0 AS col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - 35 AS col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6d967b3bac2e01a0318865f682f9a97b

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT DISTINCT - cor0.col2 - - col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - + col2 + col0 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT + - col1 * + 75 * col0 + + col2 * + 47 * cor0.col1 FROM tab0 AS cor0
----
-21414
-250066
-256711

query I rowsort
SELECT ALL + cor0.col1 * + cor0.col2 + + cor0.col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL - col1 * - 40 FROM tab2 AS cor0
----
1240
2360
680

query I rowsort
SELECT ALL - 50 + + 15 * col1 AS col2 FROM tab1 AS cor0
----
100
145
340

query I rowsort
SELECT - 15 AS col0 FROM tab2 cor0
----
-15
-15
-15

query I rowsort
SELECT DISTINCT + - col0 * cor0.col2 + col2 AS col1 FROM tab2 cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 72 * - col2 - + cor0.col0 * + 17 col0 FROM tab2 AS cor0
----
-2063
-3198
-4079

query I rowsort
SELECT ( 33 ) AS col2 FROM tab2 AS cor0
----
33
33
33

query I rowsort
SELECT ( + 12 ) * + cor0.col2 AS col2 FROM tab2 cor0
----
312
324
456

query I rowsort
SELECT ALL col2 + cor0.col1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - - 55 * 69 + + col1 * + 21 FROM tab1 AS cor0
----
4005
4068
4341

query I rowsort
SELECT ( 69 ) FROM tab1 cor0
----
69
69
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4836
SELECT ALL - CAST( NULL AS SIGNED ) * - 26 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4836
SELECT ALL - CAST ( NULL AS INTEGER ) * - 26 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4837
SELECT ALL + CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4837
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4838
SELECT DISTINCT col1 DIV cor0.col1 + col0 DIV col0 FROM tab1 AS cor0
----
2

skipif mysql # not compatible
query I rowsort label-4838
SELECT DISTINCT col1 / cor0.col1 + col0 / col0 FROM tab1 AS cor0
----
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 14 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT + + ( - 99 ) FROM tab2 AS cor0
----
-99
-99
-99

query I rowsort
SELECT 34 + + 63 AS col2 FROM tab1 cor0
----
97
97
97

query I rowsort
SELECT - col0 * + 71 AS col1 FROM tab1 AS cor0
----
-213
-4544
-5680

query I rowsort
SELECT - col1 * col2 * col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT DISTINCT 52 * 33 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
1716

query I rowsort
SELECT DISTINCT + 82 AS col0 FROM tab2, tab1 AS cor0
----
82

skipif mysql # not compatible
query I rowsort
SELECT - col0 * CAST ( 55 AS REAL ) FROM tab0 AS cor0
----
-1320
-1925
-4895

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT col0 DIV col0 + - col1 DIV tab1.col2 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4847
SELECT col0 / col0 + - col1 / tab1.col2 AS col2 FROM tab1
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4848
SELECT CAST( - 67 AS SIGNED ) AS col2 FROM tab2, tab0, tab1 AS cor0, tab1 cor1
----
81 values hashing to b06dbb8370537177bf40dc825f674151

skipif mysql # not compatible
query I rowsort label-4848
SELECT CAST ( - 67 AS INTEGER ) AS col2 FROM tab2, tab0, tab1 AS cor0, tab1 cor1
----
81 values hashing to b06dbb8370537177bf40dc825f674151

query I rowsort
SELECT ALL + 32 AS col2 FROM tab0
----
32
32
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 87 col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to c0011cd00aa3e86f06bebc13678997f9

query I rowsort
SELECT DISTINCT ( - 46 ) * col1 AS col2 FROM tab1
----
-1196
-460
-598

query I rowsort
SELECT DISTINCT - 22 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-39
-53
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 23 + + cor0.col1 col0 FROM tab2 cor0
----
-6
36
8

query I rowsort
SELECT - + cor0.col0 * - cor0.col2 * col0 + - col2 FROM tab0 cor0
----
1224
18975
649440

onlyif mysql # use DIV operator for integer division
query I rowsort label-4855
SELECT DISTINCT - col0 DIV col1 col0 FROM tab2
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4855
SELECT DISTINCT - col0 / col1 col0 FROM tab2
----
-1
-4
0

query I rowsort
SELECT + 58 AS col1 FROM tab0 AS cor0
----
58
58
58

query I rowsort
SELECT DISTINCT + 25 * col2 + col0 FROM tab1 AS cor0
----
1353
1489
2480

query I rowsort
SELECT DISTINCT + col0 * - col2 * - col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL - 54 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

query I rowsort
SELECT + cor0.col2 + col1 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - 82 * + col0 FROM tab1 AS cor0
----
-246
-5248
-6560

query I rowsort
SELECT + - col2 * cor0.col0 + - ( col1 ) + + col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL tab2.col2 + col1 AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL 57 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT ALL cor0.col0 * - 62 FROM tab0, tab0 AS cor0
----
9 values hashing to 8ccb8323d1fa2c60b5f7496854776f8c

query I rowsort
SELECT DISTINCT - - col0 + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4867
SELECT ALL - - col1 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4867
SELECT ALL - - col1 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * + ( cor0.col1 ) AS col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + - cor0.col0 + - cor0.col0 AS col2 FROM tab0 cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * col2 col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT col1 + + 60 * col0 + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-386
3205
4111

query I rowsort
SELECT col1 * + 44 FROM tab2 AS cor0
----
1364
2596
748

onlyif mysql # use DIV operator for integer division
query I rowsort label-4873
SELECT DISTINCT - col1 * - col2 DIV + col2 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4873
SELECT DISTINCT - col1 * - col2 / + col2 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col0 col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4875
SELECT col1 DIV - 94 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4875
SELECT col1 / - 94 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - 32 AS col1 FROM tab2 AS cor0
----
32
32
32

query I rowsort
SELECT + + 12 * - col2 AS col1 FROM tab1 cor0
----
-1152
-648
-684

query I rowsort
SELECT + 35 - col1 FROM tab0 AS cor0
----
-51
-56
-62

query I rowsort
SELECT - col0 - - ( col2 ) AS col2 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + ( - 94 ) - cor0.col0 AS col0 FROM tab1 AS cor0
----
-158
-174
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4881
SELECT + CAST( NULL AS SIGNED ) + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4881
SELECT + CAST ( NULL AS INTEGER ) + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + + 7 FROM tab1 AS cor0
----
-57
-73
4

query I rowsort
SELECT + + 77 * + col0 - - cor0.col0 * 2 * col0 FROM tab0 cor0
----
22695
3000
5145

query I rowsort
SELECT - col0 + 85 AS col2 FROM tab1 AS cor0
----
21
5
82

query I rowsort
SELECT - - 15 + 68 FROM tab2 AS cor0
----
83
83
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4886
SELECT col1 * 67 - col0 DIV - 52 AS col1 FROM tab1 AS cor0
----
1742
671
872

skipif mysql # not compatible
query I rowsort label-4886
SELECT col1 * 67 - col0 / - 52 AS col1 FROM tab1 AS cor0
----
1742
671
872

query I rowsort
SELECT ALL 15 - col2 FROM tab2 AS cor0
----
-11
-12
-23

query I rowsort
SELECT ALL 99 * + col2 * col2 - + 3 AS col2 FROM tab1 cor0
----
288681
321648
912381

query I rowsort
SELECT DISTINCT - ( + col2 ) + + ( - 29 ) * - col0 FROM tab1 AS cor0
----
1799
2224
33

query I rowsort
SELECT col0 * - cor0.col0 + ( col2 ) FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL + cor0.col1 + - cor0.col2 * ( col1 ) - col0 FROM tab1 AS cor0
----
-1315
-1381
-624

query I rowsort
SELECT 77 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT - 98 AS col1 FROM tab0
----
-98
-98
-98

query I rowsort
SELECT tab1.col0 * - 47 AS col1 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to acc9f0a2ba51823129d15be1945560b3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4895
SELECT ALL CAST( - 17 AS SIGNED ) - - col2 AS col1 FROM tab0
----
-16
16
65

skipif mysql # not compatible
query I rowsort label-4895
SELECT ALL CAST ( - 17 AS INTEGER ) - - col2 AS col1 FROM tab0
----
-16
16
65

query I rowsort
SELECT DISTINCT col2 * + col2 - - col1 * tab1.col2 AS col2 FROM tab1
----
10464
3819
4320

query I rowsort
SELECT DISTINCT tab1.col2 + 4 FROM tab1
----
100
58
61

query I rowsort
SELECT - ( - 87 ) + - col0 AS col2 FROM tab2
----
8
80
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4899
SELECT CAST( tab0.col0 AS SIGNED ) FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4899
SELECT CAST ( tab0.col0 AS INTEGER ) FROM tab0
----
24
35
89

query I rowsort
SELECT 17 + - col1 AS col0 FROM tab0
----
-69
-74
-80

query I rowsort
SELECT DISTINCT + - 4 AS col0 FROM tab0 AS cor0
----
-4

query I rowsort
SELECT ALL 16 * + col1 + - col0 * col0 - - col2 * - col2 AS col1 FROM tab1 AS cor0
----
-15408
-2509
-7185

query I rowsort
SELECT + cor1.col2 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab2 cor2
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT ALL + 72 * - col0 AS col2 FROM tab2 AS cor0
----
-504
-5616
-5688

query I rowsort
SELECT 72 * + col0 + ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
1704
2485
6319

onlyif mysql # use DIV operator for integer division
query I rowsort label-4906
SELECT ALL + col1 DIV + col1 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4906
SELECT ALL + col1 / + col1 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col0 + col0 * ( 23 ) * - col2 AS col1 FROM tab0 AS cor0
----
-167943
-18240
-840

query I rowsort
SELECT + 33 + + col1 * col0 * - 0 AS col2 FROM tab1 AS cor0
----
33
33
33

query I rowsort
SELECT ALL - cor0.col0 + col2 + ( - col0 ) FROM tab1 cor0
----
-64
-71
48

query I rowsort
SELECT ALL - - cor0.col1 * + col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col0 + - col0 AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4912
SELECT + - col0 * + col0 DIV col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4912
SELECT + - col0 * + col0 / col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - 15 * - col2 AS col1 FROM tab1 AS cor0
----
1440
810
855

onlyif mysql # use DIV operator for integer division
query I rowsort label-4914
SELECT + - ( cor0.col0 ) DIV + col2 + - col0 - col2 AS col2 FROM tab0 AS cor0
----
-172
-57
-71

skipif mysql # not compatible
query I rowsort label-4914
SELECT + - ( cor0.col0 ) / + col2 + - col0 - col2 AS col2 FROM tab0 AS cor0
----
-172
-57
-71

query I rowsort
SELECT DISTINCT col2 + - col0 + col0 * col0 FROM tab0 AS cor0
----
1191
585
7914

query I rowsort
SELECT ALL - 19 * col0 FROM tab0 AS cor0
----
-1691
-456
-665

query I rowsort
SELECT 36 * cor0.col0 + col2 - - cor0.col1 FROM tab1 AS cor0
----
188
2371
2989

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4918
SELECT ALL + CAST( NULL AS SIGNED ) - col0 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4918
SELECT ALL + CAST ( NULL AS INTEGER ) - col0 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + - col0 + - cor0.col2 * - col0 * + col1 FROM tab1 AS cor0
----
36416
4209
99760

query I rowsort
SELECT col1 * - col2 + - col0 + col2 * col2 AS col2 FROM tab0
----
-131
-1773
-827

query I rowsort
SELECT 33 + - col0 AS col2 FROM tab0 cor0
----
-2
-56
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4922
SELECT + + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4922
SELECT + + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * - col1 + col1 * col0 FROM tab2 AS cor0
----
-744
1054
1121

query I rowsort
SELECT + + col1 * 67 FROM tab2 cor0
----
1139
2077
3953

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4925
SELECT DISTINCT - cor0.col0 + + CAST( - 88 AS SIGNED ) * col0 FROM tab0 cor0
----
-2136
-3115
-7921

skipif mysql # not compatible
query I rowsort label-4925
SELECT DISTINCT - cor0.col0 + + CAST ( - 88 AS INTEGER ) * col0 FROM tab0 cor0
----
-2136
-3115
-7921

query I rowsort
SELECT DISTINCT + - col2 - + ( col0 * col2 ) AS col1 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL - - col0 - 52 AS col2 FROM tab0 cor0
----
-17
-28
37

query I rowsort
SELECT DISTINCT + + col2 + 39 AS col2 FROM tab0 AS cor0
----
121
40
72

query I rowsort
SELECT + col1 + 94 AS col1 FROM tab2 AS cor0
----
111
125
153

query I rowsort
SELECT - col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - col1 + 92 FROM tab0 cor0
----
-5
1
6

query I rowsort
SELECT ALL + cor0.col2 + ( cor0.col1 ) FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col1 + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4934
SELECT ALL - col1 DIV + 14 - col2 AS col0 FROM tab1 AS cor0
----
-55
-57
-96

skipif mysql # not compatible
query I rowsort label-4934
SELECT ALL - col1 / + 14 - col2 AS col0 FROM tab1 AS cor0
----
-55
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4935
SELECT col2 DIV col1 + + col1 AS col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4935
SELECT col2 / col1 + + col1 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + cor0.col1 * + ( - col1 ) + - 17 AS col0 FROM tab2 AS cor0
----
-306
-3498
-978

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4937
SELECT DISTINCT + + CAST( - col2 AS SIGNED ) * + col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-4937
SELECT DISTINCT + + CAST ( - col2 AS INTEGER ) * + col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + ( col1 ) * col2 + + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT tab2.col0 * + 60 + + col0 AS col2 FROM tab2
----
427
4758
4819

query I rowsort
SELECT 51 * col0 AS col1 FROM tab1 AS cor0
----
153
3264
4080

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4941
SELECT CAST( NULL AS SIGNED ) * cor0.col0 * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4941
SELECT CAST ( NULL AS INTEGER ) * cor0.col0 * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) * col1 + - col2 col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL - ( 33 ) + - col2 + 37 * 13 AS col2 FROM tab0 AS cor0
----
366
415
447

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4944
SELECT + CAST( NULL AS SIGNED ) * + 91 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4944
SELECT + CAST ( NULL AS INTEGER ) * + 91 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 60 col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 1a0b29f8e6f82c54623a665ba4af8fd1

query I rowsort
SELECT ALL - col1 * 44 AS col0 FROM tab1
----
-1144
-440
-572

query I rowsort
SELECT + 18 * ( col1 + col2 ) AS col0 FROM tab2 AS cor0
----
1044
1530
990

query I rowsort
SELECT DISTINCT col1 * - col1 * - col2 AS col0 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT ALL + col1 * 58 FROM tab1 AS cor0
----
1508
580
754

query I rowsort
SELECT DISTINCT - + 44 + + col2 AS col0 FROM tab1 cor0
----
10
13
52

query I rowsort
SELECT DISTINCT + 5 AS col1 FROM tab2, tab1 AS cor0
----
5

query I rowsort
SELECT ALL + ( - col0 ) * cor0.col2 - + col1 FROM tab2 AS cor0
----
-2087
-220
-3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-4953
SELECT - 40 DIV tab2.col1 + col1 DIV - tab2.col0 FROM tab2
----
-2
-5
0

skipif mysql # not compatible
query I rowsort label-4953
SELECT - 40 / tab2.col1 + col1 / - tab2.col0 FROM tab2
----
-2
-5
0

query I rowsort
SELECT + 17 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT - cor0.col1 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT tab0.col2 * - col2 + - ( - 17 ) AS col1 FROM tab0
----
-1072
-6707
16

query I rowsort
SELECT DISTINCT + col1 * 96 FROM tab2
----
1632
2976
5664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + + col0 * col0 col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT 87 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0, tab0 AS cor2
----
243 values hashing to 8bc10da748e01dcb4f9c3610cdff39b0

query I rowsort
SELECT DISTINCT + tab0.col0 * + col2 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT + col1 * - 5 AS col1 FROM tab1
----
-130
-50
-65

skipif mysql # not compatible
query I rowsort
SELECT - + col1 * + CAST ( 67 AS REAL ) + cor0.col0 * + cor0.col1 FROM tab2 AS cor0
----
-1860
204
649

onlyif mysql # use DIV operator for integer division
query I rowsort label-4963
SELECT DISTINCT - + col2 DIV cor0.col2 col0 FROM tab1 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4963
SELECT DISTINCT - + col2 / cor0.col2 col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT col0 + + ( + cor0.col0 ) FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL + cor0.col1 * - ( + cor0.col1 ) + col2 + 43 FROM tab1 cor0
----
-30
-579
0

query I rowsort
SELECT DISTINCT - cor0.col2 * + 34 - + cor0.col1 AS col1 FROM tab1 AS cor0
----
-1862
-1948
-3277

query I rowsort
SELECT - + col2 * - col0 + 92 * - cor0.col0 FROM tab1 AS cor0
----
-114
-2240
320

query I rowsort
SELECT + col1 * col0 + col2 AS col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT + ( + col0 ) + ( 93 ) * - col0 AS col0 FROM tab2
----
-644
-7176
-7268

query I rowsort
SELECT - col2 + - col2 * + col0 * 8 AS col1 FROM tab0 AS cor0
----
-281
-58466
-6369

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4971
SELECT + + col0 + col2 * - CAST( - 22 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
1893
57
750

skipif mysql # not compatible
query I rowsort label-4971
SELECT + + col0 + col2 * - CAST ( - 22 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
1893
57
750

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 7 + col2 col1 FROM tab2 AS cor0
----
33
34
45

query I rowsort
SELECT DISTINCT col1 + - col0 * - col1 * cor0.col0 AS col2 FROM tab2 AS cor0
----
106114
1550
359015

query I rowsort
SELECT ALL - 56 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

query I rowsort
SELECT col1 * col2 * col0 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT - + 12 + col2 * - col2 * + col2 AS col2 FROM tab2 AS cor0
----
-17588
-19695
-54884

query I rowsort
SELECT 11 * col1 + col0 * 9 * col0 AS col1 FROM tab1 AS cor0
----
367
36974
57743

query I rowsort
SELECT + col1 + + 24 AS col2 FROM tab2
----
41
55
83

query I rowsort
SELECT - col0 + col2 * 81 AS col0 FROM tab2 AS cor0
----
2028
2180
2999

query I rowsort
SELECT - col2 * col0 + col1 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - tab2.col1 * + col1 + - col1 - 44 FROM tab2
----
-1036
-350
-3584

query I rowsort
SELECT - + col0 * + cor0.col1 + + col2 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - col1 + - col1 * - 56 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT DISTINCT + - cor0.col0 * col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4985
SELECT - CAST( + 76 AS SIGNED ) col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d90b4aa5f03b4a149aa925c4a88acca0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4985
SELECT - CAST ( + 76 AS INTEGER ) col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d90b4aa5f03b4a149aa925c4a88acca0

query I rowsort
SELECT + ( col1 ) * col0 + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT - 3 * + cor0.col2 AS col0 FROM tab0, tab2 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 02fc226cabef995f4b671b46a65e89e1

query I rowsort
SELECT DISTINCT 18 FROM tab2, tab1 cor0 CROSS JOIN tab0, tab1 AS cor1
----
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-4989
SELECT + col0 * col2 DIV col0 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-4989
SELECT + col0 * col2 / col0 FROM tab2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 96 + col2 col0 FROM tab2
----
122
123
134

onlyif mysql # use DIV operator for integer division
query I rowsort label-4991
SELECT ALL col1 DIV col1 + 20 FROM tab1
----
21
21
21

skipif mysql # not compatible
query I rowsort label-4991
SELECT ALL col1 / col1 + 20 FROM tab1
----
21
21
21

query I rowsort
SELECT ALL - col2 - - col1 AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - 56 AS col1 FROM tab1 AS cor0
----
-56
-56
-56

query I rowsort
SELECT DISTINCT 11 * col2 + + tab0.col1 * col1 + col0 AS col2 FROM tab0
----
7783
9272
9455

query I rowsort
SELECT 38 FROM tab2, tab0 cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT ALL ( 10 ) FROM tab0, tab2 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

onlyif mysql # use DIV operator for integer division
query I rowsort label-4997
SELECT ALL - tab1.col2 DIV - tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to dd2a1e9fc863524e3326dbd164233e1f

skipif mysql # not compatible
query I rowsort label-4997
SELECT ALL - tab1.col2 / - tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to dd2a1e9fc863524e3326dbd164233e1f

query I rowsort
SELECT ALL col0 * 10 FROM tab1
----
30
640
800

query I rowsort
SELECT DISTINCT + 88 FROM tab1, tab0 AS cor0
----
88

query I rowsort
SELECT col1 * 26 FROM tab0 AS cor0
----
2236
2366
2522

query I rowsort
SELECT tab1.col2 * + 61 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 4e743e0f52fe290648d09d671bc05229

query I rowsort
SELECT ALL - tab0.col0 * - 51 AS col2 FROM tab0
----
1224
1785
4539

query I rowsort
SELECT cor0.col2 + ( cor0.col2 ) + - ( - 65 ) AS col0 FROM tab0 cor0
----
131
229
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5004
SELECT + CAST( 36 AS SIGNED ) * col2 + - 87 AS col1 FROM tab1 AS cor0
----
1857
1965
3369

skipif mysql # not compatible
query I rowsort label-5004
SELECT + CAST ( 36 AS INTEGER ) * col2 + - 87 AS col1 FROM tab1 AS cor0
----
1857
1965
3369

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5005
SELECT + + CAST( NULL AS SIGNED ) * + col0 + col2 * 44 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5005
SELECT + + CAST ( NULL AS INTEGER ) * + col0 + col2 * 44 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * col0 col0 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( col1 ) col2 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + + ( - col2 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL - + col2 * col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col1 + col0 * + col0 AS col1 FROM tab1 cor0
----
-17
4086
6387

query I rowsort
SELECT DISTINCT col2 * - 40 AS col1 FROM tab0 AS cor0
----
-1320
-3280
-40

query I rowsort
SELECT + - col2 - col2 * + col0 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT + - col2 * ( col0 * col0 ) AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT + 0 * cor0.col1 + col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - 4 + - col1 * col2 AS col0 FROM tab1 AS cor0
----
-1252
-1408
-574

query I rowsort
SELECT + col1 * 51 FROM tab1 AS cor0
----
1326
510
663

query I rowsort
SELECT ALL - 85 AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 91e44ead5e72fa22f87a57243e232ede

query I rowsort
SELECT DISTINCT + - col2 + col2 + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - 21 * + col0 AS col0 FROM tab0 AS cor0
----
-1869
-504
-735

query I rowsort
SELECT + - col0 * - col2 + ( + cor0.col1 ) + col1 AS col0 FROM tab0 cor0
----
229
7480
964

query I rowsort
SELECT ( - tab0.col2 * ( + col2 ) ) AS col1 FROM tab0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 + + col2 col1 FROM tab2
----
55
58
85

query I rowsort
SELECT + 10 FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2, tab0 cor3
----
243 values hashing to 75ac55f1d3b666f2332e2c4bb542aa66

query I rowsort
SELECT ALL - + col2 * - col0 + col0 * - col1 FROM tab2 AS cor0
----
-2574
-28
1659

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 77 col1 FROM tab1 AS cor0
----
-4158
-4389
-7392

onlyif mysql # use DIV operator for integer division
query I rowsort label-5026
SELECT + col1 * cor0.col2 DIV - col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-5026
SELECT + col1 * cor0.col2 / - col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col2 * ( + 19 ) + col2 FROM tab0 cor0
----
-1476
-18
-594

onlyif mysql # use DIV operator for integer division
query I rowsort label-5028
SELECT ALL col2 DIV 20 FROM tab0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5028
SELECT ALL col2 / 20 FROM tab0
----
0
1
4

query I rowsort
SELECT 60 FROM tab2, tab0 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT + col2 + ( - col1 ) * col1 * - ( col2 + cor0.col2 ) AS col1 FROM tab0 cor0
----
1358166
18819
488169

query I rowsort
SELECT col2 * 58 FROM tab0 AS cor0
----
1914
4756
58

query I rowsort
SELECT ALL - col2 + col1 * col2 AS col2 FROM tab0 AS cor0
----
2805
7380
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + 27 * + col2 col0 FROM tab0 AS cor0
----
2296
28
924

query I rowsort
SELECT DISTINCT - - col2 + ( col2 ) * col0 FROM tab1 cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + - col0 * + ( col1 ) col0 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT - col2 * + 67 FROM tab0 cor0
----
-2211
-5494
-67

query I rowsort
SELECT DISTINCT col0 * 97 FROM tab1 AS cor0
----
291
6208
7760

query I rowsort
SELECT + cor0.col2 * col1 AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col2 + ( + col1 ) * - col0 AS col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT - col2 + 62 AS col2 FROM tab1
----
-34
5
8

query I rowsort
SELECT - + 64 + col0 FROM tab2 cor0
----
-57
14
15

query I rowsort
SELECT 55 + col2 * - col2 AS col0 FROM tab1
----
-2861
-3194
-9161

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2
----
3645 values hashing to ac17da4547aa356439ff11568174588c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5044
SELECT ALL - CAST( col2 AS SIGNED ) + col0 AS col2 FROM tab2 AS cor0
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-5044
SELECT ALL - CAST ( col2 AS INTEGER ) + col0 AS col2 FROM tab2 AS cor0
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 28 * col2 + - col0 * col2 * 81 col2 FROM tab0 AS cor0
----
-2807
-588842
-63228

query I rowsort
SELECT - + col2 * cor0.col0 + + cor0.col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT + ( col2 ) - - col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - 37 * 60 AS col1 FROM tab2 AS cor0
----
-2220
-2220
-2220

query I rowsort
SELECT - col0 + cor0.col1 + - col2 FROM tab2 AS cor0
----
-100
-3
-45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5050
SELECT DISTINCT CAST( col1 AS SIGNED ) * + col1 + col2 * 9 * - cor0.col1 FROM tab2 AS cor0
----
-10325
-5525
-6572

skipif mysql # not compatible
query I rowsort label-5050
SELECT DISTINCT CAST ( col1 AS INTEGER ) * + col1 + col2 * 9 * - cor0.col1 FROM tab2 AS cor0
----
-10325
-5525
-6572

query I rowsort
SELECT DISTINCT - - 22 AS col1 FROM tab2 AS cor0
----
22

query I rowsort
SELECT + col1 * col2 + col0 * col2 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT - col1 * - 99 AS col0 FROM tab0 AS cor0
----
8514
9009
9603

onlyif mysql # use DIV operator for integer division
query I rowsort label-5054
SELECT ALL + col1 * + col2 + col2 + ( - 18 ) DIV - col2 FROM tab0 AS cor0
----
116
2871
7544

skipif mysql # not compatible
query I rowsort label-5054
SELECT ALL + col1 * + col2 + col2 + ( - 18 ) / - col2 FROM tab0 AS cor0
----
116
2871
7544

query I rowsort
SELECT ALL 11 * + col0 + + col0 AS col0 FROM tab2 cor0
----
84
936
948

query I rowsort
SELECT DISTINCT + 68 AS col2 FROM tab2, tab1 AS cor0, tab0 cor1
----
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-5057
SELECT - cor0.col1 + col0 DIV ( - col1 + col2 * - cor0.col1 ) FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5057
SELECT - cor0.col1 + col0 / ( - col1 + col2 * - cor0.col1 ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col0 + - col0 FROM tab0 cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT col2 * - col0 + col1 - 54 * col1 FROM tab2 AS cor0
----
-1832
-3903
-5155

query I rowsort
SELECT DISTINCT - col1 * col0 + - ( ( - col0 ) * col2 ) FROM tab0 AS cor0
----
-1272
-3360
-801

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5061
SELECT - - col1 * + col0 * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5061
SELECT - - col1 * + col0 * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 14 + col0 * col1 col0 FROM tab2 AS cor0
----
1329
203
4588

onlyif mysql # use DIV operator for integer division
query I rowsort label-5063
SELECT ALL - - col1 * + cor0.col2 + - col2 + + col2 DIV + col0 FROM tab0 AS cor0
----
2806
7380
96

skipif mysql # not compatible
query I rowsort label-5063
SELECT ALL - - col1 * + cor0.col2 + - col2 + + col2 / + col0 FROM tab0 AS cor0
----
2806
7380
96

query I rowsort
SELECT + 29 + col2 FROM tab2 cor0
----
55
56
67

query I rowsort
SELECT DISTINCT - cor0.col2 - col2 * + 53 FROM tab1 AS cor0
----
-2916
-3078
-5184

query I rowsort
SELECT ALL - cor0.col1 - - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - 67 * col1 FROM tab1 AS cor0
----
-1742
-670
-871

query I rowsort
SELECT DISTINCT - col0 * + col0 + - 45 - col0 * col0 AS col1 FROM tab2 AS cor0
----
-12213
-12527
-143

query I rowsort
SELECT DISTINCT - + 30 + col2 * col1 FROM tab2 AS cor0
----
1504
616
807

query I rowsort
SELECT + 57 AS col0 FROM tab1 AS cor0
----
57
57
57

query I rowsort
SELECT + 85 * col1 FROM tab1 AS cor0
----
1105
2210
850

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5072
SELECT - col1 / + col1 + - CAST( NULL AS SIGNED ) * 43 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5072
SELECT - col1 / + col1 + - CAST ( NULL AS INTEGER ) * 43 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col2 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5074
SELECT + col2 + + CAST( + col0 * + col2 AS SIGNED ) AS col0 FROM tab1 cor0
----
216
3705
7776

skipif mysql # not compatible
query I rowsort label-5074
SELECT + col2 + + CAST ( + col0 * + col2 AS INTEGER ) AS col0 FROM tab1 cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 56 + cor1.col0 col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4017dba853a419d426bf2797b1325f85

query I rowsort
SELECT - ( - 78 ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query I rowsort
SELECT + col0 * col2 + cor0.col1 + 29 AS col1 FROM tab1 AS cor0
----
217
3687
7722

query I rowsort
SELECT + - col1 * - 27 + cor0.col1 FROM tab1 AS cor0
----
280
364
728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 + + col1 col0 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL ( col2 ) + + col1 + - 76 AS col0 FROM tab1
----
-9
33
4

query I rowsort
SELECT DISTINCT + tab1.col0 * - col2 + col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT ALL - - cor0.col0 + + col1 + col0 AS col2 FROM tab1 AS cor0
----
138
173
32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5083
SELECT - CAST( col0 AS SIGNED ) * + cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-5083
SELECT - CAST ( col0 AS INTEGER ) * + cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - CAST ( col2 AS REAL ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL - + ( cor0.col1 ) * col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL col1 * + col2 * tab1.col1 FROM tab1
----
16224
36504
5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 55 ) * - col2 col2 FROM tab0
----
-1815
-4510
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-5088
SELECT - cor0.col1 + - col2 DIV + col0 FROM tab0 AS cor0
----
-87
-91
-97

skipif mysql # not compatible
query I rowsort label-5088
SELECT - cor0.col1 + - col2 / + col0 FROM tab0 AS cor0
----
-87
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5089
SELECT + + col0 + CAST( col2 * cor0.col0 AS SIGNED ) FROM tab0 AS cor0
----
70
7387
816

skipif mysql # not compatible
query I rowsort label-5089
SELECT + + col0 + CAST ( col2 * cor0.col0 AS INTEGER ) FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT + col1 + 10 AS col0 FROM tab2 AS cor0
----
27
41
69

query I rowsort
SELECT ALL col0 - col1 * + col2 AS col2 FROM tab2
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5092
SELECT - ( col2 ) + col0 * - CAST( - cor0.col1 AS SIGNED ) AS col1 FROM tab0 cor0
----
2031
3394
8017

skipif mysql # not compatible
query I rowsort label-5092
SELECT - ( col2 ) + col0 * - CAST ( - cor0.col1 AS INTEGER ) AS col1 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT col2 + - 72 AS col2 FROM tab1 AS cor0
----
-15
-18
24

query I rowsort
SELECT ALL tab1.col1 + + col0 + + tab1.col2 * - tab1.col2 * col0 AS col0 FROM tab1
----
-207862
-737187
-8719

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 58 + col0 col0 FROM tab1 AS cor0
----
3135
3370
5648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5096
SELECT DISTINCT - + CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5096
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + + 0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + + 53 * - col2 FROM tab1 AS cor0
----
-2862
-3021
-5088

query I rowsort
SELECT + col0 * cor0.col2 - + col2 AS col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT + + col1 * col0 + col1 * - col2 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT + col0 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL - - col0 + - 48 FROM tab0 cor0
----
-13
-24
41

query I rowsort
SELECT ALL ( col0 + col1 ) FROM tab2
----
137
38
96

query I rowsort
SELECT + col1 + col2 * + col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL - + col2 * - col0 * col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - col2 * ( + col2 ) FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - - col2 + - col0 * col2 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-5108
SELECT ALL + cor0.col0 DIV 68 AS col1 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5108
SELECT ALL + cor0.col0 / 68 AS col1 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL + col2 * + col1 + col0 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - col2 * ( - ( col1 ) ) FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5111
SELECT col0 * - CAST( NULL AS SIGNED ) + col2 * - col0 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5111
SELECT col0 * - CAST ( NULL AS INTEGER ) + col2 * - col0 col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 50 + col2 + col0 AS col0 FROM tab2 AS cor0
----
154
167
84

skipif mysql # not compatible
query I rowsort
SELECT ALL - + CAST ( cor0.col1 AS REAL ) * col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + - 39 + 36 AS col1 FROM tab0 AS cor0
----
-3
-3
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5115
SELECT DISTINCT cor0.col1 + 1 * + col0 DIV - col1 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-5115
SELECT DISTINCT cor0.col1 + 1 * + col0 / - col1 FROM tab1 AS cor0
----
26
4
7

query I rowsort
SELECT ALL + ( 96 ) * - col0 - + col2 * + ( + col0 ) AS col0 FROM tab2 cor0
----
-10586
-861
-9516

query I rowsort
SELECT 40 * - 69 + col0 * + col1 FROM tab1 AS cor0
----
-1720
-2120
-2682

query I rowsort
SELECT DISTINCT - 68 * - col2 + col0 * cor0.col1 FROM tab2 AS cor0
----
2053
3927
6370

query I rowsort
SELECT DISTINCT - col0 * tab2.col1 + 91 * col2 AS col0 FROM tab2
----
-2236
2115
2240

query I rowsort
SELECT DISTINCT col2 * 12 - - col2 FROM tab1
----
1248
702
741

query I rowsort
SELECT col1 * ( + 63 ) FROM tab0
----
5418
5733
6111

query I rowsort
SELECT - col1 * + tab2.col2 + - col0 * col2 + 9 * - 54 FROM tab2
----
-1512
-4048
-4134

query I rowsort
SELECT ALL - col0 * + col2 + 6 - col0 AS col2 FROM tab0
----
-64
-7381
-810

query I rowsort
SELECT DISTINCT + col2 * + col1 - 54 * col0 AS col1 FROM tab0
----
-1793
1542
2656

query I rowsort
SELECT - 8 + + tab2.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to bc5bdd5902a62dd9ecaca47e41d56ede

query I rowsort
SELECT DISTINCT - 49 * + col2 AS col1 FROM tab2 AS cor0
----
-1274
-1323
-1862

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 90 col2 FROM tab0 cor0
----
90
90
90

query I rowsort
SELECT DISTINCT col2 + 93 + col0 * ( col0 ) FROM tab2
----
169
6203
6372

onlyif mysql # use DIV operator for integer division
query I rowsort label-5129
SELECT DISTINCT - CAST( - ( col2 ) * + 54 AS SIGNED ) + + col1 DIV + col2 FROM tab0
----
151
1784
4429

skipif mysql # not compatible
query I rowsort label-5129
SELECT DISTINCT - CAST ( - ( col2 ) * + 54 AS INTEGER ) + + col1 / + col2 FROM tab0
----
151
1784
4429

query I rowsort
SELECT DISTINCT + + 25 FROM tab0, tab2, tab1 AS cor0
----
25

query I rowsort
SELECT DISTINCT - col0 * + tab0.col2 * col1 AS col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT tab2.col1 - col2 * col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT - cor0.col1 * cor0.col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT - + ( - cor0.col2 ) * - ( + 96 ) * col2 FROM tab2 cor0
----
-138624
-64896
-69984

query I rowsort
SELECT - ( + col0 ) * + col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + - col2 + col0 AS col1 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - ( ( col2 ) ) + 86 FROM tab0 cor0
----
4
53
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5138
SELECT - - CAST( NULL AS SIGNED ) + col0 * col0 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-5138
SELECT - - CAST ( NULL AS INTEGER ) + col0 * col0 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * - cor0.col0 * + col1 - col0 * 29 * + col1 AS col2 FROM tab0 AS cor0
----
117648
230860
502138

query I rowsort
SELECT - col2 + 29 * col1 FROM tab2 AS cor0
----
1685
455
872

query I rowsort
SELECT ALL + - 44 * - 27 FROM tab2 AS cor0
----
1188
1188
1188

query I rowsort
SELECT ALL - 46 + col2 * + col1 FROM tab1 AS cor0
----
1202
1358
524

query I rowsort
SELECT + - col2 * 86 + col2 FROM tab2 cor0
----
-2210
-2295
-3230

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 98 col0 FROM tab0 cor0
----
184
189
195

query I rowsort
SELECT cor0.col1 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - + cor0.col2 - col1 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - + 78 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to c4f3c63f98c3c08f2848f46850a476d4

query I rowsort
SELECT - col1 * col2 * - col0 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT - - col1 + + cor0.col0 * col0 FROM tab2 cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT col1 - + col2 AS col1 FROM tab0 cor0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5151
SELECT DISTINCT + CAST( col1 + - col1 AS SIGNED ) AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-5151
SELECT DISTINCT + CAST ( col1 + - col1 AS INTEGER ) AS col2 FROM tab1
----
0

query I rowsort
SELECT 32 * - ( col0 + col1 ) FROM tab0
----
-3520
-4224
-5760

query I rowsort
SELECT ALL 40 - + col1 * col2 * col0 AS col1 FROM tab1
----
-36440
-4172
-99800

onlyif mysql # use DIV operator for integer division
query I rowsort label-5154
SELECT DISTINCT - col2 * - col0 + col0 DIV col1 - + col2 FROM tab0
----
34
7216
759

skipif mysql # not compatible
query I rowsort label-5154
SELECT DISTINCT - col2 * - col0 + col0 / col1 - + col2 FROM tab0
----
34
7216
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5155
SELECT DISTINCT col0 * CAST( 94 AS SIGNED ) FROM tab0 AS cor0
----
2256
3290
8366

skipif mysql # not compatible
query I rowsort label-5155
SELECT DISTINCT col0 * CAST ( 94 AS INTEGER ) FROM tab0 AS cor0
----
2256
3290
8366

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5156
SELECT col2 - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5156
SELECT col2 - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5157
SELECT - col0 DIV tab2.col1 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-5157
SELECT - col0 / tab2.col1 FROM tab2
----
-1
-4
0

query I rowsort
SELECT 78 * col0 FROM tab1
----
234
4992
6240

query I rowsort
SELECT + col2 + col0 + col1 FROM tab2
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5160
SELECT DISTINCT + 93 DIV + col2 + - ( + 66 ) * - col0 AS col2 FROM tab1
----
199
4225
5280

skipif mysql # not compatible
query I rowsort label-5160
SELECT DISTINCT + 93 / + col2 + - ( + 66 ) * - col0 AS col2 FROM tab1
----
199
4225
5280

query I rowsort
SELECT + 75 + + col0 + - col2 AS col0 FROM tab2
----
116
127
55

query I rowsort
SELECT + col0 + - col1 * + tab1.col2 FROM tab1
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5163
SELECT DISTINCT col2 + col1 + + CAST( col2 AS SIGNED ) AS col0 FROM tab0
----
152
255
99

skipif mysql # not compatible
query I rowsort label-5163
SELECT DISTINCT col2 + col1 + + CAST ( col2 AS INTEGER ) AS col0 FROM tab0
----
152
255
99

query I rowsort
SELECT DISTINCT + tab0.col2 * - col2 + + 69 - - 9 * - col0 AS col1 FROM tab0
----
-1236
-247
-7456

query I rowsort
SELECT ALL + cor1.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL - tab0.col2 + col0 AS col1 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL - col2 + - col1 - col0 FROM tab2 AS cor0
----
-134
-163
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5168
SELECT ALL cor0.col1 DIV - 27 + - col1 AS col0 FROM tab2 AS cor0
----
-17
-32
-61

skipif mysql # not compatible
query I rowsort label-5168
SELECT ALL cor0.col1 / - 27 + - col1 AS col0 FROM tab2 AS cor0
----
-17
-32
-61

query I rowsort
SELECT ALL - + col0 * + col1 * - col2 + - col2 AS col1 FROM tab1 AS cor0
----
36423
4158
99744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + cor0.col0 col0 FROM tab2 cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-5171
SELECT + cor0.col0 DIV + 30 AS col1 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5171
SELECT + cor0.col0 / + 30 AS col1 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT DISTINCT - col0 + + 52 FROM tab1 AS cor0
----
-12
-28
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5173
SELECT ALL + + cor0.col1 + CAST( NULL AS DECIMAL ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5173
SELECT ALL + + cor0.col1 + CAST ( NULL AS REAL ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 + - 39 FROM tab0 AS cor0
----
-15
-4
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-5175
SELECT tab2.col2 * + col0 + - col1 DIV tab2.col1 + + ( col1 + col0 ) * - col1 FROM tab2
----
-6056
-990
1369

skipif mysql # not compatible
query I rowsort label-5175
SELECT tab2.col2 * + col0 + - col1 / tab2.col1 + + ( col1 + col0 ) * - col1 FROM tab2
----
-6056
-990
1369

query I rowsort
SELECT 84 FROM tab2, tab2 cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5177
SELECT ALL - col2 DIV 63 + col1 col2 FROM tab1
----
10
12
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5177
SELECT ALL - col2 / 63 + col1 col2 FROM tab1
----
10
12
26

query I rowsort
SELECT ALL - col2 + ( - 58 ) FROM tab1
----
-112
-115
-154

query I rowsort
SELECT - - col0 * - cor0.col1 + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT - col1 * - 26 AS col1 FROM tab1
----
260
338
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5181
SELECT - CAST( + cor0.col0 AS SIGNED ) * - col0 + CAST( col2 AS SIGNED ) * cor0.col1 AS col0 FROM tab1 cor0
----
1413
4666
7648

skipif mysql # not compatible
query I rowsort label-5181
SELECT - CAST ( + cor0.col0 AS INTEGER ) * - col0 + CAST ( col2 AS INTEGER ) * cor0.col1 AS col0 FROM tab1 cor0
----
1413
4666
7648

query I rowsort
SELECT 80 * + col0 + - col0 FROM tab2 AS cor0
----
553
6162
6241

query I rowsort
SELECT - ( + 37 ) AS col2 FROM tab1 AS cor0
----
-37
-37
-37

query I rowsort
SELECT ( col0 ) + col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - 96 * col1 * - col1 + cor0.col2 AS col1 FROM tab1 AS cor0
----
16320
64950
9657

query I rowsort
SELECT + ( 10 ) + col2 AS col1 FROM tab0 AS cor0
----
11
43
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5187
SELECT - - CAST( cor0.col1 AS SIGNED ) * col1 DIV col0 AS col0 FROM tab0 AS cor0
----
268
308
93

skipif mysql # not compatible
query I rowsort label-5187
SELECT - - CAST ( cor0.col1 AS INTEGER ) * col1 / col0 AS col0 FROM tab0 AS cor0
----
268
308
93

query I rowsort
SELECT + - 52 FROM tab1 cor0
----
-52
-52
-52

query I rowsort
SELECT - 16 * - col2 + cor0.col1 AS col1 FROM tab0 AS cor0
----
113
1403
614

query I rowsort
SELECT ALL cor0.col0 * + col2 * col0 FROM tab0 AS cor0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( col1 ) + 43 * col2 col0 FROM tab0 AS cor0
----
-54
1333
3435

query I rowsort
SELECT DISTINCT 42 * + col1 + col0 AS col2 FROM tab1 AS cor0
----
1095
484
626

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5193
SELECT ALL + + col2 * - col0 - CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5193
SELECT ALL + + col2 * - col0 - CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + ( + col0 ) + 92 FROM tab1 AS cor0
----
156
172
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( cor0.col1 ) col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL col0 + + col2 + + col0 * - 79 AS col0 FROM tab0 cor0
----
-1839
-2729
-6860

query I rowsort
SELECT DISTINCT col2 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( col1 ) - - col2 col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL - + col0 + + col1 + 28 FROM tab1 AS cor0
----
-26
-39
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5200
SELECT + col2 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5200
SELECT + col2 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5201
SELECT ALL col1 DIV - col1 AS col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5201
SELECT ALL col1 / - col1 AS col0 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT ALL - col2 * + tab1.col2 * 21 FROM tab1
----
-193536
-61236
-68229

query I rowsort
SELECT DISTINCT - + col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - ( col2 ) * col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT col2 - + col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL - col1 * col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ( - col1 ) * col0 * col2 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT + col1 + + col2 * - 53 AS col1 FROM tab0 AS cor0
----
-1663
-4255
44

query I rowsort
SELECT + cor0.col1 - - col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - col2 * - cor0.col0 + 55 * col2 FROM tab2 AS cor0
----
1674
3458
5092

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5211
SELECT - ( col2 ) * + CAST( - col0 AS SIGNED ) + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

skipif mysql # not compatible
query I rowsort label-5211
SELECT - ( col2 ) * + CAST ( - col0 AS INTEGER ) + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL + cor0.col1 + - 62 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to e235e995e240cd4345b31120f7fb9c73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5213
SELECT ALL - CAST( NULL AS SIGNED ) col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5213
SELECT ALL - CAST ( NULL AS INTEGER ) col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + - col2 * + ( cor0.col0 * - col2 ) FROM tab2 AS cor0
----
114114
5130
52754

onlyif mysql # use DIV operator for integer division
query I rowsort label-5215
SELECT DISTINCT + 83 DIV tab2.col0 AS col2 FROM tab2
----
1
11

skipif mysql # not compatible
query I rowsort label-5215
SELECT DISTINCT + 83 / tab2.col0 AS col2 FROM tab2
----
1
11

query I rowsort
SELECT ALL col2 * - col0 * col0 AS col0 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT + col2 - col2 * + cor0.col0 * - ( col1 ) FROM tab1 AS cor0
----
36537
4266
99936

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5218
SELECT - + ( + col0 ) * CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5218
SELECT - + ( + col0 ) * CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 87 * - col1 + col0 FROM tab2 AS cor0
----
-1400
-2690
-5055

query I rowsort
SELECT DISTINCT tab0.col0 * col1 * + ( 20 ) + + col0 FROM tab0
----
162069
41304
67935

query I rowsort
SELECT - 0 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - - ( - 8 ) + + col2 FROM tab2 AS cor0
----
18
19
30

query I rowsort
SELECT ALL - tab2.col2 * 60 FROM tab2
----
-1560
-1620
-2280

query I rowsort
SELECT - - col1 * cor0.col2 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT DISTINCT 7 * tab0.col1 AS col2 FROM tab0
----
602
637
679

query I rowsort
SELECT + 97 * + col1 FROM tab0 AS cor0
----
8342
8827
9409

query I rowsort
SELECT tab1.col0 - + ( - col1 ) AS col2 FROM tab1
----
29
74
93

query I rowsort
SELECT - col1 * - col1 * col2 AS col2 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT - - 13 * - col2 FROM tab1 AS cor0
----
-1248
-702
-741

query I rowsort
SELECT DISTINCT ( 21 ) FROM tab1 AS cor0
----
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-5231
SELECT - col2 DIV ( - cor0.col0 ) FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5231
SELECT - col2 / ( - cor0.col0 ) FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT DISTINCT ( ( + col1 ) ) + + col2 * - col2 + - col2 FROM tab1 AS cor0
----
-2944
-3296
-9299

onlyif mysql # use DIV operator for integer division
query I rowsort label-5233
SELECT ALL - - cor0.col2 DIV - col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-5233
SELECT ALL - - cor0.col2 / - col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT + - 21 * + col0 FROM tab0 AS cor0
----
-1869
-504
-735

query I rowsort
SELECT ALL - + ( 83 ) FROM tab1 AS cor0
----
-83
-83
-83

query I rowsort
SELECT ALL ( - ( + tab1.col2 ) ) AS col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL + col0 + col0 AS col0 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT 24 * + col0 FROM tab1 AS cor0
----
1536
1920
72

query I rowsort
SELECT DISTINCT - col2 * - col1 * col0 AS col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL col0 + + col2 * 34 * 82 AS col0 FROM tab2 AS cor0
----
106023
72566
75283

query I rowsort
SELECT ALL - 20 AS col2 FROM tab1 AS cor0
----
-20
-20
-20

query I rowsort
SELECT ALL + 22 * - col1 FROM tab1 AS cor0
----
-220
-286
-572

query I rowsort
SELECT + 53 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

query I rowsort
SELECT ALL col1 + - col1 * col1 AS col1 FROM tab0
----
-7310
-8190
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-5245
SELECT ALL col2 * - col1 * 85 + col0 DIV col0 AS col1 FROM tab0 cor0
----
-241229
-634269
-8244

skipif mysql # not compatible
query I rowsort label-5245
SELECT ALL col2 * - col1 * 85 + col0 / col0 AS col1 FROM tab0 cor0
----
-241229
-634269
-8244

query I rowsort
SELECT + cor0.col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0 WHERE ( NULL ) < NULL
----

query I rowsort
SELECT ALL - 92 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT + col1 * - col1 + col0 * + col1 FROM tab0 AS cor0
----
-182
-5332
-6014

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5250
SELECT + - col1 * - CAST( NULL AS SIGNED ) + 1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5250
SELECT + - col1 * - CAST ( NULL AS INTEGER ) + 1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 - + col0 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5252
SELECT DISTINCT + cor0.col0 DIV 90 + + col1 - - cor0.col0 AS col0 FROM tab2 cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-5252
SELECT DISTINCT + cor0.col0 / 90 + + col1 - - cor0.col0 AS col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT col1 + + col0 + col2 * - col0 FROM tab1 AS cor0
----
-133
-3574
-7587

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5254
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + - ( - col2 ) col1 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5254
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + - ( - col2 ) col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT + ( - 68 ) * - col1 FROM tab1 AS cor0
----
1768
680
884

query I rowsort
SELECT ALL 78 AS col1 FROM tab0 AS cor0
----
78
78
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5257
SELECT DISTINCT CAST( - 93 AS SIGNED ) * col1 + + col2 FROM tab1 AS cor0
----
-1113
-2364
-873

skipif mysql # not compatible
query I rowsort label-5257
SELECT DISTINCT CAST ( - 93 AS INTEGER ) * col1 + + col2 FROM tab1 AS cor0
----
-1113
-2364
-873

query I rowsort
SELECT DISTINCT - ( - 21 ) * + col0 + + 15 * 59 * col2 FROM tab1 AS cor0
----
47853
51789
86640

query I rowsort
SELECT DISTINCT - + 95 * + col2 + cor0.col1 AS col1 FROM tab0 cor0
----
-3049
-7699
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5260
SELECT ALL - col0 * 57 + col0 DIV cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
-1335
-1959
-4990

skipif mysql # not compatible
query I rowsort label-5260
SELECT ALL - col0 * 57 + col0 / cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
-1335
-1959
-4990

onlyif mysql # use DIV operator for integer division
query I rowsort label-5261
SELECT ALL + + 99 DIV 2 AS col1 FROM tab2 AS cor0
----
49
49
49

skipif mysql # not compatible
query I rowsort label-5261
SELECT ALL + + 99 / 2 AS col1 FROM tab2 AS cor0
----
49
49
49

query I rowsort
SELECT 34 FROM tab2, tab2 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT ALL col0 + - col2 + col1 AS col2 FROM tab2
----
11
111
58

query I rowsort
SELECT ALL tab0.col2 + - col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT 46 + 3 AS col2 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to e587c122dea39a2488ff88b884cea462

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5266
SELECT + col1 / - CAST( NULL AS DECIMAL ) + col2 * tab1.col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5266
SELECT + col1 / - CAST ( NULL AS REAL ) + col2 * tab1.col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + tab0.col0 * + col1 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT - col0 * col1 / col0 + + cor0.col0 FROM tab1 AS cor0 WHERE NULL NOT IN ( + col1 / + cor0.col1 )
----

query III rowsort
SELECT * FROM tab2 cor0 WHERE NOT - col0 + - cor0.col0 NOT BETWEEN col0 AND col1 + col1 * + col0
----

query III rowsort
SELECT * FROM tab0 cor0 WHERE NULL NOT IN ( cor0.col1 * + col1 )
----

query I rowsort
SELECT ALL col0 + col1 + col2 * + cor0.col0 * + col2 FROM tab2 AS cor0
----
114172
5141
52865

query I rowsort
SELECT ALL - cor0.col2 + - col1 * + col2 + + col1 AS col2 FROM tab0 AS cor0
----
-1
-2785
-7453

query I rowsort
SELECT ALL col2 * col2 + col0 FROM tab0
----
1113
36
6813

query III rowsort
SELECT ALL * FROM tab1 WHERE + col0 NOT IN ( - col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col2 * col2 + col2 * col1 FROM tab0
----
14186
3927
98

query I rowsort
SELECT DISTINCT cor0.col2 + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL col1 * col1 * col2 + col0 AS col0 FROM tab0 cor0
----
244092
679131
9444

query I rowsort
SELECT cor0.col1 - - col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col1 * col2 + - col1 * col1 * col0 FROM tab0 AS cor0
----
-174666
-329218
-729547

query I rowsort
SELECT ALL + col0 + cor0.col2 * col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT col0 * + col2 + + col2 * col0 FROM tab2 AS cor0
----
378
4056
6004

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab2, tab0 cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - col1 * col1 col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT + col2 AS col2 FROM tab0 WHERE NOT NULL IN ( + col2 )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL NOT IN ( tab1.col1 )
----

query I rowsort
SELECT ALL + col0 * tab2.col1 + col2 AS col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT col2 FROM tab1 WHERE NOT ( + col1 ) IN ( - col0 )
----
54
57
96

query I rowsort
SELECT ALL col0 * col2 * col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT col1 * + tab1.col0 * + col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT + col0 + + col0 + - col2 * - col2 * col1 AS col0 FROM tab2
----
22613
24706
40040

query I rowsort
SELECT ALL + col2 + + col1 / + col0 AS col0 FROM tab1 WHERE NOT NULL IN ( + col2 )
----

query I rowsort
SELECT DISTINCT + col2 * tab0.col2 * col2 + col2 * + col2 * - col0 AS col2 FROM tab0
----
-34
-47068
9801

query III rowsort
SELECT * FROM tab2 WHERE NOT - col1 + - col2 IN ( tab2.col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL col0 * - tab1.col1 + tab1.col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL col2 * tab0.col2 + + col1 FROM tab0
----
1175
6815
98

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT IN ( col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col0 * + col2 col0 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT ALL + + col1 * - col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - cor0.col0 + - col0 * - col1 * - col2 AS col0 FROM tab1 AS cor0
----
-36544
-4215
-99920

onlyif mysql # use DIV operator for integer division
query I rowsort label-5301
SELECT DISTINCT + col2 + + cor0.col1 DIV - col1 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-5301
SELECT DISTINCT + col2 + + cor0.col1 / - col1 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT DISTINCT - col1 + - col2 * - col1 * col2 AS col1 FROM tab2 AS cor0
----
22568
24531
39825

query I rowsort
SELECT + + col0 + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT col1 * - col1 * col0 FROM tab2 cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT + + col1 + - cor0.col2 * col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + cor0.col1 + + col0 * col0 AS col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT col0 - col0 * + col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT + tab0.col0 + col0 - + col2 * col0 FROM tab0
----
-7120
-744
35

query I rowsort
SELECT ALL col1 * - tab2.col2 - col1 FROM tab2
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-5310
SELECT DISTINCT - col2 DIV + col0 + col1 AS col0 FROM tab2 AS cor0
----
17
28
59

skipif mysql # not compatible
query I rowsort label-5310
SELECT DISTINCT - col2 / + col0 + col1 AS col0 FROM tab2 AS cor0
----
17
28
59

query I rowsort
SELECT ALL - col1 * + col2 - - col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL - - col2 + col2 * col0 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT ALL col1 FROM tab2 WHERE ( NULL ) >= NULL
----

query I rowsort
SELECT + col2 * col0 + - col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT + cor0.col1 * + 77 FROM tab1 AS cor0
----
1001
2002
770

query I rowsort
SELECT DISTINCT - 17 * col0 FROM tab2
----
-119
-1326
-1343

query I rowsort
SELECT + col1 * col1 + cor0.col0 AS col1 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT - - col1 + 49 * + col0 FROM tab2 cor0
----
374
3881
3888

query I rowsort
SELECT + + col1 * - 72 - - 60 FROM tab1 AS cor0
----
-1812
-660
-876

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col1 + col1 col2 FROM tab1 WHERE - col0 BETWEEN ( col1 + col1 * col0 ) AND NULL
----

query I rowsort
SELECT ALL col1 - col2 * col1 AS col1 FROM tab1
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - + col2 col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL - col1 + col1 * - tab2.col1 / + col2 AS col2 FROM tab2 WHERE col0 >= NULL
----

query I rowsort
SELECT col0 * + col2 + - col0 AS col0 FROM tab0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * tab2.col2 * col2 + col1 * col0 col2 FROM tab2
----
-112733
-48126
-4886

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 * - col0 - col2 * col2 col2 FROM tab1
----
-2889
258895
502784

query I rowsort
SELECT DISTINCT - 23 * - col0 AS col0 FROM tab1 AS cor0
----
1472
1840
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 * + col2 + - col0 + - col1 col2 FROM tab0 cor0
----
-167
-7478
-902

onlyif mysql # use DIV operator for integer division
query I rowsort label-5329
SELECT + - 76 DIV col0 FROM tab1 AS cor0
----
-1
-25
0

skipif mysql # not compatible
query I rowsort label-5329
SELECT + - 76 / col0 FROM tab1 AS cor0
----
-1
-25
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5330
SELECT ( + col1 ) DIV + col1 AS col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5330
SELECT ( + col1 ) / + col1 AS col1 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5331
SELECT CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5331
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5332
SELECT + - cor0.col0 DIV tab2.col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to f68cbae6f5f15db1e8be3f408d59006e

skipif mysql # not compatible
query I rowsort label-5332
SELECT + - cor0.col0 / tab2.col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to f68cbae6f5f15db1e8be3f408d59006e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col1 / col0 + - col1 col1 FROM tab2 WHERE NOT ( NULL ) NOT IN ( col0 )
----

query I rowsort
SELECT - col2 + - col1 + + tab0.col1 AS col0 FROM tab0
----
-1
-33
-82

query III rowsort
SELECT ALL * FROM tab2 WHERE ( col2 ) BETWEEN NULL AND NULL
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5336
SELECT DISTINCT + col1 + + CAST( + 10 AS SIGNED ) * col2 AS col1 FROM tab1 cor0
----
566
580
973

skipif mysql # not compatible
query I rowsort label-5336
SELECT DISTINCT + col1 + + CAST ( + 10 AS INTEGER ) * col2 AS col1 FROM tab1 cor0
----
566
580
973

query I rowsort
SELECT DISTINCT - cor0.col0 + 98 AS col1 FROM tab1, tab1 AS cor0
----
18
34
95

query I rowsort
SELECT cor0.col2 * 29 FROM tab2 AS cor0
----
1102
754
783

query I rowsort
SELECT DISTINCT + col0 + - col2 * col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT 84 FROM tab1 cor0 CROSS JOIN tab0 cor1
----
84

query I rowsort
SELECT ALL - cor0.col0 * cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to b1a10d0ce1bd78a97a3f25900325a81f

query I rowsort
SELECT ALL + 11 * - 12 + + col1 FROM tab1 AS cor0
----
-106
-119
-122

query I rowsort
SELECT ALL + + cor0.col1 * - col2 + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT col1 * - col1 + ( - tab0.col0 + + col1 ) * + col0 AS col2 FROM tab0
----
-5908
-7239
-8103

query I rowsort
SELECT ALL - col2 + + col1 * col0 AS col0 FROM tab2 AS cor0
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - ( col2 ) * - col0 + - 16 FROM tab2 AS cor0
----
173
2012
2986

query I rowsort
SELECT ( + 60 ) AS col0 FROM tab2
----
60
60
60

query I rowsort
SELECT DISTINCT + col1 + col1 * - col0 FROM tab2
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5350
SELECT ALL - 7 + col2 + - CAST( + 57 AS SIGNED ) * - col0 AS col2 FROM tab1
----
218
3698
4649

skipif mysql # not compatible
query I rowsort label-5350
SELECT ALL - 7 + col2 + - CAST ( + 57 AS INTEGER ) * - col0 AS col2 FROM tab1
----
218
3698
4649

onlyif mysql # use DIV operator for integer division
query I rowsort label-5351
SELECT ALL col1 DIV col0 + + ( + col0 ) AS col0 FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-5351
SELECT ALL col1 / col0 + + ( + col0 ) AS col0 FROM tab0
----
27
37
90

query I rowsort
SELECT DISTINCT - - cor0.col0 * col0 + cor0.col0 * col2 AS col1 FROM tab1 AS cor0
----
14080
171
7744

query I rowsort
SELECT DISTINCT - col1 + + col0 AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT 78 * col2 + - col0 + - col0 FROM tab1 AS cor0
----
4206
4318
7328

query I rowsort
SELECT + col1 * col2 * + tab0.col2 + + col1 FROM tab0
----
194
611975
93740

query I rowsort
SELECT + cor0.col0 * col2 * col2 AS col1 FROM tab1 AS cor0
----
207936
737280
8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-5357
SELECT DISTINCT - col0 DIV cor0.col0 AS col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5357
SELECT DISTINCT - col0 / cor0.col0 AS col2 FROM tab1 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5358
SELECT + col1 DIV col1 col2 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5358
SELECT + col1 / col1 col2 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5359
SELECT + col2 DIV + cor0.col2 + + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5359
SELECT + col2 / + cor0.col2 + + col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT ALL + cor0.col1 + col1 + + col1 AS col1 FROM tab2 AS cor0
----
177
51
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5361
SELECT DISTINCT + + col2 - col0 DIV col0 AS col0 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-5361
SELECT DISTINCT + + col2 - col0 / col0 AS col0 FROM tab1 AS cor0
----
53
56
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT + tab0.col0 + + tab0.col0 - tab0.col1 AS col0 FROM tab0
----
-27
-38
87

query I rowsort
SELECT tab1.col0 - - 90 AS col0 FROM tab1
----
154
170
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5365
SELECT CAST( NULL AS SIGNED ) / col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5365
SELECT CAST ( NULL AS INTEGER ) / col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 86 + - col1 AS col2 FROM tab1
----
60
73
76

query I rowsort
SELECT ( col2 + col1 ) AS col1 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT col2 + 50 - col2 AS col2 FROM tab1
----
50

query I rowsort
SELECT ALL + 40 - col1 * + col1 AS col2 FROM tab1
----
-129
-60
-636

onlyif mysql # use DIV operator for integer division
query I rowsort label-5370
SELECT + col1 DIV - tab0.col1 AS col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5370
SELECT + col1 / - tab0.col1 AS col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - 16 * + col1 - - col1 FROM tab2
----
-255
-465
-885

query I rowsort
SELECT - - 17 + - 26 AS col2 FROM tab1 AS cor0
----
-9
-9
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5373
SELECT + CAST( NULL AS SIGNED ) + - 81 * + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5373
SELECT + CAST ( NULL AS INTEGER ) + - 81 * + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) * - col2 + col0 AS col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - 69 + + 45 FROM tab1 AS cor0
----
-24
-24
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + col1 col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - - 13 * col2 + cor0.col0 AS col2 FROM tab2 AS cor0
----
358
416
573

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * col1 col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - 54 + col0 * col1 FROM tab1 AS cor0
----
24
586
986

query I rowsort
SELECT + 49 * - col0 + + col2 FROM tab1 cor0
----
-3079
-3824
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5381
SELECT + col2 DIV col0 AS col2 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5381
SELECT + col2 / col0 AS col2 FROM tab1 cor0
----
0
1
18

query I rowsort
SELECT DISTINCT col1 * - col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT + cor0.col0 * - col0 * - col1 FROM tab0 AS cor0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-5384
SELECT DISTINCT tab2.col2 DIV + col1 FROM tab2
----
0
2

skipif mysql # not compatible
query I rowsort label-5384
SELECT DISTINCT tab2.col2 / + col1 FROM tab2
----
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5385
SELECT ALL col0 DIV col0 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5385
SELECT ALL col0 / col0 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL - ( - col2 * col1 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col0 * + col1 + - col2 AS col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT - 50 * col2 AS col2 FROM tab0 AS cor0
----
-1650
-4100
-50

query I rowsort
SELECT tab0.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT col2 + + col1 - + 77 FROM tab0 AS cor0
----
21
42
96

query I rowsort
SELECT ALL + - 97 AS col2 FROM tab2 AS cor0
----
-97
-97
-97

query I rowsort
SELECT 96 * - col1 AS col1 FROM tab1 AS cor0
----
-1248
-2496
-960

query I rowsort
SELECT cor1.col2 AS col0 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT DISTINCT + 67 AS col1 FROM tab2, tab2 AS cor0
----
67

query I rowsort
SELECT ALL - - 99 + col0 FROM tab0 AS cor0
----
123
134
188

query I rowsort
SELECT DISTINCT 8 + - col0 FROM tab1 AS cor0
----
-56
-72
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5397
SELECT ALL + CAST( NULL AS SIGNED ) / + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5397
SELECT ALL + CAST ( NULL AS INTEGER ) / + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 58 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT ALL - 87 AS col2 FROM tab0
----
-87
-87
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5400
SELECT col0 * col1 + CAST( 66 AS SIGNED ) col0 FROM tab2 AS cor0
----
1409
283
4668

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5400
SELECT col0 * col1 + CAST ( 66 AS INTEGER ) col0 FROM tab2 AS cor0
----
1409
283
4668

query I rowsort
SELECT + 72 + col1 * + 95 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
1649
2990
5651

onlyif mysql # use DIV operator for integer division
query I rowsort label-5402
SELECT ALL col1 DIV - col2 + - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5402
SELECT ALL col1 / - col2 + - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col1 * col0 - - 61 FROM tab1 AS cor0
----
1101
139
701

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5404
SELECT ALL - col2 + CAST( NULL AS SIGNED ) * - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5404
SELECT ALL - col2 + CAST ( NULL AS INTEGER ) * - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 + + ( - 59 + + col2 ) AS col0 FROM tab2 AS cor0
----
-5
-7
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-5406
SELECT DISTINCT - + col0 * ( ( col1 ) ) DIV col1 + cor0.col0 * col2 FROM tab1 AS cor0
----
159
3584
7600

skipif mysql # not compatible
query I rowsort label-5406
SELECT DISTINCT - + col0 * ( ( col1 ) ) / col1 + cor0.col0 * col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT + col0 * + col1 + col0 + - col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL cor1.col0 AS col2 FROM tab1, tab1 cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5409
SELECT DISTINCT + col0 * + CAST( ( col2 ) AS SIGNED ) FROM tab0 cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-5409
SELECT DISTINCT + col0 * + CAST ( ( col2 ) AS INTEGER ) FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5410
SELECT DISTINCT col1 * + ( + col1 * col2 ) + + CAST( col1 + - col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
244121
679051
9505

skipif mysql # not compatible
query I rowsort label-5410
SELECT DISTINCT col1 * + ( + col1 * col2 ) + + CAST ( col1 + - col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
244121
679051
9505

query I rowsort
SELECT + col0 + 68 AS col0 FROM tab2 AS cor0
----
146
147
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-5412
SELECT ALL - + col1 + + col2 DIV - ( col1 + col1 ) FROM tab1 AS cor0
----
-12
-16
-27

skipif mysql # not compatible
query I rowsort label-5412
SELECT ALL - + col1 + + col2 / - ( col1 + col1 ) FROM tab1 AS cor0
----
-12
-16
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5413
SELECT DISTINCT + col0 * 86 + 25 - col1 DIV col2 FROM tab1 AS cor0
----
283
5529
6905

skipif mysql # not compatible
query I rowsort label-5413
SELECT DISTINCT + col0 * 86 + 25 - col1 / col2 FROM tab1 AS cor0
----
283
5529
6905

query I rowsort
SELECT - col0 * - ( ( + col2 ) ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5415
SELECT DISTINCT - col2 DIV + col2 + col2 * cor0.col1 DIV - col1 AS col1 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-5415
SELECT DISTINCT - col2 / + col2 + col2 * cor0.col1 / - col1 AS col1 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT DISTINCT - cor0.col2 + 56 * - col0 AS col2 FROM tab1 AS cor0
----
-222
-3641
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-5417
SELECT + - 84 + col2 DIV + col1 AS col0 FROM tab2 AS cor0
----
-82
-84
-84

skipif mysql # not compatible
query I rowsort label-5417
SELECT + - 84 + col2 / + col1 AS col0 FROM tab2 AS cor0
----
-82
-84
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5418
SELECT - - CAST( NULL AS SIGNED ) / col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5418
SELECT - - CAST ( NULL AS INTEGER ) / col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 35 * col2 AS col1 FROM tab2 AS cor0
----
1330
910
945

query I rowsort
SELECT ALL - 78 * - col1 AS col1 FROM tab2 AS cor0
----
1326
2418
4602

query I rowsort
SELECT ALL - + col2 * 40 * col1 FROM tab0 cor0
----
-113520
-298480
-3880

query I rowsort
SELECT DISTINCT + 10 FROM tab1 AS cor0
----
10

query I rowsort
SELECT ALL + 81 * + col2 FROM tab1 AS cor0
----
4374
4617
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5424
SELECT ALL CAST( NULL AS SIGNED ) + + col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5424
SELECT ALL CAST ( NULL AS INTEGER ) + + col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 83 * 21 AS col2 FROM tab2 cor0
----
-1743

onlyif mysql # use DIV operator for integer division
query I rowsort label-5426
SELECT col1 DIV col2 AS col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5426
SELECT col1 / col2 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - 43 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

query I rowsort
SELECT ALL col0 * + col0 + + ( col2 ) AS col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT + 74 FROM tab1, tab1 AS cor0
----
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-5430
SELECT DISTINCT 68 DIV + col1 AS col2 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-5430
SELECT DISTINCT 68 / + col1 AS col2 FROM tab2
----
1
2
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5431
SELECT ALL tab0.col0 DIV - 93 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5431
SELECT ALL tab0.col0 / - 93 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT 13 FROM tab1, tab0 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT ALL - cor0.col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT - col2 + col2 * ( ( col0 ) ) FROM tab2
----
162
2002
2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5435
SELECT + col0 * + CAST( NULL AS DECIMAL ) + col0 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5435
SELECT + col0 * + CAST ( NULL AS REAL ) + col0 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * col2 + + 44 * col2 AS col1 FROM tab0 AS cor0
----
10332
2541
45

query I rowsort
SELECT DISTINCT 58 - 94 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
-36

query I rowsort
SELECT ALL 37 + + tab2.col0 + + col1 AS col1 FROM tab2
----
133
174
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-5439
SELECT col0 + - col1 DIV ( - ( col0 ) ) + 6 AS col1 FROM tab0
----
33
43
96

skipif mysql # not compatible
query I rowsort label-5439
SELECT col0 + - col1 / ( - ( col0 ) ) + 6 AS col1 FROM tab0
----
33
43
96

query I rowsort
SELECT ALL - 30 + - tab0.col0 * + tab0.col0 + tab0.col0 FROM tab0
----
-1220
-582
-7862

query I rowsort
SELECT 86 AS col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT ALL + 25 + + tab1.col1 AS col0 FROM tab1
----
35
38
51

query I rowsort
SELECT 30 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT col0 + - ( + col0 ) FROM tab1
----
0
0
0

query I rowsort
SELECT ALL cor0.col0 + col0 AS col2 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT + col0 * col0 + col2 * - cor0.col2 AS col0 FROM tab0 cor0
----
-513
1197
1224

onlyif mysql # use DIV operator for integer division
query I rowsort label-5447
SELECT col2 * + col1 + - tab2.col1 DIV 69 col0 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5447
SELECT col2 * + col1 + - tab2.col1 / 69 col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT col0 + col0 + col1 * + col2 FROM tab1
----
1408
1410
698

query I rowsort
SELECT DISTINCT + col0 * tab1.col2 * col2 AS col2 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT DISTINCT col2 * + col0 * 85 FROM tab2
----
16065
172380
255170

query I rowsort
SELECT col0 + + cor0.col2 + + col0 FROM tab2 AS cor0
----
182
196
41

query I rowsort
SELECT ALL 86 + - col0 + + 75 AS col2 FROM tab1
----
158
81
97

query I rowsort
SELECT + + 32 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT - col1 * 71 AS col0 FROM tab0 AS cor0
----
-6106
-6461
-6887

query I rowsort
SELECT ALL - + cor0.col2 * col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT col1 * + col0 * + col0 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT ALL - col0 + ( cor0.col1 ) FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT - col0 * - ( - col1 ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col0 + + 43 * col1 FROM tab2 cor0
----
1340
2615
810

query I rowsort
SELECT DISTINCT col1 * 25 AS col1 FROM tab0 AS cor0
----
2150
2275
2425

query I rowsort
SELECT ALL col2 + 48 FROM tab0 AS cor0
----
130
49
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5462
SELECT - + col0 * CAST( NULL AS SIGNED ) * 58 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5462
SELECT - + col0 * CAST ( NULL AS INTEGER ) * 58 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col0 * + 35 FROM tab1 AS cor0
----
105
2240
2800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5464
SELECT ALL + + CAST( 34 AS SIGNED ) * + col1 * ( col0 ) - col1 * ( 14 ) FROM tab0 AS cor0
----
114072
274092
68972

skipif mysql # not compatible
query I rowsort label-5464
SELECT ALL + + CAST ( 34 AS INTEGER ) * + col1 * ( col0 ) - col1 * ( 14 ) FROM tab0 AS cor0
----
114072
274092
68972

query I rowsort
SELECT - - col0 * 65 + + col2 AS col0 FROM tab1 AS cor0
----
249
4217
5296

query I rowsort
SELECT ALL - - 84 FROM tab0 cor0
----
84
84
84

query I rowsort
SELECT - 49 - - col0 * col1 AS col2 FROM tab1 AS cor0
----
29
591
991

query I rowsort
SELECT DISTINCT + 63 FROM tab2 cor0
----
63

query I rowsort
SELECT + col2 + + col2 * cor0.col1 AS col0 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT + col2 + + 39 AS col2 FROM tab0 AS cor0
----
121
40
72

query I rowsort
SELECT cor0.col0 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT + 72 + col0 * 48 FROM tab1 AS cor0
----
216
3144
3912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 25 + col2 col2 FROM tab1 AS cor0
----
29
32
71

query I rowsort
SELECT DISTINCT + + 69 AS col0 FROM tab0 AS cor0
----
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT - + col1 + col1 AS col1 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5477
SELECT - 4 * + col2 + ( col1 ) + - col2 * + CAST( NULL AS DECIMAL ) 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-5477
SELECT - 4 * + col2 + ( col1 ) + - col2 * + CAST ( NULL AS REAL ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5478
SELECT ALL - cor0.col2 * + col2 + - CAST( 93 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-1182
-6817
-94

skipif mysql # not compatible
query I rowsort label-5478
SELECT ALL - cor0.col2 * + col2 + - CAST ( 93 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-1182
-6817
-94

query I rowsort
SELECT - ( - cor0.col2 ) * + col2 + + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL col2 - col1 * 82 AS col2 FROM tab1 AS cor0
----
-2078
-763
-970

onlyif mysql # use DIV operator for integer division
query I rowsort label-5481
SELECT ALL - 68 + - cor0.col1 DIV - cor0.col1 + + 50 AS col2 FROM tab0 AS cor0
----
-17
-17
-17

skipif mysql # not compatible
query I rowsort label-5481
SELECT ALL - 68 + - cor0.col1 / - cor0.col1 + + 50 AS col2 FROM tab0 AS cor0
----
-17
-17
-17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5482
SELECT DISTINCT 53 * - cor0.col0 + - CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5482
SELECT DISTINCT 53 * - cor0.col0 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5483
SELECT + + col1 * + cor0.col2 + - CAST( + col1 + + col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-35
2728
7282

skipif mysql # not compatible
query I rowsort label-5483
SELECT + + col1 * + cor0.col2 + - CAST ( + col1 + + col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-35
2728
7282

query I rowsort
SELECT 84 * + col0 + - 23 AS col2 FROM tab0 AS cor0
----
1993
2917
7453

onlyif mysql # use DIV operator for integer division
query I rowsort label-5485
SELECT - col2 + col2 DIV col1 FROM tab1 cor0
----
-52
-52
-89

skipif mysql # not compatible
query I rowsort label-5485
SELECT - col2 + col2 / col1 FROM tab1 cor0
----
-52
-52
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5486
SELECT DISTINCT col1 DIV col0 + 41 col1 FROM tab2 cor0
----
41
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5486
SELECT DISTINCT col1 / col0 + 41 col1 FROM tab2 cor0
----
41
45

query I rowsort
SELECT ALL - 37 + + col1 FROM tab0 AS cor0
----
49
54
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-5488
SELECT DISTINCT cor0.col1 DIV col1 + - CAST( + col1 AS SIGNED ) + col2 col2 FROM tab1 AS cor0
----
29
48
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5488
SELECT DISTINCT cor0.col1 / col1 + - CAST ( + col1 AS INTEGER ) + col2 col2 FROM tab1 AS cor0
----
29
48
84

query I rowsort
SELECT ALL - 73 AS col2 FROM tab1 AS cor0
----
-73
-73
-73

query I rowsort
SELECT DISTINCT + col0 * + col1 * ( + col1 * col2 ) + col1 + cor0.col1 * col2 * + col0 FROM tab2 cor0
----
187519
7179179
918629

query I rowsort
SELECT - 62 + tab0.col0 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 70b0fb814f72d66e674ffa047e743c10

query I rowsort
SELECT ALL + 28 * 22 FROM tab1
----
616
616
616

query I rowsort
SELECT ALL 31 - - tab1.col1 AS col0 FROM tab1
----
41
44
57

query I rowsort
SELECT + - col1 * + col2 + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + + ( + cor0.col2 ) + 91 + - col1 FROM tab1 AS cor0
----
119
138
174

query I rowsort
SELECT col2 * - col1 - col2 * + 10 * + col2 FROM tab1 cor0
----
-30564
-33060
-93408

query I rowsort
SELECT DISTINCT 6 - - col0 AS col1 FROM tab0 AS cor0
----
30
41
95

query I rowsort
SELECT - col0 * col0 + - 24 + + col0 * cor0.col0 * - col0 AS col1 FROM tab0 cor0
----
-14424
-44124
-712914

query I rowsort
SELECT DISTINCT + col2 + - col2 * - col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT - tab2.col1 * - col0 + - col0 FROM tab2
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5501
SELECT + CAST( NULL AS SIGNED ) + cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5501
SELECT + CAST ( NULL AS INTEGER ) + cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 95 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT ALL - ( col0 ) * col0 AS col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT - - col0 * + 90 + - col2 AS col0 FROM tab2 AS cor0
----
603
6994
7072

query I rowsort
SELECT 61 * - col1 * col1 AS col1 FROM tab1 AS cor0
----
-10309
-41236
-6100

query I rowsort
SELECT DISTINCT + 12 + + col1 FROM tab0 AS cor0
----
103
109
98

query I rowsort
SELECT + 33 + 20 FROM tab2, tab0 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 74 ) col2 FROM tab0, tab1 AS cor0
----
74

query I rowsort
SELECT DISTINCT col0 * tab1.col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL + cor0.col0 AS col1 FROM tab2 cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5511
SELECT - tab0.col1 DIV + col1 + col1 + - tab0.col2 * + col2 * + col0 FROM tab0
----
-26051
-598346
61

skipif mysql # not compatible
query I rowsort label-5511
SELECT - tab0.col1 / + col1 + col1 + - tab0.col2 * + col2 * + col0 FROM tab0
----
-26051
-598346
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-5512
SELECT col2 DIV - col0 + col2 AS col0 FROM tab2
----
24
26
38

skipif mysql # not compatible
query I rowsort label-5512
SELECT col2 / - col0 + col2 AS col0 FROM tab2
----
24
26
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5513
SELECT 89 DIV - col0 FROM tab2
----
-1
-1
-12

skipif mysql # not compatible
query I rowsort label-5513
SELECT 89 / - col0 FROM tab2
----
-1
-1
-12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5514
SELECT - CAST( NULL AS SIGNED ) / 4 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5514
SELECT - CAST ( NULL AS INTEGER ) / 4 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * tab1.col0 + col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT col1 * + 86 + col2 AS col2 FROM tab0
----
7429
7908
8343

query I rowsort
SELECT DISTINCT + tab1.col1 - + tab1.col2 AS col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT col0 * - col0 - + col0 FROM tab0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT + col2 + - 65 AS col0 FROM tab1
----
-11
-8
31

query I rowsort
SELECT ALL - cor0.col2 * cor0.col2 * - cor0.col2 + ( - cor0.col1 ) FROM tab2 AS cor0
----
17517
19652
54855

query I rowsort
SELECT - col0 * + col2 + - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + 64 * col2 + + tab1.col0 col1 FROM tab1
----
186627
208000
589904

query I rowsort
SELECT - - 82 * col2 + - col0 * col1 + col1 AS col1 FROM tab0 AS cor0
----
-1284
-3216
728

query I rowsort
SELECT ALL - - 41 * - 96 AS col0 FROM tab2 AS cor0
----
-3936
-3936
-3936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 42 * col2 col1 FROM tab1 AS cor0
----
-2268
-2394
-4032

query I rowsort
SELECT + + col0 * 9 + col2 FROM tab0 AS cor0
----
249
316
883

query I rowsort
SELECT 81 AS col1 FROM tab2
----
81
81
81

query I rowsort
SELECT DISTINCT + col0 * - 51 * 83 AS col2 FROM tab2
----
-29631
-330174
-334407

query I rowsort
SELECT ALL - 37 + + 16 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + 16 * + 40 + col1 FROM tab0
----
726
731
737

query I rowsort
SELECT DISTINCT 29 * - 3 + - col1 FROM tab0
----
-173
-178
-184

query I rowsort
SELECT - ( col0 ) * - col0 - + 60 AS col1 FROM tab2
----
-11
6024
6181

query I rowsort
SELECT DISTINCT 19 FROM tab2, tab0 AS cor0
----
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-5535
SELECT DISTINCT col0 DIV 64 col0 FROM tab2 AS cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5535
SELECT DISTINCT col0 / 64 col0 FROM tab2 AS cor0
----
0
1

query I rowsort
SELECT 32 * cor0.col2 * 34 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to a25c3245f987796225685d66cc6f22e9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 90 + col1 * + col2 col0 FROM tab2 AS cor0
----
-1593
-2774
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5538
SELECT DISTINCT - - col1 DIV - col1 FROM tab2 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5538
SELECT DISTINCT - - col1 / - col1 FROM tab2 cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5539
SELECT - 37 + - cor0.col0 * - 56 + col1 DIV - cor0.col2 AS col1 FROM tab1 cor0
----
131
3547
4443

skipif mysql # not compatible
query I rowsort label-5539
SELECT - 37 + - cor0.col0 * - 56 + col1 / - cor0.col2 AS col1 FROM tab1 cor0
----
131
3547
4443

query I rowsort
SELECT ALL - col1 + - col1 * ( 20 * col1 ) FROM tab2 AS cor0
----
-19251
-5797
-69679

query I rowsort
SELECT + col0 * - cor0.col1 + + col2 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-5542
SELECT - + ( - cor0.col1 ) DIV + 22 AS col2 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5542
SELECT - + ( - cor0.col1 ) / + 22 AS col2 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT + cor0.col1 * col0 + + 92 AS col1 FROM tab0 AS cor0
----
2156
3487
8191

query I rowsort
SELECT DISTINCT 91 * col1 AS col2 FROM tab2 cor0
----
1547
2821
5369

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col2 * 58 col2 FROM tab0 AS cor0
----
2030
423284
45936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 45 * - cor0.col2 col2 FROM tab2 AS cor0
----
1170
1215
1710

query I rowsort
SELECT - 33 * col1 AS col0 FROM tab1 AS cor0
----
-330
-429
-858

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT col2 + cor0.col0 * col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + - cor0.col0 * - col0 + - ( 1 ) AS col2 FROM tab2 cor0
----
48
6083
6240

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5551
SELECT - col1 * col1 / CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5551
SELECT - col1 * col1 / CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 + cor0.col0 * - col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT + - 72 FROM tab0 AS cor0
----
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-5554
SELECT ALL - + col2 DIV col2 + - CAST( - 87 AS SIGNED ) DIV col1 AS col0 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5554
SELECT ALL - + col2 / col2 + - CAST ( - 87 AS INTEGER ) / col1 AS col0 FROM tab1 AS cor0
----
2
5
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5555
SELECT DISTINCT 98 DIV + col0 FROM tab0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-5555
SELECT DISTINCT 98 / + col0 FROM tab0
----
1
2
4

query I rowsort
SELECT - + 15 AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 91b10a00c89b36b5bf0bed723e656ccc

query I rowsort
SELECT ( tab0.col1 ) * col1 AS col1 FROM tab0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-5558
SELECT + col1 + col2 DIV col0 AS col0 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-5558
SELECT + col1 + col2 / col0 AS col0 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT - 14 * col0 * ( + 51 ) + + col1 AS col0 FROM tab0 AS cor0
----
-17050
-24893
-63455

query I rowsort
SELECT col2 * col2 + 30 * 73 AS col1 FROM tab1 AS cor0
----
11406
5106
5439

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5561
SELECT cor0.col1 * + CAST( NULL AS SIGNED ) + 13 * col2 + - cor0.col1 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5561
SELECT cor0.col1 * + CAST ( NULL AS INTEGER ) + 13 * col2 + - cor0.col1 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + - ( cor0.col0 ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - col1 + + 81 * + 31 * - col2 FROM tab1 AS cor0
----
-135620
-143137
-241069

query I rowsort
SELECT - ( col0 ) - - col1 * - col2 * - col1 FROM tab0 AS cor0
----
244044
678953
9374

query I rowsort
SELECT + - cor0.col0 + + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - 90 * - col0 FROM tab1 AS cor0
----
-270
-5760
-7200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 + 95 col1 FROM tab2 AS cor0
----
112
126
154

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 48 + + 27 col2 FROM tab2 AS cor0
----
75
75
75

query I rowsort
SELECT ALL col1 * - col0 + cor0.col1 FROM tab1 AS cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-5570
SELECT DISTINCT col2 - - col0 * col2 DIV - col1 AS col2 FROM tab2 AS cor0
----
-138
-8
21

skipif mysql # not compatible
query I rowsort label-5570
SELECT DISTINCT col2 - - col0 * col2 / - col1 AS col2 FROM tab2 AS cor0
----
-138
-8
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-5571
SELECT DISTINCT - 42 * col0 DIV - col2 FROM tab1 AS cor0
----
2
35
47

skipif mysql # not compatible
query I rowsort label-5571
SELECT DISTINCT - 42 * col0 / - col2 FROM tab1 AS cor0
----
2
35
47

query I rowsort
SELECT col2 * + col2 + + tab2.col2 * col2 FROM tab2
----
1352
1458
2888

query I rowsort
SELECT - - col2 - 85 FROM tab1 AS cor0
----
-28
-31
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-5574
SELECT + col1 DIV + col0 + - col0 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-5574
SELECT + col1 / + col0 + - col0 FROM tab1 AS cor0
----
-64
-80
5

query I rowsort
SELECT - 92 * col1 AS col1 FROM tab2
----
-1564
-2852
-5428

query I rowsort
SELECT DISTINCT - col0 + - tab2.col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT + col0 + col0 * ( col1 + - col1 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT 6 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
6

query I rowsort
SELECT DISTINCT - ( ( + col0 ) + col0 ) AS col0 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT + 1 AS col1 FROM tab1, tab1 cor0, tab0 cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT ALL - ( col2 ) + col0 * 91 AS col0 FROM tab0 cor0
----
2151
3184
8017

query I rowsort
SELECT + 66 + col1 FROM tab0 AS cor0
----
152
157
163

query I rowsort
SELECT 58 + 40 * + col0 AS col1 FROM tab0 AS cor0
----
1018
1458
3618

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * col0 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + 5 * - col1 * - cor0.col0 FROM tab2 AS cor0
----
1085
23010
6715

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT - col0 - 83 FROM tab1
----
-147
-163
-86

query I rowsort
SELECT - col2 * 35 + 10 FROM tab0
----
-1145
-25
-2860

query I rowsort
SELECT DISTINCT col1 + - 63 FROM tab1
----
-37
-50
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-5590
SELECT col2 DIV 24 + - 53 + + tab2.col1 FROM tab2
----
-21
-35
7

skipif mysql # not compatible
query I rowsort label-5590
SELECT col2 / 24 + - 53 + + tab2.col1 FROM tab2
----
-21
-35
7

query I rowsort
SELECT col1 * + ( - col2 ) * - col0 AS col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT - col0 * col0 - 90 FROM tab1
----
-4186
-6490
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 79 col0 FROM tab0
----
103
114
168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5594
SELECT CAST( NULL AS SIGNED ) + + col0 * tab2.col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5594
SELECT CAST ( NULL AS INTEGER ) + + col0 * tab2.col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 66 * - 24 AS col2 FROM tab2
----
-1584
-1584
-1584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5596
SELECT - CAST( NULL AS SIGNED ) * + col1 + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5596
SELECT - CAST ( NULL AS INTEGER ) * + col1 + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( + col1 ) * + col2 - - 29 * + col0 AS col2 FROM tab0 AS cor0
----
10043
1112
3534

query I rowsort
SELECT col2 * col0 + col0 FROM tab2 cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - cor0.col0 col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL - col2 * cor0.col0 - - col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + ( cor0.col0 ) * col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - 88 * + col2 AS col0 FROM tab0 cor0
----
-2904
-7216
-88

query I rowsort
SELECT - - 90 * col1 FROM tab2 AS cor0
----
1530
2790
5310

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5604
SELECT CAST( col2 AS SIGNED ) * col2 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-5604
SELECT CAST ( col2 AS INTEGER ) * col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-5605
SELECT - ( + col2 ) DIV col2 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5605
SELECT - ( + col2 ) / col2 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - cor1.col0 AS col2 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT col1 * - col0 + + ( + col1 ) * - col0 FROM tab2 AS cor0
----
-2686
-434
-9204

query I rowsort
SELECT - col2 * + col2 + - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-5609
SELECT - - col2 DIV - cor0.col2 + col2 + + cor0.col1 * col1 FROM tab0 cor0
----
7428
8362
9409

skipif mysql # not compatible
query I rowsort label-5609
SELECT - - col2 / - cor0.col2 + col2 + + cor0.col1 * col1 FROM tab0 cor0
----
7428
8362
9409

query I rowsort
SELECT DISTINCT + 30 AS col2 FROM tab1, tab2 cor0, tab2 AS cor1
----
30

query I rowsort
SELECT 48 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + 49 col2 FROM tab2 AS cor0
----
127
128
56

query I rowsort
SELECT col0 - cor0.col0 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * col0 + col0 AS col1 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5615
SELECT DISTINCT + + col1 + CAST( NULL AS SIGNED ) + + cor0.col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5615
SELECT DISTINCT + + col1 + CAST ( NULL AS INTEGER ) + + cor0.col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT - col2 - - cor0.col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + - col2 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT cor0.col0 + - cor0.col0 * - 10 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
231
384
897

query I rowsort
SELECT - cor0.col0 * ( - cor0.col2 + + col2 ) AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5620
SELECT ALL col0 * - CAST( NULL AS DECIMAL ) + col2 * col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5620
SELECT ALL col0 * - CAST ( NULL AS REAL ) + col2 * col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col1 + 64 * + cor0.col2 FROM tab0 AS cor0
----
161
2198
5339

query I rowsort
SELECT DISTINCT - col1 * col1 * - col1 + + col1 AS col2 FROM tab2 cor0
----
205438
29822
4930

query I rowsort
SELECT ALL + col2 * - cor0.col2 + col0 - - col1 FROM tab1 AS cor0
----
-2887
-3175
-9123

query I rowsort
SELECT ALL - col1 + ( col1 ) + col1 * - ( 88 ) * + col1 FROM tab2 AS cor0
----
-25432
-306328
-84568

query I rowsort
SELECT DISTINCT + ( 27 ) * col1 + 60 AS col0 FROM tab1 AS cor0
----
330
411
762

query I rowsort
SELECT col0 * 69 + - col2 * col1 FROM tab0 AS cor0
----
-1182
-1321
2318

query I rowsort
SELECT DISTINCT + + cor0.col2 * - col1 + col0 AS col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT + 10 * - 11 - col0 AS col1 FROM tab1 AS cor0
----
-113
-174
-190

query I rowsort
SELECT + - col2 + + 5 AS col0 FROM tab0 AS cor0
----
-28
-77
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5630
SELECT DISTINCT 24 / + col0 + cor0.col1 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5630
SELECT DISTINCT 24 / + col0 + cor0.col1 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL cor0.col0 * - 77 FROM tab2 AS cor0
----
-539
-6006
-6083

onlyif mysql # use DIV operator for integer division
query I rowsort label-5632
SELECT - + cor0.col0 * col1 DIV col0 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5632
SELECT - + cor0.col0 * col1 / col0 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5633
SELECT + col1 DIV + 65 col2 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5633
SELECT + col1 / + 65 col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + col1 - + 59 AS col0 FROM tab1
----
-33
-46
-49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5635
SELECT DISTINCT + 41 * - col0 - CAST( NULL AS SIGNED ) * + col0 * + col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5635
SELECT DISTINCT + 41 * - col0 - CAST ( NULL AS INTEGER ) * + col0 * + col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + cor0.col1 * - col0 - + 97 * col1 AS col1 FROM tab0 AS cor0
----
-10406
-12804
-16926

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5638
SELECT DISTINCT + 58 + col1 DIV col0 AS col1 FROM tab2 cor0
----
58
62

skipif mysql # not compatible
query I rowsort label-5638
SELECT DISTINCT + 58 + col1 / col0 AS col1 FROM tab2 cor0
----
58
62

query I rowsort
SELECT ALL 62 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5640
SELECT col0 DIV - col2 + col0 AS col2 FROM tab1
----
3
63
80

skipif mysql # not compatible
query I rowsort label-5640
SELECT col0 / - col2 + col0 AS col2 FROM tab1
----
3
63
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5641
SELECT ALL - col0 DIV + 1 + col2 + + col0 col2 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5641
SELECT ALL - col0 / + 1 + col2 + + col0 col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + 32 + - col2 AS col2 FROM tab0
----
-1
-50
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 + col2 * col0 col0 FROM tab1
----
14080
171
7744

onlyif mysql # use DIV operator for integer division
query I rowsort label-5644
SELECT col1 * col0 + 30 DIV + col1 FROM tab0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-5644
SELECT col1 * col0 + 30 / + col1 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col0 col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5647
SELECT ALL - col1 DIV - col1 + + cor0.col2 * col0 + - col2 AS col1 FROM tab2 cor0
----
163
2003
2965

skipif mysql # not compatible
query I rowsort label-5647
SELECT ALL - col1 / - col1 + + cor0.col2 * col0 + - col2 AS col1 FROM tab2 cor0
----
163
2003
2965

onlyif mysql # use DIV operator for integer division
query I rowsort label-5648
SELECT ALL + col1 DIV - col0 col2 FROM tab1
----
-8
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5648
SELECT ALL + col1 / - col0 col2 FROM tab1
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5649
SELECT col0 * col1 + col0 * col2 DIV + col2 col2 FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5649
SELECT col0 * col1 + col0 * col2 / + col2 col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT cor0.col2 + col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT col2 + + col1 + col2 AS col2 FROM tab0
----
152
255
99

query I rowsort
SELECT + col0 + + cor0.col2 + - col1 AS col0 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT col0 + - col1 * - cor0.col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT + cor0.col1 * - col2 + - col2 * + col0 * col0 AS col1 FROM tab1 AS cor0
----
-1890
-234042
-615648

onlyif mysql # use DIV operator for integer division
query I rowsort label-5655
SELECT - + col0 + col1 DIV col2 col0 FROM tab0 AS cor0
----
-22
-88
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5655
SELECT - + col0 + col1 / col2 col0 FROM tab0 AS cor0
----
-22
-88
62

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL BETWEEN + col1 AND col0 / - col2
----

query I rowsort
SELECT col2 * col2 * - col2 AS col1 FROM tab2 AS cor0
----
-17576
-19683
-54872

query I rowsort
SELECT ALL + col0 AS col2 FROM tab1 AS cor0 WHERE col1 = ( NULL )
----

query I rowsort
SELECT tab2.col2 + col2 AS col1 FROM tab2
----
52
54
76

query I rowsort
SELECT - + col0 - col1 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT col1 + - col2 + - col0 FROM tab0 AS cor0
----
-80
29
61

query I rowsort
SELECT + col1 * + col0 + cor0.col2 AS col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + + col0 * + col1 + + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + cor0.col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT 72 + col2 + col1 FROM tab1
----
139
152
181

query I rowsort
SELECT col0 + col1 + col2 AS col0 FROM tab2
----
134
163
65

query I rowsort
SELECT DISTINCT + + cor1.col1 AS col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
17
31
59

query I rowsort
SELECT ALL + + cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT - tab0.col2 + col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT col2 + + col2 + - col1 FROM tab2
----
-7
23
59

query I rowsort
SELECT ALL + col1 * col0 + tab1.col2 * tab1.col2 FROM tab1
----
10256
2994
3889

query I rowsort
SELECT col1 * col2 + + col0 AS col1 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL col2 + col1 * col1 AS col2 FROM tab1
----
157
265
730

query I rowsort
SELECT DISTINCT + col0 * + col2 * + col0 + col0 AS col2 FROM tab0
----
1260
19032
649611

query I rowsort
SELECT ALL col0 + col1 * col2 AS col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT DISTINCT + col2 + + col2 * col2 AS col0 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT DISTINCT + + col2 * col0 * col1 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - tab1.col0 col2 FROM tab1
----
1040
640
78

query III rowsort
SELECT ALL * FROM tab1 WHERE + col2 + - col1 IN ( - col2 * - col1 + col0 / col0 )
----

query I rowsort
SELECT - col1 * tab1.col2 + col0 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT col0 * col1 - + col1 FROM tab2 WHERE col0 IN ( - col0 )
----

query I rowsort
SELECT col0 * + col2 + - cor0.col0 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5683
SELECT - 87 * + cor0.col1 - - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5683
SELECT - 87 * + cor0.col1 - - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col1 - col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT DISTINCT - col2 * col1 + ( + col1 * col2 ) AS col0 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5686
SELECT col1 DIV col0 + col2 AS col0 FROM tab2
----
26
31
38

skipif mysql # not compatible
query I rowsort label-5686
SELECT col1 / col0 + col2 AS col0 FROM tab2
----
26
31
38

query I rowsort
SELECT DISTINCT + tab2.col2 - col0 AS col0 FROM tab2
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5688
SELECT tab1.col0 DIV col0 + + col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5688
SELECT tab1.col0 / col0 + + col0 FROM tab1
----
4
65
81

query I rowsort
SELECT - tab1.col1 - - col0 AS col0 FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT + tab2.col0 + + col1 FROM tab2
----
137
38
96

query I rowsort
SELECT col1 * col1 * - 17 + col0 FROM tab1
----
-11489
-1636
-2793

query I rowsort
SELECT col1 + - col1 * - col2 * - col0 FROM tab0
----
-3298
-664027
-68026

query I rowsort
SELECT + ( - tab1.col0 ) * col2 * - 15 FROM tab1
----
115200
2430
54720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 58 col1 FROM tab2
----
58

query I rowsort
SELECT DISTINCT + ( - 95 * tab0.col2 ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
-3135
-7790
-95

query I rowsort
SELECT - - cor0.col2 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT col0 * + col0 + ( + col2 + col0 * col0 ) AS col1 FROM tab1 AS cor0
----
12896
72
8249

query I rowsort
SELECT ALL + tab0.col1 + col0 FROM tab0 WHERE NOT ( NULL ) = NULL
----

query I rowsort
SELECT ALL col2 + - col0 * + tab0.col0 AS col0 FROM tab0
----
-1224
-543
-7839

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( col2 * col0 ) NOT IN ( col0 )
----
24
86
33
89
91
82

query I rowsort
SELECT ALL col2 + + tab0.col2 * col1 FROM tab0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col2 + tab0.col0 col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT + tab1.col0 + - col2 FROM tab1 WHERE NOT col0 * - col0 NOT BETWEEN NULL AND ( col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col1 FROM tab2, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + tab1.col1 + col0 AS col0 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5706
SELECT DISTINCT tab1.col0 * + col0 DIV + col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5706
SELECT DISTINCT tab1.col0 * + col0 / + col0 FROM tab1
----
3
64
80

query I rowsort
SELECT tab1.col1 - - col2 * tab1.col2 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT + col0 - + col1 * col0 AS col0 FROM tab1 WHERE NOT ( NULL ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL - tab1.col0 + col2 AS col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL 96 * col2 FROM tab0 AS cor0
----
3168
7872
96

query I rowsort
SELECT ALL + ( + col2 ) + + ( col2 + col0 * - cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-6032
-6165
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5712
SELECT ALL + col2 DIV cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5712
SELECT ALL + col2 / cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + col0 - - col1 AS col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-5714
SELECT - - cor0.col0 DIV + col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5714
SELECT - - cor0.col0 / + col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL - 85 * 95 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 3dfb6737fedbbdddc38c3ba99191cc27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5716
SELECT DISTINCT + col1 * col1 DIV cor0.col2 + col0 AS col2 FROM tab1 cor0
----
15
65
81

skipif mysql # not compatible
query I rowsort label-5716
SELECT DISTINCT + col1 * col1 / cor0.col2 + col0 AS col2 FROM tab1 cor0
----
15
65
81

query I rowsort
SELECT ALL + cor0.col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 19 col0 FROM tab0, tab2 AS cor0
----
-19

query I rowsort
SELECT + cor0.col1 + + col2 * - col1 FROM tab2 cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col1 * + col2 + col2 * + col0 col2 FROM tab1 AS cor0
----
23904
36666
9348

query I rowsort
SELECT ALL + 97 * cor0.col2 + + col2 FROM tab2 AS cor0
----
2548
2646
3724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 89 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT ALL col0 - col2 AS col2 FROM tab2
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5724
SELECT - cor0.col0 DIV - cor0.col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5724
SELECT - cor0.col0 / - cor0.col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT ALL + cor0.col0 * + col1 + + col2 * + col2 AS col0 FROM tab0 AS cor0
----
14823
3153
3396

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col1 col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5727
SELECT + cor0.col1 - - 28 DIV + col0 AS col0 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-5727
SELECT + cor0.col1 - - 28 / + col0 AS col0 FROM tab0 AS cor0
----
87
91
97

query I rowsort
SELECT ALL - col0 + 14 AS col0 FROM tab2 AS cor0
----
-64
-65
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5729
SELECT - col2 DIV + cor0.col2 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5729
SELECT - col2 / + cor0.col2 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + + 16 AS col0 FROM tab1, tab0, tab2 cor0
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT DISTINCT col1 * tab1.col0 * + col2 + col2 AS col0 FROM tab1
----
36537
4266
99936

query I rowsort
SELECT DISTINCT col0 * col1 + col0 AS col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT + 6 * - col0 AS col0 FROM tab1
----
-18
-384
-480

query I rowsort
SELECT DISTINCT - - ( col0 ) * col0 + 3 - col1 FROM tab2 AS cor0
----
21
6028
6227

query I rowsort
SELECT DISTINCT 4 + + col0 FROM tab0 AS cor0
----
28
39
93

query I rowsort
SELECT - col2 * 82 FROM tab1 AS cor0
----
-4428
-4674
-7872

onlyif mysql # use DIV operator for integer division
query I rowsort label-5737
SELECT ALL - cor0.col0 DIV - col0 + + col0 * col2 AS col1 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-5737
SELECT ALL - cor0.col0 / - col0 + + col0 * col2 AS col1 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT DISTINCT col1 - 97 * col0 AS col2 FROM tab1 AS cor0
----
-265
-6198
-7747

query I rowsort
SELECT DISTINCT - col1 + + 21 AS col1 FROM tab1 AS cor0
----
-5
11
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5740
SELECT DISTINCT - + 79 * 33 DIV col1 + - 85 DIV - cor0.col0 col2 FROM tab1 AS cor0
----
-199
-259
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5740
SELECT DISTINCT - + 79 * 33 / col1 + - 85 / - cor0.col0 col2 FROM tab1 AS cor0
----
-199
-259
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 99 - + col2 col0 FROM tab2 AS cor0
----
61
72
73

query I rowsort
SELECT + - 50 + 10 * col2 FROM tab1 AS cor0
----
490
520
910

query I rowsort
SELECT ALL - col0 * + col1 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT col2 * + ( tab1.col2 ) * + tab1.col1 FROM tab1
----
119808
32490
75816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5745
SELECT DISTINCT - col0 * - CAST( NULL AS SIGNED ) * col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5745
SELECT DISTINCT - col0 * - CAST ( NULL AS INTEGER ) * col0 FROM tab2
----
NULL

query I rowsort
SELECT - col0 * col1 - + col2 * 75 FROM tab1
----
-4128
-4915
-8240

query I rowsort
SELECT - ( col0 ) + col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT - - ( col1 ) + - col1 * + col0 AS col1 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT + col2 * + 76 AS col1 FROM tab1 AS cor0
----
4104
4332
7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-5750
SELECT col0 DIV col1 + col0 * - ( - 67 ) AS col0 FROM tab2
----
469
5227
5297

skipif mysql # not compatible
query I rowsort label-5750
SELECT col0 / col1 + col0 * - ( - 67 ) AS col0 FROM tab2
----
469
5227
5297

query I rowsort
SELECT 30 * + 57 FROM tab2 AS cor0
----
1710
1710
1710

query I rowsort
SELECT 17 * - col2 + col2 AS col0 FROM tab2
----
-416
-432
-608

query I rowsort
SELECT cor0.col0 + + col2 * + col2 AS col0 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5754
SELECT + CAST( - 85 AS SIGNED ) AS col1 FROM tab1
----
-85
-85
-85

skipif mysql # not compatible
query I rowsort label-5754
SELECT + CAST ( - 85 AS INTEGER ) AS col1 FROM tab1
----
-85
-85
-85

query I rowsort
SELECT 85 - tab0.col1 AS col2 FROM tab0
----
-1
-12
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - tab1.col1 ) col2 FROM tab1
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5757
SELECT - CAST( - 59 AS SIGNED ) FROM tab2
----
59
59
59

skipif mysql # not compatible
query I rowsort label-5757
SELECT - CAST ( - 59 AS INTEGER ) FROM tab2
----
59
59
59

query I rowsort
SELECT ALL col1 * - col2 * + col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL + col2 * ( cor0.col2 ) AS col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5760
SELECT CAST( - 92 AS SIGNED ) + + col2 FROM tab2
----
-54
-65
-66

skipif mysql # not compatible
query I rowsort label-5760
SELECT CAST ( - 92 AS INTEGER ) + + col2 FROM tab2
----
-54
-65
-66

query I rowsort
SELECT - 95 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT + col0 + - ( + col0 + col0 ) * - tab0.col1 FROM tab0
----
16287
4152
6825

query I rowsort
SELECT ALL ( 55 ) * + col0 FROM tab0
----
1320
1925
4895

query I rowsort
SELECT DISTINCT col2 - col1 * col0 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT - 8 * col1 FROM tab1 cor0
----
-104
-208
-80

query I rowsort
SELECT DISTINCT col2 * - col1 * col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-5767
SELECT ALL col2 * - col1 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5767
SELECT ALL col2 * - col1 / cor0.col1 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - 44 + + col2 * col1 AS col1 FROM tab1 AS cor0
----
1204
1360
526

onlyif mysql # use DIV operator for integer division
query I rowsort label-5769
SELECT DISTINCT - cor0.col2 + col2 DIV col0 AS col0 FROM tab1 AS cor0
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-5769
SELECT DISTINCT - cor0.col2 + col2 / col0 AS col0 FROM tab1 AS cor0
----
-36
-57
-95

query I rowsort
SELECT ALL - - col2 + cor0.col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - col2 + col0 * col2 FROM tab0 cor0
----
34
7216
759

query I rowsort
SELECT + - 64 * col2 AS col2 FROM tab0 AS cor0
----
-2112
-5248
-64

query I rowsort
SELECT - 30 * - col0 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT 13 + + col2 AS col0 FROM tab1 AS cor0
----
109
67
70

query I rowsort
SELECT ALL - col1 * - col2 * + col1 AS col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT col0 + 10 FROM tab0
----
34
45
99

query I rowsort
SELECT DISTINCT + - cor0.col0 * + 23 AS col2 FROM tab2 AS cor0
----
-161
-1794
-1817

onlyif mysql # use DIV operator for integer division
query I rowsort label-5778
SELECT DISTINCT col0 DIV ( + col2 ) - + col1 AS col2 FROM tab1 cor0
----
-13
-26
-9

skipif mysql # not compatible
query I rowsort label-5778
SELECT DISTINCT col0 / ( + col2 ) - + col1 AS col2 FROM tab1 cor0
----
-13
-26
-9

query I rowsort
SELECT + col2 + - 98 * - col1 AS col1 FROM tab2 AS cor0
----
1704
3065
5808

query I rowsort
SELECT ALL - col0 * + ( col2 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT cor0.col0 + - col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col2 * ( + col0 * col2 ) AS col1 FROM tab0 AS cor0
----
-26136
-35
-598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-5783
SELECT DISTINCT - col0 + - ( col2 ) DIV - col1 AS col0 FROM tab2 AS cor0
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-5783
SELECT DISTINCT - col0 + - ( col2 ) / - col1 AS col0 FROM tab2 AS cor0
----
-7
-77
-78

query I rowsort
SELECT ALL cor0.col1 * + col1 + col0 AS col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT - - col2 * 9 AS col0 FROM tab0 cor0
----
297
738
9

query I rowsort
SELECT ALL + ( - col0 ) * col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - ( + 13 ) + col2 FROM tab0 AS cor0
----
-12
20
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-5788
SELECT 33 DIV - col2 + - col2 FROM tab0 AS cor0
----
-34
-34
-82

skipif mysql # not compatible
query I rowsort label-5788
SELECT 33 / - col2 + - col2 FROM tab0 AS cor0
----
-34
-34
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5789
SELECT DISTINCT + cor0.col0 DIV + cor0.col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
1

skipif mysql # not compatible
query I rowsort label-5789
SELECT DISTINCT + cor0.col0 / + cor0.col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
1

query I rowsort
SELECT ALL + + 0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - 40 * - col2 FROM tab2 cor0
----
-1040
-1080
-1520

query I rowsort
SELECT 94 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT + col0 * col1 + + cor0.col0 + col2 * + cor0.col1 FROM tab2 AS cor0
----
1061
2068
6214

query I rowsort
SELECT ALL - col0 + ( - col2 + - col1 ) FROM tab0
----
-133
-143
-262

query I rowsort
SELECT cor0.col2 + + cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8733ba2dd568938e338b27ad757d3e3b

query I rowsort
SELECT tab1.col1 * - ( - ( tab1.col2 ) ) AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL cor0.col1 + ( cor0.col2 ) AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL - - col0 + - cor0.col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5799
SELECT ALL + - cor0.col1 * - CAST( NULL AS SIGNED ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5799
SELECT ALL + - cor0.col1 * - CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 * col1 + - 81 AS col1 FROM tab1 AS cor0
----
-181
-250
-757

query I rowsort
SELECT + col1 * col2 + + 96 * + col2 * cor0.col2 FROM tab2 AS cor0
----
139270
66430
70821

query I rowsort
SELECT DISTINCT + + col2 * col1 + - col0 AS col2 FROM tab1 cor0
----
1168
1401
506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5803
SELECT ALL - col1 + - cor0.col1 * col0 + col0 * col0 DIV 53 AS col0 FROM tab0 AS cor0
----
-2140
-3469
-8041

skipif mysql # not compatible
query I rowsort label-5803
SELECT ALL - col1 + - cor0.col1 * col0 + col0 * col0 / 53 AS col0 FROM tab0 AS cor0
----
-2140
-3469
-8041

onlyif mysql # use DIV operator for integer division
query I rowsort label-5804
SELECT col1 DIV 8 + + col1 * + cor0.col1 FROM tab0 AS cor0
----
7406
8292
9421

skipif mysql # not compatible
query I rowsort label-5804
SELECT col1 / 8 + + col1 * + cor0.col1 FROM tab0 AS cor0
----
7406
8292
9421

query I rowsort
SELECT + - 87 * col1 + - col1 FROM tab1 AS cor0
----
-1144
-2288
-880

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + CAST ( col2 AS REAL ) * cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0, tab2 cor1, tab1, tab1 AS cor2
----
3645 values hashing to 199388980dc5177ebebcfdbc0408ba02

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 41 * col1 col0 FROM tab2 AS cor0
----
-1271
-2419
-697

query I rowsort
SELECT DISTINCT - - col1 + col2 * 23 FROM tab1 AS cor0
----
1268
1321
2221

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + cor0.col2 col2 FROM tab1 AS cor0
----
0
0
0

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 cor0 CROSS JOIN tab2, tab2 cor1, tab2 cor2
----
3645 values hashing to f23c9ebf4a57b11b108cf933fe3c62aa

query I rowsort
SELECT + 55 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT - col1 + + col2 * + col0 * - tab2.col0 AS col0 FROM tab2
----
-1354
-158243
-237175

onlyif mysql # use DIV operator for integer division
query I rowsort label-5814
SELECT - - col1 DIV - 4 FROM tab2 AS cor0
----
-14
-4
-7

skipif mysql # not compatible
query I rowsort label-5814
SELECT - - col1 / - 4 FROM tab2 AS cor0
----
-14
-4
-7

query I rowsort
SELECT + col2 + - col0 * - col1 AS col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL + tab1.col0 * - col2 AS col0 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5817
SELECT col0 + - col2 DIV - 97 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5817
SELECT col0 + - col2 / - 97 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + 39 col0 FROM tab0 AS cor0
----
125
130
136

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab2 AS cor1, tab1 cor2
----
972 values hashing to 9364ef7545b07c67767dceb70f02c643

query I rowsort
SELECT - + cor0.col1 * + col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 84 * col2 * - col2 + - col2 col2 FROM tab1 AS cor0
----
-244998
-272973
-774240

query I rowsort
SELECT + 0 + col0 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - - 0 * cor0.col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL 40 FROM tab1, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT col1 * + col2 + + col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL + col1 * - col2 AS col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - col0 * 7 AS col1 FROM tab0
----
-168
-245
-623

query I rowsort
SELECT DISTINCT - 92 FROM tab1, tab1 AS cor0
----
-92

query I rowsort
SELECT 98 + cor0.col2 FROM tab0 AS cor0
----
131
180
99

query I rowsort
SELECT - 11 FROM tab1 cor0
----
-11
-11
-11

query I rowsort
SELECT - tab1.col0 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5832
SELECT + CAST( 62 AS SIGNED ) + col0 AS col2 FROM tab2
----
140
141
69

skipif mysql # not compatible
query I rowsort label-5832
SELECT + CAST ( 62 AS INTEGER ) + col0 AS col2 FROM tab2
----
140
141
69

query I rowsort
SELECT col1 * - ( - col2 ) AS col0 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 99 col2 FROM tab2
----
99
99
99

query I rowsort
SELECT - 65 + + col1 FROM tab0 AS cor0
----
21
26
32

query I rowsort
SELECT + - col1 * cor0.col1 * col1 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT 4 * + col0 FROM tab2 AS cor0
----
28
312
316

query I rowsort
SELECT col1 + col1 * 34 FROM tab0 AS cor0
----
3010
3185
3395

query I rowsort
SELECT - - 81 * col1 AS col2 FROM tab2 AS cor0
----
1377
2511
4779

query I rowsort
SELECT - tab0.col1 AS col1 FROM tab0, tab2, tab2 cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL col2 * 66 AS col2 FROM tab0
----
2178
5412
66

query I rowsort
SELECT ALL 69 * + col0 * - col2 AS col1 FROM tab2
----
-13041
-139932
-207138

query I rowsort
SELECT ALL + + 85 + - ( + col1 ) * col2 FROM tab2 AS cor0
----
-1449
-561
-752

query I rowsort
SELECT ALL col0 + - col1 * + col1 + 66 FROM tab0 AS cor0
----
-7306
-8126
-9308

query I rowsort
SELECT 42 * + 95 FROM tab1 AS cor0
----
3990
3990
3990

query I rowsort
SELECT + 91 + cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to aae7faa1d960eba037051845044ac278

query I rowsort
SELECT ALL + col0 + col2 * - col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT - 6 AS col0 FROM tab0 AS cor0
----
-6
-6
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5849
SELECT DISTINCT CAST( NULL AS DECIMAL ) * + col1 - - cor0.col2 * + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5849
SELECT DISTINCT CAST ( NULL AS REAL ) * + col1 - - cor0.col2 * + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL 74 FROM tab1 cor0
----
74
74
74

query I rowsort
SELECT DISTINCT + 76 * col1 AS col1 FROM tab2 AS cor0
----
1292
2356
4484

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col1 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + 85 + - col1 AS col0 FROM tab0 AS cor0
----
-1
-12
-6

query I rowsort
SELECT - col1 + - col1 - + cor0.col1 FROM tab1 AS cor0
----
-30
-39
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5855
SELECT ALL + - cor0.col2 DIV + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5855
SELECT ALL + - cor0.col2 / + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT 63 * - col1 FROM tab2 AS cor0
----
-1071
-1953
-3717

query I rowsort
SELECT ALL + + 30 AS col1 FROM tab1 AS cor0
----
30
30
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 50 col0 FROM tab2 AS cor0
----
50

query I rowsort
SELECT ALL - - 86 * - col2 AS col1 FROM tab1 AS cor0
----
-4644
-4902
-8256

query I rowsort
SELECT + + col2 + cor0.col1 - col1 * - col1 AS col2 FROM tab1 AS cor0
----
167
278
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-5861
SELECT DISTINCT + ( + col1 ) DIV + col1 AS col0 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5861
SELECT DISTINCT + ( + col1 ) / + col1 AS col0 FROM tab2 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 73 col2 FROM tab0 AS cor0
----
73

query I rowsort
SELECT - col1 + col1 + + col0 AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - + col0 * ( col1 ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - col2 + - cor0.col2 - col2 FROM tab1 AS cor0
----
-162
-171
-288

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5866
SELECT + col0 * CAST( NULL AS SIGNED ) + + col0 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5866
SELECT + col0 * CAST ( NULL AS INTEGER ) + + col0 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - cor0.col0 + + col2 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + + col0 * - col1 + + cor0.col1 FROM tab0 cor0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5869
SELECT ALL - col0 + CAST( NULL AS DECIMAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5869
SELECT ALL - col0 + CAST ( NULL AS REAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col0 - + col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + col2 + 25 AS col1 FROM tab1 AS cor0
----
121
79
82

query I rowsort
SELECT + 81 * - 39 FROM tab1 AS cor0
----
-3159
-3159
-3159

query I rowsort
SELECT DISTINCT col1 + ( tab2.col1 ) FROM tab2
----
118
34
62

query I rowsort
SELECT col2 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + ( col0 ) + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL 93 + col0 FROM tab1 AS cor0
----
157
173
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5877
SELECT ALL + 19 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-5877
SELECT ALL + 19 / - col1 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 * col0 - col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + col1 * - ( + col1 ) FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - ( col0 ) + col1 AS col0 FROM tab1 cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-5881
SELECT DISTINCT - col0 + col1 DIV - col1 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-5881
SELECT DISTINCT - col0 + col1 / - col1 FROM tab1 AS cor0
----
-4
-65
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5882
SELECT + ( col2 ) * + col0 + CAST( 69 AS SIGNED ) * col2 FROM tab0 AS cor0
----
104
12956
3069

skipif mysql # not compatible
query I rowsort label-5882
SELECT + ( col2 ) * + col0 + CAST ( 69 AS INTEGER ) * col2 FROM tab0 AS cor0
----
104
12956
3069

query I rowsort
SELECT ALL col0 * col2 * col2 + - col2 * + col0 * col0 FROM tab1 AS cor0
----
-25536
122880
8262

query I rowsort
SELECT DISTINCT - 13 - col1 * - col2 AS col1 FROM tab0 cor0
----
2825
7449
84

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) + cor0.col2 AS col0 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5886
SELECT DISTINCT col2 + - col1 DIV 57 AS col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5886
SELECT DISTINCT col2 + - col1 / 57 AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT ALL + col1 + 79 * 84 AS col2 FROM tab2
----
6653
6667
6695

query I rowsort
SELECT - col1 * - ( - 22 ) + - col2 * tab1.col2 AS col1 FROM tab1
----
-3469
-3488
-9502

query I rowsort
SELECT + col0 * + ( + col1 ) FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - tab1.col1 + col1 + + tab1.col0 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT col0 + + col1 + - col0 FROM tab2
----
17
31
59

query I rowsort
SELECT col0 * ( col2 + tab0.col2 ) AS col2 FROM tab0
----
14596
1584
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5893
SELECT col1 DIV + col0 + tab0.col1 FROM tab0
----
89
92
99

skipif mysql # not compatible
query I rowsort label-5893
SELECT col1 / + col0 + tab0.col1 FROM tab0
----
89
92
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( - 81 ) + col1 col2 FROM tab1 AS cor0
----
107
91
94

query I rowsort
SELECT ALL 25 * - 69 + col0 + col0 * - col0 FROM tab0 AS cor0
----
-2277
-2915
-9557

onlyif mysql # use DIV operator for integer division
query I rowsort label-5896
SELECT 2 + + 91 DIV col2 FROM tab1
----
2
3
3

skipif mysql # not compatible
query I rowsort label-5896
SELECT 2 + + 91 / col2 FROM tab1
----
2
3
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5897
SELECT ALL - ( col1 ) * + col0 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5897
SELECT ALL - ( col1 ) * + col0 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * col0 + + col2 AS col1 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT col0 * - tab0.col2 + col2 * - col1 - + tab0.col2 AS col0 FROM tab0
----
-133
-14842
-3663

query I rowsort
SELECT cor0.col0 * - col1 - col0 AS col2 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT - 6 AS col0 FROM tab2 cor0
----
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5902
SELECT DISTINCT - col0 + CAST( cor0.col2 AS SIGNED ) * cor0.col2 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

skipif mysql # not compatible
query I rowsort label-5902
SELECT DISTINCT - col0 + CAST ( cor0.col2 AS INTEGER ) * cor0.col2 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT + - col2 + ( 37 ) AS col1 FROM tab2 AS cor0
----
-1
10
11

query I rowsort
SELECT + col2 * 14 + 22 FROM tab0 AS cor0
----
1170
36
484

query I rowsort
SELECT ALL tab0.col0 + ( col1 ) * col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL - cor0.col2 * 28 + - col0 AS col1 FROM tab2 AS cor0
----
-1143
-763
-806

query I rowsort
SELECT DISTINCT col0 + - 19 + col0 FROM tab2 AS cor0
----
-5
137
139

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5908
SELECT DISTINCT - col1 * + CAST( - col2 AS SIGNED ) col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5908
SELECT DISTINCT - col1 * + CAST ( - col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + col2 * - 72 * - col1 col1 FROM tab1 AS cor0
----
101142
41097
89952

query I rowsort
SELECT ALL + col2 - - 61 * col2 * + col1 FROM tab0 AS cor0
----
173151
455264
5918

query IIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0 WHERE NOT NULL <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + ( + 15 ) col1 FROM tab2 AS cor0
----
-105
-1170
-1185

query I rowsort
SELECT - + col1 * + 54 + - col1 + col0 * + col0 FROM tab0 cor0
----
-4110
-4154
2916

query I rowsort
SELECT DISTINCT 53 AS col2 FROM tab0
----
53

query I rowsort
SELECT + 68 * col0 FROM tab1 AS cor0
----
204
4352
5440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5916
SELECT DISTINCT - CAST( + 67 AS SIGNED ) * + col0 FROM tab1
----
-201
-4288
-5360

skipif mysql # not compatible
query I rowsort label-5916
SELECT DISTINCT - CAST ( + 67 AS INTEGER ) * + col0 FROM tab1
----
-201
-4288
-5360

query I rowsort
SELECT + col0 * tab0.col1 + tab0.col0 AS col1 FROM tab0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 9 col2 FROM tab1
----
9
9
9

query I rowsort
SELECT col1 * col0 + - col2 FROM tab1
----
24
583
944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 55 col1 FROM tab2
----
55

query I rowsort
SELECT DISTINCT 66 * + col2 * + col0 FROM tab0
----
2310
481668
52272

query I rowsort
SELECT DISTINCT - 22 AS col2 FROM tab2
----
-22

query I rowsort
SELECT DISTINCT + 22 AS col0 FROM tab1
----
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-5924
SELECT - 62 * + col0 + - col2 * col1 DIV col0 FROM tab1 AS cor0
----
-3976
-4975
-654

skipif mysql # not compatible
query I rowsort label-5924
SELECT - 62 * + col0 + - col2 * col1 / col0 FROM tab1 AS cor0
----
-3976
-4975
-654

query I rowsort
SELECT col2 * - col0 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + + ( + col2 ) * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - 81 - col1 * + 7 * - col1 FROM tab2 AS cor0
----
1942
24286
6646

query I rowsort
SELECT ALL - 17 + col0 FROM tab1 cor0
----
-14
47
63

query I rowsort
SELECT + col2 * - col2 - - col1 * 16 AS col1 FROM tab2 AS cor0
----
-1172
-233
268

query I rowsort
SELECT + 96 * col1 + - col2 FROM tab2 cor0
----
1594
2949
5638

query I rowsort
SELECT col2 + col2 * col2 FROM tab0
----
1122
2
6806

query I rowsort
SELECT DISTINCT + 77 FROM tab1, tab1 AS cor0, tab2, tab1 AS cor1
----
77

query I rowsort
SELECT ALL + cor0.col0 + 18 * col1 * cor0.col1 FROM tab2 AS cor0
----
17305
5281
62736

query I rowsort
SELECT DISTINCT + col1 * + ( 55 ) + cor0.col0 AS col1 FROM tab1 AS cor0
----
1433
614
795

query I rowsort
SELECT - col1 + - ( cor0.col2 * col0 + + col1 ) AS col1 FROM tab1 AS cor0
----
-214
-3668
-7706

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - col2 * + col1 * col2 col0 FROM tab0 cor0
----
-611793
-93568
0

query I rowsort
SELECT + - col0 * 6 * + cor0.col0 FROM tab2 cor0
----
-294
-36504
-37446

query I rowsort
SELECT ALL - cor0.col2 * - 70 FROM tab1 AS cor0
----
3780
3990
6720

query I rowsort
SELECT DISTINCT col2 + - col1 * - 80 FROM tab0 AS cor0
----
6913
7362
7761

onlyif mysql # use DIV operator for integer division
query I rowsort label-5940
SELECT ALL + col0 DIV - col0 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5940
SELECT ALL + col0 / - col0 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - 73 * + 47 - col2 AS col1 FROM tab1 AS cor0
----
-3485
-3488
-3527

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5942
SELECT CAST( NULL AS SIGNED ) * col2 * - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5942
SELECT CAST ( NULL AS INTEGER ) * col2 * - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * col2 * + tab2.col2 FROM tab2
----
17576
19683
54872

onlyif mysql # use DIV operator for integer division
query I rowsort label-5944
SELECT DISTINCT + + 60 + - col0 DIV col2 FROM tab0 AS cor0
----
25
59
60

skipif mysql # not compatible
query I rowsort label-5944
SELECT DISTINCT + + 60 + - col0 / col2 FROM tab0 AS cor0
----
25
59
60

query I rowsort
SELECT - ( 92 ) FROM tab0 AS cor0
----
-92
-92
-92

query I rowsort
SELECT ALL + 34 + + 4 * + cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to a8d4db102474a675f5d73a5c0098e02c

query I rowsort
SELECT 39 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT cor0.col2 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT col0 + col0 + - col1 AS col0 FROM tab0 AS cor0
----
-27
-38
87

query I rowsort
SELECT col0 * col0 - + col2 * 64 FROM tab0
----
-1536
1161
2673

query I rowsort
SELECT - ( 38 ) + - col0 * col0 AS col2 FROM tab0 AS cor0
----
-1263
-614
-7959

query I rowsort
SELECT - - ( cor0.col1 ) + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT 73 * col0 AS col1 FROM tab0 AS cor0
----
1752
2555
6497

onlyif mysql # use DIV operator for integer division
query I rowsort label-5954
SELECT - col0 DIV 95 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5954
SELECT - col0 / 95 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5955
SELECT + - col2 DIV - col0 + + col1 AS col2 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-5955
SELECT + - col2 / - col0 + + col1 AS col2 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT + + col1 * + col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5958
SELECT col2 * - ( + col2 ) + col1 + CAST( + col2 + col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-6469
-937
98

skipif mysql # not compatible
query I rowsort label-5958
SELECT col2 * - ( + col2 ) + col1 + CAST ( + col2 + col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-6469
-937
98

skipif mysql # not compatible
query I rowsort
SELECT + col0 - - CAST ( - 40 + - col1 AS REAL ) AS col0 FROM tab1 AS cor0
----
-63
14
27

query I rowsort
SELECT + col1 * 17 + cor0.col1 AS col0 FROM tab2 cor0
----
1062
306
558

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5961
SELECT ALL CAST( NULL AS DECIMAL ) FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5961
SELECT ALL CAST ( NULL AS REAL ) FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - - ( col1 ) * - col0 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 33 AS col2 FROM tab0 AS cor0
----
-33
-33
-33

query I rowsort
SELECT - + col0 + - col1 + - col2 AS col1 FROM tab2 AS cor0
----
-134
-163
-65

query I rowsort
SELECT ( - cor0.col0 + - tab0.col1 ) FROM tab0, tab2 AS cor0
----
9 values hashing to 4a88a96a89d4ececac205d3e45cfb39d

query I rowsort
SELECT + - tab1.col1 FROM tab0, tab2, tab0 AS cor0, tab1
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT DISTINCT - col1 * ( + ( + col2 ) ) FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT 99 * col2 FROM tab0
----
3267
8118
99

query I rowsort
SELECT - col0 * - 33 FROM tab1 AS cor0
----
2112
2640
99

query I rowsort
SELECT DISTINCT - - cor0.col0 FROM tab0, tab2, tab0 cor0
----
24
35
89

query I rowsort
SELECT + col0 + 2 AS col2 FROM tab1 AS cor0
----
5
66
82

query I rowsort
SELECT DISTINCT col1 * - 8 FROM tab2 AS cor0
----
-136
-248
-472

query I rowsort
SELECT ALL + col1 + + 42 FROM tab2 cor0
----
101
59
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 - col2 * - col2 * - ( + col0 + + cor0.col1 ) col2 FROM tab1 cor0
----
-241066
-84642
-858128

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5975
SELECT ALL - - col0 / + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5975
SELECT ALL - - col0 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 92 + - col1 * col1 + col0 * ( col1 + + 90 ) * + tab1.col1 AS col1 FROM tab1
----
107043
63992
8464

query I rowsort
SELECT + ( col2 ) * col1 - + col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT tab0.col0 + + col0 * col1 - - tab0.col2 AS col1 FROM tab0
----
2121
3431
8270

query I rowsort
SELECT 52 + col2 + + tab0.col0 AS col0 FROM tab0
----
109
223
88

query I rowsort
SELECT DISTINCT - col1 + col1 * col1 + ( 63 ) AS col1 FROM tab0
----
7373
8253
9375

query I rowsort
SELECT ALL + ( col0 * col2 ) - col0 * - col1 * tab1.col2 AS col0 FROM tab1
----
107520
40128
4374

query I rowsort
SELECT + ( col1 ) - + col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - 1 AS col0 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT - + col0 * - col2 + - col1 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-5985
SELECT + ( + col1 ) DIV + col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5985
SELECT + ( + col1 ) / + col0 AS col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT + 65 * - col1 FROM tab1 AS cor0
----
-1690
-650
-845

query I rowsort
SELECT ALL 82 * - col0 FROM tab1 AS cor0
----
-246
-5248
-6560

query I rowsort
SELECT ALL + + cor0.col1 * + col0 + col0 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + col1 col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - col1 * col1 + - col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT ALL - + 13 AS col1 FROM tab1 AS cor0
----
-13
-13
-13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col0 + + col0 col1 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5993
SELECT + cor0.col2 / + col0 + CAST( NULL AS SIGNED ) * col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5993
SELECT + cor0.col2 / + col0 + CAST ( NULL AS INTEGER ) * col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * - col1 + 27 * col2 FROM tab0 AS cor0
----
-6067
-6505
-9382

onlyif mysql # use DIV operator for integer division
query I rowsort label-5995
SELECT DISTINCT - 61 - - col1 * col1 DIV - col1 AS col2 FROM tab0 AS cor0
----
-147
-152
-158

skipif mysql # not compatible
query I rowsort label-5995
SELECT DISTINCT - 61 - - col1 * col1 / - col1 AS col2 FROM tab0 AS cor0
----
-147
-152
-158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5996
SELECT CAST( NULL AS DECIMAL ) * col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5996
SELECT CAST ( NULL AS REAL ) * col2 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( col0 ) * 74 AS col1 FROM tab1 cor0
----
222
4736
5920

query I rowsort
SELECT DISTINCT + + 68 + + cor0.col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
1602
714
905

query I rowsort
SELECT ALL 74 * col0 * col0 FROM tab1 AS cor0
----
303104
473600
666

onlyif mysql # use DIV operator for integer division
query I rowsort label-6000
SELECT DISTINCT - ( - cor0.col1 ) DIV cor0.col0 FROM tab1 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-6000
SELECT DISTINCT - ( - cor0.col1 ) / cor0.col0 FROM tab1 AS cor0
----
0
8

query I rowsort
SELECT ALL + + 84 AS col0 FROM tab0 AS cor0
----
84
84
84

query I rowsort
SELECT + tab1.col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6003
SELECT + col1 * - col0 + col2 * - ( cor0.col2 * CAST( col1 AS SIGNED ) ) AS col0 FROM tab0 AS cor0
----
-3492
-619983
-95718

skipif mysql # not compatible
query I rowsort label-6003
SELECT + col1 * - col0 + col2 * - ( cor0.col2 * CAST ( col1 AS INTEGER ) ) AS col0 FROM tab0 AS cor0
----
-3492
-619983
-95718

query I rowsort
SELECT DISTINCT - 80 FROM tab1
----
-80

query I rowsort
SELECT - cor0.col1 AS col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT 4 + - 25 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to cdcb40c9e1bb9a33ce9167a0d2bac0b1

query I rowsort
SELECT ALL - col2 * - col0 * + 18 FROM tab0
----
131364
14256
630

query I rowsort
SELECT ALL + col2 * - col0 + - ( - cor0.col2 ) FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6009
SELECT ALL 80 * - col0 + CAST( - col2 AS SIGNED ) col1 FROM tab0 AS cor0
----
-1953
-2801
-7202

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6009
SELECT ALL 80 * - col0 + CAST ( - col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
-1953
-2801
-7202

query I rowsort
SELECT - col1 - - cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 * + col0 + 36 FROM tab2 AS cor0
----
-1307
-181
-4566

query I rowsort
SELECT + - 1 + + col2 * + 15 AS col1 FROM tab0 AS cor0
----
1229
14
494

query I rowsort
SELECT + col2 * + col2 * col1 AS col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT ALL col0 + - tab2.col1 AS col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT tab0.col2 * tab0.col0 AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT + col0 * - col0 * ( + col2 ) FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT col1 * col0 + + ( + 23 ) * col2 AS col0 FROM tab2
----
2217
5200
838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + tab2.col0 col2 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT - col1 + col0 + 82 AS col2 FROM tab0
----
20
80

query I rowsort
SELECT col2 * - col1 + 86 * col0 FROM tab1
----
-1146
4934
5632

query I rowsort
SELECT ALL + + ( - col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 + col0 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col2 + cor0.col2 AS col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT - - col1 * + col0 - col2 * col1 AS col1 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT + + 26 AS col2 FROM tab2 AS cor0
----
26
26
26

query I rowsort
SELECT DISTINCT - col2 + 91 AS col0 FROM tab1 AS cor0
----
-5
34
37

query I rowsort
SELECT DISTINCT + col0 * col1 + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT + - col2 + - 80 * col2 FROM tab2 AS cor0
----
-2106
-2187
-3078

query I rowsort
SELECT ALL - + col2 * + col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + 95 * + 39 AS col2 FROM tab0 AS cor0
----
3705
3705
3705

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6031
SELECT ALL - ( cor0.col0 ) + - cor0.col2 * + CAST( NULL AS SIGNED ) * - col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6031
SELECT ALL - ( cor0.col0 ) + - cor0.col2 * + CAST ( NULL AS INTEGER ) * - col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( - col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + + col0 + col1 * col1 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6034
SELECT - CAST( 68 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-68
-68
-68

skipif mysql # not compatible
query I rowsort label-6034
SELECT - CAST ( 68 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-68
-68
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-6035
SELECT DISTINCT 56 DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-6035
SELECT DISTINCT 56 / cor0.col0 AS col1 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT ALL - col2 * - cor0.col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL tab2.col2 * - 40 * 32 AS col0 FROM tab2
----
-33280
-34560
-48640

onlyif mysql # use DIV operator for integer division
query I rowsort label-6038
SELECT ALL col2 DIV ( col2 ) - ( col1 ) FROM tab0 cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-6038
SELECT ALL col2 / ( col2 ) - ( col1 ) FROM tab0 cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT 87 * - col0 + col1 FROM tab1
----
-235
-5558
-6947

onlyif mysql # use DIV operator for integer division
query I rowsort label-6040
SELECT + ( ( + col2 ) ) DIV ( col2 ) FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6040
SELECT + ( ( + col2 ) ) / ( col2 ) FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6041
SELECT + - col0 * col1 + + 55 DIV - col1 FROM tab2 cor0
----
-1346
-218
-4602

skipif mysql # not compatible
query I rowsort label-6041
SELECT + - col0 * col1 + + 55 / - col1 FROM tab2 cor0
----
-1346
-218
-4602

query I rowsort
SELECT DISTINCT - ( + col0 ) + col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - col2 * 70 AS col0 FROM tab2 AS cor0
----
-1820
-1890
-2660

query I rowsort
SELECT DISTINCT col2 * - 30 - + col1 FROM tab0 AS cor0
----
-1076
-127
-2551

query I rowsort
SELECT DISTINCT + ( + ( col1 ) ) FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 53 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

query I rowsort
SELECT - - col0 * 74 AS col1 FROM tab2 AS cor0
----
518
5772
5846

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * tab2.col0 col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ( + cor0.col1 + tab0.col0 ) AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to dbf53c8d395fe624f70bcff710ecddf8

skipif mysql # not compatible
query I rowsort
SELECT ALL col1 * - CAST ( tab2.col0 AS REAL ) * + col0 AS col2 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT - 58 + + cor0.col2 FROM tab2, tab1 AS cor0
----
-1
-4
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6052
SELECT ALL - col1 DIV col0 + col1 FROM tab2 AS cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-6052
SELECT ALL - col1 / col0 + col1 FROM tab2 AS cor0
----
17
27
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6053
SELECT ALL + 45 DIV + 40 + - col0 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-6053
SELECT ALL + 45 / + 40 + - col0 FROM tab1
----
-2
-63
-79

query I rowsort
SELECT - + cor0.col0 * + 75 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 6b0b4fa9083f5c5555ea34a6c2b684d9

query I rowsort
SELECT + col0 * - col0 + col1 FROM tab0 cor0
----
-1128
-490
-7830

query I rowsort
SELECT - ( + ( col2 ) ) AS col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT 1 + ( + col1 ) FROM tab2
----
18
32
60

query I rowsort
SELECT cor0.col0 AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL + 89 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT ALL + 9 FROM tab2
----
9
9
9

query I rowsort
SELECT + - cor0.col1 * - col2 + 43 AS col2 FROM tab1 AS cor0
----
1291
1447
613

query I rowsort
SELECT - 12 + cor0.col2 * 7 FROM tab2 AS cor0
----
170
177
254

query I rowsort
SELECT ALL + - col2 - col0 FROM tab1 cor0
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col1 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + ( col0 ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT cor0.col1 * - cor0.col1 AS col2 FROM tab2, tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + col0 * - col0 + 80 + col0 AS col0 FROM tab2 cor0
----
-5926
-6082
38

query I rowsort
SELECT + 21 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col0 * 74 * col2 col2 FROM tab0 AS cor0
----
2687
540143
58694

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + ( col2 ) col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT DISTINCT col0 + col0 * 45 FROM tab0 AS cor0
----
1104
1610
4094

query I rowsort
SELECT col0 + col1 * col2 * + col2 AS col0 FROM tab0 AS cor0
----
132
611973
93678

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6073
SELECT DISTINCT - + col2 * CAST( NULL AS SIGNED ) * - col0 + col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6073
SELECT DISTINCT - + col2 * CAST ( NULL AS INTEGER ) * - col0 + col0 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - + col1 * col0 + - 30 * col1 AS col1 FROM tab0 AS cor0
----
-10829
-4644
-6305

query I rowsort
SELECT col0 * 11 * + col0 FROM tab1 AS cor0
----
45056
70400
99

query I rowsort
SELECT cor0.col1 + ( - 54 ) FROM tab2, tab2 cor0
----
9 values hashing to ea39948edbf9aeb4bcbafb4ee3e24051

query I rowsort
SELECT ALL 24 * + tab0.col2 FROM tab0
----
1968
24
792

query I rowsort
SELECT DISTINCT - 3 + cor0.col1 AS col1 FROM tab1, tab2 cor0
----
14
28
56

query I rowsort
SELECT + 78 AS col0 FROM tab2 cor0
----
78
78
78

query I rowsort
SELECT - ( cor0.col1 ) - - col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT - col2 + + col0 * 59 AS col2 FROM tab0 cor0
----
1383
2064
5169

query I rowsort
SELECT - col2 * - col0 * - ( 38 ) FROM tab2 AS cor0
----
-114076
-7182
-77064

query I rowsort
SELECT 9 * cor0.col0 * col0 AS col0 FROM tab2 AS cor0
----
441
54756
56169

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 85 col1 FROM tab1
----
85
85
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 50 col2 FROM tab0
----
1650
4100
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-6086
SELECT ALL - col1 - + col0 DIV + col0 AS col2 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-6086
SELECT ALL - col1 - + col0 / + col0 AS col2 FROM tab2 AS cor0
----
-18
-32
-60

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab1 cor1, tab0 AS cor2
----
972 values hashing to 9b91cf9fcc064ee1c13074a678b72ac7

query I rowsort
SELECT ALL 15 - - col1 AS col1 FROM tab1 AS cor0
----
25
28
41

query I rowsort
SELECT ALL + col0 * - 14 + cor0.col1 FROM tab2 AS cor0
----
-1033
-1089
-67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6090
SELECT - CAST( - col2 AS SIGNED ) * col2 * + col0 + ( col2 * col0 ) FROM tab2 AS cor0
----
117078
5292
54756

skipif mysql # not compatible
query I rowsort label-6090
SELECT - CAST ( - col2 AS INTEGER ) * col2 * + col0 + ( col2 * col0 ) FROM tab2 AS cor0
----
117078
5292
54756

query I rowsort
SELECT + + 46 + - 58 FROM tab2 AS cor0
----
-12
-12
-12

query I rowsort
SELECT DISTINCT - 0 + + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - col2 * + 70 AS col2 FROM tab2 AS cor0
----
-1820
-1890
-2660

query I rowsort
SELECT - 46 * col0 + cor0.col1 AS col0 FROM tab1 AS cor0
----
-112
-2934
-3667

query I rowsort
SELECT DISTINCT col2 * col0 + + col0 FROM tab1 cor0
----
165
3712
7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6096
SELECT ALL - col0 - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6096
SELECT ALL - col0 - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + + 29 * col0 AS col2 FROM tab1
----
113
1866
2333

query I rowsort
SELECT ALL - 71 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

query I rowsort
SELECT 51 + + 31 AS col0 FROM tab1
----
82
82
82

query I rowsort
SELECT DISTINCT tab1.col0 FROM tab1, tab0 cor0, tab1 AS cor1
----
3
64
80

query I rowsort
SELECT - 18 + ( col0 * col0 ) AS col1 FROM tab2
----
31
6066
6223

query I rowsort
SELECT - col2 - col2 AS col1 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT col0 + 91 AS col1 FROM tab2
----
169
170
98

query I rowsort
SELECT DISTINCT - col2 + + col0 FROM tab0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6105
SELECT - - CAST( - 66 AS SIGNED ) col1 FROM tab2 AS cor0
----
-66
-66
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6105
SELECT - - CAST ( - 66 AS INTEGER ) col1 FROM tab2 AS cor0
----
-66
-66
-66

query I rowsort
SELECT + 63 + 59 FROM tab1 AS cor0
----
122
122
122

query I rowsort
SELECT DISTINCT col2 * + col0 + + col0 - - cor0.col0 FROM tab2 AS cor0
----
203
2184
3160

query I rowsort
SELECT DISTINCT - 36 + 97 * tab1.col2 AS col0 FROM tab1
----
5202
5493
9276

query I rowsort
SELECT DISTINCT col1 - cor0.col2 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - col2 + - 81 AS col1 FROM tab1 AS cor0
----
-135
-138
-177

query I rowsort
SELECT DISTINCT + 65 FROM tab2
----
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-6112
SELECT + col0 DIV + cor0.col2 AS col2 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6112
SELECT + col0 / + cor0.col2 AS col2 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT + cor0.col1 * col2 + - col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT + ( + 37 ) FROM tab0, tab0 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT - - cor0.col1 * col1 + - 1 + + col2 AS col2 FROM tab1 cor0
----
156
264
729

query I rowsort
SELECT ALL - col2 * ( + col1 ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col0 - col1 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + col1 * ( + cor0.col1 ) FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL col2 * - 98 AS col2 FROM tab0 AS cor0
----
-3234
-8036
-98

query I rowsort
SELECT + col0 * - col0 + col0 + col2 FROM tab1 cor0
----
-3975
-6224
48

query I rowsort
SELECT - col0 * ( - col1 ) - col0 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + col2 + - col2 * col0 AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6123
SELECT cor0.col1 - - CAST( + col1 AS SIGNED ) FROM tab2 cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-6123
SELECT cor0.col1 - - CAST ( + col1 AS INTEGER ) FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ALL col0 * 37 * + 93 AS col2 FROM tab1 AS cor0
----
10323
220224
275280

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col1 col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT col0 + - tab2.col2 + + 57 FROM tab2
----
109
37
98

query I rowsort
SELECT 70 AS col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT DISTINCT 40 FROM tab2, tab1 AS cor0
----
40

query I rowsort
SELECT ALL + col0 + ( col0 ) * col0 AS col2 FROM tab1
----
12
4160
6480

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2, tab2 AS cor0, tab1 cor1
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

query I rowsort
SELECT DISTINCT - col2 + - col1 AS col2 FROM tab2
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6132
SELECT ALL tab2.col0 DIV + col0 col0 FROM tab2
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6132
SELECT ALL tab2.col0 / + col0 col0 FROM tab2
----
1
1
1

query I rowsort
SELECT - col1 * ( + col2 ) AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL cor0.col0 * + 30 AS col0 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT ALL + + cor0.col0 * - col2 * 55 AS col0 FROM tab0 AS cor0
----
-1925
-401390
-43560

query I rowsort
SELECT DISTINCT + col2 * 69 AS col1 FROM tab1 cor0
----
3726
3933
6624

query I rowsort
SELECT + col0 * col1 + - col0 FROM tab0 AS cor0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 82 col1 FROM tab1 AS cor0
----
-82
-82
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6139
SELECT ( ( col0 ) ) * ( 37 * col1 ) + CAST( + col2 * + col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
27328
3048
46160

skipif mysql # not compatible
query I rowsort label-6139
SELECT ( ( col0 ) ) * ( 37 * col1 ) + CAST ( + col2 * + col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
27328
3048
46160

query I rowsort
SELECT ALL cor0.col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - cor0.col1 * + 76 FROM tab1 AS cor0
----
-1976
-760
-988

query I rowsort
SELECT DISTINCT - col1 + col0 - col0 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT - + 19 + - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1267
-1423
-589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * - col2 col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - ( + col2 ) * col0 - + 46 * + col0 AS col0 FROM tab1 cor0
----
-11360
-300
-6592

query I rowsort
SELECT ALL + - 51 AS col1 FROM tab1 AS cor0
----
-51
-51
-51

query I rowsort
SELECT ALL - 45 + col0 * + col1 FROM tab0 AS cor0
----
2019
3350
8054

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 10 + + col0 * 56 col0 FROM tab1 AS cor0
----
3684
428
4610

query I rowsort
SELECT + - col0 * - col0 + + col2 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT col0 * - cor0.col0 + + col1 - + col0 FROM tab0 AS cor0
----
-1163
-514
-7919

query I rowsort
SELECT ALL - col0 + col1 * + 72 AS col1 FROM tab1 cor0
----
1869
656
856

query I rowsort
SELECT - + ( col1 ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL col1 * col1 + 63 FROM tab2 AS cor0
----
1024
352
3544

query I rowsort
SELECT ALL 47 * col1 FROM tab2 cor0
----
1457
2773
799

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + - col2 * col0 + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT - - 58 + col2 * ( col1 + + cor0.col2 ) AS col0 FROM tab2 AS cor0
----
1624
2148
2268

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6158
SELECT ALL + 46 + + col1 / + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6158
SELECT ALL + 46 + + col1 / + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL - 44 + col2 AS col1 FROM tab2 AS cor0
----
-17
-18
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6161
SELECT DISTINCT + 7 DIV col1 + + col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6161
SELECT DISTINCT + 7 / col1 + + col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6162
SELECT ALL - col2 + - col1 DIV col0 col2 FROM tab0 AS cor0
----
-3
-36
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6162
SELECT ALL - col2 + - col1 / col0 col2 FROM tab0 AS cor0
----
-3
-36
-83

query I rowsort
SELECT ALL + + col1 + col0 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - - 61 AS col1 FROM tab1 AS cor0
----
61
61
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6165
SELECT DISTINCT - 2 * + col0 + CAST( + col2 AS SIGNED ) * - col2 AS col0 FROM tab2 AS cor0
----
-1602
-743
-832

skipif mysql # not compatible
query I rowsort label-6165
SELECT DISTINCT - 2 * + col0 + CAST ( + col2 AS INTEGER ) * - col2 AS col0 FROM tab2 AS cor0
----
-1602
-743
-832

onlyif mysql # use DIV operator for integer division
query I rowsort label-6166
SELECT - - cor0.col2 DIV ( 57 ) AS col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6166
SELECT - - cor0.col2 / ( 57 ) AS col2 FROM tab1 AS cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + ( col0 ) col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - 56 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

query I rowsort
SELECT + tab0.col2 * ( - 38 ) FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to c57942902c6cf6a039c5ccfcb33f599d

query I rowsort
SELECT + - col2 * - col2 * ( 4 ) AS col2 FROM tab1 AS cor0
----
11664
12996
36864

onlyif mysql # use DIV operator for integer division
query I rowsort label-6171
SELECT 59 DIV - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6171
SELECT 59 / - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 * 75 + 80 FROM tab1 AS cor0
----
305
4880
6080

query I rowsort
SELECT - col1 * - 78 AS col0 FROM tab1 AS cor0
----
1014
2028
780

onlyif mysql # use DIV operator for integer division
query I rowsort label-6174
SELECT - col2 + ( 44 ) * col2 DIV CAST( ( col2 ) AS SIGNED ) FROM tab1 cor0
----
-10
-13
-52

skipif mysql # not compatible
query I rowsort label-6174
SELECT - col2 + ( 44 ) * col2 / CAST ( ( col2 ) AS INTEGER ) FROM tab1 cor0
----
-10
-13
-52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6175
SELECT - col1 * CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-6175
SELECT - col1 * CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL - 79 * + col0 AS col1 FROM tab0
----
-1896
-2765
-7031

onlyif mysql # use DIV operator for integer division
query I rowsort label-6177
SELECT ALL col0 DIV + col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6177
SELECT ALL col0 / + col1 FROM tab2
----
0
1
4

query I rowsort
SELECT col1 - - 23 FROM tab1 cor0
----
33
36
49

query I rowsort
SELECT - - 44 * + cor0.col2 + + col1 AS col0 FROM tab0 AS cor0
----
141
1538
3699

query I rowsort
SELECT col2 + - 23 - - col1 * + col1 FROM tab0 AS cor0
----
7406
8340
9387

query I rowsort
SELECT DISTINCT - + 10 + cor0.col1 FROM tab0 AS cor0
----
76
81
87

query I rowsort
SELECT - col2 - - col0 * - cor0.col2 FROM tab1 AS cor0
----
-216
-3705
-7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-6183
SELECT 57 * col0 DIV col1 FROM tab2 cor0
----
12
264
75

skipif mysql # not compatible
query I rowsort label-6183
SELECT 57 * col0 / col1 FROM tab2 cor0
----
12
264
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-6184
SELECT + col1 * 11 DIV - col1 - + col1 DIV - 49 FROM tab0 AS cor0
----
-10
-10
-10

skipif mysql # not compatible
query I rowsort label-6184
SELECT + col1 * 11 / - col1 - + col1 / - 49 FROM tab0 AS cor0
----
-10
-10
-10

query I rowsort
SELECT + col1 * + 71 FROM tab0
----
6106
6461
6887

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6186
SELECT ALL - CAST( NULL AS DECIMAL ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6186
SELECT ALL - CAST ( NULL AS REAL ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + + col2 + col0 * col0 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT 99 + col2 * col0 * + 6 FROM tab1 cor0
----
1071
21987
46179

query I rowsort
SELECT ALL col1 + ( col1 ) + + col1 FROM tab0
----
258
273
291

query I rowsort
SELECT ALL - cor0.col2 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + col0 col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + 94 * col2 AS col1 FROM tab2 AS cor0
----
2444
2538
3572

query I rowsort
SELECT DISTINCT - 58 * col1 + 3 FROM tab0 AS cor0
----
-4985
-5275
-5623

query I rowsort
SELECT ALL + + 3 + - col2 * col1 FROM tab2 AS cor0
----
-1531
-643
-834

query I rowsort
SELECT + - cor0.col0 - + col1 * + cor0.col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT - 1 * col1 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6197
SELECT ALL + 12 * col2 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6197
SELECT ALL + 12 * col2 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col1 * + col2 + + ( col1 + - col1 ) * col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT cor0.col2 * - col1 + ( - 56 ) FROM tab0 AS cor0
----
-153
-2894
-7518

query I rowsort
SELECT ALL + col0 * col0 + - ( - col0 ) FROM tab0
----
1260
600
8010

query I rowsort
SELECT - 15 * + 84 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to b5b3eb88ba35f0d366c930f7e7c8859c

query I rowsort
SELECT - 62 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT - + col2 * - 32 AS col0 FROM tab2 AS cor0
----
1216
832
864

query I rowsort
SELECT - 71 FROM tab0, tab1 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 71 * col1 col1 FROM tab2 AS cor0
----
1207
2201
4189

query I rowsort
SELECT + + 48 + - 45 FROM tab1 cor0
----
3
3
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6207
SELECT + + col1 * col0 + cor0.col1 + col0 * - CAST( + col0 AS SIGNED ) FROM tab1 AS cor0
----
-3446
-5347
95

skipif mysql # not compatible
query I rowsort label-6207
SELECT + + col1 * col0 + cor0.col1 + col0 * - CAST ( + col0 AS INTEGER ) FROM tab1 AS cor0
----
-3446
-5347
95

query I rowsort
SELECT DISTINCT col1 + + ( col0 ) FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT col2 + 86 * - col1 * cor0.col2 FROM tab0 AS cor0
----
-244035
-641650
-8341

query I rowsort
SELECT ALL + + 76 AS col0 FROM tab0 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT ALL - col0 * col1 + + ( col2 ) FROM tab2 AS cor0
----
-1305
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + - ( col1 ) * - col2 col0 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-6213
SELECT DISTINCT cor0.col1 DIV + 82 + col1 * + col1 + 14 AS col1 FROM tab1 AS cor0
----
114
183
690

skipif mysql # not compatible
query I rowsort label-6213
SELECT DISTINCT cor0.col1 / + 82 + col1 * + col1 + 14 AS col1 FROM tab1 AS cor0
----
114
183
690

query I rowsort
SELECT DISTINCT - + col2 + - col2 AS col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT DISTINCT + col1 * + 31 FROM tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT - col1 * 35 FROM tab1 cor0
----
-350
-455
-910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6217
SELECT ALL - col2 / - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6217
SELECT ALL - col2 / - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - cor0.col0 * + col1 + + 77 FROM tab1 AS cor0
----
-1
-563
-963

query I rowsort
SELECT + col1 + + col2 * ( col1 ) - col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - col0 * col1 + col2 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 38 * col0 col2 FROM tab2 AS cor0
----
-266
-2964
-3002

query I rowsort
SELECT + - 89 + + col2 FROM tab1 cor0
----
-32
-35
7

query I rowsort
SELECT DISTINCT - 41 * col1 FROM tab1 AS cor0
----
-1066
-410
-533

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6224
SELECT - CAST( col2 AS SIGNED ) * + col2 + col0 FROM tab0 AS cor0
----
-1065
-6635
34

skipif mysql # not compatible
query I rowsort label-6224
SELECT - CAST ( col2 AS INTEGER ) * + col2 + col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT col2 + - 47 AS col2 FROM tab1 cor0
----
10
49
7

query I rowsort
SELECT DISTINCT 76 + 17 * col2 AS col2 FROM tab0 AS cor0
----
1470
637
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6227
SELECT ALL + ( - 55 ) + col2 DIV - 17 FROM tab1 AS cor0
----
-58
-58
-60

skipif mysql # not compatible
query I rowsort label-6227
SELECT ALL + ( - 55 ) + col2 / - 17 FROM tab1 AS cor0
----
-58
-58
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6228
SELECT CAST( NULL AS DECIMAL ) + + col1 + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6228
SELECT CAST ( NULL AS REAL ) + + col1 + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 - col1 * - col0 AS col2 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT ALL 38 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT - 35 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT DISTINCT col2 * + col2 - + col0 * col1 FROM tab2
----
-3926
101
512

onlyif mysql # use DIV operator for integer division
query I rowsort label-6233
SELECT + col1 + ( col2 ) DIV - col2 - 40 * + col2 FROM tab1
----
-2135
-2271
-3828

skipif mysql # not compatible
query I rowsort label-6233
SELECT + col1 + ( col2 ) / - col2 - 40 * + col2 FROM tab1
----
-2135
-2271
-3828

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6234
SELECT DISTINCT cor0.col0 + col0 * - CAST( col2 + cor0.col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-399
-4266
-6552

skipif mysql # not compatible
query I rowsort label-6234
SELECT DISTINCT cor0.col0 + col0 * - CAST ( col2 + cor0.col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-399
-4266
-6552

query I rowsort
SELECT ALL col0 * - col0 + cor0.col1 * cor0.col2 FROM tab1 AS cor0
----
-3526
-5152
1395

query I rowsort
SELECT ALL - col1 - + col2 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT 95 * - col0 FROM tab2 AS cor0
----
-665
-7410
-7505

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 99 col2 FROM tab1 AS cor0
----
99
99
99

query I rowsort
SELECT ALL col2 * - col1 - - col1 * - col2 AS col1 FROM tab2
----
-1292
-1674
-3068

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col1 col2 FROM tab0 WHERE NULL NOT IN ( col2 )
----

query I rowsort
SELECT + tab1.col2 + col1 * col1 FROM tab1 WHERE NULL > ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6242
SELECT - col0 + col2 * + col0 * col2 - + col1 DIV - col0 AS col1 FROM tab2
----
113997
5100
52650

skipif mysql # not compatible
query I rowsort label-6242
SELECT - col0 + col2 * + col0 * col2 - + col1 / - col0 AS col1 FROM tab2
----
113997
5100
52650

query I rowsort
SELECT ALL col1 * - col0 + ( col2 * + col0 ) FROM tab2 AS cor0
----
-2574
-28
1659

query I rowsort
SELECT ALL + tab1.col1 * - col2 AS col1 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT cor0.col0 * + CAST ( + col0 AS REAL ) + col1 FROM tab1 AS cor0
----
35
4106
6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * 34 col2 FROM tab1 AS cor0
----
-1836
-1938
-3264

query I rowsort
SELECT DISTINCT + + col2 + col0 * col1 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT - 16 + col2 AS col1 FROM tab0 AS cor0
----
-15
17
66

query I rowsort
SELECT - tab2.col0 + + col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL ( col2 * - 81 ) AS col1 FROM tab0
----
-2673
-6642
-81

query I rowsort
SELECT ALL + 47 AS col2 FROM tab0
----
47
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - col0 col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT col0 + + 14 * + col0 AS col0 FROM tab2
----
105
1170
1185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 col1 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT 52 + - tab1.col1 FROM tab1
----
26
39
42

query I rowsort
SELECT + 48 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT + col1 + col2 * + col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT - 55 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

query I rowsort
SELECT ALL - + col0 * + col2 AS col1 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT - + col0 * col2 + - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT col0 + + 63 AS col1 FROM tab0
----
152
87
98

query I rowsort
SELECT DISTINCT col2 * - col0 + + col1 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 + - cor0.col2 col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT + col1 * + col2 + - ( cor0.col2 ) * col0 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT ALL - 69 + - cor0.col0 FROM tab2 AS cor0
----
-147
-148
-76

query I rowsort
SELECT ALL + 72 * col2 FROM tab0 AS cor0
----
2376
5904
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6267
SELECT DISTINCT - col1 * col0 + col0 + col0 * col0 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6267
SELECT DISTINCT - col1 * col0 + col0 + col0 * col0 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT 89 AS col0 FROM tab0 AS cor0
----
89
89
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 - + col1 col0 FROM tab1 cor0
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-6270
SELECT ALL - col0 DIV + col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6270
SELECT ALL - col0 / + col1 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 62 + - col2 col0 FROM tab2 AS cor0
----
24
35
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * - col2 * + 85 col1 FROM tab1 AS cor0
----
247860
276165
783360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 + - 65 col0 FROM tab2 AS cor0
----
-2093
-254
-3067

query I rowsort
SELECT DISTINCT + + 91 * + cor0.col1 + 95 AS col0 FROM tab2 AS cor0
----
1642
2916
5464

query I rowsort
SELECT + ( col1 ) * - 92 AS col0 FROM tab2 AS cor0
----
-1564
-2852
-5428

query I rowsort
SELECT ALL 11 * + col1 + + col1 AS col0 FROM tab0 AS cor0
----
1032
1092
1164

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - col1 * col1 col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6278
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6278
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6279
SELECT - col0 + col2 DIV - col0 AS col2 FROM tab0 AS cor0
----
-25
-35
-89

skipif mysql # not compatible
query I rowsort label-6279
SELECT - col0 + col2 / - col0 AS col2 FROM tab0 AS cor0
----
-25
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6280
SELECT col2 DIV 61 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6280
SELECT col2 / 61 FROM tab1
----
0
0
1

query I rowsort
SELECT tab0.col2 * + ( 80 ) * col1 + - col0 FROM tab0
----
227016
596871
7725

query I rowsort
SELECT ALL - col0 * 69 FROM tab2
----
-483
-5382
-5451

query I rowsort
SELECT col0 + - 70 + col1 FROM tab2 AS cor0
----
-32
26
67

query I rowsort
SELECT DISTINCT - 51 + - 97 FROM tab1, tab0 cor0
----
-148

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6285
SELECT ALL tab1.col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6285
SELECT ALL tab1.col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * col2 + + col2 AS col0 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT - cor0.col1 + + col0 * + col1 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT col0 * + ( + col2 ) + col1 AS col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-6289
SELECT - 45 DIV col2 + - col1 AS col0 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-6289
SELECT - 45 / col2 + - col1 AS col0 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT + + 43 - 41 * + col1 * + ( - ( cor0.col0 ) ) AS col2 FROM tab0 AS cor0
----
139238
332102
84667

query I rowsort
SELECT + - 75 * - col2 + col1 * + col1 FROM tab1 cor0
----
4375
4726
7369

onlyif mysql # use DIV operator for integer division
query I rowsort label-6292
SELECT ALL 70 DIV col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6292
SELECT ALL 70 / col2 FROM tab1
----
0
1
1

query I rowsort
SELECT ALL - - col1 * + col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - - 40 * - col0 * col1 FROM tab0 AS cor0
----
-135800
-323960
-82560

query I rowsort
SELECT DISTINCT - col0 * col1 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + ( + col0 ) * cor0.col1 * + col0 FROM tab1 AS cor0
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col1 + - col2 col0 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT ALL 10 FROM tab0 cor0
----
10
10
10

query I rowsort
SELECT - col1 * col0 * + 71 AS col1 FROM tab1 cor0
----
-45440
-5538
-73840

query I rowsort
SELECT - + cor0.col2 * + 26 + col1 FROM tab1 AS cor0
----
-1378
-1472
-2483

query I rowsort
SELECT + cor0.col0 * col1 + col1 * + col0 * col2 + - 40 FROM tab2 cor0
----
124214
52337
6036

query I rowsort
SELECT + col2 + - col1 * col1 + + col1 AS col0 FROM tab1 AS cor0
----
-33
-596
-60

query I rowsort
SELECT + tab1.col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6304
SELECT - - col0 DIV + col2 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6304
SELECT - - col0 / + col2 AS col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - col1 + + col1 * + col0 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL + + col1 * - col1 + - col0 + + col2 FROM tab2 AS cor0
----
-330
-3533
-941

query I rowsort
SELECT ALL - - cor0.col1 * col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + - cor0.col1 + + col2 * + col2 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT ( 3 ) + - col0 AS col0 FROM tab1 cor0
----
-61
-77
0

query I rowsort
SELECT DISTINCT 55 * col0 + cor0.col2 AS col0 FROM tab0 AS cor0
----
1353
1926
4977

query I rowsort
SELECT ALL - 33 * cor0.col0 FROM tab1 AS cor0
----
-2112
-2640
-99

skipif mysql # not compatible
query I rowsort
SELECT col1 / - CAST ( - col1 AS REAL ) AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT 14 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT - col0 * - col1 + + col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + col0 * col1 + ( + col0 ) * + col1 FROM tab2 AS cor0
----
2686
434
9204

query I rowsort
SELECT DISTINCT 73 AS col2 FROM tab2, tab1 AS cor0
----
73

query I rowsort
SELECT DISTINCT 40 AS col0 FROM tab1
----
40

query I rowsort
SELECT col2 * + col0 + col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT ALL - ( tab0.col1 + + col0 ) FROM tab0
----
-110
-132
-180

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 CROSS JOIN tab2, tab1, tab0 cor1
----
3645 values hashing to 9d746e15fdb5adcb43a7518cd9743eb3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6321
SELECT - tab1.col0 + - ( col1 ) DIV col2 AS col1 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-6321
SELECT - tab1.col0 + - ( col1 ) / col2 AS col1 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT 28 FROM tab1, tab0 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT + col1 + - 88 FROM tab0
----
-2
3
9

query I rowsort
SELECT + + col0 * ( col1 + ( + col2 ) ) AS col2 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT DISTINCT + col0 + 45 FROM tab0 cor0
----
134
69
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6326
SELECT ALL + - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6326
SELECT ALL + - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col1 AS REAL ) + + col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL + + col2 * - col0 + col2 * ( col0 ) FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6329
SELECT + col1 DIV - cor0.col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-6329
SELECT + col1 / - cor0.col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT DISTINCT - - col2 * + col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT - col2 + - 5 FROM tab2 AS cor0
----
-31
-32
-43

onlyif mysql # use DIV operator for integer division
query I rowsort label-6332
SELECT ALL + 69 DIV col1 FROM tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-6332
SELECT ALL + 69 / col1 FROM tab1 AS cor0
----
2
5
6

query I rowsort
SELECT DISTINCT + col2 * col0 * + ( col1 * - col2 ) + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-2247729
-3396
-54457758

query I rowsort
SELECT DISTINCT 13 + cor0.col2 * + col1 FROM tab1 AS cor0
----
1261
1417
583

query I rowsort
SELECT DISTINCT - 83 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
-83

query I rowsort
SELECT + 10 + + cor0.col0 * col0 FROM tab1 AS cor0
----
19
4106
6410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6337
SELECT - - CAST( 43 AS SIGNED ) + cor0.col0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to e040dd19ef805c1a6d94fad959b43bc3

skipif mysql # not compatible
query I rowsort label-6337
SELECT - - CAST ( 43 AS INTEGER ) + cor0.col0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to e040dd19ef805c1a6d94fad959b43bc3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 76 * cor0.col0 col1 FROM tab2 AS cor0
----
532
5928
6004

query I rowsort
SELECT 90 + + cor0.col2 FROM tab2 cor0
----
116
117
128

onlyif mysql # use DIV operator for integer division
query I rowsort label-6340
SELECT DISTINCT + col0 + + col0 DIV - cor0.col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-6340
SELECT DISTINCT + col0 + + col0 / - cor0.col0 FROM tab1 AS cor0
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 5 col2 FROM tab1 AS cor0
----
5

query I rowsort
SELECT + tab1.col2 - 10 * col1 AS col2 FROM tab1
----
-206
-34
-43

query I rowsort
SELECT + 61 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

onlyif mysql # use DIV operator for integer division
query I rowsort label-6344
SELECT ALL - + ( col0 ) * col1 DIV + col0 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6344
SELECT ALL - + ( col0 ) * col1 / + col0 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + - ( - col0 ) + - col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + cor0.col2 + + ( + col1 ) * col1 * col1 AS col0 FROM tab1 AS cor0
----
1057
17630
2293

query I rowsort
SELECT + - col0 + - col1 + - col2 * - col2 AS col1 FROM tab0 AS cor0
----
-131
6544
979

query I rowsort
SELECT + tab2.col2 AS col2 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6349
SELECT - col2 * + col2 + - col2 DIV + col2 AS col2 FROM tab1 AS cor0
----
-2917
-3250
-9217

skipif mysql # not compatible
query I rowsort label-6349
SELECT - col2 * + col2 + - col2 / + col2 AS col2 FROM tab1 AS cor0
----
-2917
-3250
-9217

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col1 + + CAST ( - col1 AS REAL ) col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - col1 * 63 + 75 + col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-1485
296
85

query I rowsort
SELECT ALL col2 + + ( ( cor0.col1 ) ) AS col0 FROM tab0 cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6353
SELECT DISTINCT - col0 + 93 DIV - col1 FROM tab2 AS cor0
----
-10
-79
-84

skipif mysql # not compatible
query I rowsort label-6353
SELECT DISTINCT - col0 + 93 / - col1 FROM tab2 AS cor0
----
-10
-79
-84

query I rowsort
SELECT ALL 20 + 77 AS col1 FROM tab0 AS cor0
----
97
97
97

query I rowsort
SELECT - - 32 AS col2 FROM tab2 AS cor0
----
32
32
32

query I rowsort
SELECT ALL 45 AS col2 FROM tab2 AS cor0
----
45
45
45

query I rowsort
SELECT ALL - 35 AS col1 FROM tab1 AS cor0
----
-35
-35
-35

onlyif mysql # use DIV operator for integer division
query I rowsort label-6358
SELECT + col1 DIV 45 FROM tab0 AS cor0
----
1
2
2

skipif mysql # not compatible
query I rowsort label-6358
SELECT + col1 / 45 FROM tab0 AS cor0
----
1
2
2

query I rowsort
SELECT cor0.col0 + col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL - ( col0 ) * + col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + 34 * 96 AS col2 FROM tab1 AS cor0
----
3264

query I rowsort
SELECT DISTINCT tab1.col1 + col1 * - tab1.col2 + - col2 AS col0 FROM tab1
----
-1331
-1432
-617

onlyif mysql # use DIV operator for integer division
query I rowsort label-6363
SELECT tab0.col1 - - 51 * col1 DIV col1 FROM tab0
----
137
142
148

skipif mysql # not compatible
query I rowsort label-6363
SELECT tab0.col1 - - 51 * col1 / col1 FROM tab0
----
137
142
148

query I rowsort
SELECT 11 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 41 * 5 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to fe4fd90442e9bf0cc16392ecc6ad1585

query I rowsort
SELECT DISTINCT + col2 * 38 * 50 AS col2 FROM tab0
----
155800
1900
62700

query I rowsort
SELECT + col0 * + col1 * col0 FROM tab0
----
118825
49536
720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 19 col1 FROM tab0, tab1 AS cor0
----
19

query I rowsort
SELECT ALL + 9 + + col1 AS col1 FROM tab2 AS cor0
----
26
40
68

query I rowsort
SELECT ALL + + col2 + - 71 * cor0.col1 FROM tab0 AS cor0
----
-6073
-6379
-6886

query I rowsort
SELECT DISTINCT - - col0 * col0 AS col0 FROM tab0 cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col1 col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + 86 + - cor0.col1 AS col1 FROM tab2, tab1 AS cor0
----
60
73
76

query I rowsort
SELECT ALL col2 + - 57 + + col1 * - col2 FROM tab0 AS cor0
----
-153
-2862
-7437

query I rowsort
SELECT - + ( + col2 ) * + col0 + + 8 FROM tab2 cor0
----
-181
-2020
-2994

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 col2 FROM tab0 AS cor0
----
72
72
72

query I rowsort
SELECT + col1 * 74 + - tab0.col0 * + 43 FROM tab0
----
2907
5332
5673

query I rowsort
SELECT ALL ( col0 ) * + tab0.col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT 38 * col0 FROM tab0 AS cor0
----
1330
3382
912

query I rowsort
SELECT ALL ( tab0.col1 ) AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT - col2 + + col1 * col1 * col0 AS col1 FROM tab0 AS cor0
----
177471
329314
736927

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + 79 ) - cor0.col2 col1 FROM tab1 AS cor0
----
-17
22
25

query I rowsort
SELECT - ( col2 ) * col0 + 59 AS col2 FROM tab2
----
-130
-1969
-2943

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col1 - - col1 col1 FROM tab2
----
0
0
0

query I rowsort
SELECT 43 * + tab1.col1 AS col2 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to afcccd61fde1b03de416c9f10db2de82

query I rowsort
SELECT ALL col1 * col2 * + col1 - - col0 * - col1 FROM tab1
----
15184
36426
5060

query I rowsort
SELECT DISTINCT - + col0 + col2 AS col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL - - col1 * ( 89 ) FROM tab1 cor0
----
1157
2314
890

query I rowsort
SELECT col0 * cor0.col0 + + col2 AS col0 FROM tab2 cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6390
SELECT + col1 DIV - col2 + 26 AS col0 FROM tab1 AS cor0
----
26
26
26

skipif mysql # not compatible
query I rowsort label-6390
SELECT + col1 / - col2 + 26 AS col0 FROM tab1 AS cor0
----
26
26
26

query I rowsort
SELECT DISTINCT + tab1.col1 + - col2 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT 18 FROM tab2, tab1, tab2 AS cor0
----
18

query I rowsort
SELECT col2 * col1 * col1 AS col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT - tab0.col0 * + col1 + + col1 * col2 + col0 * tab0.col0 * - col1 AS col1 FROM tab0
----
-122123
-48762
-721448

query I rowsort
SELECT tab1.col2 * col2 + + col2 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT - col0 * + col2 + col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT + 73 + + col0 FROM tab2
----
151
152
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6398
SELECT 59 + col1 + col1 * ( col0 + - CAST( - col1 AS SIGNED ) ) AS col0 FROM tab1
----
1281
809
839

skipif mysql # not compatible
query I rowsort label-6398
SELECT 59 + col1 + col1 * ( col0 + - CAST ( - col1 AS INTEGER ) ) AS col0 FROM tab1
----
1281
809
839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 + - ( 44 ) col2 FROM tab0
----
-9
7254
748

query I rowsort
SELECT tab2.col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6401
SELECT col0 * - CAST( + col2 AS SIGNED ) + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

skipif mysql # not compatible
query I rowsort label-6401
SELECT col0 * - CAST ( + col2 AS INTEGER ) + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-6402
SELECT DISTINCT col0 DIV 1 + col1 AS col1 FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-6402
SELECT DISTINCT col0 / 1 + col1 AS col1 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + ( - cor0.col2 ) col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - - col2 + + ( col1 ) * col0 AS col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col2 + 48 * - 17 FROM tab1 cor0
----
-720
-759
-762

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6406
SELECT ALL + col1 * ( + col1 ) + cor0.col0 * CAST( + col1 AS SIGNED ) AS col0 FROM tab0 cor0
----
12804
16380
9460

skipif mysql # not compatible
query I rowsort label-6406
SELECT ALL + col1 * ( + col1 ) + cor0.col0 * CAST ( + col1 AS INTEGER ) AS col0 FROM tab0 cor0
----
12804
16380
9460

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 31 + + ( - col0 ) * col1 + ( col1 + + 66 * 26 ) col0 FROM tab2 AS cor0
----
-137
-4656
569

query I rowsort
SELECT + col2 + 98 AS col2 FROM tab2 AS cor0
----
124
125
136

query I rowsort
SELECT ALL col1 * ( cor0.col2 ) + col2 + cor0.col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
14268
3960
99

query I rowsort
SELECT DISTINCT - col2 * ( col2 ) - + col1 AS col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6411
SELECT - col0 + - CAST( 55 + - col0 AS SIGNED ) * col2 FROM tab2 AS cor0
----
-1303
520
833

skipif mysql # not compatible
query I rowsort label-6411
SELECT - col0 + - CAST ( 55 + - col0 AS INTEGER ) * col2 FROM tab2 AS cor0
----
-1303
520
833

query I rowsort
SELECT - + 28 FROM tab0 cor0
----
-28
-28
-28

query I rowsort
SELECT DISTINCT 89 + col2 * 19 AS col0 FROM tab1 AS cor0
----
1115
1172
1913

query I rowsort
SELECT DISTINCT + 10 * - tab0.col0 FROM tab0
----
-240
-350
-890

query I rowsort
SELECT - cor0.col1 + + cor0.col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT col2 + tab1.col0 * + col1 FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL - tab0.col1 - + col1 FROM tab0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-6418
SELECT + 84 DIV col1 AS col2 FROM tab1
----
3
6
8

skipif mysql # not compatible
query I rowsort label-6418
SELECT + 84 / col1 AS col2 FROM tab1
----
3
6
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6419
SELECT - - 88 DIV + col2 - col2 DIV col0 FROM tab0 AS cor0
----
1
1
88

skipif mysql # not compatible
query I rowsort label-6419
SELECT - - 88 / + col2 - col2 / col0 FROM tab0 AS cor0
----
1
1
88

query I rowsort
SELECT col1 * - 39 AS col0 FROM tab0 cor0
----
-3354
-3549
-3783

query I rowsort
SELECT + col2 + - tab1.col0 AS col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT + cor0.col0 + - 67 FROM tab2 AS cor0
----
-60
11
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 col0 FROM tab1
----
25
25
25

query I rowsort
SELECT + col0 * 43 FROM tab2 AS cor0
----
301
3354
3397

query I rowsort
SELECT 88 + 12 AS col1 FROM tab0 AS cor0
----
100
100
100

query I rowsort
SELECT - + 29 * col0 AS col0 FROM tab0 AS cor0
----
-1015
-2581
-696

query I rowsort
SELECT + ( + ( - col0 ) ) + - 80 FROM tab0
----
-104
-115
-169

query I rowsort
SELECT 66 * col1 + col2 FROM tab2
----
1160
2073
3920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6429
SELECT - tab0.col2 DIV + 47 - - tab0.col1 AS col1 FROM tab0
----
86
90
97

skipif mysql # not compatible
query I rowsort label-6429
SELECT - tab0.col2 / + 47 - - tab0.col1 AS col1 FROM tab0
----
86
90
97

query I rowsort
SELECT DISTINCT + col0 + - ( col1 ) AS col0 FROM tab0
----
-2
-62

query I rowsort
SELECT 65 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT ALL 83 * + col1 FROM tab2
----
1411
2573
4897

query I rowsort
SELECT - ( col0 ) + col0 * - col1 AS col2 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT + tab0.col2 + - col0 AS col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT - ( + 92 ) FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to a0e6b76227d870d10c4d9f46545a7c83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6436
SELECT DISTINCT col1 + col0 DIV + cor0.col1 AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6436
SELECT DISTINCT col1 + col0 / + cor0.col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + 44 * cor0.col1 + + col0 AS col1 FROM tab1 AS cor0
----
1147
504
652

query I rowsort
SELECT DISTINCT + + col1 + cor0.col0 - - col2 * col2 FROM tab2 AS cor0
----
1540
767
813

query I rowsort
SELECT ( col1 ) + - ( - 21 ) FROM tab0 AS cor0
----
107
112
118

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT + + col2 + col1 * col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL - - cor0.col2 - + col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - 59 * col1 + col0 AS col2 FROM tab2 AS cor0
----
-1822
-3403
-924

query I rowsort
SELECT DISTINCT cor0.col0 - - col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL + + 37 * - col0 FROM tab0 AS cor0
----
-1295
-3293
-888

query I rowsort
SELECT cor0.col2 * + col0 + + 76 * col2 AS col1 FROM tab1 AS cor0
----
14976
4266
7980

onlyif mysql # use DIV operator for integer division
query I rowsort label-6447
SELECT col2 + - col2 DIV - 72 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6447
SELECT col2 + - col2 / - 72 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL + col1 + ( ( + col0 ) ) * 77 * col1 AS col0 FROM tab1
----
49290
6032
80093

query I rowsort
SELECT - col2 + + 44 * col0 * tab1.col0 AS col1 FROM tab1
----
180167
281504
342

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6450
SELECT col2 + CAST( NULL AS SIGNED ) * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6450
SELECT col2 + CAST ( NULL AS INTEGER ) * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6451
SELECT ALL + + col1 + CAST( 58 + + col2 AS SIGNED ) * 30 AS col2 FROM tab1 AS cor0
----
3386
3460
4633

skipif mysql # not compatible
query I rowsort label-6451
SELECT ALL + + col1 + CAST ( 58 + + col2 AS INTEGER ) * 30 AS col2 FROM tab1 AS cor0
----
3386
3460
4633

query I rowsort
SELECT ALL - col0 + + col1 * col1 AS col2 FROM tab2 cor0
----
210
3403
954

onlyif mysql # use DIV operator for integer division
query I rowsort label-6453
SELECT DISTINCT col0 DIV col1 AS col2 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6453
SELECT DISTINCT col0 / col1 AS col2 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL - col1 * 45 AS col2 FROM tab0 AS cor0
----
-3870
-4095
-4365

query I rowsort
SELECT col2 - 8 AS col1 FROM tab0 cor0
----
-7
25
74

query I rowsort
SELECT DISTINCT + col1 * col0 + col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT cor0.col1 + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + ( - 79 ) AS col1 FROM tab0 AS cor0
----
-79

query I rowsort
SELECT DISTINCT - col1 * + ( - col2 ) AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col0 + - 33 * col0 + + 30 AS col2 FROM tab2 AS cor0
----
-194
-2466
-2498

query I rowsort
SELECT ALL - 72 * - 74 AS col1 FROM tab2 AS cor0
----
5328
5328
5328

query I rowsort
SELECT - cor0.col1 * col2 + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT - 13 FROM tab2, tab0 AS cor0
----
-13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6464
SELECT + col0 + + tab1.col2 * CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6464
SELECT + col0 + + tab1.col2 * CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 - col0 * - col2 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + + col2 * + col1 * - 5 + col1 FROM tab0 AS cor0
----
-14104
-37219
-388

query I rowsort
SELECT + cor0.col0 * - 35 AS col1 FROM tab1 AS cor0
----
-105
-2240
-2800

query I rowsort
SELECT DISTINCT - cor0.col0 * + col2 + - col2 AS col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT tab1.col1 FROM tab1, tab2, tab0 AS cor0
----
10
13
26

query I rowsort
SELECT - ( tab0.col1 ) AS col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT 12 * col1 + + ( 93 + col1 ) FROM tab1
----
223
262
431

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6472
SELECT DISTINCT - 46 + col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6472
SELECT DISTINCT - 46 + col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL

query I rowsort
SELECT ALL ( - col2 * - col0 ) + + col1 AS col1 FROM tab1
----
188
3658
7693

query I rowsort
SELECT ( - tab0.col0 ) * + col1 + - col0 AS col0 FROM tab0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-6475
SELECT + ( col1 ) + 3 DIV + col2 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6475
SELECT + ( col1 ) + 3 / + col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT col1 * - col1 + col1 FROM tab2
----
-272
-3422
-930

query I rowsort
SELECT col2 * tab1.col0 + tab1.col2 * ( - col2 + col1 ) AS col1 FROM tab1
----
-1350
-288
969

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6478
SELECT - col2 + CAST( NULL AS DECIMAL ) * col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6478
SELECT - col2 + CAST ( NULL AS REAL ) * col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6479
SELECT - col2 - CAST( + 52 AS SIGNED ) FROM tab1
----
-106
-109
-148

skipif mysql # not compatible
query I rowsort label-6479
SELECT - col2 - CAST ( + 52 AS INTEGER ) FROM tab1
----
-106
-109
-148

onlyif mysql # use DIV operator for integer division
query I rowsort label-6480
SELECT ALL + col1 DIV - col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6480
SELECT ALL + col1 / - col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT - col0 + ( col2 ) FROM tab0 cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6482
SELECT DISTINCT - col0 + 29 DIV + col0 FROM tab0 AS cor0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-6482
SELECT DISTINCT - col0 + 29 / + col0 FROM tab0 AS cor0
----
-23
-35
-89

query I rowsort
SELECT ALL col2 - + 62 * col0 AS col2 FROM tab2 AS cor0
----
-407
-4810
-4860

query I rowsort
SELECT col0 + - col2 * tab0.col2 AS col0 FROM tab0
----
-1065
-6635
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6485
SELECT ALL + col0 + + col2 DIV + 60 FROM tab1 AS cor0
----
3
64
81

skipif mysql # not compatible
query I rowsort label-6485
SELECT ALL + col0 + + col2 / + 60 FROM tab1 AS cor0
----
3
64
81

query I rowsort
SELECT DISTINCT + col0 * col1 + col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT - + cor0.col1 AS col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col0 - + col0 * - col2 AS col0 FROM tab1
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 39 + col2 col1 FROM tab2
----
65
66
77

query I rowsort
SELECT ( - col2 ) + + col0 + 96 FROM tab2
----
137
148
76

query I rowsort
SELECT 5 - - col2 FROM tab1
----
101
59
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - + cor0.col1 * + col2 * cor0.col1 col2 FROM tab2 AS cor0
----
-11020
-25974
-90532

query I rowsort
SELECT - col0 * + col1 + col1 + + 66 FROM tab0 AS cor0
----
-1912
-3232
-7942

query I rowsort
SELECT DISTINCT + ( + col1 ) * + col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col0 + - cor0.col2 * - col0 AS col1 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + ( + col2 ) + cor0.col0 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT 84 FROM tab1, tab0 cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT DISTINCT + 54 * col2 + ( - col2 ) FROM tab2 AS cor0
----
1378
1431
2014

onlyif mysql # use DIV operator for integer division
query I rowsort label-6499
SELECT + + col2 + col2 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6499
SELECT + + col2 + col2 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 26 * - cor0.col2 col2 FROM tab1 AS cor0
----
-1404
-1482
-2496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 6 col0 FROM tab0 AS cor0
----
-6

query I rowsort
SELECT ALL + + col0 + cor0.col0 * - 0 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT col0 * col0 - - col0 AS col2 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT - - 52 + col0 * ( 5 ) * col1 FROM tab2 AS cor0
----
1137
23062
6767

query I rowsort
SELECT ALL - cor0.col0 * - cor0.col2 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + cor0.col2 col2 FROM tab1 AS cor0
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * cor0.col0 * ( - 35 ) + + col1 col0 FROM tab0 AS cor0
----
-1128
-255339
-27634

query I rowsort
SELECT DISTINCT col2 - - col2 AS col1 FROM tab2 cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 73 + col1 col2 FROM tab0 AS cor0
----
13
18
24

query I rowsort
SELECT DISTINCT - 62 + + cor0.col1 - col0 * - ( col1 + - col2 ) * col1 FROM tab0 AS cor0
----
109416
325955
72920

query I rowsort
SELECT ALL - - 4 + col0 FROM tab0 AS cor0
----
28
39
93

query I rowsort
SELECT - - ( col2 ) + - col1 - + col2 * col2 AS col2 FROM tab1 AS cor0
----
-2888
-3202
-9133

onlyif mysql # use DIV operator for integer division
query I rowsort label-6513
SELECT - col1 * col0 + + col2 DIV - 63 + + col1 AS col0 FROM tab1 AS cor0
----
-1028
-52
-630

skipif mysql # not compatible
query I rowsort label-6513
SELECT - col1 * col0 + + col2 / - 63 + + col1 AS col0 FROM tab1 AS cor0
----
-1028
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-6514
SELECT + - cor0.col2 * cor0.col2 DIV col1 AS col0 FROM tab0 AS cor0
----
-12
-73
0

skipif mysql # not compatible
query I rowsort label-6514
SELECT + - cor0.col2 * cor0.col2 / col1 AS col0 FROM tab0 AS cor0
----
-12
-73
0

query I rowsort
SELECT ALL - + cor0.col0 * + col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL - - col2 * + col0 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT 34 * + col2 AS col0 FROM tab0
----
1122
2788
34

query I rowsort
SELECT ALL - - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + 41 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
2214
2337
3936

query I rowsort
SELECT DISTINCT - 44 * + cor0.col1 FROM tab2 AS cor0
----
-1364
-2596
-748

query I rowsort
SELECT - col1 + + col0 * col0 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT - - col2 * col2 + + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL - 83 FROM tab2, tab1 cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT + col1 * col1 + col0 * col1 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT ALL + + col1 * ( col1 ) AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - col1 * 91 AS col0 FROM tab0 cor0
----
-7826
-8281
-8827

query I rowsort
SELECT DISTINCT 88 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
88

query I rowsort
SELECT ALL - 24 AS col0 FROM tab2 cor0
----
-24
-24
-24

query I rowsort
SELECT + ( + cor0.col0 ) * col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + ( 5 + col1 ) AS col0 FROM tab2
----
22
36
64

query I rowsort
SELECT DISTINCT ( cor0.col2 ) * - col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 4c87430a2010fee8daf6d04acf0ad703

query I rowsort
SELECT - - 59 * col1 AS col1 FROM tab2 AS cor0
----
1003
1829
3481

query I rowsort
SELECT - 6 * - col2 FROM tab1 AS cor0
----
324
342
576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 * col2 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - 66 - + cor0.col0 * + ( + col2 ) AS col0 FROM tab2 AS cor0
----
-2094
-255
-3068

query I rowsort
SELECT DISTINCT + col2 + - 82 AS col1 FROM tab0
----
-49
-81
0

query I rowsort
SELECT + ( col1 ) + + col1 FROM tab1
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + cor0.col1 * + 54 col2 FROM tab2 AS cor0
----
1647
3160
880

query I rowsort
SELECT DISTINCT - 28 + - col2 AS col0 FROM tab2
----
-54
-55
-66

query I rowsort
SELECT ALL - 93 FROM tab1, tab2 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT DISTINCT col1 * + ( col0 + + ( + col0 ) ) AS col0 FROM tab0
----
16198
4128
6790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6543
SELECT DISTINCT ( + col1 ) * - col0 / CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6543
SELECT DISTINCT ( + col1 ) * - col0 / CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6544
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6544
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col1 FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6545
SELECT + 57 DIV - 10 + - col2 + 0 FROM tab1
----
-101
-59
-62

skipif mysql # not compatible
query I rowsort label-6545
SELECT + 57 / - 10 + - col2 + 0 FROM tab1
----
-101
-59
-62

query I rowsort
SELECT ALL + 61 + 97 AS col2 FROM tab2
----
158
158
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6547
SELECT - - col0 DIV + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6547
SELECT - - col0 / + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 + col0 + + col0 AS col1 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT + - 26 AS col2 FROM tab1 cor0
----
-26
-26
-26

query I rowsort
SELECT + col0 + cor0.col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT - col0 * 1 * + col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + 13 * col0 * - col0 + col0 FROM tab1
----
-114
-53184
-83120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * - col0 col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + col0 * col2 * col2 + col2 FROM tab1 AS cor0
----
207993
737376
8802

query I rowsort
SELECT + cor0.col1 + col2 AS col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL col1 * - col0 + tab1.col0 AS col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT - col0 FROM tab2 WHERE NOT col2 > NULL
----

query I rowsort
SELECT DISTINCT - col0 FROM tab1 WHERE NOT NULL BETWEEN - col0 * - col1 + - col2 + - col1 / - col2 AND col0 + col1
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col1 NOT IN ( col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - tab0.col2 + - col0 * + col2 AS col0 FROM tab0
----
-36
-7380
-825

query I rowsort
SELECT + col1 * - col0 + - col0 AS col1 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL col0 + tab2.col1 * - col2 * + col0 AS col2 FROM tab2 WHERE NOT NULL BETWEEN col0 * + col1 AND NULL
----

query I rowsort
SELECT + col0 FROM tab1 WHERE + col2 <> ( NULL )
----

query I rowsort
SELECT DISTINCT col2 + + col1 FROM tab2 WHERE NOT ( NULL ) > ( + col0 * col1 )
----

query I rowsort
SELECT ALL - col0 + + tab0.col0 + - tab0.col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT col2 + tab1.col2 + col2 FROM tab1
----
162
171
288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 + col2 + - col2 col0 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6568
SELECT - col1 DIV - tab2.col0 + + col1 + col1 FROM tab2
----
118
34
66

skipif mysql # not compatible
query I rowsort label-6568
SELECT - col1 / - tab2.col0 + + col1 + col1 FROM tab2
----
118
34
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-6569
SELECT DISTINCT + col2 + + col1 + + tab1.col2 DIV - col1 FROM tab1
----
102
62
78

skipif mysql # not compatible
query I rowsort label-6569
SELECT DISTINCT + col2 + + col1 + + tab1.col2 / - col1 FROM tab1
----
102
62
78

query I rowsort
SELECT col0 + col0 * col2 + - col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL col2 FROM tab0 WHERE NOT ( col2 ) <= ( NULL )
----

query I rowsort
SELECT - col2 AS col0 FROM tab2 WHERE ( NULL ) <> tab2.col2 * col2 + + col1 * col0
----

query I rowsort
SELECT ALL + col0 * tab1.col2 AS col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL + tab2.col1 * - tab2.col0 AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - col1 - col1 * - col0 FROM tab1
----
1027
52
630

query I rowsort
SELECT ALL tab2.col2 * - col2 * + col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT col1 * + col2 - + col2 FROM tab2
----
1508
608
810

query I rowsort
SELECT DISTINCT col0 * + col1 + col2 AS col0 FROM tab0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-6579
SELECT - col1 * col0 + + col0 DIV - col0 FROM tab1
----
-1041
-641
-79

skipif mysql # not compatible
query I rowsort label-6579
SELECT - col1 * col0 + + col0 / - col0 FROM tab1
----
-1041
-641
-79

query I rowsort
SELECT - col1 FROM tab0 WHERE NOT - col2 = NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 + + col2 col0 FROM tab2 WHERE NOT col2 * col2 * + col1 NOT BETWEEN col1 + + col0 AND col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - + col0 col0 FROM tab2
----
-14
-156
-158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - + tab2.col1 col1 FROM tab2
----
-24
19
62

query III rowsort
SELECT * FROM tab1 WHERE NOT + col1 <> NULL
----

query I rowsort
SELECT col0 AS col0 FROM tab0 WHERE col2 NOT IN ( + col2 - col0 )
----
24
35
89

query I rowsort
SELECT + - col1 + cor0.col1 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6587
SELECT + + col2 DIV col0 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6587
SELECT + + col2 / col0 FROM tab1 cor0
----
0
1
18

query I rowsort
SELECT + col0 + - col0 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
1260
600
8010

query III rowsort
SELECT DISTINCT * FROM tab1 cor0 WHERE NOT ( NULL ) < ( NULL )
----

query I rowsort
SELECT col2 * col0 + col2 * col2 * - col2 FROM tab2 AS cor0
----
-15548
-19494
-51870

query I rowsort
SELECT ALL - col0 AS col1 FROM tab0 AS cor0 WHERE NOT ( NULL ) < NULL
----

query I rowsort
SELECT col0 + col1 * - cor0.col1 FROM tab1 cor0
----
-36
-673
-89

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT ( NULL ) NOT BETWEEN NULL AND + col2
----

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE ( NULL ) IN ( col0 )
----

query I rowsort
SELECT col0 * col1 + col2 * - col2 - - col2 FROM tab2 AS cor0
----
-485
-63
3952

query I rowsort
SELECT - + 9 * col2 + - col1 * + col0 FROM tab1 cor0
----
-1153
-1904
-564

query I rowsort
SELECT ALL - - ( - 34 ) * + col0 FROM tab0 AS cor0
----
-1190
-3026
-816

query I rowsort
SELECT col1 + cor0.col1 * cor0.col2 AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT 20 + - 38 FROM tab0 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + - col2 + - 2 FROM tab1 cor0
----
-56
-59
-98

query I rowsort
SELECT DISTINCT - - col1 + col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - 39 + col0 * + col1 * 42 AS col2 FROM tab2 AS cor0
----
193245
56367
9075

query I rowsort
SELECT + + 90 + col0 AS col0 FROM tab1 AS cor0
----
154
170
93

query I rowsort
SELECT ALL + 40 + col2 AS col1 FROM tab0 AS cor0
----
122
41
73

query I rowsort
SELECT DISTINCT 13 + - ( + col0 ) FROM tab1 AS cor0
----
-51
-67
10

query I rowsort
SELECT col0 * 31 + col1 AS col2 FROM tab0 AS cor0
----
1182
2850
830

query I rowsort
SELECT ALL tab2.col2 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6608
SELECT tab0.col2 DIV cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to f9d52149f37586061733a2a7a4974850

skipif mysql # not compatible
query I rowsort label-6608
SELECT tab0.col2 / cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to f9d52149f37586061733a2a7a4974850

query I rowsort
SELECT ALL 16 AS col2 FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT + 55 + + col0 FROM tab0 AS cor0
----
144
79
90

query I rowsort
SELECT - ( 77 ) * col2 + 40 FROM tab0 AS cor0
----
-2501
-37
-6274

query I rowsort
SELECT DISTINCT - 8 * col0 AS col1 FROM tab1 AS cor0
----
-24
-512
-640

onlyif mysql # use DIV operator for integer division
query I rowsort label-6613
SELECT DISTINCT - - col0 DIV + col2 + + col0 * - 78 col0 FROM tab1 AS cor0
----
-234
-4991
-6240

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6613
SELECT DISTINCT - - col0 / + col2 + + col0 * - 78 col0 FROM tab1 AS cor0
----
-234
-4991
-6240

query I rowsort
SELECT DISTINCT - col2 * + col2 + - col0 * - ( + cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-297
34
574

query I rowsort
SELECT - 84 FROM tab1 cor0
----
-84
-84
-84

query I rowsort
SELECT ALL - 12 * + col0 AS col0 FROM tab0 AS cor0
----
-1068
-288
-420

query I rowsort
SELECT ALL - + col2 * + 22 + col2 AS col2 FROM tab1 AS cor0
----
-1134
-1197
-2016

query I rowsort
SELECT ALL - col2 + - ( col2 ) FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - - col2 * ( 27 ) FROM tab0 AS cor0
----
2214
27
891

query I rowsort
SELECT col0 * - col1 - ( col1 ) FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT ALL col0 + - col0 * 66 * - col0 FROM tab0 AS cor0
----
38040
522875
80885

query I rowsort
SELECT + 0 * - col1 + col0 * ( - col1 ) AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT 43 * + col1 FROM tab1
----
1118
430
559

query I rowsort
SELECT ALL tab1.col0 + 31 AS col2 FROM tab1
----
111
34
95

query I rowsort
SELECT + col0 * + ( 42 + + col1 ) AS col0 FROM tab0
----
11837
3072
4865

query I rowsort
SELECT - col2 * - ( col1 ) + + tab2.col0 AS col0 FROM tab2
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-6627
SELECT - col0 DIV + 23 FROM tab0
----
-1
-1
-3

skipif mysql # not compatible
query I rowsort label-6627
SELECT - col0 / + 23 FROM tab0
----
-1
-1
-3

query I rowsort
SELECT DISTINCT col1 * 38 + - col0 * - col0 FROM tab1
----
4476
6894
997

query I rowsort
SELECT col0 - - ( + col0 ) * col2 AS col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT DISTINCT + col0 * + ( + 6 ) + col0 AS col1 FROM tab2
----
49
546
553

query I rowsort
SELECT ALL col1 + ( col1 + col2 ) AS col2 FROM tab1
----
106
122
77

query I rowsort
SELECT ALL col1 + col0 * - 85 AS col2 FROM tab0 AS cor0
----
-1954
-2878
-7474

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 1 * col1 * col0 col2 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL col2 * + 11 + col0 AS col0 FROM tab0 AS cor0
----
387
46
991

onlyif mysql # use DIV operator for integer division
query I rowsort label-6635
SELECT col2 DIV + 79 AS col2 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6635
SELECT col2 / + 79 AS col2 FROM tab0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6636
SELECT DISTINCT - col2 * 97 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
-1
-37
-87

skipif mysql # not compatible
query I rowsort label-6636
SELECT DISTINCT - col2 * 97 / cor0.col1 AS col1 FROM tab0 AS cor0
----
-1
-37
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 32 * 82 * + cor0.col1 col1 FROM tab2 AS cor0
----
154875
44625
81375

onlyif mysql # use DIV operator for integer division
query I rowsort label-6638
SELECT cor0.col1 DIV - cor1.col0 AS col0 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 37f4fda77b3e2709baab31a94e3f7c12

skipif mysql # not compatible
query I rowsort label-6638
SELECT cor0.col1 / - cor1.col0 AS col0 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 37f4fda77b3e2709baab31a94e3f7c12

onlyif mysql # use DIV operator for integer division
query I rowsort label-6639
SELECT - col1 + 12 DIV col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6639
SELECT - col1 + 12 / col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + + col1 + ( col1 ) FROM tab1 AS cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6641
SELECT col0 DIV tab0.col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6641
SELECT col0 / tab0.col2 FROM tab0
----
0
1
35

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
-1
-33
-82

query I rowsort
SELECT ALL 72 * 61 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 1179360400988971aed4b9c1512d08e3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6644
SELECT ALL cor0.col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6644
SELECT ALL cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 * 43 FROM tab0 cor0
----
1032
1505
3827

query I rowsort
SELECT DISTINCT + cor0.col1 * + ( + col2 ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + 49 FROM tab2, tab2 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 67 * col1 + - col2 col2 FROM tab2 AS cor0
----
1101
2050
3927

query I rowsort
SELECT DISTINCT + cor0.col2 + - 38 FROM tab2 AS cor0
----
-11
-12
0

query I rowsort
SELECT ALL ( col1 * - col0 ) AS col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + col2 * + col1 + - col1 AS col0 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT - col0 * col0 + cor0.col2 AS col0 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-6653
SELECT + 27 DIV 68 + + col1 AS col0 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6653
SELECT + 27 / 68 + + col1 AS col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT ALL cor0.col1 + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - - col1 + ( - cor0.col2 * + col2 ) AS col1 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT ALL - cor0.col1 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL + col2 * + col2 * 71 FROM tab1
----
207036
230679
654336

query I rowsort
SELECT DISTINCT + cor0.col0 AS col0 FROM tab1, tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 31 AS col1 FROM tab2
----
31

query I rowsort
SELECT 78 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT ALL - cor0.col1 * col1 + + ( cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-272
-3422
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-6662
SELECT + 9 + - col1 DIV + ( + col0 ) + - cor0.col0 FROM tab1 cor0
----
-2
-55
-71

skipif mysql # not compatible
query I rowsort label-6662
SELECT + 9 + - col1 / + ( + col0 ) + - cor0.col0 FROM tab1 cor0
----
-2
-55
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col0 col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - ( col2 ) * 70 * 61 FROM tab2 AS cor0
----
-111020
-115290
-162260

query I rowsort
SELECT - cor0.col2 * + col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + + col1 - 30 AS col2 FROM tab2 cor0
----
-13
1
29

query I rowsort
SELECT + + cor0.col1 * + col2 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + ( 84 ) + + col1 * + col2 col2 FROM tab2 AS cor0
----
1677
747
952

query I rowsort
SELECT ALL - 51 FROM tab1
----
-51
-51
-51

query I rowsort
SELECT ALL - tab2.col1 * + tab2.col2 FROM tab2
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + col1 col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col1 * ( + col0 * - col2 ) FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6673
SELECT col2 + col0 DIV + col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6673
SELECT col2 + col0 / + col1 FROM tab0
----
1
33
82

query I rowsort
SELECT + tab0.col2 + - tab0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 3b143560120db39ddcee311b43b28291

onlyif mysql # use DIV operator for integer division
query I rowsort label-6675
SELECT + col0 DIV - col0 + - 84 FROM tab2 AS cor0
----
-85
-85
-85

skipif mysql # not compatible
query I rowsort label-6675
SELECT + col0 / - col0 + - 84 FROM tab2 AS cor0
----
-85
-85
-85

query I rowsort
SELECT + + col2 + cor0.col2 AS col1 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT DISTINCT col1 + + col1 * - tab1.col1 AS col1 FROM tab1
----
-156
-650
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6678
SELECT col1 + + CAST( 36 AS SIGNED ) DIV + col0 AS col1 FROM tab0 AS cor0
----
87
91
98

skipif mysql # not compatible
query I rowsort label-6678
SELECT col1 + + CAST ( 36 AS INTEGER ) / + col0 AS col1 FROM tab0 AS cor0
----
87
91
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6679
SELECT col1 * + CAST( 29 AS SIGNED ) + col2 FROM tab0 AS cor0
----
2527
2721
2814

skipif mysql # not compatible
query I rowsort label-6679
SELECT col1 * + CAST ( 29 AS INTEGER ) + col2 FROM tab0 AS cor0
----
2527
2721
2814

query I rowsort
SELECT DISTINCT - col0 - 15 * - 53 * col0 FROM tab0 AS cor0
----
19056
27790
70666

query I rowsort
SELECT ALL + col0 * - col0 * + col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6682
SELECT ALL - col1 + CAST( NULL AS SIGNED ) * col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6682
SELECT ALL - col1 + CAST ( NULL AS INTEGER ) * col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 63 * - 32 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 51e375e0b88c9e3543f3ffe44ac1cf17

query I rowsort
SELECT - 90 + tab0.col0 AS col2 FROM tab0, tab2, tab2 cor0
----
27 values hashing to c36f1977a2495017a8db5442a73d1b94

query I rowsort
SELECT - ( col2 ) + + col1 + + 61 FROM tab0 AS cor0
----
114
157
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6686
SELECT - - 75 DIV col1 AS col0 FROM tab2 cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-6686
SELECT - - 75 / col1 AS col0 FROM tab2 cor0
----
1
2
4

query I rowsort
SELECT + col0 * col2 + + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL - - col2 - - col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6689
SELECT + cor0.col1 + + col1 DIV ( - col2 + col1 ) FROM tab0 cor0
----
101
87
98

skipif mysql # not compatible
query I rowsort label-6689
SELECT + cor0.col1 + + col1 / ( - col2 + col1 ) FROM tab0 cor0
----
101
87
98

query I rowsort
SELECT - col0 * + col1 + col0 * col0 * col0 FROM tab0 AS cor0
----
11760
39480
696870

query I rowsort
SELECT ALL 73 * col2 AS col1 FROM tab2
----
1898
1971
2774

onlyif mysql # use DIV operator for integer division
query I rowsort label-6692
SELECT col2 DIV 59 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6692
SELECT col2 / 59 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - 45 FROM tab1, tab0 AS cor0
----
9 values hashing to 71160abf09589695379a70558726f0ba

query I rowsort
SELECT + 32 * col1 FROM tab0
----
2752
2912
3104

query I rowsort
SELECT DISTINCT + col2 * - col0 * col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT - 37 + - col1 FROM tab1 AS cor0
----
-47
-50
-63

query I rowsort
SELECT DISTINCT + + 24 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
50
51
62

query I rowsort
SELECT ( + cor0.col0 ) + + ( col1 * cor0.col1 ) FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT + + ( col0 ) * col0 + + ( col1 ) AS col2 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6700
SELECT ALL col0 + + col1 DIV - col0 FROM tab2 AS cor0
----
3
78
79

skipif mysql # not compatible
query I rowsort label-6700
SELECT ALL col0 + + col1 / - col0 FROM tab2 AS cor0
----
3
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6701
SELECT col0 * col1 DIV - tab0.col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6701
SELECT col0 * col1 / - tab0.col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT col2 + - col1 * 35 AS col0 FROM tab0 AS cor0
----
-2977
-3103
-3394

query I rowsort
SELECT ALL + col1 * 60 AS col2 FROM tab2 cor0
----
1020
1860
3540

query I rowsort
SELECT DISTINCT + col1 + - col2 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col0 + + ( 89 * col1 + 96 ) FROM tab2 AS cor0
----
1688
2862
5425

query I rowsort
SELECT DISTINCT col1 + col2 * + 46 AS col1 FROM tab2 AS cor0
----
1255
1273
1765

query I rowsort
SELECT ALL col0 + + col2 * ( col1 ) + + col2 FROM tab0
----
133
2895
7633

query I rowsort
SELECT tab1.col0 + col2 * - ( col0 ) + col2 * 49 AS col0 FROM tab1
----
-2896
-791
2487

onlyif mysql # use DIV operator for integer division
query I rowsort label-6709
SELECT 75 * col2 DIV - 72 FROM tab1
----
-100
-56
-59

skipif mysql # not compatible
query I rowsort label-6709
SELECT 75 * col2 / - 72 FROM tab1
----
-100
-56
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6710
SELECT DISTINCT - 94 DIV - tab0.col1 + col1 + 51 FROM tab0
----
138
143
148

skipif mysql # not compatible
query I rowsort label-6710
SELECT DISTINCT - 94 / - tab0.col1 + col1 + 51 FROM tab0
----
138
143
148

query I rowsort
SELECT DISTINCT col1 + + col1 * col0 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL - tab2.col0 + col1 * col2 + col1 * tab2.col1 AS col0 FROM tab2
----
1791
4937
856

query I rowsort
SELECT 87 * - col1 AS col2 FROM tab1
----
-1131
-2262
-870

query I rowsort
SELECT + 30 AS col0 FROM tab2
----
30
30
30

query I rowsort
SELECT ALL - 9 - + cor0.col0 * + col0 AS col1 FROM tab0 AS cor0
----
-1234
-585
-7930

query I rowsort
SELECT DISTINCT - col1 * col1 + + col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL - 62 + col1 * col2 AS col2 FROM tab0 AS cor0
----
2776
35
7400

query I rowsort
SELECT DISTINCT + col2 + + 3 + + col0 * ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-105
-3588
-7581

query I rowsort
SELECT DISTINCT + col0 * col1 + col2 + - ( - col0 * col0 ) FROM tab0 AS cor0
----
16102
2673
4621

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 60 col1 FROM tab2 AS cor0
----
-60
-60
-60

query I rowsort
SELECT DISTINCT + ( + 78 ) * col1 FROM tab1 cor0
----
1014
2028
780

query I rowsort
SELECT + 29 AS col0 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT + col1 - 30 AS col2 FROM tab1
----
-17
-20
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 75 col0 FROM tab2
----
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6725
SELECT - CAST( NULL AS SIGNED ) * 54 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6725
SELECT - CAST ( NULL AS INTEGER ) * 54 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6726
SELECT ALL - CAST( 28 AS SIGNED ) + cor0.col2 AS col2 FROM tab1 AS cor0
----
26
29
68

skipif mysql # not compatible
query I rowsort label-6726
SELECT ALL - CAST ( 28 AS INTEGER ) + cor0.col2 AS col2 FROM tab1 AS cor0
----
26
29
68

query I rowsort
SELECT - - 36 * - 18 FROM tab2 AS cor0
----
-648
-648
-648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 79 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6729
SELECT - tab0.col0 DIV 64 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6729
SELECT - tab0.col0 / 64 FROM tab0
----
-1
0
0

query I rowsort
SELECT DISTINCT - tab2.col0 + + ( - col1 ) AS col2 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT cor0.col0 * col2 * col1 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + - col2 + ( col1 ) * + col2 AS col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL col0 + + col1 * + col0 * - col2 FROM tab0 AS cor0
----
-3360
-664029
-68088

query I rowsort
SELECT col2 - 52 AS col2 FROM tab2 AS cor0
----
-14
-25
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 * - col0 col1 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT - col1 + - ( - col2 * col1 ) FROM tab1
----
1235
1378
560

query I rowsort
SELECT ( - ( + col0 ) ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + 82 * col2 FROM tab2 AS cor0
----
2132
2214
3116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 44 col1 FROM tab1 cor0
----
-44

query I rowsort
SELECT - - col1 + + col2 + + col2 AS col0 FROM tab0 AS cor0
----
152
255
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - cor0.col0 * cor0.col1 col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + 51 + 21 FROM tab0 cor0
----
72
72
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6743
SELECT + CAST( NULL AS SIGNED ) * - 25 + cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6743
SELECT + CAST ( NULL AS INTEGER ) * - 25 + cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6745
SELECT ALL 93 + - col1 * + col0 * + CAST( NULL AS SIGNED ) + col1 * cor0.col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6745
SELECT ALL 93 + - col1 * + col0 * + CAST ( NULL AS INTEGER ) + col1 * cor0.col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 * + col0 + + col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT ALL - ( - col1 ) * col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL ( + col0 ) + - col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 43 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6750
SELECT + + CAST( + 82 AS SIGNED ) + + col1 AS col0 FROM tab1 AS cor0
----
108
92
95

skipif mysql # not compatible
query I rowsort label-6750
SELECT + + CAST ( + 82 AS INTEGER ) + + col1 AS col0 FROM tab1 AS cor0
----
108
92
95

query I rowsort
SELECT + + 87 * 82 + + col0 AS col0 FROM tab0 cor0
----
7158
7169
7223

query I rowsort
SELECT - col2 * + col0 - col0 AS col2 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT DISTINCT + - 64 * + col1 + 67 AS col2 FROM tab0 AS cor0
----
-5437
-5757
-6141

query I rowsort
SELECT + 82 * col0 + + 86 AS col1 FROM tab0 cor0
----
2054
2956
7384

onlyif mysql # use DIV operator for integer division
query I rowsort label-6755
SELECT DISTINCT - col1 DIV - cor0.col1 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-6755
SELECT DISTINCT - col1 / - cor0.col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT DISTINCT - 98 AS col2 FROM tab2 AS cor0
----
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6757
SELECT ALL + cor0.col2 + + col2 DIV + cor0.col1 + + col0 * - col1 AS col2 FROM tab0 cor0
----
-2031
-3394
-8017

skipif mysql # not compatible
query I rowsort label-6757
SELECT ALL + cor0.col2 + + col2 / + cor0.col1 + + col0 * - col1 AS col2 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT - - 62 + + cor0.col0 FROM tab0 AS cor0
----
151
86
97

query I rowsort
SELECT + + col0 * - cor0.col1 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + + col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6761
SELECT + - col2 DIV cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6761
SELECT + - col2 / cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col1 * ( col1 ) col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT + col1 * 81 FROM tab1 AS cor0
----
1053
2106
810

query I rowsort
SELECT + + 54 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

onlyif mysql # use DIV operator for integer division
query I rowsort label-6765
SELECT + col0 + 85 DIV col2 AS col1 FROM tab1 AS cor0
----
4
65
80

skipif mysql # not compatible
query I rowsort label-6765
SELECT + col0 + 85 / col2 AS col1 FROM tab1 AS cor0
----
4
65
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - ( - col2 ) * col1 col1 FROM tab1 AS cor0
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-6767
SELECT 88 DIV + 57 col1 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6767
SELECT 88 / + 57 col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT - cor0.col2 + + ( - col0 ) AS col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL - + col2 * 13 AS col0 FROM tab2 AS cor0
----
-338
-351
-494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 col0 FROM tab2
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6771
SELECT ALL - CAST( col0 AS SIGNED ) + - col1 * col2 FROM tab1
----
-1328
-1407
-634

skipif mysql # not compatible
query I rowsort label-6771
SELECT ALL - CAST ( col0 AS INTEGER ) + - col1 * col2 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT - col2 * col2 * col1 + - col0 AS col0 FROM tab1 AS cor0
----
-119888
-32554
-75819

query I rowsort
SELECT 76 * - col0 AS col1 FROM tab0
----
-1824
-2660
-6764

query I rowsort
SELECT - col1 * col2 * - col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT 69 AS col0 FROM tab2
----
69

query I rowsort
SELECT - tab0.col0 + tab0.col2 FROM tab0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6777
SELECT ALL + col1 DIV col2 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6777
SELECT ALL + col1 / col2 AS col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 24 col2 FROM tab1
----
24
24
24

query I rowsort
SELECT + col0 * col2 + 42 FROM tab2 AS cor0
----
2070
231
3044

query I rowsort
SELECT + 95 + - col0 AS col1 FROM tab1 AS cor0
----
15
31
92

query I rowsort
SELECT ALL - + col0 * col1 + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - + ( - col2 ) + 37 FROM tab2 AS cor0
----
63
64
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col0 + - 14 * - 81 + col2 col0 FROM tab1 AS cor0
----
1350
4839
8910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + col1 col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - ( + col2 ) * col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - - 57 + + col0 FROM tab1 AS cor0
----
121
137
60

query I rowsort
SELECT DISTINCT ( - 81 ) AS col2 FROM tab0 AS cor0
----
-81

query I rowsort
SELECT - cor2.col0 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT ALL - col2 + col1 + + col1 * - col2 * 86 AS col2 FROM tab1 cor0
----
-107411
-120772
-49067

query I rowsort
SELECT DISTINCT - 4 - col0 FROM tab1 AS cor0
----
-68
-7
-84

query I rowsort
SELECT DISTINCT 5 AS col1 FROM tab2, tab2 AS cor0
----
5

query I rowsort
SELECT 27 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT col2 + + col0 * col0 + - ( col0 ) * col2 FROM tab0
----
-183
1191
705

query I rowsort
SELECT DISTINCT 52 + col0 * - col2 AS col0 FROM tab1
----
-110
-3596
-7628

query I rowsort
SELECT ( + 77 ) * col0 FROM tab0
----
1848
2695
6853

onlyif mysql # use DIV operator for integer division
query I rowsort label-6797
SELECT col0 + ( col0 ) DIV col0 AS col1 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6797
SELECT col0 + ( col0 ) / col0 AS col1 FROM tab1
----
4
65
81

query I rowsort
SELECT - col2 + tab0.col0 * + col2 + col1 * 5 FROM tab0
----
1189
519
7671

query I rowsort
SELECT tab2.col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT col2 * - 67 FROM tab0
----
-2211
-5494
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-6801
SELECT + col2 + ( col2 ) DIV - ( - col1 ) FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6801
SELECT + col2 + ( col2 ) / - ( - col1 ) FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 98 col0 FROM tab2
----
98

query I rowsort
SELECT ALL tab2.col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 85 FROM tab0, tab1, tab0 cor0
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6805
SELECT DISTINCT tab1.col2 * col0 DIV col1 FROM tab1
----
364
590
6

skipif mysql # not compatible
query I rowsort label-6805
SELECT DISTINCT tab1.col2 * col0 / col1 FROM tab1
----
364
590
6

query I rowsort
SELECT ALL tab1.col2 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + + col2 * ( ( col1 ) ) - col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT + col0 * 66 FROM tab1 AS cor0
----
198
4224
5280

query I rowsort
SELECT + - col0 * col1 - 59 FROM tab0 AS cor0
----
-2123
-3454
-8158

query I rowsort
SELECT - - col2 * - 38 FROM tab0 AS cor0
----
-1254
-3116
-38

query I rowsort
SELECT DISTINCT - 39 * + col2 * 86 AS col0 FROM tab0
----
-110682
-275028
-3354

query I rowsort
SELECT ALL - 20 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

query I rowsort
SELECT ALL + - col2 + - col2 * - col2 AS col0 FROM tab1 AS cor0
----
2862
3192
9120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6814
SELECT + - col2 + CAST( NULL AS SIGNED ) * col1 * cor0.col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6814
SELECT + - col2 + CAST ( NULL AS INTEGER ) * col1 * cor0.col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 80 + col0 * cor0.col2 + + ( - col0 ) AS col2 FROM tab0 AS cor0
----
7289
80
848

query I rowsort
SELECT + cor0.col1 + + col1 * + cor0.col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - - col1 + - col2 * - col0 * - col0 AS col0 FROM tab2 AS cor0
----
-1292
-158125
-237141

query I rowsort
SELECT DISTINCT ( col0 ) * col1 * 48 + 98 + col1 AS col0 FROM tab1 AS cor0
----
30828
3868
50031

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col1 * - 61 - col2 col1 FROM tab2 AS cor0
----
1864
3573
999

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6820
SELECT - + CAST( NULL AS SIGNED ) * cor0.col0 * + cor0.col0 + ( col1 ) * - col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6820
SELECT - + CAST ( NULL AS INTEGER ) * cor0.col0 * + cor0.col0 + ( col1 ) * - col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 13 FROM tab2 AS cor0
----
13

query I rowsort
SELECT ALL - ( + 63 ) AS col1 FROM tab1 AS cor0
----
-63
-63
-63

query I rowsort
SELECT - + col1 * + col2 + + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT col1 * col1 + col2 * + col0 AS col1 FROM tab2 AS cor0
----
1150
3291
5509

query I rowsort
SELECT ALL - ( + col1 ) + col0 * + col1 * - col2 AS col0 FROM tab2 AS cor0
----
-119711
-51051
-5890

query I rowsort
SELECT ALL + - ( cor0.col2 ) * - col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - col2 * + col1 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6828
SELECT + ( - col2 ) * - cor0.col2 * CAST( - ( - col2 ) AS SIGNED ) - - 23 FROM tab2 AS cor0
----
17599
19706
54895

skipif mysql # not compatible
query I rowsort label-6828
SELECT + ( - col2 ) * - cor0.col2 * CAST ( - ( - col2 ) AS INTEGER ) - - 23 FROM tab2 AS cor0
----
17599
19706
54895

onlyif mysql # use DIV operator for integer division
query I rowsort label-6829
SELECT ALL + col0 DIV - ( col0 * - 93 ) FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6829
SELECT ALL + col0 / - ( col0 * - 93 ) FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT tab1.col0 * 70 AS col0 FROM tab1
----
210
4480
5600

query I rowsort
SELECT col2 - - ( col2 ) FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT + cor0.col2 + - cor0.col0 AS col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - + 1 * col0 + col2 + col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - + 36 + + col1 * ( + cor0.col0 ) AS col2 FROM tab0 AS cor0
----
2028
3359
8063

onlyif mysql # use DIV operator for integer division
query I rowsort label-6835
SELECT - cor0.col2 DIV col2 + col1 + + col2 FROM tab1 AS cor0
----
108
66
79

skipif mysql # not compatible
query I rowsort label-6835
SELECT - cor0.col2 / col2 + col1 + + col2 FROM tab1 AS cor0
----
108
66
79

query I rowsort
SELECT cor0.col0 + - col0 * - 61 AS col0 FROM tab1 AS cor0
----
186
3968
4960

query I rowsort
SELECT + col2 + - col2 + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - 19 * - col2 + ( col1 ) FROM tab2 AS cor0
----
544
553
739

query I rowsort
SELECT DISTINCT - 0 * - col2 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT col0 * - col2 + + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL 0 * + col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + col1 * + col0 + col2 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + + col1 * cor0.col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT 99 * cor0.col1 AS col2 FROM tab0, tab1 AS cor0
----
1287
2574
990

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 55 ) col0 FROM tab0
----
55
55
55

query I rowsort
SELECT col2 * cor0.col1 * col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL + 5 * + col1 AS col1 FROM tab0
----
430
455
485

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6848
SELECT - - col1 + ( col2 ) * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6848
SELECT - - col1 + ( col2 ) * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * 81 * col2 + col2 AS col0 FROM tab2
----
15336
164294
243200

query I rowsort
SELECT ALL - cor0.col1 + col0 AS col0 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT cor0.col2 + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col0 + - col2 AS col1 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT - 77 * col1 FROM tab1 cor0
----
-1001
-2002
-770

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 63 * col1 - col0 col1 FROM tab0 AS cor0
----
-5442
-5822
-6146

query I rowsort
SELECT DISTINCT + 80 * col2 AS col1 FROM tab0 AS cor0
----
2640
6560
80

query I rowsort
SELECT DISTINCT + 71 + col1 FROM tab2 cor0
----
102
130
88

query I rowsort
SELECT DISTINCT + + col2 * col2 + + col1 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT ALL + 94 * col0 - col2 FROM tab0 AS cor0
----
2223
3289
8284

query I rowsort
SELECT - col2 + 21 FROM tab0
----
-12
-61
20

query I rowsort
SELECT ALL + col0 * + cor0.col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT col2 * - 16 FROM tab2 AS cor0
----
-416
-432
-608

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col0 * CAST ( - col1 AS REAL ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col1 * ( col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + + col0 * col0 + + col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT - - cor0.col0 + col1 * - 46 FROM tab2 AS cor0
----
-1419
-2636
-703

query I rowsort
SELECT - cor0.col1 + - 30 AS col0 FROM tab0 cor0
----
-116
-121
-127

query I rowsort
SELECT DISTINCT col2 * - 22 FROM tab0 AS cor0
----
-1804
-22
-726

query I rowsort
SELECT - col0 * + col1 * 0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - 7 col1 FROM tab2 AS cor0
----
-182
-189
-266

skipif mysql # not compatible
query I rowsort
SELECT ALL + + col0 * - CAST ( - col1 AS REAL ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 * 49 col2 FROM tab1 AS cor0
----
-1274
-490
-637

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL cor0.col0 * - 43 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 1dfd6a0733c31352bbeb4776e880050b

query I rowsort
SELECT DISTINCT col0 * - 55 - col2 AS col2 FROM tab2 AS cor0
----
-412
-4316
-4383

query I rowsort
SELECT DISTINCT 35 - 3 FROM tab0 AS cor0
----
32

query I rowsort
SELECT ALL + ( - ( - col2 ) ) AS col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6877
SELECT + col1 + - col0 DIV col0 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-6877
SELECT + col1 + - col0 / col0 FROM tab2 AS cor0
----
16
30
58

query I rowsort
SELECT + + cor0.col2 * col2 * + col2 FROM tab2 AS cor0
----
17576
19683
54872

query I rowsort
SELECT DISTINCT 58 * + 31 AS col1 FROM tab0 AS cor0
----
1798

query I rowsort
SELECT DISTINCT + 54 AS col0 FROM tab0 AS cor0
----
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-6881
SELECT DISTINCT - 76 + 87 DIV col1 + col1 AS col1 FROM tab2 AS cor0
----
-16
-43
-54

skipif mysql # not compatible
query I rowsort label-6881
SELECT DISTINCT - 76 + 87 / col1 + col1 AS col1 FROM tab2 AS cor0
----
-16
-43
-54

query I rowsort
SELECT DISTINCT + ( 45 ) AS col2 FROM tab1 AS cor0
----
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6883
SELECT + ( + col1 ) DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-6883
SELECT + ( + col1 ) / col0 AS col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT - + 70 * - col1 FROM tab1 AS cor0
----
1820
700
910

query I rowsort
SELECT + col0 * 30 AS col1 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT + + col0 * 33 + col2 + - 23 AS col1 FROM tab2 AS cor0
----
235
2577
2622

query I rowsort
SELECT DISTINCT - 16 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
-16

query I rowsort
SELECT 40 * 4 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 657a59eb2ad19b061a701df88105c303

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6889
SELECT + cor0.col0 / CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6889
SELECT + cor0.col0 / CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - ( - 8 ) AS col0 FROM tab1
----
8
8
8

skipif mysql # not compatible
query I rowsort
SELECT - col0 + - CAST ( - ( col2 ) AS REAL ) AS col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - - 89 AS col2 FROM tab0, tab2 AS cor0
----
89

query I rowsort
SELECT - + cor0.col0 * - col0 + 36 FROM tab0 AS cor0
----
1261
612
7957

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6894
SELECT cor0.col1 * - CAST( NULL AS SIGNED ) + ( cor0.col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6894
SELECT cor0.col1 * - CAST ( NULL AS INTEGER ) + ( cor0.col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col2 + 17 * col0 AS col0 FROM tab0 AS cor0
----
1431
375
594

query I rowsort
SELECT + 87 + 28 FROM tab0, tab2 AS cor0
----
9 values hashing to 8ea29c11e2d920a09e8656cafe5a9642

query I rowsort
SELECT - col0 + + col0 + tab1.col2 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT - col0 + ( + col2 ) AS col0 FROM tab1
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6899
SELECT + col2 * CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6899
SELECT + col2 * CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + 2 AS col0 FROM tab1 AS cor0
----
56
59
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6901
SELECT col0 DIV - col1 AS col1 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6901
SELECT col0 / - col1 AS col1 FROM tab2
----
-1
-4
0

query I rowsort
SELECT + 52 * + col0 AS col0 FROM tab0 AS cor0
----
1248
1820
4628

query I rowsort
SELECT - 2 * + col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - - col1 * col2 * col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT + cor1.col1 + - cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 01fd1afbe3d10d148c21df449f74d57c

query I rowsort
SELECT tab2.col2 * col2 * - tab2.col1 + col2 * col1 FROM tab2
----
-21762
-23902
-38350

query I rowsort
SELECT - col1 + col1 * tab2.col0 * col1 AS col1 FROM tab2
----
22814
271459
6696

query I rowsort
SELECT + + cor0.col2 * - cor0.col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + + cor0.col0 * col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT - + ( - col2 ) AS col2 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * - col0 * + col1 col1 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT - col2 * cor0.col0 + - col0 AS col1 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT 40 * + col2 * + col1 AS col2 FROM tab2 cor0
----
25840
33480
61360

query I rowsort
SELECT DISTINCT + 27 FROM tab0 cor0
----
27

query I rowsort
SELECT ALL - 93 * col1 AS col2 FROM tab2 AS cor0
----
-1581
-2883
-5487

query I rowsort
SELECT ALL - col1 * - col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + col0 + - col1 * - col2 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - cor0.col0 + cor0.col1 * col0 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-6919
SELECT ALL - - col1 + - col2 DIV + col0 FROM tab0 cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-6919
SELECT ALL - - col1 + - col2 / + col0 FROM tab0 cor0
----
85
91
97

query I rowsort
SELECT ALL 0 * + cor0.col0 FROM tab2, tab0 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + - col0 * + col1 + col1 AS col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - col1 - - 84 FROM tab1
----
58
71
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-6923
SELECT ( col1 ) DIV + col1 - col2 FROM tab2
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-6923
SELECT ( col1 ) / + col1 - col2 FROM tab2
----
-25
-26
-37

query I rowsort
SELECT ( - ( col0 ) ) AS col2 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + 89 AS col0 FROM tab2
----
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6926
SELECT ALL - tab0.col0 DIV - col2 + col2 col0 FROM tab0
----
33
36
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6926
SELECT ALL - tab0.col0 / - col2 + col2 col0 FROM tab0
----
33
36
83

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE + col1 + col2 <> ( NULL )
----

query I rowsort
SELECT DISTINCT col0 + + col1 + - col1 * col1 AS col0 FROM tab2 AS cor0
----
-193
-3344
-923

query I rowsort
SELECT ALL + col1 + + tab1.col0 AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT - col0 * + col1 + col0 AS col0 FROM tab2 WHERE NOT NULL BETWEEN - col0 AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL <> + col0
----

query I rowsort
SELECT - col2 + - col1 * col0 * + tab2.col0 FROM tab2
----
-106135
-1546
-358982

query I rowsort
SELECT DISTINCT col2 * - col2 + + tab1.col1 AS col1 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT ALL - col2 * tab1.col1 * tab1.col1 + col2 AS col0 FROM tab1
----
-16128
-36450
-5643

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL IN ( col2 )
----

query I rowsort
SELECT ALL - col2 + + col0 FROM tab1 WHERE NULL NOT IN ( + col1 * col0 * + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col1 FROM tab2 cor0
----
-26
-27
-38

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE NULL IN ( + cor0.col2 )
----

query I rowsort
SELECT + col2 + col2 * col0 FROM tab0
----
36
7380
825

query I rowsort
SELECT - col2 + + col0 - tab1.col1 * + col2 FROM tab1
----
-1264
-1455
-563

query I rowsort
SELECT + col2 * col2 * - col2 + - tab0.col1 * col2 FROM tab0
----
-38775
-558830
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col2 * col1 col1 FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT DISTINCT col1 * col0 + + col1 * + tab0.col0 AS col2 FROM tab0
----
16198
4128
6790

onlyif mysql # use DIV operator for integer division
query I rowsort label-6944
SELECT + col1 - tab2.col1 DIV - col1 AS col1 FROM tab2
----
18
32
60

skipif mysql # not compatible
query I rowsort label-6944
SELECT + col1 - tab2.col1 / - col1 AS col1 FROM tab2
----
18
32
60

query I rowsort
SELECT ALL + col1 + tab0.col0 * - col0 * col0 FROM tab0
----
-13738
-42778
-704878

onlyif mysql # use DIV operator for integer division
query I rowsort label-6946
SELECT DISTINCT col1 DIV + col0 + tab2.col0 col2 FROM tab2
----
11
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6946
SELECT DISTINCT col1 / + col0 + tab2.col0 col2 FROM tab2
----
11
78
79

query I rowsort
SELECT + cor0.col1 * col1 + + col1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT - col0 * - tab1.col2 * - col2 + col0 AS col1 FROM tab1
----
-207872
-737200
-8745

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 col2 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT ALL + col2 * - col1 + col0 * col1 FROM tab1 cor0
----
-1326
-208
70

query I rowsort
SELECT DISTINCT - col2 * + col1 + col2 * col1 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - cor0.col2 - - cor0.col0 * + col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-6953
SELECT - col0 * + col0 + - col2 * col1 DIV col0 col0 FROM tab1 AS cor0
----
-4104
-477
-6415

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6953
SELECT - col0 * + col0 + - col2 * col1 / col0 col0 FROM tab1 AS cor0
----
-4104
-477
-6415

query I rowsort
SELECT ALL - col0 * tab0.col1 * + col1 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT + + col2 * col0 + - col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-6956
SELECT DISTINCT + col0 DIV col0 + + col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6956
SELECT DISTINCT + col0 / col0 + + col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ALL col1 * col0 + col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col2 - - col0 col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT + col1 * + col0 + - 44 FROM tab0 AS cor0
----
2020
3351
8055

query I rowsort
SELECT ALL col2 * - 15 FROM tab0 AS cor0
----
-1230
-15
-495

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6961
SELECT + - col1 * + CAST( NULL AS SIGNED ) / 90 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6961
SELECT + - col1 * + CAST ( NULL AS INTEGER ) / 90 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * - 80 + + ( - col0 ) * col0 AS col2 FROM tab0 cor0
----
-1305
-14481
-3216

query I rowsort
SELECT DISTINCT + - col1 + - 79 * + 33 + col1 FROM tab2 AS cor0
----
-2607

query I rowsort
SELECT ALL + tab2.col1 + tab2.col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT - col0 + 69 + - col2 FROM tab0 AS cor0
----
-102
12
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col0 + col0 * col2 col1 FROM tab2 AS cor0
----
2165
227
3098

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6967
SELECT ALL + col1 * CAST( NULL AS DECIMAL ) col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6967
SELECT ALL + col1 * CAST ( NULL AS REAL ) col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6968
SELECT ALL col2 / CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6968
SELECT ALL col2 / CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - + ( col2 ) * col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6970
SELECT + 76 + col2 * col2 DIV col0 FROM tab0 AS cor0
----
121
151
76

skipif mysql # not compatible
query I rowsort label-6970
SELECT + 76 + col2 * col2 / col0 FROM tab0 AS cor0
----
121
151
76

query I rowsort
SELECT ALL - col1 * - 49 FROM tab0
----
4214
4459
4753

onlyif mysql # use DIV operator for integer division
query I rowsort label-6972
SELECT DISTINCT col0 DIV ( + 88 ) AS col0 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-6972
SELECT DISTINCT col0 / ( + 88 ) AS col0 FROM tab1
----
0

query I rowsort
SELECT ALL - col0 * - col0 AS col2 FROM tab1
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col2 ) + col1 col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL - + col2 * col2 + - 71 AS col0 FROM tab2 AS cor0
----
-1515
-747
-800

query I rowsort
SELECT DISTINCT + + 69 + + cor0.col0 FROM tab2 AS cor0
----
147
148
76

query I rowsort
SELECT DISTINCT - + 72 AS col1 FROM tab0 AS cor0
----
-72

query I rowsort
SELECT ALL - col2 + + col2 * - col1 AS col2 FROM tab0 cor0
----
-2871
-7544
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 24 col0 FROM tab2 AS cor0
----
24
24
24

query I rowsort
SELECT + col2 * + col0 + - col1 AS col0 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-6981
SELECT - + col1 DIV - col0 + - col1 AS col1 FROM tab2 AS cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-6981
SELECT - + col1 / - col0 + - col1 AS col1 FROM tab2 AS cor0
----
-17
-27
-59

query I rowsort
SELECT ( + col2 + col0 ) FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 + - col0 + col0 * col1 col1 FROM tab0
----
14734
3129
3361

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 13 + + 8 col2 FROM tab0
----
-5
-5
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + 66 + - col1 + - tab2.col2 col0 FROM tab2
----
404
5063
5159

query I rowsort
SELECT DISTINCT + 24 AS col2 FROM tab1, tab2 AS cor0
----
24

query I rowsort
SELECT tab2.col2 + - col0 + + col1 AS col0 FROM tab2
----
-24
51
7

query I rowsort
SELECT DISTINCT ( + col1 ) + - tab0.col2 FROM tab0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6989
SELECT ALL + col2 + - col1 DIV cor0.col2 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6989
SELECT ALL + col2 + - col1 / cor0.col2 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + + col2 * col2 - col0 FROM tab0 AS cor0
----
-34
1065
6635

onlyif mysql # use DIV operator for integer division
query I rowsort label-6991
SELECT DISTINCT - col0 + - col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-6991
SELECT DISTINCT - col0 + - col1 / + col1 AS col0 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT DISTINCT + + 80 * - cor0.col1 + + 8 AS col2 FROM tab2 AS cor0
----
-1352
-2472
-4712

query I rowsort
SELECT - cor0.col1 * + cor0.col1 + + 11 + - col1 FROM tab1 AS cor0
----
-171
-691
-99

query I rowsort
SELECT + cor0.col0 * - cor0.col2 + + 33 FROM tab0 AS cor0
----
-2
-7265
-759

query I rowsort
SELECT DISTINCT + - 61 AS col1 FROM tab2 AS cor0
----
-61

query I rowsort
SELECT DISTINCT - + cor0.col1 * col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col1 + - col0 * - ( - col2 + - col2 ) FROM tab2 AS cor0
----
-347
-3997
-5987

query I rowsort
SELECT + col2 * col1 + col0 + - col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 93 * - tab0.col1 FROM tab0
----
-7998
-8463
-9021

query I rowsort
SELECT DISTINCT col0 + + col2 * - col0 * + col1 FROM tab1 AS cor0
----
-36416
-4209
-99760

query I rowsort
SELECT DISTINCT + col2 + col2 * + col0 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT 20 * col0 AS col0 FROM tab1
----
1280
1600
60

query I rowsort
SELECT tab1.col1 + col0 * 35 AS col0 FROM tab1
----
131
2250
2813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7004
SELECT - + col1 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7004
SELECT - + col1 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7005
SELECT - col0 + + CAST( NULL AS SIGNED ) * cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7005
SELECT - col0 + + CAST ( NULL AS INTEGER ) * cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col0 + col2 * - 71 AS col2 FROM tab1 AS cor0
----
-3831
-3983
-6736

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col0 + col2 col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT col0 + 55 AS col1 FROM tab0 AS cor0
----
144
79
90

query I rowsort
SELECT - col1 + - 32 FROM tab1 AS cor0
----
-42
-45
-58

query I rowsort
SELECT - col0 * - col0 + col1 AS col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT - + cor0.col2 * 55 AS col1 FROM tab2 AS cor0
----
-1430
-1485
-2090

query I rowsort
SELECT col0 * col0 * 59 + col1 * col0 * cor0.col1 FROM tab0 AS cor0
----
1204348
211488
401590

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7013
SELECT ALL - + CAST( col0 AS SIGNED ) col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7013
SELECT ALL - + CAST ( col0 AS INTEGER ) col1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7014
SELECT DISTINCT - + ( - col2 ) DIV + col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7014
SELECT DISTINCT - + ( - col2 ) / + col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ( - 10 ) + col1 * - ( - col2 ) AS col0 FROM tab0 AS cor0
----
2828
7452
87

query I rowsort
SELECT + + ( + col1 ) AS col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - 3 - + 82 AS col2 FROM tab2 AS cor0
----
-85

query I rowsort
SELECT DISTINCT - col2 - 82 FROM tab1 AS cor0
----
-136
-139
-178

onlyif mysql # use DIV operator for integer division
query I rowsort label-7019
SELECT ALL - col1 DIV - 32 + + col2 * - ( - cor0.col2 ) FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-7019
SELECT ALL - col1 / - 32 + + col2 * - ( - cor0.col2 ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + col0 * 60 AS col0 FROM tab1 AS cor0
----
180
3840
4800

query I rowsort
SELECT + 61 * - col0 + col0 + - col0 AS col0 FROM tab0 AS cor0
----
-1464
-2135
-5429

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - cor0.col1 ) + + col0 col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + + cor0.col1 - - cor0.col1 AS col0 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7024
SELECT - col1 + - col0 * - col0 + CAST( NULL AS SIGNED ) / tab1.col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7024
SELECT - col1 + - col0 * - col0 + CAST ( NULL AS INTEGER ) / tab1.col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7025
SELECT cor0.col1 + + col2 * - col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7025
SELECT cor0.col1 + + col2 * - col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * 41 AS col2 FROM tab0 AS cor0
----
-3526
-3731
-3977

query I rowsort
SELECT + - cor0.col0 AS col2 FROM tab0 cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7028
SELECT + CAST( + col2 AS SIGNED ) * cor0.col0 AS col2 FROM tab2 cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-7028
SELECT + CAST ( + col2 AS INTEGER ) * cor0.col0 AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL - 69 + col0 FROM tab0 cor0
----
-34
-45
20

query I rowsort
SELECT ALL - col0 * - col1 + - col1 AS col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-7031
SELECT DISTINCT - col2 * + col0 + + col1 DIV col2 FROM tab0 AS cor0
----
-7297
-790
62

skipif mysql # not compatible
query I rowsort label-7031
SELECT DISTINCT - col2 * + col0 + + col1 / col2 FROM tab0 AS cor0
----
-7297
-790
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7032
SELECT - cor0.col1 * - CAST( NULL AS SIGNED ) + 15 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7032
SELECT - cor0.col1 * - CAST ( NULL AS INTEGER ) + 15 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7033
SELECT + col0 DIV - 73 - col0 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-1344
-217
-4603

skipif mysql # not compatible
query I rowsort label-7033
SELECT + col0 / - 73 - col0 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-1344
-217
-4603

onlyif mysql # use DIV operator for integer division
query I rowsort label-7034
SELECT + col2 DIV col2 + + 42 AS col0 FROM tab0 AS cor0
----
43
43
43

skipif mysql # not compatible
query I rowsort label-7034
SELECT + col2 / col2 + + 42 AS col0 FROM tab0 AS cor0
----
43
43
43

query I rowsort
SELECT - col0 * - ( col0 ) + + col2 * - ( ( - cor0.col1 ) ) AS col2 FROM tab2 cor0
----
6887
7618
886

query I rowsort
SELECT - - col2 + ( col0 ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - - cor0.col0 * 5 AS col1 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT ( col0 ) * - cor0.col2 + - 9 + - cor0.col1 FROM tab0 AS cor0
----
-141
-7398
-887

query I rowsort
SELECT 60 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT DISTINCT + tab0.col1 + col1 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT col2 * + 58 AS col1 FROM tab1
----
3132
3306
5568

query I rowsort
SELECT col2 * col2 + col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT - + col0 * 78 + - col0 * 99 FROM tab0 AS cor0
----
-15753
-4248
-6195

query I rowsort
SELECT DISTINCT - cor1.col0 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
-7
-78
-79

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab0 AS cor2
----
86
91
97

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 20 AS REAL ) + col1 FROM tab1 AS cor0
----
30
33
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7047
SELECT + + CAST( 64 AS SIGNED ) + - col1 AS col2 FROM tab1 AS cor0
----
38
51
54

skipif mysql # not compatible
query I rowsort label-7047
SELECT + + CAST ( 64 AS INTEGER ) + - col1 AS col2 FROM tab1 AS cor0
----
38
51
54

query I rowsort
SELECT ALL col0 + - col0 * + cor0.col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT + 72 AS col2 FROM tab1 cor0
----
72

query I rowsort
SELECT col1 * col1 + col1 AS col1 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-7051
SELECT col2 * cor0.col1 + - col1 DIV + col0 + col1 FROM tab1 AS cor0
----
1261
1422
580

skipif mysql # not compatible
query I rowsort label-7051
SELECT col2 * cor0.col1 + - col1 / + col0 + col1 FROM tab1 AS cor0
----
1261
1422
580

query I rowsort
SELECT + - 33 * cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 19504a839b06313e8205a0a00a1ab0cc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col0 col0 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7054
SELECT DISTINCT + 95 + - col1 DIV col2 FROM tab1 cor0
----
95

skipif mysql # not compatible
query I rowsort label-7054
SELECT DISTINCT + 95 + - col1 / col2 FROM tab1 cor0
----
95

query I rowsort
SELECT - tab2.col1 * - tab2.col0 * + ( col1 ) AS col2 FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-7056
SELECT - 67 DIV tab1.col0 AS col2 FROM tab1
----
-1
-22
0

skipif mysql # not compatible
query I rowsort label-7056
SELECT - 67 / tab1.col0 AS col2 FROM tab1
----
-1
-22
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7057
SELECT ALL + col1 * + tab1.col1 DIV + col1 - + col1 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7057
SELECT ALL + col1 * + tab1.col1 / + col1 - + col1 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - - col2 - col1 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - + cor0.col2 * cor0.col0 * + col2 + cor0.col1 * cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
217932
80606
9374

query I rowsort
SELECT DISTINCT - col1 - 11 * cor0.col1 FROM tab1 AS cor0
----
-120
-156
-312

query I rowsort
SELECT ALL + ( col2 * - ( - col0 ) ) AS col0 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + ( + col2 ) - col2 col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT + col0 * - col1 + tab1.col2 * col1 FROM tab1
----
-70
1326
208

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7064
SELECT DISTINCT + col2 * CAST( NULL AS DECIMAL ) + - col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7064
SELECT DISTINCT + col2 * CAST ( NULL AS REAL ) + - col0 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - + col2 * col2 * col1 + - col0 AS col2 FROM tab1 AS cor0
----
-119888
-32554
-75819

query I rowsort
SELECT DISTINCT cor0.col2 + ( col0 ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - col2 * - ( 93 * - col2 ) AS col1 FROM tab2 AS cor0
----
-134292
-62868
-67797

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7068
SELECT ALL + col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7068
SELECT ALL + col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + col1 + cor0.col0 AS col0 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT ALL - + col1 * + col0 + ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT + cor0.col2 * - col2 + cor0.col2 FROM tab2 cor0
----
-1406
-650
-702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * ( 48 ) + col2 col0 FROM tab1 AS cor0
----
2646
2793
4704

query I rowsort
SELECT DISTINCT + col1 * col1 + + col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT col1 * col1 + 47 AS col2 FROM tab2 cor0
----
1008
336
3528

query I rowsort
SELECT DISTINCT 73 + col1 * col0 FROM tab2 AS cor0
----
1416
290
4675

query I rowsort
SELECT ALL - col0 * + col2 + ( col2 ) FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - - 46 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
-36
13
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-7078
SELECT 49 DIV + 97 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-7078
SELECT 49 / + 97 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT ALL + ( + tab0.col0 * 51 ) FROM tab0
----
1224
1785
4539

onlyif mysql # use DIV operator for integer division
query I rowsort label-7080
SELECT ALL 66 DIV col0 FROM tab2
----
0
0
9

skipif mysql # not compatible
query I rowsort label-7080
SELECT ALL 66 / col0 FROM tab2
----
0
0
9

query I rowsort
SELECT ALL col2 * col1 * + col2 AS col0 FROM tab2 AS cor0
----
22599
24548
39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col2 - + col2 * col2 col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT 95 + + col0 AS col0 FROM tab2 AS cor0
----
102
173
174

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col2 col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7085
SELECT + - col1 * CAST( NULL AS SIGNED ) * - 23 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7085
SELECT + - col1 * CAST ( NULL AS INTEGER ) * - 23 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * + 29 + col1 FROM tab0 AS cor0
----
1112
2672
782

query I rowsort
SELECT DISTINCT + tab2.col0 * col2 AS col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + tab0.col2 * - tab0.col1 AS col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - 29 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 56a8aa9e4c5d3c934d1853afeb22653e

query I rowsort
SELECT + ( tab0.col1 ) AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT 88 + + col0 AS col2 FROM tab0
----
112
123
177

onlyif mysql # use DIV operator for integer division
query I rowsort label-7092
SELECT DISTINCT + tab1.col0 DIV + col1 - + col0 AS col2 FROM tab1
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-7092
SELECT DISTINCT + tab1.col0 / + col1 - + col0 AS col2 FROM tab1
----
-3
-58
-74

query I rowsort
SELECT - col1 + col0 * tab0.col2 AS col2 FROM tab0
----
-62
706
7207

query I rowsort
SELECT + col0 + + col1 * col1 + col2 FROM tab2 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT + col2 + + col1 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL - col1 + + col1 * - tab2.col1 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT col2 * + col2 + + col0 * - col0 AS col1 FROM tab2 WHERE col1 >= NULL
----

query I rowsort
SELECT ALL - col1 AS col2 FROM tab0 WHERE NOT col2 IN ( col1 * col0 )
----
-86
-91
-97

query I rowsort
SELECT + col0 * + col2 + col0 * - tab0.col1 + - col1 * + col0 FROM tab0
----
-3336
-6755
-8900

query III rowsort
SELECT * FROM tab2 WHERE NOT - col0 BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT + col2 - tab1.col2 * - col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT tab1.col2 - - col0 FROM tab1 WHERE ( col2 * col2 * + col2 ) <> + col1
----
121
176
57

query I rowsort
SELECT col0 + col2 + + tab0.col0 * col2 FROM tab0
----
71
7469
849

onlyif mysql # use DIV operator for integer division
query I rowsort label-7104
SELECT DISTINCT col1 + + tab0.col0 * tab0.col1 DIV col2 FROM tab0
----
148
189
3492

skipif mysql # not compatible
query I rowsort label-7104
SELECT DISTINCT col1 + + tab0.col0 * tab0.col1 / col2 FROM tab0
----
148
189
3492

query I rowsort
SELECT col2 * col2 * - tab0.col0 AS col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT col1 AS col1 FROM tab0 WHERE NOT NULL <> ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + tab1.col1 * + tab1.col0 col0 FROM tab1 WHERE NULL IN ( + col2 )
----

query I rowsort
SELECT DISTINCT col1 + col1 - - col0 FROM tab0
----
196
229
271

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 - col0 col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT + cor0.col1 + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7111
SELECT DISTINCT col0 * col2 DIV col1 FROM tab0
----
0
80
9

skipif mysql # not compatible
query I rowsort label-7111
SELECT DISTINCT col0 * col2 / col1 FROM tab0
----
0
80
9

query I rowsort
SELECT + col2 * - col1 * - tab1.col1 FROM tab1
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-7113
SELECT DISTINCT col2 DIV + col2 AS col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-7113
SELECT DISTINCT col2 / + col2 AS col0 FROM tab0
----
1

query I rowsort
SELECT col1 + - col2 FROM tab1 WHERE NOT ( NULL ) BETWEEN ( NULL ) AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7115
SELECT ALL col0 + col2 - col0 DIV - tab0.col2 FROM tab0
----
172
57
71

skipif mysql # not compatible
query I rowsort label-7115
SELECT ALL col0 + col2 - col0 / - tab0.col2 FROM tab0
----
172
57
71

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT BETWEEN ( + col1 + + col1 * + col0 - - col1 / - col2 ) AND NULL
----

query I rowsort
SELECT col2 * col0 * col0 FROM tab0
----
1225
19008
649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-7118
SELECT col0 DIV + col2 + col1 * + tab0.col0 AS col0 FROM tab0
----
2064
3430
8100

skipif mysql # not compatible
query I rowsort label-7118
SELECT col0 / + col2 + col1 * + tab0.col0 AS col0 FROM tab0
----
2064
3430
8100

query I rowsort
SELECT DISTINCT col0 + tab2.col1 * - col2 FROM tab2
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-7120
SELECT col1 DIV col0 + + col1 FROM tab1
----
10
13
34

skipif mysql # not compatible
query I rowsort label-7120
SELECT col1 / col0 + + col1 FROM tab1
----
10
13
34

query I rowsort
SELECT + col1 * col1 - col2 FROM tab1 WHERE col2 + col0 <> col1
----
43
622
73

query III rowsort
SELECT * FROM tab2 WHERE col1 NOT BETWEEN ( tab2.col0 ) AND ( col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT - tab1.col1 * col2 AS col1 FROM tab1
----
-1248
-1404
-570

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT - col1 + col0 / col2 NOT BETWEEN - col0 + col0 * - col1 AND ( NULL )
----

query I rowsort
SELECT + col1 - col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 27 * col2 FROM tab0 AS cor0
----
2214
27
891

query I rowsort
SELECT + col1 * + col2 + col1 * col2 FROM tab2 AS cor0
----
1292
1674
3068

query I rowsort
SELECT ( 7 ) AS col2 FROM tab0
----
7
7
7

query I rowsort
SELECT + + col0 * col0 - + col1 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT ALL cor0.col1 * + 22 + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-1261
-172
-6097

query I rowsort
SELECT ALL + - col1 * 0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7132
SELECT ALL col2 DIV 94 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7132
SELECT ALL col2 / 94 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7133
SELECT ALL CAST( NULL AS SIGNED ) * 27 * + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7133
SELECT ALL CAST ( NULL AS INTEGER ) * 27 * + col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 62 FROM tab2, tab0 cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT + - ( - col1 ) * + col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT 5 * cor0.col2 + col2 FROM tab0 AS cor0
----
198
492
6

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab0 cor1, tab1 cor2
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 82 col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - col2 col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col0 * + col2 + + col1 AS col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - + cor0.col1 * 83 + 27 * col0 + col0 FROM tab2 AS cor0
----
-2377
-2713
801

query I rowsort
SELECT ALL + - col0 + + col2 * 13 * col0 FROM tab0 AS cor0
----
10272
420
94785

query I rowsort
SELECT DISTINCT - 18 + tab1.col0 AS col2 FROM tab1
----
-15
46
62

query I rowsort
SELECT ALL - 75 * col2 + + tab2.col2 FROM tab2
----
-1924
-1998
-2812

query I rowsort
SELECT + 7 * + cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to 3b75e0bd85f40756fc4d3aea79adb269

query I rowsort
SELECT - col1 + ( + col0 ) AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL - ( - 57 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT + 42 FROM tab2, tab0 cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * ( + 98 ) * - cor0.col1 + + ( col0 * - col0 ) + col1 col0 FROM tab1 AS cor0
----
-108307
-66806
-7627

query I rowsort
SELECT DISTINCT + col2 * col2 * 39 AS col0 FROM tab0 cor0
----
262236
39
42471

query I rowsort
SELECT ALL - col0 * 53 + - col1 * col0 + + ( 14 * col0 ) AS col2 FROM tab0 AS cor0
----
-11570
-3000
-4760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7152
SELECT ALL - + cor0.col0 * + CAST( NULL AS SIGNED ) + col1 * col1 * + 35 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7152
SELECT ALL - + cor0.col0 * + CAST ( NULL AS INTEGER ) + col1 * col1 * + 35 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7153
SELECT col1 * - CAST( + col1 AS SIGNED ) + + col2 + col0 FROM tab2 cor0
----
-172
-3377
-927

skipif mysql # not compatible
query I rowsort label-7153
SELECT col1 * - CAST ( + col1 AS INTEGER ) + + col2 + col0 FROM tab2 cor0
----
-172
-3377
-927

onlyif mysql # use DIV operator for integer division
query I rowsort label-7154
SELECT - cor0.col1 DIV col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-7154
SELECT - cor0.col1 / col0 FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7155
SELECT - col2 * 60 DIV col0 AS col1 FROM tab1 cor0
----
-1080
-53
-72

skipif mysql # not compatible
query I rowsort label-7155
SELECT - col2 * 60 / col0 AS col1 FROM tab1 cor0
----
-1080
-53
-72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7156
SELECT - cor0.col1 + + CAST( + 34 AS SIGNED ) + + col1 FROM tab2 cor0
----
34
34
34

skipif mysql # not compatible
query I rowsort label-7156
SELECT - cor0.col1 + + CAST ( + 34 AS INTEGER ) + + col1 FROM tab2 cor0
----
34
34
34

query I rowsort
SELECT DISTINCT - cor0.col1 * - 15 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
255
465
885

query I rowsort
SELECT + - 10 AS col2 FROM tab1 AS cor0
----
-10
-10
-10

query I rowsort
SELECT - col0 * 6 FROM tab2 AS cor0
----
-42
-468
-474

query I rowsort
SELECT - col1 - 73 * col1 FROM tab1 AS cor0
----
-1924
-740
-962

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7161
SELECT 62 * + col1 * col1 + + CAST( NULL AS SIGNED ) * 74 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-7161
SELECT 62 * + col1 * col1 + + CAST ( NULL AS INTEGER ) * 74 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 + + col0 * - col2 FROM tab1 AS cor0
----
-188
-3658
-7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7163
SELECT DISTINCT col0 + - tab0.col2 * CAST( NULL AS DECIMAL ) col0 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7163
SELECT DISTINCT col0 + - tab0.col2 * CAST ( NULL AS REAL ) col0 FROM tab0
----
NULL

query I rowsort
SELECT - col2 + + col2 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col1 + cor0.col1 * + col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT + + cor0.col0 * + col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT 62 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT DISTINCT 38 + - col0 FROM tab0 AS cor0
----
-51
14
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7169
SELECT col1 DIV - cor0.col1 + + col0 DIV + col0 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7169
SELECT col1 / - cor0.col1 + + col0 / + col0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - 84 + + col1 FROM tab1 AS cor0
----
-58
-71
-74

query I rowsort
SELECT ALL 12 + tab0.col0 * ( col2 * - col2 ) AS col0 FROM tab0
----
-23
-26124
-598424

query I rowsort
SELECT DISTINCT - cor0.col2 * col2 + - 94 FROM tab2 cor0
----
-1538
-770
-823

query I rowsort
SELECT DISTINCT + col2 + + col0 AS col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - - 75 AS col2 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
75

query I rowsort
SELECT ALL + + ( - cor0.col2 ) FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT + + 4 * col1 - col0 FROM tab0 AS cor0
----
275
320
353

query I rowsort
SELECT ALL - 2 + col0 * - ( col1 ) AS col2 FROM tab1 AS cor0
----
-1042
-642
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7178
SELECT col0 + col0 + + col2 DIV cor0.col0 FROM tab1 AS cor0
----
128
161
24

skipif mysql # not compatible
query I rowsort label-7178
SELECT col0 + col0 + + col2 / cor0.col0 FROM tab1 AS cor0
----
128
161
24

query I rowsort
SELECT DISTINCT col0 + col2 * ( 81 ) AS col0 FROM tab0 cor0
----
116
2697
6731

query I rowsort
SELECT + 11 AS col1 FROM tab0 AS cor0
----
11
11
11

query I rowsort
SELECT ALL 75 * col0 - col1 AS col2 FROM tab1 AS cor0
----
199
4790
5987

query I rowsort
SELECT DISTINCT - ( + col1 ) * + 79 AS col1 FROM tab2 AS cor0
----
-1343
-2449
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-7183
SELECT - col2 DIV - col2 - col1 * col2 FROM tab1 AS cor0
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-7183
SELECT - col2 / - col2 - col1 * col2 FROM tab1 AS cor0
----
-1247
-1403
-569

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col0 + + 11 col2 FROM tab0 AS cor0
----
1236
587
7932

query I rowsort
SELECT DISTINCT + - 41 - + col0 FROM tab0 AS cor0
----
-130
-65
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7186
SELECT DISTINCT + + 17 + - col1 DIV - col1 FROM tab1 AS cor0
----
18

skipif mysql # not compatible
query I rowsort label-7186
SELECT DISTINCT + + 17 + - col1 / - col1 FROM tab1 AS cor0
----
18

query I rowsort
SELECT col1 * + col0 + 96 * + col2 * - col1 + col1 AS col0 FROM tab1 AS cor0
----
-118755
-134680
-54070

query I rowsort
SELECT DISTINCT col1 * 65 FROM tab2 AS cor0
----
1105
2015
3835

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7189
SELECT DISTINCT + + col2 + + CAST( NULL AS DECIMAL ) * + cor0.col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7189
SELECT DISTINCT + + col2 + + CAST ( NULL AS REAL ) * + cor0.col2 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL - col0 * cor0.col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT col2 + + col0 * + col2 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT col1 + + col1 * + cor0.col0 * + col0 FROM tab1 AS cor0
----
260
40970
83213

query I rowsort
SELECT + col2 + col2 - 80 * cor0.col1 FROM tab0 AS cor0
----
-6814
-7116
-7758

query I rowsort
SELECT DISTINCT + tab0.col1 - + col1 FROM tab0
----
0

query I rowsort
SELECT + - 51 + + 37 FROM tab2 AS cor0
----
-14
-14
-14

query I rowsort
SELECT ALL + - col1 * + col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-7197
SELECT ALL + + col1 DIV ( + col2 ) AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-7197
SELECT ALL + + col1 / ( + col2 ) AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL - + 85 AS col1 FROM tab2 AS cor0
----
-85
-85
-85

query I rowsort
SELECT DISTINCT - ( + col2 ) + + col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 40 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

query I rowsort
SELECT DISTINCT - - 43 * + col2 AS col1 FROM tab0 cor0
----
1419
3526
43

query I rowsort
SELECT DISTINCT - ( col2 ) * col1 AS col2 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 84 + col0 col0 FROM tab1
----
148
164
87

query I rowsort
SELECT ( col0 ) + col1 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL - col1 * + cor0.col0 * + col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT ( col2 ) - col1 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT + col2 + - 23 FROM tab1
----
31
34
73

query I rowsort
SELECT DISTINCT + 27 FROM tab1, tab2 cor0
----
27

query I rowsort
SELECT ALL - 35 FROM tab0
----
-35
-35
-35

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0, tab2 cor2
----
3645 values hashing to 61c64d7c972af4105004f57e1913df08

query I rowsort
SELECT ALL col1 * col0 + + cor0.col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - col1 * + 48 AS col1 FROM tab1 AS cor0
----
-1248
-480
-624

query I rowsort
SELECT + - cor0.col1 * + col2 + + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7214
SELECT CAST( - col0 AS SIGNED ) * + col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-7214
SELECT CAST ( - col0 AS INTEGER ) * + col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL cor1.col2 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7216
SELECT + CAST( NULL AS SIGNED ) * - col2 + + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7216
SELECT + CAST ( NULL AS INTEGER ) * - col2 + + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7217
SELECT - CAST( NULL AS SIGNED ) * ( - col1 ) - - 9 * col0 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7217
SELECT - CAST ( NULL AS INTEGER ) * ( - col1 ) - - 9 * col0 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + + 79 * col2 FROM tab2 AS cor0
----
2113
2164
3019

query I rowsort
SELECT ( col0 ) + + col2 * col2 AS col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT - 98 * col1 * ( + col1 ) AS col2 FROM tab2
----
-28322
-341138
-94178

query I rowsort
SELECT ALL + col2 - col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col0 - cor0.col1 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT 12 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
22
25
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-7224
SELECT ALL - 47 + cor0.col1 DIV + 6 FROM tab2 AS cor0
----
-38
-42
-45

skipif mysql # not compatible
query I rowsort label-7224
SELECT ALL - 47 + cor0.col1 / + 6 FROM tab2 AS cor0
----
-38
-42
-45

query I rowsort
SELECT ALL + 96 + cor0.col0 AS col0 FROM tab1 AS cor0
----
160
176
99

skipif mysql # not compatible
query I rowsort
SELECT cor0.col1 * CAST ( + 23 AS REAL ) FROM tab2 AS cor0
----
1357
391
713

query I rowsort
SELECT - col1 + - ( col1 ) * col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT + + col0 + - ( cor0.col2 ) * col1 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col2 * ( col1 ) col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL - col0 * col1 + - col1 * col1 FROM tab2 cor0
----
-1178
-1632
-8083

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - ( col2 ) col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL + 27 AS col1 FROM tab0, tab0 cor0, tab2 AS cor1, tab2, tab1 cor2
----
243 values hashing to cee3679895e41b5065b6c038274a6a7d

query I rowsort
SELECT - - col2 + 12 FROM tab0 AS cor0
----
13
45
94

query I rowsort
SELECT + col1 * 4 FROM tab1 cor0
----
104
40
52

query I rowsort
SELECT DISTINCT + ( 78 ) AS col2 FROM tab1 AS cor0
----
78

query I rowsort
SELECT DISTINCT - 32 + - col0 FROM tab2 AS cor0
----
-110
-111
-39

query I rowsort
SELECT DISTINCT + 60 FROM tab0, tab1 cor0
----
60

query I rowsort
SELECT ALL - ( - col1 ) + col2 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL ( - 40 ) FROM tab1, tab1 cor0
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

query I rowsort
SELECT ALL tab1.col0 * tab1.col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ALL + 22 * 20 FROM tab0, tab1 AS cor0
----
9 values hashing to 574050448bf6a14b7436d7e456945832

query I rowsort
SELECT - + 39 + + col0 AS col1 FROM tab0 AS cor0
----
-15
-4
50

query I rowsort
SELECT - col2 * col2 + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT col1 + - col2 * + col1 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7245
SELECT ALL - CAST( + tab0.col2 AS SIGNED ) * + col2 * + 16 FROM tab0
----
-107584
-16
-17424

skipif mysql # not compatible
query I rowsort label-7245
SELECT ALL - CAST ( + tab0.col2 AS INTEGER ) * + col2 * + 16 FROM tab0
----
-107584
-16
-17424

query I rowsort
SELECT 49 * - col0 AS col0 FROM tab2
----
-343
-3822
-3871

query I rowsort
SELECT tab2.col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + col2 * col0 * 8 AS col1 FROM tab0 AS cor0
----
280
58384
6336

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 * + col2 col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT + ( 63 ) + + cor1.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 92cd3d1c2e00f987c595a465b20add9b

query I rowsort
SELECT ALL + 0 + 16 FROM tab0 AS cor0
----
16
16
16

query I rowsort
SELECT + col1 * + ( + col1 ) + + col0 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # use DIV operator for integer division
query I rowsort label-7253
SELECT ALL - col1 DIV - col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-7253
SELECT ALL - col1 / - col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - col1 AS REAL ) + + col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT cor0.col0 + col2 FROM tab0 cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7256
SELECT - ( col1 ) DIV - col0 - + col1 AS col2 FROM tab2 AS cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-7256
SELECT - ( col1 ) / - col0 - + col1 AS col2 FROM tab2 AS cor0
----
-17
-27
-59

query I rowsort
SELECT ALL + col2 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * - col1 col2 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-7259
SELECT - col1 DIV - 42 AS col1 FROM tab0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-7259
SELECT - col1 / - 42 AS col1 FROM tab0
----
2
2
2

query I rowsort
SELECT + col1 + + 20 FROM tab2 AS cor0
----
37
51
79

query I rowsort
SELECT DISTINCT 11 * + 56 FROM tab0 cor0
----
616

onlyif mysql # use DIV operator for integer division
query I rowsort label-7262
SELECT col2 * col2 DIV col1 FROM tab2
----
11
23
84

skipif mysql # not compatible
query I rowsort label-7262
SELECT col2 * col2 / col1 FROM tab2
----
11
23
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7263
SELECT CAST( NULL AS SIGNED ) + + col2 * + tab0.col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7263
SELECT CAST ( NULL AS INTEGER ) + + col2 * + tab0.col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7264
SELECT + cor0.col0 * cor0.col0 DIV col0 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-7264
SELECT + cor0.col0 * cor0.col0 / col0 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT 55 * + col1 * tab1.col1 + col2 FROM tab1
----
37234
5557
9391

query I rowsort
SELECT ALL + 24 FROM tab0, tab2 cor0 CROSS JOIN tab1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT ALL col0 + + 44 FROM tab1 cor0
----
108
124
47

query I rowsort
SELECT - col2 + - 8 AS col2 FROM tab0 AS cor0
----
-41
-9
-90

query I rowsort
SELECT DISTINCT + cor0.col0 + 83 * col2 * + col1 FROM tab2 cor0
----
127400
53697
69478

query I rowsort
SELECT DISTINCT - 51 AS col1 FROM tab0
----
-51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col0 * 59 - col1 col0 FROM tab2
----
-444
-4661
-4678

query I rowsort
SELECT tab1.col1 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - col0 + 23 FROM tab2 AS cor0
----
-55
-56
16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7274
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7274
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL col0 * - 65 FROM tab2
----
-455
-5070
-5135

query I rowsort
SELECT ALL + col0 - col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - col1 * cor0.col2 + 36 AS col2 FROM tab0 AS cor0
----
-2802
-61
-7426

query I rowsort
SELECT DISTINCT - col2 + + 1 AS col0 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT ALL + col1 + - col2 * + col0 - col2 FROM tab0 cor0
----
-7289
-739
61

query I rowsort
SELECT col0 + ( + ( col1 ) ) * - ( + cor0.col2 ) AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL + - cor0.col2 + 56 AS col1 FROM tab1 AS cor0
----
-1
-40
2

query I rowsort
SELECT + col1 + + ( - tab1.col0 ) AS col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT ALL - 32 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7284
SELECT DISTINCT + col0 + CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7284
SELECT DISTINCT + col0 + CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT - - col1 * + col2 + col2 * col1 FROM tab2 AS cor0
----
1292
1674
3068

query I rowsort
SELECT + - col0 * + ( - cor0.col1 ) AS col2 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col0 col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT - ( 17 ) + col0 AS col2 FROM tab1 AS cor0
----
-14
47
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7289
SELECT + - CAST( NULL AS SIGNED ) + ( - col0 ) / CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7289
SELECT + - CAST ( NULL AS INTEGER ) + ( - col0 ) / 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-7290
SELECT ALL + CAST( ( col1 ) AS SIGNED ) * 91 FROM tab1 AS cor0
----
1183
2366
910

skipif mysql # not compatible
query I rowsort label-7290
SELECT ALL + CAST ( ( col1 ) AS INTEGER ) * 91 FROM tab1 AS cor0
----
1183
2366
910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7291
SELECT DISTINCT - + CAST( ( col2 ) AS SIGNED ) + 20 FROM tab1 AS cor0
----
-34
-37
-76

skipif mysql # not compatible
query I rowsort label-7291
SELECT DISTINCT - + CAST ( ( col2 ) AS INTEGER ) + 20 FROM tab1 AS cor0
----
-34
-37
-76

query I rowsort
SELECT ALL ( + 48 ) + cor0.col1 * ( - 2 ) FROM tab1 cor0
----
-4
22
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-7293
SELECT tab1.col2 DIV col1 + col2 + + col1 FROM tab1
----
116
72
82

skipif mysql # not compatible
query I rowsort label-7293
SELECT tab1.col2 / col1 + col2 + + col1 FROM tab1
----
116
72
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 11 ) + + col2 col2 FROM tab1
----
107
65
68

query I rowsort
SELECT ALL - 84 + - cor0.col1 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to a341c0a47d91a172ce66c2ffd711056e

query I rowsort
SELECT DISTINCT - ( - 28 ) + + col2 * col2 FROM tab2 AS cor0
----
1472
704
757

query I rowsort
SELECT + + 57 * col2 * 90 FROM tab0 AS cor0
----
169290
420660
5130

query I rowsort
SELECT DISTINCT + col2 * col1 + 45 * + col1 - + col2 FROM tab0 AS cor0
----
11475
4461
6675

query I rowsort
SELECT ALL - 4 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 39ed23475412c3cbba02ecdd2d7018e6

query I rowsort
SELECT DISTINCT - 97 * + col2 FROM tab0 AS cor0
----
-3201
-7954
-97

query I rowsort
SELECT ALL + col1 * cor0.col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT 38 * - col0 + col0 FROM tab0 cor0
----
-1295
-3293
-888

query I rowsort
SELECT ALL cor0.col2 + - col0 * + ( + col0 ) FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT cor2.col1 AS col2 FROM tab2, tab2 AS cor0, tab1 cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT cor0.col1 * - col1 * + 99 AS col0 FROM tab2 AS cor0
----
-28611
-344619
-95139

query I rowsort
SELECT cor0.col2 * + col0 * - 43 FROM tab2 AS cor0
----
-129086
-8127
-87204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col0 * 75 col2 FROM tab1 AS cor0
----
-279
-4857
-6096

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * 7 col0 FROM tab2 AS cor0
----
182
189
266

query I rowsort
SELECT DISTINCT cor0.col0 + col2 * col2 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT col0 + 65 * - col0 FROM tab0 cor0
----
-1536
-2240
-5696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7311
SELECT ALL + col0 + CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7311
SELECT ALL + col0 + CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 11 + col0 * 35 AS col1 FROM tab1
----
116
2251
2811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * + 74 * col2 col2 FROM tab1
----
215838
240483
682080

query I rowsort
SELECT DISTINCT 88 + - col0 FROM tab0
----
-1
53
64

query I rowsort
SELECT - col0 + 42 FROM tab2
----
-36
-37
35

query I rowsort
SELECT ALL + cor1.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT - 63 + + 15 * tab2.col2 FROM tab2
----
327
342
507

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0 CROSS JOIN tab0, tab1, tab2 AS cor1
----
3645 values hashing to b34c9987c389223e07378cde8a36e94f

query I rowsort
SELECT - + 50 AS col2 FROM tab0, tab2, tab2 cor0
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

query I rowsort
SELECT ALL - 71 + - col1 FROM tab0
----
-157
-162
-168

query I rowsort
SELECT 59 * col0 * col2 AS col0 FROM tab2
----
11151
119652
177118

query I rowsort
SELECT ALL 29 AS col2 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT DISTINCT - 63 * - col2 AS col2 FROM tab2 AS cor0
----
1638
1701
2394

query I rowsort
SELECT ALL + + col0 + col2 * col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT 62 + + 37 FROM tab1, tab2 cor0
----
99

query I rowsort
SELECT DISTINCT col0 * - 47 FROM tab0
----
-1128
-1645
-4183

query I rowsort
SELECT DISTINCT + col2 * + col2 + col2 FROM tab0
----
1122
2
6806

query I rowsort
SELECT - col1 + ( col1 * - col2 ) FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT ALL - - col1 * + col2 + 63 AS col0 FROM tab1 AS cor0
----
1311
1467
633

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7330
SELECT + cor0.col1 + CAST( - col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7330
SELECT + cor0.col1 + CAST ( - col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 38 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

query I rowsort
SELECT DISTINCT + cor0.col1 * + col0 - + 81 AS col2 FROM tab1 AS cor0
----
-3
559
959

query I rowsort
SELECT + col0 * - col1 + - col2 AS col0 FROM tab2
----
-1381
-244
-4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-7334
SELECT col1 + - ( col0 ) + col0 DIV + 88 AS col2 FROM tab1
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-7334
SELECT col1 + - ( col0 ) + col0 / + 88 AS col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab2, tab1, tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - cor0.col0 - + cor0.col0 * - col0 AS col0 FROM tab2 cor0
----
42
6006
6162

query I rowsort
SELECT ALL + - ( - col1 ) + col2 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 46 * - col1 + col1 col1 FROM tab2 AS cor0
----
-1395
-2655
-765

onlyif mysql # use DIV operator for integer division
query I rowsort label-7339
SELECT DISTINCT + ( - col1 ) DIV col1 - col0 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-7339
SELECT DISTINCT + ( - col1 ) / col1 - col0 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT ALL + col0 * 12 AS col0 FROM tab1 AS cor0
----
36
768
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7341
SELECT DISTINCT + CAST( - col1 AS SIGNED ) * col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-7341
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) * col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL cor0.col1 + col0 * + col1 + - cor0.col0 FROM tab2 cor0
----
1281
241
4583

query I rowsort
SELECT - ( 44 ) + col0 AS col1 FROM tab0 AS cor0
----
-20
-9
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7344
SELECT DISTINCT + - CAST( NULL AS SIGNED ) * - 30 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7344
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) * - 30 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - ( col2 ) * col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + col1 * ( + col0 ) + + col2 * 39 AS col2 FROM tab1 AS cor0
----
2184
2863
4784

query I rowsort
SELECT DISTINCT + ( - 58 ) + + col2 FROM tab2 AS cor0
----
-20
-31
-32

query I rowsort
SELECT DISTINCT + col0 * + col0 * col0 AS col0 FROM tab2 AS cor0
----
343
474552
493039

query I rowsort
SELECT - ( - col1 ) * - cor0.col1 AS col0 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT 89 * + col1 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
1144
2288
880

query I rowsort
SELECT ALL + col0 * + 81 * + col0 FROM tab1
----
331776
518400
729

query I rowsort
SELECT + - cor0.col2 + + col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT 41 * col2 AS col0 FROM tab1 AS cor0
----
2214
2337
3936

query I rowsort
SELECT + - 3 * col0 FROM tab2 AS cor0
----
-21
-234
-237

query I rowsort
SELECT ALL 21 * col1 AS col2 FROM tab1
----
210
273
546

query I rowsort
SELECT DISTINCT col0 + + col2 AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT 87 * col2 FROM tab2 AS cor0
----
2262
2349
3306

query I rowsort
SELECT ALL + col2 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7360
SELECT - col0 + - 74 DIV col1 AS col1 FROM tab1 AS cor0
----
-5
-71
-85

skipif mysql # not compatible
query I rowsort label-7360
SELECT - col0 + - 74 / col1 AS col1 FROM tab1 AS cor0
----
-5
-71
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7361
SELECT - col1 DIV - 26 + col1 * - col0 col0 FROM tab2 AS cor0
----
-1343
-216
-4600

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7361
SELECT - col1 / - 26 + col1 * - col0 col0 FROM tab2 AS cor0
----
-1343
-216
-4600

onlyif mysql # use DIV operator for integer division
query I rowsort label-7362
SELECT + - col2 DIV + col2 + - col1 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-7362
SELECT + - col2 / + col2 + - col1 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT ALL + - col2 * + ( 59 ) * + col1 AS col2 FROM tab2 AS cor0
----
-38114
-49383
-90506

query I rowsort
SELECT ALL col1 * col1 * - col1 AS col1 FROM tab0 AS cor0
----
-636056
-753571
-912673

query I rowsort
SELECT col1 + - col1 * + col0 AS col1 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT - 89 * col0 AS col1 FROM tab2
----
-623
-6942
-7031

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col1 col0 FROM tab2
----
118
34
62

query I rowsort
SELECT + + 22 AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT - col2 * - col0 + - col1 FROM tab1 cor0
----
136
3638
7667

query I rowsort
SELECT + 43 + + 50 AS col1 FROM tab1 cor0
----
93
93
93

query I rowsort
SELECT - cor0.col2 + cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 09b61d5303a3c257c2b4280abfc64db7

query I rowsort
SELECT ALL - + 58 + 81 * tab1.col0 AS col0 FROM tab1, tab0 AS cor0, tab0, tab2 AS cor1
----
81 values hashing to c0e03cbc1df8b499159da8f4a231717a

query I rowsort
SELECT 87 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT + col2 * - col0 + - col0 AS col1 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT - cor0.col1 + 61 * + col2 * col2 AS col0 FROM tab1 AS cor0
----
177850
198179
562163

query I rowsort
SELECT ALL - cor0.col1 + ( - cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - + col1 * - 97 AS col0 FROM tab1 AS cor0
----
1261
2522
970

query I rowsort
SELECT col2 * + 17 FROM tab2 AS cor0
----
442
459
646

query I rowsort
SELECT ALL + ( + 41 ) * - col2 FROM tab0 AS cor0
----
-1353
-3362
-41

query I rowsort
SELECT DISTINCT + + 61 + + col1 AS col0 FROM tab1 AS cor0
----
71
74
87

query I rowsort
SELECT - + ( - col2 ) - + col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 38 + col1 + col2 FROM tab2 AS cor0
----
17
20
47

query I rowsort
SELECT DISTINCT - + 10 + - col2 FROM tab0 AS cor0
----
-11
-43
-92

query I rowsort
SELECT + - 98 * col2 + col2 FROM tab2 AS cor0
----
-2522
-2619
-3686

onlyif mysql # use DIV operator for integer division
query I rowsort label-7385
SELECT ALL col0 * - col0 + + col0 DIV + 57 AS col0 FROM tab2 AS cor0
----
-49
-6083
-6240

skipif mysql # not compatible
query I rowsort label-7385
SELECT ALL col0 * - col0 + + col0 / + 57 AS col0 FROM tab2 AS cor0
----
-49
-6083
-6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-7386
SELECT ALL + col1 + - col0 + col0 DIV 33 AS col1 FROM tab0 AS cor0
----
4
62
63

skipif mysql # not compatible
query I rowsort label-7386
SELECT ALL + col1 + - col0 + col0 / 33 AS col1 FROM tab0 AS cor0
----
4
62
63

query I rowsort
SELECT DISTINCT - + 34 + + col1 AS col0 FROM tab2 cor0
----
-17
-3
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-7388
SELECT - + col0 * + ( + col2 ) * 91 - - col2 DIV col1 AS col0 FROM tab0 AS cor0
----
-3185
-664118
-72072

skipif mysql # not compatible
query I rowsort label-7388
SELECT - + col0 * + ( + col2 ) * 91 - - col2 / col1 AS col0 FROM tab0 AS cor0
----
-3185
-664118
-72072

query I rowsort
SELECT ALL 1 + - col2 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT - - col2 - 43 * - col1 AS col2 FROM tab2 AS cor0
----
1360
2563
769

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 - col2 col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT 89 AS col2 FROM tab2, tab2 AS cor0
----
89

query I rowsort
SELECT col2 - + ( ( tab0.col2 ) ) * 5 FROM tab0
----
-132
-328
-4

query I rowsort
SELECT + - col0 + 17 * - cor0.col1 * + col0 FROM tab0 AS cor0
----
-137772
-35112
-57750

onlyif mysql # use DIV operator for integer division
query I rowsort label-7395
SELECT col1 DIV 81 + col0 + + cor0.col2 * col2 * col1 FROM tab2 AS cor0
----
22606
24627
39962

skipif mysql # not compatible
query I rowsort label-7395
SELECT col1 / 81 + col0 + + cor0.col2 * col2 * col1 FROM tab2 AS cor0
----
22606
24627
39962

query I rowsort
SELECT DISTINCT - 43 FROM tab1, tab1 AS cor0
----
-43

query I rowsort
SELECT ALL - - 81 + + col0 FROM tab0 AS cor0
----
105
116
170

query I rowsort
SELECT + col2 * - 77 * col1 FROM tab0
----
-218526
-574574
-7469

query I rowsort
SELECT DISTINCT 58 * + col2 AS col2 FROM tab0 AS cor0
----
1914
4756
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 95 + col1 * - 27 col0 FROM tab0 AS cor0
----
-2227
-2362
-2524

query I rowsort
SELECT + - 44 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
-1144
-440
-572

query I rowsort
SELECT + 55 AS col0 FROM tab1 AS cor0
----
55
55
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7403
SELECT - col2 + + col0 + + CAST( col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
11
111
58

skipif mysql # not compatible
query I rowsort label-7403
SELECT - col2 + + col0 + + CAST ( col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT col0 + - col0 * - 39 FROM tab1 AS cor0
----
120
2560
3200

query I rowsort
SELECT ALL ( + tab0.col1 ) * col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL - + 56 + col1 AS col0 FROM tab1 AS cor0
----
-30
-43
-46

query I rowsort
SELECT ALL + col1 * + col1 * - ( - col1 ) FROM tab2
----
205379
29791
4913

query I rowsort
SELECT 47 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT + - col1 + + 7 FROM tab1 AS cor0
----
-19
-3
-6

query I rowsort
SELECT + - col1 + cor0.col2 * col0 AS col2 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7411
SELECT ALL - + col1 + col0 + ( + col1 ) * CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7411
SELECT ALL - + col1 + col0 + ( + col1 ) * CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * 36 AS col0 FROM tab1 cor0
----
-108
-2304
-2880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7413
SELECT + col0 / CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7413
SELECT + col0 / CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7414
SELECT ALL col0 DIV col2 + col0 AS col1 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-7414
SELECT ALL col0 / col2 + col0 AS col1 FROM tab0 AS cor0
----
24
70
90

query I rowsort
SELECT DISTINCT - 45 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
-45

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2, tab2 AS cor0, tab1 cor1
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col2 + col0 * + 47 + - col2 col1 FROM tab2
----
113
1612
673

onlyif mysql # use DIV operator for integer division
query I rowsort label-7418
SELECT 66 DIV col1 + ( col0 ) * col1 * - 32 FROM tab0
----
-108640
-259168
-66048

skipif mysql # not compatible
query I rowsort label-7418
SELECT 66 / col1 + ( col0 ) * col1 * - 32 FROM tab0
----
-108640
-259168
-66048

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7419
SELECT - col2 + CAST( col2 AS SIGNED ) AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7419
SELECT - col2 + CAST ( col2 AS INTEGER ) AS col0 FROM tab1
----
0
0
0

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab2, tab2 cor1
----
243 values hashing to 5d85c5683e3ffd6d68920690d7302f7d

query I rowsort
SELECT DISTINCT - + col0 + - col0 * cor0.col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT col0 + 4 FROM tab0 AS cor0
----
28
39
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-7423
SELECT ALL + - cor0.col0 DIV + ( ( cor0.col1 ) + + ( 9 ) ) FROM tab1 AS cor0
----
-3
-3
0

skipif mysql # not compatible
query I rowsort label-7423
SELECT ALL + - cor0.col0 / + ( ( cor0.col1 ) + + ( 9 ) ) FROM tab1 AS cor0
----
-3
-3
0

query I rowsort
SELECT - + col1 * - col1 * + 19 FROM tab1 AS cor0
----
12844
1900
3211

query I rowsort
SELECT ALL + col0 + 80 AS col2 FROM tab1 AS cor0
----
144
160
83

query I rowsort
SELECT DISTINCT - 41 + ( - cor0.col2 ) AS col0 FROM tab2, tab0 AS cor0
----
-123
-42
-74

query I rowsort
SELECT ALL + 37 FROM tab1, tab2 cor0, tab0, tab2 AS cor1
----
81 values hashing to b8def841e97863779a391f3a05d3eb92

query I rowsort
SELECT DISTINCT - 11 + + tab0.col1 AS col0 FROM tab0
----
75
80
86

query I rowsort
SELECT col2 * - ( + col1 ) + - ( - col2 ) FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col0 + col2 col0 FROM tab1
----
216
3705
7776

query I rowsort
SELECT ALL + 12 * - col0 + col2 FROM tab0 AS cor0
----
-255
-419
-986

query I rowsort
SELECT DISTINCT + col1 + col1 + - col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7433
SELECT DISTINCT + col0 DIV + col0 + col2 FROM tab1 cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-7433
SELECT DISTINCT + col0 / + col0 + col2 FROM tab1 cor0
----
55
58
97

query I rowsort
SELECT DISTINCT + col2 + col1 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT DISTINCT 41 AS col1 FROM tab2
----
41

query I rowsort
SELECT - 3 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 65b7e16aaa7821ace3a45a9846ffa166

query I rowsort
SELECT ALL + col2 + - col1 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT + + col2 + col0 * col0 AS col1 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7439
SELECT ALL - col0 * col0 + CAST( - col2 * col0 + - col1 AS SIGNED ) col0 FROM tab0 AS cor0
----
-1357
-1454
-15310

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7439
SELECT ALL - col0 * col0 + CAST ( - col2 * col0 + - col1 AS INTEGER ) col0 FROM tab0 AS cor0
----
-1357
-1454
-15310

onlyif mysql # use DIV operator for integer division
query I rowsort label-7440
SELECT ALL - cor0.col1 + + col1 DIV cor0.col1 + ( col0 ) AS col2 FROM tab2 cor0
----
-23
20
63

skipif mysql # not compatible
query I rowsort label-7440
SELECT ALL - cor0.col1 + + col1 / cor0.col1 + ( col0 ) AS col2 FROM tab2 cor0
----
-23
20
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 + - col2 * + ( 42 ) col2 FROM tab1 AS cor0
----
-2242
-2384
-4019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7442
SELECT + - col0 * col2 + + CAST( col0 AS SIGNED ) * col0 + + col0 * + col2 * col2 AS col0 FROM tab0 AS cor0
----
1225
25920
599059

skipif mysql # not compatible
query I rowsort label-7442
SELECT + - col0 * col2 + + CAST ( col0 AS INTEGER ) * col0 + + col0 * + col2 * col2 AS col0 FROM tab0 AS cor0
----
1225
25920
599059

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL NOT IN ( col0 + + col0 * - col2 + - col1 )
----

query I rowsort
SELECT DISTINCT col2 - col0 AS col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL + col2 * tab1.col2 * + col0 + col1 * - col0 * + col0 AS col0 FROM tab1
----
166976
654080
8514

query III rowsort
SELECT ALL * FROM tab1 WHERE col0 NOT IN ( col0 * - col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT tab2.col1 + col2 * col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT ALL + col1 * + tab2.col1 AS col0 FROM tab2
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-7449
SELECT tab1.col1 * col2 DIV - col2 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7449
SELECT tab1.col1 * col2 / - col2 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col0 * + col0 * col0 FROM tab0 WHERE NOT ( NULL ) IN ( + col0 * + col0 - - tab0.col2 )
----

query I rowsort
SELECT ALL col2 FROM tab2 WHERE NULL < ( NULL )
----

query I rowsort
SELECT col1 + - col2 * col1 * tab1.col1 AS col0 FROM tab1 WHERE NULL NOT IN ( col1 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT col2 * - col2 + + col2 NOT BETWEEN NULL AND ( + col2 + + col1 )
----

query I rowsort
SELECT - col2 + + col0 - col2 AS col1 FROM tab1
----
-105
-112
-50

query I rowsort
SELECT DISTINCT col0 * - col1 * col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT col2 * col2 + - col1 * - col2 FROM tab1
----
10464
3819
4320

query I rowsort
SELECT ALL col1 * - tab0.col0 * col1 AS col0 FROM tab0
----
-177504
-329315
-737009

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT IN ( col1 + col2 + col1 )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( col1 * + col2 ) NOT BETWEEN NULL AND NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) NOT IN ( - col0 * + col1 )
----

query III rowsort
SELECT * FROM tab0 WHERE ( col2 ) < NULL
----

query I rowsort
SELECT col1 * col0 + + col2 * cor0.col1 FROM tab2 cor0
----
1054
1989
6136

query I rowsort
SELECT col1 + col2 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT col2 * + tab2.col0 + col1 + - col0 AS col2 FROM tab2
----
2009
213
2940

query I rowsort
SELECT ALL + col1 AS col0 FROM tab2 WHERE NOT NULL NOT IN ( col2 * col2 )
----

query I rowsort
SELECT - col0 - - col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT tab0.col2 + col1 * + tab0.col2 * col2 AS col1 FROM tab0
----
611966
93687
98

query I rowsort
SELECT tab2.col1 * col2 + + col2 AS col2 FROM tab2
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-7469
SELECT ALL col2 * + col1 + + col2 DIV - tab1.col1 col1 FROM tab1
----
1241
1402
565

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7469
SELECT ALL col2 * + col1 + + col2 / - tab1.col1 col1 FROM tab1
----
1241
1402
565

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 tab2.col1 + col0 * col0 AS col1 FROM tab2
----
6143
6258
80

query III rowsort
SELECT * FROM tab0 WHERE ( - col2 + col2 * + col2 ) IN ( - col1 * - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + col0 * + col2 col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT DISTINCT col0 + - tab0.col2 * tab0.col2 AS col2 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT ALL col1 * + tab1.col2 + col1 FROM tab1 WHERE NULL > NULL
----

query I rowsort
SELECT tab2.col1 * + col1 + - col2 AS col0 FROM tab2
----
251
3455
934

query I rowsort
SELECT ALL + col1 + col2 * - col2 FROM tab2
----
-1427
-617
-698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col1 col1 FROM tab0
----
2
62

query I rowsort
SELECT DISTINCT col0 * + col0 + - col2 * col2 AS col0 FROM tab1
----
-2816
-2907
847

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE - col0 IN ( col0 )
----

query I rowsort
SELECT col1 * tab1.col0 + + col2 AS col0 FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL - col1 + col2 * - col1 AS col0 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT ALL - + col1 * + col0 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 70 + 99 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT 9 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT - - col0 - col0 AS col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7487
SELECT DISTINCT + col1 DIV + col1 + col2 AS col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-7487
SELECT DISTINCT + col1 / + col1 + col2 AS col2 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT ALL 16 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT DISTINCT 51 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
51

query I rowsort
SELECT DISTINCT + col1 - - col0 * 0 * col1 FROM tab2
----
17
31
59

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab0, tab2 cor1, tab0 AS cor2, tab0 AS cor3
----
3645 values hashing to b223aa53e3aafe0f3f3f59048cc7a0d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7492
SELECT ALL CAST( NULL AS SIGNED ) + col1 + col2 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7492
SELECT ALL CAST ( NULL AS INTEGER ) + col1 + col2 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ( - col0 + col1 ) AS col2 FROM tab0
----
2
62
62

query I rowsort
SELECT 64 * + col1 FROM tab1
----
1664
640
832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 23 col2 FROM tab1, tab0, tab0 cor0
----
-23

query I rowsort
SELECT 95 + col1 * + col2 + + 88 FROM tab1 AS cor0
----
1431
1587
753

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0, tab0 cor1, tab0 AS cor2
----
972 values hashing to 8420206d6932c454f05a38de634b3cb5

query I rowsort
SELECT DISTINCT + 60 * - col2 AS col0 FROM tab1
----
-3240
-3420
-5760

query I rowsort
SELECT ALL - 74 AS col1 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 5a477330c946251f814fbbfd08e77c28

query I rowsort
SELECT cor0.col2 + - cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-7501
SELECT + col2 + 90 DIV col0 FROM tab2 AS cor0
----
27
39
39

skipif mysql # not compatible
query I rowsort label-7501
SELECT + col2 + 90 / col0 FROM tab2 AS cor0
----
27
39
39

query I rowsort
SELECT - col2 * ( + col1 ) + - col2 AS col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT col2 - - ( col0 ) FROM tab0
----
171
36
57

query I rowsort
SELECT - col2 * col1 + + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT - - cor0.col0 - + 10 FROM tab0 AS cor0
----
14
25
79

query I rowsort
SELECT - col0 + - ( 87 ) AS col0 FROM tab0 AS cor0
----
-111
-122
-176

query I rowsort
SELECT DISTINCT + col2 * + col0 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - cor0.col2 * + 63 FROM tab0, tab2, tab0 AS cor0, tab1
----
-2079
-5166
-63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * + col0 col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - + cor0.col1 * ( cor0.col1 ) - col1 * col0 FROM tab1 AS cor0
----
-1209
-740
-754

query I rowsort
SELECT - 42 + tab2.col0 FROM tab2
----
-35
36
37

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab2, tab2 cor0, tab0 AS cor1
----
26
27
38

query I rowsort
SELECT col1 * - ( col1 ) * - ( - 58 ) - + col0 * col1 FROM tab0
----
-431032
-488397
-549117

query I rowsort
SELECT DISTINCT 91 * - ( tab1.col0 ) FROM tab1
----
-273
-5824
-7280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7515
SELECT - ( - tab2.col1 ) * + col2 + CAST( NULL AS SIGNED ) * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7515
SELECT - ( - tab2.col1 ) * + col2 + CAST ( NULL AS INTEGER ) * col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 81 AS col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT ALL cor1.col0 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - 83 * col0 + - col2 FROM tab0 AS cor0
----
-2025
-2906
-7469

query I rowsort
SELECT 3 + tab2.col1 * 19 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 6419a8037ef68524c91cd24ede2206c0

query I rowsort
SELECT - ( col1 ) * - tab2.col2 * + col0 + + 20 AS col0 FROM tab2
----
119672
51054
5879

query I rowsort
SELECT DISTINCT col1 * col1 + col2 * - ( col1 ) AS col1 FROM tab0 AS cor0
----
4558
819
9312

query I rowsort
SELECT DISTINCT - 65 * - cor0.col1 FROM tab2 AS cor0
----
1105
2015
3835

query I rowsort
SELECT ALL - 78 + col1 - - ( 28 ) FROM tab2 AS cor0
----
-19
-33
9

query I rowsort
SELECT DISTINCT - col1 + cor0.col1 * col1 * col1 FROM tab0 cor0
----
635970
753480
912576

query I rowsort
SELECT ALL + col0 * + col2 * - 14 + 34 * - col2 FROM tab0 AS cor0
----
-104960
-12210
-524

query I rowsort
SELECT ALL + - ( cor0.col2 ) + - cor0.col0 + 28 AS col2 FROM tab2 AS cor0
----
-6
-76
-89

query I rowsort
SELECT DISTINCT - 38 FROM tab2 cor0
----
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 20 * + col0 col0 FROM tab0 AS cor0
----
-1780
-480
-700

onlyif mysql # use DIV operator for integer division
query I rowsort label-7529
SELECT ALL + + col2 + + col2 DIV - CAST( + 67 AS SIGNED ) + col0 AS col0 FROM tab1 AS cor0
----
121
175
57

skipif mysql # not compatible
query I rowsort label-7529
SELECT ALL + + col2 + + col2 / - CAST ( + 67 AS INTEGER ) + col0 AS col0 FROM tab1 AS cor0
----
121
175
57

query I rowsort
SELECT ALL + - 52 + + col0 + 82 AS col1 FROM tab0 AS cor0
----
119
54
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 34 * + cor0.col1 col1 FROM tab2 AS cor0
----
1054
2006
578

query I rowsort
SELECT DISTINCT + 56 FROM tab0 cor0
----
56

query I rowsort
SELECT DISTINCT 20 * col2 AS col0 FROM tab2 AS cor0
----
520
540
760

query I rowsort
SELECT - cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT + col0 * - col1 + col1 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-7536
SELECT col2 + col0 DIV col1 FROM tab2 AS cor0
----
27
27
42

skipif mysql # not compatible
query I rowsort label-7536
SELECT col2 + col0 / col1 FROM tab2 AS cor0
----
27
27
42

query I rowsort
SELECT + col0 * 52 * + 94 FROM tab1 AS cor0
----
14664
312832
391040

query I rowsort
SELECT + 60 FROM tab0, tab2 cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT col1 + ( col2 ) AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL + cor0.col2 * 49 AS col1 FROM tab1 AS cor0
----
2646
2793
4704

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7541
SELECT DISTINCT col1 * CAST( NULL AS DECIMAL ) + + cor0.col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7541
SELECT DISTINCT col1 * CAST ( NULL AS REAL ) + + cor0.col2 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col0 - - col0 * - 13 AS col0 FROM tab1 AS cor0
----
-36
-768
-960

query I rowsort
SELECT - - col0 * - cor0.col0 * + col0 FROM tab1 AS cor0
----
-262144
-27
-512000

query I rowsort
SELECT col0 * 8 * + cor0.col2 FROM tab2 AS cor0
----
1512
16224
24016

query I rowsort
SELECT - + col2 + col2 * - col0 * + col0 FROM tab2 AS cor0
----
-1350
-158210
-237196

query I rowsort
SELECT DISTINCT + 35 * + col2 FROM tab2 AS cor0
----
1330
910
945

query I rowsort
SELECT + ( + col2 ) * col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-7548
SELECT DISTINCT + 42 DIV 89 - - col1 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7548
SELECT DISTINCT + 42 / 89 - - col1 AS col2 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7549
SELECT DISTINCT CAST( NULL AS SIGNED ) + + tab1.col0 col2 FROM tab1, tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7549
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + tab1.col0 col2 FROM tab1, tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - - col1 + - ( col0 + col0 ) FROM tab2 AS cor0
----
-141
-97
17

query I rowsort
SELECT + - ( + ( + col2 ) ) * + ( col2 ) + cor0.col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT ALL - col0 * col1 + - cor0.col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT - - col2 * - 24 AS col2 FROM tab1 cor0
----
-1296
-1368
-2304

onlyif mysql # use DIV operator for integer division
query I rowsort label-7554
SELECT DISTINCT col1 DIV + col2 AS col0 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-7554
SELECT DISTINCT col1 / + col2 AS col0 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL + col2 * + col2 + + col0 * ( - col0 ) AS col1 FROM tab2 AS cor0
----
-4797
-5408
680

onlyif mysql # use DIV operator for integer division
query I rowsort label-7556
SELECT - + col2 DIV - cor0.col0 AS col2 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-7556
SELECT - + col2 / - cor0.col0 AS col2 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT - 18 * 20 + col2 AS col0 FROM tab0 AS cor0
----
-278
-327
-359

query I rowsort
SELECT col1 * + col1 + col2 * - 83 FROM tab1 AS cor0
----
-3806
-4631
-7799

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7559
SELECT ALL + + CAST( + col2 AS SIGNED ) * + cor0.col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-7559
SELECT ALL + + CAST ( + col2 AS INTEGER ) * + cor0.col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7560
SELECT - ( ( - col0 ) ) DIV - 1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-7560
SELECT - ( ( - col0 ) ) / - 1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7561
SELECT - + 49 + col1 * cor0.col2 DIV + col2 FROM tab0 AS cor0
----
37
42
48

skipif mysql # not compatible
query I rowsort label-7561
SELECT - + 49 + col1 * cor0.col2 / + col2 FROM tab0 AS cor0
----
37
42
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-7562
SELECT DISTINCT col0 DIV + 34 FROM tab1 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-7562
SELECT DISTINCT col0 / + 34 FROM tab1 AS cor0
----
0
1
2

query I rowsort
SELECT - + col0 * col0 + - cor0.col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL col1 * col1 + ( col2 ) AS col1 FROM tab2
----
327
3507
988

query I rowsort
SELECT ALL - col1 * + tab0.col1 + 53 FROM tab0
----
-7343
-8228
-9356

onlyif mysql # use DIV operator for integer division
query I rowsort label-7566
SELECT ALL + col1 DIV - col1 + - col0 AS col2 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-7566
SELECT ALL + col1 / - col1 + - col0 AS col2 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT DISTINCT - 61 FROM tab1 cor0
----
-61

query I rowsort
SELECT - - col0 * + col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - col0 + cor0.col0 * col1 AS col1 FROM tab2 AS cor0
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7570
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * + ( col2 ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7570
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * + ( col2 ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL 80 FROM tab2, tab2 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT col1 * 33 + 73 AS col0 FROM tab0 AS cor0
----
2911
3076
3274

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7573
SELECT ALL + cor0.col1 + + CAST( NULL AS SIGNED ) * - col2 * col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7573
SELECT ALL + cor0.col1 + + CAST ( NULL AS INTEGER ) * - col2 * col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 39 * + col1 + - 79 FROM tab2
----
1130
2222
584

query I rowsort
SELECT 87 * 22 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a77178baea378bcb3119d890a311bcaa

onlyif mysql # use DIV operator for integer division
query I rowsort label-7576
SELECT tab0.col0 DIV - col0 + col1 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-7576
SELECT tab0.col0 / - col0 + col1 FROM tab0
----
85
90
96

query I rowsort
SELECT col1 + ( - col2 ) + + tab2.col0 AS col0 FROM tab2
----
11
111
58

query I rowsort
SELECT tab1.col1 + + tab1.col2 + - col2 FROM tab1
----
10
13
26

query I rowsort
SELECT col1 + 45 AS col0 FROM tab2
----
104
62
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7580
SELECT ALL + col0 DIV - 48 + col1 AS col0 FROM tab1
----
12
26
9

skipif mysql # not compatible
query I rowsort label-7580
SELECT ALL + col0 / - 48 + col1 AS col0 FROM tab1
----
12
26
9

query I rowsort
SELECT ALL - col2 + 86 + - 32 FROM tab1
----
-3
-42
0

query I rowsort
SELECT DISTINCT - tab1.col2 * 61 + col0 AS col2 FROM tab1
----
-3291
-3413
-5776

onlyif mysql # use DIV operator for integer division
query I rowsort label-7583
SELECT DISTINCT + 81 DIV + cor0.col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
0
2
81

skipif mysql # not compatible
query I rowsort label-7583
SELECT DISTINCT + 81 / + cor0.col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
0
2
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-7584
SELECT - cor0.col2 DIV CAST( col2 AS SIGNED ) + - col0 * + CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
-1226
-577
-7922

skipif mysql # not compatible
query I rowsort label-7584
SELECT - cor0.col2 / CAST ( col2 AS INTEGER ) + - col0 * + CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
-1226
-577
-7922

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 61 * 96 col0 FROM tab0 AS cor0
----
-503616
-532896
-568032

query I rowsort
SELECT + - col1 + col2 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - col2 - + col2 AS col1 FROM tab2 cor0
----
-52
-54
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7588
SELECT - + 43 DIV col2 + + ( 13 ) AS col0 FROM tab1 AS cor0
----
13
13
13

skipif mysql # not compatible
query I rowsort label-7588
SELECT - + 43 / col2 + + ( 13 ) AS col0 FROM tab1 AS cor0
----
13
13
13

query I rowsort
SELECT + cor0.col1 * - col0 - cor0.col0 * + col1 AS col1 FROM tab0 AS cor0
----
-16198
-4128
-6790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7590
SELECT DISTINCT - 0 + col2 * CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7590
SELECT DISTINCT - 0 + col2 * CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - + 54 + col0 * col0 FROM tab2 AS cor0
----
-5
6030
6187

query I rowsort
SELECT + col1 * col2 + col0 * col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT - - col2 * + cor0.col2 + ( + col0 ) FROM tab0 cor0
----
1113
36
6813

query I rowsort
SELECT 32 * col2 FROM tab0
----
1056
2624
32

query I rowsort
SELECT ALL - + col2 * - cor0.col2 + + ( + col2 ) FROM tab0 AS cor0
----
1122
2
6806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7596
SELECT DISTINCT - - col0 + + col0 * CAST( ( col0 ) AS SIGNED ) FROM tab1 AS cor0
----
12
4160
6480

skipif mysql # not compatible
query I rowsort label-7596
SELECT DISTINCT - - col0 + + col0 * CAST ( ( col0 ) AS INTEGER ) FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL + - 44 + col2 AS col2 FROM tab1 AS cor0
----
10
13
52

query I rowsort
SELECT + cor0.col2 + + 48 FROM tab2 AS cor0
----
74
75
86

query I rowsort
SELECT - - col1 + - 23 FROM tab0 AS cor0
----
63
68
74

query I rowsort
SELECT DISTINCT - col1 + + col1 AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7601
SELECT ALL col1 * + ( + col2 ) + - col1 + CAST( - cor0.col2 AS SIGNED ) * cor0.col2 * + 74 FROM tab2 AS cor0
----
-106227
-48549
-53140

skipif mysql # not compatible
query I rowsort label-7601
SELECT ALL col1 * + ( + col2 ) + - col1 + CAST ( - cor0.col2 AS INTEGER ) * cor0.col2 * + 74 FROM tab2 AS cor0
----
-106227
-48549
-53140

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7602
SELECT - cor0.col2 + + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7602
SELECT - cor0.col2 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 6 * col2 FROM tab1 AS cor0
----
324
342
576

onlyif mysql # use DIV operator for integer division
query I rowsort label-7604
SELECT - - col2 DIV + 50 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7604
SELECT - - col2 / + 50 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7605
SELECT 10 DIV - tab1.col0 AS col2 FROM tab1
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-7605
SELECT 10 / - tab1.col0 AS col2 FROM tab1
----
-3
0
0

query I rowsort
SELECT col1 - 18 * - col1 FROM tab0
----
1634
1729
1843

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 cor1, tab1 AS cor2
----
972 values hashing to a8481bfbfcb330825976c5896e54bc19

query I rowsort
SELECT DISTINCT - col1 * - 37 FROM tab1 AS cor0
----
370
481
962

query I rowsort
SELECT 59 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 05f41d0d3fd0b5c29af79ab9209cab27

query I rowsort
SELECT 15 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT 20 * - cor0.col0 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 0ac5adb7a2b0cab9fe42930f5c60e309

onlyif mysql # use DIV operator for integer division
query I rowsort label-7612
SELECT + - col2 DIV - col2 + 91 DIV col2 - + col1 AS col0 FROM tab1 AS cor0
----
-12
-24
-8

skipif mysql # not compatible
query I rowsort label-7612
SELECT + - col2 / - col2 + 91 / col2 - + col1 AS col0 FROM tab1 AS cor0
----
-12
-24
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7613
SELECT ALL - 74 + + tab1.col2 * col1 DIV col2 FROM tab1
----
-48
-61
-64

skipif mysql # not compatible
query I rowsort label-7613
SELECT ALL - 74 + + tab1.col2 * col1 / col2 FROM tab1
----
-48
-61
-64

query I rowsort
SELECT - 94 * 64 * col0 FROM tab0
----
-144384
-210560
-535424

onlyif mysql # use DIV operator for integer division
query I rowsort label-7615
SELECT ALL - CAST( - ( + col1 ) AS SIGNED ) + col1 DIV + col0 AS col0 FROM tab2
----
17
35
59

skipif mysql # not compatible
query I rowsort label-7615
SELECT ALL - CAST ( - ( + col1 ) AS INTEGER ) + col1 / + col0 AS col0 FROM tab2
----
17
35
59

query I rowsort
SELECT + + col1 + cor0.col1 + - ( + col2 ) FROM tab0 AS cor0
----
100
139
193

query I rowsort
SELECT ALL - cor0.col0 * - col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + 74 FROM tab0, tab1 AS cor0, tab1 cor1
----
74

query I rowsort
SELECT ALL + cor0.col1 * 31 AS col0 FROM tab1 AS cor0
----
310
403
806

query I rowsort
SELECT - + col0 + col1 * + col1 * col1 FROM tab0 AS cor0
----
636032
753482
912638

query I rowsort
SELECT DISTINCT col1 * - col0 * 59 FROM tab2
----
-12803
-271518
-79237

query I rowsort
SELECT + tab0.col0 + - 39 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 85e5bae13b84411e62b65132f17b937b

query I rowsort
SELECT ALL 36 * - tab0.col2 + + 52 - + ( col2 ) * tab0.col0 FROM tab0
----
-10198
-19
-1928

onlyif mysql # use DIV operator for integer division
query I rowsort label-7624
SELECT + tab2.col0 DIV cor0.col1 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 761c0bac61c63fe58b14c5c95c76ae09

skipif mysql # not compatible
query I rowsort label-7624
SELECT + tab2.col0 / cor0.col1 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 761c0bac61c63fe58b14c5c95c76ae09

query I rowsort
SELECT 16 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT - ( + col2 ) + col1 AS col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT ALL 4 FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab0 cor1
----
81 values hashing to 3347a3237b37ed63205e9440d8818a46

query I rowsort
SELECT + col1 * - 38 AS col1 FROM tab0 AS cor0
----
-3268
-3458
-3686

onlyif mysql # use DIV operator for integer division
query I rowsort label-7629
SELECT - cor0.col2 DIV cor0.col0 + - col0 FROM tab0 cor0
----
-25
-35
-89

skipif mysql # not compatible
query I rowsort label-7629
SELECT - cor0.col2 / cor0.col0 + - col0 FROM tab0 cor0
----
-25
-35
-89

query I rowsort
SELECT + - cor0.col2 + col0 + - col1 FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT ALL col2 + + 87 * 40 FROM tab1 AS cor0
----
3534
3537
3576

query I rowsort
SELECT - - col0 * - col1 + - col1 * cor0.col1 FROM tab0 AS cor0
----
-12804
-16380
-9460

query I rowsort
SELECT DISTINCT col1 * + 36 FROM tab0 AS cor0
----
3096
3276
3492

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7634
SELECT - col0 - tab1.col1 * + CAST( col1 AS SIGNED ) * + col2 FROM tab1
----
-16304
-36507
-5764

skipif mysql # not compatible
query I rowsort label-7634
SELECT - col0 - tab1.col1 * + CAST ( col1 AS INTEGER ) * + col2 FROM tab1
----
-16304
-36507
-5764

onlyif mysql # use DIV operator for integer division
query I rowsort label-7635
SELECT + col1 DIV - 52 + col2 FROM tab2
----
25
27
38

skipif mysql # not compatible
query I rowsort label-7635
SELECT + col1 / - 52 + col2 FROM tab2
----
25
27
38

query I rowsort
SELECT DISTINCT col0 * 32 * - col0 FROM tab1
----
-131072
-204800
-288

query I rowsort
SELECT DISTINCT + tab1.col0 FROM tab1, tab2, tab2 cor0
----
3
64
80

query I rowsort
SELECT + col2 * 19 AS col1 FROM tab1 AS cor0
----
1026
1083
1824

query I rowsort
SELECT DISTINCT - col1 * ( + col2 ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - col1 + + col0 * + ( col1 ) AS col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT col2 + - tab2.col0 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT 30 * + 68 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 73c78bed6721e71e8b9317c0f2ede911

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 89 * col2 col1 FROM tab0
----
598436
89
96921

query I rowsort
SELECT DISTINCT - ( + 89 ) AS col0 FROM tab0
----
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7645
SELECT + 80 DIV 71 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7645
SELECT + 80 / 71 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL 0 * col2 - - col1 * + ( - col1 ) AS col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT + ( + col0 ) * - col1 AS col2 FROM tab0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col2 + - col0 col1 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT - 88 AS col0 FROM tab2
----
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + cor0.col0 * col0 * col2 col1 FROM tab0 AS cor0
----
1226
19041
649604

query I rowsort
SELECT + - ( - col2 ) + - 77 * + cor0.col1 - col1 FROM tab1 AS cor0
----
-1974
-723
-918

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col1 + - ( 78 ) col1 FROM tab0 AS cor0
----
1986
3317
8021

query I rowsort
SELECT + ( - col0 ) * + col1 AS col0 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 18 col0 FROM tab0
----
18
18
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-7655
SELECT - ( - 61 ) DIV - col1 FROM tab1
----
-2
-4
-6

skipif mysql # not compatible
query I rowsort label-7655
SELECT - ( - 61 ) / - col1 FROM tab1
----
-2
-4
-6

query I rowsort
SELECT ( ( col2 ) ) * col2 + - col2 FROM tab0 cor0
----
0
1056
6642

query I rowsort
SELECT - cor0.col2 * - col0 + col2 * col0 AS col0 FROM tab1 AS cor0
----
15360
324
7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-7658
SELECT DISTINCT 38 DIV col2 + - CAST( col0 AS SIGNED ) * col0 FROM tab0
----
-1187
-575
-7921

skipif mysql # not compatible
query I rowsort label-7658
SELECT DISTINCT 38 / col2 + - CAST ( col0 AS INTEGER ) * col0 FROM tab0
----
-1187
-575
-7921

query I rowsort
SELECT col1 * + col2 - + 92 * col2 FROM tab2
----
-1647
-2850
-858

query I rowsort
SELECT DISTINCT - col1 * cor0.col0 * + col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT ALL col2 + - cor0.col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + - col2 * col2 * 85 - col0 * col0 FROM tab0 AS cor0
----
-1310
-579461
-93141

onlyif mysql # use DIV operator for integer division
query I rowsort label-7663
SELECT + - cor0.col0 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7663
SELECT + - cor0.col0 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - 56 + col0 * + ( + 62 ) FROM tab1 AS cor0
----
242
4024
5016

query I rowsort
SELECT DISTINCT + col0 + col2 * col1 * col1 FROM tab0 AS cor0
----
244092
679131
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-7666
SELECT ALL - 67 DIV col1 AS col1 FROM tab1 AS cor0
----
-2
-5
-6

skipif mysql # not compatible
query I rowsort label-7666
SELECT ALL - 67 / col1 AS col1 FROM tab1 AS cor0
----
-2
-5
-6

query I rowsort
SELECT - ( - col1 ) * - col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col0 * - col0 * col0 + col2 FROM tab1 AS cor0
----
-262087
-511904
27

query I rowsort
SELECT ALL 39 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col0 + 80 col1 FROM tab2
----
-24
-37
46

query I rowsort
SELECT - col1 + + tab0.col2 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT tab2.col1 + tab2.col1 FROM tab2
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7673
SELECT DISTINCT + ( - col2 ) * col1 + 32 DIV col2 AS col1 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-7673
SELECT DISTINCT + ( - col2 ) * col1 + 32 / col2 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL col0 + col0 * ( 59 ) * col1 FROM tab0
----
121800
200340
477930

query I rowsort
SELECT ALL + 8 + - col2 FROM tab0
----
-25
-74
7

query I rowsort
SELECT DISTINCT - + cor0.col0 FROM tab0, tab2, tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - 18 * - col2 * + ( col1 ) + + col0 FROM tab0 AS cor0
----
134405
1781
51108

query I rowsort
SELECT - 54 + col1 AS col0 FROM tab2 AS cor0
----
-23
-37
5

query I rowsort
SELECT - col0 + cor0.col1 * - cor0.col1 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT DISTINCT - col0 + + col0 * - 57 FROM tab1
----
-174
-3712
-4640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + col1 col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT col2 * + 18 AS col0 FROM tab1 AS cor0
----
1026
1728
972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * - cor0.col0 + col0 + + col0 * + col2 col2 FROM tab0 AS cor0
----
105
14685
1608

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7684
SELECT - cor0.col0 + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7684
SELECT - cor0.col0 + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + 45 * + col1 + col1 AS col1 FROM tab1 AS cor0
----
25660
56173
63206

query I rowsort
SELECT ALL - col2 - ( - 2 * col2 ) AS col2 FROM tab0 AS cor0
----
1
33
82

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 cor1, tab1, tab0 AS cor2
----
3645 values hashing to 2566f3fa788816c8bfc482e730aaed74

query I rowsort
SELECT - - col1 - ( 24 ) AS col1 FROM tab0 AS cor0
----
62
67
73

query I rowsort
SELECT ALL + col0 + - col1 AS col2 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - col1 + - col2 AS col1 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT - col0 * - col1 + 4 FROM tab1 AS cor0
----
1044
644
82

query I rowsort
SELECT ALL col0 + + col2 * col2 AS col0 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT DISTINCT - - 67 FROM tab0, tab2, tab0 AS cor0
----
67

query I rowsort
SELECT col2 * 3 + 50 FROM tab0 AS cor0
----
149
296
53

query I rowsort
SELECT - cor0.col0 + col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 + col1 * 79 + + col1 FROM tab0 AS cor0
----
6856
7191
7725

query I rowsort
SELECT - col0 * + 23 AS col2 FROM tab2 AS cor0
----
-161
-1794
-1817

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7698
SELECT DISTINCT CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-7698
SELECT DISTINCT CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7699
SELECT - + CAST( NULL AS SIGNED ) * - col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7699
SELECT - + CAST ( NULL AS INTEGER ) * - col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 77 * 59 * + cor0.col0 col1 FROM tab1 cor0
----
-13629
-290752
-363440

query I rowsort
SELECT 74 * col0 FROM tab2 AS cor0
----
518
5772
5846

query I rowsort
SELECT ALL + ( 1 ) FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - cor0.col2 * - ( - col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + ( - 22 ) FROM tab1 AS cor0
----
-22
-22
-22

query I rowsort
SELECT ALL - ( - 25 ) FROM tab0 AS cor0
----
25
25
25

query I rowsort
SELECT DISTINCT ( + col1 ) * + col0 AS col0 FROM tab1
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7707
SELECT CAST( NULL AS SIGNED ) * - ( + col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7707
SELECT CAST ( NULL AS INTEGER ) * - ( + col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 96 * - col2 + cor0.col2 FROM tab2 AS cor0
----
2522
2619
3686

query I rowsort
SELECT DISTINCT + 23 * col1 + + cor0.col0 * col0 FROM tab1 AS cor0
----
4326
607
6699

query I rowsort
SELECT DISTINCT + - cor0.col1 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + + cor0.col1 * col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + 52 AS col2 FROM tab2 cor0
----
52
52
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-7713
SELECT - ( col1 ) DIV col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-7713
SELECT - ( col1 ) / col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT ALL + cor0.col0 * - col2 + - ( col0 ) FROM tab2 cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL + 3 + + cor0.col2 FROM tab0 AS cor0
----
36
4
85

query I rowsort
SELECT + + 83 AS col2 FROM tab0 AS cor0
----
83
83
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7717
SELECT + 5 + + col2 DIV col2 AS col0 FROM tab1
----
6
6
6

skipif mysql # not compatible
query I rowsort label-7717
SELECT + 5 + + col2 / col2 AS col0 FROM tab1
----
6
6
6

query I rowsort
SELECT DISTINCT + 85 AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
85

query I rowsort
SELECT ALL - tab0.col1 * col1 AS col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + 75 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
75

query I rowsort
SELECT - 70 - col0 AS col1 FROM tab0 AS cor0
----
-105
-159
-94

query I rowsort
SELECT 28 + col0 FROM tab1 AS cor0
----
108
31
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 71 * - 36 col2 FROM tab2 AS cor0
----
2556
2556
2556

query I rowsort
SELECT 22 * 42 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to fc75b215d85a746590ebf00d6efabd08

query I rowsort
SELECT DISTINCT - 69 AS col0 FROM tab0
----
-69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7726
SELECT - cor0.col2 - CAST( NULL AS SIGNED ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7726
SELECT - cor0.col2 - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT 48 - col1 * col0 FROM tab0 AS cor0
----
-2016
-3347
-8051

query I rowsort
SELECT + cor0.col1 + - cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT col0 + col1 - col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + cor0.col0 * col1 - - col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ( + 56 ) + + col1 * cor0.col2 FROM tab0 AS cor0
----
153
2894
7518

onlyif mysql # use DIV operator for integer division
query I rowsort label-7732
SELECT - 0 DIV 56 + col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-7732
SELECT - 0 / 56 + col1 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-7733
SELECT DISTINCT + cor0.col1 * col1 DIV - col1 + 8 * + col0 col1 FROM tab0 AS cor0
----
106
183
621

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7733
SELECT DISTINCT + cor0.col1 * col1 / - col1 + 8 * + col0 col1 FROM tab0 AS cor0
----
106
183
621

onlyif mysql # use DIV operator for integer division
query I rowsort label-7734
SELECT DISTINCT - col0 DIV + cor0.col0 + - ( col0 ) FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-7734
SELECT DISTINCT - col0 / + cor0.col0 + - ( col0 ) FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT - + ( - cor0.col1 ) AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - col2 + cor0.col0 * - 78 FROM tab1 cor0
----
-288
-5049
-6336

query I rowsort
SELECT ALL 51 * + col2 AS col2 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT - col2 + - col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT DISTINCT - ( - col0 ) * - col2 + 90 * + col0 FROM tab2 AS cor0
----
4108
441
4992

query I rowsort
SELECT - 10 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT DISTINCT + col0 * + col1 + col1 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-7742
SELECT col2 + col0 DIV - col0 FROM tab0 cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-7742
SELECT col2 + col0 / - col0 FROM tab0 cor0
----
0
32
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-7743
SELECT col0 DIV col1 + + col1 DIV - col1 AS col1 FROM tab2
----
-1
0
3

skipif mysql # not compatible
query I rowsort label-7743
SELECT col0 / col1 + + col1 / - col1 AS col1 FROM tab2
----
-1
0
3

query I rowsort
SELECT + - cor2.col2 + - cor2.col0 * + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to 3a7c78f7d2ea389ec7b3918e699e2363

query I rowsort
SELECT DISTINCT cor0.col0 - + ( 39 ) FROM tab0 AS cor0
----
-15
-4
50

query I rowsort
SELECT - - col2 + + col1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT 79 FROM tab0, tab2 cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

onlyif mysql # use DIV operator for integer division
query I rowsort label-7748
SELECT DISTINCT col1 DIV ( col0 ) + 86 AS col1 FROM tab0 AS cor0
----
87
88
89

skipif mysql # not compatible
query I rowsort label-7748
SELECT DISTINCT col1 / ( col0 ) + 86 AS col1 FROM tab0 AS cor0
----
87
88
89

query I rowsort
SELECT ALL cor0.col0 * - col0 + + col2 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7750
SELECT - - CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7750
SELECT - - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + 22 col0 FROM tab0, tab0 AS cor0
----
111
46
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * 89 col0 FROM tab1 AS cor0
----
-1157
-2314
-890

query I rowsort
SELECT DISTINCT - 86 AS col0 FROM tab0 cor0
----
-86

query I rowsort
SELECT ALL col1 * + col2 + col0 - col0 AS col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-7755
SELECT ALL + - 73 DIV col1 + + col1 FROM tab2 AS cor0
----
13
29
58

skipif mysql # not compatible
query I rowsort label-7755
SELECT ALL + - 73 / col1 + + col1 FROM tab2 AS cor0
----
13
29
58

query I rowsort
SELECT + 13 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-65
-66
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7757
SELECT DISTINCT + - col0 DIV col1 - cor0.col1 * - col1 * + col1 FROM tab2 AS cor0
----
205378
29791
4909

skipif mysql # not compatible
query I rowsort label-7757
SELECT DISTINCT + - col0 / col1 - cor0.col1 * - col1 * + col1 FROM tab2 AS cor0
----
205378
29791
4909

query I rowsort
SELECT + 1 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT - col1 * + col2 * - col1 AS col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT - - col0 * - cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col1 FROM tab0, tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + - col2 * col0 + + col0 AS col2 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab0, tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT 27 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27

query I rowsort
SELECT + + cor0.col1 * + col1 + col2 AS col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL + + cor0.col2 * cor0.col0 + + col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL cor0.col1 * col2 + 31 * col2 AS col0 FROM tab0 AS cor0
----
10004
128
3861

query I rowsort
SELECT DISTINCT + col2 - + ( col0 + - col0 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + col1 - col2 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT + col1 * 96 FROM tab0 cor0
----
8256
8736
9312

query I rowsort
SELECT DISTINCT - + col0 + col2 + 31 FROM tab2 AS cor0
----
-10
-21
51

query I rowsort
SELECT DISTINCT + 90 AS col2 FROM tab1, tab2, tab0 AS cor0
----
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) + + col0 * + col1 col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL 17 * + 35 * col0 FROM tab2 AS cor0
----
4165
46410
47005

query I rowsort
SELECT DISTINCT + - col2 * - 51 AS col1 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT col0 + - col1 + cor0.col0 FROM tab2 cor0
----
-17
141
97

query I rowsort
SELECT 59 * - 1 FROM tab1
----
-59
-59
-59

query I rowsort
SELECT 87 + + ( col0 ) FROM tab2 AS cor0
----
165
166
94

query I rowsort
SELECT DISTINCT cor0.col2 + - 74 AS col2 FROM tab2 AS cor0
----
-36
-47
-48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7780
SELECT - CAST( + col0 AS SIGNED ) * col2 * - col1 + cor0.col1 FROM tab0 AS cor0
----
3492
664209
68198

skipif mysql # not compatible
query I rowsort label-7780
SELECT - CAST ( + col0 AS INTEGER ) * col2 * - col1 + cor0.col1 FROM tab0 AS cor0
----
3492
664209
68198

query I rowsort
SELECT col0 - cor0.col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + - col0 * + cor0.col2 + cor0.col1 * col1 AS col1 FROM tab1 AS cor0
----
-3548
-7511
514

query I rowsort
SELECT DISTINCT col2 + col2 * + col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT - + ( ( - col0 ) ) + - col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - 55 * + col1 * col0 + col2 * cor0.col2 - col0 AS col0 FROM tab1 AS cor0
----
38385
66336
7203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - 0 * - col2 col1 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL + ( + 77 * col0 ) + - col0 FROM tab2
----
532
5928
6004

query I rowsort
SELECT col1 * 84 AS col0 FROM tab1
----
1092
2184
840

query I rowsort
SELECT + 49 * col0 + + col0 AS col1 FROM tab2 AS cor0
----
350
3900
3950

query I rowsort
SELECT DISTINCT + ( col1 ) - col1 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - + ( + col2 ) * col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + 85 * + col2 AS col0 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT ALL col1 * - col1 * + col2 AS col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 + col0 col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL - col2 + 90 * + col2 * + col2 AS col2 FROM tab0
----
605078
89
97977

query I rowsort
SELECT DISTINCT col1 + col1 * col1 AS col2 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT col2 * + col0 + + tab0.col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT ALL + ( 62 ) + col0 * + col1 * col2 FROM tab2
----
119714
51096
5921

query I rowsort
SELECT DISTINCT 0 + + 6 + col1 AS col2 FROM tab0
----
103
92
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col2 col1 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL - col0 + 52 * col0 FROM tab1 cor0
----
153
3264
4080

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7802
SELECT + - col2 + CAST( 24 AS SIGNED ) FROM tab1 AS cor0
----
-30
-33
-72

skipif mysql # not compatible
query I rowsort label-7802
SELECT + - col2 + CAST ( 24 AS INTEGER ) FROM tab1 AS cor0
----
-30
-33
-72

query I rowsort
SELECT ALL + col1 * - 50 AS col1 FROM tab0 AS cor0
----
-4300
-4550
-4850

onlyif mysql # use DIV operator for integer division
query I rowsort label-7804
SELECT ALL + col2 + col2 * 93 DIV col1 FROM tab1 AS cor0
----
247
587
782

skipif mysql # not compatible
query I rowsort label-7804
SELECT ALL + col2 + col2 * 93 / col1 FROM tab1 AS cor0
----
247
587
782

onlyif mysql # use DIV operator for integer division
query I rowsort label-7805
SELECT DISTINCT col1 DIV col0 + 63 FROM tab1 AS cor0
----
63
71

skipif mysql # not compatible
query I rowsort label-7805
SELECT DISTINCT col1 / col0 + 63 FROM tab1 AS cor0
----
63
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-7806
SELECT + - col1 DIV 53 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7806
SELECT + - col1 / 53 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT - - col2 * + ( + 80 * col2 ) FROM tab0 AS cor0
----
537920
80
87120

query I rowsort
SELECT ALL - col0 + - ( 90 + + col1 ) FROM tab2 AS cor0
----
-128
-186
-227

onlyif mysql # use DIV operator for integer division
query I rowsort label-7809
SELECT + col0 DIV col2 + + col2 AS col0 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-7809
SELECT + col0 / col2 + + col2 AS col0 FROM tab0
----
33
36
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7810
SELECT DISTINCT - col0 DIV col0 + col2 - tab0.col0 FROM tab0
----
-35
-8
8

skipif mysql # not compatible
query I rowsort label-7810
SELECT DISTINCT - col0 / col0 + col2 - tab0.col0 FROM tab0
----
-35
-8
8

query I rowsort
SELECT DISTINCT - col2 * 87 + + 24 - + col0 * col2 FROM tab2
----
-2514
-4266
-6284

query I rowsort
SELECT DISTINCT col1 + ( + col0 ) * col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT col0 + ( - col2 ) AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT tab0.col2 - col2 AS col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7815
SELECT - col0 + + col0 DIV col0 AS col1 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-7815
SELECT - col0 + + col0 / col0 AS col1 FROM tab1
----
-2
-63
-79

query I rowsort
SELECT - col1 + col1 * + col0 AS col1 FROM tab1
----
1027
52
630

query I rowsort
SELECT tab1.col1 * - col2 + - col1 AS col1 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT + col0 + + col0 * + col0 + col1 * - col2 FROM tab1 AS cor0
----
-1392
3590
5232

query I rowsort
SELECT DISTINCT - + cor0.col1 + col1 * col2 + cor0.col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL - + col1 * cor0.col0 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col2 + cor0.col2 * cor0.col0 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-7822
SELECT ALL - + col2 DIV + col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-7822
SELECT ALL - + col2 / + col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT ALL col2 * col2 + + col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT + cor0.col2 + col1 * + col2 * col2 FROM tab2 cor0
----
22626
24586
39910

onlyif mysql # use DIV operator for integer division
query I rowsort label-7825
SELECT col0 + cor0.col2 DIV - col1 AS col0 FROM tab1 AS cor0
----
1
59
73

skipif mysql # not compatible
query I rowsort label-7825
SELECT col0 + cor0.col2 / - col1 AS col0 FROM tab1 AS cor0
----
1
59
73

query I rowsort
SELECT DISTINCT - + 87 + - col2 * col2 AS col0 FROM tab0 AS cor0
----
-1176
-6811
-88

query I rowsort
SELECT + - 13 FROM tab1 cor0
----
-13
-13
-13

query I rowsort
SELECT DISTINCT ( col2 ) * col1 * - col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + col2 + - cor0.col0 * col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL - + col2 + + col1 * - col1 AS col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT 88 + + col1 AS col0 FROM tab0 AS cor0
----
174
179
185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col0 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + + ( col2 ) + + col0 AS col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - 36 * col1 - col0 FROM tab2 cor0
----
-1123
-2202
-691

query I rowsort
SELECT DISTINCT + ( col1 ) + cor0.col1 * col1 * col0 FROM tab0 AS cor0
----
177590
329412
737100

query I rowsort
SELECT - ( col2 ) * + col1 + + cor0.col0 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 + col1 col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT - 33 + col2 AS col0 FROM tab2 AS cor0
----
-6
-7
5

query I rowsort
SELECT ALL - col2 + + cor0.col2 * col1 AS col0 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT - col0 * - col1 + col2 * col1 AS col2 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT ALL col2 - + col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL 20 + + col0 FROM tab0
----
109
44
55

query I rowsort
SELECT - cor0.col0 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * col1 * col0 col1 FROM tab2 AS cor0
----
106097
1519
358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 38 * tab1.col0 col1 FROM tab1
----
114
2432
3040

query I rowsort
SELECT ALL - 55 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7847
SELECT - col1 * col0 + - CAST( - col2 AS SIGNED ) * col0 FROM tab2 AS cor0
----
-2574
-28
1659

skipif mysql # not compatible
query I rowsort label-7847
SELECT - col1 * col0 + - CAST ( - col2 AS INTEGER ) * col0 FROM tab2 AS cor0
----
-2574
-28
1659

query I rowsort
SELECT + 50 FROM tab2, tab2 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT - 72 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

query I rowsort
SELECT DISTINCT - 35 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-35

onlyif mysql # use DIV operator for integer division
query I rowsort label-7851
SELECT DISTINCT + - cor0.col0 DIV col1 AS col1 FROM tab1 AS cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-7851
SELECT DISTINCT + - cor0.col0 / col1 AS col1 FROM tab1 AS cor0
----
-6
0

query I rowsort
SELECT ( col1 ) * 81 AS col1 FROM tab0 AS cor0
----
6966
7371
7857

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7853
SELECT DISTINCT + - CAST( 23 AS SIGNED ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-23

skipif mysql # not compatible
query I rowsort label-7853
SELECT DISTINCT + - CAST ( 23 AS INTEGER ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-23

onlyif mysql # use DIV operator for integer division
query I rowsort label-7854
SELECT DISTINCT - 37 DIV + col1 AS col2 FROM tab1
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-7854
SELECT DISTINCT - 37 / + col1 AS col2 FROM tab1
----
-1
-2
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7855
SELECT CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7855
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 AS cor2, tab0 cor3
----
3645 values hashing to 2566f3fa788816c8bfc482e730aaed74

onlyif mysql # use DIV operator for integer division
query I rowsort label-7857
SELECT ( + col1 ) DIV - col0 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-7857
SELECT ( + col1 ) / - col0 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT tab1.col2 * 88 FROM tab1
----
4752
5016
8448

query I rowsort
SELECT ALL col2 * 71 * tab1.col1 AS col1 FROM tab1
----
40470
88608
99684

query I rowsort
SELECT ALL 74 FROM tab0, tab0 cor0, tab1, tab0 AS cor1
----
81 values hashing to 22fe261d6995563c0767a5087aea05b1

query I rowsort
SELECT ALL - 80 FROM tab1
----
-80
-80
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7862
SELECT ( col2 + col1 ) * CAST( - 72 + + col1 AS SIGNED ) FROM tab0
----
1666
2450
3287

skipif mysql # not compatible
query I rowsort label-7862
SELECT ( col2 + col1 ) * CAST ( - 72 + + col1 AS INTEGER ) FROM tab0
----
1666
2450
3287

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0, tab2 cor1, tab1 AS cor2
----
972 values hashing to 263f0eb7d5dfd4076c74918bc141bd9b

query I rowsort
SELECT ALL - + ( cor0.col1 ) + - col0 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7865
SELECT ALL + CAST( - 76 AS SIGNED ) + col1 * - col1 + cor0.col1 AS col2 FROM tab2 AS cor0
----
-1006
-348
-3498

skipif mysql # not compatible
query I rowsort label-7865
SELECT ALL + CAST ( - 76 AS INTEGER ) + col1 * - col1 + cor0.col1 AS col2 FROM tab2 AS cor0
----
-1006
-348
-3498

query I rowsort
SELECT DISTINCT ( col2 * - col0 ) FROM tab1
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7867
SELECT - - CAST( 0 AS SIGNED ) + - col1 * 1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-7867
SELECT - - CAST ( 0 AS INTEGER ) + - col1 * 1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - col2 * ( col2 * + 27 ) + + ( col1 + col1 ) FROM tab1
----
-248806
-78680
-87703

query I rowsort
SELECT - - 36 * + col0 + + 36 AS col0 FROM tab1 AS cor0
----
144
2340
2916

query I rowsort
SELECT - tab1.col1 * col2 + 39 FROM tab1
----
-1209
-1365
-531

query I rowsort
SELECT DISTINCT - + col0 + - col1 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + col0 + cor0.col2 * + col0 * - col0 AS col1 FROM tab0 AS cor0
----
-1190
-18984
-649433

query I rowsort
SELECT + 37 * - col2 AS col1 FROM tab0 cor0
----
-1221
-3034
-37

onlyif mysql # use DIV operator for integer division
query I rowsort label-7874
SELECT + + 65 DIV col1 FROM tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-7874
SELECT + + 65 / col1 FROM tab1 AS cor0
----
2
5
6

query I rowsort
SELECT + col2 + 61 + 72 FROM tab1 AS cor0
----
187
190
229

query I rowsort
SELECT - cor0.col2 * + 14 * col1 + col0 FROM tab2 AS cor0
----
-11711
-21398
-8965

query I rowsort
SELECT + col0 + 32 FROM tab0 AS cor0
----
121
56
67

query I rowsort
SELECT - col2 - col2 * col1 FROM tab1 AS cor0
----
-1344
-1458
-627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * cor0.col0 + + col1 col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT + col2 + 99 + col1 FROM tab1 AS cor0
----
166
179
208

query I rowsort
SELECT DISTINCT ( col0 ) * + col0 + - col1 + - 79 FROM tab0 AS cor0
----
1049
411
7751

query I rowsort
SELECT + col1 + - 37 * - col0 FROM tab0 AS cor0
----
1392
3384
974

query I rowsort
SELECT ALL + - 33 FROM tab1 AS cor0
----
-33
-33
-33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7884
SELECT CAST( + 70 AS SIGNED ) * - col2 + + col0 * col2 FROM tab0 cor0
----
-1518
-35
1558

skipif mysql # not compatible
query I rowsort label-7884
SELECT CAST ( + 70 AS INTEGER ) * - col2 + + col0 * col2 FROM tab0 cor0
----
-1518
-35
1558

query I rowsort
SELECT + col0 * ( col0 + - col2 ) FROM tab0
----
-216
1190
623

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7886
SELECT col0 / + CAST( NULL AS DECIMAL ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7886
SELECT col0 / + CAST ( NULL AS REAL ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 61 FROM tab0, tab1 AS cor0
----
61

query I rowsort
SELECT - col2 * col1 * - 72 AS col2 FROM tab0
----
204336
537264
6984

onlyif mysql # use DIV operator for integer division
query I rowsort label-7889
SELECT ALL + 43 DIV 6 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

skipif mysql # not compatible
query I rowsort label-7889
SELECT ALL + 43 / 6 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7890
SELECT col0 DIV - 80 col0 FROM tab0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7890
SELECT col0 / - 80 col0 FROM tab0
----
-1
0
0

query I rowsort
SELECT cor0.col2 + col2 * col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7892
SELECT ALL col0 + CAST( col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-7892
SELECT ALL col0 + CAST ( col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + col0 - 76 * col2 AS col2 FROM tab2 AS cor0
----
-1898
-2045
-2809

query I rowsort
SELECT ALL + + cor0.col0 * + col1 FROM tab1 cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7895
SELECT ALL - col0 + CAST( NULL AS SIGNED ) / + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7895
SELECT ALL - col0 + CAST ( NULL AS INTEGER ) / + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * ( + col2 ) + col0 col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + - col1 + 71 + cor0.col0 * - col1 FROM tab0 cor0
----
-2079
-3421
-8119

query I rowsort
SELECT - cor0.col0 * 48 + cor0.col1 FROM tab2 cor0
----
-305
-3685
-3775

query I rowsort
SELECT DISTINCT + 28 * + 61 FROM tab2 AS cor0
----
1708

query I rowsort
SELECT ALL - 32 + + 31 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - 99 * + col0 AS col1 FROM tab1
----
-297
-6336
-7920

query I rowsort
SELECT - 84 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

query I rowsort
SELECT DISTINCT + col1 * col0 + + col1 AS col0 FROM tab2
----
1360
248
4661

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0, tab1 AS cor1, tab1, tab2 cor2
----
3645 values hashing to b6efe6f7ec1a3daa3cc6ea9dd7d13455

query I rowsort
SELECT DISTINCT - ( - ( - col1 ) ) + col0 FROM tab0 cor0
----
-2
-62

query I rowsort
SELECT ALL - + ( ( col2 ) ) FROM tab2 cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 - col0 col1 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7908
SELECT ALL - CAST( NULL AS SIGNED ) + cor0.col0 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7908
SELECT ALL - CAST ( NULL AS INTEGER ) + cor0.col0 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( col2 ) * + col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - - col0 * - col0 * col0 + col2 FROM tab0 AS cor0
----
-13791
-42874
-704887

query I rowsort
SELECT - ( col2 ) + - ( ( - col2 ) ) * - col2 FROM tab0 cor0
----
-1122
-2
-6806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + cor0.col0 col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + 56 - - col2 AS col1 FROM tab2 AS cor0
----
82
83
94

query I rowsort
SELECT ALL + + 79 * col2 FROM tab2 AS cor0
----
2054
2133
3002

query I rowsort
SELECT col1 * col2 + - 22 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
350
832
962

query I rowsort
SELECT DISTINCT col2 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - col1 * col2 * + col1 + - cor0.col0 - - col0 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL - col2 * + col1 + 30 AS col2 FROM tab0 cor0
----
-2808
-67
-7432

query I rowsort
SELECT + - col2 * + 90 FROM tab2 AS cor0
----
-2340
-2430
-3420

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col1 + col2 col1 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT ALL + cor0.col2 * - col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7922
SELECT + col2 + + CAST( col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-7922
SELECT + col2 + + CAST ( col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col0 - + 21 col0 FROM tab1 AS cor0
----
-30
-4117
-6421

query I rowsort
SELECT 21 + col0 AS col1 FROM tab0
----
110
45
56

query I rowsort
SELECT 92 - - col0 AS col1 FROM tab1
----
156
172
95

query I rowsort
SELECT + 26 - col1 AS col0 FROM tab0
----
-60
-65
-71

query I rowsort
SELECT DISTINCT - + col0 + - ( col1 ) * + col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT - col0 * ( - col1 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT cor0.col2 * - cor0.col0 + col0 + col1 * - col2 FROM tab2 AS cor0
----
-1019
-3484
-3569

query I rowsort
SELECT DISTINCT col0 * + 56 AS col1 FROM tab0 AS cor0
----
1344
1960
4984

query I rowsort
SELECT + cor0.col1 * + col2 * col0 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + col0 * col1 + col0 FROM tab1
----
1120
704
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7933
SELECT + CAST( + col1 AS SIGNED ) * col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-7933
SELECT + CAST ( + col1 AS INTEGER ) * col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + tab0.col2 * 41 AS col0 FROM tab0
----
1353
3362
41

query I rowsort
SELECT ALL + 53 + col0 AS col0 FROM tab2
----
131
132
60

query I rowsort
SELECT DISTINCT + col1 * - col0 * col2 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-7937
SELECT ALL - - cor0.col2 DIV + col1 AS col0 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7937
SELECT ALL - - cor0.col2 / + col1 AS col0 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT + ( + cor0.col2 ) * col1 + col0 * - col2 AS col0 FROM tab1 AS cor0
----
-3078
-6432
1242

query I rowsort
SELECT DISTINCT 61 + + col2 AS col0 FROM tab1
----
115
118
157

query I rowsort
SELECT + 2 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

onlyif mysql # use DIV operator for integer division
query I rowsort label-7941
SELECT ( + col2 ) DIV - col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7941
SELECT ( + col2 ) / - col0 FROM tab0
----
-1
0
0

query I rowsort
SELECT ALL - col2 + + col0 + - col1 FROM tab2
----
-51
-7
24

query I rowsort
SELECT DISTINCT col2 + ( + col0 ) AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL - col1 + col1 * - col1 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT ALL ( col2 ) + - col1 AS col1 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ( col1 * - ( 34 ) ) FROM tab1
----
-340
-442
-884

query I rowsort
SELECT + col0 * col1 + - col1 AS col0 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT ALL - + 52 * col1 AS col0 FROM tab2 cor0
----
-1612
-3068
-884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7949
SELECT + 35 * col2 * - CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-261170
-3395
-99330

skipif mysql # not compatible
query I rowsort label-7949
SELECT + 35 * col2 * - CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-261170
-3395
-99330

query I rowsort
SELECT DISTINCT - - cor0.col1 * + col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col1 + + col0 * 23 AS col1 FROM tab2 AS cor0
----
130
1735
1800

query I rowsort
SELECT + 70 + - col1 * + 20 FROM tab2 cor0
----
-1110
-270
-550

query I rowsort
SELECT ALL 59 * col1 + ( - col2 + col2 ) FROM tab2 AS cor0
----
1003
1829
3481

query I rowsort
SELECT col2 * col2 + col1 * 96 FROM tab1 AS cor0
----
10464
4209
5412

query I rowsort
SELECT - cor0.col0 + + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to c99cbeca6e6fdb3507b2e08470c1cda6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7956
SELECT col0 * col1 + col1 DIV - col0 FROM tab0 AS cor0
----
2061
3393
8098

skipif mysql # not compatible
query I rowsort label-7956
SELECT col0 * col1 + col1 / - col0 FROM tab0 AS cor0
----
2061
3393
8098

query I rowsort
SELECT DISTINCT 70 + col2 * + tab2.col0 AS col0 FROM tab2
----
2098
259
3072

onlyif mysql # use DIV operator for integer division
query I rowsort label-7958
SELECT - + ( - 63 ) + col0 * - ( + cor0.col2 ) DIV col2 FROM tab1 cor0
----
-1
-17
60

skipif mysql # not compatible
query I rowsort label-7958
SELECT - + ( - 63 ) + col0 * - ( + cor0.col2 ) / col2 FROM tab1 cor0
----
-1
-17
60

query I rowsort
SELECT + - col2 + - col1 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 col2 FROM tab2, tab1 AS cor0
----
7
78
79

query I rowsort
SELECT + - col2 + col2 * ( + cor0.col0 ) AS col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT - - col0 * 97 + - col2 AS col0 FROM tab1 cor0
----
237
6151
7664

query I rowsort
SELECT + col2 + - col1 - - ( col2 ) FROM tab0 AS cor0
----
-20
-95
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 5 * tab2.col1 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 34ff6994b476f6f007f4db49c664ea5a

query I rowsort
SELECT ALL - - col2 - 61 AS col0 FROM tab2 AS cor0
----
-23
-34
-35

query I rowsort
SELECT - - col0 + col2 * 27 AS col1 FROM tab0 AS cor0
----
2303
62
915

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7967
SELECT DISTINCT cor0.col2 * + CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7967
SELECT DISTINCT cor0.col2 * + CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0
----
NULL

query I rowsort
SELECT + col1 + ( + col1 * + col2 ) FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT + col1 + + 94 * + 30 * col2 FROM tab0 AS cor0
----
231331
2917
93146

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * cor0.col1 + col2 * col1 + - ( + col1 ) col0 FROM tab0 AS cor0
----
14833
5590
97

query I rowsort
SELECT col0 * - col0 + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * + col1 col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - 60 * 7 * - cor0.col1 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to c9b2b4542df4691ecc40c20e2a81d542

query I rowsort
SELECT + 99 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT + col2 * + 58 + + col0 AS col2 FROM tab0 AS cor0
----
1938
4845
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 48 col0 FROM tab2 AS cor0
----
-48

query I rowsort
SELECT ALL - - ( col0 ) * + col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7978
SELECT ALL + CAST( 40 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
40
40
40

skipif mysql # not compatible
query I rowsort label-7978
SELECT ALL + CAST ( 40 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
40
40
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-7979
SELECT + - 6 DIV 9 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7979
SELECT + - 6 / 9 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + col2 + col1 - col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT ( + 65 ) * - col1 * + col1 AS col0 FROM tab2 AS cor0
----
-18785
-226265
-62465

query I rowsort
SELECT + col0 * col1 + + col0 AS col2 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + - col2 * - col0 col2 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-7984
SELECT - col0 * 12 + - col1 DIV + col0 FROM tab2 AS cor0
----
-88
-936
-948

skipif mysql # not compatible
query I rowsort label-7984
SELECT - col0 * 12 + - col1 / + col0 FROM tab2 AS cor0
----
-88
-936
-948

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 29 col2 FROM tab0
----
2378
29
957

query I rowsort
SELECT DISTINCT + 85 * ( col0 ) + + 93 FROM tab0 AS cor0
----
2133
3068
7658

query I rowsort
SELECT col2 * + col1 + - col1 - + 10 FROM tab0 AS cor0
----
-10
2742
7361

query I rowsort
SELECT DISTINCT - 15 AS col2 FROM tab1
----
-15

query I rowsort
SELECT ( 47 ) * col2 FROM tab0
----
1551
3854
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-7990
SELECT col0 + 80 DIV col2 FROM tab0 AS cor0
----
115
26
89

skipif mysql # not compatible
query I rowsort label-7990
SELECT col0 + 80 / col2 FROM tab0 AS cor0
----
115
26
89

query I rowsort
SELECT 38 + + col1 * col2 FROM tab0 AS cor0
----
135
2876
7500

query I rowsort
SELECT - - cor0.col1 * - col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7993
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-7993
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT tab1.col0 * + col0 * + 31 FROM tab1
----
126976
198400
279

query I rowsort
SELECT ALL - cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT ALL + col1 - 97 FROM tab2
----
-38
-66
-80

query I rowsort
SELECT col2 - 72 AS col2 FROM tab2
----
-34
-45
-46

query I rowsort
SELECT ALL col0 - + 42 * 26 FROM tab1
----
-1012
-1028
-1089

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 78 col1 FROM tab1 cor0
----
104
88
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-8000
SELECT + 20 DIV + col0 FROM tab1 AS cor0
----
0
0
6

skipif mysql # not compatible
query I rowsort label-8000
SELECT + 20 / + col0 FROM tab1 AS cor0
----
0
0
6

query I rowsort
SELECT ALL 85 * col2 AS col1 FROM tab1
----
4590
4845
8160

query I rowsort
SELECT DISTINCT tab2.col2 * col1 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT tab0.col2 + + tab0.col2 FROM tab0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-8004
SELECT - + 74 DIV col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-8004
SELECT - + 74 / col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL ( - cor0.col2 ) AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL 34 * col1 FROM tab1 cor0
----
340
442
884

query I rowsort
SELECT DISTINCT + - 74 FROM tab1 cor0
----
-74

query I rowsort
SELECT ALL col2 + + col0 * 31 AS col1 FROM tab2 AS cor0
----
244
2444
2487

query I rowsort
SELECT ALL - cor0.col2 + - col0 * ( - col2 ) FROM tab1 AS cor0
----
108
3591
7584

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab0 AS cor1, tab2 cor2
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT ALL + 79 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT tab0.col2 + col0 + + 53 AS col1 FROM tab0
----
110
224
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8013
SELECT - + col1 + ( + col1 ) DIV - col0 col0 FROM tab0 AS cor0
----
-89
-92
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8013
SELECT - + col1 + ( + col1 ) / - col0 col0 FROM tab0 AS cor0
----
-89
-92
-99

query I rowsort
SELECT DISTINCT - - col0 * - col1 AS col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + col0 + - ( + 55 ) * col1 * ( + col2 ) + - col1 * cor0.col1 FROM tab1 cor0
----
-31386
-68729
-77893

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8016
SELECT - col0 + - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8016
SELECT - col0 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 49 AS col0 FROM tab2, tab1 AS cor0
----
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8018
SELECT + col0 * + CAST( col1 AS SIGNED ) + col2 FROM tab0 AS cor0
----
2097
3396
8181

skipif mysql # not compatible
query I rowsort label-8018
SELECT + col0 * + CAST ( col1 AS INTEGER ) + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL - 23 + col2 FROM tab1 AS cor0
----
31
34
73

query I rowsort
SELECT + - 76 + 57 AS col0 FROM tab1 AS cor0
----
-19
-19
-19

query I rowsort
SELECT DISTINCT - 27 + + ( - col1 ) FROM tab0 AS cor0
----
-113
-118
-124

query I rowsort
SELECT - 30 + + col0 * - col2 FROM tab2 AS cor0
----
-2058
-219
-3032

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8023
SELECT DISTINCT CAST( 90 AS SIGNED ) + col1 FROM tab1 AS cor0
----
100
103
116

skipif mysql # not compatible
query I rowsort label-8023
SELECT DISTINCT CAST ( 90 AS INTEGER ) + col1 FROM tab1 AS cor0
----
100
103
116

query I rowsort
SELECT DISTINCT + 55 * + cor0.col1 - col2 FROM tab1 AS cor0
----
1376
493
619

query I rowsort
SELECT - ( 63 ) AS col2 FROM tab1 AS cor0
----
-63
-63
-63

query I rowsort
SELECT - + ( - cor0.col2 ) + col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL 84 + col0 FROM tab2 AS cor0
----
162
163
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-8028
SELECT DISTINCT + col2 DIV col0 + - col1 AS col1 FROM tab0 AS cor0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-8028
SELECT DISTINCT + col2 / col0 + - col1 AS col1 FROM tab0 AS cor0
----
-85
-91
-97

query I rowsort
SELECT DISTINCT - 21 + col0 * - col0 FROM tab0 AS cor0
----
-1246
-597
-7942

onlyif mysql # use DIV operator for integer division
query I rowsort label-8030
SELECT DISTINCT + 77 DIV - col0 + - cor0.col2 * ( - col2 + + col2 ) * - col1 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-8030
SELECT DISTINCT + 77 / - col0 + - cor0.col2 * ( - col2 + + col2 ) * - col1 FROM tab0 AS cor0
----
-2
-3
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8031
SELECT + ( col0 ) * cor0.col1 + + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8031
SELECT + ( col0 ) * cor0.col1 + + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - cor0.col1 + - ( col0 ) FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL cor0.col1 * + 43 * - col2 + 64 * col1 AS col1 FROM tab1 AS cor0
----
-23870
-52832
-58708

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8034
SELECT + + CAST( NULL AS SIGNED ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8034
SELECT + + CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 73 + + col1 * col2 FROM tab1 cor0
----
1321
1477
643

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 21 col0 FROM tab2 AS cor0
----
-21
-21
-21

query I rowsort
SELECT - col0 + 49 AS col0 FROM tab2 AS cor0
----
-29
-30
42

query I rowsort
SELECT + - col2 * - 23 + - col2 FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT + ( + 20 ) + + col1 AS col1 FROM tab0 AS cor0
----
106
111
117

query I rowsort
SELECT DISTINCT - 68 AS col1 FROM tab0 AS cor0
----
-68

query I rowsort
SELECT + cor1.col1 * 33 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 206693476d314a11a88471e3dc5c5f10

query I rowsort
SELECT + 78 + + cor0.col1 FROM tab1 AS cor0
----
104
88
91

query I rowsort
SELECT 64 * + col1 + + 41 AS col0 FROM tab0 AS cor0
----
5545
5865
6249

query I rowsort
SELECT 82 * + col0 AS col1 FROM tab1
----
246
5248
6560

query I rowsort
SELECT DISTINCT + 81 + col1 AS col2 FROM tab2
----
112
140
98

query I rowsort
SELECT col0 * 96 AS col0 FROM tab0
----
2304
3360
8544

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 83 * col0 col0 FROM tab1
----
252
5376
6720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - col0 col0 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8049
SELECT + col2 * CAST( NULL AS SIGNED ) * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8049
SELECT + col2 * CAST ( NULL AS INTEGER ) * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * - 13 AS col2 FROM tab1 AS cor0
----
1040
39
832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8051
SELECT ALL + + col1 * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8051
SELECT ALL + + col1 * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * 50 FROM tab2 AS cor0
----
1300
1350
1900

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8053
SELECT + col1 * + CAST( col0 AS SIGNED ) + col2 * ( col1 ) * col1 AS col0 FROM tab2 AS cor0
----
12325
26164
95108

skipif mysql # not compatible
query I rowsort label-8053
SELECT + col1 * + CAST ( col0 AS INTEGER ) + col2 * ( col1 ) * col1 AS col0 FROM tab2 AS cor0
----
12325
26164
95108

query I rowsort
SELECT ALL + + cor0.col2 + - 41 AS col0 FROM tab2 AS cor0
----
-14
-15
-3

query I rowsort
SELECT cor0.col1 + - cor0.col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 81d3107020f8e1cd31edca99c0a5480a

onlyif mysql # use DIV operator for integer division
query I rowsort label-8056
SELECT + col0 DIV ( col1 ) FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-8056
SELECT + col0 / ( col1 ) FROM tab2 AS cor0
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-8057
SELECT - - col1 DIV - CAST( 97 AS SIGNED ) FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8057
SELECT - - col1 / - CAST ( 97 AS INTEGER ) FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT 16 - + col0 AS col0 FROM tab2
----
-62
-63
9

query I rowsort
SELECT ALL cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 + + ( + 53 ) col2 FROM tab2 AS cor0
----
79
80
91

query I rowsort
SELECT ALL - - col1 * - 5 FROM tab2 AS cor0
----
-155
-295
-85

query I rowsort
SELECT - tab2.col1 + - col0 AS col1 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT ALL 82 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT - 5 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

query I rowsort
SELECT DISTINCT + col2 + 83 FROM tab0 AS cor0
----
116
165
84

query I rowsort
SELECT ALL col1 * ( col0 + - col1 ) AS col1 FROM tab2 AS cor0
----
-744
1054
1121

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 25 col0 FROM tab1
----
25
25
25

query I rowsort
SELECT 93 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8069
SELECT ( col0 ) DIV col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8069
SELECT ( col0 ) / col0 FROM tab2
----
1
1
1

query I rowsort
SELECT + col0 + ( + col2 ) + + col1 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT col2 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 87 + col2 + + col0 col2 FROM tab1 AS cor0
----
-204
-5447
-6784

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8073
SELECT + col0 * - CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8073
SELECT + col0 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 16 FROM tab2, tab0 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 9ffb4aaf972de606a4957894645b6216

query I rowsort
SELECT - + 65 * col0 AS col2 FROM tab1 cor0
----
-195
-4160
-5200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8076
SELECT - CAST( + 21 AS SIGNED ) * cor0.col0 FROM tab1 cor0
----
-1344
-1680
-63

skipif mysql # not compatible
query I rowsort label-8076
SELECT - CAST ( + 21 AS INTEGER ) * cor0.col0 FROM tab1 cor0
----
-1344
-1680
-63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( cor0.col0 ) * - col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - col0 + col0 * - 26 FROM tab2 AS cor0
----
-189
-2106
-2133

query IIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 WHERE NOT NULL <> ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8080
SELECT col2 DIV tab1.col1 AS col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-8080
SELECT col2 / tab1.col1 AS col1 FROM tab1
----
2
5
7

query I rowsort
SELECT - - 69 + col0 FROM tab1 cor0
----
133
149
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8082
SELECT DISTINCT CAST( NULL AS DECIMAL ) + + col0 * - col2 col1 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8082
SELECT DISTINCT CAST ( NULL AS REAL ) + + col0 * - col2 col1 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT + col2 * 2 + col2 AS col0 FROM tab2
----
114
78
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-8084
SELECT + 98 * col0 DIV - 69 FROM tab2 AS cor0
----
-110
-112
-9

skipif mysql # not compatible
query I rowsort label-8084
SELECT + 98 * col0 / - 69 FROM tab2 AS cor0
----
-110
-112
-9

query I rowsort
SELECT + 82 * col2 FROM tab1 AS cor0
----
4428
4674
7872

query I rowsort
SELECT DISTINCT + 52 + - col0 * col1 * ( - cor0.col2 ) AS col0 FROM tab0 AS cor0
----
3447
664170
68164

query I rowsort
SELECT ALL col2 * col0 - + col2 AS col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT + 61 * col2 * col0 FROM tab0 AS cor0
----
2135
445178
48312

query I rowsort
SELECT ALL + + 1 AS col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - - col1 * col1 * - ( col2 ) AS col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL + cor0.col1 * col2 + + ( col0 ) FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL + tab0.col2 * + col0 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT - 62 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to d2579f9395350eda865ff3a2d38a74f6

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT ALL - col2 * + col0 * 39 + col2 FROM tab1 AS cor0
----
-142215
-299424
-6264

query I rowsort
SELECT ALL - + col0 + cor0.col1 + col2 * col0 FROM tab0 AS cor0
----
7300
854
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8097
SELECT ALL + - col2 DIV - col1 + col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
133
167
8

skipif mysql # not compatible
query I rowsort label-8097
SELECT ALL + - col2 / - col1 + col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
133
167
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8098
SELECT DISTINCT + cor0.col0 * + ( - col2 ) - col1 * + CAST( col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-3748
-7849
-838

skipif mysql # not compatible
query I rowsort label-8098
SELECT DISTINCT + cor0.col0 * + ( - col2 ) - col1 * + CAST ( col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-3748
-7849
-838

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8099
SELECT DISTINCT col0 * col1 - + CAST( col0 AS SIGNED ) FROM tab0
----
2040
3360
8010

skipif mysql # not compatible
query I rowsort label-8099
SELECT DISTINCT col0 * col1 - + CAST ( col0 AS INTEGER ) FROM tab0
----
2040
3360
8010

query I rowsort
SELECT ALL + 93 * 43 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f20b220cfd56fc9fe0b99aa224cb8b86

query I rowsort
SELECT ALL 32 - col1 AS col0 FROM tab0
----
-54
-59
-65

query I rowsort
SELECT + cor1.col1 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT + 32 + cor0.col1 FROM tab0, tab2 AS cor0
----
49
63
91

query I rowsort
SELECT - col2 + col2 + + col0 AS col1 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8105
SELECT DISTINCT CAST( NULL AS SIGNED ) * tab0.col0 AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-8105
SELECT DISTINCT CAST ( NULL AS INTEGER ) * tab0.col0 AS col2 FROM tab0
----
NULL

query I rowsort
SELECT ( + col0 * - col2 ) FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ( + 58 ) FROM tab0
----
58
58
58

query I rowsort
SELECT 24 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT ALL - 90 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f6f26b9a04da14807208b93d507095c5

onlyif mysql # use DIV operator for integer division
query I rowsort label-8110
SELECT 3 DIV 82 + col0 AS col1 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-8110
SELECT 3 / 82 + col0 AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT 91 * - col0 - - col0 AS col1 FROM tab1
----
-270
-5760
-7200

query I rowsort
SELECT ALL - col2 * col1 + col0 * col0 AS col0 FROM tab2 AS cor0
----
-788
4550
5595

query I rowsort
SELECT ALL + col0 * ( col0 ) - + col2 * col1 FROM tab0 AS cor0
----
-2262
1128
459

query I rowsort
SELECT ALL + col2 + + 16 AS col2 FROM tab2 cor0
----
42
43
54

query I rowsort
SELECT - col2 * - 51 * 29 AS col1 FROM tab1 AS cor0
----
141984
79866
84303

query I rowsort
SELECT ALL - col1 - - cor0.col0 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8117
SELECT + - col0 + CAST( - 13 AS SIGNED ) col1 FROM tab0 AS cor0
----
-102
-37
-48

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8117
SELECT + - col0 + CAST ( - 13 AS INTEGER ) col1 FROM tab0 AS cor0
----
-102
-37
-48

onlyif mysql # use DIV operator for integer division
query I rowsort label-8118
SELECT ALL + - col0 DIV + 65 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8118
SELECT ALL + - col0 / + 65 AS col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT cor0.col2 * col0 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT col0 * 44 AS col0 FROM tab1 AS cor0
----
132
2816
3520

query I rowsort
SELECT ALL - + cor0.col1 * col0 - 93 AS col1 FROM tab1 AS cor0
----
-1133
-171
-733

onlyif mysql # use DIV operator for integer division
query I rowsort label-8122
SELECT - tab1.col0 + col2 - 49 * 63 DIV col2 FROM tab1
----
-16
-6
-61

skipif mysql # not compatible
query I rowsort label-8122
SELECT - tab1.col0 + col2 - 49 * 63 / col2 FROM tab1
----
-16
-6
-61

query I rowsort
SELECT DISTINCT + cor0.col0 + 29 FROM tab0 AS cor0
----
118
53
64

query I rowsort
SELECT DISTINCT cor0.col1 * 70 AS col0 FROM tab0 AS cor0
----
6020
6370
6790

onlyif mysql # use DIV operator for integer division
query I rowsort label-8125
SELECT - + col1 DIV - col0 + + ( col0 ) FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-8125
SELECT - + col1 / - col0 + + ( col0 ) FROM tab2 AS cor0
----
11
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8126
SELECT col2 * col1 + col0 DIV col0 AS col2 FROM tab2 AS cor0
----
1535
647
838

skipif mysql # not compatible
query I rowsort label-8126
SELECT col2 * col1 + col0 / col0 AS col2 FROM tab2 AS cor0
----
1535
647
838

query I rowsort
SELECT + - 18 * + col1 FROM tab1 cor0
----
-180
-234
-468

query I rowsort
SELECT ALL col0 * - ( + tab2.col2 * + col2 ) FROM tab2
----
-114076
-5103
-52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col0 * + col0 col2 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-8130
SELECT - col1 DIV col2 + + col2 AS col0 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-8130
SELECT - col1 / col2 + + col2 AS col0 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8131
SELECT ALL + col2 + - cor0.col2 DIV col1 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8131
SELECT ALL + col2 + - cor0.col2 / col1 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - + ( col0 ) * 49 + + col2 FROM tab1 cor0
----
-3079
-3824
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col2 ) col2 FROM tab0
----
1
33
82

query I rowsort
SELECT - 16 FROM tab2, tab1 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

query I rowsort
SELECT ALL 90 + tab0.col2 - tab0.col2 * - col2 FROM tab0
----
1212
6896
92

query I rowsort
SELECT ALL 21 + - tab1.col1 FROM tab1
----
-5
11
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8137
SELECT DISTINCT + 53 + - col2 DIV col0 FROM tab1
----
35
52
53

skipif mysql # not compatible
query I rowsort label-8137
SELECT DISTINCT + 53 + - col2 / col0 FROM tab1
----
35
52
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-8138
SELECT DISTINCT col0 + tab1.col2 DIV - ( + col2 ) FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-8138
SELECT DISTINCT col0 + tab1.col2 / - ( + col2 ) FROM tab1
----
2
63
79

query I rowsort
SELECT ALL ( col1 ) * + 6 + + tab1.col1 AS col0 FROM tab1
----
182
70
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 21 * + col0 col0 FROM tab0 AS cor0
----
1869
504
735

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8141
SELECT + cor0.col0 + - col1 * CAST( + col1 AS SIGNED ) + + col1 * col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-8141
SELECT + cor0.col0 + - col1 * CAST ( + col1 AS INTEGER ) + + col1 * col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - col1 * - col1 + col2 AS col2 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-8143
SELECT ALL + - col1 + cor0.col1 DIV col0 FROM tab1 cor0
----
-10
-13
-18

skipif mysql # not compatible
query I rowsort label-8143
SELECT ALL + - col1 + cor0.col1 / col0 FROM tab1 cor0
----
-10
-13
-18

onlyif mysql # use DIV operator for integer division
query I rowsort label-8144
SELECT ALL + col1 + col2 DIV + col2 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-8144
SELECT ALL + col1 + col2 / + col2 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort
SELECT - - col1 / - col2 + - CAST ( cor0.col1 AS REAL ) AS col1 FROM tab0 AS cor0
----
-194
-88
-92

query I rowsort
SELECT ALL - - col1 * col0 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - col1 * + col1 + col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT - col2 * - tab0.col2 + + col0 FROM tab0
----
1113
36
6813

query I rowsort
SELECT + col1 * col0 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - 9 * col2 FROM tab1 AS cor0
----
-486
-513
-864

query I rowsort
SELECT ALL + col1 + + col0 AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL + 56 AS col2 FROM tab1
----
56
56
56

query I rowsort
SELECT DISTINCT - tab2.col2 * col2 AS col2 FROM tab2
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-8154
SELECT - + col2 DIV - col0 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8154
SELECT - + col2 / - col0 AS col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + col0 * - col1 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT - col0 * - col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + col1 * col0 + + col0 AS col2 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT - - col1 - + cor0.col2 FROM tab0 AS cor0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( col2 AS REAL ) FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT - col0 * 44 - - col1 FROM tab0 AS cor0
----
-1443
-3825
-970

query I rowsort
SELECT ALL + + 6 FROM tab1 AS cor0
----
6
6
6

query I rowsort
SELECT DISTINCT - - col1 * 24 AS col1 FROM tab2 cor0
----
1416
408
744

onlyif mysql # use DIV operator for integer division
query I rowsort label-8164
SELECT DISTINCT cor0.col1 DIV - col2 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-8164
SELECT DISTINCT cor0.col1 / - col2 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + 2 * + col0 AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT 53 AS col1 FROM tab1 cor0
----
53
53
53

query I rowsort
SELECT DISTINCT - 93 + col0 FROM tab2 AS cor0
----
-14
-15
-86

query I rowsort
SELECT ALL 94 * + col2 FROM tab0 AS cor0
----
3102
7708
94

query I rowsort
SELECT - 3 AS col1 FROM tab2 AS cor0
----
-3
-3
-3

query I rowsort
SELECT ALL 55 * + col0 AS col2 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT DISTINCT - 88 AS col0 FROM tab1
----
-88

query I rowsort
SELECT - 78 AS col0 FROM tab2
----
-78
-78
-78

query I rowsort
SELECT + - ( 24 ) AS col1 FROM tab0 AS cor0
----
-24
-24
-24

query I rowsort
SELECT DISTINCT + col2 * 47 FROM tab2
----
1222
1269
1786

query I rowsort
SELECT - + 88 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

query I rowsort
SELECT + ( cor0.col0 ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT DISTINCT 91 * - col1 FROM tab0 cor0
----
-7826
-8281
-8827

query I rowsort
SELECT + ( col2 ) * - col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT ( + 6 ) FROM tab0
----
6

query I rowsort
SELECT DISTINCT col0 * + tab0.col0 * + tab0.col0 AS col2 FROM tab0
----
13824
42875
704969

query I rowsort
SELECT 70 * - col1 * + tab1.col2 AS col1 FROM tab1
----
-39900
-87360
-98280

query I rowsort
SELECT 27 * + col0 FROM tab2
----
189
2106
2133

query I rowsort
SELECT - col2 * + tab1.col1 AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT 33 AS col1 FROM tab2
----
33
33
33

query I rowsort
SELECT ALL + + col2 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ( col2 ) * tab1.col0 AS col0 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8187
SELECT DISTINCT + col1 DIV - col1 - + col1 FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-8187
SELECT DISTINCT + col1 / - col1 - + col1 FROM tab0
----
-87
-92
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - col0 col0 FROM tab1
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8189
SELECT - CAST( tab1.col2 AS SIGNED ) - col0 AS col1 FROM tab1
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-8189
SELECT - CAST ( tab1.col2 AS INTEGER ) - col0 AS col1 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT + + col2 * - col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + col1 * - ( + col0 ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8192
SELECT - col0 / CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8192
SELECT - col0 / CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 44 AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 38f05fdaaf15e64b62f27cd96f73fb79

query I rowsort
SELECT + 16 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab0, tab1 cor1, tab1, tab2 AS cor2
----
3645 values hashing to a8f0522dfcc0ffd1116145dd0d0134ff

onlyif mysql # use DIV operator for integer division
query I rowsort label-8196
SELECT - col2 * cor0.col1 DIV 83 AS col0 FROM tab0 cor0
----
-1
-34
-89

skipif mysql # not compatible
query I rowsort label-8196
SELECT - col2 * cor0.col1 / 83 AS col0 FROM tab0 cor0
----
-1
-34
-89

query I rowsort
SELECT 68 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT + col2 * - col0 + 53 AS col1 FROM tab2
----
-136
-1975
-2949

query I rowsort
SELECT tab0.col0 * 2 + ( col2 ) FROM tab0
----
260
71
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-8200
SELECT ALL col1 DIV ( - ( col2 ) * tab0.col2 ) AS col0 FROM tab0
----
-97
0
0

skipif mysql # not compatible
query I rowsort label-8200
SELECT ALL col1 / ( - ( col2 ) * tab0.col2 ) AS col0 FROM tab0
----
-97
0
0

query I rowsort
SELECT - tab2.col0 + col1 * col2 AS col0 FROM tab2
----
1456
567
830

query I rowsort
SELECT - - 70 * - 16 * col1 FROM tab0 AS cor0
----
-101920
-108640
-96320

query I rowsort
SELECT DISTINCT - col0 + - cor0.col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT 97 AS col1 FROM tab2 AS cor0
----
97

query I rowsort
SELECT - - col0 * 69 FROM tab0 cor0
----
1656
2415
6141

query I rowsort
SELECT ALL cor0.col0 * 88 * - col1 AS col0 FROM tab2 AS cor0
----
-118184
-19096
-404976

query I rowsort
SELECT ALL + - col1 + col0 * + col0 AS col2 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT - ( - col0 ) FROM tab0 cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col2 + - col0 col0 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT ( tab0.col1 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT - - 96 * cor0.col0 * + col2 FROM tab2 AS cor0
----
18144
194688
288192

query I rowsort
SELECT DISTINCT 2 * - 43 + col1 AS col2 FROM tab1 AS cor0
----
-60
-73
-76

query I rowsort
SELECT - - ( + ( col2 ) ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + col1 - col1 * + col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT + 34 + col0 FROM tab2 cor0
----
112
113
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * - cor0.col0 col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL + 37 + + ( col2 + 92 ) * col2 AS col2 FROM tab0 AS cor0
----
130
14305
4162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( 62 ) * - cor0.col2 col0 FROM tab2 AS cor0
----
1612
1674
2356

query I rowsort
SELECT DISTINCT - cor0.col0 * + cor0.col1 + col1 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL + ( - col0 ) * - cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - 16 * + col0 + + cor0.col0 * 86 AS col0 FROM tab0 AS cor0
----
1680
2450
6230

query I rowsort
SELECT ALL + 31 * col2 FROM tab0 AS cor0
----
1023
2542
31

query I rowsort
SELECT DISTINCT + col0 * col0 + ( col0 ) * + col1 AS col2 FROM tab0
----
16020
2640
4620

query I rowsort
SELECT - col0 * col1 * + col1 + col0 FROM tab1 AS cor0
----
-13440
-2025
-6336

query I rowsort
SELECT - col2 + + col2 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL tab1.col2 + col2 AS col0 FROM tab1
----
108
114
192

query I rowsort
SELECT ALL - col0 * col0 * 40 + - tab0.col0 AS col2 FROM tab0
----
-23064
-316929
-49035

onlyif mysql # use DIV operator for integer division
query I rowsort label-8228
SELECT ALL + 90 DIV col0 col0 FROM tab1 AS cor0
----
1
1
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8228
SELECT ALL + 90 / col0 col0 FROM tab1 AS cor0
----
1
1
30

query I rowsort
SELECT ALL - col1 * cor0.col1 * cor0.col2 FROM tab1 cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL + + 55 AS col2 FROM tab0 AS cor0
----
55
55
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-8231
SELECT ALL 66 DIV + col2 + + 85 col2 FROM tab0 AS cor0
----
151
85
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8231
SELECT ALL 66 / + col2 + + 85 col2 FROM tab0 AS cor0
----
151
85
87

query I rowsort
SELECT + 97 * - col2 + - col2 * col0 AS col0 FROM tab1 cor0
----
-16992
-5400
-9177

query I rowsort
SELECT DISTINCT - cor0.col0 + col2 + + ( ( - col2 ) ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + cor0.col2 * col0 + 82 * - ( col0 ) FROM tab1 AS cor0
----
-1600
-84
1120

query I rowsort
SELECT + ( + col0 ) + + col2 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + col2 * + col1 + + col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-8237
SELECT DISTINCT col1 + - ( - 77 ) DIV + col1 FROM tab1 AS cor0
----
17
18
28

skipif mysql # not compatible
query I rowsort label-8237
SELECT DISTINCT col1 + - ( - 77 ) / + col1 FROM tab1 AS cor0
----
17
18
28

query I rowsort
SELECT ALL - - col1 * - cor0.col1 AS col2 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL - cor0.col1 + + 80 AS col2 FROM tab2 cor0
----
21
49
63

query I rowsort
SELECT DISTINCT col0 * ( - 83 ) * - col1 FROM tab2 AS cor0
----
111469
18011
381966

query I rowsort
SELECT - col0 * col0 * col0 + + col2 * col2 AS col0 FROM tab1 AS cor0
----
-258895
-502784
2889

query I rowsort
SELECT DISTINCT - 88 + cor0.col2 FROM tab2 AS cor0
----
-50
-61
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8243
SELECT DISTINCT + 92 DIV col0 - ( + col2 ) AS col0 FROM tab1 AS cor0
----
-24
-56
-95

skipif mysql # not compatible
query I rowsort label-8243
SELECT DISTINCT + 92 / col0 - ( + col2 ) AS col0 FROM tab1 AS cor0
----
-24
-56
-95

query I rowsort
SELECT DISTINCT - cor1.col2 * cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5ac8aba7baafe9bd6ceb7b5654f2c0b7

query I rowsort
SELECT + 38 + col2 * tab2.col2 AS col2 FROM tab2
----
1482
714
767

onlyif mysql # use DIV operator for integer division
query I rowsort label-8246
SELECT ALL + col1 DIV + cor0.col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-8246
SELECT ALL + col1 / + cor0.col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( cor0.col0 ) * + 77 col0 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT - col2 * + col2 - col1 AS col1 FROM tab0 cor0
----
-1175
-6815
-98

query I rowsort
SELECT ( col0 ) + col1 * + 26 FROM tab2 AS cor0
----
1612
521
813

onlyif mysql # use DIV operator for integer division
query I rowsort label-8250
SELECT ALL col1 * - col1 - + ( col2 + col0 ) DIV - ( col0 + + cor0.col0 ) FROM tab1 AS cor0
----
-100
-168
-667

skipif mysql # not compatible
query I rowsort label-8250
SELECT ALL col1 * - col1 - + ( col2 + col0 ) / - ( col0 + + cor0.col0 ) FROM tab1 AS cor0
----
-100
-168
-667

query I rowsort
SELECT cor0.col2 + col0 * col1 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT + + 6 * col0 FROM tab1 AS cor0
----
18
384
480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 67 + col1 * col0 col1 FROM tab1 AS cor0
----
11
573
973

query I rowsort
SELECT col0 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT 80 * col2 * - CAST ( + col1 AS REAL ) + + col0 + col2 FROM tab1 AS cor0
----
-112263
-45479
-99664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 48 col1 FROM tab0 AS cor0
----
48

query I rowsort
SELECT ALL - col2 * col1 - col1 AS col0 FROM tab2 AS cor0
----
-1593
-663
-868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 11 col2 FROM tab1 AS cor0
----
11
11
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - col0 col0 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + ( - cor0.col0 ) col2 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT + col0 * - ( ( + col0 ) ) + - col2 * - col2 + cor0.col1 * 67 AS col0 FROM tab1 AS cor0
----
-177
3687
4649

query I rowsort
SELECT col1 * 67 + - col0 FROM tab0 AS cor0
----
5738
6008
6464

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab1 cor1, tab0, tab2 AS cor2
----
3645 values hashing to 773bb916e463ebc075d701108532badb

query I rowsort
SELECT ALL - cor0.col2 + - col0 + col1 AS col1 FROM tab2 AS cor0
----
-100
-3
-45

query I rowsort
SELECT DISTINCT col2 * - col2 + col0 AS col1 FROM tab0
----
-1065
-6635
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8266
SELECT + CAST( 27 AS SIGNED ) FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

skipif mysql # not compatible
query I rowsort label-8266
SELECT + CAST ( 27 AS INTEGER ) FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT ALL col2 * col1 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT + 7 * cor0.col1 - - col0 AS col2 FROM tab2 AS cor0
----
198
224
491

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8269
SELECT ALL + CAST( col0 AS SIGNED ) + col0 FROM tab0 cor0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-8269
SELECT ALL + CAST ( col0 AS INTEGER ) + col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT - - col2 * 87 AS col0 FROM tab1 cor0
----
4698
4959
8352

query I rowsort
SELECT DISTINCT 39 * - 88 FROM tab0 AS cor0
----
-3432

query I rowsort
SELECT + 42 AS col1 FROM tab2, tab1 AS cor0, tab1 cor1, tab1 cor2
----
81 values hashing to 4d49d5ffe533e92cf06d98cb59a19b10

query I rowsort
SELECT DISTINCT - cor0.col2 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - 63 + + 92 AS col0 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT DISTINCT - 64 * + col0 AS col1 FROM tab0 AS cor0
----
-1536
-2240
-5696

query I rowsort
SELECT DISTINCT - col0 * - col2 * col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT 41 + col1 FROM tab2 AS cor0
----
100
58
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-8278
SELECT - col2 DIV - col0 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8278
SELECT - col2 / - col0 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 col0 FROM tab1 AS cor0
----
58
58
58

query I rowsort
SELECT DISTINCT - 95 AS col2 FROM tab0, tab1, tab0 AS cor0, tab2
----
-95

query I rowsort
SELECT ALL + 27 FROM tab0
----
27
27
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-8282
SELECT ALL + + cor0.col2 DIV - col2 + col2 AS col2 FROM tab0 cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-8282
SELECT ALL + + cor0.col2 / - col2 + col2 AS col2 FROM tab0 cor0
----
0
32
81

query I rowsort
SELECT - col2 * 28 + + col2 - + 15 FROM tab2
----
-1041
-717
-744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT + 28 FROM tab2
----
28

query I rowsort
SELECT - 52 * - col1 FROM tab0 AS cor0
----
4472
4732
5044

query I rowsort
SELECT - ( - col0 ) + - col2 * col1 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT - ( + col2 ) AS col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT 14 * col0 FROM tab0
----
1246
336
490

query I rowsort
SELECT DISTINCT tab1.col0 + col2 * - col2 FROM tab1
----
-2913
-3185
-9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8291
SELECT + cor0.col0 * CAST( NULL AS SIGNED ) FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8291
SELECT + cor0.col0 * CAST ( NULL AS INTEGER ) FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - + 20 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

query I rowsort
SELECT DISTINCT + - cor0.col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + 1 + + col1 * 40 AS col1 FROM tab0 AS cor0
----
3441
3641
3881

query I rowsort
SELECT DISTINCT - col0 * - col2 * + 66 AS col0 FROM tab1
----
10692
240768
506880

query I rowsort
SELECT - col0 * col0 * + col1 FROM tab2 AS cor0
----
-106097
-1519
-358956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8297
SELECT col0 * CAST( NULL AS SIGNED ) - col2 * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8297
SELECT col0 * CAST ( NULL AS INTEGER ) - col2 * col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab0.col1 + + col2 + - 25 FROM tab0
----
148
73
94

query I rowsort
SELECT col2 + - tab1.col1 * 61 FROM tab1
----
-1532
-553
-697

query I rowsort
SELECT ALL + 35 FROM tab0, tab2 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8301
SELECT ALL - - col2 + - CAST( NULL AS SIGNED ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8301
SELECT ALL - - col2 + - CAST ( NULL AS INTEGER ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + col2 + - col1 AS col0 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8303
SELECT ALL + col0 + - ( - col0 ) DIV col0 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-8303
SELECT ALL + col0 + - ( - col0 ) / col0 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL + 71 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT - 91 * + 66 AS col2 FROM tab2 AS cor0
----
-6006
-6006
-6006

query I rowsort
SELECT - 42 * col0 * col0 AS col0 FROM tab2 cor0
----
-2058
-255528
-262122

query I rowsort
SELECT DISTINCT - 4 FROM tab1 cor0
----
-4

query I rowsort
SELECT DISTINCT 77 + col1 AS col0 FROM tab2 AS cor0
----
108
136
94

query I rowsort
SELECT ALL - + col1 * 27 AS col2 FROM tab2 AS cor0
----
-1593
-459
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8310
SELECT + col1 * col1 + col2 * - CAST( NULL AS DECIMAL ) + col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8310
SELECT + col1 * col1 + col2 * - CAST ( NULL AS REAL ) + col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 32 + + col0 FROM tab0 AS cor0
----
-8
3
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8312
SELECT DISTINCT - - col2 + 38 DIV + col2 + + col0 * + 64 * + col2 AS col0 FROM tab1 AS cor0
----
10422
233529
491616

skipif mysql # not compatible
query I rowsort label-8312
SELECT DISTINCT - - col2 + 38 / + col2 + + col0 * + 64 * + col2 AS col0 FROM tab1 AS cor0
----
10422
233529
491616

query I rowsort
SELECT ( 85 ) FROM tab2 AS cor0
----
85
85
85

query I rowsort
SELECT + ( - 43 ) * - col2 + - 62 AS col2 FROM tab2 AS cor0
----
1056
1099
1572

query I rowsort
SELECT DISTINCT - col1 * + col0 + + col1 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT - - 15 + col1 FROM tab0 AS cor0
----
101
106
112

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT + col0 NOT BETWEEN - col1 * cor0.col1 * + cor0.col1 AND NULL
----

query I rowsort
SELECT ALL + col2 * tab1.col2 + tab1.col1 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT ALL + col1 AS col2 FROM tab2 WHERE NOT col1 NOT IN ( col2 + col2 / + col1 )
----

query I rowsort
SELECT cor0.col0 * + col2 FROM tab1 AS cor0 WHERE - col2 BETWEEN NULL AND ( + col1 * col1 + col1 * + col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NULL NOT IN ( + col2 )
----

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE NOT - col1 * - col2 >= ( + col1 )
----

query I rowsort
SELECT + col2 + + col0 * - col0 AS col2 FROM tab0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT col0 * col2 + - col0 * - tab1.col0 FROM tab1
----
14080
171
7744

query I rowsort
SELECT col0 - col1 AS col0 FROM tab2 WHERE NOT col0 NOT IN ( + col1 + col2 - + col2 * col0 )
----

query I rowsort
SELECT ALL - col0 AS col1 FROM tab2 WHERE NOT NULL BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8327
SELECT + col2 + col0 DIV + col1 FROM tab1
----
102
54
63

skipif mysql # not compatible
query I rowsort label-8327
SELECT + col2 + col0 / + col1 FROM tab1
----
102
54
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-8328
SELECT + col2 + - col2 DIV col0 FROM tab0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-8328
SELECT + col2 + - col2 / col0 FROM tab0
----
1
32
82

query I rowsort
SELECT DISTINCT col2 * col2 + - tab1.col1 FROM tab1
----
2890
3239
9203

query I rowsort
SELECT DISTINCT col0 + col0 * + col1 AS col0 FROM tab0
----
2088
3430
8188

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) BETWEEN + col2 / col2 AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col1 + col2 * - col0 col1 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT - + cor0.col1 * + col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + + col0 * col0 + + col2 AS col1 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT + - cor0.col0 * + col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col1 col2 FROM tab2
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-8337
SELECT tab1.col2 DIV col0 + col2 AS col0 FROM tab1
----
57
72
97

skipif mysql # not compatible
query I rowsort label-8337
SELECT tab1.col2 / col0 + col2 AS col0 FROM tab1
----
57
72
97

query I rowsort
SELECT DISTINCT col1 * + tab2.col0 * - col0 FROM tab2
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col2 col0 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8340
SELECT col1 * cor0.col2 DIV col0 AS col2 FROM tab1 AS cor0
----
15
468
8

skipif mysql # not compatible
query I rowsort label-8340
SELECT col1 * cor0.col2 / col0 AS col2 FROM tab1 AS cor0
----
15
468
8

query I rowsort
SELECT - tab0.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT DISTINCT - col2 * col1 * col0 AS col2 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-8343
SELECT DISTINCT 31 DIV - col0 AS col2 FROM tab2
----
-4
0

skipif mysql # not compatible
query I rowsort label-8343
SELECT DISTINCT 31 / - col0 AS col2 FROM tab2
----
-4
0

query I rowsort
SELECT ALL col2 * - col2 AS col1 FROM tab0 cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-8345
SELECT DISTINCT - col1 + col0 DIV cor0.col2 FROM tab0 AS cor0
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-8345
SELECT DISTINCT - col1 + col0 / cor0.col2 FROM tab0 AS cor0
----
-62
-86
-90

query I rowsort
SELECT + col1 + ( 15 ) + col0 FROM tab2 cor0
----
111
152
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * + cor0.col2 col0 FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * + ( + col2 ) col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT col1 * + ( cor0.col1 ) + + col0 + col0 AS col2 FROM tab2 AS cor0
----
3637
447
975

query I rowsort
SELECT DISTINCT - + col2 + col1 * - col1 FROM tab2 AS cor0
----
-327
-3507
-988

query I rowsort
SELECT ALL col2 * + col1 + + 67 FROM tab0
----
164
2905
7529

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 + + 41 + col2 FROM tab0 AS cor0
----
-1015
-6601
41

query I rowsort
SELECT + col0 + 90 * + ( - col2 ) FROM tab1 cor0
----
-4857
-5066
-8560

query I rowsort
SELECT ALL + col2 + ( cor0.col2 ) * col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT ALL - col1 + col1 * col1 AS col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT - - col0 + + ( - 10 ) AS col0 FROM tab2 AS cor0
----
-3
68
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + ( + 51 ) col0 FROM tab1 cor0
----
115
131
54

query I rowsort
SELECT - col2 * - ( - cor0.col1 ) + - col1 + + ( 81 ) * cor0.col2 FROM tab0 AS cor0
----
-113
-251
-911

onlyif mysql # use DIV operator for integer division
query I rowsort label-8359
SELECT DISTINCT col0 * col0 DIV col1 FROM tab1
----
0
409
492

skipif mysql # not compatible
query I rowsort label-8359
SELECT DISTINCT col0 * col0 / col1 FROM tab1
----
0
409
492

query I rowsort
SELECT - tab0.col2 * col1 + col0 - + col2 FROM tab0
----
-2847
-63
-7455

onlyif mysql # use DIV operator for integer division
query I rowsort label-8361
SELECT - col0 DIV col2 + - col0 AS col0 FROM tab0
----
-24
-70
-90

skipif mysql # not compatible
query I rowsort label-8361
SELECT - col0 / col2 + - col0 AS col0 FROM tab0
----
-24
-70
-90

query I rowsort
SELECT ALL tab2.col2 + col1 * col0 - tab2.col2 AS col1 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8363
SELECT col2 DIV + col2 + - col0 * + col1 FROM tab0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-8363
SELECT col2 / + col2 + - col0 * + col1 FROM tab0
----
-2063
-3394
-8098

query I rowsort
SELECT + col2 FROM tab0 WHERE NULL > ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8365
SELECT ALL col2 * tab1.col2 DIV col0 FROM tab1
----
115
50
972

skipif mysql # not compatible
query I rowsort label-8365
SELECT ALL col2 * tab1.col2 / col0 FROM tab1
----
115
50
972

onlyif mysql # use DIV operator for integer division
query I rowsort label-8366
SELECT DISTINCT tab0.col2 DIV tab0.col1 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-8366
SELECT DISTINCT tab0.col2 / tab0.col1 AS col1 FROM tab0
----
0

query I rowsort
SELECT - col0 * + col2 + - tab2.col2 + col0 * - col2 AS col2 FROM tab2
----
-405
-4082
-6042

query I rowsort
SELECT tab0.col1 AS col1 FROM tab0 WHERE NULL NOT IN ( - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8369
SELECT ALL col0 * col0 DIV col2 FROM tab1
----
0
66
71

skipif mysql # not compatible
query I rowsort label-8369
SELECT ALL col0 * col0 / col2 FROM tab1
----
0
66
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8370
SELECT - - col1 + cor0.col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8370
SELECT - - col1 + cor0.col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 38 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 + 69 col1 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to a1509e33d3aaa01839fa4f2fb69edf25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8373
SELECT ALL CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8373
SELECT ALL CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + col1 * col0 + col2 + ( - col2 ) * 94 FROM tab2 AS cor0
----
-2191
-2294
2184

query I rowsort
SELECT DISTINCT - col1 * col0 + col2 * + 64 FROM tab1 AS cor0
----
3008
3378
5104

query I rowsort
SELECT + col0 - - col0 * cor0.col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT col1 FROM tab2 WHERE NOT NULL >= + col0 + col1 / col1
----

query I rowsort
SELECT col1 * + col2 + col2 FROM tab1 WHERE col0 * - col0 NOT BETWEEN NULL AND - col2 / - col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8379
SELECT - col0 DIV + col0 + col2 col0 FROM tab1
----
53
56
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8379
SELECT - col0 / + col0 + col2 col0 FROM tab1
----
53
56
95

query I rowsort
SELECT ALL tab0.col0 * - col2 - tab0.col0 * + col1 FROM tab0
----
-15397
-2856
-3430

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL < NULL
----

query I rowsort
SELECT - + col2 + - col1 * cor0.col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT col0 * 59 * - col0 FROM tab0
----
-33984
-467339
-72275

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8384
SELECT + CAST( NULL AS SIGNED ) * + 28 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8384
SELECT + CAST ( NULL AS INTEGER ) * + 28 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 80 + col2 * col2 AS col0 FROM tab0 AS cor0
----
-79
1009
6644

query I rowsort
SELECT - 15 + + 45 FROM tab2, tab2 cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT ( + tab2.col2 ) * + col1 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * col0 col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL + - col2 * - 59 AS col2 FROM tab1 AS cor0
----
3186
3363
5664

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8390
SELECT ALL + - CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8390
SELECT ALL + - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 44 * col2 FROM tab1 AS cor0
----
2376
2508
4224

query I rowsort
SELECT - + 89 * col2 AS col2 FROM tab1 AS cor0
----
-4806
-5073
-8544

query I rowsort
SELECT ALL 20 + + col2 AS col0 FROM tab0 AS cor0
----
102
21
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-8394
SELECT DISTINCT + ( - col0 ) DIV + col0 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8394
SELECT DISTINCT + ( - col0 ) / + col0 AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT - col0 * cor0.col2 * col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT - ( - col0 ) * - col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - 55 * cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3396b6e3a9a33a8501d0661305be581c

query I rowsort
SELECT ALL cor1.col1 FROM tab1, tab0 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT - 82 AS col2 FROM tab2 cor0
----
-82
-82
-82

query I rowsort
SELECT DISTINCT + + 7 + col0 AS col1 FROM tab2 cor0
----
14
85
86

query I rowsort
SELECT ALL + 48 * col1 + + 66 FROM tab2 AS cor0
----
1554
2898
882

query I rowsort
SELECT DISTINCT + - col0 - col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL + 94 * col0 + col2 FROM tab1 AS cor0
----
336
6073
7616

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8404
SELECT DISTINCT col2 + + col0 * CAST( NULL AS DECIMAL ) * ( - col1 ) - + col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8404
SELECT DISTINCT col2 + + col0 * CAST ( NULL AS REAL ) * ( - col1 ) - + col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - - 70 * col2 FROM tab0 AS cor0
----
2310
5740
70

query I rowsort
SELECT DISTINCT - cor0.col2 * col0 * col0 + col2 FROM tab0 AS cor0
----
-1224
-18975
-649440

query I rowsort
SELECT ALL + cor0.col0 - + col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL - + ( + cor0.col1 ) * + col0 + cor0.col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT - - col0 * - 48 FROM tab0 cor0
----
-1152
-1680
-4272

query I rowsort
SELECT ALL - col2 * 56 FROM tab0 AS cor0
----
-1848
-4592
-56

query I rowsort
SELECT DISTINCT + + col1 * 59 FROM tab0 AS cor0
----
5074
5369
5723

onlyif mysql # use DIV operator for integer division
query I rowsort label-8412
SELECT ALL col0 DIV col1 + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8412
SELECT ALL col0 / col1 + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT col2 + col0 * + 97 FROM tab2 AS cor0
----
706
7592
7701

onlyif mysql # use DIV operator for integer division
query I rowsort label-8414
SELECT - col2 DIV + col1 + col2 * ( + col1 ) FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-8414
SELECT - col2 / + col1 + col2 * ( + col1 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT + + col1 * col1 + col1 AS col0 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL + - cor0.col1 + + ( col1 ) AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - + col0 * + col0 + col2 FROM tab0 cor0
----
-1224
-543
-7839

query I rowsort
SELECT + 71 AS col1 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT + col1 + cor0.col0 * - col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT - - col2 * - 59 * - col0 AS col0 FROM tab2 AS cor0
----
11151
119652
177118

query I rowsort
SELECT DISTINCT 74 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab2 AS cor2
----
74

query I rowsort
SELECT 78 * - col0 AS col1 FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT ALL 30 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT DISTINCT 92 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
92

query I rowsort
SELECT - + col1 + col2 * + 65 FROM tab1 AS cor0
----
3484
3695
6227

query I rowsort
SELECT DISTINCT - col1 + col1 * + ( + col2 ) AS col0 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-8427
SELECT + ( - col2 ) * col2 + col1 DIV - col0 AS col2 FROM tab1 AS cor0
----
-2924
-3249
-9216

skipif mysql # not compatible
query I rowsort label-8427
SELECT + ( - col2 ) * col2 + col1 / - col0 AS col2 FROM tab1 AS cor0
----
-2924
-3249
-9216

query I rowsort
SELECT + 36 - + cor0.col0 FROM tab0 cor0
----
-53
1
12

query I rowsort
SELECT DISTINCT - 12 FROM tab0, tab1 cor0
----
-12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 21 col0 FROM tab2
----
21
21
21

query I rowsort
SELECT DISTINCT 32 * - col1 FROM tab2
----
-1888
-544
-992

query I rowsort
SELECT DISTINCT 51 AS col2 FROM tab0
----
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col0 ) * + col2 col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + col1 * 36 AS col0 FROM tab0
----
3096
3276
3492

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8435
SELECT - CAST( NULL AS SIGNED ) + ( col0 ) * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8435
SELECT - CAST ( NULL AS INTEGER ) + ( col0 ) * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * col2 * 96 FROM tab0 cor0
----
104544
645504
96

query I rowsort
SELECT + 11 + - col0 * - 77 FROM tab1 AS cor0
----
242
4939
6171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 45 col0 FROM tab1
----
45

query I rowsort
SELECT 66 * col2 + + 88 * tab0.col1 FROM tab0
----
13420
8602
9746

query I rowsort
SELECT 93 + col0 FROM tab1
----
157
173
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8441
SELECT + col2 DIV - col1 FROM tab2 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-8441
SELECT + col2 / - col1 FROM tab2 cor0
----
-2
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8442
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab0, tab1 AS cor0, tab2 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-8442
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab0, tab1 AS cor0, tab2 cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8443
SELECT DISTINCT - 28 DIV - col1 FROM tab1 cor0
----
1
2

skipif mysql # not compatible
query I rowsort label-8443
SELECT DISTINCT - 28 / - col1 FROM tab1 cor0
----
1
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-8444
SELECT DISTINCT col0 DIV col0 AS col1 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-8444
SELECT DISTINCT col0 / col0 AS col1 FROM tab0 AS cor0
----
1

query I rowsort
SELECT DISTINCT tab2.col1 * - cor0.col2 FROM tab2, tab2 cor0
----
9 values hashing to 3f5ea019223361c8c7a5502ecc1aeefb

query I rowsort
SELECT 59 + - 92 FROM tab1, tab2 AS cor0
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

onlyif mysql # use DIV operator for integer division
query I rowsort label-8447
SELECT + - col1 DIV - col1 - - col0 AS col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-8447
SELECT + - col1 / - col1 - - col0 AS col0 FROM tab2 AS cor0
----
79
8
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col0 col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + + col1 + - 25 AS col0 FROM tab2 AS cor0
----
-8
34
6

query I rowsort
SELECT - col1 * 90 * col2 + - cor0.col0 FROM tab1 AS cor0
----
-112400
-126363
-51364

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8451
SELECT DISTINCT CAST( NULL AS SIGNED ) * 33 + - col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8451
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 33 + - col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col1 + cor0.col2 * - col0 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT col1 * - 21 FROM tab1
----
-210
-273
-546

query I rowsort
SELECT ALL ( + col1 ) + col2 * - col0 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - - col1 * - col0 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - 84 * ( + col0 ) FROM tab2 AS cor0
----
-588
-6552
-6636

query I rowsort
SELECT DISTINCT - 92 FROM tab0, tab0 AS cor0
----
-92

query I rowsort
SELECT ALL - col0 * 51 + + col2 * ( - 54 ) FROM tab2 cor0
----
-1815
-5382
-6081

query I rowsort
SELECT ALL - col0 * cor0.col1 + col1 * ( + col1 ) + - col1 FROM tab0 AS cor0
----
5246
5917
91

query I rowsort
SELECT DISTINCT + - ( + 95 ) + - col2 * col2 AS col0 FROM tab2 AS cor0
----
-1539
-771
-824

query I rowsort
SELECT 97 AS col0 FROM tab0, tab1, tab2 cor0
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT ALL ( + cor0.col2 ) + - col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + ( + col2 ) * cor0.col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8464
SELECT DISTINCT ( cor0.col0 ) + col1 * + CAST( NULL AS SIGNED ) - 35 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8464
SELECT DISTINCT ( cor0.col0 ) + col1 * + CAST ( NULL AS INTEGER ) - 35 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + cor0.col0 * + col1 + col0 * - col1 * col2 AS col1 FROM tab2 AS cor0
----
-115050
-49691
-5642

query I rowsort
SELECT DISTINCT 72 * col2 + col1 AS col2 FROM tab0 AS cor0
----
169
2462
5995

query I rowsort
SELECT DISTINCT - 59 + + col1 + col2 * col2 AS col0 FROM tab2 AS cor0
----
1402
676
701

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 99 * + col1 - + col0 * + col2 col0 FROM tab2 AS cor0
----
-1319
2880
3813

query I rowsort
SELECT + col1 * + col1 + - col0 FROM tab1 AS cor0
----
36
673
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 16 col0 FROM tab0 AS cor0
----
16
16
16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8471
SELECT - CAST( NULL AS SIGNED ) col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8471
SELECT - CAST ( NULL AS INTEGER ) col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 23 + - 14 AS col0 FROM tab2
----
9
9
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 * ( + col1 ) + cor0.col2 col0 FROM tab0 AS cor0
----
177537
329316
737091

query I rowsort
SELECT ALL + col0 * col2 * + 11 + 50 + + col1 FROM tab2 cor0
----
2160
22417
33089

onlyif mysql # use DIV operator for integer division
query I rowsort label-8475
SELECT + col2 DIV - cor0.col1 + + col2 FROM tab2 AS cor0
----
26
27
36

skipif mysql # not compatible
query I rowsort label-8475
SELECT + col2 / - cor0.col1 + + col2 FROM tab2 AS cor0
----
26
27
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-8476
SELECT ALL 79 DIV col1 + 20 FROM tab0 AS cor0
----
20
20
20

skipif mysql # not compatible
query I rowsort label-8476
SELECT ALL 79 / col1 + 20 FROM tab0 AS cor0
----
20
20
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-8477
SELECT ALL 83 + col1 * tab0.col1 DIV col1 FROM tab0
----
169
174
180

skipif mysql # not compatible
query I rowsort label-8477
SELECT ALL 83 + col1 * tab0.col1 / col1 FROM tab0
----
169
174
180

query I rowsort
SELECT - - 60 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col1 * + 31 col0 FROM tab2 cor0
----
-1829
-527
-961

query I rowsort
SELECT ALL + col0 * ( col0 ) FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT cor0.col1 + - ( col1 ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * + 36 FROM tab1 cor0
----
1944
2052
3456

query I rowsort
SELECT ALL - - col1 * 18 - 64 AS col2 FROM tab1 AS cor0
----
116
170
404

query I rowsort
SELECT + - col0 + - col2 * col2 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT - col2 + - ( + cor0.col2 ) * + col2 AS col1 FROM tab1 cor0
----
-2970
-3306
-9312

query I rowsort
SELECT ALL - col2 * col0 + + col1 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT + - col1 + ( col0 ) * + col0 AS col1 FROM tab2 AS cor0
----
18
6025
6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-8488
SELECT ALL + - col1 + col2 DIV - col2 + - col2 AS col1 FROM tab0 AS cor0
----
-120
-174
-99

skipif mysql # not compatible
query I rowsort label-8488
SELECT ALL + - col1 + col2 / - col2 + - col2 AS col1 FROM tab0 AS cor0
----
-120
-174
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 7 * col1 col2 FROM tab2
----
-119
-217
-413

query I rowsort
SELECT ALL col1 * tab0.col1 AS col2 FROM tab0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-8491
SELECT col0 DIV - 14 AS col1 FROM tab1
----
-4
-5
0

skipif mysql # not compatible
query I rowsort label-8491
SELECT col0 / - 14 AS col1 FROM tab1
----
-4
-5
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8492
SELECT cor0.col1 * + CAST( col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-8492
SELECT cor0.col1 * + CAST ( col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + - col1 * - 81 FROM tab2 cor0
----
1377
2511
4779

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8494
SELECT ALL + cor0.col2 + + CAST( - col2 AS SIGNED ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8494
SELECT ALL + cor0.col2 + + CAST ( - col2 AS INTEGER ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col2 * - ( + col0 * col1 + + col0 * 66 ) FROM tab2 AS cor0
----
-18333
-249166
-253500

onlyif mysql # use DIV operator for integer division
query I rowsort label-8496
SELECT ALL 45 DIV - 18 FROM tab1, tab0 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

skipif mysql # not compatible
query I rowsort label-8496
SELECT ALL 45 / - 18 FROM tab1, tab0 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT + 95 * - col1 AS col0 FROM tab1 AS cor0
----
-1235
-2470
-950

query I rowsort
SELECT DISTINCT + 20 AS col0 FROM tab2 cor0
----
20

query I rowsort
SELECT - - col2 * col1 * - 77 FROM tab1 AS cor0
----
-108108
-43890
-96096

query I rowsort
SELECT ALL + col1 * + col0 + + 61 AS col2 FROM tab0 AS cor0
----
2125
3456
8160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col2 ) * + col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8502
SELECT ALL col2 * col1 * CAST( + col2 AS SIGNED ) + col1 * - col0 FROM tab1 AS cor0
----
118768
31850
75738

skipif mysql # not compatible
query I rowsort label-8502
SELECT ALL col2 * col1 * CAST ( + col2 AS INTEGER ) + col1 * - col0 FROM tab1 AS cor0
----
118768
31850
75738

query I rowsort
SELECT + 14 * + col0 FROM tab0 AS cor0
----
1246
336
490

query I rowsort
SELECT - - 78 * + col2 FROM tab1 AS cor0
----
4212
4446
7488

onlyif mysql # use DIV operator for integer division
query I rowsort label-8505
SELECT DISTINCT + 21 * tab2.col1 DIV col0 FROM tab2
----
15
4
93

skipif mysql # not compatible
query I rowsort label-8505
SELECT DISTINCT + 21 * tab2.col1 / col0 FROM tab2
----
15
4
93

query I rowsort
SELECT ( + cor1.col0 ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT - - 88 * col1 FROM tab0 AS cor0
----
7568
8008
8536

query I rowsort
SELECT + col1 * col2 * - 13 AS col0 FROM tab0 cor0
----
-1261
-36894
-97006

query I rowsort
SELECT DISTINCT - - 37 + col1 AS col1 FROM tab2 AS cor0
----
54
68
96

query I rowsort
SELECT col0 + - col2 * 70 AS col2 FROM tab0 cor0
----
-2286
-35
-5651

query I rowsort
SELECT ALL + col1 * col0 + 11 AS col0 FROM tab1 AS cor0
----
1051
651
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8512
SELECT - CAST( cor0.col2 AS SIGNED ) + + col0 FROM tab2 cor0
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-8512
SELECT - CAST ( cor0.col2 AS INTEGER ) + + col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT + col2 * col0 - tab0.col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT - cor0.col0 + + 91 AS col0 FROM tab2 AS cor0
----
12
13
84

query I rowsort
SELECT ALL + - col0 + 52 * + 22 FROM tab1 AS cor0
----
1064
1080
1141

query I rowsort
SELECT DISTINCT + col0 * - col2 + + 84 AS col2 FROM tab2 AS cor0
----
-105
-1944
-2918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8517
SELECT - + CAST( col0 AS SIGNED ) + + col2 + col2 AS col1 FROM tab1 cor0
----
105
112
50

skipif mysql # not compatible
query I rowsort label-8517
SELECT - + CAST ( col0 AS INTEGER ) + + col2 + col2 AS col1 FROM tab1 cor0
----
105
112
50

query I rowsort
SELECT DISTINCT - col1 * - 72 FROM tab0 AS cor0
----
6192
6552
6984

query I rowsort
SELECT col2 + - 30 + cor0.col0 * col1 AS col2 FROM tab0 cor0
----
2067
3366
8151

query I rowsort
SELECT ALL col2 + cor0.col2 * + col2 AS col0 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT + - 49 + + 96 AS col2 FROM tab1, tab2, tab1 AS cor0
----
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-8522
SELECT - col2 + col0 DIV + col1 AS col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8522
SELECT - col2 + col0 / + col1 AS col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - ( - col2 ) + + col0 * + col1 AS col0 FROM tab1
----
1136
132
697

query I rowsort
SELECT DISTINCT + col2 + 37 FROM tab0 AS cor0
----
119
38
70

query I rowsort
SELECT ALL ( + cor0.col1 ) FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8526
SELECT 90 + col0 DIV + col0 AS col2 FROM tab0 AS cor0
----
91
91
91

skipif mysql # not compatible
query I rowsort label-8526
SELECT 90 + col0 / + col0 AS col2 FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT + 25 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8528
SELECT - CAST( col2 AS SIGNED ) * + col0 + - cor0.col2 DIV + col2 FROM tab1 AS cor0
----
-163
-3649
-7681

skipif mysql # not compatible
query I rowsort label-8528
SELECT - CAST ( col2 AS INTEGER ) * + col0 + - cor0.col2 / + col2 FROM tab1 AS cor0
----
-163
-3649
-7681

query I rowsort
SELECT DISTINCT 90 * col2 + - col0 FROM tab0 AS cor0
----
2946
55
7291

query I rowsort
SELECT ALL + - cor0.col0 + col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - ( 48 ) * col2 - col0 AS col2 FROM tab2 AS cor0
----
-1303
-1326
-1903

query I rowsort
SELECT - + 82 FROM tab2 AS cor0
----
-82
-82
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8533
SELECT - col0 + - col2 DIV col1 FROM tab1 AS cor0
----
-5
-69
-87

skipif mysql # not compatible
query I rowsort label-8533
SELECT - col0 + - col2 / col1 FROM tab1 AS cor0
----
-5
-69
-87

query I rowsort
SELECT col1 * 50 AS col0 FROM tab1
----
1300
500
650

query I rowsort
SELECT DISTINCT + + 46 FROM tab1 AS cor0
----
46

query I rowsort
SELECT DISTINCT col2 * col0 + col0 * ( col2 ) AS col1 FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT ( 63 ) * + col0 AS col1 FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT ALL + col1 - col0 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - - col2 * col0 + - ( - 84 ) + + cor0.col1 AS col0 FROM tab0 AS cor0
----
216
7473
962

onlyif mysql # use DIV operator for integer division
query I rowsort label-8540
SELECT 54 + - col2 DIV 92 + cor0.col2 * col2 FROM tab2 AS cor0
----
1498
730
783

skipif mysql # not compatible
query I rowsort label-8540
SELECT 54 + - col2 / 92 + cor0.col2 * col2 FROM tab2 AS cor0
----
1498
730
783

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 0 col1 FROM tab2, tab1 cor0, tab1 AS cor1
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8542
SELECT + col0 + col0 + + CAST( - 3 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
175
45
67

skipif mysql # not compatible
query I rowsort label-8542
SELECT + col0 + col0 + + CAST ( - 3 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
175
45
67

query I rowsort
SELECT + 81 AS col2 FROM tab0 cor0
----
81
81
81

query I rowsort
SELECT 36 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

onlyif mysql # use DIV operator for integer division
query I rowsort label-8545
SELECT ALL + - col2 DIV - col1 col2 FROM tab2 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8545
SELECT ALL + - col2 / - col1 col2 FROM tab2 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + cor0.col1 col2 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-8548
SELECT - col2 DIV 48 AS col0 FROM tab1
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-8548
SELECT - col2 / 48 AS col0 FROM tab1
----
-1
-1
-2

query I rowsort
SELECT col1 * ( - col0 ) FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col1 * - col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - col0 * + 56 FROM tab1 AS cor0
----
-168
-3584
-4480

query I rowsort
SELECT ( + col1 ) + + cor0.col2 * 61 AS col1 FROM tab0 AS cor0
----
158
2099
5093

query I rowsort
SELECT col0 - - col1 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL tab2.col1 + 90 * + col1 FROM tab2
----
1547
2821
5369

query I rowsort
SELECT + 88 - col2 FROM tab2 cor0
----
50
61
62

query I rowsort
SELECT ALL 34 FROM tab1, tab0 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT DISTINCT col1 + 87 * + col1 FROM tab2
----
1496
2728
5192

onlyif mysql # use DIV operator for integer division
query I rowsort label-8558
SELECT col1 DIV - 13 + + col0 FROM tab0 AS cor0
----
18
28
82

skipif mysql # not compatible
query I rowsort label-8558
SELECT col1 / - 13 + + col0 FROM tab0 AS cor0
----
18
28
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col2 * cor0.col2 col1 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8560
SELECT ALL + col2 + + CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8560
SELECT ALL + col2 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8561
SELECT col1 * - CAST( + col0 AS SIGNED ) + col2 AS col0 FROM tab0
----
-2031
-3394
-8017

skipif mysql # not compatible
query I rowsort label-8561
SELECT col1 * - CAST ( + col0 AS INTEGER ) + col2 AS col0 FROM tab0
----
-2031
-3394
-8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8562
SELECT ALL col1 + + CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8562
SELECT ALL col1 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + - 87 FROM tab1 AS cor0
----
-30
-33
9

query I rowsort
SELECT - cor0.col1 * ( 71 ) * - col1 + 31 * col0 FROM tab0 AS cor0
----
525860
590710
669124

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8565
SELECT - col2 * - CAST( NULL AS SIGNED ) + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8565
SELECT - col2 * - CAST ( NULL AS INTEGER ) + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8566
SELECT + - col2 DIV - 37 + + col1 col2 FROM tab0 AS cor0
----
86
93
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8566
SELECT + - col2 / - 37 + + col1 col2 FROM tab0 AS cor0
----
86
93
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8567
SELECT ALL ( - col0 + - tab0.col1 ) DIV col1 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8567
SELECT ALL ( - col0 + - tab0.col1 ) / col1 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 36 col1 FROM tab1, tab2 AS cor0
----
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-8569
SELECT ALL + tab0.col1 * col0 DIV + col1 AS col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8569
SELECT ALL + tab0.col1 * col0 / + col1 AS col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 10 col2 FROM tab1
----
10
10
10

query I rowsort
SELECT ( col1 ) - col0 AS col2 FROM tab2
----
-19
-62
24

query I rowsort
SELECT - col1 * col0 + 13 * col0 FROM tab0 AS cor0
----
-1752
-2940
-6942

onlyif mysql # use DIV operator for integer division
query I rowsort label-8573
SELECT + col2 DIV - cor0.col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8573
SELECT + col2 / - cor0.col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 33 + - col1 AS col2 FROM tab0 AS cor0
----
-119
-124
-130

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col1 * col1 + CAST ( - 53 AS REAL ) FROM tab2 AS cor0
----
236
3428
908

query I rowsort
SELECT - col0 * + col2 + - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT col1 + cor0.col1 - - 88 AS col0 FROM tab0 cor0
----
260
270
282

query I rowsort
SELECT + 43 * - col0 - - col0 FROM tab1 AS cor0
----
-126
-2688
-3360

query I rowsort
SELECT ALL + 7 FROM tab1
----
7
7
7

query I rowsort
SELECT + col0 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ( col0 ) AS col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT - 29 AS col2 FROM tab0 cor0
----
-29
-29
-29

query I rowsort
SELECT - 64 AS col1 FROM tab2 AS cor0
----
-64
-64
-64

query I rowsort
SELECT DISTINCT - + 43 + cor0.col0 * col2 FROM tab1 AS cor0
----
119
3605
7637

query I rowsort
SELECT + 31 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8586
SELECT DISTINCT col0 / - CAST( NULL AS SIGNED ) + + col2 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8586
SELECT DISTINCT col0 / - CAST ( NULL AS INTEGER ) + + col2 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col1 * + 92 AS col0 FROM tab1 AS cor0
----
1196
2392
920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8588
SELECT + col1 * CAST( col1 AS SIGNED ) + + col1 AS col2 FROM tab0 cor0
----
7482
8372
9506

skipif mysql # not compatible
query I rowsort label-8588
SELECT + col1 * CAST ( col1 AS INTEGER ) + + col1 AS col2 FROM tab0 cor0
----
7482
8372
9506

query I rowsort
SELECT ALL - col0 * ( col0 ) + - col0 * ( - col1 ) AS col1 FROM tab0 AS cor0
----
1488
178
2170

query I rowsort
SELECT DISTINCT + + col0 + 88 * col2 FROM tab0 AS cor0
----
123
2928
7305

query I rowsort
SELECT col0 - + col2 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + + col2 + + ( - col0 ) * + col2 AS col1 FROM tab0 cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL - cor0.col1 * + 58 AS col2 FROM tab2 AS cor0
----
-1798
-3422
-986

query I rowsort
SELECT DISTINCT + col0 + + 54 FROM tab2 AS cor0
----
132
133
61

query I rowsort
SELECT DISTINCT + ( col0 ) - - ( - col0 ) * - col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT ALL + col1 - tab2.col1 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * col2 - col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT ALL + col2 * col2 - + 15 FROM tab1
----
2901
3234
9201

query I rowsort
SELECT ALL + cor0.col1 + - 47 * - col2 FROM tab2 AS cor0
----
1281
1300
1803

query I rowsort
SELECT DISTINCT col1 + 43 * + col2 AS col2 FROM tab2 cor0
----
1177
1192
1651

onlyif mysql # use DIV operator for integer division
query I rowsort label-8601
SELECT 93 DIV col0 AS col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-8601
SELECT 93 / col0 AS col0 FROM tab0
----
1
2
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8602
SELECT + col2 + - col0 * + CAST( NULL AS SIGNED ) - + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8602
SELECT + col2 + - col0 * + CAST ( NULL AS INTEGER ) - + col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + - 94 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1222
-2444
-940

query I rowsort
SELECT ALL 52 * - col1 - + col2 * ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-1514
-4168
-8356

query I rowsort
SELECT DISTINCT - 11 + 30 + - col0 * col2 FROM tab1 AS cor0
----
-143
-3629
-7661

query I rowsort
SELECT ALL - + col1 * ( col2 ) - - ( col2 + col2 ) AS col1 FROM tab2 AS cor0
----
-1482
-570
-783

query I rowsort
SELECT DISTINCT 92 + col2 AS col1 FROM tab2 AS cor0
----
118
119
130

query I rowsort
SELECT col2 * + 11 FROM tab2
----
286
297
418

query I rowsort
SELECT + ( 19 ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT ALL + col0 * - col0 * - col2 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT 42 * + col1 FROM tab1 AS cor0
----
1092
420
546

query I rowsort
SELECT ALL - + 45 * + col1 FROM tab1 AS cor0
----
-1170
-450
-585

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8613
SELECT CAST( NULL AS DECIMAL ) * cor0.col0 * col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8613
SELECT CAST ( NULL AS REAL ) * cor0.col0 * col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + 79 * col0 AS col0 FROM tab1 cor0
----
211
5046
6307

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + + cor0.col1 col2 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 73 + cor0.col1 col1 FROM tab1 AS cor0
----
83
86
99

query I rowsort
SELECT ALL - - col1 * - cor0.col1 * - col0 + + col1 * - col1 AS col2 FROM tab2 AS cor0
----
22542
268037
5766

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab2, tab0 AS cor1
----
3645 values hashing to ca4c79a162f92454e0544707b897521a

query I rowsort
SELECT + - col1 * col2 + + col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL - col1 * col1 + + col0 AS col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT 25 + col1 AS col0 FROM tab1 AS cor0
----
35
38
51

query I rowsort
SELECT ( - col2 ) + + col2 * + col2 FROM tab0 AS cor0
----
0
1056
6642

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) + col2 col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8624
SELECT ALL 15 DIV - 46 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8624
SELECT ALL 15 / - 46 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( col1 AS REAL ) AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT + col1 * + col1 - + col1 * col2 FROM tab1 AS cor0
----
-1079
-470
-728

onlyif mysql # use DIV operator for integer division
query I rowsort label-8627
SELECT DISTINCT ( - col0 ) DIV col1 + cor0.col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8627
SELECT DISTINCT ( - col0 ) / col1 + cor0.col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + + ( + col0 ) * col2 + cor0.col2 + 8 AS col2 FROM tab0 AS cor0
----
44
7388
833

query I rowsort
SELECT + - 8 + + col1 AS col0 FROM tab2 AS cor0
----
23
51
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8630
SELECT DISTINCT 75 * - col2 + col1 DIV 61 AS col0 FROM tab1 cor0
----
-4050
-4275
-7200

skipif mysql # not compatible
query I rowsort label-8630
SELECT DISTINCT 75 * - col2 + col1 / 61 AS col0 FROM tab1 cor0
----
-4050
-4275
-7200

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0, tab1 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 4c87430a2010fee8daf6d04acf0ad703

onlyif mysql # use DIV operator for integer division
query I rowsort label-8632
SELECT col1 + col1 DIV - col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-8632
SELECT col1 + col1 / - col1 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT + 92 * col0 + col0 + col2 FROM tab1 AS cor0
----
333
6009
7536

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8634
SELECT - ( + col2 ) * CAST( NULL AS SIGNED ) + col2 + + col2 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8634
SELECT - ( + col2 ) * CAST ( NULL AS INTEGER ) + col2 + + col2 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 54 + - col0 * + 20 * ( + col0 + col1 ) FROM tab0 AS cor0
----
-320454
-52854
-92454

query I rowsort
SELECT - col0 * ( - col0 ) + - col1 AS col2 FROM tab0
----
1128
490
7830

query I rowsort
SELECT DISTINCT ( + col2 * col0 ) FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL - col2 + col0 + - col2 FROM tab1 AS cor0
----
-105
-112
-50

query I rowsort
SELECT - + col2 - - col0 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT + col0 + + col1 * cor0.col1 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8641
SELECT ALL + col0 * + CAST( NULL AS SIGNED ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8641
SELECT ALL + col0 * + CAST ( NULL AS INTEGER ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 - - 38 * - cor0.col2 FROM tab0 AS cor0
----
-1230
-3
-3027

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8643
SELECT DISTINCT - - col1 * CAST( NULL AS SIGNED ) + col1 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8643
SELECT DISTINCT - - col1 * CAST ( NULL AS INTEGER ) + col1 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - col2 * ( col2 ) AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col0 * 85 * - cor0.col1 - col2 FROM tab2 cor0
----
-114193
-18472
-391196

query I rowsort
SELECT + + col2 + 67 + - col1 * - col1 AS col0 FROM tab2 AS cor0
----
1055
3574
394

query I rowsort
SELECT + cor0.col1 * + col0 - + 29 AS col0 FROM tab1 AS cor0
----
1011
49
611

query I rowsort
SELECT ALL col2 * ( - cor0.col0 ) + - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT + - col1 + - 84 FROM tab1 AS cor0
----
-110
-94
-97

query I rowsort
SELECT ( + 37 ) AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

onlyif mysql # use DIV operator for integer division
query I rowsort label-8651
SELECT - - col2 DIV - col2 + - col2 * + col2 AS col1 FROM tab0 AS cor0
----
-1090
-2
-6725

skipif mysql # not compatible
query I rowsort label-8651
SELECT - - col2 / - col2 + - col2 * + col2 AS col1 FROM tab0 AS cor0
----
-1090
-2
-6725

query I rowsort
SELECT + cor0.col2 * - col0 AS col1 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-8653
SELECT col0 + col0 DIV - ( col1 ) AS col2 FROM tab2
----
7
75
77

skipif mysql # not compatible
query I rowsort label-8653
SELECT col0 + col0 / - ( col1 ) AS col2 FROM tab2
----
7
75
77

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 cor0 CROSS JOIN tab1, tab2 cor1, tab0, tab0 AS cor2
----
3645 values hashing to 1713adaf687595322d888d4eeefdbbc8

query I rowsort
SELECT - + 26 + ( + cor0.col2 ) FROM tab1 AS cor0
----
28
31
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-8656
SELECT ALL col0 + 61 DIV + col1 + tab0.col1 AS col1 FROM tab0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-8656
SELECT ALL col0 + 61 / + col1 + tab0.col1 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) FROM tab1, tab0 AS cor0
----
-24
-35
-89

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab2 AS cor2, tab0 AS cor3
----
3645 values hashing to be7848c91584d04f21fd5bbb0d239aca

query I rowsort
SELECT col0 * - ( + ( col2 ) ) AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT col0 + 99 FROM tab2 AS cor0
----
106
177
178

query I rowsort
SELECT ALL - + cor0.col0 * 13 FROM tab2 AS cor0
----
-1014
-1027
-91

query I rowsort
SELECT - col0 - ( - col0 ) * - cor0.col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT + col0 - 61 AS col0 FROM tab1 AS cor0
----
-58
19
3

query I rowsort
SELECT DISTINCT - 73 - + 11 FROM tab2, tab2 AS cor0
----
-84

query I rowsort
SELECT ALL - cor1.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT col1 + 99 FROM tab2
----
116
130
158

query I rowsort
SELECT ALL 63 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT ALL + col2 + + 13 FROM tab2
----
39
40
51

query I rowsort
SELECT - + col2 * + col1 + col2 - - 8 AS col2 FROM tab2 AS cor0
----
-1500
-600
-802

query I rowsort
SELECT ALL tab1.col1 + ( - col1 ) FROM tab1
----
0
0
0

query I rowsort
SELECT col2 + 66 AS col1 FROM tab1 AS cor0
----
120
123
162

query I rowsort
SELECT 11 AS col1 FROM tab1 cor0
----
11
11
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8673
SELECT DISTINCT + col2 / CAST( NULL AS DECIMAL ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-8673
SELECT DISTINCT + col2 / CAST ( NULL AS REAL ) FROM tab0
----
NULL

query I rowsort
SELECT + 85 FROM tab0, tab0 cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + 8 + + 77 col0 FROM tab2
----
133
701
709

query I rowsort
SELECT + col0 * + 26 AS col1 FROM tab0
----
2314
624
910

query I rowsort
SELECT 25 * - cor0.col0 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to eee5537b47f821d2e4fdd78e5fad2a2d

query I rowsort
SELECT + 58 + col1 AS col1 FROM tab2 AS cor0
----
117
75
89

query I rowsort
SELECT 95 * + col0 + cor0.col0 * 23 FROM tab2 AS cor0
----
826
9204
9322

query I rowsort
SELECT - - cor0.col0 + + col0 AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT ( - col1 ) * 1 AS col0 FROM tab2
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8682
SELECT DISTINCT - ( + col0 ) DIV - CAST( - 18 + - col0 AS SIGNED ) AS col2 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-8682
SELECT DISTINCT - ( + col0 ) / - CAST ( - 18 + - col0 AS INTEGER ) AS col2 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8683
SELECT - ( col1 ) + 83 DIV + ( tab0.col1 ) AS col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8683
SELECT - ( col1 ) + 83 / + ( tab0.col1 ) AS col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL 0 * - col0 + + col0 * + 75 * col1 AS col2 FROM tab0 AS cor0
----
154800
254625
607425

onlyif mysql # use DIV operator for integer division
query I rowsort label-8685
SELECT DISTINCT - ( cor0.col2 ) DIV + 97 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8685
SELECT DISTINCT - ( cor0.col2 ) / + 97 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL 60 AS col0 FROM tab0 AS cor0
----
60
60
60

query I rowsort
SELECT - - col2 * col1 AS col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL col0 * - col0 + - col0 * + col0 AS col0 FROM tab0 cor0
----
-1152
-15842
-2450

query I rowsort
SELECT + col1 * ( + 42 ) FROM tab1 AS cor0
----
1092
420
546

query I rowsort
SELECT DISTINCT tab2.col1 * - ( + col2 ) AS col1 FROM tab2
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-8691
SELECT + + col0 DIV - col0 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8691
SELECT + + col0 / - col0 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8692
SELECT - col2 + cor0.col1 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-8692
SELECT - col2 + cor0.col1 / cor0.col1 AS col1 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT - col0 * col1 * col1 - col0 FROM tab1
----
-13600
-2031
-6464

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - col0 col2 FROM tab0
----
171
36
57

query I rowsort
SELECT - cor0.col2 - col2 * col2 AS col1 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT col2 * - col2 + col1 AS col2 FROM tab1 cor0
----
-2890
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col1 col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT col2 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL col2 + - col1 * col2 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-8700
SELECT ALL - - col0 * col1 - col2 DIV col0 FROM tab0 cor0
----
2063
3395
8099

skipif mysql # not compatible
query I rowsort label-8700
SELECT ALL - - col0 * col1 - col2 / col0 FROM tab0 cor0
----
2063
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-8701
SELECT ALL cor0.col2 * - col2 DIV + col2 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-8701
SELECT ALL cor0.col2 * - col2 / + col2 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + col0 * + col0 col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL col2 * - col2 + col0 * - col0 * cor0.col1 FROM tab2 AS cor0
----
-107541
-2248
-359632

query I rowsort
SELECT + cor0.col0 + + col2 * col0 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-8705
SELECT DISTINCT col0 DIV + col0 + - col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-8705
SELECT DISTINCT col0 / + col0 + - col0 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT DISTINCT col0 * + col0 + col2 FROM tab0 cor0
----
1226
609
8003

query I rowsort
SELECT + col1 + - col2 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + cor0.col1 * cor0.col1 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to ae5946db6904798b8afac35f5777bb79

query I rowsort
SELECT + col2 - col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 - tab0.col2 * - tab0.col0 FROM tab0
----
132
7389
878

query I rowsort
SELECT ALL col0 * + tab1.col0 - - col0 AS col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT - cor0.col0 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8713
SELECT col2 - col0 DIV + col1 FROM tab2
----
25
27
34

skipif mysql # not compatible
query I rowsort label-8713
SELECT col2 - col0 / + col1 FROM tab2
----
25
27
34

query IIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 WHERE NOT NULL < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - tab2.col1 col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + col2 + col0 * - col0 FROM tab2
----
-22
-6058
-6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * - col2 col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - 36 + - col0 AS col1 FROM tab1 AS cor0
----
-100
-116
-39

query I rowsort
SELECT - col2 + + col0 AS col0 FROM tab1 WHERE + col0 / col0 <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8720
SELECT tab1.col1 * col0 + col1 * col0 DIV col1 FROM tab1
----
1120
704
81

skipif mysql # not compatible
query I rowsort label-8720
SELECT tab1.col1 * col0 + col1 * col0 / col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT - col2 + - col0 + - col1 FROM tab0
----
-133
-143
-262

query I rowsort
SELECT ALL - 88 AS col1 FROM tab2 AS cor0
----
-88
-88
-88

query I rowsort
SELECT ALL - col0 * col2 * 40 AS col1 FROM tab1 cor0
----
-145920
-307200
-6480

query I rowsort
SELECT - ( - col1 ) * - ( + col2 ) * - col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT + col1 * + cor0.col1 * + col0 AS col1 FROM tab1 AS cor0
----
13520
2028
6400

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL IN ( + col2 )
----

query I rowsort
SELECT ALL + tab0.col2 * + col1 * col2 AS col1 FROM tab0
----
611884
93654
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 col1 FROM tab1 WHERE NOT col1 + col1 * + col2 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT + col2 * - col1 / + tab0.col0 AS col1 FROM tab0 WHERE NULL IN ( + col2 + - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - col0 * col2 col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - col1 + col0 * col0 AS col2 FROM tab1
----
-17
4086
6387

query I rowsort
SELECT col2 * + col1 * col1 AS col0 FROM tab1 WHERE NOT NULL NOT BETWEEN ( NULL ) AND col0 * col0 * + col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8733
SELECT col2 * - col0 - + col2 DIV col0 AS col2 FROM tab2
----
-192
-2028
-3002

skipif mysql # not compatible
query I rowsort label-8733
SELECT col2 * - col0 - + col2 / col0 AS col2 FROM tab2
----
-192
-2028
-3002

query I rowsort
SELECT ALL col1 + col1 + + col1 * col0 FROM tab2
----
1377
279
4720

query I rowsort
SELECT DISTINCT col0 + - tab1.col0 + col0 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8736
SELECT DISTINCT col2 + col0 + - col2 DIV col0 AS col0 FROM tab2
----
104
117
31

skipif mysql # not compatible
query I rowsort label-8736
SELECT DISTINCT col2 + col0 + - col2 / col0 AS col0 FROM tab2
----
104
117
31

query I rowsort
SELECT DISTINCT - col1 * col1 * col2 AS col2 FROM tab2
----
-10982
-25947
-90506

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL BETWEEN ( NULL ) AND - col1
----

query I rowsort
SELECT col1 * col1 * cor0.col1 + - col0 FROM tab0 AS cor0
----
636032
753482
912638

query I rowsort
SELECT DISTINCT cor0.col1 * - col2 + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL - col2 + - col0 + col2 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + col0 - + cor0.col2 FROM tab0 cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * - cor0.col1 col0 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT ALL - tab2.col1 + col0 * + col2 AS col0 FROM tab2
----
158
1969
2985

query I rowsort
SELECT + col1 + col1 - col1 FROM tab0
----
86
91
97

query I rowsort
SELECT col1 * + col0 * - col1 AS col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT col2 + + col2 * col1 AS col0 FROM tab0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - tab0.col1 + + col0 * + tab0.col2 FROM tab0
----
-62
706
7207

query I rowsort
SELECT DISTINCT + tab0.col1 * col0 - col1 AS col1 FROM tab0 WHERE col0 > ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col0 * + col1 IN ( - tab2.col1 + + tab2.col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL col2 * + col2 - col1 FROM tab0
----
-96
1003
6633

query I rowsort
SELECT + col1 + + col0 FROM tab1 WHERE NULL > NULL
----

query I rowsort
SELECT + tab0.col1 - col0 * col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL col0 - col0 AS col1 FROM tab1
----
0
0
0

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) > - col0
----

query I rowsort
SELECT col0 * col0 + col1 FROM tab2
----
6143
6258
80

query I rowsort
SELECT tab2.col0 + - col1 * col2 AS col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT col0 * + col2 - col1 * col1 AS col1 FROM tab0
----
-6604
-9374
-983

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL <= ( NULL )
----

query I rowsort
SELECT ALL + col0 + + tab2.col2 + col2 FROM tab2
----
130
155
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-8761
SELECT col2 * - col2 + col0 + + col1 DIV + col1 col2 FROM tab1
----
-2912
-3184
-9135

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8761
SELECT col2 * - col2 + col0 + + col1 / + col1 col2 FROM tab1
----
-2912
-3184
-9135

query I rowsort
SELECT col0 - + tab0.col0 * col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT tab2.col1 * col2 + ( + col1 ) * - col0 AS col0 FROM tab2
----
-3068
-697
620

query I rowsort
SELECT ALL 68 AS col1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col0 + cor1.col2 col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 8a206af99264e378e55b667df888459e

query I rowsort
SELECT ALL col0 + - col0 * - col1 FROM tab2
----
1422
224
4680

query I rowsort
SELECT ALL - ( tab0.col2 ) + col0 * - col2 + + col0 FROM tab0
----
-1
-7291
-801

onlyif mysql # use DIV operator for integer division
query I rowsort label-8768
SELECT ALL + col0 DIV - col1 + - col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8768
SELECT ALL + col0 / - col1 + - col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + + 95 + col1 * col2 FROM tab1 AS cor0
----
1343
1499
665

query I rowsort
SELECT + ( + col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 98 * - tab2.col1 FROM tab2
----
-1666
-3038
-5782

query I rowsort
SELECT ALL + ( + col2 ) * 10 FROM tab2 AS cor0
----
260
270
380

query I rowsort
SELECT + + col1 * 2 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - col0 * + col2 * col0 + + col0 FROM tab1 AS cor0
----
-233408
-483
-614320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8775
SELECT + - col2 + CAST( NULL AS SIGNED ) + - col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8775
SELECT + - col2 + CAST ( NULL AS INTEGER ) + - col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 * ( col0 ) * + col2 AS col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT ALL cor0.col0 * - 15 FROM tab0 AS cor0
----
-1335
-360
-525

query I rowsort
SELECT - col2 + col2 * + col2 FROM tab1 AS cor0
----
2862
3192
9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-8779
SELECT DISTINCT + col2 * col1 DIV + 9 FROM tab0 AS cor0
----
10
315
829

skipif mysql # not compatible
query I rowsort label-8779
SELECT DISTINCT + col2 * col1 / + 9 FROM tab0 AS cor0
----
10
315
829

query I rowsort
SELECT ALL - + col1 * + 89 FROM tab1 AS cor0
----
-1157
-2314
-890

onlyif mysql # use DIV operator for integer division
query I rowsort label-8781
SELECT ALL col1 * ( - col1 ) DIV col1 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-8781
SELECT ALL col1 * ( - col1 ) / col1 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT - col2 * 99 FROM tab2 AS cor0
----
-2574
-2673
-3762

onlyif mysql # use DIV operator for integer division
query I rowsort label-8783
SELECT - + col1 DIV + ( - col1 ) FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8783
SELECT - + col1 / + ( - col1 ) FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT col2 + col2 * - col0 AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT + - col2 * - cor0.col1 + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL - 50 + - col2 AS col0 FROM tab1 AS cor0
----
-104
-107
-146

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col0 col0 FROM tab2 cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8788
SELECT ALL - + CAST( col0 AS SIGNED ) * cor0.col0 + + cor0.col2 FROM tab2 AS cor0
----
-22
-6058
-6203

skipif mysql # not compatible
query I rowsort label-8788
SELECT ALL - + CAST ( col0 AS INTEGER ) * cor0.col0 + + cor0.col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT 67 FROM tab0 cor0
----
67
67
67

query I rowsort
SELECT ALL + ( + col0 ) + - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT 22 * - 62 * - col2 FROM tab0 AS cor0
----
111848
1364
45012

query I rowsort
SELECT ALL + col1 * + col1 * col0 + - 53 FROM tab0 AS cor0
----
177451
329262
736956

query I rowsort
SELECT DISTINCT 24 - cor0.col0 AS col2 FROM tab2 cor0
----
-54
-55
17

query I rowsort
SELECT + 81 AS col0 FROM tab0 AS cor0
----
81
81
81

query I rowsort
SELECT ALL + 64 * - col2 + col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT DISTINCT + cor0.col1 + 31 AS col0 FROM tab0 AS cor0
----
117
122
128

query I rowsort
SELECT ALL 53 * + col2 + + col1 FROM tab0 AS cor0
----
150
1835
4437

query I rowsort
SELECT + + ( col1 ) * + 24 FROM tab1 AS cor0
----
240
312
624

query I rowsort
SELECT - 57 * col0 + col0 AS col0 FROM tab0 AS cor0
----
-1344
-1960
-4984

skipif mysql # not compatible
query I rowsort
SELECT - cor0.col0 - CAST ( tab2.col0 AS REAL ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 625e99802c37f1b6e261b243e04b6cd7

query I rowsort
SELECT DISTINCT - col2 * - col2 * - col1 AS col1 FROM tab0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 78 + - tab2.col1 * cor0.col2 col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 08846260cb5e7214985436152e28c020

query I rowsort
SELECT 84 AS col2 FROM tab0 cor0
----
84
84
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 97 col0 FROM tab1 AS cor0
----
97
97
97

query I rowsort
SELECT - 37 + cor0.col2 AS col2 FROM tab2 AS cor0
----
-10
-11
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( cor0.col0 ) * 13 col2 FROM tab2, tab0 AS cor0
----
1157
312
455

query I rowsort
SELECT + col2 + col0 * col0 AS col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT cor0.col2 + cor0.col2 * - col0 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-8809
SELECT + 85 DIV + col2 AS col0 FROM tab0
----
1
2
85

skipif mysql # not compatible
query I rowsort label-8809
SELECT + 85 / + col2 AS col0 FROM tab0
----
1
2
85

query I rowsort
SELECT cor0.col0 - ( ( col1 ) ) AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL col0 * - ( + col0 ) + col2 FROM tab2 AS cor0
----
-22
-6058
-6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT 62 AS col2 FROM tab2, tab2 AS cor0
----
62

query I rowsort
SELECT + - col0 + ( - col1 ) FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL ( + col2 * - col1 + + col1 ) AS col2 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT + 21 AS col2 FROM tab0
----
21
21
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + 5 FROM tab2, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

skipif mysql # not compatible
query I rowsort
SELECT ALL cor1.col1 * + CAST ( - ( - cor1.col0 ) AS REAL ) AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 6387e809cb1e467e8e7184dc79f3a43b

query I rowsort
SELECT + 97 + cor0.col0 FROM tab2 cor0
----
104
175
176

query I rowsort
SELECT 90 + + 12 + + col1 * ( col1 ) FROM tab1 AS cor0
----
202
271
778

query I rowsort
SELECT ALL - col0 + - 72 FROM tab1 AS cor0
----
-136
-152
-75

query I rowsort
SELECT DISTINCT - 31 + + 69 FROM tab0 cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
38

query I rowsort
SELECT - col1 + 56 AS col2 FROM tab1
----
30
43
46

query I rowsort
SELECT - 58 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 897f42d096eff3935f4f50603850c23b

query I rowsort
SELECT - + col2 * 37 FROM tab0 AS cor0
----
-1221
-3034
-37

onlyif mysql # use DIV operator for integer division
query I rowsort label-8827
SELECT ALL - - col1 DIV col2 + ( cor0.col0 ) + + col2 col2 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8827
SELECT ALL - - col1 / col2 + ( cor0.col0 ) + + col2 col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8828
SELECT cor0.col0 * - CAST( + 47 AS SIGNED ) FROM tab0 AS cor0
----
-1128
-1645
-4183

skipif mysql # not compatible
query I rowsort label-8828
SELECT cor0.col0 * - CAST ( + 47 AS INTEGER ) FROM tab0 AS cor0
----
-1128
-1645
-4183

query I rowsort
SELECT - col1 * 87 FROM tab2 AS cor0
----
-1479
-2697
-5133

query I rowsort
SELECT - col0 * col2 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT 27 * - cor0.col1 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to d43cb5ec49d07ed28abf45a3dad5bd4d

query I rowsort
SELECT DISTINCT - col2 + - col0 * - col2 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-8833
SELECT DISTINCT - - ( - col0 ) + + cor0.col0 DIV ( + col2 ) FROM tab1 cor0
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-8833
SELECT DISTINCT - - ( - col0 ) + + cor0.col0 / ( + col2 ) FROM tab1 cor0
----
-3
-63
-80

query I rowsort
SELECT - + ( col0 ) * 84 + col1 AS col1 FROM tab0 AS cor0
----
-1930
-2843
-7385

query I rowsort
SELECT + - 92 + + col2 AS col2 FROM tab2 AS cor0
----
-54
-65
-66

query I rowsort
SELECT - cor0.col0 * col1 + 51 FROM tab2 cor0
----
-1292
-166
-4551

query I rowsort
SELECT ALL + ( + col2 ) + col0 * - col2 * col1 AS col2 FROM tab0 cor0
----
-3394
-664036
-68079

query I rowsort
SELECT ALL - col0 + col1 AS col2 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT - - ( col0 ) * + col2 * + col2 + + cor0.col2 FROM tab2 AS cor0
----
114114
5130
52754

query I rowsort
SELECT DISTINCT col1 * - col1 + - col0 * - col0 FROM tab2 AS cor0
----
-912
2603
5952

query I rowsort
SELECT ALL + col0 - 16 FROM tab2 AS cor0
----
-9
62
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + 11 col0 FROM tab0 cor0
----
12
44
93

query I rowsort
SELECT DISTINCT - + col1 * + ( 90 ) + col2 FROM tab0 AS cor0
----
-7707
-8108
-8729

query I rowsort
SELECT + + col2 * col2 AS col1 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + col2 * - col2 - 87 AS col2 FROM tab0 AS cor0
----
-1176
-6811
-88

query I rowsort
SELECT + col1 * - 12 FROM tab1 AS cor0
----
-120
-156
-312

query I rowsort
SELECT ALL + col1 * + tab1.col1 + ( col0 ) * - col1 AS col2 FROM tab1
----
-540
-871
598

query I rowsort
SELECT DISTINCT + col1 * + ( + col1 ) FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - col2 - + cor0.col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - col0 * - ( + col2 ) + col1 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT 28 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
28

query I rowsort
SELECT - col2 + ( - col1 ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL - - col2 + + col0 * 38 FROM tab2 AS cor0
----
293
2990
3040

query I rowsort
SELECT 97 * + 33 FROM tab0, tab1 cor0
----
9 values hashing to 46c382ac902bdd21ff97adfd7222538d

query I rowsort
SELECT DISTINCT - col0 + 6 FROM tab2 AS cor0
----
-1
-72
-73

query I rowsort
SELECT + 20 * col2 + col1 FROM tab1
----
1106
1150
1933

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 * col0 col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT + col1 * col0 + - col2 * + col1 FROM tab2
----
-620
3068
697

query I rowsort
SELECT + col2 * - 63 * 7 + col1 * col1 FROM tab0
----
-27881
-7157
8968

query I rowsort
SELECT - tab1.col1 + - 32 AS col1 FROM tab1
----
-42
-45
-58

query I rowsort
SELECT col0 - - ( tab0.col1 ) * + col2 AS col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL - + col0 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col0 + tab2.col2 * - col2 AS col1 FROM tab2
----
-1365
-598
-722

onlyif mysql # use DIV operator for integer division
query I rowsort label-8864
SELECT - 55 DIV + tab0.col2 FROM tab0
----
-1
-55
0

skipif mysql # not compatible
query I rowsort label-8864
SELECT - 55 / + tab0.col2 FROM tab0
----
-1
-55
0

query I rowsort
SELECT + 92 AS col1 FROM tab1
----
92
92
92

query I rowsort
SELECT ALL cor0.col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT col1 - - col2 * col0 AS col0 FROM tab1
----
188
3658
7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8868
SELECT ALL - col1 + - col0 * CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8868
SELECT ALL - col1 + - col0 * CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 85 * cor0.col1 FROM tab0 AS cor0
----
-7310
-7735
-8245

query I rowsort
SELECT - + col1 * col2 + + ( - col1 ) FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT ( col0 * + col0 ) FROM tab2
----
49
6084
6241

query I rowsort
SELECT col1 * - 82 FROM tab0
----
-7052
-7462
-7954

onlyif mysql # use DIV operator for integer division
query I rowsort label-8873
SELECT - ( tab1.col2 ) + - tab1.col1 DIV 31 - - tab1.col0 * + col0 AS col1 FROM tab1
----
-45
4039
6304

skipif mysql # not compatible
query I rowsort label-8873
SELECT - ( tab1.col2 ) + - tab1.col1 / 31 - - tab1.col0 * + col0 AS col1 FROM tab1
----
-45
4039
6304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8874
SELECT + CAST( NULL AS SIGNED ) - 27 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8874
SELECT + CAST ( NULL AS INTEGER ) - 27 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - - 43 AS col2 FROM tab2, tab1, tab1 cor0
----
43

query I rowsort
SELECT ALL col1 * 0 * tab0.col2 + - col2 - 20 AS col2 FROM tab0
----
-102
-21
-53

query I rowsort
SELECT + cor0.col0 - - cor0.col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + + 48 + cor0.col0 - cor0.col1 AS col1 FROM tab2 AS cor0
----
110
24
67

query I rowsort
SELECT DISTINCT ( col0 ) + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + ( + col0 ) * col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

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-8882
SELECT ALL + - col0 DIV - col2 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8882
SELECT ALL + - col0 / - col2 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT - cor0.col1 + + col1 * + ( col1 ) AS col0 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT + col1 * col2 * + ( 54 ) FROM tab1 AS cor0
----
30780
67392
75816

query I rowsort
SELECT + 65 * + col1 AS col2 FROM tab2 AS cor0
----
1105
2015
3835

query I rowsort
SELECT DISTINCT ( - cor0.col1 ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL tab0.col1 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT col1 * col0 * col1 FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-8889
SELECT + col2 DIV 11 FROM tab2
----
2
2
3

skipif mysql # not compatible
query I rowsort label-8889
SELECT + col2 / 11 FROM tab2
----
2
2
3

query I rowsort
SELECT ALL + ( col1 * col1 ) + ( 13 ) FROM tab0
----
7409
8294
9422

query I rowsort
SELECT + ( + col1 ) + - cor0.col2 * col1 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT - 29 * + col0 FROM tab2 AS cor0
----
-203
-2262
-2291

query I rowsort
SELECT ALL - + 5 FROM tab2 AS cor0
----
-5
-5
-5

query I rowsort
SELECT + + 75 * - col0 AS col2 FROM tab1 AS cor0
----
-225
-4800
-6000

query I rowsort
SELECT DISTINCT - - 2 * col2 AS col0 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + cor0.col2 * col2 * - ( col0 ) + + col1 * ( 67 ) col2 FROM tab0 cor0
----
-20398
-592428
6429

onlyif mysql # use DIV operator for integer division
query I rowsort label-8897
SELECT + tab1.col2 + + tab1.col2 DIV + col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-8897
SELECT + tab1.col2 + + tab1.col2 / + col2 FROM tab1
----
55
58
97

query IIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0, tab1 AS cor0 WHERE NOT ( NULL ) >= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 7 * - col0 col1 FROM tab0
----
168
245
623

query I rowsort
SELECT col1 * col1 * tab2.col2 AS col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT DISTINCT + + tab0.col2 AS col0 FROM tab0, tab1, tab1 AS cor0
----
1
33
82

query I rowsort
SELECT + 62 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT DISTINCT + tab0.col0 AS col1 FROM tab0, tab2, tab0 AS cor0
----
24
35
89

query I rowsort
SELECT col1 * col0 + + col1 * col1 AS col2 FROM tab2 AS cor0
----
1178
1632
8083

query I rowsort
SELECT DISTINCT ( - tab0.col1 * - col1 ) FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL col1 + - ( - col1 ) * - col1 FROM tab0 cor0
----
-7310
-8190
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - col2 col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - col0 + - 93 * col2 FROM tab2 AS cor0
----
-2496
-2518
-3613

onlyif mysql # use DIV operator for integer division
query I rowsort label-8909
SELECT DISTINCT - tab0.col1 * ( + tab0.col2 ) DIV col2 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8909
SELECT DISTINCT - tab0.col1 * ( + tab0.col2 ) / col2 FROM tab0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8910
SELECT DISTINCT + CAST( NULL AS SIGNED ) col1 FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8910
SELECT DISTINCT + CAST ( NULL AS INTEGER ) col1 FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col2 * - col2 col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT - + col1 * 11 AS col1 FROM tab1 AS cor0
----
-110
-143
-286

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8913
SELECT ALL + col1 + - CAST( NULL AS SIGNED ) * - cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8913
SELECT ALL + col1 + - CAST ( NULL AS INTEGER ) * - cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 40 FROM tab2, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT ALL col1 + 9 AS col2 FROM tab1
----
19
22
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-8916
SELECT - col0 + cor0.col2 DIV col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-8916
SELECT - col0 + cor0.col2 / col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + cor0.col1 * + ( - col1 ) * - 92 AS col0 FROM tab2 cor0
----
26588
320252
88412

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8918
SELECT + CAST( 91 AS SIGNED ) FROM tab1 AS cor0
----
91
91
91

skipif mysql # not compatible
query I rowsort label-8918
SELECT + CAST ( 91 AS INTEGER ) FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT + cor0.col2 + cor0.col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8920
SELECT DISTINCT + col1 DIV ( tab0.col0 ) FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-8920
SELECT DISTINCT + col1 / ( tab0.col0 ) FROM tab0
----
1
2
3

query I rowsort
SELECT DISTINCT + 71 AS col2 FROM tab1 cor0
----
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8922
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - col0 * - col0 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8922
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - col0 * - col0 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL 0 * + col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT ALL - + CAST ( 59 AS REAL ) FROM tab2 AS cor0
----
-59
-59
-59

query I rowsort
SELECT - + 52 * col1 * - 60 + cor0.col2 AS col2 FROM tab1 AS cor0
----
31257
40656
81174

query I rowsort
SELECT + col0 * - col0 - + col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-14080
-171
-7744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 91 - cor0.col1 * col0 col1 FROM tab2 AS cor0
----
-1434
-308
-4693

query I rowsort
SELECT + + 95 + col0 FROM tab0 AS cor0
----
119
130
184

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8929
SELECT - ( - col1 ) * + CAST( - 99 AS SIGNED ) + col2 AS col2 FROM tab0 AS cor0
----
-8481
-8927
-9602

skipif mysql # not compatible
query I rowsort label-8929
SELECT - ( - col1 ) * + CAST ( - 99 AS INTEGER ) + col2 AS col2 FROM tab0 AS cor0
----
-8481
-8927
-9602

query I rowsort
SELECT + col1 * - col2 + 55 + + col1 * col2 AS col0 FROM tab1 AS cor0
----
55
55
55

query I rowsort
SELECT DISTINCT col1 + + col2 + - col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT 94 + 72 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
166

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8933
SELECT + col2 + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8933
SELECT + col2 + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 73 AS col0 FROM tab2, tab1 AS cor0, tab0 cor1, tab0, tab0 AS cor2
----
243 values hashing to eba0d5133c113efdb9a1713e1b521c68

query I rowsort
SELECT + 82 * - col1 FROM tab0
----
-7052
-7462
-7954

query I rowsort
SELECT ALL + col1 * + col2 AS col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - ( 45 + - col1 ) * 11 AS col0 FROM tab0
----
451
506
572

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8938
SELECT DISTINCT - CAST( NULL AS DECIMAL ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8938
SELECT DISTINCT - CAST ( NULL AS REAL ) FROM tab1
----
NULL

query I rowsort
SELECT 65 * + cor0.col0 FROM tab2 AS cor0
----
455
5070
5135

query I rowsort
SELECT DISTINCT - col1 * + col2 * col2 AS col1 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT col0 * - cor0.col1 * + 32 AS col2 FROM tab2 AS cor0
----
-147264
-42976
-6944

query I rowsort
SELECT DISTINCT - + 45 FROM tab0 AS cor0
----
-45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8943
SELECT DISTINCT CAST( NULL AS SIGNED ) + + 76 * col2 AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8943
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + 76 * col2 AS col2 FROM tab1
----
NULL

query I rowsort
SELECT - 52 + col0 AS col1 FROM tab2
----
-45
26
27

query I rowsort
SELECT - tab0.col1 * + col2 - col2 AS col2 FROM tab0
----
-2871
-7544
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col2 * 11 + col2 + + 65 col1 FROM tab2
----
377
389
521

query I rowsort
SELECT ALL tab2.col0 + - col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL col1 + tab0.col1 * col0 AS col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL - 74 + col2 AS col0 FROM tab0
----
-41
-73
8

query I rowsort
SELECT ALL - 12 AS col1 FROM tab0
----
-12
-12
-12

query I rowsort
SELECT DISTINCT - + cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-17
-31
-59

query I rowsort
SELECT - 94 * + 44 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 02e58d5b8287a4465eef9a2a4b27b1fc

query I rowsort
SELECT ALL - 58 * tab2.col2 AS col2 FROM tab2
----
-1508
-1566
-2204

query I rowsort
SELECT ALL tab2.col0 AS col2 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL col1 + col0 * col2 * - col1 FROM tab2 AS cor0
----
-119593
-51017
-5828

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + + col0 * col1 col2 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8957
SELECT - col2 * - col2 * + ( - ( cor0.col1 ) + + CAST( NULL AS SIGNED ) ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8957
SELECT - col2 * - col2 * + ( - ( cor0.col1 ) + + CAST ( NULL AS INTEGER ) ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 41 * col2 + 50 + - col0 * col1 AS col1 FROM tab0 AS cor0
----
-3304
-4687
-661

query I rowsort
SELECT - + ( - col2 ) * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 + + cor0.col2 * ( + 97 + col0 ) col0 FROM tab0 AS cor0
----
15341
167
4017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 93 + + cor0.col2 col2 FROM tab1, tab0 cor0
----
9 values hashing to de0a1fc074b4f5c3f97e57241af46934

query I rowsort
SELECT ALL cor0.col0 - + cor1.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 368bdd3ebc2b232b96706f1bf4f68a3e

query I rowsort
SELECT ALL 89 FROM tab0 cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to bb5bb13eab35a33bb4641905f5e7c9b6

query I rowsort
SELECT - col2 - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1344
-1458
-627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + cor0.col0 col2 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8966
SELECT + cor0.col2 + - col2 DIV + col2 - + col1 AS col1 FROM tab1 AS cor0
----
27
46
82

skipif mysql # not compatible
query I rowsort label-8966
SELECT + cor0.col2 + - col2 / + col2 - + col1 AS col1 FROM tab1 AS cor0
----
27
46
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - 7 + + col2 + col0 col2 FROM tab0
----
659
715
808

onlyif mysql # use DIV operator for integer division
query I rowsort label-8968
SELECT 54 DIV + col0 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-8968
SELECT 54 / + col0 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT + col0 - - 67 * col1 FROM tab2 AS cor0
----
1218
2084
4031

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8970
SELECT ALL + CAST( col0 AS SIGNED ) * - cor0.col1 + + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8970
SELECT ALL + CAST ( col0 AS INTEGER ) * - cor0.col1 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col0 AS col1 FROM tab0, tab2 cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 * col1 col1 FROM tab1 AS cor0
----
164
249
679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( col2 ) col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col1 * + 33 FROM tab2 AS cor0
----
-1023
-1947
-561

query I rowsort
SELECT DISTINCT ( - col0 ) * col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT col0 + 39 AS col1 FROM tab0 AS cor0
----
128
63
74

query I rowsort
SELECT ALL - - col2 + - 9 AS col1 FROM tab2 AS cor0
----
17
18
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8978
SELECT CAST( NULL AS DECIMAL ) * 32 + - cor0.col0 + col1 * - ( col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8978
SELECT CAST ( NULL AS REAL ) * 32 + - cor0.col0 + col1 * - ( col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * - col0 - + col2 * - col2 FROM tab1 AS cor0
----
-399
1536
2754

query I rowsort
SELECT DISTINCT - col1 - - col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - 73 + col0 AS col2 FROM tab0 AS cor0
----
-38
-49
16

query I rowsort
SELECT + - cor0.col0 * col0 - + col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT DISTINCT + - ( - col1 ) + col1 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8984
SELECT ALL - col1 DIV + ( col1 * cor0.col1 ) FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8984
SELECT ALL - col1 / + ( col1 * cor0.col1 ) FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8985
SELECT DISTINCT - - 26 + 21 DIV col0 FROM tab0 AS cor0
----
26

skipif mysql # not compatible
query I rowsort label-8985
SELECT DISTINCT - - 26 + 21 / col0 FROM tab0 AS cor0
----
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8986
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8986
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + col1 FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8987
SELECT - + ( 52 ) DIV col1 + - cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8987
SELECT - + ( 52 ) / col1 + - cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col1 * - ( col2 * - col1 ) FROM tab0 cor0
----
244068
679042
9409

query I rowsort
SELECT ALL 67 + col0 FROM tab2 AS cor0
----
145
146
74

query I rowsort
SELECT DISTINCT - ( col0 ) + + col2 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL + ( + col2 ) * + col1 + 70 FROM tab1 AS cor0
----
1318
1474
640

query I rowsort
SELECT DISTINCT + col0 + col2 * col2 * 54 AS col2 FROM tab1 AS cor0
----
157467
175510
497744

query I rowsort
SELECT + 31 AS col1 FROM tab2 AS cor0
----
31
31
31

query I rowsort
SELECT + 65 * - col2 + + col2 + 66 FROM tab0 AS cor0
----
-2046
-5182
2

query I rowsort
SELECT DISTINCT - - 7 AS col1 FROM tab2 AS cor0
----
7

query I rowsort
SELECT ALL - + ( cor0.col1 ) * 3 + + 97 FROM tab0 AS cor0
----
-161
-176
-194

query I rowsort
SELECT DISTINCT - - 90 + col1 AS col0 FROM tab1 AS cor0
----
100
103
116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ( 65 * + col1 ) + 62 AS col2 FROM tab0
----
5652
5977
6367

query I rowsort
SELECT DISTINCT 36 + col1 * col0 * 37 FROM tab0
----
125651
299699
76404

query I rowsort
SELECT DISTINCT ( + tab2.col1 ) + col0 FROM tab2
----
137
38
96

skipif mysql # not compatible
query I rowsort
SELECT ALL - - col1 + CAST ( cor0.col2 AS REAL ) FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + col0 * 70 FROM tab0 AS cor0
----
1680
2450
6230

query I rowsort
SELECT ALL + col1 * col0 * + 16 + col2 * 35 AS col2 FROM tab0 AS cor0
----
132454
34179
54355

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - 68 col2 FROM tab2 AS cor0
----
1768
1836
2584

query I rowsort
SELECT ALL col0 * - col2 * - col1 + + col1 * col0 AS col2 FROM tab0 AS cor0
----
672217
6790
70176

onlyif mysql # use DIV operator for integer division
query I rowsort label-9007
SELECT col0 DIV + 88 AS col1 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9007
SELECT col0 / + 88 AS col1 FROM tab0
----
0
0
1

query I rowsort
SELECT col2 + + ( col2 * - col1 ) AS col1 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT + - col1 * 9 + - col0 FROM tab0 AS cor0
----
-798
-908
-908

query I rowsort
SELECT ALL col0 * cor0.col0 + col2 AS col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT 11 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT ALL 56 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT - cor0.col0 + + col1 * - col1 * col1 FROM tab0 AS cor0
----
-636080
-753660
-912708

query I rowsort
SELECT DISTINCT + 57 AS col1 FROM tab0, tab1, tab0 AS cor0
----
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9016
SELECT CAST( NULL AS SIGNED ) * cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9016
SELECT CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9017
SELECT + cor0.col0 * + cor0.col0 + - col0 DIV ( col2 * col2 ) FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-9017
SELECT + cor0.col0 * + cor0.col0 + - col0 / ( col2 * col2 ) FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9018
SELECT ALL + col1 + tab2.col2 DIV + 7 FROM tab2
----
22
34
62

skipif mysql # not compatible
query I rowsort label-9018
SELECT ALL + col1 + tab2.col2 / + 7 FROM tab2
----
22
34
62

query I rowsort
SELECT ALL + col0 + - 46 AS col2 FROM tab1
----
-43
18
34

query I rowsort
SELECT - + ( col0 ) + col1 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9021
SELECT + col1 * ( col0 ) DIV col0 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9021
SELECT + col1 * ( col0 ) / col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + 12 FROM tab2, tab1 AS cor0
----
12

query I rowsort
SELECT ALL + col1 + - ( - col0 * col1 + - 43 * col1 ) AS col0 FROM tab1
----
1080
1222
1612

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 62 ) * col1 col0 FROM tab2
----
-1054
-1922
-3658

query I rowsort
SELECT cor0.col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - 17 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT - cor0.col1 + + col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - + 90 * col1 AS col1 FROM tab2 AS cor0
----
-1530
-2790
-5310

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9029
SELECT + - CAST( NULL AS SIGNED ) * 15 + col0 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9029
SELECT + - CAST ( NULL AS INTEGER ) * 15 + col0 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( col2 ) - col2 AS col1 FROM tab0 cor0
----
-164
-2
-66

query I rowsort
SELECT DISTINCT + 19 + - col1 AS col2 FROM tab1 AS cor0
----
-7
6
9

query I rowsort
SELECT DISTINCT + 22 * col0 AS col2 FROM tab2 AS cor0
----
154
1716
1738

onlyif mysql # use DIV operator for integer division
query I rowsort label-9033
SELECT + col1 DIV col0 + + col1 AS col0 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-9033
SELECT + col1 / col0 + + col1 AS col0 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT ALL + 24 * - col0 FROM tab0 AS cor0
----
-2136
-576
-840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + tab2.col1 col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL + col1 + col2 * + cor0.col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL tab1.col1 * ( tab1.col1 * - col1 ) AS col0 FROM tab1
----
-1000
-17576
-2197

onlyif mysql # use DIV operator for integer division
query I rowsort label-9038
SELECT ALL col2 DIV - col1 + - col0 * tab0.col2 - - col1 FROM tab0
----
-706
-7207
62

skipif mysql # not compatible
query I rowsort label-9038
SELECT ALL col2 / - col1 + - col0 * tab0.col2 - - col1 FROM tab0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9039
SELECT DISTINCT - 29 DIV col1 FROM tab2
----
-1
0

skipif mysql # not compatible
query I rowsort label-9039
SELECT DISTINCT - 29 / col1 FROM tab2
----
-1
0

query I rowsort
SELECT + - col2 * + col0 * col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT 99 * + tab2.col0 * col2 FROM tab2
----
18711
200772
297198

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 62 * - col1 + col1 col1 FROM tab1 AS cor0
----
-1586
-610
-793

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * cor0.col0 + col2 col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + 67 + + col2 FROM tab1 AS cor0
----
121
124
163

query I rowsort
SELECT + 56 + + col0 FROM tab2 AS cor0
----
134
135
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-9046
SELECT DISTINCT - + col2 DIV + CAST( - 42 AS SIGNED ) + - col1 FROM tab0 cor0
----
-86
-90
-97

skipif mysql # not compatible
query I rowsort label-9046
SELECT DISTINCT - + col2 / + CAST ( - 42 AS INTEGER ) + - col1 FROM tab0 cor0
----
-86
-90
-97

query I rowsort
SELECT + 12 + col2 AS col1 FROM tab1 AS cor0
----
108
66
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-9048
SELECT col1 + - cor0.col2 DIV + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9048
SELECT col1 + - cor0.col2 / + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - cor0.col0 AS REAL ) FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT + col1 + + 56 FROM tab1 AS cor0
----
66
69
82

query I rowsort
SELECT + col1 + 77 AS col1 FROM tab1 AS cor0
----
103
87
90

query I rowsort
SELECT ALL + - cor1.col1 AS col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT - col1 * cor0.col2 + col2 * - col0 - - cor0.col1 AS col2 FROM tab0 AS cor0
----
-14669
-35
-3544

query I rowsort
SELECT ALL col0 * 18 + col1 AS col1 FROM tab2 AS cor0
----
1439
1463
157

onlyif mysql # use DIV operator for integer division
query I rowsort label-9055
SELECT ALL col0 DIV col1 + col2 + + col0 AS col2 FROM tab2 AS cor0
----
105
121
34

skipif mysql # not compatible
query I rowsort label-9055
SELECT ALL col0 / col1 + col2 + + col0 AS col2 FROM tab2 AS cor0
----
105
121
34

query I rowsort
SELECT DISTINCT - col0 - ( + ( col1 ) ) FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT col0 * col2 - - col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL + + col2 * - 75 + + col1 * col2 + col1 AS col0 FROM tab0 cor0
----
119
1403
449

query I rowsort
SELECT DISTINCT + col1 + 45 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1229
1246
1727

query I rowsort
SELECT - col0 * col1 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + ( 37 ) + + col1 col1 FROM tab0 AS cor0
----
-1198
-3202
-802

query I rowsort
SELECT DISTINCT + + col0 * + ( 67 + col0 ) AS col0 FROM tab0 cor0
----
13884
2184
3570

query I rowsort
SELECT DISTINCT + col1 * - 85 AS col0 FROM tab0 AS cor0
----
-7310
-7735
-8245

query I rowsort
SELECT DISTINCT col1 * col1 * + col0 AS col2 FROM tab2
----
22831
271518
6727

skipif mysql # not compatible
query I rowsort
SELECT ALL + col1 * + 89 * - ( col1 ) + CAST ( ( cor0.col0 ) AS REAL ) AS col0 FROM tab0 cor0
----
-658220
-736920
-837366

query I rowsort
SELECT DISTINCT + - col2 + col2 * col1 - col0 AS col1 FROM tab0 AS cor0
----
2781
61
7291

query I rowsort
SELECT DISTINCT + col2 * col2 * col1 AS col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT - col2 + ( col0 ) AS col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT DISTINCT + tab1.col0 + col2 AS col2 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-9070
SELECT DISTINCT - col0 DIV col2 AS col2 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-9070
SELECT DISTINCT - col0 / col2 AS col2 FROM tab0 cor0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * cor0.col0 + col2 col1 FROM tab2 AS cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-9072
SELECT DISTINCT col2 * + ( 66 ) + col0 DIV 36 FROM tab1
----
3564
3763
6338

skipif mysql # not compatible
query I rowsort label-9072
SELECT DISTINCT col2 * + ( 66 ) + col0 / 36 FROM tab1
----
3564
3763
6338

query I rowsort
SELECT ALL col2 + col1 * 81 AS col1 FROM tab1 AS cor0
----
1149
2160
867

onlyif mysql # use DIV operator for integer division
query I rowsort label-9074
SELECT - cor0.col2 DIV - cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9074
SELECT - cor0.col2 / - cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL 81 - col1 FROM tab1
----
55
68
71

query I rowsort
SELECT DISTINCT + col0 - col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - 54 + tab2.col1 + + col0 AS col2 FROM tab2
----
-16
42
83

query I rowsort
SELECT DISTINCT - 79 - cor0.col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
-112
-161
-80

query I rowsort
SELECT DISTINCT col1 * tab1.col2 - - 28 FROM tab1
----
1276
1432
598

query I rowsort
SELECT ALL - 79 AS col2 FROM tab1 cor0
----
-79
-79
-79

query I rowsort
SELECT + - col2 + + col0 * 92 AS col2 FROM tab2 AS cor0
----
617
7150
7230

query I rowsort
SELECT ( - col2 ) + cor0.col1 * 92 FROM tab1 AS cor0
----
1100
2338
863

onlyif mysql # use DIV operator for integer division
query I rowsort label-9083
SELECT 60 DIV + col1 + + 65 DIV - 76 AS col2 FROM tab2 AS cor0
----
1
1
3

skipif mysql # not compatible
query I rowsort label-9083
SELECT 60 / + col1 + + 65 / - 76 AS col2 FROM tab2 AS cor0
----
1
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-9084
SELECT DISTINCT + col0 DIV - col0 AS col2 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-9084
SELECT DISTINCT + col0 / - col0 AS col2 FROM tab0
----
-1

query I rowsort
SELECT ALL + - col0 + col1 * - col2 FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT - col2 * + col0 * col1 + - col2 + col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - cor0.col0 + - cor0.col0 * - 27 AS col2 FROM tab2 AS cor0
----
182
2028
2054

onlyif mysql # use DIV operator for integer division
query I rowsort label-9088
SELECT - + col1 + - cor0.col1 DIV col1 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-9088
SELECT - + col1 + - cor0.col1 / col1 FROM tab2 AS cor0
----
-18
-32
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9089
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab0, tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9089
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab0, tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT + cor0.col0 + - 30 AS col2 FROM tab2 AS cor0
----
-23
48
49

query I rowsort
SELECT - - col0 + - cor0.col0 * cor0.col2 + - col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - col1 + - col2 * col0 - 82 FROM tab1
----
-270
-3740
-7775

onlyif mysql # use DIV operator for integer division
query I rowsort label-9093
SELECT DISTINCT + + cor0.col0 + 8 DIV 27 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-9093
SELECT DISTINCT + + cor0.col0 + 8 / 27 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - cor0.col2 * - col0 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - + col1 + ( col1 ) * - col2 FROM tab1 cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT 0 AS col0 FROM tab2, tab2 AS cor0
----
0

query I rowsort
SELECT + col2 * col2 + - col1 AS col1 FROM tab0 cor0
----
-96
1003
6633

query I rowsort
SELECT ( - col0 ) AS col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + + 25 + + 63 AS col1 FROM tab0 AS cor0
----
88

query I rowsort
SELECT 65 + - col0 AS col1 FROM tab1
----
-15
1
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9101
SELECT CAST( + 78 AS SIGNED ) * + tab0.col1 + + ( + col1 ) FROM tab0
----
6794
7189
7663

skipif mysql # not compatible
query I rowsort label-9101
SELECT CAST ( + 78 AS INTEGER ) * + tab0.col1 + + ( + col1 ) FROM tab0
----
6794
7189
7663

query I rowsort
SELECT DISTINCT + ( - col2 + col2 * - 99 ) FROM tab0
----
-100
-3300
-8200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col0 col2 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9104
SELECT DISTINCT + col2 DIV 50 col0 FROM tab0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9104
SELECT DISTINCT + col2 / 50 col0 FROM tab0
----
0
1

query I rowsort
SELECT 75 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1 cor2
----
81 values hashing to 3384246e49f3e69ba32c165b88111fee

query I rowsort
SELECT ALL - col1 * - 3 - + col2 FROM tab1 AS cor0
----
-27
-57
24

query I rowsort
SELECT cor0.col2 * 55 FROM tab1, tab0 AS cor0
----
9 values hashing to 8a756501255b38d6a7d7b424505dacb7

query I rowsort
SELECT ALL + - 86 FROM tab1 AS cor0
----
-86
-86
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + 52 ) + col1 col1 FROM tab0 AS cor0
----
138
143
149

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 + - ( col1 ) col1 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-9111
SELECT ALL - + col2 * col2 DIV cor0.col1 AS col1 FROM tab1 AS cor0
----
-112
-324
-708

skipif mysql # not compatible
query I rowsort label-9111
SELECT ALL - + col2 * col2 / cor0.col1 AS col1 FROM tab1 AS cor0
----
-112
-324
-708

query I rowsort
SELECT DISTINCT - 53 * - col0 AS col2 FROM tab2 AS cor0
----
371
4134
4187

query I rowsort
SELECT ALL + 56 * col1 AS col0 FROM tab1 AS cor0
----
1456
560
728

query I rowsort
SELECT - + cor0.col2 + cor0.col0 * + col0 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT ALL - ( col1 ) * - cor0.col1 + col1 AS col2 FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT ALL - - 2 * + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL + + col1 + col1 * - col2 * col1 + col0 FROM tab1 AS cor0
----
-16131
-36475
-5626

query I rowsort
SELECT DISTINCT col1 * col2 * 12 FROM tab1 cor0
----
14976
16848
6840

query I rowsort
SELECT - tab0.col2 + col2 AS col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 67 - col0 * 21 col2 FROM tab0
----
-668
1707
3625

query I rowsort
SELECT 19 FROM tab2, tab1 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT ALL + 79 AS col1 FROM tab2
----
79
79
79

query I rowsort
SELECT ALL - ( - tab2.col2 ) AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT + 45 * col0 AS col0 FROM tab2 AS cor0
----
315
3510
3555

query I rowsort
SELECT + 56 + - col2 AS col2 FROM tab1 AS cor0
----
-1
-40
2

query I rowsort
SELECT - col2 * 53 FROM tab0 AS cor0
----
-1749
-4346
-53

query I rowsort
SELECT DISTINCT ( col1 ) * + col2 AS col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT 29 * - ( col2 ) AS col1 FROM tab2 cor0
----
-1102
-754
-783

onlyif mysql # use DIV operator for integer division
query I rowsort label-9129
SELECT DISTINCT - col2 DIV 81 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9129
SELECT DISTINCT - col2 / 81 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT + cor0.col0 * - 13 AS col2 FROM tab1 AS cor0
----
-1040
-39
-832

query I rowsort
SELECT + 75 + - col0 AS col0 FROM tab2 AS cor0
----
-3
-4
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col2 * col2 col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT + - col2 * + ( + col2 ) + col2 AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-9134
SELECT col2 * col0 + - ( col0 ) DIV 30 FROM tab2 AS cor0
----
189
2026
3000

skipif mysql # not compatible
query I rowsort label-9134
SELECT col2 * col0 + - ( col0 ) / 30 FROM tab2 AS cor0
----
189
2026
3000

query I rowsort
SELECT col1 * col1 * 90 FROM tab1
----
15210
60840
9000

query I rowsort
SELECT DISTINCT col2 + + ( + 93 ) AS col1 FROM tab1 AS cor0
----
147
150
189

query I rowsort
SELECT DISTINCT - col0 * col1 + col2 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT + col0 * col0 + - col0 * - ( cor0.col2 ) FROM tab2 AS cor0
----
238
8112
9243

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9139
SELECT ALL col1 + CAST( - 71 AS SIGNED ) * + col2 FROM tab1
----
-3808
-4037
-6803

skipif mysql # not compatible
query I rowsort label-9139
SELECT ALL col1 + CAST ( - 71 AS INTEGER ) * + col2 FROM tab1
----
-3808
-4037
-6803

query I rowsort
SELECT - col2 * col0 * 62 AS col0 FROM tab0
----
-2170
-452476
-49104

query I rowsort
SELECT ALL - col2 + + 70 * 1 FROM tab0
----
-12
37
69

query I rowsort
SELECT ALL col2 + + col2 + + 65 FROM tab1
----
173
179
257

query I rowsort
SELECT 5 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9144
SELECT + CAST( NULL AS SIGNED ) + cor0.col2 * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9144
SELECT + CAST ( NULL AS INTEGER ) + cor0.col2 * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 46 * + col2 * - col0 + col0 * col0 FROM tab1 AS cor0
----
-163712
-346880
-7443

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 + 28 col0 FROM tab0 AS cor0
----
-58
-63
-69

query I rowsort
SELECT - 49 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT DISTINCT + col2 * col0 + col1 * - col2 * 88 AS col2 FROM tab0 AS cor0
----
-248952
-649358
-8501

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * col0 * col0 + + col2 + - col2 col0 FROM tab1 AS cor0
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + - 5 col0 FROM tab1 AS cor0
----
-101
-59
-62

query I rowsort
SELECT - ( + 47 ) * - col1 + - col2 FROM tab0 AS cor0
----
4009
4195
4558

query I rowsort
SELECT + col2 * 97 AS col2 FROM tab2
----
2522
2619
3686

query I rowsort
SELECT ALL + - 69 AS col1 FROM tab1 AS cor0
----
-69
-69
-69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9155
SELECT col2 * col1 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9155
SELECT col2 * col1 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9156
SELECT + CAST( NULL AS SIGNED ) * + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9156
SELECT + CAST ( NULL AS INTEGER ) * + col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col2 * col2 ) AS col0 FROM tab1
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 52 col1 FROM tab0
----
52

query I rowsort
SELECT ALL 21 - col2 AS col1 FROM tab0
----
-12
-61
20

query I rowsort
SELECT - 7 AS col0 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * 37 col1 FROM tab0 AS cor0
----
1221
3034
37

query I rowsort
SELECT ALL col0 * 20 * - col0 AS col2 FROM tab1 cor0
----
-128000
-180
-81920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col2 * - col1 * 93 col0 FROM tab0
----
263934
693966
9021

query I rowsort
SELECT 78 AS col0 FROM tab0
----
78
78
78

query I rowsort
SELECT DISTINCT col2 * - col1 * + col0 AS col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT cor0.col1 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT 54 AS col1 FROM tab2, tab2 cor0
----
54

query I rowsort
SELECT - col1 + + 16 AS col0 FROM tab1 AS cor0
----
-10
3
6

query I rowsort
SELECT - - col0 * col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + col0 * - col1 * + 93 FROM tab0 AS cor0
----
-191952
-315735
-753207

query I rowsort
SELECT - - 85 * + col0 AS col2 FROM tab2 AS cor0
----
595
6630
6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-9172
SELECT col2 + col2 DIV - col0 + - col0 * + col1 AS col1 FROM tab2
----
-1305
-193
-4576

skipif mysql # not compatible
query I rowsort label-9172
SELECT col2 + col2 / - col0 + - col0 * + col1 AS col1 FROM tab2
----
-1305
-193
-4576

query I rowsort
SELECT ALL - 28 AS col2 FROM tab2 AS cor0
----
-28
-28
-28

query I rowsort
SELECT ALL 39 + + col2 AS col2 FROM tab1 AS cor0
----
135
93
96

query I rowsort
SELECT ALL + col2 + 18 AS col0 FROM tab1 AS cor0
----
114
72
75

query I rowsort
SELECT DISTINCT - + col1 * 7 FROM tab0 AS cor0
----
-602
-637
-679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9177
SELECT DISTINCT col1 * - CAST( 49 AS SIGNED ) FROM tab1 AS cor0
----
-1274
-490
-637

skipif mysql # not compatible
query I rowsort label-9177
SELECT DISTINCT col1 * - CAST ( 49 AS INTEGER ) FROM tab1 AS cor0
----
-1274
-490
-637

query I rowsort
SELECT + col0 * ( - 36 ) FROM tab0 AS cor0
----
-1260
-3204
-864

query I rowsort
SELECT ALL col2 + col1 * - 91 AS col0 FROM tab2 AS cor0
----
-1509
-2794
-5343

onlyif mysql # use DIV operator for integer division
query I rowsort label-9180
SELECT DISTINCT + col0 DIV ( + 62 ) AS col0 FROM tab2 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-9180
SELECT DISTINCT + col0 / ( + 62 ) AS col0 FROM tab2 AS cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9181
SELECT ALL + col1 DIV + col1 + - 32 FROM tab1 AS cor0
----
-31
-31
-31

skipif mysql # not compatible
query I rowsort label-9181
SELECT ALL + col1 / + col1 + - 32 FROM tab1 AS cor0
----
-31
-31
-31

onlyif mysql # use DIV operator for integer division
query I rowsort label-9182
SELECT DISTINCT col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-9182
SELECT DISTINCT col0 / + col0 AS col0 FROM tab0 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9183
SELECT DISTINCT - cor0.col2 * - CAST( - col0 AS SIGNED ) col1 FROM tab2 cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9183
SELECT DISTINCT - cor0.col2 * - CAST ( - col0 AS INTEGER ) col1 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9184
SELECT - + cor0.col1 + + CAST( col1 * cor0.col2 AS SIGNED ) - 97 FROM tab0 cor0
----
-97
2655
7274

skipif mysql # not compatible
query I rowsort label-9184
SELECT - + cor0.col1 + + CAST ( col1 * cor0.col2 AS INTEGER ) - 97 FROM tab0 cor0
----
-97
2655
7274

onlyif mysql # use DIV operator for integer division
query I rowsort label-9185
SELECT col1 + ( col2 ) * col1 DIV 11 AS col1 FROM tab1 AS cor0
----
126
153
61

skipif mysql # not compatible
query I rowsort label-9185
SELECT col1 + ( col2 ) * col1 / 11 AS col1 FROM tab1 AS cor0
----
126
153
61

query I rowsort
SELECT - tab2.col0 + + col1 * - 59 * + col1 - col1 * col2 FROM tab2
----
-17776
-206991
-57543

onlyif mysql # use DIV operator for integer division
query I rowsort label-9187
SELECT DISTINCT col0 + - col2 DIV + col0 - 83 FROM tab0
----
-48
-60
6

skipif mysql # not compatible
query I rowsort label-9187
SELECT DISTINCT col0 + - col2 / + col0 - 83 FROM tab0
----
-48
-60
6

query I rowsort
SELECT DISTINCT + 61 - col2 AS col2 FROM tab1
----
-35
4
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9189
SELECT DISTINCT - col1 * + col2 - col0 DIV 62 FROM tab1
----
-1249
-1404
-571

skipif mysql # not compatible
query I rowsort label-9189
SELECT DISTINCT - col1 * + col2 - col0 / 62 FROM tab1
----
-1249
-1404
-571

query I rowsort
SELECT DISTINCT tab2.col2 + - col2 * + col0 - - ( col0 ) AS col0 FROM tab2
----
-155
-1924
-2885

onlyif mysql # use DIV operator for integer division
query I rowsort label-9191
SELECT + col1 DIV + col0 + ( + col0 ) AS col0 FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-9191
SELECT + col1 / + col0 + ( + col0 ) AS col0 FROM tab0
----
27
37
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9192
SELECT ALL + col2 * col1 + - CAST( - 21 AS SIGNED ) * - col2 - 37 FROM tab1
----
-664
-805
233

skipif mysql # not compatible
query I rowsort label-9192
SELECT ALL + col2 * col1 + - CAST ( - 21 AS INTEGER ) * - col2 - 37 FROM tab1
----
-664
-805
233

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + tab2.col0 * col0 col2 FROM tab2
----
42
6006
6162

query I rowsort
SELECT - col0 - ( - col2 * col1 ) AS col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT col2 * - 28 AS col0 FROM tab2 AS cor0
----
-1064
-728
-756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 * col0 col2 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9197
SELECT col2 DIV tab1.col0 + + col1 - - col1 FROM tab1
----
20
27
70

skipif mysql # not compatible
query I rowsort label-9197
SELECT col2 / tab1.col0 + + col1 - - col1 FROM tab1
----
20
27
70

query I rowsort
SELECT + + col1 * + 33 FROM tab0 AS cor0
----
2838
3003
3201

onlyif mysql # use DIV operator for integer division
query I rowsort label-9199
SELECT DISTINCT + + 27 - + col2 DIV col2 FROM tab1 AS cor0
----
26

skipif mysql # not compatible
query I rowsort label-9199
SELECT DISTINCT + + 27 - + col2 / col2 FROM tab1 AS cor0
----
26

query I rowsort
SELECT DISTINCT ( - 1 ) + col2 AS col1 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT + 93 * 51 + + col0 AS col2 FROM tab0 AS cor0
----
4767
4778
4832

query I rowsort
SELECT ALL col0 + cor0.col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + - col0 * + 7 AS col1 FROM tab1 AS cor0
----
-21
-448
-560

query I rowsort
SELECT + 1 * - ( - col2 ) AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT 58 FROM tab0, tab2 cor0, tab0 AS cor1
----
58

query I rowsort
SELECT ALL - - cor0.col2 + - cor0.col0 * - cor0.col2 FROM tab0 AS cor0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - cor0.col0 ) * + col1 + - ( + col1 ) col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 13 + + 6 col0 FROM tab2 cor0
----
19

query I rowsort
SELECT + 30 * - 96 + + cor0.col0 * col1 FROM tab1 AS cor0
----
-1840
-2240
-2802

query I rowsort
SELECT ALL + 85 * col0 + - 45 FROM tab1 AS cor0
----
210
5395
6755

onlyif mysql # use DIV operator for integer division
query I rowsort label-9211
SELECT ALL - col0 + - col1 * + col2 + - cor0.col2 DIV col0 FROM tab1 AS cor0
----
-1329
-1425
-634

skipif mysql # not compatible
query I rowsort label-9211
SELECT ALL - col0 + - col1 * + col2 + - cor0.col2 / col0 FROM tab1 AS cor0
----
-1329
-1425
-634

query I rowsort
SELECT 26 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query I rowsort
SELECT - col0 * - col0 + + 17 * + 86 FROM tab0 AS cor0
----
2038
2687
9383

query I rowsort
SELECT - - ( - col1 ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL col2 * + col0 - + col2 AS col1 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL - + cor0.col0 * col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - cor0.col1 + - col0 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - col0 AS REAL ) AS col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT 36 + 81 FROM tab2
----
117
117
117

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 46 col0 FROM tab2
----
46
46
46

query I rowsort
SELECT + col2 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - + 86 FROM tab0 cor0
----
-86
-86
-86

query I rowsort
SELECT ALL cor0.col2 * col2 + col0 * + col2 AS col0 FROM tab0 AS cor0
----
14022
1881
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9224
SELECT DISTINCT + - col2 * + col2 + - CAST( 74 AS SIGNED ) FROM tab2 AS cor0
----
-1518
-750
-803

skipif mysql # not compatible
query I rowsort label-9224
SELECT DISTINCT + - col2 * + col2 + - CAST ( 74 AS INTEGER ) FROM tab2 AS cor0
----
-1518
-750
-803

query I rowsort
SELECT DISTINCT - 95 FROM tab1, tab2 cor0
----
-95

query I rowsort
SELECT ALL 55 * - cor0.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 43476a73746cc280354325c126d25dc5

query I rowsort
SELECT + col2 + + ( col1 * col2 ) FROM tab1
----
1344
1458
627

query I rowsort
SELECT - 89 * col2 AS col2 FROM tab0 cor0
----
-2937
-7298
-89

query I rowsort
SELECT col0 * - 51 + col1 * col1 AS col1 FROM tab2
----
-3740
-497
604

onlyif mysql # use DIV operator for integer division
query I rowsort label-9230
SELECT col0 DIV CAST( - col1 + + col2 AS SIGNED ) FROM tab2 AS cor0
----
-1
-2
3

skipif mysql # not compatible
query I rowsort label-9230
SELECT col0 / CAST ( - col1 + + col2 AS INTEGER ) FROM tab2 AS cor0
----
-1
-2
3

query I rowsort
SELECT - col1 * col1 + + col0 * col0 FROM tab1 AS cor0
----
-667
3996
6231

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col0 * - ( - col2 ) col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL 20 AS col2 FROM tab2, tab1 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to 8550664862df5be7a3d3f6037537d2d8

query I rowsort
SELECT + cor0.col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT ( ( cor0.col0 ) ) + - col2 * col2 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9236
SELECT ALL + + col0 + 1 * - cor0.col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9236
SELECT ALL + + col0 + 1 * - cor0.col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + ( - 26 ) - + col0 AS col2 FROM tab0 AS cor0
----
-63
-9
2

query I rowsort
SELECT ( + col1 * col1 ) FROM tab2
----
289
3481
961

query I rowsort
SELECT 14 + col1 AS col0 FROM tab0
----
100
105
111

query I rowsort
SELECT ( - tab0.col2 ) AS col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT ALL 51 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT DISTINCT 94 + col1 FROM tab2 cor0
----
111
125
153

query I rowsort
SELECT ALL - 77 * col0 + col1 FROM tab2 AS cor0
----
-508
-5947
-6066

query I rowsort
SELECT DISTINCT + col0 - + ( - col0 ) AS col1 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9245
SELECT DISTINCT - CAST( - col2 AS SIGNED ) + - cor0.col1 * - 43 AS col0 FROM tab0 cor0
----
3731
3995
4172

skipif mysql # not compatible
query I rowsort label-9245
SELECT DISTINCT - CAST ( - col2 AS INTEGER ) + - cor0.col1 * - 43 AS col0 FROM tab0 cor0
----
3731
3995
4172

onlyif mysql # use DIV operator for integer division
query I rowsort label-9246
SELECT col2 DIV cor0.col2 + col0 col1 FROM tab0 AS cor0
----
25
36
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9246
SELECT col2 / cor0.col2 + col0 col1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL cor0.col2 * cor0.col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + + col0 + + ( + col0 ) * col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT - col0 * tab2.col2 * + col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT + col0 * col0 + + 18 AS col0 FROM tab0 AS cor0
----
1243
594
7939

query I rowsort
SELECT - col2 + - 81 FROM tab0 AS cor0
----
-114
-163
-82

query I rowsort
SELECT - col1 * cor0.col0 * - col2 + + col1 FROM tab2 AS cor0
----
119711
51051
5890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9253
SELECT ( - 67 ) * + col2 + CAST( + 24 AS SIGNED ) * col2 col1 FROM tab0
----
-1419
-3526
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9253
SELECT ( - 67 ) * + col2 + CAST ( + 24 AS INTEGER ) * col2 col1 FROM tab0
----
-1419
-3526
-43

query I rowsort
SELECT ALL - 56 AS col1 FROM tab2
----
-56
-56
-56

query I rowsort
SELECT ALL + + tab2.col0 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT 0 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT col2 * col2 * + col1 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL 11 AS col0 FROM tab2 AS cor0
----
11
11
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9259
SELECT DISTINCT + CAST( col2 AS SIGNED ) + col0 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9259
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + col0 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - ( col1 ) * col1 AS col0 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9261
SELECT DISTINCT + col0 * col0 + CAST( NULL AS SIGNED ) + cor0.col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9261
SELECT DISTINCT + col0 * col0 + CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - col2 + + col2 * + cor0.col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT 78 * - col2 + - ( - 25 ) AS col1 FROM tab1 AS cor0
----
-4187
-4421
-7463

query I rowsort
SELECT - col2 + 54 * + col0 FROM tab1
----
108
3399
4224

query I rowsort
SELECT - + ( - cor0.col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - 35 * col1 FROM tab0 AS cor0
----
-3010
-3185
-3395

query I rowsort
SELECT 31 * col1 FROM tab1 AS cor0
----
310
403
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9268
SELECT + ( col1 ) - + CAST( NULL AS SIGNED ) / + col2 col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9268
SELECT + ( col1 ) - + CAST ( NULL AS INTEGER ) / + col2 col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 50 ) col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

query I rowsort
SELECT DISTINCT + 48 + col1 FROM tab0 AS cor0
----
134
139
145

query I rowsort
SELECT 93 + col1 * ( 95 ) AS col2 FROM tab2 AS cor0
----
1708
3038
5698

query I rowsort
SELECT - 31 + - col2 * ( - cor0.col0 ) AS col1 FROM tab1 AS cor0
----
131
3617
7649

query I rowsort
SELECT + cor0.col0 * + ( + col2 ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9274
SELECT ALL + + col2 DIV + 99 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9274
SELECT ALL + + col2 / + 99 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col2 - - col2 * - col2 AS col1 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT ALL 12 * tab1.col0 AS col2 FROM tab1
----
36
768
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + 5 * col2 col1 FROM tab1 AS cor0
----
324
342
576

query I rowsort
SELECT - col1 + 7 FROM tab1 cor0
----
-19
-3
-6

query I rowsort
SELECT col0 + + 48 FROM tab2 AS cor0
----
126
127
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-9281
SELECT ALL col0 + 14 DIV - col2 col1 FROM tab0 AS cor0
----
21
24
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9281
SELECT ALL col0 + 14 / - col2 col1 FROM tab0 AS cor0
----
21
24
89

query I rowsort
SELECT + + ( tab1.col2 ) - + cor0.col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to b946f76353289f5f276bfcbfd6f7de37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col1 ) col1 FROM tab2
----
17
31
59

query I rowsort
SELECT + - 56 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

query I rowsort
SELECT - col0 + 56 FROM tab1 AS cor0
----
-24
-8
53

query I rowsort
SELECT + ( + ( - col1 ) ) * col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - col1 + 14 AS col0 FROM tab0 AS cor0
----
-72
-77
-83

query I rowsort
SELECT + col0 * + 93 AS col1 FROM tab1 AS cor0
----
279
5952
7440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9289
SELECT CAST( NULL AS SIGNED ) * - 77 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9289
SELECT CAST ( NULL AS INTEGER ) * - 77 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 64 AS col0 FROM tab1, tab2 cor0
----
64

query I rowsort
SELECT + cor0.col1 + - cor0.col1 * + col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT col2 * - 48 FROM tab0
----
-1584
-3936
-48

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
3645 values hashing to 181d902c42955a43a374f13a73d8b0a1

query I rowsort
SELECT 5 + col2 FROM tab0 AS cor0
----
38
6
87

query I rowsort
SELECT 80 + - col0 * col0 FROM tab0 AS cor0
----
-1145
-496
-7841

query I rowsort
SELECT ( - 31 ) AS col2 FROM tab1 AS cor0
----
-31
-31
-31

query I rowsort
SELECT - 62 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 col0 FROM tab2
----
52
54
76

query I rowsort
SELECT DISTINCT - 13 AS col0 FROM tab0, tab2 AS cor0
----
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-9300
SELECT - - col0 DIV + cor0.col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9300
SELECT - - col0 / + cor0.col1 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9301
SELECT + cor0.col1 * - CAST( - col0 AS SIGNED ) + col2 + ( - 82 + + col0 ) FROM tab0 AS cor0
----
2039
3349
8188

skipif mysql # not compatible
query I rowsort label-9301
SELECT + cor0.col1 * - CAST ( - col0 AS INTEGER ) + col2 + ( - 82 + + col0 ) FROM tab0 AS cor0
----
2039
3349
8188

query I rowsort
SELECT 27 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT - col2 + 66 AS col0 FROM tab1
----
-30
12
9

query I rowsort
SELECT - 68 * + 46 FROM tab2, tab0 AS cor0
----
9 values hashing to fae9c03fcd5fc824cd6105b0cff3e2e6

query I rowsort
SELECT DISTINCT + tab1.col1 * 20 FROM tab1
----
200
260
520

query I rowsort
SELECT ALL + 18 * col1 AS col1 FROM tab1 AS cor0
----
180
234
468

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9307
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9307
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9308
SELECT + CAST( NULL AS SIGNED ) * cor0.col2 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9308
SELECT + CAST ( NULL AS INTEGER ) * cor0.col2 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 22 * col2 AS col1 FROM tab2 AS cor0
----
-572
-594
-836

query I rowsort
SELECT ALL + + ( + ( col2 ) ) + col1 + + col1 * col2 * 90 AS col1 FROM tab2 AS cor0
----
138145
58195
75388

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - col2 * + cor0.col1 * + col2 - + CAST ( col1 + col2 AS REAL ) AS col0 FROM tab1 AS cor0
----
-119917
-32557
-75896

query I rowsort
SELECT DISTINCT cor0.col1 - - col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ( col0 ) + - col0 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col2 + col0 * + col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT - ( 14 ) * + col2 AS col2 FROM tab0 AS cor0
----
-1148
-14
-462

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + cor0.col1 col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9317
SELECT 40 DIV - 42 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9317
SELECT 40 / - 42 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + ( + col1 ) + - col1 * - ( col1 ) FROM tab2 cor0
----
306
3540
992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9319
SELECT CAST( col1 AS SIGNED ) * + col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-9319
SELECT CAST ( col1 AS INTEGER ) * + col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT 55 + col1 FROM tab0 AS cor0
----
141
146
152

query I rowsort
SELECT ALL 1 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT ( - col2 ) AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL cor0.col2 * 85 AS col0 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT DISTINCT ( 28 ) + cor0.col1 FROM tab0 AS cor0
----
114
119
125

query I rowsort
SELECT ALL ( col1 ) * + col2 * + 3 AS col0 FROM tab0 cor0
----
22386
291
8514

query I rowsort
SELECT + 94 * col0 * + col1 AS col1 FROM tab0 AS cor0
----
194016
319130
761306

query I rowsort
SELECT cor0.col0 + - col2 * - 91 + 3 FROM tab1 cor0
----
4920
5254
8819

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 + + 15 col2 FROM tab1 AS cor0
----
123
129
207

query I rowsort
SELECT + + col0 * cor0.col1 + col1 + - col2 FROM tab2 AS cor0
----
1322
221
4635

query I rowsort
SELECT + ( + col0 ) * 22 FROM tab1
----
1408
1760
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-9331
SELECT - col0 * + col2 + + col1 DIV col1 FROM tab1
----
-161
-3647
-7679

skipif mysql # not compatible
query I rowsort label-9331
SELECT - col0 * + col2 + + col1 / col1 FROM tab1
----
-161
-3647
-7679

query I rowsort
SELECT ALL - - col1 * col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + + 93 + + col2 AS col1 FROM tab1 AS cor0
----
147
150
189

query I rowsort
SELECT DISTINCT col0 + col1 + + col2 FROM tab2 AS cor0
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-9335
SELECT ALL + 7 + col1 * + col0 + + 75 DIV - col2 AS col0 FROM tab0 AS cor0
----
2069
3327
8106

skipif mysql # not compatible
query I rowsort label-9335
SELECT ALL + 7 + col1 * + col0 + + 75 / - col2 AS col0 FROM tab0 AS cor0
----
2069
3327
8106

query I rowsort
SELECT cor0.col0 + + col2 * cor0.col2 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL - col0 * - 98 AS col0 FROM tab2 AS cor0
----
686
7644
7742

onlyif mysql # use DIV operator for integer division
query I rowsort label-9338
SELECT ALL + + col2 DIV + col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-9338
SELECT ALL + + col2 / + col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT ALL col2 * col1 + 79 AS col2 FROM tab2 AS cor0
----
1613
725
916

query I rowsort
SELECT DISTINCT - col0 - - ( - 54 * col1 ) AS col1 FROM tab2 AS cor0
----
-1681
-3264
-997

query I rowsort
SELECT ALL - + col0 * ( - cor0.col1 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9342
SELECT ALL + - col1 + + CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-9342
SELECT ALL + - col1 + + CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT col2 + - 0 * ( + col1 ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - + cor0.col0 + + 75 AS col0 FROM tab2 AS cor0
----
-3
-4
68

query I rowsort
SELECT DISTINCT col0 * col1 * 15 FROM tab2 AS cor0
----
20145
3255
69030

query I rowsort
SELECT ALL + cor0.col1 + + 21 AS col1 FROM tab0 cor0
----
107
112
118

query I rowsort
SELECT DISTINCT - col2 - 4 * col2 AS col1 FROM tab0 AS cor0
----
-165
-410
-5

query I rowsort
SELECT col0 + ( - col2 + col0 * - cor0.col1 ) AS col2 FROM tab0 AS cor0
----
-2073
-3361
-8092

query I rowsort
SELECT col0 * col0 + col2 AS col0 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT - + cor0.col2 + col2 * - col1 FROM tab0 AS cor0
----
-2871
-7544
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9351
SELECT DISTINCT col1 DIV col2 + + 71 + - col0 AS col2 FROM tab0 cor0
----
-17
133
49

skipif mysql # not compatible
query I rowsort label-9351
SELECT DISTINCT col1 / col2 + + 71 + - col0 AS col2 FROM tab0 cor0
----
-17
133
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - 37 + col0 * cor0.col2 col1 FROM tab1 AS cor0
----
-1836
1539
4128

query I rowsort
SELECT - + col0 + - col1 FROM tab1 cor0
----
-29
-74
-93

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 cor2
----
972 values hashing to 0a9194f200a4220e419d35c461f9fcfe

query I rowsort
SELECT + 11 FROM tab1, tab0 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT - - 5 + col2 + - col1 * + ( + col0 + col1 ) AS col1 FROM tab0 AS cor0
----
-12798
-16293
-9422

onlyif mysql # use DIV operator for integer division
query I rowsort label-9357
SELECT + col2 - + col2 DIV - 41 FROM tab0 AS cor0
----
1
33
84

skipif mysql # not compatible
query I rowsort label-9357
SELECT + col2 - + col2 / - 41 FROM tab0 AS cor0
----
1
33
84

query I rowsort
SELECT + col2 - cor0.col2 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9359
SELECT ALL - - cor0.col0 DIV + col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9359
SELECT ALL - - cor0.col0 / + col0 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9360
SELECT + col2 + - col0 * 72 DIV + col2 + - col2 AS col2 FROM tab0 AS cor0
----
-2520
-52
-78

skipif mysql # not compatible
query I rowsort label-9360
SELECT + col2 + - col0 * 72 / + col2 + - col2 AS col2 FROM tab0 AS cor0
----
-2520
-52
-78

query I rowsort
SELECT 53 + col1 * - col0 FROM tab2 AS cor0
----
-1290
-164
-4549

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - col0 * tab1.col0 col1 FROM tab1
----
-35
-4106
-6413

query I rowsort
SELECT ALL - 83 + - col1 AS col0 FROM tab1
----
-109
-93
-96

query I rowsort
SELECT ALL 44 + + col0 * 38 * col2 AS col2 FROM tab1
----
138668
291884
6200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9365
SELECT ALL + col1 + col1 * - CAST( col1 AS SIGNED ) * + col1 AS col0 FROM tab0
----
-635970
-753480
-912576

skipif mysql # not compatible
query I rowsort label-9365
SELECT ALL + col1 + col1 * - CAST ( col1 AS INTEGER ) * + col1 AS col0 FROM tab0
----
-635970
-753480
-912576

query I rowsort
SELECT ALL - col0 * + col1 + - col0 * + tab1.col2 FROM tab1
----
-240
-4288
-8720

query I rowsort
SELECT ALL - col0 + + col2 + + 43 FROM tab1 AS cor0
----
36
59
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-9368
SELECT DISTINCT + cor0.col2 DIV - cor0.col1 + 70 FROM tab0 cor0
----
70

skipif mysql # not compatible
query I rowsort label-9368
SELECT DISTINCT + cor0.col2 / - cor0.col1 + 70 FROM tab0 cor0
----
70

query I rowsort
SELECT ALL + + 85 FROM tab0 AS cor0
----
85
85
85

query I rowsort
SELECT col2 * + col2 + 68 AS col2 FROM tab2 AS cor0
----
1512
744
797

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 22 * + cor0.col2 col1 FROM tab2 AS cor0
----
-572
-594
-836

query I rowsort
SELECT DISTINCT - 28 FROM tab0, tab2 AS cor0, tab1 cor1
----
-28

query I rowsort
SELECT DISTINCT + col1 * col2 + col0 * + col0 AS col2 FROM tab0 cor0
----
1322
15383
3414

query I rowsort
SELECT + col1 * - col2 AS col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT + ( - cor0.col2 ) * col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 col1 FROM tab2 AS cor0
----
67
67
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-9377
SELECT 70 DIV col0 FROM tab0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-9377
SELECT 70 / col0 FROM tab0
----
0
2
2

query I rowsort
SELECT DISTINCT - 54 AS col1 FROM tab1
----
-54

query I rowsort
SELECT ALL - - 45 * - col0 * 43 + - 82 * col1 FROM tab2 AS cor0
----
-154259
-155768
-16087

query I rowsort
SELECT col2 + + col1 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL - 40 * - cor0.col1 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
3354
3549
3783

onlyif mysql # use DIV operator for integer division
query I rowsort label-9382
SELECT + tab1.col1 DIV col1 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9382
SELECT + tab1.col1 / col1 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT - col1 + col2 * + 45 FROM tab1 AS cor0
----
2404
2555
4307

query I rowsort
SELECT tab2.col2 * + col1 + col2 FROM tab2
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 15 col1 FROM tab1
----
-15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9386
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-9386
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
NULL

query I rowsort
SELECT ALL col1 * - 93 AS col1 FROM tab2
----
-1581
-2883
-5487

query I rowsort
SELECT col1 * ( + 61 ) FROM tab1 AS cor0
----
1586
610
793

query I rowsort
SELECT DISTINCT - col2 * col0 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - 87 AS col0 FROM tab1, tab1 AS cor0
----
-87

query I rowsort
SELECT + - col2 * col2 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1566
-2090
-2210

query I rowsort
SELECT DISTINCT col2 * - ( 82 ) FROM tab2
----
-2132
-2214
-3116

query I rowsort
SELECT + col0 + col2 + - col1 AS col1 FROM tab2 AS cor0
----
100
3
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9394
SELECT + + col0 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9394
SELECT + + col0 * 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-9395
SELECT ( - col0 ) DIV - cor0.col0 AS col2 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9395
SELECT ( - col0 ) / - cor0.col0 AS col2 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT - ( + col2 ) * - col1 + - col1 FROM tab2
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9397
SELECT ALL + + CAST( - ( + col2 ) AS SIGNED ) * col2 + - col0 FROM tab1 cor0
----
-2919
-3313
-9296

skipif mysql # not compatible
query I rowsort label-9397
SELECT ALL + + CAST ( - ( + col2 ) AS INTEGER ) * col2 + - col0 FROM tab1 cor0
----
-2919
-3313
-9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-9398
SELECT DISTINCT + - CAST( + col2 AS SIGNED ) + - col1 DIV - col1 AS col1 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-9398
SELECT DISTINCT + - CAST ( + col2 AS INTEGER ) + - col1 / - col1 AS col1 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT - ( col2 ) * - col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + - 24 * - col2 FROM tab1 AS cor0
----
1296
1368
2304

query I rowsort
SELECT + col1 * tab0.col0 * tab0.col1 AS col2 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT + + cor0.col2 * + col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT col0 - tab2.col1 * + ( col2 ) AS col1 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT cor0.col1 * - col2 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + col0 * + ( + ( cor0.col0 ) ) + - col2 AS col0 FROM tab0 cor0
----
1224
543
7839

query I rowsort
SELECT DISTINCT + - cor0.col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT + - col2 * 14 FROM tab1 AS cor0
----
-1344
-756
-798

query I rowsort
SELECT DISTINCT + col2 * col2 * col2 AS col2 FROM tab1
----
157464
185193
884736

query I rowsort
SELECT + 97 * col1 + col1 AS col1 FROM tab2 AS cor0
----
1666
3038
5782

query I rowsort
SELECT DISTINCT + col1 - + cor0.col2 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + col0 - + col2 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL + 79 AS col1 FROM tab1 AS cor0
----
79
79
79

query I rowsort
SELECT + tab2.col2 - 10 FROM tab2
----
16
17
28

query I rowsort
SELECT DISTINCT 84 + tab1.col2 AS col2 FROM tab1
----
138
141
180

query I rowsort
SELECT col0 + - col0 * col0 AS col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT - 61 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to c91d7b51e91f33d302e697913fb438b6

query I rowsort
SELECT col2 + tab2.col2 FROM tab2
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 13 * cor1.col2 col2 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 318161c56bb53ea06874f8d395cb1886

query I rowsort
SELECT ALL + - col1 * - col0 + col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + - cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT 42 + - col2 AS col2 FROM tab0
----
-40
41
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + ( col2 + - col2 ) * - col0 AS col0 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9424
SELECT tab1.col2 * col0 DIV + col1 FROM tab1
----
364
590
6

skipif mysql # not compatible
query I rowsort label-9424
SELECT tab1.col2 * col0 / + col1 FROM tab1
----
364
590
6

query I rowsort
SELECT 5 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9426
SELECT DISTINCT - - CAST( NULL AS SIGNED ) / - col2 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9426
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) / - col2 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9427
SELECT ALL CAST( col2 AS SIGNED ) * - col2 * col2 FROM tab1 AS cor0
----
-157464
-185193
-884736

skipif mysql # not compatible
query I rowsort label-9427
SELECT ALL CAST ( col2 AS INTEGER ) * - col2 * col2 FROM tab1 AS cor0
----
-157464
-185193
-884736

query I rowsort
SELECT - 93 * + col0 + cor0.col1 - + col1 FROM tab1 AS cor0
----
-279
-5952
-7440

query I rowsort
SELECT ALL - - 64 * col2 FROM tab0 AS cor0
----
2112
5248
64

query I rowsort
SELECT ALL + col1 + col1 * col2 * - col1 AS col2 FROM tab0
----
-243982
-678951
-9312

query I rowsort
SELECT - col1 * - 46 - + col1 * + tab1.col0 FROM tab1
----
-180
-442
1118

query I rowsort
SELECT ALL col1 * col2 + - col2 * tab1.col1 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT 20 + col1 FROM tab1
----
30
33
46

query I rowsort
SELECT + - 28 + + col2 AS col0 FROM tab2 AS cor0
----
-1
-2
10

query I rowsort
SELECT DISTINCT + + 27 + ( col2 ) AS col2 FROM tab1 cor0
----
123
81
84

query I rowsort
SELECT ( - col0 ) + col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + 40 * 91 AS col0 FROM tab1 AS cor0
----
3640
3640
3640

query I rowsort
SELECT - col2 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9439
SELECT ALL + CAST( + ( col2 ) AS SIGNED ) + cor0.col0 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-9439
SELECT ALL + CAST ( + ( col2 ) AS INTEGER ) + cor0.col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - cor0.col2 + ( col0 * col1 ) FROM tab0 cor0
----
2031
3394
8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * col2 + + col0 col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9442
SELECT ALL + CAST( NULL AS DECIMAL ) * - col2 + col1 * CAST( 3 AS DECIMAL ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9442
SELECT ALL + CAST ( NULL AS REAL ) * - col2 + col1 * CAST ( 3 AS REAL ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( + ( col1 ) ) + - col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + cor0.col1 * ( col1 ) - - col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT - - col2 * col2 + + col0 AS col2 FROM tab1 cor0
----
2919
3313
9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 * - ( - col1 ) col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL col0 + col1 * - col2 AS col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT ALL col0 * - col0 + + col0 + col1 AS col2 FROM tab1
----
-4022
-6307
20

query I rowsort
SELECT ALL + 47 * cor0.col0 AS col1 FROM tab2 AS cor0
----
329
3666
3713

query I rowsort
SELECT - - col2 * col2 + col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT DISTINCT + ( tab1.col2 ) FROM tab1, tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9452
SELECT 41 DIV - tab0.col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9452
SELECT 41 / - tab0.col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + - ( 77 ) FROM tab0 AS cor0
----
-77
-77
-77

query I rowsort
SELECT + + col0 * 76 + - col0 AS col1 FROM tab0 AS cor0
----
1800
2625
6675

onlyif mysql # use DIV operator for integer division
query I rowsort label-9455
SELECT ALL - - 80 DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9455
SELECT ALL - - 80 / + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + cor0.col2 * cor0.col1 + ( col1 ) FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + col1 + col2 * - col1 * col0 AS col0 FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT ( + col1 ) * - 28 FROM tab0 AS cor0
----
-2408
-2548
-2716

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col1 col0 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + - col2 * - col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + ( col1 ) + + col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT cor0.col2 + col2 AS col1 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-9463
SELECT + + col1 + - col0 DIV - col0 FROM tab1 cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-9463
SELECT + + col1 + - col0 / - col0 FROM tab1 cor0
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + 44 + col0 + + cor0.col1 col0 FROM tab0 AS cor0
----
1562
176
3788

query I rowsort
SELECT DISTINCT - + col2 - ( col1 ) AS col2 FROM tab0 cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col1 col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL - col2 * - 43 FROM tab2 AS cor0
----
1118
1161
1634

query I rowsort
SELECT DISTINCT col2 * + col1 + col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-9469
SELECT ALL + col0 DIV + col0 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9469
SELECT ALL + col0 / + col0 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL + col1 * + 70 FROM tab0 AS cor0
----
6020
6370
6790

query I rowsort
SELECT + cor0.col2 + col1 * cor0.col0 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT col2 * 71 + col0 AS col0 FROM tab0 AS cor0
----
106
2367
5911

query I rowsort
SELECT ALL col2 + 94 * - 10 FROM tab0 AS cor0
----
-858
-907
-939

query I rowsort
SELECT ALL + col1 * 63 FROM tab2 cor0
----
1071
1953
3717

query I rowsort
SELECT DISTINCT - col2 * + 20 + col2 AS col1 FROM tab0 AS cor0
----
-1558
-19
-627

onlyif mysql # use DIV operator for integer division
query I rowsort label-9476
SELECT + + col2 DIV - col0 AS col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-9476
SELECT + + col2 / - col0 AS col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT - 59 + 39 AS col0 FROM tab2 AS cor0
----
-20
-20
-20

query I rowsort
SELECT - col0 - 97 * - col0 AS col2 FROM tab1 AS cor0
----
288
6144
7680

query I rowsort
SELECT - col1 + col0 * col1 AS col0 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL 16 * col2 + + col2 AS col1 FROM tab1 AS cor0
----
1632
918
969

query I rowsort
SELECT col1 * col0 - col1 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT col1 * 9 + + 45 * cor0.col2 * ( col0 ) AS col0 FROM tab2 AS cor0
----
135243
8784
91791

query I rowsort
SELECT + - col1 + col1 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - + col1 * 30 + col2 + + col2 AS col0 FROM tab0 AS cor0
----
-2514
-2566
-2908

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9485
SELECT ALL CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9485
SELECT ALL CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 72 FROM tab2, tab1 AS cor0
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

query I rowsort
SELECT 57 + + cor1.col0 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 92d7b706a9af5fc43d48683f871caa13

query I rowsort
SELECT - 81 * col2 + col1 FROM tab2 cor0
----
-2047
-2156
-3061

onlyif mysql # use DIV operator for integer division
query I rowsort label-9489
SELECT + - col0 * col2 + col2 DIV col2 col0 FROM tab1 AS cor0
----
-161
-3647
-7679

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9489
SELECT + - col0 * col2 + col2 / col2 col0 FROM tab1 AS cor0
----
-161
-3647
-7679

query I rowsort
SELECT - col0 + col2 * 37 AS col2 FROM tab2 AS cor0
----
1327
884
992

query I rowsort
SELECT - - cor0.col0 + + col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col1 * - col2 * col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT + col1 - + col1 AS col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9494
SELECT ALL + col1 DIV col2 - col1 col0 FROM tab0
----
-84
-90
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9494
SELECT ALL + col1 / col2 - col1 col0 FROM tab0
----
-84
-90
0

query I rowsort
SELECT tab0.col1 AS col2 FROM tab0 WHERE NOT ( NULL ) IN ( col2 + col0 )
----

query I rowsort
SELECT ALL tab1.col2 * col1 * - col0 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9497
SELECT + col1 * col0 * + CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9497
SELECT + col1 * col0 * + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + tab0.col1 - - 94 AS col1 FROM tab0, tab2 AS cor0
----
180
185
191

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab0, tab1 cor0, tab0 AS cor1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL col1 + - col2 * - 55 FROM tab2 cor0
----
1489
1516
2107

query I rowsort
SELECT ALL - + col2 + col1 * - col1 * + col1 AS col0 FROM tab1 AS cor0
----
-1057
-17630
-2293

query I rowsort
SELECT DISTINCT 52 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
52

query I rowsort
SELECT DISTINCT col0 * 99 AS col1 FROM tab1 AS cor0
----
297
6336
7920

query I rowsort
SELECT + col1 * cor0.col2 + + ( cor0.col0 ) AS col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT - + cor0.col1 + col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 + + 83 FROM tab0 AS cor0
----
169
174
180

query I rowsort
SELECT - + col0 * ( ( - col2 ) ) FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 col2 FROM tab0
----
25
25
25

query I rowsort
SELECT + ( col0 ) - - 89 * col0 * - tab2.col2 FROM tab2
----
-16814
-180414
-267099

query I rowsort
SELECT ALL + col0 + - col1 * - 22 AS col2 FROM tab0
----
1916
2091
2169

query I rowsort
SELECT ALL - col2 + 53 FROM tab1
----
-1
-4
-43

query I rowsort
SELECT + cor0.col0 + 80 FROM tab1, tab2 AS cor0
----
9 values hashing to 187baf1077bdd4e6dd8c8df53c3ece94

query I rowsort
SELECT + cor0.col2 * - col1 + col0 * col2 FROM tab1 AS cor0
----
-1242
3078
6432

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9515
SELECT - col0 * CAST( NULL AS DECIMAL ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9515
SELECT - col0 * CAST ( NULL AS REAL ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * 96 FROM tab1
----
5184
5472
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col1 + col1 * col2 col2 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT + - ( + col0 ) * col0 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + col2 * col0 * + cor0.col0 + - 50 * - col0 AS col1 FROM tab2 AS cor0
----
162084
1673
241108

query I rowsort
SELECT col1 * - col2 + col1 * + cor0.col1 - - col2 FROM tab0 AS cor0
----
4591
901
9313

query I rowsort
SELECT ( + col0 ) + + col1 AS col1 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 13 * - col2 col0 FROM tab0 AS cor0
----
-1066
-13
-429

query I rowsort
SELECT - col1 * col0 - + 33 AS col2 FROM tab2 AS cor0
----
-1376
-250
-4635

onlyif mysql # use DIV operator for integer division
query I rowsort label-9524
SELECT col1 DIV col0 + + col1 DIV - col1 - col2 col1 FROM tab1 AS cor0
----
-47
-58
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9524
SELECT col1 / col0 + + col1 / - col1 - col2 col1 FROM tab1 AS cor0
----
-47
-58
-97

query I rowsort
SELECT - col2 + col2 * + col1 * - col1 AS col2 FROM tab2 AS cor0
----
-11020
-25974
-90532

query I rowsort
SELECT ALL + cor0.col0 + + col0 + - col0 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + col1 + - col1 + + col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query IIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0 WHERE NOT ( NULL ) > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * - col1 + + col0 col2 FROM tab0 cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT + col0 / - col2 AS col2 FROM tab2 WHERE ( NULL ) NOT IN ( + tab2.col2 ) AND NOT NULL BETWEEN ( NULL ) AND col0
----

query I rowsort
SELECT - tab2.col2 * tab2.col2 * tab2.col1 + - col1 * col0 AS col1 FROM tab2
----
-22816
-25891
-44486

query I rowsort
SELECT DISTINCT - col0 + + col0 * + col2 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - col1 * + col1 + col0 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT col2 + - col1 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - col0 * col2 + cor0.col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT - col2 * col1 - col2 AS col0 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL + cor0.col0 * + col1 + - col2 AS col1 FROM tab2 cor0
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col1 + col1 + col1 col0 FROM tab1 AS cor0
----
-143
-624
-80

query I rowsort
SELECT ALL col2 + col1 + col0 FROM tab2 cor0
----
134
163
65

query I rowsort
SELECT DISTINCT + + col0 * cor0.col0 + - col2 AS col0 FROM tab2 AS cor0
----
22
6058
6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col2 * col0 col1 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT ALL col2 + + tab2.col2 AS col2 FROM tab2
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col2 col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9544
SELECT ALL col0 + - col0 DIV + col2 + col1 * + cor0.col2 * col0 AS col0 FROM tab0 AS cor0
----
3395
664206
68136

skipif mysql # not compatible
query I rowsort label-9544
SELECT ALL col0 + - col0 / + col2 + col1 * + cor0.col2 * col0 AS col0 FROM tab0 AS cor0
----
3395
664206
68136

query I rowsort
SELECT ALL + col2 * + col2 + col0 FROM tab0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-9546
SELECT ALL + col0 + - col1 DIV - tab1.col1 AS col2 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-9546
SELECT ALL + col0 + - col1 / - tab1.col1 AS col2 FROM tab1
----
4
65
81

query I rowsort
SELECT col0 + col1 * + col1 + - col2 FROM tab1
----
107
153
625

query I rowsort
SELECT ALL col1 * tab2.col1 + + col0 FROM tab2
----
3559
368
968

query I rowsort
SELECT ALL - tab1.col1 + tab1.col0 FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL - col2 + - tab2.col0 + col0 * - tab2.col1 * col2 AS col2 FROM tab2
----
-119756
-51151
-5893

onlyif mysql # use DIV operator for integer division
query I rowsort label-9551
SELECT DISTINCT tab1.col0 + + col2 + - col2 DIV col2 FROM tab1
----
120
175
56

skipif mysql # not compatible
query I rowsort label-9551
SELECT DISTINCT tab1.col0 + + col2 + - col2 / col2 FROM tab1
----
120
175
56

query I rowsort
SELECT ALL col1 + col2 * tab2.col0 * col0 FROM tab2
----
1354
158243
237175

query I rowsort
SELECT ALL col1 * col0 + - col2 AS col0 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT - - col0 * cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col1 * + col0 * - col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 * col0 col0 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL col1 * cor0.col1 - col0 FROM tab1 cor0
----
36
673
89

query I rowsort
SELECT + + col1 + - col2 * - col1 AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT col0 * + col0 * + tab1.col1 - - col2 * col1 FROM tab1
----
1638
41530
84448

query I rowsort
SELECT tab0.col1 + - tab0.col2 * + tab0.col1 AS col1 FROM tab0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9561
SELECT + col2 DIV - tab1.col1 + col0 AS col1 FROM tab1
----
1
59
73

skipif mysql # not compatible
query I rowsort label-9561
SELECT + col2 / - tab1.col1 + col0 AS col1 FROM tab1
----
1
59
73

query I rowsort
SELECT DISTINCT ( 41 ) FROM tab2
----
41

query I rowsort
SELECT - col2 - col2 * + col0 FROM tab0
----
-36
-7380
-825

query I rowsort
SELECT + ( - ( + col0 ) ) FROM tab0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 col0 FROM tab0
----
64
64
64

query I rowsort
SELECT - 13 + col2 * + col2 FROM tab2
----
1431
663
716

query I rowsort
SELECT DISTINCT + - col0 * col1 + col2 * cor0.col0 FROM tab1 AS cor0
----
3008
6640
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col1 * + col2 col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT tab2.col1 * + col2 - col1 FROM tab2
----
1475
629
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-9570
SELECT ALL + col1 DIV col1 + col0 * + col0 AS col2 FROM tab1
----
10
4097
6401

skipif mysql # not compatible
query I rowsort label-9570
SELECT ALL + col1 / col1 + col0 * + col0 AS col2 FROM tab1
----
10
4097
6401

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL IN ( tab1.col1 )
----

query III rowsort
SELECT * FROM tab0 WHERE col0 * - col0 < col0 * col1
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT - col2 FROM tab1 WHERE NOT ( NULL ) IN ( - col1 / col1 + col2 + + col0 * col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9574
SELECT DISTINCT - tab1.col2 DIV + col1 + col0 AS col2 FROM tab1
----
1
59
73

skipif mysql # not compatible
query I rowsort label-9574
SELECT DISTINCT - tab1.col2 / + col1 + col0 AS col2 FROM tab1
----
1
59
73

query I rowsort
SELECT ALL - col2 + tab2.col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT + col2 + - tab1.col0 FROM tab1
----
-7
16
51

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL IN ( col0 )
----

query I rowsort
SELECT - col2 + + col1 * col1 AS col0 FROM tab1 WHERE NULL NOT IN ( + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 - - tab0.col2 col2 FROM tab0
----
2097
3396
8181

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT - col2 + + col2 * col0 FROM tab2
----
162
2002
2964

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT - col0 BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9583
SELECT col0 DIV col1 + col2 * - col1 FROM tab2
----
-1533
-642
-837

skipif mysql # not compatible
query I rowsort label-9583
SELECT col0 / col1 + col2 * - col1 FROM tab2
----
-1533
-642
-837

query I rowsort
SELECT ALL - col2 + + col1 * col0 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT + col0 * + col2 + col1 * tab2.col1 AS col1 FROM tab2
----
1150
3291
5509

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * tab2.col0 * col0 + - col1 col0 FROM tab2
----
106080
1488
358897

query I rowsort
SELECT - col0 + + col2 AS col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT col0 FROM tab0 WHERE ( NULL ) IN ( + col2 + col1 + + col0 )
----

query I rowsort
SELECT col1 * - col1 + cor0.col1 FROM tab2 AS cor0
----
-272
-3422
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-9590
SELECT + col1 + + cor0.col1 + col0 DIV col0 AS col1 FROM tab2 AS cor0
----
119
35
63

skipif mysql # not compatible
query I rowsort label-9590
SELECT + col1 + + cor0.col1 + col0 / col0 AS col1 FROM tab2 AS cor0
----
119
35
63

query I rowsort
SELECT DISTINCT + col2 * col0 + + cor0.col0 + + col0 AS col1 FROM tab2 cor0
----
203
2184
3160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 + col0 + col2 col1 FROM tab0 AS cor0
----
-2781
-61
-7291

onlyif mysql # use DIV operator for integer division
query I rowsort label-9593
SELECT ALL col0 + + col2 * col0 DIV + col2 AS col0 FROM tab0 AS cor0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-9593
SELECT ALL col0 + + col2 * col0 / + col2 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL col0 * col1 * cor0.col2 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-9595
SELECT ALL cor0.col1 DIV col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9595
SELECT ALL cor0.col1 / col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 FROM tab2 AS cor0 WHERE col2 = NULL
----

query I rowsort
SELECT DISTINCT + col2 * - col1 AS col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT col1 FROM tab1 AS cor0 WHERE NOT NULL NOT IN ( cor0.col2 * - col0 )
----

query IIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0 WHERE NULL IN ( + cor0.col2 )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9600
SELECT tab2.col0 - CAST( NULL AS SIGNED ) FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9600
SELECT tab2.col0 - CAST ( NULL AS INTEGER ) FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + + 58 * col0 AS col2 FROM tab0 AS cor0
----
1392
2030
5162

query I rowsort
SELECT DISTINCT + ( + tab0.col0 ) * - col0 AS col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT col1 * col1 + + col2 AS col2 FROM tab2
----
327
3507
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-9604
SELECT DISTINCT col1 * col0 DIV - col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9604
SELECT DISTINCT col1 * col0 / - col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + + col1 * + col2 + - 67 FROM tab2 cor0
----
1467
579
770

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9606
SELECT col0 * - cor0.col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9606
SELECT col0 * - cor0.col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9607
SELECT - col0 + col2 DIV col0 AS col2 FROM tab2 cor0
----
-4
-78
-79

skipif mysql # not compatible
query I rowsort label-9607
SELECT - col0 + col2 / col0 AS col2 FROM tab2 cor0
----
-4
-78
-79

query I rowsort
SELECT DISTINCT + 14 + col0 AS col0 FROM tab0
----
103
38
49

query I rowsort
SELECT col0 + - col0 * - col1 AS col2 FROM tab2
----
1422
224
4680

query I rowsort
SELECT + - col2 * - col0 + col0 * col1 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT ( + cor0.col2 ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + - 31 + + col2 AS col2 FROM tab1 AS cor0
----
23
26
65

query I rowsort
SELECT - - col0 + - 99 AS col1 FROM tab0 AS cor0
----
-10
-64
-75

query I rowsort
SELECT + - cor0.col2 * + ( + col1 ) FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT col1 + ( ( + col0 ) ) FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-9616
SELECT - 81 * + col2 + + col2 DIV cor0.col2 AS col2 FROM tab1 cor0
----
-4373
-4616
-7775

skipif mysql # not compatible
query I rowsort label-9616
SELECT - 81 * + col2 + + col2 / cor0.col2 AS col2 FROM tab1 cor0
----
-4373
-4616
-7775

onlyif mysql # use DIV operator for integer division
query I rowsort label-9617
SELECT + col1 + cor0.col0 DIV col0 + - 95 * + col1 * col0 AS col2 FROM tab1 AS cor0
----
-60789
-7383
-98786

skipif mysql # not compatible
query I rowsort label-9617
SELECT + col1 + cor0.col0 / col0 + - 95 * + col1 * col0 AS col2 FROM tab1 AS cor0
----
-60789
-7383
-98786

query I rowsort
SELECT + - 25 + - col2 AS col1 FROM tab0 AS cor0
----
-107
-26
-58

query I rowsort
SELECT cor0.col1 + - 38 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 2a2798d173832cbc1b90346dfd67d223

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + col0 col0 FROM tab1 AS cor0
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - col2 col0 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT cor0.col0 * + col0 + + col1 FROM tab2 cor0
----
6143
6258
80

query I rowsort
SELECT - + 87 FROM tab2 AS cor0
----
-87
-87
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 13 + col0 * col1 * 65 col1 FROM tab2
----
14118
299143
87308

query I rowsort
SELECT 70 * + col0 FROM tab0 AS cor0
----
1680
2450
6230

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * 95 col2 FROM tab0 AS cor0
----
2280
3325
8455

onlyif mysql # use DIV operator for integer division
query I rowsort label-9627
SELECT DISTINCT + col0 DIV col1 + col2 col0 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9627
SELECT DISTINCT + col0 / col1 + col2 col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + + cor0.col0 - - col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT 73 * 66 + - col1 AS col1 FROM tab1 AS cor0
----
4792
4805
4808

query I rowsort
SELECT ALL + col2 + + cor0.col1 * col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + cor0.col1 + 12 * col2 FROM tab1 AS cor0
----
1165
674
694

query I rowsort
SELECT - - col2 * col1 + col0 - col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9633
SELECT cor0.col0 DIV - col0 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9633
SELECT cor0.col0 / - col0 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - + 59 * col0 + + col2 FROM tab0 AS cor0
----
-1383
-2064
-5169

query I rowsort
SELECT DISTINCT - ( + col2 ) + - 88 FROM tab0 cor0
----
-121
-170
-89

query I rowsort
SELECT DISTINCT col1 + - col0 * col0 FROM tab1 cor0
----
-4086
-6387
17

query I rowsort
SELECT ( + col2 + tab1.col2 * 45 ) AS col1 FROM tab1
----
2484
2622
4416

query I rowsort
SELECT + 48 + col0 * col0 FROM tab0 AS cor0
----
1273
624
7969

query I rowsort
SELECT ALL - col0 + col0 * - col0 FROM tab1 AS cor0
----
-12
-4160
-6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9640
SELECT ALL + CAST( col0 AS SIGNED ) - + col1 FROM tab0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-9640
SELECT ALL + CAST ( col0 AS INTEGER ) - + col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT ALL 92 * - 49 * col1 - col1 FROM tab0
----
-387774
-410319
-437373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9642
SELECT ALL - col2 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9642
SELECT ALL - col2 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * ( - col0 ) AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col1 * - 92 AS col1 FROM tab2 cor0
----
-1564
-2852
-5428

query I rowsort
SELECT + 99 AS col0 FROM tab1
----
99
99
99

query I rowsort
SELECT 86 * - 4 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 7bbe10d2a6dc58d1a80433e1736680d4

query I rowsort
SELECT col0 * col1 * col0 - col1 AS col0 FROM tab2
----
106080
1488
358897

onlyif mysql # use DIV operator for integer division
query I rowsort label-9648
SELECT ALL col1 DIV - ( col1 ) FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9648
SELECT ALL col1 / - ( col1 ) FROM tab0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9649
SELECT 51 + tab1.col2 DIV + col1 AS col1 FROM tab1
----
53
56
58

skipif mysql # not compatible
query I rowsort label-9649
SELECT 51 + tab1.col2 / + col1 AS col1 FROM tab1
----
53
56
58

query I rowsort
SELECT ALL col2 + - col1 - 26 AS col2 FROM tab2
----
-30
-5
-59

query I rowsort
SELECT 37 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT ALL - - 3 FROM tab2 AS cor0
----
3
3
3

query I rowsort
SELECT - col2 * - col1 * 6 FROM tab2 cor0
----
3876
5022
9204

query I rowsort
SELECT ALL - ( - col1 ) * + 38 AS col2 FROM tab1 AS cor0
----
380
494
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 93 * - col2 col2 FROM tab1 AS cor0
----
-5022
-5301
-8928

query I rowsort
SELECT + + col0 * col1 * col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT - ( col0 ) + tab1.col2 FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-9658
SELECT col2 DIV + col2 + + col2 DIV - col2 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9658
SELECT col2 / + col2 + + col2 / - col2 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col2 * + ( - col2 ) + + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT - col1 + - col0 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT col1 + ( col1 ) AS col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT 85 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

query I rowsort
SELECT DISTINCT + + col2 + ( + col1 ) * + col0 AS col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - + 60 + - cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 326a6a90f1d534b22c35e886570d0152

onlyif mysql # use DIV operator for integer division
query I rowsort label-9665
SELECT DISTINCT col0 DIV col0 + - col2 * col0 + - col1 AS col2 FROM tab2 AS cor0
----
-2086
-219
-3018

skipif mysql # not compatible
query I rowsort label-9665
SELECT DISTINCT col0 / col0 + - col2 * col0 + - col1 AS col2 FROM tab2 AS cor0
----
-2086
-219
-3018

query I rowsort
SELECT DISTINCT col0 - - col1 AS col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9667
SELECT + col1 DIV col0 + 91 * col2 AS col1 FROM tab0 cor0
----
3006
7463
93

skipif mysql # not compatible
query I rowsort label-9667
SELECT + col1 / col0 + 91 * col2 AS col1 FROM tab0 cor0
----
3006
7463
93

query I rowsort
SELECT DISTINCT + - col0 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 98 AS col2 FROM tab2
----
-98

query I rowsort
SELECT ALL col0 * col0 + cor0.col1 AS col2 FROM tab1 AS cor0
----
35
4106
6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-9671
SELECT ALL + 43 DIV + 77 col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9671
SELECT ALL + 43 / + 77 col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9672
SELECT + col0 DIV - col0 + - col1 AS col1 FROM tab1
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-9672
SELECT + col0 / - col0 + - col1 AS col1 FROM tab1
----
-11
-14
-27

query I rowsort
SELECT col0 * + 94 * - col1 + col0 AS col0 FROM tab0
----
-193992
-319095
-761217

onlyif mysql # use DIV operator for integer division
query I rowsort label-9674
SELECT - CAST( col1 AS SIGNED ) DIV col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9674
SELECT - CAST ( col1 AS INTEGER ) / col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - ( + col1 ) * - col0 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9676
SELECT + + col0 DIV - cor0.col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9676
SELECT + + col0 / - cor0.col0 FROM tab0 AS cor0
----
-1
-1
-1

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0, tab1 cor1, tab0, tab2 AS cor2
----
3645 values hashing to 149298fc0224e93f3bc2df24a3ebeeb8

onlyif mysql # use DIV operator for integer division
query I rowsort label-9678
SELECT DISTINCT - - 44 DIV 22 FROM tab2 AS cor0
----
2

skipif mysql # not compatible
query I rowsort label-9678
SELECT DISTINCT - - 44 / 22 FROM tab2 AS cor0
----
2

query I rowsort
SELECT ALL - + col0 + cor0.col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col2 * col1 col2 FROM tab1 cor0
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-9681
SELECT ALL - col0 DIV cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-9681
SELECT ALL - col0 / cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT DISTINCT - + col2 * - col1 * 89 AS col0 FROM tab2 AS cor0
----
136526
57494
74493

onlyif mysql # use DIV operator for integer division
query I rowsort label-9683
SELECT 3 DIV - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9683
SELECT 3 / - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL col0 + - col1 * ( col1 ) AS col2 FROM tab0 AS cor0
----
-7372
-8192
-9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col1 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + 47 * col0 FROM tab1 AS cor0
----
141
3008
3760

query I rowsort
SELECT ALL - + 98 * col2 FROM tab1 AS cor0
----
-5292
-5586
-9408

query I rowsort
SELECT - 49 * - cor0.col1 FROM tab2 cor0
----
1519
2891
833

query I rowsort
SELECT ALL - 49 * + col1 AS col2 FROM tab2 AS cor0
----
-1519
-2891
-833

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9690
SELECT ALL + col0 + - col1 / CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9690
SELECT ALL + col0 + - col1 / CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 * + col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + 18 AS col2 FROM tab1
----
18
18
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9693
SELECT DISTINCT CAST( ( col0 ) AS SIGNED ) * + col2 col2 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9693
SELECT DISTINCT CAST ( ( col0 ) AS INTEGER ) * + col2 col2 FROM tab2
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9694
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-9694
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 cor0, tab2 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9695
SELECT + cor0.col2 DIV tab1.col0 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to c65f3e23e10963333fdf2ac85b974f8b

skipif mysql # not compatible
query I rowsort label-9695
SELECT + cor0.col2 / tab1.col0 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to c65f3e23e10963333fdf2ac85b974f8b

query I rowsort
SELECT - 78 AS col0 FROM tab0 AS cor0
----
-78
-78
-78

query I rowsort
SELECT DISTINCT - col0 * col2 * - col1 + - col0 FROM tab0 AS cor0
----
3360
664029
68088

query I rowsort
SELECT ( - ( col1 ) ) + ( col1 ) FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9699
SELECT col1 DIV + col1 AS col2 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9699
SELECT col1 / + col1 AS col2 FROM tab2 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col0 col0 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + 9 AS col1 FROM tab2
----
9

query I rowsort
SELECT ALL + cor0.col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + col0 * 48 AS col2 FROM tab2 AS cor0
----
336
3744
3792

query I rowsort
SELECT DISTINCT ( col0 + 35 ) AS col1 FROM tab1
----
115
38
99

query I rowsort
SELECT + ( ( - col2 ) ) * cor0.col2 * - col1 + col1 AS col2 FROM tab2 AS cor0
----
22630
24565
39943

onlyif mysql # use DIV operator for integer division
query I rowsort label-9706
SELECT - 75 DIV ( + col0 ) + 67 FROM tab2 cor0
----
57
67
67

skipif mysql # not compatible
query I rowsort label-9706
SELECT - 75 / ( + col0 ) + 67 FROM tab2 cor0
----
57
67
67

query I rowsort
SELECT 40 + 49 AS col1 FROM tab1 AS cor0
----
89
89
89

query I rowsort
SELECT col2 + 1 FROM tab1
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col1 * - tab2.col1 + col0 * - tab2.col2 col0 FROM tab2
----
1911
203351
29602

query I rowsort
SELECT + 62 + + col2 AS col0 FROM tab2 AS cor0
----
100
88
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + 40 col1 FROM tab0 cor0
----
1400
3560
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-9712
SELECT ALL - + ( 70 ) + + col0 DIV - cor0.col1 AS col0 FROM tab1 AS cor0
----
-70
-76
-76

skipif mysql # not compatible
query I rowsort label-9712
SELECT ALL - + ( 70 ) + + col0 / - cor0.col1 AS col0 FROM tab1 AS cor0
----
-70
-76
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-9713
SELECT DISTINCT col2 DIV col0 + - col1 AS col2 FROM tab2 AS cor0
----
-17
-28
-59

skipif mysql # not compatible
query I rowsort label-9713
SELECT DISTINCT col2 / col0 + - col1 AS col2 FROM tab2 AS cor0
----
-17
-28
-59

query I rowsort
SELECT ALL - 84 + 82 AS col2 FROM tab2 AS cor0
----
-2
-2
-2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9715
SELECT ALL CAST( NULL AS SIGNED ) * 39 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9715
SELECT ALL CAST ( NULL AS INTEGER ) * 39 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9716
SELECT DISTINCT ( - cor0.col2 ) DIV col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9716
SELECT DISTINCT ( - cor0.col2 ) / col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + cor0.col1 * 42 AS col0 FROM tab0 AS cor0
----
3612
3822
4074

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + 32 col0 FROM tab1 AS cor0
----
128
86
89

query I rowsort
SELECT ALL col0 + - col0 + - col1 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9720
SELECT ALL col1 DIV + 41 AS col2 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9720
SELECT ALL col1 / + 41 AS col2 FROM tab2 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9721
SELECT DISTINCT + CAST( ( col0 ) AS SIGNED ) * - ( col0 ) + col2 FROM tab2 AS cor0
----
-22
-6058
-6203

skipif mysql # not compatible
query I rowsort label-9721
SELECT DISTINCT + CAST ( ( col0 ) AS INTEGER ) * - ( col0 ) + col2 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-9722
SELECT + col1 * - col1 + - 34 DIV col0 FROM tab1 AS cor0
----
-100
-169
-687

skipif mysql # not compatible
query I rowsort label-9722
SELECT + col1 * - col1 + - 34 / col0 FROM tab1 AS cor0
----
-100
-169
-687

query I rowsort
SELECT DISTINCT col0 * 14 FROM tab0 cor0
----
1246
336
490

query I rowsort
SELECT col0 * + col1 + col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + - col2 + ( - col0 ) AS col1 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9726
SELECT + col2 * CAST( col1 AS SIGNED ) + + col1 FROM tab2 cor0
----
1593
663
868

skipif mysql # not compatible
query I rowsort label-9726
SELECT + col2 * CAST ( col1 AS INTEGER ) + + col1 FROM tab2 cor0
----
1593
663
868

query I rowsort
SELECT col0 * - 99 - 1 * - cor0.col0 FROM tab1 AS cor0
----
-294
-6272
-7840

query I rowsort
SELECT DISTINCT + 74 * col0 FROM tab2
----
518
5772
5846

query I rowsort
SELECT 66 * col0 * + 52 FROM tab0
----
120120
305448
82368

query I rowsort
SELECT 24 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT ( - 81 ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

query I rowsort
SELECT + 38 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + + col2 col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT ( - tab1.col0 ) * - col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT - 41 AS col0 FROM tab0 AS cor0
----
-41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 94 + - 48 col1 FROM tab1 cor0
----
46
46
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col1 AS REAL ) col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL 27 FROM tab0, tab0 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT 47 * cor0.col2 * - col1 FROM tab2 cor0
----
-30362
-39339
-72098

query I rowsort
SELECT col2 + col0 * + 56 FROM tab2 cor0
----
419
4394
4462

query I rowsort
SELECT - ( tab2.col2 ) AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT + col2 * col1 * col2 AS col0 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT col2 * col2 * col2 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT 98 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

onlyif mysql # use DIV operator for integer division
query I rowsort label-9745
SELECT DISTINCT - 28 DIV col0 FROM tab2
----
-4
0

skipif mysql # not compatible
query I rowsort label-9745
SELECT DISTINCT - 28 / col0 FROM tab2
----
-4
0

query I rowsort
SELECT + - 88 * col0 FROM tab0 AS cor0
----
-2112
-3080
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-9747
SELECT DISTINCT - cor0.col0 DIV col1 + + 92 FROM tab0 AS cor0
----
92

skipif mysql # not compatible
query I rowsort label-9747
SELECT DISTINCT - cor0.col0 / col1 + + 92 FROM tab0 AS cor0
----
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 * col1 col0 FROM tab1 AS cor0
----
1235
2470
950

query I rowsort
SELECT 40 + cor0.col1 FROM tab0 AS cor0
----
126
131
137

onlyif mysql # use DIV operator for integer division
query I rowsort label-9750
SELECT - col1 DIV col0 col1 FROM tab0 cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9750
SELECT - col1 / col0 col1 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT ALL + cor0.col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + - col0 + col1 * 45 AS col1 FROM tab1 AS cor0
----
1167
386
505

query I rowsort
SELECT ALL + 30 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT - ( + col0 ) AS col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT - cor0.col0 * + 8 FROM tab0 AS cor0
----
-192
-280
-712

query I rowsort
SELECT cor0.col1 + ( + col0 ) * + col2 AS col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - col0 * col0 * - col1 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + + col1 + + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + cor0.col2 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + - cor0.col1 * ( col0 ) + 11 FROM tab0 AS cor0
----
-2053
-3384
-8088

query I rowsort
SELECT - col0 * cor0.col1 + - col2 * 60 AS col0 FROM tab1 AS cor0
----
-3318
-4060
-6800

onlyif mysql # use DIV operator for integer division
query I rowsort label-9762
SELECT ALL - ( + col1 ) DIV - col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-9762
SELECT ALL - ( + col1 ) / - col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT 81 * col0 + + col1 * + col0 + col2 * col1 AS col1 FROM tab2 AS cor0
----
12454
1621
8388

query I rowsort
SELECT DISTINCT - 85 AS col1 FROM tab0, tab0 AS cor0
----
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9765
SELECT DISTINCT ( - col0 ) + - col0 * + CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
-12
-4160
-6480

skipif mysql # not compatible
query I rowsort label-9765
SELECT DISTINCT ( - col0 ) + - col0 * + CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT - + cor0.col1 AS col1 FROM tab2, tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + 3 * + col2 AS col2 FROM tab2 AS cor0
----
114
78
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9768
SELECT ALL CAST( NULL AS SIGNED ) * col2 + + col2 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9768
SELECT ALL CAST ( NULL AS INTEGER ) * col2 + + col2 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - 54 + + cor0.col2 * + col1 FROM tab1 AS cor0
----
1194
1350
516

onlyif mysql # use DIV operator for integer division
query I rowsort label-9770
SELECT ALL - - 22 + cor0.col2 DIV + col0 FROM tab2 AS cor0
----
22
22
25

skipif mysql # not compatible
query I rowsort label-9770
SELECT ALL - - 22 + cor0.col2 / + col0 FROM tab2 AS cor0
----
22
22
25

query I rowsort
SELECT ALL - - 49 * - col0 AS col2 FROM tab1 AS cor0
----
-147
-3136
-3920

onlyif mysql # use DIV operator for integer division
query I rowsort label-9772
SELECT DISTINCT - cor0.col1 DIV + col1 + col2 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-9772
SELECT DISTINCT - cor0.col1 / + col1 + col2 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT ALL 83 * col2 + + col2 AS col2 FROM tab2
----
2184
2268
3192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 6 * tab0.col1 + col2 col2 FROM tab0
----
-464
-483
-581

query I rowsort
SELECT ALL - tab0.col0 * 66 FROM tab0
----
-1584
-2310
-5874

query I rowsort
SELECT + 19 FROM tab0
----
19
19
19

query I rowsort
SELECT ALL + col1 * 13 FROM tab0
----
1118
1183
1261

query I rowsort
SELECT DISTINCT - col0 * 61 * col2 + - ( - cor0.col1 ) FROM tab0 AS cor0
----
-2038
-445087
-48226

query I rowsort
SELECT DISTINCT - cor1.col2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT ALL col2 * ( 63 ) FROM tab1
----
3402
3591
6048

query I rowsort
SELECT DISTINCT + 98 * 69 FROM tab1
----
6762

onlyif mysql # use DIV operator for integer division
query I rowsort label-9782
SELECT col2 + + 64 DIV - col1 FROM tab1
----
51
52
92

skipif mysql # not compatible
query I rowsort label-9782
SELECT col2 + + 64 / - col1 FROM tab1
----
51
52
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-9783
SELECT 6 DIV col1 + col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-9783
SELECT 6 / col1 + col0 FROM tab0
----
24
35
89

query I rowsort
SELECT + 44 + col1 AS col1 FROM tab2
----
103
61
75

query I rowsort
SELECT - 22 + + 94 FROM tab2 AS cor0
----
72
72
72

query I rowsort
SELECT ALL - ( 72 ) AS col1 FROM tab1 cor0
----
-72
-72
-72

query I rowsort
SELECT DISTINCT - 7 * + col1 + - cor0.col0 FROM tab0 AS cor0
----
-626
-714
-726

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9788
SELECT DISTINCT - CAST( + col0 AS SIGNED ) * + col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-9788
SELECT DISTINCT - CAST ( + col0 AS INTEGER ) * + col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - + ( col0 ) * col1 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9790
SELECT ALL col1 * + col1 + 20 DIV col0 AS col1 FROM tab0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-9790
SELECT ALL col1 * + col1 + 20 / col0 AS col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL col2 * - col0 + - 93 * - 63 + col2 * + col1 * col0 AS col0 FROM tab0
----
662679
73179
9219

query I rowsort
SELECT ALL - 88 + col1 + + 9 AS col0 FROM tab1
----
-53
-66
-69

query I rowsort
SELECT ALL - col2 * + col2 * col1 AS col1 FROM tab0 AS cor0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 2 * col0 col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT 90 * - col0 AS col2 FROM tab0
----
-2160
-3150
-8010

query I rowsort
SELECT - col0 * - 1 AS col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT + + col1 * 44 AS col0 FROM tab2 AS cor0
----
1364
2596
748

query I rowsort
SELECT col1 + cor0.col1 * - 94 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-1305
-2472
-987

query I rowsort
SELECT DISTINCT + + col0 * col0 + 48 * - col0 AS col2 FROM tab1 AS cor0
----
-135
1024
2560

query I rowsort
SELECT ALL - cor0.col1 * - col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + col0 + - 66 FROM tab2 AS cor0
----
-59
12
13

query I rowsort
SELECT ALL cor0.col1 * ( - 80 ) AS col1 FROM tab1 cor0
----
-1040
-2080
-800

query I rowsort
SELECT - col0 + ( + col1 ) * - cor0.col1 * + col1 AS col2 FROM tab2 AS cor0
----
-205457
-29798
-4992

query I rowsort
SELECT ALL + col2 * 81 AS col1 FROM tab2 AS cor0
----
2106
2187
3078

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9805
SELECT ALL - - cor0.col1 * - CAST( - col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-9805
SELECT ALL - - cor0.col1 * - CAST ( - col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9806
SELECT + col1 + - col2 * col2 DIV col2 + col0 col2 FROM tab1 AS cor0
----
-25
-3
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9806
SELECT + col1 + - col2 * col2 / col2 + col0 col2 FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT - 28 + + col2 FROM tab1
----
26
29
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9808
SELECT + tab1.col2 - col1 * CAST( - col0 * - col2 AS SIGNED ) AS col2 FROM tab1
----
-36423
-4158
-99744

skipif mysql # not compatible
query I rowsort label-9808
SELECT + tab1.col2 - col1 * CAST ( - col0 * - col2 AS INTEGER ) AS col2 FROM tab1
----
-36423
-4158
-99744

query I rowsort
SELECT ALL col2 * col0 + col1 + col0 AS col0 FROM tab1 AS cor0
----
191
3722
7773

query I rowsort
SELECT DISTINCT - col0 + 69 AS col2 FROM tab2 AS cor0
----
-10
-9
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col2 + - col0 col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + cor0.col0 + + cor0.col0 AS col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT - col1 + - 32 AS col0 FROM tab2 AS cor0
----
-49
-63
-91

query I rowsort
SELECT ALL - cor0.col0 + col0 FROM tab0 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9815
SELECT DISTINCT + - cor0.col1 * ( col2 ) + - col0 + - CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9815
SELECT DISTINCT + - cor0.col1 * ( col2 ) + - col0 + - CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col0 + + ( 10 ) AS col2 FROM tab0
----
-14
-25
-79

query I rowsort
SELECT - cor0.col2 * col0 + col1 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT + - col0 + - 24 * ( - col1 ) + col0 AS col2 FROM tab1 AS cor0
----
240
312
624

onlyif mysql # use DIV operator for integer division
query I rowsort label-9819
SELECT ALL col0 DIV + col1 AS col0 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-9819
SELECT ALL col0 / + col1 AS col0 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT - + 24 + - 95 AS col1 FROM tab0 AS cor0
----
-119
-119
-119

query I rowsort
SELECT col2 + + col0 + col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT + col1 * - col1 * col1 AS col2 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT ALL - + cor0.col2 AS col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT + 92 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT DISTINCT tab0.col2 * - ( 63 ) FROM tab0
----
-2079
-5166
-63

query I rowsort
SELECT - 73 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2931474b870c05694e446771031a6949

query I rowsort
SELECT + tab0.col0 * + col1 * col2 AS col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT - col2 * - ( ( col1 ) * + col2 ) FROM tab0
----
611884
93654
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col1 ) + + cor0.col2 col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + col1 * + col2 + col0 * + 25 FROM tab2 AS cor0
----
1012
2621
3484

query I rowsort
SELECT ALL + col1 * col1 + + ( col2 ) + - col0 AS col0 FROM tab0 AS cor0
----
7405
8274
9375

query I rowsort
SELECT ALL 29 * col1 AS col0 FROM tab0 AS cor0
----
2494
2639
2813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9833
SELECT DISTINCT col0 * + col0 + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9833
SELECT DISTINCT col0 * + col0 + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL 40 + - col2 AS col2 FROM tab2 AS cor0
----
13
14
2

query I rowsort
SELECT ALL - col0 - + col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT 30 FROM tab0 cor0
----
30

query I rowsort
SELECT + 31 * - col1 + - col0 FROM tab1
----
-374
-483
-809

query I rowsort
SELECT - col2 + + 94 AS col2 FROM tab2
----
56
67
68

query I rowsort
SELECT col2 + ( col2 + col1 ) FROM tab2
----
111
85
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 83 * col2 col2 FROM tab1 AS cor0
----
4482
4731
7968

query I rowsort
SELECT + 51 + col1 AS col1 FROM tab0 AS cor0
----
137
142
148

onlyif mysql # use DIV operator for integer division
query I rowsort label-9842
SELECT DISTINCT col0 - - col0 DIV - col0 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-9842
SELECT DISTINCT col0 - - col0 / - col0 FROM tab0
----
23
34
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-9843
SELECT DISTINCT + tab1.col2 + - col0 DIV - ( col2 ) FROM tab1
----
54
58
96

skipif mysql # not compatible
query I rowsort label-9843
SELECT DISTINCT + tab1.col2 + - col0 / - ( col2 ) FROM tab1
----
54
58
96

query I rowsort
SELECT DISTINCT col1 + + col1 * - 80 FROM tab1
----
-1027
-2054
-790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9845
SELECT + - col2 + + col2 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9845
SELECT + - col2 + + col2 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 8 - - cor0.col2 FROM tab0 AS cor0
----
41
9
90

query I rowsort
SELECT DISTINCT - - col1 * - col0 + + col2 * col2 AS col0 FROM tab2 AS cor0
----
-3926
101
512

query I rowsort
SELECT + 15 AS col0 FROM tab2, tab2 cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 97c4e033347d2076218e240ed49af0a7

query I rowsort
SELECT 57 + col0 FROM tab0
----
146
81
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 11 col2 FROM tab1
----
-11
-11
-11

query I rowsort
SELECT - tab2.col0 * col0 + tab2.col1 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT 9 * col1 FROM tab2
----
153
279
531

query I rowsort
SELECT DISTINCT col1 + - col0 * + cor0.col1 * + 66 AS col0 FROM tab1 AS cor0
----
-42230
-5122
-68627

query I rowsort
SELECT - + cor0.col1 + - col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT - col0 + col0 * col2 - col2 AS col2 FROM tab1 cor0
----
105
3527
7504

query I rowsort
SELECT ALL - - col1 * - col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + col1 * - col1 AS col2 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT + - col1 * + col2 + col1 + + col1 FROM tab2 AS cor0
----
-1416
-612
-775

query I rowsort
SELECT - col0 + - col2 * + col2 - col2 * - col0 * - col0 FROM tab2 AS cor0
----
-158938
-2059
-238681

query I rowsort
SELECT DISTINCT - col1 * 20 AS col2 FROM tab2 cor0
----
-1180
-340
-620

query I rowsort
SELECT col0 * + col0 + + col0 * - col0 FROM tab2
----
0
0
0

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL IN ( col2 )
----

query I rowsort
SELECT col0 FROM tab0 WHERE NULL NOT IN ( + tab0.col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL = col2 * tab2.col1 - col1 * + col2
----

query III rowsort
SELECT * FROM tab1 WHERE NOT + col1 BETWEEN + col1 * col1 AND + col0
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - tab2.col0 * + col1 + + col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT + tab2.col2 - col2 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT - col1 FROM tab1 WHERE NOT ( NULL ) >= NULL
----

query I rowsort
SELECT - col0 - - col2 * - col2 * col2 FROM tab2
----
-17654
-19690
-54951

query I rowsort
SELECT - col1 FROM tab0 WHERE col0 BETWEEN - col1 AND NULL
----

query I rowsort
SELECT + tab2.col2 + + col1 * - col2 AS col2 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT col0 AS col1 FROM tab1 WHERE - col2 > NULL
----

query I rowsort
SELECT ALL + col1 * - col1 * - col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT + col1 AS col0 FROM tab0 WHERE NOT col1 + col1 BETWEEN NULL AND col2 - + col1
----
86
91
97

query I rowsort
SELECT DISTINCT - col0 - - col2 * - col1 FROM tab0
----
-132
-2862
-7551

query I rowsort
SELECT DISTINCT - + 34 * col0 - + 13 * - col2 FROM tab0 AS cor0
----
-1177
-1960
-387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 3 + - col2 col1 FROM tab0 AS cor0
----
-36
-4
-85

query I rowsort
SELECT ALL + ( - col0 ) + col2 * + 40 AS col0 FROM tab2 AS cor0
----
1073
1441
962

query I rowsort
SELECT ALL - 82 * col2 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT 6 * col2 AS col0 FROM tab0 AS cor0
----
198
492
6

query I rowsort
SELECT ALL tab0.col0 + - 13 FROM tab0
----
11
22
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9882
SELECT ALL - ( col0 ) * CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9882
SELECT ALL - ( col0 ) * CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 22 + - col0 AS col2 FROM tab2 AS cor0
----
-56
-57
15

query I rowsort
SELECT - + ( col2 ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9885
SELECT DISTINCT - col2 DIV - col2 + - col2 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-9885
SELECT DISTINCT - col2 / - col2 + - col2 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT ALL - 55 FROM tab2 AS cor0
----
-55
-55
-55

query I rowsort
SELECT ALL + 98 * col1 + ( - col0 ) FROM tab0 AS cor0
----
8404
8829
9471

query I rowsort
SELECT DISTINCT + 21 + - col2 + col1 AS col1 FROM tab1 AS cor0
----
-26
-62
-7

query I rowsort
SELECT + - 60 * - col2 FROM tab0 AS cor0
----
1980
4920
60

query I rowsort
SELECT ALL 37 * + col0 AS col2 FROM tab2 AS cor0
----
259
2886
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 47 col2 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 97 + col0 col2 FROM tab1 AS cor0
----
-5235
-5465
-9232

query I rowsort
SELECT - cor0.col2 + + cor0.col2 * 47 * cor0.col2 FROM tab1 AS cor0
----
136998
152646
433056

onlyif mysql # use DIV operator for integer division
query I rowsort label-9894
SELECT + col2 DIV - cor0.col2 + - col0 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-9894
SELECT + col2 / - cor0.col2 + - col0 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT + cor0.col1 * 49 + col1 AS col1 FROM tab2 AS cor0
----
1550
2950
850

query I rowsort
SELECT DISTINCT 28 FROM tab2, tab1 AS cor0
----
28

query I rowsort
SELECT ALL 7 * + col1 + col0 FROM tab2
----
198
224
491

query I rowsort
SELECT - 92 + + 20 FROM tab1 AS cor0
----
-72
-72
-72

query I rowsort
SELECT ALL + - 89 AS col2 FROM tab2 cor0
----
-89
-89
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9900
SELECT ALL + CAST( + 28 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
28
28
28

skipif mysql # not compatible
query I rowsort label-9900
SELECT ALL + CAST ( + 28 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
28
28
28

query I rowsort
SELECT + - 96 * + col1 + col2 FROM tab2 cor0
----
-1594
-2949
-5638

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - cor0.col0 col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - + cor0.col2 + - col1 AS col1 FROM tab2 cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-9904
SELECT ALL + + col2 DIV col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9904
SELECT ALL + + col2 / col2 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 * col1 col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT col1 * - col1 + + col2 + col0 AS col1 FROM tab1 cor0
----
-619
21
7

query I rowsort
SELECT DISTINCT - - col1 + - col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT 76 * - cor0.col2 FROM tab1 AS cor0
----
-4104
-4332
-7296

query I rowsort
SELECT DISTINCT - col1 + - col0 * - tab0.col0 + col2 FROM tab0
----
1129
523
7912

query I rowsort
SELECT + 83 + col1 FROM tab2
----
100
114
142

query I rowsort
SELECT DISTINCT 68 * + col1 AS col0 FROM tab0
----
5848
6188
6596

query I rowsort
SELECT - + col0 + cor0.col1 * col0 * col2 FROM tab0 AS cor0
----
3360
664029
68088

query I rowsort
SELECT 42 - + col0 FROM tab0 AS cor0
----
-47
18
7

query I rowsort
SELECT ALL - + 34 * 85 + - col0 AS col2 FROM tab2 AS cor0
----
-2897
-2968
-2969

query I rowsort
SELECT DISTINCT + - 44 + col1 FROM tab2 AS cor0
----
-13
-27
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9916
SELECT DISTINCT + CAST( - col2 AS SIGNED ) + - col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

skipif mysql # not compatible
query I rowsort label-9916
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) + - col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - 65 + col0 AS col1 FROM tab0 AS cor0
----
-30
-41
24

query I rowsort
SELECT DISTINCT col0 * + tab0.col0 + + ( + tab0.col0 ) AS col0 FROM tab0
----
1260
600
8010

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 cor1, tab0 AS cor2
----
972 values hashing to 63ccb67e72ebac679a0221202c067b9e

query I rowsort
SELECT ALL + ( - col2 ) * tab1.col1 + - col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT 34 + - col2 FROM tab2
----
-4
7
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-9922
SELECT 17 DIV + col1 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9922
SELECT 17 / + col1 FROM tab2
----
0
0
1

query I rowsort
SELECT DISTINCT ( - col2 ) + col1 AS col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL col0 * - tab1.col0 * col0 + col0 AS col1 FROM tab1
----
-24
-262080
-511920

query I rowsort
SELECT DISTINCT + 71 + cor0.col2 AS col2 FROM tab1 AS cor0
----
125
128
167

query I rowsort
SELECT ALL - 72 + col0 FROM tab2 AS cor0
----
-65
6
7

query I rowsort
SELECT - col2 + - cor0.col1 AS col1 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT ALL ( col2 ) * + cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 78 * col1 + - col2 * col2 FROM tab0 cor0
----
374
5619
7565

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 62 col2 FROM tab0
----
-62
-62
-62

query I rowsort
SELECT - ( + 75 ) * tab0.col2 AS col0 FROM tab0
----
-2475
-6150
-75

query I rowsort
SELECT - 73 FROM tab1, tab0 AS cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

query I rowsort
SELECT ALL + col1 + 16 AS col1 FROM tab0 AS cor0
----
102
107
113

query IIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 CROSS JOIN tab0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col0 col1 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT + col1 * - col2 FROM tab0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT - tab0.col1 FROM tab0 WHERE NOT col2 NOT IN ( + col0 + + tab0.col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 cor0 WHERE NOT NULL < col2 * - col0
----

query I rowsort
SELECT - col1 * col2 + - col1 AS col2 FROM tab2
----
-1593
-663
-868

query I rowsort
SELECT col1 FROM tab1 WHERE ( col0 ) NOT IN ( col0 )
----

query I rowsort
SELECT ALL col2 AS col2 FROM tab2 WHERE NOT ( col0 ) NOT IN ( col2 )
----

query I rowsort
SELECT + col0 + col1 AS col1 FROM tab1 WHERE ( + col1 ) <> - col2
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 col1 FROM tab1 AS cor0 WHERE ( NULL ) NOT IN ( col1 + - cor0.col2 )
----

query I rowsort
SELECT col2 FROM tab0 AS cor0 WHERE NOT ( NULL ) > col2 + + col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 * - col1 col2 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT - col0 + col0 * col2 * col0 FROM tab1 cor0
----
233408
483
614320

query I rowsort
SELECT col2 * col1 * col0 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col2 col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col2 + cor0.col1 + - col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT col2 - col0 * col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL cor0.col2 * - col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-9952
SELECT + cor0.col1 DIV - col2 + + col2 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9952
SELECT + cor0.col1 / - col2 + + col2 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 * - col0 - col0 * col1 * col2 col1 FROM tab0 AS cor0
----
-1328236
-136224
-6790

query I rowsort
SELECT - col1 * + col1 + cor0.col1 * col2 * col2 - - col1 * col1 FROM tab2 AS cor0
----
22599
24548
39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * tab0.col2 col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col1 + + col1 * + cor0.col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - col1 + col1 * + col2 * col0 FROM tab1 AS cor0
----
36470
4186
99827

query I rowsort
SELECT - + col2 * 82 + - col2 * col1 + - ( - 22 ) AS col0 FROM tab2 AS cor0
----
-3029
-3644
-3740

query I rowsort
SELECT + col1 * 0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 + col0 * col1 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT col2 * 44 AS col0 FROM tab1 AS cor0
----
2376
2508
4224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 88 col2 FROM tab0 AS cor0
----
88
88
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-9963
SELECT - col0 DIV 46 AS col2 FROM tab1 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-9963
SELECT - col0 / 46 AS col2 FROM tab1 cor0
----
-1
-1
0

query I rowsort
SELECT ALL col2 + - cor0.col2 * col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-9965
SELECT ALL col2 + col2 * - col1 - - CAST( col0 + col0 AS SIGNED ) DIV - cor0.col0 AS col1 FROM tab2 AS cor0
----
-1510
-610
-812

skipif mysql # not compatible
query I rowsort label-9965
SELECT ALL col2 + col2 * - col1 - - CAST ( col0 + col0 AS INTEGER ) / - cor0.col0 AS col1 FROM tab2 AS cor0
----
-1510
-610
-812

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9966
SELECT DISTINCT col1 * - col0 + col2 * - CAST( NULL AS SIGNED ) * - col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9966
SELECT DISTINCT col1 * - col0 + col2 * - CAST ( NULL AS INTEGER ) * - col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + + col2 AS col1 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT + cor0.col0 * + 87 AS col1 FROM tab2 cor0
----
609
6786
6873

query I rowsort
SELECT ALL + 35 - - 41 AS col1 FROM tab1 AS cor0
----
76
76
76

query I rowsort
SELECT + + ( + cor0.col2 ) AS col0 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + col0 col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - + cor0.col1 * col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + + ( - col1 ) * ( - col1 ) - + col2 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT DISTINCT ( + col0 ) * - col1 AS col1 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9975
SELECT + - col1 DIV + col1 + + 48 * + col1 AS col1 FROM tab0 AS cor0
----
4127
4367
4655

skipif mysql # not compatible
query I rowsort label-9975
SELECT + - col1 / + col1 + + 48 * + col1 AS col1 FROM tab0 AS cor0
----
4127
4367
4655

query I rowsort
SELECT + + col2 - + col1 * 35 AS col2 FROM tab0 AS cor0
----
-2977
-3103
-3394

query I rowsort
SELECT ALL - ( - 57 ) + + col2 * - col1 AS col2 FROM tab0
----
-2781
-40
-7405

query I rowsort
SELECT + + 41 * col0 AS col1 FROM tab1 AS cor0
----
123
2624
3280

query I rowsort
SELECT - + col1 * - 67 + col2 * col2 AS col1 FROM tab1 cor0
----
10087
3919
4658

query I rowsort
SELECT DISTINCT + col2 + - 86 * - col0 AS col2 FROM tab2 AS cor0
----
629
6734
6832

query I rowsort
SELECT ALL + col2 * + col0 + 88 FROM tab1 AS cor0
----
250
3736
7768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9982
SELECT ALL + - col2 + - CAST( 43 AS SIGNED ) - col2 AS col1 FROM tab0 AS cor0
----
-109
-207
-45

skipif mysql # not compatible
query I rowsort label-9982
SELECT ALL + - col2 + - CAST ( 43 AS INTEGER ) - col2 AS col1 FROM tab0 AS cor0
----
-109
-207
-45

query I rowsort
SELECT + col1 + 45 AS col0 FROM tab2 AS cor0
----
104
62
76

query I rowsort
SELECT DISTINCT - col0 + + col0 * + ( - col1 ) FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9985
SELECT ALL + cor0.col0 + CAST( NULL AS SIGNED ) + col0 * + cor0.col0 * cor0.col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9985
SELECT ALL + cor0.col0 + CAST ( NULL AS INTEGER ) + col0 * + cor0.col0 * cor0.col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * + col1 + - 27 * + col0 * cor0.col0 FROM tab2 AS cor0
----
-162734
-167861
-486

query I rowsort
SELECT + col2 + - col0 * 40 AS col2 FROM tab0 AS cor0
----
-1399
-3478
-927

query I rowsort
SELECT DISTINCT + col0 * col2 * - col2 + col1 + - col2 * col1 FROM tab2 AS cor0
----
-114705
-54203
-5909

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9989
SELECT DISTINCT col1 * CAST( - ( col0 ) AS SIGNED ) + + col2 + - col0 * col2 FROM tab0 AS cor0
----
-15315
-2823
-3429

skipif mysql # not compatible
query I rowsort label-9989
SELECT DISTINCT col1 * CAST ( - ( col0 ) AS INTEGER ) + + col2 + - col0 * col2 FROM tab0 AS cor0
----
-15315
-2823
-3429

onlyif mysql # use DIV operator for integer division
query I rowsort label-9990
SELECT - 81 DIV tab0.col2 FROM tab0
----
-2
-81
0

skipif mysql # not compatible
query I rowsort label-9990
SELECT - 81 / tab0.col2 FROM tab0
----
-2
-81
0

query I rowsort
SELECT + + col2 * col2 + col2 AS col0 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT + + tab1.col1 * tab1.col2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to f8894e3f33962cda5901e1c2ce65d5b0

query I rowsort
SELECT DISTINCT + tab2.col1 + + 33 * col1 FROM tab2
----
1054
2006
578

query I rowsort
SELECT DISTINCT + + 91 FROM tab0 AS cor0
----
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-9995
SELECT DISTINCT tab1.col0 * 1 + + col2 * - col1 + ( tab1.col0 ) DIV col0 FROM tab1
----
-1167
-1400
-505

skipif mysql # not compatible
query I rowsort label-9995
SELECT DISTINCT tab1.col0 * 1 + + col2 * - col1 + ( tab1.col0 ) / col0 FROM tab1
----
-1167
-1400
-505

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2, tab1 AS cor3
----
3645 values hashing to d865c68b86e66898eeac28f450e48e70

query I rowsort
SELECT DISTINCT - + ( + col0 ) - col1 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL - col0 * - cor0.col0 + - ( + col2 ) + col1 AS col1 FROM tab2 AS cor0
----
53
6117
6220

