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)

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

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

query I rowsort
SELECT + + col2 * 22 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-14872
-16038
-31768

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

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

query I rowsort
SELECT - ( col1 ) * 44 FROM tab0 AS cor0
----
-3784
-4004
-4268

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-7
SELECT - cor0.col0 DIV 6 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to a19be59c4f7a0e06f0829b3d2cdf3902

skipif mysql # not compatible
query I rowsort label-7
SELECT - cor0.col0 / 6 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to a19be59c4f7a0e06f0829b3d2cdf3902

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

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

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

query I rowsort
SELECT ALL - - cor0.col2 * 50 FROM tab2 AS cor0
----
1300
1350
1900

onlyif mysql # use DIV operator for integer division
query I rowsort label-12
SELECT ALL - col0 * - col0 - col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-12
SELECT ALL - col0 * - col0 - col0 / - col1 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + col1 * ( - col1 ) + - col2 * col1 AS col0 FROM tab2 AS cor0
----
-1798
-5015
-935

onlyif mysql # use DIV operator for integer division
query I rowsort label-14
SELECT ALL col2 DIV 44 - col1 AS col1 FROM tab0 AS cor0
----
-86
-90
-97

skipif mysql # not compatible
query I rowsort label-14
SELECT ALL col2 / 44 - col1 AS col1 FROM tab0 AS cor0
----
-86
-90
-97

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

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

query I rowsort
SELECT ALL + + 51 + - col0 FROM tab0 AS cor0
----
-38
16
27

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

query I rowsort
SELECT ALL ( + tab1.col1 ) * tab1.col1 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to ae5946db6904798b8afac35f5777bb79

query I rowsort
SELECT col0 + + col1 + - col2 AS col2 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT ALL - 1 FROM tab1 cor0
----
-1
-1
-1

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

query I rowsort
SELECT - - 98 + + col0 * col0 + - col0 AS col0 FROM tab0 AS cor0
----
1288
650
7930

query I rowsort
SELECT 92 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT ( + col0 ) * + 66 * - 53 AS col1 FROM tab2 AS cor0
----
-24486
-272844
-276342

query I rowsort
SELECT + - col1 * cor0.col2 + col0 + ( col2 * - col0 ) FROM tab2 AS cor0
----
-1019
-3484
-3569

query I rowsort
SELECT DISTINCT + 9 * cor0.col0 AS col1 FROM tab2 AS cor0
----
63
702
711

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

query I rowsort
SELECT ALL + 15 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

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

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

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

query I rowsort
SELECT ALL 29 * - 55 + cor0.col2 * + col2 FROM tab0 AS cor0
----
-1594
-506
5129

query I rowsort
SELECT DISTINCT + 70 * cor0.col1 + col2 AS col1 FROM tab2 AS cor0
----
1228
2197
4156

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-37
SELECT DISTINCT + 82 DIV - col0 FROM tab1 AS cor0
----
-1
-27

skipif mysql # not compatible
query I rowsort label-37
SELECT DISTINCT + 82 / - col0 FROM tab1 AS cor0
----
-1
-27

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col2 + + col2 col1 FROM tab1 AS cor0
----
-2862
-3192
-9120

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

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

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

query I rowsort
SELECT + 38 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

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

query I rowsort
SELECT DISTINCT - col2 * + ( 55 ) AS col1 FROM tab1 AS cor0
----
-2970
-3135
-5280

query I rowsort
SELECT cor0.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-47
SELECT ALL col0 + - CAST( + col0 AS SIGNED ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-47
SELECT ALL col0 + - CAST ( + col0 AS INTEGER ) FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-48
SELECT + col1 DIV 35 + + 80 FROM tab1
----
80
80
80

skipif mysql # not compatible
query I rowsort label-48
SELECT + col1 / 35 + + 80 FROM tab1
----
80
80
80

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

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

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

query I rowsort
SELECT + col2 * - 70 + - col2 AS col0 FROM tab1 AS cor0
----
-3834
-4047
-6816

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

skipif mysql # not compatible
query I rowsort label-53
SELECT col1 / - 83 + - col0 AS col0 FROM tab0 cor0
----
-25
-36
-90

query I rowsort
SELECT DISTINCT + - col2 * - 18 - + col2 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
1596
2376
2976

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

query I rowsort
SELECT + - col2 + - cor0.col0 * + ( + col1 + - ( col1 ) * col1 ) AS col0 FROM tab0 cor0
----
175407
325919
728828

query I rowsort
SELECT DISTINCT col2 * 64 FROM tab0 AS cor0
----
2112
5248
64

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-59
SELECT ALL - col0 * 50 + - col1 * col2 DIV 3 AS col2 FROM tab1 cor0
----
-3390
-4416
-618

skipif mysql # not compatible
query I rowsort label-59
SELECT ALL - col0 * 50 + - col1 * col2 / 3 AS col2 FROM tab1 cor0
----
-3390
-4416
-618

query I rowsort
SELECT ALL - 56 + + col2 * - col2 FROM tab1 AS cor0
----
-2972
-3305
-9272

query I rowsort
SELECT - 55 + col2 FROM tab1 AS cor0
----
-1
2
41

query I rowsort
SELECT ALL - + 15 * - col0 + + col0 + col0 * - cor0.col1 FROM tab2 AS cor0
----
-105
-3354
-79

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

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

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

query I rowsort
SELECT ALL col1 * 93 * col1 + - 88 * - col1 AS col1 FROM tab2 AS cor0
----
28373
328925
92101

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

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

query I rowsort
SELECT ALL - - 5 - 17 FROM tab1 AS cor0
----
-12
-12
-12

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * 56 + col1 + 58 * - cor0.col0 col1 FROM tab1 cor0
----
-316
-7286
-9107

query I rowsort
SELECT ALL - ( + 31 ) + col0 AS col0 FROM tab2 AS cor0
----
-24
47
48

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

query I rowsort
SELECT ALL - col1 * col2 + + 76 * tab1.col2 * col0 FROM tab1
----
10908
276678
582432

query I rowsort
SELECT - col2 + - col1 + cor0.col1 * + ( + 11 ) FROM tab0 AS cor0
----
827
828
969

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

query I rowsort
SELECT DISTINCT - + col2 + 34 FROM tab0 AS cor0
----
-48
1
33

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

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

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

query I rowsort
SELECT 64 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

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

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

query I rowsort
SELECT col0 * - 82 FROM tab0
----
-1968
-2870
-7298

query I rowsort
SELECT - 52 * - col0 + col1 AS col0 FROM tab2 AS cor0
----
395
4115
4125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 99 * 87 col2 FROM tab2
----
8613

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 22 * - col0 col1 FROM tab1 AS cor0
----
1408
1760
66

query I rowsort
SELECT col1 * 17 + col2 FROM tab0
----
1495
1629
1650

query I rowsort
SELECT col0 + + 67 * + col0 AS col0 FROM tab2
----
476
5304
5372

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

query I rowsort
SELECT + ( col0 ) + col1 * col1 AS col2 FROM tab1 AS cor0
----
164
249
679

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

query I rowsort
SELECT 21 * col0 AS col2 FROM tab1
----
1344
1680
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-91
SELECT DISTINCT 10 + - col2 DIV - tab0.col0 - col0 col2 FROM tab0
----
-13
-25
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-91
SELECT DISTINCT 10 + - col2 / - tab0.col0 - col0 col2 FROM tab0
----
-13
-25
-79

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

query I rowsort
SELECT col1 * - col2 + - col2 + col0 FROM tab2
----
-1482
-605
-857

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-95
SELECT + + col1 DIV + 97 + 99 AS col2 FROM tab1 AS cor0
----
99
99
99

skipif mysql # not compatible
query I rowsort label-95
SELECT + + col1 / + 97 + 99 AS col2 FROM tab1 AS cor0
----
99
99
99

query I rowsort
SELECT DISTINCT + col1 + col1 + - col2 * 88 FROM tab1
----
-4700
-4996
-8422

query I rowsort
SELECT ALL - 83 * - col0 AS col2 FROM tab2
----
581
6474
6557

query I rowsort
SELECT ALL + col1 + tab1.col0 * col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT + + col2 * - col2 - col1 * col1 FROM tab2 AS cor0
----
-1690
-1733
-4157

query I rowsort
SELECT DISTINCT col2 + + 76 * + cor0.col2 * + col1 AS col2 FROM tab2 AS cor0
----
116610
49134
63639

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 - 86 col0 FROM tab0 AS cor0
----
-110
-121
-175

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

query I rowsort
SELECT - - col0 * col1 * col0 AS col0 FROM tab0 AS cor0
----
118825
49536
720811

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

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

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

query I rowsort
SELECT + col1 + - 33 AS col2 FROM tab0
----
53
58
64

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

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

query I rowsort
SELECT ALL + 6 AS col1 FROM tab0
----
6
6
6

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-114
SELECT + - col2 DIV - col0 + col0 * - col2 FROM tab1 cor0
----
-144
-3648
-7679

skipif mysql # not compatible
query I rowsort label-114
SELECT + - col2 / - col0 + col0 * - col2 FROM tab1 cor0
----
-144
-3648
-7679

query I rowsort
SELECT DISTINCT - col0 * ( 40 ) + col1 AS col0 FROM tab1 AS cor0
----
-2550
-3187
-94

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

query I rowsort
SELECT + col0 * + col2 * - 28 + col1 FROM tab1 cor0
----
-102134
-215027
-4510

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

query I rowsort
SELECT - ( 9 ) FROM tab2 cor0
----
-9
-9
-9

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 73 * + col1 * col2 col0 FROM tab2
----
111982
47158
61101

onlyif mysql # use DIV operator for integer division
query I rowsort label-122
SELECT ALL + col1 * + col2 DIV + col2 + - 75 FROM tab1 AS cor0
----
-49
-62
-65

skipif mysql # not compatible
query I rowsort label-122
SELECT ALL + col1 * + col2 / + col2 + - 75 FROM tab1 AS cor0
----
-49
-62
-65

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-125
SELECT - col2 DIV - 22 + + tab0.col1 AS col0 FROM tab0
----
87
94
97

skipif mysql # not compatible
query I rowsort label-125
SELECT - col2 / - 22 + + tab0.col1 AS col0 FROM tab0
----
87
94
97

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

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

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

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

skipif mysql # not compatible
query I rowsort label-128
SELECT CAST ( + 23 AS INTEGER ) FROM tab2
----
23
23
23

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

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

skipif mysql # not compatible
query I rowsort label-130
SELECT ALL - - ( - 63 ) * col0 + + CAST ( + col1 AS INTEGER ) + - col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-850
-883
2405

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

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

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

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

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

query I rowsort
SELECT ALL + 22 * + col2 + col0 FROM tab0 AS cor0
----
1893
57
750

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

skipif mysql # not compatible
query I rowsort label-137
SELECT + cor0.col0 + + CAST ( - col1 AS INTEGER ) * - col1 AS col2 FROM tab2 AS cor0
----
3559
368
968

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

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

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

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

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

query I rowsort
SELECT + 52 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

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

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

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

query I rowsort
SELECT ALL ( col1 ) - - col1 FROM tab2 cor0
----
118
34
62

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

query I rowsort
SELECT + + 63 * col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
40698
52731
96642

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

query I rowsort
SELECT DISTINCT + - 0 * + col0 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT col0 * + 57 - - col1 AS col0 FROM tab0 AS cor0
----
1454
2092
5164

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

query I rowsort
SELECT DISTINCT - 49 * 94 AS col0 FROM tab2 AS cor0
----
-4606

query I rowsort
SELECT + col1 + col0 - + col2 FROM tab2
----
11
111
58

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + 52 - col1 col1 FROM tab2
----
-1411
-1435
-1993

onlyif mysql # use DIV operator for integer division
query I rowsort label-157
SELECT ALL col2 + + 5 * col1 DIV - col0 FROM tab0
----
-12
16
77

skipif mysql # not compatible
query I rowsort label-157
SELECT ALL col2 + + 5 * col1 / - col0 FROM tab0
----
-12
16
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-158
SELECT - col1 * CAST( col2 AS SIGNED ) FROM tab2
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-158
SELECT - col1 * CAST ( col2 AS INTEGER ) FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT + col1 * 7 AS col2 FROM tab2
----
119
217
413

query I rowsort
SELECT - col2 * 17 FROM tab2
----
-442
-459
-646

query I rowsort
SELECT ALL + 50 + + col1 FROM tab1
----
60
63
76

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

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

query I rowsort
SELECT + col1 + col1 + - ( + col0 * + ( - col1 ) ) FROM tab1 AS cor0
----
1066
130
660

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

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

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

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

query I rowsort
SELECT - 35 + col1 FROM tab1 cor0
----
-22
-25
-9

query I rowsort
SELECT ALL + 19 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT ALL ( cor0.col1 ) + + tab2.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to b8b62762005dc0d7237145d0538edb34

query I rowsort
SELECT - col1 * ( col1 ) + - col0 FROM tab2
----
-3559
-368
-968

onlyif mysql # use DIV operator for integer division
query I rowsort label-171
SELECT DISTINCT - col0 DIV - col2 + col0 AS col0 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-171
SELECT DISTINCT - col0 / - col2 + col0 AS col0 FROM tab0 AS cor0
----
24
70
90

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

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

query I rowsort
SELECT ALL + col1 + 84 * col2 AS col0 FROM tab0 AS cor0
----
181
2858
6979

onlyif mysql # use DIV operator for integer division
query I rowsort label-174
SELECT ALL + col0 * 92 DIV + col0 FROM tab2 AS cor0
----
92
92
92

skipif mysql # not compatible
query I rowsort label-174
SELECT ALL + col0 * 92 / + col0 FROM tab2 AS cor0
----
92
92
92

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

query I rowsort
SELECT ALL cor0.col1 * + 89 + - 3 AS col0 FROM tab1 AS cor0
----
1154
2311
887

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

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

skipif mysql # not compatible
query I rowsort label-178
SELECT + CAST ( - col2 AS INTEGER ) * col0 AS col2 FROM tab0
----
-35
-7298
-792

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

query I rowsort
SELECT - 46 * + tab2.col1 * + col1 FROM tab2
----
-13294
-160126
-44206

query I rowsort
SELECT col2 * - col1 + + col2 + - 23 * col0 FROM tab0
----
-3357
-901
-9427

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

query I rowsort
SELECT DISTINCT ( col1 ) + + col2 FROM tab0
----
119
173
98

query I rowsort
SELECT 44 + col2 * - cor0.col2 FROM tab1 AS cor0
----
-2872
-3205
-9172

query I rowsort
SELECT - 42 + - col1 AS col1 FROM tab0 AS cor0
----
-128
-133
-139

query I rowsort
SELECT DISTINCT - 37 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-1998
-2109
-3552

query I rowsort
SELECT ALL - - col0 * col0 + - col1 + + col0 AS col1 FROM tab0 AS cor0
----
1163
514
7919

query I rowsort
SELECT 52 + - cor0.col0 FROM tab1 AS cor0
----
-12
-28
49

query I rowsort
SELECT DISTINCT + col1 * col0 * - col0 AS col2 FROM tab0 AS cor0
----
-118825
-49536
-720811

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

query I rowsort
SELECT 34 * - col1 + ( col2 ) FROM tab1 AS cor0
----
-283
-346
-830

query I rowsort
SELECT DISTINCT + col2 * - col0 + col1 + col0 FROM tab2 AS cor0
----
-151
-1891
-2906

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

query I rowsort
SELECT ALL - col2 * col2 + col2 FROM tab1 cor0
----
-2862
-3192
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( cor0.col2 ) + 1 * 99 * + col2 col1 FROM tab2 AS cor0
----
2600
2700
3800

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + ( 56 * col0 ) - - col2 FROM tab0
----
1377
1961
5066

query I rowsort
SELECT DISTINCT col1 - col0 * tab2.col0 AS col2 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + tab2.col0 - - 47 AS col1 FROM tab2
----
125
126
54

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

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

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

query I rowsort
SELECT + ( - col0 ) + - col1 * col1 + - col1 FROM tab1 cor0
----
-174
-262
-705

onlyif mysql # use DIV operator for integer division
query I rowsort label-213
SELECT - - 43 DIV col0 + 31 * col2 + - col1 FROM tab2 AS cor0
----
1161
747
812

skipif mysql # not compatible
query I rowsort label-213
SELECT - - 43 / col0 + 31 * col2 + - col1 FROM tab2 AS cor0
----
1161
747
812

query I rowsort
SELECT DISTINCT - 46 * - col1 * col1 FROM tab1 AS cor0
----
31096
4600
7774

query I rowsort
SELECT DISTINCT col0 + col0 + + 88 AS col1 FROM tab1 AS cor0
----
216
248
94

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

query I rowsort
SELECT - + 36 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to afecaf209e79e23b6674a73fffa3e837

query I rowsort
SELECT + - 74 * col0 AS col0 FROM tab2 AS cor0
----
-518
-5772
-5846

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col0 col1 FROM tab1 AS cor0
----
-4096
-6400
-9

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-225
SELECT + col2 + + 67 DIV - cor0.col2 FROM tab1 AS cor0
----
53
56
96

skipif mysql # not compatible
query I rowsort label-225
SELECT + col2 + + 67 / - cor0.col2 FROM tab1 AS cor0
----
53
56
96

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

skipif mysql # not compatible
query I rowsort label-226
SELECT ALL - 5 + col2 * - CAST ( - tab0.col0 + col0 AS INTEGER ) FROM tab0
----
-5
-5
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col1 + + 30 col2 FROM tab2
----
319
3511
991

query I rowsort
SELECT - 50 * + 93 AS col1 FROM tab2 AS cor0
----
-4650
-4650
-4650

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

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

query I rowsort
SELECT ALL + 20 * + col2 AS col0 FROM tab0 AS cor0
----
1640
20
660

query I rowsort
SELECT DISTINCT - 21 + - col0 FROM tab0 AS cor0
----
-110
-45
-56

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

query I rowsort
SELECT - tab1.col0 * 36 + + col2 FROM tab1
----
-2247
-2784
-54

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-235
SELECT ALL + col1 DIV - tab0.col2 - - tab0.col1 AS col1 FROM tab0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-235
SELECT ALL + col1 / - tab0.col2 - - tab0.col1 AS col1 FROM tab0
----
0
84
90

query I rowsort
SELECT ALL 24 * 84 FROM tab0 AS cor0
----
2016
2016
2016

query I rowsort
SELECT - ( 59 ) FROM tab2 AS cor0
----
-59
-59
-59

query I rowsort
SELECT DISTINCT + col2 * col0 - - col0 * + col0 FROM tab0 AS cor0
----
1260
1368
15219

query I rowsort
SELECT DISTINCT + col1 * - 41 AS col1 FROM tab1 AS cor0
----
-1066
-410
-533

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

query I rowsort
SELECT - tab2.col1 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL + 50 + - cor0.col0 * cor0.col2 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 54df49d1110ed416af417ebe338a77c5

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

skipif mysql # not compatible
query I rowsort label-243
SELECT 14 + col2 / + col1 AS col2 FROM tab0 AS cor0
----
14
14
14

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

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

query I rowsort
SELECT DISTINCT 32 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
32

query I rowsort
SELECT - tab0.col2 AS col1 FROM tab0, tab2 cor0, tab2, tab0 cor1
----
81 values hashing to 87af467938ef355540b8de24db1bf3b8

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

query I rowsort
SELECT + 51 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1 cor2
----
81 values hashing to c9771396949659773ab2fa2a1ac228de

query I rowsort
SELECT + cor0.col2 * 47 AS col2 FROM tab1 cor0
----
2538
2679
4512

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

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

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

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

query I rowsort
SELECT DISTINCT col0 * + col0 + + col0 + + col1 * col1 AS col2 FROM tab1 AS cor0
----
4260
6649
688

query I rowsort
SELECT DISTINCT - col1 + col2 * - 28 FROM tab2 AS cor0
----
-1081
-787

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

query I rowsort
SELECT 57 FROM tab0, tab2 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - ( 22 * col1 ) col2 FROM tab1 AS cor0
----
-210
-273
-546

query I rowsort
SELECT + col1 * col2 + - 97 FROM tab2 AS cor0
----
1437
549
740

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

query I rowsort
SELECT + col1 + + ( + 79 ) * - col2 FROM tab0 AS cor0
----
-2521
-6387
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + 81 + - ( - cor0.col1 + ( cor0.col2 ) ) col2 FROM tab0 AS cor0
----
-2620
-6633
15

query I rowsort
SELECT - cor0.col0 FROM tab2, tab0, tab0 AS cor0, tab1
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

query I rowsort
SELECT ALL 64 * tab0.col1 + col1 + col2 * - col1 AS col1 FROM tab0
----
-1547
2752
6208

query I rowsort
SELECT - 19 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

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

query I rowsort
SELECT ALL + 41 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 29 col2 FROM tab0 cor0
----
-2494
-2639
-2813

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

query I rowsort
SELECT DISTINCT col1 * 60 AS col1 FROM tab2
----
1020
1860
3540

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

skipif mysql # not compatible
query I rowsort label-273
SELECT DISTINCT - col1 / - ( - col2 ) AS col1 FROM tab0
----
-1
-2
-97

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

query I rowsort
SELECT - cor0.col2 * - col1 + + col2 * - 68 + - col1 FROM tab0 AS cor0
----
-68
1795
508

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

query I rowsort
SELECT ALL ( - 65 ) * + col2 AS col2 FROM tab0 cor0
----
-2145
-5330
-65

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-280
SELECT DISTINCT + tab2.col1 DIV col1 + col1 FROM tab2
----
18
32
60

skipif mysql # not compatible
query I rowsort label-280
SELECT DISTINCT + tab2.col1 / col1 + col1 FROM tab2
----
18
32
60

query I rowsort
SELECT ALL col0 * col2 + - col2 + + tab0.col0 FROM tab0
----
69
7305
783

query I rowsort
SELECT DISTINCT col1 - 46 AS col0 FROM tab2
----
-15
-29
13

query I rowsort
SELECT DISTINCT - col0 + 55 + 61 * col2 FROM tab0
----
2044
4968
81

query I rowsort
SELECT DISTINCT + 93 + + 41 FROM tab1
----
134

query I rowsort
SELECT tab2.col0 + 42 AS col1 FROM tab2
----
120
121
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-286
SELECT ALL + CAST( - col2 AS SIGNED ) * cor0.col0 DIV col1 FROM tab2 AS cor0
----
-176
-34
-6

skipif mysql # not compatible
query I rowsort label-286
SELECT ALL + CAST ( - col2 AS INTEGER ) * cor0.col0 / col1 FROM tab2 AS cor0
----
-176
-34
-6

query I rowsort
SELECT DISTINCT 82 * - 7 AS col1 FROM tab0 AS cor0
----
-574

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-289
SELECT ALL CAST( + col0 AS SIGNED ) + cor0.col2 * + 99 AS col2 FROM tab2 AS cor0
----
2652
2680
3841

skipif mysql # not compatible
query I rowsort label-289
SELECT ALL CAST ( + col0 AS INTEGER ) + cor0.col2 * + 99 AS col2 FROM tab2 AS cor0
----
2652
2680
3841

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

query I rowsort
SELECT DISTINCT + + 33 AS col1 FROM tab1 AS cor0
----
33

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

query I rowsort
SELECT + + 17 * col1 + col2 FROM tab0 AS cor0
----
1495
1629
1650

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + 19 col2 FROM tab0 cor0
----
1691
456
665

query I rowsort
SELECT ALL - col1 * + col0 - col2 * + col0 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT ( - 60 ) * col2 AS col1 FROM tab1 AS cor0
----
-3240
-3420
-5760

query I rowsort
SELECT DISTINCT + 22 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
22

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

skipif mysql # not compatible
query I rowsort label-300
SELECT DISTINCT ( - col2 ) / 85 FROM tab0
----
0

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

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

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

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

skipif mysql # not compatible
query I rowsort label-303
SELECT + col2 / + 18 FROM tab0 AS cor0
----
0
1
4

query I rowsort
SELECT + col1 + ( + col2 ) + col1 FROM tab0
----
195
205
264

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-306
SELECT - 29 DIV col0 AS col1 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-306
SELECT - 29 / col0 AS col1 FROM tab2
----
-4
0
0

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

skipif mysql # not compatible
query I rowsort label-307
SELECT DISTINCT + col2 + 21 / - ( + col2 ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL - cor0.col2 + 17 AS col0 FROM tab0 cor0
----
-16
-65
16

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

query I rowsort
SELECT + col1 - + 38 FROM tab1 AS cor0
----
-12
-25
-28

query I rowsort
SELECT ALL col1 * 26 AS col0 FROM tab2 cor0
----
1534
442
806

query I rowsort
SELECT - col1 + 12 FROM tab0 AS cor0
----
-74
-79
-85

query I rowsort
SELECT DISTINCT col0 * col1 - - 43 AS col0 FROM tab2 AS cor0
----
1386
260
4645

query I rowsort
SELECT DISTINCT + 19 * + col2 AS col1 FROM tab1 AS cor0
----
1026
1083
1824

query I rowsort
SELECT DISTINCT - 6 * + col2 AS col2 FROM tab1 AS cor0
----
-324
-342
-576

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

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

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

query I rowsort
SELECT ALL + col0 * col0 + 39 FROM tab1 AS cor0
----
4135
48
6439

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 58 + + col1 * 79 col2 FROM tab0 cor0
----
6852
7247
7721

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

query I rowsort
SELECT - 55 + ( - col0 + - ( + 79 ) ) * col2 AS col2 FROM tab1
----
-15319
-4483
-8206

query I rowsort
SELECT + col0 + cor0.col2 * - ( - col2 ) * - col0 FROM tab1 cor0
----
-207872
-737200
-8745

query I rowsort
SELECT + cor2.col0 * + cor1.col1 AS col1 FROM tab0, tab0 cor0, tab2 cor1, tab2 AS cor2
----
81 values hashing to b9beb01f31f0dbcbb6fe195d8c5fcf4a

query I rowsort
SELECT ALL + 19 + - ( + cor0.col2 ) * - col0 FROM tab1 AS cor0
----
181
3667
7699

onlyif mysql # use DIV operator for integer division
query I rowsort label-326
SELECT + col0 - + col2 DIV ( col2 ) AS col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-326
SELECT + col0 - + col2 / ( col2 ) AS col0 FROM tab1
----
2
63
79

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-328
SELECT ALL CAST ( NULL AS REAL ) * col0 * cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor2.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2, tab0 AS cor3
----
243 values hashing to 3dcd863493ac16ce594c62d4ac8b0412

query I rowsort
SELECT - 38 + col1 * - col2 + col2 AS col2 FROM tab1
----
-1190
-1388
-551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-331
SELECT ALL CAST( + 86 AS SIGNED ) + - col1 + 27 FROM tab1
----
100
103
87

skipif mysql # not compatible
query I rowsort label-331
SELECT ALL CAST ( + 86 AS INTEGER ) + - col1 + 27 FROM tab1
----
100
103
87

query I rowsort
SELECT DISTINCT 4 + - col1 AS col1 FROM tab1
----
-22
-6
-9

query I rowsort
SELECT 32 + col0 FROM tab0
----
121
56
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 79 + + col2 * tab0.col1 + 52 col2 FROM tab0
----
228
2969
7593

query I rowsort
SELECT ALL - col2 * 99 FROM tab1 AS cor0
----
-5346
-5643
-9504

query I rowsort
SELECT 78 * - 59 AS col1 FROM tab0 AS cor0
----
-4602
-4602
-4602

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

query I rowsort
SELECT ALL col0 + 98 + col1 AS col0 FROM tab0
----
208
230
278

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

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

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

query I rowsort
SELECT DISTINCT cor1.col0 + + 71 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
135
151
74

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

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

query I rowsort
SELECT cor1.col1 AS col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + 91 ) + + col2 col1 FROM tab2 AS cor0
----
117
118
129

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-351
SELECT + ( col0 ) / col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT DISTINCT 11 * col0 FROM tab0 AS cor0
----
264
385
979

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 94 * col1 ) col1 FROM tab0
----
8084
8554
9118

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

query I rowsort
SELECT 78 AS col0 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-359
SELECT + col0 + - col0 DIV col1 AS col0 FROM tab2 AS cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-359
SELECT + col0 + - col0 / col1 AS col0 FROM tab2 AS cor0
----
7
75
77

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

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

query I rowsort
SELECT + + col1 + 4 FROM tab1 AS cor0
----
14
17
30

query I rowsort
SELECT DISTINCT + + col1 + ( col1 ) * + col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT + cor0.col2 * ( - col1 ) + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

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

skipif mysql # not compatible
query I rowsort label-365
SELECT - + cor0.col0 / - 20 + col2 AS col0 FROM tab2 AS cor0
----
27
29
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 2 ) + + col1 col0 FROM tab2 AS cor0
----
15
29
57

query I rowsort
SELECT - ( 71 ) + cor0.col1 * - 72 FROM tab0 AS cor0
----
-6263
-6623
-7055

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-370
SELECT + CAST( col1 AS SIGNED ) + - col2 AS col0 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-370
SELECT + CAST ( col1 AS INTEGER ) + - col2 AS col0 FROM tab0 AS cor0
----
53
9
96

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

query I rowsort
SELECT ALL - 89 FROM tab2, tab0 AS cor0
----
9 values hashing to 924a74d31360fa4301c953b423a4710e

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 22 * - 59 col0 FROM tab1 AS cor0
----
-1298
-1298
-1298

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

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

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

query I rowsort
SELECT cor0.col1 + 73 AS col0 FROM tab1 AS cor0
----
83
86
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-379
SELECT + - col0 DIV ( - 28 + cor0.col2 ) AS col0 FROM tab2 cor0
----
-7
39
7

skipif mysql # not compatible
query I rowsort label-379
SELECT + - col0 / ( - 28 + cor0.col2 ) AS col0 FROM tab2 cor0
----
-7
39
7

query I rowsort
SELECT ALL + 29 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-382
SELECT + cor0.col0 + - col2 DIV col0 + + cor0.col0 * 14 FROM tab2 AS cor0
----
102
1170
1185

skipif mysql # not compatible
query I rowsort label-382
SELECT + cor0.col0 + - col2 / col0 + + cor0.col0 * 14 FROM tab2 AS cor0
----
102
1170
1185

query I rowsort
SELECT ALL cor0.col2 - 17 FROM tab1 AS cor0
----
37
40
79

query I rowsort
SELECT ALL - col1 + ( 62 ) AS col2 FROM tab1 AS cor0
----
36
49
52

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

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

query I rowsort
SELECT - + 80 - col2 AS col0 FROM tab2 AS cor0
----
-106
-107
-118

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 - + col1 col2 FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT + + col2 - - 21 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1265
395
678

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

query I rowsort
SELECT - col2 + + 78 AS col0 FROM tab2
----
40
51
52

query I rowsort
SELECT + col0 * 1 + + 35 * col1 AS col1 FROM tab0
----
3034
3274
3430

query I rowsort
SELECT col1 + + 96 * + col0 AS col1 FROM tab2 AS cor0
----
703
7547
7601

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

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

query I rowsort
SELECT DISTINCT + 99 * + col0 * tab2.col1 AS col2 FROM tab2
----
132957
21483
455598

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

skipif mysql # not compatible
query I rowsort label-398
SELECT ( col0 ) / col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
10
13
26

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

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

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

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

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

query I rowsort
SELECT ( - col0 ) * col1 + 23 - - col1 * - ( - cor0.col2 ) AS col2 FROM tab2 AS cor0
----
-3045
-674
643

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

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

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

query I rowsort
SELECT ALL + col2 * - col2 * - 77 FROM tab2 AS cor0
----
111188
52052
56133

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 70 + - col2 col1 FROM tab1
----
-26
13
16

query I rowsort
SELECT - tab0.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

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

query I rowsort
SELECT - - 44 - cor0.col2 * ( col0 ) AS col0 FROM tab2 AS cor0
----
-145
-1984
-2958

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + 59 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
59

query I rowsort
SELECT ALL - 15 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT 4 + col1 * col2 FROM tab0
----
101
2842
7466

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

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

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

query I rowsort
SELECT ALL - 74 * - 86 FROM tab2
----
6364
6364
6364

query I rowsort
SELECT ALL + 69 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
2277
5658
69

query I rowsort
SELECT 33 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

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

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

skipif mysql # not compatible
query I rowsort label-428
SELECT + CAST ( + col1 AS INTEGER ) AS col2 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - col0 * - 65 AS col2 FROM tab2 AS cor0
----
455
5070
5135

query I rowsort
SELECT DISTINCT - col0 + 54 AS col1 FROM tab0 AS cor0
----
-35
19
30

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

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

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

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

query I rowsort
SELECT ALL + - cor0.col1 * col1 + 77 AS col0 FROM tab0 AS cor0
----
-7319
-8204
-9332

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

query I rowsort
SELECT DISTINCT + cor0.col1 * ( 56 + + col1 ) * 3 FROM tab2 AS cor0
----
20355
3723
8091

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-440
SELECT ALL col1 + col2 DIV 25 FROM tab0 AS cor0
----
87
94
97

skipif mysql # not compatible
query I rowsort label-440
SELECT ALL col1 + col2 / 25 FROM tab0 AS cor0
----
87
94
97

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col2 FROM tab0 cor0
----
86
91
97

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

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

query I rowsort
SELECT DISTINCT - + col1 * - 69 + cor0.col0 * col2 FROM tab2 AS cor0
----
2328
4175
6099

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT col0 * col0 - - col0 * col0 FROM tab1 AS cor0
----
12800
18
8192

query I rowsort
SELECT - cor1.col0 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-455
SELECT ALL + col0 * cor0.col1 DIV - 8 - - col0 FROM tab1 cor0
----
-16
-50
-6

skipif mysql # not compatible
query I rowsort label-455
SELECT ALL + col0 * cor0.col1 / - 8 - - col0 FROM tab1 cor0
----
-16
-50
-6

query I rowsort
SELECT 60 + - tab0.col0 FROM tab0
----
-29
25
36

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

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

query I rowsort
SELECT DISTINCT - 4 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
-4

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

query I rowsort
SELECT + col2 * + col2 * + 38 FROM tab2 cor0
----
25688
27702
54872

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

skipif mysql # not compatible
query I rowsort label-462
SELECT + col1 * CAST ( col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * 55 col1 FROM tab0
----
4730
5005
5335

query I rowsort
SELECT - 59 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

query I rowsort
SELECT + 53 * - 65 FROM tab2, tab2 AS cor0
----
9 values hashing to d6762adfd62d74710c08c59ce163bd17

query I rowsort
SELECT DISTINCT col1 * - 46 - col2 AS col0 FROM tab0 AS cor0
----
-3989
-4268
-4463

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * 95 + - col2 col1 FROM tab2 cor0
----
2444
2538
3572

onlyif mysql # use DIV operator for integer division
query I rowsort label-469
SELECT DISTINCT - col0 * - 23 * - cor0.col1 - col1 DIV 4 AS col1 FROM tab1 cor0
----
-14722
-1800
-23923

skipif mysql # not compatible
query I rowsort label-469
SELECT DISTINCT - col0 * - 23 * - cor0.col1 - col1 / 4 AS col1 FROM tab1 cor0
----
-14722
-1800
-23923

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

skipif mysql # not compatible
query I rowsort label-470
SELECT ALL col2 * - CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-2838
-7462
-97

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

query I rowsort
SELECT 56 + col0 AS col2 FROM tab0
----
145
80
91

query I rowsort
SELECT tab0.col2 * 52 AS col2 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 6132920580fa8c8176d261356fdbf084

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 73 + 28 col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to be97f57dbcc0951edc78f8cfa7ed1724

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

query I rowsort
SELECT DISTINCT - - ( 81 ) AS col1 FROM tab0 AS cor0
----
81

query I rowsort
SELECT DISTINCT 51 + cor0.col1 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-27
-589
-989

query I rowsort
SELECT - - 89 * + col1 AS col2 FROM tab2 AS cor0
----
1513
2759
5251

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

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

query I rowsort
SELECT + 48 * 37 * col1 FROM tab1 AS cor0
----
17760
23088
46176

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

query I rowsort
SELECT DISTINCT cor0.col1 + col1 * - ( 90 ) AS col0 FROM tab2 AS cor0
----
-1513
-2759
-5251

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-483
SELECT - + col0 * - col0 * + CAST( NULL AS DECIMAL ) 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-483
SELECT - + col0 * - col0 * + CAST ( NULL AS REAL ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + + col1 + + 25 * col1 FROM tab0 AS cor0
----
2269
2448
2523

query I rowsort
SELECT - ( + cor0.col2 ) + + 8 AS col0 FROM tab2 cor0
----
-18
-19
-30

query I rowsort
SELECT DISTINCT - ( + col0 ) * - 62 + cor0.col2 AS col2 FROM tab1 AS cor0
----
240
4025
5056

query I rowsort
SELECT + ( 54 ) * + cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 08085e5dd776fd51fb3fc0cc67f23f39

onlyif mysql # use DIV operator for integer division
query I rowsort label-488
SELECT DISTINCT 91 * cor0.col2 DIV - ( 4 ) FROM tab0 AS cor0
----
-1865
-22
-750

skipif mysql # not compatible
query I rowsort label-488
SELECT DISTINCT 91 * cor0.col2 / - ( 4 ) FROM tab0 AS cor0
----
-1865
-22
-750

query I rowsort
SELECT col0 + col0 * + 90 + + col2 * col1 FROM tab2 cor0
----
1474
7835
8632

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

query I rowsort
SELECT + col2 + - cor0.col2 * - 50 FROM tab0 AS cor0
----
1683
4182
51

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

query I rowsort
SELECT + ( col1 ) + col1 + + col2 FROM tab2 AS cor0
----
144
72
89

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

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

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

query I rowsort
SELECT DISTINCT + ( + col2 ) * + col2 + col1 AS col2 FROM tab2 AS cor0
----
1461
735
760

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to 82def1c3361e635dd4cf447edc22edb9

query I rowsort
SELECT ALL - 2 - + cor0.col0 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to fa911f04741ccf10678404b9018f0f49

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

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

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( - col0 AS REAL ) * - col0 AS col1 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT col1 * - col2 + col1 * ( tab0.col2 ) - col0 AS col1 FROM tab0
----
-24
-35
-89

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

query I rowsort
SELECT DISTINCT ( col1 ) * + col2 + - 87 FROM tab1
----
1161
1317
483

query I rowsort
SELECT col1 * 64 AS col2 FROM tab2
----
1088
1984
3776

onlyif mysql # use DIV operator for integer division
query I rowsort label-506
SELECT ALL col1 * col1 DIV - col0 AS col2 FROM tab2
----
-137
-3
-44

skipif mysql # not compatible
query I rowsort label-506
SELECT ALL col1 * col1 / - col0 AS col2 FROM tab2
----
-137
-3
-44

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

query I rowsort
SELECT DISTINCT 44 * col2 * col1 FROM tab1
----
25080
54912
61776

query I rowsort
SELECT + 7 AS col0 FROM tab0, tab0 cor0, tab1 cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

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

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

query I rowsort
SELECT - col1 * - ( + 36 ) FROM tab1 AS cor0
----
360
468
936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - ( 14 ) * col0 col2 FROM tab2 AS cor0
----
-1066
-1068
-71

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-516
SELECT DISTINCT - col1 * + col1 * CAST ( NULL AS REAL ) AS col2 FROM tab2
----
NULL

query I rowsort
SELECT + col2 * 34 AS col2 FROM tab0 AS cor0
----
1122
2788
34

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

query I rowsort
SELECT ALL col1 + + col1 + ( col0 ) * - 58 AS col2 FROM tab1 AS cor0
----
-122
-3692
-4614

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

query I rowsort
SELECT tab1.col2 * + col0 + - 45 AS col2 FROM tab1
----
117
3603
7635

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

query I rowsort
SELECT - col2 * - 26 AS col1 FROM tab0 AS cor0
----
2132
26
858

query I rowsort
SELECT DISTINCT - col1 * 31 + - 67 AS col0 FROM tab2 AS cor0
----
-1028
-1896
-594

query I rowsort
SELECT DISTINCT + col2 * 79 * col0 + col0 FROM tab2 AS cor0
----
14938
160290
237237

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-527
SELECT DISTINCT col0 * + col0 + col0 * col1 + col0 DIV col1 AS col0 FROM tab2 AS cor0
----
10687
266
7588

skipif mysql # not compatible
query I rowsort label-527
SELECT DISTINCT col0 * + col0 + col0 * col1 + col0 / col1 AS col0 FROM tab2 AS cor0
----
10687
266
7588

query I rowsort
SELECT DISTINCT - - col2 - - 19 * col0 AS col1 FROM tab2 AS cor0
----
1508
1539
160

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

query I rowsort
SELECT DISTINCT 12 + col0 AS col2 FROM tab2 AS cor0
----
19
90
91

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-533
SELECT ALL + CAST( + col0 AS SIGNED ) + col1 DIV + col1 col2 FROM tab0 cor0
----
25
36
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-533
SELECT ALL + CAST ( + col0 AS INTEGER ) + col1 / + col1 col2 FROM tab0 cor0
----
25
36
90

query I rowsort
SELECT ( - 88 ) * - col1 - - 19 AS col0 FROM tab0 AS cor0
----
7587
8027
8555

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

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

query I rowsort
SELECT + 6 * + 87 - + col1 FROM tab2 AS cor0
----
463
491
505

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

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

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

query I rowsort
SELECT - ( 57 ) AS col1 FROM tab0 AS cor0
----
-57
-57
-57

query I rowsort
SELECT ALL 38 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT col2 + + 67 FROM tab2
----
105
93
94

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

skipif mysql # not compatible
query I rowsort label-544
SELECT ALL - CAST ( col0 AS INTEGER ) + + col1 FROM tab2 cor0
----
-19
-62
24

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

skipif mysql # not compatible
query I rowsort label-545
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / + col2 + - col1 - + 82 AS col1 FROM tab2 AS cor0
----
NULL

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

query I rowsort
SELECT - - 52 * + cor0.col1 FROM tab1 cor0
----
1352
520
676

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

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

query I rowsort
SELECT DISTINCT col1 + + col2 * 16 AS col2 FROM tab2 cor0
----
463
475
625

query I rowsort
SELECT + - 32 * col1 + 3 * + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1394
1519
2714

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

query I rowsort
SELECT + + 75 * - col0 + + 79 FROM tab0 AS cor0
----
-1721
-2546
-6596

query I rowsort
SELECT DISTINCT + 1 + - cor0.col2 * cor0.col2 FROM tab2 AS cor0
----
-1443
-675
-728

query I rowsort
SELECT col2 * 49 FROM tab1
----
2646
2793
4704

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

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

query I rowsort
SELECT ALL + - 4 + col1 * col0 * + 17 FROM tab1 AS cor0
----
10876
1322
17676

query I rowsort
SELECT + ( - 71 ) + + cor1.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 4eef06bf82f2944720664b0411ae664d

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 52 col1 FROM tab0
----
52
52
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-563
SELECT ALL - 21 DIV 64 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-563
SELECT ALL - 21 / 64 FROM tab0
----
0
0
0

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

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

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

query I rowsort
SELECT ALL + - ( - col1 ) * 12 AS col0 FROM tab1 AS cor0
----
120
156
312

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

query I rowsort
SELECT + 8 + - col0 * col1 FROM tab1 cor0
----
-1032
-632
-70

query I rowsort
SELECT 96 * + col2 * - col1 FROM tab0 AS cor0
----
-272448
-716352
-9312

query I rowsort
SELECT + - 31 * col1 * - col0 AS col0 FROM tab1 cor0
----
19840
2418
32240

query I rowsort
SELECT col0 * col1 * + 93 FROM tab1 AS cor0
----
59520
7254
96720

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

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

query I rowsort
SELECT DISTINCT 30 + col0 * col2 FROM tab1 AS cor0
----
192
3678
7710

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

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

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

query I rowsort
SELECT ALL + - 57 + col2 FROM tab0 AS cor0
----
-24
-56
25

query I rowsort
SELECT ALL col0 + 74 FROM tab1
----
138
154
77

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

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

query I rowsort
SELECT ALL col1 * + cor0.col1 + col1 + col1 AS col1 FROM tab0 AS cor0
----
7568
8463
9603

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-583
SELECT - - col2 * + ( cor0.col0 ) + + col2 DIV 41 col2 FROM tab1 AS cor0
----
163
3649
7682

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-583
SELECT - - col2 * + ( cor0.col0 ) + + col2 / 41 col2 FROM tab1 AS cor0
----
163
3649
7682

query I rowsort
SELECT ALL col0 + 89 * + col1 + col1 * col2 AS col2 FROM tab1 AS cor0
----
1524
2485
3721

onlyif mysql # use DIV operator for integer division
query I rowsort label-585
SELECT DISTINCT - col1 + + ( col1 ) DIV - col2 FROM tab0 AS cor0
----
-194
-88
-92

skipif mysql # not compatible
query I rowsort label-585
SELECT DISTINCT - col1 + + ( col1 ) / - col2 FROM tab0 AS cor0
----
-194
-88
-92

query I rowsort
SELECT ALL - col0 * 89 + ( + cor0.col2 ) * + col0 FROM tab0 AS cor0
----
-1344
-3080
-623

query I rowsort
SELECT - col0 * + col2 + 34 FROM tab2 AS cor0
----
-155
-1994
-2968

query I rowsort
SELECT col2 + 14 AS col2 FROM tab0 AS cor0
----
15
47
96

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

query I rowsort
SELECT 51 * + 57 FROM tab1 AS cor0
----
2907
2907
2907

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

query I rowsort
SELECT DISTINCT 63 * 84 FROM tab0 AS cor0
----
5292

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + cor0.col0 * col1 + + 14 col0 FROM tab0 AS cor0
----
2045
3408
8031

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

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

query I rowsort
SELECT DISTINCT - ( col1 ) * + cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + 61 FROM tab2, tab2 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT cor0.col1 * 96 + col0 * - col1 AS col2 FROM tab1 cor0
----
208
2418
320

query I rowsort
SELECT - 4 * + col1 + col1 FROM tab2 AS cor0
----
-177
-51
-93

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

query I rowsort
SELECT + 87 * - col1 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-7506
-8006
-8474

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + ( col0 * - ( 81 ) ) col1 FROM tab2 AS cor0
----
-540
-6292
-6361

query I rowsort
SELECT + + 83 + col1 AS col1 FROM tab0 AS cor0
----
169
174
180

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

query I rowsort
SELECT - cor0.col2 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT - + 73 FROM tab1, tab2 AS cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

query I rowsort
SELECT DISTINCT + col0 * + col0 * + 99 FROM tab1
----
405504
633600
891

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-611
SELECT - cor0.col2 * + 64 * - ( col0 ) + - CAST( cor0.col2 AS SIGNED ) FROM tab1 AS cor0
----
10314
233415
491424

skipif mysql # not compatible
query I rowsort label-611
SELECT - cor0.col2 * + 64 * - ( col0 ) + - CAST ( cor0.col2 AS INTEGER ) FROM tab1 AS cor0
----
10314
233415
491424

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

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

query I rowsort
SELECT DISTINCT - tab0.col2 + 57 FROM tab0, tab1, tab1 AS cor0, tab2
----
-25
24
56

query I rowsort
SELECT 51 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT DISTINCT col2 + col2 * col0 FROM tab1 AS cor0 WHERE NULL = NULL
----

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col1 - col2 col0 FROM tab1
----
-1136
-132
-697

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

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

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

query I rowsort
SELECT col1 * - col2 + col0 + - col1 AS col2 FROM tab0
----
-159
-2900
-7464

query I rowsort
SELECT col0 AS col1 FROM tab1 WHERE NOT ( + col1 ) >= + col1
----

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL > - col1
----

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-628
SELECT ALL - col2 DIV col1 AS col2 FROM tab2
----
-2
0
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col1 col1 FROM tab0
----
2
62

query I rowsort
SELECT col2 * - col1 + col2 + + col1 FROM tab1 AS cor0
----
-1139
-1324
-503

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

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

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

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

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 <> - col1
----

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-639
SELECT ALL col0 DIV col0 + ( col2 ) * col1 col1 FROM tab2
----
1535
647
838

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-639
SELECT ALL col0 / col0 + ( col2 ) * col1 col1 FROM tab2
----
1535
647
838

query I rowsort
SELECT ALL - 70 + + col0 AS col2 FROM tab0
----
-35
-46
19

query I rowsort
SELECT ALL + + 33 * - cor0.col0 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to c558179f93e1b3182d54cac4cbc4db5a

query I rowsort
SELECT - 76 * + col0 + + col0 FROM tab2 cor0
----
-525
-5850
-5925

query I rowsort
SELECT 41 + + col0 AS col0 FROM tab0 AS cor0
----
130
65
76

query I rowsort
SELECT DISTINCT - 45 FROM tab0 cor0
----
-45

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

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

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

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-651
SELECT col1 + + ( - col2 ) / + col0 AS col2 FROM tab0 AS cor0
----
85
91
97

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

query I rowsort
SELECT DISTINCT col0 * col2 + + 68 * - col0 AS col2 FROM tab0 AS cor0
----
-2345
-840
1246

query I rowsort
SELECT col0 + 81 FROM tab1 AS cor0
----
145
161
84

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-657
SELECT ALL col2 DIV + col1 + + col0 + col1 FROM tab1
----
100
31
79

skipif mysql # not compatible
query I rowsort label-657
SELECT ALL col2 / + col1 + + col0 + col1 FROM tab1
----
100
31
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-658
SELECT DISTINCT col2 + col0 DIV + col0 + col2 FROM tab1
----
109
115
193

skipif mysql # not compatible
query I rowsort label-658
SELECT DISTINCT col2 + col0 / + col0 + col2 FROM tab1
----
109
115
193

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

query I rowsort
SELECT DISTINCT tab1.col2 + col0 * + col0 + + tab1.col1 AS col1 FROM tab1
----
4163
6509
89

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-662
SELECT - tab0.col2 * col0 * + col2 + - col2 DIV - tab0.col0 col1 FROM tab0
----
-26135
-35
-598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-662
SELECT - tab0.col2 * col0 * + col2 + - col2 / - tab0.col0 col1 FROM tab0
----
-26135
-35
-598436

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

query I rowsort
SELECT ALL col1 + col0 + col0 FROM tab1
----
138
173
32

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

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

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

query I rowsort
SELECT ALL tab2.col2 FROM tab2 WHERE col0 * col0 + col0 <= NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NULL BETWEEN col1 AND NULL
----

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

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

query I rowsort
SELECT DISTINCT tab0.col2 * col2 * col0 + + col2 AS col0 FROM tab0
----
26169
36
598518

query I rowsort
SELECT DISTINCT col1 * tab2.col2 * - col2 + + col2 * - col0 AS col0 FROM tab2
----
-22788
-27550
-41912

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

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

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

query I rowsort
SELECT + + col1 + col1 * cor0.col1 FROM tab2 AS cor0
----
306
3540
992

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

query I rowsort
SELECT DISTINCT - - col1 + cor0.col2 * col1 + col1 * col0 FROM tab2 AS cor0
----
1085
2006
6195

onlyif mysql # use DIV operator for integer division
query I rowsort label-678
SELECT 6 + - col2 DIV 47 FROM tab2 cor0
----
6
6
6

skipif mysql # not compatible
query I rowsort label-678
SELECT 6 + - col2 / 47 FROM tab2 cor0
----
6
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 60 * col0 + + 79 + col0 * + cor0.col1 col1 FROM tab0 AS cor0
----
13518
3583
5574

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

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

skipif mysql # not compatible
query I rowsort label-681
SELECT DISTINCT CAST ( NULL AS REAL ) AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-682
SELECT DISTINCT + cor0.col0 DIV + col0 + 69 col1 FROM tab2 AS cor0
----
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-682
SELECT DISTINCT + cor0.col0 / + col0 + 69 col1 FROM tab2 AS cor0
----
70

query I rowsort
SELECT DISTINCT - col1 * - col1 + col2 + col0 FROM tab2
----
3585
406
995

query I rowsort
SELECT DISTINCT col0 + - col1 + col0 * col1 FROM tab0
----
2002
3333
8097

onlyif mysql # use DIV operator for integer division
query I rowsort label-685
SELECT - col1 * col1 DIV - col0 FROM tab2
----
137
3
44

skipif mysql # not compatible
query I rowsort label-685
SELECT - col1 * col1 / - col0 FROM tab2
----
137
3
44

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

query I rowsort
SELECT ALL col2 + col1 + tab2.col2 * - col1 AS col0 FROM tab2
----
-1449
-591
-779

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 col2 FROM tab0 WHERE NOT NULL < - col0
----

query I rowsort
SELECT col1 * ( col1 + - col2 ) AS col0 FROM tab0 AS cor0
----
4558
819
9312

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

query I rowsort
SELECT ALL 11 + col1 + col2 FROM tab0
----
109
130
184

onlyif mysql # use DIV operator for integer division
query I rowsort label-693
SELECT DISTINCT - cor0.col2 DIV col0 - col2 FROM tab2 AS cor0
----
-26
-30
-38

skipif mysql # not compatible
query I rowsort label-693
SELECT DISTINCT - cor0.col2 / col0 - col2 FROM tab2 AS cor0
----
-26
-30
-38

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

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

query I rowsort
SELECT - col2 * col2 + 1 * col0 * - cor0.col0 FROM tab0 AS cor0
----
-1226
-14645
-1665

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 + - 6 col0 FROM tab0
----
2832
7456
91

query I rowsort
SELECT 17 * col2 FROM tab1
----
1632
918
969

query I rowsort
SELECT - col0 + - col2 * - col0 * + col1 FROM tab1
----
36416
4209
99760

query I rowsort
SELECT - col1 + tab1.col0 * col0 FROM tab1
----
-17
4086
6387

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-703
SELECT ALL + col1 + ( 54 ) DIV col0 FROM tab0 AS cor0
----
88
91
98

skipif mysql # not compatible
query I rowsort label-703
SELECT ALL + col1 + ( 54 ) / col0 FROM tab0 AS cor0
----
88
91
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-704
SELECT ALL - col2 * - ( 13 ) + col2 + + col2 DIV + col1 AS col1 FROM tab1 AS cor0
----
1351
758
803

skipif mysql # not compatible
query I rowsort label-704
SELECT ALL - col2 * - ( 13 ) + col2 + + col2 / + col1 AS col1 FROM tab1 AS cor0
----
1351
758
803

onlyif mysql # use DIV operator for integer division
query I rowsort label-705
SELECT DISTINCT + col0 + col2 DIV cor0.col0 - - cor0.col2 * - col2 AS col0 FROM tab1 AS cor0
----
-2895
-3185
-9135

skipif mysql # not compatible
query I rowsort label-705
SELECT DISTINCT + col0 + col2 / cor0.col0 - - cor0.col2 * - col2 AS col0 FROM tab1 AS cor0
----
-2895
-3185
-9135

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

skipif mysql # not compatible
query I rowsort label-706
SELECT ALL col2 * + CAST ( - ( col1 ) AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

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

query I rowsort
SELECT ALL ( - 53 ) * col0 + col1 * tab2.col2 * col0 + col2 AS col0 FROM tab2
----
115544
46885
5515

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

query I rowsort
SELECT ALL + col2 * 44 + col1 - ( col1 ) AS col2 FROM tab0
----
1452
3608
44

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

query I rowsort
SELECT + 69 * + col1 - col0 FROM tab0 AS cor0
----
5910
6190
6658

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

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

query I rowsort
SELECT 2 * - col0 + col2 * col0 - - col1 AS col0 FROM tab2 AS cor0
----
1931
206
2861

query I rowsort
SELECT DISTINCT - + 9 * - col1 AS col1 FROM tab1 AS cor0
----
117
234
90

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

query I rowsort
SELECT + col1 * col1 + col2 * col1 + cor0.col0 AS col0 FROM tab1 cor0
----
1497
2083
734

query I rowsort
SELECT DISTINCT - + col2 * col0 * ( 90 ) AS col0 FROM tab0 AS cor0
----
-3150
-656820
-71280

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

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

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

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

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

query I rowsort
SELECT DISTINCT - ( + col0 ) * col2 + col2 * - col2 FROM tab1 AS cor0
----
-16896
-3078
-6897

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

skipif mysql # not compatible
query I rowsort label-725
SELECT ALL - + col2 + col2 / col2 AS col2 FROM tab0 AS cor0
----
-32
-81
0

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

query I rowsort
SELECT + 23 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-2047
-552
-805

query I rowsort
SELECT - 31 + col2 * + col2 AS col2 FROM tab2 cor0
----
1413
645
698

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

query I rowsort
SELECT ALL + 57 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
4902
5187
5529

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

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

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

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

query IIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 WHERE NOT NULL > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-735
SELECT + col2 * cor0.col0 + + cor0.col0 + cor0.col2 DIV col0 FROM tab1 AS cor0
----
183
3712
7761

skipif mysql # not compatible
query I rowsort label-735
SELECT + col2 * cor0.col0 + + cor0.col0 + cor0.col2 / col0 FROM tab1 AS cor0
----
183
3712
7761

onlyif mysql # use DIV operator for integer division
query I rowsort label-736
SELECT + + col1 + + col2 + col1 DIV col2 AS col0 FROM tab0 AS cor0
----
121
174
195

skipif mysql # not compatible
query I rowsort label-736
SELECT + + col1 + + col2 + col1 / col2 AS col0 FROM tab0 AS cor0
----
121
174
195

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col2 * col0 + col1 + col1 col1 FROM tab0
----
229
7480
964

query I rowsort
SELECT 85 + + col2 + - tab0.col1 * - col0 AS col2 FROM tab0
----
2182
3481
8266

query I rowsort
SELECT + col1 - col0 * - cor0.col2 * col2 AS col2 FROM tab2 AS cor0
----
114093
5134
52787

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 - + ( - col0 ) col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT DISTINCT 48 + - col2 AS col1 FROM tab2 AS cor0
----
10
21
22

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

query I rowsort
SELECT + 71 + - ( col0 ) FROM tab2 AS cor0
----
-7
-8
64

query I rowsort
SELECT - 25 * - col0 AS col1 FROM tab2 AS cor0
----
175
1950
1975

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

query I rowsort
SELECT 28 * ( - col0 * col2 ) FROM tab1 AS cor0
----
-102144
-215040
-4536

query I rowsort
SELECT + 12 * col2 * - col2 + col2 * col0 AS col1 FROM tab2 AS cor0
----
-14326
-6084
-8559

onlyif mysql # use DIV operator for integer division
query I rowsort label-748
SELECT ( col2 ) DIV col1 + col2 * col2 FROM tab2
----
1446
676
729

skipif mysql # not compatible
query I rowsort label-748
SELECT ( col2 ) / col1 + col2 * col2 FROM tab2
----
1446
676
729

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

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

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

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

query I rowsort
SELECT + 38 + - col2 AS col0 FROM tab0 AS cor0
----
-44
37
5

query I rowsort
SELECT DISTINCT 50 * - col1 * tab2.col2 AS col2 FROM tab2
----
-32300
-41850
-76700

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

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

query I rowsort
SELECT DISTINCT + 92 * 73 FROM tab2 AS cor0
----
6716

query I rowsort
SELECT ALL + + 70 * col2 + + col1 FROM tab0 AS cor0
----
167
2396
5831

query I rowsort
SELECT - 18 * col2 + + cor0.col0 * col0 AS col1 FROM tab0 AS cor0
----
-18
1207
6445

query I rowsort
SELECT cor0.col0 * 53 AS col2 FROM tab2 AS cor0
----
371
4134
4187

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-761
SELECT DISTINCT + 91 * - col0 + CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
-270
-5760
-7200

skipif mysql # not compatible
query I rowsort label-761
SELECT DISTINCT + 91 * - col0 + CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
-270
-5760
-7200

query I rowsort
SELECT + 9 + col1 * col2 FROM tab0 AS cor0
----
106
2847
7471

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

query I rowsort
SELECT ALL - - col1 * col1 * col2 AS col0 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT - 40 * + col1 FROM tab0 cor0
----
-3440
-3640
-3880

query I rowsort
SELECT DISTINCT + 62 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
62

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

query I rowsort
SELECT - col2 * col0 + 77 FROM tab0 cor0
----
-715
-7221
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-769
SELECT ALL cor0.col2 + col1 * ( - col2 ) - + 31 DIV 63 FROM tab1 AS cor0
----
-1152
-1350
-513

skipif mysql # not compatible
query I rowsort label-769
SELECT ALL cor0.col2 + col1 * ( - col2 ) - + 31 / 63 FROM tab1 AS cor0
----
-1152
-1350
-513

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

query I rowsort
SELECT ALL - col0 * 80 AS col1 FROM tab2 AS cor0
----
-560
-6240
-6320

query I rowsort
SELECT - col2 + 93 FROM tab0 cor0
----
11
60
92

query I rowsort
SELECT 46 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT ALL col2 * + 62 FROM tab2 AS cor0
----
1612
1674
2356

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - tab1.col1 * - 28 col0 FROM tab1
----
344
444
731

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

query I rowsort
SELECT tab2.col2 + + 87 + + 73 FROM tab2
----
186
187
198

query I rowsort
SELECT tab2.col0 * + 32 FROM tab2
----
224
2496
2528

query I rowsort
SELECT col1 * ( 12 ) FROM tab1
----
120
156
312

query I rowsort
SELECT ALL 72 - 34 FROM tab0, tab2 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT ALL + - 77 * col0 * + cor0.col1 + ( - col2 + col1 ) FROM tab1 AS cor0
----
-49327
-6034
-80163

onlyif mysql # use DIV operator for integer division
query I rowsort label-784
SELECT + + col1 DIV cor0.col2 - col0 * + 35 FROM tab1 AS cor0
----
-105
-2240
-2800

skipif mysql # not compatible
query I rowsort label-784
SELECT + + col1 / cor0.col2 - col0 * + 35 FROM tab1 AS cor0
----
-105
-2240
-2800

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

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

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

query I rowsort
SELECT ALL + 36 * col1 + + cor0.col2 FROM tab0 AS cor0
----
3129
3358
3493

query I rowsort
SELECT 45 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab2 cor2
----
81 values hashing to 8a6d20810140ea088e8e0fd74ffb8339

onlyif mysql # use DIV operator for integer division
query I rowsort label-789
SELECT DISTINCT 55 * col0 + col0 DIV - ( col2 + - cor0.col0 ) AS col0 FROM tab2 AS cor0
----
385
4291
4346

skipif mysql # not compatible
query I rowsort label-789
SELECT DISTINCT 55 * col0 + col0 / - ( col2 + - cor0.col0 ) AS col0 FROM tab2 AS cor0
----
385
4291
4346

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

skipif mysql # not compatible
query I rowsort label-790
SELECT DISTINCT + + col2 / col1 + + col2 AS col1 FROM tab2 cor0
----
26
27
40

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 * col1 col0 FROM tab0 AS cor0
----
6192
6552
6984

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

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

query I rowsort
SELECT ALL col0 * col1 - + 96 AS col0 FROM tab2
----
121
1247
4506

query I rowsort
SELECT DISTINCT + ( - 48 ) FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab1 AS cor2, tab0 AS cor3
----
-48

query I rowsort
SELECT ALL col1 * - 71 + col2 * col1 * - col2 AS col0 FROM tab0
----
-618345
-6984
-99760

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

skipif mysql # not compatible
query I rowsort label-798
SELECT ALL + tab1.col1 * - CAST ( - col0 AS INTEGER ) + + col1 FROM tab1
----
104
1053
650

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-801
SELECT ALL + 38 DIV col0 + - col0 FROM tab1
----
-64
-80
9

skipif mysql # not compatible
query I rowsort label-801
SELECT ALL + 38 / col0 + - col0 FROM tab1
----
-64
-80
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col1 ) + tab1.col1 col1 FROM tab1
----
20
26
52

query I rowsort
SELECT col2 - col1 * tab0.col2 AS col0 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT - col1 + 81 AS col1 FROM tab2
----
22
50
64

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-806
SELECT DISTINCT + - col2 + - col0 DIV col2 AS col0 FROM tab0 AS cor0
----
-33
-36
-83

skipif mysql # not compatible
query I rowsort label-806
SELECT DISTINCT + - col2 + - col0 / col2 AS col0 FROM tab0 AS cor0
----
-33
-36
-83

query I rowsort
SELECT + col0 * - cor0.col0 + - cor0.col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1152
-15842
-2450

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

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-812
SELECT + cor0.col2 * + CAST( - 41 AS SIGNED ) FROM tab1 AS cor0
----
-2214
-2337
-3936

skipif mysql # not compatible
query I rowsort label-812
SELECT + cor0.col2 * + CAST ( - 41 AS INTEGER ) FROM tab1 AS cor0
----
-2214
-2337
-3936

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

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

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

query I rowsort
SELECT + - col2 - + 4 AS col0 FROM tab2 AS cor0
----
-30
-31
-42

query I rowsort
SELECT + + col0 + col2 - cor0.col2 * - col0 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT ALL cor0.col2 * 34 + + 1 * - col0 AS col2 FROM tab2 AS cor0
----
1213
806
911

query I rowsort
SELECT ALL - cor0.col0 * 18 + - col1 FROM tab2 cor0
----
-1439
-1463
-157

query I rowsort
SELECT DISTINCT + col0 - + 31 FROM tab0 AS cor0
----
-7
4
58

query I rowsort
SELECT + col1 * 71 - - cor0.col2 AS col2 FROM tab1 cor0
----
1019
1900
767

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

query I rowsort
SELECT + - col1 * 68 + + col1 * + col1 AS col0 FROM tab2 AS cor0
----
-1147
-531
-867

onlyif mysql # use DIV operator for integer division
query I rowsort label-824
SELECT - col1 DIV col0 + + 0 - col1 FROM tab1 AS cor0
----
-10
-13
-34

skipif mysql # not compatible
query I rowsort label-824
SELECT - col1 / col0 + + 0 - col1 FROM tab1 AS cor0
----
-10
-13
-34

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

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

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

query I rowsort
SELECT + col2 * + cor0.col1 + + col0 AS col2 FROM tab2 cor0
----
1612
725
844

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 - 58 * + col0 + - cor0.col0 FROM tab1 AS cor0
----
-177
-3776
-4720

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

query I rowsort
SELECT + col1 * - cor0.col2 + col1 * + 33 + + col0 FROM tab2 AS cor0
----
-6
193
491

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 + - 4 + + col1 AS col2 FROM tab0 AS cor0
----
-1982
-3302
-8012

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

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

query I rowsort
SELECT - cor0.col1 + + cor0.col1 + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + - col2 + + col0 * ( col1 ) * cor0.col1 FROM tab0 cor0
----
177471
329314
736927

query I rowsort
SELECT - + col1 + - 94 + col1 * - col1 FROM tab0 AS cor0
----
-7576
-8466
-9600

query I rowsort
SELECT DISTINCT 80 + tab2.col2 * 2 AS col0 FROM tab2
----
132
134
156

query I rowsort
SELECT + + cor0.col1 * - 95 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to a55f8c8cde3ac25ae6cd52eddedd6d13

query I rowsort
SELECT DISTINCT + - 80 - 15 FROM tab1 AS cor0
----
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 72 ) * - col0 col0 FROM tab2 cor0
----
504
5616
5688

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col0 + + col0 * - col0 * CAST ( col2 AS REAL ) FROM tab1 AS cor0
----
-233536
-489
-614480

onlyif mysql # use DIV operator for integer division
query I rowsort label-845
SELECT DISTINCT - + col2 * 55 + - col1 DIV + 98 FROM tab2 AS cor0
----
-1430
-1485
-2090

skipif mysql # not compatible
query I rowsort label-845
SELECT DISTINCT - + col2 * 55 + - col1 / + 98 FROM tab2 AS cor0
----
-1430
-1485
-2090

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

skipif mysql # not compatible
query I rowsort label-846
SELECT ALL - CAST ( + cor0.col1 AS INTEGER ) * col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-847
SELECT ALL 53 + 58 DIV - col1 FROM tab2 cor0
----
50
52
53

skipif mysql # not compatible
query I rowsort label-847
SELECT ALL 53 + 58 / - col1 FROM tab2 cor0
----
50
52
53

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

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

query I rowsort
SELECT col0 * 33 * col0 AS col1 FROM tab1 AS cor0
----
135168
211200
297

query I rowsort
SELECT DISTINCT + + col2 * + 2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT 87 + col0 AS col0 FROM tab2 AS cor0
----
165
166
94

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

query I rowsort
SELECT DISTINCT + 68 + cor0.col0 AS col0 FROM tab2 AS cor0
----
146
147
75

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

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

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

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

query I rowsort
SELECT DISTINCT - ( col0 + - col0 ) * - ( 57 ) FROM tab2
----
0

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-862
SELECT ALL + CAST( 70 AS SIGNED ) + cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to afef4ac2a7c153294e1ee5833d9f08e4

skipif mysql # not compatible
query I rowsort label-862
SELECT ALL + CAST ( 70 AS INTEGER ) + cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to afef4ac2a7c153294e1ee5833d9f08e4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-863
SELECT DISTINCT - col0 * - CAST( ( + col0 ) * ( 72 ) AS SIGNED ) FROM tab0
----
41472
570312
88200

skipif mysql # not compatible
query I rowsort label-863
SELECT DISTINCT - col0 * - CAST ( ( + col0 ) * ( 72 ) AS INTEGER ) FROM tab0
----
41472
570312
88200

query I rowsort
SELECT ALL - col0 * - col2 + + col0 * - col0 AS col1 FROM tab1 cor0
----
-448
1280
153

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-867
SELECT + ( col2 ) + + col2 * 30 DIV col2 AS col1 FROM tab1 AS cor0
----
126
84
87

skipif mysql # not compatible
query I rowsort label-867
SELECT + ( col2 ) + + col2 * 30 / col2 AS col1 FROM tab1 AS cor0
----
126
84
87

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

query I rowsort
SELECT col0 + 83 FROM tab1
----
147
163
86

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

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

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

query I rowsort
SELECT DISTINCT + - cor0.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-24
-35
-89

query I rowsort
SELECT + - col0 * - col2 + col0 + col0 AS col0 FROM tab1 cor0
----
168
3776
7840

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

query I rowsort
SELECT - 34 * col0 * - col1 FROM tab0 AS cor0
----
115430
275366
70176

query I rowsort
SELECT tab2.col2 - col2 FROM tab2
----
0
0
0

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

query I rowsort
SELECT DISTINCT col2 + - 10 AS col2 FROM tab2 cor0
----
16
17
28

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

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

query I rowsort
SELECT DISTINCT col2 * + 99 + 15 FROM tab2 cor0
----
2589
2688
3777

query I rowsort
SELECT col0 * - 59 AS col2 FROM tab1 AS cor0
----
-177
-3776
-4720

query I rowsort
SELECT ALL + col1 * + col1 + col1 + + col2 AS col2 FROM tab0 AS cor0
----
7515
8454
9507

query I rowsort
SELECT 19 * cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to fa80d67a77cef9463bc185ea9e379d2b

query I rowsort
SELECT col0 + - 11 * - col2 + col1 AS col1 FROM tab0 AS cor0
----
1082
143
473

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

skipif mysql # not compatible
query I rowsort label-885
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) - col1 FROM tab1
----
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-887
SELECT ALL CAST( 22 AS SIGNED ) - - col2 DIV + col1 FROM tab2
----
22
22
24

skipif mysql # not compatible
query I rowsort label-887
SELECT ALL CAST ( 22 AS INTEGER ) - - col2 / + col1 FROM tab2
----
22
22
24

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

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

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) * - 52 FROM tab0, tab0 AS cor0
----
-1716
-4264
-52

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

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

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

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

query I rowsort
SELECT + 3 * col1 + + 95 * col2 FROM tab2 AS cor0
----
2647
2658
3661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + cor0.col2 col0 FROM tab0 AS cor0
----
164
2
66

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

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

skipif mysql # not compatible
query I rowsort label-896
SELECT + col1 - + col1 * CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
110
182
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-897
SELECT + 27 DIV - col2 + - 80 DIV cor0.col0 FROM tab0 AS cor0
----
-29
-3
0

skipif mysql # not compatible
query I rowsort label-897
SELECT + 27 / - col2 + - 80 / cor0.col0 FROM tab0 AS cor0
----
-29
-3
0

query I rowsort
SELECT - col0 + cor0.col0 * 49 + cor0.col1 FROM tab2 AS cor0
----
367
3803
3809

onlyif mysql # use DIV operator for integer division
query I rowsort label-899
SELECT ALL - 78 DIV + 9 AS col2 FROM tab2
----
-8
-8
-8

skipif mysql # not compatible
query I rowsort label-899
SELECT ALL - 78 / + 9 AS col2 FROM tab2
----
-8
-8
-8

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

query I rowsort
SELECT - col2 - col1 * - ( col2 ) FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT - 14 * col2 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-1237
-486
-49

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

query I rowsort
SELECT DISTINCT + col0 * - col1 + col0 * - col2 AS col0 FROM tab1 AS cor0
----
-240
-4288
-8720

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

skipif mysql # not compatible
query I rowsort label-905
SELECT ALL - col2 * + col0 / - col0 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT - 35 + + col1 * + ( + col2 ) FROM tab0 cor0
----
2803
62
7427

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

query I rowsort
SELECT ALL + col1 * 67 AS col0 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT ALL + col0 + ( + 69 ) * - cor0.col1 + 64 AS col1 FROM tab1 AS cor0
----
-1727
-562
-753

onlyif mysql # use DIV operator for integer division
query I rowsort label-910
SELECT + - col2 * 66 - col1 DIV col0 FROM tab2 AS cor0
----
-1716
-1786
-2508

skipif mysql # not compatible
query I rowsort label-910
SELECT + - col2 * 66 - col1 / col0 FROM tab2 AS cor0
----
-1716
-1786
-2508

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

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

query I rowsort
SELECT 74 * - col1 + - col2 * col0 + + col0 FROM tab0
----
-13943
-7132
-7178

onlyif mysql # use DIV operator for integer division
query I rowsort label-913
SELECT col0 + + col0 - 0 * - col2 DIV col0 FROM tab2
----
14
156
158

skipif mysql # not compatible
query I rowsort label-913
SELECT col0 + + col0 - 0 * - col2 / col0 FROM tab2
----
14
156
158

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

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

skipif mysql # not compatible
query I rowsort label-915
SELECT ALL + + CAST ( + col0 AS INTEGER ) + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - 35 + + col2 * col0 FROM tab1 AS cor0
----
127
3613
7645

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

query I rowsort
SELECT DISTINCT - 55 AS col1 FROM tab2 cor0
----
-55

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

query I rowsort
SELECT ALL - 80 * + col2 FROM tab1 AS cor0
----
-4320
-4560
-7680

query I rowsort
SELECT DISTINCT - col2 * + 32 FROM tab0
----
-1056
-2624
-32

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( - col0 ) - col2 col1 FROM tab1 AS cor0
----
-16
-51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + 38 col0 FROM tab2 AS cor0
----
116
117
45

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

query I rowsort
SELECT ALL - col0 * + 3 + col1 * col1 FROM tab0
----
7324
8014
9304

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

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

query I rowsort
SELECT col2 - ( col2 ) FROM tab2
----
0
0
0

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

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

query I rowsort
SELECT ALL + 59 - col0 FROM tab0 AS cor0
----
-30
24
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-933
SELECT DISTINCT + ( col1 ) + + col1 DIV + cor0.col0 AS col1 FROM tab2 AS cor0
----
17
35
59

skipif mysql # not compatible
query I rowsort label-933
SELECT DISTINCT + ( col1 ) + + col1 / + cor0.col0 AS col1 FROM tab2 AS cor0
----
17
35
59

query I rowsort
SELECT col1 * - col0 + col0 + col2 * ( - ( + col1 ) ) * - 21 FROM tab0
----
-1323
148692
57558

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-936
SELECT col0 DIV - 79 + col2 AS col0 FROM tab0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-936
SELECT col0 / - 79 + col2 AS col0 FROM tab0
----
1
33
81

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

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

query I rowsort
SELECT + + 26 * 73 + - col1 AS col1 FROM tab2 cor0
----
1839
1867
1881

onlyif mysql # use DIV operator for integer division
query I rowsort label-939
SELECT - col2 + + cor0.col1 * col2 DIV - 93 FROM tab0 AS cor0
----
-162
-2
-63

skipif mysql # not compatible
query I rowsort label-939
SELECT - col2 + + cor0.col1 * col2 / - 93 FROM tab0 AS cor0
----
-162
-2
-63

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

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

query I rowsort
SELECT ALL - - 64 FROM tab0 AS cor0
----
64
64
64

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

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) * - col1 - ( + col1 ) FROM tab1 cor0
----
-110
-182
-702

query I rowsort
SELECT DISTINCT + col2 + - 61 * col0 AS col2 FROM tab0 AS cor0
----
-1431
-2134
-5347

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

query I rowsort
SELECT DISTINCT + 92 + col2 * col2 FROM tab1 AS cor0
----
3008
3341
9308

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 38 ) * - col0 col0 FROM tab2 AS cor0
----
266
2964
3002

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

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

query I rowsort
SELECT DISTINCT + col0 + + ( 90 * - col2 ) AS col0 FROM tab2
----
-2262
-2423
-3341

onlyif mysql # use DIV operator for integer division
query I rowsort label-951
SELECT col1 * col0 + ( col1 ) DIV col1 + - ( + col0 ) * - 42 FROM tab0
----
11838
3073
4866

skipif mysql # not compatible
query I rowsort label-951
SELECT col1 * col0 + ( col1 ) / col1 + - ( + col0 ) * - 42 FROM tab0
----
11838
3073
4866

onlyif mysql # use DIV operator for integer division
query I rowsort label-952
SELECT - ( - 88 ) DIV + col2 AS col0 FROM tab0 AS cor0
----
1
2
88

skipif mysql # not compatible
query I rowsort label-952
SELECT - ( - 88 ) / + col2 AS col0 FROM tab0 AS cor0
----
1
2
88

query I rowsort
SELECT + col1 * - cor0.col2 + col1 * - col1 - col0 FROM tab1 AS cor0
----
-1497
-2083
-734

query I rowsort
SELECT 19 + 51 AS col0 FROM tab0 AS cor0
----
70
70
70

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - col2 AS REAL ) - - col1 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - col2 - col1 * 74 AS col1 FROM tab0 AS cor0
----
-6397
-6816
-7179

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

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

query I rowsort
SELECT DISTINCT col2 * col2 + 65 FROM tab2 AS cor0
----
1509
741
794

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

query I rowsort
SELECT - col2 * col2 + 97 AS col1 FROM tab1 AS cor0
----
-2819
-3152
-9119

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

skipif mysql # not compatible
query I rowsort label-962
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + 5 * + col1 / - 25 FROM tab0
----
NULL

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

query I rowsort
SELECT DISTINCT - + col2 - col0 * ( + 16 ) FROM tab2 AS cor0
----
-1274
-1302
-139

query I rowsort
SELECT - 97 + col1 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1137
-175
-737

query I rowsort
SELECT DISTINCT + 18 * + col0 + ( - 99 ) + cor0.col2 FROM tab2 cor0
----
1331
1361
54

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

skipif mysql # not compatible
query I rowsort label-967
SELECT DISTINCT col2 / - col1 + - col1 * - col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-968
SELECT ALL col2 * + col2 DIV CAST( col2 AS SIGNED ) col0 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-968
SELECT ALL col2 * + col2 / CAST ( col2 AS INTEGER ) col0 FROM tab0
----
1
33
82

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col2 * + cor2.col1 ) + cor1.col2 col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to b40ae36bd6f611b017f35d7ce4a98aad

query I rowsort
SELECT - col0 * col2 + + ( 85 ) AS col2 FROM tab2 AS cor0
----
-104
-1943
-2917

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

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

query I rowsort
SELECT ( + 10 ) AS col2 FROM tab2
----
10
10
10

query I rowsort
SELECT 78 AS col0 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
81 values hashing to f0487ba81d377516702723e098c02ba1

query I rowsort
SELECT 77 * col2 AS col0 FROM tab2
----
2002
2079
2926

query I rowsort
SELECT DISTINCT + 89 * - col0 AS col1 FROM tab1
----
-267
-5696
-7120

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

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

query I rowsort
SELECT ALL - - 52 * - cor0.col1 AS col2 FROM tab2 cor0
----
-1612
-3068
-884

query I rowsort
SELECT - 47 * cor0.col0 * col2 + col1 AS col2 FROM tab2 AS cor0
----
-141077
-8852
-95257

query I rowsort
SELECT 97 * - col1 + + 58 FROM tab2 AS cor0
----
-1591
-2949
-5665

query I rowsort
SELECT - col2 * - col2 - col0 AS col0 FROM tab0 AS cor0
----
-34
1065
6635

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

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

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

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

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

query I rowsort
SELECT DISTINCT + col1 * - col1 + col1 * col0 + + col1 * + cor0.col0 * + col0 FROM tab1 AS cor0
----
-364
41500
84071

onlyif mysql # use DIV operator for integer division
query I rowsort label-989
SELECT DISTINCT - col1 * col0 + col0 DIV + col0 FROM tab0 AS cor0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-989
SELECT DISTINCT - col1 * col0 + col0 / + col0 FROM tab0 AS cor0
----
-2063
-3394
-8098

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

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

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

query I rowsort
SELECT ALL col1 + - col2 + cor0.col2 * col1 * col0 AS col2 FROM tab0 AS cor0
----
3491
664127
68165

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-995
SELECT DISTINCT - cor0.col0 / - cor0.col0 - col2 col1 FROM tab0 AS cor0
----
-32
-81
0

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

query I rowsort
SELECT col0 * - col0 * - col2 AS col0 FROM tab1
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - tab2.col0 + - col1 col2 FROM tab2
----
-1360
-248
-4661

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1000
SELECT ALL col0 + col1 * - cor0.col0 + - col2 DIV + col1 AS col0 FROM tab2 AS cor0
----
-1266
-210
-4524

skipif mysql # not compatible
query I rowsort label-1000
SELECT ALL col0 + col1 * - cor0.col0 + - col2 / + col1 AS col0 FROM tab2 AS cor0
----
-1266
-210
-4524

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

query I rowsort
SELECT DISTINCT - cor0.col2 - cor1.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 42327f69747766ff4b5513d67e3eeaf6

query I rowsort
SELECT DISTINCT - 45 * col1 AS col2 FROM tab0
----
-3870
-4095
-4365

query I rowsort
SELECT DISTINCT - 11 * col2 FROM tab0
----
-11
-363
-902

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

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

query I rowsort
SELECT + cor0.col0 * - cor0.col2 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 18f45a7edd86e3eccc832dcdb6123662

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * cor0.col0 col2 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL col1 + col0 * col0 * col0 AS col0 FROM tab0
----
13910
42972
705060

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

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL BETWEEN col1 / + col2 AND - col2 * col2
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL BETWEEN NULL AND - col2
----

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

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

query I rowsort
SELECT ALL - col0 * col2 * ( col2 + - col0 * col1 ) AS col2 FROM tab1 AS cor0
----
2126784
3888
7249920

onlyif mysql # use DIV operator for integer division
query I rowsort label-1015
SELECT DISTINCT tab1.col2 DIV col1 + + col2 col0 FROM tab1
----
103
56
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1015
SELECT DISTINCT tab1.col2 / col1 + + col2 col0 FROM tab1
----
103
56
62

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

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

query I rowsort
SELECT DISTINCT col2 + col1 * + 2 * col0 AS col1 FROM tab2 cor0
----
2724
461
9230

query I rowsort
SELECT ALL cor1.col1 * cor1.col2 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to f8894e3f33962cda5901e1c2ce65d5b0

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

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

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

skipif mysql # not compatible
query I rowsort label-1021
SELECT - col2 / tab1.col2 AS col0 FROM tab1
----
-1
-1
-1

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

query I rowsort
SELECT DISTINCT - 50 * - col0 FROM tab1 AS cor0
----
150
3200
4000

query III rowsort
SELECT * FROM tab1 WHERE NOT tab1.col2 * col2 > col2
----

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL IN ( - col2 )
----

query I rowsort
SELECT - col0 AS col0 FROM tab1 WHERE NULL NOT IN ( col2 )
----

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

query I rowsort
SELECT col2 * + col1 + + col2 * col1 AS col0 FROM tab0 cor0
----
14924
194
5676

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col1 * col0 col2 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - col2 FROM tab1 WHERE col1 + col2 + col1 <> + col1
----
-54
-57
-96

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

query I rowsort
SELECT ALL + tab1.col0 + - col2 AS col2 FROM tab1 WHERE NOT + col2 * - col2 >= ( col1 )
----
-16
-51
7

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

query I rowsort
SELECT + col2 * col2 + col1 * col2 + - col2 AS col1 FROM tab2
----
1539
2052
2184

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

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

query I rowsort
SELECT - col1 * col0 + - col2 FROM tab1
----
-1136
-132
-697

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

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

query I rowsort
SELECT + col0 * + col2 + col2 * + col1 FROM tab2
----
1026
3562
3648

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

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

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

query I rowsort
SELECT + 47 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT ( + 61 ) FROM tab2
----
61
61
61

query I rowsort
SELECT - - 36 * col2 AS col0 FROM tab0 AS cor0
----
1188
2952
36

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

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

query I rowsort
SELECT ALL - 24 + + 7 FROM tab1, tab2 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT + col2 * 11 FROM tab2
----
286
297
418

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

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

query I rowsort
SELECT DISTINCT col1 * - 79 + + 20 * - col1 FROM tab1
----
-1287
-2574
-990

query I rowsort
SELECT DISTINCT + ( 34 ) FROM tab1, tab0 AS cor0
----
34

query I rowsort
SELECT col0 * - col2 + col2 + + col0 * 56 FROM tab1 AS cor0
----
-3104
-7
60

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

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

query I rowsort
SELECT - ( 41 ) AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

query I rowsort
SELECT ALL + 61 * + 84 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 3de2700e6615c12f6d231830cbab2094

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 40 + col1 col2 FROM tab1 AS cor0
----
-14
-27
-30

query I rowsort
SELECT DISTINCT + 31 * col0 * col2 AS col2 FROM tab2 AS cor0
----
5859
62868
93062

query I rowsort
SELECT DISTINCT + col1 * - 31 + + col2 AS col0 FROM tab2 AS cor0
----
-1803
-489
-934

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1068
SELECT col2 * 58 DIV col0 + + 62 + - ( col1 ) * - col1 AS col0 FROM tab2 AS cor0
----
1246
3562
378

skipif mysql # not compatible
query I rowsort label-1068
SELECT col2 * 58 / col0 + + 62 + - ( col1 ) * - col1 AS col0 FROM tab2 AS cor0
----
1246
3562
378

query I rowsort
SELECT - 44 * col1 AS col1 FROM tab1 AS cor0
----
-1144
-440
-572

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

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

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

query I rowsort
SELECT col1 * 69 * + tab2.col0 AS col2 FROM tab2
----
14973
317538
92667

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

query I rowsort
SELECT + col1 * + 54 FROM tab2
----
1674
3186
918

query I rowsort
SELECT DISTINCT + 12 * - col1 AS col0 FROM tab0
----
-1032
-1092
-1164

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

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

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

query I rowsort
SELECT - - 70 * - col0 FROM tab1 AS cor0
----
-210
-4480
-5600

query I rowsort
SELECT ALL 96 * col0 AS col0 FROM tab1 AS cor0
----
288
6144
7680

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1084
SELECT - col1 + col2 * ( - col1 ) DIV + col0 AS col0 FROM tab2
----
-150
-25
-78

skipif mysql # not compatible
query I rowsort label-1084
SELECT - col1 + col2 * ( - col1 ) / + col0 AS col0 FROM tab2
----
-150
-25
-78

query I rowsort
SELECT - - ( cor0.col2 ) + + col2 * - col1 + + col1 AS col0 FROM tab1 AS cor0
----
-1139
-1324
-503

query I rowsort
SELECT - 75 * + col1 + col1 FROM tab1 AS cor0
----
-1924
-740
-962

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1088
SELECT - tab1.col0 DIV 63 AS col0 FROM tab1
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-1088
SELECT - tab1.col0 / 63 AS col0 FROM tab1
----
-1
-1
0

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1092
SELECT ALL + - col2 * + cor0.col0 + + cor0.col2 DIV col2 FROM tab0 cor0
----
-34
-7297
-791

skipif mysql # not compatible
query I rowsort label-1092
SELECT ALL + - col2 * + cor0.col0 + + cor0.col2 / col2 FROM tab0 cor0
----
-34
-7297
-791

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

query I rowsort
SELECT ALL + col1 + + 16 * col0 * cor0.col2 AS col0 FROM tab1 cor0
----
122893
2618
58378

query I rowsort
SELECT - col1 * 22 FROM tab0 AS cor0
----
-1892
-2002
-2134

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

query I rowsort
SELECT DISTINCT ( + col0 ) * col1 * col1 + + col1 FROM tab2 AS cor0
----
22848
271577
6758

skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( 96 AS REAL ) - + col1 FROM tab1 AS cor0
----
70
83
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col2 * col1 col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT + + 2 FROM tab2 AS cor0
----
2

query I rowsort
SELECT DISTINCT col0 * + 39 AS col0 FROM tab2
----
273
3042
3081

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to 0be13143d898cc667fe1a2dd93b34703

query I rowsort
SELECT - col1 - - 69 * + col1 AS col2 FROM tab0
----
5848
6188
6596

query I rowsort
SELECT DISTINCT + cor1.col1 AS col0 FROM tab2 cor0 CROSS JOIN tab2, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT ALL - 49 * + col2 - - col1 AS col2 FROM tab2 AS cor0
----
-1215
-1292
-1845

onlyif mysql # use DIV operator for integer division
query I rowsort label-1106
SELECT ALL col1 - col0 DIV - 67 FROM tab1 AS cor0
----
10
14
26

skipif mysql # not compatible
query I rowsort label-1106
SELECT ALL col1 - col0 / - 67 FROM tab1 AS cor0
----
10
14
26

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

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

skipif mysql # not compatible
query I rowsort label-1108
SELECT ( - col0 ) * CAST ( - col2 AS INTEGER ) + + col0 * col1 FROM tab0 cor0
----
15397
2856
3430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 + 93 * - col2 col1 FROM tab0 AS cor0
----
-10465
-15907
-9502

query I rowsort
SELECT DISTINCT - col1 * + col2 + col0 * 7 + + col1 AS col0 FROM tab0 AS cor0
----
-2584
-6748
245

query I rowsort
SELECT ALL - 91 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 6ec4feac5c635ab8e5da71006896acab

query I rowsort
SELECT - 57 + col1 * + col1 FROM tab2 AS cor0
----
232
3424
904

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + col2 col0 FROM tab0 AS cor0
----
164
2
66

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

query I rowsort
SELECT + 97 * - 5 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 461dbcb9c77b4fc3708e13f9fe612822

query I rowsort
SELECT - col1 * + tab1.col2 + + 23 * - tab1.col1 FROM tab1
----
-1547
-2002
-800

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

skipif mysql # not compatible
query I rowsort label-1119
SELECT col0 + + col1 / + ( ( col2 ) ) AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + 48 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
48

query I rowsort
SELECT tab2.col0 + col2 * - col2 * tab2.col2 FROM tab2
----
-17498
-19676
-54793

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

query I rowsort
SELECT col1 + 52 FROM tab2
----
111
69
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1124
SELECT + col1 DIV - col1 + + 14 col0 FROM tab1
----
13
13
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1124
SELECT + col1 / - col1 + + 14 col0 FROM tab1
----
13
13
13

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

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

query I rowsort
SELECT col1 * - 5 FROM tab2 AS cor0
----
-155
-295
-85

query I rowsort
SELECT - col1 + + 28 * + col1 FROM tab2 AS cor0
----
1593
459
837

query I rowsort
SELECT ALL col2 + + 70 * + col0 AS col2 FROM tab1 AS cor0
----
264
4537
5696

query I rowsort
SELECT - col0 * + 99 AS col1 FROM tab2 AS cor0
----
-693
-7722
-7821

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

query I rowsort
SELECT ALL col2 + + col0 * - col0 + ( tab1.col0 ) AS col1 FROM tab1
----
-3975
-6224
48

query I rowsort
SELECT + 13 * - col2 FROM tab1
----
-1248
-702
-741

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 + - col2 col0 FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT DISTINCT col2 + col2 * - col1 + - 81 * - col2 FROM tab2
----
1377
2470
598

query I rowsort
SELECT - + cor0.col2 + col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT ALL 76 * col0 AS col1 FROM tab0 AS cor0
----
1824
2660
6764

query I rowsort
SELECT ALL 61 * + 9 FROM tab0 cor0
----
549
549
549

query I rowsort
SELECT + - 34 * col0 * + 59 FROM tab2 AS cor0
----
-14042
-156468
-158474

query I rowsort
SELECT col2 * col1 + - 40 + cor0.col2 FROM tab0 AS cor0
----
2831
58
7504

query I rowsort
SELECT DISTINCT 5 * col2 AS col2 FROM tab1 cor0
----
270
285
480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col1 ) * col1 * col0 col1 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1142
SELECT ( + col1 ) * - CAST( - 75 AS SIGNED ) + + col0 + ( ( cor0.col1 ) ) FROM tab1 cor0
----
1068
1979
824

skipif mysql # not compatible
query I rowsort label-1142
SELECT ( + col1 ) * - CAST ( - 75 AS INTEGER ) + + col0 + ( ( cor0.col1 ) ) FROM tab1 cor0
----
1068
1979
824

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

query I rowsort
SELECT DISTINCT ( col1 ) + - 72 FROM tab2 cor0
----
-13
-41
-55

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

query I rowsort
SELECT ALL 46 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
1104
1610
4094

query I rowsort
SELECT + 57 - - 32 FROM tab0
----
89
89
89

query I rowsort
SELECT DISTINCT - - col1 * col2 + col1 * + ( - col1 ) AS col2 FROM tab0 AS cor0
----
-4558
-819
-9312

query I rowsort
SELECT 99 * col0 * + col1 FROM tab2 cor0
----
132957
21483
455598

query I rowsort
SELECT DISTINCT - col2 * + col0 + col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT + 21 + - col0 FROM tab1 AS cor0
----
-43
-59
18

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

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

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

query I rowsort
SELECT - 52 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 9500afe5646d620d5e8943351a29d082

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col2 + col2 col0 FROM tab1
----
108
114
192

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

query I rowsort
SELECT + ( 70 ) FROM tab2
----
70
70
70

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

skipif mysql # not compatible
query I rowsort label-1158
SELECT + - 37 / col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 78 AS col2 FROM tab0
----
-78
-78
-78

query I rowsort
SELECT ALL - 58 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1161
SELECT - CAST( cor0.col2 AS SIGNED ) FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-1161
SELECT - CAST ( cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT 73 * col0 + CAST ( col1 AS REAL ) AS col1 FROM tab0
----
1838
2652
6588

query I rowsort
SELECT + - cor0.col0 * + 11 FROM tab1 AS cor0
----
-33
-704
-880

query I rowsort
SELECT ALL - col1 + + col1 * + 16 AS col1 FROM tab2
----
255
465
885

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1166
SELECT + col0 + col2 DIV 26 + 27 FROM tab2
----
106
107
35

skipif mysql # not compatible
query I rowsort label-1166
SELECT + col0 + col2 / 26 + 27 FROM tab2
----
106
107
35

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

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

query I rowsort
SELECT ALL - col0 * - 36 AS col1 FROM tab2 AS cor0
----
252
2808
2844

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

query I rowsort
SELECT ALL + col0 * - 5 AS col2 FROM tab0 AS cor0
----
-120
-175
-445

query I rowsort
SELECT ALL - - 41 FROM tab0, tab0 cor0, tab1, tab2 AS cor1
----
81 values hashing to 0733f496a5445ffeac9d19797afe4831

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

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

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

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

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

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

query I rowsort
SELECT ALL - tab1.col0 * - ( + 66 ) FROM tab1
----
198
4224
5280

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1180
SELECT col0 DIV - 17 FROM tab1
----
-3
-4
0

skipif mysql # not compatible
query I rowsort label-1180
SELECT col0 / - 17 FROM tab1
----
-3
-4
0

query I rowsort
SELECT DISTINCT 64 * 7 AS col1 FROM tab2 AS cor0
----
448

query I rowsort
SELECT ALL - col1 + + 7 + + col1 FROM tab2 cor0
----
7
7
7

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

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

query I rowsort
SELECT 79 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

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

query I rowsort
SELECT ALL + col0 * + ( - 93 ) AS col0 FROM tab1
----
-279
-5952
-7440

query I rowsort
SELECT + col0 + cor0.col2 + - col1 FROM tab1 AS cor0
----
111
163
31

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

query I rowsort
SELECT + + col2 + - col2 FROM tab2 cor0
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-1190
SELECT - col2 / 55 - col1 AS col0 FROM tab2 AS cor0
----
-17
-31
-59

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

query I rowsort
SELECT - - col2 * 19 + - col2 AS col1 FROM tab2 AS cor0
----
468
486
684

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col0 col1 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL ( cor0.col1 ) FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT + 69 + + col1 FROM tab2 cor0
----
100
128
86

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1201
SELECT + col1 DIV - ( cor0.col1 ) + - col2 * - 71 FROM tab1 AS cor0
----
3833
4046
6815

skipif mysql # not compatible
query I rowsort label-1201
SELECT + col1 / - ( cor0.col1 ) + - col2 * - 71 FROM tab1 AS cor0
----
3833
4046
6815

query I rowsort
SELECT ALL 3 + col1 AS col0 FROM tab1
----
13
16
29

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

query I rowsort
SELECT - ( 10 * + col1 ) + + 97 AS col1 FROM tab1
----
-163
-3
-33

query I rowsort
SELECT DISTINCT + col2 * - 83 + tab2.col2 FROM tab2
----
-2132
-2214
-3116

query I rowsort
SELECT DISTINCT - 27 * col0 + + cor0.col0 + - 83 AS col1 FROM tab0 AS cor0
----
-2397
-707
-993

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

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

query I rowsort
SELECT ALL cor0.col0 + col0 * 68 * col0 AS col2 FROM tab0 cor0
----
39192
538717
83335

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col0 * col1 col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT 29 * col1 FROM tab0 AS cor0
----
2494
2639
2813

query I rowsort
SELECT ( + col1 ) * - col2 * - col1 AS col0 FROM tab2 AS cor0
----
10982
25947
90506

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

query I rowsort
SELECT - + ( cor0.col0 ) * ( + 25 ) AS col2 FROM tab0 AS cor0
----
-2225
-600
-875

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT col2 * + col2 + col0 AS col1 FROM tab2
----
1523
736
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + ( - col2 ) + col2 * 15 col0 FROM tab1 AS cor0
----
1357
782
808

query I rowsort
SELECT + col1 * 52 FROM tab2 AS cor0
----
1612
3068
884

query I rowsort
SELECT 53 FROM tab2, tab2 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

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

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

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

query I rowsort
SELECT DISTINCT + col2 + - ( + 48 ) * - col1 AS col2 FROM tab1 AS cor0
----
1302
537
720

query I rowsort
SELECT col1 * col2 - - ( - col0 * + 56 ) FROM tab1 AS cor0
----
-3014
-3232
1236

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

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

query I rowsort
SELECT - col1 * + 86 * + col2 + col2 AS col1 FROM tab1 AS cor0
----
-107232
-120690
-48963

onlyif mysql # use DIV operator for integer division
query I rowsort label-1232
SELECT DISTINCT + col1 DIV 22 + 70 FROM tab1 AS cor0
----
70
71

skipif mysql # not compatible
query I rowsort label-1232
SELECT DISTINCT + col1 / 22 + 70 FROM tab1 AS cor0
----
70
71

query I rowsort
SELECT ALL + - col2 + + 10 * + col2 FROM tab2 AS cor0
----
234
243
342

query I rowsort
SELECT col1 - 86 * - col0 AS col2 FROM tab1 AS cor0
----
284
5514
6893

query I rowsort
SELECT ALL col1 * cor0.col1 + - col2 * col0 + ( - 82 + col1 ) FROM tab2 AS cor0
----
-2778
1430
721

query I rowsort
SELECT ALL 1 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 2a004dce2d308bae163576f54ee1a3fc

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

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

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

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

query I rowsort
SELECT - + col1 + - col0 + col0 AS col1 FROM tab2 cor0
----
-17
-31
-59

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

skipif mysql # not compatible
query I rowsort label-1240
SELECT DISTINCT CAST ( col2 AS INTEGER ) + col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT ALL - 4 * + col2 AS col1 FROM tab2 AS cor0
----
-104
-108
-152

query I rowsort
SELECT + col2 + ( - cor0.col2 * 36 ) FROM tab2 cor0
----
-1330
-910
-945

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

skipif mysql # not compatible
query I rowsort label-1243
SELECT - col2 / col0 + cor0.col0 AS col1 FROM tab2 AS cor0
----
4
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1244
SELECT col0 + 46 DIV + col1 + + 43 * - col0 AS col2 FROM tab0 AS cor0
----
-1008
-1470
-3738

skipif mysql # not compatible
query I rowsort label-1244
SELECT col0 + 46 / + col1 + + 43 * - col0 AS col2 FROM tab0 AS cor0
----
-1008
-1470
-3738

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

query I rowsort
SELECT ALL tab1.col2 + + 63 FROM tab1
----
117
120
159

query I rowsort
SELECT DISTINCT - 18 + + col2 + + col2 FROM tab1 cor0
----
174
90
96

query I rowsort
SELECT + - 19 + - col0 FROM tab0 AS cor0
----
-108
-43
-54

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

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

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

query I rowsort
SELECT - col1 + + 30 FROM tab2 AS cor0
----
-1
-29
13

query I rowsort
SELECT ALL + + 89 + + col0 FROM tab2 AS cor0
----
167
168
96

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

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

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

query I rowsort
SELECT ALL - - 13 * 95 + cor0.col2 + + cor0.col0 * - 75 * + col1 FROM tab2 AS cor0
----
-15013
-343889
-99452

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

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

query I rowsort
SELECT - col2 + 90 FROM tab1 AS cor0
----
-6
33
36

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

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

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

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

query I rowsort
SELECT ALL 23 FROM tab2, tab0 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

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

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

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

query I rowsort
SELECT ALL + - col0 + 38 + col2 AS col1 FROM tab1 cor0
----
31
54
89

query I rowsort
SELECT ALL 19 * col1 AS col1 FROM tab2
----
1121
323
589

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

skipif mysql # not compatible
query I rowsort label-1267
SELECT DISTINCT + CAST ( - 31 AS INTEGER ) AS col1 FROM tab1, tab2 AS cor0, tab2 cor1
----
-31

query I rowsort
SELECT - col0 + col2 * + 23 FROM tab1
----
1239
1247
2128

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

skipif mysql # not compatible
query I rowsort label-1269
SELECT - col2 / ( + 1 ) FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + col2 + - 36 * tab1.col0 FROM tab1
----
-2247
-2784
-54

query I rowsort
SELECT - col1 + - col1 + 6 FROM tab0
----
-166
-176
-188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 93 * + col0 col2 FROM tab1 AS cor0
----
282
6016
7520

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1274
SELECT - col0 DIV col0 + 22 FROM tab0 AS cor0
----
21
21
21

skipif mysql # not compatible
query I rowsort label-1274
SELECT - col0 / col0 + 22 FROM tab0 AS cor0
----
21
21
21

query I rowsort
SELECT ( col1 ) * + 41 - - col2 AS col0 FROM tab1 AS cor0
----
1120
467
629

query I rowsort
SELECT + + 85 * col2 + col2 * + col0 FROM tab0 AS cor0
----
120
14268
3597

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

query I rowsort
SELECT - col0 + - col2 * col1 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL + 65 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + ( col2 + + col1 ) col1 FROM tab2 AS cor0
----
144
72
89

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1285
SELECT ALL CAST( + col0 AS SIGNED ) + - col2 + cor0.col1 AS col0 FROM tab1 AS cor0
----
-25
-3
17

skipif mysql # not compatible
query I rowsort label-1285
SELECT ALL CAST ( + col0 AS INTEGER ) + - col2 + cor0.col1 AS col0 FROM tab1 AS cor0
----
-25
-3
17

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

query I rowsort
SELECT - col1 * - col2 * col1 AS col1 FROM tab0 AS cor0
----
244068
679042
9409

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

query I rowsort
SELECT - col1 * + cor0.col1 + + col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT + 64 FROM tab0, tab1 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

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

query I rowsort
SELECT 76 * col2 + col2 FROM tab2 AS cor0
----
2002
2079
2926

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 55 + col1 col2 FROM tab1
----
-29
-42
-45

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

query I rowsort
SELECT DISTINCT cor0.col2 * - col1 + 90 FROM tab1 AS cor0
----
-1158
-1314
-480

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0, tab1 AS cor1, tab2 cor2
----
972 values hashing to 72eb3d4d523f5d0c69d1b855edd18f4a

query I rowsort
SELECT ALL 8 * col0 + + 95 FROM tab2 AS cor0
----
151
719
727

query I rowsort
SELECT DISTINCT col0 * + col0 + - cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
37
4143
6483

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

query I rowsort
SELECT col1 * - col2 - + ( col2 ) * col2 * col0 FROM tab1
----
-10152
-208506
-738528

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

query I rowsort
SELECT col1 * 64 FROM tab2
----
1088
1984
3776

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1307
SELECT - 22 + - col0 DIV - col0 col2 FROM tab0 AS cor0
----
-21
-21
-21

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1307
SELECT - 22 + - col0 / - col0 col2 FROM tab0 AS cor0
----
-21
-21
-21

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

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

query I rowsort
SELECT ALL - col2 + col2 + 3 FROM tab2
----
3
3
3

query I rowsort
SELECT DISTINCT - col2 * + 87 FROM tab1
----
-4698
-4959
-8352

onlyif mysql # use DIV operator for integer division
query I rowsort label-1312
SELECT DISTINCT + + tab0.col0 + 2 DIV - cor0.col1 AS col0 FROM tab0, tab1, tab1 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1312
SELECT DISTINCT + + tab0.col0 + 2 / - cor0.col1 AS col0 FROM tab0, tab1, tab1 AS cor0
----
24
35
89

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

query I rowsort
SELECT - 76 * ( col0 ) AS col0 FROM tab0 AS cor0
----
-1824
-2660
-6764

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1319
SELECT col2 + 54 / + col2 FROM tab1 AS cor0
----
55
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1320
SELECT col2 + CAST( - col1 AS SIGNED ) DIV - cor0.col1 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1320
SELECT col2 + CAST ( - col1 AS INTEGER ) / - cor0.col1 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT DISTINCT + cor0.col0 + - 84 AS col0 FROM tab0 AS cor0
----
-49
-60
5

query I rowsort
SELECT - - col1 * ( - col2 ) + col2 * - col1 * + col1 FROM tab2 AS cor0
----
-11628
-26784
-92040

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

query I rowsort
SELECT ALL + col2 * 69 * col0 AS col1 FROM tab2 AS cor0
----
13041
139932
207138

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

query I rowsort
SELECT DISTINCT 69 * col0 + col2 AS col0 FROM tab1
----
261
4473
5616

query I rowsort
SELECT ALL 84 + + col2 FROM tab0
----
117
166
85

query I rowsort
SELECT - col0 + 31 * - ( + col0 ) AS col1 FROM tab1 AS cor0
----
-2048
-2560
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1329
SELECT DISTINCT col1 + - CAST( 81 AS SIGNED ) FROM tab2
----
-22
-50
-64

skipif mysql # not compatible
query I rowsort label-1329
SELECT DISTINCT col1 + - CAST ( 81 AS INTEGER ) FROM tab2
----
-22
-50
-64

query I rowsort
SELECT - cor0.col1 * 3 + col0 FROM tab0 AS cor0
----
-184
-234
-256

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

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

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

query I rowsort
SELECT DISTINCT + + cor0.col1 * col1 AS col2 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - col1 * + col1 * col2 - + col0 AS col2 FROM tab2 AS cor0
----
-11061
-25954
-90584

query I rowsort
SELECT + col2 + - 52 AS col2 FROM tab1 AS cor0
----
2
44
5

query I rowsort
SELECT - col2 * col0 * 3 FROM tab0 AS cor0
----
-105
-21894
-2376

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1338
SELECT DISTINCT - 52 DIV col0 - - col1 FROM tab2
----
17
24
59

skipif mysql # not compatible
query I rowsort label-1338
SELECT DISTINCT - 52 / col0 - - col1 FROM tab2
----
17
24
59

query I rowsort
SELECT + + 80 * col1 AS col0 FROM tab1 AS cor0
----
1040
2080
800

query I rowsort
SELECT - 22 + - 76 FROM tab2 AS cor0
----
-98
-98
-98

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

query I rowsort
SELECT + + 78 * col1 AS col2 FROM tab2 AS cor0
----
1326
2418
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-1343
SELECT DISTINCT + 50 DIV tab1.col0 AS col1 FROM tab1, tab2, tab2 AS cor0
----
0
16

skipif mysql # not compatible
query I rowsort label-1343
SELECT DISTINCT + 50 / tab1.col0 AS col1 FROM tab1, tab2, tab2 AS cor0
----
0
16

query I rowsort
SELECT ( - col0 ) * - col0 + - col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-513
1197
1224

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

query I rowsort
SELECT 78 * cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 7de15befa4eeabd40210b3c7fdc18770

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

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

skipif mysql # not compatible
query I rowsort label-1348
SELECT + 20 / + col1 + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT + - col0 * + col2 + 83 * col1 FROM tab1 AS cor0
----
-2818
-6601
1996

query I rowsort
SELECT ALL - 99 * col0 AS col2 FROM tab1 AS cor0
----
-297
-6336
-7920

query I rowsort
SELECT - 18 + cor0.col0 AS col1 FROM tab1 AS cor0
----
-15
46
62

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1355
SELECT ALL - col0 DIV col2 + - ( + 20 + cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-110
-44
-90

skipif mysql # not compatible
query I rowsort label-1355
SELECT ALL - col0 / col2 + - ( + 20 + cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-110
-44
-90

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

query I rowsort
SELECT ALL - col2 * + col2 + + col2 AS col1 FROM tab1
----
-2862
-3192
-9120

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

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

query I rowsort
SELECT DISTINCT col1 * + col0 + + 99 FROM tab0 AS cor0
----
2163
3494
8198

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( + col0 ) * col1 + col2 * cor0.col2 col1 FROM tab2 AS cor0
----
-3926
101
512

query I rowsort
SELECT DISTINCT + + col0 + col0 * - col0 * ( col2 ) FROM tab2 AS cor0
----
-1316
-158106
-237079

query I rowsort
SELECT ALL + - 37 * col1 + col1 FROM tab0 AS cor0
----
-3096
-3276
-3492

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

query I rowsort
SELECT + col1 + + col1 + 67 AS col1 FROM tab0 AS cor0
----
239
249
261

query I rowsort
SELECT + col2 + 31 + - 43 FROM tab2 cor0
----
14
15
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1368
SELECT ALL cor0.col1 + 29 DIV - col1 col1 FROM tab1 AS cor0
----
11
25
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1368
SELECT ALL cor0.col1 + 29 / - col1 col1 FROM tab1 AS cor0
----
11
25
8

query I rowsort
SELECT col0 + + col0 + col1 AS col0 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT - 77 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + ( + 75 + col2 ) * col2 col1 FROM tab2 AS cor0
----
2600
2727
4256

query I rowsort
SELECT DISTINCT col2 * col2 + + 8 AS col0 FROM tab0
----
1097
6732
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 + col1 - col0 col0 FROM tab2
----
-24
51
7

query I rowsort
SELECT ALL - 71 - + 10 FROM tab0 AS cor0
----
-81
-81
-81

query I rowsort
SELECT ALL - 21 FROM tab0, tab2 AS cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

query I rowsort
SELECT - - col2 * + 97 AS col2 FROM tab0 AS cor0
----
3201
7954
97

query I rowsort
SELECT DISTINCT + ( col0 ) + cor0.col2 + 6 * - col2 AS col0 FROM tab0 AS cor0
----
-141
-321
30

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

query I rowsort
SELECT DISTINCT + ( col0 ) * col2 + + ( col2 ) FROM tab0 AS cor0
----
36
7380
825

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

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

query I rowsort
SELECT DISTINCT 93 * 64 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
5952

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

query I rowsort
SELECT - - tab1.col1 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + + col2 + col1 * - ( + 13 ) FROM tab1 AS cor0
----
-284
-73
-73

query I rowsort
SELECT ( - 7 ) FROM tab1, tab2, tab0 cor0
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + 5 * + col1 ) col1 FROM tab2
----
155
295
85

query I rowsort
SELECT - 41 + - 16 * + col0 AS col0 FROM tab2
----
-1289
-1305
-153

query I rowsort
SELECT 94 * - col1 + + col0 FROM tab0
----
-8060
-8465
-9083

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

query I rowsort
SELECT 43 + col2 * col2 AS col2 FROM tab1
----
2959
3292
9259

query I rowsort
SELECT ALL + - col2 + col2 - + col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - 33 AS col2 FROM tab0
----
-33
-33
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col1 * tab1.col1 ) col0 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - ( cor0.col0 ) AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col1 col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL + col0 * + col1 * col0 AS col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT col1 * - cor0.col2 + col2 * + 76 FROM tab2 AS cor0
----
1215
2242
442

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

query I rowsort
SELECT DISTINCT + col1 + 42 FROM tab1 cor0
----
52
55
68

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1402
SELECT ALL + col0 * CAST( + col0 AS SIGNED ) * + col0 FROM tab0
----
13824
42875
704969

skipif mysql # not compatible
query I rowsort label-1402
SELECT ALL + col0 * CAST ( + col0 AS INTEGER ) * + col0 FROM tab0
----
13824
42875
704969

query I rowsort
SELECT ALL - 63 AS col2 FROM tab1
----
-63
-63
-63

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

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

query I rowsort
SELECT DISTINCT + 59 * tab2.col1 AS col2 FROM tab2
----
1003
1829
3481

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

query I rowsort
SELECT + 57 + - cor0.col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 4e216cb0d47d5b7dd80f16307e0e7ee7

query I rowsort
SELECT ALL 52 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

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

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

query I rowsort
SELECT ALL - col1 * + col2 + + col2 * col1 * col1 FROM tab1 AS cor0
----
14976
35100
5130

query I rowsort
SELECT + col1 * - 32 + cor0.col2 FROM tab2 AS cor0
----
-1862
-506
-965

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1417
SELECT cor0.col2 + - CAST ( col2 AS INTEGER ) * col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT cor0.col2 + + 50 AS col1 FROM tab0 AS cor0
----
132
51
83

query I rowsort
SELECT ALL col0 * + col0 * - 44 AS col0 FROM tab2
----
-2156
-267696
-274604

query I rowsort
SELECT + + col2 + - 78 FROM tab1 AS cor0
----
-21
-24
18

query I rowsort
SELECT DISTINCT + 99 * col2 AS col1 FROM tab1 AS cor0
----
5346
5643
9504

query I rowsort
SELECT ALL + cor0.col2 * 61 AS col0 FROM tab0 AS cor0
----
2013
5002
61

query I rowsort
SELECT + + 49 * ( col2 ) AS col0 FROM tab2 AS cor0
----
1274
1323
1862

query I rowsort
SELECT DISTINCT - 99 * - col2 FROM tab1 cor0
----
5346
5643
9504

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

query I rowsort
SELECT ALL ( + 2 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

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

query I rowsort
SELECT ALL cor0.col2 * + 20 AS col1 FROM tab2 AS cor0
----
520
540
760

query I rowsort
SELECT ALL cor0.col2 * tab2.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 9f4d33c2594156f40c1a77ce18b06bc3

query I rowsort
SELECT DISTINCT 74 FROM tab2, tab2 AS cor0
----
74

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

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

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

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

query I rowsort
SELECT + + cor0.col2 * + col1 + col1 * 63 AS col2 FROM tab0 AS cor0
----
13195
6208
8256

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

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

query I rowsort
SELECT DISTINCT 70 + col2 FROM tab0 AS cor0
----
103
152
71

query I rowsort
SELECT + col0 * 62 AS col2 FROM tab0
----
1488
2170
5518

query I rowsort
SELECT ALL 30 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

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

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

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

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

query I rowsort
SELECT + - 39 * cor0.col1 FROM tab1 AS cor0
----
-1014
-390
-507

query I rowsort
SELECT + 97 + col1 * col2 FROM tab0 AS cor0
----
194
2935
7559

query I rowsort
SELECT ALL 64 + - col1 * col1 AS col2 FROM tab2 AS cor0
----
-225
-3417
-897

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

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

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

query I rowsort
SELECT ALL - - 98 * col0 FROM tab0 AS cor0
----
2352
3430
8722

query I rowsort
SELECT ALL + col0 + + col0 * ( col0 ) FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL + 72 * - col1 FROM tab2 cor0
----
-1224
-2232
-4248

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

query I rowsort
SELECT - - 21 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-1869
-504
-735

onlyif mysql # use DIV operator for integer division
query I rowsort label-1454
SELECT - col0 DIV - 56 + 62 + col1 DIV - col1 FROM tab2 cor0
----
61
62
62

skipif mysql # not compatible
query I rowsort label-1454
SELECT - col0 / - 56 + 62 + col1 / - col1 FROM tab2 cor0
----
61
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1455
SELECT ALL - col2 - col2 DIV ( - ( col2 ) + - col2 ) FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-1455
SELECT ALL - col2 - col2 / ( - ( col2 ) + - col2 ) FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT 47 + - col1 + - col2 FROM tab0
----
-126
-51
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-1457
SELECT + + col1 DIV 14 + - 81 * cor0.col1 FROM tab1 AS cor0
----
-1053
-2105
-810

skipif mysql # not compatible
query I rowsort label-1457
SELECT + + col1 / 14 + - 81 * cor0.col1 FROM tab1 AS cor0
----
-1053
-2105
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-1458
SELECT + - cor0.col0 DIV ( + col2 ) - cor0.col2 FROM tab1 AS cor0
----
-54
-58
-96

skipif mysql # not compatible
query I rowsort label-1458
SELECT + - cor0.col0 / ( + col2 ) - cor0.col2 FROM tab1 AS cor0
----
-54
-58
-96

query I rowsort
SELECT col2 + col2 - - col1 FROM tab1
----
124
134
205

query I rowsort
SELECT + col1 + + col1 * 70 FROM tab1
----
1846
710
923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 13 * + col0 + - col2 col0 FROM tab0
----
1075
279
454

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

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

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

query I rowsort
SELECT ALL + 4 + 13 + + col2 * - 96 FROM tab2 AS cor0
----
-2479
-2575
-3631

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1466
SELECT CAST( 80 AS SIGNED ) * col1 col0 FROM tab2 AS cor0
----
1360
2480
4720

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1466
SELECT CAST ( 80 AS INTEGER ) * col1 col0 FROM tab2 AS cor0
----
1360
2480
4720

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

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

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

query I rowsort
SELECT DISTINCT - 16 AS col1 FROM tab2 AS cor0
----
-16

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - 71 col2 FROM tab2 AS cor0
----
-149
-150
-78

query I rowsort
SELECT ALL + 85 * + col0 + col2 FROM tab1 AS cor0
----
309
5497
6896

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1479
SELECT - 57 / col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL 75 + - 29 AS col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + 65 col1 FROM tab1
----
195
4160
5200

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 36 * cor0.col2 col0 FROM tab1 AS cor0
----
1944
2052
3456

query I rowsort
SELECT DISTINCT - 37 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
17
20
59

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

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

query I rowsort
SELECT ALL + 40 - + col1 AS col2 FROM tab0 AS cor0
----
-46
-51
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * col2 + + col2 * ( + col0 ) * + col2 col0 FROM tab1 AS cor0
----
211584
744960
8910

query I rowsort
SELECT col0 * col2 + - 95 * + col2 + ( - ( + col0 ) ) AS col2 FROM tab1 AS cor0
----
-1520
-1831
-4971

query I rowsort
SELECT ALL - - col1 * + 64 FROM tab0 AS cor0
----
5504
5824
6208

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

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

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

query I rowsort
SELECT ALL + col2 + + 74 * col0 FROM tab0 AS cor0
----
1809
2591
6668

query I rowsort
SELECT DISTINCT - col0 * - ( col0 ) + col1 * col1 FROM tab0 AS cor0
----
10634
16202
7972

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

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

query I rowsort
SELECT ALL - col0 + 99 * col1 FROM tab2 AS cor0
----
1604
3062
5763

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + + 43 col0 FROM tab1 AS cor0
----
107
123
46

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

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0, tab0 AS cor2, tab1
----
13122 values hashing to 94657c8c1d9dda82be248377944370da

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

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

query I rowsort
SELECT + cor0.col2 * 80 FROM tab2 AS cor0
----
2080
2160
3040

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

query I rowsort
SELECT ALL - ( cor0.col1 ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT tab2.col0 FROM tab2 WHERE NULL NOT BETWEEN ( col0 ) AND col1 + - col2
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col2 / + tab1.col1 + tab1.col0 * col0 * col1 < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 + col1 * + col1 * + col2 col1 FROM tab0
----
243982
678951
9312

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1516
SELECT ALL col2 DIV col0 + - col1 * + col0 AS col0 FROM tab2
----
-1343
-214
-4602

skipif mysql # not compatible
query I rowsort label-1516
SELECT ALL col2 / col0 + - col1 * + col0 AS col0 FROM tab2
----
-1343
-214
-4602

query I rowsort
SELECT + 66 * + col1 * + 63 + + col2 * col1 AS col2 FROM tab2 AS cor0
----
129735
246856
71332

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1519
SELECT DISTINCT col0 DIV tab2.col1 + - col0 AS col1 FROM tab2
----
-7
-75
-77

skipif mysql # not compatible
query I rowsort label-1519
SELECT DISTINCT col0 / tab2.col1 + - col0 AS col1 FROM tab2
----
-7
-75
-77

query III rowsort
SELECT * FROM tab1 WHERE NOT ( - col2 ) <> + col0 - + col0 / col1
----

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

query I rowsort
SELECT ALL col2 + - cor0.col2 * 82 AS col0 FROM tab1 AS cor0
----
-4374
-4617
-7776

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

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

query I rowsort
SELECT - - 52 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 7f4ae30893ab330784829711032ae599

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

query I rowsort
SELECT 76 * col0 * + ( - ( - cor0.col0 ) + + col0 ) FROM tab0 AS cor0
----
1203992
186200
87552

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL - - col2 + + 32 FROM tab0 cor0
----
114
33
65

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

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

query I rowsort
SELECT DISTINCT col0 + ( + cor0.col1 * col2 ) - + ( 90 ) AS col1 FROM tab1 AS cor0
----
1238
1317
544

query I rowsort
SELECT + col0 + 42 * 49 + - col2 AS col1 FROM tab1 AS cor0
----
2007
2042
2065

query I rowsort
SELECT DISTINCT + tab0.col2 - - 33 FROM tab0
----
115
34
66

query I rowsort
SELECT + 40 * 71 FROM tab0 AS cor0
----
2840
2840
2840

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

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

query I rowsort
SELECT ALL + + col1 + col1 * col1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-1537
SELECT DISTINCT + + col0 + col1 DIV 12 FROM tab0 AS cor0
----
31
43
96

skipif mysql # not compatible
query I rowsort label-1537
SELECT DISTINCT + + col0 + col1 / 12 FROM tab0 AS cor0
----
31
43
96

query I rowsort
SELECT - - 93 * + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-191952
-315735
-753207

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 82 + + col2 * col1 col1 FROM tab0 AS cor0
----
179
2920
7544

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1542
SELECT ALL ( - 5 ) DIV tab1.col1 col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1542
SELECT ALL ( - 5 ) / tab1.col1 col0 FROM tab1
----
0
0
0

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

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

skipif mysql # not compatible
query I rowsort label-1544
SELECT DISTINCT - ( - col2 ) / CAST ( - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT col1 * + 82 AS col2 FROM tab2
----
1394
2542
4838

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

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

query I rowsort
SELECT ALL col2 * 58 FROM tab0
----
1914
4756
58

query I rowsort
SELECT ALL + col1 * - 57 + + col2 AS col0 FROM tab2 AS cor0
----
-1740
-3337
-931

query I rowsort
SELECT col1 + + ( - 64 ) FROM tab2 AS cor0
----
-33
-47
-5

query I rowsort
SELECT ALL - ( - 72 ) * col2 * col1 FROM tab2 AS cor0
----
110448
46512
60264

onlyif mysql # use DIV operator for integer division
query I rowsort label-1552
SELECT 11 * - col2 * + col2 + - col1 DIV - col0 AS col0 FROM tab1 cor0
----
-101376
-32068
-35739

skipif mysql # not compatible
query I rowsort label-1552
SELECT 11 * - col2 * + col2 + - col1 / - col0 AS col0 FROM tab1 cor0
----
-101376
-32068
-35739

query I rowsort
SELECT DISTINCT + ( 71 ) * - col2 FROM tab0 AS cor0
----
-2343
-5822
-71

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

query I rowsort
SELECT ALL - 20 * cor0.col2 + col0 AS col2 FROM tab0 AS cor0
----
-1551
-636
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-1556
SELECT ALL - CAST( - col2 AS SIGNED ) DIV col0 - 12 AS col2 FROM tab0 AS cor0
----
-11
-12
-12

skipif mysql # not compatible
query I rowsort label-1556
SELECT ALL - CAST ( - col2 AS INTEGER ) / col0 - 12 AS col2 FROM tab0 AS cor0
----
-11
-12
-12

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

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

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

skipif mysql # not compatible
query I rowsort label-1558
SELECT ALL 86 / - col0 FROM tab1 AS cor0
----
-1
-1
-28

query I rowsort
SELECT 31 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT ALL col1 * - col0 * - 51 AS col0 FROM tab0
----
105264
173145
413049

query I rowsort
SELECT DISTINCT - + col0 + - 61 FROM tab1 AS cor0
----
-125
-141
-64

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

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

skipif mysql # not compatible
query I rowsort label-1563
SELECT - 7 / col2 FROM tab1 AS cor0
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-1564
SELECT DISTINCT 76 / col0 + 1 FROM tab0 AS cor0
----
1
3
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - cor0.col0 + col0 col2 FROM tab1 AS cor0
----
-4032
-6
-6320

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

query I rowsort
SELECT ALL - 64 * - cor0.col1 FROM tab2 AS cor0
----
1088
1984
3776

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

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

query I rowsort
SELECT ALL - ( col0 ) + - col1 * cor0.col2 FROM tab1 cor0
----
-1328
-1407
-634

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

query I rowsort
SELECT DISTINCT - ( 19 ) FROM tab2
----
-19

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1575
SELECT 17 * col1 + + col1 DIV ( - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
1003
289
523

skipif mysql # not compatible
query I rowsort label-1575
SELECT 17 * col1 + + col1 / ( - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
1003
289
523

query I rowsort
SELECT DISTINCT 23 + - col2 * + col1 FROM tab1 AS cor0
----
-1225
-1381
-547

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col1 + CAST ( + 19 AS REAL ) * col0 AS col0 FROM tab2 AS cor0
----
102
1423
1484

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

query I rowsort
SELECT - col1 * + 50 + + col2 FROM tab2 cor0
----
-1523
-2924
-812

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

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

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

query I rowsort
SELECT ALL cor0.col1 + 36 FROM tab1 AS cor0
----
46
49
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1584
SELECT ALL + 37 DIV - col1 + + ( - col2 + + col2 ) AS col0 FROM tab1
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-1584
SELECT ALL + 37 / - col1 + + ( - col2 + + col2 ) AS col0 FROM tab1
----
-1
-2
-3

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

skipif mysql # not compatible
query I rowsort label-1585
SELECT ALL - 79 / col1 + col1 AS col2 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1586
SELECT DISTINCT - col2 + col2 DIV - col2 AS col1 FROM tab0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-1586
SELECT DISTINCT - col2 + col2 / - col2 AS col1 FROM tab0
----
-2
-34
-83

query I rowsort
SELECT DISTINCT + 78 FROM tab0, tab2 cor0, tab2, tab0 AS cor1
----
78

query I rowsort
SELECT DISTINCT - col2 * + 85 + col1 FROM tab2 AS cor0
----
-2151
-2264
-3213

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1589
SELECT DISTINCT + - col0 - + CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1589
SELECT DISTINCT + - col0 - + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT + col1 + 33 AS col1 FROM tab1 AS cor0
----
43
46
59

query I rowsort
SELECT ALL - col2 - + col0 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + cor0.col2 * + col2 * col2 AS col2 FROM tab1 AS cor0
----
157464
185193
884736

onlyif mysql # use DIV operator for integer division
query I rowsort label-1593
SELECT ALL - col2 DIV 20 + tab0.col0 * - CAST( col2 AS SIGNED ) AS col1 FROM tab0
----
-35
-7302
-793

skipif mysql # not compatible
query I rowsort label-1593
SELECT ALL - col2 / 20 + tab0.col0 * - CAST ( col2 AS INTEGER ) AS col1 FROM tab0
----
-35
-7302
-793

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1594
SELECT ALL CAST( NULL AS DECIMAL ) * col0 + col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1594
SELECT ALL CAST ( NULL AS REAL ) * col0 + col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 76 * ( cor0.col2 ) + cor0.col1 FROM tab0 AS cor0
----
-2422
-6141
21

query I rowsort
SELECT + + 85 + + 45 * - col2 FROM tab2 AS cor0
----
-1085
-1130
-1625

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1597
SELECT ALL - CAST( - col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-1597
SELECT ALL - CAST ( - col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT col1 * 6 + col1 AS col2 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT DISTINCT 85 + col0 * col1 AS col0 FROM tab2 AS cor0
----
1428
302
4687

query I rowsort
SELECT ALL - + col1 * - col0 + cor0.col2 * cor0.col1 + col0 AS col1 FROM tab2 AS cor0
----
1061
2068
6214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col2 + - 67 col0 FROM tab0 AS cor0
----
-164
-2905
-7529

query I rowsort
SELECT ALL - - cor0.col2 + cor0.col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + cor0.col1 - - 58 FROM tab1, tab2 AS cor0
----
9 values hashing to c2d0909e210f7304bd2ecf45ce4cea34

query I rowsort
SELECT ALL - 95 * - col1 * - col2 FROM tab0
----
-269610
-708890
-9215

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 + + ( col2 ) col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL - - col2 * - col1 + + col0 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - cor0.col0 + cor0.col0 * col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT DISTINCT + col1 - cor0.col1 AS col1 FROM tab0 cor0
----
0

query I rowsort
SELECT + 62 * cor0.col0 + col2 AS col0 FROM tab0 AS cor0
----
1521
2171
5600

query I rowsort
SELECT DISTINCT 30 + col1 AS col1 FROM tab0 AS cor0
----
116
121
127

onlyif mysql # use DIV operator for integer division
query I rowsort label-1611
SELECT - cor0.col0 DIV col0 + col2 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-1611
SELECT - cor0.col0 / col0 + col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT + 55 + col0 + - col2 FROM tab2 AS cor0
----
107
35
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1613
SELECT + CAST( + 99 AS SIGNED ) + - col0 FROM tab2 AS cor0
----
20
21
92

skipif mysql # not compatible
query I rowsort label-1613
SELECT + CAST ( + 99 AS INTEGER ) + - col0 FROM tab2 AS cor0
----
20
21
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1614
SELECT + CAST( col2 AS SIGNED ) * + cor0.col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-1614
SELECT + CAST ( col2 AS INTEGER ) * + cor0.col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col2 * - col0 + - col0 AS col2 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT - col0 * 77 AS col0 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT 36 + - col0 * col1 * - col1 AS col0 FROM tab1 AS cor0
----
13556
2064
6436

onlyif mysql # use DIV operator for integer division
query I rowsort label-1618
SELECT col2 + - ( - 71 + - col2 ) DIV + 11 AS col1 FROM tab2 cor0
----
34
35
47

skipif mysql # not compatible
query I rowsort label-1618
SELECT col2 + - ( - 71 + - col2 ) / + 11 AS col1 FROM tab2 cor0
----
34
35
47

query I rowsort
SELECT + 49 FROM tab0, tab1 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT ALL - 48 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT ALL 18 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT + col2 + 90 FROM tab2 AS cor0
----
116
117
128

query I rowsort
SELECT - cor0.col1 * 59 AS col1 FROM tab2 AS cor0
----
-1003
-1829
-3481

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1624
SELECT - col0 * + CAST( NULL AS DECIMAL ) * col2 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1624
SELECT - col0 * + CAST ( NULL AS REAL ) * col2 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + + col0 * col0 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT col2 + col1 * - col1 * + tab2.col2 FROM tab2
----
-10944
-25920
-90480

query I rowsort
SELECT ALL col1 * col1 + 1 FROM tab0 cor0
----
7397
8282
9410

query I rowsort
SELECT ALL + col0 + + ( col0 ) FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1629
SELECT ALL + - col0 * + ( - cor0.col1 ) + CAST( - 94 * - col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1580
2262
2522

skipif mysql # not compatible
query I rowsort label-1629
SELECT ALL + - col0 * + ( - cor0.col1 ) + CAST ( - 94 * - col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1580
2262
2522

query I rowsort
SELECT ALL + - ( col1 ) * col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-1631
SELECT - col1 * + col0 + + col1 DIV col1 AS col0 FROM tab1 AS cor0
----
-1039
-639
-77

skipif mysql # not compatible
query I rowsort label-1631
SELECT - col1 * + col0 + + col1 / col1 AS col0 FROM tab1 AS cor0
----
-1039
-639
-77

query I rowsort
SELECT DISTINCT col2 * 97 FROM tab0
----
3201
7954
97

query I rowsort
SELECT - ( col2 ) + - col1 AS col0 FROM tab2
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1634
SELECT DISTINCT + col2 DIV - ( + col2 * 51 ) + + col0 AS col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1634
SELECT DISTINCT + col2 / - ( + col2 * 51 ) + + col0 AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT - tab2.col0 + - col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT 66 + col2 * col1 * - tab0.col0 + - col2 * col0 FROM tab0
----
-3364
-671350
-68838

query I rowsort
SELECT 31 * tab0.col1 FROM tab0
----
2666
2821
3007

query I rowsort
SELECT ( tab2.col2 * col1 ) + - col0 FROM tab2
----
1456
567
830

query I rowsort
SELECT DISTINCT - col2 + + tab2.col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT ( + ( + col0 ) * tab0.col0 ) - + col2 * col2 AS col1 FROM tab0
----
-513
1197
1224

query I rowsort
SELECT ( col2 ) * col0 + - 96 FROM tab1 AS cor0
----
3552
66
7584

query I rowsort
SELECT DISTINCT 23 * + 39 AS col1 FROM tab0 AS cor0
----
897

onlyif mysql # use DIV operator for integer division
query I rowsort label-1643
SELECT ALL + col2 + col1 DIV - col2 FROM tab0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-1643
SELECT ALL + col2 + col1 / - col2 FROM tab0
----
-96
31
81

query I rowsort
SELECT 88 * 98 AS col2 FROM tab2
----
8624
8624
8624

query I rowsort
SELECT + cor0.col0 * - 28 + - col2 FROM tab0 AS cor0
----
-2574
-705
-981

query I rowsort
SELECT DISTINCT - ( col1 + 79 ) AS col0 FROM tab1
----
-105
-89
-92

query I rowsort
SELECT ALL - cor0.col2 * ( - cor0.col1 ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b2e5b025b1c725661248b0f29aaef908

query I rowsort
SELECT + 87 AS col2 FROM tab0
----
87
87
87

query I rowsort
SELECT 82 + col1 * - col1 FROM tab0 AS cor0
----
-7314
-8199
-9327

query I rowsort
SELECT + col2 + - 90 FROM tab0 AS cor0
----
-57
-8
-89

query I rowsort
SELECT ALL col1 + + 86 * col1 * col2 AS col0 FROM tab0 AS cor0
----
244154
641823
8439

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1652
SELECT col2 + + CAST( 87 AS SIGNED ) * col2 AS col0 FROM tab2 AS cor0
----
2288
2376
3344

skipif mysql # not compatible
query I rowsort label-1652
SELECT col2 + + CAST ( 87 AS INTEGER ) * col2 AS col0 FROM tab2 AS cor0
----
2288
2376
3344

query I rowsort
SELECT DISTINCT - 20 AS col0 FROM tab2
----
-20

query I rowsort
SELECT + col0 * col2 * col0 AS col0 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT + cor0.col0 * 57 AS col0 FROM tab0 AS cor0
----
1368
1995
5073

query I rowsort
SELECT + + cor0.col0 * 98 AS col0 FROM tab2 cor0
----
686
7644
7742

query I rowsort
SELECT DISTINCT col2 + 15 * + col0 AS col2 FROM tab0 cor0
----
1417
393
526

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1658
SELECT ALL - col2 + col1 * col0 / CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1658
SELECT ALL - col2 + col1 * col0 / CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 + + ( + col1 ) * tab0.col0 * 20 FROM tab0
----
161891
41256
67865

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1660
SELECT ALL + col0 + + col1 * - CAST( col2 AS SIGNED ) * - col0 - + ( + ( cor0.col2 ) ) AS col2 FROM tab2 AS cor0
----
119704
51075
5839

skipif mysql # not compatible
query I rowsort label-1660
SELECT ALL + col0 + + col1 * - CAST ( col2 AS INTEGER ) * - col0 - + ( + ( cor0.col2 ) ) AS col2 FROM tab2 AS cor0
----
119704
51075
5839

onlyif mysql # use DIV operator for integer division
query I rowsort label-1661
SELECT + tab2.col2 DIV col1 + + col2 * col0 AS col1 FROM tab2
----
189
2028
3004

skipif mysql # not compatible
query I rowsort label-1661
SELECT + tab2.col2 / col1 + + col2 * col0 AS col1 FROM tab2
----
189
2028
3004

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + tab0.col2 col2 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL 42 + - col2 FROM tab1 AS cor0
----
-12
-15
-54

query I rowsort
SELECT ALL 79 AS col0 FROM tab2
----
79
79
79

query I rowsort
SELECT DISTINCT - cor0.col0 + - col0 * - col0 - + ( cor0.col0 ) * + col1 FROM tab0 AS cor0
----
-1512
-2205
-267

query I rowsort
SELECT ALL + + col2 - col0 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + col1 * col1 - - col1 * col2 AS col0 FROM tab2 AS cor0
----
1798
5015
935

query I rowsort
SELECT ALL col0 + col1 * - ( + col0 ) + - col0 * cor0.col2 FROM tab2 AS cor0
----
-399
-4266
-6552

query I rowsort
SELECT DISTINCT col0 * + cor0.col2 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 17 col0 FROM tab1 cor0
----
-17
-17
-17

query I rowsort
SELECT DISTINCT tab0.col2 + + col2 + tab0.col1 FROM tab0
----
152
255
99

query I rowsort
SELECT 19 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

onlyif mysql # use DIV operator for integer division
query I rowsort label-1673
SELECT col0 * 5 DIV col1 + col0 * tab1.col0 FROM tab1
----
4128
6430
9

skipif mysql # not compatible
query I rowsort label-1673
SELECT col0 * 5 / col1 + col0 * tab1.col0 FROM tab1
----
4128
6430
9

query I rowsort
SELECT DISTINCT - tab0.col1 + col2 * 63 FROM tab0
----
-34
1993
5075

query I rowsort
SELECT DISTINCT col2 * 67 + 43 * col1 AS col2 FROM tab2
----
3142
3277
4279

query I rowsort
SELECT cor0.col1 + + ( + 54 ) AS col0 FROM tab0 AS cor0
----
140
145
151

query I rowsort
SELECT - + cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT DISTINCT - col2 * - 66 AS col2 FROM tab0 AS cor0
----
2178
5412
66

query I rowsort
SELECT + 58 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) AS col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL 93 * 56 AS col2 FROM tab1 AS cor0
----
5208
5208
5208

query I rowsort
SELECT ALL - - cor0.col2 + + col1 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT + + 54 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
2916
3078
5184

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1684
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + ( - col2 ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1684
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + ( - col2 ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL ( - col1 ) + col0 + 0 AS col1 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 - col2 * col0 col2 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + + 87 + - col0 FROM tab1 AS cor0
----
23
7
84

query I rowsort
SELECT - ( + cor0.col2 ) AS col1 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT + ( + col0 ) * + col1 AS col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-1690
SELECT ( + 5 ) DIV col1 + - col0 * - col0 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-1690
SELECT ( + 5 ) / col1 + - col0 * - col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL col0 + ( + col0 ) FROM tab0
----
178
48
70

query I rowsort
SELECT - col0 + 15 AS col0 FROM tab0
----
-20
-74
-9

query I rowsort
SELECT - 34 * - 48 + col1 FROM tab2 AS cor0
----
1649
1663
1691

query I rowsort
SELECT - 24 + - col1 AS col0 FROM tab1 AS cor0
----
-34
-37
-50

query I rowsort
SELECT DISTINCT + cor0.col1 * - 22 - - col1 FROM tab0 AS cor0
----
-1806
-1911
-2037

query I rowsort
SELECT ALL cor0.col2 * + col1 * col0 AS col1 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-1697
SELECT + 27 + - 65 DIV cor0.col0 + + col2 AS col1 FROM tab0 cor0
----
109
27
58

skipif mysql # not compatible
query I rowsort label-1697
SELECT + 27 + - 65 / cor0.col0 + + col2 AS col1 FROM tab0 cor0
----
109
27
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1698
SELECT ALL - CAST( NULL AS SIGNED ) / - 71 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1698
SELECT ALL - CAST ( NULL AS INTEGER ) / - 71 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + 57 * - cor0.col0 FROM tab1 AS cor0
----
-145
-3638
-4547

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 84 col0 FROM tab2, tab0 AS cor0
----
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 65 col2 FROM tab0, tab0 AS cor0
----
65

query I rowsort
SELECT + + col1 + col0 + col0 AS col0 FROM tab0 cor0
----
134
167
269

onlyif mysql # use DIV operator for integer division
query I rowsort label-1703
SELECT + ( 49 ) + - col0 DIV - cor0.col0 AS col0 FROM tab2 AS cor0
----
50
50
50

skipif mysql # not compatible
query I rowsort label-1703
SELECT + ( 49 ) + - col0 / - cor0.col0 AS col0 FROM tab2 AS cor0
----
50
50
50

query I rowsort
SELECT col0 * 46 + col2 * col0 FROM tab0 cor0
----
11392
1645
1896

query I rowsort
SELECT DISTINCT cor1.col0 FROM tab1, tab0 cor0, tab2 AS cor1
----
7
78
79

query I rowsort
SELECT col0 * + col2 + 50 AS col1 FROM tab1 AS cor0
----
212
3698
7730

query I rowsort
SELECT - + cor0.col2 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-1708
SELECT DISTINCT col2 DIV + 74 AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-1708
SELECT DISTINCT col2 / + 74 AS col0 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 64 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT 32 * ( - col0 ) AS col0 FROM tab0
----
-1120
-2848
-768

query I rowsort
SELECT ALL 98 * 70 * col2 AS col0 FROM tab0
----
226380
562520
6860

query I rowsort
SELECT DISTINCT - col2 * - col2 + col2 FROM tab2
----
1482
702
756

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1713
SELECT ALL - - col2 + - CAST( NULL AS SIGNED ) / col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1713
SELECT ALL - - col2 + - CAST ( NULL AS INTEGER ) / col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 + - 19 AS col1 FROM tab0 AS cor0
----
67
72
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1715
SELECT - col0 DIV 25 col0 FROM tab2 AS cor0
----
-3
-3
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1715
SELECT - col0 / 25 col0 FROM tab2 AS cor0
----
-3
-3
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1716
SELECT ALL col1 / CAST( NULL AS SIGNED ) - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1716
SELECT ALL col1 / CAST ( NULL AS INTEGER ) - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * ( cor0.col0 ) + cor0.col0 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT ALL + - col1 + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT + col1 + + ( + col1 ) FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL col2 - 31 FROM tab0 AS cor0
----
-30
2
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-1721
SELECT DISTINCT col2 + col1 DIV + 97 AS col1 FROM tab0 AS cor0
----
2
33
82

skipif mysql # not compatible
query I rowsort label-1721
SELECT DISTINCT col2 + col1 / + 97 AS col1 FROM tab0 AS cor0
----
2
33
82

query I rowsort
SELECT ALL + col0 + + col2 + tab2.col2 FROM tab2
----
130
155
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 2 * col1 col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT ALL - col0 + - ( col2 * col0 ) FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT cor0.col2 + - col1 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1726
SELECT ALL col2 DIV 69 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1726
SELECT ALL col2 / 69 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 + col0 col2 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL - col2 * - 91 FROM tab2 AS cor0
----
2366
2457
3458

query I rowsort
SELECT + + col0 * + col2 * - col2 AS col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT 4 + + col1 FROM tab2 AS cor0
----
21
35
63

query I rowsort
SELECT DISTINCT ( cor1.col2 ) AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT col2 + + tab0.col1 * ( col2 ) AS col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT + col0 * + 11 + 73 * - col2 FROM tab1 AS cor0
----
-3457
-3909
-6128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col2 + col0 col2 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col0 * col2 * + col0 col1 FROM tab2 cor0
----
-1292
-158125
-237141

query I rowsort
SELECT ALL cor0.col2 * ( col0 ) * col2 - + col2 AS col2 FROM tab1 cor0
----
207879
737184
8694

query I rowsort
SELECT ALL - col0 - 0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - cor0.col0 + ( - 17 ) AS col1 FROM tab2 AS cor0
----
-24
-95
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1739
SELECT DISTINCT tab1.col0 DIV - 61 AS col0 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-1739
SELECT DISTINCT tab1.col0 / - 61 AS col0 FROM tab1
----
-1
0

query I rowsort
SELECT - 94 * col1 * + col2 AS col0 FROM tab0 cor0
----
-266772
-701428
-9118

onlyif mysql # use DIV operator for integer division
query I rowsort label-1741
SELECT + col2 DIV - 57 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1741
SELECT + col2 / - 57 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + + ( col1 ) * 14 AS col0 FROM tab0 AS cor0
----
1204
1274
1358

query I rowsort
SELECT ALL 5 * + col2 * + tab2.col2 FROM tab2
----
3380
3645
7220

query I rowsort
SELECT + cor0.col2 + + col1 AS col0 FROM tab1 cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1745
SELECT + - col2 DIV + col1 AS col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1745
SELECT + - col2 / + col1 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL 22 * col2 * + 12 FROM tab0 AS cor0
----
21648
264
8712

onlyif mysql # use DIV operator for integer division
query I rowsort label-1747
SELECT DISTINCT + - col0 DIV col1 + - 80 + + col1 AS col2 FROM tab1 cor0
----
-54
-73
-76

skipif mysql # not compatible
query I rowsort label-1747
SELECT DISTINCT + - col0 / col1 + - 80 + + col1 AS col2 FROM tab1 cor0
----
-54
-73
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-1748
SELECT - ( col0 ) DIV + cor0.col0 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1748
SELECT - ( col0 ) / + cor0.col0 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - + 25 + + col2 * ( col2 ) AS col2 FROM tab0 AS cor0
----
-24
1064
6699

query I rowsort
SELECT DISTINCT + - col0 * - cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - ( - tab2.col1 ) AS col2 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL cor0.col2 + col0 AS col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - 7 + + col2 * col1 + cor0.col0 AS col2 FROM tab0 AS cor0
----
125
2855
7544

query I rowsort
SELECT - - col1 + + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + + 91 * + cor1.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9f0a1bf1a98f8825cc1c5ab293f31a1c

onlyif mysql # use DIV operator for integer division
query I rowsort label-1756
SELECT DISTINCT col0 DIV - col1 AS col2 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-1756
SELECT DISTINCT col0 / - col1 AS col2 FROM tab0
----
0

query I rowsort
SELECT + 80 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT ALL + - 45 + 86 AS col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL - ( 49 ) * col0 AS col0 FROM tab2 AS cor0
----
-343
-3822
-3871

query I rowsort
SELECT - cor0.col1 * col1 + + col2 * + col2 FROM tab1 AS cor0
----
2240
3149
9047

query I rowsort
SELECT ALL 2 + + col0 AS col1 FROM tab1 AS cor0
----
5
66
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1762
SELECT DISTINCT - col2 * + ( + col1 * - CAST( - col2 AS SIGNED ) ) AS col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

skipif mysql # not compatible
query I rowsort label-1762
SELECT DISTINCT - col2 * + ( + col1 * - CAST ( - col2 AS INTEGER ) ) AS col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT + - col0 * + col2 + - col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT + - 75 + col1 AS col2 FROM tab2 AS cor0
----
-16
-44
-58

query I rowsort
SELECT DISTINCT + ( 22 ) * - cor0.col2 - - ( 83 ) AS col1 FROM tab0 AS cor0
----
-1721
-643
61

query I rowsort
SELECT ( - ( - col0 ) ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + - col2 - 0 FROM tab2 cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 * - col0 * col1 col1 FROM tab2
----
-22831
-271518
-6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-1769
SELECT ALL + col2 DIV 79 AS col2 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1769
SELECT ALL + col2 / 79 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + tab1.col0 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT 63 AS col0 FROM tab1
----
63

query I rowsort
SELECT 38 + 67 AS col0 FROM tab0 AS cor0
----
105
105
105

onlyif mysql # use DIV operator for integer division
query I rowsort label-1773
SELECT DISTINCT col1 DIV + col1 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-1773
SELECT DISTINCT col1 / + col1 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-1774
SELECT DISTINCT - col0 DIV - col1 AS col1 FROM tab2 cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-1774
SELECT DISTINCT - col0 / - col1 AS col1 FROM tab2 cor0
----
0
1
4

query I rowsort
SELECT cor0.col0 + + col2 * - col1 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT + + col2 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + col2 * + col0 + col1 AS col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - col0 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * + col0 + - col2 col2 FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT ALL - col0 + + tab1.col1 AS col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT cor0.col1 + + col2 * col1 FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col0 + col1 col1 FROM tab0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 + col2 col0 FROM tab1
----
121
124
163

onlyif mysql # use DIV operator for integer division
query I rowsort label-1784
SELECT DISTINCT col2 + tab0.col2 DIV col1 AS col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1784
SELECT DISTINCT col2 + tab0.col2 / col1 AS col2 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1785
SELECT ALL + col0 DIV col1 + tab1.col2 FROM tab1
----
102
54
63

skipif mysql # not compatible
query I rowsort label-1785
SELECT ALL + col0 / col1 + tab1.col2 FROM tab1
----
102
54
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col1 + col2 col0 FROM tab2 cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-1787
SELECT ALL + col0 DIV - col2 + col1 AS col2 FROM tab1 AS cor0
----
13
26
9

skipif mysql # not compatible
query I rowsort label-1787
SELECT ALL + col0 / - col2 + col1 AS col2 FROM tab1 AS cor0
----
13
26
9

query IIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 WHERE NOT NULL = NULL
----

query I rowsort
SELECT ALL + col1 + col2 * col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col0 AS col2 FROM tab0, tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - ( + col1 ) * col2 - - col1 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT ( 3 + + col2 ) FROM tab1
----
57
60
99

query I rowsort
SELECT - - col1 * cor0.col0 + cor0.col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT + col1 + - ( col2 ) * + col0 AS col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT + 5 + + 0 FROM tab1
----
5
5
5

query I rowsort
SELECT - col1 * - col2 * - col2 - + tab0.col1 FROM tab0
----
-194
-611975
-93740

onlyif mysql # use DIV operator for integer division
query I rowsort label-1798
SELECT ALL - 70 + col2 DIV col1 col2 FROM tab2
----
-68
-70
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1798
SELECT ALL - 70 + col2 / col1 col2 FROM tab2
----
-68
-70
-70

query I rowsort
SELECT ALL + 20 * + col2 AS col2 FROM tab0 cor0
----
1640
20
660

query I rowsort
SELECT 46 * col0 * + col2 + col1 * col1 AS col0 FROM tab2 AS cor0
----
138381
9655
96769

query I rowsort
SELECT + cor0.col2 - + col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL ( - col1 ) - col2 * col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT ALL + col0 + - col0 * col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT DISTINCT - - 87 * col0 + col0 * col1 AS col2 FROM tab2 AS cor0
----
11388
8216
826

query I rowsort
SELECT + ( - col0 ) * - col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - 39 * col2 AS col1 FROM tab0 AS cor0
----
-1287
-3198
-39

query I rowsort
SELECT DISTINCT + - 32 FROM tab1 AS cor0
----
-32

query I rowsort
SELECT col0 * cor0.col0 + col0 - + cor0.col1 FROM tab2 AS cor0
----
25
6103
6303

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + col1 col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT 31 + col1 AS col1 FROM tab2 cor0
----
48
62
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - + col1 col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - col1 + col2 * + col0 + col0 FROM tab1 AS cor0
----
139
3702
7747

query I rowsort
SELECT DISTINCT - - col2 + + col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + + cor0.col0 - + col1 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 * col2 col1 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT ALL col2 + + col1 + col2 * - col2 AS col1 FROM tab0
----
-6551
-970
97

query I rowsort
SELECT ALL col1 * - col1 * + col1 - col2 FROM tab0
----
-636089
-753653
-912674

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) <= ( - col0 )
----

query I rowsort
SELECT tab2.col1 * + col1 + col0 FROM tab2
----
3559
368
968

query I rowsort
SELECT DISTINCT col1 * - tab2.col1 * + col2 AS col0 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT ALL col1 * - col1 * col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

query III rowsort
SELECT * FROM tab2 cor0 WHERE col2 < col1 / - col1
----

query I rowsort
SELECT col2 * + col1 + - col0 FROM tab2 AS cor0 WHERE NOT col1 * + col2 * col0 NOT IN ( - col2 * col1 - col2 )
----

query I rowsort
SELECT ALL + col2 AS col1 FROM tab0 AS cor0 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT DISTINCT + col0 + + tab2.col0 AS col0 FROM tab2
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-1826
SELECT DISTINCT col0 * tab2.col2 DIV + col0 AS col2 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-1826
SELECT DISTINCT col0 * tab2.col2 / + col0 AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT - col2 * col2 * - col2 + - col2 * col0 + col0 FROM tab0
----
1
35169
544159

query I rowsort
SELECT DISTINCT col0 AS col2 FROM tab1 WHERE NOT NULL NOT IN ( - tab1.col2 )
----

query I rowsort
SELECT - col1 + col0 * - col2 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT - col2 * col1 - - col2 * tab2.col0 AS col0 FROM tab2
----
-648
2356
494

query I rowsort
SELECT ALL col2 + + tab0.col0 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT col1 + - col2 * - col0 - col0 FROM tab1
----
185
3594
7613

query I rowsort
SELECT ALL tab0.col0 + col1 + col0 AS col0 FROM tab0
----
134
167
269

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL NOT IN ( col0 * col1 + + col0 )
----

query I rowsort
SELECT col0 * col0 * - col2 AS col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT + tab1.col2 FROM tab1 WHERE NOT ( NULL ) IN ( + col2 - + col1 )
----

query I rowsort
SELECT ALL + col1 + col0 * + col0 AS col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + - col0 * - col2 + col2 * - col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * - col0 + + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-1840
SELECT - col0 + + col0 DIV col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-1840
SELECT - col0 + + col0 / col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT ALL + + col1 + col2 * cor0.col0 AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT cor0.col0 FROM tab1, tab2 cor0 WHERE NOT NULL <= NULL
----

query I rowsort
SELECT + + ( cor0.col1 ) + cor0.col0 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + 20 + - col1 AS col2 FROM tab2 cor0
----
-11
-39
3

query I rowsort
SELECT ALL ( 12 ) * cor0.col2 AS col1 FROM tab2 cor0
----
312
324
456

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1846
SELECT - + CAST( NULL AS SIGNED ) + + col2 * col0 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-1846
SELECT - + CAST ( NULL AS INTEGER ) + + col2 * col0 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + 48 col1 FROM tab1
----
144
3072
3840

query I rowsort
SELECT DISTINCT 4 AS col0 FROM tab1, tab1 AS cor0
----
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-1849
SELECT DISTINCT + 74 DIV 84 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-1849
SELECT DISTINCT + 74 / 84 FROM tab0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1850
SELECT - + col1 - + col0 DIV - col2 FROM tab1 AS cor0
----
-13
-26
-9

skipif mysql # not compatible
query I rowsort label-1850
SELECT - + col1 - + col0 / - col2 FROM tab1 AS cor0
----
-13
-26
-9

query I rowsort
SELECT - col2 * - 82 + - cor0.col1 FROM tab0 cor0
----
-15
2620
6633

query I rowsort
SELECT + col0 - - col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT + col1 + - col2 * col0 AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + 71 col1 FROM tab1 AS cor0
----
3834
4047
6816

query I rowsort
SELECT ALL + - col1 * cor0.col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + - 67 * cor0.col0 + + cor0.col0 * 79 + - col2 FROM tab1 cor0
----
-18
711
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-1857
SELECT + cor0.col2 * - col1 + - 29 + + 30 DIV col2 FROM tab0 cor0
----
-2867
-7491
-96

skipif mysql # not compatible
query I rowsort label-1857
SELECT + cor0.col2 * - col1 + - 29 + + 30 / col2 FROM tab0 cor0
----
-2867
-7491
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * col1 * + 30 col1 FROM tab1 AS cor0
----
20280
3000
5070

query I rowsort
SELECT 21 FROM tab2, tab0 cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT - 24 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f2e40f6e5cdbc2877843191cb261975f

query I rowsort
SELECT + col1 * 54 AS col1 FROM tab2 AS cor0
----
1674
3186
918

query I rowsort
SELECT DISTINCT - col1 * - ( - col2 ) AS col0 FROM tab2
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1863
SELECT - col2 + + CAST( NULL AS SIGNED ) col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1863
SELECT - col2 + + CAST ( NULL AS INTEGER ) col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT - 57 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1866
SELECT + col1 + + CAST( NULL AS SIGNED ) * col0 * col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1866
SELECT + col1 + + CAST ( NULL AS INTEGER ) * col0 * col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 * col0 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + col0 + - col0 AS col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT + col0 * col1 + col2 * - col1 + col1 FROM tab0 AS cor0
----
-688
3395
728

onlyif mysql # use DIV operator for integer division
query I rowsort label-1870
SELECT col1 DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1870
SELECT col1 / cor0.col0 AS col1 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL - + 39 + 88 AS col2 FROM tab0 cor0
----
49
49
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col2 + + cor0.col2 col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - ( col2 ) + + cor0.col0 AS col2 FROM tab1 AS cor0
----
-16
-51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col0 ) col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + col0 * 84 AS col2 FROM tab1
----
252
5376
6720

query I rowsort
SELECT + col1 * col1 * + col1 AS col1 FROM tab1 AS cor0
----
1000
17576
2197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 * col0 col2 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT + + col0 + cor0.col0 * col1 * - col0 + cor0.col2 FROM tab2 AS cor0
----
-105980
-1485
-358852

query I rowsort
SELECT - - col1 + cor0.col0 + 13 AS col0 FROM tab0 AS cor0
----
123
145
193

query I rowsort
SELECT ALL - 13 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 1c6aaa07ba8d3dc01ee616e16bef60f2

query I rowsort
SELECT col2 + col2 + ( + 56 ) * cor0.col0 AS col1 FROM tab2 AS cor0
----
4420
446
4500

query I rowsort
SELECT - col1 * col2 + col2 * - col1 * cor0.col2 FROM tab0 cor0
----
-194
-619346
-96492

query I rowsort
SELECT + - 45 * - col2 FROM tab2 AS cor0
----
1170
1215
1710

onlyif mysql # use DIV operator for integer division
query I rowsort label-1884
SELECT ALL - 6 * - col2 + - 63 DIV 68 + + col1 AS col0 FROM tab2 AS cor0
----
193
215
245

skipif mysql # not compatible
query I rowsort label-1884
SELECT ALL - 6 * - col2 + - 63 / 68 + + col1 AS col0 FROM tab2 AS cor0
----
193
215
245

query I rowsort
SELECT DISTINCT - + col0 * + col2 + - col1 * - col1 FROM tab2 cor0
----
-2713
1453
772

query I rowsort
SELECT DISTINCT - - 0 + + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - - 61 + - col2 AS col0 FROM tab2 AS cor0
----
23
34
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col2 col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT 75 * col0 FROM tab2
----
525
5850
5925

query I rowsort
SELECT ALL 57 * col1 FROM tab0
----
4902
5187
5529

query I rowsort
SELECT DISTINCT - col1 + - 48 * col2 FROM tab0 AS cor0
----
-145
-1670
-4027

query I rowsort
SELECT - col1 + - ( col2 ) FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col2 + col0 + col2 col2 FROM tab1 cor0
----
-2859
-3128
-9040

query I rowsort
SELECT DISTINCT - tab2.col2 * col2 + ( col2 ) FROM tab2
----
-1406
-650
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-1895
SELECT DISTINCT - 71 * col1 * 68 + col2 * col0 + - tab2.col0 DIV - col0 AS col1 FROM tab2
----
-149478
-282823
-79073

skipif mysql # not compatible
query I rowsort label-1895
SELECT DISTINCT - 71 * col1 * 68 + col2 * col0 + - tab2.col0 / - col0 AS col1 FROM tab2
----
-149478
-282823
-79073

query I rowsort
SELECT - col0 + - col0 + 0 * 73 AS col0 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT col1 + - col2 * ( 88 ) AS col1 FROM tab1
----
-4726
-5006
-8435

query I rowsort
SELECT - ( tab0.col0 + tab0.col2 ) AS col2 FROM tab0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 52 * - tab2.col2 * 6 + 28 col2 FROM tab2
----
11884
8140
8452

onlyif mysql # use DIV operator for integer division
query I rowsort label-1900
SELECT DISTINCT - col1 * col1 DIV col1 col0 FROM tab1
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1900
SELECT DISTINCT - col1 * col1 / col1 col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL + cor0.col1 FROM tab1, tab2, tab2 cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + col2 + - col2 * - ( 85 ) FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT cor0.col0 * col2 + - col2 * cor0.col2 FROM tab1 AS cor0
----
-1536
-2754
399

query I rowsort
SELECT + + col2 + + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-1905
SELECT DISTINCT + 55 DIV - col1 FROM tab1 AS cor0
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-1905
SELECT DISTINCT + 55 / - col1 FROM tab1 AS cor0
----
-2
-4
-5

query I rowsort
SELECT - col1 * + cor0.col2 - - ( ( col2 ) ) * col2 FROM tab1 AS cor0
----
1512
2679
7968

query I rowsort
SELECT DISTINCT cor0.col2 + - 36 FROM tab2, tab1 cor0
----
18
21
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-1908
SELECT ALL - 24 DIV - col0 + + tab2.col2 AS col2 FROM tab2
----
26
30
38

skipif mysql # not compatible
query I rowsort label-1908
SELECT ALL - 24 / - col0 + + tab2.col2 AS col2 FROM tab2
----
26
30
38

query I rowsort
SELECT col1 + col0 * + ( + col2 ) - col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - 13 * + col1 * ( + cor0.col2 ) FROM tab2 AS cor0
----
-10881
-19942
-8398

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-1912
SELECT ALL - ( col0 ) DIV 74 AS col2 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1912
SELECT ALL - ( col0 ) / 74 AS col2 FROM tab1 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1913
SELECT + + col0 + cor0.col0 DIV col1 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-1913
SELECT + + col0 + cor0.col0 / col1 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT ALL - 61 AS col0 FROM tab0 AS cor0
----
-61
-61
-61

query I rowsort
SELECT + col1 * col0 - + cor0.col2 * cor0.col1 FROM tab1 AS cor0
----
-1326
-208
70

query I rowsort
SELECT DISTINCT - col0 + - col0 * 34 FROM tab2 AS cor0
----
-245
-2730
-2765

query I rowsort
SELECT DISTINCT 77 AS col2 FROM tab1 AS cor0
----
77

query I rowsort
SELECT - col1 * - col1 + + ( cor0.col2 ) FROM tab2 cor0
----
327
3507
988

query I rowsort
SELECT - - col0 * 58 + - 94 FROM tab0 AS cor0
----
1298
1936
5068

query I rowsort
SELECT col0 * 39 + 84 * + col1 FROM tab2 AS cor0
----
2877
4509
7998

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col2 col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT - tab0.col1 AS col0 FROM tab0, tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - cor0.col0 - col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT 60 FROM tab1 cor0
----
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-1925
SELECT DISTINCT + col2 + + cor0.col2 DIV col0 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-1925
SELECT DISTINCT + col2 + + cor0.col2 / col0 FROM tab1 AS cor0
----
57
72
97

query I rowsort
SELECT - 13 + - ( col2 ) FROM tab0 AS cor0
----
-14
-46
-95

query I rowsort
SELECT DISTINCT - - 21 + + 94 * + col0 AS col0 FROM tab1 AS cor0
----
303
6037
7541

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1928
SELECT ALL + CAST( 84 AS SIGNED ) + col2 FROM tab1 AS cor0
----
138
141
180

skipif mysql # not compatible
query I rowsort label-1928
SELECT ALL + CAST ( 84 AS INTEGER ) + col2 FROM tab1 AS cor0
----
138
141
180

query I rowsort
SELECT tab2.col1 * + tab2.col1 + + 8 FROM tab2
----
297
3489
969

query I rowsort
SELECT ALL + 33 * - col0 AS col0 FROM tab0 AS cor0
----
-1155
-2937
-792

query I rowsort
SELECT ALL + col2 + + col2 * cor0.col0 AS col0 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT ALL + 62 FROM tab1
----
62
62
62

query I rowsort
SELECT DISTINCT + cor0.col0 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
7
78
79

query I rowsort
SELECT DISTINCT 66 * - 82 * col0 AS col2 FROM tab0
----
-129888
-189420
-481668

query I rowsort
SELECT ALL + + 84 + col1 AS col2 FROM tab0 AS cor0
----
170
175
181

query I rowsort
SELECT + 7 * - col2 FROM tab2 AS cor0
----
-182
-189
-266

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 76 ) + col2 * ( col1 ) col1 FROM tab0
----
21
2762
7386

query I rowsort
SELECT ALL - 27 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 96d69a44243853624f324b296563e205

query I rowsort
SELECT col2 + tab2.col2 * col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT - ( col1 * col2 ) AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT 98 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT ALL 70 * col0 AS col0 FROM tab0
----
1680
2450
6230

onlyif mysql # use DIV operator for integer division
query I rowsort label-1943
SELECT ALL + col0 DIV + tab1.col2 AS col1 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1943
SELECT ALL + col0 / + tab1.col2 AS col1 FROM tab1
----
0
0
1

query I rowsort
SELECT + ( 93 ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT - col2 + col1 AS col0 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + col2 * + 73 FROM tab2 AS cor0
----
1898
1971
2774

query I rowsort
SELECT - 33 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

query I rowsort
SELECT DISTINCT + + 39 + col0 FROM tab1 AS cor0
----
103
119
42

query I rowsort
SELECT ALL 76 + 49 AS col1 FROM tab2 AS cor0
----
125
125
125

query I rowsort
SELECT ALL cor0.col0 + cor0.col2 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - 29 + cor1.col2 FROM tab1, tab0 cor0, tab0, tab0 AS cor1
----
81 values hashing to 32ae48b43a5808cce6e6bb99edb8bb6c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 86 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT cor0.col0 + col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 34 AS col1 FROM tab0 cor0
----
34
34
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 54 + cor0.col1 col0 FROM tab0 AS cor0
----
140
145
151

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1956
SELECT + CAST( - col2 AS SIGNED ) * + col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort label-1956
SELECT + CAST ( - col2 AS INTEGER ) * + col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 83 col0 FROM tab2 AS cor0
----
-1411
-2573
-4897

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - col2 * + CAST ( - 10 AS REAL ) AS col2 FROM tab0 AS cor0
----
-10
-330
-820

query I rowsort
SELECT DISTINCT + 8 AS col0 FROM tab0, tab1 AS cor0
----
8

query I rowsort
SELECT - col1 * 42 AS col0 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT DISTINCT col0 + col2 * + col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-1962
SELECT ALL cor0.col1 DIV cor0.col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-1962
SELECT ALL cor0.col1 / cor0.col2 FROM tab0 AS cor0
----
1
2
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1963
SELECT DISTINCT - CAST( NULL AS SIGNED ) * - 1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1963
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * - 1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col1 + col2 * col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT 71 * - col0 AS col1 FROM tab2 AS cor0
----
-497
-5538
-5609

onlyif mysql # use DIV operator for integer division
query I rowsort label-1966
SELECT DISTINCT + + col1 + col0 DIV col2 FROM tab1 AS cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-1966
SELECT DISTINCT + + col1 + col0 / col2 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT ALL + col0 + + 93 AS col2 FROM tab0 AS cor0
----
117
128
182

query I rowsort
SELECT - 7 * col1 AS col1 FROM tab0 AS cor0
----
-602
-637
-679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1969
SELECT ALL + col1 * + CAST( NULL AS SIGNED ) col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1969
SELECT ALL + col1 * + CAST ( NULL AS INTEGER ) col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * - col0 * + col1 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT - + 15 AS col2 FROM tab1 AS cor0
----
-15
-15
-15

query I rowsort
SELECT - 43 + cor0.col2 FROM tab0 AS cor0
----
-10
-42
39

query I rowsort
SELECT - 3 * - col0 + + 8 AS col2 FROM tab0 cor0
----
113
275
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1974
SELECT col0 + + col1 DIV 7 AS col2 FROM tab0 AS cor0
----
102
36
48

skipif mysql # not compatible
query I rowsort label-1974
SELECT col0 + + col1 / 7 AS col2 FROM tab0 AS cor0
----
102
36
48

query I rowsort
SELECT + + 6 + col0 * col2 FROM tab0 AS cor0
----
41
7304
798

query I rowsort
SELECT DISTINCT - 60 AS col2 FROM tab2, tab0 AS cor0
----
-60

query I rowsort
SELECT col1 + col0 + col2 AS col2 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT DISTINCT col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT 38 * col1 FROM tab0
----
3268
3458
3686

query I rowsort
SELECT DISTINCT - 39 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-39

query I rowsort
SELECT ALL + 2 + 36 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT col1 * - col2 + 6 FROM tab2 AS cor0
----
-1528
-640
-831

query I rowsort
SELECT DISTINCT + col0 + col1 * 37 * + col2 FROM tab0 AS cor0
----
105030
276183
3624

query I rowsort
SELECT col2 - col2 * col1 AS col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT + col2 * tab2.col2 + + col2 AS col1 FROM tab2
----
1482
702
756

query I rowsort
SELECT + - col1 * 81 + ( - col1 + + col0 ) AS col2 FROM tab0 AS cor0
----
-7028
-7373
-7919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1987
SELECT ALL + cor0.col1 * CAST( NULL AS SIGNED ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1987
SELECT ALL + cor0.col1 * CAST ( NULL AS INTEGER ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1988
SELECT DISTINCT col0 - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1988
SELECT DISTINCT col0 - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col2 * + 36 FROM tab0 cor0
----
1188
2952
36

query I rowsort
SELECT tab2.col0 + col2 * + col2 * - 79 AS col2 FROM tab2
----
-113997
-53326
-57584

query I rowsort
SELECT - ( col0 ) + col2 * + 56 FROM tab0
----
1824
21
4503

onlyif mysql # use DIV operator for integer division
query I rowsort label-1992
SELECT DISTINCT col1 DIV - col1 + col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-1992
SELECT DISTINCT col1 / - col1 + col0 FROM tab1
----
2
63
79

query I rowsort
SELECT DISTINCT + 96 + col0 * + 34 FROM tab1
----
198
2272
2816

query I rowsort
SELECT - col0 + col0 * - col2 AS col1 FROM tab0
----
-70
-7387
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1995
SELECT ALL + col2 + CAST( col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-1995
SELECT ALL + col2 + CAST ( col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + col1 + + 67 FROM tab0 AS cor0
----
153
158
164

query I rowsort
SELECT ALL - col2 + - col1 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT col1 * col0 * 70 AS col0 FROM tab0 AS cor0
----
144480
237650
566930

query I rowsort
SELECT ALL + col0 + ( + col1 ) * - col0 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT + col0 + + 52 * + 64 AS col0 FROM tab0 AS cor0
----
3352
3363
3417

onlyif mysql # use DIV operator for integer division
query I rowsort label-2001
SELECT - + col1 DIV cor0.col2 + + col1 AS col1 FROM tab0 cor0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-2001
SELECT - + col1 / cor0.col2 + + col1 AS col1 FROM tab0 cor0
----
0
84
90

query I rowsort
SELECT DISTINCT col1 + - col0 * - cor0.col0 * col1 AS col2 FROM tab2 AS cor0
----
106114
1550
359015

query I rowsort
SELECT DISTINCT + col1 * col2 + - col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT col2 + col0 * col2 * col1 FROM tab0 AS cor0
----
3396
664200
68145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col0 * col1 col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT col1 + col2 + col2 FROM tab0
----
152
255
99

query I rowsort
SELECT DISTINCT col1 - col2 AS col0 FROM tab0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2008
SELECT 81 DIV - tab1.col0 FROM tab1
----
-1
-1
-27

skipif mysql # not compatible
query I rowsort label-2008
SELECT 81 / - tab1.col0 FROM tab1
----
-1
-1
-27

query I rowsort
SELECT - ( col2 ) * + cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2010
SELECT CAST( NULL AS SIGNED ) - - col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2010
SELECT CAST ( NULL AS INTEGER ) - - col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 89 col1 FROM tab1, tab1 cor0 CROSS JOIN tab0, tab2 AS cor1
----
81 values hashing to 1e1759ead845b97a0ef58dbd6a959d73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2012
SELECT - CAST( col1 AS SIGNED ) * + col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-2012
SELECT - CAST ( col1 AS INTEGER ) * + col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + + ( cor0.col2 ) * + 38 + - col2 AS col2 FROM tab2 AS cor0
----
1406
962
999

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 86 + - col2 col1 FROM tab0 AS cor0
----
4
53
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2015
SELECT + col0 + col2 DIV + 41 AS col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2015
SELECT + col0 + col2 / + 41 AS col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2016
SELECT - col2 * - col2 + + CAST( 75 AS SIGNED ) * cor0.col2 AS col1 FROM tab2 AS cor0
----
2626
2754
4294

skipif mysql # not compatible
query I rowsort label-2016
SELECT - col2 * - col2 + + CAST ( 75 AS INTEGER ) * cor0.col2 AS col1 FROM tab2 AS cor0
----
2626
2754
4294

query I rowsort
SELECT - 75 * cor0.col1 + - col1 AS col1 FROM tab1 AS cor0
----
-1976
-760
-988

query I rowsort
SELECT ALL + col1 + + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - + 12 + col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
177
2016
2990

query I rowsort
SELECT + 9 * - col0 + col2 AS col2 FROM tab2 cor0
----
-36
-673
-676

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 + - cor0.col1 * + CAST ( col1 AS REAL ) FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT DISTINCT - - ( cor0.col0 ) + - 66 * + ( col2 ) AS col2 FROM tab2 AS cor0
----
-1638
-1775
-2429

query I rowsort
SELECT ALL col0 * col2 - col2 * 8 * - col1 FROM tab2 AS cor0
----
14300
6885
8170

query I rowsort
SELECT - ( - 45 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT DISTINCT - col2 * ( - col2 ) FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - col0 * + 78 AS col1 FROM tab1 AS cor0
----
-234
-4992
-6240

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2027
SELECT + CAST( - col1 AS SIGNED ) + col2 * + col0 * - cor0.col2 FROM tab2 AS cor0
----
-114093
-5134
-52787

skipif mysql # not compatible
query I rowsort label-2027
SELECT + CAST ( - col1 AS INTEGER ) + col2 * + col0 * - cor0.col2 FROM tab2 AS cor0
----
-114093
-5134
-52787

query I rowsort
SELECT DISTINCT + tab2.col0 * - 67 AS col0 FROM tab2
----
-469
-5226
-5293

query I rowsort
SELECT DISTINCT + - col1 + - cor0.col0 * - col1 * - col0 AS col1 FROM tab0 AS cor0
----
-118922
-49622
-720902

query I rowsort
SELECT DISTINCT + + 2 * col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT + ( - col1 ) + col2 * 92 FROM tab0 AS cor0
----
-5
2950
7453

query I rowsort
SELECT + col0 + + 67 FROM tab2 AS cor0
----
145
146
74

query I rowsort
SELECT DISTINCT ( 26 ) AS col1 FROM tab1 AS cor0
----
26

query I rowsort
SELECT DISTINCT - - ( cor0.col0 ) + col1 + ( + 68 ) FROM tab2 AS cor0
----
106
164
205

query I rowsort
SELECT ( - ( - cor0.col2 ) ) + - 95 * ( col2 ) AS col0 FROM tab1 AS cor0
----
-5076
-5358
-9024

query I rowsort
SELECT 74 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

query I rowsort
SELECT + 53 * col0 + col0 + 72 * + col2 AS col0 FROM tab1 AS cor0
----
11232
4050
7560

query I rowsort
SELECT DISTINCT - col0 + - col2 + col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + col1 + - col1 + cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - - 3 * + col0 AS col1 FROM tab0 AS cor0
----
105
267
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-2041
SELECT ALL col0 * + col0 + - 19 * col0 DIV col1 FROM tab2 AS cor0
----
45
6059
6153

skipif mysql # not compatible
query I rowsort label-2041
SELECT ALL col0 * + col0 + - 19 * col0 / col1 FROM tab2 AS cor0
----
45
6059
6153

query I rowsort
SELECT DISTINCT - 40 + col0 FROM tab0
----
-16
-5
49

query I rowsort
SELECT ALL + col0 + ( + col2 ) AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + col0 * ( 82 ) FROM tab2 AS cor0
----
574
6396
6478

query I rowsort
SELECT DISTINCT cor0.col0 + col0 * + col1 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT cor0.col0 + - ( - col1 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT 16 + + tab2.col0 AS col0 FROM tab2
----
23
94
95

query I rowsort
SELECT + 75 AS col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT - col2 * + col0 + ( col2 ) * tab1.col2 AS col0 FROM tab1
----
-399
1536
2754

query I rowsort
SELECT DISTINCT 43 * - col1 * col0 AS col1 FROM tab0
----
-145985
-348257
-88752

query I rowsort
SELECT DISTINCT ( + col2 ) AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT - ( + col1 ) * + col2 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT + - col2 + - 37 FROM tab0 AS cor0
----
-119
-38
-70

query I rowsort
SELECT col1 * - cor0.col2 * 15 AS col0 FROM tab0 AS cor0
----
-111930
-1455
-42570

query I rowsort
SELECT DISTINCT - col1 + 36 * + col2 FROM tab0 AS cor0
----
-61
1102
2861

query I rowsort
SELECT - - col0 + - col2 * 87 FROM tab0 cor0
----
-2847
-52
-7045

query I rowsort
SELECT DISTINCT + - col2 + col2 * + col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT - col1 * ( + col0 ) + col2 * - ( - col2 ) FROM tab1 AS cor0
----
2609
2838
8176

onlyif mysql # use DIV operator for integer division
query I rowsort label-2059
SELECT - col0 * - tab2.col2 + + col1 DIV 69 FROM tab2
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-2059
SELECT - col0 * - tab2.col2 + + col1 / 69 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL tab0.col1 * col2 + col0 * col1 FROM tab0
----
15561
3492
4902

query I rowsort
SELECT + + col0 + - col2 * - col0 FROM tab0 cor0
----
70
7387
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col0 col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL - 80 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 26dbcc98d4b4e864ffa31be685a5dfbd

query I rowsort
SELECT + ( - cor0.col1 ) + - cor0.col2 * + 75 AS col1 FROM tab2 AS cor0
----
-2009
-2056
-2867

onlyif mysql # use DIV operator for integer division
query I rowsort label-2065
SELECT col0 - + col0 DIV cor0.col2 FROM tab0 AS cor0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-2065
SELECT col0 - + col0 / cor0.col2 FROM tab0 AS cor0
----
0
24
88

query I rowsort
SELECT DISTINCT + col2 + - ( + col2 + ( - col1 ) * col0 ) AS col0 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2067
SELECT - tab2.col0 * + col1 DIV + col1 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-2067
SELECT - tab2.col0 * + col1 / + col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL ( + 16 * + col2 ) + - col2 * 85 * + col1 FROM tab2
----
-129974
-54302
-70713

onlyif mysql # use DIV operator for integer division
query I rowsort label-2069
SELECT DISTINCT + col2 DIV col2 + col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-2069
SELECT DISTINCT + col2 / col2 + col1 FROM tab1
----
11
14
27

query I rowsort
SELECT 63 + - 69 + + col1 * + col0 AS col0 FROM tab1
----
1034
634
72

query I rowsort
SELECT + col0 * + 37 AS col1 FROM tab2
----
259
2886
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor1.col2 col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT DISTINCT - 52 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
-52

query I rowsort
SELECT ALL + - col0 + - col0 + ( col1 ) * col2 FROM tab0 AS cor0
----
27
2790
7284

query I rowsort
SELECT ALL + ( - col1 ) * - 28 * col2 + col1 * + col0 * - 35 FROM tab1 cor0
----
-1456
-6440
36582

query I rowsort
SELECT + col1 - + col2 * - ( + col2 ) FROM tab1 AS cor0
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 70 * - cor0.col1 col2 FROM tab2 AS cor0
----
1190
2170
4130

query I rowsort
SELECT ( cor0.col0 ) + 73 AS col1 FROM tab2 AS cor0
----
151
152
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2079
SELECT ALL - col2 + col0 DIV + 71 FROM tab0 AS cor0
----
-1
-33
-81

skipif mysql # not compatible
query I rowsort label-2079
SELECT ALL - col2 + col0 / + 71 FROM tab0 AS cor0
----
-1
-33
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + + col2 col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL - col2 + + col2 * 55 + col2 * col1 FROM tab2 AS cor0
----
2295
2698
2938

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2082
SELECT DISTINCT + - col0 + col1 * CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
-3559
-368
-968

skipif mysql # not compatible
query I rowsort label-2082
SELECT DISTINCT + - col0 + col1 * CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
-3559
-368
-968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2083
SELECT DISTINCT CAST( 60 AS SIGNED ) + col0 AS col0 FROM tab1
----
124
140
63

skipif mysql # not compatible
query I rowsort label-2083
SELECT DISTINCT CAST ( 60 AS INTEGER ) + col0 AS col0 FROM tab1
----
124
140
63

query I rowsort
SELECT - 12 * - ( tab2.col1 ) FROM tab2
----
204
372
708

query I rowsort
SELECT DISTINCT + col1 + col0 * + col1 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT + 15 * + col0 FROM tab1
----
1200
45
960

query I rowsort
SELECT + col0 * 61 * col0 FROM tab0
----
35136
483181
74725

query I rowsort
SELECT + ( + col1 ) + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - - 67 + + col0 + col1 FROM tab2 AS cor0
----
105
163
204

query I rowsort
SELECT + col2 + - col0 + + cor0.col0 * col2 FROM tab0 AS cor0
----
1
7291
801

query I rowsort
SELECT ALL - ( col0 ) * 64 - col0 AS col2 FROM tab0 AS cor0
----
-1560
-2275
-5785

query I rowsort
SELECT DISTINCT ( tab2.col1 ) * - col0 * - 34 FROM tab2
----
156468
45662
7378

query I rowsort
SELECT col1 * + col2 * col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT ALL 32 AS col0 FROM tab2
----
32
32
32

query I rowsort
SELECT ALL - cor0.col2 - + cor0.col2 FROM tab2 AS cor0
----
-52
-54
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2096
SELECT + col0 DIV + col2 + + 24 col0 FROM tab1 AS cor0
----
24
24
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2096
SELECT + col0 / + col2 + + 24 col0 FROM tab1 AS cor0
----
24
24
25

query I rowsort
SELECT ALL - cor0.col0 + - col1 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL 70 + cor0.col0 * col1 * 13 FROM tab0 AS cor0
----
105357
26902
44205

query I rowsort
SELECT DISTINCT + + 50 AS col2 FROM tab2 AS cor0
----
50

query I rowsort
SELECT cor0.col1 * 77 + col0 AS col1 FROM tab1 AS cor0
----
1081
2005
834

query I rowsort
SELECT - + col0 * + 93 AS col2 FROM tab1 AS cor0
----
-279
-5952
-7440

query I rowsort
SELECT - col2 + + 30 * col1 FROM tab0 cor0
----
2547
2648
2909

onlyif mysql # use DIV operator for integer division
query I rowsort label-2103
SELECT col1 DIV + 8 - col1 AS col2 FROM tab2 AS cor0
----
-15
-28
-52

skipif mysql # not compatible
query I rowsort label-2103
SELECT col1 / + 8 - col1 AS col2 FROM tab2 AS cor0
----
-15
-28
-52

query I rowsort
SELECT col1 * + 7 + col1 * col1 AS col0 FROM tab0 cor0
----
10088
7998
8918

onlyif mysql # use DIV operator for integer division
query I rowsort label-2105
SELECT DISTINCT + col1 * - col2 + 58 DIV - col0 FROM tab1
----
-1248
-1423
-570

skipif mysql # not compatible
query I rowsort label-2105
SELECT DISTINCT + col1 * - col2 + 58 / - col0 FROM tab1
----
-1248
-1423
-570

query I rowsort
SELECT ( - col0 ) + - 8 * col1 AS col1 FROM tab1
----
-144
-184
-211

query I rowsort
SELECT col1 + - col0 * - col2 AS col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT cor0.col0 + col2 * + cor0.col1 + col1 * col2 AS col0 FROM tab0 AS cor0
----
15013
229
5700

query I rowsort
SELECT - + col1 * col0 - 65 AS col1 FROM tab0 cor0
----
-2129
-3460
-8164

query I rowsort
SELECT ALL cor0.col0 + + 38 AS col0 FROM tab2 AS cor0
----
116
117
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2111
SELECT ALL + CAST( col2 AS SIGNED ) + + col1 AS col2 FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-2111
SELECT ALL + CAST ( col2 AS INTEGER ) + + col1 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + - 98 AS col2 FROM tab0 AS cor0
----
-98

query I rowsort
SELECT ALL + cor0.col0 + 17 AS col0 FROM tab0 cor0
----
106
41
52

query I rowsort
SELECT - cor0.col2 + cor0.col2 + col2 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + 21 + col1 * - col1 FROM tab1 cor0
----
-148
-655
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col1 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + col1 - - 16 FROM tab2 AS cor0
----
33
47
75

query I rowsort
SELECT ALL - col0 * + col2 + cor0.col0 + 41 FROM tab0 cor0
----
-7168
-727
41

query I rowsort
SELECT - 2 + + col2 AS col0 FROM tab1 AS cor0
----
52
55
94

query I rowsort
SELECT DISTINCT ( 67 ) + col2 * col0 AS col1 FROM tab0 AS cor0
----
102
7365
859

query I rowsort
SELECT DISTINCT + cor0.col2 + col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT 33 * - col0 + + col2 FROM tab2 AS cor0
----
-204
-2548
-2569

query I rowsort
SELECT ALL - - 39 + - col1 FROM tab2 AS cor0
----
-20
22
8

query I rowsort
SELECT ALL - 32 + col0 FROM tab0 AS cor0
----
-8
3
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2125
SELECT DISTINCT 44 DIV col0 AS col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2125
SELECT DISTINCT 44 / col0 AS col0 FROM tab0 AS cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2126
SELECT ALL - CAST( col0 * col0 AS SIGNED ) + + col2 * tab0.col0 FROM tab0
----
-1190
-623
216

skipif mysql # not compatible
query I rowsort label-2126
SELECT ALL - CAST ( col0 * col0 AS INTEGER ) + + col2 * tab0.col0 FROM tab0
----
-1190
-623
216

query I rowsort
SELECT ALL 19 + + ( col2 + + col1 ) FROM tab0
----
117
138
192

query I rowsort
SELECT DISTINCT + col1 * col2 + ( - col1 ) FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT - 73 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
-47
-60
-63

query I rowsort
SELECT - 52 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 9500afe5646d620d5e8943351a29d082

query I rowsort
SELECT + 65 * 20 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to c08b3e7291b038346127309573216246

query I rowsort
SELECT + tab2.col0 + + tab2.col2 AS col2 FROM tab2
----
104
117
34

query I rowsort
SELECT - col0 + + col2 * + col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT + ( + col0 ) * - cor0.col0 + + 52 FROM tab0 AS cor0
----
-1173
-524
-7869

query I rowsort
SELECT DISTINCT - - ( + col2 ) + cor0.col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL ( 10 ) * tab0.col0 * col1 + - col1 * col0 AS col1 FROM tab0
----
18576
30555
72891

query I rowsort
SELECT DISTINCT - 85 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2138
SELECT ALL + - col0 DIV CAST( + col1 AS SIGNED ) col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2138
SELECT ALL + - col0 / CAST ( + col1 AS INTEGER ) col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + + ( - col1 ) FROM tab0 cor0
----
-172
-182
-194

query I rowsort
SELECT 77 * col0 + ( col2 ) FROM tab1
----
285
4985
6256

query I rowsort
SELECT ALL 28 * - col0 AS col1 FROM tab0
----
-2492
-672
-980

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 - - col2 * col2 col2 FROM tab0
----
-34
1065
6635

query I rowsort
SELECT ALL 92 FROM tab0, tab1 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT ALL - 69 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + - ( col2 ) col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + col1 * + col1 * + col0 AS col1 FROM tab1 AS cor0
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 98 + - col0 col1 FROM tab0 AS cor0
----
63
74
9

query I rowsort
SELECT ALL col2 * col1 + cor0.col1 * col2 FROM tab0 cor0
----
14924
194
5676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2149
SELECT + col1 + - col0 DIV + cor0.col1 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-2149
SELECT + col1 + - col0 / + cor0.col1 FROM tab1 AS cor0
----
26
4
7

query I rowsort
SELECT - ( col0 ) * - col1 + - col2 * col2 FROM tab1
----
-2609
-2838
-8176

query I rowsort
SELECT - col0 + ( tab2.col2 * - col1 ) FROM tab2
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT 60 + col0 + + col2 FROM tab2
----
164
177
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-2153
SELECT + col0 DIV + col2 + - col1 AS col0 FROM tab0
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-2153
SELECT + col0 / + col2 + - col1 AS col0 FROM tab0
----
-62
-86
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2154
SELECT CAST( NULL AS SIGNED ) + + col2 col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2154
SELECT CAST ( NULL AS INTEGER ) + + col2 col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT tab1.col0 FROM tab1 WHERE ( NOT col0 NOT IN ( col1 ) ) AND NOT NULL NOT BETWEEN ( + col2 ) AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2156
SELECT 15 * col2 DIV - col1 + + col1 AS col2 FROM tab1
----
-5
-75
-97

skipif mysql # not compatible
query I rowsort label-2156
SELECT 15 * col2 / - col1 + + col1 AS col2 FROM tab1
----
-5
-75
-97

query I rowsort
SELECT DISTINCT + - 67 FROM tab2 AS cor0
----
-67

query I rowsort
SELECT DISTINCT + - cor0.col2 * - cor0.col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + cor0.col1 * - col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - cor0.col2 * cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col2 * col0 + + col2 AS col2 FROM tab1 cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-2162
SELECT ALL - 89 DIV col0 AS col1 FROM tab2
----
-1
-1
-12

skipif mysql # not compatible
query I rowsort label-2162
SELECT ALL - 89 / col0 AS col1 FROM tab2
----
-1
-1
-12

query I rowsort
SELECT DISTINCT - col1 * col2 + + 83 FROM tab1
----
-1165
-1321
-487

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col0 + + col2 col0 FROM tab2
----
6110
6279
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2165
SELECT + tab0.col2 * CAST( - col0 AS SIGNED ) FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-2165
SELECT + tab0.col2 * CAST ( - col0 AS INTEGER ) FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 * col1 col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT - col2 - 72 AS col2 FROM tab1 AS cor0
----
-126
-129
-168

query I rowsort
SELECT DISTINCT + + col1 + - 92 FROM tab0 AS cor0
----
-1
-6
5

query I rowsort
SELECT ALL col0 + - col0 * 32 FROM tab0
----
-1085
-2759
-744

query I rowsort
SELECT ALL + 28 * col0 + + cor0.col2 * col2 FROM tab2 AS cor0
----
2860
3656
925

query I rowsort
SELECT + col2 * + col1 + + col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - ( + 77 ) FROM tab0
----
-77
-77
-77

query I rowsort
SELECT ALL - 1 + col1 FROM tab0 cor0
----
85
90
96

query I rowsort
SELECT 69 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2175
SELECT - 27 DIV col0 + col1 * + col2 AS col2 FROM tab1 AS cor0
----
1248
1395
570

skipif mysql # not compatible
query I rowsort label-2175
SELECT - 27 / col0 + col1 * + col2 AS col2 FROM tab1 AS cor0
----
1248
1395
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2176
SELECT DISTINCT + CAST( - col0 AS SIGNED ) + col2 * col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

skipif mysql # not compatible
query I rowsort label-2176
SELECT DISTINCT + CAST ( - col0 AS INTEGER ) + col2 * col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - 28 + - 82 FROM tab2 AS cor0
----
-110
-110
-110

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2178
SELECT ALL CAST( NULL AS DECIMAL ) + - cor0.col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2178
SELECT ALL CAST ( NULL AS REAL ) + - cor0.col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2179
SELECT col1 * 23 + col0 * col1 DIV + col2 FROM tab0 AS cor0
----
2040
2191
5626

skipif mysql # not compatible
query I rowsort label-2179
SELECT col1 * 23 + col0 * col1 / + col2 FROM tab0 AS cor0
----
2040
2191
5626

query I rowsort
SELECT DISTINCT - col2 * 53 * - cor0.col2 + col2 * + col0 * col0 FROM tab1 AS cor0
----
1102848
155034
405669

query I rowsort
SELECT + + col0 + - col2 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT - - col2 * - col0 * col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT + + col1 * - cor0.col1 - - col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT - - col0 * col0 + col2 AS col1 FROM tab2 AS cor0
----
6110
6279
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col0 col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - col0 * - col2 + + col0 FROM tab2 AS cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 col2 FROM tab1 WHERE NULL NOT IN ( + col1 )
----

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE + col0 * + col1 NOT IN ( - col0 + - col1 * - col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2189
SELECT col0 DIV + col1 AS col2 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-2189
SELECT col0 / + col1 AS col2 FROM tab2 AS cor0
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2190
SELECT DISTINCT + col2 + - col1 DIV col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2190
SELECT DISTINCT + col2 + - col1 / col2 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + + cor0.col0 * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + + col0 + + col1 - col0 AS col2 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2193
SELECT + - col1 + cor0.col0 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-2193
SELECT + - col1 + cor0.col0 / cor0.col0 AS col1 FROM tab1 AS cor0
----
-12
-25
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2194
SELECT DISTINCT col2 + - col1 DIV col0 + col1 AS col1 FROM tab1
----
109
67
72

skipif mysql # not compatible
query I rowsort label-2194
SELECT DISTINCT col2 + - col1 / col0 + col1 AS col1 FROM tab1
----
109
67
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-2195
SELECT + col1 DIV - col1 + + col1 - cor0.col2 * - col1 AS col2 FROM tab2 AS cor0
----
1592
662
867

skipif mysql # not compatible
query I rowsort label-2195
SELECT + col1 / - col1 + + col1 - cor0.col2 * - col1 AS col2 FROM tab2 AS cor0
----
1592
662
867

onlyif mysql # use DIV operator for integer division
query I rowsort label-2196
SELECT cor0.col0 + - col0 DIV + col0 AS col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-2196
SELECT cor0.col0 + - col0 / + col0 AS col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT ALL + col0 + + tab2.col1 FROM tab2
----
137
38
96

query I rowsort
SELECT col1 * - col0 + 14 FROM tab1 AS cor0
----
-1026
-626
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2199
SELECT + + col2 + CAST( 1 AS SIGNED ) * - col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2199
SELECT + + col2 + CAST ( 1 AS INTEGER ) * - col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2200
SELECT DISTINCT - + col2 + CAST( + 59 * + col2 + + col0 AS SIGNED ) FROM tab1 AS cor0
----
3135
3370
5648

skipif mysql # not compatible
query I rowsort label-2200
SELECT DISTINCT - + col2 + CAST ( + 59 * + col2 + + col0 AS INTEGER ) FROM tab1 AS cor0
----
3135
3370
5648

query I rowsort
SELECT DISTINCT + col1 - + col1 AS col1 FROM tab1
----
0

query I rowsort
SELECT tab2.col1 * + ( - col0 + + col2 ) * - col2 AS col0 FROM tab2
----
-16740
26486
79768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + 11 col0 FROM tab1
----
1056
594
627

query I rowsort
SELECT ALL - col0 * - 6 + - ( col2 ) FROM tab2
----
15
436
442

query I rowsort
SELECT - col1 - + ( 71 * - col0 ) FROM tab0
----
1618
2388
6228

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2206
SELECT DISTINCT col0 / - CAST( NULL AS SIGNED ) + + col0 * tab0.col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2206
SELECT DISTINCT col0 / - CAST ( NULL AS INTEGER ) + + col0 * tab0.col1 FROM tab0
----
NULL

query I rowsort
SELECT - col1 + col1 * col2 FROM tab1
----
1235
1378
560

query I rowsort
SELECT DISTINCT col0 * - tab1.col2 + tab1.col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT + col2 + ( - cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col2 * + 54 * col1 + + cor0.col2 FROM tab2 cor0
----
34922
45225
82862

query I rowsort
SELECT - tab0.col1 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2212
SELECT DISTINCT + CAST( + col0 AS SIGNED ) * + col0 FROM tab1
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-2212
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) * + col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT + cor0.col2 * cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 41d4c126bfd4bfab59ba5e83427c98e0

query I rowsort
SELECT + ( 59 ) AS col2 FROM tab0 AS cor0
----
59
59
59

query I rowsort
SELECT + ( 13 ) FROM tab1 cor0
----
13
13
13

query I rowsort
SELECT - 82 AS col1 FROM tab1 cor0
----
-82
-82
-82

query I rowsort
SELECT 49 * col0 AS col0 FROM tab1
----
147
3136
3920

query I rowsort
SELECT 58 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT - - col2 - col0 AS col1 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT + 58 * col2 + col2 FROM tab0 AS cor0
----
1947
4838
59

query I rowsort
SELECT ALL - ( - col0 ) * - col1 + - col0 * + col1 FROM tab0 cor0
----
-16198
-4128
-6790

query I rowsort
SELECT 59 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
-23
26
58

query I rowsort
SELECT ALL cor0.col2 + col0 * + 91 FROM tab2 AS cor0
----
664
7124
7227

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 13 col0 FROM tab1 AS cor0
----
13

query I rowsort
SELECT - - col0 * col2 + cor0.col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + 70 * col2 * + ( 60 ) FROM tab0
----
138600
344400
4200

query I rowsort
SELECT ALL - + 33 * col1 AS col1 FROM tab0 AS cor0
----
-2838
-3003
-3201

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) col1 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2229
SELECT + col1 * col1 + - tab0.col0 DIV + 13 AS col1 FROM tab0
----
7395
8275
9407

skipif mysql # not compatible
query I rowsort label-2229
SELECT + col1 * col1 + - tab0.col0 / + 13 AS col1 FROM tab0
----
7395
8275
9407

query I rowsort
SELECT DISTINCT - + 11 + - col1 * + cor0.col1 FROM tab1 AS cor0
----
-111
-180
-687

query I rowsort
SELECT DISTINCT + + col2 - cor0.col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + col0 - + col2 * col2 FROM tab2 AS cor0
----
-1365
-598
-722

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2233
SELECT ALL + col2 + col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2233
SELECT ALL + col2 + col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + 89 AS col2 FROM tab0 cor0
----
89
89
89

query I rowsort
SELECT DISTINCT col1 + - col1 * col0 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - col2 * col1 + ( - cor0.col0 ) FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT - - col2 * ( 83 ) - + col0 * - col0 * - col2 AS col2 FROM tab1 AS cor0
----
-228741
-606432
3996

query I rowsort
SELECT ALL - + col2 + + col0 AS col1 FROM tab2 cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2239
SELECT DISTINCT - + col2 * col2 + - col1 DIV col0 - + col2 * col1 col2 FROM tab2 AS cor0
----
-1570
-2090
-2210

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2239
SELECT DISTINCT - + col2 * col2 + - col1 / col0 - + col2 * col1 col2 FROM tab2 AS cor0
----
-1570
-2090
-2210

query I rowsort
SELECT - + col2 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col1 * 25 AS col0 FROM tab0 AS cor0
----
2150
2275
2425

query I rowsort
SELECT + cor0.col0 * + ( - 32 ) + col2 AS col0 FROM tab2 AS cor0
----
-197
-2470
-2490

query I rowsort
SELECT DISTINCT + + col1 * + ( col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - 27 + - col1 * + 12 FROM tab0
----
-1059
-1119
-1191

query I rowsort
SELECT ALL 76 * tab2.col0 FROM tab2
----
532
5928
6004

query I rowsort
SELECT DISTINCT + col0 + + ( ( col0 ) ) FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - col2 * - ( cor0.col0 ) - col2 FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT ALL - tab0.col2 * tab0.col2 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 8c9123b78bd6939e7be59da36c5c5c77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col0 ) + col0 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + - ( col1 ) FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT ALL ( col1 ) * - col0 * col0 FROM tab2 cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL - 9 * ( + col0 ) + col1 FROM tab1 AS cor0
----
-1
-566
-707

query I rowsort
SELECT + 56 + - 73 AS col0 FROM tab1 AS cor0
----
-17
-17
-17

query I rowsort
SELECT cor0.col0 + + col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL - - col1 * + ( - cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + - ( + col2 ) * + col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL col1 * col1 AS col0 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT - ( col0 ) * + cor0.col0 + col1 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2259
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - col1 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2259
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - col1 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL 97 + cor0.col0 AS col2 FROM tab0 AS cor0
----
121
132
186

query I rowsort
SELECT ALL + - col1 * - ( col2 * + 26 ) FROM tab2 AS cor0
----
16796
21762
39884

query I rowsort
SELECT - col2 * cor0.col1 * 62 AS col2 FROM tab2 AS cor0
----
-40052
-51894
-95108

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0 CROSS JOIN tab2, tab0 AS cor1
----
972 values hashing to 95de14c88adc44eda4adb5267fe9ebd1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 95 + cor0.col2 col1 FROM tab1 AS cor0
----
-38
-41
1

query I rowsort
SELECT ALL ( + ( - col0 - 94 ) ) + col0 * col2 + 5 FROM tab0 AS cor0
----
-89
679
7120

query I rowsort
SELECT ALL 2 * col1 + col1 AS col0 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT DISTINCT - - col0 + col2 * col1 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT col2 + 99 AS col0 FROM tab0 AS cor0
----
100
132
181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + tab2.col0 ) * + col1 * col0 col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT - + 99 * - 4 FROM tab1 AS cor0
----
396

query I rowsort
SELECT ALL + - ( + col0 ) * col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2272
SELECT DISTINCT - CAST( col0 AS SIGNED ) * col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-2272
SELECT DISTINCT - CAST ( col0 AS INTEGER ) * col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + 45 + - col0 FROM tab0 AS cor0
----
-44
10
21

query I rowsort
SELECT DISTINCT col0 + - col0 AS col0 FROM tab1 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2275
SELECT - 22 - col2 DIV + col1 FROM tab2 AS cor0
----
-22
-22
-24

skipif mysql # not compatible
query I rowsort label-2275
SELECT - 22 - col2 / + col1 FROM tab2 AS cor0
----
-22
-22
-24

query I rowsort
SELECT DISTINCT - col2 * ( ( col1 ) ) + col0 * col2 FROM tab0
----
-164
-2046
-62

query I rowsort
SELECT - cor0.col2 * ( - col2 ) AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT 61 + col1 FROM tab0
----
147
152
158

query I rowsort
SELECT 64 + 62 FROM tab0
----
126
126
126

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2280
SELECT DISTINCT + col2 * + CAST( col1 AS SIGNED ) * col2 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
611802
93621
96

skipif mysql # not compatible
query I rowsort label-2280
SELECT DISTINCT + col2 * + CAST ( col1 AS INTEGER ) * col2 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
611802
93621
96

query I rowsort
SELECT DISTINCT - col0 * 82 FROM tab1 AS cor0
----
-246
-5248
-6560

query I rowsort
SELECT col0 * + col2 + col0 AS col0 FROM tab0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2283
SELECT tab1.col0 DIV cor0.col1 + - 76 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

skipif mysql # not compatible
query I rowsort label-2283
SELECT tab1.col0 / cor0.col1 + - 76 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT + tab0.col1 * + 59 AS col0 FROM tab0
----
5074
5369
5723

query I rowsort
SELECT DISTINCT col1 * col2 + + col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL - col1 + - col0 + col0 * col2 AS col1 FROM tab0
----
-97
682
7118

query I rowsort
SELECT col1 * 95 FROM tab0
----
8170
8645
9215

query I rowsort
SELECT - col1 * - ( 11 ) + tab0.col0 AS col2 FROM tab0
----
1090
1102
970

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col2 + col0 * - col1 col2 FROM tab1
----
-1210
-1482
-2288

query I rowsort
SELECT DISTINCT tab2.col0 * + tab2.col0 + + col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT - col0 + ( - col2 ) FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT ALL - - cor0.col2 + 81 * 60 AS col1 FROM tab2 AS cor0
----
4886
4887
4898

query I rowsort
SELECT DISTINCT - col0 + - col0 + col2 FROM tab1 AS cor0
----
-64
-71
48

query I rowsort
SELECT col0 * + col0 * ( - tab1.col1 * ( + tab1.col2 ) ) FROM tab1
----
-12636
-2334720
-7987200

query I rowsort
SELECT + 0 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + - cor0.col0 + col0 * col1 AS col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT cor0.col1 * - 65 AS col0 FROM tab1 AS cor0
----
-1690
-650
-845

query I rowsort
SELECT + col2 - + ( cor0.col2 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * 23 + col0 AS col2 FROM tab0 AS cor0
----
-1797
-735
12

query I rowsort
SELECT ALL col0 + + 60 AS col2 FROM tab0
----
149
84
95

query I rowsort
SELECT DISTINCT col2 - col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - - col1 * col2 - + col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ALL + + col0 * 83 FROM tab0 cor0
----
1992
2905
7387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + 97 col0 FROM tab0
----
-15
-64
-96

query I rowsort
SELECT + + col2 + + ( cor0.col0 ) AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + col2 + - col2 * col1 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT - - 63 * + col0 + + col0 FROM tab0 AS cor0
----
1536
2240
5696

query I rowsort
SELECT + ( cor0.col1 ) * + col2 + - ( col2 ) FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL + 57 * - col0 - 99 FROM tab2 AS cor0
----
-4545
-4602
-498

query I rowsort
SELECT DISTINCT tab0.col2 AS col2 FROM tab0, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + col2 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT - - col1 + col2 * col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT col0 * - cor0.col0 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT ALL + - cor0.col1 + col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT ALL - 63 * col2 FROM tab1 AS cor0
----
-3402
-3591
-6048

query I rowsort
SELECT - cor0.col2 * - 10 FROM tab2 AS cor0
----
260
270
380

query I rowsort
SELECT + - cor0.col0 * + ( - cor0.col2 ) AS col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2318
SELECT ALL - col1 DIV 15 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2318
SELECT ALL - col1 / 15 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + col1 * - col0 * cor0.col1 col2 FROM tab2 AS cor0
----
-22752
-271440
-6720

query I rowsort
SELECT - col0 * - 48 AS col1 FROM tab0 AS cor0
----
1152
1680
4272

query I rowsort
SELECT ALL - 84 FROM tab1
----
-84
-84
-84

query I rowsort
SELECT 95 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

onlyif mysql # use DIV operator for integer division
query I rowsort label-2323
SELECT + 13 DIV col2 AS col2 FROM tab0 AS cor0
----
0
0
13

skipif mysql # not compatible
query I rowsort label-2323
SELECT + 13 / col2 AS col2 FROM tab0 AS cor0
----
0
0
13

query I rowsort
SELECT ALL + col0 * col0 * + col1 + - col1 FROM tab2
----
106080
1488
358897

onlyif mysql # use DIV operator for integer division
query I rowsort label-2325
SELECT - tab0.col2 - - col2 DIV col2 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-2325
SELECT - tab0.col2 - - col2 / col2 FROM tab0
----
-32
-81
0

query I rowsort
SELECT DISTINCT + col2 * col1 + col2 FROM tab2
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2327
SELECT ALL - col1 + + tab2.col0 * CAST( NULL AS SIGNED ) - + 81 * col1 * - tab2.col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2327
SELECT ALL - col1 + + tab2.col0 * CAST ( NULL AS INTEGER ) - + 81 * col1 * - tab2.col2 AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2328
SELECT ALL + 31 DIV + col0 - - col0 FROM tab2
----
11
78
79

skipif mysql # not compatible
query I rowsort label-2328
SELECT ALL + 31 / + col0 - - col0 FROM tab2
----
11
78
79

query I rowsort
SELECT 83 * - col2 FROM tab2
----
-2158
-2241
-3154

onlyif mysql # use DIV operator for integer division
query I rowsort label-2330
SELECT + 58 DIV - col1 FROM tab1
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-2330
SELECT + 58 / - col1 FROM tab1
----
-2
-4
-5

query I rowsort
SELECT cor0.col1 * + col0 + - 24 AS col1 FROM tab1 AS cor0
----
1016
54
616

query I rowsort
SELECT ALL - 11 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

onlyif mysql # use DIV operator for integer division
query I rowsort label-2333
SELECT ALL + tab1.col0 + col1 * col1 - + col2 DIV + tab1.col1 AS col2 FROM tab1
----
159
242
677

skipif mysql # not compatible
query I rowsort label-2333
SELECT ALL + tab1.col0 + col1 * col1 - + col2 / + tab1.col1 AS col2 FROM tab1
----
159
242
677

onlyif mysql # use DIV operator for integer division
query I rowsort label-2334
SELECT DISTINCT col0 DIV col1 + tab0.col2 col2 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2334
SELECT DISTINCT col0 / col1 + tab0.col2 col2 FROM tab0
----
1
33
82

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL < NULL
----

query III rowsort
SELECT * FROM tab2 WHERE col2 IN ( - col1 / tab2.col0 )
----

query I rowsort
SELECT DISTINCT col0 * col2 * col1 + - col0 AS col1 FROM tab0
----
3360
664029
68088

onlyif mysql # use DIV operator for integer division
query I rowsort label-2338
SELECT DISTINCT col0 DIV col0 - + col2 * + col0 AS col1 FROM tab2
----
-188
-2027
-3001

skipif mysql # not compatible
query I rowsort label-2338
SELECT DISTINCT col0 / col0 - + col2 * + col0 AS col1 FROM tab2
----
-188
-2027
-3001

query I rowsort
SELECT col1 * col1 + + tab1.col1 AS col1 FROM tab1
----
110
182
702

query I rowsort
SELECT - col2 * - col2 + col0 AS col0 FROM tab2
----
1523
736
754

query I rowsort
SELECT DISTINCT - col2 * + tab2.col1 + col1 AS col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT - tab1.col0 * col1 + col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT - col1 * tab2.col1 + col0 FROM tab2 WHERE ( - col0 ) IN ( - col0 * tab2.col0 + - col1 )
----

query I rowsort
SELECT ALL + col0 AS col1 FROM tab2 WHERE NOT ( NULL ) NOT IN ( col0 )
----

query I rowsort
SELECT col0 + tab0.col1 * col2 * col1 FROM tab0
----
244092
679131
9444

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( NULL ) IN ( - col2 )
----

query I rowsort
SELECT - col1 * col2 + - col2 + col1 AS col2 FROM tab2
----
-1501
-667
-833

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col2 + col2 col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL col1 FROM tab0 WHERE NOT NULL NOT IN ( + col0 * - col0 )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL <> + col1
----

query I rowsort
SELECT tab1.col2 * col2 AS col2 FROM tab1
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col0 * - col2 + tab1.col2 * - col0 * col1 col0 FROM tab1
----
-269952
-4698
-714240

query I rowsort
SELECT DISTINCT - tab1.col2 * - col2 + col2 AS col1 FROM tab1
----
2970
3306
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 col1 FROM tab2 WHERE tab2.col1 IN ( + col1 * col1 )
----

query I rowsort
SELECT + tab2.col1 * - col1 AS col1 FROM tab2
----
-289
-3481
-961

query III rowsort
SELECT * FROM tab2 WHERE + col0 * col1 / + col0 IN ( col0 * col1 )
----

query I rowsort
SELECT DISTINCT + col1 * col0 + + col1 * col0 AS col1 FROM tab1
----
1280
156
2080

query I rowsort
SELECT DISTINCT - tab0.col1 * + col2 + col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT - col1 / - col1 + - col1 * - tab1.col0 AS col1 FROM tab1 WHERE NOT ( col1 ) BETWEEN ( NULL ) AND ( col2 + + col1 )
----

query I rowsort
SELECT ALL + col2 FROM tab2 WHERE ( NULL ) NOT IN ( col2 )
----

query I rowsort
SELECT ALL - col2 * ( tab1.col2 ) * - tab1.col1 AS col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT + tab2.col2 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT + ( + 85 + tab0.col1 ) AS col1 FROM tab0
----
171
176
182

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2364
SELECT - CAST( + col1 AS SIGNED ) - + col1 * col2 AS col0 FROM tab2
----
-1593
-663
-868

skipif mysql # not compatible
query I rowsort label-2364
SELECT - CAST ( + col1 AS INTEGER ) - + col1 * col2 AS col0 FROM tab2
----
-1593
-663
-868

query I rowsort
SELECT ALL 26 * 86 FROM tab1
----
2236
2236
2236

query I rowsort
SELECT - ( col2 * - col0 ) - 73 FROM tab2
----
116
1955
2929

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 79 * col1 + + col0 * - ( + col0 * + col1 ) col2 FROM tab1
----
-40170
-82173
1820

query I rowsort
SELECT DISTINCT - cor0.col2 * - 33 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
1089
2706
33

query I rowsort
SELECT + + 77 AS col1 FROM tab0 AS cor0
----
77
77
77

query I rowsort
SELECT col2 * col1 + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + ( + col0 ) * + col2 AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + 67 + + tab0.col1 * col0 AS col1 FROM tab0
----
2131
3462
8166

query I rowsort
SELECT DISTINCT col2 * - col1 + + cor0.col1 * ( - cor0.col1 ) FROM tab1 AS cor0
----
-1417
-2080
-670

query I rowsort
SELECT ALL - col2 * + col0 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT + 21 * - col2 AS col2 FROM tab1 AS cor0
----
-1134
-1197
-2016

query I rowsort
SELECT DISTINCT + col0 * col1 * 29 FROM tab0 AS cor0
----
234871
59856
98455

query I rowsort
SELECT ALL + col1 + col0 * col2 AS col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL 26 + col1 FROM tab0 cor0
----
112
117
123

query I rowsort
SELECT DISTINCT col1 * - col2 + col2 - - 87 * + col1 AS col1 FROM tab0 cor0
----
4677
537
8343

query I rowsort
SELECT + 58 * - col0 AS col1 FROM tab2 cor0
----
-406
-4524
-4582

query I rowsort
SELECT DISTINCT - col2 + + cor0.col1 * + ( col2 * - col2 ) + col2 AS col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL - + 43 FROM tab2 AS cor0
----
-43
-43
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 91 + cor0.col2 col2 FROM tab2 AS cor0
----
117
118
129

query I rowsort
SELECT ALL - col2 * col0 + col2 + - col1 AS col0 FROM tab0 AS cor0
----
-131
-7307
-845

query I rowsort
SELECT - ( col2 ) AS col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + 94 + col1 AS col0 FROM tab0 AS cor0
----
180
185
191

query I rowsort
SELECT ALL - ( - col1 ) * + 43 + - 80 AS col2 FROM tab2 AS cor0
----
1253
2457
651

query I rowsort
SELECT DISTINCT ( - 21 ) FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2
----
-21

query I rowsort
SELECT col1 * - 13 + + ( col1 ) FROM tab1 cor0
----
-120
-156
-312

query I rowsort
SELECT - col2 * + col0 + + cor0.col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL col1 * - col1 + + col0 * - tab0.col0 AS col0 FROM tab0
----
-10634
-16202
-7972

query I rowsort
SELECT ALL + 68 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT DISTINCT - col1 * 40 FROM tab2 AS cor0
----
-1240
-2360
-680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2394
SELECT + + cor0.col0 DIV ( cor0.col1 ) + + col0 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-2394
SELECT + + cor0.col0 / ( cor0.col1 ) + + col0 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT - col2 + - col0 + col0 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + col1 * + ( col2 ) AS col0 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2397
SELECT DISTINCT col0 * - CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2397
SELECT DISTINCT col0 * - CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col2 * - ( col2 ) * - col1 + + col1 AS col1 FROM tab1 AS cor0
----
119821
32500
75842

onlyif mysql # use DIV operator for integer division
query I rowsort label-2399
SELECT DISTINCT - + col2 + - 74 DIV + 78 col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2399
SELECT DISTINCT - + col2 + - 74 / + 78 col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - - col2 + + 33 AS col0 FROM tab1 AS cor0
----
129
87
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2402
SELECT ALL - col2 DIV + 85 AS col2 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2402
SELECT ALL - col2 / + 85 AS col2 FROM tab1 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2403
SELECT col1 * - col0 - 91 * col2 DIV - col1 FROM tab2 AS cor0
----
-1140
-138
-4562

skipif mysql # not compatible
query I rowsort label-2403
SELECT col1 * - col0 - 91 * col2 / - col1 FROM tab2 AS cor0
----
-1140
-138
-4562

query I rowsort
SELECT DISTINCT - ( + 54 ) FROM tab0 cor0
----
-54

query I rowsort
SELECT 13 * - col2 + col0 * col2 + - 4 AS col0 FROM tab1 AS cor0
----
-544
2903
6428

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2406
SELECT DISTINCT + CAST( + col2 AS SIGNED ) * col1 * + cor0.col1 FROM tab2 AS cor0
----
10982
25947
90506

skipif mysql # not compatible
query I rowsort label-2406
SELECT DISTINCT + CAST ( + col2 AS INTEGER ) * col1 * + cor0.col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT - 43 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

query I rowsort
SELECT DISTINCT col2 * + tab1.col2 + col1 * col0 FROM tab1
----
10256
2994
3889

query I rowsort
SELECT - 22 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab0 cor2
----
81 values hashing to a0e2414933a8871692e3623f463e9d4b

query I rowsort
SELECT DISTINCT + col0 + - col0 AS col2 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2411
SELECT ALL - 58 + + col2 DIV 43 col0 FROM tab0
----
-57
-58
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2411
SELECT ALL - 58 + + col2 / 43 col0 FROM tab0
----
-57
-58
-58

query I rowsort
SELECT - 78 AS col2 FROM tab1, tab0, tab0 cor0
----
27 values hashing to c4f3c63f98c3c08f2848f46850a476d4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col1 col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT col1 + col0 * ( col0 ) * col2 FROM tab0
----
1322
19094
649613

query I rowsort
SELECT - tab0.col1 * - col0 * + col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT - + 8 + col2 FROM tab0 AS cor0
----
-7
25
74

query I rowsort
SELECT + 17 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT - col2 + - 6 * ( col1 ) * 32 FROM tab1 AS cor0
----
-1977
-2592
-5046

query I rowsort
SELECT - + col0 * 5 + 45 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-1185
-770
-985

query I rowsort
SELECT col0 * + col2 + col2 AS col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT col0 + - 90 AS col0 FROM tab2 cor0
----
-11
-12
-83

query I rowsort
SELECT DISTINCT + col1 - ( + cor0.col1 + col2 ) * cor0.col1 FROM tab0 AS cor0
----
-10148
-15652
-9409

query I rowsort
SELECT col0 * + cor0.col0 + + 29 FROM tab1 cor0
----
38
4125
6429

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2424
SELECT + - col2 - - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2424
SELECT + - col2 - - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + 12 col2 FROM tab1 AS cor0
----
22
25
38

query I rowsort
SELECT DISTINCT + col1 + - 16 + col0 FROM tab1 AS cor0
----
13
58
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-2427
SELECT ALL + - cor0.col2 + 3 DIV - ( col2 ) FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2427
SELECT ALL + - cor0.col2 + 3 / - ( col2 ) FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2428
SELECT + col0 + CAST( - ( col0 ) AS SIGNED ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2428
SELECT + col0 + CAST ( - ( col0 ) AS INTEGER ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col2 + col2 * col2 AS col1 FROM tab0
----
1122
2
6806

query I rowsort
SELECT + - col1 + col2 * col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT - ( 91 ) + - col1 * - col1 AS col0 FROM tab2 AS cor0
----
198
3390
870

onlyif mysql # use DIV operator for integer division
query I rowsort label-2432
SELECT + 88 DIV col1 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2432
SELECT + 88 / col1 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 73 col0 FROM tab0 AS cor0
----
-73
-73
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2434
SELECT DISTINCT + CAST( 29 AS SIGNED ) FROM tab1 AS cor0
----
29

skipif mysql # not compatible
query I rowsort label-2434
SELECT DISTINCT + CAST ( 29 AS INTEGER ) FROM tab1 AS cor0
----
29

query I rowsort
SELECT ALL + + ( col2 ) + col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - 41 * + col2 * col1 FROM tab2 AS cor0
----
-26486
-34317
-62894

query I rowsort
SELECT + 75 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-525
-5850
-5925

query I rowsort
SELECT + col1 * 39 FROM tab2 AS cor0
----
1209
2301
663

query I rowsort
SELECT DISTINCT col1 * - 23 + + col2 FROM tab0 AS cor0
----
-1945
-2011
-2230

query I rowsort
SELECT DISTINCT + col2 + - col2 * - col0 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT col2 * + cor0.col1 + - col1 AS col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT - + cor0.col2 * - cor0.col1 FROM tab2 cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 17 + ( cor0.col2 ) * 62 col2 FROM tab0 AS cor0
----
2029
45
5067

onlyif mysql # use DIV operator for integer division
query I rowsort label-2444
SELECT DISTINCT + + 44 DIV cor0.col0 FROM tab2 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-2444
SELECT DISTINCT + + 44 / cor0.col0 FROM tab2 AS cor0
----
0
6

query I rowsort
SELECT + - cor0.col2 * col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2446
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + col1 AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2446
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + col1 AS col2 FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2447
SELECT tab0.col0 DIV + tab0.col1 + col0 col2 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2447
SELECT tab0.col0 / + tab0.col1 + col0 col2 FROM tab0
----
24
35
89

query I rowsort
SELECT 31 + + col1 * col1 FROM tab2 AS cor0
----
320
3512
992

query I rowsort
SELECT DISTINCT + cor0.col0 AS col1 FROM tab0, tab2, tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL 17 * col0 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT - - 38 + cor0.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 0d5111297ba0ed20c68997c9e30d4278

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2452
SELECT ALL cor0.col2 * - CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2452
SELECT ALL cor0.col2 * - CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 50 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-50

query I rowsort
SELECT - - 62 + - col1 * - col1 FROM tab2 AS cor0
----
1023
351
3543

query I rowsort
SELECT cor0.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + 73 * cor1.col2 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e0fec770aa9cc04ce43c9852e8b1c021

query I rowsort
SELECT - ( - ( + col2 ) ) * + 32 AS col2 FROM tab1
----
1728
1824
3072

query I rowsort
SELECT ALL + ( - col1 + col0 ) * col2 FROM tab2
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-2459
SELECT ALL ( 78 ) DIV - col0 FROM tab2
----
-1
-11
0

skipif mysql # not compatible
query I rowsort label-2459
SELECT ALL ( 78 ) / - col0 FROM tab2
----
-1
-11
0

query I rowsort
SELECT + 92 + col1 * - col0 AS col0 FROM tab1 cor0
----
-548
-948
14

query I rowsort
SELECT col1 + col1 AS col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT ALL 64 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT ALL + 27 * + cor0.col2 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to ff6162e0ec52b9f9437b6969c2ae51dc

query I rowsort
SELECT DISTINCT - col2 - 70 FROM tab0 cor0
----
-103
-152
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-2465
SELECT DISTINCT col1 * col1 DIV col0 FROM tab0 AS cor0
----
268
308
93

skipif mysql # not compatible
query I rowsort label-2465
SELECT DISTINCT col1 * col1 / col0 FROM tab0 AS cor0
----
268
308
93

query I rowsort
SELECT ALL + col1 * ( 76 ) + - col1 AS col0 FROM tab0 AS cor0
----
6450
6825
7275

query I rowsort
SELECT col0 * - 45 + - col2 FROM tab0 AS cor0
----
-1113
-1576
-4087

query I rowsort
SELECT DISTINCT + col1 - col1 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + col0 * cor0.col0 + + cor0.col2 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2470
SELECT ALL - CAST( cor0.col1 AS SIGNED ) - col2 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-2470
SELECT ALL - CAST ( cor0.col1 AS INTEGER ) - col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT - + 58 * + col2 * col1 + col2 FROM tab1 AS cor0
----
-33003
-72288
-81378

query I rowsort
SELECT + - ( + col2 ) * - col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT col1 * + 10 AS col0 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT ALL col2 + - 23 * - col0 AS col0 FROM tab1 AS cor0
----
123
1529
1936

query I rowsort
SELECT ALL + 21 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT - ( 66 ) * + col2 FROM tab1 AS cor0
----
-3564
-3762
-6336

query I rowsort
SELECT DISTINCT - ( + cor0.col0 ) AS col2 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT - col1 * - cor0.col2 + 84 AS col1 FROM tab0 cor0
----
181
2922
7546

query I rowsort
SELECT + - cor0.col1 FROM tab0, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT DISTINCT col2 + + col2 + + ( 97 ) * col0 AS col1 FROM tab0
----
2394
3397
8797

query I rowsort
SELECT - - 81 FROM tab1, tab2 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT cor0.col2 + col2 + - ( 23 ) FROM tab2 AS cor0
----
29
31
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-2483
SELECT ALL col0 DIV cor0.col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2483
SELECT ALL col0 / cor0.col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ALL - - 68 FROM tab1 AS cor0
----
68
68
68

query I rowsort
SELECT + - 64 + + col0 FROM tab0 AS cor0
----
-29
-40
25

query I rowsort
SELECT - col0 * col0 * + 75 AS col2 FROM tab2
----
-3675
-456300
-468075

query I rowsort
SELECT col2 * tab0.col1 + - col0 * ( + col1 ) AS col2 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT ALL col0 + col2 * + 45 AS col2 FROM tab1
----
2433
2629
4400

query I rowsort
SELECT DISTINCT - 47 + - col1 FROM tab2
----
-106
-64
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2490
SELECT ALL + ( - tab0.col1 ) * col2 * - tab0.col1 + - col1 DIV - 29 col0 FROM tab0
----
244070
679045
9412

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2490
SELECT ALL + ( - tab0.col1 ) * col2 * - tab0.col1 + - col1 / - 29 col0 FROM tab0
----
244070
679045
9412

query I rowsort
SELECT ALL - - col0 + + ( + 48 * col0 ) AS col2 FROM tab2 AS cor0
----
343
3822
3871

query I rowsort
SELECT ALL cor0.col2 + - cor0.col2 + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + - cor0.col0 + + col1 + - cor0.col2 FROM tab1 cor0
----
-111
-163
-31

query I rowsort
SELECT - + col0 + - ( - cor0.col1 ) * - col0 + col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col2 + - col2 * col1 + col1 AS col1 FROM tab1 AS cor0
----
-1139
-1324
-503

query I rowsort
SELECT + tab2.col0 + + tab2.col2 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL col0 * + tab1.col1 + - ( + col0 ) * - col2 FROM tab1
----
240
4288
8720

query I rowsort
SELECT col1 * col1 * + col2 + + col1 FROM tab1 AS cor0
----
16237
36530
5710

query I rowsort
SELECT DISTINCT - col2 + col1 + col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - 81 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-81

query I rowsort
SELECT ALL + + cor0.col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT col2 * 82 AS col0 FROM tab0
----
2706
6724
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2503
SELECT ALL - col2 DIV 17 FROM tab1
----
-3
-3
-5

skipif mysql # not compatible
query I rowsort label-2503
SELECT ALL - col2 / 17 FROM tab1
----
-3
-3
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + 41 col2 FROM tab2
----
100
58
72

query I rowsort
SELECT col2 + + 41 FROM tab1
----
137
95
98

query I rowsort
SELECT DISTINCT col2 * - 85 AS col0 FROM tab1
----
-4590
-4845
-8160

query I rowsort
SELECT + - tab0.col0 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT ALL - 52 AS col2 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to e8a5cb10c0973a78554f344d4f6e7e74

query I rowsort
SELECT ALL tab0.col2 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + 75 * col1 - - 80 FROM tab2 AS cor0
----
1355
2405
4505

query I rowsort
SELECT DISTINCT 5 + col0 * + col1 + - col0 FROM tab1 AS cor0
----
581
80
965

query I rowsort
SELECT DISTINCT - + cor0.col0 * col1 + 54 AS col1 FROM tab1 AS cor0
----
-24
-586
-986

query I rowsort
SELECT DISTINCT col1 * col2 + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT col1 + col0 * col0 AS col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL 79 AS col0 FROM tab2 cor0
----
79
79
79

query I rowsort
SELECT + 30 FROM tab0, tab2 AS cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT ALL + col2 * - ( col0 ) AS col2 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - tab0.col2 * + col2 ) col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT + col1 + + 80 FROM tab0
----
166
171
177

query I rowsort
SELECT ALL col1 + col1 * - col2 * ( col1 ) AS col0 FROM tab1 AS cor0
----
-16211
-36478
-5690

query I rowsort
SELECT + ( + cor0.col2 ) - col1 AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL col2 + - tab2.col2 AS col0 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2524
SELECT DISTINCT 29 DIV + col1 + - 28 FROM tab0 AS cor0
----
-28

skipif mysql # not compatible
query I rowsort label-2524
SELECT DISTINCT 29 / + col1 + - 28 FROM tab0 AS cor0
----
-28

query I rowsort
SELECT ALL - col1 * col0 + 28 AS col1 FROM tab1 AS cor0
----
-1012
-50
-612

query I rowsort
SELECT + + col0 * col2 - + col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2527
SELECT DISTINCT + + ( + col0 ) + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2527
SELECT DISTINCT + + ( + col0 ) + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * - col0 + - col0 AS col1 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT cor0.col1 * col1 + + col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL + 32 + col1 AS col2 FROM tab1 AS cor0
----
42
45
58

query I rowsort
SELECT ALL cor0.col1 + + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + 71 FROM tab1 AS cor0
----
71

query I rowsort
SELECT - col0 * + col2 - 34 FROM tab1 AS cor0
----
-196
-3682
-7714

query I rowsort
SELECT + ( ( + col2 ) ) AS col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT - - ( - col2 ) * - col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT - + 56 * + col1 AS col1 FROM tab0 AS cor0
----
-4816
-5096
-5432

query I rowsort
SELECT ALL - col2 + col2 * col0 AS col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL - col1 + col2 * col2 AS col1 FROM tab2 AS cor0
----
1427
617
698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 99 col1 FROM tab0 AS cor0
----
99
99
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2540
SELECT + 95 * - col2 DIV col2 FROM tab1 AS cor0
----
-95
-95
-95

skipif mysql # not compatible
query I rowsort label-2540
SELECT + 95 * - col2 / col2 FROM tab1 AS cor0
----
-95
-95
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col0 + 2 col1 FROM tab0, tab1 AS cor0
----
-22
-33
-87

query I rowsort
SELECT DISTINCT - + col0 - + col0 AS col2 FROM tab2 AS cor0
----
-14
-156
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-2543
SELECT - col1 + + col0 DIV - col0 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-2543
SELECT - col1 + + col0 / - col0 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT ALL + - 93 + col2 * ( + col1 ) FROM tab2 AS cor0
----
1441
553
744

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2545
SELECT ALL cor0.col0 + - col1 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2545
SELECT ALL cor0.col0 + - col1 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2546
SELECT DISTINCT - col0 DIV cor0.col0 col1 FROM tab0 cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2546
SELECT DISTINCT - col0 / cor0.col0 col1 FROM tab0 cor0
----
-1

query I rowsort
SELECT ALL - + 71 AS col2 FROM tab1 AS cor0
----
-71
-71
-71

query I rowsort
SELECT - col2 + + cor0.col1 + col0 AS col0 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT ALL + + 20 + - col2 AS col2 FROM tab1 AS cor0
----
-34
-37
-76

query I rowsort
SELECT ALL - ( col0 ) * 83 + col1 + col0 AS col0 FROM tab2 AS cor0
----
-543
-6337
-6461

onlyif mysql # use DIV operator for integer division
query I rowsort label-2551
SELECT DISTINCT 83 DIV cor0.col1 - 24 FROM tab2 AS cor0
----
-20
-22
-23

skipif mysql # not compatible
query I rowsort label-2551
SELECT DISTINCT 83 / cor0.col1 - 24 FROM tab2 AS cor0
----
-20
-22
-23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col2 col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - col0 + - col2 col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT - - ( + col2 ) FROM tab2 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2555
SELECT ALL col1 DIV 83 AS col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2555
SELECT ALL col1 / 83 AS col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT col1 * + col2 + 60 * col2 AS col1 FROM tab1 AS cor0
----
3990
4644
7008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2557
SELECT - col2 + CAST( NULL AS SIGNED ) * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2557
SELECT - col2 + CAST ( NULL AS INTEGER ) * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 - col0 * - col1 AS col2 FROM tab0 cor0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-2559
SELECT DISTINCT + + col1 DIV ( col1 * col0 + - col1 ) AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2559
SELECT DISTINCT + + col1 / ( col1 * col0 + - col1 ) AS col2 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - ( - col2 ) * col1 col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + - col2 * 82 AS col0 FROM tab2 AS cor0
----
-2132
-2214
-3116

onlyif mysql # use DIV operator for integer division
query I rowsort label-2562
SELECT - col2 DIV - 46 + cor0.col0 + col0 AS col1 FROM tab0 AS cor0
----
179
48
70

skipif mysql # not compatible
query I rowsort label-2562
SELECT - col2 / - 46 + cor0.col0 + col0 AS col1 FROM tab0 AS cor0
----
179
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2563
SELECT + CAST( - 31 AS SIGNED ) FROM tab1, tab0 cor0
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

skipif mysql # not compatible
query I rowsort label-2563
SELECT + CAST ( - 31 AS INTEGER ) FROM tab1, tab0 cor0
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

query I rowsort
SELECT 85 * + 53 + cor0.col1 FROM tab2, tab1 AS cor0, tab1, tab0 cor1
----
81 values hashing to 8f8cd183852cd1e9e4593a59a9dbf2e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2565
SELECT + col0 DIV - 51 + col0 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-2565
SELECT + col0 / - 51 + col0 FROM tab2 AS cor0
----
7
77
78

query I rowsort
SELECT + - col0 + - 8 * 59 + - col1 FROM tab2 AS cor0
----
-510
-568
-609

onlyif mysql # use DIV operator for integer division
query I rowsort label-2567
SELECT + + col2 + - 78 DIV + col0 + - col0 FROM tab1 AS cor0
----
-8
16
25

skipif mysql # not compatible
query I rowsort label-2567
SELECT + + col2 + - 78 / + col0 + - col0 FROM tab1 AS cor0
----
-8
16
25

query I rowsort
SELECT + + col2 + + col1 + + col0 AS col0 FROM tab2 cor0
----
134
163
65

query I rowsort
SELECT - - ( - col2 ) * - col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col2 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + ( - ( + col2 ) ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2572
SELECT ALL CAST( NULL AS SIGNED ) * + 49 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2572
SELECT ALL CAST ( NULL AS INTEGER ) * + 49 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * col1 * + col1 FROM tab2 AS cor0
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 33 * 80 col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to e1fff407ed148842eb68c8355a7658c4

query I rowsort
SELECT DISTINCT ( 5 ) AS col0 FROM tab2, tab2 AS cor0
----
5

query I rowsort
SELECT + col1 - col1 * - cor0.col2 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-2577
SELECT + cor0.col2 DIV - col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-2577
SELECT + cor0.col2 / - col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2578
SELECT 21 + + col1 DIV - 66 FROM tab2 AS cor0
----
21
21
21

skipif mysql # not compatible
query I rowsort label-2578
SELECT 21 + + col1 / - 66 FROM tab2 AS cor0
----
21
21
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-2579
SELECT ALL 39 + col1 + - col2 DIV col0 FROM tab0
----
124
130
136

skipif mysql # not compatible
query I rowsort label-2579
SELECT ALL 39 + col1 + - col2 / col0 FROM tab0
----
124
130
136

query I rowsort
SELECT 6 * col2 + col1 AS col1 FROM tab0 AS cor0
----
103
284
583

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col1 AS REAL ) * + col1 + ( + 64 ) + col2 * + col0 FROM tab1
----
3812
7913
902

query I rowsort
SELECT - tab1.col2 + 69 + col2 FROM tab1
----
69
69
69

query I rowsort
SELECT + col0 * + col1 + cor0.col0 * + col0 + col2 FROM tab2 AS cor0
----
10712
293
7622

query I rowsort
SELECT ALL col0 * - col1 * col0 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT ALL tab2.col0 * - col2 AS col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL - - col0 + col2 * + cor0.col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT - + 73 * col1 + cor0.col0 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1179
-2287
-4288

query I rowsort
SELECT - - 7 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT DISTINCT + 56 FROM tab2, tab0, tab1 AS cor0
----
56

query I rowsort
SELECT ALL + col2 * col1 * + ( col2 ) FROM tab1
----
119808
32490
75816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2591
SELECT DISTINCT 17 + + col2 * CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2591
SELECT DISTINCT 17 + + col2 * CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL 13 + col0 FROM tab1
----
16
77
93

query I rowsort
SELECT ALL + cor0.col1 * - cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL ( + cor0.col1 ) * + col0 + - 10 FROM tab1 AS cor0
----
1030
630
68

query I rowsort
SELECT ALL + + col1 - - cor0.col1 AS col1 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT ALL - col0 * col2 + 23 AS col2 FROM tab1 AS cor0
----
-139
-3625
-7657

query I rowsort
SELECT 95 + col0 FROM tab0 AS cor0
----
119
130
184

onlyif mysql # use DIV operator for integer division
query I rowsort label-2598
SELECT DISTINCT + ( col2 ) + cor0.col1 * cor0.col2 DIV cor0.col1 AS col1 FROM tab2 cor0
----
52
54
76

skipif mysql # not compatible
query I rowsort label-2598
SELECT DISTINCT + ( col2 ) + cor0.col1 * cor0.col2 / cor0.col1 AS col1 FROM tab2 cor0
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2599
SELECT - tab0.col0 DIV - 28 AS col1 FROM tab0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-2599
SELECT - tab0.col0 / - 28 AS col1 FROM tab0
----
0
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2600
SELECT col2 + ( + col1 + - col0 ) DIV col1 col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2600
SELECT col2 + ( + col1 + - col0 ) / col1 col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT col1 - 52 FROM tab2 AS cor0
----
-21
-35
7

query I rowsort
SELECT ALL - ( 16 ) FROM tab2 AS cor0
----
-16
-16
-16

query I rowsort
SELECT ALL - ( + col1 ) + col2 * col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - 96 * col0 * col2 + ( col0 ) * - col2 AS col2 FROM tab0 AS cor0
----
-3395
-707906
-76824

query I rowsort
SELECT DISTINCT + - ( 41 ) FROM tab0 AS cor0
----
-41

query I rowsort
SELECT ALL - + 75 AS col2 FROM tab0 AS cor0
----
-75
-75
-75

query I rowsort
SELECT + col0 * col0 + col1 AS col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT 95 + + col2 FROM tab1 AS cor0
----
149
152
191

query I rowsort
SELECT - col2 * col2 + + col2 * + 41 AS col2 FROM tab0 AS cor0
----
-3362
264
40

query I rowsort
SELECT DISTINCT + ( - col2 ) * col0 * 86 AS col1 FROM tab0 cor0
----
-3010
-627628
-68112

query I rowsort
SELECT ALL - cor0.col2 * + 87 * col1 AS col0 FROM tab1 cor0
----
-108576
-122148
-49590

query I rowsort
SELECT - col0 + - 29 * - cor0.col2 FROM tab0 cor0
----
-6
2289
933

onlyif mysql # use DIV operator for integer division
query I rowsort label-2613
SELECT DISTINCT ( 98 ) DIV + col0 FROM tab2 AS cor0
----
1
14

skipif mysql # not compatible
query I rowsort label-2613
SELECT DISTINCT ( 98 ) / + col0 FROM tab2 AS cor0
----
1
14

query I rowsort
SELECT DISTINCT - + col2 - + 66 * + col1 * 76 FROM tab1 AS cor0
----
-130470
-50217
-65304

query I rowsort
SELECT ALL - - ( ( col0 ) ) + cor0.col1 AS col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2616
SELECT ALL 42 DIV - col0 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2616
SELECT ALL 42 / - col0 FROM tab0 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL + + col1 + cor0.col0 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2618
SELECT ( 96 ) DIV col2 FROM tab0
----
1
2
96

skipif mysql # not compatible
query I rowsort label-2618
SELECT ( 96 ) / col2 FROM tab0
----
1
2
96

query I rowsort
SELECT - ( col0 ) + col1 * + ( + ( col1 ) ) * cor0.col1 AS col2 FROM tab2 AS cor0
----
205301
29784
4834

query I rowsort
SELECT DISTINCT ( + col2 ) * - col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + ( + col1 ) * - cor0.col0 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - - cor0.col1 + col0 * col0 AS col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT ALL + - 18 FROM tab0 cor0
----
-18
-18
-18

query I rowsort
SELECT - 94 + + col0 * - col2 FROM tab1 AS cor0
----
-256
-3742
-7774

query I rowsort
SELECT + col1 * - 58 + 7 + + col0 FROM tab1
----
-1498
-509
-667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + + 43 col0 FROM tab2 AS cor0
----
16
17
5

query I rowsort
SELECT ALL 48 * 74 FROM tab1 AS cor0
----
3552
3552
3552

query I rowsort
SELECT + cor0.col1 - col2 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL col0 + - col0 * - col2 AS col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT DISTINCT 33 FROM tab0, tab2 AS cor0
----
33

query I rowsort
SELECT DISTINCT 91 * col2 * + col2 + 54 FROM tab0
----
145
611938
99153

query I rowsort
SELECT DISTINCT - + col2 + cor0.col0 * + ( + col0 * - col0 ) AS col1 FROM tab0 cor0
----
-13857
-42876
-705051

query I rowsort
SELECT ALL - - col0 + + col1 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - + 69 + col1 FROM tab0 AS cor0
----
17
22
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 92 * col2 col1 FROM tab1
----
4968
5244
8832

query I rowsort
SELECT ALL - 71 * - tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 17333d4137b43afc4eab639234ff6136

query I rowsort
SELECT + 54 * - col0 * + tab0.col1 + col0 FROM tab0
----
-111432
-183295
-437257

query I rowsort
SELECT DISTINCT - 5 + - col0 AS col1 FROM tab1
----
-69
-8
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2639
SELECT ALL col2 + 4 DIV col0 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2639
SELECT ALL col2 + 4 / col0 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT - 21 + - 92 AS col2 FROM tab0
----
-113

query I rowsort
SELECT - - cor0.col2 + ( col0 ) FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + - col1 * - 44 + + 29 FROM tab1 AS cor0
----
1173
469
601

query I rowsort
SELECT DISTINCT + col0 * col1 - ( - col0 ) FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2644
SELECT DISTINCT + col1 + ( - col1 ) / cor0.col2 + + CAST( NULL AS SIGNED ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2644
SELECT DISTINCT + col1 + ( - col1 ) / cor0.col2 + + CAST ( NULL AS INTEGER ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - col0 + 29 FROM tab1 AS cor0
----
109
32
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2646
SELECT ALL col2 + col0 + col2 DIV - col1 AS col2 FROM tab2 cor0
----
104
115
34

skipif mysql # not compatible
query I rowsort label-2646
SELECT ALL col2 + col0 + col2 / - col1 AS col2 FROM tab2 cor0
----
104
115
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2647
SELECT DISTINCT col2 * col1 DIV - 98 FROM tab0
----
-28
-76
0

skipif mysql # not compatible
query I rowsort label-2647
SELECT DISTINCT col2 * col1 / - 98 FROM tab0
----
-28
-76
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - col1 col1 FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT - ( + tab2.col1 * - 98 + - 70 * col0 ) AS col0 FROM tab2
----
11242
3528
7196

query I rowsort
SELECT DISTINCT + tab0.col1 * - col1 AS col0 FROM tab0
----
-7396
-8281
-9409

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2, tab0 AS cor3
----
3645 values hashing to b223aa53e3aafe0f3f3f59048cc7a0d2

query I rowsort
SELECT + tab2.col1 * + ( col0 ) * - col2 + col2 * + tab2.col1 FROM tab2
----
-118118
-5022
-50388

query I rowsort
SELECT ALL + + col2 * ( + col0 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - - cor0.col1 + - cor0.col0 + col2 AS col0 FROM tab1 AS cor0
----
29
3
77

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 cor2
----
972 values hashing to 3a31dab513390ca6bd05c71a3d9c50f0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2656
SELECT - col0 DIV - col1 + 59 AS col1 FROM tab0
----
59
59
59

skipif mysql # not compatible
query I rowsort label-2656
SELECT - col0 / - col1 + 59 AS col1 FROM tab0
----
59
59
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2657
SELECT - col0 / - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2657
SELECT - col0 / - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * - col1 * - col2 AS col0 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT + cor0.col0 * + col0 AS col2 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT ALL - 59 * tab0.col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to ac86bf57c11709bfa15b00c3b6f93048

query I rowsort
SELECT - col1 + - cor0.col1 + + 43 AS col0 FROM tab0 cor0
----
-129
-139
-151

query I rowsort
SELECT - - 59 + - cor0.col0 * col0 FROM tab0 cor0
----
-1166
-517
-7862

query I rowsort
SELECT + 94 + + col1 FROM tab2 AS cor0
----
111
125
153

query I rowsort
SELECT DISTINCT col0 + col0 + col2 FROM tab2
----
182
196
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-2665
SELECT DISTINCT 70 + + col0 DIV col1 FROM tab0
----
70

skipif mysql # not compatible
query I rowsort label-2665
SELECT DISTINCT 70 + + col0 / col1 FROM tab0
----
70

query I rowsort
SELECT DISTINCT - ( col2 * + col0 ) + + col2 + + 10 * - col2 AS col0 FROM tab0
----
-1089
-44
-8036

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2667
SELECT ALL CAST( 62 AS SIGNED ) AS col0 FROM tab2
----
62
62
62

skipif mysql # not compatible
query I rowsort label-2667
SELECT ALL CAST ( 62 AS INTEGER ) AS col0 FROM tab2
----
62
62
62

query I rowsort
SELECT - ( + col2 ) * col1 AS col2 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT ALL + 36 + + tab2.col2 FROM tab2
----
62
63
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-2670
SELECT DISTINCT col0 + 64 DIV col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2670
SELECT DISTINCT col0 + 64 / col1 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL tab0.col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT + tab1.col0 + + 15 AS col0 FROM tab1
----
18
79
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 + - col1 col1 FROM tab1
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-2674
SELECT ALL cor1.col2 DIV + 33 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to eff82df49d5880477456e4901e030e04

skipif mysql # not compatible
query I rowsort label-2674
SELECT ALL cor1.col2 / + 33 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to eff82df49d5880477456e4901e030e04

onlyif mysql # use DIV operator for integer division
query I rowsort label-2675
SELECT - col2 DIV - col0 + - ( col0 ) + col0 AS col1 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2675
SELECT - col2 / - col0 + - ( col0 ) + col0 AS col1 FROM tab0 cor0
----
0
0
1

query I rowsort
SELECT + - col1 * col1 - + cor0.col1 FROM tab2 AS cor0
----
-306
-3540
-992

onlyif mysql # use DIV operator for integer division
query I rowsort label-2677
SELECT + tab1.col0 DIV + 69 FROM tab1, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-2677
SELECT + tab1.col0 / + 69 FROM tab1, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2678
SELECT DISTINCT + col1 * col2 + CAST( NULL AS SIGNED ) * + col0 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2678
SELECT DISTINCT + col1 * col2 + CAST ( NULL AS INTEGER ) * + col0 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + - col0 + col0 * 44 FROM tab1 AS cor0
----
129
2752
3440

query I rowsort
SELECT 87 * col2 + + col2 AS col1 FROM tab0 AS cor0
----
2904
7216
88

query I rowsort
SELECT col2 * + col2 + - ( 0 ) AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT col1 - - col2 * cor0.col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT cor0.col0 * - col2 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - 83 * cor0.col1 + + ( + ( cor0.col1 ) ) * + col2 AS col1 FROM tab1 AS cor0
----
-260
-754
169

query I rowsort
SELECT - col2 * + col0 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + col1 + + col0 * - col1 + - cor0.col2 * - ( ( col2 ) ) FROM tab2 AS cor0
----
-3867
118
543

query I rowsort
SELECT DISTINCT ( col1 * - col1 + col2 ) AS col0 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL 12 * col0 - ( col2 ) FROM tab0
----
255
419
986

query I rowsort
SELECT - col0 + + col0 + ( 88 * col1 ) AS col1 FROM tab1
----
1144
2288
880

query I rowsort
SELECT ALL + col2 - col2 * col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT ALL ( col2 ) * col2 * - 91 - + col0 * col1 FROM tab1
----
-265434
-296299
-839696

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 + 17 col0 FROM tab1 AS cor0
----
-37
-40
-79

query I rowsort
SELECT ALL col0 + + ( col0 * col1 ) FROM tab1
----
1120
704
81

query I rowsort
SELECT cor0.col2 + - ( - col1 ) * + col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - col0 + + col1 * + col1 FROM tab0 cor0
----
7372
8192
9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 col2 FROM tab2 cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2697
SELECT - col1 * + CAST( - 58 AS SIGNED ) * + col2 + + 81 AS col2 FROM tab1 AS cor0
----
33141
72465
81513

skipif mysql # not compatible
query I rowsort label-2697
SELECT - col1 * + CAST ( - 58 AS INTEGER ) * + col2 + + 81 AS col2 FROM tab1 AS cor0
----
33141
72465
81513

query I rowsort
SELECT ALL - col2 * 63 + + col1 FROM tab0 AS cor0
----
-1993
-5075
34

query I rowsort
SELECT DISTINCT + col2 + ( - col1 ) * col2 * - ( cor0.col0 ) FROM tab1 AS cor0
----
36537
4266
99936

query I rowsort
SELECT - cor0.col1 + + 42 FROM tab0 AS cor0
----
-44
-49
-55

query I rowsort
SELECT - 31 + col1 FROM tab2 AS cor0
----
-14
0
28

query I rowsort
SELECT - col0 + col2 AS col0 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - 58 AS col2 FROM tab0, tab0 AS cor0
----
-58

query I rowsort
SELECT ALL + col0 * col0 + col2 AS col0 FROM tab0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - col1 + - col0 * tab2.col1 AS col1 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - col1 AS col1 FROM tab0 WHERE NULL > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col2 * col1 col2 FROM tab0
----
-611884
-93654
-97

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col0 IN ( + col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( col1 * + col2 * col2 ) < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2710
SELECT DISTINCT tab1.col2 * col1 DIV - col0 FROM tab1
----
-15
-468
-8

skipif mysql # not compatible
query I rowsort label-2710
SELECT DISTINCT tab1.col2 * col1 / - col0 FROM tab1
----
-15
-468
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2711
SELECT - col0 * col1 DIV col2 AS col2 FROM tab0
----
-3395
-62
-98

skipif mysql # not compatible
query I rowsort label-2711
SELECT - col0 * col1 / col2 AS col2 FROM tab0
----
-3395
-62
-98

query I rowsort
SELECT + col1 + + col0 + tab0.col0 FROM tab0
----
134
167
269

onlyif mysql # use DIV operator for integer division
query I rowsort label-2713
SELECT ALL - col2 DIV col2 AS col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2713
SELECT ALL - col2 / col2 AS col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - tab0.col2 * col1 + + col2 AS col1 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT col2 FROM tab1 WHERE NOT ( NULL ) > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + tab2.col2 * - col2 * + col2 col1 FROM tab2
----
-17550
-19656
-54834

query I rowsort
SELECT ALL col0 * - col1 + col0 AS col1 FROM tab1
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col2 col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT + col0 * + col2 * col0 FROM tab0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col1 * - tab2.col1 + + tab2.col1 col0 FROM tab2
----
-193
-3344
-923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 * + col1 - - col2 col0 FROM tab1
----
1440
1512
684

query I rowsort
SELECT ALL - - cor0.col1 * + col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col2 * - col2 + - col1 + + col2 * col0 FROM tab0
----
-383
-63
483

query I rowsort
SELECT col1 FROM tab0 WHERE - col2 + - col2 * col1 * + col1 NOT IN ( - col2 + col1 + tab0.col1 * + tab0.col2 )
----
86
91
97

query I rowsort
SELECT DISTINCT - tab2.col2 * + col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT + col2 * col1 + col1 FROM tab2
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 col0 FROM tab1 WHERE NOT - col1 + - col0 + + col1 NOT IN ( + col0 )
----

query I rowsort
SELECT DISTINCT col1 - col2 FROM tab2 WHERE NULL = ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2729
SELECT ALL tab0.col0 + + col0 DIV tab0.col2 col0 FROM tab0
----
24
70
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2729
SELECT ALL tab0.col0 + + col0 / tab0.col2 col0 FROM tab0
----
24
70
90

query I rowsort
SELECT DISTINCT col1 * + col1 * + col0 FROM tab1
----
13520
2028
6400

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL = ( + col2 * col0 )
----

query I rowsort
SELECT - col0 * + col0 * col0 FROM tab1
----
-262144
-27
-512000

query I rowsort
SELECT col2 FROM tab1 WHERE NULL NOT IN ( col0 * tab1.col1 )
----

query I rowsort
SELECT DISTINCT col0 + col1 * + col1 AS col2 FROM tab2
----
3559
368
968

onlyif mysql # use DIV operator for integer division
query I rowsort label-2735
SELECT DISTINCT col0 + - col2 DIV + col2 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-2735
SELECT DISTINCT col0 + - col2 / + col2 FROM tab1
----
2
63
79

query I rowsort
SELECT tab0.col1 * - col1 + col1 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT col2 * tab1.col0 + + col2 FROM tab1
----
216
3705
7776

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL > ( col0 * - col1 )
----

query I rowsort
SELECT col2 * - col0 FROM tab1 AS cor0 WHERE NOT NULL = + col0 * col1
----

query I rowsort
SELECT ALL - col0 * col0 * col1 + + col2 * col2 FROM tab1 AS cor0
----
-37711
-73984
2682

query I rowsort
SELECT ALL + col2 * col0 * col0 AS col2 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT ALL - col1 * - col2 + col2 + tab2.col1 AS col1 FROM tab2
----
1619
701
895

onlyif mysql # use DIV operator for integer division
query I rowsort label-2743
SELECT ALL - col0 DIV + col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2743
SELECT ALL - col0 / + col1 AS col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col2 + + tab2.col1 * col2 col2 FROM tab2
----
1638
763
871

onlyif mysql # use DIV operator for integer division
query I rowsort label-2745
SELECT DISTINCT + tab1.col1 DIV col1 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-2745
SELECT DISTINCT + tab1.col1 / col1 FROM tab1
----
1

query I rowsort
SELECT + col2 * col0 + + col2 * - col2 FROM tab1
----
-1536
-2754
399

query I rowsort
SELECT ALL cor0.col2 * - cor0.col2 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 309d8ba6d1ea89e6795c82dda466e1ce

query I rowsort
SELECT DISTINCT - col1 + cor0.col1 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT + + col0 * + 93 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
253
5942
7427

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2750
SELECT ALL - col2 + CAST( + col1 AS SIGNED ) * col2 AS col2 FROM tab2 cor0
----
1508
608
810

skipif mysql # not compatible
query I rowsort label-2750
SELECT ALL - col2 + CAST ( + col1 AS INTEGER ) * col2 AS col2 FROM tab2 cor0
----
1508
608
810

query I rowsort
SELECT col0 * + 84 AS col2 FROM tab1 AS cor0
----
252
5376
6720

query I rowsort
SELECT DISTINCT 35 * ( - cor0.col1 ) + - 67 FROM tab0 AS cor0
----
-3077
-3252
-3462

query I rowsort
SELECT - ( ( col0 ) ) + + ( col2 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT + + col2 * 8 FROM tab2 AS cor0
----
208
216
304

query I rowsort
SELECT ( col0 * + col2 ) FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2756
SELECT col1 DIV 92 + + col2 * col1 DIV + col2 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2756
SELECT col1 / 92 + + col2 * col1 / + col2 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + 6 + + 7 FROM tab2 AS cor0
----
13
13
13

query I rowsort
SELECT DISTINCT - 7 FROM tab2, tab0 cor0
----
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + + cor0.col1 col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL 63 * - col0 * col1 FROM tab1
----
-40320
-4914
-65520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col2 * col2 col1 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT 6 + + col0 AS col1 FROM tab1 AS cor0
----
70
86
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 80 * col0 col0 FROM tab0 AS cor0
----
-1920
-2800
-7120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2764
SELECT DISTINCT 65 + - col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2764
SELECT DISTINCT 65 + - col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + - col1 + + col0 + col0 FROM tab0 AS cor0
----
-27
-38
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2766
SELECT + 4 * - col0 + - CAST( NULL AS SIGNED ) * - 50 * col0 + col0 * + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2766
SELECT + 4 * - col0 + - CAST ( NULL AS INTEGER ) * - 50 * col0 + col0 * + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 20 - cor0.col1 * + ( - cor0.col2 ) AS col1 FROM tab0 AS cor0
----
2818
7442
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-2768
SELECT ALL + col2 DIV col1 + cor0.col1 col2 FROM tab2 AS cor0
----
19
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2768
SELECT ALL + col2 / col1 + cor0.col1 col2 FROM tab2 AS cor0
----
19
31
59

query I rowsort
SELECT - col2 * 69 AS col1 FROM tab1 AS cor0
----
-3726
-3933
-6624

query I rowsort
SELECT col0 * col2 * - cor0.col0 FROM tab2 cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + + col1 * 12 FROM tab2 AS cor0
----
204
372
708

query I rowsort
SELECT ALL col1 + + col1 - col1 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-1222
-1352
-550

query I rowsort
SELECT ALL col0 * + 37 AS col2 FROM tab1 cor0
----
111
2368
2960

query I rowsort
SELECT DISTINCT - col2 * + col2 + - col1 AS col0 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT + col1 * col2 * + 3 FROM tab1 AS cor0
----
1710
3744
4212

query I rowsort
SELECT DISTINCT + - col1 * + ( col1 ) AS col0 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + cor1.col0 AS col2 FROM tab0, tab1, tab0 AS cor0, tab1 AS cor1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT tab1.col0 + col1 * - tab1.col2 FROM tab1
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2779
SELECT col0 DIV - col1 + col1 * - col0 FROM tab2 AS cor0
----
-1347
-217
-4603

skipif mysql # not compatible
query I rowsort label-2779
SELECT col0 / - col1 + col1 * - col0 FROM tab2 AS cor0
----
-1347
-217
-4603

onlyif mysql # use DIV operator for integer division
query I rowsort label-2780
SELECT - 26 + col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
-26
-26
-26

skipif mysql # not compatible
query I rowsort label-2780
SELECT - 26 + col0 / - col1 AS col0 FROM tab0 AS cor0
----
-26
-26
-26

query I rowsort
SELECT DISTINCT 28 AS col2 FROM tab0 AS cor0
----
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-2782
SELECT col0 * + col0 DIV + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2782
SELECT col0 * + col0 / + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - col0 + col0 col2 FROM tab0 AS cor0
----
-1190
-552
-7832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2784
SELECT + CAST( NULL AS DECIMAL ) * - cor0.col0 + cor0.col0 / + col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2784
SELECT + CAST ( NULL AS REAL ) * - cor0.col0 + cor0.col0 / + col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 17 * - col1 AS col1 FROM tab0 AS cor0
----
-1462
-1547
-1649

query I rowsort
SELECT col0 * col2 + - col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + col0 + + cor0.col2 + col0 FROM tab0 cor0
----
260
71
81

query I rowsort
SELECT + 57 + 11 FROM tab1
----
68
68
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col0 + + col2 col1 FROM tab0
----
253
37
90

query I rowsort
SELECT + - ( col2 ) + + col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + + col1 * 36 AS col1 FROM tab1 AS cor0
----
360
468
936

onlyif mysql # use DIV operator for integer division
query I rowsort label-2792
SELECT + cor0.col2 DIV + col2 AS col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2792
SELECT + cor0.col2 / + col2 AS col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT + + cor0.col1 + + ( + col1 ) * col0 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-2794
SELECT DISTINCT + - col2 + - col0 DIV + col1 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-2794
SELECT DISTINCT + - col2 + - col0 / + col1 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2795
SELECT - col0 DIV ( col2 + col1 ) FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2795
SELECT - col0 / ( col2 + col1 ) FROM tab0 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2796
SELECT - col2 * CAST( - col0 AS SIGNED ) * + col0 AS col2 FROM tab1 AS cor0
----
233472
486
614400

skipif mysql # not compatible
query I rowsort label-2796
SELECT - col2 * CAST ( - col0 AS INTEGER ) * + col0 AS col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - ( + ( - cor0.col2 ) ) AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + 7 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT - + cor0.col0 * - 34 AS col1 FROM tab1 AS cor0
----
102
2176
2720

query I rowsort
SELECT 11 + - col1 AS col2 FROM tab2
----
-20
-48
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2801
SELECT - + CAST( NULL AS SIGNED ) * + cor0.col2 + - col1 * 49 / cor0.col1 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2801
SELECT - + CAST ( NULL AS INTEGER ) * + cor0.col2 + - col1 * 49 / cor0.col1 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * + col1 + + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + col2 + ( + col1 ) AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + col0 * - 18 FROM tab2 AS cor0
----
-126
-1404
-1422

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 31 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT ALL 42 + col1 * col2 * 7 FROM tab1 AS cor0
----
4032
8778
9870

query I rowsort
SELECT + - col1 * 23 + col0 * col1 + 13 * col1 AS col0 FROM tab2 AS cor0
----
-93
1173
4012

query I rowsort
SELECT DISTINCT col2 * 45 AS col0 FROM tab0
----
1485
3690
45

query I rowsort
SELECT + 98 + col1 FROM tab1
----
108
111
124

onlyif mysql # use DIV operator for integer division
query I rowsort label-2810
SELECT + + 59 DIV col0 - - col1 * col2 AS col1 FROM tab1 AS cor0
----
1248
1423
570

skipif mysql # not compatible
query I rowsort label-2810
SELECT + + 59 / col0 - - col1 * col2 AS col1 FROM tab1 AS cor0
----
1248
1423
570

query I rowsort
SELECT cor0.col0 - + 77 FROM tab2 AS cor0
----
-70
1
2

query I rowsort
SELECT col0 * cor0.col2 + - col2 FROM tab1 AS cor0
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 82 - + col2 col1 FROM tab0
----
0
49
81

query I rowsort
SELECT 89 * - col0 AS col0 FROM tab1 cor0
----
-267
-5696
-7120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * 64 col2 FROM tab2 cor0
----
1088
1984
3776

query I rowsort
SELECT DISTINCT + ( + 42 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
42

query I rowsort
SELECT DISTINCT - 23 * col2 + + col0 AS col0 FROM tab1 AS cor0
----
-1239
-1247
-2128

query I rowsort
SELECT - - ( col0 ) + - col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 58 FROM tab0, tab0 cor0
----
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-2820
SELECT - 38 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2820
SELECT - 38 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + ( - col0 ) * + 38 FROM tab1 AS cor0
----
-114
-2432
-3040

query I rowsort
SELECT ALL - - 23 AS col1 FROM tab1 cor0
----
23
23
23

query I rowsort
SELECT ALL + 33 AS col2 FROM tab1 AS cor0
----
33
33
33

query I rowsort
SELECT ALL - - 98 * - col1 FROM tab0 AS cor0
----
-8428
-8918
-9506

query I rowsort
SELECT ALL - 21 * col2 AS col0 FROM tab2 AS cor0
----
-546
-567
-798

query I rowsort
SELECT - - col2 * col2 * - 10 FROM tab0 AS cor0
----
-10
-10890
-67240

query I rowsort
SELECT + + col0 * cor0.col2 * - col2 AS col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT ALL + - 69 + + col1 AS col0 FROM tab0 AS cor0
----
17
22
28

query I rowsort
SELECT + 75 * - col1 AS col1 FROM tab2 AS cor0
----
-1275
-2325
-4425

query I rowsort
SELECT DISTINCT + 76 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 89 * - cor0.col2 col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 40b116dcc09e64a228a1f6f10a249323

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + + 48 col2 FROM tab1 AS cor0
----
102
105
144

onlyif mysql # use DIV operator for integer division
query I rowsort label-2833
SELECT - col1 DIV 71 + - col2 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-2833
SELECT - col1 / 71 + - col2 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT DISTINCT col2 - + col2 * ( col2 ) FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT ( col0 ) - col0 FROM tab2
----
0

query I rowsort
SELECT DISTINCT 29 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2837
SELECT + col2 + col1 + CAST( - col0 AS SIGNED ) FROM tab1
----
29
3
77

skipif mysql # not compatible
query I rowsort label-2837
SELECT + col2 + col1 + CAST ( - col0 AS INTEGER ) FROM tab1
----
29
3
77

query I rowsort
SELECT ALL - col0 + 12 FROM tab2 AS cor0
----
-66
-67
5

query I rowsort
SELECT DISTINCT ( + col1 ) * cor0.col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - + 38 * - 34 + - col0 AS col0 FROM tab1 AS cor0
----
1212
1228
1289

query I rowsort
SELECT - col0 * - col1 * cor0.col1 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT ALL + ( + 23 ) AS col2 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to d3b0357ceadb3a70da7f1649b1ef2a30

query I rowsort
SELECT - + ( col2 ) * col1 + 83 AS col0 FROM tab0 AS cor0
----
-14
-2755
-7379

query I rowsort
SELECT DISTINCT - 19 + col0 AS col1 FROM tab2 AS cor0
----
-12
59
60

query I rowsort
SELECT ALL + 22 * 89 AS col1 FROM tab1 AS cor0
----
1958
1958
1958

query I rowsort
SELECT col0 * tab2.col2 + col0 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-2847
SELECT DISTINCT 2 DIV col1 col1 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2847
SELECT DISTINCT 2 / col1 col1 FROM tab1
----
0

query I rowsort
SELECT DISTINCT + ( 94 + - tab1.col1 ) FROM tab1
----
68
81
84

query I rowsort
SELECT ALL - col2 * 55 * + col1 AS col1 FROM tab1
----
-31350
-68640
-77220

query I rowsort
SELECT - col0 + ( - col1 ) FROM tab1
----
-29
-74
-93

query I rowsort
SELECT - + col2 * + col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL 27 * col0 AS col0 FROM tab0
----
2403
648
945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2853
SELECT DISTINCT + 30 + col2 * + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2853
SELECT DISTINCT + 30 + col2 * + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT + + ( - col1 ) + + col0 FROM tab2 cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2855
SELECT ALL - CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2855
SELECT ALL - CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT 86 FROM tab2, tab1 cor0, tab2 AS cor1
----
86

query I rowsort
SELECT ALL - - col0 + cor0.col2 + 82 AS col2 FROM tab1 AS cor0
----
139
203
258

onlyif mysql # use DIV operator for integer division
query I rowsort label-2858
SELECT 83 DIV col1 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-2858
SELECT 83 / col1 FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT col1 * - 38 + + col0 + col1 AS col2 FROM tab0
----
-3158
-3278
-3554

query I rowsort
SELECT col2 + + 0 * ( col1 ) AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT col1 * col2 + - 45 FROM tab2 AS cor0
----
1489
601
792

query I rowsort
SELECT ALL - col0 * col1 + - col2 * - col1 AS col2 FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT ( + 13 ) AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT ALL cor0.col0 + - 95 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to a463a912adaf700f05e51566ae030e4c

query I rowsort
SELECT DISTINCT col2 + - 75 FROM tab1 AS cor0
----
-18
-21
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2866
SELECT DISTINCT + CAST( col1 AS SIGNED ) + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-2866
SELECT DISTINCT + CAST ( col1 AS INTEGER ) + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * + col0 col2 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2868
SELECT ALL CAST( + col0 AS SIGNED ) - - col0 * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2868
SELECT ALL CAST ( + col0 AS INTEGER ) - - col0 * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 * + col0 + - col0 * - col1 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT 46 * + 84 AS col1 FROM tab2 cor0
----
3864
3864
3864

query I rowsort
SELECT ALL + col1 * - col2 - + col0 AS col1 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL + col0 + - cor0.col0 * col1 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT - col1 * - 75 FROM tab2 AS cor0
----
1275
2325
4425

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( ( + cor0.col1 ) AS REAL ) * 53 + + col2 FROM tab0 AS cor0
----
-4525
-4741
-5140

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2875
SELECT DISTINCT ( col1 ) / col0 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2875
SELECT DISTINCT ( col1 ) / col0 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 61 + 50 col1 FROM tab0 AS cor0
----
111
111
111

query I rowsort
SELECT DISTINCT ( + col1 ) * col1 - col1 AS col0 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT col2 * - col0 + - col0 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 + col0 AS col1 FROM tab2 cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-2880
SELECT DISTINCT + col0 * tab1.col1 DIV - col2 + col0 AS col0 FROM tab1
----
2
53
70

skipif mysql # not compatible
query I rowsort label-2880
SELECT DISTINCT + col0 * tab1.col1 / - col2 + col0 AS col0 FROM tab1
----
2
53
70

query I rowsort
SELECT DISTINCT + col1 * - col2 * - col0 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT + col1 * 46 AS col2 FROM tab1 AS cor0
----
1196
460
598

query I rowsort
SELECT - cor0.col1 * 17 + - col1 * ( cor0.col2 ) AS col1 FROM tab1 cor0
----
-1469
-1846
-740

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2884
SELECT DISTINCT - + CAST( NULL AS SIGNED ) / + col1 + col2 / - col0 AS col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2884
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) / + col1 + col2 / - col0 AS col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT col2 * col2 * col0 + col2 FROM tab2 AS cor0
----
114114
5130
52754

query I rowsort
SELECT ALL - cor0.col2 + - col0 * + col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT - - col2 + 11 AS col2 FROM tab0 AS cor0
----
12
44
93

query I rowsort
SELECT - col1 * - 73 + col2 * + col0 + - 16 AS col2 FROM tab2 AS cor0
----
2436
4227
6319

onlyif mysql # use DIV operator for integer division
query I rowsort label-2889
SELECT - col0 DIV - col0 AS col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2889
SELECT - col0 / - col0 AS col1 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT - + col0 + + col2 AS col2 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-2891
SELECT ALL + 59 DIV + col1 FROM tab2 AS cor0
----
1
1
3

skipif mysql # not compatible
query I rowsort label-2891
SELECT ALL + 59 / + col1 FROM tab2 AS cor0
----
1
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2892
SELECT DISTINCT col0 DIV + 74 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-2892
SELECT DISTINCT col0 / + 74 FROM tab0
----
0
1

query I rowsort
SELECT - 93 - 75 FROM tab0, tab2 AS cor0
----
9 values hashing to 607f5e02ee6c33f6455bbd825a0de826

query I rowsort
SELECT ALL col2 * + tab2.col0 * col0 AS col2 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT ALL - tab0.col0 FROM tab0, tab0 cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

onlyif mysql # use DIV operator for integer division
query I rowsort label-2896
SELECT + col0 + cor0.col1 + ( col2 ) DIV cor0.col1 FROM tab2 AS cor0
----
137
38
98

skipif mysql # not compatible
query I rowsort label-2896
SELECT + col0 + cor0.col1 + ( col2 ) / cor0.col1 FROM tab2 AS cor0
----
137
38
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + cor0.col1 col1 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-2898
SELECT - - cor0.col2 DIV + 10 + + col1 FROM tab0 AS cor0
----
89
97
99

skipif mysql # not compatible
query I rowsort label-2898
SELECT - - cor0.col2 / + 10 + + col1 FROM tab0 AS cor0
----
89
97
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2899
SELECT - tab0.col1 * + CAST( NULL AS SIGNED ) + 91 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2899
SELECT - tab0.col1 * + CAST ( NULL AS INTEGER ) + 91 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT tab1.col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 90 AS REAL ) col0 FROM tab2
----
90
90
90

query I rowsort
SELECT 98 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + col0 AS REAL ) FROM tab2 AS cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 42 * col0 col0 FROM tab2 AS cor0
----
-294
-3276
-3318

query I rowsort
SELECT DISTINCT - col1 * + 29 FROM tab0 AS cor0
----
-2494
-2639
-2813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2906
SELECT DISTINCT - + CAST( NULL AS DECIMAL ) * cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2906
SELECT DISTINCT - + CAST ( NULL AS REAL ) * cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + - col0 * + 57 AS col0 FROM tab2 AS cor0
----
-399
-4446
-4503

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2908
SELECT + - CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2908
SELECT + - CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2909
SELECT ALL cor0.col1 DIV - col1 col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2909
SELECT ALL cor0.col1 / - col1 col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col0 col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + + col2 + col1 * 45 AS col0 FROM tab1 AS cor0
----
1224
507
681

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 + col1 col1 FROM tab0
----
2
62
62

query I rowsort
SELECT ALL + 4 FROM tab1
----
4
4
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2914
SELECT DISTINCT + CAST( NULL AS DECIMAL ) / - cor1.col0 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2914
SELECT DISTINCT + CAST ( NULL AS REAL ) / - cor1.col0 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
NULL

query I rowsort
SELECT + 18 AS col0 FROM tab1 AS cor0
----
18
18
18

query I rowsort
SELECT DISTINCT + col0 * + ( col2 ) + + cor0.col1 AS col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - cor0.col2 * + col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2918
SELECT ALL + col2 DIV - col2 - 4 * + col2 FROM tab1 AS cor0
----
-217
-229
-385

skipif mysql # not compatible
query I rowsort label-2918
SELECT ALL + col2 / - col2 - 4 * + col2 FROM tab1 AS cor0
----
-217
-229
-385

query I rowsort
SELECT DISTINCT 88 * col2 FROM tab2
----
2288
2376
3344

query I rowsort
SELECT DISTINCT + - col0 + 16 * - col1 * col2 + - col1 AS col2 FROM tab1 AS cor0
----
-20061
-22493
-9194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2921
SELECT ALL col0 + - CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2921
SELECT ALL col0 + - CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2922
SELECT DISTINCT col2 DIV - 41 + - col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-2922
SELECT DISTINCT col2 / - 41 + - col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - 62 + col0 * + col1 FROM tab0
----
2002
3333
8037

query I rowsort
SELECT col2 * col1 + col1 * col0 FROM tab2
----
1054
1989
6136

query I rowsort
SELECT - 52 AS col0 FROM tab2
----
-52
-52
-52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2926
SELECT + + CAST( - col0 AS SIGNED ) + + col1 FROM tab0 AS cor0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-2926
SELECT + + CAST ( - col0 AS INTEGER ) + + col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - + 81 + + col2 + - col0 * cor0.col1 AS col1 FROM tab0 cor0
----
-2112
-3475
-8098

query I rowsort
SELECT DISTINCT 91 * ( + cor0.col2 ) * 6 + - col1 AS col1 FROM tab2 AS cor0
----
14137
14711
20731

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2929
SELECT - ( col1 ) + + col1 + CAST( NULL AS SIGNED ) * col1 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2929
SELECT - ( col1 ) + + col1 + CAST ( NULL AS INTEGER ) * col1 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + ( cor0.col0 * + col2 ) + 9 * - col0 col0 FROM tab2 AS cor0
----
1260
157482
236447

query I rowsort
SELECT ALL tab0.col2 * col0 * 14 AS col0 FROM tab0
----
102172
11088
490

query I rowsort
SELECT ALL - col0 * + 74 * + col0 FROM tab2
----
-3626
-450216
-461834

query I rowsort
SELECT - ( + ( + col2 ) ) + + col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL - cor0.col0 * - 81 + - col2 FROM tab0 AS cor0
----
1911
2834
7127

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col0 ) + col0 col2 FROM tab1 AS cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * - col0 col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT + - col2 * cor0.col2 + - col1 FROM tab0 cor0
----
-1175
-6815
-98

query I rowsort
SELECT - + ( col2 ) * + col1 + 33 AS col0 FROM tab2 AS cor0
----
-1501
-613
-804

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - - ( col1 * - col2 ) col2 FROM tab1
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-2940
SELECT + col2 + col1 * col2 DIV col2 AS col2 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-2940
SELECT + col2 + col1 * col2 / col2 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT col2 - 38 AS col1 FROM tab2
----
-11
-12
0

query I rowsort
SELECT DISTINCT 21 AS col0 FROM tab1, tab0 AS cor0, tab2 cor1
----
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col1 col0 FROM tab2 cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2944
SELECT ALL + col1 + + CAST( NULL AS SIGNED ) + cor0.col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2944
SELECT ALL + col1 + + CAST ( NULL AS INTEGER ) + cor0.col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * 60 AS col2 FROM tab0 cor0
----
1440
2100
5340

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2946
SELECT DISTINCT - 1 / col0 + - col2 * - CAST( NULL AS SIGNED ) / col1 + col2 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2946
SELECT DISTINCT - 1 / col0 + - col2 * - CAST ( NULL AS INTEGER ) / col1 + col2 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + 5 + - col0 AS col1 FROM tab0 AS cor0
----
-19
-30
-84

query I rowsort
SELECT + - 68 AS col0 FROM tab1 cor0
----
-68
-68
-68

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col1 AS REAL ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - cor0.col2 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT + 72 AS col2 FROM tab1
----
72
72
72

query I rowsort
SELECT ALL + col2 * cor0.col2 + - col2 AS col1 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL - col0 * - 20 + col0 FROM tab0 AS cor0
----
1869
504
735

query I rowsort
SELECT - + ( col1 ) * cor0.col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + + 31 + col1 FROM tab1 AS cor0
----
41
44
57

query I rowsort
SELECT ALL + 94 * - col0 FROM tab2 AS cor0
----
-658
-7332
-7426

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2957
SELECT ALL CAST( + col0 AS SIGNED ) + - col0 + - 17 * - col2 FROM tab0 AS cor0
----
1394
17
561

skipif mysql # not compatible
query I rowsort label-2957
SELECT ALL CAST ( + col0 AS INTEGER ) + - col0 + - 17 * - col2 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT ALL + col0 - col1 * + col0 AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT + + 97 + - col1 * + 21 FROM tab1 AS cor0
----
-113
-176
-449

query I rowsort
SELECT - - ( col2 ) * col2 + col1 * col1 FROM tab0 AS cor0
----
15005
8485
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 31 * col0 col2 FROM tab2 AS cor0
----
217
2418
2449

onlyif mysql # use DIV operator for integer division
query I rowsort label-2962
SELECT DISTINCT col2 DIV col0 + + col0 * + col2 FROM tab1
----
180
3648
7681

skipif mysql # not compatible
query I rowsort label-2962
SELECT DISTINCT col2 / col0 + + col0 * + col2 FROM tab1
----
180
3648
7681

query I rowsort
SELECT ALL col1 * tab1.col0 + tab1.col0 AS col0 FROM tab1
----
1120
704
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2964
SELECT - + CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2964
SELECT - + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-2965
SELECT - 22 DIV col1 AS col0 FROM tab1 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-2965
SELECT - 22 / col1 AS col0 FROM tab1 AS cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT cor0.col1 * col1 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + + col1 + col1 * 58 AS col0 FROM tab2 AS cor0
----
1003
1829
3481

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2968
SELECT + - col0 * col2 + - CAST( NULL AS SIGNED ) * - col0 * + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2968
SELECT + - col0 * col2 + - CAST ( NULL AS INTEGER ) * - col0 * + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * - col1 - 18 AS col0 FROM tab0 AS cor0
----
2046
3377
8081

query I rowsort
SELECT + 81 * - col1 + + cor0.col1 AS col0 FROM tab2 cor0
----
-1360
-2480
-4720

query I rowsort
SELECT cor0.col0 * col2 * col1 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT + col2 * - col0 + + col0 AS col0 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT - col1 + + col0 * + ( + col0 ) FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT - col0 * col1 + + col0 * - col2 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT DISTINCT - 54 + col1 AS col0 FROM tab2 AS cor0
----
-23
-37
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2976
SELECT DISTINCT - col0 * cor0.col0 DIV ( + 35 + col1 ) AS col1 FROM tab2 AS cor0
----
-120
-64
0

skipif mysql # not compatible
query I rowsort label-2976
SELECT DISTINCT - col0 * cor0.col0 / ( + 35 + col1 ) AS col1 FROM tab2 AS cor0
----
-120
-64
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 * col1 col0 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT DISTINCT - col2 + - ( - cor0.col2 + col0 ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + col0 * col2 + cor0.col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT col1 * + 60 + + col2 FROM tab0 AS cor0
----
5193
5542
5821

query I rowsort
SELECT ALL + col0 + col0 * 87 FROM tab2 AS cor0
----
616
6864
6952

query I rowsort
SELECT DISTINCT + + col2 + - 30 * + col2 AS col2 FROM tab0 cor0
----
-2378
-29
-957

query I rowsort
SELECT col0 + - ( cor0.col2 + - col2 ) * - 75 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2984
SELECT ALL cor0.col1 * col2 - + 3 DIV - col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-2984
SELECT ALL cor0.col1 * col2 - + 3 / - col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + + cor0.col1 + - col2 AS col1 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2986
SELECT ALL - col0 DIV + ( 44 ) AS col0 FROM tab1 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2986
SELECT ALL - col0 / + ( 44 ) AS col0 FROM tab1 cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT + col1 + - cor0.col2 * col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT + - col1 + + 55 * col2 + col1 AS col1 FROM tab1 AS cor0
----
2970
3135
5280

query I rowsort
SELECT ALL + - col1 + col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL cor0.col2 * ( - 1 + col2 ) * cor0.col0 AS col1 FROM tab1 AS cor0
----
204288
729600
8586

query I rowsort
SELECT ALL + col0 * - col1 * - col0 AS col2 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT + - col1 + col2 * + col2 * - col0 FROM tab1 AS cor0
----
-207946
-737293
-8774

onlyif mysql # use DIV operator for integer division
query I rowsort label-2993
SELECT + col2 * - col2 + - 32 DIV col1 + ( col0 ) AS col0 FROM tab1 AS cor0
----
-2914
-3188
-9138

skipif mysql # not compatible
query I rowsort label-2993
SELECT + col2 * - col2 + - 32 / col1 + ( col0 ) AS col0 FROM tab1 AS cor0
----
-2914
-3188
-9138

query I rowsort
SELECT col0 + 18 + - col2 * col2 AS col2 FROM tab0 AS cor0
----
-1047
-6617
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2995
SELECT + col1 + - ( + col0 ) * col2 DIV - col2 FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-2995
SELECT + col1 + - ( + col0 ) * col2 / - col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT 22 + cor0.col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 55bdbdcbcfef73f1b5693aa2329cde1b

query I rowsort
SELECT + - col0 + col0 * 45 FROM tab0 AS cor0
----
1056
1540
3916

onlyif mysql # use DIV operator for integer division
query I rowsort label-2998
SELECT - - 41 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2998
SELECT - - 41 / col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 61 col1 FROM tab1 cor0
----
61

query I rowsort
SELECT DISTINCT 53 + + 31 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
84

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( + cor0.col1 AS REAL ) AS col0 FROM tab1, tab0 cor0 CROSS JOIN tab0, tab2 AS cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

onlyif mysql # use DIV operator for integer division
query I rowsort label-3002
SELECT DISTINCT + col1 DIV - col0 + 22 AS col0 FROM tab2
----
18
22

skipif mysql # not compatible
query I rowsort label-3002
SELECT DISTINCT + col1 / - col0 + 22 AS col0 FROM tab2
----
18
22

query I rowsort
SELECT DISTINCT 54 + - tab1.col1 + + 12 FROM tab1
----
40
53
56

query I rowsort
SELECT DISTINCT col2 + col0 * + col2 FROM tab1
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-3005
SELECT DISTINCT - col2 DIV + col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-3005
SELECT DISTINCT - col2 / + col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * cor0.col0 + ( col1 ) * - col0 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 43 * + cor0.col1 * + col2 FROM tab1 AS cor0
----
-24510
-53664
-60372

query I rowsort
SELECT - 15 * col2 * col0 FROM tab2
----
-2835
-30420
-45030

query I rowsort
SELECT DISTINCT - - col2 * - col2 AS col0 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT - col0 * + 21 FROM tab2 AS cor0
----
-147
-1638
-1659

query I rowsort
SELECT + 4 * col0 * - col2 + tab1.col2 + - col0 AS col0 FROM tab1
----
-14599
-30704
-597

query I rowsort
SELECT + 26 * - col2 AS col0 FROM tab0
----
-2132
-26
-858

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3013
SELECT DISTINCT CAST( NULL AS SIGNED ) + + col0 * + col1 + col1 * + col1 AS col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-3013
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + col0 * + col1 + col1 * + col1 AS col0 FROM tab2
----
NULL

query I rowsort
SELECT ALL tab2.col2 * - 86 AS col2 FROM tab2
----
-2236
-2322
-3268

query I rowsort
SELECT + col0 * + col1 + col2 AS col1 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT + 79 + - col1 FROM tab2
----
20
48
62

query I rowsort
SELECT DISTINCT + 54 * - col1 FROM tab0 AS cor0
----
-4644
-4914
-5238

query I rowsort
SELECT ALL + 55 + col0 FROM tab1 AS cor0
----
119
135
58

query I rowsort
SELECT ALL - 58 + + col0 FROM tab2 AS cor0
----
-51
20
21

query I rowsort
SELECT ALL 43 * + col1 FROM tab1
----
1118
430
559

query I rowsort
SELECT DISTINCT - + col0 + ( + cor0.col2 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL - col0 + - ( 60 + col0 ) FROM tab2 AS cor0
----
-216
-218
-74

query I rowsort
SELECT cor0.col0 + col2 * col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL + col1 + + 13 * - 94 AS col1 FROM tab2 AS cor0
----
-1163
-1191
-1205

query I rowsort
SELECT ALL col0 * 49 AS col1 FROM tab2
----
343
3822
3871

onlyif mysql # use DIV operator for integer division
query I rowsort label-3026
SELECT + col0 DIV CAST( cor0.col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-3026
SELECT + col0 / CAST ( cor0.col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT DISTINCT tab0.col1 * - col1 + - col1 AS col2 FROM tab0
----
-7482
-8372
-9506

query I rowsort
SELECT ALL col2 + col2 * col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT col1 - + col1 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - col0 * + col2 + + col1 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT + tab1.col2 - tab1.col1 FROM tab1
----
28
47
83

query I rowsort
SELECT + tab2.col0 * + tab2.col1 AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + col2 * tab1.col1 * col2 AS col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT + col2 * - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - + col2 + + col0 * col1 * cor0.col1 AS col2 FROM tab2 cor0
----
22793
271492
6700

query I rowsort
SELECT - col0 * col0 + col1 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT ALL cor0.col1 + col1 AS col0 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + col0 + - col0 - col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col2 col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT cor0.col2 * - col0 + col2 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL cor0.col2 - + col1 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - cor0.col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + cor0.col0 * col0 + + col2 AS col1 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-3044
SELECT ALL - col2 DIV - col2 col1 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3044
SELECT ALL - col2 / - col2 col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + ( col2 ) * - col2 + col2 * col2 * + col1 AS col0 FROM tab1 AS cor0
----
110592
29241
72900

query I rowsort
SELECT + + 50 * + col0 - + col0 FROM tab1 AS cor0
----
147
3136
3920

query I rowsort
SELECT + + cor1.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT - 88 * + col1 AS col0 FROM tab0 AS cor0
----
-7568
-8008
-8536

query I rowsort
SELECT col2 - - col1 * - col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT - + col1 * col2 * + col1 + - col2 AS col0 FROM tab0 AS cor0
----
-244101
-679124
-9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * col2 col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + ( - ( col2 ) * col0 ) + + col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT - 62 * - col1 FROM tab2
----
1054
1922
3658

query I rowsort
SELECT DISTINCT + cor0.col1 * + col1 - - col0 * + col0 AS col1 FROM tab1 AS cor0
----
4196
6569
685

query I rowsort
SELECT ALL + 92 AS col2 FROM tab2
----
92
92
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-3057
SELECT 91 DIV col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3057
SELECT 91 / col0 FROM tab0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 78 * + cor0.col2 + + col1 col0 FROM tab0 AS cor0
----
175
2660
6487

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3059
SELECT + CAST( col0 AS SIGNED ) - col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3059
SELECT + CAST ( col0 AS INTEGER ) - col0 FROM tab2
----
0
0
0

query I rowsort
SELECT col0 * + col0 + cor0.col2 + col2 FROM tab0 AS cor0
----
1227
642
8085

query I rowsort
SELECT DISTINCT - - ( col0 ) * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col2 * + col1 + + cor0.col2 * + 71 + - cor0.col1 * - col2 FROM tab0 AS cor0
----
20746
265
8019

onlyif mysql # use DIV operator for integer division
query I rowsort label-3063
SELECT ALL - cor0.col0 DIV + col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3063
SELECT ALL - cor0.col0 / + col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + 57 + - col1 AS col0 FROM tab0
----
-29
-34
-40

query I rowsort
SELECT DISTINCT tab1.col1 + tab1.col0 + col0 FROM tab1
----
138
173
32

query I rowsort
SELECT DISTINCT + 84 + + col2 * - tab2.col1 AS col1 FROM tab2
----
-1450
-562
-753

query I rowsort
SELECT col0 * + col2 * col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT ( col1 ) * col1 + - col1 AS col2 FROM tab1
----
156
650
90

query I rowsort
SELECT col2 * col2 - tab2.col2 FROM tab2
----
1406
650
702

query I rowsort
SELECT DISTINCT ( 63 ) + + col2 AS col1 FROM tab2
----
101
89
90

query I rowsort
SELECT - ( - 70 ) + + cor1.col2 * + cor1.col1 - + cor1.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 014c6b58569b7acbe9e433de95ad5db0

query I rowsort
SELECT ALL + ( + cor0.col1 ) * col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col2 AS col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - + ( col1 ) + 40 AS col0 FROM tab1 AS cor0
----
14
27
30

query I rowsort
SELECT ALL cor0.col0 * - cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-3076
SELECT DISTINCT + - ( col1 ) DIV + 63 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3076
SELECT DISTINCT + - ( col1 ) / + 63 FROM tab0 AS cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3077
SELECT + col2 + col1 / CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3077
SELECT + col2 + col1 / CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * + col0 + - 57 AS col1 FROM tab2 AS cor0
----
132
1971
2945

query I rowsort
SELECT + 7 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-231
-574
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3080
SELECT + 60 * col2 DIV 67 + - 65 * + col2 * col0 AS col2 FROM tab1 AS cor0
----
-10482
-237069
-499115

skipif mysql # not compatible
query I rowsort label-3080
SELECT + 60 * col2 / 67 + - 65 * + col2 * col0 AS col2 FROM tab1 AS cor0
----
-10482
-237069
-499115

query I rowsort
SELECT DISTINCT - - col0 * + col2 + - cor0.col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL + ( - col0 ) * col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 32 + cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 9bfe0a3a40f6ea36db9e7cd8f88b4222

query I rowsort
SELECT ALL + 50 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 AS cor2, tab2 cor3
----
243 values hashing to b834e2084022ca341153dd05ef833c6b

query I rowsort
SELECT - col2 * 55 + + 84 * col2 * + col1 - + cor0.col0 FROM tab2 AS cor0
----
127348
52095
68816

query I rowsort
SELECT - col0 + - 75 * cor0.col2 FROM tab1 AS cor0
----
-4053
-4339
-7280

onlyif mysql # use DIV operator for integer division
query I rowsort label-3087
SELECT DISTINCT + col1 DIV col1 - - col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3087
SELECT DISTINCT + col1 / col1 - - col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT + ( + tab0.col2 ) + col0 + - col0 * + 33 AS col1 FROM tab0
----
-1119
-2766
-735

query I rowsort
SELECT - col2 + 15 FROM tab0 AS cor0
----
-18
-67
14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 68 * - col0 + + col1 * 42 col1 FROM tab0 AS cor0
----
-2230
1694
1980

query I rowsort
SELECT - + 48 AS col1 FROM tab2 AS cor0
----
-48
-48
-48

query I rowsort
SELECT ALL - col0 * + col2 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT ( ( col2 ) ) + + ( - col0 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL + + 5 + 42 AS col0 FROM tab2 AS cor0
----
47
47
47

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( cor0.col2 AS REAL ) * col1 + - cor0.col1 FROM tab0 cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL + cor0.col0 + - ( + col0 ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor1.col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-3098
SELECT + ( - col0 ) * col0 - + ( cor0.col0 ) DIV + col1 AS col2 FROM tab1 AS cor0
----
-4102
-6406
-9

skipif mysql # not compatible
query I rowsort label-3098
SELECT + ( - col0 ) * col0 - + ( cor0.col0 ) / + col1 AS col2 FROM tab1 AS cor0
----
-4102
-6406
-9

query I rowsort
SELECT cor0.col1 AS col1 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3100
SELECT DISTINCT - + ( + col2 ) + + col0 * + CAST( - 73 AS SIGNED ) FROM tab2 AS cor0
----
-538
-5720
-5805

skipif mysql # not compatible
query I rowsort label-3100
SELECT DISTINCT - + ( + col2 ) + + col0 * + CAST ( - 73 AS INTEGER ) FROM tab2 AS cor0
----
-538
-5720
-5805

query I rowsort
SELECT DISTINCT - 19 + + cor0.col1 FROM tab0, tab0 AS cor0
----
67
72
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3102
SELECT ALL + ( col1 * - col1 ) + + ( col2 ) DIV col0 col1 FROM tab2
----
-289
-3481
-958

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3102
SELECT ALL + ( col1 * - col1 ) + + ( col2 ) / col0 col1 FROM tab2
----
-289
-3481
-958

query I rowsort
SELECT DISTINCT + - 81 * 61 + col2 AS col1 FROM tab1 AS cor0
----
-4845
-4884
-4887

onlyif mysql # use DIV operator for integer division
query I rowsort label-3104
SELECT ALL + - 99 + 6 * + col2 - - col2 DIV + col2 FROM tab1 AS cor0
----
226
244
478

skipif mysql # not compatible
query I rowsort label-3104
SELECT ALL + - 99 + 6 * + col2 - - col2 / + col2 FROM tab1 AS cor0
----
226
244
478

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3105
SELECT + CAST( col0 AS SIGNED ) + - col0 * + 66 * + col2 FROM tab0 AS cor0
----
-2275
-481579
-52248

skipif mysql # not compatible
query I rowsort label-3105
SELECT + CAST ( col0 AS INTEGER ) + - col0 * + 66 * + col2 FROM tab0 AS cor0
----
-2275
-481579
-52248

query I rowsort
SELECT ALL + + col0 * - col0 + cor0.col0 + + col2 * col2 FROM tab2 AS cor0
----
-4718
-5330
687

query I rowsort
SELECT DISTINCT - + col0 - + 15 * - cor0.col1 FROM tab0 AS cor0
----
1266
1276
1420

query I rowsort
SELECT + 58 * + 23 AS col0 FROM tab2 AS cor0
----
1334
1334
1334

query I rowsort
SELECT + col1 + 21 AS col0 FROM tab2 AS cor0
----
38
52
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3110
SELECT DISTINCT + CAST( col2 AS SIGNED ) * col2 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-3110
SELECT DISTINCT + CAST ( col2 AS INTEGER ) * col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-3111
SELECT - cor0.col1 + + cor0.col2 DIV - cor0.col2 AS col0 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-3111
SELECT - cor0.col1 + + cor0.col2 / - cor0.col2 AS col0 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT ALL + - col0 * 33 AS col0 FROM tab0 AS cor0
----
-1155
-2937
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3113
SELECT DISTINCT - cor0.col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3113
SELECT DISTINCT - cor0.col0 / + col0 AS col1 FROM tab1 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col2 * + col0 - cor0.col1 col1 FROM tab2 cor0
----
131
1943
2947

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + - col1 * - cor0.col1 col2 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT + col0 + col1 * 79 FROM tab1 AS cor0
----
1107
2057
854

onlyif mysql # use DIV operator for integer division
query I rowsort label-3117
SELECT col2 * - col2 * + ( 8 ) + - col2 DIV - col1 FROM tab2 cor0
----
-11550
-5408
-5832

skipif mysql # not compatible
query I rowsort label-3117
SELECT col2 * - col2 * + ( 8 ) + - col2 / - col1 FROM tab2 cor0
----
-11550
-5408
-5832

query I rowsort
SELECT ALL ( + col0 ) + ( + 15 + + col0 ) AS col2 FROM tab2 AS cor0
----
171
173
29

query I rowsort
SELECT - 59 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 582c5aa5e5b4fc3f2ea27e7637992d1f

query I rowsort
SELECT + col1 * - col0 + - ( + col1 + - col0 ) * col2 AS col0 FROM tab2 AS cor0
----
-4108
-865
1013

query I rowsort
SELECT ( - ( col1 ) ) + - 46 * + col2 * col2 + - col0 AS col1 FROM tab1
----
-134165
-149528
-424029

query I rowsort
SELECT ALL - 47 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

query I rowsort
SELECT + + col1 * 52 FROM tab0 AS cor0
----
4472
4732
5044

query I rowsort
SELECT DISTINCT col1 + + 72 AS col0 FROM tab0 AS cor0
----
158
163
169

query I rowsort
SELECT DISTINCT + - col1 * - col1 + + 87 FROM tab1 cor0
----
187
256
763

query I rowsort
SELECT DISTINCT col0 + ( + col1 ) * + col0 FROM tab1 AS cor0
----
1120
704
81

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab0 AS cor1, tab2, tab1 cor2
----
3645 values hashing to 7ccb6e2515d95809a8c30b73a5cf5f46

query I rowsort
SELECT + 94 FROM tab2, tab1 cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT DISTINCT - col1 * - ( 79 ) AS col0 FROM tab1
----
1027
2054
790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 99 col0 FROM tab1
----
1287
2574
990

query I rowsort
SELECT + col2 * + 46 FROM tab1 AS cor0
----
2484
2622
4416

query I rowsort
SELECT + ( col1 ) + + col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - 16 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

query I rowsort
SELECT col1 * - col2 + + 21 AS col1 FROM tab1
----
-1227
-1383
-549

query I rowsort
SELECT ALL - col0 * col0 * - col1 AS col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT + cor0.col2 * + col1 + col0 * - col2 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT col2 * ( col0 * - col2 ) AS col2 FROM tab0 AS cor0
----
-26136
-35
-598436

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3138
SELECT cor0.col2 + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-3138
SELECT cor0.col2 + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col1 + - col1 * - col0 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3140
SELECT - - CAST( col0 AS SIGNED ) + col1 * ( + col0 ) AS col1 FROM tab0 AS cor0
----
2088
3430
8188

skipif mysql # not compatible
query I rowsort label-3140
SELECT - - CAST ( col0 AS INTEGER ) + col1 * ( + col0 ) AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + 80 AS col1 FROM tab0 cor0
----
80
80
80

query I rowsort
SELECT ALL cor0.col0 * + col1 + + col0 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3143
SELECT - CAST( NULL AS SIGNED ) * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3143
SELECT - CAST ( NULL AS INTEGER ) * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 + col2 AS col2 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT + 5 * - col2 - col1 FROM tab1 AS cor0
----
-295
-296
-493

query I rowsort
SELECT - + col2 + + col0 + - 14 FROM tab1 AS cor0
----
-30
-65
-7

query I rowsort
SELECT ALL ( + col2 ) + tab1.col2 + - col1 FROM tab1
----
104
179
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3148
SELECT CAST( NULL AS SIGNED ) * + col1 * + tab1.col1 + + CAST( + col1 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-3148
SELECT CAST ( NULL AS INTEGER ) * + col1 * + tab1.col1 + + CAST ( + col1 AS INTEGER ) col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3149
SELECT 64 * col0 * - col1 + col0 DIV cor0.col2 col0 FROM tab1 cor0
----
-40959
-4992
-66560

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3149
SELECT 64 * col0 * - col1 + col0 / cor0.col2 col0 FROM tab1 cor0
----
-40959
-4992
-66560

query I rowsort
SELECT ALL - 15 AS col0 FROM tab2
----
-15
-15
-15

query I rowsort
SELECT ALL - col1 * - col2 - col0 * col1 * ( cor0.col0 ) FROM tab1 AS cor0
----
-40390
-81952
1170

query I rowsort
SELECT - col0 * - col0 + + col0 AS col1 FROM tab1 AS cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 75 * - col2 col1 FROM tab2
----
1950
2025
2850

query I rowsort
SELECT + col0 - col2 * + col0 * col0 AS col2 FROM tab0 AS cor0
----
-1190
-18984
-649433

query I rowsort
SELECT ALL + col2 * ( 31 ) FROM tab1 AS cor0
----
1674
1767
2976

query I rowsort
SELECT col2 * + col1 + col0 + col2 * ( - col1 + + col2 ) FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL + - 95 + + 30 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 744531575c1b6461ed2916d4940e4d23

query I rowsort
SELECT col1 + - 2 FROM tab0
----
84
89
95

query I rowsort
SELECT + col1 * 55 - col1 FROM tab0
----
4644
4914
5238

query I rowsort
SELECT ALL col0 * col2 + col2 FROM tab1
----
216
3705
7776

query I rowsort
SELECT DISTINCT 79 AS col0 FROM tab0, tab0 AS cor0
----
79

query I rowsort
SELECT + col1 * - 18 + 24 FROM tab1 cor0
----
-156
-210
-444

query I rowsort
SELECT col1 + cor0.col0 + - col1 AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + col2 * 54 AS col0 FROM tab2 cor0
----
-1404
-1458
-2052

query I rowsort
SELECT DISTINCT - col0 * 76 FROM tab1 AS cor0
----
-228
-4864
-6080

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3166
SELECT tab0.col1 * CAST( + 14 AS SIGNED ) * tab0.col0 FROM tab0
----
113386
28896
47530

skipif mysql # not compatible
query I rowsort label-3166
SELECT tab0.col1 * CAST ( + 14 AS INTEGER ) * tab0.col0 FROM tab0
----
113386
28896
47530

query I rowsort
SELECT + 98 AS col1 FROM tab2
----
98
98
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3169
SELECT + + CAST( NULL AS DECIMAL ) * - col1 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3169
SELECT + + CAST ( NULL AS REAL ) * - col1 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 32 - - col0 AS col1 FROM tab0 AS cor0
----
121
56
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-3171
SELECT + - col2 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3171
SELECT + - col2 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 - tab2.col1 * + col1 AS col0 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT col0 * - col0 * col1 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT + + col0 + - col0 + - col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT cor0.col1 + col1 * 0 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 * - col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + col0 - col1 * + ( 6 ) AS col0 FROM tab2 AS cor0
----
-179
-23
-276

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3178
SELECT DISTINCT col1 * + cor0.col1 + - CAST( NULL AS DECIMAL ) * + col2 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3178
SELECT DISTINCT col1 * + cor0.col1 + - CAST ( NULL AS REAL ) * + col2 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + ( col0 ) + col1 * col2 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - + col1 - + col1 * ( - col0 * - col0 ) AS col2 FROM tab0 AS cor0
----
-118922
-49622
-720902

query I rowsort
SELECT ALL col2 * col1 + - 20 AS col1 FROM tab0 AS cor0
----
2818
7442
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3182
SELECT DISTINCT + + col2 * + cor0.col1 + CAST( - 81 AS SIGNED ) FROM tab0 cor0
----
16
2757
7381

skipif mysql # not compatible
query I rowsort label-3182
SELECT DISTINCT + + col2 * + cor0.col1 + CAST ( - 81 AS INTEGER ) FROM tab0 cor0
----
16
2757
7381

query I rowsort
SELECT cor0.col2 * - col0 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL - ( - 3 ) AS col1 FROM tab2 AS cor0
----
3
3
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3185
SELECT DISTINCT - col1 + col1 DIV col1 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-3185
SELECT DISTINCT - col1 + col1 / col1 FROM tab2 AS cor0
----
-16
-30
-58

query I rowsort
SELECT - 72 FROM tab2, tab0 AS cor0
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

query I rowsort
SELECT - 43 * + cor0.col0 + col1 FROM tab2 AS cor0
----
-270
-3295
-3380

query I rowsort
SELECT + ( + cor0.col0 ) + - cor0.col1 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT - col2 + - col0 * col0 AS col2 FROM tab0
----
-1226
-609
-8003

query I rowsort
SELECT ALL col1 + - 34 * col1 AS col1 FROM tab2 AS cor0
----
-1023
-1947
-561

query I rowsort
SELECT ALL + - col1 * 74 + + col2 * 80 FROM tab1 cor0
----
2396
3820
6718

onlyif mysql # use DIV operator for integer division
query I rowsort label-3192
SELECT col2 * cor0.col0 + - col1 - - col2 DIV - col2 FROM tab1 cor0
----
135
3637
7666

skipif mysql # not compatible
query I rowsort label-3192
SELECT col2 * cor0.col0 + - col1 - - col2 / - col2 FROM tab1 cor0
----
135
3637
7666

query I rowsort
SELECT ALL + 33 * + col0 FROM tab0 AS cor0
----
1155
2937
792

query I rowsort
SELECT ALL - tab0.col2 + + col2 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3195
SELECT ALL + - 68 * col0 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3195
SELECT ALL + - 68 * col0 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 * - cor0.col1 + - col1 AS col0 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT - + ( - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT 78 * col2 + col1 AS col1 FROM tab0 AS cor0
----
175
2660
6487

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col1 col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL + 67 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT 80 * tab0.col1 AS col2 FROM tab0
----
6880
7280
7760

query I rowsort
SELECT - col2 * col2 * col0 + 97 * tab2.col0 AS col1 FROM tab2
----
-106413
-4424
-45162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * cor0.col2 col0 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL col2 * + col1 * 99 FROM tab2
----
151866
63954
82863

query I rowsort
SELECT - col2 + 18 FROM tab2 cor0
----
-20
-8
-9

query I rowsort
SELECT + col0 * col2 * + 60 AS col1 FROM tab1 AS cor0
----
218880
460800
9720

query I rowsort
SELECT DISTINCT col1 + - ( col2 ) * - col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + 55 + + col1 AS col2 FROM tab1
----
65
68
81

query I rowsort
SELECT cor0.col2 * - 51 * 57 FROM tab1, tab1 AS cor0
----
9 values hashing to b54bf3b2c1a17bcb43404507954a1de6

query I rowsort
SELECT ALL - 37 + tab0.col0 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 70c0e3a915598760a441644271812d43

query I rowsort
SELECT DISTINCT + 15 * - col1 FROM tab1
----
-150
-195
-390

query I rowsort
SELECT + col0 + - col0 * - col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT DISTINCT + 5 * + 73 * tab0.col2 + 50 FROM tab0, tab1 cor0
----
12095
29980
415

query I rowsort
SELECT + col0 * + tab1.col1 + - col1 * col1 AS col1 FROM tab1
----
-598
540
871

query I rowsort
SELECT DISTINCT + - cor0.col1 + 43 AS col2 FROM tab2 AS cor0
----
-16
12
26

query I rowsort
SELECT ALL - + col0 * + 87 FROM tab2 AS cor0
----
-609
-6786
-6873

onlyif mysql # use DIV operator for integer division
query I rowsort label-3217
SELECT cor0.col0 + col1 DIV + col1 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-3217
SELECT cor0.col0 + col1 / + col1 FROM tab2 AS cor0
----
79
8
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * 84 col2 FROM tab1 AS cor0
----
252
5376
6720

onlyif mysql # use DIV operator for integer division
query I rowsort label-3219
SELECT - + col2 + col1 DIV - col0 AS col0 FROM tab2 AS cor0
----
-26
-31
-38

skipif mysql # not compatible
query I rowsort label-3219
SELECT - + col2 + col1 / - col0 AS col0 FROM tab2 AS cor0
----
-26
-31
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3220
SELECT DISTINCT col1 DIV + 15 FROM tab2
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3220
SELECT DISTINCT col1 / + 15 FROM tab2
----
1
2
3

query I rowsort
SELECT - 55 * col1 FROM tab1 AS cor0
----
-1430
-550
-715

query I rowsort
SELECT DISTINCT + ( 10 ) AS col0 FROM tab2, tab1 AS cor0
----
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-3223
SELECT - - 96 DIV + col0 + col1 AS col1 FROM tab1 AS cor0
----
11
14
58

skipif mysql # not compatible
query I rowsort label-3223
SELECT - - 96 / + col0 + col1 AS col1 FROM tab1 AS cor0
----
11
14
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-3224
SELECT + ( col2 ) DIV col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3224
SELECT + ( col2 ) / col2 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT 33 * + col0 FROM tab1 AS cor0
----
2112
2640
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-3226
SELECT ALL + cor0.col0 + 70 DIV col2 FROM tab1 AS cor0
----
4
65
80

skipif mysql # not compatible
query I rowsort label-3226
SELECT ALL + cor0.col0 + 70 / col2 FROM tab1 AS cor0
----
4
65
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + 10 * - col1 + + col1 col2 FROM tab0 AS cor0
----
-73874
-82719
-93993

onlyif mysql # use DIV operator for integer division
query I rowsort label-3228
SELECT ALL - + ( col1 ) + col1 DIV col0 FROM tab2 cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-3228
SELECT ALL - + ( col1 ) + col1 / col0 FROM tab2 cor0
----
-17
-27
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 32 col2 FROM tab2 AS cor0
----
-32

query I rowsort
SELECT ALL - + col0 * - col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT col0 + + col2 * 48 FROM tab2 AS cor0
----
1303
1326
1903

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3232
SELECT DISTINCT + 19 + - col0 * CAST( + col1 AS SIGNED ) FROM tab0 AS cor0
----
-2045
-3376
-8080

skipif mysql # not compatible
query I rowsort label-3232
SELECT DISTINCT + 19 + - col0 * CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
-2045
-3376
-8080

query I rowsort
SELECT ALL + + col1 + - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 55 + - col2 FROM tab0 AS cor0
----
-137
-56
-88

query I rowsort
SELECT 13 * + col1 FROM tab0 AS cor0
----
1118
1183
1261

query I rowsort
SELECT col1 + + col0 * + 19 AS col0 FROM tab0 AS cor0
----
1782
542
762

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3237
SELECT DISTINCT + col0 * col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3237
SELECT DISTINCT + col0 * col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col2 * col2 + 12 FROM tab0 AS cor0
----
1101
13
6736

query I rowsort
SELECT ALL + + col1 * + col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col1 - - col0 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 59 + + col1 * + col2 col1 FROM tab1 AS cor0
----
1307
1463
629

query I rowsort
SELECT DISTINCT cor0.col2 + ( 37 ) FROM tab1 AS cor0
----
133
91
94

query I rowsort
SELECT DISTINCT + - cor0.col2 * col0 + cor0.col2 + - col2 * col2 AS col2 FROM tab0 AS cor0
----
-13940
-1848
-35

query I rowsort
SELECT - col1 * + 90 AS col0 FROM tab0 AS cor0
----
-7740
-8190
-8730

query I rowsort
SELECT ALL + cor0.col0 + col1 + col1 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT + 10 FROM tab2, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT - 24 - col2 FROM tab0 AS cor0
----
-106
-25
-57

query I rowsort
SELECT + + 83 - col0 FROM tab2 AS cor0
----
4
5
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3249
SELECT - CAST( - 69 AS SIGNED ) + col0 * - 94 FROM tab2
----
-589
-7263
-7357

skipif mysql # not compatible
query I rowsort label-3249
SELECT - CAST ( - 69 AS INTEGER ) + col0 * - 94 FROM tab2
----
-589
-7263
-7357

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) * col2 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + - col1 + 37 * - col2 FROM tab2 AS cor0
----
-1021
-1030
-1423

onlyif mysql # use DIV operator for integer division
query I rowsort label-3252
SELECT + col1 DIV col1 + ( - col1 ) * - col0 FROM tab0 AS cor0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-3252
SELECT + col1 / col1 + ( - col1 ) * - col0 FROM tab0 AS cor0
----
2065
3396
8100

query I rowsort
SELECT + ( col0 * - ( ( tab2.col1 ) ) ) AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - 70 + + 88 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 903ac227935c1532300db45a8537c595

query I rowsort
SELECT DISTINCT 31 - - col2 * ( - col0 ) AS col1 FROM tab1 AS cor0
----
-131
-3617
-7649

onlyif mysql # use DIV operator for integer division
query I rowsort label-3256
SELECT DISTINCT - + 58 - - col0 DIV + col0 FROM tab1 AS cor0
----
-57

skipif mysql # not compatible
query I rowsort label-3256
SELECT DISTINCT - + 58 - - col0 / + col0 FROM tab1 AS cor0
----
-57

query I rowsort
SELECT + - col2 * col0 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT 49 AS col2 FROM tab1, tab2 AS cor0
----
49

query I rowsort
SELECT ALL - 41 + 15 AS col2 FROM tab0, tab1 cor0, tab1 cor1
----
27 values hashing to 4e49eac022daeae6f88f610644ba3754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3260
SELECT 35 * + cor0.col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3260
SELECT 35 * + cor0.col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 39 + - cor0.col2 FROM tab2 AS cor0
----
1
12
13

query I rowsort
SELECT DISTINCT + col0 * + col1 AS col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT col2 * 52 FROM tab1 AS cor0
----
2808
2964
4992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + ( + 56 ) col1 FROM tab2 cor0
----
115
73
87

query I rowsort
SELECT DISTINCT - col1 - - col1 AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3266
SELECT - - col1 + + 72 * col0 DIV col1 FROM tab0 AS cor0
----
106
122
161

skipif mysql # not compatible
query I rowsort label-3266
SELECT - - col1 + + 72 * col0 / col1 FROM tab0 AS cor0
----
106
122
161

query I rowsort
SELECT - 40 - cor0.col0 FROM tab0 cor0
----
-129
-64
-75

query I rowsort
SELECT - + cor0.col2 + - col0 * + col2 AS col1 FROM tab2 cor0
----
-2054
-216
-3040

query I rowsort
SELECT ALL - 64 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 100c625e45715c20368551989514ba64

query I rowsort
SELECT ALL tab2.col0 * - cor0.col1 + 72 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 3a87c2c6ae8a3d9999daa77ef108702f

query I rowsort
SELECT ALL 76 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT ALL + 58 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT col1 * 53 FROM tab1
----
1378
530
689

query I rowsort
SELECT DISTINCT - col0 + ( + col1 ) * + col1 AS col1 FROM tab0
----
7372
8192
9374

query I rowsort
SELECT - + cor0.col1 FROM tab1, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT DISTINCT - col0 * - ( + col2 ) FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - cor0.col1 * cor0.col1 col0 FROM tab0 cor0
----
-636056
-753571
-912673

query I rowsort
SELECT ALL - + col2 + - 63 * col0 FROM tab1 AS cor0
----
-243
-4089
-5136

query I rowsort
SELECT ALL - cor1.col1 + + cor0.col0 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to df1b03e43943ab224f201d4f68bf1b1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( tab0.col1 + + col0 ) * col2 col1 FROM tab0
----
132
14760
3630

query I rowsort
SELECT + ( - 49 ) AS col0 FROM tab2
----
-49
-49
-49

query I rowsort
SELECT ALL + + col0 - - col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + 22 * - col2 AS col2 FROM tab1 AS cor0
----
-1188
-1254
-2112

query I rowsort
SELECT ALL + col2 * + col0 + col1 * 8 FROM tab1 AS cor0
----
370
3728
7784

query I rowsort
SELECT + + 97 + cor0.col0 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
1322
673
8018

query I rowsort
SELECT - 38 * - tab0.col1 * col0 + 38 AS col0 FROM tab0
----
129048
307800
78470

query I rowsort
SELECT tab1.col1 * col0 * - col0 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT + 68 + ( col2 ) + - col1 * col2 AS col2 FROM tab2
----
-1440
-540
-742

query I rowsort
SELECT - col2 * + tab1.col2 + col1 * + col2 + - ( col1 ) AS col1 FROM tab1
----
-1538
-2689
-7981

query I rowsort
SELECT col2 + - cor0.col0 * cor0.col0 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3291
SELECT + ( col0 + CAST( col0 AS SIGNED ) ) FROM tab0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-3291
SELECT + ( col0 + CAST ( col0 AS INTEGER ) ) FROM tab0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-3292
SELECT DISTINCT 97 + col0 DIV 62 + 42 DIV + col0 FROM tab1
----
111
98

skipif mysql # not compatible
query I rowsort label-3292
SELECT DISTINCT 97 + col0 / 62 + 42 / + col0 FROM tab1
----
111
98

query I rowsort
SELECT - 3 * 69 FROM tab1, tab2 AS cor0
----
9 values hashing to 566853d0755dc9cda45797106ad7864c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col1 col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + col2 + col1 * + cor0.col2 AS col1 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT + - col0 + + col1 * - col0 FROM tab1 cor0
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT col1 * - col1 - col2 FROM tab1 cor0
----
-157
-265
-730

query I rowsort
SELECT ALL ( - tab0.col0 ) FROM tab0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3299
SELECT - col0 * - col0 + CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
1260
600
8010

skipif mysql # not compatible
query I rowsort label-3299
SELECT - col0 * - col0 + CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
1260
600
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 32 * col1 col0 FROM tab0 AS cor0
----
2752
2912
3104

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 58 col0 FROM tab2 AS cor0
----
-58
-58
-58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3302
SELECT ALL - - col0 + CAST( 25 AS SIGNED ) FROM tab2 AS cor0
----
103
104
32

skipif mysql # not compatible
query I rowsort label-3302
SELECT ALL - - col0 + CAST ( 25 AS INTEGER ) FROM tab2 AS cor0
----
103
104
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 * - col0 + col0 col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT col0 + - 72 FROM tab1 cor0
----
-69
-8
8

query I rowsort
SELECT ALL + + col2 - col0 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3306
SELECT DISTINCT + + col2 * + CAST( NULL AS SIGNED ) * - col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3306
SELECT DISTINCT + + col2 * + CAST ( NULL AS INTEGER ) * - col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3307
SELECT ALL + - col2 DIV + col1 + + col1 + col1 AS col1 FROM tab2 AS cor0
----
118
32
62

skipif mysql # not compatible
query I rowsort label-3307
SELECT ALL + - col2 / + col1 + + col1 + col1 AS col1 FROM tab2 AS cor0
----
118
32
62

query I rowsort
SELECT DISTINCT + col0 + - 84 * - col2 FROM tab0 cor0
----
119
2796
6977

query I rowsort
SELECT DISTINCT + + col0 * - col0 + col2 * col1 AS col1 FROM tab2 AS cor0
----
-4550
-5595
788

query I rowsort
SELECT col0 - - 41 AS col0 FROM tab0 AS cor0
----
130
65
76

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 + - cor0.col2 + col0 AS col1 FROM tab0 cor0
----
-7405
-8274
-9375

query I rowsort
SELECT - col0 + - 67 * col0 FROM tab0 AS cor0
----
-1632
-2380
-6052

query I rowsort
SELECT col0 + col2 + 53 * + tab2.col2 AS col1 FROM tab2
----
1465
1482
2131

query I rowsort
SELECT + col2 + col1 + + tab0.col0 FROM tab0
----
133
143
262

query I rowsort
SELECT + 91 * + tab2.col0 AS col2 FROM tab2
----
637
7098
7189

query I rowsort
SELECT DISTINCT col0 - - col1 AS col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT + col2 * - cor0.col0 * col0 - + col2 AS col2 FROM tab0 AS cor0
----
-1226
-19041
-649604

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3318
SELECT ALL CAST( - col2 AS SIGNED ) * - col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-3318
SELECT ALL CAST ( - col2 AS INTEGER ) * - col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + col1 * + 49 AS col0 FROM tab2 AS cor0
----
1519
2891
833

query I rowsort
SELECT DISTINCT col1 * - col1 + col1 AS col2 FROM tab0 AS cor0
----
-7310
-8190
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3321
SELECT - col2 + + 47 * col2 + CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3321
SELECT - col2 + + 47 * col2 + CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col2 * + 34 + col1 FROM tab1 AS cor0
----
-1810
-1928
-3251

onlyif mysql # use DIV operator for integer division
query I rowsort label-3323
SELECT ( - col0 ) + - col0 DIV ( col0 ) FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-3323
SELECT ( - col0 ) + - col0 / ( col0 ) FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT DISTINCT col0 + 43 AS col1 FROM tab2 AS cor0
----
121
122
50

query I rowsort
SELECT DISTINCT cor0.col1 * - 57 - cor0.col2 FROM tab2 AS cor0
----
-1007
-1794
-3389

query I rowsort
SELECT 69 * 74 AS col0 FROM tab2 AS cor0
----
5106
5106
5106

query I rowsort
SELECT DISTINCT + col2 * + ( cor0.col0 ) AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + - 27 * ( col0 + 84 ) FROM tab1 AS cor0
----
-2349
-3996
-4428

onlyif mysql # use DIV operator for integer division
query I rowsort label-3329
SELECT ALL + col2 DIV + col0 AS col2 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-3329
SELECT ALL + col2 / + col0 AS col2 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT ( 8 ) FROM tab0, tab1 AS cor0
----
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3331
SELECT DISTINCT - ( + 58 ) DIV col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3331
SELECT DISTINCT - ( + 58 ) / col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + 64 + - col0 * col2 * + col0 + col1 AS col2 FROM tab2 AS cor0
----
-1228
-158061
-237077

query I rowsort
SELECT ALL col2 + 8 * + col0 FROM tab1 AS cor0
----
569
736
78

query I rowsort
SELECT + - 56 * + col0 + col0 + + col1 AS col0 FROM tab1 AS cor0
----
-139
-3510
-4387

query I rowsort
SELECT ALL + 29 + + 22 FROM tab2 cor0
----
51
51
51

query I rowsort
SELECT - ( - col1 ) + col0 + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1671
742
875

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3337
SELECT ALL - CAST( col0 AS SIGNED ) col1 FROM tab2
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3337
SELECT ALL - CAST ( col0 AS INTEGER ) col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL col1 + - col2 * + 78 FROM tab2 AS cor0
----
-1969
-2075
-2947

query I rowsort
SELECT + - 80 AS col0 FROM tab1 AS cor0
----
-80
-80
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 69 col1 FROM tab0
----
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 col2 FROM tab1 AS cor0
----
67

query I rowsort
SELECT DISTINCT ( 44 ) AS col0 FROM tab1
----
44

query I rowsort
SELECT ( 44 ) * col2 FROM tab0
----
1452
3608
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 61 * col1 col1 FROM tab0
----
-125904
-207095
-494039

query I rowsort
SELECT ALL + 78 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query I rowsort
SELECT + col0 + 67 AS col0 FROM tab0
----
102
156
91

query I rowsort
SELECT - 18 AS col0 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 2dbe09d9295cfd52d854fefabf2cec4e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col1 col2 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 13 col0 FROM tab2
----
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-3350
SELECT DISTINCT col1 + col1 DIV - ( - ( + col1 ) ) AS col2 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3350
SELECT DISTINCT col1 + col1 / - ( - ( + col1 ) ) AS col2 FROM tab0 AS cor0
----
87
92
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3351
SELECT ALL + cor0.col1 + col2 * 14 DIV col0 AS col1 FROM tab1 cor0
----
22
278
29

skipif mysql # not compatible
query I rowsort label-3351
SELECT ALL + cor0.col1 + col2 * 14 / col0 AS col1 FROM tab1 cor0
----
22
278
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3352
SELECT + + col2 * cor0.col0 + + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3352
SELECT + + col2 * cor0.col0 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3353
SELECT + CAST( cor1.col1 AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

skipif mysql # not compatible
query I rowsort label-3353
SELECT + CAST ( cor1.col1 AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 cor1, tab0, tab1 AS cor2
----
3645 values hashing to f9101173abc9e524c6310e6c0eeefb0c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3355
SELECT + col0 * cor0.col2 + col0 - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3355
SELECT + col0 * cor0.col2 + col0 - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 + - col0 + ( - col2 ) * - col0 FROM tab1 AS cor0
----
213
3641
7696

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 38 col1 FROM tab1
----
102
118
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3358
SELECT + CAST( 60 AS SIGNED ) col2 FROM tab0 AS cor0
----
60
60
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3358
SELECT + CAST ( 60 AS INTEGER ) col2 FROM tab0 AS cor0
----
60
60
60

query I rowsort
SELECT 61 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3360
SELECT ALL - - CAST( NULL AS SIGNED ) + 24 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3360
SELECT ALL - - CAST ( NULL AS INTEGER ) + 24 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - ( + col0 ) * col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL + 17 * tab0.col0 FROM tab0
----
1513
408
595

query I rowsort
SELECT ALL - + col1 * + col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + 77 + col1 * col0 AS col0 FROM tab1 AS cor0
----
1117
155
717

query I rowsort
SELECT - col1 + + 94 + col2 * ( 93 ) AS col1 FROM tab0 cor0
----
3077
7629
90

query I rowsort
SELECT + 47 + ( + col2 ) * 32 AS col0 FROM tab2 AS cor0
----
1263
879
911

query I rowsort
SELECT ALL - 46 * + col0 + + col0 FROM tab0 cor0
----
-1080
-1575
-4005

query I rowsort
SELECT DISTINCT + col0 + 73 + - col2 AS col0 FROM tab0 AS cor0
----
107
64
80

query I rowsort
SELECT DISTINCT + col0 * + 74 + cor0.col1 AS col1 FROM tab1 AS cor0
----
248
4746
5933

onlyif mysql # use DIV operator for integer division
query I rowsort label-3371
SELECT + - 30 DIV + col2 + - col2 FROM tab0 AS cor0
----
-31
-33
-82

skipif mysql # not compatible
query I rowsort label-3371
SELECT + - 30 / + col2 + - col2 FROM tab0 AS cor0
----
-31
-33
-82

query I rowsort
SELECT col2 * 55 * 21 AS col2 FROM tab2 AS cor0
----
30030
31185
43890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3373
SELECT DISTINCT + - col1 + CAST( + col2 AS SIGNED ) col1 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3373
SELECT DISTINCT + - col1 + CAST ( + col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - + cor0.col1 * cor0.col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - col2 * 18 FROM tab2 AS cor0
----
-468
-486
-684

query I rowsort
SELECT col0 - cor0.col0 * col1 * - col2 FROM tab1 cor0
----
36544
4215
99920

onlyif mysql # use DIV operator for integer division
query I rowsort label-3377
SELECT col2 DIV + col1 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3377
SELECT col2 / + col1 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - col0 * col1 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 0 col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ( - col2 ) AS col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - col0 - 71 FROM tab0
----
-106
-160
-95

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + col2 * - 54 + 46 FROM tab1
----
-2870
-3032
-5138

onlyif mysql # use DIV operator for integer division
query I rowsort label-3384
SELECT + col1 DIV cor0.col0 - - col0 FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-3384
SELECT + col1 / cor0.col0 - - col0 FROM tab2 AS cor0
----
11
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3385
SELECT col1 DIV + 23 col1 FROM tab2 AS cor0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3385
SELECT col1 / + 23 col1 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT - col2 * 13 AS col1 FROM tab0 AS cor0
----
-1066
-13
-429

query I rowsort
SELECT ( + col2 + - tab2.col2 ) AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + 9 FROM tab0
----
9

query I rowsort
SELECT + 15 * + tab1.col2 + col2 AS col2 FROM tab1
----
1536
864
912

query I rowsort
SELECT DISTINCT 51 * col2 FROM tab0
----
1683
4182
51

query I rowsort
SELECT - 19 + 70 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT - - 36 AS col2 FROM tab2 AS cor0
----
36
36
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 - + col1 col2 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3394
SELECT DISTINCT + col0 * + col2 DIV - col2 + col2 * col2 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

skipif mysql # not compatible
query I rowsort label-3394
SELECT DISTINCT + col0 * + col2 / - col2 + col2 * col2 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT + 9 AS col0 FROM tab1 cor0
----
9

query I rowsort
SELECT ALL - col1 + col0 * col0 - col2 FROM tab1 AS cor0
----
-71
4029
6291

query I rowsort
SELECT DISTINCT - - cor0.col1 * + col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT 8 + - col0 + col0 AS col2 FROM tab2 AS cor0
----
8
8
8

query I rowsort
SELECT - 5 AS col0 FROM tab0 cor0
----
-5
-5
-5

query I rowsort
SELECT col0 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3401
SELECT 54 DIV + cor0.col0 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

skipif mysql # not compatible
query I rowsort label-3401
SELECT 54 / + cor0.col0 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

query I rowsort
SELECT ( col2 ) * + col0 * + col2 + col2 AS col0 FROM tab1 AS cor0
----
207993
737376
8802

query I rowsort
SELECT + - col0 + ( col0 + cor0.col0 ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + + 61 + - col1 * cor0.col0 AS col2 FROM tab1 AS cor0
----
-17
-579
-979

query I rowsort
SELECT DISTINCT + 48 * + ( - col0 ) + col0 * tab0.col1 FROM tab0
----
1715
3827
912

query I rowsort
SELECT DISTINCT + ( - 43 ) * col1 FROM tab0 AS cor0
----
-3698
-3913
-4171

onlyif mysql # use DIV operator for integer division
query I rowsort label-3407
SELECT ALL col0 DIV + 43 AS col0 FROM tab0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-3407
SELECT ALL col0 / + 43 AS col0 FROM tab0
----
0
0
2

query I rowsort
SELECT col1 + - 23 AS col1 FROM tab1 AS cor0
----
-10
-13
3

query I rowsort
SELECT ALL - - col1 + + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT 99 + - col2 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
-6625
-990
98

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-3412
SELECT ALL - 74 * - col0 + + col1 DIV + col1 + + col2 * col2 FROM tab0 AS cor0
----
13311
2592
2866

skipif mysql # not compatible
query I rowsort label-3412
SELECT ALL - 74 * - col0 + + col1 / + col1 + + col2 * col2 FROM tab0 AS cor0
----
13311
2592
2866

query I rowsort
SELECT DISTINCT - 22 * - col1 * - cor0.col1 - col0 AS col0 FROM tab0 AS cor0
----
-162736
-182271
-207033

query I rowsort
SELECT DISTINCT 46 + col1 AS col2 FROM tab0 AS cor0
----
132
137
143

query I rowsort
SELECT ALL col2 * + col1 + cor0.col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT col2 + + 71 AS col2 FROM tab0
----
104
153
72

query I rowsort
SELECT DISTINCT col2 * col2 * + col1 + + col0 + - col2 * + col2 AS col0 FROM tab2
----
21877
23183
39286

query I rowsort
SELECT + col1 * tab1.col2 + col1 AS col0 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL 17 * 69 + col0 AS col2 FROM tab0
----
1197
1208
1262

query I rowsort
SELECT col0 + 34 * col1 FROM tab1
----
404
522
887

query I rowsort
SELECT DISTINCT col0 + - ( + tab0.col2 ) FROM tab0
----
-9
34
7

query I rowsort
SELECT + 14 FROM tab2, tab0 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT - ( - col0 ) * - col1 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col1 + - col1 * + tab2.col0 AS col0 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT ALL col1 + + ( col2 + col2 * - tab0.col1 ) FROM tab0
----
-2719
-7289
1

query I rowsort
SELECT ALL + 62 + - col2 AS col0 FROM tab2
----
24
35
36

query I rowsort
SELECT + col0 + + ( - col0 ) * - col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT - 37 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) col0 FROM tab1
----
3
64
80

query I rowsort
SELECT + - 37 * cor0.col0 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 4800f04ebcb1e3ae4b843b3142272ea7

query I rowsort
SELECT DISTINCT + 17 FROM tab1, tab2 AS cor0
----
17

query I rowsort
SELECT ALL col2 * 57 AS col1 FROM tab0
----
1881
4674
57

query I rowsort
SELECT DISTINCT 79 * - 23 AS col2 FROM tab2
----
-1817

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 90 + ( col2 ) col1 FROM tab2 AS cor0
----
116
117
128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 61 col2 FROM tab2 AS cor0
----
-61
-61
-61

query I rowsort
SELECT ALL + - ( + 86 ) AS col0 FROM tab0 AS cor0
----
-86
-86
-86

query I rowsort
SELECT ALL - - 0 * + col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 col2 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT - 35 * + 69 * + col1 FROM tab2 AS cor0
----
-142485
-41055
-74865

query I rowsort
SELECT DISTINCT - col1 + 7 AS col2 FROM tab2 AS cor0
----
-10
-24
-52

query I rowsort
SELECT DISTINCT + col0 * + 54 FROM tab2 AS cor0
----
378
4212
4266

query I rowsort
SELECT 8 FROM tab0 cor0
----
8
8
8

query I rowsort
SELECT DISTINCT - col0 + - col1 * col0 FROM tab2
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT col0 + + col1 * - 14 FROM tab2
----
-159
-427
-748

query I rowsort
SELECT + col0 * tab1.col0 + + col2 * + col0 + col2 AS col2 FROM tab1
----
14176
225
7801

onlyif mysql # use DIV operator for integer division
query I rowsort label-3446
SELECT col1 DIV - col2 + - col1 * 21 FROM tab0
----
-1808
-1912
-2134

skipif mysql # not compatible
query I rowsort label-3446
SELECT col1 / - col2 + - col1 * 21 FROM tab0
----
-1808
-1912
-2134

query I rowsort
SELECT DISTINCT col0 + cor0.col2 * col0 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3448
SELECT DISTINCT col2 * col1 + 0 DIV 65 AS col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-3448
SELECT DISTINCT col2 * col1 + 0 / 65 AS col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3449
SELECT DISTINCT - col0 * col2 + CAST( col2 AS SIGNED ) * col1 FROM tab1
----
-3078
-6432
1242

skipif mysql # not compatible
query I rowsort label-3449
SELECT DISTINCT - col0 * col2 + CAST ( col2 AS INTEGER ) * col1 FROM tab1
----
-3078
-6432
1242

query I rowsort
SELECT ALL - col1 * col2 + 18 * 5 * col0 AS col2 FROM tab1 AS cor0
----
-1134
5190
5952

query I rowsort
SELECT ALL - - 34 + + col2 FROM tab2 AS cor0
----
60
61
72

query I rowsort
SELECT - + col2 + 28 * cor0.col0 FROM tab1 cor0
----
1735
2144
30

query I rowsort
SELECT ALL - + col1 * - ( - col2 ) + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-3454
SELECT ALL cor0.col2 * col2 DIV - 98 AS col1 FROM tab1 AS cor0
----
-29
-33
-94

skipif mysql # not compatible
query I rowsort label-3454
SELECT ALL cor0.col2 * col2 / - 98 AS col1 FROM tab1 AS cor0
----
-29
-33
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3455
SELECT - col2 DIV 16 FROM tab1 AS cor0
----
-3
-3
-6

skipif mysql # not compatible
query I rowsort label-3455
SELECT - col2 / 16 FROM tab1 AS cor0
----
-3
-3
-6

query I rowsort
SELECT cor0.col1 * - 84 + col0 AS col1 FROM tab1 AS cor0
----
-1012
-2181
-776

query I rowsort
SELECT - cor0.col0 + - ( + col1 ) AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL + col2 + - 55 AS col1 FROM tab1 AS cor0
----
-1
2
41

query I rowsort
SELECT ALL + 39 + col1 FROM tab0
----
125
130
136

query I rowsort
SELECT ALL cor0.col2 + + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-3461
SELECT DISTINCT - col2 DIV + CAST( col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3461
SELECT DISTINCT - col2 / + CAST ( col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - + col1 * - ( + col2 ) + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT col2 * + ( col1 ) + + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + col1 * - col0 + + 76 * - col2 FROM tab2 AS cor0
----
-2269
-4231
-6578

query I rowsort
SELECT ALL + 5 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT + col2 + + ( cor0.col0 + col0 ) * - cor0.col2 FROM tab0 AS cor0
----
-14514
-1551
-69

query I rowsort
SELECT + cor0.col2 + 62 FROM tab2 AS cor0
----
100
88
89

query I rowsort
SELECT + col0 + - col0 * + col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - + ( - col0 ) + cor0.col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col2 + ( col0 ) * 4 FROM tab1 AS cor0
----
313
416
66

query I rowsort
SELECT col2 + 4 * col1 AS col0 FROM tab1 AS cor0
----
148
158
97

query I rowsort
SELECT - col2 * 11 AS col1 FROM tab1
----
-1056
-594
-627

query I rowsort
SELECT + tab0.col0 * 30 + + col2 FROM tab0
----
1051
2752
753

query I rowsort
SELECT + + ( - col2 ) * + col2 AS col0 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - 87 + - col0 + - 93 * + col0 FROM tab2 AS cor0
----
-7419
-745
-7513

query I rowsort
SELECT - col1 * col1 * 44 - col0 FROM tab1 cor0
----
-29747
-4464
-7516

query I rowsort
SELECT ALL - + col0 * + col1 + + 0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - 39 + - col0 AS col1 FROM tab2 AS cor0
----
-117
-118
-46

query I rowsort
SELECT DISTINCT + - col1 - + cor0.col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT + + 34 AS col1 FROM tab1 AS cor0
----
34

query I rowsort
SELECT DISTINCT - + cor0.col2 + + col2 - col0 * cor0.col0 * - col2 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT - col1 + - cor0.col2 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT - 16 * - col2 - col1 FROM tab0 AS cor0
----
-81
1221
442

query I rowsort
SELECT + 77 FROM tab2, tab1 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT + 84 AS col2 FROM tab2
----
84
84
84

query I rowsort
SELECT - col2 + col2 * - cor0.col1 AS col2 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT - + 55 * - col0 AS col0 FROM tab2 AS cor0
----
385
4290
4345

query I rowsort
SELECT - 41 + + 46 FROM tab2
----
5
5
5

query I rowsort
SELECT DISTINCT 16 + - 69 * tab2.col1 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
-1157
-2123
-4055

query I rowsort
SELECT col0 * col0 + + col1 FROM tab0 AS cor0
----
1322
662
8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-3491
SELECT col1 - 77 DIV ( col2 * + col1 + - 80 ) FROM tab0 AS cor0
----
86
91
93

skipif mysql # not compatible
query I rowsort label-3491
SELECT col1 - 77 / ( col2 * + col1 + - 80 ) FROM tab0 AS cor0
----
86
91
93

query I rowsort
SELECT - - col2 * + col1 + - col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT 80 + - col2 * - 80 - - 76 FROM tab0 cor0
----
236
2796
6716

query I rowsort
SELECT ALL col1 + col2 * - 0 FROM tab2
----
17
31
59

query I rowsort
SELECT - + cor0.col0 + col1 * + col1 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT col0 + col0 * cor0.col2 AS col1 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT - 93 * + col1 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
687828
770133
875037

query I rowsort
SELECT + 43 AS col1 FROM tab2 AS cor0
----
43
43
43

query I rowsort
SELECT - col0 * cor0.col2 * 36 AS col1 FROM tab2 cor0
----
-108072
-6804
-73008

query I rowsort
SELECT ALL - 49 AS col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to adfccb10c9468825d9961e3613140f89

query I rowsort
SELECT - + cor0.col1 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col1 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT 63 AS col1 FROM tab2 cor0
----
63

query I rowsort
SELECT - - ( col0 ) + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT 9 AS col1 FROM tab0 AS cor0
----
9

query I rowsort
SELECT + 93 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT DISTINCT + + 78 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
78

query I rowsort
SELECT ALL - col2 * + col1 + col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT 59 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT + col1 * - 43 + + col2 AS col1 FROM tab1 AS cor0
----
-1064
-373
-463

query I rowsort
SELECT col1 * - col1 * - col0 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT - col1 * - cor0.col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT - 12 FROM tab1, tab0 AS cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT ALL + 66 FROM tab0, tab1, tab2 cor0, tab1 AS cor1
----
81 values hashing to dc112f70fecc29a6e605a39541192f43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3515
SELECT + CAST( NULL AS SIGNED ) + + col1 * col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3515
SELECT + CAST ( NULL AS INTEGER ) + + col1 * col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + - tab0.col0 * + col0 AS col2 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT + - cor0.col2 * + col2 * - col2 + + ( - 12 ) * col2 AS col1 FROM tab1 cor0
----
156816
184509
883584

query I rowsort
SELECT 48 * + col2 AS col1 FROM tab0 AS cor0
----
1584
3936
48

query I rowsort
SELECT + - cor0.col2 * - col0 + + col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT 96 + ( + col0 + - col2 ) FROM tab0 AS cor0
----
103
130
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3521
SELECT + CAST( NULL AS SIGNED ) * + 36 + col0 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3521
SELECT + CAST ( NULL AS INTEGER ) * + 36 + col0 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( col0 ) + + col1 FROM tab1
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 58 * cor0.col0 + + col2 * col2 * + col1 col0 FROM tab1 AS cor0
----
124448
36202
75990

query I rowsort
SELECT ALL ( col1 ) * + tab1.col1 * - col1 FROM tab1
----
-1000
-17576
-2197

query I rowsort
SELECT ALL + 93 * cor0.col2 AS col2 FROM tab1 AS cor0
----
5022
5301
8928

query I rowsort
SELECT - - 44 + col1 * + 93 FROM tab0 AS cor0
----
8042
8507
9065

query I rowsort
SELECT DISTINCT + col2 + col0 * col0 FROM tab0 cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-3528
SELECT ALL + cor0.col0 DIV col0 + + col2 AS col0 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-3528
SELECT ALL + cor0.col0 / col0 + + col2 AS col0 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT DISTINCT + ( + col2 ) * - ( 59 ) + col0 AS col2 FROM tab0 AS cor0
----
-1923
-24
-4749

query I rowsort
SELECT + 77 + col2 AS col0 FROM tab1 AS cor0
----
131
134
173

onlyif mysql # use DIV operator for integer division
query I rowsort label-3531
SELECT ALL col0 - col0 DIV col0 col0 FROM tab2
----
6
77
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3531
SELECT ALL col0 - col0 / col0 col0 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort
SELECT ALL col0 * CAST ( - col0 AS REAL ) * tab2.col0 - - col0 AS col2 FROM tab2
----
-336
-474474
-492960

query I rowsort
SELECT ALL tab0.col1 - + col1 * col0 AS col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - col1 - 59 AS col1 FROM tab0
----
-145
-150
-156

query I rowsort
SELECT tab0.col2 * 2 FROM tab0, tab2 AS cor0
----
9 values hashing to e5ee086d16e1b2450d3f7ac8d26a0f7b

onlyif mysql # use DIV operator for integer division
query I rowsort label-3536
SELECT ALL + 83 DIV - cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to f114da4c1c4e8114248a55a599eef399

skipif mysql # not compatible
query I rowsort label-3536
SELECT ALL + 83 / - cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to f114da4c1c4e8114248a55a599eef399

onlyif mysql # use DIV operator for integer division
query I rowsort label-3537
SELECT - col2 * - col1 + col0 DIV + cor0.col2 AS col0 FROM tab0 cor0
----
132
2838
7463

skipif mysql # not compatible
query I rowsort label-3537
SELECT - col2 * - col1 + col0 / + cor0.col2 AS col0 FROM tab0 cor0
----
132
2838
7463

query I rowsort
SELECT ALL + col2 + - ( + col2 ) * col1 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT + col1 + - col0 * + 42 FROM tab0 AS cor0
----
-1373
-3647
-922

onlyif mysql # use DIV operator for integer division
query I rowsort label-3540
SELECT DISTINCT 33 DIV col2 + col2 AS col0 FROM tab0 AS cor0
----
34
82

skipif mysql # not compatible
query I rowsort label-3540
SELECT DISTINCT 33 / col2 + col2 AS col0 FROM tab0 AS cor0
----
34
82

query I rowsort
SELECT - ( col2 ) * col0 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT ALL + + col0 * col2 * col0 + 39 AS col0 FROM tab1 AS cor0
----
233511
525
614439

query I rowsort
SELECT ALL - - 60 * col0 FROM tab2 AS cor0
----
420
4680
4740

query I rowsort
SELECT ALL + 36 + + 84 + - col2 * 76 AS col0 FROM tab0 AS cor0
----
-2388
-6112
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3545
SELECT - - CAST( NULL AS DECIMAL ) + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3545
SELECT - - CAST ( NULL AS REAL ) + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 7 + + col1 AS col2 FROM tab2 AS cor0
----
24
38
66

query I rowsort
SELECT DISTINCT - 0 * col2 * col0 + - ( + col2 ) + cor0.col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + ( + col0 ) + - col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT 89 - - 10 FROM tab2 AS cor0
----
99

query I rowsort
SELECT - 72 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col2 * - col2 col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT col0 + col0 + col1 * col0 FROM tab2 AS cor0
----
1501
231
4758

query I rowsort
SELECT col0 * tab2.col0 + col0 - col1 AS col2 FROM tab2
----
25
6103
6303

onlyif mysql # use DIV operator for integer division
query I rowsort label-3554
SELECT DISTINCT + col0 + + col2 DIV + col0 AS col0 FROM tab0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-3554
SELECT DISTINCT + col0 + + col2 / + col0 AS col0 FROM tab0
----
25
35
89

query I rowsort
SELECT DISTINCT - tab0.col1 + - tab0.col2 * tab0.col2 FROM tab0
----
-1175
-6815
-98

query I rowsort
SELECT DISTINCT + col0 * tab1.col1 + col2 AS col0 FROM tab1
----
1136
132
697

query I rowsort
SELECT tab2.col1 FROM tab2 WHERE NOT NULL IN ( col2 - + col1 )
----

query I rowsort
SELECT col1 * tab0.col0 * - col1 + - col2 AS col2 FROM tab0
----
-177537
-329316
-737091

query I rowsort
SELECT DISTINCT + col1 + col0 * col0 * + col2 AS col0 FROM tab1 AS cor0
----
233482
512
614413

query I rowsort
SELECT ALL + col2 + - col2 * col2 AS col1 FROM tab0
----
-1056
-6642
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3561
SELECT ALL + tab0.col2 * - col0 - - tab0.col0 DIV + col2 AS col2 FROM tab0
----
-7297
-792
0

skipif mysql # not compatible
query I rowsort label-3561
SELECT ALL + tab0.col2 * - col0 - - tab0.col0 / + col2 AS col2 FROM tab0
----
-7297
-792
0

query I rowsort
SELECT ALL col0 * col1 + tab1.col2 - col2 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3563
SELECT col0 DIV - col0 - - col1 * col2 * + col1 AS col1 FROM tab2
----
10981
25946
90505

skipif mysql # not compatible
query I rowsort label-3563
SELECT col0 / - col0 - - col1 * col2 * + col1 AS col1 FROM tab2
----
10981
25946
90505

query I rowsort
SELECT + col2 + tab1.col1 * - col0 FROM tab1
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-3565
SELECT - col1 + cor0.col2 DIV + col0 FROM tab2 AS cor0
----
-17
-28
-59

skipif mysql # not compatible
query I rowsort label-3565
SELECT - col1 + cor0.col2 / + col0 FROM tab2 AS cor0
----
-17
-28
-59

query I rowsort
SELECT ALL - cor0.col2 * + col2 + col0 FROM tab2 AS cor0
----
-1365
-598
-722

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0 WHERE NOT NULL < NULL
----

query I rowsort
SELECT ALL - col0 * col0 - col0 FROM tab1
----
-12
-4160
-6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - col0 * + col1 col1 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT ALL + col1 - col2 AS col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL col0 * + col1 + col2 * + col1 FROM tab1
----
1210
1482
2288

query I rowsort
SELECT ALL - col1 * + col1 AS col2 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - col2 - - col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL cor0.col0 + - col1 AS col0 FROM tab2 cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3575
SELECT col2 * + col1 + - col0 DIV - col2 col2 FROM tab1 AS cor0
----
1248
1404
571

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3575
SELECT col2 * + col1 + - col0 / - col2 col2 FROM tab1 AS cor0
----
1248
1404
571

onlyif mysql # use DIV operator for integer division
query I rowsort label-3576
SELECT ALL - col2 + col2 DIV - col1 FROM tab1 AS cor0
----
-103
-56
-62

skipif mysql # not compatible
query I rowsort label-3576
SELECT ALL - col2 + col2 / - col1 FROM tab1 AS cor0
----
-103
-56
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col2 col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + col1 + col1 * - col0 AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + col2 * col2 + - col1 * cor0.col1 FROM tab1 AS cor0
----
2240
3149
9047

query I rowsort
SELECT ALL col2 * col2 * + col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT - cor0.col2 + col1 + col1 AS col0 FROM tab2 AS cor0
----
-4
35
92

query I rowsort
SELECT - col2 * col1 + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL - + cor0.col0 * col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - cor0.col1 * + cor0.col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + - col2 + - col2 * col1 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT + - col0 + cor0.col0 * col0 * - col0 FROM tab1 AS cor0
----
-262208
-30
-512080

onlyif mysql # use DIV operator for integer division
query I rowsort label-3587
SELECT DISTINCT - 5 + + col2 DIV + 29 AS col1 FROM tab1
----
-2
-4

skipif mysql # not compatible
query I rowsort label-3587
SELECT DISTINCT - 5 + + col2 / + 29 AS col1 FROM tab1
----
-2
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3588
SELECT - col0 DIV + col0 AS col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3588
SELECT - col0 / + col0 AS col2 FROM tab1
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3589
SELECT ( - col2 ) DIV 62 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3589
SELECT ( - col2 ) / 62 FROM tab0
----
-1
0
0

query I rowsort
SELECT col1 * + col1 * 40 AS col0 FROM tab1
----
27040
4000
6760

query I rowsort
SELECT ALL 79 + col2 AS col1 FROM tab0
----
112
161
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 1 * - cor0.col2 col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT 51 + col1 * + col0 FROM tab1 AS cor0
----
1091
129
691

query I rowsort
SELECT col1 * - tab0.col1 AS col0 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - 63 * cor0.col0 FROM tab1 AS cor0
----
-189
-4032
-5040

query I rowsort
SELECT + + col2 + + 12 + + col0 * + cor0.col0 FROM tab1 AS cor0
----
4165
6508
75

query I rowsort
SELECT - col2 + col1 * col2 * + cor0.col0 + - col2 AS col2 FROM tab1 AS cor0
----
36366
4104
99648

query I rowsort
SELECT ALL + col0 * 53 + cor0.col2 AS col1 FROM tab2 cor0
----
398
4160
4225

query I rowsort
SELECT ALL - 9 * col2 + 15 FROM tab0
----
-282
-723
6

query I rowsort
SELECT - col1 * col1 + 62 + + col1 * + col2 AS col0 FROM tab0
----
-4496
-757
-9250

query I rowsort
SELECT col2 * - cor0.col1 + col1 * + col1 AS col2 FROM tab1 AS cor0
----
-1079
-470
-728

query I rowsort
SELECT col0 - ( cor0.col1 + col0 ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query III rowsort
SELECT ALL * FROM tab0 WHERE + col0 NOT IN ( col1 * - col0 + - tab0.col1 + col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col1 col0 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + col0 * col0 + - tab0.col2 * - col0 * col1 FROM tab0
----
4620
672039
68688

query III rowsort
SELECT * FROM tab0 WHERE - col2 = NULL
----

query I rowsort
SELECT DISTINCT + col2 + col1 * - col0 FROM tab1
----
-24
-583
-944

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT BETWEEN NULL AND col0
----

query I rowsort
SELECT ALL col2 + col2 * + col0 AS col1 FROM tab1
----
216
3705
7776

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col0 < + col0
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT col1 - + col1 * col1 AS col0 FROM tab1
----
-156
-650
-90

query I rowsort
SELECT col2 * + col0 + - col2 + + col1 AS col0 FROM tab1
----
134
3601
7597

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT IN ( col1 + + col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 col2 FROM tab1 WHERE NOT ( NULL ) IN ( - col2 )
----

query I rowsort
SELECT DISTINCT - col1 - col0 FROM tab2 WHERE col1 <> ( NULL )
----

query I rowsort
SELECT ALL col0 + - col1 AS col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT tab0.col0 + + col0 * tab0.col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL - col1 FROM tab0 WHERE + col2 NOT IN ( + col0 - col2 * - col1 * tab0.col1 )
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3619
SELECT ALL col0 + tab0.col1 * tab0.col1 DIV + tab0.col0 AS col1 FROM tab0
----
182
303
332

skipif mysql # not compatible
query I rowsort label-3619
SELECT ALL col0 + tab0.col1 * tab0.col1 / + tab0.col0 AS col1 FROM tab0
----
182
303
332

query I rowsort
SELECT - tab2.col1 * - col1 AS col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT col1 + col1 + col2 FROM tab2
----
144
72
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3622
SELECT ALL + tab2.col2 * - CAST( col2 AS SIGNED ) + + col1 * + 5 + - 97 FROM tab2
----
-1456
-478
-671

skipif mysql # not compatible
query I rowsort label-3622
SELECT ALL + tab2.col2 * - CAST ( col2 AS INTEGER ) + + col1 * + 5 + - 97 FROM tab2
----
-1456
-478
-671

query I rowsort
SELECT DISTINCT 70 FROM tab0, tab1 AS cor0
----
70

query I rowsort
SELECT col1 * - col0 + + ( col2 ) * col2 AS col2 FROM tab2
----
-3926
101
512

onlyif mysql # use DIV operator for integer division
query I rowsort label-3625
SELECT - 0 + + col2 DIV col0 AS col1 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-3625
SELECT - 0 + + col2 / col0 AS col1 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT - 76 * - 99 AS col1 FROM tab0 AS cor0
----
7524
7524
7524

onlyif mysql # use DIV operator for integer division
query I rowsort label-3627
SELECT + col1 DIV cor0.col1 col2 FROM tab1 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3627
SELECT + col1 / cor0.col1 col2 FROM tab1 cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3628
SELECT + + ( col0 ) DIV col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-3628
SELECT + + ( col0 ) / col1 FROM tab2 AS cor0
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3629
SELECT + cor0.col0 DIV - col1 AS col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-3629
SELECT + cor0.col0 / - col1 AS col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT + + cor0.col2 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 4 col1 FROM tab1 cor0
----
4
4
4

query I rowsort
SELECT DISTINCT - 54 + - col1 AS col1 FROM tab2 AS cor0
----
-113
-71
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3633
SELECT + CAST( 70 AS SIGNED ) + col0 AS col0 FROM tab1 AS cor0
----
134
150
73

skipif mysql # not compatible
query I rowsort label-3633
SELECT + CAST ( 70 AS INTEGER ) + col0 AS col0 FROM tab1 AS cor0
----
134
150
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 55 + 48 * col1 * + 35 col1 FROM tab2 AS cor0
----
28505
52025
99065

query I rowsort
SELECT - cor0.col0 + cor0.col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL + + 6 + + col1 AS col2 FROM tab2 AS cor0
----
23
37
65

query I rowsort
SELECT DISTINCT col2 * 16 * - col2 AS col0 FROM tab2 AS cor0
----
-10816
-11664
-23104

query I rowsort
SELECT DISTINCT + + 72 * + 78 AS col1 FROM tab1 AS cor0
----
5616

onlyif mysql # use DIV operator for integer division
query I rowsort label-3639
SELECT DISTINCT 82 DIV - ( - col2 ) AS col2 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3639
SELECT DISTINCT 82 / - ( - col2 ) AS col2 FROM tab1 cor0
----
0
1

query I rowsort
SELECT ALL - col2 + 83 FROM tab2 AS cor0
----
45
56
57

query I rowsort
SELECT - col0 * col2 + - 99 AS col2 FROM tab1 AS cor0
----
-261
-3747
-7779

query I rowsort
SELECT col2 * - col1 + 81 AS col2 FROM tab0 AS cor0
----
-16
-2757
-7381

query I rowsort
SELECT - - col0 - - col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + 31 * - col2 + + ( col1 + col2 ) AS col1 FROM tab1 AS cor0
----
-1594
-1700
-2867

query I rowsort
SELECT + ( col0 ) * cor0.col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + - col0 + cor0.col1 * 82 AS col1 FROM tab2 AS cor0
----
1315
2535
4760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3647
SELECT + 97 DIV cor0.col1 - col0 * + col1 FROM tab0 AS cor0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-3647
SELECT + 97 / cor0.col1 - col0 * + col1 FROM tab0 AS cor0
----
-2063
-3394
-8098

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3648
SELECT DISTINCT CAST( NULL AS SIGNED ) + - 41 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3648
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - 41 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + - cor0.col0 + - 8 * - col2 * + col1 AS col2 FROM tab1 AS cor0
----
11229
4496
9904

query I rowsort
SELECT DISTINCT col2 * 31 FROM tab0 AS cor0
----
1023
2542
31

query I rowsort
SELECT col1 * col1 * + cor0.col1 + - col2 FROM tab1 cor0
----
17522
2101
943

query I rowsort
SELECT - + cor0.col0 + + ( + 68 ) AS col2 FROM tab1 AS cor0
----
-12
4
65

query I rowsort
SELECT + 79 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT DISTINCT + col2 * - col1 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL + cor0.col2 + - ( + col1 * - cor0.col1 + - 49 ) AS col2 FROM tab0 AS cor0
----
7478
8412
9459

query I rowsort
SELECT + + cor0.col1 * - col0 + - 70 FROM tab0 cor0
----
-2134
-3465
-8169

query I rowsort
SELECT - col2 * 24 - col2 AS col2 FROM tab0 AS cor0
----
-2050
-25
-825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col0 - + 29 col1 FROM tab1 AS cor0
----
-1069
-107
-669

query I rowsort
SELECT ALL - - cor0.col0 * cor0.col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3660
SELECT - + col2 DIV - ( 76 ) + + col0 * col0 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-3660
SELECT - + col2 / - ( 76 ) + + col0 * col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-3661
SELECT + + col1 * + ( + 97 ) - - col0 DIV - 96 AS col1 FROM tab2 AS cor0
----
1649
3007
5723

skipif mysql # not compatible
query I rowsort label-3661
SELECT + + col1 * + ( + 97 ) - - col0 / - 96 AS col1 FROM tab2 AS cor0
----
1649
3007
5723

query I rowsort
SELECT ALL col2 * + ( col1 ) + + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL col1 * + 38 + - col1 AS col0 FROM tab1 AS cor0
----
370
481
962

query I rowsort
SELECT DISTINCT + col2 - ( col1 ) * - col2 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3665
SELECT cor0.col2 DIV 25 + - 95 FROM tab0, tab1 AS cor0
----
9 values hashing to 6cef77174d12859a3ed2444175f295a0

skipif mysql # not compatible
query I rowsort label-3665
SELECT cor0.col2 / 25 + - 95 FROM tab0, tab1 AS cor0
----
9 values hashing to 6cef77174d12859a3ed2444175f295a0

query I rowsort
SELECT DISTINCT col2 + + 52 AS col2 FROM tab1 AS cor0
----
106
109
148

query I rowsort
SELECT + - cor0.col2 * cor0.col0 + + col1 * col0 FROM tab0 cor0
----
1272
3360
801

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3668
SELECT col1 * CAST( + 57 AS SIGNED ) FROM tab1 AS cor0
----
1482
570
741

skipif mysql # not compatible
query I rowsort label-3668
SELECT col1 * CAST ( + 57 AS INTEGER ) FROM tab1 AS cor0
----
1482
570
741

query I rowsort
SELECT col0 * - cor0.col2 + + 74 * - col0 AS col0 FROM tab2 AS cor0
----
-707
-7800
-8848

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3670
SELECT cor0.col2 / + CAST( NULL AS DECIMAL ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3670
SELECT cor0.col2 / + CAST ( NULL AS REAL ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - 38 + 19 FROM tab1, tab0 AS cor0
----
9 values hashing to 339c9d62143bf2f7566b89a1b56eeeb4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3672
SELECT ALL col2 / + CAST( NULL AS DECIMAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3672
SELECT ALL col2 / + CAST ( NULL AS REAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * 30 FROM tab0 cor0
----
2580
2730
2910

query I rowsort
SELECT col2 * - col1 * 22 + col2 FROM tab1 AS cor0
----
-12483
-27360
-30834

query I rowsort
SELECT ALL col1 * 2 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL + tab2.col1 * + col2 + + 58 AS col0 FROM tab2
----
1592
704
895

query I rowsort
SELECT DISTINCT + cor1.col0 * cor0.col2 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
9 values hashing to d678abade8bf70a0dcfdc79d6219306c

query I rowsort
SELECT ALL col0 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3679
SELECT DISTINCT col0 * col0 + CAST( col1 AS SIGNED ) FROM tab0 cor0
----
1322
662
8012

skipif mysql # not compatible
query I rowsort label-3679
SELECT DISTINCT col0 * col0 + CAST ( col1 AS INTEGER ) FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT - 44 * col0 AS col2 FROM tab2 cor0
----
-308
-3432
-3476

onlyif mysql # use DIV operator for integer division
query I rowsort label-3681
SELECT ALL - - 69 DIV col1 AS col0 FROM tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-3681
SELECT ALL - - 69 / col1 AS col0 FROM tab1 AS cor0
----
2
5
6

query I rowsort
SELECT DISTINCT ( cor0.col2 ) AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
1
33
82

query I rowsort
SELECT 88 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT DISTINCT + col2 + col2 * - col1 - + 4 AS col1 FROM tab1
----
-1156
-1354
-517

query I rowsort
SELECT 12 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT ALL + col2 - col1 * 59 AS col2 FROM tab0
----
-5041
-5287
-5722

onlyif mysql # use DIV operator for integer division
query I rowsort label-3687
SELECT ALL tab1.col1 - col1 DIV + col1 AS col0 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-3687
SELECT ALL tab1.col1 - col1 / + col1 AS col0 FROM tab1
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) + col2 col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL 79 + 27 FROM tab1 cor0
----
106
106
106

query I rowsort
SELECT ALL - - col2 * - 1 + cor0.col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + + 99 FROM tab2 AS cor0
----
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 ) * col2 - - col2 * - col2 col1 FROM tab0 AS cor0
----
-297
34
574

query I rowsort
SELECT + ( 88 ) + - col0 * + col1 FROM tab1 AS cor0
----
-552
-952
10

query I rowsort
SELECT ALL - 82 AS col2 FROM tab0 AS cor0
----
-82
-82
-82

query I rowsort
SELECT ALL + - col0 - col1 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT 86 + col0 * col0 AS col0 FROM tab2 AS cor0
----
135
6170
6327

query I rowsort
SELECT + - col2 - col0 * - col2 AS col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL + + col1 + cor0.col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - + 71 - col2 AS col0 FROM tab0 AS cor0
----
-104
-153
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + 69 + + col2 col1 FROM tab1 AS cor0
----
126
190
245

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3701
SELECT CAST( NULL AS DECIMAL ) + 55 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3701
SELECT CAST ( NULL AS REAL ) + 55 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * - 91 FROM tab1 cor0
----
-273
-5824
-7280

query I rowsort
SELECT + cor0.col1 + 59 FROM tab1 AS cor0
----
69
72
85

query I rowsort
SELECT ALL + ( 32 ) AS col2 FROM tab0 AS cor0
----
32
32
32

query I rowsort
SELECT DISTINCT - - col0 * + col0 - + col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT 2 + cor0.col1 FROM tab1 AS cor0
----
12
15
28

query I rowsort
SELECT + cor0.col2 + - col1 * + ( - ( col2 ) ) FROM tab1 AS cor0
----
1344
1458
627

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 CROSS JOIN tab0, tab1 cor1
----
972 values hashing to 7942394eb7766dfb9ea95b7805ff595d

query I rowsort
SELECT DISTINCT tab1.col0 - + tab1.col1 AS col2 FROM tab1, tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + col2 + + CAST ( - ( + col2 ) AS REAL ) * col2 col0 FROM tab0 cor0
----
-1056
-6642
0

query I rowsort
SELECT ALL - + col0 - + col1 * col2 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-3712
SELECT DISTINCT col2 DIV - 57 + - 4 FROM tab0 AS cor0
----
-4
-5

skipif mysql # not compatible
query I rowsort label-3712
SELECT DISTINCT col2 / - 57 + - 4 FROM tab0 AS cor0
----
-4
-5

query I rowsort
SELECT 85 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

query I rowsort
SELECT DISTINCT - + col2 * 5 FROM tab1 cor0
----
-270
-285
-480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3715
SELECT col2 * - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3715
SELECT col2 * - CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * 2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL + - col1 * col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - col0 * + ( col0 ) AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + ( 2 ) * + col0 + + col0 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT 42 * col1 + cor0.col0 FROM tab2 AS cor0
----
1309
2556
793

query I rowsort
SELECT ALL - col0 - ( + tab0.col1 ) * - col2 FROM tab0
----
2814
62
7373

query I rowsort
SELECT ALL - tab0.col1 * ( col0 + + tab0.col0 ) FROM tab0
----
-16198
-4128
-6790

query I rowsort
SELECT cor0.col1 * 51 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 316bf57050f82302e16098f349a215a2

query I rowsort
SELECT - col0 * col2 * - col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT + ( col1 ) + - col0 * col0 * 91 AS col0 FROM tab0 AS cor0
----
-111378
-52330
-720720

query I rowsort
SELECT ALL cor0.col1 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL tab1.col2 * + 36 FROM tab1
----
1944
2052
3456

query I rowsort
SELECT DISTINCT 18 FROM tab2, tab1 cor0
----
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col0 col2 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3730
SELECT 47 DIV - col2 AS col1 FROM tab0
----
-1
-47
0

skipif mysql # not compatible
query I rowsort label-3730
SELECT 47 / - col2 AS col1 FROM tab0
----
-1
-47
0

query I rowsort
SELECT - ( cor0.col0 ) FROM tab1, tab2 cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 22 + + 42 col2 FROM tab1 AS cor0
----
20
20
20

query I rowsort
SELECT cor1.col1 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL + ( tab2.col0 ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT - 77 * - col0 + col1 AS col1 FROM tab0
----
1934
2792
6944

query I rowsort
SELECT - col2 * - cor0.col1 * + ( 48 * + cor0.col1 ) + 28 * col0 AS col1 FROM tab2 cor0
----
1245652
4346472
529348

query I rowsort
SELECT DISTINCT + col2 + col0 * - cor0.col0 * 98 FROM tab2 AS cor0
----
-4775
-596206
-611580

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 + + col2 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT + 47 FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT DISTINCT col0 + - 89 FROM tab0 AS cor0
----
-54
-65
0

query I rowsort
SELECT - col0 * col0 * 8 FROM tab0 cor0
----
-4608
-63368
-9800

onlyif mysql # use DIV operator for integer division
query I rowsort label-3742
SELECT DISTINCT col2 DIV + 92 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-3742
SELECT DISTINCT col2 / + 92 FROM tab1
----
0
1

query I rowsort
SELECT - col2 + + 2 AS col1 FROM tab2 AS cor0
----
-24
-25
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-3744
SELECT - + col2 DIV + col0 + + col2 AS col0 FROM tab2 AS cor0
----
24
26
38

skipif mysql # not compatible
query I rowsort label-3744
SELECT - + col2 / + col0 + + col2 AS col0 FROM tab2 AS cor0
----
24
26
38

query I rowsort
SELECT ALL 42 * col1 AS col1 FROM tab1
----
1092
420
546

query I rowsort
SELECT tab2.col0 * col1 * col1 AS col2 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT ALL - col0 * col1 * - col2 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-3748
SELECT col2 DIV - 17 AS col2 FROM tab1
----
-3
-3
-5

skipif mysql # not compatible
query I rowsort label-3748
SELECT col2 / - 17 AS col2 FROM tab1
----
-3
-3
-5

query I rowsort
SELECT ALL + + 48 + col2 + col1 * + col1 FROM tab0 AS cor0
----
7477
8411
9458

query I rowsort
SELECT ALL 80 * col1 FROM tab2 AS cor0
----
1360
2480
4720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3751
SELECT + + 28 + cor0.col2 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3751
SELECT + + 28 + cor0.col2 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( col2 ) col0 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL col2 * 19 - + col1 FROM tab1
----
1000
1073
1811

onlyif mysql # use DIV operator for integer division
query I rowsort label-3754
SELECT ALL + col2 DIV tab2.col0 - col1 * + 79 * tab2.col1 FROM tab2
----
-22831
-274999
-75916

skipif mysql # not compatible
query I rowsort label-3754
SELECT ALL + col2 / tab2.col0 - col1 * + 79 * tab2.col1 FROM tab2
----
-22831
-274999
-75916

query I rowsort
SELECT ( - col0 ) + - cor0.col1 * - ( - 39 ) FROM tab1 AS cor0
----
-1017
-454
-587

query I rowsort
SELECT 24 * + col0 + - col0 FROM tab1 AS cor0
----
1472
1840
69

query I rowsort
SELECT ALL tab2.col1 * + ( - tab2.col1 * col0 + + col1 ) AS col1 FROM tab2
----
-22542
-268037
-5766

query I rowsort
SELECT col0 + + col2 * col2 AS col0 FROM tab2
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-3759
SELECT col0 * col1 DIV ( - 32 * - cor0.col1 ) AS col2 FROM tab2 AS cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-3759
SELECT col0 * col1 / ( - 32 * - cor0.col1 ) AS col2 FROM tab2 AS cor0
----
0
2
2

query I rowsort
SELECT ALL - + 20 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query I rowsort
SELECT - - ( + col2 ) * + 69 FROM tab1 AS cor0
----
3726
3933
6624

query I rowsort
SELECT ALL col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + col2 * col1 + - 63 AS col0 FROM tab1 cor0
----
1185
1341
507

onlyif mysql # use DIV operator for integer division
query I rowsort label-3764
SELECT 25 + col2 DIV + col1 + col0 * col2 FROM tab2 AS cor0
----
2053
214
3029

skipif mysql # not compatible
query I rowsort label-3764
SELECT 25 + col2 / + col1 + col0 * col2 FROM tab2 AS cor0
----
2053
214
3029

query I rowsort
SELECT ALL cor0.col2 * - 2 FROM tab1, tab2 AS cor0
----
9 values hashing to 7a2e0645e15b3844a0d89b13fc219077

query I rowsort
SELECT col0 * + col2 - - col0 AS col0 FROM tab0
----
70
7387
816

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 cor2
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

query I rowsort
SELECT + - col0 * + 69 FROM tab2 AS cor0
----
-483
-5382
-5451

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - col1 col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + + cor0.col1 + - col2 + + col1 AS col2 FROM tab1 AS cor0
----
-2
-37
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-3771
SELECT DISTINCT col2 DIV - col0 + + cor0.col1 FROM tab1 AS cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-3771
SELECT DISTINCT col2 / - col0 + + cor0.col1 FROM tab1 AS cor0
----
10
12
8

query I rowsort
SELECT 97 * 14 + col0 FROM tab1 AS cor0
----
1361
1422
1438

query I rowsort
SELECT ALL + - 18 + col1 * col1 AS col1 FROM tab2 cor0
----
271
3463
943

query I rowsort
SELECT DISTINCT col2 + + col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL col2 * col1 - col1 AS col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ( ( col2 ) ) AS col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * col1 - + col0 col1 FROM tab0 AS cor0
----
-132
-2862
-7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-3778
SELECT ALL - - col0 DIV + ( - col1 ) + 52 + - col2 FROM tab2 AS cor0
----
10
25
25

skipif mysql # not compatible
query I rowsort label-3778
SELECT ALL - - col0 / + ( - col1 ) + 52 + - col2 FROM tab2 AS cor0
----
10
25
25

query I rowsort
SELECT + ( - col0 ) - col2 AS col2 FROM tab2
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 0 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + col0 * - 92 FROM tab2 AS cor0
----
-644
-7176
-7268

query I rowsort
SELECT ALL - - col1 * col1 + cor0.col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT + ( - col1 ) * - col2 FROM tab1 cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col1 AS REAL ) * - cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3785
SELECT - cor0.col1 DIV col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-3785
SELECT - cor0.col1 / col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 31 * - 47 col2 FROM tab2 cor0
----
1457

query I rowsort
SELECT - + 66 * 51 FROM tab2 AS cor0
----
-3366
-3366
-3366

query I rowsort
SELECT DISTINCT + 15 * col0 FROM tab0 AS cor0
----
1335
360
525

query I rowsort
SELECT ALL col1 * + col0 + + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + col0 - ( + col1 ) AS col1 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT ALL - col0 * col0 * col0 AS col1 FROM tab0 AS cor0
----
-13824
-42875
-704969

onlyif mysql # use DIV operator for integer division
query I rowsort label-3792
SELECT + - col2 + + col2 DIV - 2 AS col1 FROM tab0 AS cor0
----
-1
-123
-49

skipif mysql # not compatible
query I rowsort label-3792
SELECT + - col2 + + col2 / - 2 AS col1 FROM tab0 AS cor0
----
-1
-123
-49

onlyif mysql # use DIV operator for integer division
query I rowsort label-3793
SELECT DISTINCT col0 * col2 + + col1 DIV col0 + + col1 AS col2 FROM tab1 AS cor0
----
196
3658
7693

skipif mysql # not compatible
query I rowsort label-3793
SELECT DISTINCT col0 * col2 + + col1 / col0 + + col1 AS col2 FROM tab1 AS cor0
----
196
3658
7693

query I rowsort
SELECT ALL - col2 * col2 + + col1 AS col1 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT DISTINCT + + 18 * col0 * + 18 + + col2 * + col2 FROM tab1 AS cor0
----
23985
35136
3888

query I rowsort
SELECT ALL - - col2 - + col1 AS col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT DISTINCT - - col2 * - col2 + - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT DISTINCT - col0 * + col2 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT + tab2.col0 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3800
SELECT 74 + col2 * col1 DIV col2 + ( - col2 ) FROM tab1
----
-9
27
46

skipif mysql # not compatible
query I rowsort label-3800
SELECT 74 + col2 * col1 / col2 + ( - col2 ) FROM tab1
----
-9
27
46

query I rowsort
SELECT DISTINCT tab2.col2 - 69 AS col1 FROM tab2
----
-31
-42
-43

query I rowsort
SELECT DISTINCT + col2 - + col1 * col1 * col1 AS col0 FROM tab1
----
-17522
-2101
-943

onlyif mysql # use DIV operator for integer division
query I rowsort label-3803
SELECT 85 DIV 73 AS col2 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3803
SELECT 85 / 73 AS col2 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT + 25 * - 23 AS col1 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
-575

query I rowsort
SELECT ALL + cor0.col1 + col1 * - 68 FROM tab0 AS cor0
----
-5762
-6097
-6499

query I rowsort
SELECT + col1 + 44 * + col0 * - col2 FROM tab2 AS cor0
----
-132071
-8285
-89173

query I rowsort
SELECT DISTINCT - - col2 - col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ( - tab0.col2 ) AS col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT + tab2.col1 + - col1 * col2 AS col0 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT tab1.col2 * - col1 + col0 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT ALL + + col0 + + col2 + 49 AS col0 FROM tab0 AS cor0
----
106
220
85

query I rowsort
SELECT ALL + + col2 + cor0.col0 * 59 AS col1 FROM tab1 AS cor0
----
231
3833
4816

query I rowsort
SELECT - tab1.col1 + - col0 AS col2 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - 19 * + col1 * col0 AS col1 FROM tab2 AS cor0
----
-25517
-4123
-87438

query I rowsort
SELECT DISTINCT col0 + 35 * col2 FROM tab2 AS cor0
----
1409
952
988

query I rowsort
SELECT ALL col0 * - 64 * col0 FROM tab2 AS cor0
----
-3136
-389376
-399424

onlyif mysql # use DIV operator for integer division
query I rowsort label-3817
SELECT DISTINCT - + col0 DIV 86 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-3817
SELECT DISTINCT - + col0 / 86 FROM tab0 AS cor0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3818
SELECT + col1 DIV + 31 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3818
SELECT + col1 / + 31 FROM tab1
----
0
0
0

query I rowsort
SELECT cor0.col0 * + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT col1 * - 6 AS col2 FROM tab1
----
-156
-60
-78

query I rowsort
SELECT - col1 * - ( cor0.col2 ) * - col2 AS col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL - col2 * + 61 * col1 FROM tab1 AS cor0
----
-34770
-76128
-85644

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3823
SELECT + - col1 + + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3823
SELECT + - col1 + + 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-3824
SELECT ALL - col0 * col1 + col0 DIV + 4 AS col0 FROM tab2 AS cor0
----
-1324
-216
-4583

skipif mysql # not compatible
query I rowsort label-3824
SELECT ALL - col0 * col1 + col0 / + 4 AS col0 FROM tab2 AS cor0
----
-1324
-216
-4583

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 - col0 col0 FROM tab0 AS cor0
----
1190
552
7832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3826
SELECT CAST( NULL AS SIGNED ) + col0 / + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3826
SELECT CAST ( NULL AS INTEGER ) + col0 / + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - cor0.col2 col1 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT ALL + 52 * col1 FROM tab1
----
1352
520
676

query I rowsort
SELECT + 2 AS col2 FROM tab2
----
2
2
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3830
SELECT CAST( col1 AS SIGNED ) DIV + col0 + ( col1 ) FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-3830
SELECT CAST ( col1 AS INTEGER ) / + col0 + ( col1 ) FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT + + ( + 2 ) * - col2 + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-2130
-3397
-8263

query I rowsort
SELECT ALL col1 * ( - col2 ) - 48 FROM tab1 AS cor0
----
-1296
-1452
-618

query I rowsort
SELECT + 99 AS col2 FROM tab0 cor0
----
99
99
99

query I rowsort
SELECT ALL - - col2 * cor0.col0 + - 65 FROM tab1 AS cor0
----
3583
7615
97

query I rowsort
SELECT ALL + 58 * + col1 + col1 AS col2 FROM tab1 cor0
----
1534
590
767

query I rowsort
SELECT ALL + col0 * - col0 + ( + col2 * col1 ) FROM tab1 AS cor0
----
-3526
-5152
1395

onlyif mysql # use DIV operator for integer division
query I rowsort label-3837
SELECT - 44 DIV + col0 FROM tab1 AS cor0
----
-14
0
0

skipif mysql # not compatible
query I rowsort label-3837
SELECT - 44 / + col0 FROM tab1 AS cor0
----
-14
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3838
SELECT CAST( NULL AS SIGNED ) * tab1.col0 + - col1 / 71 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3838
SELECT CAST ( NULL AS INTEGER ) * tab1.col0 + - col1 / 71 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + 61 ) FROM tab0
----
61
61
61

query I rowsort
SELECT - col2 - - tab1.col1 AS col2 FROM tab1
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3841
SELECT DISTINCT CAST( 38 + - col0 AS SIGNED ) FROM tab2
----
-40
-41
31

skipif mysql # not compatible
query I rowsort label-3841
SELECT DISTINCT CAST ( 38 + - col0 AS INTEGER ) FROM tab2
----
-40
-41
31

query I rowsort
SELECT ALL - 64 AS col0 FROM tab1
----
-64
-64
-64

query I rowsort
SELECT 57 * col2 AS col2 FROM tab2 AS cor0
----
1482
1539
2166

onlyif mysql # use DIV operator for integer division
query I rowsort label-3844
SELECT + 58 * col1 DIV + col1 + - col2 AS col1 FROM tab0 AS cor0
----
-24
25
57

skipif mysql # not compatible
query I rowsort label-3844
SELECT + 58 * col1 / + col1 + - col2 AS col1 FROM tab0 AS cor0
----
-24
25
57

query I rowsort
SELECT ALL + - col2 * - col2 + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT tab1.col1 AS col2 FROM tab1, tab2 AS cor0
----
10
13
26

query I rowsort
SELECT tab2.col0 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 6 col2 FROM tab2
----
-6
-6
-6

query I rowsort
SELECT + ( - col1 ) AS col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT col1 + col1 * - col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT col1 * col2 * col2 AS col1 FROM tab2 AS cor0
----
22599
24548
39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-3852
SELECT - tab2.col0 DIV col0 + col1 + col0 FROM tab2
----
136
37
95

skipif mysql # not compatible
query I rowsort label-3852
SELECT - tab2.col0 / col0 + col1 + col0 FROM tab2
----
136
37
95

query I rowsort
SELECT ALL col0 * 34 + - col2 FROM tab0
----
1189
2944
783

query I rowsort
SELECT 12 AS col2 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT ALL col1 + - ( 77 ) + + tab2.col0 AS col2 FROM tab2
----
-39
19
60

query I rowsort
SELECT DISTINCT + tab0.col0 + - tab0.col1 FROM tab0
----
-2
-62

query I rowsort
SELECT ALL col0 * - 45 + - col2 AS col0 FROM tab2
----
-342
-3536
-3593

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + 32 col2 FROM tab0 AS cor0
----
118
123
129

query I rowsort
SELECT DISTINCT 86 + - col2 * col2 AS col1 FROM tab1 AS cor0
----
-2830
-3163
-9130

query I rowsort
SELECT cor0.col2 * + col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - + 25 + col1 + + col1 FROM tab0 AS cor0
----
147
157
169

query I rowsort
SELECT + ( col0 ) * - col1 + + 18 FROM tab2 AS cor0
----
-1325
-199
-4584

query I rowsort
SELECT + col2 + cor0.col1 * cor0.col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT col0 * - 20 + col0 FROM tab2 AS cor0
----
-133
-1482
-1501

query I rowsort
SELECT DISTINCT - - ( + col0 ) * col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - cor0.col0 + + col0 + - col0 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - col2 + ( col0 ) * + col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT + col0 * col2 + col0 AS col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT + + 11 * cor0.col1 + + col2 FROM tab1 AS cor0
----
167
239
340

query I rowsort
SELECT DISTINCT 57 * - col2 FROM tab0 AS cor0
----
-1881
-4674
-57

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 AS col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + + ( - ( col0 ) ) * 96 + cor0.col2 FROM tab1 AS cor0
----
-234
-6087
-7584

query I rowsort
SELECT 37 + - col0 AS col0 FROM tab2 AS cor0
----
-41
-42
30

query I rowsort
SELECT DISTINCT + tab2.col0 * 42 FROM tab2
----
294
3276
3318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - ( - col1 ) + + col1 * - col0 - col0 * 1 col2 FROM tab2 AS cor0
----
-1185
-1711
-8161

onlyif mysql # use DIV operator for integer division
query I rowsort label-3876
SELECT ALL col0 DIV col1 + cor0.col1 AS col0 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-3876
SELECT ALL col0 / col1 + cor0.col1 AS col0 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT ALL ( 15 ) FROM tab2, tab0 cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 97c4e033347d2076218e240ed49af0a7

query I rowsort
SELECT ALL tab1.col2 * + ( col0 * col2 + + ( col2 ) * - col0 ) AS col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col2 ) * col2 col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT tab1.col2 * 91 + - tab1.col1 AS col1 FROM tab1
----
4888
5177
8723

query I rowsort
SELECT DISTINCT 48 - col1 AS col0 FROM tab1
----
22
35
38

query I rowsort
SELECT col1 * cor0.col2 * - 35 + - 39 AS col0 FROM tab2 cor0
----
-22649
-29334
-53729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3883
SELECT DISTINCT + + col2 + + col2 * + CAST( ( - col1 ) * - col0 AS SIGNED ) FROM tab1 AS cor0
----
36537
4266
99936

skipif mysql # not compatible
query I rowsort label-3883
SELECT DISTINCT + + col2 + + col2 * + CAST ( ( - col1 ) * - col0 AS INTEGER ) FROM tab1 AS cor0
----
36537
4266
99936

query I rowsort
SELECT + cor0.col2 * + cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL tab0.col0 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - ( col0 ) * + ( + 51 ) + - col1 * - ( - 63 ) AS col2 FROM tab0 AS cor0
----
-10272
-6642
-7896

onlyif mysql # use DIV operator for integer division
query I rowsort label-3887
SELECT - col1 DIV + tab2.col0 AS col0 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-3887
SELECT - col1 / + tab2.col0 AS col0 FROM tab2
----
-4
0
0

query I rowsort
SELECT - tab1.col2 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - tab1.col0 col0 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT ALL 85 * col1 + + col0 FROM tab2
----
1524
2642
5093

query I rowsort
SELECT - col0 * + 18 + - col1 FROM tab1 AS cor0
----
-1162
-1453
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3892
SELECT - CAST( col1 AS SIGNED ) + col0 + - 16 * col2 DIV col2 FROM tab1
----
-39
38
51

skipif mysql # not compatible
query I rowsort label-3892
SELECT - CAST ( col1 AS INTEGER ) + col0 + - 16 * col2 / col2 FROM tab1
----
-39
38
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 - col2 col0 FROM tab0
----
2805
7380
96

query I rowsort
SELECT ALL + 30 * - col2 AS col2 FROM tab1
----
-1620
-1710
-2880

query I rowsort
SELECT DISTINCT - 49 * tab2.col1 FROM tab2, tab0, tab1 cor0
----
-1519
-2891
-833

onlyif mysql # use DIV operator for integer division
query I rowsort label-3896
SELECT col0 DIV + 88 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3896
SELECT col0 / + 88 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT DISTINCT + col1 + 88 DIV cor0.col2 col1 FROM tab0 cor0
----
185
88
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3897
SELECT DISTINCT + col1 + 88 / cor0.col2 col1 FROM tab0 cor0
----
185
88
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3898
SELECT DISTINCT - col2 * CAST( NULL AS SIGNED ) - col0 * - col0 / col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3898
SELECT DISTINCT - col2 * CAST ( NULL AS INTEGER ) - col0 * - col0 / col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3899
SELECT ALL + ( col2 * CAST( NULL AS SIGNED ) ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3899
SELECT ALL + ( col2 * CAST ( NULL AS INTEGER ) ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 55 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT DISTINCT + tab1.col1 + - tab1.col1 + + 18 FROM tab1
----
18

query I rowsort
SELECT ALL + tab2.col0 * - 78 FROM tab2
----
-546
-6084
-6162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * + 55 col2 FROM tab0 AS cor0
----
1815
4510
55

query I rowsort
SELECT + col0 + + col0 * + cor0.col0 FROM tab1 cor0
----
12
4160
6480

query I rowsort
SELECT - col0 * 78 AS col0 FROM tab0 AS cor0
----
-1872
-2730
-6942

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3906
SELECT col0 * + CAST( - col0 AS SIGNED ) + col2 AS col0 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif mysql # not compatible
query I rowsort label-3906
SELECT col0 * + CAST ( - col0 AS INTEGER ) + col2 AS col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT + col0 * - 54 FROM tab0 AS cor0
----
-1296
-1890
-4806

query I rowsort
SELECT + col1 * + col2 * 35 + - col2 * + col2 FROM tab0
----
254446
3394
98241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 31 col0 FROM tab0
----
-2
-51
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3910
SELECT DISTINCT - col0 * CAST( + col2 AS SIGNED ) * col2 FROM tab1
----
-207936
-737280
-8748

skipif mysql # not compatible
query I rowsort label-3910
SELECT DISTINCT - col0 * CAST ( + col2 AS INTEGER ) * col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT col0 + ( - col2 ) FROM tab2
----
-20
41
52

query I rowsort
SELECT + col2 + 32 AS col1 FROM tab0
----
114
33
65

query I rowsort
SELECT - col2 - + col0 AS col0 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + col0 * + col1 + cor0.col2 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-3915
SELECT + col0 DIV 21 + col1 AS col2 FROM tab0 AS cor0
----
87
95
98

skipif mysql # not compatible
query I rowsort label-3915
SELECT + col0 / 21 + col1 AS col2 FROM tab0 AS cor0
----
87
95
98

query I rowsort
SELECT DISTINCT + + col2 + - 69 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
1689
2416
6223

query I rowsort
SELECT DISTINCT + tab2.col2 * col2 * ( - col0 * + 84 ) FROM tab2
----
-428652
-4429152
-9582384

query I rowsort
SELECT ALL + - col0 * cor0.col0 + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT ALL - 75 * + ( - col1 ) * + cor0.col2 FROM tab0 AS cor0
----
212850
559650
7275

query I rowsort
SELECT - - 35 * 77 * + col0 FROM tab0 cor0
----
239855
64680
94325

query I rowsort
SELECT - col0 * + 34 AS col1 FROM tab0 AS cor0
----
-1190
-3026
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3922
SELECT - + CAST( col2 AS SIGNED ) * col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-3922
SELECT - + CAST ( col2 AS INTEGER ) * col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + ( - col1 ) * col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3924
SELECT DISTINCT + - ( + col2 ) DIV col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3924
SELECT DISTINCT + - ( + col2 ) / col1 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL - + 41 * 89 FROM tab0 AS cor0
----
-3649
-3649
-3649

query I rowsort
SELECT + 10 * 98 FROM tab2 AS cor0
----
980
980
980

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3927
SELECT CAST( NULL AS SIGNED ) / + 57 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3927
SELECT CAST ( NULL AS INTEGER ) / + 57 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 5 FROM tab2 cor0
----
5
5
5

query I rowsort
SELECT ALL + + 4 AS col1 FROM tab1 cor0
----
4
4
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3930
SELECT ALL - + 65 DIV ( + cor0.col0 ) FROM tab2 AS cor0
----
-9
0
0

skipif mysql # not compatible
query I rowsort label-3930
SELECT ALL - + 65 / ( + cor0.col0 ) FROM tab2 AS cor0
----
-9
0
0

query I rowsort
SELECT - col1 * col1 * + col1 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT DISTINCT - + col1 + col2 * col2 FROM tab1 cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT + ( + 21 ) AS col1 FROM tab2 AS cor0
----
21

query I rowsort
SELECT col2 * + col1 + 74 AS col0 FROM tab2 cor0
----
1608
720
911

query I rowsort
SELECT ALL ( - 9 ) FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

onlyif mysql # use DIV operator for integer division
query I rowsort label-3936
SELECT 21 * - col2 * cor0.col1 + col2 DIV + col1 AS col0 FROM tab0 AS cor0
----
-156702
-2037
-59598

skipif mysql # not compatible
query I rowsort label-3936
SELECT 21 * - col2 * cor0.col1 + col2 / + col1 AS col0 FROM tab0 AS cor0
----
-156702
-2037
-59598

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3937
SELECT ALL - - ( col2 ) * CAST( NULL AS SIGNED ) + + col1 * col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3937
SELECT ALL - - ( col2 ) * CAST ( NULL AS INTEGER ) + + col1 * col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 66 + + col2 AS col2 FROM tab1 AS cor0
----
120
123
162

query I rowsort
SELECT + - 70 + + cor0.col2 FROM tab0 AS cor0
----
-37
-69
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3940
SELECT - col1 * cor0.col0 + - CAST( + col2 AS SIGNED ) * - cor0.col0 FROM tab2 AS cor0
----
-2574
-28
1659

skipif mysql # not compatible
query I rowsort label-3940
SELECT - col1 * cor0.col0 + - CAST ( + col2 AS INTEGER ) * - cor0.col0 FROM tab2 AS cor0
----
-2574
-28
1659

query I rowsort
SELECT DISTINCT + 19 + + col1 FROM tab1 AS cor0
----
29
32
45

query I rowsort
SELECT DISTINCT - col0 + - col0 * 13 - - 18 * + col1 AS col1 FROM tab1 cor0
----
-716
-886
426

query I rowsort
SELECT DISTINCT + cor0.col0 * col1 + - 67 FROM tab2 AS cor0
----
1276
150
4535

query I rowsort
SELECT ALL + - cor0.col2 * - cor0.col2 - col0 AS col2 FROM tab0 cor0
----
-34
1065
6635

query I rowsort
SELECT ALL 21 * col1 AS col0 FROM tab2 AS cor0
----
1239
357
651

query I rowsort
SELECT DISTINCT - - col2 * + col0 + - col1 + - ( - col0 + + col2 ) AS col0 FROM tab2 AS cor0
----
138
2021
3026

query I rowsort
SELECT ALL - col1 + col0 * - cor0.col0 * - col1 AS col0 FROM tab1 AS cor0
----
208
40950
83187

query I rowsort
SELECT ALL - col1 * 77 AS col1 FROM tab2 AS cor0
----
-1309
-2387
-4543

query I rowsort
SELECT ALL + col2 * + col1 + + col0 * - col2 AS col0 FROM tab1 cor0
----
-3078
-6432
1242

onlyif mysql # use DIV operator for integer division
query I rowsort label-3950
SELECT + cor0.col1 DIV ( cor0.col0 + + cor0.col2 ) AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3950
SELECT + cor0.col1 / ( cor0.col0 + + cor0.col2 ) AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 * ( + 59 * col2 ) AS col1 FROM tab2 AS cor0
----
38114
49383
90506

query I rowsort
SELECT ALL + + col0 * + 9 + 53 FROM tab0 AS cor0
----
269
368
854

onlyif mysql # use DIV operator for integer division
query I rowsort label-3953
SELECT ALL tab1.col0 DIV + col1 + - col2 FROM tab1
----
-51
-54
-90

skipif mysql # not compatible
query I rowsort label-3953
SELECT ALL tab1.col0 / + col1 + - col2 FROM tab1
----
-51
-54
-90

query I rowsort
SELECT ALL + col0 + - ( col0 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT tab0.col2 * + tab0.col2 + col1 * + ( + col2 ) FROM tab0
----
14186
3927
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3956
SELECT - col1 + col2 DIV col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3956
SELECT - col1 + col2 / col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + col1 + + col1 * col1 FROM tab1
----
110
182
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-3958
SELECT col2 + col1 DIV + tab0.col2 FROM tab0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-3958
SELECT col2 + col1 / + tab0.col2 FROM tab0
----
35
83
98

query I rowsort
SELECT col2 + - col0 * - col2 * + col1 AS col2 FROM tab0
----
3396
664200
68145

query I rowsort
SELECT DISTINCT - col0 * - col1 * + col1 FROM tab2
----
22831
271518
6727

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) IN ( tab1.col1 )
----

query I rowsort
SELECT DISTINCT + tab1.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1
----
10
13
26

query I rowsort
SELECT ALL + cor0.col1 * - col2 FROM tab0 cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * col2 col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col2 + + tab0.col0 * + tab0.col2 AS col0 FROM tab0
----
34
7216
759

query I rowsort
SELECT - col0 * tab1.col2 + - col2 AS col2 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT ALL tab1.col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query IIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT + col2 + - col2 + col0 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col1 col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - + col1 + col2 + - col2 * col0 FROM tab0 AS cor0
----
-131
-7307
-845

query III rowsort
SELECT * FROM tab0 WHERE NOT ( col0 / col2 ) < ( NULL )
----

query I rowsort
SELECT + col1 * tab1.col2 + col0 AS col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT DISTINCT + col1 * + col0 + col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT DISTINCT + col2 * tab1.col2 + col0 * - tab1.col1 + + tab1.col2 FROM tab1
----
2666
2892
8272

query I rowsort
SELECT ALL + tab1.col0 + + col0 * tab1.col1 + - col1 * + col1 FROM tab1
----
-595
604
951

query I rowsort
SELECT col1 + - col2 FROM tab0 WHERE NOT NULL IN ( col0 )
----

query I rowsort
SELECT ALL + col0 * + col0 * col0 + col2 FROM tab2
----
370
474578
493077

onlyif mysql # use DIV operator for integer division
query I rowsort label-3979
SELECT col1 DIV + tab2.col0 AS col1 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-3979
SELECT col1 / + tab2.col0 AS col1 FROM tab2
----
0
0
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3980
SELECT ALL + col1 DIV col0 AS col1 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3980
SELECT ALL + col1 / col0 AS col1 FROM tab0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col1 + - tab2.col0 col2 FROM tab2
----
-24
51
7

query I rowsort
SELECT - col1 * - col0 + col2 AS col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ( + 92 ) FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT + ( - col1 ) + - col1 * - col2 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT + col0 + - col0 + ( - col1 * col1 ) AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - col2 * + col0 + - ( col1 + + col1 ) AS col2 FROM tab0 AS cor0
----
-229
-7480
-964

onlyif mysql # use DIV operator for integer division
query I rowsort label-3987
SELECT - col2 + - col2 DIV - col2 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-3987
SELECT - col2 + - col2 / - col2 FROM tab0
----
-32
-81
0

query I rowsort
SELECT + - cor0.col0 * cor0.col2 + - cor0.col1 + - 47 AS col0 FROM tab2 AS cor0
----
-2134
-267
-3066

query I rowsort
SELECT ALL 78 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT DISTINCT col2 + - col1 FROM tab0 AS cor0 WHERE NOT col0 NOT IN ( col1 )
----

query I rowsort
SELECT DISTINCT col1 * col0 + + col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT ALL col2 + - col2 * + col1 FROM tab2 AS cor0
----
-1508
-608
-810

query IIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 WHERE NOT NULL <> cor0.col1
----

query I rowsort
SELECT + col1 * - col0 * + col1 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT col2 + - tab2.col1 * + col2 FROM tab2
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-3996
SELECT col0 * - col1 DIV - tab2.col1 - + col1 FROM tab2
----
-24
19
62

skipif mysql # not compatible
query I rowsort label-3996
SELECT col0 * - col1 / - tab2.col1 - + col1 FROM tab2
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col2 + - col2 * + tab0.col2 * + col2 + col0 col2 FROM tab0
----
-1
-36705
-558577

query I rowsort
SELECT DISTINCT - col2 + col0 * col0 + + tab1.col1 AS col0 FROM tab1
----
-19
4049
6317

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col1 - - tab2.col0 * + col0 col1 FROM tab2
----
10686
266
7584

query I rowsort
SELECT ALL col2 * col0 + - col2 AS col2 FROM tab1
----
108
3591
7584

query I rowsort
SELECT DISTINCT + col0 - + col2 * + col2 AS col2 FROM tab2
----
-1365
-598
-722

query I rowsort
SELECT 82 * col2 AS col2 FROM tab0 cor0
----
2706
6724
82

query I rowsort
SELECT 27 * col2 * tab2.col0 - + 25 * + col2 FROM tab2
----
4428
54106
80104

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + tab0.col2 col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 940a6b82c800eab4d330c129dc095a0c

query I rowsort
SELECT DISTINCT + col1 + col0 * 65 FROM tab0 AS cor0
----
1646
2372
5876

query I rowsort
SELECT ALL 56 * + col0 + - col2 - + col2 * col0 * ( col0 ) FROM tab1 AS cor0
----
-229945
-372
-610016

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col2 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 + - cor0.col1 * col0 * col1 AS col1 FROM tab2 AS cor0
----
-22814
-271459
-6696

query I rowsort
SELECT ALL - - col0 + - col1 AS col1 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT ALL - + col0 + + 66 * col1 AS col1 FROM tab0 AS cor0
----
5652
5917
6367

onlyif mysql # use DIV operator for integer division
query I rowsort label-4011
SELECT - col1 DIV col2 - + 97 AS col0 FROM tab0
----
-194
-98
-99

skipif mysql # not compatible
query I rowsort label-4011
SELECT - col1 / col2 - + 97 AS col0 FROM tab0
----
-194
-98
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-4012
SELECT + col0 + col1 DIV col0 AS col0 FROM tab1
----
11
64
80

skipif mysql # not compatible
query I rowsort label-4012
SELECT + col0 + col1 / col0 AS col0 FROM tab1
----
11
64
80

query I rowsort
SELECT DISTINCT 56 - cor0.col0 FROM tab0 AS cor0
----
-33
21
32

query I rowsort
SELECT + col0 + + 90 AS col0 FROM tab0 AS cor0
----
114
125
179

query I rowsort
SELECT DISTINCT + 39 + cor0.col0 * + col0 AS col1 FROM tab1 AS cor0
----
4135
48
6439

onlyif mysql # use DIV operator for integer division
query I rowsort label-4016
SELECT DISTINCT + - 15 - cor0.col1 DIV + cor0.col2 AS col1 FROM tab1 AS cor0
----
-15

skipif mysql # not compatible
query I rowsort label-4016
SELECT DISTINCT + - 15 - cor0.col1 / + cor0.col2 AS col1 FROM tab1 AS cor0
----
-15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( cor0.col1 ) col2 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT - 4 * - col1 AS col1 FROM tab2 AS cor0
----
124
236
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4019
SELECT CAST( col0 AS SIGNED ) + col2 * 4 col2 FROM tab2 cor0
----
115
182
231

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4019
SELECT CAST ( col0 AS INTEGER ) + col2 * 4 col2 FROM tab2 cor0
----
115
182
231

onlyif mysql # use DIV operator for integer division
query I rowsort label-4020
SELECT DISTINCT col1 DIV ( + col1 ) AS col2 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-4020
SELECT DISTINCT col1 / ( + col1 ) AS col2 FROM tab2
----
1

query I rowsort
SELECT ( + 55 ) + col0 + - cor0.col2 * - 30 FROM tab1 AS cor0
----
1678
1829
3015

query I rowsort
SELECT ALL + 61 * col1 * + col1 AS col2 FROM tab0 AS cor0
----
451156
505141
573949

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4023
SELECT DISTINCT - + CAST( NULL AS SIGNED ) / col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4023
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) / col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 14 col2 FROM tab2, tab1 cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT + col2 * col2 * tab1.col2 FROM tab1
----
157464
185193
884736

query IIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0 CROSS JOIN tab0 AS cor1
----
243 values hashing to 5c33e96b85afe1ea51bb6d4e9fa6f993

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 col1 FROM tab2 AS cor0
----
76
76
76

query I rowsort
SELECT - 54 + + col2 AS col0 FROM tab1 AS cor0
----
0
3
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-4029
SELECT ALL tab0.col2 * 26 + + tab0.col1 DIV col2 AS col2 FROM tab0
----
123
2133
860

skipif mysql # not compatible
query I rowsort label-4029
SELECT ALL tab0.col2 * 26 + + tab0.col1 / col2 AS col2 FROM tab0
----
123
2133
860

query I rowsort
SELECT ALL + 96 FROM tab2 cor0
----
96
96
96

query I rowsort
SELECT DISTINCT + - 73 AS col1 FROM tab2 AS cor0
----
-73

query I rowsort
SELECT ALL + ( + col0 ) * ( - 45 * col0 ) AS col0 FROM tab2 AS cor0
----
-2205
-273780
-280845

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col2 + 4 col0 FROM tab2 AS cor0
----
-100
-113
-30

onlyif mysql # use DIV operator for integer division
query I rowsort label-4034
SELECT DISTINCT - + col0 + col1 DIV - 90 AS col0 FROM tab0 AS cor0
----
-24
-36
-90

skipif mysql # not compatible
query I rowsort label-4034
SELECT DISTINCT - + col0 + col1 / - 90 AS col0 FROM tab0 AS cor0
----
-24
-36
-90

query I rowsort
SELECT + col1 + - cor0.col1 + 85 FROM tab2 cor0
----
85
85
85

query I rowsort
SELECT DISTINCT 63 + - col1 FROM tab0 AS cor0
----
-23
-28
-34

query I rowsort
SELECT DISTINCT - col2 * + col2 + col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - 11 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

onlyif mysql # use DIV operator for integer division
query I rowsort label-4039
SELECT DISTINCT + ( col0 * + col1 ) + + col2 DIV + tab0.col2 FROM tab0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-4039
SELECT DISTINCT + ( col0 * + col1 ) + + col2 / + tab0.col2 FROM tab0
----
2065
3396
8100

query I rowsort
SELECT ALL 62 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT DISTINCT 17 * + col1 AS col0 FROM tab0 cor0
----
1462
1547
1649

query I rowsort
SELECT ALL - - 51 * col0 AS col2 FROM tab0 AS cor0
----
1224
1785
4539

query I rowsort
SELECT ALL + - ( + col0 ) * 96 FROM tab0 AS cor0
----
-2304
-3360
-8544

query I rowsort
SELECT - + 27 * col0 AS col1 FROM tab1 AS cor0
----
-1728
-2160
-81

query I rowsort
SELECT DISTINCT 36 * - col1 AS col2 FROM tab2 AS cor0
----
-1116
-2124
-612

query I rowsort
SELECT ALL - + 92 * + col0 AS col2 FROM tab1 AS cor0
----
-276
-5888
-7360

query I rowsort
SELECT + - col1 + col0 * - 30 AS col2 FROM tab0 cor0
----
-1147
-2761
-806

query I rowsort
SELECT DISTINCT - - ( col1 ) * + col0 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + cor2.col0 * cor1.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 4763b15a51dbd5cdb83318bbe5f6b333

query I rowsort
SELECT DISTINCT + col1 - + tab2.col1 * + col2 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT ALL - col0 - + tab0.col0 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT - cor0.col1 + + col0 AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + col0 * 68 + + col2 FROM tab1 AS cor0
----
258
4409
5536

query I rowsort
SELECT ALL + + col0 + col0 AS col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + cor1.col2 * 97 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab1 cor2
----
243 values hashing to fa9bd87b98c814982d3fa166d41046a3

query I rowsort
SELECT ALL + - col0 + - cor0.col2 * col0 AS col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT + - col1 * - 84 AS col1 FROM tab2 AS cor0
----
1428
2604
4956

query I rowsort
SELECT DISTINCT col1 * 83 FROM tab1 AS cor0
----
1079
2158
830

query I rowsort
SELECT ALL - 90 AS col1 FROM tab2 AS cor0
----
-90
-90
-90

query I rowsort
SELECT ALL + - 23 FROM tab0 AS cor0
----
-23
-23
-23

query I rowsort
SELECT - 77 AS col0 FROM tab0
----
-77
-77
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4062
SELECT - CAST( NULL AS SIGNED ) + col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4062
SELECT - CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 87 * cor0.col0 + + col0 AS col2 FROM tab2 AS cor0
----
616
6864
6952

query I rowsort
SELECT - - cor0.col0 * - col0 + + col1 AS col2 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT ALL 53 * ( - col2 ) + + col1 FROM tab1 cor0
----
-2836
-3011
-5075

query I rowsort
SELECT 81 + - col2 AS col1 FROM tab2 AS cor0
----
43
54
55

query I rowsort
SELECT DISTINCT + - ( 87 ) * - col2 + cor0.col1 + + col1 * + cor0.col2 FROM tab0 AS cor0
----
14687
281
5795

query I rowsort
SELECT DISTINCT - 9 + + col0 * col1 AS col1 FROM tab2 AS cor0
----
1334
208
4593

query I rowsort
SELECT 0 + col0 * - col0 * col0 + cor0.col1 FROM tab1 AS cor0
----
-1
-262134
-511987

query I rowsort
SELECT DISTINCT col0 + col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1065
-6635
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4071
SELECT 5 DIV - col0 - col1 * cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-4071
SELECT 5 / - col0 - col1 * cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - - col1 + ( col2 ) FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - + col0 + ( 89 ) FROM tab1 AS cor0
----
25
86
9

query I rowsort
SELECT ALL - col2 + - ( col0 ) AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT col1 * + col2 + + cor0.col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL + col2 + - ( + col1 ) AS col0 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4077
SELECT ALL col0 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4077
SELECT ALL col0 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 7 col1 FROM tab1 cor0
----
378
399
672

query I rowsort
SELECT cor0.col0 + + 72 * 10 FROM tab1 AS cor0
----
723
784
800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 + col1 col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - 64 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4082
SELECT CAST( NULL AS SIGNED ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4082
SELECT CAST ( NULL AS INTEGER ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 71 * + cor0.col1 col1 FROM tab0, tab2 AS cor0
----
1207
2201
4189

query I rowsort
SELECT col2 + 5 AS col2 FROM tab0
----
38
6
87

query I rowsort
SELECT col1 * cor0.col0 * - ( + col0 * - col2 ) - - col0 FROM tab0 AS cor0
----
118860
1634712
59106591

query I rowsort
SELECT - col1 * - col0 + 15 FROM tab1 AS cor0
----
1055
655
93

query I rowsort
SELECT + 45 * - col0 + + ( col0 + col1 * - col1 ) AS col1 FROM tab0 AS cor0
----
-10949
-12197
-8452

query I rowsort
SELECT DISTINCT 62 * tab1.col2 - - col1 FROM tab1
----
3374
3544
5965

query I rowsort
SELECT 68 + - col0 AS col0 FROM tab0
----
-21
33
44

query I rowsort
SELECT ALL 7 + col1 FROM tab0
----
104
93
98

query I rowsort
SELECT ALL + tab1.col0 * col2 + tab1.col0 FROM tab1
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4092
SELECT cor0.col1 DIV 46 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-4092
SELECT cor0.col1 / 46 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + cor0.col1 + col0 * col0 AS col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT - col1 + - ( - col1 ) * cor0.col2 AS col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL + cor2.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab0 cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - col0 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 11 AS col2 FROM tab0
----
11
11
11

query I rowsort
SELECT - col1 + + 4 * col2 - col2 * tab0.col1 FROM tab0
----
-190
-2792
-7225

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4099
SELECT DISTINCT + col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-4099
SELECT DISTINCT + col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL

query I rowsort
SELECT + col0 + col2 + cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
7453
8452
9445

query I rowsort
SELECT ALL - cor0.col1 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4102
SELECT col0 DIV col2 + col1 * cor0.col0 + col2 FROM tab0 AS cor0
----
2097
3431
8182

skipif mysql # not compatible
query I rowsort label-4102
SELECT col0 / col2 + col1 * cor0.col0 + col2 FROM tab0 AS cor0
----
2097
3431
8182

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL ( + 6 ) * - col1 FROM tab2
----
-102
-186
-354

query I rowsort
SELECT + 27 * - cor0.col1 FROM tab0 AS cor0
----
-2322
-2457
-2619

query I rowsort
SELECT DISTINCT col0 + + cor0.col0 * cor0.col1 + col0 FROM tab1 AS cor0
----
1200
768
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 42 ) col0 FROM tab1 AS cor0
----
-42
-42
-42

onlyif mysql # use DIV operator for integer division
query I rowsort label-4108
SELECT ALL + 25 + - col2 DIV col0 AS col1 FROM tab2 AS cor0
----
22
25
25

skipif mysql # not compatible
query I rowsort label-4108
SELECT ALL + 25 + - col2 / col0 AS col1 FROM tab2 AS cor0
----
22
25
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-4109
SELECT - ( col2 ) * - col1 DIV - ( col1 ) FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-4109
SELECT - ( col2 ) * - col1 / - ( col1 ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - - ( - col0 ) + 13 * col0 AS col2 FROM tab2 cor0
----
84
936
948

query I rowsort
SELECT - + 18 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
-1548
-1638
-1746

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4112
SELECT CAST( NULL AS SIGNED ) * 97 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4112
SELECT CAST ( NULL AS INTEGER ) * 97 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + tab2.col2 + - ( col0 ) * - tab2.col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT - + cor0.col0 + - col1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4115
SELECT - - CAST( + 79 AS SIGNED ) FROM tab2, tab0 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to da0116d31b8af0da9f685c090d378baf

skipif mysql # not compatible
query I rowsort label-4115
SELECT - - CAST ( + 79 AS INTEGER ) FROM tab2, tab0 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to da0116d31b8af0da9f685c090d378baf

onlyif mysql # use DIV operator for integer division
query I rowsort label-4116
SELECT DISTINCT ( cor0.col2 ) * col0 DIV col0 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4116
SELECT DISTINCT ( cor0.col2 ) * col0 / col0 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col2 * ( - col2 ) FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL col2 + + col1 + col2 AS col2 FROM tab0
----
152
255
99

query I rowsort
SELECT + col0 * 76 AS col2 FROM tab1 AS cor0
----
228
4864
6080

query I rowsort
SELECT DISTINCT + col0 + tab0.col1 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL + col1 * 84 FROM tab0
----
7224
7644
8148

query I rowsort
SELECT ALL + col1 + col1 * col0 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL - 35 * col1 AS col0 FROM tab0 AS cor0
----
-3010
-3185
-3395

onlyif mysql # use DIV operator for integer division
query I rowsort label-4124
SELECT 31 * 86 + col2 DIV 28 FROM tab2
----
2666
2666
2667

skipif mysql # not compatible
query I rowsort label-4124
SELECT 31 * 86 + col2 / 28 FROM tab2
----
2666
2666
2667

query I rowsort
SELECT ( cor0.col2 ) FROM tab1, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4126
SELECT ALL col1 + + col1 * col1 DIV - col0 AS col0 FROM tab0 AS cor0
----
-171
-2
-222

skipif mysql # not compatible
query I rowsort label-4126
SELECT ALL col1 + + col1 * col1 / - col0 AS col0 FROM tab0 AS cor0
----
-171
-2
-222

query I rowsort
SELECT col2 + 33 FROM tab1 AS cor0
----
129
87
90

query I rowsort
SELECT + 76 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to a8a6c4c5005303c62d4e50b6c96b584f

query I rowsort
SELECT - - cor0.col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL - 93 + col1 AS col0 FROM tab2
----
-34
-62
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4131
SELECT ALL - col1 / tab2.col1 - CAST( NULL AS DECIMAL ) col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4131
SELECT ALL - col1 / tab2.col1 - CAST ( NULL AS REAL ) col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ( col0 ) * col2 + 83 AS col2 FROM tab2 AS cor0
----
2111
272
3085

query I rowsort
SELECT + + 51 + cor0.col0 FROM tab2 AS cor0
----
129
130
58

query I rowsort
SELECT col1 + col1 * + ( 17 ) AS col0 FROM tab0 AS cor0
----
1548
1638
1746

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4135
SELECT ALL col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4135
SELECT ALL col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 + + col0 + + col0 AS col1 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT ALL + col1 * - col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + col1 * + 97 + + cor0.col0 AS col1 FROM tab1 cor0
----
1034
1341
2525

onlyif mysql # use DIV operator for integer division
query I rowsort label-4139
SELECT ALL + + col1 + ( 7 ) DIV + col0 AS col2 FROM tab1 AS cor0
----
10
13
28

skipif mysql # not compatible
query I rowsort label-4139
SELECT ALL + + col1 + ( 7 ) / + col0 AS col2 FROM tab1 AS cor0
----
10
13
28

query I rowsort
SELECT - col0 * - tab0.col1 AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT 64 * col2 FROM tab1
----
3456
3648
6144

onlyif mysql # use DIV operator for integer division
query I rowsort label-4142
SELECT col0 DIV - tab2.col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4142
SELECT col0 / - tab2.col0 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT + 3 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT 88 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT - col1 + - 89 + col0 FROM tab1 AS cor0
----
-112
-22
-35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4146
SELECT ALL + col1 * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4146
SELECT ALL + col1 * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + tab1.col1 FROM tab0, tab2, tab2 AS cor0, tab1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT - + col1 + 18 FROM tab0 AS cor0
----
-68
-73
-79

query I rowsort
SELECT DISTINCT - cor0.col2 * - col1 + - 0 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT 97 AS col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT DISTINCT + col1 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - col2 - + ( 18 + col2 ) FROM tab0 AS cor0
----
-182
-20
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + + cor0.col0 col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + - col0 - 60 FROM tab0 AS cor0
----
-149
-84
-95

query I rowsort
SELECT - + col2 + 44 AS col0 FROM tab1 AS cor0
----
-10
-13
-52

query I rowsort
SELECT ALL - cor0.col0 + + 69 AS col0 FROM tab0 cor0
----
-20
34
45

query I rowsort
SELECT + col1 * 65 + + col0 AS col2 FROM tab1 AS cor0
----
1693
714
925

query I rowsort
SELECT ALL col0 + col0 + ( + col0 ) FROM tab2 AS cor0
----
21
234
237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 75 + - 95 col0 FROM tab2 AS cor0
----
-20
-20
-20

query I rowsort
SELECT ALL + col1 + col2 + col0 AS col1 FROM tab1
----
131
189
83

query I rowsort
SELECT ALL col1 + 97 + + col0 AS col0 FROM tab0
----
207
229
277

query I rowsort
SELECT DISTINCT + 35 * + col2 + - col1 FROM tab0 AS cor0
----
-62
1069
2779

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 * col1 col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - - cor0.col2 + col0 * - col0 FROM tab0 cor0
----
-1224
-543
-7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-4165
SELECT col1 + - ( - ( - col2 ) ) DIV - ( col0 ) AS col0 FROM tab0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-4165
SELECT col1 + - ( - ( - col2 ) ) / - ( col0 ) AS col0 FROM tab0
----
87
91
97

query I rowsort
SELECT col1 + + 23 * col0 + col0 FROM tab2
----
1913
1931
199

query I rowsort
SELECT DISTINCT col0 + - tab0.col2 * - ( tab0.col0 * - col0 ) FROM tab0
----
-1190
-18984
-649433

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4168
SELECT + tab1.col1 + - col0 * col0 + tab1.col1 * - CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4168
SELECT + tab1.col1 + - col0 * col0 + tab1.col1 * - CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4169
SELECT ALL - col0 DIV - col2 - 6 * + 72 AS col2 FROM tab1 AS cor0
----
-431
-432
-432

skipif mysql # not compatible
query I rowsort label-4169
SELECT ALL - col0 / - col2 - 6 * + 72 AS col2 FROM tab1 AS cor0
----
-431
-432
-432

query I rowsort
SELECT ALL - - col2 + + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-4171
SELECT ALL + 8 DIV col0 - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-4171
SELECT ALL + 8 / col0 - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + 83 * col0 FROM tab2 AS cor0
----
581
6474
6557

query I rowsort
SELECT + 75 * cor0.col1 FROM tab1 AS cor0
----
1950
750
975

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4174
SELECT ALL + + 56 + + col1 * + CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
156
225
732

skipif mysql # not compatible
query I rowsort label-4174
SELECT ALL + + 56 + + col1 * + CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
156
225
732

query I rowsort
SELECT + + col0 * - col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT 71 * - col1 FROM tab2 AS cor0
----
-1207
-2201
-4189

query I rowsort
SELECT ( - 62 + - col2 ) FROM tab2
----
-100
-88
-89

query I rowsort
SELECT 85 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT DISTINCT 78 AS col0 FROM tab2
----
78

query I rowsort
SELECT 18 + + col1 FROM tab1
----
28
31
44

query I rowsort
SELECT DISTINCT tab0.col1 - col0 FROM tab0
----
2
62

query I rowsort
SELECT DISTINCT col1 * + col0 - - ( + col0 * + col1 ) AS col2 FROM tab0
----
16198
4128
6790

query I rowsort
SELECT DISTINCT + 22 * - col1 - col1 AS col0 FROM tab1 AS cor0
----
-230
-299
-598

query I rowsort
SELECT + cor0.col0 * cor0.col0 * + ( - ( - col0 ) ) FROM tab2 AS cor0
----
343
474552
493039

query I rowsort
SELECT ALL - col2 + - col2 AS col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - 44 + col0 * col2 FROM tab2 AS cor0
----
145
1984
2958

query I rowsort
SELECT + - ( - cor0.col2 ) * cor0.col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL 94 * - col0 + + col0 AS col2 FROM tab0 AS cor0
----
-2232
-3255
-8277

onlyif mysql # use DIV operator for integer division
query I rowsort label-4189
SELECT 40 DIV 47 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4189
SELECT 40 / 47 AS col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 1 ) * + col2 col0 FROM tab1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4191
SELECT ( 28 ) DIV - col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4191
SELECT ( 28 ) / - col0 FROM tab0
----
-1
0
0

query I rowsort
SELECT + 67 * + col2 FROM tab1
----
3618
3819
6432

query I rowsort
SELECT DISTINCT - col2 * ( - col2 ) FROM tab2
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-4194
SELECT DISTINCT col2 DIV 73 col0 FROM tab1 AS cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4194
SELECT DISTINCT col2 / 73 col0 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT 69 AS col2 FROM tab2, tab0 AS cor0
----
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 83 col1 FROM tab0 AS cor0
----
-83
-83
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4197
SELECT CAST( + 43 AS SIGNED ) AS col0 FROM tab0
----
43
43
43

skipif mysql # not compatible
query I rowsort label-4197
SELECT CAST ( + 43 AS INTEGER ) AS col0 FROM tab0
----
43
43
43

query I rowsort
SELECT DISTINCT 46 * col1 * col1 FROM tab0
----
340216
380926
432814

onlyif mysql # use DIV operator for integer division
query I rowsort label-4199
SELECT - col1 DIV - col0 + + col1 AS col1 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-4199
SELECT - col1 / - col0 + + col1 AS col1 FROM tab1 AS cor0
----
10
13
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4200
SELECT col0 DIV col0 - col2 DIV col1 AS col1 FROM tab1 AS cor0
----
-1
-4
-6

skipif mysql # not compatible
query I rowsort label-4200
SELECT col0 / col0 - col2 / col1 AS col1 FROM tab1 AS cor0
----
-1
-4
-6

query I rowsort
SELECT 12 + col0 AS col2 FROM tab0 AS cor0
----
101
36
47

query I rowsort
SELECT 50 * col2 + + col0 + - col2 FROM tab0 AS cor0
----
1641
4107
84

query I rowsort
SELECT ALL - + col1 * + col0 * 36 FROM tab0 AS cor0
----
-122220
-291564
-74304

query I rowsort
SELECT col0 + col0 + + col1 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT - - 12 + col1 * - col0 FROM tab2 AS cor0
----
-1331
-205
-4590

onlyif mysql # use DIV operator for integer division
query I rowsort label-4206
SELECT col2 + col1 + col1 DIV col2 AS col1 FROM tab0 AS cor0
----
121
174
195

skipif mysql # not compatible
query I rowsort label-4206
SELECT col2 + col1 + col1 / col2 AS col1 FROM tab0 AS cor0
----
121
174
195

query I rowsort
SELECT ALL col0 * tab2.col1 + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT col2 * col0 + col2 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-4209
SELECT + col1 DIV + col2 + - col0 * + 71 + col1 FROM tab0 AS cor0
----
-1616
-2291
-6227

skipif mysql # not compatible
query I rowsort label-4209
SELECT + col1 / + col2 + - col0 * + 71 + col1 FROM tab0 AS cor0
----
-1616
-2291
-6227

query I rowsort
SELECT ( col0 ) * col1 + - col2 + + col2 FROM tab1 cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4211
SELECT ALL - cor0.col2 + - CAST( + col1 AS SIGNED ) * cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
-11020
-25974
-90532

skipif mysql # not compatible
query I rowsort label-4211
SELECT ALL - cor0.col2 + - CAST ( + col1 AS INTEGER ) * cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
-11020
-25974
-90532

query I rowsort
SELECT DISTINCT col2 * - col0 + - ( col1 * + 38 ) AS col1 FROM tab0 AS cor0
----
-10756
-3721
-4060

query I rowsort
SELECT ALL + cor0.col0 * + 88 AS col0 FROM tab1 AS cor0
----
264
5632
7040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col2 col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 51 col0 FROM tab1 cor0
----
-51
-51
-51

query I rowsort
SELECT - col2 + + 3 * + col0 AS col1 FROM tab1
----
-45
135
144

query I rowsort
SELECT ALL - 37 * - 11 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 29ec9bc634eb883839f60ce7bc5642f5

query I rowsort
SELECT - 57 * - 66 FROM tab2 AS cor0
----
3762
3762
3762

query I rowsort
SELECT - - col2 + 48 FROM tab0 cor0
----
130
49
81

query I rowsort
SELECT ALL + col2 + 57 - + col1 FROM tab1 AS cor0
----
104
140
85

query I rowsort
SELECT ALL ( + tab2.col1 ) FROM tab2, tab1 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT + - 99 AS col2 FROM tab1 AS cor0
----
-99

query I rowsort
SELECT DISTINCT + 72 - 22 * col1 FROM tab2 AS cor0
----
-1226
-302
-610

query I rowsort
SELECT ALL - 73 * cor0.col0 FROM tab2 AS cor0
----
-511
-5694
-5767

query I rowsort
SELECT DISTINCT + col0 + 74 * col0 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT ALL - - cor0.col1 + col2 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT cor1.col1 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - col1 + col0 AS col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT col0 * - col0 * + col0 FROM tab2 AS cor0
----
-343
-474552
-493039

query I rowsort
SELECT - col0 * cor0.col2 - 77 AS col0 FROM tab2 AS cor0
----
-2105
-266
-3079

query I rowsort
SELECT ALL + 19 + col2 FROM tab0 AS cor0
----
101
20
52

query I rowsort
SELECT DISTINCT - 34 * - ( + tab2.col0 ) AS col2 FROM tab2
----
238
2652
2686

query I rowsort
SELECT DISTINCT ( col1 + - col2 ) FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + - col0 + ( 33 ) AS col0 FROM tab1 AS cor0
----
-31
-47
30

query I rowsort
SELECT ALL ( col2 + ( 83 ) ) FROM tab2
----
109
110
121

query I rowsort
SELECT - cor0.col1 + + col1 + + col2 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4237
SELECT - col0 DIV - col1 + col2 + + col0 AS col2 FROM tab2 AS cor0
----
105
121
34

skipif mysql # not compatible
query I rowsort label-4237
SELECT - col0 / - col1 + col2 + + col0 AS col2 FROM tab2 AS cor0
----
105
121
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4238
SELECT DISTINCT col1 * + CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-4238
SELECT DISTINCT col1 * + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT cor0.col1 - + cor0.col2 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 5fc5fcec216468c99d1c0eaf371b3149

query I rowsort
SELECT - - col0 + + 95 * - col0 FROM tab1 cor0
----
-282
-6016
-7520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col1 col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + col2 - cor0.col2 * col0 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4243
SELECT ALL CAST( - 40 * + col2 AS SIGNED ) col1 FROM tab1
----
-2160
-2280
-3840

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4243
SELECT ALL CAST ( - 40 * + col2 AS INTEGER ) col1 FROM tab1
----
-2160
-2280
-3840

query I rowsort
SELECT DISTINCT 22 AS col1 FROM tab0 cor0
----
22

query I rowsort
SELECT - - col0 * - col1 + 4 AS col1 FROM tab1 cor0
----
-1036
-636
-74

query I rowsort
SELECT 36 + - col2 + 79 * + col2 FROM tab2 AS cor0
----
2064
2142
3000

query I rowsort
SELECT DISTINCT - + col1 + col2 * ( + col1 ) FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT + col1 + col1 * 52 FROM tab1 cor0
----
1378
530
689

query I rowsort
SELECT DISTINCT col0 * col0 - col0 AS col1 FROM tab0
----
1190
552
7832

query I rowsort
SELECT 97 + tab0.col0 * + col2 FROM tab0
----
132
7395
889

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 14 col0 FROM tab1
----
14
14
14

query I rowsort
SELECT ALL 98 * - col2 + + col2 - + col2 AS col1 FROM tab0
----
-3234
-8036
-98

query I rowsort
SELECT + 54 + + col2 FROM tab0
----
136
55
87

query I rowsort
SELECT ALL - col1 + + col2 + tab2.col2 AS col0 FROM tab2
----
-7
23
59

query I rowsort
SELECT ALL - col1 + + col1 * + col0 * 12 AS col1 FROM tab0 AS cor0
----
24682
40643
97097

query I rowsort
SELECT DISTINCT 39 + col1 * - col1 AS col2 FROM tab2
----
-250
-3442
-922

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * + col1 + - col2 col0 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT col0 + col2 * + col2 AS col0 FROM tab1 cor0
----
2919
3313
9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col1 col0 FROM tab0, tab2, tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 63 ) col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT ALL 88 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT col1 + + col2 * + col0 AS col0 FROM tab0
----
132
7389
878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4263
SELECT + col1 * CAST( col0 AS SIGNED ) - + col2 AS col0 FROM tab0
----
2031
3394
8017

skipif mysql # not compatible
query I rowsort label-4263
SELECT + col1 * CAST ( col0 AS INTEGER ) - + col2 AS col0 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT cor0.col0 + - 68 FROM tab0 AS cor0
----
-33
-44
21

query I rowsort
SELECT ALL - tab0.col0 * ( 38 ) FROM tab0
----
-1330
-3382
-912

query I rowsort
SELECT - ( - cor0.col1 ) * col2 - cor0.col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4267
SELECT + CAST( NULL AS SIGNED ) / cor0.col1 - + col1 * - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4267
SELECT + CAST ( NULL AS INTEGER ) / cor0.col1 - + col1 * - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 12 + col1 FROM tab0
----
103
109
98

query I rowsort
SELECT - 71 - col2 FROM tab0
----
-104
-153
-72

query I rowsort
SELECT + col2 * - ( col1 ) * col1 + - col0 AS col2 FROM tab0 AS cor0
----
-244092
-679131
-9444

query I rowsort
SELECT DISTINCT ( - 3 ) FROM tab0 AS cor0
----
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4272
SELECT DISTINCT + ( + cor0.col1 ) DIV col1 col0 FROM tab1 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4272
SELECT DISTINCT + ( + cor0.col1 ) / col1 col0 FROM tab1 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4273
SELECT 0 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4273
SELECT 0 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * ( col0 ) + - ( + col2 ) AS col2 FROM tab0 cor0
----
1224
543
7839

query I rowsort
SELECT + col0 * + col1 + + col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-4276
SELECT ALL 42 + col2 DIV - col1 FROM tab2 AS cor0
----
40
42
42

skipif mysql # not compatible
query I rowsort label-4276
SELECT ALL 42 + col2 / - col1 FROM tab2 AS cor0
----
40
42
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-4277
SELECT + ( - col1 ) DIV + col0 + + col0 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-4277
SELECT + ( - col1 ) / + col0 + + col0 FROM tab0 AS cor0
----
21
33
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4278
SELECT ALL CAST( col1 AS SIGNED ) * tab2.col2 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-4278
SELECT ALL CAST ( col1 AS INTEGER ) * tab2.col2 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col1 AS REAL ) FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 89 - ( - col0 ) col0 FROM tab0
----
113
124
178

query I rowsort
SELECT + ( 44 * - col1 ) FROM tab1
----
-1144
-440
-572

query I rowsort
SELECT ALL col2 * + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL - cor1.col1 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

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-4285
SELECT ALL + - CAST( - col0 AS SIGNED ) * col0 DIV + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-4285
SELECT ALL + - CAST ( - col0 AS INTEGER ) * col0 / + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL 3 FROM tab0 cor0
----
3
3
3

query I rowsort
SELECT ALL - 13 AS col1 FROM tab1 cor0
----
-13
-13
-13

query I rowsort
SELECT - 97 * - cor0.col2 FROM tab0 AS cor0
----
3201
7954
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4289
SELECT ALL col1 DIV + col2 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-4289
SELECT ALL col1 / + col2 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT DISTINCT - - col2 * col1 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT + ( + col2 ) * col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col0 - col2 * col1 FROM tab2 cor0
----
-1612
-725
-844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col0 + - cor0.col1 col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL + col1 * - col1 + - col2 FROM tab2 AS cor0
----
-327
-3507
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-4295
SELECT col0 - col2 DIV - cor0.col0 AS col0 FROM tab1 cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-4295
SELECT col0 - col2 / - cor0.col0 AS col0 FROM tab1 cor0
----
21
64
81

query I rowsort
SELECT ALL - col2 * - col2 + cor0.col0 * col2 AS col0 FROM tab0 AS cor0
----
14022
1881
36

query I rowsort
SELECT DISTINCT - 75 * col0 + col2 FROM tab0 cor0
----
-1767
-2624
-6593

query I rowsort
SELECT ALL + ( - col2 ) - col0 * - col0 FROM tab2
----
22
6058
6203

query I rowsort
SELECT DISTINCT 96 - - 49 AS col2 FROM tab1
----
145

query I rowsort
SELECT ( cor0.col1 ) - + col1 * + col1 FROM tab2 cor0
----
-272
-3422
-930

query I rowsort
SELECT + col1 - col0 AS col0 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4302
SELECT ( col0 ) DIV col1 + col1 + col2 AS col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-4302
SELECT ( col0 ) / col1 + col1 + col2 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - 48 * 62 AS col2 FROM tab2
----
-2976
-2976
-2976

query I rowsort
SELECT DISTINCT col1 * - col2 - col0 AS col0 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT + - col0 + - ( col1 ) * col2 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT + cor0.col2 * ( 6 ) AS col2 FROM tab0 cor0
----
198
492
6

query I rowsort
SELECT ALL - + col0 * + cor0.col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - cor0.col1 * cor0.col2 + + col2 * col0 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT ALL - col0 + + 96 AS col1 FROM tab2 AS cor0
----
17
18
89

query I rowsort
SELECT DISTINCT col1 + col1 * + col0 - + col2 AS col1 FROM tab0 AS cor0
----
2117
3491
8108

query I rowsort
SELECT DISTINCT - col0 + cor0.col0 + - col2 * + cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - col0 + + 47 FROM tab1 AS cor0
----
-17
-33
44

query I rowsort
SELECT 88 * + col0 FROM tab2
----
616
6864
6952

query I rowsort
SELECT ALL - col2 * col0 - + col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT 84 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 85 * - cor0.col1 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 5adaa23c416a0110ec97ec8a917373c0

query I rowsort
SELECT ALL ( col1 ) * col2 * 38 AS col0 FROM tab1
----
21660
47424
53352

query I rowsort
SELECT col0 + ( + 37 ) FROM tab1 AS cor0
----
101
117
40

query I rowsort
SELECT DISTINCT - cor0.col0 + + 16 FROM tab2 AS cor0
----
-62
-63
9

query I rowsort
SELECT DISTINCT + col0 - - ( ( col1 ) * - cor0.col2 ) FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT + col0 * col0 + - col0 FROM tab1 cor0
----
4032
6
6320

query I rowsort
SELECT ALL - cor0.col0 + - ( col2 ) FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT col2 * + 5 FROM tab2 AS cor0
----
130
135
190

query I rowsort
SELECT DISTINCT - + cor0.col2 * 36 FROM tab1 AS cor0
----
-1944
-2052
-3456

onlyif mysql # use DIV operator for integer division
query I rowsort label-4325
SELECT ALL cor0.col0 + col0 * + col1 DIV col1 AS col1 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-4325
SELECT ALL cor0.col0 + col0 * + col1 / col1 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT col0 * col1 + - col2 FROM tab2
----
1305
190
4576

query I rowsort
SELECT DISTINCT + 16 AS col0 FROM tab1, tab0 AS cor0
----
16

query I rowsort
SELECT + cor0.col1 * - 88 * - col0 FROM tab0 AS cor0
----
181632
298760
712712

query I rowsort
SELECT + + col2 * col2 * + 82 AS col0 FROM tab1 AS cor0
----
239112
266418
755712

onlyif mysql # use DIV operator for integer division
query I rowsort label-4330
SELECT ALL col0 DIV - tab0.col2 FROM tab0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-4330
SELECT ALL col0 / - tab0.col2 FROM tab0
----
-1
-35
0

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 cor2
----
972 values hashing to 635619591835474e6aa6acdff4ab166c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 92 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4333
SELECT DISTINCT - col0 * col2 + cor0.col2 / col2 - CAST( NULL AS SIGNED ) * col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4333
SELECT DISTINCT - col0 * col2 + cor0.col2 / col2 - CAST ( NULL AS INTEGER ) * col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4334
SELECT - col2 + + cor0.col2 DIV col1 FROM tab1 AS cor0
----
-52
-52
-89

skipif mysql # not compatible
query I rowsort label-4334
SELECT - col2 + + cor0.col2 / col1 FROM tab1 AS cor0
----
-52
-52
-89

query I rowsort
SELECT - col1 - + 61 AS col0 FROM tab1 AS cor0
----
-71
-74
-87

query I rowsort
SELECT ALL + - cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to 3e2b81ca10484cbfc66f186955e0e920

query I rowsort
SELECT - col2 * 31 * + cor0.col1 FROM tab1 AS cor0
----
-17670
-38688
-43524

query I rowsort
SELECT col0 * ( 86 ) FROM tab1 AS cor0
----
258
5504
6880

query I rowsort
SELECT DISTINCT - col0 * - 45 FROM tab1 AS cor0
----
135
2880
3600

query I rowsort
SELECT col0 * ( col2 ) AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col2 * + col2 + col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL + 74 AS col1 FROM tab0 AS cor0
----
74
74
74

query I rowsort
SELECT + 71 * 55 + - col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
2501
2657
3335

query I rowsort
SELECT DISTINCT - col2 + - 34 FROM tab0 cor0
----
-116
-35
-67

query I rowsort
SELECT DISTINCT + col2 + ( cor0.col1 + col2 ) * 9 * col0 FROM tab0 AS cor0
----
138655
25737
30871

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( 25 AS REAL ) * - cor0.col2 + col1 AS col0 FROM tab2 AS cor0
----
-591
-644
-933

query I rowsort
SELECT + 89 + 28 * + col0 AS col2 FROM tab0 AS cor0
----
1069
2581
761

query I rowsort
SELECT ALL + cor0.col0 * 96 * cor0.col2 FROM tab1 AS cor0
----
15552
350208
737280

query I rowsort
SELECT DISTINCT 68 * col2 + cor0.col1 FROM tab2 AS cor0
----
1827
1867
2601

query I rowsort
SELECT + + col2 + col0 * - col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL - - 62 * 1 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
116
119
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-4352
SELECT + + cor0.col2 DIV 55 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4352
SELECT + + cor0.col2 / 55 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + 42 col0 FROM tab0 AS cor0
----
1386
3444
42

query I rowsort
SELECT ALL + cor0.col1 * 96 + cor0.col2 * 86 AS col1 FROM tab0 cor0
----
11094
15788
9398

query I rowsort
SELECT DISTINCT - + col2 * 59 AS col2 FROM tab0 AS cor0
----
-1947
-4838
-59

query I rowsort
SELECT ALL + - col1 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + 30 + + cor0.col0 AS col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 11ece3da67df272dd52f910d6088fcc0

query I rowsort
SELECT ALL col0 * + col1 + col2 * ( col1 ) * - 7 AS col1 FROM tab2 cor0
----
-3179
-5642
-6136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 79 * + cor0.col1 col0 FROM tab1 AS cor0
----
-1027
-2054
-790

query I rowsort
SELECT 76 * + col1 AS col1 FROM tab0 AS cor0
----
6536
6916
7372

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col0 col0 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT - ( 1 ) AS col2 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT ALL + 33 + - tab1.col2 AS col0 FROM tab1
----
-21
-24
-63

query I rowsort
SELECT + - 80 * col1 + ( 65 ) AS col0 FROM tab1 AS cor0
----
-2015
-735
-975

query I rowsort
SELECT - col2 * - col0 + + 82 AS col0 FROM tab0 AS cor0
----
117
7380
874

query I rowsort
SELECT 1 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT DISTINCT - - col2 * 93 FROM tab2 AS cor0
----
2418
2511
3534

query I rowsort
SELECT - + col2 * - 80 AS col0 FROM tab2 cor0
----
2080
2160
3040

query I rowsort
SELECT + col1 * col1 + cor0.col2 * col1 FROM tab2 AS cor0
----
1798
5015
935

query I rowsort
SELECT - + col2 + + cor0.col1 AS col2 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL cor0.col1 - tab2.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 773ba5cace8a7d36bd64dd8fb384bdc8

query I rowsort
SELECT DISTINCT + 29 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
29

query I rowsort
SELECT ALL + cor0.col1 + - cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 023677f2362ebf8bd60cb629f4090df4

query I rowsort
SELECT + ( - tab1.col0 * col1 ) AS col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ( - 21 ) * - col0 AS col1 FROM tab2
----
147
1638
1659

query I rowsort
SELECT - col0 * - col0 + + col1 AS col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT + col2 * - col2 * + col2 - + col1 FROM tab0 AS cor0
----
-36023
-551459
-98

query I rowsort
SELECT - + 71 * col0 * 45 AS col1 FROM tab2 AS cor0
----
-22365
-249210
-252405

query I rowsort
SELECT DISTINCT + 14 + - col2 FROM tab2 AS cor0
----
-12
-13
-24

query I rowsort
SELECT ALL ( + col1 ) * col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT + ( col0 ) * col0 + col0 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4382
SELECT CAST( NULL AS SIGNED ) * - 28 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4382
SELECT CAST ( NULL AS INTEGER ) * - 28 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4383
SELECT DISTINCT CAST( NULL AS SIGNED ) col0 FROM tab2, tab0, tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4383
SELECT DISTINCT CAST ( NULL AS INTEGER ) col0 FROM tab2, tab0, tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL 64 AS col1 FROM tab0 AS cor0
----
64
64
64

query I rowsort
SELECT ALL col1 * + 26 + col2 FROM tab0 AS cor0
----
2269
2448
2523

query I rowsort
SELECT + col2 + + 90 FROM tab0 cor0
----
123
172
91

query I rowsort
SELECT DISTINCT + col0 * - col0 - col2 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT + 50 + 11 FROM tab2 AS cor0
----
61
61
61

query I rowsort
SELECT DISTINCT col1 * col1 + - col2 AS col2 FROM tab1 cor0
----
43
622
73

query I rowsort
SELECT - 40 + col2 AS col1 FROM tab0 AS cor0
----
-39
-7
42

query I rowsort
SELECT DISTINCT + 80 * + col2 AS col0 FROM tab1 AS cor0
----
4320
4560
7680

query I rowsort
SELECT DISTINCT + 23 AS col2 FROM tab0 AS cor0
----
23

query I rowsort
SELECT ALL - ( + col0 ) * - cor0.col1 + - col1 AS col0 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4394
SELECT DISTINCT - + col2 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4394
SELECT DISTINCT - + col2 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - + col1 * col2 + col2 * + col0 FROM tab0 AS cor0
----
-164
-2046
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4396
SELECT DISTINCT col1 * 58 + + col1 DIV 28 FROM tab0 AS cor0
----
4991
5281
5629

skipif mysql # not compatible
query I rowsort label-4396
SELECT DISTINCT col1 * 58 + + col1 / 28 FROM tab0 AS cor0
----
4991
5281
5629

query I rowsort
SELECT ALL col2 * + col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + + 20 + + col1 * - col1 FROM tab1 AS cor0
----
-149
-656
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4399
SELECT DISTINCT - + CAST( col0 AS SIGNED ) + col1 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-4399
SELECT DISTINCT - + CAST ( col0 AS INTEGER ) + col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL + 78 * 51 FROM tab0 AS cor0
----
3978
3978
3978

query I rowsort
SELECT DISTINCT - - col2 * + col1 + col2 + + ( + col0 ) * - ( 35 ) * col1 FROM tab1 AS cor0
----
-1272
-21773
-35056

query I rowsort
SELECT ALL col0 * col0 + col0 AS col0 FROM tab1 AS cor0
----
12
4160
6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-4403
SELECT ALL + - 31 DIV + col1 + 84 * - col0 col0 FROM tab1 AS cor0
----
-253
-5379
-6722

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4403
SELECT ALL + - 31 / + col1 + 84 * - col0 col0 FROM tab1 AS cor0
----
-253
-5379
-6722

query I rowsort
SELECT - col1 - + col1 AS col2 FROM tab1 AS cor0
----
-20
-26
-52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col1 + col0 col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL col0 - col2 * - col0 AS col1 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL - col2 + 75 FROM tab2 AS cor0
----
37
48
49

query I rowsort
SELECT ALL - - cor0.col0 * 90 AS col0 FROM tab0 AS cor0
----
2160
3150
8010

query I rowsort
SELECT DISTINCT + col1 - ( col2 + - col0 ) AS col2 FROM tab0 AS cor0
----
131
77
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4410
SELECT DISTINCT - + col2 + cor0.col0 DIV cor0.col2 FROM tab0 AS cor0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-4410
SELECT DISTINCT - + col2 + cor0.col0 / cor0.col2 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT ALL + col0 * 64 + - col2 * - col1 AS col2 FROM tab2 cor0
----
1285
5702
6526

query I rowsort
SELECT - col0 * - col2 - col1 * col1 FROM tab2
----
-1453
-772
2713

query I rowsort
SELECT col0 * col2 - - col1 * col1 AS col2 FROM tab0
----
15579
8188
9444

query I rowsort
SELECT 8 + + 14 FROM tab0, tab2 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 36 col0 FROM tab1, tab1 AS cor0
----
36

query I rowsort
SELECT + col1 + - 71 FROM tab1
----
-45
-58
-61

query I rowsort
SELECT + col1 * col2 + 47 FROM tab2
----
1581
693
884

query I rowsort
SELECT + tab1.col2 + col2 AS col1 FROM tab1
----
108
114
192

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to a8481bfbfcb330825976c5896e54bc19

query I rowsort
SELECT - col2 * 38 AS col1 FROM tab1 AS cor0
----
-2052
-2166
-3648

query I rowsort
SELECT - cor0.col0 * + col2 * col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT 81 * col1 FROM tab2 AS cor0
----
1377
2511
4779

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to b225d3765f33551c12574f545c8c91eb

query I rowsort
SELECT ( 8 ) * + tab1.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to cab8512e8432e71d5f577d7d048e5a49

query I rowsort
SELECT ALL - 31 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

query I rowsort
SELECT ALL + - 65 * cor0.col1 FROM tab0 AS cor0
----
-5590
-5915
-6305

query I rowsort
SELECT ALL 31 + + cor0.col2 * col1 AS col2 FROM tab2 cor0
----
1565
677
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - - 14 col2 FROM tab2 AS cor0
----
31
45
73

query I rowsort
SELECT - 81 AS col0 FROM tab1 AS cor0
----
-81
-81
-81

query I rowsort
SELECT ALL + 46 * + col0 FROM tab0 cor0
----
1104
1610
4094

query I rowsort
SELECT cor0.col1 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to de2705ff0bb8b4f714dafb07497c6119

query I rowsort
SELECT ALL - + 86 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 9d2e1e8eda15b3b83dd7136dfc4f19af

onlyif mysql # use DIV operator for integer division
query I rowsort label-4433
SELECT ALL + 60 + + col2 DIV col2 + 88 FROM tab1
----
149
149
149

skipif mysql # not compatible
query I rowsort label-4433
SELECT ALL + 60 + + col2 / col2 + 88 FROM tab1
----
149
149
149

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + cor0.col0 col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT 20 * col2 + + col1 + col0 * cor0.col1 FROM tab1 AS cor0
----
1184
1790
2973

query I rowsort
SELECT + - col0 + col0 + col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT ALL - - col2 + col2 + 59 FROM tab0 AS cor0
----
125
223
61

query I rowsort
SELECT 79 * col0 FROM tab1
----
237
5056
6320

query I rowsort
SELECT - 5 + col2 + - col2 * + 1 FROM tab1 cor0
----
-5
-5
-5

query I rowsort
SELECT DISTINCT col0 + col2 * 95 AS col1 FROM tab1 AS cor0
----
5133
5479
9200

query I rowsort
SELECT DISTINCT + - col1 + 88 FROM tab0 AS cor0
----
-3
-9
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4442
SELECT ALL col2 * CAST( + col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-4442
SELECT ALL col2 * CAST ( + col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT col2 + cor0.col0 * - 15 + col1 AS col1 FROM tab2 AS cor0
----
-1085
-1130
-47

query I rowsort
SELECT ALL - - col2 * 65 AS col0 FROM tab1 cor0
----
3510
3705
6240

query I rowsort
SELECT col1 + col1 * + 0 FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4446
SELECT col2 DIV CAST( col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4446
SELECT col2 / CAST ( col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4447
SELECT DISTINCT + - col1 DIV + 55 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4447
SELECT DISTINCT + - col1 / + 55 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - cor0.col0 + cor0.col0 * col1 * - col1 AS col1 FROM tab1 cor0
----
-13600
-2031
-6464

query I rowsort
SELECT DISTINCT col1 * + col1 AS col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT + - col0 + - col1 * + col0 AS col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT - col2 + 14 * col0 FROM tab2 AS cor0
----
1066
1068
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - 76 col0 FROM tab1 cor0
----
-102
-86
-89

query I rowsort
SELECT - col1 + - 72 FROM tab1 AS cor0
----
-82
-85
-98

query I rowsort
SELECT + ( - 61 ) AS col2 FROM tab0
----
-61
-61
-61

query I rowsort
SELECT ALL + 15 * col0 FROM tab0
----
1335
360
525

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4456
SELECT - - col0 * CAST( col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-4456
SELECT - - col0 * CAST ( col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - + cor0.col1 + - 69 FROM tab1 AS cor0
----
-79
-82
-95

query I rowsort
SELECT + col1 * + 57 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
1485
634
821

query I rowsort
SELECT + col1 * col0 * col2 AS col2 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT + cor0.col2 * 94 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
2503
2569
3589

query I rowsort
SELECT ( - col1 ) * + col2 + col2 * + col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - col0 + col2 + col0 * 6 FROM tab2 AS cor0
----
572
591
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - ( - tab0.col1 ) col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT tab0.col1 * tab0.col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT - 7 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

query I rowsort
SELECT DISTINCT - ( col1 ) AS col2 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT 70 * col1 + col1 FROM tab2 AS cor0
----
1207
2201
4189

query I rowsort
SELECT + 78 AS col2 FROM tab2 AS cor0
----
78
78
78

query I rowsort
SELECT col0 + col1 * - col0 FROM tab0 cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - col1 * - col1 * col1 + col2 AS col0 FROM tab2 AS cor0
----
205405
29818
4951

query I rowsort
SELECT DISTINCT + 25 * + cor0.col0 FROM tab2, tab1 AS cor0
----
1600
2000
75

query I rowsort
SELECT ALL + 44 * col2 - col2 FROM tab0 AS cor0
----
1419
3526
43

query I rowsort
SELECT 96 + - cor0.col2 FROM tab2 AS cor0
----
58
69
70

query I rowsort
SELECT DISTINCT - - col2 * + col0 + cor0.col1 + 36 AS col0 FROM tab0 AS cor0
----
168
7425
914

query I rowsort
SELECT ALL - - col0 + 82 * col0 AS col0 FROM tab2 AS cor0
----
581
6474
6557

query I rowsort
SELECT - col2 + + 40 AS col2 FROM tab0 cor0
----
-42
39
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4477
SELECT ALL + col2 DIV ( - col0 * - 81 ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4477
SELECT ALL + col2 / ( - col0 * - 81 ) FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 * - 25 col1 FROM tab2
----
-1875
-1875
-1875

query I rowsort
SELECT - ( - col1 + + col0 ) FROM tab0
----
2
62
62

query I rowsort
SELECT DISTINCT - ( - col1 ) * cor0.col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - 37 FROM tab1, tab0 cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

query I rowsort
SELECT cor0.col0 + - col2 * - col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL 72 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT - col1 + cor0.col0 + col2 * - col1 AS col0 FROM tab2 AS cor0
----
-1515
-584
-861

query I rowsort
SELECT + - cor0.col1 + col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT tab0.col1 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 82 * - cor0.col1 * - col0 col2 FROM tab2 AS cor0
----
110126
17794
377364

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4488
SELECT ALL + col0 * - col0 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4488
SELECT ALL + col0 * - col0 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( col1 ) * + col0 + col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT col2 + - col2 * col1 FROM tab0 cor0
----
-2805
-7380
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4491
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + 89 - cor0.col1 * 27 AS col0 FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4491
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + 89 - cor0.col1 * 27 AS col0 FROM tab0, tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + tab2.col0 ) col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT col1 * 13 AS col2 FROM tab1 AS cor0
----
130
169
338

query I rowsort
SELECT - col0 * - ( col2 ) AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col0 + cor0.col1 * + col1 AS col1 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4496
SELECT - - ( - 17 ) / col1 + CAST( NULL AS SIGNED ) col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4496
SELECT - - ( - 17 ) / col1 + CAST ( NULL AS INTEGER ) col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + 99 col2 FROM tab1 AS cor0
----
73
86
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4498
SELECT - - col0 - col0 DIV col1 FROM tab1 AS cor0
----
3
58
74

skipif mysql # not compatible
query I rowsort label-4498
SELECT - - col0 - col0 / col1 FROM tab1 AS cor0
----
3
58
74

query I rowsort
SELECT - 51 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 27bcc31433ce90833ed76619cbd8d6a4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4500
SELECT ALL - tab0.col0 DIV 62 AS col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4500
SELECT ALL - tab0.col0 / 62 AS col0 FROM tab0
----
-1
0
0

query I rowsort
SELECT + ( col2 ) * col1 - + 32 FROM tab2 AS cor0
----
1502
614
805

onlyif mysql # use DIV operator for integer division
query I rowsort label-4502
SELECT - col2 + col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-4502
SELECT - col2 + col0 / col0 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT DISTINCT + col2 + + 82 AS col1 FROM tab0 AS cor0
----
115
164
83

query I rowsort
SELECT cor0.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL 27 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT - 30 AS col0 FROM tab0
----
-30
-30
-30

query I rowsort
SELECT DISTINCT - 51 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
-51

query I rowsort
SELECT ALL col2 + col2 * - col2 + col0 FROM tab0 cor0
----
-1032
-6553
35

query I rowsort
SELECT DISTINCT col0 * col0 + + 17 FROM tab1 AS cor0
----
26
4113
6417

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4510
SELECT DISTINCT + col2 * col1 + CAST( NULL AS SIGNED ) * + col2 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4510
SELECT DISTINCT + col2 * col1 + CAST ( NULL AS INTEGER ) * + col2 AS col0 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4511
SELECT 51 * - cor0.col0 * CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
-32640
-3978
-53040

skipif mysql # not compatible
query I rowsort label-4511
SELECT 51 * - cor0.col0 * CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
-32640
-3978
-53040

query I rowsort
SELECT + + col2 * + cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + - cor0.col2 + 32 FROM tab1 AS cor0
----
-22
-25
-64

query I rowsort
SELECT ALL - - col1 * col2 + 48 FROM tab1 AS cor0
----
1296
1452
618

query I rowsort
SELECT + 54 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 81150d59d6c3fc48b4ef5a4a5495bc7a

query I rowsort
SELECT DISTINCT + + cor0.col0 * + 83 FROM tab2 AS cor0
----
581
6474
6557

query I rowsort
SELECT DISTINCT - - col2 * + 59 AS col0 FROM tab1 AS cor0
----
3186
3363
5664

query I rowsort
SELECT ALL cor0.col1 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4519
SELECT col2 * CAST( 54 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
2916
3078
5184

skipif mysql # not compatible
query I rowsort label-4519
SELECT col2 * CAST ( 54 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
2916
3078
5184

query I rowsort
SELECT cor0.col2 * - col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - + col0 * cor0.col2 + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT + cor0.col1 * + col2 + + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT - + 54 + cor0.col0 FROM tab2 AS cor0
----
-47
24
25

query I rowsort
SELECT + - 11 AS col1 FROM tab2 AS cor0
----
-11
-11
-11

query I rowsort
SELECT ALL ( - cor0.col1 ) * - col1 + + col1 * - ( col1 * col2 ) AS col1 FROM tab1 AS cor0
----
-16055
-35828
-5600

onlyif mysql # use DIV operator for integer division
query I rowsort label-4526
SELECT 29 DIV 69 + col2 * col0 * + col1 FROM tab0 AS cor0
----
3395
664118
68112

skipif mysql # not compatible
query I rowsort label-4526
SELECT 29 / 69 + col2 * col0 * + col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT - col1 - 47 AS col0 FROM tab0 AS cor0
----
-133
-138
-144

query I rowsort
SELECT ALL + + col0 - - col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL - ( + col1 ) * - col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + + col1 * col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - col1 + col2 + + 27 AS col2 FROM tab1 AS cor0
----
110
55
74

query I rowsort
SELECT ALL + col0 * col1 + - col1 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-4533
SELECT DISTINCT + cor0.col1 DIV + col1 + - 16 FROM tab0 AS cor0
----
-15

skipif mysql # not compatible
query I rowsort label-4533
SELECT DISTINCT + cor0.col1 / + col1 + - 16 FROM tab0 AS cor0
----
-15

query I rowsort
SELECT DISTINCT + col2 * - col2 + - col0 * + 18 FROM tab1 AS cor0
----
-10656
-2970
-4401

query I rowsort
SELECT ALL + + 75 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT ALL + ( col0 ) * - col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL - ( + col2 ) + col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT - 23 FROM tab0, tab0 AS cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT DISTINCT col2 * col2 + - col2 FROM tab1 cor0
----
2862
3192
9120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4540
SELECT col0 * col2 + + CAST( + 31 AS SIGNED ) * col0 AS col1 FROM tab1 AS cor0
----
10160
255
5632

skipif mysql # not compatible
query I rowsort label-4540
SELECT col0 * col2 + + CAST ( + 31 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
10160
255
5632

query I rowsort
SELECT 35 * col1 + - col0 FROM tab0 AS cor0
----
2986
3096
3360

query I rowsort
SELECT DISTINCT + 88 + col2 AS col2 FROM tab0 AS cor0
----
121
170
89

query I rowsort
SELECT - col1 * cor0.col0 + col0 * + col2 AS col2 FROM tab2 AS cor0
----
-2574
-28
1659

query I rowsort
SELECT 35 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
81 values hashing to ca814400b6361c20866ff8fe01717430

query I rowsort
SELECT - col2 * + col1 + - 87 AS col0 FROM tab2
----
-1621
-733
-924

query I rowsort
SELECT DISTINCT - ( - tab2.col2 + tab2.col2 ) FROM tab2
----
0

query I rowsort
SELECT ALL - - cor0.col0 * - col0 + cor0.col1 * + cor0.col1 - + col2 * ( col0 * cor0.col2 ) FROM tab2 cor0
----
-120028
-4191
-55331

query I rowsort
SELECT - ( 37 ) FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 395d44ccbce08828bc493e93ec3d9207

query I rowsort
SELECT ALL + cor0.col1 + + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL cor2.col0 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4551
SELECT tab1.col0 DIV 17 + ( + col2 ) FROM tab1
----
100
54
60

skipif mysql # not compatible
query I rowsort label-4551
SELECT tab1.col0 / 17 + ( + col2 ) FROM tab1
----
100
54
60

query I rowsort
SELECT col2 * col2 - + col2 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT ALL col0 - + col1 * 99 AS col2 FROM tab1
----
-1207
-2571
-926

query I rowsort
SELECT col2 * 39 - cor0.col1 AS col0 FROM tab2 AS cor0
----
1022
1465
955

query I rowsort
SELECT ALL - + ( 10 ) + col2 FROM tab1 AS cor0
----
44
47
86

query I rowsort
SELECT DISTINCT col2 * col2 + 61 - col1 * - 85 AS col1 FROM tab0
----
14520
8307
8460

query I rowsort
SELECT ALL col0 + 36 + tab1.col0 * col1 FROM tab1
----
1156
117
740

onlyif mysql # use DIV operator for integer division
query I rowsort label-4558
SELECT ALL col1 + + col1 DIV col2 AS col0 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4558
SELECT ALL col1 + + col1 / col2 AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL 88 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT ALL - tab1.col0 + + 76 - col0 FROM tab1
----
-52
-84
70

query I rowsort
SELECT ALL col0 + ( + col2 * col1 ) AS col1 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + 92 * col2 - col1 AS col1 FROM tab2 AS cor0
----
2333
2453
3479

query I rowsort
SELECT 28 - + col0 AS col1 FROM tab1 cor0
----
-36
-52
25

query I rowsort
SELECT DISTINCT 35 FROM tab0 cor0
----
35

query I rowsort
SELECT ALL - + 7 FROM tab2 AS cor0
----
-7
-7
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4566
SELECT DISTINCT CAST( - 85 AS SIGNED ) * col0 FROM tab1 AS cor0
----
-255
-5440
-6800

skipif mysql # not compatible
query I rowsort label-4566
SELECT DISTINCT CAST ( - 85 AS INTEGER ) * col0 FROM tab1 AS cor0
----
-255
-5440
-6800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4567
SELECT CAST( NULL AS SIGNED ) * col2 * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4567
SELECT CAST ( NULL AS INTEGER ) * col2 * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + - 36 FROM tab0 AS cor0
----
50
55
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4569
SELECT - CAST( 28 AS SIGNED ) * col2 FROM tab1 cor0
----
-1512
-1596
-2688

skipif mysql # not compatible
query I rowsort label-4569
SELECT - CAST ( 28 AS INTEGER ) * col2 FROM tab1 cor0
----
-1512
-1596
-2688

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * cor0.col0 col2 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT - + ( col0 ) * + col1 + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL - - 1 * - col0 AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT cor0.col0 * + col1 * col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT - 45 * - col2 AS col0 FROM tab1 AS cor0
----
2430
2565
4320

query I rowsort
SELECT - col0 + col2 * col1 AS col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT + + col1 + cor0.col1 * - col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT - - col1 + + col0 * + 90 * - col1 FROM tab0 AS cor0
----
-185674
-305453
-728819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4578
SELECT CAST( NULL AS DECIMAL ) + cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4578
SELECT CAST ( NULL AS REAL ) + cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4579
SELECT ALL col0 / + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4579
SELECT ALL col0 / + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 * + ( + ( col0 ) ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - 99 * col0 + col1 * - col2 - col2 AS col0 FROM tab0 AS cor0
----
-16355
-3563
-5247

query I rowsort
SELECT DISTINCT 56 * col0 + - 1 FROM tab1 AS cor0
----
167
3583
4479

query I rowsort
SELECT ALL col1 + + col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL - + col1 * cor0.col1 - - 42 AS col2 FROM tab2 AS cor0
----
-247
-3439
-919

query I rowsort
SELECT - col2 * - col0 - col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT + col2 + cor0.col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT 37 * + 52 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
1924

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4588
SELECT ALL 79 + col2 + CAST( - col1 AS SIGNED ) AS col2 FROM tab2
----
100
46
75

skipif mysql # not compatible
query I rowsort label-4588
SELECT ALL 79 + col2 + CAST ( - col1 AS INTEGER ) AS col2 FROM tab2
----
100
46
75

query I rowsort
SELECT + 44 + col2 AS col2 FROM tab1
----
101
140
98

query I rowsort
SELECT ALL - 3 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT DISTINCT - 50 * + col0 + cor0.col0 FROM tab1 cor0
----
-147
-3136
-3920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col1 + + col2 * cor0.col1 col2 FROM tab0 cor0
----
14924
194
5676

onlyif mysql # use DIV operator for integer division
query I rowsort label-4593
SELECT - col0 DIV ( - col0 ) + col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-4593
SELECT - col0 / ( - col0 ) + col2 FROM tab1 AS cor0
----
55
58
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4594
SELECT - col0 * + CAST( + col2 AS SIGNED ) - - col0 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif mysql # not compatible
query I rowsort label-4594
SELECT - col0 * + CAST ( + col2 AS INTEGER ) - - col0 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT col0 + ( col2 ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col0 + - col2 * 43 FROM tab0 cor0
----
-1443
-3615
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4597
SELECT 9 * + col2 DIV col2 FROM tab1
----
9
9
9

skipif mysql # not compatible
query I rowsort label-4597
SELECT 9 * + col2 / col2 FROM tab1
----
9
9
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4598
SELECT + ( col1 ) DIV 10 AS col1 FROM tab2
----
1
3
5

skipif mysql # not compatible
query I rowsort label-4598
SELECT + ( col1 ) / 10 AS col1 FROM tab2
----
1
3
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4599
SELECT col1 * col1 DIV col0 FROM tab1
----
1
2
225

skipif mysql # not compatible
query I rowsort label-4599
SELECT col1 * col1 / col0 FROM tab1
----
1
2
225

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 cor1, tab0 AS cor2
----
972 values hashing to 86dbd337f00ab84c613ad03d6fc06e28

query I rowsort
SELECT - col2 * 82 FROM tab1
----
-4428
-4674
-7872

query I rowsort
SELECT - col0 * ( + 37 ) * cor0.col2 - col1 FROM tab0 AS cor0
----
-1392
-270117
-29390

onlyif mysql # use DIV operator for integer division
query I rowsort label-4603
SELECT + - col1 - - cor0.col0 DIV - 46 AS col1 FROM tab2 AS cor0
----
-18
-31
-60

skipif mysql # not compatible
query I rowsort label-4603
SELECT + - col1 - - cor0.col0 / - 46 AS col1 FROM tab2 AS cor0
----
-18
-31
-60

query I rowsort
SELECT - col2 * 36 + col1 FROM tab0 cor0
----
-1102
-2861
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-4605
SELECT col0 DIV col0 - col0 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4605
SELECT col0 / col0 - col0 FROM tab0
----
-23
-34
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4606
SELECT + - CAST( col2 AS SIGNED ) * col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-4606
SELECT + - CAST ( col2 AS INTEGER ) * col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-4607
SELECT DISTINCT + 19 DIV - col2 AS col1 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-4607
SELECT DISTINCT + 19 / - col2 AS col1 FROM tab1
----
0

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2 cor2
----
972 values hashing to 72eb3d4d523f5d0c69d1b855edd18f4a

query I rowsort
SELECT + 95 - + col0 FROM tab1
----
15
31
92

query I rowsort
SELECT col2 * - col2 * + col0 AS col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - + col0 col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - + col2 * 66 FROM tab2 AS cor0
----
-1716
-1782
-2508

onlyif mysql # use DIV operator for integer division
query I rowsort label-4613
SELECT cor0.col2 DIV - cor0.col0 + - cor0.col0 * 56 FROM tab0 AS cor0
----
-1345
-1960
-4984

skipif mysql # not compatible
query I rowsort label-4613
SELECT cor0.col2 / - cor0.col0 + - cor0.col0 * 56 FROM tab0 AS cor0
----
-1345
-1960
-4984

query I rowsort
SELECT - + 85 FROM tab0 AS cor0
----
-85
-85
-85

query I rowsort
SELECT ALL + + 6 + ( col0 ) * cor0.col1 FROM tab2 AS cor0
----
1349
223
4608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col1 ) * - col2 col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4617
SELECT ALL col0 * 77 + + tab0.col2 * + col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4617
SELECT ALL col0 * 77 + + tab0.col2 * + col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col0 * + 25 + 31 AS col0 FROM tab2
----
1981
2006
206

query I rowsort
SELECT ALL col2 * col1 + col1 * col0 AS col0 FROM tab2
----
1054
1989
6136

query I rowsort
SELECT ALL - tab0.col1 * + ( + 13 ) + col0 * tab0.col1 FROM tab0
----
2134
6916
946

query I rowsort
SELECT DISTINCT - tab2.col2 FROM tab2, tab1 cor0
----
-26
-27
-38

query I rowsort
SELECT 73 FROM tab1, tab2 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT ALL + col2 * col0 - + cor0.col1 AS col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT ALL - ( cor0.col1 ) FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4625
SELECT ALL + cor0.col0 + - 96 * cor0.col2 DIV col0 - - col0 * col1 FROM tab2 cor0
----
-146
1376
4648

skipif mysql # not compatible
query I rowsort label-4625
SELECT ALL + cor0.col0 + - 96 * cor0.col2 / col0 - - col0 * col1 FROM tab2 cor0
----
-146
1376
4648

query I rowsort
SELECT ALL 40 * 35 + col0 FROM tab0 AS cor0
----
1424
1435
1489

query I rowsort
SELECT + + ( - 80 ) FROM tab2 AS cor0
----
-80
-80
-80

query I rowsort
SELECT ALL - col2 - + col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT DISTINCT 51 * ( col0 ) FROM tab0 AS cor0
----
1224
1785
4539

onlyif mysql # use DIV operator for integer division
query I rowsort label-4630
SELECT ALL col1 + col2 DIV col0 FROM tab0 cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-4630
SELECT ALL col1 + col2 / col0 FROM tab0 cor0
----
87
91
97

query I rowsort
SELECT ALL - ( - 36 ) FROM tab0 AS cor0
----
36
36
36

query I rowsort
SELECT DISTINCT - 79 + - col1 + col0 FROM tab0 AS cor0
----
-141
-81

query I rowsort
SELECT DISTINCT - cor0.col2 * - 7 * + col2 + 28 FROM tab2 AS cor0
----
10136
4760
5131

query I rowsort
SELECT DISTINCT col1 * + col0 - ( + col0 * + tab2.col1 + tab2.col0 ) AS col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL - tab2.col1 + - col2 - - col0 * - col1 FROM tab2
----
-1398
-275
-4687

query I rowsort
SELECT col0 + - col2 - col2 FROM tab1
----
-105
-112
-50

query I rowsort
SELECT DISTINCT + col0 * - col1 * col2 - - col0 * col1 AS col1 FROM tab1
----
-35840
-4134
-98800

onlyif mysql # use DIV operator for integer division
query I rowsort label-4638
SELECT - 56 DIV + cor0.col1 + 76 + col1 DIV cor0.col0 FROM tab1 AS cor0
----
71
72
82

skipif mysql # not compatible
query I rowsort label-4638
SELECT - 56 / + cor0.col1 + 76 + col1 / cor0.col0 FROM tab1 AS cor0
----
71
72
82

query I rowsort
SELECT + - col0 * + col2 * + col0 AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT DISTINCT + ( + col0 ) * ( - 94 + col2 * + 43 ) FROM tab2 AS cor0
----
121660
7469
79872

query I rowsort
SELECT - col1 * - col2 - - col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4642
SELECT + 92 DIV - cor0.col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4642
SELECT + 92 / - cor0.col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT 19 * + col1 + col2 AS col2 FROM tab0
----
1667
1811
1844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + ( col0 * cor0.col1 ) + col1 col1 FROM tab2 AS cor0
----
1322
221
4635

query I rowsort
SELECT DISTINCT + col0 + col2 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT - - cor0.col0 * - cor0.col1 + + 36 FROM tab1 AS cor0
----
-1004
-42
-604

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4647
SELECT + col2 + CAST( NULL AS SIGNED ) + col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4647
SELECT + col2 + CAST ( NULL AS INTEGER ) + col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor1.col0 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT + col2 + + col2 + col2 FROM tab0 AS cor0
----
246
3
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-4650
SELECT ALL - - col2 + + col0 DIV + cor0.col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-4650
SELECT ALL - - col2 + + col0 / + cor0.col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT cor0.col1 * col2 + - 69 + col1 * 3 * + col1 AS col2 FROM tab0 cor0
----
24957
28255
32236

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4652
SELECT ALL col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4652
SELECT ALL col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4653
SELECT DISTINCT + - col1 + 5 * - 75 + + col2 DIV 77 AS col0 FROM tab0 AS cor0
----
-461
-465
-472

skipif mysql # not compatible
query I rowsort label-4653
SELECT DISTINCT + - col1 + 5 * - 75 + + col2 / 77 AS col0 FROM tab0 AS cor0
----
-461
-465
-472

query I rowsort
SELECT col0 * + col1 + col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - + cor1.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
-24
-35
-89

query I rowsort
SELECT + col2 * 39 + col0 AS col2 FROM tab1 AS cor0
----
2109
2287
3824

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + + col1 col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - col1 * cor0.col2 + - ( + col0 + + col0 ) FROM tab1 AS cor0
----
-1408
-1410
-698

query I rowsort
SELECT col2 + + ( col2 ) + - col0 FROM tab2 AS cor0
----
-26
-3
47

query I rowsort
SELECT DISTINCT cor0.col1 * + col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - col0 * ( 8 ) AS col0 FROM tab1 AS cor0
----
-24
-512
-640

query I rowsort
SELECT + + col1 + + ( - col1 ) AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - col2 * + col2 - col2 AS col1 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT + + col2 + + col2 + + ( col0 ) AS col1 FROM tab2 AS cor0
----
130
155
61

query I rowsort
SELECT + col1 * col1 + + col1 * + col2 + col1 * + col0 FROM tab1 AS cor0
----
1310
2158
2457

query I rowsort
SELECT + + col1 - col1 * - col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + col0 * - ( + col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + cor0.col2 AS col1 FROM tab2, tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 23 * col0 + - col2 * col2 * col2 col0 FROM tab0 AS cor0
----
-22689
-369185
28174

query I rowsort
SELECT ALL + - cor0.col0 + + col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 + + ( col1 ) FROM tab0
----
119
173
98

query I rowsort
SELECT 40 + + col1 * col1 + + col1 * col2 AS col2 FROM tab1 AS cor0
----
1457
2120
710

onlyif mysql # use DIV operator for integer division
query I rowsort label-4673
SELECT ALL ( - cor0.col2 ) DIV 41 FROM tab1 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-4673
SELECT ALL ( - cor0.col2 ) / 41 FROM tab1 AS cor0
----
-1
-1
-2

query I rowsort
SELECT - 7 FROM tab0 cor0
----
-7
-7
-7

query I rowsort
SELECT DISTINCT + + col2 * col1 + - col0 AS col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT 54 - + col1 * - col0 FROM tab0 AS cor0
----
2118
3449
8153

onlyif mysql # use DIV operator for integer division
query I rowsort label-4677
SELECT DISTINCT + 77 DIV col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4677
SELECT DISTINCT + 77 / col1 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - cor0.col0 * + 1 col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - 15 - col1 * 21 FROM tab2
----
-1254
-372
-666

query I rowsort
SELECT ( - col2 ) + ( + ( col0 ) * col1 ) FROM tab1
----
24
583
944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col1 - + col1 * + col1 col2 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL - 42 + col1 AS col1 FROM tab1
----
-16
-29
-32

query I rowsort
SELECT - col0 - - cor0.col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT ALL - col0 * - col0 * - col2 FROM tab2
----
-1323
-158184
-237158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4685
SELECT + ( col0 ) * - CAST( + col2 AS SIGNED ) + + col2 AS col2 FROM tab0 cor0
----
-34
-7216
-759

skipif mysql # not compatible
query I rowsort label-4685
SELECT + ( col0 ) * - CAST ( + col2 AS INTEGER ) + + col2 AS col2 FROM tab0 cor0
----
-34
-7216
-759

query I rowsort
SELECT + + ( - col2 ) * col0 - + ( col2 ) AS col1 FROM tab2 cor0
----
-2054
-216
-3040

query I rowsort
SELECT ALL - 40 * - cor0.col2 FROM tab2 AS cor0
----
1040
1080
1520

query I rowsort
SELECT + tab0.col1 + col0 * - col0 + col0 FROM tab0
----
-1093
-466
-7741

query I rowsort
SELECT ALL col0 * col2 + + tab1.col2 * col2 AS col0 FROM tab1
----
16896
3078
6897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 26 col0 FROM tab2
----
26

query I rowsort
SELECT ALL + ( col2 ) - + col2 * col1 AS col2 FROM tab0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4692
SELECT - 50 DIV - col2 - ( 54 * - col2 ) AS col1 FROM tab0 AS cor0
----
104
1783
4428

skipif mysql # not compatible
query I rowsort label-4692
SELECT - 50 / - col2 - ( 54 * - col2 ) AS col1 FROM tab0 AS cor0
----
104
1783
4428

query I rowsort
SELECT - col2 * col0 + + 59 FROM tab1 AS cor0
----
-103
-3589
-7621

query I rowsort
SELECT ( - col0 ) AS col1 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT 56 FROM tab2, tab1 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT 48 + cor0.col2 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 713963ab4dfecf424d719d05d75b961d

query I rowsort
SELECT 88 FROM tab1, tab0 cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4698
SELECT + - col2 + - CAST( + 94 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-148
-151
-190

skipif mysql # not compatible
query I rowsort label-4698
SELECT + - col2 + - CAST ( + 94 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-148
-151
-190

onlyif mysql # use DIV operator for integer division
query I rowsort label-4699
SELECT + 65 DIV - 24 AS col1 FROM tab2 cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-4699
SELECT + 65 / - 24 AS col1 FROM tab2 cor0
----
-2
-2
-2

query I rowsort
SELECT cor0.col0 * + col0 + cor0.col2 AS col0 FROM tab0 cor0
----
1226
609
8003

query I rowsort
SELECT + 61 * 53 AS col0 FROM tab1 AS cor0
----
3233
3233
3233

query I rowsort
SELECT - col1 * col1 + col1 AS col2 FROM tab2
----
-272
-3422
-930

query I rowsort
SELECT + 47 FROM tab0, tab0 cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4704
SELECT - + col0 DIV + col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4704
SELECT - + col0 / + col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT ( + 70 ) AS col1 FROM tab1 AS cor0
----
70
70
70

query I rowsort
SELECT 54 * - col2 + - col0 AS col2 FROM tab0
----
-1806
-4517
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 36 - col2 col2 FROM tab2
----
-2
10
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4708
SELECT ALL + + CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-4708
SELECT ALL + + CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - + col2 * ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - - col2 * + col1 + cor0.col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - col2 * - cor0.col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL ( - col1 ) + + col1 * - col0 AS col0 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT - 13 * - cor0.col1 FROM tab1 AS cor0
----
130
169
338

query I rowsort
SELECT ALL + col1 + col0 * - 9 AS col0 FROM tab0 AS cor0
----
-130
-218
-710

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col2 * col2 col2 FROM tab2 AS cor0
----
17576
19683
54872

onlyif mysql # use DIV operator for integer division
query I rowsort label-4716
SELECT ALL + + col1 DIV + col1 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4716
SELECT ALL + + col1 / + col1 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + + col2 * col1 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 9 + + col1 FROM tab2 AS cor0
----
26
40
68

query I rowsort
SELECT + 4 + + col2 - - cor0.col1 AS col1 FROM tab2 cor0
----
59
62
89

query I rowsort
SELECT DISTINCT + col0 * + col0 + + 27 AS col1 FROM tab1 AS cor0
----
36
4123
6427

query I rowsort
SELECT DISTINCT 75 * + col2 FROM tab2
----
1950
2025
2850

query I rowsort
SELECT - col1 * ( 43 ) FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT DISTINCT + + col2 * col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - - col2 * + 41 FROM tab1 AS cor0
----
2214
2337
3936

query I rowsort
SELECT ALL 58 * col2 FROM tab2
----
1508
1566
2204

query I rowsort
SELECT + 43 * col2 AS col2 FROM tab0
----
1419
3526
43

query I rowsort
SELECT ALL + - col1 + 81 AS col2 FROM tab0 cor0
----
-10
-16
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4728
SELECT ALL col1 DIV 55 + + 83 AS col1 FROM tab0 AS cor0
----
84
84
84

skipif mysql # not compatible
query I rowsort label-4728
SELECT ALL col1 / 55 + + 83 AS col1 FROM tab0 AS cor0
----
84
84
84

query I rowsort
SELECT ALL - 50 FROM tab1, tab0 AS cor0
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT 25 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

query I rowsort
SELECT + col1 * 80 AS col1 FROM tab0 AS cor0
----
6880
7280
7760

query I rowsort
SELECT ALL col0 * - col0 + 52 FROM tab0 AS cor0
----
-1173
-524
-7869

query I rowsort
SELECT + col0 * col2 + cor0.col2 AS col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-4734
SELECT ALL col0 DIV - col1 col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4734
SELECT ALL col0 / - col1 col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4735
SELECT ALL + col2 * + ( cor0.col1 ) + col1 DIV col1 - col2 * col0 col1 FROM tab0 AS cor0
----
165
2047
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4735
SELECT ALL + col2 * + ( cor0.col1 ) + col1 / col1 - col2 * col0 col1 FROM tab0 AS cor0
----
165
2047
63

query I rowsort
SELECT DISTINCT col0 * col2 + cor0.col1 AS col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL col0 - - ( 74 ) AS col0 FROM tab0 AS cor0
----
109
163
98

query I rowsort
SELECT - col2 * 99 FROM tab1 AS cor0
----
-5346
-5643
-9504

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col0 - + ( 5 ) col2 FROM tab2
----
-54
-6089
-6246

query I rowsort
SELECT DISTINCT + + cor0.col0 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + - col2 * + col2 + 81 FROM tab0 AS cor0
----
-1008
-6643
80

query I rowsort
SELECT ALL - - col0 + + col1 AS col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT + - cor0.col1 + - col2 AS col1 FROM tab0 cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col1 - + col2 col1 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT ALL + col2 * + col1 + + col0 AS col2 FROM tab0 AS cor0
----
132
2862
7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 4 - 39 * tab1.col1 col2 FROM tab1
----
-123
-162
-798

query I rowsort
SELECT - col2 + - ( col1 ) AS col0 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4748
SELECT ALL + col1 DIV + col0 + ( - col2 ) DIV col0 FROM tab1 cor0
----
-1
-10
0

skipif mysql # not compatible
query I rowsort label-4748
SELECT ALL + col1 / + col0 + ( - col2 ) / col0 FROM tab1 cor0
----
-1
-10
0

query I rowsort
SELECT ALL - col0 * + col2 + - col2 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT col0 + - col1 * + col1 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT cor0.col2 * col1 * 13 AS col2 FROM tab1 AS cor0
----
16224
18252
7410

query I rowsort
SELECT ALL + col0 * - cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + 45 + + col2 FROM tab2 AS cor0
----
71
72
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4754
SELECT ALL col2 + - col0 * col1 DIV col1 AS col0 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-4754
SELECT ALL col2 + - col0 * col1 / col1 AS col0 FROM tab0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 col2 FROM tab0 WHERE NULL >= - col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4756
SELECT - col1 + + col0 DIV col0 FROM tab1
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-4756
SELECT - col1 + + col0 / col0 FROM tab1
----
-12
-25
-9

query III rowsort
SELECT * FROM tab0 WHERE NOT - col0 IN ( + col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT IN ( + col2 * col1 * + col0 )
----

query I rowsort
SELECT ALL col2 * col2 + - col0 * + col1 * col2 + - 34 FROM tab0
----
-3428
-657428
-67057

query I rowsort
SELECT 81 * col2 - 78 AS col0 FROM tab2
----
2028
2109
3000

query I rowsort
SELECT ALL + 39 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT ALL + 38 + col2 FROM tab0 AS cor0
----
120
39
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4763
SELECT ALL - CAST( NULL AS SIGNED ) FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4763
SELECT ALL - CAST ( NULL AS INTEGER ) FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - col0 + col0 * 4 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT DISTINCT - 36 + - col2 FROM tab2 cor0
----
-62
-63
-74

query I rowsort
SELECT 90 * + col1 AS col1 FROM tab0 cor0
----
7740
8190
8730

query I rowsort
SELECT 28 AS col1 FROM tab1
----
28
28
28

query I rowsort
SELECT ALL 12 AS col2 FROM tab2 AS cor0
----
12
12
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-4769
SELECT col2 * col1 DIV col0 AS col0 FROM tab1 AS cor0
----
15
468
8

skipif mysql # not compatible
query I rowsort label-4769
SELECT col2 * col1 / col0 AS col0 FROM tab1 AS cor0
----
15
468
8

query I rowsort
SELECT ALL - - col0 + - col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col2 + + col2 * ( - col1 ) FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT 92 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4773
SELECT DISTINCT - col2 * + CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4773
SELECT DISTINCT - col2 * + CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col2 + col1 * + 20 AS col1 FROM tab2 AS cor0
----
1206
378
647

onlyif mysql # use DIV operator for integer division
query I rowsort label-4775
SELECT + col2 DIV + 91 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4775
SELECT + col2 / + 91 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT - col1 * - col1 AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT col0 * - ( - col1 + col2 ) AS col2 FROM tab1
----
-3008
-6640
-84

query I rowsort
SELECT + + col2 * cor0.col1 + - 35 AS col2 FROM tab1 AS cor0
----
1213
1369
535

query I rowsort
SELECT ALL col2 * 77 + - col2 * - col0 AS col2 FROM tab2 cor0
----
2268
4030
5928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4780
SELECT DISTINCT - col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4780
SELECT DISTINCT - col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT cor0.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-4782
SELECT col1 * - col1 + col2 * + col1 - 48 DIV - 28 AS col0 FROM tab2 AS cor0
----
-123
-1946
358

skipif mysql # not compatible
query I rowsort label-4782
SELECT col1 * - col1 + col2 * + col1 - 48 / - 28 AS col0 FROM tab2 AS cor0
----
-123
-1946
358

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col1 * 16 col2 FROM tab2 AS cor0
----
-193
-489
-866

query I rowsort
SELECT - - col1 * + 66 * col1 + col0 FROM tab2 AS cor0
----
19153
229824
63433

query I rowsort
SELECT - col2 * 99 + - 13 AS col1 FROM tab1 cor0
----
-5359
-5656
-9517

query I rowsort
SELECT col2 + + ( col2 ) AS col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT cor0.col2 * + 58 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c267c64cd97d9160be19dbf12d8b9b64

query I rowsort
SELECT ALL col0 * + 85 + col0 + - ( 95 * col0 ) AS col2 FROM tab1 cor0
----
-27
-576
-720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4789
SELECT DISTINCT CAST( - col1 AS SIGNED ) * + col1 + col2 FROM tab2 cor0
----
-251
-3455
-934

skipif mysql # not compatible
query I rowsort label-4789
SELECT DISTINCT CAST ( - col1 AS INTEGER ) * + col1 + col2 FROM tab2 cor0
----
-251
-3455
-934

query I rowsort
SELECT + + 35 + + 54 AS col1 FROM tab1 AS cor0
----
89
89
89

query I rowsort
SELECT ALL + ( + col0 ) + - col2 * col2 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT + - 24 FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT + 12 * - col0 AS col1 FROM tab2 AS cor0
----
-84
-936
-948

onlyif mysql # use DIV operator for integer division
query I rowsort label-4794
SELECT ALL 16 * - col0 + + col0 DIV + col0 + - col2 DIV ( col0 + - col2 ) FROM tab2 AS cor0
----
-110
-1247
-1263

skipif mysql # not compatible
query I rowsort label-4794
SELECT ALL 16 * - col0 + + col0 / + col0 + - col2 / ( col0 + - col2 ) FROM tab2 AS cor0
----
-110
-1247
-1263

query I rowsort
SELECT ALL + - 7 + - col1 + 93 * col0 AS col2 FROM tab1 AS cor0
----
246
5935
7420

onlyif mysql # use DIV operator for integer division
query I rowsort label-4796
SELECT DISTINCT + col1 DIV + col1 AS col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-4796
SELECT DISTINCT + col1 / + col1 AS col0 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col0 * + col2 col0 FROM tab0 AS cor0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 17 col1 FROM tab2
----
17
17
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-4799
SELECT + col2 DIV - col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4799
SELECT + col2 / - col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col0 * + tab2.col1 * + col2 AS col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT + col0 * + col2 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col1 * tab0.col1 * col1 AS col0 FROM tab0
----
636056
753571
912673

query IIIIII rowsort
SELECT * FROM tab0, tab1 cor0 WHERE NOT NULL < NULL
----

query I rowsort
SELECT cor0.col1 * cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 16ae0e1090cb09b93854a4788f17716b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4805
SELECT + col2 DIV col1 AS col2 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4805
SELECT + col2 / col1 AS col2 FROM tab2
----
0
0
2

query I rowsort
SELECT tab0.col0 * col0 + col2 AS col0 FROM tab0
----
1226
609
8003

query I rowsort
SELECT - ( + tab2.col0 ) AS col0 FROM tab2
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 0 * col0 * + tab2.col2 col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + col1 + 86 AS col1 FROM tab2
----
103
117
145

query I rowsort
SELECT col2 * + 89 * col0 FROM tab0
----
3115
649522
70488

query I rowsort
SELECT ( col2 ) * col1 * + col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT col1 * - 74 * + col0 AS col0 FROM tab1
----
-47360
-5772
-76960

query I rowsort
SELECT DISTINCT + col2 * + col1 * col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT ALL cor1.col1 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - + 27 FROM tab2 cor0
----
-27
-27
-27

query I rowsort
SELECT DISTINCT col1 * + 37 * - col1 AS col2 FROM tab2
----
-10693
-128797
-35557

query I rowsort
SELECT - 85 AS col0 FROM tab0
----
-85
-85
-85

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) = ( - col1 )
----

query I rowsort
SELECT ALL + col1 * tab0.col2 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT tab1.col2 + col2 AS col0 FROM tab1
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col1 + - col2 * - col0 * col1 col0 FROM tab2
----
115050
49691
5642

query I rowsort
SELECT ALL - col0 + + col2 * col1 AS col2 FROM tab0
----
2814
62
7373

query I rowsort
SELECT + col0 * - col1 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - tab2.col1 FROM tab2 WHERE NULL = ( NULL )
----

query III rowsort
SELECT * FROM tab2 WHERE NULL IN ( tab2.col2 + + tab2.col0 * col0 * - col0 + + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4826
SELECT col1 DIV - col1 + + cor0.col2 * - cor0.col0 * - col2 FROM tab0 AS cor0
----
26135
34
598435

skipif mysql # not compatible
query I rowsort label-4826
SELECT col1 / - col1 + + cor0.col2 * - cor0.col0 * - col2 FROM tab0 AS cor0
----
26135
34
598435

query III rowsort
SELECT * FROM tab2 WHERE NULL IN ( col2 * col2 )
----

query I rowsort
SELECT DISTINCT + tab2.col0 + - col2 * tab2.col1 AS col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT col1 * - tab1.col1 + col2 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT DISTINCT tab2.col0 + - col2 FROM tab2
----
-20
41
52

query III rowsort
SELECT ALL * FROM tab1 WHERE ( - col0 ) NOT IN ( col0 + col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - col2 AS col0 FROM tab2 WHERE NULL >= col2 * col1
----

query I rowsort
SELECT DISTINCT col1 + tab0.col0 AS col1 FROM tab0
----
110
132
180

query III rowsort
SELECT * FROM tab1 WHERE NOT + col2 NOT IN ( col2 * + tab1.col1 * + col0 )
----

query I rowsort
SELECT ALL col0 * + col0 + + col2 FROM tab1
----
4153
63
6496

query I rowsort
SELECT - tab2.col0 / col0 + + tab2.col2 AS col2 FROM tab2 WHERE NOT + col2 / + col1 NOT IN ( col2 )
----

query I rowsort
SELECT col2 + - col1 * - tab2.col0 * col0 FROM tab2
----
106135
1546
358982

query I rowsort
SELECT DISTINCT + col2 - - col1 * - col0 AS col2 FROM tab0 WHERE NOT NULL < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 * - col2 col0 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - col0 + col2 * cor0.col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - col1 - + col2 AS col2 FROM tab1
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4842
SELECT DISTINCT + tab0.col2 - col1 DIV col2 FROM tab0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-4842
SELECT DISTINCT + tab0.col2 - col1 / col2 FROM tab0
----
-96
31
81

query I rowsort
SELECT + tab1.col2 * col0 AS col2 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col0 col0 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4845
SELECT cor0.col2 + - col0 DIV + col2 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-4845
SELECT cor0.col2 + - col0 / + col2 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT ALL col2 + - cor0.col1 + col2 AS col2 FROM tab1 cor0
----
104
179
82

query I rowsort
SELECT DISTINCT + + cor0.col1 * col0 + - col2 * col0 + cor0.col2 FROM tab0 AS cor0
----
1305
3361
883

query I rowsort
SELECT - col0 FROM tab2 AS cor0 WHERE NOT ( NULL ) IN ( col0 ) OR NOT col1 + + col2 <> NULL
----

query I rowsort
SELECT DISTINCT col0 * + col1 + cor0.col1 + + col0 FROM tab2 AS cor0
----
1439
255
4739

query I rowsort
SELECT ALL - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT cor0.col0 * col2 + + cor0.col2 FROM tab0 AS cor0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col1 col1 FROM tab2 AS cor0
----
55
58
85

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col1 > col2
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL col1 + 5 + - tab2.col2 * col0 FROM tab2
----
-153
-1964
-2980

onlyif mysql # use DIV operator for integer division
query I rowsort label-4855
SELECT ALL ( 57 ) DIV - col0 AS col0 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-4855
SELECT ALL ( 57 ) / - col0 AS col0 FROM tab0
----
-1
-2
0

query I rowsort
SELECT ALL col0 + - col0 + + col1 * + col0 AS col1 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col2 * 36 + - col2 col2 FROM tab2
----
1330
910
945

onlyif mysql # use DIV operator for integer division
query I rowsort label-4858
SELECT DISTINCT + col0 DIV ( col2 ) AS col1 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-4858
SELECT DISTINCT + col0 / ( col2 ) AS col1 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT DISTINCT - ( 31 ) AS col0 FROM tab2 AS cor0
----
-31

query I rowsort
SELECT ALL cor0.col0 * 73 FROM tab1 cor0
----
219
4672
5840

query I rowsort
SELECT DISTINCT - 68 + col0 AS col2 FROM tab2 AS cor0
----
-61
10
11

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT + col2 + + col1 + - ( col2 ) FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) + ( col2 ) col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - 19 * + col2 FROM tab0 cor0
----
-1558
-19
-627

onlyif mysql # use DIV operator for integer division
query I rowsort label-4866
SELECT - cor0.col0 + col2 DIV 75 AS col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-4866
SELECT - cor0.col0 + col2 / 75 AS col0 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4867
SELECT ALL col1 * col2 DIV 5 AS col0 FROM tab0 AS cor0
----
1492
19
567

skipif mysql # not compatible
query I rowsort label-4867
SELECT ALL col1 * col2 / 5 AS col0 FROM tab0 AS cor0
----
1492
19
567

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col0 ) - col0 col1 FROM tab2
----
-14
-156
-158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4869
SELECT DISTINCT CAST( NULL AS SIGNED ) * 40 - - col2 * + col0 col0 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4869
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 40 - - col2 * + col0 col0 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4870
SELECT DISTINCT - 69 + col0 DIV - col1 + col1 FROM tab2
----
-11
-38
-56

skipif mysql # not compatible
query I rowsort label-4870
SELECT DISTINCT - 69 + col0 / - col1 + col1 FROM tab2
----
-11
-38
-56

query I rowsort
SELECT - 96 * - cor0.col0 FROM tab2 AS cor0
----
672
7488
7584

query I rowsort
SELECT - + col0 + col1 * - 55 AS col2 FROM tab2 AS cor0
----
-1014
-1712
-3323

query I rowsort
SELECT - col2 + col0 * 64 FROM tab0 AS cor0
----
1503
2239
5614

query I rowsort
SELECT ALL + + col0 * + col0 - col0 * col1 FROM tab2 AS cor0
----
-168
1482
4898

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4875
SELECT ALL + col1 * - CAST( NULL AS SIGNED ) + 60 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4875
SELECT ALL + col1 * - CAST ( NULL AS INTEGER ) + 60 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col1 + + cor0.col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL col2 * 77 FROM tab2 AS cor0
----
2002
2079
2926

query I rowsort
SELECT DISTINCT - col0 + + ( col0 ) FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - + col0 * - col0 * col2 AS col1 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT ALL + col2 + col2 + col2 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT + col0 * 45 FROM tab2 cor0
----
315
3510
3555

query I rowsort
SELECT ALL - col1 + + col0 AS col2 FROM tab1 cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-4883
SELECT ALL + 44 * + col2 + col1 DIV - ( + col0 ) FROM tab1
----
2368
2508
4224

skipif mysql # not compatible
query I rowsort label-4883
SELECT ALL + 44 * + col2 + col1 / - ( + col0 ) FROM tab1
----
2368
2508
4224

query I rowsort
SELECT ALL + col2 * + 18 + 75 + col2 FROM tab2 AS cor0
----
569
588
797

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col2 + CAST ( - 29 AS REAL ) AS col0 FROM tab2 AS cor0
----
-55
-56
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-4886
SELECT DISTINCT col2 DIV + col1 - - col0 AS col2 FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-4886
SELECT DISTINCT col2 / + col1 - - col0 AS col2 FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT ALL - col0 + + col1 AS col1 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4888
SELECT + col1 + + CAST( col0 AS SIGNED ) * col1 FROM tab2 cor0
----
1360
248
4661

skipif mysql # not compatible
query I rowsort label-4888
SELECT + col1 + + CAST ( col0 AS INTEGER ) * col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT tab2.col2 + 92 AS col0 FROM tab2
----
118
119
130

query I rowsort
SELECT - 20 AS col2 FROM tab0 cor0
----
-20
-20
-20

query I rowsort
SELECT 68 + - 10 FROM tab2 AS cor0
----
58
58
58

query I rowsort
SELECT + cor0.col0 + 47 + col0 FROM tab0 AS cor0
----
117
225
95

query I rowsort
SELECT ALL - - 55 + + cor0.col1 FROM tab2 AS cor0
----
114
72
86

query I rowsort
SELECT ALL col2 + + 4 FROM tab1 AS cor0
----
100
58
61

query I rowsort
SELECT DISTINCT + + ( - cor0.col2 ) AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - - ( + 94 ) AS col0 FROM tab1 AS cor0
----
94
94
94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4897
SELECT CAST( + col1 * - col2 AS SIGNED ) FROM tab2
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-4897
SELECT CAST ( + col1 * - col2 AS INTEGER ) FROM tab2
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4898
SELECT + cor0.col1 + + CAST( + 6 AS SIGNED ) FROM tab1 AS cor0
----
16
19
32

skipif mysql # not compatible
query I rowsort label-4898
SELECT + cor0.col1 + + CAST ( + 6 AS INTEGER ) FROM tab1 AS cor0
----
16
19
32

query I rowsort
SELECT DISTINCT - 46 + col2 AS col1 FROM tab1
----
11
50
8

query I rowsort
SELECT - 6 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

query I rowsort
SELECT - - col1 + col0 * - col0 AS col2 FROM tab1 cor0
----
-4086
-6387
17

query I rowsort
SELECT ALL - col1 + + 76 * + cor0.col0 FROM tab0 cor0
----
1738
2563
6673

query I rowsort
SELECT ALL + col2 * col0 - + col1 * col0 * - 88 AS col1 FROM tab0 AS cor0
----
182424
298795
720010

query I rowsort
SELECT - 62 - col1 * col2 AS col0 FROM tab2
----
-1596
-708
-899

query I rowsort
SELECT - 43 * col2 FROM tab0 AS cor0
----
-1419
-3526
-43

query I rowsort
SELECT DISTINCT + - cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT col2 * + col2 + - col2 * col0 FROM tab2 AS cor0
----
-1352
-1558
540

query I rowsort
SELECT DISTINCT 15 + - col0 AS col1 FROM tab2 AS cor0
----
-63
-64
8

query I rowsort
SELECT + 6 * - col1 + col0 FROM tab0 cor0
----
-457
-492
-547

query I rowsort
SELECT - 24 + - col0 AS col2 FROM tab2 AS cor0
----
-102
-103
-31

query I rowsort
SELECT col0 * col2 * col1 FROM tab2 cor0
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-4912
SELECT ALL - + col0 DIV cor0.col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4912
SELECT ALL - + col0 / cor0.col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - col0 * - 71 FROM tab2 cor0
----
497
5538
5609

query I rowsort
SELECT - col2 + 30 * - col1 AS col1 FROM tab0 AS cor0
----
-2613
-2812
-2911

query I rowsort
SELECT col1 + 25 FROM tab2 AS cor0
----
42
56
84

query I rowsort
SELECT + - ( - cor1.col1 ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ( - ( + col0 ) ) * + 17 + - col2 FROM tab2 AS cor0
----
-1352
-1381
-146

query I rowsort
SELECT col0 * ( - cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - col2 + col1 * + col0 * + 39 FROM tab1 AS cor0
----
24903
2988
40464

onlyif mysql # use DIV operator for integer division
query I rowsort label-4920
SELECT ALL col2 DIV 81 + col2 FROM tab0
----
1
33
83

skipif mysql # not compatible
query I rowsort label-4920
SELECT ALL col2 / 81 + col2 FROM tab0
----
1
33
83

query I rowsort
SELECT - + col0 * + 59 FROM tab2 AS cor0
----
-413
-4602
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-4922
SELECT + col1 DIV - ( col1 + - col2 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4922
SELECT + col1 / - ( col1 + - col2 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 + + CAST ( col2 AS REAL ) AS col2 FROM tab0
----
0

query I rowsort
SELECT 52 * + col1 FROM tab0
----
4472
4732
5044

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 56 + col2 * cor0.col0 col2 FROM tab0 cor0
----
-21
7242
736

query I rowsort
SELECT DISTINCT + - 19 + cor0.col2 FROM tab0 AS cor0
----
-18
14
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4927
SELECT ALL 80 * col2 + + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
4294
4550
7667

skipif mysql # not compatible
query I rowsort label-4927
SELECT ALL 80 * col2 + + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
4294
4550
7667

query I rowsort
SELECT + col0 + - cor0.col2 * col1 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 46 * - tab1.col2 col0 FROM tab1
----
-2484
-2622
-4416

onlyif mysql # use DIV operator for integer division
query I rowsort label-4930
SELECT ALL tab2.col0 + 54 DIV + col0 + - 24 FROM tab2
----
-10
54
55

skipif mysql # not compatible
query I rowsort label-4930
SELECT ALL tab2.col0 + 54 / + col0 + - 24 FROM tab2
----
-10
54
55

query I rowsort
SELECT 42 * + 62 AS col1 FROM tab2
----
2604
2604
2604

query I rowsort
SELECT ALL + 43 * col0 - + col0 AS col0 FROM tab1 AS cor0
----
126
2688
3360

query I rowsort
SELECT DISTINCT + col2 * + col0 - + ( 60 + col1 ) AS col2 FROM tab2 AS cor0
----
1909
2925
98

query I rowsort
SELECT + cor0.col2 + col0 * - 8 * - col1 FROM tab1 AS cor0
----
5177
678
8416

query I rowsort
SELECT ALL - ( - cor0.col1 ) * + col0 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + col0 col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4937
SELECT ALL col2 DIV cor0.col0 - + col2 AS col1 FROM tab2 AS cor0
----
-24
-26
-38

skipif mysql # not compatible
query I rowsort label-4937
SELECT ALL col2 / cor0.col0 - + col2 AS col1 FROM tab2 AS cor0
----
-24
-26
-38

query I rowsort
SELECT + 8 * + col2 + 55 AS col1 FROM tab0
----
319
63
711

query I rowsort
SELECT DISTINCT col2 + - col0 * + ( ( + col2 ) * + ( tab0.col0 ) ) FROM tab0
----
-1224
-18975
-649440

query I rowsort
SELECT - col2 * tab1.col2 + + col1 * + col0 * col0 FROM tab1
----
-2682
37711
73984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col1 - + col2 col1 FROM tab1
----
43
622
73

query I rowsort
SELECT ALL + col1 + col1 * - 77 FROM tab1
----
-1976
-760
-988

query I rowsort
SELECT ALL 70 + col0 FROM tab2
----
148
149
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4944
SELECT ALL - 2 * - col2 + - tab2.col2 DIV 76 FROM tab2
----
52
54
76

skipif mysql # not compatible
query I rowsort label-4944
SELECT ALL - 2 * - col2 + - tab2.col2 / 76 FROM tab2
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4945
SELECT ALL + col1 * - col2 + ( col2 ) DIV - col2 FROM tab1 cor0
----
-1249
-1405
-571

skipif mysql # not compatible
query I rowsort label-4945
SELECT ALL + col1 * - col2 + ( col2 ) / - col2 FROM tab1 cor0
----
-1249
-1405
-571

onlyif mysql # use DIV operator for integer division
query I rowsort label-4946
SELECT DISTINCT - cor0.col1 DIV col1 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-10
-4097
-6401

skipif mysql # not compatible
query I rowsort label-4946
SELECT DISTINCT - cor0.col1 / col1 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-10
-4097
-6401

query I rowsort
SELECT + - 68 * col0 + + 66 FROM tab0 AS cor0
----
-1566
-2314
-5986

onlyif mysql # use DIV operator for integer division
query I rowsort label-4948
SELECT DISTINCT 84 * col0 + + col1 DIV + col1 AS col2 FROM tab2
----
589
6553
6637

skipif mysql # not compatible
query I rowsort label-4948
SELECT DISTINCT 84 * col0 + + col1 / + col1 AS col2 FROM tab2
----
589
6553
6637

onlyif mysql # use DIV operator for integer division
query I rowsort label-4949
SELECT ALL 20 DIV + 80 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4949
SELECT ALL 20 / + 80 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + col1 + - tab1.col1 * - tab1.col1 FROM tab1
----
110
182
702

query I rowsort
SELECT + 40 FROM tab1, tab1 cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT DISTINCT - tab2.col0 * col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT 73 * + cor0.col2 FROM tab2 AS cor0
----
1898
1971
2774

query I rowsort
SELECT - 37 + ( col0 + - 45 ) * col1 AS col1 FROM tab1 AS cor0
----
-1129
153
418

onlyif mysql # use DIV operator for integer division
query I rowsort label-4955
SELECT - ( + col0 ) DIV + col0 - + 32 * - col2 AS col1 FROM tab0 AS cor0
----
1055
2623
31

skipif mysql # not compatible
query I rowsort label-4955
SELECT - ( + col0 ) / + col0 - + 32 * - col2 AS col1 FROM tab0 AS cor0
----
1055
2623
31

query I rowsort
SELECT ( - col1 ) + - col0 AS col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT - + 81 * 60 FROM tab2 AS cor0
----
-4860
-4860
-4860

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col2 - + col2 col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT 79 * 40 FROM tab0 AS cor0
----
3160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4960
SELECT ( + col1 ) * + col2 / - 26 - 48 * + cor0.col0 * + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4960
SELECT ( + col1 ) * + col2 / - 26 - 48 * + cor0.col0 * + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - col2 ) * cor0.col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col2 + + col2 * col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT DISTINCT - col2 * ( + col1 ) AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL ( col2 ) + col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - 43 + + 46 * + col2 * - col1 AS col0 FROM tab2 AS cor0
----
-29759
-38545
-70607

query I rowsort
SELECT DISTINCT col2 + + cor0.col2 * - col1 AS col1 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4967
SELECT ALL + 88 * ( - col0 ) DIV + 99 + col1 FROM tab1 AS cor0
----
-46
-58
24

skipif mysql # not compatible
query I rowsort label-4967
SELECT ALL + 88 * ( - col0 ) / + 99 + col1 FROM tab1 AS cor0
----
-46
-58
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * tab0.col1 col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + ( tab1.col1 + - col2 * col0 ) FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT 41 + col0 FROM tab0
----
130
65
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4971
SELECT ( + col1 ) * col2 * + col2 + + col0 DIV - ( - col1 ) AS col0 FROM tab2
----
22599
24552
39885

skipif mysql # not compatible
query I rowsort label-4971
SELECT ( + col1 ) * col2 * + col2 + + col0 / - ( - col1 ) AS col0 FROM tab2
----
22599
24552
39885

query I rowsort
SELECT + col2 * + tab0.col2 + - col1 FROM tab0
----
-96
1003
6633

query I rowsort
SELECT - col2 + col0 * - col1 FROM tab2
----
-1381
-244
-4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + cor0.col2 + - 76 col2 FROM tab0 AS cor0
----
-41
716
7222

query I rowsort
SELECT 19 + - col2 * 24 FROM tab2
----
-605
-629
-893

query I rowsort
SELECT ( - col0 ) * - 87 + - col0 * - col2 * + col2 AS col2 FROM tab0
----
28224
3080
606179

query I rowsort
SELECT - + col0 * ( 94 ) AS col1 FROM tab2 AS cor0
----
-658
-7332
-7426

query I rowsort
SELECT DISTINCT + col0 + cor0.col2 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL - - col2 * + 91 AS col0 FROM tab1 AS cor0
----
4914
5187
8736

query I rowsort
SELECT DISTINCT - - col2 * 22 - 85 * + col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT ALL - col2 * col1 * - 70 + col1 * - col2 * col1 FROM tab1 AS cor0
----
34200
61776
71136

query I rowsort
SELECT DISTINCT col0 + ( + cor0.col0 ) * col1 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - col2 * + 71 + col0 FROM tab1 cor0
----
-3831
-3983
-6736

query I rowsort
SELECT ALL + col1 * 41 + col0 * col2 FROM tab2 cor0
----
1460
3699
4447

query I rowsort
SELECT DISTINCT + col0 * ( - cor0.col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + col2 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - 9 + - ( + col0 + 85 ) FROM tab0 AS cor0
----
-118
-129
-183

query I rowsort
SELECT + col2 + - col2 + + col2 AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 AS col0 FROM tab1 cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4990
SELECT DISTINCT + col0 * - col1 + - col0 DIV cor0.col2 AS col0 FROM tab0 AS cor0
----
-2064
-3430
-8100

skipif mysql # not compatible
query I rowsort label-4990
SELECT DISTINCT + col0 * - col1 + - col0 / cor0.col2 AS col0 FROM tab0 AS cor0
----
-2064
-3430
-8100

query I rowsort
SELECT - col1 * + 44 FROM tab0 cor0
----
-3784
-4004
-4268

query I rowsort
SELECT ALL ( col1 ) * col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - 24 FROM tab1 cor0
----
-24

query I rowsort
SELECT - - col2 * col0 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL - col2 * 48 AS col0 FROM tab1 AS cor0
----
-2592
-2736
-4608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) * col1 + col1 col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT col1 * 62 AS col1 FROM tab0 AS cor0
----
5332
5642
6014

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4998
SELECT - col2 + col1 + + cor0.col2 * - CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
-185
-1995
-3023

skipif mysql # not compatible
query I rowsort label-4998
SELECT - col2 + col1 + + cor0.col2 * - CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
-185
-1995
-3023

query I rowsort
SELECT col2 * + col2 + - 62 FROM tab1 AS cor0
----
2854
3187
9154

onlyif mysql # use DIV operator for integer division
query I rowsort label-5000
SELECT ALL + - col2 DIV - cor0.col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5000
SELECT ALL + - col2 / - cor0.col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT ALL 61 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT DISTINCT - col2 + + 14 FROM tab1
----
-40
-43
-82

query I rowsort
SELECT DISTINCT + + col1 * + cor0.col0 + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - - 68 + col2 AS col2 FROM tab2 AS cor0
----
106
94
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + col1 col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL - + 92 + col2 AS col2 FROM tab1 cor0
----
-35
-38
4

query I rowsort
SELECT ALL - 62 * col0 + 36 * - col2 FROM tab0 AS cor0
----
-2206
-2676
-8470

query I rowsort
SELECT + col1 * + col2 * + 17 + ( - col0 ) AS col1 FROM tab1 AS cor0
----
21136
23865
9626

query I rowsort
SELECT ALL 20 + col0 FROM tab0
----
109
44
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-5010
SELECT + 77 DIV - col1 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-5010
SELECT + 77 / - col1 FROM tab2 AS cor0
----
-1
-2
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5011
SELECT - - 0 DIV col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5011
SELECT - - 0 / col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL tab0.col2 * col0 * col1 AS col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT - col2 * + col1 + - col0 - 81 * - cor0.col0 FROM tab1 AS cor0
----
-1164
4550
5152

onlyif mysql # use DIV operator for integer division
query I rowsort label-5014
SELECT DISTINCT - cor0.col1 DIV - col0 + - col1 col0 FROM tab1 AS cor0
----
-10
-13
-18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5014
SELECT DISTINCT - cor0.col1 / - col0 + - col1 col0 FROM tab1 AS cor0
----
-10
-13
-18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5015
SELECT - CAST( NULL AS SIGNED ) + - 13 * col2 / col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5015
SELECT - CAST ( NULL AS INTEGER ) + - 13 * col2 / col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 * cor0.col0 + - col2 AS col1 FROM tab0 AS cor0
----
34
7216
759

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab2 AS cor1, tab0, tab0 AS cor2 WHERE NULL <= ( NULL )
----

query I rowsort
SELECT ALL - ( - 73 ) + cor0.col2 - col2 AS col1 FROM tab0 AS cor0
----
73
73
73

query I rowsort
SELECT 3 * col2 + + col2 FROM tab1 AS cor0
----
216
228
384

query I rowsort
SELECT DISTINCT + col0 * col1 + col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL - 45 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 71160abf09589695379a70558726f0ba

query I rowsort
SELECT DISTINCT + ( - col1 ) + col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ( cor0.col2 ) * + col2 * - 52 + 80 FROM tab1 AS cor0
----
-151552
-168868
-479152

query I rowsort
SELECT DISTINCT - ( + 47 ) FROM tab1 AS cor0
----
-47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5025
SELECT - col2 + CAST( 91 AS SIGNED ) + col1 FROM tab2 AS cor0
----
124
70
95

skipif mysql # not compatible
query I rowsort label-5025
SELECT - col2 + CAST ( 91 AS INTEGER ) + col1 FROM tab2 AS cor0
----
124
70
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5026
SELECT - col2 * CAST( NULL AS SIGNED ) * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5026
SELECT - col2 * CAST ( NULL AS INTEGER ) * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + - 80 * + col1 AS col1 FROM tab0 AS cor0
----
-6847
-7198
-7759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5028
SELECT + - cor0.col2 * + 3 + + col2 + CAST( + col0 AS SIGNED ) FROM tab0 AS cor0
----
-42
-75
33

skipif mysql # not compatible
query I rowsort label-5028
SELECT + - cor0.col2 * + 3 + + col2 + CAST ( + col0 AS INTEGER ) FROM tab0 AS cor0
----
-42
-75
33

query I rowsort
SELECT + - col1 + 32 * col1 FROM tab0 AS cor0
----
2666
2821
3007

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5030
SELECT - + CAST( NULL AS SIGNED ) + + ( cor0.col2 ) + + col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5030
SELECT - + CAST ( NULL AS INTEGER ) + + ( cor0.col2 ) + + col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - col2 ) * + col2 + ( - col1 * + col2 ) FROM tab1 AS cor0
----
1512
2679
7968

query I rowsort
SELECT ALL - + 70 + 30 FROM tab2 AS cor0
----
-40
-40
-40

query I rowsort
SELECT - + col2 * - col2 + col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT + + col0 * col2 + cor0.col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL - cor0.col2 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

onlyif mysql # use DIV operator for integer division
query I rowsort label-5036
SELECT DISTINCT - 2 DIV - cor0.col1 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
0

skipif mysql # not compatible
query I rowsort label-5036
SELECT DISTINCT - 2 / - cor0.col1 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
0

query I rowsort
SELECT - + col1 * 21 + 51 AS col2 FROM tab2 cor0
----
-1188
-306
-600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 + - ( - col2 + - cor0.col0 ) col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col2 * col1 + col2 * col0 AS col2 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT DISTINCT col0 + - tab2.col0 FROM tab2
----
0

query I rowsort
SELECT ALL - col0 + - col0 * tab2.col1 AS col0 FROM tab2
----
-1422
-224
-4680

query I rowsort
SELECT + - col1 * col0 * 90 FROM tab0 AS cor0
----
-185760
-305550
-728910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 - - cor0.col2 col1 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 + - cor0.col1 + cor0.col0 col1 FROM tab2 cor0
----
1405
193
4621

query I rowsort
SELECT + tab0.col0 * 82 FROM tab0, tab2 AS cor0
----
9 values hashing to fec7215572a55d979eee5e57175da1b3

query I rowsort
SELECT 36 AS col2 FROM tab2, tab0, tab2 cor0
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT DISTINCT - ( tab1.col2 ) FROM tab1, tab2, tab2 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 col2 FROM tab0
----
67

query I rowsort
SELECT ALL - col0 + 48 FROM tab1 AS cor0
----
-16
-32
45

query I rowsort
SELECT ALL + cor0.col1 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
2
62
62

skipif mysql # not compatible
query I rowsort
SELECT col0 * CAST ( 3 AS REAL ) + col1 * + ( + col2 + - col2 ) FROM tab2 AS cor0
----
21
234
237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + ( + 63 ) col1 FROM tab1 AS cor0
----
73
76
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5053
SELECT DISTINCT + col2 DIV col2 + - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-5053
SELECT DISTINCT + col2 / col2 + - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT - col0 * 37 + 4 AS col1 FROM tab2 AS cor0
----
-255
-2882
-2919

onlyif mysql # use DIV operator for integer division
query I rowsort label-5055
SELECT + - col1 DIV col0 + + col0 FROM tab1 AS cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-5055
SELECT + - col1 / col0 + + col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
54
57
96

query I rowsort
SELECT + col0 - col2 * + col1 AS col2 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT - col0 + 11 FROM tab0 cor0
----
-13
-24
-78

query I rowsort
SELECT + col1 * 62 - col2 * col2 AS col2 FROM tab1 AS cor0
----
-1304
-2629
-8410

query I rowsort
SELECT ALL col1 + cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - + col1 * + col2 * ( col0 ) + - col2 + - cor0.col2 FROM tab1 cor0
----
-100032
-36594
-4320

query I rowsort
SELECT - + cor0.col2 + col2 * + col1 FROM tab0 AS cor0
----
2805
7380
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5063
SELECT - col1 + CAST( NULL AS SIGNED ) / - ( col0 ) - 93 / - col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5063
SELECT - col1 + CAST ( NULL AS INTEGER ) / - ( col0 ) - 93 / - col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( + 6 ) * cor0.col0 FROM tab2, tab1 AS cor0
----
18
384
480

query I rowsort
SELECT ALL 55 * + col1 AS col1 FROM tab2 AS cor0
----
1705
3245
935

query I rowsort
SELECT DISTINCT - ( col0 ) * col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT col0 * - ( col0 ) AS col2 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + 81 + col1 AS col0 FROM tab1 cor0
----
107
91
94

query I rowsort
SELECT - - 1 FROM tab0 cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5070
SELECT + tab1.col1 DIV - 35 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5070
SELECT + tab1.col1 / - 35 FROM tab1
----
0
0
0

query I rowsort
SELECT tab1.col0 + col2 * - col1 FROM tab1
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5072
SELECT ALL + col2 - col2 DIV - col2 AS col1 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-5072
SELECT ALL + col2 - col2 / - col2 AS col1 FROM tab1
----
55
58
97

query I rowsort
SELECT - col2 + col0 + ( tab1.col1 ) * + col1 AS col0 FROM tab1
----
107
153
625

query I rowsort
SELECT DISTINCT - col2 + tab1.col1 + 93 FROM tab1
----
10
46
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5075
SELECT CAST( ( + col1 ) AS SIGNED ) FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5075
SELECT CAST ( ( + col1 ) AS INTEGER ) FROM tab0
----
86
91
97

query I rowsort
SELECT ALL col1 - - col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL - col2 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + ( - col2 ) * + ( 73 ) AS col1 FROM tab2 AS cor0
----
-1898
-1971
-2774

query I rowsort
SELECT - + ( + cor0.col0 ) * col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5080
SELECT DISTINCT - - 87 + + col2 DIV col0 col0 FROM tab1 AS cor0
----
105
87
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5080
SELECT DISTINCT - - 87 + + col2 / col0 col0 FROM tab1 AS cor0
----
105
87
88

query I rowsort
SELECT ALL + + 92 FROM tab1 AS cor0
----
92
92
92

query I rowsort
SELECT ALL 26 + - col1 FROM tab2
----
-33
-5
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col1 col1 FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT - col0 + col2 * - col2 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT DISTINCT - 14 * col2 + col2 FROM tab2 AS cor0
----
-338
-351
-494

query I rowsort
SELECT + cor0.col2 + + cor0.col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL + col1 * + col2 + - 34 FROM tab2 AS cor0
----
1500
612
803

query I rowsort
SELECT ALL - col0 - + tab0.col2 * col0 AS col0 FROM tab0 WHERE NOT ( + col2 + + col0 ) IN ( col2 )
----
-70
-7387
-816

query I rowsort
SELECT ALL tab1.col0 * tab1.col2 AS col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL col1 * col0 + - col1 * col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - + 7 + col1 AS col0 FROM tab2 AS cor0
----
10
24
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col1 * + col1 col0 FROM tab1 AS cor0
----
156
650
90

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) > ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5094
SELECT col1 + tab0.col0 DIV - col2 AS col0 FROM tab0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-5094
SELECT col1 + tab0.col0 / - col2 AS col0 FROM tab0
----
62
86
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5095
SELECT - col2 + + col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-5095
SELECT - col2 + + col1 / - col1 AS col0 FROM tab2 AS cor0
----
-27
-28
-39

query I rowsort
SELECT + - 85 + cor0.col1 AS col0 FROM tab0 AS cor0
----
1
12
6

query I rowsort
SELECT DISTINCT + col1 * col1 + - cor0.col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT DISTINCT 68 * col1 FROM tab1
----
1768
680
884

query I rowsort
SELECT - col2 * col2 * col1 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT col1 + - col0 * + col1 + col0 AS col2 FROM tab1
----
-49
-566
-947

onlyif mysql # use DIV operator for integer division
query I rowsort label-5101
SELECT DISTINCT + tab0.col2 DIV col2 col2 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5101
SELECT DISTINCT + tab0.col2 / col2 col2 FROM tab0
----
1

query I rowsort
SELECT ALL - col2 * col1 + col2 - + col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - col1 * + col0 + col0 AS col2 FROM tab2
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-5104
SELECT ALL col0 + - col2 DIV col0 + - col0 * col0 * + col1 FROM tab1
----
-249
-40896
-83121

skipif mysql # not compatible
query I rowsort label-5104
SELECT ALL col0 + - col2 / col0 + - col0 * col0 * + col1 FROM tab1
----
-249
-40896
-83121

query I rowsort
SELECT ALL - col0 + col1 - - col0 * + col1 FROM tab1
----
101
586
973

query I rowsort
SELECT + col2 FROM tab2 WHERE NOT ( + col2 * col0 - - col0 ) > ( NULL )
----

query I rowsort
SELECT ALL + col1 * col1 + - col2 + + tab0.col0 * col1 AS col0 FROM tab0
----
12803
16298
9427

query I rowsort
SELECT ALL col1 * col2 + - col0 * + col1 FROM tab1 WHERE NOT NULL IN ( col2 )
----

query I rowsort
SELECT DISTINCT tab2.col0 * tab2.col2 * tab2.col2 AS col0 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT ALL col2 * + col1 * col2 AS col1 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT + col0 * col0 * + tab1.col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT DISTINCT + col0 + col0 * - tab1.col0 + col0 FROM tab1
----
-3
-3968
-6240

query I rowsort
SELECT ALL + col0 * + col0 + - col0 + + tab2.col0 FROM tab2
----
49
6084
6241

query I rowsort
SELECT ALL col0 * + col0 * col2 FROM tab2
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5115
SELECT + col2 DIV col2 - col1 AS col2 FROM tab0 WHERE col0 <> ( + col1 DIV col0 )
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-5115
SELECT + col2 / col2 - col1 AS col2 FROM tab0 WHERE col0 <> ( + col1 / col0 )
----
-85
-90
-96

query I rowsort
SELECT DISTINCT col0 * + col0 + col0 AS col0 FROM tab0
----
1260
600
8010

query I rowsort
SELECT ALL col2 * col0 + col0 AS col1 FROM tab2
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - + col2 col1 FROM tab0
----
-9
34
7

query I rowsort
SELECT - tab0.col2 + + col2 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL col1 * - col0 + col1 * col1 * - col0 FROM tab1
----
-14560
-2106
-7040

query III rowsort
SELECT ALL * FROM tab2 WHERE ( col1 ) > NULL
----

query I rowsort
SELECT col2 * col0 + tab0.col1 * - col0 FROM tab0
----
-1272
-3360
-801

query III rowsort
SELECT * FROM tab1 WHERE NULL = + tab1.col2 / + col1 + + col1
----

query I rowsort
SELECT DISTINCT tab1.col2 * + col0 + tab1.col0 * col1 FROM tab1
----
240
4288
8720

query I rowsort
SELECT - col2 * tab2.col0 + col0 AS col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT 0 AS col0 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5127
SELECT - col2 DIV + col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5127
SELECT - col2 / + col1 AS col1 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5128
SELECT CAST( ( col1 ) AS SIGNED ) FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-5128
SELECT CAST ( ( col1 ) AS INTEGER ) FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col0 FROM tab0, tab1 cor0
----
10
13
26

query I rowsort
SELECT + col0 * col2 * + col0 AS col0 FROM tab0 AS cor0
----
1225
19008
649522

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 3eea7cef970c8ff51d71b8a23ee129bf

query I rowsort
SELECT - tab2.col1 * - 70 AS col0 FROM tab2
----
1190
2170
4130

query I rowsort
SELECT - ( - ( col0 ) ) * col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT 22 * col1 + col1 FROM tab1 AS cor0
----
230
299
598

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5135
SELECT DISTINCT CAST( col0 AS SIGNED ) AS col2 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5135
SELECT DISTINCT CAST ( col0 AS INTEGER ) AS col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT + col2 + col2 + 59 * col0 AS col1 FROM tab1 cor0
----
285
3890
4912

query I rowsort
SELECT - - 76 * + col2 AS col0 FROM tab0 AS cor0
----
2508
6232
76

query I rowsort
SELECT 66 + - cor0.col0 * - col1 FROM tab2 AS cor0
----
1409
283
4668

query I rowsort
SELECT - 84 + col2 FROM tab0 AS cor0
----
-2
-51
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5140
SELECT - cor0.col0 + + col2 * - CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
-196
-2106
-3081

skipif mysql # not compatible
query I rowsort label-5140
SELECT - cor0.col0 + + col2 * - CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - col0 * - cor0.col2 * col2 FROM tab2 AS cor0
----
114076
5103
52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - cor0.col0 * + cor0.col0 col1 FROM tab2 cor0
----
-18
-6025
-6224

query I rowsort
SELECT ALL - + col0 + - ( col1 ) * + col2 + ( - col1 ) FROM tab0 AS cor0
----
-229
-2948
-7642

query I rowsort
SELECT + col1 + + 2 FROM tab0 AS cor0
----
88
93
99

query I rowsort
SELECT - cor0.col1 * + ( + 98 ) FROM tab0 AS cor0
----
-8428
-8918
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5147
SELECT ALL col1 DIV + cor0.col0 + col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-5147
SELECT ALL col1 / + cor0.col0 + col0 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT DISTINCT col2 * 46 + - col2 AS col2 FROM tab0 AS cor0
----
1485
3690
45

query I rowsort
SELECT + col0 + - 14 AS col1 FROM tab0 AS cor0
----
10
21
75

query I rowsort
SELECT - 95 + col1 FROM tab1 cor0
----
-69
-82
-85

query I rowsort
SELECT + 41 * - 67 + col0 AS col2 FROM tab1 cor0
----
-2667
-2683
-2744

query I rowsort
SELECT + - col2 - - cor0.col0 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL ( 32 ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT ALL ( - col0 ) + - col1 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + col0 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - col2 + col1 * - col0 * - col0 - - col2 FROM tab2 cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT 22 * - col1 + + col1 FROM tab0 AS cor0
----
-1806
-1911
-2037

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) + + col1 * cor0.col2 * cor0.col0 col0 FROM tab2 AS cor0
----
119730
51113
5866

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - col1 col0 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5160
SELECT CAST( + col1 AS SIGNED ) * col0 AS col1 FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-5160
SELECT CAST ( + col1 AS INTEGER ) * col0 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL + 42 * + cor0.col2 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 75f9e61ff973806e32e45e6335de6153

onlyif mysql # use DIV operator for integer division
query I rowsort label-5162
SELECT ( col1 ) DIV col0 AS col1 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5162
SELECT ( col1 ) / col0 AS col1 FROM tab1
----
0
0
8

query I rowsort
SELECT + col2 * tab2.col0 + + col0 + col2 FROM tab2
----
2132
223
3119

query I rowsort
SELECT ALL + ( + col0 + tab1.col1 ) * + tab1.col2 AS col1 FROM tab1
----
1566
4218
8928

query I rowsort
SELECT col2 + - col1 + col1 * col2 FROM tab2 AS cor0
----
1501
667
833

query I rowsort
SELECT + - col2 * col1 - col2 AS col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT - col2 + - col2 * col2 AS col1 FROM tab2
----
-1482
-702
-756

query I rowsort
SELECT DISTINCT tab0.col2 * + tab0.col1 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - + ( col0 ) + - col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT - 59 - + 83 * col1 AS col0 FROM tab1
----
-1138
-2217
-889

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 15 - - tab2.col1 col0 FROM tab2
----
32
46
74

query I rowsort
SELECT DISTINCT - ( col0 * col0 ) AS col2 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT + ( 7 ) AS col1 FROM tab2 AS cor0
----
7
7
7

query I rowsort
SELECT cor0.col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT 86 * col1 * - col1 FROM tab1 AS cor0
----
-14534
-58136
-8600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col0 * + col0 col2 FROM tab1
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * - col1 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5178
SELECT DISTINCT + cor0.col1 DIV + col0 FROM tab1 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-5178
SELECT DISTINCT + cor0.col1 / + col0 FROM tab1 AS cor0
----
0
8

query I rowsort
SELECT DISTINCT - col2 * - col2 + col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT DISTINCT + col0 AS col1 FROM tab1 cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col2 * col2 * + col1 AS col2 FROM tab1 AS cor0
----
119808
32490
75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT cor0.col1 * col2 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col0 - col1 FROM tab0 cor0 WHERE ( cor0.col1 ) > NULL
----

query I rowsort
SELECT ALL - col2 * col1 * + tab2.col0 AS col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT ALL col0 + + col0 FROM tab2 AS cor0 WHERE NOT NULL NOT IN ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * col1 * cor0.col2 col1 FROM tab0 cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-5188
SELECT + col2 + - col0 DIV + col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-5188
SELECT + col2 + - col0 / + col0 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT ALL - col1 * + col2 * col1 + col1 * + col2 AS col0 FROM tab2 AS cor0
----
-10336
-25110
-88972

query I rowsort
SELECT DISTINCT - - cor0.col0 * + col0 AS col2 FROM tab2 cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-5191
SELECT DISTINCT col0 + - col1 DIV - col2 + col0 AS col0 FROM tab0
----
167
179
50

skipif mysql # not compatible
query I rowsort label-5191
SELECT DISTINCT col0 + - col1 / - col2 + col0 AS col0 FROM tab0
----
167
179
50

query I rowsort
SELECT DISTINCT + cor0.col0 * - col2 * - col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT - cor0.col1 + + col1 * + col1 AS col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT DISTINCT - cor0.col2 + - cor0.col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 + - col1 FROM tab2 cor0
----
272
3422
930

onlyif mysql # use DIV operator for integer division
query I rowsort label-5196
SELECT ALL - col1 * col0 + - col0 DIV col1 - - col1 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

skipif mysql # not compatible
query I rowsort label-5196
SELECT ALL - col1 * col0 + - col0 / col1 - - col1 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-5197
SELECT DISTINCT - col0 DIV col2 AS col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5197
SELECT DISTINCT - col0 / col2 AS col2 FROM tab1 AS cor0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5198
SELECT + + col2 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5198
SELECT + + col2 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 * + col2 col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL - cor0.col1 + + cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 318a6997409c5decbbc3333c9d493ad3

query I rowsort
SELECT DISTINCT cor0.col0 + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - col1 + col1 * col1 AS col2 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT + - col0 + col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT - - col1 * - col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - + col0 * + col1 + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5206
SELECT ALL + col2 DIV col0 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5206
SELECT ALL + col2 / col0 FROM tab0 cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5207
SELECT ALL col1 DIV + col1 + col2 AS col0 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-5207
SELECT ALL col1 / + col1 + col2 AS col0 FROM tab1
----
55
58
97

query I rowsort
SELECT ALL - col1 * col1 + + col1 FROM tab1
----
-156
-650
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5209
SELECT ALL col1 DIV col1 + + col0 DIV - col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5209
SELECT ALL col1 / col1 + + col0 / - col1 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL + tab0.col2 * col0 + col0 * col1 AS col0 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT DISTINCT - + col2 + 52 * - col1 FROM tab2 AS cor0
----
-1639
-3094
-922

query I rowsort
SELECT DISTINCT - + col0 + - col0 + + 99 AS col1 FROM tab1 AS cor0
----
-29
-61
93

query I rowsort
SELECT + cor0.col1 * - 14 + col2 FROM tab2 AS cor0
----
-200
-407
-800

query I rowsort
SELECT + - col2 + - 17 * + 24 AS col2 FROM tab0 AS cor0
----
-409
-441
-490

query I rowsort
SELECT col0 * - ( 2 ) + cor0.col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5216
SELECT ALL + col1 * + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5216
SELECT ALL + col1 * + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * col1 + col2 * cor0.col0 FROM tab2 AS cor0
----
-648
2356
494

query I rowsort
SELECT DISTINCT - - col1 * 80 FROM tab0 AS cor0
----
6880
7280
7760

query I rowsort
SELECT col1 + - col2 + - col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT 17 * + col1 FROM tab2 AS cor0
----
1003
289
527

query I rowsort
SELECT - 63 + - 72 FROM tab2 AS cor0
----
-135
-135
-135

query I rowsort
SELECT + ( + col0 ) * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + col0 * ( - col0 ) AS col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + col0 + 39 FROM tab0
----
128
63
74

query I rowsort
SELECT DISTINCT - + col0 + + col0 * 17 FROM tab1 AS cor0
----
1024
1280
48

query I rowsort
SELECT ALL col0 * col0 + + col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT - cor0.col1 * + col0 * - ( - col2 ) AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT col2 + - col1 * 58 * col2 FROM tab1 AS cor0
----
-33003
-72288
-81378

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - col0 col1 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT + - col0 + col1 AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL + ( - col2 ) + + col2 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5232
SELECT ALL + col2 * + col1 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5232
SELECT ALL + col2 * + col1 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5233
SELECT DISTINCT CAST( ( col0 ) AS SIGNED ) AS col0 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5233
SELECT DISTINCT CAST ( ( col0 ) AS INTEGER ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT + ( - 11 ) FROM tab0
----
-11
-11
-11

query I rowsort
SELECT - col1 + + col1 * 92 * + col1 FROM tab1
----
15535
62166
9190

query I rowsort
SELECT - col2 + + col0 + - ( - col0 + tab1.col1 ) * 40 AS col2 FROM tab1
----
-971
2167
2664

onlyif mysql # use DIV operator for integer division
query I rowsort label-5237
SELECT DISTINCT - cor0.col2 * - cor0.col2 + col2 DIV 14 AS col0 FROM tab1 cor0
----
2919
3253
9222

skipif mysql # not compatible
query I rowsort label-5237
SELECT DISTINCT - cor0.col2 * - cor0.col2 + col2 / 14 AS col0 FROM tab1 cor0
----
2919
3253
9222

query I rowsort
SELECT DISTINCT + + 83 FROM tab2 AS cor0
----
83

query I rowsort
SELECT ALL - - ( + col1 ) * 55 + cor0.col2 FROM tab1 AS cor0
----
1484
607
811

query I rowsort
SELECT DISTINCT col0 * - col0 + 41 * - tab0.col1 FROM tab0
----
-11652
-4102
-5202

query I rowsort
SELECT - 80 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 26dbcc98d4b4e864ffa31be685a5dfbd

query I rowsort
SELECT col2 + 60 * cor0.col2 FROM tab1 AS cor0
----
3294
3477
5856

query I rowsort
SELECT ALL col1 * + 32 AS col2 FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT + + col1 * col2 - 57 FROM tab0 AS cor0
----
2781
40
7405

query I rowsort
SELECT col2 + 43 AS col0 FROM tab1 AS cor0
----
100
139
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5246
SELECT cor0.col1 * col2 - - col0 DIV cor0.col2 FROM tab1 AS cor0
----
1248
1404
571

skipif mysql # not compatible
query I rowsort label-5246
SELECT cor0.col1 * col2 - - col0 / cor0.col2 FROM tab1 AS cor0
----
1248
1404
571

query I rowsort
SELECT col0 - ( + 95 ) AS col1 FROM tab0 AS cor0
----
-6
-60
-71

query I rowsort
SELECT 68 FROM tab0, tab2 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT 97 FROM tab0, tab2 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT DISTINCT - 72 * + col2 FROM tab0 AS cor0
----
-2376
-5904
-72

query I rowsort
SELECT ALL + - ( - col1 ) + + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT col1 * col2 + + col0 AS col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL - 14 + col2 * - col1 FROM tab0 AS cor0
----
-111
-2852
-7476

query I rowsort
SELECT + - 18 * + col2 AS col1 FROM tab0 AS cor0
----
-1476
-18
-594

query I rowsort
SELECT DISTINCT 82 AS col0 FROM tab2 AS cor0
----
82

query I rowsort
SELECT + + 68 * - ( - col1 ) FROM tab1 cor0
----
1768
680
884

onlyif mysql # use DIV operator for integer division
query I rowsort label-5257
SELECT ALL + ( + cor0.col0 ) + col0 * 0 DIV col2 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5257
SELECT ALL + ( + cor0.col0 ) + col0 * 0 / col2 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + - col2 * col0 + - col0 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT cor0.col2 - 21 FROM tab1, tab2 cor0
----
9 values hashing to 46aa67bd7039f66bd66650c2beb4e634

query I rowsort
SELECT 34 * + col1 FROM tab0 AS cor0
----
2924
3094
3298

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + tab1.col1 AS REAL ) FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - 32 * - 98 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 654cf6b7875072dc93c75e01426f1b4a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 49 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT + cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ( + col1 ) * + col2 AS col2 FROM tab2 cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5266
SELECT DISTINCT col1 DIV 72 col2 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5266
SELECT DISTINCT col1 / 72 col2 FROM tab2
----
0

query I rowsort
SELECT DISTINCT + + 17 AS col0 FROM tab1 AS cor0
----
17

query I rowsort
SELECT ALL - col1 - - col1 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL ( - col1 ) + + col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + 63 * 20 AS col2 FROM tab1 cor0
----
1260
1260
1260

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 ) col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5273
SELECT ALL CAST( NULL AS SIGNED ) * - col2 * col0 + + col0 * col0 * col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5273
SELECT ALL CAST ( NULL AS INTEGER ) * - col2 * col0 + + col0 * col0 * col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( 73 ) + - cor0.col2 * - col0 FROM tab1 AS cor0
----
235
3721
7753

query I rowsort
SELECT DISTINCT + 66 AS col1 FROM tab2 AS cor0
----
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5276
SELECT - 66 DIV 52 AS col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5276
SELECT - 66 / 52 AS col0 FROM tab2
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5277
SELECT col0 DIV 17 FROM tab0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-5277
SELECT col0 / 17 FROM tab0
----
1
2
5

query I rowsort
SELECT DISTINCT - - col0 * + col0 * 52 + cor0.col0 FROM tab0 cor0
----
29976
411981
63735

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 + col0 AS REAL ) FROM tab2
----
104
117
34

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - col1 + CAST ( + col0 AS REAL ) AS col2 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 93 col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

query I rowsort
SELECT + col0 + ( - cor0.col0 ) FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 44 col2 FROM tab0
----
-44

query I rowsort
SELECT + cor0.col0 * ( col1 ) + + col2 AS col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL - col2 * + 6 FROM tab2
----
-156
-162
-228

query I rowsort
SELECT col2 + col1 * col1 AS col1 FROM tab1 cor0
----
157
265
730

query I rowsort
SELECT col0 - 2 FROM tab2
----
5
76
77

query I rowsort
SELECT DISTINCT col1 + 77 FROM tab1
----
103
87
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5289
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5289
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT cor2.col2 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 3dcd863493ac16ce594c62d4ac8b0412

query I rowsort
SELECT ALL - - col1 - col2 AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT 40 * 70 AS col2 FROM tab0 AS cor0
----
2800

query I rowsort
SELECT DISTINCT - col0 * - col2 + + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-5294
SELECT ALL - + ( - col0 ) DIV - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5294
SELECT ALL - + ( - col0 ) / - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + ( - col2 ) * - col1 * - 66 FROM tab0 AS cor0
----
187308
492492
6402

query I rowsort
SELECT ALL ( - col0 ) * col1 + + col1 * col1 AS col0 FROM tab1
----
-540
-871
598

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5297
SELECT CAST( NULL AS SIGNED ) + cor0.col0 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5297
SELECT CAST ( NULL AS INTEGER ) + cor0.col0 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5298
SELECT ALL col0 - col2 * - CAST( NULL AS SIGNED ) col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5298
SELECT ALL col0 - col2 * - CAST ( NULL AS INTEGER ) col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 13 + tab0.col2 - + 75 AS col2 FROM tab0
----
-29
-61
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * + tab0.col1 - - col1 col0 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT 77 * col1 * - tab1.col2 + col2 AS col0 FROM tab1
----
-108054
-43833
-96000

onlyif mysql # use DIV operator for integer division
query I rowsort label-5302
SELECT + col2 + + col2 DIV - 56 + 22 AS col1 FROM tab1 AS cor0
----
117
76
78

skipif mysql # not compatible
query I rowsort label-5302
SELECT + col2 + + col2 / - 56 + 22 AS col1 FROM tab1 AS cor0
----
117
76
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5303
SELECT - col0 + col0 + col2 DIV col0 AS col1 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5303
SELECT - col0 + col0 + col2 / col0 AS col1 FROM tab1 AS cor0
----
0
1
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5304
SELECT col2 + CAST( NULL AS SIGNED ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5304
SELECT col2 + CAST ( NULL AS INTEGER ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 + 76 + + 46 AS col1 FROM tab0 AS cor0
----
121
40
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5306
SELECT - col0 + 99 + - col0 DIV - col1 AS col0 FROM tab1 AS cor0
----
25
41
96

skipif mysql # not compatible
query I rowsort label-5306
SELECT - col0 + 99 + - col0 / - col1 AS col0 FROM tab1 AS cor0
----
25
41
96

query I rowsort
SELECT col1 * + 17 AS col2 FROM tab1 AS cor0
----
170
221
442

query I rowsort
SELECT - col0 + + col0 * 44 + col2 * - col0 FROM tab0 AS cor0
----
-3471
1470
240

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5309
SELECT - cor0.col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5309
SELECT - cor0.col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * ( col1 ) + + col0 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT + + col0 * ( + col2 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - - col1 + - ( col1 ) + - col0 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT col1 * - col1 * - col0 AS col2 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT 73 * - tab1.col0 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b8ed8ab0baacb8f3308669db8c62d323

onlyif mysql # use DIV operator for integer division
query I rowsort label-5315
SELECT + col2 DIV - 27 FROM tab1
----
-2
-2
-3

skipif mysql # not compatible
query I rowsort label-5315
SELECT + col2 / - 27 FROM tab1
----
-2
-2
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5316
SELECT ALL ( col2 ) DIV - col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5316
SELECT ALL ( col2 ) / - col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col2 * - col1 - col1 FROM tab2 cor0
----
-1593
-663
-868

query I rowsort
SELECT ALL + - 83 * col0 FROM tab0 AS cor0
----
-1992
-2905
-7387

query I rowsort
SELECT ALL + + 30 * + col2 + col2 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT DISTINCT col0 + ( col1 + col0 ) FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT DISTINCT 7 * 17 * + col1 AS col2 FROM tab0
----
10234
10829
11543

query I rowsort
SELECT DISTINCT + col0 + - col1 * - col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - col1 * + col2 + col1 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL + ( col1 ) + - ( col0 ) FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT ALL - col0 - - col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL 99 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

onlyif mysql # use DIV operator for integer division
query I rowsort label-5327
SELECT - cor0.col2 DIV cor0.col0 - col2 FROM tab2 AS cor0
----
-26
-30
-38

skipif mysql # not compatible
query I rowsort label-5327
SELECT - cor0.col2 / cor0.col0 - col2 FROM tab2 AS cor0
----
-26
-30
-38

query I rowsort
SELECT - + col2 - col2 AS col1 FROM tab2 AS cor0
----
-52
-54
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5329
SELECT - CAST( NULL AS SIGNED ) + + 10 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5329
SELECT - CAST ( NULL AS INTEGER ) + + 10 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col0 * col0 + 68 FROM tab2 AS cor0
----
-6016
-6173
19

query I rowsort
SELECT - col2 + col1 * - 23 AS col0 FROM tab2 AS cor0
----
-1383
-429
-740

query I rowsort
SELECT DISTINCT + cor0.col2 * + col0 + + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - col0 + - 71 AS col0 FROM tab1
----
-135
-151
-74

query I rowsort
SELECT ALL 70 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT DISTINCT + + col0 * - ( + cor0.col0 ) FROM tab1 cor0
----
-4096
-6400
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5336
SELECT col2 / CAST( NULL AS SIGNED ) + - col2 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5336
SELECT col2 / CAST ( NULL AS INTEGER ) + - col2 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * 43 FROM tab0 cor0
----
-3698
-3913
-4171

query I rowsort
SELECT DISTINCT - + col2 + 60 AS col2 FROM tab0 AS cor0
----
-22
27
59

query I rowsort
SELECT - + col2 + - col1 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5340
SELECT CAST( - 7 AS SIGNED ) + col1 AS col1 FROM tab2 AS cor0
----
10
24
52

skipif mysql # not compatible
query I rowsort label-5340
SELECT CAST ( - 7 AS INTEGER ) + col1 AS col1 FROM tab2 AS cor0
----
10
24
52

query I rowsort
SELECT + 95 + 31 FROM tab1 cor0
----
126
126
126

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( 52 AS REAL ) * + col1 - col2 FROM tab2 AS cor0
----
-1639
-3094
-922

query I rowsort
SELECT DISTINCT ( - col2 ) * + col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + 37 AS col0 FROM tab2 AS cor0
----
37
37
37

query I rowsort
SELECT DISTINCT - + 20 * col1 AS col1 FROM tab1 AS cor0
----
-200
-260
-520

onlyif mysql # use DIV operator for integer division
query I rowsort label-5346
SELECT ALL + ( - col0 ) + + cor0.col1 DIV col1 AS col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-5346
SELECT ALL + ( - col0 ) + + cor0.col1 / col1 AS col0 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT - + 28 * + 66 FROM tab1 cor0
----
-1848
-1848
-1848

query I rowsort
SELECT DISTINCT tab2.col1 * + 49 AS col2 FROM tab2
----
1519
2891
833

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 35 col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

query I rowsort
SELECT + 53 AS col0 FROM tab0 cor0
----
53
53
53

query I rowsort
SELECT + - 15 * + col0 FROM tab0 AS cor0
----
-1335
-360
-525

query I rowsort
SELECT DISTINCT + 66 * col2 AS col1 FROM tab1 cor0
----
3564
3762
6336

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5353
SELECT ALL - CAST( NULL AS SIGNED ) / + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5353
SELECT ALL - CAST ( NULL AS INTEGER ) / + col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col2 ) * - cor0.col2 col1 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - 94 + cor0.col1 AS col2 FROM tab1 AS cor0
----
-68
-81
-84

query I rowsort
SELECT DISTINCT - 63 * - col1 AS col2 FROM tab0 AS cor0
----
5418
5733
6111

query I rowsort
SELECT + + 15 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5358
SELECT ALL + 23 DIV col0 FROM tab1
----
0
0
7

skipif mysql # not compatible
query I rowsort label-5358
SELECT ALL + 23 / col0 FROM tab1
----
0
0
7

query I rowsort
SELECT + 94 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT - cor0.col2 + ( + 45 ) * col1 AS col0 FROM tab1 AS cor0
----
1116
393
489

query I rowsort
SELECT + col1 * 18 AS col2 FROM tab2 AS cor0
----
1062
306
558

query I rowsort
SELECT + - col1 + col1 * + col2 * + col1 AS col1 FROM tab1 AS cor0
----
16211
36478
5690

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 86 * - 93 col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
-7998

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5364
SELECT ALL + col2 / col0 + col0 * ( + col2 ) * + CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5364
SELECT ALL + col2 / col0 + col0 * ( + col2 ) * + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * 45 AS col1 FROM tab1 AS cor0
----
1170
450
585

onlyif mysql # use DIV operator for integer division
query I rowsort label-5366
SELECT - col0 * CAST( + 68 AS SIGNED ) DIV col0 + - col1 FROM tab2 AS cor0
----
-127
-85
-99

skipif mysql # not compatible
query I rowsort label-5366
SELECT - col0 * CAST ( + 68 AS INTEGER ) / col0 + - col1 FROM tab2 AS cor0
----
-127
-85
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5367
SELECT - + col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5367
SELECT - + col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * col1 + 32 FROM tab2 AS cor0
----
1566
678
869

query I rowsort
SELECT ALL + col1 * 99 AS col2 FROM tab1 AS cor0
----
1287
2574
990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5370
SELECT ALL + col2 * - col2 + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5370
SELECT ALL + col2 * - col2 + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 40 + + col0 FROM tab2
----
-33
38
39

query I rowsort
SELECT ALL 59 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT ALL + col2 * col2 + + 66 + col1 * 58 AS col2 FROM tab0 AS cor0
----
12068
5693
6143

query I rowsort
SELECT ALL col1 * + 24 + - 5 FROM tab2 AS cor0
----
1411
403
739

query I rowsort
SELECT DISTINCT col0 * + cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col1 col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5377
SELECT col1 * CAST( - 29 AS SIGNED ) col1 FROM tab1 AS cor0
----
-290
-377
-754

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5377
SELECT col1 * CAST ( - 29 AS INTEGER ) col1 FROM tab1 AS cor0
----
-290
-377
-754

onlyif mysql # use DIV operator for integer division
query I rowsort label-5378
SELECT DISTINCT - + col1 DIV - 35 FROM tab2 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5378
SELECT DISTINCT - + col1 / - 35 FROM tab2 cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5379
SELECT + col2 DIV - CAST( col1 + col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5379
SELECT + col2 / - CAST ( col1 + col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + cor0.col0 * - ( cor0.col0 * col0 ) FROM tab2 AS cor0
----
-343
-474552
-493039

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5381
SELECT ALL - col2 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5381
SELECT ALL - col2 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 8 * 11 * - cor0.col0 + - col2 + + col2 * + col1 FROM tab2 AS cor0
----
-5356
-6344
194

query I rowsort
SELECT + cor0.col2 + - col1 + + col0 FROM tab1 AS cor0
----
111
163
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-5384
SELECT - col0 DIV cor0.col1 + col1 + + col0 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-5384
SELECT - col0 / cor0.col1 + col1 + + col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - col1 * tab1.col0 + + col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT ALL + 73 + col1 FROM tab0 AS cor0
----
159
164
170

query I rowsort
SELECT cor0.col1 + cor0.col0 + col0 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT DISTINCT + 26 + col0 FROM tab0 AS cor0
----
115
50
61

query I rowsort
SELECT DISTINCT 30 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
30

query I rowsort
SELECT + 75 + col2 FROM tab1 AS cor0
----
129
132
171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 67 + col2 col0 FROM tab1 AS cor0
----
121
124
163

query I rowsort
SELECT DISTINCT 51 * - col0 AS col2 FROM tab0 AS cor0
----
-1224
-1785
-4539

onlyif mysql # use DIV operator for integer division
query I rowsort label-5393
SELECT 19 * cor0.col0 DIV col2 AS col1 FROM tab1 AS cor0
----
1
15
21

skipif mysql # not compatible
query I rowsort label-5393
SELECT 19 * cor0.col0 / col2 AS col1 FROM tab1 AS cor0
----
1
15
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 56 + - col2 * ( ( col1 ) * col2 ) col1 FROM tab1 AS cor0
----
-119752
-32434
-75760

query I rowsort
SELECT ALL + 78 * - col2 * - 12 FROM tab2 AS cor0
----
24336
25272
35568

query I rowsort
SELECT - col2 * col1 + - ( ( - col2 ) ) + col2 FROM tab2 AS cor0
----
-1482
-570
-783

query I rowsort
SELECT DISTINCT - + cor1.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
-17
-31
-59

query I rowsort
SELECT DISTINCT tab2.col0 * + col1 + - tab2.col2 * col1 FROM tab2
----
-620
3068
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL 32 * - col0 + col1 + - col1 AS col0 FROM tab0 AS cor0
----
-1120
-2848
-768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 - - col0 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + + col2 + col1 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + 13 + - col1 * - col0 FROM tab2 AS cor0
----
1356
230
4615

onlyif mysql # use DIV operator for integer division
query I rowsort label-5404
SELECT ALL col0 * col0 DIV ( ( col2 ) ) + - 22 FROM tab0 AS cor0
----
-5
1203
74

skipif mysql # not compatible
query I rowsort label-5404
SELECT ALL col0 * col0 / ( ( col2 ) ) + - 22 FROM tab0 AS cor0
----
-5
1203
74

query I rowsort
SELECT DISTINCT - 77 AS col1 FROM tab2 AS cor0
----
-77

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 * - col1 AS REAL ) + - tab1.col2 AS col2 FROM tab1
----
-1344
-1458
-627

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5407
SELECT DISTINCT - CAST( NULL AS SIGNED ) * - col0 * - col2 + ( tab2.col0 ) * - col1 - + col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5407
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * - col0 * - col2 + ( tab2.col0 ) * - col1 - + col0 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT - 41 * - cor0.col2 FROM tab2, tab0, tab2 cor0
----
1066
1107
1558

query I rowsort
SELECT ALL - ( tab2.col0 ) FROM tab2, tab1 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT - col1 * + col1 * + col2 AS col1 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT ( col1 ) * 21 + + cor0.col0 FROM tab0 AS cor0
----
1830
2000
2072

onlyif mysql # use DIV operator for integer division
query I rowsort label-5412
SELECT DISTINCT + col0 DIV - cor0.col1 + - col0 * - col0 + col2 AS col1 FROM tab1 AS cor0
----
4147
63
6490

skipif mysql # not compatible
query I rowsort label-5412
SELECT DISTINCT + col0 / - cor0.col1 + - col0 * - col0 + col2 AS col1 FROM tab1 AS cor0
----
4147
63
6490

query I rowsort
SELECT + - cor0.col1 + - col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL + col0 - col1 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col2 * col2 col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT + 88 FROM tab2
----
88
88
88

query I rowsort
SELECT 57 + + col0 - col2 * + 59 AS col2 FROM tab0
----
-1866
-4692
33

query I rowsort
SELECT DISTINCT col2 + col2 * 29 FROM tab2
----
1140
780
810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5419
SELECT ALL cor2.col2 - - CAST( - tab2.col2 AS SIGNED ) FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 6a4b01aff43883f6dbe6655de6f7a1d0

skipif mysql # not compatible
query I rowsort label-5419
SELECT ALL cor2.col2 - - CAST ( - tab2.col2 AS INTEGER ) FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 6a4b01aff43883f6dbe6655de6f7a1d0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5420
SELECT DISTINCT 68 DIV - cor1.col1 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-5420
SELECT DISTINCT 68 / - cor1.col1 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-1
-2
-4

query I rowsort
SELECT ALL - cor1.col1 + cor0.col2 * - cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to df04ec718bc82e945e7ad2a37b32123d

query I rowsort
SELECT cor0.col2 + - col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT + cor0.col0 * col1 + cor0.col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + - 60 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-60

query I rowsort
SELECT col2 + - col2 * col0 * - col1 FROM tab1
----
36537
4266
99936

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5426
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + 70 col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5426
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + 70 col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + - 11 + col1 + col2 FROM tab2 AS cor0
----
44
47
74

query I rowsort
SELECT DISTINCT - 57 AS col0 FROM tab0, tab0 AS cor0
----
-57

query I rowsort
SELECT ALL + cor0.col2 * - col0 * col2 + + 44 FROM tab1 AS cor0
----
-207892
-737236
-8704

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2, tab1 AS cor3
----
3645 values hashing to 79b6ae096785aaecea9c1428e4a43e5f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5431
SELECT ALL - + 84 DIV cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 96308c1047e27c000d229f71df430662

skipif mysql # not compatible
query I rowsort label-5431
SELECT ALL - + 84 / cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 96308c1047e27c000d229f71df430662

query I rowsort
SELECT + 70 + 84 * + col2 * ( + col0 ) FROM tab0
----
3010
613102
66598

query I rowsort
SELECT ( cor0.col2 ) * - 33 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to cc16a349f6f0925588e1b0e550618c89

query I rowsort
SELECT DISTINCT + + 37 FROM tab0 AS cor0
----
37

query I rowsort
SELECT ALL + - 18 * col2 + col2 AS col1 FROM tab1 cor0
----
-1632
-918
-969

query I rowsort
SELECT DISTINCT + col1 * - cor0.col1 + + col2 + + col0 FROM tab0 AS cor0
----
-7339
-8110
-9373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5437
SELECT DISTINCT CAST( NULL AS SIGNED ) + cor0.col1 * + col1 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5437
SELECT DISTINCT CAST ( NULL AS INTEGER ) + cor0.col1 * + col1 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5438
SELECT CAST( NULL AS SIGNED ) * 83 + - col1 / ( 4 + col2 ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5438
SELECT CAST ( NULL AS INTEGER ) * 83 + - col1 / ( 4 + col2 ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 69 * col1 + + col0 col2 FROM tab2 AS cor0
----
1252
2146
4149

query I rowsort
SELECT ALL 73 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col0 * - col1 col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL + col2 - - col1 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col2 * + 72 FROM tab1 AS cor0
----
-3888
-4104
-6912

query I rowsort
SELECT DISTINCT + col0 * + 13 AS col0 FROM tab2 AS cor0
----
1014
1027
91

query I rowsort
SELECT + 86 + tab0.col2 FROM tab0
----
119
168
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5446
SELECT ALL + CAST( + col2 * col0 AS SIGNED ) + 30 * col0 AS col1 FROM tab2
----
399
4368
5372

skipif mysql # not compatible
query I rowsort label-5446
SELECT ALL + CAST ( + col2 * col0 AS INTEGER ) + 30 * col0 AS col1 FROM tab2
----
399
4368
5372

query I rowsort
SELECT ALL - col0 + ( - col1 ) * + tab0.col2 FROM tab0
----
-132
-2862
-7551

query I rowsort
SELECT ALL + col1 * col0 + col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT ALL 29 * 28 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
815
876
892

query I rowsort
SELECT + - cor0.col2 * ( - col2 ) + - col1 AS col0 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT DISTINCT + col0 + 6 FROM tab2 AS cor0
----
13
84
85

query I rowsort
SELECT DISTINCT 18 + - col0 * - col0 FROM tab1 AS cor0
----
27
4114
6418

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5453
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5453
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5454
SELECT ALL + cor0.col1 * - col2 DIV col2 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5454
SELECT ALL + cor0.col1 * - col2 / col2 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT col1 + - 93 + col1 * ( + col1 + col1 ) * col2 FROM tab0
----
1358082
18822
488129

query I rowsort
SELECT - - col1 * col1 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT col0 - - col2 * + ( - col1 ) * col0 AS col1 FROM tab2 cor0
----
-119574
-50955
-5852

query I rowsort
SELECT + - col2 * cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - col2 - cor0.col0 * + col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT - cor0.col1 + - col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL col1 * + col0 * + col1 + + col0 AS col0 FROM tab1 AS cor0
----
13600
2031
6464

query I rowsort
SELECT + + col1 * - col0 + 89 AS col2 FROM tab2 AS cor0
----
-1254
-128
-4513

onlyif mysql # use DIV operator for integer division
query I rowsort label-5463
SELECT ALL + col1 + col0 DIV + col1 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-5463
SELECT ALL + col1 + col0 / + col1 FROM tab2 AS cor0
----
21
31
60

query I rowsort
SELECT ALL ( + tab0.col2 ) * col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - ( col2 ) * col1 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5466
SELECT DISTINCT - col2 + cor0.col1 DIV - col2 AS col0 FROM tab0 AS cor0
----
-35
-83
-98

skipif mysql # not compatible
query I rowsort label-5466
SELECT DISTINCT - col2 + cor0.col1 / - col2 AS col0 FROM tab0 AS cor0
----
-35
-83
-98

query I rowsort
SELECT + col1 * cor0.col2 + + col1 * - ( - col1 + col0 ) FROM tab0 AS cor0
----
6111
7644
8170

query I rowsort
SELECT - 22 * + col2 + - col2 FROM tab2 AS cor0
----
-598
-621
-874

query I rowsort
SELECT + ( col0 ) + + col0 * - col1 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - + col0 * 18 FROM tab1 cor0
----
-1152
-1440
-54

query I rowsort
SELECT - cor0.col2 + - col1 * col1 AS col2 FROM tab0 AS cor0
----
-7429
-8363
-9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 35 col2 FROM tab1
----
35
35
35

query I rowsort
SELECT 68 * - col1 AS col1 FROM tab0
----
-5848
-6188
-6596

query I rowsort
SELECT DISTINCT - col1 + col1 * col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT ALL ( - 32 ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 7106326ae056e78044adc0aef747ef08

query I rowsort
SELECT + 82 + cor0.col2 AS col2 FROM tab2 AS cor0
----
108
109
120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + col0 col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL - - 18 * col2 FROM tab2 AS cor0
----
468
486
684

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5479
SELECT ALL CAST( NULL AS SIGNED ) * cor0.col2 / + col1 + + col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5479
SELECT ALL CAST ( NULL AS INTEGER ) * cor0.col2 / + col1 + + col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 - col0 * cor0.col0 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT - + 12 * col0 FROM tab0 AS cor0
----
-1068
-288
-420

query I rowsort
SELECT + col2 + col1 * - cor0.col2 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-5483
SELECT - 18 + col2 DIV + col1 FROM tab0
----
-18
-18
-18

skipif mysql # not compatible
query I rowsort label-5483
SELECT - 18 + col2 / + col1 FROM tab0
----
-18
-18
-18

query I rowsort
SELECT DISTINCT - - 91 FROM tab0, tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
91

query I rowsort
SELECT - - 11 * col2 FROM tab1 AS cor0
----
1056
594
627

query I rowsort
SELECT ALL - col2 * - 60 + - col0 AS col2 FROM tab0 AS cor0
----
1956
25
4831

query I rowsort
SELECT DISTINCT col2 * 50 FROM tab0
----
1650
4100
50

query I rowsort
SELECT ALL + 64 AS col1 FROM tab1 AS cor0
----
64
64
64

query I rowsort
SELECT + 23 * cor0.col2 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
628
676
953

query I rowsort
SELECT DISTINCT + col2 - + col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + cor0.col1 + col2 FROM tab1 cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - col1 AS REAL ) * col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - ( tab0.col1 ) FROM tab0, tab2 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5494
SELECT DISTINCT + col0 * + ( + col1 * col1 ) + + CAST( col2 AS SIGNED ) * col2 AS col0 FROM tab0
----
178593
329316
743733

skipif mysql # not compatible
query I rowsort label-5494
SELECT DISTINCT + col0 * + ( + col1 * col1 ) + + CAST ( col2 AS INTEGER ) * col2 AS col0 FROM tab0
----
178593
329316
743733

query I rowsort
SELECT ALL + 70 AS col0 FROM tab1
----
70
70
70

query I rowsort
SELECT + - col1 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + 94 * 24 + col1 * + ( + col2 ) AS col1 FROM tab2 AS cor0
----
2902
3093
3790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 + col1 col2 FROM tab1 cor0
----
0

query I rowsort
SELECT col1 * col2 + + col0 AS col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + 89 * cor0.col0 + col1 + + col0 * - col1 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-175282
-326103
-728997

query I rowsort
SELECT - ( - 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-5502
SELECT ALL + CAST( 18 AS SIGNED ) * col2 + - col2 + 1 * - col0 col0 FROM tab2 AS cor0
----
364
452
567

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5502
SELECT ALL + CAST ( 18 AS INTEGER ) * col2 + - col2 + 1 * - col0 col0 FROM tab2 AS cor0
----
364
452
567

query I rowsort
SELECT DISTINCT - 4 + 30 * - col1 AS col1 FROM tab2 AS cor0
----
-1774
-514
-934

query I rowsort
SELECT 69 * + cor0.col1 AS col2 FROM tab1 cor0
----
1794
690
897

onlyif mysql # use DIV operator for integer division
query I rowsort label-5505
SELECT - - ( col0 ) DIV col1 + - 58 * - cor0.col1 * - col0 + col2 AS col0 FROM tab0 AS cor0
----
-119679
-196909
-469660

skipif mysql # not compatible
query I rowsort label-5505
SELECT - - ( col0 ) / col1 + - 58 * - cor0.col1 * - col0 + col2 AS col0 FROM tab0 AS cor0
----
-119679
-196909
-469660

query I rowsort
SELECT ALL ( col2 ) - - col0 FROM tab2
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5507
SELECT + col2 * + col2 * - CAST( - ( col1 ) AS SIGNED ) FROM tab1 cor0
----
119808
32490
75816

skipif mysql # not compatible
query I rowsort label-5507
SELECT + col2 * + col2 * - CAST ( - ( col1 ) AS INTEGER ) FROM tab1 cor0
----
119808
32490
75816

query I rowsort
SELECT - 13 * col0 AS col1 FROM tab0 AS cor0
----
-1157
-312
-455

query I rowsort
SELECT col0 + - col1 * - col2 AS col2 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-5510
SELECT - 56 DIV col0 col1 FROM tab1 AS cor0
----
-18
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5510
SELECT - 56 / col0 col1 FROM tab1 AS cor0
----
-18
0
0

query I rowsort
SELECT - - 38 * - col0 * col1 FROM tab1 AS cor0
----
-24320
-2964
-39520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 71 + col1 col1 FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT + + col0 + ( 3 ) AS col0 FROM tab1 AS cor0
----
6
67
83

query I rowsort
SELECT - col2 * - col1 * col1 + - col0 AS col0 FROM tab2 AS cor0
----
10903
25940
90428

query I rowsort
SELECT - - col2 - col1 * - 65 FROM tab0 cor0
----
5623
5997
6306

query I rowsort
SELECT DISTINCT + col2 * col0 AS col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT - cor0.col1 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT - cor0.col1 * + col2 + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL cor0.col0 + + col2 * cor0.col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT - col2 + - 94 AS col1 FROM tab1 AS cor0
----
-148
-151
-190

onlyif mysql # use DIV operator for integer division
query I rowsort label-5521
SELECT DISTINCT - - col2 DIV + 41 AS col2 FROM tab1 AS cor0
----
1
2

skipif mysql # not compatible
query I rowsort label-5521
SELECT DISTINCT - - col2 / + 41 AS col2 FROM tab1 AS cor0
----
1
2

query I rowsort
SELECT ALL - cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT cor0.col0 * + ( + col1 + col2 ) * + col2 AS col0 FROM tab0 AS cor0
----
1262554
3430
94248

onlyif mysql # use DIV operator for integer division
query I rowsort label-5524
SELECT DISTINCT - col0 DIV + col0 + - 57 FROM tab1 cor0
----
-58

skipif mysql # not compatible
query I rowsort label-5524
SELECT DISTINCT - col0 / + col0 + - 57 FROM tab1 cor0
----
-58

query I rowsort
SELECT DISTINCT - + col2 * - ( col0 ) FROM tab0 cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + cor0.col0 col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT + - col2 * + ( + col1 ) FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT + col0 + - ( + 47 ) * - col1 AS col0 FROM tab1 AS cor0
----
1225
534
691

query I rowsort
SELECT DISTINCT + col2 + 93 FROM tab0 AS cor0
----
126
175
94

query I rowsort
SELECT - col2 * + 5 + - col2 AS col0 FROM tab1 AS cor0
----
-324
-342
-576

query I rowsort
SELECT ALL + + cor0.col1 * ( col2 * col2 ) + 58 AS col2 FROM tab1 cor0
----
119866
32548
75874

query I rowsort
SELECT col0 - + ( cor0.col1 ) * col0 FROM tab0 cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * + col1 col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5534
SELECT - 11 DIV + ( + col2 ) + ( col2 + col1 ) * - col0 AS col1 FROM tab0 AS cor0
----
-15397
-2856
-3441

skipif mysql # not compatible
query I rowsort label-5534
SELECT - 11 / + ( + col2 ) + ( col2 + col1 ) * - col0 AS col1 FROM tab0 AS cor0
----
-15397
-2856
-3441

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 16 col0 FROM tab2 AS cor0
----
16
16
16

query I rowsort
SELECT DISTINCT cor0.col1 + col1 * col1 AS col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL col0 * col0 + col1 - - tab0.col2 AS col2 FROM tab0
----
1323
695
8094

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 5 + 32 * col1 col1 FROM tab0 AS cor0
----
2757
2917
3109

query I rowsort
SELECT ALL + - ( + 56 ) FROM tab0 AS cor0
----
-56
-56
-56

query I rowsort
SELECT + - col1 * - col2 + - col0 * + ( 4 * col1 ) FROM tab0 AS cor0
----
-13483
-24934
-5418

query I rowsort
SELECT ALL + cor0.col2 * ( + col0 ) AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT col0 + + ( - col1 ) + 79 FROM tab1 AS cor0
----
133
146
56

query I rowsort
SELECT ALL + col1 + - ( - col2 + col0 ) FROM tab1
----
29
3
77

query I rowsort
SELECT DISTINCT col2 * col1 - tab2.col0 * col0 FROM tab2
----
-4550
-5595
788

query I rowsort
SELECT DISTINCT 94 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
94

query I rowsort
SELECT + + cor0.col1 * col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - 2 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 20c9213316527d507e26425041e08387

query I rowsort
SELECT DISTINCT - col0 * + col1 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5549
SELECT DISTINCT - - 56 * + cor0.col0 + + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5549
SELECT DISTINCT - - 56 * + cor0.col0 + + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col2 ) col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - 90 + cor0.col0 * - col0 FROM tab1 AS cor0
----
-4186
-6490
-99

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col1 * col2 AS REAL ) AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT + cor0.col2 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT cor0.col1 * col0 + + 66 AS col1 FROM tab1 AS cor0
----
1106
144
706

query I rowsort
SELECT + cor0.col0 * cor1.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to eb103eabe531563e672e54874d056f9f

query I rowsort
SELECT - 2 - + col0 * + 48 FROM tab0
----
-1154
-1682
-4274

query I rowsort
SELECT DISTINCT - 26 FROM tab0, tab2, tab0 AS cor0
----
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5558
SELECT 18 DIV + col1 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5558
SELECT 18 / + col1 FROM tab2 cor0
----
0
0
1

query I rowsort
SELECT 52 + col2 FROM tab1
----
106
109
148

query I rowsort
SELECT col2 * - col0 + + col1 + + col0 FROM tab1 AS cor0
----
-133
-3574
-7587

query I rowsort
SELECT DISTINCT + 43 * - col0 FROM tab1 cor0
----
-129
-2752
-3440

query I rowsort
SELECT + 87 * cor0.col2 + cor0.col2 FROM tab1 AS cor0
----
4752
5016
8448

onlyif mysql # use DIV operator for integer division
query I rowsort label-5563
SELECT DISTINCT + ( col1 ) DIV ( + col0 ) FROM tab1 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-5563
SELECT DISTINCT + ( col1 ) / ( + col0 ) FROM tab1 AS cor0
----
0
8

query I rowsort
SELECT 99 * + col1 FROM tab0 cor0
----
8514
9009
9603

query I rowsort
SELECT ( + col1 ) * col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT + - cor0.col0 + col1 + 7 FROM tab0 AS cor0
----
69
69
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5567
SELECT col1 DIV - col1 + - ( tab1.col1 + col0 ) col0 FROM tab1
----
-30
-75
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5567
SELECT col1 / - col1 + - ( tab1.col1 + col0 ) col0 FROM tab1
----
-30
-75
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5568
SELECT + col1 + - CAST( NULL AS SIGNED ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5568
SELECT + col1 + - CAST ( NULL AS INTEGER ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + col2 * 82 AS col1 FROM tab2 AS cor0
----
2191
2245
3133

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col1 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
3
64
80

query I rowsort
SELECT ALL 51 * tab1.col2 FROM tab1
----
2754
2907
4896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col1 * cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 9b23e5e74ef3405a4dbf05cceb18c8a8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5574
SELECT + CAST( - col1 AS SIGNED ) * - cor0.col1 - ( cor0.col0 * col0 ) AS col1 FROM tab0 AS cor0
----
360
6820
8184

skipif mysql # not compatible
query I rowsort label-5574
SELECT + CAST ( - col1 AS INTEGER ) * - cor0.col1 - ( cor0.col0 * col0 ) AS col1 FROM tab0 AS cor0
----
360
6820
8184

query I rowsort
SELECT DISTINCT - + col0 * - 69 FROM tab0 AS cor0
----
1656
2415
6141

query I rowsort
SELECT - 14 * - col0 + col2 FROM tab0 AS cor0
----
1328
369
491

query I rowsort
SELECT DISTINCT col0 + ( - col0 * col1 ) AS col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT - 76 + tab1.col2 FROM tab1
----
-19
-22
20

query I rowsort
SELECT ALL col1 + + col0 + - col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL col0 * - col0 + + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT 52 + - cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
-137
-1976
-2950

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0, tab1 cor1, tab2 AS cor2
----
972 values hashing to caf6adb9936510208f5945a7e5c76f14

query I rowsort
SELECT DISTINCT - 47 + cor0.col0 FROM tab1 AS cor0
----
-44
17
33

query I rowsort
SELECT + 30 + - col0 AS col0 FROM tab0 AS cor0
----
-5
-59
6

query I rowsort
SELECT DISTINCT + ( 84 ) AS col1 FROM tab0
----
84

query I rowsort
SELECT DISTINCT 11 * - col0 + - col1 AS col1 FROM tab0 AS cor0
----
-1070
-350
-482

onlyif mysql # use DIV operator for integer division
query I rowsort label-5587
SELECT DISTINCT 64 + col1 DIV + col1 FROM tab1 AS cor0
----
65

skipif mysql # not compatible
query I rowsort label-5587
SELECT DISTINCT 64 + col1 / + col1 FROM tab1 AS cor0
----
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5588
SELECT ALL - col2 DIV cor0.col2 + 92 + - col2 * - col0 FROM tab0 AS cor0
----
126
7389
883

skipif mysql # not compatible
query I rowsort label-5588
SELECT ALL - col2 / cor0.col2 + 92 + - col2 * - col0 FROM tab0 AS cor0
----
126
7389
883

query I rowsort
SELECT col1 + col0 + + col2 FROM tab1
----
131
189
83

query I rowsort
SELECT DISTINCT 1 FROM tab0, tab2, tab1 AS cor0
----
1

query I rowsort
SELECT 33 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
115
34
66

query I rowsort
SELECT ALL cor1.col1 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - col1 * col1 * col0 + + ( cor0.col2 ) AS col1 FROM tab2 AS cor0
----
-22793
-271492
-6700

query I rowsort
SELECT DISTINCT - 80 AS col0 FROM tab1, tab2 AS cor0
----
-80

query I rowsort
SELECT - 72 + + col2 * 32 AS col0 FROM tab1 AS cor0
----
1656
1752
3000

query I rowsort
SELECT + + cor0.col2 * col0 * + col0 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT - - col1 + 48 FROM tab0 AS cor0
----
134
139
145

query I rowsort
SELECT + 79 * col2 AS col2 FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT + - ( col2 ) + col1 * - col2 * - col2 FROM tab0 AS cor0
----
611802
93621
96

query I rowsort
SELECT - - cor0.col0 * + col0 + col2 + cor0.col2 FROM tab1 AS cor0
----
117
4210
6592

query I rowsort
SELECT - col2 * + col0 + - 33 AS col0 FROM tab0 AS cor0
----
-68
-7331
-825

onlyif mysql # use DIV operator for integer division
query I rowsort label-5602
SELECT DISTINCT col0 DIV - col0 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5602
SELECT DISTINCT col0 / - col0 AS col0 FROM tab1 AS cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5603
SELECT DISTINCT col2 * + CAST( NULL AS SIGNED ) + + col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5603
SELECT DISTINCT col2 * + CAST ( NULL AS INTEGER ) + + col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col0 * + 37 * 8 FROM tab1 AS cor0
----
18944
23680
888

query I rowsort
SELECT - col1 * - col0 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-5606
SELECT ALL cor0.col0 + + cor0.col0 DIV col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5606
SELECT ALL cor0.col0 + + cor0.col0 / col1 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5607
SELECT DISTINCT + col2 DIV - col0 col2 FROM tab0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5607
SELECT DISTINCT + col2 / - col0 col2 FROM tab0
----
-1
0

query I rowsort
SELECT col1 * - cor0.col1 + cor0.col1 * - cor0.col1 FROM tab1 AS cor0
----
-1352
-200
-338

query I rowsort
SELECT DISTINCT + - col1 * 25 + + 79 AS col2 FROM tab0 AS cor0
----
-2071
-2196
-2346

query I rowsort
SELECT cor0.col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL col1 + 89 FROM tab1 AS cor0
----
102
115
99

query I rowsort
SELECT ALL + + col2 + 38 FROM tab2 AS cor0
----
64
65
76

query I rowsort
SELECT DISTINCT col2 - - 54 FROM tab2
----
80
81
92

query I rowsort
SELECT tab1.col0 + 34 * - 53 FROM tab1
----
-1722
-1738
-1799

query I rowsort
SELECT DISTINCT col2 * ( - col1 ) - col1 AS col2 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT ALL ( - col1 ) FROM tab2 cor0
----
-17
-31
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5617
SELECT DISTINCT - CAST( NULL AS SIGNED ) * - cor0.col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5617
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * - cor0.col0 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + cor0.col0 + - ( col1 + ( col2 ) ) * + col0 * + cor0.col0 FROM tab2 cor0
----
-2835
-343176
-517062

query I rowsort
SELECT ALL - col2 * - cor0.col2 FROM tab1 cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) * - col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT tab2.col0 * col0 + col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT DISTINCT + 91 * + col0 FROM tab1 cor0
----
273
5824
7280

onlyif mysql # use DIV operator for integer division
query I rowsort label-5623
SELECT DISTINCT 25 + - col2 DIV + cor0.col0 FROM tab2 AS cor0
----
22
25

skipif mysql # not compatible
query I rowsort label-5623
SELECT DISTINCT 25 + - col2 / + cor0.col0 FROM tab2 AS cor0
----
22
25

query I rowsort
SELECT ALL - - ( col2 ) + ( + col0 * - col2 ) FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - cor0.col1 + cor0.col1 * - 20 FROM tab2 cor0
----
-1239
-357
-651

onlyif mysql # use DIV operator for integer division
query I rowsort label-5626
SELECT ALL - ( col0 ) DIV + col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5626
SELECT ALL - ( col0 ) / + col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + ( 66 ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 29794915b585eea848ad670075452c88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 88 + cor0.col1 col0 FROM tab0 AS cor0
----
174
179
185

onlyif mysql # use DIV operator for integer division
query I rowsort label-5629
SELECT + col1 + col2 DIV col1 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-5629
SELECT + col1 + col2 / col1 FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT 29 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT + col0 - col1 AS col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL - + tab1.col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 48 col2 FROM tab1
----
48

query I rowsort
SELECT 87 * - col2 + + 56 FROM tab2
----
-2206
-2293
-3250

query I rowsort
SELECT ALL - tab2.col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT cor0.col2 * - col1 * col1 AS col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT - 72 * - col1 AS col1 FROM tab2
----
1224
2232
4248

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 - - ( + col1 ) * + col2 col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT + col2 + + 66 AS col1 FROM tab1 AS cor0
----
120
123
162

query I rowsort
SELECT ALL + col0 * ( + cor0.col2 ) AS col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5641
SELECT DISTINCT col1 DIV col1 + col1 AS col2 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-5641
SELECT DISTINCT col1 / col1 + col1 AS col2 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT - col1 * 14 FROM tab0 AS cor0
----
-1204
-1274
-1358

query I rowsort
SELECT - col0 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT col2 * ( + cor0.col0 ) * col0 + col1 AS col1 FROM tab1 AS cor0
----
233482
512
614413

query I rowsort
SELECT + col1 + - 4 AS col1 FROM tab2 cor0
----
13
27
55

query I rowsort
SELECT ALL + col0 - col2 * col0 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - col2 * 68 * col0 FROM tab1 AS cor0
----
-11016
-248064
-522240

query I rowsort
SELECT DISTINCT + col0 + col0 + col0 AS col1 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT DISTINCT - + cor0.col0 * - col2 + + col1 AS col2 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT - 30 * - col0 + cor0.col1 * col0 + 4 * cor0.col0 FROM tab2 cor0
----
4029
455
7254

query I rowsort
SELECT ALL + + col1 * + 39 AS col0 FROM tab1 AS cor0
----
1014
390
507

query I rowsort
SELECT ALL ( col2 ) * - col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-157464
-185193
-884736

query I rowsort
SELECT col0 * - 27 AS col0 FROM tab2 cor0
----
-189
-2106
-2133

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 80 col0 FROM tab1 AS cor0
----
80

query I rowsort
SELECT + + col1 * + 63 + + col1 AS col1 FROM tab1 AS cor0
----
1664
640
832

query I rowsort
SELECT - + col0 * - col2 * col1 AS col2 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 79 col2 FROM tab0 cor0
----
79

query I rowsort
SELECT ALL + 84 AS col1 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

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 - 76 * col2 col1 FROM tab1 AS cor0
----
-4104
-4332
-7296

query I rowsort
SELECT DISTINCT - - 2 * - cor0.col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT - col2 + - cor0.col2 * - ( - col1 * col0 ) FROM tab0 AS cor0
----
-3396
-664200
-68145

query I rowsort
SELECT col2 * + col0 + 95 FROM tab2 AS cor0
----
2123
284
3097

query I rowsort
SELECT DISTINCT 2 + + col1 * 30 FROM tab0 AS cor0
----
2582
2732
2912

query I rowsort
SELECT - tab2.col0 + 91 AS col0 FROM tab2
----
12
13
84

query I rowsort
SELECT ALL + - col0 + + col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + col0 + + 31 AS col1 FROM tab1 AS cor0
----
-20
15
38

query I rowsort
SELECT DISTINCT col1 * 24 * + col0 AS col1 FROM tab0
----
194376
49536
81480

query I rowsort
SELECT ALL + col0 * ( 91 ) FROM tab1 cor0
----
273
5824
7280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5670
SELECT + cor0.col1 * + CAST( NULL AS SIGNED ) - col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5670
SELECT + cor0.col1 * + CAST ( NULL AS INTEGER ) - col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * 53 + + 42 AS col0 FROM tab1 AS cor0
----
2904
3063
5130

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5672
SELECT ALL + cor0.col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5672
SELECT ALL + cor0.col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 * 56 AS col0 FROM tab1 AS cor0
----
3024
3192
5376

query I rowsort
SELECT DISTINCT + cor0.col0 * - 74 AS col2 FROM tab1 cor0
----
-222
-4736
-5920

query I rowsort
SELECT col1 * col0 * col0 FROM tab1 AS cor0
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + - cor0.col2 col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - col1 + + col1 + + col1 * col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - 96 + + col2 AS col0 FROM tab0 AS cor0
----
-14
-63
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 36 * - 69 + + col0 col2 FROM tab2 AS cor0
----
-2405
-2406
-2477

query I rowsort
SELECT DISTINCT 74 + 50 FROM tab2, tab2 AS cor0, tab1, tab1 AS cor1
----
124

query I rowsort
SELECT DISTINCT - 4 + 14 FROM tab1, tab1 cor0
----
10

query I rowsort
SELECT cor0.col1 + - cor0.col1 * + col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT col1 + + 10 + col2 * col2 AS col1 FROM tab2
----
1471
745
770

onlyif mysql # use DIV operator for integer division
query I rowsort label-5684
SELECT DISTINCT + - col2 DIV col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5684
SELECT DISTINCT + - col2 / col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - col0 * + col2 * ( - 59 ) FROM tab1 AS cor0
----
215232
453120
9558

onlyif mysql # use DIV operator for integer division
query I rowsort label-5686
SELECT ALL - + 93 DIV cor0.col1 FROM tab1 AS cor0
----
-3
-7
-9

skipif mysql # not compatible
query I rowsort label-5686
SELECT ALL - + 93 / cor0.col1 FROM tab1 AS cor0
----
-3
-7
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5687
SELECT - tab0.col0 + - col0 + CAST( + col1 AS SIGNED ) col1 FROM tab0
----
-87
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5687
SELECT - tab0.col0 + - col0 + CAST ( + col1 AS INTEGER ) col1 FROM tab0
----
-87
27
38

query I rowsort
SELECT DISTINCT + col1 * col2 + - ( col1 ) FROM tab2
----
1475
629
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5689
SELECT - col0 - 4 DIV 88 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5689
SELECT - col0 - 4 / 88 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5690
SELECT col2 + CAST( 83 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
137
140
179

skipif mysql # not compatible
query I rowsort label-5690
SELECT col2 + CAST ( 83 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
137
140
179

query I rowsort
SELECT - 36 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 3bcd07d22b62d2042b499253b1c13d9e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 52 * - col1 + + ( 76 ) col1 FROM tab0
----
-4396
-4656
-4968

query I rowsort
SELECT DISTINCT - ( col1 ) + col2 * - col1 AS col2 FROM tab1
----
-1261
-1430
-580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 92 col2 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * 35 col0 FROM tab2 cor0
----
1085
2065
595

query I rowsort
SELECT DISTINCT - col0 * - tab1.col2 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 61 * - 72 col2 FROM tab0, tab2, tab2 AS cor0, tab1
----
81 values hashing to 615bd688f3577fc653d69128b59241de

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 * ( + col0 ) col1 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col1 col0 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL col2 * col1 * tab0.col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT + cor0.col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT tab2.col1 - 32 * col0 AS col0 FROM tab2
----
-193
-2437
-2511

query I rowsort
SELECT col2 + tab2.col1 - - col0 * col0 FROM tab2
----
107
6169
6296

query I rowsort
SELECT + col1 * - 7 - col2 AS col0 FROM tab0
----
-635
-680
-719

onlyif mysql # use DIV operator for integer division
query I rowsort label-5705
SELECT col0 DIV + col1 AS col0 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-5705
SELECT col0 / + col1 AS col0 FROM tab1
----
0
6
6

query I rowsort
SELECT DISTINCT + ( tab1.col1 * - col2 ) AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL 94 AS col1 FROM tab2
----
94
94
94

query I rowsort
SELECT DISTINCT - col1 * 99 AS col2 FROM tab0
----
-8514
-9009
-9603

query I rowsort
SELECT + 28 * col2 FROM tab1 AS cor0
----
1512
1596
2688

query I rowsort
SELECT ( - col2 ) + + col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT 3 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT ALL 11 + 49 FROM tab1 AS cor0
----
60
60
60

query I rowsort
SELECT DISTINCT - 52 * - 57 * col2 FROM tab0
----
243048
2964
97812

query I rowsort
SELECT - 14 AS col1 FROM tab2 AS cor0
----
-14
-14
-14

query I rowsort
SELECT - - ( + col1 ) + + 92 * col1 AS col1 FROM tab0 AS cor0
----
7998
8463
9021

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 80 + - col1 col2 FROM tab1 AS cor0
----
54
67
70

query I rowsort
SELECT DISTINCT ( 97 ) * + col0 FROM tab0
----
2328
3395
8633

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab2 cor1, tab1, tab2 cor2
----
3645 values hashing to 6726a15019c52908f1f1d0df0cd4c1b8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - cor0.col2 col1 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5720
SELECT + col2 DIV cor0.col2 + ( - col0 * - col0 ) FROM tab0 AS cor0
----
1226
577
7922

skipif mysql # not compatible
query I rowsort label-5720
SELECT + col2 / cor0.col2 + ( - col0 * - col0 ) FROM tab0 AS cor0
----
1226
577
7922

query I rowsort
SELECT ALL col2 * col2 * 46 FROM tab2 cor0
----
31096
33534
66424

query I rowsort
SELECT ALL - + 34 * col2 AS col2 FROM tab0 AS cor0
----
-1122
-2788
-34

query I rowsort
SELECT ALL + 88 * - col1 * 32 AS col2 FROM tab0 AS cor0
----
-242176
-256256
-273152

onlyif mysql # use DIV operator for integer division
query I rowsort label-5724
SELECT - col2 DIV - col1 - - 80 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
2080
2160
3042

skipif mysql # not compatible
query I rowsort label-5724
SELECT - col2 / - col1 - - 80 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
2080
2160
3042

query I rowsort
SELECT ALL + - 64 * cor0.col0 * ( - 57 ) + + col1 AS col1 FROM tab1 AS cor0
----
10970
233482
291853

query I rowsort
SELECT DISTINCT - - 14 - - col2 FROM tab1 AS cor0
----
110
68
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-5727
SELECT ALL 91 DIV + cor0.col1 AS col0 FROM tab2 cor0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-5727
SELECT ALL 91 / + cor0.col1 AS col0 FROM tab2 cor0
----
1
2
5

query I rowsort
SELECT col0 * + col2 + - col2 * 39 * + col1 FROM tab2 AS cor0
----
-22192
-32454
-57798

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5729
SELECT DISTINCT - + 24 + + col0 * - CAST( + cor0.col1 AS SIGNED ) FROM tab1 AS cor0
----
-102
-1064
-664

skipif mysql # not compatible
query I rowsort label-5729
SELECT DISTINCT - + 24 + + col0 * - CAST ( + cor0.col1 AS INTEGER ) FROM tab1 AS cor0
----
-102
-1064
-664

query I rowsort
SELECT + cor0.col2 + col2 FROM tab0 cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5731
SELECT DISTINCT - col2 DIV col0 + 77 * col2 FROM tab0 AS cor0
----
2540
6314
77

skipif mysql # not compatible
query I rowsort label-5731
SELECT DISTINCT - col2 / col0 + 77 * col2 FROM tab0 AS cor0
----
2540
6314
77

query I rowsort
SELECT ALL - - col2 * ( + cor0.col2 + col2 ) FROM tab1 cor0
----
18432
5832
6498

query I rowsort
SELECT - cor0.col1 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 * 53 + col2 * col2 * ( ( col0 ) * col1 ) AS col1 FROM tab1 AS cor0
----
2078830
226070
9583951

query I rowsort
SELECT DISTINCT col0 * + 57 AS col2 FROM tab2 AS cor0
----
399
4446
4503

query I rowsort
SELECT + col1 + col0 * 82 AS col2 FROM tab1 AS cor0
----
272
5258
6573

query I rowsort
SELECT DISTINCT + col1 * ( col2 ) * col0 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col1 col0 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 - - tab0.col0 col2 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to 30d7054d1d16cc0cd2af7741ad06735e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5740
SELECT ALL + CAST( NULL AS SIGNED ) * col2 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-5740
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( 83 ) + col1 FROM tab1 AS cor0
----
-57
-70
-73

query I rowsort
SELECT - 60 * - col0 FROM tab0 AS cor0
----
1440
2100
5340

query I rowsort
SELECT + col2 + 67 FROM tab0
----
100
149
68

query I rowsort
SELECT ALL + - ( col0 ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + 79 + - ( col1 ) AS col1 FROM tab2 AS cor0
----
20
48
62

query I rowsort
SELECT ALL - ( + 88 ) * + col1 FROM tab2 AS cor0
----
-1496
-2728
-5192

query I rowsort
SELECT DISTINCT + cor0.col2 + col1 * col2 + cor0.col0 FROM tab1 AS cor0
----
1424
1461
691

query I rowsort
SELECT DISTINCT + col0 * - col0 + + col2 * + col1 FROM tab0 AS cor0
----
-1128
-459
2262

query I rowsort
SELECT + - ( ( + col2 ) ) + - 67 AS col0 FROM tab1 AS cor0
----
-121
-124
-163

query I rowsort
SELECT DISTINCT 90 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
90

query I rowsort
SELECT ALL col1 + - ( col1 ) AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT - 57 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT DISTINCT + 43 - 51 AS col2 FROM tab0 AS cor0
----
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col2 col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL - + col2 + 25 AS col1 FROM tab1 AS cor0
----
-29
-32
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 col2 FROM tab0
----
-5
-5
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col0 ) + col2 * col2 col2 FROM tab1 cor0
----
2913
3185
9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5758
SELECT DISTINCT - 11 * + 51 + - col0 * - CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
-526
231
6737

skipif mysql # not compatible
query I rowsort label-5758
SELECT DISTINCT - 11 * + 51 + - col0 * - CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
-526
231
6737

query I rowsort
SELECT DISTINCT - col2 * col1 + + col1 AS col0 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT ALL 0 + + 83 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

query I rowsort
SELECT ALL col2 * col0 - + 38 AS col1 FROM tab1
----
124
3610
7642

query I rowsort
SELECT - col2 * col1 + - col2 AS col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT + 60 - - col1 * col1 AS col2 FROM tab2 cor0
----
1021
349
3541

query I rowsort
SELECT DISTINCT - col1 + col2 - 60 * + col2 * - col0 FROM tab1 AS cor0
----
218927
460883
9748

onlyif mysql # use DIV operator for integer division
query I rowsort label-5765
SELECT DISTINCT 21 + - col2 DIV + ( - cor0.col0 * cor0.col2 ) col2 FROM tab0 AS cor0
----
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5765
SELECT DISTINCT 21 + - col2 / + ( - cor0.col0 * cor0.col2 ) col2 FROM tab0 AS cor0
----
21

query I rowsort
SELECT - 45 - + col0 FROM tab2 AS cor0
----
-123
-124
-52

query I rowsort
SELECT ALL col2 + col2 * ( col2 * col0 ) AS col1 FROM tab1 AS cor0
----
207993
737376
8802

query I rowsort
SELECT + col2 * cor0.col1 + - 56 AS col0 FROM tab0 cor0
----
2782
41
7406

query I rowsort
SELECT col0 * + col1 * col2 - 22 * + col0 * col1 AS col2 FROM tab1 AS cor0
----
22400
2496
76960

query I rowsort
SELECT DISTINCT + col1 * - col2 - - 3 AS col2 FROM tab2 AS cor0
----
-1531
-643
-834

query I rowsort
SELECT 49 * col2 + + col1 AS col2 FROM tab1 AS cor0
----
2672
2803
4717

query I rowsort
SELECT ( - col2 * col2 ) + col1 AS col2 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT ALL + col2 * - 28 * + col0 + - col2 * - col2 * col0 FROM tab0 AS cor0
----
-945
394092
3960

query I rowsort
SELECT DISTINCT - col1 - + 99 AS col1 FROM tab0 AS cor0
----
-185
-190
-196

query I rowsort
SELECT - col0 * ( tab0.col1 ) AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT + col0 + 40 AS col2 FROM tab1
----
104
120
43

query I rowsort
SELECT DISTINCT - col2 * - cor0.col2 * + 8 + cor0.col2 FROM tab1 AS cor0
----
23382
26049
73824

query I rowsort
SELECT - - col2 + + col1 * 88 * - col2 AS col2 FROM tab0 cor0
----
-249711
-656574
-8535

query I rowsort
SELECT DISTINCT cor0.col0 + cor0.col1 AS col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL + - cor0.col2 + + col2 * cor0.col2 FROM tab0 cor0
----
0
1056
6642

query I rowsort
SELECT + col2 * - ( + 4 ) * + col2 + - 7 FROM tab2 AS cor0
----
-2711
-2923
-5783

query I rowsort
SELECT DISTINCT col1 * - col0 + + cor0.col1 * col0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - - col0 + + col1 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + col1 * col2 + 62 AS col0 FROM tab2 AS cor0
----
1596
708
899

query I rowsort
SELECT + - col0 * col0 + - col0 AS col2 FROM tab2 AS cor0
----
-56
-6162
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 11 col2 FROM tab0
----
11
11
11

query I rowsort
SELECT 19 * tab2.col2 + + tab2.col0 * col1 FROM tab2
----
2065
5096
730

query I rowsort
SELECT - 61 + col1 * - col2 FROM tab1
----
-1309
-1465
-631

query I rowsort
SELECT - + 57 FROM tab1 cor0
----
-57
-57
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5790
SELECT + cor0.col2 DIV - col1 + - col1 + cor0.col2 FROM tab1 AS cor0
----
26
42
76

skipif mysql # not compatible
query I rowsort label-5790
SELECT + cor0.col2 / - col1 + - col1 + cor0.col2 FROM tab1 AS cor0
----
26
42
76

query I rowsort
SELECT ALL tab1.col0 * tab1.col1 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT - 9 AS col0 FROM tab1, tab0, tab0 AS cor0
----
-9

query I rowsort
SELECT DISTINCT - ( + 19 ) AS col2 FROM tab2, tab0, tab1 AS cor0
----
-19

query I rowsort
SELECT - - col0 * col0 + col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT + - col2 - + col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT - + 7 * + col0 + + col1 * col1 * col0 FROM tab1 AS cor0
----
12960
2007
5952

query I rowsort
SELECT + col2 + + col0 * col1 * + col0 FROM tab0 AS cor0
----
118826
49569
720893

query I rowsort
SELECT ALL + col2 + - 66 * ( col2 ) * + col0 AS col0 FROM tab1 AS cor0
----
-10638
-240711
-506784

onlyif mysql # use DIV operator for integer division
query I rowsort label-5799
SELECT DISTINCT col1 DIV 15 FROM tab2 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5799
SELECT DISTINCT col1 / 15 FROM tab2 AS cor0
----
1
2
3

query I rowsort
SELECT - col1 + - col2 * + 8 + + cor0.col1 * - col1 AS col0 FROM tab1 AS cor0
----
-1134
-566
-950

query I rowsort
SELECT ALL col1 + cor0.col0 FROM tab0 cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5802
SELECT DISTINCT + col1 + CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-5802
SELECT DISTINCT + col1 + CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - col2 + cor0.col2 * col2 * col2 AS col1 FROM tab2 AS cor0
----
17550
19656
54834

onlyif mysql # use DIV operator for integer division
query I rowsort label-5804
SELECT + col2 + ( + cor0.col2 ) * col2 * ( + col2 ) + col1 * col0 DIV + 97 col1 FROM tab0 AS cor0
----
35991
37
551533

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5804
SELECT + col2 + ( + cor0.col2 ) * col2 * ( + col2 ) + col1 * col0 / + 97 col1 FROM tab0 AS cor0
----
35991
37
551533

onlyif mysql # use DIV operator for integer division
query I rowsort label-5805
SELECT DISTINCT + - col1 DIV ( ( col2 ) ) FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-5805
SELECT DISTINCT + - col1 / ( ( col2 ) ) FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT + col1 * - 9 FROM tab1 AS cor0
----
-117
-234
-90

query I rowsort
SELECT DISTINCT - 68 + col1 FROM tab1 AS cor0
----
-42
-55
-58

query I rowsort
SELECT DISTINCT - col0 * + col2 * + col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT 55 * col0 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT 17 * - 25 FROM tab1 AS cor0
----
-425
-425
-425

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab2 AS cor1, tab2 cor2
----
972 values hashing to 617c9545df26d6d983e3967864e8e9e4

query I rowsort
SELECT ALL col2 * 27 AS col1 FROM tab2
----
1026
702
729

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 cor2
----
972 values hashing to a8481bfbfcb330825976c5896e54bc19

query I rowsort
SELECT col0 * col2 * + col0 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT 10 FROM tab0, tab0 cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to bf75e71325a06683558cf93fd725ad16

query I rowsort
SELECT + 89 + 77 FROM tab2 AS cor0
----
166
166
166

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5817
SELECT - + CAST( NULL AS SIGNED ) + col2 * - col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5817
SELECT - + CAST ( NULL AS INTEGER ) + col2 * - col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 2 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT + cor0.col1 AS col2 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT - col2 * + 22 FROM tab1
----
-1188
-1254
-2112

query I rowsort
SELECT + - cor0.col2 * + 51 + col2 + col2 FROM tab2 AS cor0
----
-1274
-1323
-1862

query I rowsort
SELECT - col0 + - col0 + - 2 AS col2 FROM tab0 AS cor0
----
-180
-50
-72

query I rowsort
SELECT + cor0.col2 + - col2 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - cor0.col2 * - 84 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 0063e3d4b3ae644db98bfb3860e2b98d

query I rowsort
SELECT - - col2 + cor0.col2 AS col0 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT ALL - col2 + - cor0.col1 + col1 AS col1 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT ALL 39 FROM tab1 cor0
----
39
39
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5828
SELECT - CAST( NULL AS SIGNED ) * col0 + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5828
SELECT - CAST ( NULL AS INTEGER ) * col0 + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( - col2 ) + + col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-5830
SELECT ALL - col0 + col2 DIV col0 AS col2 FROM tab2
----
-4
-78
-79

skipif mysql # not compatible
query I rowsort label-5830
SELECT ALL - col0 + col2 / col0 AS col2 FROM tab2
----
-4
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5831
SELECT tab2.col1 + 73 - col2 DIV - col0 FROM tab2
----
107
132
90

skipif mysql # not compatible
query I rowsort label-5831
SELECT tab2.col1 + 73 - col2 / - col0 FROM tab2
----
107
132
90

query I rowsort
SELECT - col0 - - 1 * - col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT col2 * ( 82 ) * col1 AS col1 FROM tab1
----
102336
115128
46740

query I rowsort
SELECT - col1 * tab0.col0 + tab0.col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT col0 * ( + ( - col0 ) ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5836
SELECT col0 * col1 + + col0 DIV ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
1041
641
79

skipif mysql # not compatible
query I rowsort label-5836
SELECT col0 * col1 + + col0 / ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
1041
641
79

query I rowsort
SELECT ( col2 ) + + 93 * - col0 FROM tab1 AS cor0
----
-225
-5895
-7344

query I rowsort
SELECT - col0 * + cor0.col1 + + col2 + 48 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-1714
-3745
-879

query I rowsort
SELECT + col0 * col0 + + col0 FROM tab0
----
1260
600
8010

query I rowsort
SELECT DISTINCT + cor0.col0 * + col1 + cor0.col2 * + col0 AS col2 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT 70 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT col1 + - tab2.col2 AS col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT DISTINCT - 26 AS col1 FROM tab1, tab0 AS cor0
----
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5844
SELECT DISTINCT - col0 / + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5844
SELECT DISTINCT - col0 / + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT - + cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL col2 * col1 + - col2 * col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5847
SELECT col1 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5847
SELECT col1 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 16 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT DISTINCT + ( + col2 * col0 ) + 98 AS col0 FROM tab1
----
260
3746
7778

query I rowsort
SELECT ALL + col2 + 68 FROM tab2
----
106
94
95

query I rowsort
SELECT - - ( - col1 ) * col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col1 * - 96 + - tab1.col0 + - col1 FROM tab1
----
-1034
-1341
-2525

query I rowsort
SELECT - col0 * - col2 + col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT 69 - - col1 * tab0.col1 FROM tab0
----
7465
8350
9478

query I rowsort
SELECT 97 + - col2 AS col2 FROM tab0 AS cor0
----
15
64
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col1 col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5857
SELECT + + col1 + col0 DIV + col1 AS col2 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-5857
SELECT + + col1 + col0 / + col1 AS col2 FROM tab2 AS cor0
----
21
31
60

query I rowsort
SELECT cor0.col1 + col1 * + col0 FROM tab1 cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-5859
SELECT - col0 DIV 77 + col2 AS col1 FROM tab0 cor0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-5859
SELECT - col0 / 77 + col2 AS col1 FROM tab0 cor0
----
1
33
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5860
SELECT + + col0 * col1 + + col1 DIV 48 AS col1 FROM tab0 AS cor0
----
2065
3397
8100

skipif mysql # not compatible
query I rowsort label-5860
SELECT + + col0 * col1 + + col1 / 48 AS col1 FROM tab0 AS cor0
----
2065
3397
8100

onlyif mysql # use DIV operator for integer division
query I rowsort label-5861
SELECT DISTINCT + col2 + col2 DIV col0 + - col1 FROM tab0 cor0
----
-52
-9
-96

skipif mysql # not compatible
query I rowsort label-5861
SELECT DISTINCT + col2 + col2 / col0 + - col1 FROM tab0 cor0
----
-52
-9
-96

query I rowsort
SELECT DISTINCT + col1 * col0 + col2 * col0 AS col2 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT DISTINCT + col2 + + col0 * + col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT - col2 + cor0.col2 * - col1 * ( + col0 ) FROM tab0 cor0
----
-3396
-664200
-68145

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5865
SELECT DISTINCT - + ( col0 ) + CAST( NULL AS SIGNED ) + + col1 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5865
SELECT DISTINCT - + ( col0 ) + CAST ( NULL AS INTEGER ) + + col1 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - - col0 + - col1 AS col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT 12 * cor0.col0 * + 6 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to 18a75408bc15f458d0d684a9de456b0b

query I rowsort
SELECT ( + 81 + col1 ) AS col1 FROM tab0
----
167
172
178

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5869
SELECT - CAST( NULL AS SIGNED ) * - col2 * + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5869
SELECT - CAST ( NULL AS INTEGER ) * - col2 * + col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - 42 AS col2 FROM tab1
----
-42
-42
-42

query I rowsort
SELECT ALL + + cor0.col1 - col2 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT col0 + col2 * + col2 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-5873
SELECT + ( + col0 ) DIV + 48 + col2 FROM tab2 AS cor0
----
27
27
39

skipif mysql # not compatible
query I rowsort label-5873
SELECT + ( + col0 ) / + 48 + col2 FROM tab2 AS cor0
----
27
27
39

query I rowsort
SELECT - 69 + col1 + col1 FROM tab0 AS cor0
----
103
113
125

query I rowsort
SELECT + - 30 * + col0 + col0 * + 89 FROM tab2 AS cor0
----
413
4602
4661

query I rowsort
SELECT + + 0 - col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - - col2 col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT 76 * + col2 + 19 + - 9 FROM tab0 AS cor0
----
2518
6242
86

query I rowsort
SELECT DISTINCT - col1 + + col2 * - 16 FROM tab2 AS cor0
----
-463
-475
-625

onlyif mysql # use DIV operator for integer division
query I rowsort label-5880
SELECT + col2 DIV - col0 + - ( col2 + 85 ) * col2 FROM tab2 AS cor0
----
-2886
-3027
-4674

skipif mysql # not compatible
query I rowsort label-5880
SELECT + col2 / - col0 + - ( col2 + 85 ) * col2 FROM tab2 AS cor0
----
-2886
-3027
-4674

query I rowsort
SELECT col2 + + col0 * 99 * - col0 FROM tab0 AS cor0
----
-121274
-56991
-784097

query I rowsort
SELECT ALL col2 * - tab2.col2 * col2 + + col1 FROM tab2
----
-17517
-19652
-54855

onlyif mysql # use DIV operator for integer division
query I rowsort label-5883
SELECT DISTINCT - 59 + col0 DIV col2 + tab0.col1 AS col2 FROM tab0
----
27
33
73

skipif mysql # not compatible
query I rowsort label-5883
SELECT DISTINCT - 59 + col0 / col2 + tab0.col1 AS col2 FROM tab0
----
27
33
73

query I rowsort
SELECT ( 55 ) AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT - - col1 + ( col2 ) FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL 68 + + 50 AS col2 FROM tab0 AS cor0
----
118
118
118

query I rowsort
SELECT DISTINCT ( ( col0 ) ) * cor0.col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - + cor0.col1 + cor0.col0 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT ALL + col0 * - col2 - - col0 FROM tab2 cor0
----
-182
-1950
-2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5890
SELECT - CAST( NULL AS SIGNED ) * 84 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5890
SELECT - CAST ( NULL AS INTEGER ) * 84 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - cor0.col0 * col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL + + 75 * cor0.col1 FROM tab0 AS cor0
----
6450
6825
7275

query I rowsort
SELECT ALL - 54 AS col0 FROM tab1 cor0
----
-54
-54
-54

query I rowsort
SELECT ALL 43 FROM tab0, tab1 cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT ALL 45 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT + + cor0.col1 - col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col0 + + col1 * col1 * 42 FROM tab1 AS cor0
----
28389
4136
7018

query I rowsort
SELECT ALL + - col0 + + col0 * col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT DISTINCT + col0 * 19 AS col0 FROM tab2 cor0
----
133
1482
1501

query I rowsort
SELECT cor0.col2 - + col0 * + col0 FROM tab1 AS cor0
----
-4039
-6304
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-5901
SELECT ALL 25 * + col0 DIV col0 FROM tab2 AS cor0
----
25
25
25

skipif mysql # not compatible
query I rowsort label-5901
SELECT ALL 25 * + col0 / col0 FROM tab2 AS cor0
----
25
25
25

query I rowsort
SELECT DISTINCT + col1 * + col1 + col0 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5903
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - col0 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5903
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - col0 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ( - col1 ) * col0 - + col2 AS col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT - col2 + 25 FROM tab2
----
-1
-13
-2

query I rowsort
SELECT DISTINCT - col2 + - col0 AS col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + tab1.col0 + - col1 * col2 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT + col0 + + col1 * + col1 FROM tab0
----
7420
8370
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-5909
SELECT col1 + - col1 + - col0 DIV - col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5909
SELECT col1 + - col1 + - col0 / - col2 FROM tab0
----
0
1
35

query I rowsort
SELECT ALL + col0 + - col0 * - col2 FROM tab1
----
165
3712
7760

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col2 < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5912
SELECT ALL - col2 DIV col0 + col0 FROM tab1
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-5912
SELECT ALL - col2 / col0 + col0 FROM tab1
----
-15
64
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - tab2.col2 * - col0 col0 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-5914
SELECT DISTINCT + col0 DIV col2 + col1 FROM tab1
----
11
13
26

skipif mysql # not compatible
query I rowsort label-5914
SELECT DISTINCT + col0 / col2 + col1 FROM tab1
----
11
13
26

query I rowsort
SELECT + col2 - col1 * - col1 AS col0 FROM tab0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + tab2.col0 col2 FROM tab2
----
137
38
96

query I rowsort
SELECT col2 AS col2 FROM tab2 WHERE col1 / - col0 IN ( col0 + - col1 - - col2 )
----

query I rowsort
SELECT ALL - col1 FROM tab0 WHERE NOT NULL BETWEEN col0 AND NULL
----

query I rowsort
SELECT DISTINCT col1 * col1 AS col1 FROM tab1 WHERE NOT col1 < ( - col0 * col1 * col2 )
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col0 col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL col1 + col0 * - col1 FROM tab2
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-5922
SELECT - col1 - col1 DIV tab0.col0 AS col2 FROM tab0
----
-89
-92
-99

skipif mysql # not compatible
query I rowsort label-5922
SELECT - col1 - col1 / tab0.col0 AS col2 FROM tab0
----
-89
-92
-99

query I rowsort
SELECT DISTINCT + col0 + - col2 * tab1.col2 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT col0 * col0 + col0 * tab0.col0 FROM tab0
----
1152
15842
2450

query I rowsort
SELECT + col2 * - col2 + tab1.col1 * - col1 * tab1.col1 AS col0 FROM tab1
----
-11413
-20492
-4249

query I rowsort
SELECT ALL col1 * + col0 + tab2.col0 AS col0 FROM tab2
----
1422
224
4680

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NOT ( - col1 * col0 ) <> ( NULL )
----

query I rowsort
SELECT ALL cor0.col1 * cor0.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 4a2f25e7025075a0ce048be425c35957

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE ( + col1 + col2 * + col2 ) NOT BETWEEN ( col2 * + col0 * + col0 ) AND col1
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 col2 FROM tab1
----
-4096
-6400
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * - cor0.col1 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT tab1.col0 FROM tab2, tab1 cor0 CROSS JOIN tab1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT col2 * col0 + + tab1.col0 AS col2 FROM tab1
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5934
SELECT DISTINCT - tab2.col0 + col2 DIV + col1 FROM tab2
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-5934
SELECT DISTINCT - tab2.col0 + col2 / + col1 FROM tab2
----
-7
-77
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5935
SELECT + col1 + col0 DIV col0 AS col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5935
SELECT + col1 + col0 / col0 AS col1 FROM tab1
----
11
14
27

query I rowsort
SELECT ALL col0 * - col1 * col0 + + col0 FROM tab1 cor0
----
-231
-40896
-83120

query I rowsort
SELECT ALL col1 + + col2 + + col0 * + col2 AS col2 FROM tab2 AS cor0
----
2113
247
3057

query I rowsort
SELECT ALL + col0 + - col2 * col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT - col2 + + col2 * + col1 AS col2 FROM tab0
----
2805
7380
96

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE ( - col1 * col1 ) NOT IN ( - cor0.col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - cor0.col2 + - col0 AS col1 FROM tab1 AS cor0 WHERE ( col1 ) > cor0.col1
----

query I rowsort
SELECT ALL + col2 + col0 * col1 AS col1 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT - col1 * + col0 + - col1 * col1 AS col1 FROM tab0 AS cor0
----
-12804
-16380
-9460

query I rowsort
SELECT DISTINCT col1 * - col2 - col1 * - cor0.col2 FROM tab0 cor0
----
0

query I rowsort
SELECT + col0 * - ( + col2 ) + cor0.col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT col1 * 84 * - col1 AS col2 FROM tab2 cor0
----
-24276
-292404
-80724

query I rowsort
SELECT - + col0 * 15 + + 32 FROM tab2 AS cor0
----
-1138
-1153
-73

query I rowsort
SELECT 35 * - 63 + + col2 FROM tab1 AS cor0
----
-2109
-2148
-2151

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5949
SELECT - CAST( - 20 AS SIGNED ) FROM tab0 cor0
----
20
20
20

skipif mysql # not compatible
query I rowsort label-5949
SELECT - CAST ( - 20 AS INTEGER ) FROM tab0 cor0
----
20
20
20

query I rowsort
SELECT ALL - + col2 + + col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + 25 * col2 + cor0.col1 * cor0.col1 AS col1 FROM tab0 AS cor0
----
10331
8221
9434

onlyif mysql # use DIV operator for integer division
query I rowsort label-5952
SELECT + cor0.col1 * cor0.col1 + - col1 DIV col0 FROM tab2 AS cor0
----
289
3481
957

skipif mysql # not compatible
query I rowsort label-5952
SELECT + cor0.col1 * cor0.col1 + - col1 / col0 FROM tab2 AS cor0
----
289
3481
957

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + + col0 col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + 75 * + col1 * 32 AS col1 FROM tab1 AS cor0
----
24000
31200
62400

query I rowsort
SELECT + + 21 * - col0 + + ( + col2 ) FROM tab1 AS cor0
----
-1287
-1584
-9

query I rowsort
SELECT 16 AS col0 FROM tab2 AS cor0
----
16
16
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-5957
SELECT - col0 + + col0 * col2 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
-1
-44
97

skipif mysql # not compatible
query I rowsort label-5957
SELECT - col0 + + col0 * col2 / cor0.col1 AS col1 FROM tab2 AS cor0
----
-1
-44
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5958
SELECT + col0 * - col0 + 95 DIV - col2 FROM tab0 AS cor0
----
-1320
-578
-7922

skipif mysql # not compatible
query I rowsort label-5958
SELECT + col0 * - col0 + 95 / - col2 FROM tab0 AS cor0
----
-1320
-578
-7922

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5959
SELECT col0 + CAST( ( col1 ) AS SIGNED ) * + col2 col2 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5959
SELECT col0 + CAST ( ( col1 ) AS INTEGER ) * + col2 col2 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-5960
SELECT DISTINCT - + col0 + 8 DIV ( col1 * - col0 ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5960
SELECT DISTINCT - + col0 + 8 / ( col1 * - col0 ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT cor0.col0 * cor0.col2 + col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - 30 col2 FROM tab0 AS cor0
----
-119
-54
-65

query I rowsort
SELECT DISTINCT + ( col1 ) * + col0 * - 81 AS col1 FROM tab0
----
-167184
-274995
-656019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5964
SELECT CAST( NULL AS SIGNED ) + 72 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5964
SELECT CAST ( NULL AS INTEGER ) + 72 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5965
SELECT + ( col0 ) DIV + 12 FROM tab1
----
0
5
6

skipif mysql # not compatible
query I rowsort label-5965
SELECT + ( col0 ) / + 12 FROM tab1
----
0
5
6

query I rowsort
SELECT ALL - col2 * - col0 + - col1 * col0 * cor0.col1 FROM tab2 AS cor0
----
-19829
-269490
-6538

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * - col1 + col2 col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
54
57
96

query I rowsort
SELECT DISTINCT + + col1 + + col1 * - col2 * + col0 FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT ALL cor0.col2 * cor0.col1 AS col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - 91 AS col1 FROM tab0, tab1 AS cor0
----
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5972
SELECT ALL - - CAST( col2 AS SIGNED ) + col1 * col1 FROM tab2 AS cor0
----
327
3507
988

skipif mysql # not compatible
query I rowsort label-5972
SELECT ALL - - CAST ( col2 AS INTEGER ) + col1 * col1 FROM tab2 AS cor0
----
327
3507
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-5973
SELECT 46 * 23 + col2 DIV - col1 FROM tab1 AS cor0
----
1051
1053
1056

skipif mysql # not compatible
query I rowsort label-5973
SELECT 46 * 23 + col2 / - col1 FROM tab1 AS cor0
----
1051
1053
1056

query I rowsort
SELECT DISTINCT - - ( + 52 ) * - col0 AS col1 FROM tab1 AS cor0
----
-156
-3328
-4160

query I rowsort
SELECT ALL + 98 + + 72 * + col1 AS col1 FROM tab1 cor0
----
1034
1970
818

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5976
SELECT DISTINCT CAST( NULL AS SIGNED ) + col1 + col0 AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5976
SELECT DISTINCT CAST ( NULL AS INTEGER ) + col1 + col0 AS col0 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5977
SELECT ALL + col2 + col2 DIV + col0 + tab0.col2 AS col1 FROM tab0
----
164
2
67

skipif mysql # not compatible
query I rowsort label-5977
SELECT ALL + col2 + col2 / + col0 + tab0.col2 AS col1 FROM tab0
----
164
2
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5978
SELECT ALL + CAST( NULL AS SIGNED ) - 55 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5978
SELECT ALL + CAST ( NULL AS INTEGER ) - 55 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5979
SELECT - 1 DIV col1 + cor0.col0 * col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-5979
SELECT - 1 / col1 + cor0.col0 * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col0 + - ( col1 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL cor0.col0 * col2 + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL - col0 + 8 AS col2 FROM tab1 AS cor0
----
-56
-72
5

query I rowsort
SELECT - ( - cor0.col1 ) * col0 + col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT + 41 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5985
SELECT ALL - CAST( NULL AS SIGNED ) + - 30 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5985
SELECT ALL - CAST ( NULL AS INTEGER ) + - 30 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - 88 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
-88

query I rowsort
SELECT + col1 - col0 * col2 AS col2 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT - 17 + col1 FROM tab1
----
-4
-7
9

query I rowsort
SELECT DISTINCT - ( tab1.col2 ) AS col1 FROM tab1, tab2, tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - col2 - 29 FROM tab2 AS cor0
----
-55
-56
-67

query I rowsort
SELECT - tab2.col1 + + ( + col2 + col0 ) FROM tab2
----
100
3
45

query I rowsort
SELECT - col1 * 54 AS col1 FROM tab1 AS cor0
----
-1404
-540
-702

query I rowsort
SELECT ALL cor0.col2 + + 87 - + col0 * - col1 FROM tab0 cor0
----
2184
3483
8268

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * 60 * + cor0.col0 + col2 col2 FROM tab0 AS cor0
----
2101
437962
47553

query I rowsort
SELECT DISTINCT + col0 + ( - col2 ) * col0 AS col1 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + - col1 + col2 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-5997
SELECT DISTINCT - col1 DIV col0 + ( col0 ) * - col2 * - cor0.col2 - + cor0.col1 * col1 AS col2 FROM tab1 cor0
----
207836
737111
8064

skipif mysql # not compatible
query I rowsort label-5997
SELECT DISTINCT - col1 / col0 + ( col0 ) * - col2 * - cor0.col2 - + cor0.col1 * col1 AS col2 FROM tab1 cor0
----
207836
737111
8064

query I rowsort
SELECT DISTINCT - - col2 + + 81 * ( - col0 + + col2 ) FROM tab0 AS cor0
----
-2753
-485
762

query I rowsort
SELECT ALL - + col2 * + col0 AS col2 FROM tab0 cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - 19 col1 FROM tab1 AS cor0
----
-6
-9
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6001
SELECT DISTINCT col2 / CAST( NULL AS SIGNED ) - col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6001
SELECT DISTINCT col2 / CAST ( NULL AS INTEGER ) - col2 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col2 * - ( 42 ) + col2 FROM tab0 AS cor0
----
-1353
-3362
-41

query I rowsort
SELECT ALL col1 + tab0.col1 * col1 * - col1 FROM tab0
----
-635970
-753480
-912576

query I rowsort
SELECT ALL col2 * col0 + + tab2.col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT ALL - col2 + col0 * col0 AS col0 FROM tab0
----
1224
543
7839

query I rowsort
SELECT ALL col0 + col2 * tab0.col1 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL + - col1 + col1 * + col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT ALL + + cor0.col2 FROM tab0 cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6009
SELECT DISTINCT + + col0 + col2 DIV col0 AS col2 FROM tab2 AS cor0
----
10
78
79

skipif mysql # not compatible
query I rowsort label-6009
SELECT DISTINCT + + col0 + col2 / col0 AS col2 FROM tab2 AS cor0
----
10
78
79

query I rowsort
SELECT ALL - cor0.col2 - + col1 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6011
SELECT + col1 + + col2 DIV - col0 col2 FROM tab1 AS cor0
----
10
12
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6011
SELECT + col1 + + col2 / - col0 col2 FROM tab1 AS cor0
----
10
12
8

query I rowsort
SELECT DISTINCT + cor0.col2 + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL col0 * col2 + col0 * col2 AS col2 FROM tab0 AS cor0
----
14596
1584
70

query I rowsort
SELECT DISTINCT col2 - col2 * col1 * col2 FROM tab2
----
-22572
-24510
-39858

onlyif mysql # use DIV operator for integer division
query I rowsort label-6015
SELECT + col1 + + col1 + - col0 DIV - tab1.col1 col1 FROM tab1
----
26
32
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6015
SELECT + col1 + + col1 + - col0 / - tab1.col1 col1 FROM tab1
----
26
32
52

query I rowsort
SELECT DISTINCT + col2 + col1 * + col1 * + col0 FROM tab2
----
22869
271544
6754

query I rowsort
SELECT DISTINCT - col1 + tab1.col0 AS col2 FROM tab1
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col1 - - col1 * cor0.col0 col2 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT - ( - col0 ) * col2 * col0 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT + - cor0.col0 * + col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT 3 AS col2 FROM tab1 AS cor0
----
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6022
SELECT ALL col2 + col0 DIV + col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6022
SELECT ALL col2 + col0 / + col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL 91 * - tab0.col2 FROM tab0
----
-3003
-7462
-91

query I rowsort
SELECT 73 + + col2 * col1 FROM tab2 cor0
----
1607
719
910

onlyif mysql # use DIV operator for integer division
query I rowsort label-6025
SELECT DISTINCT - 26 DIV cor0.col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-6025
SELECT DISTINCT - 26 / cor0.col0 FROM tab2 AS cor0
----
-3
0

query I rowsort
SELECT DISTINCT - - 3 * col1 + cor0.col0 FROM tab1 AS cor0
----
119
81
94

query I rowsort
SELECT ALL - - 20 + + cor0.col2 FROM tab1 AS cor0
----
116
74
77

query I rowsort
SELECT ( col2 ) + col0 AS col0 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col2 ) - - col2 col1 FROM tab0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-6030
SELECT DISTINCT + 39 + col0 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
40

skipif mysql # not compatible
query I rowsort label-6030
SELECT DISTINCT + 39 + col0 / cor0.col0 AS col2 FROM tab2 AS cor0
----
40

query I rowsort
SELECT ALL ( col0 ) + + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - 42 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-3612
-3822
-4074

query I rowsort
SELECT 93 + - cor0.col2 * col0 FROM tab2 AS cor0
----
-1935
-2909
-96

query I rowsort
SELECT DISTINCT col2 * col1 AS col1 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6035
SELECT DISTINCT - - col2 * + col0 DIV - col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-6035
SELECT DISTINCT - - col2 * + col0 / - col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT col0 * + col0 + - col0 AS col2 FROM tab2 AS cor0
----
42
6006
6162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 65 col0 FROM tab1 AS cor0
----
-65
-65
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col1 ) col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - 80 * - col2 + - col1 * + tab2.col0 AS col2 FROM tab2
----
-2522
1697
1943

query I rowsort
SELECT DISTINCT - col0 * col1 + col1 FROM tab2 cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-6041
SELECT ALL col0 DIV - col0 AS col2 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6041
SELECT ALL col0 / - col0 AS col2 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT ALL + ( + col2 ) * col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT - col2 * - tab0.col2 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT col1 * + tab1.col1 AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT + cor0.col2 + col0 * cor0.col1 + 24 AS col2 FROM tab0 cor0
----
2121
3420
8205

query I rowsort
SELECT - col0 + col2 + ( 15 ) AS col2 FROM tab2 AS cor0
----
-26
-37
35

query I rowsort
SELECT + - cor0.col0 * + col0 + 77 FROM tab0 AS cor0
----
-1148
-499
-7844

query I rowsort
SELECT + + col0 * - 18 AS col2 FROM tab1 cor0
----
-1152
-1440
-54

query I rowsort
SELECT - + col0 + ( + 29 ) * col1 FROM tab1 cor0
----
226
297
751

query I rowsort
SELECT - - cor0.col2 + 97 * + col0 AS col1 FROM tab1 cor0
----
345
6265
7856

query I rowsort
SELECT + + 20 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT DISTINCT 83 * + col0 FROM tab1
----
249
5312
6640

onlyif mysql # use DIV operator for integer division
query I rowsort label-6053
SELECT - ( col2 ) DIV col1 + + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6053
SELECT - ( col2 ) / col1 + + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT 51 + col1 AS col0 FROM tab1 AS cor0
----
61
64
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 19 + cor0.col0 * cor0.col0 + - cor0.col2 col1 FROM tab2 AS cor0
----
3
6039
6184

query I rowsort
SELECT + - ( 51 ) + col1 AS col1 FROM tab0 AS cor0
----
35
40
46

query I rowsort
SELECT DISTINCT + - col1 * - col1 AS col1 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT - col1 * - 11 + + col1 AS col1 FROM tab1 AS cor0
----
120
156
312

onlyif mysql # use DIV operator for integer division
query I rowsort label-6059
SELECT ALL 77 DIV - col0 + - cor0.col0 FROM tab0 AS cor0
----
-27
-37
-89

skipif mysql # not compatible
query I rowsort label-6059
SELECT ALL 77 / - col0 + - cor0.col0 FROM tab0 AS cor0
----
-27
-37
-89

query I rowsort
SELECT DISTINCT - ( + col1 ) * - cor0.col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + col1 * + ( 73 ) + col1 * col0 FROM tab0
----
10476
14742
8342

query I rowsort
SELECT DISTINCT + col2 * col0 + - col1 AS col0 FROM tab1
----
136
3638
7667

query I rowsort
SELECT - 46 * - ( col1 * - 57 ) FROM tab2 AS cor0
----
-154698
-44574
-81282

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6064
SELECT CAST( - col1 AS SIGNED ) + col0 * col0 FROM tab0 AS cor0
----
1128
490
7830

skipif mysql # not compatible
query I rowsort label-6064
SELECT CAST ( - col1 AS INTEGER ) + col0 * col0 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT + + col0 - + col0 * col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL - col2 * + 49 * col0 AS col1 FROM tab1
----
-178752
-376320
-7938

query I rowsort
SELECT DISTINCT + cor1.col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT - cor0.col0 * - col0 + ( cor0.col1 ) + col2 FROM tab1 AS cor0
----
4163
6509
89

query I rowsort
SELECT ALL - 90 * - col1 FROM tab2 cor0
----
1530
2790
5310

query I rowsort
SELECT ALL - 31 * - cor0.col0 + 25 * - ( col0 ) AS col0 FROM tab1 cor0
----
18
384
480

query I rowsort
SELECT ALL 88 * - col2 AS col1 FROM tab0 AS cor0
----
-2904
-7216
-88

query I rowsort
SELECT DISTINCT - 95 * col0 FROM tab2 AS cor0
----
-665
-7410
-7505

query I rowsort
SELECT DISTINCT + 95 + + col1 * + col1 AS col2 FROM tab2 AS cor0
----
1056
3576
384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 - col0 col1 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6075
SELECT + cor0.col2 * col0 - col2 DIV col1 FROM tab2 AS cor0
----
189
2028
3000

skipif mysql # not compatible
query I rowsort label-6075
SELECT + cor0.col2 * col0 - col2 / col1 FROM tab2 AS cor0
----
189
2028
3000

query I rowsort
SELECT ALL - cor0.col1 * cor0.col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + - cor0.col2 * col1 * ( - cor0.col2 ) FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT 31 - 99 FROM tab1
----
-68

query I rowsort
SELECT ALL col1 + col0 * - col2 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT ALL 78 AS col2 FROM tab1
----
78
78
78

query I rowsort
SELECT - - cor0.col1 + col0 AS col2 FROM tab0 cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( - col2 ) col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - + ( col1 ) * col2 + + 75 + col2 AS col2 FROM tab2 AS cor0
----
-1433
-533
-735

query I rowsort
SELECT DISTINCT + col2 * tab1.col2 + tab1.col1 - - col1 FROM tab1
----
2968
3269
9242

query I rowsort
SELECT + ( 8 ) FROM tab0 AS cor0
----
8
8
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6086
SELECT CAST( - 89 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-89
-89
-89

skipif mysql # not compatible
query I rowsort label-6086
SELECT CAST ( - 89 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-89
-89
-89

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + tab1.col2 * col2 + - col0 * + col1 - 29 FROM tab1
----
2580
2809
8147

query I rowsort
SELECT ALL - tab2.col0 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT - tab1.col1 - 81 AS col1 FROM tab1
----
-107
-91
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6091
SELECT + tab2.col0 + - 36 * + col0 + - CAST( NULL AS SIGNED ) * col1 * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6091
SELECT + tab2.col0 + - 36 * + col0 + - CAST ( NULL AS INTEGER ) * col1 * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 15 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT ALL - col0 + - 43 FROM tab2 AS cor0
----
-121
-122
-50

query I rowsort
SELECT ALL + col2 * - col1 + col2 + cor0.col2 * + cor0.col0 FROM tab1 AS cor0
----
-1188
3135
6528

query I rowsort
SELECT ALL col0 * + ( col2 ) - col1 FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-6096
SELECT DISTINCT + - col2 + - col1 DIV cor0.col1 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-6096
SELECT DISTINCT + - col2 + - col1 / cor0.col1 FROM tab1 AS cor0
----
-55
-58
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6097
SELECT DISTINCT - col1 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6097
SELECT DISTINCT - col1 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col2 * + col2 * + col2 + - col0 AS col1 FROM tab0 AS cor0
----
-34
35913
551279

query I rowsort
SELECT DISTINCT - col1 + - ( + col0 ) * - col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - ( + 57 ) FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT col0 + + 8 * tab2.col0 AS col2 FROM tab2
----
63
702
711

onlyif mysql # use DIV operator for integer division
query I rowsort label-6102
SELECT ALL + col2 DIV - ( - 43 ) FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6102
SELECT ALL + col2 / - ( - 43 ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + col0 * col2 + ( + col1 ) - col1 * + col2 AS col2 FROM tab0 cor0
----
-1960
-73
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6104
SELECT ALL + col1 * + CAST( - col2 AS SIGNED ) + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort label-6104
SELECT ALL + col1 * + CAST ( - col2 AS INTEGER ) + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT + col1 * col0 * - col1 AS col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT - col0 + - col1 * col2 FROM tab1 cor0
----
-1328
-1407
-634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - ( - 82 ) * cor0.col0 col1 FROM tab0 AS cor0
----
1882
2773
7207

query I rowsort
SELECT DISTINCT + col0 * 43 FROM tab0 AS cor0
----
1032
1505
3827

onlyif mysql # use DIV operator for integer division
query I rowsort label-6109
SELECT DISTINCT col1 + col2 DIV col2 FROM tab0 cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-6109
SELECT DISTINCT col1 + col2 / col2 FROM tab0 cor0
----
87
92
98

query I rowsort
SELECT + + col0 - + cor0.col1 * + 72 FROM tab2 AS cor0
----
-1145
-2225
-4170

query I rowsort
SELECT ALL - ( col1 ) * col0 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6112
SELECT + ( cor0.col0 ) * col0 + + CAST( 23 AS SIGNED ) * - col1 AS col2 FROM tab1 AS cor0
----
-589
3866
6101

skipif mysql # not compatible
query I rowsort label-6112
SELECT + ( cor0.col0 ) * col0 + + CAST ( 23 AS INTEGER ) * - col1 AS col2 FROM tab1 AS cor0
----
-589
3866
6101

onlyif mysql # use DIV operator for integer division
query I rowsort label-6113
SELECT ALL - 61 DIV + col0 - col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-46

skipif mysql # not compatible
query I rowsort label-6113
SELECT ALL - 61 / + col0 - col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-46

query I rowsort
SELECT ALL - - 25 * col0 FROM tab1 AS cor0
----
1600
2000
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6115
SELECT - ( col0 ) / col2 + + 23 * col0 + col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6115
SELECT - ( col0 ) / col2 + + 23 * col0 + col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 92 * - col2 - col2 FROM tab1 AS cor0
----
4914
5187
8736

onlyif mysql # use DIV operator for integer division
query I rowsort label-6117
SELECT - + 54 * - 69 + col1 * 11 DIV 35 AS col2 FROM tab0 AS cor0
----
3753
3754
3756

skipif mysql # not compatible
query I rowsort label-6117
SELECT - + 54 * - 69 + col1 * 11 / 35 AS col2 FROM tab0 AS cor0
----
3753
3754
3756

query I rowsort
SELECT DISTINCT - ( 47 ) + - col1 AS col0 FROM tab2 AS cor0
----
-106
-64
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6119
SELECT ALL - col2 + + CAST( NULL AS DECIMAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6119
SELECT ALL - col2 + + CAST ( NULL AS REAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 41 FROM tab0 cor0
----
-41

query I rowsort
SELECT DISTINCT + - col2 + + col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * ( + 39 ) col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 3a348112fdd91fe2b3539c63b529c830

query I rowsort
SELECT ALL + - col1 + - col2 + + ( ( cor0.col2 ) + + ( 9 ) ) AS col1 FROM tab0 AS cor0
----
-77
-82
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) * - col1 col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL 50 AS col2 FROM tab2 AS cor0
----
50
50
50

query I rowsort
SELECT ( 41 * col2 ) AS col0 FROM tab1
----
2214
2337
3936

onlyif mysql # use DIV operator for integer division
query I rowsort label-6127
SELECT col0 DIV col0 + - col2 FROM tab2
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-6127
SELECT col0 / col0 + - col2 FROM tab2
----
-25
-26
-37

query I rowsort
SELECT DISTINCT 84 AS col1 FROM tab1
----
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 9 * col1 col0 FROM tab2
----
153
279
531

onlyif mysql # use DIV operator for integer division
query I rowsort label-6130
SELECT DISTINCT ( col0 ) DIV col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-6130
SELECT DISTINCT ( col0 ) / col1 AS col0 FROM tab0
----
0

query I rowsort
SELECT col0 + col1 * - col1 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT - tab0.col1 AS col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL + col1 * + 49 AS col0 FROM tab2
----
1519
2891
833

query I rowsort
SELECT DISTINCT + - cor0.col2 * + col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - col2 * ( col0 ) + + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT + 49 AS col1 FROM tab2, tab1 AS cor0
----
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * cor0.col2 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to e1120e7b687b32270ef70393236e7341

query I rowsort
SELECT - ( - cor0.col0 ) + + cor0.col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - col2 * col0 + + col2 * - 6 * - 13 AS col2 FROM tab1 AS cor0
----
-192
4050
798

query I rowsort
SELECT + col0 * col2 + col1 AS col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL - 39 AS col1 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to fe3460a5258986a2d83e1ea75c1e275e

query I rowsort
SELECT + col0 + + tab0.col1 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT - cor0.col2 * - col0 - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT - 62 * col2 FROM tab1 AS cor0
----
-3348
-3534
-5952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6145
SELECT ALL 63 * col1 + + CAST( col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1150
1960
3795

skipif mysql # not compatible
query I rowsort label-6145
SELECT ALL 63 * col1 + + CAST ( col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1150
1960
3795

onlyif mysql # use DIV operator for integer division
query I rowsort label-6146
SELECT DISTINCT - 57 * col2 + 68 DIV - col0 FROM tab1 AS cor0
----
-3100
-3250
-5472

skipif mysql # not compatible
query I rowsort label-6146
SELECT DISTINCT - 57 * col2 + 68 / - col0 FROM tab1 AS cor0
----
-3100
-3250
-5472

query I rowsort
SELECT 14 * col1 FROM tab2 AS cor0
----
238
434
826

query I rowsort
SELECT ALL + - 29 + - col0 * ( + cor0.col1 ) FROM tab1 AS cor0
----
-1069
-107
-669

onlyif mysql # use DIV operator for integer division
query I rowsort label-6149
SELECT + col1 * cor0.col2 + 47 DIV col0 col0 FROM tab1 cor0
----
1248
1419
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6149
SELECT + col1 * cor0.col2 + 47 / col0 col0 FROM tab1 cor0
----
1248
1419
570

query I rowsort
SELECT ALL col1 * col0 * col1 + + 65 + col0 * col2 AS col0 FROM tab2 AS cor0
----
25898
273611
6981

query I rowsort
SELECT ALL - col1 * col2 + - ( - col0 * col1 ) AS col2 FROM tab1 AS cor0
----
-1326
-208
70

query I rowsort
SELECT ALL 39 * col2 + 91 FROM tab1 AS cor0
----
2197
2314
3835

query I rowsort
SELECT - + col0 * - cor0.col2 + - col0 * col1 AS col0 FROM tab1 cor0
----
3008
6640
84

query I rowsort
SELECT DISTINCT 89 FROM tab0, tab2 AS cor0
----
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6155
SELECT + col0 * 67 DIV col0 FROM tab1
----
67
67
67

skipif mysql # not compatible
query I rowsort label-6155
SELECT + col0 * 67 / col0 FROM tab1
----
67
67
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6156
SELECT - col2 + - CAST( - 72 AS SIGNED ) * cor0.col0 * col2 FROM tab0 AS cor0
----
2519
525374
56991

skipif mysql # not compatible
query I rowsort label-6156
SELECT - col2 + - CAST ( - 72 AS INTEGER ) * cor0.col0 * col2 FROM tab0 AS cor0
----
2519
525374
56991

query I rowsort
SELECT col1 + 82 * cor0.col1 FROM tab0 AS cor0
----
7138
7553
8051

query I rowsort
SELECT DISTINCT col1 * 76 FROM tab0
----
6536
6916
7372

query I rowsort
SELECT + col0 * 86 + col2 FROM tab2 AS cor0
----
629
6734
6832

query I rowsort
SELECT + - col0 * - col1 + cor0.col2 AS col0 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT + + ( + 31 ) + col1 FROM tab1 cor0
----
41
44
57

query I rowsort
SELECT col2 * cor0.col2 + - col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT 27 + col0 * - cor0.col1 FROM tab1 cor0
----
-1013
-51
-613

query I rowsort
SELECT - - 86 * - col1 * col1 AS col0 FROM tab1 AS cor0
----
-14534
-58136
-8600

onlyif mysql # use DIV operator for integer division
query I rowsort label-6165
SELECT cor0.col2 * col1 DIV 11 AS col0 FROM tab0 AS cor0
----
258
678
8

skipif mysql # not compatible
query I rowsort label-6165
SELECT cor0.col2 * col1 / 11 AS col0 FROM tab0 AS cor0
----
258
678
8

query I rowsort
SELECT + cor0.col2 * + col0 + 54 FROM tab0 AS cor0
----
7352
846
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 0 + - tab0.col2 * + col0 col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - col1 * 24 AS col2 FROM tab0 AS cor0
----
-2064
-2184
-2328

query I rowsort
SELECT - col2 * 6 AS col2 FROM tab2 AS cor0
----
-156
-162
-228

onlyif mysql # use DIV operator for integer division
query I rowsort label-6170
SELECT col1 + cor0.col2 DIV col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6170
SELECT col1 + cor0.col2 / col2 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ALL - col1 * + col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - - col0 * + 1 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + - col1 * - 27 + + 28 + col2 FROM tab2 AS cor0
----
1647
525
892

onlyif mysql # use DIV operator for integer division
query I rowsort label-6174
SELECT cor0.col2 DIV ( 95 + col2 ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6174
SELECT cor0.col2 / ( 95 + col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ( - col1 ) - cor0.col0 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT ALL 19 FROM tab1, tab2 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT - ( + 53 ) - col0 AS col2 FROM tab0 AS cor0
----
-142
-77
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6178
SELECT ALL tab1.col2 DIV tab1.col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6178
SELECT ALL tab1.col2 / tab1.col0 FROM tab1
----
0
1
18

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 cor2
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

onlyif mysql # use DIV operator for integer division
query I rowsort label-6180
SELECT 19 DIV col0 FROM tab2 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6180
SELECT 19 / col0 FROM tab2 cor0
----
0
0
2

query I rowsort
SELECT DISTINCT + 91 * - cor0.col1 FROM tab1 AS cor0
----
-1183
-2366
-910

query I rowsort
SELECT + cor0.col1 + - 39 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to f4eb5a1036e5bd9f1cbd8ed824f35cab

query I rowsort
SELECT DISTINCT - 63 FROM tab1, tab2 AS cor0
----
-63

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + 83 AS col0 FROM tab2
----
83
83
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6186
SELECT DISTINCT + 64 DIV col2 AS col0 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-6186
SELECT DISTINCT + 64 / col2 AS col0 FROM tab1 AS cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6187
SELECT ALL + - CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6187
SELECT ALL + - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + + cor0.col0 * + col0 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT - col1 + col2 * col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT ALL + 83 AS col0 FROM tab2 cor0
----
83
83
83

query I rowsort
SELECT DISTINCT - + cor0.col2 AS col2 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT + + 11 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
286
297
418

query I rowsort
SELECT ALL col2 * + ( col0 ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort
SELECT ALL cor0.col2 + col2 * CAST ( + ( - col2 ) AS REAL ) AS col2 FROM tab0 cor0
----
-1056
-6642
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * + col0 + + ( col0 ) * + col2 col1 FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT - + 24 FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT DISTINCT ( - col1 + col1 ) * col2 AS col0 FROM tab0
----
0

query I rowsort
SELECT ALL ( col2 ) * + col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 7 + col0 * col1 + cor0.col0 FROM tab0 AS cor0
----
2095
3437
8195

query I rowsort
SELECT ALL + + col1 * cor0.col1 AS col0 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - cor0.col0 * cor0.col0 + 19 AS col0 FROM tab1 AS cor0
----
-4077
-6381
10

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab0 cor1, tab2, tab0 AS cor2
----
3645 values hashing to 4fa4bd3038de6e74a345debc8ab4cd53

query I rowsort
SELECT + - ( - col1 ) * + col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL 81 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) + col2 * 40 FROM tab0 AS cor0
----
1296
3191
5

query I rowsort
SELECT DISTINCT col0 + ( + col0 ) * + col0 FROM tab0 cor0
----
1260
600
8010

query I rowsort
SELECT + cor0.col2 * col2 + col0 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - + cor0.col0 + col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col0 * + col1 + - ( col0 ) AS col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT col0 * + 11 * + col2 AS col0 FROM tab0
----
385
80278
8712

onlyif mysql # use DIV operator for integer division
query I rowsort label-6211
SELECT + col1 + + col2 DIV - cor0.col0 AS col1 FROM tab2 AS cor0
----
17
28
59

skipif mysql # not compatible
query I rowsort label-6211
SELECT + col1 + + col2 / - cor0.col0 AS col1 FROM tab2 AS cor0
----
17
28
59

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 * CAST ( - ( col0 ) + - col2 AS REAL ) AS col0 FROM tab1 AS cor0
----
1210
1482
2288

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab2, tab1 cor1
----
972 values hashing to 9364ef7545b07c67767dceb70f02c643

query I rowsort
SELECT DISTINCT + ( col0 ) + + col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT ALL 77 * - col2 + col1 FROM tab0 AS cor0
----
-2455
-6223
20

query I rowsort
SELECT ALL + + col2 * cor0.col0 * col0 + col1 + - 5 * col0 AS col1 FROM tab1 AS cor0
----
233162
497
614013

query I rowsort
SELECT DISTINCT 68 FROM tab0, tab1 AS cor0, tab0 cor1
----
68

query I rowsort
SELECT ALL 25 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

query I rowsort
SELECT DISTINCT ( - col1 ) * cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6220
SELECT ALL 71 + col0 DIV col0 AS col1 FROM tab0 AS cor0
----
72
72
72

skipif mysql # not compatible
query I rowsort label-6220
SELECT ALL 71 + col0 / col0 AS col1 FROM tab0 AS cor0
----
72
72
72

query I rowsort
SELECT - col0 * - 29 AS col2 FROM tab2 AS cor0
----
203
2262
2291

query I rowsort
SELECT ALL + + col2 - cor0.col1 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 93 col0 FROM tab2 cor0
----
119
120
131

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 36 col0 FROM tab1 AS cor0
----
36

query I rowsort
SELECT DISTINCT - ( col0 ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6226
SELECT ALL col2 DIV - 22 + col2 FROM tab1 AS cor0
----
52
55
92

skipif mysql # not compatible
query I rowsort label-6226
SELECT ALL col2 / - 22 + col2 FROM tab1 AS cor0
----
52
55
92

query I rowsort
SELECT ALL - ( 14 ) - col2 * - 59 * + col0 AS col1 FROM tab2 AS cor0
----
11137
119638
177104

onlyif mysql # use DIV operator for integer division
query I rowsort label-6228
SELECT ALL - tab2.col0 DIV ( - col1 ) FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6228
SELECT ALL - tab2.col0 / ( - col1 ) FROM tab2
----
0
1
4

query I rowsort
SELECT - col1 + - ( + col2 ) FROM tab0
----
-119
-173
-98

query I rowsort
SELECT ALL 52 FROM tab0, tab1 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT DISTINCT + 1 + col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
50
6085
6242

query I rowsort
SELECT 30 * + col0 AS col1 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT ALL + 64 AS col2 FROM tab0 AS cor0
----
64
64
64

query I rowsort
SELECT DISTINCT col1 * - cor0.col1 * - col1 FROM tab1 cor0
----
1000
17576
2197

onlyif mysql # use DIV operator for integer division
query I rowsort label-6235
SELECT - col0 * - 25 + - 47 DIV + col0 AS col0 FROM tab2
----
169
1950
1975

skipif mysql # not compatible
query I rowsort label-6235
SELECT - col0 * - 25 + - 47 / + col0 AS col0 FROM tab2
----
169
1950
1975

query I rowsort
SELECT + cor2.col1 + 94 FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 1adcec6472628e531e73f481a2e07769

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col1 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * - 40 * col1 + + col2 AS col2 FROM tab0
----
-295807
-331158
-376359

query I rowsort
SELECT 56 + ( col1 ) * + col2 FROM tab2
----
1590
702
893

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col0 col2 FROM tab0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + 30 + - col1 ) * col0 col1 FROM tab1
----
12
1280
1360

query I rowsort
SELECT - tab2.col1 * ( col0 ) + col0 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT 94 + + tab1.col2 - + col0 FROM tab1
----
110
145
87

query I rowsort
SELECT DISTINCT + 59 - - tab2.col0 * col1 AS col2 FROM tab2
----
1402
276
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-6245
SELECT - col2 + - col0 DIV - 73 AS col2 FROM tab2
----
-25
-27
-37

skipif mysql # not compatible
query I rowsort label-6245
SELECT - col2 + - col0 / - 73 AS col2 FROM tab2
----
-25
-27
-37

query I rowsort
SELECT + cor0.col1 - cor0.col1 * ( - cor0.col0 ) FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6247
SELECT col0 + - CAST( + 27 AS SIGNED ) * + col0 col2 FROM tab1 AS cor0
----
-1664
-2080
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6247
SELECT col0 + - CAST ( + 27 AS INTEGER ) * + col0 col2 FROM tab1 AS cor0
----
-1664
-2080
-78

query I rowsort
SELECT ALL col0 + - col0 * col1 AS col2 FROM tab0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-6249
SELECT tab1.col2 * col0 DIV tab1.col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6249
SELECT tab1.col2 * col0 / tab1.col0 FROM tab1
----
54
57
96

query I rowsort
SELECT + 57 * col2 * col2 FROM tab2
----
38532
41553
82308

query I rowsort
SELECT ALL col0 * 96 FROM tab1
----
288
6144
7680

query I rowsort
SELECT DISTINCT - col0 * + cor0.col0 + 34 FROM tab0 cor0
----
-1191
-542
-7887

query I rowsort
SELECT DISTINCT - cor0.col2 * ( col0 ) + col0 FROM tab2 cor0
----
-182
-1950
-2923

query I rowsort
SELECT - col1 * + 42 AS col1 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT DISTINCT col0 * col2 * - 52 FROM tab1 AS cor0
----
-189696
-399360
-8424

query I rowsort
SELECT ALL + col1 * 4 + 65 AS col0 FROM tab2 AS cor0
----
133
189
301

query I rowsort
SELECT ALL + - cor0.col0 + - ( - col1 ) * col2 - col2 AS col1 FROM tab2 AS cor0
----
1430
529
803

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - 80 col1 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT + - col0 + - 86 FROM tab1 cor0
----
-150
-166
-89

query I rowsort
SELECT DISTINCT + - col0 + ( + col2 ) AS col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + - col1 * + ( - 29 ) + col0 FROM tab2 cor0
----
1789
572
906

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6262
SELECT DISTINCT col2 * CAST( NULL AS SIGNED ) + cor0.col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6262
SELECT DISTINCT col2 * CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + ( + col0 ) * - cor0.col1 + ( - 55 ) col2 FROM tab1 AS cor0
----
-638
-79
-999

query I rowsort
SELECT - + col0 + - col1 * + col1 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT DISTINCT col1 FROM tab1 AS cor0 WHERE NOT col0 + - col0 NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL - col0 AS col1 FROM tab1 WHERE + col1 - col1 IN ( col2 * col1 + tab1.col1 * col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col2 * col1 IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6268
SELECT ALL + col0 DIV + tab1.col1 + col2 FROM tab1
----
102
54
63

skipif mysql # not compatible
query I rowsort label-6268
SELECT ALL + col0 / + tab1.col1 + col2 FROM tab1
----
102
54
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-6269
SELECT DISTINCT + col0 DIV + col0 + col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6269
SELECT DISTINCT + col0 / + col0 + col2 FROM tab0
----
2
34
83

query I rowsort
SELECT DISTINCT - col0 + tab2.col2 * col0 FROM tab2
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-6271
SELECT - tab1.col0 DIV col1 + + tab1.col1 * - col2 * + col0 FROM tab1
----
-36486
-4212
-99846

skipif mysql # not compatible
query I rowsort label-6271
SELECT - tab1.col0 / col1 + + tab1.col1 * - col2 * + col0 FROM tab1
----
-36486
-4212
-99846

onlyif mysql # use DIV operator for integer division
query I rowsort label-6272
SELECT - col1 * col1 DIV - col0 FROM tab0
----
268
308
93

skipif mysql # not compatible
query I rowsort label-6272
SELECT - col1 * col1 / - col0 FROM tab0
----
268
308
93

query I rowsort
SELECT ALL - col2 + tab2.col0 + - col1 AS col2 FROM tab2
----
-51
-7
24

query I rowsort
SELECT ALL tab0.col1 + col0 + - tab0.col1 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6275
SELECT + tab2.col2 DIV + col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6275
SELECT + tab2.col2 / + col1 FROM tab2
----
0
0
2

query I rowsort
SELECT - tab1.col1 * + col2 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6277
SELECT - col1 + + col1 * - col1 DIV + tab2.col1 AS col0 FROM tab2
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-6277
SELECT - col1 + + col1 * - col1 / + tab2.col1 AS col0 FROM tab2
----
-118
-34
-62

query I rowsort
SELECT - col0 * - col2 * - col0 + cor0.col2 * + col1 AS col1 FROM tab2 AS cor0
----
-156650
-236512
-486

query I rowsort
SELECT ALL + cor0.col2 - + col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - col0 FROM tab1 AS cor0 WHERE NOT NULL BETWEEN NULL AND NULL OR NOT NULL = ( NULL )
----

query I rowsort
SELECT col0 * + col0 * + col0 FROM tab0 AS cor0
----
13824
42875
704969

query I rowsort
SELECT - 58 AS col0 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

query I rowsort
SELECT + col0 * col0 + - col2 AS col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT 11 + col0 * col1 + + col1 FROM tab1 AS cor0
----
1064
115
661

query I rowsort
SELECT + col0 * col1 + col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT DISTINCT col0 + col2 * + col2 AS col1 FROM tab2 AS cor0
----
1523
736
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col1 * col2 col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT col0 * 54 + - col1 FROM tab1 AS cor0
----
136
3446
4307

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6289
SELECT DISTINCT - + col1 * + CAST( col0 AS SIGNED ) + - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

skipif mysql # not compatible
query I rowsort label-6289
SELECT DISTINCT - + col1 * + CAST ( col0 AS INTEGER ) + - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL col2 + + col0 * 11 * - col1 FROM tab2 AS cor0
----
-14735
-2360
-50596

query I rowsort
SELECT ALL - - col2 * cor0.col0 AS col0 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6292
SELECT DISTINCT + col1 DIV - 68 + - col1 - col2 * + 31 AS col1 FROM tab2 AS cor0
----
-1195
-865
-868

skipif mysql # not compatible
query I rowsort label-6292
SELECT DISTINCT + col1 / - 68 + - col1 - col2 * + 31 AS col1 FROM tab2 AS cor0
----
-1195
-865
-868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6293
SELECT ALL cor0.col0 + CAST( + 82 AS SIGNED ) FROM tab2 AS cor0
----
160
161
89

skipif mysql # not compatible
query I rowsort label-6293
SELECT ALL cor0.col0 + CAST ( + 82 AS INTEGER ) FROM tab2 AS cor0
----
160
161
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6294
SELECT ALL - col1 + 89 DIV - col1 + col0 AS col2 FROM tab0 AS cor0
----
-2
-62
-63

skipif mysql # not compatible
query I rowsort label-6294
SELECT ALL - col1 + 89 / - col1 + col0 AS col2 FROM tab0 AS cor0
----
-2
-62
-63

query I rowsort
SELECT ALL + col2 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 + ( col2 ) * cor0.col0 AS col1 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL - col2 + tab1.col2 * + col1 AS col0 FROM tab1
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col1 col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL col2 FROM tab0 WHERE ( NULL ) NOT IN ( + col0 + col2 / col2 )
----

query I rowsort
SELECT ALL col2 + tab1.col0 * tab1.col0 * col0 + col2 AS col1 FROM tab1
----
135
262258
512192

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT IN ( - col0 + col0 )
----

query I rowsort
SELECT col1 * col1 + col2 AS col1 FROM tab1
----
157
265
730

query I rowsort
SELECT DISTINCT tab2.col1 + tab2.col2 * - col0 AS col1 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT col0 AS col0 FROM tab2 WHERE NOT NULL IN ( - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6305
SELECT DISTINCT tab1.col1 + - col2 DIV tab1.col1 AS col0 FROM tab1
----
24
5
6

skipif mysql # not compatible
query I rowsort label-6305
SELECT DISTINCT tab1.col1 + - col2 / tab1.col1 AS col0 FROM tab1
----
24
5
6

query III rowsort
SELECT * FROM tab1 WHERE NOT - col0 + + col0 / + col1 + col1 / + col0 IN ( - col2 + + col2 * col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT col0 + - col2 * - 92 * 79 AS col1 FROM tab0 cor0
----
239868
596065
7303

query I rowsort
SELECT ALL + + col1 * col2 * - col2 AS col2 FROM tab1 cor0
----
-119808
-32490
-75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-6309
SELECT col0 + + col2 * + col1 + - col0 DIV tab1.col0 AS col2 FROM tab1
----
1327
1406
633

skipif mysql # not compatible
query I rowsort label-6309
SELECT col0 + + col2 * + col1 + - col0 / tab1.col0 AS col2 FROM tab1
----
1327
1406
633

query I rowsort
SELECT DISTINCT col2 + tab0.col2 * + tab0.col0 + col1 FROM tab0
----
133
7471
911

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col2 col0 FROM tab0
----
0

query I rowsort
SELECT - col2 + - col0 * + col0 FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT tab2.col1 * col1 + col0 AS col1 FROM tab2
----
3559
368
968

query I rowsort
SELECT - col0 * ( col2 ) AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT col1 + 9 AS col1 FROM tab0 AS cor0
----
100
106
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6316
SELECT ALL - col2 * col2 + + col0 + col1 * col1 DIV col1 FROM tab2 AS cor0
----
-1348
-539
-691

skipif mysql # not compatible
query I rowsort label-6316
SELECT ALL - col2 * col2 + + col0 + col1 * col1 / col1 FROM tab2 AS cor0
----
-1348
-539
-691

query I rowsort
SELECT ALL + col0 * - cor0.col0 + col1 AS col1 FROM tab0 cor0
----
-1128
-490
-7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-6318
SELECT ALL col1 DIV 13 AS col2 FROM tab0 AS cor0
----
6
7
7

skipif mysql # not compatible
query I rowsort label-6318
SELECT ALL col1 / 13 AS col2 FROM tab0 AS cor0
----
6
7
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6319
SELECT + - cor0.col1 + - col2 DIV + col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6319
SELECT + - cor0.col1 + - col2 / + col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL 56 AS col0 FROM tab1
----
56
56
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col1 * col2 + - tab1.col1 col1 FROM tab1
----
1331
1432
617

query I rowsort
SELECT ALL - - tab2.col1 AS col1 FROM tab1, tab0, tab2 AS cor0, tab2
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT ALL col1 * col0 + tab2.col0 * - ( + tab2.col2 ) * - col1 FROM tab2
----
124254
52377
6076

onlyif mysql # use DIV operator for integer division
query I rowsort label-6324
SELECT - 87 DIV + 72 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6324
SELECT - 87 / + 72 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-6325
SELECT ALL - col2 DIV + tab0.col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6325
SELECT ALL - col2 / + tab0.col0 FROM tab0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6326
SELECT DISTINCT + col2 + 94 DIV - 64 AS col2 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-6326
SELECT DISTINCT + col2 + 94 / - 64 AS col2 FROM tab1 AS cor0
----
53
56
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + + cor0.col2 col0 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT ALL - cor0.col0 * - 98 FROM tab0 AS cor0
----
2352
3430
8722

query I rowsort
SELECT DISTINCT - col2 + cor0.col0 * ( + col1 ) FROM tab2 cor0
----
1305
190
4576

query I rowsort
SELECT col2 + 62 * col2 FROM tab0 AS cor0
----
2079
5166
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-6331
SELECT - ( col0 * - col2 ) + 3 DIV 91 FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-6331
SELECT - ( col0 * - col2 ) + 3 / 91 FROM tab1
----
162
3648
7680

query I rowsort
SELECT col0 + 44 FROM tab1 AS cor0
----
108
124
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6333
SELECT DISTINCT + CAST( - col1 AS SIGNED ) + col1 col1 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6333
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) + col1 col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + 93 + - cor0.col1 FROM tab2 AS cor0
----
34
62
76

query I rowsort
SELECT ALL - ( + 10 ) + + col2 AS col2 FROM tab2 AS cor0
----
16
17
28

query I rowsort
SELECT ALL - col0 + - ( - col1 ) * 55 * - col1 - col2 FROM tab2 AS cor0
----
-16012
-191559
-52889

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 + ( - col2 * + col2 ) col1 FROM tab0 AS cor0
----
-14823
-3153
-3396

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) + + 16 col0 FROM tab0 cor0
----
105
40
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-6339
SELECT DISTINCT + 95 DIV - col0 + + col1 AS col1 FROM tab2 cor0
----
16
18
58

skipif mysql # not compatible
query I rowsort label-6339
SELECT DISTINCT + 95 / - col0 + + col1 AS col1 FROM tab2 cor0
----
16
18
58

query I rowsort
SELECT 22 + - col2 AS col1 FROM tab0
----
-11
-60
21

query I rowsort
SELECT ALL + + 71 + + col2 * - ( col0 + col1 ) FROM tab2 AS cor0
----
-3491
-3577
-955

query I rowsort
SELECT ALL + cor0.col0 + + cor0.col0 FROM tab0 AS cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col1 + col1 col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT col0 * col2 + - 97 FROM tab2 AS cor0
----
1931
2905
92

query I rowsort
SELECT ALL - 68 + - col1 FROM tab0 AS cor0
----
-154
-159
-165

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + col2 + - cor0.col2 col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT col2 + col2 * + col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + 62 * col0 + col2 * col0 FROM tab2 cor0
----
623
6864
7900

query I rowsort
SELECT - - cor0.col0 * + col1 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 - col2 FROM tab2 cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + cor0.col1 - cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col0 - col0 AS col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL - col2 * col2 * col1 AS col0 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT cor0.col1 * + col0 - + col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + col0 * - col1 * - col2 + + col2 AS col1 FROM tab1 AS cor0
----
36537
4266
99936

query I rowsort
SELECT 35 * 33 FROM tab0 AS cor0
----
1155
1155
1155

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6358
SELECT + CAST( col1 AS SIGNED ) * cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-6358
SELECT + CAST ( col1 AS INTEGER ) * cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6359
SELECT col1 * col0 DIV + col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6359
SELECT col1 * col0 / + col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + + 16 FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT + ( col0 ) * col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + tab0.col2 * + ( col2 + - col0 ) FROM tab0
----
-34
-574
297

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 78 * + col0 col2 FROM tab1 AS cor0
----
234
4992
6240

query I rowsort
SELECT DISTINCT 74 AS col2 FROM tab0, tab0 AS cor0
----
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-6365
SELECT tab1.col2 DIV + col0 AS col2 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6365
SELECT tab1.col2 / + col0 AS col2 FROM tab1
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 col2 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT + col0 + + col1 * - col1 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL - 42 + + col2 AS col2 FROM tab0
----
-41
-9
40

query I rowsort
SELECT + - col2 + + col0 FROM tab2 cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6370
SELECT ALL CAST( NULL AS SIGNED ) * 77 + + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6370
SELECT ALL CAST ( NULL AS INTEGER ) * 77 + + col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + - ( - col1 + - col1 ) AS col0 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 79 + - col1 + col2 col2 FROM tab1
----
-209
-5009
-6237

onlyif mysql # use DIV operator for integer division
query I rowsort label-6373
SELECT - col0 DIV 59 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6373
SELECT - col0 / 59 FROM tab0
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6374
SELECT ALL + CAST( NULL AS DECIMAL ) + + col1 * col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6374
SELECT ALL + CAST ( NULL AS REAL ) + + col1 * col2 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + 68 ) FROM tab0 AS cor0
----
68
68
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 43 * col2 col2 FROM tab0
----
1419
3526
43

query I rowsort
SELECT 18 * 35 AS col2 FROM tab0 cor0
----
630
630
630

query I rowsort
SELECT ALL col0 + cor0.col1 AS col0 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 * col0 col0 FROM tab1 cor0
----
201
4288
5360

query I rowsort
SELECT ALL + - col0 * col1 - + cor0.col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query IIIIIIIII rowsort
SELECT * FROM tab1, tab0, tab0 AS cor0 WHERE NOT cor0.col1 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL ( + tab2.col1 ) * col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + + cor0.col0 AS col2 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT 38 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6385
SELECT - col0 * 6 + col1 DIV + col0 AS col1 FROM tab0 AS cor0
----
-141
-208
-533

skipif mysql # not compatible
query I rowsort label-6385
SELECT - col0 * 6 + col1 / + col0 AS col1 FROM tab0 AS cor0
----
-141
-208
-533

onlyif mysql # use DIV operator for integer division
query I rowsort label-6386
SELECT + col2 DIV 69 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6386
SELECT + col2 / 69 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT - + cor0.col2 * ( + col1 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT col2 + - col1 * - col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL + 37 AS col0 FROM tab2
----
37
37
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6390
SELECT ALL col2 * + CAST( col2 AS SIGNED ) AS col0 FROM tab1
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-6390
SELECT ALL col2 * + CAST ( col2 AS INTEGER ) AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT cor0.col0 * + 37 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 73ee812132330de098318363c918c2c8

query I rowsort
SELECT ALL + 8 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT ALL col2 + ( + col1 ) AS col1 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6394
SELECT col0 * CAST( col1 + - col1 AS SIGNED ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6394
SELECT col0 * CAST ( col1 + - col1 AS INTEGER ) FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 col2 FROM tab1
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - col2 col0 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL - 4 - - 62 AS col0 FROM tab1 AS cor0
----
58
58
58

query I rowsort
SELECT ALL col1 * - col1 + col0 * col1 AS col0 FROM tab2 AS cor0
----
-744
1054
1121

query I rowsort
SELECT ALL + ( + cor0.col0 ) FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT + col0 - + tab2.col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT col0 * + 74 + col2 FROM tab0
----
1809
2591
6668

query I rowsort
SELECT DISTINCT tab2.col1 * - col2 * + col2 AS col2 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT + col0 * - col1 * col0 AS col1 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT - col1 - col1 * col1 FROM tab0
----
-7482
-8372
-9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 22 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT ALL + ( 16 ) AS col1 FROM tab0 AS cor0
----
16
16
16

query I rowsort
SELECT ALL + 0 + + col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - 2 * - col1 AS col1 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6409
SELECT + + CAST( NULL AS SIGNED ) + - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6409
SELECT + + CAST ( NULL AS INTEGER ) + - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 + + cor0.col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + ( + col2 ) * - col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + 81 * col0 AS col0 FROM tab1 AS cor0
----
243
5184
6480

query I rowsort
SELECT + - cor0.col0 AS col0 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT - ( col2 ) * 46 - - col1 FROM tab2 AS cor0
----
-1137
-1211
-1731

query I rowsort
SELECT DISTINCT - - col2 + 40 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1066
1107
1558

query I rowsort
SELECT ALL + col0 * + col0 + 32 AS col1 FROM tab2 cor0
----
6116
6273
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6417
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6417
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab2 AS cor1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6418
SELECT ALL - col2 + + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6418
SELECT ALL - col2 + + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + + 74 - col2 AS col1 FROM tab1 AS cor0
----
74

query I rowsort
SELECT - col0 * - col0 + cor0.col2 AS col1 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT + + col2 + cor0.col0 AS col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6422
SELECT - col2 * tab1.col2 DIV - CAST( - col2 AS SIGNED ) col2 FROM tab1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6422
SELECT - col2 * tab1.col2 / - CAST ( - col2 AS INTEGER ) col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col1 * - col1 AS col0 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT col0 + - col1 + 84 FROM tab2 AS cor0
----
103
146
60

query I rowsort
SELECT + 34 + + col0 + + col2 FROM tab0 AS cor0
----
205
70
91

query I rowsort
SELECT ALL + 98 * - col1 AS col0 FROM tab2 AS cor0
----
-1666
-3038
-5782

query I rowsort
SELECT + 1 + col1 + - 62 AS col2 FROM tab1 AS cor0
----
-35
-48
-51

query I rowsort
SELECT ALL - - 15 FROM tab2 AS cor0
----
15
15
15

query I rowsort
SELECT - ( + cor0.col2 ) * 31 + + col2 FROM tab0 AS cor0
----
-2460
-30
-990

query I rowsort
SELECT DISTINCT 0 * - col2 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6431
SELECT DISTINCT - - 88 DIV 54 AS col0 FROM tab0, tab2, tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-6431
SELECT DISTINCT - - 88 / 54 AS col0 FROM tab0, tab2, tab2 AS cor0
----
1

query I rowsort
SELECT DISTINCT col1 + + 64 AS col1 FROM tab2
----
123
81
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6433
SELECT - + col1 + col0 + CAST( 33 AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
1316
867
877

skipif mysql # not compatible
query I rowsort label-6433
SELECT - + col1 + col0 + CAST ( 33 AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
1316
867
877

query I rowsort
SELECT ALL - 4 * + col0 AS col2 FROM tab1 cor0
----
-12
-256
-320

query I rowsort
SELECT + col2 * + col2 * 93 + - 23 * col2 * col2 + + col1 FROM tab0 cor0
----
167
470771
76316

query I rowsort
SELECT + + col1 * + 46 AS col2 FROM tab0 AS cor0
----
3956
4186
4462

onlyif mysql # use DIV operator for integer division
query I rowsort label-6437
SELECT - col1 + - col1 DIV - ( - 49 * col0 ) FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6437
SELECT - col1 + - col1 / - ( - 49 * col0 ) FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - 52 * cor0.col0 + - cor0.col1 + - 99 AS col1 FROM tab2 AS cor0
----
-4214
-4224
-494

onlyif mysql # use DIV operator for integer division
query I rowsort label-6439
SELECT + col2 * + col1 + - col2 + - col0 DIV col2 AS col1 FROM tab0 AS cor0
----
2805
61
7379

skipif mysql # not compatible
query I rowsort label-6439
SELECT + col2 * + col1 + - col2 + - col0 / col2 AS col1 FROM tab0 AS cor0
----
2805
61
7379

query I rowsort
SELECT + 30 * col0 + col1 FROM tab0 cor0
----
1147
2761
806

query I rowsort
SELECT - col2 - + 54 FROM tab2 cor0
----
-80
-81
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col2 + col2 col1 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6443
SELECT + CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6443
SELECT + CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 96 * - col0 + col0 FROM tab1
----
-285
-6080
-7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6445
SELECT - CAST( col0 AS SIGNED ) - + col1 * ( col2 + col2 * - col1 ) AS col2 FROM tab1
----
14896
35097
5066

skipif mysql # not compatible
query I rowsort label-6445
SELECT - CAST ( col0 AS INTEGER ) - + col1 * ( col2 + col2 * - col1 ) AS col2 FROM tab1
----
14896
35097
5066

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 + + tab0.col1 col0 FROM tab0
----
148
159
93

query I rowsort
SELECT - tab0.col2 * - 72 AS col0 FROM tab0
----
2376
5904
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-6448
SELECT - cor0.col0 DIV cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif mysql # not compatible
query I rowsort label-6448
SELECT - cor0.col0 / cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT ALL + col0 * - col1 + + col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT + 95 + + col2 * col2 AS col0 FROM tab0 AS cor0
----
1184
6819
96

query I rowsort
SELECT + 61 + + 37 + - col2 FROM tab2 AS cor0
----
60
71
72

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab2 cor1, tab1, tab1 AS cor2
----
3645 values hashing to 79b6ae096785aaecea9c1428e4a43e5f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6453
SELECT DISTINCT + CAST( - col0 AS SIGNED ) DIV cor0.col1 FROM tab1 AS cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-6453
SELECT DISTINCT + CAST ( - col0 AS INTEGER ) / cor0.col1 FROM tab1 AS cor0
----
-6
0

query I rowsort
SELECT ALL - 92 AS col1 FROM tab1 cor0
----
-92
-92
-92

query I rowsort
SELECT ALL + ( - 77 ) + col2 AS col2 FROM tab1
----
-20
-23
19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6456
SELECT ALL tab2.col0 / 92 + col0 / CAST( NULL AS DECIMAL ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6456
SELECT ALL tab2.col0 / 92 + col0 / CAST ( NULL AS REAL ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 99 FROM tab2 cor0
----
99

query I rowsort
SELECT ALL - 98 * 70 + + col2 FROM tab2 AS cor0
----
-6822
-6833
-6834

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6459
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + + col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6459
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + + col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - + 3 - cor0.col1 AS col1 FROM tab1 AS cor0
----
-13
-16
-29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 68 col2 FROM tab1 AS cor0
----
-68

query I rowsort
SELECT + 68 * + col0 FROM tab1
----
204
4352
5440

query I rowsort
SELECT DISTINCT + 59 * + col2 * 38 FROM tab2
----
58292
60534
85196

query I rowsort
SELECT col1 + col0 * 27 AS col2 FROM tab0 cor0
----
1042
2494
734

query I rowsort
SELECT + 65 - col2 AS col0 FROM tab2 AS cor0
----
27
38
39

query I rowsort
SELECT col0 + col0 AS col1 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT - - col1 * - col1 + + 35 AS col0 FROM tab2 AS cor0
----
-254
-3446
-926

query I rowsort
SELECT + 0 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT col0 * + ( 9 ) + - col0 FROM tab0 AS cor0
----
192
280
712

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1, tab0 cor0, tab1 AS cor1
----
972 values hashing to 0a9194f200a4220e419d35c461f9fcfe

query I rowsort
SELECT col1 * ( tab0.col2 ) + tab0.col2 AS col0 FROM tab0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6472
SELECT DISTINCT col2 DIV - 6 AS col2 FROM tab1 AS cor0
----
-16
-9

skipif mysql # not compatible
query I rowsort label-6472
SELECT DISTINCT col2 / - 6 AS col2 FROM tab1 AS cor0
----
-16
-9

query I rowsort
SELECT cor0.col1 + 31 + + col2 AS col1 FROM tab1 AS cor0
----
111
140
98

query I rowsort
SELECT ALL 94 FROM tab2, tab2 cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT + cor0.col1 * ( col1 * - col0 ) AS col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT 99 FROM tab1, tab2 cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * - 81 col1 FROM tab1 AS cor0
----
243
5184
6480

query I rowsort
SELECT DISTINCT + - ( + col0 ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL + cor0.col1 * + 98 + + col2 FROM tab1 AS cor0
----
1037
1370
2602

query I rowsort
SELECT ( ( col1 ) ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 92 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT ALL + col0 * 82 FROM tab1
----
246
5248
6560

query I rowsort
SELECT - - ( - 69 ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

query I rowsort
SELECT - 54 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 71e27a12767d3a987ce05e4d6edad211

query I rowsort
SELECT ( + col2 ) + cor0.col0 * + col2 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT 80 + - col0 AS col1 FROM tab2 AS cor0
----
1
2
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col0 * ( + col0 ) col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT cor0.col0 * - 89 FROM tab0 AS cor0
----
-2136
-3115
-7921

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab2 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to ca91d1f523a87017f672304548e91a77

query I rowsort
SELECT col1 * - 98 * col2 + col0 FROM tab0 AS cor0
----
-278100
-731187
-9471

query I rowsort
SELECT DISTINCT - cor0.col2 * 62 AS col0 FROM tab2, tab0 AS cor0
----
-2046
-5084
-62

query I rowsort
SELECT + cor0.col0 - + ( + cor0.col1 ) FROM tab2, tab2 AS cor0
----
9 values hashing to d924577a04b3a692cbbd2348e6f8e88f

query I rowsort
SELECT + ( + col0 ) + + cor0.col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT tab0.col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
1
33
82

query I rowsort
SELECT DISTINCT 43 AS col2 FROM tab1, tab1 cor0
----
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-6496
SELECT - ( - 19 ) DIV tab1.col1 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6496
SELECT - ( - 19 ) / tab1.col1 FROM tab1
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 89 * - col1 col1 FROM tab2
----
-1475
-2732
-5225

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6498
SELECT + CAST( NULL AS SIGNED ) + + 33 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6498
SELECT + CAST ( NULL AS INTEGER ) + + 33 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6499
SELECT - ( col1 ) DIV - cor0.col2 + col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-6499
SELECT - ( col1 ) / - cor0.col2 + col2 FROM tab0 AS cor0
----
35
83
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6500
SELECT - + 59 DIV + col0 + col2 * ( + col0 ) FROM tab2 AS cor0
----
181
2028
3002

skipif mysql # not compatible
query I rowsort label-6500
SELECT - + 59 / + col0 + col2 * ( + col0 ) FROM tab2 AS cor0
----
181
2028
3002

query I rowsort
SELECT - 83 * + col0 * + col0 + - 83 FROM tab1 AS cor0
----
-340051
-531283
-830

query I rowsort
SELECT DISTINCT + 16 + + col1 FROM tab0 AS cor0
----
102
107
113

query I rowsort
SELECT ALL col2 * col2 + - ( + col0 + + col2 ) FROM tab1 AS cor0
----
2859
3128
9040

query I rowsort
SELECT 60 * col1 AS col1 FROM tab0 AS cor0
----
5160
5460
5820

query I rowsort
SELECT + - col2 * - col1 + col0 + + col1 FROM tab1 AS cor0
----
1341
1433
644

query I rowsort
SELECT - + col1 * + col0 * - col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT - 28 * - col2 AS col1 FROM tab2 AS cor0
----
1064
728
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-6508
SELECT - col2 DIV - 99 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6508
SELECT - col2 / - 99 AS col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6509
SELECT + tab1.col2 DIV 84 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6509
SELECT + tab1.col2 / 84 FROM tab1
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6510
SELECT - ( - cor0.col1 ) DIV col0 + 59 + - col0 FROM tab2 cor0
----
-19
-20
56

skipif mysql # not compatible
query I rowsort label-6510
SELECT - ( - cor0.col1 ) / col0 + 59 + - col0 FROM tab2 cor0
----
-19
-20
56

query I rowsort
SELECT 19 - - col1 FROM tab2 AS cor0
----
36
50
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6512
SELECT CAST( NULL AS SIGNED ) / + 80 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6512
SELECT CAST ( NULL AS INTEGER ) / + 80 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + - 24 AS col0 FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT DISTINCT + col0 * + ( col2 ) AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT col0 * + ( + col2 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - - cor0.col0 + - col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT ALL 63 * - col0 * - ( col0 ) + + col1 FROM tab1
----
258058
403213
593

query I rowsort
SELECT ALL + col2 + - col2 * + col0 * col2 AS col0 FROM tab0
----
-26103
-34
-598354

query I rowsort
SELECT DISTINCT ( - col1 ) + + col1 AS col1 FROM tab1
----
0

query I rowsort
SELECT DISTINCT - 4 * - col0 AS col1 FROM tab0 cor0
----
140
356
96

query I rowsort
SELECT ALL col2 * - 77 + cor0.col1 FROM tab0 AS cor0
----
-2455
-6223
20

query I rowsort
SELECT ALL cor0.col0 * + col1 + cor0.col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + cor0.col2 + col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL - + 83 + col0 + + col0 * + col2 FROM tab0 AS cor0
----
-13
7304
733

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - col1 ) * col2 col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - col2 + 97 FROM tab0 AS cor0
----
15
64
96

query I rowsort
SELECT DISTINCT - ( + col2 ) * + col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + 52 * - 71 + - col2 + - ( - 99 * col1 ) FROM tab2
----
-2047
-650
2123

query I rowsort
SELECT 10 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-170
-310
-590

query I rowsort
SELECT - + 38 * col1 FROM tab0 AS cor0
----
-3268
-3458
-3686

query I rowsort
SELECT - 98 + 0 FROM tab1 AS cor0
----
-98
-98
-98

query I rowsort
SELECT ALL cor0.col2 * - 11 AS col0 FROM tab0 AS cor0
----
-11
-363
-902

query I rowsort
SELECT DISTINCT + 88 AS col2 FROM tab1 AS cor0
----
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 65 * + col1 col0 FROM tab2 AS cor0
----
18785
226265
62465

query I rowsort
SELECT + + col1 + - col1 * + col2 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT - 57 * 43 FROM tab2 cor0
----
-2451
-2451
-2451

query I rowsort
SELECT DISTINCT col2 + 3 FROM tab0
----
36
4
85

query I rowsort
SELECT DISTINCT + col2 + col1 * col2 AS col2 FROM tab1
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-6539
SELECT + col0 DIV col1 + 8 FROM tab2
----
12
8
9

skipif mysql # not compatible
query I rowsort label-6539
SELECT + col0 / col1 + 8 FROM tab2
----
12
8
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + tab0.col0 col0 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT + + col0 + 76 FROM tab1 cor0
----
140
156
79

query I rowsort
SELECT + cor0.col0 + + col2 FROM tab2 cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + + ( col0 ) * col1 col2 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6544
SELECT ALL + - col0 * - ( + col2 * col0 ) + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6544
SELECT ALL + - col0 * - ( + col2 * col0 ) + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 59 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

query I rowsort
SELECT DISTINCT col0 * 14 * col0 + col1 AS col1 FROM tab1 AS cor0
----
152
57354
89613

query I rowsort
SELECT + col2 + cor0.col0 * + col0 AS col0 FROM tab0 cor0
----
1226
609
8003

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6548
SELECT DISTINCT - + col2 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6548
SELECT DISTINCT - + col2 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - 77 * 54 FROM tab2 AS cor0
----
-4158
-4158
-4158

query I rowsort
SELECT ALL + 76 + 92 AS col0 FROM tab1 AS cor0
----
168
168
168

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + cor0.col2 col0 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6552
SELECT + ( - col2 ) * + col1 + - col1 DIV ( - cor0.col2 ) - 25 * col0 AS col0 FROM tab0 AS cor0
----
-3436
-875
-9686

skipif mysql # not compatible
query I rowsort label-6552
SELECT + ( - col2 ) * + col1 + - col1 / ( - cor0.col2 ) - 25 * col0 AS col0 FROM tab0 AS cor0
----
-3436
-875
-9686

query I rowsort
SELECT ALL - + col0 * col0 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT ALL + - 49 + - 14 FROM tab1 AS cor0
----
-63
-63
-63

query I rowsort
SELECT DISTINCT + col0 + - col1 - + col1 FROM tab2 AS cor0
----
-40
-55
45

query I rowsort
SELECT - col0 + 26 FROM tab0 AS cor0
----
-63
-9
2

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 + cor0.col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT 78 AS col0 FROM tab2, tab1 AS cor0
----
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + ( 53 ) col1 FROM tab2
----
112
70
84

query I rowsort
SELECT + 13 + + col2 AS col2 FROM tab0 cor0
----
14
46
95

query I rowsort
SELECT - ( col1 ) * cor0.col1 + + col2 FROM tab2 AS cor0
----
-251
-3455
-934

onlyif mysql # use DIV operator for integer division
query I rowsort label-6562
SELECT 68 - + 67 DIV cor0.col0 FROM tab2 cor0
----
59
68
68

skipif mysql # not compatible
query I rowsort label-6562
SELECT 68 - + 67 / cor0.col0 FROM tab2 cor0
----
59
68
68

query I rowsort
SELECT - ( col0 ) * + col2 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-6564
SELECT - + cor0.col0 DIV col1 AS col1 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6564
SELECT - + cor0.col0 / col1 AS col1 FROM tab2 cor0
----
-1
-4
0

query I rowsort
SELECT + + 45 AS col1 FROM tab1 cor0
----
45
45
45

query I rowsort
SELECT DISTINCT + ( - col0 ) * col1 - col0 * col2 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT DISTINCT + 35 + col1 FROM tab2 AS cor0
----
52
66
94

query I rowsort
SELECT ALL - 89 + col2 AS col0 FROM tab2 AS cor0
----
-51
-62
-63

query I rowsort
SELECT + + 16 FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT DISTINCT - 89 - col2 FROM tab2 AS cor0
----
-115
-116
-127

query I rowsort
SELECT ALL + col0 * col0 * + col2 AS col2 FROM tab2 AS cor0
----
1323
158184
237158

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 col0 + - col2 * 43 * + 13 AS col1 FROM tab0 AS cor0
----
-18423
-45749
-524

query I rowsort
SELECT + 39 + - col1 * - 44 FROM tab0 AS cor0
----
3823
4043
4307

query I rowsort
SELECT DISTINCT + 18 + + col1 AS col2 FROM tab0
----
104
109
115

onlyif mysql # use DIV operator for integer division
query I rowsort label-6576
SELECT 2 - + col2 DIV col0 FROM tab2
----
-1
2
2

skipif mysql # not compatible
query I rowsort label-6576
SELECT 2 - + col2 / col0 FROM tab2
----
-1
2
2

query I rowsort
SELECT col1 + 66 FROM tab2
----
125
83
97

query I rowsort
SELECT DISTINCT + 31 * + col2 - + col2 FROM tab1 AS cor0
----
1620
1710
2880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 17 * col1 + ( col0 ) * - cor0.col0 col0 FROM tab0 AS cor0
----
-6374
424
886

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col1 + - cor0.col1 * ( col0 * - 58 + - 2 ) col2 FROM tab1 cor0
----
37066
4547
60253

query I rowsort
SELECT DISTINCT - cor0.col1 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT 31 * - col2 FROM tab0 AS cor0
----
-1023
-2542
-31

onlyif mysql # use DIV operator for integer division
query I rowsort label-6583
SELECT - + cor0.col0 DIV 92 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6583
SELECT - + cor0.col0 / 92 AS col1 FROM tab2 AS cor0
----
0
0
0

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab0 cor1, tab1, tab2 AS cor2
----
3645 values hashing to 57708840c4ff70ecdca82ffd05259432

query I rowsort
SELECT - col2 * - 14 FROM tab2 cor0
----
364
378
532

query I rowsort
SELECT + col0 * 16 FROM tab0 AS cor0
----
1424
384
560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6587
SELECT col0 * + CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-6587
SELECT col0 * + CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
4096
6400
9

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab1, tab0 AS cor1, tab2 cor2, tab2 AS cor3
----
3645 values hashing to 7eb416b97f0ed263f6364cf59aa64c2b

query I rowsort
SELECT + col1 + - 30 FROM tab1 AS cor0
----
-17
-20
-4

query I rowsort
SELECT + + col0 + ( cor0.col2 ) * - col2 AS col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT DISTINCT - col1 * + 62 * + col1 FROM tab1
----
-10478
-41912
-6200

query I rowsort
SELECT + cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT DISTINCT col2 * 4 FROM tab1
----
216
228
384

query I rowsort
SELECT DISTINCT col0 + + 11 FROM tab1
----
14
75
91

query I rowsort
SELECT ALL 4 FROM tab1, tab0 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 3347a3237b37ed63205e9440d8818a46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6596
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6596
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT col1 * + col2 + - cor0.col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL + - 53 + col2 AS col0 FROM tab1 cor0
----
1
4
43

query I rowsort
SELECT - cor0.col0 * 40 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to fffb87eee33dd74a0f54228d6860212e

query I rowsort
SELECT - - cor0.col0 * col2 * ( + col0 * col1 ) FROM tab1 AS cor0
----
12636
2334720
7987200

query I rowsort
SELECT col2 * - col2 + - cor0.col2 AS col2 FROM tab0 cor0
----
-1122
-2
-6806

query I rowsort
SELECT 17 + col1 AS col1 FROM tab2 cor0
----
34
48
76

query I rowsort
SELECT DISTINCT + 50 * - col1 + col0 AS col1 FROM tab0 AS cor0
----
-4276
-4461
-4815

query I rowsort
SELECT ALL cor2.col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT ALL + col2 * ( 66 ) * col2 - + col2 AS col0 FROM tab0
----
443702
65
71841

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6606
SELECT + CAST( NULL AS SIGNED ) + 58 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6606
SELECT + CAST ( NULL AS INTEGER ) + 58 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - 69 + - col1 * + col1 FROM tab1
----
-169
-238
-745

query I rowsort
SELECT col1 * - ( - col1 ) * col0 AS col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT - 68 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 6fbba7db5bccb533a35aa5125a231f88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 81 col0 FROM tab0, tab2 cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT - 65 * + col0 + - tab1.col0 AS col1 FROM tab1
----
-198
-4224
-5280

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + - col0 + + col0 * col2 col2 FROM tab0 AS cor0
----
-97
682
7118

query I rowsort
SELECT ( + col0 ) * col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-6614
SELECT col0 + + col0 DIV + cor0.col2 FROM tab1 AS cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-6614
SELECT col0 + + col0 / + cor0.col2 FROM tab1 AS cor0
----
3
65
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6615
SELECT + col2 DIV + col0 + cor0.col2 * + col2 + + col1 * + col2 FROM tab0 AS cor0
----
14186
3928
98

skipif mysql # not compatible
query I rowsort label-6615
SELECT + col2 / + col0 + cor0.col2 * + col2 + + col1 * + col2 FROM tab0 AS cor0
----
14186
3928
98

query I rowsort
SELECT + - col0 * + col1 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6617
SELECT - cor0.col2 - CAST( NULL AS SIGNED ) * + 4 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-6617
SELECT - cor0.col2 - CAST ( NULL AS INTEGER ) * + 4 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 - ( - 33 ) FROM tab1 AS cor0
----
129
87
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col2 * - col0 col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT - - col2 - - col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6621
SELECT DISTINCT col0 + cor0.col1 + 70 DIV - col1 col2 FROM tab2 AS cor0
----
136
36
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6621
SELECT DISTINCT col0 + cor0.col1 + 70 / - col1 col2 FROM tab2 AS cor0
----
136
36
92

query I rowsort
SELECT col0 + 91 AS col0 FROM tab0 AS cor0
----
115
126
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6623
SELECT ALL col0 * CAST( NULL AS SIGNED ) + + 46 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6623
SELECT ALL col0 * CAST ( NULL AS INTEGER ) + + 46 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 73 + col1 AS col1 FROM tab1
----
83
86
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 1 col1 FROM tab0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6626
SELECT - col0 + CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6626
SELECT - col0 + CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + col0 * col0 AS col1 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT - col2 + - 85 FROM tab0
----
-118
-167
-86

query I rowsort
SELECT ALL col1 * + 43 FROM tab0
----
3698
3913
4171

query I rowsort
SELECT col0 * + col2 + col1 * - tab2.col0 AS col2 FROM tab2
----
-2574
-28
1659

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 34 col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 33 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

query I rowsort
SELECT col2 * ( - col2 ) FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + - col2 col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL col0 * col0 + cor0.col2 + col2 * - col2 FROM tab2 AS cor0
----
-653
4835
5434

query I rowsort
SELECT ALL ( col2 ) + col0 * - 11 AS col2 FROM tab2 cor0
----
-50
-831
-832

query I rowsort
SELECT + + col1 * 73 FROM tab2 AS cor0
----
1241
2263
4307

query I rowsort
SELECT ALL + + 7 - - col0 FROM tab1 AS cor0
----
10
71
87

query I rowsort
SELECT DISTINCT - - ( - col2 ) * - col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT col0 * col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6641
SELECT + col0 DIV + col2 - col1 AS col0 FROM tab0 AS cor0
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-6641
SELECT + col0 / + col2 - col1 AS col0 FROM tab0 AS cor0
----
-62
-86
-90

query I rowsort
SELECT - 73 AS col1 FROM tab1 AS cor0
----
-73
-73
-73

query I rowsort
SELECT DISTINCT + 68 * - col2 AS col2 FROM tab2 AS cor0
----
-1768
-1836
-2584

query I rowsort
SELECT + col1 * + ( + col0 ) + 20 FROM tab2 cor0
----
1363
237
4622

query I rowsort
SELECT ALL - ( 4 ) FROM tab0 AS cor0
----
-4
-4
-4

query I rowsort
SELECT col0 * + col2 + + cor0.col2 - + col2 AS col2 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6647
SELECT ALL CAST( col0 AS SIGNED ) + - col0 * cor0.col0 AS col1 FROM tab1 cor0
----
-4032
-6
-6320

skipif mysql # not compatible
query I rowsort label-6647
SELECT ALL CAST ( col0 AS INTEGER ) + - col0 * cor0.col0 AS col1 FROM tab1 cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL + col0 * + ( + 33 ) * col2 - - ( + col1 ) AS col0 FROM tab1
----
120394
253453
5372

query I rowsort
SELECT + - col1 * col1 * col0 AS col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT ( - col2 ) * - ( col2 + - col1 ) * - col1 AS col0 FROM tab2 AS cor0
----
-13566
3348
50622

query I rowsort
SELECT ALL + ( tab0.col1 ) + cor0.col0 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to b4f1c386be87fcd5849dc0c2155c8ce7

query I rowsort
SELECT + ( 50 + - col0 ) AS col1 FROM tab2
----
-28
-29
43

query I rowsort
SELECT - cor1.col1 AS col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT - col1 * - 7 * tab1.col2 AS col0 FROM tab1
----
3990
8736
9828

query I rowsort
SELECT ALL 74 + col1 * col0 AS col2 FROM tab0 AS cor0
----
2138
3469
8173

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6656
SELECT CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6656
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - 86 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 9ac806793c03d3a6b5e3a3029d20e4da

query I rowsort
SELECT ALL col1 * - 41 AS col2 FROM tab0 AS cor0
----
-3526
-3731
-3977

query I rowsort
SELECT ALL - ( - ( col2 ) + 28 ) * col1 FROM tab1
----
290
676
884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) + - col1 col2 FROM tab0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6661
SELECT ALL 16 DIV + 87 col2 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6661
SELECT ALL 16 / + 87 col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT 85 + + cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
171
176
182

query I rowsort
SELECT + ( 80 ) AS col1 FROM tab0
----
80
80
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6664
SELECT DISTINCT - + col2 + col1 - col0 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
-25
32
4

skipif mysql # not compatible
query I rowsort label-6664
SELECT DISTINCT - + col2 + col1 - col0 / cor0.col1 AS col1 FROM tab2 AS cor0
----
-25
32
4

query I rowsort
SELECT + 0 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT col1 + col0 + - 35 FROM tab1 AS cor0
----
-6
39
58

query I rowsort
SELECT ALL - - col1 + - cor0.col2 * + col2 * + cor0.col2 FROM tab0 AS cor0
----
-35851
-551277
96

query I rowsort
SELECT DISTINCT + - 39 AS col2 FROM tab0 AS cor0
----
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-6669
SELECT col1 + + cor0.col2 DIV 37 AS col2 FROM tab0 AS cor0
----
86
93
97

skipif mysql # not compatible
query I rowsort label-6669
SELECT col1 + + cor0.col2 / 37 AS col2 FROM tab0 AS cor0
----
86
93
97

query I rowsort
SELECT - 24 + + col0 FROM tab0 cor0
----
0
11
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-6671
SELECT ALL + + 81 + - col2 DIV col2 col1 FROM tab1 AS cor0
----
80
80
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6671
SELECT ALL + + 81 + - col2 / col2 col1 FROM tab1 AS cor0
----
80
80
80

query I rowsort
SELECT DISTINCT col2 * col1 + - 3 AS col1 FROM tab2
----
1531
643
834

query I rowsort
SELECT DISTINCT - + 51 AS col2 FROM tab1 AS cor0
----
-51

query I rowsort
SELECT ALL 20 AS col2 FROM tab0 AS cor0
----
20
20
20

query I rowsort
SELECT cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + col2 + + cor0.col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + + col0 * - col2 + 98 * cor0.col1 AS col0 FROM tab0 AS cor0
----
1620
7636
9471

onlyif mysql # use DIV operator for integer division
query I rowsort label-6678
SELECT DISTINCT - col2 DIV + col2 AS col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-6678
SELECT DISTINCT - col2 / + col2 AS col1 FROM tab0 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6679
SELECT ALL - 22 DIV - 94 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6679
SELECT ALL - 22 / - 94 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT col0 * col0 * col2 AS col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT col2 + - 92 - col2 * col2 FROM tab1 cor0
----
-2954
-3284
-9212

query I rowsort
SELECT - col2 + 43 AS col1 FROM tab2 AS cor0
----
16
17
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6683
SELECT - + cor0.col2 * CAST( NULL AS SIGNED ) * col2 + - col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6683
SELECT - + cor0.col2 * CAST ( NULL AS INTEGER ) * col2 + - col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6684
SELECT - - col1 DIV + col1 + col0 AS col1 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6684
SELECT - - col1 / + col1 + col0 AS col1 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT DISTINCT col2 + col1 * cor0.col1 * + col2 FROM tab2 AS cor0
----
11020
25974
90532

query I rowsort
SELECT ALL col1 * + col0 + 91 + - cor0.col0 FROM tab2 cor0
----
1355
301
4615

query I rowsort
SELECT ALL + col0 + + 19 * col2 * col2 AS col0 FROM tab1 AS cor0
----
175184
55407
61795

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - + ( - col1 ) * - col1 * - 17 col2 FROM tab1 cor0
----
11495
1764
2953

query I rowsort
SELECT col2 * - ( ( + col0 ) ) AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6690
SELECT ALL + 26 DIV 27 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6690
SELECT ALL + 26 / 27 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 90 col1 FROM tab0 AS cor0
----
-90
-90
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6692
SELECT ALL CAST( - 24 AS SIGNED ) + - col0 - - 9 FROM tab0 AS cor0
----
-104
-39
-50

skipif mysql # not compatible
query I rowsort label-6692
SELECT ALL CAST ( - 24 AS INTEGER ) + - col0 - - 9 FROM tab0 AS cor0
----
-104
-39
-50

query I rowsort
SELECT + tab1.col0 * ( 0 ) + + col0 * - col1 AS col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - - 96 * 50 FROM tab2 cor0
----
4800
4800
4800

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 + cor0.col0 * - col1 + - col1 col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT + col0 * - 86 AS col1 FROM tab0
----
-2064
-3010
-7654

onlyif mysql # use DIV operator for integer division
query I rowsort label-6698
SELECT ALL + col0 DIV 15 FROM tab0 AS cor0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-6698
SELECT ALL + col0 / 15 FROM tab0 AS cor0
----
1
2
5

query I rowsort
SELECT ( 94 ) * + col2 AS col1 FROM tab1 AS cor0
----
5076
5358
9024

query I rowsort
SELECT + 45 + 79 + col1 AS col0 FROM tab0 cor0
----
210
215
221

onlyif mysql # use DIV operator for integer division
query I rowsort label-6701
SELECT ( - 62 ) DIV col1 AS col1 FROM tab2 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6701
SELECT ( - 62 ) / col1 AS col1 FROM tab2 cor0
----
-1
-2
-3

query I rowsort
SELECT - + 58 * cor0.col1 + - col1 * + col2 FROM tab0 AS cor0
----
-12740
-5723
-7826

query I rowsort
SELECT DISTINCT + - 9 + + cor1.col1 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1, tab1 AS cor2
----
22
50
8

query I rowsort
SELECT 80 * - col1 AS col0 FROM tab2 AS cor0
----
-1360
-2480
-4720

query I rowsort
SELECT ALL 14 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

query I rowsort
SELECT + + col1 + ( + cor0.col0 ) * col0 + - col2 AS col1 FROM tab0 AS cor0
----
1321
629
7930

onlyif mysql # use DIV operator for integer division
query I rowsort label-6707
SELECT + col0 DIV - col0 + col1 * col0 + CAST( + 37 AS SIGNED ) FROM tab0 AS cor0
----
2100
3431
8135

skipif mysql # not compatible
query I rowsort label-6707
SELECT + col0 / - col0 + col1 * col0 + CAST ( + 37 AS INTEGER ) FROM tab0 AS cor0
----
2100
3431
8135

query I rowsort
SELECT - - col0 * - ( - 98 ) + - col0 AS col0 FROM tab1 AS cor0
----
291
6208
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-6709
SELECT + col1 DIV + col2 + 35 AS col1 FROM tab0 AS cor0
----
132
36
37

skipif mysql # not compatible
query I rowsort label-6709
SELECT + col1 / + col2 + 35 AS col1 FROM tab0 AS cor0
----
132
36
37

query I rowsort
SELECT ALL tab0.col0 * col1 + + col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + 68 + + col0 FROM tab1
----
132
148
71

query I rowsort
SELECT tab1.col0 + 85 AS col0 FROM tab1
----
149
165
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6713
SELECT DISTINCT - col0 * + ( + col1 + + col1 ) DIV - col1 FROM tab2
----
14
156
158

skipif mysql # not compatible
query I rowsort label-6713
SELECT DISTINCT - col0 * + ( + col1 + + col1 ) / - col1 FROM tab2
----
14
156
158

query I rowsort
SELECT - col1 + ( col0 ) + cor0.col2 * 66 FROM tab1 AS cor0
----
3541
3816
6403

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6715
SELECT col0 * + CAST( NULL AS DECIMAL ) * ( - tab0.col0 ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6715
SELECT col0 * + CAST ( NULL AS REAL ) * ( - tab0.col0 ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 * - col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6717
SELECT - col1 * - CAST( NULL AS SIGNED ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6717
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-6718
SELECT - col1 DIV ( - cor0.col0 ) FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-6718
SELECT - col1 / ( - cor0.col0 ) FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT DISTINCT - col2 * - col0 + - col2 * + cor0.col2 - 72 AS col0 FROM tab2 AS cor0
----
-612
1280
1486

query I rowsort
SELECT DISTINCT col1 + 73 * 19 AS col1 FROM tab2 AS cor0
----
1404
1418
1446

query I rowsort
SELECT DISTINCT + + col0 * - cor0.col2 + - col0 - - col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col1 * + 62 FROM tab2 AS cor0
----
-1054
-1922
-3658

query I rowsort
SELECT - cor0.col1 * - col2 * 13 FROM tab1 AS cor0
----
16224
18252
7410

onlyif mysql # use DIV operator for integer division
query I rowsort label-6724
SELECT - col0 DIV + CAST( col1 AS SIGNED ) AS col2 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-6724
SELECT - col0 / + CAST ( col1 AS INTEGER ) AS col2 FROM tab1
----
-6
-6
0

query I rowsort
SELECT ALL 72 * col2 - + cor0.col0 FROM tab0 AS cor0
----
2352
37
5815

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - col2 col2 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + cor0.col1 ) * 43 * + cor0.col1 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to d14ddd308b40bd8fa1808ce4d9e63ebe

query I rowsort
SELECT - col2 * + tab2.col0 - - col0 * col1 FROM tab2
----
-1659
2574
28

query I rowsort
SELECT ALL ( col1 ) * 59 AS col1 FROM tab1 AS cor0
----
1534
590
767

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * col0 col2 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6731
SELECT DISTINCT col0 * col0 * - CAST( 94 + + col0 * - 80 AS SIGNED ) AS col1 FROM tab2
----
22834
37392264
38856466

skipif mysql # not compatible
query I rowsort label-6731
SELECT DISTINCT col0 * col0 * - CAST ( 94 + + col0 * - 80 AS INTEGER ) AS col1 FROM tab2
----
22834
37392264
38856466

query I rowsort
SELECT DISTINCT + 13 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
13

query I rowsort
SELECT + 56 + + col0 AS col2 FROM tab1 cor0
----
120
136
59

query I rowsort
SELECT - - ( 67 ) * cor0.col0 + 20 AS col0 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e8e3466b58d240afb6e8817418d06840

query I rowsort
SELECT DISTINCT + ( - tab0.col0 ) FROM tab0
----
-24
-35
-89

query I rowsort
SELECT - tab2.col1 + 42 AS col2 FROM tab2
----
-17
11
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + col2 * - ( col0 * - col0 ) col0 FROM tab2 AS cor0
----
1330
158262
237237

query I rowsort
SELECT col2 * col2 + - col2 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT col2 + ( + 10 + tab0.col1 ) FROM tab0
----
108
129
183

query I rowsort
SELECT ALL + col0 + + 77 FROM tab0 AS cor0
----
101
112
166

query I rowsort
SELECT DISTINCT - + col0 + 51 FROM tab1 AS cor0
----
-13
-29
48

query I rowsort
SELECT DISTINCT - 76 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
-76

query I rowsort
SELECT 24 + col0 FROM tab1
----
104
27
88

query I rowsort
SELECT DISTINCT 85 * + col2 + col0 AS col0 FROM tab0
----
120
2829
7059

query I rowsort
SELECT ALL - 12 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT ALL - ( col0 ) * tab0.col2 * - ( col0 ) + + col2 * 79 AS col1 FROM tab0
----
1304
21615
656000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6747
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + 33 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6747
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + 33 FROM tab0
----
NULL

query I rowsort
SELECT 76 * - 96 * col0 - - 93 AS col1 FROM tab0
----
-175011
-255267
-649251

query I rowsort
SELECT - ( + 95 ) + - col0 * + col0 AS col1 FROM tab0
----
-1320
-671
-8016

query I rowsort
SELECT + cor0.col1 + - 48 FROM tab0 AS cor0
----
38
43
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 19 + col1 col1 FROM tab1 AS cor0
----
29
32
45

query I rowsort
SELECT ALL + 86 * + col2 * cor0.col2 - - col2 * col1 FROM tab0 AS cor0
----
183
585726
96492

query I rowsort
SELECT DISTINCT + col1 + 2 FROM tab0 AS cor0
----
88
93
99

query I rowsort
SELECT ALL - col2 + 54 FROM tab2 AS cor0
----
16
27
28

query I rowsort
SELECT - col0 + 79 AS col2 FROM tab0 AS cor0
----
-10
44
55

query I rowsort
SELECT DISTINCT - col1 + - col2 * - col2 AS col0 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT ALL + + col2 * cor0.col0 * ( col1 ) + + cor0.col1 + col0 FROM tab0 AS cor0
----
3527
664298
68222

query I rowsort
SELECT ALL - 69 * col0 FROM tab1 AS cor0
----
-207
-4416
-5520

query I rowsort
SELECT - cor0.col1 * - col0 + 74 AS col0 FROM tab0 AS cor0
----
2138
3469
8173

query I rowsort
SELECT DISTINCT - - 47 * - col2 * ( ( col0 ) ) - col1 AS col2 FROM tab1 AS cor0
----
-171466
-360973
-7640

query I rowsort
SELECT DISTINCT + 81 + - col0 * + col1 * 83 FROM tab1 AS cor0
----
-53039
-6393
-86239

query I rowsort
SELECT ( - col0 ) + col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + + 72 AS col1 FROM tab1 AS cor0
----
72

query I rowsort
SELECT DISTINCT + - col2 * + col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - col2 + - col0 * col0 AS col0 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT DISTINCT col0 + + col2 * col1 AS col2 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT - col1 + cor0.col0 * + ( 37 ) AS col0 FROM tab2 AS cor0
----
228
2827
2906

query I rowsort
SELECT ALL + 25 + + col2 AS col2 FROM tab0 AS cor0
----
107
26
58

query I rowsort
SELECT col1 * - col1 * 76 + - col1 AS col1 FROM tab0 AS cor0
----
-562182
-629447
-715181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 + col1 * + col1 col1 FROM tab1 AS cor0
----
110
182
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-6771
SELECT + + 64 DIV cor0.col0 col1 FROM tab1 AS cor0
----
0
1
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6771
SELECT + + 64 / cor0.col0 col1 FROM tab1 AS cor0
----
0
1
21

query I rowsort
SELECT ALL ( col1 ) + col0 * 93 * - ( col0 ) FROM tab0 AS cor0
----
-113828
-53482
-736562

onlyif mysql # use DIV operator for integer division
query I rowsort label-6773
SELECT ALL + col0 DIV + ( - cor0.col1 ) FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6773
SELECT ALL + col0 / + ( - cor0.col1 ) FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT - + 31 AS col1 FROM tab0, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to cb21a77465f6a7c6b5c4c99bafc9df52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6775
SELECT CAST( + 83 AS SIGNED ) * + col1 + - ( 61 * col2 ) AS col0 FROM tab1
----
-1136
-2647
-4777

skipif mysql # not compatible
query I rowsort label-6775
SELECT CAST ( + 83 AS INTEGER ) * + col1 + - ( 61 * col2 ) AS col0 FROM tab1
----
-1136
-2647
-4777

query I rowsort
SELECT + + col1 + - ( + col0 ) AS col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + 0 FROM tab1, tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col1 + - col1 col0 FROM tab0
----
0

query I rowsort
SELECT DISTINCT + col2 + - col2 + col1 FROM tab2
----
17
31
59

query I rowsort
SELECT - col0 * - col2 + + ( 68 ) + - col1 AS col0 FROM tab1
----
204
3706
7735

query I rowsort
SELECT DISTINCT + col2 + + col0 + - ( + col1 + + col0 * - ( - col1 ) ) FROM tab1
----
-47
-529
-877

query I rowsort
SELECT 7 * + tab1.col0 FROM tab1
----
21
448
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6783
SELECT col0 DIV col0 + cor0.col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6783
SELECT col0 / col0 + cor0.col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT col0 * 84 FROM tab0
----
2016
2940
7476

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6785
SELECT DISTINCT col1 + - CAST( 82 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-23
-51
-65

skipif mysql # not compatible
query I rowsort label-6785
SELECT DISTINCT col1 + - CAST ( 82 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-23
-51
-65

query I rowsort
SELECT DISTINCT + col1 + - ( col2 ) FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - col0 + - col2 * col0 + cor0.col2 FROM tab1 AS cor0
----
-111
-3655
-7664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col2 col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL - cor0.col1 * + 88 FROM tab1 AS cor0
----
-1144
-2288
-880

query I rowsort
SELECT ALL cor1.col2 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT DISTINCT - col1 + + ( + col0 * col2 ) FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT + col1 + + cor0.col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - 14 * + col2 + + cor0.col1 AS col2 FROM tab1 cor0
----
-1331
-730
-788

query I rowsort
SELECT ALL - 53 + col2 AS col0 FROM tab2 AS cor0
----
-15
-26
-27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6795
SELECT - CAST( - 95 AS SIGNED ) * col0 AS col1 FROM tab1 AS cor0
----
285
6080
7600

skipif mysql # not compatible
query I rowsort label-6795
SELECT - CAST ( - 95 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
285
6080
7600

query I rowsort
SELECT DISTINCT - col0 + col1 * col1 FROM tab0 cor0
----
7372
8192
9374

query I rowsort
SELECT ( + 33 ) + + col2 FROM tab0 AS cor0
----
115
34
66

query I rowsort
SELECT + cor0.col0 + - 19 AS col0 FROM tab1 AS cor0
----
-16
45
61

query I rowsort
SELECT - ( + col2 ) + - col0 * col2 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT + + 3 * col1 AS col2 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT - 76 * + col1 FROM tab1 AS cor0
----
-1976
-760
-988

query I rowsort
SELECT + 65 FROM tab1 cor0
----
65
65
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-6803
SELECT DISTINCT - + col0 + col2 DIV 43 + 68 AS col2 FROM tab0 AS cor0
----
-20
33
44

skipif mysql # not compatible
query I rowsort label-6803
SELECT DISTINCT - + col0 + col2 / 43 + 68 AS col2 FROM tab0 AS cor0
----
-20
33
44

query I rowsort
SELECT DISTINCT 86 + + col1 AS col2 FROM tab0 cor0
----
172
177
183

query I rowsort
SELECT - - col0 - cor0.col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col2 * 66 + + ( - cor0.col0 ) FROM tab1 AS cor0
----
3561
3698
6256

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - 31 + - col0 * - col1 col1 FROM tab0 AS cor0
----
1320
2310
5340

query I rowsort
SELECT - cor0.col1 + ( col2 + - col1 * ( 48 ) ) FROM tab0 AS cor0
----
-4181
-4377
-4752

query I rowsort
SELECT - - 20 + + 61 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6810
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6810
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6811
SELECT ALL col1 + + col1 DIV - col0 AS col1 FROM tab0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-6811
SELECT ALL col1 + + col1 / - col0 AS col1 FROM tab0
----
83
90
95

query I rowsort
SELECT 83 * - 60 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to a76a5dc25d44e3907d4c0c5f07e62e8f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6813
SELECT + col0 * col1 + - col2 DIV + ( - 46 ) AS col2 FROM tab0
----
2064
3395
8100

skipif mysql # not compatible
query I rowsort label-6813
SELECT + col0 * col1 + - col2 / + ( - 46 ) AS col2 FROM tab0
----
2064
3395
8100

query I rowsort
SELECT - - ( 88 ) FROM tab2 AS cor0
----
88
88
88

query I rowsort
SELECT 98 AS col1 FROM tab0 AS cor0
----
98
98
98

query I rowsort
SELECT DISTINCT + 90 AS col0 FROM tab1
----
90

query I rowsort
SELECT ( col1 ) * - cor0.col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6818
SELECT CAST( col2 AS SIGNED ) + col2 * + col0 FROM tab2 AS cor0
----
2054
216
3040

skipif mysql # not compatible
query I rowsort label-6818
SELECT CAST ( col2 AS INTEGER ) + col2 * + col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT col1 + + 87 FROM tab2 AS cor0
----
104
118
146

query I rowsort
SELECT DISTINCT - 90 * col2 * + col2 + col0 AS col1 FROM tab2 AS cor0
----
-129881
-60762
-65603

query I rowsort
SELECT DISTINCT - col1 + - col0 * - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT - 57 AS col2 FROM tab1 AS cor0
----
-57
-57
-57

query I rowsort
SELECT DISTINCT 14 - - cor1.col2 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
40
41
52

query I rowsort
SELECT + col1 * - ( cor0.col0 ) + cor0.col0 FROM tab1 AS cor0
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6825
SELECT col2 + col0 + 54 DIV cor0.col0 FROM tab2 AS cor0
----
104
117
41

skipif mysql # not compatible
query I rowsort label-6825
SELECT col2 + col0 + 54 / cor0.col0 FROM tab2 AS cor0
----
104
117
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6826
SELECT + col1 * - CAST( NULL AS SIGNED ) + + cor0.col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6826
SELECT + col1 * - CAST ( NULL AS INTEGER ) + + cor0.col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * tab2.col1 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT 91 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + 43 col0 FROM tab1 AS cor0
----
53
56
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-6830
SELECT ALL - col0 + col2 DIV col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-6830
SELECT ALL - col0 + col2 / col2 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT + ( + 44 ) + - col0 FROM tab2 AS cor0
----
-34
-35
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6832
SELECT DISTINCT - col1 * + CAST( + 44 AS SIGNED ) AS col2 FROM tab2
----
-1364
-2596
-748

skipif mysql # not compatible
query I rowsort label-6832
SELECT DISTINCT - col1 * + CAST ( + 44 AS INTEGER ) AS col2 FROM tab2
----
-1364
-2596
-748

query I rowsort
SELECT DISTINCT - 8 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
-8

query I rowsort
SELECT col2 * 72 * - 22 + - col2 AS col0 FROM tab2
----
-41210
-42795
-60230

onlyif mysql # use DIV operator for integer division
query I rowsort label-6835
SELECT DISTINCT col0 * col0 + tab1.col2 DIV col2 AS col1 FROM tab1
----
10
4097
6401

skipif mysql # not compatible
query I rowsort label-6835
SELECT DISTINCT col0 * col0 + tab1.col2 / col2 AS col1 FROM tab1
----
10
4097
6401

query I rowsort
SELECT col0 * - cor0.col0 + - col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col2 col1 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - col2 * - col2 AS col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - - col2 * - ( + cor0.col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL col1 * col2 + + col0 * 2 + - col1 * col0 AS col2 FROM tab1 AS cor0
----
1332
368
58

query I rowsort
SELECT + + 11 * - col1 AS col1 FROM tab2 cor0
----
-187
-341
-649

onlyif mysql # use DIV operator for integer division
query I rowsort label-6842
SELECT ALL - 62 DIV - col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6842
SELECT ALL - 62 / - col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT + cor0.col1 * + cor0.col1 + + cor0.col2 * ( + 65 ) * + col0 + + col1 * - 88 FROM tab2 AS cor0
----
10518
130109
193923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6844
SELECT DISTINCT + - CAST( 38 AS SIGNED ) + col2 AS col2 FROM tab1 AS cor0
----
16
19
58

skipif mysql # not compatible
query I rowsort label-6844
SELECT DISTINCT + - CAST ( 38 AS INTEGER ) + col2 AS col2 FROM tab1 AS cor0
----
16
19
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6845
SELECT - 66 + - col0 * + cor0.col1 + CAST( NULL AS DECIMAL ) * + col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6845
SELECT - 66 + - col0 * + cor0.col1 + CAST ( NULL AS REAL ) * + col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + cor0.col2 col2 FROM tab1, tab0 AS cor0
----
164
2
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6847
SELECT DISTINCT CAST( col0 AS SIGNED ) + col2 + col1 AS col0 FROM tab2 AS cor0
----
134
163
65

skipif mysql # not compatible
query I rowsort label-6847
SELECT DISTINCT CAST ( col0 AS INTEGER ) + col2 + col1 AS col0 FROM tab2 AS cor0
----
134
163
65

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-6849
SELECT col1 + 86 DIV - col0 AS col0 FROM tab2 AS cor0
----
16
19
58

skipif mysql # not compatible
query I rowsort label-6849
SELECT col1 + 86 / - col0 AS col0 FROM tab2 AS cor0
----
16
19
58

query I rowsort
SELECT DISTINCT cor0.col2 * - col0 + - col0 AS col1 FROM tab1 AS cor0
----
-165
-3712
-7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + col1 col0 FROM tab1
----
20
26
52

query I rowsort
SELECT col0 + 97 FROM tab2
----
104
175
176

query I rowsort
SELECT ALL + tab0.col1 + 28 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to c24a94655549e8491967d55419c7f8ef

query I rowsort
SELECT ALL ( col2 ) * + col1 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT - - tab0.col2 * - tab0.col1 AS col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to cbc7ea781e219f4177126feeb59feb2d

onlyif mysql # use DIV operator for integer division
query I rowsort label-6856
SELECT ALL col2 DIV + col2 col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6856
SELECT ALL col2 / + col2 col0 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL col0 * - 12 AS col1 FROM tab2
----
-84
-936
-948

query I rowsort
SELECT ALL - + ( col1 ) * col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - ( col2 ) + + col2 * col1 FROM tab1 AS cor0
----
1152
1350
513

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab1 cor1, tab2, tab2 AS cor2
----
3645 values hashing to 803a5565701c4ced6bba69940782c17a

query I rowsort
SELECT ALL - 9 * col0 FROM tab1
----
-27
-576
-720

query I rowsort
SELECT DISTINCT + 86 * + 8 AS col1 FROM tab2 AS cor0
----
688

query I rowsort
SELECT ALL ( - col1 ) * ( - tab1.col0 ) - - col0 FROM tab1
----
1120
704
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6864
SELECT DISTINCT col1 * col1 - - CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6864
SELECT DISTINCT col1 * col1 - - CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL

query I rowsort
SELECT ALL + 58 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 9ee363c6ac19cfdb8a50c7dfd5cc2b8a

query I rowsort
SELECT ALL - + col1 * 73 + - col2 FROM tab0 AS cor0
----
-6311
-6725
-7082

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6867
SELECT DISTINCT col2 + - CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6867
SELECT DISTINCT col2 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 24 col2 FROM tab1
----
24
24
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 13 col2 FROM tab2
----
-13
-13
-13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - col0 col2 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT - col2 * col0 + + col2 * col1 FROM tab2
----
-2356
-494
648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6872
SELECT + + col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6872
SELECT + + col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + col0 + - 16 FROM tab0 AS cor0
----
-18
-78
-78

query I rowsort
SELECT + col2 + col0 - + col2 AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - col1 * - ( - col0 ) + + col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + col0 + ( col0 ) * + cor0.col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT + col0 + 34 FROM tab0 AS cor0
----
123
58
69

query I rowsort
SELECT + + col2 * - col1 - - col2 AS col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL col0 * col1 + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL col2 * - 85 FROM tab1 AS cor0
----
-4590
-4845
-8160

query I rowsort
SELECT DISTINCT - cor0.col0 + + 59 FROM tab2 AS cor0
----
-19
-20
52

query I rowsort
SELECT + col2 * ( - col2 ) + + col0 + col1 FROM tab1 AS cor0
----
-2887
-3175
-9123

query I rowsort
SELECT col0 + + ( col2 * col1 ) + + col1 AS col0 FROM tab0 AS cor0
----
229
2948
7642

query I rowsort
SELECT DISTINCT + col0 + - 21 FROM tab1 AS cor0
----
-18
43
59

query I rowsort
SELECT col2 + - ( col0 ) * - col1 AS col1 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT ALL + col2 * 55 + 53 FROM tab1 AS cor0
----
3023
3188
5333

query I rowsort
SELECT ALL - col0 + - 41 * - col2 + col2 AS col1 FROM tab0 AS cor0
----
1362
3355
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6888
SELECT DISTINCT - col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6888
SELECT DISTINCT - col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - 37 + cor0.col2 FROM tab2 AS cor0
----
-10
-11
1

query I rowsort
SELECT ALL + col0 * col0 + - col0 AS col2 FROM tab2 AS cor0
----
42
6006
6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-6891
SELECT DISTINCT + 66 DIV + col1 + col1 FROM tab2 AS cor0
----
20
33
60

skipif mysql # not compatible
query I rowsort label-6891
SELECT DISTINCT + 66 / + col1 + col1 FROM tab2 AS cor0
----
20
33
60

query I rowsort
SELECT ALL + - ( - col1 ) AS col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6893
SELECT - + 34 DIV + col2 + + 29 * - ( - col0 ) * col0 AS col1 FROM tab1 AS cor0
----
118784
185600
261

skipif mysql # not compatible
query I rowsort label-6893
SELECT - + 34 / + col2 + + 29 * - ( - col0 ) * col0 AS col1 FROM tab1 AS cor0
----
118784
185600
261

onlyif mysql # use DIV operator for integer division
query I rowsort label-6894
SELECT ALL 25 - - col0 DIV col1 FROM tab0 AS cor0
----
25
25
25

skipif mysql # not compatible
query I rowsort label-6894
SELECT ALL 25 - - col0 / col1 FROM tab0 AS cor0
----
25
25
25

query I rowsort
SELECT ALL - - ( col2 ) + - col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL 65 * col0 - 75 AS col1 FROM tab0 cor0
----
1485
2200
5710

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6897
SELECT - col1 / col1 + CAST( NULL AS SIGNED ) * - col1 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6897
SELECT - col1 / col1 + CAST ( NULL AS INTEGER ) * - col1 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + - 24 AS col2 FROM tab2 AS cor0
----
-50
-51
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6899
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6899
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT + + 24 FROM tab1, tab0, tab1 AS cor0
----
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-6901
SELECT - cor0.col2 DIV - col0 AS col1 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6901
SELECT - cor0.col2 / - col0 AS col1 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT DISTINCT + + col2 + - col1 AS col2 FROM tab2 cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-6903
SELECT DISTINCT - - col2 + - col2 DIV + col2 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-6903
SELECT DISTINCT - - col2 + - col2 / + col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT DISTINCT - col2 * col0 + - col2 * - col2 FROM tab1 AS cor0
----
-399
1536
2754

onlyif mysql # use DIV operator for integer division
query I rowsort label-6905
SELECT DISTINCT + + ( col1 ) + - col1 DIV col0 AS col0 FROM tab1 AS cor0
----
10
13
18

skipif mysql # not compatible
query I rowsort label-6905
SELECT DISTINCT + + ( col1 ) + - col1 / col0 AS col0 FROM tab1 AS cor0
----
10
13
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-6906
SELECT + + col1 DIV + 3 AS col2 FROM tab2 AS cor0
----
10
19
5

skipif mysql # not compatible
query I rowsort label-6906
SELECT + + col1 / + 3 AS col2 FROM tab2 AS cor0
----
10
19
5

query I rowsort
SELECT ALL - + 76 FROM tab1 AS cor0
----
-76
-76
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6908
SELECT - - CAST( - 1 AS SIGNED ) * col0 * + cor0.col2 + + col2 AS col2 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif mysql # not compatible
query I rowsort label-6908
SELECT - - CAST ( - 1 AS INTEGER ) * col0 * + cor0.col2 + + col2 AS col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT col1 * 74 FROM tab1 AS cor0
----
1924
740
962

onlyif mysql # use DIV operator for integer division
query I rowsort label-6910
SELECT + col0 DIV + tab0.col1 + - 62 AS col0 FROM tab0
----
-62
-62
-62

skipif mysql # not compatible
query I rowsort label-6910
SELECT + col0 / + tab0.col1 + - 62 AS col0 FROM tab0
----
-62
-62
-62

query I rowsort
SELECT DISTINCT col2 * + col0 + + tab1.col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT 41 * - 61 - col0 FROM tab2 AS cor0
----
-2508
-2579
-2580

query I rowsort
SELECT ALL 70 AS col0 FROM tab1 cor0
----
70
70
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6914
SELECT + cor0.col0 DIV + 27 + col1 AS col0 FROM tab1 AS cor0
----
12
15
26

skipif mysql # not compatible
query I rowsort label-6914
SELECT + cor0.col0 / + 27 + col1 AS col0 FROM tab1 AS cor0
----
12
15
26

query I rowsort
SELECT ALL cor0.col0 * + col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - 44 * + col2 - + col2 AS col0 FROM tab1 AS cor0
----
-2430
-2565
-4320

query I rowsort
SELECT DISTINCT + cor0.col1 * + 45 AS col1 FROM tab0 AS cor0
----
3870
4095
4365

skipif mysql # not compatible
query I rowsort
SELECT ALL - 12 + - ( + col0 ) * + CAST ( + col1 AS REAL ) * - col2 FROM tab1 AS cor0
----
36468
4200
99828

query I rowsort
SELECT 66 * - col0 FROM tab2
----
-462
-5148
-5214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col0 FROM tab0, tab2, tab2 AS cor0, tab1
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6921
SELECT ( col0 ) DIV - col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6921
SELECT ( col0 ) / - col0 FROM tab1
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6922
SELECT ALL - CAST( 27 AS SIGNED ) + col0 DIV + col1 FROM tab0
----
-27
-27
-27

skipif mysql # not compatible
query I rowsort label-6922
SELECT ALL - CAST ( 27 AS INTEGER ) + col0 / + col1 FROM tab0
----
-27
-27
-27

query I rowsort
SELECT - - cor0.col0 + cor0.col0 * cor0.col2 + - col2 AS col0 FROM tab1 AS cor0
----
111
3655
7664

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6924
SELECT ALL CAST( NULL AS SIGNED ) col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6924
SELECT ALL CAST ( NULL AS INTEGER ) col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 57 AS col0 FROM tab1
----
57
57
57

query I rowsort
SELECT - 71 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6927
SELECT DISTINCT + CAST( + 38 AS SIGNED ) col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6927
SELECT DISTINCT + CAST ( + 38 AS INTEGER ) col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
38

query I rowsort
SELECT DISTINCT - tab0.col1 + + 67 * - 53 AS col0 FROM tab0, tab0 cor0
----
-3637
-3642
-3648

query I rowsort
SELECT + col0 * col2 - - 86 * cor0.col2 AS col0 FROM tab1 AS cor0
----
15936
4806
8550

query I rowsort
SELECT 30 * col1 + col2 FROM tab2 AS cor0
----
1796
548
957

onlyif mysql # use DIV operator for integer division
query I rowsort label-6931
SELECT - col0 + col2 + - 46 DIV col0 FROM tab1 AS cor0
----
-7
16
36

skipif mysql # not compatible
query I rowsort label-6931
SELECT - col0 + col2 + - 46 / col0 FROM tab1 AS cor0
----
-7
16
36

query I rowsort
SELECT DISTINCT cor0.col0 * col0 * + col1 + + col1 * col2 FROM tab0 AS cor0
----
118922
52374
728273

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6933
SELECT DISTINCT - col2 + CAST( - col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-52
-54
-76

skipif mysql # not compatible
query I rowsort label-6933
SELECT DISTINCT - col2 + CAST ( - col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - + cor0.col2 + + cor0.col0 * 17 AS col0 FROM tab0 cor0
----
1431
375
594

query I rowsort
SELECT DISTINCT cor0.col1 * col1 + 41 + col0 AS col1 FROM tab0 AS cor0
----
7461
8411
9485

onlyif mysql # use DIV operator for integer division
query I rowsort label-6936
SELECT ALL col2 + col0 * 30 DIV + col0 + + col2 AS col2 FROM tab2 AS cor0
----
106
82
84

skipif mysql # not compatible
query I rowsort label-6936
SELECT ALL col2 + col0 * 30 / + col0 + + col2 AS col2 FROM tab2 AS cor0
----
106
82
84

query I rowsort
SELECT - cor0.col1 + - ( - col0 ) * cor0.col0 * + 88 FROM tab1 AS cor0
----
360438
563187
766

onlyif mysql # use DIV operator for integer division
query I rowsort label-6938
SELECT + - col0 DIV 12 AS col1 FROM tab0 AS cor0
----
-2
-2
-7

skipif mysql # not compatible
query I rowsort label-6938
SELECT + - col0 / 12 AS col1 FROM tab0 AS cor0
----
-2
-2
-7

query I rowsort
SELECT - col2 + 79 FROM tab0 AS cor0
----
-3
46
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6940
SELECT - 95 DIV + 54 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6940
SELECT - 95 / + 54 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 50 col1 FROM tab0
----
-50

query I rowsort
SELECT DISTINCT + col1 + + col0 * - 38 AS col1 FROM tab1 AS cor0
----
-2422
-3027
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6943
SELECT + col1 DIV 70 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6943
SELECT + col1 / 70 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6944
SELECT ALL col0 DIV + col0 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6944
SELECT ALL col0 / + col0 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT - col2 + - 39 * ( col1 ) * - 34 + - col0 AS col2 FROM tab1 AS cor0
----
13139
17062
34419

query I rowsort
SELECT ALL - 13 * + col0 AS col0 FROM tab2
----
-1014
-1027
-91

query I rowsort
SELECT DISTINCT + 70 + - col2 + col2 AS col0 FROM tab0
----
70

query I rowsort
SELECT + col1 + col2 * + 63 * + col2 FROM tab2
----
42647
45958
90989

onlyif mysql # use DIV operator for integer division
query I rowsort label-6949
SELECT DISTINCT + col0 * - tab1.col2 + 39 + col1 DIV col1 AS col2 FROM tab1
----
-122
-3608
-7640

skipif mysql # not compatible
query I rowsort label-6949
SELECT DISTINCT + col0 * - tab1.col2 + 39 + col1 / col1 AS col2 FROM tab1
----
-122
-3608
-7640

query I rowsort
SELECT DISTINCT + 3 * + tab2.col1 + + col0 FROM tab2
----
100
130
255

query I rowsort
SELECT + col2 * tab1.col0 + 14 AS col2 FROM tab1
----
176
3662
7694

query I rowsort
SELECT - 79 FROM tab2, tab1 cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + - col0 * + ( col0 ) col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL + col0 * + 98 * col2 AS col1 FROM tab0 AS cor0
----
3430
715204
77616

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6955
SELECT col0 * + CAST( NULL AS DECIMAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6955
SELECT col0 * + CAST ( NULL AS REAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 * + col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - col1 * + 83 FROM tab0 AS cor0
----
-7138
-7553
-8051

query I rowsort
SELECT + col1 * 37 + col2 AS col1 FROM tab2 cor0
----
1174
2209
667

query I rowsort
SELECT DISTINCT - - cor0.col2 * 71 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
2343
5822
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6960
SELECT DISTINCT CAST( - 22 * - col0 AS SIGNED ) - + col2 col1 FROM tab1
----
12
1351
1664

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6960
SELECT DISTINCT CAST ( - 22 * - col0 AS INTEGER ) - + col2 col1 FROM tab1
----
12
1351
1664

query I rowsort
SELECT - ( 50 ) FROM tab0
----
-50
-50
-50

query I rowsort
SELECT + - 60 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-34
-47
-50

query I rowsort
SELECT + + 41 + - 69 - cor0.col1 * - col1 AS col1 FROM tab2 AS cor0
----
261
3453
933

query I rowsort
SELECT col1 + + 61 AS col2 FROM tab1 AS cor0
----
71
74
87

query I rowsort
SELECT - 21 * cor0.col0 + ( col2 + + col2 ) FROM tab1 AS cor0
----
-1230
-1488
45

query I rowsort
SELECT ( col1 ) + + col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6967
SELECT + 78 DIV + tab0.col1 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-6967
SELECT + 78 / + tab0.col1 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 cor0, tab2, tab2 cor1
----
972 values hashing to 64ce0e736818e884f0a9ecd075da5eb7

query I rowsort
SELECT DISTINCT - 80 FROM tab0 cor0
----
-80

query I rowsort
SELECT ALL - 67 * col2 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
-3644
-3829
-6445

query I rowsort
SELECT - 3 * - col1 + col1 AS col0 FROM tab2 AS cor0
----
124
236
68

query I rowsort
SELECT ALL - col0 * + col0 * - col0 AS col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT ALL col1 + + cor0.col1 * 81 + col2 AS col1 FROM tab0 AS cor0
----
7085
7544
7955

query I rowsort
SELECT DISTINCT - col2 + col1 * ( - col2 ) FROM tab2 AS cor0
----
-1560
-684
-864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6975
SELECT - cor0.col0 + + col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6975
SELECT - cor0.col0 + + col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + - tab2.col0 * col1 FROM tab2
----
-1305
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 * + cor0.col0 col0 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT + - ( col2 ) * + col2 + - ( - cor0.col2 + col0 ) FROM tab0 AS cor0
----
-1080
-35
-6731

query I rowsort
SELECT DISTINCT + 43 AS col0 FROM tab2 cor0
----
43

query I rowsort
SELECT + + 39 * 55 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a165537ad82d9e4190f5c1990a54dd2f

query I rowsort
SELECT DISTINCT col0 + col0 * + col2 FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT ALL + + 54 * - cor0.col2 + col2 - - cor0.col2 AS col0 FROM tab0 AS cor0
----
-1716
-4264
-52

query I rowsort
SELECT ALL - + ( - cor0.col2 ) * col2 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 39 * + cor0.col2 - ( col1 ) col2 FROM tab1 AS cor0
----
-2132
-2233
-3757

query I rowsort
SELECT - 75 * col0 + 39 AS col0 FROM tab0 AS cor0
----
-1761
-2586
-6636

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( col1 ) + + 32 col2 FROM tab0 AS cor0
----
118
123
129

query I rowsort
SELECT + - col0 + - cor0.col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT col2 + col2 + + col2 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT ALL + - 3 + cor0.col1 FROM tab2 AS cor0
----
14
28
56

query I rowsort
SELECT - col1 - - col2 * - 2 FROM tab0 AS cor0
----
-152
-255
-99

query I rowsort
SELECT DISTINCT - ( col2 ) + ( - ( - col0 ) ) FROM tab0 cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6992
SELECT DISTINCT - col1 * col2 - CAST( - col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif mysql # not compatible
query I rowsort label-6992
SELECT DISTINCT - col1 * col2 - CAST ( - col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT + + cor0.col1 * col1 + col2 AS col1 FROM tab2 cor0
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 90 * + col2 col0 FROM tab1 AS cor0
----
4860
5130
8640

query I rowsort
SELECT - + 40 - + col2 FROM tab0 AS cor0
----
-122
-41
-73

query I rowsort
SELECT DISTINCT - + 13 + cor0.col2 AS col0 FROM tab1 AS cor0
----
41
44
83

query I rowsort
SELECT ALL + - col2 * col2 + col1 AS col0 FROM tab1 AS cor0
----
-2890
-3239
-9203

onlyif mysql # use DIV operator for integer division
query I rowsort label-6998
SELECT + col0 * - col0 + + col0 DIV col1 FROM tab2 AS cor0
----
-49
-6083
-6237

skipif mysql # not compatible
query I rowsort label-6998
SELECT + col0 * - col0 + + col0 / col1 FROM tab2 AS cor0
----
-49
-6083
-6237

query I rowsort
SELECT + col0 + 32 AS col1 FROM tab1 AS cor0
----
112
35
96

query I rowsort
SELECT cor0.col0 AS col1 FROM tab2, tab1 cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL col0 + - col0 * 82 FROM tab0 AS cor0
----
-1944
-2835
-7209

query I rowsort
SELECT DISTINCT + - col0 * ( + col1 ) - col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT + ( + 63 ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT DISTINCT + 34 AS col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
34

query I rowsort
SELECT ALL col2 * col0 + - ( col1 ) AS col2 FROM tab0
----
-62
706
7207

query I rowsort
SELECT ALL 62 * col1 + 35 FROM tab1
----
1647
655
841

onlyif mysql # use DIV operator for integer division
query I rowsort label-7007
SELECT ALL col1 DIV - 29 FROM tab0 AS cor0
----
-2
-3
-3

skipif mysql # not compatible
query I rowsort label-7007
SELECT ALL col1 / - 29 FROM tab0 AS cor0
----
-2
-3
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 17 * + col1 col2 FROM tab2 AS cor0
----
1003
289
527

query I rowsort
SELECT + cor0.col0 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT + ( col0 ) * - col0 AS col0 FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7011
SELECT ALL + CAST( NULL AS DECIMAL ) + - 29 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7011
SELECT ALL + CAST ( NULL AS REAL ) + - 29 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 43 + 72 FROM tab2
----
115
115
115

query I rowsort
SELECT 4 + 63 AS col0 FROM tab2
----
67
67
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 * + col0 ) col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT + ( + 97 ) * col0 * + 84 FROM tab0
----
195552
285180
725172

query I rowsort
SELECT DISTINCT ( - col2 ) AS col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT + col2 + + col0 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + ( col1 * - col0 ) AS col2 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 45 col2 FROM tab2
----
-45
-45
-45

query I rowsort
SELECT - 62 FROM tab1, tab0 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT - - ( cor0.col0 ) FROM tab1, tab2 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT DISTINCT - 1 FROM tab1, tab0 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - col1 + + ( 78 ) AS col2 FROM tab2 AS cor0
----
19
47
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-7024
SELECT ALL + - col2 + - 28 DIV - cor0.col1 FROM tab2 AS cor0
----
-26
-27
-37

skipif mysql # not compatible
query I rowsort label-7024
SELECT ALL + - col2 + - 28 / - cor0.col1 FROM tab2 AS cor0
----
-26
-27
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col2 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col2 + + ( ( + col0 ) + - col0 ) * 25 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 * col2 + - col0 * col2 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT col1 + + 51 * + col1 + col1 AS col0 FROM tab1 cor0
----
1378
530
689

query I rowsort
SELECT - + 91 - col2 AS col2 FROM tab1 cor0
----
-145
-148
-187

query I rowsort
SELECT cor0.col0 + - cor0.col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT col0 * - col1 + col1 * - ( col0 ) + col2 * col1 FROM tab2 AS cor0
----
-2040
-7670
403

query I rowsort
SELECT ALL 22 - col1 AS col1 FROM tab1 cor0
----
-4
12
9

query I rowsort
SELECT DISTINCT 63 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
63

query I rowsort
SELECT DISTINCT ( - col0 ) * col1 - cor0.col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL + - 33 FROM tab0 AS cor0
----
-33
-33
-33

query I rowsort
SELECT + - ( - cor0.col0 ) * 68 FROM tab1 AS cor0
----
204
4352
5440

query I rowsort
SELECT DISTINCT - cor0.col1 * + col1 * col1 AS col2 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT ALL + + ( + col1 ) * + col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-7039
SELECT ALL - col2 DIV 6 FROM tab1 AS cor0
----
-16
-9
-9

skipif mysql # not compatible
query I rowsort label-7039
SELECT ALL - col2 / 6 FROM tab1 AS cor0
----
-16
-9
-9

query I rowsort
SELECT 34 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT 30 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT - + col0 * col2 AS col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT + col1 + ( ( + cor0.col2 ) ) FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7044
SELECT - - col0 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7044
SELECT - - col0 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 cor0, tab2 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 7e572cf6967c395d92dce41dcb35c4db

query I rowsort
SELECT DISTINCT + col2 + - col0 * - col2 + col0 FROM tab1 AS cor0
----
219
3769
7856

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * + 31 * - col2 col1 FROM tab1 AS cor0
----
-100719
-285696
-90396

query I rowsort
SELECT + + cor0.col1 * cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - - 30 * 56 AS col1 FROM tab1 AS cor0
----
1680
1680
1680

query I rowsort
SELECT DISTINCT col2 * 12 AS col1 FROM tab2
----
312
324
456

query I rowsort
SELECT DISTINCT + ( col0 ) + col1 * - col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT col2 + + col2 + col1 AS col1 FROM tab0 cor0
----
152
255
99

query I rowsort
SELECT DISTINCT 71 - 15 AS col2 FROM tab0 AS cor0
----
56

query I rowsort
SELECT - 51 + + col2 FROM tab0 AS cor0
----
-18
-50
31

query I rowsort
SELECT + + ( + cor0.col2 ) * cor0.col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7056
SELECT col0 * col0 + - CAST( - col1 AS SIGNED ) * col1 + col2 col2 FROM tab0 AS cor0
----
10635
16284
8005

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7056
SELECT col0 * col0 + - CAST ( - col1 AS INTEGER ) * col1 + col2 col2 FROM tab0 AS cor0
----
10635
16284
8005

query I rowsort
SELECT col0 * 73 AS col0 FROM tab1
----
219
4672
5840

onlyif mysql # use DIV operator for integer division
query I rowsort label-7058
SELECT - col0 DIV col1 + 75 AS col1 FROM tab1 AS cor0
----
69
69
75

skipif mysql # not compatible
query I rowsort label-7058
SELECT - col0 / col1 + 75 AS col1 FROM tab1 AS cor0
----
69
69
75

query I rowsort
SELECT - col0 + - col0 + col1 FROM tab2 AS cor0
----
-141
-97
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-7060
SELECT ALL - col0 DIV cor0.col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7060
SELECT ALL - col0 / cor0.col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - - col0 + col0 FROM tab2 cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 - col2 col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL cor0.col0 * - col2 + col2 AS col0 FROM tab2 cor0
----
-162
-2002
-2964

query I rowsort
SELECT + col2 + + cor0.col0 + - cor0.col1 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT DISTINCT - - col0 * + cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + cor0.col2 * col0 * col0 AS col0 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT ALL tab0.col2 + col0 - col0 FROM tab0
----
1
33
82

query I rowsort
SELECT - cor0.col1 * - col0 - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT col2 + - col1 + - col0 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-193
-2061
-2981

query I rowsort
SELECT tab0.col0 * tab0.col0 * col1 AS col1 FROM tab0
----
118825
49536
720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col2 + + col0 col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT - col1 * col2 + col0 * col0 AS col0 FROM tab0
----
-2262
1128
459

query I rowsort
SELECT ALL - col2 * + col1 + + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-7074
SELECT DISTINCT - 27 DIV col0 AS col0 FROM tab1
----
-9
0

skipif mysql # not compatible
query I rowsort label-7074
SELECT DISTINCT - 27 / col0 AS col0 FROM tab1
----
-9
0

query I rowsort
SELECT + col0 + col1 + + col1 FROM tab1
----
106
55
84

query I rowsort
SELECT col0 * col0 * + col2 AS col2 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT tab1.col2 * + col1 - + tab1.col2 FROM tab1
----
1152
1350
513

query I rowsort
SELECT col0 * + col1 + col1 * + col1 FROM tab2
----
1178
1632
8083

onlyif mysql # use DIV operator for integer division
query I rowsort label-7079
SELECT tab2.col0 * + col1 + col1 DIV col1 FROM tab2
----
1344
218
4603

skipif mysql # not compatible
query I rowsort label-7079
SELECT tab2.col0 * + col1 + col1 / col1 FROM tab2
----
1344
218
4603

query I rowsort
SELECT ALL + col2 - col1 * + col2 * + col0 AS col1 FROM tab0
----
-3394
-664036
-68079

onlyif mysql # use DIV operator for integer division
query I rowsort label-7081
SELECT DISTINCT - col1 - col2 DIV + col1 FROM tab2
----
-19
-31
-59

skipif mysql # not compatible
query I rowsort label-7081
SELECT DISTINCT - col1 - col2 / + col1 FROM tab2
----
-19
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-7082
SELECT DISTINCT - col0 + col0 - - col2 DIV col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-7082
SELECT DISTINCT - col0 + col0 - - col2 / col0 FROM tab1
----
0
1
18

query I rowsort
SELECT + col1 + - col1 * + col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + col0 + - col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT + - col1 * - cor0.col0 AS col0 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-7086
SELECT + col0 DIV cor0.col0 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7086
SELECT + col0 / cor0.col0 AS col2 FROM tab1 AS cor0
----
1
1
1

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT IN ( + tab2.col0 + + col2 )
----

query I rowsort
SELECT ALL col0 + + tab2.col0 * col2 AS col2 FROM tab2
----
196
2106
3081

query III rowsort
SELECT * FROM tab1 WHERE col1 NOT IN ( + col2 * tab1.col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT col2 * col1 + + col0 AS col1 FROM tab1
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-7091
SELECT col0 DIV col1 + col0 - col2 * - col0 FROM tab2
----
196
2107
3085

skipif mysql # not compatible
query I rowsort label-7091
SELECT col0 / col1 + col0 - col2 * - col0 FROM tab2
----
196
2107
3085

query I rowsort
SELECT DISTINCT - col1 FROM tab0 WHERE col2 BETWEEN col2 * col0 AND ( NULL )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT col0 IN ( col0 * col0 + col2 * - col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 + col2 col0 FROM tab2
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-7095
SELECT ALL - col2 DIV - col2 + - tab0.col1 FROM tab0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-7095
SELECT ALL - col2 / - col2 + - tab0.col1 FROM tab0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT + col0 FROM tab0 WHERE + col1 NOT IN ( + col1 / tab0.col2 )
----
24
89

query I rowsort
SELECT ALL tab1.col2 + tab1.col0 * - col0 * col0 AS col2 FROM tab1
----
-262087
-511904
27

query I rowsort
SELECT + col1 + tab2.col2 AS col0 FROM tab2
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT + 41 + cor0.col1 * 93 FROM tab2 AS cor0
----
1622
2924
5528

query I rowsort
SELECT ( - col2 ) * col1 + + col2 * col0 AS col0 FROM tab1 AS cor0
----
-1242
3078
6432

onlyif mysql # use DIV operator for integer division
query I rowsort label-7102
SELECT + - col1 DIV cor0.col2 + 46 + col1 AS col2 FROM tab0 cor0
----
130
136
46

skipif mysql # not compatible
query I rowsort label-7102
SELECT + - col1 / cor0.col2 + 46 + col1 AS col2 FROM tab0 cor0
----
130
136
46

query I rowsort
SELECT ALL + - col2 * cor0.col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - + 31 * col2 FROM tab1 AS cor0
----
-1674
-1767
-2976

query I rowsort
SELECT DISTINCT + cor0.col1 + + col1 * + col1 AS col2 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT - col2 + + cor0.col2 * - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT DISTINCT - 19 * - col0 + + ( col1 ) AS col1 FROM tab1 AS cor0
----
1226
1533
83

query I rowsort
SELECT + - 82 * - col0 + col2 * col0 + col0 FROM tab1 AS cor0
----
14320
411
8960

query I rowsort
SELECT DISTINCT - 27 * - cor0.col1 FROM tab0 AS cor0
----
2322
2457
2619

query I rowsort
SELECT + + 3 + + col0 * - ( col0 ) * + col2 + + col0 FROM tab0 AS cor0
----
-1187
-18981
-649430

query I rowsort
SELECT DISTINCT - - 12 * - col0 * col2 AS col0 FROM tab1 AS cor0
----
-1944
-43776
-92160

query I rowsort
SELECT + col1 + col1 + - col1 * + col1 AS col1 FROM tab2 AS cor0
----
-255
-3363
-899

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 - col1 * + col2 col2 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7114
SELECT DISTINCT + col0 DIV - col0 + col1 * col2 AS col0 FROM tab1
----
1247
1403
569

skipif mysql # not compatible
query I rowsort label-7114
SELECT DISTINCT + col0 / - col0 + col1 * col2 AS col0 FROM tab1
----
1247
1403
569

query I rowsort
SELECT - col1 * - col1 AS col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE NOT col1 * + col0 >= NULL
----

query I rowsort
SELECT col2 - + col0 AS col1 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL col2 * col2 + col2 - col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT + col0 - + col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT tab2.col0 - + col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT - tab2.col2 - + col0 AS col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT - col1 + col2 * col1 AS col2 FROM tab1
----
1235
1378
560

query III rowsort
SELECT * FROM tab1 WHERE NULL > col2
----

query I rowsort
SELECT - col1 + + col0 * tab0.col1 AS col1 FROM tab0
----
1978
3298
8008

query III rowsort
SELECT * FROM tab0 WHERE - col0 IN ( tab0.col2 + col2 )
----

onlyif mysql # use DIV operator for integer division
query III rowsort label-7126
SELECT ALL * FROM tab0 WHERE NOT + col0 >= + col0 + col0 DIV col1
----

skipif mysql # not compatible
query III rowsort label-7126
SELECT ALL * FROM tab0 WHERE NOT + col0 >= + col0 + col0 / col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7127
SELECT col0 DIV tab2.col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7127
SELECT col0 / tab2.col0 FROM tab2
----
1
1
1

query III rowsort
SELECT ALL * FROM tab2 WHERE col1 NOT IN ( tab2.col1 * - col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-7129
SELECT tab1.col1 DIV - col1 AS col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7129
SELECT tab1.col1 / - col1 AS col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT + col0 * col0 * + tab1.col1 FROM tab1 WHERE - col1 BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT + 75 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
75

query I rowsort
SELECT DISTINCT + 6 AS col1 FROM tab1
----
6

query I rowsort
SELECT DISTINCT + 62 AS col0 FROM tab0
----
62

query I rowsort
SELECT + + 30 + col2 AS col1 FROM tab2 AS cor0
----
56
57
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-7135
SELECT ALL 97 DIV - 47 FROM tab1
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-7135
SELECT ALL 97 / - 47 FROM tab1
----
-2
-2
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 74 * col2 col0 FROM tab0
----
2442
6068
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-7137
SELECT ALL + 0 DIV + col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7137
SELECT ALL + 0 / + col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + 95 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT ( + col2 * + col1 ) + - 56 AS col1 FROM tab2
----
1478
590
781

onlyif mysql # use DIV operator for integer division
query I rowsort label-7140
SELECT - col0 DIV col1 + col1 + col2 AS col0 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-7140
SELECT - col0 / col1 + col1 + col2 AS col0 FROM tab0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 26 * col1 + - col0 col2 FROM tab1
----
196
258
673

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col1 + 64 + + col0 * col0 col0 FROM tab0
----
-296
-6756
-8120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( col2 ) col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 * 83 + col0 FROM tab0
----
2016
2940
7476

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * 56 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to b539fa0de41546446ac562bdb239e646

query I rowsort
SELECT DISTINCT - col1 * - ( + 38 ) + col2 FROM tab1 AS cor0
----
1042
437
590

query I rowsort
SELECT DISTINCT - - col2 * - col1 + + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + col2 + col1 * 84 AS col2 FROM tab1 cor0
----
1188
2238
897

query I rowsort
SELECT ALL + col2 * cor0.col2 + cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
10464
3819
4320

query I rowsort
SELECT DISTINCT col1 * - 95 AS col2 FROM tab0
----
-8170
-8645
-9215

query I rowsort
SELECT ALL + ( - 23 ) + + col0 * col0 FROM tab2 AS cor0
----
26
6061
6218

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 80 col2 FROM tab1 AS cor0
----
-80
-80
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7153
SELECT ALL - CAST( 85 AS SIGNED ) * - col0 AS col2 FROM tab2 AS cor0
----
595
6630
6715

skipif mysql # not compatible
query I rowsort label-7153
SELECT ALL - CAST ( 85 AS INTEGER ) * - col0 AS col2 FROM tab2 AS cor0
----
595
6630
6715

query I rowsort
SELECT + 30 + + col2 AS col1 FROM tab2 AS cor0
----
56
57
68

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 55 AS REAL ) + + col0 + ( - 57 ) * + col1 FROM tab1 AS cor0
----
-1424
-451
-606

onlyif mysql # use DIV operator for integer division
query I rowsort label-7156
SELECT - ( 74 ) * col0 DIV - ( - col0 ) FROM tab0 AS cor0
----
-74
-74
-74

skipif mysql # not compatible
query I rowsort label-7156
SELECT - ( 74 ) * col0 / - ( - col0 ) FROM tab0 AS cor0
----
-74
-74
-74

query I rowsort
SELECT ALL - ( col2 ) * - col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + - ( ( - col1 ) ) AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - + ( + col2 ) * col1 + - cor0.col1 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-7160
SELECT col2 DIV + 3 AS col2 FROM tab0 AS cor0
----
0
11
27

skipif mysql # not compatible
query I rowsort label-7160
SELECT col2 / + 3 AS col2 FROM tab0 AS cor0
----
0
11
27

query I rowsort
SELECT 65 + + col2 * col2 FROM tab1 AS cor0
----
2981
3314
9281

query I rowsort
SELECT ALL - col0 * 87 + col0 FROM tab2
----
-602
-6708
-6794

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7163
SELECT - CAST( 31 AS SIGNED ) + - cor0.col1 FROM tab0 AS cor0
----
-117
-122
-128

skipif mysql # not compatible
query I rowsort label-7163
SELECT - CAST ( 31 AS INTEGER ) + - cor0.col1 FROM tab0 AS cor0
----
-117
-122
-128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 58 col2 FROM tab2
----
58
58
58

query I rowsort
SELECT ( col1 * - tab0.col0 ) FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col0 * 36 AS col0 FROM tab0
----
1260
3204
864

query I rowsort
SELECT ( col1 + col2 ) * col0 AS col0 FROM tab1
----
240
4288
8720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7168
SELECT - - CAST( 40 AS SIGNED ) + + col1 AS col1 FROM tab0 AS cor0
----
126
131
137

skipif mysql # not compatible
query I rowsort label-7168
SELECT - - CAST ( 40 AS INTEGER ) + + col1 AS col1 FROM tab0 AS cor0
----
126
131
137

query I rowsort
SELECT + ( col1 ) * col1 + cor0.col0 * col0 FROM tab2 AS cor0
----
1010
6530
9565

query I rowsort
SELECT - cor0.col0 + col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - col0 * col1 + col2 * col1 FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT ( + col2 ) * col1 * tab0.col2 FROM tab0
----
611884
93654
97

query I rowsort
SELECT ( + col2 + - tab1.col0 ) AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT - 58 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT ALL + - 7 + col2 + + col0 AS col0 FROM tab2 AS cor0
----
110
27
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7176
SELECT - col0 DIV - col0 + - col2 col1 FROM tab2 AS cor0
----
-25
-26
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7176
SELECT - col0 / - col0 + - col2 col1 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT - col2 * + 49 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT + col1 - - col0 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + col0 * - 22 FROM tab1 AS cor0
----
-1408
-1760
-66

query I rowsort
SELECT + cor0.col2 + - col1 + - 22 AS col2 FROM tab0 AS cor0
----
-118
-31
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-7181
SELECT col0 DIV 80 - col2 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-7181
SELECT col0 / 80 - col2 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col0 * col0 + 66 + - 68 FROM tab0
----
-1227
-578
-7923

query I rowsort
SELECT + 12 * col0 + + col1 FROM tab0
----
1159
374
517

query I rowsort
SELECT DISTINCT col2 + - tab1.col1 AS col2 FROM tab1
----
28
47
83

query I rowsort
SELECT - col2 * ( col1 ) FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col0 * ( col2 ) * col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT col1 - + 63 * - col0 AS col2 FROM tab2
----
472
4973
4994

query I rowsort
SELECT + tab2.col1 + ( - col1 ) AS col1 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7189
SELECT ALL - col2 DIV 70 + + col2 + col1 FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-7189
SELECT ALL - col2 / 70 + + col2 + col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT col1 + - 37 * 68 FROM tab0 AS cor0
----
-2419
-2425
-2430

query I rowsort
SELECT + col1 * - 87 AS col2 FROM tab1 AS cor0
----
-1131
-2262
-870

query I rowsort
SELECT ALL col0 * - cor0.col2 AS col2 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7193
SELECT DISTINCT - col1 * CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7193
SELECT DISTINCT - col1 * CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + cor0.col0 * - col2 + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT + + col0 * - 96 AS col0 FROM tab2 cor0
----
-672
-7488
-7584

query I rowsort
SELECT DISTINCT - cor0.col1 + + col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7197
SELECT - CAST( NULL AS SIGNED ) * - 21 + + col2 * 3 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7197
SELECT - CAST ( NULL AS INTEGER ) * - 21 + + col2 * 3 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( 77 ) AS col1 FROM tab0 cor0
----
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 84 + + col0 * col1 col0 FROM tab1 AS cor0
----
1124
162
724

query I rowsort
SELECT ALL col1 - col2 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL col2 * + col2 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + + col2 + col1 col1 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT + - col0 + - ( + cor0.col2 * + ( col0 ) ) AS col1 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7204
SELECT ALL + - CAST( - col2 AS SIGNED ) + col1 * 13 FROM tab0 AS cor0
----
1151
1262
1265

skipif mysql # not compatible
query I rowsort label-7204
SELECT ALL + - CAST ( - col2 AS INTEGER ) + col1 * 13 FROM tab0 AS cor0
----
1151
1262
1265

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 38 - - col0 col0 FROM tab0 AS cor0
----
-3244
-3369
-3651

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7206
SELECT DISTINCT + CAST( NULL AS SIGNED ) + - col1 / - col1 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7206
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + - col1 / - col1 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ( + 79 ) + + cor0.col1 AS col1 FROM tab2 AS cor0
----
110
138
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7208
SELECT + col1 + - col2 DIV - col1 + tab0.col1 FROM tab0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-7208
SELECT + col1 + - col2 / - col1 + tab0.col1 FROM tab0
----
172
182
194

query I rowsort
SELECT ALL ( - col2 ) * col2 * - col2 + col0 * col0 * + ( 96 ) FROM tab2 AS cor0
----
24387
601640
654008

query I rowsort
SELECT ALL + - col1 - 13 AS col0 FROM tab2 AS cor0
----
-30
-44
-72

query I rowsort
SELECT ALL + + 64 * - col0 + cor0.col2 AS col1 FROM tab1 AS cor0
----
-138
-4039
-5024

query I rowsort
SELECT + - col1 + - col0 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + ( tab0.col2 + col0 ) AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL + 92 FROM tab2, tab2 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7215
SELECT DISTINCT col2 DIV + cor0.col0 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-7215
SELECT DISTINCT col2 / + cor0.col0 FROM tab1 cor0
----
0
1
18

query I rowsort
SELECT DISTINCT - col0 + - col2 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT ALL + + 28 + - cor0.col0 FROM tab0 AS cor0
----
-61
-7
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-7218
SELECT + col2 * cor0.col0 DIV 20 FROM tab1 AS cor0
----
182
384
8

skipif mysql # not compatible
query I rowsort label-7218
SELECT + col2 * cor0.col0 / 20 FROM tab1 AS cor0
----
182
384
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7219
SELECT ALL 63 DIV + col1 - - col2 AS col0 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7219
SELECT ALL 63 / + col1 - - col2 AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL - cor0.col0 + col1 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT DISTINCT cor0.col0 + + cor0.col0 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 40 col0 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT + col2 * 86 FROM tab0 AS cor0
----
2838
7052
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7224
SELECT - - col0 DIV + col2 AS col1 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7224
SELECT - - col0 / + col2 AS col1 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - - 97 FROM tab2, tab1, tab1 AS cor0
----
97

query I rowsort
SELECT col2 * + col1 + ( tab0.col1 ) AS col2 FROM tab0
----
194
2924
7553

query I rowsort
SELECT + col0 + - 71 FROM tab2 AS cor0
----
-64
7
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7228
SELECT ALL + col2 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7228
SELECT ALL + col2 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 + - col1 * - col1 col1 FROM tab0 AS cor0
----
7363
8199
9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * + 27 col2 FROM tab2 AS cor0
----
-1026
-702
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col0 * col0 * col0 FROM tab0 cor0
----
-13824
-42875
-704969

query I rowsort
SELECT + col2 * + ( ( + col1 ) ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - tab0.col1 * tab0.col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + 19 * - col2 AS col2 FROM tab2
----
-494
-513
-722

query I rowsort
SELECT DISTINCT - 46 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 cor2, tab1 AS cor3
----
-46

query I rowsort
SELECT 54 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT - col2 + - cor0.col1 * - 15 FROM tab0 cor0
----
1257
1283
1454

query I rowsort
SELECT DISTINCT + + col0 * col1 + col0 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT ALL - col0 + cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 * - col2 * + col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT cor0.col2 * - col0 AS col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT col0 * + 44 * - col1 AS col2 FROM tab1 cor0
----
-28160
-3432
-45760

query I rowsort
SELECT ALL - col2 * + cor0.col1 - + 70 FROM tab1 AS cor0
----
-1318
-1474
-640

query I rowsort
SELECT ALL - col2 + + 94 FROM tab2
----
56
67
68

query I rowsort
SELECT + 44 AS col1 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT DISTINCT + 11 * + col0 FROM tab2 AS cor0
----
77
858
869

onlyif mysql # use DIV operator for integer division
query I rowsort label-7248
SELECT ALL - ( + col2 ) DIV + col0 + + 66 + - col0 * col1 col0 FROM tab2 AS cor0
----
-1277
-154
-4536

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7248
SELECT ALL - ( + col2 ) / + col0 + + 66 + - col0 * col1 col0 FROM tab2 AS cor0
----
-1277
-154
-4536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + 49 col0 FROM tab1 AS cor0
----
-47
-5
-8

query I rowsort
SELECT cor0.col1 + + col2 - - col2 FROM tab2 AS cor0
----
111
85
93

query I rowsort
SELECT ALL + cor0.col0 + cor0.col0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 10977325261681ddca962e0a5d2b348b

query I rowsort
SELECT DISTINCT + 57 + - col1 AS col1 FROM tab0 AS cor0
----
-29
-34
-40

query I rowsort
SELECT - + col1 * cor0.col1 + col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT + 11 + - col1 FROM tab0 cor0
----
-75
-80
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7255
SELECT - 38 + + col2 DIV - col1 AS col2 FROM tab0 AS cor0
----
-38
-38
-38

skipif mysql # not compatible
query I rowsort label-7255
SELECT - 38 + + col2 / - col1 AS col2 FROM tab0 AS cor0
----
-38
-38
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-7256
SELECT - col0 DIV col1 col1 FROM tab2 AS cor0
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7256
SELECT - col0 / col1 col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT ALL - col1 * col1 + - col2 + + col1 AS col0 FROM tab0 AS cor0
----
-7343
-8272
-9313

query I rowsort
SELECT DISTINCT - + col0 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-7259
SELECT ALL col0 * col2 + CAST( - col0 AS SIGNED ) DIV + col1 FROM tab1 AS cor0
----
162
3642
7674

skipif mysql # not compatible
query I rowsort label-7259
SELECT ALL col0 * col2 + CAST ( - col0 AS INTEGER ) / + col1 FROM tab1 AS cor0
----
162
3642
7674

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * col1 + + col0 col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT + ( - col2 ) FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT + - 99 * col0 * col2 + + col2 FROM tab1 AS cor0
----
-15984
-361095
-760224

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( 46 AS REAL ) FROM tab2
----
46
46
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( ( - col0 ) ) + - 86 col2 FROM tab1 AS cor0
----
-150
-166
-89

query I rowsort
SELECT - - col0 + - cor0.col1 FROM tab2 cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7266
SELECT ALL + + CAST( + cor0.col0 AS SIGNED ) - + col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-7266
SELECT ALL + + CAST ( + cor0.col0 AS INTEGER ) - + col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7267
SELECT + CAST( - col2 AS SIGNED ) + + col0 col1 FROM tab1 AS cor0
----
-16
-51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7267
SELECT + CAST ( - col2 AS INTEGER ) + + col0 col1 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7268
SELECT - col2 DIV col1 + col0 FROM tab1 AS cor0
----
1
59
73

skipif mysql # not compatible
query I rowsort label-7268
SELECT - col2 / col1 + col0 FROM tab1 AS cor0
----
1
59
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-7269
SELECT + col0 DIV - cor0.col0 + col2 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-7269
SELECT + col0 / - cor0.col0 + col2 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT - ( - col1 ) + col0 + 26 * col2 AS col0 FROM tab2 AS cor0
----
1084
740
813

query I rowsort
SELECT - col0 + 55 AS col0 FROM tab1 AS cor0
----
-25
-9
52

query I rowsort
SELECT + col2 * + 59 * 0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7273
SELECT + - col0 * col0 + cor0.col2 DIV + col0 FROM tab0 AS cor0
----
-1225
-575
-7921

skipif mysql # not compatible
query I rowsort label-7273
SELECT + - col0 * col0 + cor0.col2 / + col0 FROM tab0 AS cor0
----
-1225
-575
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7274
SELECT col1 + CAST( NULL AS SIGNED ) + + col2 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7274
SELECT col1 + CAST ( NULL AS INTEGER ) + + col2 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + tab1.col2 * - 33 FROM tab1, tab1 cor0
----
9 values hashing to 1ae98b00fc45346dda555ad1945cf133

query I rowsort
SELECT ALL tab2.col1 * ( + col1 ) AS col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL col0 * - 86 * + ( + col2 ) FROM tab2
----
-16254
-174408
-258172

query I rowsort
SELECT ALL col1 + col1 AS col0 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT + - col1 * - col1 + - col1 AS col2 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT DISTINCT - col1 * ( - col2 ) - - col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + col2 + - 14 * + col1 * - col1 + - col0 * 54 AS col2 FROM tab1 AS cor0
----
-1858
-1999
9356

onlyif mysql # use DIV operator for integer division
query I rowsort label-7282
SELECT - + col1 + + 98 DIV 42 col0 FROM tab0 AS cor0
----
-84
-89
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7282
SELECT - + col1 + + 98 / 42 col0 FROM tab0 AS cor0
----
-84
-89
-95

query I rowsort
SELECT + - cor1.col0 * + cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f921d4cdc13dc0e8c0388ccf3f81ffc1

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab0, tab1 cor1
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

query I rowsort
SELECT + col0 + col0 + col0 FROM tab0 AS cor0
----
105
267
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7286
SELECT ALL - CAST( - col0 AS SIGNED ) + col1 AS col2 FROM tab2 cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-7286
SELECT ALL - CAST ( - col0 AS INTEGER ) + col1 AS col2 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT DISTINCT 84 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
84

query I rowsort
SELECT - 87 * - tab0.col0 FROM tab0
----
2088
3045
7743

onlyif mysql # use DIV operator for integer division
query I rowsort label-7289
SELECT - 9 DIV col0 + - col0 FROM tab1
----
-6
-64
-80

skipif mysql # not compatible
query I rowsort label-7289
SELECT - 9 / col0 + - col0 FROM tab1
----
-6
-64
-80

query I rowsort
SELECT + 92 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to cfcf012ce1a8dd60a7428b4ef6b95843

query I rowsort
SELECT DISTINCT 35 + + col0 AS col0 FROM tab2
----
113
114
42

query I rowsort
SELECT - 65 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 4ca93c42a91c7dff917e7b7090ba9e57

query I rowsort
SELECT ALL col1 + - col2 + + col0 AS col0 FROM tab2
----
11
111
58

query I rowsort
SELECT - cor0.col0 + - col0 * col1 + col0 * 7 AS col1 FROM tab2 AS cor0
----
-175
-4134
-869

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 90 col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to c0d96679aba507520916e8654e5a6618

onlyif mysql # use DIV operator for integer division
query I rowsort label-7296
SELECT ( - cor0.col0 ) DIV + ( - 47 ) FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-7296
SELECT ( - cor0.col0 ) / + ( - 47 ) FROM tab2 AS cor0
----
0
1
1

query I rowsort
SELECT + col1 + 0 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col0 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + + cor0.col2 * - ( + col0 ) * col0 + + 68 * + col2 FROM tab2 AS cor0
----
-156416
-234574
513

query I rowsort
SELECT cor0.col1 + - 92 + - col2 AS col2 FROM tab0 AS cor0
----
-39
-83
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7301
SELECT + + col1 * - CAST( NULL AS DECIMAL ) * col2 - + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7301
SELECT + + col1 * - CAST ( NULL AS REAL ) * col2 - + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 - cor0.col0 * - col0 AS col2 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT + col2 * + col2 AS col0 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT col1 * + ( + cor0.col0 ) FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + col0 * 78 * + col0 col2 FROM tab0 AS cor0
----
44961
617920
95551

query I rowsort
SELECT ALL ( 36 ) FROM tab1
----
36
36
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) + + col2 col2 FROM tab0
----
171
36
57

query I rowsort
SELECT - 6 AS col0 FROM tab1 cor0
----
-6
-6
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7309
SELECT cor0.col2 * - 68 + col2 DIV 93 + col2 * cor0.col0 FROM tab1 cor0
----
-228
-3510
1153

skipif mysql # not compatible
query I rowsort label-7309
SELECT cor0.col2 * - 68 + col2 / 93 + col2 * cor0.col0 FROM tab1 cor0
----
-228
-3510
1153

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + 69 ) * col1 col1 FROM tab1
----
1794
690
897

query I rowsort
SELECT DISTINCT + col1 * cor0.col2 + ( cor0.col0 ) * col0 + + col2 AS col0 FROM tab2 AS cor0
----
6925
7644
913

onlyif mysql # use DIV operator for integer division
query I rowsort label-7312
SELECT ALL cor0.col0 DIV - col0 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-7312
SELECT ALL cor0.col0 / - col0 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT - - 80 AS col0 FROM tab2 AS cor0
----
80
80
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * - col0 * - cor0.col0 + col1 col2 FROM tab2 AS cor0
----
-312
-474493
-493022

onlyif mysql # use DIV operator for integer division
query I rowsort label-7315
SELECT 71 DIV + col1 AS col0 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-7315
SELECT 71 / + col1 AS col0 FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT ALL - - col0 + + cor0.col2 * col2 FROM tab2 cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT + + col0 + cor0.col1 - + 74 FROM tab1 AS cor0
----
-45
0
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 * col0 col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + - cor0.col1 * - col1 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL + - col1 * col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + col0 * - col1 + - cor0.col0 * col0 AS col0 FROM tab1 AS cor0
----
-4736
-7440
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-7322
SELECT col2 + ( + 68 ) DIV col2 AS col1 FROM tab0 cor0
----
35
69
82

skipif mysql # not compatible
query I rowsort label-7322
SELECT col2 + ( + 68 ) / col2 AS col1 FROM tab0 cor0
----
35
69
82

query I rowsort
SELECT DISTINCT - - 32 * 5 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
160

onlyif mysql # use DIV operator for integer division
query I rowsort label-7324
SELECT col2 DIV - col2 + col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-7324
SELECT col2 / - col2 + col2 FROM tab1
----
53
56
95

query I rowsort
SELECT ALL col1 * tab1.col2 + 85 AS col1 FROM tab1
----
1333
1489
655

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col2 * col1 col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT col1 * col1 + cor0.col2 FROM tab2 AS cor0
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * - col2 + + col0 col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL - cor0.col2 - ( + col2 ) FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL - col2 + + ( + 10 ) AS col1 FROM tab0 cor0
----
-23
-72
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 + ( + 12 ) col2 FROM tab0 AS cor0
----
101
36
47

query I rowsort
SELECT + col1 * cor0.col2 * 36 + + col0 FROM tab1 AS cor0
----
20584
45008
50547

query I rowsort
SELECT - + col2 * 99 FROM tab1 AS cor0
----
-5346
-5643
-9504

query I rowsort
SELECT + col1 * + col1 * + col2 + col2 * - 99 FROM tab0 AS cor0
----
240801
670924
9310

query I rowsort
SELECT DISTINCT - col2 - ( 76 * - col2 ) FROM tab2 AS cor0
----
1950
2025
2850

query I rowsort
SELECT + col0 * + cor0.col0 + + col2 FROM tab1 AS cor0
----
4153
63
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col2 - - ( cor0.col1 ) col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + + 20 FROM tab1 AS cor0
----
20
20
20

query I rowsort
SELECT 91 FROM tab0, tab1 AS cor0, tab0 cor1, tab2 AS cor2
----
81 values hashing to 8a48d0ac75792561e233f0311a8872fd

query I rowsort
SELECT ALL + 27 + + col2 * col1 + ( + 86 ) FROM tab1 AS cor0
----
1361
1517
683

query I rowsort
SELECT cor0.col1 + - cor0.col1 * + 76 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to a77762a19d8b57fb4a2d312cd7894615

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 11 + + ( + col0 ) col1 FROM tab2 AS cor0
----
18
89
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7343
SELECT ALL + CAST( NULL AS SIGNED ) + col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7343
SELECT ALL + CAST ( NULL AS INTEGER ) + col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) * cor0.col2 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT 94 + col0 * col2 AS col1 FROM tab2 AS cor0
----
2122
283
3096

onlyif mysql # use DIV operator for integer division
query I rowsort label-7346
SELECT DISTINCT + col1 DIV - col1 AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-7346
SELECT DISTINCT + col1 / - col1 AS col2 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL - col0 + col2 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1113
-36
-6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 88 + col2 col2 FROM tab1 AS cor0
----
142
145
184

query I rowsort
SELECT - col2 * + col2 * cor0.col1 + 98 AS col1 FROM tab1 AS cor0
----
-119710
-32392
-75718

query I rowsort
SELECT ALL - ( col1 ) * col0 + + col1 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 84 + - ( col0 ) col1 FROM tab0 AS cor0
----
-5
49
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-7352
SELECT ALL - ( 56 ) DIV cor0.col1 AS col2 FROM tab2 AS cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-7352
SELECT ALL - ( 56 ) / cor0.col1 AS col2 FROM tab2 AS cor0
----
-1
-3
0

query I rowsort
SELECT DISTINCT col1 + - col0 AS col0 FROM tab1
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 + ( col2 + tab2.col0 ) * col1 col2 FROM tab2
----
10738
1271
3332

query I rowsort
SELECT DISTINCT - col0 + 89 + - col0 * col0 AS col1 FROM tab2
----
-6073
-6231
33

query I rowsort
SELECT - tab0.col2 * + 54 + + col0 * col2 FROM tab0
----
-19
-990
2870

query I rowsort
SELECT DISTINCT col0 * 21 + col2 FROM tab2
----
1664
1697
174

query I rowsort
SELECT col0 * col2 + + col2 * 45 FROM tab0 AS cor0
----
10988
2277
80

query I rowsort
SELECT DISTINCT + - 3 * col0 AS col1 FROM tab1 AS cor0
----
-192
-240
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL col1 + ( 46 ) * col1 FROM tab2 AS cor0
----
1457
2773
799

query I rowsort
SELECT ALL + - col0 + + col2 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-7363
SELECT col2 * col2 DIV + tab2.col1 FROM tab2
----
11
23
84

skipif mysql # not compatible
query I rowsort label-7363
SELECT col2 * col2 / + tab2.col1 FROM tab2
----
11
23
84

query I rowsort
SELECT - col0 + + col1 * - 64 FROM tab2 AS cor0
----
-1167
-1991
-3854

query I rowsort
SELECT 54 + 15 * + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 075fbd8631e12f684722aff86667377b

query I rowsort
SELECT col0 + + 67 + + 14 AS col0 FROM tab0
----
105
116
170

onlyif mysql # use DIV operator for integer division
query I rowsort label-7367
SELECT DISTINCT + tab2.col0 + + col1 DIV + tab2.col1 AS col1 FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-7367
SELECT DISTINCT + tab2.col0 + + col1 / + tab2.col1 AS col1 FROM tab2
----
79
8
80

query I rowsort
SELECT DISTINCT - tab1.col1 * col1 + + col1 AS col2 FROM tab1
----
-156
-650
-90

query I rowsort
SELECT ALL - 14 * cor0.col1 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 85cef78dcc79e88490bb4c4ddaeae89c

query I rowsort
SELECT DISTINCT 56 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7371
SELECT ALL + col2 / + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7371
SELECT ALL + col2 / + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7372
SELECT + col1 DIV - cor0.col2 - - 4 AS col1 FROM tab0 AS cor0
----
-93
2
3

skipif mysql # not compatible
query I rowsort label-7372
SELECT + col1 / - cor0.col2 - - 4 AS col1 FROM tab0 AS cor0
----
-93
2
3

skipif mysql # not compatible
query I rowsort
SELECT col2 * + CAST ( 49 AS REAL ) + - cor0.col0 FROM tab2 AS cor0
----
1196
1316
1783

query I rowsort
SELECT - col2 + - col1 + - col0 FROM tab0 cor0
----
-133
-143
-262

onlyif mysql # use DIV operator for integer division
query I rowsort label-7375
SELECT ALL col2 * col1 + - col0 DIV + col0 + 28 * - 89 FROM tab0
----
-2396
345
4969

skipif mysql # not compatible
query I rowsort label-7375
SELECT ALL col2 * col1 + - col0 / + col0 + 28 * - 89 FROM tab0
----
-2396
345
4969

query I rowsort
SELECT + cor0.col1 + - 0 * - col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - 9 + + col0 AS col2 FROM tab2
----
-2
69
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-7378
SELECT + + col2 + - col0 DIV + col2 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-7378
SELECT + + col2 + - col0 / + col2 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT - 45 + col2 AS col0 FROM tab1 AS cor0
----
12
51
9

query I rowsort
SELECT ALL col2 + col2 - + col1 * + 69 AS col1 FROM tab0 AS cor0
----
-5868
-6115
-6691

onlyif mysql # use DIV operator for integer division
query I rowsort label-7381
SELECT DISTINCT - - col1 DIV + cor0.col0 AS col1 FROM tab2 cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-7381
SELECT DISTINCT - - col1 / + cor0.col0 AS col1 FROM tab2 cor0
----
0
4

query I rowsort
SELECT DISTINCT - col2 + - cor0.col0 * - ( cor0.col1 ) AS col1 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT + col2 * - col2 + - ( col0 + - col0 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT ( - col1 ) + - ( + col0 ) * + col2 AS col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT - col2 + - cor0.col1 * + 6 AS col1 FROM tab2 AS cor0
----
-140
-213
-380

query I rowsort
SELECT - col1 * col0 + + col1 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

query I rowsort
SELECT col0 + + 45 * - 10 FROM tab1 AS cor0
----
-370
-386
-447

query I rowsort
SELECT - ( cor0.col0 ) + - cor0.col1 * + col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL - ( - col2 ) + col1 * + col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT cor2.col0 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT DISTINCT - cor0.col0 AS col1 FROM tab1, tab0, tab2 cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7393
SELECT + col2 * + col0 + + tab2.col0 DIV ( col1 ) + - tab2.col1 AS col0 FROM tab2
----
158
1970
2989

skipif mysql # not compatible
query I rowsort label-7393
SELECT + col2 * + col0 + + tab2.col0 / ( col1 ) + - tab2.col1 AS col0 FROM tab2
----
158
1970
2989

query I rowsort
SELECT DISTINCT + ( col2 ) + - col0 AS col2 FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-7395
SELECT col0 DIV - col2 - ( - ( col2 ) * 15 ) FROM tab1 AS cor0
----
1440
810
854

skipif mysql # not compatible
query I rowsort label-7395
SELECT col0 / - col2 - ( - ( col2 ) * 15 ) FROM tab1 AS cor0
----
1440
810
854

query I rowsort
SELECT + col0 * col0 * col0 - col0 AS col2 FROM tab0 cor0
----
13800
42840
704880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col0 + + col0 col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 61 col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT DISTINCT - col2 + + col1 * + col2 FROM tab1
----
1152
1350
513

onlyif mysql # use DIV operator for integer division
query I rowsort label-7400
SELECT 40 DIV + col0 FROM tab1
----
0
0
13

skipif mysql # not compatible
query I rowsort label-7400
SELECT 40 / + col0 FROM tab1
----
0
0
13

query I rowsort
SELECT ALL - cor0.col0 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + cor0.col1 - ( 93 * cor0.col1 ) col2 FROM tab0 AS cor0
----
-1001
-5160
-8924

query I rowsort
SELECT ALL + ( col1 ) * col0 * col1 AS col2 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT + 16 AS col2 FROM tab2, tab0 AS cor0
----
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 87 col1 FROM tab1, tab2, tab2 AS cor0
----
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-7406
SELECT ALL col0 DIV ( 68 ) - col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-79

skipif mysql # not compatible
query I rowsort label-7406
SELECT ALL col0 / ( 68 ) - col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-79

query I rowsort
SELECT - col0 * - col2 + - 75 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-5658
-7240
473

query I rowsort
SELECT 17 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT ALL - ( + col1 ) - col2 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT - col0 * col0 - + ( + 42 ) FROM tab2
----
-6126
-6283
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7411
SELECT col0 * cor0.col1 * CAST( NULL AS SIGNED ) + col2 * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7411
SELECT col0 * cor0.col1 * CAST ( NULL AS INTEGER ) + col2 * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7412
SELECT DISTINCT + col1 DIV - col0 - col0 AS col1 FROM tab2
----
-11
-78
-79

skipif mysql # not compatible
query I rowsort label-7412
SELECT DISTINCT + col1 / - col0 - col0 AS col1 FROM tab2
----
-11
-78
-79

query I rowsort
SELECT ALL + tab1.col1 - col0 FROM tab1
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - ( col2 ) ) * + col2 col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - - col2 * + ( + cor0.col2 ) + - col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-847
2816
2907

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col2 * col0 col2 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT col0 * - 61 FROM tab2 AS cor0
----
-427
-4758
-4819

query I rowsort
SELECT - ( + 98 ) AS col2 FROM tab2 AS cor0
----
-98
-98
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7419
SELECT + 43 DIV 90 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7419
SELECT + 43 / 90 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 22 * + cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 2cab1a36082b1834212aa27e0e1e0f14

query I rowsort
SELECT + + col0 + 33 * col1 * cor0.col1 AS col0 FROM tab1 cor0
----
22311
3364
5657

query I rowsort
SELECT + - 77 AS col0 FROM tab2 AS cor0
----
-77
-77
-77

query I rowsort
SELECT col2 + - 83 * + col0 FROM tab2 cor0
----
-554
-6448
-6519

query I rowsort
SELECT + + col1 + + col1 AS col0 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col2 * - col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT - col2 * - col0 - + col0 * - col2 AS col1 FROM tab1 cor0
----
15360
324
7296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * cor0.col0 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - 23 * col0 * col2 + col0 AS col0 FROM tab2
----
-4340
-46566
-68967

query I rowsort
SELECT ALL tab0.col2 * - col2 * col1 AS col1 FROM tab0
----
-611884
-93654
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7430
SELECT - col2 * col1 + tab2.col0 DIV col0 FROM tab2
----
-1533
-645
-836

skipif mysql # not compatible
query I rowsort label-7430
SELECT - col2 * col1 + tab2.col0 / col0 FROM tab2
----
-1533
-645
-836

query I rowsort
SELECT tab1.col2 * - col2 + + col1 FROM tab1
----
-2890
-3239
-9203

onlyif mysql # use DIV operator for integer division
query I rowsort label-7432
SELECT + col0 * + col1 + - cor0.col2 * + col1 DIV + col1 FROM tab1 AS cor0
----
24
583
944

skipif mysql # not compatible
query I rowsort label-7432
SELECT + col0 * + col1 + - cor0.col2 * + col1 / + col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL + col0 * + cor0.col0 + col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - - col2 - + col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT cor0.col0 * col0 * + col0 AS col2 FROM tab0 cor0
----
13824
42875
704969

query I rowsort
SELECT + cor0.col2 + - cor0.col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 9 + - ( + col1 ) - - col2 AS col0 FROM tab0
----
-105
-18
-62

query I rowsort
SELECT DISTINCT 89 - + col1 AS col2 FROM tab1
----
63
76
79

query I rowsort
SELECT DISTINCT - col1 - + 84 AS col1 FROM tab2
----
-101
-115
-143

onlyif mysql # use DIV operator for integer division
query I rowsort label-7440
SELECT ALL tab1.col1 DIV - col1 col2 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7440
SELECT ALL tab1.col1 / - col1 col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT - tab2.col2 + ( - col0 ) FROM tab2
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7442
SELECT + CAST( NULL AS SIGNED ) / - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7442
SELECT + CAST ( NULL AS INTEGER ) / - col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * ( + col0 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-7444
SELECT ALL col1 - + 78 DIV col2 FROM tab1
----
13
25
9

skipif mysql # not compatible
query I rowsort label-7444
SELECT ALL col1 - + 78 / col2 FROM tab1
----
13
25
9

query I rowsort
SELECT DISTINCT - col0 - - tab1.col2 * + col0 FROM tab1
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-7446
SELECT ALL - col0 DIV + col2 col0 FROM tab0 AS cor0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7446
SELECT ALL - col0 / + col2 col0 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT + col0 - col2 * - col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL col2 * + col2 * + col1 + - col2 FROM tab1
----
119712
32433
75762

query I rowsort
SELECT - 80 - col2 FROM tab0 AS cor0
----
-113
-162
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 14 * + cor0.col0 col2 FROM tab1 cor0
----
-1120
-42
-896

query I rowsort
SELECT col2 - + col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 84 * col1 + col0 FROM tab1 AS cor0
----
1172
2187
904

query I rowsort
SELECT col0 * + col1 - + col0 FROM tab0 AS cor0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + col1 col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT col1 * - col0 + + col0 FROM tab0 cor0
----
-2040
-3360
-8010

query I rowsort
SELECT + col2 + + cor0.col2 + + cor0.col0 FROM tab1 cor0
----
111
178
272

query I rowsort
SELECT ALL - ( cor0.col1 ) + - col0 * - col2 * - col2 FROM tab0 AS cor0
----
-132
-26222
-598527

query I rowsort
SELECT + col2 * + cor0.col1 - + col2 * + col0 AS col2 FROM tab0 AS cor0
----
164
2046
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7459
SELECT DISTINCT + 62 DIV - cor0.col1 FROM tab2 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-7459
SELECT DISTINCT + 62 / - cor0.col1 FROM tab2 AS cor0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT + 61 + cor0.col0 * col0 AS col1 FROM tab1 AS cor0
----
4157
6461
70

query I rowsort
SELECT - + col2 * - cor0.col1 + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT col0 * + col0 + col0 FROM tab2
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-7463
SELECT + col0 DIV col0 + - col0 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-7463
SELECT + col0 / col0 + - col0 FROM tab1
----
-2
-63
-79

query I rowsort
SELECT ALL tab1.col1 - + col0 AS col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT col1 * + col1 * + tab1.col0 AS col0 FROM tab1
----
13520
2028
6400

query III rowsort
SELECT * FROM tab1 WHERE col2 * + col2 + col2 + - col1 NOT IN ( + col2 + col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL col2 * + col1 + - tab2.col0 FROM tab2
----
1456
567
830

query I rowsort
SELECT - tab0.col1 + + col0 AS col2 FROM tab0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7469
SELECT + tab0.col1 DIV - col1 + col1 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-7469
SELECT + tab0.col1 / - col1 + col1 FROM tab0
----
85
90
96

query I rowsort
SELECT ALL - cor0.col0 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 col0 FROM tab2 AS cor0 WHERE NULL NOT BETWEEN col2 / - col1 AND cor0.col1
----

query I rowsort
SELECT col2 + - cor0.col2 * col2 + col0 * + col1 FROM tab0 AS cor0
----
1008
1457
3395

query I rowsort
SELECT ALL - col0 * + col0 * - col1 + col2 AS col1 FROM tab1
----
288
41017
83296

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT col1 >= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7475
SELECT - col0 DIV col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7475
SELECT - col0 / col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 * + col0 * col2 FROM tab1
----
233472
486
614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-7477
SELECT DISTINCT - col0 * - col2 * col1 + col0 DIV col1 + col1 * col2 FROM tab2
----
121187
51684
6696

skipif mysql # not compatible
query I rowsort label-7477
SELECT DISTINCT - col0 * - col2 * col1 + col0 / col1 + col1 * col2 FROM tab2
----
121187
51684
6696

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + tab2.col2 + - col1 col2 FROM tab2
----
26
27
38

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( col1 * - col1 + col1 * col2 ) NOT IN ( col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col0 * - col2 col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT + col1 * col0 + col2 FROM tab1
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-7482
SELECT ALL col0 DIV col1 + - col0 + col0 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-7482
SELECT ALL col0 / col1 + - col0 + col0 FROM tab2
----
0
1
4

query I rowsort
SELECT + col0 + - col0 * - col2 * col1 - col0 FROM tab2
----
119652
51034
5859

query III rowsort
SELECT * FROM tab2 WHERE NULL = ( - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7485
SELECT tab0.col0 * col1 DIV + col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-7485
SELECT tab0.col0 * col1 / + col1 FROM tab0
----
24
35
89

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) > ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7487
SELECT - col0 DIV - tab1.col2 + tab1.col0 FROM tab1
----
3
65
80

skipif mysql # not compatible
query I rowsort label-7487
SELECT - col0 / - tab1.col2 + tab1.col0 FROM tab1
----
3
65
80

query I rowsort
SELECT DISTINCT - col1 * col2 * - col0 + - col0 AS col1 FROM tab0 AS cor0
----
3360
664029
68088

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + cor0.col2 - + col1 * col0 FROM tab1 cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-7491
SELECT ALL - col1 DIV + col0 + col0 AS col0 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-7491
SELECT ALL - col1 / + col0 + col0 AS col0 FROM tab0 AS cor0
----
21
33
88

query I rowsort
SELECT ALL - col2 FROM tab1 WHERE NULL <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * cor0.col1 - + col1 col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT - col1 + + col0 * - col0 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT + tab2.col2 - col1 AS col0 FROM tab2
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * + col0 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - + cor0.col1 * + col1 * - col0 AS col0 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-7498
SELECT col2 * - col1 - col1 DIV col1 FROM tab2 cor0
----
-1535
-647
-838

skipif mysql # not compatible
query I rowsort label-7498
SELECT col2 * - col1 - col1 / col1 FROM tab2 cor0
----
-1535
-647
-838

query I rowsort
SELECT + col0 * col1 / - col0 + - col0 AS col1 FROM tab2 WHERE NULL = NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 col2 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-7501
SELECT - + cor0.col1 DIV - col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-7501
SELECT - + cor0.col1 / - col0 FROM tab1 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - 92 * col1 + - tab0.col0 * + col1 * col0 col1 FROM tab0
----
-1482663
-729968
-984453

onlyif mysql # use DIV operator for integer division
query I rowsort label-7503
SELECT col1 DIV ( + col2 ) col2 FROM tab0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7503
SELECT col1 / ( + col2 ) col2 FROM tab0
----
1
2
97

query I rowsort
SELECT ALL + 0 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 47 col1 FROM tab2
----
1222
1269
1786

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7506
SELECT - - col1 * 78 / col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7506
SELECT - - col1 * 78 / col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 - 76 AS col2 FROM tab2 AS cor0
----
-102
-103
-114

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 46 + + col2 col2 FROM tab1 AS cor0
----
100
103
142

query I rowsort
SELECT + 66 * - cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 6cdb498e738c54c4869be2d1e9a50bbd

query I rowsort
SELECT ( col2 ) * - 6 AS col2 FROM tab1 AS cor0
----
-324
-342
-576

query I rowsort
SELECT + cor0.col1 * - cor0.col0 + col0 AS col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT + col2 * - cor0.col2 + + ( - ( - col1 ) ) * + col0 + 41 FROM tab0 AS cor0
----
1016
1416
3435

query I rowsort
SELECT DISTINCT - col0 * - col2 + - col1 * col2 + col1 FROM tab0 cor0
----
-1960
-73
35

query I rowsort
SELECT DISTINCT col0 + - col0 * col2 * col2 FROM tab1 AS cor0
----
-207872
-737200
-8745

query I rowsort
SELECT ALL - - ( + 34 ) * col2 + col0 AS col1 FROM tab2 AS cor0
----
1371
925
962

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7516
SELECT CAST( col1 AS SIGNED ) * - col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-7516
SELECT CAST ( col1 AS INTEGER ) * - col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( col0 AS REAL ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - 90 + ( col0 ) FROM tab1 AS cor0
----
-10
-26
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-7519
SELECT ALL - col0 DIV + 42 AS col0 FROM tab1
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-7519
SELECT ALL - col0 / + 42 AS col0 FROM tab1
----
-1
-1
0

query I rowsort
SELECT cor0.col2 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL - cor0.col2 * - col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - + 32 AS col0 FROM tab1 AS cor0
----
-32
-32
-32

query I rowsort
SELECT ALL ( col2 + 9 * + col2 ) FROM tab0
----
10
330
820

onlyif mysql # use DIV operator for integer division
query I rowsort label-7524
SELECT ALL col2 DIV col1 + cor0.col2 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-7524
SELECT ALL col2 / col1 + cor0.col2 FROM tab2 AS cor0
----
26
27
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + 12 + 24 col0 FROM tab0 cor0
----
1056
1116
1188

query I rowsort
SELECT + col1 * + 19 FROM tab2 cor0
----
1121
323
589

query I rowsort
SELECT ALL col2 + - ( col0 ) FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - 21 * - col2 * 72 + col2 FROM tab0
----
124066
1513
49929

query I rowsort
SELECT ALL 21 + - col0 * + col2 FROM tab1
----
-141
-3627
-7659

query I rowsort
SELECT 40 + + col0 AS col0 FROM tab2
----
118
119
47

query I rowsort
SELECT + col1 * + tab1.col2 + - 85 + col2 FROM tab1
----
1259
1373
542

query I rowsort
SELECT ALL - col0 * - tab2.col2 + + ( col2 + col1 ) FROM tab2
----
2113
247
3057

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 col0 FROM tab1
----
50
50
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7534
SELECT DISTINCT cor0.col0 + col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7534
SELECT DISTINCT cor0.col0 + col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ( col0 ) * 80 + + col0 * col0 FROM tab1 AS cor0
----
12800
249
9216

query I rowsort
SELECT - col1 * + col0 + - col2 AS col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT ALL 30 * cor0.col1 + col2 AS col2 FROM tab1 AS cor0
----
357
486
834

onlyif mysql # use DIV operator for integer division
query I rowsort label-7538
SELECT DISTINCT col2 + col2 DIV 91 FROM tab1 cor0
----
54
57
97

skipif mysql # not compatible
query I rowsort label-7538
SELECT DISTINCT col2 + col2 / 91 FROM tab1 cor0
----
54
57
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7539
SELECT - CAST( NULL AS SIGNED ) / + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7539
SELECT - CAST ( NULL AS INTEGER ) / + col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT + 77 AS col1 FROM tab1 cor0
----
77

query I rowsort
SELECT ALL - cor0.col0 * col0 * + ( col1 ) AS col1 FROM tab1 AS cor0
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 + col0 col1 FROM tab1
----
-2913
-3185
-9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-7544
SELECT ALL + ( + col1 ) DIV 86 + col0 AS col1 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-7544
SELECT ALL + ( + col1 ) / 86 + col0 AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL - - col1 + cor0.col0 FROM tab1 cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-7546
SELECT DISTINCT - col1 DIV - col0 + - col0 DIV + col1 AS col0 FROM tab2 AS cor0
----
-1
-4
4

skipif mysql # not compatible
query I rowsort label-7546
SELECT DISTINCT - col1 / - col0 + - col0 / + col1 AS col0 FROM tab2 AS cor0
----
-1
-4
4

skipif mysql # not compatible
query I rowsort
SELECT ALL - - col0 - CAST ( + col2 AS REAL ) FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7548
SELECT DISTINCT + - col0 * CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7548
SELECT DISTINCT + - col0 * CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7549
SELECT col1 + ( + ( + col2 ) ) * CAST( - col1 AS SIGNED ) col0 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7549
SELECT col1 + ( + ( + col2 ) ) * CAST ( - col1 AS INTEGER ) col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL + col0 * - col2 + col0 AS col0 FROM tab1 cor0
----
-159
-3584
-7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * ( col0 ) col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + col1 * - tab0.col2 + - 19 FROM tab0
----
-116
-2857
-7481

query I rowsort
SELECT + - 80 AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 26dbcc98d4b4e864ffa31be685a5dfbd

query I rowsort
SELECT col0 * tab2.col2 + 6 FROM tab2
----
195
2034
3008

onlyif mysql # use DIV operator for integer division
query I rowsort label-7555
SELECT - ( col0 ) DIV + cor0.col0 col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7555
SELECT - ( col0 ) / + cor0.col0 col1 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7556
SELECT DISTINCT - CAST( - col0 AS SIGNED ) DIV col2 AS col1 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-7556
SELECT DISTINCT - CAST ( - col0 AS INTEGER ) / col2 AS col1 FROM tab0 AS cor0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 52 ) * + tab2.col0 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 60346347074ba1da9159ea5d643a1512

query I rowsort
SELECT DISTINCT ( + 94 ) AS col0 FROM tab1 cor0
----
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-7559
SELECT ALL - - 32 DIV col2 AS col1 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7559
SELECT ALL - - 32 / col2 AS col1 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col2 ) col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + cor0.col1 * 29 FROM tab0 AS cor0
----
2494
2639
2813

query I rowsort
SELECT - 62 * col1 FROM tab1 AS cor0
----
-1612
-620
-806

query I rowsort
SELECT col0 + 56 FROM tab0 AS cor0
----
145
80
91

query I rowsort
SELECT DISTINCT + + col0 * + cor0.col1 AS col2 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL col1 * col1 * - tab0.col1 AS col1 FROM tab0
----
-636056
-753571
-912673

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7566
SELECT + tab0.col1 * - CAST( NULL AS SIGNED ) FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7566
SELECT + tab0.col1 * - CAST ( NULL AS INTEGER ) FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + 30 * 25 - col0 FROM tab1
----
670
686
747

query I rowsort
SELECT DISTINCT 77 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
77

query I rowsort
SELECT + 27 AS col2 FROM tab2, tab1 cor0 CROSS JOIN tab1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT + 71 * - col0 AS col1 FROM tab1 AS cor0
----
-213
-4544
-5680

query I rowsort
SELECT - col2 * - 59 FROM tab0 AS cor0
----
1947
4838
59

query I rowsort
SELECT DISTINCT col0 - - cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT + + ( - col0 ) * + col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + - ( - cor0.col1 ) * + col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - - 84 * + col1 FROM tab0 cor0
----
7224
7644
8148

query I rowsort
SELECT + 14 + - col2 * col2 * - 38 AS col1 FROM tab1 AS cor0
----
110822
123476
350222

query I rowsort
SELECT ALL + col0 * + cor0.col2 + 46 AS col0 FROM tab1 AS cor0
----
208
3694
7726

query I rowsort
SELECT + - col2 - + col0 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - - ( col0 ) * + ( ( - col1 ) ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - + ( - col0 ) + + col2 * col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT - ( col0 ) + - col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT + col0 * + col1 - col0 AS col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + + 38 AS col0 FROM tab1 AS cor0
----
38

query I rowsort
SELECT ALL + - 94 * col1 AS col2 FROM tab0 AS cor0
----
-8084
-8554
-9118

query I rowsort
SELECT tab1.col2 * 94 AS col2 FROM tab1
----
5076
5358
9024

query I rowsort
SELECT DISTINCT + col2 * + 52 + 27 * col2 * + col0 FROM tab2 AS cor0
----
56108
6507
83030

query I rowsort
SELECT DISTINCT - 51 * + 10 FROM tab0, tab0 AS cor0
----
-510

query I rowsort
SELECT DISTINCT - cor0.col0 * 27 + + cor0.col2 FROM tab2 AS cor0
----
-162
-2080
-2095

query I rowsort
SELECT col0 * + ( 47 ) + - col2 AS col2 FROM tab1
----
2951
3664
87

query I rowsort
SELECT DISTINCT - cor1.col1 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + + ( + 22 ) col1 FROM tab2 AS cor0
----
-37
-9
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7592
SELECT DISTINCT - col2 DIV + col2 + 84 AS col1 FROM tab1 AS cor0
----
83

skipif mysql # not compatible
query I rowsort label-7592
SELECT DISTINCT - col2 / + col2 + 84 AS col1 FROM tab1 AS cor0
----
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7593
SELECT col0 * CAST( 55 AS SIGNED ) + col2 FROM tab2 AS cor0
----
412
4316
4383

skipif mysql # not compatible
query I rowsort label-7593
SELECT col0 * CAST ( 55 AS INTEGER ) + col2 FROM tab2 AS cor0
----
412
4316
4383

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7594
SELECT ALL - col0 + - CAST( col1 AS SIGNED ) * + col2 FROM tab2 AS cor0
----
-1612
-725
-844

skipif mysql # not compatible
query I rowsort label-7594
SELECT ALL - col0 + - CAST ( col1 AS INTEGER ) * + col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL + col2 + + col1 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL cor0.col0 * 5 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT ALL col0 - 31 AS col1 FROM tab0 AS cor0
----
-7
4
58

query I rowsort
SELECT col2 + 8 FROM tab1 AS cor0
----
104
62
65

query I rowsort
SELECT DISTINCT - - cor0.col2 * - cor0.col1 + ( col0 ) FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL + col1 - 40 AS col0 FROM tab2 AS cor0
----
-23
-9
19

query I rowsort
SELECT DISTINCT col2 * - 3 * 72 FROM tab2 cor0
----
-5616
-5832
-8208

query I rowsort
SELECT + - col2 + - 40 FROM tab0 AS cor0
----
-122
-41
-73

query I rowsort
SELECT DISTINCT - - col2 * cor0.col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7604
SELECT ALL + CAST( - col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-7604
SELECT ALL + CAST ( - col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - - 67 * - col1 + cor0.col0 * col0 FROM tab2 cor0
----
-2028
2131
5102

query I rowsort
SELECT tab2.col0 - - ( + col2 * col1 ) FROM tab2
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7607
SELECT - col0 * CAST( 55 + col2 AS SIGNED ) FROM tab2 AS cor0
----
-574
-6318
-7347

skipif mysql # not compatible
query I rowsort label-7607
SELECT - col0 * CAST ( 55 + col2 AS INTEGER ) FROM tab2 AS cor0
----
-574
-6318
-7347

query I rowsort
SELECT + col2 * 28 * col2 AS col0 FROM tab1 AS cor0
----
258048
81648
90972

query I rowsort
SELECT - col2 * ( col2 ) AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col2 * cor0.col1 * 42 FROM tab2 AS cor0
----
27132
35154
64428

query I rowsort
SELECT - tab0.col0 + 35 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 15d23219791fd95a9b93d8d911c07406

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7612
SELECT DISTINCT + CAST( NULL AS SIGNED ) + col2 - + cor0.col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7612
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + col2 - + cor0.col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT 29 * + 82 - - cor0.col0 AS col0 FROM tab1 AS cor0
----
2381
2442
2458

query I rowsort
SELECT ALL - col1 * 87 + + col2 AS col0 FROM tab0 AS cor0
----
-7449
-7835
-8438

query I rowsort
SELECT + col0 + col2 + col2 * col2 AS col2 FROM tab1
----
2973
3370
9392

query I rowsort
SELECT tab1.col1 AS col2 FROM tab1 WHERE NOT ( NULL ) < col0 + col0
----

query I rowsort
SELECT ALL + col1 + col2 AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT - - 89 * col2 AS col1 FROM tab1 AS cor0
----
4806
5073
8544

query I rowsort
SELECT DISTINCT + cor0.col0 * 99 AS col1 FROM tab2, tab2 cor0
----
693
7722
7821

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col2 + col0 col2 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT DISTINCT col2 * - col1 + col2 * col0 AS col1 FROM tab0
----
-164
-2046
-62

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) = col1 + - col1
----

query I rowsort
SELECT ALL ( 46 ) FROM tab2, tab1 cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7624
SELECT - col0 + col0 * + CAST( ( - col0 ) AS SIGNED ) * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7624
SELECT - col0 + col0 * + CAST ( ( - col0 ) AS INTEGER ) * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 48 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

onlyif mysql # use DIV operator for integer division
query I rowsort label-7626
SELECT col1 DIV + col1 + col0 + + 31 * + col1 AS col2 FROM tab1 AS cor0
----
375
484
810

skipif mysql # not compatible
query I rowsort label-7626
SELECT col1 / + col1 + col0 + + 31 * + col1 AS col2 FROM tab1 AS cor0
----
375
484
810

query I rowsort
SELECT ALL 98 * col2 * ( - 8 ) FROM tab2
----
-20384
-21168
-29792

query I rowsort
SELECT + - col0 + col0 * ( cor0.col2 ) FROM tab0 cor0
----
0
7209
768

query I rowsort
SELECT cor0.col2 AS col0 FROM tab0, tab2 AS cor0, tab1, tab0 cor1
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT 37 - col2 AS col0 FROM tab1
----
-17
-20
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7631
SELECT ALL + col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7631
SELECT ALL + col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 * - col1 FROM tab0 AS cor0
----
244068
679042
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7633
SELECT col1 * CAST( cor0.col0 + col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1210
1482
2288

skipif mysql # not compatible
query I rowsort label-7633
SELECT col1 * CAST ( cor0.col0 + col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT ALL 93 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

query I rowsort
SELECT ALL cor0.col2 + col1 * + col1 * col1 FROM tab2 AS cor0
----
205405
29818
4951

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - 99 col0 FROM tab0 cor0
----
-185
-190
-196

query I rowsort
SELECT - cor0.col1 + 31 + - 35 * - cor0.col1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 195375a627de64f0d81218477684e0df

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7638
SELECT + cor0.col0 * - CAST( - 90 AS SIGNED ) FROM tab0, tab2 AS cor0
----
9 values hashing to 8624d337b50d843925771a840f6703e1

skipif mysql # not compatible
query I rowsort label-7638
SELECT + cor0.col0 * - CAST ( - 90 AS INTEGER ) FROM tab0, tab2 AS cor0
----
9 values hashing to 8624d337b50d843925771a840f6703e1

query I rowsort
SELECT - 50 * col0 + + col0 FROM tab1 AS cor0
----
-147
-3136
-3920

query I rowsort
SELECT DISTINCT + col2 * col1 + - 86 FROM tab2 AS cor0
----
1448
560
751

skipif mysql # not compatible
query I rowsort
SELECT + 99 + cor0.col2 * CAST ( col0 AS REAL ) AS col2 FROM tab1 AS cor0
----
261
3747
7779

query I rowsort
SELECT ALL - col1 * col1 AS col2 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ALL cor0.col2 * + col0 + - 69 FROM tab2 AS cor0
----
120
1959
2933

query I rowsort
SELECT ALL 95 + - col0 AS col0 FROM tab2 AS cor0
----
16
17
88

query I rowsort
SELECT DISTINCT - - col2 + col0 * + 67 AS col2 FROM tab2 AS cor0
----
496
5252
5331

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7646
SELECT - 49 + - col2 * - CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7646
SELECT - 49 + - col2 * - CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to f23c9ebf4a57b11b108cf933fe3c62aa

query I rowsort
SELECT ALL + + col2 + col2 AS col1 FROM tab2 cor0
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7649
SELECT ALL + cor0.col2 DIV ( - col0 + col1 * - col2 ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7649
SELECT ALL + cor0.col2 / ( - col0 + col1 * - col2 ) FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * col2 col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + + col0 * - col1 * - cor0.col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT ALL + - col1 + ( - col0 ) AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - - 13 + col0 FROM tab1 AS cor0
----
16
77
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-7654
SELECT DISTINCT - + col0 DIV - 88 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7654
SELECT DISTINCT - + col0 / - 88 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + col2 * - 95 AS col1 FROM tab1 AS cor0
----
-5130
-5415
-9120

query I rowsort
SELECT - ( col1 ) * + col1 FROM tab1 AS cor0
----
-100
-169
-676

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 28412d50061391eec23a02d0efcfb3f9

query I rowsort
SELECT tab0.col0 + 95 FROM tab0
----
119
130
184

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col1 col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT 89 + - 31 AS col1 FROM tab1 AS cor0
----
58

query I rowsort
SELECT DISTINCT col0 + col2 + col2 * - 22 FROM tab2 AS cor0
----
-468
-560
-719

onlyif mysql # use DIV operator for integer division
query I rowsort label-7662
SELECT - col0 + col0 DIV col1 FROM tab1 AS cor0
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-7662
SELECT - col0 + col0 / col1 FROM tab1 AS cor0
----
-3
-58
-74

query I rowsort
SELECT ALL - 30 AS col2 FROM tab0
----
-30
-30
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col1 ) + - cor0.col2 * - col1 col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + 88 AS col0 FROM tab0 cor0
----
88
88
88

query I rowsort
SELECT 37 * + cor0.col2 + col1 * - col1 AS col0 FROM tab1 AS cor0
----
1322
2009
3383

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * col2 + - 80 col0 FROM tab2 AS cor0
----
-1614
-726
-917

query I rowsort
SELECT DISTINCT - cor0.col2 * + cor0.col2 * + col1 + + col1 - + col2 * ( + col1 ) FROM tab0 AS cor0
----
-619255
-96406
-97

query I rowsort
SELECT DISTINCT + 58 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
58

query I rowsort
SELECT + - col1 * col0 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 1 * col0 - - 67 * col0 AS col0 FROM tab2 AS cor0
----
462
5148
5214

query I rowsort
SELECT DISTINCT cor0.col1 + - ( + col0 ) * col1 AS col1 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT + - col2 * + col0 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - cor0.col2 + - cor0.col2 + col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL 18 AS col2 FROM tab2
----
18
18
18

query I rowsort
SELECT - - col0 * - ( 63 ) AS col2 FROM tab0 AS cor0
----
-1512
-2205
-5607

query I rowsort
SELECT DISTINCT + cor0.col1 * + col0 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-7678
SELECT ALL + col2 DIV - col0 AS col2 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7678
SELECT ALL + col2 / - col0 AS col2 FROM tab0 cor0
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7679
SELECT DISTINCT + cor0.col2 + - CAST( + ( - col0 ) AS SIGNED ) AS col2 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-7679
SELECT DISTINCT + cor0.col2 + - CAST ( + ( - col0 ) AS INTEGER ) AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - + col1 + 89 AS col1 FROM tab0 AS cor0
----
-2
-8
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7681
SELECT ALL - col0 + CAST( + 88 AS SIGNED ) DIV - col2 FROM tab1 AS cor0
----
-4
-65
-80

skipif mysql # not compatible
query I rowsort label-7681
SELECT ALL - col0 + CAST ( + 88 AS INTEGER ) / - col2 FROM tab1 AS cor0
----
-4
-65
-80

query I rowsort
SELECT ALL 53 * tab1.col0 FROM tab1
----
159
3392
4240

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 12 - + col1 col1 FROM tab0
----
-103
-109
-98

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0, tab2 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to 825c5bff5308aeedb3a0a28713da0683

query I rowsort
SELECT + col2 * ( + ( - col1 ) ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ( + 75 ) FROM tab2, tab0 cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT ALL + col2 + - col2 * col1 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-7688
SELECT ALL + col0 * ( - col0 ) + + col2 - + col0 DIV 91 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif mysql # not compatible
query I rowsort label-7688
SELECT ALL + col0 * ( - col0 ) + + col2 - + col0 / 91 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL col0 * - ( 22 ) FROM tab0 cor0
----
-1958
-528
-770

query I rowsort
SELECT - col1 + - col0 * col2 AS col2 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT col0 + - 32 AS col0 FROM tab2
----
-25
46
47

query I rowsort
SELECT ALL + tab1.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT col0 * - ( - 11 ) AS col0 FROM tab1
----
33
704
880

query I rowsort
SELECT ALL - 94 + - 77 * + tab2.col1 AS col0 FROM tab2
----
-1403
-2481
-4637

onlyif mysql # use DIV operator for integer division
query I rowsort label-7695
SELECT 99 DIV tab1.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 479fa835031c34d2797c1a275bb0a502

skipif mysql # not compatible
query I rowsort label-7695
SELECT 99 / tab1.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 479fa835031c34d2797c1a275bb0a502

query I rowsort
SELECT - cor0.col1 + col1 * 19 * col0 FROM tab0 AS cor0
----
153790
39130
64408

query I rowsort
SELECT 71 * col0 AS col1 FROM tab0 AS cor0
----
1704
2485
6319

query I rowsort
SELECT - col0 * 36 AS col2 FROM tab1
----
-108
-2304
-2880

query I rowsort
SELECT DISTINCT - 40 AS col0 FROM tab0, tab1 AS cor0
----
-40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7700
SELECT DISTINCT - CAST( NULL AS SIGNED ) + col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7700
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + col1 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7701
SELECT + col0 DIV 40 AS col1 FROM tab1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-7701
SELECT + col0 / 40 AS col1 FROM tab1
----
0
1
2

query I rowsort
SELECT ALL - ( - col1 ) + + col2 FROM tab0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7703
SELECT DISTINCT 50 + 97 + col0 * CAST( - col0 AS SIGNED ) FROM tab2
----
-5937
-6094
98

skipif mysql # not compatible
query I rowsort label-7703
SELECT DISTINCT 50 + 97 + col0 * CAST ( - col0 AS INTEGER ) FROM tab2
----
-5937
-6094
98

query I rowsort
SELECT DISTINCT - col2 * + ( + col1 ) + + 82 FROM tab0
----
-15
-2756
-7380

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7705
SELECT + 93 * col0 * - CAST( - col2 * col2 AS SIGNED ) + tab1.col2 AS col1 FROM tab1
----
19338105
68567136
813618

skipif mysql # not compatible
query I rowsort label-7705
SELECT + 93 * col0 * - CAST ( - col2 * col2 AS INTEGER ) + tab1.col2 AS col1 FROM tab1
----
19338105
68567136
813618

query I rowsort
SELECT - + col2 + + col1 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - col1 * + col1 * ( cor0.col1 ) FROM tab0 cor0
----
-636056
-753571
-912673

query I rowsort
SELECT + 59 * + col0 * + col2 + - col1 AS col1 FROM tab0 AS cor0
----
1968
430491
46642

query I rowsort
SELECT ALL + col1 + - cor0.col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - - 73 + + col1 FROM tab2 AS cor0
----
104
132
90

query I rowsort
SELECT ALL - - ( + col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - col1 + col2 * 99 FROM tab2 cor0
----
2515
2642
3745

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * - col2 col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ( + col2 ) + col1 + - col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT 45 * + col1 FROM tab1
----
1170
450
585

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 col1 FROM tab0, tab1 cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7717
SELECT CAST( 89 + - col2 AS SIGNED ) FROM tab1
----
-7
32
35

skipif mysql # not compatible
query I rowsort label-7717
SELECT CAST ( 89 + - col2 AS INTEGER ) FROM tab1
----
-7
32
35

query I rowsort
SELECT - - col0 * - 14 FROM tab1 AS cor0
----
-1120
-42
-896

query I rowsort
SELECT - col1 * 47 FROM tab0 AS cor0
----
-4042
-4277
-4559

query I rowsort
SELECT + ( - 94 ) + - col0 FROM tab0 AS cor0
----
-118
-129
-183

query I rowsort
SELECT - + 16 AS col1 FROM tab1 cor0
----
-16
-16
-16

onlyif mysql # use DIV operator for integer division
query I rowsort label-7722
SELECT col2 + col2 DIV 83 AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-7722
SELECT col2 + col2 / 83 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - 87 + + cor0.col2 + + 13 FROM tab0, tab1 AS cor0
----
9 values hashing to 43bfa75eee95922b6602fafc3c412a78

query I rowsort
SELECT DISTINCT cor0.col2 * col1 * cor0.col1 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT ALL col1 * + cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - col0 + col2 * 48 FROM tab0 AS cor0
----
13
1560
3847

query I rowsort
SELECT - + col0 + - col0 AS col1 FROM tab1 cor0
----
-128
-160
-6

query I rowsort
SELECT - col1 * 93 + + col0 FROM tab0 cor0
----
-7974
-8374
-8986

query I rowsort
SELECT DISTINCT - col2 * col0 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - col2 - - 37 AS col2 FROM tab1 cor0
----
-17
-20
-59

query I rowsort
SELECT 38 * col0 AS col1 FROM tab2
----
266
2964
3002

query I rowsort
SELECT DISTINCT + col1 * tab0.col0 + + col0 AS col1 FROM tab0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - col0 + CAST ( 7 AS REAL ) * - col0 col0 FROM tab0 cor0
----
-192
-280
-712

query I rowsort
SELECT ALL + cor0.col1 * + 95 + + col2 FROM tab2 cor0
----
1653
2972
5631

query I rowsort
SELECT DISTINCT col0 * + 59 FROM tab1 AS cor0
----
177
3776
4720

onlyif mysql # use DIV operator for integer division
query I rowsort label-7736
SELECT ( col1 ) DIV - col0 - ( - col0 ) * + col0 AS col0 FROM tab2 AS cor0
----
45
6084
6241

skipif mysql # not compatible
query I rowsort label-7736
SELECT ( col1 ) / - col0 - ( - col0 ) * + col0 AS col0 FROM tab2 AS cor0
----
45
6084
6241

query I rowsort
SELECT DISTINCT + 65 * + col2 - col1 FROM tab0 AS cor0
----
-32
2059
5239

query I rowsort
SELECT - col2 * - col2 + - col2 * col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col1 ) * cor0.col0 * + 74 col1 FROM tab2 cor0
----
16058
340548
99382

query I rowsort
SELECT DISTINCT - cor0.col0 * ( col2 ) + col0 * col0 FROM tab2 AS cor0
----
-140
3239
4056

query I rowsort
SELECT ALL 7 * - col0 - + col2 AS col0 FROM tab2 AS cor0
----
-572
-591
-76

query I rowsort
SELECT + - 12 * col2 + col0 * col1 AS col2 FROM tab0 AS cor0
----
1668
3383
7115

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7743
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + col1 col2 FROM tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7743
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + col1 col2 FROM tab1 cor0
----
NULL

query I rowsort
SELECT ALL ( + 13 ) - - col1 AS col2 FROM tab2 AS cor0
----
30
44
72

query I rowsort
SELECT ( - col2 ) * cor0.col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + 25 FROM tab0, tab2, tab2 cor0, tab1
----
25

query I rowsort
SELECT col2 * col0 * + col2 + col2 + + col2 FROM tab2
----
114152
5157
52780

query I rowsort
SELECT ALL + - 61 AS col2 FROM tab1 AS cor0
----
-61
-61
-61

query I rowsort
SELECT DISTINCT ( 29 ) FROM tab0 AS cor0
----
29

query I rowsort
SELECT ALL col1 * - 47 FROM tab1
----
-1222
-470
-611

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0, tab2, tab1 cor1
----
972 values hashing to dd771e0c15d524f62127686e9bd43f9a

query I rowsort
SELECT ALL ( col2 ) * col1 + 39 * + col0 AS col0 FROM tab2
----
1110
3727
4576

query I rowsort
SELECT ( col0 ) * - col2 + ( + 58 ) FROM tab0
----
-7240
-734
23

query I rowsort
SELECT - + 33 * cor0.col1 FROM tab0 AS cor0
----
-2838
-3003
-3201

query I rowsort
SELECT + col2 * - 70 AS col1 FROM tab2 AS cor0
----
-1820
-1890
-2660

query I rowsort
SELECT DISTINCT - - col2 * + col0 + + col1 AS col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - - col0 + - col1 * - col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col2 col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
1
33
82

query I rowsort
SELECT - 50 * col1 FROM tab1 cor0
----
-1300
-500
-650

query I rowsort
SELECT DISTINCT - + 72 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-72

query I rowsort
SELECT + col1 * - 34 AS col2 FROM tab1 cor0
----
-340
-442
-884

query I rowsort
SELECT cor0.col2 * - col0 + col0 * + col0 FROM tab2 AS cor0
----
-140
3239
4056

onlyif mysql # use DIV operator for integer division
query I rowsort label-7763
SELECT tab1.col0 DIV cor0.col2 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to cb0e6c4eb7e285d8fd00751a013cbeb6

skipif mysql # not compatible
query I rowsort label-7763
SELECT tab1.col0 / cor0.col2 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to cb0e6c4eb7e285d8fd00751a013cbeb6

query I rowsort
SELECT DISTINCT - col2 * + col2 + cor0.col0 AS col2 FROM tab1 cor0
----
-2913
-3185
-9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-7765
SELECT + cor0.col0 + 44 DIV col0 FROM tab2 AS cor0
----
13
78
79

skipif mysql # not compatible
query I rowsort label-7765
SELECT + cor0.col0 + 44 / col0 FROM tab2 AS cor0
----
13
78
79

query I rowsort
SELECT col1 * + col0 + + 65 AS col2 FROM tab1 cor0
----
1105
143
705

query I rowsort
SELECT + cor0.col0 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT col2 + col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - ( + col1 * + col0 ) + ( + col2 ) * col0 * 9 AS col2 FROM tab1
----
1380
32192
68080

query I rowsort
SELECT ( + col2 ) * + col0 AS col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL + + 49 AS col2 FROM tab0 cor0
----
49
49
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7772
SELECT + col0 * + tab0.col2 * CAST( NULL AS SIGNED ) + + 33 * col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7772
SELECT + col0 * + tab0.col2 * CAST ( NULL AS INTEGER ) + + 33 * col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 16 + col1 * + col1 FROM tab1
----
116
185
692

query I rowsort
SELECT DISTINCT 26 * + tab0.col2 * col2 AS col1 FROM tab0
----
174824
26
28314

query I rowsort
SELECT DISTINCT ( col0 ) * cor0.col0 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7776
SELECT ALL + col2 + - col1 * + CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7776
SELECT ALL + col2 + - col1 * + CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col1 * + col0 * ( + 34 ) AS col1 FROM tab0 AS cor0
----
115430
275366
70176

query I rowsort
SELECT - col2 * col2 * + col0 AS col1 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT + - col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - col2 + - col2 * col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + + col1 + - col0 * 22 AS col2 FROM tab0 AS cor0
----
-1867
-442
-673

query I rowsort
SELECT ALL - 60 + cor0.col1 * 89 + 87 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e3e2d56ab40f4d73336b1099e4c46c3f

onlyif mysql # use DIV operator for integer division
query I rowsort label-7784
SELECT DISTINCT col0 DIV - 72 + col1 AS col1 FROM tab2
----
16
31
58

skipif mysql # not compatible
query I rowsort label-7784
SELECT DISTINCT col0 / - 72 + col1 AS col1 FROM tab2
----
16
31
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-7785
SELECT + col0 DIV + 95 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7785
SELECT + col0 / + 95 FROM tab1
----
0
0
0

query I rowsort
SELECT col0 + + ( 0 ) AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL col1 + + 69 * + 24 FROM tab0
----
1742
1747
1753

query I rowsort
SELECT DISTINCT + tab2.col1 * - col1 + tab2.col0 + + col1 FROM tab2
----
-193
-3344
-923

query I rowsort
SELECT col1 * 11 FROM tab2
----
187
341
649

query I rowsort
SELECT - col2 * col0 + + tab1.col0 FROM tab1
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-7791
SELECT ALL col1 DIV col2 + - ( - col0 ) AS col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-7791
SELECT ALL col1 / col2 + - ( - col0 ) AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + col1 * + col0 + - col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL + col2 + ( + cor0.col1 ) * col0 * + cor0.col2 + - col1 * col0 FROM tab2 AS cor0
----
115076
49729
5669

query I rowsort
SELECT ALL + cor0.col2 + - col1 AS col0 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - 19 * - col1 FROM tab1 AS cor0
----
190
247
494

query I rowsort
SELECT DISTINCT - 18 + + col2 FROM tab1 AS cor0
----
36
39
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7797
SELECT - cor0.col0 DIV col2 AS col1 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7797
SELECT - cor0.col0 / col2 AS col1 FROM tab1 cor0
----
-1
0
0

query I rowsort
SELECT ALL 46 * col0 FROM tab0 AS cor0
----
1104
1610
4094

query I rowsort
SELECT - - ( 40 ) * - col0 + 57 * 46 * + col0 AS col0 FROM tab2 AS cor0
----
18074
201396
203978

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - cor0.col1 ) col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + ( - col1 ) * + col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + 1 + col0 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL + + col2 * cor0.col0 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - ( + col2 ) + col0 * - 94 AS col2 FROM tab2 AS cor0
----
-685
-7358
-7464

query I rowsort
SELECT ALL + col0 * 84 AS col2 FROM tab0 AS cor0
----
2016
2940
7476

query I rowsort
SELECT + cor0.col2 + 59 FROM tab2 cor0
----
85
86
97

query I rowsort
SELECT col2 - - col1 * 7 AS col2 FROM tab0
----
635
680
719

query I rowsort
SELECT col0 - - 43 FROM tab1
----
107
123
46

query I rowsort
SELECT DISTINCT - col0 + + ( + col1 ) AS col2 FROM tab0 AS cor0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7810
SELECT DISTINCT - CAST( 13 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-13

skipif mysql # not compatible
query I rowsort label-7810
SELECT DISTINCT - CAST ( 13 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-7811
SELECT DISTINCT - col1 * ( col1 ) DIV + col0 AS col0 FROM tab0 cor0
----
-268
-308
-93

skipif mysql # not compatible
query I rowsort label-7811
SELECT DISTINCT - col1 * ( col1 ) / + col0 AS col0 FROM tab0 cor0
----
-268
-308
-93

query I rowsort
SELECT ALL - 18 * col2 + + col0 AS col0 FROM tab0 AS cor0
----
-1387
-570
17

query I rowsort
SELECT ALL + col0 * - col0 + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1224
-543
-7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-7814
SELECT ALL + 6 * - cor0.col0 + + col2 DIV - ( - col0 ) AS col0 FROM tab0 cor0
----
-143
-210
-534

skipif mysql # not compatible
query I rowsort label-7814
SELECT ALL + 6 * - cor0.col0 + + col2 / - ( - col0 ) AS col0 FROM tab0 cor0
----
-143
-210
-534

query I rowsort
SELECT DISTINCT - cor0.col2 AS col2 FROM tab1, tab2 cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7816
SELECT col2 * - col1 + - col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7816
SELECT col2 * - col1 + - col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * col0 + - col1 AS col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT + col2 * - col2 + - col1 * + col0 * + col1 AS col2 FROM tab2 AS cor0
----
-24275
-272194
-7456

onlyif mysql # use DIV operator for integer division
query I rowsort label-7819
SELECT DISTINCT + cor0.col1 DIV + col0 + - col1 AS col0 FROM tab0 cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-7819
SELECT DISTINCT + cor0.col1 / + col0 + - col1 AS col0 FROM tab0 cor0
----
-83
-90
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7820
SELECT DISTINCT - CAST( col1 AS SIGNED ) * - cor0.col0 - 8 * + col1 AS col2 FROM tab1 AS cor0
----
-130
560
936

skipif mysql # not compatible
query I rowsort label-7820
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * - cor0.col0 - 8 * + col1 AS col2 FROM tab1 AS cor0
----
-130
560
936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 31 col2 FROM tab2
----
31
31
31

query I rowsort
SELECT ( tab2.col2 ) * + col0 AS col1 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7823
SELECT - cor0.col2 * 39 + - col0 DIV col1 FROM tab0 AS cor0
----
-1287
-3198
-39

skipif mysql # not compatible
query I rowsort label-7823
SELECT - cor0.col2 * 39 + - col0 / col1 FROM tab0 AS cor0
----
-1287
-3198
-39

query I rowsort
SELECT DISTINCT - - cor0.col0 AS col0 FROM tab2, tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - ( col1 ) * + col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - - 56 + col0 * 5 AS col2 FROM tab2 cor0
----
446
451
91

query I rowsort
SELECT - ( + col2 ) * - col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-7828
SELECT ALL - ( - col0 ) DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7828
SELECT ALL - ( - col0 ) / col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL ( - 59 ) * + col0 FROM tab2
----
-413
-4602
-4661

query I rowsort
SELECT DISTINCT + ( 1 ) AS col2 FROM tab2
----
1

query I rowsort
SELECT - - col2 * + ( + col0 ) - - col0 AS col2 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-7832
SELECT + + col1 DIV col0 + + col1 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-7832
SELECT + + col1 / col0 + + col1 FROM tab1 AS cor0
----
10
13
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7833
SELECT col2 DIV 71 - + ( - col2 ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-7833
SELECT col2 / 71 - + ( - col2 ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT col0 - - ( cor0.col0 ) * - col0 AS col1 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL - + col1 * + cor0.col1 + - 44 * col1 AS col0 FROM tab1 cor0
----
-1820
-540
-741

query I rowsort
SELECT DISTINCT + col1 - ( + col0 + + col0 ) AS col1 FROM tab1 AS cor0
----
-118
-147
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-7837
SELECT ALL - col0 DIV + col0 + 90 AS col0 FROM tab2 AS cor0
----
89
89
89

skipif mysql # not compatible
query I rowsort label-7837
SELECT ALL - col0 / + col0 + 90 AS col0 FROM tab2 AS cor0
----
89
89
89

query I rowsort
SELECT ALL + col0 * - col1 - 5 AS col1 FROM tab2 AS cor0
----
-1348
-222
-4607

query I rowsort
SELECT DISTINCT + col2 * 95 FROM tab2 AS cor0
----
2470
2565
3610

onlyif mysql # use DIV operator for integer division
query I rowsort label-7840
SELECT DISTINCT - col2 * - 7 + col2 DIV + col1 - + col2 AS col1 FROM tab1 AS cor0
----
326
347
583

skipif mysql # not compatible
query I rowsort label-7840
SELECT DISTINCT - col2 * - 7 + col2 / + col1 - + col2 AS col1 FROM tab1 AS cor0
----
326
347
583

query I rowsort
SELECT - col1 - 22 FROM tab2 AS cor0
----
-39
-53
-81

query I rowsort
SELECT ALL + col2 * - col2 + 80 FROM tab1 cor0
----
-2836
-3169
-9136

query I rowsort
SELECT col1 * + col0 - col2 * col1 AS col1 FROM tab0
----
-774
3298
637

query I rowsort
SELECT + col1 * + 61 + - col0 FROM tab1 AS cor0
----
1583
546
713

query I rowsort
SELECT - 73 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 2931474b870c05694e446771031a6949

query I rowsort
SELECT ALL + ( col0 ) * ( + col1 ) * tab0.col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT ALL - col0 * + col2 + col2 AS col2 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT ALL col0 * cor0.col1 + col1 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT col1 * - col2 * + col0 + col2 FROM tab2 AS cor0
----
-119626
-50996
-5832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7850
SELECT ALL - col0 * col1 + col1 * + col2 - + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7850
SELECT ALL - col0 * col1 + col1 * + col2 - + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * col2 * 83 AS col2 FROM tab1
----
242028
269667
764928

query I rowsort
SELECT + - 47 AS col1 FROM tab1, tab0, tab2 cor0
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

query I rowsort
SELECT - cor0.col0 + cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + - 5 FROM tab2, tab0 cor0
----
9 values hashing to 74665fbb47d5b17da011bca567195b21

query I rowsort
SELECT ALL 48 AS col2 FROM tab1
----
48
48
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-7856
SELECT - + cor0.col0 + CAST( 52 AS SIGNED ) DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-7856
SELECT - + cor0.col0 + CAST ( 52 AS INTEGER ) / cor0.col1 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT col2 + - 9 + col1 FROM tab2 AS cor0
----
46
49
76

query I rowsort
SELECT - col2 + + 7 + - 75 AS col1 FROM tab1 cor0
----
-122
-125
-164

onlyif mysql # use DIV operator for integer division
query I rowsort label-7859
SELECT - - cor0.col2 DIV 47 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7859
SELECT - - cor0.col2 / 47 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + + col2 + + 28 * col1 FROM tab1 cor0
----
337
460
782

query I rowsort
SELECT - - 44 + + col2 FROM tab0 AS cor0
----
126
45
77

query I rowsort
SELECT ALL - col2 + 22 AS col2 FROM tab1 AS cor0
----
-32
-35
-74

query I rowsort
SELECT ALL + col0 + 72 * + col1 FROM tab0 cor0
----
6216
6641
7019

query I rowsort
SELECT + + cor0.col0 * col1 * - cor0.col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7865
SELECT - + CAST( cor0.col1 AS SIGNED ) FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-7865
SELECT - + CAST ( cor0.col1 AS INTEGER ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + 51 + ( col0 ) FROM tab0 AS cor0
----
140
75
86

query I rowsort
SELECT - col0 + - col1 * - col1 AS col0 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT - col1 + - col1 * col0 + - cor0.col1 FROM tab0 AS cor0
----
-2236
-3589
-8281

query I rowsort
SELECT - - col1 * col1 + ( - col1 ) * + col2 + 43 FROM tab2 AS cor0
----
-314
167
1990

query I rowsort
SELECT - - col1 * - col0 + + col0 + + col2 * col2 FROM tab0 AS cor0
----
-1286
-3359
-951

query I rowsort
SELECT ( + cor0.col1 ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT col0 * - col0 + + col1 FROM tab1 cor0
----
-4086
-6387
17

skipif mysql # not compatible
query I rowsort
SELECT + + col0 * col0 * CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT col0 * - col1 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-7875
SELECT DISTINCT + col2 DIV col0 + 47 * 13 FROM tab2 AS cor0
----
611
614

skipif mysql # not compatible
query I rowsort label-7875
SELECT DISTINCT + col2 / col0 + 47 * 13 FROM tab2 AS cor0
----
611
614

query I rowsort
SELECT ALL - ( col0 ) * 2 * 31 FROM tab1 AS cor0
----
-186
-3968
-4960

query I rowsort
SELECT ALL - 69 FROM tab2 cor0
----
-69
-69
-69

query I rowsort
SELECT DISTINCT col1 * 40 AS col2 FROM tab1 AS cor0
----
1040
400
520

query I rowsort
SELECT ALL + 30 - col2 AS col2 FROM tab2
----
-8
3
4

query I rowsort
SELECT 52 * + 75 FROM tab1 AS cor0
----
3900
3900
3900

onlyif mysql # use DIV operator for integer division
query I rowsort label-7881
SELECT DISTINCT col2 DIV - col1 col2 FROM tab2 AS cor0
----
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7881
SELECT DISTINCT col2 / - col1 col2 FROM tab2 AS cor0
----
-2
0

query I rowsort
SELECT DISTINCT 43 AS col1 FROM tab1 AS cor0
----
43

query I rowsort
SELECT ALL - + 95 + - col0 FROM tab0 AS cor0
----
-119
-130
-184

query I rowsort
SELECT cor0.col0 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + + 57 AS col2 FROM tab0 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT + - 18 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
-18

query I rowsort
SELECT ALL - ( tab1.col1 ) * + col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT ( col0 + col0 ) AS col2 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL + 40 AS col2 FROM tab1
----
40
40
40

query I rowsort
SELECT + + 95 FROM tab2 cor0
----
95
95
95

query I rowsort
SELECT ALL - tab2.col0 * + col1 FROM tab2
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7892
SELECT + CAST( 86 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
86
86
86

skipif mysql # not compatible
query I rowsort label-7892
SELECT + CAST ( 86 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
86
86
86

query I rowsort
SELECT - ( cor0.col0 ) + - col1 * - col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT - col0 - - cor0.col0 AS col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col0 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + 49 * + ( col0 ) * + col2 AS col1 FROM tab1 AS cor0
----
178752
376320
7938

query I rowsort
SELECT DISTINCT + + 47 * - col0 + cor0.col2 * 43 AS col1 FROM tab1 AS cor0
----
-557
2181
368

query I rowsort
SELECT ALL col1 + + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT - ( - col0 ) * col2 + + col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - col1 + - col1 * col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL + - 80 + - col2 + + cor0.col2 FROM tab2 AS cor0
----
-80
-80
-80

query I rowsort
SELECT DISTINCT - - 10 * 44 FROM tab0 cor0
----
440

query I rowsort
SELECT DISTINCT - ( + 83 ) FROM tab1 AS cor0
----
-83

query I rowsort
SELECT + tab0.col0 * 25 AS col2 FROM tab0
----
2225
600
875

query I rowsort
SELECT + - col0 * col0 + col2 AS col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT - 61 + + ( col2 * 2 ) AS col1 FROM tab0 AS cor0
----
-59
103
5

query I rowsort
SELECT - col1 + - 45 * + col1 AS col1 FROM tab0 cor0
----
-3956
-4186
-4462

query I rowsort
SELECT - 29 * col2 AS col1 FROM tab1 AS cor0
----
-1566
-1653
-2784

query I rowsort
SELECT + - 17 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-34
-48
-76

query I rowsort
SELECT + + 6 * + col1 AS col1 FROM tab1 cor0
----
156
60
78

query I rowsort
SELECT - ( col2 ) * - col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col0 * cor0.col0 AS col2 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT 77 * tab1.col2 * col2 AS col2 FROM tab1
----
224532
250173
709632

query I rowsort
SELECT DISTINCT + - cor0.col1 * + col2 + - col1 AS col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT + 99 AS col2 FROM tab2
----
99

query I rowsort
SELECT cor0.col0 - 89 AS col1 FROM tab2 AS cor0
----
-10
-11
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col0 - - col1 col2 FROM tab1 AS cor0
----
106
55
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-7918
SELECT + 75 DIV col2 FROM tab0
----
0
2
75

skipif mysql # not compatible
query I rowsort label-7918
SELECT + 75 / col2 FROM tab0
----
0
2
75

query I rowsort
SELECT DISTINCT 56 * + 14 * - cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-13328
-24304
-46256

query I rowsort
SELECT ALL col1 * col0 - - cor0.col2 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT ALL - col1 + + 80 FROM tab0 AS cor0
----
-11
-17
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7922
SELECT ALL + col1 DIV - col1 - 67 * col0 * 50 FROM tab2 cor0
----
-23451
-261301
-264651

skipif mysql # not compatible
query I rowsort label-7922
SELECT ALL + col1 / - col1 - 67 * col0 * 50 FROM tab2 cor0
----
-23451
-261301
-264651

onlyif mysql # use DIV operator for integer division
query I rowsort label-7923
SELECT DISTINCT + tab2.col0 DIV + col1 + - col0 col2 FROM tab2
----
-7
-75
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7923
SELECT DISTINCT + tab2.col0 / + col1 + - col0 col2 FROM tab2
----
-7
-75
-77

query I rowsort
SELECT DISTINCT col0 + - 71 * 40 * - col2 AS col1 FROM tab2
----
107999
73918
76687

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col2 + + col0 col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + cor0.col0 + - 54 AS col1 FROM tab0 AS cor0
----
-19
-30
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-7927
SELECT DISTINCT - col2 DIV 28 FROM tab2 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7927
SELECT DISTINCT - col2 / 28 FROM tab2 cor0
----
-1
0

query I rowsort
SELECT + - col1 + cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
1235
1378
560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 64 col0 FROM tab0 AS cor0
----
-18
31
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-7930
SELECT col0 DIV - 41 - - 35 FROM tab1 AS cor0
----
34
34
35

skipif mysql # not compatible
query I rowsort label-7930
SELECT col0 / - 41 - - 35 FROM tab1 AS cor0
----
34
34
35

query I rowsort
SELECT ALL + cor0.col2 * + col2 + col0 * col0 FROM tab0 AS cor0
----
1226
14645
1665

query I rowsort
SELECT DISTINCT + 49 FROM tab1, tab0 cor0
----
49

query I rowsort
SELECT 88 FROM tab1, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 663c36cf4bc51cf4ea19f7275ac6d30e

query I rowsort
SELECT ALL + col0 * + 66 * - col2 FROM tab2 AS cor0
----
-12474
-133848
-198132

query I rowsort
SELECT + 70 * - cor0.col2 + - 39 FROM tab2, tab0 AS cor0
----
9 values hashing to e3991d7d0c1e00c28845572efaa244e9

query I rowsort
SELECT + 25 * - col2 * + col2 + + col2 * - 4 FROM tab2 AS cor0
----
-17004
-18333
-36252

query I rowsort
SELECT - + ( - col2 ) * + col1 + cor0.col2 FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-7938
SELECT 2 * col1 DIV cor0.col1 - col0 * col0 col0 FROM tab0 AS cor0
----
-1223
-574
-7919

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7938
SELECT 2 * col1 / cor0.col1 - col0 * col0 col0 FROM tab0 AS cor0
----
-1223
-574
-7919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7939
SELECT CAST( + col0 AS SIGNED ) * col0 * - col1 + - col2 * + col2 FROM tab0 cor0
----
-118826
-50625
-727535

skipif mysql # not compatible
query I rowsort label-7939
SELECT CAST ( + col0 AS INTEGER ) * col0 * - col1 + - col2 * + col2 FROM tab0 cor0
----
-118826
-50625
-727535

query I rowsort
SELECT cor0.col0 * col2 - cor0.col1 * + col0 * - col0 FROM tab2 AS cor0
----
109099
1708
360984

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7941
SELECT - CAST( + col2 AS SIGNED ) + col2 + col2 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7941
SELECT - CAST ( + col2 AS INTEGER ) + col2 + col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + + col0 + col0 * ( + 57 ) + - col2 FROM tab1 AS cor0
----
120
3655
4544

query I rowsort
SELECT + 36 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col1 ) * + col2 col1 FROM tab0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7945
SELECT CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7945
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - + 11 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-100
-35
-46

query I rowsort
SELECT ALL + 67 FROM tab1 cor0
----
67
67
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-7948
SELECT - col2 DIV + 22 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7948
SELECT - col2 / + 22 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT col1 * 67 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT col1 * + 49 FROM tab1 AS cor0
----
1274
490
637

query I rowsort
SELECT - col2 * + ( col2 ) + col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL - + cor0.col0 * - 9 FROM tab1 AS cor0
----
27
576
720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + ( col1 ) col1 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * col0 col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col2 * + ( col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7956
SELECT + ( + col1 ) * - CAST( col2 AS SIGNED ) - + col0 AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

skipif mysql # not compatible
query I rowsort label-7956
SELECT + ( + col1 ) * - CAST ( col2 AS INTEGER ) - + col0 AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT - col2 - cor0.col2 * 75 * 3 FROM tab1 AS cor0
----
-12204
-12882
-21696

query I rowsort
SELECT + 47 + col0 FROM tab0 AS cor0
----
136
71
82

query I rowsort
SELECT ALL 44 AS col2 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT - - ( + col0 ) * - col2 + cor0.col1 * - col0 AS col0 FROM tab2 AS cor0
----
-406
-4345
-6630

query I rowsort
SELECT - - 79 + - col1 FROM tab0 AS cor0
----
-12
-18
-7

query I rowsort
SELECT ALL - col1 * col0 - 50 FROM tab1 cor0
----
-1090
-128
-690

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 43 + - cor0.col2 col2 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to ba07fe43c43e1689ac7e6a8becabade2

query I rowsort
SELECT - col2 + - col1 * - col1 FROM tab2
----
251
3455
934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 col1 FROM tab0 WHERE NOT NULL = - col0 * col2
----

query I rowsort
SELECT ALL col2 + + col0 / + col2 FROM tab0 WHERE NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT DISTINCT 18 AS col0 FROM tab0
----
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - col2 col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT DISTINCT 20 FROM tab0, tab2, tab2 AS cor0
----
20

query I rowsort
SELECT 26 - + col1 FROM tab2
----
-33
-5
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7971
SELECT 62 DIV - col2 - - ( 98 * col2 + CAST( + 6 AS SIGNED ) ) FROM tab0
----
3239
42
8042

skipif mysql # not compatible
query I rowsort label-7971
SELECT 62 / - col2 - - ( 98 * col2 + CAST ( + 6 AS INTEGER ) ) FROM tab0
----
3239
42
8042

query I rowsort
SELECT DISTINCT tab2.col0 + tab2.col0 * - tab2.col0 * col1 FROM tab2
----
-106018
-1512
-358878

onlyif mysql # use DIV operator for integer division
query I rowsort label-7973
SELECT col1 + - col0 DIV col1 AS col1 FROM tab1
----
26
4
7

skipif mysql # not compatible
query I rowsort label-7973
SELECT col1 + - col0 / col1 AS col1 FROM tab1
----
26
4
7

query I rowsort
SELECT DISTINCT - col1 + - col1 AS col2 FROM tab1
----
-20
-26
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-7975
SELECT ALL - col2 DIV - col2 + col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-7975
SELECT ALL - col2 / - col2 + col1 FROM tab1
----
11
14
27

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT + col2 >= NULL
----

query I rowsort
SELECT ALL tab0.col1 * + col1 - col0 FROM tab0
----
7372
8192
9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * + col2 * + col1 col1 FROM tab2
----
11020
25974
90532

onlyif mysql # use DIV operator for integer division
query I rowsort label-7979
SELECT DISTINCT - col1 DIV col1 + + col0 * - col0 FROM tab1
----
-10
-4097
-6401

skipif mysql # not compatible
query I rowsort label-7979
SELECT DISTINCT - col1 / col1 + + col0 * - col0 FROM tab1
----
-10
-4097
-6401

onlyif mysql # use DIV operator for integer division
query I rowsort label-7980
SELECT col1 DIV col2 + - col1 + - col1 AS col0 FROM tab1
----
-20
-26
-52

skipif mysql # not compatible
query I rowsort label-7980
SELECT col1 / col2 + - col1 + - col1 AS col0 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT - col0 + col0 FROM tab0 WHERE - col0 IN ( col1 * tab0.col0 * col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7982
SELECT DISTINCT tab0.col2 * col0 DIV col1 + - col2 AS col1 FROM tab0
----
-1
-2
-24

skipif mysql # not compatible
query I rowsort label-7982
SELECT DISTINCT tab0.col2 * col0 / col1 + - col2 AS col1 FROM tab0
----
-1
-2
-24

query I rowsort
SELECT ALL tab1.col0 + tab1.col2 * col1 FROM tab1
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-7984
SELECT col0 + + col1 DIV col1 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-7984
SELECT col0 + + col1 / col1 FROM tab1
----
4
65
81

query I rowsort
SELECT ALL col1 - col2 FROM tab0 WHERE NULL NOT IN ( col1 )
----

query I rowsort
SELECT ALL col2 + col1 * + col1 FROM tab2
----
327
3507
988

query I rowsort
SELECT ALL col0 AS col2 FROM tab1 WHERE NOT NULL IN ( - col2 + - col0 * + col1 )
----

query I rowsort
SELECT DISTINCT col0 * + tab0.col1 AS col0 FROM tab0 WHERE + col2 <= ( NULL )
----

query I rowsort
SELECT - col2 + col0 - col0 * col1 * col2 FROM tab1
----
-36473
-4263
-99856

query I rowsort
SELECT + 94 AS col0 FROM tab1, tab2, tab2 cor0
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT ALL + - 95 AS col0 FROM tab1 AS cor0
----
-95
-95
-95

query I rowsort
SELECT DISTINCT col2 * - cor0.col2 + - col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT DISTINCT 89 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1157
2314
890

query I rowsort
SELECT ALL 29 + col2 FROM tab0 AS cor0
----
111
30
62

query I rowsort
SELECT - - ( col1 ) * - col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - 17 AS col1 FROM tab0 AS cor0
----
-17
-17
-17

query I rowsort
SELECT 21 * col1 AS col1 FROM tab0 AS cor0
----
1806
1911
2037

query I rowsort
SELECT ALL + 26 * - col2 FROM tab1 AS cor0
----
-1404
-1482
-2496

query I rowsort
SELECT DISTINCT - - col2 * col1 + + 65 AS col1 FROM tab2 AS cor0
----
1599
711
902

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 66 * - col2 col2 FROM tab1 AS cor0
----
3564
3762
6336

query I rowsort
SELECT ( + 11 ) AS col2 FROM tab2
----
11
11
11

query I rowsort
SELECT - 85 * - col1 FROM tab2 AS cor0
----
1445
2635
5015

query I rowsort
SELECT ALL - col0 * col0 + - 80 FROM tab2 AS cor0
----
-129
-6164
-6321

query I rowsort
SELECT - 55 * + col2 FROM tab2 AS cor0
----
-1430
-1485
-2090

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - ( col1 + col2 ) * + col1 col2 FROM tab0 AS cor0
----
-10258
-15832
-9541

query I rowsort
SELECT - - col2 + + 99 AS col0 FROM tab1 AS cor0
----
153
156
195

query I rowsort
SELECT - + col0 + + col0 * col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - cor0.col2 * col1 + - ( - col0 ) FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + cor0.col1 + - 38 FROM tab1 AS cor0
----
-12
-25
-28

query I rowsort
SELECT col2 * col2 + col1 AS col1 FROM tab1 AS cor0
----
2942
3259
9229

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8011
SELECT ALL cor0.col2 * + CAST( NULL AS SIGNED ) + + 72 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8011
SELECT ALL cor0.col2 * + CAST ( NULL AS INTEGER ) + + 72 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8012
SELECT DISTINCT + cor0.col2 * CAST( NULL AS SIGNED ) - - 74 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8012
SELECT DISTINCT + cor0.col2 * CAST ( NULL AS INTEGER ) - - 74 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * - col0 + 43 * - col1 + - 89 FROM tab0 AS cor0
----
-12101
-5851
-7655

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8014
SELECT DISTINCT - - cor0.col0 / CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8014
SELECT DISTINCT - - cor0.col0 / CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8015
SELECT + cor0.col2 DIV col1 col0 FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8015
SELECT + cor0.col2 / col1 col0 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + col1 + + ( 20 ) AS col2 FROM tab0 AS cor0
----
106
111
117

query I rowsort
SELECT - - col1 + - 0 AS col2 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8018
SELECT DISTINCT + - col1 - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8018
SELECT DISTINCT + - col1 - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8019
SELECT ALL - + col1 * + CAST( NULL AS SIGNED ) + + 80 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8019
SELECT ALL - + col1 * + CAST ( NULL AS INTEGER ) + + 80 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 26 * - cor0.col2 + - col2 AS col2 FROM tab1 AS cor0
----
-1458
-1539
-2592

onlyif mysql # use DIV operator for integer division
query I rowsort label-8021
SELECT + col1 DIV - 23 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8021
SELECT + col1 / - 23 FROM tab1 cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 92 col0 FROM tab0 AS cor0
----
-92
-92
-92

query I rowsort
SELECT ALL - ( + 40 ) AS col2 FROM tab2 AS cor0
----
-40
-40
-40

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - - ( + col1 ) * col2 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ( - ( - cor0.col2 ) ) * - ( - col2 ) AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT col1 + - 33 AS col1 FROM tab0
----
53
58
64

query I rowsort
SELECT ALL col1 + - 16 FROM tab1
----
-3
-6
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-8029
SELECT - col0 DIV col2 + - col1 AS col1 FROM tab1 AS cor0
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-8029
SELECT - col0 / col2 + - col1 AS col1 FROM tab1 AS cor0
----
-11
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col0 col0 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 55 col0 FROM tab1 AS cor0
----
55

query I rowsort
SELECT - cor1.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT DISTINCT - - 33 + col1 FROM tab0 AS cor0
----
119
124
130

query I rowsort
SELECT + col1 - - col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL - + ( - col2 ) + cor0.col2 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT - col2 * + col2 + - col2 * 2 - - col0 * cor0.col0 FROM tab1 AS cor0
----
-3008
-3015
733

query I rowsort
SELECT 69 - col0 FROM tab0 AS cor0
----
-20
34
45

query I rowsort
SELECT ALL - cor0.col2 + + col2 * 66 * col0 FROM tab1 AS cor0
----
10638
240711
506784

query I rowsort
SELECT DISTINCT ( - col1 ) * + col2 + col1 * col1 FROM tab1 AS cor0
----
-1079
-470
-728

query I rowsort
SELECT ALL + col2 + col0 + - ( col1 ) * col2 FROM tab2 AS cor0
----
-1430
-529
-803

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 23 + col1 col1 FROM tab0 AS cor0
----
63
68
74

query I rowsort
SELECT ALL + cor0.col2 + col2 - col1 * - 76 FROM tab0 AS cor0
----
6602
7080
7374

query I rowsort
SELECT DISTINCT + + col0 + col1 * + col2 AS col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT - - 88 FROM tab0 AS cor0
----
88
88
88

query I rowsort
SELECT ALL - cor0.col1 + - col0 * col2 AS col2 FROM tab2 AS cor0
----
-2087
-220
-3019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8046
SELECT ALL col0 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8046
SELECT ALL col0 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + col2 AS col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL + col1 * + 79 * + col0 AS col2 FROM tab1 AS cor0
----
50560
6162
82160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8049
SELECT - - col2 + + CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8049
SELECT - - col2 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * + 92 + col0 FROM tab1 AS cor0
----
279
5952
7440

query I rowsort
SELECT + col2 * col2 + - cor0.col1 + col2 FROM tab0 AS cor0
----
-95
1036
6715

query I rowsort
SELECT ALL - ( col0 ) + + tab2.col1 AS col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT DISTINCT 2 + 71 * col2 AS col2 FROM tab0 AS cor0
----
2345
5824
73

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) * + cor0.col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + ( - 69 ) * col1 FROM tab0 AS cor0
----
-5934
-6279
-6693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - 99 col0 FROM tab0 AS cor0
----
-8514
-9009
-9603

query I rowsort
SELECT ALL - cor1.col0 AS col0 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT ALL ( - ( col0 ) ) * - 6 AS col0 FROM tab0 cor0
----
144
210
534

query I rowsort
SELECT ALL + col1 * 70 AS col1 FROM tab0 cor0
----
6020
6370
6790

query I rowsort
SELECT DISTINCT - col2 + 48 * col1 FROM tab2 AS cor0
----
1461
2806
778

query I rowsort
SELECT DISTINCT - 15 * + col2 + col1 AS col0 FROM tab0 AS cor0
----
-1139
-409
82

query I rowsort
SELECT ALL 74 - col0 FROM tab0
----
-15
39
50

query I rowsort
SELECT + tab0.col1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT 46 + + col2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1490
722
775

query I rowsort
SELECT - cor0.col0 * 80 AS col2 FROM tab0 AS cor0
----
-1920
-2800
-7120

query I rowsort
SELECT - 19 AS col0 FROM tab0
----
-19
-19
-19

query I rowsort
SELECT ALL 30 FROM tab0, tab2 cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT DISTINCT - cor2.col2 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab2 AS cor2
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-8069
SELECT DISTINCT + 13 DIV - ( tab1.col1 ) AS col2 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-8069
SELECT DISTINCT + 13 / - ( tab1.col1 ) AS col2 FROM tab1
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8070
SELECT ALL - CAST( + col1 AS SIGNED ) * tab1.col2 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-8070
SELECT ALL - CAST ( + col1 AS INTEGER ) * tab1.col2 FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT DISTINCT - 85 - tab0.col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-109
-120
-174

query I rowsort
SELECT + 62 + col0 * + 64 FROM tab0
----
1598
2302
5758

query I rowsort
SELECT DISTINCT ( + col0 ) * - col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + 25 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 32 col1 FROM tab0 AS cor0
----
32

query I rowsort
SELECT ALL + tab2.col1 * - 92 FROM tab2
----
-1564
-2852
-5428

query I rowsort
SELECT DISTINCT tab2.col1 * 41 FROM tab2
----
1271
2419
697

query I rowsort
SELECT - tab1.col1 * + 15 + - col1 AS col0 FROM tab1
----
-160
-208
-416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8080
SELECT DISTINCT CAST( + 88 AS SIGNED ) FROM tab0, tab1 AS cor0
----
88

skipif mysql # not compatible
query I rowsort label-8080
SELECT DISTINCT CAST ( + 88 AS INTEGER ) FROM tab0, tab1 AS cor0
----
88

query I rowsort
SELECT + - col0 + ( - col2 ) * - col0 AS col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT - cor0.col1 + - 77 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-4184
-4399
-7405

query I rowsort
SELECT DISTINCT - col2 + 33 FROM tab2 AS cor0
----
-5
6
7

query I rowsort
SELECT col0 + 84 * - col2 FROM tab1 AS cor0
----
-4533
-4724
-7984

query I rowsort
SELECT DISTINCT + 88 FROM tab1, tab2 AS cor0
----
88

query I rowsort
SELECT DISTINCT col1 * - ( + col1 ) + - col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT DISTINCT + 24 * col0 AS col2 FROM tab2 AS cor0
----
168
1872
1896

query I rowsort
SELECT - col0 * + 0 * col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - ( + col1 ) AS col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - 28 * col2 AS col1 FROM tab1 AS cor0
----
-1512
-1596
-2688

query I rowsort
SELECT DISTINCT - - cor0.col1 + ( + 39 ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
125
130
136

query I rowsort
SELECT 35 * ( + col2 ) AS col0 FROM tab2 AS cor0
----
1330
910
945

query I rowsort
SELECT - - col1 * - ( col2 ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + - col0 * - col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
207936
737280
8748

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8095
SELECT DISTINCT + + col1 + CAST( - cor0.col0 AS SIGNED ) * - col0 * col2 FROM tab2 AS cor0
----
1354
158243
237175

skipif mysql # not compatible
query I rowsort label-8095
SELECT DISTINCT + + col1 + CAST ( - cor0.col0 AS INTEGER ) * - col0 * col2 FROM tab2 AS cor0
----
1354
158243
237175

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col1 AS REAL ) + - col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8097
SELECT ALL - cor0.col1 * - col1 + col0 DIV 69 AS col2 FROM tab1 AS cor0
----
100
170
676

skipif mysql # not compatible
query I rowsort label-8097
SELECT ALL - cor0.col1 * - col1 + col0 / 69 AS col2 FROM tab1 AS cor0
----
100
170
676

query I rowsort
SELECT DISTINCT - - ( col0 ) * col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col2 * 52 + - col1 FROM tab1 AS cor0
----
-2834
-2974
-5005

query I rowsort
SELECT ALL - 72 * col1 FROM tab0 cor0
----
-6192
-6552
-6984

onlyif mysql # use DIV operator for integer division
query I rowsort label-8101
SELECT DISTINCT + + col0 DIV col0 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-8101
SELECT DISTINCT + + col0 / col0 FROM tab1 AS cor0
----
1

query I rowsort
SELECT - col2 * 85 + - col1 * - 68 + - col0 AS col1 FROM tab2 AS cor0
----
-194
-2153
1724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( tab0.col2 ) col0 FROM tab0, tab1 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 34 col1 FROM tab2 AS cor0
----
-34
-34
-34

query I rowsort
SELECT + ( + col2 ) + + 94 * - col1 + + col2 FROM tab2 AS cor0
----
-1522
-2860
-5494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 54 col1 FROM tab0 AS cor0
----
-54
-54
-54

query I rowsort
SELECT - cor0.col1 * - cor0.col2 + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - 65 * + col1 FROM tab2 AS cor0
----
-1105
-2015
-3835

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 27 * 33 col0 FROM tab0
----
-891

query I rowsort
SELECT DISTINCT ( col0 ) * col2 * - col2 AS col0 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT ALL + cor1.col0 FROM tab0, tab2 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT - - 75 + col2 * - col1 AS col0 FROM tab2 AS cor0
----
-1459
-571
-762

query I rowsort
SELECT tab0.col2 AS col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL + col2 * tab0.col0 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT + ( - col1 ) * col0 AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col0 * - 50 AS col2 FROM tab2 AS cor0
----
-350
-3900
-3950

query I rowsort
SELECT + col1 * - 4 + + col1 FROM tab2 AS cor0
----
-177
-51
-93

query I rowsort
SELECT - col0 + 95 AS col0 FROM tab1 cor0
----
15
31
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-8119
SELECT + col1 DIV col0 - - col2 FROM tab2
----
26
31
38

skipif mysql # not compatible
query I rowsort label-8119
SELECT + col1 / col0 - - col2 FROM tab2
----
26
31
38

query I rowsort
SELECT 5 AS col1 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT DISTINCT + col1 + - col2 * 31 FROM tab2
----
-1161
-747
-806

query I rowsort
SELECT - 9 + col1 + col1 FROM tab2
----
109
25
53

query I rowsort
SELECT tab2.col2 * 34 + - tab2.col2 AS col0 FROM tab2
----
1254
858
891

query I rowsort
SELECT ALL col2 * cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT - col1 * + col1 + col0 + - col2 AS col1 FROM tab2 AS cor0
----
-248
-3429
-981

onlyif mysql # use DIV operator for integer division
query I rowsort label-8126
SELECT ALL col2 + + cor0.col2 DIV + col0 FROM tab0 AS cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-8126
SELECT ALL col2 + + cor0.col2 / + col0 FROM tab0 AS cor0
----
1
34
82

query I rowsort
SELECT DISTINCT + - cor0.col1 * - 58 * col1 - - col1 * - col1 * 46 FROM tab2 AS cor0
----
11532
3468
41772

query I rowsort
SELECT cor0.col0 * - 55 FROM tab1 AS cor0
----
-165
-3520
-4400

query I rowsort
SELECT + + col0 * col2 + 58 FROM tab0 AS cor0
----
7356
850
93

query I rowsort
SELECT cor1.col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - col2 - col0 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + col2 col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + col1 + col1 + cor0.col2 * + col0 FROM tab1 AS cor0
----
214
3668
7706

query I rowsort
SELECT - 3 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT + cor0.col2 - + col1 AS col0 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-8136
SELECT 3 DIV - col2 + + 19 + + col0 AS col2 FROM tab1 AS cor0
----
22
83
99

skipif mysql # not compatible
query I rowsort label-8136
SELECT 3 / - col2 + + 19 + + col0 AS col2 FROM tab1 AS cor0
----
22
83
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-8137
SELECT DISTINCT + col0 DIV col2 + ( - col2 ) * col2 col2 FROM tab1 AS cor0
----
-2916
-3248
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8137
SELECT DISTINCT + col0 / col2 + ( - col2 ) * col2 col2 FROM tab1 AS cor0
----
-2916
-3248
-9216

query I rowsort
SELECT col2 + col2 * ( col2 ) + col0 * col2 FROM tab1 AS cor0
----
16992
3132
6954

query I rowsort
SELECT ALL - tab0.col1 * + col2 * 28 AS col2 FROM tab0
----
-208936
-2716
-79464

query I rowsort
SELECT + col1 + 65 * col2 AS col0 FROM tab0 AS cor0
----
162
2231
5421

query I rowsort
SELECT DISTINCT col2 * col1 * col0 AS col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL col2 * + 17 AS col2 FROM tab1
----
1632
918
969

query I rowsort
SELECT ALL col0 * - ( + tab1.col2 ) * tab1.col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT - 1 FROM tab0, tab0 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-8145
SELECT ALL col1 DIV - ( col1 * - 33 ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8145
SELECT ALL col1 / - ( col1 * - 33 ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - ( col2 ) * col0 - col0 * col1 * col0 FROM tab1 AS cor0
----
-37312
-72
-75520

onlyif mysql # use DIV operator for integer division
query I rowsort label-8147
SELECT DISTINCT - - 58 * - col2 + + cor0.col2 DIV ( - 51 ) - - cor0.col2 FROM tab0 AS cor0
----
-1881
-4675
-57

skipif mysql # not compatible
query I rowsort label-8147
SELECT DISTINCT - - 58 * - col2 + + cor0.col2 / ( - 51 ) - - cor0.col2 FROM tab0 AS cor0
----
-1881
-4675
-57

query I rowsort
SELECT - cor0.col2 + 9 FROM tab2 AS cor0
----
-17
-18
-29

query I rowsort
SELECT DISTINCT - col1 - - cor0.col1 * col1 * - col2 FROM tab2 cor0
----
-10999
-25978
-90565

query I rowsort
SELECT ALL - cor0.col2 * 88 + col1 AS col0 FROM tab2 AS cor0
----
-2229
-2345
-3327

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - 63 col2 FROM tab1 AS cor0
----
-127
-143
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 26 col2 FROM tab2
----
182
2028
2054

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * + cor0.col0 col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT + + 84 * 33 FROM tab1 AS cor0
----
2772
2772
2772

onlyif mysql # use DIV operator for integer division
query I rowsort label-8155
SELECT 88 * col1 DIV - cor0.col1 col0 FROM tab0 AS cor0
----
-88
-88
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8155
SELECT 88 * col1 / - cor0.col1 col0 FROM tab0 AS cor0
----
-88
-88
-88

query I rowsort
SELECT ALL + col0 + - col1 * cor0.col2 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-8157
SELECT - ( - col2 ) * + col2 - - CAST( col1 AS SIGNED ) * col1 DIV ( col2 ) FROM tab1 AS cor0
----
2928
3250
9217

skipif mysql # not compatible
query I rowsort label-8157
SELECT - ( - col2 ) * + col2 - - CAST ( col1 AS INTEGER ) * col1 / ( col2 ) FROM tab1 AS cor0
----
2928
3250
9217

query I rowsort
SELECT cor0.col2 + + col2 * col1 FROM tab0 cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT + col1 * ( - col2 ) + - col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT + + ( - col0 ) + + col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + 59 * col1 AS col0 FROM tab2
----
1003
1829
3481

query I rowsort
SELECT DISTINCT - - 91 + + cor0.col2 * + ( col0 ) AS col0 FROM tab1 AS cor0
----
253
3739
7771

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 86 col1 FROM tab0 cor0
----
86
86
86

query I rowsort
SELECT - 94 + col1 FROM tab0 AS cor0
----
-3
-8
3

query I rowsort
SELECT DISTINCT + ( - col2 ) * + 45 + + ( col0 * ( col0 ) ) FROM tab2 AS cor0
----
-1166
4531
4914

query I rowsort
SELECT ALL + - col1 * - cor0.col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - col0 * + col2 + + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL + cor0.col1 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL 59 * col1 + + 13 AS col2 FROM tab1 cor0
----
1547
603
780

query I rowsort
SELECT DISTINCT - ( - col2 ) * - col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + cor0.col1 + + cor0.col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + 93 + + col2 AS col1 FROM tab1 AS cor0
----
147
150
189

query I rowsort
SELECT DISTINCT cor0.col1 * + col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + - col2 * - col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort
SELECT - col2 + CAST ( - 25 AS REAL ) FROM tab2 AS cor0
----
-51
-52
-63

query I rowsort
SELECT ALL - - cor0.col1 * - ( - col0 * - col0 + + col1 ) AS col0 FROM tab2 cor0
----
-106386
-2480
-362437

onlyif mysql # use DIV operator for integer division
query I rowsort label-8177
SELECT - col2 DIV + col1 + - col0 * 41 FROM tab1
----
-125
-2629
-3287

skipif mysql # not compatible
query I rowsort label-8177
SELECT - col2 / + col1 + - col0 * 41 FROM tab1
----
-125
-2629
-3287

query I rowsort
SELECT DISTINCT - 81 AS col0 FROM tab2
----
-81

query I rowsort
SELECT DISTINCT - 2 + 12 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * - col2 col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - + col2 * 80 FROM tab2 AS cor0
----
-2080
-2160
-3040

query I rowsort
SELECT + col0 + 16 * - col1 AS col1 FROM tab2 AS cor0
----
-193
-489
-866

query I rowsort
SELECT col0 + - ( col2 ) * col1 * 4 AS col0 FROM tab2 AS cor0
----
-2505
-3341
-6058

query I rowsort
SELECT ALL + + col1 * + 38 + 36 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8185
SELECT + col2 + + col2 DIV col1 FROM tab1 AS cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-8185
SELECT + col2 + + col2 / col1 FROM tab1 AS cor0
----
103
56
62

query I rowsort
SELECT ALL 76 * + 16 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to cde8bd5058cbf2f19969952c41e6ec4f

query I rowsort
SELECT + + 6 AS col1 FROM tab2 cor0
----
6
6
6

query I rowsort
SELECT + - 78 + col1 AS col0 FROM tab0 cor0
----
13
19
8

query I rowsort
SELECT - + 6 * col0 - - 39 * + col2 FROM tab1 AS cor0
----
1839
2088
3264

query I rowsort
SELECT ALL + col0 * 85 + + tab2.col2 * 65 AS col1 FROM tab2
----
2350
8320
9185

query I rowsort
SELECT ALL cor1.col2 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - col1 * - cor0.col2 - + 1 FROM tab0 cor0
----
2837
7461
96

query I rowsort
SELECT ALL 35 + 35 AS col0 FROM tab0
----
70
70
70

query I rowsort
SELECT tab1.col0 * col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL - 97 * + col0 - - col2 AS col2 FROM tab2 AS cor0
----
-652
-7540
-7625

query I rowsort
SELECT 9 + col1 * col2 FROM tab1 AS cor0
----
1257
1413
579

query I rowsort
SELECT DISTINCT + col0 * - col1 + ( - cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL + 63 + + col0 * ( ( col1 ) ) AS col1 FROM tab1 AS cor0
----
1103
141
703

query I rowsort
SELECT + col1 * col0 * col2 + - col1 FROM tab0 AS cor0
----
3298
664027
68026

query I rowsort
SELECT - tab1.col0 * - tab1.col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT cor0.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT ( col1 + - col1 ) * + 65 FROM tab1
----
0

query I rowsort
SELECT 54 * col1 + + col2 AS col0 FROM tab2 AS cor0
----
1701
3212
956

query I rowsort
SELECT ALL - + col0 * - col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL 87 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT - col0 * - col2 * 64 FROM tab2 AS cor0
----
12096
129792
192128

query I rowsort
SELECT ALL col1 - + col1 AS col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8208
SELECT - col2 + 83 DIV col2 AS col0 FROM tab1 AS cor0
----
-53
-56
-96

skipif mysql # not compatible
query I rowsort label-8208
SELECT - col2 + 83 / col2 AS col0 FROM tab1 AS cor0
----
-53
-56
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8209
SELECT col0 + col0 DIV col1 + col0 AS col2 FROM tab2 AS cor0
----
14
157
162

skipif mysql # not compatible
query I rowsort label-8209
SELECT col0 + col0 / col1 + col0 AS col2 FROM tab2 AS cor0
----
14
157
162

query I rowsort
SELECT - cor0.col1 * + 47 + - cor0.col1 AS col2 FROM tab2 cor0
----
-1488
-2832
-816

query I rowsort
SELECT col1 * - col2 + cor0.col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT + col0 - 66 AS col2 FROM tab2 AS cor0
----
-59
12
13

query I rowsort
SELECT - + cor0.col2 * 47 - 84 AS col2 FROM tab0 AS cor0
----
-131
-1635
-3938

query I rowsort
SELECT - + ( 0 ) + - col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 64 ) col0 FROM tab0 cor0
----
-64
-64
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8216
SELECT - CAST( col1 AS SIGNED ) + - col2 * 19 FROM tab1 AS cor0
----
-1052
-1093
-1837

skipif mysql # not compatible
query I rowsort label-8216
SELECT - CAST ( col1 AS INTEGER ) + - col2 * 19 FROM tab1 AS cor0
----
-1052
-1093
-1837

query I rowsort
SELECT DISTINCT + - 55 * col1 AS col1 FROM tab2 cor0
----
-1705
-3245
-935

query I rowsort
SELECT - - col2 * + col2 AS col1 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT + 77 * col2 FROM tab1 AS cor0
----
4158
4389
7392

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8220
SELECT - CAST( - 72 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
72
72
72

skipif mysql # not compatible
query I rowsort label-8220
SELECT - CAST ( - 72 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
72
72
72

query I rowsort
SELECT - 27 * - cor0.col2 FROM tab0 AS cor0
----
2214
27
891

query I rowsort
SELECT 87 * - 24 AS col1 FROM tab2 AS cor0
----
-2088
-2088
-2088

query I rowsort
SELECT - col0 * + col2 + col2 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT col0 * + 62 AS col0 FROM tab0
----
1488
2170
5518

query I rowsort
SELECT DISTINCT + 78 + col2 FROM tab2 cor0
----
104
105
116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 3 ) col2 FROM tab0 AS cor0
----
3
3
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-8227
SELECT DISTINCT col0 * col0 DIV + tab1.col2 AS col1 FROM tab1
----
0
66
71

skipif mysql # not compatible
query I rowsort label-8227
SELECT DISTINCT col0 * col0 / + tab1.col2 AS col1 FROM tab1
----
0
66
71

query I rowsort
SELECT DISTINCT - 70 * - 21 + col1 FROM tab2 AS cor0
----
1487
1501
1529

query I rowsort
SELECT + cor0.col2 + - col2 AS col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 34 * 80 + col2 FROM tab2 AS cor0
----
2746
2747
2758

query I rowsort
SELECT DISTINCT 51 * - col0 + col0 AS col0 FROM tab1 cor0
----
-150
-3200
-4000

query I rowsort
SELECT + + 97 + col2 AS col0 FROM tab1 AS cor0
----
151
154
193

query I rowsort
SELECT DISTINCT col1 * 94 FROM tab2 AS cor0
----
1598
2914
5546

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8234
SELECT CAST( NULL AS SIGNED ) * + col1 + col0 * - col1 * - col0 + col2 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8234
SELECT CAST ( NULL AS INTEGER ) * + col1 + col0 * - col1 * - col0 + col2 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( + col0 ) * + col1 * + cor0.col0 FROM tab1 AS cor0
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 62 col2 FROM tab0 AS cor0
----
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( + col2 ) - col1 * - 35 col2 FROM tab1 AS cor0
----
407
551
964

onlyif mysql # use DIV operator for integer division
query I rowsort label-8238
SELECT + col1 * 63 DIV col2 FROM tab1
----
11
30
8

skipif mysql # not compatible
query I rowsort label-8238
SELECT + col1 * 63 / col2 FROM tab1
----
11
30
8

query I rowsort
SELECT ALL 0 * + col1 + + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - 36 FROM tab1, tab2 AS cor0
----
9 values hashing to afecaf209e79e23b6674a73fffa3e837

query I rowsort
SELECT ALL 76 + + 80 * + col2 * + col0 FROM tab1 AS cor0
----
13036
291916
614476

query I rowsort
SELECT DISTINCT + col1 * col2 + col1 + ( + col0 ) * col1 FROM tab0
----
15652
3589
4988

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8243
SELECT CAST( - col2 * - col2 AS SIGNED ) AS col2 FROM tab1
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-8243
SELECT CAST ( - col2 * - col2 AS INTEGER ) AS col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ( - ( + col1 ) ) + - 39 FROM tab2
----
-56
-70
-98

query I rowsort
SELECT ALL - col1 * + col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT 68 * + col2 AS col2 FROM tab2 AS cor0
----
1768
1836
2584

query I rowsort
SELECT - - col1 + col0 * - col0 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-8248
SELECT DISTINCT - tab0.col0 * tab0.col2 DIV col2 + 94 * - col2 FROM tab0
----
-129
-3126
-7797

skipif mysql # not compatible
query I rowsort label-8248
SELECT DISTINCT - tab0.col0 * tab0.col2 / col2 + 94 * - col2 FROM tab0
----
-129
-3126
-7797

query I rowsort
SELECT DISTINCT + col2 * col0 + col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT - col0 * - ( col1 ) + 18 * - col1 FROM tab2
----
-341
1037
3540

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8251
SELECT - CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8251
SELECT - CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + 3 FROM tab2
----
29
30
41

query I rowsort
SELECT + tab0.col0 * col0 AS col2 FROM tab0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-8254
SELECT DISTINCT + 54 * col0 DIV - col0 + + ( col2 ) * + col1 AS col1 FROM tab1
----
1194
1350
516

skipif mysql # not compatible
query I rowsort label-8254
SELECT DISTINCT + 54 * col0 / - col0 + + ( col2 ) * + col1 AS col1 FROM tab1
----
1194
1350
516

query I rowsort
SELECT col2 - - 16 FROM tab2
----
42
43
54

query I rowsort
SELECT 50 * - col2 + + tab2.col0 FROM tab2
----
-1222
-1343
-1821

query I rowsort
SELECT DISTINCT - - col2 * ( - cor0.col1 ) * col2 + col0 * 13 FROM tab1 AS cor0
----
-118768
-31658
-75777

query I rowsort
SELECT DISTINCT - col2 - + 65 AS col1 FROM tab2 AS cor0
----
-103
-91
-92

query I rowsort
SELECT ALL - - cor0.col1 * 4 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT 7 + - cor0.col1 * - 24 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 1b5d870ecf536743e047522d9e8350e4

query I rowsort
SELECT DISTINCT + col2 + 99 * - col0 AS col1 FROM tab0 AS cor0
----
-2343
-3464
-8729

query I rowsort
SELECT DISTINCT + + col1 * cor0.col1 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8263
SELECT ALL col1 * + CAST( NULL AS SIGNED ) + col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8263
SELECT ALL col1 * + CAST ( NULL AS INTEGER ) + col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 82 col1 FROM tab1 AS cor0
----
108
92
95

query I rowsort
SELECT ALL - + col1 * ( col0 * + col0 + col1 ) AS col2 FROM tab0 AS cor0
----
-128234
-56932
-729092

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8266
SELECT DISTINCT - - col2 + + CAST( NULL AS DECIMAL ) + - col2 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8266
SELECT DISTINCT - - col2 + + CAST ( NULL AS REAL ) + - col2 AS col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 * tab0.col1 - + tab0.col0 * + col2 col1 FROM tab0
----
164
2046
62

query I rowsort
SELECT - 93 + cor0.col2 * + cor1.col0 AS col1 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to cf109067a10965ded1ed38a44b422cf8

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2, tab0 AS cor0, tab2 cor1
----
972 values hashing to 42e69ecdafb3c81046bc5cb4c98b1666

query I rowsort
SELECT DISTINCT - col1 * - tab0.col0 AS col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + col2 * - col2 + tab1.col0 FROM tab1
----
-2913
-3185
-9136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT + col1 * 28 FROM tab1 cor0
----
280
364
728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 47 col0 FROM tab0 AS cor0
----
47
47
47

query I rowsort
SELECT + 67 * - cor0.col0 * col0 FROM tab0 cor0
----
-38592
-530707
-82075

query I rowsort
SELECT DISTINCT + - col0 * cor0.col2 + + col0 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + + col1 * + col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT ALL 7 * col2 AS col0 FROM tab0
----
231
574
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 66 * col0 col0 FROM tab2
----
462
5148
5214

query I rowsort
SELECT DISTINCT - col1 * - col0 * col0 AS col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT 34 AS col2 FROM tab0
----
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 + tab0.col1 * col1 col1 FROM tab0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-8283
SELECT ALL - cor0.col2 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8283
SELECT ALL - cor0.col2 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL 16 + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-19
-7282
-776

query I rowsort
SELECT ALL + 10 + col0 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
45
7308
802

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT + 62 + + col1 * col1 * + col2 AS col1 FROM tab2 AS cor0
----
11044
26009
90568

query I rowsort
SELECT DISTINCT - col1 + 20 AS col2 FROM tab1
----
-6
10
7

query I rowsort
SELECT - + col1 + - 57 + 11 * + col1 AS col0 FROM tab1 AS cor0
----
203
43
73

query I rowsort
SELECT ALL - - col0 * + ( + col1 ) + - col1 * - cor0.col2 * col0 AS col1 FROM tab0 AS cor0
----
672217
6790
70176

query I rowsort
SELECT col0 * + 62 + - col1 * - col1 + + col1 AS col1 FROM tab2 AS cor0
----
1426
5204
8376

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8292
SELECT ALL - col0 + - CAST( 46 AS SIGNED ) AS col2 FROM tab1 cor0
----
-110
-126
-49

skipif mysql # not compatible
query I rowsort label-8292
SELECT ALL - col0 + - CAST ( 46 AS INTEGER ) AS col2 FROM tab1 cor0
----
-110
-126
-49

query I rowsort
SELECT tab2.col1 * col2 * col2 FROM tab2
----
22599
24548
39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-8294
SELECT ALL cor0.col1 DIV - col1 - col2 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-8294
SELECT ALL cor0.col1 / - col1 - col2 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT ALL + 6 FROM tab1, tab0 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT + 11 + + col1 * col2 + col1 AS col0 FROM tab1 AS cor0
----
1272
1441
591

query I rowsort
SELECT ALL tab0.col0 * 44 AS col1 FROM tab0
----
1056
1540
3916

query I rowsort
SELECT - col1 * - col2 + tab2.col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT - 23 AS col0 FROM tab0, tab1 AS cor0
----
-23

query I rowsort
SELECT ALL - col1 + - col2 * - col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - col1 * + cor0.col0 * col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT 21 * col0 AS col0 FROM tab0 AS cor0
----
1869
504
735

query I rowsort
SELECT + + col2 * col2 + col1 * - col1 + + col2 * + col1 FROM tab1 AS cor0
----
10295
3644
3719

query I rowsort
SELECT col2 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - ( 26 ) * - col0 FROM tab2 AS cor0
----
182
2028
2054

query I rowsort
SELECT DISTINCT 80 AS col1 FROM tab0 AS cor0
----
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8307
SELECT + - col0 DIV col0 - col0 col1 FROM tab2 AS cor0
----
-79
-8
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8307
SELECT + - col0 / col0 - col0 col1 FROM tab2 AS cor0
----
-79
-8
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8308
SELECT col0 + col0 + - col2 DIV + col0 FROM tab1 AS cor0
----
-12
128
159

skipif mysql # not compatible
query I rowsort label-8308
SELECT col0 + col0 + - col2 / + col0 FROM tab1 AS cor0
----
-12
128
159

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT - col2 NOT BETWEEN - col1 + col1 AND NULL OR NOT ( NULL ) IN ( - col1 )
----

query I rowsort
SELECT ALL + col0 * + cor0.col1 + + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + tab0.col2 * col0 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT col0 + col1 * + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - col1 AS col2 FROM tab0 cor0 WHERE ( col0 + + col1 ) <> NULL
----

query I rowsort
SELECT col1 * - col2 + - col2 AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT + col0 FROM tab1 AS cor0 WHERE NOT ( col1 + - col0 ) >= NULL
----

query I rowsort
SELECT DISTINCT + col2 * - col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - col1 + - col0 * cor0.col2 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL + col2 AS col2 FROM tab0 cor0 WHERE NOT col1 * col0 <> NULL AND NULL IN ( + col2 * + cor0.col1 * col0 ) OR NOT ( - col1 ) < ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8319
SELECT ALL 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-8319
SELECT ALL col0 / + col2 col1 FROM tab0
----
0
1
35

query I rowsort
SELECT - + col2 * - cor0.col1 + col0 AS col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-8321
SELECT ALL col2 + col1 DIV col1 AS col2 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-8321
SELECT ALL col2 + col1 / col1 AS col2 FROM tab2
----
27
28
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-8322
SELECT + col1 DIV - col1 col0 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8322
SELECT + col1 / - col1 col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - col1 + tab0.col2 * + col2 AS col2 FROM tab0
----
-96
1003
6633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col2 + col0 col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT - col1 * - col0 + + cor0.col2 - - cor0.col1 FROM tab2 AS cor0
----
1398
275
4687

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 col0 FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT col0 * - col0 + + col2 * col0 AS col2 FROM tab0
----
-1190
-623
216

onlyif mysql # use DIV operator for integer division
query I rowsort label-8328
SELECT DISTINCT - col0 DIV + col0 + col0 * - col1 AS col0 FROM tab2
----
-1344
-218
-4603

skipif mysql # not compatible
query I rowsort label-8328
SELECT DISTINCT - col0 / + col0 + col0 * - col1 AS col0 FROM tab2
----
-1344
-218
-4603

query I rowsort
SELECT DISTINCT + col1 + col2 * - col0 FROM tab0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8330
SELECT + col2 * col0 + + cor0.col1 * col1 * + CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
25833
273546
6916

skipif mysql # not compatible
query I rowsort label-8330
SELECT + col2 * col0 + + cor0.col1 * col1 * + CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
25833
273546
6916

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8332
SELECT ALL + col2 DIV - 72 - + cor0.col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-1249
-1404
-570

skipif mysql # not compatible
query I rowsort label-8332
SELECT ALL + col2 / - 72 - + cor0.col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-1249
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8333
SELECT ALL col1 * CAST( + col2 AS SIGNED ) * + col2 + col1 FROM tab0
----
194
611975
93740

skipif mysql # not compatible
query I rowsort label-8333
SELECT ALL col1 * CAST ( + col2 AS INTEGER ) * + col2 + col1 FROM tab0
----
194
611975
93740

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8334
SELECT - col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8334
SELECT - col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8335
SELECT DISTINCT - col1 * - CAST( NULL AS SIGNED ) * - col1 + col2 * + 40 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8335
SELECT DISTINCT - col1 * - CAST ( NULL AS INTEGER ) * - col1 + col2 * + 40 FROM tab1
----
NULL

query I rowsort
SELECT + cor0.col1 + + 45 FROM tab1 AS cor0
----
55
58
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-8337
SELECT tab2.col1 DIV + 47 AS col2 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8337
SELECT tab2.col1 / + 47 AS col2 FROM tab2
----
0
0
1

query I rowsort
SELECT - 75 * - col1 FROM tab0 cor0
----
6450
6825
7275

query I rowsort
SELECT - 35 - - col2 FROM tab1 AS cor0
----
19
22
61

query I rowsort
SELECT 85 + - col2 * - col2 * - col2 FROM tab0 AS cor0
----
-35852
-551283
84

query I rowsort
SELECT - col2 * - col1 + 2 FROM tab0 cor0
----
2840
7464
99

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 + + col2 * - col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT + 81 AS col0 FROM tab2
----
81
81
81

query I rowsort
SELECT DISTINCT col1 + + col1 + col2 AS col1 FROM tab0
----
195
205
264

query I rowsort
SELECT col0 * col1 - 67 AS col1 FROM tab2 AS cor0
----
1276
150
4535

query I rowsort
SELECT - 27 * col0 + + cor0.col1 AS col1 FROM tab1 cor0
----
-1718
-2147
-55

query I rowsort
SELECT + - col2 * + cor0.col0 + cor0.col1 * col0 + col1 * col0 FROM tab2 AS cor0
----
-316
245
7176

query I rowsort
SELECT + col2 - col1 AS col1 FROM tab2 cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-8350
SELECT - - cor0.col0 * col2 DIV col1 AS col0 FROM tab1 AS cor0
----
364
590
6

skipif mysql # not compatible
query I rowsort label-8350
SELECT - - cor0.col0 * col2 / col1 AS col0 FROM tab1 AS cor0
----
364
590
6

query I rowsort
SELECT ALL - col0 + col2 - 9 FROM tab1
----
-16
42
7

query I rowsort
SELECT DISTINCT + 63 - col0 AS col0 FROM tab0
----
-26
28
39

query I rowsort
SELECT DISTINCT - ( col1 ) * + 8 - col0 FROM tab0
----
-712
-811
-817

query I rowsort
SELECT col0 * col2 * ( col0 ) AS col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT - ( - cor0.col1 ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - cor0.col2 * + col1 * + col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8357
SELECT ALL + + col0 + col0 / - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8357
SELECT ALL + + col0 + col0 / - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 44 * - col1 AS col1 FROM tab2 AS cor0
----
-1364
-2596
-748

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL + - cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col1 + cor0.col1 * col2 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * col0 col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + col0 * 84 AS col2 FROM tab1 AS cor0
----
252
5376
6720

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-8365
SELECT - col0 * - col0 + - col0 * col0 + col2 DIV - col0 AS col1 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8365
SELECT - col0 * - col0 + - col0 * col0 + col2 / - col0 AS col1 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT cor0.col2 + - 39 FROM tab0 AS cor0
----
-38
-6
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-8367
SELECT - + col0 * - col0 * col0 + + cor0.col1 DIV col1 + col1 AS col0 FROM tab0 cor0
----
13911
42973
705061

skipif mysql # not compatible
query I rowsort label-8367
SELECT - + col0 * - col0 * col0 + + cor0.col1 / col1 + col1 AS col0 FROM tab0 cor0
----
13911
42973
705061

query I rowsort
SELECT ALL + col0 * + 0 * - 25 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + + col0 col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-8370
SELECT DISTINCT col1 DIV col0 AS col0 FROM tab2 cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-8370
SELECT DISTINCT col1 / col0 AS col0 FROM tab2 cor0
----
0
4

query I rowsort
SELECT ALL + col2 * ( - col2 ) + col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT + col0 * 16 - + col2 * + col0 AS col2 FROM tab2 AS cor0
----
-1738
-77
-780

query I rowsort
SELECT - - col1 + + col1 * 25 FROM tab1 AS cor0
----
260
338
676

query I rowsort
SELECT - - col2 + - col1 + cor0.col2 FROM tab0 cor0
----
-20
-95
73

query I rowsort
SELECT ALL + 65 - + tab2.col0 FROM tab2
----
-13
-14
58

query I rowsort
SELECT col1 * col1 + - 38 FROM tab2
----
251
3443
923

query I rowsort
SELECT ALL col1 * 52 FROM tab1 AS cor0
----
1352
520
676

query I rowsort
SELECT ALL + col2 * - col1 - col2 AS col0 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT ALL 99 * col2 * col1 + + col2 AS col1 FROM tab1 AS cor0
----
123648
139050
56487

query I rowsort
SELECT DISTINCT - col0 * 91 + col2 - cor0.col2 FROM tab1 cor0
----
-273
-5824
-7280

query I rowsort
SELECT DISTINCT col2 * - 60 FROM tab1
----
-3240
-3420
-5760

query I rowsort
SELECT ALL 44 + cor0.col2 FROM tab1 cor0
----
101
140
98

query I rowsort
SELECT ALL + + 94 AS col2 FROM tab2 AS cor0
----
94
94
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col2 + col2 col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - 60 * + col1 + col0 - 19 * - col1 * col1 AS col2 FROM tab0 AS cor0
----
135388
151968
172986

query I rowsort
SELECT + + 44 FROM tab2 cor0
----
44
44
44

query I rowsort
SELECT DISTINCT - - 54 FROM tab1 AS cor0
----
54

query I rowsort
SELECT + col0 + tab1.col1 * - col1 AS col2 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT + col1 * col2 - col1 FROM tab0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-8390
SELECT - col0 DIV 39 + - col1 * col0 col2 FROM tab2 AS cor0
----
-1345
-217
-4604

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8390
SELECT - col0 / 39 + - col1 * col0 col2 FROM tab2 AS cor0
----
-1345
-217
-4604

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8391
SELECT ALL CAST( - col1 AS SIGNED ) AS col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8391
SELECT ALL CAST ( - col1 AS INTEGER ) AS col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL 90 * - col1 AS col2 FROM tab2
----
-1530
-2790
-5310

query I rowsort
SELECT + - col1 * col1 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT ALL + 56 + 51 FROM tab2 AS cor0
----
107
107
107

query I rowsort
SELECT - + 6 * + col2 FROM tab1 AS cor0
----
-324
-342
-576

query I rowsort
SELECT col1 * - col1 + - col1 * col1 FROM tab0 AS cor0
----
-14792
-16562
-18818

query I rowsort
SELECT - + 74 FROM tab2 AS cor0
----
-74
-74
-74

query I rowsort
SELECT + 16 + - 42 * + col0 AS col1 FROM tab2
----
-278
-3260
-3302

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8399
SELECT ALL - CAST( - col0 AS SIGNED ) FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8399
SELECT ALL - CAST ( - col0 AS INTEGER ) FROM tab0
----
24
35
89

query I rowsort
SELECT - col1 + col0 * - ( col0 ) AS col1 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT - ( - col2 ) + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT col2 * 42 AS col1 FROM tab2
----
1092
1134
1596

query I rowsort
SELECT ALL + ( col0 ) * - tab2.col1 AS col1 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8404
SELECT DISTINCT + col0 + 36 DIV col1 FROM tab1 cor0
----
4
67
82

skipif mysql # not compatible
query I rowsort label-8404
SELECT DISTINCT + col0 + 36 / col1 FROM tab1 cor0
----
4
67
82

query I rowsort
SELECT col2 * 12 + col1 AS col2 FROM tab2 AS cor0
----
355
371
473

query I rowsort
SELECT + col2 - - 70 FROM tab2 cor0
----
108
96
97

query I rowsort
SELECT col2 + - 90 FROM tab0 AS cor0
----
-57
-8
-89

query I rowsort
SELECT col2 + + 7 FROM tab1 AS cor0
----
103
61
64

query I rowsort
SELECT ALL + + col2 + col2 - col2 * + col0 FROM tab0 AS cor0
----
-33
-7134
-726

query I rowsort
SELECT + - col2 + - col2 * 70 AS col1 FROM tab2 AS cor0
----
-1846
-1917
-2698

query I rowsort
SELECT DISTINCT col1 * col2 + + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - col1 + col2 - 78 AS col1 FROM tab0 cor0
----
-131
-174
-87

query I rowsort
SELECT ALL col1 * ( - cor0.col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col0 * + col1 + - 19 AS col0 FROM tab2 AS cor0
----
1324
198
4583

query I rowsort
SELECT + col2 + + col1 * col0 AS col0 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8416
SELECT + col1 * - CAST( NULL AS SIGNED ) + ( col0 ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8416
SELECT + col1 * - CAST ( NULL AS INTEGER ) + ( col0 ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - tab2.col1 - tab2.col1 * - col0 FROM tab2
----
1326
186
4543

query I rowsort
SELECT ALL - col2 - + tab0.col1 * - tab0.col1 FROM tab0
----
7363
8199
9408

query I rowsort
SELECT ALL + col0 * col2 - + 49 FROM tab1
----
113
3599
7631

query I rowsort
SELECT 57 FROM tab1, tab0 cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT + + col2 + 93 AS col1 FROM tab2 AS cor0
----
119
120
131

query I rowsort
SELECT DISTINCT - col0 * + 30 - - 73 FROM tab2 AS cor0
----
-137
-2267
-2297

query I rowsort
SELECT + col1 * col1 - - cor0.col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT - col2 + - 44 FROM tab2 AS cor0
----
-70
-71
-82

query I rowsort
SELECT - col2 * 87 AS col1 FROM tab2
----
-2262
-2349
-3306

query I rowsort
SELECT + col0 * + 49 AS col2 FROM tab1
----
147
3136
3920

query I rowsort
SELECT DISTINCT 45 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-8428
SELECT - col0 DIV 97 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8428
SELECT - col0 / 97 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8429
SELECT col2 * + CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8429
SELECT col2 * + CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 61 * - 62 FROM tab0 AS cor0
----
-3782
-3782
-3782

query I rowsort
SELECT cor0.col2 * ( + cor0.col1 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT tab1.col1 * 25 FROM tab1, tab1 AS cor0
----
250
325
650

query I rowsort
SELECT - col1 * + col0 * cor0.col0 FROM tab1 cor0
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col2 col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL 84 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT - col2 + 12 FROM tab0 AS cor0
----
-21
-70
11

query I rowsort
SELECT - col0 * + col1 * - ( - 42 ) + col2 + col1 FROM tab2 cor0
----
-193199
-56351
-9056

query I rowsort
SELECT ALL ( - cor0.col1 ) + col2 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL 76 * col1 FROM tab0 AS cor0
----
6536
6916
7372

query I rowsort
SELECT 83 * - col2 + tab0.col1 FROM tab0
----
-2653
-6715
14

query I rowsort
SELECT - 45 + col2 FROM tab0 AS cor0
----
-12
-44
37

query I rowsort
SELECT - - col2 * + col2 + + 59 - cor0.col0 AS col2 FROM tab0 AS cor0
----
1124
25
6694

onlyif mysql # use DIV operator for integer division
query I rowsort label-8443
SELECT + cor0.col0 + + cor0.col0 + col0 DIV + col2 FROM tab0 cor0
----
105
179
48

skipif mysql # not compatible
query I rowsort label-8443
SELECT + cor0.col0 + + cor0.col0 + col0 / + col2 FROM tab0 cor0
----
105
179
48

query I rowsort
SELECT ALL - 48 * cor0.col0 FROM tab2 AS cor0
----
-336
-3744
-3792

onlyif mysql # use DIV operator for integer division
query I rowsort label-8445
SELECT DISTINCT - 64 DIV - col1 + cor0.col0 * + col0 + + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
4202
6573
687

skipif mysql # not compatible
query I rowsort label-8445
SELECT DISTINCT - 64 / - col1 + cor0.col0 * + col0 + + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
4202
6573
687

query I rowsort
SELECT DISTINCT - col0 + cor0.col2 AS col0 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT - 33 + + col2 AS col2 FROM tab2 AS cor0
----
-6
-7
5

query I rowsort
SELECT ALL + - 46 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-2484
-2622
-4416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8449
SELECT DISTINCT + CAST( - col2 AS SIGNED ) AS col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-8449
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT 61 * + col0 AS col1 FROM tab0 AS cor0
----
1464
2135
5429

query I rowsort
SELECT ALL + - 31 * col2 + 6 AS col0 FROM tab2 AS cor0
----
-1172
-800
-831

query I rowsort
SELECT cor0.col0 + ( col0 ) * - col0 - 5 FROM tab2 cor0
----
-47
-6011
-6167

query I rowsort
SELECT - col0 - - col0 * 41 FROM tab0
----
1400
3560
960

query I rowsort
SELECT DISTINCT tab0.col2 FROM tab0, tab1 AS cor0, tab1 cor1
----
1
33
82

query I rowsort
SELECT + - 18 AS col2 FROM tab0 AS cor0
----
-18
-18
-18

query I rowsort
SELECT DISTINCT col1 * - ( + col1 ) AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - col2 * - ( col1 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - 98 FROM tab0, tab1 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT cor0.col2 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL 84 FROM tab0, tab2 cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT - 71 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

query I rowsort
SELECT - col0 * 87 AS col2 FROM tab1
----
-261
-5568
-6960

query I rowsort
SELECT 20 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT DISTINCT + 34 FROM tab0, tab1 AS cor0
----
34

query I rowsort
SELECT DISTINCT + cor0.col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
7
78
79

query I rowsort
SELECT - - ( col2 ) * cor0.col0 * + cor0.col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + ( col2 ) * col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL + ( - 43 ) AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT - 35 FROM tab1 cor0
----
-35
-35
-35

query I rowsort
SELECT DISTINCT col1 + cor0.col0 * col0 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT - 16 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 71c8b08964ab47ce12158975c0ee1fd9

query I rowsort
SELECT ALL - tab2.col1 * col2 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - cor0.col2 + + cor0.col2 + 21 FROM tab1 AS cor0
----
21

query I rowsort
SELECT DISTINCT + 34 AS col2 FROM tab2 AS cor0
----
34

query I rowsort
SELECT ALL col2 * + col0 * ( - col0 ) + + col1 AS col0 FROM tab2 AS cor0
----
-1292
-158125
-237141

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col1 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + cor0.col0 + tab2.col1 * - 15 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ec249bef78565b60c482f9058ed86f72

query I rowsort
SELECT DISTINCT col0 + - ( col1 ) + - col1 FROM tab2
----
-40
-55
45

query I rowsort
SELECT col2 * + 50 FROM tab1
----
2700
2850
4800

onlyif mysql # use DIV operator for integer division
query I rowsort label-8480
SELECT ALL col1 DIV + 64 + col2 + col0 FROM tab0
----
172
37
58

skipif mysql # not compatible
query I rowsort label-8480
SELECT ALL col1 / + 64 + col2 + col0 FROM tab0
----
172
37
58

query I rowsort
SELECT tab0.col1 + col0 AS col1 FROM tab0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col0 + + col0 col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + - col0 + cor0.col1 + ( col2 ) AS col0 FROM tab2 AS cor0
----
-24
51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8484
SELECT ALL - col2 DIV 53 + + cor0.col2 + - col1 FROM tab0 AS cor0
----
-10
-53
-96

skipif mysql # not compatible
query I rowsort label-8484
SELECT ALL - col2 / 53 + + cor0.col2 + - col1 FROM tab0 AS cor0
----
-10
-53
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8485
SELECT - cor0.col0 * - CAST( col0 AS SIGNED ) + + cor0.col0 * ( col1 * - col2 ) AS col1 FROM tab2 AS cor0
----
-113568
-44793
-5810

skipif mysql # not compatible
query I rowsort label-8485
SELECT - cor0.col0 * - CAST ( col0 AS INTEGER ) + + cor0.col0 * ( col1 * - col2 ) AS col1 FROM tab2 AS cor0
----
-113568
-44793
-5810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8486
SELECT + col2 + CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8486
SELECT + col2 + CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * col1 * + col1 AS col0 FROM tab0 AS cor0
----
244068
679042
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8488
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * + 94 + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8488
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * + 94 + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + col1 - 77 AS col0 FROM tab1 AS cor0
----
-103
-87
-90

query I rowsort
SELECT DISTINCT - 94 AS col0 FROM tab0 AS cor0
----
-94

query I rowsort
SELECT + 15 * ( cor0.col0 + ( + col0 ) ) AS col1 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT ALL - 47 + col2 * - col1 * col0 AS col1 FROM tab0 AS cor0
----
-3442
-664165
-68159

onlyif mysql # use DIV operator for integer division
query I rowsort label-8493
SELECT col1 DIV + 21 FROM tab2 cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-8493
SELECT col1 / + 21 FROM tab2 cor0
----
0
1
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8494
SELECT ALL + + CAST( NULL AS SIGNED ) * + 67 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8494
SELECT ALL + + CAST ( NULL AS INTEGER ) * + 67 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( col1 AS REAL ) * - col0 + 94 FROM tab0 AS cor0
----
-1970
-3301
-8005

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8496
SELECT ALL CAST( NULL AS SIGNED ) * + 64 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8496
SELECT ALL CAST ( NULL AS INTEGER ) * + 64 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * 85 FROM tab0 AS cor0
----
7310
7735
8245

onlyif mysql # use DIV operator for integer division
query I rowsort label-8498
SELECT ALL - + ( 28 ) DIV + col0 AS col2 FROM tab1 AS cor0
----
-9
0
0

skipif mysql # not compatible
query I rowsort label-8498
SELECT ALL - + ( 28 ) / + col0 AS col2 FROM tab1 AS cor0
----
-9
0
0

query I rowsort
SELECT + 46 * 51 FROM tab1 AS cor0
----
2346
2346
2346

query I rowsort
SELECT DISTINCT + ( + cor0.col1 ) + col1 * ( + col2 ) * col0 FROM tab1 AS cor0
----
36490
4238
99853

query I rowsort
SELECT DISTINCT col0 + col0 + ( 26 ) AS col0 FROM tab2
----
182
184
40

query I rowsort
SELECT DISTINCT 71 * - col2 FROM tab1
----
-3834
-4047
-6816

query I rowsort
SELECT DISTINCT + col2 * + tab2.col0 + ( 24 ) + + col1 * ( 75 ) FROM tab2
----
2538
4301
6477

query I rowsort
SELECT - 45 * - col2 + + col0 + col1 * col0 AS col0 FROM tab2 cor0
----
1439
3132
5850

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab0, tab0 cor0
----
24
35
89

query I rowsort
SELECT ALL + col1 + col2 * ( - 33 ) FROM tab1 AS cor0
----
-1756
-1871
-3155

query I rowsort
SELECT - ( + ( + cor1.col0 ) ) * + 21 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to bb7399c3066e6585d6b816df5d03b3eb

onlyif mysql # use DIV operator for integer division
query I rowsort label-8508
SELECT ALL 13 * col1 DIV - cor0.col0 AS col0 FROM tab2 AS cor0
----
-2
-57
-9

skipif mysql # not compatible
query I rowsort label-8508
SELECT ALL 13 * col1 / - cor0.col0 AS col0 FROM tab2 AS cor0
----
-2
-57
-9

query I rowsort
SELECT + col0 * - ( - col2 ) AS col2 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8510
SELECT - col2 DIV + col2 + - col1 * - col0 AS col0 FROM tab1 AS cor0
----
1039
639
77

skipif mysql # not compatible
query I rowsort label-8510
SELECT - col2 / + col2 + - col1 * - col0 AS col0 FROM tab1 AS cor0
----
1039
639
77

query I rowsort
SELECT DISTINCT + cor0.col0 + col0 * + col2 * + col1 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT DISTINCT col0 + col2 - col0 * col2 AS col1 FROM tab2 AS cor0
----
-155
-1924
-2885

query I rowsort
SELECT - col1 + ( ( col0 ) * - 33 ) AS col1 FROM tab0 AS cor0
----
-1252
-3028
-878

query I rowsort
SELECT + ( col0 * - col2 ) + col2 * + col2 FROM tab2
----
-1352
-1558
540

onlyif mysql # use DIV operator for integer division
query I rowsort label-8515
SELECT col1 DIV + col2 + + 39 + + ( col0 ) FROM tab0
----
129
171
65

skipif mysql # not compatible
query I rowsort label-8515
SELECT col1 / + col2 + + 39 + + ( col0 ) FROM tab0
----
129
171
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-8516
SELECT + col2 + + col0 * + ( col0 ) DIV - col0 FROM tab2
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-8516
SELECT + col2 + + col0 * + ( col0 ) / - col0 FROM tab2
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-8517
SELECT - 81 DIV - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8517
SELECT - 81 / - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - col0 + 31 + - col2 FROM tab0 AS cor0
----
-140
-26
-5

query I rowsort
SELECT DISTINCT - ( 52 ) * + cor0.col2 FROM tab2 AS cor0
----
-1352
-1404
-1976

query I rowsort
SELECT ALL + - ( 59 ) * + col1 + + col2 FROM tab2 AS cor0
----
-1802
-3455
-965

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8521
SELECT - CAST( NULL AS SIGNED ) + col2 * col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8521
SELECT - CAST ( NULL AS INTEGER ) + col2 * col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 48 AS col0 FROM tab1 AS cor0
----
-48

query I rowsort
SELECT DISTINCT + col2 + cor0.col1 * - col2 AS col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + + col0 + - 64 * col1 FROM tab2 AS cor0
----
-1009
-1977
-3698

query I rowsort
SELECT DISTINCT - - col1 * + col0 * col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL col0 * col0 * col0 AS col1 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT DISTINCT - col1 * + cor0.col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 51 * - ( + col0 ) col0 FROM tab0 AS cor0
----
1224
1785
4539

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 15 + + 66 col2 FROM tab2 AS cor0
----
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-8530
SELECT DISTINCT 81 DIV - 99 + col1 col0 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8530
SELECT DISTINCT 81 / - 99 + col1 col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT col2 - - ( - col2 * col1 + + col2 ) AS col0 FROM tab1
----
-1056
-1296
-456

skipif mysql # not compatible
query I rowsort
SELECT + ( col0 + + col1 * + CAST ( col1 AS REAL ) ) AS col0 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT ALL cor0.col0 + cor0.col0 AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT + 31 + col2 FROM tab1 AS cor0
----
127
85
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8535
SELECT ALL + CAST( col1 AS SIGNED ) FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-8535
SELECT ALL + CAST ( col1 AS INTEGER ) FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8536
SELECT DISTINCT - 65 DIV col0 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-8536
SELECT DISTINCT - 65 / col0 FROM tab0
----
-1
-2
0

query I rowsort
SELECT - col2 + - 90 * - col0 FROM tab2
----
603
6994
7072

query I rowsort
SELECT - 24 AS col2 FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT + + cor0.col0 + col0 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col1 col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + tab1.col1 * - ( - col0 ) AS col1 FROM tab1
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8542
SELECT ALL + CAST( - 63 AS SIGNED ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

skipif mysql # not compatible
query I rowsort label-8542
SELECT ALL + CAST ( - 63 AS INTEGER ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

query I rowsort
SELECT ALL + cor0.col0 - + 14 * col0 * col1 FROM tab2 AS cor0
----
-18723
-3031
-64350

query I rowsort
SELECT + ( cor0.col0 ) FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab2 cor1, tab2, tab2 AS cor2
----
3645 values hashing to c04c36412775e8805d6b3befa2f52917

query I rowsort
SELECT - - col2 * - col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT col1 * + ( + col1 ) AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL - col1 * ( 10 ) * col0 FROM tab0
----
-20640
-33950
-80990

query I rowsort
SELECT - + 22 AS col2 FROM tab0 AS cor0
----
-22
-22
-22

query I rowsort
SELECT ALL 23 - 9 AS col2 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT col2 + + 9 AS col0 FROM tab1 AS cor0
----
105
63
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col1 FROM tab1, tab2 cor0, tab2 cor1, tab0, tab0 AS cor2
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8553
SELECT - - CAST( col2 AS SIGNED ) + - col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8553
SELECT - - CAST ( col2 AS INTEGER ) + - col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8554
SELECT - col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8554
SELECT - col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col2 + + col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + - col2 * - ( col0 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col1 * col2 + col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - + 79 AS col1 FROM tab0 AS cor0
----
-79
-79
-79

query I rowsort
SELECT ALL + - cor2.col1 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0, tab0 AS cor2
----
243 values hashing to 7f0405f8197238fbd342972ef0bcee12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8560
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col1 * + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8560
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col1 * + col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - ( cor0.col0 ) * - cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT 66 FROM tab2, tab0 cor0
----
66

query I rowsort
SELECT - + 24 + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b261bfb2716097199f8b05bf118d9d4e

query I rowsort
SELECT + cor0.col1 + - col0 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT 71 * col0 AS col2 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT DISTINCT 11 AS col1 FROM tab1, tab1 cor0
----
11

query I rowsort
SELECT 57 + cor0.col2 FROM tab2 cor0
----
83
84
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-8568
SELECT ALL + 62 DIV 29 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

skipif mysql # not compatible
query I rowsort label-8568
SELECT ALL + 62 / 29 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT 83 AS col0 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT + - 23 FROM tab2 cor0
----
-23
-23
-23

query I rowsort
SELECT ALL - 43 + + col0 AS col1 FROM tab1 AS cor0
----
-40
21
37

query I rowsort
SELECT DISTINCT + - col2 + + col0 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL col2 * cor0.col0 * + 80 FROM tab0 AS cor0
----
2800
583840
63360

query I rowsort
SELECT ALL col1 * tab0.col2 * - col2 FROM tab0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 32 col0 FROM tab2
----
-32
-32
-32

query I rowsort
SELECT ALL + col0 + - col1 * + col2 * col2 AS col1 FROM tab1 cor0
----
-119728
-32426
-75813

query I rowsort
SELECT DISTINCT - col1 - 61 AS col1 FROM tab0 AS cor0
----
-147
-152
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-8578
SELECT DISTINCT + col2 DIV + ( - 12 ) AS col2 FROM tab1 AS cor0
----
-4
-8

skipif mysql # not compatible
query I rowsort label-8578
SELECT DISTINCT + col2 / + ( - 12 ) AS col2 FROM tab1 AS cor0
----
-4
-8

query I rowsort
SELECT ALL + col2 + + col1 * - col0 AS col0 FROM tab0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 64 - tab1.col2 col0 FROM tab1
----
-32
10
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8581
SELECT col0 + - 24 DIV ( + col2 ) AS col1 FROM tab0
----
11
24
89

skipif mysql # not compatible
query I rowsort label-8581
SELECT col0 + - 24 / ( + col2 ) AS col1 FROM tab0
----
11
24
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8582
SELECT + col1 DIV + ( 28 * - tab0.col0 ) + ( 63 ) FROM tab0
----
63
63
63

skipif mysql # not compatible
query I rowsort label-8582
SELECT + col1 / + ( 28 * - tab0.col0 ) + ( 63 ) FROM tab0
----
63
63
63

query I rowsort
SELECT col0 + - 20 AS col1 FROM tab2
----
-13
58
59

query I rowsort
SELECT DISTINCT - col2 * + 22 AS col0 FROM tab0
----
-1804
-22
-726

onlyif mysql # use DIV operator for integer division
query I rowsort label-8585
SELECT DISTINCT col2 DIV CAST( col2 AS SIGNED ) col0 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8585
SELECT DISTINCT col2 / CAST ( col2 AS INTEGER ) col0 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + tab0.col2 * 3 col1 FROM tab0
----
100
185
337

query I rowsort
SELECT ALL - col2 + - col1 * col0 - - col1 FROM tab0 AS cor0
----
-2011
-3299
-8090

query I rowsort
SELECT ALL - col2 + + 37 FROM tab1 AS cor0
----
-17
-20
-59

query I rowsort
SELECT DISTINCT 73 * col1 - - col0 AS col0 FROM tab1
----
1029
1901
794

query I rowsort
SELECT + - col2 + + col2 * + col0 * - col1 FROM tab1 AS cor0
----
-36537
-4266
-99936

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8591
SELECT CAST( col1 AS SIGNED ) + col2 + - col2 AS col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-8591
SELECT CAST ( col1 AS INTEGER ) + col2 + - col2 AS col1 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8592
SELECT - - 58 DIV - col2 AS col0 FROM tab0 AS cor0
----
-1
-58
0

skipif mysql # not compatible
query I rowsort label-8592
SELECT - - 58 / - col2 AS col0 FROM tab0 AS cor0
----
-1
-58
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8593
SELECT 94 DIV 88 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8593
SELECT 94 / 88 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL ( col1 ) - + tab1.col1 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT col2 - - col2 AS col1 FROM tab2
----
52
54
76

query I rowsort
SELECT tab1.col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT - + col2 - + cor0.col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT + + col0 * - col1 * col1 + - col0 AS col0 FROM tab0 AS cor0
----
-177528
-329350
-737098

query I rowsort
SELECT - ( + 57 ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT DISTINCT 35 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
35

query I rowsort
SELECT ALL 53 * col2 + col2 FROM tab1
----
2916
3078
5184

query I rowsort
SELECT 95 * + col2 FROM tab0 AS cor0
----
3135
7790
95

query I rowsort
SELECT + - col1 * + col0 + - 61 * col2 FROM tab0 AS cor0
----
-13101
-3456
-4077

onlyif mysql # use DIV operator for integer division
query I rowsort label-8604
SELECT DISTINCT col0 DIV col1 AS col2 FROM tab1 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-8604
SELECT DISTINCT col0 / col1 AS col2 FROM tab1 AS cor0
----
0
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - col0 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + 8 - col1 * cor0.col0 * - col0 AS col2 FROM tab0 AS cor0
----
118833
49544
720819

onlyif mysql # use DIV operator for integer division
query I rowsort label-8607
SELECT cor0.col0 DIV - cor0.col1 + - ( ( col0 ) * + col2 ) AS col1 FROM tab1 AS cor0
----
-162
-3654
-7686

skipif mysql # not compatible
query I rowsort label-8607
SELECT cor0.col0 / - cor0.col1 + - ( ( col0 ) * + col2 ) AS col1 FROM tab1 AS cor0
----
-162
-3654
-7686

query I rowsort
SELECT + - 54 * cor0.col2 - col2 FROM tab2 AS cor0
----
-1430
-1485
-2090

query I rowsort
SELECT ALL - 12 * - col2 FROM tab2 AS cor0
----
312
324
456

onlyif mysql # use DIV operator for integer division
query I rowsort label-8610
SELECT DISTINCT - + col2 DIV - cor0.col0 AS col0 FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-8610
SELECT DISTINCT - + col2 / - cor0.col0 AS col0 FROM tab2 AS cor0
----
0
3

query I rowsort
SELECT + + col0 * + col2 + - cor0.col2 * + col0 + col2 * - 22 AS col1 FROM tab1 AS cor0
----
-1188
-1254
-2112

query I rowsort
SELECT ALL - + col0 + col1 AS col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ( col0 ) * col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + col0 + ( 35 ) AS col2 FROM tab2
----
113
114
42

query I rowsort
SELECT 0 * col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 + - tab0.col0 * col1 * tab0.col0 + + col2 FROM tab0
----
-118789
-49479
-720640

query I rowsort
SELECT ALL - 92 + - tab1.col2 FROM tab1
----
-146
-149
-188

query I rowsort
SELECT DISTINCT - 20 AS col2 FROM tab1, tab1 cor0
----
-20

query I rowsort
SELECT ALL 30 + - col2 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-5
-7268
-762

query I rowsort
SELECT + cor0.col1 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ( col2 + col1 ) FROM tab2
----
55
58
85

query I rowsort
SELECT DISTINCT - 56 * tab0.col1 FROM tab0
----
-4816
-5096
-5432

query I rowsort
SELECT col1 * col2 + col0 FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - - col2 * - col0 FROM tab2 cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 33 col0 FROM tab0 AS cor0
----
-33
-33
-33

query I rowsort
SELECT ALL + 90 * col1 FROM tab1
----
1170
2340
900

query I rowsort
SELECT DISTINCT - tab0.col1 + - 74 FROM tab0, tab0 AS cor0
----
-160
-165
-171

query I rowsort
SELECT DISTINCT - col2 + - col1 + col2 * + cor0.col0 * - col1 AS col2 FROM tab0 AS cor0
----
-3493
-664291
-68231

query I rowsort
SELECT ALL - col2 * + 82 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT ALL cor0.col0 * col1 - - col0 * - col0 FROM tab2 AS cor0
----
-1482
-4898
168

query I rowsort
SELECT DISTINCT - + col0 * - col0 + + col2 AS col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL + col2 * - col2 AS col1 FROM tab1
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-8633
SELECT DISTINCT - col0 * col2 DIV col1 AS col2 FROM tab1 AS cor0
----
-364
-590
-6

skipif mysql # not compatible
query I rowsort label-8633
SELECT DISTINCT - col0 * col2 / col1 AS col2 FROM tab1 AS cor0
----
-364
-590
-6

query I rowsort
SELECT DISTINCT - col1 * 62 AS col2 FROM tab0 AS cor0
----
-5332
-5642
-6014

query I rowsort
SELECT + cor0.col2 + + col1 * + cor0.col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT col1 * - 6 FROM tab2 AS cor0
----
-102
-186
-354

query I rowsort
SELECT + col2 + - ( col1 ) AS col1 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8638
SELECT ALL - col2 DIV col2 + - tab1.col0 * - tab1.col1 AS col0 FROM tab1
----
1039
639
77

skipif mysql # not compatible
query I rowsort label-8638
SELECT ALL - col2 / col2 + - tab1.col0 * - tab1.col1 AS col0 FROM tab1
----
1039
639
77

query I rowsort
SELECT ALL tab0.col2 + + col2 AS col0 FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT - col2 * col1 * tab2.col2 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT col0 * cor0.col1 + - col1 * col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * - cor0.col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + col2 * - col2 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
-26136
-35
-598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT - col2 * + col2 * + col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT + 40 + col1 * col1 + + col1 FROM tab0 AS cor0
----
7522
8412
9546

query I rowsort
SELECT + + col2 - col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-8648
SELECT DISTINCT col0 + + 60 DIV tab0.col1 AS col2 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8648
SELECT DISTINCT col0 + + 60 / tab0.col1 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL + cor1.col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8650
SELECT DISTINCT CAST( NULL AS DECIMAL ) + 7 * + col0 AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8650
SELECT DISTINCT CAST ( NULL AS REAL ) + 7 * + col0 AS col0 FROM tab1
----
NULL

query I rowsort
SELECT + ( cor0.col0 ) + + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + + cor0.col0 + + cor0.col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT 63 AS col2 FROM tab1
----
63

query I rowsort
SELECT ALL - 18 - col0 FROM tab0 AS cor0
----
-107
-42
-53

query I rowsort
SELECT DISTINCT cor0.col0 * col0 + - col2 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT ALL col2 * - col0 * - 58 AS col2 FROM tab1 AS cor0
----
211584
445440
9396

query I rowsort
SELECT 5 + 31 FROM tab1
----
36
36
36

query I rowsort
SELECT DISTINCT - col0 + 37 * - col0 AS col0 FROM tab0
----
-1330
-3382
-912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - col1 col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT + cor0.col2 + + cor0.col1 AS col0 FROM tab0, tab2 AS cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8661
SELECT + CAST( NULL AS SIGNED ) - tab1.col0 * + tab1.col2 col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8661
SELECT + CAST ( NULL AS INTEGER ) - tab1.col0 * + tab1.col2 col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( 17 * tab0.col0 ) + 6 FROM tab0
----
1519
414
601

query I rowsort
SELECT + tab2.col1 * - col0 + 49 AS col0 FROM tab2
----
-1294
-168
-4553

query I rowsort
SELECT DISTINCT + 15 + cor0.col0 * + col0 AS col1 FROM tab2 cor0
----
6099
6256
64

query I rowsort
SELECT ALL 66 - + col1 FROM tab2 AS cor0
----
35
49
7

query I rowsort
SELECT + + 12 AS col0 FROM tab0 AS cor0
----
12
12
12

query I rowsort
SELECT - 10 + col1 FROM tab0 AS cor0
----
76
81
87

query I rowsort
SELECT DISTINCT - - cor0.col0 - col0 AS col0 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col0 ) * - ( cor0.col1 ) col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - col2 * + cor0.col1 + ( + 68 ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
-1274
3010
6499

query I rowsort
SELECT - col1 * + col2 + ( + col0 ) + - col0 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8672
SELECT + col1 * - CAST( - col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-8672
SELECT + col1 * - CAST ( - col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col1 - - ( col0 ) AS col1 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-8674
SELECT + col2 + - col0 DIV col2 + col2 DIV cor0.col1 AS col0 FROM tab1 AS cor0
----
103
56
61

skipif mysql # not compatible
query I rowsort label-8674
SELECT + col2 + - col0 / col2 + col2 / cor0.col1 AS col0 FROM tab1 AS cor0
----
103
56
61

query I rowsort
SELECT ( - col0 ) + - col0 * - col2 AS col1 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL - col2 + col0 + col0 FROM tab2 AS cor0
----
-13
120
130

query I rowsort
SELECT DISTINCT 50 * - cor0.col1 AS col2 FROM tab0, tab2 AS cor0
----
-1550
-2950
-850

query I rowsort
SELECT DISTINCT - + col0 * col0 - col1 * + ( + col2 ) AS col0 FROM tab2 AS cor0
----
-6887
-7618
-886

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8679
SELECT CAST( + ( - col1 ) AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-8679
SELECT CAST ( + ( - col1 ) AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + ( - 83 ) * col2 FROM tab1
----
-4482
-4731
-7968

query I rowsort
SELECT ALL - col0 * - ( col0 ) FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-8682
SELECT ALL - col2 + + 0 DIV - col0 FROM tab2 cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-8682
SELECT ALL - col2 + + 0 / - col0 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT + ( 67 ) FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT - 8 + + col0 FROM tab1
----
-5
56
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-8685
SELECT - col1 DIV col1 + - col2 + - col1 FROM tab1 AS cor0
----
-110
-68
-81

skipif mysql # not compatible
query I rowsort label-8685
SELECT - col1 / col1 + - col2 + - col1 FROM tab1 AS cor0
----
-110
-68
-81

query I rowsort
SELECT - - 6 + + 64 FROM tab0 AS cor0
----
70
70
70

query I rowsort
SELECT DISTINCT + col0 * col0 * - col2 FROM tab1 AS cor0
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-8688
SELECT ALL + 56 + col2 DIV col0 FROM tab1 AS cor0
----
56
57
74

skipif mysql # not compatible
query I rowsort label-8688
SELECT ALL + 56 + col2 / col0 FROM tab1 AS cor0
----
56
57
74

query I rowsort
SELECT ( - 5 ) + + col0 FROM tab1 AS cor0
----
-2
59
75

query I rowsort
SELECT + + cor0.col0 + col1 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT col1 * + 55 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT + ( + col0 ) - + col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + 82 * col2 + col0 FROM tab0 AS cor0
----
117
2730
6813

query I rowsort
SELECT col2 + - col1 * col2 + col0 AS col0 FROM tab0 AS cor0
----
-2781
-61
-7291

query I rowsort
SELECT ALL + ( col2 ) + + col1 * - col1 * + col2 FROM tab2 AS cor0
----
-10944
-25920
-90480

onlyif mysql # use DIV operator for integer division
query I rowsort label-8696
SELECT DISTINCT col1 DIV col0 col2 FROM tab1 AS cor0
----
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8696
SELECT DISTINCT col1 / col0 col2 FROM tab1 AS cor0
----
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8697
SELECT ALL - col2 DIV + col1 + - CAST( 60 AS SIGNED ) + + col1 FROM tab1 AS cor0
----
-36
-54
-55

skipif mysql # not compatible
query I rowsort label-8697
SELECT ALL - col2 / + col1 + - CAST ( 60 AS INTEGER ) + + col1 FROM tab1 AS cor0
----
-36
-54
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-8698
SELECT + 29 DIV col1 AS col2 FROM tab1 AS cor0
----
1
2
2

skipif mysql # not compatible
query I rowsort label-8698
SELECT + 29 / col1 AS col2 FROM tab1 AS cor0
----
1
2
2

query I rowsort
SELECT - col2 - col1 * - col0 FROM tab1
----
24
583
944

query I rowsort
SELECT DISTINCT - col2 * - ( - col1 ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-8701
SELECT + col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8701
SELECT + col0 / - col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8702
SELECT DISTINCT col2 * + col0 DIV - col0 AS col0 FROM tab0 cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8702
SELECT DISTINCT col2 * + col0 / - col0 AS col0 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT ALL - + col0 * + 37 AS col1 FROM tab2 AS cor0
----
-259
-2886
-2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8704
SELECT DISTINCT + col2 * CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-8704
SELECT DISTINCT + col2 * CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL - col1 + + col1 + 93 AS col0 FROM tab2 cor0
----
93
93
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor1.col0 + 38 col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
-40
-41
31

query I rowsort
SELECT ALL col0 + ( + col0 ) - - col2 AS col1 FROM tab2
----
182
196
41

query I rowsort
SELECT DISTINCT + col2 * col0 - col0 * tab0.col2 FROM tab0
----
0

query I rowsort
SELECT DISTINCT - 33 AS col1 FROM tab1, tab2 AS cor0
----
-33

query I rowsort
SELECT ALL + cor0.col1 * col2 * - col1 AS col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL col2 + - tab1.col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT col1 * + 42 AS col1 FROM tab2 AS cor0
----
1302
2478
714

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8713
SELECT - + col1 * + CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-8713
SELECT - + col1 * + CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
-289
-3481
-961

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab0 cor1, tab1, tab2 AS cor2
----
3645 values hashing to df00d19f178a708f636b036dcb6c6f87

query I rowsort
SELECT DISTINCT + col2 * + col0 + cor0.col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT + + col0 + + col0 - col2 AS col0 FROM tab1 AS cor0
----
-48
64
71

query I rowsort
SELECT 98 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 86 + col2 col2 FROM tab2
----
112
113
124

query I rowsort
SELECT + cor0.col2 + cor0.col0 * col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT 92 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT DISTINCT - 44 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 + col2 col0 FROM tab1 AS cor0
----
108
66
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 col2 FROM tab2 AS cor0
----
11
11
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8724
SELECT - CAST( NULL AS SIGNED ) * - col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8724
SELECT - CAST ( NULL AS INTEGER ) * - col2 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + tab2.col2 + + tab2.col0 * tab2.col0 * - col0 AS col0 FROM tab2
----
-316
-474526
-493001

query I rowsort
SELECT + 87 AS col1 FROM tab2
----
87
87
87

query I rowsort
SELECT ALL + col1 * + 64 AS col0 FROM tab1
----
1664
640
832

query I rowsort
SELECT - ( col1 ) + + col2 AS col2 FROM tab1
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8729
SELECT DISTINCT + col0 DIV col2 + col2 FROM tab1
----
54
58
96

skipif mysql # not compatible
query I rowsort label-8729
SELECT DISTINCT + col0 / col2 + col2 FROM tab1
----
54
58
96

query I rowsort
SELECT - 97 + + col2 * - col1 + + ( - tab2.col0 ) * + col1 FROM tab2
----
-1151
-2086
-6233

query I rowsort
SELECT DISTINCT + col2 + + 23 * col0 * + 96 AS col0 FROM tab0
----
196594
53025
77281

query I rowsort
SELECT col2 + col0 * + col0 FROM tab2 cor0
----
6110
6279
76

query I rowsort
SELECT ALL 46 - col0 FROM tab2 AS cor0
----
-32
-33
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - cor0.col0 ) + col1 * col2 col2 FROM tab0 cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-8735
SELECT - - ( - col0 ) DIV - 81 + col2 AS col1 FROM tab0 AS cor0
----
1
33
83

skipif mysql # not compatible
query I rowsort label-8735
SELECT - - ( - col0 ) / - 81 + col2 AS col1 FROM tab0 AS cor0
----
1
33
83

query I rowsort
SELECT DISTINCT - col2 + col2 * + col0 * + col0 + col1 FROM tab0 AS cor0
----
1321
19061
649531

query I rowsort
SELECT - + 67 + cor0.col2 FROM tab1 AS cor0
----
-10
-13
29

query I rowsort
SELECT DISTINCT - - ( - cor0.col0 ) * 33 + + col2 * col0 FROM tab0 AS cor0
----
-1120
0
4361

query I rowsort
SELECT - tab2.col2 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT - cor0.col2 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-26
-27
-38

query I rowsort
SELECT ALL + ( + col2 ) * + col0 * + 8 AS col2 FROM tab0
----
280
58384
6336

query I rowsort
SELECT - + col1 * + col2 * col2 + + col2 * - col2 + ( col2 * col0 ) AS col1 FROM tab1 AS cor0
----
-121344
-32091
-78570

query I rowsort
SELECT DISTINCT - 33 * - col0 * 54 - + col0 AS col1 FROM tab1
----
113984
142480
5343

query I rowsort
SELECT col1 + ( 30 ) FROM tab1 AS cor0
----
40
43
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 55 col1 FROM tab0 AS cor0
----
-1815
-4510
-55

query I rowsort
SELECT ALL tab2.col0 * - col0 * + col1 + col1 FROM tab2
----
-106080
-1488
-358897

query I rowsort
SELECT ALL col2 * - col0 + + col0 * + col0 FROM tab2
----
-140
3239
4056

query I rowsort
SELECT + + col2 * + ( - 74 ) + - col1 FROM tab2 AS cor0
----
-1983
-2029
-2829

onlyif mysql # use DIV operator for integer division
query I rowsort label-8749
SELECT - + col1 DIV 73 + + col1 * col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-8749
SELECT - + col1 / 73 + + col1 * col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + col0 * - ( col1 ) + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT - col0 + - 76 * col0 AS col1 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT DISTINCT + - ( col1 ) * + col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT 11 AS col1 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
11

query I rowsort
SELECT - ( + 47 ) + col0 AS col0 FROM tab2 AS cor0
----
-40
31
32

query I rowsort
SELECT - - 3 * - col2 FROM tab1 cor0
----
-162
-171
-288

query I rowsort
SELECT - - col2 * col2 * col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT ( col1 ) * - col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + 14 - col1 FROM tab1 AS cor0
----
-12
1
4

query I rowsort
SELECT DISTINCT 40 AS col1 FROM tab1, tab1 AS cor0
----
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 48 col1 FROM tab1, tab0 cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT - - col2 - col0 * col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT col2 * col0 + + tab2.col2 AS col0 FROM tab2
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col0 col0 FROM tab1
----
128
160
6

query I rowsort
SELECT - tab2.col0 * col1 + col1 AS col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT + col0 * + col2 + - col1 AS col0 FROM tab1
----
136
3638
7667

query I rowsort
SELECT + col1 * - col0 + tab1.col1 AS col2 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT - col2 + - col0 * + tab1.col1 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT ALL col1 * col2 + - tab2.col2 AS col2 FROM tab2
----
1508
608
810

query I rowsort
SELECT DISTINCT - tab1.col0 + + col0 FROM tab1
----
0

query I rowsort
SELECT ALL - tab2.col0 + + tab2.col2 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT + col2 * col0 - + tab0.col2 AS col1 FROM tab0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-8772
SELECT DISTINCT + col0 DIV + col1 + col1 + + col0 AS col0 FROM tab0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-8772
SELECT DISTINCT + col0 / + col1 + col1 + + col0 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT - col2 * col2 * - col2 FROM tab0
----
1
35937
551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-8774
SELECT DISTINCT - tab0.col2 DIV - col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-8774
SELECT DISTINCT - tab0.col2 / - col1 AS col0 FROM tab0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8775
SELECT + col1 + - col2 DIV - col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8775
SELECT + col1 + - col2 / - col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + col0 + + col1 * + col2 FROM tab2
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 col1 FROM tab0
----
171
36
57

query I rowsort
SELECT - col2 + - col0 FROM tab2 WHERE NOT + col1 NOT IN ( - col1 - + col2 * - tab2.col0 )
----

query I rowsort
SELECT DISTINCT tab0.col2 * col1 + col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL - col1 FROM tab0 WHERE NOT - col2 + col1 BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT DISTINCT + tab2.col1 * col2 * col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL col1 AS col0 FROM tab2 WHERE NOT NULL IN ( tab2.col0 )
----

query I rowsort
SELECT DISTINCT col2 + col2 - - col2 FROM tab0
----
246
3
99

query I rowsort
SELECT + col2 * tab1.col2 AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT col2 * - col2 FROM tab0 WHERE NULL NOT IN ( + col2 )
----

query I rowsort
SELECT ALL - col0 * col2 * - col0 AS col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT ALL tab2.col0 * - tab2.col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + col0 * - col1 + col2 * col0 AS col0 FROM tab0
----
-1272
-3360
-801

query I rowsort
SELECT ALL - tab1.col0 + col2 FROM tab1
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 * col2 + + col0 + col2 col0 FROM tab2
----
1561
763
780

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL IN ( + col0 )
----

query I rowsort
SELECT DISTINCT tab1.col1 * - col0 AS col0 FROM tab1
----
-1040
-640
-78

query III rowsort
SELECT * FROM tab2 WHERE + col2 * + col1 >= col2
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL tab1.col0 * + tab1.col2 * + col0 AS col2 FROM tab1
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 * - col1 col2 FROM tab2 AS cor0
----
-106097
-1519
-358956

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col0 = ( NULL )
----

query I rowsort
SELECT col1 - + tab1.col2 AS col1 FROM tab1
----
-28
-47
-83

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) IN ( col1 )
----

query I rowsort
SELECT - col1 * col2 + col0 * - col2 * + col0 AS col2 FROM tab1 AS cor0
----
-1890
-234042
-615648

query I rowsort
SELECT ALL - tab1.col1 * col2 + col2 + + col0 AS col2 FROM tab1
----
-1072
-1347
-449

onlyif mysql # use DIV operator for integer division
query I rowsort label-8801
SELECT + col2 + - col1 - tab1.col2 DIV - col2 AS col1 FROM tab1
----
29
48
84

skipif mysql # not compatible
query I rowsort label-8801
SELECT + col2 + - col1 - tab1.col2 / - col2 AS col1 FROM tab1
----
29
48
84

query I rowsort
SELECT DISTINCT - col0 + + tab1.col1 + + tab1.col2 FROM tab1
----
29
3
77

query I rowsort
SELECT ALL + tab2.col2 * - col0 + col2 + tab2.col0 FROM tab2
----
-155
-1924
-2885

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * cor0.col1 col2 FROM tab2 AS cor0
----
1475
629
806

query IIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0 WHERE NULL >= NULL
----

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 cor2
----
972 values hashing to 8b4fcda7f1ca76bad7c7d728f54a51e0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8807
SELECT + col1 * col1 DIV - col2 AS col1 FROM tab0
----
-100
-224
-9409

skipif mysql # not compatible
query I rowsort label-8807
SELECT + col1 * col1 / - col2 AS col1 FROM tab0
----
-100
-224
-9409

query I rowsort
SELECT ALL - col1 * col2 * cor0.col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 + cor0.col2 * col0 col2 FROM tab0 cor0
----
132
7389
878

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + 39 AS REAL ) * + col2 + col2 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT ALL - ( ( + col2 ) ) * - col2 * - col0 + cor0.col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 39 col1 FROM tab1
----
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-8813
SELECT DISTINCT - col2 + 96 DIV 78 - col1 FROM tab0
----
-118
-172
-97

skipif mysql # not compatible
query I rowsort label-8813
SELECT DISTINCT - col2 + 96 / 78 - col1 FROM tab0
----
-118
-172
-97

query I rowsort
SELECT DISTINCT - + 80 * col2 - - col0 AS col0 FROM tab1 AS cor0
----
-4317
-4496
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-8815
SELECT 35 DIV cor0.col0 - - col0 AS col1 FROM tab1 cor0
----
14
64
80

skipif mysql # not compatible
query I rowsort label-8815
SELECT 35 / cor0.col0 - - col0 AS col1 FROM tab1 cor0
----
14
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * 85 col1 FROM tab1 AS cor0
----
4590
4845
8160

onlyif mysql # use DIV operator for integer division
query I rowsort label-8817
SELECT 92 DIV 76 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

skipif mysql # not compatible
query I rowsort label-8817
SELECT 92 / 76 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8818
SELECT - + ( col1 ) DIV + 95 + - col1 FROM tab0 cor0
----
-86
-91
-98

skipif mysql # not compatible
query I rowsort label-8818
SELECT - + ( col1 ) / + 95 + - col1 FROM tab0 cor0
----
-86
-91
-98

query I rowsort
SELECT DISTINCT - + 36 * - col2 * 98 AS col1 FROM tab0 AS cor0
----
116424
289296
3528

query I rowsort
SELECT ALL 76 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to a8a6c4c5005303c62d4e50b6c96b584f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col2 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col1 * col0 + - cor0.col1 * - cor0.col1 FROM tab2 AS cor0
----
1178
1632
8083

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8823
SELECT ALL - - 24 + col1 * + CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
-2040
-3371
-8075

skipif mysql # not compatible
query I rowsort label-8823
SELECT ALL - - 24 + col1 * + CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
-2040
-3371
-8075

query I rowsort
SELECT DISTINCT + - col0 * - 41 AS col1 FROM tab2 AS cor0
----
287
3198
3239

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - 45 col1 FROM tab0 AS cor0
----
-3870
-4095
-4365

query I rowsort
SELECT DISTINCT + 67 * - col2 * + col0 AS col2 FROM tab1
----
-10854
-244416
-514560

query I rowsort
SELECT ALL col2 + 36 AS col2 FROM tab1 AS cor0
----
132
90
93

query I rowsort
SELECT DISTINCT col0 * + ( + ( cor0.col0 ) ) * - cor0.col0 AS col1 FROM tab2 cor0
----
-343
-474552
-493039

query I rowsort
SELECT DISTINCT 84 * col2 FROM tab2
----
2184
2268
3192

query I rowsort
SELECT 44 + - col0 AS col2 FROM tab2
----
-34
-35
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-8831
SELECT - + col2 DIV col2 + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-8831
SELECT - + col2 / col2 + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT - ( - ( - cor0.col1 ) ) * ( 67 * col2 ) + + 18 * col1 * + col0 + col0 FROM tab2 AS cor0
----
-19029
-19864
-52166

query I rowsort
SELECT + - col2 * - col0 + - col1 * ( col1 ) FROM tab1 AS cor0
----
-514
3548
7511

query I rowsort
SELECT + - col0 + 64 * col2 + 80 AS col0 FROM tab2 AS cor0
----
1666
1801
2433

query I rowsort
SELECT ALL col1 * 6 AS col1 FROM tab1 AS cor0
----
156
60
78

query I rowsort
SELECT + cor0.col2 + + col0 * cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
13616
2082
6457

query I rowsort
SELECT + 69 * cor0.col2 + col0 * + ( + col2 ) + + col0 FROM tab2 AS cor0
----
2059
3900
5703

query I rowsort
SELECT 72 + cor0.col1 AS col0 FROM tab2 AS cor0
----
103
131
89

query I rowsort
SELECT - 63 * col1 * + col2 AS col0 FROM tab2 AS cor0
----
-40698
-52731
-96642

query I rowsort
SELECT col2 + col1 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT + + col0 * - col2 * - col1 AS col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + col1 * col2 * col1 AS col0 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT ALL - col0 * col1 + + ( + col0 + - col2 * col2 ) AS col2 FROM tab2 AS cor0
----
-2708
-5200
-939

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8844
SELECT + col2 * CAST( NULL AS SIGNED ) + - col0 + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8844
SELECT + col2 * CAST ( NULL AS INTEGER ) + - col0 + - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 87 AS col2 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT - col2 + 96 + col0 AS col2 FROM tab0 AS cor0
----
103
130
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + 63 + 24 * col1 col2 FROM tab2
----
-1986
-222
-957

query I rowsort
SELECT - 58 * col2 FROM tab1 AS cor0
----
-3132
-3306
-5568

onlyif mysql # use DIV operator for integer division
query I rowsort label-8849
SELECT col0 DIV 28 FROM tab0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-8849
SELECT col0 / 28 FROM tab0
----
0
1
3

query I rowsort
SELECT - col2 * - 41 FROM tab1
----
2214
2337
3936

query I rowsort
SELECT - tab1.col2 * 11 * + tab1.col1 FROM tab1
----
-13728
-15444
-6270

onlyif mysql # use DIV operator for integer division
query I rowsort label-8852
SELECT ALL col2 DIV - tab1.col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8852
SELECT ALL col2 / - tab1.col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT - 35 * 75 FROM tab1, tab0 AS cor0
----
9 values hashing to bba1fc599843419a248d10e7bc0ffca0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8854
SELECT + col1 + + col1 + - cor0.col2 / CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8854
SELECT + col1 + + col1 + - cor0.col2 / CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( - 25 ) + col0 AS col1 FROM tab1 AS cor0
----
-22
39
55

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 WHERE NOT ( NULL ) < ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 55 col0 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
55

query I rowsort
SELECT col1 + col2 * - col0 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-673
-7125
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8859
SELECT + CAST( NULL AS DECIMAL ) + 61 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-8859
SELECT + CAST ( NULL AS REAL ) + 61 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL - 1 + - cor0.col0 * cor0.col2 FROM tab0 AS cor0
----
-36
-7299
-793

query I rowsort
SELECT ALL col2 * 63 + - col0 + + col1 * - 45 AS col0 FROM tab1 AS cor0
----
2229
3077
5383

query I rowsort
SELECT ALL - tab0.col0 - col1 * + tab0.col1 AS col2 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT ALL ( 1 ) AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT - col1 * + col0 + + col2 + col2 AS col0 FROM tab1 AS cor0
----
-526
-848
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 21 * col1 + + col0 + ( + col2 ) col0 FROM tab1 AS cor0
----
-489
-89
-97

query I rowsort
SELECT + - 98 + - col2 AS col0 FROM tab2 AS cor0
----
-124
-125
-136

query I rowsort
SELECT DISTINCT 79 FROM tab1 cor0
----
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( ( cor0.col1 ) ) * + ( - 99 ) col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 061cf7a4b9d04456c4b643bde0d131df

onlyif mysql # use DIV operator for integer division
query I rowsort label-8870
SELECT 24 + col1 DIV - col1 col1 FROM tab1 AS cor0
----
23
23
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8870
SELECT 24 + col1 / - col1 col1 FROM tab1 AS cor0
----
23
23
23

query I rowsort
SELECT ALL + col2 - 26 FROM tab1
----
28
31
70

query I rowsort
SELECT 71 * + 16 + - col0 FROM tab2
----
1057
1058
1129

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 39 col0 FROM tab0, tab2 AS cor0, tab2 cor1
----
-39

query I rowsort
SELECT - 80 AS col2 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 26dbcc98d4b4e864ffa31be685a5dfbd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + cor0.col0 * col1 col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL + - cor0.col1 * col0 - col0 AS col2 FROM tab2 AS cor0
----
-1422
-224
-4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8877
SELECT DISTINCT - - col0 + - col0 DIV - 63 + col2 DIV col1 FROM tab2 cor0
----
7
79
82

skipif mysql # not compatible
query I rowsort label-8877
SELECT DISTINCT - - col0 + - col0 / - 63 + col2 / col1 FROM tab2 cor0
----
7
79
82

query I rowsort
SELECT col1 + + ( - col2 ) AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + col0 + col0 * col2 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8880
SELECT cor0.col1 + CAST( col1 AS SIGNED ) * - col1 FROM tab1 cor0
----
-156
-650
-90

skipif mysql # not compatible
query I rowsort label-8880
SELECT cor0.col1 + CAST ( col1 AS INTEGER ) * - col1 FROM tab1 cor0
----
-156
-650
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 + cor0.col1 * + col2 col0 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT DISTINCT tab0.col2 FROM tab0, tab1, tab2 AS cor0, tab2 AS cor1
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8883
SELECT DISTINCT - 69 DIV - col0 + col1 + + 37 * + col0 FROM tab0
----
1393
3384
976

skipif mysql # not compatible
query I rowsort label-8883
SELECT DISTINCT - 69 / - col0 + col1 + + 37 * + col0 FROM tab0
----
1393
3384
976

query I rowsort
SELECT ALL col2 * tab2.col0 + + tab2.col0 + - col0 AS col2 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col1 + - col0 col0 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT + 2 + - col1 FROM tab2
----
-15
-29
-57

query I rowsort
SELECT - + col2 * - col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - cor0.col0 * col1 * col0 AS col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL cor0.col2 * 1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + 90 * - col2 col1 FROM tab0 AS cor0
----
-2884
-7289
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8891
SELECT DISTINCT - cor0.col1 DIV + col0 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-8891
SELECT DISTINCT - cor0.col1 / + col0 FROM tab2 AS cor0
----
-4
0

query I rowsort
SELECT DISTINCT col1 * col0 + cor0.col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-8893
SELECT ALL - col0 + - col0 DIV + col2 FROM tab1 AS cor0
----
-3
-65
-80

skipif mysql # not compatible
query I rowsort label-8893
SELECT ALL - col0 + - col0 / + col2 FROM tab1 AS cor0
----
-3
-65
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8894
SELECT DISTINCT col1 * col1 - cor0.col2 * col2 DIV - col0 FROM tab2 cor0
----
1065
307
3489

skipif mysql # not compatible
query I rowsort label-8894
SELECT DISTINCT col1 * col1 - cor0.col2 * col2 / - col0 FROM tab2 cor0
----
1065
307
3489

query I rowsort
SELECT ALL + col1 + ( - col2 ) * col0 AS col1 FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8896
SELECT + - col0 - - CAST( + col1 AS SIGNED ) FROM tab1 cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-8896
SELECT + - col0 - - CAST ( + col1 AS INTEGER ) FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT col2 + + 89 * 3 AS col0 FROM tab2 AS cor0
----
293
294
305

query I rowsort
SELECT DISTINCT + cor0.col1 + ( - col2 ) FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT - cor0.col0 + - col1 * + col1 AS col0 FROM tab1 cor0
----
-164
-249
-679

onlyif mysql # use DIV operator for integer division
query I rowsort label-8900
SELECT ALL + col0 * CAST( col2 AS SIGNED ) DIV - col0 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8900
SELECT ALL + col0 * CAST ( col2 AS INTEGER ) / - col0 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * 22 - col1 col0 FROM tab0 AS cor0
----
-2049
-614
-867

query I rowsort
SELECT + cor0.col2 + - 68 * 22 + col2 FROM tab1 AS cor0
----
-1304
-1382
-1388

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 95 col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT ALL col2 * col1 * 62 - + col0 FROM tab2
----
39973
51887
95030

query I rowsort
SELECT - col0 + - tab1.col2 + - col0 * - tab1.col2 AS col2 FROM tab1
----
105
3527
7504

query I rowsort
SELECT ALL - col0 + - 53 AS col1 FROM tab1 AS cor0
----
-117
-133
-56

query I rowsort
SELECT DISTINCT + col1 * + 28 + 43 FROM tab0 AS cor0
----
2451
2591
2759

query I rowsort
SELECT + 24 - tab0.col1 * + 0 AS col1 FROM tab0
----
24
24
24

query I rowsort
SELECT + col2 * col1 + + col1 * + tab1.col2 AS col2 FROM tab1
----
1140
2496
2808

onlyif mysql # use DIV operator for integer division
query I rowsort label-8910
SELECT DISTINCT - col1 DIV cor0.col0 + - col0 AS col2 FROM tab1 cor0
----
-11
-64
-80

skipif mysql # not compatible
query I rowsort label-8910
SELECT DISTINCT - col1 / cor0.col0 + - col0 AS col2 FROM tab1 cor0
----
-11
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 32 + + cor0.col1 * + col1 col2 FROM tab1 AS cor0
----
132
201
708

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 25 col0 FROM tab0 AS cor0
----
-25
-25
-25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col0 ) * - col0 col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - - col2 + ( col1 ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - - 17 AS col0 FROM tab1 AS cor0
----
17

query I rowsort
SELECT + - 86 * col0 FROM tab1 AS cor0
----
-258
-5504
-6880

query I rowsort
SELECT DISTINCT - col0 + - 11 FROM tab2 AS cor0
----
-18
-89
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-8918
SELECT + ( - col1 ) DIV + col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8918
SELECT + ( - col1 ) / + col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 + + col2 * + col2 AS col0 FROM tab0 AS cor0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-8920
SELECT ( col1 ) DIV cor0.col2 col0 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8920
SELECT ( col1 ) / cor0.col2 col0 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT - col0 * - ( col1 ) FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + 87 * - col0 col2 FROM tab2 AS cor0
----
-578
-6727
-6856

query I rowsort
SELECT ALL 78 + col0 AS col0 FROM tab1 AS cor0
----
142
158
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-8924
SELECT + - col2 DIV col0 col2 FROM tab1 AS cor0
----
-1
-18
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8924
SELECT + - col2 / col0 col2 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT 59 * - 32 * col0 AS col0 FROM tab2 AS cor0
----
-13216
-147264
-149152

onlyif mysql # use DIV operator for integer division
query I rowsort label-8926
SELECT DISTINCT col2 DIV col0 + + 67 * + 56 AS col0 FROM tab2 AS cor0
----
3752
3755

skipif mysql # not compatible
query I rowsort label-8926
SELECT DISTINCT col2 / col0 + + 67 * + 56 AS col0 FROM tab2 AS cor0
----
3752
3755

onlyif mysql # use DIV operator for integer division
query I rowsort label-8927
SELECT - col1 + col0 DIV + col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8927
SELECT - col1 + col0 / + col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ( 57 ) FROM tab1
----
57
57
57

query I rowsort
SELECT ALL - col0 * col1 + - 89 FROM tab0 AS cor0
----
-2153
-3484
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-8930
SELECT ALL 34 DIV - col2 + cor0.col0 DIV 9 - col0 * + col0 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
-13823
-42906
-704960

skipif mysql # not compatible
query I rowsort label-8930
SELECT ALL 34 / - col2 + cor0.col0 / 9 - col0 * + col0 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
-13823
-42906
-704960

query I rowsort
SELECT - 48 AS col2 FROM tab0
----
-48
-48
-48

onlyif mysql # use DIV operator for integer division
query I rowsort label-8932
SELECT 66 + 97 * tab1.col2 DIV col0 FROM tab1
----
152
1812
182

skipif mysql # not compatible
query I rowsort label-8932
SELECT 66 + 97 * tab1.col2 / col0 FROM tab1
----
152
1812
182

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8933
SELECT CAST( col1 AS SIGNED ) AS col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8933
SELECT CAST ( col1 AS INTEGER ) AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT ( - col1 ) + tab1.col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8935
SELECT - tab0.col1 + tab0.col1 DIV + col2 col1 FROM tab0
----
-84
-90
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8935
SELECT - tab0.col1 + tab0.col1 / + col2 col1 FROM tab0
----
-84
-90
0

query I rowsort
SELECT ALL + - 8 FROM tab1 AS cor0
----
-8
-8
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8937
SELECT ALL + - col2 + col1 DIV col0 col2 FROM tab0 AS cor0
----
-30
-81
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8937
SELECT ALL + - col2 + col1 / col0 col2 FROM tab0 AS cor0
----
-30
-81
1

query I rowsort
SELECT ALL - 18 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
13
41

query I rowsort
SELECT DISTINCT - 18 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-28
-31
-44

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col0 + + col2 AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT col1 + + 31 * + col1 AS col1 FROM tab2
----
1888
544
992

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to a3c09af95301183ccb084eb1936b14e3

query I rowsort
SELECT + + col0 * 26 FROM tab2 AS cor0
----
182
2028
2054

query I rowsort
SELECT + 33 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT + col2 * 57 FROM tab0 AS cor0
----
1881
4674
57

query I rowsort
SELECT - cor0.col1 + - col2 * col0 AS col0 FROM tab0 AS cor0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 7 + + cor0.col1 col0 FROM tab1 AS cor0
----
404
409
685

query I rowsort
SELECT + + ( ( - cor0.col2 ) ) + + col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + cor0.col0 + - ( col2 ) * + ( - col0 ) FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT + 69 + col2 AS col2 FROM tab1 AS cor0
----
123
126
165

query I rowsort
SELECT DISTINCT - + ( col2 ) + + col2 + + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + - 41 - - cor0.col2 FROM tab2 cor0
----
-14
-15
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8953
SELECT - + cor0.col1 * + CAST( + col2 AS SIGNED ) * col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

skipif mysql # not compatible
query I rowsort label-8953
SELECT - + cor0.col1 * + CAST ( + col2 AS INTEGER ) * col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL + col0 + col0 * 77 * col2 FROM tab1
----
12477
280960
591440

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + cor0.col1 col1 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 23 col0 FROM tab2 AS cor0
----
23
23
23

query I rowsort
SELECT + - 38 * - col0 FROM tab2 AS cor0
----
266
2964
3002

query I rowsort
SELECT DISTINCT + + 97 + + cor0.col2 * cor0.col1 FROM tab1 AS cor0
----
1345
1501
667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 58 col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
58

query I rowsort
SELECT col0 * + ( + col0 ) + col0 AS col2 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8961
SELECT + - col0 * col1 - ( - cor0.col1 * CAST( 4 AS SIGNED ) ) FROM tab1 AS cor0
----
-600
-988
26

skipif mysql # not compatible
query I rowsort label-8961
SELECT + - col0 * col1 - ( - cor0.col1 * CAST ( 4 AS INTEGER ) ) FROM tab1 AS cor0
----
-600
-988
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8962
SELECT cor0.col2 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8962
SELECT cor0.col2 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + ( col1 ) * col1 FROM tab2 AS cor0
----
272
3422
930

onlyif mysql # use DIV operator for integer division
query I rowsort label-8964
SELECT ALL 54 DIV + tab2.col0 FROM tab2
----
0
0
7

skipif mysql # not compatible
query I rowsort label-8964
SELECT ALL 54 / + tab2.col0 FROM tab2
----
0
0
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col1 col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT + - 42 AS col2 FROM tab1 AS cor0
----
-42
-42
-42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8967
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8967
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT cor0.col0 * 89 AS col1 FROM tab1 cor0
----
267
5696
7120

query I rowsort
SELECT + - ( col2 ) * ( + col1 ) AS col0 FROM tab1 cor0
----
-1248
-1404
-570

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-8971
SELECT ALL - col2 DIV col1 AS col1 FROM tab2 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-8971
SELECT ALL - col2 / col1 AS col1 FROM tab2 cor0
----
-2
0
0

query I rowsort
SELECT - - col2 * cor0.col2 - + 61 AS col0 FROM tab1 AS cor0
----
2855
3188
9155

query I rowsort
SELECT - col1 * col2 * + col2 - col2 * col1 FROM tab1 AS cor0
----
-121056
-33060
-77220

query I rowsort
SELECT ALL - tab1.col0 * - col0 AS col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT - + col1 * - col2 * + 19 AS col2 FROM tab2 AS cor0
----
12274
15903
29146

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0, tab0 AS cor1, tab0 cor2
----
972 values hashing to 09b120a8ff13ebafea7af10c2152241b

query I rowsort
SELECT DISTINCT + - 70 * col1 * + 3 FROM tab0 cor0
----
-18060
-19110
-20370

onlyif mysql # use DIV operator for integer division
query I rowsort label-8978
SELECT DISTINCT + col1 DIV + 24 FROM tab0 cor0
----
3
4

skipif mysql # not compatible
query I rowsort label-8978
SELECT DISTINCT + col1 / + 24 FROM tab0 cor0
----
3
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-8979
SELECT cor0.col2 * ( - ( + col1 ) ) - + ( + ( col2 ) ) DIV - 5 AS col1 FROM tab1 AS cor0
----
-1229
-1394
-559

skipif mysql # not compatible
query I rowsort label-8979
SELECT cor0.col2 * ( - ( + col1 ) ) - + ( + ( col2 ) ) / - 5 AS col1 FROM tab1 AS cor0
----
-1229
-1394
-559

query I rowsort
SELECT DISTINCT - col0 * - tab1.col0 AS col1 FROM tab1
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8981
SELECT + 13 DIV col1 col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8981
SELECT + 13 / col1 col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - + cor0.col1 * col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - - col0 * + 44 FROM tab1 AS cor0
----
132
2816
3520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * col2 * + 34 + - col1 * col1 col1 FROM tab1 cor0
----
-110566
-313513
-99820

skipif mysql # not compatible
query I rowsort
SELECT - col0 * - CAST ( 97 AS REAL ) - col1 FROM tab1 AS cor0
----
265
6198
7747

query I rowsort
SELECT DISTINCT - - col1 + 98 FROM tab0 AS cor0
----
184
189
195

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 col1 FROM tab0
----
66
66
66

query I rowsort
SELECT tab2.col2 + tab2.col1 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-8989
SELECT - 23 * - col0 + - col2 DIV ( + col2 ) AS col1 FROM tab0 AS cor0
----
2046
551
804

skipif mysql # not compatible
query I rowsort label-8989
SELECT - 23 * - col0 + - col2 / ( + col2 ) AS col1 FROM tab0 AS cor0
----
2046
551
804

query I rowsort
SELECT - + col0 * + 20 + + cor0.col1 * ( + col2 + col1 ) FROM tab2 AS cor0
----
-645
1658
3455

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 0 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + 0 + ( - col0 * col0 + col1 ) FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT + tab1.col2 * col2 * col2 FROM tab1
----
157464
185193
884736

query I rowsort
SELECT ALL col1 * - 1 AS col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT - - ( + 92 ) FROM tab0 AS cor0
----
92
92
92

query I rowsort
SELECT - ( col2 ) + + col1 * col2 AS col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL tab0.col1 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL + col0 + - col2 * col2 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT + tab0.col1 * + 42 AS col2 FROM tab0
----
3612
3822
4074

query I rowsort
SELECT + 93 + - 53 FROM tab0, tab2 cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT + col2 - - col1 * col0 AS col1 FROM tab1
----
1136
132
697

query I rowsort
SELECT + ( + tab2.col0 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT + col2 * + cor0.col0 * col1 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9004
SELECT DISTINCT CAST( NULL AS SIGNED ) * 67 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9004
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 67 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - + ( - ( + col1 ) ) * + col2 + - col2 + cor0.col1 FROM tab0 AS cor0
----
193
2891
7471

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9006
SELECT + CAST( NULL AS SIGNED ) + 53 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9006
SELECT + CAST ( NULL AS INTEGER ) + 53 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col1 + + col0 + cor0.col1 * 96 FROM tab2 cor0
----
1728
3014
5801

query I rowsort
SELECT ALL - col0 * - 8 AS col2 FROM tab0 AS cor0
----
192
280
712

query I rowsort
SELECT - 8 AS col0 FROM tab2 AS cor0
----
-8
-8
-8

query I rowsort
SELECT ALL + col2 * + 22 AS col0 FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT + ( cor0.col1 ) * cor0.col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL ( - ( - col2 ) ) * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9013
SELECT + - CAST( NULL AS DECIMAL ) * + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9013
SELECT + - CAST ( NULL AS REAL ) * + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 99 * 12 AS col2 FROM tab1 AS cor0
----
1188
1188
1188

query I rowsort
SELECT ALL + 31 + - cor0.col1 * col2 AS col0 FROM tab2 AS cor0
----
-1503
-615
-806

query I rowsort
SELECT ALL - + 60 - cor0.col0 * + col2 FROM tab2 AS cor0
----
-2088
-249
-3062

query I rowsort
SELECT DISTINCT + cor0.col0 + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL - + col1 * col2 * col0 + ( + col2 ) FROM tab2 AS cor0
----
-119626
-50996
-5832

query I rowsort
SELECT + - 69 AS col0 FROM tab1 cor0
----
-69
-69
-69

query I rowsort
SELECT ALL ( cor0.col1 ) * col1 * + 5 + 97 - col2 * col2 * col0 FROM tab2 AS cor0
----
-112534
-201
-35226

query I rowsort
SELECT ALL ( + col1 ) * col0 + - col0 + + col2 AS col2 FROM tab2
----
1302
237
4550

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * + col2 col0 FROM tab0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-9023
SELECT + - ( col1 ) DIV CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9023
SELECT + - ( col1 ) / CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - - cor0.col1 * col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + 51 + + col1 * + col2 + + col1 FROM tab2 AS cor0
----
1644
714
919

query I rowsort
SELECT DISTINCT col0 * cor0.col0 + - col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT + col2 + col0 + - ( + 60 + + col0 ) * - col0 AS col2 FROM tab1 AS cor0
----
11376
246
8057

onlyif mysql # use DIV operator for integer division
query I rowsort label-9028
SELECT ALL + col2 + col1 * col1 + 89 DIV col1 FROM tab0 AS cor0
----
7430
8363
9410

skipif mysql # not compatible
query I rowsort label-9028
SELECT ALL + col2 + col1 * col1 + 89 / col1 FROM tab0 AS cor0
----
7430
8363
9410

query I rowsort
SELECT + col2 * col2 + + col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT + cor0.col0 + col1 * + cor0.col1 + col0 FROM tab0 AS cor0
----
7444
8459
9479

query I rowsort
SELECT DISTINCT - col0 * col2 * - col1 AS col1 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9032
SELECT DISTINCT col2 * + CAST( - col0 * + col2 AS SIGNED ) FROM tab1 cor0
----
-207936
-737280
-8748

skipif mysql # not compatible
query I rowsort label-9032
SELECT DISTINCT col2 * + CAST ( - col0 * + col2 AS INTEGER ) FROM tab1 cor0
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT col1 * + col1 + + col2 AS col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT + ( + 35 ) FROM tab2, tab1 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT col0 + - ( col0 ) * - col0 FROM tab0 AS cor0
----
1260
600
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col0 * + 79 col1 FROM tab2 cor0
----
-560
-6240
-6320

query I rowsort
SELECT ALL cor0.col1 * 95 AS col1 FROM tab2 AS cor0
----
1615
2945
5605

query I rowsort
SELECT ALL + col2 * 80 FROM tab1 AS cor0
----
4320
4560
7680

query I rowsort
SELECT DISTINCT - cor0.col0 + ( + 57 * - col2 ) FROM tab0 AS cor0
----
-1905
-4763
-92

query I rowsort
SELECT - - col1 * col0 + - cor0.col0 * + col0 FROM tab2 AS cor0
----
-1482
-4898
168

query I rowsort
SELECT + + col0 + ( col2 ) FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + - cor0.col2 + 69 AS col0 FROM tab1 cor0
----
-27
12
15

query I rowsort
SELECT DISTINCT - + col0 + - col2 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9044
SELECT col1 DIV - col2 + 41 FROM tab0 AS cor0
----
-56
39
40

skipif mysql # not compatible
query I rowsort label-9044
SELECT col1 / - col2 + 41 FROM tab0 AS cor0
----
-56
39
40

query I rowsort
SELECT ALL col2 * 58 * - col0 FROM tab0 AS cor0
----
-2030
-423284
-45936

query I rowsort
SELECT DISTINCT col0 * + ( col0 ) + - cor0.col1 AS col2 FROM tab0 AS cor0
----
1128
490
7830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col0 * col1 col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT + cor0.col0 * col0 + col0 + - cor0.col2 FROM tab1 cor0
----
-42
4103
6384

query I rowsort
SELECT DISTINCT 40 + col2 AS col1 FROM tab1
----
136
94
97

query I rowsort
SELECT ALL - 19 + + col1 FROM tab1
----
-6
-9
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9051
SELECT DISTINCT 20 DIV + col1 + + col2 FROM tab2
----
26
27
39

skipif mysql # not compatible
query I rowsort label-9051
SELECT DISTINCT 20 / + col1 + + col2 FROM tab2
----
26
27
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-9052
SELECT - col0 + - col2 DIV - 82 FROM tab0 AS cor0
----
-24
-35
-88

skipif mysql # not compatible
query I rowsort label-9052
SELECT - col0 + - col2 / - 82 FROM tab0 AS cor0
----
-24
-35
-88

query I rowsort
SELECT 83 FROM tab1 cor0
----
83
83
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 70 + + col0 col0 FROM tab2 AS cor0
----
148
149
77

query I rowsort
SELECT + + col1 - + col1 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9056
SELECT DISTINCT + col2 DIV + col0 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-9056
SELECT DISTINCT + col2 / + col0 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
17
34
59

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 cor0, tab2 AS cor1, tab2 cor2
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 63 + + col0 col2 FROM tab1 AS cor0
----
127
143
66

query I rowsort
SELECT DISTINCT 79 FROM tab0, tab2 cor0 CROSS JOIN tab2
----
79

query I rowsort
SELECT DISTINCT - 61 + col1 AS col1 FROM tab2
----
-2
-30
-44

query I rowsort
SELECT - tab1.col0 * col2 AS col0 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9062
SELECT DISTINCT - 92 * tab0.col2 + + col0 DIV 46 + tab0.col0 * ( col1 ) AS col1 FROM tab0
----
-972
3303
556

skipif mysql # not compatible
query I rowsort label-9062
SELECT DISTINCT - 92 * tab0.col2 + + col0 / 46 + tab0.col0 * ( col1 ) AS col1 FROM tab0
----
-972
3303
556

query I rowsort
SELECT + col2 * - tab2.col1 + + col1 * tab2.col0 FROM tab2
----
-620
3068
697

query I rowsort
SELECT col1 + - col2 + col2 * col1 FROM tab0
----
193
2891
7471

query I rowsort
SELECT ALL + ( + col2 ) + + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - 86 * col1 + + 85 * 26 * cor0.col2 FROM tab2 AS cor0
----
52386
57004
82518

onlyif mysql # use DIV operator for integer division
query I rowsort label-9067
SELECT + col1 - + col2 DIV col0 FROM tab1 AS cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-9067
SELECT + col1 - + col2 / col0 FROM tab1 AS cor0
----
10
12
8

query I rowsort
SELECT ALL col0 + col0 AS col1 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + col1 * col1 - - 44 FROM tab2 AS cor0
----
1005
333
3525

query I rowsort
SELECT - 11 + col1 * + ( - col1 ) AS col2 FROM tab0 AS cor0
----
-7407
-8292
-9420

query I rowsort
SELECT DISTINCT + col0 * - col0 + - ( cor0.col0 + + col0 ) FROM tab0 cor0
----
-1295
-624
-8099

query I rowsort
SELECT + 59 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

onlyif mysql # use DIV operator for integer division
query I rowsort label-9073
SELECT 2 DIV - col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9073
SELECT 2 / - col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( 56 + + col1 ) FROM tab1
----
66
69
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9075
SELECT ALL - col2 + - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9075
SELECT ALL - col2 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * - 62 - col0 AS col1 FROM tab1 AS cor0
----
-1615
-684
-886

query I rowsort
SELECT col0 * ( col2 + col0 ) * 73 FROM tab1
----
1027840
12483
565312

query I rowsort
SELECT ALL 18 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 903ac227935c1532300db45a8537c595

query I rowsort
SELECT col2 * - ( - 32 ) FROM tab0
----
1056
2624
32

query I rowsort
SELECT ALL 54 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT ( - 73 * col1 ) AS col1 FROM tab0
----
-6278
-6643
-7081

onlyif mysql # use DIV operator for integer division
query I rowsort label-9082
SELECT DISTINCT col2 + 7 DIV - cor0.col0 + - col0 AS col0 FROM tab1 AS cor0
----
-7
16
49

skipif mysql # not compatible
query I rowsort label-9082
SELECT DISTINCT col2 + 7 / - cor0.col0 + - col0 AS col0 FROM tab1 AS cor0
----
-7
16
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-9083
SELECT DISTINCT + 76 DIV col0 FROM tab1 cor0
----
0
1
25

skipif mysql # not compatible
query I rowsort label-9083
SELECT DISTINCT + 76 / col0 FROM tab1 cor0
----
0
1
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 2 * col0 col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT - 52 + + 92 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 09624b9180d40f03a4dda4b4c17356c0

query I rowsort
SELECT - + 32 + + col0 * col0 FROM tab2 AS cor0
----
17
6052
6209

query I rowsort
SELECT ALL 85 * col1 FROM tab2
----
1445
2635
5015

query I rowsort
SELECT col2 * - col0 + col1 AS col0 FROM tab0 cor0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - ( col2 ) col0 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT - - 71 AS col0 FROM tab0 cor0
----
71
71
71

query I rowsort
SELECT 38 AS col1 FROM tab1
----
38
38
38

query I rowsort
SELECT ALL - col0 * + col0 + ( + ( col0 ) ) FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + 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-9094
SELECT DISTINCT ( + col1 ) * - CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9094
SELECT DISTINCT ( + col1 ) * - CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - 67 * col1 AS col1 FROM tab2 AS cor0
----
-1139
-2077
-3953

query I rowsort
SELECT ALL + col1 * 15 + 3 + + col0 FROM tab1
----
217
278
396

query I rowsort
SELECT ALL + tab2.col0 * tab2.col1 - col0 AS col1 FROM tab2
----
1264
210
4524

query I rowsort
SELECT + col0 + col0 * - col0 + + col0 FROM tab2 AS cor0
----
-35
-5928
-6083

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col2 FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9100
SELECT + + col2 + 46 DIV + col2 + - col2 FROM tab0 AS cor0
----
0
1
46

skipif mysql # not compatible
query I rowsort label-9100
SELECT + + col2 + 46 / + col2 + - col2 FROM tab0 AS cor0
----
0
1
46

query I rowsort
SELECT col2 * col1 - col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT + cor0.col2 * + 71 FROM tab2 AS cor0
----
1846
1917
2698

query I rowsort
SELECT + 7 * col1 + - cor0.col1 + - ( - col1 ) FROM tab1 AS cor0
----
182
70
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 + + col2 col1 FROM tab2 cor0
----
114
78
81

query I rowsort
SELECT ALL + - 97 AS col0 FROM tab1 AS cor0
----
-97
-97
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9106
SELECT DISTINCT 74 + ( col2 ) DIV cor0.col1 AS col1 FROM tab0 cor0
----
74

skipif mysql # not compatible
query I rowsort label-9106
SELECT DISTINCT 74 + ( col2 ) / cor0.col1 AS col1 FROM tab0 cor0
----
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9107
SELECT ALL CAST( - col0 AS SIGNED ) FROM tab0 cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-9107
SELECT ALL CAST ( - col0 AS INTEGER ) FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT ALL ( col2 ) + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL - - 66 AS col0 FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT + 99 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT ALL col0 + - 87 - col0 FROM tab1 AS cor0
----
-87
-87
-87

query I rowsort
SELECT + col1 * + 37 * col1 FROM tab2
----
10693
128797
35557

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9113
SELECT DISTINCT + CAST( NULL AS SIGNED ) col0 FROM tab2, tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9113
SELECT DISTINCT + CAST ( NULL AS INTEGER ) col0 FROM tab2, tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * ( - 39 * tab0.col1 ) col1 FROM tab0
----
-110682
-291018
-3783

query I rowsort
SELECT DISTINCT col0 * col1 * + col2 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT col2 AS col1 FROM tab0 AS cor0 WHERE + col0 IN ( - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9117
SELECT ALL tab1.col0 * col0 DIV + col1 + col0 FROM tab1
----
3
473
572

skipif mysql # not compatible
query I rowsort label-9117
SELECT ALL tab1.col0 * col0 / + col1 + col0 FROM tab1
----
3
473
572

onlyif mysql # use DIV operator for integer division
query I rowsort label-9118
SELECT col1 + + tab1.col2 DIV col2 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-9118
SELECT col1 + + tab1.col2 / col2 FROM tab1
----
11
14
27

query I rowsort
SELECT DISTINCT col2 + col2 * - tab2.col1 * + col1 FROM tab2
----
-10944
-25920
-90480

onlyif mysql # use DIV operator for integer division
query I rowsort label-9120
SELECT - col0 * col0 DIV - col1 FROM tab0 cor0
----
12
6
87

skipif mysql # not compatible
query I rowsort label-9120
SELECT - col0 * col0 / - col1 FROM tab0 cor0
----
12
6
87

query I rowsort
SELECT col1 * col1 + + col2 AS col2 FROM tab1
----
157
265
730

query I rowsort
SELECT DISTINCT + tab2.col2 + col2 * - col1 AS col1 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT + tab2.col2 AS col0 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col1 col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT tab2.col2 + + col2 * - col2 FROM tab2
----
-1406
-650
-702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col1 * col1 + + col1 * - col1 + col1 col0 FROM tab2
----
17
31
59

query I rowsort
SELECT col0 + col0 - col1 AS col1 FROM tab0
----
-27
-38
87

query I rowsort
SELECT col1 * + col2 + col2 - + tab0.col1 AS col0 FROM tab0
----
1
2785
7453

query I rowsort
SELECT DISTINCT + col1 * + col2 + + tab2.col0 * + col2 FROM tab2
----
1026
3562
3648

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT col0 NOT IN ( col2 )
----

query I rowsort
SELECT ALL col0 * + col2 + + col2 * col0 + col1 * col1 FROM tab1 cor0
----
1000
15529
7396

query I rowsort
SELECT ALL - col0 - col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT ALL col1 - - tab0.col2 * col2 AS col2 FROM tab0
----
1175
6815
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 - col1 col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - col1 - - col2 * + col2 AS col2 FROM tab1 AS cor0
----
2890
3239
9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * + cor0.col0 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - - col0 - cor0.col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT col0 + col1 * cor0.col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT tab0.col2 * - tab0.col1 + - col1 + col0 FROM tab0
----
-159
-2900
-7464

onlyif mysql # use DIV operator for integer division
query I rowsort label-9140
SELECT ALL - col1 DIV - tab1.col0 + - col1 * - col1 col1 FROM tab1
----
100
169
684

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9140
SELECT ALL - col1 / - tab1.col0 + - col1 * - col1 col1 FROM tab1
----
100
169
684

onlyif mysql # use DIV operator for integer division
query I rowsort label-9141
SELECT + col2 + col1 DIV col2 + col1 col2 FROM tab0
----
121
174
195

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9141
SELECT + col2 + col1 / col2 + col1 col2 FROM tab0
----
121
174
195

onlyif mysql # use DIV operator for integer division
query I rowsort label-9142
SELECT ALL col1 * - col0 DIV - col0 + col1 AS col0 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-9142
SELECT ALL col1 * - col0 / - col0 + col1 AS col0 FROM tab1
----
20
26
52

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT IN ( col1 / + col0 )
----

query I rowsort
SELECT DISTINCT + col2 + cor0.col1 * - col2 + col0 FROM tab1 AS cor0
----
-1072
-1347
-449

query I rowsort
SELECT ALL - col1 * + cor0.col2 + - col1 AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL - - col0 - + col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-9147
SELECT ALL + col0 DIV col1 + + col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-9147
SELECT ALL + col0 / col1 + + col2 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL + cor0.col1 + + cor0.col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT DISTINCT col1 * - cor0.col0 - col1 FROM tab1 AS cor0
----
-104
-1053
-650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * - col1 * - col0 + col2 * col2 col2 FROM tab0 AS cor0
----
178593
329316
743733

onlyif mysql # use DIV operator for integer division
query I rowsort label-9151
SELECT col1 DIV col0 + + cor0.col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-9151
SELECT col1 / col0 + + cor0.col0 FROM tab0 AS cor0
----
27
37
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9152
SELECT DISTINCT + col1 DIV + col0 + + col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-9152
SELECT DISTINCT + col1 / + col0 + + col0 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT + + col0 * + col0 + + col0 * col2 AS col0 FROM tab1 AS cor0
----
14080
171
7744

onlyif mysql # use DIV operator for integer division
query I rowsort label-9154
SELECT ALL + cor0.col1 + col2 DIV col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9154
SELECT ALL + cor0.col1 + col2 / col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9155
SELECT ALL CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9155
SELECT ALL CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 41 * - col2 * + col1 + col2 FROM tab2
----
-26448
-34290
-62868

onlyif mysql # use DIV operator for integer division
query I rowsort label-9157
SELECT + tab0.col2 DIV + col0 AS col1 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9157
SELECT + tab0.col2 / + col0 AS col1 FROM tab0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9158
SELECT - col1 * col1 + CAST( 15 AS SIGNED ) * - col2 AS col1 FROM tab2
----
-1366
-3871
-859

skipif mysql # not compatible
query I rowsort label-9158
SELECT - col1 * col1 + CAST ( 15 AS INTEGER ) * - col2 AS col1 FROM tab2
----
-1366
-3871
-859

query I rowsort
SELECT - col1 + + col2 * + col0 AS col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - 59 * - col1 FROM tab0 AS cor0
----
5074
5369
5723

query I rowsort
SELECT ALL - col0 * + col0 FROM tab1 cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9162
SELECT + 84 DIV + col0 FROM tab1
----
1
1
28

skipif mysql # not compatible
query I rowsort label-9162
SELECT + 84 / + col0 FROM tab1
----
1
1
28

query I rowsort
SELECT DISTINCT - 39 + col2 * - 38 FROM tab0 AS cor0
----
-1293
-3155
-77

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2, tab1 cor2
----
3645 values hashing to 91c4f11552b395e0eb390f09eebaec3d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 * cor0.col1 * col0 + col2 * + cor0.col0 col1 FROM tab0 AS cor0
----
-118790
-48744
-713513

query I rowsort
SELECT + col2 * col2 + cor0.col2 FROM tab0 AS cor0
----
1122
2
6806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col1 + + col0 col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT + + col0 + + col0 + - cor0.col0 * - col0 AS col0 FROM tab2 AS cor0
----
6240
63
6399

query I rowsort
SELECT - - col2 * - ( + 21 ) + col1 AS col2 FROM tab1 AS cor0
----
-1108
-1187
-2003

onlyif mysql # use DIV operator for integer division
query I rowsort label-9170
SELECT DISTINCT - cor0.col0 DIV - ( 75 ) - col0 FROM tab0 AS cor0
----
-24
-35
-88

skipif mysql # not compatible
query I rowsort label-9170
SELECT DISTINCT - cor0.col0 / - ( 75 ) - col0 FROM tab0 AS cor0
----
-24
-35
-88

query I rowsort
SELECT DISTINCT - - col1 - - col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL - - cor0.col0 * - 18 AS col0 FROM tab1 AS cor0
----
-1152
-1440
-54

query I rowsort
SELECT ALL + col1 * ( + col0 * col1 ) FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9174
SELECT col1 + - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9174
SELECT col1 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 57 + col1 AS col0 FROM tab1
----
67
70
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9176
SELECT col0 + col2 + - CAST( 71 AS SIGNED ) * - col0 AS col0 FROM tab2
----
531
5642
5726

skipif mysql # not compatible
query I rowsort label-9176
SELECT col0 + col2 + - CAST ( 71 AS INTEGER ) * - col0 AS col0 FROM tab2
----
531
5642
5726

onlyif mysql # use DIV operator for integer division
query I rowsort label-9177
SELECT col2 DIV - col0 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-9177
SELECT col2 / - col0 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT - col2 * 29 + col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1000
-2445
-5356

query I rowsort
SELECT DISTINCT col0 * col1 + - col0 FROM tab0
----
2040
3360
8010

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT - col1 * col1 / col2 IN ( col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT ALL tab2.col1 + - col1 * col2 AS col1 FROM tab2
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 col0 FROM tab2
----
-1534
-646
-837

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( col1 ) NOT IN ( - col1 - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 col0 FROM tab1 WHERE ( - col2 * - col2 ) NOT BETWEEN col2 AND ( - col2 * + col2 )
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9185
SELECT - col1 * col2 DIV - ( - col0 ) - col2 * + ( + col2 * + col0 ) FROM tab1 AS cor0
----
-207944
-737295
-9216

skipif mysql # not compatible
query I rowsort label-9185
SELECT - col1 * col2 / - ( - col0 ) - col2 * + ( + col2 * + col0 ) FROM tab1 AS cor0
----
-207944
-737295
-9216

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) NOT IN ( col2 - tab1.col0 / col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9187
SELECT ALL - tab2.col1 DIV - col1 AS col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9187
SELECT ALL - tab2.col1 / - col1 AS col1 FROM tab2
----
1
1
1

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 - 0 + cor0.col2 AS col1 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9190
SELECT ALL - col1 DIV col0 AS col0 FROM tab1
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-9190
SELECT ALL - col1 / col0 AS col0 FROM tab1
----
-8
0
0

query I rowsort
SELECT + col0 AS col1 FROM tab0 WHERE NOT ( NULL ) = NULL
----

query I rowsort
SELECT ALL tab1.col1 * col0 * - col2 AS col2 FROM tab1 WHERE ( NULL ) NOT IN ( - col0 )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9193
SELECT - cor0.col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9193
SELECT - cor0.col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col1 * + 86 + col0 * cor0.col1 FROM tab1 AS cor0
----
1500
2158
2314

onlyif mysql # use DIV operator for integer division
query I rowsort label-9195
SELECT + col0 * col2 DIV + 24 AS col1 FROM tab1 cor0
----
152
320
6

skipif mysql # not compatible
query I rowsort label-9195
SELECT + col0 * col2 / + 24 AS col1 FROM tab1 cor0
----
152
320
6

query I rowsort
SELECT + col2 * - 9 AS col2 FROM tab2 AS cor0
----
-234
-243
-342

query I rowsort
SELECT 25 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 cor0, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT 44 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT + + 9 + + cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 62eabbed21c8d12c3a0b7b427fb027f8

query I rowsort
SELECT - col2 + col1 * ( + col1 * cor0.col2 + ( 84 ) ) FROM tab1 AS cor0
----
17220
38634
6483

query I rowsort
SELECT + cor0.col2 + + col0 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - ( + col2 ) * + col1 + ( + col2 * + col2 ) FROM tab0
----
-1749
-738
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9204
SELECT DISTINCT + col0 DIV + col0 + col2 AS col1 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-9204
SELECT DISTINCT + col0 / + col0 + col2 AS col1 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT + + ( col0 ) + ( - col0 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 65 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 1654646feeae82f39d2f564fe4ea26c2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9207
SELECT DISTINCT + col1 - + CAST( - ( + col0 ) + + CAST( + col1 AS SIGNED ) AS SIGNED ) * col0 AS col2 FROM tab1 AS cor0
----
-43
3466
5373

skipif mysql # not compatible
query I rowsort label-9207
SELECT DISTINCT + col1 - + CAST ( - ( + col0 ) + + CAST ( + col1 AS INTEGER ) AS INTEGER ) * col0 AS col2 FROM tab1 AS cor0
----
-43
3466
5373

query I rowsort
SELECT + col1 + + col0 * - col2 * - col2 FROM tab0 AS cor0
----
132
26222
598527

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col2 - + 83 col1 FROM tab0 AS cor0
----
-1172
-6807
-84

query I rowsort
SELECT DISTINCT - col2 - - tab1.col1 * ( tab1.col2 ) * - tab1.col1 FROM tab1
----
-16320
-36558
-5757

query I rowsort
SELECT + + 87 * 29 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 3d90473a6786304f77f6fb1bb12f68f4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 27 col0 FROM tab1
----
27
27
27

query I rowsort
SELECT DISTINCT + col1 + - ( col2 * + col1 ) FROM tab2
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-9214
SELECT - col1 DIV col0 + col2 FROM tab0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-9214
SELECT - col1 / col0 + col2 FROM tab0
----
-1
30
81

query I rowsort
SELECT ALL ( cor0.col2 ) AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 46 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT col1 * 43 FROM tab1
----
1118
430
559

query I rowsort
SELECT ALL + col1 + + ( 57 ) FROM tab2 AS cor0
----
116
74
88

query I rowsort
SELECT - + col1 * + col2 + col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT 22 * + 8 FROM tab0
----
176
176
176

query I rowsort
SELECT DISTINCT col2 * - ( - col2 ) FROM tab2
----
1444
676
729

query I rowsort
SELECT DISTINCT 36 AS col0 FROM tab1
----
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 47 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT col0 * + col2 - - col1 FROM tab2
----
2087
220
3019

query I rowsort
SELECT col0 * col1 * col1 - 29 AS col2 FROM tab0
----
177475
329286
736980

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab1 cor1, tab0, tab0 AS cor2
----
3645 values hashing to 78077727601c056ad0d4f4c11c8daffb

query I rowsort
SELECT 56 + col1 FROM tab2 AS cor0
----
115
73
87

query I rowsort
SELECT + + ( + col0 ) * + col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + - col1 * col2 - col1 AS col0 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9230
SELECT DISTINCT ( - col1 ) + ( tab1.col0 + col2 ) * + CAST( NULL AS DECIMAL ) * + col1 AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-9230
SELECT DISTINCT ( - col1 ) + ( tab1.col0 + col2 ) * + CAST ( NULL AS REAL ) * + col1 AS col1 FROM tab1
----
NULL

query I rowsort
SELECT + col0 * - col2 + 91 FROM tab2 AS cor0
----
-1937
-2911
-98

query I rowsort
SELECT ALL - col2 - col0 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - 54 * + col1 * - 2 + col2 * col0 AS col0 FROM tab2 AS cor0
----
3537
4838
8400

query I rowsort
SELECT ALL - col1 - col0 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT + ( + 23 ) * - col0 AS col0 FROM tab0
----
-2047
-552
-805

query I rowsort
SELECT - 49 + + col0 FROM tab2 AS cor0
----
-42
29
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-9237
SELECT ALL - + 47 DIV + col1 AS col1 FROM tab2 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-9237
SELECT ALL - + 47 / + col1 AS col1 FROM tab2 cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT - 68 + col0 * + col2 AS col0 FROM tab0 AS cor0
----
-33
7230
724

query I rowsort
SELECT - + 18 * col1 AS col2 FROM tab2 AS cor0
----
-1062
-306
-558

query I rowsort
SELECT ALL - col0 * - 66 + col0 AS col0 FROM tab0 AS cor0
----
1608
2345
5963

query I rowsort
SELECT DISTINCT + col2 + col2 * col1 + - col0 * 28 FROM tab1 cor0
----
-1165
-896
1374

query I rowsort
SELECT ( col1 ) + + col0 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9243
SELECT DISTINCT - ( 52 ) DIV - cor0.col1 + + 70 + 0 FROM tab0 AS cor0
----
70

skipif mysql # not compatible
query I rowsort label-9243
SELECT DISTINCT - ( 52 ) / - cor0.col1 + + 70 + 0 FROM tab0 AS cor0
----
70

query I rowsort
SELECT DISTINCT - 38 * col0 AS col0 FROM tab2 AS cor0
----
-266
-2964
-3002

query I rowsort
SELECT ALL ( col2 ) * + col2 + - col1 * - 64 + cor0.col1 AS col1 FROM tab1 AS cor0
----
10061
3899
4606

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 5 col0 FROM tab0 cor0
----
5
5
5

query I rowsort
SELECT DISTINCT 69 FROM tab0, tab1 cor0, tab0 AS cor1, tab2 AS cor2
----
69

query I rowsort
SELECT + - col0 + col0 + col0 * col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + 13 * col0 AS col1 FROM tab1 cor0
----
1040
39
832

query I rowsort
SELECT DISTINCT + - 70 FROM tab1 AS cor0
----
-70

query I rowsort
SELECT + + cor0.col1 * - col2 + + col0 - + col1 FROM tab1 AS cor0
----
-1181
-1427
-516

query I rowsort
SELECT tab1.col2 + - ( col1 ) * - col1 + + ( - col0 * - col0 ) FROM tab1
----
4253
6665
739

query I rowsort
SELECT ALL + ( 63 ) AS col1 FROM tab2, tab2 AS cor0, tab0 cor1, tab1 cor2
----
81 values hashing to 29cdb8d01f1c3eb072511674b1c6d5fd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9254
SELECT - CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9254
SELECT - CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9255
SELECT ALL col0 * + col2 * + col1 + CAST( 56 AS SIGNED ) FROM tab2
----
119708
51090
5915

skipif mysql # not compatible
query I rowsort label-9255
SELECT ALL col0 * + col2 * + col1 + CAST ( 56 AS INTEGER ) FROM tab2
----
119708
51090
5915

query I rowsort
SELECT 92 * - col0 AS col1 FROM tab1
----
-276
-5888
-7360

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) + 87 FROM tab1 AS cor0
----
61
74
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-9258
SELECT - 18 DIV col1 AS col1 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-9258
SELECT - 18 / col1 AS col1 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL - 54 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-378
-4212
-4266

query I rowsort
SELECT ALL + cor0.col2 * cor0.col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT col2 * + 9 FROM tab0
----
297
738
9

query I rowsort
SELECT DISTINCT - col0 * - col1 + - col0 + - col0 FROM tab1
----
512
72
880

onlyif mysql # use DIV operator for integer division
query I rowsort label-9263
SELECT col2 + col0 DIV + tab2.col0 col2 FROM tab2
----
27
28
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9263
SELECT col2 + col0 / + tab2.col0 col2 FROM tab2
----
27
28
39

query I rowsort
SELECT DISTINCT tab0.col1 + - tab0.col0 AS col2 FROM tab0
----
2
62

query I rowsort
SELECT ALL + col1 + - col0 * col2 AS col1 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - 20 FROM tab0, tab1 AS cor0
----
-20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 * + col0 - + col1 col2 FROM tab1 AS cor0
----
13507
2002
6390

query I rowsort
SELECT DISTINCT + col2 - 3 FROM tab0 AS cor0
----
-2
30
79

query I rowsort
SELECT - + cor0.col2 * col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL col0 + + ( ( col1 ) ) * col1 AS col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT - - cor0.col0 * col1 + col0 * - cor0.col2 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT - + col0 * 58 AS col1 FROM tab0 AS cor0
----
-1392
-2030
-5162

onlyif mysql # use DIV operator for integer division
query I rowsort label-9273
SELECT ALL col1 * - 35 + col0 + - cor0.col1 DIV ( cor0.col0 ) FROM tab1 AS cor0
----
-286
-375
-915

skipif mysql # not compatible
query I rowsort label-9273
SELECT ALL col1 * - 35 + col0 + - cor0.col1 / ( cor0.col0 ) FROM tab1 AS cor0
----
-286
-375
-915

query I rowsort
SELECT ALL + 99 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

onlyif mysql # use DIV operator for integer division
query I rowsort label-9275
SELECT col0 + + col1 DIV tab1.col0 FROM tab1
----
11
64
80

skipif mysql # not compatible
query I rowsort label-9275
SELECT col0 + + col1 / tab1.col0 FROM tab1
----
11
64
80

query I rowsort
SELECT DISTINCT - col0 + + col1 * col2 AS col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9277
SELECT DISTINCT + col1 + - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9277
SELECT DISTINCT + col1 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col1 - - 26 FROM tab0 AS cor0
----
112
117
123

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9279
SELECT ALL - col1 * - CAST( col2 AS SIGNED ) + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

skipif mysql # not compatible
query I rowsort label-9279
SELECT ALL - col1 * - CAST ( col2 AS INTEGER ) + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL + 37 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT DISTINCT col0 * col1 + col2 AS col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT col1 - - col0 * col2 AS col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + col1 * ( + cor0.col0 + col2 ) FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT + ( - cor0.col0 ) - col0 FROM tab0 AS cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 93 + cor0.col0 col2 FROM tab1 AS cor0
----
5025
5365
9008

query I rowsort
SELECT DISTINCT + 24 FROM tab2, tab1 cor0, tab0 AS cor1
----
24

query I rowsort
SELECT 13 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT ( + tab1.col0 ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9289
SELECT - CAST( NULL AS SIGNED ) * 14 - - col2 / + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9289
SELECT - CAST ( NULL AS INTEGER ) * 14 - - col2 / + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9290
SELECT - col1 + 83 DIV - col2 FROM tab1 AS cor0
----
-11
-13
-27

skipif mysql # not compatible
query I rowsort label-9290
SELECT - col1 + 83 / - col2 FROM tab1 AS cor0
----
-11
-13
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 84 * 65 + col1 col2 FROM tab0 AS cor0
----
5546
5551
5557

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0, tab2, tab1 cor1
----
972 values hashing to 4634d10e8b6b37510bb99745aade36ab

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 + cor0.col1 col2 FROM tab2 AS cor0
----
112
126
154

query I rowsort
SELECT - col0 * col1 - + col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-9295
SELECT + + col2 DIV col0 + + col1 * + 68 col1 FROM tab1 AS cor0
----
1786
680
885

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9295
SELECT + + col2 / col0 + + col1 * + 68 col1 FROM tab1 AS cor0
----
1786
680
885

query I rowsort
SELECT + cor0.col0 * col0 - col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT ALL - col0 * - col2 + col1 * 82 + col1 FROM tab2 AS cor0
----
2762
4413
6925

query I rowsort
SELECT + - ( cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 32 * + col2 + col0 col1 FROM tab1 AS cor0
----
-1725
-1760
-2992

query I rowsort
SELECT ALL - + col2 + cor0.col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + + 29 + - 47 FROM tab1 AS cor0
----
-18

query I rowsort
SELECT + - col0 * + col0 - cor0.col1 FROM tab0 cor0
----
-1322
-662
-8012

query I rowsort
SELECT cor0.col2 * col1 * ( col2 * - col1 ) AS col1 FROM tab1 AS cor0
----
-1557504
-1971216
-324900

query I rowsort
SELECT ALL 12 * col2 AS col0 FROM tab0 AS cor0
----
12
396
984

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9305
SELECT ALL cor0.col2 + + col2 * + CAST( NULL AS SIGNED ) / col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9305
SELECT ALL cor0.col2 + + col2 * + CAST ( NULL AS INTEGER ) / col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 23 FROM tab2 cor0
----
23

query I rowsort
SELECT + + 85 * col0 AS col2 FROM tab1 cor0
----
255
5440
6800

query I rowsort
SELECT DISTINCT - col1 + + col1 * - 27 FROM tab1 AS cor0
----
-280
-364
-728

onlyif mysql # use DIV operator for integer division
query I rowsort label-9309
SELECT DISTINCT + 37 DIV + col2 FROM tab0 AS cor0
----
0
1
37

skipif mysql # not compatible
query I rowsort label-9309
SELECT DISTINCT + 37 / + col2 FROM tab0 AS cor0
----
0
1
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9310
SELECT DISTINCT cor0.col0 * + CAST( - ( + col1 ) AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-9310
SELECT DISTINCT cor0.col0 * + CAST ( - ( + col1 ) AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL col2 * - ( 69 ) AS col1 FROM tab2 AS cor0
----
-1794
-1863
-2622

query I rowsort
SELECT ALL + col0 * ( col0 ) AS col2 FROM tab0
----
1225
576
7921

query I rowsort
SELECT 12 * + ( - col0 ) AS col2 FROM tab1
----
-36
-768
-960

query I rowsort
SELECT cor0.col2 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL col2 + col2 + - 12 * cor0.col2 * col0 AS col1 FROM tab2 AS cor0
----
-2214
-24284
-35948

query I rowsort
SELECT - ( + 30 ) * col0 AS col1 FROM tab1
----
-1920
-2400
-90

query I rowsort
SELECT ALL ( 53 ) AS col2 FROM tab0
----
53
53
53

query I rowsort
SELECT tab2.col2 * 75 * tab2.col1 FROM tab2
----
115050
48450
62775

query I rowsort
SELECT ALL col2 + 94 FROM tab0
----
127
176
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-9320
SELECT ALL + ( col0 ) DIV col2 + - 22 DIV + col0 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-9320
SELECT ALL + ( col0 ) / col2 + - 22 / + col0 FROM tab0
----
0
1
35

query I rowsort
SELECT ALL + 26 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query I rowsort
SELECT ALL 93 * + cor0.col1 + - 89 AS col0 FROM tab2 AS cor0
----
1492
2794
5398

query I rowsort
SELECT ALL col1 * - col1 + + 34 AS col0 FROM tab1 AS cor0
----
-135
-642
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-9324
SELECT ALL + col2 DIV - cor0.col2 + - 73 FROM tab0 cor0
----
-74
-74
-74

skipif mysql # not compatible
query I rowsort label-9324
SELECT ALL + col2 / - cor0.col2 + - 73 FROM tab0 cor0
----
-74
-74
-74

query I rowsort
SELECT DISTINCT + 76 AS col1 FROM tab1 AS cor0
----
76

query I rowsort
SELECT 58 + col1 FROM tab0 cor0
----
144
149
155

query I rowsort
SELECT + col1 + col2 * + 91 AS col0 FROM tab1 AS cor0
----
4940
5197
8749

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
54
57
96

query I rowsort
SELECT - + col0 * cor0.col2 + + col1 AS col2 FROM tab2 cor0
----
-158
-1969
-2985

query I rowsort
SELECT + 12 - col0 AS col0 FROM tab0 AS cor0
----
-12
-23
-77

query I rowsort
SELECT ( + col1 ) * - col0 + col1 * col1 FROM tab1 cor0
----
-540
-871
598

query I rowsort
SELECT DISTINCT - 6 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
-6

query I rowsort
SELECT + col0 * - col0 + - col1 AS col0 FROM tab1 cor0
----
-35
-4106
-6413

query I rowsort
SELECT + + 22 * + col1 FROM tab1 AS cor0
----
220
286
572

onlyif mysql # use DIV operator for integer division
query I rowsort label-9335
SELECT + col0 DIV 54 - - col0 DIV 94 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9335
SELECT + col0 / 54 - - col0 / 94 FROM tab1 AS cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 10 col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT - col2 - col2 AS col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT cor0.col2 * - col1 - + col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ( 17 ) + + col0 * + ( - col0 ) + col0 FROM tab0 AS cor0
----
-1173
-535
-7815

query I rowsort
SELECT ALL - 40 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
46
51
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9341
SELECT - + CAST( NULL AS SIGNED ) * col2 + col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9341
SELECT - + CAST ( NULL AS INTEGER ) * col2 + col2 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9342
SELECT - + CAST( NULL AS DECIMAL ) * + col0 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9342
SELECT - + CAST ( NULL AS REAL ) * + col0 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 72 * 79 + col2 + + 88 AS col1 FROM tab0 AS cor0
----
5777
5809
5858

query I rowsort
SELECT DISTINCT + - 1 FROM tab0 cor0
----
-1

query I rowsort
SELECT - - 9 FROM tab1 AS cor0
----
9
9
9

query I rowsort
SELECT ALL + 13 FROM tab0 AS cor0
----
13
13
13

query I rowsort
SELECT DISTINCT - ( - cor0.col2 ) + + col2 * - 55 AS col1 FROM tab1 cor0
----
-2916
-3078
-5184

query I rowsort
SELECT - 35 - cor0.col0 FROM tab2 cor0
----
-113
-114
-42

query I rowsort
SELECT DISTINCT + cor0.col2 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL ( cor0.col1 ) * - col1 + - col0 AS col2 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT - - col0 + 19 AS col1 FROM tab2 AS cor0
----
26
97
98

query I rowsort
SELECT ALL 31 * col1 AS col1 FROM tab1 cor0
----
310
403
806

query I rowsort
SELECT - 6 - - col1 * col1 FROM tab2 AS cor0
----
283
3475
955

query I rowsort
SELECT DISTINCT - 28 AS col0 FROM tab0 cor0
----
-28

query I rowsort
SELECT DISTINCT ( col1 ) + + 8 AS col0 FROM tab0 AS cor0
----
105
94
99

query I rowsort
SELECT ( 23 + - tab1.col0 ) AS col0 FROM tab1
----
-41
-57
20

query I rowsort
SELECT tab0.col2 * + col2 + col0 FROM tab0
----
1113
36
6813

query I rowsort
SELECT + cor0.col0 FROM tab2, tab1 cor0 CROSS JOIN tab0, tab2 AS cor1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) * + col2 + + col0 col2 FROM tab1
----
165
3712
7760

query I rowsort
SELECT col2 - col1 * col0 AS col0 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT ALL - 92 FROM tab1, tab2 AS cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT DISTINCT col2 * + tab1.col2 - col0 AS col0 FROM tab1
----
2913
3185
9136

query I rowsort
SELECT - 83 AS col2 FROM tab2, tab2 cor0, tab0 cor1
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

onlyif mysql # use DIV operator for integer division
query I rowsort label-9364
SELECT DISTINCT - - col1 * ( col1 ) * col0 + 95 DIV cor0.col0 col2 FROM tab2 AS cor0
----
22832
271519
6740

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9364
SELECT DISTINCT - - col1 * ( col1 ) * col0 + 95 / cor0.col0 col2 FROM tab2 AS cor0
----
22832
271519
6740

onlyif mysql # use DIV operator for integer division
query I rowsort label-9365
SELECT DISTINCT tab2.col2 * col0 DIV 13 col1 FROM tab2
----
14
156
230

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9365
SELECT DISTINCT tab2.col2 * col0 / 13 col1 FROM tab2
----
14
156
230

query I rowsort
SELECT + ( + col1 * + col2 ) AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT - tab2.col0 - col0 AS col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT - col1 * col0 - - tab2.col0 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT col2 + - col2 * 43 AS col2 FROM tab0
----
-1386
-3444
-42

query I rowsort
SELECT ( tab1.col1 ) + col1 FROM tab1
----
20
26
52

query I rowsort
SELECT + 36 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT ALL col1 * + col1 + 82 FROM tab0 cor0
----
7478
8363
9491

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 17 * col0 + - col0 + + col0 col1 FROM tab2 AS cor0
----
119
1326
1343

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + cor0.col0 - + col0 col0 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9375
SELECT DISTINCT - ( col1 ) * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9375
SELECT DISTINCT - ( col1 ) * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col1 + cor0.col1 AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL - col2 - ( cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9378
SELECT - col0 * + CAST( NULL AS SIGNED ) + 27 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9378
SELECT - col0 * + CAST ( NULL AS INTEGER ) + 27 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 + col2 * - col1 col0 FROM tab1 AS cor0
----
-1140
-2496
-2808

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col1 + cor0.col1 * - col0 col2 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT + col2 * + 3 FROM tab1
----
162
171
288

query I rowsort
SELECT DISTINCT - + col2 + 89 FROM tab1 cor0
----
-7
32
35

query I rowsort
SELECT + - col0 + ( 47 ) FROM tab1 cor0
----
-17
-33
44

query I rowsort
SELECT DISTINCT + col0 * ( 33 ) + - col0 AS col2 FROM tab2 cor0
----
224
2496
2528

query I rowsort
SELECT ALL col2 * col0 - + 16 AS col0 FROM tab2
----
173
2012
2986

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + col0 * + cor0.col1 col2 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL - ( + col1 ) * - col1 AS col2 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 78 col2 FROM tab0 AS cor0
----
-78
-78
-78

query I rowsort
SELECT DISTINCT - 4 FROM tab2, tab0 cor0
----
-4

query I rowsort
SELECT ALL col0 * - col2 * + col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT ALL ( col2 ) * + col1 AS col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT 23 * ( - col1 ) FROM tab1 AS cor0
----
-230
-299
-598

query I rowsort
SELECT ALL - ( + 85 ) FROM tab2 AS cor0
----
-85
-85
-85

query I rowsort
SELECT DISTINCT col0 * + 65 AS col1 FROM tab2 AS cor0
----
455
5070
5135

query IIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0 WHERE NOT NULL >= + cor0.col2
----

query I rowsort
SELECT + ( - col0 ) * + col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + - col1 * 7 FROM tab0 AS cor0
----
-602
-637
-679

query I rowsort
SELECT ( col2 ) * - cor0.col1 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-9399
SELECT ALL tab1.col2 DIV + col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-9399
SELECT ALL tab1.col2 / + col0 FROM tab1
----
0
1
18

query I rowsort
SELECT ALL + + col1 * - col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-9401
SELECT DISTINCT - 45 DIV - col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-9401
SELECT DISTINCT - 45 / - col0 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT ALL - col1 * - col0 AS col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ( col0 ) + ( col2 ) * col0 * - col1 AS col0 FROM tab0 AS cor0
----
-3360
-664029
-68088

query I rowsort
SELECT DISTINCT - - 18 + + col2 AS col0 FROM tab2 AS cor0
----
44
45
56

query I rowsort
SELECT 34 - cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 04d2796372609ea2fbfb8d029ec877aa

query I rowsort
SELECT tab0.col2 * + col1 - col2 FROM tab0
----
2805
7380
96

query I rowsort
SELECT + 32 + - col1 FROM tab2
----
-27
1
15

query I rowsort
SELECT + col1 * 14 + - col1 AS col1 FROM tab2
----
221
403
767

query I rowsort
SELECT 95 + col2 FROM tab2 AS cor0
----
121
122
133

query I rowsort
SELECT ALL + 11 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

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 - col0 * ( + col0 * col2 ) FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT + cor0.col1 * - ( 90 ) FROM tab0 AS cor0
----
-7740
-8190
-8730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 * + 21 col0 FROM tab2 AS cor0
----
-546
-567
-798

query I rowsort
SELECT ALL 63 * + tab0.col1 FROM tab0
----
5418
5733
6111

onlyif mysql # use DIV operator for integer division
query I rowsort label-9416
SELECT - + ( - cor0.col0 ) + 96 * col2 DIV col0 FROM tab0 AS cor0
----
156
177
37

skipif mysql # not compatible
query I rowsort label-9416
SELECT - + ( - cor0.col0 ) + 96 * col2 / col0 FROM tab0 AS cor0
----
156
177
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9417
SELECT ALL col0 * col1 * - CAST( - col1 AS SIGNED ) AS col1 FROM tab2
----
22831
271518
6727

skipif mysql # not compatible
query I rowsort label-9417
SELECT ALL col0 * col1 * - CAST ( - col1 AS INTEGER ) AS col1 FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-9418
SELECT DISTINCT - tab0.col1 DIV col0 + 19 DIV tab0.col0 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-9418
SELECT DISTINCT - tab0.col1 / col0 + 19 / tab0.col0 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT col2 * col1 + col2 AS col0 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT col1 * 58 + + col0 FROM tab1
----
1511
644
834

onlyif mysql # use DIV operator for integer division
query I rowsort label-9421
SELECT col0 * - 90 + ( col1 ) DIV + 72 + + ( col1 ) * + col0 FROM tab2
----
-2418
-413
-5767

skipif mysql # not compatible
query I rowsort label-9421
SELECT col0 * - 90 + ( col1 ) / + 72 + + ( col1 ) * + col0 FROM tab2
----
-2418
-413
-5767

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
7
78
79

query I rowsort
SELECT ALL col2 + + 53 * - 23 AS col2 FROM tab1
----
-1123
-1162
-1165

query I rowsort
SELECT DISTINCT + col1 + col0 * + 69 AS col1 FROM tab2
----
514
5441
5468

query I rowsort
SELECT - + col0 + - col2 * - col1 AS col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT - + ( - col0 ) * - col2 AS col2 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9427
SELECT ALL + + CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9427
SELECT ALL + + CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + - col0 * col2 FROM tab2 cor0
----
-2054
-216
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-9429
SELECT ALL - col2 * + col2 + + col1 DIV - col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-9429
SELECT ALL - col2 * + col2 + + col1 / - col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - 78 AS col0 FROM tab1 AS cor0
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-9432
SELECT - col2 DIV + col0 FROM tab2 cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-9432
SELECT - col2 / + col0 FROM tab2 cor0
----
-3
0
0

query I rowsort
SELECT ALL - + ( 79 ) + - col0 AS col2 FROM tab2 AS cor0
----
-157
-158
-86

query I rowsort
SELECT DISTINCT + + cor0.col1 * + 91 FROM tab0 AS cor0
----
7826
8281
8827

onlyif mysql # use DIV operator for integer division
query I rowsort label-9435
SELECT DISTINCT col1 DIV - col1 AS col2 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9435
SELECT DISTINCT col1 / - col1 AS col2 FROM tab2 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9436
SELECT DISTINCT col0 * col2 DIV col0 + cor0.col2 AS col1 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-9436
SELECT DISTINCT col0 * col2 / col0 + cor0.col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL col1 - + col2 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 14 col0 FROM tab0
----
-14
-14
-14

onlyif mysql # use DIV operator for integer division
query I rowsort label-9439
SELECT 87 DIV col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9439
SELECT 87 / col2 FROM tab1
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + col1 col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT + col0 * - 47 + col1 AS col0 FROM tab1 AS cor0
----
-115
-2998
-3747

onlyif mysql # use DIV operator for integer division
query I rowsort label-9442
SELECT + col2 * col1 DIV - 89 FROM tab0
----
-1
-31
-83

skipif mysql # not compatible
query I rowsort label-9442
SELECT + col2 * col1 / - 89 FROM tab0
----
-1
-31
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9443
SELECT + col0 + col1 DIV - 54 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-9443
SELECT + col0 + col1 / - 54 AS col0 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9444
SELECT col1 DIV + col0 AS col2 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-9444
SELECT col1 / + col0 AS col2 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9446
SELECT DISTINCT - ( 31 + - col0 ) * + CAST( + col0 AS SIGNED ) col1 FROM tab1
----
-84
2112
3920

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9446
SELECT DISTINCT - ( 31 + - col0 ) * + CAST ( + col0 AS INTEGER ) col1 FROM tab1
----
-84
2112
3920

query I rowsort
SELECT - ( + 28 ) * col2 FROM tab2 cor0
----
-1064
-728
-756

query I rowsort
SELECT DISTINCT + - 56 + col0 FROM tab0 AS cor0
----
-21
-32
33

query I rowsort
SELECT DISTINCT col0 * col0 - - col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT + - 49 AS col1 FROM tab0 AS cor0
----
-49
-49
-49

query I rowsort
SELECT ALL - 43 + - col0 FROM tab1 cor0
----
-107
-123
-46

query I rowsort
SELECT - - 94 * col1 * + cor0.col0 FROM tab2 AS cor0
----
126242
20398
432588

onlyif mysql # use DIV operator for integer division
query I rowsort label-9453
SELECT ALL + 36 DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
0
1
36

skipif mysql # not compatible
query I rowsort label-9453
SELECT ALL + 36 / cor0.col2 AS col2 FROM tab0 AS cor0
----
0
1
36

query I rowsort
SELECT + 27 * - col2 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT DISTINCT cor0.col0 * - col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - col1 + col1 * - col1 AS col1 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT col0 + - col1 * + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - cor0.col0 * cor0.col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col0 + - col0 * + col0 AS col2 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT - - col2 + - col2 AS col0 FROM tab1 cor0
----
0

query I rowsort
SELECT 89 * col1 + + col1 FROM tab2 cor0
----
1530
2790
5310

onlyif mysql # use DIV operator for integer division
query I rowsort label-9462
SELECT + 31 DIV + 61 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9462
SELECT + 31 / + 61 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9463
SELECT + - CAST( 50 AS SIGNED ) FROM tab1 AS cor0
----
-50
-50
-50

skipif mysql # not compatible
query I rowsort label-9463
SELECT + - CAST ( 50 AS INTEGER ) FROM tab1 AS cor0
----
-50
-50
-50

query I rowsort
SELECT DISTINCT - cor0.col0 + 77 * cor0.col2 FROM tab2 AS cor0
----
1924
2072
2847

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9465
SELECT DISTINCT + + CAST( - col2 AS SIGNED ) FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-9465
SELECT DISTINCT + + CAST ( - col2 AS INTEGER ) FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9466
SELECT + ( - col2 ) DIV - col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9466
SELECT + ( - col2 ) / - col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT cor0.col1 * + 21 AS col1 FROM tab1 AS cor0
----
210
273
546

query I rowsort
SELECT ALL ( - col1 ) * tab1.col1 AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT DISTINCT 15 + + col0 * + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-118810
-49521
-720796

onlyif mysql # use DIV operator for integer division
query I rowsort label-9470
SELECT DISTINCT - - 59 DIV col0 FROM tab2 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-9470
SELECT DISTINCT - - 59 / col0 FROM tab2 AS cor0
----
0
8

query I rowsort
SELECT DISTINCT col2 * - col1 * col1 + + tab0.col1 + col1 AS col0 FROM tab0
----
-243896
-678860
-9215

onlyif mysql # use DIV operator for integer division
query I rowsort label-9472
SELECT col1 - col1 DIV col0 FROM tab0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-9472
SELECT col1 - col1 / col0 FROM tab0
----
83
90
95

query I rowsort
SELECT - ( + ( - tab2.col0 ) + col1 * + col0 ) FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT - 93 - 62 * col1 AS col2 FROM tab1
----
-1705
-713
-899

query I rowsort
SELECT - col1 * - col1 - col0 FROM tab2
----
210
3403
954

query I rowsort
SELECT DISTINCT + cor0.col2 + + 9 AS col2 FROM tab1 AS cor0
----
105
63
66

query I rowsort
SELECT - - 10 * 82 + col2 * 50 FROM tab2 AS cor0
----
2120
2170
2720

query I rowsort
SELECT tab2.col2 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9479
SELECT ALL col1 DIV col1 AS col0 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9479
SELECT ALL col1 / col1 AS col0 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - 81 * col1 FROM tab1 AS cor0
----
-1053
-2106
-810

query I rowsort
SELECT DISTINCT + 96 + + col0 * cor0.col0 FROM tab2 AS cor0
----
145
6180
6337

onlyif mysql # use DIV operator for integer division
query I rowsort label-9482
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-9482
SELECT ALL col0 / col0 col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT 97 * - col0 FROM tab1 AS cor0
----
-291
-6208
-7760

query I rowsort
SELECT + 5 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT DISTINCT - 0 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - ( + 66 ) FROM tab1 cor0
----
-66
-66
-66

query I rowsort
SELECT - col0 * 16 AS col2 FROM tab0 AS cor0
----
-1424
-384
-560

query I rowsort
SELECT ALL + cor0.col1 * 7 FROM tab2 AS cor0
----
119
217
413

query I rowsort
SELECT + col1 * + col0 * tab0.col2 AS col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT 90 * - col1 + col2 * col2 FROM tab0
----
-1466
-6651
-8729

query I rowsort
SELECT DISTINCT - col2 + - col1 - 53 FROM tab0 cor0
----
-151
-172
-226

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9492
SELECT - - 51 * col0 + CAST( NULL AS SIGNED ) * - 41 / col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9492
SELECT - - 51 * col0 + CAST ( NULL AS INTEGER ) * - 41 / col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 41 * col0 + col0 FROM tab1 AS cor0
----
126
2688
3360

query I rowsort
SELECT + 63 + cor0.col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 800e4fb8967171ac40b330e06d55796c

query I rowsort
SELECT - - cor0.col0 + col0 * ( + col2 * col0 ) FROM tab1 AS cor0
----
233536
489
614480

onlyif mysql # use DIV operator for integer division
query I rowsort label-9496
SELECT DISTINCT - + cor0.col0 + col0 DIV 53 FROM tab2 AS cor0
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-9496
SELECT DISTINCT - + cor0.col0 + col0 / 53 FROM tab2 AS cor0
----
-7
-77
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-9497
SELECT DISTINCT - cor0.col1 * CAST( col0 AS SIGNED ) DIV col1 col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9497
SELECT DISTINCT - cor0.col1 * CAST ( col0 AS INTEGER ) / col1 col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + col1 + 3 * 40 AS col2 FROM tab0 AS cor0
----
206
211
217

query I rowsort
SELECT ALL - cor0.col0 * 91 AS col2 FROM tab1 AS cor0
----
-273
-5824
-7280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9500
SELECT ALL + - col1 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9500
SELECT ALL + - col1 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * 25 AS col0 FROM tab1 AS cor0
----
-1350
-1425
-2400

query I rowsort
SELECT DISTINCT col2 + + col1 * - col1 AS col1 FROM tab1 AS cor0
----
-43
-622
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-9503
SELECT DISTINCT col2 DIV 52 + - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-88

skipif mysql # not compatible
query I rowsort label-9503
SELECT DISTINCT col2 / 52 + - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9504
SELECT ALL + col2 / - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9504
SELECT ALL + col2 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col0 * + ( - col0 ) - col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9506
SELECT ALL + - cor0.col2 * + CAST( + col1 AS SIGNED ) * + cor0.col1 + + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9506
SELECT ALL + - cor0.col2 * + CAST ( + col1 AS INTEGER ) * + cor0.col1 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL cor0.col2 + col1 FROM tab0 cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 - - cor0.col2 * + col2 col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL + col0 * col2 + tab1.col0 * col0 FROM tab1
----
14080
171
7744

query I rowsort
SELECT DISTINCT + col1 - + ( - col2 + + col0 ) AS col0 FROM tab2 cor0
----
-24
51
7

query I rowsort
SELECT ALL tab0.col2 AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL + col1 + 60 FROM tab1 cor0
----
70
73
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9514
SELECT ALL + col2 * CAST( col1 AS SIGNED ) + + cor0.col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

skipif mysql # not compatible
query I rowsort label-9514
SELECT ALL + col2 * CAST ( col1 AS INTEGER ) + + cor0.col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT col1 * cor0.col1 + - col0 + col1 FROM tab0 AS cor0
----
7458
8283
9471

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9516
SELECT DISTINCT col0 / + CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9516
SELECT DISTINCT col0 / + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - cor0.col0 + - 73 * - col1 FROM tab1 AS cor0
----
1895
666
869

query I rowsort
SELECT + col2 * col1 + - col2 FROM tab0 cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT col0 * + col2 + + 87 FROM tab1 AS cor0
----
249
3735
7767

query I rowsort
SELECT ALL + col1 * - 16 AS col1 FROM tab0 cor0
----
-1376
-1456
-1552

query I rowsort
SELECT DISTINCT - col0 + - col0 * + col1 * - col1 AS col2 FROM tab2 AS cor0
----
22752
271440
6720

query I rowsort
SELECT - ( cor0.col1 ) * + 12 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 167f6d70893ba96d936c6dea5da3dcb0

query I rowsort
SELECT col1 + - cor0.col2 * col2 * cor0.col2 FROM tab2 AS cor0
----
-17517
-19652
-54855

query I rowsort
SELECT + - 9 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

query I rowsort
SELECT DISTINCT - + col2 * col2 + 56 * + col2 FROM tab1 AS cor0
----
-3840
-57
108

query I rowsort
SELECT col1 * - 93 AS col0 FROM tab2 AS cor0
----
-1581
-2883
-5487

query I rowsort
SELECT ( - col2 ) + - col2 * col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT col0 + - col0 * + col2 FROM tab2 cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 62 * 33 col0 FROM tab2 AS cor0
----
-2046
-2046
-2046

query I rowsort
SELECT - cor0.col2 * col0 * - col1 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT 6 AS col0 FROM tab2 cor0
----
6
6
6

query I rowsort
SELECT col1 + col2 * - col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - col1 + + 32 * cor0.col1 * + col0 AS col1 FROM tab2 AS cor0
----
147205
42959
6913

query I rowsort
SELECT ALL col2 * ( - tab2.col0 + + col1 ) AS col0 FROM tab2
----
-2356
-494
648

query I rowsort
SELECT col1 * + col1 + + 6 FROM tab1
----
106
175
682

query I rowsort
SELECT col2 * 61 AS col1 FROM tab0
----
2013
5002
61

query I rowsort
SELECT - 77 - - col1 * cor0.col1 AS col1 FROM tab0 AS cor0
----
7319
8204
9332

query I rowsort
SELECT ALL + - cor0.col1 + - col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT col0 * col2 - ( + 22 ) FROM tab0 AS cor0
----
13
7276
770

onlyif mysql # use DIV operator for integer division
query I rowsort label-9540
SELECT + - col2 - col0 DIV - col0 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-9540
SELECT + - col2 - col0 / - col0 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT cor0.col2 + col2 * cor0.col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL + + col0 + - cor0.col0 * 44 FROM tab1 AS cor0
----
-129
-2752
-3440

query I rowsort
SELECT DISTINCT + 18 AS col0 FROM tab1 cor0
----
18

query I rowsort
SELECT 47 AS col1 FROM tab0 AS cor0
----
47
47
47

query I rowsort
SELECT ALL - col0 + - col1 + 33 FROM tab2 AS cor0
----
-104
-5
-63

query I rowsort
SELECT - 27 + cor0.col2 FROM tab2 cor0
----
-1
0
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-9547
SELECT DISTINCT + col2 * col2 + col1 DIV + 62 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-9547
SELECT DISTINCT + col2 * col2 + col1 / + 62 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT - cor0.col2 * 85 AS col2 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 34ee4df4490ac9849464d56156906997

query I rowsort
SELECT - + 46 * col0 + - col1 AS col2 FROM tab1 AS cor0
----
-164
-2954
-3693

query I rowsort
SELECT + 83 - col0 AS col1 FROM tab1 AS cor0
----
19
3
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9551
SELECT col1 * - col0 - col1 DIV + col0 col0 FROM tab2
----
-1343
-221
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9551
SELECT col1 * - col0 - col1 / + col0 col0 FROM tab2
----
-1343
-221
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9552
SELECT + col0 + 12 + col2 DIV + col0 FROM tab2
----
22
90
91

skipif mysql # not compatible
query I rowsort label-9552
SELECT + col0 + 12 + col2 / + col0 FROM tab2
----
22
90
91

query I rowsort
SELECT ALL 28 + tab1.col2 FROM tab1
----
124
82
85

query I rowsort
SELECT + + cor0.col0 * cor0.col1 + 77 * - 98 * col0 FROM tab2 AS cor0
----
-52605
-583986
-594791

query I rowsort
SELECT + + col2 * cor0.col1 + ( col1 ) - col0 FROM tab2 cor0
----
1515
584
861

query I rowsort
SELECT ALL - 9 + + col0 AS col0 FROM tab2 AS cor0
----
-2
69
70

query I rowsort
SELECT - - 16 + col2 + col2 FROM tab1 AS cor0
----
124
130
208

query I rowsort
SELECT ALL 77 * col0 AS col1 FROM tab0
----
1848
2695
6853

query I rowsort
SELECT - + col2 * + col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col1 + + tab2.col1 AS col1 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT - + 66 AS col2 FROM tab1, tab0, tab0 AS cor0
----
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 90 col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT ALL cor0.col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + 59 * col2 FROM tab1
----
3186
3363
5664

query I rowsort
SELECT DISTINCT - 90 * - col0 AS col2 FROM tab1 AS cor0
----
270
5760
7200

query I rowsort
SELECT 86 * col2 AS col2 FROM tab0 AS cor0
----
2838
7052
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * ( col2 ) col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + - col1 * 41 AS col0 FROM tab2 cor0
----
-1271
-2419
-697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9569
SELECT - cor0.col0 * - CAST( NULL AS SIGNED ) col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9569
SELECT - cor0.col0 * - CAST ( NULL AS INTEGER ) col0 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9570
SELECT DISTINCT + col2 - - ( - 36 ) DIV - col2 FROM tab0 AS cor0
----
34
37
82

skipif mysql # not compatible
query I rowsort label-9570
SELECT DISTINCT + col2 - - ( - 36 ) / - col2 FROM tab0 AS cor0
----
34
37
82

query I rowsort
SELECT + - col1 * 3 - + 64 FROM tab2 AS cor0
----
-115
-157
-241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 85 col0 FROM tab1 AS cor0
----
-28
-31
11

query I rowsort
SELECT ALL + col0 * + 39 AS col1 FROM tab2 AS cor0
----
273
3042
3081

query I rowsort
SELECT DISTINCT - tab0.col0 * + col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + 18 * tab0.col2 FROM tab0
----
1476
18
594

query I rowsort
SELECT - ( col0 ) * + col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + col0 * 90 * + col2 FROM tab0 AS cor0
----
3150
656820
71280

query I rowsort
SELECT col1 + 13 * col2 * + 74 FROM tab2 AS cor0
----
25071
26005
36573

query I rowsort
SELECT ALL col2 * cor0.col1 + + col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9580
SELECT - - col1 DIV + 67 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9580
SELECT - - col1 / + 67 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + 68 * col0 FROM tab0 cor0
----
1632
2380
6052

query I rowsort
SELECT + col0 * 50 AS col2 FROM tab0
----
1200
1750
4450

query I rowsort
SELECT DISTINCT - col1 + ( col0 ) * - 15 FROM tab0 AS cor0
----
-1426
-446
-622

onlyif mysql # use DIV operator for integer division
query I rowsort label-9584
SELECT DISTINCT ( - tab1.col1 ) DIV + col0 FROM tab1
----
-8
0

skipif mysql # not compatible
query I rowsort label-9584
SELECT DISTINCT ( - tab1.col1 ) / + col0 FROM tab1
----
-8
0

query I rowsort
SELECT DISTINCT + ( + ( - col1 ) ) * col2 * col2 AS col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT - ( - 87 ) * tab0.col2 * - 29 FROM tab0
----
-206886
-2523
-83259

query I rowsort
SELECT DISTINCT col2 * col0 * col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT + - 75 AS col2 FROM tab1 AS cor0
----
-75
-75
-75

query I rowsort
SELECT col2 * col0 + col1 * + col1 FROM tab0 AS cor0
----
15579
8188
9444

query I rowsort
SELECT + - ( - tab0.col2 ) FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-9591
SELECT ALL col2 + + col1 + 44 DIV - col0 col1 FROM tab2 AS cor0
----
52
55
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9591
SELECT ALL col2 + + col1 + 44 / - col0 col1 FROM tab2 AS cor0
----
52
55
85

query I rowsort
SELECT + 35 + - col0 AS col0 FROM tab1 AS cor0
----
-29
-45
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-9593
SELECT DISTINCT col2 DIV - col0 + - 9 col0 FROM tab0 AS cor0
----
-10
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9593
SELECT DISTINCT col2 / - col0 + - 9 col0 FROM tab0 AS cor0
----
-10
-9

query I rowsort
SELECT ALL - - 28 + col1 AS col1 FROM tab1 AS cor0
----
38
41
54

query I rowsort
SELECT DISTINCT - 77 + + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1611
-723
-914

query I rowsort
SELECT + ( 0 ) - col0 FROM tab1
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9597
SELECT CAST( col1 AS SIGNED ) * - tab2.col0 + 88 AS col1 FROM tab2
----
-1255
-129
-4514

skipif mysql # not compatible
query I rowsort label-9597
SELECT CAST ( col1 AS INTEGER ) * - tab2.col0 + 88 AS col1 FROM tab2
----
-1255
-129
-4514

query I rowsort
SELECT DISTINCT - cor0.col1 * - 16 - 32 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
128
176
384

query I rowsort
SELECT - 47 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 6942a0d9558277afd0d00408d65cf5aa

query I rowsort
SELECT col0 * col1 + + col1 FROM tab1
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 17 + + col1 col0 FROM tab2
----
34
48
76

query I rowsort
SELECT DISTINCT + cor1.col0 * 11 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
77
858
869

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col2 col2 FROM tab0 cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-9604
SELECT ALL - + col2 + col1 DIV - 7 AS col0 FROM tab2 AS cor0
----
-31
-34
-40

skipif mysql # not compatible
query I rowsort label-9604
SELECT ALL - + col2 + col1 / - 7 AS col0 FROM tab2 AS cor0
----
-31
-34
-40

query I rowsort
SELECT + col2 + col2 * col2 AS col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL col0 + - col1 * ( - 44 ) * + cor0.col0 FROM tab2 cor0
----
202566
59171
9555

onlyif mysql # use DIV operator for integer division
query I rowsort label-9607
SELECT DISTINCT + 6 DIV + col0 AS col0 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9607
SELECT DISTINCT + 6 / + col0 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + 44 * col0 AS col0 FROM tab0 AS cor0
----
1056
1540
3916

query I rowsort
SELECT 43 AS col0 FROM tab0 AS cor0
----
43
43
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-9610
SELECT ALL - col2 DIV - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9610
SELECT ALL - col2 / - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * - ( col0 ) AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - + col0 + + col2 * col2 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT + - col1 * + 13 FROM tab1 AS cor0
----
-130
-169
-338

onlyif mysql # use DIV operator for integer division
query I rowsort label-9614
SELECT - col2 DIV 54 - - cor0.col2 * + col2 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-9614
SELECT - col2 / 54 - - cor0.col2 * + col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT + 4 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT col1 + - ( + col1 * col0 ) AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - cor0.col0 + - cor0.col2 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9618
SELECT DISTINCT - col2 DIV - ( col0 * ( col2 ) ) + - col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-9618
SELECT DISTINCT - col2 / - ( col0 * ( col2 ) ) + - col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + 95 + - 9 AS col2 FROM tab1 AS cor0
----
86
86
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9620
SELECT ALL + ( - ( - col1 ) ) * - ( + cor0.col2 ) - col0 * CAST( col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-15561
-3492
-4902

skipif mysql # not compatible
query I rowsort label-9620
SELECT ALL + ( - ( - col1 ) ) * - ( + cor0.col2 ) - col0 * CAST ( col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-15561
-3492
-4902

query I rowsort
SELECT ALL - + ( - 76 ) - col1 AS col2 FROM tab2 AS cor0
----
17
45
59

query I rowsort
SELECT 49 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT ( cor0.col2 ) + col0 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 * + col0 + cor0.col0 col1 FROM tab0 cor0
----
1320
1925
4895

query I rowsort
SELECT + - 15 * - ( - col0 ) + + cor0.col2 AS col1 FROM tab1 AS cor0
----
-1104
-903
9

query I rowsort
SELECT ALL + + 25 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 cor1
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

query I rowsort
SELECT ALL - 30 * + col1 AS col0 FROM tab0 AS cor0
----
-2580
-2730
-2910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * ( - col2 ) col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-9629
SELECT + col0 DIV 24 col0 FROM tab0 AS cor0
----
1
1
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9629
SELECT + col0 / 24 col0 FROM tab0 AS cor0
----
1
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-9630
SELECT DISTINCT col2 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9630
SELECT DISTINCT col2 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9631
SELECT DISTINCT - - col0 * 71 + col1 DIV - col1 AS col0 FROM tab0 AS cor0
----
1703
2484
6318

skipif mysql # not compatible
query I rowsort label-9631
SELECT DISTINCT - - col0 * 71 + col1 / - col1 AS col0 FROM tab0 AS cor0
----
1703
2484
6318

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9632
SELECT - col1 + CAST( - ( - col2 ) AS SIGNED ) * col0 FROM tab0 AS cor0
----
-62
706
7207

skipif mysql # not compatible
query I rowsort label-9632
SELECT - col1 + CAST ( - ( - col2 ) AS INTEGER ) * col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT + col0 + - 92 AS col0 FROM tab0 AS cor0
----
-3
-57
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-9634
SELECT DISTINCT col1 DIV - col2 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9634
SELECT DISTINCT col1 / - col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + + cor0.col0 * + ( 9 ) FROM tab0 AS cor0
----
216
315
801

query I rowsort
SELECT DISTINCT col0 * 57 + col2 AS col1 FROM tab0 AS cor0
----
1401
1996
5155

query I rowsort
SELECT cor0.col1 * col2 + cor0.col1 * col2 AS col2 FROM tab0 cor0
----
14924
194
5676

query I rowsort
SELECT col1 * + 69 + col0 FROM tab0 AS cor0
----
5958
6368
6728

query I rowsort
SELECT col0 + - ( col2 ) * - cor0.col1 AS col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9640
SELECT - CAST( NULL AS SIGNED ) * 22 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9640
SELECT - CAST ( NULL AS INTEGER ) * 22 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + 30 * - col1 AS col2 FROM tab1 cor0
----
-300
-390
-780

query I rowsort
SELECT DISTINCT + 44 FROM tab0, tab0 cor0
----
44

query I rowsort
SELECT ALL - 43 FROM tab0, tab2 AS cor0
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

query I rowsort
SELECT + ( - 48 ) * + cor0.col2 AS col2 FROM tab1 cor0
----
-2592
-2736
-4608

query I rowsort
SELECT DISTINCT 62 - - col2 AS col2 FROM tab0
----
144
63
95

query I rowsort
SELECT ALL - ( col0 ) * + col2 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + + col1 * + col1 + - ( col2 ) + col1 AS col0 FROM tab2 cor0
----
268
3514
965

query I rowsort
SELECT ALL - 76 + cor1.col1 FROM tab0, tab0 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to f8f3dd8a7ca8f09292148d7a10f1bb26

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab0 cor1
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9650
SELECT ALL - tab1.col1 + + col1 * - col2 * CAST( + ( col1 ) AS SIGNED ) FROM tab1
----
-16237
-36530
-5710

skipif mysql # not compatible
query I rowsort label-9650
SELECT ALL - tab1.col1 + + col1 * - col2 * CAST ( + ( col1 ) AS INTEGER ) FROM tab1
----
-16237
-36530
-5710

query I rowsort
SELECT DISTINCT - ( col1 ) + 5 * col0 + - tab1.col0 FROM tab1
----
-14
246
307

query I rowsort
SELECT + tab2.col0 AS col2 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT col0 + + col2 * - col1 * col2 + - col1 FROM tab0
----
-159
-611886
-93716

query I rowsort
SELECT + - col2 + col2 + 98 FROM tab0 AS cor0
----
98
98
98

query I rowsort
SELECT DISTINCT - cor0.col2 * + cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - + col2 * col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT col1 * + col0 + - col2 * + col0 + + cor0.col2 * + 14 FROM tab1 cor0
----
-2210
-5296
672

onlyif mysql # use DIV operator for integer division
query I rowsort label-9658
SELECT col1 + + col0 DIV col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9658
SELECT col1 + + col0 / col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + ( 58 ) AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 9ee363c6ac19cfdb8a50c7dfd5cc2b8a

onlyif mysql # use DIV operator for integer division
query I rowsort label-9660
SELECT + col2 * - col2 + + col1 DIV col0 FROM tab2 AS cor0
----
-1444
-676
-725

skipif mysql # not compatible
query I rowsort label-9660
SELECT + col2 * - col2 + + col1 / col0 FROM tab2 AS cor0
----
-1444
-676
-725

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 + + cor0.col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT + 80 + col1 AS col1 FROM tab1 AS cor0
----
106
90
93

query I rowsort
SELECT + col1 * 78 + cor0.col0 FROM tab2 AS cor0
----
1405
2425
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9664
SELECT DISTINCT + col0 DIV - col1 + col2 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-9664
SELECT DISTINCT + col0 / - col1 + col2 FROM tab1
----
51
54
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9665
SELECT DISTINCT + 75 DIV col0 + + col1 FROM tab2 AS cor0
----
17
41
59

skipif mysql # not compatible
query I rowsort label-9665
SELECT DISTINCT + 75 / col0 + + col1 FROM tab2 AS cor0
----
17
41
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9666
SELECT - - cor0.col1 - col0 DIV 8 AS col1 FROM tab1 AS cor0
----
2
26
3

skipif mysql # not compatible
query I rowsort label-9666
SELECT - - cor0.col1 - col0 / 8 AS col1 FROM tab1 AS cor0
----
2
26
3

query I rowsort
SELECT ALL + 5 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT cor0.col2 * + 19 FROM tab2, tab1 AS cor0
----
9 values hashing to cceada998ac7ee4ff73047acfc238017

query I rowsort
SELECT ALL tab0.col0 * 36 FROM tab0
----
1260
3204
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-9670
SELECT - + col0 * col0 + 19 DIV - cor0.col0 col2 FROM tab2 AS cor0
----
-51
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9670
SELECT - + col0 * col0 + 19 / - cor0.col0 col2 FROM tab2 AS cor0
----
-51
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9671
SELECT + cor0.col0 * CAST( 95 * - col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-17955
-192660
-285190

skipif mysql # not compatible
query I rowsort label-9671
SELECT + cor0.col0 * CAST ( 95 * - col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-17955
-192660
-285190

query I rowsort
SELECT DISTINCT + col1 * + 93 FROM tab0
----
7998
8463
9021

query I rowsort
SELECT ALL - 12 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT DISTINCT - ( + 6 ) FROM tab1 AS cor0
----
-6

query I rowsort
SELECT + 89 AS col2 FROM tab0 cor0
----
89
89
89

query I rowsort
SELECT ALL + col2 * + col0 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-9677
SELECT DISTINCT - col2 DIV + col1 + col2 FROM tab2 AS cor0
----
26
27
36

skipif mysql # not compatible
query I rowsort label-9677
SELECT DISTINCT - col2 / + col1 + col2 FROM tab2 AS cor0
----
26
27
36

query I rowsort
SELECT + - 3 AS col2 FROM tab1 cor0
----
-3
-3
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9679
SELECT col2 * - col0 + + CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9679
SELECT col2 * - col0 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 3 * - col2 AS col1 FROM tab0 AS cor0
----
-246
-3
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9681
SELECT - col1 * + col2 - + CAST( - col1 AS SIGNED ) DIV + cor0.col0 FROM tab2 AS cor0
----
-1534
-646
-833

skipif mysql # not compatible
query I rowsort label-9681
SELECT - col1 * + col2 - + CAST ( - col1 AS INTEGER ) / + cor0.col0 FROM tab2 AS cor0
----
-1534
-646
-833

query I rowsort
SELECT DISTINCT + - 69 * cor0.col0 + + 56 FROM tab1 AS cor0
----
-151
-4360
-5464

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 31 * - col2 + - 77 col2 FROM tab1 cor0
----
1597
1690
2899

query I rowsort
SELECT 23 + + col0 AS col2 FROM tab2 AS cor0
----
101
102
30

query I rowsort
SELECT ALL + 23 AS col2 FROM tab2
----
23
23
23

query I rowsort
SELECT 50 * + tab0.col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 01e76136518b46f56b64850cb962537f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9687
SELECT DISTINCT - + CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab1, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9687
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab1, tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9688
SELECT + tab1.col0 DIV - col1 - + col0 col2 FROM tab1
----
-3
-70
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9688
SELECT + tab1.col0 / - col1 - + col0 col2 FROM tab1
----
-3
-70
-86

query I rowsort
SELECT - col2 * col1 + - col0 AS col1 FROM tab2 cor0
----
-1612
-725
-844

query I rowsort
SELECT + col1 * 66 FROM tab2 AS cor0
----
1122
2046
3894

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col1 * + col2 + col2 col2 FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT ALL 79 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT ALL ( - col1 ) * col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-9694
SELECT ALL + ( + 39 ) DIV col0 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9694
SELECT ALL + ( + 39 ) / col0 FROM tab0 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9695
SELECT ALL - 25 DIV col0 + + col2 FROM tab1 AS cor0
----
46
57
96

skipif mysql # not compatible
query I rowsort label-9695
SELECT ALL - 25 / col0 + + col2 FROM tab1 AS cor0
----
46
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9696
SELECT + col1 * cor0.col0 + col0 + - 16 DIV + col2 FROM tab0 AS cor0
----
2088
3414
8188

skipif mysql # not compatible
query I rowsort label-9696
SELECT + col1 * cor0.col0 + col0 + - 16 / + col2 FROM tab0 AS cor0
----
2088
3414
8188

query I rowsort
SELECT - + col0 * col0 + - col0 - - col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9698
SELECT ( + col2 ) + CAST( col1 AS SIGNED ) - + tab2.col0 * - col1 col0 FROM tab2
----
1398
275
4687

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9698
SELECT ( + col2 ) + CAST ( col1 AS INTEGER ) - + tab2.col0 * - col1 col0 FROM tab2
----
1398
275
4687

query I rowsort
SELECT - 22 * - col2 + - 4 + col0 * + col0 * + col2 AS col2 FROM tab2 AS cor0
----
158752
1913
237990

query I rowsort
SELECT + 81 + - col2 * 28 FROM tab2 AS cor0
----
-647
-675
-983

query I rowsort
SELECT + col0 + - col1 * 52 * 33 + col2 * col0 FROM tab2 AS cor0
----
-26091
-53000
-99138

query I rowsort
SELECT - col2 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT + - cor0.col1 * - 46 AS col0 FROM tab0 AS cor0
----
3956
4186
4462

query I rowsort
SELECT ALL col2 + 52 FROM tab0 AS cor0
----
134
53
85

query I rowsort
SELECT ALL - col2 + - 97 * col0 FROM tab1 AS cor0
----
-345
-6265
-7856

query I rowsort
SELECT ALL col2 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT col1 * 3 AS col2 FROM tab1 cor0
----
30
39
78

query I rowsort
SELECT ALL col1 + + ( cor0.col2 + + col0 ) AS col1 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT DISTINCT 98 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9710
SELECT ALL + col0 DIV tab1.col0 + - tab1.col0 - - 42 AS col2 FROM tab1
----
-21
-37
40

skipif mysql # not compatible
query I rowsort label-9710
SELECT ALL + col0 / tab1.col0 + - tab1.col0 - - 42 AS col2 FROM tab1
----
-21
-37
40

query I rowsort
SELECT ALL col2 - + col1 AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT ALL + 1 + col1 - col2 * - col1 AS col1 FROM tab2
----
1594
664
869

query I rowsort
SELECT col0 * tab2.col2 * + tab2.col2 + - col2 * + col2 FROM tab2
----
112632
4374
52052

query I rowsort
SELECT - col1 * 5 + + col0 FROM tab2 AS cor0
----
-148
-217
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9715
SELECT DISTINCT + 82 DIV + col0 FROM tab0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-9715
SELECT DISTINCT + 82 / + col0 FROM tab0
----
0
2
3

query I rowsort
SELECT DISTINCT - + 3 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 cor1
----
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - 83 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * 65 * col1 col2 FROM tab2
----
18785
226265
62465

query I rowsort
SELECT + 74 - + cor0.col1 FROM tab1 AS cor0
----
48
61
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - col2 * col2 - 84 col0 FROM tab1 AS cor0
----
-157548
-185277
-884820

query I rowsort
SELECT - 50 FROM tab0, tab1 AS cor0
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT tab1.col2 * 46 + col2 FROM tab1
----
2538
2679
4512

onlyif mysql # use DIV operator for integer division
query I rowsort label-9724
SELECT 2 DIV - col1 col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9724
SELECT 2 / - col1 col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT 37 + col0 * col2 * - col2 + col2 AS col1 FROM tab1 AS cor0
----
-207842
-737147
-8657

query I rowsort
SELECT ( + col1 ) * + 0 - col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + + cor0.col2 * - cor0.col2 + ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9728
SELECT - 5 * + col2 + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9728
SELECT - 5 * + col2 + CAST ( NULL AS REAL ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 84 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to aaabc1266a1bb4f477091ffbc243c849

query I rowsort
SELECT - col1 + col0 * + ( - col1 ) - col1 AS col2 FROM tab2 AS cor0
----
-1377
-279
-4720

query I rowsort
SELECT + ( + col0 ) + - cor0.col1 * + ( + col1 ) + - col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT 90 * + cor1.col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
2340
2430
3420

query I rowsort
SELECT DISTINCT 73 * ( col1 ) * 86 + col0 * - col1 FROM tab1 AS cor0
----
163150
62140
80574

query I rowsort
SELECT + col0 + - col0 + + col0 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col1 * - 68 * col2 FROM tab0 AS cor0
----
-192984
-507416
-6596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( + col2 ) * col2 col1 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-9737
SELECT DISTINCT + 46 DIV - col1 FROM tab1 AS cor0
----
-1
-3
-4

skipif mysql # not compatible
query I rowsort label-9737
SELECT DISTINCT + 46 / - col1 FROM tab1 AS cor0
----
-1
-3
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col1 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - cor0.col2 * 86 * - col1 FROM tab2 AS cor0
----
131924
55556
71982

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9740
SELECT CAST( NULL AS SIGNED ) * + col1 + cor0.col1 + 38 * col2 * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9740
SELECT CAST ( NULL AS INTEGER ) * + col1 + cor0.col1 + 38 * col2 * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - 5 + col2 col1 FROM tab0 AS cor0
----
198
492
6

query I rowsort
SELECT ALL + 50 + col2 AS col1 FROM tab0 AS cor0
----
132
51
83

query I rowsort
SELECT ALL - col2 * - 97 FROM tab0 cor0
----
3201
7954
97

query I rowsort
SELECT + col2 * col1 * col1 + - col2 * 78 AS col0 FROM tab2 AS cor0
----
23841
8018
88478

query I rowsort
SELECT ALL + - col1 * col1 + col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT + - col0 + - col2 + col0 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - col2 * cor0.col2 FROM tab1 cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9748
SELECT ALL + cor0.col1 + col0 - - CAST( 9 + + cor0.col0 AS SIGNED ) FROM tab1 AS cor0
----
147
182
41

skipif mysql # not compatible
query I rowsort label-9748
SELECT ALL + cor0.col1 + col0 - - CAST ( 9 + + cor0.col0 AS INTEGER ) FROM tab1 AS cor0
----
147
182
41

query I rowsort
SELECT DISTINCT + col1 - col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT + + cor0.col1 + + col0 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT 55 + ( col1 + + 9 ) AS col0 FROM tab1
----
74
77
90

query I rowsort
SELECT DISTINCT + - col0 + 4 AS col0 FROM tab1 AS cor0
----
-60
-76
1

query I rowsort
SELECT DISTINCT - col0 * ( col1 ) + + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col1 col1 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9755
SELECT ALL - + col1 / - CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9755
SELECT ALL - + col1 / - CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9756
SELECT - cor0.col1 * - CAST( - 65 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-1105
-2015
-3835

skipif mysql # not compatible
query I rowsort label-9756
SELECT - cor0.col1 * - CAST ( - 65 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-1105
-2015
-3835

query I rowsort
SELECT DISTINCT - - col1 * 4 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT ALL - col0 + + 54 AS col1 FROM tab2 cor0
----
-24
-25
47

query I rowsort
SELECT 20 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT tab1.col2 * + 75 FROM tab1
----
4050
4275
7200

query I rowsort
SELECT ALL - col1 * - 69 - col1 FROM tab0
----
5848
6188
6596

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9762
SELECT CAST( NULL AS DECIMAL ) - - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9762
SELECT CAST ( NULL AS REAL ) - - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9763
SELECT ALL col2 * - CAST( NULL AS SIGNED ) - - col0 * + tab1.col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9763
SELECT ALL col2 * - CAST ( NULL AS INTEGER ) - - col0 * + tab1.col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9764
SELECT DISTINCT col2 + - col2 DIV 8 AS col0 FROM tab1
----
48
50
84

skipif mysql # not compatible
query I rowsort label-9764
SELECT DISTINCT col2 + - col2 / 8 AS col0 FROM tab1
----
48
50
84

query I rowsort
SELECT ALL - tab1.col1 + - 18 FROM tab1
----
-28
-31
-44

query I rowsort
SELECT col0 * cor0.col1 * + col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT - col0 + ( - 24 ) * + col0 * - col1 + - tab0.col1 AS col2 FROM tab0
----
194196
49426
81348

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 47 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 56 + - col1 + ( - 68 * - col0 ) col0 FROM tab0 AS cor0
----
10945
2890
4243

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0, tab2 cor1, tab2 cor2
----
972 values hashing to 958533d1a7bf61199ed7c03eadf37f9a

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 cor2
----
972 values hashing to d522b52b67b20888d3544d25cb98f232

query I rowsort
SELECT DISTINCT 28 FROM tab0, tab0 AS cor0
----
28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9773
SELECT DISTINCT + CAST( col1 AS SIGNED ) AS col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9773
SELECT DISTINCT + CAST ( col1 AS INTEGER ) AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT 88 + 8 + - col1 FROM tab0
----
-1
10
5

query I rowsort
SELECT + 84 * - col1 * - col0 AS col0 FROM tab2
----
112812
18228
386568

onlyif mysql # use DIV operator for integer division
query I rowsort label-9776
SELECT + col2 DIV + col2 + - col2 + col1 FROM tab0 AS cor0
----
10
54
97

skipif mysql # not compatible
query I rowsort label-9776
SELECT + col2 / + col2 + - col2 + col1 FROM tab0 AS cor0
----
10
54
97

query I rowsort
SELECT - col2 * col1 + col1 + - cor0.col0 FROM tab2 AS cor0
----
-1553
-708
-813

query I rowsort
SELECT - col2 * + col0 * - col0 FROM tab2
----
1323
158184
237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col0 AS REAL ) * col1 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9780
SELECT DISTINCT ( col1 ) * + CAST( col0 * + col2 AS SIGNED ) FROM tab2
----
119652
51034
5859

skipif mysql # not compatible
query I rowsort label-9780
SELECT DISTINCT ( col1 ) * + CAST ( col0 * + col2 AS INTEGER ) FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL 50 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT - col2 + + tab1.col2 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT - 35 + + col1 FROM tab2
----
-18
-4
24

query I rowsort
SELECT ALL - col0 * col2 - - col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL + 83 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT ALL - ( col2 ) + col2 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 col0 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT + - 82 + tab2.col0 * - 18 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 8f0b1ea0c29605f066a6ba366f758577

query I rowsort
SELECT DISTINCT + col2 * 70 * - cor0.col2 - - col0 FROM tab2 AS cor0
----
-101001
-47242
-51023

query I rowsort
SELECT ALL - col2 * - col1 AS col1 FROM tab2 cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-9791
SELECT DISTINCT + - col1 * + col0 DIV cor0.col0 + + col1 DIV + 73 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-9791
SELECT DISTINCT + - col1 * + col0 / cor0.col0 + + col1 / + 73 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT 94 + - cor0.col1 * - 3 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
145
187
271

query I rowsort
SELECT + - col0 + + 21 FROM tab0 AS cor0
----
-14
-3
-68

query I rowsort
SELECT + + col2 + + 75 * col0 AS col0 FROM tab1 AS cor0
----
279
4857
6096

query I rowsort
SELECT ALL - 97 AS col0 FROM tab0
----
-97
-97
-97

query I rowsort
SELECT DISTINCT + + col0 + - cor0.col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + 62 + col2 FROM tab0 AS cor0
----
144
63
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 3 col2 FROM tab2, tab1 AS cor0
----
3

query I rowsort
SELECT ALL + 65 * + col2 FROM tab2 AS cor0
----
1690
1755
2470

query I rowsort
SELECT ALL 12 * + col1 FROM tab0 AS cor0
----
1032
1092
1164

query I rowsort
SELECT - col2 + - col1 * 65 AS col1 FROM tab0
----
-5623
-5997
-6306

onlyif mysql # use DIV operator for integer division
query I rowsort label-9802
SELECT + col0 DIV col2 - + col0 FROM tab1
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-9802
SELECT + col0 / col2 - + col0 FROM tab1
----
-3
-63
-80

query I rowsort
SELECT DISTINCT - col1 * col1 + col1 + - 93 FROM tab1
----
-183
-249
-743

query I rowsort
SELECT DISTINCT col0 * + col1 * - cor0.col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT - ( col1 ) + + col1 * + ( + col2 + col2 * col2 ) FROM tab0 cor0
----
619255
96406
97

query I rowsort
SELECT ALL - 4 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 39ed23475412c3cbba02ecdd2d7018e6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * tab0.col1 col0 FROM tab0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9808
SELECT col1 + + cor0.col1 * - CAST( col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

skipif mysql # not compatible
query I rowsort label-9808
SELECT col1 + + cor0.col1 * - CAST ( col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + col1 - tab2.col2 AS col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT col2 + ( + col0 ) * col0 * + 6 - - 89 * + col2 AS col0 FROM tab0
----
54906
6426
7440

query I rowsort
SELECT col0 * col2 + + col2 + - col0 AS col1 FROM tab2
----
1976
209
2961

query I rowsort
SELECT - 60 AS col0 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 1a0b29f8e6f82c54623a665ba4af8fd1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 59 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT tab1.col2 * - tab1.col2 + col0 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT ALL col1 - ( - tab2.col0 ) FROM tab2
----
137
38
96

query I rowsort
SELECT col2 - + ( 29 * col0 ) FROM tab0
----
-1014
-2499
-663

query I rowsort
SELECT DISTINCT 18 * 62 FROM tab0 AS cor0
----
1116

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) + col1 - col2 / + 88 AS col2 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9819
SELECT DISTINCT ( + col0 ) DIV + cor0.col0 + + cor0.col2 * col2 + col1 FROM tab1 AS cor0
----
2943
3260
9230

skipif mysql # not compatible
query I rowsort label-9819
SELECT DISTINCT ( + col0 ) / + cor0.col0 + + cor0.col2 * col2 + col1 FROM tab1 AS cor0
----
2943
3260
9230

query I rowsort
SELECT DISTINCT + cor0.col0 + + 1 * col0 + - 48 FROM tab1 AS cor0
----
-42
112
80

query I rowsort
SELECT tab0.col2 * - 79 FROM tab0
----
-2607
-6478
-79

query I rowsort
SELECT 36 * col2 AS col1 FROM tab1 AS cor0
----
1944
2052
3456

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * - col0 + + cor0.col2 * + cor0.col0 col0 FROM tab2 cor0
----
-3239
-4056
140

query I rowsort
SELECT DISTINCT + - ( + col2 ) + col2 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT + 34 * + col2 + + cor0.col0 * + cor0.col2 - - 91 AS col0 FROM tab0 AS cor0
----
10177
160
2005

onlyif mysql # use DIV operator for integer division
query I rowsort label-9826
SELECT ALL - - 5 DIV + col0 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9826
SELECT ALL - - 5 / + col0 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9827
SELECT ( 68 ) DIV col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9827
SELECT ( 68 ) / col2 FROM tab1
----
0
1
1

query I rowsort
SELECT ALL ( ( col0 ) ) * tab0.col2 + - col1 FROM tab0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-9829
SELECT ALL tab1.col1 DIV - col1 + col1 * + tab1.col1 + col1 FROM tab1
----
109
181
701

skipif mysql # not compatible
query I rowsort label-9829
SELECT ALL tab1.col1 / - col1 + col1 * + tab1.col1 + col1 FROM tab1
----
109
181
701

query I rowsort
SELECT - - cor0.col1 + col1 AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL col1 * 68 + tab1.col2 FROM tab1
----
1822
737
980

query I rowsort
SELECT ALL tab0.col0 + ( + col0 ) AS col1 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL - 83 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

onlyif mysql # use DIV operator for integer division
query I rowsort label-9834
SELECT ALL - ( col2 ) DIV col1 + col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1255
-1406
-575

skipif mysql # not compatible
query I rowsort label-9834
SELECT ALL - ( col2 ) / col1 + col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1255
-1406
-575

query I rowsort
SELECT ALL + col2 * + 52 + col1 AS col2 FROM tab2 AS cor0
----
1411
1435
1993

query I rowsort
SELECT ALL + col1 + 98 FROM tab2 AS cor0
----
115
129
157

query I rowsort
SELECT DISTINCT - + 52 * - 33 FROM tab1 AS cor0
----
1716

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9838
SELECT ALL - + CAST( + col2 AS SIGNED ) FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-9838
SELECT ALL - + CAST ( + col2 AS INTEGER ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT col1 + col2 * + col2 FROM tab0 AS cor0
----
1175
6815
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9840
SELECT - 14 - - 13 DIV col1 AS col0 FROM tab1 AS cor0
----
-13
-13
-14

skipif mysql # not compatible
query I rowsort label-9840
SELECT - 14 - - 13 / col1 AS col0 FROM tab1 AS cor0
----
-13
-13
-14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 70 * + col0 + col1 col2 FROM tab0 AS cor0
----
-1594
-2353
-6139

query I rowsort
SELECT - col0 * - col0 + col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT - ( col0 ) + + col0 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9844
SELECT DISTINCT col1 + cor0.col1 * + cor0.col2 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-9844
SELECT DISTINCT col1 + cor0.col1 * + cor0.col2 / cor0.col2 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL col0 * col1 - + col0 * col2 AS col1 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT 96 * - col0 * - col0 AS col0 FROM tab1 cor0
----
393216
614400
864

query I rowsort
SELECT col1 * + cor0.col1 + col0 AS col2 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT ALL - 39 * + col1 - col0 AS col2 FROM tab0 AS cor0
----
-3378
-3638
-3818

query I rowsort
SELECT DISTINCT - 49 * col1 AS col0 FROM tab0 AS cor0
----
-4214
-4459
-4753

query I rowsort
SELECT - + 83 + - col0 FROM tab0 cor0
----
-107
-118
-172

query I rowsort
SELECT DISTINCT + col1 * col1 + col0 FROM tab2 cor0
----
3559
368
968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 64 * - col2 + - col2 col2 FROM tab2 AS cor0
----
1638
1701
2394

onlyif mysql # use DIV operator for integer division
query I rowsort label-9853
SELECT DISTINCT - col0 + col2 DIV col0 FROM tab1 AS cor0
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-9853
SELECT DISTINCT - col0 + col2 / col0 FROM tab1 AS cor0
----
-64
-79
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col1 col2 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-9855
SELECT DISTINCT + + 55 + col0 DIV cor0.col1 FROM tab2 AS cor0
----
55
56
59

skipif mysql # not compatible
query I rowsort label-9855
SELECT DISTINCT + + 55 + col0 / cor0.col1 FROM tab2 AS cor0
----
55
56
59

query I rowsort
SELECT ALL - 86 - - col0 FROM tab2
----
-7
-79
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9857
SELECT ALL + CAST( NULL AS DECIMAL ) - - tab1.col2 * - col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9857
SELECT ALL + CAST ( NULL AS REAL ) - - tab1.col2 * - col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + col2 ) + - col2 * + col2 FROM tab0
----
-1122
-2
-6806

query I rowsort
SELECT ALL + - 0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - 0 * col2 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - col0 * + col1 * + cor0.col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9862
SELECT DISTINCT cor0.col2 * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9862
SELECT DISTINCT cor0.col2 * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col0 * + 93 FROM tab0 AS cor0
----
2232
3255
8277

query I rowsort
SELECT col0 * + col1 * - col0 FROM tab1 AS cor0
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 9 col1 FROM tab1 cor0
----
-27
-576
-720

query I rowsort
SELECT ALL - + cor0.col0 * 33 AS col0 FROM tab1 cor0
----
-2112
-2640
-99

query I rowsort
SELECT DISTINCT col0 + ( - cor0.col2 ) FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL + ( - col1 ) * - 14 FROM tab1
----
140
182
364

query I rowsort
SELECT DISTINCT col0 * col1 * col0 + + col1 FROM tab0 AS cor0
----
118922
49622
720902

onlyif mysql # use DIV operator for integer division
query I rowsort label-9870
SELECT ALL - + col2 DIV 99 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9870
SELECT ALL - + col2 / 99 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col0 * ( col1 ) + col2 * col0 col1 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT ALL 3 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT col2 + - tab1.col1 AS col2 FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT + 95 + + col1 AS col0 FROM tab0
----
181
186
192

query I rowsort
SELECT ALL 74 * - col0 + + 37 * col0 * col0 AS col0 FROM tab2
----
1295
219336
225071

query I rowsort
SELECT + + col2 * + col1 + + cor0.col0 + - cor0.col1 * + col2 AS col0 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 6 * col1 + col0 col2 FROM tab0 AS cor0
----
626
714
726

query I rowsort
SELECT + col2 * col2 + + ( col0 ) FROM tab0
----
1113
36
6813

query I rowsort
SELECT DISTINCT - 19 AS col2 FROM tab0
----
-19

onlyif mysql # use DIV operator for integer division
query I rowsort label-9880
SELECT DISTINCT + col1 DIV + cor0.col1 AS col2 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-9880
SELECT DISTINCT + col1 / + cor0.col1 AS col2 FROM tab0 AS cor0
----
1

query I rowsort
SELECT ALL - - col0 + + col2 * + 9 AS col2 FROM tab0 AS cor0
----
321
44
827

query I rowsort
SELECT + tab0.col0 * tab0.col0 * col2 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT col1 * col0 + - 93 AS col1 FROM tab0 AS cor0
----
1971
3302
8006

query I rowsort
SELECT DISTINCT col0 + + 50 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1303
564
730

query I rowsort
SELECT col1 + + ( col0 ) - + col2 * cor0.col0 FROM tab2 AS cor0
----
-151
-1891
-2906

onlyif mysql # use DIV operator for integer division
query I rowsort label-9886
SELECT - col1 + col2 + 11 DIV col0 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-9886
SELECT - col1 + col2 + 11 / col0 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9887
SELECT DISTINCT + col2 * ( col2 * + col0 ) + col1 + col2 * col2 DIV - col2 FROM tab0 AS cor0
----
131
26189
598445

skipif mysql # not compatible
query I rowsort label-9887
SELECT DISTINCT + col2 * ( col2 * + col0 ) + col1 + col2 * col2 / - col2 FROM tab0 AS cor0
----
131
26189
598445

query I rowsort
SELECT col1 + cor0.col1 * - col1 * + col2 AS col2 FROM tab0 AS cor0
----
-243982
-678951
-9312

query I rowsort
SELECT DISTINCT + col2 * + ( col0 ) + - col2 * + 91 * - col0 FROM tab1 AS cor0
----
14904
335616
706560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9890
SELECT + - col0 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9890
SELECT + - col0 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 + 34 FROM tab0 cor0
----
-1
-55
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-9892
SELECT ALL + ( col0 ) * col1 DIV 46 AS col2 FROM tab2 AS cor0
----
100
29
4

skipif mysql # not compatible
query I rowsort label-9892
SELECT ALL + ( col0 ) * col1 / 46 AS col2 FROM tab2 AS cor0
----
100
29
4

query I rowsort
SELECT DISTINCT + col2 + 22 AS col2 FROM tab2 cor0
----
48
49
60

query I rowsort
SELECT ALL + col1 * - ( + cor0.col1 ) - - ( col1 ) AS col0 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL + + col0 * + 81 FROM tab0 AS cor0
----
1944
2835
7209

query I rowsort
SELECT DISTINCT + - col1 + ( - col1 ) FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT col2 * - 17 FROM tab2 AS cor0
----
-442
-459
-646

query I rowsort
SELECT ALL col1 * + col1 + col0 * - col1 AS col2 FROM tab2 AS cor0
----
-1054
-1121
744

query I rowsort
SELECT + 15 + + col0 * + cor0.col0 FROM tab0 AS cor0
----
1240
591
7936

query I rowsort
SELECT ALL - col1 * 85 FROM tab0 cor0
----
-7310
-7735
-8245

query I rowsort
SELECT DISTINCT col1 * - 42 FROM tab1 AS cor0
----
-1092
-420
-546

query I rowsort
SELECT DISTINCT + col1 * + 58 AS col1 FROM tab2 AS cor0
----
1798
3422
986

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9903
SELECT ALL + CAST( NULL AS SIGNED ) * col2 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-9903
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 1 + col2 col1 FROM tab1 AS cor0
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9905
SELECT ALL - ( - col0 ) + col1 * col2 DIV col0 AS col1 FROM tab1 AS cor0
----
471
72
95

skipif mysql # not compatible
query I rowsort label-9905
SELECT ALL - ( - col0 ) + col1 * col2 / col0 AS col1 FROM tab1 AS cor0
----
471
72
95

query I rowsort
SELECT DISTINCT cor0.col1 + col0 * col1 * + ( col1 ) FROM tab0 AS cor0
----
177590
329412
737100

query I rowsort
SELECT 29 * - col2 FROM tab2 AS cor0
----
-1102
-754
-783

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9908
SELECT - - CAST( NULL AS SIGNED ) / + cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9908
SELECT - - CAST ( NULL AS INTEGER ) / + cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 1 + - col0 * 94 col1 FROM tab2 AS cor0
----
-657
-7331
-7425

query I rowsort
SELECT 42 + + col1 AS col1 FROM tab1
----
52
55
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9911
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9911
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + ( - 17 ) FROM tab1, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT + 22 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT - 93 * - col2 + - col2 + + 89 FROM tab1 AS cor0
----
5057
5333
8921

onlyif mysql # use DIV operator for integer division
query I rowsort label-9915
SELECT - 78 DIV - col0 + + col1 FROM tab0 AS cor0
----
89
91
99

skipif mysql # not compatible
query I rowsort label-9915
SELECT - 78 / - col0 + + col1 FROM tab0 AS cor0
----
89
91
99

query I rowsort
SELECT - 3 * + col2 + col2 + - col2 FROM tab0 cor0
----
-246
-3
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9917
SELECT CAST( 63 AS SIGNED ) AS col0 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

skipif mysql # not compatible
query I rowsort label-9917
SELECT CAST ( 63 AS INTEGER ) AS col0 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT col0 * - 68 FROM tab2
----
-476
-5304
-5372

query I rowsort
SELECT DISTINCT cor1.col2 - 59 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
-26
-58
23

query I rowsort
SELECT DISTINCT + ( - col1 ) * + col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + + col1 + 52 FROM tab1 AS cor0
----
62
65
78

query I rowsort
SELECT + + 21 + - col0 FROM tab1 AS cor0
----
-43
-59
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 col2 FROM tab2 cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 96 ) * - col2 col2 FROM tab2
----
2496
2592
3648

query I rowsort
SELECT - ( col2 ) - col2 AS col1 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT + col0 * 95 + + col0 FROM tab1 AS cor0
----
288
6144
7680

query I rowsort
SELECT col1 - - 60 AS col0 FROM tab0 cor0
----
146
151
157

query I rowsort
SELECT - ( + col0 ) + cor0.col1 * - 16 FROM tab1 AS cor0
----
-224
-288
-419

query I rowsort
SELECT - - ( - 89 ) - - col0 AS col2 FROM tab0 cor0
----
-54
-65
0

query I rowsort
SELECT ALL - 0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT ALL - col0 * - col1 + col2 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT + ( + 43 ) * - col2 FROM tab0
----
-1419
-3526
-43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9933
SELECT ALL - + CAST( 83 AS SIGNED ) AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

skipif mysql # not compatible
query I rowsort label-9933
SELECT ALL - + CAST ( 83 AS INTEGER ) AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT + col1 * + 40 AS col1 FROM tab0
----
3440
3640
3880

query I rowsort
SELECT DISTINCT + 85 FROM tab0, tab1 AS cor0
----
85

query I rowsort
SELECT DISTINCT + 84 * col0 AS col2 FROM tab0
----
2016
2940
7476

query I rowsort
SELECT DISTINCT - 33 * + tab2.col1 FROM tab2
----
-1023
-1947
-561

query I rowsort
SELECT DISTINCT - col1 + ( - col2 ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + - col1 * 23 AS col2 FROM tab0 cor0
----
-1978
-2093
-2231

query I rowsort
SELECT 31 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT + 54 - + col1 AS col0 FROM tab2
----
-5
23
37

query I rowsort
SELECT ALL - tab1.col2 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-9944
SELECT + + col2 * col1 DIV - col0 AS col2 FROM tab2 AS cor0
----
-119
-19
-8

skipif mysql # not compatible
query I rowsort label-9944
SELECT + + col2 * col1 / - col0 AS col2 FROM tab2 AS cor0
----
-119
-19
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + ( col1 ) col0 FROM tab1
----
28
47
83

query I rowsort
SELECT ALL + col2 - + col2 * + cor0.col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT - - col2 * - ( + col0 ) FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 69 * col1 - - col0 col1 FROM tab1 AS cor0
----
1797
754
977

onlyif mysql # use DIV operator for integer division
query I rowsort label-9949
SELECT ALL + col2 * cor0.col0 + + cor0.col2 * cor0.col2 + col0 DIV col1 AS col1 FROM tab0 AS cor0
----
14022
1881
36

skipif mysql # not compatible
query I rowsort label-9949
SELECT ALL + col2 * cor0.col0 + + cor0.col2 * cor0.col2 + col0 / col1 AS col1 FROM tab0 AS cor0
----
14022
1881
36

query I rowsort
SELECT - 27 + - 30 FROM tab0 cor0
----
-57
-57
-57

query I rowsort
SELECT DISTINCT + ( col2 ) + + col0 * - 79 * + col1 FROM tab2 AS cor0
----
-106059
-17116
-363532

query I rowsort
SELECT DISTINCT - - 94 * col0 AS col2 FROM tab2 cor0
----
658
7332
7426

query I rowsort
SELECT ALL cor0.col1 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - 44 FROM tab2 AS cor0
----
44
44
44

query I rowsort
SELECT DISTINCT - + col0 * - 92 + - col1 FROM tab0 AS cor0
----
2122
3123
8097

query I rowsort
SELECT DISTINCT - 35 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-28
43
44

query I rowsort
SELECT ALL 42 * 28 * + col1 AS col1 FROM tab2 AS cor0
----
19992
36456
69384

query I rowsort
SELECT ALL - 39 * 45 FROM tab1 AS cor0
----
-1755
-1755
-1755

query I rowsort
SELECT DISTINCT - - 52 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
130
131
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + 65 ) col1 FROM tab2 AS cor0
----
-65
-65
-65

query I rowsort
SELECT ALL + ( + col2 ) + + col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + 25 + - col1 + col2 AS col0 FROM tab2 AS cor0
----
-8
21
46

query I rowsort
SELECT ALL + col1 * + cor0.col1 - col0 AS col0 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT - 19 + col1 * 21 + col1 AS col1 FROM tab1 AS cor0
----
201
267
553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * col0 col1 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9966
SELECT + col0 DIV col2 + col2 * + 76 AS col1 FROM tab1 cor0
----
4104
4333
7296

skipif mysql # not compatible
query I rowsort label-9966
SELECT + col0 / col2 + col2 * + 76 AS col1 FROM tab1 cor0
----
4104
4333
7296

query I rowsort
SELECT ALL ( cor0.col0 ) * 92 + + col0 * + cor0.col2 FROM tab0 AS cor0
----
15486
3000
3255

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 21 * cor0.col1 * + ( - col0 ) - - col0 * - 42 col2 FROM tab0 cor0
----
166341
42336
69825

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - 72 FROM tab1 AS cor0
----
-72
-72
-72

query I rowsort
SELECT - - col2 * - col1 * - ( + col1 ) + + col2 FROM tab1 cor0
----
16320
36558
5757

onlyif mysql # use DIV operator for integer division
query I rowsort label-9972
SELECT + + col0 DIV - col2 + - col1 + 34 FROM tab1 AS cor0
----
21
23
8

skipif mysql # not compatible
query I rowsort label-9972
SELECT + + col0 / - col2 + - col1 + 34 FROM tab1 AS cor0
----
21
23
8

query I rowsort
SELECT ALL + + 98 FROM tab1 cor0
----
98
98
98

query I rowsort
SELECT + + ( col0 ) * - cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT + 92 + cor0.col0 AS col0 FROM tab1 AS cor0
----
156
172
95

query I rowsort
SELECT DISTINCT + col0 * ( col2 ) AS col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9977
SELECT ALL col0 * CAST( + col0 AS SIGNED ) + cor0.col0 AS col2 FROM tab0 AS cor0
----
1260
600
8010

skipif mysql # not compatible
query I rowsort label-9977
SELECT ALL col0 * CAST ( + col0 AS INTEGER ) + cor0.col0 AS col2 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT col2 * ( + col2 * + col1 + + ( + col0 ) ) FROM tab1 AS cor0
----
127488
36138
75978

query I rowsort
SELECT DISTINCT col0 * - cor0.col0 + + col2 * + col0 AS col0 FROM tab0 AS cor0
----
-1190
-623
216

query I rowsort
SELECT DISTINCT col0 + 54 * col0 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT ALL 94 + col1 AS col2 FROM tab0
----
180
185
191

query I rowsort
SELECT DISTINCT - 17 * + col0 AS col0 FROM tab0
----
-1513
-408
-595

query I rowsort
SELECT tab1.col2 * - tab1.col2 + - col1 AS col1 FROM tab1
----
-2942
-3259
-9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-9984
SELECT - col1 DIV + col1 + col1 * col2 col1 FROM tab1
----
1247
1403
569

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9984
SELECT - col1 / + col1 + col1 * col2 col1 FROM tab1
----
1247
1403
569

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + col2 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - + cor0.col2 * - col1 * - cor0.col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL col2 * col1 + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - - col2 * + col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-9989
SELECT DISTINCT col2 * tab1.col2 DIV col1 + - col2 AS col1 FROM tab1
----
267
58
612

skipif mysql # not compatible
query I rowsort label-9989
SELECT DISTINCT col2 * tab1.col2 / col1 + - col2 AS col1 FROM tab1
----
267
58
612

query I rowsort
SELECT + ( col0 * + col1 ) FROM tab2
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col1 col0 FROM tab1 WHERE ( NOT ( NULL ) BETWEEN NULL AND NULL ) AND NULL <> + col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9992
SELECT ALL - - 93 * col2 * col1 + col0 DIV + col1 AS col1 FROM tab2 AS cor0
----
142663
60082
77841

skipif mysql # not compatible
query I rowsort label-9992
SELECT ALL - - 93 * col2 * col1 + col0 / + col1 AS col1 FROM tab2 AS cor0
----
142663
60082
77841

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col0 col1 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT cor0.col2 * - col2 * cor0.col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT ALL + col1 + + tab0.col1 AS col1 FROM tab0
----
172
182
194

query I rowsort
SELECT - col0 + cor0.col1 AS col2 FROM tab0 cor0
----
2
62
62

