sqllogictest

Artifact [27cf67ae70]
Login

Artifact 27cf67ae703767bd7735b4289b1f0244785ca45d:


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 + - col0 * + col2 + col1 AS col1 FROM tab0 AS cor0
----
-706
-7207
62

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

query I rowsort
SELECT ALL - col1 + tab1.col1 * - 82 * + ( tab1.col1 ) AS col0 FROM tab1
----
-13871
-55458
-8210

query I rowsort
SELECT DISTINCT 30 - - col1 * + col2 AS col2 FROM tab0
----
127
2868
7492

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

query I rowsort
SELECT + 38 * + 67 FROM tab2, tab0 cor0
----
9 values hashing to b8233df8cded22604194961c1ba09040

onlyif mysql # use DIV operator for integer division
query I rowsort label-6
SELECT ALL col0 * col0 + + col1 DIV + ( col1 ) FROM tab2 AS cor0
----
50
6085
6242

skipif mysql # not compatible
query I rowsort label-6
SELECT ALL col0 * col0 + + col1 / + ( col1 ) FROM tab2 AS cor0
----
50
6085
6242

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

query I rowsort
SELECT - 36 * - cor0.col0 + + col1 * 22 FROM tab1 AS cor0
----
2524
3166
680

query I rowsort
SELECT DISTINCT + - col0 + cor0.col1 * cor0.col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
16144
36501
5636

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - CAST ( + col2 AS REAL ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + 18 * col0 + + col2 AS col2 FROM tab2 AS cor0
----
1430
1460
153

query I rowsort
SELECT ALL + col1 + cor0.col2 * - col2 AS col0 FROM tab0 cor0
----
-1003
-6633
96

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

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

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

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

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

query I rowsort
SELECT ALL - col0 * 83 FROM tab0 AS cor0
----
-1992
-2905
-7387

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

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

query I rowsort
SELECT - 42 * col2 * col0 AS col0 FROM tab1 AS cor0
----
-153216
-322560
-6804

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

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

query I rowsort
SELECT + + col0 + cor0.col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT 69 + - col1 * + col1 AS col1 FROM tab0
----
-7327
-8212
-9340

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

query I rowsort
SELECT ALL + - col2 + ( - 95 ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
-2313
-3326
-8537

query I rowsort
SELECT - cor0.col0 * + ( 14 ) FROM tab1 cor0
----
-1120
-42
-896

query I rowsort
SELECT DISTINCT - + col1 * ( - 55 ) FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT - 93 * - tab0.col1 + col2 FROM tab0
----
8031
8545
9022

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col1 * 22 col0 FROM tab0 AS cor0
----
1916
2091
2169

onlyif mysql # use DIV operator for integer division
query I rowsort label-31
SELECT DISTINCT - col1 DIV - col0 + + col2 + + col2 FROM tab2 AS cor0
----
52
58
76

skipif mysql # not compatible
query I rowsort label-31
SELECT DISTINCT - col1 / - col0 + + col2 + + col2 FROM tab2 AS cor0
----
52
58
76

query I rowsort
SELECT DISTINCT cor0.col0 * - 79 AS col1 FROM tab1 AS cor0
----
-237
-5056
-6320

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

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

query I rowsort
SELECT - tab0.col2 + + 45 AS col0 FROM tab0
----
-37
12
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-35
SELECT - col1 DIV - CAST( ( + col2 ) AS SIGNED ) FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-35
SELECT - col1 / - CAST ( ( + col2 ) AS INTEGER ) FROM tab0
----
1
2
97

query I rowsort
SELECT + 87 + col2 FROM tab1 cor0
----
141
144
183

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

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

skipif mysql # not compatible
query I rowsort label-38
SELECT + 38 / - col0 FROM tab0 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL - col2 + + col1 - col0 FROM tab1
----
-111
-163
-31

query I rowsort
SELECT - + 65 AS col1 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to 62fe7b8eb6ce8c547418f08ea8ada1fc

query I rowsort
SELECT DISTINCT - col1 * + 62 - - col1 FROM tab1
----
-1586
-610
-793

query I rowsort
SELECT DISTINCT - col0 + 41 AS col2 FROM tab2
----
-37
-38
34

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

query I rowsort
SELECT ALL 10 + tab2.col1 FROM tab2
----
27
41
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-45
SELECT + tab0.col0 DIV 12 FROM tab0
----
2
2
7

skipif mysql # not compatible
query I rowsort label-45
SELECT + tab0.col0 / 12 FROM tab0
----
2
2
7

query I rowsort
SELECT DISTINCT 25 AS col1 FROM tab0
----
25

query I rowsort
SELECT DISTINCT - 28 * col0 FROM tab0
----
-2492
-672
-980

query I rowsort
SELECT DISTINCT tab0.col1 * col0 * + ( col0 * col2 ) FROM tab0
----
118825
1634688
59106502

query I rowsort
SELECT + 6 * + col1 + col0 * + 79 FROM tab2 AS cor0
----
6343
6516
739

query I rowsort
SELECT DISTINCT 14 + cor0.col1 AS col0 FROM tab1 AS cor0
----
24
27
40

query I rowsort
SELECT + - col2 * - col2 + 61 + col1 * col1 FROM tab1 AS cor0
----
3410
3653
9446

query I rowsort
SELECT DISTINCT 39 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
39

query I rowsort
SELECT DISTINCT - - cor0.col2 * - 98 AS col1 FROM tab1 AS cor0
----
-5292
-5586
-9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 14 col2 FROM tab1 cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 742ac5d81e64168a26fbd2bc8c808eff

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

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

query I rowsort
SELECT ALL + col2 + - 49 AS col2 FROM tab1 AS cor0
----
47
5
8

query I rowsort
SELECT col1 * - 56 FROM tab2 AS cor0
----
-1736
-3304
-952

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

query I rowsort
SELECT + col2 + 60 * col2 * col1 AS col2 FROM tab2 AS cor0
----
38798
50247
92066

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

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

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

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

query I rowsort
SELECT DISTINCT + 67 + + col1 * 66 FROM tab0 AS cor0
----
5743
6073
6469

query I rowsort
SELECT + + col2 * col2 + + ( col2 ) * - col1 FROM tab2 AS cor0
----
-108
-858
798

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

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

query I rowsort
SELECT - 96 FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
81 values hashing to 5c66f1deb3d2ed61020ac982642dd7b2

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

query I rowsort
SELECT ALL col1 * - col1 + col2 AS col0 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT 19 * 30 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 3b6a5baf6a60e1ff4ab50392d81153af

query I rowsort
SELECT ALL - 6 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 8be8910507908e6353d02a545b748252

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

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

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

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

skipif mysql # not compatible
query I rowsort label-75
SELECT ALL - CAST ( NULL AS INTEGER ) / - 81 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-76
SELECT col2 + - CAST( 56 AS SIGNED ) FROM tab2 AS cor0
----
-18
-29
-30

skipif mysql # not compatible
query I rowsort label-76
SELECT col2 + - CAST ( 56 AS INTEGER ) FROM tab2 AS cor0
----
-18
-29
-30

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

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

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

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

query I rowsort
SELECT 14 * - col2 + - col2 FROM tab2 AS cor0
----
-390
-405
-570

query I rowsort
SELECT + 4 - - col1 AS col0 FROM tab2 AS cor0
----
21
35
63

query I rowsort
SELECT - cor0.col0 + 43 FROM tab1 cor0
----
-21
-37
40

query I rowsort
SELECT DISTINCT + col2 + + 39 FROM tab0 AS cor0
----
121
40
72

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

query I rowsort
SELECT ALL - cor0.col2 * 26 + col2 * + cor0.col0 FROM tab0 AS cor0
----
-66
5166
9

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

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

query I rowsort
SELECT ALL + col2 * + 27 + + col0 FROM tab2 AS cor0
----
1105
736
780

onlyif mysql # use DIV operator for integer division
query I rowsort label-90
SELECT ALL - col1 DIV col2 + + cor0.col0 * 35 FROM tab0 AS cor0
----
1128
3114
838

skipif mysql # not compatible
query I rowsort label-90
SELECT ALL - col1 / col2 + + cor0.col0 * 35 FROM tab0 AS cor0
----
1128
3114
838

query I rowsort
SELECT + 34 AS col2 FROM tab1 AS cor0
----
34
34
34

query I rowsort
SELECT 97 - - cor0.col1 AS col1 FROM tab0 AS cor0
----
183
188
194

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

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

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

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

query I rowsort
SELECT - col1 + 43 + + col2 FROM tab2
----
10
39
64

query I rowsort
SELECT ALL + 11 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

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

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

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

query I rowsort
SELECT - col0 * 43 AS col1 FROM tab1 cor0
----
-129
-2752
-3440

query I rowsort
SELECT - + 54 + + col0 FROM tab2 AS cor0
----
-47
24
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col2 ) col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT col1 * + 78 AS col2 FROM tab1 cor0
----
1014
2028
780

query I rowsort
SELECT + 48 * + 59 + + col0 + - col0 FROM tab0 AS cor0
----
2832
2832
2832

query I rowsort
SELECT - 94 * 95 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-151810
-276830
-526870

query I rowsort
SELECT ALL - + 3 * - col0 AS col2 FROM tab0 AS cor0
----
105
267
72

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

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

query I rowsort
SELECT ALL + - 87 FROM tab2 cor0
----
-87
-87
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-109
SELECT - col0 DIV + col0 + + col1 - col1 * col2 * - col0 FROM tab2
----
119710
51050
5889

skipif mysql # not compatible
query I rowsort label-109
SELECT - col0 / + col0 + + col1 - col1 * col2 * - col0 FROM tab2
----
119710
51050
5889

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

query I rowsort
SELECT DISTINCT - 35 - col2 FROM tab1
----
-131
-89
-92

query I rowsort
SELECT 8 + col2 * + tab2.col1 AS col0 FROM tab2
----
1542
654
845

query I rowsort
SELECT DISTINCT col1 - + 32 FROM tab2
----
-1
-15
27

query I rowsort
SELECT DISTINCT - - 64 + col2 FROM tab0 AS cor0
----
146
65
97

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-116
SELECT DISTINCT - col2 * col1 DIV col0 AS col0 FROM tab2 AS cor0
----
-119
-19
-8

skipif mysql # not compatible
query I rowsort label-116
SELECT DISTINCT - col2 * col1 / col0 AS col0 FROM tab2 AS cor0
----
-119
-19
-8

query I rowsort
SELECT DISTINCT - col2 * 41 + col2 AS col1 FROM tab0 AS cor0
----
-1320
-3280
-40

query I rowsort
SELECT DISTINCT + col1 * ( + 10 * col2 ) + - 66 AS col1 FROM tab1 AS cor0
----
12414
13974
5634

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

query I rowsort
SELECT DISTINCT col0 + 66 * - 96 AS col0 FROM tab2 cor0
----
-6257
-6258
-6329

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

query I rowsort
SELECT DISTINCT + col2 * ( 18 ) AS col0 FROM tab1 AS cor0
----
1026
1728
972

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

skipif mysql # not compatible
query I rowsort label-123
SELECT DISTINCT col1 / - 42 FROM tab0 AS cor0
----
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-124
SELECT DISTINCT col2 + 95 * col0 DIV col2 FROM tab1 AS cor0
----
163
175
59

skipif mysql # not compatible
query I rowsort label-124
SELECT DISTINCT col2 + 95 * col0 / col2 FROM tab1 AS cor0
----
163
175
59

query I rowsort
SELECT ALL + - col1 + 23 * + col0 FROM tab1 AS cor0
----
1462
1827
43

query I rowsort
SELECT ALL - col2 + - 17 AS col0 FROM tab0 AS cor0
----
-18
-50
-99

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-128
SELECT DISTINCT + - cor0.col1 - - CAST( + 42 AS SIGNED ) FROM tab1 AS cor0
----
16
29
32

skipif mysql # not compatible
query I rowsort label-128
SELECT DISTINCT + - cor0.col1 - - CAST ( + 42 AS INTEGER ) FROM tab1 AS cor0
----
16
29
32

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-131
SELECT + 69 DIV - 94 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-131
SELECT + 69 / - 94 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-132
SELECT ALL col2 DIV + 7 FROM tab2
----
3
3
5

skipif mysql # not compatible
query I rowsort label-132
SELECT ALL col2 / + 7 FROM tab2
----
3
3
5

query I rowsort
SELECT DISTINCT 49 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
49

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-140
SELECT DISTINCT tab0.col1 DIV 37 AS col2 FROM tab0, tab2 cor0
----
2

skipif mysql # not compatible
query I rowsort label-140
SELECT DISTINCT tab0.col1 / 37 AS col2 FROM tab0, tab2 cor0
----
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-141
SELECT ALL + col1 + ( 65 + col2 ) * 22 DIV + col0 FROM tab1 AS cor0
----
51
57
898

skipif mysql # not compatible
query I rowsort label-141
SELECT ALL + col1 + ( 65 + col2 ) * 22 / + col0 FROM tab1 AS cor0
----
51
57
898

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

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

query I rowsort
SELECT + + col2 - + 39 AS col1 FROM tab2 AS cor0
----
-1
-12
-13

query I rowsort
SELECT - - col0 - + 47 * 77 * - cor0.col2 FROM tab1 AS cor0
----
195429
206347
347504

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + col2 * col0 + col2 col1 FROM tab0 AS cor0
----
71
7469
849

query I rowsort
SELECT ALL col1 - 57 AS col2 FROM tab2 AS cor0
----
-26
-40
2

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

query I rowsort
SELECT DISTINCT 35 + tab1.col2 FROM tab1, tab0 cor0
----
131
89
92

query I rowsort
SELECT ALL + 76 AS col2 FROM tab0
----
76
76
76

query I rowsort
SELECT + ( - 28 ) * col2 + col2 AS col2 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT ALL + ( + cor0.col0 ) * + col2 + 97 + col2 FROM tab2 cor0
----
2151
313
3137

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

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

query I rowsort
SELECT + 39 * - col1 AS col1 FROM tab2 AS cor0
----
-1209
-2301
-663

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

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

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

query I rowsort
SELECT DISTINCT - 8 * + col1 AS col2 FROM tab1 AS cor0
----
-104
-208
-80

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

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

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

skipif mysql # not compatible
query I rowsort label-159
SELECT + CAST ( col2 AS INTEGER ) * + col0 * - ( + ( col0 ) ) FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT + + 78 * 48 AS col2 FROM tab2 cor0
----
3744

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

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

query I rowsort
SELECT DISTINCT - + 42 * col0 FROM tab0 AS cor0
----
-1008
-1470
-3738

query I rowsort
SELECT DISTINCT 8 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
8

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

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

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

query I rowsort
SELECT DISTINCT + + cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
86
91
97

query I rowsort
SELECT DISTINCT + 84 * - col1 AS col0 FROM tab0
----
-7224
-7644
-8148

query I rowsort
SELECT 5 * col0 + - cor0.col1 + ( cor0.col0 + + col2 ) AS col1 FROM tab1 cor0
----
431
46
563

query I rowsort
SELECT + + 90 FROM tab2 cor0
----
90
90
90

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-172
SELECT + col2 / + 14 col2 FROM tab2 AS cor0
----
1
1
2

query I rowsort
SELECT + + col2 * 45 FROM tab0 AS cor0
----
1485
3690
45

query I rowsort
SELECT - - cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT 23 * col0 + col1 * - col0 + 28 FROM tab1 AS cor0
----
19
828
860

query I rowsort
SELECT - + 69 + col2 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-35
35
48

query I rowsort
SELECT ALL - 20 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query I rowsort
SELECT - 52 * - col0 * col0 - col1 FROM tab0 AS cor0
----
29866
411801
63603

query I rowsort
SELECT + + col2 + - col1 * - col1 * ( + col2 ) + - cor0.col1 AS col1 FROM tab2 AS cor0
----
11003
25943
90473

query I rowsort
SELECT ( col0 ) * + col1 * col0 FROM tab2
----
106097
1519
358956

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

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

query I rowsort
SELECT 26 + cor0.col0 + + col0 FROM tab1 AS cor0
----
154
186
32

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

query I rowsort
SELECT DISTINCT + 80 * col0 AS col0 FROM tab1 AS cor0
----
240
5120
6400

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-188
SELECT ALL - col0 + 3 * cor0.col2 DIV col0 AS col0 FROM tab2 cor0
----
-77
-78
4

skipif mysql # not compatible
query I rowsort label-188
SELECT ALL - col0 + 3 * cor0.col2 / col0 AS col0 FROM tab2 cor0
----
-77
-78
4

query I rowsort
SELECT + col1 * - 45 + + ( - col0 ) + - cor0.col2 FROM tab0 AS cor0
----
-3927
-4266
-4401

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-192
SELECT DISTINCT + col1 DIV ( - col2 ) - - col2 * - 55 AS col1 FROM tab0 AS cor0
----
-152
-1817
-4511

skipif mysql # not compatible
query I rowsort label-192
SELECT DISTINCT + col1 / ( - col2 ) - - col2 * - 55 AS col1 FROM tab0 AS cor0
----
-152
-1817
-4511

query I rowsort
SELECT DISTINCT cor0.col2 * 59 FROM tab0, tab2, tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT - col2 * 63 AS col1 FROM tab1
----
-3402
-3591
-6048

query I rowsort
SELECT ALL + 29 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL + 6 * + col1 AS col2 FROM tab0 AS cor0
----
516
546
582

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

query I rowsort
SELECT 11 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT ALL - tab0.col0 + - col0 + col2 FROM tab0
----
-15
-69
-96

query I rowsort
SELECT DISTINCT + col1 * + col2 + + 13 * col0 FROM tab0
----
3150
552
8619

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

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

query I rowsort
SELECT DISTINCT + col1 - - 17 FROM tab0
----
103
108
114

query I rowsort
SELECT ALL + tab0.col0 * col2 * col0 - col0 * + col1 * + col0 AS col2 FROM tab0
----
-117600
-30528
-71289

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

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

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

query I rowsort
SELECT DISTINCT - cor0.col1 + cor0.col1 * cor0.col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT DISTINCT col1 + col0 * + 88 FROM tab2 AS cor0
----
647
6923
6969

onlyif mysql # use DIV operator for integer division
query I rowsort label-209
SELECT ALL - + col0 + - col2 DIV + col2 - col2 * + col2 AS col2 FROM tab0 AS cor0
----
-1114
-37
-6814

skipif mysql # not compatible
query I rowsort label-209
SELECT ALL - + col0 + - col2 / + col2 - col2 * + col2 AS col2 FROM tab0 AS cor0
----
-1114
-37
-6814

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

query I rowsort
SELECT - - ( 77 ) AS col2 FROM tab1, tab2, tab0 cor0
----
27 values hashing to d7b027bca5d37c67e29013904def8125

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

query I rowsort
SELECT DISTINCT + ( 99 + + col0 ) FROM tab1
----
102
163
179

query I rowsort
SELECT ALL - 61 * + tab0.col0 FROM tab0
----
-1464
-2135
-5429

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 37 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

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

query IIIIIIIII rowsort
SELECT * FROM tab0, tab2, tab1 AS cor0 WHERE ( tab2.col1 ) >= NULL
----

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

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

query I rowsort
SELECT + 39 + - col0 * col0 AS col1 FROM tab2 cor0
----
-10
-6045
-6202

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

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

query I rowsort
SELECT - 42 + + col0 FROM tab2
----
-35
36
37

query I rowsort
SELECT col0 * - 21 AS col2 FROM tab2 AS cor0
----
-147
-1638
-1659

query I rowsort
SELECT ALL - + cor0.col1 + - 60 * - ( + col0 ) AS col2 FROM tab1 AS cor0
----
154
3830
4787

query I rowsort
SELECT DISTINCT - col0 + - 17 * 63 FROM tab0 AS cor0
----
-1095
-1106
-1160

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

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

query I rowsort
SELECT + col2 + - col0 * 10 AS col0 FROM tab2 AS cor0
----
-43
-752
-754

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

skipif mysql # not compatible
query I rowsort label-229
SELECT ALL + - col0 + ( col2 ) / - col0 FROM tab0 cor0
----
-25
-35
-89

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

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

query I rowsort
SELECT ALL col0 * ( + 38 ) AS col1 FROM tab0 cor0
----
1330
3382
912

query I rowsort
SELECT DISTINCT + col0 + 37 AS col0 FROM tab0 AS cor0
----
126
61
72

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

query I rowsort
SELECT - col1 * + 10 FROM tab2 AS cor0
----
-170
-310
-590

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

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

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

query I rowsort
SELECT ALL ( 45 ) FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col2 AS REAL ) * col0 * - 57 FROM tab2 AS cor0
----
-10773
-115596
-171114

query I rowsort
SELECT ALL - 3 * col2 FROM tab1 AS cor0
----
-162
-171
-288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 70 + ( + col0 ) col0 FROM tab0 AS cor0
----
105
159
94

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

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

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

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

skipif mysql # not compatible
query I rowsort label-247
SELECT - cor0.col1 + - ( col2 ) / + cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

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

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

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

skipif mysql # not compatible
query I rowsort label-249
SELECT ALL CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
24
35
89

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-252
SELECT DISTINCT - col2 + + col2 * col0 DIV 73 FROM tab0
----
-1
-23
17

skipif mysql # not compatible
query I rowsort label-252
SELECT DISTINCT - col2 + + col2 * col0 / 73 FROM tab0
----
-1
-23
17

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

query I rowsort
SELECT DISTINCT + + 32 + col2 AS col2 FROM tab1 AS cor0
----
128
86
89

query I rowsort
SELECT DISTINCT - + cor0.col2 * - 60 AS col1 FROM tab0 AS cor0
----
1980
4920
60

query I rowsort
SELECT ALL 42 + - col0 + cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1286
-1365
-592

query I rowsort
SELECT + col2 + tab2.col0 * - 50 AS col0 FROM tab2
----
-323
-3874
-3912

query I rowsort
SELECT col1 * + ( - ( - col0 ) * col0 ) + - col1 AS col0 FROM tab0
----
118728
49450
720720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 - tab2.col2 col2 FROM tab2
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-260
SELECT ALL col1 * 45 DIV col0 FROM tab0
----
124
161
46

skipif mysql # not compatible
query I rowsort label-260
SELECT ALL col1 * 45 / col0 FROM tab0
----
124
161
46

query I rowsort
SELECT DISTINCT - + 39 * - col0 FROM tab1 AS cor0
----
117
2496
3120

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

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

skipif mysql # not compatible
query I rowsort label-263
SELECT + - 23 / col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col1 * - 88 FROM tab1 AS cor0
----
1144
2288
880

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col2 + + 88 * col2 col1 FROM tab1 AS cor0
----
4698
4959
8352

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

query I rowsort
SELECT + col0 + 47 * col1 FROM tab0 AS cor0
----
4066
4366
4594

query I rowsort
SELECT ALL + col2 * - cor0.col0 + 28 FROM tab1 AS cor0
----
-134
-3620
-7652

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 col2 FROM tab0, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-274
SELECT DISTINCT + col2 DIV ( ( - col0 ) * 4 ) + col0 AS col0 FROM tab1 AS cor0
----
-1
64
80

skipif mysql # not compatible
query I rowsort label-274
SELECT DISTINCT + col2 / ( ( - col0 ) * 4 ) + col0 AS col0 FROM tab1 AS cor0
----
-1
64
80

query I rowsort
SELECT ALL cor0.col2 * - 70 - col0 AS col0 FROM tab1 AS cor0
----
-3783
-4054
-6800

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

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

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

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

query I rowsort
SELECT + 16 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT + - col1 + - 87 AS col0 FROM tab2 AS cor0
----
-104
-118
-146

query I rowsort
SELECT col2 * + 95 + + col0 FROM tab1 AS cor0
----
5133
5479
9200

query I rowsort
SELECT col2 * col2 + - 95 FROM tab2 AS cor0
----
1349
581
634

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

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

skipif mysql # not compatible
query I rowsort label-284
SELECT DISTINCT - col0 + - col1 / col0 FROM tab1 AS cor0
----
-11
-64
-80

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

skipif mysql # not compatible
query I rowsort label-285
SELECT - col2 * 57 + col2 * + CAST ( cor0.col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-56
-792
2050

query I rowsort
SELECT + + 29 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

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

query I rowsort
SELECT DISTINCT 85 * cor0.col2 AS col2 FROM tab2, tab1 AS cor0
----
4590
4845
8160

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

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

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

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

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

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

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

query I rowsort
SELECT - col0 - + ( 60 ) * + col2 FROM tab1 AS cor0
----
-3243
-3484
-5840

query I rowsort
SELECT + col1 + col1 * - 1 * col1 AS col2 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT + col1 * ( 94 ) FROM tab1 cor0
----
1222
2444
940

query I rowsort
SELECT ALL + col2 * col1 * - ( - col2 + - tab2.col2 ) FROM tab2
----
45198
49096
79768

query I rowsort
SELECT ALL col0 + tab2.col1 AS col2 FROM tab2
----
137
38
96

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

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

query I rowsort
SELECT ALL tab0.col1 * tab0.col2 AS col0 FROM tab0
----
2838
7462
97

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

query I rowsort
SELECT - 16 + col2 * 92 * 43 AS col2 FROM tab0 cor0
----
130532
324376
3940

query I rowsort
SELECT - + 83 * + col1 FROM tab2 AS cor0
----
-1411
-2573
-4897

query I rowsort
SELECT col2 + col2 * + 66 FROM tab2 AS cor0
----
1742
1809
2546

query I rowsort
SELECT DISTINCT + - col2 + - col2 * - col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + 85 col1 FROM tab1 AS cor0
----
59
72
75

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

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

query I rowsort
SELECT + cor0.col0 * + ( + col2 * + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
233472
486
614400

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

skipif mysql # not compatible
query I rowsort label-311
SELECT ALL col0 / CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT ALL + col2 * + ( 64 ) AS col0 FROM tab1 cor0
----
3456
3648
6144

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

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

skipif mysql # not compatible
query I rowsort label-315
SELECT ALL + col2 * + ( - col1 ) / col1 FROM tab2 cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 24 col2 FROM tab2, tab0 cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT - col1 * + 58 + - col0 * + col1 + + col1 FROM tab0 cor0
----
-13286
-6966
-8924

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

query I rowsort
SELECT ( 44 ) AS col0 FROM tab2 AS cor0
----
44
44
44

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - CAST ( - col0 AS REAL ) * + col0 + col0 AS col0 FROM tab2 AS cor0
----
56
6162
6320

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

query I rowsort
SELECT 57 * - 24 + cor0.col0 FROM tab2 cor0
----
-1289
-1290
-1361

query I rowsort
SELECT ALL + 10 + col1 * cor0.col0 AS col0 FROM tab2 AS cor0
----
1353
227
4612

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

query I rowsort
SELECT DISTINCT - 7 * - col2 AS col2 FROM tab2 AS cor0
----
182
189
266

query I rowsort
SELECT DISTINCT + 98 * + col2 AS col1 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT DISTINCT - - 6 * col1 AS col1 FROM tab0 AS cor0
----
516
546
582

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

query I rowsort
SELECT DISTINCT col1 + + 47 AS col2 FROM tab1
----
57
60
73

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

query I rowsort
SELECT ALL - 11 * + col0 + + col2 * ( - col2 ) AS col2 FROM tab1 AS cor0
----
-10096
-2949
-3953

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

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

query I rowsort
SELECT cor0.col2 * - col2 + - cor0.col1 + - col0 AS col0 FROM tab1 AS cor0
----
-2945
-3323
-9309

query I rowsort
SELECT DISTINCT col1 * - col1 + col1 FROM tab2 AS cor0
----
-272
-3422
-930

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-337
SELECT - 93 DIV - col2 + - 87 + col0 FROM tab1 AS cor0
----
-22
-7
-83

skipif mysql # not compatible
query I rowsort label-337
SELECT - 93 / - col2 + - 87 + col0 FROM tab1 AS cor0
----
-22
-7
-83

query I rowsort
SELECT ALL + tab2.col0 * + tab2.col0 + - 17 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to adcec5606a9a2f800c6b69d0fc3dba5c

query I rowsort
SELECT ALL + 95 AS col0 FROM tab1
----
95
95
95

query I rowsort
SELECT + 89 * col2 FROM tab0
----
2937
7298
89

query I rowsort
SELECT + 33 + col1 FROM tab1
----
43
46
59

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

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

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

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

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

query I rowsort
SELECT ALL + - 87 + col0 FROM tab1 AS cor0
----
-23
-7
-84

query I rowsort
SELECT ( + col0 ) * col1 - + ( col2 ) * + col2 FROM tab0 cor0
----
1375
3394
975

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-349
SELECT - col0 DIV 39 + col1 * 44 DIV col2 AS col2 FROM tab1 AS cor0
----
21
3
6

skipif mysql # not compatible
query I rowsort label-349
SELECT - col0 / 39 + col1 * 44 / col2 AS col2 FROM tab1 AS cor0
----
21
3
6

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

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

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

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

query I rowsort
SELECT - col1 + + col1 * col1 + + col2 FROM tab0
----
7343
8272
9313

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

query I rowsort
SELECT ALL + + 78 + 69 FROM tab1 AS cor0
----
147
147
147

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

query I rowsort
SELECT col2 + 26 FROM tab2
----
52
53
64

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-358
SELECT DISTINCT - CAST( - col1 AS SIGNED ) + col1 - - 11 * col1 AS col0 FROM tab1 cor0
----
130
169
338

skipif mysql # not compatible
query I rowsort label-358
SELECT DISTINCT - CAST ( - col1 AS INTEGER ) + col1 - - 11 * col1 AS col0 FROM tab1 cor0
----
130
169
338

query I rowsort
SELECT + col2 * + 69 + col0 FROM tab2 cor0
----
1870
1872
2701

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

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

query I rowsort
SELECT ALL ( - col1 ) * + col1 + + col1 * 62 + + col0 * 19 * - col0 FROM tab2 cor0
----
-115419
-117814
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-363
SELECT ALL + 2 * col0 + col0 DIV - 49 AS col0 FROM tab1 AS cor0
----
127
159
6

skipif mysql # not compatible
query I rowsort label-363
SELECT ALL + 2 * col0 + col0 / - 49 AS col0 FROM tab1 AS cor0
----
127
159
6

query I rowsort
SELECT ALL + col0 * 4 FROM tab0 AS cor0
----
140
356
96

query I rowsort
SELECT ALL - cor0.col2 + 46 * col0 AS col2 FROM tab2 AS cor0
----
295
3562
3596

query I rowsort
SELECT ALL - 78 + - col2 - col1 AS col2 FROM tab2 AS cor0
----
-133
-136
-163

query I rowsort
SELECT ALL - col0 * + col0 + col1 + + col1 FROM tab1 AS cor0
----
-4076
-6374
43

query I rowsort
SELECT DISTINCT + col0 * 72 AS col0 FROM tab1 cor0
----
216
4608
5760

onlyif mysql # use DIV operator for integer division
query I rowsort label-369
SELECT ALL - col0 + col0 DIV - col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-369
SELECT ALL - col0 + col0 / - col0 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT ALL 87 AS col1 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT + tab0.col0 * ( 55 * col1 ) FROM tab0
----
113520
186725
445445

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

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

query I rowsort
SELECT col0 * 44 FROM tab0 AS cor0
----
1056
1540
3916

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

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

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

skipif mysql # not compatible
query I rowsort label-376
SELECT col0 * CAST ( + col2 AS INTEGER ) + - col0 FROM tab2 cor0
----
182
1950
2923

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

query I rowsort
SELECT DISTINCT col0 * - 5 AS col2 FROM tab1 cor0
----
-15
-320
-400

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

query I rowsort
SELECT + cor0.col0 * 60 FROM tab0 AS cor0
----
1440
2100
5340

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-381
SELECT + + CAST ( NULL AS REAL ) col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + + 54 AS col1 FROM tab0
----
136
55
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-383
SELECT col1 + cor0.col1 DIV 34 AS col1 FROM tab2 AS cor0
----
17
31
60

skipif mysql # not compatible
query I rowsort label-383
SELECT col1 + cor0.col1 / 34 AS col1 FROM tab2 AS cor0
----
17
31
60

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

query I rowsort
SELECT ALL - 71 * col1 AS col1 FROM tab2 AS cor0
----
-1207
-2201
-4189

query I rowsort
SELECT - col2 + + col2 * + 32 FROM tab0 AS cor0
----
1023
2542
31

query I rowsort
SELECT ALL + col2 * - col1 * + 60 AS col2 FROM tab0 AS cor0
----
-170280
-447720
-5820

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

skipif mysql # not compatible
query I rowsort label-388
SELECT 26 / col2 + col2 * + col1 FROM tab0 AS cor0
----
123
2838
7462

query I rowsort
SELECT - - 24 + - col0 * col1 AS col1 FROM tab2 AS cor0
----
-1319
-193
-4578

query I rowsort
SELECT ALL - 77 + + col2 AS col0 FROM tab2 AS cor0
----
-39
-50
-51

query I rowsort
SELECT tab1.col1 * + col1 + col2 * 62 + + col2 * tab1.col2 AS col2 FROM tab1
----
15337
6883
6940

query I rowsort
SELECT + 62 * - col2 + col2 - col1 AS col1 FROM tab2
----
-1645
-1678
-2335

query I rowsort
SELECT - col0 - + col2 * col1 * + 13 AS col0 FROM tab1 AS cor0
----
-16304
-18255
-7474

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

query I rowsort
SELECT + 35 * + 75 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 0b6e8e9efbea9f9aa681616c091ff8aa

query I rowsort
SELECT DISTINCT + 57 + col1 AS col0 FROM tab0
----
143
148
154

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-397
SELECT DISTINCT + cor0.col1 * CAST( - 42 AS SIGNED ) AS col1 FROM tab2, tab2 AS cor0
----
-1302
-2478
-714

skipif mysql # not compatible
query I rowsort label-397
SELECT DISTINCT + cor0.col1 * CAST ( - 42 AS INTEGER ) AS col1 FROM tab2, tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT DISTINCT + cor0.col2 * - ( - col2 ) * - col0 AS col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT ALL - col2 + + 81 AS col0 FROM tab2 AS cor0
----
43
54
55

query I rowsort
SELECT ALL + col1 + - ( - col0 ) + cor0.col0 * - col2 AS col2 FROM tab1 AS cor0
----
-133
-3574
-7587

query I rowsort
SELECT DISTINCT - cor0.col0 * ( - 73 ) * + col0 + - col1 AS col1 FROM tab1 cor0
----
298998
467187
631

query I rowsort
SELECT + col1 + 28 FROM tab1 AS cor0
----
38
41
54

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

skipif mysql # not compatible
query I rowsort label-403
SELECT col1 + + CAST ( col2 AS INTEGER ) + col1 AS col0 FROM tab2 AS cor0
----
144
72
89

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-405
SELECT ALL 43 * col0 + ( 53 * col0 + - CAST( - col0 AS SIGNED ) ) AS col1 FROM tab1
----
291
6208
7760

skipif mysql # not compatible
query I rowsort label-405
SELECT ALL 43 * col0 + ( 53 * col0 + - CAST ( - col0 AS INTEGER ) ) AS col1 FROM tab1
----
291
6208
7760

query I rowsort
SELECT + 42 * - tab2.col0 FROM tab2
----
-294
-3276
-3318

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-409
SELECT DISTINCT 77 DIV - tab0.col1 AS col1 FROM tab0, tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-409
SELECT DISTINCT 77 / - tab0.col1 AS col1 FROM tab0, tab0 cor0
----
0

query I rowsort
SELECT - col0 + - 49 FROM tab2 cor0
----
-127
-128
-56

query I rowsort
SELECT col2 * col1 - col1 * col1 * + col0 FROM tab1
----
-12272
-5830
-624

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

query I rowsort
SELECT ALL + 44 + + 14 * col2 FROM tab1 cor0
----
1388
800
842

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

query I rowsort
SELECT ( 30 ) FROM tab1 AS cor0
----
30
30
30

query I rowsort
SELECT 81 + + col1 AS col1 FROM tab1 AS cor0
----
107
91
94

query I rowsort
SELECT ALL + - ( + 43 ) FROM tab0 cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT DISTINCT - - 16 + 82 + + col2 FROM tab1 AS cor0
----
152
155
194

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-421
SELECT col2 DIV col1 - - col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-421
SELECT col2 / col1 - - col0 FROM tab0
----
24
35
89

query I rowsort
SELECT - col1 * - 30 FROM tab1 AS cor0
----
300
390
780

skipif mysql # not compatible
query I rowsort
SELECT 48 * col0 + + col2 * CAST ( col0 AS REAL ) * col2 FROM tab0
----
1715
27288
602708

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

query I rowsort
SELECT DISTINCT 12 + col2 FROM tab1 cor0
----
108
66
69

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-427
SELECT DISTINCT + - CAST( 6 AS SIGNED ) + col2 FROM tab1 cor0
----
48
51
90

skipif mysql # not compatible
query I rowsort label-427
SELECT DISTINCT + - CAST ( 6 AS INTEGER ) + col2 FROM tab1 cor0
----
48
51
90

query I rowsort
SELECT 75 * + col2 FROM tab0
----
2475
6150
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-429
SELECT + col0 DIV col1 + + 40 FROM tab2 AS cor0
----
40
41
44

skipif mysql # not compatible
query I rowsort label-429
SELECT + col0 / col1 + + 40 FROM tab2 AS cor0
----
40
41
44

query I rowsort
SELECT - + 55 * + col2 * + ( - col2 ) + + cor0.col0 FROM tab1 AS cor0
----
160383
178759
506960

query I rowsort
SELECT + - cor0.col0 + - col2 * 23 FROM tab1 AS cor0
----
-1245
-1375
-2288

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

query I rowsort
SELECT - col2 + 0 AS col0 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT - - col2 * col2 * - 26 AS col0 FROM tab2 AS cor0
----
-17576
-18954
-37544

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

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

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

query I rowsort
SELECT - col1 * col1 + col0 * + col2 * col1 AS col2 FROM tab1 AS cor0
----
3536
36380
99671

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-439
SELECT - col0 + CAST ( col2 * col2 AS INTEGER ) col1 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT DISTINCT + col1 * - 96 + col1 * col2 * ( 43 ) AS col0 FROM tab2 AS cor0
----
26146
33015
60298

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

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

query I rowsort
SELECT + - col0 * 40 + - col0 FROM tab2 AS cor0
----
-287
-3198
-3239

query I rowsort
SELECT DISTINCT + + cor0.col2 * 3 FROM tab2 cor0
----
114
78
81

query I rowsort
SELECT - col2 - - 91 AS col2 FROM tab1 cor0
----
-5
34
37

query I rowsort
SELECT DISTINCT - - cor0.col0 + + col0 * 9 FROM tab1 AS cor0
----
30
640
800

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

query I rowsort
SELECT ALL - col1 + - 47 AS col0 FROM tab2 cor0
----
-106
-64
-78

query I rowsort
SELECT + + col1 * ( + col0 ) + cor0.col1 FROM tab1 AS cor0
----
104
1053
650

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-452
SELECT DISTINCT ( 7 ) DIV col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-452
SELECT DISTINCT ( 7 ) / col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - ( + 64 ) + col2 * col0 AS col2 FROM tab2 AS cor0
----
125
1964
2938

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

query I rowsort
SELECT DISTINCT + - ( 65 ) AS col1 FROM tab2 AS cor0
----
-65

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

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

query I rowsort
SELECT + 47 * 14 * col0 FROM tab0 AS cor0
----
15792
23030
58562

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

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

query I rowsort
SELECT col2 + 53 * col2 FROM tab1
----
2916
3078
5184

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

query I rowsort
SELECT DISTINCT col0 + + ( - tab1.col1 ) AS col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL + col0 * - tab2.col1 + - col1 + col1 * ( - col0 * col1 ) FROM tab2
----
-24191
-276179
-6975

query I rowsort
SELECT 7 + + 62 FROM tab2, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

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

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 + - col1 + col2 AS col2 FROM tab2 cor0
----
-268
-3514
-965

query I rowsort
SELECT ALL - col2 * + col1 + 55 AS col1 FROM tab0 AS cor0
----
-2783
-42
-7407

query I rowsort
SELECT + 87 * col2 AS col0 FROM tab2 cor0
----
2262
2349
3306

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

query I rowsort
SELECT ALL + 15 + + col1 * col2 FROM tab2 AS cor0
----
1549
661
852

query I rowsort
SELECT ALL + cor0.col2 + col0 * + cor0.col0 * + ( cor0.col1 ) FROM tab1 AS cor0
----
288
41017
83296

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

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

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

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

query I rowsort
SELECT 36 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 81 * - col1 - 44 col2 FROM tab2
----
-1421
-2555
-4823

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

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

query I rowsort
SELECT cor0.col2 + col0 * 71 * col2 AS col2 FROM tab1 cor0
----
11556
259065
545376

query I rowsort
SELECT DISTINCT + 62 * + col1 AS col2 FROM tab0 cor0
----
5332
5642
6014

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 65 - col0 col0 FROM tab2 AS cor0
----
-143
-144
-72

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

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

query I rowsort
SELECT DISTINCT + + 0 * + 62 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
0

query I rowsort
SELECT ALL 86 - - tab2.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 10f8a310055ad2224566464d08440af6

query I rowsort
SELECT DISTINCT - 44 * 44 AS col1 FROM tab1, tab2, tab0 cor0
----
-1936

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

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

query I rowsort
SELECT ALL + + ( col1 ) * col2 + 82 - - col0 * col1 FROM tab2 AS cor0
----
1136
2071
6218

query I rowsort
SELECT + - 60 + - col1 AS col0 FROM tab0 AS cor0
----
-146
-151
-157

query I rowsort
SELECT ALL - ( 47 ) * - col1 + - 25 AS col1 FROM tab2 AS cor0
----
1432
2748
774

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 6 + col1 * + ( - 52 + - col2 ) col0 FROM tab1 AS cor0
----
-1096
-1930
-2762

onlyif mysql # use DIV operator for integer division
query I rowsort label-493
SELECT ALL - 90 + - cor0.col1 DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
-91
-92
-93

skipif mysql # not compatible
query I rowsort label-493
SELECT ALL - 90 + - cor0.col1 / cor0.col0 AS col1 FROM tab0 AS cor0
----
-91
-92
-93

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

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

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

query I rowsort
SELECT + 76 * col2 AS col1 FROM tab0 AS cor0
----
2508
6232
76

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-499
SELECT - - col0 * 60 DIV col0 AS col0 FROM tab1 AS cor0
----
60
60
60

skipif mysql # not compatible
query I rowsort label-499
SELECT - - col0 * 60 / col0 AS col0 FROM tab1 AS cor0
----
60
60
60

query I rowsort
SELECT ALL col2 * - cor0.col1 * + col1 FROM tab1 cor0
----
-16224
-36504
-5700

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-502
SELECT - - col0 * 35 DIV + col0 FROM tab1 AS cor0
----
35
35
35

skipif mysql # not compatible
query I rowsort label-502
SELECT - - col0 * 35 / + col0 FROM tab1 AS cor0
----
35
35
35

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-505
SELECT - - col0 DIV 19 FROM tab1 AS cor0
----
0
3
4

skipif mysql # not compatible
query I rowsort label-505
SELECT - - col0 / 19 FROM tab1 AS cor0
----
0
3
4

query I rowsort
SELECT + col1 * 9 FROM tab2 cor0
----
153
279
531

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

query I rowsort
SELECT DISTINCT - col2 * + ( 8 ) * - col2 FROM tab0 AS cor0
----
53792
8
8712

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-510
SELECT col2 * col2 DIV + cor0.col1 AS col1 FROM tab1 AS cor0
----
112
324
708

skipif mysql # not compatible
query I rowsort label-510
SELECT col2 * col2 / + cor0.col1 AS col1 FROM tab1 AS cor0
----
112
324
708

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

query I rowsort
SELECT + col1 * 23 + col1 - - col0 FROM tab0 AS cor0
----
2088
2273
2363

query I rowsort
SELECT ( col1 ) + + cor0.col2 * + 75 FROM tab0 AS cor0
----
172
2561
6241

query I rowsort
SELECT + col0 + col2 * + col1 * 64 FROM tab1 AS cor0
----
36544
79952
89859

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

query I rowsort
SELECT ALL - 79 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

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

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

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

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

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

query I rowsort
SELECT + 98 * col1 FROM tab2 AS cor0
----
1666
3038
5782

query I rowsort
SELECT col2 + + 49 * - 67 AS col2 FROM tab2
----
-3245
-3256
-3257

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

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

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

skipif mysql # not compatible
query I rowsort label-524
SELECT CAST ( 88 AS INTEGER ) AS col2 FROM tab2 cor0
----
88
88
88

query I rowsort
SELECT + ( - 70 ) + + col1 AS col2 FROM tab2 cor0
----
-11
-39
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-526
SELECT + 48 * col1 DIV - col0 AS col2 FROM tab2
----
-10
-212
-36

skipif mysql # not compatible
query I rowsort label-526
SELECT + 48 * col1 / - col0 AS col2 FROM tab2
----
-10
-212
-36

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

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

skipif mysql # not compatible
query I rowsort label-528
SELECT DISTINCT - col2 + col2 / ( + col1 ) AS col1 FROM tab2 cor0
----
-26
-27
-36

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

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

skipif mysql # not compatible
query I rowsort label-530
SELECT DISTINCT CAST ( 16 AS INTEGER ) FROM tab2, tab0 AS cor0
----
16

skipif mysql # not compatible
query I rowsort
SELECT CAST ( cor0.col2 AS REAL ) FROM tab0, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL col2 * 36 * col0 AS col2 FROM tab0 AS cor0
----
1260
262728
28512

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 64 * + col1 col0 FROM tab2 AS cor0
----
1088
1984
3776

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

query I rowsort
SELECT 35 + + col1 AS col1 FROM tab1 AS cor0
----
45
48
61

query I rowsort
SELECT ALL 85 + cor0.col1 FROM tab0 cor0
----
171
176
182

query I rowsort
SELECT - ( cor0.col0 ) * - cor0.col2 + col2 * + col0 + ( + col1 * + col0 + + col1 * - col1 ) FROM tab2 AS cor0
----
-366
5177
7058

query I rowsort
SELECT - col2 * col1 + col2 + cor0.col2 AS col0 FROM tab0 AS cor0
----
-2772
-7298
-95

query I rowsort
SELECT ALL 4 + - cor0.col0 FROM tab2 AS cor0
----
-3
-74
-75

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

query I rowsort
SELECT + 22 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 77 ) * - col0 col2 FROM tab2
----
539
6006
6083

query I rowsort
SELECT col2 * 20 AS col0 FROM tab1
----
1080
1140
1920

query I rowsort
SELECT ALL + 79 * cor0.col0 FROM tab1 cor0
----
237
5056
6320

query I rowsort
SELECT + - 28 + + col1 FROM tab1 AS cor0
----
-15
-18
-2

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

query I rowsort
SELECT - 31 - cor0.col0 FROM tab0 AS cor0
----
-120
-55
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-550
SELECT tab2.col1 DIV + ( col1 ) FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-550
SELECT tab2.col1 / + ( col1 ) FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-551
SELECT DISTINCT + col2 DIV + col0 + 56 FROM tab2
----
56
59

skipif mysql # not compatible
query I rowsort label-551
SELECT DISTINCT + col2 / + col0 + 56 FROM tab2
----
56
59

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

query I rowsort
SELECT ALL - col1 + + 31 * col0 AS col0 FROM tab2 AS cor0
----
186
2359
2432

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

query I rowsort
SELECT ALL col1 * - col2 + col0 * + 34 AS col1 FROM tab0 AS cor0
----
-2022
-4436
1093

query I rowsort
SELECT ALL - col1 * - col1 * cor0.col0 + - 56 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
23783
274822
8463

query I rowsort
SELECT DISTINCT col1 + 84 * col2 * + col2 FROM tab1
----
244970
272926
774157

query I rowsort
SELECT ( col0 ) + - col1 + + ( col1 ) * + col1 FROM tab2
----
3500
351
937

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

query I rowsort
SELECT col2 + + col2 - - col1 FROM tab0
----
152
255
99

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

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

query I rowsort
SELECT ALL - 9 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 3dfe689e16ce3a87877d40f349e6c7b5

query I rowsort
SELECT DISTINCT - ( - col2 ) * + col1 + 7 AS col0 FROM tab2 AS cor0
----
1541
653
844

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

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

query I rowsort
SELECT ALL - 76 + cor0.col1 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to e3d09fb155f65751bb2891b9c56803d2

query I rowsort
SELECT 6 + - 17 FROM tab2 AS cor0
----
-11
-11
-11

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

query I rowsort
SELECT DISTINCT ( 6 ) * + tab2.col2 + col2 FROM tab2
----
182
189
266

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

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

query I rowsort
SELECT DISTINCT - - 80 + col0 FROM tab1 cor0
----
144
160
83

query I rowsort
SELECT 78 + cor0.col2 FROM tab2 AS cor0
----
104
105
116

query I rowsort
SELECT + 71 AS col2 FROM tab1 cor0
----
71
71
71

query I rowsort
SELECT ALL 72 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-576
SELECT DISTINCT - 38 + - col2 * + CAST( - ( + col2 ) + + col1 AS SIGNED ) col0 FROM tab0 AS cor0
----
-134
-1787
-776

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-576
SELECT DISTINCT - 38 + - col2 * + CAST ( - ( + col2 ) + + col1 AS INTEGER ) col0 FROM tab0 AS cor0
----
-134
-1787
-776

query I rowsort
SELECT DISTINCT + cor0.col2 + + col2 + - col1 * + col1 AS col1 FROM tab1 AS cor0
----
-568
14
23

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

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

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

query I rowsort
SELECT 29 * - tab1.col2 FROM tab1
----
-1566
-1653
-2784

onlyif mysql # use DIV operator for integer division
query I rowsort label-581
SELECT + + 87 + col2 DIV col2 AS col1 FROM tab1 AS cor0
----
88
88
88

skipif mysql # not compatible
query I rowsort label-581
SELECT + + 87 + col2 / col2 AS col1 FROM tab1 AS cor0
----
88
88
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-582
SELECT - + col0 DIV col0 + + cor0.col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1249
-1405
-571

skipif mysql # not compatible
query I rowsort label-582
SELECT - + col0 / col0 + + cor0.col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1249
-1405
-571

query I rowsort
SELECT - 68 - + col2 AS col2 FROM tab2 AS cor0
----
-106
-94
-95

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

skipif mysql # not compatible
query I rowsort label-584
SELECT ALL + + col2 * - cor0.col1 * CAST ( - col0 * col2 AS INTEGER ) + - col2 * col1 + + col0 FROM tab2 AS cor0
----
157363
1938725
3109496

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

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

query I rowsort
SELECT ALL cor0.col0 + col2 - col1 * + col0 AS col1 FROM tab2 AS cor0
----
-1226
-183
-4498

query I rowsort
SELECT DISTINCT + col0 - col1 * + col1 * + 46 FROM tab1 AS cor0
----
-31093
-4536
-7694

query I rowsort
SELECT + - cor0.col2 * col1 - + col2 * 22 AS col0 FROM tab2 AS cor0
----
-1431
-1482
-2106

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

query I rowsort
SELECT col0 * - 40 + col0 AS col1 FROM tab1
----
-117
-2496
-3120

query I rowsort
SELECT + + col1 * + 71 AS col1 FROM tab0 AS cor0
----
6106
6461
6887

query I rowsort
SELECT DISTINCT + 10 * - cor0.col2 AS col1 FROM tab0, tab1 AS cor0
----
-540
-570
-960

query I rowsort
SELECT + ( - cor0.col2 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT + - col0 * - 95 AS col2 FROM tab0 AS cor0
----
2280
3325
8455

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

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

skipif mysql # not compatible
query I rowsort label-596
SELECT ALL - - col1 / + 13 AS col2 FROM tab1 AS cor0
----
0
1
2

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

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

query I rowsort
SELECT DISTINCT - + col0 + col2 * - col0 * - col0 AS col2 FROM tab0 AS cor0
----
1190
18984
649433

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

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

query I rowsort
SELECT DISTINCT col1 + 73 FROM tab0 AS cor0
----
159
164
170

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

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

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

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

query I rowsort
SELECT ALL - col0 * col2 * col0 + - col0 * - col1 FROM tab1 cor0
----
-232832
-408
-613360

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

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-614
SELECT col2 DIV + col0 + col2 + + tab1.col2 * - 78 col2 FROM tab1
----
-4140
-4389
-7391

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-614
SELECT col2 / + col0 + col2 + + tab1.col2 * - 78 col2 FROM tab1
----
-4140
-4389
-7391

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

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

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

query I rowsort
SELECT + ( 12 ) FROM tab0, tab2 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT + 72 * tab0.col2 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 0cbe31ebe383d21e113aa6fe38f9b384

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

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

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

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

query I rowsort
SELECT - ( - col1 ) * + col1 + tab2.col2 FROM tab2
----
327
3507
988

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

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

query I rowsort
SELECT DISTINCT + 44 + col2 * - col0 FROM tab2 AS cor0
----
-145
-1984
-2958

query I rowsort
SELECT - - 95 * + col1 AS col0 FROM tab1 AS cor0
----
1235
2470
950

query I rowsort
SELECT - - 94 * col0 FROM tab0 AS cor0
----
2256
3290
8366

query I rowsort
SELECT ALL col2 + - col0 * - 91 AS col0 FROM tab0 cor0
----
2217
3186
8181

query I rowsort
SELECT 0 * - cor0.col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-630
SELECT DISTINCT - col1 DIV col2 + col0 * 84 AS col0 FROM tab0 AS cor0
----
2014
2843
7475

skipif mysql # not compatible
query I rowsort label-630
SELECT DISTINCT - col1 / col2 + col0 * 84 AS col0 FROM tab0 AS cor0
----
2014
2843
7475

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

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

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

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

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

query I rowsort
SELECT DISTINCT col2 * 28 AS col0 FROM tab0 cor0
----
2296
28
924

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

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

query I rowsort
SELECT ALL - - col0 + ( + ( col2 ) + 64 ) FROM tab1 AS cor0
----
121
185
240

query I rowsort
SELECT ALL + - col1 + - ( + 14 ) * col1 FROM tab1 AS cor0
----
-150
-195
-390

query I rowsort
SELECT col2 + 32 FROM tab2 AS cor0
----
58
59
70

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-641
SELECT - col0 + 90 / col2 col1 FROM tab0 AS cor0
----
-22
-88
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * cor0.col0 * col0 col1 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT + + 36 * + col1 + + col0 AS col2 FROM tab1 AS cor0
----
424
548
939

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

query I rowsort
SELECT - 63 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
-28
-39
26

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

skipif mysql # not compatible
query I rowsort label-646
SELECT CAST ( cor0.col0 AS INTEGER ) + - col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-648
SELECT - + 4 DIV + ( - col0 ) + - cor0.col1 AS col0 FROM tab1 cor0
----
-10
-13
-25

skipif mysql # not compatible
query I rowsort label-648
SELECT - + 4 / + ( - col0 ) + - cor0.col1 AS col0 FROM tab1 cor0
----
-10
-13
-25

onlyif mysql # use DIV operator for integer division
query I rowsort label-649
SELECT + 93 DIV 14 col2 FROM tab0 AS cor0
----
6
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-649
SELECT + 93 / 14 col2 FROM tab0 AS cor0
----
6
6
6

query I rowsort
SELECT + 33 + col2 AS col0 FROM tab0 AS cor0
----
115
34
66

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

query I rowsort
SELECT + 42 * col0 AS col1 FROM tab0 AS cor0
----
1008
1470
3738

query I rowsort
SELECT 27 * - tab2.col2 FROM tab2
----
-1026
-702
-729

query I rowsort
SELECT ALL tab2.col0 * col1 * col1 - tab2.col2 FROM tab2 WHERE NOT col0 + col0 < + col0
----
22793
271492
6700

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

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

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL > ( col0 - - col1 * + col0 / col1 )
----

query I rowsort
SELECT col0 + - col0 AS col0 FROM tab0 WHERE NOT NULL = NULL
----

query I rowsort
SELECT ALL - col1 * col1 - + col0 FROM tab1
----
-164
-249
-679

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

query I rowsort
SELECT DISTINCT + 8 * col1 AS col2 FROM tab1 AS cor0
----
104
208
80

query I rowsort
SELECT + + 61 * col1 FROM tab1 AS cor0
----
1586
610
793

query I rowsort
SELECT ALL - - col0 - col1 * - col1 AS col1 FROM tab1 cor0
----
164
249
679

query I rowsort
SELECT + + 56 + - col2 * col2 FROM tab2 AS cor0
----
-1388
-620
-673

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

query I rowsort
SELECT ALL + col1 * col2 * - col0 + + col0 - + col1 FROM tab1
----
-36426
-4235
-99773

onlyif mysql # use DIV operator for integer division
query I rowsort label-668
SELECT - col1 * - col0 - col0 DIV col1 FROM tab2
----
1339
217
4601

skipif mysql # not compatible
query I rowsort label-668
SELECT - col1 * - col0 - col0 / col1 FROM tab2
----
1339
217
4601

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-674
SELECT DISTINCT - col1 / col1 AS col2 FROM tab2
----
-1

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

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

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

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

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

query I rowsort
SELECT - col2 + + col1 + + tab0.col1 * col2 FROM tab0
----
193
2891
7471

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col1 / + col0 >= col1
----

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

query III rowsort
SELECT * FROM tab2 WHERE col1 * col0 <> NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NULL <= + col2 / + col2
----

query III rowsort
SELECT * FROM tab0 WHERE NOT ( col0 ) >= NULL
----

query I rowsort
SELECT col0 + - col1 + - tab0.col0 * + col2 FROM tab0
----
-7300
-854
-97

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

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

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

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

query I rowsort
SELECT DISTINCT + 85 AS col2 FROM tab0 AS cor0
----
85

query I rowsort
SELECT 91 * ( col2 ) AS col2 FROM tab1 AS cor0
----
4914
5187
8736

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

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

query I rowsort
SELECT - 42 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 56f86ff01cd96a3511acd46e0e811e27

onlyif mysql # use DIV operator for integer division
query I rowsort label-695
SELECT DISTINCT - - 76 DIV + 76 FROM tab2, tab1, tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-695
SELECT DISTINCT - - 76 / + 76 FROM tab2, tab1, tab0 AS cor0
----
1

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-699
SELECT DISTINCT - CAST( col2 AS SIGNED ) * + col0 + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

skipif mysql # not compatible
query I rowsort label-699
SELECT DISTINCT - CAST ( col2 AS INTEGER ) * + col0 + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - 76 * 97 AS col0 FROM tab0 cor0
----
-7372
-7372
-7372

onlyif mysql # use DIV operator for integer division
query I rowsort label-701
SELECT col2 DIV + col0 + - tab2.col0 * col1 * col0 FROM tab2
----
-106097
-1516
-358956

skipif mysql # not compatible
query I rowsort label-701
SELECT col2 / + col0 + - tab2.col0 * col1 * col0 FROM tab2
----
-106097
-1516
-358956

query I rowsort
SELECT ALL + col1 + - col1 * + 11 AS col2 FROM tab0
----
-860
-910
-970

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-704
SELECT ALL ( col2 ) DIV + col1 - - col2 FROM tab1 cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-704
SELECT ALL ( col2 ) / + col1 - - col2 FROM tab1 cor0
----
103
56
62

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

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

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

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

query I rowsort
SELECT ALL - + col1 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-118
-34
-62

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

query I rowsort
SELECT - cor0.col0 + - cor0.col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL - col0 + + 25 + - cor0.col0 * - col0 FROM tab2 AS cor0
----
6031
6187
67

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * - 44 col2 FROM tab1 AS cor0
----
132
2816
3520

query I rowsort
SELECT ALL col1 + - col0 + cor0.col2 * + col0 * + ( ( col2 ) * + col1 + col1 ) FROM tab1 AS cor0
----
2115786
231683
9684413

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + 59 col0 FROM tab1 AS cor0
----
-3186
-3363
-5664

query I rowsort
SELECT - + cor0.col0 * cor0.col1 * - 23 AS col1 FROM tab1 cor0
----
14720
1794
23920

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

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

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

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

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

query I rowsort
SELECT ALL - + col1 * - col1 + - col2 * - col2 FROM tab1 AS cor0
----
3349
3592
9385

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

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

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

query I rowsort
SELECT col0 * 4 FROM tab1 AS cor0
----
12
256
320

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

query I rowsort
SELECT ALL 5 * + col2 AS col0 FROM tab2 AS cor0
----
130
135
190

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

query I rowsort
SELECT ( 72 ) * col1 + - col1 AS col1 FROM tab2 AS cor0
----
1207
2201
4189

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

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

query I rowsort
SELECT col1 + 78 FROM tab0
----
164
169
175

onlyif mysql # use DIV operator for integer division
query I rowsort label-733
SELECT - - col0 DIV - 23 FROM tab0 AS cor0
----
-1
-1
-3

skipif mysql # not compatible
query I rowsort label-733
SELECT - - col0 / - 23 FROM tab0 AS cor0
----
-1
-1
-3

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

query IIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0, tab2 AS cor0 WHERE NULL <> NULL
----

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

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

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

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

query I rowsort
SELECT DISTINCT col2 * - 42 AS col0 FROM tab2
----
-1092
-1134
-1596

query I rowsort
SELECT ALL - 46 * col0 AS col2 FROM tab2
----
-322
-3588
-3634

query I rowsort
SELECT + col0 * col0 * col2 + cor0.col0 * col1 AS col1 FROM tab0 AS cor0
----
21072
4620
657621

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

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT - + cor0.col0 * CAST ( 47 AS REAL ) FROM tab2 AS cor0
----
-329
-3666
-3713

query I rowsort
SELECT col1 * 36 * - col0 + col2 * + col2 + + cor0.col1 FROM tab2 AS cor0
----
-164937
-46887
-7052

query I rowsort
SELECT ALL - tab2.col2 + col2 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-748
SELECT ALL + col1 * col1 DIV col1 AS col2 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-748
SELECT ALL + col1 * col1 / col1 AS col2 FROM tab2
----
17
31
59

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

query I rowsort
SELECT 96 + + col2 + col0 AS col2 FROM tab0
----
132
153
267

query I rowsort
SELECT - col2 * col0 * 99 AS col1 FROM tab2
----
-18711
-200772
-297198

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

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

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

skipif mysql # not compatible
query I rowsort label-754
SELECT ALL + col2 / 19 FROM tab2
----
1
1
2

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-756
SELECT DISTINCT cor0.col0 DIV 44 col2 FROM tab0 AS cor0
----
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-756
SELECT DISTINCT cor0.col0 / 44 col2 FROM tab0 AS cor0
----
0
2

query I rowsort
SELECT col2 * col2 + - col2 * - col2 FROM tab2 AS cor0
----
1352
1458
2888

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

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

query I rowsort
SELECT ALL - cor0.col0 + - col0 AS col0 FROM tab2 AS cor0
----
-14
-156
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-761
SELECT + + col2 * + col0 + 52 DIV - col1 + col1 FROM tab0 AS cor0
----
132
7389
878

skipif mysql # not compatible
query I rowsort label-761
SELECT + + col2 * + col0 + 52 / - col1 + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT - - col0 + 82 FROM tab1 cor0
----
146
162
85

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col1 + + col1 col0 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT + tab2.col1 * col2 + - col1 * - col2 + col1 AS col0 FROM tab2
----
1309
1705
3127

query I rowsort
SELECT ALL col1 * + col2 + col1 * col2 AS col2 FROM tab0
----
14924
194
5676

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - col2 col2 FROM tab1
----
-28
-47
-83

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

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

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

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

query I rowsort
SELECT ALL 95 FROM tab0
----
95
95
95

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

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

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

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

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

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

query I rowsort
SELECT col1 * + cor0.col2 + + col0 - col0 * + col1 FROM tab0 AS cor0
----
-3263
-548
798

query I rowsort
SELECT ALL + 37 * + col0 FROM tab0 AS cor0
----
1295
3293
888

query I rowsort
SELECT + col1 * + col1 + 76 FROM tab1
----
176
245
752

query I rowsort
SELECT ALL - - col1 * col1 + col0 AS col0 FROM tab1 AS cor0
----
164
249
679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 + 97 col1 FROM tab1 AS cor0
----
151
154
193

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

skipif mysql # not compatible
query I rowsort label-786
SELECT ALL - col1 + - CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
-110
-132
-180

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-788
SELECT ALL col0 * CAST( - 4 AS SIGNED ) * - cor0.col2 AS col2 FROM tab0 cor0
----
140
29192
3168

skipif mysql # not compatible
query I rowsort label-788
SELECT ALL col0 * CAST ( - 4 AS INTEGER ) * - cor0.col2 AS col2 FROM tab0 cor0
----
140
29192
3168

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

query I rowsort
SELECT ALL cor0.col1 * - col0 - 85 * col0 FROM tab0 AS cor0
----
-15664
-4104
-6370

query I rowsort
SELECT ALL col1 - + 15 AS col0 FROM tab0 AS cor0
----
71
76
82

query I rowsort
SELECT col2 * ( col0 ) * col0 AS col1 FROM tab2 AS cor0
----
1323
158184
237158

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

skipif mysql # not compatible
query I rowsort label-793
SELECT DISTINCT + col2 + - 95 / cor0.col1 AS col0 FROM tab0 AS cor0
----
1
32
81

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-796
SELECT ALL col0 DIV - col1 - 76 * col0 * + ( + col2 + - col2 * - ( - cor0.col0 ) ) FROM tab2 AS cor0
----
11867855
17795852
86184

skipif mysql # not compatible
query I rowsort label-796
SELECT ALL col0 / - col1 - 76 * col0 * + ( + col2 + - col2 * - ( - cor0.col0 ) ) FROM tab2 AS cor0
----
11867855
17795852
86184

query I rowsort
SELECT + 84 + + col1 FROM tab1 AS cor0
----
110
94
97

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

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

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

query I rowsort
SELECT - 54 + col2 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
-2970
-3303
-9270

query I rowsort
SELECT DISTINCT + col1 + + 62 * - col0 AS col0 FROM tab2 AS cor0
----
-403
-4777
-4881

onlyif mysql # use DIV operator for integer division
query I rowsort label-803
SELECT + - cor0.col1 * + cor0.col2 + + col2 DIV col0 col1 FROM tab2 AS cor0
----
-1534
-646
-834

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-803
SELECT + - cor0.col1 * + cor0.col2 + + col2 / col0 col1 FROM tab2 AS cor0
----
-1534
-646
-834

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

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col0 AS REAL ) * - col0 + ( col0 ) / - col0 + + col0 FROM tab2 AS cor0
----
55
6161
6319

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 26 + col1 * + col1 col2 FROM tab1 AS cor0
----
143
650
74

query I rowsort
SELECT 56 + + cor0.col2 FROM tab2 AS cor0
----
82
83
94

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

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

query I rowsort
SELECT DISTINCT 29 FROM tab0 cor0
----
29

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

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

query I rowsort
SELECT ALL + - 25 * 72 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 4e7224d88eaaf0020415c6a0afbcbbd6

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

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

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 + col1 + col0 * - ( ( col1 ) ) + col1 AS col2 FROM tab0 AS cor0
----
-1892
-3201
-7917

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 9 col0 FROM tab2
----
16
87
88

query I rowsort
SELECT + col1 + col1 + cor0.col1 AS col0 FROM tab0 AS cor0
----
258
273
291

onlyif mysql # use DIV operator for integer division
query I rowsort label-820
SELECT col1 DIV col1 + - col0 + col0 * - col2 FROM tab0 AS cor0
----
-69
-7386
-815

skipif mysql # not compatible
query I rowsort label-820
SELECT col1 / col1 + - col0 + col0 * - col2 FROM tab0 AS cor0
----
-69
-7386
-815

query I rowsort
SELECT DISTINCT 16 AS col0 FROM tab0
----
16

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-824
SELECT - col1 - + col0 DIV col0 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-824
SELECT - col1 - + col0 / col0 FROM tab2 AS cor0
----
-18
-32
-60

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

query I rowsort
SELECT ALL - 84 + + col0 AS col0 FROM tab0 AS cor0
----
-49
-60
5

query I rowsort
SELECT DISTINCT tab2.col2 * + col1 - 34 * + col1 * - tab2.col0 FROM tab2
----
158002
46308
8215

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

query I rowsort
SELECT DISTINCT col1 * 48 * - col0 + ( - 13 ) * col2 FROM tab0
----
-162973
-389818
-99501

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

query I rowsort
SELECT DISTINCT + cor0.col1 AS col2 FROM tab1, tab0 cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-832
SELECT ALL - cor0.col1 + + ( + col2 + cor0.col2 ) DIV - col0 AS col2 FROM tab0 AS cor0
----
-88
-92
-97

skipif mysql # not compatible
query I rowsort label-832
SELECT ALL - cor0.col1 + + ( + col2 + cor0.col2 ) / - col0 AS col2 FROM tab0 AS cor0
----
-88
-92
-97

query I rowsort
SELECT + 2 + col0 AS col0 FROM tab1 AS cor0
----
5
66
82

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

query I rowsort
SELECT ALL + ( cor0.col2 ) * cor0.col0 + col1 + + 48 FROM tab1 AS cor0
----
236
3706
7741

onlyif mysql # use DIV operator for integer division
query I rowsort label-836
SELECT DISTINCT + 73 * col2 DIV col1 AS col0 FROM tab0 cor0
----
0
28
65

skipif mysql # not compatible
query I rowsort label-836
SELECT DISTINCT + 73 * col2 / col1 AS col0 FROM tab0 cor0
----
0
28
65

query I rowsort
SELECT + col2 * - 91 + col2 AS col1 FROM tab2 AS cor0
----
-2340
-2430
-3420

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

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

skipif mysql # not compatible
query I rowsort label-839
SELECT DISTINCT col2 / col1 + 34 FROM tab2 AS cor0
----
34
36

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

query I rowsort
SELECT cor0.col0 + + 4 AS col2 FROM tab0 AS cor0
----
28
39
93

query I rowsort
SELECT - col0 + - 92 FROM tab0 AS cor0
----
-116
-127
-181

query I rowsort
SELECT ALL + col1 + - 95 + col2 FROM tab1 AS cor0
----
-15
-28
14

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

query I rowsort
SELECT col2 + 64 AS col2 FROM tab0 AS cor0
----
146
65
97

query I rowsort
SELECT ALL 29 * col1 + + col1 * - col1 FROM tab1 AS cor0
----
190
208
78

query I rowsort
SELECT DISTINCT 98 - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1150
-1306
-472

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

query I rowsort
SELECT col2 * col1 + - 66 * 18 FROM tab1 cor0
----
-618
216
60

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

query I rowsort
SELECT + col2 * 35 + cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
1586
1674
2774

query I rowsort
SELECT + col0 + 53 * col1 AS col2 FROM tab0 AS cor0
----
4582
4912
5176

query I rowsort
SELECT + - col0 * col0 + + col0 * cor0.col0 * + ( - col2 ) AS col2 FROM tab1 AS cor0
----
-237568
-495
-620800

onlyif mysql # use DIV operator for integer division
query I rowsort label-854
SELECT + - col2 + - 31 DIV 54 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-854
SELECT + - col2 + - 31 / 54 FROM tab2 AS cor0
----
-26
-27
-38

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-855
SELECT + col1 + col0 / col1 col2 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT ALL col0 * col1 + 31 FROM tab1
----
1071
109
671

query I rowsort
SELECT + - col1 - 60 AS col2 FROM tab1 AS cor0
----
-70
-73
-86

query I rowsort
SELECT + col1 + - col0 - ( + col2 ) FROM tab2 AS cor0
----
-100
-3
-45

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

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

skipif mysql # not compatible
query I rowsort label-860
SELECT col0 * 81 * - col0 + col0 * CAST ( col0 + + col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-45288
-626382
-97965

query I rowsort
SELECT DISTINCT 86 + ( + cor1.col2 ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
119
168
87

query I rowsort
SELECT DISTINCT col1 * + col0 * + col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT + + col2 - - 82 AS col0 FROM tab2 AS cor0
----
108
109
120

query I rowsort
SELECT - - cor0.col1 * + ( - 18 ) + + col2 AS col2 FROM tab2 AS cor0
----
-1036
-268
-531

query I rowsort
SELECT + col2 + + 63 * + ( + col1 ) * col0 AS col1 FROM tab0
----
130065
213886
510319

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

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

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

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

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

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

query I rowsort
SELECT - tab1.col0 + - 6 * + 59 - tab1.col0 * ( - col2 ) AS col1 FROM tab1
----
-195
3230
7246

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

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

query I rowsort
SELECT ALL + 29 + col1 FROM tab0 AS cor0
----
115
120
126

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

query I rowsort
SELECT ALL + 21 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1869
504
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-875
SELECT DISTINCT + 25 + + col1 DIV 44 FROM tab1 AS cor0
----
25

skipif mysql # not compatible
query I rowsort label-875
SELECT DISTINCT + 25 + + col1 / 44 FROM tab1 AS cor0
----
25

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-879
SELECT - - CAST( + 57 AS SIGNED ) * col2 + + CAST( 44 AS SIGNED ) FROM tab0 AS cor0
----
101
1925
4718

skipif mysql # not compatible
query I rowsort label-879
SELECT - - CAST ( + 57 AS INTEGER ) * col2 + + CAST ( 44 AS INTEGER ) FROM tab0 AS cor0
----
101
1925
4718

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

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

query I rowsort
SELECT DISTINCT + - 55 + col1 FROM tab2 AS cor0
----
-24
-38
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-883
SELECT ALL col2 * col0 + col0 * tab2.col1 DIV col0 AS col2 FROM tab2
----
2087
220
3019

skipif mysql # not compatible
query I rowsort label-883
SELECT ALL col2 * col0 + col0 * tab2.col1 / col0 AS col2 FROM tab2
----
2087
220
3019

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + + col2 col2 FROM tab1
----
28
47
83

query I rowsort
SELECT - col0 * 51 - - 13 AS col2 FROM tab2
----
-344
-3965
-4016

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-887
SELECT + CAST( 41 AS SIGNED ) + col1 col2 FROM tab0
----
127
132
138

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-887
SELECT + CAST ( 41 AS INTEGER ) + col1 col2 FROM tab0
----
127
132
138

query I rowsort
SELECT ALL 56 * - 39 AS col2 FROM tab2 AS cor0
----
-2184
-2184
-2184

query I rowsort
SELECT ALL - ( - 94 ) + cor0.col2 AS col1 FROM tab2 cor0
----
120
121
132

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

query I rowsort
SELECT ALL - 79 * - 21 FROM tab2 AS cor0
----
1659
1659
1659

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 57 + + col2 * col2 + - 99 col1 FROM tab2 cor0
----
1288
520
573

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

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

query I rowsort
SELECT ALL - 94 * + col2 + - cor0.col1 + col1 AS col1 FROM tab0 cor0
----
-3102
-7708
-94

query I rowsort
SELECT ALL - 76 - col2 FROM tab1
----
-130
-133
-172

query I rowsort
SELECT + - col2 + col0 * 48 - + col0 FROM tab0 cor0
----
1095
1644
4101

skipif mysql # not compatible
query I rowsort
SELECT + + 72 + - col0 - - CAST ( 21 * col1 AS REAL ) AS col0 FROM tab2 AS cor0
----
1233
350
716

query I rowsort
SELECT DISTINCT col1 * + col1 * col0 + - col0 AS col2 FROM tab0
----
177480
329280
736920

query I rowsort
SELECT + col0 + + 1 AS col2 FROM tab2 cor0
----
79
8
80

query I rowsort
SELECT + cor0.col1 + 47 * + col0 FROM tab0 AS cor0
----
1214
1742
4274

query I rowsort
SELECT DISTINCT col0 * + 65 + cor0.col2 * col2 AS col0 FROM tab2 AS cor0
----
1184
5746
6579

query I rowsort
SELECT ALL + - col2 * - col2 + - 89 AS col0 FROM tab1 AS cor0
----
2827
3160
9127

query I rowsort
SELECT + col0 * ( 39 ) + col2 * - col2 FROM tab1
----
-2799
-6096
-753

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

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

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

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

query I rowsort
SELECT col0 * + 17 * - 32 + - col1 * ( col1 ) FROM tab1 AS cor0
----
-2308
-34916
-43689

query I rowsort
SELECT - cor0.col1 + 43 AS col1 FROM tab2 AS cor0
----
-16
12
26

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-910
SELECT DISTINCT cor0.col2 + col0 DIV ( col2 ) FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-910
SELECT DISTINCT cor0.col2 + col0 / ( col2 ) FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT ALL - col1 * col2 + 78 FROM tab1 AS cor0
----
-1170
-1326
-492

query I rowsort
SELECT DISTINCT + + cor0.col1 - + 77 FROM tab2 AS cor0
----
-18
-46
-60

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

query I rowsort
SELECT 36 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to e09b197365a04fabbaaf0718d2ae88c5

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

query I rowsort
SELECT + col2 * col1 * col1 + - col0 * col2 FROM tab1 AS cor0
----
2052
36342
8544

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

query I rowsort
SELECT - col2 + - 95 * col2 * - col0 AS col0 FROM tab1 cor0
----
15336
346503
729504

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col1 + + cor0.col2 - cor0.col0 * 43 * + col2 col2 FROM tab1 AS cor0
----
-156167
-329104
-6834

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

query I rowsort
SELECT DISTINCT col2 + + col0 * + col0 + col0 AS col0 FROM tab1 AS cor0
----
4217
6576
66

query I rowsort
SELECT - col1 + - ( 69 ) - col1 FROM tab2 AS cor0
----
-103
-131
-187

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-923
SELECT + col1 * CAST( + col2 AS SIGNED ) + + col0 * 37 AS col1 FROM tab0 AS cor0
----
10755
1392
3726

skipif mysql # not compatible
query I rowsort label-923
SELECT + col1 * CAST ( + col2 AS INTEGER ) + + col0 * 37 AS col1 FROM tab0 AS cor0
----
10755
1392
3726

query I rowsort
SELECT ALL + col2 * - 51 FROM tab0 AS cor0
----
-1683
-4182
-51

query I rowsort
SELECT + col1 * 38 * - col0 FROM tab2 AS cor0
----
-174876
-51034
-8246

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-929
SELECT + 64 DIV - 22 + - col1 * col2 FROM tab1 AS cor0
----
-1250
-1406
-572

skipif mysql # not compatible
query I rowsort label-929
SELECT + 64 / - 22 + - col1 * col2 FROM tab1 AS cor0
----
-1250
-1406
-572

query I rowsort
SELECT DISTINCT - - col0 - - 37 FROM tab2 AS cor0
----
115
116
44

query I rowsort
SELECT + 24 + 79 * + col1 AS col0 FROM tab1 AS cor0
----
1051
2078
814

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

query I rowsort
SELECT + tab1.col0 + 77 AS col0 FROM tab1
----
141
157
80

query I rowsort
SELECT DISTINCT + col1 + ( ( + col1 ) + - 49 * + col0 ) AS col1 FROM tab0
----
-1004
-1521
-4179

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

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

query I rowsort
SELECT DISTINCT 96 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-672
-7488
-7584

query I rowsort
SELECT ALL cor1.col2 AS col0 FROM tab2, tab0 cor0, tab2 AS cor1, tab0 cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL + + 15 + col0 * ( - cor0.col1 + + col0 ) AS col1 FROM tab0 cor0
----
-1473
-163
-2155

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

query I rowsort
SELECT ALL 57 + - col1 AS col1 FROM tab2 AS cor0
----
-2
26
40

query I rowsort
SELECT 66 + - col1 + ( + col2 + - tab1.col1 ) * col0 * + col2 AS col2 FROM tab1
----
171512
4576
637493

query I rowsort
SELECT col1 + 24 * col0 AS col1 FROM tab0 AS cor0
----
2227
662
937

query I rowsort
SELECT - col0 - 30 FROM tab0 AS cor0
----
-119
-54
-65

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

query I rowsort
SELECT DISTINCT 30 + + col0 FROM tab2
----
108
109
37

query I rowsort
SELECT ALL 87 AS col1 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT DISTINCT - col0 + col2 + 29 FROM tab1
----
22
45
80

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

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

query I rowsort
SELECT ALL - 29 + + col0 + tab0.col0 AS col0 FROM tab0
----
149
19
41

query I rowsort
SELECT - 61 AS col2 FROM tab0
----
-61
-61
-61

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-955
SELECT DISTINCT + + col0 * - col2 / - col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - ( + 90 ) AS col2 FROM tab2
----
-90

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

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

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

query I rowsort
SELECT + tab1.col1 + + 97 FROM tab1
----
107
110
123

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

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

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

query I rowsort
SELECT - col0 + - 98 FROM tab2 AS cor0
----
-105
-176
-177

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 4 + - col0 col1 FROM tab0 cor0
----
-20
-31
-85

query I rowsort
SELECT + 15 - - 90 AS col0 FROM tab2 AS cor0
----
105
105
105

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-967
SELECT DISTINCT 17 * col0 + + cor0.col0 * + CAST( col1 AS SIGNED ) + - col1 col0 FROM tab0 AS cor0
----
2386
3893
9521

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-967
SELECT DISTINCT 17 * col0 + + cor0.col0 * + CAST ( col1 AS INTEGER ) + - col1 col0 FROM tab0 AS cor0
----
2386
3893
9521

query I rowsort
SELECT ( 89 ) + col1 AS col1 FROM tab1 AS cor0
----
102
115
99

query I rowsort
SELECT + tab2.col2 + + ( - 56 ) AS col0 FROM tab2
----
-18
-29
-30

query I rowsort
SELECT col1 + 31 * + col0 FROM tab2
----
2466
2477
248

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

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

query I rowsort
SELECT + 66 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 cor2
----
81 values hashing to dc112f70fecc29a6e605a39541192f43

query I rowsort
SELECT ALL - ( + cor0.col2 ) AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT 39 + - cor0.col1 * + col0 FROM tab1 AS cor0
----
-1001
-39
-601

query I rowsort
SELECT DISTINCT - col2 * 62 FROM tab0
----
-2046
-5084
-62

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

query I rowsort
SELECT 92 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

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

query I rowsort
SELECT + 33 * col1 AS col2 FROM tab2 AS cor0
----
1023
1947
561

query I rowsort
SELECT + 78 + + cor0.col2 * col1 * 88 AS col1 FROM tab1 AS cor0
----
109902
123630
50238

query I rowsort
SELECT DISTINCT 18 * col2 + - col0 * - col1 AS col1 FROM tab2 AS cor0
----
2027
5070
703

query I rowsort
SELECT ALL + + col0 * col2 - 21 FROM tab2 AS cor0
----
168
2007
2981

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-984
SELECT - col2 * cor0.col1 * CAST( col1 AS SIGNED ) + cor0.col2 FROM tab1 AS cor0
----
-16128
-36450
-5643

skipif mysql # not compatible
query I rowsort label-984
SELECT - col2 * cor0.col1 * CAST ( col1 AS INTEGER ) + cor0.col2 FROM tab1 AS cor0
----
-16128
-36450
-5643

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-988
SELECT ( col0 ) * 63 + + col0 * col1 + ( col0 + + col1 ) DIV + col2 AS col0 FROM tab0 cor0
----
13708
3579
5732

skipif mysql # not compatible
query I rowsort label-988
SELECT ( col0 ) * 63 + + col0 * col1 + ( col0 + + col1 ) / + col2 AS col0 FROM tab0 cor0
----
13708
3579
5732

query I rowsort
SELECT + - 63 AS col2 FROM tab0 AS cor0
----
-63
-63
-63

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-991
SELECT + col1 DIV - col1 - - 14 col0 FROM tab1 AS cor0
----
13
13
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-991
SELECT + col1 / - col1 - - 14 col0 FROM tab1 AS cor0
----
13
13
13

query I rowsort
SELECT ALL - 69 FROM tab1 cor0
----
-69
-69
-69

query I rowsort
SELECT ALL cor0.col1 + col1 AS col0 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT DISTINCT col0 - col0 * - col0 AS col1 FROM tab1 AS cor0
----
12
4160
6480

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

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

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

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

query I rowsort
SELECT 16 * + tab2.col0 FROM tab2
----
112
1248
1264

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

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

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

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

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

query I rowsort
SELECT DISTINCT tab0.col0 AS col0 FROM tab0, tab1 AS cor0
----
24
35
89

query I rowsort
SELECT 51 * - col0 FROM tab2
----
-357
-3978
-4029

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1006
SELECT ALL + col0 + + cor0.col2 + + 42 DIV + cor0.col2 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-1006
SELECT ALL + col0 + + cor0.col2 + + 42 / + cor0.col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - 68 + 67 FROM tab0, tab0 cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT ALL col1 * - 70 FROM tab0
----
-6020
-6370
-6790

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

query I rowsort
SELECT DISTINCT - col0 - col1 * col0 * col2 FROM tab2 cor0
----
-119730
-51113
-5866

query I rowsort
SELECT col1 * col2 + + tab0.col0 * - tab0.col1 * + col2 FROM tab0
----
-3298
-65274
-656656

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1013
SELECT DISTINCT cor0.col2 DIV col1 + cor0.col1 + col2 FROM tab2 AS cor0
----
57
58
85

skipif mysql # not compatible
query I rowsort label-1013
SELECT DISTINCT cor0.col2 / col1 + cor0.col1 + col2 FROM tab2 AS cor0
----
57
58
85

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

skipif mysql # not compatible
query I rowsort label-1014
SELECT ALL col2 / + col0 + col1 FROM tab0 AS cor0
----
87
91
97

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

skipif mysql # not compatible
query I rowsort label-1015
SELECT ALL col1 * + col0 - col0 / + col0 AS col0 FROM tab0 AS cor0
----
2063
3394
8098

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

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

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

query I rowsort
SELECT tab1.col0 + - col2 + + col2 * - col1 AS col1 FROM tab1
----
-1264
-1455
-563

query I rowsort
SELECT - col1 * - col0 FROM tab2 WHERE NULL IN ( col2 )
----

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

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

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

query I rowsort
SELECT col0 + - col2 * col2 * - col1 FROM tab0
----
132
611973
93678

query I rowsort
SELECT + col1 + col0 + - tab1.col2 AS col1 FROM tab1
----
-25
-3
17

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

query I rowsort
SELECT + col2 + - col0 + + col1 * - tab2.col1 FROM tab2
----
-330
-3533
-941

query I rowsort
SELECT ALL + col2 * - col2 * col2 AS col0 FROM tab0
----
-1
-35937
-551368

query I rowsort
SELECT DISTINCT - + 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 DISTINCT + col1 * col0 col2 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1031
SELECT DISTINCT + - col2 + col1 * col1 DIV + col2 AS col0 FROM tab1 AS cor0
----
-42
-56
-95

skipif mysql # not compatible
query I rowsort label-1031
SELECT DISTINCT + - col2 + col1 * col1 / + col2 AS col0 FROM tab1 AS cor0
----
-42
-56
-95

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1035
SELECT + - cor0.col1 / - col1 - col1 AS col2 FROM tab2 cor0
----
-16
-30
-58

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col2 * col0 col0 FROM tab2 cor0
----
114076
5103
52728

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

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

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

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

query I rowsort
SELECT - col2 + - cor0.col1 - col1 * + col2 FROM tab1 cor0
----
-1357
-1484
-637

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

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

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

query I rowsort
SELECT - - col1 + col2 * col0 - + col1 * col0 FROM tab0 AS cor0
----
-1186
-3263
-710

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

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT BETWEEN - col2 * + col1 + col1 AND - col1 + + tab2.col0 * col0 + col1 * col1 * col2
----

query I rowsort
SELECT 7 + - col2 * col1 FROM tab1
----
-1241
-1397
-563

onlyif mysql # use DIV operator for integer division
query I rowsort label-1050
SELECT 18 DIV col0 FROM tab1
----
0
0
6

skipif mysql # not compatible
query I rowsort label-1050
SELECT 18 / col0 FROM tab1
----
0
0
6

query I rowsort
SELECT DISTINCT 36 + col1 * col0 AS col1 FROM tab1
----
1076
114
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-1052
SELECT ( - tab1.col0 ) DIV ( 39 ) FROM tab1
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-1052
SELECT ( - tab1.col0 ) / ( 39 ) FROM tab1
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + - cor0.col2 * + col0 col0 FROM tab0 AS cor0
----
-36
-7380
-825

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

query I rowsort
SELECT col1 + col1 * 97 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT - 90 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to c0d96679aba507520916e8654e5a6618

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1057
SELECT DISTINCT + col0 * + CAST( - col1 AS SIGNED ) * col1 FROM tab2
----
-22831
-271518
-6727

skipif mysql # not compatible
query I rowsort label-1057
SELECT DISTINCT + col0 * + CAST ( - col1 AS INTEGER ) * col1 FROM tab2
----
-22831
-271518
-6727

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 82 col0 FROM tab0 AS cor0
----
115
164
83

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

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

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

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

query I rowsort
SELECT DISTINCT - - col1 + 52 AS col0 FROM tab2 cor0
----
111
69
83

query I rowsort
SELECT ALL - - col0 * 27 + col1 FROM tab1 AS cor0
----
107
1738
2173

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

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

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

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

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

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

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

query I rowsort
SELECT - + 93 * + col1 AS col0 FROM tab0 AS cor0
----
-7998
-8463
-9021

query I rowsort
SELECT ALL 56 + col0 FROM tab0 AS cor0
----
145
80
91

query I rowsort
SELECT + col2 AS col0 FROM tab1 WHERE NOT NULL = NULL
----

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

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

query I rowsort
SELECT + - 68 * col0 AS col2 FROM tab2 AS cor0
----
-476
-5304
-5372

query I rowsort
SELECT col2 * 67 * - 0 AS col2 FROM tab1 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT - 29 * col0 + ( + tab2.col1 ) FROM tab2
----
-172
-2203
-2274

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

query I rowsort
SELECT DISTINCT - - cor0.col1 + 99 FROM tab0 AS cor0
----
185
190
196

onlyif mysql # use DIV operator for integer division
query I rowsort label-1083
SELECT - 46 DIV col0 + col0 * col1 * + col2 FROM tab0 AS cor0
----
3394
664118
68111

skipif mysql # not compatible
query I rowsort label-1083
SELECT - 46 / col0 + col0 * col1 * + col2 FROM tab0 AS cor0
----
3394
664118
68111

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 6 col0 FROM tab0
----
-144
-210
-534

query I rowsort
SELECT DISTINCT - 58 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
-58

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

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

query I rowsort
SELECT ALL ( - 27 ) FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 0259a67676b131a4843853be4811b775

query I rowsort
SELECT + - 57 * col2 * col0 FROM tab1 AS cor0
----
-207936
-437760
-9234

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

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

query I rowsort
SELECT DISTINCT cor0.col0 + col0 + col2 FROM tab0 AS cor0
----
260
71
81

query I rowsort
SELECT + 27 + col2 FROM tab0
----
109
28
60

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

query I rowsort
SELECT + 86 - - tab1.col2 AS col2 FROM tab1
----
140
143
182

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

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

query I rowsort
SELECT col0 + - col2 * + col2 AS col2 FROM tab0
----
-1065
-6635
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-1099
SELECT ALL - cor0.col2 + + col2 DIV col2 + - col0 AS col2 FROM tab0 AS cor0
----
-170
-35
-56

skipif mysql # not compatible
query I rowsort label-1099
SELECT ALL - cor0.col2 + + col2 / col2 + - col0 AS col2 FROM tab0 AS cor0
----
-170
-35
-56

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

query I rowsort
SELECT tab0.col0 * - 15 FROM tab0
----
-1335
-360
-525

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + 78 col1 FROM tab1
----
104
88
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-1107
SELECT DISTINCT col2 DIV - col2 + + tab1.col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-1107
SELECT DISTINCT col2 / - col2 + + tab1.col0 FROM tab1
----
2
63
79

query I rowsort
SELECT + col0 * 72 + col0 AS col1 FROM tab2
----
511
5694
5767

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

query IIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0 WHERE NULL NOT IN ( cor0.col0 )
----

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

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

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

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

query I rowsort
SELECT ALL 20 + col0 * + col2 AS col2 FROM tab1 AS cor0
----
182
3668
7700

onlyif mysql # use DIV operator for integer division
query I rowsort label-1115
SELECT ( - col0 ) + col2 * + cor0.col1 DIV + col1 AS col1 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-1115
SELECT ( - col0 ) + col2 * + cor0.col1 / + col1 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + 44 * col0 * - col0 FROM tab0 AS cor0
----
-25344
-348524
-53900

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

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

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

query I rowsort
SELECT - 19 * col2 AS col2 FROM tab2
----
-494
-513
-722

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

query I rowsort
SELECT DISTINCT + + 47 + cor0.col1 AS col2 FROM tab0 AS cor0
----
133
138
144

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col2 ) * cor0.col1 - col2 col1 FROM tab0 AS cor0
----
-2871
-7544
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1123
SELECT ALL ( col2 ) DIV - col1 - - col0 AS col0 FROM tab1 AS cor0
----
1
59
73

skipif mysql # not compatible
query I rowsort label-1123
SELECT ALL ( col2 ) / - col1 - - col0 AS col0 FROM tab1 AS cor0
----
1
59
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-1124
SELECT + col2 * cor0.col0 + + col1 DIV + col2 FROM tab0 cor0
----
132
7299
794

skipif mysql # not compatible
query I rowsort label-1124
SELECT + col2 * cor0.col0 + + col1 / + col2 FROM tab0 cor0
----
132
7299
794

onlyif mysql # use DIV operator for integer division
query I rowsort label-1125
SELECT 31 + col1 DIV + col1 AS col0 FROM tab2
----
32
32
32

skipif mysql # not compatible
query I rowsort label-1125
SELECT 31 + col1 / + col1 AS col0 FROM tab2
----
32
32
32

query I rowsort
SELECT col1 * + 17 FROM tab2
----
1003
289
527

query I rowsort
SELECT + 1 AS col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 41 - + col2 * - col2 col2 FROM tab0
----
1130
42
6765

query I rowsort
SELECT DISTINCT ( + tab1.col0 ) * col1 + + col2 + col1 AS col1 FROM tab1
----
1149
158
707

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1132
SELECT DISTINCT + CAST( + col1 AS SIGNED ) * + col2 + - 27 * - 47 * + col1 FROM tab1 AS cor0
----
13260
17745
34398

skipif mysql # not compatible
query I rowsort label-1132
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) * + col2 + - 27 * - 47 * + col1 FROM tab1 AS cor0
----
13260
17745
34398

query I rowsort
SELECT + col1 * + col0 * ( col0 ) + - col2 * col0 AS col1 FROM tab0 AS cor0
----
118790
48744
713513

query I rowsort
SELECT ALL col1 * + col2 + + cor0.col2 + cor0.col1 FROM tab0 cor0
----
195
2957
7635

query I rowsort
SELECT col1 * - col1 + + col2 * 52 AS col0 FROM tab2 AS cor0
----
-2129
1687
443

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - cor0.col1 * - ( cor0.col2 ) + - col2 col1 FROM tab1 AS cor0
----
1056
1296
456

query I rowsort
SELECT + 17 + cor0.col0 FROM tab0 AS cor0
----
106
41
52

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

query I rowsort
SELECT DISTINCT + col1 + col2 - - col2 FROM tab2 AS cor0
----
111
85
93

query I rowsort
SELECT DISTINCT - 24 * - col2 + col2 * 26 AS col1 FROM tab0 cor0
----
1650
4100
50

query I rowsort
SELECT ALL + 57 AS col1 FROM tab0 AS cor0
----
57
57
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-1142
SELECT ALL + ( - ( col2 ) ) - - 53 DIV - col0 AS col1 FROM tab0
----
-2
-35
-82

skipif mysql # not compatible
query I rowsort label-1142
SELECT ALL + ( - ( col2 ) ) - - 53 / - col0 AS col1 FROM tab0
----
-2
-35
-82

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

query I rowsort
SELECT - col1 + 17 * + tab2.col2 FROM tab2
----
383
428
629

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

query I rowsort
SELECT ALL - col1 + - col1 * col1 * col1 FROM tab1 AS cor0
----
-1010
-17602
-2210

query I rowsort
SELECT ALL col2 + 25 AS col2 FROM tab1 AS cor0
----
121
79
82

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

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

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

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

query I rowsort
SELECT DISTINCT - col1 * col1 * 6 AS col2 FROM tab2 AS cor0
----
-1734
-20886
-5766

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

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

query I rowsort
SELECT - 3 * ( col1 ) AS col0 FROM tab2 AS cor0
----
-177
-51
-93

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1155
SELECT ALL + col0 DIV - col0 + + col1 * - col0 AS col2 FROM tab1 cor0
----
-1041
-641
-79

skipif mysql # not compatible
query I rowsort label-1155
SELECT ALL + col0 / - col0 + + col1 * - col0 AS col2 FROM tab1 cor0
----
-1041
-641
-79

query I rowsort
SELECT DISTINCT - ( col0 ) * col1 + + 18 FROM tab2 cor0
----
-1325
-199
-4584

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

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

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

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

query I rowsort
SELECT - - 35 + - col1 AS col2 FROM tab1 AS cor0
----
22
25
9

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1163
SELECT ALL 20 DIV col1 AS col0 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1163
SELECT ALL 20 / col1 AS col0 FROM tab2
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 18 * - col2 col2 FROM tab1 AS cor0
----
-1026
-1728
-972

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1167
SELECT DISTINCT - CAST( col0 AS SIGNED ) * - col2 + CAST( 62 AS SIGNED ) DIV - col2 FROM tab1 AS cor0
----
161
3647
7680

skipif mysql # not compatible
query I rowsort label-1167
SELECT DISTINCT - CAST ( col0 AS INTEGER ) * - col2 + CAST ( 62 AS INTEGER ) / - col2 FROM tab1 AS cor0
----
161
3647
7680

query I rowsort
SELECT DISTINCT 89 + - 23 * - col0 FROM tab1 AS cor0
----
1561
158
1929

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 73 col0 FROM tab0, tab1 cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT ALL col0 + col2 * - col2 + col2 AS col1 FROM tab2
----
-1327
-572
-695

onlyif mysql # use DIV operator for integer division
query I rowsort label-1172
SELECT DISTINCT + col2 DIV cor0.col2 + 29 AS col0 FROM tab0 AS cor0
----
30

skipif mysql # not compatible
query I rowsort label-1172
SELECT DISTINCT + col2 / cor0.col2 + 29 AS col0 FROM tab0 AS cor0
----
30

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

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

query I rowsort
SELECT DISTINCT - 8 + - col0 FROM tab1
----
-11
-72
-88

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

query I rowsort
SELECT ALL + 92 + + 4 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

onlyif mysql # use DIV operator for integer division
query I rowsort label-1177
SELECT ALL - + col0 + 57 DIV col1 AS col2 FROM tab0 cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1177
SELECT ALL - + col0 + 57 / col1 AS col2 FROM tab0 cor0
----
-24
-35
-89

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

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

query I rowsort
SELECT DISTINCT + col2 * - 73 FROM tab1 AS cor0
----
-3942
-4161
-7008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 + - 42 col1 FROM tab0 AS cor0
----
-1267
-618
-7963

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

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

query I rowsort
SELECT - + 42 * cor0.col0 AS col2 FROM tab2 AS cor0
----
-294
-3276
-3318

query I rowsort
SELECT + col0 * + col0 * - col0 AS col1 FROM tab0 AS cor0
----
-13824
-42875
-704969

query I rowsort
SELECT - 43 + col0 * col1 * - col0 AS col1 FROM tab1 AS cor0
----
-277
-41003
-83243

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1188
SELECT ALL + cor0.col0 DIV CAST( col0 AS SIGNED ) + + col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-1188
SELECT ALL + cor0.col0 / CAST ( col0 AS INTEGER ) + + col1 FROM tab2 AS cor0
----
18
32
60

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

query I rowsort
SELECT + - col1 * - 47 AS col2 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT DISTINCT - col1 + 20 - + col0 AS col0 FROM tab0 AS cor0
----
-112
-160
-90

query I rowsort
SELECT DISTINCT - + cor0.col2 + - cor0.col0 FROM tab2, tab0 cor0
----
-171
-36
-57

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

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

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

query I rowsort
SELECT DISTINCT - - cor0.col2 + - 57 FROM tab2, tab1 AS cor0
----
-3
0
39

query I rowsort
SELECT ALL - 70 * - tab2.col1 FROM tab2
----
1190
2170
4130

query I rowsort
SELECT - cor0.col1 + - col2 + cor0.col0 FROM tab0 AS cor0
----
-63
-84
-95

query I rowsort
SELECT col1 * + ( + col0 ) * tab0.col1 FROM tab0
----
177504
329315
737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 78 * - col1 col1 FROM tab1
----
-1014
-2028
-780

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1205
SELECT ALL - - 25 + - col2 DIV col2 + - col1 FROM tab1 AS cor0
----
-2
11
14

skipif mysql # not compatible
query I rowsort label-1205
SELECT ALL - - 25 + - col2 / col2 + - col1 FROM tab1 AS cor0
----
-2
11
14

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

query I rowsort
SELECT ALL col1 + - col0 * + col2 FROM tab1 cor0
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-1208
SELECT ALL 68 * - ( tab1.col0 ) + ( - col0 ) DIV - col0 FROM tab1
----
-203
-4351
-5439

skipif mysql # not compatible
query I rowsort label-1208
SELECT ALL 68 * - ( tab1.col0 ) + ( - col0 ) / - col0 FROM tab1
----
-203
-4351
-5439

query I rowsort
SELECT ALL - col1 * 70 * tab0.col2 AS col1 FROM tab0
----
-198660
-522340
-6790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 81 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

query I rowsort
SELECT + col0 + - tab2.col1 * col2 FROM tab2
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col2 col2 FROM tab1
----
-28
-47
-83

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

query I rowsort
SELECT ALL - + col0 + col1 * - ( cor0.col2 ) + col2 AS col0 FROM tab2 AS cor0
----
-1586
-687
-817

query I rowsort
SELECT 7 + - col2 + - col1 FROM tab1 AS cor0
----
-102
-60
-73

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col0 * CAST ( + col2 AS REAL ) - col1 AS col1 FROM tab0
----
-62
706
7207

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

query I rowsort
SELECT + col2 + + 90 * + tab0.col2 FROM tab0
----
3003
7462
91

query I rowsort
SELECT col1 * - col1 + tab2.col0 AS col2 FROM tab2
----
-210
-3403
-954

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + col0 AS REAL ) * + col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-1227
SELECT + + 6 * - col2 + + col0 DIV + col1 AS col1 FROM tab2 AS cor0
----
-155
-162
-224

skipif mysql # not compatible
query I rowsort label-1227
SELECT + + 6 * - col2 + + col0 / + col1 AS col1 FROM tab2 AS cor0
----
-155
-162
-224

query I rowsort
SELECT 46 * col1 + - col1 AS col2 FROM tab0
----
3870
4095
4365

query I rowsort
SELECT + 84 + 96 + + col2 AS col2 FROM tab2 cor0
----
206
207
218

query I rowsort
SELECT DISTINCT 67 * - col1 + col2 * ( - ( col2 ) ) AS col2 FROM tab0 AS cor0
----
-12821
-6500
-6851

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

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

query I rowsort
SELECT DISTINCT col1 + 34 + col0 * + col0 FROM tab2 AS cor0
----
114
6177
6292

query I rowsort
SELECT ALL ( - 90 ) * col2 * ( col2 ) - col1 * + ( - col2 + col0 ) AS col1 FROM tab2 cor0
----
-130657
-63908
-64990

query I rowsort
SELECT + - 85 + col0 FROM tab0 AS cor0
----
-50
-61
4

query I rowsort
SELECT + + 36 * - 66 + col1 AS col0 FROM tab2 AS cor0
----
-2317
-2345
-2359

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1236
SELECT + CAST( 39 AS SIGNED ) - + col1 * col2 FROM tab1 AS cor0
----
-1209
-1365
-531

skipif mysql # not compatible
query I rowsort label-1236
SELECT + CAST ( 39 AS INTEGER ) - + col1 * col2 FROM tab1 AS cor0
----
-1209
-1365
-531

query I rowsort
SELECT DISTINCT - - col1 + + col1 * + col0 * col0 FROM tab2 AS cor0
----
106114
1550
359015

query I rowsort
SELECT cor0.col0 * + cor0.col0 + + cor0.col1 * 63 AS col1 FROM tab0 AS cor0
----
13654
5994
7336

query I rowsort
SELECT - 62 * 29 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 10447c8a3a4e30893fcfc69ed097a7b4

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1242
SELECT DISTINCT - col1 * - CAST ( NULL AS REAL ) * col0 AS col2 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1243
SELECT col2 DIV ( - col1 ) AS col2 FROM tab2
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-1243
SELECT col2 / ( - col1 ) AS col2 FROM tab2
----
-2
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1244
SELECT col1 DIV 40 AS col1 FROM tab0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-1244
SELECT col1 / 40 AS col1 FROM tab0
----
2
2
2

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

query I rowsort
SELECT col1 * cor0.col0 * col0 FROM tab2 cor0
----
106097
1519
358956

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

query I rowsort
SELECT ALL + - cor0.col2 * ( + 64 ) FROM tab2 AS cor0
----
-1664
-1728
-2432

query I rowsort
SELECT + 73 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT DISTINCT - + col2 * ( + 95 ) FROM tab1 cor0
----
-5130
-5415
-9120

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

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

query I rowsort
SELECT DISTINCT col2 + + 55 * tab0.col2 AS col2 FROM tab0
----
1848
4592
56

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

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

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

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

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

query I rowsort
SELECT ALL + ( + col0 ) * col1 + 55 FROM tab1 AS cor0
----
1095
133
695

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

query I rowsort
SELECT - ( + 53 ) * - col1 FROM tab1 AS cor0
----
1378
530
689

query I rowsort
SELECT ALL - ( 8 ) FROM tab0
----
-8
-8
-8

query I rowsort
SELECT ALL - + col1 + - 49 FROM tab1 cor0
----
-59
-62
-75

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

query I rowsort
SELECT DISTINCT 79 * cor0.col1 + - col2 AS col1 FROM tab1 AS cor0
----
2000
733
931

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1267
SELECT 49 * col1 DIV - 38 FROM tab1 AS cor0
----
-12
-16
-33

skipif mysql # not compatible
query I rowsort label-1267
SELECT 49 * col1 / - 38 FROM tab1 AS cor0
----
-12
-16
-33

query I rowsort
SELECT DISTINCT - - 19 + + col1 + + ( - col2 ) * + cor0.col0 FROM tab1 AS cor0
----
-117
-3619
-7648

query I rowsort
SELECT 49 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
147
3136
3920

query I rowsort
SELECT ALL - cor0.col0 * col1 - + ( 51 + cor0.col0 ) * + 18 FROM tab2 AS cor0
----
-1261
-3683
-6924

query I rowsort
SELECT ALL col1 * col2 * + 74 + + col1 AS col0 FROM tab1 AS cor0
----
103922
42190
92365

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - cor0.col2 col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - 2 + col2 * + col1 FROM tab1 AS cor0
----
1246
1402
568

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

skipif mysql # not compatible
query I rowsort label-1275
SELECT ALL + - col1 * col1 + 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-1276
SELECT + cor0.col0 DIV cor0.col2 + + 94 AS col2 FROM tab0 cor0
----
129
94
95

skipif mysql # not compatible
query I rowsort label-1276
SELECT + cor0.col0 / cor0.col2 + + 94 AS col2 FROM tab0 cor0
----
129
94
95

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

query I rowsort
SELECT DISTINCT - + 31 + col2 FROM tab0 AS cor0
----
-30
2
51

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

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

query I rowsort
SELECT - 86 + + col1 AS col2 FROM tab2 AS cor0
----
-27
-55
-69

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

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

query I rowsort
SELECT + col1 + - col1 * ( - col2 ) * - 85 FROM tab1 AS cor0
----
-106067
-119314
-48440

query I rowsort
SELECT - + 26 * col1 * - col1 FROM tab2 AS cor0
----
24986
7514
90506

query I rowsort
SELECT ALL 88 + col1 * + col2 AS col2 FROM tab0 AS cor0
----
185
2926
7550

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

query I rowsort
SELECT DISTINCT - ( 79 ) FROM tab0 cor0
----
-79

query I rowsort
SELECT ALL - + 87 * col0 AS col0 FROM tab0 AS cor0
----
-2088
-3045
-7743

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 + - 66 + col0 col1 FROM tab2
----
1356
158
4614

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

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

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

query I rowsort
SELECT + + 92 + 75 FROM tab2 AS cor0
----
167
167
167

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

skipif mysql # not compatible
query I rowsort label-1295
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + cor0.col2 AS col2 FROM tab2, tab2 cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT ALL - 73 * - 82 FROM tab2 AS cor0
----
5986
5986
5986

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + 31 col2 FROM tab2 AS cor0
----
109
110
38

query I rowsort
SELECT - 83 * col1 * - cor0.col0 - col1 AS col1 FROM tab0 AS cor0
----
171226
281688
672126

query I rowsort
SELECT 91 * + ( col2 ) FROM tab0
----
3003
7462
91

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

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

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

query I rowsort
SELECT col1 + col1 * 32 + + col2 FROM tab1
----
387
525
912

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

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

query I rowsort
SELECT - ( + 30 ) AS col2 FROM tab2 AS cor0
----
-30
-30
-30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1306
SELECT + + CAST( NULL AS SIGNED ) + + 1 + + cor0.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-1306
SELECT + + CAST ( NULL AS INTEGER ) + + 1 + + cor0.col0 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - cor0.col0 + - 27 FROM tab2 AS cor0
----
-20
51
52

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1309
SELECT DISTINCT col2 DIV - cor0.col2 + + col2 DIV col1 FROM tab1 AS cor0
----
1
4
6

skipif mysql # not compatible
query I rowsort label-1309
SELECT DISTINCT col2 / - cor0.col2 + + col2 / col1 FROM tab1 AS cor0
----
1
4
6

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

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

query I rowsort
SELECT + ( 84 ) * col2 AS col0 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT 24 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT 97 * + tab0.col2 * ( 92 ) FROM tab0
----
294492
731768
8924

onlyif mysql # use DIV operator for integer division
query I rowsort label-1315
SELECT + - col2 * col0 - + ( - 11 ) * col1 DIV + col2 AS col1 FROM tab1 AS cor0
----
-157
-3647
-7679

skipif mysql # not compatible
query I rowsort label-1315
SELECT + - col2 * col0 - + ( - 11 ) * col1 / + col2 AS col1 FROM tab1 AS cor0
----
-157
-3647
-7679

query I rowsort
SELECT col2 * - col1 - - 77 AS col1 FROM tab0 cor0
----
-20
-2761
-7385

query I rowsort
SELECT DISTINCT 80 + cor0.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
113
162
81

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

query I rowsort
SELECT DISTINCT col0 * 22 + cor0.col2 * col1 FROM tab1 cor0
----
1470
1978
3008

query I rowsort
SELECT + col0 * cor0.col0 - + 69 FROM tab0 cor0
----
1156
507
7852

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

query I rowsort
SELECT DISTINCT + col1 + ( 84 ) + cor0.col0 AS col2 FROM tab1 cor0
----
113
158
177

onlyif mysql # use DIV operator for integer division
query I rowsort label-1323
SELECT col1 + + cor0.col0 DIV + col2 - - col0 FROM tab1 AS cor0
----
29
75
93

skipif mysql # not compatible
query I rowsort label-1323
SELECT col1 + + cor0.col0 / + col2 - - col0 FROM tab1 AS cor0
----
29
75
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1324
SELECT DISTINCT + col0 * ( ( + col0 ) ) DIV 8 AS col0 FROM tab2 AS cor0
----
6
760
780

skipif mysql # not compatible
query I rowsort label-1324
SELECT DISTINCT + col0 * ( ( + col0 ) ) / 8 AS col0 FROM tab2 AS cor0
----
6
760
780

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

query I rowsort
SELECT ALL + col0 * - 87 FROM tab1 AS cor0
----
-261
-5568
-6960

query I rowsort
SELECT ALL - col1 - 40 FROM tab0 AS cor0
----
-126
-131
-137

query I rowsort
SELECT - col2 * col0 * 63 + + col2 FROM tab2 AS cor0
----
-11880
-127738
-189088

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1330
SELECT ALL col0 + col0 DIV + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-1330
SELECT ALL col0 + col0 / + col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT ALL + col2 * col0 * + col0 + col2 - 39 AS col2 FROM tab2 AS cor0
----
1311
158171
237157

query I rowsort
SELECT DISTINCT + col0 + 54 * - col0 FROM tab0 AS cor0
----
-1272
-1855
-4717

query I rowsort
SELECT + col1 - - 96 * + col1 AS col2 FROM tab1 AS cor0
----
1261
2522
970

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

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

skipif mysql # not compatible
query I rowsort label-1335
SELECT DISTINCT - + CAST ( col2 AS INTEGER ) + col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL + 4 * - cor0.col0 FROM tab1 AS cor0
----
-12
-256
-320

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1338
SELECT DISTINCT col2 * - ( + col2 ) - 68 * col0 DIV col0 AS col2 FROM tab2 AS cor0
----
-1512
-744
-797

skipif mysql # not compatible
query I rowsort label-1338
SELECT DISTINCT col2 * - ( + col2 ) - 68 * col0 / col0 AS col2 FROM tab2 AS cor0
----
-1512
-744
-797

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + - ( - col0 ) AS col0 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1345
SELECT - col1 * col1 DIV ( + 51 ) col1 FROM tab2 cor0
----
-18
-5
-68

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1345
SELECT - col1 * col1 / ( + 51 ) col1 FROM tab2 cor0
----
-18
-5
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-1346
SELECT DISTINCT - col0 * col0 DIV col1 AS col0 FROM tab0 cor0
----
-12
-6
-87

skipif mysql # not compatible
query I rowsort label-1346
SELECT DISTINCT - col0 * col0 / col1 AS col0 FROM tab0 cor0
----
-12
-6
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-1347
SELECT - - col0 * cor0.col2 DIV - ( - col1 * + col1 ) FROM tab2 cor0
----
0
0
10

skipif mysql # not compatible
query I rowsort label-1347
SELECT - - col0 * cor0.col2 / - ( - col1 * + col1 ) FROM tab2 cor0
----
0
0
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-1348
SELECT DISTINCT - ( - col0 + col1 ) DIV + 24 FROM tab0
----
-2
0

skipif mysql # not compatible
query I rowsort label-1348
SELECT DISTINCT - ( - col0 + col1 ) / + 24 FROM tab0
----
-2
0

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

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

query I rowsort
SELECT - 40 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 01aad4539198a6509248e086869f90a6

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + 52 col0 FROM tab2 AS cor0
----
130
131
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1354
SELECT + CAST( 8 AS SIGNED ) + - col2 * - col0 FROM tab1 cor0
----
170
3656
7688

skipif mysql # not compatible
query I rowsort label-1354
SELECT + CAST ( 8 AS INTEGER ) + - col2 * - col0 FROM tab1 cor0
----
170
3656
7688

query I rowsort
SELECT - - col2 * 62 + + col0 AS col1 FROM tab1 AS cor0
----
3351
3598
6032

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1359
SELECT ALL + col0 + - 54 DIV + col0 FROM tab0 AS cor0
----
22
34
89

skipif mysql # not compatible
query I rowsort label-1359
SELECT ALL + col0 + - 54 / + col0 FROM tab0 AS cor0
----
22
34
89

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

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

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

query I rowsort
SELECT 1 + 49 * + col0 AS col1 FROM tab1
----
148
3137
3921

query I rowsort
SELECT DISTINCT col0 + + col1 - 65 * + 65 FROM tab2
----
-4088
-4129
-4187

query I rowsort
SELECT DISTINCT - col0 * - col1 - 27 * ( - tab0.col0 ) FROM tab0
----
10502
2712
4340

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

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

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

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

query I rowsort
SELECT - col1 * - 87 - - col0 AS col0 FROM tab1 AS cor0
----
1211
2265
934

query I rowsort
SELECT DISTINCT col1 * - col1 AS col2 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - col0 + col2 * 47 - col0 AS col0 FROM tab2
----
1066
1255
1628

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

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

query I rowsort
SELECT ALL + col0 * col2 + + col0 FROM tab0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-1374
SELECT - col2 DIV + col0 + - 50 + col2 AS col1 FROM tab1
----
-14
45
7

skipif mysql # not compatible
query I rowsort label-1374
SELECT - col2 / + col0 + - 50 + col2 AS col1 FROM tab1
----
-14
45
7

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

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

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

query I rowsort
SELECT 57 - col2 AS col2 FROM tab0
----
-25
24
56

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1380
SELECT tab1.col2 DIV - 70 + tab1.col1 AS col2 FROM tab1
----
10
12
26

skipif mysql # not compatible
query I rowsort label-1380
SELECT tab1.col2 / - 70 + tab1.col1 AS col2 FROM tab1
----
10
12
26

query I rowsort
SELECT ALL col1 * - 87 * col1 AS col0 FROM tab0
----
-643452
-720447
-818583

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

query I rowsort
SELECT ALL - col0 * 56 AS col0 FROM tab1 AS cor0
----
-168
-3584
-4480

query I rowsort
SELECT - col0 * - 10 + - col0 FROM tab2 AS cor0
----
63
702
711

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

query I rowsort
SELECT DISTINCT col1 + + 61 FROM tab0 AS cor0
----
147
152
158

query I rowsort
SELECT - cor0.col0 + + 94 * + col2 AS col1 FROM tab1 AS cor0
----
5073
5294
8944

query I rowsort
SELECT DISTINCT col0 * + col0 * - 19 + cor0.col1 AS col1 FROM tab1 cor0
----
-121587
-145
-77814

query I rowsort
SELECT col0 * cor0.col0 * cor0.col2 + col2 + 50 FROM tab2 AS cor0
----
1400
158260
237246

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1390
SELECT ALL col1 * - CAST( - 50 AS SIGNED ) FROM tab1 AS cor0
----
1300
500
650

skipif mysql # not compatible
query I rowsort label-1390
SELECT ALL col1 * - CAST ( - 50 AS INTEGER ) FROM tab1 AS cor0
----
1300
500
650

query I rowsort
SELECT cor0.col1 * + 73 + 60 AS col2 FROM tab1 AS cor0
----
1009
1958
790

query I rowsort
SELECT DISTINCT col1 * - col0 * + col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT col1 + 82 AS col0 FROM tab2
----
113
141
99

query I rowsort
SELECT DISTINCT col0 * + 60 + + col1 AS col2 FROM tab0
----
1526
2197
5431

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1395
SELECT ALL col1 + - CAST( 34 AS SIGNED ) * col2 AS col0 FROM tab0
----
-1036
-2697
63

skipif mysql # not compatible
query I rowsort label-1395
SELECT ALL col1 + - CAST ( 34 AS INTEGER ) * col2 AS col0 FROM tab0
----
-1036
-2697
63

query I rowsort
SELECT - tab1.col0 * 22 AS col2 FROM tab1
----
-1408
-1760
-66

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1398
SELECT DISTINCT + cor0.col1 + + ( col0 ) * + col1 + col0 DIV col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif mysql # not compatible
query I rowsort label-1398
SELECT DISTINCT + cor0.col1 + + ( col0 ) * + col1 + col0 / col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

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

query I rowsort
SELECT - col0 * col2 + + col0 * - col2 AS col2 FROM tab0 AS cor0
----
-14596
-1584
-70

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

query I rowsort
SELECT - cor0.col0 + - 96 + + col0 FROM tab0 AS cor0
----
-96
-96
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1403
SELECT DISTINCT - + 78 DIV 20 FROM tab1 AS cor0
----
-3

skipif mysql # not compatible
query I rowsort label-1403
SELECT DISTINCT - + 78 / 20 FROM tab1 AS cor0
----
-3

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 36 + 88 * col2 col0 FROM tab1
----
5376
5688
8916

query I rowsort
SELECT ( - col1 ) * + col0 * col1 + + col1 * + col1 AS col1 FROM tab0 cor0
----
-170108
-319906
-728728

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

query I rowsort
SELECT DISTINCT + col1 + - cor0.col1 * + col1 AS col1 FROM tab2 cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL - 66 - + col2 AS col1 FROM tab1 AS cor0
----
-120
-123
-162

query I rowsort
SELECT - + col0 + cor0.col0 * + 20 FROM tab0 AS cor0
----
1691
456
665

query I rowsort
SELECT ALL - col0 * col2 + ( 43 ) FROM tab2 cor0
----
-146
-1985
-2959

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1413
SELECT ALL + + 86 * col1 - - CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
1500
2693
5100

skipif mysql # not compatible
query I rowsort label-1413
SELECT ALL + + 86 * col1 - - CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
1500
2693
5100

query I rowsort
SELECT DISTINCT - 71 - col0 AS col0 FROM tab0 AS cor0
----
-106
-160
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + - col2 * + col2 col1 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT + 36 * cor0.col0 FROM tab1 AS cor0
----
108
2304
2880

query I rowsort
SELECT col2 * col2 - col2 * col2 AS col1 FROM tab2 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT ALL col0 * 92 * col0 FROM tab0 AS cor0
----
112700
52992
728732

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

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

query I rowsort
SELECT col2 + + col2 * 60 * col2 AS col2 FROM tab1
----
175014
194997
553056

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

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

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

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

query I rowsort
SELECT + - 22 + col2 * + col0 AS col1 FROM tab1 AS cor0
----
140
3626
7658

onlyif mysql # use DIV operator for integer division
query I rowsort label-1427
SELECT - 99 DIV 36 AS col2 FROM tab2
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-1427
SELECT - 99 / 36 AS col2 FROM tab2
----
-2
-2
-2

query I rowsort
SELECT - - 10 + cor0.col2 FROM tab2 cor0
----
36
37
48

query I rowsort
SELECT col0 - col0 * - col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT - cor0.col0 * col1 + + 3 AS col2 FROM tab2 cor0
----
-1340
-214
-4599

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1433
SELECT ALL 40 DIV tab1.col1 AS col1 FROM tab1
----
1
3
4

skipif mysql # not compatible
query I rowsort label-1433
SELECT ALL 40 / tab1.col1 AS col1 FROM tab1
----
1
3
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-1434
SELECT + col0 + + col1 DIV + ( + 93 ) + col2 DIV col0 col1 FROM tab0 AS cor0
----
25
36
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1434
SELECT + col0 + + col1 / + ( + 93 ) + col2 / col0 col1 FROM tab0 AS cor0
----
25
36
89

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

query I rowsort
SELECT - + 53 AS col1 FROM tab0, tab2 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 639c30ad80f8147eddb1a5f768a0a5ec

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1437
SELECT ALL col1 * - CAST( 7 AS SIGNED ) * col0 AS col0 FROM tab1
----
-4480
-546
-7280

skipif mysql # not compatible
query I rowsort label-1437
SELECT ALL col1 * - CAST ( 7 AS INTEGER ) * col0 AS col0 FROM tab1
----
-4480
-546
-7280

query I rowsort
SELECT + 58 + 0 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT ALL col0 * 63 + - col1 FROM tab0 AS cor0
----
1426
2108
5516

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

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

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

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

query I rowsort
SELECT ALL - 70 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

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

query I rowsort
SELECT ALL - + 38 * - col2 + - col0 - ( 89 ) * col2 * - col0 AS col0 FROM tab1 AS cor0
----
16467
326774
687088

query I rowsort
SELECT DISTINCT - 98 + + col2 FROM tab2 AS cor0
----
-60
-71
-72

query I rowsort
SELECT + 87 * col1 + - col1 FROM tab2 AS cor0
----
1462
2666
5074

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

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

query I rowsort
SELECT DISTINCT 25 * col1 * col1 AS col1 FROM tab0 AS cor0
----
184900
207025
235225

query I rowsort
SELECT ALL - ( cor0.col0 ) * + 58 + col2 AS col2 FROM tab2 AS cor0
----
-379
-4498
-4544

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1453
SELECT DISTINCT - - col0 - + col0 * - col1 DIV col1 AS col1 FROM tab1 AS cor0
----
128
160
6

skipif mysql # not compatible
query I rowsort label-1453
SELECT DISTINCT - - col0 - + col0 * - col1 / col1 AS col1 FROM tab1 AS cor0
----
128
160
6

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

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

query I rowsort
SELECT DISTINCT cor0.col0 * - col1 * col0 + - cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
-40390
-81952
1170

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

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

query I rowsort
SELECT + col1 * ( 13 + - col1 ) FROM tab0 AS cor0
----
-6278
-7098
-8148

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

query I rowsort
SELECT ALL + col2 + 2 * + col2 AS col0 FROM tab0 AS cor0
----
246
3
99

query I rowsort
SELECT ALL col0 + - 50 AS col2 FROM tab0 AS cor0
----
-15
-26
39

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

query I rowsort
SELECT DISTINCT 54 AS col0 FROM tab2 cor0
----
54

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

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

query I rowsort
SELECT DISTINCT - col0 + + 87 * + cor0.col1 FROM tab0 AS cor0
----
7458
7828
8404

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

skipif mysql # not compatible
query I rowsort label-1468
SELECT CAST ( 29 AS INTEGER ) * + col2 * col0 AS col2 FROM tab0 AS cor0
----
1015
211642
22968

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

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

query I rowsort
SELECT ALL + col1 * - col0 * + col0 AS col1 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT - tab1.col2 * + col1 + - 7 FROM tab1
----
-1255
-1411
-577

query IIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1 WHERE NOT NULL BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1474
SELECT DISTINCT + col1 + col1 * + col0 - - col1 * col1 DIV + 88 FROM tab1 AS cor0
----
1054
111
651

skipif mysql # not compatible
query I rowsort label-1474
SELECT DISTINCT + col1 + col1 * + col0 - - col1 * col1 / + 88 FROM tab1 AS cor0
----
1054
111
651

query I rowsort
SELECT ALL + cor0.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-1476
SELECT - - cor0.col1 * - CAST( col2 AS SIGNED ) - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

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

query I rowsort
SELECT DISTINCT - col0 + + col2 * col0 * col0 + + col2 AS col0 FROM tab2 AS cor0
----
1343
158132
237117

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

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

query I rowsort
SELECT - col1 * - col1 + - col2 * col0 AS col2 FROM tab0 AS cor0
----
6604
9374
983

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1481
SELECT ALL - col2 DIV + col0 + + 48 * col1 + 12 FROM tab2 AS cor0
----
1497
2844
828

skipif mysql # not compatible
query I rowsort label-1481
SELECT ALL - col2 / + col0 + + 48 * col1 + 12 FROM tab2 AS cor0
----
1497
2844
828

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1482
SELECT ALL - - col0 * CAST( 62 AS SIGNED ) + + col0 + col0 * + col1 * - col0 AS col0 FROM tab1 AS cor0
----
-36928
-45
-78160

skipif mysql # not compatible
query I rowsort label-1482
SELECT ALL - - col0 * CAST ( 62 AS INTEGER ) + + col0 + col0 * + col1 * - col0 AS col0 FROM tab1 AS cor0
----
-36928
-45
-78160

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

query I rowsort
SELECT + col2 * 15 FROM tab1 AS cor0
----
1440
810
855

query I rowsort
SELECT ALL + col2 * - ( col1 * - col1 ) + 67 FROM tab2 AS cor0
----
11049
26014
90573

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 38 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

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

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

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

query I rowsort
SELECT ALL cor1.col1 - - 64 FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to be08727196bb20aa17473feb7efe057e

skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 + CAST ( + col2 AS REAL ) * col1 AS col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT ALL + 69 * col1 * ( - 28 ) FROM tab1 AS cor0
----
-19320
-25116
-50232

query I rowsort
SELECT DISTINCT - 91 + col0 * + col1 AS col1 FROM tab0 AS cor0
----
1973
3304
8008

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col0 + - col2 + + 41 col0 FROM tab2 cor0
----
1346
231
4617

query I rowsort
SELECT DISTINCT 65 * + col0 * - col2 + cor0.col2 + - cor0.col2 * - col1 AS col0 FROM tab0 AS cor0
----
-2177
-466826
-48609

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

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

query I rowsort
SELECT DISTINCT + col0 + col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT + col1 * - col0 * ( + 24 ) FROM tab1 AS cor0
----
-15360
-1872
-24960

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

query I rowsort
SELECT ALL - col2 + col0 * + ( - 22 ) * col0 AS col2 FROM tab2 AS cor0
----
-1105
-133874
-137340

query I rowsort
SELECT ALL col0 + + col1 * - tab2.col2 - + col0 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT tab1.col0 * 90 AS col1 FROM tab1, tab2 AS cor0
----
270
5760
7200

query I rowsort
SELECT 77 + col0 + + 61 AS col2 FROM tab1
----
141
202
218

query I rowsort
SELECT ALL + 0 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - 12 + - col2 * - cor0.col1 col1 FROM tab0 AS cor0
----
109
3234
8446

query I rowsort
SELECT ALL 42 * - col1 * + col2 + + col2 FROM tab0
----
-119163
-313322
-4073

query I rowsort
SELECT DISTINCT + col0 * col2 + ( col1 * col2 ) FROM tab2
----
1026
3562
3648

query I rowsort
SELECT ALL col1 + - col0 * 86 * + 10 FROM tab0
----
-20554
-30003
-76449

query I rowsort
SELECT DISTINCT tab0.col0 * 22 AS col0 FROM tab0, tab1, tab0 AS cor0, tab2
----
1958
528
770

query I rowsort
SELECT DISTINCT col2 * col2 + col1 * - col1 AS col0 FROM tab2
----
-232
-2805
1155

query I rowsort
SELECT DISTINCT - col2 * + col0 + - col2 * - ( col1 ) * + ( col1 ) AS col2 FROM tab0
----
243276
671744
9374

onlyif mysql # use DIV operator for integer division
query I rowsort label-1514
SELECT col0 * col0 DIV - 31 AS col0 FROM tab1
----
-132
-206
0

skipif mysql # not compatible
query I rowsort label-1514
SELECT col0 * col0 / - 31 AS col0 FROM tab1
----
-132
-206
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - cor0.col2 - 79 col1 FROM tab0 AS cor0
----
-145
-243
-81

query I rowsort
SELECT + col2 + 91 * - col0 FROM tab2 cor0
----
-610
-7072
-7151

query I rowsort
SELECT col0 + 77 + + col2 * col2 * col2 AS col2 FROM tab0 AS cor0
----
113
36038
551534

query I rowsort
SELECT DISTINCT 98 + - 23 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
75

query I rowsort
SELECT 83 + 37 FROM tab2, tab2 AS cor0
----
9 values hashing to 9a76417a0e660b9e47db42d33f8268c3

query I rowsort
SELECT col0 * - 59 AS col2 FROM tab1
----
-177
-3776
-4720

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

query I rowsort
SELECT ALL tab1.col1 * 15 AS col1 FROM tab1
----
150
195
390

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 56 - + 71 col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 91b10a00c89b36b5bf0bed723e656ccc

query I rowsort
SELECT - 6 FROM tab0, tab1 AS cor0
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

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

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

query I rowsort
SELECT DISTINCT - + col0 * 42 AS col2 FROM tab2 AS cor0
----
-294
-3276
-3318

query I rowsort
SELECT DISTINCT - ( 71 ) + col0 FROM tab2 AS cor0
----
-64
7
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-1530
SELECT ALL 80 DIV col0 FROM tab2
----
1
1
11

skipif mysql # not compatible
query I rowsort label-1530
SELECT ALL 80 / col0 FROM tab2
----
1
1
11

query I rowsort
SELECT DISTINCT 55 * cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
-1925
-401390
-43560

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

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

query I rowsort
SELECT - 91 * + col2 AS col2 FROM tab1 AS cor0
----
-4914
-5187
-8736

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

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

query I rowsort
SELECT DISTINCT + - col0 + - col2 * 65 AS col2 FROM tab2 AS cor0
----
-1762
-1768
-2549

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

query I rowsort
SELECT + - 55 * col0 FROM tab2 AS cor0
----
-385
-4290
-4345

query I rowsort
SELECT 33 * col0 AS col0 FROM tab2 cor0
----
231
2574
2607

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

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

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

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

query I rowsort
SELECT - - 52 - col0 * col2 AS col1 FROM tab1 cor0
----
-110
-3596
-7628

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

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

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

query I rowsort
SELECT DISTINCT - 4 + - col2 AS col0 FROM tab1 AS cor0
----
-100
-58
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-1547
SELECT DISTINCT - 57 DIV - cor0.col2 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-1547
SELECT DISTINCT - 57 / - cor0.col2 FROM tab1 cor0
----
0
1

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

query I rowsort
SELECT ALL - col2 * cor0.col0 + + col1 * - col0 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT ALL 27 * - cor0.col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-213
-255
-648

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

query I rowsort
SELECT DISTINCT 23 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
598
621
874

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

skipif mysql # not compatible
query I rowsort label-1553
SELECT col2 / ( + col1 ) AS col0 FROM tab1
----
2
5
7

query I rowsort
SELECT col2 + col1 * 87 AS col1 FROM tab1 AS cor0
----
1227
2316
927

query I rowsort
SELECT - col2 + 34 + - col1 AS col0 FROM tab0 AS cor0
----
-139
-64
-85

query I rowsort
SELECT DISTINCT col2 + col2 * col2 - col1 * 24 AS col1 FROM tab1 AS cor0
----
2346
3066
9000

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1559
SELECT + tab2.col2 DIV + 31 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-1559
SELECT + tab2.col2 / + 31 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1560
SELECT col2 * - col1 * CAST( + col1 + col2 AS SIGNED ) FROM tab2
----
-130390
-35530
-48546

skipif mysql # not compatible
query I rowsort label-1560
SELECT col2 * - col1 * CAST ( + col1 + col2 AS INTEGER ) FROM tab2
----
-130390
-35530
-48546

query I rowsort
SELECT ALL col2 + + 49 AS col0 FROM tab0 AS cor0
----
131
50
82

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

query I rowsort
SELECT - 39 AS col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to a08a82dc9276c0173448e9a1c89dba93

query I rowsort
SELECT DISTINCT 6 * - tab1.col2 FROM tab1
----
-324
-342
-576

query I rowsort
SELECT 80 * col1 * - col0 AS col2 FROM tab0
----
-165120
-271600
-647920

onlyif mysql # use DIV operator for integer division
query I rowsort label-1566
SELECT + 36 DIV cor0.col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e25e25742ea53d2d8c3352d017bbe9b4

skipif mysql # not compatible
query I rowsort label-1566
SELECT + 36 / cor0.col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e25e25742ea53d2d8c3352d017bbe9b4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * - col0 col2 FROM tab0 AS cor0
----
-1225
-576
-7921

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1568
SELECT - col0 / + tab0.col0 + col1 col1 FROM tab0
----
85
90
96

query I rowsort
SELECT cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT DISTINCT - - 74 * col0 FROM tab0 AS cor0
----
1776
2590
6586

query I rowsort
SELECT + col0 + + 6 FROM tab2 AS cor0
----
13
84
85

query I rowsort
SELECT ALL - col1 + 74 * cor0.col2 FROM tab2 AS cor0
----
1865
1967
2795

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

query I rowsort
SELECT - ( - 55 ) FROM tab0 AS cor0
----
55
55
55

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1576
SELECT ( - 61 ) DIV col1 col2 FROM tab2 AS cor0
----
-1
-1
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1576
SELECT ( - 61 ) / col1 col2 FROM tab2 AS cor0
----
-1
-1
-3

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

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

query I rowsort
SELECT DISTINCT 8 + - 59 * - col2 AS col2 FROM tab2 AS cor0
----
1542
1601
2250

query I rowsort
SELECT DISTINCT 25 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
25

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

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

query I rowsort
SELECT + 22 AS col0 FROM tab1
----
22
22
22

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

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

skipif mysql # not compatible
query I rowsort label-1585
SELECT DISTINCT - tab2.col1 / + tab2.col1 FROM tab2
----
-1

query I rowsort
SELECT DISTINCT + col1 * 22 FROM tab0 AS cor0
----
1892
2002
2134

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

query I rowsort
SELECT ALL - 60 * col1 * - col2 FROM tab2 AS cor0
----
38760
50220
92040

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 * + 67 col0 FROM tab0
----
1608
2345
5963

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

query I rowsort
SELECT + - 74 * col1 FROM tab0 AS cor0
----
-6364
-6734
-7178

query I rowsort
SELECT - + col1 * cor0.col1 + - col0 * - cor0.col2 * - col1 FROM tab0 AS cor0
----
-12804
-672399
-75508

query I rowsort
SELECT - + 97 * - cor0.col0 + - 16 AS col2 FROM tab0 AS cor0
----
2312
3379
8617

query I rowsort
SELECT ALL col0 + col0 * 57 AS col0 FROM tab0
----
1392
2030
5162

query I rowsort
SELECT + cor0.col2 + + 65 * + 34 FROM tab1 AS cor0
----
2264
2267
2306

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

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

query I rowsort
SELECT - cor0.col0 FROM tab0, tab1 AS cor0 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT ALL + col0 * - 14 FROM tab2 AS cor0
----
-1092
-1106
-98

query I rowsort
SELECT col0 + - col1 + col2 AS col2 FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT ALL col2 * col1 + + cor0.col0 + cor0.col0 * 83 AS col0 FROM tab0 AS cor0
----
14938
3037
4854

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

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

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

skipif mysql # not compatible
query I rowsort label-1603
SELECT - col2 / ( cor0.col2 ) FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1604
SELECT - col2 * + ( col0 * col2 ) + ( col0 ) + col0 DIV col1 col0 FROM tab2 cor0
----
-113993
-5096
-52649

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1604
SELECT - col2 * + ( col0 * col2 ) + ( col0 ) + col0 / col1 col0 FROM tab2 cor0
----
-113993
-5096
-52649

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

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

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

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

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

query I rowsort
SELECT DISTINCT + col1 * col0 * cor0.col1 + - 53 FROM tab1 AS cor0
----
13467
1975
6347

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1613
SELECT DISTINCT + CAST ( col0 AS INTEGER ) FROM tab0 cor0
----
24
35
89

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

query I rowsort
SELECT DISTINCT + - cor0.col2 * 14 FROM tab0 AS cor0
----
-1148
-14
-462

onlyif mysql # use DIV operator for integer division
query I rowsort label-1616
SELECT ALL 40 * - col0 DIV col0 + + col1 FROM tab1
----
-14
-27
-30

skipif mysql # not compatible
query I rowsort label-1616
SELECT ALL 40 * - col0 / col0 + + col1 FROM tab1
----
-14
-27
-30

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

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

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

query I rowsort
SELECT + 73 + col1 + - col2 * 5 * + col2 AS col2 FROM tab1 AS cor0
----
-14481
-16162
-45994

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

query I rowsort
SELECT DISTINCT - 53 FROM tab0, tab0 AS cor0
----
-53

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

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

query I rowsort
SELECT DISTINCT col0 * col2 - 24 AS col2 FROM tab0 AS cor0
----
11
7274
768

query I rowsort
SELECT DISTINCT + + col1 + - 79 - - 43 FROM tab1 AS cor0
----
-10
-23
-26

query I rowsort
SELECT + 71 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT ALL - - cor0.col2 + - 93 AS col2 FROM tab2 AS cor0
----
-55
-66
-67

query I rowsort
SELECT ALL + + 86 * col0 + - cor0.col1 * + col2 AS col1 FROM tab1 cor0
----
-1146
4934
5632

query I rowsort
SELECT ALL + + col2 * col1 + + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT 10 + 90 FROM tab1 AS cor0
----
100
100
100

query I rowsort
SELECT + 81 FROM tab2 cor0
----
81
81
81

query I rowsort
SELECT ALL - 6 - col2 AS col2 FROM tab1 AS cor0
----
-102
-60
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-1633
SELECT DISTINCT col1 DIV 44 AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1633
SELECT DISTINCT col1 / 44 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - + col1 + col0 * + col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT 59 + col0 * col1 AS col0 FROM tab1 AS cor0
----
1099
137
699

query I rowsort
SELECT ALL + 10 + - col1 FROM tab0 cor0
----
-76
-81
-87

query I rowsort
SELECT ALL col2 * 45 + col1 AS col2 FROM tab1 AS cor0
----
2456
2575
4333

query I rowsort
SELECT DISTINCT col2 + 28 AS col1 FROM tab1 AS cor0
----
124
82
85

query I rowsort
SELECT col2 * + col2 + tab0.col1 FROM tab0
----
1175
6815
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 38 * ( - cor0.col2 ) col1 FROM tab2 cor0
----
-1026
-1444
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + ( ( + col1 ) ) col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT ( - col0 ) + col1 * col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT + + col1 * + col1 * + 49 FROM tab0 AS cor0
----
362404
405769
461041

query I rowsort
SELECT + 21 * col0 * + col2 FROM tab0 AS cor0
----
153258
16632
735

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 82 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1646
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab1, tab0, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1646
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab1, tab0, tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1647
SELECT ALL + CAST( NULL AS SIGNED ) * - col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1647
SELECT ALL + CAST ( NULL AS INTEGER ) * - col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( + 96 ) FROM tab0
----
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + col0 * ( - ( col0 ) ) FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL 32 * - col2 + - col2 + 93 * + tab2.col0 AS col1 FROM tab2
----
-240
6093
6396

query I rowsort
SELECT - cor0.col1 * + col1 * + col0 AS col2 FROM tab1 AS cor0
----
-13520
-2028
-6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-1653
SELECT ALL + 71 * col0 + + 72 DIV + col0 FROM tab2
----
507
5538
5609

skipif mysql # not compatible
query I rowsort label-1653
SELECT ALL + 71 * col0 + + 72 / + col0 FROM tab2
----
507
5538
5609

query I rowsort
SELECT - col0 + - col2 + - col0 FROM tab2
----
-182
-196
-41

onlyif mysql # use DIV operator for integer division
query I rowsort label-1655
SELECT ALL + col0 * + col1 + - 61 * + ( + tab1.col0 ) + + col2 DIV col2 FROM tab1
----
-104
-3263
-3839

skipif mysql # not compatible
query I rowsort label-1655
SELECT ALL + col0 * + col1 + - 61 * + ( + tab1.col0 ) + + col2 / col2 FROM tab1
----
-104
-3263
-3839

query I rowsort
SELECT tab0.col0 * + 73 AS col0 FROM tab0
----
1752
2555
6497

query I rowsort
SELECT DISTINCT 25 * - 20 FROM tab2, tab1 AS cor0
----
-500

query I rowsort
SELECT DISTINCT + col1 * + tab1.col2 AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - + 58 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-1660
SELECT - col1 + + col2 * - col1 + col1 DIV ( col0 ) AS col0 FROM tab2 AS cor0
----
-1593
-663
-864

skipif mysql # not compatible
query I rowsort label-1660
SELECT - col1 + + col2 * - col1 + col1 / ( col0 ) AS col0 FROM tab2 AS cor0
----
-1593
-663
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( - cor0.col1 ) col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-1662
SELECT ALL + - col2 DIV - 94 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1662
SELECT ALL + - col2 / - 94 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1663
SELECT ALL + col1 * - CAST( - col0 AS SIGNED ) FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-1663
SELECT ALL + col1 * - CAST ( - col0 AS INTEGER ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL + col2 * - col2 + + 3 AS col0 FROM tab1 cor0
----
-2913
-3246
-9213

query I rowsort
SELECT + - col0 * col1 + + ( - col0 ) + - 46 * + ( - col1 ) FROM tab1 AS cor0
----
-244
-522
1115

query I rowsort
SELECT + ( tab1.col0 ) FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - - col1 * col0 + - col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + 49 * + 44 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 8fdc33c0cb16c65282ea23d640e38438

query I rowsort
SELECT ALL + cor0.col1 + 8 FROM tab2 AS cor0
----
25
39
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1670
SELECT ALL + col1 * CAST( + col2 AS SIGNED ) + col0 * - cor0.col2 + - col2 col1 FROM tab2 AS cor0
----
-2394
-520
621

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1670
SELECT ALL + col1 * CAST ( + col2 AS INTEGER ) + col0 * - cor0.col2 + - col2 col1 FROM tab2 AS cor0
----
-2394
-520
621

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - cor0.col2 * col0 * 67 + col0 + CAST ( col0 AS REAL ) AS col1 FROM tab1 AS cor0
----
-10848
-244288
-514400

query I rowsort
SELECT + col0 * 45 AS col2 FROM tab2 AS cor0
----
315
3510
3555

query I rowsort
SELECT DISTINCT - col1 * 82 * 82 FROM tab2 AS cor0
----
-114308
-208444
-396716

query I rowsort
SELECT ALL + - col2 * col2 * col1 + col0 AS col2 FROM tab1 cor0
----
-119728
-32426
-75813

query I rowsort
SELECT + + col0 * 72 FROM tab0 AS cor0
----
1728
2520
6408

onlyif mysql # use DIV operator for integer division
query I rowsort label-1676
SELECT - 66 * - col0 + col0 DIV + col1 FROM tab0 AS cor0
----
1584
2310
5874

skipif mysql # not compatible
query I rowsort label-1676
SELECT - 66 * - col0 + col0 / + col1 FROM tab0 AS cor0
----
1584
2310
5874

query I rowsort
SELECT + col1 * 54 * col0 + ( + col1 ) AS col0 FROM tab1 AS cor0
----
34570
4238
56173

query I rowsort
SELECT + col0 + 77 FROM tab2 cor0
----
155
156
84

query I rowsort
SELECT - - col2 * - ( + col0 * + col1 + - col1 * - col2 ) FROM tab2 cor0
----
-159536
-28458
-75582

query I rowsort
SELECT DISTINCT 48 * col0 * + col2 FROM tab1 AS cor0
----
175104
368640
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-1681
SELECT DISTINCT + CAST( - col1 AS SIGNED ) DIV - col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1681
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) / - col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + col1 + - ( col0 ) AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + + 97 * - col2 FROM tab0 cor0
----
-3201
-7954
-97

query I rowsort
SELECT ( + col0 ) * col2 + col0 AS col1 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-1685
SELECT - col0 * 45 + - col1 DIV - cor0.col2 AS col1 FROM tab1 AS cor0
----
-135
-2880
-3600

skipif mysql # not compatible
query I rowsort label-1685
SELECT - col0 * 45 + - col1 / - cor0.col2 AS col1 FROM tab1 AS cor0
----
-135
-2880
-3600

query I rowsort
SELECT - col0 * - col1 * + col1 AS col0 FROM tab0 AS cor0
----
177504
329315
737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 76 * col1 col0 FROM tab2 cor0
----
1292
2356
4484

query I rowsort
SELECT DISTINCT - + cor0.col0 * col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL 4 FROM tab2, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1690
SELECT ALL + CAST( 19 AS SIGNED ) FROM tab0
----
19
19
19

skipif mysql # not compatible
query I rowsort label-1690
SELECT ALL + CAST ( 19 AS INTEGER ) FROM tab0
----
19
19
19

query I rowsort
SELECT ( col0 + + col2 * + 19 ) FROM tab1
----
1029
1147
1904

onlyif mysql # use DIV operator for integer division
query I rowsort label-1692
SELECT - col0 DIV - col0 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1692
SELECT - col0 / - col0 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + col2 col1 FROM tab0 cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col1 - + 68 col1 FROM tab2 AS cor0
----
1466
578
769

query I rowsort
SELECT - - cor0.col0 + - col1 * - 53 * - col1 FROM tab1 AS cor0
----
-35825
-5236
-8877

query I rowsort
SELECT ALL + + 81 * col1 FROM tab0 cor0
----
6966
7371
7857

query I rowsort
SELECT ALL - cor0.col1 * + col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + ( col1 ) AS col2 FROM tab0 cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 13 col2 FROM tab0, tab1, tab1 AS cor0, tab0 AS cor1
----
81 values hashing to b092e3fa17e78608cf120e97d1bfff67

query I rowsort
SELECT + col2 * 65 + tab0.col1 + col0 * - col1 AS col1 FROM tab0
----
-2678
-3233
167

query I rowsort
SELECT + col1 + - tab0.col1 * col0 * + 61 FROM tab0
----
-125818
-206998
-493948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1702
SELECT CAST( NULL AS SIGNED ) / - col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1702
SELECT CAST ( NULL AS INTEGER ) / - col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1703
SELECT ALL + col0 * cor0.col0 DIV col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-1703
SELECT ALL + col0 * cor0.col0 / col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1704
SELECT - + 52 + cor0.col1 + col1 DIV - col0 FROM tab1 AS cor0
----
-34
-39
-42

skipif mysql # not compatible
query I rowsort label-1704
SELECT - + 52 + cor0.col1 + col1 / - col0 FROM tab1 AS cor0
----
-34
-39
-42

query I rowsort
SELECT ALL 14 AS col2 FROM tab0 cor0
----
14
14
14

query I rowsort
SELECT ALL 53 * ( col2 * col0 ) FROM tab0
----
1855
386794
41976

query I rowsort
SELECT ALL - 78 + tab1.col0 FROM tab1
----
-14
-75
2

query I rowsort
SELECT - col1 + + col0 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT ( col2 ) * - col2 FROM tab1
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + col0 * - col0 + - col0 FROM tab1
----
-12
-4160
-6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-1712
SELECT - col2 DIV - 65 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1712
SELECT - col2 / - 65 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT cor0.col1 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * cor0.col0 + + col1 col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + ( + cor0.col1 ) - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1716
SELECT DISTINCT 20 DIV col0 + col1 col2 FROM tab2 AS cor0
----
17
33
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1716
SELECT DISTINCT 20 / col0 + col1 col2 FROM tab2 AS cor0
----
17
33
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1717
SELECT 32 - + col0 DIV + col2 FROM tab0 AS cor0
----
-3
31
32

skipif mysql # not compatible
query I rowsort label-1717
SELECT 32 - + col0 / + col2 FROM tab0 AS cor0
----
-3
31
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-1718
SELECT + col0 DIV 59 + tab2.col0 AS col0 FROM tab2
----
7
79
80

skipif mysql # not compatible
query I rowsort label-1718
SELECT + col0 / 59 + tab2.col0 AS col0 FROM tab2
----
7
79
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1719
SELECT DISTINCT 10 + col0 DIV col2 AS col2 FROM tab1
----
10
11

skipif mysql # not compatible
query I rowsort label-1719
SELECT DISTINCT 10 + col0 / col2 AS col2 FROM tab1
----
10
11

query I rowsort
SELECT cor1.col0 + + 65 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 6280b3dce166772fbff91b7245ddd680

query I rowsort
SELECT DISTINCT + col2 + + 59 FROM tab1
----
113
116
155

query I rowsort
SELECT ALL col2 + tab2.col1 * tab2.col1 FROM tab2
----
327
3507
988

query I rowsort
SELECT DISTINCT - ( + tab0.col2 * col1 ) + 24 FROM tab0
----
-2814
-73
-7438

query I rowsort
SELECT + 17 * - col1 FROM tab2
----
-1003
-289
-527

query I rowsort
SELECT ( + col1 ) * + col2 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + 34 * col1 + col1 * + ( + col0 ) + - col0 AS col0 FROM tab2
----
1264
1842
6530

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1727
SELECT CAST( NULL AS SIGNED ) * - tab0.col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1727
SELECT CAST ( NULL AS INTEGER ) * - tab0.col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1728
SELECT ALL ( - ( col0 ) ) + - ( ( + col1 ) ) * ( - 58 ) DIV - col0 AS col1 FROM tab1 AS cor0
----
-505
-73
-89

skipif mysql # not compatible
query I rowsort label-1728
SELECT ALL ( - ( col0 ) ) + - ( ( + col1 ) ) * ( - 58 ) / - col0 AS col1 FROM tab1 AS cor0
----
-505
-73
-89

query I rowsort
SELECT + cor0.col2 * - 8 + - col0 AS col2 FROM tab1 AS cor0
----
-435
-520
-848

query I rowsort
SELECT - cor0.col1 * 26 AS col1 FROM tab1 AS cor0
----
-260
-338
-676

query I rowsort
SELECT + col2 * - col2 * cor0.col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1732
SELECT DISTINCT + col2 + + CAST( - cor0.col0 AS SIGNED ) * col1 FROM tab1 AS cor0
----
-24
-583
-944

skipif mysql # not compatible
query I rowsort label-1732
SELECT DISTINCT + col2 + + CAST ( - cor0.col0 AS INTEGER ) * col1 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - cor0.col0 + - col2 * + col2 FROM tab1 cor0
----
-2919
-3313
-9296

skipif mysql # not compatible
query I rowsort
SELECT cor0.col1 * CAST ( + col2 AS REAL ) AS col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - - cor0.col2 * col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL 42 + - 74 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7106326ae056e78044adc0aef747ef08

query I rowsort
SELECT ALL 25 * col0 FROM tab0
----
2225
600
875

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2, tab0 AS cor3
----
3645 values hashing to 78077727601c056ad0d4f4c11c8daffb

onlyif mysql # use DIV operator for integer division
query I rowsort label-1739
SELECT ALL + col2 DIV ( + 98 + + col1 ) col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1739
SELECT ALL + col2 / ( + 98 + + col1 ) col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + cor0.col2 * + 73 * 50 FROM tab1 AS cor0
----
197100
208050
350400

query I rowsort
SELECT cor0.col2 * 85 * cor0.col0 FROM tab1 cor0
----
13770
310080
652800

query I rowsort
SELECT - cor0.col2 * + 26 AS col0 FROM tab2 AS cor0
----
-676
-702
-988

query I rowsort
SELECT ALL - ( - cor1.col2 ) FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT DISTINCT 78 * 0 FROM tab1, tab2 AS cor0
----
0

query I rowsort
SELECT ALL col1 + + 62 * col0 FROM tab0
----
1574
2267
5609

query I rowsort
SELECT ( ( - col1 ) * tab0.col0 ) + + col1 FROM tab0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-1747
SELECT DISTINCT + 68 * + col1 DIV col1 col1 FROM tab1
----
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1747
SELECT DISTINCT + 68 * + col1 / col1 col1 FROM tab1
----
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 41 * tab0.col2 col2 FROM tab0
----
1435
299218
32472

onlyif mysql # use DIV operator for integer division
query I rowsort label-1749
SELECT ALL 58 + + col2 DIV - cor0.col0 FROM tab0 AS cor0
----
57
58
58

skipif mysql # not compatible
query I rowsort label-1749
SELECT ALL 58 + + col2 / - cor0.col0 FROM tab0 AS cor0
----
57
58
58

query I rowsort
SELECT DISTINCT 14 * - tab1.col2 FROM tab1
----
-1344
-756
-798

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1751
SELECT DISTINCT + 38 + col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1751
SELECT DISTINCT + 38 + col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + 75 * cor0.col2 * + ( + col1 * col1 ) AS col1 FROM tab0 AS cor0
----
18305100
50928150
705675

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 30 * col2 col1 FROM tab0 AS cor0
----
-2460
-30
-990

query I rowsort
SELECT + + col1 * col2 * + col0 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT + col1 * + col2 + + cor0.col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + + 28 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
28

query I rowsort
SELECT - col1 * - cor0.col1 + 45 AS col0 FROM tab1 AS cor0
----
145
214
721

query I rowsort
SELECT - ( col0 ) + + col2 * 86 FROM tab1 AS cor0
----
4641
4838
8176

onlyif mysql # use DIV operator for integer division
query I rowsort label-1759
SELECT col1 DIV 19 AS col1 FROM tab2 AS cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-1759
SELECT col1 / 19 AS col1 FROM tab2 AS cor0
----
0
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-1760
SELECT ALL - col0 + CAST( - 78 AS SIGNED ) * - col0 DIV + col0 col1 FROM tab1 AS cor0
----
-2
14
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1760
SELECT ALL - col0 + CAST ( - 78 AS INTEGER ) * - col0 / + col0 col1 FROM tab1 AS cor0
----
-2
14
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-1761
SELECT + + col1 DIV - 34 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1761
SELECT + + col1 / - 34 FROM tab2 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1762
SELECT ALL - ( - 75 ) DIV col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-1762
SELECT ALL - ( - 75 ) / col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT ALL - ( + ( col1 ) ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT 79 FROM tab0, tab2 AS cor0
----
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1765
SELECT + 17 DIV + col0 - - cor0.col0 FROM tab1 cor0
----
64
8
80

skipif mysql # not compatible
query I rowsort label-1765
SELECT + 17 / + col0 - - cor0.col0 FROM tab1 cor0
----
64
8
80

query I rowsort
SELECT + + ( - 77 ) + + col0 FROM tab2 AS cor0
----
-70
1
2

query I rowsort
SELECT ( + col0 ) * col1 - - col1 AS col1 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT col0 * + 99 - - col0 FROM tab2 AS cor0
----
700
7800
7900

query I rowsort
SELECT - 53 * col0 AS col0 FROM tab2 AS cor0
----
-371
-4134
-4187

query I rowsort
SELECT col1 * col1 + - ( cor0.col2 ) * - col0 AS col0 FROM tab0 AS cor0
----
15579
8188
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 ) * col1 col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL - 10 AS col0 FROM tab2
----
-10
-10
-10

query I rowsort
SELECT ALL - tab0.col2 * + col0 AS col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + ( + 9 ) * - col1 FROM tab0
----
-774
-819
-873

query I rowsort
SELECT ALL + cor0.col0 AS col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL col2 * 41 FROM tab0 AS cor0
----
1353
3362
41

query I rowsort
SELECT DISTINCT - 50 AS col1 FROM tab0 AS cor0
----
-50

query I rowsort
SELECT + - 77 + + col1 FROM tab1 AS cor0
----
-51
-64
-67

query I rowsort
SELECT ALL - cor0.col2 + - col1 * col0 FROM tab1 cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT + - 12 FROM tab1 AS cor0
----
-12

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col2 AS REAL ) + col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT - + ( col0 ) * + cor0.col0 + ( - col1 ) FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT ALL + 94 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to d876bb0ae813b06a5ee497ecacf37ee6

query I rowsort
SELECT ALL - tab0.col1 * 85 + + 45 AS col1 FROM tab0
----
-7265
-7690
-8200

query I rowsort
SELECT + col1 * - col1 * col0 AS col0 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT - 57 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT ALL 17 * - col0 + col0 * col0 + ( + col1 ) * - col1 FROM tab1
----
-718
2908
4871

query I rowsort
SELECT + 99 - col1 FROM tab1
----
73
86
89

query I rowsort
SELECT ALL - - ( col2 ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - 13 * cor0.col2 + cor0.col0 AS col1 FROM tab1 cor0
----
-1168
-677
-699

onlyif mysql # use DIV operator for integer division
query I rowsort label-1791
SELECT - col1 DIV + tab1.col1 AS col1 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1791
SELECT - col1 / + tab1.col1 AS col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT - - ( - col0 ) + - col0 FROM tab2 AS cor0
----
-14
-156
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-1793
SELECT DISTINCT col2 - - tab1.col1 DIV col0 FROM tab1
----
57
62
96

skipif mysql # not compatible
query I rowsort label-1793
SELECT DISTINCT col2 - - tab1.col1 / col0 FROM tab1
----
57
62
96

query I rowsort
SELECT ALL tab0.col2 + cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 1b6920525e1810523fdee3171c929510

query I rowsort
SELECT DISTINCT + col1 - - tab0.col0 FROM tab0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1796
SELECT col0 / col0 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1796
SELECT col0 / col0 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1797
SELECT - col0 - ( col1 + col1 ) DIV + col0 AS col1 FROM tab0 cor0
----
-31
-40
-91

skipif mysql # not compatible
query I rowsort label-1797
SELECT - col0 - ( col1 + col1 ) / + col0 AS col1 FROM tab0 cor0
----
-31
-40
-91

query I rowsort
SELECT - col2 * - col2 + + col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT col0 * - ( + col1 ) + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1800
SELECT ALL + CAST( NULL AS SIGNED ) * 44 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1800
SELECT ALL + CAST ( NULL AS INTEGER ) * 44 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT DISTINCT - + 78 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-78

query I rowsort
SELECT - - col2 + col1 * col2 * col0 AS col2 FROM tab1 AS cor0
----
36537
4266
99936

onlyif mysql # use DIV operator for integer division
query I rowsort label-1804
SELECT ALL + col1 DIV - col1 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1804
SELECT ALL + col1 / - col1 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + cor0.col1 * ( col2 ) + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT + col0 * + ( col0 * col1 ) AS col0 FROM tab0 cor0
----
118825
49536
720811

query I rowsort
SELECT - + col0 + - 61 + - 80 AS col2 FROM tab1 AS cor0
----
-144
-205
-221

query I rowsort
SELECT col0 + + col0 AS col0 FROM tab1 cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1809
SELECT DISTINCT - col0 * - CAST( + cor0.col1 AS SIGNED ) FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-1809
SELECT DISTINCT - col0 * - CAST ( + cor0.col1 AS INTEGER ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT col1 + - col2 + - col1 * + col0 AS col2 FROM tab0 AS cor0
----
-2011
-3299
-8090

query I rowsort
SELECT ALL col2 + ( - cor0.col0 ) * col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT - col0 + - ( col2 ) * + col0 FROM tab0 AS cor0
----
-70
-7387
-816

onlyif mysql # use DIV operator for integer division
query I rowsort label-1813
SELECT - col1 DIV + 53 FROM tab2
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1813
SELECT - col1 / + 53 FROM tab2
----
-1
0
0

query I rowsort
SELECT tab2.col2 + col0 * col2 + col0 FROM tab2
----
2132
223
3119

query I rowsort
SELECT col2 + 24 + col2 FROM tab2
----
100
76
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 27 col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT + col1 + cor0.col2 * - col0 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - col0 * - col0 + + col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - + cor0.col1 * col2 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + + col0 * col2 + + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL - + col0 * - col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1822
SELECT ALL + CAST( NULL AS SIGNED ) + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1822
SELECT ALL + CAST ( NULL AS INTEGER ) + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 5 * 22 + + col0 AS col0 FROM tab2 AS cor0
----
117
188
189

query I rowsort
SELECT ALL + col0 + - 59 FROM tab0 AS cor0
----
-24
-35
30

query I rowsort
SELECT 36 + 82 FROM tab0 AS cor0
----
118
118
118

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1826
SELECT ALL + CAST( col0 AS SIGNED ) FROM tab2 cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-1826
SELECT ALL + CAST ( col0 AS INTEGER ) FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col0 * col1 - col2 AS col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT col1 * + col2 - col1 * cor0.col2 * 15 FROM tab0 AS cor0
----
-104468
-1358
-39732

query I rowsort
SELECT DISTINCT + col1 + col1 * col0 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - cor0.col2 + - 0 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( 46 AS REAL ) AS col0 FROM tab0 AS cor0
----
-46
-46
-46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 98 + col2 col1 FROM tab2 cor0
----
-60
-71
-72

query I rowsort
SELECT col2 * - col0 + + col0 * + col1 FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT ALL - - col2 * col0 + col0 + col0 * + col0 FROM tab0 AS cor0
----
1295
1392
15308

onlyif mysql # use DIV operator for integer division
query I rowsort label-1835
SELECT DISTINCT + col0 * tab1.col1 * + col1 + + col0 DIV 90 FROM tab1
----
13520
2028
6400

skipif mysql # not compatible
query I rowsort label-1835
SELECT DISTINCT + col0 * tab1.col1 * + col1 + + col0 / 90 FROM tab1
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + ( 42 ) FROM tab2 AS cor0
----
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1838
SELECT CAST( - col0 AS SIGNED ) AS col0 FROM tab2 cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-1838
SELECT CAST ( - col0 AS INTEGER ) AS col0 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1839
SELECT + + col0 * - 23 + col2 DIV + ( 27 * - col0 ) AS col1 FROM tab0 AS cor0
----
-2047
-552
-805

skipif mysql # not compatible
query I rowsort label-1839
SELECT + + col0 * - 23 + col2 / + ( 27 * - col0 ) AS col1 FROM tab0 AS cor0
----
-2047
-552
-805

query I rowsort
SELECT ALL - ( + col0 ) + - col0 AS col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT + col0 * col0 + + col1 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT ( col0 ) + - ( col1 ) * + col1 FROM tab2 AS cor0
----
-210
-3403
-954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 4 col1 FROM tab2 cor0
----
4

query I rowsort
SELECT - 67 + - cor0.col1 * ( col1 + + col1 ) * + col0 AS col1 FROM tab1 cor0
----
-12867
-27107
-4123

query I rowsort
SELECT DISTINCT col0 * + col0 + 95 AS col2 FROM tab0 AS cor0
----
1320
671
8016

query I rowsort
SELECT ALL + col1 - col0 * cor0.col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT + ( 16 ) * col1 AS col0 FROM tab2
----
272
496
944

query I rowsort
SELECT DISTINCT ( + cor0.col0 ) - + 61 FROM tab0, tab2 cor0
----
-54
17
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-1849
SELECT ALL - - col1 DIV + col2 + 61 * col1 FROM tab0 cor0
----
5248
5552
6014

skipif mysql # not compatible
query I rowsort label-1849
SELECT ALL - - col1 / + col2 + 61 * col1 FROM tab0 cor0
----
5248
5552
6014

query I rowsort
SELECT + 57 * + col2 AS col1 FROM tab2 AS cor0
----
1482
1539
2166

query I rowsort
SELECT DISTINCT - - 90 + col2 * - ( - col2 ) - col2 AS col1 FROM tab1 AS cor0
----
2952
3282
9210

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1852
SELECT DISTINCT - col2 * cor0.col2 + + CAST( col1 AS SIGNED ) * - col0 * col2 AS col1 FROM tab2 AS cor0
----
-120328
-52478
-6588

skipif mysql # not compatible
query I rowsort label-1852
SELECT DISTINCT - col2 * cor0.col2 + + CAST ( col1 AS INTEGER ) * - col0 * col2 AS col1 FROM tab2 AS cor0
----
-120328
-52478
-6588

query I rowsort
SELECT ALL col0 * col2 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL - - col1 + ( - col0 ) FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT col1 + + 88 + - ( col0 + 78 ) FROM tab0 AS cor0
----
12
72

query I rowsort
SELECT ALL - col1 - - col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 * cor0.col1 * col0 + - col1 * col2 * + col0 AS col2 FROM tab2 AS cor0
----
-4340
239304
55063

query I rowsort
SELECT DISTINCT + cor0.col2 * + 73 - - col0 FROM tab2 cor0
----
1976
1978
2853

query I rowsort
SELECT + col2 + - col0 * + col2 * col2 FROM tab2
----
-114038
-5076
-52702

onlyif mysql # use DIV operator for integer division
query I rowsort label-1860
SELECT DISTINCT + col2 DIV + col1 AS col0 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-1860
SELECT DISTINCT + col2 / + col1 AS col0 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT - - col1 * + col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + col1 * col2 + cor0.col0 AS col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL - col2 * cor0.col2 + cor0.col2 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-1327
-572
-695

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL NOT IN ( col2 * - col1 - + col1 ) OR NOT NULL IN ( col2 )
----

query I rowsort
SELECT DISTINCT + - cor0.col0 + + col0 * col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL + col0 + - col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT + col1 + - col2 + - cor0.col2 FROM tab1 cor0
----
-104
-179
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 col0 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT + col2 * + col0 * - cor0.col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT + + col0 + + col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + tab0.col1 FROM tab0 WHERE NOT ( NULL ) <> NULL
----

query I rowsort
SELECT ALL cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT tab1.col1 * col2 + tab1.col2 AS col2 FROM tab1
----
1344
1458
627

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL IN ( + col2 )
----

query I rowsort
SELECT cor0.col1 * cor0.col2 + col2 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * - col0 - col2 col0 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT DISTINCT - col2 * col1 + col0 * + col0 AS col1 FROM tab0 AS cor0
----
-2262
1128
459

onlyif mysql # use DIV operator for integer division
query I rowsort label-1878
SELECT + col1 + + col0 DIV col2 AS col0 FROM tab0 AS cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-1878
SELECT + col1 + + col0 / col2 AS col0 FROM tab0 AS cor0
----
132
86
92

query I rowsort
SELECT ALL + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL 31 * - col1 + tab2.col0 AS col2 FROM tab2
----
-1751
-448
-954

query I rowsort
SELECT DISTINCT - col1 * - col2 * col1 - col1 AS col1 FROM tab2
----
10965
25916
90447

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT col1 * + col2 * - col1 + col2 FROM tab1
----
-16128
-36450
-5643

query I rowsort
SELECT DISTINCT tab2.col0 * col0 * col0 AS col2 FROM tab2
----
343
474552
493039

onlyif mysql # use DIV operator for integer division
query I rowsort label-1885
SELECT ALL col1 DIV tab0.col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1885
SELECT ALL col1 / tab0.col1 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT col2 + col1 * + col1 FROM tab2
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col2 + - col2 col0 FROM tab0
----
34
7216
759

query I rowsort
SELECT DISTINCT col1 * - col1 - col1 FROM tab1
----
-110
-182
-702

query I rowsort
SELECT ALL col0 * - col0 AS col1 FROM tab2
----
-49
-6084
-6241

query III rowsort
SELECT * FROM tab1 WHERE ( col2 * col2 * + col2 ) IN ( col0 * tab1.col0 + + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1891
SELECT col2 + + col0 DIV col0 AS col0 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-1891
SELECT col2 + + col0 / col0 AS col0 FROM tab0
----
2
34
83

query III rowsort
SELECT * FROM tab2 WHERE NOT + col2 / col0 > - col2 * + col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1893
SELECT + col0 + col0 DIV + cor0.col2 + - cor0.col1 DIV col1 FROM tab0 AS cor0
----
23
69
89

skipif mysql # not compatible
query I rowsort label-1893
SELECT + col0 + col0 / + cor0.col2 + - cor0.col1 / col1 FROM tab0 AS cor0
----
23
69
89

query I rowsort
SELECT - col0 + - cor0.col0 * - col0 + + 10 AS col2 FROM tab2 AS cor0
----
52
6016
6172

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col0 * col0 * - col1 col2 FROM tab2
----
106059
1492
358930

query I rowsort
SELECT - col0 AS col1 FROM tab2 WHERE NULL NOT BETWEEN NULL AND col1 + - col2 / + col2
----

query I rowsort
SELECT DISTINCT + col1 * - col0 + col0 FROM tab2
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-1898
SELECT DISTINCT - col0 + col2 DIV + col0 AS col1 FROM tab1
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-1898
SELECT DISTINCT - col0 + col2 / + col0 AS col1 FROM tab1
----
-64
-79
15

query I rowsort
SELECT + col2 - - col1 * col2 AS col2 FROM tab1
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-1900
SELECT ALL col2 DIV col0 col2 FROM tab1
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1900
SELECT ALL col2 / col0 col2 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT col1 + - col1 * - col2 - col0 FROM tab2
----
1515
584
861

onlyif mysql # use DIV operator for integer division
query I rowsort label-1902
SELECT col0 + + col1 * col0 + col0 DIV - col0 AS col1 FROM tab2
----
1421
223
4679

skipif mysql # not compatible
query I rowsort label-1902
SELECT col0 + + col1 * col0 + col0 / - col0 AS col1 FROM tab2
----
1421
223
4679

onlyif mysql # use DIV operator for integer division
query I rowsort label-1903
SELECT col1 * col1 DIV - col0 FROM tab1
----
-1
-2
-225

skipif mysql # not compatible
query I rowsort label-1903
SELECT col1 * col1 / - col0 FROM tab1
----
-1
-2
-225

onlyif mysql # use DIV operator for integer division
query I rowsort label-1904
SELECT ALL tab2.col2 DIV + col0 AS col1 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-1904
SELECT ALL tab2.col2 / + col0 AS col1 FROM tab2
----
0
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-1905
SELECT ALL col1 DIV tab0.col1 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1905
SELECT ALL col1 / tab0.col1 AS col0 FROM tab0
----
1
1
1

query I rowsort
SELECT + col0 * col0 + - col0 + - col0 * - col2 FROM tab1
----
14000
168
7680

query I rowsort
SELECT col1 * col2 + col1 + col2 AS col1 FROM tab0
----
195
2957
7635

query I rowsort
SELECT DISTINCT col2 FROM tab0 WHERE NOT ( - col0 ) IN ( col2 / col1 + col2 / col1 )
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1909
SELECT + tab0.col2 - - col0 DIV col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1909
SELECT + tab0.col2 - - col0 / col1 FROM tab0
----
1
33
82

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT IN ( - col2 * col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1911
SELECT DISTINCT - col0 DIV + col0 AS col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-1911
SELECT DISTINCT - col0 / + col0 AS col0 FROM tab0
----
-1

query I rowsort
SELECT - col2 + col1 * col0 * - tab0.col1 + col1 AS col1 FROM tab0
----
-177451
-329219
-737000

query I rowsort
SELECT + col1 - col2 AS col2 FROM tab2 WHERE NOT NULL IN ( col0 )
----

query I rowsort
SELECT ALL - tab1.col2 * col2 AS col0 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT col1 + + col2 AS col1 FROM tab0 WHERE ( NULL ) NOT IN ( - col1 * col0 * + col2 + + col1 / - col2 + col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 col1 FROM tab1 WHERE NOT ( NULL ) IN ( col1 )
----

query I rowsort
SELECT cor0.col2 + col2 * col0 AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL + + col2 * + cor0.col2 + + col1 AS col0 FROM tab2 cor0
----
1461
735
760

query I rowsort
SELECT ALL - + col2 + + col0 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT 68 * col1 + 5 AS col0 FROM tab2 cor0
----
1161
2113
4017

query I rowsort
SELECT DISTINCT cor0.col2 * + col1 + col0 + + col1 * col1 FROM tab1 AS cor0
----
1497
2083
734

query I rowsort
SELECT - col0 * + col0 * + 37 + + col0 * col0 FROM tab1 AS cor0
----
-147456
-230400
-324

onlyif mysql # use DIV operator for integer division
query I rowsort label-1923
SELECT ALL col2 * + col1 + - col0 DIV + cor0.col0 - - col1 col0 FROM tab1 AS cor0
----
1260
1429
579

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1923
SELECT ALL col2 * + col1 + - col0 / + cor0.col0 - - col1 col0 FROM tab1 AS cor0
----
1260
1429
579

query I rowsort
SELECT ALL - 68 * - col0 FROM tab2
----
476
5304
5372

query I rowsort
SELECT DISTINCT + ( col1 + - col0 ) * ( tab0.col2 ) AS col1 FROM tab0
----
164
2046
62

query I rowsort
SELECT - cor0.col1 * col2 + cor0.col2 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL - col0 * + col1 * - col1 FROM tab2 cor0
----
22831
271518
6727

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-1929
SELECT + col0 * tab2.col2 DIV + 69 + 36 * + col1 FROM tab2
----
1118
2153
655

skipif mysql # not compatible
query I rowsort label-1929
SELECT + col0 * tab2.col2 / + 69 + 36 * + col1 FROM tab2
----
1118
2153
655

query I rowsort
SELECT - col1 + + col0 * col2 + col1 AS col0 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1931
SELECT DISTINCT col0 + col2 DIV col0 AS col1 FROM tab1
----
21
64
81

skipif mysql # not compatible
query I rowsort label-1931
SELECT DISTINCT col0 + col2 / col0 AS col1 FROM tab1
----
21
64
81

query I rowsort
SELECT - ( - tab1.col2 ) * col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + 80 + - col0 AS col1 FROM tab1
----
0
16
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1934
SELECT ALL + CAST( NULL AS SIGNED ) + + 59 * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1934
SELECT ALL + CAST ( NULL AS INTEGER ) + + 59 * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( - 82 ) AS col2 FROM tab1 AS cor0
----
-82

query I rowsort
SELECT - + ( 92 ) FROM tab1 AS cor0
----
-92
-92
-92

query I rowsort
SELECT DISTINCT col2 + + col1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT ( col2 ) * + col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1939
SELECT - CAST( NULL AS SIGNED ) + + ( + col0 ) * 17 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1939
SELECT - CAST ( NULL AS INTEGER ) + + ( + col0 ) * 17 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1940
SELECT - - col0 DIV col0 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1940
SELECT - - col0 / col0 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT col1 * - 61 * + col2 FROM tab0 cor0
----
-173118
-455182
-5917

query I rowsort
SELECT ALL 27 * 57 + + cor0.col0 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 0cf9ff77ca2bada707e7d51010580bef

onlyif mysql # use DIV operator for integer division
query I rowsort label-1943
SELECT DISTINCT + tab2.col0 DIV - 37 AS col2 FROM tab2
----
-2
0

skipif mysql # not compatible
query I rowsort label-1943
SELECT DISTINCT + tab2.col0 / - 37 AS col2 FROM tab2
----
-2
0

query I rowsort
SELECT + 56 * 98 FROM tab2
----
5488
5488
5488

query I rowsort
SELECT - - cor0.col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL + 8 - tab0.col0 FROM tab0
----
-16
-27
-81

query I rowsort
SELECT + + ( + 5 ) * + col0 FROM tab0 AS cor0
----
120
175
445

onlyif mysql # use DIV operator for integer division
query I rowsort label-1948
SELECT ( 50 ) DIV - col2 FROM tab0 AS cor0
----
-1
-50
0

skipif mysql # not compatible
query I rowsort label-1948
SELECT ( 50 ) / - col2 FROM tab0 AS cor0
----
-1
-50
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col2 col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + - 17 * col0 * col1 FROM tab2 AS cor0
----
-22831
-3689
-78234

query I rowsort
SELECT + col1 + + 72 AS col0 FROM tab0 AS cor0
----
158
163
169

query I rowsort
SELECT ALL - 15 AS col1 FROM tab0
----
-15
-15
-15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 35 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT ALL - 97 * - col0 FROM tab2
----
679
7566
7663

query I rowsort
SELECT ALL + ( + 44 + - col2 * + col1 ) FROM tab1
----
-1204
-1360
-526

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1956
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * 1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1956
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * 1 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1957
SELECT DISTINCT - CAST( NULL AS DECIMAL ) / + col2 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1957
SELECT DISTINCT - CAST ( NULL AS REAL ) / + col2 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT 89 + col0 FROM tab2
----
167
168
96

query I rowsort
SELECT col1 * + col0 + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL col2 + col0 * col0 * col1 AS col2 FROM tab2 cor0
----
106135
1546
358982

query I rowsort
SELECT DISTINCT - 37 + col2 AS col2 FROM tab0 AS cor0
----
-36
-4
45

query I rowsort
SELECT - col1 * - cor0.col1 - col0 AS col1 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT DISTINCT - 89 * + col0 AS col1 FROM tab0 AS cor0
----
-2136
-3115
-7921

query I rowsort
SELECT ALL - - col1 * col2 + + cor0.col0 + col1 AS col0 FROM tab2 AS cor0
----
1671
742
875

query I rowsort
SELECT DISTINCT - 76 AS col2 FROM tab0 AS cor0
----
-76

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 + col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-1967
SELECT col2 + + col0 DIV col0 AS col1 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1967
SELECT col2 + + col0 / col0 AS col1 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT + col1 + col0 * col2 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - col2 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT col1 + - col1 * - cor0.col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + + col0 + col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL - + 91 * - cor0.col2 FROM tab0 AS cor0
----
3003
7462
91

query I rowsort
SELECT - 25 FROM tab2 cor0
----
-25
-25
-25

query I rowsort
SELECT DISTINCT cor0.col2 + col1 * col2 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - cor0.col1 * ( col1 ) + + col0 col2 FROM tab1 AS cor0
----
-17573
-2117
-936

query I rowsort
SELECT DISTINCT col1 + tab1.col1 * col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT 71 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT - col0 * 2 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT ALL col0 + 95 FROM tab2 AS cor0
----
102
173
174

query I rowsort
SELECT ALL - col2 * + ( col0 ) * - col2 + cor0.col2 FROM tab1 AS cor0
----
207993
737376
8802

query I rowsort
SELECT DISTINCT - col1 + col2 * col0 AS col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT col1 * - col2 + + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL + col0 + - cor0.col1 * - col1 * + col2 AS col1 FROM tab1 AS cor0
----
16304
36507
5764

query I rowsort
SELECT DISTINCT + + cor0.col2 * + ( 58 ) * col2 - + col0 FROM tab1 AS cor0
----
169125
188378
534448

query I rowsort
SELECT DISTINCT - col0 - - 47 AS col1 FROM tab2 AS cor0
----
-31
-32
40

query I rowsort
SELECT DISTINCT - col0 + col1 * - col0 AS col2 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL + col0 * col0 + - cor0.col2 FROM tab2 AS cor0
----
22
6058
6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1988
SELECT + CAST( - col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-1988
SELECT + CAST ( - col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + col0 + - 91 FROM tab2 AS cor0
----
-12
-13
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-1990
SELECT DISTINCT + + col2 + col2 DIV col2 AS col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-1990
SELECT DISTINCT + + col2 + col2 / col2 AS col2 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT DISTINCT col2 + + 18 * col2 FROM tab2 cor0
----
494
513
722

query I rowsort
SELECT DISTINCT 7 AS col2 FROM tab0, tab2 AS cor0
----
7

query I rowsort
SELECT ALL cor0.col0 * col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1994
SELECT ALL + CAST( NULL AS DECIMAL ) * 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-1994
SELECT ALL + CAST ( NULL AS REAL ) * col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1997
SELECT + cor0.col0 * col0 DIV + col0 col0 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1997
SELECT + cor0.col0 * col0 / + col0 col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - col2 * - col1 + + 44 + col1 FROM tab0 AS cor0
----
238
2968
7597

query I rowsort
SELECT col2 * + col0 + + 30 AS col2 FROM tab2 AS cor0
----
2058
219
3032

query I rowsort
SELECT ALL + col0 * - col0 + 91 AS col2 FROM tab1 cor0
----
-4005
-6309
82

query I rowsort
SELECT + cor0.col2 * col2 + 10 FROM tab0 AS cor0
----
1099
11
6734

query I rowsort
SELECT ALL col1 * 61 AS col2 FROM tab1
----
1586
610
793

query I rowsort
SELECT + ( col0 ) * col0 + + 29 FROM tab0 AS cor0
----
1254
605
7950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2004
SELECT DISTINCT - col0 * 15 + col1 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2004
SELECT DISTINCT - col0 * 15 + col1 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - - col2 + 96 + col0 AS col2 FROM tab2 AS cor0
----
130
200
213

onlyif mysql # use DIV operator for integer division
query I rowsort label-2006
SELECT col0 + - col0 DIV + col0 + - col1 AS col0 FROM tab2 AS cor0
----
-25
18
61

skipif mysql # not compatible
query I rowsort label-2006
SELECT col0 + - col0 / + col0 + - col1 AS col0 FROM tab2 AS cor0
----
-25
18
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-2007
SELECT + col1 + - col0 + col0 DIV 48 FROM tab2 AS cor0
----
-18
-61
24

skipif mysql # not compatible
query I rowsort label-2007
SELECT + col1 + - col0 + col0 / 48 FROM tab2 AS cor0
----
-18
-61
24

query I rowsort
SELECT 22 * - col2 + - col2 FROM tab0 AS cor0
----
-1886
-23
-759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2009
SELECT ALL + col1 * - col0 + + CAST( + cor0.col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif mysql # not compatible
query I rowsort label-2009
SELECT ALL + col1 * - col0 + + CAST ( + cor0.col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 96 - + cor0.col2 * + col0 * ( col0 + + col0 ) col0 FROM tab0 AS cor0
----
-1298948
-2354
-37920

query I rowsort
SELECT ALL - 91 + - cor0.col0 * + ( - col2 ) FROM tab0 AS cor0
----
-56
701
7207

query I rowsort
SELECT ALL 62 * col0 - col2 FROM tab2 AS cor0
----
407
4810
4860

onlyif mysql # use DIV operator for integer division
query I rowsort label-2013
SELECT ALL - ( + cor0.col1 ) DIV + cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2013
SELECT ALL - ( + cor0.col1 ) / + cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2014
SELECT DISTINCT col0 + + col1 DIV + 60 AS col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2014
SELECT DISTINCT col0 + + col1 / + 60 AS col0 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col2 * + tab2.col1 + - col0 col1 FROM tab2
----
1456
567
830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 48 col0 FROM tab2 AS cor0
----
-48
-48
-48

query I rowsort
SELECT DISTINCT - + 9 AS col2 FROM tab0 AS cor0
----
-9

query I rowsort
SELECT - + col1 * + col1 * col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT + - col2 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + cor0.col1 * + col0 col2 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT col0 * cor0.col0 - col1 AS col2 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT - col1 * - col0 - 78 * col1 AS col0 FROM tab1 AS cor0
----
-140
-1950
26

query I rowsort
SELECT - - col2 + 55 AS col1 FROM tab0 AS cor0
----
137
56
88

query I rowsort
SELECT - - col0 + + 53 * + col2 AS col1 FROM tab2 AS cor0
----
1438
1456
2093

query I rowsort
SELECT + - col2 * + col0 - + ( - col2 ) AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT + tab0.col0 - ( + 49 ) * col1 FROM tab0
----
-4190
-4370
-4718

query I rowsort
SELECT + col2 + 90 AS col1 FROM tab0 AS cor0
----
123
172
91

query I rowsort
SELECT + col0 * cor0.col0 + + col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT + col2 + + ( cor0.col0 ) AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - + col2 * 16 FROM tab2 AS cor0
----
-416
-432
-608

onlyif mysql # use DIV operator for integer division
query I rowsort label-2031
SELECT ALL - cor0.col0 * col0 + - col2 DIV - col0 + + 54 AS col2 FROM tab2 AS cor0
----
-6030
-6187
8

skipif mysql # not compatible
query I rowsort label-2031
SELECT ALL - cor0.col0 * col0 + - col2 / - col0 + + 54 AS col2 FROM tab2 AS cor0
----
-6030
-6187
8

query I rowsort
SELECT DISTINCT col2 - - col0 * col2 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query IIIIIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1, tab2 AS cor2, tab0
----
13122 values hashing to 5beaeefe064dbc70ad1565b5520b2d04

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2034
SELECT - CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2034
SELECT - CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + - ( + 49 ) AS col2 FROM tab2 cor0
----
-49
-49
-49

onlyif mysql # use DIV operator for integer division
query I rowsort label-2036
SELECT ALL - col2 - col1 DIV col0 FROM tab0 AS cor0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-2036
SELECT ALL - col2 - col1 / col0 FROM tab0 AS cor0
----
-3
-36
-83

query I rowsort
SELECT DISTINCT 18 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
18

query I rowsort
SELECT DISTINCT - 55 * 90 AS col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
-4950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2039
SELECT - CAST( - col2 AS SIGNED ) + col0 FROM tab1
----
121
176
57

skipif mysql # not compatible
query I rowsort label-2039
SELECT - CAST ( - col2 AS INTEGER ) + col0 FROM tab1
----
121
176
57

query I rowsort
SELECT 60 * + cor0.col2 FROM tab1 AS cor0
----
3240
3420
5760

query I rowsort
SELECT - 87 * + col1 * col1 AS col0 FROM tab1
----
-14703
-58812
-8700

query I rowsort
SELECT ALL 12 AS col2 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT ALL 10 + 29 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT ALL - cor0.col2 + - ( cor1.col1 ) * + tab2.col0 AS col1 FROM tab2, tab0 cor0, tab2 cor1
----
27 values hashing to 651190aaaa3e82fffb3c591b97268fb6

query I rowsort
SELECT + col1 * col2 - - col1 * + tab0.col0 FROM tab0
----
15561
3492
4902

query I rowsort
SELECT ALL 83 * + 23 + cor0.col0 FROM tab1 AS cor0
----
1912
1973
1989

onlyif mysql # use DIV operator for integer division
query I rowsort label-2047
SELECT DISTINCT + + 44 + + 12 DIV - col1 AS col1 FROM tab2 cor0
----
44

skipif mysql # not compatible
query I rowsort label-2047
SELECT DISTINCT + + 44 + + 12 / - col1 AS col1 FROM tab2 cor0
----
44

query I rowsort
SELECT ALL col2 * + col2 * + ( - col2 ) + - col0 AS col1 FROM tab2 AS cor0
----
-17654
-19690
-54951

query I rowsort
SELECT ALL - - 44 + col0 AS col2 FROM tab2 AS cor0
----
122
123
51

query I rowsort
SELECT + col0 * - col1 + - col0 AS col2 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT + ( col0 * col1 ) FROM tab1
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2052
SELECT + CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2052
SELECT + CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col1 * col2 + 13 FROM tab2 cor0
----
1547
659
850

query I rowsort
SELECT + col1 + - 27 AS col2 FROM tab0 AS cor0
----
59
64
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2055
SELECT - cor0.col1 + + CAST( NULL AS SIGNED ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2055
SELECT - cor0.col1 + + CAST ( NULL AS INTEGER ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + - ( + col1 ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * - col1 AS col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + 96 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0, tab2 AS cor2
----
96

query I rowsort
SELECT DISTINCT - ( col1 ) + + col0 * col0 + - col2 * - col0 AS col0 FROM tab2 cor0
----
207
8053
9226

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2060
SELECT - CAST( NULL AS SIGNED ) + + ( - col0 ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2060
SELECT - CAST ( NULL AS INTEGER ) + + ( - col0 ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 53 * 39 + - cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 19da13726fac64194aca54bf1ef06212

query I rowsort
SELECT DISTINCT + 26 * cor0.col0 AS col1 FROM tab0, tab0 AS cor0
----
2314
624
910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2063
SELECT ALL - CAST( 11 AS SIGNED ) * - col0 FROM tab0 AS cor0
----
264
385
979

skipif mysql # not compatible
query I rowsort label-2063
SELECT ALL - CAST ( 11 AS INTEGER ) * - col0 FROM tab0 AS cor0
----
264
385
979

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - col0 * col2 + - col2 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + col0 + - 18 AS col1 FROM tab0 cor0
----
17
6
71

query I rowsort
SELECT DISTINCT ( col2 ) * col0 + col2 FROM tab2 cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 43 + - col1 col0 FROM tab2 AS cor0
----
-16
12
26

query I rowsort
SELECT DISTINCT - cor0.col2 * + 48 + + col1 FROM tab0 AS cor0
----
-1498
-3845
49

query I rowsort
SELECT DISTINCT - + col2 + + cor0.col1 - cor0.col2 FROM tab0 AS cor0
----
-73
20
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2070
SELECT tab0.col1 * ( + col2 * col0 ) + + CAST( NULL AS DECIMAL ) col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2070
SELECT tab0.col1 * ( + col2 * col0 ) + + CAST ( NULL AS REAL ) col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * - col0 + - ( + col2 ) AS col1 FROM tab2
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 32 * + 72 col0 FROM tab0
----
2328
2339
2393

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col0 AS REAL ) * col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + - 34 + col1 * col0 - cor0.col2 FROM tab2 cor0
----
1271
156
4542

query I rowsort
SELECT + ( col1 ) + - col0 AS col0 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - cor1.col0 AS col2 FROM tab0, tab1 AS cor0, tab0 cor1
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 48 col1 FROM tab1, tab0 AS cor0
----
48

query I rowsort
SELECT ALL tab2.col0 + - ( + col2 ) AS col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL col1 + - ( ( - col0 ) ) AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL - col0 * + 6 FROM tab0
----
-144
-210
-534

query I rowsort
SELECT ALL 74 FROM tab0, tab1 cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT - 28 + ( + col1 + col0 ) * tab1.col1 AS col1 FROM tab1
----
1181
712
726

query I rowsort
SELECT ALL col2 - + 86 FROM tab0 AS cor0
----
-4
-53
-85

query I rowsort
SELECT col1 * + col2 + + col2 AS col2 FROM tab2
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2085
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab1, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2085
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab1, tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 - + col0 * + col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT 77 * + col0 - tab1.col0 FROM tab1
----
228
4864
6080

query I rowsort
SELECT + col2 * col0 + + col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT ALL + col1 + tab0.col0 * tab0.col1 + tab0.col0 FROM tab0
----
2174
3527
8279

query I rowsort
SELECT col1 * 87 AS col2 FROM tab0 AS cor0
----
7482
7917
8439

query I rowsort
SELECT ALL - + col0 * + col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * cor0.col0 col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT col0 + - tab2.col2 * - col1 FROM tab2
----
1612
725
844

skipif mysql # not compatible
query I rowsort
SELECT ALL + tab0.col0 + col0 * CAST ( + 61 AS REAL ) FROM tab0
----
1488
2170
5518

query I rowsort
SELECT DISTINCT - 97 * col0 + col1 * - col2 AS col0 FROM tab2
----
-1516
-8309
-9100

query I rowsort
SELECT DISTINCT - tab2.col1 * col0 + - col1 AS col0 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT + col1 * + col0 + - 55 * - col0 * + col2 FROM tab1
----
201280
423440
8988

onlyif mysql # use DIV operator for integer division
query I rowsort label-2098
SELECT DISTINCT col0 DIV 10 FROM tab2
----
0
7

skipif mysql # not compatible
query I rowsort label-2098
SELECT DISTINCT col0 / 10 FROM tab2
----
0
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2099
SELECT + cor0.col1 * - 8 + - col0 DIV + col1 + + ( col1 ) FROM tab2 cor0
----
-123
-217
-414

skipif mysql # not compatible
query I rowsort label-2099
SELECT + cor0.col1 * - 8 + - col0 / + col1 + + ( col1 ) FROM tab2 cor0
----
-123
-217
-414

query I rowsort
SELECT tab1.col2 * + col2 * - col1 + + col0 * + col1 AS col0 FROM tab1
----
-118768
-31850
-75738

query I rowsort
SELECT DISTINCT + tab2.col0 * tab2.col0 AS col1 FROM tab2
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2102
SELECT DISTINCT + CAST( - 75 * cor0.col1 AS SIGNED ) AS col1 FROM tab0, tab1 AS cor0
----
-1950
-750
-975

skipif mysql # not compatible
query I rowsort label-2102
SELECT DISTINCT + CAST ( - 75 * cor0.col1 AS INTEGER ) AS col1 FROM tab0, tab1 AS cor0
----
-1950
-750
-975

query I rowsort
SELECT - col2 * - 28 FROM tab1 AS cor0
----
1512
1596
2688

query I rowsort
SELECT + col2 + 13 + + col0 FROM tab1 AS cor0
----
134
189
70

query I rowsort
SELECT DISTINCT col2 * - 84 * - col0 AS col1 FROM tab1 AS cor0
----
13608
306432
645120

onlyif mysql # use DIV operator for integer division
query I rowsort label-2106
SELECT DISTINCT col1 + 0 DIV cor0.col0 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2106
SELECT DISTINCT col1 + 0 / cor0.col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL cor0.col2 + - col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + cor0.col0 * col1 + ( cor0.col0 ) FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - col2 * + cor0.col2 + + 33 AS col2 FROM tab2 AS cor0
----
-1411
-643
-696

query I rowsort
SELECT - - col2 * + ( col0 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - col0 * - cor0.col1 - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL - - col2 * ( - 77 ) AS col2 FROM tab1 AS cor0
----
-4158
-4389
-7392

onlyif mysql # use DIV operator for integer division
query I rowsort label-2113
SELECT DISTINCT + + cor0.col1 DIV - col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2113
SELECT DISTINCT + + cor0.col1 / - col2 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2114
SELECT 44 DIV col2 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2114
SELECT 44 / col2 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT cor0.col0 * col2 + + col1 - col1 AS col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT + ( - col1 ) + - ( ( col2 ) ) FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - 47 AS REAL ) * col2 * + 63 AS col2 FROM tab1
----
-159894
-168777
-284256

onlyif mysql # use DIV operator for integer division
query I rowsort label-2118
SELECT ALL col2 DIV col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2118
SELECT ALL col2 / col1 FROM tab2
----
0
0
2

query I rowsort
SELECT DISTINCT cor0.col0 * 56 FROM tab1, tab2, tab0 AS cor0
----
1344
1960
4984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 22 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to fae46f8148b02964f7145eb6ed5819f9

query I rowsort
SELECT col1 + - col1 * col1 + 40 * - col2 AS col0 FROM tab2
----
-1792
-2010
-4462

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + 48 * - col0 col2 FROM tab1
----
-118
-3062
-3827

query I rowsort
SELECT - tab0.col2 + + 87 AS col0 FROM tab0
----
5
54
86

query I rowsort
SELECT - - 43 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT - ( tab0.col0 ) FROM tab0
----
-24
-35
-89

query I rowsort
SELECT + tab0.col1 * col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL + 80 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

onlyif mysql # use DIV operator for integer division
query I rowsort label-2128
SELECT + col1 + col0 DIV + col1 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-2128
SELECT + col1 + col0 / + col1 FROM tab2 AS cor0
----
21
31
60

query I rowsort
SELECT + 43 * - col1 + cor0.col2 - + col2 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT - 56 + col2 - + 65 FROM tab0 cor0
----
-120
-39
-88

query I rowsort
SELECT + cor0.col2 + - col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 95 - + col2 * col0 FROM tab1 AS cor0
----
-3553
-67
-7585

onlyif mysql # use DIV operator for integer division
query I rowsort label-2133
SELECT 45 DIV - col0 + CAST( col0 * col2 AS SIGNED ) FROM tab0 AS cor0
----
34
7298
791

skipif mysql # not compatible
query I rowsort label-2133
SELECT 45 / - col0 + CAST ( col0 * col2 AS INTEGER ) FROM tab0 AS cor0
----
34
7298
791

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + col0 * + col2 * cor0.col0 col2 FROM tab0 AS cor0
----
1190
18984
649433

query I rowsort
SELECT col1 + + cor0.col2 * ( + col2 ) * + cor0.col1 AS col2 FROM tab1 AS cor0
----
119821
32500
75842

query I rowsort
SELECT col1 * - col1 AS col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT + - col2 + + col0 AS col0 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2138
SELECT - - cor0.col2 * - CAST( NULL AS SIGNED ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2138
SELECT - - cor0.col2 * - CAST ( NULL AS INTEGER ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * cor0.col2 + + col0 * col1 AS col1 FROM tab1 AS cor0
----
10256
2994
3889

query I rowsort
SELECT ALL - cor0.col1 * + ( col0 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2141
SELECT - - col2 DIV + col1 AS col2 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2141
SELECT - - col2 / + col1 AS col2 FROM tab1 cor0
----
2
5
7

query I rowsort
SELECT ALL col0 * cor0.col0 AS col0 FROM tab2 cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-2143
SELECT - col0 + col2 DIV 99 AS col2 FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2143
SELECT - col0 + col2 / 99 AS col2 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT - 86 * + col0 AS col2 FROM tab2 AS cor0
----
-602
-6708
-6794

query I rowsort
SELECT ALL - - 92 + 52 + - col0 * + col1 AS col0 FROM tab1 AS cor0
----
-496
-896
66

query I rowsort
SELECT cor1.col0 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - - col2 * 68 FROM tab0 cor0
----
2244
5576
68

query I rowsort
SELECT ALL 88 - cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 cor1, tab2 AS cor2
----
81 values hashing to 3c19d09b9f61e22db0e23b0ecdebe515

query I rowsort
SELECT 27 * - 3 FROM tab0 AS cor0
----
-81
-81
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 23 * - 61 col0 FROM tab1 AS cor0
----
1403
1403
1403

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2151
SELECT DISTINCT CAST( + col1 + col1 AS SIGNED ) AS col0 FROM tab0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-2151
SELECT DISTINCT CAST ( + col1 + col1 AS INTEGER ) AS col0 FROM tab0
----
172
182
194

query I rowsort
SELECT + col0 - 27 AS col1 FROM tab2
----
-20
51
52

query I rowsort
SELECT 38 AS col1 FROM tab2 cor0
----
38
38
38

query I rowsort
SELECT + ( col0 ) * col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + ( ( - col0 ) ) * - col0 + col2 AS col1 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ( 68 ) FROM tab1 AS cor0
----
68
68
68

query I rowsort
SELECT DISTINCT + col2 * col0 + ( col1 ) FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT + ( - col2 ) + - col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL + 61 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT + + 12 FROM tab2 AS cor0
----
12
12
12

query I rowsort
SELECT DISTINCT + + 48 + cor0.col2 FROM tab1 AS cor0
----
102
105
144

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2162
SELECT + col2 * CAST( NULL AS DECIMAL ) + + 49 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2162
SELECT + col2 * CAST ( NULL AS REAL ) + + 49 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2163
SELECT + col0 * col1 + - col2 DIV cor0.col1 FROM tab2 AS cor0
----
1341
217
4602

skipif mysql # not compatible
query I rowsort label-2163
SELECT + col0 * col1 + - col2 / cor0.col1 FROM tab2 AS cor0
----
1341
217
4602

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab1, tab1 cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col2 * + col2 col0 FROM tab2
----
1444
676
729

query I rowsort
SELECT + col1 + ( - col0 ) * 7 AS col1 FROM tab0 AS cor0
----
-148
-532
-82

query I rowsort
SELECT ALL + cor0.col2 * col0 + col0 AS col1 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + col0 * + cor0.col1 - col0 AS col1 FROM tab2 AS cor0
----
1264
210
4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 45 col2 FROM tab2, tab2 AS cor0
----
45

query I rowsort
SELECT 6 + col0 AS col0 FROM tab0
----
30
41
95

skipif mysql # not compatible
query I rowsort
SELECT - col0 * col2 + ( + 34 * col0 ) + CAST ( + ( + col0 ) AS REAL ) * + col1 FROM tab2 AS cor0
----
1027
266
5226

onlyif mysql # use DIV operator for integer division
query I rowsort label-2172
SELECT DISTINCT tab2.col1 DIV + col1 AS col2 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-2172
SELECT DISTINCT tab2.col1 / + col1 AS col2 FROM tab2
----
1

query I rowsort
SELECT DISTINCT - 36 * 17 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-612

onlyif mysql # use DIV operator for integer division
query I rowsort label-2174
SELECT col1 + col2 DIV - col0 AS col2 FROM tab0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-2174
SELECT col1 + col2 / - col0 AS col2 FROM tab0
----
85
91
97

query I rowsort
SELECT col2 * + 29 FROM tab1 AS cor0
----
1566
1653
2784

query I rowsort
SELECT - cor0.col0 * col0 * + col2 AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT - col2 * + col1 * 98 AS col0 FROM tab1
----
-122304
-137592
-55860

query I rowsort
SELECT - 19 FROM tab2, tab1 cor0
----
9 values hashing to 339c9d62143bf2f7566b89a1b56eeeb4

query I rowsort
SELECT ALL - col2 * - ( col2 ) AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - col1 + 33 * 82 AS col2 FROM tab1 AS cor0
----
2680
2693
2696

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + 49 * - col2 col1 FROM tab1 cor0
----
-178752
-376320
-7938

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2182
SELECT DISTINCT + col0 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2182
SELECT DISTINCT + col0 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2183
SELECT cor0.col0 * CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-2183
SELECT cor0.col0 * CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2184
SELECT + CAST( NULL AS SIGNED ) + col1 * tab2.col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2184
SELECT + CAST ( NULL AS INTEGER ) + col1 * tab2.col0 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 76 + - col2 AS col0 FROM tab1
----
-20
19
22

query I rowsort
SELECT - ( ( - tab0.col1 ) + col2 ) * + 28 FROM tab0
----
1484
252
2688

query I rowsort
SELECT ALL + 84 FROM tab1, tab0 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT - ( + col1 ) * tab2.col2 * + tab2.col2 AS col1 FROM tab2
----
-22599
-24548
-39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2189
SELECT DISTINCT CAST( col0 AS SIGNED ) + + col2 * col1 FROM tab0
----
132
2862
7551

skipif mysql # not compatible
query I rowsort label-2189
SELECT DISTINCT CAST ( col0 AS INTEGER ) + + col2 * col1 FROM tab0
----
132
2862
7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2190
SELECT CAST( NULL AS SIGNED ) + - col0 / col2 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2190
SELECT CAST ( NULL AS INTEGER ) + - col0 / col2 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + 3 AS col2 FROM tab2 AS cor0
----
-14
-28
-56

query I rowsort
SELECT + col1 + + 39 * + cor0.col2 FROM tab1 AS cor0
----
2132
2233
3757

query I rowsort
SELECT + + ( cor0.col2 ) * + col1 * ( - 69 ) - col0 FROM tab2 AS cor0
----
-105924
-44653
-57760

query I rowsort
SELECT DISTINCT - + 29 + - cor0.col2 FROM tab0 AS cor0
----
-111
-30
-62

query I rowsort
SELECT ALL + + col0 * col1 * + col1 + 86 * - col2 FROM tab0 AS cor0
----
174666
329229
729957

query I rowsort
SELECT - 35 * col0 AS col1 FROM tab0 AS cor0
----
-1225
-3115
-840

query I rowsort
SELECT DISTINCT - ( - col0 ) * + ( + ( cor0.col2 ) ) * - 99 FROM tab2 cor0
----
-18711
-200772
-297198

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 39 + col0 col2 FROM tab0 AS cor0
----
128
63
74

query I rowsort
SELECT - 4 * col0 AS col2 FROM tab0 cor0
----
-140
-356
-96

query I rowsort
SELECT ALL + 87 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT DISTINCT - ( 62 ) FROM tab1
----
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2202
SELECT CAST( col0 + col2 AS SIGNED ) * 46 * - 71 AS col2 FROM tab0
----
-117576
-186162
-558486

skipif mysql # not compatible
query I rowsort label-2202
SELECT CAST ( col0 + col2 AS INTEGER ) * 46 * - 71 AS col2 FROM tab0
----
-117576
-186162
-558486

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2203
SELECT + CAST( - col0 AS SIGNED ) * - col1 FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-2203
SELECT + CAST ( - col0 AS INTEGER ) * - col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + - col1 + cor0.col0 AS col2 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT - - col1 + cor0.col0 AS col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2206
SELECT DISTINCT col1 + + col0 / CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2206
SELECT DISTINCT col1 + + col0 / CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 * + cor0.col0 + + cor0.col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT ALL + + 27 AS col0 FROM tab2 AS cor0
----
27
27
27

query I rowsort
SELECT + col0 * - col0 * col0 FROM tab2 AS cor0
----
-343
-474552
-493039

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col0 ) col2 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2211
SELECT DISTINCT - col1 + col1 DIV - cor0.col1 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-2211
SELECT DISTINCT - col1 + col1 / - cor0.col1 FROM tab1 AS cor0
----
-11
-14
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-2212
SELECT + - col2 + col1 DIV - col0 FROM tab2 AS cor0
----
-26
-31
-38

skipif mysql # not compatible
query I rowsort label-2212
SELECT + - col2 + col1 / - col0 FROM tab2 AS cor0
----
-26
-31
-38

query I rowsort
SELECT DISTINCT col0 * + col1 - - 23 AS col0 FROM tab1 AS cor0
----
101
1063
663

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 21 * col2 - + ( + col2 ) * col2 col0 FROM tab1 AS cor0
----
-11232
-4050
-4446

query I rowsort
SELECT ALL + col2 * + col1 + + col0 * 7 FROM tab2 AS cor0
----
1199
2080
886

onlyif mysql # use DIV operator for integer division
query I rowsort label-2216
SELECT ALL - + cor0.col2 DIV - col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-2216
SELECT ALL - + cor0.col2 / - col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT + - 91 FROM tab1 cor0
----
-91
-91
-91

query I rowsort
SELECT ALL col0 * col1 + cor0.col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT col0 * - 91 FROM tab0 cor0
----
-2184
-3185
-8099

query I rowsort
SELECT - ( - col1 ) - 77 AS col1 FROM tab2
----
-18
-46
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2221
SELECT - col1 + - col0 * CAST( NULL AS SIGNED ) * + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2221
SELECT - col1 + - col0 * CAST ( NULL AS INTEGER ) * + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col0 * + col1 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-2223
SELECT DISTINCT + col2 + 73 DIV 11 AS col0 FROM tab2 AS cor0
----
32
33
44

skipif mysql # not compatible
query I rowsort label-2223
SELECT DISTINCT + col2 + 73 / 11 AS col0 FROM tab2 AS cor0
----
32
33
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 12 + col1 col0 FROM tab2 AS cor0
----
221
403
767

query I rowsort
SELECT DISTINCT - + col2 + + cor0.col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - col2 * - col2 + ( col2 ) * col0 * - col1 FROM tab2
----
-118976
-49590
-5130

query I rowsort
SELECT ALL cor1.col1 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + 60 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT DISTINCT - col1 * - col0 + ( col0 ) AS col2 FROM tab0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2230
SELECT 5 * + col2 + - CAST( NULL AS SIGNED ) * - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2230
SELECT 5 * + col2 + - CAST ( NULL AS INTEGER ) * - col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + 67 * col1 + + 24 FROM tab0
----
5786
6121
6523

query I rowsort
SELECT ALL + - 10 * 32 AS col2 FROM tab1 AS cor0
----
-320
-320
-320

query I rowsort
SELECT ( 47 ) AS col0 FROM tab0 cor0
----
47
47
47

query I rowsort
SELECT ALL + - ( col0 ) FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - + 20 + + 54 FROM tab1 AS cor0
----
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2236
SELECT + col1 DIV col1 AS col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2236
SELECT + col1 / col1 AS col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT - - ( 42 ) + + cor0.col1 FROM tab0 AS cor0
----
128
133
139

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2238
SELECT ALL + - CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2238
SELECT ALL + - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2239
SELECT 77 + col2 - + cor0.col0 * CAST( - 45 AS SIGNED ) FROM tab1 AS cor0
----
266
3014
3773

skipif mysql # not compatible
query I rowsort label-2239
SELECT 77 + col2 - + cor0.col0 * CAST ( - 45 AS INTEGER ) FROM tab1 AS cor0
----
266
3014
3773

query I rowsort
SELECT DISTINCT - + cor0.col2 * - 85 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT - ( + col2 ) + + col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + - 34 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-2924
-3094
-3298

onlyif mysql # use DIV operator for integer division
query I rowsort label-2243
SELECT DISTINCT col1 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-2243
SELECT DISTINCT col1 / cor0.col0 AS col1 FROM tab1 AS cor0
----
0
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2244
SELECT - CAST( NULL AS SIGNED ) / 26 + - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2244
SELECT - CAST ( NULL AS INTEGER ) / 26 + - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col0 * + ( col2 ) * tab0.col2 + + col1 AS col0 FROM tab0
----
132
26222
598527

query I rowsort
SELECT DISTINCT - - col2 + - col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT + tab2.col1 * + col2 * col0 - - col1 FROM tab2
----
119711
51051
5890

query I rowsort
SELECT ALL ( - col1 ) + - col2 AS col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL - 96 * col2 * col1 + + ( col1 ) * col1 FROM tab1 AS cor0
----
-119639
-134108
-54620

query I rowsort
SELECT DISTINCT + col0 + col0 - + col0 * col1 FROM tab1 AS cor0
----
-512
-72
-880

query I rowsort
SELECT DISTINCT + + 22 FROM tab0 AS cor0
----
22

query I rowsort
SELECT cor0.col0 - ( col0 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 + + col2 * - col2 * - 52 - + 62 FROM tab2 AS cor0
----
35116
37873
75064

query I rowsort
SELECT DISTINCT 93 + col0 FROM tab2
----
100
171
172

query I rowsort
SELECT + cor0.col1 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0 WHERE NOT NULL <= NULL
----

query I rowsort
SELECT + col1 * + col2 - col2 * + col0 AS col1 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT - - 95 + col1 + - col1 FROM tab0 AS cor0
----
95
95
95

query I rowsort
SELECT + 78 + col2 * + col0 AS col0 FROM tab2 AS cor0
----
2106
267
3080

query I rowsort
SELECT col1 * - col2 * col2 + + col0 AS col0 FROM tab2 cor0
----
-22592
-24469
-39806

query I rowsort
SELECT ALL - col2 * - 13 + tab1.col2 FROM tab1
----
1344
756
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-2262
SELECT + 68 DIV - col0 + - col0 AS col2 FROM tab2 cor0
----
-16
-78
-79

skipif mysql # not compatible
query I rowsort label-2262
SELECT + 68 / - col0 + - col0 AS col2 FROM tab2 cor0
----
-16
-78
-79

query I rowsort
SELECT col2 * col2 * - col1 + + col1 + + col1 FROM tab2
----
-22537
-24514
-39766

query I rowsort
SELECT col1 * 7 AS col2 FROM tab0
----
602
637
679

query I rowsort
SELECT + - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT ALL + ( - col0 ) + + col0 + col0 * col1 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + ( col2 ) + + col1 + cor0.col2 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT ALL ( + cor0.col2 ) - col1 * col1 AS col2 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT ALL + 99 * - col1 * + col2 FROM tab0
----
-280962
-738738
-9603

query I rowsort
SELECT ALL + - col0 * - col2 * col2 - col2 FROM tab1 AS cor0
----
207879
737184
8694

query I rowsort
SELECT col1 * col2 + tab0.col0 * col2 FROM tab0
----
132
14760
3630

onlyif mysql # use DIV operator for integer division
query I rowsort label-2272
SELECT - col2 * + col0 + + col1 DIV col2 FROM tab0
----
-7297
-790
62

skipif mysql # not compatible
query I rowsort label-2272
SELECT - col2 * + col0 + + col1 / col2 FROM tab0
----
-7297
-790
62

query I rowsort
SELECT DISTINCT col2 * col0 * + col0 + col2 * + col0 AS col2 FROM tab0
----
1260
19800
656820

query I rowsort
SELECT ALL + tab1.col1 * col1 + - col1 + col1 AS col2 FROM tab1
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2275
SELECT - tab0.col2 DIV - col0 col1 FROM tab0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2275
SELECT - tab0.col2 / - col0 col1 FROM tab0
----
0
0
1

query I rowsort
SELECT col0 + tab2.col1 * - col1 * - col2 FROM tab2
----
11061
25954
90584

query I rowsort
SELECT ALL - col2 * - col0 * - tab1.col0 AS col1 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT + cor0.col1 + col1 + col2 AS col1 FROM tab0 cor0
----
195
205
264

query I rowsort
SELECT ALL + col1 + col2 * - col2 AS col0 FROM tab1 WHERE NULL > ( NULL )
----

query I rowsort
SELECT DISTINCT - tab1.col0 * - col2 * - col2 AS col0 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT col1 + col0 + + tab0.col1 * + tab0.col1 AS col2 FROM tab0
----
7506
8461
9541

query I rowsort
SELECT ALL - col2 * col1 AS col1 FROM tab2
----
-1534
-646
-837

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT col1 * col1 * col0 + + col1 NOT IN ( col2 )
----

query I rowsort
SELECT - col1 + col1 * - col1 + col0 AS col0 FROM tab2
----
-227
-3462
-985

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT IN ( - col2 + - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col0 + + col0 col2 FROM tab1
----
192
240
9

query I rowsort
SELECT - tab0.col0 + col2 + col0 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL col0 FROM tab2 WHERE ( - col2 * - col2 ) NOT IN ( - col2 )
----
7
78
79

query III rowsort
SELECT * FROM tab2 WHERE NOT col1 IN ( tab2.col1 + + col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT + col0 * - col1 + + col1 * col1 + col2 FROM tab1
----
-483
-775
652

query I rowsort
SELECT ALL - col2 * + col1 AS col2 FROM tab0 WHERE NOT ( NULL ) IN ( tab0.col1 + + col1 * col1 )
----

query I rowsort
SELECT + col0 FROM tab2 WHERE NULL < col2 * + col2 - - col0
----

query III rowsort
SELECT * FROM tab0 WHERE NOT col2 * - col2 = ( NULL )
----

query III rowsort
SELECT * FROM tab2 WHERE col1 * + col0 * - col0 < ( + col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2295
SELECT ALL col0 - - col0 DIV col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-2295
SELECT ALL col0 - - col0 / col2 FROM tab0
----
24
70
90

query I rowsort
SELECT - col1 * col0 * - col2 AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT ALL col1 AS col2 FROM tab1 WHERE NOT ( col0 * - col0 ) <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - col0 + + col1 * - col1 + - col2 FROM tab0 cor0
----
-7453
-8452
-9445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 - col2 col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT - col1 + - cor0.col0 * col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT ALL + col1 * + ( col2 ) FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT cor0.col0 * col1 + col2 * + col0 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT ALL + cor0.col0 * - 29 - + col1 FROM tab2 AS cor0
----
-2308
-2321
-234

query I rowsort
SELECT col2 + - 68 * - col1 FROM tab0 AS cor0
----
5881
6270
6597

query I rowsort
SELECT ALL - col0 + - col2 * col1 FROM tab0 cor0
----
-132
-2862
-7551

query I rowsort
SELECT - cor0.col1 * - col2 * col2 AS col2 FROM tab2 cor0
----
22599
24548
39884

query I rowsort
SELECT col2 * + ( - col0 * - col2 ) AS col1 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT col2 * - col0 AS col2 FROM tab0 cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( ( col0 ) ) * col1 + col0 * - col2 + col2 col2 FROM tab2 AS cor0
----
-1621
2600
55

query I rowsort
SELECT DISTINCT + - col1 * ( col1 * - ( + cor0.col2 ) ) - - col1 AS col2 FROM tab0 AS cor0
----
244154
679133
9506

query I rowsort
SELECT 69 * col2 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
1853
1894
2639

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( - 89 ) col0 FROM tab0 AS cor0
----
89
89
89

query I rowsort
SELECT - - cor0.col0 * 30 + col1 AS col1 FROM tab0 AS cor0
----
1147
2761
806

query I rowsort
SELECT DISTINCT - col2 + col1 * col1 * + col2 FROM tab1 cor0
----
16128
36450
5643

onlyif mysql # use DIV operator for integer division
query I rowsort label-2316
SELECT DISTINCT - 37 DIV + col2 - - col0 AS col0 FROM tab0 AS cor0
----
-2
23
89

skipif mysql # not compatible
query I rowsort label-2316
SELECT DISTINCT - 37 / + col2 - - col0 AS col0 FROM tab0 AS cor0
----
-2
23
89

query I rowsort
SELECT + ( cor0.col0 ) + col0 * + ( - 43 ) AS col0 FROM tab2 AS cor0
----
-294
-3276
-3318

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2318
SELECT ALL + col0 + CAST( NULL AS SIGNED ) * 6 * + col1 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2318
SELECT ALL + col0 + CAST ( NULL AS INTEGER ) * 6 * + col1 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 57 * cor1.col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e41b68a9b7bf385c0099d7eec0412344

query I rowsort
SELECT DISTINCT + 38 * col2 AS col0 FROM tab0 AS cor0
----
1254
3116
38

query I rowsort
SELECT - ( - 26 ) * - col1 AS col1 FROM tab2 cor0
----
-1534
-442
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2322
SELECT + 77 * col0 DIV col1 + 91 AS col1 FROM tab0 AS cor0
----
112
118
166

skipif mysql # not compatible
query I rowsort label-2322
SELECT + 77 * col0 / col1 + 91 AS col1 FROM tab0 AS cor0
----
112
118
166

query I rowsort
SELECT 53 + col2 * + col2 AS col2 FROM tab0 AS cor0
----
1142
54
6777

query IIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0 WHERE NULL <= NULL
----

query I rowsort
SELECT DISTINCT + col0 + 8 * - cor0.col1 AS col1 FROM tab1 cor0
----
-16
-205
-24

query I rowsort
SELECT DISTINCT - col0 * col2 * col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - cor0.col0 + - col0 * + col2 * col2 AS col1 FROM tab0 cor0
----
-26160
-598525
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 + - 68 col2 FROM tab2
----
27
27
27

query I rowsort
SELECT DISTINCT col1 * - col0 * + col2 AS col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT - col0 * + 99 AS col1 FROM tab1 AS cor0
----
-297
-6336
-7920

query I rowsort
SELECT DISTINCT - col1 + 98 * col1 FROM tab2 AS cor0
----
1649
3007
5723

query I rowsort
SELECT DISTINCT + + col1 * - ( + 48 ) AS col2 FROM tab1 AS cor0
----
-1248
-480
-624

query I rowsort
SELECT DISTINCT - col2 * - tab1.col1 + 33 AS col1 FROM tab1
----
1281
1437
603

query I rowsort
SELECT DISTINCT + col0 + + 95 * col2 FROM tab1
----
5133
5479
9200

onlyif mysql # use DIV operator for integer division
query I rowsort label-2335
SELECT ALL + tab1.col2 DIV + 99 + + col1 + - col2 FROM tab1
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-2335
SELECT ALL + tab1.col2 / + 99 + + col1 + - col2 FROM tab1
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2336
SELECT - tab2.col2 DIV 16 FROM tab2
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-2336
SELECT - tab2.col2 / 16 FROM tab2
----
-1
-1
-2

query I rowsort
SELECT + col0 + 10 AS col1 FROM tab1
----
13
74
90

query I rowsort
SELECT ALL col1 * - 24 - - 54 FROM tab2 AS cor0
----
-1362
-354
-690

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 + + col2 - - col2 FROM tab2 AS cor0
----
1586
722
891

query I rowsort
SELECT col1 - ( + 47 ) AS col2 FROM tab2 AS cor0
----
-16
-30
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-2341
SELECT + col1 DIV col0 + + col2 AS col1 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-2341
SELECT + col1 / col0 + + col2 AS col1 FROM tab1 AS cor0
----
57
62
96

query I rowsort
SELECT - col0 * - ( col2 * col0 ) + + col1 FROM tab0 AS cor0
----
1322
19094
649613

query I rowsort
SELECT ALL - cor0.col0 + + ( - 76 ) * cor0.col2 FROM tab2 AS cor0
----
-2054
-2059
-2967

onlyif mysql # use DIV operator for integer division
query I rowsort label-2344
SELECT + col2 + col0 DIV + 11 - col0 AS col1 FROM tab2 cor0
----
-34
-45
20

skipif mysql # not compatible
query I rowsort label-2344
SELECT + col2 + col0 / + 11 - col0 AS col1 FROM tab2 cor0
----
-34
-45
20

query I rowsort
SELECT ALL + col2 * + 66 FROM tab1 cor0
----
3564
3762
6336

query I rowsort
SELECT + - cor0.col2 * col0 + - 14 AS col0 FROM tab2 AS cor0
----
-203
-2042
-3016

onlyif mysql # use DIV operator for integer division
query I rowsort label-2347
SELECT DISTINCT - + col2 DIV - col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2347
SELECT DISTINCT - + col2 / - col2 FROM tab1 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2348
SELECT + CAST( 70 AS SIGNED ) DIV - col0 FROM tab1 AS cor0
----
-1
-23
0

skipif mysql # not compatible
query I rowsort label-2348
SELECT + CAST ( 70 AS INTEGER ) / - col0 FROM tab1 AS cor0
----
-1
-23
0

query I rowsort
SELECT ALL + 37 AS col2 FROM tab1 AS cor0
----
37
37
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-2350
SELECT ALL col0 DIV + ( + cor0.col1 ) + + col0 FROM tab2 AS cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-2350
SELECT ALL col0 / + ( + cor0.col1 ) + + col0 FROM tab2 AS cor0
----
7
79
83

query I rowsort
SELECT + - ( col0 ) * - col1 + - col1 * col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 44 * col1 FROM tab2 AS cor0
----
1364
2596
748

query I rowsort
SELECT - - ( cor0.col1 ) * - col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL cor0.col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + col0 + ( col2 ) FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 79 col2 FROM tab0
----
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 7 col2 FROM tab2
----
7
7
7

query I rowsort
SELECT + 86 + cor0.col2 * - col1 FROM tab1 AS cor0
----
-1162
-1318
-484

query I rowsort
SELECT DISTINCT + 89 AS col0 FROM tab1 cor0
----
89

query I rowsort
SELECT DISTINCT cor0.col2 AS col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
54
57
96

query I rowsort
SELECT DISTINCT + col0 * + 9 + ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-27
519
624

onlyif mysql # use DIV operator for integer division
query I rowsort label-2362
SELECT cor0.col1 DIV + ( + col1 + + col1 ) AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2362
SELECT cor0.col1 / + ( + col1 + + col1 ) AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * 29 + col2 * - col2 AS col1 FROM tab1 AS cor0
----
-1350
-1596
-6432

query I rowsort
SELECT ALL col2 * + ( 44 ) FROM tab1 cor0
----
2376
2508
4224

query I rowsort
SELECT ALL + cor0.col2 * + 20 + col0 FROM tab2 AS cor0
----
547
598
839

onlyif mysql # use DIV operator for integer division
query I rowsort label-2366
SELECT + + col1 DIV + col0 col0 FROM tab1 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2366
SELECT + + col1 / + col0 col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT DISTINCT - col0 * - 6 AS col2 FROM tab2 AS cor0
----
42
468
474

onlyif mysql # use DIV operator for integer division
query I rowsort label-2368
SELECT DISTINCT - col2 DIV 87 + col0 + + col0 * col2 FROM tab0 AS cor0
----
70
7387
816

skipif mysql # not compatible
query I rowsort label-2368
SELECT DISTINCT - col2 / 87 + col0 + + col0 * col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT + 56 AS col1 FROM tab0
----
56
56
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-2370
SELECT ALL - cor0.col2 - cor0.col2 DIV col0 FROM tab1 cor0
----
-57
-72
-97

skipif mysql # not compatible
query I rowsort label-2370
SELECT ALL - cor0.col2 - cor0.col2 / col0 FROM tab1 cor0
----
-57
-72
-97

query I rowsort
SELECT + col0 * cor0.col2 + - 43 * + 9 AS col1 FROM tab0 AS cor0
----
-352
405
6911

onlyif mysql # use DIV operator for integer division
query I rowsort label-2372
SELECT DISTINCT - 91 DIV + cor0.col1 - col1 * - col0 AS col1 FROM tab0 AS cor0
----
2063
3395
8098

skipif mysql # not compatible
query I rowsort label-2372
SELECT DISTINCT - 91 / + cor0.col1 - col1 * - col0 AS col1 FROM tab0 AS cor0
----
2063
3395
8098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + col2 col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - + col2 * + 58 FROM tab0 AS cor0
----
-1914
-4756
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - col2 + + ( 62 ) FROM tab0 AS cor0
----
-20
29
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-2377
SELECT ALL 23 DIV - col2 col2 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2377
SELECT ALL 23 / - col2 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col1 + 89 * col2 AS col0 FROM tab0 cor0
----
-8
2851
7207

query I rowsort
SELECT - 2 + + col1 FROM tab2 AS cor0
----
15
29
57

query I rowsort
SELECT + cor0.col1 - + col2 * + col0 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT + - 11 + 87 AS col1 FROM tab2 AS cor0
----
76

query I rowsort
SELECT ALL + col0 * - col0 + col0 AS col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT 45 + - ( + col0 ) FROM tab0 AS cor0
----
-44
10
21

query I rowsort
SELECT ALL + 82 * - col0 - col0 FROM tab0 AS cor0
----
-1992
-2905
-7387

onlyif mysql # use DIV operator for integer division
query I rowsort label-2385
SELECT + 7 * 24 + cor0.col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
168
168
171

skipif mysql # not compatible
query I rowsort label-2385
SELECT + 7 * 24 + cor0.col2 / + col0 AS col0 FROM tab2 AS cor0
----
168
168
171

query I rowsort
SELECT ALL + col2 * - ( + col0 ) - 67 AS col0 FROM tab2 AS cor0
----
-2095
-256
-3069

query I rowsort
SELECT DISTINCT - 4 * cor0.col2 + col2 * - col2 * + col1 FROM tab2 cor0
----
-22707
-24700
-39988

query I rowsort
SELECT col2 + - 32 FROM tab0 AS cor0
----
-31
1
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2389
SELECT DISTINCT tab0.col1 / + ( + 3 ) + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2389
SELECT DISTINCT tab0.col1 / + ( + 3 ) + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL

query I rowsort
SELECT + + ( + col0 ) - - col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT col0 + 78 AS col2 FROM tab2
----
156
157
85

query I rowsort
SELECT col1 + 29 AS col1 FROM tab0
----
115
120
126

onlyif mysql # use DIV operator for integer division
query I rowsort label-2393
SELECT col2 DIV + tab2.col0 + - col1 + col1 * + col2 FROM tab2
----
1475
629
809

skipif mysql # not compatible
query I rowsort label-2393
SELECT col2 / + tab2.col0 + - col1 + col1 * + col2 FROM tab2
----
1475
629
809

query I rowsort
SELECT + ( + col0 ) + col0 FROM tab0 cor0
----
178
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2395
SELECT DISTINCT CAST( ( col0 ) AS SIGNED ) col2 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2395
SELECT DISTINCT CAST ( ( col0 ) AS INTEGER ) col2 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL - - 99 * 91 FROM tab0, tab2 AS cor0
----
9 values hashing to 2816805ba1aa3df6d4a8a39f3610217c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2397
SELECT + CAST( NULL AS DECIMAL ) * - 19 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2397
SELECT + CAST ( NULL AS REAL ) * - 19 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * col0 + + 60 AS col1 FROM tab1 cor0
----
222
3708
7740

onlyif mysql # use DIV operator for integer division
query I rowsort label-2399
SELECT - + cor0.col1 DIV col1 + - ( + 7 ) DIV + col1 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2399
SELECT - + cor0.col1 / col1 + - ( + 7 ) / + col1 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL 54 * cor0.col0 AS col2 FROM tab2 AS cor0
----
378
4212
4266

query I rowsort
SELECT DISTINCT cor0.col0 * col1 * + ( - col0 ) FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL + col2 * + col1 AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - - 65 FROM tab1 AS cor0
----
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 * ( 61 ) col0 FROM tab1 AS cor0
----
1532
553
697

query I rowsort
SELECT - col2 * - cor0.col0 + + ( col2 ) FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + - 70 + - col1 AS col0 FROM tab1 AS cor0
----
-80
-83
-96

query I rowsort
SELECT ALL col0 * - 96 FROM tab1
----
-288
-6144
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * tab0.col2 col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL + 40 * 19 AS col1 FROM tab1
----
760
760
760

query I rowsort
SELECT DISTINCT + + 12 * - cor0.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-204
-372
-708

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 + - col0 col0 FROM tab0 AS cor0
----
-22
32
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2412
SELECT - CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2412
SELECT - CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ( + col1 ) * + col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + 49 + + 22 * tab0.col1 - tab0.col1 * 27 * col1 AS col2 FROM tab0
----
-197751
-221536
-251860

query I rowsort
SELECT DISTINCT col1 + + col0 - + col1 * - col0 AS col0 FROM tab2
----
1439
255
4739

query I rowsort
SELECT + 74 + - col1 AS col1 FROM tab0 cor0
----
-12
-17
-23

query I rowsort
SELECT - - col0 * 17 FROM tab0 cor0
----
1513
408
595

query I rowsort
SELECT + col2 * col0 * col1 - col1 * - 18 AS col0 FROM tab2 AS cor0
----
120714
51340
6417

query I rowsort
SELECT DISTINCT + col2 * - 76 - + 89 AS col2 FROM tab1 cor0
----
-4193
-4421
-7385

query I rowsort
SELECT ALL - + col1 * 48 AS col1 FROM tab2 AS cor0
----
-1488
-2832
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + cor0.col2 + + col1 * col2 col0 FROM tab2 AS cor0
----
1619
701
895

query I rowsort
SELECT ALL - col1 * - 0 + + tab0.col0 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL - cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # use DIV operator for integer division
query I rowsort label-2424
SELECT col1 DIV col0 + 60 * - cor0.col0 FROM tab1 AS cor0
----
-172
-3840
-4800

skipif mysql # not compatible
query I rowsort label-2424
SELECT col1 / col0 + 60 * - cor0.col0 FROM tab1 AS cor0
----
-172
-3840
-4800

query I rowsort
SELECT ALL - - cor0.col2 + - col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2426
SELECT DISTINCT col0 + CAST( + 64 * col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
1560
2275
5785

skipif mysql # not compatible
query I rowsort label-2426
SELECT DISTINCT col0 + CAST ( + 64 * col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
1560
2275
5785

query I rowsort
SELECT + col0 * - col2 - 16 AS col2 FROM tab0 AS cor0
----
-51
-7314
-808

query I rowsort
SELECT DISTINCT col1 + - col0 * + col2 + cor0.col2 * + 26 FROM tab2 cor0
----
-1293
-1997
544

query I rowsort
SELECT DISTINCT + + cor0.col2 + 2 AS col0 FROM tab2 AS cor0
----
28
29
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2430
SELECT - col0 * CAST( NULL AS SIGNED ) + + col0 * + col2 * ( col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2430
SELECT - col0 * CAST ( NULL AS INTEGER ) + + col0 * + col2 * ( col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * col1 + - col2 * + col1 FROM tab0 AS cor0
----
-14924
-194
-5676

query I rowsort
SELECT ALL + col2 + - col0 * col2 AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL col0 * - 92 FROM tab2 AS cor0
----
-644
-7176
-7268

query I rowsort
SELECT DISTINCT - cor0.col1 * + 91 FROM tab2 AS cor0
----
-1547
-2821
-5369

query I rowsort
SELECT + col0 * - col2 + - col0 * col2 * - col2 FROM tab0 AS cor0
----
0
25344
591138

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2436
SELECT - col0 * - CAST( - 43 * col2 AS SIGNED ) - - col0 * + col1 * col1 AS col0 FROM tab0 cor0
----
143448
327810
423195

skipif mysql # not compatible
query I rowsort label-2436
SELECT - col0 * - CAST ( - 43 * col2 AS INTEGER ) - - col0 * + col1 * col1 AS col0 FROM tab0 cor0
----
143448
327810
423195

query I rowsort
SELECT ALL col1 + 33 AS col0 FROM tab2 cor0
----
50
64
92

query I rowsort
SELECT DISTINCT - col0 + col2 * + col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT + - 18 * + col1 AS col1 FROM tab0 AS cor0
----
-1548
-1638
-1746

onlyif mysql # use DIV operator for integer division
query I rowsort label-2440
SELECT DISTINCT - 67 DIV + col2 col0 FROM tab1 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2440
SELECT DISTINCT - 67 / + col2 col0 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT + - 10 AS col0 FROM tab0 AS cor0
----
-10

query I rowsort
SELECT DISTINCT + + 92 + + col2 - - col1 AS col1 FROM tab1 AS cor0
----
159
172
201

onlyif mysql # use DIV operator for integer division
query I rowsort label-2443
SELECT ALL + col1 DIV - col1 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2443
SELECT ALL + col1 / - col1 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2444
SELECT - - CAST( NULL AS SIGNED ) + col1 / 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-2444
SELECT - - CAST ( NULL AS INTEGER ) + col1 / col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 71 * + 80 + - col1 AS col0 FROM tab1 cor0
----
-5690
-5693
-5706

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2446
SELECT ALL + + CAST( NULL AS SIGNED ) * - col0 * cor0.col1 + - col2 + ( + col0 ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2446
SELECT ALL + + CAST ( NULL AS INTEGER ) * - col0 * cor0.col1 + - col2 + ( + col0 ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 49 ) + tab2.col0 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to af8cea20c223995f2fcc5ae779ae6cad

query I rowsort
SELECT + col2 + - 3 * col1 AS col0 FROM tab0
----
-191
-225
-290

query I rowsort
SELECT ALL + col2 + - 87 FROM tab0
----
-5
-54
-86

query I rowsort
SELECT + + cor1.col1 * cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to c60831db2936bdb61fb09e86d08b0883

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2451
SELECT - 47 * + col2 + CAST( + col1 AS SIGNED ) * col0 AS col2 FROM tab1 AS cor0
----
-2039
-2460
-3472

skipif mysql # not compatible
query I rowsort label-2451
SELECT - 47 * + col2 + CAST ( + col1 AS INTEGER ) * col0 AS col2 FROM tab1 AS cor0
----
-2039
-2460
-3472

query I rowsort
SELECT DISTINCT - col1 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + 20 * - col0 FROM tab1 AS cor0
----
-1280
-1600
-60

query I rowsort
SELECT + col1 + col2 + col1 AS col2 FROM tab0
----
195
205
264

query I rowsort
SELECT ALL - col1 * tab2.col0 - 99 FROM tab2
----
-1442
-316
-4701

query I rowsort
SELECT ALL - + col0 + - ( - col1 ) AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + col0 * 60 + col1 * - col0 AS col2 FROM tab0 AS cor0
----
-1295
-2759
-624

onlyif mysql # use DIV operator for integer division
query I rowsort label-2458
SELECT DISTINCT col1 DIV + col2 - ( 91 * col2 ) FROM tab1
----
-4914
-5187
-8736

skipif mysql # not compatible
query I rowsort label-2458
SELECT DISTINCT col1 / + col2 - ( 91 * col2 ) FROM tab1
----
-4914
-5187
-8736

query I rowsort
SELECT ALL + 98 * col2 AS col2 FROM tab0
----
3234
8036
98

query I rowsort
SELECT DISTINCT + 61 FROM tab1
----
61

query I rowsort
SELECT 34 + + col0 AS col2 FROM tab2
----
112
113
41

query I rowsort
SELECT - - col1 * + cor0.col0 * + col1 FROM tab2 cor0
----
22831
271518
6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 * col0 col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT + col0 + 51 FROM tab0
----
140
75
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-2465
SELECT + col2 DIV + ( - ( col1 ) ) AS col2 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-2465
SELECT + col2 / + ( - ( col1 ) ) AS col2 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT DISTINCT + col0 * + col0 + - col0 AS col1 FROM tab0
----
1190
552
7832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2467
SELECT + col0 * + CAST( NULL AS SIGNED ) col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2467
SELECT + col0 * + CAST ( NULL AS INTEGER ) col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * + 21 + + 51 + + col2 AS col0 FROM tab1
----
318
420
651

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - 75 + 22 col1 FROM tab1
----
-203
-4778
-5978

query I rowsort
SELECT + tab2.col0 * 24 FROM tab2
----
168
1872
1896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + ( - col1 ) + col1 col1 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT 19 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT ALL + col2 * ( col0 ) + + col0 FROM tab0 cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2474
SELECT ALL col2 DIV - 46 + + 20 AS col0 FROM tab0 AS cor0
----
19
20
20

skipif mysql # not compatible
query I rowsort label-2474
SELECT ALL col2 / - 46 + + 20 AS col0 FROM tab0 AS cor0
----
19
20
20

query I rowsort
SELECT - col0 * 25 * - ( + col2 ) FROM tab2 AS cor0
----
4725
50700
75050

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - 2 * col2 AS REAL ) AS col0 FROM tab1
----
108
114
192

query I rowsort
SELECT DISTINCT - ( col1 * col1 ) + 69 AS col0 FROM tab0
----
-7327
-8212
-9340

query I rowsort
SELECT ( tab1.col1 ) + col1 AS col2 FROM tab1
----
20
26
52

query I rowsort
SELECT ( col2 ) - - col2 FROM tab1
----
108
114
192

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT 99 + - 69 + + col1 AS col0 FROM tab0 AS cor0
----
116
121
127

query I rowsort
SELECT 2 + col1 * - col1 * + col1 + + 57 * + col2 FROM tab1 AS cor0
----
-14496
2251
3277

query I rowsort
SELECT ALL + 17 + 64 * + col2 + cor0.col2 AS col0 FROM tab1 cor0
----
3527
3722
6257

query I rowsort
SELECT + col2 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2485
SELECT - col1 * col1 / - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2485
SELECT - col1 * col1 / - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + ( cor0.col0 ) + + 58 FROM tab0 AS cor0
----
-31
23
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2487
SELECT ALL - ( + cor0.col2 ) DIV - 48 + col0 AS col0 FROM tab1 cor0
----
4
65
82

skipif mysql # not compatible
query I rowsort label-2487
SELECT ALL - ( + cor0.col2 ) / - 48 + col0 AS col0 FROM tab1 cor0
----
4
65
82

query I rowsort
SELECT DISTINCT - col0 * + col1 + + ( col0 ) AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 72 * - col1 col0 FROM tab1 AS cor0
----
-1872
-720
-936

query I rowsort
SELECT DISTINCT tab2.col2 * + 72 FROM tab2, tab1 AS cor0, tab0 cor1
----
1872
1944
2736

query I rowsort
SELECT + 54 * col0 AS col1 FROM tab1 AS cor0
----
162
3456
4320

query I rowsort
SELECT col1 * col0 - - tab1.col1 FROM tab1
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col2 ) col1 FROM tab1
----
54
57
96

query I rowsort
SELECT - col1 - col2 * + col0 FROM tab1
----
-188
-3658
-7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-2495
SELECT DISTINCT + - col2 * col2 + - 22 DIV col0 FROM tab1 cor0
----
-2923
-3249
-9216

skipif mysql # not compatible
query I rowsort label-2495
SELECT DISTINCT + - col2 * col2 + - 22 / col0 FROM tab1 cor0
----
-2923
-3249
-9216

query I rowsort
SELECT DISTINCT col1 * + col1 + - 29 AS col2 FROM tab2 AS cor0
----
260
3452
932

query I rowsort
SELECT 73 AS col1 FROM tab1 AS cor0
----
73
73
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - + col1 * + cor0.col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - 24 + col2 AS col0 FROM tab1 AS cor0
----
30
33
72

query I rowsort
SELECT - - 27 FROM tab0 AS cor0
----
27
27
27

query I rowsort
SELECT - + col0 * - 52 + col1 AS col2 FROM tab1 AS cor0
----
182
3338
4173

query I rowsort
SELECT DISTINCT - + ( - 0 ) FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - 74 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 5a567947d14593676e3825756f8e6130

onlyif mysql # use DIV operator for integer division
query I rowsort label-2505
SELECT ALL - - CAST( - col2 AS SIGNED ) DIV col1 col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2505
SELECT ALL - - CAST ( - col2 AS INTEGER ) / col1 col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT ALL ( - tab1.col2 ) * col0 * + ( + col0 ) + - tab1.col1 AS col1 FROM tab1
----
-233482
-512
-614413

query I rowsort
SELECT - ( - tab0.col1 ) AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL cor0.col0 * 27 * - cor0.col2 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to d171090ac5129d13dfa17223c237364b

query I rowsort
SELECT + col2 + 71 FROM tab1 AS cor0
----
125
128
167

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2510
SELECT + CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-2510
SELECT + CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col1 col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL 61 AS col0 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

onlyif mysql # use DIV operator for integer division
query I rowsort label-2514
SELECT + col2 DIV - 88 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2514
SELECT + col2 / - 88 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + col1 - col0 * + 33 FROM tab2 AS cor0
----
-262
-2624
-2633

query I rowsort
SELECT + col0 * + col2 + 35 * col0 FROM tab1 AS cor0
----
10480
267
5888

query I rowsort
SELECT + col0 + + tab2.col0 FROM tab2
----
14
156
158

query I rowsort
SELECT + col0 + col1 * - ( ( + col0 ) ) * - col1 + + col0 FROM tab2
----
22989
271674
6741

query I rowsort
SELECT + 24 AS col0 FROM tab1, tab2 AS cor0, tab2 cor1, tab0, tab0 cor2
----
243 values hashing to 2b80bdcd0ded0130ce1ec273eab5c9b8

query I rowsort
SELECT ALL tab2.col2 - 37 AS col1 FROM tab2
----
-10
-11
1

query I rowsort
SELECT + + cor0.col1 * cor0.col1 FROM tab2 AS cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * 28 + - col1 col1 FROM tab1 AS cor0
----
1486
1586
2675

query I rowsort
SELECT DISTINCT col2 * + 71 AS col2 FROM tab0 AS cor0
----
2343
5822
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-2524
SELECT ALL + col0 DIV - col1 + - 22 AS col2 FROM tab1 AS cor0
----
-22
-28
-28

skipif mysql # not compatible
query I rowsort label-2524
SELECT ALL + col0 / - col1 + - 22 AS col2 FROM tab1 AS cor0
----
-22
-28
-28

query I rowsort
SELECT DISTINCT - + col2 * + col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col2 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT + col1 * - ( col2 ) + - 35 AS col1 FROM tab1 AS cor0
----
-1283
-1439
-605

query I rowsort
SELECT ALL 21 FROM tab2 cor0
----
21
21
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2529
SELECT + - CAST( NULL AS SIGNED ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2529
SELECT + - CAST ( NULL AS INTEGER ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 48 * + col2 AS col0 FROM tab1 AS cor0
----
-2592
-2736
-4608

query I rowsort
SELECT DISTINCT + + ( col2 ) + col2 AS col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - - col1 * + 93 AS col1 FROM tab1 AS cor0
----
1209
2418
930

query I rowsort
SELECT ALL + ( col0 ) * - col2 + - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-2534
SELECT ALL - 86 + - col2 DIV + col1 AS col2 FROM tab2 cor0
----
-86
-86
-88

skipif mysql # not compatible
query I rowsort label-2534
SELECT ALL - 86 + - col2 / + col1 AS col2 FROM tab2 cor0
----
-86
-86
-88

query I rowsort
SELECT 96 * ( + col0 ) FROM tab0 AS cor0
----
2304
3360
8544

query I rowsort
SELECT DISTINCT + - col0 * 49 FROM tab2 AS cor0
----
-343
-3822
-3871

query I rowsort
SELECT + cor0.col1 * + col1 - col2 AS col1 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT ALL - 52 * col1 AS col0 FROM tab2 AS cor0
----
-1612
-3068
-884

query I rowsort
SELECT ALL cor0.col2 * 32 AS col0 FROM tab1 cor0
----
1728
1824
3072

query I rowsort
SELECT col0 - 10 AS col2 FROM tab2 AS cor0
----
-3
68
69

query I rowsort
SELECT ALL - ( 10 ) * col1 + cor0.col2 AS col1 FROM tab1 AS cor0
----
-206
-34
-43

query I rowsort
SELECT DISTINCT 55 * col2 + cor0.col0 AS col1 FROM tab1 AS cor0
----
2973
3199
5360

query I rowsort
SELECT ALL col0 * - 61 - col1 * col2 * + ( col0 * - col0 ) FROM tab1
----
12453
2330816
7982320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 63 + 49 col2 FROM tab1, tab0, tab2 cor0, tab2
----
81 values hashing to a58fbac92f43bc63036f08d7bd355007

onlyif mysql # use DIV operator for integer division
query I rowsort label-2545
SELECT + col0 DIV + 2 AS col0 FROM tab2
----
3
39
39

skipif mysql # not compatible
query I rowsort label-2545
SELECT + col0 / + 2 AS col0 FROM tab2
----
3
39
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 65 col1 FROM tab1
----
3510
3705
6240

query I rowsort
SELECT + - col1 + - col0 AS col2 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - - 37 + col0 * - col1 FROM tab2 AS cor0
----
-1306
-180
-4565

query I rowsort
SELECT cor0.col0 * + col0 * + 13 FROM tab0 AS cor0
----
102973
15925
7488

query I rowsort
SELECT + + col1 + - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - 61 * col0 AS col0 FROM tab1 AS cor0
----
-183
-3904
-4880

query I rowsort
SELECT - - 77 * - col2 FROM tab0 AS cor0
----
-2541
-6314
-77

query I rowsort
SELECT + + 22 * tab1.col0 + + cor0.col2 * - 25 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to d30bcc43939f8d2407a6cfb97cad3355

query I rowsort
SELECT col2 * + 24 - + col1 FROM tab0
----
-73
1877
706

query I rowsort
SELECT DISTINCT col2 * col2 * tab2.col2 FROM tab2
----
17576
19683
54872

query I rowsort
SELECT ALL 38 * + col0 FROM tab2
----
266
2964
3002

query I rowsort
SELECT 55 * 6 + - col0 AS col1 FROM tab0
----
241
295
306

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2558
SELECT ALL CAST( 71 AS SIGNED ) * col2 FROM tab2
----
1846
1917
2698

skipif mysql # not compatible
query I rowsort label-2558
SELECT ALL CAST ( 71 AS INTEGER ) * col2 FROM tab2
----
1846
1917
2698

query I rowsort
SELECT DISTINCT 31 FROM tab2 AS cor0
----
31

query I rowsort
SELECT DISTINCT 26 AS col2 FROM tab1
----
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2561
SELECT ALL - + col2 DIV + col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2561
SELECT ALL - + col2 / + col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col2 + col2 col1 FROM tab1
----
0

query I rowsort
SELECT + 94 * col0 + 59 FROM tab2 AS cor0
----
717
7391
7485

onlyif mysql # use DIV operator for integer division
query I rowsort label-2564
SELECT - col2 DIV col0 + - cor0.col2 - col0 * + col1 AS col1 FROM tab2 AS cor0
----
-1381
-247
-4628

skipif mysql # not compatible
query I rowsort label-2564
SELECT - col2 / col0 + - cor0.col2 - col0 * + col1 AS col1 FROM tab2 AS cor0
----
-1381
-247
-4628

query I rowsort
SELECT cor0.col1 AS col0 FROM tab2, tab0 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT ALL + 56 + + col2 * ( cor0.col0 ) * - col0 FROM tab2 AS cor0
----
-1267
-158128
-237102

query I rowsort
SELECT + + col1 * + col0 AS col2 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT + - cor0.col0 + + col0 * + col2 AS col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT - 71 + cor0.col0 FROM tab0 AS cor0
----
-36
-47
18

query I rowsort
SELECT col0 + + col1 * 55 - 50 AS col1 FROM tab2 AS cor0
----
1662
3273
964

onlyif mysql # use DIV operator for integer division
query I rowsort label-2571
SELECT + 80 DIV col2 + col2 * ( + cor0.col2 ) + + 43 AS col0 FROM tab0 AS cor0
----
1134
124
6767

skipif mysql # not compatible
query I rowsort label-2571
SELECT + 80 / col2 + col2 * ( + cor0.col2 ) + + 43 AS col0 FROM tab0 AS cor0
----
1134
124
6767

query I rowsort
SELECT + col2 + - cor0.col0 - col0 FROM tab0 cor0
----
-15
-69
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2573
SELECT DISTINCT + col2 + - col0 * - CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
4153
63
6496

skipif mysql # not compatible
query I rowsort label-2573
SELECT DISTINCT + col2 + - col0 * - CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2574
SELECT - CAST( NULL AS SIGNED ) * + 7 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2574
SELECT - CAST ( NULL AS INTEGER ) * + 7 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2575
SELECT DISTINCT + col0 * - CAST( col0 AS SIGNED ) AS col0 FROM tab2
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-2575
SELECT DISTINCT + col0 * - CAST ( col0 AS INTEGER ) AS col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT ALL + col0 * + col2 + + ( col0 ) AS col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + + col1 * - 22 + - col0 AS col0 FROM tab1 AS cor0
----
-284
-366
-575

query I rowsort
SELECT + col1 + - 38 AS col1 FROM tab2 AS cor0
----
-21
-7
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 21 * + col1 col2 FROM tab2 AS cor0
----
1161
278
644

query I rowsort
SELECT ALL col0 * 74 FROM tab2 AS cor0
----
518
5772
5846

query I rowsort
SELECT DISTINCT - col1 + 36 * ( + col0 ) FROM tab2 cor0
----
221
2749
2827

query I rowsort
SELECT DISTINCT - col2 - col0 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2583
SELECT ALL + cor0.col2 * + CAST( + col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-2583
SELECT ALL + cor0.col2 * + CAST ( + col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + cor0.col2 * + ( 57 ) + + cor0.col0 * - 5 AS col1 FROM tab1 AS cor0
----
2929
3063
5072

query I rowsort
SELECT DISTINCT + 59 + 11 AS col2 FROM tab2 AS cor0
----
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-2586
SELECT - 37 DIV col0 FROM tab1 AS cor0
----
-12
0
0

skipif mysql # not compatible
query I rowsort label-2586
SELECT - 37 / col0 FROM tab1 AS cor0
----
-12
0
0

query I rowsort
SELECT ALL - col2 * 53 FROM tab0 AS cor0
----
-1749
-4346
-53

query I rowsort
SELECT + col1 + 12 * cor0.col1 FROM tab2 AS cor0
----
221
403
767

query I rowsort
SELECT ALL 73 AS col1 FROM tab2 AS cor0
----
73
73
73

query I rowsort
SELECT - - col0 * 78 FROM tab2 AS cor0
----
546
6084
6162

query I rowsort
SELECT ALL + 72 * cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 6ea840cdf2b42247db0ed404945b7aa1

query I rowsort
SELECT ALL + + col0 * - col1 * + col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT + + 67 AS col0 FROM tab2 AS cor0
----
67
67
67

query I rowsort
SELECT DISTINCT - ( col2 ) + col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - - 69 * - col0 + col2 AS col0 FROM tab1 AS cor0
----
-153
-4359
-5424

query I rowsort
SELECT - ( - ( col1 ) ) * + col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - 60 AS col2 FROM tab0 cor0
----
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-2598
SELECT DISTINCT col0 + col2 DIV col0 + col0 FROM tab0 AS cor0
----
178
49
70

skipif mysql # not compatible
query I rowsort label-2598
SELECT DISTINCT col0 + col2 / col0 + col0 FROM tab0 AS cor0
----
178
49
70

query I rowsort
SELECT ALL - + 88 + + 1 * col1 FROM tab2 AS cor0
----
-29
-57
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 51 col0 FROM tab2 AS cor0
----
-51
-51
-51

query I rowsort
SELECT ALL - 90 * - col2 - + col1 AS col2 FROM tab1 AS cor0
----
4834
5120
8627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - 31 ) + col2 * ( col2 ) * + cor0.col2 col2 FROM tab1 AS cor0
----
157433
185162
884705

query I rowsort
SELECT ALL + + col2 + + col1 AS col0 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2604
SELECT + CAST( NULL AS SIGNED ) * col2 * col1 + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2604
SELECT + CAST ( NULL AS INTEGER ) * col2 * col1 + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 50 + + col0 FROM tab1 AS cor0
----
114
130
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 + 34 col1 FROM tab1
----
1282
1438
604

query I rowsort
SELECT - col2 + + cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT + 89 AS col2 FROM tab0
----
89

query I rowsort
SELECT + ( - 37 * + col1 ) FROM tab2
----
-1147
-2183
-629

query I rowsort
SELECT + 26 * col2 * 91 AS col1 FROM tab1 AS cor0
----
127764
134862
227136

query I rowsort
SELECT ALL - ( - cor0.col2 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ( col2 * - col2 + - 21 ) AS col2 FROM tab0
----
-1110
-22
-6745

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 40 + col0 col2 FROM tab2
----
118
119
47

query I rowsort
SELECT col1 * ( - 81 * - cor0.col2 ) FROM tab0 AS cor0
----
229878
604422
7857

query I rowsort
SELECT DISTINCT + - col1 * - 98 + cor0.col2 * - col1 - + 58 AS col0 FROM tab1 AS cor0
----
-32
1086
352

query I rowsort
SELECT DISTINCT cor0.col1 - + col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT DISTINCT col2 + + 20 * col1 AS col0 FROM tab2 AS cor0
----
1206
378
647

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * - col1 - - col2 col0 FROM tab0 cor0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + col1 + 71 col0 FROM tab1 cor0
----
171
240
747

query I rowsort
SELECT - 92 AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a0e6b76227d870d10c4d9f46545a7c83

query I rowsort
SELECT ALL col0 * tab2.col2 + col1 * tab2.col1 FROM tab2
----
1150
3291
5509

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 12 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT col2 * ( - tab0.col2 + col0 * - col0 ) AS col2 FROM tab0
----
-1226
-20097
-656246

query I rowsort
SELECT - col0 + ( - col1 * + col2 ) FROM tab1
----
-1328
-1407
-634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 82 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

onlyif mysql # use DIV operator for integer division
query I rowsort label-2626
SELECT col1 DIV 67 + - ( + col1 ) FROM tab0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2626
SELECT col1 / 67 + - ( + col1 ) FROM tab0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT + col0 + - 14 FROM tab2 AS cor0
----
-7
64
65

skipif mysql # not compatible
query I rowsort
SELECT - col1 * - CAST ( - cor0.col2 AS REAL ) * cor0.col0 + - ( 78 ) AS col0 FROM tab0 AS cor0
----
-3473
-664196
-68190

query I rowsort
SELECT ALL + col1 + col2 * - 63 FROM tab0 AS cor0
----
-1993
-5075
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2630
SELECT cor0.col1 * col1 + - cor0.col1 DIV + col0 FROM tab1 AS cor0
----
100
169
668

skipif mysql # not compatible
query I rowsort label-2630
SELECT cor0.col1 * col1 + - cor0.col1 / + col0 FROM tab1 AS cor0
----
100
169
668

query I rowsort
SELECT + 49 * col0 - + col1 * + 71 FROM tab2 AS cor0
----
-1858
-367
2664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 32 * col0 - ( col0 ) * + col0 col2 FROM tab0 AS cor0
----
-10769
-1344
-2345

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2633
SELECT - + 54 - - col0 * + CAST( + col2 + col0 AS SIGNED ) FROM tab2 AS cor0
----
184
8058
9189

skipif mysql # not compatible
query I rowsort label-2633
SELECT - + 54 - - col0 * + CAST ( + col2 + col0 AS INTEGER ) FROM tab2 AS cor0
----
184
8058
9189

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 + ( - col1 * cor0.col2 ) col2 FROM tab0 AS cor0
----
-2262
1128
459

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2635
SELECT col2 + + 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-2635
SELECT col2 + + col0 * - CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + + col0 * tab2.col0 FROM tab2
----
22
6058
6203

query I rowsort
SELECT 64 + + col0 * col1 FROM tab0
----
2128
3459
8163

query I rowsort
SELECT ALL - 42 FROM tab0
----
-42
-42
-42

onlyif mysql # use DIV operator for integer division
query I rowsort label-2639
SELECT - tab0.col1 * - tab0.col2 DIV col2 AS col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2639
SELECT - tab0.col1 * - tab0.col2 / col2 AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT - col0 * - tab1.col1 * ( - 66 ) FROM tab1
----
-42240
-5148
-68640

onlyif mysql # use DIV operator for integer division
query I rowsort label-2641
SELECT - + col2 * - col0 DIV + col0 + col0 * - col1 DIV - col1 col0 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2641
SELECT - + col2 * - col0 / + col0 + col0 * - col1 / - col1 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL 56 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 32 * - col0 col1 FROM tab2
----
-224
-2496
-2528

query I rowsort
SELECT - ( - 45 ) FROM tab0, tab1 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

onlyif mysql # use DIV operator for integer division
query I rowsort label-2645
SELECT ALL - col0 DIV 8 FROM tab1
----
-10
-8
0

skipif mysql # not compatible
query I rowsort label-2645
SELECT ALL - col0 / 8 FROM tab1
----
-10
-8
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2646
SELECT CAST( NULL AS SIGNED ) * + 67 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2646
SELECT CAST ( NULL AS INTEGER ) * + 67 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 86 FROM tab0, tab1 AS cor0, tab1 cor1
----
86

query I rowsort
SELECT DISTINCT + 19 * ( tab0.col2 ) + - 67 AS col2 FROM tab0, tab1 cor0
----
-48
1491
560

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-2650
SELECT - col1 * CAST( col1 AS SIGNED ) AS col2 FROM tab2 cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-2650
SELECT - col1 * CAST ( col1 AS INTEGER ) AS col2 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + 49 FROM tab0, tab1 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT + - ( - 14 ) + col2 * - ( - col2 ) AS col2 FROM tab2 AS cor0
----
1458
690
743

query I rowsort
SELECT ALL - - 70 * col2 * - cor0.col2 FROM tab2 AS cor0
----
-101080
-47320
-51030

query I rowsort
SELECT 73 FROM tab2 cor0
----
73
73
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-2655
SELECT + - 60 DIV + 14 FROM tab1 AS cor0
----
-4
-4
-4

skipif mysql # not compatible
query I rowsort label-2655
SELECT + - 60 / + 14 FROM tab1 AS cor0
----
-4
-4
-4

query I rowsort
SELECT ALL + 3 * 79 AS col0 FROM tab0
----
237
237
237

query I rowsort
SELECT - col0 * - col0 + col2 FROM tab2
----
6110
6279
76

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col2 AS REAL ) - + tab2.col2 FROM tab2
----
-52
-54
-76

query I rowsort
SELECT ( + ( - col2 ) ) AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + 71 AS col1 FROM tab0, tab2 cor0
----
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2661
SELECT ALL - CAST( NULL AS SIGNED ) * + col2 * - tab1.col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2661
SELECT ALL - CAST ( NULL AS INTEGER ) * + col2 * - tab1.col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2662
SELECT DISTINCT - col0 DIV - col0 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-2662
SELECT DISTINCT - col0 / - col0 FROM tab1
----
1

query I rowsort
SELECT + - cor0.col0 * + col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - 2 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT ALL - cor1.col2 - 88 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to e390566f79823b1ed04d31152dd5b928

query I rowsort
SELECT ALL + ( col0 ) + - col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - col2 * + col2 + + 95 FROM tab2 AS cor0
----
-1349
-581
-634

query I rowsort
SELECT ALL + - 75 + col2 AS col2 FROM tab0 AS cor0
----
-42
-74
7

query I rowsort
SELECT - 37 * col1 FROM tab2 AS cor0
----
-1147
-2183
-629

query I rowsort
SELECT - - 28 * + col2 FROM tab2 AS cor0
----
1064
728
756

query I rowsort
SELECT - - 22 AS col0 FROM tab1 AS cor0
----
22
22
22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + cor0.col1 * - col1 col0 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT ALL - 51 + + col0 FROM tab1 AS cor0
----
-48
13
29

query I rowsort
SELECT + 5 AS col2 FROM tab1 AS cor0
----
5
5
5

query I rowsort
SELECT ALL + ( col1 ) * col0 * - col0 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT + 88 * col2 FROM tab0 AS cor0
----
2904
7216
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 73 * - col1 col1 FROM tab2 AS cor0
----
-1241
-2263
-4307

query I rowsort
SELECT ALL + 25 + cor0.col1 + 92 * + 56 FROM tab0 cor0
----
5263
5268
5274

query I rowsort
SELECT ALL - 98 * - cor0.col1 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT - + col1 + ( - 40 ) AS col0 FROM tab1 cor0
----
-50
-53
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2681
SELECT + + col2 + - CAST( 89 AS SIGNED ) AS col2 FROM tab1 cor0
----
-32
-35
7

skipif mysql # not compatible
query I rowsort label-2681
SELECT + + col2 + - CAST ( 89 AS INTEGER ) AS col2 FROM tab1 cor0
----
-32
-35
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2682
SELECT col1 * + col1 + + ( col1 ) DIV 32 AS col1 FROM tab2 AS cor0
----
289
3482
961

skipif mysql # not compatible
query I rowsort label-2682
SELECT col1 * + col1 + + ( col1 ) / 32 AS col1 FROM tab2 AS cor0
----
289
3482
961

query I rowsort
SELECT + cor0.col0 + + col2 * + col2 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT - col0 * col0 + + col0 + + col1 FROM tab0 AS cor0
----
-1093
-466
-7741

query I rowsort
SELECT DISTINCT - - col0 * cor0.col2 + + ( col1 ) FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + cor0.col1 * 6 + + 47 AS col1 FROM tab1 cor0
----
107
125
203

onlyif mysql # use DIV operator for integer division
query I rowsort label-2687
SELECT col2 DIV - 80 + + cor0.col0 col0 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2687
SELECT col2 / - 80 + + cor0.col0 col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + - col2 + - col0 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + col0 + + ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + + 26 * col1 * col2 AS col1 FROM tab1 AS cor0
----
14820
32448
36504

query I rowsort
SELECT ALL - + 23 * + col1 FROM tab0 AS cor0
----
-1978
-2093
-2231

query I rowsort
SELECT DISTINCT - - ( 20 ) * col1 AS col1 FROM tab2 AS cor0
----
1180
340
620

query I rowsort
SELECT ( cor0.col0 ) + col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL col2 * + 62 AS col1 FROM tab0
----
2046
5084
62

query I rowsort
SELECT + tab1.col0 * tab1.col2 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cf1383d310e5e3e19470e0b8dc064d0c

query I rowsort
SELECT + 76 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT DISTINCT - col0 * + ( - col1 ) AS col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - - col2 * 10 + col1 FROM tab0 AS cor0
----
107
416
911

onlyif mysql # use DIV operator for integer division
query I rowsort label-2699
SELECT DISTINCT + col2 * - col1 * col2 + col2 DIV col1 AS col1 FROM tab1
----
-119801
-32485
-75814

skipif mysql # not compatible
query I rowsort label-2699
SELECT DISTINCT + col2 * - col1 * col2 + col2 / col1 AS col1 FROM tab1
----
-119801
-32485
-75814

query I rowsort
SELECT DISTINCT + col2 * - col1 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + col1 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - + col0 + col2 - + ( col2 * 63 + - col1 ) AS col2 FROM tab2 AS cor0
----
-1631
-1650
-2418

query I rowsort
SELECT DISTINCT - - cor0.col1 AS col1 FROM tab0 cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * cor0.col2 col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT 97 + - tab0.col1 AS col1 FROM tab0
----
0
11
6

query I rowsort
SELECT 62 + col1 AS col1 FROM tab0
----
148
153
159

query I rowsort
SELECT + col2 * col1 - - col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT + col1 * 67 + 37 FROM tab2
----
1176
2114
3990

query I rowsort
SELECT DISTINCT col0 * - col0 + - 62 * + col1 AS col1 FROM tab0 AS cor0
----
-13563
-5908
-7239

query I rowsort
SELECT ALL + - col0 * - col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - col0 * - 66 AS col2 FROM tab0 AS cor0
----
1584
2310
5874

query I rowsort
SELECT ( col2 ) * col2 - - col0 AS col2 FROM tab0
----
1113
36
6813

query I rowsort
SELECT - ( col2 ) + cor0.col0 * + cor0.col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT + + ( 56 ) * - cor0.col1 FROM tab0 AS cor0
----
-4816
-5096
-5432

query I rowsort
SELECT DISTINCT + 56 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
56

query I rowsort
SELECT col2 + col2 + + col0 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT ALL ( col2 + col1 ) * + ( col1 + 54 ) AS col1 FROM tab1
----
4288
6400
7303

query I rowsort
SELECT ALL + col1 + + cor0.col1 * 16 AS col0 FROM tab0 cor0
----
1462
1547
1649

query I rowsort
SELECT DISTINCT + col0 * cor0.col2 * ( col1 ) FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT 1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT ALL + 2 + - col1 AS col1 FROM tab2 AS cor0
----
-15
-29
-57

query I rowsort
SELECT - ( + cor1.col2 ) FROM tab2 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT 14 + col2 AS col1 FROM tab1 cor0
----
110
68
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-2724
SELECT DISTINCT - col1 + - col2 DIV 57 FROM tab0 AS cor0
----
-86
-92
-97

skipif mysql # not compatible
query I rowsort label-2724
SELECT DISTINCT - col1 + - col2 / 57 FROM tab0 AS cor0
----
-86
-92
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2725
SELECT + col1 * cor0.col0 - + CAST( col2 AS SIGNED ) * col0 AS col0 FROM tab2 AS cor0
----
-1659
2574
28

skipif mysql # not compatible
query I rowsort label-2725
SELECT + col1 * cor0.col0 - + CAST ( col2 AS INTEGER ) * col0 AS col0 FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT DISTINCT - ( - col2 ) + col2 FROM tab1 AS cor0
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 45 + + col1 + ( - col0 ) col2 FROM tab1 AS cor0
----
-112
-22
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2728
SELECT DISTINCT col1 * col1 + + ( + ( + col1 ) + - 1 ) DIV - cor0.col2 FROM tab0 cor0
----
7394
8280
9313

skipif mysql # not compatible
query I rowsort label-2728
SELECT DISTINCT col1 * col1 + + ( + ( + col1 ) + - 1 ) / - cor0.col2 FROM tab0 cor0
----
7394
8280
9313

onlyif mysql # use DIV operator for integer division
query I rowsort label-2729
SELECT ALL - 81 * col1 DIV col1 + + col2 - col1 AS col1 FROM tab1 AS cor0
----
-34
-53
2

skipif mysql # not compatible
query I rowsort label-2729
SELECT ALL - 81 * col1 / col1 + + col2 - col1 AS col1 FROM tab1 AS cor0
----
-34
-53
2

query I rowsort
SELECT + - 17 + cor0.col2 AS col0 FROM tab2 AS cor0
----
10
21
9

query I rowsort
SELECT DISTINCT - - ( + cor0.col2 ) FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL + + 74 - - col0 FROM tab1 AS cor0
----
138
154
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col0 ) * - ( + col0 ) col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + cor0.col2 * ( - col0 ) AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT col2 * - col0 * - col1 FROM tab1 cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-2736
SELECT col1 + col1 DIV ( + col0 * - ( col2 ) ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2736
SELECT col1 + col1 / ( + col0 * - ( col2 ) ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - 26 + - col1 AS col1 FROM tab2
----
-43
-57
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - col1 col2 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT ALL + cor0.col0 * col2 + cor0.col1 AS col0 FROM tab0 cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - col2 ) col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col2 * + col1 * col1 FROM tab1 cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT + - ( + col0 ) * + col2 + 38 + col2 * - cor0.col0 FROM tab1 AS cor0
----
-15322
-286
-7258

query I rowsort
SELECT DISTINCT - - col0 * col2 - col2 AS col2 FROM tab2 AS cor0
----
162
2002
2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + ( - col1 ) col0 FROM tab2
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2745
SELECT - col0 + 70 DIV - col0 + - tab0.col1 FROM tab0
----
-112
-134
-180

skipif mysql # not compatible
query I rowsort label-2745
SELECT - col0 + 70 / - col0 + - tab0.col1 FROM tab0
----
-112
-134
-180

query I rowsort
SELECT + 66 + - tab0.col2 * - col2 AS col0 FROM tab0
----
1155
67
6790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 15 + 56 col2 FROM tab2
----
71

query I rowsort
SELECT col2 + 15 FROM tab0
----
16
48
97

query I rowsort
SELECT DISTINCT + 76 FROM tab0, tab1 AS cor0
----
76

query I rowsort
SELECT - ( - col2 ) * - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-2751
SELECT DISTINCT + col1 DIV + tab0.col1 AS col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-2751
SELECT DISTINCT + col1 / + tab0.col1 AS col0 FROM tab0
----
1

query I rowsort
SELECT + - cor0.col0 + + col0 * col2 AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT + - 55 * - col2 AS col1 FROM tab2 AS cor0
----
1430
1485
2090

query I rowsort
SELECT ALL col1 + - col1 * - col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - + 1 * col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT 63 * + col0 FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT + col1 * - col0 - - col0 AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - 79 FROM tab2, tab1 AS cor0
----
-79

query I rowsort
SELECT ALL - col2 + - col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + col1 * 7 + col0 AS col0 FROM tab2 AS cor0
----
198
224
491

query I rowsort
SELECT - col2 + 80 * - col1 AS col1 FROM tab1 AS cor0
----
-1136
-2134
-857

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2762
SELECT CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2762
SELECT CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + - col2 + ( col1 ) FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - - col2 * col0 + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-2765
SELECT col1 DIV + col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2765
SELECT col1 / + col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL - 89 * col2 FROM tab0 AS cor0
----
-2937
-7298
-89

query I rowsort
SELECT DISTINCT - - 27 AS col2 FROM tab2 cor0
----
27

query I rowsort
SELECT DISTINCT col2 * + 19 + + col0 * - 62 FROM tab1 AS cor0
----
-2885
-3136
840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2769
SELECT DISTINCT - + CAST( col2 AS SIGNED ) - col1 FROM tab0 cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-2769
SELECT DISTINCT - + CAST ( col2 AS INTEGER ) - col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT - - 27 * + 76 + col0 AS col2 FROM tab1 cor0
----
2055
2116
2132

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2771
SELECT + + CAST( + col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2771
SELECT + + CAST ( + col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT 12 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to c60b9398e29d6382e0d15363f9325811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + tab0.col2 col0 FROM tab0
----
164
2
66

query I rowsort
SELECT + cor0.col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT 79 AS col1 FROM tab2, tab2 cor0
----
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2776
SELECT ALL - col0 * - CAST( ( + col2 ) AS SIGNED ) AS col2 FROM tab2
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-2776
SELECT ALL - col0 * - CAST ( ( + col2 ) AS INTEGER ) AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT ( col0 + + col1 ) AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT + 58 * 7 * + col0 + + ( col2 ) FROM tab1
----
1272
26041
32576

query I rowsort
SELECT ALL + + tab0.col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + + 5 * 56 * - col2 + cor0.col1 FROM tab2 AS cor0
----
-10623
-7221
-7529

query I rowsort
SELECT DISTINCT + 11 AS col1 FROM tab0 cor0
----
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-2782
SELECT ( - col0 ) DIV col1 AS col1 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-2782
SELECT ( - col0 ) / col1 AS col1 FROM tab1
----
-6
-6
0

query I rowsort
SELECT ALL tab0.col0 * tab0.col1 AS col2 FROM tab0, tab2, tab2 cor0
----
27 values hashing to aff311fa1b3948e179779cc03c1fade4

query I rowsort
SELECT 64 * + tab0.col0 AS col0 FROM tab0
----
1536
2240
5696

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab1, tab0, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT 69 AS col2 FROM tab2
----
69

query I rowsort
SELECT ALL 16 * col0 AS col1 FROM tab2
----
112
1248
1264

query I rowsort
SELECT 83 + col1 + col1 * + col1 FROM tab2
----
1075
3623
389

query I rowsort
SELECT col1 * cor0.col1 + col0 FROM tab0 AS cor0
----
7420
8370
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-2790
SELECT + cor0.col0 DIV 91 + + col0 DIV col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2790
SELECT + cor0.col0 / 91 + + col0 / col0 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * + 18 col0 FROM tab0 AS cor0
----
-1602
-432
-630

query I rowsort
SELECT DISTINCT col1 + col0 * + 56 AS col0 FROM tab0 AS cor0
----
1430
2057
5075

query I rowsort
SELECT col2 * col0 + + col0 - col0 * 6 FROM tab0 cor0
----
-140
672
6853

query I rowsort
SELECT ALL col1 + + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2795
SELECT ALL + col1 DIV 36 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2795
SELECT ALL + col1 / 36 AS col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2796
SELECT ALL + - col1 * + 46 - 42 DIV + col0 col0 FROM tab1 AS cor0
----
-1210
-460
-598

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2796
SELECT ALL + - col1 * + 46 - 42 / + col0 col0 FROM tab1 AS cor0
----
-1210
-460
-598

query I rowsort
SELECT DISTINCT - col1 + col1 * 54 AS col0 FROM tab1 AS cor0
----
1378
530
689

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2798
SELECT + - col1 * + CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-2798
SELECT + - col1 * + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - col0 * - 61 AS col2 FROM tab0 AS cor0
----
1464
2135
5429

query I rowsort
SELECT - col0 * + ( col2 ) * col0 FROM tab0 cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT - cor0.col1 + col2 AS col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT ALL + - col0 + cor0.col0 * ( 21 ) FROM tab2 AS cor0
----
140
1560
1580

onlyif mysql # use DIV operator for integer division
query I rowsort label-2803
SELECT DISTINCT ( - col0 ) + - col0 * col0 DIV col1 AS col2 FROM tab1 AS cor0
----
-3
-473
-572

skipif mysql # not compatible
query I rowsort label-2803
SELECT DISTINCT ( - col0 ) + - col0 * col0 / col1 AS col2 FROM tab1 AS cor0
----
-3
-473
-572

query I rowsort
SELECT ALL + col2 * col2 - col0 FROM tab1 AS cor0
----
2913
3185
9136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + cor0.col1 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - 94 * + col1 + - col0 FROM tab1 AS cor0
----
-1004
-1302
-2447

query I rowsort
SELECT DISTINCT - - col0 * col0 + ( 53 ) FROM tab2 AS cor0
----
102
6137
6294

query I rowsort
SELECT ALL + + col1 - - cor0.col2 AS col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2809
SELECT ALL - col1 * col1 DIV - 81 AS col0 FROM tab2 AS cor0
----
11
3
42

skipif mysql # not compatible
query I rowsort label-2809
SELECT ALL - col1 * col1 / - 81 AS col0 FROM tab2 AS cor0
----
11
3
42

query I rowsort
SELECT - cor0.col2 * - 13 AS col0 FROM tab2 cor0
----
338
351
494

query I rowsort
SELECT cor0.col0 + + col0 + ( col2 * - col1 ) AS col0 FROM tab1 cor0
----
-1088
-1398
-442

onlyif mysql # use DIV operator for integer division
query I rowsort label-2812
SELECT col2 DIV - CAST( - col0 * col2 AS SIGNED ) FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2812
SELECT col2 / - CAST ( - col0 * col2 AS INTEGER ) FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - tab2.col0 col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT DISTINCT - col1 * + col0 + + col1 * col2 AS col2 FROM tab2 cor0
----
-3068
-697
620

query I rowsort
SELECT DISTINCT - col0 + cor0.col2 * - col1 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-2816
SELECT col2 DIV + CAST( - col2 AS SIGNED ) FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2816
SELECT col2 / + CAST ( - col2 AS INTEGER ) FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL 99 * col2 FROM tab0
----
3267
8118
99

query I rowsort
SELECT DISTINCT + tab0.col0 + + tab0.col1 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT ( - tab1.col0 + - col2 ) AS col2 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT col2 + + col0 * - col0 FROM tab1 WHERE NOT col0 NOT IN ( col1 )
----

query I rowsort
SELECT DISTINCT - col2 + tab1.col0 * tab1.col0 FROM tab1
----
-45
4039
6304

onlyif mysql # use DIV operator for integer division
query I rowsort label-2822
SELECT + col0 * col2 DIV - col1 + + col0 AS col1 FROM tab2
----
-97
1
44

skipif mysql # not compatible
query I rowsort label-2822
SELECT + col0 * col2 / - col1 + + col0 AS col1 FROM tab2
----
-97
1
44

query I rowsort
SELECT ALL col0 FROM tab0 WHERE NOT col1 NOT IN ( tab0.col2 )
----

query I rowsort
SELECT col0 + tab1.col0 AS col1 FROM tab1
----
128
160
6

query I rowsort
SELECT + col0 + - col1 + tab2.col2 FROM tab2
----
100
3
45

query I rowsort
SELECT tab0.col1 * tab0.col0 AS col2 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col0 * col1 + col0 * col0 FROM tab2 WHERE NOT + col1 + col2 * - col0 IN ( col2 + col0 )
----
10686
266
7584

query I rowsort
SELECT - tab2.col1 + - col1 + tab2.col0 FROM tab2
----
-40
-55
45

query I rowsort
SELECT col0 + col2 + - col0 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT + col1 + - col0 * col0 + col2 FROM tab2
----
-5999
-6186
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 * col2 col2 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT + col1 FROM tab1 WHERE ( col2 ) IN ( col2 + col2 + + col1 * - col0 )
----

query I rowsort
SELECT ALL - col1 * + col2 - col2 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT ALL col1 * col0 * tab2.col0 - - col0 AS col2 FROM tab2
----
106176
1526
359034

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2835
SELECT ALL - CAST( NULL AS SIGNED ) + + col0 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2835
SELECT ALL - CAST ( NULL AS INTEGER ) + + col0 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + col0 * col2 AS col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT + col1 * + 28 AS col1 FROM tab2
----
1652
476
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2838
SELECT CAST( NULL AS SIGNED ) + col1 * - col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2838
SELECT CAST ( NULL AS INTEGER ) + col1 * - col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col0 + tab1.col2 ) * col1 FROM tab1
----
-1210
-1482
-2288

query I rowsort
SELECT 57 * col1 + 47 FROM tab1 AS cor0
----
1529
617
788

query I rowsort
SELECT 58 * - col2 + col1 FROM tab1 AS cor0
----
-3106
-3296
-5555

onlyif mysql # use DIV operator for integer division
query I rowsort label-2842
SELECT + col2 DIV + col1 + col0 FROM tab2 cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-2842
SELECT + col2 / + col1 + col0 FROM tab2 cor0
----
7
78
81

query I rowsort
SELECT + - col2 * col0 - col1 * + cor0.col0 FROM tab2 AS cor0
----
-406
-4345
-6630

query I rowsort
SELECT - 46 * col1 + col0 AS col0 FROM tab2 AS cor0
----
-1419
-2636
-703

query I rowsort
SELECT ALL + + ( - cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - - cor0.col0 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT 83 * cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 301b984ec517cdb90354f315dcab9f29

query I rowsort
SELECT - 39 - + 72 FROM tab1, tab0 AS cor0
----
9 values hashing to e2b4facad736216c70d28e44e6731f5c

query I rowsort
SELECT col1 + - tab2.col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT ALL + col2 * - 86 AS col0 FROM tab0 AS cor0
----
-2838
-7052
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-2851
SELECT ALL col1 DIV col2 AS col1 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2851
SELECT ALL col1 / col2 AS col1 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT ALL + cor2.col1 * 41 FROM tab1 cor0 CROSS JOIN tab2, tab1 AS cor1, tab0, tab0 cor2
----
243 values hashing to 365682f44da05a651bc89ee7466fb17c

query I rowsort
SELECT DISTINCT col2 * 1 + - ( - col2 ) * + col1 * + col1 FROM tab0 AS cor0
----
244101
679124
9410

query I rowsort
SELECT DISTINCT - cor0.col1 * + col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2855
SELECT - 91 DIV col2 FROM tab0 AS cor0
----
-1
-2
-91

skipif mysql # not compatible
query I rowsort label-2855
SELECT - 91 / col2 FROM tab0 AS cor0
----
-1
-2
-91

query I rowsort
SELECT - + 58 AS col0 FROM tab0 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT 30 AS col0 FROM tab0 AS cor0
----
30
30
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2858
SELECT + ( + cor0.col2 ) + - CAST( NULL AS SIGNED ) * - col2 * + col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2858
SELECT + ( + cor0.col2 ) + - CAST ( NULL AS INTEGER ) * - col2 * + col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * col1 + col1 AS col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT + cor0.col1 * - 54 * ( + cor0.col1 * + 35 ) AS col1 FROM tab0 AS cor0
----
-13978440
-15651090
-17783010

query I rowsort
SELECT DISTINCT - col0 * + col2 * - ( col2 ) FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT ALL 81 * col1 FROM tab0
----
6966
7371
7857

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab1 AS cor1, tab1, tab1 cor2
----
3645 values hashing to 44545a6297aa29bb730ffb907c13bc58

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0, tab2 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 52c9380a39df7a744b9f2f2c5bf55dd5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2865
SELECT - ( + 14 ) + col0 DIV + 41 col0 FROM tab0 cor0
----
-12
-14
-14

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2865
SELECT - ( + 14 ) + col0 / + 41 col0 FROM tab0 cor0
----
-12
-14
-14

query I rowsort
SELECT - + cor0.col0 + - 65 AS col0 FROM tab0 AS cor0
----
-100
-154
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2867
SELECT 21 + - col0 DIV col2 FROM tab0 cor0
----
-14
20
21

skipif mysql # not compatible
query I rowsort label-2867
SELECT 21 + - col0 / col2 FROM tab0 cor0
----
-14
20
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-2868
SELECT + + col2 DIV col0 + + ( - col2 ) + col1 FROM tab0 AS cor0
----
54
9
96

skipif mysql # not compatible
query I rowsort label-2868
SELECT + + col2 / col0 + + ( - col2 ) + col1 FROM tab0 AS cor0
----
54
9
96

query I rowsort
SELECT - - col1 * - col1 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2870
SELECT + 63 * - col0 + CAST( NULL AS DECIMAL ) + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2870
SELECT + 63 * - col0 + CAST ( NULL AS REAL ) + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + cor0.col1 * - col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT 99 * cor0.col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to bcd60d28479500be67fb7f800619901d

query I rowsort
SELECT DISTINCT + col2 - + cor0.col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - cor0.col1 - + col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - - ( - col1 ) + - col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + col2 + + col2 AS col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT - + col1 * col2 + + col0 * 39 - cor0.col1 AS col1 FROM tab0 AS cor0
----
-1988
-4082
1171

query I rowsort
SELECT + - 53 * col0 + 4 AS col1 FROM tab1 AS cor0
----
-155
-3388
-4236

onlyif mysql # use DIV operator for integer division
query I rowsort label-2879
SELECT DISTINCT 64 DIV 38 AS col1 FROM tab1, tab2 AS cor0, tab1 cor1
----
1

skipif mysql # not compatible
query I rowsort label-2879
SELECT DISTINCT 64 / 38 AS col1 FROM tab1, tab2 AS cor0, tab1 cor1
----
1

query I rowsort
SELECT + col2 + col1 * + ( - col1 ) - + col0 FROM tab1
----
-107
-153
-625

query I rowsort
SELECT DISTINCT + 15 AS col2 FROM tab0, tab1, tab0 AS cor0
----
15

query I rowsort
SELECT DISTINCT col1 + - col0 * + 71 AS col0 FROM tab2 AS cor0
----
-466
-5479
-5592

query I rowsort
SELECT + - col2 + 90 AS col2 FROM tab1 AS cor0
----
-6
33
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 + col1 col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + col0 * - col0 * - col2 AS col1 FROM tab0
----
1225
19008
649522

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2886
SELECT - 69 + + col2 * CAST( + 74 * col1 AS SIGNED ) + + 99 FROM tab2
----
113546
47834
61968

skipif mysql # not compatible
query I rowsort label-2886
SELECT - 69 + + col2 * CAST ( + 74 * col1 AS INTEGER ) + + 99 FROM tab2
----
113546
47834
61968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col1 col0 FROM tab0
----
119
173
98

query I rowsort
SELECT - 47 + - col2 FROM tab1
----
-101
-104
-143

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2889
SELECT DISTINCT cor0.col2 * CAST( NULL AS SIGNED ) + + ( tab2.col1 ) AS col2 FROM tab2, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2889
SELECT DISTINCT cor0.col2 * CAST ( NULL AS INTEGER ) + + ( tab2.col1 ) AS col2 FROM tab2, tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL ( + 8 ) AS col2 FROM tab0 cor0
----
8
8
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + - col1 col0 FROM tab2 AS cor0
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 33 * + col0 * cor0.col2 col2 FROM tab0 cor0
----
1155
240834
26136

query I rowsort
SELECT + col0 * + 45 AS col0 FROM tab0 AS cor0
----
1080
1575
4005

query I rowsort
SELECT DISTINCT + ( col2 ) * + col0 + col2 + + col1 FROM tab0 AS cor0
----
133
7471
911

query I rowsort
SELECT ALL - 26 * col1 * col2 - + col2 * col0 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-36018
218652
581952

query I rowsort
SELECT DISTINCT col2 * ( col2 + - col1 * + ( col1 ) ) FROM tab1
----
-2451
-33588
-7008

query I rowsort
SELECT ( col1 ) * + col0 + 36 AS col1 FROM tab0
----
2100
3431
8135

query I rowsort
SELECT DISTINCT + tab1.col1 - 7 FROM tab1
----
19
3
6

query I rowsort
SELECT col0 * 52 FROM tab0 AS cor0
----
1248
1820
4628

query I rowsort
SELECT - ( + cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + + 0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + ( 10 ) FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

query I rowsort
SELECT + col0 * - ( + col1 ) + + 41 + - col2 AS col0 FROM tab0 AS cor0
----
-2056
-3355
-8140

query I rowsort
SELECT - col0 * 25 FROM tab1 AS cor0
----
-1600
-2000
-75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2905
SELECT DISTINCT col1 + col1 * - col0 * - col2 + - CAST( col2 + - col0 * col2 AS SIGNED ) FROM tab1
----
107437
40081
4346

skipif mysql # not compatible
query I rowsort label-2905
SELECT DISTINCT col1 + col1 * - col0 * - col2 + - CAST ( col2 + - col0 * col2 AS INTEGER ) FROM tab1
----
107437
40081
4346

query I rowsort
SELECT DISTINCT tab0.col2 * tab0.col0 + 27 AS col1 FROM tab0
----
62
7325
819

onlyif mysql # use DIV operator for integer division
query I rowsort label-2907
SELECT - tab1.col1 DIV - col0 AS col1 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-2907
SELECT - tab1.col1 / - col0 AS col1 FROM tab1
----
0
0
8

query I rowsort
SELECT tab1.col0 * - 30 + + col1 AS col2 FROM tab1
----
-1910
-2387
-64

query I rowsort
SELECT + col2 * ( tab2.col0 * + col2 + + 28 * col1 ) AS col0 FROM tab2
----
132164
28539
95680

query I rowsort
SELECT DISTINCT - col2 + + col0 AS col2 FROM tab0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2911
SELECT + col0 - 77 DIV ( - cor0.col1 ) AS col1 FROM tab1 cor0
----
5
71
85

skipif mysql # not compatible
query I rowsort label-2911
SELECT + col0 - 77 / ( - cor0.col1 ) AS col1 FROM tab1 cor0
----
5
71
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2912
SELECT DISTINCT col1 / + CAST( NULL AS DECIMAL ) + 8 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2912
SELECT DISTINCT col1 / + CAST ( NULL AS REAL ) + 8 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2913
SELECT DISTINCT - - col2 DIV - 81 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-2913
SELECT DISTINCT - - col2 / - 81 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL + - cor0.col0 + 38 FROM tab2 AS cor0
----
-40
-41
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-2915
SELECT col0 + col1 DIV col2 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-2915
SELECT col0 + col1 / col2 FROM tab0 AS cor0
----
132
26
90

query I rowsort
SELECT ALL - 2 + + ( col1 ) * col1 * col1 AS col1 FROM tab2 AS cor0
----
205377
29789
4911

query I rowsort
SELECT DISTINCT - ( 15 ) * - col0 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1449
1530
2448

query I rowsort
SELECT + col0 * col2 + + col2 + + 18 AS col2 FROM tab2 AS cor0
----
2072
234
3058

query I rowsort
SELECT ALL + - 24 * - 4 FROM tab0 AS cor0
----
96
96
96

query I rowsort
SELECT + 52 * col1 * col0 + - 57 AS col1 FROM tab2 AS cor0
----
11227
239247
69779

query I rowsort
SELECT - 43 * - ( col2 ) + - 22 + col0 FROM tab0 cor0
----
1421
3593
56

query I rowsort
SELECT ALL - col2 + + 11 FROM tab2 AS cor0
----
-15
-16
-27

query I rowsort
SELECT ALL col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - 82 AS col0 FROM tab2 AS cor0
----
-82
-82
-82

query I rowsort
SELECT DISTINCT - 83 AS col0 FROM tab0 cor0
----
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 61 + - col1 col0 FROM tab1 AS cor0
----
-209
-3914
-4893

query I rowsort
SELECT DISTINCT - + 88 * - col1 FROM tab2 AS cor0
----
1496
2728
5192

onlyif mysql # use DIV operator for integer division
query I rowsort label-2928
SELECT ALL + + ( + col1 ) DIV cor0.col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-2928
SELECT ALL + + ( + col1 ) / cor0.col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT - - 5 * - col0 FROM tab1 AS cor0
----
-15
-320
-400

query I rowsort
SELECT ALL - 57 + col0 FROM tab0 AS cor0
----
-22
-33
32

query I rowsort
SELECT tab2.col0 * col2 + col1 * + col1 + + ( tab2.col1 * col1 ) FROM tab2
----
2111
3580
8990

query I rowsort
SELECT ALL col2 + 82 + + 62 AS col2 FROM tab0
----
145
177
226

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2933
SELECT - CAST( - ( col2 ) AS SIGNED ) * 66 FROM tab0 AS cor0
----
2178
5412
66

skipif mysql # not compatible
query I rowsort label-2933
SELECT - CAST ( - ( col2 ) AS INTEGER ) * 66 FROM tab0 AS cor0
----
2178
5412
66

query I rowsort
SELECT - col2 * + 78 + - col0 + + cor0.col2 * + col0 AS col0 FROM tab0 cor0
----
-1806
-78
813

query I rowsort
SELECT - 84 * - col2 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT DISTINCT - 17 + col0 AS col2 FROM tab1 AS cor0
----
-14
47
63

query I rowsort
SELECT - 34 + - col2 FROM tab0 AS cor0
----
-116
-35
-67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2938
SELECT ALL + col1 * + col1 - CAST( NULL AS SIGNED ) * + 92 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2938
SELECT ALL + col1 * + col1 - CAST ( NULL AS INTEGER ) * + 92 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 40 * + col0 + + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-1046
-1497
-3651

query I rowsort
SELECT ALL ( - col2 ) AS col1 FROM tab2 cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - - col0 * - col2 + + col1 + - ( col0 ) FROM tab2 AS cor0
----
-165
-2047
-3064

query I rowsort
SELECT + - col2 * col0 * - 33 FROM tab2 AS cor0
----
6237
66924
99066

query I rowsort
SELECT ALL + col1 * col1 + ( col2 ) * cor0.col2 FROM tab1 AS cor0
----
3349
3592
9385

query I rowsort
SELECT DISTINCT + col2 - - col1 * 81 AS col2 FROM tab1 AS cor0
----
1149
2160
867

query I rowsort
SELECT - ( 71 * + tab1.col2 + ( + col0 ) ) FROM tab1
----
-3837
-4111
-6896

query I rowsort
SELECT ALL cor0.col2 * + col1 - - col0 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT ALL - + col1 * col0 * - col2 + + col1 * col0 FROM tab1 AS cor0
----
100880
37120
4290

query I rowsort
SELECT ALL col1 + col1 + ( + col2 ) * + col1 FROM tab0 AS cor0
----
291
3010
7644

onlyif mysql # use DIV operator for integer division
query I rowsort label-2950
SELECT DISTINCT col0 + col2 - + ( - col2 ) DIV + col1 FROM tab2 AS cor0
----
104
119
34

skipif mysql # not compatible
query I rowsort label-2950
SELECT DISTINCT col0 + col2 - + ( - col2 ) / + col1 FROM tab2 AS cor0
----
104
119
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * - col2 - + col1 * col2 col1 FROM tab2 AS cor0
----
-648
2356
494

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-2953
SELECT col2 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2953
SELECT col2 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + cor0.col2 + col0 * - col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL - - col0 + + 72 FROM tab1 AS cor0
----
136
152
75

query I rowsort
SELECT col1 * 68 AS col1 FROM tab0 AS cor0
----
5848
6188
6596

onlyif mysql # use DIV operator for integer division
query I rowsort label-2957
SELECT ALL col1 DIV col2 col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2957
SELECT ALL col1 / col2 col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + 82 * + col2 FROM tab2
----
2132
2214
3116

query I rowsort
SELECT ALL col2 + - ( col2 ) * col1 * col0 FROM tab0 cor0
----
-3394
-664036
-68079

query I rowsort
SELECT DISTINCT cor0.col0 * + ( cor0.col1 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + 75 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 7 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT cor1.col1 * tab2.col0 FROM tab2, tab1 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 844a3644851af967df99084c38f3e6a7

query I rowsort
SELECT + 72 FROM tab1, tab1 cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

onlyif mysql # use DIV operator for integer division
query I rowsort label-2965
SELECT ALL - 28 DIV tab0.col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2965
SELECT ALL - 28 / tab0.col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col1 * col2 + - col0 AS col1 FROM tab2
----
1456
567
830

query I rowsort
SELECT ALL ( + cor0.col2 ) AS col2 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col2 * + col0 col0 FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col1 col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL - + col2 * col2 + - col1 + 14 AS col2 FROM tab1 AS cor0
----
-2928
-3245
-9215

onlyif mysql # use DIV operator for integer division
query I rowsort label-2971
SELECT DISTINCT - - ( + col0 ) DIV + col2 AS col0 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2971
SELECT DISTINCT - - ( + col0 ) / + col2 AS col0 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT - ( ( - col2 ) ) * + 92 - col2 * col0 AS col1 FROM tab2 AS cor0
----
2295
364
494

query I rowsort
SELECT + - 16 AS col2 FROM tab1 cor0
----
-16
-16
-16

query I rowsort
SELECT + col1 - 11 AS col2 FROM tab2 AS cor0
----
20
48
6

query I rowsort
SELECT ALL + ( + cor0.col2 ) * - col0 + + 96 FROM tab1 AS cor0
----
-3552
-66
-7584

query I rowsort
SELECT 20 * - col2 + - col1 FROM tab1 AS cor0
----
-1106
-1150
-1933

query I rowsort
SELECT - col0 * col2 + + cor0.col0 * + col1 FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT ALL - 76 + col2 FROM tab2 AS cor0
----
-38
-49
-50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2979
SELECT + CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2979
SELECT + CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col0 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - ( 44 ) * - col2 AS col1 FROM tab1 AS cor0
----
2376
2508
4224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 col1 FROM tab1, tab2 cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT 90 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT 41 * col1 AS col1 FROM tab2
----
1271
2419
697

query I rowsort
SELECT DISTINCT col2 * - col1 + col2 AS col1 FROM tab1
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-2986
SELECT + - col1 + - ( - cor0.col2 + - col1 ) DIV col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2986
SELECT + - col1 + - ( - cor0.col2 + - col1 ) / col1 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT - + ( col0 ) + col1 * - col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT 23 + col2 AS col2 FROM tab2 AS cor0
----
49
50
61

query I rowsort
SELECT 31 + col2 * + tab0.col1 AS col0 FROM tab0
----
128
2869
7493

query I rowsort
SELECT DISTINCT - - col1 - 8 FROM tab1 AS cor0
----
18
2
5

query I rowsort
SELECT cor0.col2 * + 31 * col2 AS col1 FROM tab0 AS cor0
----
208444
31
33759

query I rowsort
SELECT - - col1 * + col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - - col0 + - 56 FROM tab1 AS cor0
----
-53
24
8

query I rowsort
SELECT DISTINCT 83 AS col2 FROM tab1, tab2 AS cor0
----
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2995
SELECT ALL - col1 DIV - col0 - col0 DIV - col0 col0 FROM tab2
----
1
1
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2995
SELECT ALL - col1 / - col0 - col0 / - col0 col0 FROM tab2
----
1
1
5

query I rowsort
SELECT + col2 * + ( 81 ) + + col2 AS col2 FROM tab0 cor0
----
2706
6724
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col2 * cor0.col0 col0 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-2998
SELECT + col0 * 82 DIV col2 + + col2 * - cor0.col2 AS col2 FROM tab0 cor0
----
-1030
-6635
2869

skipif mysql # not compatible
query I rowsort label-2998
SELECT + col0 * 82 / col2 + + col2 * - cor0.col2 AS col2 FROM tab0 cor0
----
-1030
-6635
2869

onlyif mysql # use DIV operator for integer division
query I rowsort label-2999
SELECT col0 + col0 * 25 DIV - col1 FROM tab1 AS cor0
----
-73
-96
1

skipif mysql # not compatible
query I rowsort label-2999
SELECT col0 + col0 * 25 / - col1 FROM tab1 AS cor0
----
-73
-96
1

query I rowsort
SELECT 79 FROM tab2, tab2 cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT - col0 + 89 * 89 AS col2 FROM tab0
----
7832
7886
7897

query I rowsort
SELECT DISTINCT + col1 + - col0 * - col1 + col0 FROM tab0 AS cor0
----
2174
3527
8279

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3003
SELECT ALL - cor0.col0 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3003
SELECT ALL - cor0.col0 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - col2 + col1 col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL - col0 * 91 AS col0 FROM tab1 AS cor0
----
-273
-5824
-7280

query I rowsort
SELECT DISTINCT - col1 + 59 FROM tab2 cor0
----
0
28
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-3007
SELECT - col0 * ( col1 ) DIV + col0 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-3007
SELECT - col0 * ( col1 ) / + col0 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + col0 * - 92 FROM tab2 AS cor0
----
-644
-7176
-7268

query I rowsort
SELECT + col2 * - cor0.col0 + col0 * + ( col0 + + col1 ) FROM tab0 cor0
----
1848
4585
8722

query I rowsort
SELECT ALL + - col2 * + ( + col0 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + col0 + - col2 * + col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL col2 * col0 + + col2 AS col0 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-3013
SELECT cor0.col2 DIV + col2 + col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3013
SELECT cor0.col2 / + col2 + col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT col0 + ( + col1 * + col2 ) - col1 FROM tab0 cor0
----
2776
35
7460

query I rowsort
SELECT DISTINCT - + col2 + cor0.col2 AS col1 FROM tab1 cor0
----
0

query I rowsort
SELECT ALL - 59 * - cor0.col2 FROM tab1 AS cor0
----
3186
3363
5664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + col1 - - cor0.col2 * col0 col2 FROM tab1 AS cor0
----
134
3601
7597

query I rowsort
SELECT ALL + 19 AS col1 FROM tab2
----
19
19
19

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to f655b6f4c5b9ff73813030f2822ea1fd

query I rowsort
SELECT ALL - 25 * col1 AS col0 FROM tab2 AS cor0
----
-1475
-425
-775

query I rowsort
SELECT DISTINCT - col0 + cor0.col0 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - 28 + + col1 * 1 AS col2 FROM tab2 cor0
----
-11
3
31

query I rowsort
SELECT ALL + 28 FROM tab0 AS cor0
----
28
28
28

query I rowsort
SELECT + + col0 + - 42 * ( + col2 + ( cor0.col2 ) * + col0 ) FROM tab2 AS cor0
----
-127601
-86190
-9065

query I rowsort
SELECT ALL + col1 + + col1 * + cor0.col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - - cor0.col0 * + ( col1 * - col2 ) AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + col1 + col0 * - col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - 0 + tab0.col1 FROM tab0
----
86
91
97

query IIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0, tab0 cor0 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT + 1 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT ALL - 88 FROM tab2, tab0 AS cor0
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

query I rowsort
SELECT tab1.col2 + tab1.col1 AS col1 FROM tab1
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3033
SELECT CAST( NULL AS SIGNED ) + col1 * col0 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3033
SELECT CAST ( NULL AS INTEGER ) + col1 * col0 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 39 + tab0.col1 AS col2 FROM tab0, tab2 cor0
----
125
130
136

query I rowsort
SELECT ALL + 59 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT DISTINCT 42 + tab0.col0 FROM tab0
----
131
66
77

query I rowsort
SELECT DISTINCT - 29 FROM tab1
----
-29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3038
SELECT + col1 * tab0.col0 * CAST( - col1 AS SIGNED ) FROM tab0
----
-177504
-329315
-737009

skipif mysql # not compatible
query I rowsort label-3038
SELECT + col1 * tab0.col0 * CAST ( - col1 AS INTEGER ) FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT col1 + - tab1.col1 * 78 FROM tab1
----
-1001
-2002
-770

query I rowsort
SELECT - 4 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 39ed23475412c3cbba02ecdd2d7018e6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3041
SELECT + col1 * tab2.col0 DIV - ( col0 + + col2 * - 63 ) FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-3041
SELECT + col1 * tab2.col0 / - ( col0 + + col2 * - 63 ) FROM tab2
----
0
0
2

query I rowsort
SELECT - 87 * cor0.col2 + 44 AS col0 FROM tab1 AS cor0
----
-4654
-4915
-8308

query I rowsort
SELECT DISTINCT 61 * col2 * 49 AS col2 FROM tab1 AS cor0
----
161406
170373
286944

onlyif mysql # use DIV operator for integer division
query I rowsort label-3044
SELECT - col2 DIV tab0.col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3044
SELECT - col2 / tab0.col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + 89 + col2 FROM tab2 AS cor0
----
115
116
127

query I rowsort
SELECT DISTINCT - ( - col0 ) + + col1 * + 33 + - cor0.col2 FROM tab1 cor0
----
337
413
807

query I rowsort
SELECT col1 + + col2 * 56 AS col1 FROM tab0 AS cor0
----
153
1934
4683

query I rowsort
SELECT DISTINCT ( col2 ) * + ( col1 ) + col0 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 61 * col1 col0 FROM tab0
----
5160
5460
5820

query I rowsort
SELECT ALL + col0 * + 93 AS col0 FROM tab2
----
651
7254
7347

query I rowsort
SELECT DISTINCT col1 * + col1 + - ( col2 + - col1 * col1 ) FROM tab1 AS cor0
----
1298
143
242

query I rowsort
SELECT col1 * col0 + + 30 + + col2 AS col1 FROM tab0 AS cor0
----
2127
3426
8211

onlyif mysql # use DIV operator for integer division
query I rowsort label-3053
SELECT ALL - + col1 * 36 + col1 DIV col0 FROM tab2 AS cor0
----
-1112
-2124
-612

skipif mysql # not compatible
query I rowsort label-3053
SELECT ALL - + col1 * 36 + col1 / col0 FROM tab2 AS cor0
----
-1112
-2124
-612

query I rowsort
SELECT DISTINCT + + col2 - 49 AS col2 FROM tab2 AS cor0
----
-11
-22
-23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3055
SELECT ALL - CAST( - col2 AS SIGNED ) * + col0 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-3055
SELECT ALL - CAST ( - col2 AS INTEGER ) * + col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT cor0.col2 * - col0 * + col0 AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT + 85 FROM tab1 AS cor0
----
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3058
SELECT col0 DIV + ( - col0 + 57 ) FROM tab1 AS cor0
----
-3
-9
0

skipif mysql # not compatible
query I rowsort label-3058
SELECT col0 / + ( - col0 + 57 ) FROM tab1 AS cor0
----
-3
-9
0

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT ALL 49 + + cor0.col2 AS col0 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to eaf3c2e8d62e57f0bbe45627ff102c30

query I rowsort
SELECT ALL + ( + col0 ) + - col0 * + col1 AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT + + 97 AS col2 FROM tab1 AS cor0
----
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3063
SELECT - + 14 DIV col1 AS col1 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-3063
SELECT - + 14 / col1 AS col1 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL - + 47 AS col1 FROM tab2 AS cor0
----
-47
-47
-47

query I rowsort
SELECT DISTINCT - 60 * + tab1.col0 AS col2 FROM tab1
----
-180
-3840
-4800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 col1 FROM tab0, tab0 cor0, tab1 AS cor1
----
-86
-91
-97

query I rowsort
SELECT 53 * col1 FROM tab0 AS cor0
----
4558
4823
5141

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 29 + 75 col0 FROM tab1 AS cor0
----
104

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3069
SELECT + CAST( NULL AS SIGNED ) + col0 + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3069
SELECT + CAST ( NULL AS INTEGER ) + col0 + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 ) + col1 * - col0 col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ( + col0 ) * ( cor0.col1 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 68 * - col2 AS col0 FROM tab0 AS cor0
----
-2244
-5576
-68

query I rowsort
SELECT ALL - ( tab0.col0 * + tab0.col2 ) FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 59 col1 FROM tab1
----
59
59
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3075
SELECT 99 * + tab0.col0 + + col0 DIV + ( 26 ) AS col0 FROM tab0
----
2376
3466
8814

skipif mysql # not compatible
query I rowsort label-3075
SELECT 99 * + tab0.col0 + + col0 / + ( 26 ) AS col0 FROM tab0
----
2376
3466
8814

query I rowsort
SELECT - col2 * + cor0.col0 - + ( col0 ) FROM tab0 cor0
----
-70
-7387
-816

query I rowsort
SELECT ALL cor0.col0 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + col2 + + 76 FROM tab0 cor0
----
109
158
77

query I rowsort
SELECT ALL - - col2 + - 33 FROM tab2 AS cor0
----
-6
-7
5

query I rowsort
SELECT + - col2 + - ( cor0.col2 ) * col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT + cor0.col1 + + col2 * - col0 * + col0 AS col0 FROM tab0 AS cor0
----
-1128
-18922
-649431

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + - col0 + + col2 col2 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT ALL - col0 * cor0.col2 * + col1 + col1 + + ( col0 ) FROM tab1 AS cor0
----
-36406
-4183
-99747

query I rowsort
SELECT + - col0 * - 4 + col2 AS col0 FROM tab0 AS cor0
----
129
141
438

query I rowsort
SELECT DISTINCT col0 + col1 * 66 AS col1 FROM tab1
----
1719
724
938

query I rowsort
SELECT - col0 * + tab1.col2 * + tab1.col1 AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT col0 * - col2 + col2 * + col1 * + 56 AS col0 FROM tab2 AS cor0
----
33174
46683
83876

query I rowsort
SELECT - col2 * 32 + cor0.col1 * col2 FROM tab0 AS cor0
----
1782
4838
65

query I rowsort
SELECT ALL - + cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 5 - + cor0.col1 col1 FROM tab2 AS cor0
----
-12
-26
-54

query I rowsort
SELECT + col2 - col2 * - col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3092
SELECT DISTINCT - col2 - + col1 DIV col1 AS col2 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-3092
SELECT DISTINCT - col2 - + col1 / col1 AS col2 FROM tab1 AS cor0
----
-55
-58
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3093
SELECT DISTINCT ( col0 ) DIV + col2 AS col0 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3093
SELECT DISTINCT ( col0 ) / + col2 AS col0 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT ALL + + cor0.col0 + - col0 * col1 AS col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL col2 * col1 - - col0 * - col1 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT - 36 * - col2 FROM tab2 AS cor0
----
1368
936
972

query I rowsort
SELECT col2 * col0 * col2 AS col1 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT + tab0.col1 - col2 AS col2 FROM tab0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - tab1.col1 ) * col2 col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - - col2 + - col0 AS col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT + ( col1 ) + cor0.col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - ( - ( col1 ) ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL 92 FROM tab0, tab2 cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT col0 * 8 AS col1 FROM tab2
----
56
624
632

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT - 97 AS col1 FROM tab1, tab1 cor0
----
-97

query I rowsort
SELECT DISTINCT 88 * 44 FROM tab0, tab1 cor0
----
3872

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3108
SELECT CAST( + tab0.col1 + col2 AS SIGNED ) AS col0 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-3108
SELECT CAST ( + tab0.col1 + col2 AS INTEGER ) AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL 15 FROM tab2, tab0 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT ALL - 2 FROM tab0, tab2 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3111
SELECT + CAST( col2 AS SIGNED ) * col1 FROM tab1 cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-3111
SELECT + CAST ( col2 AS INTEGER ) * col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + - col0 + - 32 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
217
2418
2449

query I rowsort
SELECT DISTINCT col2 + + col0 * cor0.col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL - col0 + col1 * + col0 FROM tab1 AS cor0
----
576
75
960

query III rowsort
SELECT * FROM tab0 WHERE + col1 * + col1 NOT BETWEEN NULL AND ( - col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 col1 FROM tab2 AS cor0 CROSS JOIN tab1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

onlyif mysql # use DIV operator for integer division
query I rowsort label-3117
SELECT ALL col1 DIV + col2 col0 FROM tab0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3117
SELECT ALL col1 / + col2 col0 FROM tab0
----
1
2
97

query I rowsort
SELECT DISTINCT - tab0.col0 + + col1 AS col1 FROM tab0
----
2
62

query I rowsort
SELECT ALL col0 * col2 * col2 AS col1 FROM tab1 AS cor0
----
207936
737280
8748

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN NULL AND ( - col0 * col1 )
----

query I rowsort
SELECT - col0 * col1 + tab2.col2 * tab2.col1 + + col2 AS col0 FROM tab2
----
-3042
-659
647

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col2 * - tab0.col1 + - col1 col2 FROM tab0
----
-194
-2924
-7553

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT + col0 < - col2
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT + tab1.col1 * + col2 FROM tab1
----
1248
1404
570

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( - col1 ) IN ( + col1 + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3126
SELECT col0 * - col1 DIV col1 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3126
SELECT col0 * - col1 / col1 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - col0 + col1 * - cor0.col0 + + col1 AS col0 FROM tab1 AS cor0
----
-1107
-55
-694

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL NOT IN ( + col0 )
----

query I rowsort
SELECT + col0 * col1 * + col1 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT col2 * + col0 + col2 AS col1 FROM tab2
----
2054
216
3040

query I rowsort
SELECT - col1 * col2 * - col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT col2 + col2 * + col1 + + col2 FROM tab2
----
1586
722
891

query I rowsort
SELECT DISTINCT + col1 + - col0 + + tab1.col0 AS col0 FROM tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3134
SELECT + col0 - col2 DIV + col1 FROM tab2
----
7
77
78

skipif mysql # not compatible
query I rowsort label-3134
SELECT + col0 - col2 / + col1 FROM tab2
----
7
77
78

query I rowsort
SELECT ALL + col2 + + col0 * + col2 AS col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT - col2 * - col0 - col2 * col1 AS col2 FROM tab2
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-3137
SELECT DISTINCT + col0 + + tab1.col0 DIV - col0 AS col1 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3137
SELECT DISTINCT + col0 + + tab1.col0 / - col0 AS col1 FROM tab1
----
2
63
79

query I rowsort
SELECT DISTINCT col1 * + col2 + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + - col0 + col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT - cor0.col2 + - col1 * - col1 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT + + cor0.col2 * cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - + col1 + + col0 * - col2 FROM tab0 AS cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3143
SELECT + + col2 + cor0.col0 + col2 DIV cor0.col2 FROM tab0 AS cor0
----
172
37
58

skipif mysql # not compatible
query I rowsort label-3143
SELECT + + col2 + cor0.col0 + col2 / cor0.col2 FROM tab0 AS cor0
----
172
37
58

query I rowsort
SELECT DISTINCT - + col2 * - col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - col1 + cor0.col1 * - col1 + col0 * col0 AS col0 FROM tab0 AS cor0
----
-451
-6906
-8281

query I rowsort
SELECT + cor0.col1 + + col2 + col0 AS col1 FROM tab1 AS cor0
----
131
189
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + - col1 col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - cor0.col1 * col2 + - col1 AS col0 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-3149
SELECT ALL + col0 DIV cor0.col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3149
SELECT ALL + col0 / cor0.col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT - - col0 * - col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - col1 + col1 * cor0.col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL + col2 + + col2 * col1 FROM tab2 cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3153
SELECT + col0 * CAST( col2 AS SIGNED ) + - col2 * + cor0.col1 FROM tab1 AS cor0
----
-1242
3078
6432

skipif mysql # not compatible
query I rowsort label-3153
SELECT + col0 * CAST ( col2 AS INTEGER ) + - col2 * + cor0.col1 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT DISTINCT - col0 * + 12 FROM tab1 AS cor0
----
-36
-768
-960

query I rowsort
SELECT ALL cor0.col2 + + ( - cor0.col2 ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 * col2 * - ( 89 + tab0.col1 ) FROM tab0
----
-1343160
-18042
-496650

query I rowsort
SELECT + - 65 + cor0.col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 098c854922ddcdf37296c3322bbadeb1

query I rowsort
SELECT - ( - 61 ) AS col1 FROM tab2 AS cor0
----
61
61
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3159
SELECT ALL CAST( - cor0.col1 AS SIGNED ) FROM tab0, tab0 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

skipif mysql # not compatible
query I rowsort label-3159
SELECT ALL CAST ( - cor0.col1 AS INTEGER ) FROM tab0, tab0 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT + cor0.col1 * + 55 AS col1 FROM tab2 cor0
----
1705
3245
935

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3161
SELECT DISTINCT + - cor0.col2 * CAST( NULL AS DECIMAL ) - col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3161
SELECT DISTINCT + - cor0.col2 * CAST ( NULL AS REAL ) - col0 FROM tab1 cor0
----
NULL

query I rowsort
SELECT 95 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT 6 + cor0.col2 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 7e7bf41801025a34765567e3fa48855f

query I rowsort
SELECT ALL 40 * - col1 + + col2 AS col2 FROM tab2
----
-1213
-2334
-642

query I rowsort
SELECT ALL 53 + col0 AS col2 FROM tab1
----
117
133
56

query I rowsort
SELECT ALL ( col2 ) + + col2 AS col1 FROM tab2
----
52
54
76

query I rowsort
SELECT DISTINCT + col1 * + col0 - + col2 * 16 AS col0 FROM tab2 AS cor0
----
-215
4186
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-3168
SELECT ALL 5 DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3168
SELECT ALL 5 / + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + col1 * + ( col2 ) FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT 61 AS col2 FROM tab0, tab1, tab1 AS cor0
----
61

query I rowsort
SELECT col0 * col0 + col0 * + col0 * 88 FROM tab2
----
4361
541476
555449

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 79 col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT + 6 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3174
SELECT CAST( col0 + col0 AS SIGNED ) FROM tab1
----
128
160
6

skipif mysql # not compatible
query I rowsort label-3174
SELECT CAST ( col0 + col0 AS INTEGER ) FROM tab1
----
128
160
6

query I rowsort
SELECT ( + 79 ) + - col0 FROM tab0
----
-10
44
55

query I rowsort
SELECT ALL - + 70 - + col2 AS col1 FROM tab1 AS cor0
----
-124
-127
-166

query I rowsort
SELECT + 97 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT + 58 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT DISTINCT + - ( + col1 ) * 18 AS col0 FROM tab0 AS cor0
----
-1548
-1638
-1746

onlyif mysql # use DIV operator for integer division
query I rowsort label-3180
SELECT - - col0 DIV + col1 + cor0.col1 DIV col1 col2 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3180
SELECT - - col0 / + col1 + cor0.col1 / col1 col2 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3181
SELECT col1 + col0 DIV ( 62 ) AS col0 FROM tab1 AS cor0
----
11
14
26

skipif mysql # not compatible
query I rowsort label-3181
SELECT col1 + col0 / ( 62 ) AS col0 FROM tab1 AS cor0
----
11
14
26

query I rowsort
SELECT DISTINCT 10 + - cor0.col2 FROM tab2 AS cor0
----
-16
-17
-28

query I rowsort
SELECT ALL + cor0.col1 * col0 * col1 AS col0 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT - 88 * col0 AS col2 FROM tab0 AS cor0
----
-2112
-3080
-7832

query I rowsort
SELECT DISTINCT - col1 + cor0.col0 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 * - 38 AS col0 FROM tab1 AS cor0
----
155648
243200
342

query I rowsort
SELECT ALL - + 80 * col0 AS col2 FROM tab1 AS cor0
----
-240
-5120
-6400

query I rowsort
SELECT ALL - - 49 AS col0 FROM tab2 AS cor0
----
49
49
49

query I rowsort
SELECT - 1 * - tab1.col0 + col1 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3190
SELECT ALL - - 81 DIV - col0 AS col2 FROM tab2 cor0
----
-1
-1
-11

skipif mysql # not compatible
query I rowsort label-3190
SELECT ALL - - 81 / - col0 AS col2 FROM tab2 cor0
----
-1
-1
-11

query I rowsort
SELECT - 41 + col2 AS col2 FROM tab1 AS cor0
----
13
16
55

query I rowsort
SELECT DISTINCT - cor0.col0 * + col2 + - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL - 14 AS col1 FROM tab2
----
-14
-14
-14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + 83 col0 FROM tab0 AS cor0
----
107
118
172

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * ( + col0 ) * col2 col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + col0 * col2 + + 44 + + col2 FROM tab0 AS cor0
----
7424
80
869

onlyif mysql # use DIV operator for integer division
query I rowsort label-3197
SELECT DISTINCT - + col1 DIV col1 + + col1 - col0 AS col1 FROM tab0 AS cor0
----
1
61

skipif mysql # not compatible
query I rowsort label-3197
SELECT DISTINCT - + col1 / col1 + + col1 - col0 AS col1 FROM tab0 AS cor0
----
1
61

query I rowsort
SELECT - col2 * + col1 + col0 FROM tab0 cor0
----
-2814
-62
-7373

query I rowsort
SELECT - col0 * col0 * + col0 AS col2 FROM tab0
----
-13824
-42875
-704969

query I rowsort
SELECT ALL + 54 AS col0 FROM tab2
----
54
54
54

query I rowsort
SELECT DISTINCT - ( + col1 ) * col1 AS col0 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL ( col0 ) * col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL - 26 + cor0.col2 AS col2 FROM tab0 AS cor0
----
-25
56
7

query I rowsort
SELECT ALL - col0 + - 63 FROM tab2
----
-141
-142
-70

query I rowsort
SELECT 43 * col2 FROM tab0 AS cor0
----
1419
3526
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 39 col0 FROM tab2 AS cor0
----
39
39
39

query I rowsort
SELECT ALL - + col1 + col2 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - ( ( - col0 ) ) AS col0 FROM tab2 cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 58 col1 FROM tab0 AS cor0
----
-58
-58
-58

query I rowsort
SELECT DISTINCT + col1 * 69 + col1 AS col1 FROM tab0 AS cor0
----
6020
6370
6790

query I rowsort
SELECT ALL 17 * 99 + - col2 FROM tab0 AS cor0
----
1601
1650
1682

onlyif mysql # use DIV operator for integer division
query I rowsort label-3212
SELECT DISTINCT + - col1 + col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-3212
SELECT DISTINCT + - col1 + col0 / + col0 AS col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT + 18 - + cor0.col1 AS col2 FROM tab1 cor0
----
-8
5
8

query I rowsort
SELECT + - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT - 87 - + col1 * col1 * col0 FROM tab1 AS cor0
----
-13607
-2115
-6487

query I rowsort
SELECT ALL col2 * + col0 + + col2 AS col0 FROM tab2
----
2054
216
3040

query I rowsort
SELECT col2 - + col2 * col1 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT 40 + 25 * col0 AS col0 FROM tab1
----
115
1640
2040

onlyif mysql # use DIV operator for integer division
query I rowsort label-3219
SELECT col1 + - col0 DIV col0 col2 FROM tab1
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3219
SELECT col1 + - col0 / col0 col2 FROM tab1
----
12
25
9

query I rowsort
SELECT + 38 AS col1 FROM tab2
----
38
38
38

query I rowsort
SELECT ( tab1.col2 + col1 ) AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT - cor2.col0 + - cor2.col0 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 6294555425facfca7034d843ce1afa9a

onlyif mysql # use DIV operator for integer division
query I rowsort label-3223
SELECT + 2 DIV + 61 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3223
SELECT + 2 / + 61 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3224
SELECT - col2 DIV + 12 + col0 FROM tab1
----
-1
60
72

skipif mysql # not compatible
query I rowsort label-3224
SELECT - col2 / + 12 + col0 FROM tab1
----
-1
60
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-3225
SELECT ( col1 ) DIV - col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3225
SELECT ( col1 ) / - col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + 51 + col1 * - 78 FROM tab0 cor0
----
-6657
-7047
-7515

query I rowsort
SELECT ALL + col2 + + col1 AS col2 FROM tab1 cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 48 col2 FROM tab0 AS cor0
----
48
48
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-3229
SELECT + 3 DIV col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3229
SELECT + 3 / col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * + col0 * ( 39 ) AS col0 FROM tab2 AS cor0
----
1911
237276
243399

query I rowsort
SELECT ALL + 56 AS col1 FROM tab1 cor0
----
56
56
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3232
SELECT - CAST( - 13 AS SIGNED ) FROM tab1
----
13
13
13

skipif mysql # not compatible
query I rowsort label-3232
SELECT - CAST ( - 13 AS INTEGER ) FROM tab1
----
13
13
13

query I rowsort
SELECT DISTINCT + cor0.col0 + col0 * ( col0 ) FROM tab1 cor0
----
12
4160
6480

query I rowsort
SELECT - + col1 + + col1 + - col2 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3235
SELECT + - cor0.col0 + 20 DIV 21 + + col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3235
SELECT + - cor0.col0 + 20 / 21 + + col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 21 * - col2 col2 FROM tab0 AS cor0
----
-1631
-607
76

query I rowsort
SELECT ALL - cor0.col1 + cor0.col1 + - col2 * - col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL col2 * 70 + 20 + col0 FROM tab0 AS cor0
----
125
2354
5849

query I rowsort
SELECT ALL col0 + - 20 FROM tab2 AS cor0
----
-13
58
59

query I rowsort
SELECT + col1 * - 2 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-3241
SELECT + cor0.col1 DIV - ( - col1 ) AS col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3241
SELECT + cor0.col1 / - ( - col1 ) AS col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - tab2.col2 * 66 AS col2 FROM tab2
----
-1716
-1782
-2508

query I rowsort
SELECT DISTINCT - ( col2 ) + - cor0.col2 FROM tab1 cor0
----
-108
-114
-192

query I rowsort
SELECT 27 * 1 AS col1 FROM tab1 AS cor0
----
27
27
27

query I rowsort
SELECT DISTINCT - 81 * - col2 AS col0 FROM tab0 AS cor0
----
2673
6642
81

query I rowsort
SELECT + ( - 73 ) FROM tab1 AS cor0
----
-73
-73
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 81 + 51 col2 FROM tab0 AS cor0
----
-30
-30
-30

onlyif mysql # use DIV operator for integer division
query I rowsort label-3248
SELECT + col0 DIV 76 + + col2 FROM tab0 cor0
----
1
33
83

skipif mysql # not compatible
query I rowsort label-3248
SELECT + col0 / 76 + + col2 FROM tab0 cor0
----
1
33
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 55 * col0 + - col2 col1 FROM tab1 AS cor0
----
-219
-3577
-4496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + + col1 col2 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3251
SELECT DISTINCT + - 62 DIV 7 FROM tab0 AS cor0
----
-8

skipif mysql # not compatible
query I rowsort label-3251
SELECT DISTINCT + - 62 / 7 FROM tab0 AS cor0
----
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3252
SELECT CAST( NULL AS DECIMAL ) * + col1 + col2 * col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3252
SELECT CAST ( NULL AS REAL ) * + col1 + col2 * col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3253
SELECT ALL + - CAST( NULL AS SIGNED ) + 13 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3253
SELECT ALL + - CAST ( NULL AS INTEGER ) + 13 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( - cor0.col2 ) - + col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col2 * - col1 * - col1 AS col1 FROM tab0 cor0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT + 23 FROM tab0 AS cor0
----
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-3257
SELECT + ( - col0 ) DIV col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3257
SELECT + ( - col0 ) / col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL 39 * + col0 AS col2 FROM tab0 AS cor0
----
1365
3471
936

query I rowsort
SELECT - col1 * + col0 + + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT - ( col1 ) * + cor0.col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3261
SELECT ALL + col0 DIV 66 FROM tab2 cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3261
SELECT ALL + col0 / 66 FROM tab2 cor0
----
0
1
1

query I rowsort
SELECT DISTINCT - + ( 32 ) FROM tab1 AS cor0
----
-32

query I rowsort
SELECT ALL - + col1 * col1 * col1 + col0 * - col0 AS col1 FROM tab1 AS cor0
----
-17585
-5096
-8597

query I rowsort
SELECT col2 * + 4 * - 88 FROM tab2
----
-13376
-9152
-9504

query I rowsort
SELECT ALL - 45 * - 37 FROM tab2, tab2 AS cor0
----
9 values hashing to c923dc6cca93c6574bd076d64533ba81

query I rowsort
SELECT ALL ( - col0 ) * col2 + + 37 FROM tab1 AS cor0
----
-125
-3611
-7643

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3267
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col0 + col2 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3267
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col0 + col2 col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + ( 77 ) - + cor0.col0 AS col0 FROM tab0 AS cor0
----
-12
42
53

query I rowsort
SELECT - + col1 + 54 * cor0.col0 AS col2 FROM tab2 cor0
----
347
4153
4249

query I rowsort
SELECT ALL - col1 * - 51 * col1 FROM tab0 AS cor0
----
377196
422331
479859

query I rowsort
SELECT - col0 * cor0.col0 * cor0.col1 + col0 FROM tab1 AS cor0
----
-231
-40896
-83120

query I rowsort
SELECT DISTINCT col2 + + cor0.col1 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT 68 FROM tab1, tab2 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT DISTINCT - 11 AS col2 FROM tab1
----
-11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3275
SELECT ALL + CAST( NULL AS SIGNED ) - + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3275
SELECT ALL + CAST ( NULL AS INTEGER ) - + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + 80 - + 38 FROM tab2 AS cor0
----
101
59
73

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3278
SELECT ALL cor0.col0 DIV col1 - col2 col2 FROM tab2 AS cor0
----
-25
-27
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3278
SELECT ALL cor0.col0 / col1 - col2 col2 FROM tab2 AS cor0
----
-25
-27
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 34 - + col0 col1 FROM tab2
----
-44
-45
27

query I rowsort
SELECT - ( + cor0.col2 ) FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

onlyif mysql # use DIV operator for integer division
query I rowsort label-3281
SELECT DISTINCT + 62 - - col1 DIV col0 FROM tab1
----
62
70

skipif mysql # not compatible
query I rowsort label-3281
SELECT DISTINCT + 62 - - col1 / col0 FROM tab1
----
62
70

query I rowsort
SELECT DISTINCT - col1 + col1 * 66 FROM tab1
----
1690
650
845

query I rowsort
SELECT ALL + col2 * 44 + - col2 * + col2 * + ( col2 ) FROM tab2
----
-16432
-18495
-53200

query I rowsort
SELECT tab2.col2 + + tab2.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 993162448d72b066e1ac9ba4caa8d8d7

query I rowsort
SELECT ALL col0 * col2 + - col0 AS col2 FROM tab0
----
0
7209
768

query I rowsort
SELECT DISTINCT col2 + - tab2.col2 * col1 AS col2 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT ALL + col1 * cor0.col0 - cor0.col0 * col1 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3288
SELECT - cor0.col0 * - CAST( - cor0.col2 AS SIGNED ) + + col2 col2 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3288
SELECT - cor0.col0 * - CAST ( - cor0.col2 AS INTEGER ) + + col2 col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL + col0 + + ( + 52 ) * col1 FROM tab2 AS cor0
----
1619
3146
963

onlyif mysql # use DIV operator for integer division
query I rowsort label-3290
SELECT ALL col0 DIV + 69 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3290
SELECT ALL col0 / + 69 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + col1 + 48 AS col0 FROM tab2 AS cor0
----
107
65
79

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 + col2 * col0 - - col0 AS col0 FROM tab2 AS cor0
----
2782
4525
925

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - 36 + + 57 col2 FROM tab1 AS cor0
----
2001
2109
3513

query I rowsort
SELECT ALL + 29 * - col1 FROM tab1 cor0
----
-290
-377
-754

query I rowsort
SELECT DISTINCT - col2 + + col2 * 30 FROM tab1 AS cor0
----
1566
1653
2784

query I rowsort
SELECT DISTINCT + 30 * + cor0.col2 FROM tab1 AS cor0
----
1620
1710
2880

query I rowsort
SELECT + col2 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 40 col2 FROM tab2 AS cor0
----
40
40
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 + - ( + cor0.col1 ) col2 FROM tab1 AS cor0
----
-20
118
147

query I rowsort
SELECT - 20 * - col0 FROM tab2 AS cor0
----
140
1560
1580

query I rowsort
SELECT DISTINCT + col0 + + col0 * - ( + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL - + cor0.col0 * - col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT cor0.col2 * col1 * col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT + col0 + + col0 + - cor0.col2 * - col2 FROM tab2 AS cor0
----
1602
743
832

query I rowsort
SELECT DISTINCT + 29 AS col1 FROM tab0, tab2 AS cor0
----
29

query I rowsort
SELECT DISTINCT - col0 - - 89 FROM tab1 AS cor0
----
25
86
9

query I rowsort
SELECT + 37 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT ALL - 86 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
4644
4902
8256

query I rowsort
SELECT ALL - col0 + - col1 * col0 * col1 FROM tab0 cor0
----
-177528
-329350
-737098

query I rowsort
SELECT + - col2 + + 49 FROM tab1 AS cor0
----
-47
-5
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 99 col0 FROM tab2
----
99
99
99

query I rowsort
SELECT 1 + col0 AS col0 FROM tab0 AS cor0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3314
SELECT ALL ( + col0 ) * cor0.col1 + + CAST( - 24 AS SIGNED ) DIV + col1 FROM tab1 AS cor0
----
1039
638
78

skipif mysql # not compatible
query I rowsort label-3314
SELECT ALL ( + col0 ) * cor0.col1 + + CAST ( - 24 AS INTEGER ) / + col1 FROM tab1 AS cor0
----
1039
638
78

query I rowsort
SELECT DISTINCT - + col1 + + 30 AS col0 FROM tab2 AS cor0
----
-1
-29
13

query I rowsort
SELECT ( - cor0.col0 ) FROM tab1, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

onlyif mysql # use DIV operator for integer division
query I rowsort label-3317
SELECT ALL + CAST( - col1 AS SIGNED ) + - col0 + - col0 DIV - ( col1 ) AS col2 FROM tab1
----
-29
-68
-87

skipif mysql # not compatible
query I rowsort label-3317
SELECT ALL + CAST ( - col1 AS INTEGER ) + - col0 + - col0 / - ( col1 ) AS col2 FROM tab1
----
-29
-68
-87

query I rowsort
SELECT + + cor0.col0 + + cor0.col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT - ( + cor0.col1 ) FROM tab1, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3320
SELECT ALL + col2 * - col0 * + col1 + col2 + + col0 DIV col0 FROM tab1
----
-36422
-4157
-99743

skipif mysql # not compatible
query I rowsort label-3320
SELECT ALL + col2 * - col0 * + col1 + col2 + + col0 / col0 FROM tab1
----
-36422
-4157
-99743

query I rowsort
SELECT - col1 * + cor0.col0 * ( col1 ) - col0 AS col2 FROM tab0 AS cor0
----
-177528
-329350
-737098

onlyif mysql # use DIV operator for integer division
query I rowsort label-3322
SELECT 22 DIV col0 - ( + col0 ) col2 FROM tab1 AS cor0
----
-64
-80
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3322
SELECT 22 / col0 - ( + col0 ) col2 FROM tab1 AS cor0
----
-64
-80
4

query I rowsort
SELECT - 38 - - col1 FROM tab0 AS cor0
----
48
53
59

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2
----
3645 values hashing to b62c1ebc681aca72d13feadb888b3be7

query I rowsort
SELECT DISTINCT + ( + col1 + tab2.col1 ) FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT - 71 * col1 * 29 FROM tab2
----
-121481
-35003
-63829

query I rowsort
SELECT 93 * - col0 * col2 FROM tab0
----
-3255
-678714
-73656

onlyif mysql # use DIV operator for integer division
query I rowsort label-3328
SELECT ALL - 62 DIV col0 - col1 AS col0 FROM tab0
----
-88
-91
-98

skipif mysql # not compatible
query I rowsort label-3328
SELECT ALL - 62 / col0 - col1 AS col0 FROM tab0
----
-88
-91
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3329
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + 5 AS col2 FROM tab1, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3329
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + 5 AS col2 FROM tab1, tab0 AS cor0
----
NULL

query I rowsort
SELECT + + col2 * 34 AS col1 FROM tab0 AS cor0
----
1122
2788
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col0 * col0 col1 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT + 26 FROM tab0, tab1 cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

skipif mysql # not compatible
query I rowsort
SELECT ALL + col1 * CAST ( ( col2 ) AS REAL ) * + col2 FROM tab2
----
22599
24548
39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3334
SELECT DISTINCT col0 * + CAST( NULL AS SIGNED ) col2 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3334
SELECT DISTINCT col0 * + CAST ( NULL AS INTEGER ) col2 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT + - cor0.col0 FROM tab1, tab0, tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - 18 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

query I rowsort
SELECT + cor0.col1 * + 3 + + col2 AS col2 FROM tab2 cor0
----
120
203
89

query I rowsort
SELECT DISTINCT + col2 * 33 * col0 - - col0 AS col1 FROM tab0 cor0
----
1190
240923
26160

query I rowsort
SELECT DISTINCT 67 AS col1 FROM tab2, tab0 cor0
----
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col0 + + tab2.col1 ) col2 FROM tab2
----
137
38
96

query I rowsort
SELECT + col0 + - cor0.col1 AS col0 FROM tab2 cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 * col2 col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT - col1 * + 92 FROM tab2 AS cor0
----
-1564
-2852
-5428

query I rowsort
SELECT - 68 AS col1 FROM tab2 cor0
----
-68
-68
-68

query I rowsort
SELECT + ( col0 ) * col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ( col0 ) * cor0.col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL + col2 + col1 * - col1 AS col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT + + col2 - - col0 AS col0 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * 50 col0 FROM tab2 AS cor0
----
350
3900
3950

query I rowsort
SELECT ALL + - cor0.col0 + ( - 1 ) * col2 + + ( + col1 ) FROM tab2 AS cor0
----
-100
-3
-45

query I rowsort
SELECT DISTINCT - col0 + col1 * + tab0.col1 FROM tab0
----
7372
8192
9374

query I rowsort
SELECT DISTINCT 20 + + col1 FROM tab2
----
37
51
79

query I rowsort
SELECT ALL + tab2.col0 * tab2.col0 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 458b4c13e6825f9686b15a38663930f4

query I rowsort
SELECT 56 FROM tab0, tab1 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - cor0.col2 + - 64 col1 FROM tab2 AS cor0
----
-116
-118
-140

query I rowsort
SELECT DISTINCT col0 + 4 AS col0 FROM tab2 AS cor0
----
11
82
83

query I rowsort
SELECT col0 + + ( - 94 ) * + col1 FROM tab1 AS cor0
----
-1142
-2441
-876

query I rowsort
SELECT ALL + - cor0.col1 + col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + cor0.col2 * 32 * - col1 FROM tab0 AS cor0
----
238784
3104
90816

query I rowsort
SELECT col1 * ( - 21 ) FROM tab2 AS cor0
----
-1239
-357
-651

query I rowsort
SELECT DISTINCT cor0.col2 * ( 95 * + cor0.col1 ) FROM tab0 AS cor0
----
269610
708890
9215

query I rowsort
SELECT ALL - cor0.col1 * + col1 AS col1 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-3363
SELECT - CAST( col2 AS SIGNED ) + + cor0.col0 - 81 DIV - cor0.col1 FROM tab1 AS cor0
----
-10
-48
15

skipif mysql # not compatible
query I rowsort label-3363
SELECT - CAST ( col2 AS INTEGER ) + + cor0.col0 - 81 / - cor0.col1 FROM tab1 AS cor0
----
-10
-48
15

query I rowsort
SELECT col2 * col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - ( - col0 ) - + cor0.col0 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3366
SELECT - + CAST( NULL AS DECIMAL ) * col2 + - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3366
SELECT - + CAST ( NULL AS REAL ) * col2 + - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3367
SELECT col0 DIV - col1 + + col2 + - col2 AS col1 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-3367
SELECT col0 / - col1 + + col2 + - col2 AS col1 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT DISTINCT - 87 AS col0 FROM tab1, tab2 AS cor0
----
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col1 ) * col2 col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + 45 * + col1 * 18 AS col0 FROM tab1 cor0
----
10530
21060
8100

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 49 - + col1 * col2 col2 FROM tab0 AS cor0
----
-2789
-48
-7413

onlyif mysql # use DIV operator for integer division
query I rowsort label-3372
SELECT DISTINCT + + col1 DIV + col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3372
SELECT DISTINCT + + col1 / + col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT - + col1 + cor0.col0 * - col1 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT - 87 + col2 * 53 FROM tab0 AS cor0
----
-34
1662
4259

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3375
SELECT DISTINCT - ( + col0 ) + CAST( NULL AS SIGNED ) * + 86 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3375
SELECT DISTINCT - ( + col0 ) + CAST ( NULL AS INTEGER ) * + 86 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * col1 * 23 AS col1 FROM tab1 AS cor0
----
15548
2300
3887

query I rowsort
SELECT - cor0.col0 - - col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - col2 - - col0 * col1 AS col1 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT ALL col0 * - col0 * col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL - col1 + col1 * col0 + + 62 AS col0 FROM tab0 AS cor0
----
2040
3360
8070

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 14 + col1 col1 FROM tab2 AS cor0
----
31
45
73

query I rowsort
SELECT cor0.col2 * - col1 + 10 FROM tab2 AS cor0
----
-1524
-636
-827

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 * + col0 AS col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - col1 + col2 + + col2 AS col1 FROM tab1 AS cor0
----
104
179
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 col2 FROM tab0 cor0
----
64
64
64

query I rowsort
SELECT ALL + - col2 + - col2 * - col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT ALL + col2 + + col0 * + col0 AS col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - - col1 * + col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - - col1 + - 16 + + col2 * col1 AS col1 FROM tab0 cor0
----
178
2908
7537

onlyif mysql # use DIV operator for integer division
query I rowsort label-3390
SELECT ALL + col1 + col1 DIV - 85 AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3390
SELECT ALL + col1 + col1 / - 85 AS col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3391
SELECT DISTINCT + CAST( 28 AS SIGNED ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
28

skipif mysql # not compatible
query I rowsort label-3391
SELECT DISTINCT + CAST ( 28 AS INTEGER ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
28

query I rowsort
SELECT ALL 81 * col2 + - col2 FROM tab0
----
2640
6560
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3393
SELECT ALL ( - 56 ) * col1 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3393
SELECT ALL ( - 56 ) * col1 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT ( + col1 ) * col0 + CAST ( cor0.col0 AS REAL ) * - col2 * + 30 AS col2 FROM tab2 AS cor0
----
-5453
-56238
-88717

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 64 ) + col0 col1 FROM tab2 AS cor0
----
142
143
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-3396
SELECT + col1 DIV cor0.col0 col0 FROM tab1 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3396
SELECT + col1 / cor0.col0 col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT ALL + 74 + col2 FROM tab1 AS cor0
----
128
131
170

skipif mysql # not compatible
query I rowsort
SELECT ALL - - CAST ( - 65 AS REAL ) + cor0.col1 FROM tab2 AS cor0
----
-34
-48
-6

query I rowsort
SELECT ALL 82 FROM tab1, tab0 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT ALL - ( + col2 ) + - cor0.col1 + 39 FROM tab2 cor0
----
-16
-19
-46

query I rowsort
SELECT DISTINCT - ( col2 ) + - col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT tab2.col1 + + cor0.col1 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 1aafc156b714810d5d1cdf5028ce351d

query I rowsort
SELECT - col2 + - 52 * + col0 FROM tab0 AS cor0
----
-1281
-1821
-4710

query I rowsort
SELECT ALL + ( 93 ) - col0 AS col0 FROM tab2
----
14
15
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3406
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + - 60 AS col0 FROM tab0, tab2, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3406
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + - 60 AS col0 FROM tab0, tab2, tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + 98 AS col1 FROM tab1
----
98
98
98

query I rowsort
SELECT DISTINCT col0 + + 38 * tab0.col2 FROM tab0
----
1278
3205
73

query I rowsort
SELECT 56 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT tab1.col0 + - ( col1 ) FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT + cor0.col1 * 6 FROM tab1 AS cor0
----
156
60
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + 40 + - col0 col2 FROM tab1 AS cor0
----
2157
2216
3760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3413
SELECT - + col1 DIV 29 + col1 col0 FROM tab2 AS cor0
----
17
30
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3413
SELECT - + col1 / 29 + col1 col0 FROM tab2 AS cor0
----
17
30
57

query I rowsort
SELECT DISTINCT cor0.col1 + + 28 AS col0 FROM tab0 AS cor0
----
114
119
125

query I rowsort
SELECT - col0 + - 89 FROM tab1 AS cor0
----
-153
-169
-92

query I rowsort
SELECT ALL col1 + + 23 FROM tab0
----
109
114
120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + 96 * col1 col2 FROM tab2 AS cor0
----
1553
2969
5586

onlyif mysql # use DIV operator for integer division
query I rowsort label-3418
SELECT ALL + ( + 13 ) DIV col2 + col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3418
SELECT ALL + ( + 13 ) / col2 + col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + + col1 * + col0 - col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ( + col2 ) * + col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - cor1.col2 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT + col2 * - ( col0 ) + + col2 * cor0.col1 FROM tab2 cor0
----
-2356
-494
648

query I rowsort
SELECT - 6 * + col2 * - cor0.col1 + - col1 FROM tab1 AS cor0
----
3410
7475
8398

onlyif mysql # use DIV operator for integer division
query I rowsort label-3424
SELECT ( 56 ) DIV + col1 - + col1 * 58 FROM tab1 AS cor0
----
-1506
-575
-750

skipif mysql # not compatible
query I rowsort label-3424
SELECT ( 56 ) / + col1 - + col1 * 58 FROM tab1 AS cor0
----
-1506
-575
-750

query I rowsort
SELECT - - 92 * - col1 * - 85 FROM tab1 AS cor0
----
101660
203320
78200

query I rowsort
SELECT - - col0 * + col0 AS col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT ALL col2 * col2 * 81 FROM tab1
----
236196
263169
746496

query I rowsort
SELECT DISTINCT + - cor0.col2 * + col2 + col2 * - cor0.col2 * cor0.col1 FROM tab0 cor0
----
-618608
-94743
-98

query I rowsort
SELECT + - 82 + col2 AS col1 FROM tab2 AS cor0
----
-44
-55
-56

query I rowsort
SELECT DISTINCT - - col1 + + cor0.col1 * ( cor0.col2 ) FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL 1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - col0 * - 41 + - col1 * col0 AS col1 FROM tab2 AS cor0
----
-1404
1896
70

query I rowsort
SELECT DISTINCT + col0 * - ( ( + col2 ) ) * 19 + - cor0.col1 - col2 FROM tab0 AS cor0
----
-138835
-15167
-763

query I rowsort
SELECT + - col0 + - cor0.col1 * - col1 AS col0 FROM tab1 AS cor0
----
36
673
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + 77 col1 FROM tab1 cor0
----
231
4928
6160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 20 col1 FROM tab1 AS cor0
----
-200
-260
-520

query I rowsort
SELECT - - col0 + col2 * 87 * - col1 AS col0 FROM tab1 cor0
----
-108496
-122145
-49526

query I rowsort
SELECT 91 * col2 + col0 FROM tab2
----
2444
2464
3537

onlyif mysql # use DIV operator for integer division
query I rowsort label-3439
SELECT ALL 22 DIV - col0 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3439
SELECT ALL 22 / - col0 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT 30 + - col2 * 85 AS col1 FROM tab2
----
-2180
-2265
-3200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3441
SELECT - col2 + + CAST( NULL AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3441
SELECT - col2 + + CAST ( NULL AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * - 47 + 86 AS col1 FROM tab0 AS cor0
----
-1042
-1559
-4097

query I rowsort
SELECT col1 + 99 * 88 FROM tab2 AS cor0
----
8729
8743
8771

query I rowsort
SELECT + 99 * + col0 + cor0.col2 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
15535
3465
3466

query I rowsort
SELECT ALL - col0 + - 46 + + col0 FROM tab1
----
-46
-46
-46

query I rowsort
SELECT + - ( 24 ) * - col0 FROM tab2 AS cor0
----
168
1872
1896

query I rowsort
SELECT + col2 * + cor0.col0 - + cor0.col0 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-3448
SELECT ALL tab1.col0 DIV - col1 col2 FROM tab1
----
-6
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3448
SELECT ALL tab1.col0 / - col1 col2 FROM tab1
----
-6
-6
0

query I rowsort
SELECT 99 * - 42 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 74766ebeccd3f43e8baa7949942b3e39

query I rowsort
SELECT + - 18 * + col0 FROM tab0 AS cor0
----
-1602
-432
-630

query I rowsort
SELECT - + 99 AS col0 FROM tab2 cor0
----
-99
-99
-99

query I rowsort
SELECT + cor0.col1 * + col1 + - ( - col0 + col0 ) AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + cor0.col0 * col0 + 31 AS col1 FROM tab0 cor0
----
1256
607
7952

query I rowsort
SELECT col0 * - col2 + - ( + col2 + + col2 ) AS col1 FROM tab1 AS cor0
----
-270
-3762
-7872

query I rowsort
SELECT ALL ( col0 ) * - tab1.col1 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - ( ( + col2 ) ) * ( 32 ) AS col0 FROM tab2
----
-1216
-832
-864

query I rowsort
SELECT DISTINCT 82 * col0 AS col2 FROM tab0
----
1968
2870
7298

query I rowsort
SELECT DISTINCT + 74 AS col1 FROM tab1
----
74

query I rowsort
SELECT ALL + cor0.col0 + cor0.col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + 75 + + col0 * 42 FROM tab1 AS cor0
----
201
2763
3435

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3461
SELECT ALL + col1 * col1 + ( + 84 + col1 ) * CAST( cor0.col2 + - col1 AS SIGNED ) FROM tab2 AS cor0
----
-1238
2410
501

skipif mysql # not compatible
query I rowsort label-3461
SELECT ALL + col1 * col1 + ( + 84 + col1 ) * CAST ( cor0.col2 + - col1 AS INTEGER ) FROM tab2 AS cor0
----
-1238
2410
501

query I rowsort
SELECT DISTINCT 61 - - col2 * + col1 FROM tab0 AS cor0
----
158
2899
7523

query I rowsort
SELECT - 47 + col0 AS col2 FROM tab0 AS cor0
----
-12
-23
42

query I rowsort
SELECT DISTINCT + + col0 * col2 + 73 * ( col0 ) * - 12 AS col1 FROM tab2 AS cor0
----
-5943
-66202
-66300

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3465
SELECT CAST( NULL AS DECIMAL ) + col0 + - col2 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3465
SELECT CAST ( NULL AS REAL ) + col0 + - col2 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 82 AS col1 FROM tab1 AS cor0
----
-82

query I rowsort
SELECT DISTINCT + - 84 * + ( col2 + - col0 ) FROM tab2 AS cor0
----
-1680
3444
4368

query I rowsort
SELECT DISTINCT - + ( + ( + col2 ) ) + col2 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + + col0 * cor0.col0 - col2 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT - - 62 + - cor0.col0 FROM tab2 AS cor0
----
-16
-17
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col0 FROM tab0, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + ( - col1 ) + col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - cor1.col2 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3474
SELECT ALL CAST( NULL AS SIGNED ) * cor0.col2 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3474
SELECT ALL CAST ( NULL AS INTEGER ) * cor0.col2 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + - col1 * + col2 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3476
SELECT ALL - CAST( NULL AS SIGNED ) * + col1 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3476
SELECT ALL - CAST ( NULL AS INTEGER ) * + col1 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * col0 * col0 FROM tab2
----
343
474552
493039

query I rowsort
SELECT - col1 * col0 + - col1 AS col1 FROM tab1
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) + - col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT 46 * col1 AS col2 FROM tab1 AS cor0
----
1196
460
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-3481
SELECT + 72 + col1 DIV - cor0.col0 FROM tab2 AS cor0
----
68
72
72

skipif mysql # not compatible
query I rowsort label-3481
SELECT + 72 + col1 / - cor0.col0 FROM tab2 AS cor0
----
68
72
72

query I rowsort
SELECT DISTINCT + - col2 * cor0.col0 + - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT + 30 AS col0 FROM tab2 cor0
----
30
30
30

query I rowsort
SELECT DISTINCT - 56 AS col1 FROM tab1 AS cor0
----
-56

query I rowsort
SELECT 67 + - 53 + col2 AS col0 FROM tab1
----
110
68
71

query I rowsort
SELECT ( + col1 ) * - col2 * - col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT - 93 * col2 + tab0.col1 * col0 + - col0 FROM tab0
----
-1029
3267
384

query I rowsort
SELECT DISTINCT 57 + - col1 FROM tab0
----
-29
-34
-40

onlyif mysql # use DIV operator for integer division
query I rowsort label-3489
SELECT DISTINCT + col1 + - col2 DIV col1 AS col0 FROM tab1
----
24
5
6

skipif mysql # not compatible
query I rowsort label-3489
SELECT DISTINCT + col1 + - col2 / col1 AS col0 FROM tab1
----
24
5
6

query I rowsort
SELECT ALL col2 * - col1 + - col0 + - col1 AS col1 FROM tab1
----
-1341
-1433
-644

query I rowsort
SELECT DISTINCT 16 + col1 FROM tab2
----
33
47
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-3492
SELECT ALL col1 DIV - col0 AS col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-3492
SELECT ALL col1 / - col0 AS col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT ALL + - col0 * col0 + 30 * - col2 AS col1 FROM tab0 AS cor0
----
-10381
-1255
-1566

query I rowsort
SELECT ALL + + col1 * 9 * col0 FROM tab2 AS cor0
----
12087
1953
41418

skipif mysql # not compatible
query I rowsort
SELECT ALL col2 * CAST ( - ( - col1 ) * - col0 AS REAL ) FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3496
SELECT ALL cor0.col2 * col0 * ( col0 ) + - col2 DIV - col0 FROM tab1 AS cor0
----
233472
504
614401

skipif mysql # not compatible
query I rowsort label-3496
SELECT ALL cor0.col2 * col0 * ( col0 ) + - col2 / - col0 FROM tab1 AS cor0
----
233472
504
614401

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3497
SELECT 40 - - col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3497
SELECT 40 - - col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 94 FROM tab1
----
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3499
SELECT - col2 + ( - col1 ) DIV col0 FROM tab2
----
-26
-31
-38

skipif mysql # not compatible
query I rowsort label-3499
SELECT - col2 + ( - col1 ) / col0 FROM tab2
----
-26
-31
-38

query I rowsort
SELECT DISTINCT + col0 * col2 * col0 - col0 * + col0 * col0 FROM tab2
----
-255881
-316368
980

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3501
SELECT + - col2 * - CAST( NULL AS SIGNED ) + col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3501
SELECT + - col2 * - CAST ( NULL AS INTEGER ) + col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3502
SELECT DISTINCT + col0 DIV col1 - + col2 AS col0 FROM tab1
----
-51
-54
-90

skipif mysql # not compatible
query I rowsort label-3502
SELECT DISTINCT + col0 / col1 - + col2 AS col0 FROM tab1
----
-51
-54
-90

query I rowsort
SELECT ALL col1 - - tab2.col0 AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT - + col1 + ( + 97 ) FROM tab1 AS cor0
----
71
84
87

query I rowsort
SELECT ALL tab2.col0 * col1 * + col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT ALL - - col2 * col2 + + col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT - + cor0.col1 * col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL col2 * - col2 + - col2 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT - + col1 * cor0.col1 - col0 AS col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT ALL - col2 * col2 + + col2 + + col0 AS col0 FROM tab2 AS cor0
----
-1327
-572
-695

query I rowsort
SELECT col1 + col0 AS col1 FROM tab1 WHERE NULL NOT IN ( col1 )
----

query I rowsort
SELECT ALL col2 + + col1 * - col2 * col0 AS col0 FROM tab0
----
-3394
-664036
-68079

query I rowsort
SELECT + col1 * - cor0.col1 + + col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT - col1 * - cor0.col2 + + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + col0 * + col0 + col0 AS col0 FROM tab2 cor0
----
56
6162
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - col1 - - col0 * - col2 col2 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT DISTINCT + - col1 + col2 AS col2 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-3518
SELECT ALL col0 * + col0 - - col2 DIV col1 AS col1 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-3518
SELECT ALL col0 * + col0 - - col2 / col1 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - + col2 + col1 AS col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + col1 * - col1 + + col0 + col1 * col2 * - col0 FROM tab1 AS cor0
----
-36516
-4885
-99929

query I rowsort
SELECT ALL - 14 * col1 FROM tab1
----
-140
-182
-364

query I rowsort
SELECT cor0.col1 * col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - 37 AS col1 FROM tab2
----
-37

query I rowsort
SELECT ALL col0 + col0 * + col2 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT - col2 * - col1 + + col0 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT - col0 + cor0.col0 * - col0 + - col0 AS col2 FROM tab2 AS cor0
----
-6240
-63
-6399

query I rowsort
SELECT DISTINCT - col0 * col2 + - col0 * col2 AS col1 FROM tab1 AS cor0
----
-15360
-324
-7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-3528
SELECT ALL - - ( col0 ) + - cor0.col0 DIV col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-3528
SELECT ALL - - ( col0 ) + - cor0.col0 / col0 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT + + col0 * + col1 + col2 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT - - 63 * col2 FROM tab1 AS cor0
----
3402
3591
6048

query I rowsort
SELECT + col2 * + col2 AS col1 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - col2 + col0 * col0 * - col1 AS col2 FROM tab2 AS cor0
----
-106135
-1546
-358982

query I rowsort
SELECT ALL - col0 + col2 * + col0 * + col1 AS col1 FROM tab2 AS cor0
----
119574
50955
5852

query I rowsort
SELECT - col1 * col0 * col1 AS col2 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - - col0 * col1 + col2 * - col2 AS col1 FROM tab2 AS cor0
----
-101
-512
3926

query I rowsort
SELECT DISTINCT ( + col1 + - col0 ) * col1 AS col2 FROM tab1
----
-540
-871
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-3537
SELECT - + col0 DIV - col0 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3537
SELECT - + col0 / - col0 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col2 * + col2 + col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT DISTINCT - ( + col2 ) * cor0.col0 + + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-3540
SELECT DISTINCT + col0 DIV col1 + + col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3540
SELECT DISTINCT + col0 / col1 + + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ( 4 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT DISTINCT - 31 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
-31

query I rowsort
SELECT - ( col1 ) * col0 AS col2 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3544
SELECT - col1 * CAST( 16 * - col2 AS SIGNED ) FROM tab2
----
10336
13392
24544

skipif mysql # not compatible
query I rowsort label-3544
SELECT - col1 * CAST ( 16 * - col2 AS INTEGER ) FROM tab2
----
10336
13392
24544

query I rowsort
SELECT 44 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT ALL + ( + col2 ) + - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT - 5 FROM tab2
----
-5

query I rowsort
SELECT ALL + ( + col1 + tab0.col2 ) FROM tab0
----
119
173
98

query I rowsort
SELECT ALL - cor0.col0 + 62 * col1 FROM tab1 AS cor0
----
1609
556
726

query I rowsort
SELECT + + col2 + 40 FROM tab0 AS cor0
----
122
41
73

query I rowsort
SELECT DISTINCT + 57 - col2 FROM tab0 AS cor0
----
-25
24
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3552
SELECT + + CAST( col1 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-3552
SELECT + + CAST ( col1 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + col1 * + 92 + + col0 + + col0 FROM tab1 AS cor0
----
1048
1356
2398

query I rowsort
SELECT + + 62 + - cor0.col2 + col2 AS col0 FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT ALL col1 * cor0.col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT col2 + + col2 * + col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT - + col1 * + 43 FROM tab2 AS cor0
----
-1333
-2537
-731

query I rowsort
SELECT + col0 * - 6 + - col2 FROM tab2 AS cor0
----
-494
-512
-69

query I rowsort
SELECT + + col0 - col1 AS col0 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT - col1 * cor0.col2 - cor0.col0 AS col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT - - 59 + col0 + col2 AS col1 FROM tab2 AS cor0
----
163
176
93

query I rowsort
SELECT - + 81 + col0 * - col2 FROM tab0 AS cor0
----
-116
-7379
-873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * 79 col1 FROM tab2 AS cor0
----
2054
2133
3002

query I rowsort
SELECT col0 + col0 + + col0 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT DISTINCT - ( 21 ) FROM tab2 AS cor0
----
-21

onlyif mysql # use DIV operator for integer division
query I rowsort label-3566
SELECT - col2 + - 87 DIV col0 FROM tab2 cor0
----
-27
-39
-39

skipif mysql # not compatible
query I rowsort label-3566
SELECT - col2 + - 87 / col0 FROM tab2 cor0
----
-27
-39
-39

query I rowsort
SELECT col0 * + ( 17 ) AS col0 FROM tab2
----
119
1326
1343

onlyif mysql # use DIV operator for integer division
query I rowsort label-3568
SELECT 27 DIV 4 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

skipif mysql # not compatible
query I rowsort label-3568
SELECT 27 / 4 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

onlyif mysql # use DIV operator for integer division
query I rowsort label-3569
SELECT DISTINCT + col0 DIV 71 AS col2 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-3569
SELECT DISTINCT + col0 / 71 AS col2 FROM tab0
----
0
1

query I rowsort
SELECT - col0 * 17 + col0 AS col2 FROM tab0 AS cor0
----
-1424
-384
-560

query I rowsort
SELECT - col1 + + 15 FROM tab1 AS cor0
----
-11
2
5

query I rowsort
SELECT ALL - col1 * + 1 - + 47 FROM tab1
----
-57
-60
-73

query I rowsort
SELECT ALL - col0 * - 34 - 85 FROM tab1
----
17
2091
2635

query I rowsort
SELECT DISTINCT - tab1.col2 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT ALL col0 - - 26 FROM tab2
----
104
105
33

skipif mysql # not compatible
query I rowsort
SELECT ALL col2 / - ( col1 ) + tab0.col0 - + CAST ( col0 AS REAL ) * + col2 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT + + col0 + 12 AS col0 FROM tab1 AS cor0
----
15
76
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3578
SELECT DISTINCT - - col2 + + CAST( NULL AS SIGNED ) / + ( col0 ) + - col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3578
SELECT DISTINCT - - col2 + + CAST ( NULL AS INTEGER ) / + ( col0 ) + - col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL + col1 * cor0.col1 + - cor0.col0 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT - ( + col2 ) * - cor0.col2 + - col1 FROM tab2 cor0
----
1427
617
698

query I rowsort
SELECT ALL 54 * 90 FROM tab1 AS cor0
----
4860
4860
4860

query I rowsort
SELECT DISTINCT - 41 AS col0 FROM tab1 cor0
----
-41

query I rowsort
SELECT DISTINCT + + ( + 5 ) AS col0 FROM tab2 AS cor0
----
5

query I rowsort
SELECT ALL + - cor0.col2 * - 2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT - 17 * 10 FROM tab0 cor0
----
-170

query I rowsort
SELECT - cor0.col1 * + col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3587
SELECT + CAST( NULL AS SIGNED ) + col0 * - col0 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3587
SELECT + CAST ( NULL AS INTEGER ) + col0 * - col0 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3588
SELECT ALL 48 DIV - 62 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3588
SELECT ALL 48 / - 62 AS col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3589
SELECT DISTINCT - CAST( + col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3589
SELECT DISTINCT - CAST ( + col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3590
SELECT + col0 DIV + 88 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3590
SELECT + col0 / + 88 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + + 31 AS col2 FROM tab2 cor0
----
48
62
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3592
SELECT + cor0.col0 DIV col2 + col0 FROM tab1 AS cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-3592
SELECT + cor0.col0 / col2 + col0 FROM tab1 AS cor0
----
3
65
80

query I rowsort
SELECT ALL - - 99 AS col1 FROM tab2 AS cor0
----
99
99
99

query I rowsort
SELECT DISTINCT + col2 - 94 AS col0 FROM tab2 AS cor0
----
-56
-67
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-3595
SELECT + 31 DIV + col2 - + col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3595
SELECT + 31 / + col2 - + col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT tab1.col1 * + 16 FROM tab1
----
160
208
416

query I rowsort
SELECT ALL col2 * col2 - ( + tab2.col0 ) * - ( 53 ) FROM tab2
----
1100
4810
5631

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3598
SELECT ALL - col0 - - CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3598
SELECT ALL - col0 - - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 * - 3 FROM tab1 AS cor0
----
-162
-171
-288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 82 col2 FROM tab0, tab2 cor0, tab0 AS cor1
----
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3601
SELECT col1 DIV + 99 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3601
SELECT col1 / + 99 AS col0 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3602
SELECT cor0.col2 DIV col0 col1 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3602
SELECT cor0.col2 / col0 col1 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3603
SELECT ALL + col2 * col1 + + cor0.col2 * + col2 DIV col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

skipif mysql # not compatible
query I rowsort label-3603
SELECT ALL + col2 * col1 + + cor0.col2 * + col2 / col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + 66 * col1 AS col1 FROM tab1 AS cor0
----
1716
660
858

query I rowsort
SELECT ALL + + col2 + col1 + 56 * - col2 * - col0 FROM tab0 AS cor0
----
2058
408861
44471

query I rowsort
SELECT - 85 * cor0.col1 FROM tab0 AS cor0
----
-7310
-7735
-8245

query I rowsort
SELECT DISTINCT cor0.col1 * + col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + + 27 * - col0 AS col0 FROM tab0 AS cor0
----
-2403
-648
-945

query I rowsort
SELECT DISTINCT + 3 * + col1 + col2 * - col2 FROM tab1 AS cor0
----
-2838
-3219
-9177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3610
SELECT - tab0.col2 + + CAST( NULL AS SIGNED ) FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3610
SELECT - tab0.col2 + + CAST ( NULL AS INTEGER ) FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + col0 * col0 + 85 FROM tab2 cor0
----
134
6169
6326

query I rowsort
SELECT ALL col1 * 1 + col0 + - col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + ( + col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3614
SELECT DISTINCT - + col1 + - CAST( NULL AS SIGNED ) + col1 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3614
SELECT DISTINCT - + col1 + - CAST ( NULL AS INTEGER ) + col1 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col0 + 31 AS col0 FROM tab1 AS cor0
----
111
34
95

query I rowsort
SELECT ALL + col2 * - col2 - + col1 FROM tab1 AS cor0
----
-2942
-3259
-9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * + ( col1 ) col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3618
SELECT ALL + - col2 + - CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-55
-58
-85

skipif mysql # not compatible
query I rowsort label-3618
SELECT ALL + - col2 + - CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 + - cor0.col2 * + col2 FROM tab2 AS cor0
----
-2704
-4446
-918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3620
SELECT DISTINCT cor0.col0 + - CAST( NULL AS DECIMAL ) / - col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3620
SELECT DISTINCT cor0.col0 + - CAST ( NULL AS REAL ) / - col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - col2 * + 53 FROM tab0 AS cor0
----
-1749
-4346
-53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 96 col0 FROM tab1
----
-96

query I rowsort
SELECT 24 + col2 AS col2 FROM tab0
----
106
25
57

query I rowsort
SELECT DISTINCT + tab2.col0 * 14 FROM tab2, tab1, tab1 AS cor0, tab0
----
1092
1106
98

query I rowsort
SELECT col0 * + col1 + 19 * 31 AS col2 FROM tab0
----
2653
3984
8688

query I rowsort
SELECT col2 + - col1 * ( ( col0 ) ) * col2 AS col2 FROM tab0
----
-3394
-664036
-68079

query I rowsort
SELECT ALL 50 AS col0 FROM tab0, tab0 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 6932c991110d256d3f92f3e9538f8040

onlyif mysql # use DIV operator for integer division
query I rowsort label-3628
SELECT DISTINCT col0 * col0 DIV col1 AS col2 FROM tab1
----
0
409
492

skipif mysql # not compatible
query I rowsort label-3628
SELECT DISTINCT col0 * col0 / col1 AS col2 FROM tab1
----
0
409
492

query I rowsort
SELECT ALL - cor0.col2 * + col1 + 1 FROM tab0 AS cor0
----
-2837
-7461
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 - + col0 * col1 col0 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT col1 * - col0 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT + col0 * + col1 + ( col0 ) * - col2 * col2 - cor0.col2 FROM tab0 cor0
----
-24105
-590419
3359

query I rowsort
SELECT + + col2 * + 80 FROM tab0 AS cor0
----
2640
6560
80

query I rowsort
SELECT ALL - col1 + ( cor0.col2 ) * col0 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3635
SELECT + CAST( NULL AS SIGNED ) + - col1 * col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3635
SELECT + CAST ( NULL AS INTEGER ) + - col1 * col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 1 col0 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3637
SELECT + + 34 DIV ( col1 * + 38 ) + ( col1 + col2 * - col1 ) AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif mysql # not compatible
query I rowsort label-3637
SELECT + + 34 / ( col1 * + 38 ) + ( col1 + col2 * - col1 ) AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3638
SELECT col2 * + ( + col2 ) - - CAST( 47 AS SIGNED ) FROM tab1 AS cor0
----
2963
3296
9263

skipif mysql # not compatible
query I rowsort label-3638
SELECT col2 * + ( + col2 ) - - CAST ( 47 AS INTEGER ) FROM tab1 AS cor0
----
2963
3296
9263

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3639
SELECT CAST( NULL AS SIGNED ) * cor0.col0 + + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3639
SELECT CAST ( NULL AS INTEGER ) * cor0.col0 + + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 + col0 * - ( - 92 ) FROM tab0 AS cor0
----
2184
3185
8099

query I rowsort
SELECT ALL + + 57 FROM tab1 cor0
----
57
57
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3642
SELECT - col2 * + col0 + CAST( 53 AS SIGNED ) col0 FROM tab2 AS cor0
----
-136
-1975
-2949

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3642
SELECT - col2 * + col0 + CAST ( 53 AS INTEGER ) col0 FROM tab2 AS cor0
----
-136
-1975
-2949

query I rowsort
SELECT ALL 24 * tab2.col0 FROM tab2
----
168
1872
1896

query I rowsort
SELECT + - 68 AS col0 FROM tab2 AS cor0
----
-68
-68
-68

query I rowsort
SELECT DISTINCT cor0.col2 * col2 * col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - - 35 + col1 FROM tab1 AS cor0
----
45
48
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 + col1 * + col2 col1 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT tab0.col2 * col0 AS col0 FROM tab0 WHERE ( + col2 * - col2 * tab0.col2 + col2 ) >= NULL
----

query I rowsort
SELECT ALL + col2 - + col0 AS col2 FROM tab0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3650
SELECT - tab2.col0 + - col2 DIV col0 FROM tab2
----
-10
-78
-79

skipif mysql # not compatible
query I rowsort label-3650
SELECT - tab2.col0 + - col2 / col0 FROM tab2
----
-10
-78
-79

query I rowsort
SELECT ALL + tab2.col2 * col2 * + tab2.col1 FROM tab2
----
22599
24548
39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col1 col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT tab1.col2 * - tab1.col2 AS col1 FROM tab1 WHERE + col0 + col1 >= NULL
----

query I rowsort
SELECT DISTINCT - tab1.col1 * tab1.col1 AS col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT ALL col0 + - col1 * + col1 * col0 FROM tab1
----
-13440
-2025
-6336

query I rowsort
SELECT DISTINCT col2 * - col2 AS col1 FROM tab0 WHERE NOT ( - tab0.col0 ) >= - col1 * - col2 * - col0
----

query I rowsort
SELECT col0 FROM tab2 WHERE NOT ( NULL ) NOT BETWEEN + col1 AND ( - col0 )
----

query I rowsort
SELECT - col0 + - col2 * - col0 AS col0 FROM tab2
----
182
1950
2923

query I rowsort
SELECT - col2 AS col0 FROM tab2 WHERE ( col1 * col0 * - col2 ) IN ( col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( - col1 ) = col1 * - col2
----

query I rowsort
SELECT DISTINCT col2 * col2 AS col2 FROM tab0 AS cor0 WHERE NOT ( col2 * col1 ) = NULL
----

query I rowsort
SELECT cor0.col2 + cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to b24047a4766c1dbbfa5abb9df45d1883

query I rowsort
SELECT col0 * col1 + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL col1 * col2 + + col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 + cor0.col1 - + col2 col1 FROM tab0 AS cor0
----
193
2891
7471

query I rowsort
SELECT ALL - cor0.col1 FROM tab2 AS cor0 WHERE NOT col0 + - col2 = ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3667
SELECT DISTINCT col0 * col2 DIV col1 FROM tab0 AS cor0
----
0
80
9

skipif mysql # not compatible
query I rowsort label-3667
SELECT DISTINCT col0 * col2 / col1 FROM tab0 AS cor0
----
0
80
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3668
SELECT ALL + col1 + col0 DIV col1 col0 FROM tab0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3668
SELECT ALL + col1 + col0 / col1 col0 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT col1 + - col1 * - col2 * col1 FROM tab2
----
10999
25978
90565

query I rowsort
SELECT DISTINCT - col1 + - tab2.col0 AS col1 FROM tab2
----
-137
-38
-96

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) IN ( + col2 )
----

query I rowsort
SELECT DISTINCT col0 * + cor0.col0 + col0 FROM tab0 cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT + col1 + - col0 * col2 / col1 AS col1 FROM tab2 WHERE NOT - col2 < + col0
----

query I rowsort
SELECT - col2 - col2 AS col0 FROM tab0
----
-164
-2
-66

query I rowsort
SELECT - 65 FROM tab0, tab0 cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 62fe7b8eb6ce8c547418f08ea8ada1fc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3676
SELECT + CAST( col0 AS SIGNED ) * cor0.col2 col0 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3676
SELECT + CAST ( col0 AS INTEGER ) * cor0.col2 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT cor1.col2 AS col1 FROM tab1, tab1 AS cor0, tab2 cor1
----
26
27
38

query I rowsort
SELECT DISTINCT + ( tab2.col2 ) + col2 FROM tab2
----
52
54
76

query I rowsort
SELECT DISTINCT + cor1.col2 AS col0 FROM tab0, tab2 cor0, tab1 AS cor1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3680
SELECT + ( col2 ) * col2 * 30 + cor0.col2 DIV cor0.col1 AS col2 FROM tab2 AS cor0
----
20280
21870
43322

skipif mysql # not compatible
query I rowsort label-3680
SELECT + ( col2 ) * col2 * 30 + cor0.col2 / cor0.col1 AS col2 FROM tab2 AS cor0
----
20280
21870
43322

query I rowsort
SELECT + col0 * - col1 + cor0.col0 * - 86 FROM tab2 AS cor0
----
-11310
-8137
-819

query I rowsort
SELECT - ( col0 + - 10 ) FROM tab1
----
-54
-70
7

query I rowsort
SELECT DISTINCT + tab0.col0 * col1 + - tab0.col1 + col2 AS col0 FROM tab0
----
2011
3299
8090

onlyif mysql # use DIV operator for integer division
query I rowsort label-3684
SELECT - 53 DIV + col0 col2 FROM tab1
----
-17
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3684
SELECT - 53 / + col0 col2 FROM tab1
----
-17
0
0

query I rowsort
SELECT + cor1.col0 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT + ( col0 ) + + 14 * 95 AS col2 FROM tab1 cor0
----
1333
1394
1410

query I rowsort
SELECT ALL col2 * + col0 * - col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + 21 col1 FROM tab2 cor0
----
-57
-58
14

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3689
SELECT + cor0.col1 + CAST( col2 + col2 AS SIGNED ) FROM tab0 AS cor0
----
152
255
99

skipif mysql # not compatible
query I rowsort label-3689
SELECT + cor0.col1 + CAST ( col2 + col2 AS INTEGER ) FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT DISTINCT col0 + - col2 + + col2 * + tab1.col0 AS col2 FROM tab1
----
111
3655
7664

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3691
SELECT - cor0.col0 - + CAST( ( col2 ) AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-171
-36
-57

skipif mysql # not compatible
query I rowsort label-3691
SELECT - cor0.col0 - + CAST ( ( col2 ) AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT col2 + + 82 AS col2 FROM tab1 AS cor0
----
136
139
178

query I rowsort
SELECT + col2 * col0 + + 39 - col1 AS col0 FROM tab2 AS cor0
----
197
2008
3024

query I rowsort
SELECT DISTINCT col0 + + col1 * - cor0.col1 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT DISTINCT col1 * - col0 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT + tab1.col1 + tab1.col0 AS col2 FROM tab1
----
29
74
93

query I rowsort
SELECT - ( - 40 ) + + cor0.col1 FROM tab2 AS cor0
----
57
71
99

query I rowsort
SELECT ALL ( + col2 ) + + col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL - col1 * + cor0.col1 + + col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT DISTINCT + + col2 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT ( col2 ) + col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + cor0.col0 * col2 + + col2 * - col2 AS col2 FROM tab1 AS cor0
----
-1536
-2754
399

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 + 13 * - col1 + + col2 col0 FROM tab0
----
-1010
-1163
-999

query I rowsort
SELECT DISTINCT - 86 AS col0 FROM tab0, tab2 AS cor0
----
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-3705
SELECT - col2 DIV 93 + 21 AS col1 FROM tab2
----
21
21
21

skipif mysql # not compatible
query I rowsort label-3705
SELECT - col2 / 93 + 21 AS col1 FROM tab2
----
21
21
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3706
SELECT + col1 + CAST( NULL AS SIGNED ) - + col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3706
SELECT + col1 + CAST ( NULL AS INTEGER ) - + col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3707
SELECT ALL col1 + 52 * col0 DIV - col1 + 7 FROM tab0
----
48
79
86

skipif mysql # not compatible
query I rowsort label-3707
SELECT ALL col1 + 52 * col0 / - col1 + 7 FROM tab0
----
48
79
86

query I rowsort
SELECT cor0.col2 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + col1 col0 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3710
SELECT - col2 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3710
SELECT - col2 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 7 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT - col1 * + col0 + - col2 * col0 FROM tab2 AS cor0
----
-406
-4345
-6630

query I rowsort
SELECT + - col2 * cor0.col1 + + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + - col0 + - ( + col2 ) + + ( ( col1 ) ) FROM tab2 AS cor0
----
-100
-3
-45

query I rowsort
SELECT + ( - ( cor0.col0 ) ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col1 * col0 * col1 + 41 AS col1 FROM tab0 AS cor0
----
177545
329356
737050

query I rowsort
SELECT DISTINCT - - cor0.col2 - - ( col2 ) AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT col2 + 15 AS col2 FROM tab2 AS cor0
----
41
42
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3719
SELECT - - CAST( col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3719
SELECT - - CAST ( col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ( + cor0.col0 ) * - col1 * + col2 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + ( + col2 ) * + col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + 30 + ( cor0.col1 ) * col2 FROM tab0 AS cor0
----
127
2868
7492

query I rowsort
SELECT DISTINCT + - 52 AS col0 FROM tab2 cor0
----
-52

query I rowsort
SELECT DISTINCT + 49 * col1 FROM tab1 cor0
----
1274
490
637

query I rowsort
SELECT + 0 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - - col2 - 99 * + col1 FROM tab0 cor0
----
-8481
-8927
-9602

query I rowsort
SELECT DISTINCT - - col0 + col2 * col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + - 32 + col2 * col1 + 18 AS col0 FROM tab0 AS cor0
----
2824
7448
83

query I rowsort
SELECT ALL + col2 * + col0 + - col1 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT col0 * ( + col1 ) + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT 79 * 15 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to c2a76c0102a55efcdeefaecff0a2dc97

query I rowsort
SELECT ALL - + 50 * + col0 * col0 FROM tab0 AS cor0
----
-28800
-396050
-61250

onlyif mysql # use DIV operator for integer division
query I rowsort label-3733
SELECT DISTINCT + col2 DIV + 49 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-3733
SELECT DISTINCT + col2 / + 49 FROM tab1 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3734
SELECT + + CAST( NULL AS SIGNED ) + 8 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-3734
SELECT + + CAST ( NULL AS INTEGER ) + 8 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 95 FROM tab1, tab2 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT ALL + + col2 + + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
24
35
89

query I rowsort
SELECT ( + col2 ) + + col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - col1 + 59 AS col0 FROM tab1 AS cor0
----
33
46
49

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col0 * - col0 AS REAL ) AS col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT col0 + 27 FROM tab2
----
105
106
34

query I rowsort
SELECT col1 * + col2 + - col1 AS col0 FROM tab2
----
1475
629
806

query I rowsort
SELECT DISTINCT tab1.col2 * + 62 FROM tab1
----
3348
3534
5952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3744
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab1, tab0, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3744
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab1, tab0, tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 30 * col2 FROM tab1
----
1620
1710
2880

query I rowsort
SELECT 6 * - 44 FROM tab1
----
-264
-264
-264

query I rowsort
SELECT - col2 + + 43 AS col2 FROM tab1 AS cor0
----
-11
-14
-53

query I rowsort
SELECT DISTINCT + - col0 + - col0 FROM tab2 cor0
----
-14
-156
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3749
SELECT - col1 * + col0 - col2 DIV + col1 col2 FROM tab1 cor0
----
-1047
-645
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3749
SELECT - col1 * + col0 - col2 / + col1 col2 FROM tab1 cor0
----
-1047
-645
-80

query I rowsort
SELECT DISTINCT + + cor0.col0 + - col2 FROM tab2 cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3751
SELECT + col0 * - col1 + + col0 DIV - col1 + - 57 FROM tab1 AS cor0
----
-1103
-135
-703

skipif mysql # not compatible
query I rowsort label-3751
SELECT + col0 * - col1 + + col0 / - col1 + - 57 FROM tab1 AS cor0
----
-1103
-135
-703

query I rowsort
SELECT + + col0 * - 87 - col0 * cor0.col2 FROM tab1 AS cor0
----
-14640
-423
-9216

query I rowsort
SELECT DISTINCT - col2 + ( + col2 ) + - col2 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3754
SELECT DISTINCT col0 DIV cor0.col0 + - col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-3754
SELECT DISTINCT col0 / cor0.col0 + - col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT ALL col0 * 14 - col0 AS col1 FROM tab2 AS cor0
----
1014
1027
91

query I rowsort
SELECT DISTINCT - tab0.col2 - - col0 * + 95 AS col1 FROM tab0
----
2247
3324
8373

query I rowsort
SELECT ALL - col0 * 63 FROM tab2 AS cor0
----
-441
-4914
-4977

query I rowsort
SELECT - + col0 * - col2 - - col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT + 96 * - col0 - col0 AS col1 FROM tab1
----
-291
-6208
-7760

query I rowsort
SELECT DISTINCT + col0 - - tab0.col2 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT col1 * - 12 + - col1 FROM tab1
----
-130
-169
-338

query I rowsort
SELECT ALL - cor0.col2 * col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT - + col0 * ( 1 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - col2 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - cor0.col1 col0 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT - + col0 * + col2 - 17 FROM tab2 AS cor0
----
-2045
-206
-3019

query I rowsort
SELECT col2 + 47 * col2 AS col1 FROM tab0
----
1584
3936
48

query I rowsort
SELECT col2 * col2 + ( tab1.col0 ) FROM tab1
----
2919
3313
9296

query I rowsort
SELECT + 7 * col0 AS col0 FROM tab2
----
49
546
553

query I rowsort
SELECT ALL 72 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT - 2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 20c9213316527d507e26425041e08387

onlyif mysql # use DIV operator for integer division
query I rowsort label-3772
SELECT col2 DIV col2 + 96 FROM tab0 AS cor0
----
97
97
97

skipif mysql # not compatible
query I rowsort label-3772
SELECT col2 / col2 + 96 FROM tab0 AS cor0
----
97
97
97

query I rowsort
SELECT - 47 * col1 AS col0 FROM tab1
----
-1222
-470
-611

query I rowsort
SELECT ALL ( - tab0.col0 ) FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT DISTINCT + col0 * + 7 AS col2 FROM tab2
----
49
546
553

query I rowsort
SELECT + col0 * + col2 + - 63 FROM tab1 AS cor0
----
3585
7617
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-3777
SELECT + col0 DIV + cor0.col0 + col1 col2 FROM tab0 AS cor0
----
87
92
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3777
SELECT + col0 / + cor0.col0 + col1 col2 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT + - col2 * - col2 + + col1 FROM tab1 AS cor0
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 57 * + col0 col0 FROM tab0 AS cor0
----
1401
1996
5155

onlyif mysql # use DIV operator for integer division
query I rowsort label-3780
SELECT col1 DIV cor0.col1 + - cor0.col1 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
1041
641
79

skipif mysql # not compatible
query I rowsort label-3780
SELECT col1 / cor0.col1 + - cor0.col1 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
1041
641
79

query I rowsort
SELECT + ( + col2 ) * tab2.col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT ALL - - 25 AS col2 FROM tab2 AS cor0
----
25
25
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col1 col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + cor0.col1 + 71 * - col0 FROM tab0 AS cor0
----
-1618
-2388
-6228

query I rowsort
SELECT ALL cor0.col1 + col1 * - col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT tab0.col1 AS col1 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - col1 * 97 FROM tab2 AS cor0
----
-1649
-3007
-5723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 52 * col0 col0 FROM tab0 AS cor0
----
1248
1820
4628

query I rowsort
SELECT + 69 AS col1 FROM tab0 cor0
----
69
69
69

query I rowsort
SELECT + 71 + cor0.col0 - + cor0.col1 AS col1 FROM tab0 cor0
----
69
9
9

query I rowsort
SELECT ALL + cor0.col2 * col2 * + col0 AS col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT + + cor0.col1 * - col2 + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3793
SELECT DISTINCT - + CAST( NULL AS DECIMAL ) + col2 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3793
SELECT DISTINCT - + CAST ( NULL AS REAL ) + col2 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + - ( - col2 ) * col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 4 * cor0.col2 col2 FROM tab0 cor0
----
132
328
4

query I rowsort
SELECT + cor0.col1 * - col2 + - col0 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL 16 + - col1 AS col0 FROM tab0
----
-70
-75
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3798
SELECT + col1 + - col2 * CAST( + col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif mysql # not compatible
query I rowsort label-3798
SELECT + col1 + - col2 * CAST ( + col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT + 5 + 3 AS col2 FROM tab2
----
8

query I rowsort
SELECT + col1 - - col1 * - col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - 39 + - col0 FROM tab2 AS cor0
----
-117
-118
-46

query I rowsort
SELECT - col2 + col0 * - ( + col1 + - col1 ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - + 5 AS col2 FROM tab0 AS cor0
----
-5
-5
-5

query I rowsort
SELECT DISTINCT + ( col1 ) * ( + col0 ) * col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT cor0.col0 + - col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT + col2 + col2 * col0 - - col1 FROM tab0 cor0
----
133
7471
911

onlyif mysql # use DIV operator for integer division
query I rowsort label-3807
SELECT - 19 DIV col1 AS col1 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-3807
SELECT - 19 / col1 AS col1 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT - ( 1 ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT - 33 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab2 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 29937e0f604055b7324ce0c354a5e778

query I rowsort
SELECT DISTINCT col2 + + 14 * col2 AS col1 FROM tab0 AS cor0
----
1230
15
495

query I rowsort
SELECT ALL - - col1 + - 60 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
157
2066
5011

query I rowsort
SELECT DISTINCT 39 + col2 * col1 - ( tab2.col1 + - 15 ) * 91 AS col1 FROM tab2
----
-2431
-580
503

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 + 47 col0 FROM tab2, tab1 cor0
----
9 values hashing to 49d412da1aa5be090cdef33d4d0fcb9b

query I rowsort
SELECT cor0.col1 * col2 * col1 AS col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
-1
-33
-82

query I rowsort
SELECT + 5 AS col1 FROM tab1 AS cor0
----
5
5
5

query I rowsort
SELECT - 40 AS col0 FROM tab0 cor0
----
-40
-40
-40

query I rowsort
SELECT DISTINCT - 58 FROM tab0, tab1 AS cor0
----
-58

query I rowsort
SELECT DISTINCT - ( - tab0.col0 + - col0 ) FROM tab0
----
178
48
70

query I rowsort
SELECT - + 9 * + cor0.col0 AS col0 FROM tab1 cor0
----
-27
-576
-720

onlyif mysql # use DIV operator for integer division
query I rowsort label-3822
SELECT + cor0.col2 DIV 78 AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3822
SELECT + cor0.col2 / 78 AS col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + - cor0.col0 + - 0 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + cor0.col2 - + 39 * + col0 FROM tab2 AS cor0
----
-246
-3016
-3043

query I rowsort
SELECT DISTINCT - + col1 * col0 + col0 FROM tab1 cor0
----
-576
-75
-960

query I rowsort
SELECT + col1 * col1 + - 69 AS col1 FROM tab0 AS cor0
----
7327
8212
9340

query I rowsort
SELECT + 8 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT - col1 * col2 + + col1 AS col0 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT col0 - col2 * + col0 AS col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT col0 * + 5 + 27 * - col2 AS col0 FROM tab1
----
-1219
-1443
-2192

query I rowsort
SELECT ALL + col1 + + col0 * - col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + tab2.col2 + ( 24 ) AS col0 FROM tab2
----
50
51
62

query I rowsort
SELECT - 60 FROM tab2, tab2 AS cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

query I rowsort
SELECT ALL - 29 + + col0 * cor0.col0 FROM tab0 AS cor0
----
1196
547
7892

query I rowsort
SELECT - 7 * - col0 + - col0 AS col2 FROM tab0 AS cor0
----
144
210
534

query I rowsort
SELECT - ( - cor0.col1 ) * 86 FROM tab0, tab2 AS cor0
----
9 values hashing to d37849d551c3e612af02856f5e5e76f3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3837
SELECT ALL col0 DIV col0 - + col0 AS col2 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-3837
SELECT ALL col0 / col0 - + col0 AS col2 FROM tab0
----
-23
-34
-88

query I rowsort
SELECT ALL col0 - col1 * - col1 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT + col1 + col2 * + col1 + tab1.col0 AS col2 FROM tab1
----
1341
1433
644

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-3841
SELECT - ( col1 ) * + col1 + + col0 DIV cor0.col0 FROM tab1 AS cor0
----
-168
-675
-99

skipif mysql # not compatible
query I rowsort label-3841
SELECT - ( col1 ) * + col1 + + col0 / cor0.col0 FROM tab1 AS cor0
----
-168
-675
-99

query I rowsort
SELECT + - 96 + - col0 * 89 * col0 FROM tab0 cor0
----
-109121
-51360
-705065

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + cor0.col2 col1 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3844
SELECT ALL - col1 - + col2 DIV + col0 FROM tab0 AS cor0
----
-87
-91
-97

skipif mysql # not compatible
query I rowsort label-3844
SELECT ALL - col1 - + col2 / + col0 FROM tab0 AS cor0
----
-87
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * + col2 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-3846
SELECT + col1 * + col0 DIV - col0 + - cor0.col2 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-3846
SELECT + col1 * + col0 / - col0 + - cor0.col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3847
SELECT ALL + 47 + + col1 * 57 DIV col0 AS col1 FROM tab0 AS cor0
----
105
204
251

skipif mysql # not compatible
query I rowsort label-3847
SELECT ALL + 47 + + col1 * 57 / col0 AS col1 FROM tab0 AS cor0
----
105
204
251

query I rowsort
SELECT DISTINCT - col2 * - col2 + col0 AS col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT - - ( - col2 ) * - ( cor0.col2 ) + - col1 * ( + col0 ) FROM tab0 AS cor0
----
-1375
-3394
-975

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 45 * + col2 - + col1 * - col1 * - col1 col2 FROM tab2 AS cor0
----
-204209
-28576
-3203

onlyif mysql # use DIV operator for integer division
query I rowsort label-3851
SELECT - + col0 * col2 DIV + col2 + col1 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-3851
SELECT - + col0 * col2 / + col2 + col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL cor0.col2 * col0 + 28 FROM tab1 AS cor0
----
190
3676
7708

query I rowsort
SELECT DISTINCT - - col0 * col2 * 33 + 42 * col2 - + col0 AS col1 FROM tab2 AS cor0
----
100583
67938
7364

query I rowsort
SELECT DISTINCT col0 + + col2 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT - 36 + col0 FROM tab1
----
-33
28
44

query I rowsort
SELECT + 87 * - tab2.col2 + col1 + - col2 FROM tab2
----
-2229
-2345
-3327

query I rowsort
SELECT DISTINCT ( - col2 ) + + 8 AS col0 FROM tab0
----
-25
-74
7

query I rowsort
SELECT DISTINCT tab2.col2 FROM tab2, tab0, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + col1 + + cor0.col2 - 36 AS col1 FROM tab1 AS cor0
----
31
44
73

query I rowsort
SELECT - 69 * - col0 + - col0 * + col1 FROM tab2 AS cor0
----
266
4108
780

query I rowsort
SELECT DISTINCT tab1.col2 * + col2 AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT DISTINCT 26 * + col0 + - col1 AS col0 FROM tab1
----
1654
2067
52

query I rowsort
SELECT ALL + + 67 FROM tab2 AS cor0
----
67
67
67

query I rowsort
SELECT DISTINCT + col1 + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + cor0.col1 + + 24 * col0 FROM tab0 AS cor0
----
2227
662
937

query I rowsort
SELECT - - col1 + - ( col0 ) AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + col0 + col2 + col0 FROM tab0 cor0
----
260
71
81

query I rowsort
SELECT DISTINCT - col1 + ( + col1 ) AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - col0 - - 61 AS col2 FROM tab2 AS cor0
----
-17
-18
54

query I rowsort
SELECT DISTINCT - - col2 * col0 + col1 * + cor0.col0 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT ALL col2 * + col2 - + col0 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

onlyif mysql # use DIV operator for integer division
query I rowsort label-3872
SELECT col0 DIV + cor0.col0 + col0 * cor0.col1 FROM tab2 AS cor0
----
1344
218
4603

skipif mysql # not compatible
query I rowsort label-3872
SELECT col0 / + cor0.col0 + col0 * cor0.col1 FROM tab2 AS cor0
----
1344
218
4603

query I rowsort
SELECT + col2 + + 43 * - col0 * col2 FROM tab2 AS cor0
----
-129048
-8100
-87178

query I rowsort
SELECT col0 * 84 AS col1 FROM tab0 cor0
----
2016
2940
7476

query I rowsort
SELECT DISTINCT + col1 * + 87 AS col0 FROM tab2 cor0
----
1479
2697
5133

query I rowsort
SELECT DISTINCT + col2 * - 28 FROM tab0 cor0
----
-2296
-28
-924

query I rowsort
SELECT DISTINCT col1 * ( - 1 ) + + cor0.col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - + col0 - col0 * - col2 FROM tab1 AS cor0
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + tab0.col0 col2 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL tab2.col2 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT + 0 AS col0 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT col2 * + 68 FROM tab2 AS cor0
----
1768
1836
2584

query I rowsort
SELECT col0 + 58 * col1 * - col2 AS col0 FROM tab0 AS cor0
----
-164580
-432707
-5591

query I rowsort
SELECT - 18 * col0 AS col1 FROM tab2 cor0
----
-126
-1404
-1422

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col0 col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + 50 * + 37 * col2 AS col2 FROM tab2 AS cor0
----
48100
49950
70300

query I rowsort
SELECT DISTINCT + - 13 AS col1 FROM tab1 AS cor0
----
-13

query I rowsort
SELECT + 32 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT ALL - - col1 + 7 FROM tab2 cor0
----
24
38
66

query I rowsort
SELECT + ( 27 ) FROM tab1 AS cor0
----
27
27
27

query I rowsort
SELECT DISTINCT - ( - 52 ) AS col0 FROM tab2 AS cor0
----
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) * + col0 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + cor0.col2 * cor0.col2 + - col1 + col1 * + ( col1 + - ( + ( col1 ) ) ) FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT ALL - 19 * + col2 FROM tab0 AS cor0
----
-1558
-19
-627

query I rowsort
SELECT + ( 86 ) FROM tab1 AS cor0
----
86
86
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3896
SELECT ALL - CAST( col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3896
SELECT ALL - CAST ( col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL - + 5 AS col2 FROM tab1 AS cor0
----
-5
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3898
SELECT DISTINCT 68 * col0 DIV col2 + col2 + 35 * - col0 FROM tab1 AS cor0
----
-2107
-2648
-48

skipif mysql # not compatible
query I rowsort label-3898
SELECT DISTINCT 68 * col0 / col2 + col2 + 35 * - col0 FROM tab1 AS cor0
----
-2107
-2648
-48

query I rowsort
SELECT ALL - + ( + cor0.col1 ) * col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + 94 + col0 + cor0.col2 * col1 FROM tab2 AS cor0
----
1706
819
938

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3901
SELECT ALL + - CAST( - col0 AS SIGNED ) * - col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-3901
SELECT ALL + - CAST ( - col0 AS INTEGER ) * - col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL col2 + cor0.col2 AS col0 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT - tab2.col0 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT - col2 * + 21 AS col2 FROM tab1 cor0
----
-1134
-1197
-2016

query I rowsort
SELECT ALL + 84 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT col1 * + cor0.col1 + col2 FROM tab1 AS cor0
----
157
265
730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 49 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT DISTINCT - col1 * + ( - col0 ) AS col2 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3909
SELECT + col1 DIV - 96 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3909
SELECT + col1 / - 96 FROM tab0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3910
SELECT col0 DIV + 26 AS col1 FROM tab0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-3910
SELECT col0 / + 26 AS col1 FROM tab0
----
0
1
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3911
SELECT - col2 * CAST( NULL AS SIGNED ) / + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3911
SELECT - col2 * CAST ( NULL AS INTEGER ) / + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * 57 + - col1 FROM tab0
----
-1454
-2092
-5164

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 76 col0 FROM tab2
----
532
5928
6004

query I rowsort
SELECT DISTINCT + 66 FROM tab0, tab2 AS cor0
----
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 ) * col2 col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + - 11 * col1 AS col0 FROM tab2 AS cor0
----
-187
-341
-649

query I rowsort
SELECT + col0 * - col0 + col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT col2 * + col2 - - col1 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT + col1 * 68 + - col1 FROM tab0 AS cor0
----
5762
6097
6499

query I rowsort
SELECT DISTINCT - col2 * col0 + cor0.col1 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3921
SELECT DISTINCT - col0 + ( col0 ) + - CAST( NULL AS DECIMAL ) col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3921
SELECT DISTINCT - col0 + ( col0 ) + - CAST ( NULL AS REAL ) col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 + ( col1 * - col0 + col1 * col0 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - + 8 + ( col1 ) AS col2 FROM tab1 AS cor0
----
18
2
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3924
SELECT DISTINCT 94 DIV - col2 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-3924
SELECT DISTINCT 94 / - col2 FROM tab1
----
-1
0

query I rowsort
SELECT - cor1.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT DISTINCT - col1 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3927
SELECT DISTINCT + - col0 DIV col0 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3927
SELECT DISTINCT + - col0 / col0 FROM tab1 cor0
----
-1

query I rowsort
SELECT ALL + + cor0.col0 * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - 53 AS col0 FROM tab0 AS cor0
----
-53

query I rowsort
SELECT - - 68 * + col2 AS col1 FROM tab2 AS cor0
----
1768
1836
2584

query I rowsort
SELECT DISTINCT - - col2 * ( cor0.col2 ) FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL - cor0.col1 * - col2 + cor0.col0 * col0 AS col0 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT DISTINCT - col2 * 67 FROM tab2
----
-1742
-1809
-2546

query I rowsort
SELECT ALL 37 FROM tab1, tab0 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 * col2 col0 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT - 54 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

query I rowsort
SELECT + col0 * ( - col1 ) * col2 AS col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3938
SELECT cor0.col0 DIV 17 FROM tab2 AS cor0
----
0
4
4

skipif mysql # not compatible
query I rowsort label-3938
SELECT cor0.col0 / 17 FROM tab2 AS cor0
----
0
4
4

query I rowsort
SELECT ALL + + col2 + 10 * col0 AS col1 FROM tab1 AS cor0
----
697
84
896

query I rowsort
SELECT DISTINCT col0 * col2 * - col1 AS col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + ( - col0 ) * - col1 + col1 * - 26 FROM tab0 AS cor0
----
-172
5733
873

query I rowsort
SELECT ALL - col1 * ( - col2 * ( + cor0.col1 ) + col1 ) AS col2 FROM tab0 AS cor0
----
0
236672
670761

query I rowsort
SELECT DISTINCT + - cor0.col0 + 85 FROM tab0 AS cor0
----
-4
50
61

query I rowsort
SELECT + cor0.col2 + col0 + - col2 * + col2 AS col1 FROM tab0 AS cor0
----
-1032
-6553
35

query I rowsort
SELECT - + col1 * - cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - col2 * - col2 + + col0 AS col2 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - tab0.col2 * tab0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 18f45a7edd86e3eccc832dcdb6123662

query I rowsort
SELECT DISTINCT + col2 * col2 * 5 AS col0 FROM tab0 AS cor0
----
33620
5
5445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - 72 col1 FROM tab1 AS cor0
----
-46
-59
-62

query I rowsort
SELECT ALL - - col1 + + cor0.col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL col0 + ( col0 ) * cor0.col0 AS col1 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT ( - col2 + + ( - col2 ) ) FROM tab1
----
-108
-114
-192

query I rowsort
SELECT + - cor0.col0 FROM tab1, tab2, tab1 AS cor0, tab0
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT col2 * cor0.col0 - + ( 99 ) * col1 FROM tab1 AS cor0
----
-2412
2658
6393

onlyif mysql # use DIV operator for integer division
query I rowsort label-3955
SELECT 87 DIV + col0 FROM tab2 cor0
----
1
1
12

skipif mysql # not compatible
query I rowsort label-3955
SELECT 87 / + col0 FROM tab2 cor0
----
1
1
12

query I rowsort
SELECT + cor0.col2 + + col2 * - col0 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-3957
SELECT + col0 DIV cor0.col0 + 85 * col1 * + col0 AS col0 FROM tab2 AS cor0
----
114156
18446
391171

skipif mysql # not compatible
query I rowsort label-3957
SELECT + col0 / cor0.col0 + 85 * col1 * + col0 AS col0 FROM tab2 AS cor0
----
114156
18446
391171

query I rowsort
SELECT DISTINCT + ( - cor0.col0 ) * + ( col2 ) FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 * col0 col2 FROM tab1 AS cor0
----
225
4800
6000

query I rowsort
SELECT ALL + - col1 + - col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + col0 - cor0.col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + + 98 AS col0 FROM tab0 AS cor0
----
98

query I rowsort
SELECT DISTINCT cor0.col2 * cor0.col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT ( + col0 ) * + col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + - col1 + col1 + + ( - col1 ) * col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 4 AS col1 FROM tab1 cor0
----
-4
-4
-4

query I rowsort
SELECT col2 * col0 * col0 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT - col1 * ( - col0 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - - col0 * + 58 AS col0 FROM tab2 AS cor0
----
406
4524
4582

query I rowsort
SELECT ALL + col2 + ( - 58 ) AS col2 FROM tab2 AS cor0
----
-20
-31
-32

onlyif mysql # use DIV operator for integer division
query I rowsort label-3971
SELECT ALL + col0 DIV + col2 + - ( + 41 ) FROM tab0
----
-40
-41
-6

skipif mysql # not compatible
query I rowsort label-3971
SELECT ALL + col0 / + col2 + - ( + 41 ) FROM tab0
----
-40
-41
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3972
SELECT ALL 68 + + col0 DIV col0 FROM tab2
----
69
69
69

skipif mysql # not compatible
query I rowsort label-3972
SELECT ALL 68 + + col0 / col0 FROM tab2
----
69
69
69

query I rowsort
SELECT DISTINCT col2 + col1 * 33 AS col2 FROM tab2
----
1050
1973
599

query I rowsort
SELECT ALL + ( col2 ) + - col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3975
SELECT ALL ( - col2 ) + cor0.col0 DIV col0 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-3975
SELECT ALL ( - col2 ) + cor0.col0 / col0 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT + 46 * col0 * + col0 AS col1 FROM tab2 cor0
----
2254
279864
287086

query I rowsort
SELECT col0 * - 21 AS col2 FROM tab0 AS cor0
----
-1869
-504
-735

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3978
SELECT - CAST( col0 AS SIGNED ) * + col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-3978
SELECT - CAST ( col0 AS INTEGER ) * + col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL - 17 * - col0 + col1 * col1 FROM tab2 AS cor0
----
1080
1632
4807

query I rowsort
SELECT - 33 FROM tab1, tab0 cor0
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

query I rowsort
SELECT - - 93 + + 91 AS col2 FROM tab2 AS cor0
----
184
184
184

onlyif mysql # use DIV operator for integer division
query I rowsort label-3982
SELECT - + cor0.col2 DIV + 20 col2 FROM tab1 AS cor0
----
-2
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3982
SELECT - + cor0.col2 / + 20 col2 FROM tab1 AS cor0
----
-2
-2
-4

query I rowsort
SELECT DISTINCT - 14 * - tab1.col2 * - col1 - 88 FROM tab1
----
-17560
-19744
-8068

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - 37 col0 FROM tab2
----
63
64
75

query I rowsort
SELECT - col0 * + col2 + + tab0.col1 + tab0.col2 FROM tab0
----
-673
-7125
63

query I rowsort
SELECT col2 + - col2 * col1 + - col1 * col0 AS col0 FROM tab1
----
-1153
-1428
-2192

query I rowsort
SELECT + col1 * + col1 + + 3 AS col1 FROM tab0 AS cor0
----
7399
8284
9412

query I rowsort
SELECT 55 + col0 FROM tab0 AS cor0
----
144
79
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3989
SELECT + col1 DIV col1 + col0 * col2 + 20 AS col0 FROM tab0
----
56
7319
813

skipif mysql # not compatible
query I rowsort label-3989
SELECT + col1 / col1 + col0 * col2 + 20 AS col0 FROM tab0
----
56
7319
813

query I rowsort
SELECT DISTINCT 49 FROM tab0, tab2, tab0 AS cor0, tab1
----
49

query I rowsort
SELECT DISTINCT - 42 FROM tab1, tab2, tab2 cor0, tab0
----
-42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col1 + col2 + col2 col0 FROM tab1
----
104
179
82

query I rowsort
SELECT ( - col2 ) + col1 AS col0 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - ( col1 ) ) col2 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT 63 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
63

query I rowsort
SELECT DISTINCT 91 * col0 AS col1 FROM tab0
----
2184
3185
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 27 + col1 * - ( col0 ) * col0 col1 FROM tab0
----
-118852
-49563
-720838

query I rowsort
SELECT + col0 * tab2.col1 * ( - col2 * - col0 ) + + col0 FROM tab2
----
4031765
41020
9332934

query I rowsort
SELECT - col1 + cor0.col0 * - col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL - 51 + col2 AS col2 FROM tab2 cor0
----
-13
-24
-25

onlyif mysql # use DIV operator for integer division
query I rowsort label-4001
SELECT ( tab2.col2 ) DIV - tab2.col1 AS col1 FROM tab2
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-4001
SELECT ( tab2.col2 ) / - tab2.col1 AS col1 FROM tab2
----
-2
0
0

query I rowsort
SELECT + cor0.col2 + col0 + cor0.col0 * 85 AS col0 FROM tab0 AS cor0
----
2097
3011
7736

query I rowsort
SELECT ALL + ( + col1 ) + cor0.col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - - cor0.col1 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 * - col2 col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + tab1.col1 - ( - col0 * + col0 ) FROM tab1
----
35
4106
6413

query I rowsort
SELECT tab0.col1 + 34 AS col1 FROM tab0
----
120
125
131

query I rowsort
SELECT DISTINCT - + col2 - + col0 FROM tab1 AS cor0
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - col1 + - ( col1 ) AS col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT + col1 * + cor0.col0 + col2 * + col2 FROM tab1 cor0
----
10256
2994
3889

query I rowsort
SELECT DISTINCT 7 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
7

query I rowsort
SELECT - col0 + col0 * col0 FROM tab1
----
4032
6
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 34 * - cor0.col2 col0 FROM tab2 AS cor0
----
-1292
-884
-918

query I rowsort
SELECT ALL - col2 * + 77 AS col2 FROM tab2 AS cor0
----
-2002
-2079
-2926

onlyif mysql # use DIV operator for integer division
query I rowsort label-4016
SELECT ALL + - ( - col2 ) DIV - col1 AS col1 FROM tab1 cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-4016
SELECT ALL + - ( - col2 ) / - col1 AS col1 FROM tab1 cor0
----
-2
-5
-7

query I rowsort
SELECT ALL col1 + - col0 + col0 AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + col0 + + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1612
725
844

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 cor0, tab1, tab1 AS cor1
----
972 values hashing to f8fe28681e8720551e1ec173631fc529

query I rowsort
SELECT + + 51 AS col0 FROM tab2 AS cor0
----
51
51
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-4021
SELECT ALL + 65 * col1 - col0 DIV + col0 AS col0 FROM tab1 cor0
----
1689
649
844

skipif mysql # not compatible
query I rowsort label-4021
SELECT ALL + 65 * col1 - col0 / + col0 AS col0 FROM tab1 cor0
----
1689
649
844

query I rowsort
SELECT - + 18 FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + ( col2 ) * - col0 * + col2 AS col1 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT 1 FROM tab2 cor0
----
1

query I rowsort
SELECT ALL + col2 + 47 AS col2 FROM tab0 AS cor0
----
129
48
80

query I rowsort
SELECT ALL - - 0 * + col2 + col0 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col1 col0 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4028
SELECT ALL - CAST( NULL AS SIGNED ) + + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4028
SELECT ALL - CAST ( NULL AS INTEGER ) + + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT - col0 BETWEEN col2 + col0 * + col1 / - col1 AND NULL
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL NOT IN ( - col2 - col2 )
----

query I rowsort
SELECT + cor0.col1 - - cor0.col2 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 5484e660e65aa37f29a1eca3fc30f5cc

query I rowsort
SELECT + col2 FROM tab0 AS cor0 WHERE NOT - col0 * col0 <= col2 * col1
----

query I rowsort
SELECT cor0.col2 * - col0 * col1 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) <> col2 + - col0
----

query I rowsort
SELECT DISTINCT col2 + + col1 FROM tab2 AS cor0 WHERE NULL <> col0 * + col0 * - col1 + - col1 / + col0
----

query I rowsort
SELECT DISTINCT + tab0.col1 * col0 * tab0.col0 AS col2 FROM tab0
----
118825
49536
720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 * col1 * + col1 col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT - tab0.col1 * + col0 * col1 AS col2 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT col0 / tab2.col0 + - col0 FROM tab2 WHERE NOT col2 + col1 BETWEEN + col0 + - col2 AND col2 * col1 * col1
----

query I rowsort
SELECT DISTINCT - col0 + col1 * col0 - tab2.col2 FROM tab2
----
1226
183
4498

query I rowsort
SELECT ALL + tab0.col2 * col1 * col0 AS col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL col1 FROM tab2 WHERE NULL NOT IN ( col1 - + col1 * + col2 * col1 )
----

query I rowsort
SELECT col0 + + col2 * + col0 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-4044
SELECT col2 + - col0 DIV - col2 FROM tab1
----
54
58
96

skipif mysql # not compatible
query I rowsort label-4044
SELECT col2 + - col0 / - col2 FROM tab1
----
54
58
96

query I rowsort
SELECT DISTINCT + col1 + tab0.col2 * - col0 AS col0 FROM tab0
----
-706
-7207
62

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT + col1 * + col0 BETWEEN + col2 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 col1 FROM tab2
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4048
SELECT + cor0.col2 DIV - col1 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-4048
SELECT + cor0.col2 / - col1 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT col2 FROM tab1 WHERE NOT NULL > col0 AND NULL >= - col0
----

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT col0 + col0 * + col0 * col0 AS col1 FROM tab2
----
350
474630
493118

onlyif mysql # use DIV operator for integer division
query I rowsort label-4052
SELECT col2 * col2 DIV + col1 + - col1 FROM tab2
----
-48
-8
67

skipif mysql # not compatible
query I rowsort label-4052
SELECT col2 * col2 / + col1 + - col1 FROM tab2
----
-48
-8
67

query I rowsort
SELECT + col0 + col2 * + tab2.col1 AS col0 FROM tab2
----
1612
725
844

query III rowsort
SELECT * FROM tab2 WHERE NOT + col0 BETWEEN col1 + - col2 AND NULL
----

query I rowsort
SELECT DISTINCT col0 + - col0 * col2 * col1 AS col1 FROM tab2 WHERE NOT NULL <> ( col0 )
----

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 * + col0 AS col1 FROM tab2 cor0
----
-22831
-271518
-6727

query I rowsort
SELECT - col0 AS col0 FROM tab0 WHERE NOT col2 - + col1 * col0 NOT IN ( col1 )
----

query I rowsort
SELECT - 64 * col2 FROM tab2
----
-1664
-1728
-2432

onlyif mysql # use DIV operator for integer division
query I rowsort label-4059
SELECT ALL cor0.col0 DIV + col1 + 41 AS col2 FROM tab1 cor0
----
41
47
47

skipif mysql # not compatible
query I rowsort label-4059
SELECT ALL cor0.col0 / + col1 + 41 AS col2 FROM tab1 cor0
----
41
47
47

query I rowsort
SELECT ALL - col0 * - col0 - - col1 * col0 AS col2 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT DISTINCT + - cor0.col2 * 64 + col0 FROM tab2 AS cor0
----
-1586
-1721
-2353

query I rowsort
SELECT ALL + cor0.col1 * col2 + col2 + col2 * 95 AS col2 FROM tab1 AS cor0
----
10464
6042
6588

query I rowsort
SELECT + col2 + 16 FROM tab2 cor0
----
42
43
54

query I rowsort
SELECT DISTINCT - + cor0.col2 * + col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT cor0.col0 + - col1 + 37 * col1 AS col2 FROM tab1 cor0
----
424
548
939

query I rowsort
SELECT DISTINCT 13 + + col2 * - ( + col0 ) FROM tab2
----
-176
-2015
-2989

onlyif mysql # use DIV operator for integer division
query I rowsort label-4067
SELECT col2 DIV col2 - + col1 AS col2 FROM tab0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-4067
SELECT col2 / col2 - + col1 AS col2 FROM tab0
----
-85
-90
-96

query I rowsort
SELECT 11 * col2 AS col0 FROM tab1
----
1056
594
627

query I rowsort
SELECT ALL - ( - tab0.col0 ) AS col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + ( col2 ) * col0 col1 FROM tab1
----
165
3712
7760

query I rowsort
SELECT ALL - - col2 * cor0.col0 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT - cor0.col2 + - 39 AS col2 FROM tab2 AS cor0
----
-65
-66
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4073
SELECT DISTINCT + col2 + - col2 DIV - 53 FROM tab0 AS cor0
----
1
33
83

skipif mysql # not compatible
query I rowsort label-4073
SELECT DISTINCT + col2 + - col2 / - 53 FROM tab0 AS cor0
----
1
33
83

query I rowsort
SELECT DISTINCT - - col0 * + 28 + + col1 AS col2 FROM tab1 AS cor0
----
110
1802
2253

query I rowsort
SELECT DISTINCT col2 + col2 + col1 AS col1 FROM tab2 AS cor0
----
111
85
93

query I rowsort
SELECT ALL + col0 + col2 * + col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT - col0 * + col0 + - tab2.col1 FROM tab2
----
-6143
-6258
-80

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) IN ( - tab2.col2 * + col2 + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4079
SELECT ALL + col1 * col2 DIV + col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4079
SELECT ALL + col1 * col2 / + col1 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT - col1 - col0 AS col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT + tab1.col0 * + col0 + - col1 * + col0 AS col1 FROM tab1
----
-69
3456
5360

query I rowsort
SELECT - col1 * col0 - col1 AS col1 FROM tab0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL col0 + tab2.col2 + col1 AS col0 FROM tab2
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-4084
SELECT col0 DIV - col2 + - col2 AS col0 FROM tab1
----
-54
-58
-96

skipif mysql # not compatible
query I rowsort label-4084
SELECT col0 / - col2 + - col2 AS col0 FROM tab1
----
-54
-58
-96

query I rowsort
SELECT col2 * - col2 + col1 + - col0 FROM tab2
----
-1506
-695
-705

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL NOT IN ( - col0 * - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4087
SELECT DISTINCT col2 DIV + col1 AS col2 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-4087
SELECT DISTINCT col2 / + col1 AS col2 FROM tab0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4088
SELECT + col1 * col2 DIV col2 col0 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4088
SELECT + col1 * col2 / col2 col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL - col1 FROM tab1 WHERE ( NULL ) IN ( + col0 * - col0 + tab1.col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4090
SELECT - col2 DIV + col0 + 13 * + 41 FROM tab1 AS cor0
----
515
532
533

skipif mysql # not compatible
query I rowsort label-4090
SELECT - col2 / + col0 + 13 * + 41 FROM tab1 AS cor0
----
515
532
533

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 96 * - col0 col1 FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT DISTINCT - + ( + col2 ) * col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - col1 * col1 + - col0 AS col0 FROM tab2
----
-3559
-368
-968

onlyif mysql # use DIV operator for integer division
query I rowsort label-4094
SELECT + col2 * - col2 DIV col2 + col1 FROM tab0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-4094
SELECT + col2 * - col2 / col2 + col1 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT col0 + col0 * - col0 * col1 FROM tab2
----
-106018
-1512
-358878

query I rowsort
SELECT + 1 AS col1 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4097
SELECT ALL - col1 * col1 + + CAST( + col0 AS SIGNED ) * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-15579
-8188
-9444

skipif mysql # not compatible
query I rowsort label-4097
SELECT ALL - col1 * col1 + + CAST ( + col0 AS INTEGER ) * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-15579
-8188
-9444

query I rowsort
SELECT + 25 + col1 AS col2 FROM tab0 AS cor0
----
111
116
122

query I rowsort
SELECT DISTINCT - col1 * + col1 - - ( 3 ) AS col2 FROM tab1 AS cor0
----
-166
-673
-97

query I rowsort
SELECT DISTINCT - 2 * col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT - 2 FROM tab2 AS cor0
----
-2

query I rowsort
SELECT 39 + - cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to d9056564cc9403ecb08b5a2d52e7c612

query I rowsort
SELECT ALL + col2 + cor0.col1 * + col1 FROM tab2 cor0
----
327
3507
988

query I rowsort
SELECT + col1 * 77 FROM tab0 AS cor0
----
6622
7007
7469

query I rowsort
SELECT + col1 * ( col1 ) * col1 AS col0 FROM tab0 cor0
----
636056
753571
912673

query I rowsort
SELECT + - col2 * col1 * col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

skipif mysql # not compatible
query I rowsort
SELECT ALL - col0 * CAST ( - 78 AS REAL ) FROM tab1 AS cor0
----
234
4992
6240

query I rowsort
SELECT - col2 * + ( col0 ) AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT ( col1 ) * - col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4110
SELECT 3 DIV 38 + - col1 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4110
SELECT 3 / 38 + - col1 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - + col0 + col0 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 94 - 78 AS col2 FROM tab0 cor0
----
-172
-172
-172

onlyif mysql # use DIV operator for integer division
query I rowsort label-4113
SELECT ALL col2 DIV + col1 + - col0 AS col2 FROM tab1 AS cor0
----
-1
-59
-73

skipif mysql # not compatible
query I rowsort label-4113
SELECT ALL col2 / + col1 + - col0 AS col2 FROM tab1 AS cor0
----
-1
-59
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4114
SELECT DISTINCT 15 * + 38 + col2 - + CAST( NULL AS SIGNED ) * + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4114
SELECT DISTINCT 15 * + 38 + col2 - + CAST ( NULL AS INTEGER ) * + col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 + ( col2 ) + ( col1 ) col0 FROM tab2
----
134
163
65

query I rowsort
SELECT ALL - + 89 * - col0 AS col1 FROM tab0 AS cor0
----
2136
3115
7921

query I rowsort
SELECT ALL - 51 * - col2 AS col1 FROM tab1 AS cor0
----
2754
2907
4896

onlyif mysql # use DIV operator for integer division
query I rowsort label-4118
SELECT ALL col1 - + col2 DIV 91 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4118
SELECT ALL col1 - + col2 / 91 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4119
SELECT ALL + + col0 DIV - col1 + + col2 * - col0 * - col1 + col2 FROM tab0 cor0
----
3396
664200
68145

skipif mysql # not compatible
query I rowsort label-4119
SELECT ALL + + col0 / - col1 + + col2 * - col0 * - col1 + col2 FROM tab0 cor0
----
3396
664200
68145

query I rowsort
SELECT DISTINCT 79 + col0 AS col2 FROM tab0 AS cor0
----
103
114
168

onlyif mysql # use DIV operator for integer division
query I rowsort label-4121
SELECT + col1 DIV - col2 - - col1 * - ( - ( + col2 ) ) AS col0 FROM tab0 cor0
----
0
2836
7461

skipif mysql # not compatible
query I rowsort label-4121
SELECT + col1 / - col2 - - col1 * - ( - ( + col2 ) ) AS col0 FROM tab0 cor0
----
0
2836
7461

query I rowsort
SELECT DISTINCT - col2 + col0 - + col0 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4123
SELECT - col0 DIV + tab2.col1 - col0 * 74 FROM tab2
----
-518
-5773
-5850

skipif mysql # not compatible
query I rowsort label-4123
SELECT - col0 / + tab2.col1 - col0 * 74 FROM tab2
----
-518
-5773
-5850

query I rowsort
SELECT 7 + + col0 FROM tab2
----
14
85
86

query I rowsort
SELECT DISTINCT - 79 * - col2 FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT DISTINCT + - 49 + col0 AS col2 FROM tab2 cor0
----
-42
29
30

query I rowsort
SELECT cor0.col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL + cor1.col2 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-4129
SELECT ALL + + col0 DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4129
SELECT ALL + + col0 / + col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * cor0.col1 col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + + col0 * 1 - col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4132
SELECT ALL col2 * CAST( NULL AS DECIMAL ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4132
SELECT ALL col2 * CAST ( NULL AS REAL ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col2 + 66 + col1 FROM tab2 cor0
----
45
70
99

query I rowsort
SELECT ALL + + cor0.col1 + col0 AS col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4135
SELECT DISTINCT - col2 * + CAST( - col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-4135
SELECT DISTINCT - col2 * + CAST ( - col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 * - 60 col1 FROM tab0 AS cor0
----
-170280
-447720
-5820

query I rowsort
SELECT DISTINCT 49 * + col2 FROM tab0
----
1617
4018
49

query IIIIIIIII rowsort
SELECT * FROM tab1, tab0, tab0 AS cor0 WHERE ( NULL ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL ( + cor1.col1 ) * 37 AS col0 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to 2c5dda53c552c57cd0caf57be2369981

query I rowsort
SELECT DISTINCT - col1 * 1 * cor0.col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - - 2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT tab2.col2 * - tab2.col1 + 41 * - tab2.col1 FROM tab2
----
-1343
-2108
-3953

query I rowsort
SELECT ALL col1 * - col0 * - col0 AS col2 FROM tab1
----
234
40960
83200

query I rowsort
SELECT - col0 + + col0 * col2 FROM tab0 cor0
----
0
7209
768

query I rowsort
SELECT + 61 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT DISTINCT col1 * - col1 + col0 * col0 FROM tab2
----
-912
2603
5952

query I rowsort
SELECT + ( + cor0.col0 ) + ( col2 ) * col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT 27 + col1 AS col2 FROM tab1
----
37
40
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4149
SELECT DISTINCT CAST( 61 AS SIGNED ) + + col2 * + 8 AS col2 FROM tab2
----
269
277
365

skipif mysql # not compatible
query I rowsort label-4149
SELECT DISTINCT CAST ( 61 AS INTEGER ) + + col2 * + 8 AS col2 FROM tab2
----
269
277
365

query I rowsort
SELECT + ( col1 ) + col0 + + col0 AS col1 FROM tab1
----
138
173
32

query I rowsort
SELECT ALL tab0.col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - 68 * tab2.col2 AS col0 FROM tab2, tab0 AS cor0
----
-1768
-1836
-2584

query I rowsort
SELECT ALL 78 - cor0.col0 * 77 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 0ea3f3c1c1c64f0a501a6a3fa0e330a3

query I rowsort
SELECT DISTINCT col2 * + col2 + tab1.col1 FROM tab1
----
2942
3259
9229

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4155
SELECT - CAST( NULL AS DECIMAL ) * col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4155
SELECT - CAST ( NULL AS REAL ) * col2 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 50 * col1 AS col0 FROM tab2 AS cor0
----
1550
2950
850

query I rowsort
SELECT DISTINCT ( + col0 ) + + cor0.col1 FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort
SELECT ALL 62 * col1 + - CAST ( 42 AS REAL ) AS col1 FROM tab1 cor0
----
1570
578
764

query I rowsort
SELECT DISTINCT - 42 * - col2 + col2 AS col2 FROM tab2 cor0
----
1118
1161
1634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4160
SELECT ALL + col1 - + col1 * ( col0 + col1 * + CAST( NULL AS DECIMAL ) ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4160
SELECT ALL + col1 - + col1 * ( col0 + col1 * + CAST ( NULL AS REAL ) ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 * col2 * - col0 AS col2 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT - - ( + col2 ) + + col1 * 14 AS col2 FROM tab1 AS cor0
----
197
278
418

query I rowsort
SELECT DISTINCT - - cor0.col2 * col1 + col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-4164
SELECT ALL + col0 DIV - col0 col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4164
SELECT ALL + col0 / - col0 col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - 48 + - cor0.col1 * + col1 * - cor0.col2 FROM tab1 AS cor0
----
16176
36456
5652

query I rowsort
SELECT - 67 + + col1 AS col2 FROM tab2 AS cor0
----
-36
-50
-8

query I rowsort
SELECT ALL 18 * col2 FROM tab0
----
1476
18
594

query I rowsort
SELECT DISTINCT ( - 68 ) AS col0 FROM tab0, tab1, tab1 AS cor0
----
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4169
SELECT CAST( 97 AS SIGNED ) FROM tab0
----
97
97
97

skipif mysql # not compatible
query I rowsort label-4169
SELECT CAST ( 97 AS INTEGER ) FROM tab0
----
97
97
97

query I rowsort
SELECT DISTINCT + + 74 + - col0 * + col0 - 22 FROM tab0 AS cor0
----
-1173
-524
-7869

query I rowsort
SELECT ALL + 57 * col0 AS col1 FROM tab1
----
171
3648
4560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4172
SELECT 48 + - col1 DIV + col2 AS col2 FROM tab0 AS cor0
----
-49
46
47

skipif mysql # not compatible
query I rowsort label-4172
SELECT 48 + - col1 / + col2 AS col2 FROM tab0 AS cor0
----
-49
46
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-4173
SELECT + + 94 + - col0 DIV col2 AS col2 FROM tab0 AS cor0
----
59
93
94

skipif mysql # not compatible
query I rowsort label-4173
SELECT + + 94 + - col0 / col2 AS col2 FROM tab0 AS cor0
----
59
93
94

query I rowsort
SELECT - 93 * col1 AS col2 FROM tab0 AS cor0
----
-7998
-8463
-9021

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4175
SELECT DISTINCT + CAST( + col0 AS SIGNED ) * col2 AS col1 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-4175
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) * col2 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL - cor0.col1 AS col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL + col1 * 50 * + col1 AS col2 FROM tab0
----
369800
414050
470450

query I rowsort
SELECT DISTINCT - 24 AS col2 FROM tab2 AS cor0
----
-24

query I rowsort
SELECT cor1.col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-4180
SELECT - + col1 + - col0 + - cor0.col0 DIV - cor0.col1 AS col0 FROM tab0 cor0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-4180
SELECT - + col1 + - col0 + - cor0.col0 / - cor0.col1 AS col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT + col0 + + ( - 2 ) FROM tab0 AS cor0
----
22
33
87

query I rowsort
SELECT ALL - cor0.col1 + 16 AS col2 FROM tab2 AS cor0
----
-1
-15
-43

skipif mysql # not compatible
query I rowsort
SELECT + col0 + CAST ( ( + col2 ) * ( - col2 ) AS REAL ) FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT DISTINCT col0 + - col2 + + col2 AS col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL ( - tab0.col2 ) + 65 FROM tab0
----
-17
32
64

query I rowsort
SELECT + 27 * + col0 AS col2 FROM tab1
----
1728
2160
81

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 cor2
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

onlyif mysql # use DIV operator for integer division
query I rowsort label-4188
SELECT DISTINCT + col0 * col2 DIV 77 AS col2 FROM tab0
----
0
10
94

skipif mysql # not compatible
query I rowsort label-4188
SELECT DISTINCT + col0 * col2 / 77 AS col2 FROM tab0
----
0
10
94

query I rowsort
SELECT DISTINCT - 83 + + col1 FROM tab1 AS cor0
----
-57
-70
-73

query I rowsort
SELECT ALL - ( col1 ) + col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 * col0 + + col1 - col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + 49 AS col2 FROM tab1 AS cor0
----
49
49
49

query I rowsort
SELECT DISTINCT col1 * + 30 FROM tab1 AS cor0
----
300
390
780

query I rowsort
SELECT DISTINCT col0 * + 2 + - col2 + cor0.col0 FROM tab0 AS cor0
----
104
185
39

query I rowsort
SELECT ALL - 90 * col1 + col2 FROM tab2 AS cor0
----
-1492
-2763
-5284

onlyif mysql # use DIV operator for integer division
query I rowsort label-4196
SELECT + col2 DIV 73 + + col2 - + col1 * col0 FROM tab1 AS cor0
----
-24
-583
-943

skipif mysql # not compatible
query I rowsort label-4196
SELECT + col2 / 73 + + col2 - + col1 * col0 FROM tab1 AS cor0
----
-24
-583
-943

query I rowsort
SELECT ALL 52 * col0 FROM tab2 cor0
----
364
4056
4108

query I rowsort
SELECT ( - col1 ) * + col0 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4199
SELECT + - CAST( NULL AS SIGNED ) + - col2 * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4199
SELECT + - CAST ( NULL AS INTEGER ) + - col2 * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * 3 + + col0 * 48 * + ( col1 + + 68 ) FROM tab1 AS cor0
----
13614
239646
311079

query I rowsort
SELECT - - 74 AS col0 FROM tab1 AS cor0
----
74
74
74

query I rowsort
SELECT + col2 * 42 AS col0 FROM tab2
----
1092
1134
1596

query I rowsort
SELECT + - 74 + cor0.col1 * col1 + col0 FROM tab2 AS cor0
----
294
3485
894

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4204
SELECT DISTINCT - col2 + col0 * + col0 + - CAST( - col0 AS SIGNED ) FROM tab0
----
1259
567
7928

skipif mysql # not compatible
query I rowsort label-4204
SELECT DISTINCT - col2 + col0 * + col0 + - CAST ( - col0 AS INTEGER ) FROM tab0
----
1259
567
7928

query I rowsort
SELECT DISTINCT tab0.col2 FROM tab0, tab2 AS cor0, tab1, tab1 AS cor1
----
1
33
82

query I rowsort
SELECT - ( 89 * col1 ) FROM tab2
----
-1513
-2759
-5251

query I rowsort
SELECT - + 91 FROM tab2 AS cor0
----
-91
-91
-91

query I rowsort
SELECT 0 * + ( tab2.col1 ) + 21 FROM tab2
----
21
21
21

query I rowsort
SELECT DISTINCT col0 * - col2 - col0 * + col1 AS col2 FROM tab1 cor0
----
-240
-4288
-8720

onlyif mysql # use DIV operator for integer division
query I rowsort label-4210
SELECT + 60 DIV - col1 AS col0 FROM tab1
----
-2
-4
-6

skipif mysql # not compatible
query I rowsort label-4210
SELECT + 60 / - col1 AS col0 FROM tab1
----
-2
-4
-6

query I rowsort
SELECT - - 54 AS col1 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT + 66 AS col2 FROM tab0 cor0
----
66
66
66

query I rowsort
SELECT col2 - - 85 FROM tab2 AS cor0
----
111
112
123

query I rowsort
SELECT DISTINCT 14 * + 0 FROM tab1, tab2 AS cor0
----
0

query I rowsort
SELECT col2 * 58 + col0 FROM tab1 AS cor0
----
3135
3370
5648

query I rowsort
SELECT DISTINCT col1 - + col1 * - 96 FROM tab2 AS cor0
----
1649
3007
5723

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4217
SELECT ALL col1 * CAST( col1 AS SIGNED ) + col1 + col1 FROM tab0 AS cor0
----
7568
8463
9603

skipif mysql # not compatible
query I rowsort label-4217
SELECT ALL col1 * CAST ( col1 AS INTEGER ) + col1 + col1 FROM tab0 AS cor0
----
7568
8463
9603

query I rowsort
SELECT + cor0.col2 + - 46 FROM tab2 AS cor0
----
-19
-20
-8

query I rowsort
SELECT - ( + col0 ) + col0 * + tab0.col2 AS col2 FROM tab0
----
0
7209
768

query I rowsort
SELECT DISTINCT 30 * - col2 * col1 AS col2 FROM tab2 AS cor0
----
-19380
-25110
-46020

query I rowsort
SELECT DISTINCT - 32 * - col1 + col0 * cor0.col0 + + col0 * - col1 AS col2 FROM tab1 AS cor0
----
3776
5776
763

query I rowsort
SELECT ALL - ( + col0 ) + - cor0.col2 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT ALL col2 * - col1 + - 15 * - col0 * - col1 AS col2 FROM tab1 AS cor0
----
-10170
-16848
-2574

query I rowsort
SELECT ALL 20 FROM tab2, tab1 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4225
SELECT DISTINCT 47 DIV + col2 AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-4225
SELECT DISTINCT 47 / + col2 AS col2 FROM tab1
----
0

query I rowsort
SELECT ALL - col2 * tab0.col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT - 24 + 39 FROM tab2
----
15
15
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-4228
SELECT - ( 11 ) DIV tab0.col0 + + tab0.col2 * 33 AS col0 FROM tab0
----
1089
2706
33

skipif mysql # not compatible
query I rowsort label-4228
SELECT - ( 11 ) / tab0.col0 + + tab0.col2 * 33 AS col0 FROM tab0
----
1089
2706
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4229
SELECT - tab2.col1 + col2 * + CAST( NULL AS SIGNED ) * + col0 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4229
SELECT - tab2.col1 + col2 * + CAST ( NULL AS INTEGER ) * + col0 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 69 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4231
SELECT + cor0.col1 DIV col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-4231
SELECT + cor0.col1 / col2 AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT + - col1 * - col2 + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL col0 + col1 * col2 + col1 AS col0 FROM tab0 AS cor0
----
229
2948
7642

onlyif mysql # use DIV operator for integer division
query I rowsort label-4234
SELECT + cor0.col1 DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4234
SELECT + cor0.col1 / col0 AS col0 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 87 * + col2 col1 FROM tab2 AS cor0
----
-2262
-2349
-3306

query I rowsort
SELECT DISTINCT - + ( - cor0.col2 ) * ( col0 ) + col2 + cor0.col2 FROM tab1 AS cor0
----
270
3762
7872

query I rowsort
SELECT ALL + col0 * - col1 + - ( col2 ) AS col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT + col0 - + col0 * - 51 AS col1 FROM tab2
----
364
4056
4108

onlyif mysql # use DIV operator for integer division
query I rowsort label-4239
SELECT ALL col1 + col0 DIV col1 FROM tab2
----
21
31
60

skipif mysql # not compatible
query I rowsort label-4239
SELECT ALL col1 + col0 / col1 FROM tab2
----
21
31
60

query I rowsort
SELECT + col1 * 74 FROM tab0 AS cor0
----
6364
6734
7178

query I rowsort
SELECT - col2 * + cor0.col0 + - 61 * - col2 FROM tab0 AS cor0
----
-2296
1221
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col2 col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + - col0 + + ( + col0 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + + cor0.col2 + - 66 FROM tab0 AS cor0
----
-33
-65
16

query I rowsort
SELECT DISTINCT 33 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
33

query I rowsort
SELECT DISTINCT - col0 + 72 AS col0 FROM tab1
----
-8
69
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4247
SELECT CAST( col1 AS SIGNED ) * col0 + - 92 FROM tab1 AS cor0
----
-14
548
948

skipif mysql # not compatible
query I rowsort label-4247
SELECT CAST ( col1 AS INTEGER ) * col0 + - 92 FROM tab1 AS cor0
----
-14
548
948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4248
SELECT DISTINCT - CAST( NULL AS SIGNED ) - + col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4248
SELECT DISTINCT - CAST ( NULL AS INTEGER ) - + col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 76 - + col1 FROM tab0 AS cor0
----
-10
-15
-21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col0 * - col2 ) col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col2 - + col1 * - col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL col1 + 86 * - col0 AS col1 FROM tab0 cor0
----
-1978
-2913
-7563

onlyif mysql # use DIV operator for integer division
query I rowsort label-4253
SELECT DISTINCT + - 77 + 73 DIV cor0.col0 + col2 AS col0 FROM tab1 AS cor0
----
-19
1
19

skipif mysql # not compatible
query I rowsort label-4253
SELECT DISTINCT + - 77 + 73 / cor0.col0 + col2 AS col0 FROM tab1 AS cor0
----
-19
1
19

query I rowsort
SELECT DISTINCT 62 * col1 FROM tab0 AS cor0
----
5332
5642
6014

query I rowsort
SELECT DISTINCT + ( + 60 ) + + col0 FROM tab2 AS cor0
----
138
139
67

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 cor0 CROSS JOIN tab1 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * tab0.col0 col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL ( + 69 ) * col0 FROM tab1
----
207
4416
5520

query I rowsort
SELECT - ( - 37 ) AS col0 FROM tab1 AS cor0
----
37
37
37

query I rowsort
SELECT DISTINCT + col1 * - col1 - - col0 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT ALL - - 49 AS col0 FROM tab1 AS cor0
----
49
49
49

query I rowsort
SELECT col0 * 36 + cor0.col1 AS col0 FROM tab0 AS cor0
----
1357
3295
950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4263
SELECT - CAST( NULL AS SIGNED ) * col1 / + col2 + - col1 * 44 col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4263
SELECT - CAST ( NULL AS INTEGER ) * col1 / + col2 + - col1 * 44 col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + + col0 * col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT ALL + + 77 + + col1 FROM tab2 AS cor0
----
108
136
94

query I rowsort
SELECT DISTINCT + + 95 * col1 + - col0 AS col1 FROM tab1 cor0
----
1155
2467
886

skipif mysql # not compatible
query I rowsort
SELECT ALL - 73 * 74 - - col2 * CAST ( - 49 AS REAL ) AS col1 FROM tab1 AS cor0
----
-10106
-8048
-8195

query I rowsort
SELECT DISTINCT + col0 + - 96 * - col0 AS col0 FROM tab1 cor0
----
291
6208
7760

query I rowsort
SELECT + - col2 * - col0 + - 36 AS col2 FROM tab2 AS cor0
----
153
1992
2966

onlyif mysql # use DIV operator for integer division
query I rowsort label-4270
SELECT DISTINCT + - col1 DIV - col0 - col2 FROM tab2 AS cor0
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-4270
SELECT DISTINCT + - col1 / - col0 - col2 FROM tab2 AS cor0
----
-23
-26
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 23 col2 FROM tab2 AS cor0
----
23
23
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col1 + col0 col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT ( + 37 ) FROM tab2, tab2 AS cor0, tab0 cor1
----
37

query I rowsort
SELECT - 85 * col2 AS col0 FROM tab2 cor0
----
-2210
-2295
-3230

query I rowsort
SELECT - + col2 - 25 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
1543
1904
21

query I rowsort
SELECT DISTINCT - + cor0.col1 * - ( - ( - col1 ) ) + + col2 * - col0 AS col0 FROM tab0 AS cor0
----
6604
9374
983

query I rowsort
SELECT col1 * + ( - col2 ) FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 col0 FROM tab1, tab0 cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

query I rowsort
SELECT - - col0 + + ( + 97 + col1 ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
16821
4416
6825

query I rowsort
SELECT ALL + col1 * 36 + - col1 FROM tab0 cor0
----
3010
3185
3395

query I rowsort
SELECT + col2 + 76 - + col0 * - col2 FROM tab0 AS cor0
----
112
7456
901

query I rowsort
SELECT + - cor0.col1 * 38 - - col0 FROM tab0 AS cor0
----
-3244
-3369
-3651

query I rowsort
SELECT + + 96 + + col0 + - col0 FROM tab0 AS cor0
----
96
96
96

query I rowsort
SELECT col0 + - ( 10 ) + + col2 FROM tab1
----
111
166
47

query I rowsort
SELECT - col2 * 23 + col0 AS col0 FROM tab1
----
-1239
-1247
-2128

onlyif mysql # use DIV operator for integer division
query I rowsort label-4286
SELECT tab1.col1 DIV col0 + + col1 + + col0 * - 26 FROM tab1
----
-1654
-2067
-44

skipif mysql # not compatible
query I rowsort label-4286
SELECT tab1.col1 / col0 + + col1 + + col0 * - 26 FROM tab1
----
-1654
-2067
-44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4287
SELECT col1 + - CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4287
SELECT col1 + - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + ( col0 ) + + col0 * 8 FROM tab1
----
-27
519
624

query I rowsort
SELECT ALL 82 * cor0.col2 * cor0.col0 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to f38380d7880e63134eca122830d1abd6

query I rowsort
SELECT - cor0.col2 * col2 + + ( - col0 ) * - 23 AS col0 FROM tab0 AS cor0
----
-4677
-537
804

query I rowsort
SELECT ALL col0 * col2 * - col0 + - tab0.col2 FROM tab0
----
-1226
-19041
-649604

query I rowsort
SELECT col1 - - ( tab2.col0 ) AS col0 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL - col0 * + col0 + col0 AS col2 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT ALL col1 + - col2 * - 84 * - col2 AS col0 FROM tab0
----
-564725
-91390
13

query I rowsort
SELECT ALL - 3 FROM tab2, tab1 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + 52 col0 FROM tab2
----
364
4056
4108

query I rowsort
SELECT - - col1 + + cor0.col2 FROM tab0 cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort
SELECT + cor0.col0 + + CAST ( col1 AS REAL ) + + col1 AS col1 FROM tab2 cor0
----
113
196
69

query I rowsort
SELECT - ( + cor0.col0 ) FROM tab1, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT - 33 * + col1 AS col0 FROM tab2
----
-1023
-1947
-561

query I rowsort
SELECT ALL + 93 AS col2 FROM tab0
----
93
93
93

query I rowsort
SELECT ALL - ( 65 ) FROM tab1
----
-65
-65
-65

query I rowsort
SELECT + 27 * + cor0.col1 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 098e9cb5f58dfd24b8b1b40ed212b109

query I rowsort
SELECT ALL - 16 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

query I rowsort
SELECT DISTINCT - + col1 * col0 + + col0 + - 64 AS col2 FROM tab1 AS cor0
----
-1024
-139
-640

query I rowsort
SELECT col0 + + 89 FROM tab2 AS cor0
----
167
168
96

query I rowsort
SELECT + col0 * col0 - + col1 FROM tab2 AS cor0
----
18
6025
6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-4308
SELECT - cor0.col1 + col2 DIV 42 FROM tab1 AS cor0
----
-11
-25
-9

skipif mysql # not compatible
query I rowsort label-4308
SELECT - cor0.col1 + col2 / 42 FROM tab1 AS cor0
----
-11
-25
-9

query I rowsort
SELECT + 4 * + col1 + col0 FROM tab2 AS cor0
----
131
147
314

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 * col2 + ( cor0.col0 + col1 ) col1 FROM tab1 AS cor0
----
4241
4520
7581

query I rowsort
SELECT + col2 * cor0.col0 + + ( col0 + col0 * ( + col1 ) ) FROM tab0 AS cor0
----
15486
2880
3465

query I rowsort
SELECT + 54 + - tab0.col1 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 2b09ee3d471bb888531b26267d798ad9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4313
SELECT + col2 DIV + col2 + 20 FROM tab0 AS cor0
----
21
21
21

skipif mysql # not compatible
query I rowsort label-4313
SELECT + col2 / + col2 + 20 FROM tab0 AS cor0
----
21
21
21

query I rowsort
SELECT + col2 * col2 - - 96 FROM tab1 AS cor0
----
3012
3345
9312

query I rowsort
SELECT + col0 + col0 * + cor0.col0 * - col2 FROM tab2 AS cor0
----
-1316
-158106
-237079

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col2 + - 51 col2 FROM tab1
----
111
3597
7629

query I rowsort
SELECT col0 + + col1 - - col1 AS col0 FROM tab1
----
106
55
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-4318
SELECT ALL col2 DIV - col1 - - col2 * tab0.col0 AS col1 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-4318
SELECT ALL col2 / - col1 - - col2 * tab0.col0 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL - 71 * col1 * col0 FROM tab1 cor0
----
-45440
-5538
-73840

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 ALL - 26 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4e49eac022daeae6f88f610644ba3754

query I rowsort
SELECT DISTINCT + 49 + - col1 * - 41 FROM tab2 AS cor0
----
1320
2468
746

query I rowsort
SELECT - - 18 * col1 AS col2 FROM tab1 AS cor0
----
180
234
468

query I rowsort
SELECT + col2 + + 9 FROM tab1 AS cor0
----
105
63
66

query I rowsort
SELECT - cor0.col1 * ( - col1 ) AS col0 FROM tab1 cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-4326
SELECT ALL - col2 DIV 31 FROM tab1 AS cor0
----
-1
-1
-3

skipif mysql # not compatible
query I rowsort label-4326
SELECT ALL - col2 / 31 FROM tab1 AS cor0
----
-1
-1
-3

query I rowsort
SELECT - col0 * cor0.col2 + + 25 AS col0 FROM tab2 AS cor0
----
-164
-2003
-2977

query I rowsort
SELECT - cor0.col2 + + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 - 34 FROM tab1 AS cor0
----
-130
-88
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - cor0.col2 col1 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4331
SELECT col0 * CAST( 59 AS SIGNED ) * col0 - col0 AS col0 FROM tab2 AS cor0
----
2884
358878
368140

skipif mysql # not compatible
query I rowsort label-4331
SELECT col0 * CAST ( 59 AS INTEGER ) * col0 - col0 AS col0 FROM tab2 AS cor0
----
2884
358878
368140

query I rowsort
SELECT DISTINCT + 79 FROM tab0, tab1, tab2 cor0
----
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4333
SELECT DISTINCT - col0 DIV + cor0.col0 - + col2 FROM tab1 cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-4333
SELECT DISTINCT - col0 / + cor0.col0 - + col2 FROM tab1 cor0
----
-55
-58
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 89 col0 FROM tab0
----
89
89
89

query I rowsort
SELECT - col0 * ( col1 ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT 49 * 24 * col1 FROM tab0 AS cor0
----
101136
107016
114072

query I rowsort
SELECT DISTINCT + col0 + 17 AS col0 FROM tab0 AS cor0
----
106
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 15 * col2 + + cor0.col2 * + cor0.col0 col1 FROM tab1 AS cor0
----
4503
9120
972

query I rowsort
SELECT ALL ( col1 ) * cor0.col1 + + 89 AS col1 FROM tab2 AS cor0
----
1050
3570
378

query I rowsort
SELECT ALL + ( + col2 ) + cor0.col2 * 45 AS col1 FROM tab1 AS cor0
----
2484
2622
4416

query I rowsort
SELECT + col2 * col2 * + col2 AS col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT + + 20 * 67 FROM tab1 AS cor0
----
1340
1340
1340

onlyif mysql # use DIV operator for integer division
query I rowsort label-4343
SELECT DISTINCT - 31 DIV 88 FROM tab1, tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4343
SELECT DISTINCT - 31 / 88 FROM tab1, tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4344
SELECT - - CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4344
SELECT - - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4345
SELECT ALL + CAST( NULL AS SIGNED ) * 97 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4345
SELECT ALL + CAST ( NULL AS INTEGER ) * 97 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 56 * + col2 AS col1 FROM tab0 AS cor0
----
-1848
-4592
-56

query I rowsort
SELECT ALL + col1 * 41 AS col0 FROM tab0
----
3526
3731
3977

onlyif mysql # use DIV operator for integer division
query I rowsort label-4348
SELECT ALL + col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4348
SELECT ALL + col0 / + col0 AS col0 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4349
SELECT + - CAST( NULL AS DECIMAL ) * - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4349
SELECT + - CAST ( NULL AS REAL ) * - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 29 * - 66 AS col2 FROM tab2
----
-1914
-1914
-1914

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4351
SELECT DISTINCT + CAST( 28 AS SIGNED ) FROM tab1, tab0 cor0 CROSS JOIN tab2, tab2 cor1, tab2 AS cor2
----
28

skipif mysql # not compatible
query I rowsort label-4351
SELECT DISTINCT + CAST ( 28 AS INTEGER ) FROM tab1, tab0 cor0 CROSS JOIN tab2, tab2 cor1, tab2 AS cor2
----
28

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-4353
SELECT ALL - + col1 DIV - col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-4353
SELECT ALL - + col1 / - col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 67 + + 1 col1 FROM tab2 AS cor0
----
-1741
-1808
-2545

query I rowsort
SELECT DISTINCT + - col2 + col2 AS col2 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL col2 + 54 FROM tab1 AS cor0
----
108
111
150

query I rowsort
SELECT DISTINCT + + col2 * - 82 * 19 + - col2 AS col1 FROM tab0 AS cor0
----
-127838
-1559
-51447

query I rowsort
SELECT ALL + cor0.col1 * + col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4359
SELECT - col0 DIV - col0 + - col1 + col0 AS col2 FROM tab0 AS cor0
----
-1
-61
-61

skipif mysql # not compatible
query I rowsort label-4359
SELECT - col0 / - col0 + - col1 + col0 AS col2 FROM tab0 AS cor0
----
-1
-61
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-4360
SELECT col0 DIV CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-4360
SELECT col0 / CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT ALL - + cor0.col2 * + cor0.col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - col0 * col0 + col2 AS col2 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + 23 col1 FROM tab0 AS cor0
----
1978
2093
2231

onlyif mysql # use DIV operator for integer division
query I rowsort label-4364
SELECT + col1 * - col0 + - col0 DIV col2 + col1 AS col1 FROM tab0 AS cor0
----
-1978
-3333
-8009

skipif mysql # not compatible
query I rowsort label-4364
SELECT + col1 * - col0 + - col0 / col2 + col1 AS col1 FROM tab0 AS cor0
----
-1978
-3333
-8009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4365
SELECT DISTINCT - col2 * CAST( NULL AS SIGNED ) + ( col1 ) + col1 / cor0.col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4365
SELECT DISTINCT - col2 * CAST ( NULL AS INTEGER ) + ( col1 ) + col1 / cor0.col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 + col2 + ( - col2 * col0 ) FROM tab1
----
-3581
-7571
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col0 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT cor0.col1 * ( cor0.col1 ) + + col0 * - col0 AS col2 FROM tab1 AS cor0
----
-3996
-6231
667

query I rowsort
SELECT + + col2 + 53 FROM tab1 AS cor0
----
107
110
149

query I rowsort
SELECT ALL - tab0.col1 * 47 AS col0 FROM tab0
----
-4042
-4277
-4559

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4371
SELECT DISTINCT - - col1 / + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4371
SELECT DISTINCT - - col1 / + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4372
SELECT ALL col1 DIV + col1 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4372
SELECT ALL col1 / + col1 AS col2 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 57 - cor0.col1 col0 FROM tab2 AS cor0
----
-2
26
40

query I rowsort
SELECT - col0 * + col1 - 21 AS col2 FROM tab0 AS cor0
----
-2085
-3416
-8120

query I rowsort
SELECT - + ( + cor0.col2 ) * - 66 - - col2 FROM tab2 AS cor0
----
1742
1809
2546

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4376
SELECT + + ( col0 ) - + CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4376
SELECT + + ( col0 ) - + CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4377
SELECT - col0 * - col1 + + col2 DIV cor0.col1 AS col2 FROM tab2 AS cor0
----
1345
217
4602

skipif mysql # not compatible
query I rowsort label-4377
SELECT - col0 * - col1 + + col2 / cor0.col1 AS col2 FROM tab2 AS cor0
----
1345
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4378
SELECT ALL - CAST( NULL AS SIGNED ) * - 8 - + col2 col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4378
SELECT ALL - CAST ( NULL AS INTEGER ) * - 8 - + col2 col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( 81 ) * - col1 - + col1 * - ( col2 * - col2 ) FROM tab0
----
-100620
-619255
-7954

query I rowsort
SELECT - cor0.col0 AS col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 84 + - col2 col1 FROM tab2
----
46
57
58

query I rowsort
SELECT 62 + col0 + - 32 AS col2 FROM tab0
----
119
54
65

query I rowsort
SELECT DISTINCT + col0 + + col1 * + col0 * col0 AS col0 FROM tab0
----
118860
49560
720900

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 11 + col2 col1 FROM tab2
----
37
38
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4385
SELECT + col0 * tab0.col0 + + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4385
SELECT + col0 * tab0.col0 + + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 38 + col2 FROM tab2 AS cor0
----
-11
-12
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4387
SELECT ALL + col0 * col2 + CAST( NULL AS SIGNED ) * + col1 + - cor0.col0 / col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4387
SELECT ALL + col0 * col2 + CAST ( NULL AS INTEGER ) * + col1 + - cor0.col0 / col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 38 * col2 * col1 FROM tab2
----
24548
31806
58292

query I rowsort
SELECT ALL col2 * + col2 * 96 + + col2 * col1 * - col2 AS col2 FROM tab0 AS cor0
----
-1
10890
33620

query I rowsort
SELECT 85 + col1 + - col0 FROM tab2 AS cor0
----
109
23
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4391
SELECT - ( col1 ) + - CAST( NULL AS SIGNED ) + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4391
SELECT - ( col1 ) + - CAST ( NULL AS INTEGER ) + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 44 AS col1 FROM tab1, tab1 cor0, tab0 cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT DISTINCT - + 44 FROM tab2 cor0
----
-44

query I rowsort
SELECT ALL - 76 * col2 + - col2 FROM tab1
----
-4158
-4389
-7392

query I rowsort
SELECT 6 + + tab1.col2 AS col0 FROM tab1
----
102
60
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4396
SELECT ALL + + col0 DIV - col2 + + col2 + - col2 * - col1 * col2 FROM tab1 cor0
----
119904
32546
75870

skipif mysql # not compatible
query I rowsort label-4396
SELECT ALL + + col0 / - col2 + + col2 + - col2 * - col1 * col2 FROM tab1 cor0
----
119904
32546
75870

query I rowsort
SELECT - ( - col0 ) + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT - ( col1 ) + + cor0.col2 * col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT + col1 - - col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT col0 * + cor0.col1 * col0 + - col2 FROM tab2 AS cor0
----
106059
1492
358930

query I rowsort
SELECT - + col2 * col1 + col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + col1 * + col1 + + col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT DISTINCT - - col1 * - col1 + - cor0.col0 * + col1 FROM tab2 AS cor0
----
-1178
-1632
-8083

onlyif mysql # use DIV operator for integer division
query I rowsort label-4404
SELECT col0 + col0 DIV + col2 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-4404
SELECT col0 + col0 / + col2 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col1 AS REAL ) * + col1 AS col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT ALL + 37 AS col2 FROM tab2
----
37
37
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-4407
SELECT DISTINCT + col2 + - col1 DIV + cor0.col0 FROM tab0 AS cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-4407
SELECT DISTINCT + col2 + - col1 / + cor0.col0 FROM tab0 AS cor0
----
-1
30
81

query I rowsort
SELECT DISTINCT + 85 * col2 + - col0 FROM tab1 cor0
----
4587
4781
8080

query I rowsort
SELECT ALL 57 * - col2 FROM tab1 AS cor0
----
-3078
-3249
-5472

query I rowsort
SELECT ALL + + 89 + col2 FROM tab0 AS cor0
----
122
171
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4411
SELECT - + cor0.col1 DIV - col0 + + cor0.col2 - col1 AS col0 FROM tab0 AS cor0
----
-50
-8
-94

skipif mysql # not compatible
query I rowsort label-4411
SELECT - + cor0.col1 / - col0 + + cor0.col2 - col1 AS col0 FROM tab0 AS cor0
----
-50
-8
-94

query I rowsort
SELECT - 62 + col2 + + col2 AS col2 FROM tab1 AS cor0
----
130
46
52

query I rowsort
SELECT ALL + + col1 - + cor0.col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT col1 * + col2 AS col2 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-4415
SELECT ALL - - cor0.col0 DIV col0 AS col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4415
SELECT ALL - - cor0.col0 / col0 AS col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + 25 + col2 * col0 FROM tab0 AS cor0
----
60
7323
817

onlyif mysql # use DIV operator for integer division
query I rowsort label-4417
SELECT ( col2 ) * col1 + col0 DIV + col2 - col1 * col2 AS col1 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4417
SELECT ( col2 ) * col1 + col0 / + col2 - col1 * col2 AS col1 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT + 70 + col2 * + col1 AS col2 FROM tab2
----
1604
716
907

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT col0 + - cor0.col2 * - col0 * + CAST ( + col0 AS REAL ) col1 FROM tab2 AS cor0
----
1330
158262
237237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) + col0 col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - - cor0.col2 + + cor0.col0 * + col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT 38 * - 52 FROM tab2, tab1 AS cor0
----
-1976

onlyif mysql # use DIV operator for integer division
query I rowsort label-4423
SELECT DISTINCT 5 DIV - col1 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-4423
SELECT DISTINCT 5 / - col1 FROM tab1
----
0

query I rowsort
SELECT - col0 + + col0 * + 1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - tab1.col1 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT col2 * 74 FROM tab0
----
2442
6068
74

query I rowsort
SELECT ALL + 36 - - ( + col2 ) FROM tab0
----
118
37
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-4428
SELECT - col0 + - ( + col2 ) DIV + col2 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-4428
SELECT - col0 + - ( + col2 ) / + col2 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT ALL + 55 FROM tab1, tab0 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4430
SELECT ALL + CAST( col2 AS SIGNED ) FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4430
SELECT ALL + CAST ( col2 AS INTEGER ) FROM tab0
----
1
33
82

query I rowsort
SELECT ALL col1 - col0 AS col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT - + 71 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 3907e0aa4f29c002120742c4abb3e23a

query I rowsort
SELECT + col2 * 69 FROM tab2 AS cor0
----
1794
1863
2622

onlyif mysql # use DIV operator for integer division
query I rowsort label-4434
SELECT + - col0 DIV cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4434
SELECT + - col0 / cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - 73 FROM tab1, tab1 cor0
----
-73

query I rowsort
SELECT + - tab1.col0 AS col2 FROM tab1, tab2, tab0 cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - + 19 * + col2 col1 FROM tab2
----
-416
-506
-643

query I rowsort
SELECT col2 + 25 * col2 FROM tab2
----
676
702
988

query I rowsort
SELECT - col0 * + ( col0 ) + + col0 AS col0 FROM tab1
----
-4032
-6
-6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4440
SELECT + col2 * CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-4440
SELECT + col2 * CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col1 * ( col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 20 * tab2.col0 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
140
1560
1580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 94 col0 FROM tab2 cor0
----
2444
2538
3572

query I rowsort
SELECT 62 * col2 AS col2 FROM tab2 AS cor0
----
1612
1674
2356

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4445
SELECT DISTINCT - CAST( NULL AS DECIMAL ) * + 18 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4445
SELECT DISTINCT - CAST ( NULL AS REAL ) * + 18 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4446
SELECT DISTINCT - ( col0 ) DIV col0 FROM tab2 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4446
SELECT DISTINCT - ( col0 ) / col0 FROM tab2 cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4447
SELECT - CAST( NULL AS SIGNED ) * + col2 + col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4447
SELECT - CAST ( NULL AS INTEGER ) * + col2 + col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 19 + - col0 * - col0 FROM tab2 AS cor0
----
6103
6260
68

query I rowsort
SELECT DISTINCT + 10 + - 62 AS col1 FROM tab1 cor0
----
-52

query I rowsort
SELECT DISTINCT + + col2 - col2 * col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL 72 + col2 FROM tab2 AS cor0
----
110
98
99

query I rowsort
SELECT + + col1 * + 76 AS col2 FROM tab1 AS cor0
----
1976
760
988

query I rowsort
SELECT DISTINCT - col2 * 41 + + col2 * - col0 FROM tab1 cor0
----
-11616
-2376
-5985

query I rowsort
SELECT ALL - - col1 * - 49 AS col2 FROM tab1 AS cor0
----
-1274
-490
-637

query I rowsort
SELECT ALL - 6 + col1 * + col2 * 75 FROM tab2 AS cor0
----
115044
48444
62769

query I rowsort
SELECT DISTINCT + - ( - col2 ) * - cor0.col1 + + col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT col1 * col1 + ( - ( col2 ) + ( col0 ) ) AS col1 FROM tab1 cor0
----
107
153
625

query I rowsort
SELECT ALL col2 + - col0 + + col1 AS col0 FROM tab0
----
63
84
95

query I rowsort
SELECT ALL - - col0 * - cor0.col1 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - - 31 * cor0.col2 AS col2 FROM tab2 cor0
----
1178
806
837

query I rowsort
SELECT col0 + col2 + 22 FROM tab1 AS cor0
----
143
198
79

query I rowsort
SELECT ALL + cor0.col2 * + col0 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - 2 + col0 FROM tab1 AS cor0
----
1
62
78

query I rowsort
SELECT cor1.col0 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to 63f734facb33901524f6f2c799118db4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4465
SELECT ALL - col1 DIV 25 FROM tab0 AS cor0
----
-3
-3
-3

skipif mysql # not compatible
query I rowsort label-4465
SELECT ALL - col1 / 25 FROM tab0 AS cor0
----
-3
-3
-3

query I rowsort
SELECT DISTINCT + col1 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 49 AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT ALL tab2.col2 * col0 + + ( tab2.col0 ) * col2 FROM tab2
----
378
4056
6004

query I rowsort
SELECT DISTINCT 18 + - col0 * - ( 24 ) AS col0 FROM tab0
----
2154
594
858

query I rowsort
SELECT DISTINCT + - col1 - col2 AS col1 FROM tab0 cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4471
SELECT - + cor0.col0 DIV - cor0.col1 + + cor0.col0 col2 FROM tab2 AS cor0
----
7
79
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4471
SELECT - + cor0.col0 / - cor0.col1 + + cor0.col0 col2 FROM tab2 AS cor0
----
7
79
83

query I rowsort
SELECT DISTINCT - 76 + + col0 * - col1 FROM tab2 AS cor0
----
-1419
-293
-4678

query I rowsort
SELECT ALL - 14 * - col1 + col0 - - col1 AS col0 FROM tab2 AS cor0
----
334
472
963

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4474
SELECT ALL + col1 + + cor0.col1 - CAST( col2 AS SIGNED ) * col1 * col0 FROM tab0 AS cor0
----
-3201
-663936
-67940

skipif mysql # not compatible
query I rowsort label-4474
SELECT ALL + col1 + + cor0.col1 - CAST ( col2 AS INTEGER ) * col1 * col0 FROM tab0 AS cor0
----
-3201
-663936
-67940

query I rowsort
SELECT DISTINCT - 83 AS col0 FROM tab1
----
-83

query I rowsort
SELECT ALL + - 25 + - col0 FROM tab0 AS cor0
----
-114
-49
-60

query I rowsort
SELECT - cor0.col1 * + col1 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT DISTINCT + 86 + col1 * + col0 + cor0.col1 FROM tab2 AS cor0
----
1446
334
4747

query I rowsort
SELECT DISTINCT col0 - 13 FROM tab2 cor0
----
-6
65
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4480
SELECT DISTINCT col0 * + cor0.col2 + + cor0.col1 DIV col1 AS col0 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-4480
SELECT DISTINCT col0 * + cor0.col2 + + cor0.col1 / col1 AS col0 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT ALL + col1 + 87 AS col0 FROM tab0 AS cor0
----
173
178
184

query I rowsort
SELECT - cor0.col2 * + col2 + - col1 * - col2 AS col1 FROM tab2 AS cor0
----
-798
108
858

query I rowsort
SELECT - - col1 * col1 * + cor0.col1 + col2 AS col1 FROM tab0 cor0
----
636089
753653
912674

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 + col0 AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + - col0 * + ( col0 ) + col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL - col1 * + col0 + col1 * + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - cor0.col0 * + ( + cor0.col0 + col2 ) FROM tab0 AS cor0
----
-1260
-1368
-15219

query I rowsort
SELECT ALL - col2 + - ( - col2 + - col1 ) AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL tab0.col2 * col0 * - tab0.col0 + 99 FROM tab0
----
-1126
-18909
-649423

query I rowsort
SELECT - cor0.col1 + 2 AS col0 FROM tab1 AS cor0
----
-11
-24
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 + + cor0.col1 col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL 5 AS col1 FROM tab2 cor0
----
5
5
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4493
SELECT - + 30 DIV - col0 FROM tab1 AS cor0
----
0
0
10

skipif mysql # not compatible
query I rowsort label-4493
SELECT - + 30 / - col0 FROM tab1 AS cor0
----
0
0
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-4494
SELECT - col1 DIV + ( col1 ) AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4494
SELECT - col1 / + ( col1 ) AS col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - + 91 * + col0 FROM tab1 AS cor0
----
-273
-5824
-7280

query I rowsort
SELECT DISTINCT + 82 + col2 FROM tab1 AS cor0
----
136
139
178

query I rowsort
SELECT ALL + col1 * + ( + cor0.col0 ) FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT 53 * - col0 AS col0 FROM tab1 cor0
----
-159
-3392
-4240

query I rowsort
SELECT DISTINCT + + 51 AS col0 FROM tab2 AS cor0
----
51

query I rowsort
SELECT DISTINCT + - ( - 25 ) AS col1 FROM tab2 AS cor0
----
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-4501
SELECT DISTINCT - col0 DIV col0 FROM tab0 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4501
SELECT DISTINCT - col0 / col0 FROM tab0 cor0
----
-1

query I rowsort
SELECT DISTINCT + col2 + + col1 * col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - ( + 61 ) + cor0.col0 AS col0 FROM tab2 AS cor0
----
-54
17
18

query I rowsort
SELECT + col1 - col2 * + 28 AS col0 FROM tab2 AS cor0
----
-1047
-669
-725

query I rowsort
SELECT 17 * col2 + col2 + - 98 FROM tab2
----
370
388
586

query I rowsort
SELECT ALL + col0 + + 90 * col1 - - col1 AS col2 FROM tab2
----
1626
2828
5447

query I rowsort
SELECT DISTINCT - 95 * - cor0.col1 * cor0.col1 FROM tab1 AS cor0
----
16055
64220
9500

query I rowsort
SELECT 97 - - cor0.col2 AS col2 FROM tab2 AS cor0
----
123
124
135

query I rowsort
SELECT + ( + col2 ) + + col1 FROM tab2
----
55
58
85

query I rowsort
SELECT 16 + + col1 FROM tab1
----
26
29
42

query I rowsort
SELECT - - 16 + cor0.col1 AS col1 FROM tab2 AS cor0
----
33
47
75

query I rowsort
SELECT + ( col1 ) * 40 FROM tab1 cor0
----
1040
400
520

query I rowsort
SELECT ALL 50 + 78 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 627d9e05796dcd941d7b712e3de8215f

query I rowsort
SELECT - tab1.col0 + col0 * + tab1.col2 AS col1 FROM tab1
----
159
3584
7600

query I rowsort
SELECT - tab2.col2 + 38 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to dfe7c495ddb399fd0b8bc29ea773d3e7

query I rowsort
SELECT + + col0 * - col0 + - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT - tab0.col2 + 67 * + 92 AS col2 FROM tab0
----
6082
6131
6163

query I rowsort
SELECT + col1 * 6 AS col0 FROM tab2
----
102
186
354

query I rowsort
SELECT ( - cor0.col1 ) AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4521
SELECT ALL 30 * col2 DIV - col1 FROM tab0
----
-11
-27
0

skipif mysql # not compatible
query I rowsort label-4521
SELECT ALL 30 * col2 / - col1 FROM tab0
----
-11
-27
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4522
SELECT - + col2 DIV - col1 AS col2 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4522
SELECT - + col2 / - col1 AS col2 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col2 AS REAL ) * col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT col1 * + 40 + col2 * tab1.col1 * col2 FROM tab1
----
120328
32890
76856

query I rowsort
SELECT + cor2.col2 * ( 8 ) + cor2.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to 2427ae74c6c147d65e8ded4b1823d22d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4526
SELECT tab2.col1 * CAST( NULL AS SIGNED ) + col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4526
SELECT tab2.col1 * CAST ( NULL AS INTEGER ) + col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col1 * col0 * + col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 41 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT col2 * ( ( + col0 ) + col2 ) * 45 AS col1 FROM tab1 AS cor0
----
138510
310365
760320

query I rowsort
SELECT DISTINCT + col2 * + cor0.col1 + col0 * + ( col0 ) * - col2 FROM tab2 AS cor0
----
-156650
-236512
-486

query I rowsort
SELECT col0 * - col2 - col2 AS col0 FROM tab0 cor0
----
-36
-7380
-825

query I rowsort
SELECT + + 27 * col2 - col0 AS col1 FROM tab2 cor0
----
624
722
947

onlyif mysql # use DIV operator for integer division
query I rowsort label-4533
SELECT DISTINCT - + col2 DIV + 56 AS col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4533
SELECT DISTINCT - + col2 / + 56 AS col2 FROM tab1 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 72 * - 30 - col2 * + col1 col1 FROM tab2 AS cor0
----
1323
1514
626

query I rowsort
SELECT 21 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT ALL col0 * + ( + col0 ) AS col1 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4537
SELECT col0 * cor0.col0 DIV 35 AS col0 FROM tab2 AS cor0
----
1
173
178

skipif mysql # not compatible
query I rowsort label-4537
SELECT col0 * cor0.col0 / 35 AS col0 FROM tab2 AS cor0
----
1
173
178

query I rowsort
SELECT + col0 * + cor0.col0 + + cor0.col2 + - col0 FROM tab1 AS cor0
----
4089
60
6416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4539
SELECT CAST( NULL AS DECIMAL ) col2 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4539
SELECT CAST ( NULL AS REAL ) col2 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT col0 * - col2 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + cor0.col0 * 15 AS col0 FROM tab2 cor0
----
105
1170
1185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - 2 col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL + col0 * col1 + 72 * col0 FROM tab2 cor0
----
10218
7031
721

query I rowsort
SELECT ALL + col2 * + col2 + - 65 * - col1 AS col2 FROM tab1
----
10061
3899
4606

query I rowsort
SELECT + tab2.col2 + 25 FROM tab2, tab1 AS cor0
----
9 values hashing to 525c3cf41519d9f98c4173cf35ea24ba

query I rowsort
SELECT ALL - col0 * + ( + col1 ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT 70 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

onlyif mysql # use DIV operator for integer division
query I rowsort label-4548
SELECT DISTINCT col0 DIV + col2 AS col0 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-4548
SELECT DISTINCT col0 / + col2 AS col0 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT - col0 * col1 * - col1 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-4550
SELECT + col0 * + col2 + + 82 DIV + tab0.col0 FROM tab0
----
37
7298
795

skipif mysql # not compatible
query I rowsort label-4550
SELECT + col0 * + col2 + + 82 / + tab0.col0 FROM tab0
----
37
7298
795

query I rowsort
SELECT DISTINCT col0 * col2 + + col2 + 82 * + tab0.col1 FROM tab0
----
14842
7877
7990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4552
SELECT DISTINCT - col1 / + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4552
SELECT DISTINCT - col1 / + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT + col1 + - 57 * col2 * - col1 FROM tab0
----
161852
425425
5626

onlyif mysql # use DIV operator for integer division
query I rowsort label-4554
SELECT - col1 * - col0 - - col2 DIV - col0 FROM tab1
----
1039
60
640

skipif mysql # not compatible
query I rowsort label-4554
SELECT - col1 * - col0 - - col2 / - col0 FROM tab1
----
1039
60
640

query I rowsort
SELECT col0 + 60 AS col1 FROM tab1
----
124
140
63

query I rowsort
SELECT ALL + col1 + + 39 FROM tab1 AS cor0
----
49
52
65

query I rowsort
SELECT DISTINCT col1 * 91 * col0 FROM tab0 cor0
----
187824
308945
737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 + col0 col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT - 29 * col0 AS col0 FROM tab0
----
-1015
-2581
-696

query I rowsort
SELECT DISTINCT 48 AS col0 FROM tab2
----
48

query I rowsort
SELECT - col1 + - col2 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL + col1 * - col2 + - col0 AS col2 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT + + 61 + col1 FROM tab2 AS cor0
----
120
78
92

query I rowsort
SELECT ALL - 83 - + col2 FROM tab0
----
-116
-165
-84

query I rowsort
SELECT 4 + col0 * - col0 FROM tab0 AS cor0
----
-1221
-572
-7917

query I rowsort
SELECT tab0.col0 * col2 * col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT ALL col0 * tab1.col0 - col2 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT ALL - col2 * + col0 + - 91 AS col1 FROM tab2
----
-2119
-280
-3093

query I rowsort
SELECT + col0 * col0 + cor0.col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT ALL ( col2 ) * 22 + - col0 + - col1 FROM tab0 AS cor0
----
-110
1624
616

query I rowsort
SELECT ALL + col0 + col2 AS col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL 32 * col1 * - 63 + col0 FROM tab2 AS cor0
----
-118866
-34193
-62489

query I rowsort
SELECT DISTINCT - 8 + col2 FROM tab2 AS cor0
----
18
19
30

query I rowsort
SELECT DISTINCT 18 + col2 FROM tab2 cor0
----
44
45
56

query I rowsort
SELECT ALL - 30 * - col1 + ( - col1 ) * col1 FROM tab0 AS cor0
----
-4816
-5551
-6499

query I rowsort
SELECT DISTINCT - ( + col2 ) + + 10 * + col0 AS col2 FROM tab2 AS cor0
----
43
752
754

query I rowsort
SELECT 5 + + cor0.col1 FROM tab1 AS cor0
----
15
18
31

query I rowsort
SELECT DISTINCT ( col1 ) * + cor0.col0 + col0 * - col0 AS col0 FROM tab0 AS cor0
----
1488
178
2170

query I rowsort
SELECT DISTINCT - 63 * col0 + - col2 AS col0 FROM tab0 cor0
----
-1545
-2206
-5689

query I rowsort
SELECT + col0 + 34 + col2 * - col2 FROM tab0
----
-1031
-6601
68

query I rowsort
SELECT DISTINCT 54 FROM tab0, tab1, tab2 AS cor0, tab0 AS cor1
----
54

query I rowsort
SELECT ALL ( ( cor0.col1 ) ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT + ( + cor0.col1 ) - col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT - col2 - 78 AS col1 FROM tab2
----
-104
-105
-116

query I rowsort
SELECT DISTINCT col0 - + col0 * - col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL - - col0 * 88 * col2 AS col0 FROM tab2 AS cor0
----
16632
178464
264176

query I rowsort
SELECT ALL + - 72 - - cor0.col2 * + col0 AS col1 FROM tab2 AS cor0
----
117
1956
2930

query I rowsort
SELECT + - col0 + + 27 FROM tab0 AS cor0
----
-62
-8
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4589
SELECT DISTINCT - + CAST( + col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4589
SELECT DISTINCT - + CAST ( + col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4590
SELECT ALL - ( - ( + col0 ) ) + col0 DIV - 54 + col2 FROM tab0 AS cor0
----
170
36
57

skipif mysql # not compatible
query I rowsort label-4590
SELECT ALL - ( - ( + col0 ) ) + col0 / - 54 + col2 FROM tab0 AS cor0
----
170
36
57

query I rowsort
SELECT ALL + col1 + col0 * col0 AS col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + 69 + col1 FROM tab0 AS cor0
----
155
160
166

query I rowsort
SELECT - 10 AS col0 FROM tab2 AS cor0
----
-10
-10
-10

query I rowsort
SELECT - - 27 * + cor0.col0 * + col2 - 68 AS col2 FROM tab0 AS cor0
----
196978
21316
877

query I rowsort
SELECT - ( col0 ) * col0 - + cor0.col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL 23 * col0 FROM tab0 cor0
----
2047
552
805

query I rowsort
SELECT + 88 - 64 FROM tab2 AS cor0
----
24
24
24

query I rowsort
SELECT DISTINCT - + cor0.col1 * ( col2 ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + - 17 * - col0 + col2 * cor0.col2 + col2 * - col1 FROM tab0 AS cor0
----
-1341
499
775

query I rowsort
SELECT + ( - ( - col0 ) ) * cor0.col0 + - col2 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT ALL + + col2 + + ( - col0 * col0 ) AS col2 FROM tab0 cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL + ( - 46 ) FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 491ad1fb79fec0b5715ea54949d1aa2d

query I rowsort
SELECT DISTINCT + 53 * + col1 FROM tab2
----
1643
3127
901

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - + col0 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 68 AS col1 FROM tab1 cor0
----
-68

query I rowsort
SELECT ALL + - cor0.col2 + cor0.col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + col0 * + col2 * col1 FROM tab2 AS cor0
----
119593
51017
5828

onlyif mysql # use DIV operator for integer division
query I rowsort label-4608
SELECT ALL - 59 DIV col2 - 78 DIV + 48 AS col2 FROM tab0 AS cor0
----
-1
-2
-60

skipif mysql # not compatible
query I rowsort label-4608
SELECT ALL - 59 / col2 - 78 / + 48 AS col2 FROM tab0 AS cor0
----
-1
-2
-60

query I rowsort
SELECT + + ( cor0.col0 ) * - col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - ( col1 ) + col2 * 14 FROM tab1 AS cor0
----
1331
730
788

query I rowsort
SELECT + col0 + + col2 * col1 FROM tab0 cor0
----
132
2862
7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + cor0.col1 col0 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4613
SELECT ALL - + 76 + cor0.col0 + - col1 DIV col0 AS col0 FROM tab0 AS cor0
----
-43
-55
12

skipif mysql # not compatible
query I rowsort label-4613
SELECT ALL - + 76 + cor0.col0 + - col1 / col0 AS col0 FROM tab0 AS cor0
----
-43
-55
12

query I rowsort
SELECT DISTINCT - + col1 + cor0.col2 * 34 FROM tab1 AS cor0
----
1810
1928
3251

query I rowsort
SELECT - col0 * + ( + col0 ) * - col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT DISTINCT + - col2 + - 27 * col0 AS col2 FROM tab2 AS cor0
----
-2132
-216
-2171

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 * - 0 * - cor0.col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - + col0 * 52 AS col0 FROM tab0 AS cor0
----
-1248
-1820
-4628

query I rowsort
SELECT DISTINCT - - col0 * + 29 AS col1 FROM tab2 AS cor0
----
203
2262
2291

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4621
SELECT cor0.col1 * CAST( + 67 + + col2 AS SIGNED ) FROM tab1 AS cor0
----
1240
2119
3146

skipif mysql # not compatible
query I rowsort label-4621
SELECT cor0.col1 * CAST ( + 67 + + col2 AS INTEGER ) FROM tab1 AS cor0
----
1240
2119
3146

query I rowsort
SELECT - col1 + ( col1 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 * col2 * cor0.col2 FROM tab2 cor0
----
22599
24548
39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4624
SELECT col1 + CAST( NULL AS SIGNED ) * + ( col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4624
SELECT col1 + CAST ( NULL AS INTEGER ) * + ( col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * 13 AS col2 FROM tab2 AS cor0
----
1014
1027
91

query I rowsort
SELECT - + 52 * col2 FROM tab1 AS cor0
----
-2808
-2964
-4992

query I rowsort
SELECT ALL - 97 FROM tab1, tab2 cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT DISTINCT - col0 + + col0 + col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + cor0.col2 * cor0.col0 + + col1 * - cor0.col2 + + col0 FROM tab0 AS cor0
----
-2022
-27
-75

query I rowsort
SELECT DISTINCT - 41 + - ( + col1 + + 88 ) FROM tab2
----
-146
-160
-188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4631
SELECT ALL + CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4631
SELECT ALL + CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - col1 * col0 * col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT col0 + - cor0.col1 + + col2 FROM tab1 cor0
----
111
163
31

query I rowsort
SELECT ALL - - cor0.col0 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + ( + cor0.col0 ) * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ( col2 ) + - col2 FROM tab0
----
0
0
0

query I rowsort
SELECT - - 34 * col2 FROM tab0 AS cor0
----
1122
2788
34

query I rowsort
SELECT + ( - col1 * - col1 ) - - ( col0 ) FROM tab2
----
3559
368
968

query I rowsort
SELECT col0 * - col1 + - col2 AS col2 FROM tab0 cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL ( - 89 ) AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 924a74d31360fa4301c953b423a4710e

query I rowsort
SELECT cor0.col1 + 75 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 0671e28986b54fbf40581e5632aa9124

onlyif mysql # use DIV operator for integer division
query I rowsort label-4642
SELECT - col1 + - col0 DIV + col0 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-4642
SELECT - col1 + - col0 / + col0 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT - + col1 - cor0.col0 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - + col2 * ( col2 ) FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT col1 + - 82 * col1 FROM tab0 cor0
----
-6966
-7371
-7857

query I rowsort
SELECT - - col1 * - 43 * + col1 AS col0 FROM tab2 AS cor0
----
-12427
-149683
-41323

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + 38 col2 FROM tab2 AS cor0
----
266
2964
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 51 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT + col1 * 70 AS col2 FROM tab1
----
1820
700
910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4650
SELECT ALL + + 90 * col0 + + col2 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4650
SELECT ALL + + 90 * col0 + + col2 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4651
SELECT ALL - CAST( col2 AS SIGNED ) * + col2 + + col2 + + 28 * - col1 FROM tab1 AS cor0
----
-3472
-3590
-9484

skipif mysql # not compatible
query I rowsort label-4651
SELECT ALL - CAST ( col2 AS INTEGER ) * + col2 + + col2 + + 28 * - col1 FROM tab1 AS cor0
----
-3472
-3590
-9484

query I rowsort
SELECT DISTINCT - + 3 * col1 FROM tab1 AS cor0
----
-30
-39
-78

query I rowsort
SELECT DISTINCT ( - col0 * col2 ) + col2 * col1 FROM tab1
----
-3078
-6432
1242

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4654
SELECT - cor0.col1 * col1 + - col0 * + CAST( NULL AS SIGNED ) * + col2 + cor0.col0 * 71 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4654
SELECT - cor0.col1 * col1 + - col0 * + CAST ( NULL AS INTEGER ) * + col2 + cor0.col0 * 71 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + col0 ) * - col0 + ( col2 ) + + col0 FROM tab1 AS cor0
----
-3975
-6224
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-4656
SELECT DISTINCT + col0 DIV + col1 + cor0.col0 FROM tab2 AS cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-4656
SELECT DISTINCT + col0 / + col1 + cor0.col0 FROM tab2 AS cor0
----
7
79
83

query I rowsort
SELECT ALL 5 FROM tab0 cor0
----
5
5
5

query I rowsort
SELECT DISTINCT + col1 * col2 * col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT - ( col0 ) * + col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + - col0 * 40 AS col0 FROM tab0 AS cor0
----
-1400
-3560
-960

query I rowsort
SELECT col0 + - col1 AS col2 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT - col2 * + cor0.col0 AS col1 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - ( + col2 ) * 1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT 3 * col1 FROM tab0
----
258
273
291

query I rowsort
SELECT ALL ( - tab1.col1 ) * + col2 + + col0 * tab1.col1 AS col2 FROM tab1
----
-1326
-208
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4666
SELECT DISTINCT - col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4666
SELECT DISTINCT - col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 * + col0 + col2 + + cor0.col2 FROM tab1 AS cor0
----
117
4210
6592

query I rowsort
SELECT ALL - col1 * + 73 + col2 FROM tab0 AS cor0
----
-6245
-6561
-7080

onlyif mysql # use DIV operator for integer division
query I rowsort label-4669
SELECT DISTINCT - col1 + - col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-4669
SELECT DISTINCT - col1 + - col0 / col0 AS col2 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT col0 * ( col0 ) - + col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT ALL + col1 * 69 AS col1 FROM tab1 AS cor0
----
1794
690
897

query I rowsort
SELECT DISTINCT cor0.col2 * col2 * + col0 + col0 AS col1 FROM tab0 AS cor0
----
26160
598525
70

query I rowsort
SELECT + col1 * + ( col1 ) AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + col1 * + col2 + col2 AS col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT ALL - col0 * tab1.col1 - col1 * tab1.col1 AS col2 FROM tab1
----
-1209
-740
-754

query I rowsort
SELECT DISTINCT tab2.col1 * - tab2.col0 - ( col2 + + col1 ) AS col1 FROM tab2
----
-1398
-275
-4687

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-4678
SELECT col2 DIV - ( 5 ) FROM tab1 AS cor0
----
-10
-11
-19

skipif mysql # not compatible
query I rowsort label-4678
SELECT col2 / - ( 5 ) FROM tab1 AS cor0
----
-10
-11
-19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4679
SELECT - cor0.col2 - CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-108
-114
-192

skipif mysql # not compatible
query I rowsort label-4679
SELECT - cor0.col2 - CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT + col1 * col0 + + col1 - col2 * + ( col2 ) AS col0 FROM tab0 AS cor0
----
1061
1466
3491

query I rowsort
SELECT + col0 * + cor0.col1 - + col1 * - cor0.col0 * - col1 FROM tab1 AS cor0
----
-12480
-1950
-5760

query I rowsort
SELECT + - cor0.col1 * + col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT cor0.col2 * + 98 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6767b7b6c83cabced588f43545cac2f8

query I rowsort
SELECT ALL - col1 * - col1 AS col2 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT + + 95 * col1 AS col1 FROM tab1 AS cor0
----
1235
2470
950

query I rowsort
SELECT DISTINCT + 47 * col1 FROM tab1 AS cor0
----
1222
470
611

onlyif mysql # use DIV operator for integer division
query I rowsort label-4687
SELECT ALL - - 86 * col0 DIV ( 59 * col0 + col2 ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4687
SELECT ALL - - 86 * col0 / ( 59 * col0 + col2 ) FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL tab2.col2 * col2 AS col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT ( col0 * 72 ) + col2 FROM tab0
----
1761
2521
6490

query I rowsort
SELECT + col1 * col0 * - col0 + 74 FROM tab2
----
-106023
-1445
-358882

onlyif mysql # use DIV operator for integer division
query I rowsort label-4691
SELECT col0 + col0 * ( col0 ) DIV col0 FROM tab0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-4691
SELECT col0 + col0 * ( col0 ) / col0 FROM tab0
----
178
48
70

query I rowsort
SELECT - + 72 + - 74 * + cor0.col2 FROM tab2 AS cor0
----
-1996
-2070
-2884

query I rowsort
SELECT ALL col2 * + 90 + col1 FROM tab1
----
4886
5140
8653

query I rowsort
SELECT ( + col2 ) * col1 + + col0 + col2 FROM tab1 cor0
----
1424
1461
691

query I rowsort
SELECT + + ( + col0 ) * + col0 + - col1 FROM tab1 cor0
----
-17
4086
6387

query I rowsort
SELECT DISTINCT col0 + + 45 FROM tab1
----
109
125
48

query I rowsort
SELECT ALL col1 * - col0 + + col1 + col2 FROM tab1
----
-573
-931
2

query I rowsort
SELECT DISTINCT col2 + 32 * - 50 FROM tab2
----
-1562
-1573
-1574

query I rowsort
SELECT col0 + - 3 + + col0 FROM tab1
----
125
157
3

query I rowsort
SELECT ALL - col0 + 0 AS col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col0 + + 97 * col1 FROM tab2
----
1728
3014
5801

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4702
SELECT + cor1.col1 + CAST( NULL AS SIGNED ) * 69 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4702
SELECT + cor1.col1 + CAST ( NULL AS INTEGER ) * 69 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - 58 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4704
SELECT ALL + col2 DIV 24 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4704
SELECT ALL + col2 / 24 AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT - - col2 + col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4706
SELECT ALL - col0 DIV - col0 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-4706
SELECT ALL - col0 / - col0 col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + + cor0.col0 + + col1 * - col2 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-4708
SELECT CAST( + col0 AS SIGNED ) DIV - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4708
SELECT CAST ( + col0 AS INTEGER ) / - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 47 + + col0 FROM tab2 AS cor0
----
125
126
54

query I rowsort
SELECT ALL ( + 52 ) + - col0 FROM tab1 AS cor0
----
-12
-28
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-4711
SELECT DISTINCT + 51 DIV col1 AS col2 FROM tab1 AS cor0
----
1
3
5

skipif mysql # not compatible
query I rowsort label-4711
SELECT DISTINCT + 51 / col1 AS col2 FROM tab1 AS cor0
----
1
3
5

query I rowsort
SELECT - - 1 + 19 FROM tab0 AS cor0
----
20
20
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4713
SELECT CAST( col1 * - col1 AS SIGNED ) FROM tab0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-4713
SELECT CAST ( col1 * - col1 AS INTEGER ) FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT - ( 59 ) * col2 AS col1 FROM tab1
----
-3186
-3363
-5664

query I rowsort
SELECT 50 * col1 AS col2 FROM tab0
----
4300
4550
4850

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + ( - col0 ) AS REAL ) AS col0 FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4717
SELECT DISTINCT + CAST( col1 AS SIGNED ) * col1 + + col1 * + cor0.col2 DIV - col2 FROM tab1 AS cor0
----
156
650
90

skipif mysql # not compatible
query I rowsort label-4717
SELECT DISTINCT + CAST ( col1 AS INTEGER ) * col1 + + col1 * + cor0.col2 / - col2 FROM tab1 AS cor0
----
156
650
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 20 col2 FROM tab1
----
-20
-20
-20

query I rowsort
SELECT - ( - col2 ) + - col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - 56 * - col1 * - col0 + col1 AS col1 FROM tab0 AS cor0
----
-115498
-190023
-453453

query I rowsort
SELECT ALL + 91 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT col1 + - 74 * - cor0.col0 - col2 * col2 FROM tab1 AS cor0
----
-2668
-3283
1497

query I rowsort
SELECT DISTINCT cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT - + col1 - 57 FROM tab1 AS cor0
----
-67
-70
-83

query I rowsort
SELECT col2 * ( col1 ) + + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - col0 * + col0 + 83 AS col0 FROM tab0 AS cor0
----
-1142
-493
-7838

query I rowsort
SELECT + col0 * ( + col1 ) * col2 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + col2 + cor0.col2 AS col1 FROM tab2 AS cor0
----
52
54
76

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-4730
SELECT ALL col1 DIV - 95 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4730
SELECT ALL col1 / - 95 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - + col0 * + col1 + + col2 * cor0.col0 * col1 FROM tab2 AS cor0
----
115050
49691
5642

query I rowsort
SELECT col1 - + col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - col0 - + col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT + + 54 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4735
SELECT cor0.col0 + ( - col0 ) * col1 + + CAST( NULL AS SIGNED ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4735
SELECT cor0.col0 + ( - col0 ) * col1 + + CAST ( NULL AS INTEGER ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col2 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - col0 + - ( col1 ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL + cor0.col0 * 86 + - 30 * cor0.col0 + 54 FROM tab1 AS cor0
----
222
3638
4534

query I rowsort
SELECT - + col0 * + ( 59 ) + + cor0.col2 + - 58 FROM tab2 AS cor0
----
-444
-4634
-4681

query I rowsort
SELECT DISTINCT - col2 * 61 * col0 AS col1 FROM tab2 AS cor0
----
-11529
-123708
-183122

query I rowsort
SELECT DISTINCT col1 * + col1 * + 62 FROM tab0
----
458552
513422
583358

query I rowsort
SELECT - tab1.col1 * - col1 * col2 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT + 46 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT - col1 * col2 * ( + 21 ) FROM tab2
----
-13566
-17577
-32214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + col2 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - tab2.col1 * + col0 * ( col1 ) FROM tab2
----
-22831
-271518
-6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col2 col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + 71 * col2 AS col2 FROM tab1 AS cor0
----
3834
4047
6816

query I rowsort
SELECT cor0.col1 * - col0 - + 88 FROM tab0 AS cor0
----
-2152
-3483
-8187

onlyif mysql # use DIV operator for integer division
query I rowsort label-4750
SELECT 83 DIV - tab1.col0 col1 FROM tab1
----
-1
-1
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4750
SELECT 83 / - tab1.col0 col1 FROM tab1
----
-1
-1
-27

query I rowsort
SELECT DISTINCT - 92 AS col0 FROM tab2, tab0 AS cor0
----
-92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4752
SELECT CAST( 97 AS SIGNED ) FROM tab1
----
97
97
97

skipif mysql # not compatible
query I rowsort label-4752
SELECT CAST ( 97 AS INTEGER ) FROM tab1
----
97
97
97

query I rowsort
SELECT DISTINCT - ( 33 * col2 ) FROM tab0
----
-1089
-2706
-33

query I rowsort
SELECT ALL + tab1.col2 + tab1.col0 * + tab1.col1 - - col0 * col0 FROM tab1
----
141
4793
7536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col0 - tab1.col2 col1 FROM tab1
----
-45
4039
6304

skipif mysql # not compatible
query I rowsort
SELECT ALL - tab0.col1 - col1 * CAST ( 75 * + col1 AS REAL ) FROM tab0
----
-554786
-621166
-705772

query I rowsort
SELECT ALL 22 - - tab1.col0 FROM tab1
----
102
25
86

query I rowsort
SELECT + - col0 * + col1 - col1 AS col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT + 75 - - 66 FROM tab2, tab0 AS cor0
----
141

query I rowsort
SELECT - 21 * col0 + 2 FROM tab0 cor0
----
-1867
-502
-733

query I rowsort
SELECT DISTINCT 3 * - col1 - ( + col1 ) * + col0 AS col1 FROM tab1
----
-1079
-156
-670

query I rowsort
SELECT DISTINCT - 45 - - col0 FROM tab2
----
-38
33
34

query I rowsort
SELECT 26 - - col2 * - col0 FROM tab0
----
-7272
-766
-9

query I rowsort
SELECT DISTINCT - + 65 * - col0 FROM tab2 AS cor0
----
455
5070
5135

query I rowsort
SELECT col0 + - col0 * ( - col2 ) AS col1 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL 9 + + col1 * - col1 * col0 + col2 FROM tab0 AS cor0
----
-177462
-329305
-736918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4767
SELECT CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4767
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 + - ( col0 ) col1 FROM tab0 cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT col1 * - col0 + 4 * + col0 + + col2 * cor0.col2 AS col2 FROM tab1 cor0
----
2850
2865
8496

query I rowsort
SELECT DISTINCT - + cor0.col1 + col1 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4771
SELECT - col2 * - CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4771
SELECT - col2 * - CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col0 + col2 col0 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT - col1 + 57 FROM tab2 AS cor0
----
-2
26
40

query I rowsort
SELECT + + col2 - + ( col0 ) * + col0 * - col2 FROM tab1 AS cor0
----
233529
540
614496

query I rowsort
SELECT ALL + col1 + + 70 * cor0.col2 AS col0 FROM tab0 AS cor0
----
167
2396
5831

query I rowsort
SELECT ALL col2 * + col0 + ( - col0 ) * cor0.col2 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4777
SELECT ALL - col1 * CAST( NULL AS SIGNED ) + - 37 * + col0 + col1 * 60 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4777
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) + - 37 * + col0 + col1 * 60 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * col2 - + col2 * col0 AS col0 FROM tab2 AS cor0
----
-1352
-1558
540

query I rowsort
SELECT ALL col1 * - col2 - - col2 * col0 AS col2 FROM tab2 AS cor0
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-4780
SELECT - col2 DIV + col0 - col0 AS col1 FROM tab1 AS cor0
----
-21
-64
-81

skipif mysql # not compatible
query I rowsort label-4780
SELECT - col2 / + col0 - col0 AS col1 FROM tab1 AS cor0
----
-21
-64
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4781
SELECT CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4781
SELECT CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 6 * col2 - - col2 AS col1 FROM tab2
----
182
189
266

query I rowsort
SELECT - 61 * - ( - col0 ) + - col1 FROM tab0
----
-1550
-2232
-5520

query I rowsort
SELECT + ( 64 ) AS col0 FROM tab1
----
64
64
64

query I rowsort
SELECT - cor1.col0 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT DISTINCT - 75 * - 50 + col0 AS col2 FROM tab2 cor0
----
3757
3828
3829

query I rowsort
SELECT ALL ( cor0.col0 ) + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + - 85 + - 37 AS col0 FROM tab2 AS cor0
----
-122
-122
-122

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col2 col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4790
SELECT - - CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4790
SELECT - - CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + 28 FROM tab2 cor0
----
-3
-31
11

query I rowsort
SELECT DISTINCT + + ( col0 ) + col1 * + col1 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT - ( - 64 ) AS col1 FROM tab2 AS cor0
----
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-4794
SELECT 55 DIV - col1 AS col0 FROM tab2 AS cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-4794
SELECT 55 / - col1 AS col0 FROM tab2 AS cor0
----
-1
-3
0

query I rowsort
SELECT DISTINCT + 59 AS col1 FROM tab2 cor0
----
59

query I rowsort
SELECT ALL + 80 + col2 AS col1 FROM tab0 AS cor0
----
113
162
81

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL - - col0 * col0 * + col1 + - cor0.col1 * col0 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
183040
4446
77440

query I rowsort
SELECT DISTINCT 36 * col0 + + cor0.col0 FROM tab2 AS cor0
----
259
2886
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - + col0 col2 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4801
SELECT ALL col2 + col2 * CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
2871
7544
98

skipif mysql # not compatible
query I rowsort label-4801
SELECT ALL col2 + col2 * CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL 85 * + col1 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-14365
-57460
-8500

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) + + col1 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT tab0.col0 - ( col1 + ( col2 ) ) AS col0 FROM tab0
----
-63
-84
-95

query I rowsort
SELECT tab2.col2 - - col1 AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL 80 * - 57 AS col0 FROM tab0
----
-4560
-4560
-4560

query I rowsort
SELECT 21 + - tab0.col0 * + col1 FROM tab0
----
-2043
-3374
-8078

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 83 col2 FROM tab2 cor0
----
-83
-83
-83

query I rowsort
SELECT - 78 AS col1 FROM tab2
----
-78
-78
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 col1 FROM tab1 AS cor0
----
72
72
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + 63 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to c526fd09f17e1f500877f5ebe067c973

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4812
SELECT DISTINCT + - ( col1 ) - + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4812
SELECT DISTINCT + - ( col1 ) - + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col0 + + tab2.col1 * col1 AS col0 FROM tab2
----
3559
368
968

query I rowsort
SELECT + col2 + 52 FROM tab0
----
134
53
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4815
SELECT - + col2 DIV - col1 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4815
SELECT - + col2 / - col1 FROM tab1 cor0
----
2
5
7

query I rowsort
SELECT ALL col2 + - col0 * - 90 AS col0 FROM tab0 AS cor0
----
2193
3151
8092

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-4818
SELECT col0 DIV 3 FROM tab0 AS cor0
----
11
29
8

skipif mysql # not compatible
query I rowsort label-4818
SELECT col0 / 3 FROM tab0 AS cor0
----
11
29
8

query I rowsort
SELECT DISTINCT - col1 + col0 * col2 FROM tab2 cor0
----
158
1969
2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4820
SELECT ALL col0 * + CAST( - col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-4820
SELECT ALL col0 * + CAST ( - col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - col1 * 41 AS col0 FROM tab1 AS cor0
----
-1066
-410
-533

query I rowsort
SELECT ALL col0 + + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT - + col1 * - col1 * + col1 + - col0 + + cor0.col0 FROM tab0 AS cor0
----
636056
753571
912673

query I rowsort
SELECT + col2 + - tab1.col2 - + col1 AS col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL col1 - - col2 AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT + col1 + - col0 * + tab0.col2 * + col1 - col1 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-4827
SELECT 29 DIV + col2 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4827
SELECT 29 / + col2 AS col1 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4828
SELECT ALL col2 * + col0 + - CAST( NULL AS SIGNED ) * - 79 / tab1.col1 - col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4828
SELECT ALL col2 * + col0 + - CAST ( NULL AS INTEGER ) * - 79 / tab1.col1 - col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4829
SELECT ( - col0 ) + CAST( NULL AS SIGNED ) * col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4829
SELECT ( - col0 ) + CAST ( NULL AS INTEGER ) * col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4830
SELECT + col0 DIV + col0 + + col0 AS col2 FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-4830
SELECT + col0 / + col0 + + col0 AS col2 FROM tab2
----
79
8
80

query I rowsort
SELECT DISTINCT + col2 + tab0.col2 AS col0 FROM tab0
----
164
2
66

query I rowsort
SELECT - col0 - 55 * col1 FROM tab1
----
-1433
-614
-795

query I rowsort
SELECT + col2 + - 40 AS col2 FROM tab2 AS cor0
----
-13
-14
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + + col0 col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT - 54 * - col0 + - cor0.col0 * + col2 FROM tab1 AS cor0
----
-192
-3360
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4836
SELECT CAST( + col2 AS SIGNED ) * col2 + + ( - col1 ) * - col2 * - col2 FROM tab0 AS cor0
----
-605160
-92565
-96

skipif mysql # not compatible
query I rowsort label-4836
SELECT CAST ( + col2 AS INTEGER ) * col2 + + ( - col1 ) * - col2 * - col2 FROM tab0 AS cor0
----
-605160
-92565
-96

query I rowsort
SELECT + tab0.col2 * + col0 * col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT 26 + 31 FROM tab1, tab2, tab2 cor0, tab0
----
81 values hashing to 23b62d6905061dab566f3a9e15667302

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4839
SELECT - col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4839
SELECT - col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 37 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT tab0.col2 * col0 * + col1 FROM tab0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-4842
SELECT DISTINCT - 1 DIV 85 AS col2 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-4842
SELECT DISTINCT - 1 / 85 AS col2 FROM tab2
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4843
SELECT + CAST( - col1 AS SIGNED ) * + tab1.col0 * + ( col1 ) AS col2 FROM tab1
----
-13520
-2028
-6400

skipif mysql # not compatible
query I rowsort label-4843
SELECT + CAST ( - col1 AS INTEGER ) * + tab1.col0 * + ( col1 ) AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT ALL - 89 FROM tab2, tab1 cor0
----
9 values hashing to 924a74d31360fa4301c953b423a4710e

query I rowsort
SELECT + ( 25 ) FROM tab2 AS cor0
----
25
25
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4846
SELECT + + 91 * 61 + - col0 + + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4846
SELECT + + 91 * 61 + - col0 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col0 * - col2 - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT - cor0.col2 * - 57 - - col2 FROM tab2 AS cor0
----
1508
1566
2204

onlyif mysql # use DIV operator for integer division
query I rowsort label-4849
SELECT ALL - ( col1 ) DIV col0 + + 52 col1 FROM tab1 cor0
----
44
52
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4849
SELECT ALL - ( col1 ) / col0 + + 52 col1 FROM tab1 cor0
----
44
52
52

skipif mysql # not compatible
query I rowsort
SELECT CAST ( 93 AS REAL ) + col0 + col1 * + col0 * + col1 AS col1 FROM tab0 AS cor0
----
177621
329443
737191

query I rowsort
SELECT 27 * 3 AS col0 FROM tab1 AS cor0
----
81
81
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4852
SELECT ALL CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4852
SELECT ALL CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL col2 * col0 + - col2 FROM tab0 cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT + 11 + + cor0.col2 - - col2 FROM tab1 AS cor0
----
119
125
203

query I rowsort
SELECT ALL + 80 + + col1 * - col0 FROM tab0 cor0
----
-1984
-3315
-8019

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 cor0.col0 * col0 + + col1 * col0 * + 20 col2 FROM tab0 AS cor0
----
169901
41856
69125

query I rowsort
SELECT + + col0 * 91 FROM tab0 cor0
----
2184
3185
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4859
SELECT + col1 DIV 97 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4859
SELECT + col1 / 97 FROM tab0
----
0
0
1

query I rowsort
SELECT ALL + 51 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT - cor0.col1 + - col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT + + cor0.col0 + + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT col2 + col2 * col0 * + col2 AS col2 FROM tab2 AS cor0
----
114114
5130
52754

query I rowsort
SELECT - col0 - cor0.col2 AS col1 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT - col0 * - col2 + col1 * col1 - - col0 AS col1 FROM tab2 AS cor0
----
1157
3370
5587

query I rowsort
SELECT - - cor0.col1 - - cor0.col1 * + col0 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL col1 * - col0 + + col0 * + col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col2 - - cor0.col1 * col1 FROM tab2 AS cor0
----
327
3507
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-4869
SELECT col0 DIV tab2.col1 col2 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4869
SELECT col0 / tab2.col1 col2 FROM tab2
----
0
1
4

query I rowsort
SELECT - cor0.col1 * - col2 + col1 * col0 AS col1 FROM tab1 cor0
----
1210
1482
2288

query I rowsort
SELECT - - col0 + + col0 * col0 AS col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT + col2 * - cor0.col0 - - cor0.col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - cor0.col1 - cor0.col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT - col2 - tab0.col0 * col0 FROM tab0
----
-1226
-609
-8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-4875
SELECT - col0 + col2 - col0 DIV col0 AS col0 FROM tab1
----
-8
15
50

skipif mysql # not compatible
query I rowsort label-4875
SELECT - col0 + col2 - col0 / col0 AS col0 FROM tab1
----
-8
15
50

query I rowsort
SELECT ALL + - col1 + col1 * col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT DISTINCT + col2 * - col1 + col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 * + col0 col2 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-4879
SELECT DISTINCT - col1 DIV col0 AS col2 FROM tab1
----
-8
0

skipif mysql # not compatible
query I rowsort label-4879
SELECT DISTINCT - col1 / col0 AS col2 FROM tab1
----
-8
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4880
SELECT ALL + col1 DIV tab2.col1 AS col2 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4880
SELECT ALL + col1 / tab2.col1 AS col2 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT tab1.col2 * + col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT col0 - col2 * col2 * - col2 AS col1 FROM tab2
----
17654
19690
54951

query I rowsort
SELECT - col2 - col2 * col1 FROM tab2
----
-1560
-684
-864

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col2 IN ( + col2 )
----

query I rowsort
SELECT + col1 - + col0 FROM tab2
----
-19
-62
24

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL IN ( + col0 )
----

query I rowsort
SELECT - col2 + col0 * col2 AS col0 FROM tab1
----
108
3591
7584

query I rowsort
SELECT DISTINCT cor0.col1 * col2 + + 32 FROM tab1 AS cor0
----
1280
1436
602

query I rowsort
SELECT ALL 26 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE + col0 * - col0 <= ( col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL NOT IN ( + col0 / + col1 + - col1 )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE ( NULL ) = col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4893
SELECT ALL + col1 DIV + col0 - col1 AS col2 FROM tab2
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-4893
SELECT ALL + col1 / + col0 - col1 AS col2 FROM tab2
----
-17
-27
-59

query I rowsort
SELECT + col2 AS col2 FROM tab2 WHERE NULL IN ( + tab2.col2 / tab2.col2 + col0 )
----

query I rowsort
SELECT DISTINCT - col0 * - col1 - col0 * tab1.col2 FROM tab1
----
-3008
-6640
-84

query I rowsort
SELECT col1 * tab0.col0 AS col0 FROM tab0 WHERE NOT NULL NOT IN ( col1 )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4897
SELECT DISTINCT col2 + + col0 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4897
SELECT DISTINCT col2 + + col0 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 * col1 + + col0 * col1 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT DISTINCT 27 * col1 + + col1 - + col0 AS col1 FROM tab0
----
2384
2459
2681

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + tab0.col0 * + 37 col2 FROM tab0
----
1330
3382
912

query I rowsort
SELECT ALL col0 * + col0 + - tab2.col0 * col0 + + col1 * 53 FROM tab2
----
1643
3127
901

query I rowsort
SELECT ALL 45 AS col0 FROM tab1
----
45
45
45

query I rowsort
SELECT DISTINCT - cor0.col1 + cor0.col1 * col2 FROM tab0 cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-4904
SELECT - + 97 + - cor0.col2 DIV col0 AS col2 FROM tab0 AS cor0
----
-97
-97
-98

skipif mysql # not compatible
query I rowsort label-4904
SELECT - + 97 + - cor0.col2 / col0 AS col2 FROM tab0 AS cor0
----
-97
-97
-98

query I rowsort
SELECT DISTINCT - - col2 * - col0 + ( + col0 * col2 ) FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL 92 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT DISTINCT + 13 FROM tab2, tab0 AS cor0, tab2 cor1, tab1 AS cor2
----
13

query I rowsort
SELECT DISTINCT col1 * col2 * col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT col2 AS col0 FROM tab1 WHERE ( col2 + col2 * + col2 ) >= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - tab2.col1 col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL col0 * - tab1.col1 * tab1.col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT tab2.col2 * - tab2.col0 AS col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT col0 * - col2 * - col2 AS col0 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT col1 * col1 * + col1 + - col0 + col0 FROM tab1
----
1000
17576
2197

query I rowsort
SELECT ALL col2 * + tab1.col2 * tab1.col1 FROM tab1
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-4916
SELECT col2 DIV + col0 + col0 AS col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-4916
SELECT col2 / + col0 + col0 AS col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT DISTINCT col0 - + col0 * col2 FROM tab0 AS cor0
----
-7209
-768
0

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 cor0 WHERE ( NULL ) <> NULL
----

query I rowsort
SELECT - col1 + - col2 * + col0 - + tab1.col0 FROM tab1
----
-191
-3722
-7773

query I rowsort
SELECT - col2 AS col2 FROM tab1 WHERE NOT ( - col1 ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL tab2.col1 - tab2.col2 AS col2 FROM tab2 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT + col2 - col2 * - col0 AS col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT tab2.col1 * - col0 + col2 AS col1 FROM tab2
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-4924
SELECT ALL col2 DIV col0 - + col1 FROM tab2
----
-17
-28
-59

skipif mysql # not compatible
query I rowsort label-4924
SELECT ALL col2 / col0 - + col1 FROM tab2
----
-17
-28
-59

query I rowsort
SELECT DISTINCT col2 - col2 AS col2 FROM tab0
----
0

query I rowsort
SELECT ALL col2 * - col0 + tab1.col2 AS col1 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT + col1 * col1 * + col0 + - col0 AS col0 FROM tab2
----
22752
271440
6720

query III rowsort
SELECT * FROM tab2 WHERE + col0 + col2 IN ( - tab2.col1 * col0 )
----

query I rowsort
SELECT DISTINCT col0 * - col2 + tab1.col2 AS col2 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - col2 * - col0 - col1 FROM tab0
----
-62
706
7207

query I rowsort
SELECT DISTINCT 57 AS col0 FROM tab0 cor0
----
57

query I rowsort
SELECT ALL + col0 + col2 * 67 AS col2 FROM tab1 AS cor0
----
3621
3883
6512

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4933
SELECT ALL CAST( - 47 AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

skipif mysql # not compatible
query I rowsort label-4933
SELECT ALL CAST ( - 47 AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

query I rowsort
SELECT - 55 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4935
SELECT ALL col2 * - CAST( NULL AS SIGNED ) + - 26 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4935
SELECT ALL col2 * - CAST ( NULL AS INTEGER ) + - 26 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 * + col2 + - col0 * - ( col1 ) * - cor0.col1 col2 FROM tab1 AS cor0
----
-12192
-5766
-621

query I rowsort
SELECT DISTINCT + + col2 + - ( - col2 ) AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - + col2 * + col0 + + col2 + col0 FROM tab0 AS cor0
----
-7127
-735
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4939
SELECT ALL - col0 DIV 96 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4939
SELECT ALL - col0 / 96 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - 76 * - cor0.col2 col2 FROM tab1 AS cor0
----
4107
4396
7376

query I rowsort
SELECT 73 AS col0 FROM tab0 cor0
----
73
73
73

query I rowsort
SELECT DISTINCT + cor0.col2 * + col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - col1 * + cor0.col1 * - col1 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT ALL + 59 * + 14 + - col2 AS col1 FROM tab0 AS cor0
----
744
793
825

query I rowsort
SELECT DISTINCT cor0.col1 * + 60 FROM tab0, tab2 AS cor0
----
1020
1860
3540

query I rowsort
SELECT + 78 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to f0487ba81d377516702723e098c02ba1

query I rowsort
SELECT DISTINCT - 38 * col2 FROM tab0 AS cor0
----
-1254
-3116
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4948
SELECT DISTINCT - + cor0.col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4948
SELECT DISTINCT - + cor0.col0 / col0 AS col2 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT ALL - + 53 + col1 FROM tab1 AS cor0
----
-27
-40
-43

query I rowsort
SELECT ALL - 52 AS col0 FROM tab0 AS cor0
----
-52
-52
-52

query I rowsort
SELECT 7 + - col0 FROM tab1 AS cor0
----
-57
-73
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4952
SELECT - - col0 - col2 DIV col1 AS col2 FROM tab1 cor0
----
1
59
73

skipif mysql # not compatible
query I rowsort label-4952
SELECT - - col0 - col2 / col1 AS col2 FROM tab1 cor0
----
1
59
73

query I rowsort
SELECT DISTINCT + 93 FROM tab1 cor0
----
93

query I rowsort
SELECT + col0 - col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL - ( + col2 ) * cor0.col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - cor0.col2 + col0 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
22
6058
6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-4957
SELECT col0 * col1 + + col2 DIV + col1 AS col2 FROM tab0 cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-4957
SELECT col0 * col1 + + col2 / + col1 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - cor0.col2 + + col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + tab0.col2 - - 14 FROM tab0
----
15
47
96

query I rowsort
SELECT + - 5 * - col2 AS col2 FROM tab1 AS cor0
----
270
285
480

query I rowsort
SELECT + col2 * - col1 * + col1 AS col2 FROM tab0 cor0
----
-244068
-679042
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + 3 col0 FROM tab1 AS cor0
----
13
16
29

query I rowsort
SELECT DISTINCT col0 - col1 AS col2 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT col0 * col2 + + col2 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-164
-2046
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4965
SELECT + - col1 DIV cor0.col1 - col1 * col0 AS col2 FROM tab0 cor0
----
-2065
-3396
-8100

skipif mysql # not compatible
query I rowsort label-4965
SELECT + - col1 / cor0.col1 - col1 * col0 AS col2 FROM tab0 cor0
----
-2065
-3396
-8100

onlyif mysql # use DIV operator for integer division
query I rowsort label-4966
SELECT ALL + + cor0.col0 * col0 DIV ( - col0 ) + col2 col2 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4966
SELECT ALL + + cor0.col0 * col0 / ( - col0 ) + col2 col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + col2 + - ( col0 ) - col1 AS col1 FROM tab0 AS cor0
----
-131
-77
-98

query I rowsort
SELECT - tab1.col2 * - col1 AS col2 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-4969
SELECT + col1 DIV - col1 AS col2 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4969
SELECT + col1 / - col1 AS col2 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT ALL + 62 * col1 FROM tab0
----
5332
5642
6014

query I rowsort
SELECT DISTINCT + tab2.col2 AS col1 FROM tab2, tab1 cor0
----
26
27
38

query I rowsort
SELECT - 36 * + col2 AS col0 FROM tab0 AS cor0
----
-1188
-2952
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-4973
SELECT + 5 + cor0.col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
6
6
6

skipif mysql # not compatible
query I rowsort label-4973
SELECT + 5 + cor0.col0 / + col0 AS col0 FROM tab0 AS cor0
----
6
6
6

query I rowsort
SELECT ALL + 91 FROM tab2, tab1 cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT - col1 + col0 * 73 FROM tab2
----
480
5635
5750

query I rowsort
SELECT DISTINCT + 54 AS col2 FROM tab2 AS cor0
----
54

query I rowsort
SELECT + 74 + - cor0.col0 FROM tab1 AS cor0
----
-6
10
71

query I rowsort
SELECT - - col2 * 55 FROM tab2 AS cor0
----
1430
1485
2090

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4979
SELECT col0 + - CAST( col1 AS SIGNED ) col0 FROM tab1
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4979
SELECT col0 + - CAST ( col1 AS INTEGER ) col0 FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT 69 FROM tab1, tab0 AS cor0
----
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-4981
SELECT + col1 DIV tab1.col0 + tab1.col0 AS col2 FROM tab1
----
11
64
80

skipif mysql # not compatible
query I rowsort label-4981
SELECT + col1 / tab1.col0 + tab1.col0 AS col2 FROM tab1
----
11
64
80

query I rowsort
SELECT 93 + - col2 AS col1 FROM tab0 AS cor0
----
11
60
92

query I rowsort
SELECT + col2 + col2 * + col2 AS col0 FROM tab2 cor0
----
1482
702
756

query I rowsort
SELECT ALL + col0 * col2 + - col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL - col1 + col1 * - col0 * - col2 FROM tab2 AS cor0
----
119593
51017
5828

query I rowsort
SELECT DISTINCT - cor0.col1 + col1 * col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT + col2 * 91 + + col1 AS col1 FROM tab2
----
2425
2488
3475

query I rowsort
SELECT - - ( - col2 ) + col1 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4989
SELECT ALL + - col0 DIV - col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4989
SELECT ALL + - col0 / - col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT - ( cor0.col1 ) * col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - + ( + cor0.col1 ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT tab1.col0 FROM tab1, tab0, tab0 AS cor0, tab2
----
3
64
80

query I rowsort
SELECT ALL 63 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

onlyif mysql # use DIV operator for integer division
query I rowsort label-4994
SELECT DISTINCT ( + col1 ) DIV + col2 + 88 * col2 + col2 AS col2 FROM tab0 cor0
----
186
2939
7299

skipif mysql # not compatible
query I rowsort label-4994
SELECT DISTINCT ( + col1 ) / + col2 + 88 * col2 + col2 AS col2 FROM tab0 cor0
----
186
2939
7299

query I rowsort
SELECT ALL ( + col0 ) + + col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT col1 + + col0 * - cor0.col1 AS col1 FROM tab0 cor0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4997
SELECT - CAST( - col0 AS SIGNED ) + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-4997
SELECT - CAST ( - col0 AS INTEGER ) + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col2 + + 73 col0 FROM tab0 AS cor0
----
108
7371
865

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4999
SELECT DISTINCT - ( col1 ) * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4999
SELECT DISTINCT - ( col1 ) * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5000
SELECT + 70 DIV + cor0.col2 + - col1 + col1 FROM tab0 AS cor0
----
0
2
70

skipif mysql # not compatible
query I rowsort label-5000
SELECT + 70 / + cor0.col2 + - col1 + col1 FROM tab0 AS cor0
----
0
2
70

query I rowsort
SELECT - 76 + col2 * col1 AS col2 FROM tab0 cor0
----
21
2762
7386

query I rowsort
SELECT ALL + 29 * + cor0.col2 FROM tab0 AS cor0
----
2378
29
957

query I rowsort
SELECT - - 80 + col2 AS col1 FROM tab2 AS cor0
----
106
107
118

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 - 11 col1 FROM tab0 AS cor0
----
1214
565
7910

onlyif mysql # use DIV operator for integer division
query I rowsort label-5005
SELECT - col1 + - col0 DIV 49 FROM tab1 AS cor0
----
-11
-14
-26

skipif mysql # not compatible
query I rowsort label-5005
SELECT - col1 + - col0 / 49 FROM tab1 AS cor0
----
-11
-14
-26

query I rowsort
SELECT + col2 * col0 + ( + cor0.col0 ) FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL + col0 + col2 AS col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + - cor0.col1 + - 96 FROM tab2 AS cor0
----
-113
-127
-155

query I rowsort
SELECT DISTINCT + tab2.col2 * col2 * + col0 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT col0 * col0 - col2 AS col1 FROM tab1
----
-45
4039
6304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 * - tab0.col2 - + col2 * col1 col0 FROM tab0
----
-14186
-3927
-98

query I rowsort
SELECT DISTINCT + col2 * + 24 FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT - + col0 * + 78 FROM tab1 AS cor0
----
-234
-4992
-6240

query I rowsort
SELECT - col0 * + col1 * 74 AS col2 FROM tab2 AS cor0
----
-16058
-340548
-99382

query I rowsort
SELECT DISTINCT + col0 + 26 FROM tab0 AS cor0
----
115
50
61

query I rowsort
SELECT ALL col2 * ( cor0.col1 * + col2 ) AS col0 FROM tab1 AS cor0
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-5017
SELECT ALL + col1 DIV 65 col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5017
SELECT ALL + col1 / 65 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - + col2 + + col0 * ( - cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-4153
-63
-6496

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 - + CAST ( - col0 * - col1 + - col2 AS REAL ) FROM tab1 AS cor0
----
-526
-848
30

query I rowsort
SELECT - + cor0.col2 * - cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col1 col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - col0 * col0 + - col1 AS col0 FROM tab0 AS cor0
----
-1322
-662
-8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-5023
SELECT ALL col0 DIV cor0.col0 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5023
SELECT ALL col0 / cor0.col0 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + - col2 * 75 AS col0 FROM tab2 AS cor0
----
-1950
-2025
-2850

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5025
SELECT + + col0 + CAST( cor0.col0 AS SIGNED ) + col0 AS col1 FROM tab0 AS cor0
----
105
267
72

skipif mysql # not compatible
query I rowsort label-5025
SELECT + + col0 + CAST ( cor0.col0 AS INTEGER ) + col0 AS col1 FROM tab0 AS cor0
----
105
267
72

query I rowsort
SELECT tab1.col2 * col1 * - 49 AS col1 FROM tab1
----
-27930
-61152
-68796

query I rowsort
SELECT DISTINCT - col2 + cor0.col0 * + 78 * + col0 FROM tab2 AS cor0
----
3795
474526
486760

query I rowsort
SELECT - cor0.col2 + + col2 * col0 + cor0.col1 FROM tab1 AS cor0
----
134
3601
7597

query I rowsort
SELECT ALL + col1 + ( 96 ) * + col2 FROM tab0 cor0
----
193
3254
7963

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 56 * + col2 + col1 col1 FROM tab1
----
204298
430093
9098

query I rowsort
SELECT + ( cor0.col0 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL + col0 * ( col1 * col0 ) AS col0 FROM tab2
----
106097
1519
358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * col0 + - cor0.col1 col2 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL + ( 85 ) AS col1 FROM tab2
----
85
85
85

query I rowsort
SELECT DISTINCT 77 * - col0 - - col1 FROM tab0
----
-1762
-2598
-6762

query I rowsort
SELECT DISTINCT + 3 * col1 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT col2 * - col1 * - col2 AS col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT ALL 17 + col2 * + col2 FROM tab0
----
1106
18
6741

query I rowsort
SELECT DISTINCT - col2 * + col0 + col0 AS col1 FROM tab2
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-5040
SELECT + col2 + col0 DIV - 43 FROM tab2
----
25
27
37

skipif mysql # not compatible
query I rowsort label-5040
SELECT + col2 + col0 / - 43 FROM tab2
----
25
27
37

query I rowsort
SELECT ALL 43 + col2 AS col1 FROM tab0
----
125
44
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 36 + col1 * col2 col1 FROM tab0
----
133
2874
7498

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - cor0.col2 col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - col1 * col0 + 1 AS col2 FROM tab2 AS cor0
----
-1342
-216
-4601

query I rowsort
SELECT DISTINCT - ( - col1 ) * + 17 + cor0.col0 FROM tab0 AS cor0
----
1486
1636
1684

query I rowsort
SELECT - + 20 FROM tab2 AS cor0
----
-20
-20
-20

query I rowsort
SELECT + - 50 + col2 FROM tab0 cor0
----
-17
-49
32

query I rowsort
SELECT DISTINCT - + col2 * - col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT 26 * - col1 + 30 + + col1 AS col2 FROM tab0 AS cor0
----
-2120
-2245
-2395

query I rowsort
SELECT cor0.col1 + col1 * ( + col0 ) + - col0 FROM tab2 AS cor0
----
1281
241
4583

onlyif mysql # use DIV operator for integer division
query I rowsort label-5051
SELECT - 24 DIV col2 + col2 * ( col0 + 91 ) * + col0 AS col0 FROM tab1 AS cor0
----
1313280
15228
565440

skipif mysql # not compatible
query I rowsort label-5051
SELECT - 24 / col2 + col2 * ( col0 + 91 ) * + col0 AS col0 FROM tab1 AS cor0
----
1313280
15228
565440

onlyif mysql # use DIV operator for integer division
query I rowsort label-5052
SELECT 8 DIV col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5052
SELECT 8 / col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + 56 * col0 + - col0 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT ALL - - cor0.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT + 18 FROM tab2, tab0 cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT DISTINCT - cor0.col0 * 54 FROM tab2, tab2 AS cor0
----
-378
-4212
-4266

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 + - col0 col2 FROM tab2
----
1264
210
4524

query I rowsort
SELECT DISTINCT + 55 AS col1 FROM tab1
----
55

query I rowsort
SELECT ALL - col1 + + 40 + - col1 AS col0 FROM tab0
----
-132
-142
-154

query I rowsort
SELECT 4 * 15 AS col1 FROM tab2
----
60
60
60

query I rowsort
SELECT ALL 27 * col0 AS col0 FROM tab1 AS cor0
----
1728
2160
81

query I rowsort
SELECT - + ( + col1 ) * col1 + - ( - col2 + + col1 ) FROM tab2 AS cor0
----
-268
-3514
-965

onlyif mysql # use DIV operator for integer division
query I rowsort label-5063
SELECT ( + col2 ) DIV - col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5063
SELECT ( + col2 ) / - col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT 98 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 6624b1f09c0594f5576803ac29f4499d

onlyif mysql # use DIV operator for integer division
query I rowsort label-5065
SELECT - col0 * col1 DIV col2 + + 8 FROM tab0 AS cor0
----
-3387
-54
-90

skipif mysql # not compatible
query I rowsort label-5065
SELECT - col0 * col1 / col2 + + 8 FROM tab0 AS cor0
----
-3387
-54
-90

query I rowsort
SELECT DISTINCT 97 * col0 + 8 FROM tab2 AS cor0
----
687
7574
7671

query I rowsort
SELECT + 87 FROM tab2
----
87
87
87

query I rowsort
SELECT ALL - col1 + - ( 41 ) FROM tab2 AS cor0
----
-100
-58
-72

query I rowsort
SELECT - + col0 * col1 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL col2 + - 78 * - col1 FROM tab2 AS cor0
----
1364
2445
4628

query I rowsort
SELECT ALL + col0 + 94 * - col1 * + col1 AS col2 FROM tab1 AS cor0
----
-15806
-63541
-9336

query I rowsort
SELECT DISTINCT - col0 * - col1 + - 7 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-104
570
949

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5073
SELECT ALL + col1 * - CAST( NULL AS SIGNED ) + col0 / - cor0.col2 + + ( col2 * col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5073
SELECT ALL + col1 * - CAST ( NULL AS INTEGER ) + col0 / - cor0.col2 + + ( col2 * col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5074
SELECT - + col1 * + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5074
SELECT - + col1 * + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + col2 AS col1 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT + - col2 * - col2 + col2 AS col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT col0 * 16 + cor0.col2 AS col1 FROM tab0 AS cor0
----
1506
417
561

query I rowsort
SELECT col0 + + col0 * + col2 AS col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + - col2 * 83 AS col1 FROM tab0 AS cor0
----
-2739
-6806
-83

query I rowsort
SELECT DISTINCT 39 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
39

query I rowsort
SELECT + col0 * + ( - cor0.col0 ) FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5082
SELECT CAST( NULL AS SIGNED ) + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5082
SELECT CAST ( NULL AS INTEGER ) + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - ( ( - col0 ) ) FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5084
SELECT CAST( 71 AS SIGNED ) * col2 * col0 FROM tab2 AS cor0
----
13419
143988
213142

skipif mysql # not compatible
query I rowsort label-5084
SELECT CAST ( 71 AS INTEGER ) * col2 * col0 FROM tab2 AS cor0
----
13419
143988
213142

query I rowsort
SELECT 85 * + col1 FROM tab2 AS cor0
----
1445
2635
5015

query I rowsort
SELECT ALL + 92 AS col0 FROM tab0 AS cor0
----
92
92
92

query I rowsort
SELECT + 22 * + col2 AS col0 FROM tab2 AS cor0
----
572
594
836

query I rowsort
SELECT DISTINCT - cor0.col0 + + col2 - - col1 FROM tab0 AS cor0
----
63
84
95

query I rowsort
SELECT + 57 * col0 FROM tab2 AS cor0
----
399
4446
4503

query I rowsort
SELECT - - col1 + - col1 * - ( col2 ) FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT ( col2 ) + - col2 * + col1 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT + ( col1 ) * + 81 AS col1 FROM tab2 cor0
----
1377
2511
4779

onlyif mysql # use DIV operator for integer division
query I rowsort label-5093
SELECT DISTINCT - 48 DIV col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5093
SELECT DISTINCT - 48 / col1 AS col1 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 91 * - col0 col0 FROM tab2
----
637
7098
7189

query I rowsort
SELECT - + col1 + col1 * col0 + - cor0.col1 FROM tab1 AS cor0
----
1014
26
620

query I rowsort
SELECT cor1.col2 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL + - cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT + 83 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

query I rowsort
SELECT DISTINCT - cor1.col2 + cor0.col2 AS col0 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
-32
-49
-81
0
32
49
81

query I rowsort
SELECT - ( col2 ) * + 81 FROM tab2
----
-2106
-2187
-3078

onlyif mysql # use DIV operator for integer division
query I rowsort label-5101
SELECT ALL 58 DIV col2 col1 FROM tab0 AS cor0
----
0
1
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5101
SELECT ALL 58 / col2 col1 FROM tab0 AS cor0
----
0
1
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col0 + col1 col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + 91 * col2 + + col1 FROM tab0 AS cor0
----
188
3089
7553

query I rowsort
SELECT ALL - - 88 FROM tab0 AS cor0
----
88
88
88

query I rowsort
SELECT - col1 * - col2 * ( col2 * + cor0.col1 ) FROM tab2 AS cor0
----
2353156
417316
700569

query I rowsort
SELECT DISTINCT col0 + col0 * col0 * + 82 AS col2 FROM tab0
----
100485
47256
649611

query I rowsort
SELECT DISTINCT - 55 * cor0.col1 FROM tab1, tab2 AS cor0
----
-1705
-3245
-935

query I rowsort
SELECT DISTINCT - cor0.col1 * - 66 FROM tab0, tab1 AS cor0, tab1 cor1
----
1716
660
858

query I rowsort
SELECT ALL + col2 * - tab1.col0 + col0 AS col0 FROM tab1
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5110
SELECT DISTINCT 19 * col1 DIV col0 FROM tab2 cor0
----
14
4
84

skipif mysql # not compatible
query I rowsort label-5110
SELECT DISTINCT 19 * col1 / col0 FROM tab2 cor0
----
14
4
84

query I rowsort
SELECT DISTINCT + - cor0.col1 + col0 AS col2 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT 46 + col1 * cor0.col1 FROM tab2 AS cor0
----
1007
335
3527

query I rowsort
SELECT DISTINCT 9 AS col0 FROM tab2 AS cor0
----
9

query I rowsort
SELECT ALL - 40 + - col0 FROM tab2 AS cor0
----
-118
-119
-47

query I rowsort
SELECT 79 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT 42 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT + - col1 + + cor0.col0 - cor0.col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - col2 + + 25 FROM tab1 cor0
----
-29
-32
-71

query I rowsort
SELECT DISTINCT col1 * + 6 + 85 * col0 AS col1 FROM tab1
----
411
5500
6878

query I rowsort
SELECT + col1 * ( col1 ) + 72 AS col0 FROM tab1 AS cor0
----
172
241
748

query I rowsort
SELECT ALL - col0 * 17 AS col2 FROM tab0 AS cor0
----
-1513
-408
-595

query I rowsort
SELECT - 71 * 63 FROM tab1 AS cor0
----
-4473
-4473
-4473

onlyif mysql # use DIV operator for integer division
query I rowsort label-5123
SELECT ALL - - col2 DIV - col0 AS col1 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-5123
SELECT ALL - - col2 / - col0 AS col1 FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT + 21 FROM tab2 cor0
----
21
21
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + 84 - col1 col1 FROM tab1 AS cor0
----
-9
10
55

query I rowsort
SELECT ALL cor0.col0 + col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - ( - col0 ) * + col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL + cor0.col1 + - ( + col1 ) * ( + col0 ) FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-5129
SELECT + col1 DIV col2 + col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-5129
SELECT + col1 / col2 + col2 FROM tab0 AS cor0
----
35
83
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5130
SELECT DISTINCT CAST( NULL AS SIGNED ) + + col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5130
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + col2 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT + cor0.col2 * + cor0.col2 - + col0 * 96 FROM tab0 AS cor0
----
-1215
-1820
-3359

query I rowsort
SELECT DISTINCT col1 * col2 + - col2 * ( + col1 * + col0 ) AS col0 FROM tab0 AS cor0
----
-3298
-65274
-656656

query I rowsort
SELECT ALL - 39 * + 34 FROM tab1 AS cor0
----
-1326
-1326
-1326

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + 19 * + col2 + - cor0.col1 col2 FROM tab2 AS cor0
----
12785
13820
27419

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-5136
SELECT - CAST( NULL AS SIGNED ) * - ( col1 ) + 11 * + 80 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5136
SELECT - CAST ( NULL AS INTEGER ) * - ( col1 ) + 11 * + 80 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 24 * - col1 - cor0.col2 AS col1 FROM tab2 cor0
----
1390
370
717

query I rowsort
SELECT + 90 * + col0 + col0 AS col1 FROM tab0 AS cor0
----
2184
3185
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5139
SELECT ALL CAST( - 87 AS SIGNED ) * col2 FROM tab0 AS cor0
----
-2871
-7134
-87

skipif mysql # not compatible
query I rowsort label-5139
SELECT ALL CAST ( - 87 AS INTEGER ) * col2 FROM tab0 AS cor0
----
-2871
-7134
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5140
SELECT + ( col0 ) + + CAST( NULL AS DECIMAL ) * + 39 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5140
SELECT + ( col0 ) + + CAST ( NULL AS REAL ) * + 39 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 - col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 20 + + col0 FROM tab2 AS cor0
----
27
98
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - col0 col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT - 82 * col1 + tab1.col1 * 59 AS col1 FROM tab1
----
-230
-299
-598

query I rowsort
SELECT DISTINCT - col0 + cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
1365
598
722

onlyif mysql # use DIV operator for integer division
query I rowsort label-5146
SELECT cor0.col0 DIV col0 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5146
SELECT cor0.col0 / col0 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT - - cor0.col0 + col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL col0 * - 2 AS col1 FROM tab0 AS cor0
----
-178
-48
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5149
SELECT ALL col0 * col0 DIV 23 FROM tab2 AS cor0
----
2
264
271

skipif mysql # not compatible
query I rowsort label-5149
SELECT ALL col0 * col0 / 23 FROM tab2 AS cor0
----
2
264
271

query I rowsort
SELECT - + 38 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

query I rowsort
SELECT DISTINCT 57 * tab1.col2 AS col1 FROM tab1
----
3078
3249
5472

onlyif mysql # use DIV operator for integer division
query I rowsort label-5152
SELECT DISTINCT + col0 * col1 DIV + col2 FROM tab1 cor0
----
1
10
11

skipif mysql # not compatible
query I rowsort label-5152
SELECT DISTINCT + col0 * col1 / + col2 FROM tab1 cor0
----
1
10
11

query I rowsort
SELECT - col0 * + 62 AS col1 FROM tab0 AS cor0
----
-1488
-2170
-5518

onlyif mysql # use DIV operator for integer division
query I rowsort label-5154
SELECT col0 DIV - 57 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-5154
SELECT col0 / - 57 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT + 1 FROM tab1, tab1 AS cor0
----
1

query I rowsort
SELECT ALL + col2 * col0 + + 19 AS col0 FROM tab0 AS cor0
----
54
7317
811

query I rowsort
SELECT 77 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

onlyif mysql # use DIV operator for integer division
query I rowsort label-5158
SELECT - col1 DIV col0 + - col1 - - col0 FROM tab1
----
-31
54
67

skipif mysql # not compatible
query I rowsort label-5158
SELECT - col1 / col0 + - col1 - - col0 FROM tab1
----
-31
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-5159
SELECT ALL + tab2.col1 DIV - 86 - - col0 * + col2 FROM tab2
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-5159
SELECT ALL + tab2.col1 / - 86 - - col0 * + col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + 45 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT ALL col2 - col2 * col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - - 9 * + col0 + cor0.col1 AS col0 FROM tab2 AS cor0
----
728
761
94

query I rowsort
SELECT DISTINCT - + 54 * col0 * + col0 + - col0 FROM tab2 cor0
----
-2653
-328614
-337093

query I rowsort
SELECT col2 + - 41 * 59 + - col0 AS col1 FROM tab2
----
-2399
-2460
-2471

query I rowsort
SELECT - col0 * - 43 + col2 * - col0 AS col2 FROM tab2 AS cor0
----
112
1326
395

query I rowsort
SELECT ALL + col2 * 57 * - col2 FROM tab2 AS cor0
----
-38532
-41553
-82308

query I rowsort
SELECT - col1 * - 48 FROM tab1 AS cor0
----
1248
480
624

onlyif mysql # use DIV operator for integer division
query I rowsort label-5168
SELECT DISTINCT - col1 DIV col1 + + col2 * col0 FROM tab2 AS cor0
----
188
2027
3001

skipif mysql # not compatible
query I rowsort label-5168
SELECT DISTINCT - col1 / col1 + + col2 * col0 FROM tab2 AS cor0
----
188
2027
3001

onlyif mysql # use DIV operator for integer division
query I rowsort label-5169
SELECT ALL + col0 + - 29 - cor0.col1 DIV cor0.col0 FROM tab1 AS cor0
----
-34
35
51

skipif mysql # not compatible
query I rowsort label-5169
SELECT ALL + col0 + - 29 - cor0.col1 / cor0.col0 FROM tab1 AS cor0
----
-34
35
51

query I rowsort
SELECT cor0.col2 * cor0.col0 * + col1 AS col1 FROM tab1 AS cor0
----
36480
4212
99840

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 cor2
----
972 values hashing to 82e15d5967b272804e574774895a0222

query I rowsort
SELECT - col1 * 41 FROM tab0 cor0
----
-3526
-3731
-3977

query I rowsort
SELECT - col0 * ( ( col0 ) ) FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT 6 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
6

query I rowsort
SELECT cor0.col0 + + col1 * + col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT 3 * + col1 FROM tab2 cor0
----
177
51
93

query I rowsort
SELECT ALL - 8 * col1 FROM tab1 AS cor0
----
-104
-208
-80

query I rowsort
SELECT - - 49 + col1 + + ( + col0 ) * cor0.col1 AS col2 FROM tab0 AS cor0
----
2199
3541
8239

query I rowsort
SELECT ALL - col1 - - col1 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL col0 * - col0 * col2 AS col2 FROM tab2
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5181
SELECT col0 DIV tab2.col1 - col0 * tab2.col0 AS col1 FROM tab2
----
-49
-6083
-6237

skipif mysql # not compatible
query I rowsort label-5181
SELECT col0 / tab2.col1 - col0 * tab2.col0 AS col1 FROM tab2
----
-49
-6083
-6237

query I rowsort
SELECT - col1 * - col1 * col1 FROM tab1
----
1000
17576
2197

query I rowsort
SELECT DISTINCT + tab0.col1 * - col1 + - tab0.col1 AS col1 FROM tab0
----
-7482
-8372
-9506

query I rowsort
SELECT DISTINCT col1 * + col1 * + col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT DISTINCT - col0 * + col2 * - col2 AS col1 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT - tab0.col1 * + col1 + - col0 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT + tab0.col0 + + tab0.col0 AS col1 FROM tab0
----
178
48
70

query I rowsort
SELECT DISTINCT 47 * - col1 AS col2 FROM tab0
----
-4042
-4277
-4559

query I rowsort
SELECT col1 * tab0.col0 + - col2 AS col1 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT - + 60 * - col2 + 81 + col0 AS col0 FROM tab1 cor0
----
3324
3565
5921

query I rowsort
SELECT DISTINCT 31 FROM tab1 AS cor0
----
31

query I rowsort
SELECT DISTINCT - - cor0.col0 - col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + - 14 * + col1 * + 39 + - col2 * col0 FROM tab0 AS cor0
----
-47748
-52997
-56984

query I rowsort
SELECT - col2 * + ( ( - col0 ) ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + tab2.col2 * col0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + 14 * col0 * - 64 FROM tab1
----
-2688
-57344
-71680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5197
SELECT ALL tab0.col1 + + 21 + - col1 DIV tab0.col0 AS col0 FROM tab0
----
104
111
116

skipif mysql # not compatible
query I rowsort label-5197
SELECT ALL tab0.col1 + + 21 + - col1 / tab0.col0 AS col0 FROM tab0
----
104
111
116

query I rowsort
SELECT DISTINCT + 47 AS col2 FROM tab0, tab0 cor0, tab2 AS cor1
----
47

query I rowsort
SELECT + 48 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT - col2 * 5 + cor0.col2 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-40
-7708
-957

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + 24 + + col2 col0 FROM tab0 cor0
----
-2031
-2102
-2327

query I rowsort
SELECT tab2.col1 * 69 AS col2 FROM tab2
----
1173
2139
4071

onlyif mysql # use DIV operator for integer division
query I rowsort label-5203
SELECT + col2 + col0 DIV col2 AS col1 FROM tab0 AS cor0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-5203
SELECT + col2 + col0 / col2 AS col1 FROM tab0 AS cor0
----
33
36
83

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab1 cor1, tab2, tab2 AS cor2
----
3645 values hashing to 1a92b418ae3c05ba566f88a890a407ae

query I rowsort
SELECT DISTINCT tab1.col2 + + 48 FROM tab1, tab1 cor0, tab0 AS cor1
----
102
105
144

onlyif mysql # use DIV operator for integer division
query I rowsort label-5206
SELECT 26 DIV + 81 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5206
SELECT 26 / + 81 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5207
SELECT - 97 DIV + col1 col1 FROM tab1
----
-3
-7
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5207
SELECT - 97 / + col1 col1 FROM tab1
----
-3
-7
-9

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0, tab2 AS cor1, tab2 cor2
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5209
SELECT - CAST( 45 AS SIGNED ) DIV col1 AS col1 FROM tab1
----
-1
-3
-4

skipif mysql # not compatible
query I rowsort label-5209
SELECT - CAST ( 45 AS INTEGER ) / col1 AS col1 FROM tab1
----
-1
-3
-4

query I rowsort
SELECT cor0.col2 * - cor0.col0 FROM tab2 cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 * ( - ( col1 ) ) + - col2 * + cor0.col1 + - col0 col2 FROM tab2 AS cor0
----
-23443
-25273
-41496

query I rowsort
SELECT - + col0 + col2 + col0 * cor0.col0 FROM tab1 AS cor0
----
4089
60
6416

query I rowsort
SELECT DISTINCT col0 - - col1 * - col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL + ( 26 * col2 ) + - col1 * + 16 FROM tab2
----
-268
206
716

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - cor0.col1 col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - cor0.col2 * - col0 + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT - col1 + - col1 * + col2 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT + + col2 + + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + - col2 * - col1 - col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL + - col2 + + cor0.col2 FROM tab2 AS cor0
----
0
0
0

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NULL NOT IN ( - cor0.col1 ) OR NOT NULL IN ( + col0 )
----

query I rowsort
SELECT DISTINCT - - col1 + - col1 + col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL - col1 * col2 - col0 * - col1 FROM tab1 cor0
----
-1326
-208
70

query I rowsort
SELECT col2 * - col0 - col1 * col0 * - col2 AS col0 FROM tab1
----
32832
4050
92160

query I rowsort
SELECT + tab1.col0 * - col2 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5227
SELECT DISTINCT col1 + col2 * col1 DIV col1 AS col1 FROM tab2
----
55
58
85

skipif mysql # not compatible
query I rowsort label-5227
SELECT DISTINCT col1 + col2 * col1 / col1 AS col1 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-5228
SELECT ALL - col0 DIV col1 + - col2 * + col0 AS col1 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-5228
SELECT ALL - col0 / col1 + - col2 * + col0 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col0 + col0 + tab2.col0 AS col1 FROM tab2
----
21
234
237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 50 + col2 * col2 col1 FROM tab0 AS cor0
----
-49
1039
6674

query I rowsort
SELECT - 17 * + col1 - + col0 FROM tab1 AS cor0
----
-234
-301
-445

query I rowsort
SELECT ALL 91 * col2 + col0 FROM tab1 AS cor0
----
4917
5251
8816

query I rowsort
SELECT DISTINCT - - 0 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT + ( - col0 ) FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT ALL 11 + - col2 * col0 AS col1 FROM tab0 AS cor0
----
-24
-7287
-781

query I rowsort
SELECT - col0 - + 98 AS col0 FROM tab0
----
-122
-133
-187

query I rowsort
SELECT col0 * col2 - + col2 AS col0 FROM tab1
----
108
3591
7584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5238
SELECT ALL + CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5238
SELECT ALL + CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5239
SELECT DISTINCT col1 DIV + tab2.col1 AS col1 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-5239
SELECT DISTINCT col1 / + tab2.col1 AS col1 FROM tab2
----
1

query I rowsort
SELECT ( col1 ) + + tab1.col0 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5241
SELECT - 82 * + col2 + + col0 DIV col0 AS col1 FROM tab1 AS cor0
----
-4427
-4673
-7871

skipif mysql # not compatible
query I rowsort label-5241
SELECT - 82 * + col2 + + col0 / col0 AS col1 FROM tab1 AS cor0
----
-4427
-4673
-7871

onlyif mysql # use DIV operator for integer division
query I rowsort label-5242
SELECT + 40 DIV - col0 col0 FROM tab1 AS cor0
----
-13
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5242
SELECT + 40 / - col0 col0 FROM tab1 AS cor0
----
-13
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5243
SELECT ALL - ( col0 ) + cor0.col2 DIV col0 FROM tab0 AS cor0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-5243
SELECT ALL - ( col0 ) + cor0.col2 / col0 FROM tab0 AS cor0
----
-23
-35
-89

query I rowsort
SELECT + cor0.col1 * - col1 * col0 - col1 AS col0 FROM tab0 AS cor0
----
-177590
-329412
-737100

query I rowsort
SELECT + 59 + - col2 * col1 FROM tab0 AS cor0
----
-2779
-38
-7403

onlyif mysql # use DIV operator for integer division
query I rowsort label-5246
SELECT + - col0 DIV - col2 + col0 FROM tab1 AS cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-5246
SELECT + - col0 / - col2 + col0 FROM tab1 AS cor0
----
3
65
80

query I rowsort
SELECT - col0 * - col1 AS col0 FROM tab1 WHERE ( col2 + - col1 - col0 ) IN ( col0 )
----

query I rowsort
SELECT DISTINCT col2 + col1 + + col1 FROM tab2
----
144
72
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5249
SELECT col0 DIV tab0.col2 + col1 * - col1 col0 FROM tab0
----
-7396
-8280
-9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5249
SELECT col0 / tab0.col2 + col1 * - col1 col0 FROM tab0
----
-7396
-8280
-9374

query I rowsort
SELECT + col2 FROM tab0 WHERE NOT - col1 - + col0 IN ( col0 )
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5251
SELECT ALL col0 * col0 DIV + col0 AS col1 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5251
SELECT ALL col0 * col0 / + col0 AS col1 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5252
SELECT DISTINCT col2 * + col1 DIV col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5252
SELECT DISTINCT col2 * + col1 / col1 FROM tab0
----
1
33
82

query I rowsort
SELECT col2 + - col1 * - col0 * - col2 FROM tab1
----
-36423
-4158
-99744

query I rowsort
SELECT + col1 FROM tab2 WHERE NOT NULL <> NULL
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL BETWEEN - col0 AND NULL
----

query I rowsort
SELECT ALL - tab0.col1 + col2 AS col2 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT - tab1.col2 + - col0 * + tab1.col1 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT col0 * col2 * + col1 AS col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT ALL + col0 + tab2.col0 FROM tab2
----
14
156
158

query I rowsort
SELECT + col2 + - col2 + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL - col2 + - col1 * - col2 FROM tab1
----
1152
1350
513

query I rowsort
SELECT DISTINCT col0 * + tab1.col0 AS col0 FROM tab1 WHERE col1 / + col1 IN ( - col2 * - tab1.col1 )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT - col1 IN ( + col2 + + tab0.col1 * col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col0 + + col0 * col1 AS col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT col2 + col2 * - tab2.col1 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT col2 AS col2 FROM tab0 WHERE NOT - col1 * col0 IN ( tab0.col1 )
----
1
33
82

query I rowsort
SELECT - col2 + - col2 * col2 FROM tab1
----
-2970
-3306
-9312

query I rowsort
SELECT - tab1.col2 * col0 + col2 * + col1 AS col1 FROM tab1 WHERE ( NULL ) <= col1 + col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5269
SELECT col1 DIV col2 + + col0 FROM tab0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-5269
SELECT col1 / col2 + + col0 FROM tab0
----
132
26
90

query I rowsort
SELECT col1 + - col0 + tab0.col0 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + col0 * col0 + + col0 - col2 AS col1 FROM tab0
----
1259
567
7928

query I rowsort
SELECT + tab2.col0 * col1 * - col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT ALL - col1 * col0 - - tab0.col0 AS col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + col1 * - col1 - - col0 FROM tab0
----
-7372
-8192
-9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 col1 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5276
SELECT DISTINCT cor0.col1 + col0 DIV col2 AS col2 FROM tab1 AS cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-5276
SELECT DISTINCT cor0.col1 + col0 / col2 AS col2 FROM tab1 AS cor0
----
11
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + - cor0.col0 - + col1 col2 FROM tab1 AS cor0
----
-138
-173
-32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + + col1 col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL - + col0 * - col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT col2 + cor0.col1 - col2 * + col1 AS col2 FROM tab2 AS cor0
----
-1449
-591
-779

query I rowsort
SELECT DISTINCT - - col0 - + col1 * col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-231
-40896
-83120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 + + col1 col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - col0 + col2 * col2 * col2 FROM tab2 cor0
----
17498
19676
54793

query I rowsort
SELECT ALL + col1 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT NULL >= col0 + col0 - + col2
----

query I rowsort
SELECT + tab0.col1 - col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL - ( - col2 ) * col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - 70 FROM tab0 cor0
----
-70
-70
-70

query I rowsort
SELECT + col2 + + 27 AS col2 FROM tab2 AS cor0
----
53
54
65

query I rowsort
SELECT - ( - col0 ) + col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT - ( + cor0.col1 ) * col2 + col0 * col1 FROM tab0 AS cor0
----
-774
3298
637

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5293
SELECT + CAST( NULL AS SIGNED ) + + cor0.col0 * - col1 * col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5293
SELECT + CAST ( NULL AS INTEGER ) + + cor0.col0 * - col1 * col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + + 52 FROM tab2 cor0
----
130
131
59

query I rowsort
SELECT DISTINCT + + ( col0 ) + cor0.col2 * + 77 FROM tab1 AS cor0
----
4161
4453
7472

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( col2 AS REAL ) AS col1 FROM tab0 cor0
----
1
33
82

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0, tab0 AS cor1, tab1 cor2
----
972 values hashing to 0210050fb1701e2797a9b17e1ebac91e

query I rowsort
SELECT ALL - 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 DISTINCT + cor0.col0 * col1 col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5300
SELECT cor0.col2 * + CAST( - col2 AS SIGNED ) + col2 * ( 3 ) * + col2 FROM tab0 AS cor0
----
13448
2
2178

skipif mysql # not compatible
query I rowsort label-5300
SELECT cor0.col2 * + CAST ( - col2 AS INTEGER ) + col2 * ( 3 ) * + col2 FROM tab0 AS cor0
----
13448
2
2178

query I rowsort
SELECT DISTINCT + col0 * 17 FROM tab1 AS cor0
----
1088
1360
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * col2 - col1 * col2 col0 FROM tab1 AS cor0
----
-10464
-3819
-4320

query I rowsort
SELECT 57 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT DISTINCT - col2 + - cor0.col1 * col0 * + col2 AS col0 FROM tab0 AS cor0
----
-3396
-664200
-68145

query I rowsort
SELECT + cor0.col2 + col1 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL col2 * col1 + + col1 AS col1 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * col0 + 81 * + col2 col1 FROM tab1 AS cor0
----
4212
96
969

query I rowsort
SELECT ALL col1 + ( - col2 ) AS col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT - ( + col2 ) + col1 AS col0 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT col1 * + ( + col0 + - col2 * - col0 ) FROM tab0
----
672217
6790
70176

query I rowsort
SELECT col1 * - ( - 4 ) AS col0 FROM tab0
----
344
364
388

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + 20 col1 FROM tab1
----
116
74
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( - col1 ) * + col0 col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( 23 AS REAL ) * - col0 - - col1 * col2 * - col1 AS col0 FROM tab0 AS cor0
----
-243516
-676995
-8604

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5315
SELECT ( 2 ) * col2 * CAST( NULL AS SIGNED ) + - col2 * + 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-5315
SELECT ( 2 ) * col2 * CAST ( NULL AS INTEGER ) + - col2 * + col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 67 * - col0 col2 FROM tab0 AS cor0
----
1608
2345
5963

query I rowsort
SELECT DISTINCT col1 * col1 + + col1 * - col1 + col2 AS col0 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5318
SELECT ALL + 32 - col0 DIV - col2 FROM tab1 AS cor0
----
32
32
33

skipif mysql # not compatible
query I rowsort label-5318
SELECT ALL + 32 - col0 / - col2 FROM tab1 AS cor0
----
32
32
33

query I rowsort
SELECT DISTINCT ( - col1 + col0 ) FROM tab2
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( + col2 * col1 ) col1 FROM tab0
----
611884
93654
97

query I rowsort
SELECT + col2 - - tab0.col0 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT + col0 * 87 + col0 FROM tab2 AS cor0
----
616
6864
6952

onlyif mysql # use DIV operator for integer division
query I rowsort label-5323
SELECT DISTINCT ( - col0 ) * col2 + 11 - col1 DIV col0 FROM tab2
----
-182
-2017
-2991

skipif mysql # not compatible
query I rowsort label-5323
SELECT DISTINCT ( - col0 ) * col2 + 11 - col1 / col0 FROM tab2
----
-182
-2017
-2991

query I rowsort
SELECT DISTINCT 52 FROM tab0, tab1, tab2 cor0
----
52

query I rowsort
SELECT + col2 + - ( col0 ) * - cor0.col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL + 33 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col1 * + col2 col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT - - col2 * - 39 AS col1 FROM tab0 AS cor0
----
-1287
-3198
-39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + cor0.col2 col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col2 * 46 FROM tab1 AS cor0
----
2484
2622
4416

query I rowsort
SELECT ALL col0 + col0 * - col0 AS col1 FROM tab2
----
-42
-6006
-6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-5332
SELECT ALL col2 + - col1 DIV + col0 FROM tab0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-5332
SELECT ALL col2 + - col1 / + col0 FROM tab0
----
-1
30
81

query I rowsort
SELECT ALL col2 * - col2 * - ( col2 * col2 ) + - 2 AS col1 FROM tab1
----
10555999
84934654
8503054

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0, tab0 cor1, tab0, tab1 AS cor2
----
3645 values hashing to 59bb9dc93b6f10de841a7db8eb3857e9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 - col2 col0 FROM tab1
----
-104
-179
-82

query I rowsort
SELECT + cor0.col1 * + col0 - + col2 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT ALL + col0 + - cor0.col2 * col2 + - 52 FROM tab0 AS cor0
----
-1117
-18
-6687

query I rowsort
SELECT + col2 + + col2 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + col2 col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT 50 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT + - 85 * - 88 FROM tab0, tab1 AS cor0
----
9 values hashing to e4a1d5cf82af9790f2992f571d486559

query I rowsort
SELECT DISTINCT - + col2 * + col1 * col0 AS col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 14 + + cor0.col2 col0 FROM tab2 cor0
----
276
461
852

query I rowsort
SELECT DISTINCT - cor0.col0 + col1 AS col1 FROM tab0 cor0
----
2
62

query I rowsort
SELECT - - col1 * ( - 80 ) + col1 FROM tab1 AS cor0
----
-1027
-2054
-790

query I rowsort
SELECT DISTINCT cor0.col2 + + col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL - + cor0.col1 * 20 AS col0 FROM tab1 AS cor0
----
-200
-260
-520

onlyif mysql # use DIV operator for integer division
query I rowsort label-5348
SELECT ALL - col0 DIV ( + 97 ) - - col1 * - 2 AS col0 FROM tab1 AS cor0
----
-20
-26
-52

skipif mysql # not compatible
query I rowsort label-5348
SELECT ALL - col0 / ( + 97 ) - - col1 * - 2 AS col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT ALL col0 + 80 * - cor0.col1 * + col2 + 15 AS col1 FROM tab0 AS cor0
----
-227001
-596856
-7710

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5350
SELECT - - col0 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5350
SELECT - - col0 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + ( - col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT - col0 * tab1.col1 * - col1 AS col1 FROM tab1
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + 28 - - 91 * col1 col0 FROM tab2 AS cor0
----
1613
2876
5423

query I rowsort
SELECT DISTINCT - 65 FROM tab1, tab2 cor0, tab2 AS cor1
----
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 93 col2 FROM tab0 AS cor0
----
93
93
93

query I rowsort
SELECT ALL ( + ( - cor0.col0 ) ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL col0 + - col0 * col0 AS col2 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5358
SELECT DISTINCT + - 32 + 63 DIV cor0.col1 FROM tab0 AS cor0
----
-32

skipif mysql # not compatible
query I rowsort label-5358
SELECT DISTINCT + - 32 + 63 / cor0.col1 FROM tab0 AS cor0
----
-32

query I rowsort
SELECT DISTINCT - col2 * - cor0.col0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5360
SELECT - CAST( NULL AS SIGNED ) + col1 * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5360
SELECT - CAST ( NULL AS INTEGER ) + col1 * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - ( 86 ) AS col1 FROM tab0 cor0
----
-86
-86
-86

query I rowsort
SELECT 27 + + col0 AS col2 FROM tab1 AS cor0
----
107
30
91

query I rowsort
SELECT - 37 + col2 FROM tab0 cor0
----
-36
-4
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5364
SELECT + CAST( NULL AS SIGNED ) + 70 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5364
SELECT + CAST ( NULL AS INTEGER ) + 70 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5365
SELECT ALL col2 DIV - CAST( + col0 AS SIGNED ) FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5365
SELECT ALL col2 / - CAST ( + col0 AS INTEGER ) FROM tab0
----
-1
0
0

query I rowsort
SELECT + 75 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - col1 AS REAL ) col0 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5368
SELECT + - CAST( - col0 AS SIGNED ) FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5368
SELECT + - CAST ( - col0 AS INTEGER ) FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL 19 AS col2 FROM tab0 cor0
----
19
19
19

query I rowsort
SELECT DISTINCT + - 14 * - 14 AS col2 FROM tab1 AS cor0
----
196

query I rowsort
SELECT ( - 18 ) * - col1 FROM tab2 AS cor0
----
1062
306
558

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5372
SELECT DISTINCT + - CAST( NULL AS DECIMAL ) + + 87 / col2 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5372
SELECT DISTINCT + - CAST ( NULL AS REAL ) + + 87 / col2 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + - col1 * + col2 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT 94 AS col0 FROM tab0, tab1 AS cor0
----
94

query I rowsort
SELECT ALL - ( - ( col0 ) ) FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + col2 * col1 + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT 60 + 63 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
123

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 AS cor2
----
3645 values hashing to f655b6f4c5b9ff73813030f2822ea1fd

onlyif mysql # use DIV operator for integer division
query I rowsort label-5379
SELECT - 96 DIV - col0 FROM tab0 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-5379
SELECT - 96 / - col0 FROM tab0 AS cor0
----
1
2
4

query I rowsort
SELECT - + ( col0 ) + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - ( ( col1 ) + ( tab0.col0 ) ) FROM tab0
----
-110
-132
-180

query I rowsort
SELECT - col0 + - col2 * + col0 * col2 FROM tab1
----
-208000
-737360
-8751

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 21 col0 FROM tab2
----
-21
-21
-21

query I rowsort
SELECT - col2 * tab0.col2 * + col2 + - col1 AS col0 FROM tab0
----
-36023
-551459
-98

query I rowsort
SELECT ALL + col0 * col2 * 92 FROM tab0 AS cor0
----
3220
671416
72864

query I rowsort
SELECT DISTINCT - + 91 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-11
-27
-88

query I rowsort
SELECT ALL + 99 * - col0 AS col2 FROM tab0 AS cor0
----
-2376
-3465
-8811

query I rowsort
SELECT - col1 + - col2 * - 49 FROM tab0 cor0
----
-48
1531
3927

query I rowsort
SELECT DISTINCT + cor0.col0 * + col2 * + ( ( col1 ) ) FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT + col1 + - col0 * - 68 AS col1 FROM tab1 AS cor0
----
230
4362
5453

query I rowsort
SELECT - 98 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-2352
-3430
-8722

query I rowsort
SELECT ALL + + col1 + + col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col2 * - col2 * ( col0 ) AS col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT tab0.col2 + - col0 AS col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT col2 + 69 + 23 AS col0 FROM tab1
----
146
149
188

query I rowsort
SELECT - - col1 * col2 + 40 * + col1 AS col1 FROM tab2 AS cor0
----
1326
2077
3894

query I rowsort
SELECT ALL - col1 + ( col1 ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 + cor0.col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT ALL cor0.col2 FROM tab0 cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2, tab0 AS cor3
----
243 values hashing to 291cdf20f55dc7bbcb55f561dc0b74d8

query I rowsort
SELECT ALL + col0 + - col2 AS col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT + - col2 * + 46 AS col1 FROM tab0 cor0
----
-1518
-3772
-46

query I rowsort
SELECT ALL col2 * cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5403
SELECT ALL CAST( NULL AS SIGNED ) / 96 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5403
SELECT ALL CAST ( NULL AS INTEGER ) / 96 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 52 * - 92 FROM tab2
----
-4784
-4784
-4784

query I rowsort
SELECT DISTINCT + + 91 FROM tab2 AS cor0
----
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col2 + + ( col0 ) * - col1 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT - col1 * 89 AS col1 FROM tab2 AS cor0
----
-1513
-2759
-5251

onlyif mysql # use DIV operator for integer division
query I rowsort label-5409
SELECT DISTINCT + col2 DIV col0 AS col2 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5409
SELECT DISTINCT + col2 / col0 AS col2 FROM tab1 AS cor0
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-5410
SELECT ALL - col2 DIV + col1 + - ( - 24 + - col2 ) FROM tab0
----
106
25
57

skipif mysql # not compatible
query I rowsort label-5410
SELECT ALL - col2 / + col1 + - ( - 24 + - col2 ) FROM tab0
----
106
25
57

query I rowsort
SELECT + col0 + ( ( + col0 ) ) FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT + + col1 + 70 + + col1 AS col2 FROM tab1 cor0
----
122
90
96

query I rowsort
SELECT col1 * 4 AS col1 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT ALL 3 + tab1.col0 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to ad218c5dab3010afbb8f5793c606925e

query I rowsort
SELECT ALL + col1 * col1 + + 59 + + col1 * - tab2.col1 AS col1 FROM tab2
----
59
59
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5416
SELECT 74 DIV tab2.col1 AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to bbb27326c926bed56f07f4b0660b3cff

skipif mysql # not compatible
query I rowsort label-5416
SELECT 74 / tab2.col1 AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to bbb27326c926bed56f07f4b0660b3cff

query I rowsort
SELECT - col0 * - col1 * col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT tab1.col0 * col0 * + 28 FROM tab1
----
114688
179200
252

onlyif mysql # use DIV operator for integer division
query I rowsort label-5419
SELECT ALL - 98 DIV col0 col1 FROM tab0
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5419
SELECT ALL - 98 / col0 col1 FROM tab0
----
-1
-2
-4

query I rowsort
SELECT + cor0.col0 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT col1 + + col1 + + col0 FROM tab1 AS cor0
----
106
55
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-5422
SELECT + col0 * col0 + ( cor0.col0 ) DIV 19 FROM tab0 AS cor0
----
1226
577
7925

skipif mysql # not compatible
query I rowsort label-5422
SELECT + col0 * col0 + ( cor0.col0 ) / 19 FROM tab0 AS cor0
----
1226
577
7925

query I rowsort
SELECT + - cor0.col1 + col0 + - col1 * col0 FROM tab1 AS cor0
----
-101
-586
-973

query I rowsort
SELECT col0 * 19 + col1 AS col1 FROM tab2
----
1518
1541
164

onlyif mysql # use DIV operator for integer division
query I rowsort label-5425
SELECT + ( tab2.col2 ) DIV 19 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to c08e3956186780709ba0eab5eede7b9c

skipif mysql # not compatible
query I rowsort label-5425
SELECT + ( tab2.col2 ) / 19 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to c08e3956186780709ba0eab5eede7b9c

query I rowsort
SELECT ALL + ( - col1 ) * col1 + col2 * col2 FROM tab0 AS cor0
----
-1557
-6307
-9408

query I rowsort
SELECT - 95 * - 24 + + col2 * 75 FROM tab0 cor0
----
2355
4755
8430

query I rowsort
SELECT ALL - 81 - 2 FROM tab2 cor0
----
-83
-83
-83

query I rowsort
SELECT ALL + col2 * - 50 + - cor0.col0 * col1 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
-12117
-3444
-3681

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT cor1.col2 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5432
SELECT DISTINCT + CAST( col1 AS SIGNED ) * + col0 + - cor0.col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif mysql # not compatible
query I rowsort label-5432
SELECT DISTINCT + CAST ( col1 AS INTEGER ) * + col0 + - cor0.col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 10 col1 FROM tab0 AS cor0
----
-10

query I rowsort
SELECT + 67 * cor0.col0 * - col1 + - 56 * col1 FROM tab2 AS cor0
----
-16275
-311638
-90933

query I rowsort
SELECT ALL - ( + cor0.col1 ) FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT - col1 + + col1 * 77 FROM tab1 AS cor0
----
1976
760
988

query I rowsort
SELECT DISTINCT 68 * - col1 + col0 * col0 AS col2 FROM tab1 AS cor0
----
-1759
3416
5516

query I rowsort
SELECT - col1 + col0 + - 43 * - cor0.col0 * - cor0.col0 FROM tab0 AS cor0
----
-24830
-340605
-52737

query I rowsort
SELECT + 8 AS col2 FROM tab0
----
8
8
8

query I rowsort
SELECT - 56 - col0 AS col0 FROM tab0 AS cor0
----
-145
-80
-91

query I rowsort
SELECT - + col2 - - col2 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5442
SELECT + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5442
SELECT + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + 90 * - ( cor0.col1 ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 59f0d554f46aced322dfaa2485535d42

query I rowsort
SELECT 48 * - col2 FROM tab0 cor0
----
-1584
-3936
-48

query I rowsort
SELECT ALL + col2 + col2 * col2 * + col1 AS col0 FROM tab2 AS cor0
----
22626
24586
39910

query I rowsort
SELECT + - ( col2 ) FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - - col0 * - 9 FROM tab1 AS cor0
----
-27
-576
-720

onlyif mysql # use DIV operator for integer division
query I rowsort label-5448
SELECT + col0 + ( col0 ) DIV col2 AS col1 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-5448
SELECT + col0 + ( col0 ) / col2 AS col1 FROM tab0 AS cor0
----
24
70
90

query I rowsort
SELECT ALL - col1 * - col1 + + col2 AS col0 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-5450
SELECT ALL col2 + + col0 DIV + col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-5450
SELECT ALL col2 + + col0 / + col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT + cor0.col2 * + cor0.col2 + + 24 AS col2 FROM tab2 cor0
----
1468
700
753

query I rowsort
SELECT - 50 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT col0 + 65 FROM tab2 AS cor0
----
143
144
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-5454
SELECT DISTINCT + col0 + 87 DIV col0 FROM tab0 cor0
----
27
37
89

skipif mysql # not compatible
query I rowsort label-5454
SELECT DISTINCT + col0 + 87 / col0 FROM tab0 cor0
----
27
37
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5455
SELECT DISTINCT col2 + + col2 DIV - col2 AS col0 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-5455
SELECT DISTINCT col2 + + col2 / - col2 AS col0 FROM tab0
----
0
32
81

query I rowsort
SELECT ALL tab2.col1 * + 92 FROM tab2
----
1564
2852
5428

query I rowsort
SELECT - 40 + col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1208
1364
530

query I rowsort
SELECT 8 * ( - col1 ) AS col1 FROM tab1 AS cor0
----
-104
-208
-80

query I rowsort
SELECT ALL 42 FROM tab2, tab0 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT DISTINCT - - 49 * + cor0.col2 + col1 AS col1 FROM tab2 AS cor0
----
1333
1354
1879

query I rowsort
SELECT ALL 5 * col0 FROM tab0 cor0
----
120
175
445

query I rowsort
SELECT - col0 * - col2 - - col1 * + ( + col0 ) AS col2 FROM tab2
----
406
4345
6630

query I rowsort
SELECT ALL - ( + col0 ) + col0 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT 42 - - tab1.col2 * - col1 FROM tab1
----
-1206
-1362
-528

query I rowsort
SELECT ALL - col0 * tab2.col1 AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT 25 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT ALL - + col1 * + 68 FROM tab0 cor0
----
-5848
-6188
-6596

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col1 AS REAL ) * + col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - 44 FROM tab2, tab2 AS cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

query I rowsort
SELECT ALL 5 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT ALL + ( 74 ) + - col1 FROM tab0
----
-12
-17
-23

query I rowsort
SELECT ALL + 7 AS col0 FROM tab2 cor0
----
7
7
7

query I rowsort
SELECT col1 + - 24 * + col0 AS col1 FROM tab1 cor0
----
-1526
-1907
-46

query I rowsort
SELECT ALL + 9 * col1 AS col1 FROM tab0 AS cor0
----
774
819
873

query I rowsort
SELECT ALL + 12 * col1 FROM tab1 AS cor0
----
120
156
312

query I rowsort
SELECT DISTINCT + 14 + col0 FROM tab2 AS cor0
----
21
92
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5477
SELECT DISTINCT col2 * col0 * - CAST( NULL AS SIGNED ) + - 11 * + tab0.col0 + + col1 AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5477
SELECT DISTINCT col2 * col0 * - CAST ( NULL AS INTEGER ) + - 11 * + tab0.col0 + + col1 AS col2 FROM tab0
----
NULL

query I rowsort
SELECT ALL col0 * tab0.col0 + + 80 AS col2 FROM tab0
----
1305
656
8001

query I rowsort
SELECT 81 + col2 * - 87 FROM tab2
----
-2181
-2268
-3225

query I rowsort
SELECT ALL + + col0 * - col0 * + col2 + col1 AS col1 FROM tab2 AS cor0
----
-1292
-158125
-237141

onlyif mysql # use DIV operator for integer division
query I rowsort label-5481
SELECT - col0 DIV + col1 + col1 * col1 FROM tab2 AS cor0
----
285
3480
961

skipif mysql # not compatible
query I rowsort label-5481
SELECT - col0 / + col1 + col1 * col1 FROM tab2 AS cor0
----
285
3480
961

query I rowsort
SELECT - ( col2 ) * 0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 - - col2 * + col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT - 55 * + col2 + ( col2 ) * - col0 * ( + col1 ) - col0 AS col1 FROM tab2 cor0
----
-121160
-53203
-7351

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5485
SELECT ALL ( - col2 ) * CAST( - col0 AS SIGNED ) FROM tab2 cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-5485
SELECT ALL ( - col2 ) * CAST ( - col0 AS INTEGER ) FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - col1 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL col1 * 82 AS col2 FROM tab0 AS cor0
----
7052
7462
7954

query I rowsort
SELECT ALL col1 * ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col1 * - 57 FROM tab1 AS cor0
----
-1482
-570
-741

query I rowsort
SELECT ALL cor0.col0 * + col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - col1 * - 18 AS col2 FROM tab0 AS cor0
----
1548
1638
1746

query I rowsort
SELECT - col2 + ( - ( + col2 ) ) * + col0 FROM tab1 cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT + col0 * + col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + col0 * - col2 + - col0 * - col1 + cor0.col1 FROM tab0 AS cor0
----
1358
3457
892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + col0 col1 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort
SELECT + col2 * CAST ( col2 AS REAL ) FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-5497
SELECT DISTINCT + + cor0.col1 + + col2 DIV col0 AS col2 FROM tab2 cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-5497
SELECT DISTINCT + + cor0.col1 + + col2 / col0 AS col2 FROM tab2 cor0
----
17
34
59

query I rowsort
SELECT DISTINCT col0 * - col0 + cor0.col1 FROM tab0 cor0
----
-1128
-490
-7830

query I rowsort
SELECT + col0 * - 59 AS col1 FROM tab2 AS cor0
----
-413
-4602
-4661

query I rowsort
SELECT ALL + col1 + col0 FROM tab2 cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + - col0 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + cor0.col0 * ( col0 ) + - col2 FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT DISTINCT col2 * + 51 AS col1 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT DISTINCT + col1 - + col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + - col0 * + col2 - cor0.col1 * col1 FROM tab0 AS cor0
----
-15579
-8188
-9444

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5506
SELECT ALL + CAST( NULL AS DECIMAL ) FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5506
SELECT ALL + CAST ( NULL AS REAL ) FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5507
SELECT col2 + 82 DIV - col1 FROM tab2
----
25
25
34

skipif mysql # not compatible
query I rowsort label-5507
SELECT col2 + 82 / - col1 FROM tab2
----
25
25
34

query I rowsort
SELECT - col0 * ( col0 ) AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - - col1 * 97 * - col1 FROM tab1 AS cor0
----
-16393
-65572
-9700

query I rowsort
SELECT ALL col1 * col1 * cor0.col1 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT col2 * + col1 + col1 * + col1 FROM tab2 AS cor0
----
1798
5015
935

query I rowsort
SELECT DISTINCT col2 - - col0 FROM tab2 cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 63 + - col0 col1 FROM tab2 AS cor0
----
-141
-142
-70

query I rowsort
SELECT ALL 35 * - col2 + + col0 * + 65 FROM tab2 AS cor0
----
-490
3805
4160

onlyif mysql # use DIV operator for integer division
query I rowsort label-5515
SELECT - - cor0.col0 DIV - cor0.col0 AS col0 FROM tab2 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5515
SELECT - - cor0.col0 / - cor0.col0 AS col0 FROM tab2 cor0
----
-1
-1
-1

query I rowsort
SELECT + ( - 99 ) AS col0 FROM tab2 AS cor0
----
-99
-99
-99

query I rowsort
SELECT DISTINCT 93 AS col1 FROM tab2, tab0 AS cor0, tab2 cor1
----
93

query I rowsort
SELECT ALL 93 + - col0 AS col2 FROM tab1 AS cor0
----
13
29
90

query I rowsort
SELECT + col0 * col1 * col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT + - col1 - col0 AS col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - + ( col1 ) AS col2 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col0 + + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * cor0.col1 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + ( col2 ) + 38 * - 61 AS col2 FROM tab2 AS cor0
----
-2280
-2291
-2292

query I rowsort
SELECT + 89 * - col0 AS col0 FROM tab0 AS cor0
----
-2136
-3115
-7921

query I rowsort
SELECT DISTINCT - 9 * + col0 FROM tab1 AS cor0
----
-27
-576
-720

query I rowsort
SELECT ALL - + col2 - - col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - 65 + col2 * col1 FROM tab0 AS cor0
----
162
2903
7527

query I rowsort
SELECT DISTINCT - cor0.col0 + + col1 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL + col0 + + col0 * col1 * - col0 FROM tab2 AS cor0
----
-106018
-1512
-358878

query I rowsort
SELECT + col2 * + ( col2 ) AS col2 FROM tab1
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-5533
SELECT 62 * col0 - - col0 DIV - col1 FROM tab1 AS cor0
----
186
3962
4954

skipif mysql # not compatible
query I rowsort label-5533
SELECT 62 * col0 - - col0 / - col1 FROM tab1 AS cor0
----
186
3962
4954

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5534
SELECT + 33 * cor0.col1 + CAST( + 0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
1023
1947
561

skipif mysql # not compatible
query I rowsort label-5534
SELECT + 33 * cor0.col1 + CAST ( + 0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
1023
1947
561

query I rowsort
SELECT DISTINCT + 5 FROM tab2, tab0 AS cor0
----
5

query I rowsort
SELECT DISTINCT + col0 * col0 + col0 AS col0 FROM tab0
----
1260
600
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col1 * + 93 col1 FROM tab0
----
8022
8552
9056

query I rowsort
SELECT DISTINCT 27 + + col2 AS col0 FROM tab1
----
123
81
84

query I rowsort
SELECT + + 85 * + col1 * - cor0.col2 FROM tab0 AS cor0
----
-241230
-634270
-8245

query I rowsort
SELECT - - cor0.col0 * col0 * - col1 + + col1 AS col0 FROM tab1 AS cor0
----
-208
-40950
-83187

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5541
SELECT ALL col2 + tab1.col0 / - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5541
SELECT ALL col2 + tab1.col0 / - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 60 * col2 col2 FROM tab2
----
1560
1620
2280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5543
SELECT CAST( - col2 AS SIGNED ) * col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-5543
SELECT CAST ( - col2 AS INTEGER ) * col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - col0 * + cor0.col0 AS col2 FROM tab1 cor0
----
-4096
-6400
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * + 12 col1 FROM tab0 AS cor0
----
12
396
984

query I rowsort
SELECT ( cor0.col1 ) * col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT 59 * - 6 + + cor0.col0 AS col2 FROM tab2 cor0
----
-275
-276
-347

query I rowsort
SELECT - 39 * + 66 AS col0 FROM tab1 AS cor0
----
-2574
-2574
-2574

query I rowsort
SELECT + 89 * - 11 AS col2 FROM tab0 AS cor0
----
-979
-979
-979

query I rowsort
SELECT DISTINCT + tab1.col2 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
54
57
96

query I rowsort
SELECT DISTINCT 74 + tab0.col2 * col1 FROM tab0
----
171
2912
7536

query I rowsort
SELECT ALL - cor0.col1 + - 91 * col2 FROM tab2 cor0
----
-2425
-2488
-3475

query I rowsort
SELECT + 54 * col1 + col2 - ( 51 ) AS col2 FROM tab1 AS cor0
----
1407
546
747

query I rowsort
SELECT ALL + 92 FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab0 cor1
----
81 values hashing to cfcf012ce1a8dd60a7428b4ef6b95843

query I rowsort
SELECT ALL - 73 * tab0.col1 FROM tab0
----
-6278
-6643
-7081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 * - cor0.col1 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - + col1 * 41 AS col2 FROM tab1 AS cor0
----
-1066
-410
-533

query I rowsort
SELECT cor0.col0 + cor0.col0 * cor0.col1 AS col2 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 01cbd555b012411c37d61ab5929c29be

onlyif mysql # use DIV operator for integer division
query I rowsort label-5560
SELECT col2 DIV + ( 52 * col0 ) AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5560
SELECT col2 / + ( 52 * col0 ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 - - 59 FROM tab0
----
145
150
156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( col2 ) col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL col1 * cor0.col2 + + col1 AS col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + 9 + col1 AS col2 FROM tab1 AS cor0
----
19
22
35

query I rowsort
SELECT DISTINCT - col2 * 27 AS col2 FROM tab0 AS cor0
----
-2214
-27
-891

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 49 col1 FROM tab1, tab1 AS cor0
----
49

query I rowsort
SELECT ALL ( - col0 ) + col0 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT + ( col1 ) * 7 + ( - col0 * col0 ) FROM tab2 AS cor0
----
-5671
-6122
168

query I rowsort
SELECT + col2 * - tab0.col1 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - col1 * + col1 * 3 AS col0 FROM tab2 AS cor0
----
-10443
-2883
-867

query I rowsort
SELECT - - col2 + - 98 * + col1 FROM tab0 AS cor0
----
-8395
-8836
-9505

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + 96 + col1 col2 FROM tab2 AS cor0
----
703
7547
7601

query I rowsort
SELECT + tab2.col0 * - col2 AS col2 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 82 col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to ce62f59690969f4492d78eb57c3181f0

query I rowsort
SELECT DISTINCT col2 * - ( cor0.col0 ) + col1 AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT col1 + + 14 AS col1 FROM tab2 AS cor0
----
31
45
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 2 col0 FROM tab1
----
2
2
2

query I rowsort
SELECT DISTINCT 93 AS col2 FROM tab1
----
93

query I rowsort
SELECT ALL 92 * col1 FROM tab1 AS cor0
----
1196
2392
920

query I rowsort
SELECT DISTINCT + col0 * + col0 + + 62 FROM tab2 AS cor0
----
111
6146
6303

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 18 col0 FROM tab0 AS cor0
----
-18

query I rowsort
SELECT ( + col1 ) * col1 * 36 FROM tab1
----
24336
3600
6084

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
3645 values hashing to 52c9380a39df7a744b9f2f2c5bf55dd5

query I rowsort
SELECT - ( tab1.col1 ) - col2 AS col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT col1 - col2 * col1 FROM tab1
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 87 col1 FROM tab2
----
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5587
SELECT ALL cor0.col2 + + col1 * col2 DIV - 8 FROM tab1 AS cor0
----
-121
-14
-60

skipif mysql # not compatible
query I rowsort label-5587
SELECT ALL cor0.col2 + + col1 * col2 / - 8 FROM tab1 AS cor0
----
-121
-14
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 * + cor0.col2 col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT tab0.col0 * + col1 * ( col1 ) AS col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT + 60 AS col1 FROM tab1, tab0 AS cor0
----
60

query I rowsort
SELECT DISTINCT col0 * + col0 * col1 + + col2 * col1 - col0 FROM tab1
----
1635
41466
84368

onlyif mysql # use DIV operator for integer division
query I rowsort label-5592
SELECT tab0.col0 + + tab0.col1 DIV - 33 + col0 FROM tab0
----
176
46
68

skipif mysql # not compatible
query I rowsort label-5592
SELECT tab0.col0 + + tab0.col1 / - 33 + col0 FROM tab0
----
176
46
68

query I rowsort
SELECT DISTINCT col1 - 30 FROM tab2
----
-13
1
29

query I rowsort
SELECT DISTINCT col1 * - 64 - + col1 FROM tab2
----
-1105
-2015
-3835

query I rowsort
SELECT DISTINCT + + ( 70 ) AS col2 FROM tab1 AS cor0
----
70

query I rowsort
SELECT - 59 * - col1 + + col1 + cor0.col1 * + col2 AS col0 FROM tab0 AS cor0
----
12922
5917
7998

query I rowsort
SELECT ALL + - 64 * + col1 FROM tab2 AS cor0
----
-1088
-1984
-3776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 26 col0 FROM tab0 cor0
----
26

query I rowsort
SELECT DISTINCT - col0 * ( - col0 ) AS col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ALL col0 + col2 * - tab2.col1 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT col1 + + ( 94 ) FROM tab2 AS cor0
----
111
125
153

onlyif mysql # use DIV operator for integer division
query I rowsort label-5602
SELECT - col1 DIV - ( 77 ) FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5602
SELECT - col1 / - ( 77 ) FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5603
SELECT - col0 * col1 + col1 * 51 DIV + cor0.col1 + col0 col2 FROM tab2 cor0
----
-1213
-159
-4473

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5603
SELECT - col0 * col1 + col1 * 51 / + cor0.col1 + col0 col2 FROM tab2 cor0
----
-1213
-159
-4473

query I rowsort
SELECT - col0 + + 15 * col0 AS col1 FROM tab0
----
1246
336
490

query I rowsort
SELECT DISTINCT - + ( col0 ) * col1 * cor0.col1 + col1 * col1 AS col2 FROM tab2 AS cor0
----
-22542
-268037
-5766

query I rowsort
SELECT DISTINCT - 8 + + col2 FROM tab0 AS cor0
----
-7
25
74

query I rowsort
SELECT - - ( - 12 ) * - col1 + - ( + cor0.col1 ) FROM tab2 AS cor0
----
187
341
649

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + 48 col1 FROM tab1 AS cor0
----
-48
-6
-9

query I rowsort
SELECT DISTINCT + 7 + 48 FROM tab0 AS cor0
----
55

query I rowsort
SELECT DISTINCT - col0 + + col2 + - col1 AS col2 FROM tab1 AS cor0
----
-17
25
3

query I rowsort
SELECT ALL + 11 * 42 AS col2 FROM tab2 cor0
----
462
462
462

query I rowsort
SELECT DISTINCT + + 92 AS col0 FROM tab1 AS cor0
----
92

query I rowsort
SELECT + 35 + - col2 + col2 FROM tab0 AS cor0
----
35
35
35

query I rowsort
SELECT ALL col1 + 85 AS col2 FROM tab1 AS cor0
----
111
95
98

query I rowsort
SELECT DISTINCT - col0 + 74 AS col2 FROM tab2 AS cor0
----
-4
-5
67

query I rowsort
SELECT ALL col1 * col1 + + col0 * ( - col0 * - col1 ) + + 42 FROM tab0 AS cor0
----
128276
56974
729134

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 54 + col2 col0 FROM tab0 AS cor0
----
136
55
87

query I rowsort
SELECT + ( + 29 ) * col1 FROM tab1
----
290
377
754

query I rowsort
SELECT ALL ( - 82 ) * + col1 + col2 FROM tab2
----
-1356
-2515
-4812

query I rowsort
SELECT - 41 * - cor0.col0 + col2 AS col2 FROM tab2 AS cor0
----
314
3224
3277

query I rowsort
SELECT ALL ( - col1 ) * - col1 + - 54 AS col2 FROM tab1 AS cor0
----
115
46
622

onlyif mysql # use DIV operator for integer division
query I rowsort label-5622
SELECT col0 * col0 - col2 DIV 22 FROM tab1 AS cor0
----
4094
6396
7

skipif mysql # not compatible
query I rowsort label-5622
SELECT col0 * col0 - col2 / 22 FROM tab1 AS cor0
----
4094
6396
7

query I rowsort
SELECT ALL + 80 + - col2 * - col1 FROM tab2 AS cor0
----
1614
726
917

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5624
SELECT DISTINCT - - CAST( NULL AS SIGNED ) - + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5624
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) - + col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col1 + + col0 * col2 AS col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT ALL - cor0.col1 FROM tab2, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5627
SELECT DISTINCT + CAST( 18 AS SIGNED ) FROM tab1
----
18

skipif mysql # not compatible
query I rowsort label-5627
SELECT DISTINCT + CAST ( 18 AS INTEGER ) FROM tab1
----
18

query I rowsort
SELECT + 21 * col1 AS col2 FROM tab0
----
1806
1911
2037

query I rowsort
SELECT ALL + col2 * - col0 + + col1 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5630
SELECT ALL CAST( NULL AS DECIMAL ) + - ( col1 ) - col1 / - 13 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-5630
SELECT ALL CAST ( NULL AS REAL ) + - ( col1 ) - col1 / - 13 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5631
SELECT ALL + cor0.col1 DIV + col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5631
SELECT ALL + cor0.col1 / + col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT - 74 + col0 FROM tab2 AS cor0
----
-67
4
5

query I rowsort
SELECT DISTINCT + 75 + cor0.col2 * col0 FROM tab1 AS cor0
----
237
3723
7755

query I rowsort
SELECT 26 + + col0 * col0 * 88 + + col1 AS col2 FROM tab0 AS cor0
----
107923
50800
697165

query I rowsort
SELECT + cor0.col1 * - col1 + + col1 * 67 FROM tab2 AS cor0
----
1116
472
850

query I rowsort
SELECT ALL col2 + + col0 * ( - col1 ) AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT - col1 * col2 + - col1 * col2 FROM tab2 AS cor0
----
-1292
-1674
-3068

query I rowsort
SELECT DISTINCT col1 * + col1 * + col1 AS col0 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT - - col2 * + cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL ( - 99 ) + + col1 * + 7 * + col1 AS col2 FROM tab2
----
1924
24268
6628

query I rowsort
SELECT - 27 AS col1 FROM tab2 AS cor0
----
-27
-27
-27

query I rowsort
SELECT cor0.col2 + col0 AS col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col2 * - 71 + - col0 + - col1 * - 63 FROM tab1 AS cor0
----
-2199
-3481
-6077

query I rowsort
SELECT DISTINCT col2 + - 10 FROM tab2 AS cor0
----
16
17
28

query I rowsort
SELECT DISTINCT + col1 - - 91 * - 97 FROM tab2 AS cor0
----
-8768
-8796
-8810

query I rowsort
SELECT ALL + - col2 * + col2 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT + cor0.col0 * + col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - col0 + - col0 * 49 AS col2 FROM tab2 AS cor0
----
-350
-3900
-3950

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT DISTINCT + col1 + 62 FROM tab1 AS cor0
----
72
75
88

query I rowsort
SELECT ALL - col2 - col0 * + 8 FROM tab1 AS cor0
----
-569
-736
-78

query I rowsort
SELECT DISTINCT + col2 * 75 AS col0 FROM tab2 cor0
----
1950
2025
2850

onlyif mysql # use DIV operator for integer division
query I rowsort label-5653
SELECT - 23 DIV col2 + - col2 FROM tab0 AS cor0
----
-24
-33
-82

skipif mysql # not compatible
query I rowsort label-5653
SELECT - 23 / col2 + - col2 FROM tab0 AS cor0
----
-24
-33
-82

query I rowsort
SELECT ALL col2 - + col1 * col2 * col1 FROM tab2
----
-10944
-25920
-90480

query I rowsort
SELECT ALL + col0 - col0 * + tab1.col1 AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL - 97 * col0 + + cor0.col0 FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT + + ( + 16 ) * col1 - + col0 FROM tab0 AS cor0
----
1352
1367
1517

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5658
SELECT DISTINCT col0 * + col2 + + col2 + + CAST( NULL AS SIGNED ) * cor0.col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5658
SELECT DISTINCT col0 * + col2 + + col2 + + CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ( - col2 ) * cor0.col2 - + ( col2 ) FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL - 41 AS col0 FROM tab0 cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 007857b49fbf51962923f3da53f42f2b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT col0 * 89 AS col0 FROM tab0 cor0
----
2136
3115
7921

query I rowsort
SELECT - 45 * col2 AS col2 FROM tab0 AS cor0
----
-1485
-3690
-45

query I rowsort
SELECT - 89 * col0 AS col2 FROM tab1 AS cor0
----
-267
-5696
-7120

onlyif mysql # use DIV operator for integer division
query I rowsort label-5665
SELECT + cor0.col1 DIV col0 AS col0 FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5665
SELECT + cor0.col1 / col0 AS col0 FROM tab2 cor0
----
0
0
4

query I rowsort
SELECT ( - 23 ) FROM tab0, tab1 AS cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT ALL cor0.col0 * ( tab0.col1 ) AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 2e5239e07239fc5e8b7ad998a3c285e1

query I rowsort
SELECT 7 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

onlyif mysql # use DIV operator for integer division
query I rowsort label-5669
SELECT CAST( col1 AS SIGNED ) DIV col0 AS col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5669
SELECT CAST ( col1 AS INTEGER ) / col0 AS col0 FROM tab1 AS cor0
----
0
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5670
SELECT DISTINCT + + col0 + - cor0.col1 DIV col2 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5670
SELECT DISTINCT + + col0 + - cor0.col1 / col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT + col0 + 45 AS col1 FROM tab0 cor0
----
134
69
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col2 col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT - cor0.col0 * - cor0.col2 + 21 AS col2 FROM tab0 AS cor0
----
56
7319
813

query I rowsort
SELECT - + 15 * col1 + - col1 * + col0 FROM tab2 AS cor0
----
-1598
-5487
-682

query I rowsort
SELECT + col0 + col2 * 24 AS col1 FROM tab0 AS cor0
----
2057
59
816

query I rowsort
SELECT - ( cor0.col2 ) * - col2 + col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT ALL + - col0 * col1 * + 19 FROM tab2 AS cor0
----
-25517
-4123
-87438

query I rowsort
SELECT DISTINCT 15 + col2 AS col1 FROM tab1 AS cor0
----
111
69
72

query I rowsort
SELECT DISTINCT + + cor0.col1 + + col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5680
SELECT + 28 DIV cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
26
27
39

skipif mysql # not compatible
query I rowsort label-5680
SELECT + 28 / cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
26
27
39

query I rowsort
SELECT ALL + ( - 89 ) * - col0 + + ( - col1 ) AS col0 FROM tab2
----
592
6883
7014

query I rowsort
SELECT + 68 FROM tab1, tab0 cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

onlyif mysql # use DIV operator for integer division
query I rowsort label-5683
SELECT + 65 DIV - col0 + + 23 * + col0 AS col0 FROM tab0 AS cor0
----
2047
550
804

skipif mysql # not compatible
query I rowsort label-5683
SELECT + 65 / - col0 + + 23 * + col0 AS col0 FROM tab0 AS cor0
----
2047
550
804

query I rowsort
SELECT + col1 + 49 FROM tab1 AS cor0
----
59
62
75

query I rowsort
SELECT ALL col0 + 36 AS col1 FROM tab0 AS cor0
----
125
60
71

query I rowsort
SELECT ALL - + col1 - 25 FROM tab1 AS cor0
----
-35
-38
-51

query I rowsort
SELECT DISTINCT col0 + 75 * col0 FROM tab2 AS cor0
----
532
5928
6004

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5688
SELECT ALL - cor0.col1 / + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5688
SELECT ALL - cor0.col1 / + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - 24 * - 20 AS col0 FROM tab0 AS cor0
----
566
571
577

query I rowsort
SELECT ALL + - col1 - col0 * col1 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - cor0.col0 * - 72 AS col2 FROM tab0 AS cor0
----
1728
2520
6408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col0 * col2 col1 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5693
SELECT ALL - col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5693
SELECT ALL - col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col0 + + col1 + col0 AS col0 FROM tab0 AS cor0
----
134
167
269

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5695
SELECT + - col0 + CAST( - 70 AS SIGNED ) FROM tab2 AS cor0
----
-148
-149
-77

skipif mysql # not compatible
query I rowsort label-5695
SELECT + - col0 + CAST ( - 70 AS INTEGER ) FROM tab2 AS cor0
----
-148
-149
-77

query I rowsort
SELECT - - col1 + ( + col1 ) FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT - col0 + - 63 FROM tab1 AS cor0
----
-127
-143
-66

query I rowsort
SELECT + tab2.col0 + 44 FROM tab2
----
122
123
51

query I rowsort
SELECT DISTINCT + 59 FROM tab2, tab0 cor0
----
59

query I rowsort
SELECT + col2 * + tab2.col0 * + col2 AS col1 FROM tab2
----
114076
5103
52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col1 col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 20 col1 FROM tab2
----
-20
-20
-20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + col2 col0 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT ALL + + 78 * + col2 + + 61 FROM tab1 AS cor0
----
4273
4507
7549

query I rowsort
SELECT ALL 49 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT + + 35 - col2 FROM tab2 AS cor0
----
-3
8
9

query I rowsort
SELECT col2 + col1 * + 27 FROM tab2
----
1619
497
864

query I rowsort
SELECT ALL col1 * tab1.col0 * 15 + 76 FROM tab1
----
1246
15676
9676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5709
SELECT - + col2 DIV col1 - + col1 FROM tab1 AS cor0
----
-15
-20
-28

skipif mysql # not compatible
query I rowsort label-5709
SELECT - + col2 / col1 - + col1 FROM tab1 AS cor0
----
-15
-20
-28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5710
SELECT ALL ( + col2 ) + CAST( NULL AS DECIMAL ) * - col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5710
SELECT ALL ( + col2 ) + CAST ( NULL AS REAL ) * - col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * col2 + - col1 AS col1 FROM tab0 AS cor0
----
-96
1003
6633

onlyif mysql # use DIV operator for integer division
query I rowsort label-5712
SELECT - col0 + col2 DIV - col0 AS col1 FROM tab1 AS cor0
----
-21
-64
-81

skipif mysql # not compatible
query I rowsort label-5712
SELECT - col0 + col2 / - col0 AS col1 FROM tab1 AS cor0
----
-21
-64
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5713
SELECT col0 DIV + col2 + - col2 + - 71 FROM tab0
----
-104
-152
-37

skipif mysql # not compatible
query I rowsort label-5713
SELECT col0 / + col2 + - col2 + - 71 FROM tab0
----
-104
-152
-37

query I rowsort
SELECT DISTINCT + - col1 * col2 + - col0 AS col2 FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL + - col2 + col0 * - cor0.col1 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + col0 + - col2 * col0 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-5717
SELECT ALL + col0 DIV - col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5717
SELECT ALL + col0 / - col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL col2 + col0 * + col0 - 19 AS col0 FROM tab0 AS cor0
----
1207
590
7984

query I rowsort
SELECT DISTINCT - col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5720
SELECT ALL + 16 DIV - 60 + col0 * 92 FROM tab0 AS cor0
----
2208
3220
8188

skipif mysql # not compatible
query I rowsort label-5720
SELECT ALL + 16 / - 60 + col0 * 92 FROM tab0 AS cor0
----
2208
3220
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col2 - - col1 col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT DISTINCT + + cor0.col1 - - cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - 38 ) * cor0.col1 col0 FROM tab0 AS cor0
----
3268
3458
3686

query I rowsort
SELECT + ( - col1 ) + + col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - + ( col2 ) * - col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - ( + 26 ) + + cor0.col1 FROM tab0 AS cor0
----
60
65
71

query I rowsort
SELECT - ( + ( col2 ) ) * cor0.col0 + + 54 * - col2 FROM tab0 AS cor0
----
-11726
-2574
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5728
SELECT ALL - - CAST( NULL AS SIGNED ) * + ( + col1 ) + cor0.col0 + + col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5728
SELECT ALL - - CAST ( NULL AS INTEGER ) * + ( + col1 ) + cor0.col0 + + col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col2 * col2 * col1 + col2 FROM tab0 AS cor0
----
611966
93687
98

query I rowsort
SELECT + 54 + 31 * cor0.col2 AS col1 FROM tab2 AS cor0
----
1232
860
891

query I rowsort
SELECT ALL + - col2 + col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - - 9 * col0 AS col0 FROM tab2 AS cor0
----
63
702
711

query I rowsort
SELECT - 34 * + cor0.col2 FROM tab1 AS cor0
----
-1836
-1938
-3264

query I rowsort
SELECT ALL - cor0.col2 + ( ( cor0.col0 ) * - 76 ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to bea4ced187745ac8b128a4d36b627d1f

query I rowsort
SELECT DISTINCT - cor1.col0 * + cor0.col1 + + 1 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
9 values hashing to 92e2c03bc23e9be583e104994fdc75e8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5736
SELECT col0 / CAST( NULL AS SIGNED ) - col1 / + col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5736
SELECT col0 / CAST ( NULL AS INTEGER ) - col1 / + col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * cor0.col1 + + col0 FROM tab2 cor0
----
-210
-3403
-954

query I rowsort
SELECT DISTINCT 80 FROM tab2, tab1 AS cor0
----
80

query I rowsort
SELECT DISTINCT - col1 * col2 + + col2 + - col0 FROM tab1 AS cor0
----
-1232
-1353
-577

query I rowsort
SELECT DISTINCT + col2 - ( - col2 ) AS col0 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * cor0.col0 * - col1 col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + col2 * 8 AS col2 FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT DISTINCT col0 + 4 AS col0 FROM tab0 AS cor0
----
28
39
93

query I rowsort
SELECT - + col2 * + col2 + ( - col1 ) + + col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - col0 * col1 + + col2 FROM tab1 AS cor0
----
-24
-583
-944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col0 * + 61 col0 FROM tab1 AS cor0
----
209
3914
4893

query I rowsort
SELECT col1 + - col1 * - col2 AS col0 FROM tab2
----
1593
663
868

query I rowsort
SELECT ALL + col1 - + ( + col1 + col1 ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + col2 - ( - ( + col1 ) ) AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT + col0 + tab1.col0 - + col2 * col1 * - col1 FROM tab1
----
16384
36510
5828

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
17
31
59

query I rowsort
SELECT - col2 * + 72 AS col0 FROM tab0
----
-2376
-5904
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 56 + - col1 * - col2 col2 FROM tab2 AS cor0
----
1478
590
781

query I rowsort
SELECT tab2.col1 + + col0 + col2 * - col0 AS col0 FROM tab2
----
-151
-1891
-2906

query I rowsort
SELECT col2 - - 54 AS col1 FROM tab1
----
108
111
150

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - 6 AS REAL ) * col2 col2 FROM tab2 AS cor0
----
156
162
228

onlyif mysql # use DIV operator for integer division
query I rowsort label-5757
SELECT + - CAST( + col1 AS SIGNED ) + col1 DIV + ( - col0 ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-66

skipif mysql # not compatible
query I rowsort label-5757
SELECT + - CAST ( + col1 AS INTEGER ) + col1 / + ( - col0 ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-66

query I rowsort
SELECT 69 - 68 AS col0 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT ALL + ( 50 ) * - col1 FROM tab2
----
-1550
-2950
-850

query I rowsort
SELECT col1 + 10 FROM tab0 AS cor0
----
101
107
96

query I rowsort
SELECT DISTINCT 96 + 65 FROM tab2 AS cor0
----
161

query I rowsort
SELECT ALL - col0 * - col2 * - col2 AS col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-5763
SELECT - CAST( - col0 AS SIGNED ) DIV + col0 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5763
SELECT - CAST ( - col0 AS INTEGER ) / + col0 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT - 11 + + col1 FROM tab2 AS cor0
----
20
48
6

query I rowsort
SELECT + 92 * col2 + + col1 FROM tab2 AS cor0
----
2451
2515
3513

query I rowsort
SELECT DISTINCT - col2 * - tab0.col0 * - col1 AS col1 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT - 82 - col0 * 85 FROM tab1
----
-337
-5522
-6882

query I rowsort
SELECT + col2 * tab1.col0 + col2 FROM tab1
----
216
3705
7776

query I rowsort
SELECT DISTINCT 92 * + col2 FROM tab2 AS cor0
----
2392
2484
3496

query I rowsort
SELECT col0 + col2 * 95 FROM tab1 AS cor0
----
5133
5479
9200

onlyif mysql # use DIV operator for integer division
query I rowsort label-5771
SELECT DISTINCT 73 DIV + cor0.col1 + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5771
SELECT DISTINCT 73 / + cor0.col1 + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + 21 AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

query I rowsort
SELECT - 64 * col1 FROM tab1
----
-1664
-640
-832

query I rowsort
SELECT - cor0.col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT - cor0.col2 * 82 AS col0 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT ALL - col2 + col0 * col2 AS col1 FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT ALL - cor0.col2 * 64 AS col0 FROM tab1 AS cor0
----
-3456
-3648
-6144

query I rowsort
SELECT - tab1.col2 FROM tab1, tab2 cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2, tab2 AS cor3
----
3645 values hashing to 713ff9f9cde43214a064a8e6ada00f4e

query I rowsort
SELECT col1 * - 76 AS col0 FROM tab0 AS cor0
----
-6536
-6916
-7372

onlyif mysql # use DIV operator for integer division
query I rowsort label-5781
SELECT - col0 DIV + 91 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5781
SELECT - col0 / + 91 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 * 26 FROM tab2 AS cor0
----
-1534
-442
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5783
SELECT col0 DIV - ( + col2 ) AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5783
SELECT col0 / - ( + col2 ) AS col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT + 85 * - col0 FROM tab2
----
-595
-6630
-6715

query I rowsort
SELECT - 71 * + 57 FROM tab2
----
-4047
-4047
-4047

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5786
SELECT - CAST( - ( col0 ) AS SIGNED ) AS col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5786
SELECT - CAST ( - ( col0 ) AS INTEGER ) AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT col0 * 60 AS col1 FROM tab1
----
180
3840
4800

query I rowsort
SELECT DISTINCT 72 + 81 * col2 FROM tab2 AS cor0
----
2178
2259
3150

query I rowsort
SELECT - 57 + - col2 FROM tab1 AS cor0
----
-111
-114
-153

query I rowsort
SELECT DISTINCT - 36 FROM tab1, tab0 AS cor0
----
-36

query I rowsort
SELECT + - ( + col2 ) AS col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT 97 + col2 FROM tab1 cor0
----
151
154
193

query I rowsort
SELECT DISTINCT - 83 AS col2 FROM tab2
----
-83

query I rowsort
SELECT - col2 * - col2 + cor0.col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + 8 + col2 * - 21 FROM tab0 AS cor0
----
-13
-1714
-685

onlyif mysql # use DIV operator for integer division
query I rowsort label-5796
SELECT 72 DIV col2 AS col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-5796
SELECT 72 / col2 AS col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT ALL + col1 * + col1 + - 36 * cor0.col0 FROM tab2 AS cor0
----
-2555
673
709

query I rowsort
SELECT col0 * + col0 + + cor0.col1 * - col0 * col1 AS col2 FROM tab0 AS cor0
----
-176928
-328090
-729088

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5799
SELECT DISTINCT - col2 + CAST( NULL AS SIGNED ) + - col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5799
SELECT DISTINCT - col2 + CAST ( NULL AS INTEGER ) + - col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 - 71 col1 FROM tab0 AS cor0
----
26
2767
7391

query I rowsort
SELECT + col1 * - ( col0 ) - + cor0.col0 FROM tab2 AS cor0
----
-1422
-224
-4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5802
SELECT - - col0 DIV col1 - - col1 AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5802
SELECT - - col0 / col1 - - col1 AS col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5803
SELECT ALL + - col2 * + CAST( NULL AS SIGNED ) - - cor0.col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5803
SELECT ALL + - col2 * + CAST ( NULL AS INTEGER ) - - cor0.col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 + + cor0.col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + col2 * 89 FROM tab2 AS cor0
----
2314
2403
3382

query I rowsort
SELECT + + ( - 78 ) + col0 + - ( 29 + + col2 ) AS col2 FROM tab0 AS cor0
----
-100
-116
-73

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col1 AS REAL ) + col1 * col1 + col1 FROM tab1 AS cor0
----
120
195
728

query I rowsort
SELECT - + 56 FROM tab1 AS cor0
----
-56
-56
-56

query I rowsort
SELECT col2 - + col0 * - col0 AS col1 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT - col2 * - 49 + cor0.col1 * 26 FROM tab1 cor0
----
3053
3322
5042

query I rowsort
SELECT + + 46 * col1 * col1 + + cor0.col1 FROM tab2 AS cor0
----
13311
160185
44237

query I rowsort
SELECT col2 * - 46 - - col2 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-2079
-2394
-2730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 3 * - 53 * col2 col0 FROM tab1 AS cor0
----
-15264
-8586
-9063

query I rowsort
SELECT + 66 * col2 + col1 - + cor0.col0 FROM tab0 cor0
----
128
2240
5414

query I rowsort
SELECT ALL + 25 + + ( + col2 ) * col1 FROM tab2 AS cor0
----
1559
671
862

query I rowsort
SELECT col2 + + col1 * + col2 * col1 AS col0 FROM tab1 AS cor0
----
16320
36558
5757

query I rowsort
SELECT DISTINCT - col0 + - col1 * col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-5818
SELECT ALL col0 DIV + col2 + + col0 - 28 AS col0 FROM tab1 AS cor0
----
-25
37
52

skipif mysql # not compatible
query I rowsort label-5818
SELECT ALL col0 / + col2 + + col0 - 28 AS col0 FROM tab1 AS cor0
----
-25
37
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 col1 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + + 13 * col0 AS col2 FROM tab0 AS cor0
----
1157
312
455

query I rowsort
SELECT + ( col2 ) - tab1.col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - col0 * - 88 AS col0 FROM tab1 AS cor0
----
264
5632
7040

query I rowsort
SELECT ALL + col1 + 51 FROM tab0 AS cor0
----
137
142
148

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * 26 col1 FROM tab2 AS cor0
----
-182
-2028
-2054

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5825
SELECT DISTINCT - cor0.col0 * CAST( + 24 AS SIGNED ) FROM tab1 AS cor0
----
-1536
-1920
-72

skipif mysql # not compatible
query I rowsort label-5825
SELECT DISTINCT - cor0.col0 * CAST ( + 24 AS INTEGER ) FROM tab1 AS cor0
----
-1536
-1920
-72

query I rowsort
SELECT DISTINCT cor0.col2 * col2 * - col1 AS col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-5827
SELECT DISTINCT + 72 DIV col0 AS col0 FROM tab1
----
0
1
24

skipif mysql # not compatible
query I rowsort label-5827
SELECT DISTINCT + 72 / col0 AS col0 FROM tab1
----
0
1
24

query I rowsort
SELECT + 82 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT + col0 + col2 * - 76 FROM tab1 AS cor0
----
-4101
-4268
-7216

query I rowsort
SELECT + col1 + - ( col0 ) FROM tab2
----
-19
-62
24

query I rowsort
SELECT + col0 + 68 FROM tab0
----
103
157
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 * + 97 col0 FROM tab0
----
3395
707906
76824

query I rowsort
SELECT - col0 * - tab0.col2 + 82 FROM tab0
----
117
7380
874

query I rowsort
SELECT ALL + col1 + col2 * col2 FROM tab0
----
1175
6815
98

query I rowsort
SELECT ALL + col1 * cor0.col1 AS col2 FROM tab1 cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 71 + + col0 col2 FROM tab2 AS cor0
----
149
150
78

query I rowsort
SELECT DISTINCT - + col0 + col0 * ( - cor0.col2 ) AS col2 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT - 78 * col1 + ( + cor0.col0 * col1 ) FROM tab1 AS cor0
----
-140
-1950
26

skipif mysql # not compatible
query I rowsort
SELECT ALL + col2 * col0 - CAST ( + ( + col1 ) * - col2 AS REAL ) AS col0 FROM tab1 cor0
----
1566
4218
8928

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col0 * - cor0.col2 - + col1 FROM tab1 AS cor0
----
-188
-3658
-7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-5842
SELECT ALL - ( - cor0.col1 ) DIV col0 col0 FROM tab0 AS cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5842
SELECT ALL - ( - cor0.col1 ) / col0 col0 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5843
SELECT ALL col1 * + CAST( + 80 AS SIGNED ) FROM tab2 cor0
----
1360
2480
4720

skipif mysql # not compatible
query I rowsort label-5843
SELECT ALL col1 * + CAST ( + 80 AS INTEGER ) FROM tab2 cor0
----
1360
2480
4720

query I rowsort
SELECT ALL - col0 + col2 * ( col2 ) FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT col0 - cor0.col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT col1 * + 84 + col2 FROM tab0 AS cor0
----
7257
7726
8149

query I rowsort
SELECT DISTINCT col0 * - col2 * col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5848
SELECT DISTINCT - - col0 DIV col2 AS col0 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5848
SELECT DISTINCT - - col0 / col2 AS col0 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT cor0.col2 * col0 + + col2 + col0 * + col0 * 79 AS col1 FROM tab1 AS cor0
----
327289
513376
927

query I rowsort
SELECT DISTINCT + col0 * col1 + - col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT col0 * 23 AS col0 FROM tab2 AS cor0
----
161
1794
1817

query I rowsort
SELECT DISTINCT - cor0.col2 + - cor0.col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT + ( + ( col1 ) ) + - 11 FROM tab2 cor0
----
20
48
6

query I rowsort
SELECT DISTINCT - 19 AS col0 FROM tab2, tab0 AS cor0
----
-19

query I rowsort
SELECT + col1 + tab2.col2 * - tab2.col2 AS col0 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT ( + col1 + col2 ) FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT 18 + + col2 AS col1 FROM tab0 AS cor0
----
100
19
51

query I rowsort
SELECT DISTINCT + 42 * - cor0.col1 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT ALL col1 + + col2 AS col0 FROM tab1 cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5860
SELECT DISTINCT + col1 DIV + col0 AS col1 FROM tab1 cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-5860
SELECT DISTINCT + col1 / + col0 AS col1 FROM tab1 cor0
----
0
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5861
SELECT ALL col1 + - col2 * - CAST( NULL AS SIGNED ) * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5861
SELECT ALL col1 + - col2 * - CAST ( NULL AS INTEGER ) * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * col2 + 76 FROM tab0 AS cor0
----
-716
-7222
41

query I rowsort
SELECT ( + col2 ) + - 14 AS col1 FROM tab2 AS cor0
----
12
13
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5864
SELECT ALL + col1 * col0 + CAST( + col1 AS SIGNED ) FROM tab0 AS cor0
----
2150
3492
8190

skipif mysql # not compatible
query I rowsort label-5864
SELECT ALL + col1 * col0 + CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + + 8 * cor0.col0 * 22 + + 84 AS col2 FROM tab0 AS cor0
----
15748
4308
6244

query I rowsort
SELECT ALL + - 37 FROM tab0 AS cor0
----
-37
-37
-37

onlyif mysql # use DIV operator for integer division
query I rowsort label-5867
SELECT + - col0 * col0 DIV - col2 FROM tab0 AS cor0
----
1225
17
96

skipif mysql # not compatible
query I rowsort label-5867
SELECT + - col0 * col0 / - col2 FROM tab0 AS cor0
----
1225
17
96

query I rowsort
SELECT - 58 AS col2 FROM tab0
----
-58
-58
-58

query I rowsort
SELECT - ( - col2 + - tab2.col1 ) AS col1 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL + - col0 + col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT col2 * - cor0.col2 + + col2 * - col2 FROM tab0 AS cor0
----
-13448
-2
-2178

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5872
SELECT ALL CAST( NULL AS SIGNED ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5872
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - col1 * + tab0.col1 + tab0.col2 AS col2 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT col1 * col1 * + 95 + col2 * - col1 * tab0.col1 FROM tab0
----
107653
458552
884446

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + 22 col0 FROM tab1 AS cor0
----
-4
12
9

query I rowsort
SELECT ALL col2 + + col1 * - col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT + tab2.col2 + + col1 AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL + + col1 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + cor0.col2 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT col0 * 15 FROM tab1 AS cor0
----
1200
45
960

query I rowsort
SELECT col1 * + col1 + + cor0.col1 FROM tab1 cor0
----
110
182
702

query I rowsort
SELECT ALL col1 + 31 * + col0 FROM tab2
----
2466
2477
248

query I rowsort
SELECT ALL col0 + 38 AS col1 FROM tab1
----
102
118
41

query I rowsort
SELECT col2 * + col0 * - col1 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT - 35 * col2 FROM tab0
----
-1155
-2870
-35

query I rowsort
SELECT DISTINCT - - col2 + - col1 * + col1 AS col0 FROM tab2 cor0
----
-251
-3455
-934

onlyif mysql # use DIV operator for integer division
query I rowsort label-5887
SELECT col0 * 14 DIV - col0 + + 21 + - col0 FROM tab1 AS cor0
----
-57
-73
4

skipif mysql # not compatible
query I rowsort label-5887
SELECT col0 * 14 / - col0 + + 21 + - col0 FROM tab1 AS cor0
----
-57
-73
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + col2 + - col0 col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT col1 * col0 * col2 AS col1 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5890
SELECT + - CAST( col1 AS SIGNED ) * col0 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-5890
SELECT + - CAST ( col1 AS INTEGER ) * col0 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5891
SELECT DISTINCT - - 50 + - 53 DIV + cor0.col0 AS col1 FROM tab1 AS cor0
----
33
50

skipif mysql # not compatible
query I rowsort label-5891
SELECT DISTINCT - - 50 + - 53 / + cor0.col0 AS col1 FROM tab1 AS cor0
----
33
50

query I rowsort
SELECT ALL - + cor0.col0 + - 57 FROM tab1 AS cor0
----
-121
-137
-60

query I rowsort
SELECT - col1 * ( + col2 ) - col1 * + ( - col0 ) FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT col0 * + ( + cor0.col2 ) + - col2 AS col2 FROM tab1 cor0
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + + 60 col1 FROM tab2, tab2 cor0
----
9 values hashing to 0c4e629da9ab538f0a0ed876800eb49e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5896
SELECT ALL - - col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5896
SELECT ALL - - col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 17 FROM tab1, tab1 cor0, tab0 cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT + col2 * - 91 FROM tab1
----
-4914
-5187
-8736

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 45 + 51 * - col0 col2 FROM tab1 AS cor0
----
-108
-3219
-4035

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * 0 col0 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5901
SELECT + col1 DIV + col1 - col2 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-5901
SELECT + col1 / + col1 - col2 FROM tab1
----
-53
-56
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5902
SELECT + CAST( NULL AS SIGNED ) + - cor0.col0 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5902
SELECT + CAST ( NULL AS INTEGER ) + - cor0.col0 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col2 * - ( col0 ) FROM tab0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5904
SELECT + CAST( NULL AS SIGNED ) col1 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5904
SELECT + CAST ( NULL AS INTEGER ) col1 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + 29 * - col2 col0 FROM tab2
----
-1064
-728
-756

onlyif mysql # use DIV operator for integer division
query I rowsort label-5906
SELECT + col0 + + col1 DIV 91 FROM tab0 AS cor0
----
24
36
90

skipif mysql # not compatible
query I rowsort label-5906
SELECT + col0 + + col1 / 91 FROM tab0 AS cor0
----
24
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5907
SELECT DISTINCT col1 DIV col0 col1 FROM tab1
----
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5907
SELECT DISTINCT col1 / col0 col1 FROM tab1
----
0
8

query I rowsort
SELECT DISTINCT + tab0.col1 AS col2 FROM tab0, tab0 cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5909
SELECT ( col2 ) DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5909
SELECT ( col2 ) / col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 32 + cor0.col0 col1 FROM tab0 AS cor0
----
121
56
67

query I rowsort
SELECT DISTINCT 28 * + col2 * col1 AS col2 FROM tab0
----
208936
2716
79464

query I rowsort
SELECT col0 + col1 * 80 FROM tab1
----
1120
2083
864

query I rowsort
SELECT DISTINCT ( col1 ) * - 29 * col1 AS col1 FROM tab2
----
-100949
-27869
-8381

query I rowsort
SELECT DISTINCT + 66 FROM tab0, tab2, tab0 cor0
----
66

query I rowsort
SELECT 77 + col2 * - 88 FROM tab0
----
-11
-2827
-7139

onlyif mysql # use DIV operator for integer division
query I rowsort label-5916
SELECT - col2 * col0 DIV col0 + cor0.col1 DIV col2 col0 FROM tab0 AS cor0
----
-31
-81
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5916
SELECT - col2 * col0 / col0 + cor0.col1 / col2 col0 FROM tab0 AS cor0
----
-31
-81
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5917
SELECT DISTINCT + - cor0.col1 * CAST( - ( - col0 ) AS SIGNED ) FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-5917
SELECT DISTINCT + - cor0.col1 * CAST ( - ( - col0 ) AS INTEGER ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + col2 * + col2 * ( col1 ) FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5919
SELECT DISTINCT - col0 DIV col0 col1 FROM tab1 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5919
SELECT DISTINCT - col0 / col0 col1 FROM tab1 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5920
SELECT + + col2 * - col0 - - col0 DIV + col1 FROM tab2 AS cor0
----
-189
-2027
-2998

skipif mysql # not compatible
query I rowsort label-5920
SELECT + + col2 * - col0 - - col0 / + col1 FROM tab2 AS cor0
----
-189
-2027
-2998

query I rowsort
SELECT ALL col0 * 28 AS col1 FROM tab1 cor0
----
1792
2240
84

query I rowsort
SELECT col2 * - 54 FROM tab0
----
-1782
-4428
-54

query I rowsort
SELECT DISTINCT + col0 * 40 + - 17 FROM tab0 AS cor0
----
1383
3543
943

onlyif mysql # use DIV operator for integer division
query I rowsort label-5924
SELECT - - col1 DIV col1 AS col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5924
SELECT - - col1 / col1 AS col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT + - col1 - 16 AS col2 FROM tab2 AS cor0
----
-33
-47
-75

query I rowsort
SELECT ALL col2 + + col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT - col1 + - 76 FROM tab0 AS cor0
----
-162
-167
-173

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - ( + 96 ) + cor0.col1 - col2 * col0 col0 FROM tab1 AS cor0
----
13
152
2506

query I rowsort
SELECT - col0 * cor0.col0 AS col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT + - col1 * + col0 * col2 + col2 * + col2 AS col1 FROM tab1 AS cor0
----
-1296
-33231
-90624

query I rowsort
SELECT 68 * col2 + tab1.col0 * - col1 AS col2 FROM tab1
----
3236
3594
5488

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5932
SELECT + CAST( NULL AS SIGNED ) + cor0.col1 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5932
SELECT + CAST ( NULL AS INTEGER ) + cor0.col1 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 * 15 FROM tab0 AS cor0
----
-1290
-1365
-1455

onlyif mysql # use DIV operator for integer division
query I rowsort label-5934
SELECT ALL + - col0 DIV + col1 + col2 * 32 AS col0 FROM tab2 AS cor0
----
1212
831
864

skipif mysql # not compatible
query I rowsort label-5934
SELECT ALL + - col0 / + col1 + col2 * 32 AS col0 FROM tab2 AS cor0
----
1212
831
864

query I rowsort
SELECT DISTINCT col0 * - 51 + - col2 FROM tab1 AS cor0
----
-207
-3321
-4176

query I rowsort
SELECT ALL col0 * - 28 * - cor0.col1 + + col1 * col0 FROM tab0 cor0
----
234871
59856
98455

query I rowsort
SELECT ALL 50 - - cor0.col1 AS col1 FROM tab2 AS cor0
----
109
67
81

query I rowsort
SELECT DISTINCT + col1 - - col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 23 col0 FROM tab2 cor0
----
23
23
23

query I rowsort
SELECT ALL col0 * col0 - col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT + ( - 16 ) AS col2 FROM tab1 AS cor0
----
-16
-16
-16

query I rowsort
SELECT DISTINCT + 26 * col2 FROM tab0 AS cor0
----
2132
26
858

query I rowsort
SELECT ALL - 29 + + cor0.col1 FROM tab0 AS cor0
----
57
62
68

query I rowsort
SELECT ALL + col2 * - cor0.col2 + - col1 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT ALL - + 87 + + col1 * col0 AS col1 FROM tab2 AS cor0
----
1256
130
4515

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5946
SELECT CAST( - 36 AS SIGNED ) FROM tab0
----
-36
-36
-36

skipif mysql # not compatible
query I rowsort label-5946
SELECT CAST ( - 36 AS INTEGER ) FROM tab0
----
-36
-36
-36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5947
SELECT + + 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-5947
SELECT + + CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col0 ) * cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + - col2 * + cor0.col0 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - + col1 * + 24 AS col1 FROM tab0 AS cor0
----
-2064
-2184
-2328

query I rowsort
SELECT + col2 * + col1 * cor0.col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT DISTINCT + ( - 14 ) * + col2 AS col2 FROM tab0 AS cor0
----
-1148
-14
-462

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5953
SELECT - CAST( col0 AS SIGNED ) * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-5953
SELECT - CAST ( col0 AS INTEGER ) * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 * ( col1 ) + col0 FROM tab1
----
164
249
679

query I rowsort
SELECT DISTINCT + tab1.col2 * ( col0 ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT col2 * + col0 + 93 FROM tab2
----
2121
282
3095

query I rowsort
SELECT - col2 + 93 FROM tab1
----
-3
36
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5958
SELECT CAST( col0 AS SIGNED ) * + tab0.col2 + + 12 AS col0 FROM tab0
----
47
7310
804

skipif mysql # not compatible
query I rowsort label-5958
SELECT CAST ( col0 AS INTEGER ) * + tab0.col2 + + 12 AS col0 FROM tab0
----
47
7310
804

query I rowsort
SELECT ALL + col0 + - 57 FROM tab1
----
-54
23
7

query I rowsort
SELECT ALL + col0 * - ( col1 ) + col2 AS col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT DISTINCT cor0.col1 * 86 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
1118
2236
860

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5962
SELECT DISTINCT - CAST( 47 AS SIGNED ) + - col0 * col1 FROM tab1 cor0
----
-1087
-125
-687

skipif mysql # not compatible
query I rowsort label-5962
SELECT DISTINCT - CAST ( 47 AS INTEGER ) + - col0 * col1 FROM tab1 cor0
----
-1087
-125
-687

query I rowsort
SELECT + 92 + 72 AS col1 FROM tab0 AS cor0
----
164
164
164

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col2 + cor0.col0 * + col1 + col0 col2 FROM tab2 AS cor0
----
-613
3146
776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5965
SELECT ALL - - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5965
SELECT ALL - - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 28 + 80 AS col2 FROM tab1 AS cor0
----
108

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5967
SELECT ALL col0 * + ( col1 ) * CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
22831
271518
6727

skipif mysql # not compatible
query I rowsort label-5967
SELECT ALL col0 * + ( col1 ) * CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT DISTINCT + 65 AS col2 FROM tab0
----
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5969
SELECT DISTINCT - 63 * + tab1.col1 - - CAST( NULL AS SIGNED ) FROM tab1, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5969
SELECT DISTINCT - 63 * + tab1.col1 - - CAST ( NULL AS INTEGER ) FROM tab1, tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL 7 + + tab1.col1 * col2 + + 20 FROM tab1
----
1275
1431
597

query I rowsort
SELECT - - col1 + 63 AS col2 FROM tab0 AS cor0
----
149
154
160

query I rowsort
SELECT ALL - cor1.col2 AS col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT - - col2 + col0 * + cor0.col0 * - col0 + cor0.col1 FROM tab2 AS cor0
----
-285
-474467
-492984

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5974
SELECT + + cor0.col0 + col2 + - CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5974
SELECT + + cor0.col0 + col2 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 * + col2 + - 1 AS col0 FROM tab2 AS cor0
----
-1445
-677
-730

query I rowsort
SELECT + 90 * + tab2.col0 + - ( col2 ) AS col2 FROM tab2
----
603
6994
7072

query I rowsort
SELECT DISTINCT - tab1.col1 * col2 AS col2 FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * col0 col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + col1 + + ( 80 ) FROM tab0 AS cor0
----
166
171
177

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
-54
-57
-96

query I rowsort
SELECT ALL - 8 + - cor0.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 10c5f18f56648b9d119d7fe2ef0eec12

query I rowsort
SELECT - col0 * col2 + cor0.col0 * col1 AS col2 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT ALL col2 * 82 + col0 * col2 AS col0 FROM tab2 AS cor0
----
2403
4160
6118

query I rowsort
SELECT cor0.col0 + ( 79 ) AS col0 FROM tab1 AS cor0
----
143
159
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5985
SELECT col2 DIV - 54 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5985
SELECT col2 / - 54 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col0 + col0 * - col2 AS col0 FROM tab1 AS cor0
----
-165
-3712
-7760

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab1 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to ed0ce6de90f51f6f9035da5f66a6f197

query I rowsort
SELECT - + col2 * + 15 AS col1 FROM tab1 AS cor0
----
-1440
-810
-855

onlyif mysql # use DIV operator for integer division
query I rowsort label-5989
SELECT + + col1 DIV + col0 AS col2 FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5989
SELECT + + col1 / + col0 AS col2 FROM tab2 cor0
----
0
0
4

query I rowsort
SELECT col2 * col1 + 44 FROM tab1 AS cor0
----
1292
1448
614

query I rowsort
SELECT DISTINCT - - cor0.col2 + cor0.col0 AS col1 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 - 0 col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL col2 * - col2 + - col1 * + ( cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-2787
-5278
-946

query I rowsort
SELECT tab1.col0 * + col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL + col2 + - col2 - col0 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5996
SELECT - 40 * - col1 + + 64 DIV + 76 FROM tab0 AS cor0
----
3440
3640
3880

skipif mysql # not compatible
query I rowsort label-5996
SELECT - 40 * - col1 + + 64 / + 76 FROM tab0 AS cor0
----
3440
3640
3880

query I rowsort
SELECT 67 * col1 - col0 * - col2 AS col0 FROM tab2 AS cor0
----
2266
4141
5981

query I rowsort
SELECT ALL col0 + + col0 * 26 + col1 * - col2 FROM tab2 AS cor0
----
-648
1487
572

query I rowsort
SELECT - col2 + - 81 AS col1 FROM tab1 cor0
----
-135
-138
-177

onlyif mysql # use DIV operator for integer division
query I rowsort label-6000
SELECT + tab2.col0 DIV + tab2.col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to ee52f9b4c9d252c357ebca3161ec6918

skipif mysql # not compatible
query I rowsort label-6000
SELECT + tab2.col0 / + tab2.col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to ee52f9b4c9d252c357ebca3161ec6918

query I rowsort
SELECT - 78 AS col0 FROM tab0
----
-78
-78
-78

query I rowsort
SELECT ALL + 10 * - col2 + - col0 AS col0 FROM tab0
----
-354
-45
-909

query I rowsort
SELECT DISTINCT + 70 FROM tab2, tab1, tab0 AS cor0
----
70

query I rowsort
SELECT - 50 FROM tab0 cor0
----
-50
-50
-50

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL > col2 / col0 + - col1
----

query I rowsort
SELECT ALL - + col2 + - col0 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + - col2 * + ( + col0 ) + + col2 + col1 * col2 FROM tab1 AS cor0
----
-3021
-6336
1296

query I rowsort
SELECT DISTINCT + col2 + + cor0.col0 + + col2 AS col1 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT col2 + 29 FROM tab0 AS cor0
----
111
30
62

query I rowsort
SELECT - - col0 + - 38 FROM tab0 cor0
----
-14
-3
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6011
SELECT DISTINCT col0 * + CAST( - ( - col0 ) AS SIGNED ) FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-6011
SELECT DISTINCT col0 * + CAST ( - ( - col0 ) AS INTEGER ) FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - 13 AS col0 FROM tab1
----
-13
-13
-13

query I rowsort
SELECT col1 AS col0 FROM tab2 WHERE NOT - col0 <> NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT IN ( - col1 * - col2 + tab2.col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL IN ( tab0.col1 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL NOT IN ( col1 * + tab1.col0 + col0 / col0 )
----

query I rowsort
SELECT DISTINCT tab2.col2 AS col1 FROM tab2 WHERE col1 IN ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 * + tab0.col2 + col0 col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL + col2 FROM tab2 WHERE ( NULL ) NOT BETWEEN - col2 - col2 * col2 AND ( - col1 / - col0 )
----

query I rowsort
SELECT + col2 * + col0 - col2 FROM tab1
----
108
3591
7584

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL BETWEEN NULL AND + col1 + col2 * col0 / col2 + - col1
----

query I rowsort
SELECT col2 * col2 + - col0 * col1 AS col2 FROM tab1
----
2609
2838
8176

query I rowsort
SELECT col2 * + col0 * + col2 AS col1 FROM tab1 WHERE NOT + col0 BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL col2 AS col2 FROM tab0 WHERE ( - col1 ) >= col2
----

query I rowsort
SELECT - col1 + tab1.col2 * + tab1.col1 AS col2 FROM tab1
----
1235
1378
560

query I rowsort
SELECT ALL + col2 - col0 FROM tab2
----
-41
-52
20

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) <> - col0 + + col1 * - col0 / col2
----

query I rowsort
SELECT ALL col1 - col0 * col0 FROM tab1
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-6029
SELECT ALL col2 DIV + col0 + tab2.col0 AS col0 FROM tab2
----
10
78
79

skipif mysql # not compatible
query I rowsort label-6029
SELECT ALL col2 / + col0 + tab2.col0 AS col0 FROM tab2
----
10
78
79

query I rowsort
SELECT - col2 + + col0 * col1 AS col0 FROM tab0
----
2031
3394
8017

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT - col0 = ( NULL )
----

query I rowsort
SELECT - 96 AS col1 FROM tab0
----
-96
-96
-96

query I rowsort
SELECT DISTINCT - 5 + - col2 FROM tab0 cor0
----
-38
-6
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6034
SELECT ALL + cor0.col0 * col0 + CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
6110
6279
76

skipif mysql # not compatible
query I rowsort label-6034
SELECT ALL + cor0.col0 * col0 + CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL - + 10 * + col2 FROM tab2 cor0
----
-260
-270
-380

onlyif mysql # use DIV operator for integer division
query I rowsort label-6036
SELECT col2 - + col2 DIV col2 AS col1 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-6036
SELECT col2 - + col2 / col2 AS col1 FROM tab1
----
53
56
95

query I rowsort
SELECT DISTINCT + col1 * - tab0.col2 + tab0.col0 * - 16 AS col1 FROM tab0
----
-3222
-657
-8886

query I rowsort
SELECT ALL col1 + 36 FROM tab1
----
46
49
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6039
SELECT - tab1.col1 + + col2 * col0 DIV + tab1.col1 AS col2 FROM tab1
----
-20
354
577

skipif mysql # not compatible
query I rowsort label-6039
SELECT - tab1.col1 + + col2 * col0 / + tab1.col1 AS col2 FROM tab1
----
-20
354
577

query I rowsort
SELECT + col1 * + col1 * 38 FROM tab2 AS cor0
----
10982
132278
36518

query I rowsort
SELECT - tab2.col2 - - col0 FROM tab2
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6042
SELECT ALL - cor0.col2 DIV col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-6042
SELECT ALL - cor0.col2 / col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT + 69 * col2 AS col0 FROM tab0 AS cor0
----
2277
5658
69

query I rowsort
SELECT ALL + 66 FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT + + cor1.col2 + + cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b24047a4766c1dbbfa5abb9df45d1883

query I rowsort
SELECT DISTINCT + tab1.col1 * 46 * - col2 + - col2 + 98 * ( tab1.col2 ) FROM tab1
----
-20691
-48096
-59346

query I rowsort
SELECT - tab0.col2 * - ( - col1 ) * + tab0.col2 AS col2 FROM tab0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * ( - col1 ) + + col1 * col2 col1 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT col0 + 84 * col0 AS col0 FROM tab0 cor0
----
2040
2975
7565

query I rowsort
SELECT + col2 + + 13 * - col0 FROM tab1 AS cor0
----
-775
-944
15

query I rowsort
SELECT + col0 - - ( + 64 ) * - col0 AS col2 FROM tab0 AS cor0
----
-1512
-2205
-5607

query I rowsort
SELECT + ( + 86 ) * cor0.col1 FROM tab1 cor0
----
1118
2236
860

query I rowsort
SELECT - + 44 FROM tab0 cor0
----
-44
-44
-44

query I rowsort
SELECT - 17 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT DISTINCT ( - 71 ) AS col2 FROM tab2 AS cor0
----
-71

query I rowsort
SELECT DISTINCT ( + col2 ) + + col1 * 3 FROM tab2 AS cor0
----
120
203
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6057
SELECT DISTINCT + + ( 18 ) + col2 * CAST( 73 AS SIGNED ) FROM tab1 AS cor0
----
3960
4179
7026

skipif mysql # not compatible
query I rowsort label-6057
SELECT DISTINCT + + ( 18 ) + col2 * CAST ( 73 AS INTEGER ) FROM tab1 AS cor0
----
3960
4179
7026

onlyif mysql # use DIV operator for integer division
query I rowsort label-6058
SELECT col0 DIV - 45 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6058
SELECT col0 / - 45 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL + 41 + col1 + - cor0.col1 * col1 * + col0 AS col2 FROM tab2 AS cor0
----
-22773
-271418
-6655

query I rowsort
SELECT ALL + 63 + cor0.col0 + - col1 FROM tab0 AS cor0
----
1
1
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 86 * - col1 col1 FROM tab0 AS cor0
----
-7396
-7826
-8342

query I rowsort
SELECT ALL ( - cor0.col1 ) AS col1 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - col1 * col2 + cor0.col1 * + col0 AS col1 FROM tab2 AS cor0
----
-620
3068
697

query I rowsort
SELECT DISTINCT 31 FROM tab2 cor0
----
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 81 col2 FROM tab2 AS cor0
----
81
81
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 col2 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6067
SELECT - col1 DIV col0 + col1 * col1 col2 FROM tab0 cor0
----
7393
8280
9407

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6067
SELECT - col1 / col0 + col1 * col1 col2 FROM tab0 cor0
----
7393
8280
9407

query I rowsort
SELECT ALL 67 + tab0.col1 FROM tab0
----
153
158
164

query I rowsort
SELECT ( col0 ) - + col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT + ( col1 ) * tab0.col2 * - col1 - col0 * + tab0.col1 AS col2 FROM tab0
----
-12804
-246132
-687141

query I rowsort
SELECT DISTINCT 51 * col1 + - col2 - col1 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-3043
-3722
-4463

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * col0 + col2 col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - + col0 + cor0.col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT DISTINCT - 60 * + cor0.col1 * col1 + - cor0.col2 + - cor0.col1 * + col2 FROM tab1 AS cor0
----
-11484
-42018
-6627

query I rowsort
SELECT DISTINCT - ( - col0 ) - - col2 AS col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT 21 * + col0 AS col0 FROM tab0 AS cor0
----
1869
504
735

query I rowsort
SELECT ALL ( - col0 + col2 ) FROM tab0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( ( col0 ) ) - - col0 col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + + 19 * 44 AS col1 FROM tab0 AS cor0
----
836
836
836

query I rowsort
SELECT DISTINCT col0 - col0 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL col1 - + tab2.col0 AS col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT DISTINCT + + 37 FROM tab1 AS cor0
----
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6083
SELECT DISTINCT - CAST( NULL AS DECIMAL ) * + col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6083
SELECT DISTINCT - CAST ( NULL AS REAL ) * + col0 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + 22 * + ( col0 * + col2 ) AS col1 FROM tab0 AS cor0
----
160556
17424
770

query I rowsort
SELECT ALL col2 * + col0 * col2 FROM tab2 cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT tab2.col1 + col2 + + 10 FROM tab2
----
65
68
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6087
SELECT ALL - col2 DIV + tab2.col0 - col1 FROM tab2
----
-17
-34
-59

skipif mysql # not compatible
query I rowsort label-6087
SELECT ALL - col2 / + tab2.col0 - col1 FROM tab2
----
-17
-34
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6088
SELECT + ( col0 ) + - col2 * tab2.col1 DIV col0 FROM tab2
----
-112
59
71

skipif mysql # not compatible
query I rowsort label-6088
SELECT + ( col0 ) + - col2 * tab2.col1 / col0 FROM tab2
----
-112
59
71

query I rowsort
SELECT ALL col1 + - 38 FROM tab2
----
-21
-7
21

query I rowsort
SELECT DISTINCT + 38 + - col1 * col1 FROM tab0
----
-7358
-8243
-9371

onlyif mysql # use DIV operator for integer division
query I rowsort label-6091
SELECT + col0 + + col1 DIV col0 col2 FROM tab1 AS cor0
----
11
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6091
SELECT + col0 + + col1 / col0 col2 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT + col0 * ( col0 ) AS col2 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6093
SELECT ( col1 ) * col2 + + col2 DIV col0 FROM tab1 AS cor0
----
1249
1422
570

skipif mysql # not compatible
query I rowsort label-6093
SELECT ( col1 ) * col2 + + col2 / col0 FROM tab1 AS cor0
----
1249
1422
570

query I rowsort
SELECT DISTINCT - 94 * 68 FROM tab0 AS cor0
----
-6392

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col0 FROM tab2, tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL col1 + col2 + + col1 FROM tab0 WHERE NOT NULL <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 + tab1.col1 col2 FROM tab1
----
1261
1430
580

query I rowsort
SELECT DISTINCT - tab0.col0 * col2 * col1 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + col1 FROM tab0 AS cor0 WHERE NOT ( NULL ) NOT BETWEEN ( NULL ) AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6100
SELECT DISTINCT col1 + col0 DIV + col0 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6100
SELECT DISTINCT col1 + col0 / + col0 FROM tab1
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + col2 col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + + col1 * col0 + - col2 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT - col0 * col2 + + tab1.col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT ALL tab2.col0 FROM tab0, tab1 cor0 CROSS JOIN tab2
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query IIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 JOIN tab2 ON NULL <= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6106
SELECT ALL col0 * col1 DIV - cor0.col1 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-6106
SELECT ALL col0 * col1 / - cor0.col1 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6107
SELECT ALL col2 DIV col1 + tab2.col0 * - tab2.col1 col2 FROM tab2
----
-1341
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6107
SELECT ALL col2 / col1 + tab2.col0 * - tab2.col1 col2 FROM tab2
----
-1341
-217
-4602

query I rowsort
SELECT + col1 + col1 AS col0 FROM tab0 WHERE - col2 * - col2 * + col2 > ( NULL )
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT ( col1 ) NOT BETWEEN - col0 AND NULL
----

query I rowsort
SELECT + col2 + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT + + col2 + cor0.col1 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT col2 * col2 AS col1 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + col1 * col0 + cor0.col1 * col0 AS col2 FROM tab1 AS cor0
----
1280
156
2080

query I rowsort
SELECT - + col1 * + col0 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + col2 + + cor0.col1 * col0 + + col1 AS col1 FROM tab1 AS cor0
----
1149
158
707

query I rowsort
SELECT DISTINCT col2 + col1 * - cor0.col2 + - col1 * + col2 * col1 AS col1 FROM tab0 AS cor0
----
-246873
-686422
-9505

query I rowsort
SELECT - + col0 * + col1 + col1 AS col2 FROM tab1 AS cor0
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + - col0 col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL col1 * - cor0.col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT + + col2 - col0 * col0 AS col1 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT + cor0.col1 + col0 + cor0.col1 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT ALL col2 + col0 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT + + col1 * col0 - cor0.col2 AS col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + ( + 57 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

onlyif mysql # use DIV operator for integer division
query I rowsort label-6125
SELECT ALL tab0.col1 DIV - col1 AS col1 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6125
SELECT ALL tab0.col1 / - col1 AS col1 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT col0 * - col1 * + col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT - col1 + + ( - col2 + - col0 ) AS col2 FROM tab1 AS cor0
----
-131
-189
-83

query I rowsort
SELECT 29 FROM tab1, tab2 cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT + + ( + 46 ) * cor0.col2 FROM tab2 AS cor0
----
1196
1242
1748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - 7 col0 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT ALL + tab1.col0 FROM tab1, tab2 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT 68 AS col0 FROM tab2, tab1 AS cor0
----
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 79 + - 78 col1 FROM tab2
----
-157
-157
-157

query I rowsort
SELECT ALL 76 * col1 + - col0 FROM tab1 AS cor0
----
1973
696
908

query I rowsort
SELECT ALL cor0.col1 * cor0.col1 FROM tab1, tab1 cor0
----
9 values hashing to ae5946db6904798b8afac35f5777bb79

query I rowsort
SELECT ALL + col2 * + col0 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT + - 0 * col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 + col2 * + col2 FROM tab1 AS cor0
----
2913
3185
9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6139
SELECT CAST( - ( - col0 ) AS SIGNED ) * CAST( col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-6139
SELECT CAST ( - ( - col0 ) AS INTEGER ) * CAST ( col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - tab1.col0 + + col2 FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-6141
SELECT ALL - 21 DIV col2 + - ( - 82 ) FROM tab1
----
82
82
82

skipif mysql # not compatible
query I rowsort label-6141
SELECT ALL - 21 / col2 + - ( - 82 ) FROM tab1
----
82
82
82

query I rowsort
SELECT cor0.col2 * - col0 - - col1 * col0 FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT + 73 AS col1 FROM tab1 cor0
----
73
73
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6144
SELECT col2 * - col2 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6144
SELECT col2 * - col2 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6145
SELECT - - 56 + - col2 DIV - 42 FROM tab0 AS cor0
----
56
56
57

skipif mysql # not compatible
query I rowsort label-6145
SELECT - - 56 + - col2 / - 42 FROM tab0 AS cor0
----
56
56
57

query I rowsort
SELECT + + 19 AS col1 FROM tab2 AS cor0
----
19
19
19

query I rowsort
SELECT ALL + col0 + + ( 36 ) FROM tab2 AS cor0
----
114
115
43

query I rowsort
SELECT ALL - col0 + - ( 51 ) FROM tab2 AS cor0
----
-129
-130
-58

query I rowsort
SELECT DISTINCT - + col2 + + ( col0 ) AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT 45 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * - 13 + - col2 * col1 col0 FROM tab2 cor0
----
-1140
-1188
-1872

onlyif mysql # use DIV operator for integer division
query I rowsort label-6152
SELECT DISTINCT - cor0.col2 + col2 DIV 18 AS col0 FROM tab1 cor0
----
-51
-54
-91

skipif mysql # not compatible
query I rowsort label-6152
SELECT DISTINCT - cor0.col2 + col2 / 18 AS col0 FROM tab1 cor0
----
-51
-54
-91

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 - + col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL - col1 + 50 AS col1 FROM tab2 AS cor0
----
-9
19
33

query I rowsort
SELECT - col1 + ( + col1 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col0 * + ( + col0 ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT col1 + col0 * col2 FROM tab2 cor0
----
2087
220
3019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6158
SELECT DISTINCT + col2 + CAST( + col0 AS SIGNED ) FROM tab1 cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-6158
SELECT DISTINCT + col2 + CAST ( + col0 AS INTEGER ) FROM tab1 cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6159
SELECT ALL + + col0 * col0 DIV cor0.col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6159
SELECT ALL + + col0 * col0 / cor0.col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL col2 * - col1 - + col1 * col0 FROM tab0 cor0
----
-15561
-3492
-4902

query I rowsort
SELECT ALL - - cor0.col0 * + col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT col2 + 43 * cor0.col1 AS col0 FROM tab1 cor0
----
1172
487
655

onlyif mysql # use DIV operator for integer division
query I rowsort label-6163
SELECT ALL - col2 + col0 DIV + col0 AS col1 FROM tab2 cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-6163
SELECT ALL - col2 + col0 / + col0 AS col1 FROM tab2 cor0
----
-25
-26
-37

query I rowsort
SELECT + 77 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT + - 85 FROM tab1 cor0
----
-85
-85
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + col0 col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col1 * + 3 + + col0 + col0 FROM tab1 AS cor0
----
158
199
84

query I rowsort
SELECT ALL tab0.col2 + ( ( - tab0.col0 ) * + col1 + col0 ) AS col2 FROM tab0
----
-2007
-3359
-7928

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 17 col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
17

query I rowsort
SELECT - col1 * - col0 - col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT - col2 * + col0 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - ( col1 ) - ( col2 + + col0 ) FROM tab0 AS cor0
----
-133
-143
-262

query I rowsort
SELECT DISTINCT + - cor0.col2 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT - 46 + + col0 - cor0.col2 FROM tab0 AS cor0
----
-12
-39
-55

query I rowsort
SELECT col1 - ( col0 + col0 ) FROM tab0
----
-87
27
38

query I rowsort
SELECT tab2.col0 * col0 + - col2 * col0 AS col0 FROM tab2
----
-140
3239
4056

query I rowsort
SELECT + ( + ( col1 ) ) + - 54 FROM tab0
----
32
37
43

query I rowsort
SELECT 1 AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT + col0 * cor0.col1 * col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT - + 1 * col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT 76 FROM tab0 cor0
----
76

query I rowsort
SELECT - + 43 - col1 AS col2 FROM tab1 AS cor0
----
-53
-56
-69

query I rowsort
SELECT DISTINCT + col0 * col2 + ( + col1 ) * col1 AS col1 FROM tab1
----
3748
7849
838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 + col2 col1 FROM tab2
----
111
85
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6185
SELECT CAST( + col2 AS SIGNED ) * col2 * + ( + 35 * col0 ) FROM tab2
----
178605
1845480
3992660

skipif mysql # not compatible
query I rowsort label-6185
SELECT CAST ( + col2 AS INTEGER ) * col2 * + ( + 35 * col0 ) FROM tab2
----
178605
1845480
3992660

query I rowsort
SELECT ALL - 99 * 92 AS col0 FROM tab2
----
-9108
-9108
-9108

query I rowsort
SELECT ( 2 ) + - col0 FROM tab0
----
-22
-33
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6188
SELECT ALL col1 + col1 + + col0 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6188
SELECT ALL col1 + col1 + + col0 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6189
SELECT - 58 - col0 DIV col0 FROM tab2 AS cor0
----
-59
-59
-59

skipif mysql # not compatible
query I rowsort label-6189
SELECT - 58 - col0 / col0 FROM tab2 AS cor0
----
-59
-59
-59

query I rowsort
SELECT + ( - 93 ) * - col1 - ( + col1 ) AS col2 FROM tab0 AS cor0
----
7912
8372
8924

query I rowsort
SELECT ALL - 35 + col2 AS col0 FROM tab2 AS cor0
----
-8
-9
3

query I rowsort
SELECT DISTINCT 70 * - col1 + + col0 AS col2 FROM tab0 AS cor0
----
-5996
-6281
-6755

query I rowsort
SELECT ALL + 22 FROM tab1, tab2 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT DISTINCT - 26 * + 71 FROM tab1
----
-1846

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6195
SELECT + CAST( NULL AS SIGNED ) + - col1 + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6195
SELECT + CAST ( NULL AS INTEGER ) + - col1 + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + ( 79 ) AS col0 FROM tab2 AS cor0
----
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col1 ) + col1 col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - - cor0.col2 + col0 * + col2 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT ALL - + 7 AS col0 FROM tab2 cor0
----
-7
-7
-7

query I rowsort
SELECT ALL cor0.col0 * - cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT 27 + col2 FROM tab0 AS cor0
----
109
28
60

query I rowsort
SELECT cor0.col0 + col0 + - ( + col0 ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + col1 * - col1 + tab2.col1 + - col0 AS col0 FROM tab2
----
-3500
-351
-937

onlyif mysql # use DIV operator for integer division
query I rowsort label-6204
SELECT + 19 DIV + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6204
SELECT + 19 / + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col1 * 80 + + col1 FROM tab0 AS cor0
----
-6794
-7189
-7663

query I rowsort
SELECT ALL + cor0.col0 * 5 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
3200
390
5200

onlyif mysql # use DIV operator for integer division
query I rowsort label-6207
SELECT DISTINCT col2 * col1 DIV + col0 FROM tab2 AS cor0
----
119
19
8

skipif mysql # not compatible
query I rowsort label-6207
SELECT DISTINCT col2 * col1 / + col0 FROM tab2 AS cor0
----
119
19
8

query I rowsort
SELECT ALL + col1 * - col2 + col1 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6209
SELECT + col1 DIV 78 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6209
SELECT + col1 / 78 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL 52 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT ALL + col0 - cor0.col0 * 36 FROM tab2 AS cor0
----
-245
-2730
-2765

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6212
SELECT DISTINCT col0 + CAST( col0 AS SIGNED ) col0 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6212
SELECT DISTINCT col0 + CAST ( col0 AS INTEGER ) col0 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6213
SELECT ALL - + col2 DIV + 88 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6213
SELECT ALL - + col2 / + 88 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + col1 * cor0.col0 + - col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-6215
SELECT DISTINCT + - col2 DIV - 25 AS col1 FROM tab1 AS cor0
----
2
3

skipif mysql # not compatible
query I rowsort label-6215
SELECT DISTINCT + - col2 / - 25 AS col1 FROM tab1 AS cor0
----
2
3

query I rowsort
SELECT + - col2 + - col0 AS col0 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6217
SELECT DISTINCT - col1 + - CAST( + col1 * col2 AS SIGNED ) FROM tab2 AS cor0
----
-1593
-663
-868

skipif mysql # not compatible
query I rowsort label-6217
SELECT DISTINCT - col1 + - CAST ( + col1 * col2 AS INTEGER ) FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-6218
SELECT - 26 * 45 DIV - col1 - col1 * 87 * + col1 FROM tab2 AS cor0
----
-25075
-302828
-83570

skipif mysql # not compatible
query I rowsort label-6218
SELECT - 26 * 45 / - col1 - col1 * 87 * + col1 FROM tab2 AS cor0
----
-25075
-302828
-83570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 36 * col2 + col2 col0 FROM tab2 AS cor0
----
1406
962
999

query I rowsort
SELECT 79 + col0 FROM tab0 AS cor0
----
103
114
168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6221
SELECT + CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6221
SELECT + CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6222
SELECT - CAST( col0 AS SIGNED ) - + col2 FROM tab2 AS cor0
----
-104
-117
-34

skipif mysql # not compatible
query I rowsort label-6222
SELECT - CAST ( col0 AS INTEGER ) - + col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT cor0.col2 * col2 + col2 FROM tab1 cor0
----
2970
3306
9312

query I rowsort
SELECT ( + 79 ) FROM tab2 AS cor0
----
79
79
79

query I rowsort
SELECT cor1.col2 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ( 67 ) FROM tab2, tab2 AS cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

query I rowsort
SELECT tab2.col0 + + cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 218174566e316faf7def1869e4f9f1b6

query I rowsort
SELECT DISTINCT col2 + 62 * col1 AS col2 FROM tab0
----
5365
5724
6015

query I rowsort
SELECT DISTINCT - col0 + 23 + + col0 FROM tab1 AS cor0
----
23

query I rowsort
SELECT + ( - col2 ) + col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT col0 * 58 AS col2 FROM tab0 AS cor0
----
1392
2030
5162

query I rowsort
SELECT + col0 * + 77 FROM tab2 AS cor0
----
539
6006
6083

query I rowsort
SELECT ALL + - ( - 56 ) AS col1 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT 13 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT 9 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT ALL - cor0.col1 * col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - col1 * - col1 * - col0 AS col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT - - ( col2 ) + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - cor1.col2 AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6240
SELECT ALL CAST( NULL AS DECIMAL ) * 17 * col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6240
SELECT ALL CAST ( NULL AS REAL ) * 17 * col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 75 * col1 + - col0 * - col2 col1 FROM tab1
----
-1788
2898
6705

query I rowsort
SELECT - + 42 * col2 AS col1 FROM tab1 cor0
----
-2268
-2394
-4032

query I rowsort
SELECT - - col1 * cor0.col2 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - cor0.col2 + - 84 AS col0 FROM tab0 AS cor0
----
-117
-166
-85

query I rowsort
SELECT - - cor0.col2 - 59 AS col2 FROM tab2 cor0
----
-21
-32
-33

query I rowsort
SELECT + col2 + + 76 AS col1 FROM tab2 AS cor0
----
102
103
114

onlyif mysql # use DIV operator for integer division
query I rowsort label-6247
SELECT DISTINCT col1 DIV ( col0 ) col2 FROM tab1
----
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6247
SELECT DISTINCT col1 / ( col0 ) col2 FROM tab1
----
0
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6248
SELECT DISTINCT - col0 - CAST( ( col1 ) AS SIGNED ) FROM tab1
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-6248
SELECT DISTINCT - col0 - CAST ( ( col1 ) AS INTEGER ) FROM tab1
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6249
SELECT 90 DIV + ( col0 ) + - cor0.col0 FROM tab1 AS cor0
----
-63
-79
27

skipif mysql # not compatible
query I rowsort label-6249
SELECT 90 / + ( col0 ) + - cor0.col0 FROM tab1 AS cor0
----
-63
-79
27

query I rowsort
SELECT + + cor0.col2 * 12 FROM tab2 AS cor0
----
312
324
456

query I rowsort
SELECT - - ( cor0.col0 ) * - col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - col1 * - col1 + cor0.col0 + 90 AS col0 FROM tab0 AS cor0
----
7510
8460
9534

query I rowsort
SELECT 26 - col0 FROM tab0 AS cor0
----
-63
-9
2

query I rowsort
SELECT ( + ( - cor0.col2 ) ) + col1 + 28 FROM tab2 AS cor0
----
32
61
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6255
SELECT ALL col0 DIV CAST( col1 AS SIGNED ) col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6255
SELECT ALL col0 / CAST ( col1 AS INTEGER ) col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + + cor0.col1 + 11 AS col0 FROM tab2 AS cor0
----
28
42
70

query I rowsort
SELECT - 38 * - 57 AS col1 FROM tab2 AS cor0
----
2166
2166
2166

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6258
SELECT - - CAST( NULL AS SIGNED ) - 19 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6258
SELECT - - CAST ( NULL AS INTEGER ) - 19 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 99 * + col1 col0 FROM tab2 AS cor0
----
1700
3100
5900

query I rowsort
SELECT + 93 + - col2 + + col0 AS col0 FROM tab2
----
134
145
73

query I rowsort
SELECT ALL col1 + col2 * + tab1.col1 AS col2 FROM tab1
----
1261
1430
580

query I rowsort
SELECT tab2.col0 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + 81 + + col0 + + col0 * col2 FROM tab1
----
246
3793
7841

query I rowsort
SELECT DISTINCT tab2.col1 + + col1 AS col1 FROM tab2
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6265
SELECT + CAST( NULL AS DECIMAL ) + cor0.col1 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6265
SELECT + CAST ( NULL AS REAL ) + cor0.col1 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 81 * - col2 - col0 * + col1 * - col1 FROM tab0 AS cor0
----
174831
329234
730367

query I rowsort
SELECT DISTINCT - col2 * col1 + col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 - 60 col1 FROM tab0 AS cor0
----
-25
-36
29

query I rowsort
SELECT + - 14 * col2 - col2 AS col0 FROM tab1 AS cor0
----
-1440
-810
-855

query I rowsort
SELECT DISTINCT - 33 + cor0.col1 * - col2 AS col0 FROM tab2 AS cor0
----
-1567
-679
-870

query I rowsort
SELECT DISTINCT 33 * col0 + - col2 FROM tab1 AS cor0
----
2055
2544
45

query I rowsort
SELECT ALL + col0 * col1 + - cor0.col2 * + col1 FROM tab1 cor0
----
-1326
-208
70

query I rowsort
SELECT ALL - col1 + + col0 AS col2 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT + + col0 + - col1 * 45 AS col2 FROM tab1 AS cor0
----
-1167
-386
-505

query I rowsort
SELECT ALL col2 * + cor0.col1 AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - col0 + - col1 + 4 FROM tab2 AS cor0
----
-133
-34
-92

query I rowsort
SELECT DISTINCT + 48 FROM tab1 AS cor0
----
48

query I rowsort
SELECT DISTINCT + 29 * col0 FROM tab2 AS cor0
----
203
2262
2291

query I rowsort
SELECT 80 * col1 + col2 FROM tab1 AS cor0
----
1136
2134
857

query I rowsort
SELECT DISTINCT - 34 AS col0 FROM tab1 AS cor0
----
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT ( + tab1.col2 ) - tab1.col0 AS col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT col1 + col2 - + col0 AS col1 FROM tab1
----
29
3
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6284
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 20 - col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6284
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 20 - col0 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT + 69 - 64 * col0 AS col2 FROM tab0
----
-1467
-2171
-5627

query I rowsort
SELECT ALL - 33 + + col1 * - 84 * 20 AS col2 FROM tab1 cor0
----
-16833
-21873
-43713

query I rowsort
SELECT DISTINCT 51 * col0 AS col1 FROM tab2 AS cor0
----
357
3978
4029

query I rowsort
SELECT + - 86 * col0 AS col1 FROM tab1 AS cor0
----
-258
-5504
-6880

query I rowsort
SELECT DISTINCT ( - ( + col2 ) ) * 36 FROM tab2
----
-1368
-936
-972

query I rowsort
SELECT ALL + col2 * - ( 73 * col2 ) FROM tab0 AS cor0
----
-490852
-73
-79497

query I rowsort
SELECT DISTINCT - cor0.col2 * col2 + col0 AS col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT ALL cor0.col1 + - ( + cor0.col1 + - col2 ) AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL cor0.col2 * col0 + col1 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT col2 + ( col0 ) * - col1 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT - - cor0.col2 * - 70 FROM tab1 cor0
----
-3780
-3990
-6720

query I rowsort
SELECT - + cor0.col1 * col2 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT col2 * - 89 FROM tab1 AS cor0
----
-4806
-5073
-8544

query I rowsort
SELECT ALL cor0.col1 + col0 * + 13 AS col0 FROM tab1 AS cor0
----
1053
65
842

query I rowsort
SELECT ALL + cor0.col2 + - 99 AS col1 FROM tab2 AS cor0
----
-61
-72
-73

query I rowsort
SELECT ALL col0 * col0 + - col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT + col2 * ( + col2 ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + col2 * + 86 + - col1 - + col2 AS col1 FROM tab0 AS cor0
----
-12
2719
6879

query I rowsort
SELECT DISTINCT + + col2 * - col1 + - col2 FROM tab1 AS cor0
----
-1344
-1458
-627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 73 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT ALL ( 52 ) + col0 * - col2 * col1 FROM tab1 AS cor0
----
-36428
-4160
-99788

query I rowsort
SELECT col2 - + ( col2 ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 9 AS col2 FROM tab0 cor0
----
9
9
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6308
SELECT ALL CAST( NULL AS SIGNED ) * 35 * + col0 + - 58 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6308
SELECT ALL CAST ( NULL AS INTEGER ) * 35 * + col0 + - 58 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( - col2 ) * - 75 FROM tab2
----
1950
2025
2850

query I rowsort
SELECT + 92 AS col0 FROM tab2
----
92
92
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-6311
SELECT + col2 + cor0.col2 DIV + col0 - col2 AS col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6311
SELECT + col2 + cor0.col2 / + col0 - col2 AS col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT - col1 * - 11 FROM tab1 AS cor0
----
110
143
286

query I rowsort
SELECT DISTINCT - tab0.col1 * col2 + col0 - col1 AS col2 FROM tab0
----
-159
-2900
-7464

onlyif mysql # use DIV operator for integer division
query I rowsort label-6314
SELECT - col2 DIV + col1 - + col2 AS col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6314
SELECT - col2 / + col1 - + col2 AS col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + col0 + col2 - + col0 FROM tab1
----
54
57
96

query I rowsort
SELECT + + 15 + col2 * col0 AS col0 FROM tab0 AS cor0
----
50
7313
807

query I rowsort
SELECT 71 + cor0.col2 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 927b9f07be6fdc7675d085262826f124

query I rowsort
SELECT ALL + tab2.col1 + col1 + 63 FROM tab2
----
125
181
97

query I rowsort
SELECT DISTINCT + 91 * col0 + - col2 + col0 FROM tab1
----
222
5831
7264

query I rowsort
SELECT + 20 * + col1 FROM tab2
----
1180
340
620

query I rowsort
SELECT 29 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT - tab0.col2 * 68 AS col0 FROM tab0
----
-2244
-5576
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6323
SELECT DISTINCT - cor0.col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6323
SELECT DISTINCT - cor0.col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * ( - col0 ) col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6325
SELECT ALL col1 DIV cor0.col1 + - col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-6325
SELECT ALL col1 / cor0.col1 + - col0 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT ALL + col0 * ( - col1 ) AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6327
SELECT col0 + CAST( NULL AS DECIMAL ) / + 22 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6327
SELECT col0 + CAST ( NULL AS REAL ) / + 22 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col0 + 14 * col1 AS col1 FROM tab0 AS cor0
----
1180
1185
1323

query I rowsort
SELECT - + 75 * + col0 + col2 FROM tab1 AS cor0
----
-171
-4743
-5904

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6330
SELECT ALL CAST( NULL AS SIGNED ) * col0 + col0 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6330
SELECT ALL CAST ( NULL AS INTEGER ) * col0 + col0 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6331
SELECT ALL - col0 DIV 9 AS col0 FROM tab1 AS cor0
----
-7
-8
0

skipif mysql # not compatible
query I rowsort label-6331
SELECT ALL - col0 / 9 AS col0 FROM tab1 AS cor0
----
-7
-8
0

query I rowsort
SELECT DISTINCT + - col1 * - 46 + - col0 AS col1 FROM tab2 AS cor0
----
1419
2636
703

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col0 AS REAL ) + - col1 * 19 col2 FROM tab2 AS cor0
----
-1043
-244
-582

query I rowsort
SELECT ALL + + col0 * ( col0 ) AS col1 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6335
SELECT DISTINCT - CAST( + col2 AS SIGNED ) FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-6335
SELECT DISTINCT - CAST ( + col2 AS INTEGER ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + col0 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) + col2 AS col1 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6338
SELECT col0 / - ( tab2.col0 ) + + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6338
SELECT col0 / - ( tab2.col0 ) + + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 87 * + cor0.col0 FROM tab0 AS cor0
----
-2088
-3045
-7743

query I rowsort
SELECT + - cor0.col2 * col1 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6341
SELECT DISTINCT col2 DIV - 58 AS col1 FROM tab0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6341
SELECT DISTINCT col2 / - 58 AS col1 FROM tab0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 49 + col0 col1 FROM tab1 AS cor0
----
-46
15
31

query I rowsort
SELECT ALL + 99 + col0 AS col0 FROM tab2 AS cor0
----
106
177
178

query I rowsort
SELECT + 55 + col1 * ( - col0 ) AS col2 FROM tab0 AS cor0
----
-2009
-3340
-8044

query I rowsort
SELECT - 9 AS col0 FROM tab2 AS cor0
----
-9
-9
-9

query I rowsort
SELECT col0 + + col1 * col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6347
SELECT ALL + col2 DIV + tab0.col0 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6347
SELECT ALL + col2 / + tab0.col0 FROM tab0
----
0
0
1

query I rowsort
SELECT ( + cor0.col1 ) + + col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT cor1.col2 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

skipif mysql # not compatible
query I rowsort
SELECT col2 * CAST ( col2 AS REAL ) * col0 FROM tab1
----
207936
737280
8748

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6351
SELECT + CAST( col2 AS SIGNED ) + col1 * - col0 col2 FROM tab1
----
-24
-583
-944

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6351
SELECT + CAST ( col2 AS INTEGER ) + col1 * - col0 col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT DISTINCT + 25 AS col0 FROM tab2
----
25

query I rowsort
SELECT ALL col2 * col1 - - col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT 78 + + 8 AS col0 FROM tab0 AS cor0
----
86
86
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6355
SELECT - ( - 79 ) * col0 + - CAST( - 47 AS SIGNED ) AS col2 FROM tab1 cor0
----
284
5103
6367

skipif mysql # not compatible
query I rowsort label-6355
SELECT - ( - 79 ) * col0 + - CAST ( - 47 AS INTEGER ) AS col2 FROM tab1 cor0
----
284
5103
6367

query I rowsort
SELECT DISTINCT + 88 AS col2 FROM tab1
----
88

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( NULL ) IN ( - col2 * - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col1 + tab1.col1 col0 FROM tab1 WHERE NULL NOT IN ( - tab1.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6359
SELECT ALL col2 DIV col0 - + col1 AS col0 FROM tab0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-6359
SELECT ALL col2 / col0 - + col1 AS col0 FROM tab0
----
-85
-91
-97

query I rowsort
SELECT + col2 * col0 * + col1 + - col2 * + col2 FROM tab0
----
3394
657394
67023

query I rowsort
SELECT col2 * col0 * col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT col0 * tab0.col2 * col2 AS col0 FROM tab0
----
26136
35
598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col1 col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + col2 * - col0 + - col0 * col0 FROM tab1
----
-14080
-171
-7744

query I rowsort
SELECT ALL - col2 * col0 FROM tab2 WHERE + col1 * col2 + col1 NOT BETWEEN NULL AND - col2
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6366
SELECT tab0.col1 DIV + col2 + - col2 * col0 * + col1 FROM tab0
----
-3298
-664117
-68110

skipif mysql # not compatible
query I rowsort label-6366
SELECT tab0.col1 / + col2 + - col2 * col0 * + col1 FROM tab0
----
-3298
-664117
-68110

query I rowsort
SELECT DISTINCT + col1 + + cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab2 AS cor1, tab1 cor2
----
972 values hashing to 263f0eb7d5dfd4076c74918bc141bd9b

query I rowsort
SELECT col2 + - col1 * col1 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT ALL - 96 AS col2 FROM tab1 AS cor0
----
-96
-96
-96

query I rowsort
SELECT ALL + - col1 + + col1 * - ( + cor0.col0 ) FROM tab0 AS cor0
----
-2150
-3492
-8190

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col1 + - col2 BETWEEN col0 AND NULL
----
89
91
82

query I rowsort
SELECT DISTINCT - tab1.col1 + - col0 * - col2 + + col1 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6374
SELECT tab0.col0 DIV + col2 AS col1 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6374
SELECT tab0.col0 / + col2 AS col1 FROM tab0
----
0
1
35

query I rowsort
SELECT ALL - col1 * - col1 * col1 FROM tab2
----
205379
29791
4913

onlyif mysql # use DIV operator for integer division
query I rowsort label-6376
SELECT DISTINCT col2 DIV col0 AS col0 FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-6376
SELECT DISTINCT col2 / col0 AS col0 FROM tab2 AS cor0
----
0
3

query I rowsort
SELECT ALL col1 + cor0.col0 * + col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT cor0.col1 * col2 * - col0 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL IN ( + tab2.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6380
SELECT + col0 DIV - col1 AS col0 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6380
SELECT + col0 / - col1 AS col0 FROM tab2
----
-1
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6381
SELECT DISTINCT + col0 DIV col2 - col2 FROM tab0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-6381
SELECT DISTINCT + col0 / col2 - col2 FROM tab0
----
-33
-81
34

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT IN ( col1 * col0 * - col0 + - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6383
SELECT DISTINCT tab0.col2 DIV + tab0.col0 + col1 FROM tab0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-6383
SELECT DISTINCT tab0.col2 / + tab0.col0 + col1 FROM tab0
----
87
91
97

query I rowsort
SELECT tab0.col2 * col1 + - col0 AS col1 FROM tab0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - col0 col2 FROM tab1
----
-29
-74
-93

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT - col0 < NULL
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL IN ( tab1.col2 * - col2 + col1 )
----

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - CAST ( + cor0.col1 AS REAL ) * - col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT ( ( + col1 ) ) AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + - 21 * ( + col2 ) AS col1 FROM tab1 AS cor0
----
-1134
-1197
-2016

onlyif mysql # use DIV operator for integer division
query I rowsort label-6391
SELECT DISTINCT ( - col0 ) * col2 DIV 81 AS col0 FROM tab1 AS cor0
----
-2
-45
-94

skipif mysql # not compatible
query I rowsort label-6391
SELECT DISTINCT ( - col0 ) * col2 / 81 AS col0 FROM tab1 AS cor0
----
-2
-45
-94

query I rowsort
SELECT - - 25 * col0 AS col2 FROM tab0 AS cor0
----
2225
600
875

query I rowsort
SELECT DISTINCT - ( 99 ) + col2 + - 26 * + tab0.col1 FROM tab0
----
-2302
-2383
-2620

query I rowsort
SELECT DISTINCT 86 + ( col1 ) * cor0.col1 * + ( - col2 * - col0 ) FROM tab1 AS cor0
----
109598
1298006
364886

query I rowsort
SELECT col2 + + tab2.col1 AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL - + ( - col1 ) + col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL 28 * - col0 FROM tab0 AS cor0
----
-2492
-672
-980

query I rowsort
SELECT + 71 + 71 FROM tab1 AS cor0
----
142
142
142

query I rowsort
SELECT ALL + + col1 + col2 + - col2 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - tab0.col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT cor0.col1 * + cor0.col1 + + 20 + col1 * + col2 FROM tab0 AS cor0
----
10254
15763
9526

onlyif mysql # use DIV operator for integer division
query I rowsort label-6402
SELECT + - cor0.col2 DIV col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6402
SELECT + - cor0.col2 / col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6403
SELECT DISTINCT - col2 + col2 DIV col1 AS col1 FROM tab2 cor0
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-6403
SELECT DISTINCT - col2 + col2 / col1 AS col1 FROM tab2 cor0
----
-26
-27
-36

query I rowsort
SELECT DISTINCT + - col0 + - col2 * - col0 + 10 * + col0 * - col0 AS col1 FROM tab0 AS cor0
----
-12250
-4992
-72001

onlyif mysql # use DIV operator for integer division
query I rowsort label-6405
SELECT + + ( col1 ) + - col1 + + col2 DIV col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-6405
SELECT + + ( col1 ) + - col1 + + col2 / col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT DISTINCT - col0 * ( cor0.col0 ) AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL cor0.col0 * - 31 * 45 AS col0 FROM tab1 AS cor0
----
-111600
-4185
-89280

query I rowsort
SELECT ALL + - col1 * ( + 66 ) AS col2 FROM tab0 AS cor0
----
-5676
-6006
-6402

query I rowsort
SELECT ALL + - col0 * + col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - cor0.col1 + + 92 * + col1 AS col2 FROM tab0 AS cor0
----
7826
8281
8827

query I rowsort
SELECT DISTINCT tab0.col0 + + tab0.col2 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL 20 + col2 FROM tab0
----
102
21
53

query I rowsort
SELECT 78 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT ALL - ( - col2 ) + col2 * 5 * - tab2.col2 + - col1 AS col1 FROM tab2
----
-3413
-3649
-7199

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6415
SELECT DISTINCT - col1 * CAST( 88 AS SIGNED ) FROM tab2 AS cor0
----
-1496
-2728
-5192

skipif mysql # not compatible
query I rowsort label-6415
SELECT DISTINCT - col1 * CAST ( 88 AS INTEGER ) FROM tab2 AS cor0
----
-1496
-2728
-5192

query I rowsort
SELECT - col1 + 57 * 54 FROM tab0 AS cor0
----
2981
2987
2992

query I rowsort
SELECT cor0.col0 + ( col0 ) * + col0 FROM tab1 cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT cor0.col0 * col2 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT - col0 * ( col2 ) AS col1 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT col2 * + 60 AS col2 FROM tab0 AS cor0
----
1980
4920
60

query I rowsort
SELECT DISTINCT - col2 * 19 * - 6 FROM tab1 AS cor0
----
10944
6156
6498

query I rowsort
SELECT ALL - 11 FROM tab1, tab1 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

query I rowsort
SELECT - ( + ( col0 ) ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + + col1 + 99 * - cor0.col0 * col2 FROM tab1 AS cor0
----
-16012
-361142
-760307

query I rowsort
SELECT + col1 * 99 AS col0 FROM tab2 AS cor0
----
1683
3069
5841

onlyif mysql # use DIV operator for integer division
query I rowsort label-6426
SELECT DISTINCT - col0 DIV 22 AS col0 FROM tab0 AS cor0
----
-1
-4

skipif mysql # not compatible
query I rowsort label-6426
SELECT DISTINCT - col0 / 22 AS col0 FROM tab0 AS cor0
----
-1
-4

query I rowsort
SELECT DISTINCT + 60 AS col0 FROM tab1
----
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-6428
SELECT + ( cor0.col0 ) + col2 DIV - col1 AS col2 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-6428
SELECT + ( cor0.col0 ) + col2 / - col1 AS col2 FROM tab2 AS cor0
----
7
77
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6429
SELECT CAST( col0 AS SIGNED ) * col0 + col1 FROM tab0
----
1322
662
8012

skipif mysql # not compatible
query I rowsort label-6429
SELECT CAST ( col0 AS INTEGER ) * col0 + col1 FROM tab0
----
1322
662
8012

query I rowsort
SELECT ALL + 56 AS col1 FROM tab1
----
56
56
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col1 + col1 ) col2 FROM tab1
----
20
26
52

query I rowsort
SELECT tab2.col0 * + 30 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 2ffe9792cd89b46c1761ee9ceb5c7dd0

query I rowsort
SELECT ALL + col0 * - col2 + col1 * - 58 FROM tab1
----
-1670
-4228
-8434

query I rowsort
SELECT col0 + ( - col1 ) AS col0 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-6435
SELECT - col2 DIV + col2 + col0 + col1 * + cor0.col2 FROM tab1 AS cor0
----
1327
1406
633

skipif mysql # not compatible
query I rowsort label-6435
SELECT - col2 / + col2 + col0 + col1 * + cor0.col2 FROM tab1 AS cor0
----
1327
1406
633

query I rowsort
SELECT ALL - 97 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

query I rowsort
SELECT tab0.col2 * col2 + + col0 AS col0 FROM tab0
----
1113
36
6813

query I rowsort
SELECT ALL col2 + col2 * col1 AS col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT DISTINCT col2 + + 72 * + cor0.col1 + - col0 FROM tab1 AS cor0
----
1923
713
952

query I rowsort
SELECT - col2 * - col0 + + 2 FROM tab1 AS cor0
----
164
3650
7682

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 - 24 * col2 col2 FROM tab2 AS cor0
----
-598
-621
-874

query I rowsort
SELECT ALL - col1 + ( - col2 ) * + col0 - col1 * col2 AS col0 FROM tab1 AS cor0
----
-1592
-4228
-8941

query I rowsort
SELECT ALL + cor0.col2 + - col0 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT - + col0 * + ( 62 ) + + col1 FROM tab2 AS cor0
----
-403
-4777
-4881

query I rowsort
SELECT DISTINCT - col0 + 33 * cor0.col0 FROM tab1 AS cor0
----
2048
2560
96

query I rowsort
SELECT + col1 * - col1 * col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT col0 * + tab0.col2 FROM tab0 WHERE NOT - col1 / col0 + col0 = ( col2 + - col0 ) AND col0 * col0 IN ( + col0 * - col1 )
----

query I rowsort
SELECT col2 * - tab0.col2 FROM tab0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-6450
SELECT col0 DIV col0 + - cor0.col1 + + col0 FROM tab0 AS cor0
----
-1
-61
-61

skipif mysql # not compatible
query I rowsort label-6450
SELECT col0 / col0 + - cor0.col1 + + col0 FROM tab0 AS cor0
----
-1
-61
-61

query I rowsort
SELECT col1 * + col2 * + col0 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-6452
SELECT + col2 DIV - col0 col1 FROM tab0 cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6452
SELECT + col2 / - col0 col1 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT - + col2 * - col1 AS col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - col2 * col2 + col2 AS col2 FROM tab2
----
-1406
-650
-702

query I rowsort
SELECT + col2 * col1 + col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT - + cor0.col0 * col0 * cor0.col0 FROM tab2 AS cor0
----
-343
-474552
-493039

query I rowsort
SELECT + col2 * - col1 * - col1 AS col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT - - col2 + + cor0.col2 * + col2 + - col1 FROM tab0 AS cor0
----
-95
1036
6715

query I rowsort
SELECT DISTINCT ( - col0 ) * - col1 * col1 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-6460
SELECT ALL 11 DIV + cor0.col0 AS col0 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6460
SELECT ALL 11 / + cor0.col0 AS col0 FROM tab2 AS cor0
----
0
0
1

query I rowsort
SELECT - col2 * - col0 + + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT 11 - col1 AS col2 FROM tab0 cor0
----
-75
-80
-86

query I rowsort
SELECT + col2 * + col0 + col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-6464
SELECT - col2 - col2 DIV + col0 FROM tab2 AS cor0
----
-26
-30
-38

skipif mysql # not compatible
query I rowsort label-6464
SELECT - col2 - col2 / + col0 FROM tab2 AS cor0
----
-26
-30
-38

query I rowsort
SELECT DISTINCT col0 * + col0 * col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT col1 * col1 + col0 AS col0 FROM tab1
----
164
249
679

query I rowsort
SELECT ALL + col1 + col2 + ( 43 ) FROM tab1 AS cor0
----
110
123
152

query I rowsort
SELECT + cor0.col1 * - col2 + cor0.col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + 77 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT DISTINCT - + col0 * + 32 AS col1 FROM tab2 AS cor0
----
-224
-2496
-2528

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6471
SELECT ALL - col0 + + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6471
SELECT ALL - col0 + + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * - col0 + - 2 FROM tab0 AS cor0
----
-1227
-578
-7923

query I rowsort
SELECT - - col2 - + 89 FROM tab0 AS cor0
----
-56
-7
-88

query I rowsort
SELECT + cor0.col1 * ( - col2 ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + 74 * 33 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to be8aa4206b1cb8d63e25bab1a720fe03

query I rowsort
SELECT + col1 * col2 - col0 AS col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT + 7 AS col1 FROM tab1 cor0
----
7
7
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6478
SELECT DISTINCT - - CAST( + col1 AS SIGNED ) * col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-6478
SELECT DISTINCT - - CAST ( + col1 AS INTEGER ) * col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT + + 65 * + cor0.col1 AS col0 FROM tab1 cor0 CROSS JOIN tab0, tab2 cor1
----
27 values hashing to 9ef329f168c312678e07bd24d6a79595

query I rowsort
SELECT + ( 74 ) + col1 FROM tab2 cor0
----
105
133
91

query I rowsort
SELECT DISTINCT + + col2 + col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT + 35 AS col1 FROM tab0 AS cor0
----
35
35
35

query I rowsort
SELECT + 88 * - col0 FROM tab2 AS cor0
----
-616
-6864
-6952

query I rowsort
SELECT ALL + cor0.col1 * + col0 + col0 * + col1 FROM tab1 AS cor0
----
1280
156
2080

query I rowsort
SELECT DISTINCT - 30 + + col2 FROM tab1 AS cor0
----
24
27
66

query I rowsort
SELECT - col0 + cor0.col0 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + + col1 AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + col0 + col1 + 32 * + col2 FROM tab2 AS cor0
----
1312
902
969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col0 ) + - col1 * + col0 col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT - col2 * + tab2.col1 + + col2 AS col0 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT 48 * + col0 AS col2 FROM tab0
----
1152
1680
4272

query I rowsort
SELECT 44 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

onlyif mysql # use DIV operator for integer division
query I rowsort label-6493
SELECT - tab1.col2 + - col2 * col1 DIV + col1 AS col0 FROM tab1
----
-108
-114
-192

skipif mysql # not compatible
query I rowsort label-6493
SELECT - tab1.col2 + - col2 * col1 / + col1 AS col0 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT DISTINCT + 69 * col2 - - cor0.col0 FROM tab2 AS cor0
----
1870
1872
2701

query I rowsort
SELECT ALL - ( col1 ) + + 27 FROM tab1 AS cor0
----
1
14
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-6496
SELECT ALL - + 89 DIV - col0 FROM tab2 cor0
----
1
1
12

skipif mysql # not compatible
query I rowsort label-6496
SELECT ALL - + 89 / - col0 FROM tab2 cor0
----
1
1
12

query I rowsort
SELECT 48 + + tab1.col0 * col2 FROM tab1
----
210
3696
7728

query I rowsort
SELECT col1 * ( 22 ) AS col0 FROM tab0
----
1892
2002
2134

onlyif mysql # use DIV operator for integer division
query I rowsort label-6499
SELECT col1 DIV ( - col2 ) + col0 + - tab0.col2 FROM tab0
----
-11
-63
6

skipif mysql # not compatible
query I rowsort label-6499
SELECT col1 / ( - col2 ) + col0 + - tab0.col2 FROM tab0
----
-11
-63
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6500
SELECT col0 DIV - col1 + 37 AS col0 FROM tab1
----
31
31
37

skipif mysql # not compatible
query I rowsort label-6500
SELECT col0 / - col1 + 37 AS col0 FROM tab1
----
31
31
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-6501
SELECT + col1 + - 79 DIV + col0 FROM tab0
----
83
91
95

skipif mysql # not compatible
query I rowsort label-6501
SELECT + col1 + - 79 / + col0 FROM tab0
----
83
91
95

query I rowsort
SELECT 21 + 78 * - cor0.col0 FROM tab2 cor0
----
-525
-6063
-6141

query I rowsort
SELECT ALL + 71 + col0 * col1 AS col2 FROM tab0 AS cor0
----
2135
3466
8170

query I rowsort
SELECT ALL col1 * 99 + col2 AS col1 FROM tab2
----
1721
3096
5867

query I rowsort
SELECT DISTINCT + 96 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
96

query I rowsort
SELECT - 40 + ( cor0.col2 ) FROM tab1 cor0
----
14
17
56

query I rowsort
SELECT ALL cor0.col2 AS col0 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6508
SELECT CAST( - col1 AS SIGNED ) * col2 + - col1 AS col2 FROM tab1
----
-1261
-1430
-580

skipif mysql # not compatible
query I rowsort label-6508
SELECT CAST ( - col1 AS INTEGER ) * col2 + - col1 AS col2 FROM tab1
----
-1261
-1430
-580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 41 col1 FROM tab0 AS cor0
----
123
42
74

query I rowsort
SELECT + col1 + col0 + - col2 AS col0 FROM tab1 cor0
----
-25
-3
17

query I rowsort
SELECT DISTINCT + ( col2 ) + col0 * - ( + col2 ) AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-6512
SELECT DISTINCT - ( + cor0.col0 ) DIV col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-6512
SELECT DISTINCT - ( + cor0.col0 ) / col0 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT - ( - cor0.col2 ) * - col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 77 * - cor0.col0 col1 FROM tab2 AS cor0
----
-539
-6006
-6083

query I rowsort
SELECT ALL + cor0.col1 + 28 FROM tab1 AS cor0
----
38
41
54

query I rowsort
SELECT DISTINCT - col2 * col1 - col1 FROM tab0 cor0
----
-194
-2924
-7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 51 * - col1 col2 FROM tab0 AS cor0
----
-4386
-4641
-4947

query I rowsort
SELECT + col0 + + col2 * - col0 * 4 FROM tab1 AS cor0
----
-14528
-30640
-645

query I rowsort
SELECT - + col2 + 49 FROM tab0 AS cor0
----
-33
16
48

query I rowsort
SELECT ALL col1 + + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6521
SELECT DISTINCT + CAST( NULL AS SIGNED ) * cor0.col0 + col0 - - ( - col1 ) col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6521
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * cor0.col0 + col0 - - ( - col1 ) col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ( - col0 ) + cor0.col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 * + 57 AS col2 FROM tab2 AS cor0
----
-1767
-3363
-969

query I rowsort
SELECT + 59 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT DISTINCT - ( 57 ) FROM tab2, tab1 AS cor0
----
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6526
SELECT col0 * + CAST( NULL AS SIGNED ) + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6526
SELECT col0 * + CAST ( NULL AS INTEGER ) + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * + 42 AS col1 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT ALL - 38 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6529
SELECT col2 * + CAST( NULL AS SIGNED ) / col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6529
SELECT col2 * + CAST ( NULL AS INTEGER ) / col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + col2 AS col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT + + ( col1 ) * col2 * + col2 FROM tab2 AS cor0
----
22599
24548
39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6532
SELECT - CAST( - col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-6532
SELECT - CAST ( - col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT ( cor0.col0 ) * col2 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT col2 * - col1 + - 58 AS col2 FROM tab1 AS cor0
----
-1306
-1462
-628

query I rowsort
SELECT - 92 + col1 AS col2 FROM tab2 AS cor0
----
-33
-61
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-6536
SELECT col2 DIV + cor0.col0 + col2 FROM tab0 AS cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-6536
SELECT col2 / + cor0.col0 + col2 FROM tab0 AS cor0
----
1
34
82

query I rowsort
SELECT DISTINCT 51 + + col2 * - 31 AS col0 FROM tab1 AS cor0
----
-1623
-1716
-2925

query I rowsort
SELECT DISTINCT - - col1 - + col1 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + col1 + + col1 * ( - 93 ) FROM tab0 AS cor0
----
-7912
-8372
-8924

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 5 + col0 col1 FROM tab1 AS cor0
----
69
8
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6541
SELECT 44 DIV cor0.col1 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6541
SELECT 44 / cor0.col1 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

onlyif mysql # use DIV operator for integer division
query I rowsort label-6542
SELECT col2 + + tab1.col2 * col2 + tab1.col2 DIV 55 FROM tab1
----
2970
3307
9313

skipif mysql # not compatible
query I rowsort label-6542
SELECT col2 + + tab1.col2 * col2 + tab1.col2 / 55 FROM tab1
----
2970
3307
9313

query I rowsort
SELECT - ( col1 ) + col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( col0 ) * col2 - + col2 AS col1 FROM tab0
----
34
7216
759

query I rowsort
SELECT - 68 + + col2 FROM tab2
----
-30
-41
-42

query I rowsort
SELECT + + col1 + - col0 AS col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT ALL - 96 + col2 AS col0 FROM tab2 AS cor0
----
-58
-69
-70

query I rowsort
SELECT DISTINCT - col1 * + col0 + + ( col2 * + cor0.col2 ) - + col1 FROM tab2 cor0
----
-3985
481
84

query I rowsort
SELECT ALL - 49 + + cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 0454bf88c06701f6ab93c5dd1dec9c26

query I rowsort
SELECT - - col0 + ( - 64 ) FROM tab1 AS cor0
----
-61
0
16

query I rowsort
SELECT col1 + + ( - 42 ) FROM tab0 AS cor0
----
44
49
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6552
SELECT - col2 + + CAST( NULL AS SIGNED ) * - ( cor0.col0 ) * - CAST( - 95 AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6552
SELECT - col2 + + CAST ( NULL AS INTEGER ) * - ( cor0.col0 ) * - CAST ( - 95 AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6553
SELECT + + cor0.col2 DIV col1 - + cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-6553
SELECT + + cor0.col2 / col1 - + cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1, tab2 cor0, tab0 cor1
----
972 values hashing to 58757c5bbbd4217c03cf2ac0b6126e55

query I rowsort
SELECT DISTINCT 31 * col0 FROM tab2
----
217
2418
2449

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6556
SELECT - CAST( ( tab2.col0 ) AS SIGNED ) FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

skipif mysql # not compatible
query I rowsort label-6556
SELECT - CAST ( ( tab2.col0 ) AS INTEGER ) FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT + 52 * 61 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 90107ad83570ffc995ed458543e81ce3

query I rowsort
SELECT - col0 * - 76 AS col1 FROM tab0
----
1824
2660
6764

query I rowsort
SELECT col0 * 46 + 34 FROM tab2 AS cor0
----
356
3622
3668

query I rowsort
SELECT - col1 * 61 * - col1 FROM tab1 cor0
----
10309
41236
6100

query I rowsort
SELECT col1 * col2 * - col1 + + col2 FROM tab2 AS cor0
----
-10944
-25920
-90480

query I rowsort
SELECT - col2 + + ( 23 ) * col1 FROM tab1 AS cor0
----
173
203
544

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT - cor0.col2 * col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL 94 * 42 FROM tab0 cor0
----
3948
3948
3948

query I rowsort
SELECT ( - 35 ) FROM tab2 AS cor0
----
-35
-35
-35

query I rowsort
SELECT 87 + + col0 * + col1 FROM tab0 AS cor0
----
2151
3482
8186

query I rowsort
SELECT DISTINCT + ( col1 ) * - col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6569
SELECT ALL + + 14 DIV 3 AS col0 FROM tab2 AS cor0
----
4
4
4

skipif mysql # not compatible
query I rowsort label-6569
SELECT ALL + + 14 / 3 AS col0 FROM tab2 AS cor0
----
4
4
4

query I rowsort
SELECT DISTINCT - 39 * - col2 FROM tab0 AS cor0
----
1287
3198
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6571
SELECT + - CAST( NULL AS SIGNED ) * col1 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6571
SELECT + - CAST ( NULL AS INTEGER ) * col1 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + col1 + - col1 FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT - 64 * + cor0.col2 - + col1 FROM tab1 AS cor0
----
-3482
-3658
-6157

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6574
SELECT DISTINCT tab2.col2 * col1 / CAST( NULL AS SIGNED ) col2 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6574
SELECT DISTINCT tab2.col2 * col1 / CAST ( NULL AS INTEGER ) col2 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT + cor0.col0 + col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT col1 * - col1 - col0 AS col2 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT + 70 + + col2 FROM tab1 AS cor0
----
124
127
166

onlyif mysql # use DIV operator for integer division
query I rowsort label-6578
SELECT ALL - 29 + + col1 - col2 DIV - 88 FROM tab1 AS cor0
----
-15
-19
-3

skipif mysql # not compatible
query I rowsort label-6578
SELECT ALL - 29 + + col1 - col2 / - 88 FROM tab1 AS cor0
----
-15
-19
-3

query I rowsort
SELECT + 5 * ( col2 ) FROM tab2 AS cor0
----
130
135
190

query I rowsort
SELECT - 55 + col1 AS col2 FROM tab1 AS cor0
----
-29
-42
-45

query I rowsort
SELECT ALL + col2 * col1 + col1 AS col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT ALL cor0.col1 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - col0 - 80 AS col1 FROM tab1
----
-144
-160
-83

query I rowsort
SELECT + 89 FROM tab0, tab0 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT ALL col2 + - 5 FROM tab1 AS cor0
----
49
52
91

query I rowsort
SELECT DISTINCT - col2 + 92 - - col1 * ( + col0 + col2 ) FROM tab2 AS cor0
----
1119
2043
6202

query I rowsort
SELECT - + 40 AS col2 FROM tab1 AS cor0
----
-40
-40
-40

query I rowsort
SELECT + col0 * 77 AS col2 FROM tab1 AS cor0
----
231
4928
6160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 85 * 13 + + col0 col2 FROM tab1 AS cor0
----
-1025
-1041
-1102

query I rowsort
SELECT DISTINCT - 55 + col0 FROM tab0 AS cor0
----
-20
-31
34

query I rowsort
SELECT ALL - - 93 - 92 AS col2 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - ( col2 ) * col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6593
SELECT col1 + col1 + + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6593
SELECT col1 + col1 + + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col0 + - col2 + - ( + cor0.col0 + + col0 ) * 35 AS col1 FROM tab1 cor0
----
-267
-4601
-5776

query I rowsort
SELECT - + col2 * cor0.col0 FROM tab0 cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6596
SELECT + + col2 * - col1 + 7 DIV col1 + - cor0.col1 FROM tab2 cor0
----
-1593
-663
-868

skipif mysql # not compatible
query I rowsort label-6596
SELECT + + col2 * - col1 + 7 / col1 + - cor0.col1 FROM tab2 cor0
----
-1593
-663
-868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 68 + - col1 col2 FROM tab0
----
-18
-23
-29

query I rowsort
SELECT - + ( + col1 ) - col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + + col1 + - col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 + + ( col2 ) AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col2 * - col2 + col2 + cor0.col2 FROM tab0 AS cor0
----
1155
3
6888

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6602
SELECT col0 * + CAST( NULL AS SIGNED ) + col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6602
SELECT col0 * + CAST ( NULL AS INTEGER ) + col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 * ( col0 ) + cor0.col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6604
SELECT DISTINCT - + col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6604
SELECT DISTINCT - + col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - + col2 + col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6606
SELECT + - cor0.col0 + - col1 DIV - col0 FROM tab0 AS cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-6606
SELECT + - cor0.col0 + - col1 / - col0 FROM tab0 AS cor0
----
-21
-33
-88

query I rowsort
SELECT DISTINCT - col2 * - tab2.col1 FROM tab2
----
1534
646
837

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab1 AS cor2, tab1
----
13122 values hashing to 10056dbdff161d61931f2724b5488f26

query I rowsort
SELECT ALL cor2.col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 cor2, tab0 cor3
----
243 values hashing to ee8b23a58dda2d92e14ed437e06ed8d2

query I rowsort
SELECT - col0 + col0 + + 17 AS col0 FROM tab1 AS cor0
----
17
17
17

query I rowsort
SELECT ALL - + col0 + ( col2 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT + col2 + - col1 FROM tab0 cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6613
SELECT + col0 + col0 DIV 57 FROM tab1 cor0
----
3
65
81

skipif mysql # not compatible
query I rowsort label-6613
SELECT + col0 + col0 / 57 FROM tab1 cor0
----
3
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6614
SELECT DISTINCT + col0 + ( - 80 ) DIV col2 FROM tab0 AS cor0
----
-45
22
89

skipif mysql # not compatible
query I rowsort label-6614
SELECT DISTINCT + col0 + ( - 80 ) / col2 FROM tab0 AS cor0
----
-45
22
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6615
SELECT ALL - CAST( NULL AS DECIMAL ) / + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6615
SELECT ALL - CAST ( NULL AS REAL ) / + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 38 * 38 AS col1 FROM tab1 AS cor0
----
-1444

onlyif mysql # use DIV operator for integer division
query I rowsort label-6617
SELECT DISTINCT - col2 DIV - 8 + tab2.col0 + + tab2.col0 FROM tab2
----
159
162
17

skipif mysql # not compatible
query I rowsort label-6617
SELECT DISTINCT - col2 / - 8 + tab2.col0 + + tab2.col0 FROM tab2
----
159
162
17

query I rowsort
SELECT col2 + + col0 * col0 FROM tab0
----
1226
609
8003

query I rowsort
SELECT + 41 * - col2 + col2 FROM tab1 cor0
----
-2160
-2280
-3840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6620
SELECT ALL + col2 - + col1 DIV + 75 AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6620
SELECT ALL + col2 - + col1 / + 75 AS col1 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 - col0 * col2 col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL + cor0.col2 * col0 + 32 AS col1 FROM tab0 AS cor0
----
67
7330
824

query I rowsort
SELECT ALL + - 83 * cor0.col1 + + cor0.col1 * - col1 FROM tab2 AS cor0
----
-1700
-3534
-8378

query I rowsort
SELECT 82 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT DISTINCT + + col2 * + col1 * - 63 + - 31 AS col1 FROM tab2 AS cor0
----
-40729
-52762
-96673

onlyif mysql # use DIV operator for integer division
query I rowsort label-6626
SELECT DISTINCT + 48 DIV + cor0.col1 + ( - col1 ) * - col1 * 49 FROM tab2 AS cor0
----
14163
170569
47090

skipif mysql # not compatible
query I rowsort label-6626
SELECT DISTINCT + 48 / + cor0.col1 + ( - col1 ) * - col1 * 49 FROM tab2 AS cor0
----
14163
170569
47090

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6627
SELECT ALL + - col2 + col1 * CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6627
SELECT ALL + - col2 + col1 * CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * col1 + - col0 AS col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT col0 + + tab0.col1 * - tab0.col2 - + 63 AS col1 FROM tab0
----
-125
-2877
-7436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col1 + + col0 col2 FROM tab1
----
29
74
93

query I rowsort
SELECT 71 - col0 AS col1 FROM tab0
----
-18
36
47

query I rowsort
SELECT tab0.col0 + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 13a45e994f0549dd29e84599a57026d0

query I rowsort
SELECT ALL + col2 * + col0 + - col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT - + col1 + + col2 * col0 * + col0 FROM tab0 AS cor0
----
1128
18922
649431

query I rowsort
SELECT DISTINCT - col2 - col2 AS col0 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT + + col0 * col0 + 71 * - col0 AS col2 FROM tab0 cor0
----
-1128
-1260
1602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6637
SELECT ALL col2 * col0 + ( ( tab2.col0 ) * - CAST( NULL AS SIGNED ) ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6637
SELECT ALL col2 * col0 + ( ( tab2.col0 ) * - CAST ( NULL AS INTEGER ) ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( + cor0.col1 ) AS col2 FROM tab2, tab1, tab0 cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT - ( col2 ) + + col0 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT DISTINCT col0 + col1 * - col0 AS col2 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT 42 + tab1.col1 FROM tab1
----
52
55
68

query I rowsort
SELECT DISTINCT ( cor0.col2 ) AS col0 FROM tab2, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT col2 * - tab2.col1 * + tab2.col1 + + ( - 38 ) * + col0 * ( - col1 ) AS col0 FROM tab2
----
-17701
40052
84370

query I rowsort
SELECT + col2 * - 68 * + col2 AS col2 FROM tab1 AS cor0
----
-198288
-220932
-626688

query I rowsort
SELECT - 72 * - col1 FROM tab2 AS cor0
----
1224
2232
4248

query I rowsort
SELECT ALL - - 37 FROM tab1 AS cor0
----
37
37
37

query I rowsort
SELECT DISTINCT ( 8 ) AS col1 FROM tab2
----
8

query I rowsort
SELECT ( 91 ) * - col1 AS col2 FROM tab1
----
-1183
-2366
-910

query I rowsort
SELECT DISTINCT - 94 FROM tab0
----
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 65 - tab1.col0 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 392d14787114a3b84387d3dc39c76776

query I rowsort
SELECT - col2 * col0 + + 94 * + col1 * col2 + - 25 * cor0.col1 FROM tab0 AS cor0
----
263830
6658
691855

query I rowsort
SELECT ALL 65 FROM tab1, tab1 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - ( + col1 ) * + col0 + - ( + tab1.col2 ) col1 FROM tab1
----
-1056
-129
-633

query I rowsort
SELECT DISTINCT + cor0.col1 * 17 AS col1 FROM tab1 AS cor0
----
170
221
442

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6655
SELECT - ( 70 ) * + col2 - CAST( col0 + col0 AS SIGNED ) * + 52 FROM tab1 AS cor0
----
-10646
-15040
-4092

skipif mysql # not compatible
query I rowsort label-6655
SELECT - ( 70 ) * + col2 - CAST ( col0 + col0 AS INTEGER ) * + 52 FROM tab1 AS cor0
----
-10646
-15040
-4092

query I rowsort
SELECT - col2 - col2 * col0 AS col2 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6657
SELECT - CAST( NULL AS DECIMAL ) / + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6657
SELECT - CAST ( NULL AS REAL ) / + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 74 + - 85 * col2 AS col0 FROM tab1 AS cor0
----
-4516
-4771
-8086

query I rowsort
SELECT DISTINCT - col1 * - ( + col2 ) AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + col2 * + ( - col2 + + 38 * col0 ) FROM tab1 AS cor0
----
135375
282624
3240

query I rowsort
SELECT DISTINCT + + col2 + - col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ( - ( cor0.col1 ) ) * + col0 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT 5 + col0 * + col0 FROM tab0 cor0
----
1230
581
7926

query I rowsort
SELECT DISTINCT col2 + 52 * - col2 AS col2 FROM tab2
----
-1326
-1377
-1938

query I rowsort
SELECT DISTINCT - tab2.col0 + ( + col0 ) + col0 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - col1 + + 74 FROM tab0
----
-12
-17
-23

query I rowsort
SELECT 0 * - col0 + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT 53 * + col0 - - col0 FROM tab0 AS cor0
----
1296
1890
4806

query I rowsort
SELECT - col2 + 35 + 52 FROM tab1
----
-9
30
33

query I rowsort
SELECT - - ( col0 ) - - cor0.col1 * 38 AS col2 FROM tab0 cor0
----
3292
3547
3721

query I rowsort
SELECT + - col0 + + ( + col0 ) AS col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + ( + tab2.col2 ) * + col2 ) - + col1 * col0 * + col1 col0 FROM tab2
----
-21387
-270842
-5998

query I rowsort
SELECT 90 * + 90 * col0 + + tab1.col2 + tab1.col1 FROM tab1
----
24380
518467
648109

query I rowsort
SELECT + ( + 53 ) + col1 FROM tab0 AS cor0
----
139
144
150

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6675
SELECT ALL + CAST( NULL AS DECIMAL ) * col2 + col2 * ( col1 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6675
SELECT ALL + CAST ( NULL AS REAL ) * col2 + col2 * ( col1 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6676
SELECT + CAST( ( + col1 ) AS SIGNED ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6676
SELECT + CAST ( ( + col1 ) AS INTEGER ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - + col1 * 48 AS col0 FROM tab0 AS cor0
----
-4128
-4368
-4656

query I rowsort
SELECT DISTINCT ( cor0.col1 ) + col1 AS col0 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT ALL - col1 * col1 * col0 AS col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT + cor0.col0 - - cor0.col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT col2 * + col2 + - col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT col1 + col2 * col2 * - col1 AS col0 FROM tab0 AS cor0
----
-611793
-93568
0

query I rowsort
SELECT DISTINCT - 21 * + col2 AS col0 FROM tab1 cor0
----
-1134
-1197
-2016

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6684
SELECT 62 * col0 * CAST( NULL AS SIGNED ) - 86 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6684
SELECT 62 * col0 * CAST ( NULL AS INTEGER ) - 86 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6685
SELECT ALL + cor0.col1 * - col1 + - CAST( col2 AS SIGNED ) * - col2 * - 90 FROM tab2 AS cor0
----
-130249
-64321
-66571

skipif mysql # not compatible
query I rowsort label-6685
SELECT ALL + cor0.col1 * - col1 + - CAST ( col2 AS INTEGER ) * - col2 * - 90 FROM tab2 AS cor0
----
-130249
-64321
-66571

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 99 ) col1 FROM tab0
----
-99
-99
-99

query I rowsort
SELECT ALL - ( col1 + col2 ) * 85 FROM tab0
----
-10115
-14705
-8330

query I rowsort
SELECT + col0 + + ( + col2 ) AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL 82 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT - 49 AS col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to adfccb10c9468825d9961e3613140f89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6692
SELECT col2 * col0 * - CAST( col1 AS SIGNED ) col2 FROM tab0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6692
SELECT col2 * col0 * - CAST ( col1 AS INTEGER ) col2 FROM tab0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 30 col0 FROM tab2
----
30
30
30

query I rowsort
SELECT - col1 - + col2 AS col2 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT + 46 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT 51 * - col1 + - col1 FROM tab1 AS cor0
----
-1352
-520
-676

query I rowsort
SELECT DISTINCT col1 * cor0.col0 + 59 AS col0 FROM tab2 AS cor0
----
1402
276
4661

query I rowsort
SELECT DISTINCT - - col2 * col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT col0 * + col0 + 69 * + col0 FROM tab2 AS cor0
----
11466
11692
532

query I rowsort
SELECT ALL 69 * + cor0.col0 * col1 FROM tab1 AS cor0
----
44160
5382
71760

query I rowsort
SELECT DISTINCT - col2 - col0 * col1 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT + ( col2 ) * + tab2.col2 FROM tab2
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-6703
SELECT col1 DIV 79 - col0 * 72 AS col0 FROM tab1
----
-216
-4608
-5760

skipif mysql # not compatible
query I rowsort label-6703
SELECT col1 / 79 - col0 * 72 AS col0 FROM tab1
----
-216
-4608
-5760

query I rowsort
SELECT col2 + col2 + col2 AS col2 FROM tab2
----
114
78
81

query I rowsort
SELECT col0 + cor0.col2 * - col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT + 55 + + col2 AS col0 FROM tab2 AS cor0
----
81
82
93

query I rowsort
SELECT 36 * - ( + col0 * col2 ) FROM tab2
----
-108072
-6804
-73008

query I rowsort
SELECT DISTINCT 37 AS col0 FROM tab1, tab0 AS cor0
----
37

query I rowsort
SELECT ALL col0 + - ( col2 ) + - col1 AS col0 FROM tab0 AS cor0
----
-63
-84
-95

query I rowsort
SELECT 4 + + col2 AS col2 FROM tab2
----
30
31
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col0 + ( - tab0.col1 ) col2 FROM tab0
----
-63
-84
-95

query I rowsort
SELECT - 48 + + col0 FROM tab0
----
-13
-24
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-6713
SELECT ALL tab1.col0 DIV cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 013f5a9556a0e563417864375ceab6b6

skipif mysql # not compatible
query I rowsort label-6713
SELECT ALL tab1.col0 / cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 013f5a9556a0e563417864375ceab6b6

query I rowsort
SELECT ALL 58 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT + 23 * col0 FROM tab1 cor0
----
1472
1840
69

query I rowsort
SELECT DISTINCT + - ( cor0.col0 ) + + cor0.col2 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6717
SELECT ALL 9 DIV - col0 AS col2 FROM tab1 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-6717
SELECT ALL 9 / - col0 AS col2 FROM tab1 AS cor0
----
-3
0
0

query I rowsort
SELECT - + col0 - - col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 16 FROM tab0, tab1 cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT - col1 - + 24 AS col2 FROM tab2
----
-41
-55
-83

query I rowsort
SELECT 2 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT ALL - col1 - col0 * + col1 * col2 AS col1 FROM tab0
----
-3492
-664209
-68198

query I rowsort
SELECT ALL - col1 - + col0 * col0 FROM tab0
----
-1322
-662
-8012

query I rowsort
SELECT ALL - cor0.col2 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6725
SELECT ALL - + 34 * + 39 + - col2 - - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6725
SELECT ALL - + 34 * + 39 + - col2 - - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 38 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
38

query I rowsort
SELECT DISTINCT - ( + ( + col2 ) ) * 96 - + 29 * + cor0.col0 * ( - col0 ) FROM tab1 AS cor0
----
-4923
113312
176384

query I rowsort
SELECT DISTINCT + 2 + + cor0.col2 * col1 FROM tab2 cor0
----
1536
648
839

query I rowsort
SELECT cor0.col2 * + 49 - + col0 FROM tab2 AS cor0
----
1196
1316
1783

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6730
SELECT - - CAST( NULL AS SIGNED ) * + col0 + col1 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6730
SELECT - - CAST ( NULL AS INTEGER ) * + col0 + col1 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6731
SELECT ALL col1 DIV - col1 + - col2 * + ( - col2 ) FROM tab1
----
2915
3248
9215

skipif mysql # not compatible
query I rowsort label-6731
SELECT ALL col1 / - col1 + - col2 * + ( - col2 ) FROM tab1
----
2915
3248
9215

onlyif mysql # use DIV operator for integer division
query I rowsort label-6732
SELECT ALL col1 DIV + ( col0 ) - - tab0.col2 * col0 FROM tab0
----
37
7299
795

skipif mysql # not compatible
query I rowsort label-6732
SELECT ALL col1 / + ( col0 ) - - tab0.col2 * col0 FROM tab0
----
37
7299
795

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) + - col1 col2 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT - 59 + col2 FROM tab1 AS cor0
----
-2
-5
37

query I rowsort
SELECT ALL - cor0.col1 + 80 * - col1 AS col0 FROM tab0 AS cor0
----
-6966
-7371
-7857

query I rowsort
SELECT + 78 * + col2 + col0 FROM tab0 AS cor0
----
113
2598
6485

onlyif mysql # use DIV operator for integer division
query I rowsort label-6737
SELECT DISTINCT - col1 * - ( cor0.col2 ) DIV 1 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-6737
SELECT DISTINCT - col1 * - ( cor0.col2 ) / 1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + - 44 FROM tab1 AS cor0
----
-44

query I rowsort
SELECT ALL + 22 * col1 AS col2 FROM tab1 AS cor0
----
220
286
572

onlyif mysql # use DIV operator for integer division
query I rowsort label-6740
SELECT - cor0.col2 DIV - col2 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6740
SELECT - cor0.col2 / - col2 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT ALL 55 + + ( + col1 ) AS col1 FROM tab0 AS cor0
----
141
146
152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( col2 ) * cor0.col0 + - cor0.col1 * cor0.col0 col2 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT DISTINCT ( - col0 ) + col2 AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT 48 + col2 AS col2 FROM tab0 AS cor0
----
130
49
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6745
SELECT + + col2 * + col1 + ( cor0.col2 ) DIV cor0.col1 col1 FROM tab1 AS cor0
----
1255
1406
575

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6745
SELECT + + col2 * + col1 + ( cor0.col2 ) / cor0.col1 col1 FROM tab1 AS cor0
----
1255
1406
575

query I rowsort
SELECT DISTINCT + 70 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1680
2450
6230

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col0 ) - ( - col2 + + cor0.col1 ) * col2 col0 FROM tab1 AS cor0
----
1509
2615
7888

query I rowsort
SELECT + col0 * - col2 + + col1 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT ALL + + 82 * col0 FROM tab0 AS cor0
----
1968
2870
7298

query I rowsort
SELECT ( col0 ) + col2 AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT - 51 * col1 + col1 FROM tab1 AS cor0
----
-1300
-500
-650

query I rowsort
SELECT DISTINCT - - col1 + - col1 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT + 81 FROM tab2, tab2 AS cor0
----
81

query I rowsort
SELECT + - col2 * 20 FROM tab2 AS cor0
----
-520
-540
-760

query I rowsort
SELECT - 64 * tab1.col2 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to dc9f6aa73c98026989903b0099524e96

query I rowsort
SELECT col1 + + 67 AS col0 FROM tab2
----
126
84
98

query I rowsort
SELECT ALL - + col2 + col1 * - col1 AS col1 FROM tab0 cor0
----
-7429
-8363
-9410

query I rowsort
SELECT ALL col0 * 48 FROM tab0 AS cor0
----
1152
1680
4272

query I rowsort
SELECT - + ( 68 ) + - col1 * + col0 FROM tab1 AS cor0
----
-1108
-146
-708

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6760
SELECT DISTINCT + CAST( + col0 AS SIGNED ) FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6760
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT col0 + + col2 * col2 FROM tab0 AS cor0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-6762
SELECT + 88 + + col1 DIV col2 AS col0 FROM tab0 AS cor0
----
185
89
90

skipif mysql # not compatible
query I rowsort label-6762
SELECT + 88 + + col1 / col2 AS col0 FROM tab0 AS cor0
----
185
89
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6763
SELECT - + col1 + ( col2 ) DIV 89 AS col2 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6763
SELECT - + col1 + ( col2 ) / 89 AS col2 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col2 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-6765
SELECT + col1 DIV + 56 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6765
SELECT + col1 / + 56 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6766
SELECT DISTINCT - CAST( NULL AS SIGNED ) + col2 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6766
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + col2 AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6767
SELECT DISTINCT + col1 * col2 DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6767
SELECT DISTINCT + col1 * col2 / col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * + cor0.col2 + col2 col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT tab2.col2 * - tab2.col2 + 55 FROM tab2
----
-1389
-621
-674

query I rowsort
SELECT col0 * col2 + - col1 FROM tab1 cor0
----
136
3638
7667

query I rowsort
SELECT - col0 * + col1 - col0 AS col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT 37 + tab2.col2 FROM tab2
----
63
64
75

query I rowsort
SELECT ALL tab2.col1 + 23 FROM tab2
----
40
54
82

query I rowsort
SELECT ALL - col0 * + col0 + col1 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT ALL + col1 * col1 + + ( col2 ) * - col2 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-21638
-24259
-36403

query I rowsort
SELECT ALL + ( 54 ) FROM tab1
----
54
54
54

query I rowsort
SELECT DISTINCT 85 * col0 AS col0 FROM tab2
----
595
6630
6715

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 + col2 AS REAL ) FROM tab1
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6779
SELECT ALL CAST( + 87 AS SIGNED ) * col1 FROM tab1
----
1131
2262
870

skipif mysql # not compatible
query I rowsort label-6779
SELECT ALL CAST ( + 87 AS INTEGER ) * col1 FROM tab1
----
1131
2262
870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6780
SELECT ALL CAST( NULL AS SIGNED ) * col0 * col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6780
SELECT ALL CAST ( NULL AS INTEGER ) * col0 * col2 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 * 43 FROM tab1 AS cor0
----
2322
2451
4128

onlyif mysql # use DIV operator for integer division
query I rowsort label-6782
SELECT DISTINCT + 23 DIV 78 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6782
SELECT DISTINCT + 23 / 78 AS col1 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 * - col2 col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 54 col1 FROM tab1
----
54

query I rowsort
SELECT + ( + col1 ) AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT + col0 * - col2 AS col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - ( col0 ) * + 24 + col1 FROM tab1 cor0
----
-1526
-1907
-46

query I rowsort
SELECT DISTINCT 23 AS col0 FROM tab2 AS cor0
----
23

query I rowsort
SELECT ALL + 91 * + col2 * col2 FROM tab0 AS cor0
----
611884
91
99099

query I rowsort
SELECT ALL + + 46 * - col2 FROM tab1 AS cor0
----
-2484
-2622
-4416

query I rowsort
SELECT DISTINCT - 34 FROM tab1 cor0
----
-34

query I rowsort
SELECT 24 * + col1 + 16 AS col1 FROM tab0 cor0
----
2080
2200
2344

query I rowsort
SELECT DISTINCT 44 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
44

query I rowsort
SELECT 96 FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

query I rowsort
SELECT - 89 * - col0 AS col1 FROM tab1 AS cor0
----
267
5696
7120

query I rowsort
SELECT ALL - 66 AS col1 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

query I rowsort
SELECT + + col1 * 76 FROM tab1 AS cor0
----
1976
760
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-6798
SELECT - + cor0.col1 DIV + ( + col1 ) AS col1 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6798
SELECT - + cor0.col1 / + ( + col1 ) AS col1 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT cor0.col1 + cor0.col0 * - col1 FROM tab1 cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-6800
SELECT + col1 DIV col2 AS col1 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-6800
SELECT + col1 / col2 AS col1 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT - - col0 + - 54 * - col2 AS col1 FROM tab0 AS cor0
----
1806
4517
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - 77 col0 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT + col2 + 24 * + 69 AS col0 FROM tab0 AS cor0
----
1657
1689
1738

query I rowsort
SELECT DISTINCT col1 + + col2 * - col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT - cor0.col1 * + 35 FROM tab0 AS cor0
----
-3010
-3185
-3395

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) + - col2 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT col1 + - 3 FROM tab2 AS cor0
----
14
28
56

query I rowsort
SELECT - - ( + col2 ) - - cor0.col0 * 51 FROM tab2 AS cor0
----
384
4004
4067

query I rowsort
SELECT - - col1 + cor0.col1 * col1 AS col1 FROM tab0 cor0
----
7482
8372
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - 20 col2 FROM tab0 cor0
----
15
4
69

query I rowsort
SELECT col0 + 97 FROM tab0 AS cor0
----
121
132
186

query I rowsort
SELECT + 21 * col1 + col2 AS col2 FROM tab2 AS cor0
----
1265
395
678

query I rowsort
SELECT + col2 * tab1.col1 + + col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT ALL - cor1.col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6815
SELECT - 84 + - tab2.col1 DIV + col0 FROM tab2
----
-84
-84
-88

skipif mysql # not compatible
query I rowsort label-6815
SELECT - 84 + - tab2.col1 / + col0 FROM tab2
----
-84
-84
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6816
SELECT ALL + CAST( - col2 AS SIGNED ) + - col1 FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort label-6816
SELECT ALL + CAST ( - col2 AS INTEGER ) + - col1 FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6817
SELECT ALL - + CAST( - col0 AS SIGNED ) + col2 DIV - 45 FROM tab0 AS cor0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-6817
SELECT ALL - + CAST ( - col0 AS INTEGER ) + col2 / - 45 FROM tab0 AS cor0
----
24
35
88

query I rowsort
SELECT - + 73 + col1 FROM tab1 AS cor0
----
-47
-60
-63

query I rowsort
SELECT ALL - - 84 + - col2 AS col1 FROM tab1 cor0
----
-12
27
30

query I rowsort
SELECT 76 * col0 + - col2 AS col2 FROM tab2 AS cor0
----
505
5902
5966

query I rowsort
SELECT + ( - col1 ) + + col0 AS col0 FROM tab0 cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 80 * + ( - col0 ) col0 FROM tab1 AS cor0
----
240
5120
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 col0 FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6824
SELECT DISTINCT - col1 * col2 * CAST( + cor0.col0 AS SIGNED ) FROM tab1 AS cor0
----
-36480
-4212
-99840

skipif mysql # not compatible
query I rowsort label-6824
SELECT DISTINCT - col1 * col2 * CAST ( + cor0.col0 AS INTEGER ) FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6825
SELECT ALL + + cor0.col1 DIV + col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6825
SELECT ALL + + cor0.col1 / + col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL 38 FROM tab1 AS cor0
----
38
38
38

query I rowsort
SELECT ( + ( + tab1.col1 ) ) + - tab1.col0 + col2 FROM tab1
----
29
3
77

query I rowsort
SELECT 69 * col0 * col2 + 82 FROM tab1
----
11260
251794
530002

query I rowsort
SELECT 37 * cor0.col1 + col2 * col0 + + col0 FROM tab1 AS cor0
----
1127
4082
8241

query I rowsort
SELECT DISTINCT - ( + col2 ) * ( - col0 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - + 42 + cor0.col0 FROM tab0 AS cor0
----
-18
-7
47

query I rowsort
SELECT DISTINCT col0 - col2 AS col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT DISTINCT - - cor0.col2 + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + + col2 + + 74 * 88 FROM tab1 AS cor0
----
6566
6569
6608

query I rowsort
SELECT DISTINCT - cor0.col0 + + col2 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + col1 * + col1 + + col1 - col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + - col1 * 24 FROM tab0 AS cor0
----
-2064
-2184
-2328

query I rowsort
SELECT DISTINCT + col1 + - col0 FROM tab0 cor0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6839
SELECT ( - col1 + + CAST( col1 AS SIGNED ) ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6839
SELECT ( - col1 + + CAST ( col1 AS INTEGER ) ) FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col2 * + col2 - - col2 AS col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT - col0 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT - + ( col1 ) * + col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6843
SELECT DISTINCT CAST( col0 AS SIGNED ) * + col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-6843
SELECT DISTINCT CAST ( col0 AS INTEGER ) * + col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6844
SELECT col1 DIV - col0 - + col1 AS col1 FROM tab1
----
-10
-13
-34

skipif mysql # not compatible
query I rowsort label-6844
SELECT col1 / - col0 - + col1 AS col1 FROM tab1
----
-10
-13
-34

query I rowsort
SELECT ALL + 75 + 30 FROM tab2, tab0 AS cor0
----
9 values hashing to a8f8daa1a1bfedb1421594e2314a6b6d

query I rowsort
SELECT - 98 * col1 AS col0 FROM tab2 AS cor0
----
-1666
-3038
-5782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + cor0.col1 col2 FROM tab1 cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 42 * col1 + - col2 col1 FROM tab0 AS cor0
----
-3645
-3904
-4075

query I rowsort
SELECT DISTINCT col1 + + 49 AS col0 FROM tab0 AS cor0
----
135
140
146

query I rowsort
SELECT DISTINCT ( col2 ) + col2 * ( col0 ) + col1 AS col0 FROM tab2 AS cor0
----
2113
247
3057

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6851
SELECT + col0 + CAST( - 26 AS SIGNED ) FROM tab0
----
-2
63
9

skipif mysql # not compatible
query I rowsort label-6851
SELECT + col0 + CAST ( - 26 AS INTEGER ) FROM tab0
----
-2
63
9

query I rowsort
SELECT col1 - - 6 * + col1 FROM tab0
----
602
637
679

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 + + col0 * col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - ( 38 ) * col1 AS col1 FROM tab0 AS cor0
----
-3268
-3458
-3686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6856
SELECT + CAST( col0 AS SIGNED ) + + col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6856
SELECT + CAST ( col0 AS INTEGER ) + + col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 25 + col0 * col2 AS col2 FROM tab0 AS cor0
----
60
7323
817

query I rowsort
SELECT ALL - - ( - col1 ) + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-20
-26
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6859
SELECT ALL - ( ( - col1 ) ) + - col1 DIV + col1 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-6859
SELECT ALL - ( ( - col1 ) ) + - col1 / + col1 FROM tab2 AS cor0
----
16
30
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-6860
SELECT 42 DIV 7 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

skipif mysql # not compatible
query I rowsort label-6860
SELECT 42 / 7 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

onlyif mysql # use DIV operator for integer division
query I rowsort label-6861
SELECT ALL 11 DIV + col2 AS col0 FROM tab0 AS cor0
----
0
0
11

skipif mysql # not compatible
query I rowsort label-6861
SELECT ALL 11 / + col2 AS col0 FROM tab0 AS cor0
----
0
0
11

query I rowsort
SELECT - 8 AS col2 FROM tab2 AS cor0
----
-8
-8
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6863
SELECT 66 * + tab2.col2 + - CAST( NULL AS DECIMAL ) * - col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6863
SELECT 66 * + tab2.col2 + - CAST ( NULL AS REAL ) * - col2 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + tab0.col1 + col1 * 55 * - ( col0 ) FROM tab0
----
-113434
-186628
-445354

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - ( 59 ) col2 FROM tab0 AS cor0
----
-1947
-4838
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor1.col2 col0 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6867
SELECT + CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6867
SELECT + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - col2 * tab0.col2 + 48 FROM tab0
----
-1041
-6676
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 14 * col0 + 98 col2 FROM tab1 AS cor0
----
-1022
-798
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-6870
SELECT - - cor0.col0 DIV col1 + + ( 70 + - col2 ) AS col1 FROM tab2 AS cor0
----
36
43
45

skipif mysql # not compatible
query I rowsort label-6870
SELECT - - cor0.col0 / col1 + + ( 70 + - col2 ) AS col1 FROM tab2 AS cor0
----
36
43
45

query I rowsort
SELECT - col0 * + col0 * + col0 AS col1 FROM tab2
----
-343
-474552
-493039

query I rowsort
SELECT + 26 * col2 FROM tab2
----
676
702
988

query I rowsort
SELECT - 73 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

query I rowsort
SELECT col2 + 87 * + col1 FROM tab2 cor0
----
1517
2724
5159

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6875
SELECT ALL col2 * CAST( NULL AS SIGNED ) / col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6875
SELECT ALL col2 * CAST ( NULL AS INTEGER ) / col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab1 cor1, tab2, tab1 cor2
----
3645 values hashing to 731e4a6549b312ba21c2e61ca9bede27

query I rowsort
SELECT DISTINCT 83 AS col0 FROM tab1, tab0 cor0, tab2 AS cor1
----
83

query I rowsort
SELECT ALL - col1 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - - cor0.col1 * col0 * + col1 + col2 * col0 AS col1 FROM tab0 AS cor0
----
178296
329350
744307

onlyif mysql # use DIV operator for integer division
query I rowsort label-6880
SELECT - col2 DIV + col0 col1 FROM tab1 AS cor0
----
-1
-18
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6880
SELECT - col2 / + col0 col1 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT ( col2 ) * + cor0.col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT col1 * ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - + col2 * + ( - 51 ) AS col0 FROM tab1 AS cor0
----
2754
2907
4896

query I rowsort
SELECT - col1 - - 10 AS col1 FROM tab1 AS cor0
----
-16
-3
0

query I rowsort
SELECT ALL + 48 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - col2 * + ( 74 ) FROM tab0
----
-2442
-6068
-74

query I rowsort
SELECT + 49 * 99 * + cor0.col2 FROM tab2 AS cor0
----
126126
130977
184338

query I rowsort
SELECT cor0.col0 * - 2 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to f695e8ac4bda97d478d6d74ae91ee549

onlyif mysql # use DIV operator for integer division
query I rowsort label-6890
SELECT tab1.col2 DIV cor0.col1 AS col0 FROM tab1, tab1 cor0, tab2, tab2 AS cor1
----
81 values hashing to edb70c6a4980277392451625012e9a77

skipif mysql # not compatible
query I rowsort label-6890
SELECT tab1.col2 / cor0.col1 AS col0 FROM tab1, tab1 cor0, tab2, tab2 AS cor1
----
81 values hashing to edb70c6a4980277392451625012e9a77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col2 col0 FROM tab0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 24 col0 FROM tab1
----
24
24
24

query I rowsort
SELECT DISTINCT ( 42 + - col2 ) AS col2 FROM tab0
----
-40
41
9

query I rowsort
SELECT ALL + 76 * 9 * col0 AS col0 FROM tab1
----
2052
43776
54720

query I rowsort
SELECT - 7 * col2 AS col1 FROM tab1 AS cor0
----
-378
-399
-672

query I rowsort
SELECT DISTINCT 53 + 41 AS col0 FROM tab1 AS cor0
----
94

query I rowsort
SELECT DISTINCT + 47 AS col2 FROM tab1 AS cor0
----
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-6898
SELECT cor0.col2 DIV cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 1cd643253f19b663914c5dbb8be19829

skipif mysql # not compatible
query I rowsort label-6898
SELECT cor0.col2 / cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 1cd643253f19b663914c5dbb8be19829

query I rowsort
SELECT ALL + col2 + - cor0.col0 + + ( col0 ) AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + 70 * 70 AS col1 FROM tab2
----
4900
4900
4900

query I rowsort
SELECT DISTINCT 1 * col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT col1 * col1 + 27 FROM tab1 AS cor0
----
127
196
703

query I rowsort
SELECT + ( + cor1.col1 ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL - + 34 + + col1 AS col0 FROM tab0 cor0
----
52
57
63

query I rowsort
SELECT 70 AS col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT DISTINCT tab0.col0 FROM tab0, tab1, tab1 AS cor0
----
24
35
89

query I rowsort
SELECT - col1 + 8 AS col0 FROM tab0 AS cor0
----
-78
-83
-89

query I rowsort
SELECT - cor0.col1 * col1 + 65 * col1 * - ( col0 ) FROM tab2 cor0
----
-15066
-302611
-87584

query I rowsort
SELECT DISTINCT + col0 + + col2 - + ( - tab2.col0 ) * ( col1 ) FROM tab2
----
1460
251
4706

query I rowsort
SELECT col2 * col1 - col1 AS col2 FROM tab1
----
1235
1378
560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6911
SELECT CAST( + 49 AS SIGNED ) * col1 + col1 FROM tab1 AS cor0
----
1300
500
650

skipif mysql # not compatible
query I rowsort label-6911
SELECT CAST ( + 49 AS INTEGER ) * col1 + col1 FROM tab1 AS cor0
----
1300
500
650

query I rowsort
SELECT + - col0 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT + - col0 + col1 * + col0 AS col1 FROM tab1 cor0
----
576
75
960

query I rowsort
SELECT + col1 + col1 * + col2 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - col0 + + 93 FROM tab0 AS cor0
----
4
58
69

query I rowsort
SELECT DISTINCT 13 + - col0 * col1 * col0 AS col1 FROM tab2 AS cor0
----
-106084
-1506
-358943

query I rowsort
SELECT DISTINCT - col1 * - col1 + + col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT - ( - col0 ) * col1 + - col2 + col0 FROM tab2 AS cor0
----
1384
197
4654

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6919
SELECT - CAST( NULL AS SIGNED ) + cor0.col1 col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6919
SELECT - CAST ( NULL AS INTEGER ) + cor0.col1 col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 96 * col1 col1 FROM tab1 cor0
----
1248
2496
960

query I rowsort
SELECT - 63 + - col1 AS col1 FROM tab0
----
-149
-154
-160

query I rowsort
SELECT + col2 * col1 * - 30 + col2 * + col0 AS col1 FROM tab1
----
-13452
-29760
-41958

query I rowsort
SELECT col0 + col0 * - col1 * + col0 FROM tab0
----
-118790
-49512
-720722

query I rowsort
SELECT col2 * col2 + col1 * + col2 FROM tab0 AS cor0
----
14186
3927
98

query I rowsort
SELECT ALL - col2 * 85 FROM tab0 cor0
----
-2805
-6970
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6926
SELECT + col2 DIV + col0 + col2 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-6926
SELECT + col2 / + col0 + col2 FROM tab1 AS cor0
----
57
72
97

query I rowsort
SELECT ALL + - col2 * + ( - col0 + - col0 ) FROM tab1 AS cor0
----
15360
324
7296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6928
SELECT ALL - col1 * - CAST( col2 * col2 AS SIGNED ) FROM tab2 AS cor0
----
22599
24548
39884

skipif mysql # not compatible
query I rowsort label-6928
SELECT ALL - col1 * - CAST ( col2 * col2 AS INTEGER ) FROM tab2 AS cor0
----
22599
24548
39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-6929
SELECT ALL + col2 DIV + 96 col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6929
SELECT ALL + col2 / + 96 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + 26 AS col1 FROM tab0 AS cor0
----
-56
-7
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6931
SELECT ALL + col0 + + CAST( 31 * + col2 AS SIGNED ) AS col0 FROM tab2
----
1257
844
884

skipif mysql # not compatible
query I rowsort label-6931
SELECT ALL + col0 + + CAST ( 31 * + col2 AS INTEGER ) AS col0 FROM tab2
----
1257
844
884

query I rowsort
SELECT col0 * 14 FROM tab1
----
1120
42
896

onlyif mysql # use DIV operator for integer division
query I rowsort label-6933
SELECT ALL - col1 * ( + 23 ) DIV col2 AS col2 FROM tab1 AS cor0
----
-11
-3
-4

skipif mysql # not compatible
query I rowsort label-6933
SELECT ALL - col1 * ( + 23 ) / col2 AS col2 FROM tab1 AS cor0
----
-11
-3
-4

query I rowsort
SELECT + col1 * - 10 - - col1 FROM tab2 AS cor0
----
-153
-279
-531

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col2 col1 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort
SELECT col2 * CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6937
SELECT + CAST( NULL AS SIGNED ) FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6937
SELECT + CAST ( NULL AS INTEGER ) FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - col1 * col1 + - col1 FROM tab0 cor0
----
-7482
-8372
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6939
SELECT col0 DIV 36 AS col0 FROM tab2 AS cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-6939
SELECT col0 / 36 AS col0 FROM tab2 AS cor0
----
0
2
2

query I rowsort
SELECT DISTINCT - col1 * + cor0.col0 + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-6941
SELECT col0 * - cor0.col0 + - col1 DIV col1 FROM tab2 AS cor0
----
-50
-6085
-6242

skipif mysql # not compatible
query I rowsort label-6941
SELECT col0 * - cor0.col0 + - col1 / col1 FROM tab2 AS cor0
----
-50
-6085
-6242

query I rowsort
SELECT ALL - col2 - + col1 * + 28 * col0 FROM tab2 AS cor0
----
-128882
-37642
-6103

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6943
SELECT + col2 / col1 + ( + col2 * + CAST( NULL AS SIGNED ) ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6943
SELECT + col2 / col1 + ( + col2 * + CAST ( NULL AS INTEGER ) ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( tab1.col1 + 85 ) * + 98 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 9db383cbbd9d88b2ffd7f90e0da9ae95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6945
SELECT - ( 76 ) DIV + col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6945
SELECT - ( 76 ) / + col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL + col1 + 15 AS col1 FROM tab1 cor0
----
25
28
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6947
SELECT ALL - + 86 * - 98 + + col0 * CAST( col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
13030
8645
9771

skipif mysql # not compatible
query I rowsort label-6947
SELECT ALL - + 86 * - 98 + + col0 * CAST ( col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
13030
8645
9771

onlyif mysql # use DIV operator for integer division
query I rowsort label-6948
SELECT col2 + + col1 DIV col0 + CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
55
62
85

skipif mysql # not compatible
query I rowsort label-6948
SELECT col2 + + col1 / col0 + CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
55
62
85

query I rowsort
SELECT + col2 * - 57 AS col1 FROM tab1 AS cor0
----
-3078
-3249
-5472

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 * + 94 + col0 col2 FROM tab2 AS cor0
----
1677
2921
5624

query I rowsort
SELECT + 38 * col1 FROM tab2 AS cor0
----
1178
2242
646

query I rowsort
SELECT ALL + 77 + col0 * col1 AS col1 FROM tab1 AS cor0
----
1117
155
717

onlyif mysql # use DIV operator for integer division
query I rowsort label-6953
SELECT DISTINCT + col2 + 98 * col0 DIV - 64 AS col1 FROM tab1 cor0
----
-26
-41
50

skipif mysql # not compatible
query I rowsort label-6953
SELECT DISTINCT + col2 + 98 * col0 / - 64 AS col1 FROM tab1 cor0
----
-26
-41
50

query I rowsort
SELECT DISTINCT col0 + - col2 * - col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - col0 + col1 * - ( col1 + - cor0.col1 ) FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT col1 + - col1 * + ( - cor0.col0 ) FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-6957
SELECT - - cor0.col1 DIV + cor0.col0 col2 FROM tab1 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6957
SELECT - - cor0.col1 / + cor0.col0 col2 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT ALL + col2 + + col1 FROM tab1 cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6959
SELECT ALL + 22 DIV - col1 FROM tab1 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-6959
SELECT ALL + 22 / - col1 FROM tab1 AS cor0
----
-1
-2
0

query I rowsort
SELECT - - 73 * + col0 FROM tab0 AS cor0
----
1752
2555
6497

query I rowsort
SELECT 16 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT - cor0.col2 + - col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT col0 + col2 + - col2 * + cor0.col2 FROM tab0 AS cor0
----
-1032
-6553
35

query I rowsort
SELECT ALL - col2 + cor0.col2 * 62 FROM tab1 AS cor0
----
3294
3477
5856

query I rowsort
SELECT DISTINCT + - col2 + col2 + + ( - col0 + - col2 ) FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT col1 + + col0 * col2 + col0 AS col2 FROM tab1 cor0
----
191
3722
7773

query I rowsort
SELECT ALL - col0 * col0 - - col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL + cor0.col2 + col2 + - col1 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT ALL + - ( col1 ) * + col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - + col1 * - cor0.col1 + + col2 FROM tab1 cor0
----
157
265
730

query I rowsort
SELECT - col1 * + cor0.col1 FROM tab0 cor0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 16 - - col1 * + col2 FROM tab0
----
113
2854
7478

onlyif mysql # use DIV operator for integer division
query I rowsort label-6975
SELECT DISTINCT + col2 DIV - cor0.col1 + - ( cor0.col1 ) FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6975
SELECT DISTINCT + col2 / - cor0.col1 + - ( cor0.col1 ) FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT 52 + + col0 AS col2 FROM tab1 AS cor0
----
116
132
55

query I rowsort
SELECT DISTINCT - 60 + + col0 AS col0 FROM tab0 AS cor0
----
-25
-36
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6978
SELECT - 69 + col1 * CAST( NULL AS SIGNED ) / + 53 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6978
SELECT - 69 + col1 * CAST ( NULL AS INTEGER ) / + 53 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * - col2 + col1 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT + 0 * 14 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - cor0.col1 + + 68 * col2 FROM tab1 AS cor0
----
3646
3866
6515

query I rowsort
SELECT DISTINCT - - cor0.col1 FROM tab1, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT cor1.col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL + + 29 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT DISTINCT - 60 - col0 AS col2 FROM tab2 AS cor0
----
-138
-139
-67

query I rowsort
SELECT ALL - + col0 * col1 * col0 AS col0 FROM tab0 AS cor0
----
-118825
-49536
-720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-6987
SELECT col0 + - col1 DIV tab2.col0 AS col0 FROM tab2
----
3
78
79

skipif mysql # not compatible
query I rowsort label-6987
SELECT col0 + - col1 / tab2.col0 AS col0 FROM tab2
----
3
78
79

query I rowsort
SELECT DISTINCT 29 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
29

query I rowsort
SELECT ALL 24 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT ALL 56 + col0 FROM tab2
----
134
135
63

query I rowsort
SELECT ALL - 42 * col2 + + col0 FROM tab0 AS cor0
----
-1362
-3355
-7

query I rowsort
SELECT DISTINCT + 59 * - col1 FROM tab2 AS cor0
----
-1003
-1829
-3481

query I rowsort
SELECT + + 9 + col1 FROM tab0 cor0
----
100
106
95

query I rowsort
SELECT DISTINCT col0 * + col2 + + col2 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL ( col1 ) + col2 * ( - 41 + - col2 ) FROM tab0 AS cor0
----
-2356
-9995
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-6996
SELECT ALL col2 DIV + col0 AS col1 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6996
SELECT ALL col2 / + col0 AS col1 FROM tab1
----
0
1
18

query I rowsort
SELECT - col1 * + ( ( - col1 ) ) + + 15 * cor0.col0 * col0 AS col0 FROM tab1 AS cor0
----
61540
811
96169

query I rowsort
SELECT - col0 + col2 + col2 AS col2 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT - col2 + col0 * - col0 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT + - col1 * ( col0 ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 37 * cor0.col2 * - col2 FROM tab2 cor0
----
25012
26973
53428

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7002
SELECT + CAST( 63 AS SIGNED ) + col2 * - col2 FROM tab0 AS cor0
----
-1026
-6661
62

skipif mysql # not compatible
query I rowsort label-7002
SELECT + CAST ( 63 AS INTEGER ) + col2 * - col2 FROM tab0 AS cor0
----
-1026
-6661
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7003
SELECT + + CAST( NULL AS SIGNED ) + + cor0.col0 * + col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7003
SELECT + + CAST ( NULL AS INTEGER ) + + cor0.col0 * + col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7004
SELECT ALL + - ( cor0.col2 ) DIV ( cor0.col1 ) + + col2 + - col1 * - col1 FROM tab0 AS cor0
----
7429
8363
9410

skipif mysql # not compatible
query I rowsort label-7004
SELECT ALL + - ( cor0.col2 ) / ( cor0.col1 ) + + col2 + - col1 * - col1 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-7005
SELECT 42 DIV - cor1.col1 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 09ade60620ac13e5173651c37e5839a5

skipif mysql # not compatible
query I rowsort label-7005
SELECT 42 / - cor1.col1 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 09ade60620ac13e5173651c37e5839a5

query I rowsort
SELECT DISTINCT - + col2 + col2 * cor0.col2 * 79 AS col1 FROM tab1 AS cor0
----
230310
256614
727968

query I rowsort
SELECT + + col1 * + cor0.col2 - + col2 AS col0 FROM tab1 AS cor0
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 + + col0 col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col0 * col2 - col1 AS col2 FROM tab0 cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-7010
SELECT + col2 - cor0.col0 DIV - 25 col1 FROM tab0 AS cor0
----
2
33
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7010
SELECT + col2 - cor0.col0 / - 25 col1 FROM tab0 AS cor0
----
2
33
85

query I rowsort
SELECT + col2 * - cor0.col0 + col1 * col2 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT + 24 AS col1 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT col1 * + col1 * + tab0.col0 FROM tab0
----
177504
329315
737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-7014
SELECT ALL col2 * col0 DIV 58 AS col1 FROM tab1
----
132
2
62

skipif mysql # not compatible
query I rowsort label-7014
SELECT ALL col2 * col0 / 58 AS col1 FROM tab1
----
132
2
62

query I rowsort
SELECT + cor0.col0 - + 89 FROM tab2, tab0 AS cor0
----
9 values hashing to a1aeaaf5a356f6444f386d1d6d140202

query I rowsort
SELECT ALL 89 AS col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT col1 + 47 * + col1 FROM tab0 AS cor0
----
4128
4368
4656

query I rowsort
SELECT - - col0 * - col0 - - col2 FROM tab2 cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL 41 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT + col0 * - ( col2 ) + - col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT DISTINCT + 43 FROM tab2
----
43

query I rowsort
SELECT DISTINCT - col2 * - col1 + + 15 AS col0 FROM tab2 AS cor0
----
1549
661
852

query I rowsort
SELECT + 21 AS col0 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

query I rowsort
SELECT DISTINCT - + ( + col1 ) + - col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT + + 0 * - col0 + col2 * col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 24 col2 FROM tab2 AS cor0
----
-24
-24
-24

onlyif mysql # use DIV operator for integer division
query I rowsort label-7027
SELECT DISTINCT 44 DIV 50 FROM tab1, tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7027
SELECT DISTINCT 44 / 50 FROM tab1, tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7028
SELECT - col2 * 97 + col1 * - tab1.col0 - - col0 DIV + col2 col0 FROM tab1
----
-10352
-5316
-6168

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7028
SELECT - col2 * 97 + col1 * - tab1.col0 - - col0 / + col2 col0 FROM tab1
----
-10352
-5316
-6168

query I rowsort
SELECT + col1 - ( - col1 * - col2 ) AS col2 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + + col2 * + col1 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7031
SELECT DISTINCT + CAST( col2 AS SIGNED ) * tab0.col2 AS col1 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-7031
SELECT DISTINCT + CAST ( col2 AS INTEGER ) * tab0.col2 AS col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT + - col0 * + col2 * - ( + col2 * col2 ) AS col0 FROM tab2 AS cor0
----
1370928
137781
4334888

query I rowsort
SELECT + ( - 77 ) FROM tab0
----
-77
-77
-77

query I rowsort
SELECT ALL - 72 FROM tab2
----
-72
-72
-72

query I rowsort
SELECT ALL tab0.col1 - - col1 FROM tab0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7036
SELECT ALL - CAST( NULL AS SIGNED ) / + cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7036
SELECT ALL - CAST ( NULL AS INTEGER ) / + cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + - 12 AS col0 FROM tab2 AS cor0
----
-12
-12
-12

query I rowsort
SELECT - col1 * - cor0.col0 + - cor0.col0 * col0 - - col0 AS col0 FROM tab0 AS cor0
----
1512
2205
267

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 32 col0 FROM tab0 AS cor0
----
-32
-32
-32

query I rowsort
SELECT + cor0.col1 + + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL + 25 * cor0.col0 + + col1 FROM tab1 AS cor0
----
101
1610
2013

query I rowsort
SELECT DISTINCT + + ( cor0.col0 ) + col0 AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT + col0 + + col2 * col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - ( + 50 ) AS col1 FROM tab0 AS cor0
----
-50
-50
-50

query I rowsort
SELECT DISTINCT - ( - 56 ) + - col1 + + cor0.col0 * 95 FROM tab1 AS cor0
----
315
6126
7643

query I rowsort
SELECT ( - 36 ) * col0 FROM tab0 AS cor0
----
-1260
-3204
-864

query I rowsort
SELECT ALL - + 14 AS col2 FROM tab1 AS cor0
----
-14
-14
-14

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7048
SELECT ALL - CAST( tab0.col0 AS SIGNED ) FROM tab0, tab1 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

skipif mysql # not compatible
query I rowsort label-7048
SELECT ALL - CAST ( tab0.col0 AS INTEGER ) FROM tab0, tab1 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

query I rowsort
SELECT + col1 + ( tab0.col2 ) * + col0 FROM tab0
----
132
7389
878

query I rowsort
SELECT DISTINCT + cor0.col1 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 2 col1 FROM tab1
----
2
2
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7052
SELECT ALL CAST( col1 AS SIGNED ) DIV + col2 col2 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7052
SELECT ALL CAST ( col1 AS INTEGER ) / + col2 col2 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7053
SELECT ALL CAST( NULL AS SIGNED ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7053
SELECT ALL CAST ( NULL AS INTEGER ) col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 45 * 44 FROM tab2 AS cor0
----
-1980
-1980
-1980

query I rowsort
SELECT DISTINCT 73 * col0 + cor0.col1 AS col1 FROM tab1 AS cor0
----
245
4682
5853

query I rowsort
SELECT + 77 AS col1 FROM tab1 AS cor0
----
77
77
77

query I rowsort
SELECT + ( - tab2.col2 ) + col0 * + col0 AS col0 FROM tab2
----
22
6058
6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-7058
SELECT col0 * col1 DIV 60 - + 5 * col1 * + CAST( col1 AS SIGNED ) FROM tab0
----
-36946
-41271
-46989

skipif mysql # not compatible
query I rowsort label-7058
SELECT col0 * col1 / 60 - + 5 * col1 * + CAST ( col1 AS INTEGER ) FROM tab0
----
-36946
-41271
-46989

query I rowsort
SELECT tab0.col2 * col1 + - col2 - - 30 * col0 FROM tab0
----
10050
1146
3525

onlyif mysql # use DIV operator for integer division
query I rowsort label-7060
SELECT ALL - col1 + col0 DIV - col0 + col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7060
SELECT ALL - col1 + col0 / - col0 + col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + col1 - col0 AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL col0 * 24 AS col0 FROM tab0 AS cor0
----
2136
576
840

query I rowsort
SELECT ALL - - col0 * ( 90 ) + - cor0.col0 * - 52 AS col2 FROM tab0 cor0
----
12638
3408
4970

query I rowsort
SELECT DISTINCT 11 * - col2 AS col2 FROM tab1
----
-1056
-594
-627

query I rowsort
SELECT DISTINCT 39 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
39

query I rowsort
SELECT DISTINCT col1 + + col0 * ( - 4 ) AS col2 FROM tab1
----
-246
-307
14

query I rowsort
SELECT 67 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT DISTINCT 52 + col2 AS col2 FROM tab2
----
78
79
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7069
SELECT DISTINCT - col2 + col1 * ( col2 ) DIV - col0 AS col0 FROM tab0
----
-151
-165
-3

skipif mysql # not compatible
query I rowsort label-7069
SELECT DISTINCT - col2 + col1 * ( col2 ) / - col0 AS col0 FROM tab0
----
-151
-165
-3

query I rowsort
SELECT 38 + + col1 * + col0 FROM tab0
----
2102
3433
8137

query I rowsort
SELECT DISTINCT + cor0.col2 * col0 + col0 AS col2 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT ALL col0 * + ( - col0 ) - - col0 AS col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT ALL col0 + + col2 * + col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-7074
SELECT ALL - cor0.col2 DIV cor0.col1 - col1 * + cor0.col2 col1 FROM tab1 cor0
----
-1255
-1406
-575

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7074
SELECT ALL - cor0.col2 / cor0.col1 - col1 * + cor0.col2 col1 FROM tab1 cor0
----
-1255
-1406
-575

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - ( - col1 ) + cor0.col2 col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-7076
SELECT ALL + - col2 DIV + ( - cor0.col1 ) + col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7076
SELECT ALL + - col2 / + ( - cor0.col1 ) + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - - col1 * + 37 AS col1 FROM tab2 AS cor0
----
1147
2183
629

query I rowsort
SELECT ALL - + col2 + + col1 * col2 AS col1 FROM tab1 AS cor0
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 50 col0 FROM tab0 cor0
----
-1200
-1750
-4450

query I rowsort
SELECT DISTINCT - col1 * + col1 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT col1 + - 18 AS col2 FROM tab1 AS cor0
----
-5
-8
8

skipif mysql # not compatible
query I rowsort
SELECT ALL col2 * CAST ( 56 AS REAL ) * col1 AS col0 FROM tab0
----
158928
417872
5432

query I rowsort
SELECT DISTINCT 94 AS col2 FROM tab0, tab1 cor0
----
94

query I rowsort
SELECT DISTINCT 82 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
82

query I rowsort
SELECT ALL - col2 + ( - 23 ) FROM tab2
----
-49
-50
-61

query I rowsort
SELECT DISTINCT col2 - ( col2 ) AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7087
SELECT DISTINCT + + cor0.col2 DIV 94 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7087
SELECT DISTINCT + + cor0.col2 / 94 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - cor0.col2 * col2 + col0 + - col1 * ( + 63 ) * col0 FROM tab2 AS cor0
----
-14393
-290524
-85974

query I rowsort
SELECT ALL - col2 + ( + 92 + col1 ) * 14 AS col2 FROM tab2 AS cor0
----
1488
1695
2088

query I rowsort
SELECT + col1 + 71 FROM tab2 AS cor0
----
102
130
88

query I rowsort
SELECT ALL - 32 * - col0 FROM tab0 AS cor0
----
1120
2848
768

query I rowsort
SELECT + + 82 + col2 FROM tab2 cor0
----
108
109
120

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 5 * 10 + - cor0.col1 + col0 AS col0 FROM tab0 AS cor0
----
-12
-12
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7095
SELECT CAST( NULL AS DECIMAL ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7095
SELECT CAST ( NULL AS REAL ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7096
SELECT ALL + col1 / - col1 + - cor0.col0 * + CAST( NULL AS SIGNED ) * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7096
SELECT ALL + col1 / - col1 + - cor0.col0 * + CAST ( NULL AS INTEGER ) * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * - 53 + + col2 * col1 AS col0 FROM tab2 AS cor0
----
2268
2660
2912

query I rowsort
SELECT ALL - 99 + + 65 - col2 AS col1 FROM tab2 AS cor0
----
-60
-61
-72

query I rowsort
SELECT cor0.col1 + - 44 FROM tab0 AS cor0
----
42
47
53

query I rowsort
SELECT ALL 55 * 27 FROM tab2, tab2 AS cor0
----
9 values hashing to 4f72fd281e9bdafe8a1860895e356037

query I rowsort
SELECT ALL + col1 * - col2 + - col1 AS col1 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT + 7 * - col2 FROM tab0 AS cor0
----
-231
-574
-7

query I rowsort
SELECT - - ( + 92 ) + col1 * - ( - col2 * - col2 + col2 ) FROM tab2 cor0
----
-23344
-25102
-41326

query I rowsort
SELECT + + col2 + 84 AS col2 FROM tab1 AS cor0
----
138
141
180

query I rowsort
SELECT DISTINCT - 89 + col1 FROM tab2 AS cor0
----
-30
-58
-72

query I rowsort
SELECT DISTINCT - - col0 + cor0.col1 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + - col0 - cor0.col2 * - 43 AS col0 FROM tab0 AS cor0
----
1395
3437
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7108
SELECT ALL - + ( + cor0.col0 ) DIV col0 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7108
SELECT ALL - + ( + cor0.col0 ) / col0 FROM tab0 cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7109
SELECT - ( col0 ) * + ( 75 ) + col2 - - ( 46 ) DIV + col1 FROM tab2 AS cor0
----
-497
-5824
-5885

skipif mysql # not compatible
query I rowsort label-7109
SELECT - ( col0 ) * + ( 75 ) + col2 - - ( 46 ) / + col1 FROM tab2 AS cor0
----
-497
-5824
-5885

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - cor0.col2 ) * col0 + col1 col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + col1 * cor0.col0 + + col1 AS col2 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL col1 + col0 * 28 FROM tab0 cor0
----
1077
2583
758

query I rowsort
SELECT - col2 + col1 * + col0 + 38 AS col0 FROM tab2
----
1343
228
4614

query I rowsort
SELECT + tab1.col0 * col0 * - ( - 28 + tab1.col2 ) AS col0 FROM tab1
----
-118784
-234
-435200

query I rowsort
SELECT DISTINCT + col1 + tab1.col1 AS col0 FROM tab1
----
20
26
52

query I rowsort
SELECT + ( cor0.col0 ) - 85 FROM tab0 AS cor0
----
-50
-61
4

query I rowsort
SELECT + + ( + col0 ) * + cor0.col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - cor0.col2 + col1 * + col1 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT DISTINCT - + col0 + + col2 * col1 AS col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL + col2 * col0 + + ( col1 ) * col0 FROM tab1
----
240
4288
8720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + cor0.col1 * + col1 col2 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT - col2 * col2 + 36 FROM tab2 AS cor0
----
-1408
-640
-693

query I rowsort
SELECT + ( - col1 ) * ( + 50 ) + col1 * 9 FROM tab0 AS cor0
----
-3526
-3731
-3977

query I rowsort
SELECT + - cor0.col0 + + col2 * - col0 AS col2 FROM tab1 cor0
----
-165
-3712
-7760

query I rowsort
SELECT - 8 + col0 * - ( - ( + col0 ) ) FROM tab0 AS cor0
----
1217
568
7913

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col2 * - col2 AS REAL ) AS col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL 6 FROM tab2, tab1, tab2 AS cor0, tab0 AS cor1
----
81 values hashing to 44f233d1b3804e00d9436c0a41d1e2c8

query I rowsort
SELECT ALL ( - 83 ) AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT ALL ( + col0 * + col0 ) FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL + 68 AS col0 FROM tab2, tab1, tab1 cor0
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT - - 34 FROM tab1 AS cor0
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7132
SELECT - + col1 DIV - col1 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7132
SELECT - + col1 / - col1 AS col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + 62 * 38 FROM tab2, tab0 AS cor0
----
9 values hashing to 3b7a5eeede77b91e0eb292ede9357fda

query I rowsort
SELECT ALL 36 + - 5 FROM tab0, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7135
SELECT DISTINCT col2 * + CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-7135
SELECT DISTINCT col2 * + CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7136
SELECT ALL - col0 * + CAST( NULL AS DECIMAL ) + 47 + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7136
SELECT ALL - col0 * + CAST ( NULL AS REAL ) + 47 + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col2 * + col0 + + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + cor0.col1 - col1 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT + col1 + ( col0 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + col1 + col1 * cor0.col2 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + + col2 * - col2 + - col0 AS col1 FROM tab1 AS cor0
----
-2919
-3313
-9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-7142
SELECT 66 * ( col2 ) DIV - 89 FROM tab0
----
-24
-60
0

skipif mysql # not compatible
query I rowsort label-7142
SELECT 66 * ( col2 ) / - 89 FROM tab0
----
-24
-60
0

query I rowsort
SELECT ( 12 ) * - col0 + - col0 FROM tab0 AS cor0
----
-1157
-312
-455

query I rowsort
SELECT + ( - 80 ) * col0 + col1 - + ( col2 ) FROM tab1 AS cor0
----
-268
-5167
-6483

query I rowsort
SELECT + col2 + + col0 - + col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT 2 + 58 * - col0 AS col2 FROM tab0 AS cor0
----
-1390
-2028
-5160

query I rowsort
SELECT - 45 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 71160abf09589695379a70558726f0ba

query I rowsort
SELECT - col0 + + 66 * col1 AS col2 FROM tab0
----
5652
5917
6367

query I rowsort
SELECT + col2 + col0 * + col0 * - col0 FROM tab1 AS cor0
----
-262087
-511904
27

query I rowsort
SELECT 80 AS col0 FROM tab2 cor0
----
80
80
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 14 col2 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT ALL + - col1 * - cor0.col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col2 + col0 * 10 AS col0 FROM tab1 AS cor0
----
697
84
896

onlyif mysql # use DIV operator for integer division
query I rowsort label-7154
SELECT cor0.col1 DIV col1 - 23 AS col0 FROM tab0 AS cor0
----
-22
-22
-22

skipif mysql # not compatible
query I rowsort label-7154
SELECT cor0.col1 / col1 - 23 AS col0 FROM tab0 AS cor0
----
-22
-22
-22

query I rowsort
SELECT DISTINCT + - col0 + - col0 * col1 AS col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT - 25 + - col2 FROM tab1 AS cor0
----
-121
-79
-82

query I rowsort
SELECT + 92 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT + ( + ( col0 ) ) * + col0 FROM tab2
----
49
6084
6241

query I rowsort
SELECT DISTINCT - col1 * - col1 AS col2 FROM tab2 cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col0 col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7161
SELECT ALL col2 DIV ( 49 * col0 ) AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7161
SELECT ALL col2 / ( 49 * col0 ) AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col2 * - 69 FROM tab1 AS cor0
----
3726
3933
6624

query I rowsort
SELECT ALL + cor0.col1 + cor0.col2 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7164
SELECT DISTINCT - col0 * CAST( col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-7164
SELECT DISTINCT - col0 * CAST ( col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - cor0.col1 + - col0 * + col0 AS col0 FROM tab2 AS cor0
----
-6143
-6258
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7166
SELECT DISTINCT col2 DIV + 93 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-7166
SELECT DISTINCT col2 / + 93 FROM tab1
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7167
SELECT 65 DIV col0 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-7167
SELECT 65 / col0 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT DISTINCT + cor0.col0 + - 17 FROM tab2, tab0, tab1 AS cor0
----
-14
47
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7169
SELECT DISTINCT col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7169
SELECT DISTINCT col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT + col0 * - ( col2 ) FROM tab1
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7171
SELECT DISTINCT CAST( NULL AS SIGNED ) * ( - col1 ) * ( + col0 ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7171
SELECT DISTINCT CAST ( NULL AS INTEGER ) * ( - col1 ) * ( + col0 ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ( ( - col0 ) ) * col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT - 83 * col2 AS col0 FROM tab2 AS cor0
----
-2158
-2241
-3154

onlyif mysql # use DIV operator for integer division
query I rowsort label-7174
SELECT + 22 DIV col0 col1 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7174
SELECT + 22 / col0 col1 FROM tab2 AS cor0
----
0
0
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7175
SELECT ALL CAST( cor0.col0 AS SIGNED ) * - col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-7175
SELECT ALL CAST ( cor0.col0 AS INTEGER ) * - col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT - + cor0.col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7177
SELECT CAST( - col2 AS SIGNED ) * + col0 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-7177
SELECT CAST ( - col2 AS INTEGER ) * + col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col2 * + col1 * + col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT ALL - 44 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

query I rowsort
SELECT ALL + col2 + - col1 * + col0 + + col1 AS col1 FROM tab1 AS cor0
----
-573
-931
2

query I rowsort
SELECT DISTINCT col2 * + tab1.col2 + col2 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT col0 AS col0 FROM tab1 WHERE NOT ( - col1 ) IN ( - col2 / col2 + + tab1.col0 * + col1 )
----
3
64
80

query I rowsort
SELECT - col0 + col1 * + col2 FROM tab2 cor0
----
1456
567
830

query III rowsort
SELECT ALL * FROM tab0 cor0 WHERE - col2 IN ( cor0.col0 * + col1 )
----

query I rowsort
SELECT DISTINCT cor0.col1 * + col2 * col1 AS col0 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT col0 * cor0.col1 + - cor0.col1 - col1 AS col2 FROM tab2 AS cor0
----
1309
155
4484

onlyif mysql # use DIV operator for integer division
query I rowsort label-7187
SELECT - tab0.col1 DIV + col1 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7187
SELECT - tab0.col1 / + col1 AS col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col1 * col1 * col0 AS col1 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT ALL col1 AS col0 FROM tab1 WHERE NULL NOT IN ( col2 )
----

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE NOT col0 * - col0 NOT BETWEEN NULL AND + col0
----

query I rowsort
SELECT - col0 * col2 FROM tab2 WHERE NULL <> NULL
----

query I rowsort
SELECT tab0.col0 + col0 - - tab0.col2 FROM tab0
----
260
71
81

query I rowsort
SELECT ALL - col2 + + col0 * - col1 AS col1 FROM tab0
----
-2097
-3396
-8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 col0 FROM tab1 WHERE NULL > ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 col0 FROM tab1 WHERE NOT col1 * - col0 NOT IN ( + col2 * - tab1.col1 )
----

query I rowsort
SELECT ALL + + col2 - col1 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT col0 * col2 + col1 * + cor0.col1 FROM tab0 AS cor0
----
15579
8188
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col0 col1 FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7199
SELECT DISTINCT + col0 DIV cor0.col2 + - cor0.col2 * col2 * + col1 AS col2 FROM tab0 AS cor0
----
-611883
-62
-93654

skipif mysql # not compatible
query I rowsort label-7199
SELECT DISTINCT + col0 / cor0.col2 + - cor0.col2 * col2 * + col1 AS col2 FROM tab0 AS cor0
----
-611883
-62
-93654

query I rowsort
SELECT DISTINCT - col0 * col2 + cor0.col2 * - cor0.col1 * - col0 AS col2 FROM tab0 AS cor0
----
3360
656820
67320

query I rowsort
SELECT DISTINCT + col0 + col0 * - cor0.col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT - col0 * + cor0.col2 * col2 + col1 FROM tab0 AS cor0
----
-26050
-598345
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * col1 + - col0 * - col1 col2 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT ALL - + col1 + + col1 * + cor0.col0 + col0 FROM tab0 AS cor0
----
2002
3333
8097

onlyif mysql # use DIV operator for integer division
query I rowsort label-7205
SELECT - cor0.col0 DIV - tab2.col0 FROM tab2, tab0 cor0
----
9 values hashing to 090b58f5eefe596ddebb2836deb709fb

skipif mysql # not compatible
query I rowsort label-7205
SELECT - cor0.col0 / - tab2.col0 FROM tab2, tab0 cor0
----
9 values hashing to 090b58f5eefe596ddebb2836deb709fb

query I rowsort
SELECT ALL + col1 * col2 - col0 AS col0 FROM tab0
----
2814
62
7373

query I rowsort
SELECT col1 * + col1 + - col1 - col2 AS col2 FROM tab0
----
7277
8108
9311

query I rowsort
SELECT col1 * + tab0.col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL - tab1.col1 + - col0 AS col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT ALL col1 * - col2 + - col2 * col1 FROM tab0 AS cor0
----
-14924
-194
-5676

query I rowsort
SELECT cor0.col1 * cor0.col0 - + cor0.col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT + + cor0.col1 + col1 * col1 * col0 FROM tab0 cor0
----
177590
329412
737100

onlyif mysql # use DIV operator for integer division
query I rowsort label-7213
SELECT DISTINCT col0 DIV + col0 + + col1 + col0 FROM tab1 AS cor0
----
30
75
94

skipif mysql # not compatible
query I rowsort label-7213
SELECT DISTINCT col0 / + col0 + + col1 + col0 FROM tab1 AS cor0
----
30
75
94

query I rowsort
SELECT DISTINCT - col0 * + col2 + - col0 AS col0 FROM tab2
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT 77 + - col1 * ( col1 + col2 ) AS col2 FROM tab1
----
-1340
-2003
-593

query I rowsort
SELECT ( + col0 + + col0 ) AS col0 FROM tab0
----
178
48
70

query I rowsort
SELECT + col0 * col0 + + col2 * 87 + col0 FROM tab0
----
1347
15144
3471

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 93 + + tab0.col2 * tab0.col0 col2 FROM tab0
----
128
7391
885

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7219
SELECT + + col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7219
SELECT + + col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * col0 + + 32 FROM tab0
----
-2032
-3363
-8067

query I rowsort
SELECT DISTINCT 27 * col2 + - col2 * - col1 + col2 FROM tab2
----
1593
1710
2262

onlyif mysql # use DIV operator for integer division
query I rowsort label-7222
SELECT ALL col2 + - col1 DIV 71 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-7222
SELECT ALL col2 + - col1 / 71 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT - ( + col0 ) + ( 27 ) FROM tab1
----
-37
-53
24

query I rowsort
SELECT DISTINCT 25 + col1 FROM tab1
----
35
38
51

query I rowsort
SELECT ALL + + col2 - - 71 * col0 FROM tab2 AS cor0
----
524
5564
5647

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab1, tab2 cor0, tab2, tab0 cor1
----
86
91
97

query I rowsort
SELECT - col1 + 83 FROM tab2 AS cor0
----
24
52
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - 41 col1 FROM tab0 AS cor0
----
-40
-8
41

query I rowsort
SELECT - col1 - + col1 * - col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT + col1 + - col1 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL - cor0.col2 * col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT col1 + + ( col0 ) AS col2 FROM tab1 AS cor0
----
29
74
93

query III rowsort
SELECT * FROM tab0 WHERE NOT + col2 * col0 * + col1 IN ( - col0 / - col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT * FROM tab2 WHERE NULL < - col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7235
SELECT tab0.col1 - - tab0.col1 DIV col0 FROM tab0
----
89
92
99

skipif mysql # not compatible
query I rowsort label-7235
SELECT tab0.col1 - - tab0.col1 / col0 FROM tab0
----
89
92
99

query I rowsort
SELECT col2 + col1 * + col1 AS col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT - col2 + - col2 + col1 * col1 AS col1 FROM tab1
----
-14
-23
568

query I rowsort
SELECT DISTINCT - tab1.col2 AS col2 FROM tab1 WHERE NOT + col2 * col0 IN ( col0 )
----
-54
-57
-96

query I rowsort
SELECT tab0.col1 + col1 * tab0.col0 FROM tab0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 + col0 * col0 col0 FROM tab1
----
4153
63
6496

query I rowsort
SELECT col1 + col2 * - col0 AS col2 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT ALL + col0 FROM tab2 WHERE ( NULL ) > NULL
----

query I rowsort
SELECT DISTINCT 87 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
87

query I rowsort
SELECT DISTINCT - col0 * col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7245
SELECT + - col0 * - col2 * + CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
-233472
-486
-614400

skipif mysql # not compatible
query I rowsort label-7245
SELECT + - col0 * - col2 * + CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT ALL - - 11 * col1 AS col0 FROM tab0 AS cor0
----
1001
1067
946

query I rowsort
SELECT + cor0.col1 * col0 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - + 78 * + col2 AS col2 FROM tab1 AS cor0
----
-4212
-4446
-7488

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( + col0 ) BETWEEN NULL AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7250
SELECT + col1 DIV - tab1.col1 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7250
SELECT + col1 / - tab1.col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col2 + - col1 * + col0 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT col0 FROM tab1 WHERE NULL IN ( col0 * + col1 )
----

query I rowsort
SELECT col0 - - ( col0 ) AS col1 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + col2 * 82 * col0 + - col0 FROM tab0 AS cor0
----
2835
598347
64920

query I rowsort
SELECT + - col1 + col0 + - 8 FROM tab1 AS cor0
----
-31
46
59

query I rowsort
SELECT + col0 + - ( col0 ) AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7257
SELECT col2 * col1 + col0 DIV cor0.col1 FROM tab2 AS cor0
----
1535
650
837

skipif mysql # not compatible
query I rowsort label-7257
SELECT col2 * col1 + col0 / cor0.col1 FROM tab2 AS cor0
----
1535
650
837

query I rowsort
SELECT + cor0.col0 * cor0.col2 - - col1 AS col2 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT tab1.col1 * col1 + + ( 29 ) * - col2 AS col1 FROM tab1
----
-1553
-2615
-890

query I rowsort
SELECT 37 + col0 FROM tab0
----
126
61
72

query I rowsort
SELECT + col2 * col2 - ( - col0 ) * col0 * cor0.col0 AS col2 FROM tab0 AS cor0
----
14913
42876
711693

query I rowsort
SELECT - col1 - - col1 * - cor0.col0 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT + col1 * ( col0 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - col2 * col2 * col2 AS col0 FROM tab1
----
-157464
-185193
-884736

query I rowsort
SELECT ( col2 * - col1 ) FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 41 col0 FROM tab1 AS cor0
----
-41
-41
-41

query I rowsort
SELECT ALL - 64 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

query I rowsort
SELECT DISTINCT 16 AS col2 FROM tab2, tab0, tab2 AS cor0
----
16

query I rowsort
SELECT ALL 12 AS col2 FROM tab0
----
12
12
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7270
SELECT ( + col2 * + CAST( NULL AS SIGNED ) + col0 ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7270
SELECT ( + col2 * + CAST ( NULL AS INTEGER ) + col0 ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * - tab2.col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL + + col0 * col0 + col1 * - col1 * + col0 + col1 AS col1 FROM tab0 AS cor0
----
-176842
-327993
-728997

query I rowsort
SELECT DISTINCT col0 * col2 + + col2 * col2 AS col2 FROM tab0 AS cor0
----
14022
1881
36

query I rowsort
SELECT ALL col2 * col0 * col1 + - col2 FROM tab2 AS cor0
----
119626
50996
5832

query I rowsort
SELECT DISTINCT col0 * + col1 + - col2 * col1 FROM tab2 AS cor0
----
-620
3068
697

query I rowsort
SELECT DISTINCT - cor0.col0 * col0 AS col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT ( - 29 ) + col1 + + col2 AS col1 FROM tab2
----
26
29
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 55 + - col1 col2 FROM tab1
----
109
122
32

query I rowsort
SELECT col2 + 0 + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT col1 + - 89 FROM tab0
----
-3
2
8

query I rowsort
SELECT - col2 + + col2 + col0 * + col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + cor0.col1 + cor0.col1 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to bd4e64b4654b9e3f8122f4e1bada2bd0

query I rowsort
SELECT + col0 + + col1 * - col2 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT 69 + col2 + - col0 * col0 * - col1 FROM tab0 AS cor0
----
118895
49638
720962

query I rowsort
SELECT ALL + 25 * + col2 FROM tab2 AS cor0
----
650
675
950

query I rowsort
SELECT - 43 + cor0.col1 AS col0 FROM tab1 AS cor0
----
-17
-30
-33

query I rowsort
SELECT + 10 AS col0 FROM tab2 cor0
----
10
10
10

query I rowsort
SELECT + - 10 AS col0 FROM tab1 AS cor0
----
-10
-10
-10

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7289
SELECT - CAST( NULL AS SIGNED ) col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7289
SELECT - CAST ( NULL AS INTEGER ) col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 3 AS col1 FROM tab1
----
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7291
SELECT ALL CAST( - 92 AS SIGNED ) DIV col0 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-7291
SELECT ALL CAST ( - 92 AS INTEGER ) / col0 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT - cor1.col1 AS col0 FROM tab0, tab1 cor0 CROSS JOIN tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT 44 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT ALL col0 * - cor0.col1 AS col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + + 55 + - 54 - - col2 AS col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL + - col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + - col0 + - 46 * col2 FROM tab1 AS cor0
----
-2487
-2686
-4496

query I rowsort
SELECT + - 68 AS col1 FROM tab0 AS cor0
----
-68
-68
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7299
SELECT ALL - CAST( NULL AS SIGNED ) * + col0 - - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7299
SELECT ALL - CAST ( NULL AS INTEGER ) * + col0 - - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * - 97 AS col0 FROM tab1 AS cor0
----
-5238
-5529
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7301
SELECT ALL CAST( NULL AS SIGNED ) / ( + cor0.col1 ) + + ( + 64 ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7301
SELECT ALL CAST ( NULL AS INTEGER ) / ( + cor0.col1 ) + + ( + 64 ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + 5 * cor0.col1 FROM tab0 AS cor0
----
454
520
544

query I rowsort
SELECT DISTINCT - ( col2 ) * col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - 93 AS col2 FROM tab0 AS cor0
----
-93

query I rowsort
SELECT col2 * + col1 + - 63 * - ( + col2 ) FROM tab0 AS cor0
----
12628
160
4917

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col2 - + col1 * - col2 col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL + col0 - col1 * + col0 AS col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL - col1 * cor0.col2 - - col0 * - cor0.col2 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT + col2 + col2 + ( + 39 * - col2 ) FROM tab0
----
-1221
-3034
-37

query I rowsort
SELECT ALL tab1.col2 - + tab1.col0 * tab1.col0 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 83ec99b21d9907898184f1851d811e96

query I rowsort
SELECT - + col0 + col0 * + col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL col1 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + - cor0.col2 - col2 FROM tab1 AS cor0
----
-108
-114
-192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * cor0.col0 col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL 1 + cor0.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 1a56768f5118c30343c955aaa945a07b

query I rowsort
SELECT DISTINCT + 35 * + col1 AS col0 FROM tab1 AS cor0
----
350
455
910

query I rowsort
SELECT + col2 * + col2 + 22 AS col1 FROM tab0 AS cor0
----
1111
23
6746

query I rowsort
SELECT DISTINCT + 88 AS col0 FROM tab2, tab2 cor0
----
88

query I rowsort
SELECT - + col0 * - cor0.col2 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - tab0.col0 * - col0 AS col2 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - col2 + 76 AS col1 FROM tab2
----
38
49
50

query I rowsort
SELECT ALL cor0.col1 * + col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col2 * - col2 * + col1 FROM tab0 cor0
----
-611884
-93654
-97

query I rowsort
SELECT - 87 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to 731855201ad1d4d2d2747a1d26047554

query I rowsort
SELECT ALL + - col1 * 18 AS col2 FROM tab2 AS cor0
----
-1062
-306
-558

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7326
SELECT ALL - + col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7326
SELECT ALL - + col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - 36 FROM tab0 cor0
----
-3096
-3276
-3492

query I rowsort
SELECT - col1 + + 15 AS col2 FROM tab2 AS cor0
----
-16
-2
-44

query I rowsort
SELECT + ( col1 ) - + cor0.col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - ( cor0.col2 ) + col2 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7331
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * 31 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7331
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * 31 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + - 63 AS col2 FROM tab0 cor0
----
-63
-63
-63

query I rowsort
SELECT ALL ( 63 ) FROM tab2 AS cor0
----
63
63
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-7334
SELECT + col2 - - 34 DIV - col0 AS col0 FROM tab0 AS cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-7334
SELECT + col2 - - 34 / - col0 AS col0 FROM tab0 AS cor0
----
1
32
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 7 + - 64 col1 FROM tab1 AS cor0
----
-57
-57
-57

query I rowsort
SELECT DISTINCT ( 67 ) + col2 - + 4 FROM tab2 AS cor0
----
101
89
90

query I rowsort
SELECT + 14 + - col0 FROM tab2 AS cor0
----
-64
-65
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 43 * col2 - col0 col1 FROM tab1 AS cor0
----
-2325
-2515
-4208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( 87 ) col2 FROM tab1 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT 37 FROM tab1, tab1 cor0
----
37

query I rowsort
SELECT col1 * 56 - - col1 * - col1 AS col1 FROM tab0
----
-2580
-3185
-3977

query I rowsort
SELECT + col2 * 19 AS col0 FROM tab2 AS cor0
----
494
513
722

query I rowsort
SELECT + + ( + 51 ) AS col0 FROM tab2 AS cor0
----
51
51
51

query I rowsort
SELECT DISTINCT col2 + col0 + + col0 * - col2 FROM tab0
----
-7127
-735
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7345
SELECT col2 * 33 DIV col0 FROM tab0
----
0
30
45

skipif mysql # not compatible
query I rowsort label-7345
SELECT col2 * 33 / col0 FROM tab0
----
0
30
45

query I rowsort
SELECT DISTINCT + ( col0 ) + - col1 * ( + col0 + - col0 ) * - ( ( col1 ) ) AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT + 26 * + col1 FROM tab2
----
1534
442
806

query I rowsort
SELECT + - 18 * col2 AS col0 FROM tab0 AS cor0
----
-1476
-18
-594

onlyif mysql # use DIV operator for integer division
query I rowsort label-7349
SELECT + col1 DIV - 63 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7349
SELECT + col1 / - 63 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - 75 FROM tab2, tab0 AS cor0
----
-75

query I rowsort
SELECT ALL ( 44 + + col2 ) FROM tab0
----
126
45
77

query I rowsort
SELECT + + col0 * - col0 + col1 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-7353
SELECT - col1 DIV - cor0.col1 + col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-7353
SELECT - col1 / - cor0.col1 + col1 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT + col1 * 81 + - col0 FROM tab2 AS cor0
----
1298
2504
4701

query I rowsort
SELECT + col1 * + 92 + 87 * col0 FROM tab1 AS cor0
----
2653
6488
8156

query I rowsort
SELECT col2 + + 46 * cor0.col2 FROM tab2 AS cor0
----
1222
1269
1786

onlyif mysql # use DIV operator for integer division
query I rowsort label-7357
SELECT 60 DIV - cor1.col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6d7477cb006495db33f619576f422dbb

skipif mysql # not compatible
query I rowsort label-7357
SELECT 60 / - cor1.col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6d7477cb006495db33f619576f422dbb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * ( col2 * col0 ) + - col2 * col0 col1 FROM tab2
----
117624
48032
5670

query I rowsort
SELECT ALL + - cor0.col2 + 15 AS col2 FROM tab1 AS cor0
----
-39
-42
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7360
SELECT + cor0.col1 * - CAST( - 87 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
7482
7917
8439

skipif mysql # not compatible
query I rowsort label-7360
SELECT + cor0.col1 * - CAST ( - 87 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
7482
7917
8439

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7361
SELECT DISTINCT cor0.col0 * + CAST( NULL AS SIGNED ) * 33 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7361
SELECT DISTINCT cor0.col0 * + CAST ( NULL AS INTEGER ) * 33 FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7362
SELECT ALL - - col1 + CAST( col1 * + col1 AS SIGNED ) FROM tab0 AS cor0
----
7482
8372
9506

skipif mysql # not compatible
query I rowsort label-7362
SELECT ALL - - col1 + CAST ( col1 * + col1 AS INTEGER ) FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT + col0 + + 57 AS col2 FROM tab1 AS cor0
----
121
137
60

query I rowsort
SELECT DISTINCT + col1 + + 93 + - col0 AS col0 FROM tab1 AS cor0
----
116
26
39

query I rowsort
SELECT ALL + col0 - - 20 AS col1 FROM tab2 cor0
----
27
98
99

query I rowsort
SELECT ALL - 94 AS col2 FROM tab2
----
-94
-94
-94

query I rowsort
SELECT ALL 41 * col0 AS col0 FROM tab0
----
1435
3649
984

query I rowsort
SELECT col1 - + 67 AS col1 FROM tab1 AS cor0
----
-41
-54
-57

query I rowsort
SELECT - - col1 * - col0 - col1 * + col2 FROM tab2 AS cor0
----
-1054
-1989
-6136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 * + 75 * 67 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 18ffd9b34d4a5eae3a0867e5bb345ab8

query I rowsort
SELECT ALL - - 60 + tab1.col1 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 61b38cac83962bbead9ba9cab260b593

query I rowsort
SELECT DISTINCT + col0 + col2 * col0 AS col0 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT col2 * + cor0.col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL col2 + - 61 FROM tab1 AS cor0
----
-4
-7
35

query I rowsort
SELECT - col2 + - col1 + + col1 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT 22 AS col1 FROM tab0, tab1 AS cor0
----
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-7377
SELECT 28 DIV - 83 col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7377
SELECT 28 / - 83 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 4 + ( col2 ) FROM tab2 AS cor0
----
22
23
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7379
SELECT + + 44 DIV 20 + + col1 DIV + 26 AS col0 FROM tab2 AS cor0
----
2
3
4

skipif mysql # not compatible
query I rowsort label-7379
SELECT + + 44 / 20 + + col1 / + 26 AS col0 FROM tab2 AS cor0
----
2
3
4

query I rowsort
SELECT col1 + 0 AS col2 FROM tab0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7381
SELECT col0 * - 46 + + col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7381
SELECT col0 * - 46 + + col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 26 * cor0.col2 + col2 AS col1 FROM tab2 AS cor0
----
1026
702
729

query I rowsort
SELECT + cor0.col1 * cor0.col0 + + col2 * 71 * - ( - col1 ) AS col1 FROM tab0 cor0
----
10282
203562
537901

query I rowsort
SELECT - - 27 * + col0 FROM tab0 AS cor0
----
2403
648
945

query I rowsort
SELECT ALL - 50 FROM tab2
----
-50
-50
-50

query I rowsort
SELECT 64 FROM tab1, tab0 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ALL - col1 * - col2 + + col2 FROM tab2 cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-7388
SELECT DISTINCT + + col1 DIV + col2 AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7388
SELECT DISTINCT + + col1 / + col2 AS col2 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7389
SELECT DISTINCT + col2 + - col2 DIV - col1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7389
SELECT DISTINCT + col2 + - col2 / - col1 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + col0 + cor0.col0 AS col1 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT DISTINCT 86 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
1462
2666
5074

query I rowsort
SELECT ALL - 48 * - col2 FROM tab1 AS cor0
----
2592
2736
4608

onlyif mysql # use DIV operator for integer division
query I rowsort label-7393
SELECT + 40 + + col0 DIV - 67 AS col2 FROM tab2 AS cor0
----
39
39
40

skipif mysql # not compatible
query I rowsort label-7393
SELECT + 40 + + col0 / - 67 AS col2 FROM tab2 AS cor0
----
39
39
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-7394
SELECT DISTINCT - 16 DIV + col2 + - col1 FROM tab0 AS cor0
----
-113
-86
-91

skipif mysql # not compatible
query I rowsort label-7394
SELECT DISTINCT - 16 / + col2 + - col1 FROM tab0 AS cor0
----
-113
-86
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-7395
SELECT - + col2 DIV col0 AS col2 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-7395
SELECT - + col2 / col0 AS col2 FROM tab2 AS cor0
----
-3
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7396
SELECT DISTINCT col1 DIV + 38 AS col2 FROM tab0
----
2

skipif mysql # not compatible
query I rowsort label-7396
SELECT DISTINCT col1 / + 38 AS col2 FROM tab0
----
2

query I rowsort
SELECT ALL + + 7 AS col2 FROM tab0 AS cor0
----
7
7
7

query I rowsort
SELECT DISTINCT + 61 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1586
-610
-793

query I rowsort
SELECT DISTINCT + + ( 86 ) FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7400
SELECT ALL + 71 DIV + 1 + - cor1.col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 47db8a6bdf87b0731ee76bc8b32532d2

skipif mysql # not compatible
query I rowsort label-7400
SELECT ALL + 71 / + 1 + - cor1.col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 47db8a6bdf87b0731ee76bc8b32532d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7401
SELECT ALL tab2.col2 DIV - col0 col1 FROM tab2
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7401
SELECT ALL tab2.col2 / - col0 col1 FROM tab2
----
-3
0
0

query I rowsort
SELECT - ( cor0.col1 ) * 28 FROM tab0 AS cor0
----
-2408
-2548
-2716

query I rowsort
SELECT - col0 * - cor0.col2 + 59 AS col1 FROM tab1 AS cor0
----
221
3707
7739

query I rowsort
SELECT DISTINCT + 69 * col2 + col2 + - ( - col1 ) FROM tab2 cor0
----
1879
1921
2677

onlyif mysql # use DIV operator for integer division
query I rowsort label-7405
SELECT + 25 * + col2 - col1 DIV - col2 AS col0 FROM tab1 AS cor0
----
1350
1425
2400

skipif mysql # not compatible
query I rowsort label-7405
SELECT + 25 * + col2 - col1 / - col2 AS col0 FROM tab1 AS cor0
----
1350
1425
2400

query I rowsort
SELECT ALL - ( + 7 ) FROM tab1 AS cor0
----
-7
-7
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 69 + 63 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 71eda8f1cddbd49f139e3cd450755dd8

query I rowsort
SELECT ALL - cor0.col0 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT tab1.col0 * + 89 AS col1 FROM tab1
----
267
5696
7120

query I rowsort
SELECT + 99 + + ( col2 ) AS col2 FROM tab0
----
100
132
181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7411
SELECT DISTINCT ( col2 ) + col1 / CAST( NULL AS DECIMAL ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7411
SELECT DISTINCT ( col2 ) + col1 / CAST ( NULL AS REAL ) FROM tab0
----
NULL

query I rowsort
SELECT ALL - cor0.col2 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT + ( + 60 ) + tab0.col2 AS col2 FROM tab0
----
142
61
93

query I rowsort
SELECT + 58 - col0 AS col1 FROM tab2
----
-20
-21
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 60 + + 19 col2 FROM tab1
----
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7416
SELECT + CAST( NULL AS SIGNED ) + - 13 * - col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7416
SELECT + CAST ( NULL AS INTEGER ) + - 13 * - col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * - col1 + - tab2.col0 FROM tab2
----
-3559
-368
-968

query I rowsort
SELECT DISTINCT + ( - 66 ) * col0 - + ( cor0.col0 ) * col0 FROM tab2 AS cor0
----
-11232
-11455
-511

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - 13 col2 FROM tab2 cor0
----
-6
65
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7420
SELECT DISTINCT + - CAST( NULL AS SIGNED ) * col1 + col2 + col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7420
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) * col1 + col2 + col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col2 * - col0 + - cor0.col1 * - col2 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT col2 + - col0 * + col2 * ( + col2 ) AS col2 FROM tab1
----
-207879
-737184
-8694

query I rowsort
SELECT DISTINCT + col0 * + col2 + col0 + col2 * ( col2 + col2 ) FROM tab1 cor0
----
10210
26192
5997

query I rowsort
SELECT ALL col2 + + ( - col1 ) AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + col2 + col0 AS col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT 77 - - col2 FROM tab0
----
110
159
78

query I rowsort
SELECT 28 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

query I rowsort
SELECT ALL tab0.col2 + col0 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL - cor0.col2 * ( - cor0.col0 ) AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL col1 + + col0 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + col0 + ( + col0 * + tab1.col0 + - col2 ) FROM tab1
----
-42
4103
6384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 * - ( + col0 ) + tab0.col1 col1 FROM tab0
----
-1128
-490
-7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-7433
SELECT + - col1 DIV col1 - col0 AS col2 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-7433
SELECT + - col1 / col1 - col0 AS col2 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT DISTINCT + col2 + + ( + 57 ) FROM tab1 AS cor0
----
111
114
153

query I rowsort
SELECT + col1 * col0 + 9 AS col1 FROM tab1 cor0
----
1049
649
87

query I rowsort
SELECT - col2 * - col2 - col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT ALL + col0 * - col0 * + col0 + + col1 * ( + 4 ) FROM tab1 AS cor0
----
-262104
-511948
77

query I rowsort
SELECT DISTINCT - + col2 * 90 + + 77 * col2 FROM tab0 AS cor0
----
-1066
-13
-429

query I rowsort
SELECT col2 * - cor0.col0 + - col0 AS col0 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT - + col2 * + col0 + col2 * col1 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT ALL col2 * col2 * col0 AS col0 FROM tab2
----
114076
5103
52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-7442
SELECT - col0 * - 2 + - col0 DIV col1 FROM tab0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-7442
SELECT - col0 * - 2 + - col0 / col1 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL + cor0.col0 + + col0 AS col1 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT + 79 * - col2 + + col0 * 29 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
14097
223231
35446

query I rowsort
SELECT ALL 24 FROM tab2 AS cor0
----
24
24
24

query I rowsort
SELECT ALL ( col1 ) * col2 AS col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - ( ( cor0.col1 ) ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + - col2 + + col1 AS col1 FROM tab0 AS cor0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col0 ) + ( + 87 ) * col2 col2 FROM tab1 AS cor0
----
4695
4895
8272

query I rowsort
SELECT DISTINCT 82 * cor0.col2 AS col2 FROM tab0 AS cor0
----
2706
6724
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7451
SELECT DISTINCT + col2 DIV - col2 + + ( col1 ) AS col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-7451
SELECT DISTINCT + col2 / - col2 + + ( col1 ) AS col0 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT + col1 * col0 * ( - col0 ) FROM tab1 cor0
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-7453
SELECT ALL - - col1 + - col0 DIV + 31 AS col0 FROM tab0 AS cor0
----
86
89
96

skipif mysql # not compatible
query I rowsort label-7453
SELECT ALL - - col1 + - col0 / + 31 AS col0 FROM tab0 AS cor0
----
86
89
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7454
SELECT ALL col2 * col0 + + 45 DIV - 79 - cor0.col1 * - col2 FROM tab0 AS cor0
----
132
14760
3630

skipif mysql # not compatible
query I rowsort label-7454
SELECT ALL col2 * col0 + + 45 / - 79 - cor0.col1 * - col2 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT DISTINCT + 59 FROM tab2, tab0, tab1 AS cor0
----
59

query I rowsort
SELECT DISTINCT + 34 + - col0 FROM tab2 cor0
----
-44
-45
27

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab2, tab0, tab2 AS cor0, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT DISTINCT + 96 * - col2 FROM tab2 cor0
----
-2496
-2592
-3648

onlyif mysql # use DIV operator for integer division
query I rowsort label-7459
SELECT + 84 DIV col0 AS col1 FROM tab2 AS cor0
----
1
1
12

skipif mysql # not compatible
query I rowsort label-7459
SELECT + 84 / col0 AS col1 FROM tab2 AS cor0
----
1
1
12

query I rowsort
SELECT DISTINCT - 47 AS col2 FROM tab1, tab2, tab0 AS cor0
----
-47

query I rowsort
SELECT ALL + cor1.col1 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + ( col1 ) * + 85 FROM tab2
----
1445
2635
5015

query I rowsort
SELECT ALL 94 AS col0 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

onlyif mysql # use DIV operator for integer division
query I rowsort label-7464
SELECT DISTINCT - 99 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-7464
SELECT DISTINCT - 99 / cor0.col1 AS col1 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT DISTINCT + + 29 FROM tab2 cor0
----
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7466
SELECT + - col2 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7466
SELECT + - col2 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col2 * 53 AS col2 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT - col2 * 71 FROM tab0 AS cor0
----
-2343
-5822
-71

query I rowsort
SELECT + col1 * 26 AS col2 FROM tab1 AS cor0
----
260
338
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7470
SELECT DISTINCT - ( - col2 ) * CAST( + col1 AS SIGNED ) AS col0 FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-7470
SELECT DISTINCT - ( - col2 ) * CAST ( + col1 AS INTEGER ) AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT cor0.col2 + col2 * - col2 FROM tab1 cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT 32 FROM tab2, tab1, tab2 AS cor0
----
32

query I rowsort
SELECT ALL - + cor0.col1 * + 18 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-116
-154
-465

query I rowsort
SELECT DISTINCT - - 64 + ( - cor0.col1 ) AS col0 FROM tab1 AS cor0
----
38
51
54

query I rowsort
SELECT ALL col2 * col1 + + col2 * - ( - col2 + col1 ) FROM tab2 cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-7476
SELECT ALL 54 + - col0 DIV col0 FROM tab1 AS cor0
----
53
53
53

skipif mysql # not compatible
query I rowsort label-7476
SELECT ALL 54 + - col0 / col0 FROM tab1 AS cor0
----
53
53
53

query I rowsort
SELECT DISTINCT - ( + 4 ) FROM tab2 AS cor0
----
-4

query I rowsort
SELECT - col1 * - 97 + col2 AS col2 FROM tab2 AS cor0
----
1687
3034
5749

query I rowsort
SELECT ALL + + ( col1 ) + cor0.col2 AS col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + col2 + 60 FROM tab2
----
86
87
98

query I rowsort
SELECT col0 + + 45 + col1 AS col0 FROM tab1
----
119
138
74

query I rowsort
SELECT - col2 + ( col0 ) FROM tab1
----
-16
-51
7

query I rowsort
SELECT + col2 - ( col1 ) FROM tab1
----
28
47
83

query I rowsort
SELECT - 15 + cor0.col0 AS col0 FROM tab2, tab2 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 68bc2bb48f6a758d04f7649f80c0a4c1

query I rowsort
SELECT ALL - col1 + col2 + col2 FROM tab0
----
-20
-95
73

query I rowsort
SELECT ALL - 49 * + 21 AS col2 FROM tab1 AS cor0
----
-1029
-1029
-1029

query I rowsort
SELECT + col2 * col1 + col0 + - ( - ( col2 ) ) FROM tab2 AS cor0
----
1638
763
871

query I rowsort
SELECT ALL 93 AS col2 FROM tab2 AS cor0
----
93
93
93

query I rowsort
SELECT + cor0.col2 + col0 * col1 + - col2 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT col2 * 31 AS col0 FROM tab0
----
1023
2542
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-7491
SELECT DISTINCT CAST( 25 AS SIGNED ) + col1 DIV 8 AS col1 FROM tab2 AS cor0
----
27
28
32

skipif mysql # not compatible
query I rowsort label-7491
SELECT DISTINCT CAST ( 25 AS INTEGER ) + col1 / 8 AS col1 FROM tab2 AS cor0
----
27
28
32

query I rowsort
SELECT DISTINCT col2 + 89 FROM tab2
----
115
116
127

query I rowsort
SELECT + - 90 * + col2 FROM tab1 AS cor0
----
-4860
-5130
-8640

query I rowsort
SELECT 64 + col0 AS col0 FROM tab1
----
128
144
67

query I rowsort
SELECT - ( col0 ) * col0 - + 60 FROM tab1
----
-4156
-6460
-69

query I rowsort
SELECT ALL + col2 + - col0 * + cor0.col0 * - col1 FROM tab1 AS cor0
----
288
41017
83296

query I rowsort
SELECT + + 93 + cor0.col1 * cor0.col1 FROM tab2 AS cor0
----
1054
3574
382

query I rowsort
SELECT - cor0.col2 + + cor0.col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT 12 * + col1 AS col0 FROM tab2 AS cor0
----
204
372
708

query I rowsort
SELECT ALL + 98 * + col1 AS col1 FROM tab2 AS cor0
----
1666
3038
5782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col2 col1 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
-1
-33
-82

query I rowsort
SELECT + col0 * + col0 - + col1 AS col1 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT - - col0 + col2 * + ( + col1 ) FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT - 10 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT + - col0 + ( + col2 * cor0.col2 ) FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT - col0 - col1 * 1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7507
SELECT col2 * - CAST( cor0.col2 AS SIGNED ) + + col0 * + col1 AS col0 FROM tab2 AS cor0
----
-101
-512
3926

skipif mysql # not compatible
query I rowsort label-7507
SELECT col2 * - CAST ( cor0.col2 AS INTEGER ) + + col0 * + col1 AS col0 FROM tab2 AS cor0
----
-101
-512
3926

onlyif mysql # use DIV operator for integer division
query I rowsort label-7508
SELECT + col1 + col0 + col0 DIV + col1 AS col1 FROM tab0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-7508
SELECT + col1 + col0 + col0 / + col1 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT - col1 + col0 * + col1 * cor0.col1 FROM tab0 AS cor0
----
177418
329218
736918

query I rowsort
SELECT DISTINCT + - col2 * + 30 AS col1 FROM tab2 AS cor0
----
-1140
-780
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7511
SELECT + - col0 * CAST( col1 AS SIGNED ) + col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif mysql # not compatible
query I rowsort label-7511
SELECT + - col0 * CAST ( col1 AS INTEGER ) + col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7512
SELECT DISTINCT col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7512
SELECT DISTINCT col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col2 * - ( col1 * - col1 ) FROM tab1 cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT - cor0.col1 + 11 FROM tab2 AS cor0
----
-20
-48
-6

query I rowsort
SELECT - + col0 + col2 * col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT + col2 + 18 FROM tab1 AS cor0
----
114
72
75

query I rowsort
SELECT ALL - col2 * - col2 + + col2 * col1 FROM tab0 AS cor0
----
14186
3927
98

query I rowsort
SELECT cor0.col2 + ( - col0 ) * + col2 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 49 * col2 + cor0.col1 col0 FROM tab2 AS cor0
----
147115
9292
99431

query I rowsort
SELECT ALL + col1 + + 61 FROM tab2 AS cor0
----
120
78
92

query I rowsort
SELECT ALL - + col1 + + 33 * + col1 AS col0 FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT ( 87 ) * - col2 AS col2 FROM tab0 AS cor0
----
-2871
-7134
-87

query I rowsort
SELECT ALL - col0 * col1 + - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( 38 ) + + col2 col2 FROM tab2 AS cor0
----
64
65
76

query I rowsort
SELECT ALL + col1 * 94 + + col1 AS col0 FROM tab0
----
8170
8645
9215

onlyif mysql # use DIV operator for integer division
query I rowsort label-7526
SELECT + 65 DIV + 93 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-7526
SELECT + 65 / + 93 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT ALL col1 * - col0 + + col2 * col2 FROM tab0
----
-1375
-3394
-975

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7528
SELECT DISTINCT CAST( + 57 AS SIGNED ) FROM tab1, tab2 cor0
----
57

skipif mysql # not compatible
query I rowsort label-7528
SELECT DISTINCT CAST ( + 57 AS INTEGER ) FROM tab1, tab2 cor0
----
57

query I rowsort
SELECT ALL tab2.col1 * - 35 * 40 FROM tab2
----
-23800
-43400
-82600

query I rowsort
SELECT ALL - + col0 * + col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col0 * col1 + col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + col1 * + col1 + - ( - ( - col0 ) ) FROM tab1 AS cor0
----
36
673
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7533
SELECT DISTINCT - 51 + - col2 DIV - 60 - - cor0.col0 AS col1 FROM tab2 AS cor0
----
-44
27
28

skipif mysql # not compatible
query I rowsort label-7533
SELECT DISTINCT - 51 + - col2 / - 60 - - cor0.col0 AS col1 FROM tab2 AS cor0
----
-44
27
28

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab2, tab1 AS cor1
----
3645 values hashing to 35707ade138fec4b370f5140a4cd2963

query I rowsort
SELECT ALL - cor1.col2 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL + ( + col2 ) * + col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL col1 - + tab1.col2 AS col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT - col0 * + col0 - col2 FROM tab2
----
-6110
-6279
-76

query I rowsort
SELECT cor0.col1 - + tab0.col0 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to fac199fee49cfb7f8ea6cc57c52dd643

query I rowsort
SELECT DISTINCT - 34 FROM tab2
----
-34

query I rowsort
SELECT 33 AS col0 FROM tab2 AS cor0
----
33
33
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-7542
SELECT 21 DIV col0 FROM tab1 cor0
----
0
0
7

skipif mysql # not compatible
query I rowsort label-7542
SELECT 21 / col0 FROM tab1 cor0
----
0
0
7

query I rowsort
SELECT DISTINCT col1 * col0 - col0 * col0 FROM tab0
----
1488
178
2170

query I rowsort
SELECT DISTINCT col1 * col1 FROM tab2 cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-7545
SELECT DISTINCT col1 DIV + col0 FROM tab1 cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-7545
SELECT DISTINCT col1 / + col0 FROM tab1 cor0
----
0
8

query I rowsort
SELECT - col0 + col0 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-165
-3712
-7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-7547
SELECT - - col0 DIV cor0.col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-7547
SELECT - - col0 / cor0.col2 FROM tab0 AS cor0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * col1 col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col0 * + col2 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT - + col0 + + cor0.col2 * + col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT + - cor0.col2 AS col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT 77 - - col2 FROM tab2
----
103
104
115

query I rowsort
SELECT ALL + - col1 + + col1 AS col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + + cor0.col0 + cor0.col2 + - col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7555
SELECT DISTINCT + - col2 DIV col1 + col1 * col2 FROM tab1 AS cor0
----
1241
1402
565

skipif mysql # not compatible
query I rowsort label-7555
SELECT DISTINCT + - col2 / col1 + col1 * col2 FROM tab1 AS cor0
----
1241
1402
565

onlyif mysql # use DIV operator for integer division
query I rowsort label-7556
SELECT ALL + + col1 DIV - col0 AS col2 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-7556
SELECT ALL + + col1 / - col0 AS col2 FROM tab2 cor0
----
-4
0
0

query I rowsort
SELECT col1 * col0 + + tab1.col1 AS col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL - tab0.col1 + - col2 + col0 FROM tab0
----
-63
-84
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 79 + + col1 col1 FROM tab0
----
165
170
176

onlyif mysql # use DIV operator for integer division
query I rowsort label-7560
SELECT ALL - col2 DIV + col1 AS col1 FROM tab2
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-7560
SELECT ALL - col2 / + col1 AS col1 FROM tab2
----
-2
0
0

query I rowsort
SELECT DISTINCT col2 * - col2 + - tab2.col0 FROM tab2
----
-1523
-736
-754

onlyif mysql # use DIV operator for integer division
query I rowsort label-7562
SELECT ALL + tab2.col0 DIV - tab2.col1 AS col1 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-7562
SELECT ALL + tab2.col0 / - tab2.col1 AS col1 FROM tab2
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 + col0 col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - col0 + - tab1.col0 * - col2 * + col2 AS col0 FROM tab1
----
207872
737200
8745

query I rowsort
SELECT ALL - + col2 + col1 * col2 - cor0.col1 AS col1 FROM tab2 AS cor0
----
1449
591
779

onlyif mysql # use DIV operator for integer division
query I rowsort label-7566
SELECT DISTINCT col1 DIV + col1 AS col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-7566
SELECT DISTINCT col1 / + col1 AS col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT - - col1 * col1 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
327
3507
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-7568
SELECT DISTINCT - + col1 * col1 + - col2 DIV + col2 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-7568
SELECT DISTINCT - + col1 * col1 + - col2 / + col2 col2 FROM tab0 AS cor0
----
-7397
-8282
-9410

query I rowsort
SELECT col0 * - col2 + + col2 * col1 * + col2 AS col1 FROM tab2 cor0
----
21546
22410
37856

query I rowsort
SELECT col2 * - tab2.col2 * + tab2.col0 AS col1 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT - col2 * col1 * + col0 AS col1 FROM tab1 WHERE + col2 IN ( col1 - col2 * + col0 )
----

query I rowsort
SELECT col1 * - col0 + - col0 FROM tab0
----
-2088
-3430
-8188

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( - col0 * + col0 ) NOT IN ( col0 * - col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( NULL ) IN ( col1 )
----

query I rowsort
SELECT col1 * tab2.col0 + - col0 FROM tab2
----
1264
210
4524

query I rowsort
SELECT ALL tab1.col0 * + col1 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT tab0.col2 - col0 * - col0 FROM tab0
----
1226
609
8003

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE - col1 NOT IN ( - tab1.col1 )
----

query I rowsort
SELECT ALL + col0 + - col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + tab2.col1 * - col1 + col0 AS col2 FROM tab2 WHERE NOT ( NULL ) = NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 + col1 col0 FROM tab1
----
2942
3259
9229

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL = - col1 * - col1 - - col2 * col2
----

query I rowsort
SELECT ALL col0 + cor0.col1 * ( - 87 + + col1 * - 35 ) FROM tab2 AS cor0
----
-11515
-126890
-36325

query I rowsort
SELECT DISTINCT - 9 FROM tab1
----
-9

query I rowsort
SELECT ALL + 9 FROM tab1
----
9
9
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + col1 + + 15 col0 FROM tab1 AS cor0
----
-1233
-1389
-555

query I rowsort
SELECT DISTINCT ( + 38 ) FROM tab2, tab2 AS cor0, tab1 AS cor1
----
38

query I rowsort
SELECT col0 * + tab2.col2 * + col0 + col0 * col2 FROM tab2
----
1512
160212
240160

query I rowsort
SELECT + tab1.col0 * - col2 AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT col0 * col2 + + col2 * col1 * col1 AS col0 FROM tab2
----
13984
26136
92534

onlyif mysql # use DIV operator for integer division
query I rowsort label-7591
SELECT DISTINCT col1 * - col1 DIV col1 + - col1 AS col2 FROM tab1
----
-20
-26
-52

skipif mysql # not compatible
query I rowsort label-7591
SELECT DISTINCT col1 * - col1 / col1 + - col1 AS col2 FROM tab1
----
-20
-26
-52

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 col0 * + col1 * col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL - cor0.col1 * col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT col1 + tab1.col0 + - col1 FROM tab1
----
3
64
80

query I rowsort
SELECT + col1 + col2 - col0 * + col0 FROM tab1
----
-4029
-6291
71

query III rowsort
SELECT * FROM tab1 WHERE NOT + col2 IN ( - col2 / - col1 - col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

onlyif mysql # use DIV operator for integer division
query I rowsort label-7598
SELECT ALL + col1 DIV col2 AS col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-7598
SELECT ALL + col1 / col2 AS col2 FROM tab0
----
1
2
97

query I rowsort
SELECT ALL col2 * col0 + - col1 * + col1 - col2 FROM tab1
----
-568
3491
7415

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 col1 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-7601
SELECT col2 DIV + col0 + col1 FROM tab1
----
10
14
44

skipif mysql # not compatible
query I rowsort label-7601
SELECT col2 / + col0 + col1 FROM tab1
----
10
14
44

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( - col1 * col0 + col0 ) IN ( col1 * + col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - col0 * - col1 - col0 FROM tab0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col2 * col1 col2 FROM tab0
----
3395
664118
68112

query III rowsort
SELECT * FROM tab2 WHERE ( - col2 * col0 + - col2 ) <> NULL
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) = ( col0 )
----

query I rowsort
SELECT col2 - col0 * tab0.col1 AS col1 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT - 72 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-216
-4608
-5760

query I rowsort
SELECT - - 3 AS col1 FROM tab0 cor0
----
3
3
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + col2 + 78 col0 FROM tab0 AS cor0
----
114
135
249

onlyif mysql # use DIV operator for integer division
query I rowsort label-7611
SELECT 43 DIV cor0.col1 AS col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 1287f4e28eb4c09a9b002a6445430a76

skipif mysql # not compatible
query I rowsort label-7611
SELECT 43 / cor0.col1 AS col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 1287f4e28eb4c09a9b002a6445430a76

query I rowsort
SELECT DISTINCT + 42 AS col2 FROM tab0 AS cor0
----
42

query I rowsort
SELECT + ( col0 ) * col1 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 13 col0 FROM tab2
----
-13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7615
SELECT DISTINCT col0 * CAST( 32 AS SIGNED ) * - col0 AS col1 FROM tab1 AS cor0
----
-131072
-204800
-288

skipif mysql # not compatible
query I rowsort label-7615
SELECT DISTINCT col0 * CAST ( 32 AS INTEGER ) * - col0 AS col1 FROM tab1 AS cor0
----
-131072
-204800
-288

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col1 + CAST ( + cor0.col0 AS REAL ) * + cor0.col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT col0 * col1 * - col1 + tab0.col1 - + col2 AS col0 FROM tab0
----
-177451
-329219
-737000

onlyif mysql # use DIV operator for integer division
query I rowsort label-7618
SELECT DISTINCT - col0 * col1 + 11 DIV - 84 FROM tab2
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-7618
SELECT DISTINCT - col0 * col1 + 11 / - 84 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-7619
SELECT 49 - - col2 DIV col2 FROM tab1
----
50
50
50

skipif mysql # not compatible
query I rowsort label-7619
SELECT 49 - - col2 / col2 FROM tab1
----
50
50
50

query I rowsort
SELECT - ( - col1 ) + ( - col0 + col2 ) AS col2 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT - col0 - col2 * + 65 AS col2 FROM tab1
----
-3513
-3769
-6320

query I rowsort
SELECT col2 + + col1 + 28 AS col1 FROM tab0
----
126
147
201

query I rowsort
SELECT DISTINCT + tab1.col1 + col0 * ( - col1 ) FROM tab1
----
-1027
-52
-630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7624
SELECT DISTINCT col2 + tab1.col1 * - CAST( NULL AS DECIMAL ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7624
SELECT DISTINCT col2 + tab1.col1 * - CAST ( NULL AS REAL ) FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT 34 * col0 FROM tab0 AS cor0
----
1190
3026
816

query I rowsort
SELECT ALL - - col2 * - col2 + + col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT 95 * + cor0.col0 AS col2 FROM tab0 cor0
----
2280
3325
8455

query I rowsort
SELECT ALL + col1 + + col0 * + col2 FROM tab0 AS cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col0 col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + tab0.col0 AS col1 FROM tab0, tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 + - col2 col0 FROM tab2 cor0
----
-14
-15
-26

query I rowsort
SELECT + col0 * - cor0.col2 + col1 * - col2 + 45 FROM tab0 cor0
----
-14715
-3585
-87

query I rowsort
SELECT + 12 + col0 FROM tab0 AS cor0
----
101
36
47

query I rowsort
SELECT + col2 - - col1 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL - ( ( col2 ) ) * tab1.col0 - col1 * + col1 AS col1 FROM tab1
----
-3748
-7849
-838

query I rowsort
SELECT - col1 + 47 * + tab0.col2 AS col1 FROM tab0
----
-50
1465
3763

query I rowsort
SELECT 84 * 91 FROM tab2 cor0
----
7644
7644
7644

query I rowsort
SELECT ALL + cor0.col2 + 11 * col2 * col0 FROM tab1 AS cor0
----
1836
40185
84576

query I rowsort
SELECT DISTINCT ( 1 ) * cor0.col1 AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL - ( + col0 * tab2.col1 + col1 ) FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT 58 + col0 FROM tab0
----
147
82
93

query I rowsort
SELECT ALL cor0.col2 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT DISTINCT + col2 * 30 * col0 FROM tab1
----
109440
230400
4860

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 69 + col0 * cor0.col0 col1 FROM tab2 AS cor0
----
-20
6015
6172

query I rowsort
SELECT ALL - - col1 * col0 + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL + col2 + col1 * + col2 + col2 * col2 AS col2 FROM tab2 AS cor0
----
1593
2128
2236

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 * col2 col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + + col1 * + col2 * + cor0.col1 + col0 AS col2 FROM tab1 cor0
----
16304
36507
5764

query I rowsort
SELECT 47 * col2 + - col0 AS col2 FROM tab2
----
1144
1262
1707

query I rowsort
SELECT ALL - cor0.col1 * col1 + col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL - col0 - + col2 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * + cor0.col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * + col1 col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL + + cor0.col0 + + col2 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + + 32 * col2 + - col0 AS col1 FROM tab2 cor0
----
1137
754
857

query I rowsort
SELECT - cor0.col1 * col0 - + col2 AS col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT ALL 75 + col0 FROM tab2 AS cor0
----
153
154
82

query I rowsort
SELECT DISTINCT - col1 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7659
SELECT - 60 - + col1 DIV col1 FROM tab2 AS cor0
----
-61
-61
-61

skipif mysql # not compatible
query I rowsort label-7659
SELECT - 60 - + col1 / col1 FROM tab2 AS cor0
----
-61
-61
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-7660
SELECT ALL + col1 DIV col2 + - cor0.col2 AS col1 FROM tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-7660
SELECT ALL + col1 / col2 + - cor0.col2 AS col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - cor0.col1 + + col1 - - col2 * + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + - 48 * col1 - col1 * + col1 FROM tab1 AS cor0
----
-1924
-580
-793

query I rowsort
SELECT DISTINCT - col0 * col2 + - col1 * + col0 FROM tab2 AS cor0
----
-406
-4345
-6630

query I rowsort
SELECT + col1 * + ( col0 + cor0.col2 ) FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT DISTINCT - col1 * ( - cor0.col0 ) AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - cor0.col2 * - ( + cor0.col2 ) * + col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT + cor0.col0 + - 88 FROM tab0 AS cor0
----
-53
-64
1

query I rowsort
SELECT - col1 * + 62 FROM tab1 AS cor0
----
-1612
-620
-806

query I rowsort
SELECT ALL + - cor0.col1 * col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + col2 + col2 + col2 * col2 AS col1 FROM tab0 AS cor0
----
1155
3
6888

query I rowsort
SELECT ALL col0 + 75 * - 28 AS col2 FROM tab2 AS cor0
----
-2021
-2022
-2093

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7672
SELECT DISTINCT + CAST( - col2 AS SIGNED ) * - cor0.col1 + col2 FROM tab1 cor0
----
1344
1458
627

skipif mysql # not compatible
query I rowsort label-7672
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) * - cor0.col1 + col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT 55 * - ( col0 ) + - col2 * - col2 FROM tab2 cor0
----
-2901
-3614
344

query I rowsort
SELECT ( - col2 ) * + col0 AS col2 FROM tab0 cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7675
SELECT ALL col1 DIV - CAST( + col0 AS SIGNED ) FROM tab1
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-7675
SELECT ALL col1 / - CAST ( + col0 AS INTEGER ) FROM tab1
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7676
SELECT DISTINCT col0 DIV - col0 AS col0 FROM tab2
----
-1

skipif mysql # not compatible
query I rowsort label-7676
SELECT DISTINCT col0 / - col0 AS col0 FROM tab2
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7677
SELECT col0 + - CAST( + col0 AS SIGNED ) + + col2 AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7677
SELECT col0 + - CAST ( + col0 AS INTEGER ) + + col2 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT + + col2 + 29 * 96 FROM tab2 AS cor0
----
2810
2811
2822

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7679
SELECT ALL + col0 + 5 * + ( col1 + + CAST( - col0 AS SIGNED ) ) * + col2 FROM tab0 AS cor0
----
10254
345
909

skipif mysql # not compatible
query I rowsort label-7679
SELECT ALL + col0 + 5 * + ( col1 + + CAST ( - col0 AS INTEGER ) ) * + col2 FROM tab0 AS cor0
----
10254
345
909

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + col2 * + col2 col1 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT - col1 + - col0 * + cor0.col2 + - col2 FROM tab1 AS cor0
----
-242
-3715
-7789

query I rowsort
SELECT ALL + cor0.col1 + col1 * ( col1 ) AS col2 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT + col0 * + col2 + 43 * - col1 + + 72 * + col1 FROM tab1 AS cor0
----
3938
8057
916

query I rowsort
SELECT ALL - col0 * - 22 AS col1 FROM tab0 AS cor0
----
1958
528
770

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7685
SELECT ALL + col2 * + ( cor0.col0 + col0 * CAST( - col0 AS SIGNED ) ) FROM tab0 cor0
----
-1190
-18216
-642224

skipif mysql # not compatible
query I rowsort label-7685
SELECT ALL + col2 * + ( cor0.col0 + col0 * CAST ( - col0 AS INTEGER ) ) FROM tab0 cor0
----
-1190
-18216
-642224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col1 col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT cor0.col2 * 46 AS col2 FROM tab1 cor0
----
2484
2622
4416

query I rowsort
SELECT - col2 * col2 + col1 + + col1 FROM tab0 AS cor0
----
-6542
-917
193

onlyif mysql # use DIV operator for integer division
query I rowsort label-7689
SELECT + + col1 * col1 DIV - col1 + + col2 + cor0.col0 col1 FROM tab0 AS cor0
----
-29
-61
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7689
SELECT + + col1 * col1 / - col1 + + col2 + cor0.col0 col1 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT ALL + cor0.col1 + - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col2 + + col1 + + 51 AS col2 FROM tab1 AS cor0
----
118
131
160

query I rowsort
SELECT ALL + cor0.col2 + ( col2 ) FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT + + col1 * + 71 * col2 AS col2 FROM tab2 cor0
----
108914
45866
59427

query I rowsort
SELECT ALL + cor0.col1 * + ( - col1 ) AS col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - cor0.col2 - 17 FROM tab0, tab2 AS cor0, tab2 cor1
----
-43
-44
-55

query I rowsort
SELECT - ( col0 ) + + col1 AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT - 93 + col0 FROM tab1 cor0
----
-13
-29
-90

query I rowsort
SELECT col2 * 88 - - col1 AS col0 FROM tab0
----
185
2990
7307

query I rowsort
SELECT ALL 35 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT cor0.col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + cor0.col2 * + 18 + - col1 * + 21 AS col2 FROM tab0 AS cor0
----
-1212
-2019
-435

query I rowsort
SELECT ALL col2 * - col1 + ( tab1.col0 ) * ( col1 ) FROM tab1
----
-1326
-208
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col2 - - 29 col1 FROM tab0 AS cor0
----
-1060
-6695
28

query I rowsort
SELECT DISTINCT 73 * - col1 + - 23 AS col2 FROM tab2 AS cor0
----
-1264
-2286
-4330

query I rowsort
SELECT DISTINCT 37 * + col0 FROM tab0 AS cor0
----
1295
3293
888

query I rowsort
SELECT 34 * 92 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to beeee7769bb4524d5f312360f7dd4c3a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7707
SELECT ALL + 57 DIV cor0.col1 + col0 AS col1 FROM tab2 AS cor0
----
78
8
82

skipif mysql # not compatible
query I rowsort label-7707
SELECT ALL + 57 / cor0.col1 + col0 AS col1 FROM tab2 AS cor0
----
78
8
82

query I rowsort
SELECT tab2.col1 * col0 - tab2.col2 FROM tab2
----
1305
190
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-7709
SELECT - col0 + col2 DIV 49 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-7709
SELECT - col0 + col2 / 49 FROM tab1
----
-2
-63
-79

query I rowsort
SELECT - col0 * col0 + + ( + 47 ) AS col2 FROM tab2
----
-2
-6037
-6194

query I rowsort
SELECT col0 + + cor0.col2 * + col2 AS col0 FROM tab0 cor0
----
1113
36
6813

query I rowsort
SELECT col2 + col0 + - ( + col0 + - col0 ) FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT 15 * col0 FROM tab2
----
105
1170
1185

query I rowsort
SELECT DISTINCT col2 + - col2 + col1 * - col0 * tab2.col0 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT - col1 * col0 * + col0 + col2 FROM tab1
----
-180
-40903
-83104

query I rowsort
SELECT ALL 45 + col0 AS col1 FROM tab1
----
109
125
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7717
SELECT - cor0.col2 - ( + ( col1 ) + + CAST( NULL AS SIGNED ) ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7717
SELECT - cor0.col2 - ( + ( col1 ) + + CAST ( NULL AS INTEGER ) ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + ( + col2 ) + + cor0.col1 AS col0 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT DISTINCT + ( ( + cor0.col2 ) ) + - 75 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-37
-48
-49

query I rowsort
SELECT ALL - col1 + - col2 AS col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT - 52 * + cor0.col1 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 7ea866160fd0f579cea24af6e5d2e9dc

onlyif mysql # use DIV operator for integer division
query I rowsort label-7722
SELECT col0 DIV 79 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7722
SELECT col0 / 79 AS col2 FROM tab1
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7723
SELECT ALL + col0 * 56 DIV ( col0 ) FROM tab0
----
56
56
56

skipif mysql # not compatible
query I rowsort label-7723
SELECT ALL + col0 * 56 / ( col0 ) FROM tab0
----
56
56
56

query I rowsort
SELECT ALL - 25 AS col1 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 2e7a33467ee3a4d9570560d60302b35a

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab1 cor1, tab0 AS cor2
----
972 values hashing to b51b4342db121ebc2d3d353dcd8ed521

query I rowsort
SELECT col1 * ( col2 ) + col1 * col1 * cor0.col1 + - col0 * col1 FROM tab1 cor0
----
18902
2405
930

query I rowsort
SELECT - col1 - - col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL - ( 25 ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 40ac8fd000b2e49317aed2411077839e

query I rowsort
SELECT 48 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT - col1 + ( + cor0.col1 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 + col0 + col2 * - col2 AS col0 FROM tab1 cor0
----
-2887
-3175
-9123

query I rowsort
SELECT DISTINCT - 30 AS col2 FROM tab2, tab1 AS cor0
----
-30

query I rowsort
SELECT ALL cor0.col2 * ( + cor0.col1 * + cor0.col0 + col1 ) FROM tab2 AS cor0
----
121186
51680
6696

query I rowsort
SELECT DISTINCT tab1.col2 * - col2 AS col0 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT - col0 * tab1.col2 + + col1 AS col0 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT 63 FROM tab2, tab1 cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT - ( - 9 ) AS col0 FROM tab1
----
9
9
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7738
SELECT ALL col1 DIV - col1 + col2 DIV - cor0.col0 FROM tab0 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-7738
SELECT ALL col1 / - col1 + col2 / - cor0.col0 FROM tab0 AS cor0
----
-1
-1
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7739
SELECT ALL + + col2 + col2 * 88 DIV col2 FROM tab0 AS cor0
----
121
170
89

skipif mysql # not compatible
query I rowsort label-7739
SELECT ALL + + col2 + col2 * 88 / col2 FROM tab0 AS cor0
----
121
170
89

query I rowsort
SELECT 99 * + col2 FROM tab0 AS cor0
----
3267
8118
99

query I rowsort
SELECT ALL - - col0 * col1 + + col0 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT col2 * + cor0.col2 - - ( + col1 ) * - col0 AS col0 FROM tab2 AS cor0
----
-3926
101
512

query I rowsort
SELECT - col2 * - col0 * cor0.col0 AS col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT ALL + 32 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
58
59
70

query I rowsort
SELECT + 74 + + col2 FROM tab1 AS cor0
----
128
131
170

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7746
SELECT CAST( NULL AS SIGNED ) / col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7746
SELECT CAST ( NULL AS INTEGER ) / col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - cor0.col2 - col0 AS col2 FROM tab1 AS cor0
----
-2919
-3313
-9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( - 9 ) + col2 col2 FROM tab1 AS cor0
----
105
63
66

query I rowsort
SELECT ALL - cor1.col1 * 51 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 8fb05b2dee0359fcaabe0421d52a0ad2

query I rowsort
SELECT ( - 15 ) - col0 AS col2 FROM tab0 AS cor0
----
-104
-39
-50

query I rowsort
SELECT col0 + + 56 AS col2 FROM tab1 AS cor0
----
120
136
59

query I rowsort
SELECT ALL - 80 * - col1 AS col0 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT DISTINCT - - 30 AS col1 FROM tab1 AS cor0
----
30

query I rowsort
SELECT - + col2 + - col0 * 67 FROM tab0 AS cor0
----
-1641
-2346
-6045

query I rowsort
SELECT ALL + + col2 * cor0.col1 + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT 72 FROM tab1 AS cor0
----
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 col0 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL tab0.col0 - - tab0.col1 FROM tab0
----
110
132
180

query I rowsort
SELECT + 30 * - 44 FROM tab1
----
-1320
-1320
-1320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7760
SELECT ALL - CAST( NULL AS SIGNED ) / + col2 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7760
SELECT ALL - CAST ( NULL AS INTEGER ) / + col2 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( + 76 ) * col1 FROM tab0
----
6536
6916
7372

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7762
SELECT + col0 + - CAST( col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-7762
SELECT + col0 + - CAST ( col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + cor0.col1 * col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + - col0 * - ( - 96 ) AS col0 FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT col2 * 52 FROM tab0 cor0
----
1716
4264
52

query I rowsort
SELECT DISTINCT + 65 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
65

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT - - 66 FROM tab2 AS cor0
----
66
66
66

query I rowsort
SELECT ALL col0 + + col0 * col1 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL + cor0.col2 * - cor0.col0 + + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT - ( 57 ) AS col1 FROM tab2 AS cor0
----
-57
-57
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7772
SELECT ALL + col1 DIV cor0.col0 + - cor0.col2 DIV col2 AS col2 FROM tab1 AS cor0
----
-1
-1
7

skipif mysql # not compatible
query I rowsort label-7772
SELECT ALL + col1 / cor0.col0 + - cor0.col2 / col2 AS col2 FROM tab1 AS cor0
----
-1
-1
7

query I rowsort
SELECT ALL - 9 * col2 + col1 + col2 FROM tab2 AS cor0
----
-149
-185
-287

onlyif mysql # use DIV operator for integer division
query I rowsort label-7774
SELECT DISTINCT + 22 DIV + 95 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-7774
SELECT DISTINCT + 22 / + 95 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL - 56 FROM tab1, tab2 AS cor0
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 cor0 CROSS JOIN tab1, tab0 AS cor1, tab2 AS cor2
----
3645 values hashing to 773bb916e463ebc075d701108532badb

query I rowsort
SELECT cor0.col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

onlyif mysql # use DIV operator for integer division
query I rowsort label-7778
SELECT + 46 DIV - col1 + - col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7778
SELECT + 46 / - col1 + - col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT ALL ( - ( col1 ) ) * - col2 + 46 * col1 FROM tab2 AS cor0
----
1428
2263
4248

onlyif mysql # use DIV operator for integer division
query I rowsort label-7780
SELECT DISTINCT + ( - col1 ) + cor0.col2 DIV + col2 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-7780
SELECT DISTINCT + ( - col1 ) + cor0.col2 / + col2 FROM tab0 AS cor0
----
-85
-90
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7781
SELECT - - CAST( NULL AS SIGNED ) * + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7781
SELECT - - CAST ( NULL AS INTEGER ) * + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - 3 + cor0.col1 * - col2 FROM tab1 cor0
----
-1251
-1407
-573

onlyif mysql # use DIV operator for integer division
query I rowsort label-7783
SELECT ALL ( 78 ) DIV - col0 FROM tab1 AS cor0
----
-1
-26
0

skipif mysql # not compatible
query I rowsort label-7783
SELECT ALL ( 78 ) / - col0 FROM tab1 AS cor0
----
-1
-26
0

query I rowsort
SELECT DISTINCT + col0 * ( - cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * cor0.col2 + col0 col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL - 57 * - col1 + col0 AS col2 FROM tab2 AS cor0
----
1048
1774
3441

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7787
SELECT ALL CAST( NULL AS SIGNED ) - 93 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7787
SELECT ALL CAST ( NULL AS INTEGER ) - 93 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7788
SELECT col2 DIV col1 + ( - cor0.col0 ) FROM tab1 AS cor0
----
-1
-59
-73

skipif mysql # not compatible
query I rowsort label-7788
SELECT col2 / col1 + ( - cor0.col0 ) FROM tab1 AS cor0
----
-1
-59
-73

query I rowsort
SELECT ALL - 71 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

query I rowsort
SELECT ALL - - ( + cor0.col0 ) FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7791
SELECT + + 41 DIV col1 - ( col1 ) * col2 col2 FROM tab2 cor0
----
-1534
-644
-836

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7791
SELECT + + 41 / col1 - ( col1 ) * col2 col2 FROM tab2 cor0
----
-1534
-644
-836

query I rowsort
SELECT - col2 * col2 + - ( + col2 ) AS col0 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT - 77 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT DISTINCT 69 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
69

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-7796
SELECT + col2 * - CAST( 48 AS SIGNED ) FROM tab1 AS cor0
----
-2592
-2736
-4608

skipif mysql # not compatible
query I rowsort label-7796
SELECT + col2 * - CAST ( 48 AS INTEGER ) FROM tab1 AS cor0
----
-2592
-2736
-4608

query I rowsort
SELECT DISTINCT 51 + - col0 FROM tab0
----
-38
16
27

query I rowsort
SELECT 69 + + col0 AS col2 FROM tab0
----
104
158
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col1 * col0 col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT + ( col1 ) * + tab2.col2 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT + col2 + 53 FROM tab0
----
135
54
86

query I rowsort
SELECT - cor0.col1 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # use DIV operator for integer division
query I rowsort label-7803
SELECT 31 DIV col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7803
SELECT 31 / col1 AS col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7804
SELECT + 33 DIV cor0.col0 + col1 AS col1 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-7804
SELECT + 33 / cor0.col0 + col1 AS col1 FROM tab0 AS cor0
----
87
91
97

query I rowsort
SELECT DISTINCT + col1 * col2 + col0 * + col2 AS col0 FROM tab2
----
1026
3562
3648

query I rowsort
SELECT DISTINCT 72 AS col0 FROM tab2, tab1 AS cor0
----
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7807
SELECT DISTINCT - CAST( 42 AS SIGNED ) + - col2 FROM tab1
----
-138
-96
-99

skipif mysql # not compatible
query I rowsort label-7807
SELECT DISTINCT - CAST ( 42 AS INTEGER ) + - col2 FROM tab1
----
-138
-96
-99

query I rowsort
SELECT ALL + col0 * - col2 + col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT + + 70 * col2 + + col1 AS col1 FROM tab2 AS cor0
----
1879
1921
2677

query I rowsort
SELECT ALL - - col0 + - col2 * - col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT col2 * - tab0.col1 AS col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT 47 * cor0.col1 FROM tab1 AS cor0
----
1222
470
611

query I rowsort
SELECT 59 - + 58 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT - - ( col2 ) * col1 + col1 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT - 70 * - col0 + + 69 AS col0 FROM tab1 cor0
----
279
4549
5669

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 75 + col0 col2 FROM tab2 cor0
----
153
154
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7817
SELECT DISTINCT col0 * - cor0.col2 * 38 + cor0.col0 DIV - col1 FROM tab1 AS cor0
----
-138630
-291846
-6156

skipif mysql # not compatible
query I rowsort label-7817
SELECT DISTINCT col0 * - cor0.col2 * 38 + cor0.col0 / - col1 FROM tab1 AS cor0
----
-138630
-291846
-6156

query I rowsort
SELECT + - col2 * - col0 + + col0 * + col1 FROM tab0 AS cor0
----
15397
2856
3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-7819
SELECT col2 - - cor0.col0 DIV + ( cor0.col0 ) FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-7819
SELECT col2 - - cor0.col0 / + ( cor0.col0 ) FROM tab0 AS cor0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7820
SELECT + col1 DIV 2 AS col1 FROM tab1 AS cor0
----
13
5
6

skipif mysql # not compatible
query I rowsort label-7820
SELECT + col1 / 2 AS col1 FROM tab1 AS cor0
----
13
5
6

query I rowsort
SELECT ALL col2 * - 53 AS col2 FROM tab0 cor0
----
-1749
-4346
-53

query I rowsort
SELECT DISTINCT - 78 FROM tab0, tab0 AS cor0
----
-78

query I rowsort
SELECT ALL - + col2 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL col1 * - ( - cor0.col2 ) FROM tab1 cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col1 * + col0 col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL - cor0.col2 + cor0.col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL + 61 * + cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to e60cda0771a75019f27e20322a1e8ba7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7828
SELECT DISTINCT col2 * col1 - col0 DIV 7 FROM tab2 AS cor0
----
1523
635
836

skipif mysql # not compatible
query I rowsort label-7828
SELECT DISTINCT col2 * col1 - col0 / 7 FROM tab2 AS cor0
----
1523
635
836

query I rowsort
SELECT DISTINCT 18 * col1 * - col2 AS col1 FROM tab2 AS cor0
----
-11628
-15066
-27612

query I rowsort
SELECT DISTINCT - cor0.col1 * ( - cor0.col0 ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - + 56 + ( + col0 ) + col0 AS col1 FROM tab0 AS cor0
----
-8
122
14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 67 col0 FROM tab0 AS cor0
----
1608
2345
5963

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7833
SELECT - col1 + CAST( - col0 AS SIGNED ) FROM tab2
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-7833
SELECT - col1 + CAST ( - col0 AS INTEGER ) FROM tab2
----
-137
-38
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7834
SELECT + col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7834
SELECT + col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * - 87 * + col0 AS col0 FROM tab1 AS cor0
----
-356352
-556800
-783

query I rowsort
SELECT + col1 * - 25 FROM tab1 cor0
----
-250
-325
-650

query I rowsort
SELECT - + ( - cor0.col1 ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - - 15 * col0 AS col2 FROM tab1 AS cor0
----
1200
45
960

query I rowsort
SELECT - 61 AS col1 FROM tab1 AS cor0
----
-61
-61
-61

query I rowsort
SELECT + ( + col1 ) AS col0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT + col0 * col1 - + 80 * col2 * col0 FROM tab1 AS cor0
----
-12882
-291200
-613360

onlyif mysql # use DIV operator for integer division
query I rowsort label-7842
SELECT + col1 - col2 DIV - col0 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-7842
SELECT + col1 - col2 / - col0 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT ALL col1 * 59 AS col1 FROM tab2
----
1003
1829
3481

onlyif mysql # use DIV operator for integer division
query I rowsort label-7844
SELECT + + cor0.col0 DIV - col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7844
SELECT + + cor0.col0 / - col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + col0 * + 95 FROM tab0 AS cor0
----
2280
3325
8455

query I rowsort
SELECT - - col2 + - 8 AS col0 FROM tab1 AS cor0
----
46
49
88

query I rowsort
SELECT DISTINCT + ( - cor0.col0 ) FROM tab1, tab2 AS cor0, tab1 AS cor1
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7848
SELECT - - col0 DIV + col0 AS col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7848
SELECT - - col0 / + col0 AS col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL + col0 * - 74 * col2 FROM tab1
----
-11988
-269952
-568320

onlyif mysql # use DIV operator for integer division
query I rowsort label-7850
SELECT DISTINCT col0 DIV - 24 AS col0 FROM tab2
----
-3
0

skipif mysql # not compatible
query I rowsort label-7850
SELECT DISTINCT col0 / - 24 AS col0 FROM tab2
----
-3
0

query I rowsort
SELECT DISTINCT col2 * tab0.col2 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL + col0 * - 87 AS col2 FROM tab1
----
-261
-5568
-6960

query I rowsort
SELECT ALL col1 + - col1 * col2 * - col1 AS col1 FROM tab1 AS cor0
----
16237
36530
5710

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7854
SELECT DISTINCT col2 * CAST( NULL AS SIGNED ) / - col2 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7854
SELECT DISTINCT col2 * CAST ( NULL AS INTEGER ) / - col2 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT 56 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

query I rowsort
SELECT DISTINCT - tab0.col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
-86
-91
-97

query I rowsort
SELECT ALL - 65 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4ca93c42a91c7dff917e7b7090ba9e57

query I rowsort
SELECT DISTINCT 52 FROM tab0, tab0 AS cor0, tab2 cor1
----
52

query I rowsort
SELECT - cor0.col1 + 46 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 53419662bd47a363930e3dec8f4005ea

query I rowsort
SELECT cor0.col2 * - cor0.col0 * cor0.col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT ( - ( cor0.col0 ) ) AS col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 37 col2 FROM tab1
----
37

query I rowsort
SELECT 23 + + 61 + tab0.col0 FROM tab0, tab1 cor0
----
9 values hashing to 3f730adb0125410b47de9f7c299042ec

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * ( ( col0 ) ) - ( + col2 ) * col1 col1 FROM tab1 AS cor0
----
-1395
3526
5152

onlyif mysql # use DIV operator for integer division
query I rowsort label-7865
SELECT ALL col2 DIV - col1 + cor0.col1 FROM tab2 AS cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-7865
SELECT ALL col2 / - col1 + cor0.col1 FROM tab2 AS cor0
----
15
31
59

query I rowsort
SELECT ALL col1 * ( col0 * col2 ) - 25 FROM tab1 AS cor0
----
36455
4187
99815

query I rowsort
SELECT cor0.col2 + cor0.col0 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT 75 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to 5418e29983129f6ba0e1aa0e11342822

query I rowsort
SELECT DISTINCT + col2 * + ( col1 ) + col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + col2 + 40 AS col0 FROM tab0 AS cor0
----
122
41
73

query I rowsort
SELECT - col1 * 38 FROM tab0 AS cor0
----
-3268
-3458
-3686

query I rowsort
SELECT DISTINCT col1 + 51 AS col1 FROM tab0 AS cor0
----
137
142
148

onlyif mysql # use DIV operator for integer division
query I rowsort label-7873
SELECT ALL col0 * - col2 + + col2 DIV + col0 FROM tab0 cor0
----
-35
-7298
-791

skipif mysql # not compatible
query I rowsort label-7873
SELECT ALL col0 * - col2 + + col2 / + col0 FROM tab0 cor0
----
-35
-7298
-791

onlyif mysql # use DIV operator for integer division
query I rowsort label-7874
SELECT DISTINCT - col0 DIV col1 + col2 AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7874
SELECT DISTINCT - col0 / col1 + col2 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT 4 - + 7 FROM tab1
----
-3
-3
-3

query I rowsort
SELECT 45 + col0 AS col0 FROM tab2 AS cor0
----
123
124
52

query I rowsort
SELECT DISTINCT + col2 * 0 FROM tab0
----
0

query I rowsort
SELECT ALL 28 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col0 * - col0 col1 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT cor0.col1 AS col2 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col1 col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * cor0.col0 + cor0.col0 * 11 col2 FROM tab0 AS cor0
----
1056
420
8277

query I rowsort
SELECT DISTINCT - + 96 - cor0.col2 AS col0 FROM tab1 cor0
----
-150
-153
-192

query I rowsort
SELECT ALL cor0.col2 + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT - - col0 * + col2 * col1 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ( + col0 ) * + col2 + + col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT - col0 + col2 * col1 AS col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT 44 AS col0 FROM tab2 cor0
----
44
44
44

query I rowsort
SELECT ALL - col1 * - 57 * col2 AS col1 FROM tab0
----
161766
425334
5529

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * col0 + + col0 col2 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT ALL + + col0 * cor0.col0 - + ( + col1 ) AS col0 FROM tab2 AS cor0
----
18
6025
6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col0 * + cor0.col1 col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 220064493ff9775ff1f87429d726f896

query I rowsort
SELECT - 40 + + col1 + + col0 * col1 FROM tab1 AS cor0
----
1013
610
64

query I rowsort
SELECT DISTINCT col1 * - col0 * - 80 FROM tab1 cor0
----
51200
6240
83200

query I rowsort
SELECT - 23 + - col2 + 99 AS col2 FROM tab2 cor0
----
38
49
50

query I rowsort
SELECT + col2 + - cor0.col2 * col0 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - + col1 + col2 * + 59 FROM tab2 AS cor0
----
1475
1562
2225

query I rowsort
SELECT ALL 61 + + cor0.col1 FROM tab0 AS cor0
----
147
152
158

query I rowsort
SELECT DISTINCT - 59 * + col0 AS col1 FROM tab1 AS cor0
----
-177
-3776
-4720

query I rowsort
SELECT ( col1 ) - col2 AS col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL + cor0.col0 + 81 * ( + cor0.col0 ) AS col2 FROM tab1 AS cor0
----
246
5248
6560

query I rowsort
SELECT ALL - col2 * 2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL - col1 - - col0 AS col2 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + + col0 + 42 AS col1 FROM tab2 AS cor0
----
120
121
49

query I rowsort
SELECT ALL - - col0 - + 62 AS col2 FROM tab2 AS cor0
----
-55
16
17

query I rowsort
SELECT DISTINCT + col2 * 47 * - col0 FROM tab2 AS cor0
----
-141094
-8883
-95316

query I rowsort
SELECT ALL + cor0.col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7908
SELECT col0 + col2 * CAST( NULL AS SIGNED ) * - col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7908
SELECT col0 + col2 * CAST ( NULL AS INTEGER ) * - col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 89 AS col1 FROM tab0 AS cor0
----
89
89
89

query I rowsort
SELECT + 42 * col2 * - col1 FROM tab2 AS cor0
----
-27132
-35154
-64428

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7911
SELECT ALL - CAST( NULL AS DECIMAL ) * 74 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7911
SELECT ALL - CAST ( NULL AS REAL ) * 74 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * col0 + + col2 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
-448
1280
153

query I rowsort
SELECT DISTINCT - col1 * 17 AS col2 FROM tab1 AS cor0
----
-170
-221
-442

query I rowsort
SELECT DISTINCT + + col0 + ( col1 * - 98 ) FROM tab0 AS cor0
----
-8404
-8829
-9471

onlyif mysql # use DIV operator for integer division
query I rowsort label-7915
SELECT DISTINCT ( col2 ) DIV - col2 AS col0 FROM tab0 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-7915
SELECT DISTINCT ( col2 ) / - col2 AS col0 FROM tab0 cor0
----
-1

query I rowsort
SELECT col0 - - 10 AS col0 FROM tab2 AS cor0
----
17
88
89

query I rowsort
SELECT + ( + col0 ) * - col0 + col1 * col0 * col0 + col1 FROM tab1 AS cor0
----
251
36874
76813

query I rowsort
SELECT + col0 * cor0.col1 - col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT col2 * 50 FROM tab0 AS cor0
----
1650
4100
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 57 * - cor0.col1 col2 FROM tab2 AS cor0
----
1767
3363
969

query I rowsort
SELECT DISTINCT - col0 * + col2 * col0 AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT ALL col2 + col2 * + col2 FROM tab1 cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-7923
SELECT + - ( col1 ) * + col2 + col0 DIV - ( cor0.col1 * - col1 ) + - 38 AS col0 FROM tab1 AS cor0
----
-1286
-1442
-608

skipif mysql # not compatible
query I rowsort label-7923
SELECT + - ( col1 ) * + col2 + col0 / - ( cor0.col1 * - col1 ) + - 38 AS col0 FROM tab1 AS cor0
----
-1286
-1442
-608

query I rowsort
SELECT ALL 13 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7926
SELECT ALL - col0 * CAST( + col1 AS SIGNED ) - + col1 AS col0 FROM tab0
----
-2150
-3492
-8190

skipif mysql # not compatible
query I rowsort label-7926
SELECT ALL - col0 * CAST ( + col1 AS INTEGER ) - + col1 AS col0 FROM tab0
----
-2150
-3492
-8190

query I rowsort
SELECT + tab2.col1 + + col2 + ( tab2.col2 ) * + tab2.col1 * 9 FROM tab2
----
13891
5869
7591

query I rowsort
SELECT ALL - col1 + - tab1.col0 + - col2 AS col2 FROM tab1
----
-131
-189
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 46 col1 FROM tab2 AS cor0
----
46
46
46

query I rowsort
SELECT ALL 78 * 72 + - col1 AS col0 FROM tab1 AS cor0
----
5590
5603
5606

query I rowsort
SELECT + ( 40 ) FROM tab1 cor0
----
40
40
40

query I rowsort
SELECT ALL - col1 + col2 * - col2 * - col2 AS col2 FROM tab0 AS cor0
----
-96
35851
551277

query I rowsort
SELECT ALL + 53 * - col0 FROM tab2 AS cor0
----
-371
-4134
-4187

query I rowsort
SELECT ALL + ( + 89 ) + col2 + + 24 FROM tab0
----
114
146
195

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7935
SELECT DISTINCT col0 + 16 + - col1 * - CAST( - col1 AS SIGNED ) FROM tab1
----
-20
-657
-73

skipif mysql # not compatible
query I rowsort label-7935
SELECT DISTINCT col0 + 16 + - col1 * - CAST ( - col1 AS INTEGER ) FROM tab1
----
-20
-657
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7936
SELECT + CAST( NULL AS SIGNED ) col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 AS cor2
----
243 values hashing to 76933ee8cce600e48802fbdea2376d45

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7936
SELECT + CAST ( NULL AS INTEGER ) col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 AS cor2
----
243 values hashing to 76933ee8cce600e48802fbdea2376d45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7937
SELECT + CAST( NULL AS SIGNED ) * ( - col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7937
SELECT + CAST ( NULL AS INTEGER ) * ( - col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 * - col1 * + col2 AS col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-7939
SELECT - + cor0.col2 DIV CAST( col0 AS SIGNED ) col2 FROM tab0 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7939
SELECT - + cor0.col2 / CAST ( col0 AS INTEGER ) col2 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT + col2 * 53 * - col0 FROM tab2 AS cor0
----
-10017
-107484
-159106

query I rowsort
SELECT ALL - - col1 + - ( + 84 ) AS col0 FROM tab1 AS cor0
----
-58
-71
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-7942
SELECT + cor0.col1 DIV + cor0.col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-7942
SELECT + cor0.col1 / + cor0.col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT - col1 + col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
156
650
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7944
SELECT ALL + ( - ( cor1.col0 ) ) * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7944
SELECT ALL + ( - ( cor1.col0 ) ) * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL col0 * + col2 * - col2 + col2 FROM tab0
----
-26103
-34
-598354

query I rowsort
SELECT DISTINCT 35 * + tab2.col0 AS col0 FROM tab2, tab1 AS cor0
----
245
2730
2765

onlyif mysql # use DIV operator for integer division
query I rowsort label-7947
SELECT DISTINCT - - col1 DIV + 3 AS col1 FROM tab1 AS cor0
----
3
4
8

skipif mysql # not compatible
query I rowsort label-7947
SELECT DISTINCT - - col1 / + 3 AS col1 FROM tab1 AS cor0
----
3
4
8

query I rowsort
SELECT - col1 * 15 FROM tab0 AS cor0
----
-1290
-1365
-1455

query I rowsort
SELECT ALL + + col2 + ( ( cor0.col0 ) ) FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - + col1 * - 43 AS col0 FROM tab2 cor0
----
1333
2537
731

onlyif mysql # use DIV operator for integer division
query I rowsort label-7951
SELECT ALL - col0 + - 30 DIV 10 AS col0 FROM tab0 AS cor0
----
-27
-38
-92

skipif mysql # not compatible
query I rowsort label-7951
SELECT ALL - col0 + - 30 / 10 AS col0 FROM tab0 AS cor0
----
-27
-38
-92

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL col1 + ( + col0 ) FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col1 + col1 * + col2 col1 FROM tab2 AS cor0
----
1292
1674
3068

query I rowsort
SELECT col2 * tab2.col0 * + col1 AS col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL 15 AS col1 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT col1 * 66 AS col1 FROM tab2
----
1122
2046
3894

query I rowsort
SELECT - col2 + - 60 * + col1 AS col0 FROM tab1
----
-1614
-657
-876

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7959
SELECT - CAST( NULL AS SIGNED ) + + tab2.col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7959
SELECT - CAST ( NULL AS INTEGER ) + + tab2.col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( + 52 ) * cor0.col1 + + ( + 23 + + col1 ) AS col2 FROM tab2 AS cor0
----
1666
3150
924

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + + col0 col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + 74 AS col1 FROM tab0
----
74
74
74

query I rowsort
SELECT + 93 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 + - col2 col2 FROM tab2
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT - 32 * col1 AS col1 FROM tab0
----
-2752
-2912
-3104

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL cor0.col0 * col1 + + cor0.col2 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7968
SELECT ALL - - cor0.col0 * col2 * CAST( - col2 AS SIGNED ) + col2 FROM tab2 AS cor0
----
-114038
-5076
-52702

skipif mysql # not compatible
query I rowsort label-7968
SELECT ALL - - cor0.col0 * col2 * CAST ( - col2 AS INTEGER ) + col2 FROM tab2 AS cor0
----
-114038
-5076
-52702

onlyif mysql # use DIV operator for integer division
query I rowsort label-7969
SELECT DISTINCT - col2 + col2 DIV col0 AS col0 FROM tab0 AS cor0
----
-1
-32
-82

skipif mysql # not compatible
query I rowsort label-7969
SELECT DISTINCT - col2 + col2 / col0 AS col0 FROM tab0 AS cor0
----
-1
-32
-82

query I rowsort
SELECT - + 11 + - cor1.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 9b630042500cd20f202d4fb8dbb15e2f

query I rowsort
SELECT ALL tab0.col0 AS col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT 77 * + col2 FROM tab1 AS cor0
----
4158
4389
7392

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 * col1 col0 FROM tab1
----
-156
-650
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7974
SELECT ALL 89 DIV - col0 FROM tab1 AS cor0
----
-1
-1
-29

skipif mysql # not compatible
query I rowsort label-7974
SELECT ALL 89 / - col0 FROM tab1 AS cor0
----
-1
-1
-29

query I rowsort
SELECT - col0 - 59 AS col2 FROM tab0 AS cor0
----
-148
-83
-94

query I rowsort
SELECT DISTINCT - - ( - 18 ) FROM tab0 AS cor0
----
-18

query I rowsort
SELECT ALL + col1 * cor0.col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + + col1 + - 43 AS col2 FROM tab0 cor0
----
43
48
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7979
SELECT - - CAST( NULL AS SIGNED ) * 4 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7979
SELECT - - CAST ( NULL AS INTEGER ) * 4 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT - - cor0.col1 + + col1 + + ( cor0.col0 * col0 ) AS col1 FROM tab2 AS cor0
----
111
6202
6275

query I rowsort
SELECT - col1 * 68 FROM tab1
----
-1768
-680
-884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + 14 * col2 col2 FROM tab1
----
1424
759
862

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) * col1 col0 FROM tab2
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-7985
SELECT ALL CAST( col0 AS SIGNED ) DIV col0 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7985
SELECT ALL CAST ( col0 AS INTEGER ) / col0 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL ( - 47 ) FROM tab0
----
-47
-47
-47

query I rowsort
SELECT DISTINCT - cor0.col1 AS col1 FROM tab2, tab1, tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL col0 * + 98 AS col1 FROM tab0 AS cor0
----
2352
3430
8722

onlyif mysql # use DIV operator for integer division
query I rowsort label-7989
SELECT DISTINCT - - col2 + - col2 DIV col1 AS col1 FROM tab2 AS cor0
----
26
27
36

skipif mysql # not compatible
query I rowsort label-7989
SELECT DISTINCT - - col2 + - col2 / col1 AS col1 FROM tab2 AS cor0
----
26
27
36

query I rowsort
SELECT col2 * ( col2 ) FROM tab1
----
2916
3249
9216

query I rowsort
SELECT - col1 * + col1 * 10 + col0 + ( col0 * - tab1.col0 ) FROM tab1
----
-5032
-6766
-8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7992
SELECT ALL col1 + + CAST( NULL AS SIGNED ) * + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7992
SELECT ALL col1 + + CAST ( NULL AS INTEGER ) * + col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor1.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT ALL ( col0 ) * col1 * + col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT ( - 81 ) AS col0 FROM tab1
----
-81

query I rowsort
SELECT DISTINCT + col2 * col0 * tab2.col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT + 24 + 55 AS col1 FROM tab1 cor0
----
79
79
79

query I rowsort
SELECT ALL - - ( cor0.col0 ) * + col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + + 87 * col1 * ( - ( + cor0.col1 ) ) col2 FROM tab0 AS cor0
----
-643428
-720358
-818548

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8000
SELECT - - CAST( - col0 AS SIGNED ) * col1 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8000
SELECT - - CAST ( - col0 AS INTEGER ) * col1 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + + 19 FROM tab0, tab0 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT + col0 + col2 * - col0 AS col0 FROM tab2 cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL ( tab0.col2 ) * 67 - - col1 AS col0 FROM tab0
----
164
2297
5585

query I rowsort
SELECT col1 + + 14 AS col0 FROM tab1 AS cor0
----
24
27
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-8005
SELECT col0 DIV cor0.col1 + + col1 AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8005
SELECT col0 / cor0.col1 + + col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + + cor0.col2 + 44 FROM tab2 AS cor0
----
70
71
82

query I rowsort
SELECT DISTINCT - + col1 - 52 FROM tab2 AS cor0
----
-111
-69
-83

query I rowsort
SELECT ALL - col2 + - col0 * ( - col0 ) FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT ALL + tab0.col2 AS col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT DISTINCT - 28 * col0 AS col2 FROM tab2
----
-196
-2184
-2212

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col1 col1 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8012
SELECT DISTINCT - col1 - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8012
SELECT DISTINCT - col1 - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col1 + - tab0.col2 AS col1 FROM tab0
----
53
9
96

query I rowsort
SELECT col0 * + 64 + - col1 FROM tab1
----
166
4086
5107

query I rowsort
SELECT + col2 - 18 AS col1 FROM tab0 AS cor0
----
-17
15
64

query I rowsort
SELECT + col1 + + col0 - - col0 FROM tab1 cor0
----
138
173
32

query I rowsort
SELECT - 52 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e8a5cb10c0973a78554f344d4f6e7e74

query I rowsort
SELECT ALL - col1 * - 66 AS col2 FROM tab1 AS cor0
----
1716
660
858

query I rowsort
SELECT + + ( + col2 ) AS col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 83 col1 FROM tab1 cor0
----
83
83
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8021
SELECT - col2 * 51 DIV col1 + - 53 FROM tab2 cor0
----
-167
-75
-97

skipif mysql # not compatible
query I rowsort label-8021
SELECT - col2 * 51 / col1 + - 53 FROM tab2 cor0
----
-167
-75
-97

query I rowsort
SELECT DISTINCT + ( col2 ) - + col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - 89 - + col0 * - cor0.col2 FROM tab2 AS cor0
----
100
1939
2913

query I rowsort
SELECT - + col1 + col0 * col0 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT ALL - ( + col1 ) * cor0.col1 + col2 AS col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT + ( 11 ) FROM tab1 AS cor0
----
11
11
11

query I rowsort
SELECT ALL + - 43 + 82 AS col1 FROM tab2 AS cor0
----
39
39
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-8028
SELECT DISTINCT 9 * - col1 - col0 DIV + col1 AS col2 FROM tab0 AS cor0
----
-774
-819
-873

skipif mysql # not compatible
query I rowsort label-8028
SELECT DISTINCT 9 * - col1 - col0 / + col1 AS col2 FROM tab0 AS cor0
----
-774
-819
-873

query I rowsort
SELECT ALL ( col1 ) + - col1 * + 88 FROM tab1 cor0
----
-1131
-2262
-870

query I rowsort
SELECT DISTINCT - 55 * 0 + + col2 * + col2 + + cor0.col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - col1 + - 69 - col2 FROM tab1
----
-136
-149
-178

query I rowsort
SELECT 76 - - cor1.col1 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to 1277d34597c357afe4c18611ea2cc8fe

onlyif mysql # use DIV operator for integer division
query I rowsort label-8033
SELECT DISTINCT col2 DIV col1 + col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8033
SELECT DISTINCT col2 / col1 + col2 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT - col0 + ( col1 ) * col2 + col2 AS col0 FROM tab0
----
2847
63
7455

query I rowsort
SELECT 43 * 42 + + col0 AS col0 FROM tab2 cor0
----
1813
1884
1885

query I rowsort
SELECT DISTINCT + - col0 * ( col2 ) * col0 + col0 * col2 FROM tab1 AS cor0
----
-229824
-324
-606720

query I rowsort
SELECT - 38 * cor0.col1 FROM tab1 AS cor0
----
-380
-494
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 39 * + 95 col2 FROM tab0 AS cor0
----
-3705

query I rowsort
SELECT DISTINCT - col2 + col0 * 84 FROM tab1 AS cor0
----
198
5319
6624

onlyif mysql # use DIV operator for integer division
query I rowsort label-8040
SELECT ALL - + 21 DIV + col2 FROM tab0 AS cor0
----
-21
0
0

skipif mysql # not compatible
query I rowsort label-8040
SELECT ALL - + 21 / + col2 FROM tab0 AS cor0
----
-21
0
0

query I rowsort
SELECT + - cor0.col2 + - col1 * + col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL 69 + col0 FROM tab0 AS cor0
----
104
158
93

query I rowsort
SELECT DISTINCT col0 + + col2 * + col1 * 65 AS col2 FROM tab2 AS cor0
----
42069
54412
99788

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8044
SELECT CAST( + 6 AS SIGNED ) AS col2 FROM tab0
----
6
6
6

skipif mysql # not compatible
query I rowsort label-8044
SELECT CAST ( + 6 AS INTEGER ) AS col2 FROM tab0
----
6
6
6

query I rowsort
SELECT ALL + 73 * - cor0.col0 * - col2 AS col1 FROM tab1 AS cor0
----
11826
266304
560640

onlyif mysql # use DIV operator for integer division
query I rowsort label-8046
SELECT - col1 * col0 DIV - 5 AS col1 FROM tab1 cor0
----
128
15
208

skipif mysql # not compatible
query I rowsort label-8046
SELECT - col1 * col0 / - 5 AS col1 FROM tab1 cor0
----
128
15
208

query I rowsort
SELECT - 25 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-1475
-425
-775

query I rowsort
SELECT col1 * - col2 - ( - col0 + col1 ) FROM tab1
----
-1181
-1427
-516

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8049
SELECT - - col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8049
SELECT - - col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 - col0 FROM tab1 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8051
SELECT DISTINCT col0 * col1 * - CAST( - col1 AS SIGNED ) AS col1 FROM tab2
----
22831
271518
6727

skipif mysql # not compatible
query I rowsort label-8051
SELECT DISTINCT col0 * col1 * - CAST ( - col1 AS INTEGER ) AS col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT + + 43 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + tab1.col2 * tab1.col2 ) col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - - 62 + + col0 * + ( + cor0.col0 * cor0.col2 ) AS col1 FROM tab0 AS cor0
----
1287
19070
649584

query I rowsort
SELECT DISTINCT - ( + col0 ) * + 11 AS col2 FROM tab0
----
-264
-385
-979

query I rowsort
SELECT - 59 + col1 FROM tab0 cor0
----
27
32
38

query I rowsort
SELECT ALL + - cor0.col2 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort
SELECT + col0 * - CAST ( + 89 AS REAL ) FROM tab1 cor0
----
-267
-5696
-7120

query I rowsort
SELECT DISTINCT - 72 FROM tab1, tab2, tab1 AS cor0
----
-72

query I rowsort
SELECT col0 + ( 5 ) AS col2 FROM tab0 AS cor0
----
29
40
94

query I rowsort
SELECT DISTINCT - ( + col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col0 + + col0 * col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT - col1 + col1 * col0 AS col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL - 61 * - ( - col2 ) AS col2 FROM tab2 cor0
----
-1586
-1647
-2318

query I rowsort
SELECT col0 + - 74 FROM tab0 AS cor0
----
-39
-50
15

query I rowsort
SELECT DISTINCT - + 4 + - col2 + - col1 FROM tab2 AS cor0
----
-59
-62
-89

query I rowsort
SELECT - ( - 15 ) FROM tab2 AS cor0
----
15
15
15

query I rowsort
SELECT ALL + 15 * col2 FROM tab2 AS cor0
----
390
405
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8069
SELECT col0 + CAST( - col0 AS SIGNED ) + col0 * col0 AS col2 FROM tab1
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-8069
SELECT col0 + CAST ( - col0 AS INTEGER ) + col0 * col0 AS col2 FROM tab1
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col0 + col1 col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 1 * ( - col2 ) + + col0 + + col1 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT ALL col2 * ( 26 ) + col0 AS col2 FROM tab1
----
1407
1546
2576

query I rowsort
SELECT - - col2 + + col2 * col1 + + ( + col1 ) AS col1 FROM tab1 AS cor0
----
1357
1484
637

query I rowsort
SELECT ALL - - col2 * + col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT + + 81 + + col1 FROM tab2 AS cor0
----
112
140
98

query I rowsort
SELECT DISTINCT + tab0.col0 * - 87 AS col2 FROM tab0
----
-2088
-3045
-7743

query I rowsort
SELECT ALL - - col2 + col2 * col1 AS col2 FROM tab0 cor0
----
2871
7544
98

query I rowsort
SELECT + + 49 * + col0 FROM tab1 AS cor0
----
147
3136
3920

query I rowsort
SELECT + 36 * cor0.col0 + 50 FROM tab1 AS cor0
----
158
2354
2930

query I rowsort
SELECT ALL - ( + 65 + tab1.col1 ) AS col0 FROM tab1
----
-75
-78
-91

query I rowsort
SELECT 16 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT + 75 + cor0.col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1369
-601
-654

query I rowsort
SELECT + col0 * + tab0.col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL 32 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT DISTINCT - col2 * col1 + + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL + col0 * 51 - col2 FROM tab0 AS cor0
----
1191
1784
4457

query I rowsort
SELECT DISTINCT - cor0.col0 + + col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + cor0.col2 + 88 + - col1 AS col0 FROM tab0 AS cor0
----
-8
35
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8089
SELECT DISTINCT + 90 DIV + cor0.col1 FROM tab1, tab2 AS cor0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-8089
SELECT DISTINCT + 90 / + cor0.col1 FROM tab1, tab2 AS cor0
----
1
2
5

query I rowsort
SELECT - col1 * col2 - col0 AS col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT + 72 - cor0.col1 * - col1 FROM tab0 AS cor0
----
7468
8353
9481

query I rowsort
SELECT + cor0.col2 + 64 FROM tab1 AS cor0
----
118
121
160

onlyif mysql # use DIV operator for integer division
query I rowsort label-8093
SELECT + col0 DIV - col0 - 48 * + col2 AS col1 FROM tab2 AS cor0
----
-1249
-1297
-1825

skipif mysql # not compatible
query I rowsort label-8093
SELECT + col0 / - col0 - 48 * + col2 AS col1 FROM tab2 AS cor0
----
-1249
-1297
-1825

query I rowsort
SELECT - cor0.col2 - + col2 * - col0 * + col2 AS col1 FROM tab0 AS cor0
----
26103
34
598354

query I rowsort
SELECT ALL col1 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * ( 18 ) + + cor0.col0 col1 FROM tab1 AS cor0
----
-1088
-1360
-51

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 713ff9f9cde43214a064a8e6ada00f4e

onlyif mysql # use DIV operator for integer division
query I rowsort label-8098
SELECT col2 + + tab1.col2 DIV - col2 + tab1.col2 col2 FROM tab1
----
107
113
191

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8098
SELECT col2 + + tab1.col2 / - col2 + tab1.col2 col2 FROM tab1
----
107
113
191

query I rowsort
SELECT ALL + col1 + tab2.col2 + + col2 AS col1 FROM tab2
----
111
85
93

query I rowsort
SELECT + col0 * 49 FROM tab0 AS cor0
----
1176
1715
4361

query I rowsort
SELECT ALL col0 + ( 25 ) AS col1 FROM tab2 AS cor0
----
103
104
32

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - col0 + CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8103
SELECT DISTINCT + + col2 / + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8103
SELECT DISTINCT + + col2 / + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col2 * - 40 AS col1 FROM tab0 AS cor0
----
-1320
-3280
-40

query I rowsort
SELECT - - cor0.col1 * + cor0.col0 + col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 - col2 * + col0 col2 FROM tab0 AS cor0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 + - col2 col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 * col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT - cor0.col2 + - col1 * - col1 AS col2 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT - - col2 * + ( 59 ) FROM tab2 AS cor0
----
1534
1593
2242

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8111
SELECT col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8111
SELECT col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * 18 + col2 + + cor0.col2 * - 36 FROM tab1 cor0
----
-1632
-918
-969

query I rowsort
SELECT DISTINCT + + cor0.col0 + + col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL - + 84 + 80 FROM tab0 AS cor0
----
-4
-4
-4

query I rowsort
SELECT DISTINCT + ( 67 ) AS col0 FROM tab0, tab0 AS cor0
----
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8116
SELECT ALL - - CAST( + col0 AS SIGNED ) FROM tab2 cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-8116
SELECT ALL - - CAST ( + col0 AS INTEGER ) FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT 39 * col0 * - cor0.col0 FROM tab0 AS cor0
----
-22464
-308919
-47775

query I rowsort
SELECT DISTINCT 93 FROM tab0 cor0
----
93

query I rowsort
SELECT ALL col0 * col1 * col1 + col0 FROM tab1
----
13600
2031
6464

query I rowsort
SELECT ALL col1 * + col2 + - tab2.col1 FROM tab2
----
1475
629
806

query I rowsort
SELECT DISTINCT + col0 + + col1 * col0 AS col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT - - ( cor0.col1 ) * - col1 + - col0 AS col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT - 59 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 582c5aa5e5b4fc3f2ea27e7637992d1f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 37 col2 FROM tab1 cor0
----
-37
-37
-37

query I rowsort
SELECT DISTINCT 5 + cor1.col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
12
83
84

query I rowsort
SELECT DISTINCT 13 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-8127
SELECT ALL col0 * col0 - - col1 DIV - col0 AS col0 FROM tab0
----
1223
573
7920

skipif mysql # not compatible
query I rowsort label-8127
SELECT ALL col0 * col0 - - col1 / - col0 AS col0 FROM tab0
----
1223
573
7920

query I rowsort
SELECT DISTINCT - col2 * col0 * - tab0.col1 - + col0 * col1 FROM tab0
----
0
656019
66048

query I rowsort
SELECT col0 * col0 FROM tab1 WHERE NOT NULL <= NULL
----

query I rowsort
SELECT ALL col1 * - cor0.col1 * + 79 AS col2 FROM tab2 cor0
----
-22831
-274999
-75919

query I rowsort
SELECT ALL col1 * col1 + ( - col0 ) - + col1 AS col0 FROM tab1
----
26
647
76

query I rowsort
SELECT 89 * - cor0.col2 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to f659d08d49d6408ed46c55eb31230176

query I rowsort
SELECT + + tab2.col2 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - - col2 col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT col0 + + col2 * ( - 15 ) * col0 + col1 FROM tab1
----
-115107
-2401
-54646

query I rowsort
SELECT ALL 31 - tab2.col1 AS col1 FROM tab2
----
-28
0
14

query I rowsort
SELECT DISTINCT - col2 - 53 * - col0 AS col2 FROM tab2 cor0
----
344
4108
4149

query I rowsort
SELECT + col0 * 72 FROM tab1 AS cor0
----
216
4608
5760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8139
SELECT ALL - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8139
SELECT ALL - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + 9 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9

query I rowsort
SELECT DISTINCT + 78 FROM tab1, tab1 AS cor0
----
78

query I rowsort
SELECT + 38 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8143
SELECT col2 DIV + tab1.col2 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8143
SELECT col2 / + tab1.col2 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT - - cor0.col2 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL + col2 + 44 FROM tab2 AS cor0
----
70
71
82

query I rowsort
SELECT ALL - col1 * - col1 + - 24 AS col0 FROM tab1 AS cor0
----
145
652
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-8147
SELECT - + cor0.col2 - + ( - col1 ) DIV cor0.col0 FROM tab0 AS cor0
----
-30
-81
1

skipif mysql # not compatible
query I rowsort label-8147
SELECT - + cor0.col2 - + ( - col1 ) / cor0.col0 FROM tab0 AS cor0
----
-30
-81
1

query I rowsort
SELECT ALL col0 + col1 * col1 AS col2 FROM tab1 AS cor0
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-8149
SELECT ALL + col2 DIV - ( 17 * - col0 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8149
SELECT ALL + col2 / - ( 17 * - col0 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 * 33 + ( col0 ) AS col1 FROM tab2 AS cor0
----
238
2652
2686

query I rowsort
SELECT DISTINCT - 71 AS col1 FROM tab2
----
-71

query I rowsort
SELECT 5 * col0 FROM tab0
----
120
175
445

query I rowsort
SELECT ALL ( - 47 + col0 ) AS col1 FROM tab2
----
-40
31
32

query I rowsort
SELECT ALL ( col2 ) * + tab0.col2 * col2 AS col0 FROM tab0
----
1
35937
551368

query I rowsort
SELECT - 43 AS col0 FROM tab0 AS cor0
----
-43
-43
-43

query I rowsort
SELECT - col1 * col2 + col2 AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + 75 * cor0.col2 FROM tab0 AS cor0
----
2475
6150
75

query I rowsort
SELECT + col1 + + col1 * + 17 AS col0 FROM tab0 AS cor0
----
1548
1638
1746

query I rowsort
SELECT ALL - - col2 * col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT 35 + - col1 FROM tab1 AS cor0
----
22
25
9

query I rowsort
SELECT ALL 77 + + col2 * col2 FROM tab0 AS cor0
----
1166
6801
78

query I rowsort
SELECT 98 + tab0.col1 FROM tab0
----
184
189
195

query I rowsort
SELECT DISTINCT + - 9 + - col2 AS col1 FROM tab1 AS cor0
----
-105
-63
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8164
SELECT ALL - ( + col2 ) * + CAST( ( + col2 ) AS SIGNED ) FROM tab0 cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-8164
SELECT ALL - ( + col2 ) * + CAST ( ( + col2 ) AS INTEGER ) FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL + + col0 * - col2 * + 69 FROM tab2 AS cor0
----
-13041
-139932
-207138

query I rowsort
SELECT DISTINCT - col0 * - col0 + - col1 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT ALL 75 * - cor0.col1 + + 38 FROM tab0 AS cor0
----
-6412
-6787
-7237

onlyif mysql # use DIV operator for integer division
query I rowsort label-8168
SELECT DISTINCT + 90 + + cor0.col1 DIV 18 FROM tab1 AS cor0
----
90
91

skipif mysql # not compatible
query I rowsort label-8168
SELECT DISTINCT + 90 + + cor0.col1 / 18 FROM tab1 AS cor0
----
90
91

query I rowsort
SELECT - + col1 * col0 + ( cor0.col1 ) * - col0 FROM tab0 AS cor0
----
-16198
-4128
-6790

query I rowsort
SELECT ALL - col0 - col2 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + - 66 AS col2 FROM tab1 AS cor0
----
-66

query I rowsort
SELECT col1 + 98 FROM tab1
----
108
111
124

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 63 col2 FROM tab0
----
145
64
96

query I rowsort
SELECT - col1 + + 90 FROM tab2 AS cor0
----
31
59
73

query I rowsort
SELECT col1 * cor0.col2 + + col2 FROM tab0 cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8176
SELECT + col2 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8176
SELECT + col2 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8177
SELECT DISTINCT + cor1.col1 DIV cor1.col0 + 30 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
30
34

skipif mysql # not compatible
query I rowsort label-8177
SELECT DISTINCT + cor1.col1 / cor1.col0 + 30 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
30
34

query I rowsort
SELECT ALL cor0.col2 * + col1 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 9 * + 93 + col2 * + 22 col1 FROM tab2 AS cor0
----
1409
1431
1673

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8180
SELECT CAST( col2 AS SIGNED ) AS col2 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-8180
SELECT CAST ( col2 AS INTEGER ) AS col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL + cor0.col2 + cor0.col1 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT + + 44 AS col1 FROM tab1 AS cor0
----
44

query I rowsort
SELECT DISTINCT col2 + + col0 * ( - tab2.col1 ) FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT - col2 + 43 FROM tab2
----
16
17
5

query I rowsort
SELECT + ( + cor0.col1 ) FROM tab1 cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 21 + + 90 col0 FROM tab1 cor0
----
69
69
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + cor0.col2 col0 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-8188
SELECT - ( col2 ) DIV col0 - 58 FROM tab2 cor0
----
-58
-58
-61

skipif mysql # not compatible
query I rowsort label-8188
SELECT - ( col2 ) / col0 - 58 FROM tab2 cor0
----
-58
-58
-61

query I rowsort
SELECT DISTINCT + 40 FROM tab2 AS cor0
----
40

query I rowsort
SELECT - - ( - col1 ) * ( col0 ) AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL + 50 + tab0.col1 FROM tab0
----
136
141
147

query I rowsort
SELECT DISTINCT + - ( - col1 ) + 74 - - col2 * - cor0.col1 FROM tab1 cor0
----
-1161
-1304
-486

query I rowsort
SELECT ALL + 61 * col0 AS col2 FROM tab1 AS cor0
----
183
3904
4880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 72 * + col2 col1 FROM tab1 AS cor0
----
3888
4104
6912

query I rowsort
SELECT + col2 + + col0 * - 64 FROM tab1 AS cor0
----
-138
-4039
-5024

query I rowsort
SELECT 16 * cor0.col0 AS col2 FROM tab1 AS cor0
----
1024
1280
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 43 col0 FROM tab2 cor0
----
43
43
43

query I rowsort
SELECT DISTINCT col1 + cor0.col1 * col1 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-8199
SELECT DISTINCT - col1 DIV + col1 col2 FROM tab1 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8199
SELECT DISTINCT - col1 / + col1 col2 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT - - 10 * - col1 FROM tab2 AS cor0
----
-170
-310
-590

onlyif mysql # use DIV operator for integer division
query I rowsort label-8201
SELECT - col0 * col0 DIV + col0 + col0 * col0 FROM tab2 AS cor0
----
42
6006
6162

skipif mysql # not compatible
query I rowsort label-8201
SELECT - col0 * col0 / + col0 + col0 * col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT + col1 * - 75 FROM tab2 AS cor0
----
-1275
-2325
-4425

onlyif mysql # use DIV operator for integer division
query I rowsort label-8203
SELECT col2 * 16 DIV - col1 - - cor0.col2 AS col0 FROM tab0 AS cor0
----
1
27
68

skipif mysql # not compatible
query I rowsort label-8203
SELECT col2 * 16 / - col1 - - cor0.col2 AS col0 FROM tab0 AS cor0
----
1
27
68

query I rowsort
SELECT ALL col1 + - tab1.col1 * tab1.col0 AS col1 FROM tab1
----
-1027
-52
-630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8205
SELECT + col1 * + CAST( cor0.col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-8205
SELECT + col1 * + CAST ( cor0.col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + col0 * 91 - + cor0.col1 * - col1 AS col1 FROM tab0 AS cor0
----
12594
16380
9580

query I rowsort
SELECT - cor0.col2 * - col2 + - col1 FROM tab1 AS cor0
----
2890
3239
9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - 84 col2 FROM tab1 AS cor0
----
-20
-4
-81

query I rowsort
SELECT col1 * + cor0.col1 * + col2 FROM tab2 AS cor0
----
10982
25947
90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-8210
SELECT DISTINCT col2 + + tab1.col1 * col2 DIV 90 + + col0 AS col1 FROM tab1
----
127
189
72

skipif mysql # not compatible
query I rowsort label-8210
SELECT DISTINCT col2 + + tab1.col1 * col2 / 90 + + col0 AS col1 FROM tab1
----
127
189
72

query I rowsort
SELECT col2 + 73 AS col1 FROM tab0 AS cor0
----
106
155
74

query I rowsort
SELECT + col0 * - col2 + col2 * col0 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8213
SELECT - col2 * col0 DIV - col2 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8213
SELECT - col2 * col0 / - col2 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT col1 * 99 AS col0 FROM tab2
----
1683
3069
5841

query I rowsort
SELECT DISTINCT - + col2 * - 23 + - col0 FROM tab2 cor0
----
520
614
795

query I rowsort
SELECT DISTINCT col0 * 2 AS col2 FROM tab1 AS cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + ( - col2 ) col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT + cor0.col2 * col1 * 66 FROM tab0 AS cor0
----
187308
492492
6402

query I rowsort
SELECT ALL tab1.col2 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL - tab0.col1 + ( - 26 ) FROM tab0, tab1 AS cor0
----
9 values hashing to cdaf72e9a61731c60dece1ae3997bfd3

query I rowsort
SELECT 65 AS col1 FROM tab2
----
65
65
65

query I rowsort
SELECT DISTINCT - col2 - col0 * col1 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT - - 67 * + 15 * - col0 AS col0 FROM tab2 AS cor0
----
-7035
-78390
-79395

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8224
SELECT DISTINCT - CAST( - col2 AS SIGNED ) * col0 col1 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8224
SELECT DISTINCT - CAST ( - col2 AS INTEGER ) * col0 col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col1 * 92 FROM tab2 AS cor0
----
1564
2852
5428

query I rowsort
SELECT - + col1 * 21 + col2 * col2 FROM tab0 AS cor0
----
-2036
-717
4813

query I rowsort
SELECT + ( - 45 ) FROM tab2 cor0
----
-45
-45
-45

query I rowsort
SELECT ALL + + col2 + - col2 * col2 AS col0 FROM tab0 cor0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT + col2 + col2 * 46 FROM tab0 AS cor0
----
1551
3854
47

query I rowsort
SELECT ALL - + col0 * col2 + col0 AS col1 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL - + col1 * + col1 * 0 + col1 - col2 * 64 AS col1 FROM tab0 AS cor0
----
-2026
-5157
33

query I rowsort
SELECT cor0.col2 + col2 AS col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT + 76 + + col2 + - 37 FROM tab1 AS cor0
----
135
93
96

query I rowsort
SELECT + 10 * + ( + col2 ) AS col1 FROM tab0
----
10
330
820

query I rowsort
SELECT - + col1 + col0 * col2 AS col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + + cor0.col2 * 50 * ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
32300
41850
76700

query I rowsort
SELECT - col0 * - 82 AS col2 FROM tab1 AS cor0
----
246
5248
6560

query I rowsort
SELECT ALL - col1 * col2 * - col0 AS col0 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-8239
SELECT ALL col0 DIV + 19 FROM tab1
----
0
3
4

skipif mysql # not compatible
query I rowsort label-8239
SELECT ALL col0 / + 19 FROM tab1
----
0
3
4

query I rowsort
SELECT DISTINCT - cor0.col2 AS col1 FROM tab0, tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + + col0 * - 43 FROM tab2 AS cor0
----
-301
-3354
-3397

onlyif mysql # use DIV operator for integer division
query I rowsort label-8242
SELECT ALL - - col0 DIV ( ( col0 ) ) FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8242
SELECT ALL - - col0 / ( ( col0 ) ) FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + - cor0.col2 + col1 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + cor1.col0 * - 56 FROM tab0, tab2 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to f1b7ee50beba08f817960ab4d15acecf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 42 col2 FROM tab0, tab2 AS cor0
----
42

query I rowsort
SELECT ALL + - col2 * col0 - col1 * + col0 AS col0 FROM tab2 AS cor0
----
-406
-4345
-6630

onlyif mysql # use DIV operator for integer division
query I rowsort label-8247
SELECT DISTINCT + col0 * 97 + col2 DIV col1 AS col1 FROM tab2 AS cor0
----
679
7566
7665

skipif mysql # not compatible
query I rowsort label-8247
SELECT DISTINCT + col0 * 97 + col2 / col1 AS col1 FROM tab2 AS cor0
----
679
7566
7665

query I rowsort
SELECT DISTINCT - - 12 * - ( + col0 ) * col2 - cor0.col2 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-2457
-26364
-39026

query I rowsort
SELECT DISTINCT 51 + - 49 * + col2 FROM tab1 AS cor0
----
-2595
-2742
-4653

query I rowsort
SELECT + 46 AS col1 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT DISTINCT col0 * col0 * col1 AS col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT 76 * + col1 FROM tab1 cor0
----
1976
760
988

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8253
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8253
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - 80 AS col2 FROM tab1 AS cor0
----
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8255
SELECT - CAST( NULL AS SIGNED ) * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8255
SELECT - CAST ( NULL AS INTEGER ) * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 92 * col0 + + col1 AS col2 FROM tab1 AS cor0
----
-250
-5878
-7347

query I rowsort
SELECT - col2 + - 12 FROM tab0 AS cor0
----
-13
-45
-94

query I rowsort
SELECT ALL - 10 * - 76 FROM tab1 AS cor0
----
760
760
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-8259
SELECT tab0.col1 DIV - 61 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8259
SELECT tab0.col1 / - 61 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8260
SELECT - col1 / + ( col2 * col1 ) - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8260
SELECT - col1 / + ( col2 * col1 ) - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ( 9 ) AS col0 FROM tab1
----
9
9
9

query I rowsort
SELECT ALL 69 * - col1 FROM tab2
----
-1173
-2139
-4071

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8263
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0, tab1 cor1, tab0 AS cor2
----
NULL

skipif mysql # not compatible
query I rowsort label-8263
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab1 cor1, tab0 AS cor2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 75 ) col1 FROM tab0
----
75

query I rowsort
SELECT ALL + + ( + 14 ) AS col0 FROM tab1 AS cor0
----
14
14
14

query I rowsort
SELECT DISTINCT + + 93 * col2 AS col0 FROM tab0 AS cor0
----
3069
7626
93

query I rowsort
SELECT ALL ( ( cor0.col1 ) ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT tab1.col1 + col2 * + col0 * - 77 AS col0 FROM tab1
----
-12448
-280886
-591347

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - tab1.col0 col1 FROM tab1
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8270
SELECT ALL CAST( 64 AS SIGNED ) * col0 AS col2 FROM tab2
----
448
4992
5056

skipif mysql # not compatible
query I rowsort label-8270
SELECT ALL CAST ( 64 AS INTEGER ) * col0 AS col2 FROM tab2
----
448
4992
5056

query I rowsort
SELECT + col0 * - col2 - 52 * - col0 FROM tab0
----
-2670
1785
456

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8272
SELECT DISTINCT + col2 * CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8272
SELECT DISTINCT + col2 * CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL - col1 - + cor0.col1 * + col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT tab0.col1 AS col1 FROM tab0, tab2, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT cor0.col1 + - col2 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT col2 - + tab1.col2 * - col2 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT cor0.col1 + 8 + + 18 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to cf43be67527c2c5e29246b03f33acc82

query I rowsort
SELECT - 64 * col0 + ( col2 ) + col1 AS col2 FROM tab0
----
-1417
-2142
-5523

query I rowsort
SELECT col1 + - col1 * col1 * col1 FROM tab2
----
-205320
-29760
-4896

onlyif mysql # use DIV operator for integer division
query I rowsort label-8280
SELECT col1 DIV + 78 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8280
SELECT col1 / + 78 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 + - 97 FROM tab1 AS cor0
----
-1
-40
-43

query I rowsort
SELECT ALL - col2 * 46 FROM tab1 AS cor0
----
-2484
-2622
-4416

query I rowsort
SELECT + col2 + + 23 FROM tab0 AS cor0
----
105
24
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col2 col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8285
SELECT - + cor0.col1 * col0 + 55 DIV col2 AS col1 FROM tab0 AS cor0
----
-2063
-3340
-8099

skipif mysql # not compatible
query I rowsort label-8285
SELECT - + cor0.col1 * col0 + 55 / col2 AS col1 FROM tab0 AS cor0
----
-2063
-3340
-8099

query I rowsort
SELECT - + col0 * - 68 + col1 FROM tab1 cor0
----
230
4362
5453

query I rowsort
SELECT + cor0.col0 + 61 AS col0 FROM tab1 cor0
----
125
141
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + cor0.col1 * - col0 col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL + col1 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col0 + - 21 * col2 * col0 AS col1 FROM tab0 AS cor0
----
-153169
-16608
-700

query I rowsort
SELECT col2 * ( col0 ) + col0 AS col0 FROM tab1 cor0
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 * col0 col0 FROM tab0 AS cor0
----
1824
2660
6764

query I rowsort
SELECT + cor0.col1 * col1 - - col1 AS col2 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8294
SELECT ( + col1 ) + - CAST( col2 + + col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-111
-163
-31

skipif mysql # not compatible
query I rowsort label-8294
SELECT ( + col1 ) + - CAST ( col2 + + col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-111
-163
-31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8295
SELECT 86 * - col1 - - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8295
SELECT 86 * - col1 - - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 1 + + tab0.col0 AS col2 FROM tab0, tab1 AS cor0
----
25
36
90

query I rowsort
SELECT ALL 1 + ( + col0 ) FROM tab1
----
4
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-8298
SELECT ALL + 32 * col1 DIV + 78 FROM tab2
----
12
24
6

skipif mysql # not compatible
query I rowsort label-8298
SELECT ALL + 32 * col1 / + 78 FROM tab2
----
12
24
6

query I rowsort
SELECT - - col1 - - col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-8300
SELECT DISTINCT - - col2 DIV col1 AS col0 FROM tab2 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-8300
SELECT DISTINCT - - col2 / col1 AS col0 FROM tab2 AS cor0
----
0
2

query I rowsort
SELECT DISTINCT - col2 - - cor0.col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - + col1 * 19 AS col2 FROM tab2 AS cor0
----
-1121
-323
-589

query I rowsort
SELECT - - col0 + + ( cor0.col2 ) FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + col2 + + ( 16 ) * - col0 * col0 FROM tab0 AS cor0
----
-126654
-19599
-9183

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( cor0.col0 ) * - cor0.col2 * ( - col2 ) col2 FROM tab0 cor0
----
-26136
-35
-598436

query I rowsort
SELECT ALL + 82 + - col1 FROM tab2 cor0
----
23
51
65

query I rowsort
SELECT ALL - 71 FROM tab0 cor0
----
-71
-71
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 0 col1 FROM tab2, tab0 AS cor0, tab0, tab0 cor1
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

query I rowsort
SELECT + - ( cor0.col2 ) + - col1 AS col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT - ( + 96 ) * - cor0.col1 FROM tab0, tab1, tab0 AS cor0
----
8256
8736
9312

query I rowsort
SELECT DISTINCT 72 * col2 AS col0 FROM tab0
----
2376
5904
72

query I rowsort
SELECT DISTINCT - ( + col2 * col1 ) AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT + col0 + 1 AS col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT col0 * + col1 + - col1 AS col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT + ( - col2 ) * col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL cor0.col0 + col0 * col1 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - ( 39 ) AS col2 FROM tab1
----
-39
-39
-39

query I rowsort
SELECT DISTINCT - 86 AS col2 FROM tab2
----
-86

query I rowsort
SELECT ALL + + 96 AS col1 FROM tab1 AS cor0
----
96
96
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * + col1 col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - 73 + col2 AS col0 FROM tab0 AS cor0
----
-40
-72
9

query I rowsort
SELECT ALL + 98 + col0 * col1 FROM tab1 AS cor0
----
1138
176
738

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8323
SELECT - col0 + - CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8323
SELECT - col0 + - CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + cor0.col1 * cor0.col1 AS col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT col2 + col1 + 21 FROM tab0 AS cor0
----
119
140
194

query I rowsort
SELECT - tab0.col0 + col0 + ( 52 ) FROM tab0
----
52
52
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8327
SELECT - col2 + + CAST( NULL AS SIGNED ) col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8327
SELECT - col2 + + CAST ( NULL AS INTEGER ) col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 * col0 + 86 + - col1 AS col1 FROM tab2 AS cor0
----
-1274
-162
-4575

query I rowsort
SELECT cor0.col0 + 73 * + 47 AS col0 FROM tab0 cor0
----
3455
3466
3520

query I rowsort
SELECT ALL + col1 + 8 AS col0 FROM tab2 AS cor0
----
25
39
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-8331
SELECT ALL 94 DIV 84 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-8331
SELECT ALL 94 / 84 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT DISTINCT - cor0.col0 * - col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + + cor0.col0 * col2 + col1 + col2 FROM tab0 cor0
----
133
7471
911

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col2 col2 FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - ( col2 ) col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-8336
SELECT ALL - col2 + - col0 DIV - cor0.col2 FROM tab0 AS cor0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-8336
SELECT ALL - col2 + - col0 / - cor0.col2 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT ALL + col0 * - col1 + - col0 * - cor0.col2 FROM tab2 AS cor0
----
-2574
-28
1659

query I rowsort
SELECT DISTINCT - 18 * col0 * tab0.col1 AS col1 FROM tab0
----
-145782
-37152
-61110

query I rowsort
SELECT + col1 - + col1 * + col0 * - 56 FROM tab0
----
115670
190217
453635

onlyif mysql # use DIV operator for integer division
query I rowsort label-8340
SELECT + col2 DIV col1 + + tab2.col1 FROM tab2
----
19
31
59

skipif mysql # not compatible
query I rowsort label-8340
SELECT + col2 / col1 + + tab2.col1 FROM tab2
----
19
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8341
SELECT + + col1 DIV col0 AS col1 FROM tab1 cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-8341
SELECT + + col1 / col0 AS col1 FROM tab1 cor0
----
0
0
8

query I rowsort
SELECT DISTINCT + cor0.col0 * + col1 + 62 AS col2 FROM tab0 AS cor0
----
2126
3457
8161

query I rowsort
SELECT DISTINCT cor0.col0 * col2 + col2 + - col0 FROM tab2 cor0
----
1976
209
2961

query I rowsort
SELECT ALL - - col2 * 95 AS col2 FROM tab0 AS cor0
----
3135
7790
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 92 + + ( col2 * 17 ) col0 FROM tab0
----
109
1486
653

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 81 col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
27 values hashing to d0bfe8494f52235d9fcafb5ac5de3f81

query I rowsort
SELECT + 92 + 47 FROM tab2 AS cor0
----
139
139
139

query I rowsort
SELECT 34 * col0 FROM tab0 AS cor0
----
1190
3026
816

query I rowsort
SELECT col2 * - col2 + + col2 AS col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 81 * col1 col1 FROM tab1 AS cor0
----
-1053
-2106
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-8351
SELECT 61 DIV col0 FROM tab1 AS cor0
----
0
0
20

skipif mysql # not compatible
query I rowsort label-8351
SELECT 61 / col0 FROM tab1 AS cor0
----
0
0
20

query I rowsort
SELECT DISTINCT + + 64 + - col0 + + cor0.col0 FROM tab1 cor0
----
64

query I rowsort
SELECT + + 21 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-17
-5
-6

query I rowsort
SELECT + 71 * col1 FROM tab0
----
6106
6461
6887

query I rowsort
SELECT DISTINCT + - 81 + + col0 + + ( col0 * + col2 ) AS col2 FROM tab1 AS cor0
----
3631
7679
84

query I rowsort
SELECT - ( - cor0.col2 ) + - 33 AS col0 FROM tab0 AS cor0
----
-32
0
49

query I rowsort
SELECT ALL - + 33 + 72 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT ALL + - col0 - + col0 * 86 * + col1 AS col2 FROM tab1 cor0
----
-55104
-6711
-89520

query I rowsort
SELECT ALL - cor0.col2 * - col1 * - col1 AS col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 * - col0 col0 FROM tab0 cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-8361
SELECT DISTINCT + ( col2 ) DIV + col1 AS col1 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-8361
SELECT DISTINCT + ( col2 ) / + col1 AS col1 FROM tab1 cor0
----
2
5
7

query I rowsort
SELECT cor0.col0 + - col0 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8363
SELECT ALL - col1 DIV col1 - - 45 AS col0 FROM tab0 AS cor0
----
44
44
44

skipif mysql # not compatible
query I rowsort label-8363
SELECT ALL - col1 / col1 - - 45 AS col0 FROM tab0 AS cor0
----
44
44
44

query I rowsort
SELECT ALL - + col0 + + col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col1 * col1 - 13 * + col0 AS col2 FROM tab1 AS cor0
----
-732
-871
637

onlyif mysql # use DIV operator for integer division
query I rowsort label-8366
SELECT 38 + col0 DIV + col0 FROM tab0 AS cor0
----
39
39
39

skipif mysql # not compatible
query I rowsort label-8366
SELECT 38 + col0 / + col0 FROM tab0 AS cor0
----
39
39
39

query I rowsort
SELECT DISTINCT + 46 * col0 FROM tab2 cor0
----
322
3588
3634

query I rowsort
SELECT DISTINCT col0 + col1 * 83 FROM tab1 AS cor0
----
1159
2161
894

onlyif mysql # use DIV operator for integer division
query I rowsort label-8369
SELECT ALL + - cor0.col1 + col2 - - 47 DIV col2 AS col2 FROM tab0 AS cor0
----
-49
-52
-9

skipif mysql # not compatible
query I rowsort label-8369
SELECT ALL + - cor0.col1 + col2 - - 47 / col2 AS col2 FROM tab0 AS cor0
----
-49
-52
-9

query I rowsort
SELECT ALL cor0.col0 + col0 AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL + cor0.col1 + 55 FROM tab1 AS cor0
----
65
68
81

query I rowsort
SELECT - - col1 * + col1 AS col2 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT + + col1 * - col0 - cor0.col1 * col0 FROM tab0 cor0
----
-16198
-4128
-6790

onlyif mysql # use DIV operator for integer division
query I rowsort label-8374
SELECT DISTINCT + ( + col2 ) - col2 DIV 35 AS col1 FROM tab1 AS cor0
----
53
56
94

skipif mysql # not compatible
query I rowsort label-8374
SELECT DISTINCT + ( + col2 ) - col2 / 35 AS col1 FROM tab1 AS cor0
----
53
56
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 12 * + cor0.col2 col0 FROM tab0 AS cor0
----
1075
109
482

query I rowsort
SELECT DISTINCT + col2 + + ( cor0.col1 ) * col2 AS col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + 29 + ( col2 ) * + col0 FROM tab2 AS cor0
----
2057
218
3031

query I rowsort
SELECT - - 25 * - 86 + + cor0.col2 * ( ( + col2 ) ) FROM tab0 AS cor0
----
-1061
-2149
4574

query I rowsort
SELECT DISTINCT + col0 * - col2 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-8380
SELECT - cor0.col0 DIV - cor0.col2 FROM tab0, tab0 cor0
----
9 values hashing to 41f0a3543969085f79919f2dde47982a

skipif mysql # not compatible
query I rowsort label-8380
SELECT - cor0.col0 / - cor0.col2 FROM tab0, tab0 cor0
----
9 values hashing to 41f0a3543969085f79919f2dde47982a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8381
SELECT DISTINCT col0 - + CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-8381
SELECT DISTINCT col0 - + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT - 41 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 007857b49fbf51962923f3da53f42f2b

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 WHERE NULL <= NULL
----

query I rowsort
SELECT DISTINCT col0 + + 98 * - col1 FROM tab0
----
-8404
-8829
-9471

onlyif mysql # use DIV operator for integer division
query I rowsort label-8385
SELECT - col2 * + col0 + col2 DIV ( 46 ) FROM tab0
----
-35
-7297
-792

skipif mysql # not compatible
query I rowsort label-8385
SELECT - col2 * + col0 + col2 / ( 46 ) FROM tab0
----
-35
-7297
-792

query I rowsort
SELECT + col2 + tab2.col1 * + col1 + + col1 AS col0 FROM tab2
----
1019
344
3566

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 66 + col2 col0 FROM tab1
----
120
123
162

query I rowsort
SELECT 14 * - cor0.col1 + ( - 80 ) * col1 * 62 AS col1 FROM tab0 AS cor0
----
-427764
-452634
-482478

query I rowsort
SELECT - cor0.col2 + cor0.col1 * col0 + col1 FROM tab0 AS cor0
----
2117
3491
8108

query I rowsort
SELECT tab2.col2 * + 27 + col1 AS col1 FROM tab2
----
1043
760
761

query I rowsort
SELECT ALL 55 + col2 AS col0 FROM tab2
----
81
82
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8392
SELECT + + CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1, tab0 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8392
SELECT + + CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1, tab0 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-8393
SELECT - col1 * + col1 * col0 + + col2 DIV col0 + + col1 FROM tab2
----
-22814
-271459
-6693

skipif mysql # not compatible
query I rowsort label-8393
SELECT - col1 * + col1 * col0 + + col2 / col0 + + col1 FROM tab2
----
-22814
-271459
-6693

query I rowsort
SELECT DISTINCT col0 * - col2 + - col0 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT col2 + + 94 + col0 FROM tab0
----
130
151
265

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col2 col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL 63 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT DISTINCT col2 + ( + col0 ) * col1 * 58 + col0 AS col0 FROM tab0
----
119769
196946
469913

query I rowsort
SELECT + cor0.col1 * cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT col0 + col2 * col0 AS col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT - col2 * - col0 + - col2 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
1026
3562
3648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 col1 FROM tab2, tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT + col2 * - col2 + col0 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT col0 * tab2.col2 + col1 + + col1 FROM tab2
----
2146
251
3036

query I rowsort
SELECT ALL col0 + col1 * col0 FROM tab2
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8406
SELECT - col2 DIV - col1 + col0 + col2 FROM tab0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-8406
SELECT - col2 / - col1 + col0 + col2 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT + tab0.col1 + col2 AS col2 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8408
SELECT col2 + + col2 + col0 DIV tab1.col1 AS col2 FROM tab1
----
108
120
198

skipif mysql # not compatible
query I rowsort label-8408
SELECT col2 + + col2 + col0 / tab1.col1 AS col2 FROM tab1
----
108
120
198

query I rowsort
SELECT ALL + tab0.col0 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT tab2.col0 * - col1 AS col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - col1 * - tab2.col0 AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + 79 * col0 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
50560
6162
82160

query I rowsort
SELECT 66 * cor0.col2 AS col0 FROM tab1 cor0
----
3564
3762
6336

onlyif mysql # use DIV operator for integer division
query I rowsort label-8414
SELECT ALL col0 DIV 76 AS col1 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8414
SELECT ALL col0 / 76 AS col1 FROM tab1
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8415
SELECT ALL + CAST( NULL AS DECIMAL ) / + 51 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8415
SELECT ALL + CAST ( NULL AS REAL ) / + 51 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + - 0 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8417
SELECT DISTINCT col1 DIV + tab0.col2 AS col0 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-8417
SELECT DISTINCT col1 / + tab0.col2 AS col0 FROM tab0
----
1
2
97

query I rowsort
SELECT DISTINCT - col2 * col1 + col1 AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT - 86 * - col1 FROM tab0 AS cor0
----
7396
7826
8342

query I rowsort
SELECT ALL 40 + cor0.col1 FROM tab0 AS cor0
----
126
131
137

query I rowsort
SELECT ALL - - col2 * + col0 FROM tab0 cor0
----
35
7298
792

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL < NULL
----

query I rowsort
SELECT + col0 - - col0 * - col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT cor0.col2 + cor0.col1 * col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL col1 FROM tab2 WHERE NOT col2 > ( NULL )
----

query I rowsort
SELECT + col1 * + col1 AS col0 FROM tab0 WHERE ( NULL ) BETWEEN + col0 * - col2 AND ( tab0.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8427
SELECT tab0.col0 DIV col2 col1 FROM tab0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8427
SELECT tab0.col0 / col2 col1 FROM tab0
----
0
1
35

query I rowsort
SELECT ALL col2 * col0 + tab0.col0 AS col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT col1 * + col2 AS col1 FROM tab0 WHERE NULL < NULL
----

query I rowsort
SELECT col1 * + col1 - col1 FROM tab1 WHERE NULL IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8431
SELECT - col0 + col2 DIV col1 AS col2 FROM tab2
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-8431
SELECT - col0 + col2 / col1 AS col2 FROM tab2
----
-7
-77
-78

query I rowsort
SELECT col0 * - col0 AS col0 FROM tab2 WHERE NOT col2 <= ( NULL )
----

query I rowsort
SELECT DISTINCT - col1 AS col2 FROM tab0 WHERE NOT ( col2 + + col0 / - col1 ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT + col2 * + col0 - col1 AS col0 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT - col0 - + cor0.col0 * col1 FROM tab2 cor0
----
-1422
-224
-4680

query I rowsort
SELECT col0 * col1 - - col2 FROM tab1 AS cor0 WHERE NOT ( NULL ) IN ( + col0 * + col1 * + col1 )
----

query I rowsort
SELECT DISTINCT col2 * - cor0.col1 * - col2 AS col2 FROM tab1 AS cor0
----
119808
32490
75816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8438
SELECT DISTINCT - CAST( NULL AS DECIMAL ) * col2 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8438
SELECT DISTINCT - CAST ( NULL AS REAL ) * col2 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + - col0 * ( + col0 ) FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * + col2 col1 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-8441
SELECT ALL - ( + 13 ) * col2 DIV - col0 + + 93 FROM tab1 AS cor0
----
104
108
327

skipif mysql # not compatible
query I rowsort label-8441
SELECT ALL - ( + 13 ) * col2 / - col0 + + 93 FROM tab1 AS cor0
----
104
108
327

query I rowsort
SELECT cor0.col1 + - 47 + + col2 FROM tab1 AS cor0
----
20
33
62

query I rowsort
SELECT ALL - - ( + col0 ) + col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + col2 * 11 AS col0 FROM tab2 AS cor0
----
286
297
418

query I rowsort
SELECT ALL + + ( - 48 ) * - cor0.col1 * col1 + col2 * col2 FROM tab1 AS cor0
----
17328
35364
8049

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + tab0.col2 * CAST ( 55 AS REAL ) AS col2 FROM tab0
----
1815
4510
55

query I rowsort
SELECT DISTINCT tab1.col2 + + col0 + col0 AS col1 FROM tab1
----
185
256
60

query I rowsort
SELECT col2 + - ( + col2 ) AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT col1 * + 54 AS col1 FROM tab1
----
1404
540
702

query I rowsort
SELECT DISTINCT - col0 * - ( + col0 + + 45 ) AS col1 FROM tab2 AS cor0
----
364
9594
9796

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8451
SELECT - CAST( NULL AS DECIMAL ) + + 66 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8451
SELECT - CAST ( NULL AS REAL ) + + 66 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 63 * + 49 FROM tab1 cor0
----
-3087
-3087
-3087

onlyif mysql # use DIV operator for integer division
query I rowsort label-8453
SELECT ALL - + col1 DIV - col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-8453
SELECT ALL - + col1 / - col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT + + 67 * - 44 FROM tab2 AS cor0
----
-2948
-2948
-2948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8455
SELECT CAST( col2 AS SIGNED ) * col2 + - CAST( + col1 AS SIGNED ) FROM tab1
----
2890
3239
9203

skipif mysql # not compatible
query I rowsort label-8455
SELECT CAST ( col2 AS INTEGER ) * col2 + - CAST ( + col1 AS INTEGER ) FROM tab1
----
2890
3239
9203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8456
SELECT cor0.col2 * CAST( - col2 * - cor0.col2 AS SIGNED ) - ( col2 ) * col0 col0 FROM tab2 AS cor0
----
15548
19494
51870

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8456
SELECT cor0.col2 * CAST ( - col2 * - cor0.col2 AS INTEGER ) - ( col2 ) * col0 col0 FROM tab2 AS cor0
----
15548
19494
51870

query I rowsort
SELECT - col1 * - ( col0 ) AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - - col0 - col1 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT col2 * col1 + - 41 AS col0 FROM tab1
----
1207
1363
529

query I rowsort
SELECT ALL + 44 FROM tab2 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT + col2 * - 73 + + 57 FROM tab0
----
-16
-2352
-5929

query I rowsort
SELECT tab2.col1 * - tab2.col2 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT ALL + col2 + col1 + - 89 AS col2 FROM tab0
----
30
84
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8464
SELECT - col1 + + CAST( - col1 AS SIGNED ) DIV - col1 + - 47 * 41 FROM tab0 cor0
----
-2012
-2017
-2023

skipif mysql # not compatible
query I rowsort label-8464
SELECT - col1 + + CAST ( - col1 AS INTEGER ) / - col1 + - 47 * 41 FROM tab0 cor0
----
-2012
-2017
-2023

onlyif mysql # use DIV operator for integer division
query I rowsort label-8465
SELECT + col0 + col1 DIV - col1 - - col0 FROM tab1
----
127
159
5

skipif mysql # not compatible
query I rowsort label-8465
SELECT + col0 + col1 / - col1 - - col0 FROM tab1
----
127
159
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8466
SELECT DISTINCT tab0.col1 + CAST( col2 AS SIGNED ) AS col2 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-8466
SELECT DISTINCT tab0.col1 + CAST ( col2 AS INTEGER ) AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT - col0 * - col2 + col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT + col1 - + 59 AS col1 FROM tab1
----
-33
-46
-49

query I rowsort
SELECT ALL - cor0.col1 + 97 + + col1 * col1 * 7 FROM tab1 AS cor0
----
1267
4803
787

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8470
SELECT + col2 + - 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-8470
SELECT + col2 + - CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8471
SELECT ALL col1 + col0 DIV tab1.col0 AS col2 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-8471
SELECT ALL col1 + col0 / tab1.col0 AS col2 FROM tab1
----
11
14
27

query I rowsort
SELECT DISTINCT col1 + 52 AS col1 FROM tab2
----
111
69
83

query I rowsort
SELECT ALL - 41 * - tab1.col1 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c4ac02dfdd20f5175849c68fd21eab29

query I rowsort
SELECT DISTINCT col1 + + ( 93 ) * - col0 * col0 AS col1 FROM tab0 AS cor0
----
-113828
-53482
-736562

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8475
SELECT DISTINCT - col0 * CAST( NULL AS SIGNED ) - + col1 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8475
SELECT DISTINCT - col0 * CAST ( NULL AS INTEGER ) - + col1 AS col0 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8476
SELECT ALL + col1 DIV 78 + col1 - + col0 AS col1 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-8476
SELECT ALL + col1 / 78 + col1 - + col0 AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - col0 + 45 * + col0 AS col0 FROM tab2 cor0
----
308
3432
3476

query I rowsort
SELECT col2 * - ( col1 ) + + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + col2 + - 70 AS col1 FROM tab1 AS cor0
----
-13
-16
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8480
SELECT DISTINCT ( col1 ) DIV + col1 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-8480
SELECT DISTINCT ( col1 ) / + col1 FROM tab1 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8481
SELECT ALL - - CAST( NULL AS SIGNED ) + - col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8481
SELECT ALL - - CAST ( NULL AS INTEGER ) + - col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 38 FROM tab2, tab0 AS cor0
----
38

query I rowsort
SELECT + ( col0 ) * tab0.col1 AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + ( col0 ) * + col0 + col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + ( - tab1.col0 + + col1 * - col1 ) FROM tab1
----
-164
-249
-679

query I rowsort
SELECT ALL col2 * col0 + col0 AS col2 FROM tab2 AS cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col2 ) + + cor0.col1 col2 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8488
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + col1 * + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8488
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + col1 * + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col2 + 43 FROM tab0 AS cor0
----
125
44
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-8490
SELECT DISTINCT + cor0.col0 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8490
SELECT DISTINCT + cor0.col0 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + + 30 * 93 + col1 AS col1 FROM tab0 AS cor0
----
2876
2881
2887

query I rowsort
SELECT col1 * col2 + + 93 * col1 AS col2 FROM tab2
----
2227
3720
7021

onlyif mysql # use DIV operator for integer division
query I rowsort label-8493
SELECT ALL + col0 + cor0.col1 DIV col1 FROM tab0 cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-8493
SELECT ALL + col0 + cor0.col1 / col1 FROM tab0 cor0
----
25
36
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 77 + col1 * col1 col2 FROM tab2 AS cor0
----
212
3404
884

query I rowsort
SELECT + + 45 FROM tab1 cor0
----
45
45
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8496
SELECT DISTINCT - 35 + col0 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8496
SELECT DISTINCT - 35 + col0 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col0 + col0 + col2 FROM tab2 AS cor0
----
182
196
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 10 col0 FROM tab2
----
-10
-10
-10

query I rowsort
SELECT - ( col0 ) + 51 * ( - col1 * col0 ) AS col2 FROM tab0
----
-105288
-173180
-413138

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 6 col2 FROM tab0 AS cor0
----
-6
-6
-6

query I rowsort
SELECT ALL - 42 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-131
-66
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-8502
SELECT col2 DIV col2 + 90 AS col1 FROM tab1 AS cor0
----
91
91
91

skipif mysql # not compatible
query I rowsort label-8502
SELECT col2 / col2 + 90 AS col1 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT DISTINCT + - col1 + - ( + col2 ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT - col1 * + ( 66 ) + - col2 AS col1 FROM tab0 AS cor0
----
-5709
-6088
-6403

onlyif mysql # use DIV operator for integer division
query I rowsort label-8505
SELECT ALL + col2 + + 99 DIV col2 FROM tab0 AS cor0
----
100
36
83

skipif mysql # not compatible
query I rowsort label-8505
SELECT ALL + col2 + + 99 / col2 FROM tab0 AS cor0
----
100
36
83

query I rowsort
SELECT - col0 - - col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * 7 col0 FROM tab1 AS cor0
----
182
70
91

query I rowsort
SELECT + col2 + ( - col2 ) * col1 FROM tab0 cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8509
SELECT ALL - col2 + - ( col0 ) DIV col1 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8509
SELECT ALL - col2 + - ( col0 ) / col1 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + cor0.col0 + - 41 + - col1 FROM tab0 AS cor0
----
-103
-43

query I rowsort
SELECT 1 + - col2 AS col2 FROM tab2
----
-25
-26
-37

query I rowsort
SELECT DISTINCT + col1 * tab2.col0 * 3 - col2 AS col1 FROM tab2
----
13780
3991
624

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * 37 * 50 col0 FROM tab0, tab2 AS cor0
----
-109150
-31450
-57350

query I rowsort
SELECT - 19 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

query I rowsort
SELECT - + col2 + + col2 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8516
SELECT col1 DIV col1 + col0 * cor0.col1 * + col2 AS col0 FROM tab0 AS cor0
----
3396
664119
68113

skipif mysql # not compatible
query I rowsort label-8516
SELECT col1 / col1 + col0 * cor0.col1 * + col2 AS col0 FROM tab0 AS cor0
----
3396
664119
68113

query I rowsort
SELECT - + col2 * - 62 AS col1 FROM tab1 AS cor0
----
3348
3534
5952

query I rowsort
SELECT DISTINCT - col2 + col2 * col0 FROM tab1 cor0
----
108
3591
7584

query I rowsort
SELECT ALL - - 8 * - col1 AS col0 FROM tab0 AS cor0
----
-688
-728
-776

query I rowsort
SELECT DISTINCT col2 * + 32 FROM tab1
----
1728
1824
3072

query I rowsort
SELECT + cor0.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL + + 7 AS col1 FROM tab1 AS cor0
----
7
7
7

query I rowsort
SELECT - ( 17 ) - col1 FROM tab1 AS cor0
----
-27
-30
-43

query I rowsort
SELECT + 74 * col2 AS col0 FROM tab0 AS cor0
----
2442
6068
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-8525
SELECT + ( cor0.col2 ) DIV col0 + 99 AS col0 FROM tab0 AS cor0
----
100
99
99

skipif mysql # not compatible
query I rowsort label-8525
SELECT + ( cor0.col2 ) / col0 + 99 AS col0 FROM tab0 AS cor0
----
100
99
99

query I rowsort
SELECT ( col2 ) + + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT 16 * - col1 AS col0 FROM tab1 AS cor0
----
-160
-208
-416

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( - col1 + col2 AS REAL ) * col0 AS col2 FROM tab1
----
-3008
-6640
-84

query I rowsort
SELECT - 56 * col2 FROM tab1
----
-3024
-3192
-5376

query I rowsort
SELECT DISTINCT + + col0 * col0 * - col1 - - col2 FROM tab0 AS cor0
----
-118824
-49503
-720729

query I rowsort
SELECT - col1 - - col0 AS col0 FROM tab0 cor0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort
SELECT - - 11 + col0 * CAST ( - col2 AS REAL ) + col2 * 78 * col2 FROM tab0 AS cor0
----
517185
54
84161

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
3645 values hashing to 752ce7d2fdd0678058de6a90ff2b0f3a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 84 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT ALL + 68 FROM tab1
----
68
68
68

query I rowsort
SELECT DISTINCT + col0 + col2 * cor0.col0 * col1 FROM tab1 AS cor0
----
36544
4215
99920

query I rowsort
SELECT 10 * col1 - col0 AS col1 FROM tab0
----
821
836
935

query I rowsort
SELECT - 36 + + col1 AS col2 FROM tab1
----
-10
-23
-26

query I rowsort
SELECT DISTINCT 59 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
59

query I rowsort
SELECT + 53 * + col0 + + ( col0 ) FROM tab2 AS cor0
----
378
4212
4266

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + col0 col1 FROM tab0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8542
SELECT - col2 DIV + tab0.col0 + col0 AS col1 FROM tab0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-8542
SELECT - col2 / + tab0.col0 + col0 AS col1 FROM tab0
----
23
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8543
SELECT DISTINCT - col0 DIV col0 + col0 * col0 * col1 FROM tab0
----
118824
49535
720810

skipif mysql # not compatible
query I rowsort label-8543
SELECT DISTINCT - col0 / col0 + col0 * col0 * col1 FROM tab0
----
118824
49535
720810

query I rowsort
SELECT ALL + tab0.col2 * 73 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to e0fec770aa9cc04ce43c9852e8b1c021

query I rowsort
SELECT DISTINCT cor0.col1 + 21 FROM tab2, tab0, tab2 AS cor0, tab1 AS cor1
----
38
52
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8546
SELECT - - ( - 11 ) - col2 DIV col1 AS col2 FROM tab2 AS cor0
----
-11
-11
-13

skipif mysql # not compatible
query I rowsort label-8546
SELECT - - ( - 11 ) - col2 / col1 AS col2 FROM tab2 AS cor0
----
-11
-11
-13

query I rowsort
SELECT 60 * col2 - + col0 FROM tab0 AS cor0
----
1956
25
4831

query I rowsort
SELECT DISTINCT 2 + col2 FROM tab2 AS cor0
----
28
29
40

query I rowsort
SELECT DISTINCT + 14 + col1 AS col2 FROM tab0 cor0
----
100
105
111

query I rowsort
SELECT - ( 80 ) + - col1 * 9 AS col2 FROM tab2 AS cor0
----
-233
-359
-611

query I rowsort
SELECT + ( + col2 ) * col1 + 42 * col2 AS col0 FROM tab2 cor0
----
1971
2242
2626

query I rowsort
SELECT ALL - 13 * + col0 AS col0 FROM tab0 AS cor0
----
-1157
-312
-455

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8553
SELECT CAST( - 24 AS SIGNED ) FROM tab0
----
-24
-24
-24

skipif mysql # not compatible
query I rowsort label-8553
SELECT CAST ( - 24 AS INTEGER ) FROM tab0
----
-24
-24
-24

query I rowsort
SELECT 31 * - col2 FROM tab2
----
-1178
-806
-837

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 4fe4780e49e612b93957f575d9b3e89f

query I rowsort
SELECT + - 7 * + 94 - - cor0.col2 FROM tab1 AS cor0
----
-562
-601
-604

query I rowsort
SELECT - 76 + col2 * col0 FROM tab1 AS cor0
----
3572
7604
86

query I rowsort
SELECT - - 24 + - col2 + col0 FROM tab2 AS cor0
----
4
65
76

query I rowsort
SELECT tab2.col1 * ( ( + col2 ) ) FROM tab2
----
1534
646
837

query I rowsort
SELECT - col0 * 88 AS col1 FROM tab1
----
-264
-5632
-7040

query I rowsort
SELECT + col2 * cor0.col1 - 32 FROM tab1 AS cor0
----
1216
1372
538

query I rowsort
SELECT DISTINCT + col0 + - col2 - - cor0.col1 FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT ALL + col1 + - 43 FROM tab1 AS cor0
----
-17
-30
-33

onlyif mysql # use DIV operator for integer division
query I rowsort label-8564
SELECT ALL - col0 * col0 + 51 * col2 DIV cor0.col0 FROM tab2 AS cor0
----
-6067
-6217
147

skipif mysql # not compatible
query I rowsort label-8564
SELECT ALL - col0 * col0 + 51 * col2 / cor0.col0 FROM tab2 AS cor0
----
-6067
-6217
147

query I rowsort
SELECT DISTINCT - col0 + col1 - - col2 * col1 FROM tab2 AS cor0
----
1515
584
861

query I rowsort
SELECT ALL + - col1 * 81 + 26 AS col2 FROM tab1 cor0
----
-1027
-2080
-784

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8567
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * + col0 col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8567
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * + col0 col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 * - 7 * + col0 - + cor0.col0 AS col2 FROM tab1 AS cor0
----
-28736
-44880
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 92 col1 FROM tab2 AS cor0
----
-92
-92
-92

query I rowsort
SELECT + - 26 FROM tab1 AS cor0
----
-26
-26
-26

query I rowsort
SELECT ALL + + cor0.col1 + ( cor0.col1 ) * col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + col0 + 45 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1509
3779
80

query I rowsort
SELECT ALL 19 * - col2 + - col0 * - 89 AS col2 FROM tab2 AS cor0
----
110
6309
6448

query I rowsort
SELECT ALL - - cor0.col0 - - col1 AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8575
SELECT DISTINCT + - CAST( NULL AS DECIMAL ) + col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8575
SELECT DISTINCT + - CAST ( NULL AS REAL ) + col2 FROM tab1 cor0
----
NULL

query I rowsort
SELECT col2 * - tab2.col0 + + ( - col0 ) AS col1 FROM tab2
----
-196
-2106
-3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8577
SELECT tab1.col1 * CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8577
SELECT tab1.col1 * CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - 22 * - col1 AS col0 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT DISTINCT - ( - col2 ) + col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL + 74 AS col0 FROM tab2 AS cor0
----
74
74
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col1 col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT col2 * - col1 + + 36 AS col1 FROM tab1 AS cor0
----
-1212
-1368
-534

query I rowsort
SELECT ALL - col2 + col2 - + col0 * col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + 51 AS col1 FROM tab1 AS cor0
----
51
51
51

query I rowsort
SELECT 93 * + col2 * + 1 AS col1 FROM tab0 AS cor0
----
3069
7626
93

query I rowsort
SELECT DISTINCT - col2 + - col1 * 52 FROM tab1 AS cor0
----
-1406
-577
-772

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - col1 * + 96 col1 FROM tab2 AS cor0
----
-1670
-3003
-5690

query I rowsort
SELECT ALL + 12 * + col1 AS col0 FROM tab0 AS cor0
----
1032
1092
1164

query I rowsort
SELECT ALL col2 * + col0 * cor0.col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT ALL col1 + - ( + col1 ) * col0 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT + cor0.col2 + col1 - - col0 * col0 FROM tab2 AS cor0
----
107
6169
6296

query I rowsort
SELECT col1 + + tab0.col0 * - col2 AS col0 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT - tab2.col2 * col2 AS col2 FROM tab2
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * col1 col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + cor0.col2 - + col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8596
SELECT - col2 DIV - ( col1 * col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8596
SELECT - col2 / - ( col1 * col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 37 + + tab2.col0 AS col0 FROM tab2
----
-30
41
42

query I rowsort
SELECT + cor1.col2 FROM tab1, tab2, tab2 AS cor0, tab2 AS cor1
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8599
SELECT ALL CAST( NULL AS SIGNED ) * - 2 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8599
SELECT ALL CAST ( NULL AS INTEGER ) * - 2 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col2 * + col1 * + col1 + tab1.col1 FROM tab1
----
16237
36530
5710

query I rowsort
SELECT DISTINCT + tab2.col2 + + 18 FROM tab2
----
44
45
56

query I rowsort
SELECT DISTINCT - col0 * - 59 AS col0 FROM tab1 AS cor0
----
177
3776
4720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 * col0 - col2 col0 FROM tab0 cor0
----
1224
543
7839

query I rowsort
SELECT + col0 + col0 * + col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-8605
SELECT DISTINCT + ( - 64 ) DIV - col1 + - col0 FROM tab1 AS cor0
----
-1
-58
-76

skipif mysql # not compatible
query I rowsort label-8605
SELECT DISTINCT + ( - 64 ) / - col1 + - col0 FROM tab1 AS cor0
----
-1
-58
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8606
SELECT + CAST( + col0 AS SIGNED ) + + col2 * ( + cor0.col0 * col0 ) FROM tab2 AS cor0
----
1330
158262
237237

skipif mysql # not compatible
query I rowsort label-8606
SELECT + CAST ( + col0 AS INTEGER ) + + col2 * ( + cor0.col0 * col0 ) FROM tab2 AS cor0
----
1330
158262
237237

onlyif mysql # use DIV operator for integer division
query I rowsort label-8607
SELECT col2 + 11 DIV + tab1.col0 FROM tab1
----
57
57
96

skipif mysql # not compatible
query I rowsort label-8607
SELECT col2 + 11 / + tab1.col0 FROM tab1
----
57
57
96

query I rowsort
SELECT DISTINCT - + ( - cor0.col2 ) * col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-8609
SELECT ALL + 13 DIV tab2.col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8609
SELECT ALL + 13 / tab2.col1 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8610
SELECT - - col2 DIV col0 col0 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8610
SELECT - - col2 / col0 col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT DISTINCT col0 + col1 * 54 FROM tab0 AS cor0
----
4668
5003
5273

query I rowsort
SELECT 46 + col0 AS col2 FROM tab2 AS cor0
----
124
125
53

query I rowsort
SELECT - 75 * col0 FROM tab1 AS cor0
----
-225
-4800
-6000

query I rowsort
SELECT ALL + + 99 + - col0 FROM tab0 AS cor0
----
10
64
75

query I rowsort
SELECT DISTINCT - col0 * col2 AS col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - cor0.col1 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 27 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

query I rowsort
SELECT + col1 * ( 68 ) AS col1 FROM tab2
----
1156
2108
4012

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to fcae6e4467f798ac88c869b8e38c6b23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8620
SELECT CAST( - col0 AS SIGNED ) * - tab0.col2 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-8620
SELECT CAST ( - col0 AS INTEGER ) * - tab0.col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT + ( - tab0.col1 ) AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT + - ( 36 ) * col2 AS col2 FROM tab0 AS cor0
----
-1188
-2952
-36

query I rowsort
SELECT - 26 + - col2 * - col1 AS col0 FROM tab2 AS cor0
----
1508
620
811

query I rowsort
SELECT ( + ( + col0 ) ) * - col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - - 41 + cor0.col1 FROM tab1 AS cor0
----
51
54
67

query I rowsort
SELECT 62 * 68 FROM tab2 AS cor0
----
4216
4216
4216

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab2, tab1 cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8628
SELECT DISTINCT + tab0.col0 * + col1 * + CAST( NULL AS SIGNED ) + col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-8628
SELECT DISTINCT + tab0.col0 * + col1 * + CAST ( NULL AS INTEGER ) + col2 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 92 * - tab0.col2 col2 FROM tab0
----
-3036
-7544
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-8630
SELECT col2 * col0 DIV + tab1.col1 FROM tab1
----
364
590
6

skipif mysql # not compatible
query I rowsort label-8630
SELECT col2 * col0 / + tab1.col1 FROM tab1
----
364
590
6

query I rowsort
SELECT cor0.col2 + 29 FROM tab2, tab0 cor0
----
9 values hashing to 0ffb8c9be4ef1ad2716eac216b279aec

query I rowsort
SELECT ALL - col0 * + col0 + + ( col0 * - col2 ) + 82 FROM tab1 AS cor0
----
-13998
-7662
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col2 + + 66 col1 FROM tab0 AS cor0
----
-7232
-726
31

query I rowsort
SELECT + col2 * ( - 60 ) + col1 AS col0 FROM tab0 AS cor0
----
-1894
-4829
37

query I rowsort
SELECT + col1 * + ( cor0.col0 ) FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - + col0 * 72 + col2 AS col0 FROM tab1 AS cor0
----
-162
-4551
-5664

query I rowsort
SELECT ALL - + col0 * - 30 + col1 + col1 FROM tab1 AS cor0
----
142
1940
2426

skipif mysql # not compatible
query I rowsort
SELECT col0 * - CAST ( col0 AS REAL ) + + col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT ALL + cor0.col1 - + col1 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8640
SELECT + col2 * CAST( NULL AS SIGNED ) - + col2 * col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8640
SELECT + col2 * CAST ( NULL AS INTEGER ) - + col2 * col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + tab1.col2 + ( col2 ) * col2 FROM tab1
----
3024
3363
9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 - ( 55 ) col1 FROM tab2 AS cor0
----
-114
-72
-86

query I rowsort
SELECT - col2 + col1 * col2 AS col2 FROM tab1
----
1152
1350
513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8644
SELECT - col2 * + CAST( NULL AS SIGNED ) + + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8644
SELECT - col2 * + CAST ( NULL AS INTEGER ) + + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8645
SELECT col1 DIV cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-8645
SELECT col1 / cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT - cor0.col0 * - col2 - - ( col1 * + ( col1 ) + - col1 ) AS col1 FROM tab2 AS cor0
----
1119
3274
5450

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8647
SELECT DISTINCT + tab1.col1 - + CAST( NULL AS DECIMAL ) * - col1 AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8647
SELECT DISTINCT + tab1.col1 - + CAST ( NULL AS REAL ) * - col1 AS col1 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT col1 - - col2 AS col1 FROM tab2
----
55
58
85

query I rowsort
SELECT col0 * + col1 * tab1.col2 + - tab1.col0 FROM tab1
----
36416
4209
99760

query I rowsort
SELECT - + col0 * ( + col2 ) * col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT - col0 + col0 * 39 AS col1 FROM tab0 cor0
----
1330
3382
912

query I rowsort
SELECT + + col1 * col0 - cor0.col1 AS col0 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8653
SELECT ALL - CAST( + 69 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-69
-69
-69

skipif mysql # not compatible
query I rowsort label-8653
SELECT ALL - CAST ( + 69 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-69
-69
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 46 * 21 * + cor0.col1 col2 FROM tab1 AS cor0
----
12558
25116
9660

onlyif mysql # use DIV operator for integer division
query I rowsort label-8655
SELECT DISTINCT - col2 * 33 + - col2 DIV + ( col1 ) FROM tab0 AS cor0
----
-1089
-2706
-33

skipif mysql # not compatible
query I rowsort label-8655
SELECT DISTINCT - col2 * 33 + - col2 / + ( col1 ) FROM tab0 AS cor0
----
-1089
-2706
-33

query I rowsort
SELECT ALL 44 + - col0 AS col1 FROM tab0 AS cor0
----
-45
20
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8657
SELECT ALL col2 + - 99 DIV - col1 AS col1 FROM tab1 AS cor0
----
103
57
66

skipif mysql # not compatible
query I rowsort label-8657
SELECT ALL col2 + - 99 / - col1 AS col1 FROM tab1 AS cor0
----
103
57
66

query I rowsort
SELECT - ( + 40 ) * + cor0.col1 + + col2 * col0 FROM tab0 AS cor0
----
-2648
-3845
3658

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - cor0.col0 * - col0 col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT ALL - 77 * + col2 AS col0 FROM tab2 AS cor0
----
-2002
-2079
-2926

query I rowsort
SELECT + col2 * + 70 + col1 * - col2 FROM tab1 AS cor0
----
2376
3420
5472

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8662
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + col1 + col0 + 83 * - cor0.col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8662
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + col1 + col0 + 83 * - cor0.col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col0 + + 45 * + col0 FROM tab1 AS cor0
----
138
2944
3680

query I rowsort
SELECT + + col2 * ( col1 ) FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + 13 AS col2 FROM tab2 AS cor0
----
13
13
13

query I rowsort
SELECT ALL + + ( + col1 ) AS col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - ( + 89 ) AS col1 FROM tab0 AS cor0
----
-89

query I rowsort
SELECT + col1 * - 31 FROM tab2
----
-1829
-527
-961

query I rowsort
SELECT ALL tab0.col1 - col0 AS col1 FROM tab0
----
2
62
62

query I rowsort
SELECT ALL - col1 - + col0 AS col0 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT ( - tab1.col1 ) AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT 91 * col1 FROM tab2 AS cor0
----
1547
2821
5369

query I rowsort
SELECT - + col1 * - col0 AS col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT + + 87 * + col0 AS col0 FROM tab2 AS cor0
----
609
6786
6873

query I rowsort
SELECT ALL - + ( 80 ) + cor0.col1 AS col0 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 5f840f76b67b5f9e94e0a0584d047cf6

query I rowsort
SELECT cor1.col2 * + 37 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to da6b9e7da41066a85101a1f347afba1c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8677
SELECT DISTINCT + CAST( col0 AS SIGNED ) * col0 * - 35 AS col1 FROM tab0
----
-20160
-277235
-42875

skipif mysql # not compatible
query I rowsort label-8677
SELECT DISTINCT + CAST ( col0 AS INTEGER ) * col0 * - 35 AS col1 FROM tab0
----
-20160
-277235
-42875

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8678
SELECT ALL CAST( + ( col2 ) AS SIGNED ) * col0 * tab2.col0 AS col0 FROM tab2
----
1323
158184
237158

skipif mysql # not compatible
query I rowsort label-8678
SELECT ALL CAST ( + ( col2 ) AS INTEGER ) * col0 * tab2.col0 AS col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT 82 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

onlyif mysql # use DIV operator for integer division
query I rowsort label-8680
SELECT ALL + - col1 DIV col1 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8680
SELECT ALL + - col1 / col1 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8681
SELECT - col0 * col1 + 49 DIV 24 FROM tab2
----
-1341
-215
-4600

skipif mysql # not compatible
query I rowsort label-8681
SELECT - col0 * col1 + 49 / 24 FROM tab2
----
-1341
-215
-4600

query I rowsort
SELECT - 77 AS col2 FROM tab0 cor0
----
-77
-77
-77

query I rowsort
SELECT + + ( col1 ) * - col1 AS col0 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - 43 AS col2 FROM tab2
----
-43
-43
-43

onlyif mysql # use DIV operator for integer division
query I rowsort label-8685
SELECT tab0.col0 DIV - 5 FROM tab0
----
-17
-4
-7

skipif mysql # not compatible
query I rowsort label-8685
SELECT tab0.col0 / - 5 FROM tab0
----
-17
-4
-7

query I rowsort
SELECT + col1 * tab2.col1 * - col0 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT - 27 - - ( - col0 * 6 ) AS col2 FROM tab1
----
-411
-45
-507

onlyif mysql # use DIV operator for integer division
query I rowsort label-8688
SELECT ALL col2 - col1 DIV col1 AS col1 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-8688
SELECT ALL col2 - col1 / col1 AS col1 FROM tab0
----
0
32
81

query I rowsort
SELECT col0 * ( cor0.col1 ) AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col1 * - col1 * cor0.col2 + - col2 AS col0 FROM tab0 AS cor0
----
-244101
-679124
-9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 91 col2 FROM tab2 AS cor0
----
91

query I rowsort
SELECT DISTINCT - ( 21 ) + col0 * 22 FROM tab1 AS cor0
----
1387
1739
45

query I rowsort
SELECT ALL 89 + col0 AS col2 FROM tab1 AS cor0
----
153
169
92

query I rowsort
SELECT + 92 AS col2 FROM tab2 cor0
----
92
92
92

query I rowsort
SELECT - - 13 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT + 7 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT 65 + cor0.col2 FROM tab0 AS cor0
----
147
66
98

query I rowsort
SELECT - - col1 * cor0.col0 - + col2 AS col1 FROM tab1 cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-8699
SELECT DISTINCT + 42 DIV cor0.col1 + + cor0.col1 * col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-8699
SELECT DISTINCT + 42 / cor0.col1 + + cor0.col1 * col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT + 47 + col1 * col2 AS col0 FROM tab2 AS cor0
----
1581
693
884

onlyif mysql # use DIV operator for integer division
query I rowsort label-8701
SELECT ALL tab2.col0 DIV 29 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to dcf0bdb0a33a97c73a81c5b823899d40

skipif mysql # not compatible
query I rowsort label-8701
SELECT ALL tab2.col0 / 29 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to dcf0bdb0a33a97c73a81c5b823899d40

query I rowsort
SELECT 56 + col0 AS col0 FROM tab1 AS cor0
----
120
136
59

query I rowsort
SELECT ALL + cor0.col1 * - col0 + - 73 * - col1 + - col1 FROM tab0 AS cor0
----
-1547
3589
4128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 27 col0 FROM tab1 AS cor0
----
27
27
27

query I rowsort
SELECT + + 31 AS col1 FROM tab0 AS cor0
----
31
31
31

query I rowsort
SELECT ALL + cor0.col1 + col2 * 54 AS col2 FROM tab2 AS cor0
----
1463
1489
2069

query I rowsort
SELECT - col0 * + col1 * + col2 + - col2 * col0 FROM tab1 AS cor0
----
-107520
-40128
-4374

onlyif mysql # use DIV operator for integer division
query I rowsort label-8708
SELECT ALL ( - col2 ) DIV + col2 + + 35 AS col1 FROM tab0 AS cor0
----
34
34
34

skipif mysql # not compatible
query I rowsort label-8708
SELECT ALL ( - col2 ) / + col2 + + 35 AS col1 FROM tab0 AS cor0
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-8709
SELECT DISTINCT col2 DIV - col0 FROM tab2 cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-8709
SELECT DISTINCT col2 / - col0 FROM tab2 cor0
----
-3
0

query I rowsort
SELECT + 93 - col1 FROM tab2 AS cor0
----
34
62
76

query I rowsort
SELECT DISTINCT + - 78 AS col1 FROM tab2 AS cor0
----
-78

query I rowsort
SELECT + col1 + col2 * ( cor0.col0 ) * col0 + - ( - col0 ) AS col0 FROM tab1 cor0
----
233546
515
614493

query I rowsort
SELECT + 46 * col2 + 84 + col1 * col0 * + col1 AS col0 FROM tab2 AS cor0
----
24663
272798
8053

query I rowsort
SELECT ALL - + 11 + - col1 AS col2 FROM tab1 AS cor0
----
-21
-24
-37

query I rowsort
SELECT + col1 * + col0 - - cor0.col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT + 81 * - col0 FROM tab2 cor0
----
-567
-6318
-6399

onlyif mysql # use DIV operator for integer division
query I rowsort label-8717
SELECT ALL col1 DIV col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-8717
SELECT ALL col1 / col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT + - col0 + 0 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8719
SELECT tab0.col2 * + col1 DIV - col1 + - col2 DIV + col2 FROM tab0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-8719
SELECT tab0.col2 * + col1 / - col1 + - col2 / + col2 FROM tab0
----
-2
-34
-83

query I rowsort
SELECT ALL col0 * + 26 * col0 AS col1 FROM tab0 AS cor0
----
14976
205946
31850

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8721
SELECT DISTINCT + col2 * CAST( NULL AS SIGNED ) + col1 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8721
SELECT DISTINCT + col2 * CAST ( NULL AS INTEGER ) + col1 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col2 * 52 AS col0 FROM tab1 AS cor0
----
2808
2964
4992

query I rowsort
SELECT ALL - - col0 * col1 - col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT + - col2 * col1 + col0 + + cor0.col1 FROM tab1 AS cor0
----
-1155
-1375
-496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + ( col0 * col0 + - col0 ) col0 FROM tab0 AS cor0
----
1287
638
7923

query I rowsort
SELECT - cor0.col1 + + ( - 76 ) FROM tab0 AS cor0
----
-162
-167
-173

query I rowsort
SELECT ALL + col1 - 75 FROM tab1 cor0
----
-49
-62
-65

query I rowsort
SELECT DISTINCT cor0.col1 + - ( + cor0.col2 ) FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL 37 * col1 + col0 * col2 FROM tab0 AS cor0
----
10665
3624
3974

query I rowsort
SELECT DISTINCT + - 3 + - col0 FROM tab1 AS cor0
----
-6
-67
-83

query I rowsort
SELECT ALL - 10 * col1 * - col2 + 58 FROM tab2 AS cor0
----
15398
6518
8428

query I rowsort
SELECT ALL + col2 * - col0 + - col1 + col0 FROM tab0 AS cor0
----
-7300
-854
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + - cor0.col1 col1 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-8734
SELECT DISTINCT + col0 DIV 93 + - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8734
SELECT DISTINCT + col0 / 93 + - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8735
SELECT ALL + col0 DIV + col2 - col2 col2 FROM tab0 AS cor0
----
-33
-81
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8735
SELECT ALL + col0 / + col2 - col2 col2 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT ALL + - 76 AS col1 FROM tab2 AS cor0
----
-76
-76
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + cor0.col0 col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + 61 * col0 col1 FROM tab0 AS cor0
----
1378
2038
5338

query I rowsort
SELECT - + col1 * ( + col2 ) * + 76 AS col1 FROM tab2 AS cor0
----
-116584
-49096
-63612

query I rowsort
SELECT DISTINCT - 98 AS col1 FROM tab0 AS cor0
----
-98

query I rowsort
SELECT ( + 95 ) AS col1 FROM tab1 AS cor0
----
95
95
95

query I rowsort
SELECT col1 * + ( + tab2.col1 ) FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL col1 * + 84 + col1 FROM tab1 AS cor0
----
1105
2210
850

query I rowsort
SELECT DISTINCT + col2 * - 70 - col1 AS col1 FROM tab2 AS cor0
----
-1879
-1921
-2677

query I rowsort
SELECT 83 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT - - cor0.col2 * - cor0.col2 * + 75 AS col0 FROM tab1 AS cor0
----
-218700
-243675
-691200

query I rowsort
SELECT tab0.col1 + cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 13a45e994f0549dd29e84599a57026d0

query I rowsort
SELECT DISTINCT 4 AS col2 FROM tab1, tab1 AS cor0
----
4

query I rowsort
SELECT DISTINCT col0 + - col1 * col0 * - col2 AS col0 FROM tab1 AS cor0
----
36544
4215
99920

query I rowsort
SELECT ALL - col2 * - ( 77 ) FROM tab2 cor0
----
2002
2079
2926

query I rowsort
SELECT ALL + - col2 + - ( - col2 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col2 * col1 + - tab1.col2 + + col0 AS col2 FROM tab1
----
1232
1353
577

query I rowsort
SELECT cor0.col1 * + ( 84 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to bf5d0040fbd7fb88d76fe768ab001543

onlyif mysql # use DIV operator for integer division
query I rowsort label-8754
SELECT DISTINCT + col0 DIV + ( col2 + - col0 ) FROM tab1
----
-9
0
5

skipif mysql # not compatible
query I rowsort label-8754
SELECT DISTINCT + col0 / + ( col2 + - col0 ) FROM tab1
----
-9
0
5

query I rowsort
SELECT ALL + + cor0.col2 * + col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-8756
SELECT ALL + - col0 DIV - cor0.col0 AS col2 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8756
SELECT ALL + - col0 / - cor0.col0 AS col2 FROM tab2 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 + col2 col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - - col0 * col2 - col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT + 21 + col2 FROM tab1 AS cor0
----
117
75
78

query I rowsort
SELECT - 11 * col0 + + col0 AS col1 FROM tab2 AS cor0
----
-70
-780
-790

query I rowsort
SELECT DISTINCT col1 + + tab0.col2 + col0 FROM tab0
----
133
143
262

query I rowsort
SELECT DISTINCT - + cor0.col0 * - col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + col0 - - cor0.col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + 65 + col0 AS col1 FROM tab1
----
129
145
68

query I rowsort
SELECT + - col0 + col2 * col1 FROM tab0 cor0
----
2814
62
7373

query I rowsort
SELECT 66 * - col0 FROM tab1 AS cor0
----
-198
-4224
-5280

query I rowsort
SELECT DISTINCT + - cor0.col1 + + cor0.col0 + col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + ( + col2 ) - - tab1.col2 FROM tab1
----
108
114
192

query I rowsort
SELECT 74 * col2 FROM tab1
----
3996
4218
7104

onlyif mysql # use DIV operator for integer division
query I rowsort label-8770
SELECT - - 47 DIV col0 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-8770
SELECT - - 47 / col0 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT + col1 + 8 * + col1 AS col2 FROM tab1 cor0
----
117
234
90

query I rowsort
SELECT - 44 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

query I rowsort
SELECT - ( + col1 ) * col0 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8774
SELECT CAST( ( - col1 ) AS SIGNED ) * + col1 col1 FROM tab1
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8774
SELECT CAST ( ( - col1 ) AS INTEGER ) * + col1 col1 FROM tab1
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-8775
SELECT col0 * col1 DIV - col1 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-8775
SELECT col0 * col1 / - col1 FROM tab1
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8776
SELECT DISTINCT col0 DIV + 10 AS col2 FROM tab2
----
0
7

skipif mysql # not compatible
query I rowsort label-8776
SELECT DISTINCT col0 / + 10 AS col2 FROM tab2
----
0
7

query I rowsort
SELECT DISTINCT 78 FROM tab0, tab2 AS cor0
----
78

query I rowsort
SELECT - - 42 * - ( col1 ) AS col1 FROM tab0 AS cor0
----
-3612
-3822
-4074

query I rowsort
SELECT + cor1.col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT - col0 + - col0 * + col0 FROM tab2
----
-56
-6162
-6320

query I rowsort
SELECT ALL col0 * tab2.col2 * col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT + col2 + tab1.col0 + - col1 FROM tab1
----
111
163
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-8784
SELECT DISTINCT - col0 DIV tab2.col1 AS col2 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-8784
SELECT DISTINCT - col0 / tab2.col1 AS col2 FROM tab2
----
-1
-4
0

query I rowsort
SELECT - col1 * col1 * + col1 AS col0 FROM tab2
----
-205379
-29791
-4913

query III rowsort
SELECT * FROM tab2 WHERE NOT + col2 * col0 - col1 BETWEEN col2 AND NULL
----

query I rowsort
SELECT + col1 * col0 * + col2 AS col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL - col0 FROM tab1 WHERE NULL NOT IN ( + col2 * col2 )
----

query I rowsort
SELECT DISTINCT - tab0.col1 * - col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL + col0 * col1 FROM tab1 AS cor0 WHERE NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT + col2 * col0 + - col1 AS col0 FROM tab0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-8792
SELECT DISTINCT - col0 DIV col0 + col0 DIV col2 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-8792
SELECT DISTINCT - col0 / col0 + col0 / col2 FROM tab1
----
-1
0

query I rowsort
SELECT + col1 * - col2 - + col1 FROM tab2
----
-1593
-663
-868

query I rowsort
SELECT - col0 + col0 * - col2 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT - tab1.col0 * col0 AS col2 FROM tab1
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8796
SELECT + col0 * col1 DIV - col1 + col2 * col0 FROM tab0
----
0
7209
768

skipif mysql # not compatible
query I rowsort label-8796
SELECT + col0 * col1 / - col1 + col2 * col0 FROM tab0
----
0
7209
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-8797
SELECT + col2 DIV + col2 + + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-8797
SELECT + col2 / + col2 + + col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT + col2 + + cor0.col2 * - col1 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT - col0 * col1 + + cor0.col2 FROM tab0 cor0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-8800
SELECT ALL - + col2 DIV + col0 + col2 - - cor0.col2 col0 FROM tab0 AS cor0
----
164
2
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8800
SELECT ALL - + col2 / + col0 + col2 - - cor0.col2 col0 FROM tab0 AS cor0
----
164
2
65

query I rowsort
SELECT ALL - cor0.col0 + + cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
182
1950
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col1 FROM tab1 cor0 WHERE NOT NULL < ( NULL ) OR NULL = ( NULL )
----

query I rowsort
SELECT - - col1 + col1 AS col0 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ALL - - col1 * + col2 + col0 AS col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + - col0 * - cor0.col0 * col0 FROM tab2 AS cor0
----
343
474552
493039

query I rowsort
SELECT ALL - - col1 * - col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - - cor0.col0 + + col2 + - col2 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - - col2 * - col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT col1 * 58 FROM tab2 AS cor0
----
1798
3422
986

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 - + col0 * - col2 * cor0.col0 col2 FROM tab0 AS cor0
----
1226
19041
649604

query I rowsort
SELECT ALL + col0 + col0 * + col1 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + - col0 * col2 * - col1 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - 11 col2 FROM tab2 AS cor0
----
187
341
649

query I rowsort
SELECT DISTINCT + col1 * - 52 AS col1 FROM tab1 AS cor0
----
-1352
-520
-676

skipif mysql # not compatible
query I rowsort
SELECT - col2 + CAST ( 51 AS REAL ) FROM tab2 AS cor0
----
13
24
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col2 col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL 73 FROM tab0, tab0 cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT ALL + col0 * + ( col2 ) * col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT ALL - 70 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

query I rowsort
SELECT DISTINCT + col1 * + tab0.col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + col0 * col1 * - col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-8822
SELECT + col1 DIV ( + 93 ) + - tab1.col1 AS col0 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-8822
SELECT + col1 / ( + 93 ) + - tab1.col1 AS col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT + tab0.col1 * + col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT 35 + + col0 * col1 FROM tab2
----
1378
252
4637

query I rowsort
SELECT ALL - 83 + col2 AS col0 FROM tab2 AS cor0
----
-45
-56
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8826
SELECT DISTINCT + cor0.col2 DIV + col2 AS col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-8826
SELECT DISTINCT + cor0.col2 / + col2 AS col2 FROM tab1 AS cor0
----
1

query I rowsort
SELECT DISTINCT - 85 + + col0 * - col1 FROM tab0 cor0
----
-2149
-3480
-8184

query I rowsort
SELECT ALL 16 * cor0.col1 + + col0 AS col1 FROM tab0 cor0
----
1400
1545
1587

query I rowsort
SELECT DISTINCT ( col0 * tab2.col1 ) + + ( col2 ) FROM tab2
----
1381
244
4628

query I rowsort
SELECT col2 * col1 * - col2 AS col1 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT ( col0 ) * + col2 + + 73 * + col1 + + col2 FROM tab1
----
2114
4435
8725

query I rowsort
SELECT ALL + 27 + - col1 + + tab1.col2 * col0 AS col1 FROM tab1
----
163
3665
7694

query I rowsort
SELECT DISTINCT + 10 + + col1 AS col1 FROM tab1 AS cor0
----
20
23
36

query I rowsort
SELECT + + 15 * + col1 + 53 AS col1 FROM tab0 AS cor0
----
1343
1418
1508

onlyif mysql # use DIV operator for integer division
query I rowsort label-8835
SELECT ALL - col0 DIV + col0 col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8835
SELECT ALL - col0 / + col0 col1 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8836
SELECT + col2 + col0 DIV - ( + col2 ) AS col0 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-8836
SELECT + col2 + col0 / - ( + col2 ) AS col0 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT DISTINCT + 99 * col2 + + ( - 62 ) AS col1 FROM tab1 AS cor0
----
5284
5581
9442

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col1 col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - ( col2 ) * 69 AS col0 FROM tab0 AS cor0
----
-2277
-5658
-69

query I rowsort
SELECT ALL col2 * + cor0.col1 AS col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + col0 + - col1 * + 25 FROM tab0 AS cor0
----
-2126
-2186
-2390

query I rowsort
SELECT DISTINCT - - 86 AS col2 FROM tab0, tab2, tab1 cor0
----
86

query I rowsort
SELECT ( + col2 * ( + tab0.col0 ) ) FROM tab0
----
35
7298
792

query I rowsort
SELECT tab0.col2 * col1 + + col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + - col0 * col2 + 25 FROM tab2 AS cor0
----
-164
-2003
-2977

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col0 ) + 94 col0 FROM tab1 AS cor0
----
158
174
97

query I rowsort
SELECT ALL - ( + cor0.col2 ) AS col0 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + + 64 + cor0.col2 * + ( cor0.col0 ) FROM tab2 AS cor0
----
2092
253
3066

onlyif mysql # use DIV operator for integer division
query I rowsort label-8849
SELECT ALL - tab2.col1 DIV - tab2.col0 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-8849
SELECT ALL - tab2.col1 / - tab2.col0 FROM tab2
----
0
0
4

query I rowsort
SELECT + + col1 + ( col0 * col1 ) FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-8851
SELECT ALL - col0 + + 27 + col1 DIV + col1 FROM tab0 AS cor0
----
-61
-7
4

skipif mysql # not compatible
query I rowsort label-8851
SELECT ALL - col0 + + 27 + col1 / + col1 FROM tab0 AS cor0
----
-61
-7
4

query I rowsort
SELECT ALL cor0.col1 + col0 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col1 * col2 + - col1 * col1 FROM tab0 AS cor0
----
-4558
-819
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8854
SELECT + col0 * + CAST( cor0.col1 AS SIGNED ) + + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

skipif mysql # not compatible
query I rowsort label-8854
SELECT + col0 * + CAST ( cor0.col1 AS INTEGER ) + + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - + 12 * col2 FROM tab2 cor0
----
-312
-324
-456

onlyif mysql # use DIV operator for integer division
query I rowsort label-8856
SELECT DISTINCT 19 DIV 93 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8856
SELECT DISTINCT 19 / 93 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 51 + 65 FROM tab1 AS cor0
----
14

query I rowsort
SELECT ALL - 5 FROM tab2 cor0
----
-5
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-8859
SELECT + + col1 DIV 81 + col0 AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-8859
SELECT + + col1 / 81 + col0 AS col2 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8860
SELECT ALL + col1 DIV col0 + col1 AS col0 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-8860
SELECT ALL + col1 / col0 + col1 AS col0 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT DISTINCT - 54 * 44 AS col1 FROM tab2 AS cor0
----
-2376

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8862
SELECT DISTINCT CAST( col2 + col2 AS SIGNED ) * + 77 * - 13 AS col0 FROM tab2
----
-52052
-54054
-76076

skipif mysql # not compatible
query I rowsort label-8862
SELECT DISTINCT CAST ( col2 + col2 AS INTEGER ) * + 77 * - 13 AS col0 FROM tab2
----
-52052
-54054
-76076

onlyif mysql # use DIV operator for integer division
query I rowsort label-8863
SELECT - 25 DIV col1 - - cor0.col0 AS col2 FROM tab2 AS cor0
----
7
78
78

skipif mysql # not compatible
query I rowsort label-8863
SELECT - 25 / col1 - - cor0.col0 AS col2 FROM tab2 AS cor0
----
7
78
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 34 * 45 + col0 col2 FROM tab1 AS cor0
----
1533
1594
1610

query I rowsort
SELECT ALL col0 * - 92 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-637
-7098
-7189

query I rowsort
SELECT DISTINCT - cor0.col2 + + col0 - + col1 FROM tab0 cor0
----
-63
-84
-95

query I rowsort
SELECT ALL + 11 * col1 FROM tab1 AS cor0
----
110
143
286

query I rowsort
SELECT ALL - - col0 * col1 + col1 + cor0.col2 * - col2 FROM tab1 AS cor0
----
-2599
-2812
-8163

onlyif mysql # use DIV operator for integer division
query I rowsort label-8869
SELECT ALL + col0 DIV + col1 + cor0.col0 AS col0 FROM tab2 AS cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-8869
SELECT ALL + col0 / + col1 + cor0.col0 AS col0 FROM tab2 AS cor0
----
7
79
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 52 col0 FROM tab1 AS cor0
----
52
52
52

query I rowsort
SELECT + - 2 FROM tab0 AS cor0
----
-2
-2
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - ( - col1 ) ) + col0 * + col2 col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT - col1 + - 48 FROM tab2
----
-107
-65
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8874
SELECT ALL + CAST( + col2 AS SIGNED ) + + col1 AS col1 FROM tab2
----
55
58
85

skipif mysql # not compatible
query I rowsort label-8874
SELECT ALL + CAST ( + col2 AS INTEGER ) + + col1 AS col1 FROM tab2
----
55
58
85

query I rowsort
SELECT + - ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + + ( + 97 ) FROM tab1 AS cor0
----
97
97
97

query I rowsort
SELECT + + 71 AS col0 FROM tab2 AS cor0
----
71
71
71

query I rowsort
SELECT DISTINCT + 83 FROM tab2, tab1 AS cor0
----
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8879
SELECT - CAST( NULL AS SIGNED ) * 76 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8879
SELECT - CAST ( NULL AS INTEGER ) * 76 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 76 + - 71 * + cor0.col1 FROM tab1 AS cor0
----
-1770
-634
-847

query I rowsort
SELECT + + 24 - col0 AS col2 FROM tab2 AS cor0
----
-54
-55
17

query I rowsort
SELECT 30 AS col0 FROM tab1
----
30
30
30

query I rowsort
SELECT ALL - ( - 88 ) + - col2 AS col2 FROM tab2
----
50
61
62

query I rowsort
SELECT - + col1 - col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL + col2 + - col2 * col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT - cor0.col1 * 74 FROM tab1 AS cor0
----
-1924
-740
-962

query I rowsort
SELECT DISTINCT 39 FROM tab0, tab0 cor0, tab2 AS cor1
----
39

query I rowsort
SELECT ALL + 4 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8889
SELECT ALL - col1 * CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8889
SELECT ALL - col1 * CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 32 FROM tab2, tab0 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT ALL - - col0 + + col0 AS col2 FROM tab0 cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-8892
SELECT - ( - col0 ) DIV col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-8892
SELECT - ( - col0 ) / col1 FROM tab1 AS cor0
----
0
6
6

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab1 cor1, tab1 AS cor2
----
972 values hashing to 635619591835474e6aa6acdff4ab166c

onlyif mysql # use DIV operator for integer division
query I rowsort label-8894
SELECT ALL - - cor0.col2 DIV 9 FROM tab0 cor0
----
0
3
9

skipif mysql # not compatible
query I rowsort label-8894
SELECT ALL - - cor0.col2 / 9 FROM tab0 cor0
----
0
3
9

query I rowsort
SELECT DISTINCT ( - 11 ) FROM tab2, tab0 cor0
----
-11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col2 col1 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT 99 * + ( col1 ) FROM tab1
----
1287
2574
990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8898
SELECT ( col0 + - tab0.col0 * CAST( - 70 AS SIGNED ) ) FROM tab0
----
1704
2485
6319

skipif mysql # not compatible
query I rowsort label-8898
SELECT ( col0 + - tab0.col0 * CAST ( - 70 AS INTEGER ) ) FROM tab0
----
1704
2485
6319

onlyif mysql # use DIV operator for integer division
query I rowsort label-8899
SELECT DISTINCT - col2 + 36 DIV + col0 AS col2 FROM tab2 AS cor0
----
-22
-26
-38

skipif mysql # not compatible
query I rowsort label-8899
SELECT DISTINCT - col2 + 36 / + col0 AS col2 FROM tab2 AS cor0
----
-22
-26
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 * col2 * tab0.col1 - tab0.col0 col0 FROM tab0
----
3360
664029
68088

query I rowsort
SELECT DISTINCT - 67 + cor0.col1 FROM tab1, tab2 cor0
----
-36
-50
-8

query I rowsort
SELECT ALL - 13 FROM tab1, tab1 cor0, tab1 cor1
----
27 values hashing to 1c6aaa07ba8d3dc01ee616e16bef60f2

query I rowsort
SELECT + 31 + - cor1.col2 AS col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to acafd4c821f143dd5bc5903bbcc54003

query I rowsort
SELECT 54 * - col0 FROM tab2
----
-378
-4212
-4266

query I rowsort
SELECT + + col0 + cor0.col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL tab0.col1 AS col2 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT DISTINCT - col0 - tab1.col0 * - col2 FROM tab1
----
159
3584
7600

query I rowsort
SELECT col0 * + col0 + 57 * col2 AS col2 FROM tab2 AS cor0
----
1588
7566
8407

onlyif mysql # use DIV operator for integer division
query I rowsort label-8909
SELECT ALL + col1 * - tab2.col1 + 48 DIV - col1 FROM tab2
----
-291
-3481
-962

skipif mysql # not compatible
query I rowsort label-8909
SELECT ALL + col1 * - tab2.col1 + 48 / - col1 FROM tab2
----
-291
-3481
-962

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8910
SELECT - col2 * ( ( + col2 ) ) + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8910
SELECT - col2 * ( ( + col2 ) ) + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * - 1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8912
SELECT ALL col1 + - 66 * - 37 + + col2 * - CAST( 85 AS SIGNED ) FROM tab2 AS cor0
----
-771
178
291

skipif mysql # not compatible
query I rowsort label-8912
SELECT ALL col1 + - 66 * - 37 + + col2 * - CAST ( 85 AS INTEGER ) FROM tab2 AS cor0
----
-771
178
291

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8913
SELECT + col1 + CAST( NULL AS DECIMAL ) * + col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8913
SELECT + col1 + CAST ( NULL AS REAL ) * + col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col2 + 28 FROM tab2 cor0
----
-10
1
2

query I rowsort
SELECT DISTINCT - col1 + ( + 67 ) FROM tab2 AS cor0
----
36
50
8

query I rowsort
SELECT - - col0 + col2 + + col1 FROM tab0 cor0
----
133
143
262

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8917
SELECT cor0.col0 * CAST( NULL AS SIGNED ) + col0 + + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8917
SELECT cor0.col0 * CAST ( NULL AS INTEGER ) + col0 + + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + - cor0.col2 + + col1 AS col0 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT DISTINCT + - cor0.col0 + 70 * col0 FROM tab2 AS cor0
----
483
5382
5451

query I rowsort
SELECT ALL + + 38 FROM tab1 AS cor0
----
38
38
38

query I rowsort
SELECT ALL - 82 * tab1.col2 FROM tab1
----
-4428
-4674
-7872

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0 WHERE ( NULL ) <> NULL
----

query I rowsort
SELECT DISTINCT - col2 + - col1 + col0 AS col2 FROM tab1
----
-29
-3
-77

query I rowsort
SELECT 98 AS col1 FROM tab1 AS cor0
----
98
98
98

query I rowsort
SELECT ALL col1 * col0 + - col1 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-1326
-208
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * + cor0.col0 col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT col2 * ( + col2 ) + col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-8928
SELECT DISTINCT - col1 * + col2 + + 55 DIV - col0 - ( ( + col0 ) ) FROM tab2 AS cor0
----
-1612
-725
-851

skipif mysql # not compatible
query I rowsort label-8928
SELECT DISTINCT - col1 * + col2 + + 55 / - col0 - ( ( + col0 ) ) FROM tab2 AS cor0
----
-1612
-725
-851

query I rowsort
SELECT + + col1 * - 30 AS col0 FROM tab1 AS cor0
----
-300
-390
-780

query I rowsort
SELECT + col1 * + 18 + col2 FROM tab2 AS cor0
----
1088
344
585

query I rowsort
SELECT 37 + - col2 AS col0 FROM tab1
----
-17
-20
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + tab1.col2 col0 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL col0 * + col1 AS col2 FROM tab0 WHERE NOT NULL = NULL
----

query III rowsort
SELECT * FROM tab2 WHERE - col0 * col1 * - col0 NOT IN ( - col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - col2 * - col1 + col1 FROM tab2
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-8936
SELECT col1 DIV + col2 col1 FROM tab0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8936
SELECT col1 / + col2 col1 FROM tab0
----
1
2
97

query I rowsort
SELECT DISTINCT col1 + col2 + + col1 AS col2 FROM tab2
----
144
72
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 * col1 * + tab0.col0 col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT col0 + + tab2.col0 + + col1 FROM tab2
----
175
215
45

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT - col1 <> + col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8941
SELECT ALL col2 DIV tab1.col2 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8941
SELECT ALL col2 / tab1.col2 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT - tab0.col0 * col0 AS col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT col2 AS col0 FROM tab1 WHERE NOT + col0 * col2 + - col0 IN ( tab1.col2 + - col2 + tab1.col1 )
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col2 * + col2 col0 FROM tab2
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-8945
SELECT + col2 DIV - col1 + col0 + col1 AS col0 FROM tab2
----
137
38
94

skipif mysql # not compatible
query I rowsort label-8945
SELECT + col2 / - col1 + col0 + col1 AS col0 FROM tab2
----
137
38
94

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL NOT IN ( - col2 - + col1 * col1 )
----

query I rowsort
SELECT DISTINCT col0 + col1 - + tab2.col1 * col1 * col2 FROM tab2
----
-10886
-25909
-90369

query I rowsort
SELECT ALL + tab1.col2 + - tab1.col0 + + col0 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT col0 * col2 * col1 AS col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT col1 * col1 * col2 AS col2 FROM tab0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col0 col2 FROM tab2
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-8952
SELECT col2 + + col1 DIV col0 FROM tab1
----
57
62
96

skipif mysql # not compatible
query I rowsort label-8952
SELECT col2 + + col1 / col0 FROM tab1
----
57
62
96

query I rowsort
SELECT col2 * - col2 + - col1 FROM tab0 WHERE ( col2 * tab0.col0 ) <= - col2 * col1
----

query I rowsort
SELECT tab2.col2 AS col1 FROM tab2 WHERE NOT NULL NOT IN ( col2 / col2 )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8955
SELECT CAST( - tab2.col1 AS SIGNED ) * + col1 FROM tab2
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-8955
SELECT CAST ( - tab2.col1 AS INTEGER ) * + col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT - 77 AS col2 FROM tab2
----
-77
-77
-77

query I rowsort
SELECT col2 * + col1 + col0 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT + 86 * col2 + 53 FROM tab0 AS cor0
----
139
2891
7105

query I rowsort
SELECT col1 - col0 * col1 * col1 AS col2 FROM tab2 AS cor0
----
-22814
-271459
-6696

query I rowsort
SELECT col2 * - col0 * - tab2.col0 AS col0 FROM tab2
----
1323
158184
237158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8961
SELECT DISTINCT CAST( NULL AS SIGNED ) * col0 * col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-8961
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col0 * col1 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT - ( - 92 ) * tab1.col2 * + ( col2 ) + col2 + col2 AS col2 FROM tab1
----
268380
299022
848064

query I rowsort
SELECT DISTINCT + + col1 + - col1 * + col1 AS col2 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT 5 * - col2 AS col0 FROM tab1
----
-270
-285
-480

query I rowsort
SELECT col2 + col1 + col0 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT col0 * + cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + + 42 + + col1 * ( cor0.col1 + col1 ) FROM tab0 AS cor0
----
14834
16604
18860

query I rowsort
SELECT + + col0 + col2 * - 51 FROM tab1 AS cor0
----
-2751
-2843
-4816

query I rowsort
SELECT DISTINCT cor0.col1 * col1 * - col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT - + col1 + 99 FROM tab2 AS cor0
----
40
68
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8971
SELECT ALL + col1 + CAST( NULL AS SIGNED ) * + cor0.col0 - + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8971
SELECT ALL + col1 + CAST ( NULL AS INTEGER ) * + cor0.col0 - + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - cor0.col2 + col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8973
SELECT ALL + cor0.col1 * - CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8973
SELECT ALL + cor0.col1 * - CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 * col0 + col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT ALL + + col2 + 11 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-149
-314
-623

query I rowsort
SELECT ALL - col0 + + col0 * + col2 AS col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT + col1 * + 31 FROM tab2 cor0
----
1829
527
961

query I rowsort
SELECT DISTINCT + cor0.col2 + col1 * + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + col0 * col0 * col0 + col2 AS col2 FROM tab2 AS cor0
----
370
474578
493077

query I rowsort
SELECT DISTINCT - 91 + col0 FROM tab1 AS cor0
----
-11
-27
-88

query I rowsort
SELECT DISTINCT ( - 47 ) * col2 + + col1 AS col2 FROM tab2 AS cor0
----
-1163
-1238
-1769

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 col2 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8983
SELECT cor0.col2 * - ( col2 ) + + CAST( + col2 + + col1 AS SIGNED ) FROM tab0 AS cor0
----
-6551
-970
97

skipif mysql # not compatible
query I rowsort label-8983
SELECT cor0.col2 * - ( col2 ) + + CAST ( + col2 + + col1 AS INTEGER ) FROM tab0 AS cor0
----
-6551
-970
97

query I rowsort
SELECT - cor0.col2 * col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - 84 * + col2 + - col2 FROM tab2 AS cor0
----
-2210
-2295
-3230

query I rowsort
SELECT - 27 - cor0.col1 FROM tab0 AS cor0
----
-113
-118
-124

query I rowsort
SELECT DISTINCT + 4 FROM tab1, tab2 AS cor0
----
4

query I rowsort
SELECT ALL - col0 * ( col1 ) + cor0.col2 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT - tab0.col1 + tab0.col0 AS col0 FROM tab0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8990
SELECT DISTINCT - tab1.col2 * col2 * + col1 + - col2 DIV - col0 FROM tab1
----
-119807
-32490
-75798

skipif mysql # not compatible
query I rowsort label-8990
SELECT DISTINCT - tab1.col2 * col2 * + col1 + - col2 / - col0 FROM tab1
----
-119807
-32490
-75798

query I rowsort
SELECT DISTINCT col2 + col1 * col1 AS col2 FROM tab2
----
327
3507
988

query I rowsort
SELECT ALL + 40 AS col1 FROM tab0
----
40
40
40

query I rowsort
SELECT DISTINCT - 53 * - col2 FROM tab0
----
1749
4346
53

query I rowsort
SELECT 75 AS col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

onlyif mysql # use DIV operator for integer division
query I rowsort label-8995
SELECT + + col2 DIV 44 FROM tab1 AS cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-8995
SELECT + + col2 / 44 FROM tab1 AS cor0
----
1
1
2

query I rowsort
SELECT ALL 56 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8997
SELECT - CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8997
SELECT - CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 - 7 AS col2 FROM tab0
----
-6
26
75

query I rowsort
SELECT + cor0.col1 - col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + + col2 + + cor0.col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9001
SELECT CAST( + col2 AS SIGNED ) / col0 + + CAST( NULL AS SIGNED ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9001
SELECT CAST ( + col2 AS INTEGER ) / col0 + + CAST ( NULL AS INTEGER ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 * col2 + col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - - 63 + + 88 * col1 FROM tab2 AS cor0
----
1559
2791
5255

query I rowsort
SELECT + - col0 + - col0 FROM tab1 cor0
----
-128
-160
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9005
SELECT - cor0.col0 DIV col0 col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9005
SELECT - cor0.col0 / col0 col1 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9006
SELECT + + ( - col2 ) DIV col1 AS col2 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-9006
SELECT + + ( - col2 ) / col1 AS col2 FROM tab1 AS cor0
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9007
SELECT - 46 DIV cor0.col2 - 76 FROM tab1 AS cor0
----
-76
-76
-76

skipif mysql # not compatible
query I rowsort label-9007
SELECT - 46 / cor0.col2 - 76 FROM tab1 AS cor0
----
-76
-76
-76

query I rowsort
SELECT DISTINCT col0 * - col2 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT - + 46 * col1 + + col1 * + col0 AS col2 FROM tab2 AS cor0
----
-1209
1888
561

query I rowsort
SELECT ALL - col0 * - col2 + col2 AS col1 FROM tab2
----
2054
216
3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9011
SELECT ALL + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9011
SELECT ALL + CAST ( NULL AS REAL ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL cor0.col0 * - cor0.col1 + + 9 * - 3 FROM tab1 cor0
----
-105
-1067
-667

query I rowsort
SELECT DISTINCT + - col2 * - col2 - - ( col2 + col1 ) * + 55 AS col2 FROM tab2 AS cor0
----
3919
4469
5351

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + col1 col0 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9015
SELECT ALL - 6 + - col0 DIV 42 AS col1 FROM tab2 AS cor0
----
-6
-7
-7

skipif mysql # not compatible
query I rowsort label-9015
SELECT ALL - 6 + - col0 / 42 AS col1 FROM tab2 AS cor0
----
-6
-7
-7

query I rowsort
SELECT col2 * cor0.col0 - col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT - col2 * + 22 AS col0 FROM tab0
----
-1804
-22
-726

query I rowsort
SELECT DISTINCT col0 - col2 * col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL - 97 + col2 FROM tab1 AS cor0
----
-1
-40
-43

query I rowsort
SELECT DISTINCT - 0 - col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL cor0.col0 + - 32 * + col1 + col0 AS col1 FROM tab0 AS cor0
----
-2704
-2734
-3034

query I rowsort
SELECT DISTINCT - col2 + + ( - 86 ) AS col2 FROM tab2 AS cor0
----
-112
-113
-124

query I rowsort
SELECT DISTINCT + + col0 + col2 FROM tab0 cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-9024
SELECT + 92 DIV + 78 AS col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9024
SELECT + 92 / + 78 AS col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col0 * - col1 + cor0.col0 * 58 + col2 AS col1 FROM tab1 AS cor0
----
306
4409
5776

query I rowsort
SELECT ( - col2 ) * col1 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT 62 + - ( - col2 ) FROM tab0 AS cor0
----
144
63
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-9028
SELECT ALL - 4 DIV col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9028
SELECT ALL - 4 / col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT cor2.col2 + - 40 * cor1.col1 FROM tab1, tab2 cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 6529928343e9a2b9858a746eb63dcf07

query I rowsort
SELECT DISTINCT + + col2 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL cor2.col0 + - cor2.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 cor2
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9032
SELECT ALL CAST( NULL AS DECIMAL ) / 75 - col0 * - col1 / col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9032
SELECT ALL CAST ( NULL AS REAL ) / 75 - col0 * - col1 / col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * cor0.col0 - - col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - col0 * - col1 - col1 * + 26 AS col2 FROM tab2
----
-589
3068
901

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9035
SELECT ALL + CAST( NULL AS SIGNED ) / col1 - col2 * - ( tab2.col2 ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9035
SELECT ALL + CAST ( NULL AS INTEGER ) / col1 - col2 * - ( tab2.col2 ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 19 - + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 27180dd34ee78391863fffbf3c0e6da7

query I rowsort
SELECT tab0.col0 * + ( col1 * + col0 ) AS col2 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + col0 * ( - 93 + - col1 * col2 ) AS col1 FROM tab2 AS cor0
----
-126906
-58381
-6510

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9039
SELECT col2 + ( - col2 ) * - cor0.col1 + + CAST( NULL AS SIGNED ) * + cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9039
SELECT col2 + ( - col2 ) * - cor0.col1 + + CAST ( NULL AS INTEGER ) * + cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + col0 * 22 FROM tab1 AS cor0
----
1398
1747
40

query I rowsort
SELECT ALL + col1 * + col0 + col1 * + col0 + ( col1 ) AS col1 FROM tab0 cor0
----
16289
4214
6887

onlyif mysql # use DIV operator for integer division
query I rowsort label-9042
SELECT + - cor0.col2 + - col0 DIV - 62 AS col0 FROM tab1 AS cor0
----
-54
-56
-95

skipif mysql # not compatible
query I rowsort label-9042
SELECT + - cor0.col2 + - col0 / - 62 AS col0 FROM tab1 AS cor0
----
-54
-56
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-9043
SELECT DISTINCT tab1.col1 + ( col0 + col2 ) DIV + col1 AS col1 FROM tab1
----
22
26
28

skipif mysql # not compatible
query I rowsort label-9043
SELECT DISTINCT tab1.col1 + ( col0 + col2 ) / + col1 AS col1 FROM tab1
----
22
26
28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9044
SELECT DISTINCT + CAST( - col2 AS SIGNED ) + col2 col2 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9044
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) + col2 col2 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9045
SELECT ALL - + col0 * 58 + col2 DIV - 33 FROM tab0 AS cor0
----
-1393
-2030
-5164

skipif mysql # not compatible
query I rowsort label-9045
SELECT ALL - + col0 * 58 + col2 / - 33 FROM tab0 AS cor0
----
-1393
-2030
-5164

query I rowsort
SELECT + 98 AS col1 FROM tab2 cor0 CROSS JOIN tab1, tab2 cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT ( col1 ) * ( + 70 ) FROM tab0 AS cor0
----
6020
6370
6790

query I rowsort
SELECT DISTINCT - col0 + + col1 * + col1 + col2 FROM tab0 AS cor0
----
7405
8274
9375

query I rowsort
SELECT ALL + ( - ( cor0.col2 ) ) FROM tab0, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT ALL - col1 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + cor0.col1 + - cor0.col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT + 92 + cor0.col0 FROM tab0 AS cor0
----
116
127
181

query I rowsort
SELECT DISTINCT + + col2 + col0 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT DISTINCT col1 + + ( + 65 + col0 ) FROM tab0 AS cor0
----
175
197
245

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 + + col0 col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT - col2 * + col1 - 36 AS col1 FROM tab1 AS cor0
----
-1284
-1440
-606

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9057
SELECT - + col0 / CAST( NULL AS SIGNED ) + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9057
SELECT - + col0 / CAST ( NULL AS INTEGER ) + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9058
SELECT ALL - col0 + 60 DIV cor0.col0 FROM tab1 AS cor0
----
-64
-80
17

skipif mysql # not compatible
query I rowsort label-9058
SELECT ALL - col0 + 60 / cor0.col0 FROM tab1 AS cor0
----
-64
-80
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9059
SELECT ALL - col1 + + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9059
SELECT ALL - col1 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9060
SELECT DISTINCT + col2 + - CAST( - 68 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
101
150
69

skipif mysql # not compatible
query I rowsort label-9060
SELECT DISTINCT + col2 + - CAST ( - 68 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
101
150
69

query I rowsort
SELECT cor0.col2 * - 91 - 57 AS col2 FROM tab1 AS cor0
----
-4971
-5244
-8793

query I rowsort
SELECT ALL col2 * tab1.col2 - col0 * col0 * tab1.col0 FROM tab1
----
-258895
-502784
2889

query I rowsort
SELECT ALL col1 + + col2 - col2 FROM tab0
----
86
91
97

query I rowsort
SELECT + col1 * ( + col2 + - col0 ) * + col0 FROM tab1 AS cor0
----
-4480
16640
3978

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9065
SELECT + - cor0.col1 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9065
SELECT + - cor0.col1 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9066
SELECT DISTINCT + col0 DIV + cor0.col1 + 69 AS col2 FROM tab1 AS cor0
----
69
75

skipif mysql # not compatible
query I rowsort label-9066
SELECT DISTINCT + col0 / + cor0.col1 + 69 AS col2 FROM tab1 AS cor0
----
69
75

query I rowsort
SELECT - 60 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + col0 col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - col0 + - ( col2 ) FROM tab1
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9070
SELECT ALL - col1 + - CAST( col2 * + col1 AS SIGNED ) AS col0 FROM tab0
----
-194
-2924
-7553

skipif mysql # not compatible
query I rowsort label-9070
SELECT ALL - col1 + - CAST ( col2 * + col1 AS INTEGER ) AS col0 FROM tab0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-9071
SELECT - col2 DIV + 26 AS col1 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9071
SELECT - col2 / + 26 AS col1 FROM tab2
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 92 + col1 * col1 col2 FROM tab0 AS cor0
----
7488
8373
9501

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col2 ) * cor0.col1 col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - 5 * 61 FROM tab2, tab2 AS cor0
----
9 values hashing to 3bcc9de53c996d9f4ae2bdda2781860a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9075
SELECT col1 + CAST( - col1 AS SIGNED ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9075
SELECT col1 + CAST ( - col1 AS INTEGER ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT - 41 + - col0 * ( - col0 + - col1 ) AS col1 FROM tab1 cor0
----
46
4695
7399

query I rowsort
SELECT 56 * col2 AS col1 FROM tab1 AS cor0
----
3024
3192
5376

onlyif mysql # use DIV operator for integer division
query I rowsort label-9078
SELECT ALL ( + col0 ) DIV - col0 col2 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9078
SELECT ALL ( + col0 ) / - col0 col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT ALL ( + col1 * + col0 ) FROM tab1
----
1040
640
78

query I rowsort
SELECT + 52 * col0 + col0 AS col1 FROM tab2
----
371
4134
4187

query I rowsort
SELECT - 53 + + col1 AS col0 FROM tab1
----
-27
-40
-43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9082
SELECT - CAST( NULL AS SIGNED ) + - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9082
SELECT - CAST ( NULL AS INTEGER ) + - col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * col1 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - ( col0 ) + - col1 * ( + col0 ) AS col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT ALL - cor0.col2 + + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 72 * cor0.col2 FROM tab0 AS cor0
----
2376
5904
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-9087
SELECT ALL + ( col1 ) DIV - col1 + + 25 FROM tab2 AS cor0
----
24
24
24

skipif mysql # not compatible
query I rowsort label-9087
SELECT ALL + ( col1 ) / - col1 + + 25 FROM tab2 AS cor0
----
24
24
24

query I rowsort
SELECT + 88 * - 72 + col1 + col2 FROM tab0 AS cor0
----
-6163
-6217
-6238

onlyif mysql # use DIV operator for integer division
query I rowsort label-9089
SELECT col2 + cor0.col0 DIV - col1 + - col0 FROM tab1 AS cor0
----
-13
10
51

skipif mysql # not compatible
query I rowsort label-9089
SELECT col2 + cor0.col0 / - col1 + - col0 FROM tab1 AS cor0
----
-13
10
51

query I rowsort
SELECT ALL 67 AS col0 FROM tab0 cor0
----
67
67
67

query I rowsort
SELECT ALL - 51 * cor0.col2 + - col0 + + col0 AS col1 FROM tab1 AS cor0
----
-2754
-2907
-4896

query I rowsort
SELECT + ( + 92 ) + - col1 + - ( col1 ) AS col1 FROM tab0 AS cor0
----
-102
-80
-90

query I rowsort
SELECT DISTINCT col2 + - 33 * col0 AS col2 FROM tab1 AS cor0
----
-2055
-2544
-45

query I rowsort
SELECT DISTINCT - - col0 + + ( cor0.col0 ) * col0 * col2 FROM tab1 AS cor0
----
233536
489
614480

query I rowsort
SELECT - + 46 + - 47 FROM tab1 AS cor0
----
-93
-93
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * + cor0.col1 + + col1 + + 26 * 42 col2 FROM tab0 AS cor0
----
-2206
-6916
-886

query I rowsort
SELECT col0 + col2 * + col1 + + 14 AS col1 FROM tab1 AS cor0
----
1342
1421
648

onlyif mysql # use DIV operator for integer division
query I rowsort label-9098
SELECT DISTINCT CAST( - ( - col2 ) + 26 AS SIGNED ) DIV ( col0 ) FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-9098
SELECT DISTINCT CAST ( - ( - col2 ) + 26 AS INTEGER ) / ( col0 ) FROM tab0
----
0
1
2

query I rowsort
SELECT - + col1 * 34 AS col0 FROM tab0 AS cor0
----
-2924
-3094
-3298

query I rowsort
SELECT ALL 50 + + cor1.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c046523cc02bdd2c024ad88715748c1b

query I rowsort
SELECT ( + col0 + 46 ) FROM tab1
----
110
126
49

query I rowsort
SELECT 38 * col2 AS col2 FROM tab0 AS cor0
----
1254
3116
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9103
SELECT ALL col2 DIV - 28 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-9103
SELECT ALL col2 / - 28 FROM tab0
----
-1
-2
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9104
SELECT col2 * CAST( NULL AS DECIMAL ) * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9104
SELECT col2 * CAST ( NULL AS REAL ) * col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 - - 1 * - 53 AS col1 FROM tab2
----
-22
-36
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9106
SELECT ALL - CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9106
SELECT ALL - CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL col2 * + tab2.col0 + ( + col1 ) + - 21 * - tab2.col2 FROM tab2
----
2633
3817
787

query I rowsort
SELECT - col0 * - tab0.col0 + col0 AS col2 FROM tab0
----
1260
600
8010

query I rowsort
SELECT DISTINCT + tab0.col1 - - col2 * col2 AS col1 FROM tab0
----
1175
6815
98

query I rowsort
SELECT + + cor0.col2 - + 10 AS col2 FROM tab1 AS cor0
----
44
47
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-9111
SELECT ALL col2 * col2 + col0 DIV - col2 AS col2 FROM tab0 AS cor0
----
-34
1089
6723

skipif mysql # not compatible
query I rowsort label-9111
SELECT ALL col2 * col2 + col0 / - col2 AS col2 FROM tab0 AS cor0
----
-34
1089
6723

query I rowsort
SELECT DISTINCT - col2 + col2 * 85 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT DISTINCT col0 * col2 + - col2 * col2 AS col2 FROM tab2 AS cor0
----
-540
1352
1558

query I rowsort
SELECT + - col2 - + col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT + + col0 * + col0 + + col0 AS col1 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT ALL 70 + - 54 - col0 FROM tab0 AS cor0
----
-19
-73
-8

query I rowsort
SELECT ALL cor1.col0 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - - col0 * + cor0.col0 + - col2 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT DISTINCT - cor0.col0 * + col2 + - col0 + 74 FROM tab2 AS cor0
----
-122
-2032
-3007

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 53 + + col2 - + cor0.col0 col1 FROM tab1 AS cor0
----
-2
-37
-60

query I rowsort
SELECT DISTINCT - col2 + col2 * - col1 FROM tab0 cor0
----
-2871
-7544
-98

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 DISTINCT + 14 AS col1 FROM tab2 AS cor0
----
14

query I rowsort
SELECT - 84 AS col1 FROM tab2
----
-84
-84
-84

query I rowsort
SELECT - - 42 * col1 + col2 AS col1 FROM tab2 AS cor0
----
1329
2504
752

query I rowsort
SELECT DISTINCT - - 58 * col0 + + 81 FROM tab0 AS cor0
----
1473
2111
5243

query I rowsort
SELECT ALL + col0 - col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-9128
SELECT ALL + col0 DIV col0 + - col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-9128
SELECT ALL + col0 / col0 + - col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT DISTINCT + ( + col1 ) * col1 + 13 * cor0.col0 FROM tab0 AS cor0
----
7708
9438
9864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - + col0 col1 FROM tab2 cor0
----
0

query I rowsort
SELECT DISTINCT + col1 + col1 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT 93 AS col1 FROM tab0
----
93
93
93

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab1, tab0, tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL col0 + 28 * cor0.col1 FROM tab0 AS cor0
----
2432
2637
2751

query I rowsort
SELECT ALL + cor0.col1 * col1 + + col1 AS col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT - col1 + cor0.col1 * - col0 AS col1 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT + col1 * ( - col1 ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - col1 - + 79 FROM tab1 AS cor0
----
-105
-89
-92

query I rowsort
SELECT ALL col0 + 77 FROM tab1 AS cor0
----
141
157
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9140
SELECT tab2.col2 + + col2 * + CAST( - col2 AS SIGNED ) * + col1 FROM tab2
----
-22572
-24510
-39858

skipif mysql # not compatible
query I rowsort label-9140
SELECT tab2.col2 + + col2 * + CAST ( - col2 AS INTEGER ) * + col1 FROM tab2
----
-22572
-24510
-39858

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 74 + col2 col1 FROM tab0
----
107
156
75

query I rowsort
SELECT 54 + col2 * + col0 FROM tab2
----
2082
243
3056

onlyif mysql # use DIV operator for integer division
query I rowsort label-9143
SELECT 20 DIV col0 FROM tab1 cor0
----
0
0
6

skipif mysql # not compatible
query I rowsort label-9143
SELECT 20 / col0 FROM tab1 cor0
----
0
0
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9144
SELECT ALL + CAST( NULL AS SIGNED ) * 94 * + col0 - col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9144
SELECT ALL + CAST ( NULL AS INTEGER ) * 94 * + col0 - col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 9 - cor0.col2 col0 FROM tab1 AS cor0
----
-45
-48
-87

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
3645 values hashing to 51e2051aff75c58a5edaa314f1412983

query I rowsort
SELECT DISTINCT - ( - tab2.col1 ) FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9148
SELECT - 75 + + col0 DIV col0 + col0 FROM tab1
----
-10
-71
6

skipif mysql # not compatible
query I rowsort label-9148
SELECT - 75 + + col0 / col0 + col0 FROM tab1
----
-10
-71
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9149
SELECT + tab2.col1 DIV col0 AS col1 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-9149
SELECT + tab2.col1 / col0 AS col1 FROM tab2
----
0
0
4

query I rowsort
SELECT ALL + col0 * col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT col2 + + tab1.col0 + + 31 * + 45 FROM tab1
----
1452
1516
1571

query I rowsort
SELECT ( + col0 ) + col0 + col2 FROM tab1
----
185
256
60

query I rowsort
SELECT - 24 * col2 AS col1 FROM tab1
----
-1296
-1368
-2304

query I rowsort
SELECT ALL 3 + col0 FROM tab1 cor0
----
6
67
83

query I rowsort
SELECT DISTINCT + cor0.col1 * - cor0.col0 FROM tab2, tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col0 - - col2 * col1 FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT + 64 + col1 * + ( + cor0.col2 + - col1 ) FROM tab0 AS cor0
----
-4494
-755
-9248

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 + + col2 col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT 21 * - col2 + 27 AS col2 FROM tab2 AS cor0
----
-519
-540
-771

query I rowsort
SELECT ALL 14 AS col1 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT + col0 * 61 + col0 FROM tab0
----
1488
2170
5518

query I rowsort
SELECT ALL + + cor0.col2 + + 64 FROM tab2 AS cor0
----
102
90
91

query I rowsort
SELECT ALL + col0 * + col0 * 1 AS col2 FROM tab1
----
4096
6400
9

query I rowsort
SELECT DISTINCT ( 27 ) FROM tab1 AS cor0
----
27

query I rowsort
SELECT ALL + - col0 + + col2 AS col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9166
SELECT - - CAST( NULL AS SIGNED ) + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9166
SELECT - - CAST ( NULL AS INTEGER ) + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 35 * 42 + - cor0.col2 * col2 FROM tab0 AS cor0
----
-5254
1469
381

query I rowsort
SELECT - 78 + - col0 FROM tab1 cor0
----
-142
-158
-81

query I rowsort
SELECT ALL + 71 * - col0 FROM tab0 AS cor0
----
-1704
-2485
-6319

onlyif mysql # use DIV operator for integer division
query I rowsort label-9170
SELECT ALL CAST( + 34 AS SIGNED ) + cor0.col1 DIV col1 + - 1 FROM tab1 AS cor0
----
34
34
34

skipif mysql # not compatible
query I rowsort label-9170
SELECT ALL CAST ( + 34 AS INTEGER ) + cor0.col1 / col1 + - 1 FROM tab1 AS cor0
----
34
34
34

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) * + col2 + ( - ( col0 ) ) FROM tab0 AS cor0
----
-70
-7387
-816

onlyif mysql # use DIV operator for integer division
query I rowsort label-9172
SELECT + - col0 DIV + col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-9172
SELECT + - col0 / + col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT ALL - - 30 * + col1 AS col2 FROM tab2 AS cor0
----
1770
510
930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col1 - col0 col0 FROM tab1
----
-1328
-1407
-634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + 59 col0 FROM tab2 AS cor0
----
137
138
66

query I rowsort
SELECT DISTINCT cor0.col0 + - 79 AS col0 FROM tab1 cor0
----
-15
-76
1

query I rowsort
SELECT DISTINCT + + cor0.col1 * cor0.col2 AS col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT cor0.col0 + col1 * col1 AS col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT ALL + 29 AS col1 FROM tab0 cor0
----
29
29
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col0 + - col2 ) col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL cor1.col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL - + col0 * - col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 97 col0 FROM tab2 AS cor0
----
97
97
97

query I rowsort
SELECT - cor0.col0 + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to c99cbeca6e6fdb3507b2e08470c1cda6

query I rowsort
SELECT + col1 * col2 * - ( 34 ) FROM tab0 AS cor0
----
-253708
-3298
-96492

onlyif mysql # use DIV operator for integer division
query I rowsort label-9186
SELECT DISTINCT + 9 DIV col2 AS col0 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-9186
SELECT DISTINCT + 9 / col2 AS col0 FROM tab1
----
0

query I rowsort
SELECT ALL tab2.col2 + + cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 73feda3cdfbb1052036b56d1a1e9df2d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 63 col2 FROM tab0, tab2 AS cor0
----
-63

query I rowsort
SELECT + col1 * + ( - 15 ) AS col1 FROM tab2 AS cor0
----
-255
-465
-885

query I rowsort
SELECT DISTINCT + 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 ALL + col2 * 99 col1 FROM tab2 AS cor0
----
2574
2673
3762

query I rowsort
SELECT - col0 * + ( 35 ) + + col2 * - 21 FROM tab0 AS cor0
----
-1246
-1533
-4837

query I rowsort
SELECT col2 + - 9 AS col1 FROM tab1 AS cor0
----
45
48
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9194
SELECT - col0 * - col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9194
SELECT - col0 * - col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL + col0 * - 75 * col1 AS col2 FROM tab2
----
-100725
-16275
-345150

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab1 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 4037d65571c1bbf6e0e7d759f858120e

query I rowsort
SELECT DISTINCT - cor1.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
-26
-27
-38

query I rowsort
SELECT - + cor0.col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT + col2 * - 23 FROM tab1 AS cor0
----
-1242
-1311
-2208

query I rowsort
SELECT col1 * + ( ( col0 ) ) FROM tab2
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9202
SELECT + + cor0.col1 * CAST( 36 AS SIGNED ) - + col1 * + 89 AS col2 FROM tab0 AS cor0
----
-4558
-4823
-5141

skipif mysql # not compatible
query I rowsort label-9202
SELECT + + cor0.col1 * CAST ( 36 AS INTEGER ) - + col1 * + 89 AS col2 FROM tab0 AS cor0
----
-4558
-4823
-5141

query I rowsort
SELECT tab0.col1 * + tab0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 9708a433b981d9b5fd095bfe2ea45aea

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9204
SELECT DISTINCT - cor0.col1 * CAST( NULL AS SIGNED ) + + col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9204
SELECT DISTINCT - cor0.col1 * CAST ( NULL AS INTEGER ) + + col0 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9205
SELECT - - col0 DIV 77 + - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-88

skipif mysql # not compatible
query I rowsort label-9205
SELECT - - col0 / 77 + - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-88

query I rowsort
SELECT - col0 - - 28 AS col1 FROM tab1 AS cor0
----
-36
-52
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-9207
SELECT DISTINCT + col2 + col0 + - 84 * col1 DIV + 80 FROM tab0 AS cor0
----
-33
-65
76

skipif mysql # not compatible
query I rowsort label-9207
SELECT DISTINCT + col2 + col0 + - 84 * col1 / + 80 FROM tab0 AS cor0
----
-33
-65
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9208
SELECT ALL - + col2 - CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
-52
-54
-76

skipif mysql # not compatible
query I rowsort label-9208
SELECT ALL - + col2 - CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT + col2 + + col1 * - col2 FROM tab0 cor0
----
-2805
-7380
-96

query I rowsort
SELECT + col2 * col0 * col1 - col0 AS col1 FROM tab1 AS cor0
----
36416
4209
99760

query I rowsort
SELECT DISTINCT - 30 + + col0 + + col0 AS col1 FROM tab2 AS cor0
----
-16
126
128

query I rowsort
SELECT ALL - + 62 FROM tab0 AS cor0
----
-62
-62
-62

query I rowsort
SELECT + 72 * col2 - col2 FROM tab1 AS cor0
----
3834
4047
6816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col1 col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL col0 + - cor0.col2 * + col0 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9216
SELECT DISTINCT - CAST( + 92 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-92

skipif mysql # not compatible
query I rowsort label-9216
SELECT DISTINCT - CAST ( + 92 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-9217
SELECT + CAST( ( - cor0.col1 ) AS SIGNED ) DIV col2 + - col2 FROM tab0 AS cor0
----
-35
-83
-98

skipif mysql # not compatible
query I rowsort label-9217
SELECT + CAST ( ( - cor0.col1 ) AS INTEGER ) / col2 + - col2 FROM tab0 AS cor0
----
-35
-83
-98

query I rowsort
SELECT ( col1 ) + + col1 * col2 * - col1 FROM tab1 AS cor0
----
-16211
-36478
-5690

query I rowsort
SELECT DISTINCT - 46 + ( col2 ) * - 32 FROM tab2 AS cor0
----
-1262
-878
-910

query I rowsort
SELECT - ( + col2 ) + cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9221
SELECT ALL - CAST( NULL AS SIGNED ) + + col2 * col0 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9221
SELECT ALL - CAST ( NULL AS INTEGER ) + + col2 * col0 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( 27 ) FROM tab0 AS cor0
----
27

query I rowsort
SELECT DISTINCT + 86 * col0 + cor0.col2 * col1 FROM tab0 AS cor0
----
15116
3107
4902

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col2 + col0 col1 FROM tab1 cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 45 col2 FROM tab0 AS cor0
----
45
45
45

query I rowsort
SELECT ALL - ( - 30 ) + - col0 AS col2 FROM tab1 AS cor0
----
-34
-50
27

query I rowsort
SELECT - - col0 * - col0 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT - col1 * - 24 AS col0 FROM tab2
----
1416
408
744

query I rowsort
SELECT ALL + tab0.col1 * - 45 FROM tab0
----
-3870
-4095
-4365

query I rowsort
SELECT col1 * ( col1 ) * - col1 AS col0 FROM tab1
----
-1000
-17576
-2197

query I rowsort
SELECT DISTINCT ( + col2 * col1 ) FROM tab1
----
1248
1404
570

query I rowsort
SELECT 1 * col2 FROM tab2 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9233
SELECT DISTINCT + - col0 + cor0.col0 DIV cor0.col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-9233
SELECT DISTINCT + - col0 + cor0.col0 / cor0.col0 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT DISTINCT + tab1.col1 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
10
13
26

query I rowsort
SELECT 57 + - col0 FROM tab0
----
-32
22
33

query I rowsort
SELECT + - col1 * cor0.col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT cor0.col1 + - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * - 78 + 91 col1 FROM tab1 AS cor0
----
-1937
-689
-923

onlyif mysql # use DIV operator for integer division
query I rowsort label-9239
SELECT col2 DIV - col1 + col1 FROM tab1
----
24
5
6

skipif mysql # not compatible
query I rowsort label-9239
SELECT col2 / - col1 + col1 FROM tab1
----
24
5
6

query I rowsort
SELECT DISTINCT + - col1 * - col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL - col0 + ( col2 ) * + col2 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT - col0 * 85 FROM tab2 AS cor0
----
-595
-6630
-6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-9243
SELECT ALL - col2 + - ( + col2 ) DIV col1 FROM tab2 AS cor0
----
-26
-27
-40

skipif mysql # not compatible
query I rowsort label-9243
SELECT ALL - col2 + - ( + col2 ) / col1 FROM tab2 AS cor0
----
-26
-27
-40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * - col1 * + col1 col1 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT cor0.col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col2 * col0 * + 22 AS col0 FROM tab2
----
4158
44616
66044

onlyif mysql # use DIV operator for integer division
query I rowsort label-9247
SELECT DISTINCT 75 DIV col1 AS col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-9247
SELECT DISTINCT 75 / col1 AS col1 FROM tab1
----
2
5
7

query I rowsort
SELECT col0 - + col1 * + 98 AS col1 FROM tab2
----
-1587
-3031
-5704

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9249
SELECT + col1 + + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9249
SELECT + col1 + + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col0 * + 33 * col1 + + col1 * ( col2 ) AS col1 FROM tab0 cor0
----
-111938
-259805
-65274

query I rowsort
SELECT ALL col0 * - ( col2 ) FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9252
SELECT ALL - + cor0.col2 * + CAST( ( - col2 ) + + col0 AS SIGNED ) FROM tab2 cor0
----
-1352
-1558
540

skipif mysql # not compatible
query I rowsort label-9252
SELECT ALL - + cor0.col2 * + CAST ( ( - col2 ) + + col0 AS INTEGER ) FROM tab2 cor0
----
-1352
-1558
540

query I rowsort
SELECT - col1 * - 75 AS col0 FROM tab2 AS cor0
----
1275
2325
4425

query I rowsort
SELECT + col0 * ( col1 ) * col2 AS col2 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT ALL - col2 + 21 * col2 AS col1 FROM tab1 AS cor0
----
1080
1140
1920

query I rowsort
SELECT col0 + + ( + 10 ) FROM tab2 AS cor0
----
17
88
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9257
SELECT DISTINCT cor0.col0 * - CAST( NULL AS SIGNED ) - col1 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9257
SELECT DISTINCT cor0.col0 * - CAST ( NULL AS INTEGER ) - col1 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + 69 FROM tab2, tab1 cor0 CROSS JOIN tab0
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab1 cor1
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

query I rowsort
SELECT - ( + col1 ) * + cor0.col2 + - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT + col1 + - 39 * col1 AS col2 FROM tab2 AS cor0
----
-1178
-2242
-646

query I rowsort
SELECT ALL + 40 + - col1 + col2 AS col2 FROM tab0
----
-13
-56
31

query I rowsort
SELECT + col1 + + col2 * 30 * + col0 AS col1 FROM tab2 AS cor0
----
5701
60899
90077

query I rowsort
SELECT DISTINCT 65 * - col0 FROM tab2 AS cor0
----
-455
-5070
-5135

query I rowsort
SELECT + 88 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT + cor0.col1 + cor0.col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT 64 * col1 AS col0 FROM tab1
----
1664
640
832

query I rowsort
SELECT ALL tab2.col2 * + col1 - col2 AS col1 FROM tab2
----
1508
608
810

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL > - col2
----

query I rowsort
SELECT ALL tab2.col1 AS col1 FROM tab2 WHERE col1 BETWEEN col2 + col0 AND col2
----

query I rowsort
SELECT DISTINCT - tab2.col2 * col0 AS col1 FROM tab2 WHERE NOT - col2 NOT IN ( + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9272
SELECT + col1 + + col1 + + tab1.col1 DIV + col1 AS col0 FROM tab1
----
21
27
53

skipif mysql # not compatible
query I rowsort label-9272
SELECT + col1 + + col1 + + tab1.col1 / + col1 AS col0 FROM tab1
----
21
27
53

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL <= col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9274
SELECT + col0 * col1 DIV col0 + + col1 * tab2.col1 + col2 AS col2 FROM tab2
----
1019
344
3566

skipif mysql # not compatible
query I rowsort label-9274
SELECT + col0 * col1 / col0 + + col1 * tab2.col1 + col2 AS col2 FROM tab2
----
1019
344
3566

query I rowsort
SELECT - col2 FROM tab2 WHERE NOT ( NULL ) NOT IN ( - tab2.col2 + - col2 * - col1 )
----

query I rowsort
SELECT col1 AS col1 FROM tab0 WHERE NOT + col0 IN ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - col1 - tab2.col2 col1 FROM tab2
----
251
3455
934

query I rowsort
SELECT - col0 - col0 AS col1 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT ALL - col2 - + col2 AS col2 FROM tab0
----
-164
-2
-66

query I rowsort
SELECT ALL + col2 AS col0 FROM tab2 WHERE NOT - col2 BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT - col1 + tab0.col2 AS col1 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - col0 * col2 * col0 + - col1 FROM tab2
----
-1354
-158243
-237175

query I rowsort
SELECT - col1 + - col1 AS col0 FROM tab1
----
-20
-26
-52

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( NULL ) NOT IN ( - col0 * - col0 + - col2 )
----

query I rowsort
SELECT DISTINCT col2 / col1 + + col1 FROM tab2 WHERE ( NULL ) IN ( + col2 * - col2 )
----

query I rowsort
SELECT - col2 + col0 * col1 FROM tab1
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-9287
SELECT col1 DIV col1 + + col1 + col1 * col0 * - col0 AS col0 FROM tab0 AS cor0
----
-118727
-49449
-720719

skipif mysql # not compatible
query I rowsort label-9287
SELECT col1 / col1 + + col1 + col1 * col0 * - col0 AS col0 FROM tab0 AS cor0
----
-118727
-49449
-720719

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col0 + + tab1.col1 * - col1 col1 FROM tab1
----
-185
-727
-93

query I rowsort
SELECT + col1 * col1 - + col0 AS col0 FROM tab0
----
7372
8192
9374

onlyif mysql # use DIV operator for integer division
query I rowsort label-9290
SELECT ALL col1 DIV - tab1.col0 + - col0 FROM tab1
----
-11
-64
-80

skipif mysql # not compatible
query I rowsort label-9290
SELECT ALL col1 / - tab1.col0 + - col0 FROM tab1
----
-11
-64
-80

query I rowsort
SELECT col0 * + tab0.col2 + - col0 AS col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT + col0 * - col2 + tab1.col2 + col0 AS col0 FROM tab1
----
-105
-3527
-7504

query I rowsort
SELECT ALL col0 - tab1.col0 * col0 * + col0 FROM tab1
----
-24
-262080
-511920

query I rowsort
SELECT ALL col0 * - col1 + col2 * - col2 FROM tab1
----
-10256
-2994
-3889

query I rowsort
SELECT ALL col1 * col0 - col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT + 83 FROM tab1, tab2 cor0
----
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col0 * - ( + tab2.col1 ) col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT 79 * col0 - col0 FROM tab0
----
1872
2730
6942

query I rowsort
SELECT ( - col1 * - tab2.col0 ) AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT - - 0 + - 58 FROM tab2 AS cor0
----
-58
-58
-58

query I rowsort
SELECT ALL cor1.col2 + - cor1.col0 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to cd9042ce7b6d5be41db6200432d27198

onlyif mysql # use DIV operator for integer division
query I rowsort label-9302
SELECT + col2 DIV 1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9302
SELECT + col2 / 1 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9303
SELECT + 42 DIV col0 FROM tab1
----
0
0
14

skipif mysql # not compatible
query I rowsort label-9303
SELECT + 42 / col0 FROM tab1
----
0
0
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-9304
SELECT - cor1.col0 DIV - 73 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-9304
SELECT - cor1.col0 / - 73 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9305
SELECT col1 DIV tab1.col2 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9305
SELECT col1 / tab1.col2 AS col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 * - col2 col2 FROM tab0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9307
SELECT + col0 * col2 + CAST( NULL AS SIGNED ) + 95 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9307
SELECT + col0 * col2 + CAST ( NULL AS INTEGER ) + 95 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col0 + + col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - cor0.col0 + col1 * - col2 * + col2 FROM tab2 AS cor0
----
-22606
-24627
-39962

query I rowsort
SELECT DISTINCT - col2 * col2 * - 86 AS col0 FROM tab1 cor0
----
250776
279414
792576

query I rowsort
SELECT ALL - 70 * col1 + - col1 FROM tab0 AS cor0
----
-6106
-6461
-6887

query I rowsort
SELECT + - ( col1 ) + + col0 * - ( cor0.col0 ) FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT DISTINCT 69 * col1 FROM tab0 AS cor0
----
5934
6279
6693

query I rowsort
SELECT ( cor0.col0 ) + + col0 + cor0.col1 FROM tab1 AS cor0
----
138
173
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 42 + + cor0.col0 col2 FROM tab1 AS cor0
----
-123
-2624
-3280

query I rowsort
SELECT - cor0.col0 * + ( - col1 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + cor0.col1 + - col2 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT - - col1 + - col2 * 11 + col0 * col2 * + col2 AS col1 FROM tab0 AS cor0
----
121
25859
597625

query I rowsort
SELECT + col0 * 18 FROM tab0 AS cor0
----
1602
432
630

query I rowsort
SELECT + col0 * 10 * - ( + col2 * col1 ) FROM tab1 cor0
----
-364800
-42120
-998400

onlyif mysql # use DIV operator for integer division
query I rowsort label-9321
SELECT ( col0 ) + 88 + + 86 * col1 DIV ( col1 * + col0 ) AS col1 FROM tab0
----
115
125
177

skipif mysql # not compatible
query I rowsort label-9321
SELECT ( col0 ) + 88 + + 86 * col1 / ( col1 * + col0 ) AS col1 FROM tab0
----
115
125
177

query I rowsort
SELECT DISTINCT - tab2.col1 + col2 + - col2 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT - col1 * col2 + ( 50 ) + col0 * 95 AS col0 FROM tab1
----
-1069
5560
6402

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9324
SELECT col1 * CAST( - col1 AS SIGNED ) + + cor0.col2 AS col2 FROM tab0 cor0
----
-7363
-8199
-9408

skipif mysql # not compatible
query I rowsort label-9324
SELECT col1 * CAST ( - col1 AS INTEGER ) + + cor0.col2 AS col2 FROM tab0 cor0
----
-7363
-8199
-9408

query I rowsort
SELECT + - col1 * - 58 + ( + col0 ) + - col0 FROM tab2 AS cor0
----
1798
3422
986

onlyif mysql # use DIV operator for integer division
query I rowsort label-9326
SELECT tab1.col2 * + tab1.col2 DIV col2 - - col0 FROM tab1
----
121
176
57

skipif mysql # not compatible
query I rowsort label-9326
SELECT tab1.col2 * + tab1.col2 / col2 - - col0 FROM tab1
----
121
176
57

query I rowsort
SELECT + 89 FROM tab1, tab0 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 81 col1 FROM tab1, tab2, tab0 cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

onlyif mysql # use DIV operator for integer division
query I rowsort label-9329
SELECT - CAST( + ( col0 DIV - 85 ) AS SIGNED ) * - col2 DIV + col1 col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9329
SELECT - CAST ( + ( col0 / - 85 ) AS INTEGER ) * - col2 / + col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 85 * col2 FROM tab0 AS cor0
----
2805
6970
85

query I rowsort
SELECT - - 16 + - col2 * + ( ( - col0 ) ) AS col2 FROM tab2 AS cor0
----
2044
205
3018

query I rowsort
SELECT DISTINCT + - 96 * + col0 AS col2 FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT + - col2 - col2 * - ( - col0 ) FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT - col1 * col0 - 48 * + cor0.col1 FROM tab2 AS cor0
----
-1705
-2159
-7434

onlyif mysql # use DIV operator for integer division
query I rowsort label-9335
SELECT - col1 + - col0 * 93 * col2 + - col0 DIV ( col0 ) AS col1 FROM tab1 AS cor0
----
-15093
-339275
-714254

skipif mysql # not compatible
query I rowsort label-9335
SELECT - col1 + - col0 * 93 * col2 + - col0 / ( col0 ) AS col1 FROM tab1 AS cor0
----
-15093
-339275
-714254

query I rowsort
SELECT 5 - - col0 AS col1 FROM tab1 AS cor0
----
69
8
85

query I rowsort
SELECT + ( - col2 + col2 ) FROM tab0
----
0
0
0

query I rowsort
SELECT - 39 - - cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 619228f6c459e8b55ab693a23d79ace1

query I rowsort
SELECT DISTINCT ( 74 ) * + col2 * col0 AS col0 FROM tab1
----
11988
269952
568320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9340
SELECT ALL - col2 * - col1 + - CAST( + 90 + - cor0.col1 AS SIGNED ) * cor0.col0 * col1 FROM tab2 AS cor0
----
-11966
-141128
-97393

skipif mysql # not compatible
query I rowsort label-9340
SELECT ALL - col2 * - col1 + - CAST ( + 90 + - cor0.col1 AS INTEGER ) * cor0.col0 * col1 FROM tab2 AS cor0
----
-11966
-141128
-97393

query I rowsort
SELECT col0 * + cor0.col2 - ( + col1 ) * + col1 AS col0 FROM tab1 AS cor0
----
-514
3548
7511

onlyif mysql # use DIV operator for integer division
query I rowsort label-9342
SELECT DISTINCT + - 58 + - col2 DIV - ( 46 * + col0 ) AS col1 FROM tab2 AS cor0
----
-58

skipif mysql # not compatible
query I rowsort label-9342
SELECT DISTINCT + - 58 + - col2 / - ( 46 * + col0 ) AS col1 FROM tab2 AS cor0
----
-58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9343
SELECT ALL + cor0.col1 * col0 + - CAST( - col2 AS SIGNED ) * - col1 AS col2 FROM tab0 AS cor0
----
-774
3298
637

skipif mysql # not compatible
query I rowsort label-9343
SELECT ALL + cor0.col1 * col0 + - CAST ( - col2 AS INTEGER ) * - col1 AS col2 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT DISTINCT + - ( col1 ) AS col1 FROM tab0 cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col1 * - ( - col0 ) col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT - col1 + + cor0.col1 * col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT + cor0.col1 * - col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + cor0.col1 * + 0 + 67 FROM tab1 AS cor0
----
67
67
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9349
SELECT - col1 * CAST( col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-9349
SELECT - col1 * CAST ( col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - + cor0.col1 + + col0 * col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT 88 * - col0 + - col0 AS col0 FROM tab2 cor0
----
-623
-6942
-7031

query I rowsort
SELECT DISTINCT + col2 * - col1 + - cor0.col2 * col1 FROM tab1 AS cor0
----
-1140
-2496
-2808

query I rowsort
SELECT ALL + + 49 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9354
SELECT ALL CAST( + col0 AS SIGNED ) col2 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9354
SELECT ALL CAST ( + col0 AS INTEGER ) col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL col2 * - ( + col2 ) * - cor0.col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT - ( 20 ) AS col1 FROM tab2 AS cor0
----
-20
-20
-20

query I rowsort
SELECT DISTINCT + ( - 54 ) - - col0 FROM tab0 cor0
----
-19
-30
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( + col1 ) + col2 col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - 4 + - 90 FROM tab2 cor0
----
-94

query I rowsort
SELECT + ( + col1 ) * + col2 * ( - col2 ) FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT - ( + 31 ) FROM tab0 AS cor0
----
-31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9362
SELECT DISTINCT + + CAST( 53 AS SIGNED ) FROM tab2 AS cor0
----
53

skipif mysql # not compatible
query I rowsort label-9362
SELECT DISTINCT + + CAST ( 53 AS INTEGER ) FROM tab2 AS cor0
----
53

query I rowsort
SELECT ALL - cor0.col2 * col1 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT - + col1 + + cor0.col0 * - col0 FROM tab2 AS cor0
----
-6143
-6258
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9365
SELECT DISTINCT col1 DIV cor0.col1 - + 49 * - col1 AS col0 FROM tab0 AS cor0
----
4215
4460
4754

skipif mysql # not compatible
query I rowsort label-9365
SELECT DISTINCT col1 / cor0.col1 - + 49 * - col1 AS col0 FROM tab0 AS cor0
----
4215
4460
4754

query I rowsort
SELECT - col2 * + 24 * col0 AS col1 FROM tab1 cor0
----
-184320
-3888
-87552

query I rowsort
SELECT ALL + 53 * tab2.col0 FROM tab2
----
371
4134
4187

query I rowsort
SELECT - 13 * + 63 FROM tab0 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 92062dee70367cda7010ec9a8a62bfc7

query I rowsort
SELECT - col2 * col1 * col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT col0 + + 31 FROM tab2
----
109
110
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9371
SELECT ALL CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9371
SELECT ALL CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col1 + - col2 * col1 * col2 col2 FROM tab1
----
-119795
-32480
-75790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9373
SELECT tab2.col1 + CAST( NULL AS SIGNED ) / col0 col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9373
SELECT tab2.col1 + CAST ( NULL AS INTEGER ) / col0 col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab1, tab2, tab1 cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9375
SELECT ALL col2 + - CAST( - col1 + + col2 AS SIGNED ) * + col2 * + col2 FROM tab0
----
57750
60598
97

skipif mysql # not compatible
query I rowsort label-9375
SELECT ALL col2 + - CAST ( - col1 + + col2 AS INTEGER ) * + col2 * + col2 FROM tab0
----
57750
60598
97

query I rowsort
SELECT DISTINCT + col2 + col0 * + col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT - col0 - + col2 * col2 AS col2 FROM tab1
----
-2919
-3313
-9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-9378
SELECT ALL col1 DIV 46 AS col0 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9378
SELECT ALL col1 / 46 AS col0 FROM tab2 cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 84 col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

query I rowsort
SELECT - + cor0.col1 + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - ( col1 ) + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 - col2 * + col1 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 col2 FROM tab0, tab0 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

onlyif mysql # use DIV operator for integer division
query I rowsort label-9384
SELECT ALL + + col1 DIV col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-9384
SELECT ALL + + col1 / col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT DISTINCT + col2 * - col0 + - cor0.col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT + col1 * col2 + + col1 AS col1 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-9387
SELECT - + 27 DIV col0 + + col1 AS col1 FROM tab0 AS cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-9387
SELECT - + 27 / col0 + + col1 AS col1 FROM tab0 AS cor0
----
85
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9388
SELECT DISTINCT col2 * cor0.col0 DIV + 18 - - cor0.col0 * - col1 FROM tab1 cor0
----
-438
-614
-69

skipif mysql # not compatible
query I rowsort label-9388
SELECT DISTINCT col2 * cor0.col0 / + 18 - - cor0.col0 * - col1 FROM tab1 cor0
----
-438
-614
-69

query I rowsort
SELECT + - 30 * col0 + col1 AS col0 FROM tab0 AS cor0
----
-2579
-634
-953

query I rowsort
SELECT DISTINCT + - 85 + col0 * ( col0 * col1 ) AS col1 FROM tab2 cor0
----
106012
1434
358871

query I rowsort
SELECT ALL - col0 * - col2 * - col1 AS col1 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + + 55 * - col0 FROM tab1 AS cor0
----
-165
-3520
-4400

query I rowsort
SELECT ALL col1 * - col0 + col1 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - - cor0.col2 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - col1 + ( col0 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT 61 * col2 - col2 FROM tab0 AS cor0
----
1980
4920
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - col1 * col0 col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - - ( 82 ) * + col1 * + cor0.col1 FROM tab2 AS cor0
----
23698
285442
78802

query I rowsort
SELECT ALL + col1 + + cor0.col1 * col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT + cor0.col0 - - col1 * col1 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT ( col1 ) * - col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) + - col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT ALL cor0.col1 * cor0.col2 + + cor0.col1 - - col0 AS col2 FROM tab0 AS cor0
----
229
2948
7642

query I rowsort
SELECT - ( col0 ) + col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT cor1.col2 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 85 * col2 - col1 col0 FROM tab2 cor0
----
-2269
-2326
-3247

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col2 - - col1 col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT - 2 + ( + col2 ) * - 21 AS col0 FROM tab0 cor0
----
-1724
-23
-695

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 6 ) col2 FROM tab0 AS cor0
----
6
6
6

query I rowsort
SELECT cor0.col1 + - col2 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + 55 + - col2 FROM tab0
----
-27
22
54

query I rowsort
SELECT ( 29 ) AS col0 FROM tab1
----
29
29
29

query I rowsort
SELECT + 90 * 70 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 85552e00c925d58097ff11f098feef21

query I rowsort
SELECT + + 48 * - col1 AS col1 FROM tab2 AS cor0
----
-1488
-2832
-816

query I rowsort
SELECT - - 31 * col1 - + 68 FROM tab1 AS cor0
----
242
335
738

query I rowsort
SELECT - + col2 + col1 * col2 AS col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - col0 * + col0 + col2 * ( - col1 + - col2 ) AS col0 FROM tab2 AS cor0
----
-1615
-8294
-8331

query I rowsort
SELECT ALL - tab1.col0 + - ( col0 ) FROM tab1
----
-128
-160
-6

query I rowsort
SELECT 31 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT DISTINCT 55 AS col0 FROM tab1, tab2 cor0, tab2 AS cor1
----
55

query I rowsort
SELECT - - col2 * col2 + cor0.col0 * + col2 FROM tab2 AS cor0
----
2704
4446
918

query I rowsort
SELECT - - col1 * col2 - - col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + 63 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
63

query I rowsort
SELECT col1 + + col1 * col1 AS col1 FROM tab1 cor0
----
110
182
702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col0 col1 FROM tab1
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9427
SELECT DISTINCT + col2 * + CAST( NULL AS SIGNED ) / col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9427
SELECT DISTINCT + col2 * + CAST ( NULL AS INTEGER ) / col2 FROM tab2
----
NULL

query I rowsort
SELECT ALL + col1 * - 46 FROM tab0 cor0
----
-3956
-4186
-4462

query I rowsort
SELECT 44 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT ALL + cor0.col2 + - col0 * col1 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT ALL - - ( 0 ) * col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col1 + 81 FROM tab2 AS cor0
----
112
140
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9433
SELECT DISTINCT + + CAST( NULL AS SIGNED ) / cor0.col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9433
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) / cor0.col0 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + 44 * + col1 col0 FROM tab2 AS cor0
----
1337
2570
710

onlyif mysql # use DIV operator for integer division
query I rowsort label-9435
SELECT - col2 + + 70 DIV col0 FROM tab1 AS cor0
----
-31
-56
-96

skipif mysql # not compatible
query I rowsort label-9435
SELECT - col2 + + 70 / col0 FROM tab1 AS cor0
----
-31
-56
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9436
SELECT ALL + 19 DIV col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
64
80
9

skipif mysql # not compatible
query I rowsort label-9436
SELECT ALL + 19 / col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
64
80
9

query I rowsort
SELECT ALL + ( 32 + tab1.col1 ) * tab1.col1 AS col1 FROM tab1
----
1508
420
585

query I rowsort
SELECT + 37 + 5 * + col0 FROM tab2 AS cor0
----
427
432
72

query I rowsort
SELECT - - 2 * 91 FROM tab1 AS cor0
----
182
182
182

query I rowsort
SELECT - 62 * 73 AS col2 FROM tab1 AS cor0
----
-4526
-4526
-4526

query I rowsort
SELECT + cor0.col1 * col2 + + ( - col1 ) FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT - cor0.col2 + + col1 * 41 FROM tab0 AS cor0
----
3493
3649
3976

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9443
SELECT ALL + col0 + CAST( col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-9443
SELECT ALL + col0 + CAST ( col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT col0 * ( ( + col2 ) ) AS col2 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 42 + - col2 col0 FROM tab0
----
-40
41
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + 97 + - col2 * - CAST ( + col2 AS REAL ) + tab0.col0 * col1 col2 FROM tab0
----
14920
3250
3493

onlyif mysql # use DIV operator for integer division
query I rowsort label-9447
SELECT DISTINCT + 75 DIV - col1 AS col1 FROM tab2
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-9447
SELECT DISTINCT + 75 / - col1 AS col1 FROM tab2
----
-1
-2
-4

query I rowsort
SELECT tab0.col0 * - col2 + 89 AS col2 FROM tab0
----
-703
-7209
54

query I rowsort
SELECT col0 - 4 FROM tab0
----
20
31
85

query I rowsort
SELECT DISTINCT col2 * - col2 + ( col0 ) FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT + col2 * 22 AS col2 FROM tab0 AS cor0
----
1804
22
726

onlyif mysql # use DIV operator for integer division
query I rowsort label-9452
SELECT ALL 77 DIV col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9452
SELECT ALL 77 / col2 FROM tab1
----
0
1
1

query I rowsort
SELECT - ( ( col1 ) ) * + col0 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT 26 * tab1.col1 * tab1.col0 AS col0 FROM tab1
----
16640
2028
27040

query I rowsort
SELECT + cor1.col2 + ( - 7 ) AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a0ad735de0d814343239a5ef52f5f545

query I rowsort
SELECT ALL 69 - - col1 * tab0.col0 FROM tab0
----
2133
3464
8168

query I rowsort
SELECT - col0 + - col1 + + col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - col0 + col2 + 47 * cor0.col1 * + col1 AS col0 FROM tab2 cor0
----
13542
163555
45187

query I rowsort
SELECT DISTINCT + 74 + col0 AS col1 FROM tab0 AS cor0
----
109
163
98

query I rowsort
SELECT 3 * + col2 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT ALL - - 55 * col1 * - 31 FROM tab2 AS cor0
----
-100595
-28985
-52855

query I rowsort
SELECT 78 AS col0 FROM tab2 cor0
----
78
78
78

query I rowsort
SELECT ALL + 56 + col0 + - 85 AS col2 FROM tab2 AS cor0
----
-22
49
50

query I rowsort
SELECT DISTINCT - 71 * col1 AS col0 FROM tab2 AS cor0
----
-1207
-2201
-4189

onlyif mysql # use DIV operator for integer division
query I rowsort label-9465
SELECT + + 20 DIV cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9465
SELECT + + 20 / cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 32 AS col2 FROM tab2 cor0
----
-32
-32
-32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( tab0.col0 ) + + ( - col1 * - col2 ) col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL + 57 + tab0.col1 FROM tab0
----
143
148
154

query I rowsort
SELECT - ( tab1.col1 ) * - col1 FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - 59 * - col1 + col2 FROM tab0 cor0
----
5107
5451
5724

query I rowsort
SELECT col2 + col1 - col1 AS col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9473
SELECT ALL - col2 * col2 + - CAST( col0 AS SIGNED ) FROM tab1 cor0
----
-2919
-3313
-9296

skipif mysql # not compatible
query I rowsort label-9473
SELECT ALL - col2 * col2 + - CAST ( col0 AS INTEGER ) FROM tab1 cor0
----
-2919
-3313
-9296

query I rowsort
SELECT + - col2 + - col0 * 29 FROM tab2 AS cor0
----
-2288
-230
-2329

query I rowsort
SELECT ALL - col1 - - col0 AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL col1 + col2 - - 18 AS col2 FROM tab1 AS cor0
----
127
85
98

query I rowsort
SELECT ALL + 52 * col0 + col0 AS col1 FROM tab1 AS cor0
----
159
3392
4240

query I rowsort
SELECT ALL - col1 * - col1 * ( - col1 ) FROM tab1 cor0
----
-1000
-17576
-2197

query I rowsort
SELECT + col0 + col1 * col2 AS col0 FROM tab2 cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9480
SELECT ALL 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-9480
SELECT ALL col1 + + CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col2 * col2 + col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1352
-1458
-2888

query I rowsort
SELECT DISTINCT col0 * col1 * + 12 FROM tab2 cor0
----
16116
2604
55224

query I rowsort
SELECT col2 * ( + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT col1 + + ( - cor0.col2 ) FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9485
SELECT DISTINCT - col1 DIV col0 FROM tab1 cor0
----
-8
0

skipif mysql # not compatible
query I rowsort label-9485
SELECT DISTINCT - col1 / col0 FROM tab1 cor0
----
-8
0

query I rowsort
SELECT - cor0.col0 + ( col0 ) * col2 * - 19 FROM tab2 cor0
----
-3598
-38610
-57117

query I rowsort
SELECT + tab1.col1 + + tab1.col2 AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL col0 * col2 + col2 * 92 * - col1 + tab2.col2 FROM tab2
----
-139074
-56392
-76788

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col1 * col2 col1 FROM tab1
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col0 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT cor0.col2 - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + col0 + - 43 AS col1 FROM tab0 AS cor0
----
-19
-8
46

query I rowsort
SELECT col2 * 52 * - col0 FROM tab2 AS cor0
----
-105456
-156104
-9828

query I rowsort
SELECT ALL - - col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL + 70 + - cor0.col2 + - col0 AS col0 FROM tab1 cor0
----
-106
-51
13

query I rowsort
SELECT ALL 27 * - cor0.col2 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT + + ( + 26 ) FROM tab2 AS cor0
----
26
26
26

query I rowsort
SELECT DISTINCT - 36 AS col2 FROM tab0 AS cor0
----
-36

query I rowsort
SELECT DISTINCT + cor0.col0 + + 78 FROM tab0 AS cor0
----
102
113
167

query I rowsort
SELECT + 86 + cor0.col2 AS col2 FROM tab1 AS cor0
----
140
143
182

query I rowsort
SELECT DISTINCT + + col2 * + col2 + cor0.col2 + 32 AS col1 FROM tab0 AS cor0
----
1154
34
6838

query I rowsort
SELECT - + 62 + + col1 * - col0 FROM tab0 AS cor0
----
-2126
-3457
-8161

query I rowsort
SELECT ALL - + col1 * - 89 FROM tab0 cor0
----
7654
8099
8633

query I rowsort
SELECT - ( col0 ) * col1 * 42 FROM tab2 AS cor0
----
-193284
-56406
-9114

query I rowsort
SELECT + col1 - - 82 FROM tab1
----
108
92
95

query I rowsort
SELECT - 2 + + 67 AS col0 FROM tab0
----
65
65
65

query I rowsort
SELECT ALL + col0 * + col0 + col0 FROM tab1 cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + - col2 col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + 84 AS col2 FROM tab2 AS cor0
----
84

query I rowsort
SELECT + ( cor0.col2 ) * - col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9511
SELECT DISTINCT - 14 * ( + col1 ) + - CAST( NULL AS DECIMAL ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9511
SELECT DISTINCT - 14 * ( + col1 ) + - CAST ( NULL AS REAL ) FROM tab2
----
NULL

query I rowsort
SELECT + col2 * col1 * col1 + + tab2.col1 AS col1 FROM tab2
----
10999
25978
90565

query I rowsort
SELECT DISTINCT col2 * - tab0.col2 - tab0.col1 FROM tab0
----
-1175
-6815
-98

query I rowsort
SELECT - col1 - tab1.col2 AS col1 FROM tab1
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9515
SELECT DISTINCT - tab1.col1 DIV - tab1.col1 + - col0 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-9515
SELECT DISTINCT - tab1.col1 / - tab1.col1 + - col0 FROM tab1
----
-2
-63
-79

query I rowsort
SELECT - col0 * 13 * col0 FROM tab2
----
-637
-79092
-81133

query I rowsort
SELECT ALL + col1 * col0 + col1 + - col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + col1 * - 81 + col1 + ( ( - col0 ) ) FROM tab2 AS cor0
----
-1439
-2487
-4798

query I rowsort
SELECT + col2 * + col0 + cor0.col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL tab2.col1 * ( + cor0.col1 ) AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 4307a5c67912e63c47b74283c0988b96

query I rowsort
SELECT DISTINCT + col1 * + col2 + col2 * col1 FROM tab1
----
1140
2496
2808

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 18 col1 FROM tab2, tab2 cor0
----
18

query I rowsort
SELECT col2 + - 48 * - col0 * + cor0.col0 FROM tab0 AS cor0
----
27681
380290
58801

query I rowsort
SELECT ( - cor0.col2 ) * - col1 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9525
SELECT ALL + CAST( NULL AS SIGNED ) * col0 / cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9525
SELECT ALL + CAST ( NULL AS INTEGER ) * col0 / cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 99 col2 FROM tab1 AS cor0
----
-99

query I rowsort
SELECT DISTINCT + - 36 * col1 FROM tab1 AS cor0
----
-360
-468
-936

query I rowsort
SELECT DISTINCT - 83 * col1 FROM tab0 AS cor0
----
-7138
-7553
-8051

query I rowsort
SELECT - 44 + + col2 AS col2 FROM tab1 cor0
----
10
13
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * cor0.col2 col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9531
SELECT DISTINCT + + CAST( NULL AS DECIMAL ) AS col0 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9531
SELECT DISTINCT + + CAST ( NULL AS REAL ) AS col0 FROM tab0 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9532
SELECT col2 * col0 DIV cor0.col1 + col2 FROM tab0 AS cor0
----
1
162
42

skipif mysql # not compatible
query I rowsort label-9532
SELECT col2 * col0 / cor0.col1 + col2 FROM tab0 AS cor0
----
1
162
42

query I rowsort
SELECT ( + 12 ) AS col2 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT ALL 80 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT DISTINCT - - col2 + col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL - 47 * + cor0.col1 FROM tab2 cor0
----
-1457
-2773
-799

query I rowsort
SELECT DISTINCT - + 31 FROM tab2 AS cor0
----
-31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 col1 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL ( + tab2.col1 + col2 ) AS col1 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-9540
SELECT - tab1.col2 DIV + 41 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to a09c4c369fd6ef06f439ccfa3d3e0b51

skipif mysql # not compatible
query I rowsort label-9540
SELECT - tab1.col2 / + 41 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to a09c4c369fd6ef06f439ccfa3d3e0b51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 80 col2 FROM tab2 cor0
----
-80
-80
-80

query I rowsort
SELECT DISTINCT + cor0.col1 * col0 + + 54 FROM tab0 AS cor0
----
2118
3449
8153

query I rowsort
SELECT DISTINCT - + cor0.col0 * - 83 FROM tab0 AS cor0
----
1992
2905
7387

onlyif mysql # use DIV operator for integer division
query I rowsort label-9544
SELECT col1 DIV 32 FROM tab0
----
2
2
3

skipif mysql # not compatible
query I rowsort label-9544
SELECT col1 / 32 FROM tab0
----
2
2
3

query I rowsort
SELECT + - cor0.col1 + + col2 * col2 AS col0 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT col0 * - 49 FROM tab2 AS cor0
----
-343
-3822
-3871

query I rowsort
SELECT + + col0 - - cor0.col0 AS col2 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-9548
SELECT - + col1 DIV 91 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9548
SELECT - + col1 / 91 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + 61 FROM tab0 AS cor0
----
-21
28
60

query I rowsort
SELECT cor0.col2 * - ( 78 ) FROM tab1 AS cor0
----
-4212
-4446
-7488

query I rowsort
SELECT ALL + - col2 * - cor0.col2 + cor0.col2 FROM tab0 cor0
----
1122
2
6806

query I rowsort
SELECT - - 71 + - col1 AS col0 FROM tab1 AS cor0
----
45
58
61

query I rowsort
SELECT + col1 * + 51 FROM tab2 AS cor0
----
1581
3009
867

query I rowsort
SELECT col2 + + col2 * + col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9555
SELECT - ( col1 ) * col1 - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9555
SELECT - ( col1 ) * col1 - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 61 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 51f53697966a79d306a4570537cd91a1

query I rowsort
SELECT DISTINCT + + col2 * + col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT + col1 * - ( 89 ) FROM tab2
----
-1513
-2759
-5251

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col2 col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ( 38 ) AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 79 * 19 col0 FROM tab0
----
-1501
-1501
-1501

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9563
SELECT DISTINCT col1 + CAST( 95 AS SIGNED ) + - col1 * col2 col0 FROM tab1 cor0
----
-1140
-1283
-465

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9563
SELECT DISTINCT col1 + CAST ( 95 AS INTEGER ) + - col1 * col2 col0 FROM tab1 cor0
----
-1140
-1283
-465

query I rowsort
SELECT ALL + 82 FROM tab1
----
82
82
82

query I rowsort
SELECT + 93 * col1 FROM tab1 AS cor0
----
1209
2418
930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col1 ) col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + 45 * tab1.col1 AS col1 FROM tab1
----
1170
450
585

query I rowsort
SELECT col0 * col2 * - col0 AS col2 FROM tab0 cor0
----
-1225
-19008
-649522

query I rowsort
SELECT - 8 * col1 + + col1 FROM tab0 AS cor0
----
-602
-637
-679

query I rowsort
SELECT col1 * tab2.col0 * col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT ALL - 11 * + col2 AS col1 FROM tab2 AS cor0
----
-286
-297
-418

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9572
SELECT DISTINCT + CAST( - 37 AS SIGNED ) * + col1 * col1 FROM tab2
----
-10693
-128797
-35557

skipif mysql # not compatible
query I rowsort label-9572
SELECT DISTINCT + CAST ( - 37 AS INTEGER ) * + col1 * col1 FROM tab2
----
-10693
-128797
-35557

query I rowsort
SELECT ALL 8 + + col2 * col2 AS col1 FROM tab0
----
1097
6732
9

query I rowsort
SELECT DISTINCT + cor0.col0 + - col1 + - col0 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - + 55 * col1 + + col0 AS col2 FROM tab0 cor0
----
-4706
-4916
-5300

query I rowsort
SELECT DISTINCT + ( + col1 ) + - col1 AS col0 FROM tab1
----
0

query I rowsort
SELECT DISTINCT 8 + + col0 AS col2 FROM tab0
----
32
43
97

query I rowsort
SELECT + 82 * col2 AS col2 FROM tab2
----
2132
2214
3116

query I rowsort
SELECT + ( col2 * col2 ) + col1 AS col2 FROM tab0
----
1175
6815
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 9 col0 FROM tab1
----
9
9
9

query I rowsort
SELECT - 56 - 35 * col0 FROM tab0
----
-1281
-3171
-896

query I rowsort
SELECT col0 + - 85 FROM tab1
----
-21
-5
-82

query I rowsort
SELECT + 41 - - col1 AS col2 FROM tab0
----
127
132
138

query I rowsort
SELECT col0 * + col1 + col2 AS col2 FROM tab2
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( ( + col2 ) ) + col0 col2 FROM tab0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9586
SELECT ALL CAST( col2 AS SIGNED ) + - tab0.col1 FROM tab0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-9586
SELECT ALL CAST ( col2 AS INTEGER ) + - tab0.col1 FROM tab0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col1 col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + 12 AS col2 FROM tab0
----
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 * col0 col2 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9590
SELECT - col1 * col2 DIV - col0 AS col2 FROM tab2
----
119
19
8

skipif mysql # not compatible
query I rowsort label-9590
SELECT - col1 * col2 / - col0 AS col2 FROM tab2
----
119
19
8

query I rowsort
SELECT - col1 - 37 * - col0 FROM tab0 AS cor0
----
1198
3202
802

query I rowsort
SELECT - + col0 * + col1 + - col2 AS col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT - - col1 + ( cor0.col1 ) * + col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT col1 * 17 FROM tab2 AS cor0
----
1003
289
527

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0, tab1 AS cor0 WHERE NULL >= NULL
----

query I rowsort
SELECT ALL 51 AS col0 FROM tab1
----
51
51
51

query I rowsort
SELECT DISTINCT 9 * - col0 FROM tab1
----
-27
-576
-720

query I rowsort
SELECT - 39 AS col0 FROM tab2
----
-39
-39
-39

query I rowsort
SELECT DISTINCT tab2.col1 - - col0 FROM tab2
----
137
38
96

query I rowsort
SELECT col0 * + 6 FROM tab2
----
42
468
474

query I rowsort
SELECT col0 + col1 * 43 FROM tab2 AS cor0
----
1340
2615
810

query I rowsort
SELECT + col2 * ( col2 ) - - col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT col0 * + col2 + col1 FROM tab2 cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-9604
SELECT ALL col2 * tab1.col2 + + tab1.col2 * col1 * + col1 - - col0 DIV - col2 FROM tab1
----
25440
39420
8948

skipif mysql # not compatible
query I rowsort label-9604
SELECT ALL col2 * tab1.col2 + + tab1.col2 * col1 * + col1 - - col0 / - col2 FROM tab1
----
25440
39420
8948

query I rowsort
SELECT ALL col2 * + col0 - col1 FROM tab1
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-9606
SELECT + col2 + col1 DIV col2 FROM tab0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-9606
SELECT + col2 + col1 / col2 FROM tab0
----
35
83
98

query I rowsort
SELECT ALL col1 * - col0 - - col2 AS col1 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT col2 * col1 + + col0 - - tab1.col1 AS col0 FROM tab1
----
1341
1433
644

query I rowsort
SELECT col1 + col1 * col1 * - col2 FROM tab2
----
-10965
-25916
-90447

onlyif mysql # use DIV operator for integer division
query I rowsort label-9610
SELECT ALL - col2 * - cor0.col0 DIV + col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-9610
SELECT ALL - col2 * - cor0.col0 / + col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL tab1.col2 - + col1 FROM tab1
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + tab2.col1 col2 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL col0 + col2 * tab2.col0 AS col1 FROM tab2
----
196
2106
3081

query I rowsort
SELECT DISTINCT col0 * - col2 + - col0 AS col1 FROM tab0
----
-70
-7387
-816

query I rowsort
SELECT + col2 + + col1 * col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT cor0.col1 * + col1 + - col0 + col1 AS col0 FROM tab2 AS cor0
----
227
3462
985

query I rowsort
SELECT DISTINCT + + col2 + col0 * col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL cor0.col2 + + col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + cor0.col2 * col2 AS col1 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT ALL - tab2.col0 * - col1 + col1 + col1 FROM tab2
----
1377
279
4720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - cor0.col1 col2 FROM tab0 cor0
----
-172
-182
-194

query I rowsort
SELECT ALL - + cor0.col0 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT + col1 BETWEEN col2 AND NULL OR NOT NULL NOT BETWEEN ( NULL ) AND col1 - + col0
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

onlyif mysql # use DIV operator for integer division
query I rowsort label-9624
SELECT ALL cor0.col0 DIV - cor0.col2 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9624
SELECT ALL cor0.col0 / - cor0.col2 FROM tab1 cor0
----
-1
0
0

query I rowsort
SELECT col2 + - cor0.col1 + col0 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT DISTINCT - - col0 + col2 * + col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT - 13 + - col0 FROM tab1
----
-16
-77
-93

query I rowsort
SELECT ALL + - ( - cor0.col2 ) + col0 * col0 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT ALL ( col1 ) + - col0 * - col2 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
2146
251
3036

query I rowsort
SELECT DISTINCT cor0.col2 * - col0 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT 30 AS col1 FROM tab1 AS cor0
----
30
30
30

query I rowsort
SELECT DISTINCT + - col2 + col0 * cor0.col0 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT DISTINCT 53 - col0 FROM tab0 AS cor0
----
-36
18
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 14 col2 FROM tab1 AS cor0
----
14
14
14

query I rowsort
SELECT ALL + col0 + col2 * col2 AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL - - col2 * - col1 + - col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT + - cor0.col1 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col2 + - col1 * col0 col1 FROM tab2 AS cor0
----
-406
-4345
-6630

query I rowsort
SELECT ALL - + cor0.col2 + col2 * cor0.col0 AS col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - col2 * - cor0.col1 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9641
SELECT + tab0.col1 DIV col2 + + col2 col1 FROM tab0
----
35
83
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9641
SELECT + tab0.col1 / col2 + + col2 col1 FROM tab0
----
35
83
98

query I rowsort
SELECT ALL col1 * - col1 + - col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT 30 * - col0 AS col2 FROM tab0 AS cor0
----
-1050
-2670
-720

query I rowsort
SELECT 83 AS col1 FROM tab0 AS cor0
----
83
83
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9645
SELECT col0 * col1 + col2 * - col1 DIV + col1 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

skipif mysql # not compatible
query I rowsort label-9645
SELECT col0 * col1 + col2 * - col1 / + col1 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col2 * col1 col0 FROM tab1 cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT col2 + col1 * + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT - col1 * cor0.col2 + 3 FROM tab1 AS cor0
----
-1245
-1401
-567

onlyif mysql # use DIV operator for integer division
query I rowsort label-9649
SELECT + col0 DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-9649
SELECT + col0 / cor0.col2 AS col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT - tab0.col1 + - col1 * - tab0.col1 AS col2 FROM tab0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT - 82 + - col2 + - col0 FROM tab1 AS cor0
----
-139
-203
-258

query I rowsort
SELECT col2 * + col1 - col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL 77 FROM tab1
----
77
77
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-9654
SELECT DISTINCT + col1 DIV + col2 AS col1 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-9654
SELECT DISTINCT + col1 / + col2 AS col1 FROM tab0
----
1
2
97

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 cor2
----
972 values hashing to 75a813ebd5ec5ec2e67a66d0593ff763

onlyif mysql # use DIV operator for integer division
query I rowsort label-9656
SELECT DISTINCT - col0 + col2 DIV col1 AS col0 FROM tab2 cor0
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-9656
SELECT DISTINCT - col0 + col2 / col1 AS col0 FROM tab2 cor0
----
-7
-77
-78

query I rowsort
SELECT ( + 10 ) FROM tab0
----
10
10
10

query I rowsort
SELECT + 75 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT ALL + - 78 AS col0 FROM tab0 cor0
----
-78
-78
-78

query I rowsort
SELECT DISTINCT - cor0.col0 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
-7
-78
-79

query I rowsort
SELECT - ( + 58 ) * - col2 * + col2 FROM tab2 AS cor0
----
39208
42282
83752

query I rowsort
SELECT - ( + ( + col0 ) ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9663
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab0 cor0, tab2 AS cor1, tab1 AS cor2
----
NULL

skipif mysql # not compatible
query I rowsort label-9663
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab0 cor0, tab2 AS cor1, tab1 AS cor2
----
NULL

query I rowsort
SELECT ALL + + ( cor0.col0 ) * + col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-9665
SELECT CAST( + col1 AS SIGNED ) DIV - col0 AS col1 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-9665
SELECT CAST ( + col1 AS INTEGER ) / - col0 AS col1 FROM tab2 AS cor0
----
-4
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9666
SELECT DISTINCT + - CAST( col0 AS SIGNED ) + - cor0.col1 col2 FROM tab2 AS cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9666
SELECT DISTINCT + - CAST ( col0 AS INTEGER ) + - cor0.col1 col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT + + 58 + cor0.col1 AS col0 FROM tab2 AS cor0
----
117
75
89

query I rowsort
SELECT - 94 * 84 FROM tab0 AS cor0
----
-7896
-7896
-7896

onlyif mysql # use DIV operator for integer division
query I rowsort label-9669
SELECT + - col0 * 68 DIV col1 AS col2 FROM tab0 AS cor0
----
-18
-24
-66

skipif mysql # not compatible
query I rowsort label-9669
SELECT + - col0 * 68 / col1 AS col2 FROM tab0 AS cor0
----
-18
-24
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-9670
SELECT DISTINCT col1 DIV 3 AS col0 FROM tab1
----
3
4
8

skipif mysql # not compatible
query I rowsort label-9670
SELECT DISTINCT col1 / 3 AS col0 FROM tab1
----
3
4
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-9671
SELECT - col0 DIV 22 AS col1 FROM tab0 AS cor0
----
-1
-1
-4

skipif mysql # not compatible
query I rowsort label-9671
SELECT - col0 / 22 AS col1 FROM tab0 AS cor0
----
-1
-1
-4

query I rowsort
SELECT - 63 FROM tab1, tab2 AS cor0
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9673
SELECT - CAST( NULL AS SIGNED ) * - 48 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9673
SELECT - CAST ( NULL AS INTEGER ) * - 48 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 20 * cor0.col2 FROM tab2 AS cor0
----
-520
-540
-760

query I rowsort
SELECT + 57 * + cor0.col0 FROM tab2 AS cor0
----
399
4446
4503

query I rowsort
SELECT ALL - col2 * - 81 + col2 * col2 FROM tab1 AS cor0
----
16992
7290
7866

query I rowsort
SELECT DISTINCT col1 * - col0 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT col1 - ( + col1 ) AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9679
SELECT cor0.col2 - - col1 DIV - col2 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9679
SELECT cor0.col2 - - col1 / - col2 AS col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9680
SELECT - col0 DIV 94 + + col2 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-9680
SELECT - col0 / 94 + + col2 FROM tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * col0 col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - - 71 * + 32 FROM tab1 AS cor0
----
2272
2272
2272

query I rowsort
SELECT ALL - col0 * 49 * + col0 AS col2 FROM tab2
----
-2401
-298116
-305809

query I rowsort
SELECT ALL 77 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT + tab1.col2 * ( + 2 ) FROM tab1
----
108
114
192

query I rowsort
SELECT ALL col1 - - ( col0 ) AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT - col0 * - col0 + - col0 AS col1 FROM tab1
----
4032
6
6320

query I rowsort
SELECT col2 - ( cor0.col0 ) FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT - + col0 * 21 AS col0 FROM tab2 AS cor0
----
-147
-1638
-1659

query I rowsort
SELECT - col0 * - 63 FROM tab1 AS cor0
----
189
4032
5040

query I rowsort
SELECT DISTINCT + col0 + - 49 * - cor0.col1 FROM tab2 AS cor0
----
1526
2969
912

query I rowsort
SELECT DISTINCT + + col1 * 42 * + col0 AS col0 FROM tab2 AS cor0
----
193284
56406
9114

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9693
SELECT col2 + + CAST( NULL AS SIGNED ) + col1 * + col1 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9693
SELECT col2 + + CAST ( NULL AS INTEGER ) + col1 * + col1 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + + col0 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL col1 * + cor0.col0 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9696
SELECT DISTINCT ( 10 ) DIV + col2 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9696
SELECT DISTINCT ( 10 ) / + col2 AS col1 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9697
SELECT ALL CAST( - col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-9697
SELECT ALL CAST ( - col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + col1 + - col0 * col0 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT - ( - 67 ) FROM tab0 AS cor0
----
67

query I rowsort
SELECT 85 * + col0 AS col0 FROM tab0 AS cor0
----
2040
2975
7565

query I rowsort
SELECT - - ( + col2 ) * + col1 + + col2 + col1 * col2 FROM tab2 cor0
----
1330
1701
3094

query I rowsort
SELECT col2 + + 82 AS col0 FROM tab0 AS cor0
----
115
164
83

query I rowsort
SELECT DISTINCT + + 96 FROM tab1 AS cor0
----
96

query I rowsort
SELECT DISTINCT 1 + + 94 AS col2 FROM tab1, tab2 AS cor0
----
95

query I rowsort
SELECT + ( - 89 ) * col2 AS col1 FROM tab0 AS cor0
----
-2937
-7298
-89

query I rowsort
SELECT ALL ( + 57 ) FROM tab1 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT + col0 + col0 * - col1 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9708
SELECT + CAST( NULL AS DECIMAL ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9708
SELECT + CAST ( NULL AS REAL ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 17 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 71801088bb30ca6eac036729ebfbbace

query I rowsort
SELECT + + col2 + - col1 * col1 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT - col1 * col1 + 90 FROM tab2 AS cor0
----
-199
-3391
-871

query I rowsort
SELECT ALL + 98 + + col1 + col1 FROM tab2 AS cor0
----
132
160
216

query I rowsort
SELECT ALL ( col1 ) * col1 + - ( - cor0.col0 + + 75 ) * col0 * col2 FROM tab1 AS cor0
----
-10988
-40028
38569

query I rowsort
SELECT ALL - col0 * - cor0.col2 + 98 FROM tab2 cor0
----
2126
287
3100

query I rowsort
SELECT ALL 23 + + col1 AS col0 FROM tab1 AS cor0
----
33
36
49

query I rowsort
SELECT col1 + 60 AS col1 FROM tab0 AS cor0
----
146
151
157

query I rowsort
SELECT ALL - col2 * - cor0.col0 + cor0.col1 FROM tab1 AS cor0
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + 43 col2 FROM tab2 AS cor0
----
-16
12
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9719
SELECT ALL - col0 + - col2 DIV 54 AS col0 FROM tab0 AS cor0
----
-24
-35
-90

skipif mysql # not compatible
query I rowsort label-9719
SELECT ALL - col0 + - col2 / 54 AS col0 FROM tab0 AS cor0
----
-24
-35
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + + 5 col1 FROM tab2 AS cor0
----
31
32
43

query I rowsort
SELECT ALL + col1 + + 80 FROM tab2 AS cor0
----
111
139
97

query I rowsort
SELECT ALL - cor0.col0 * + cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + tab2.col0 col2 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 9 col1 FROM tab2
----
-9
-9
-9

query I rowsort
SELECT DISTINCT cor0.col0 * 47 FROM tab0, tab2 AS cor0
----
329
3666
3713

query I rowsort
SELECT + 97 - col0 * 13 AS col0 FROM tab0
----
-1060
-215
-358

query I rowsort
SELECT DISTINCT - col2 + + col0 * + 54 FROM tab1 AS cor0
----
108
3399
4224

query I rowsort
SELECT DISTINCT + col1 * col0 - - 26 * col1 FROM tab2 AS cor0
----
1023
1785
6136

query I rowsort
SELECT ALL + col1 + col0 * col0 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9730
SELECT DISTINCT + col0 DIV - col1 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9730
SELECT DISTINCT + col0 / - col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - cor0.col0 + + col1 AS col0 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT ALL col2 * - 51 + - 62 AS col0 FROM tab1 AS cor0
----
-2816
-2969
-4958

query I rowsort
SELECT ALL col0 * col1 * + col1 + col2 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
22948
271622
6761

query I rowsort
SELECT ALL - 97 FROM tab2, tab2 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9735
SELECT - CAST( 98 AS SIGNED ) AS col0 FROM tab2 cor0
----
-98
-98
-98

skipif mysql # not compatible
query I rowsort label-9735
SELECT - CAST ( 98 AS INTEGER ) AS col0 FROM tab2 cor0
----
-98
-98
-98

query I rowsort
SELECT - - 52 * + 72 + + col2 FROM tab2 AS cor0
----
3770
3771
3782

query I rowsort
SELECT ALL + col0 - + ( + col0 ) * col1 * col1 FROM tab1
----
-13440
-2025
-6336

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9738
SELECT ALL - CAST( NULL AS DECIMAL ) * - 15 AS col0 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-9738
SELECT ALL - CAST ( NULL AS REAL ) * - 15 AS col0 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT DISTINCT 90 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
90

query I rowsort
SELECT col0 + col1 * + col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT + col2 * + ( - col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL col0 + + col0 + + tab0.col0 FROM tab0
----
105
267
72

query I rowsort
SELECT DISTINCT - 15 FROM tab0, tab1, tab2 AS cor0
----
-15

onlyif mysql # use DIV operator for integer division
query I rowsort label-9744
SELECT + col0 DIV 2 + col1 * ( - 56 + + col1 ) * ( 86 ) FROM tab0
----
221892
273954
342039

skipif mysql # not compatible
query I rowsort label-9744
SELECT + col0 / 2 + col1 * ( - 56 + + col1 ) * ( 86 ) FROM tab0
----
221892
273954
342039

query I rowsort
SELECT ALL + col0 + cor0.col0 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - + 99 FROM tab2 cor0
----
-99
-99
-99

query I rowsort
SELECT ALL col1 * col0 + - col2 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT + + col1 * - cor0.col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9749
SELECT ALL - col0 + 39 DIV - tab0.col2 AS col0 FROM tab0
----
-25
-74
-89

skipif mysql # not compatible
query I rowsort label-9749
SELECT ALL - col0 + 39 / - tab0.col2 AS col0 FROM tab0
----
-25
-74
-89

query I rowsort
SELECT DISTINCT + tab1.col2 * + col1 + col2 FROM tab1
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col0 col1 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT - 23 AS col1 FROM tab2
----
-23

query I rowsort
SELECT ALL 30 * col0 * - 87 FROM tab1 AS cor0
----
-167040
-208800
-7830

query I rowsort
SELECT DISTINCT + - 91 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1183
-2366
-910

query I rowsort
SELECT - + col1 + col2 + - 18 FROM tab2 AS cor0
----
-22
-51
3

query I rowsort
SELECT ALL + 62 * cor0.col0 * + 53 AS col2 FROM tab1 AS cor0
----
210304
262880
9858

onlyif mysql # use DIV operator for integer division
query I rowsort label-9757
SELECT DISTINCT 51 DIV - col0 AS col2 FROM tab1 AS cor0
----
-17
0

skipif mysql # not compatible
query I rowsort label-9757
SELECT DISTINCT 51 / - col0 AS col2 FROM tab1 AS cor0
----
-17
0

query I rowsort
SELECT DISTINCT 41 * col0 * 5 + 43 FROM tab1 AS cor0
----
13163
16443
658

query I rowsort
SELECT + ( col0 ) * + col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + - col2 + col0 - col0 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col0 FROM tab2 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9762
SELECT DISTINCT - col0 * col1 DIV col1 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-9762
SELECT DISTINCT - col0 * col1 / col1 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col0 * + col2 - - 14 * col2 AS col0 FROM tab2 AS cor0
----
2392
3534
567

query I rowsort
SELECT DISTINCT + + ( - cor0.col2 ) FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9765
SELECT ALL - cor0.col0 DIV col0 AS col0 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9765
SELECT ALL - cor0.col0 / col0 AS col0 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT + col0 + - col1 * + ( 49 ) AS col2 FROM tab0 AS cor0
----
-4190
-4370
-4718

query I rowsort
SELECT ALL - + 1 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT DISTINCT + col2 + + col2 * + 53 * col1 AS col1 FROM tab0 AS cor0
----
150447
395568
5142

query I rowsort
SELECT ALL + col2 * - 13 FROM tab1 cor0
----
-1248
-702
-741

query I rowsort
SELECT 49 AS col1 FROM tab2 cor0
----
49
49
49

query I rowsort
SELECT - 3 FROM tab2, tab1 cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT ALL 74 * + 13 AS col2 FROM tab2
----
962
962
962

onlyif mysql # use DIV operator for integer division
query I rowsort label-9773
SELECT DISTINCT + cor0.col1 + 40 DIV cor0.col0 AS col1 FROM tab1, tab0 AS cor0
----
87
91
98

skipif mysql # not compatible
query I rowsort label-9773
SELECT DISTINCT + cor0.col1 + 40 / cor0.col0 AS col1 FROM tab1, tab0 AS cor0
----
87
91
98

query I rowsort
SELECT - ( col1 ) * - col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL 33 * + col0 FROM tab0
----
1155
2937
792

query I rowsort
SELECT ALL - col1 - - ( - cor0.col2 ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + col0 + - 83 * - 91 FROM tab0 AS cor0
----
7577
7588
7642

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + ( col1 ) col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - - col2 * col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-9780
SELECT DISTINCT + col1 DIV + col0 + - 24 + col0 FROM tab2 AS cor0
----
-13
54
55

skipif mysql # not compatible
query I rowsort label-9780
SELECT DISTINCT + col1 / + col0 + - 24 + col0 FROM tab2 AS cor0
----
-13
54
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-9781
SELECT DISTINCT 42 + - col2 DIV + col0 FROM tab2
----
39
42

skipif mysql # not compatible
query I rowsort label-9781
SELECT DISTINCT 42 + - col2 / + col0 FROM tab2
----
39
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-9782
SELECT + col2 + col2 DIV col1 AS col1 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-9782
SELECT + col2 + col2 / col1 AS col1 FROM tab2 AS cor0
----
26
27
40

query I rowsort
SELECT + col0 * col2 + + 85 FROM tab1 cor0
----
247
3733
7765

query I rowsort
SELECT + col2 * col2 + col0 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-9785
SELECT + + col0 DIV col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9785
SELECT + + col0 / col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * - col1 + 47 FROM tab2 AS cor0
----
1581
693
884

query I rowsort
SELECT DISTINCT + col1 + - 97 * col1 + - col2 FROM tab1 cor0
----
-1017
-1344
-2550

query I rowsort
SELECT ALL - cor0.col2 * col0 * col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT 22 FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to c6f049334398e3533dd6996714479a2f

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 cor1, tab1 AS cor2
----
972 values hashing to ed80235f6457dada5cbb50ce9e2a8923

query I rowsort
SELECT DISTINCT - 34 + col0 - col2 FROM tab1 AS cor0
----
-27
-50
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-9792
SELECT DISTINCT - + col2 DIV + col0 + - col2 + col2 AS col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-9792
SELECT DISTINCT - + col2 / + col0 + - col2 + col2 AS col0 FROM tab2 AS cor0
----
-3
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9793
SELECT CAST( NULL AS SIGNED ) * col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9793
SELECT CAST ( NULL AS INTEGER ) * col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * 98 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab1, tab0, tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - ( - col2 ) col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL 69 - + 59 FROM tab2, tab2 cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT DISTINCT + col0 * 35 FROM tab1
----
105
2240
2800

query I rowsort
SELECT ALL 4 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col1 col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT + col2 + cor0.col1 + - col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - - col1 + 54 AS col2 FROM tab1 AS cor0
----
64
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9803
SELECT ALL tab1.col2 DIV + col2 + + col2 * 33 AS col0 FROM tab1
----
1783
1882
3169

skipif mysql # not compatible
query I rowsort label-9803
SELECT ALL tab1.col2 / + col2 + + col2 * 33 AS col0 FROM tab1
----
1783
1882
3169

query I rowsort
SELECT ALL col2 * tab0.col2 + - col2 AS col1 FROM tab0
----
0
1056
6642

query I rowsort
SELECT ALL 69 FROM tab2, tab0 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT DISTINCT - col0 - - col1 * 22 FROM tab2
----
1220
295
675

query I rowsort
SELECT col2 * 19 * + col1 - col2 * - ( col2 ) FROM tab0 AS cor0
----
148502
1844
55011

onlyif mysql # use DIV operator for integer division
query I rowsort label-9808
SELECT - col0 - col2 DIV col0 FROM tab2 AS cor0
----
-10
-78
-79

skipif mysql # not compatible
query I rowsort label-9808
SELECT - col0 - col2 / col0 FROM tab2 AS cor0
----
-10
-78
-79

query I rowsort
SELECT - col2 * 70 FROM tab1 cor0
----
-3780
-3990
-6720

query I rowsort
SELECT ALL ( col2 ) AS col0 FROM tab2
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9811
SELECT DISTINCT - col0 * col0 DIV - col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-9811
SELECT DISTINCT - col0 * col0 / - col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - 29 FROM tab0
----
-29

query I rowsort
SELECT - col2 + 49 * + col1 AS col2 FROM tab1 AS cor0
----
1220
433
541

query I rowsort
SELECT - - ( col0 ) * col1 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - + col1 + + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col1 col0 FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 * col0 ) col2 FROM tab0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-9818
SELECT 16 DIV col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9818
SELECT 16 / col1 FROM tab2
----
0
0
0

query I rowsort
SELECT + 89 * - col0 FROM tab1 AS cor0
----
-267
-5696
-7120

query I rowsort
SELECT DISTINCT col1 * col2 - col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-9821
SELECT ALL + - col1 DIV - cor0.col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9821
SELECT ALL + - col1 / - cor0.col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT 84 * col0 FROM tab1 AS cor0
----
252
5376
6720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9823
SELECT + CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9823
SELECT + CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort
SELECT - cor0.col1 + - col0 * - CAST ( - col0 AS REAL ) FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT - - 25 * + col0 AS col2 FROM tab1 AS cor0
----
1600
2000
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-9826
SELECT DISTINCT - col0 + + col2 * col2 DIV - col0 AS col0 FROM tab2
----
-111
-86
-97

skipif mysql # not compatible
query I rowsort label-9826
SELECT DISTINCT - col0 + + col2 * col2 / - col0 AS col0 FROM tab2
----
-111
-86
-97

query I rowsort
SELECT col0 * - tab0.col0 AS col1 FROM tab0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9828
SELECT DISTINCT tab0.col2 + CAST( 41 AS SIGNED ) AS col0 FROM tab0
----
123
42
74

skipif mysql # not compatible
query I rowsort label-9828
SELECT DISTINCT tab0.col2 + CAST ( 41 AS INTEGER ) AS col0 FROM tab0
----
123
42
74

query I rowsort
SELECT DISTINCT - col2 + - tab0.col1 * col1 AS col0 FROM tab0
----
-7429
-8363
-9410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9830
SELECT + col1 - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9830
SELECT + col1 - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col1 + - col0 * + col0 AS col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL - 47 * cor0.col0 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8c4c0e3dfc44d87faccc12bff7bad5bf

query I rowsort
SELECT - ( + 53 ) * - col1 FROM tab2 AS cor0
----
1643
3127
901

query I rowsort
SELECT DISTINCT 79 * - col2 + col1 * + 31 * - 97 + col2 AS col1 FROM tab2 AS cor0
----
-179441
-54083
-95323

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9835
SELECT DISTINCT + - CAST( ( + col1 ) AS SIGNED ) col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9835
SELECT DISTINCT + - CAST ( ( + col1 ) AS INTEGER ) col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - 47 + + col1 * + col0 FROM tab2 AS cor0
----
1296
170
4555

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9837
SELECT ALL - CAST( NULL AS DECIMAL ) * + 98 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9837
SELECT ALL - CAST ( NULL AS REAL ) * + 98 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 40 * - col1 AS col2 FROM tab2 cor0
----
-1240
-2360
-680

query I rowsort
SELECT + ( - ( col0 ) ) + col0 * + cor0.col2 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-9840
SELECT ALL - col2 DIV - col0 AS col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-9840
SELECT ALL - col2 / - col0 AS col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT - + 78 * cor0.col0 FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT ALL ( 11 ) FROM tab2 AS cor0
----
11
11
11

query I rowsort
SELECT DISTINCT col0 + 14 AS col1 FROM tab1 AS cor0
----
17
78
94

query I rowsort
SELECT ALL + 65 * - col0 + col0 AS col0 FROM tab2 AS cor0
----
-448
-4992
-5056

query I rowsort
SELECT ALL ( + col0 ) - cor0.col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col1 * + 83 AS col0 FROM tab1 AS cor0
----
1079
2158
830

query I rowsort
SELECT 62 * + col0 FROM tab0 AS cor0
----
1488
2170
5518

query I rowsort
SELECT - - 69 * cor0.col0 FROM tab2 AS cor0
----
483
5382
5451

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col0 * + col0 col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL + cor0.col1 * col0 AS col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - col1 * - col1 + col1 FROM tab0 cor0
----
7482
8372
9506

query I rowsort
SELECT ALL + - ( cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + 1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT + 46 AS col0 FROM tab0 AS cor0
----
46
46
46

query I rowsort
SELECT ALL + col1 * + col2 + cor0.col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-9856
SELECT ALL ( col0 ) + + col2 * cor0.col0 DIV + col0 AS col0 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-9856
SELECT ALL ( col0 ) + + col2 * cor0.col0 / + col0 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + col0 + cor0.col0 * col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT + tab0.col1 * col0 AS col1 FROM tab0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col2 AS REAL ) AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT - ( - col0 ) + - col1 * + 67 * + tab2.col2 FROM tab2
----
-102700
-43203
-56072

query I rowsort
SELECT DISTINCT 51 FROM tab2, tab2 AS cor0
----
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-9862
SELECT DISTINCT - col0 + - 53 DIV + col0 FROM tab0 AS cor0
----
-26
-36
-89

skipif mysql # not compatible
query I rowsort label-9862
SELECT DISTINCT - col0 + - 53 / + col0 FROM tab0 AS cor0
----
-26
-36
-89

query I rowsort
SELECT + + col1 * - ( + col1 ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + + col2 * + col0 - ( + col2 ) * col1 * col0 AS col1 FROM tab0 cor0
----
-3360
-656820
-67320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - 0 col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL cor0.col2 * + col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - col2 + col2 * - 88 AS col2 FROM tab1 AS cor0
----
-4806
-5073
-8544

query I rowsort
SELECT DISTINCT + col0 - + col0 AS col1 FROM tab1 cor0
----
0

query I rowsort
SELECT ALL + col1 - - col2 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + - col2 * 61 FROM tab0 AS cor0
----
-2013
-5002
-61

query I rowsort
SELECT DISTINCT - col1 * + col1 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT - - cor0.col1 * + ( col1 ) + col1 * + col1 FROM tab0 cor0
----
14792
16562
18818

query I rowsort
SELECT DISTINCT + cor0.col2 + - ( col2 ) FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL cor0.col2 - - col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + cor0.col2 + 16 AS col2 FROM tab0 AS cor0
----
17
49
98

query I rowsort
SELECT - col0 + + ( + col2 ) * - col1 AS col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT - col2 * col1 + + 68 FROM tab0 AS cor0
----
-2770
-29
-7394

query I rowsort
SELECT ALL col0 + - col0 - + ( tab1.col0 ) * + col2 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9879
SELECT + col2 DIV - tab0.col2 + + col1 * col0 FROM tab0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-9879
SELECT + col2 / - tab0.col2 + + col1 * col0 FROM tab0
----
2063
3394
8098

query I rowsort
SELECT ( col2 ) + col0 + + 82 FROM tab1
----
139
203
258

onlyif mysql # use DIV operator for integer division
query I rowsort label-9881
SELECT DISTINCT col1 DIV - col2 + col0 FROM tab0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-9881
SELECT DISTINCT col1 / - col2 + col0 FROM tab0
----
-62
22
88

query I rowsort
SELECT DISTINCT tab0.col1 + 89 FROM tab0
----
175
180
186

query I rowsort
SELECT + col0 - + ( + col0 ) * + cor0.col2 * col0 FROM tab0 AS cor0
----
-1190
-18984
-649433

query I rowsort
SELECT ALL - col0 * ( col0 ) * col1 + + ( + col0 ) FROM tab1 AS cor0
----
-231
-40896
-83120

query I rowsort
SELECT DISTINCT cor0.col1 + ( + col1 ) AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT col2 * - col1 + + 29 FROM tab1 AS cor0
----
-1219
-1375
-541

query I rowsort
SELECT DISTINCT - cor0.col0 * - ( + col2 ) * col0 + 20 * col1 FROM tab1 AS cor0
----
1006
233672
614660

query I rowsort
SELECT 86 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 cor1, tab2 AS cor2
----
81 values hashing to e219687f6f4ab6f7ee442792edcebca9

query I rowsort
SELECT + 84 FROM tab0, tab1, tab1 cor0
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9890
SELECT ALL + CAST( NULL AS DECIMAL ) AS col0 FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9890
SELECT ALL + CAST ( NULL AS REAL ) AS col0 FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL col2 + + col2 * ( - col2 ) AS col1 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL - + 69 AS col2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

query I rowsort
SELECT ( 11 ) AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT - + cor0.col2 + + ( col1 ) * col1 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT col2 * - 99 AS col0 FROM tab2 AS cor0
----
-2574
-2673
-3762

query I rowsort
SELECT col1 + 67 AS col2 FROM tab0 cor0
----
153
158
164

query I rowsort
SELECT DISTINCT tab2.col1 * - col1 AS col0 FROM tab2
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-9898
SELECT + col0 DIV 85 AS col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9898
SELECT + col0 / 85 AS col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9899
SELECT + col1 DIV + 91 col2 FROM tab0 AS cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9899
SELECT + col1 / + 91 col2 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT + 31 * 82 + - col0 AS col1 FROM tab1 AS cor0
----
2462
2478
2539

query I rowsort
SELECT DISTINCT col1 + col2 + + col0 FROM tab1 AS cor0
----
131
189
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9902
SELECT + - CAST( cor0.col1 AS SIGNED ) + cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
158
1969
2985

skipif mysql # not compatible
query I rowsort label-9902
SELECT + - CAST ( cor0.col1 AS INTEGER ) + cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL - - col1 * + col2 + + col1 AS col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + + col0 * 43 AS col2 FROM tab0 AS cor0
----
1032
1505
3827

query I rowsort
SELECT ALL col1 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9906
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - col1 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9906
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - col1 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + + cor1.col0 * - 89 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cb10cde269b3bc987dceeadbf879a2a0

query I rowsort
SELECT + col1 * col2 + - col2 * ( col1 ) * - col2 + col0 * + col1 FROM tab2 AS cor0
----
23653
26537
46020

query I rowsort
SELECT - - col0 * - col0 + + col2 AS col1 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT ALL col1 * 0 + col2 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + + col2 * cor0.col2 + cor0.col2 AS col0 FROM tab1 cor0
----
2970
3306
9312

query I rowsort
SELECT ALL - ( - col0 ) - col1 * col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT 64 + - col1 FROM tab1 AS cor0
----
38
51
54

query I rowsort
SELECT DISTINCT - - cor0.col0 * 19 AS col2 FROM tab2 AS cor0
----
133
1482
1501

query I rowsort
SELECT 52 * + col2 FROM tab1 AS cor0
----
2808
2964
4992

onlyif mysql # use DIV operator for integer division
query I rowsort label-9916
SELECT ALL + col0 * - col1 + col2 + + 84 DIV col1 FROM tab2 AS cor0
----
-1301
-188
-4575

skipif mysql # not compatible
query I rowsort label-9916
SELECT ALL + col0 * - col1 + col2 + + 84 / col1 FROM tab2 AS cor0
----
-1301
-188
-4575

query I rowsort
SELECT + cor0.col0 * + col2 + col0 * 56 * - cor0.col1 FROM tab1 cor0
----
-32192
-4206
-50560

query I rowsort
SELECT - + 68 FROM tab2 cor0
----
-68
-68
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-9919
SELECT cor0.col2 + col2 DIV - col2 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-9919
SELECT cor0.col2 + col2 / - col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT cor1.col0 FROM tab0, tab0 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT + cor0.col1 * col1 + + cor0.col1 FROM tab1 AS cor0
----
110
182
702

skipif mysql # not compatible
query I rowsort
SELECT col1 - - col1 * + CAST ( - ( col2 ) AS INTEGER ) * + CAST ( - col1 + col0 AS REAL ) FROM tab1 cor0
----
-30770
-83603
32318

query I rowsort
SELECT - ( col1 ) + - col2 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT col2 * cor0.col0 + + 65 FROM tab1 AS cor0
----
227
3713
7745

query I rowsort
SELECT + col0 + col2 AS col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL ( 56 ) + - col1 * col2 FROM tab1
----
-1192
-1348
-514

onlyif mysql # use DIV operator for integer division
query I rowsort label-9927
SELECT + col0 * col2 DIV col2 col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9927
SELECT + col0 * col2 / col2 col1 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL - 4 * col2 AS col1 FROM tab1 AS cor0
----
-216
-228
-384

query I rowsort
SELECT - col2 * + col2 + - col1 * + ( cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-15005
-8485
-9410

query I rowsort
SELECT - - 8 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT DISTINCT - 52 FROM tab0, tab1 AS cor0
----
-52

query I rowsort
SELECT DISTINCT + 73 + col0 - tab2.col1 AS col0 FROM tab2
----
135
49
92

query I rowsort
SELECT + 34 + col0 + - ( + col0 ) FROM tab1
----
34
34
34

query I rowsort
SELECT DISTINCT col2 * + col2 - - col0 * 31 * - col0 AS col0 FROM tab0
----
-16767
-238827
-37974

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 21 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

query I rowsort
SELECT ALL + 99 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT - - col2 * cor0.col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ( 67 ) FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 09fa7af42010457bb3c6ffd0dfea3bc8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9939
SELECT + CAST( NULL AS SIGNED ) / - 14 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9939
SELECT + CAST ( NULL AS INTEGER ) / - 14 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9940
SELECT CAST( NULL AS DECIMAL ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9940
SELECT CAST ( NULL AS REAL ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 + 14 * - col2 FROM tab0 AS cor0
----
-111
-1239
-548

query I rowsort
SELECT - 20 * + col1 * col1 FROM tab1 cor0
----
-13520
-2000
-3380

query I rowsort
SELECT - col0 * 31 AS col2 FROM tab2 AS cor0
----
-217
-2418
-2449

query I rowsort
SELECT ALL + col2 * ( 93 ) FROM tab1 AS cor0
----
5022
5301
8928

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-9946
SELECT ALL + col0 + + cor0.col2 DIV 44 + + col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1065
-6634
34

skipif mysql # not compatible
query I rowsort label-9946
SELECT ALL + col0 + + cor0.col2 / 44 + + col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1065
-6634
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9947
SELECT DISTINCT col2 + - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9947
SELECT DISTINCT col2 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - col0 * - col2 - col2 AS col1 FROM tab2 cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-9949
SELECT DISTINCT + + col0 * 40 + col1 * - col0 + col0 DIV + col0 FROM tab2 AS cor0
----
-1481
1818
64

skipif mysql # not compatible
query I rowsort label-9949
SELECT DISTINCT + + col0 * 40 + col1 * - col0 + col0 / + col0 FROM tab2 AS cor0
----
-1481
1818
64

query I rowsort
SELECT DISTINCT - col0 * + 55 + cor0.col1 AS col0 FROM tab0 AS cor0
----
-1234
-1828
-4804

onlyif mysql # use DIV operator for integer division
query I rowsort label-9951
SELECT DISTINCT + col2 + + 79 DIV - 82 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-9951
SELECT DISTINCT + col2 + + 79 / - 82 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + + col0 + col0 * + col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT ALL - - col0 * + col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9954
SELECT DISTINCT col0 + col2 DIV + tab0.col2 AS col1 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-9954
SELECT DISTINCT col0 + col2 / + tab0.col2 AS col1 FROM tab0
----
25
36
90

query I rowsort
SELECT DISTINCT 69 * col1 + - col0 * 28 AS col1 FROM tab2
----
-1039
1887
1943

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + cor0.col2 - + col2 col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL - col1 * ( col0 ) * + col2 + col1 FROM tab0 AS cor0
----
-3298
-664027
-68026

query I rowsort
SELECT DISTINCT col1 * - ( + col2 ) - col0 * col0 FROM tab1 AS cor0
----
-1413
-4666
-7648

query I rowsort
SELECT DISTINCT - ( 97 ) * cor0.col0 FROM tab2 AS cor0
----
-679
-7566
-7663

query I rowsort
SELECT + cor0.col2 + col2 * - col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-9961
SELECT ALL 74 DIV - tab1.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to fb42e4a6a34542e94de69d6e8bb012e5

skipif mysql # not compatible
query I rowsort label-9961
SELECT ALL 74 / - tab1.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to fb42e4a6a34542e94de69d6e8bb012e5

query I rowsort
SELECT + col1 + + 77 AS col2 FROM tab0
----
163
168
174

query I rowsort
SELECT - col2 + - ( - col1 ) FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 - + 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 FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT - 89 FROM tab2, tab2 AS cor0
----
-89

query I rowsort
SELECT col1 * - 36 * col2 FROM tab0
----
-102168
-268632
-3492

query I rowsort
SELECT ALL - 11 AS col0 FROM tab1
----
-11
-11
-11

query I rowsort
SELECT ALL + 32 * + col2 AS col1 FROM tab1 AS cor0
----
1728
1824
3072

query I rowsort
SELECT 35 * 86 FROM tab0
----
3010
3010
3010

query I rowsort
SELECT DISTINCT + tab2.col0 - - col0 FROM tab2
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-9972
SELECT + 42 DIV col1 + col0 FROM tab2
----
78
8
81

skipif mysql # not compatible
query I rowsort label-9972
SELECT + 42 / col1 + col0 FROM tab2
----
78
8
81

query I rowsort
SELECT - tab1.col2 + - col0 AS col0 FROM tab1
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-9974
SELECT DISTINCT col0 DIV + col0 + 84 AS col0 FROM tab2
----
85

skipif mysql # not compatible
query I rowsort label-9974
SELECT DISTINCT col0 / + col0 + 84 AS col0 FROM tab2
----
85

query I rowsort
SELECT DISTINCT - ( col2 ) + + col1 AS col2 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT tab0.col2 + tab0.col2 AS col0 FROM tab0
----
164
2
66

query I rowsort
SELECT + col2 * + col1 + + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + 79 + col1 + col1 AS col2 FROM tab0
----
251
261
273

onlyif mysql # use DIV operator for integer division
query I rowsort label-9979
SELECT ALL - - col0 + + col1 DIV + cor0.col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-9979
SELECT ALL - - col0 + + col1 / + cor0.col0 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT + ( col1 ) * cor0.col0 - col0 AS col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT col1 * col2 + + col1 AS col1 FROM tab2 cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + - 90 * - cor0.col1 FROM tab2 AS cor0
----
1530
2790
5310

onlyif mysql # use DIV operator for integer division
query I rowsort label-9983
SELECT ALL - - col0 DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9983
SELECT ALL - - col0 / cor0.col0 AS col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - cor0.col1 * + col0 * col1 FROM tab2 cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT - tab1.col0 * - tab1.col1 FROM tab1, tab0 AS cor0
----
1040
640
78

query I rowsort
SELECT + col2 * cor0.col0 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 * col2 col0 FROM tab1
----
119808
32490
75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( - 56 ) col1 FROM tab0 AS cor0
----
56

query I rowsort
SELECT ALL - 98 + - col0 AS col1 FROM tab2 AS cor0
----
-105
-176
-177

query I rowsort
SELECT ALL 10 * 64 + col1 FROM tab1
----
650
653
666

query I rowsort
SELECT + 71 AS col1 FROM tab2
----
71
71
71

query I rowsort
SELECT ALL + + col2 + + col2 AS col2 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9993
SELECT DISTINCT - - CAST( - col0 AS SIGNED ) * col2 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

skipif mysql # not compatible
query I rowsort label-9993
SELECT DISTINCT - - CAST ( - col0 AS INTEGER ) * col2 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL col1 + col0 * col1 - + col0 * - col2 FROM tab1 cor0
----
266
4298
8733

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9995
SELECT ALL + CAST( col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-9995
SELECT ALL + CAST ( col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL - - col2 + col0 * col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT col2 + ( col0 ) AS col1 FROM tab0 AS cor0
----
171
36
57