sqllogictest
Artifact Content
Not logged in

Artifact ddba11cc26ec1337dc06c6b9febd94d7d249623c:


hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT - col0 * - 25 * - col0 AS col2 FROM tab2 AS cor0
----
-1225
-152100
-156025

query I rowsort
SELECT ALL - 25 + - col2 FROM tab2 AS cor0
----
-51
-52
-63

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

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

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

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

query I rowsort
SELECT DISTINCT - 74 * + tab2.col1 AS col1 FROM tab2, tab1 AS cor0
----
-1258
-2294
-4366

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 92 - col2 * col2 col1 FROM tab0
----
-1021
-6721
56

query I rowsort
SELECT DISTINCT col1 - - col0 * col2 * - col2 FROM tab0
----
-26050
-598345
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-10
SELECT - col2 * - 70 + tab0.col1 DIV col0 + 50 * col1 AS col0 FROM tab0
----
10291
4922
6613

skipif mysql # not compatible
query I rowsort label-10
SELECT - col2 * - 70 + tab0.col1 / col0 + 50 * col1 AS col0 FROM tab0
----
10291
4922
6613

skipif mysql # not compatible
query I rowsort
SELECT tab2.col2 * - CAST ( - 11 * - col1 AS REAL ) AS col0 FROM tab2
----
-16874
-7106
-9207

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT ( NULL ) NOT IN ( + col0 )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-13
SELECT tab1.col0 + + col2 / - col0 col0 FROM tab1
----
-15
64
79

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-15
SELECT - tab2.col2 * + col0 + col1 + - tab2.col1 DIV + col0 FROM tab2
----
-162
-1969
-2985

skipif mysql # not compatible
query I rowsort label-15
SELECT - tab2.col2 * + col0 + col1 + - tab2.col1 / + col0 FROM tab2
----
-162
-1969
-2985

query I rowsort
SELECT ALL - col0 * col2 + col1 + + col2 * col0 AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT col2 / - col0 + - col2 FROM tab1 WHERE NOT NULL NOT IN ( + col0 )
----

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

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

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( + col0 ) IN ( col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

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

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

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT ( col2 ) NOT BETWEEN ( col2 ) AND NULL
----

query I rowsort
SELECT tab0.col1 - + tab0.col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-25
SELECT - col1 DIV - col2 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-25
SELECT - col1 / - col2 FROM tab0 cor0
----
1
2
97

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

query I rowsort
SELECT DISTINCT - tab0.col0 + - col2 * col1 * + col0 FROM tab0
----
-3430
-664207
-68136

query I rowsort
SELECT + col2 * - col0 * col0 + col2 AS col1 FROM tab1
----
-233415
-432
-614304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col1 + col0 * - col2 + - col2 * + tab1.col0 col2 FROM tab1
----
-15347
-298
-7286

query I rowsort
SELECT DISTINCT col2 + col0 + - col0 AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL tab0.col2 + - tab0.col2 + col0 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT - col1 * col0 * + col2 + col0 + col2 AS col2 FROM tab0
----
-3359
-663947
-68055

query I rowsort
SELECT ALL col1 * col2 + + col1 * + col1 * col2 FROM tab2 AS cor0
----
11628
26784
92040

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

query I rowsort
SELECT DISTINCT col2 + col1 * col0 * col0 FROM tab0 AS cor0
----
118826
49569
720893

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-39
SELECT + col1 DIV - col0 + + col2 * col0 + + col0 FROM tab0 AS cor0
----
68
7386
813

skipif mysql # not compatible
query I rowsort label-39
SELECT + col1 / - col0 + + col2 * col0 + + col0 FROM tab0 AS cor0
----
68
7386
813

query I rowsort
SELECT + - cor0.col1 * cor0.col2 * col0 + col2 + + col0 * col2 AS col0 FROM tab2 AS cor0
----
-117598
-47994
-5643

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-46
SELECT col1 DIV - col0 + - col1 + col0 AS col2 FROM tab1 AS cor0
----
-31
54
67

skipif mysql # not compatible
query I rowsort label-46
SELECT col1 / - col0 + - col1 + col0 AS col2 FROM tab1 AS cor0
----
-31
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + + col0 * cor0.col0 col1 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT 46 * col1 FROM tab0
----
3956
4186
4462

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

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

query I rowsort
SELECT + 47 * col2 - 59 AS col0 FROM tab1 AS cor0
----
2479
2620
4453

query I rowsort
SELECT - 27 + - col0 * cor0.col2 * - col1 FROM tab2 AS cor0
----
119625
51007
5832

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL + col1 - cor0.col1 * + 65 AS col2 FROM tab0 AS cor0
----
-5504
-5824
-6208

query I rowsort
SELECT ALL - col2 * - 30 AS col0 FROM tab0 cor0
----
2460
30
990

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 * col0 + - col1 col1 FROM tab0
----
2002
3333
8097

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

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

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

query I rowsort
SELECT DISTINCT - col0 + - col2 * - col1 * - tab2.col1 FROM tab2
----
-11061
-25954
-90584

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-66
SELECT DISTINCT col2 * col2 + col0 DIV + col2 AS col1 FROM tab1
----
2916
3250
9216

skipif mysql # not compatible
query I rowsort label-66
SELECT DISTINCT col2 * col2 + col0 / + col2 AS col1 FROM tab1
----
2916
3250
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col1 * col0 * tab0.col0 col1 FROM tab0
----
118728
49450
720720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + tab2.col0 * - col1 col0 FROM tab2
----
-1264
-210
-4524

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

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

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col2 NOT IN ( col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

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

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

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

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

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

query I rowsort
SELECT DISTINCT col0 + - 27 AS col1 FROM tab0 AS cor0
----
-3
62
8

query I rowsort
SELECT col2 * + 67 FROM tab1 AS cor0
----
3618
3819
6432

onlyif mysql # use DIV operator for integer division
query I rowsort label-77
SELECT - col2 + col1 * + 65 * col0 + + col0 DIV - 34 col1 FROM tab2 AS cor0
----
14078
299102
87255

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-77
SELECT - col2 + col1 * + 65 * col0 + + col0 / - 34 col1 FROM tab2 AS cor0
----
14078
299102
87255

query I rowsort
SELECT ALL + col2 * ( + cor0.col2 ) * + col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL - - cor0.col1 * cor0.col0 + col1 + 59 FROM tab1 AS cor0
----
1112
163
709

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

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

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

query I rowsort
SELECT + cor0.col1 * ( - col1 * - 87 + 52 ) FROM tab1 AS cor0
----
15379
60164
9220

query I rowsort
SELECT ALL + 10 + col2 FROM tab0 AS cor0
----
11
43
92

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

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

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

query I rowsort
SELECT ALL - col1 + - 45 * 68 FROM tab0
----
-3146
-3151
-3157

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

query I rowsort
SELECT 31 + - cor0.col2 * 31 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d8660155f0fd9d28a799fb7a35596b0f

query I rowsort
SELECT ALL + ( - cor0.col2 ) * + col1 * col2 - col0 FROM tab0 cor0
----
-132
-611973
-93678

query I rowsort
SELECT DISTINCT - + col0 + + col2 * 8 FROM tab2 AS cor0
----
130
209
225

onlyif mysql # use DIV operator for integer division
query I rowsort label-92
SELECT DISTINCT + 67 + - col1 DIV ( - col0 ) AS col0 FROM tab2 AS cor0
----
67
71

skipif mysql # not compatible
query I rowsort label-92
SELECT DISTINCT + 67 + - col1 / ( - col0 ) AS col0 FROM tab2 AS cor0
----
67
71

query I rowsort
SELECT 5 + col2 * + col1 * col1 AS col0 FROM tab0 cor0
----
244073
679047
9414

onlyif mysql # use DIV operator for integer division
query I rowsort label-94
SELECT - col2 DIV col2 + + 94 * col0 AS col0 FROM tab0 AS cor0
----
2255
3289
8365

skipif mysql # not compatible
query I rowsort label-94
SELECT - col2 / col2 + + 94 * col0 AS col0 FROM tab0 AS cor0
----
2255
3289
8365

query I rowsort
SELECT + 74 * cor0.col2 AS col2 FROM tab0 AS cor0
----
2442
6068
74

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

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

query I rowsort
SELECT DISTINCT - + col1 * 76 AS col2 FROM tab1 AS cor0
----
-1976
-760
-988

query I rowsort
SELECT + cor0.col2 + + col2 * col1 * col2 FROM tab2 AS cor0
----
22626
24586
39910

onlyif mysql # use DIV operator for integer division
query I rowsort label-100
SELECT col0 DIV 32 + col1 + - col0 * + col0 FROM tab2 AS cor0
----
-18
-6023
-6222

skipif mysql # not compatible
query I rowsort label-100
SELECT col0 / 32 + col1 + - col0 * + col0 FROM tab2 AS cor0
----
-18
-6023
-6222

query I rowsort
SELECT + cor0.col2 + - 94 * - col1 FROM tab2 AS cor0
----
1636
2941
5572

query I rowsort
SELECT 34 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT ALL - col1 * 72 AS col2 FROM tab2 AS cor0
----
-1224
-2232
-4248

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

query I rowsort
SELECT ALL - col0 + + 5 + 14 AS col0 FROM tab2 AS cor0
----
-59
-60
12

query I rowsort
SELECT DISTINCT - col1 * + 67 - col0 AS col1 FROM tab2 AS cor0
----
-1218
-2084
-4031

query I rowsort
SELECT 20 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT - tab0.col0 + - tab0.col1 * 54 * - ( + col0 + - col2 ) FROM tab0
----
-41820
178057
34309

query I rowsort
SELECT DISTINCT 90 * + col2 + - col2 + col2 * + col0 AS col1 FROM tab1
----
16224
4968
8721

onlyif mysql # use DIV operator for integer division
query I rowsort label-110
SELECT DISTINCT + 19 DIV - col0 + + col1 FROM tab2
----
17
29
59

skipif mysql # not compatible
query I rowsort label-110
SELECT DISTINCT + 19 / - col0 + + col1 FROM tab2
----
17
29
59

query I rowsort
SELECT col2 + - col0 + 82 * col1 FROM tab0
----
7061
7455
7920

query I rowsort
SELECT - col0 * 73 * col1 FROM tab2
----
-15841
-335946
-98039

query I rowsort
SELECT col1 + + 41 + - 67 AS col0 FROM tab0 AS cor0
----
60
65
71

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

query I rowsort
SELECT col1 + - 86 * + col0 AS col0 FROM tab0
----
-1978
-2913
-7563

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-117
SELECT DISTINCT + 50 DIV col0 + col1 FROM tab2 AS cor0
----
17
38
59

skipif mysql # not compatible
query I rowsort label-117
SELECT DISTINCT + 50 / col0 + col1 FROM tab2 AS cor0
----
17
38
59

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

query I rowsort
SELECT DISTINCT - + col1 * + 18 + - col2 * - col0 AS col2 FROM tab1 AS cor0
----
-306
3468
7446

query I rowsort
SELECT ( 48 ) * cor0.col2 AS col1 FROM tab0 AS cor0
----
1584
3936
48

query I rowsort
SELECT + - 39 AS col1 FROM tab2, tab0 cor0, tab0, tab1 AS cor1
----
81 values hashing to fe3460a5258986a2d83e1ea75c1e275e

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

query I rowsort
SELECT ALL ( - col0 ) + + 23 AS col1 FROM tab1 AS cor0
----
-41
-57
20

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

query I rowsort
SELECT ALL ( col1 ) + 89 * - col0 AS col0 FROM tab2
----
-592
-6883
-7014

query I rowsort
SELECT - cor0.col1 - + col1 * - 56 FROM tab0 AS cor0
----
4730
5005
5335

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

query I rowsort
SELECT - col1 + - col1 * + col0 - col1 * col1 AS col2 FROM tab1 cor0
----
-1222
-750
-780

query I rowsort
SELECT ALL col1 + cor0.col1 AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + + 93 * + col1 + - col1 FROM tab0 AS cor0
----
7912
8372
8924

query I rowsort
SELECT 43 * - cor0.col2 FROM tab1 AS cor0
----
-2322
-2451
-4128

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

query I rowsort
SELECT col2 * + col2 * col2 - + ( - col0 ) FROM tab0 AS cor0
----
35961
36
551457

query I rowsort
SELECT ALL - - ( 4 ) + + cor0.col0 FROM tab0 cor0
----
28
39
93

query I rowsort
SELECT 90 + 96 FROM tab0 AS cor0
----
186
186
186

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

query I rowsort
SELECT - - 52 + + col2 FROM tab0 AS cor0
----
134
53
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-138
SELECT + 31 + + col1 DIV col0 FROM tab1 AS cor0
----
31
31
39

skipif mysql # not compatible
query I rowsort label-138
SELECT + 31 + + col1 / col0 FROM tab1 AS cor0
----
31
31
39

query I rowsort
SELECT + 66 * + 22 FROM tab0
----
1452
1452
1452

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( + col2 + + col1 AS REAL ) * - CAST ( + col1 AS INTEGER ) FROM tab0
----
-10234
-15743
-9506

query I rowsort
SELECT DISTINCT + col0 * - 77 AS col1 FROM tab2
----
-539
-6006
-6083

onlyif mysql # use DIV operator for integer division
query I rowsort label-142
SELECT ALL + - cor1.col2 DIV - ( + cor1.col1 ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 1cd643253f19b663914c5dbb8be19829

skipif mysql # not compatible
query I rowsort label-142
SELECT ALL + - cor1.col2 / - ( + cor1.col1 ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 1cd643253f19b663914c5dbb8be19829

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 col0 FROM tab2, tab0 AS cor0
----
-24
-35
-89

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

query I rowsort
SELECT + tab2.col1 * ( tab2.col1 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 4a2f25e7025075a0ce048be425c35957

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

query I rowsort
SELECT DISTINCT - col1 + + col2 + - col0 AS col2 FROM tab1
----
-17
25
3

query I rowsort
SELECT - col1 * 81 AS col1 FROM tab0
----
-6966
-7371
-7857

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

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

query I rowsort
SELECT + col1 - ( col2 ) * + col0 * + tab2.col2 FROM tab2
----
-114059
-5072
-52669

query I rowsort
SELECT DISTINCT + ( + col0 * - tab1.col1 ) + + col2 - + 39 AS col0 FROM tab1
----
-622
-63
-983

query I rowsort
SELECT 0 * col1 - - tab2.col1 AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT col0 + 58 + + col1 FROM tab2
----
154
195
96

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

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

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

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

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

query I rowsort
SELECT DISTINCT 68 + + 97 AS col2 FROM tab0, tab1 cor0, tab1 AS cor1
----
165

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

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

query I rowsort
SELECT + tab2.col2 * - ( col0 * col0 ) FROM tab2
----
-1323
-158184
-237158

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

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

query I rowsort
SELECT 25 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 68fc0eecd4f434589f3ec576bbd0c540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 ) + + col2 col0 FROM tab1 AS cor0
----
109
67
80

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

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

query I rowsort
SELECT DISTINCT - + col2 * + col1 + + col2 + + col0 FROM tab1 AS cor0
----
-1072
-1347
-449

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col0 * - ( - 58 ) + + col2 col1 FROM tab1 cor0
----
237625
371296
576

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

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

skipif mysql # not compatible
query I rowsort label-172
SELECT + 39 / + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

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

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

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

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

query I rowsort
SELECT ALL - + col1 + col2 + col1 * cor0.col2 FROM tab0 cor0
----
1
2785
7453

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

query I rowsort
SELECT ALL - 48 * + col1 + - col2 FROM tab0 cor0
----
-4161
-4450
-4657

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + 41 * ( col1 ) col0 FROM tab1 cor0
----
26240
3198
42640

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

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

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-185
SELECT DISTINCT + - cor0.col1 + 99 / col1 AS col2 FROM tab0 AS cor0
----
-85
-90
-96

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * + cor0.col0 col2 FROM tab2 AS cor0
----
-49
-6084
-6241

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

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

query I rowsort
SELECT DISTINCT - ( + 23 ) * - cor0.col2 - + tab0.col0 FROM tab0, tab0 cor0
----
9 values hashing to 972106a010a0e570a062f5e4c8b185c2

query I rowsort
SELECT DISTINCT col0 * + ( cor0.col0 + ( 55 ) ) FROM tab2 AS cor0
----
10374
10586
434

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

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

query I rowsort
SELECT ALL + + col0 * col0 * - col0 FROM tab0 cor0
----
-13824
-42875
-704969

query I rowsort
SELECT ALL - + 22 * 38 FROM tab2 AS cor0
----
-836
-836
-836

onlyif mysql # use DIV operator for integer division
query I rowsort label-195
SELECT DISTINCT + + CAST( - col2 AS SIGNED ) DIV + col1 AS col0 FROM tab2 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-195
SELECT DISTINCT + + CAST ( - col2 AS INTEGER ) / + col1 AS col0 FROM tab2 AS cor0
----
-2
0

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

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

query I rowsort
SELECT - - 27 * col0 AS col0 FROM tab2 cor0
----
189
2106
2133

onlyif mysql # use DIV operator for integer division
query I rowsort label-198
SELECT ALL - ( - cor0.col2 ) DIV col0 - ( + ( - col1 ) * + cor0.col0 ) FROM tab0 AS cor0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort label-198
SELECT ALL - ( - cor0.col2 ) / col0 - ( + ( - col1 ) * + cor0.col0 ) FROM tab0 AS cor0
----
2065
3395
8099

query I rowsort
SELECT col1 * + 4 + col0 FROM tab2 AS cor0
----
131
147
314

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

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

query I rowsort
SELECT DISTINCT + - 86 + + col2 AS col0 FROM tab0 AS cor0
----
-4
-53
-85

query I rowsort
SELECT - + 16 + 72 * col1 FROM tab2 AS cor0
----
1208
2216
4232

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 65 * + ( col2 ) col0 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT + col1 - 95 AS col2 FROM tab1
----
-69
-82
-85

query I rowsort
SELECT DISTINCT tab2.col2 + + 6 AS col0 FROM tab2
----
32
33
44

query I rowsort
SELECT DISTINCT 83 + - 64 FROM tab0 cor0
----
19

query I rowsort
SELECT - + 17 FROM tab1, tab1 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to c2265365b5649c888846aefc3ede9a69

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-210
SELECT DISTINCT + cor0.col1 * col1 DIV + col0 AS col2 FROM tab2 AS cor0
----
137
3
44

skipif mysql # not compatible
query I rowsort label-210
SELECT DISTINCT + cor0.col1 * col1 / + col0 AS col2 FROM tab2 AS cor0
----
137
3
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-211
SELECT DISTINCT + tab0.col0 * tab0.col2 + + 54 * col0 DIV - col2 FROM tab0
----
-1855
7240
753

skipif mysql # not compatible
query I rowsort label-211
SELECT DISTINCT + tab0.col0 * tab0.col2 + + 54 * col0 / - col2 FROM tab0
----
-1855
7240
753

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 * - 67 ) + tab1.col2 col2 FROM tab1
----
-147
-4231
-5264

query I rowsort
SELECT col1 * - 24 + 71 FROM tab2
----
-1345
-337
-673

onlyif mysql # use DIV operator for integer division
query I rowsort label-215
SELECT col0 * + col1 + - tab1.col2 DIV - col1 AS col2 FROM tab1
----
1047
645
80

skipif mysql # not compatible
query I rowsort label-215
SELECT col0 * + col1 + - tab1.col2 / - col1 AS col2 FROM tab1
----
1047
645
80

query I rowsort
SELECT ALL + 77 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

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

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

query I rowsort
SELECT - - col0 * 66 AS col0 FROM tab1 cor0
----
198
4224
5280

query I rowsort
SELECT DISTINCT - col0 + 90 * + col1 FROM tab2 AS cor0
----
1451
2783
5232

query I rowsort
SELECT DISTINCT cor0.col1 * ( col2 + col1 ) * ( + col2 ) AS col0 FROM tab1 AS cor0
----
112320
136032
38190

onlyif mysql # use DIV operator for integer division
query I rowsort label-221
SELECT DISTINCT col0 DIV 15 + - 55 AS col1 FROM tab2 cor0
----
-50
-55

skipif mysql # not compatible
query I rowsort label-221
SELECT DISTINCT col0 / 15 + - 55 AS col1 FROM tab2 cor0
----
-50
-55

query I rowsort
SELECT DISTINCT + + col0 * col2 * - ( + col2 + - col1 ) AS col2 FROM tab2 AS cor0
----
-63042
66924
756

query I rowsort
SELECT ALL - 85 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8ebc8ffafb1517ea04e3a6fc4059d88a

query I rowsort
SELECT ALL + col2 * - col0 + - col2 * + col2 AS col2 FROM tab1 AS cor0
----
-16896
-3078
-6897

onlyif mysql # use DIV operator for integer division
query I rowsort label-225
SELECT ALL - - col0 DIV - col2 + - col2 - col2 FROM tab1 AS cor0
----
-108
-115
-192

skipif mysql # not compatible
query I rowsort label-225
SELECT ALL - - col0 / - col2 + - col2 - col2 FROM tab1 AS cor0
----
-108
-115
-192

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

query I rowsort
SELECT ALL - - 4 * col2 + - col1 AS col2 FROM tab1 AS cor0
----
190
218
371

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

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

query I rowsort
SELECT col2 - + 75 FROM tab1 AS cor0
----
-18
-21
21

query I rowsort
SELECT ALL - 86 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9ac806793c03d3a6b5e3a3029d20e4da

query I rowsort
SELECT cor1.col0 * + cor1.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e1120e7b687b32270ef70393236e7341

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

query I rowsort
SELECT 15 + + col1 AS col0 FROM tab2 cor0
----
32
46
74

query I rowsort
SELECT ( - col0 + col2 ) * ( - col2 ) * - col1 AS col2 FROM tab0
----
-3298
-52234
25542

query I rowsort
SELECT DISTINCT - - col0 * col0 * col0 + col0 * - col2 AS col2 FROM tab0 AS cor0
----
13032
42840
697671

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 + col0 * col2 col2 FROM tab2
----
2100
261
3074

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

query I rowsort
SELECT DISTINCT 94 + - col0 * + col2 AS col0 FROM tab1 cor0
----
-3554
-68
-7586

query I rowsort
SELECT + 16 * col1 + - tab0.col1 * ( - 13 ) AS col0 FROM tab0
----
2494
2639
2813

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

query I rowsort
SELECT ALL 13 * - tab0.col1 FROM tab0
----
-1118
-1183
-1261

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-244
SELECT ALL - col1 DIV 51 AS col1 FROM tab2
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-244
SELECT ALL - col1 / 51 AS col1 FROM tab2
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 + col2 col1 FROM tab2 AS cor0
----
105
93
94

query I rowsort
SELECT + ( 73 ) FROM tab2 AS cor0
----
73
73
73

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

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

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

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

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

query I rowsort
SELECT 15 + col0 * col2 + 73 * cor0.col2 AS col1 FROM tab2 AS cor0
----
2175
3941
5791

onlyif mysql # use DIV operator for integer division
query I rowsort label-252
SELECT col1 * + ( + col0 ) * 26 + + col2 DIV col1 AS col0 FROM tab2 AS cor0
----
119652
34920
5642

skipif mysql # not compatible
query I rowsort label-252
SELECT col1 * + ( + col0 ) * 26 + + col2 / col1 AS col0 FROM tab2 AS cor0
----
119652
34920
5642

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

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

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

query I rowsort
SELECT ALL + - col0 + col2 - col0 * + 86 FROM tab0 AS cor0
----
-2055
-3044
-7661

query I rowsort
SELECT DISTINCT - 53 * - col2 FROM tab0 AS cor0
----
1749
4346
53

query I rowsort
SELECT - 44 * 73 FROM tab2 AS cor0
----
-3212
-3212
-3212

onlyif mysql # use DIV operator for integer division
query I rowsort label-258
SELECT col0 DIV + col2 + cor0.col2 * + col2 - + 37 FROM tab0 AS cor0
----
-1
1052
6688

skipif mysql # not compatible
query I rowsort label-258
SELECT col0 / + col2 + cor0.col2 * + col2 - + 37 FROM tab0 AS cor0
----
-1
1052
6688

onlyif mysql # use DIV operator for integer division
query I rowsort label-259
SELECT DISTINCT - - col1 DIV - ( col0 ) FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-259
SELECT DISTINCT - - col1 / - ( col0 ) FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT 71 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT ( ( + col2 ) ) + + 69 AS col1 FROM tab0
----
102
151
70

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( - col2 AS REAL ) col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - 60 + + col2 AS col0 FROM tab2
----
-22
-33
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-265
SELECT ALL - CAST( - 5 AS SIGNED ) * tab1.col1 + col2 FROM tab1
----
107
161
184

skipif mysql # not compatible
query I rowsort label-265
SELECT ALL - CAST ( - 5 AS INTEGER ) * tab1.col1 + col2 FROM tab1
----
107
161
184

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

skipif mysql # not compatible
query I rowsort label-266
SELECT - - 31 / col0 + cor0.col2 FROM tab0 AS cor0
----
1
34
82

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-268
SELECT ALL - 24 DIV - tab0.col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-268
SELECT ALL - 24 / - tab0.col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-269
SELECT ALL col0 DIV - 4 AS col1 FROM tab2 AS cor0
----
-1
-19
-19

skipif mysql # not compatible
query I rowsort label-269
SELECT ALL col0 / - 4 AS col1 FROM tab2 AS cor0
----
-1
-19
-19

onlyif mysql # use DIV operator for integer division
query I rowsort label-270
SELECT ALL - - col2 + - col2 DIV col1 FROM tab2 cor0
----
26
27
36

skipif mysql # not compatible
query I rowsort label-270
SELECT ALL - - col2 + - col2 / col1 FROM tab2 cor0
----
26
27
36

query I rowsort
SELECT ALL - col1 + + cor0.col1 * - col2 * - col1 AS col1 FROM tab1 AS cor0
----
16211
36478
5690

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-273
SELECT - col1 DIV 24 FROM tab0 AS cor0
----
-3
-3
-4

skipif mysql # not compatible
query I rowsort label-273
SELECT - col1 / 24 FROM tab0 AS cor0
----
-3
-3
-4

query I rowsort
SELECT DISTINCT - col1 * + col1 * 39 AS col1 FROM tab0 AS cor0
----
-288444
-322959
-366951

onlyif mysql # use DIV operator for integer division
query I rowsort label-275
SELECT ALL - cor0.col0 DIV + col2 + + col1 + cor0.col0 FROM tab1 AS cor0
----
29
73
93

skipif mysql # not compatible
query I rowsort label-275
SELECT ALL - cor0.col0 / + col2 + + col1 + cor0.col0 FROM tab1 AS cor0
----
29
73
93

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

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

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

query I rowsort
SELECT DISTINCT + col2 * 94 AS col0 FROM tab2 cor0
----
2444
2538
3572

onlyif mysql # use DIV operator for integer division
query I rowsort label-279
SELECT DISTINCT + + col1 * col0 DIV col2 FROM tab0 AS cor0
----
3395
62
98

skipif mysql # not compatible
query I rowsort label-279
SELECT DISTINCT + + col1 * col0 / col2 FROM tab0 AS cor0
----
3395
62
98

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

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

query I rowsort
SELECT tab2.col0 * col2 * 60 + + col1 * + col1 AS col1 FROM tab2
----
12301
125161
180409

onlyif mysql # use DIV operator for integer division
query I rowsort label-282
SELECT - col1 DIV + ( - col0 ) + + tab1.col0 FROM tab1
----
11
64
80

skipif mysql # not compatible
query I rowsort label-282
SELECT - col1 / + ( - col0 ) + + tab1.col0 FROM tab1
----
11
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-283
SELECT DISTINCT - col1 DIV tab0.col2 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-283
SELECT DISTINCT - col1 / tab0.col2 FROM tab0
----
-1
-2
-97

query I rowsort
SELECT + cor0.col1 + col1 * ( + col1 ) FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + col2 * cor0.col1 + 19 AS col2 FROM tab1 AS cor0
----
1267
1423
589

query I rowsort
SELECT DISTINCT + col1 + 57 FROM tab2 AS cor0
----
116
74
88

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

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

query I rowsort
SELECT ALL col1 + col0 * + col2 * - ( + col2 + + col1 * + col1 ) FROM tab2 AS cor0
----
-186701
-7112137
-981637

onlyif mysql # use DIV operator for integer division
query I rowsort label-290
SELECT ALL + 19 DIV col1 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-290
SELECT ALL + 19 / col1 FROM tab2 cor0
----
0
0
1

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 21 + 75 col2 FROM tab0 AS cor0
----
96

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

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

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

query I rowsort
SELECT ALL + + 37 + + cor0.col2 * + col2 * 48 + ( - col1 ) * - col2 AS col0 FROM tab1 AS cor0
----
141409
156559
443653

query I rowsort
SELECT ALL + 15 * + col2 AS col2 FROM tab1 AS cor0
----
1440
810
855

query I rowsort
SELECT + + cor0.col0 * 37 FROM tab2 AS cor0
----
259
2886
2923

query I rowsort
SELECT DISTINCT - 16 * col1 AS col1 FROM tab1 AS cor0
----
-160
-208
-416

onlyif mysql # use DIV operator for integer division
query I rowsort label-300
SELECT ( 65 ) DIV - col0 AS col1 FROM tab0 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-300
SELECT ( 65 ) / - col0 AS col1 FROM tab0 cor0
----
-1
-2
0

query I rowsort
SELECT 77 * - col1 FROM tab1 AS cor0
----
-1001
-2002
-770

query I rowsort
SELECT + + 26 + - col2 * col1 FROM tab0 AS cor0
----
-2812
-71
-7436

query I rowsort
SELECT ALL + ( - col0 ) * + 61 + + col0 AS col2 FROM tab2 AS cor0
----
-420
-4680
-4740

query I rowsort
SELECT DISTINCT + 78 * col1 AS col2 FROM tab0 cor0
----
6708
7098
7566

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

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

query I rowsort
SELECT + - col1 * col1 + 78 AS col2 FROM tab2 AS cor0
----
-211
-3403
-883

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

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

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

query I rowsort
SELECT ALL + col2 + col2 * - col0 FROM tab1 AS cor0
----
-108
-3591
-7584

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col1 ) * col2 + + col1 col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - col1 * col1 * col0 - - col1 AS col0 FROM tab1 AS cor0
----
-13507
-2002
-6390

query I rowsort
SELECT DISTINCT + + cor0.col1 * + col0 + col1 * + col2 AS col2 FROM tab2 AS cor0
----
1054
1989
6136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-315
SELECT DISTINCT + col2 + - col1 * + ( + col2 * CAST( + 15 AS SIGNED ) ) FROM tab1 AS cor0
----
-18624
-21006
-8493

skipif mysql # not compatible
query I rowsort label-315
SELECT DISTINCT + col2 + - col1 * + ( + col2 * CAST ( + 15 AS INTEGER ) ) FROM tab1 AS cor0
----
-18624
-21006
-8493

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + ( col0 ) * col2 col0 FROM tab2 AS cor0
----
182
1950
2923

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

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

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

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

query I rowsort
SELECT ALL + - col2 + - col2 * - col1 * - col0 FROM tab1 AS cor0
----
-36537
-4266
-99936

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

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

query I rowsort
SELECT ALL + - cor0.col1 + - col1 + col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col2 + col2 col2 FROM tab0 AS cor0
----
253
37
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-328
SELECT ALL + tab1.col2 DIV tab1.col1 + col2 + + col2 FROM tab1
----
110
119
199

skipif mysql # not compatible
query I rowsort label-328
SELECT ALL + tab1.col2 / tab1.col1 + col2 + + col2 FROM tab1
----
110
119
199

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

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

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

query I rowsort
SELECT col2 * col1 FROM tab1 WHERE NULL > ( NULL )
----

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-336
SELECT DISTINCT col1 * - col0 + col1 DIV - col1 FROM tab2
----
-1344
-218
-4603

skipif mysql # not compatible
query I rowsort label-336
SELECT DISTINCT col1 * - col0 + col1 / - col1 FROM tab2
----
-1344
-218
-4603

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-340
SELECT + col1 + col1 DIV col1 AS col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-340
SELECT + col1 + col1 / col1 AS col1 FROM tab2 AS cor0
----
18
32
60

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

query I rowsort
SELECT DISTINCT col0 + - col2 * col0 * - col0 AS col0 FROM tab2 cor0
----
1330
158262
237237

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-344
SELECT + col0 + - col2 * col1 DIV col1 FROM tab0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-344
SELECT + col0 + - col2 * col1 / col1 FROM tab0
----
-9
34
7

query I rowsort
SELECT col2 * + col1 + col1 - col2 AS col1 FROM tab2 cor0
----
1567
625
841

onlyif mysql # use DIV operator for integer division
query I rowsort label-346
SELECT col1 DIV + col0 + + col1 * + col0 * col2 AS col0 FROM tab0 AS cor0
----
3397
664119
68115

skipif mysql # not compatible
query I rowsort label-346
SELECT col1 / + col0 + + col1 * + col0 * col2 AS col0 FROM tab0 AS cor0
----
3397
664119
68115

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

query I rowsort
SELECT ALL col0 + col2 - col1 FROM tab0 AS cor0
----
-29
-61
80

query III rowsort
SELECT ALL * FROM tab0 WHERE + col0 >= + col2
----
35
97
1
89
91
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 + + col0 * col2 col1 FROM tab1
----
-1242
3078
6432

query I rowsort
SELECT ALL col2 FROM tab1 WHERE NOT NULL > NULL
----

query I rowsort
SELECT tab0.col1 * tab0.col0 + + col2 * col2 FROM tab0
----
14823
3153
3396

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col1 * - tab0.col0 col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + col0 + col1 + + col0 * + col1 * + col1 AS col1 FROM tab2
----
22927
271655
6765

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-356
SELECT DISTINCT - col2 + tab0.col0 + col1 DIV tab0.col1 AS col2 FROM tab0
----
-8
35
8

skipif mysql # not compatible
query I rowsort label-356
SELECT DISTINCT - col2 + tab0.col0 + col1 / tab0.col1 AS col2 FROM tab0
----
-8
35
8

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - col0 + tab0.col1 * - col0 * - col2 col0 FROM tab0
----
3457
664120
68174

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

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

query I rowsort
SELECT DISTINCT col1 + col0 FROM tab0 WHERE col1 <= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-362
SELECT - col2 * tab2.col2 DIV - col0 + + col0 AS col2 FROM tab2
----
111
86
97

skipif mysql # not compatible
query I rowsort label-362
SELECT - col2 * tab2.col2 / - col0 + + col0 AS col2 FROM tab2
----
111
86
97

query I rowsort
SELECT ALL - tab0.col1 * col0 + col1 * tab0.col2 AS col0 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT DISTINCT + 74 + - col1 * ( ( cor0.col2 ) ) AS col2 FROM tab1 AS cor0
----
-1174
-1330
-496

query I rowsort
SELECT DISTINCT col2 * + col1 + + 6 FROM tab0 cor0
----
103
2844
7468

query I rowsort
SELECT + 76 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

onlyif mysql # use DIV operator for integer division
query I rowsort label-367
SELECT ALL + col1 * col1 + col2 DIV col2 AS col1 FROM tab0 cor0
----
7397
8282
9410

skipif mysql # not compatible
query I rowsort label-367
SELECT ALL + col1 * col1 + col2 / col2 AS col1 FROM tab0 cor0
----
7397
8282
9410

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

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

query I rowsort
SELECT ALL - col2 * - col0 + col1 * ( col0 ) AS col1 FROM tab1 AS cor0
----
240
4288
8720

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

query I rowsort
SELECT DISTINCT + - 63 * - col2 FROM tab0 AS cor0
----
2079
5166
63

query I rowsort
SELECT - ( - tab2.col0 ) + col0 FROM tab2
----
14
156
158

query I rowsort
SELECT ALL - col1 * 35 * col2 AS col2 FROM tab1 cor0
----
-19950
-43680
-49140

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

query I rowsort
SELECT DISTINCT + - col1 * - 59 FROM tab2 cor0
----
1003
1829
3481

query I rowsort
SELECT ALL - + col0 + - col2 + 86 * cor0.col2 FROM tab0 AS cor0
----
2781
50
6881

query I rowsort
SELECT 29 + col1 FROM tab1
----
39
42
55

query I rowsort
SELECT DISTINCT - 46 * - col1 FROM tab0
----
3956
4186
4462

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

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

query I rowsort
SELECT DISTINCT col0 * 44 AS col1 FROM tab1
----
132
2816
3520

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

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

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

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

query I rowsort
SELECT + col1 - 18 FROM tab0
----
68
73
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-387
SELECT ALL + tab2.col1 DIV - 3 + + 11 FROM tab2
----
-8
1
6

skipif mysql # not compatible
query I rowsort label-387
SELECT ALL + tab2.col1 / - 3 + + 11 FROM tab2
----
-8
1
6

query I rowsort
SELECT DISTINCT col0 * - ( 5 ) AS col1 FROM tab0
----
-120
-175
-445

onlyif mysql # use DIV operator for integer division
query I rowsort label-389
SELECT DISTINCT col1 DIV - ( 72 ) + tab1.col0 * ( + col1 ) + + col0 * + CAST( + col2 AS SIGNED ) AS col2 FROM tab1
----
240
4288
8720

skipif mysql # not compatible
query I rowsort label-389
SELECT DISTINCT col1 / - ( 72 ) + tab1.col0 * ( + col1 ) + + col0 * + CAST ( + col2 AS INTEGER ) AS col2 FROM tab1
----
240
4288
8720

query I rowsort
SELECT + 16 * 23 + - col2 FROM tab0
----
286
335
367

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

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

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

skipif mysql # not compatible
query I rowsort label-393
SELECT - col1 / 65 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - 60 + - col0 FROM tab1
----
-124
-140
-63

query I rowsort
SELECT ( 86 ) * - cor0.col0 FROM tab0 cor0
----
-2064
-3010
-7654

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

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

query I rowsort
SELECT - col0 + + col1 * ( + 73 ) * col1 AS col0 FROM tab0 cor0
----
539884
604424
686822

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

query I rowsort
SELECT - ( col2 ) + col2 * - 99 FROM tab2
----
-2600
-2700
-3800

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

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

query I rowsort
SELECT DISTINCT - col1 * col2 + col1 - 59 AS col0 FROM tab1 AS cor0
----
-1294
-1437
-619

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 + cor0.col2 col2 FROM tab0 cor0
----
119
173
98

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-405
SELECT + 74 DIV col1 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-405
SELECT + 74 / col1 FROM tab2 AS cor0
----
1
2
4

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-407
SELECT 11 + - cor0.col1 DIV - ( cor0.col2 ) AS col2 FROM tab0 cor0
----
108
12
13

skipif mysql # not compatible
query I rowsort label-407
SELECT 11 + - cor0.col1 / - ( cor0.col2 ) AS col2 FROM tab0 cor0
----
108
12
13

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

query I rowsort
SELECT + col1 - 12 FROM tab2 AS cor0
----
19
47
5

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col0 + - CAST ( ( col0 ) AS REAL ) FROM tab2 AS cor0
----
-14
-156
-158

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

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

query I rowsort
SELECT - col2 * - col2 - + col2 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
14186
3927
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-413
SELECT col1 DIV - ( col0 ) - col2 AS col0 FROM tab1 AS cor0
----
-57
-62
-96

skipif mysql # not compatible
query I rowsort label-413
SELECT col1 / - ( col0 ) - col2 AS col0 FROM tab1 AS cor0
----
-57
-62
-96

query I rowsort
SELECT DISTINCT + col0 * + col0 + + ( col0 ) FROM tab0 AS cor0
----
1260
600
8010

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

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

query I rowsort
SELECT DISTINCT - col1 * 89 * + col1 + - col0 FROM tab0 AS cor0
----
-658268
-737098
-837436

query I rowsort
SELECT + + col0 + - ( 96 ) AS col2 FROM tab1 AS cor0
----
-16
-32
-93

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-421
SELECT - - 68 / col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT - 17 * col1 AS col1 FROM tab2 AS cor0
----
-1003
-289
-527

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

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

skipif mysql # not compatible
query I rowsort label-424
SELECT - CAST ( 48 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-48
-48
-48

query I rowsort
SELECT DISTINCT 84 * 89 FROM tab0 AS cor0
----
7476

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( ( - col0 ) ) + + cor0.col2 * cor0.col1 + - col2 col2 FROM tab2 AS cor0
----
1586
687
817

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

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

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

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

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

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

query I rowsort
SELECT + col0 * 14 + col0 * col0 AS col2 FROM tab0 AS cor0
----
1715
912
9167

query I rowsort
SELECT col0 + 33 FROM tab0 AS cor0
----
122
57
68

query I rowsort
SELECT ALL col0 + - col1 * + col1 AS col0 FROM tab2
----
-210
-3403
-954

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-435
SELECT ALL + col2 * CAST( 73 + + col2 AS SIGNED ) AS col2 FROM tab1
----
16224
6858
7410

skipif mysql # not compatible
query I rowsort label-435
SELECT ALL + col2 * CAST ( 73 + + col2 AS INTEGER ) AS col2 FROM tab1
----
16224
6858
7410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-436
SELECT - col0 + CAST( + 52 AS SIGNED ) + cor0.col0 * + col2 AS col1 FROM tab1 AS cor0
----
211
3636
7652

skipif mysql # not compatible
query I rowsort label-436
SELECT - col0 + CAST ( + 52 AS INTEGER ) + cor0.col0 * + col2 AS col1 FROM tab1 AS cor0
----
211
3636
7652

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

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

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

skipif mysql # not compatible
query I rowsort label-439
SELECT - tab1.col1 + col1 * col1 / ( col1 ) AS col0 FROM tab1
----
0
0
0

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

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

query I rowsort
SELECT DISTINCT 5 * col1 FROM tab0
----
430
455
485

query I rowsort
SELECT DISTINCT col1 + 85 * + col1 FROM tab1
----
1118
2236
860

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

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

query I rowsort
SELECT - 55 - + col1 AS col0 FROM tab0 cor0
----
-141
-146
-152

query I rowsort
SELECT + - ( + col0 ) * 70 FROM tab0 AS cor0
----
-1680
-2450
-6230

query I rowsort
SELECT 26 - + cor0.col2 AS col2 FROM tab1 AS cor0
----
-28
-31
-70

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

query I rowsort
SELECT + col0 * + col0 * + tab2.col2 AS col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT + 10 * col1 * - col1 FROM tab0
----
-73960
-82810
-94090

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

query I rowsort
SELECT 3 - + col0 AS col0 FROM tab0 cor0
----
-21
-32
-86

query I rowsort
SELECT col2 + ( 97 * + cor0.col0 ) FROM tab2 cor0
----
706
7592
7701

query I rowsort
SELECT DISTINCT - - cor0.col2 * 90 AS col2 FROM tab1 AS cor0
----
4860
5130
8640

query I rowsort
SELECT col2 * 66 AS col2 FROM tab2 AS cor0
----
1716
1782
2508

query I rowsort
SELECT + col2 * - 21 AS col1 FROM tab1 cor0
----
-1134
-1197
-2016

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

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

query I rowsort
SELECT + 61 * - col1 + col2 AS col0 FROM tab1 cor0
----
-1532
-553
-697

query I rowsort
SELECT - + ( - col1 ) + 13 FROM tab0 cor0
----
104
110
99

query I rowsort
SELECT + 8 * - col2 AS col1 FROM tab0 AS cor0
----
-264
-656
-8

query I rowsort
SELECT + + 89 AS col2 FROM tab2 AS cor0
----
89
89
89

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

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

query I rowsort
SELECT col1 + + 92 * col1 FROM tab2
----
1581
2883
5487

onlyif mysql # use DIV operator for integer division
query I rowsort label-466
SELECT + col0 - + 83 DIV - 13 AS col0 FROM tab2
----
13
84
85

skipif mysql # not compatible
query I rowsort label-466
SELECT + col0 - + 83 / - 13 AS col0 FROM tab2
----
13
84
85

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

query I rowsort
SELECT DISTINCT col2 * - col0 + col2 - col1 AS col1 FROM tab0 cor0
----
-131
-7307
-845

onlyif mysql # use DIV operator for integer division
query I rowsort label-469
SELECT DISTINCT - col1 + - col0 * col2 DIV col1 FROM tab0 AS cor0
----
-171
-95
-97

skipif mysql # not compatible
query I rowsort label-469
SELECT DISTINCT - col1 + - col0 * col2 / col1 FROM tab0 AS cor0
----
-171
-95
-97

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

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

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

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

query I rowsort
SELECT col1 * 7 AS col1 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT ALL + + col0 * - ( ( col0 ) + 55 ) FROM tab2 cor0
----
-10374
-10586
-434

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

skipif mysql # not compatible
query I rowsort label-475
SELECT ALL + CAST ( - 69 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-69
-69
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 16 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT ALL - + col1 * 25 AS col1 FROM tab1 AS cor0
----
-250
-325
-650

onlyif mysql # use DIV operator for integer division
query I rowsort label-478
SELECT ALL + 16 + col1 DIV - col2 FROM tab1 AS cor0
----
16
16
16

skipif mysql # not compatible
query I rowsort label-478
SELECT ALL + 16 + col1 / - col2 FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT DISTINCT + col1 + 6 AS col1 FROM tab0 AS cor0
----
103
92
97

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

query I rowsort
SELECT - - col0 + - 97 * col0 AS col0 FROM tab0 AS cor0
----
-2304
-3360
-8544

query I rowsort
SELECT DISTINCT - col0 + col2 * 90 + col2 AS col1 FROM tab0 AS cor0
----
2979
56
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 14 + - col2 col1 FROM tab1
----
-40
-43
-82

query I rowsort
SELECT ALL + + ( - col0 ) * - 55 FROM tab1 AS cor0
----
165
3520
4400

onlyif mysql # use DIV operator for integer division
query I rowsort label-485
SELECT ALL col1 DIV - col2 - 94 FROM tab1 cor0
----
-94
-94
-94

skipif mysql # not compatible
query I rowsort label-485
SELECT ALL col1 / - col2 - 94 FROM tab1 cor0
----
-94
-94
-94

query I rowsort
SELECT - col2 * - tab2.col2 * + 52 FROM tab2
----
35152
37908
75088

query I rowsort
SELECT + 98 + - col0 + - col0 FROM tab2
----
-58
-60
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * cor0.col2 + + col1 col2 FROM tab0 AS cor0
----
1175
6815
98

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

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

query I rowsort
SELECT cor0.col2 + 47 FROM tab2 cor0
----
73
74
85

query I rowsort
SELECT DISTINCT - col2 + 71 FROM tab2 AS cor0
----
33
44
45

query I rowsort
SELECT ALL col0 * 14 + - col2 - + col2 * - ( + col1 ) FROM tab2 AS cor0
----
1714
2600
908

query I rowsort
SELECT DISTINCT col0 + col1 * ( 67 ) FROM tab1
----
1745
734
951

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col0 * col2 + col1 col1 FROM tab1
----
-36470
-4186
-99827

query I rowsort
SELECT - + cor0.col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT + col1 * tab1.col2 * ( - col0 ) + - tab1.col2 - 36 AS col1 FROM tab1
----
-36573
-4302
-99972

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

query I rowsort
SELECT + col0 - ( - 82 ) * - col0 * col0 AS col1 FROM tab2 AS cor0
----
-4011
-498810
-511683

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 54 col1 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 81150d59d6c3fc48b4ef5a4a5495bc7a

query I rowsort
SELECT ALL col2 * 15 + - col1 FROM tab1
----
1427
784
845

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

query I rowsort
SELECT col1 + 52 AS col1 FROM tab2 cor0
----
111
69
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + ( + col0 ) * + col1 + + col1 * + 99 col1 FROM tab1
----
14807
4602
7390

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

query I rowsort
SELECT 5 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT - col0 * 57 * col1 + ( col2 ) FROM tab2
----
-12342
-262288
-76513

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

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

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

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

query I rowsort
SELECT + ( - ( col0 ) + + 10 ) AS col2 FROM tab2
----
-68
-69
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-513
SELECT 10 DIV + 11 + col2 AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-513
SELECT 10 / + 11 + col2 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT col0 * - col0 + tab2.col2 * + ( + 14 ) * col1 FROM tab2
----
11669
15392
2803

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-515
SELECT - CAST ( - col2 * col2 AS INTEGER ) + - col0 * - col1 col1 FROM tab0
----
14823
3153
3396

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * tab1.col0 * col1 col1 FROM tab1
----
13520
2028
6400

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

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

query I rowsort
SELECT ALL - 20 * col2 * col2 + + tab1.col2 FROM tab1
----
-184224
-58266
-64923

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

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

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

query I rowsort
SELECT - + 96 * - col2 AS col1 FROM tab1 AS cor0
----
5184
5472
9216

query I rowsort
SELECT 99 + + col0 * cor0.col0 FROM tab2 cor0
----
148
6183
6340

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 * - ( + col2 * + col2 ) col2 FROM tab1 AS cor0
----
-13307904
-26244
-58982400

onlyif mysql # use DIV operator for integer division
query I rowsort label-526
SELECT DISTINCT + col1 + col0 DIV - col2 FROM tab1 cor0
----
13
26
9

skipif mysql # not compatible
query I rowsort label-526
SELECT DISTINCT + col1 + col0 / - col2 FROM tab1 cor0
----
13
26
9

query I rowsort
SELECT ALL 31 + col1 AS col0 FROM tab0 AS cor0
----
117
122
128

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-529
SELECT - 56 DIV col1 + col0 * - 38 AS col2 FROM tab2
----
-267
-2964
-3005

skipif mysql # not compatible
query I rowsort label-529
SELECT - 56 / col1 + col0 * - 38 AS col2 FROM tab2
----
-267
-2964
-3005

query I rowsort
SELECT col2 * col0 + + col0 + ( col1 * - col0 ) FROM tab0 AS cor0
----
-1248
-3325
-712

query I rowsort
SELECT 55 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

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

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( col0 AS REAL ) FROM tab0
----
24
35
89

query I rowsort
SELECT - 17 * col2 - - col1 FROM tab0 AS cor0
----
-1303
-475
80

query I rowsort
SELECT - - ( 50 ) - col1 * + col1 AS col2 FROM tab0 AS cor0
----
-7346
-8231
-9359

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

query I rowsort
SELECT + col2 + col1 * - ( ( - cor0.col1 ) * 16 ) + 9 AS col2 FROM tab0 cor0
----
118378
132587
150554

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 63 * cor0.col0 + 60 + + col0 col0 FROM tab1 AS cor0
----
-126
-3908
-4900

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

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

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

query I rowsort
SELECT - + 30 * - col2 + + 83 AS col1 FROM tab1 AS cor0
----
1703
1793
2963

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

skipif mysql # not compatible
query I rowsort label-542
SELECT col1 + + cor0.col1 * - CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-7310
-8190
-9312

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

query I rowsort
SELECT + - col0 + + ( + col2 ) * - col1 FROM tab2 AS cor0
----
-1612
-725
-844

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

query I rowsort
SELECT ALL - - cor0.col0 * 92 FROM tab1 AS cor0
----
276
5888
7360

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + 92 * cor0.col1 col1 FROM tab1 AS cor0
----
58880
7176
95680

query I rowsort
SELECT ALL + 43 FROM tab2, tab1 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT ALL ( + 21 ) FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 4eecc28c48bfdf162a585f11d1dd0b6c

query I rowsort
SELECT - 63 FROM tab0, tab2 AS cor0
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

query I rowsort
SELECT ALL - - 99 + col1 FROM tab1 AS cor0
----
109
112
125

query I rowsort
SELECT DISTINCT + + cor0.col2 * + col2 * col0 + col2 * + ( + col1 ) * + col0 AS col2 FROM tab1 cor0
----
12960
244416
837120

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

query I rowsort
SELECT ALL - 21 + ( - col2 ) + cor0.col1 AS col2 FROM tab0 AS cor0
----
-12
32
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-557
SELECT DISTINCT + col0 * col1 DIV - col0 + + 79 AS col2 FROM tab1 cor0
----
53
66
69

skipif mysql # not compatible
query I rowsort label-557
SELECT DISTINCT + col0 * col1 / - col0 + + 79 AS col2 FROM tab1 cor0
----
53
66
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-558
SELECT DISTINCT + col0 * col1 * - cor0.col2 - CAST( col0 AS SIGNED ) * + col0 * ( col0 * cor0.col2 ) FROM tab1 AS cor0
----
-14978688
-49251840
-5670

skipif mysql # not compatible
query I rowsort label-558
SELECT DISTINCT + col0 * col1 * - cor0.col2 - CAST ( col0 AS INTEGER ) * + col0 * ( col0 * cor0.col2 ) FROM tab1 AS cor0
----
-14978688
-49251840
-5670

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

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

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

query I rowsort
SELECT + 1 - 77 AS col1 FROM tab2
----
-76
-76
-76

query I rowsort
SELECT col1 + 62 * col2 FROM tab1 AS cor0
----
3374
3544
5965

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-563
SELECT - CAST( 41 AS SIGNED ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

skipif mysql # not compatible
query I rowsort label-563
SELECT - CAST ( 41 AS INTEGER ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

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

skipif mysql # not compatible
query I rowsort label-564
SELECT DISTINCT + col0 * CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
49
6084
6241

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-566
SELECT - 15 + col1 + 2 DIV + col2 AS col1 FROM tab0 AS cor0
----
71
76
84

skipif mysql # not compatible
query I rowsort label-566
SELECT - 15 + col1 + 2 / + col2 AS col1 FROM tab0 AS cor0
----
71
76
84

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

query I rowsort
SELECT - cor0.col2 + + ( + 51 ) FROM tab0 cor0
----
-31
18
50

query I rowsort
SELECT ALL - col0 * 28 FROM tab1
----
-1792
-2240
-84

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

query I rowsort
SELECT - col1 + 27 FROM tab2 AS cor0
----
-32
-4
10

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

query I rowsort
SELECT + 17 + - col1 * + 20 * + cor0.col2 FROM tab1 AS cor0
----
-11383
-24943
-28063

query I rowsort
SELECT col1 * - 26 FROM tab0
----
-2236
-2366
-2522

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + ( + tab1.col2 ) + - col0 + CAST ( col2 AS REAL ) / col2 AS col1 FROM tab1
----
-6
17
52

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

query I rowsort
SELECT DISTINCT - + 88 + col1 FROM tab2 cor0
----
-29
-57
-71

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

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

query I rowsort
SELECT ALL + - 68 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query I rowsort
SELECT ALL 31 + + col1 * + 91 FROM tab0 AS cor0
----
7857
8312
8858

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

query I rowsort
SELECT tab2.col0 - - 99 FROM tab2
----
106
177
178

query I rowsort
SELECT - col1 - ( - col1 * col2 ) FROM tab1
----
1235
1378
560

query I rowsort
SELECT DISTINCT + + col2 + col2 * + 84 FROM tab2 AS cor0
----
2210
2295
3230

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

query I rowsort
SELECT DISTINCT col0 * col2 + + ( - col2 * - col2 ) FROM tab2 AS cor0
----
2704
4446
918

query I rowsort
SELECT ALL - col2 - 1 * 89 AS col0 FROM tab0 AS cor0
----
-122
-171
-90

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

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

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

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

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

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

query I rowsort
SELECT ( cor0.col2 ) + + col0 + + col0 AS col0 FROM tab0 AS cor0
----
260
71
81

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-596
SELECT ALL - + CAST( + cor0.col0 AS SIGNED ) FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-596
SELECT ALL - + CAST ( + cor0.col0 AS INTEGER ) FROM tab1 AS cor0
----
-3
-64
-80

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

query I rowsort
SELECT - - col2 + col0 * + col0 * col1 FROM tab2 AS cor0
----
106135
1546
358982

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-600
SELECT col2 * - 26 + - cor0.col2 DIV ( + col2 ) FROM tab0 AS cor0
----
-2133
-27
-859

skipif mysql # not compatible
query I rowsort label-600
SELECT col2 * - 26 + - cor0.col2 / ( + col2 ) FROM tab0 AS cor0
----
-2133
-27
-859

query I rowsort
SELECT DISTINCT 83 * + col2 * - col2 FROM tab2 AS cor0
----
-119852
-56108
-60507

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col0 + - col0 + 96 col1 FROM tab0 AS cor0
----
-720
-7291
26

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-607
SELECT DISTINCT col2 * 56 DIV - col1 AS col0 FROM tab2 AS cor0
----
-125
-24
-48

skipif mysql # not compatible
query I rowsort label-607
SELECT DISTINCT col2 * 56 / - col1 AS col0 FROM tab2 AS cor0
----
-125
-24
-48

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * ( + col1 ) + cor0.col0 * - col0 col0 FROM tab0 AS cor0
----
-10634
-16202
-7972

query I rowsort
SELECT 27 - cor0.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 79b1de8a47423e79cc3041c9232f9c88

query I rowsort
SELECT DISTINCT + ( - 13 ) + + col2 AS col2 FROM tab2 AS cor0
----
13
14
25

query I rowsort
SELECT DISTINCT + + 3 + + ( + col1 ) FROM tab1 AS cor0
----
13
16
29

query I rowsort
SELECT DISTINCT - 85 + 58 FROM tab2 AS cor0
----
-27

query I rowsort
SELECT ALL cor0.col2 * - 92 FROM tab1 AS cor0
----
-4968
-5244
-8832

query I rowsort
SELECT + 57 * col1 + col2 + cor0.col0 FROM tab2 AS cor0
----
1086
1801
3467

query I rowsort
SELECT 48 * col2 + + cor0.col0 + - col2 * col2 AS col2 FROM tab1 AS cor0
----
-321
-449
-4528

query I rowsort
SELECT ( 21 ) + col2 * + col1 + + col2 AS col2 FROM tab2
----
1581
705
885

query I rowsort
SELECT ALL - ( 85 ) + - col1 FROM tab0
----
-171
-176
-182

query I rowsort
SELECT DISTINCT - col0 + 51 AS col1 FROM tab1
----
-13
-29
48

query I rowsort
SELECT ALL ( - 95 ) + + col2 FROM tab2
----
-57
-68
-69

query I rowsort
SELECT + 87 * - ( + col2 ) FROM tab2
----
-2262
-2349
-3306

query I rowsort
SELECT col2 * + 37 + col2 * - col1 + - col2 FROM tab0
----
-1650
-4510
-61

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

query I rowsort
SELECT ( - col1 ) * + col1 * + col1 AS col2 FROM tab2
----
-205379
-29791
-4913

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

query I rowsort
SELECT ALL - col1 - col2 * ( cor0.col0 * col0 ) AS col1 FROM tab1 AS cor0
----
-233482
-512
-614413

query I rowsort
SELECT DISTINCT col1 * 42 + 15 FROM tab0 AS cor0
----
3627
3837
4089

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

query I rowsort
SELECT DISTINCT - + col1 * 16 AS col2 FROM tab1 AS cor0
----
-160
-208
-416

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

skipif mysql # not compatible
query I rowsort label-630
SELECT ALL + - col2 / - col2 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - - col0 * ( + 46 ) - col2 FROM tab0 cor0
----
1071
1609
4012

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

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

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

query I rowsort
SELECT DISTINCT - col0 + - col1 * - col1 + col0 FROM tab0
----
7396
8281
9409

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

query I rowsort
SELECT ALL col1 + - col2 + 74 FROM tab2
----
107
53
78

query I rowsort
SELECT col1 + col1 * 79 * tab1.col1 FROM tab1
----
13364
53430
7910

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

query I rowsort
SELECT tab0.col2 * 58 + col2 AS col0 FROM tab0
----
1947
4838
59

query I rowsort
SELECT - col0 * 41 FROM tab1 AS cor0
----
-123
-2624
-3280

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-642
SELECT - col1 + ( 84 ) DIV tab1.col0 AS col2 FROM tab1
----
-12
-9
2

skipif mysql # not compatible
query I rowsort label-642
SELECT - col1 + ( 84 ) / tab1.col0 AS col2 FROM tab1
----
-12
-9
2

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-643
SELECT ALL tab2.col1 / col1 col2 FROM tab2
----
1
1
1

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

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

query I rowsort
SELECT - 3 FROM tab2 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2, tab1 AS cor3
----
243 values hashing to f84ad243dff1ce0c39462086a2b7429c

query I rowsort
SELECT DISTINCT col2 * - col2 + 35 - col0 AS col1 FROM tab2
----
-1488
-701
-719

skipif mysql # not compatible
query I rowsort
SELECT ALL cor0.col1 * ( cor0.col2 ) + col1 * CAST ( - col0 AS REAL ) + col0 AS col1 FROM tab2 AS cor0
----
-2990
-618
627

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

query I rowsort
SELECT - col0 + 97 * col2 FROM tab1 AS cor0
----
5235
5465
9232

query I rowsort
SELECT cor0.col0 * 49 AS col1 FROM tab2 AS cor0
----
343
3822
3871

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

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

query I rowsort
SELECT + col2 + - 51 FROM tab1 AS cor0
----
3
45
6

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

query I rowsort
SELECT ALL - 55 * + col0 + col2 + - col2 AS col2 FROM tab2 AS cor0
----
-385
-4290
-4345

query I rowsort
SELECT + - 94 * col1 + col0 FROM tab1 AS cor0
----
-1142
-2441
-876

query I rowsort
SELECT col1 + 99 AS col0 FROM tab2 AS cor0
----
116
130
158

query I rowsort
SELECT + - col1 + col0 * 32 FROM tab2 AS cor0
----
193
2437
2511

query I rowsort
SELECT 36 + + 3 FROM tab2
----
39
39
39

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

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

query I rowsort
SELECT + + 11 AS col2 FROM tab0 AS cor0
----
11
11
11

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

query I rowsort
SELECT DISTINCT + col2 - col1 * 56 AS col0 FROM tab0 AS cor0
----
-4783
-5014
-5431

query I rowsort
SELECT DISTINCT - 73 + col1 FROM tab1 AS cor0
----
-47
-60
-63

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

query I rowsort
SELECT DISTINCT - cor0.col0 * - col1 + cor0.col0 - col2 AS col1 FROM tab0 AS cor0
----
2055
3429
8106

query I rowsort
SELECT DISTINCT + 81 - + col2 FROM tab1 cor0
----
-15
24
27

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-670
SELECT DISTINCT + col0 + - col0 DIV 58 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-670
SELECT DISTINCT + col0 + - col0 / 58 FROM tab2 AS cor0
----
7
77
78

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

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

skipif mysql # not compatible
query I rowsort label-672
SELECT col0 / - 46 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT + 79 - tab2.col0 AS col0 FROM tab2
----
0
1
72

query I rowsort
SELECT 46 + + col2 * col1 FROM tab2
----
1580
692
883

query I rowsort
SELECT cor0.col2 * + 61 FROM tab0 AS cor0
----
2013
5002
61

query I rowsort
SELECT ALL col0 + + 21 FROM tab1 cor0
----
101
24
85

query I rowsort
SELECT DISTINCT ( 50 ) * + col2 FROM tab0 AS cor0
----
1650
4100
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - 82 col0 FROM tab1
----
1066
2132
820

query I rowsort
SELECT ALL + col2 * col2 + + tab0.col2 FROM tab0
----
1122
2
6806

query I rowsort
SELECT + col0 + 5 FROM tab1
----
69
8
85

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col2 AS INTEGER ) + col0 * + CAST ( 78 AS REAL ) + tab2.col1 FROM tab2
----
604
6169
6217

onlyif mysql # use DIV operator for integer division
query I rowsort label-682
SELECT 27 DIV col1 + col2 * + col1 AS col2 FROM tab1
----
1250
1405
572

skipif mysql # not compatible
query I rowsort label-682
SELECT 27 / col1 + col2 * + col1 AS col2 FROM tab1
----
1250
1405
572

query I rowsort
SELECT 94 * col0 * col1 FROM tab1
----
60160
7332
97760

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

query I rowsort
SELECT ALL + 90 * + col0 FROM tab2 AS cor0
----
630
7020
7110

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-686
SELECT CAST ( + col0 AS INTEGER ) + col1 col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + - col2 + - col0 + col2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1327
572
695

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

query I rowsort
SELECT DISTINCT 53 + col1 FROM tab1 AS cor0
----
63
66
79

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

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

query I rowsort
SELECT ( 98 ) * - col0 + + cor0.col0 * - 5 AS col0 FROM tab0 AS cor0
----
-2472
-3605
-9167

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

skipif mysql # not compatible
query I rowsort label-692
SELECT DISTINCT - col1 / + col2 + col2 - 81 AS col2 FROM tab0 AS cor0
----
-177
-50
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-693
SELECT - + col1 + 60 DIV - col1 AS col0 FROM tab2 cor0
----
-20
-32
-60

skipif mysql # not compatible
query I rowsort label-693
SELECT - + col1 + 60 / - col1 AS col0 FROM tab2 cor0
----
-20
-32
-60

query I rowsort
SELECT ALL - 87 * col0 AS col0 FROM tab0 AS cor0
----
-2088
-3045
-7743

query I rowsort
SELECT DISTINCT col0 * - 45 + - col0 * - col2 FROM tab1 AS cor0
----
27
4080
768

query I rowsort
SELECT DISTINCT - 27 * col2 + + cor0.col2 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-380
108
832

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

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

query I rowsort
SELECT ALL 24 - ( col1 ) FROM tab0 AS cor0
----
-62
-67
-73

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

query I rowsort
SELECT + ( - ( col2 ) ) * - 34 + 29 FROM tab1
----
1865
1967
3293

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

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

query I rowsort
SELECT DISTINCT + cor0.col2 - 13 FROM tab0 AS cor0
----
-12
20
69

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

skipif mysql # not compatible
query I rowsort label-703
SELECT ALL - CAST ( + ( col2 ) AS INTEGER ) * tab0.col0 + 18 FROM tab0
----
-17
-7280
-774

query I rowsort
SELECT DISTINCT - 74 * col2 * col2 AS col1 FROM tab1
----
-215784
-240426
-681984

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

query I rowsort
SELECT col2 + + 83 AS col0 FROM tab0
----
116
165
84

query I rowsort
SELECT ALL col1 + + col1 * + 16 FROM tab1 cor0
----
170
221
442

query I rowsort
SELECT ALL 16 * cor0.col0 + cor2.col1 AS col0 FROM tab0, tab1 AS cor0, tab0 cor1, tab2, tab2 AS cor2
----
243 values hashing to 05b41059db9dd0796ecf8363b5367495

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-709
SELECT ALL - - col0 + + 15 / + col0 col1 FROM tab2 AS cor0
----
78
79
9

query I rowsort
SELECT col2 + 8 FROM tab2 cor0
----
34
35
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-711
SELECT DISTINCT + col1 + - 98 DIV - col2 FROM tab0 AS cor0
----
195
88
92

skipif mysql # not compatible
query I rowsort label-711
SELECT DISTINCT + col1 + - 98 / - col2 FROM tab0 AS cor0
----
195
88
92

query I rowsort
SELECT DISTINCT + + col1 + 56 FROM tab2 AS cor0
----
115
73
87

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

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

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

query I rowsort
SELECT ALL + cor0.col2 * - cor0.col1 + ( + cor0.col0 ) * + col0 FROM tab2 AS cor0
----
-788
4550
5595

onlyif mysql # use DIV operator for integer division
query I rowsort label-716
SELECT DISTINCT col0 DIV 31 FROM tab2 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-716
SELECT DISTINCT col0 / 31 FROM tab2 AS cor0
----
0
2

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

query I rowsort
SELECT ALL ( + ( - col0 - col0 ) ) * + 32 + col2 + + ( col2 ) FROM tab1 cor0
----
-3982
-4928
-84

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-721
SELECT ALL + 34 DIV - 9 FROM tab2
----
-3
-3
-3

skipif mysql # not compatible
query I rowsort label-721
SELECT ALL + 34 / - 9 FROM tab2
----
-3
-3
-3

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

query I rowsort
SELECT + - 74 * + ( col1 ) FROM tab1 AS cor0
----
-1924
-740
-962

query I rowsort
SELECT + ( + 45 ) * - cor0.col2 * 87 FROM tab0 AS cor0
----
-129195
-321030
-3915

query I rowsort
SELECT ALL 66 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

query I rowsort
SELECT ALL + + 39 * col2 AS col1 FROM tab1 AS cor0
----
2106
2223
3744

query I rowsort
SELECT col2 + - col2 + - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + 32 * + 70 FROM tab2, tab0 cor0, tab1 AS cor1
----
2240

query I rowsort
SELECT - tab1.col0 + + 41 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 5dd69c3b6ce358b56a6b95e3988936a6

query I rowsort
SELECT DISTINCT - + col2 + col1 + 89 AS col2 FROM tab0 AS cor0
----
142
185
98

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

query I rowsort
SELECT ALL - + 10 + + col1 * col0 * + col1 FROM tab1 AS cor0
----
13510
2018
6390

query I rowsort
SELECT - + col0 * ( + cor0.col2 ) + + col2 * col1 FROM tab1 AS cor0
----
-3078
-6432
1242

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

skipif mysql # not compatible
query I rowsort label-734
SELECT - col0 * + CAST ( col0 AS INTEGER ) + col0 * ( - col0 ) * col2 FROM tab0 cor0
----
-19584
-2450
-657443

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + + col0 * + 72 col0 FROM tab2 AS cor0
----
477
5590
5650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 + - ( ( - col0 ) * col2 ) col1 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 DISTINCT col2 * + col1 + ( - col1 ) FROM tab0
----
0
2752
7371

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

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

query I rowsort
SELECT DISTINCT - 31 + col2 AS col2 FROM tab1 cor0
----
23
26
65

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

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

query I rowsort
SELECT 7 * tab2.col1 * col0 AS col0 FROM tab2
----
1519
32214
9401

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

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

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

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

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

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

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

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

query I rowsort
SELECT + col0 + col0 + ( + col2 ) * col1 FROM tab1
----
1408
1410
698

query I rowsort
SELECT ALL - col2 * + ( 30 + col2 ) * - 32 AS col1 FROM tab2
----
46592
49248
82688

query I rowsort
SELECT - col1 * 80 AS col2 FROM tab1
----
-1040
-2080
-800

query I rowsort
SELECT - + col0 * cor0.col1 + 31 AS col0 FROM tab1 AS cor0
----
-1009
-47
-609

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-755
SELECT + ( - 44 ) * + col1 * + col1 + - col0 + - cor0.col1 DIV + cor0.col2 AS col0 FROM tab1 AS cor0
----
-29747
-4464
-7516

skipif mysql # not compatible
query I rowsort label-755
SELECT + ( - 44 ) * + col1 * + col1 + - col0 + - cor0.col1 / + cor0.col2 AS col0 FROM tab1 AS cor0
----
-29747
-4464
-7516

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

query I rowsort
SELECT - ( + col2 ) + - col1 + - cor0.col2 * col2 FROM tab1 AS cor0
----
-2996
-3316
-9325

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

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

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

query I rowsort
SELECT - col1 + col0 + - col1 AS col2 FROM tab1
----
-49
44
54

query I rowsort
SELECT + 23 - col2 FROM tab2
----
-15
-3
-4

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-763
SELECT + 45 * col0 * col2 + CAST( - col2 AS SIGNED ) FROM tab1
----
164103
345504
7236

skipif mysql # not compatible
query I rowsort label-763
SELECT + 45 * col0 * col2 + CAST ( - col2 AS INTEGER ) FROM tab1
----
164103
345504
7236

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-765
SELECT - ( col0 ) * - col2 - + 53 DIV col0 FROM tab1 AS cor0
----
145
3648
7680

skipif mysql # not compatible
query I rowsort label-765
SELECT - ( col0 ) * - col2 - + 53 / col0 FROM tab1 AS cor0
----
145
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 29 * col0 col2 FROM tab0 AS cor0
----
1015
2581
696

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

query I rowsort
SELECT ALL - + 63 + + col1 FROM tab1 AS cor0
----
-37
-50
-53

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

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

query I rowsort
SELECT - - col1 + 89 AS col1 FROM tab0 AS cor0
----
175
180
186

query I rowsort
SELECT DISTINCT 45 - tab1.col1 FROM tab1, tab0 AS cor0
----
19
32
35

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

query I rowsort
SELECT ALL col0 + 40 * cor0.col1 AS col1 FROM tab2 AS cor0
----
1247
2438
759

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

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

query I rowsort
SELECT DISTINCT + + col0 * - 49 + + col1 * + col0 AS col2 FROM tab0 AS cor0
----
1680
3738
888

onlyif mysql # use DIV operator for integer division
query I rowsort label-777
SELECT DISTINCT cor0.col2 + + 42 DIV - col0 FROM tab2 AS cor0
----
21
26
38

skipif mysql # not compatible
query I rowsort label-777
SELECT DISTINCT cor0.col2 + + 42 / - col0 FROM tab2 AS cor0
----
21
26
38

query I rowsort
SELECT ALL + cor0.col2 + 53 AS col0 FROM tab1 AS cor0
----
107
110
149

query I rowsort
SELECT ALL - col2 + + col2 * + cor0.col0 FROM tab1 AS cor0
----
108
3591
7584

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

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

query I rowsort
SELECT + cor0.col2 + - 4 AS col0 FROM tab0 AS cor0
----
-3
29
78

query I rowsort
SELECT - ( cor0.col0 ) * + col0 + - 18 * col2 + cor0.col1 FROM tab0 AS cor0
----
-1084
-1146
-9306

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

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

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

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

skipif mysql # not compatible
query I rowsort label-786
SELECT + col1 * - CAST ( NULL AS INTEGER ) * + 19 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) AS col2 FROM tab0, tab0 AS cor0
----
86
91
97

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

query I rowsort
SELECT DISTINCT + - 85 + col1 AS col0 FROM tab0 AS cor0
----
1
12
6

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

skipif mysql # not compatible
query I rowsort label-790
SELECT DISTINCT - - 4 * - cor0.col2 + col1 + 13 * - col1 * - CAST ( NULL AS REAL ) AS col0 FROM tab2 AS cor0
----
NULL

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-792
SELECT DISTINCT ( + col0 ) * col0 + cor0.col2 DIV col2 FROM tab0 AS cor0
----
1226
577
7922

skipif mysql # not compatible
query I rowsort label-792
SELECT DISTINCT ( + col0 ) * col0 + cor0.col2 / col2 FROM tab0 AS cor0
----
1226
577
7922

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

query I rowsort
SELECT DISTINCT 24 * col0 + col0 AS col0 FROM tab2 AS cor0
----
175
1950
1975

query I rowsort
SELECT DISTINCT + + 63 * + col0 FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT ALL - col1 + - col1 + col0 FROM tab0 cor0
----
-148
-159
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 18 * col0 + col0 col2 FROM tab2 AS cor0
----
133
1482
1501

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

skipif mysql # not compatible
query I rowsort label-798
SELECT ALL + col0 * + cor0.col2 + - CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT + 67 * - col2 + col0 * + 5 FROM tab2 AS cor0
----
-1352
-1774
-2151

onlyif mysql # use DIV operator for integer division
query I rowsort label-800
SELECT DISTINCT - 82 + - col0 DIV cor0.col2 FROM tab0 cor0
----
-117
-82
-83

skipif mysql # not compatible
query I rowsort label-800
SELECT DISTINCT - 82 + - col0 / cor0.col2 FROM tab0 cor0
----
-117
-82
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-801
SELECT ALL col2 * 29 + + col2 * col2 DIV - col0 FROM tab0 AS cor0
----
2303
29
912

skipif mysql # not compatible
query I rowsort label-801
SELECT ALL col2 * 29 + + col2 * col2 / - col0 FROM tab0 AS cor0
----
2303
29
912

onlyif mysql # use DIV operator for integer division
query I rowsort label-802
SELECT col1 * 44 DIV - 80 AS col0 FROM tab2 AS cor0
----
-17
-32
-9

skipif mysql # not compatible
query I rowsort label-802
SELECT col1 * 44 / - 80 AS col0 FROM tab2 AS cor0
----
-17
-32
-9

query I rowsort
SELECT ALL - - col0 * 56 + col2 * col1 AS col1 FROM tab0 AS cor0
----
12446
2057
4182

query I rowsort
SELECT DISTINCT + + 84 + col0 * - col0 AS col1 FROM tab2 AS cor0
----
-6000
-6157
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-805
SELECT ALL - + 17 DIV - col1 AS col1 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-805
SELECT ALL - + 17 / - col1 AS col1 FROM tab2 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + + col1 * cor0.col0 + + cor0.col0 + + col0 AS col1 FROM tab2 AS cor0
----
1501
231
4758

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

query I rowsort
SELECT ( 33 ) + col2 FROM tab2 cor0
----
59
60
71

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

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

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

query I rowsort
SELECT ALL + + 51 * 29 AS col0 FROM tab1 AS cor0
----
1479
1479
1479

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

query I rowsort
SELECT ALL - cor0.col2 + 2 * col0 * 24 + - 79 AS col1 FROM tab0 AS cor0
----
1040
1600
4111

query I rowsort
SELECT DISTINCT col0 + + 53 FROM tab0
----
142
77
88

query I rowsort
SELECT ALL col1 + - 67 * - col1 AS col0 FROM tab0
----
5848
6188
6596

onlyif mysql # use DIV operator for integer division
query I rowsort label-817
SELECT DISTINCT + ( 20 ) DIV col0 + + tab1.col1 FROM tab1
----
10
13
32

skipif mysql # not compatible
query I rowsort label-817
SELECT DISTINCT + ( 20 ) / col0 + + tab1.col1 FROM tab1
----
10
13
32

query I rowsort
SELECT ( tab2.col1 ) - - col0 * ( - col2 ) * col0 FROM tab2
----
-1292
-158125
-237141

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

query I rowsort
SELECT - 45 * + cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 0101a86cfb09a34ca3a5c63925d54ba7

query I rowsort
SELECT + 57 + col2 AS col0 FROM tab2 AS cor0
----
83
84
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-822
SELECT + tab1.col2 * col2 + col2 DIV - col0 AS col0 FROM tab1
----
2898
3249
9215

skipif mysql # not compatible
query I rowsort label-822
SELECT + tab1.col2 * col2 + col2 / - col0 AS col0 FROM tab1
----
2898
3249
9215

query I rowsort
SELECT ALL col0 * - 74 + col0 FROM tab2
----
-511
-5694
-5767

query I rowsort
SELECT - col2 * ( + 9 ) + col0 AS col0 FROM tab0
----
-273
-649
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 - ( + col0 + - col2 ) * - col2 col2 FROM tab1 AS cor0
----
-1456
-2751
463

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 * - col0 col0 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT DISTINCT - col0 * + col2 * + col0 + col0 * col2 FROM tab0 cor0
----
-1190
-18216
-642224

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

skipif mysql # not compatible
query I rowsort label-829
SELECT + col0 * - CAST ( col0 AS INTEGER ) + + col0 + - col2 FROM tab0
----
-1191
-585
-7914

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 23 + - ( col0 ) col1 FROM tab2 cor0
----
-101
-102
-30

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

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

query I rowsort
SELECT DISTINCT 69 * col1 AS col0 FROM tab0 AS cor0
----
5934
6279
6693

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

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

query I rowsort
SELECT - cor0.col0 * ( col0 ) * - col0 FROM tab1 AS cor0
----
262144
27
512000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-839
SELECT - CAST( col1 AS SIGNED ) * col1 - + 12 AS col1 FROM tab0 cor0
----
-7408
-8293
-9421

skipif mysql # not compatible
query I rowsort label-839
SELECT - CAST ( col1 AS INTEGER ) * col1 - + 12 AS col1 FROM tab0 cor0
----
-7408
-8293
-9421

query I rowsort
SELECT DISTINCT - col0 + 92 AS col1 FROM tab0
----
3
57
68

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

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

skipif mysql # not compatible
query I rowsort label-842
SELECT - CAST ( - col2 AS INTEGER ) + cor0.col1 * + col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - + 76 - 26 * col0 * col1 AS col1 FROM tab0 AS cor0
----
-210650
-53740
-88346

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

query I rowsort
SELECT - col2 - 45 AS col2 FROM tab2
----
-71
-72
-83

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - ( col0 + col0 ) * 13 col0 FROM tab2 AS cor0
----
-2054
-209
-2092

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

query I rowsort
SELECT ALL col1 * - col1 * - col2 AS col0 FROM tab0 AS cor0
----
244068
679042
9409

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

query I rowsort
SELECT - + 91 * cor0.col1 + - col2 AS col2 FROM tab1 AS cor0
----
-1279
-2420
-967

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

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

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

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

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

query I rowsort
SELECT col0 + - ( + col1 ) * 33 FROM tab1
----
-266
-349
-855

query I rowsort
SELECT + + col2 + - col1 * col2 - - 85 AS col0 FROM tab1 cor0
----
-1067
-1265
-428

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

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

query I rowsort
SELECT 34 * tab0.col0 FROM tab0
----
1190
3026
816

query I rowsort
SELECT - col2 * - col0 + 81 AS col2 FROM tab0 AS cor0
----
116
7379
873

query I rowsort
SELECT - 9 * col0 AS col2 FROM tab2 AS cor0
----
-63
-702
-711

onlyif mysql # use DIV operator for integer division
query I rowsort label-862
SELECT - col2 * + col0 + col1 * 47 DIV - col2 FROM tab0 AS cor0
----
-4594
-7350
-914

skipif mysql # not compatible
query I rowsort label-862
SELECT - col2 * + col0 + col1 * 47 / - col2 FROM tab0 AS cor0
----
-4594
-7350
-914

query I rowsort
SELECT DISTINCT col2 * 80 * cor0.col0 FROM tab0 AS cor0
----
2800
583840
63360

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

query I rowsort
SELECT DISTINCT + col2 * + 21 AS col1 FROM tab1 AS cor0
----
1134
1197
2016

query I rowsort
SELECT - 1 - col0 AS col1 FROM tab0
----
-25
-36
-90

query I rowsort
SELECT + 41 * col2 + - col0 AS col1 FROM tab0
----
1329
3273
6

query I rowsort
SELECT tab2.col2 + - tab2.col2 * 88 AS col2 FROM tab2
----
-2262
-2349
-3306

query I rowsort
SELECT DISTINCT col2 * + col0 * - col2 + + 46 - col2 AS col0 FROM tab2
----
-114068
-5084
-52708

query I rowsort
SELECT ALL 94 FROM tab0, tab2 cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

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

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

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

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

query I rowsort
SELECT col2 + + 77 AS col0 FROM tab0 cor0
----
110
159
78

query I rowsort
SELECT ALL col1 * + 20 + + col2 AS col1 FROM tab0 AS cor0
----
1753
1902
1941

query I rowsort
SELECT ( 7 ) FROM tab0
----
7
7
7

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + cor0.col2 + - cor0.col0 * + 24 AS col1 FROM tab1 AS cor0
----
-1479
-18
-1824

query I rowsort
SELECT + col1 * ( + col2 ) * + col0 + 59 FROM tab0
----
3454
664177
68171

query I rowsort
SELECT DISTINCT col1 * 92 AS col0 FROM tab0
----
7912
8372
8924

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

query I rowsort
SELECT - - 77 + col2 FROM tab2 AS cor0
----
103
104
115

query I rowsort
SELECT + - col0 + + 16 AS col2 FROM tab2 AS cor0
----
-62
-63
9

query I rowsort
SELECT ALL + col2 + - 88 * + col0 AS col2 FROM tab1
----
-210
-5575
-6944

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-889
SELECT col1 DIV tab2.col0 + + 67 AS col0 FROM tab2
----
67
67
71

skipif mysql # not compatible
query I rowsort label-889
SELECT col1 / tab2.col0 + + 67 AS col0 FROM tab2
----
67
67
71

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

query I rowsort
SELECT - col0 * - 24 + 17 FROM tab2
----
185
1889
1913

onlyif mysql # use DIV operator for integer division
query I rowsort label-892
SELECT + CAST( - ( col1 ) AS SIGNED ) DIV + 55 AS col2 FROM tab2 AS cor0
----
-1
0
0

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

query I rowsort
SELECT DISTINCT 66 * - 54 AS col0 FROM tab0 AS cor0
----
-3564

query I rowsort
SELECT DISTINCT - 7 + + col2 AS col1 FROM tab0 AS cor0
----
-6
26
75

query I rowsort
SELECT + 35 * col0 + col1 FROM tab0 AS cor0
----
1322
3206
926

query I rowsort
SELECT DISTINCT + 10 + - col0 * col1 FROM tab2 AS cor0
----
-1333
-207
-4592

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

query I rowsort
SELECT ALL + col0 * col1 - + col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT col1 + 52 FROM tab2 AS cor0
----
111
69
83

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-902
SELECT ALL 41 + + col1 DIV - 19 FROM tab2
----
38
40
41

skipif mysql # not compatible
query I rowsort label-902
SELECT ALL 41 + + col1 / - 19 FROM tab2
----
38
40
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-903
SELECT DISTINCT - 65 DIV col0 FROM tab0 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-903
SELECT DISTINCT - 65 / col0 FROM tab0 cor0
----
-1
-2
0

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

skipif mysql # not compatible
query I rowsort label-904
SELECT DISTINCT - + col2 + col2 / col0 AS col1 FROM tab2 cor0
----
-24
-26
-38

query I rowsort
SELECT col2 * col0 * - 79 - 48 AS col2 FROM tab1 cor0
----
-12846
-288240
-606768

query I rowsort
SELECT 93 - - col0 AS col1 FROM tab0 AS cor0
----
117
128
182

query I rowsort
SELECT DISTINCT + + col0 * col2 + - 24 * col0 AS col1 FROM tab1 AS cor0
----
2112
5760
90

query I rowsort
SELECT DISTINCT - - 99 + col1 * col2 FROM tab2 cor0
----
1633
745
936

query I rowsort
SELECT ALL - + 60 * - col1 FROM tab0 AS cor0
----
5160
5460
5820

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

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

query I rowsort
SELECT + + col1 + col0 + 38 * - 51 AS col0 FROM tab2 AS cor0
----
-1801
-1842
-1900

query I rowsort
SELECT DISTINCT - 68 + col1 AS col0 FROM tab1 AS cor0
----
-42
-55
-58

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

query I rowsort
SELECT ALL - col2 * 64 + col1 AS col2 FROM tab2 cor0
----
-1605
-1697
-2415

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

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

query I rowsort
SELECT cor0.col1 * 34 AS col0 FROM tab1 AS cor0
----
340
442
884

query I rowsort
SELECT DISTINCT - 66 + 50 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-16

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

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

query I rowsort
SELECT ALL - 99 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 761f5f1a166a00db99360141565a85da

query I rowsort
SELECT - - cor0.col2 + col0 + - col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT col2 * - 63 AS col2 FROM tab0
----
-2079
-5166
-63

query I rowsort
SELECT col1 * 79 * + 84 FROM tab2
----
112812
205716
391524

query I rowsort
SELECT ALL + + col0 * cor0.col0 - 31 FROM tab1 AS cor0
----
-22
4065
6369

query I rowsort
SELECT cor0.col1 * - col2 * col1 + col1 AS col1 FROM tab0 AS cor0
----
-243982
-678951
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-927
SELECT DISTINCT tab0.col2 * 82 DIV - col2 FROM tab0
----
-82

skipif mysql # not compatible
query I rowsort label-927
SELECT DISTINCT tab0.col2 * 82 / - col2 FROM tab0
----
-82

query I rowsort
SELECT DISTINCT 47 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col1 col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
-86
-91
-97

query I rowsort
SELECT ALL tab1.col0 * cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 8d0df4d65adbb98f9e0075a02971add2

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( 8 AS REAL ) FROM tab2
----
8

query I rowsort
SELECT ALL - col2 + + col1 * 6 * tab0.col1 FROM tab0
----
44343
49604
56453

query I rowsort
SELECT - tab2.col1 * + col0 + 66 + + col0 AS col0 FROM tab2
----
-1198
-144
-4458

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 99 + + col2 col0 FROM tab0
----
100
132
181

onlyif mysql # use DIV operator for integer division
query I rowsort label-936
SELECT DISTINCT + col2 DIV + col0 + col1 * col1 FROM tab0
----
7397
8281
9409

skipif mysql # not compatible
query I rowsort label-936
SELECT DISTINCT + col2 / + col0 + col1 * col1 FROM tab0
----
7397
8281
9409

query I rowsort
SELECT ALL - cor0.col2 * + cor0.col2 + col0 * col1 AS col1 FROM tab2 AS cor0
----
-101
-512
3926

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

query I rowsort
SELECT ALL + ( col0 ) + - 77 FROM tab0 AS cor0
----
-42
-53
12

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

skipif mysql # not compatible
query I rowsort label-940
SELECT DISTINCT + col0 - col2 / - 92 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - cor2.col0 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab1, tab0 AS cor2
----
243 values hashing to 68438270ef4dcbfd48dcdbe0b98336f5

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

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

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

query I rowsort
SELECT 30 * - ( col1 ) FROM tab2
----
-1770
-510
-930

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

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

query I rowsort
SELECT ALL col0 - - col0 * col2 * + 71 AS col1 FROM tab0
----
2520
518247
56256

query I rowsort
SELECT DISTINCT - 20 * + tab2.col1 + ( + tab2.col0 ) AS col2 FROM tab2
----
-1102
-261
-613

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 29 * + col2 col0 FROM tab2 AS cor0
----
-1102
-754
-783

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

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

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

query I rowsort
SELECT 99 - - 63 FROM tab2, tab1 AS cor0
----
9 values hashing to 480af13fa97bed507a41d8a44cc231af

query I rowsort
SELECT + 38 FROM tab2, tab0 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT 95 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-960
SELECT ALL + - 68 * col2 DIV - col0 FROM tab1 AS cor0
----
1224
60
81

skipif mysql # not compatible
query I rowsort label-960
SELECT ALL + - 68 * col2 / - col0 FROM tab1 AS cor0
----
1224
60
81

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

skipif mysql # not compatible
query I rowsort label-961
SELECT + 77 / - col2 FROM tab1 cor0
----
-1
-1
0

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

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

query I rowsort
SELECT ALL + col1 * 94 FROM tab0
----
8084
8554
9118

query I rowsort
SELECT ALL 39 - - 72 * + cor0.col2 FROM tab0 AS cor0
----
111
2415
5943

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

query I rowsort
SELECT ALL - - col2 * - col2 + - col2 AS col1 FROM tab2 AS cor0
----
-1482
-702
-756

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

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

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

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

query I rowsort
SELECT DISTINCT - 94 + cor0.col2 + 62 FROM tab2, tab0 AS cor0
----
-31
1
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 42 + cor0.col0 col2 FROM tab1 AS cor0
----
-39
22
38

query I rowsort
SELECT + + col2 + - 25 FROM tab2 AS cor0
----
1
13
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 97 * + col2 + + ( col2 ) col0 FROM tab1 AS cor0
----
5292
5586
9408

query I rowsort
SELECT 36 * + col0 + - col1 FROM tab0 AS cor0
----
1163
3113
778

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

query I rowsort
SELECT DISTINCT - 89 + - cor0.col1 FROM tab2 cor0
----
-106
-120
-148

query I rowsort
SELECT - col1 * - 45 + - col1 FROM tab1
----
1144
440
572

query I rowsort
SELECT - 16 + - cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 04d525aa1030b1a7d3846442a03c6f57

query I rowsort
SELECT - col0 * cor0.col1 + col1 + cor0.col2 * + ( cor0.col2 ) * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-3395
-619892
-95632

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

query I rowsort
SELECT DISTINCT col0 * ( + col0 ) + + cor0.col0 + - col1 FROM tab0 AS cor0
----
1163
514
7919

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

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

query I rowsort
SELECT col2 + - col2 * 51 FROM tab1
----
-2700
-2850
-4800

query I rowsort
SELECT - 39 - col2 AS col0 FROM tab2
----
-65
-66
-77

query I rowsort
SELECT tab0.col0 * + col0 * col1 + col0 AS col1 FROM tab0
----
118860
49560
720900

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 3 col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-990
SELECT DISTINCT col1 - - CAST( 5 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
102
91
96

skipif mysql # not compatible
query I rowsort label-990
SELECT DISTINCT col1 - - CAST ( 5 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
102
91
96

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

query I rowsort
SELECT DISTINCT + - col0 + 49 * col1 AS col2 FROM tab0 AS cor0
----
4190
4370
4718

query I rowsort
SELECT DISTINCT - col0 - - 16 AS col1 FROM tab2 AS cor0
----
-62
-63
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-994
SELECT - col2 DIV col2 + + 41 * col1 FROM tab0 AS cor0
----
3525
3730
3976

skipif mysql # not compatible
query I rowsort label-994
SELECT - col2 / col2 + + 41 * col1 FROM tab0 AS cor0
----
3525
3730
3976

query I rowsort
SELECT col0 * - col0 * + col0 - cor0.col2 FROM tab0 AS cor0
----
-13857
-42876
-705051

onlyif mysql # use DIV operator for integer division
query I rowsort label-996
SELECT + col0 + 69 DIV + 54 FROM tab1 cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-996
SELECT + col0 + 69 / + 54 FROM tab1 cor0
----
4
65
81

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + 90 col2 FROM tab2 cor0
----
1530
2790
5310

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

query I rowsort
SELECT ALL - + col2 * col1 + 87 FROM tab0 AS cor0
----
-10
-2751
-7375

query I rowsort
SELECT DISTINCT ( - tab0.col2 + - ( + 17 ) ) AS col2 FROM tab0, tab1, tab0 AS cor0
----
-18
-50
-99

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

query I rowsort
SELECT DISTINCT col1 + + col1 * + col1 AS col1 FROM tab0
----
7482
8372
9506

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( - 54 ) col1 FROM tab0
----
-1782
-4428
-54

query I rowsort
SELECT col2 + - 1 AS col1 FROM tab2 AS cor0
----
25
26
37

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

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

query I rowsort
SELECT DISTINCT - col2 + + 86 * col0 AS col0 FROM tab2 AS cor0
----
575
6682
6756

onlyif mysql # use DIV operator for integer division
query I rowsort label-1011
SELECT ALL col1 DIV - 13 - - col0 DIV + cor0.col0 FROM tab0 AS cor0
----
-5
-6
-6

skipif mysql # not compatible
query I rowsort label-1011
SELECT ALL col1 / - 13 - - col0 / + cor0.col0 FROM tab0 AS cor0
----
-5
-6
-6

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

query I rowsort
SELECT col0 + - col1 - col1 FROM tab0
----
-148
-159
-93

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

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

query I rowsort
SELECT col2 AS col0 FROM tab0 WHERE NOT + col1 * + col1 / + col1 <> NULL
----

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

query I rowsort
SELECT - col0 - + tab2.col2 FROM tab2 WHERE NOT - col2 / col1 > NULL
----

query I rowsort
SELECT col0 AS col2 FROM tab1 WHERE col2 = ( NULL )
----

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

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

query I rowsort
SELECT ALL - tab2.col0 + col0 * col1 + col2 AS col2 FROM tab2
----
1302
237
4550

onlyif mysql # use DIV operator for integer division
query I rowsort label-1023
SELECT DISTINCT + tab1.col2 + col1 * col2 DIV col0 AS col0 FROM tab1
----
111
522
65

skipif mysql # not compatible
query I rowsort label-1023
SELECT DISTINCT + tab1.col2 + col1 * col2 / col0 AS col0 FROM tab1
----
111
522
65

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

query I rowsort
SELECT + 26 * + col2 AS col2 FROM tab1 AS cor0
----
1404
1482
2496

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

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

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

query I rowsort
SELECT - + 86 + + col0 * col2 FROM tab0 AS cor0
----
-51
706
7212

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

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

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

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

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

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

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

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

query I rowsort
SELECT cor0.col1 + 22 * - cor0.col0 FROM tab0 AS cor0
----
-1867
-442
-673

onlyif mysql # use DIV operator for integer division
query I rowsort label-1036
SELECT ALL + 81 DIV col2 + - 87 col0 FROM tab1
----
-86
-86
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1036
SELECT ALL + 81 / col2 + - 87 col0 FROM tab1
----
-86
-86
-87

query I rowsort
SELECT - - col1 * - col2 - 49 AS col0 FROM tab2 AS cor0
----
-1583
-695
-886

query I rowsort
SELECT col1 * 87 AS col0 FROM tab0 cor0
----
7482
7917
8439

query I rowsort
SELECT ALL + + col0 * + 39 + col2 FROM tab2 AS cor0
----
300
3068
3119

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( 24 AS REAL ) * col0 + - 33 AS col2 FROM tab0 AS cor0
----
2103
543
807

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1044
SELECT col1 DIV 4 + col1 FROM tab0 AS cor0
----
107
113
121

skipif mysql # not compatible
query I rowsort label-1044
SELECT col1 / 4 + col1 FROM tab0 AS cor0
----
107
113
121

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

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

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

query I rowsort
SELECT DISTINCT - tab1.col2 * 18 FROM tab1
----
-1026
-1728
-972

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

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

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

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

query I rowsort
SELECT DISTINCT - col2 * col2 * col2 FROM tab0 AS cor0
----
-1
-35937
-551368

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col1 - col0 col2 FROM tab0
----
2040
3360
8010

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

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

query I rowsort
SELECT col0 + - tab2.col0 * + col0 AS col0 FROM tab2
----
-42
-6006
-6162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col1 * + col1 col1 FROM tab1
----
16224
36504
5700

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

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

query I rowsort
SELECT + col1 + - col2 * col1 * + col1 FROM tab2 AS cor0
----
-10965
-25916
-90447

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

query I rowsort
SELECT DISTINCT - col1 * 87 AS col0 FROM tab0
----
-7482
-7917
-8439

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT - 48 * - col1 AS col2 FROM tab1 cor0
----
1248
480
624

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1071
SELECT DISTINCT + col2 + - col0 DIV col1 AS col1 FROM tab2 cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-1071
SELECT DISTINCT + col2 + - col0 / col1 AS col1 FROM tab2 cor0
----
25
27
34

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

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE + col1 + col1 BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL tab2.col1 * + tab2.col2 + col0 AS col1 FROM tab2 WHERE NOT - col1 BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT col2 + - col2 * - col0 * - tab0.col0 FROM tab0
----
-1224
-18975
-649440

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

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

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT col0 <= ( col0 + col1 * col2 )
----

query I rowsort
SELECT - col1 AS col1 FROM tab2 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 * - col1 + col2 col2 FROM tab2
----
-205353
-29764
-4875

query I rowsort
SELECT ALL col0 AS col2 FROM tab0 WHERE NOT ( col2 ) >= NULL
----

query I rowsort
SELECT col2 + col0 * - col1 * + col0 FROM tab2
----
-106059
-1492
-358930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - col2 col0 FROM tab1
----
-16
-51
7

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1089
SELECT + col2 * col0 DIV col2 + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-1089
SELECT + col2 * col0 / col2 + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + col2 * col0 + col2 * + col2 FROM tab1 AS cor0
----
16896
3078
6897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col1 + - col1 col0 FROM tab0 AS cor0
----
7310
8190
9312

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

query I rowsort
SELECT - col0 * - col2 - col1 * - col0 * - col2 FROM tab2 AS cor0
----
-117624
-48032
-5670

query I rowsort
SELECT ALL col0 * col0 + col0 + col1 FROM tab2 AS cor0
----
6221
6337
87

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1096
SELECT ALL col2 DIV + col0 + - col2 * col2 * - col1 FROM tab0 AS cor0
----
611884
93655
97

skipif mysql # not compatible
query I rowsort label-1096
SELECT ALL col2 / + col0 + - col2 * col2 * - col1 FROM tab0 AS cor0
----
611884
93655
97

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

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

query I rowsort
SELECT ALL - col1 + tab0.col0 + - col1 AS col0 FROM tab0
----
-148
-159
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1100
SELECT - 51 DIV + 10 AS col1 FROM tab1
----
-5
-5
-5

skipif mysql # not compatible
query I rowsort label-1100
SELECT - 51 / + 10 AS col1 FROM tab1
----
-5
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1101
SELECT DISTINCT - ( col1 + col2 ) DIV + col2 FROM tab0
----
-2
-3
-98

skipif mysql # not compatible
query I rowsort label-1101
SELECT DISTINCT - ( col1 + col2 ) / + col2 FROM tab0
----
-2
-3
-98

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

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

query I rowsort
SELECT DISTINCT ( 34 ) * - col1 + col2 AS col0 FROM tab0 cor0
----
-2891
-3012
-3297

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

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

skipif mysql # not compatible
query I rowsort label-1106
SELECT + col1 / 66 AS col2 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 31 col2 FROM tab1 AS cor0
----
1674
1767
2976

query I rowsort
SELECT 71 - col2 * - ( 6 * - col1 ) AS col2 FROM tab1 AS cor0
----
-3349
-7417
-8353

query I rowsort
SELECT + - 43 + - col1 + ( col0 ) AS col0 FROM tab1 AS cor0
----
-66
11
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-1110
SELECT + col0 + col2 DIV + 48 AS col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-1110
SELECT + col0 + col2 / + 48 AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + ( col1 * + col0 ) + col0 AS col1 FROM tab2
----
1422
224
4680

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

query I rowsort
SELECT DISTINCT 20 * 37 + col0 FROM tab1
----
743
804
820

onlyif mysql # use DIV operator for integer division
query I rowsort label-1114
SELECT DISTINCT col0 * col1 + + col1 DIV 93 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-1114
SELECT DISTINCT col0 * col1 + + col1 / 93 FROM tab1
----
1040
640
78

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

query I rowsort
SELECT - col0 + 73 * 93 * + col2 FROM tab0 AS cor0
----
224013
556609
6754

query I rowsort
SELECT ALL - col1 * 89 * - col1 + - col1 AS col1 FROM tab1 AS cor0
----
15028
60138
8890

query I rowsort
SELECT DISTINCT + cor0.col2 - - col2 * + col1 AS col0 FROM tab1 AS cor0
----
1344
1458
627

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

skipif mysql # not compatible
query I rowsort label-1119
SELECT DISTINCT + col2 * - CAST ( - col0 * col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - 90 col1 FROM tab0 AS cor0
----
7740
8190
8730

query I rowsort
SELECT DISTINCT - - col0 * + ( - ( col1 ) ) + + 72 * + col1 * + col2 FROM tab0 AS cor0
----
202272
3589
529165

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

query I rowsort
SELECT - + cor0.col2 + 32 FROM tab1 AS cor0
----
-22
-25
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-1124
SELECT ALL + col1 DIV cor0.col0 + + 11 AS col1 FROM tab0 AS cor0
----
12
13
14

skipif mysql # not compatible
query I rowsort label-1124
SELECT ALL + col1 / cor0.col0 + + 11 AS col1 FROM tab0 AS cor0
----
12
13
14

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

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

query I rowsort
SELECT DISTINCT 4 + col2 AS col0 FROM tab2
----
30
31
42

query I rowsort
SELECT - col1 * + tab1.col2 - ( 52 ) * + tab1.col1 AS col2 FROM tab1
----
-1090
-1924
-2756

query I rowsort
SELECT ALL - 65 FROM tab1, tab1 AS cor0
----
9 values hashing to 744531575c1b6461ed2916d4940e4d23

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

skipif mysql # not compatible
query I rowsort label-1129
SELECT ALL - - col0 * CAST ( col1 AS INTEGER ) * col0 AS col1 FROM tab2 AS cor0
----
106097
1519
358956

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

query I rowsort
SELECT DISTINCT 20 + - 90 AS col1 FROM tab0, tab0 AS cor0, tab2, tab1 AS cor1
----
-70

query I rowsort
SELECT + cor1.col0 * cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 71e1c6f2098b2226c685e662111e4001

query I rowsort
SELECT + 40 * + col0 AS col2 FROM tab1 cor0
----
120
2560
3200

onlyif mysql # use DIV operator for integer division
query I rowsort label-1134
SELECT ALL ( + tab2.col1 ) DIV - 8 FROM tab2
----
-2
-3
-7

skipif mysql # not compatible
query I rowsort label-1134
SELECT ALL ( + tab2.col1 ) / - 8 FROM tab2
----
-2
-3
-7

query I rowsort
SELECT + tab1.col2 * tab1.col2 * + col1 AS col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT DISTINCT + col0 * + col2 * - 57 FROM tab1
----
-207936
-437760
-9234

query I rowsort
SELECT + 52 * tab2.col1 FROM tab2
----
1612
3068
884

query I rowsort
SELECT DISTINCT - 79 + - col1 AS col0 FROM tab2 AS cor0
----
-110
-138
-96

query I rowsort
SELECT - col0 + - col2 + - 79 * - col1 FROM tab2 AS cor0
----
1226
2415
4557

query I rowsort
SELECT + 26 + - col0 FROM tab2 AS cor0
----
-52
-53
19

query I rowsort
SELECT ALL + 60 * + 69 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b0d63e9d79b6a2407aa933d5f5a32daf

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

query I rowsort
SELECT - 41 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 47b9ef972839428f4f71d9f5b0944edf

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

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

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

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

query I rowsort
SELECT col0 + cor0.col0 * ( - col1 ) AS col1 FROM tab1 AS cor0
----
-576
-75
-960

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

query I rowsort
SELECT + + col2 + - col0 * col2 * + cor0.col0 FROM tab0 cor0
----
-1224
-18975
-649440

query I rowsort
SELECT ALL - cor0.col0 * + col2 + ( - col0 * col1 ) AS col0 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT 9 + col1 AS col2 FROM tab1 AS cor0
----
19
22
35

query I rowsort
SELECT DISTINCT - + cor0.col1 + + col2 * + 8 FROM tab2 AS cor0
----
149
185
287

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

query I rowsort
SELECT - 4 * col2 + - cor0.col2 * - col1 * col2 AS col2 FROM tab1 AS cor0
----
119424
32262
75600

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

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

query I rowsort
SELECT col1 * + ( - col1 * tab2.col0 ) AS col1 FROM tab2
----
-22831
-271518
-6727

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

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

query I rowsort
SELECT col0 * ( + 54 ) FROM tab2
----
378
4212
4266

query I rowsort
SELECT - 22 * col0 AS col2 FROM tab1
----
-1408
-1760
-66

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

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

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

query I rowsort
SELECT DISTINCT col1 * + 72 + col0 FROM tab0
----
6216
6641
7019

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

query I rowsort
SELECT cor0.col0 * ( 22 ) FROM tab0, tab2 AS cor0
----
9 values hashing to a3d05ac03ebcc5262a670a5402f27a36

query I rowsort
SELECT DISTINCT col2 + - col2 * col2 + 5 FROM tab1
----
-2857
-3187
-9115

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

query I rowsort
SELECT DISTINCT - col1 + cor0.col0 * - col0 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT ALL + col0 + col2 + col0 AS col1 FROM tab1
----
185
256
60

query I rowsort
SELECT ALL - 23 + + col0 FROM tab0
----
1
12
66

query I rowsort
SELECT DISTINCT + tab1.col2 + col0 * + col2 FROM tab1
----
216
3705
7776

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col1 * 80 + col2 ) col0 FROM tab0
----
-6847
-7198
-7759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col0 + + 25 col0 FROM tab0 AS cor0
----
-10
-7273
-767

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

query I rowsort
SELECT ALL + col0 + - col1 * ( + 56 ) * - col2 FROM tab0 AS cor0
----
158952
417961
5467

query I rowsort
SELECT col2 + + col0 * 26 AS col2 FROM tab0
----
2396
657
911

query I rowsort
SELECT col1 + + 40 * + cor0.col0 FROM tab1 cor0
----
146
2570
3213

query I rowsort
SELECT DISTINCT + + col2 * - 81 * 42 AS col0 FROM tab2 cor0
----
-129276
-88452
-91854

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1181
SELECT ALL + - col0 DIV 11 AS col1 FROM tab2 AS cor0
----
-7
-7
0

skipif mysql # not compatible
query I rowsort label-1181
SELECT ALL + - col0 / 11 AS col1 FROM tab2 AS cor0
----
-7
-7
0

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

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

query I rowsort
SELECT + col0 * - 54 AS col2 FROM tab1 cor0
----
-162
-3456
-4320

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

query I rowsort
SELECT + 59 - + col0 FROM tab2 AS cor0
----
-19
-20
52

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

query I rowsort
SELECT DISTINCT + + 5 FROM tab2 AS cor0
----
5

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

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

skipif mysql # not compatible
query I rowsort label-1190
SELECT DISTINCT CAST ( + col0 AS INTEGER ) + col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + 78 * + col2 AS col1 FROM tab0 AS cor0
----
2574
6396
78

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

query I rowsort
SELECT ALL - ( col2 ) + + cor0.col1 * 12 FROM tab0 AS cor0
----
1010
1163
999

query I rowsort
SELECT - - ( col0 ) * - col0 * col0 + - ( col0 ) * col0 AS col2 FROM tab2 AS cor0
----
-392
-480636
-499280

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

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

query I rowsort
SELECT + col2 * ( + col0 + + 22 ) AS col2 FROM tab2 AS cor0
----
2600
3838
783

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

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

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

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

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

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

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

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

query I rowsort
SELECT 67 + - col0 FROM tab2
----
-11
-12
60

query I rowsort
SELECT 22 + + cor0.col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 3f88b72f1799837cec1029c7665d892f

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 89 * - col1 col0 FROM tab2 AS cor0
----
-1513
-2759
-5251

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

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

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

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

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

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

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

query I rowsort
SELECT + col1 * 63 FROM tab2 AS cor0
----
1071
1953
3717

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

query I rowsort
SELECT ALL - cor0.col1 - - cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-1219
SELECT ( 47 ) + - cor0.col2 / cor0.col0 FROM tab2 AS cor0
----
44
47
47

query I rowsort
SELECT DISTINCT ( + 99 ) * col0 + - 43 AS col0 FROM tab1 cor0
----
254
6293
7877

query I rowsort
SELECT ALL - 77 + col0 * col0 AS col2 FROM tab1 AS cor0
----
-68
4019
6323

query I rowsort
SELECT DISTINCT + 76 * - 50 AS col2 FROM tab0 AS cor0
----
-3800

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + ( col2 ) ) + 5 col2 FROM tab0 AS cor0
----
38
6
87

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

query I rowsort
SELECT DISTINCT col1 * - col0 + + 88 FROM tab2
----
-1255
-129
-4514

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

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

skipif mysql # not compatible
query I rowsort label-1229
SELECT ALL - ( + col0 ) / col2 FROM tab0 AS cor0
----
-1
-35
0

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

query I rowsort
SELECT ALL - - ( - 77 ) + col1 AS col1 FROM tab1 AS cor0
----
-51
-64
-67

query I rowsort
SELECT - - col1 * 18 * - col0 + col1 * col1 * cor0.col1 FROM tab0 AS cor0
----
598904
607789
851563

query I rowsort
SELECT DISTINCT - 47 + 7 * col0 FROM tab2 AS cor0
----
2
499
506

query I rowsort
SELECT ALL col2 + - 87 AS col1 FROM tab2
----
-49
-60
-61

query I rowsort
SELECT + 9 + tab1.col1 AS col0 FROM tab1
----
19
22
35

query I rowsort
SELECT ( 44 + col2 ) FROM tab1
----
101
140
98

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1238
SELECT + - col0 / col0 + + col2 col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT + - 13 + - col0 * - col2 AS col2 FROM tab0 AS cor0
----
22
7285
779

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

query I rowsort
SELECT ALL 19 + + cor0.col1 + - 85 FROM tab2, tab2 AS cor0
----
9 values hashing to 5c4b24968b31517b20871432235220e6

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

skipif mysql # not compatible
query I rowsort label-1242
SELECT - cor0.col1 + - col0 / col1 AS col0 FROM tab2 cor0
----
-21
-31
-60

query I rowsort
SELECT ALL - + col0 * 75 + - col1 FROM tab1 AS cor0
----
-251
-4810
-6013

query I rowsort
SELECT DISTINCT - col2 * ( col1 ) + + col2 + 6 * - 89 FROM tab1 AS cor0
----
-1047
-1686
-1884

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 AS REAL ) * col0 FROM tab2 AS cor0
----
189
2028
3002

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1250
SELECT DISTINCT col1 * + col1 DIV - col1 + - tab2.col2 * ( + col2 ) * col1 AS col0 FROM tab2
----
-22630
-24565
-39943

skipif mysql # not compatible
query I rowsort label-1250
SELECT DISTINCT col1 * + col1 / - col1 + - tab2.col2 * ( + col2 ) * col1 AS col0 FROM tab2
----
-22630
-24565
-39943

query I rowsort
SELECT DISTINCT col1 * 60 * 23 FROM tab1
----
13800
17940
35880

query I rowsort
SELECT ALL tab2.col0 * + col1 + - 44 AS col1 FROM tab2
----
1299
173
4558

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

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

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

query I rowsort
SELECT + + 62 + 55 AS col1 FROM tab0 AS cor0
----
117
117
117

query I rowsort
SELECT DISTINCT + 13 + 63 * cor0.col0 AS col2 FROM tab2 AS cor0
----
454
4927
4990

query I rowsort
SELECT col1 * 97 - - col0 FROM tab2 AS cor0
----
1728
3014
5801

query I rowsort
SELECT ALL col2 + + 20 FROM tab2
----
46
47
58

query I rowsort
SELECT - col1 - - 47 FROM tab0
----
-39
-44
-50

query I rowsort
SELECT ALL - 2 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT col2 * cor0.col0 + + 44 * col1 - col0 * ( - col1 ) FROM tab1 cor0
----
1384
4728
9292

onlyif mysql # use DIV operator for integer division
query I rowsort label-1263
SELECT col0 DIV col2 + 33 + + cor0.col1 FROM tab1 cor0
----
44
46
59

skipif mysql # not compatible
query I rowsort label-1263
SELECT col0 / col2 + 33 + + cor0.col1 FROM tab1 cor0
----
44
46
59

query I rowsort
SELECT ALL + col2 + + col0 * 98 AS col1 FROM tab2 AS cor0
----
713
7670
7780

query I rowsort
SELECT DISTINCT - col0 + + ( + col0 ) * - col1 * + ( col1 ) + cor0.col2 AS col0 FROM tab0 AS cor0
----
-177495
-329349
-737016

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

query I rowsort
SELECT ALL col2 + - 66 FROM tab0 AS cor0
----
-33
-65
16

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

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

query I rowsort
SELECT + col1 * - col1 - 85 * - 95 FROM tab1 AS cor0
----
7399
7906
7975

query I rowsort
SELECT - + col0 + col2 * - 45 FROM tab1 AS cor0
----
-2433
-2629
-4400

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1272
SELECT ALL + - col0 * col1 + CAST( + col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif mysql # not compatible
query I rowsort label-1272
SELECT ALL + - col0 * col1 + CAST ( + col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - col0 * + cor0.col1 + col1 * col2 AS col2 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT + + col2 - - col2 * 31 FROM tab2 AS cor0
----
1216
832
864

query I rowsort
SELECT - cor0.col1 * + col0 + - col0 * + col1 FROM tab1 AS cor0
----
-1280
-156
-2080

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

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

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

query I rowsort
SELECT col2 - + 90 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1074
-2286
-843

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

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

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

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

query I rowsort
SELECT + col2 * 97 * col1 + col2 + + 54 FROM tab1
----
121206
136296
55401

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

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

skipif mysql # not compatible
query I rowsort label-1285
SELECT - col0 / ( - col2 ) + + col0 AS col0 FROM tab0
----
24
70
90

query I rowsort
SELECT + col2 + ( - 6 ) AS col2 FROM tab0
----
-5
27
76

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1290
SELECT ALL col2 + - CAST ( col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + col2 + 12 AS col1 FROM tab2
----
38
39
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-1292
SELECT DISTINCT + col2 DIV + col0 + - col0 * tab0.col1 FROM tab0
----
-2063
-3395
-8099

skipif mysql # not compatible
query I rowsort label-1292
SELECT DISTINCT + col2 / + col0 + - col0 * tab0.col1 FROM tab0
----
-2063
-3395
-8099

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

query I rowsort
SELECT 28 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

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

query I rowsort
SELECT - 23 + cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
2815
74
7439

query I rowsort
SELECT ALL col0 * + col2 + - 77 + + col1 AS col1 FROM tab1 AS cor0
----
111
3581
7616

query I rowsort
SELECT ALL - 6 - col0 FROM tab0 AS cor0
----
-30
-41
-95

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

query I rowsort
SELECT DISTINCT 72 * col0 AS col2 FROM tab0 AS cor0
----
1728
2520
6408

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

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

query I rowsort
SELECT DISTINCT - - 55 * col1 + ( col2 ) * - col0 AS col1 FROM tab2 AS cor0
----
-2067
1217
1516

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1305
SELECT DISTINCT - col2 * col2 * + col1 + col0 DIV col1 AS col2 FROM tab2
----
-22599
-24544
-39883

skipif mysql # not compatible
query I rowsort label-1305
SELECT DISTINCT - col2 * col2 * + col1 + col0 / col1 AS col2 FROM tab2
----
-22599
-24544
-39883

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

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

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

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

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

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

query I rowsort
SELECT - col0 * + col1 - col0 * + col1 FROM tab0
----
-16198
-4128
-6790

query I rowsort
SELECT DISTINCT col0 AS col2 FROM tab1 WHERE NULL IN ( col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col2 * col0 col0 FROM tab2
----
114076
5103
52728

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1318
SELECT col1 * + col2 - - col0 DIV - col0 FROM tab0
----
2837
7461
96

skipif mysql # not compatible
query I rowsort label-1318
SELECT col1 * + col2 - - col0 / - col0 FROM tab0
----
2837
7461
96

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

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

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

query I rowsort
SELECT ALL + tab2.col1 * - col0 * - col0 AS col2 FROM tab2
----
106097
1519
358956

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

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

query I rowsort
SELECT ALL - col1 * + col2 + - col0 * col2 FROM tab2
----
-1026
-3562
-3648

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

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL IN ( col1 * col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1327
SELECT DISTINCT + col2 + col2 * col1 DIV - col1 + + col0 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-1327
SELECT DISTINCT + col2 + col2 * col1 / - col1 + + col0 FROM tab2
----
7
78
79

query III rowsort
SELECT ALL * FROM tab2 WHERE ( col1 + col1 / col2 ) BETWEEN + tab2.col0 + + col0 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1329
SELECT + col0 + col2 DIV - col1 FROM tab1
----
1
59
73

skipif mysql # not compatible
query I rowsort label-1329
SELECT + col0 + col2 / - col1 FROM tab1
----
1
59
73

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

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT + col1 + - col1 NOT BETWEEN NULL AND col0
----

query I rowsort
SELECT ALL - tab2.col2 + col0 + + col0 AS col2 FROM tab2
----
-13
120
130

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

skipif mysql # not compatible
query I rowsort label-1333
SELECT DISTINCT + col0 * + col2 / col2 FROM tab0
----
24
35
89

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

query I rowsort
SELECT ALL - tab0.col1 + col2 * - col0 * col1 + - tab0.col0 AS col1 FROM tab0
----
-3527
-664298
-68222

query I rowsort
SELECT - 0 + col1 * tab2.col2 + ( tab2.col1 + col0 ) AS col1 FROM tab2
----
1671
742
875

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 29 - col1 * col0 * col0 col0 FROM tab0 AS cor0
----
-118796
-49507
-720782

query I rowsort
SELECT ALL 42 * ( - col1 ) FROM tab0
----
-3612
-3822
-4074

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

query I rowsort
SELECT - 56 - col1 AS col1 FROM tab2 AS cor0
----
-115
-73
-87

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

query I rowsort
SELECT ( - 10 ) - col0 * ( - col0 ) FROM tab0 cor0
----
1215
566
7911

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

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

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

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

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

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

query I rowsort
SELECT + col0 + - 30 AS col2 FROM tab0 AS cor0
----
-6
5
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1350
SELECT ALL col0 DIV + 5 AS col2 FROM tab0
----
17
4
7

skipif mysql # not compatible
query I rowsort label-1350
SELECT ALL col0 / + 5 AS col2 FROM tab0
----
17
4
7

query I rowsort
SELECT DISTINCT col0 * + col0 + + 2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
103
6136
6317

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

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

query I rowsort
SELECT - col2 * 61 * + col2 AS col2 FROM tab2 AS cor0
----
-41236
-44469
-88084

onlyif mysql # use DIV operator for integer division
query I rowsort label-1355
SELECT ALL col1 DIV ( - col1 ) + - col2 FROM tab2
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-1355
SELECT ALL col1 / ( - col1 ) + - col2 FROM tab2
----
-27
-28
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-1356
SELECT - col0 + + col1 * col0 DIV - col2 FROM tab1 AS cor0
----
-4
-75
-90

skipif mysql # not compatible
query I rowsort label-1356
SELECT - col0 + + col1 * col0 / - col2 FROM tab1 AS cor0
----
-4
-75
-90

query I rowsort
SELECT DISTINCT 2 * + 40 FROM tab2 AS cor0
----
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1358
SELECT ALL - 56 DIV 54 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif mysql # not compatible
query I rowsort label-1358
SELECT ALL - 56 / 54 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT ALL - col1 * + col1 * + tab1.col1 FROM tab1
----
-1000
-17576
-2197

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

query I rowsort
SELECT DISTINCT 96 + + cor0.col2 FROM tab2 AS cor0
----
122
123
134

query I rowsort
SELECT DISTINCT col0 + - col0 * - col1 - - col0 AS col2 FROM tab0 AS cor0
----
2112
3465
8277

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

query I rowsort
SELECT DISTINCT + col0 * + col0 + col0 FROM tab1 cor0
----
12
4160
6480

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

query I rowsort
SELECT ALL - col1 * col2 - + tab2.col0 FROM tab2
----
-1612
-725
-844

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

skipif mysql # not compatible
query I rowsort label-1367
SELECT - col0 / 99 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT 10 + - col0 * + col1 FROM tab2
----
-1333
-207
-4592

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

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

query I rowsort
SELECT ALL 58 + col2 FROM tab2
----
84
85
96

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

skipif mysql # not compatible
query I rowsort label-1372
SELECT DISTINCT col0 + + cor0.col0 / col2 FROM tab1 AS cor0
----
3
65
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1373
SELECT ALL - 9 + - col0 DIV col0 + + col1 * + col2 AS col2 FROM tab1 AS cor0
----
1238
1394
560

skipif mysql # not compatible
query I rowsort label-1373
SELECT ALL - 9 + - col0 / col0 + + col1 * + col2 AS col2 FROM tab1 AS cor0
----
1238
1394
560

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

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

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

query I rowsort
SELECT ALL + ( col2 ) + + col2 * col0 * cor0.col1 FROM tab1 cor0
----
36537
4266
99936

query I rowsort
SELECT ALL 21 + col1 * col0 FROM tab0 AS cor0
----
2085
3416
8120

query I rowsort
SELECT DISTINCT + 42 + + col1 FROM tab2 cor0
----
101
59
73

query I rowsort
SELECT ALL - + 96 + - col0 * col0 * col1 AS col1 FROM tab2 AS cor0
----
-106193
-1615
-359052

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

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

query I rowsort
SELECT ALL + + 90 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT DISTINCT tab1.col0 * 90 * - 82 FROM tab1
----
-22140
-472320
-590400

query I rowsort
SELECT + col2 * 77 FROM tab1 AS cor0
----
4158
4389
7392

query I rowsort
SELECT col0 * + 88 AS col1 FROM tab0 cor0
----
2112
3080
7832

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

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

skipif mysql # not compatible
query I rowsort label-1388
SELECT - col2 + - CAST ( - col1 AS INTEGER ) * - col2 * col0 FROM tab0 AS cor0
----
-3396
-664200
-68145

query I rowsort
SELECT col0 * cor0.col0 * col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT ALL + cor0.col1 + + cor1.col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4156fc5105e6abb5fe33cb914cb553df

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

query I rowsort
SELECT col1 * - 60 AS col0 FROM tab1 cor0
----
-1560
-600
-780

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

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

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

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

query I rowsort
SELECT DISTINCT col2 * - col0 + - col2 FROM tab0 AS cor0
----
-36
-7380
-825

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

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

query I rowsort
SELECT ALL - - col0 + col1 * - col0 FROM tab1 cor0
----
-576
-75
-960

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

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

query I rowsort
SELECT tab2.col1 / + col1 FROM tab2 WHERE NOT ( NULL ) = NULL
----

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

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

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

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

query I rowsort
SELECT DISTINCT + col0 + 46 AS col0 FROM tab2 AS cor0
----
124
125
53

query I rowsort
SELECT ALL - col2 * cor0.col2 * 28 AS col2 FROM tab1 cor0
----
-258048
-81648
-90972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 99 + col1 col0 FROM tab1 AS cor0
----
-271
-6326
-7907

query I rowsort
SELECT DISTINCT - + col1 + cor0.col1 * 10 + cor0.col0 AS col2 FROM tab2 AS cor0
----
232
286
609

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

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

query I rowsort
SELECT DISTINCT - - col2 + - col0 + ( + col2 ) AS col1 FROM tab1 AS cor0
----
105
112
50

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

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

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

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

query I rowsort
SELECT ALL tab1.col2 * + col0 + ( col2 * - col1 ) FROM tab1
----
-1242
3078
6432

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col1 * col1 + + 54 * col1 + col2 col0 FROM tab0 AS cor0
----
-631379
-748575
-907434

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1423
SELECT ALL col2 DIV + col0 + 65 AS col0 FROM tab0 AS cor0
----
65
65
66

skipif mysql # not compatible
query I rowsort label-1423
SELECT ALL col2 / + col0 + 65 AS col0 FROM tab0 AS cor0
----
65
65
66

query I rowsort
SELECT + - col0 * + col2 * col2 + 34 FROM tab2 AS cor0
----
-114042
-5069
-52694

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

query I rowsort
SELECT + col0 + col0 * ( col2 ) FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - ( - col2 ) * - 51 FROM tab1
----
-2754
-2907
-4896

query I rowsort
SELECT DISTINCT - 65 * col2 AS col1 FROM tab2
----
-1690
-1755
-2470

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1432
SELECT - col1 DIV + col0 + 53 col0 FROM tab0 AS cor0
----
50
51
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1432
SELECT - col1 / + col0 + 53 col0 FROM tab0 AS cor0
----
50
51
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-1433
SELECT - col1 * 17 DIV col1 AS col1 FROM tab1
----
-17
-17
-17

skipif mysql # not compatible
query I rowsort label-1433
SELECT - col1 * 17 / col1 AS col1 FROM tab1
----
-17
-17
-17

query I rowsort
SELECT + - cor0.col0 * col0 - cor0.col2 * col1 FROM tab0 AS cor0
----
-1322
-15383
-3414

query I rowsort
SELECT + + col2 + - 49 AS col0 FROM tab2 AS cor0
----
-11
-22
-23

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

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

query I rowsort
SELECT ALL + col2 * + 86 AS col2 FROM tab0 AS cor0
----
2838
7052
86

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1438
SELECT ALL - col0 / 40 col0 FROM tab0 AS cor0
----
-2
0
0

query I rowsort
SELECT + + col2 * + ( - 4 ) + col2 FROM tab0 AS cor0
----
-246
-3
-99

query I rowsort
SELECT DISTINCT + tab1.col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0, tab0 cor1
----
54
57
96

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

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

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1446
SELECT ALL - CAST( - 4 AS SIGNED ) AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

skipif mysql # not compatible
query I rowsort label-1446
SELECT ALL - CAST ( - 4 AS INTEGER ) AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

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

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

query I rowsort
SELECT ALL - + 18 - 18 FROM tab2 AS cor0
----
-36
-36
-36

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

skipif mysql # not compatible
query I rowsort label-1450
SELECT ALL col1 / + 6 + col0 FROM tab1 AS cor0
----
65
7
82

query I rowsort
SELECT - + 97 * + col0 FROM tab2 AS cor0
----
-679
-7566
-7663

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

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

query I rowsort
SELECT ALL - - col2 + + 81 + + cor0.col2 * - 78 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
112751
52835
56970

query I rowsort
SELECT - - cor0.col0 * 16 AS col2 FROM tab2 AS cor0
----
112
1248
1264

query I rowsort
SELECT DISTINCT + col2 + 92 FROM tab1 cor0
----
146
149
188

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1459
SELECT ALL col1 DIV col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-30
-81
1

skipif mysql # not compatible
query I rowsort label-1459
SELECT ALL col1 / col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-30
-81
1

query I rowsort
SELECT ALL - - 35 * - cor0.col0 + - col2 * 11 AS col0 FROM tab1 AS cor0
----
-2867
-3856
-699

query I rowsort
SELECT DISTINCT - + 79 * col0 * cor0.col1 - cor0.col0 FROM tab2 AS cor0
----
-106176
-17150
-363636

onlyif mysql # use DIV operator for integer division
query I rowsort label-1462
SELECT DISTINCT 83 DIV - col1 - col2 * - ( + col0 ) FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-1462
SELECT DISTINCT 83 / - col1 - col2 * - ( + col0 ) FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 56 + + col2 + col1 col2 FROM tab0
----
154
175
229

query I rowsort
SELECT ALL 38 * - col1 * - 66 AS col1 FROM tab1
----
25080
32604
65208

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

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

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

query I rowsort
SELECT ALL col2 * col2 + + 34 - col2 * col1 AS col2 FROM tab0 AS cor0
----
-1715
-62
-704

query I rowsort
SELECT - col0 + + cor0.col2 + + col0 * + col2 FROM tab0 cor0
----
1
7291
801

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

query I rowsort
SELECT ALL - cor0.col0 + - ( - 10 ) AS col2 FROM tab2 AS cor0
----
-68
-69
3

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

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

skipif mysql # not compatible
query I rowsort label-1472
SELECT DISTINCT - col2 * + CAST ( - col2 AS INTEGER ) - col1 * + col0 AS col1 FROM tab1 AS cor0
----
2609
2838
8176

query I rowsort
SELECT ALL - col0 + - 9 * + cor0.col0 FROM tab0 AS cor0
----
-240
-350
-890

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

skipif mysql # not compatible
query I rowsort label-1474
SELECT DISTINCT col1 * ( col2 ) / - tab1.col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT + col2 * + col0 + 57 FROM tab2
----
2085
246
3059

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col0 col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + + col0 + - 82 FROM tab0 cor0
----
-47
-58
7

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

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

query I rowsort
SELECT - cor0.col2 + 90 * col1 FROM tab1 AS cor0
----
1074
2286
843

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1483
SELECT + - cor0.col1 * col1 DIV + col0 AS col0 FROM tab0 AS cor0
----
-268
-308
-93

skipif mysql # not compatible
query I rowsort label-1483
SELECT + - cor0.col1 * col1 / + col0 AS col0 FROM tab0 AS cor0
----
-268
-308
-93

query I rowsort
SELECT ALL - - ( col0 ) * - col0 * 57 AS col0 FROM tab1 AS cor0
----
-233472
-364800
-513

query I rowsort
SELECT - - 61 * 68 FROM tab1 AS cor0
----
4148
4148
4148

query I rowsort
SELECT col0 * - cor0.col2 * cor0.col2 + col1 FROM tab0 cor0
----
-26050
-598345
62

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1488
SELECT ALL - + CAST( 11 AS SIGNED ) - + col0 AS col0 FROM tab2 AS cor0
----
-18
-89
-90

skipif mysql # not compatible
query I rowsort label-1488
SELECT ALL - + CAST ( 11 AS INTEGER ) - + col0 AS col0 FROM tab2 AS cor0
----
-18
-89
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1489
SELECT - 27 * col0 DIV + tab0.col0 FROM tab0
----
-27
-27
-27

skipif mysql # not compatible
query I rowsort label-1489
SELECT - 27 * col0 / + tab0.col0 FROM tab0
----
-27
-27
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-1490
SELECT DISTINCT - tab1.col0 DIV + col2 + 58 + - col1 * col2 col2 FROM tab1
----
-1190
-1346
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1490
SELECT DISTINCT - tab1.col0 / + col2 + 58 + - col1 * col2 col2 FROM tab1
----
-1190
-1346
-513

query I rowsort
SELECT - col2 + + col2 * + col2 + col0 * + col0 FROM tab2 AS cor0
----
6734
751
7647

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col2 ) * - 97 col1 FROM tab1 AS cor0
----
-5238
-5529
-9312

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - 98 * col1 - + CAST ( ( - col2 ) AS REAL ) * - 92 FROM tab2 AS cor0
----
-5162
-5522
-8174

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

query I rowsort
SELECT DISTINCT 38 + - col2 FROM tab2 AS cor0
----
0
11
12

query I rowsort
SELECT ALL + cor0.col0 + - 37 AS col0 FROM tab1 AS cor0
----
-34
27
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-1497
SELECT - col2 * + 78 + + 71 DIV col2 + col2 * cor0.col1 AS col2 FROM tab0 AS cor0
----
1066
266
90

skipif mysql # not compatible
query I rowsort label-1497
SELECT - col2 * + 78 + + 71 / col2 + col2 * cor0.col1 AS col2 FROM tab0 AS cor0
----
1066
266
90

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

query I rowsort
SELECT ALL + - col0 * + cor0.col2 + col1 + col2 AS col2 FROM tab1 cor0
----
-3581
-7571
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1500
SELECT + col0 DIV 33 FROM tab2 AS cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-1500
SELECT + col0 / 33 FROM tab2 AS cor0
----
0
2
2

query I rowsort
SELECT col0 + - col2 + col2 * col1 FROM tab0 AS cor0
----
131
2829
7469

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 32 + col0 * + 46 col0 FROM tab2
----
290
3556
3602

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1509
SELECT ALL - col2 + - 32 DIV cor0.col0 FROM tab1 AS cor0
----
-57
-64
-96

skipif mysql # not compatible
query I rowsort label-1509
SELECT ALL - col2 + - 32 / cor0.col0 FROM tab1 AS cor0
----
-57
-64
-96

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

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

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

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

query I rowsort
SELECT + col0 + - col1 * ( - col1 ) * col0 AS col2 FROM tab1 AS cor0
----
13600
2031
6464

query I rowsort
SELECT 37 + cor0.col2 * + 63 AS col2 FROM tab2 AS cor0
----
1675
1738
2431

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1516
SELECT - col0 / + col1 col0 FROM tab2 AS cor0
----
-1
-4
0

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

query I rowsort
SELECT ALL - col1 * 93 AS col0 FROM tab1 AS cor0
----
-1209
-2418
-930

query I rowsort
SELECT - col0 * + 72 FROM tab0 AS cor0
----
-1728
-2520
-6408

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

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

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

skipif mysql # not compatible
query I rowsort label-1521
SELECT - - 9 / + col1 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL - 34 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

query I rowsort
SELECT ALL - col0 * + 12 AS col1 FROM tab0
----
-1068
-288
-420

query I rowsort
SELECT DISTINCT ( - 63 ) AS col1 FROM tab2, tab1 AS cor0
----
-63

query I rowsort
SELECT - tab0.col1 + 86 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 43d86059ddc06082a67de9833451fd91

query I rowsort
SELECT + col0 * col0 + + 74 AS col0 FROM tab0
----
1299
650
7995

onlyif mysql # use DIV operator for integer division
query I rowsort label-1527
SELECT col2 + + col2 DIV col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1527
SELECT col2 + + col2 / col2 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT ALL + 34 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1529
SELECT + CAST( 20 AS SIGNED ) FROM tab1, tab2 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

skipif mysql # not compatible
query I rowsort label-1529
SELECT + CAST ( 20 AS INTEGER ) FROM tab1, tab2 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT - 77 + + cor1.col1 AS col1 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 47544dc0b641e49cc7f97e9e41b77656

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

query I rowsort
SELECT DISTINCT - col0 + 5 AS col2 FROM tab0 cor0
----
-19
-30
-84

query I rowsort
SELECT + ( + 53 ) + col0 FROM tab1 AS cor0
----
117
133
56

query I rowsort
SELECT DISTINCT 73 * - col0 + col1 * + 6 + col2 AS col1 FROM tab2 AS cor0
----
-298
-5314
-5627

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

query I rowsort
SELECT + 52 + - 26 FROM tab0, tab0 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

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

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

query I rowsort
SELECT + 95 * - cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 381c83e2a0077d0955cd3283ddc85954

query I rowsort
SELECT ( cor0.col1 ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT - 27 * - col2 AS col1 FROM tab1
----
1458
1539
2592

query I rowsort
SELECT - col0 * + ( col0 * 54 ) FROM tab2 cor0
----
-2646
-328536
-337014

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

query I rowsort
SELECT DISTINCT 13 - - 93 FROM tab1, tab0, tab0 AS cor0
----
106

query I rowsort
SELECT DISTINCT + tab1.col0 AS col2 FROM tab1, tab0, tab2 AS cor0
----
3
64
80

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

skipif mysql # not compatible
query I rowsort label-1546
SELECT ALL - col1 * + col1 - - col1 / col0 AS col2 FROM tab1 cor0
----
-100
-169
-668

onlyif mysql # use DIV operator for integer division
query I rowsort label-1547
SELECT 64 DIV col1 col0 FROM tab1
----
2
4
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1547
SELECT 64 / col1 col0 FROM tab1
----
2
4
6

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

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

query I rowsort
SELECT - col0 * col0 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 * 12 col1 FROM tab1 cor0
----
-36
-768
-960

query I rowsort
SELECT + cor0.col2 * 55 AS col0 FROM tab2 AS cor0
----
1430
1485
2090

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

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

query I rowsort
SELECT ALL - 92 * col0 FROM tab0
----
-2208
-3220
-8188

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - + col1 + + 41 + col0 AS col2 FROM tab1 AS cor0
----
108
18
95

query I rowsort
SELECT ALL col1 + col2 - - 28 FROM tab1 cor0
----
108
137
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + 11 col0 FROM tab1 AS cor0
----
-33
-704
-880

onlyif mysql # use DIV operator for integer division
query I rowsort label-1566
SELECT + 79 DIV + col0 - - col2 FROM tab1
----
58
80
96

skipif mysql # not compatible
query I rowsort label-1566
SELECT + 79 / + col0 - - col2 FROM tab1
----
58
80
96

query I rowsort
SELECT 6 * - col1 - - 36 FROM tab0
----
-480
-510
-546

query I rowsort
SELECT - - col0 + + 13 AS col0 FROM tab1 AS cor0
----
16
77
93

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

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

query I rowsort
SELECT ALL + 35 + col1 * col1 AS col2 FROM tab0 cor0
----
7431
8316
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-1571
SELECT ALL + 1 + col1 + col0 DIV - col2 FROM tab1 AS cor0
----
10
14
27

skipif mysql # not compatible
query I rowsort label-1571
SELECT ALL + 1 + col1 + col0 / - col2 FROM tab1 AS cor0
----
10
14
27

query I rowsort
SELECT DISTINCT 20 * 30 + col2 AS col2 FROM tab2 AS cor0
----
626
627
638

onlyif mysql # use DIV operator for integer division
query I rowsort label-1573
SELECT + - ( col1 ) * - col1 - - col1 DIV 45 FROM tab0 AS cor0
----
7397
8283
9411

skipif mysql # not compatible
query I rowsort label-1573
SELECT + - ( col1 ) * - col1 - - col1 / 45 FROM tab0 AS cor0
----
7397
8283
9411

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

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

query I rowsort
SELECT - + ( + 50 ) + col0 AS col1 FROM tab2 cor0
----
-43
28
29

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

query I rowsort
SELECT ( col1 ) * - col2 + 50 FROM tab0 AS cor0
----
-2788
-47
-7412

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( + 34 ) + col0 * - col0 + + cor0.col1 * col0 col0 FROM tab1 AS cor0
----
-3490
-5394
35

query I rowsort
SELECT ALL + col0 * - 55 AS col2 FROM tab1
----
-165
-3520
-4400

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

query I rowsort
SELECT DISTINCT - - 68 * 48 + - col0 FROM tab1 AS cor0
----
3184
3200
3261

query I rowsort
SELECT DISTINCT col2 * + 32 AS col1 FROM tab2 AS cor0
----
1216
832
864

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

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

query I rowsort
SELECT + ( - 89 ) + - col2 AS col2 FROM tab2 AS cor0
----
-115
-116
-127

query I rowsort
SELECT DISTINCT 54 FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
54

query I rowsort
SELECT - - col2 * col2 * + col0 + + col2 AS col2 FROM tab1 AS cor0
----
207993
737376
8802

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1590
SELECT + 86 DIV cor0.col1 + + col0 AS col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-1590
SELECT + 86 / cor0.col1 + + col0 AS col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT DISTINCT + - 29 FROM tab2 AS cor0
----
-29

onlyif mysql # use DIV operator for integer division
query I rowsort label-1592
SELECT ALL col2 * + col2 + col1 * + ( + col0 ) DIV - col0 FROM tab2 AS cor0
----
1427
617
698

skipif mysql # not compatible
query I rowsort label-1592
SELECT ALL col2 * + col2 + col1 * + ( + col0 ) / - col0 FROM tab2 AS cor0
----
1427
617
698

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

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

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

skipif mysql # not compatible
query I rowsort label-1594
SELECT + CAST ( 16 AS INTEGER ) + + col0 FROM tab2
----
23
94
95

query I rowsort
SELECT DISTINCT - col0 + - 3 AS col2 FROM tab1
----
-6
-67
-83

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( + 25 AS REAL ) + - col0 * col2 AS col2 FROM tab0
----
-10
-7273
-767

query I rowsort
SELECT DISTINCT + col1 + - col0 AS col2 FROM tab0
----
2
62

query I rowsort
SELECT DISTINCT + col2 + 6 FROM tab0
----
39
7
88

query I rowsort
SELECT 56 + col0 * 2 AS col1 FROM tab0
----
104
126
234

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

query I rowsort
SELECT ALL + 71 * col1 * + col2 + - col2 FROM tab2 AS cor0
----
108888
45828
59400

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

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

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

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

query I rowsort
SELECT DISTINCT + ( 81 ) FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
81

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

query I rowsort
SELECT col0 + tab1.col1 * - col1 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT ALL - + col0 * col2 - 72 AS col0 FROM tab1 AS cor0
----
-234
-3720
-7752

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

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

query I rowsort
SELECT ALL + cor0.col0 + 28 FROM tab1 AS cor0
----
108
31
92

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

skipif mysql # not compatible
query I rowsort label-1612
SELECT DISTINCT - col2 - - CAST ( NULL AS INTEGER ) / - col0 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - 37 * - col1 - cor0.col2 AS col2 FROM tab0 AS cor0
----
3149
3285
3588

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1614
SELECT ALL col2 * - col0 * - col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1614
SELECT ALL col2 * - col0 * - col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1615
SELECT + col1 + - tab1.col2 DIV col2 + 42 FROM tab1
----
51
54
67

skipif mysql # not compatible
query I rowsort label-1615
SELECT + col1 + - tab1.col2 / col2 + 42 FROM tab1
----
51
54
67

query I rowsort
SELECT tab2.col1 + - 21 + + col2 FROM tab2
----
34
37
64

query I rowsort
SELECT ALL - ( - col0 ) * + col2 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1618
SELECT DISTINCT ( + col1 ) DIV - col0 AS col2 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-1618
SELECT DISTINCT ( + col1 ) / - col0 AS col2 FROM tab2 AS cor0
----
-4
0

query I rowsort
SELECT DISTINCT + 19 + col2 AS col0 FROM tab2 AS cor0
----
45
46
57

query I rowsort
SELECT - - 26 + - 93 - col1 FROM tab1 AS cor0
----
-77
-80
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 41 + + col0 * col1 col1 FROM tab2
----
1302
176
4561

query I rowsort
SELECT DISTINCT tab2.col1 AS col1 FROM tab2, tab2 cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1623
SELECT DISTINCT + - CAST( NULL AS SIGNED ) * 89 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-1623
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) * 89 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT ALL 28 * - col1 - ( col0 ) FROM tab1 AS cor0
----
-344
-444
-731

query I rowsort
SELECT DISTINCT - 72 * - cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
216
4608
5760

query I rowsort
SELECT DISTINCT - + 36 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-36

query I rowsort
SELECT - + col2 + col2 + - col0 * 8 FROM tab1 AS cor0
----
-24
-512
-640

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 + col2 + col0 FROM tab0 AS cor0
----
-2781
-61
-7291

query I rowsort
SELECT ALL + 2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 49 col0 FROM tab1
----
49
49
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( 56 ) col1 FROM tab0 AS cor0
----
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1632
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - col1 + + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1632
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - col1 + + col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1633
SELECT - + col0 DIV + col1 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-1633
SELECT - + col0 / + col1 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT col0 * col1 + col2 + - col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1635
SELECT CAST( 11 AS SIGNED ) * - col0 FROM tab1
----
-33
-704
-880

skipif mysql # not compatible
query I rowsort label-1635
SELECT CAST ( 11 AS INTEGER ) * - col0 FROM tab1
----
-33
-704
-880

onlyif mysql # use DIV operator for integer division
query I rowsort label-1636
SELECT + 11 DIV cor0.col0 AS col1 FROM tab1 cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-1636
SELECT + 11 / cor0.col0 AS col1 FROM tab1 cor0
----
0
0
3

query I rowsort
SELECT - col1 + col2 + ( - col0 ) AS col1 FROM tab0 AS cor0
----
-131
-77
-98

query I rowsort
SELECT DISTINCT - 86 + + col1 AS col0 FROM tab0
----
0
11
5

query I rowsort
SELECT - tab0.col1 * + col0 + - 57 * - col0 AS col2 FROM tab0
----
-1400
-3026
-696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1640
SELECT DISTINCT + col0 + + col1 * + CAST( NULL AS SIGNED ) + 47 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-1640
SELECT DISTINCT + col0 + + col1 * + CAST ( NULL AS INTEGER ) + 47 FROM tab1
----
NULL

query I rowsort
SELECT ALL - - col1 + + col2 * + ( col0 ) FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT 55 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
55

query I rowsort
SELECT - col0 * col0 + 32 FROM tab2 AS cor0
----
-17
-6052
-6209

query I rowsort
SELECT DISTINCT - col1 * 85 AS col0 FROM tab0 AS cor0
----
-7310
-7735
-8245

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1645
SELECT col1 + CAST( NULL AS SIGNED ) * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1645
SELECT col1 + CAST ( NULL AS INTEGER ) * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * + 26 + 5 FROM tab0 AS cor0
----
2137
31
863

query I rowsort
SELECT DISTINCT + - tab0.col0 AS col0 FROM tab0, tab1, tab1 cor0
----
-24
-35
-89

query I rowsort
SELECT - 50 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - tab1.col1 col1 FROM tab1
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1650
SELECT - - CAST( + col2 AS SIGNED ) * - cor0.col0 + 9 FROM tab1 AS cor0
----
-153
-3639
-7671

skipif mysql # not compatible
query I rowsort label-1650
SELECT - - CAST ( + col2 AS INTEGER ) * - cor0.col0 + 9 FROM tab1 AS cor0
----
-153
-3639
-7671

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 43 + + col0 col0 FROM tab2 AS cor0
----
-36
35
36

query I rowsort
SELECT - col1 * col1 + col0 * col0 AS col0 FROM tab2 cor0
----
-912
2603
5952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1653
SELECT + CAST( NULL AS DECIMAL ) * - col2 - - col0 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1653
SELECT + CAST ( NULL AS REAL ) * - col2 - - col0 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1654
SELECT ALL col1 + + ( col0 ) DIV + col0 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-1654
SELECT ALL col1 + + ( col0 ) / + col0 FROM tab0
----
87
92
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col2 * col2 * ( col0 * 85 ) + col0 col1 FROM tab1
----
-17674496
-62668720
-743577

query I rowsort
SELECT + col1 + ( col1 ) AS col1 FROM tab1
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1657
SELECT DISTINCT col1 + CAST( + 68 + - col1 AS SIGNED ) * col1 AS col0 FROM tab2
----
1178
590
884

skipif mysql # not compatible
query I rowsort label-1657
SELECT DISTINCT col1 + CAST ( + 68 + - col1 AS INTEGER ) * col1 AS col0 FROM tab2
----
1178
590
884

query I rowsort
SELECT - 77 + - tab2.col2 AS col2 FROM tab2, tab1 cor0, tab1, tab1 AS cor1
----
81 values hashing to ae7f2fd6d843ef0c8a51dbf320781561

query I rowsort
SELECT 7 * + 46 AS col1 FROM tab0
----
322
322
322

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( + ( col0 ) AS REAL ) AS col2 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + + col0 col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - 13 * - ( col2 ) FROM tab2 AS cor0
----
338
351
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-1663
SELECT col1 * + col1 DIV col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1663
SELECT col1 * + col1 / col1 FROM tab0
----
86
91
97

query I rowsort
SELECT col0 * ( + col2 ) AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT col2 + - ( col0 + - col1 ) AS col1 FROM tab0
----
63
84
95

query I rowsort
SELECT ALL + 17 AS col0 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1667
SELECT + col1 * + CAST( NULL AS SIGNED ) * ( col1 + 73 ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1667
SELECT + col1 * + CAST ( NULL AS INTEGER ) * ( col1 + 73 ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * + col2 + - col2 * + col0 * + 13 FROM tab0 AS cor0
----
-102336
-13134
-552

query I rowsort
SELECT ALL + col0 * - col0 + col0 * cor0.col2 FROM tab2 AS cor0
----
-3239
-4056
140

query I rowsort
SELECT ALL col1 + ( + col0 ) * + col0 FROM tab1
----
35
4106
6413

query I rowsort
SELECT ALL - 83 AS col1 FROM tab2 AS cor0
----
-83
-83
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1672
SELECT + CAST( + 87 AS SIGNED ) + + col0 AS col1 FROM tab1 AS cor0
----
151
167
90

skipif mysql # not compatible
query I rowsort label-1672
SELECT + CAST ( + 87 AS INTEGER ) + + col0 AS col1 FROM tab1 AS cor0
----
151
167
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1673
SELECT DISTINCT CAST( + col1 AS SIGNED ) * col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-1673
SELECT DISTINCT CAST ( + col1 AS INTEGER ) * col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - + 10 + ( - cor0.col2 ) - - 47 FROM tab2 AS cor0
----
-1
10
11

query I rowsort
SELECT DISTINCT + col2 * + 38 + - col0 FROM tab0 AS cor0
----
1230
3
3027

query I rowsort
SELECT DISTINCT 80 AS col1 FROM tab0, tab0 AS cor0
----
80

query I rowsort
SELECT DISTINCT - ( - ( + col0 ) ) + 17 * 7 FROM tab2 cor0
----
126
197
198

query I rowsort
SELECT - col1 * - col2 + col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT ALL + ( + ( + col2 ) ) + - col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL ( + col0 ) * - col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT ( cor0.col2 ) * + col1 - - col0 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1682
SELECT + - CAST( NULL AS SIGNED ) + 9 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1682
SELECT + - CAST ( NULL AS INTEGER ) + 9 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1683
SELECT ALL + col1 * + col1 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1683
SELECT ALL + col1 * + 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-1684
SELECT ALL + cor0.col1 * col0 * - CAST( NULL AS SIGNED ) + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1684
SELECT ALL + cor0.col1 * col0 * - CAST ( NULL AS INTEGER ) + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * col2 + + col2 * + col1 col1 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT DISTINCT - cor0.col0 + - ( - col2 ) * col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT - cor0.col2 * col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - 0 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - cor1.col1 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
-86
-91
-97

query I rowsort
SELECT + col2 * + tab1.col0 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT + 51 * - cor1.col2 AS col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
-1326
-1377
-1938

query I rowsort
SELECT ALL + 60 * col0 FROM tab1
----
180
3840
4800

query I rowsort
SELECT ALL - - col1 * - col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT - col0 + ( + 56 ) AS col2 FROM tab0 AS cor0
----
-33
21
32

query I rowsort
SELECT ALL + col1 + col0 * - 20 AS col1 FROM tab2 AS cor0
----
-109
-1501
-1563

query I rowsort
SELECT DISTINCT + col2 * + 81 FROM tab1 AS cor0
----
4374
4617
7776

query I rowsort
SELECT DISTINCT col0 * + 36 * - col1 AS col2 FROM tab0 AS cor0
----
-122220
-291564
-74304

query I rowsort
SELECT + col0 * cor0.col2 - col2 AS col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL - + col2 * - ( + cor0.col0 ) + + col2 * col1 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT DISTINCT - + col1 + + col1 * - col0 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL - col0 + + col2 AS col1 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT col0 * col2 + col1 AS col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT - cor0.col0 + + col0 * col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT ALL - col2 * ( 58 * + col1 ) AS col1 FROM tab2 AS cor0
----
-37468
-48546
-88972

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1705
SELECT ALL - col0 * CAST( NULL AS SIGNED ) + - col2 * - col1 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1705
SELECT ALL - col0 * CAST ( NULL AS INTEGER ) + - col2 * - col1 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1706
SELECT col1 * ( - 61 ) + - col0 DIV 75 FROM tab2 AS cor0
----
-1038
-1891
-3600

skipif mysql # not compatible
query I rowsort label-1706
SELECT col1 * ( - 61 ) + - col0 / 75 FROM tab2 AS cor0
----
-1038
-1891
-3600

query I rowsort
SELECT DISTINCT + 53 AS col2 FROM tab2
----
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + 78 col0 FROM tab2 AS cor0
----
104
105
116

query I rowsort
SELECT + col1 * - col2 - + cor0.col1 * - col0 FROM tab2 AS cor0
----
-620
3068
697

query I rowsort
SELECT DISTINCT + 30 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-1711
SELECT col0 DIV + ( + col1 ) + 15 DIV - col1 + + col0 FROM tab2 cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-1711
SELECT col0 / + ( + col1 ) + 15 / - col1 + + col0 FROM tab2 cor0
----
7
79
83

query I rowsort
SELECT col0 + tab0.col2 + ( - col2 ) AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT 80 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

onlyif mysql # use DIV operator for integer division
query I rowsort label-1714
SELECT + ( + tab2.col1 ) DIV + tab2.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-1714
SELECT + ( + tab2.col1 ) / + tab2.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT DISTINCT col0 * col0 * + tab0.col1 AS col0 FROM tab0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-1716
SELECT ALL col2 + - col2 DIV - col1 - - col0 AS col0 FROM tab2 AS cor0
----
104
119
34

skipif mysql # not compatible
query I rowsort label-1716
SELECT ALL col2 + - col2 / - col1 - - col0 AS col0 FROM tab2 AS cor0
----
104
119
34

query I rowsort
SELECT DISTINCT - + col2 + cor0.col0 * - col2 FROM tab0 cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT cor0.col0 - 56 AS col2 FROM tab1, tab1 AS cor0
----
-53
24
8

query I rowsort
SELECT 22 * col0 + + 6 AS col1 FROM tab2
----
160
1722
1744

query I rowsort
SELECT + 52 + - col2 * ( col2 ) AS col0 FROM tab2
----
-1392
-624
-677

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1721
SELECT ALL col0 * + col0 + - CAST( - col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
35
4106
6413

skipif mysql # not compatible
query I rowsort label-1721
SELECT ALL col0 * + col0 + - CAST ( - col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
35
4106
6413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1722
SELECT DISTINCT - col2 * col0 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1722
SELECT DISTINCT - col2 * col0 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col0 * col2 * 45 - - 26 AS col2 FROM tab2 AS cor0
----
135116
8531
91286

query I rowsort
SELECT ALL + col1 + - col0 * 71 FROM tab2 AS cor0
----
-466
-5479
-5592

query I rowsort
SELECT DISTINCT 57 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
57

query I rowsort
SELECT - ( - col2 ) * ( - col1 ) AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - cor0.col1 + - col1 AS col0 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT - 26 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-2236
-2366
-2522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 92 col2 FROM tab2
----
-92
-92
-92

query I rowsort
SELECT tab2.col1 * + ( col0 * - col1 ) AS col0 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT ALL + col2 + 84 FROM tab2
----
110
111
122

query I rowsort
SELECT + ( col2 ) + - col2 * col2 AS col0 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ( - col2 ) - col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT col0 + cor0.col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - col1 + - 33 FROM tab2 AS cor0
----
-50
-64
-92

query I rowsort
SELECT DISTINCT - col2 * + 63 AS col1 FROM tab2 cor0
----
-1638
-1701
-2394

query I rowsort
SELECT ( + ( - col1 ) ) * + ( col0 ) - + col2 AS col1 FROM tab0 cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - 59 FROM tab0, tab2 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 2d947a91062cb6f04dae4c2cd8f99509

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1739
SELECT + CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1739
SELECT + CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * cor0.col0 + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-1741
SELECT col1 DIV - col1 + cor0.col1 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-1741
SELECT col1 / - col1 + cor0.col1 FROM tab2 AS cor0
----
16
30
58

query I rowsort
SELECT DISTINCT 92 - col1 AS col0 FROM tab1
----
66
79
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 98 + tab0.col1 * - col0 - 4 col1 FROM tab0
----
-1970
-3301
-8005

onlyif mysql # use DIV operator for integer division
query I rowsort label-1744
SELECT 47 DIV 85 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1744
SELECT 47 / 85 FROM tab1
----
0
0
0

query I rowsort
SELECT - col0 * + tab2.col0 + + tab2.col2 AS col2 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT + ( col1 ) * + col1 * + col0 + + col1 FROM tab2 AS cor0
----
22848
271577
6758

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 * - col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT 41 * 19 + - cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 982d17f1fd6e1d5d1080c2c0c99091ea

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 79 + + col2 * col2 * cor0.col1 col0 FROM tab2 AS cor0
----
22678
24627
39963

query I rowsort
SELECT - col2 + - col0 * 17 AS col2 FROM tab1
----
-105
-1145
-1456

skipif mysql # not compatible
query I rowsort
SELECT - col1 * - CAST ( 68 AS REAL ) AS col1 FROM tab1 AS cor0
----
1768
680
884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 19 col0 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to 39241ace4c29d5a55052e1665aa36823

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
10
13
26

query I rowsort
SELECT col0 * - 44 FROM tab2 AS cor0
----
-308
-3432
-3476

query I rowsort
SELECT DISTINCT - 65 * - 71 AS col2 FROM tab1 AS cor0
----
4615

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1756
SELECT DISTINCT + + ( - 54 ) + col0 / - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1756
SELECT DISTINCT + + ( - 54 ) + col0 / - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 70 FROM tab2 cor0
----
70

query I rowsort
SELECT DISTINCT + ( 10 ) FROM tab0 AS cor0
----
10

query I rowsort
SELECT + - col1 * + 64 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
-1610
-583
-736

query I rowsort
SELECT - + col0 * + col0 * col2 AS col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - - col0 - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - 71 * col1 FROM tab1 AS cor0
----
-1846
-710
-923

query I rowsort
SELECT ALL - col2 + - ( + col1 ) AS col2 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT col1 * - 44 FROM tab0 AS cor0
----
-3784
-4004
-4268

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1765
SELECT - + col2 + CAST( + 77 + - col0 AS SIGNED ) FROM tab2 AS cor0
----
-27
-40
43

skipif mysql # not compatible
query I rowsort label-1765
SELECT - + col2 + CAST ( + 77 + - col0 AS INTEGER ) FROM tab2 AS cor0
----
-27
-40
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + col1 * - col0 col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - col0 * + 9 FROM tab2 cor0
----
-63
-702
-711

query I rowsort
SELECT + 82 * + col0 * ( + col1 + tab1.col1 ) AS col0 FROM tab1
----
104960
12792
170560

query I rowsort
SELECT + col2 - + col1 * col0 FROM tab2
----
-1305
-190
-4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1770
SELECT DISTINCT - col2 * + CAST( col1 AS SIGNED ) + col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-1770
SELECT DISTINCT - col2 * + CAST ( col1 AS INTEGER ) + col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT tab1.col1 + - 81 AS col0 FROM tab1
----
-55
-68
-71

query I rowsort
SELECT tab1.col0 + ( col0 ) AS col0 FROM tab1
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-1773
SELECT - col0 + col2 DIV + col1 AS col2 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1773
SELECT - col0 + col2 / + col1 AS col2 FROM tab0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1774
SELECT ALL - col0 * + CAST( NULL AS SIGNED ) + 93 * - col0 + col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1774
SELECT ALL - col0 * + CAST ( NULL AS INTEGER ) + 93 * - col0 + col1 AS col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1775
SELECT col1 + - col2 + 10 DIV col1 AS col2 FROM tab0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-1775
SELECT col1 + - col2 + 10 / col1 AS col2 FROM tab0
----
53
9
96

query I rowsort
SELECT ALL col1 + + 87 + 82 AS col2 FROM tab2
----
186
200
228

query I rowsort
SELECT DISTINCT col1 * - ( - cor0.col1 ) + - col2 AS col2 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT ALL - col2 - 29 AS col2 FROM tab0 AS cor0
----
-111
-30
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1779
SELECT DISTINCT + col2 DIV CAST( 38 AS SIGNED ) FROM tab0 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-1779
SELECT DISTINCT + col2 / CAST ( 38 AS INTEGER ) FROM tab0 AS cor0
----
0
2

query I rowsort
SELECT col1 + + col1 - col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + col2 + - col2 * - 49 AS col1 FROM tab1
----
2700
2850
4800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1782
SELECT DISTINCT tab2.col0 + CAST( NULL AS DECIMAL ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-1782
SELECT DISTINCT tab2.col0 + CAST ( NULL AS REAL ) FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT - col1 + cor0.col0 + + col2 FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT - col2 - 70 AS col0 FROM tab0 AS cor0
----
-103
-152
-71

query I rowsort
SELECT DISTINCT - + 24 + + col0 * - col1 AS col1 FROM tab0 AS cor0
----
-2088
-3419
-8123

query I rowsort
SELECT - ( 17 ) FROM tab0
----
-17
-17
-17

query I rowsort
SELECT col1 + 94 FROM tab1
----
104
107
120

query I rowsort
SELECT DISTINCT col1 + + col1 + + col0 * + 76 FROM tab0 AS cor0
----
1996
2854
6946

query I rowsort
SELECT ALL cor0.col0 * col0 + 81 AS col1 FROM tab2 cor0
----
130
6165
6322

query I rowsort
SELECT - 35 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 6d967b3bac2e01a0318865f682f9a97b

query I rowsort
SELECT DISTINCT 72 * cor0.col2 FROM tab2 AS cor0
----
1872
1944
2736

query I rowsort
SELECT DISTINCT + + col2 - - cor0.col1 AS col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1793
SELECT DISTINCT col0 - col2 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-1793
SELECT DISTINCT col0 - col2 / cor0.col0 AS col2 FROM tab2 AS cor0
----
4
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col2 ) * 99 col2 FROM tab2
----
-2574
-2673
-3762

onlyif mysql # use DIV operator for integer division
query I rowsort label-1795
SELECT ALL 94 DIV col1 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
6
73
87

skipif mysql # not compatible
query I rowsort label-1795
SELECT ALL 94 / col1 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
6
73
87

query I rowsort
SELECT DISTINCT - col0 * - tab0.col2 * col0 AS col1 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT - col0 * col2 * + 19 AS col2 FROM tab0 AS cor0
----
-138662
-15048
-665

onlyif mysql # use DIV operator for integer division
query I rowsort label-1798
SELECT ALL - - 87 DIV + col1 AS col2 FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-1798
SELECT ALL - - 87 / + col1 AS col2 FROM tab1 AS cor0
----
3
6
8

query I rowsort
SELECT ALL - - cor0.col0 * - ( col1 ) AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + + col0 + + 37 AS col1 FROM tab2 AS cor0
----
115
116
44

query I rowsort
SELECT DISTINCT - cor0.col2 + - 37 * 47 - cor0.col1 * col0 AS col2 FROM tab2 AS cor0
----
-1983
-3120
-6367

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col2 * - col1 - col2 col2 FROM tab2 AS cor0
----
22572
24510
39858

query I rowsort
SELECT DISTINCT - col2 - + ( col2 ) * - col0 AS col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT - + col2 + 51 + ( + col1 ) AS col2 FROM tab0 AS cor0
----
104
147
60

query I rowsort
SELECT ALL - col2 * - col0 * col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT ALL 9 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

query I rowsort
SELECT - col2 + - col2 * col1 FROM tab0 AS cor0
----
-2871
-7544
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( + col1 ) col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL col1 * 90 AS col0 FROM tab0 AS cor0
----
7740
8190
8730

query I rowsort
SELECT - + 87 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-61
-74
-77

query I rowsort
SELECT DISTINCT + 40 + + col1 AS col1 FROM tab1 AS cor0
----
50
53
66

query I rowsort
SELECT ALL - col0 * + col2 + - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-1813
SELECT - + 91 DIV - ( col1 ) AS col2 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-1813
SELECT - + 91 / - ( col1 ) AS col2 FROM tab0 AS cor0
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1814
SELECT - cor0.col1 / col0 + col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1814
SELECT - cor0.col1 / col0 + col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + 76 * - col0 FROM tab2 AS cor0
----
-539
-6006
-6083

query I rowsort
SELECT ALL - col1 + - col2 * col1 AS col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT col1 + 31 * col1 FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT DISTINCT + 85 * + col0 * - col0 AS col1 FROM tab2 AS cor0
----
-4165
-517140
-530485

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1819
SELECT - CAST( + col2 AS SIGNED ) + col2 AS col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1819
SELECT - CAST ( + col2 AS INTEGER ) + col2 AS col0 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1820
SELECT DISTINCT + 7 + + col2 DIV - col1 + 50 DIV - col2 FROM tab1 AS cor0
----
0
2
5

skipif mysql # not compatible
query I rowsort label-1820
SELECT DISTINCT + 7 + + col2 / - col1 + 50 / - col2 FROM tab1 AS cor0
----
0
2
5

query I rowsort
SELECT - col0 * - ( cor0.col2 ) + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - 57 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT cor1.col1 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT - ( - ( + col2 ) + 15 ) FROM tab0
----
-14
18
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1825
SELECT CAST( NULL AS SIGNED ) * - ( + col1 ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1825
SELECT CAST ( NULL AS INTEGER ) * - ( + col1 ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 * ( col2 * + col0 + ( - 55 ) ) FROM tab0 AS cor0
----
-700
17688
644627

query I rowsort
SELECT + cor0.col0 + - 50 + - col2 FROM tab1 cor0
----
-101
-43
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1828
SELECT DISTINCT - col0 * CAST( NULL AS SIGNED ) + col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1828
SELECT DISTINCT - col0 * CAST ( NULL AS INTEGER ) + col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT col2 * + 63 AS col0 FROM tab1 AS cor0
----
3402
3591
6048

query I rowsort
SELECT - col2 * col0 - 26 * - col1 AS col2 FROM tab2 cor0
----
-2560
-494
617

onlyif mysql # use DIV operator for integer division
query I rowsort label-1831
SELECT col1 * + col0 + ( - col1 ) DIV + col0 AS col1 FROM tab2 AS cor0
----
1343
213
4602

skipif mysql # not compatible
query I rowsort label-1831
SELECT col1 * + col0 + ( - col1 ) / + col0 AS col1 FROM tab2 AS cor0
----
1343
213
4602

query I rowsort
SELECT - col0 + - ( + 18 ) AS col0 FROM tab0 AS cor0
----
-107
-42
-53

query I rowsort
SELECT col0 - 31 FROM tab1 cor0
----
-28
33
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1834
SELECT - + CAST( NULL AS SIGNED ) + - col0 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1834
SELECT - + CAST ( NULL AS INTEGER ) + - col0 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * + ( 19 ) FROM tab2
----
1121
323
589

query I rowsort
SELECT DISTINCT - col2 * + 85 AS col2 FROM tab2
----
-2210
-2295
-3230

query I rowsort
SELECT + col1 * + 15 * + ( col2 ) AS col1 FROM tab1
----
18720
21060
8550

query I rowsort
SELECT 42 * tab0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 24522a847b44e4ab85b1227024816378

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL + 65 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 1654646feeae82f39d2f564fe4ea26c2

onlyif mysql # use DIV operator for integer division
query I rowsort label-1841
SELECT - tab2.col1 DIV tab2.col1 AS col1 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1841
SELECT - tab2.col1 / tab2.col1 AS col1 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT - 17 + col1 + col2 * col0 FROM tab1
----
171
3641
7676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col0 + 37 + - tab2.col2 col1 FROM tab2
----
-179
-2017
-3003

query I rowsort
SELECT DISTINCT col2 * col2 + - 35 AS col0 FROM tab1 cor0
----
2881
3214
9181

query I rowsort
SELECT DISTINCT - - 77 * - col0 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1824
-2660
-6764

query I rowsort
SELECT - 35 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 6d967b3bac2e01a0318865f682f9a97b

query I rowsort
SELECT cor1.col1 AS col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col1 + + col0 col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - + col1 + 37 AS col1 FROM tab1 AS cor0
----
11
24
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-1850
SELECT col2 + col2 DIV + col1 AS col0 FROM tab1
----
103
56
62

skipif mysql # not compatible
query I rowsort label-1850
SELECT col2 + col2 / + col1 AS col0 FROM tab1
----
103
56
62

query I rowsort
SELECT ALL - 68 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query I rowsort
SELECT DISTINCT col2 - ( tab1.col0 ) FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL col2 - tab2.col2 AS col0 FROM tab2
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1854
SELECT ALL col1 - + ( col2 + - col0 * CAST( col2 AS SIGNED ) ) FROM tab0
----
131
7307
845

skipif mysql # not compatible
query I rowsort label-1854
SELECT ALL col1 - + ( col2 + - col0 * CAST ( col2 AS INTEGER ) ) FROM tab0
----
131
7307
845

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1855
SELECT CAST( NULL AS DECIMAL ) * + 27 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1855
SELECT CAST ( NULL AS REAL ) * + 27 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1856
SELECT DISTINCT col1 - 75 DIV - 19 AS col0 FROM tab1
----
13
16
29

skipif mysql # not compatible
query I rowsort label-1856
SELECT DISTINCT col1 - 75 / - 19 AS col0 FROM tab1
----
13
16
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1857
SELECT col2 * CAST( + col1 AS SIGNED ) - col2 FROM tab0 cor0
----
2805
7380
96

skipif mysql # not compatible
query I rowsort label-1857
SELECT col2 * CAST ( + col1 AS INTEGER ) - col2 FROM tab0 cor0
----
2805
7380
96

query I rowsort
SELECT + col0 * + ( - col0 ) - + col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT + cor0.col1 + + ( + col0 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT col2 - 64 AS col0 FROM tab0 AS cor0
----
-31
-63
18

query I rowsort
SELECT + + col0 * - col0 - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT ALL ( tab2.col0 + - col1 ) * + ( - tab2.col2 ) AS col0 FROM tab2
----
-2356
-494
648

query I rowsort
SELECT ( 30 * col0 ) AS col2 FROM tab0
----
1050
2670
720

query I rowsort
SELECT - tab2.col2 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT - cor0.col1 * + ( + col0 ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT 23 - tab1.col2 AS col2 FROM tab1
----
-31
-34
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-1867
SELECT DISTINCT + 10 DIV col0 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-1867
SELECT DISTINCT + 10 / col0 FROM tab2
----
0
1

query I rowsort
SELECT col1 * - col0 * + col0 AS col1 FROM tab1 cor0
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 45 * cor0.col0 col1 FROM tab2 AS cor0
----
-315
-3510
-3555

query I rowsort
SELECT - col1 * + col0 AS col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - - col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + + cor0.col2 + + col2 * col0 AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL 74 + + col1 * + col1 FROM tab0 cor0
----
7470
8355
9483

query I rowsort
SELECT ALL col0 * 49 AS col0 FROM tab0
----
1176
1715
4361

query I rowsort
SELECT DISTINCT - 33 + + ( col1 + + 17 ) AS col2 FROM tab1 AS cor0
----
-3
-6
10

query I rowsort
SELECT DISTINCT col2 + col2 + - col2 * + col0 AS col2 FROM tab0 AS cor0
----
-33
-7134
-726

onlyif mysql # use DIV operator for integer division
query I rowsort label-1877
SELECT + col0 DIV + 79 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1877
SELECT + col0 / + 79 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + - col0 * - col1 + col1 * cor0.col0 * + col1 FROM tab1 AS cor0
----
14560
2106
7040

query I rowsort
SELECT DISTINCT - cor0.col1 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab2 AS cor2
----
-86
-91
-97

query I rowsort
SELECT ALL - ( + col2 ) * + col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - ( ( + col0 ) ) FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - ( - col2 ) + cor0.col1 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
24
35
89

query I rowsort
SELECT - 5 * cor0.col0 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 99739a943df8f41edddb2227d2e0ae79

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to dd5ce24448edb4b3ab62c251475d6548

onlyif mysql # use DIV operator for integer division
query I rowsort label-1886
SELECT DISTINCT + col0 + - col1 DIV - col2 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-1886
SELECT DISTINCT + col0 + - col1 / - col2 FROM tab0 AS cor0
----
132
26
90

query I rowsort
SELECT ALL 98 * + cor0.col2 + col1 + col2 FROM tab2 AS cor0
----
2633
2704
3779

query I rowsort
SELECT ALL + - ( - cor0.col0 ) * + col0 + 17 * cor0.col2 AS col2 FROM tab0 AS cor0
----
1137
1242
9315

query I rowsort
SELECT ALL 51 - + col0 * - col2 * col0 AS col1 FROM tab0
----
1276
19059
649573

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1890
SELECT CAST( NULL AS SIGNED ) / col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1890
SELECT CAST ( NULL AS INTEGER ) / col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1891
SELECT 34 + col0 DIV col2 FROM tab1 AS cor0
----
34
34
35

skipif mysql # not compatible
query I rowsort label-1891
SELECT 34 + col0 / col2 FROM tab1 AS cor0
----
34
34
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col2 + col1 col2 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT ALL + - col0 + + col1 * col2 FROM tab1 AS cor0
----
1168
1401
506

onlyif mysql # use DIV operator for integer division
query I rowsort label-1894
SELECT - ( + col2 ) * - ( + ( + col0 ) ) - col0 DIV + col0 FROM tab1 cor0
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-1894
SELECT - ( + col2 ) * - ( + ( + col0 ) ) - col0 / + col0 FROM tab1 cor0
----
161
3647
7679

query I rowsort
SELECT ALL - col2 + - cor0.col1 * col1 AS col1 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT DISTINCT + col1 * - 6 * + col1 + cor0.col2 FROM tab0 AS cor0
----
-44343
-49604
-56453

query I rowsort
SELECT ALL - col0 + + 81 FROM tab2 cor0
----
2
3
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-1898
SELECT + col1 DIV - 81 + col1 * + col0 FROM tab0 cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-1898
SELECT + col1 / - 81 + col1 * + col0 FROM tab0 cor0
----
2063
3394
8098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * col2 col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-1900
SELECT + col1 DIV + 18 + col0 col2 FROM tab2 AS cor0
----
79
8
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1900
SELECT + col1 / + 18 + col0 col2 FROM tab2 AS cor0
----
79
8
81

query I rowsort
SELECT ALL cor0.col1 + col1 + + 24 AS col1 FROM tab1 AS cor0
----
44
50
76

query I rowsort
SELECT DISTINCT + - col1 * + 50 + col1 FROM tab0 AS cor0
----
-4214
-4459
-4753

query I rowsort
SELECT + - col1 + + 41 AS col0 FROM tab1 AS cor0
----
15
28
31

query I rowsort
SELECT ALL - - col0 * - col0 + col2 * - col2 + + 96 AS col1 FROM tab0 AS cor0
----
-1130
-14549
-1569

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 + - 54 col0 FROM tab2 AS cor0
----
-16
-27
-28

query I rowsort
SELECT DISTINCT cor0.col2 * cor0.col0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1907
SELECT ALL - + col1 * - CAST( NULL AS SIGNED ) + + col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1907
SELECT ALL - + col1 * - CAST ( NULL AS INTEGER ) + + col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 66 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT + col0 + 64 AS col2 FROM tab2 cor0
----
142
143
71

query I rowsort
SELECT DISTINCT ( col1 ) - col2 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + col2 + + col2 * + cor0.col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT - col2 + col1 - + col1 * + ( + col1 ) AS col0 FROM tab0 AS cor0
----
-7343
-8272
-9313

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 50 col0 FROM tab2 AS cor0
----
50
50
50

query I rowsort
SELECT + 72 FROM tab2, tab1 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to e1618abfe12be6a950cc575d695639b7

query I rowsort
SELECT ALL + + cor0.col2 + + 55 * + col0 AS col0 FROM tab2 AS cor0
----
412
4316
4383

query I rowsort
SELECT DISTINCT - - col0 + ( + col1 ) * 55 FROM tab2 AS cor0
----
1014
1712
3323

query I rowsort
SELECT DISTINCT + + col1 + + 49 * cor0.col1 FROM tab1 AS cor0
----
1300
500
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 21 * 21 col0 FROM tab2 cor0
----
-441

onlyif mysql # use DIV operator for integer division
query I rowsort label-1919
SELECT ALL col1 DIV 9 FROM tab2 AS cor0
----
1
3
6

skipif mysql # not compatible
query I rowsort label-1919
SELECT ALL col1 / 9 FROM tab2 AS cor0
----
1
3
6

query I rowsort
SELECT DISTINCT 76 AS col1 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
76

query I rowsort
SELECT ALL - 81 + + col0 AS col0 FROM tab0 AS cor0
----
-46
-57
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-1922
SELECT DISTINCT 67 DIV - col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1922
SELECT DISTINCT 67 / - col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - - 52 FROM tab2 AS cor0
----
52

query I rowsort
SELECT DISTINCT - 33 * + col1 FROM tab0 AS cor0
----
-2838
-3003
-3201

query I rowsort
SELECT + + 83 + col2 AS col0 FROM tab1 cor0
----
137
140
179

query I rowsort
SELECT ALL - col0 * + col2 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - - cor0.col1 + col1 * - col2 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - cor0.col1 + + col2 + 67 AS col0 FROM tab0 AS cor0
----
-29
14
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-1929
SELECT DISTINCT col0 DIV - col2 col1 FROM tab1 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1929
SELECT DISTINCT col0 / - col2 col1 FROM tab1 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 + cor0.col2 col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - - 33 + + col2 AS col2 FROM tab0 AS cor0
----
115
34
66

query I rowsort
SELECT ALL + - 6 AS col0 FROM tab2 AS cor0
----
-6
-6
-6

query I rowsort
SELECT DISTINCT - ( col0 ) * 90 AS col0 FROM tab1 AS cor0
----
-270
-5760
-7200

query I rowsort
SELECT ALL col0 * 97 AS col2 FROM tab2 cor0
----
679
7566
7663

query I rowsort
SELECT DISTINCT + cor2.col1 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
86
91
97

query I rowsort
SELECT ALL 39 - cor0.col2 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1, tab0 AS cor2
----
243 values hashing to 9439acbea8f42ba1c632ac83f479a8fc

query I rowsort
SELECT DISTINCT ( - col1 ) + ( + col2 * col2 ) FROM tab1
----
2890
3239
9203

query I rowsort
SELECT - + 75 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 258bc565c64924d905a55eaaa6e57547

onlyif mysql # use DIV operator for integer division
query I rowsort label-1939
SELECT ALL + col1 + col1 DIV + tab0.col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-1939
SELECT ALL + col1 + col1 / + tab0.col1 FROM tab0
----
87
92
98

query I rowsort
SELECT ( cor0.col1 ) * + 31 FROM tab2, tab2 AS cor0
----
9 values hashing to 179d7d13fa2c122214a4dbfbba68603d

query I rowsort
SELECT - ( col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 * - col1 col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT - - cor0.col0 * - cor0.col2 + 72 FROM tab0 AS cor0
----
-720
-7226
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col1 col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - col2 * - col1 + col2 + col0 FROM tab1
----
1424
1461
691

query I rowsort
SELECT + - 52 + col2 FROM tab2 AS cor0
----
-14
-25
-26

query I rowsort
SELECT ALL + 38 * col0 * + 74 + 32 FROM tab0 AS cor0
----
250300
67520
98452

query I rowsort
SELECT col1 * col0 + + col2 + col2 * - col2 FROM tab2 AS cor0
----
-485
-63
3952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor1.col0 col1 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT + 11 + col1 AS col0 FROM tab0 AS cor0
----
102
108
97

query I rowsort
SELECT - - ( + 73 ) * cor0.col1 AS col0 FROM tab1 AS cor0
----
1898
730
949

onlyif mysql # use DIV operator for integer division
query I rowsort label-1952
SELECT - 79 DIV + col2 AS col1 FROM tab0 AS cor0
----
-2
-79
0

skipif mysql # not compatible
query I rowsort label-1952
SELECT - 79 / + col2 AS col1 FROM tab0 AS cor0
----
-2
-79
0

query I rowsort
SELECT ALL col0 + 73 FROM tab0 AS cor0
----
108
162
97

query I rowsort
SELECT - 49 * - col1 AS col0 FROM tab0 AS cor0
----
4214
4459
4753

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 9 col0 FROM tab2 AS cor0
----
-9
-9
-9

query I rowsort
SELECT - cor0.col2 + 73 FROM tab1 AS cor0
----
-23
16
19

query I rowsort
SELECT DISTINCT 20 * + col1 * - cor0.col2 FROM tab0 AS cor0
----
-149240
-1940
-56760

query I rowsort
SELECT DISTINCT 15 * col0 AS col0 FROM tab1 AS cor0
----
1200
45
960

query I rowsort
SELECT ALL - 36 + col1 AS col2 FROM tab2 AS cor0
----
-19
-5
23

query I rowsort
SELECT ALL - - cor0.col1 + + col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - col0 * col1 + - col1 * cor0.col0 FROM tab2 cor0
----
-2686
-434
-9204

query I rowsort
SELECT ALL 93 * col0 + col1 FROM tab1 AS cor0
----
305
5962
7453

query I rowsort
SELECT DISTINCT + 36 + - cor0.col1 FROM tab1 AS cor0
----
10
23
26

query I rowsort
SELECT ALL ( - 51 ) AS col2 FROM tab2
----
-51
-51
-51

query I rowsort
SELECT ALL cor0.col1 + + col1 * + 17 * col0 - + col2 FROM tab0 AS cor0
----
137692
35141
57811

query I rowsort
SELECT DISTINCT - col2 + + col1 * col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT + - 5 FROM tab2 cor0
----
-5

query I rowsort
SELECT - + col0 * + col2 + col1 AS col1 FROM tab2 AS cor0
----
-158
-1969
-2985

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 + col0 + + 97 FROM tab0 AS cor0
----
121
132
186

query I rowsort
SELECT ALL - 69 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

query I rowsort
SELECT DISTINCT col1 * + col2 + tab2.col2 + - col0 AS col0 FROM tab2
----
1482
605
857

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * + col2 - ( tab1.col2 ) col1 FROM tab1
----
1152
1350
513

query I rowsort
SELECT ALL + col1 + 82 FROM tab2
----
113
141
99

query I rowsort
SELECT - col0 + col2 * - tab1.col1 AS col2 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT + col1 + + col2 * 87 AS col0 FROM tab1
----
4724
4969
8365

query I rowsort
SELECT - col0 * 38 FROM tab2 AS cor0
----
-266
-2964
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1978
SELECT DISTINCT col1 DIV tab2.col0 + col0 AS col1 FROM tab2
----
11
78
79

skipif mysql # not compatible
query I rowsort label-1978
SELECT DISTINCT col1 / tab2.col0 + col0 AS col1 FROM tab2
----
11
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1979
SELECT col0 + col1 DIV ( col0 ) FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-1979
SELECT col0 + col1 / ( col0 ) FROM tab0
----
27
37
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1980
SELECT col2 DIV col1 + - ( col1 + - col2 ) AS col2 FROM tab0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-1980
SELECT col2 / col1 + - ( col1 + - col2 ) AS col2 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ALL 98 + + 17 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8ea29c11e2d920a09e8656cafe5a9642

query I rowsort
SELECT + 94 + + col2 AS col0 FROM tab0
----
127
176
95

query I rowsort
SELECT DISTINCT 50 + col1 AS col0 FROM tab0 AS cor0
----
136
141
147

query I rowsort
SELECT ALL + + cor0.col2 * - col2 * + 13 AS col1 FROM tab2 AS cor0
----
-18772
-8788
-9477

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - col1 + 24 col1 FROM tab2 AS cor0
----
-1510
-622
-813

onlyif mysql # use DIV operator for integer division
query I rowsort label-1986
SELECT col2 + col1 DIV - ( cor0.col1 ) + col2 AS col0 FROM tab2 AS cor0
----
51
53
75

skipif mysql # not compatible
query I rowsort label-1986
SELECT col2 + col1 / - ( cor0.col1 ) + col2 AS col0 FROM tab2 AS cor0
----
51
53
75

query I rowsort
SELECT 19 * col1 + col1 AS col1 FROM tab0 AS cor0
----
1720
1820
1940

onlyif mysql # use DIV operator for integer division
query I rowsort label-1988
SELECT ALL + + col2 * - 29 + 46 * + cor0.col0 DIV - col0 AS col2 FROM tab0 AS cor0
----
-1003
-2424
-75

skipif mysql # not compatible
query I rowsort label-1988
SELECT ALL + + col2 * - 29 + 46 * + cor0.col0 / - col0 AS col2 FROM tab0 AS cor0
----
-1003
-2424
-75

query I rowsort
SELECT ALL - - col0 - col1 * - ( col0 ) * cor0.col0 FROM tab1 cor0
----
237
41024
83280

onlyif mysql # use DIV operator for integer division
query I rowsort label-1990
SELECT ALL col0 DIV - cor0.col2 + - 7 AS col2 FROM tab0 AS cor0
----
-42
-7
-8

skipif mysql # not compatible
query I rowsort label-1990
SELECT ALL col0 / - cor0.col2 + - 7 AS col2 FROM tab0 AS cor0
----
-42
-7
-8

query I rowsort
SELECT DISTINCT col0 * - 24 AS col2 FROM tab2 AS cor0
----
-168
-1872
-1896

onlyif mysql # use DIV operator for integer division
query I rowsort label-1992
SELECT DISTINCT - + col1 DIV ( col1 ) + + col2 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-1992
SELECT DISTINCT - + col1 / ( col1 ) + + col2 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT DISTINCT cor0.col1 * 41 FROM tab2, tab2 AS cor0
----
1271
2419
697

query I rowsort
SELECT DISTINCT + + col0 * col1 + col2 * col2 FROM tab1 AS cor0
----
10256
2994
3889

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 39 col1 FROM tab2 AS cor0
----
273
3042
3081

query I rowsort
SELECT DISTINCT - 24 * + col0 FROM tab2 cor0
----
-168
-1872
-1896

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1997
SELECT DISTINCT - + CAST( - 13 AS SIGNED ) col1 FROM tab0 AS cor0
----
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1997
SELECT DISTINCT - + CAST ( - 13 AS INTEGER ) col1 FROM tab0 AS cor0
----
13

query I rowsort
SELECT 97 - col2 * + cor0.col1 * - col2 FROM tab2 AS cor0
----
22696
24645
39981

query I rowsort
SELECT DISTINCT - - 44 + - col1 AS col2 FROM tab2 AS cor0
----
-15
13
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-2000
SELECT tab2.col0 + col1 DIV - col1 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-2000
SELECT tab2.col0 + col1 / - col1 FROM tab2
----
6
77
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2001
SELECT - CAST( col2 + + col1 AS SIGNED ) FROM tab0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-2001
SELECT - CAST ( col2 + + col1 AS INTEGER ) FROM tab0
----
-119
-173
-98

query I rowsort
SELECT 1 + tab2.col0 + + col0 AS col0 FROM tab2
----
15
157
159

onlyif mysql # use DIV operator for integer division
query I rowsort label-2003
SELECT + col2 DIV + tab0.col2 + - col0 AS col2 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-2003
SELECT + col2 / + tab0.col2 + - col0 AS col2 FROM tab0
----
-23
-34
-88

query I rowsort
SELECT + col2 * + ( + tab0.col2 * - tab0.col1 ) FROM tab0
----
-611884
-93654
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2005
SELECT DISTINCT ( 26 ) DIV + col1 + ( - col1 ) FROM tab1
----
-11
-25
-8

skipif mysql # not compatible
query I rowsort label-2005
SELECT DISTINCT ( 26 ) / + col1 + ( - col1 ) FROM tab1
----
-11
-25
-8

query I rowsort
SELECT + col0 * col0 + col2 + col2 AS col2 FROM tab0 AS cor0
----
1227
642
8085

query I rowsort
SELECT ALL 57 * col1 AS col2 FROM tab2 AS cor0
----
1767
3363
969

query I rowsort
SELECT - + 94 * col0 AS col0 FROM tab1 AS cor0
----
-282
-6016
-7520

query I rowsort
SELECT DISTINCT + - 15 + - col2 FROM tab2 AS cor0
----
-41
-42
-53

query I rowsort
SELECT DISTINCT + col2 * 8 AS col1 FROM tab1 AS cor0
----
432
456
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 * cor0.col2 col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT - 91 + + col0 AS col2 FROM tab2 AS cor0
----
-12
-13
-84

query I rowsort
SELECT DISTINCT col2 * - col0 * 16 + - col1 FROM tab0 AS cor0
----
-116859
-12758
-657

query I rowsort
SELECT ALL 76 - col2 AS col1 FROM tab1 cor0
----
-20
19
22

query I rowsort
SELECT + ( col2 ) * + col2 * + col2 AS col2 FROM tab2
----
17576
19683
54872

onlyif mysql # use DIV operator for integer division
query I rowsort label-2016
SELECT DISTINCT + col0 + - col0 * col1 DIV - ( col1 ) FROM tab1
----
128
160
6

skipif mysql # not compatible
query I rowsort label-2016
SELECT DISTINCT + col0 + - col0 * col1 / - ( col1 ) FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT - tab2.col2 + col2 AS col1 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + ( - tab2.col1 * ( + ( col1 ) ) + + ( 58 ) ) col0 FROM tab2
----
-269
-3449
-930

query I rowsort
SELECT DISTINCT - tab0.col2 + + 84 + col0 FROM tab0
----
118
75
91

query I rowsort
SELECT DISTINCT ( + col2 ) * tab1.col0 * col2 + 56 AS col0 FROM tab1
----
207992
737336
8804

query I rowsort
SELECT - - 85 FROM tab2 cor0
----
85
85
85

query I rowsort
SELECT + 95 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT + col0 * col2 * 72 AS col0 FROM tab2
----
13608
146016
216144

query I rowsort
SELECT DISTINCT 4 * col1 AS col2 FROM tab1
----
104
40
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2025
SELECT + + col1 * col0 + col1 * col2 DIV col0 AS col2 FROM tab2 AS cor0
----
1351
336
4621

skipif mysql # not compatible
query I rowsort label-2025
SELECT + + col1 * col0 + col1 * col2 / col0 AS col2 FROM tab2 AS cor0
----
1351
336
4621

query I rowsort
SELECT - 4 + - col0 AS col0 FROM tab0
----
-28
-39
-93

query I rowsort
SELECT 20 * - col0 AS col1 FROM tab0
----
-1780
-480
-700

query I rowsort
SELECT ALL cor0.col0 + + col1 + col2 FROM tab2 AS cor0
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 45 * - col1 col0 FROM tab0 AS cor0
----
-3870
-4095
-4365

onlyif mysql # use DIV operator for integer division
query I rowsort label-2030
SELECT - 64 DIV 97 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2030
SELECT - 64 / 97 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 65 * - 16 FROM tab1 AS cor0
----
-1040
-1040
-1040

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0, tab0 AS cor0 WHERE NOT cor0.col0 < NULL
----

query I rowsort
SELECT ALL + 66 + col2 * col2 + 95 * col1 AS col1 FROM tab0
----
15435
9282
9325

query I rowsort
SELECT col1 - + col1 AS col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 - - 18 AS col2 FROM tab0 AS cor0
----
104
109
115

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2036
SELECT DISTINCT CAST( NULL AS SIGNED ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2036
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2037
SELECT DISTINCT - cor0.col2 DIV - col0 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-2037
SELECT DISTINCT - cor0.col2 / - col0 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
21
64
81

query I rowsort
SELECT + cor0.col1 + ( + col0 ) FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2039
SELECT DISTINCT - CAST( NULL AS SIGNED ) + + 79 / - cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2039
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + + 79 / - cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2040
SELECT CAST( col0 AS SIGNED ) * col0 + ( + col2 ) FROM tab1 AS cor0
----
4153
63
6496

skipif mysql # not compatible
query I rowsort label-2040
SELECT CAST ( col0 AS INTEGER ) * col0 + ( + col2 ) FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-2041
SELECT col1 - 50 DIV col1 FROM tab1 AS cor0
----
10
25
5

skipif mysql # not compatible
query I rowsort label-2041
SELECT col1 - 50 / col1 FROM tab1 AS cor0
----
10
25
5

query I rowsort
SELECT DISTINCT - col2 + col2 * col1 AS col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT ( 93 ) + + col1 * - col1 * - col1 FROM tab0 AS cor0
----
636149
753664
912766

query I rowsort
SELECT DISTINCT + col0 * 89 + col1 FROM tab1 cor0
----
293
5706
7133

query I rowsort
SELECT + ( col1 ) * cor0.col0 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-2046
SELECT ALL + 9 + - 30 DIV - col2 FROM tab1 AS cor0
----
9
9
9

skipif mysql # not compatible
query I rowsort label-2046
SELECT ALL + 9 + - 30 / - col2 FROM tab1 AS cor0
----
9
9
9

query I rowsort
SELECT DISTINCT - 12 + + 91 FROM tab0 AS cor0
----
79

query III rowsort
SELECT ALL * FROM tab2 WHERE col2 IN ( col0 * col1 )
----

query I rowsort
SELECT DISTINCT - col0 + - tab1.col1 AS col2 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT + col0 - col2 FROM tab1 WHERE NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col2 + tab2.col2 FROM tab2 WHERE ( NULL ) = NULL
----

query I rowsort
SELECT DISTINCT - tab0.col1 * - col2 + col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT col0 AS col0 FROM tab0 WHERE NOT NULL > + col2 + + col1
----

query I rowsort
SELECT ALL - col1 * + col1 + col1 * col1 * col2 FROM tab0
----
0
236672
670761

onlyif mysql # use DIV operator for integer division
query I rowsort label-2055
SELECT DISTINCT col0 DIV col0 + - tab2.col1 * col0 col2 FROM tab2
----
-1342
-216
-4601

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2055
SELECT DISTINCT col0 / col0 + - tab2.col1 * col0 col2 FROM tab2
----
-1342
-216
-4601

query I rowsort
SELECT ALL + col1 + tab0.col0 * - tab0.col2 AS col1 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT col1 + tab2.col1 * - tab2.col1 AS col1 FROM tab2
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT - col1 + - tab1.col1 AS col0 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT + col0 / - col2 - col2 * col2 AS col2 FROM tab2 WHERE NOT NULL < col0 * col0
----

query I rowsort
SELECT DISTINCT + col1 * col0 + - col2 AS col0 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT - col2 AS col0 FROM tab0 WHERE NULL >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2062
SELECT col0 DIV + col0 + + col2 - col0 * + col0 FROM tab1
----
-4038
-6303
46

skipif mysql # not compatible
query I rowsort label-2062
SELECT col0 / + col0 + + col2 - col0 * + col0 FROM tab1
----
-4038
-6303
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-2063
SELECT + tab1.col2 + col2 DIV - col2 + col2 * + tab1.col2 AS col2 FROM tab1
----
2969
3305
9311

skipif mysql # not compatible
query I rowsort label-2063
SELECT + tab1.col2 + col2 / - col2 + col2 * + tab1.col2 AS col2 FROM tab1
----
2969
3305
9311

query I rowsort
SELECT + col2 AS col1 FROM tab1 WHERE NOT NULL < NULL
----

query I rowsort
SELECT ALL + col2 + col1 * - col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT col0 + + col1 + tab1.col0 AS col0 FROM tab1
----
138
173
32

query I rowsort
SELECT + cor0.col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - col1 * - col0 * col0 AS col0 FROM tab1 AS cor0
----
234
40960
83200

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-2070
SELECT col0 DIV - col0 + col2 * + col0 FROM tab2 AS cor0
----
188
2027
3001

skipif mysql # not compatible
query I rowsort label-2070
SELECT col0 / - col0 + col2 * + col0 FROM tab2 AS cor0
----
188
2027
3001

onlyif mysql # use DIV operator for integer division
query I rowsort label-2071
SELECT + col1 + + col2 + + col0 DIV cor0.col0 AS col0 FROM tab1 AS cor0 WHERE NOT ( + cor0.col2 * + col0 ) = ( col0 * + col0 )
----
110
68
81

skipif mysql # not compatible
query I rowsort label-2071
SELECT + col1 + + col2 + + col0 / cor0.col0 AS col0 FROM tab1 AS cor0 WHERE NOT ( + cor0.col2 * + col0 ) = ( col0 * + col0 )
----
110
68
81

query I rowsort
SELECT ALL - col1 + + col2 * col2 AS col2 FROM tab0
----
-96
1003
6633

query I rowsort
SELECT col1 * - col0 * + col0 + + col1 FROM tab1
----
-208
-40950
-83187

query I rowsort
SELECT - col0 * cor0.col1 * col2 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL col2 * col2 + - 65 FROM tab1
----
2851
3184
9151

query I rowsort
SELECT ALL col0 + + 76 * col0 FROM tab1
----
231
4928
6160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2077
SELECT ALL + col2 + CAST( 71 AS SIGNED ) * cor0.col1 AS col2 FROM tab1 AS cor0
----
1019
1900
767

skipif mysql # not compatible
query I rowsort label-2077
SELECT ALL + col2 + CAST ( 71 AS INTEGER ) * cor0.col1 AS col2 FROM tab1 AS cor0
----
1019
1900
767

query I rowsort
SELECT + cor0.col2 + cor0.col0 * + 57 AS col0 FROM tab1 AS cor0
----
225
3705
4656

query I rowsort
SELECT ALL - col1 + - ( ( + col2 ) ) AS col0 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT - col2 + - 49 FROM tab1 AS cor0
----
-103
-106
-145

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2081
SELECT + cor0.col2 * + col2 * col1 + cor0.col0 + CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2081
SELECT + cor0.col2 * + col2 * col1 + cor0.col0 + CAST ( NULL AS INTEGER ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * col0 + + col1 + - col0 FROM tab0 AS cor0
----
7300
854
97

query I rowsort
SELECT - col2 + 55 + col2 * col1 AS col1 FROM tab2 AS cor0
----
1563
663
865

query I rowsort
SELECT - + cor0.col0 + + 67 * + 75 + - col1 FROM tab1 AS cor0
----
4932
4951
4996

query I rowsort
SELECT ALL - col1 - - cor0.col0 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL + 72 * - col2 FROM tab0 AS cor0
----
-2376
-5904
-72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2087
SELECT DISTINCT CAST( NULL AS SIGNED ) * - ( - col1 ) * col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2087
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - ( - col1 ) * col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) * col1 * col2 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT cor0.col0 * col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col0 - 91 col1 FROM tab1 AS cor0
----
-100
-4187
-6491

query I rowsort
SELECT ( - cor0.col0 ) FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col2 ) * + 12 col2 FROM tab0
----
-12
-396
-984

query I rowsort
SELECT ALL col2 * + tab1.col1 AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT col0 * col0 * + col0 FROM tab1 AS cor0
----
262144
27
512000

onlyif mysql # use DIV operator for integer division
query I rowsort label-2095
SELECT - + col1 * - col2 + + 56 DIV + col0 + 66 FROM tab2 AS cor0
----
1600
712
911

skipif mysql # not compatible
query I rowsort label-2095
SELECT - + col1 * - col2 + + 56 / + col0 + 66 FROM tab2 AS cor0
----
1600
712
911

query I rowsort
SELECT DISTINCT col2 + + ( col1 ) * + cor0.col1 AS col2 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-2097
SELECT ALL - col0 DIV - 59 AS col2 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2097
SELECT ALL - col0 / - 59 AS col2 FROM tab2 AS cor0
----
0
1
1

query I rowsort
SELECT - cor0.col2 + ( + col2 ) * col2 AS col1 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT - col0 * col2 + - 49 * col2 - - col1 FROM tab0
----
-11225
-2323
13

query I rowsort
SELECT DISTINCT + col2 * - col2 - + col0 FROM tab1
----
-2919
-3313
-9296

query I rowsort
SELECT ALL + col0 + + 19 FROM tab0
----
108
43
54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * ( col1 ) col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + col0 + ( col1 ) * col2 AS col1 FROM tab0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-2104
SELECT 30 DIV 44 + col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2104
SELECT 30 / 44 + col0 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 11 + + col1 * - col1 col0 FROM tab0 AS cor0
----
-7385
-8270
-9398

query I rowsort
SELECT ALL - col2 + - col2 + + cor0.col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - ( + col2 ) * col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2109
SELECT - col2 DIV - 43 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2109
SELECT - col2 / - 43 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2110
SELECT ALL CAST( + 39 AS SIGNED ) FROM tab0 AS cor0
----
39
39
39

skipif mysql # not compatible
query I rowsort label-2110
SELECT ALL CAST ( + 39 AS INTEGER ) FROM tab0 AS cor0
----
39
39
39

query I rowsort
SELECT DISTINCT col0 * 59 FROM tab1 cor0
----
177
3776
4720

query I rowsort
SELECT DISTINCT - col1 + ( col1 ) AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT col0 * col0 + tab2.col2 AS col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT ALL col1 * + col2 - col2 * col2 FROM tab1
----
-1512
-2679
-7968

query I rowsort
SELECT ALL - 47 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

query I rowsort
SELECT ALL tab2.col0 - tab2.col2 FROM tab2
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2117
SELECT - col0 DIV + col1 AS col1 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-2117
SELECT - col0 / + col1 AS col1 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT - cor1.col0 + 83 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 0e7cd043f6c235bd7d76a2b1aeca6db9

query I rowsort
SELECT ALL + col0 + - col0 * + 33 * + 31 FROM tab2 AS cor0
----
-7154
-79716
-80738

query I rowsort
SELECT DISTINCT - - 84 * col2 - + cor0.col2 AS col1 FROM tab2 cor0
----
2158
2241
3154

query I rowsort
SELECT DISTINCT ( - 63 ) AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
-63

query I rowsort
SELECT ALL - 85 * + col1 * + ( - col0 ) FROM tab2 AS cor0
----
114155
18445
391170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col1 * col2 + - col0 col2 FROM tab1 AS cor0
----
-36544
-4215
-99920

query I rowsort
SELECT DISTINCT - col0 * col2 + col1 - col2 AS col1 FROM tab2 cor0
----
-185
-1995
-3023

query I rowsort
SELECT ALL + col0 + + ( col0 + - col2 * cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-27
-2790
-7284

query I rowsort
SELECT DISTINCT cor0.col1 + - ( 86 + col2 ) FROM tab0 AS cor0
----
-33
-77
10

query I rowsort
SELECT DISTINCT - col2 * + col0 + - 59 AS col0 FROM tab2 AS cor0
----
-2087
-248
-3061

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 39 col1 FROM tab0 AS cor0
----
125
130
136

query I rowsort
SELECT ALL + - col0 + ( + col2 ) * + cor0.col1 * col1 AS col1 FROM tab1 cor0
----
16144
36501
5636

onlyif mysql # use DIV operator for integer division
query I rowsort label-2130
SELECT + col0 DIV col2 - + col0 AS col1 FROM tab0 cor0
----
-24
-88
0

skipif mysql # not compatible
query I rowsort label-2130
SELECT + col0 / col2 - + col0 AS col1 FROM tab0 cor0
----
-24
-88
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2131
SELECT + + col2 * CAST( + 85 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
2805
6970
85

skipif mysql # not compatible
query I rowsort label-2131
SELECT + + col2 * CAST ( + 85 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
2805
6970
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col1 + - col2 col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT col1 * col0 - col2 * col0 FROM tab0 AS cor0
----
1272
3360
801

query I rowsort
SELECT DISTINCT - + col1 + + col0 * - col2 FROM tab0 cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-2135
SELECT col2 DIV 52 - - cor0.col1 AS col0 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2135
SELECT col2 / 52 - - cor0.col1 AS col0 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2136
SELECT ALL + col0 * + CAST( NULL AS DECIMAL ) * col2 + + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2136
SELECT ALL + col0 * + CAST ( NULL AS REAL ) * col2 + + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2137
SELECT ALL cor0.col2 DIV 15 FROM tab2 cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-2137
SELECT ALL cor0.col2 / 15 FROM tab2 cor0
----
1
1
2

query I rowsort
SELECT - col0 - col1 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - cor0.col1 AS col0 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL - tab2.col0 * col2 - + ( - ( col1 ) ) AS col0 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - 93 - + col2 * - col1 FROM tab2
----
1441
553
744

query I rowsort
SELECT + - 32 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 7106326ae056e78044adc0aef747ef08

query I rowsort
SELECT DISTINCT + col1 * col0 * + col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT + + col1 * - 2 AS col0 FROM tab2 AS cor0
----
-118
-34
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2145
SELECT - col0 DIV - 2 + + col1 AS col0 FROM tab1 AS cor0
----
27
42
53

skipif mysql # not compatible
query I rowsort label-2145
SELECT - col0 / - 2 + + col1 AS col0 FROM tab1 AS cor0
----
27
42
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2146
SELECT DISTINCT cor0.col2 * CAST( + cor0.col0 AS SIGNED ) FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-2146
SELECT DISTINCT cor0.col2 * CAST ( + cor0.col0 AS INTEGER ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT col0 * - col0 - - col1 FROM tab0 cor0
----
-1128
-490
-7830

query I rowsort
SELECT - cor0.col2 - + col1 * - col0 * + col2 AS col2 FROM tab0 cor0
----
3394
664036
68079

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + tab1.col2 col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT - - col0 + + col2 * + cor0.col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT - col2 - - col1 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - col1 * - col2 + + col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + col1 * col0 * col2 AS col2 FROM tab1 cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT - tab0.col0 + col0 AS col0 FROM tab0
----
0

query I rowsort
SELECT col0 + col2 + + col0 * + tab2.col0 FROM tab2
----
6188
6358
83

query I rowsort
SELECT ALL col2 + - col2 * + col1 + - col1 * + col2 AS col2 FROM tab1
----
-1083
-2400
-2754

onlyif mysql # use DIV operator for integer division
query I rowsort label-2157
SELECT col1 * - col1 DIV + col1 AS col1 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-2157
SELECT col1 * - col1 / + col1 AS col1 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT ALL + col1 + tab0.col2 * + tab0.col2 + col0 AS col1 FROM tab0
----
1199
133
6904

onlyif mysql # use DIV operator for integer division
query I rowsort label-2159
SELECT col0 * col2 DIV + col1 + col2 + + col2 AS col1 FROM tab0
----
2
244
75

skipif mysql # not compatible
query I rowsort label-2159
SELECT col0 * col2 / + col1 + col2 + + col2 AS col1 FROM tab0
----
2
244
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-2160
SELECT col2 + col0 DIV col0 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-2160
SELECT col2 + col0 / col0 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2161
SELECT DISTINCT col1 DIV col1 + + col1 col1 FROM tab1 AS cor0
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2161
SELECT DISTINCT col1 / col1 + + col1 col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT DISTINCT + 1 + col1 FROM tab2 cor0
----
18
32
60

query I rowsort
SELECT ALL col2 * col0 * - tab0.col0 AS col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT - tab1.col1 + tab1.col2 AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT - 41 * - col1 FROM tab2 cor0
----
1271
2419
697

query I rowsort
SELECT - col0 * col1 - - col1 AS col0 FROM tab0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2167
SELECT - 93 * - col2 + - CAST( NULL AS SIGNED ) col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2167
SELECT - 93 * - col2 + - CAST ( NULL AS INTEGER ) col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 * - tab0.col0 - col0 col1 FROM tab0
----
-2403
-648
-945

query I rowsort
SELECT DISTINCT + ( col2 ) * 67 AS col1 FROM tab2 AS cor0
----
1742
1809
2546

query I rowsort
SELECT DISTINCT + 33 + + col2 AS col0 FROM tab0 AS cor0
----
115
34
66

query I rowsort
SELECT - + col2 + col0 + + cor0.col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ( 88 ) FROM tab1
----
88
88
88

query I rowsort
SELECT col2 * + col2 + - 70 FROM tab2 AS cor0
----
1374
606
659

query I rowsort
SELECT ALL + - cor0.col0 - col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL - col1 + ( 16 ) * + cor0.col2 FROM tab1 AS cor0
----
1523
838
902

query I rowsort
SELECT DISTINCT - - col0 * - col0 + + col0 AS col1 FROM tab1 AS cor0
----
-4032
-6
-6320

skipif mysql # not compatible
query I rowsort
SELECT ALL cor0.col1 * CAST ( col0 AS REAL ) - + col1 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL col2 * 88 FROM tab2 AS cor0
----
2288
2376
3344

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2179
SELECT ALL + col1 / - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2179
SELECT ALL + col1 / - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2180
SELECT DISTINCT col0 DIV cor0.col0 + col0 * + col1 AS col0 FROM tab0 AS cor0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-2180
SELECT DISTINCT col0 / cor0.col0 + col0 * + col1 AS col0 FROM tab0 AS cor0
----
2065
3396
8100

query I rowsort
SELECT ALL - 41 * + col2 AS col1 FROM tab1
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT col2 * - col2 + col0 AS col1 FROM tab2
----
-1365
-598
-722

onlyif mysql # use DIV operator for integer division
query I rowsort label-2183
SELECT + col0 DIV col0 + + 79 FROM tab0
----
80
80
80

skipif mysql # not compatible
query I rowsort label-2183
SELECT + col0 / col0 + + 79 FROM tab0
----
80
80
80

query I rowsort
SELECT - + 29 + - cor0.col0 + + col1 AS col0 FROM tab1 AS cor0
----
-6
-83
-96

query I rowsort
SELECT + col2 + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT - 98 * col2 - col0 * - 64 FROM tab2 AS cor0
----
-2198
1332
2444

query I rowsort
SELECT cor0.col2 - - cor0.col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - col0 + - col0 + - col1 AS col1 FROM tab1 AS cor0
----
-138
-173
-32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2189
SELECT - CAST( + cor0.col1 AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-2189
SELECT - CAST ( + cor0.col1 AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - cor0.col0 + - tab2.col1 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to fada44019ad084108f202db45f662e36

query I rowsort
SELECT DISTINCT + col0 + + 42 AS col0 FROM tab0
----
131
66
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-2192
SELECT - tab2.col1 DIV 84 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2192
SELECT - tab2.col1 / 84 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT tab2.col1 * 57 + tab2.col1 * - col2 FROM tab2
----
1829
323
930

query I rowsort
SELECT - ( col1 ) * col0 + + 12 FROM tab2 AS cor0
----
-1331
-205
-4590

onlyif mysql # use DIV operator for integer division
query I rowsort label-2195
SELECT + - 68 + col2 DIV cor0.col1 FROM tab2 AS cor0
----
-66
-68
-68

skipif mysql # not compatible
query I rowsort label-2195
SELECT + - 68 + col2 / cor0.col1 FROM tab2 AS cor0
----
-66
-68
-68

query I rowsort
SELECT ( ( col1 ) ) * tab2.col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL 65 - 26 FROM tab1
----
39
39
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-2198
SELECT ALL - col2 DIV col1 - - col2 FROM tab2 AS cor0
----
26
27
36

skipif mysql # not compatible
query I rowsort label-2198
SELECT ALL - col2 / col1 - - col2 FROM tab2 AS cor0
----
26
27
36

query I rowsort
SELECT DISTINCT - cor0.col1 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2200
SELECT - col0 * col2 + col0 * - col1 + col2 DIV 52 AS col2 FROM tab1 AS cor0
----
-239
-4287
-8719

skipif mysql # not compatible
query I rowsort label-2200
SELECT - col0 * col2 + col0 * - col1 + col2 / 52 AS col2 FROM tab1 AS cor0
----
-239
-4287
-8719

query I rowsort
SELECT col1 * cor0.col0 + ( col1 ) - col2 * col1 FROM tab1 AS cor0
----
-1300
-195
80

query I rowsort
SELECT - 25 * - col1 + 79 + - ( + col1 ) FROM tab2 AS cor0
----
1495
487
823

query I rowsort
SELECT DISTINCT col2 - + tab1.col2 AS col0 FROM tab1
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2204
SELECT - 71 * tab1.col2 + col2 DIV col0 + col2 FROM tab1
----
-3762
-3990
-6719

skipif mysql # not compatible
query I rowsort label-2204
SELECT - 71 * tab1.col2 + col2 / col0 + col2 FROM tab1
----
-3762
-3990
-6719

onlyif mysql # use DIV operator for integer division
query I rowsort label-2205
SELECT DISTINCT ( - col2 ) DIV col1 - + col2 * col1 DIV col0 FROM tab2
----
-10
-119
-19

skipif mysql # not compatible
query I rowsort label-2205
SELECT DISTINCT ( - col2 ) / col1 - + col2 * col1 / col0 FROM tab2
----
-10
-119
-19

query I rowsort
SELECT ALL col0 - - col0 * tab0.col2 FROM tab0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2207
SELECT col2 DIV col1 + - col0 FROM tab1
----
-1
-59
-73

skipif mysql # not compatible
query I rowsort label-2207
SELECT col2 / col1 + - col0 FROM tab1
----
-1
-59
-73

query I rowsort
SELECT 60 + col2 * + 21 FROM tab1 AS cor0
----
1194
1257
2076

query I rowsort
SELECT DISTINCT - + col1 + col2 * + 22 FROM tab1 AS cor0
----
1162
1244
2099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2210
SELECT DISTINCT - + col0 + - cor0.col0 DIV + col1 FROM tab1 AS cor0
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-2210
SELECT DISTINCT - + col0 + - cor0.col0 / + col1 FROM tab1 AS cor0
----
-3
-70
-86

query I rowsort
SELECT col1 * col2 * col0 + col0 AS col2 FROM tab2 AS cor0
----
119730
51113
5866

query I rowsort
SELECT ALL - - cor0.col0 + col2 * + col2 AS col1 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT + col0 * - col1 * - col0 + + col2 AS col2 FROM tab0 AS cor0
----
118826
49569
720893

query I rowsort
SELECT - + ( - col0 ) * - 30 AS col0 FROM tab0 AS cor0
----
-1050
-2670
-720

query I rowsort
SELECT DISTINCT + - 88 + col0 FROM tab2 AS cor0
----
-10
-81
-9

query I rowsort
SELECT DISTINCT - + 84 AS col0 FROM tab2 AS cor0
----
-84

query I rowsort
SELECT 12 * cor0.col1 * cor0.col0 + ( + col0 ) FROM tab1 AS cor0
----
12560
7744
939

query I rowsort
SELECT ALL 93 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT + col2 + - tab2.col2 * - ( col2 ) * - 54 AS col2 FROM tab2
----
-36478
-39339
-77938

query I rowsort
SELECT - col1 + 95 AS col1 FROM tab0 AS cor0
----
-2
4
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col2 ) * col2 + ( col0 ) col2 FROM tab1 cor0
----
2919
3313
9296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2222
SELECT + CAST( NULL AS SIGNED ) + col1 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2222
SELECT + CAST ( NULL AS INTEGER ) + col1 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2223
SELECT + 41 * + col2 * col2 - - 56 DIV - col2 FROM tab1 AS cor0
----
119555
133209
377856

skipif mysql # not compatible
query I rowsort label-2223
SELECT + 41 * + col2 * col2 - - 56 / - col2 FROM tab1 AS cor0
----
119555
133209
377856

query I rowsort
SELECT col0 - - col0 AS col0 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT ALL 11 + col1 FROM tab0 AS cor0
----
102
108
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2226
SELECT DISTINCT + + CAST( col2 AS SIGNED ) * col2 - - col2 col1 FROM tab2 AS cor0
----
1482
702
756

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2226
SELECT DISTINCT + + CAST ( col2 AS INTEGER ) * col2 - - col2 col1 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL 31 FROM tab1, tab0 cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT ALL - 99 * - 90 * + col2 - ( + col0 ) * - col0 * - col2 AS col1 FROM tab1 AS cor0
----
240960
274398
480654

query I rowsort
SELECT DISTINCT - cor0.col1 - - col0 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + + col1 * - 56 AS col1 FROM tab2 AS cor0
----
-1736
-3304
-952

onlyif mysql # use DIV operator for integer division
query I rowsort label-2231
SELECT ALL + col2 DIV + col0 col2 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2231
SELECT ALL + col2 / + col0 col2 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + ( 46 ) col2 FROM tab0 AS cor0
----
1104
1610
4094

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 - - 63 col0 FROM tab2 AS cor0
----
1507
739
792

query I rowsort
SELECT ALL col1 * ( + 15 ) AS col0 FROM tab0 AS cor0
----
1290
1365
1455

query I rowsort
SELECT DISTINCT + + col1 + col2 * - col0 AS col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT col2 - + 70 FROM tab2 AS cor0
----
-32
-43
-44

onlyif mysql # use DIV operator for integer division
query I rowsort label-2237
SELECT DISTINCT col1 + - CAST( + 33 AS SIGNED ) DIV col0 FROM tab0 AS cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-2237
SELECT DISTINCT col1 + - CAST ( + 33 AS INTEGER ) / col0 FROM tab0 AS cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort
SELECT ALL cor0.col1 * - CAST ( 85 AS REAL ) FROM tab2 AS cor0
----
-1445
-2635
-5015

query I rowsort
SELECT - col2 + cor0.col0 + - col2 AS col2 FROM tab0 AS cor0
----
-42
-75
33

query I rowsort
SELECT + col2 + col2 + tab2.col0 FROM tab2
----
130
155
61

query I rowsort
SELECT DISTINCT + tab1.col1 AS col0 FROM tab1, tab2, tab2 AS cor0
----
10
13
26

query I rowsort
SELECT + - col0 - - col0 * + col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL + - col2 * ( 0 * col0 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + ( - cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2245
SELECT - col0 * - CAST( NULL AS SIGNED ) + - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2245
SELECT - col0 * - CAST ( NULL AS INTEGER ) + - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to d6394df0309139ffe20e7d96c77e26ee

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2247
SELECT CAST( 3 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-2247
SELECT CAST ( 3 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
3
3
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 12 + col2 col2 FROM tab2 AS cor0
----
38
39
50

query I rowsort
SELECT DISTINCT - 93 * + col0 + col1 - + cor0.col1 FROM tab2 AS cor0
----
-651
-7254
-7347

query I rowsort
SELECT ALL + + col2 * col0 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL 4 AS col0 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
81 values hashing to 3347a3237b37ed63205e9440d8818a46

query I rowsort
SELECT - 16 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

query I rowsort
SELECT ALL cor0.col1 * + col2 + cor0.col1 * + 18 * - col2 AS col2 FROM tab2 AS cor0
----
-10982
-14229
-26078

query I rowsort
SELECT ALL col2 * - col1 * + ( - col2 ) + + col0 FROM tab1 AS cor0
----
119888
32554
75819

query I rowsort
SELECT ALL - - col2 * cor0.col0 * - col2 + + 89 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-110694
-2700
-50414

query I rowsort
SELECT + + col1 + + col1 * + col1 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2257
SELECT DISTINCT + + CAST( NULL AS SIGNED ) * cor1.col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2257
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) * cor1.col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2258
SELECT ALL cor0.col1 DIV - col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-2258
SELECT ALL cor0.col1 / - col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT DISTINCT - 72 * col1 + - cor0.col2 FROM tab1 AS cor0
----
-1032
-1926
-777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 87 * + col0 col1 FROM tab2 AS cor0
----
609
6786
6873

query I rowsort
SELECT - 5 FROM tab1 cor0
----
-5
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2262
SELECT col0 DIV 97 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2262
SELECT col0 / 97 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 * col2 * col0 AS col0 FROM tab0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 64 col2 FROM tab1 AS cor0
----
1664
640
832

query I rowsort
SELECT DISTINCT - col0 * col2 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT 33 + + cor0.col2 FROM tab1 AS cor0
----
129
87
90

query I rowsort
SELECT + 64 * + col1 FROM tab0 cor0
----
5504
5824
6208

query I rowsort
SELECT DISTINCT col2 * 21 AS col2 FROM tab2
----
546
567
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-2269
SELECT col1 * - col0 * col0 + ( - col0 ) DIV - col2 AS col2 FROM tab0
----
-118790
-49536
-720810

skipif mysql # not compatible
query I rowsort label-2269
SELECT col1 * - col0 * col0 + ( - col0 ) / - col2 AS col2 FROM tab0
----
-118790
-49536
-720810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 81 col0 FROM tab1, tab0 AS cor0
----
81

query I rowsort
SELECT ALL + col0 - 8 AS col0 FROM tab0
----
16
27
81

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab2 AS cor1, tab2, tab2 cor2
----
3645 values hashing to 7e572cf6967c395d92dce41dcb35c4db

query I rowsort
SELECT - col1 * + 7 FROM tab0 AS cor0
----
-602
-637
-679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * col2 col2 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2275
SELECT + col1 * ( 62 ) * col1 + cor0.col1 * + cor0.col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
458466
513331
583261

skipif mysql # not compatible
query I rowsort label-2275
SELECT + col1 * ( 62 ) * col1 + cor0.col1 * + cor0.col0 / - col0 AS col1 FROM tab0 AS cor0
----
458466
513331
583261

query I rowsort
SELECT - - col1 * + col2 + - col1 * col1 * col2 FROM tab2 AS cor0
----
-10336
-25110
-88972

query I rowsort
SELECT tab2.col0 * - 31 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to d31bd0a8cd5badb1a4b79fdf61bef89f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2278
SELECT col1 * + CAST( - col1 AS SIGNED ) AS col2 FROM tab1
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-2278
SELECT col1 * + CAST ( - col1 AS INTEGER ) AS col2 FROM tab1
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2279
SELECT DISTINCT - CAST( - 35 AS SIGNED ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
-24
18
4

skipif mysql # not compatible
query I rowsort label-2279
SELECT DISTINCT - CAST ( - 35 AS INTEGER ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
-24
18
4

query I rowsort
SELECT + + col0 + 77 AS col1 FROM tab0 cor0
----
101
112
166

query I rowsort
SELECT + col1 * + 93 + + col1 FROM tab0 cor0
----
8084
8554
9118

onlyif mysql # use DIV operator for integer division
query I rowsort label-2282
SELECT DISTINCT - col0 DIV 51 + + col0 * ( - col2 ) + - cor0.col1 FROM tab1 AS cor0
----
-188
-3659
-7694

skipif mysql # not compatible
query I rowsort label-2282
SELECT DISTINCT - col0 / 51 + + col0 * ( - col2 ) + - cor0.col1 FROM tab1 AS cor0
----
-188
-3659
-7694

query I rowsort
SELECT DISTINCT col1 + cor0.col2 * + cor0.col1 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT + 81 + cor0.col2 * - 9 FROM tab1 AS cor0
----
-405
-432
-783

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 37 col1 FROM tab1 AS cor0
----
37
37
37

query I rowsort
SELECT + + ( - col1 ) + col1 * - 86 AS col0 FROM tab0 AS cor0
----
-7482
-7917
-8439

query I rowsort
SELECT + 83 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2288
SELECT CAST( - cor0.col1 AS SIGNED ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

skipif mysql # not compatible
query I rowsort label-2288
SELECT CAST ( - cor0.col1 AS INTEGER ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # use DIV operator for integer division
query I rowsort label-2289
SELECT - + col1 - col0 DIV 8 FROM tab0 AS cor0
----
-101
-102
-89

skipif mysql # not compatible
query I rowsort label-2289
SELECT - + col1 - col0 / 8 FROM tab0 AS cor0
----
-101
-102
-89

query I rowsort
SELECT ALL - col2 * + col2 + - 71 FROM tab1 AS cor0
----
-2987
-3320
-9287

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2291
SELECT ALL + CAST( NULL AS SIGNED ) * + 31 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2291
SELECT ALL + CAST ( NULL AS INTEGER ) * + 31 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + 68 * + col2 FROM tab0
----
2244
5576
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-2293
SELECT + col2 DIV + ( col1 ) FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2293
SELECT + col2 / + ( col1 ) FROM tab2 AS cor0
----
0
0
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2294
SELECT ALL + col1 + CAST( - 33 AS SIGNED ) AS col2 FROM tab1 cor0
----
-20
-23
-7

skipif mysql # not compatible
query I rowsort label-2294
SELECT ALL + col1 + CAST ( - 33 AS INTEGER ) AS col2 FROM tab1 cor0
----
-20
-23
-7

query I rowsort
SELECT DISTINCT col1 + - col2 * ( + cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT col2 + cor0.col2 + col0 AS col0 FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT DISTINCT + col0 + col0 * cor0.col2 * col0 AS col0 FROM tab1 cor0
----
233536
489
614480

query I rowsort
SELECT cor0.col2 + - col2 AS col1 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2299
SELECT - col0 DIV 46 AS col1 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2299
SELECT - col0 / 46 AS col1 FROM tab2 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col0 col2 FROM tab1, tab2, tab2 AS cor0, tab0 cor1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

onlyif mysql # use DIV operator for integer division
query I rowsort label-2301
SELECT DISTINCT col0 - + 79 DIV col1 AS col2 FROM tab1
----
0
57
74

skipif mysql # not compatible
query I rowsort label-2301
SELECT DISTINCT col0 - + 79 / col1 AS col2 FROM tab1
----
0
57
74

query I rowsort
SELECT col1 + - 19 + + tab2.col2 * col2 FROM tab2
----
1442
716
741

onlyif mysql # use DIV operator for integer division
query I rowsort label-2303
SELECT - col1 DIV col1 + + col0 col0 FROM tab0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2303
SELECT - col1 / col1 + + col0 col0 FROM tab0
----
23
34
88

query I rowsort
SELECT ALL - 69 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to b367033d2867a8ca951e3972e9b13154

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2305
SELECT DISTINCT tab1.col2 - CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2305
SELECT DISTINCT tab1.col2 - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 + col0 + 59 col2 FROM tab1 AS cor0
----
2978
3372
9355

query I rowsort
SELECT ( - cor0.col1 ) + 0 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT ALL 46 * col2 AS col1 FROM tab1
----
2484
2622
4416

query I rowsort
SELECT + tab1.col0 * + tab1.col0 + col2 AS col2 FROM tab1
----
4153
63
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 + - ( col0 ) * col2 * - col1 col2 FROM tab1 AS cor0
----
107520
40128
4374

query I rowsort
SELECT ALL col0 + col1 * - cor0.col2 + col2 * col2 FROM tab0 AS cor0
----
-1725
-61
-649

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col2 * col2 * 85 - col0 col0 FROM tab1 AS cor0
----
-247863
-276229
-783440

query I rowsort
SELECT DISTINCT - - col0 + - col2 * - col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + col1 * - col2 * col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL - + 93 * col2 AS col1 FROM tab2 AS cor0
----
-2418
-2511
-3534

onlyif mysql # use DIV operator for integer division
query I rowsort label-2316
SELECT + 93 + + 30 DIV cor0.col1 FROM tab2 AS cor0
----
93
93
94

skipif mysql # not compatible
query I rowsort label-2316
SELECT + 93 + + 30 / cor0.col1 FROM tab2 AS cor0
----
93
93
94

query I rowsort
SELECT - - 97 + col1 AS col2 FROM tab2 AS cor0
----
114
128
156

query I rowsort
SELECT DISTINCT + 48 * cor0.col0 FROM tab0 AS cor0
----
1152
1680
4272

query I rowsort
SELECT DISTINCT - 48 + - 17 FROM tab1 AS cor0
----
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-2320
SELECT ( col0 ) DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2320
SELECT ( col0 ) / col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 17 * ( - col2 ) AS col2 FROM tab2 cor0
----
-442
-459
-646

onlyif mysql # use DIV operator for integer division
query I rowsort label-2322
SELECT DISTINCT cor0.col0 + cor0.col0 DIV col2 AS col0 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-2322
SELECT DISTINCT cor0.col0 + cor0.col0 / col2 AS col0 FROM tab0 AS cor0
----
24
70
90

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) + col0 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + ( - col2 ) * col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - ( - ( col1 ) ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL 81 * cor0.col0 + - col2 + + 56 * col0 AS col2 FROM tab0 AS cor0
----
12111
3255
4794

query I rowsort
SELECT 41 - + col1 * + ( 48 * - col1 ) AS col1 FROM tab0 AS cor0
----
355049
397529
451673

query I rowsort
SELECT DISTINCT col2 * + col0 - + col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT 98 * + 13 + - col2 AS col2 FROM tab0
----
1192
1241
1273

query I rowsort
SELECT ( - tab1.col2 * - col2 ) FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ALL + - col2 * - 15 FROM tab1 AS cor0
----
1440
810
855

query I rowsort
SELECT DISTINCT col1 * 92 * - col1 + - col1 FROM tab0 AS cor0
----
-680518
-761943
-865725

onlyif mysql # use DIV operator for integer division
query I rowsort label-2333
SELECT ALL - - col2 DIV + col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-2333
SELECT ALL - - col2 / + col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT 24 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT col0 + - tab2.col1 + - col1 * col2 FROM tab2
----
-1515
-584
-861

query I rowsort
SELECT 84 * - tab2.col1 FROM tab2
----
-1428
-2604
-4956

query I rowsort
SELECT col2 + ( 75 ) FROM tab0
----
108
157
76

query I rowsort
SELECT 78 + - col1 * col1 FROM tab0 AS cor0
----
-7318
-8203
-9331

query I rowsort
SELECT col1 * col1 + - 5 AS col1 FROM tab2
----
284
3476
956

query I rowsort
SELECT col2 - col0 * - col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT DISTINCT 67 FROM tab2, tab2 AS cor0
----
67

query I rowsort
SELECT - col2 * - ( col2 + col0 ) AS col2 FROM tab1
----
16896
3078
6897

query I rowsort
SELECT 81 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT ALL ( - tab1.col1 + + col1 ) * tab1.col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT ( ( tab2.col0 ) ) FROM tab2
----
7
78
79

query I rowsort
SELECT + 53 AS col0 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 30 * + cor0.col0 col0 FROM tab2, tab2 AS cor0
----
-210
-2340
-2370

query I rowsort
SELECT ALL - 55 FROM tab0, tab2 AS cor0, tab0 cor1, tab2 AS cor2
----
81 values hashing to 037c686cf473a7e2cc59ce6c19d8dc57

query I rowsort
SELECT DISTINCT col2 * + col2 * col0 AS col1 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT ( + col2 * 97 ) + col0 FROM tab1
----
5241
5593
9392

query I rowsort
SELECT 27 + + tab0.col0 AS col2 FROM tab0
----
116
51
62

query I rowsort
SELECT ALL col0 * col0 + tab2.col1 AS col0 FROM tab2
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2353
SELECT - - cor0.col1 DIV cor0.col0 - + col0 * + col1 FROM tab1 AS cor0
----
-1040
-640
-70

skipif mysql # not compatible
query I rowsort label-2353
SELECT - - cor0.col1 / cor0.col0 - + col0 * + col1 FROM tab1 AS cor0
----
-1040
-640
-70

query I rowsort
SELECT DISTINCT + + cor0.col0 * + col0 AS col0 FROM tab0 cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-2355
SELECT - col1 * - col0 + + ( 54 ) * col2 - col2 DIV - col2 FROM tab0 AS cor0
----
12528
3450
3847

skipif mysql # not compatible
query I rowsort label-2355
SELECT - col1 * - col0 + + ( 54 ) * col2 - col2 / - col2 FROM tab0 AS cor0
----
12528
3450
3847

query I rowsort
SELECT DISTINCT ( col1 ) + - col2 * col1 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2357
SELECT col1 * - col0 + ( col0 ) DIV col1 FROM tab1 cor0
----
-1034
-634
-78

skipif mysql # not compatible
query I rowsort label-2357
SELECT col1 * - col0 + ( col0 ) / col1 FROM tab1 cor0
----
-1034
-634
-78

query I rowsort
SELECT + 88 * + tab1.col1 AS col2 FROM tab1
----
1144
2288
880

query I rowsort
SELECT - col0 * col2 + cor0.col1 AS col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - col2 * ( cor0.col0 ) + col0 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2361
SELECT DISTINCT + col0 DIV + col1 + col0 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2361
SELECT DISTINCT + col0 / + col1 + col0 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + col0 * col0 + ( col1 ) AS col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + + col0 + - col2 * col2 AS col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT - col1 * col1 * 75 FROM tab1 cor0
----
-12675
-50700
-7500

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2365
SELECT col0 * - CAST( col1 AS SIGNED ) - cor0.col1 AS col2 FROM tab0 cor0
----
-2150
-3492
-8190

skipif mysql # not compatible
query I rowsort label-2365
SELECT col0 * - CAST ( col1 AS INTEGER ) - cor0.col1 AS col2 FROM tab0 cor0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT + col2 - col2 AS col0 FROM tab2 cor0
----
0

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE - col2 / col0 NOT IN ( - col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT * FROM tab1 WHERE col1 - col0 = NULL
----

query I rowsort
SELECT ALL - tab1.col1 + + col0 + col0 AS col1 FROM tab1
----
-20
118
147

onlyif mysql # use DIV operator for integer division
query I rowsort label-2370
SELECT DISTINCT col1 DIV - tab2.col0 col1 FROM tab2
----
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2370
SELECT DISTINCT col1 / - tab2.col0 col1 FROM tab2
----
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2371
SELECT DISTINCT col0 * + col2 DIV col2 col0 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2371
SELECT DISTINCT col0 * + col2 / col2 col0 FROM tab0
----
24
35
89

query I rowsort
SELECT col1 FROM tab0 WHERE NULL = + col1 + col0 + - col2
----

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL IN ( + tab2.col2 )
----

query I rowsort
SELECT tab1.col2 * col1 * + col1 AS col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT ALL - col2 * - col0 + + col0 + + tab0.col0 * - col2 * - col2 FROM tab0
----
105
26952
605823

onlyif mysql # use DIV operator for integer division
query I rowsort label-2376
SELECT ALL col1 DIV col1 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2376
SELECT ALL col1 / col1 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT + col0 + col0 - col0 AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL col2 * col0 + - tab1.col1 + - col2 FROM tab1
----
3581
7571
82

query III rowsort
SELECT ALL * FROM tab2 WHERE col0 - - col1 < ( NULL )
----

query I rowsort
SELECT ALL col0 * col1 FROM tab0 AS cor0 WHERE NOT ( NULL ) NOT IN ( col0 * col0 + + col1 )
----

query I rowsort
SELECT col2 + col1 * col1 AS col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL + tab2.col1 AS col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL tab1.col2 * + col2 * + col0 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT col2 * col0 + + tab1.col2 AS col2 FROM tab1
----
216
3705
7776

query I rowsort
SELECT + + col0 * col1 + - col1 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-2386
SELECT ALL - col0 - + col1 DIV + col0 AS col0 FROM tab0 cor0
----
-27
-37
-90

skipif mysql # not compatible
query I rowsort label-2386
SELECT ALL - col0 - + col1 / + col0 AS col0 FROM tab0 cor0
----
-27
-37
-90

query I rowsort
SELECT - col2 + col2 * 59 FROM tab2
----
1508
1566
2204

query I rowsort
SELECT - col0 * - col1 + - tab1.col0 * + col2 AS col2 FROM tab1
----
-3008
-6640
-84

skipif mysql # not compatible
query I rowsort
SELECT - cor0.col2 + - col1 * CAST ( col0 AS REAL ) AS col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL + 25 + col2 FROM tab1 AS cor0
----
121
79
82

query I rowsort
SELECT 31 + col2 * col0 * col2 AS col0 FROM tab0 AS cor0
----
26167
598467
66

query I rowsort
SELECT DISTINCT + - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL - col1 * + 93 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
15717
62868
9300

query I rowsort
SELECT ALL - - cor0.col2 - 80 FROM tab1 AS cor0
----
-23
-26
16

query I rowsort
SELECT + col2 + - ( - 30 ) FROM tab1 AS cor0
----
126
84
87

query I rowsort
SELECT - 70 - + col2 FROM tab2
----
-108
-96
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2397
SELECT + col0 + + col0 DIV - ( - col2 ) FROM tab1
----
3
65
80

skipif mysql # not compatible
query I rowsort label-2397
SELECT + col0 + + col0 / - ( - col2 ) FROM tab1
----
3
65
80

query I rowsort
SELECT DISTINCT + - col1 - col2 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT col0 * - ( 49 ) FROM tab2 AS cor0
----
-343
-3822
-3871

query I rowsort
SELECT ALL - col2 + ( - col1 + cor0.col1 ) FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2401
SELECT ALL 98 DIV cor0.col2 AS col0 FROM tab1, tab2, tab0 cor0
----
27 values hashing to e6393f9b7ae2c051a1e4253e209b1101

skipif mysql # not compatible
query I rowsort label-2401
SELECT ALL 98 / cor0.col2 AS col0 FROM tab1, tab2, tab0 cor0
----
27 values hashing to e6393f9b7ae2c051a1e4253e209b1101

query I rowsort
SELECT 67 * - tab0.col0 + + col2 * ( col2 + + ( col0 ) ) AS col1 FROM tab0
----
-2309
273
8059

query I rowsort
SELECT ALL - col1 + - col1 AS col2 FROM tab0 WHERE ( col2 ) < - col1 * col0 * col1 + col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 + - col2 * tab1.col0 col1 FROM tab1
----
-15360
-324
-7296

query I rowsort
SELECT ALL col2 + - tab2.col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + tab2.col1 * - col1 + - col0 AS col0 FROM tab2
----
-3559
-368
-968

query I rowsort
SELECT DISTINCT col0 + col1 * - col2 * col2 AS col0 FROM tab2
----
-22592
-24469
-39806

query I rowsort
SELECT col1 * + col1 * col2 AS col0 FROM tab2
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 * col2 + col1 col2 FROM tab1
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-2410
SELECT - col1 * - col1 + col0 DIV col2 FROM tab0
----
7396
8282
9444

skipif mysql # not compatible
query I rowsort label-2410
SELECT - col1 * - col1 + col0 / col2 FROM tab0
----
7396
8282
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-2411
SELECT DISTINCT tab2.col2 + - col0 DIV + col0 FROM tab2
----
25
26
37

skipif mysql # not compatible
query I rowsort label-2411
SELECT DISTINCT tab2.col2 + - col0 / + col0 FROM tab2
----
25
26
37

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( + tab2.col1 * col2 ) >= - col2
----

query I rowsort
SELECT - tab2.col0 + col0 * + col2 + - col1 FROM tab2
----
151
1891
2906

query I rowsort
SELECT DISTINCT col2 * tab2.col1 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 FROM tab1 WHERE col0 + col1 >= NULL
----

query I rowsort
SELECT ALL - col2 * - col2 AS col2 FROM tab0 cor0
----
1
1089
6724

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL = col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - tab1.col2 col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL - col0 * - col2 * - col2 AS col0 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT DISTINCT col2 * col2 * - col0 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT - tab2.col1 + col1 - - col1 AS col1 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL tab2.col1 * - col0 * col1 AS col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT tab1.col2 + col1 * col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT col0 + + col1 - tab2.col1 AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT + ( col2 ) * ( col2 * tab2.col0 ) + col2 AS col2 FROM tab2
----
114114
5130
52754

query I rowsort
SELECT col1 * + col2 + col0 * col1 FROM tab0
----
15561
3492
4902

onlyif mysql # use DIV operator for integer division
query I rowsort label-2427
SELECT - col2 DIV - CAST( + 52 AS SIGNED ) + cor0.col1 * cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-2427
SELECT - col2 / - CAST ( + 52 AS INTEGER ) + cor0.col1 * cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2428
SELECT col1 DIV col0 + + tab1.col1 AS col0 FROM tab1
----
10
13
34

skipif mysql # not compatible
query I rowsort label-2428
SELECT col1 / col0 + + tab1.col1 AS col0 FROM tab1
----
10
13
34

query I rowsort
SELECT DISTINCT + + 96 + + col0 AS col2 FROM tab1 AS cor0
----
160
176
99

query I rowsort
SELECT ALL col2 + 30 AS col1 FROM tab2 AS cor0
----
56
57
68

query I rowsort
SELECT ALL + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - col2 + 98 AS col0 FROM tab2 AS cor0
----
60
71
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-2433
SELECT - col0 DIV + 48 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2433
SELECT - col0 / + 48 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT - - col0 * + 66 + + col2 + cor0.col1 FROM tab2 AS cor0
----
520
5233
5269

query I rowsort
SELECT DISTINCT + - cor0.col1 * 44 FROM tab0 AS cor0
----
-3784
-4004
-4268

onlyif mysql # use DIV operator for integer division
query I rowsort label-2436
SELECT DISTINCT + col2 DIV col1 - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-2436
SELECT DISTINCT + col2 / col1 - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL - 94 + + col1 AS col2 FROM tab1
----
-68
-81
-84

query I rowsort
SELECT 7 + + col0 + + col2 AS col1 FROM tab1
----
128
183
64

query I rowsort
SELECT ALL 28 AS col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab0 cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

query I rowsort
SELECT ( - col1 ) + - cor0.col1 * + cor0.col1 * ( + col1 + col1 ) FROM tab0 AS cor0
----
-1272198
-1507233
-1825443

query I rowsort
SELECT 91 * + cor0.col1 FROM tab1 AS cor0
----
1183
2366
910

query I rowsort
SELECT 23 - + col2 * col0 AS col1 FROM tab1 cor0
----
-139
-3625
-7657

query I rowsort
SELECT + + col2 - - 65 FROM tab0 AS cor0
----
147
66
98

query I rowsort
SELECT + + ( - cor0.col0 ) * col2 * ( + 60 ) + - col2 AS col2 FROM tab2 AS cor0
----
-11367
-121706
-180158

query I rowsort
SELECT ALL - - 95 * + ( + col0 ) FROM tab1 AS cor0
----
285
6080
7600

query I rowsort
SELECT DISTINCT col1 + col2 * col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL - col2 * + ( col1 ) + cor0.col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL - 29 - - col1 AS col2 FROM tab2 AS cor0
----
-12
2
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-2449
SELECT DISTINCT + 30 DIV + 87 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-2449
SELECT DISTINCT + 30 / + 87 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL - 32 + - col0 + - col0 FROM tab1 AS cor0
----
-160
-192
-38

query I rowsort
SELECT ALL - 74 * + col1 FROM tab2 AS cor0
----
-1258
-2294
-4366

query I rowsort
SELECT + col2 + 99 FROM tab2
----
125
126
137

query I rowsort
SELECT col2 + cor0.col0 * + cor0.col1 AS col2 FROM tab1 cor0
----
1136
132
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + - col2 * + col0 col0 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-2455
SELECT - + 74 DIV - col2 AS col1 FROM tab0 AS cor0
----
0
2
74

skipif mysql # not compatible
query I rowsort label-2455
SELECT - + 74 / - col2 AS col1 FROM tab0 AS cor0
----
0
2
74

query I rowsort
SELECT - - 33 * col2 * + cor0.col2 - col0 AS col2 FROM tab0 AS cor0
----
-2
221803
35913

query I rowsort
SELECT + col1 * col2 + + col2 + + col1 AS col2 FROM tab2 AS cor0
----
1619
701
895

query I rowsort
SELECT ( - col0 ) * - col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT 52 * col0 AS col0 FROM tab1 AS cor0
----
156
3328
4160

query I rowsort
SELECT - cor0.col2 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT - ( - 7 ) * col2 FROM tab2 AS cor0
----
182
189
266

query I rowsort
SELECT + 46 + - cor0.col1 * - col0 AS col0 FROM tab0 AS cor0
----
2110
3441
8145

query I rowsort
SELECT - 17 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT DISTINCT 54 AS col1 FROM tab0, tab0 AS cor0
----
54

query I rowsort
SELECT - ( ( col2 ) ) * col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col1 + col1 * - col2 * col2 AS col0 FROM tab2
----
-22630
-24565
-39943

query I rowsort
SELECT + 84 * col2 AS col1 FROM tab1
----
4536
4788
8064

query I rowsort
SELECT col0 + col2 * tab0.col2 * col2 + + col0 * - col2 AS col0 FROM tab0
----
1
35169
544159

onlyif mysql # use DIV operator for integer division
query I rowsort label-2469
SELECT tab0.col1 DIV 92 col1 FROM tab0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2469
SELECT tab0.col1 / 92 col1 FROM tab0
----
0
0
1

query I rowsort
SELECT + 80 * + col2 + col2 AS col0 FROM tab1
----
4374
4617
7776

query I rowsort
SELECT ALL + tab1.col1 + tab1.col2 AS col2 FROM tab1
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2472
SELECT CAST( 44 AS SIGNED ) + col0 * - col1 FROM tab1 cor0
----
-34
-596
-996

skipif mysql # not compatible
query I rowsort label-2472
SELECT CAST ( 44 AS INTEGER ) + col0 * - col1 FROM tab1 cor0
----
-34
-596
-996

query I rowsort
SELECT DISTINCT + + cor0.col2 + + cor0.col2 * col1 AS col0 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2474
SELECT + tab1.col0 DIV + col1 AS col0 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2474
SELECT + tab1.col0 / + col1 AS col0 FROM tab1
----
0
6
6

query I rowsort
SELECT + 25 * + 99 FROM tab0
----
2475
2475
2475

query I rowsort
SELECT + + col1 * 30 AS col2 FROM tab1 AS cor0
----
300
390
780

query I rowsort
SELECT ALL - + ( 75 ) AS col0 FROM tab0, tab1 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to a0b2f2fd1ab7466175d5b39a8fa7be73

query I rowsort
SELECT ALL + cor0.col1 + 29 AS col0 FROM tab1 AS cor0
----
39
42
55

query I rowsort
SELECT col2 * 53 FROM tab0
----
1749
4346
53

query I rowsort
SELECT ALL + 15 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

onlyif mysql # use DIV operator for integer division
query I rowsort label-2481
SELECT ( - col2 ) DIV - col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-2481
SELECT ( - col2 ) / - col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT cor0.col2 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + cor0.col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + 63 * - col1 AS col0 FROM tab2 cor0
----
-1071
-1953
-3717

onlyif mysql # use DIV operator for integer division
query I rowsort label-2485
SELECT - col1 - col1 DIV col1 FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-2485
SELECT - col1 - col1 / col1 FROM tab0
----
-87
-92
-98

query I rowsort
SELECT DISTINCT 9 FROM tab2, tab0 AS cor0, tab1 cor1
----
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * col0 - col1 col2 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT ALL + col2 + - cor0.col0 * col1 FROM tab0 cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + + col0 * cor0.col0 col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 + + col0 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT ALL - - col2 * 11 AS col2 FROM tab1 cor0
----
1056
594
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-2492
SELECT - + col0 DIV 75 + col1 * col2 FROM tab2 AS cor0
----
1533
645
837

skipif mysql # not compatible
query I rowsort label-2492
SELECT - + col0 / 75 + col1 * col2 FROM tab2 AS cor0
----
1533
645
837

query I rowsort
SELECT - - 87 + tab2.col0 * tab2.col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 8dd3b566835b46ea78684756b688450a

query I rowsort
SELECT col0 * tab0.col2 + tab0.col1 + col2 FROM tab0
----
133
7471
911

query I rowsort
SELECT + 92 * - col0 FROM tab0
----
-2208
-3220
-8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 98 col2 FROM tab2, tab1 AS cor0
----
98

query I rowsort
SELECT + cor1.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2498
SELECT col0 DIV 37 FROM tab1 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2498
SELECT col0 / 37 FROM tab1 AS cor0
----
0
1
2

query I rowsort
SELECT + - col1 * col0 + + cor0.col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - + col1 * col1 + + col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL - col0 + col0 * - ( + tab1.col1 ) * col2 AS col0 FROM tab1
----
-36544
-4215
-99920

onlyif mysql # use DIV operator for integer division
query I rowsort label-2502
SELECT + col0 DIV - tab2.col1 + 59 * col1 + 48 FROM tab2
----
1047
1877
3528

skipif mysql # not compatible
query I rowsort label-2502
SELECT + col0 / - tab2.col1 + 59 * col1 + 48 FROM tab2
----
1047
1877
3528

query I rowsort
SELECT - col0 * ( - col2 ) - + col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT DISTINCT col2 + - 94 AS col2 FROM tab2
----
-56
-67
-68

query I rowsort
SELECT ALL col2 + + col2 * + col0 AS col0 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL tab0.col0 * - col1 + 53 * col0 * + col1 FROM tab0
----
107328
176540
421148

query I rowsort
SELECT - col0 * - 44 + col1 AS col1 FROM tab1
----
158
2826
3533

query I rowsort
SELECT DISTINCT tab1.col0 + + 67 * col2 AS col2 FROM tab1
----
3621
3883
6512

query I rowsort
SELECT + col0 + + ( + 10 ) * + col2 FROM tab1 AS cor0
----
1040
543
634

query I rowsort
SELECT DISTINCT - cor0.col0 * + 79 AS col1 FROM tab0 AS cor0
----
-1896
-2765
-7031

onlyif mysql # use DIV operator for integer division
query I rowsort label-2511
SELECT - cor0.col1 * + col2 - - col1 DIV cor0.col0 AS col0 FROM tab2 AS cor0
----
-1534
-646
-833

skipif mysql # not compatible
query I rowsort label-2511
SELECT - cor0.col1 * + col2 - - col1 / cor0.col0 AS col0 FROM tab2 AS cor0
----
-1534
-646
-833

onlyif mysql # use DIV operator for integer division
query I rowsort label-2512
SELECT DISTINCT col2 DIV ( 86 ) + col2 AS col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2512
SELECT DISTINCT col2 / ( 86 ) + col2 AS col1 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - ( + 59 ) + + col0 col0 FROM tab1
----
-30
15
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2514
SELECT + col2 * ( - col2 ) DIV col2 + + 59 * col2 FROM tab1
----
3132
3306
5568

skipif mysql # not compatible
query I rowsort label-2514
SELECT + col2 * ( - col2 ) / col2 + + 59 * col2 FROM tab1
----
3132
3306
5568

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 * + col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL - ( col1 ) * cor0.col2 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + ( + cor0.col1 ) AS col0 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2518
SELECT + - 9 + col1 * col1 DIV 54 AS col2 FROM tab0 AS cor0
----
127
144
165

skipif mysql # not compatible
query I rowsort label-2518
SELECT + - 9 + col1 * col1 / 54 AS col2 FROM tab0 AS cor0
----
127
144
165

query I rowsort
SELECT ALL + 59 * 30 FROM tab1 cor0
----
1770
1770
1770

query I rowsort
SELECT DISTINCT + - ( cor0.col1 ) + - col1 FROM tab1 cor0
----
-20
-26
-52

query I rowsort
SELECT ALL - col0 + + col2 * + col2 AS col0 FROM tab2 AS cor0
----
1365
598
722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 62 + - 7 col2 FROM tab2 AS cor0
----
-69

query I rowsort
SELECT ALL ( cor0.col1 ) * - col0 * - col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT 33 + col2 * + col1 * col0 FROM tab1
----
36513
4245
99873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + 8 + cor0.col2 + col1 col1 FROM tab1 cor0
----
104
579
749

query I rowsort
SELECT DISTINCT + + ( + 81 ) AS col0 FROM tab1 AS cor0
----
81

query I rowsort
SELECT - + ( + col1 ) * cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - ( + col1 ) * - col1 - - col1 * - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col2 + 46 FROM tab2 AS cor0
----
19
20
8

query I rowsort
SELECT col0 + - 91 FROM tab0 AS cor0
----
-2
-56
-67

query I rowsort
SELECT ALL + cor0.col2 * 65 AS col2 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT DISTINCT - ( col1 ) * - col0 + - col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT ALL - 88 * - col1 - col0 * + col0 AS col0 FROM tab1 AS cor0
----
-3216
-5256
2279

query I rowsort
SELECT DISTINCT - + ( 8 ) + - col1 FROM tab2 AS cor0
----
-25
-39
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 32 + 22 + col2 col1 FROM tab1 AS cor0
----
44
47
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-2536
SELECT ALL - + col0 DIV - col0 - + col1 * col1 AS col2 FROM tab1 AS cor0
----
-168
-675
-99

skipif mysql # not compatible
query I rowsort label-2536
SELECT ALL - + col0 / - col0 - + col1 * col1 AS col2 FROM tab1 AS cor0
----
-168
-675
-99

query I rowsort
SELECT 68 * cor0.col2 - col2 AS col0 FROM tab0 AS cor0
----
2211
5494
67

query I rowsort
SELECT - col1 + col2 * - 7 AS col0 FROM tab0 AS cor0
----
-104
-317
-665

query I rowsort
SELECT 83 - col1 FROM tab1 cor0
----
57
70
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2540
SELECT CAST( - 24 AS SIGNED ) * + cor0.col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d933984f44041a946175e8a2cc183627

skipif mysql # not compatible
query I rowsort label-2540
SELECT CAST ( - 24 AS INTEGER ) * + cor0.col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d933984f44041a946175e8a2cc183627

query I rowsort
SELECT 98 * + col1 AS col1 FROM tab0 AS cor0
----
8428
8918
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * col1 col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + - col1 + - col1 * + 91 FROM tab0 cor0
----
-7912
-8372
-8924

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - 9 col2 FROM tab1 AS cor0
----
1
17
4

query I rowsort
SELECT 56 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT col1 * col1 * ( col2 * - col1 ) + + col0 * col0 + col2 FROM tab1
----
-204416
-52847
-949041

query I rowsort
SELECT DISTINCT 53 - tab2.col0 FROM tab2
----
-25
-26
46

query I rowsort
SELECT - col0 * + col0 + col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1488
178
2170

onlyif mysql # use DIV operator for integer division
query I rowsort label-2549
SELECT DISTINCT + col2 DIV col0 + col0 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-2549
SELECT DISTINCT + col2 / col0 + col0 FROM tab1 AS cor0
----
21
64
81

query I rowsort
SELECT ALL + col0 + col2 + col0 AS col0 FROM tab2 AS cor0
----
182
196
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + col2 * 14 + cor0.col0 col0 FROM tab0 cor0
----
-15222
-94047
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-2552
SELECT col0 + col0 DIV ( 21 ) FROM tab2 cor0
----
7
81
82

skipif mysql # not compatible
query I rowsort label-2552
SELECT col0 + col0 / ( 21 ) FROM tab2 cor0
----
7
81
82

query I rowsort
SELECT DISTINCT + col0 * - col0 + col1 AS col1 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT - ( col0 * tab1.col1 ) + tab1.col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT + ( + 98 ) * + col0 AS col0 FROM tab2
----
686
7644
7742

query I rowsort
SELECT DISTINCT col0 * + col0 + - tab1.col1 * + 84 FROM tab1
----
-2175
3256
5308

query I rowsort
SELECT ALL 19 AS col0 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT ALL - cor1.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT col0 + cor0.col1 + + col2 * col1 AS col0 FROM tab0 AS cor0
----
229
2948
7642

onlyif mysql # use DIV operator for integer division
query I rowsort label-2560
SELECT + col2 DIV - col1 col1 FROM tab2 AS cor0
----
-2
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2560
SELECT + col2 / - col1 col1 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT cor0.col1 * + col0 + - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT + col2 * - col2 + - ( col1 ) FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT + 9 + + col1 * - col2 FROM tab0 AS cor0
----
-2829
-7453
-88

query I rowsort
SELECT + 62 * + col1 FROM tab2 AS cor0
----
1054
1922
3658

query I rowsort
SELECT + 83 * - 37 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9b4170f309f502ede7878ffe8addb6e1

query I rowsort
SELECT - 17 + + col2 + col2 FROM tab0 AS cor0
----
-15
147
49

query I rowsort
SELECT + ( col0 + - 52 * - 19 ) FROM tab0
----
1012
1023
1077

query I rowsort
SELECT - col2 * + 62 + ( + col1 * tab2.col1 ) FROM tab2
----
-2067
-713
1869

query I rowsort
SELECT DISTINCT - col2 + 80 * + cor0.col2 + - col0 AS col2 FROM tab1 AS cor0
----
4263
4439
7504

query I rowsort
SELECT DISTINCT + col2 - 77 FROM tab1 AS cor0
----
-20
-23
19

query I rowsort
SELECT + - col0 * + 41 FROM tab1 cor0
----
-123
-2624
-3280

query I rowsort
SELECT DISTINCT - + col2 + + col2 * 93 FROM tab1 AS cor0
----
4968
5244
8832

query I rowsort
SELECT ALL - col1 * cor0.col2 + col1 * cor0.col2 + ( col1 ) FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 52 col1 FROM tab0, tab1 cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT ALL cor1.col1 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT + col1 * col0 + col0 AS col1 FROM tab1
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2577
SELECT + ( col2 ) * + col1 DIV - col1 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2577
SELECT + ( col2 ) * + col1 / - col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT col0 * 56 * col2 AS col1 FROM tab0
----
1960
408688
44352

query I rowsort
SELECT + + col0 * - col2 AS col0 FROM tab2 cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 49 + + col0 + - cor0.col1 col1 FROM tab2 AS cor0
----
111
25
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 11 col0 FROM tab0 AS cor0
----
-11
-11
-11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2582
SELECT - col2 * - col2 - col0 * CAST( col2 AS SIGNED ) AS col0 FROM tab2 cor0
----
-1352
-1558
540

skipif mysql # not compatible
query I rowsort label-2582
SELECT - col2 * - col2 - col0 * CAST ( col2 AS INTEGER ) AS col0 FROM tab2 cor0
----
-1352
-1558
540

query I rowsort
SELECT DISTINCT 23 + - 59 FROM tab1 AS cor0
----
-36

query I rowsort
SELECT - col0 + - ( col0 ) FROM tab1 cor0
----
-128
-160
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2585
SELECT CAST( col2 AS SIGNED ) * + col0 + + ( cor0.col1 ) FROM tab2 cor0
----
2087
220
3019

skipif mysql # not compatible
query I rowsort label-2585
SELECT CAST ( col2 AS INTEGER ) * + col0 + + ( cor0.col1 ) FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT ALL + - 1 - col1 FROM tab1 AS cor0
----
-11
-14
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - 63 ) col0 FROM tab1 AS cor0
----
-63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * - cor0.col1 col0 FROM tab2, tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2589
SELECT col1 * + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-2589
SELECT col1 * + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + - col0 * 84 * + col1 FROM tab0 cor0
----
-173376
-285180
-680316

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2591
SELECT col1 * + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2591
SELECT col1 * + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 58 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2, tab0 AS cor2
----
243 values hashing to 35fbb9c8a846114caca5e1135cf8703c

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) FROM tab0, tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col2 + col2 + cor0.col2 * - col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + ( - 83 + col0 ) col2 FROM tab2 AS cor0
----
-49
21
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2596
SELECT col0 DIV + ( col2 ) + col1 DIV - 75 AS col0 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2596
SELECT col0 / + ( col2 ) + col1 / - 75 AS col0 FROM tab1
----
0
0
1

query I rowsort
SELECT - + col0 * - col0 FROM tab2 cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-2598
SELECT DISTINCT + tab0.col2 DIV - ( tab0.col0 ) col0 FROM tab0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2598
SELECT DISTINCT + tab0.col2 / - ( tab0.col0 ) col0 FROM tab0
----
-1
0

query I rowsort
SELECT ALL 47 FROM tab2, tab1 cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT ALL - tab0.col0 * + ( - col0 + col0 * + ( + ( col1 ) ) ) AS col1 FROM tab0
----
-117600
-48960
-712890

query I rowsort
SELECT DISTINCT + 25 * col1 AS col0 FROM tab1 AS cor0
----
250
325
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col0 * - ( + 30 ) col1 FROM tab1 AS cor0
----
144
1977
2496

onlyif mysql # use DIV operator for integer division
query I rowsort label-2603
SELECT ALL col2 DIV col0 AS col0 FROM tab2 cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-2603
SELECT ALL col2 / col0 AS col0 FROM tab2 cor0
----
0
0
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2604
SELECT + - 47 * col2 + + CAST( ( col2 ) * col2 AS SIGNED ) FROM tab0 AS cor0
----
-46
-462
2870

skipif mysql # not compatible
query I rowsort label-2604
SELECT + - 47 * col2 + + CAST ( ( col2 ) * col2 AS INTEGER ) FROM tab0 AS cor0
----
-46
-462
2870

query I rowsort
SELECT col0 * col2 + + col1 AS col2 FROM tab0 AS cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - col0 + + col0 * col1 col2 FROM tab0 AS cor0
----
1272
3360
801

query I rowsort
SELECT DISTINCT + cor0.col2 * 78 + - col2 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
1976
2052
2888

query I rowsort
SELECT ALL 6 - 63 * + cor0.col2 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to f6b5229a8b432242b37431f62af7d58e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + ( col2 ) * col2 * col1 col0 FROM tab1 AS cor0
----
119821
32500
75842

query I rowsort
SELECT DISTINCT - col1 * + ( + 56 ) + + col2 * 78 AS col0 FROM tab2 AS cor0
----
-1276
2012
370

query I rowsort
SELECT + ( col1 ) * - col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - ( 27 ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

query I rowsort
SELECT + + col1 * + ( + col1 * + col0 ) + col0 * - col1 FROM tab2 AS cor0
----
21488
266916
6510

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2614
SELECT - CAST( NULL AS SIGNED ) - col2 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2614
SELECT - CAST ( NULL AS INTEGER ) - col2 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 - cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT - + col1 * col0 * col2 - ( + cor0.col2 + + col1 ) * 42 AS col2 FROM tab2 AS cor0
----
-123222
-53344
-8295

query I rowsort
SELECT ALL + ( col2 ) + col2 * + cor0.col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - + ( + col2 ) * col1 * - cor0.col0 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( col2 ) * col0 col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT 1 * - tab1.col2 * - col2 AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ( 59 ) AS col0 FROM tab2
----
59
59
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( cor0.col0 ) col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + col0 * - col0 + - col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL + 55 * + col1 + col2 - col2 FROM tab1
----
1430
550
715

query I rowsort
SELECT - - col1 + col0 * 53 FROM tab1 AS cor0
----
185
3402
4253

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * + col1 + + 55 col0 FROM tab0 AS cor0
----
-7341
-8226
-9354

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0, tab1 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to b3ea820890445d59f3f7464a1521d42d

query I rowsort
SELECT ALL col2 * + cor0.col2 * ( + col2 ) AS col1 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT - + 19 * col1 FROM tab2 cor0
----
-1121
-323
-589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 10 * - col2 + + col2 col2 FROM tab1
----
-486
-513
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col0 ) + 68 col0 FROM tab1
----
132
148
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-2632
SELECT - 62 + tab1.col1 DIV + ( col1 * - col0 ) AS col0 FROM tab1
----
-62
-62
-62

skipif mysql # not compatible
query I rowsort label-2632
SELECT - 62 + tab1.col1 / + ( col1 * - col0 ) AS col0 FROM tab1
----
-62
-62
-62

query I rowsort
SELECT DISTINCT col1 * + col0 + 97 + col1 * - tab1.col0 AS col1 FROM tab1
----
97

query I rowsort
SELECT ALL - + 5 + cor0.col0 AS col2 FROM tab0 AS cor0
----
19
30
84

query I rowsort
SELECT DISTINCT - col2 * col1 * 8 AS col0 FROM tab1 AS cor0
----
-11232
-4560
-9984

query I rowsort
SELECT - col2 * - col1 * - tab1.col0 AS col0 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT + ( col2 ) + col1 + col0 FROM tab1
----
131
189
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + tab2.col0 col1 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2639
SELECT DISTINCT col2 DIV 90 AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-2639
SELECT DISTINCT col2 / 90 AS col0 FROM tab2
----
0

query I rowsort
SELECT col2 * tab1.col0 + tab1.col1 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT + cor0.col0 - - col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT ( col1 ) + - cor0.col1 * 38 FROM tab2 cor0
----
-1147
-2183
-629

query I rowsort
SELECT DISTINCT - + 86 * col1 * + col2 FROM tab1 AS cor0
----
-107328
-120744
-49020

query I rowsort
SELECT DISTINCT col0 * - col1 + - col2 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT col0 * - col2 + + col2 + col2 FROM tab1
----
-3534
-54
-7488

query I rowsort
SELECT ALL + 65 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-24
30
41

query I rowsort
SELECT DISTINCT + + 74 * col0 * + col1 + 47 FROM tab0 AS cor0
----
152783
251277
599373

query I rowsort
SELECT ALL 65 + cor0.col1 FROM tab2 AS cor0
----
124
82
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2649
SELECT ALL - 17 * 93 DIV - col0 + + 54 AS col1 FROM tab0 AS cor0
----
119
71
99

skipif mysql # not compatible
query I rowsort label-2649
SELECT ALL - 17 * 93 / - col0 + + 54 AS col1 FROM tab0 AS cor0
----
119
71
99

query I rowsort
SELECT ALL - col1 * 7 AS col2 FROM tab1 AS cor0
----
-182
-70
-91

query I rowsort
SELECT + ( ( col1 ) ) * + col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL - + 69 + + col1 * + col0 * ( col2 ) FROM tab0 AS cor0
----
3326
664049
68043

query I rowsort
SELECT ALL col1 + - cor0.col2 * - col1 * + cor0.col0 FROM tab2 AS cor0
----
119711
51051
5890

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 - 60 col1 FROM tab1 AS cor0
----
-70
-73
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-2655
SELECT + + col2 DIV col0 + cor0.col1 DIV col1 AS col1 FROM tab0 AS cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-2655
SELECT + + col2 / col0 + cor0.col1 / col1 AS col1 FROM tab0 AS cor0
----
1
1
2

query I rowsort
SELECT DISTINCT + col2 * - col0 + ( col0 ) FROM tab2 cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-2657
SELECT ALL + col2 DIV + CAST( - 66 AS SIGNED ) + + col1 - + col1 AS col0 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2657
SELECT ALL + col2 / + CAST ( - 66 AS INTEGER ) + + col1 - + col1 AS col0 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2658
SELECT - col1 DIV - 38 AS col0 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2658
SELECT - col1 / - 38 AS col0 FROM tab2
----
0
0
1

query I rowsort
SELECT ALL col1 * col2 - - 52 * - col0 AS col0 FROM tab2 AS cor0
----
-2522
-3462
473

query I rowsort
SELECT ( 67 ) + + cor0.col1 AS col1 FROM tab2 AS cor0
----
126
84
98

query I rowsort
SELECT + + col1 * + ( col0 ) * - col2 + col2 * col0 AS col1 FROM tab2 AS cor0
----
-117624
-48032
-5670

query I rowsort
SELECT cor0.col2 + + 21 * + col1 FROM tab2 AS cor0
----
1265
395
678

query I rowsort
SELECT col2 * - cor0.col0 + - col1 * - col0 * + 54 AS col1 FROM tab2 AS cor0
----
11529
246480
69520

query I rowsort
SELECT + + col0 * + 57 FROM tab2 AS cor0
----
399
4446
4503

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2665
SELECT ALL - col0 + + CAST( col1 AS SIGNED ) FROM tab0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-2665
SELECT ALL - col0 + + CAST ( col1 AS INTEGER ) FROM tab0
----
2
62
62

query I rowsort
SELECT DISTINCT + col0 * tab1.col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL - col1 + ( 20 ) FROM tab2
----
-11
-39
3

query I rowsort
SELECT ALL + col0 + - 93 * - col2 FROM tab0
----
128
3093
7715

query I rowsort
SELECT col2 + ( + col0 ) * + col0 + ( col1 ) FROM tab1
----
4163
6509
89

query I rowsort
SELECT DISTINCT + 63 FROM tab1 cor0
----
63

query I rowsort
SELECT - + col2 + col2 * - col2 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT ALL - ( - col1 ) + - col2 AS col0 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2673
SELECT CAST( NULL AS SIGNED ) * 23 + col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2673
SELECT CAST ( NULL AS INTEGER ) * 23 + col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2674
SELECT + - CAST( NULL AS SIGNED ) FROM tab1, tab0, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2674
SELECT + - CAST ( NULL AS INTEGER ) FROM tab1, tab0, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT 77 * col1 * + col1 AS col1 FROM tab0
----
569492
637637
724493

query I rowsort
SELECT ALL + + 93 * col1 AS col1 FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT DISTINCT - - ( col2 ) * ( + cor0.col2 ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + cor0.col2 + ( + 19 ) FROM tab1 AS cor0
----
115
73
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2679
SELECT DISTINCT + cor0.col2 DIV col2 + + col0 + col2 FROM tab1 cor0
----
122
177
58

skipif mysql # not compatible
query I rowsort label-2679
SELECT DISTINCT + cor0.col2 / col2 + + col0 + col2 FROM tab1 cor0
----
122
177
58

query I rowsort
SELECT 43 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT 30 + cor0.col0 FROM tab2, tab0 cor0
----
9 values hashing to 46813c6d930c7ba318789e5b0c307e41

query I rowsort
SELECT ALL col2 * 49 FROM tab0
----
1617
4018
49

query I rowsort
SELECT DISTINCT - 2 * - col1 * col2 AS col1 FROM tab2 AS cor0
----
1292
1674
3068

query I rowsort
SELECT ALL 30 * ( col0 ) + ( + col2 ) * col2 AS col1 FROM tab2 AS cor0
----
3016
3814
939

query I rowsort
SELECT + - cor0.col2 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2686
SELECT + - CAST( NULL AS SIGNED ) * + col0 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2686
SELECT + - CAST ( NULL AS INTEGER ) * + col0 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 64 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

query I rowsort
SELECT ALL + 36 + 26 * - col2 * ( cor0.col2 ) FROM tab0 AS cor0
----
-174788
-28278
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-2689
SELECT cor0.col0 + col2 DIV col0 col0 FROM tab1 AS cor0
----
21
64
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2689
SELECT cor0.col0 + col2 / col0 col0 FROM tab1 AS cor0
----
21
64
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2690
SELECT - ( col0 ) * + CAST( NULL AS DECIMAL ) * col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2690
SELECT - ( col0 ) * + CAST ( NULL AS REAL ) * col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 6 AS col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 8be8910507908e6353d02a545b748252

query I rowsort
SELECT DISTINCT + 22 AS col1 FROM tab2
----
22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) * + 54 col2 FROM tab0 cor0
----
4644
4914
5238

query I rowsort
SELECT - col1 + - col1 * - tab2.col2 + - col0 AS col0 FROM tab2
----
1397
550
799

query I rowsort
SELECT + 36 FROM tab1, tab0 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT col0 - 46 * - col0 * col1 FROM tab1 AS cor0
----
29504
3591
47920

query I rowsort
SELECT + col2 * col0 * col0 + + cor0.col1 FROM tab2 AS cor0
----
1354
158243
237175

query I rowsort
SELECT DISTINCT + 22 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-2699
SELECT DISTINCT col2 + - col0 DIV - col0 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-2699
SELECT DISTINCT col2 + - col0 / - col0 FROM tab2
----
27
28
39

query I rowsort
SELECT ALL 70 + 45 AS col1 FROM tab1
----
115
115
115

query I rowsort
SELECT 61 * 97 AS col2 FROM tab2
----
5917
5917
5917

onlyif mysql # use DIV operator for integer division
query I rowsort label-2702
SELECT ALL - 93 * col1 + + col1 DIV 90 AS col0 FROM tab0 AS cor0
----
-7998
-8462
-9020

skipif mysql # not compatible
query I rowsort label-2702
SELECT ALL - 93 * col1 + + col1 / 90 AS col0 FROM tab0 AS cor0
----
-7998
-8462
-9020

query I rowsort
SELECT ALL + col1 + cor0.col1 * - col1 * col2 FROM tab1 AS cor0
----
-16211
-36478
-5690

query I rowsort
SELECT DISTINCT + - 29 + - col0 AS col1 FROM tab0 AS cor0
----
-118
-53
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2705
SELECT ALL + CAST( ( col0 ) AS SIGNED ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2705
SELECT ALL + CAST ( ( col0 ) AS INTEGER ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + - col1 + - cor0.col1 * - 34 FROM tab2 AS cor0
----
1023
1947
561

query I rowsort
SELECT ALL + col2 * + tab1.col2 * - col1 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT 96 + - col1 * + col1 AS col0 FROM tab2
----
-193
-3385
-865

query I rowsort
SELECT + - 72 + cor0.col0 * col2 AS col2 FROM tab1 cor0
----
3576
7608
90

query I rowsort
SELECT - + 75 * - col1 FROM tab0 AS cor0
----
6450
6825
7275

query I rowsort
SELECT ALL col1 * 14 + - col2 * col1 AS col2 FROM tab2 AS cor0
----
-403
-408
-708

query I rowsort
SELECT cor0.col1 * - col1 + cor0.col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT + + col1 * col2 + - col2 * col2 * + 0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT col2 * + col2 + - 71 * + col1 FROM tab0 AS cor0
----
-5017
-6886
263

query I rowsort
SELECT DISTINCT + - col2 * - 3 + - col2 * cor0.col2 FROM tab0 AS cor0
----
-6478
-990
2

query I rowsort
SELECT + col1 * 59 + - col0 FROM tab1 AS cor0
----
1531
526
687

query I rowsort
SELECT col0 + + cor0.col2 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL - + col1 + col1 * - col0 AS col0 FROM tab2 cor0
----
-1360
-248
-4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 20 * - col2 col1 FROM tab0
----
-1640
-20
-660

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * ( 13 * col0 ) col1 FROM tab0 AS cor0
----
102973
15925
7488

query I rowsort
SELECT DISTINCT + + col0 + col0 + + col2 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT col1 * ( col1 ) AS col2 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2723
SELECT DISTINCT - cor0.col0 DIV - col2 + col2 - col0 AS col2 FROM tab0 AS cor0
----
-6
1
9

skipif mysql # not compatible
query I rowsort label-2723
SELECT DISTINCT - cor0.col0 / - col2 + col2 - col0 AS col2 FROM tab0 AS cor0
----
-6
1
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2724
SELECT - col2 DIV - 99 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-2724
SELECT - col2 / - 99 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * tab0.col0 * - col2 - + col2 * 68 AS col2 FROM tab0
----
-103
-28380
-604012

query I rowsort
SELECT + col2 * - ( + col2 * col2 ) FROM tab1
----
-157464
-185193
-884736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2727
SELECT CAST( col1 AS SIGNED ) * - col2 + ( col1 ) AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif mysql # not compatible
query I rowsort label-2727
SELECT CAST ( col1 AS INTEGER ) * - col2 + ( col1 ) AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-2728
SELECT + + col1 DIV 66 - col1 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2728
SELECT + + col1 / 66 - col1 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2729
SELECT - - col1 + cor0.col2 DIV col1 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-2729
SELECT - - col1 + cor0.col2 / col1 FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT ALL tab1.col1 * - col1 * + col1 - col1 * + col2 AS col1 FROM tab1
----
-1570
-18980
-3445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * + col0 col0 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2732
SELECT - col2 * - col1 DIV ( + col1 ) FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2732
SELECT - col2 * - col1 / ( + col1 ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL 64 * + col1 FROM tab0 AS cor0
----
5504
5824
6208

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2734
SELECT ALL - CAST( col1 * col1 + ( - col1 ) AS SIGNED ) FROM tab0
----
-7310
-8190
-9312

skipif mysql # not compatible
query I rowsort label-2734
SELECT ALL - CAST ( col1 * col1 + ( - col1 ) AS INTEGER ) FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL - col2 * + col2 + - col0 * + col0 AS col1 FROM tab0 AS cor0
----
-1226
-14645
-1665

query I rowsort
SELECT DISTINCT + - col2 * col0 + 18 FROM tab2 cor0
----
-171
-2010
-2984

query I rowsort
SELECT ALL - col2 * col1 + col0 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT - - ( col2 ) + col1 * col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT - tab2.col2 + col0 * col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT ALL col0 + tab1.col1 * col2 + + col0 FROM tab1
----
1408
1410
698

query I rowsort
SELECT + col1 - tab0.col2 AS col2 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT + ( col1 ) * + col1 + ( col2 ) FROM tab0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT col2 + ( col0 ) FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT + tab1.col1 FROM tab1, tab2, tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - ( + col1 ) + 30 * + col0 FROM tab1 AS cor0
----
1910
2387
64

query I rowsort
SELECT + col2 * + cor0.col1 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - col2 * col0 * col2 + ( - cor0.col0 ) * + col0 FROM tab0 AS cor0
----
-1260
-26712
-606357

query I rowsort
SELECT ALL 7 * - col1 AS col0 FROM tab2 AS cor0
----
-119
-217
-413

query I rowsort
SELECT DISTINCT - + 83 + col0 * + col2 AS col2 FROM tab2 cor0
----
106
1945
2919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2750
SELECT + ( + col1 ) * CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2750
SELECT + ( + col1 ) * CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 74 FROM tab1, tab0 AS cor0
----
9 values hashing to 5a567947d14593676e3825756f8e6130

query I rowsort
SELECT DISTINCT ( - 87 * - col1 ) FROM tab0
----
7482
7917
8439

query I rowsort
SELECT + cor0.col0 + + 32 AS col2 FROM tab1 cor0
----
112
35
96

query I rowsort
SELECT DISTINCT - - ( col1 ) * col1 + 21 FROM tab1 AS cor0
----
121
190
697

query I rowsort
SELECT + ( 29 * col2 ) AS col2 FROM tab1
----
1566
1653
2784

query I rowsort
SELECT DISTINCT + ( + col1 ) + col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL - 34 + 21 * col1 FROM tab0 AS cor0
----
1772
1877
2003

query I rowsort
SELECT - 27 + + cor0.col2 * 49 AS col1 FROM tab2 cor0
----
1247
1296
1835

query I rowsort
SELECT ALL + + ( - col1 ) - + ( + col2 ) AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT + cor0.col1 * + col0 - - col2 AS col0 FROM tab2 AS cor0
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 16 * - col0 + col2 * - col0 col0 FROM tab1 AS cor0
----
-210
-4672
-8960

query I rowsort
SELECT - + col0 + col1 * ( col0 ) AS col2 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT - ( col2 ) - cor0.col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT - - 66 AS col0 FROM tab2 AS cor0
----
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2765
SELECT + col0 * col1 + col1 + - 99 DIV col0 AS col2 FROM tab2 AS cor0
----
1359
234
4660

skipif mysql # not compatible
query I rowsort label-2765
SELECT + col0 * col1 + col1 + - 99 / col0 AS col2 FROM tab2 AS cor0
----
1359
234
4660

query I rowsort
SELECT DISTINCT - 39 FROM tab0, tab0 AS cor0
----
-39

query I rowsort
SELECT 8 * + cor0.col2 FROM tab1 AS cor0
----
432
456
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-2768
SELECT ALL + + col0 DIV col0 - col2 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
163
3649
7681

skipif mysql # not compatible
query I rowsort label-2768
SELECT ALL + + col0 / col0 - col2 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
163
3649
7681

query I rowsort
SELECT col1 * + 38 FROM tab1 AS cor0
----
380
494
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + + ( col1 ) * col0 col0 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT cor0.col0 + - 93 FROM tab0 AS cor0
----
-4
-58
-69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2772
SELECT + col2 + CAST( 94 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
127
176
95

skipif mysql # not compatible
query I rowsort label-2772
SELECT + col2 + CAST ( 94 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
127
176
95

query I rowsort
SELECT ALL + col1 + col1 * col0 AS col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-2774
SELECT ALL + col1 * - 21 + cor0.col2 - + cor0.col2 DIV + col1 AS col2 FROM tab1 AS cor0
----
-158
-184
-494

skipif mysql # not compatible
query I rowsort label-2774
SELECT ALL + col1 * - 21 + cor0.col2 - + cor0.col2 / + col1 AS col2 FROM tab1 AS cor0
----
-158
-184
-494

query I rowsort
SELECT col2 + + 30 + col1 FROM tab2 AS cor0
----
115
85
88

query I rowsort
SELECT - col1 + + ( + col0 ) + + col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT col1 * 24 + col0 AS col2 FROM tab0 AS cor0
----
2088
2273
2363

query I rowsort
SELECT DISTINCT + col2 + + 81 AS col2 FROM tab1 AS cor0
----
135
138
177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2779
SELECT + + CAST( NULL AS SIGNED ) col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2779
SELECT + + CAST ( NULL AS INTEGER ) col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 36 col2 FROM tab1 AS cor0
----
1944
2052
3456

query I rowsort
SELECT - col2 + + 50 AS col0 FROM tab2 AS cor0
----
12
23
24

query I rowsort
SELECT - ( + 40 ) * - col0 FROM tab2 AS cor0
----
280
3120
3160

query I rowsort
SELECT - - 28 * 77 FROM tab2 AS cor0
----
2156
2156
2156

query I rowsort
SELECT + 28 + - col2 + + col2 FROM tab0 AS cor0
----
28
28
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-2785
SELECT DISTINCT + col1 DIV - 48 AS col2 FROM tab2
----
-1
0

skipif mysql # not compatible
query I rowsort label-2785
SELECT DISTINCT + col1 / - 48 AS col2 FROM tab2
----
-1
0

query I rowsort
SELECT - col1 + - ( + col2 ) * col2 FROM tab1 cor0
----
-2942
-3259
-9229

query I rowsort
SELECT 44 * col1 AS col1 FROM tab0 AS cor0
----
3784
4004
4268

query I rowsort
SELECT DISTINCT ( - col2 ) * tab0.col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT 47 AS col1 FROM tab0, tab2 cor0
----
47

query I rowsort
SELECT ALL + ( + 47 ) AS col2 FROM tab0
----
47
47
47

query I rowsort
SELECT ALL 93 AS col0 FROM tab1 AS cor0
----
93
93
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 33 col1 FROM tab1 cor0
----
33
33
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 39 col0 FROM tab2
----
-39
-39
-39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 col2 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL - col0 * col0 + 62 FROM tab0
----
-1163
-514
-7859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2796
SELECT + col0 + CAST( NULL AS DECIMAL ) * 41 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2796
SELECT + col0 + CAST ( NULL AS REAL ) * 41 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + tab1.col0 + + col2 + col0 FROM tab1
----
185
256
60

query I rowsort
SELECT ALL + 80 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

query I rowsort
SELECT + + col1 * 95 FROM tab0 cor0
----
8170
8645
9215

query I rowsort
SELECT col1 + col0 * col0 + col2 * + ( cor0.col2 ) * - col0 AS col2 FROM tab0 AS cor0
----
-25474
-590424
1287

query I rowsort
SELECT - - col2 - + 94 FROM tab1 AS cor0
----
-37
-40
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * - ( - col0 ) col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT col1 + - 70 * 50 FROM tab0 AS cor0
----
-3403
-3409
-3414

query I rowsort
SELECT DISTINCT + cor0.col2 * + col0 AS col1 FROM tab0 cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * ( - col2 ) col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + 62 - col2 * col0 FROM tab1
----
-100
-3586
-7618

query I rowsort
SELECT DISTINCT col1 * col0 * - col0 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT ALL + tab1.col1 * + col0 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT + tab0.col0 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT DISTINCT 61 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 cor1
----
61

query I rowsort
SELECT - - cor0.col1 * 31 * col1 FROM tab0 AS cor0
----
229276
256711
291679

query I rowsort
SELECT + col0 * - 43 FROM tab2
----
-301
-3354
-3397

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 85 col0 FROM tab0
----
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2814
SELECT DISTINCT col2 + - col1 * col1 DIV 23 + cor0.col0 col1 FROM tab0 AS cor0
----
-189
-264
-373

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2814
SELECT DISTINCT col2 + - col1 * col1 / 23 + cor0.col0 col1 FROM tab0 AS cor0
----
-189
-264
-373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 97 + + col2 col0 FROM tab0 cor0
----
-15
-64
-96

query I rowsort
SELECT + col2 - 37 FROM tab0
----
-36
-4
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2817
SELECT ALL + ( col1 ) DIV - 26 col0 FROM tab1 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2817
SELECT ALL + ( col1 ) / - 26 col0 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT - 25 AS col0 FROM tab2, tab2 AS cor0, tab0 cor1
----
-25

query I rowsort
SELECT DISTINCT + 62 + col2 AS col0 FROM tab1 AS cor0
----
116
119
158

query I rowsort
SELECT DISTINCT col2 + + col1 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL + - col2 * cor0.col2 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT + 79 AS col1 FROM tab2 AS cor0
----
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 78 + col1 * col2 col2 FROM tab2 AS cor0
----
1612
724
915

query I rowsort
SELECT ALL + col2 + + col2 * - 21 - col2 FROM tab0 AS cor0
----
-1722
-21
-693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 + col2 + 64 * + col0 col2 FROM tab0 AS cor0
----
13076
2276
2361

query I rowsort
SELECT + col0 * + col1 + + ( col2 ) * col2 * 78 FROM tab0 AS cor0
----
3473
532571
87006

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col0 col2 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 88 col1 FROM tab0 AS cor0
----
-88
-88
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2829
SELECT DISTINCT cor0.col0 / + col2 + + CAST( NULL AS SIGNED ) * 74 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2829
SELECT DISTINCT cor0.col0 / + col2 + + CAST ( NULL AS INTEGER ) * 74 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col2 * + cor0.col1 + - 7 AS col0 FROM tab1 cor0
----
1241
1397
563

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 8 col1 FROM tab2 AS cor0
----
-8
-8
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2832
SELECT DISTINCT - col2 DIV + col1 + + 44 FROM tab0 AS cor0
----
44

skipif mysql # not compatible
query I rowsort label-2832
SELECT DISTINCT - col2 / + col1 + + 44 FROM tab0 AS cor0
----
44

query I rowsort
SELECT DISTINCT col0 * + 76 FROM tab0 AS cor0
----
1824
2660
6764

query I rowsort
SELECT DISTINCT + col0 + - ( + 23 ) AS col1 FROM tab2 AS cor0
----
-16
55
56

query I rowsort
SELECT - col2 * - ( - col0 ) * col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL + col0 * + col0 + + col1 * - col0 AS col0 FROM tab0 AS cor0
----
-1488
-178
-2170

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab2, tab1 cor0, tab1 cor1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2838
SELECT DISTINCT + + col2 + - col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-2838
SELECT DISTINCT + + col2 + - col1 / - col1 AS col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT col2 * - 80 FROM tab0 AS cor0
----
-2640
-6560
-80

query I rowsort
SELECT ALL - - col2 * 67 AS col1 FROM tab2 AS cor0
----
1742
1809
2546

query I rowsort
SELECT ( - 54 ) * + col0 AS col2 FROM tab2 AS cor0
----
-378
-4212
-4266

query I rowsort
SELECT DISTINCT - 84 + + 96 FROM tab0 AS cor0
----
12

query I rowsort
SELECT - 18 FROM tab0, tab2 cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2844
SELECT DISTINCT + CAST( col1 AS SIGNED ) + - tab1.col0 AS col0 FROM tab1
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-2844
SELECT DISTINCT + CAST ( col1 AS INTEGER ) + - tab1.col0 AS col0 FROM tab1
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-2845
SELECT 56 + cor0.col1 DIV col1 col2 FROM tab0 AS cor0
----
57
57
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2845
SELECT 56 + cor0.col1 / col1 col2 FROM tab0 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT ( 59 ) * + col1 + + col2 FROM tab0
----
5107
5451
5724

query I rowsort
SELECT + + col0 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + col1 * + 83 FROM tab1 AS cor0
----
1079
2158
830

query I rowsort
SELECT ALL - cor0.col1 - col0 AS col2 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - - 37 * col0 AS col0 FROM tab2 AS cor0
----
259
2886
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-2851
SELECT - ( cor0.col2 ) DIV - col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-2851
SELECT - ( cor0.col2 ) / - col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 + - 96 col2 FROM tab0 AS cor0
----
-2160
-3491
-8195

query I rowsort
SELECT DISTINCT col0 * + col0 * 25 + + col1 AS col2 FROM tab0 AS cor0
----
14486
198116
30722

query I rowsort
SELECT - + 87 + cor0.col2 * - col0 AS col0 FROM tab0 AS cor0
----
-122
-7385
-879

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 37 - cor0.col0 * - col2 col1 FROM tab2 AS cor0
----
2065
226
3039

query I rowsort
SELECT ALL 53 AS col0 FROM tab1 cor0
----
53
53
53

query I rowsort
SELECT ALL + col1 + + col2 * - col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT ALL + tab0.col0 + + col0 * + col0 FROM tab0
----
1260
600
8010

query I rowsort
SELECT DISTINCT col2 + + 57 FROM tab1
----
111
114
153

onlyif mysql # use DIV operator for integer division
query I rowsort label-2860
SELECT + - 29 DIV col1 AS col1 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2860
SELECT + - 29 / col1 AS col1 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT ( cor0.col1 ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL + 80 AS col0 FROM tab2
----
80
80
80

query I rowsort
SELECT DISTINCT 79 * + 86 * col2 FROM tab0
----
224202
557108
6794

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2864
SELECT - + CAST( NULL AS DECIMAL ) * col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2864
SELECT - + CAST ( NULL AS REAL ) * col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 99 * - col2 AS col0 FROM tab0
----
-3267
-8118
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2866
SELECT col1 DIV tab0.col1 + col1 * - tab0.col1 + + col2 AS col2 FROM tab0
----
-7362
-8198
-9407

skipif mysql # not compatible
query I rowsort label-2866
SELECT col1 / tab0.col1 + col1 * - tab0.col1 + + col2 AS col2 FROM tab0
----
-7362
-8198
-9407

query I rowsort
SELECT DISTINCT 4 + col1 FROM tab1
----
14
17
30

query I rowsort
SELECT DISTINCT + + col0 * + cor0.col2 + + col0 + + cor0.col1 FROM tab0 AS cor0
----
167
7478
902

query I rowsort
SELECT ALL + 32 * col1 AS col0 FROM tab1 cor0
----
320
416
832

query I rowsort
SELECT + 53 * col0 + - col0 FROM tab0 AS cor0
----
1248
1820
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * ( 22 ) col0 FROM tab0 AS cor0
----
-1804
-22
-726

query I rowsort
SELECT DISTINCT - col2 + ( + cor0.col0 + + col2 ) * col1 AS col2 FROM tab1 cor0
----
1153
1428
2192

onlyif mysql # use DIV operator for integer division
query I rowsort label-2873
SELECT ALL col1 * - 65 + + ( col1 + - ( col2 ) ) DIV + col2 col2 FROM tab1 AS cor0
----
-1690
-650
-845

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2873
SELECT ALL col1 * - 65 + + ( col1 + - ( col2 ) ) / + col2 col2 FROM tab1 AS cor0
----
-1690
-650
-845

query I rowsort
SELECT + + col0 + 17 AS col2 FROM tab2 AS cor0
----
24
95
96

query I rowsort
SELECT DISTINCT + 23 FROM tab0, tab1 AS cor0
----
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-2876
SELECT col2 + - col0 DIV - ( + col1 * - col2 ) + - col0 col2 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2876
SELECT col2 + - col0 / - ( + col1 * - col2 ) + - col0 col2 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2877
SELECT - + cor0.col0 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2877
SELECT - + cor0.col0 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col2 * + 82 + 99 AS col2 FROM tab1 AS cor0
----
4527
4773
7971

onlyif mysql # use DIV operator for integer division
query I rowsort label-2879
SELECT - + col2 DIV - col1 AS col2 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2879
SELECT - + col2 / - col1 AS col2 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT - + col0 * + ( - col1 ) AS col2 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2881
SELECT ALL col1 DIV + col0 - tab2.col0 FROM tab2
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-2881
SELECT ALL col1 / + col0 - tab2.col0 FROM tab2
----
-3
-78
-79

query I rowsort
SELECT + + col0 + - 77 FROM tab0 AS cor0
----
-42
-53
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-2883
SELECT + - ( + col2 ) DIV + cor0.col0 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2883
SELECT + - ( + col2 ) / + cor0.col0 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT ALL + col0 + - cor0.col1 * col1 AS col2 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT + 11 + + col0 FROM tab1 AS cor0
----
14
75
91

query I rowsort
SELECT 84 + - ( + col2 ) FROM tab0 AS cor0
----
2
51
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2887
SELECT ALL col0 DIV + cor0.col0 + - col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2887
SELECT ALL col0 / + cor0.col0 + - col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 * - ( + cor0.col1 ) * + CAST ( + col2 AS REAL ) + col1 FROM tab2 cor0
----
-119593
-51017
-5828

query I rowsort
SELECT DISTINCT - col0 + 0 * - col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT 61 + - col2 FROM tab1 cor0
----
-35
4
7

query I rowsort
SELECT 35 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT ALL + ( col2 ) * col1 * col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT - col0 + 40 AS col1 FROM tab0 AS cor0
----
-49
16
5

query I rowsort
SELECT - 18 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

query I rowsort
SELECT + col2 * + ( col2 ) + col1 AS col2 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT DISTINCT - + col1 * - col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2897
SELECT ALL + 45 * - 42 + col0 * + CAST( col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1728
1758
5790

skipif mysql # not compatible
query I rowsort label-2897
SELECT ALL + 45 * - 42 + col0 * + CAST ( col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1728
1758
5790

query I rowsort
SELECT ALL - + col2 * cor0.col2 - + col0 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT cor0.col1 * + col2 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT + ( 13 ) FROM tab2 AS cor0
----
13
13
13

query I rowsort
SELECT DISTINCT - 57 * 10 + cor0.col0 * - col1 * col1 + + col1 FROM tab2 cor0
----
-23384
-272029
-7266

query I rowsort
SELECT ALL - + 6 - 83 * col2 * + col2 FROM tab2 AS cor0
----
-119858
-56114
-60513

query I rowsort
SELECT ( + 87 ) * - col0 AS col1 FROM tab2 AS cor0
----
-609
-6786
-6873

query I rowsort
SELECT ALL + col2 + - cor0.col2 * col2 FROM tab2 cor0
----
-1406
-650
-702

query I rowsort
SELECT + + 98 * - 28 + + col1 FROM tab1 AS cor0
----
-2718
-2731
-2734

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2906
SELECT DISTINCT + CAST( + col0 AS SIGNED ) * + col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-2906
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) * + col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - cor0.col2 col1 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2908
SELECT - col0 * + col0 * CAST( col0 * col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-2401
-37015056
-38950081

skipif mysql # not compatible
query I rowsort label-2908
SELECT - col0 * + col0 * CAST ( col0 * col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-2401
-37015056
-38950081

onlyif mysql # use DIV operator for integer division
query I rowsort label-2909
SELECT DISTINCT - col0 - + col2 DIV col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-2909
SELECT DISTINCT - col0 - + col2 / col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + + 23 FROM tab2 cor0
----
23

query I rowsort
SELECT ALL 52 + - cor0.col2 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 4859475101036fb584481e2b7cdc31b5

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab0, tab1 AS cor1
----
3645 values hashing to 73edaf471aef3f42e9a0b0be98b79374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col0 col1 FROM tab1, tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT ( tab2.col2 + + col2 ) * + col0 FROM tab2
----
378
4056
6004

query I rowsort
SELECT ALL tab2.col2 + 64 FROM tab2
----
102
90
91

query I rowsort
SELECT col2 * 61 FROM tab0
----
2013
5002
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT col2 + + 27 AS col0 FROM tab1
----
123
81
84

query I rowsort
SELECT - + 82 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to ce62f59690969f4492d78eb57c3181f0

query I rowsort
SELECT 94 * + cor1.col2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 61314d114015f6f0a5e9f0e24cb6cc5a

query I rowsort
SELECT ALL col1 + - 11 * col1 + col1 * - col1 * - col1 AS col0 FROM tab2
----
204789
29481
4743

query I rowsort
SELECT ALL - 10 * ( col2 ) AS col1 FROM tab0
----
-10
-330
-820

query I rowsort
SELECT ALL col0 * + col0 * col1 FROM tab1
----
234
40960
83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-2924
SELECT + 25 * col2 + col2 * + col1 DIV col1 AS col1 FROM tab1
----
1404
1482
2496

skipif mysql # not compatible
query I rowsort label-2924
SELECT + 25 * col2 + col2 * + col1 / col1 AS col1 FROM tab1
----
1404
1482
2496

query I rowsort
SELECT ALL - 75 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to c0722b1d77ac0ed13c0f2691a5751c59

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2927
SELECT ALL - col2 DIV 84 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2927
SELECT ALL - col2 / 84 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + cor0.col0 + cor0.col0 * - cor0.col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT 51 + col0 * col1 AS col2 FROM tab2 AS cor0
----
1394
268
4653

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2930
SELECT ALL + CAST( + col1 AS SIGNED ) col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2930
SELECT ALL + CAST ( + col1 AS INTEGER ) col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2931
SELECT + - col1 DIV col0 AS col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2931
SELECT + - col1 / col0 AS col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT tab1.col1 + - 72 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 1e89d4caac43c937412f6e8ceb08cffc

query I rowsort
SELECT DISTINCT - 40 + + col2 * + col1 * + 71 FROM tab1
----
40430
88568
99644

query I rowsort
SELECT ALL + col1 * + col1 + + col1 AS col2 FROM tab2
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-2935
SELECT ALL col1 DIV - tab2.col1 - col1 AS col2 FROM tab2
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-2935
SELECT ALL col1 / - tab2.col1 - col1 AS col2 FROM tab2
----
-18
-32
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 - col2 col1 FROM tab0
----
53
9
96

query I rowsort
SELECT + 97 + - col0 FROM tab0 cor0
----
62
73
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 88 col0 FROM tab2 AS cor0
----
-88
-88
-88

query I rowsort
SELECT DISTINCT 82 - + col2 FROM tab0 AS cor0
----
0
49
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col1 - col0 col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + cor0.col2 * - 64 * 3 FROM tab2, tab2 AS cor0
----
-4992
-5184
-7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-2942
SELECT DISTINCT col1 - col1 DIV + col1 AS col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-2942
SELECT DISTINCT col1 - col1 / + col1 AS col0 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT ALL cor0.col0 + ( 4 * - col1 ) FROM tab0 AS cor0
----
-275
-320
-353

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + ( col0 ) col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-2945
SELECT ALL col0 * cor0.col1 + + col1 * col1 + + col2 DIV col2 FROM tab1 AS cor0
----
1210
741
755

skipif mysql # not compatible
query I rowsort label-2945
SELECT ALL col0 * cor0.col1 + + col1 * col1 + + col2 / col2 FROM tab1 AS cor0
----
1210
741
755

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2946
SELECT + - col2 * CAST( col1 AS SIGNED ) + col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

skipif mysql # not compatible
query I rowsort label-2946
SELECT + - col2 * CAST ( col1 AS INTEGER ) + col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + + col2 + col1 * cor0.col2 FROM tab0 cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - cor0.col1 + 95 * - col1 AS col0 FROM tab1 cor0
----
-1248
-2496
-960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2949
SELECT ALL - col1 * - CAST( NULL AS DECIMAL ) + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2949
SELECT ALL - col1 * - CAST ( NULL AS REAL ) + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col2 * col0 + + 72 * col0 AS col0 FROM tab1 cor0
----
13440
378
8256

query I rowsort
SELECT ALL - + col2 - - 96 FROM tab2 AS cor0
----
58
69
70

query I rowsort
SELECT DISTINCT col2 + 50 FROM tab2 AS cor0
----
76
77
88

query I rowsort
SELECT ALL col0 - col1 * col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT ALL - col2 * 50 + + col1 * + col2 AS col2 FROM tab0 AS cor0
----
1188
3362
47

query I rowsort
SELECT ALL col1 + ( + col2 * col0 ) FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT - col0 * + 18 FROM tab2 cor0
----
-126
-1404
-1422

onlyif mysql # use DIV operator for integer division
query I rowsort label-2957
SELECT + - cor0.col2 - cor0.col1 DIV + cor0.col1 AS col1 FROM tab2 AS cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-2957
SELECT + - cor0.col2 - cor0.col1 / + cor0.col1 AS col1 FROM tab2 AS cor0
----
-27
-28
-39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2958
SELECT ALL + col2 * - col0 * ( col0 ) + - CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-233462
-460
-614387

skipif mysql # not compatible
query I rowsort label-2958
SELECT ALL + col2 * - col0 * ( col0 ) + - CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-233462
-460
-614387

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2959
SELECT DISTINCT col1 * + ( col2 ) + cor0.col2 + CAST( 61 AS SIGNED ) * + col2 AS col2 FROM tab0 AS cor0
----
12546
159
4884

skipif mysql # not compatible
query I rowsort label-2959
SELECT DISTINCT col1 * + ( col2 ) + cor0.col2 + CAST ( 61 AS INTEGER ) * + col2 AS col2 FROM tab0 AS cor0
----
12546
159
4884

query I rowsort
SELECT DISTINCT 17 * col1 + col2 AS col1 FROM tab2
----
1029
327
554

query I rowsort
SELECT col1 * + col1 + + 28 * + col2 FROM tab2 AS cor0
----
1353
1717
4209

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) * 3 col2 FROM tab1
----
192
240
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2963
SELECT DISTINCT + 87 DIV + tab0.col1 col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2963
SELECT DISTINCT + 87 / + tab0.col1 col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
0
1

query I rowsort
SELECT - col2 + col1 + col0 AS col1 FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT col2 * 21 FROM tab2 AS cor0
----
546
567
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-2966
SELECT col0 + + col2 DIV 30 FROM tab0
----
25
35
91

skipif mysql # not compatible
query I rowsort label-2966
SELECT col0 + + col2 / 30 FROM tab0
----
25
35
91

query I rowsort
SELECT DISTINCT + 3 + - col0 AS col2 FROM tab1 AS cor0
----
-61
-77
0

query I rowsort
SELECT + col1 * 44 - col2 AS col2 FROM tab1 AS cor0
----
1090
383
476

query I rowsort
SELECT ALL col0 + col2 + - col2 AS col1 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2970
SELECT DISTINCT - + col2 + 42 DIV + col0 AS col0 FROM tab0 AS cor0
----
-32
-82
0

skipif mysql # not compatible
query I rowsort label-2970
SELECT DISTINCT - + col2 + 42 / + col0 AS col0 FROM tab0 AS cor0
----
-32
-82
0

query I rowsort
SELECT ( 0 ) + + cor0.col2 + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + ( + cor0.col1 ) * col0 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - + 22 * col1 FROM tab0 cor0
----
-1892
-2002
-2134

onlyif mysql # use DIV operator for integer division
query I rowsort label-2974
SELECT - - col1 + - cor0.col2 DIV col0 AS col2 FROM tab1 AS cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-2974
SELECT - - col1 + - cor0.col2 / col0 AS col2 FROM tab1 AS cor0
----
10
12
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2975
SELECT DISTINCT + CAST( - 23 AS SIGNED ) * col2 FROM tab0 AS cor0
----
-1886
-23
-759

skipif mysql # not compatible
query I rowsort label-2975
SELECT DISTINCT + CAST ( - 23 AS INTEGER ) * col2 FROM tab0 AS cor0
----
-1886
-23
-759

query I rowsort
SELECT ALL 7 * + col2 AS col1 FROM tab1 AS cor0
----
378
399
672

onlyif mysql # use DIV operator for integer division
query I rowsort label-2977
SELECT ( col2 ) DIV col0 col0 FROM tab0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2977
SELECT ( col2 ) / col0 col0 FROM tab0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 63 * cor0.col1 + + 4 col1 FROM tab2 AS cor0
----
-1067
-1949
-3713

onlyif mysql # use DIV operator for integer division
query I rowsort label-2979
SELECT - + col2 DIV cor0.col1 + + 15 * cor0.col1 FROM tab0 AS cor0
----
1290
1365
1455

skipif mysql # not compatible
query I rowsort label-2979
SELECT - + col2 / cor0.col1 + + 15 * cor0.col1 FROM tab0 AS cor0
----
1290
1365
1455

query I rowsort
SELECT DISTINCT + ( + col1 * + col0 ) AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT - col1 * col0 - col2 * + col2 * + col0 FROM tab1 AS cor0
----
-208576
-738320
-8826

query I rowsort
SELECT + + cor0.col0 + col2 * - 11 AS col0 FROM tab1 cor0
----
-563
-591
-976

query I rowsort
SELECT - 59 * - col2 FROM tab1 AS cor0
----
3186
3363
5664

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2984
SELECT + col1 + + col2 * + CAST( NULL AS SIGNED ) + - col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2984
SELECT + col1 + + col2 * + CAST ( NULL AS INTEGER ) + - col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2985
SELECT ALL + col0 + + col0 * CAST( ( + cor0.col2 ) AS SIGNED ) FROM tab2 AS cor0
----
196
2106
3081

skipif mysql # not compatible
query I rowsort label-2985
SELECT ALL + col0 + + col0 * CAST ( ( + cor0.col2 ) AS INTEGER ) FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + cor0.col1 - col0 FROM tab0 cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2987
SELECT col1 * + col1 + 17 DIV + col0 AS col2 FROM tab1 cor0
----
100
169
681

skipif mysql # not compatible
query I rowsort label-2987
SELECT col1 * + col1 + 17 / + col0 AS col2 FROM tab1 cor0
----
100
169
681

query I rowsort
SELECT ALL cor2.col0 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 cor2
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT DISTINCT - 58 FROM tab0, tab0 cor0
----
-58

query I rowsort
SELECT DISTINCT - cor0.col0 * - cor0.col0 FROM tab1, tab0 AS cor0
----
1225
576
7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2991
SELECT + CAST( + 11 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
11
11
11

skipif mysql # not compatible
query I rowsort label-2991
SELECT + CAST ( + 11 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
11
11
11

query I rowsort
SELECT DISTINCT + 20 * ( + col2 ) * ( 11 ) + - col1 AS col0 FROM tab2 AS cor0
----
5661
5909
8343

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col0 * col1 + 25 col0 FROM tab2
----
-22806
-271493
-6702

query I rowsort
SELECT ALL - col0 + col2 * col2 AS col1 FROM tab2
----
1365
598
722

query I rowsort
SELECT 64 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT DISTINCT - col1 * + col1 - col1 FROM tab0 cor0
----
-7482
-8372
-9506

query I rowsort
SELECT + tab2.col0 * cor0.col2 + 85 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to d967e9719071119636a81eb44305d1a0

query I rowsort
SELECT - tab0.col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # use DIV operator for integer division
query I rowsort label-2999
SELECT DISTINCT tab2.col1 * - col2 * col1 + 0 + - col0 * col0 DIV - 15 FROM tab2
----
-10566
-25944
-90101

skipif mysql # not compatible
query I rowsort label-2999
SELECT DISTINCT tab2.col1 * - col2 * col1 + 0 + - col0 * col0 / - 15 FROM tab2
----
-10566
-25944
-90101

query I rowsort
SELECT + col1 * col2 + - tab0.col2 FROM tab0
----
2805
7380
96

query I rowsort
SELECT ALL + + col1 * - 37 + col1 + col0 AS col1 FROM tab0 AS cor0
----
-3072
-3187
-3457

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + ( col2 ) * - col1 * - col2 col0 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT DISTINCT col0 + + col1 * - 8 AS col0 FROM tab1 AS cor0
----
-16
-205
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - ( + ( + col2 ) ) + 73 col0 FROM tab1
----
-1175
-1331
-497

query I rowsort
SELECT DISTINCT + - col0 + ( 32 ) * col2 AS col0 FROM tab0 AS cor0
----
-3
1032
2535

query I rowsort
SELECT ALL + col0 * col0 * + 14 AS col0 FROM tab2 AS cor0
----
686
85176
87374

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3007
SELECT col2 + CAST( col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-3007
SELECT col2 + CAST ( col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col1 + + cor0.col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT ALL + col1 + + ( - col1 ) FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT col0 + 62 * col1 FROM tab2 AS cor0
----
1133
1929
3736

onlyif mysql # use DIV operator for integer division
query I rowsort label-3012
SELECT col2 DIV 4 FROM tab1 AS cor0
----
13
14
24

skipif mysql # not compatible
query I rowsort label-3012
SELECT col2 / 4 FROM tab1 AS cor0
----
13
14
24

query I rowsort
SELECT + + col1 * 55 AS col0 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT col2 * 97 * 30 FROM tab2 AS cor0
----
110580
75660
78570

query I rowsort
SELECT - + 69 + 56 * col0 FROM tab2 cor0
----
323
4299
4355

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) + col0 + + col0 col0 FROM tab1
----
3
64
80

query I rowsort
SELECT + col2 + - col0 * col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT - ( - 76 ) + col2 * 64 - 14 FROM tab1 AS cor0
----
3518
3710
6206

onlyif mysql # use DIV operator for integer division
query I rowsort label-3019
SELECT DISTINCT col1 DIV + 57 + + col0 FROM tab2
----
7
79

skipif mysql # not compatible
query I rowsort label-3019
SELECT DISTINCT col1 / + 57 + + col0 FROM tab2
----
7
79

query I rowsort
SELECT + col0 * - col2 * col1 AS col0 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3021
SELECT DISTINCT col2 DIV col0 + - col0 FROM tab1 cor0
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-3021
SELECT DISTINCT col2 / col0 + - col0 FROM tab1 cor0
----
-64
-79
15

query I rowsort
SELECT ALL - + col1 * + 31 + + col2 FROM tab0 AS cor0
----
-2633
-2739
-3006

query I rowsort
SELECT ALL 82 + - col2 * col2 FROM tab2 AS cor0
----
-1362
-594
-647

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3024
SELECT CAST( NULL AS SIGNED ) * + cor0.col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3024
SELECT CAST ( NULL AS INTEGER ) * + cor0.col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 91 + col1 FROM tab0 AS cor0
----
-5
0
6

query I rowsort
SELECT ALL - + 12 + - col1 - - col2 * - 97 FROM tab2 AS cor0
----
-2593
-2662
-3715

query I rowsort
SELECT DISTINCT ( col0 ) + + cor0.col2 * cor0.col0 + + col1 FROM tab1 AS cor0
----
191
3722
7773

onlyif mysql # use DIV operator for integer division
query I rowsort label-3028
SELECT + + cor0.col0 * col0 + - col2 DIV - cor0.col0 AS col1 FROM tab1 AS cor0
----
27
4096
6401

skipif mysql # not compatible
query I rowsort label-3028
SELECT + + cor0.col0 * col0 + - col2 / - cor0.col0 AS col1 FROM tab1 AS cor0
----
27
4096
6401

query I rowsort
SELECT ALL + col1 * - col1 + - col1 + col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - + col0 + 53 - col0 AS col0 FROM tab0 AS cor0
----
-125
-17
5

query I rowsort
SELECT DISTINCT - 88 AS col0 FROM tab0 AS cor0
----
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-3032
SELECT + cor0.col2 DIV 89 + + cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

skipif mysql # not compatible
query I rowsort label-3032
SELECT + cor0.col2 / 89 + + cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3033
SELECT + ( col1 ) + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3033
SELECT + ( col1 ) + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 79 * - col0 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
240
5120
6400

query I rowsort
SELECT ALL - cor0.col2 + - col2 * ( col2 ) FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT - col2 * col0 + col1 * - 50 AS col1 FROM tab2 AS cor0
----
-1739
-3852
-4978

query I rowsort
SELECT DISTINCT - ( col2 ) * - 7 AS col0 FROM tab1 AS cor0
----
378
399
672

onlyif mysql # use DIV operator for integer division
query I rowsort label-3038
SELECT 55 + col1 DIV col1 col0 FROM tab0 AS cor0
----
56
56
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3038
SELECT 55 + col1 / col1 col0 FROM tab0 AS cor0
----
56
56
56

query I rowsort
SELECT ALL - col1 * + col1 * col1 AS col0 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT ALL col0 + - col2 * - col0 AS col0 FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT - + col2 * col1 + + ( + col2 ) AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT - 29 * + col0 AS col1 FROM tab1 AS cor0
----
-1856
-2320
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-3043
SELECT ALL + col0 + col2 DIV + 55 AS col1 FROM tab0 AS cor0
----
24
35
90

skipif mysql # not compatible
query I rowsort label-3043
SELECT ALL + col0 + col2 / + 55 AS col1 FROM tab0 AS cor0
----
24
35
90

query I rowsort
SELECT DISTINCT + 63 AS col2 FROM tab1 cor0
----
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 89 + col1 * + ( 97 ) col2 FROM tab0 cor0
----
8253
8738
9320

query I rowsort
SELECT 76 + col2 * col2 AS col2 FROM tab2 AS cor0
----
1520
752
805

query I rowsort
SELECT - + col0 * - col1 - 40 FROM tab0 AS cor0
----
2024
3355
8059

query I rowsort
SELECT col0 + + 48 - col2 FROM tab0
----
39
55
82

query I rowsort
SELECT DISTINCT col2 - 28 AS col1 FROM tab1
----
26
29
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3050
SELECT col1 + col2 + CAST( col1 AS SIGNED ) AS col1 FROM tab0
----
195
205
264

skipif mysql # not compatible
query I rowsort label-3050
SELECT col1 + col2 + CAST ( col1 AS INTEGER ) AS col1 FROM tab0
----
195
205
264

onlyif mysql # use DIV operator for integer division
query I rowsort label-3051
SELECT + 89 + + col2 DIV + col1 AS col1 FROM tab1
----
91
94
96

skipif mysql # not compatible
query I rowsort label-3051
SELECT + 89 + + col2 / + col1 AS col1 FROM tab1
----
91
94
96

query I rowsort
SELECT col1 + + 34 AS col1 FROM tab2 AS cor0
----
51
65
93

query I rowsort
SELECT ALL + col1 * col2 * - 70 + - col1 * - col2 AS col2 FROM tab2
----
-105846
-44574
-57753

query I rowsort
SELECT ALL - - 24 * 70 AS col2 FROM tab1 cor0
----
1680
1680
1680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3055
SELECT DISTINCT + CAST( 29 AS SIGNED ) * cor0.col2 FROM tab2 AS cor0
----
1102
754
783

skipif mysql # not compatible
query I rowsort label-3055
SELECT DISTINCT + CAST ( 29 AS INTEGER ) * cor0.col2 FROM tab2 AS cor0
----
1102
754
783

onlyif mysql # use DIV operator for integer division
query I rowsort label-3056
SELECT 21 DIV col0 AS col2 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-3056
SELECT 21 / col0 AS col2 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL - 4 * col1 FROM tab2
----
-124
-236
-68

query I rowsort
SELECT ALL - ( col2 ) + - tab2.col1 - col2 AS col1 FROM tab2
----
-111
-85
-93

query I rowsort
SELECT - 61 + 85 AS col0 FROM tab2, tab0, tab0 cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 * col2 AS col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-3061
SELECT + 94 DIV 69 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3061
SELECT + 94 / 69 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - 35 * 62 FROM tab0
----
-2170
-2170
-2170

query I rowsort
SELECT ALL - 53 * + col2 AS col0 FROM tab1 AS cor0
----
-2862
-3021
-5088

query I rowsort
SELECT ALL + + 87 * 25 FROM tab2 AS cor0
----
2175
2175
2175

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + tab1.col1 col0 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL + col2 * - col1 + + col1 + + col0 FROM tab0 AS cor0
----
-2728
-7282
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3067
SELECT + col1 * CAST( NULL AS SIGNED ) - col0 * + col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3067
SELECT + col1 * CAST ( NULL AS INTEGER ) - col0 * + col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 50 * col2 * col1 - - col2 FROM tab1 AS cor0
----
-28443
-62304
-70146

query I rowsort
SELECT col0 * - 66 AS col0 FROM tab2
----
-462
-5148
-5214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 69 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col0 col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT 67 * + col0 FROM tab0 AS cor0
----
1608
2345
5963

onlyif mysql # use DIV operator for integer division
query I rowsort label-3073
SELECT ALL + col0 + col0 DIV - col0 col1 FROM tab1 AS cor0
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3073
SELECT ALL + col0 + col0 / - col0 col1 FROM tab1 AS cor0
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 43 col1 FROM tab0
----
-43
-43
-43

query I rowsort
SELECT ALL + 63 AS col1 FROM tab0 cor0
----
63
63
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3076
SELECT - + col1 * col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3076
SELECT - + col1 * col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col2 FROM tab2, tab0 cor0, tab0 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col0 col1 FROM tab2, tab1, tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT col1 + col2 * + cor0.col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL + col1 * ( cor0.col0 + col2 * 98 ) FROM tab0 AS cor0
----
12901
280188
739375

query I rowsort
SELECT DISTINCT + - cor0.col0 * + col1 * 31 + - col1 * - 32 FROM tab2 AS cor0
----
-140774
-41089
-5735

onlyif mysql # use DIV operator for integer division
query I rowsort label-3082
SELECT ALL - col0 DIV ( + col1 ) AS col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-3082
SELECT ALL - col0 / ( + col1 ) AS col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT + col1 * - ( col1 ) AS col1 FROM tab2 cor0
----
-289
-3481
-961

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 I rowsort
SELECT ALL - ( - 35 ) AS col2 FROM tab1, tab1 cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3086
SELECT - col1 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3086
SELECT - col1 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 * cor0.col1 * - col0 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT - 10 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT col0 * 64 AS col1 FROM tab2
----
448
4992
5056

query I rowsort
SELECT ALL + + ( + col2 ) * ( 48 ) + col0 AS col1 FROM tab0 AS cor0
----
1608
4025
83

query I rowsort
SELECT - 94 AS col0 FROM tab2 cor0
----
-94
-94
-94

query I rowsort
SELECT 55 * 8 AS col1 FROM tab1
----
440
440
440

query I rowsort
SELECT ALL 39 + col2 FROM tab2 AS cor0
----
65
66
77

query I rowsort
SELECT ( ( + col0 ) ) FROM tab2
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3095
SELECT + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3095
SELECT + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col2 * - col2 + + col1 FROM tab1 cor0
----
-2890
-3239
-9203

query I rowsort
SELECT DISTINCT tab2.col2 * - 9 AS col2 FROM tab2, tab1 AS cor0
----
-234
-243
-342

query I rowsort
SELECT DISTINCT col0 * + col0 + col2 AS col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT - cor0.col0 + col2 * ( + col0 ) * cor0.col2 AS col2 FROM tab2 AS cor0
----
113997
5096
52650

query I rowsort
SELECT + - 30 FROM tab0 AS cor0
----
-30
-30
-30

query I rowsort
SELECT + 34 * - col0 + ( - col0 ) * + col2 FROM tab1 AS cor0
----
-10400
-264
-5824

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 13 * + col0 col1 FROM tab1 AS cor0
----
-1040
-39
-832

query I rowsort
SELECT ALL col1 + - col0 * col2 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL + cor0.col2 * col2 + + col2 * - col0 * - col1 + - col1 FROM tab1 cor0
----
109043
39719
7102

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 + col0 * - col0 + + col0 col1 FROM tab0 AS cor0
----
-1225
-1344
-15130

query I rowsort
SELECT DISTINCT col1 + - col2 * + cor0.col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL + col2 * col0 + - col1 * col0 FROM tab1 cor0
----
3008
6640
84

query I rowsort
SELECT ALL col0 * - col2 - - tab2.col1 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT + col1 + - col2 * + col2 AS col1 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT ALL col0 + + tab1.col2 - - col0 AS col0 FROM tab1
----
185
256
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 * - col0 - + col0 col2 FROM tab1
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-3112
SELECT ALL - tab1.col2 + + col0 DIV - col0 - col2 * + col1 FROM tab1
----
-1345
-1459
-628

skipif mysql # not compatible
query I rowsort label-3112
SELECT ALL - tab1.col2 + + col0 / - col0 - col2 * + col1 FROM tab1
----
-1345
-1459
-628

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) NOT BETWEEN - col2 + col2 * + col1 AND NULL
----

query I rowsort
SELECT cor0.col0 * col2 + col0 + col1 AS col2 FROM tab0 AS cor0
----
167
7478
902

query I rowsort
SELECT DISTINCT - tab1.col2 + - tab1.col1 + + tab1.col0 * col1 FROM tab1
----
-2
573
931

query I rowsort
SELECT ALL + tab2.col2 + col1 * - col1 * col2 + - col0 AS col1 FROM tab2
----
-11023
-25927
-90558

query I rowsort
SELECT + col2 * + col1 + col1 * col1 * - col1 + col0 AS col1 FROM tab0 AS cor0
----
-633194
-746020
-912541

query I rowsort
SELECT cor0.col0 + + col0 * col0 + col0 FROM tab0 AS cor0
----
1295
624
8099

query I rowsort
SELECT + - col0 + + col0 * col0 * + col2 + col0 * col1 FROM tab0 AS cor0
----
21048
4585
657532

query I rowsort
SELECT col0 + + col0 * col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + 78 + - col2 AS col1 FROM tab1 AS cor0
----
-18
21
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-3122
SELECT ALL - col2 DIV - col1 + + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3122
SELECT ALL - col2 / - col1 + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - - 58 * col0 AS col0 FROM tab1 AS cor0
----
174
3712
4640

query I rowsort
SELECT + col2 * - col0 - - col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + + col2 + col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + + col1 * col2 - - cor0.col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL - - cor0.col1 + + col1 FROM tab0 cor0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-3128
SELECT ALL col2 + col2 DIV - col0 col0 FROM tab1
----
36
57
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3128
SELECT ALL col2 + col2 / - col0 col0 FROM tab1
----
36
57
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-3129
SELECT DISTINCT - col2 + col1 DIV + col2 FROM tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3129
SELECT DISTINCT - col2 + col1 / + col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT + col1 * - cor0.col0 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT tab2.col0 - col0 * col1 AS col0 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT - col1 + + col0 * + col1 * col1 AS col0 FROM tab1
----
13507
2002
6390

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 * + tab1.col0 col0 FROM tab1
----
35
4106
6413

query I rowsort
SELECT DISTINCT + col0 - + tab1.col2 * col1 * col0 FROM tab1 WHERE NOT ( NULL ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL - col1 * tab0.col2 + + col0 AS col0 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT col2 + col1 * col0 FROM tab1 WHERE NOT + col0 BETWEEN col0 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 + - col2 * col1 col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT ALL col0 + + col0 - col2 * - col2 FROM tab1 cor0
----
2922
3377
9376

query I rowsort
SELECT DISTINCT - col2 * - col1 - - col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-3140
SELECT DISTINCT + col1 DIV + col1 + col0 * tab2.col0 FROM tab2
----
50
6085
6242

skipif mysql # not compatible
query I rowsort label-3140
SELECT DISTINCT + col1 / + col1 + col0 * tab2.col0 FROM tab2
----
50
6085
6242

query I rowsort
SELECT - col1 * - col2 * + col0 AS col0 FROM tab1
----
36480
4212
99840

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( - col2 ) = NULL
----

query I rowsort
SELECT + col2 + col2 + col1 AS col1 FROM tab1
----
124
134
205

query I rowsort
SELECT DISTINCT col0 * + col0 + col0 AS col1 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT + col0 + col0 * - col0 + col0 FROM tab0
----
-1155
-528
-7743

query I rowsort
SELECT col0 + col0 * - col2 + - col2 FROM tab0
----
-1
-7291
-801

query III rowsort
SELECT * FROM tab1 cor0 WHERE NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL + cor0.col2 - + col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + tab0.col1 + col2 / tab0.col1 + + col2 FROM tab0 WHERE NOT ( NULL ) IN ( - col2 + - col0 / - tab0.col0 )
----

query I rowsort
SELECT + col0 + col0 * + col1 * - col2 - col0 * - col2 AS col1 FROM tab2
----
-117546
-47953
-5663

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL <= col1
----

query I rowsort
SELECT DISTINCT - col2 + + col2 * - col1 FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT - tab2.col2 * + col1 AS col0 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + tab0.col0 * + tab0.col1 + col0 FROM tab0 WHERE NOT NULL NOT IN ( - col2 * - col1 * + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3155
SELECT ALL col0 DIV + col2 + + col0 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-3155
SELECT ALL col0 / + col2 + + col0 FROM tab0
----
24
70
90

query I rowsort
SELECT + col0 + tab1.col0 AS col0 FROM tab1
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3157
SELECT DISTINCT col2 DIV - tab0.col0 + - col1 * + col0 AS col1 FROM tab0
----
-2065
-3395
-8099

skipif mysql # not compatible
query I rowsort label-3157
SELECT DISTINCT col2 / - tab0.col0 + - col1 * + col0 AS col1 FROM tab0
----
-2065
-3395
-8099

query I rowsort
SELECT + col2 FROM tab0 WHERE NOT NULL < col2
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3159
SELECT ALL - CAST( NULL AS SIGNED ) * cor0.col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3159
SELECT ALL - CAST ( NULL AS INTEGER ) * cor0.col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3160
SELECT + + ( cor0.col0 ) * col0 DIV - 82 FROM tab2 cor0
----
-74
-76
0

skipif mysql # not compatible
query I rowsort label-3160
SELECT + + ( cor0.col0 ) * col0 / - 82 FROM tab2 cor0
----
-74
-76
0

query I rowsort
SELECT + 87 + col0 * ( + cor0.col1 ) FROM tab2 AS cor0
----
1430
304
4689

query I rowsort
SELECT ALL + + col2 + + ( - col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + - 16 FROM tab0 AS cor0
----
-102
-107
-113

query I rowsort
SELECT - 82 * - col2 AS col0 FROM tab0 AS cor0
----
2706
6724
82

query I rowsort
SELECT 13 * col2 AS col1 FROM tab1 AS cor0
----
1248
702
741

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 70 + col0 * - col0 col1 FROM tab0 AS cor0
----
-1120
-482
-7762

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3167
SELECT cor0.col0 - + CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3167
SELECT cor0.col0 - + CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3168
SELECT col2 * col2 DIV + col0 AS col0 FROM tab0 AS cor0
----
0
45
75

skipif mysql # not compatible
query I rowsort label-3168
SELECT col2 * col2 / + col0 AS col0 FROM tab0 AS cor0
----
0
45
75

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( 42 AS REAL ) + + col0 AS col2 FROM tab1 AS cor0
----
-39
22
38

query I rowsort
SELECT col0 * - col1 * col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-3171
SELECT col1 * + col2 + - tab0.col1 * col2 DIV col0 FROM tab0
----
2720
7379
95

skipif mysql # not compatible
query I rowsort label-3171
SELECT col1 * + col2 + - tab0.col1 * col2 / col0 FROM tab0
----
2720
7379
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3172
SELECT - CAST( + 97 AS SIGNED ) + + col2 AS col2 FROM tab2
----
-59
-70
-71

skipif mysql # not compatible
query I rowsort label-3172
SELECT - CAST ( + 97 AS INTEGER ) + + col2 AS col2 FROM tab2
----
-59
-70
-71

query I rowsort
SELECT 99 + 33 * col1 FROM tab0
----
2937
3102
3300

query I rowsort
SELECT DISTINCT ( col2 ) + col1 AS col2 FROM tab1
----
109
67
80

query I rowsort
SELECT - ( col0 ) * - cor0.col0 * col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT + cor0.col1 * col1 * col0 + col2 * col2 FROM tab0 AS cor0
----
178593
329316
743733

query I rowsort
SELECT DISTINCT - 96 * - col2 + col0 * + col0 FROM tab2 AS cor0
----
2641
8580
9889

query I rowsort
SELECT ALL - 86 - cor0.col0 AS col1 FROM tab2 AS cor0
----
-164
-165
-93

query I rowsort
SELECT ALL + col2 + - col0 * col0 FROM tab0 cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL 24 + col1 FROM tab1 AS cor0
----
34
37
50

query I rowsort
SELECT ALL 45 AS col1 FROM tab2 AS cor0
----
45
45
45

query I rowsort
SELECT + col0 + col2 * + col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 - cor0.col2 col1 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT DISTINCT + - col1 * - col0 - + col0 AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT + col1 - 52 FROM tab0
----
34
39
45

query I rowsort
SELECT DISTINCT col0 + 2 * col1 FROM tab2
----
113
196
69

query I rowsort
SELECT + col0 + 50 + - 48 AS col2 FROM tab2 AS cor0
----
80
81
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3188
SELECT - col0 * - CAST( 1 AS SIGNED ) - col0 col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3188
SELECT - col0 * - CAST ( 1 AS INTEGER ) - col0 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 + 75 FROM tab0 AS cor0
----
108
157
76

query I rowsort
SELECT - col1 - + ( col0 ) FROM tab1 AS cor0
----
-29
-74
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col2 + cor0.col0 * + col1 + cor0.col0 col1 FROM tab2 AS cor0
----
2866
5356
953

query I rowsort
SELECT DISTINCT - 10 AS col0 FROM tab2
----
-10

onlyif mysql # use DIV operator for integer division
query I rowsort label-3193
SELECT col2 DIV + col1 col1 FROM tab2
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3193
SELECT col2 / + col1 col1 FROM tab2
----
0
0
2

query I rowsort
SELECT DISTINCT + cor0.col1 - cor0.col1 FROM tab0, tab0 cor0
----
0

query I rowsort
SELECT - col0 * col1 * - tab2.col2 AS col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - 52 * + col0 FROM tab0
----
-1248
-1820
-4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-3197
SELECT + col1 DIV + col1 + 37 FROM tab1 AS cor0
----
38
38
38

skipif mysql # not compatible
query I rowsort label-3197
SELECT + col1 / + col1 + 37 FROM tab1 AS cor0
----
38
38
38

query I rowsort
SELECT col0 + col2 + col1 AS col1 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT - - col2 - ( + 63 ) AS col2 FROM tab1 AS cor0
----
-6
-9
33

query I rowsort
SELECT DISTINCT - col0 * - 12 AS col0 FROM tab2
----
84
936
948

query I rowsort
SELECT tab2.col1 + ( col0 ) + + col0 * - tab2.col2 FROM tab2
----
-151
-1891
-2906

query I rowsort
SELECT DISTINCT tab0.col0 - ( col0 ) * col0 * col1 FROM tab0
----
-118790
-49512
-720722

query I rowsort
SELECT ALL - - cor0.col2 * 47 AS col0 FROM tab1 AS cor0
----
2538
2679
4512

query I rowsort
SELECT - - col2 + 86 * - col0 AS col0 FROM tab0 AS cor0
----
-2031
-3009
-7572

query I rowsort
SELECT - col2 * tab0.col2 + - tab0.col1 AS col1 FROM tab0
----
-1175
-6815
-98

query I rowsort
SELECT - - col1 * - ( - cor0.col1 ) FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + + col0 * 20 - ( + col1 ) FROM tab2 cor0
----
109
1501
1563

query I rowsort
SELECT - 40 * + 50 FROM tab2, tab1 AS cor0
----
9 values hashing to 351f8eda1a02b48af44f05bf34a3fe8e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3209
SELECT ALL + + col1 * CAST( 3 AS SIGNED ) - cor0.col0 FROM tab2 AS cor0
----
-28
86
99

skipif mysql # not compatible
query I rowsort label-3209
SELECT ALL + + col1 * CAST ( 3 AS INTEGER ) - cor0.col0 FROM tab2 AS cor0
----
-28
86
99

query I rowsort
SELECT ALL + col2 - - tab1.col0 * - 2 FROM tab1
----
-64
-71
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-3211
SELECT col0 DIV + col0 + + col1 - - col1 * col0 FROM tab0
----
2151
3493
8191

skipif mysql # not compatible
query I rowsort label-3211
SELECT col0 / + col0 + + col1 - - col1 * col0 FROM tab0
----
2151
3493
8191

query I rowsort
SELECT DISTINCT + 98 + 22 AS col2 FROM tab2 AS cor0
----
120

query I rowsort
SELECT - - 49 + col2 FROM tab1 AS cor0
----
103
106
145

query I rowsort
SELECT + - ( - col0 ) * - col2 + 86 AS col2 FROM tab0 AS cor0
----
-706
-7212
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-3215
SELECT DISTINCT col2 + - ( 6 ) DIV col2 - + col1 * - col1 FROM tab0
----
7429
8363
9404

skipif mysql # not compatible
query I rowsort label-3215
SELECT DISTINCT col2 + - ( 6 ) / col2 - + col1 * - col1 FROM tab0
----
7429
8363
9404

query I rowsort
SELECT ALL col1 * 20 + - 0 * col1 AS col1 FROM tab1
----
200
260
520

query I rowsort
SELECT - - col2 * col1 + ( + 65 ) AS col1 FROM tab2 AS cor0
----
1599
711
902

query I rowsort
SELECT ALL + col2 + + cor0.col1 * - col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT + col1 + + cor0.col0 AS col2 FROM tab0 cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 14 col2 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT ALL 51 * - col0 FROM tab0 AS cor0
----
-1224
-1785
-4539

query I rowsort
SELECT DISTINCT - + 99 * col1 * col1 FROM tab1 AS cor0
----
-16731
-66924
-9900

query I rowsort
SELECT col1 + col1 * + 66 FROM tab0 AS cor0
----
5762
6097
6499

query I rowsort
SELECT - ( - col0 ) - - col0 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL col2 + + 95 AS col0 FROM tab1
----
149
152
191

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3226
SELECT ALL - + CAST( 13 AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

skipif mysql # not compatible
query I rowsort label-3226
SELECT ALL - + CAST ( 13 AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

query I rowsort
SELECT ALL + - col0 * col2 + col1 FROM tab0 cor0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 14 * + col1 + 2 col0 FROM tab1 AS cor0
----
142
184
366

query I rowsort
SELECT ALL - 52 * col2 FROM tab0 AS cor0
----
-1716
-4264
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3230
SELECT DISTINCT + col2 * col2 DIV col2 col0 FROM tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3230
SELECT DISTINCT + col2 * col2 / col2 col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT 79 * col0 * - 2 + + col1 FROM tab0
----
-13971
-3706
-5433

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col0 * - ( col0 ) col2 FROM tab0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-3233
SELECT + col1 DIV + cor0.col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3233
SELECT + col1 / + cor0.col2 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3234
SELECT ALL + col0 * col1 DIV col2 + + col1 * col1 AS col1 FROM tab1 AS cor0
----
111
179
677

skipif mysql # not compatible
query I rowsort label-3234
SELECT ALL + col0 * col1 / col2 + + col1 * col1 AS col1 FROM tab1 AS cor0
----
111
179
677

query I rowsort
SELECT DISTINCT + + cor0.col0 * - 94 + col0 AS col1 FROM tab0 AS cor0
----
-2232
-3255
-8277

query I rowsort
SELECT DISTINCT + ( - 59 ) AS col1 FROM tab2, tab0 AS cor0
----
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3237
SELECT DISTINCT - ( + tab1.col2 ) * - col0 + CAST( - col2 AS SIGNED ) FROM tab1
----
108
3591
7584

skipif mysql # not compatible
query I rowsort label-3237
SELECT DISTINCT - ( + tab1.col2 ) * - col0 + CAST ( - col2 AS INTEGER ) FROM tab1
----
108
3591
7584

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT DISTINCT - ( 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-3240
SELECT - CAST( NULL AS SIGNED ) - - ( col0 ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3240
SELECT - CAST ( NULL AS INTEGER ) - - ( col0 ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 * 53 FROM tab1 AS cor0
----
-1378
-530
-689

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + 15 + - col2 + col2 col0 FROM tab2 AS cor0
----
-390
-405
-570

query I rowsort
SELECT 43 * + cor0.col2 + col0 AS col0 FROM tab1 AS cor0
----
2325
2515
4208

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3244
SELECT ALL + + CAST( + 43 AS SIGNED ) + col2 AS col1 FROM tab0 cor0
----
125
44
76

skipif mysql # not compatible
query I rowsort label-3244
SELECT ALL + + CAST ( + 43 AS INTEGER ) + col2 AS col1 FROM tab0 cor0
----
125
44
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 43 - col1 col2 FROM tab1 AS cor0
----
-53
-56
-69

query I rowsort
SELECT - 18 * col2 + col1 AS col1 FROM tab0 AS cor0
----
-1385
-508
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3247
SELECT DISTINCT cor0.col1 + col2 DIV + col0 AS col1 FROM tab1 AS cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-3247
SELECT DISTINCT cor0.col1 + col2 / + col0 AS col1 FROM tab1 AS cor0
----
10
14
44

query I rowsort
SELECT DISTINCT - col1 * - col0 - col1 AS col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3249
SELECT ALL + CAST( NULL AS SIGNED ) + col1 + + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3249
SELECT ALL + CAST ( NULL AS INTEGER ) + col1 + + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( 22 AS REAL ) + col0 FROM tab2 AS cor0
----
-15
56
57

query I rowsort
SELECT DISTINCT - + 99 FROM tab2 cor0
----
-99

query I rowsort
SELECT - cor0.col1 + col0 * 3 FROM tab1 AS cor0
----
-17
182
227

query I rowsort
SELECT ALL + col2 * col1 + 20 * 27 FROM tab1 AS cor0
----
1110
1788
1944

query I rowsort
SELECT DISTINCT + col0 + col0 * + 86 AS col1 FROM tab0 AS cor0
----
2088
3045
7743

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3255
SELECT - - col2 * ( col2 ) + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3255
SELECT - - col2 * ( col2 ) + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + + cor0.col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT col2 * 26 + + col2 * col2 AS col0 FROM tab2
----
1352
1431
2432

query I rowsort
SELECT + 80 * col2 AS col0 FROM tab2 AS cor0
----
2080
2160
3040

query I rowsort
SELECT col2 + ( col0 + cor0.col2 ) FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT ALL - col1 * 94 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1636
-2941
-5572

query I rowsort
SELECT DISTINCT - - cor0.col1 * col2 - - col1 AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT 30 * 78 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2e21ad288099e730113c7337af1a790d

query I rowsort
SELECT DISTINCT - 87 * - col0 FROM tab1 AS cor0
----
261
5568
6960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3264
SELECT + ( - col1 + - col1 * CAST( NULL AS SIGNED ) ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3264
SELECT + ( - col1 + - col1 * CAST ( NULL AS INTEGER ) ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 19 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT DISTINCT + 28 + - tab2.col0 + + 31 * col0 * + col1 FROM tab2
----
142612
41582
6748

query I rowsort
SELECT - - cor0.col0 * 9 FROM tab0 AS cor0
----
216
315
801

query I rowsort
SELECT + col1 + + col0 + + col0 FROM tab2 AS cor0
----
175
215
45

query I rowsort
SELECT ALL - col0 * + 16 FROM tab2
----
-112
-1248
-1264

query I rowsort
SELECT + - col0 * 1 + + col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - tab0.col1 * ( - 63 + col0 ) FROM tab0
----
-2366
2716
3354

query I rowsort
SELECT DISTINCT + col2 * + tab2.col1 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT + col0 + col1 + col2 AS col2 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT + col0 * col2 + - col1 - + col2 FROM tab0 AS cor0
----
-63
673
7125

query I rowsort
SELECT DISTINCT 60 AS col1 FROM tab1, tab1 AS cor0
----
60

query I rowsort
SELECT - col1 + cor0.col1 + - col2 * col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-3277
SELECT 3 + + 90 DIV + cor0.col1 FROM tab1 AS cor0
----
12
6
9

skipif mysql # not compatible
query I rowsort label-3277
SELECT 3 + + 90 / + cor0.col1 FROM tab1 AS cor0
----
12
6
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3278
SELECT - ( 90 ) * tab0.col0 + col1 DIV + tab0.col1 FROM tab0
----
-2159
-3149
-8009

skipif mysql # not compatible
query I rowsort label-3278
SELECT - ( 90 ) * tab0.col0 + col1 / + tab0.col1 FROM tab0
----
-2159
-3149
-8009

query I rowsort
SELECT ALL col1 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + col1 * 69 * - col2 AS col2 FROM tab1 AS cor0
----
-39330
-86112
-96876

query I rowsort
SELECT + 76 + + col0 AS col2 FROM tab2
----
154
155
83

query I rowsort
SELECT 51 + + col0 FROM tab1 AS cor0
----
115
131
54

query I rowsort
SELECT ALL cor0.col2 * col1 + - col1 + col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - col1 + + 17 FROM tab2 AS cor0
----
-14
-42
0

query I rowsort
SELECT ALL - - col2 * 87 FROM tab1 AS cor0
----
4698
4959
8352

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 + - 24 col1 FROM tab2 AS cor0
----
-17
54
55

query I rowsort
SELECT - col0 + + ( col1 ) AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL + + col0 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL - col1 - 19 FROM tab1 AS cor0
----
-29
-32
-45

query I rowsort
SELECT cor0.col0 * col0 - cor0.col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT DISTINCT col0 + col2 * ( col2 ) * - 96 + + 53 * + col1 * + col2 FROM tab1 AS cor0
----
-205521
-281630
-818512

onlyif mysql # use DIV operator for integer division
query I rowsort label-3292
SELECT DISTINCT col2 DIV - col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-3292
SELECT DISTINCT col2 / - col1 AS col0 FROM tab0
----
0

query I rowsort
SELECT + 67 * - cor0.col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 7691e3503372b412c3508b8d552ba316

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 51 col1 FROM tab1
----
51
51
51

query I rowsort
SELECT - col1 + 78 * cor0.col1 FROM tab1 AS cor0
----
1001
2002
770

query I rowsort
SELECT DISTINCT + - 10 * ( + cor0.col1 ) + col1 AS col0 FROM tab0 AS cor0
----
-774
-819
-873

query I rowsort
SELECT DISTINCT ( - 54 ) * - col2 FROM tab1 cor0
----
2916
3078
5184

query I rowsort
SELECT ALL + 89 + col1 AS col0 FROM tab1 AS cor0
----
102
115
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3299
SELECT cor1.col1 * CAST( NULL AS DECIMAL ) - + ( cor1.col1 ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3299
SELECT cor1.col1 * CAST ( NULL AS REAL ) - + ( cor1.col1 ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT - 91 + col0 FROM tab0 cor0
----
-2
-56
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-3301
SELECT ALL 14 + col0 DIV col2 FROM tab1 AS cor0
----
14
14
15

skipif mysql # not compatible
query I rowsort label-3301
SELECT ALL 14 + col0 / col2 FROM tab1 AS cor0
----
14
14
15

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col2 AS col0 FROM tab0, tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - ( - 44 ) AS col1 FROM tab0 AS cor0
----
44
44
44

query I rowsort
SELECT DISTINCT 48 FROM tab0, tab1 AS cor0
----
48

query I rowsort
SELECT DISTINCT + cor0.col0 + - col0 * - col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT ALL + - col1 * col2 * cor0.col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL + - col2 + cor0.col2 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + cor0.col0 * + col0 AS col0 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL - - col1 - col2 * col1 * cor0.col0 FROM tab2 AS cor0
----
-119593
-51017
-5828

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col0 + cor0.col0 * col2 col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL col1 + - cor0.col0 * + 40 AS col0 FROM tab0 cor0
----
-1303
-3469
-874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 - col0 col1 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 * 72 col2 FROM tab1 AS cor0
----
-209952
-233928
-663552

query I rowsort
SELECT DISTINCT col1 * col1 * col2 AS col1 FROM tab2 AS cor0
----
10982
25947
90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-3315
SELECT col1 DIV ( + 68 ) + col1 AS col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3315
SELECT col1 / ( + 68 ) + col1 AS col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT - cor0.col2 + col2 + - cor0.col0 * - cor0.col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL - col1 * - 28 * 68 FROM tab0 AS cor0
----
163744
173264
184688

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3318
SELECT DISTINCT - cor0.col1 / - CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3318
SELECT DISTINCT - cor0.col1 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL

query I rowsort
SELECT col1 * - ( + 79 ) FROM tab2 AS cor0
----
-1343
-2449
-4661

query I rowsort
SELECT DISTINCT - + cor0.col1 + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT - col2 + ( 24 ) * - col0 AS col1 FROM tab0 AS cor0
----
-2218
-609
-841

query I rowsort
SELECT + - col2 + 64 + cor0.col0 AS col0 FROM tab1 cor0
----
13
48
71

query I rowsort
SELECT DISTINCT - cor0.col1 * - ( ( + cor0.col2 ) ) FROM tab0 cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3324
SELECT ALL CAST( NULL AS SIGNED ) FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3324
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - cor0.col1 * + 91 + col0 FROM tab0 AS cor0
----
-7802
-8192
-8792

query I rowsort
SELECT ALL col1 * ( + col2 ) - col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT - - col2 + - ( col0 ) * col2 * col0 FROM tab2 cor0
----
-1296
-158158
-237120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 10 col0 FROM tab1 AS cor0
----
-30
-640
-800

query I rowsort
SELECT col2 + col0 * - tab1.col1 AS col2 FROM tab1
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-3330
SELECT ALL + CAST( 37 AS SIGNED ) DIV - col0 - cor0.col2 AS col1 FROM tab0 AS cor0
----
-2
-34
-82

skipif mysql # not compatible
query I rowsort label-3330
SELECT ALL + CAST ( 37 AS INTEGER ) / - col0 - cor0.col2 AS col1 FROM tab0 AS cor0
----
-2
-34
-82

query I rowsort
SELECT DISTINCT + col2 + + col1 - col2 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( - 11 AS REAL ) + + cor0.col1 * cor0.col2 FROM tab0 AS cor0
----
2827
7451
86

query I rowsort
SELECT ALL + col2 + + 56 AS col1 FROM tab1 AS cor0
----
110
113
152

query I rowsort
SELECT 25 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab2 AS cor2, tab0 AS cor3
----
3645 values hashing to 752ce7d2fdd0678058de6a90ff2b0f3a

query I rowsort
SELECT - col0 + - col2 * - col0 + + col1 FROM tab2 AS cor0
----
2009
213
2940

query I rowsort
SELECT + col1 + - 50 + cor0.col0 FROM tab2 cor0
----
-12
46
87

query I rowsort
SELECT + - 32 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
2048
2560
96

query I rowsort
SELECT ALL col1 + - col1 + - 8 AS col0 FROM tab2
----
-8
-8
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3340
SELECT - col1 + + col1 DIV col2 FROM tab0 AS cor0
----
-84
-90
0

skipif mysql # not compatible
query I rowsort label-3340
SELECT - col1 + + col1 / col2 FROM tab0 AS cor0
----
-84
-90
0

query I rowsort
SELECT - + col0 + - cor0.col1 + - col1 FROM tab0 AS cor0
----
-196
-229
-271

query I rowsort
SELECT DISTINCT - col1 + ( 21 * col2 ) AS col1 FROM tab0
----
-76
1631
607

query I rowsort
SELECT - col2 + + ( - col1 ) + + col2 AS col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col0 * - 20 + tab1.col2 + - col1 AS col2 FROM tab1
----
1327
1683
88

query I rowsort
SELECT ALL 83 * tab1.col2 FROM tab1, tab1 cor0
----
9 values hashing to 7cfac30b9a8f0efdf067d08fb36c850d

onlyif mysql # use DIV operator for integer division
query I rowsort label-3346
SELECT - ( 46 ) * col2 DIV ( - ( cor0.col1 ) ) + col1 AS col2 FROM tab2 cor0
----
119
71
79

skipif mysql # not compatible
query I rowsort label-3346
SELECT - ( 46 ) * col2 / ( - ( cor0.col1 ) ) + col1 AS col2 FROM tab2 cor0
----
119
71
79

query I rowsort
SELECT DISTINCT + - 2 + col2 FROM tab1 AS cor0
----
52
55
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + cor0.col1 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + 50 + - 96 * - col2 AS col1 FROM tab0 cor0
----
146
3218
7922

query I rowsort
SELECT ALL ( - col0 ) * cor0.col0 + 31 * + col1 FROM tab0 AS cor0
----
-5100
1782
2090

query I rowsort
SELECT DISTINCT - 27 AS col1 FROM tab1
----
-27

query I rowsort
SELECT DISTINCT + 56 - cor0.col1 * - col2 FROM tab2 AS cor0
----
1590
702
893

query I rowsort
SELECT DISTINCT - - col1 + + ( col2 ) AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col0 + tab2.col2 + + col2 AS col0 FROM tab2
----
130
155
61

query I rowsort
SELECT DISTINCT 7 AS col1 FROM tab1 AS cor0
----
7

query I rowsort
SELECT ALL - col0 + + col2 AS col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT ALL - - col1 + col2 * col0 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + cor0.col0 * - col1 col2 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT + col0 * + 56 + col2 FROM tab0 cor0
----
1377
1961
5066

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col1 + + col1 * col0 col2 FROM tab2 cor0
----
-620
3068
697

query I rowsort
SELECT ALL cor0.col1 + + 7 FROM tab1 AS cor0
----
17
20
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 69 col0 FROM tab2, tab1 cor0
----
69

query I rowsort
SELECT 80 AS col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

query I rowsort
SELECT + tab2.col2 * + col1 * - col2 FROM tab2
----
-22599
-24548
-39884

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0, tab1 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 2563d2f4127fd757b80c46400c5511cb

query I rowsort
SELECT + col0 * - ( 3 * + col2 ) AS col1 FROM tab0 AS cor0
----
-105
-21894
-2376

query I rowsort
SELECT cor0.col0 * - col0 * 35 AS col0 FROM tab0 AS cor0
----
-20160
-277235
-42875

query I rowsort
SELECT DISTINCT - + col0 + - 5 FROM tab0 AS cor0
----
-29
-40
-94

query I rowsort
SELECT - - col1 + - col1 * col2 * cor0.col0 AS col1 FROM tab1 cor0
----
-36470
-4186
-99827

query I rowsort
SELECT - 71 * col2 + - cor0.col2 FROM tab1 AS cor0
----
-3888
-4104
-6912

query I rowsort
SELECT - - 63 * - col0 AS col2 FROM tab0 AS cor0
----
-1512
-2205
-5607

query I rowsort
SELECT - col0 + - cor0.col1 * col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT ( - col1 ) - 63 * 95 * + col0 AS col1 FROM tab0 AS cor0
----
-143726
-209572
-532756

query I rowsort
SELECT col0 * col0 + ( col0 * - col2 ) FROM tab0 AS cor0
----
-216
1190
623

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 + - col0 + col2 col1 FROM tab1 AS cor0
----
1056
129
633

query I rowsort
SELECT - cor0.col1 + + ( col0 ) * - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT col0 * - col0 - cor0.col0 FROM tab0 AS cor0
----
-1260
-600
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 42 col1 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 4d49d5ffe533e92cf06d98cb59a19b10

onlyif mysql # use DIV operator for integer division
query I rowsort label-3379
SELECT 36 + - col2 DIV - col1 FROM tab2 AS cor0
----
36
36
38

skipif mysql # not compatible
query I rowsort label-3379
SELECT 36 + - col2 / - col1 FROM tab2 AS cor0
----
36
36
38

query I rowsort
SELECT 17 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT DISTINCT - col1 * 29 FROM tab1
----
-290
-377
-754

query I rowsort
SELECT + + col1 - - cor0.col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - 54 * + 67 * - col1 + - col1 + 37 AS col1 FROM tab2
----
112164
213440
61526

onlyif mysql # use DIV operator for integer division
query I rowsort label-3384
SELECT DISTINCT 63 DIV - 48 + col2 AS col1 FROM tab2
----
25
26
37

skipif mysql # not compatible
query I rowsort label-3384
SELECT DISTINCT 63 / - 48 + col2 AS col1 FROM tab2
----
25
26
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-3385
SELECT ALL - 61 - col1 DIV + cor0.col0 AS col1 FROM tab0 AS cor0
----
-62
-63
-64

skipif mysql # not compatible
query I rowsort label-3385
SELECT ALL - 61 - col1 / + cor0.col0 AS col1 FROM tab0 AS cor0
----
-62
-63
-64

query I rowsort
SELECT DISTINCT + 74 * col1 + col1 - + 19 FROM tab2 AS cor0
----
1256
2306
4406

query I rowsort
SELECT - 46 - 3 FROM tab0 AS cor0
----
-49
-49
-49

query I rowsort
SELECT - 74 * - col0 * + cor0.col0 - + 53 * + col0 * + col1 FROM tab2 AS cor0
----
-7875
206310
390655

query I rowsort
SELECT DISTINCT - 50 AS col1 FROM tab1
----
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-3390
SELECT col0 DIV + 9 AS col2 FROM tab0
----
2
3
9

skipif mysql # not compatible
query I rowsort label-3390
SELECT col0 / + 9 AS col2 FROM tab0
----
2
3
9

query I rowsort
SELECT + - 17 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 28cd5b4c959cb41fbc56389ab43d167e

query I rowsort
SELECT ALL ( - 46 ) FROM tab0
----
-46
-46
-46

query I rowsort
SELECT ALL + ( + cor0.col2 ) * col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + - col1 * col1 - 19 FROM tab2 AS cor0
----
-308
-3500
-980

query I rowsort
SELECT - 67 FROM tab2, tab2 AS cor0
----
9 values hashing to fbe03b15d6b951410b38f7e98895006f

query I rowsort
SELECT DISTINCT + 18 - col1 AS col2 FROM tab1
----
-8
5
8

query I rowsort
SELECT ALL tab0.col1 * col1 + col0 + col2 AS col1 FROM tab0
----
7453
8452
9445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col1 + col1 - + col2 * - col1 col0 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL tab0.col0 * - tab0.col2 - - col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT + + col1 + col1 * - ( col0 ) FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL 74 * cor1.col0 + - 19 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 85b1ae0723af2e295223c80e3480b941

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3402
SELECT DISTINCT col0 * + CAST( + 91 AS SIGNED ) + + col1 FROM tab2
----
668
7157
7206

skipif mysql # not compatible
query I rowsort label-3402
SELECT DISTINCT col0 * + CAST ( + 91 AS INTEGER ) + + col1 FROM tab2
----
668
7157
7206

onlyif mysql # use DIV operator for integer division
query I rowsort label-3403
SELECT + tab1.col0 - 90 DIV - col2 AS col0 FROM tab1
----
4
65
80

skipif mysql # not compatible
query I rowsort label-3403
SELECT + tab1.col0 - 90 / - col2 AS col0 FROM tab1
----
4
65
80

query I rowsort
SELECT + tab0.col1 * tab0.col1 + col2 * + tab0.col0 FROM tab0
----
15579
8188
9444

query I rowsort
SELECT + ( col2 ) * col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - col2 + - 76 FROM tab2 AS cor0
----
-102
-103
-114

query I rowsort
SELECT ALL - - ( + col1 ) * - col1 * - ( - col2 * cor0.col2 ) FROM tab2 AS cor0
----
-2353156
-417316
-700569

query I rowsort
SELECT + 92 + 66 FROM tab2 cor0
----
158
158
158

query I rowsort
SELECT DISTINCT + ( + 8 ) FROM tab1 cor0
----
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3410
SELECT col2 DIV + 36 FROM tab0 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-3410
SELECT col2 / + 36 FROM tab0 AS cor0
----
0
0
2

query I rowsort
SELECT ALL + col0 * ( - 41 * col2 + + 81 ) FROM tab1
----
-144384
-308400
-6399

query I rowsort
SELECT ALL col2 * 48 AS col1 FROM tab2 AS cor0
----
1248
1296
1824

query I rowsort
SELECT DISTINCT col0 * + col2 + + col0 * col1 + - col2 FROM tab1
----
186
4231
8624

query I rowsort
SELECT + col2 * tab0.col2 * + col0 AS col1 FROM tab0
----
26136
35
598436

query I rowsort
SELECT - cor0.col0 + + col1 * + col2 AS col2 FROM tab0 cor0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col2 + col0 col0 FROM tab0
----
70
7387
816

query IIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3418
SELECT ALL + col2 DIV + col1 col0 FROM tab1
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3418
SELECT ALL + col2 / + col1 col0 FROM tab1
----
2
5
7

query I rowsort
SELECT ALL + col1 + - col0 * - col1 * + col0 AS col1 FROM tab1 cor0
----
260
40970
83213

query I rowsort
SELECT col0 + - col1 * tab1.col0 AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT DISTINCT - col0 * + col0 + col0 * col1 FROM tab1 AS cor0
----
-3456
-5360
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * tab1.col0 col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT + 80 * col1 + - tab0.col0 + - col1 FROM tab0
----
6770
7100
7628

query I rowsort
SELECT ALL - col1 + + col2 - - col0 FROM tab2
----
100
3
45

query I rowsort
SELECT ALL - col2 * - 76 + + col1 FROM tab0
----
173
2594
6323

query I rowsort
SELECT DISTINCT + - ( 31 ) + col0 FROM tab2 AS cor0
----
-24
47
48

query I rowsort
SELECT DISTINCT - cor0.col0 * + cor0.col1 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + 47 FROM tab2 cor0
----
47
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 + - 55 col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT col2 + 0 * col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL - 24 - - 54 AS col0 FROM tab1 AS cor0
----
30
30
30

query I rowsort
SELECT - 29 * 10 - + col1 * col1 AS col1 FROM tab2 AS cor0
----
-1251
-3771
-579

query I rowsort
SELECT DISTINCT cor0.col1 * 0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 24 + - cor0.col2 * - col2 FROM tab2 cor0
----
1420
652
705

query I rowsort
SELECT - - 21 + + col0 + col0 * - cor0.col1 FROM tab1 AS cor0
----
-54
-555
-939

query I rowsort
SELECT + ( col0 ) + col1 * + col2 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - col2 * col1 * - cor0.col0 + col1 + col1 AS col1 FROM tab2 AS cor0
----
119770
51068
5921

query I rowsort
SELECT - cor0.col2 + col2 * col0 AS col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT + 13 AS col0 FROM tab2 cor0
----
13

query I rowsort
SELECT ALL + col0 + col0 * col0 + - col1 AS col1 FROM tab0 AS cor0
----
1163
514
7919

query I rowsort
SELECT ALL + 20 * cor0.col0 FROM tab0 AS cor0
----
1780
480
700

onlyif mysql # use DIV operator for integer division
query I rowsort label-3442
SELECT - + 99 + col2 DIV + col2 - + col1 * - col1 AS col2 FROM tab0 cor0
----
7298
8183
9311

skipif mysql # not compatible
query I rowsort label-3442
SELECT - + 99 + col2 / + col2 - + col1 * - col1 AS col2 FROM tab0 cor0
----
7298
8183
9311

query I rowsort
SELECT ALL + 23 + col2 AS col0 FROM tab2 AS cor0
----
49
50
61

query I rowsort
SELECT + 78 + col0 + - col0 AS col1 FROM tab2 AS cor0
----
78
78
78

query I rowsort
SELECT ALL col2 * - col2 + + col1 - + tab0.col1 * - tab0.col2 AS col1 FROM tab0
----
1835
193
829

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col0 * - col1 col1 FROM tab2
----
1264
210
4524

query I rowsort
SELECT DISTINCT col0 - 46 FROM tab1
----
-43
18
34

query I rowsort
SELECT ALL - col2 * col2 + + col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 + col1 * col0 * - cor0.col2 col1 FROM tab2 AS cor0
----
-115050
-49691
-5642

query I rowsort
SELECT + col1 * + cor0.col1 + + col0 FROM tab0 cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT + + col0 + - col0 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - 34 * + col2 + cor0.col2 - + col1 FROM tab0 AS cor0
----
-1175
-130
-2797

query I rowsort
SELECT col0 * col2 - tab1.col0 * - col0 * col0 FROM tab1
----
189
265792
519680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3454
SELECT ALL + col2 * - col1 + + col2 DIV - col1 AS col2 FROM tab2
----
-1534
-648
-837

skipif mysql # not compatible
query I rowsort label-3454
SELECT ALL + col2 * - col1 + + col2 / - col1 AS col2 FROM tab2
----
-1534
-648
-837

query I rowsort
SELECT ALL + col2 * col0 + + col1 AS col1 FROM tab1 WHERE ( col2 ) NOT IN ( col0 - col0 * - tab1.col2 / - col0 )
----
188
3658
7693

query I rowsort
SELECT - col0 - cor0.col0 AS col2 FROM tab2 AS cor0
----
-14
-156
-158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - - col0 col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + cor0.col0 + - col2 - col1 FROM tab2 AS cor0
----
-51
-7
24

query I rowsort
SELECT DISTINCT - col1 + col0 + - col2 FROM tab0
----
-63
-84
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 + - col0 col2 FROM tab2
----
210
3403
954

query I rowsort
SELECT - col1 * - col0 * col2 AS col0 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT ALL + col0 + - col1 + col0 * col0 AS col0 FROM tab0
----
1163
514
7919

query I rowsort
SELECT DISTINCT + col0 * - tab2.col2 AS col0 FROM tab2 WHERE NOT + tab2.col2 + + col0 NOT IN ( + col0 * - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col2 col0 FROM tab1
----
0
0
0

query I rowsort
SELECT + col1 * - col2 - - col1 * col0 FROM tab0
----
-774
3298
637

query III rowsort
SELECT * FROM tab0 WHERE NOT ( - col2 ) IN ( - col2 )
----

query I rowsort
SELECT + col1 * + col1 + + col2 FROM tab2
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 * - col1 col0 FROM tab1
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-3469
SELECT DISTINCT col1 DIV - col2 + col0 * col0 * col0 FROM tab0
----
13822
42778
704968

skipif mysql # not compatible
query I rowsort label-3469
SELECT DISTINCT col1 / - col2 + col0 * col0 * col0 FROM tab0
----
13822
42778
704968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 + - col2 col1 FROM tab0
----
34
7216
759

query I rowsort
SELECT col0 AS col1 FROM tab1 WHERE NOT NULL < ( NULL )
----

query I rowsort
SELECT col2 + + col0 * + tab0.col2 AS col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT - + col1 + col0 + + col0 AS col1 FROM tab0 AS cor0
----
-27
-38
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 * col2 + tab1.col1 col1 FROM tab1
----
16237
36530
5710

query I rowsort
SELECT - col2 * + col2 AS col0 FROM tab0 WHERE NOT NULL = NULL
----

query I rowsort
SELECT - col0 + + col0 * col2 * col2 FROM tab2 AS cor0
----
113997
5096
52650

query I rowsort
SELECT + 65 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT + 68 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

onlyif mysql # use DIV operator for integer division
query I rowsort label-3479
SELECT DISTINCT 82 DIV 84 AS col1 FROM tab1, tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3479
SELECT DISTINCT 82 / 84 AS col1 FROM tab1, tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3480
SELECT ALL + 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-3480
SELECT ALL + col1 / col1 col2 FROM tab1
----
1
1
1

query I rowsort
SELECT + col0 - - 75 AS col2 FROM tab1
----
139
155
78

query I rowsort
SELECT + col1 * col0 - col2 AS col1 FROM tab0
----
2031
3394
8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - 26 * - col1 col2 FROM tab0 AS cor0
----
2269
2448
2523

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col2 AS REAL ) + + col0 + col1 FROM tab1 AS cor0
----
-25
-3
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-3485
SELECT 16 DIV + col2 + col1 * ( - 39 ) + col2 * col2 * col2 FROM tab0 AS cor0
----
-3766
32583
547819

skipif mysql # not compatible
query I rowsort label-3485
SELECT 16 / + col2 + col1 * ( - 39 ) + col2 * col2 * col2 FROM tab0 AS cor0
----
-3766
32583
547819

query I rowsort
SELECT ALL + 70 FROM tab0 cor0
----
70
70
70

query I rowsort
SELECT + col0 + + col0 * col1 + - col2 * + 71 AS col2 FROM tab2 AS cor0
----
-1276
-1693
2834

query I rowsort
SELECT DISTINCT - ( - ( col1 ) ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - 14 * - ( col2 ) FROM tab0 AS cor0
----
1148
14
462

query I rowsort
SELECT - + col1 * ( cor0.col1 * + ( col2 ) ) + + col1 + + cor0.col1 FROM tab2 AS cor0
----
-10948
-25885
-90388

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3491
SELECT cor0.col2 + col1 + - col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3491
SELECT cor0.col2 + col1 + - col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3492
SELECT - CAST( cor0.col1 AS SIGNED ) * + cor0.col0 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-3492
SELECT - CAST ( cor0.col1 AS INTEGER ) * + cor0.col0 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 9 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

query I rowsort
SELECT + 60 + + col2 AS col0 FROM tab0 cor0
----
142
61
93

query I rowsort
SELECT ALL col0 + 64 * + ( col2 ) FROM tab2 AS cor0
----
1735
1742
2511

query I rowsort
SELECT DISTINCT - col0 + cor0.col0 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT cor0.col0 - + col1 * col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT + - cor0.col2 - col2 FROM tab2 AS cor0
----
-52
-54
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3499
SELECT col1 + CAST( - cor0.col2 AS SIGNED ) col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3499
SELECT col1 + CAST ( - cor0.col2 AS INTEGER ) col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT col0 + 27 FROM tab2 AS cor0
----
105
106
34

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 + + col1 AS col2 FROM tab0 cor0
----
-1003
-6633
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3502
SELECT DISTINCT + col0 DIV ( - 58 + - col1 * - col1 ) FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3502
SELECT DISTINCT + col0 / ( - 58 + - col1 * - col1 ) FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - col2 + col0 * + 62 * + col0 AS col0 FROM tab2 AS cor0
----
3011
377182
386904

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3504
SELECT DISTINCT - cor0.col2 * CAST( - col2 AS SIGNED ) FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-3504
SELECT DISTINCT - cor0.col2 * CAST ( - col2 AS INTEGER ) FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3505
SELECT ALL + col0 + + CAST( - 65 AS SIGNED ) col1 FROM tab2 cor0
----
-58
13
14

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3505
SELECT ALL + col0 + + CAST ( - 65 AS INTEGER ) col1 FROM tab2 cor0
----
-58
13
14

query I rowsort
SELECT ALL + - col1 * cor0.col1 + - 83 AS col0 FROM tab2 AS cor0
----
-1044
-3564
-372

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3507
SELECT DISTINCT - CAST( NULL AS DECIMAL ) * + col0 - + cor0.col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3507
SELECT DISTINCT - CAST ( NULL AS REAL ) * + col0 - + cor0.col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL 67 * - col1 FROM tab1 AS cor0
----
-1742
-670
-871

query I rowsort
SELECT ( 75 ) FROM tab0 AS cor0
----
75
75
75

query I rowsort
SELECT 51 + cor0.col2 FROM tab2 AS cor0
----
77
78
89

query I rowsort
SELECT ALL - + col1 * col2 + + col2 * col2 AS col2 FROM tab0 AS cor0
----
-1749
-738
-96

query I rowsort
SELECT DISTINCT + col2 + col0 * - col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT 57 + + col2 FROM tab2 AS cor0
----
83
84
95

query I rowsort
SELECT + tab2.col1 + + 73 AS col1 FROM tab2
----
104
132
90

query I rowsort
SELECT DISTINCT 16 AS col2 FROM tab0, tab0 AS cor0
----
16

query I rowsort
SELECT DISTINCT + + 57 + col1 AS col0 FROM tab1 AS cor0
----
67
70
83

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab2, tab2 cor0, tab1 cor1, tab0 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT - 79 + col2 FROM tab1 AS cor0
----
-22
-25
17

query I rowsort
SELECT DISTINCT - + 6 + col2 FROM tab1 cor0
----
48
51
90

query I rowsort
SELECT ALL + ( col0 ) * ( col2 ) AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT + 75 * + col2 + - 56 * tab0.col1 FROM tab0
----
-2341
-5357
1054

query I rowsort
SELECT - + 58 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

query I rowsort
SELECT DISTINCT + col0 * col2 * - 79 FROM tab1 AS cor0
----
-12798
-288192
-606720

query I rowsort
SELECT ( + col2 ) + col2 + col1 AS col1 FROM tab2 AS cor0
----
111
85
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 2 * - col1 col2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT + + col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ( - col2 ) - cor0.col0 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3528
SELECT ALL + - 70 DIV col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-3528
SELECT ALL + - 70 / col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT ALL 41 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT ALL 13 + col1 * - col0 AS col0 FROM tab2
----
-1330
-204
-4589

query I rowsort
SELECT col0 + + col0 * col2 AS col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT - 77 - col2 FROM tab2 AS cor0
----
-103
-104
-115

query I rowsort
SELECT - col1 + + col0 + + tab0.col2 FROM tab0
----
-29
-61
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3534
SELECT + col2 + col0 DIV - col1 AS col0 FROM tab2
----
25
27
34

skipif mysql # not compatible
query I rowsort label-3534
SELECT + col2 + col0 / - col1 AS col0 FROM tab2
----
25
27
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3535
SELECT + col1 DIV + 96 - col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3535
SELECT + col1 / + 96 - col2 FROM tab1
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3536
SELECT col2 + CAST( col1 AS SIGNED ) FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-3536
SELECT col2 + CAST ( col1 AS INTEGER ) FROM tab0
----
119
173
98

query I rowsort
SELECT ALL - - 89 * + ( col0 * + col0 ) AS col1 FROM tab1 AS cor0
----
364544
569600
801

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3538
SELECT - CAST( NULL AS SIGNED ) / + col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3538
SELECT - CAST ( NULL AS INTEGER ) / + col1 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + + ( + col1 ) + col1 * - col0 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + ( 16 ) * col0 AS col1 FROM tab2 AS cor0
----
112
1248
1264

onlyif mysql # use DIV operator for integer division
query I rowsort label-3541
SELECT + 47 DIV 39 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3541
SELECT + 47 / 39 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL col0 + + cor0.col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + col2 + + col2 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT 23 AS col2 FROM tab0 cor0
----
23

query I rowsort
SELECT ALL + ( - ( - cor0.col2 ) ) * + cor0.col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3546
SELECT ALL + + CAST( 32 AS SIGNED ) * + col2 + ( 5 + col1 ) * - col2 AS col0 FROM tab2 AS cor0
----
-108
-832
380

skipif mysql # not compatible
query I rowsort label-3546
SELECT ALL + + CAST ( 32 AS INTEGER ) * + col2 + ( 5 + col1 ) * - col2 AS col0 FROM tab2 AS cor0
----
-108
-832
380

query I rowsort
SELECT DISTINCT - + col2 + - col2 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL + + 90 + - col2 * + cor0.col1 * 97 FROM tab0 AS cor0
----
-275196
-723724
-9319

query I rowsort
SELECT ALL - ( 60 ) FROM tab0 AS cor0
----
-60
-60
-60

query I rowsort
SELECT ALL col0 * + 17 FROM tab0 cor0
----
1513
408
595

query I rowsort
SELECT - + col1 * + 86 FROM tab2 AS cor0
----
-1462
-2666
-5074

query I rowsort
SELECT ALL ( col1 + col1 ) AS col1 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL + + ( + ( + col2 ) ) + 17 * col2 FROM tab1 AS cor0
----
1026
1728
972

query I rowsort
SELECT ( col1 ) * col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3555
SELECT 87 - + col1 DIV - 69 col2 FROM tab0 cor0
----
88
88
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3555
SELECT 87 - + col1 / - 69 col2 FROM tab0 cor0
----
88
88
88

query I rowsort
SELECT + col0 - + col1 * col0 AS col0 FROM tab0 cor0
----
-2040
-3360
-8010

query I rowsort
SELECT + + 93 + + col2 FROM tab0 AS cor0
----
126
175
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3558
SELECT + - 66 * + col2 - 98 DIV + col1 FROM tab2 AS cor0
----
-1717
-1785
-2513

skipif mysql # not compatible
query I rowsort label-3558
SELECT + - 66 * + col2 - 98 / + col1 FROM tab2 AS cor0
----
-1717
-1785
-2513

onlyif mysql # use DIV operator for integer division
query I rowsort label-3559
SELECT ALL col2 + col2 DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-3559
SELECT ALL col2 + col2 / cor0.col0 AS col1 FROM tab0 AS cor0
----
1
34
82

query I rowsort
SELECT + tab2.col1 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 43 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT - - ( - cor0.col2 ) FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3563
SELECT + col0 * col0 DIV - col1 AS col0 FROM tab1 AS cor0
----
-409
-492
0

skipif mysql # not compatible
query I rowsort label-3563
SELECT + col0 * col0 / - col1 AS col0 FROM tab1 AS cor0
----
-409
-492
0

query I rowsort
SELECT ALL + cor0.col0 + + 54 - - col1 FROM tab1 AS cor0
----
128
147
83

query I rowsort
SELECT DISTINCT - cor0.col2 + ( 32 ) FROM tab0 AS cor0
----
-1
-50
31

query I rowsort
SELECT ALL - - col1 * - cor0.col2 * 22 AS col0 FROM tab1 AS cor0
----
-12540
-27456
-30888

query I rowsort
SELECT DISTINCT + col0 - - ( + 15 ) AS col2 FROM tab0 AS cor0
----
104
39
50

query I rowsort
SELECT + - col2 + 56 * + col0 FROM tab1 AS cor0
----
114
3527
4384

query I rowsort
SELECT + 12 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT - 42 * - col1 FROM tab2 AS cor0
----
1302
2478
714

query I rowsort
SELECT DISTINCT - 3 AS col1 FROM tab2, tab2 AS cor0
----
-3

query I rowsort
SELECT + + col2 * 22 AS col2 FROM tab1 cor0
----
1188
1254
2112

query I rowsort
SELECT ALL 56 * col0 FROM tab2
----
392
4368
4424

query I rowsort
SELECT + cor0.col2 + ( - 46 ) * col1 FROM tab1 AS cor0
----
-1142
-403
-502

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3575
SELECT - - 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-3575
SELECT - - col0 * - CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * + 87 col1 FROM tab0 AS cor0
----
2871
7134
87

query I rowsort
SELECT DISTINCT + col0 * ( + col0 ) FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-3578
SELECT ALL col1 DIV 71 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3578
SELECT ALL col1 / 71 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 69 col2 FROM tab0
----
69
69
69

query I rowsort
SELECT ( + 80 ) FROM tab0, tab0 cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3581
SELECT + - col2 + CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3581
SELECT + - col2 + CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * + cor0.col1 col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 * + tab1.col1 + col1 FROM tab1
----
-156
-650
-90

query III rowsort
SELECT * FROM tab0 WHERE NOT - col0 + col0 IN ( - col1 + + col1 * + col2 )
----
24
86
33
89
91
82

query I rowsort
SELECT DISTINCT + tab0.col2 + col1 + col1 FROM tab0
----
195
205
264

query I rowsort
SELECT ALL col0 * + col1 * - col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT - col1 * tab2.col0 + col0 AS col2 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT + - ( + col1 ) * ( + ( + col2 ) ) AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3589
SELECT + 99 * col0 + + 65 DIV + 80 AS col2 FROM tab1 cor0
----
297
6336
7920

skipif mysql # not compatible
query I rowsort label-3589
SELECT + 99 * col0 + + 65 / + 80 AS col2 FROM tab1 cor0
----
297
6336
7920

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 cor0, tab1 cor1, tab1 cor2
----
972 values hashing to 635619591835474e6aa6acdff4ab166c

query I rowsort
SELECT DISTINCT - 64 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2 AS cor2
----
-64

query I rowsort
SELECT ALL ( col1 ) * col0 * + 55 + col0 AS col0 FROM tab1
----
35264
4293
57280

query I rowsort
SELECT ALL - 79 + - col1 * + col0 * 30 FROM tab2
----
-138139
-40369
-6589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 71 * - col0 + - col2 col0 FROM tab2 AS cor0
----
-524
-5564
-5647

query I rowsort
SELECT - + col0 * - col1 + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + col0 + + cor0.col2 * 86 AS col0 FROM tab1 AS cor0
----
4647
4966
8336

query I rowsort
SELECT ALL - + ( - col0 ) + 98 AS col2 FROM tab2 cor0
----
105
176
177

query I rowsort
SELECT + col0 * col1 * cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
260
40970
83213

query I rowsort
SELECT 18 * - col2 FROM tab1 AS cor0
----
-1026
-1728
-972

query I rowsort
SELECT ALL - - cor0.col0 * - ( 86 * - col2 ) + 60 FROM tab2 AS cor0
----
16314
174468
258232

query I rowsort
SELECT ALL - cor0.col1 + 6 + + col2 FROM tab0 AS cor0
----
-3
-47
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3602
SELECT ALL - col1 DIV col1 + + col2 AS col1 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-3602
SELECT ALL - col1 / col1 + + col2 AS col1 FROM tab2 AS cor0
----
25
26
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3603
SELECT tab0.col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3603
SELECT tab0.col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3604
SELECT cor0.col0 * CAST( NULL AS DECIMAL ) + - col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3604
SELECT cor0.col0 * CAST ( NULL AS REAL ) + - col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3605
SELECT ALL - + col2 + - CAST( cor0.col2 AS SIGNED ) DIV + col0 FROM tab2 cor0
----
-26
-30
-38

skipif mysql # not compatible
query I rowsort label-3605
SELECT ALL - + col2 + - CAST ( cor0.col2 AS INTEGER ) / + col0 FROM tab2 cor0
----
-26
-30
-38

query I rowsort
SELECT - + col2 * 18 FROM tab1 AS cor0
----
-1026
-1728
-972

query I rowsort
SELECT - col0 * + 89 * - col0 FROM tab0 cor0
----
109025
51264
704969

query I rowsort
SELECT - + col1 + + col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - col2 * + 92 AS col2 FROM tab2
----
-2392
-2484
-3496

query I rowsort
SELECT DISTINCT - 30 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
-30

onlyif mysql # use DIV operator for integer division
query I rowsort label-3611
SELECT ( cor1.col0 ) DIV 66 col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3611
SELECT ( cor1.col0 ) / 66 col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

query I rowsort
SELECT DISTINCT 66 * - cor0.col2 FROM tab1 AS cor0
----
-3564
-3762
-6336

query I rowsort
SELECT - + 42 * col2 AS col0 FROM tab0 cor0
----
-1386
-3444
-42

query I rowsort
SELECT + ( + 64 ) * - col0 FROM tab0 AS cor0
----
-1536
-2240
-5696

query I rowsort
SELECT DISTINCT - + ( 31 ) FROM tab2 AS cor0
----
-31

query I rowsort
SELECT ALL cor1.col0 + 64 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to bcca0abf572d1e525e516481899aea93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3617
SELECT col2 DIV + col1 + 17 AS col2 FROM tab1 cor0
----
19
22
24

skipif mysql # not compatible
query I rowsort label-3617
SELECT col2 / + col1 + 17 AS col2 FROM tab1 cor0
----
19
22
24

query I rowsort
SELECT DISTINCT col1 * col1 + - col0 AS col0 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT - col1 * col0 + col2 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL + 62 * + cor0.col0 * - col1 FROM tab1 AS cor0
----
-39680
-4836
-64480

query I rowsort
SELECT 41 * - col1 + - ( + col0 * col1 ) FROM tab1 cor0
----
-1050
-1144
-1573

query I rowsort
SELECT ALL ( col1 ) * 53 - col2 AS col2 FROM tab0 AS cor0
----
4525
4741
5140

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3623
SELECT ALL ( 14 ) - col1 * CAST( 53 AS SIGNED ) FROM tab1
----
-1364
-516
-675

skipif mysql # not compatible
query I rowsort label-3623
SELECT ALL ( 14 ) - col1 * CAST ( 53 AS INTEGER ) FROM tab1
----
-1364
-516
-675

query I rowsort
SELECT DISTINCT - 22 AS col1 FROM tab0, tab0 AS cor0
----
-22

query I rowsort
SELECT ALL + col0 - col1 * col1 AS col1 FROM tab2
----
-210
-3403
-954

query I rowsort
SELECT DISTINCT - + cor0.col1 * + ( + col0 ) + - col0 AS col1 FROM tab0 AS cor0
----
-2088
-3430
-8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - 78 col1 FROM tab0 AS cor0
----
-2574
-6396
-78

query I rowsort
SELECT ALL + + col0 + 55 * 52 FROM tab2 AS cor0
----
2867
2938
2939

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3629
SELECT col1 + - CAST( - 33 AS SIGNED ) FROM tab0 AS cor0
----
119
124
130

skipif mysql # not compatible
query I rowsort label-3629
SELECT col1 + - CAST ( - 33 AS INTEGER ) FROM tab0 AS cor0
----
119
124
130

query I rowsort
SELECT ALL col0 + 22 * + cor0.col1 FROM tab0 AS cor0
----
1916
2091
2169

onlyif mysql # use DIV operator for integer division
query I rowsort label-3631
SELECT DISTINCT + + cor0.col2 DIV - col1 + cor0.col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3631
SELECT DISTINCT + + cor0.col2 / - col1 + cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - col1 - 92 FROM tab0 AS cor0
----
-178
-183
-189

query I rowsort
SELECT ALL - + cor0.col0 * ( 54 ) + col1 AS col0 FROM tab1 AS cor0
----
-136
-3446
-4307

query I rowsort
SELECT ALL + col0 - + cor0.col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col1 + + 61 * - col0 FROM tab0 AS cor0
----
-1378
-2038
-5338

query I rowsort
SELECT col1 + + 7 FROM tab1 AS cor0
----
17
20
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-3637
SELECT + CAST( - col1 AS SIGNED ) - - col0 DIV col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3637
SELECT + CAST ( - col1 AS INTEGER ) - - col0 / col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT ( - ( - col0 ) ) + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - cor0.col2 + col2 * + col1 * + col2 AS col2 FROM tab1 cor0
----
119712
32433
75762

query I rowsort
SELECT - 61 * col1 AS col1 FROM tab2 cor0
----
-1037
-1891
-3599

query I rowsort
SELECT ALL + 66 * col1 FROM tab2 AS cor0
----
1122
2046
3894

query I rowsort
SELECT DISTINCT + 67 * cor0.col1 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT 27 + + col0 * - tab2.col0 FROM tab2
----
-22
-6057
-6214

query I rowsort
SELECT - 90 AS col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to c0d96679aba507520916e8654e5a6618

query I rowsort
SELECT 40 * + cor0.col0 AS col0 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 750312b6305a60577c48dc1cf9f578af

query I rowsort
SELECT - col1 + + col2 * col0 AS col1 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT - - col1 + ( + 59 ) FROM tab2 cor0
----
118
76
90

query I rowsort
SELECT ALL 39 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT - cor0.col2 + + col1 * col0 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT ALL 69 FROM tab1, tab2 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT ALL col1 + + 57 AS col1 FROM tab1
----
67
70
83

query I rowsort
SELECT ALL + ( 75 ) FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT - - 24 AS col1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT ALL - ( + ( - col0 ) ) FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3655
SELECT ALL ( col1 ) DIV col0 AS col2 FROM tab1 cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-3655
SELECT ALL ( col1 ) / col0 AS col2 FROM tab1 cor0
----
0
0
8

query I rowsort
SELECT + ( + col0 ) + + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col1 * col0 + ( col0 ) AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - + col0 + + col2 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT 75 + + col2 * - ( col2 ) * + col1 FROM tab0 cor0
----
-22
-611809
-93579

query I rowsort
SELECT + cor0.col0 * col2 + + ( col1 ) AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT col2 * + 55 + cor0.col2 FROM tab1 AS cor0
----
3024
3192
5376

query I rowsort
SELECT ALL col0 * - 61 AS col0 FROM tab1 AS cor0
----
-183
-3904
-4880

query I rowsort
SELECT ALL + + 80 * + col2 AS col1 FROM tab2 AS cor0
----
2080
2160
3040

query I rowsort
SELECT DISTINCT col0 + 29 AS col2 FROM tab0 AS cor0
----
118
53
64

query I rowsort
SELECT + 0 + + col1 AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT 9 + - col0 AS col1 FROM tab2 AS cor0
----
-69
-70
2

query I rowsort
SELECT ALL - col2 * - col1 + + col0 + + cor0.col1 FROM tab2 AS cor0
----
1671
742
875

query I rowsort
SELECT DISTINCT + col1 * + col2 + - ( + col1 ) AS col0 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ALL - + 44 + col0 AS col1 FROM tab0 AS cor0
----
-20
-9
45

query I rowsort
SELECT + col0 * col2 * ( col1 * col0 ) FROM tab0 AS cor0
----
118825
1634688
59106502

query I rowsort
SELECT DISTINCT ( + col0 ) * + col0 + 15 + ( + col2 ) AS col1 FROM tab1
----
4168
6511
78

query I rowsort
SELECT ALL - ( col0 * col1 ) AS col2 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3673
SELECT - - col0 * col1 DIV - col0 + + col0 AS col2 FROM tab2 cor0
----
-24
19
62

skipif mysql # not compatible
query I rowsort label-3673
SELECT - - col0 * col1 / - col0 + + col0 AS col2 FROM tab2 cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3674
SELECT - + col2 + - CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3674
SELECT - + col2 + - CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + - col2 * - 34 FROM tab2 AS cor0
----
1309
943
949

onlyif mysql # use DIV operator for integer division
query I rowsort label-3676
SELECT 37 DIV - tab1.col1 FROM tab1
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-3676
SELECT 37 / - tab1.col1 FROM tab1
----
-1
-2
-3

query I rowsort
SELECT DISTINCT + tab0.col0 FROM tab0, tab1, tab1 AS cor0, tab2
----
24
35
89

query I rowsort
SELECT ( - cor0.col0 + - tab2.col0 ) AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to f3d05349096dbf5e628eed2bf90c270a

query I rowsort
SELECT + + col1 * 46 - - col0 AS col0 FROM tab2 AS cor0
----
1433
2792
861

query I rowsort
SELECT - col2 + col2 * 83 FROM tab0 AS cor0
----
2706
6724
82

query I rowsort
SELECT DISTINCT + tab0.col2 * - tab0.col0 FROM tab0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3682
SELECT - tab2.col1 - CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3682
SELECT - tab2.col1 - CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - 72 FROM tab2 cor0
----
72
72
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 35 * - col2 col1 FROM tab1 AS cor0
----
1890
1995
3360

query I rowsort
SELECT DISTINCT - 1 * col2 + col0 * 85 FROM tab1 AS cor0
----
201
5383
6704

query I rowsort
SELECT ALL - col1 + - 89 * + tab0.col1 AS col2 FROM tab0
----
-7740
-8190
-8730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col1 * - 56 col0 FROM tab2
----
1767
3363
969

query I rowsort
SELECT col1 * 89 * - 12 AS col0 FROM tab2
----
-18156
-33108
-63012

query I rowsort
SELECT col1 - - 38 AS col2 FROM tab1
----
48
51
64

query I rowsort
SELECT ALL - col2 - - 47 FROM tab1
----
-10
-49
-7

query I rowsort
SELECT - col1 * - ( - col0 ) AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 - + col1 col0 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3693
SELECT ( + col0 ) DIV + col2 + + col2 col1 FROM tab1 AS cor0
----
54
58
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3693
SELECT ( + col0 ) / + col2 + + col2 col1 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT - col2 + + col1 * + col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL + col0 + + cor0.col2 * - col0 + + cor0.col1 * + col1 AS col1 FROM tab1 AS cor0
----
-3484
-7431
517

query I rowsort
SELECT ALL + - cor0.col2 - - 15 AS col2 FROM tab2 AS cor0
----
-11
-12
-23

query I rowsort
SELECT + + 73 * 42 * col1 + - 99 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
30618
39855
79671

query I rowsort
SELECT cor0.col2 * 24 AS col1 FROM tab2 AS cor0
----
624
648
912

query I rowsort
SELECT ALL + cor0.col2 + - col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3700
SELECT ALL CAST( - 56 AS SIGNED ) * - col1 FROM tab0 AS cor0
----
4816
5096
5432

skipif mysql # not compatible
query I rowsort label-3700
SELECT ALL CAST ( - 56 AS INTEGER ) * - col1 FROM tab0 AS cor0
----
4816
5096
5432

query I rowsort
SELECT ALL 3 * col0 FROM tab0
----
105
267
72

query I rowsort
SELECT - tab2.col2 + - 35 * 50 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 9df5bc2c215d3173b20039a6e39ad683

query I rowsort
SELECT ALL + col0 * + ( cor0.col1 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT col0 + 53 * + col2 AS col0 FROM tab1 AS cor0
----
2865
3085
5168

query I rowsort
SELECT ALL + - cor0.col2 + 38 AS col2 FROM tab0 AS cor0
----
-44
37
5

query I rowsort
SELECT 91 * 47 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to fd45466e6df20145f1b9999f8152320f

query I rowsort
SELECT + col1 - col0 AS col1 FROM tab2 cor0
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3708
SELECT ALL - col2 + - CAST( NULL AS DECIMAL ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3708
SELECT ALL - col2 + - CAST ( NULL AS REAL ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3709
SELECT DISTINCT + col2 DIV + ( - col2 ) FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3709
SELECT DISTINCT + col2 / + ( - col2 ) FROM tab1 cor0
----
-1

query I rowsort
SELECT ALL 83 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

onlyif mysql # use DIV operator for integer division
query I rowsort label-3711
SELECT - + col1 DIV - ( col2 ) FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3711
SELECT - + col1 / - ( col2 ) FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT ALL + col0 + 59 * col2 * col0 FROM tab1 AS cor0
----
215296
453200
9561

query I rowsort
SELECT DISTINCT col1 + + 77 AS col0 FROM tab2 AS cor0
----
108
136
94

query I rowsort
SELECT cor0.col0 * + 65 FROM tab1 AS cor0
----
195
4160
5200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 60 ) col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

query I rowsort
SELECT DISTINCT + - col1 * - col1 * - col2 AS col1 FROM tab1 cor0
----
-16224
-36504
-5700

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 cor2
----
3645 values hashing to 4406ccc71f02ae9c1e947ffcd89b0db7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 26 col1 FROM tab0
----
26
26
26

query I rowsort
SELECT + 62 * 55 FROM tab0 cor0
----
3410
3410
3410

onlyif mysql # use DIV operator for integer division
query I rowsort label-3720
SELECT DISTINCT - CAST( + col2 AS SIGNED ) DIV + col0 + + 56 AS col1 FROM tab0 AS cor0
----
55
56

skipif mysql # not compatible
query I rowsort label-3720
SELECT DISTINCT - CAST ( + col2 AS INTEGER ) / + col0 + + 56 AS col1 FROM tab0 AS cor0
----
55
56

query I rowsort
SELECT DISTINCT + - ( - ( col1 ) ) AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT col2 * col2 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3723
SELECT ALL - - CAST( NULL AS SIGNED ) * cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3723
SELECT ALL - - CAST ( NULL AS INTEGER ) * cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3724
SELECT - + col2 DIV col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3724
SELECT - + col2 / col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - col2 * 95 AS col0 FROM tab2 AS cor0
----
-2470
-2565
-3610

query I rowsort
SELECT DISTINCT - + 77 AS col2 FROM tab0 AS cor0
----
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 31 * - cor0.col1 col1 FROM tab2 cor0
----
-1829
-527
-961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3728
SELECT ALL + - 97 + - col0 + CAST( col2 + - col1 AS SIGNED ) * - col1 AS col2 FROM tab1 AS cor0
----
-1256
-631
-828

skipif mysql # not compatible
query I rowsort label-3728
SELECT ALL + - 97 + - col0 + CAST ( col2 + - col1 AS INTEGER ) * - col1 AS col2 FROM tab1 AS cor0
----
-1256
-631
-828

query I rowsort
SELECT DISTINCT + 72 * tab1.col2 FROM tab1
----
3888
4104
6912

query I rowsort
SELECT - col0 * - col1 * 72 AS col0 FROM tab0 cor0
----
148608
244440
583128

query I rowsort
SELECT ALL - cor0.col1 * + col1 + - col0 * + col0 * col0 AS col0 FROM tab1 AS cor0
----
-262244
-512169
-703

query I rowsort
SELECT + 98 * + col2 FROM tab2 AS cor0
----
2548
2646
3724

query I rowsort
SELECT + col0 + 32 AS col0 FROM tab1 AS cor0
----
112
35
96

query I rowsort
SELECT ALL - col2 - - ( cor0.col1 ) FROM tab2 cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3735
SELECT col1 DIV + 73 - + cor0.col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3735
SELECT col1 / + 73 - + cor0.col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + cor0.col2 * - 83 AS col0 FROM tab2 AS cor0
----
-2158
-2241
-3154

onlyif mysql # use DIV operator for integer division
query I rowsort label-3737
SELECT ALL col1 DIV 41 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3737
SELECT ALL col1 / 41 FROM tab2 cor0
----
0
0
1

query I rowsort
SELECT ALL - col0 * 36 * + col2 + + col0 FROM tab2 AS cor0
----
-107993
-6797
-72930

query I rowsort
SELECT ALL - col0 * - 59 AS col0 FROM tab2 AS cor0
----
413
4602
4661

query I rowsort
SELECT ALL - + col2 * 0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + 77 * - 1 + col1 FROM tab0 AS cor0
----
14
20
9

query I rowsort
SELECT + col1 + 6 * col1 AS col0 FROM tab0 cor0
----
602
637
679

query I rowsort
SELECT ALL - 9 + - 84 * + col2 * + ( ( col1 ) ) AS col0 FROM tab0 AS cor0
----
-238401
-626817
-8157

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col0 col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - ( + 40 ) * - col2 + col2 AS col0 FROM tab0 AS cor0
----
1353
3362
41

query I rowsort
SELECT DISTINCT ( col1 ) * + col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + + 66 AS col1 FROM tab0 cor0
----
66
66
66

query I rowsort
SELECT cor0.col0 * 16 FROM tab2 AS cor0
----
112
1248
1264

query I rowsort
SELECT DISTINCT 60 + + 9 * col1 FROM tab0 AS cor0
----
834
879
933

query I rowsort
SELECT tab2.col0 + ( tab2.col0 ) - col0 AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL - 25 + 15 FROM tab2, tab0 cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3752
SELECT DISTINCT tab1.col0 + + ( - col2 ) * tab1.col2 + CAST( + col0 AS SIGNED ) FROM tab1
----
-2910
-3121
-9056

skipif mysql # not compatible
query I rowsort label-3752
SELECT DISTINCT tab1.col0 + + ( - col2 ) * tab1.col2 + CAST ( + col0 AS INTEGER ) FROM tab1
----
-2910
-3121
-9056

query I rowsort
SELECT 18 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT ALL col0 + + 71 * + col1 FROM tab2
----
1286
2208
4267

query I rowsort
SELECT ALL col1 * col1 + + tab1.col0 AS col0 FROM tab1
----
164
249
679

query I rowsort
SELECT DISTINCT + col2 * + ( 97 ) + - col2 * col1 * col2 FROM tab0
----
-603930
-90453
0

query I rowsort
SELECT + - col1 * + 73 + col2 FROM tab1 AS cor0
----
-1844
-673
-853

query I rowsort
SELECT - tab2.col0 * 7 AS col0 FROM tab2
----
-49
-546
-553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3759
SELECT - CAST( NULL AS DECIMAL ) col2 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3759
SELECT - CAST ( NULL AS REAL ) col2 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 + CAST ( - 76 AS REAL ) AS col1 FROM tab0
----
-41
-52
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * ( + col2 ) col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - ( col0 * tab2.col2 ) FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT - 66 * col1 AS col1 FROM tab1
----
-1716
-660
-858

query I rowsort
SELECT + col1 + col2 * - ( - col0 ) FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT 88 * col1 + col0 FROM tab1
----
1224
2291
944

query I rowsort
SELECT DISTINCT 38 AS col1 FROM tab1, tab2 cor0
----
38

query I rowsort
SELECT + ( - ( + col0 ) + ( col1 ) ) * - tab2.col2 AS col2 FROM tab2
----
-648
2356
494

query I rowsort
SELECT + + cor0.col2 + - col1 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT 34 - col2 AS col2 FROM tab2
----
-4
7
8

query I rowsort
SELECT + col2 - - ( col1 * + col2 ) AS col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT col2 + + 63 AS col1 FROM tab1 AS cor0
----
117
120
159

skipif mysql # not compatible
query I rowsort
SELECT cor0.col2 * CAST ( + cor0.col2 AS REAL ) - - col0 * - ( col1 + col1 ) AS col2 FROM tab1 AS cor0
----
1969
2760
7136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 74 * tab1.col0 col2 FROM tab1
----
222
4736
5920

query I rowsort
SELECT + 98 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT - col0 * 91 AS col2 FROM tab2
----
-637
-7098
-7189

query I rowsort
SELECT ALL - cor0.col1 * + col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3777
SELECT ALL - col0 + CAST( NULL AS SIGNED ) / + 91 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3777
SELECT ALL - col0 + CAST ( NULL AS INTEGER ) / + 91 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - col2 col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + col2 * - 21 AS col0 FROM tab1 AS cor0
----
-1134
-1197
-2016

query I rowsort
SELECT DISTINCT col2 * + ( - 87 ) FROM tab0 AS cor0
----
-2871
-7134
-87

query I rowsort
SELECT + col0 - 32 * col1 AS col1 FROM tab2 cor0
----
-1810
-465
-985

query I rowsort
SELECT ALL - col1 - - col1 * + col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT ALL col0 * col0 + + ( col0 + - tab2.col2 ) FROM tab2
----
29
6136
6282

query I rowsort
SELECT DISTINCT + tab1.col0 AS col0 FROM tab1, tab2 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3785
SELECT - cor0.col2 DIV - col1 + + 67 - - col0 FROM tab0 cor0
----
102
156
91

skipif mysql # not compatible
query I rowsort label-3785
SELECT - cor0.col2 / - col1 + + 67 - - col0 FROM tab0 cor0
----
102
156
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-3786
SELECT ALL - col2 * - col1 + - col0 DIV col1 col2 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3786
SELECT ALL - col2 * - col1 + - col0 / col1 col2 FROM tab0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3787
SELECT + cor0.col1 + CAST( NULL AS SIGNED ) + col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3787
SELECT + cor0.col1 + CAST ( NULL AS INTEGER ) + col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 + + cor0.col1 * + 13 FROM tab2 AS cor0
----
204
372
708

query I rowsort
SELECT DISTINCT tab1.col0 + + 30 FROM tab1, tab2 AS cor0
----
110
33
94

query I rowsort
SELECT ALL - + 72 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

query I rowsort
SELECT + col1 * + col1 * ( col0 ) FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-3792
SELECT DISTINCT + - col0 DIV + ( cor0.col0 ) + cor0.col2 * col2 AS col2 FROM tab1 AS cor0
----
2915
3248
9215

skipif mysql # not compatible
query I rowsort label-3792
SELECT DISTINCT + - col0 / + ( cor0.col0 ) + cor0.col2 * col2 AS col2 FROM tab1 AS cor0
----
2915
3248
9215

query I rowsort
SELECT ALL col2 + 76 AS col1 FROM tab1 cor0
----
130
133
172

query I rowsort
SELECT - col0 + - col0 * + col0 AS col1 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT col2 + + ( + col1 + + col0 ) AS col0 FROM tab2 cor0
----
134
163
65

query I rowsort
SELECT ALL col1 + ( col0 ) * - col0 AS col2 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT col0 + + ( col2 ) AS col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3798
SELECT + - CAST( - col2 AS SIGNED ) FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3798
SELECT + - CAST ( - col2 AS INTEGER ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT 22 * + col1 * cor0.col0 FROM tab2 AS cor0
----
101244
29546
4774

query I rowsort
SELECT + col1 + + 86 FROM tab2 AS cor0
----
103
117
145

query I rowsort
SELECT - 68 * + col2 FROM tab2 AS cor0
----
-1768
-1836
-2584

query I rowsort
SELECT ALL + col2 * 30 FROM tab2 AS cor0
----
1140
780
810

query I rowsort
SELECT DISTINCT - ( col0 ) + - col0 AS col1 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT + + 18 * col0 * col2 FROM tab2 AS cor0
----
3402
36504
54036

onlyif mysql # use DIV operator for integer division
query I rowsort label-3805
SELECT ALL + col1 DIV - col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3805
SELECT ALL + col1 / - col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - col2 * + col1 + col0 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT 37 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
126
61
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 29 col0 FROM tab0 AS cor0
----
-29
-29
-29

query I rowsort
SELECT ALL - cor0.col0 * - 82 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 669f1d4f8fa3ee4e77110d388fdff94d

query I rowsort
SELECT - 21 * cor0.col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to c8edb898d4296edfdc4a60681cdb3c61

query I rowsort
SELECT ALL - 54 FROM tab0, tab0 AS cor0
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

query I rowsort
SELECT ALL - 95 * + col2 * col0 FROM tab2
----
-17955
-192660
-285190

query I rowsort
SELECT ALL + + col2 + col0 * - col2 AS col2 FROM tab1 cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-3814
SELECT DISTINCT - + 11 DIV + cor0.col1 col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3814
SELECT DISTINCT - + 11 / + cor0.col1 col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 + + col2 col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - 49 + + col0 * + ( 83 ) AS col1 FROM tab1 AS cor0
----
200
5263
6591

query I rowsort
SELECT + cor0.col0 - - col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 + 86 + col1 * - col0 AS col2 FROM tab1 AS cor0
----
-1123
-654
-668

query I rowsort
SELECT - col2 * - col2 * + col0 - + col2 * col1 AS col0 FROM tab0 cor0
----
-62
23298
590974

onlyif mysql # use DIV operator for integer division
query I rowsort label-3820
SELECT - col2 DIV + col1 + - col2 FROM tab1
----
-103
-56
-62

skipif mysql # not compatible
query I rowsort label-3820
SELECT - col2 / + col1 + - col2 FROM tab1
----
-103
-56
-62

query I rowsort
SELECT + tab2.col2 + 24 AS col2 FROM tab2
----
50
51
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3822
SELECT 5 DIV + col0 - - col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3822
SELECT 5 / + col0 - - col1 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL 85 * col1 FROM tab1
----
1105
2210
850

query I rowsort
SELECT ALL - + tab2.col1 FROM tab2, tab2 AS cor0, tab1, tab2 cor1
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

query I rowsort
SELECT DISTINCT - - 40 + + 12 * + cor0.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
1024
436
52

query I rowsort
SELECT DISTINCT col1 * col0 + + ( col0 + col2 ) * + col0 AS col2 FROM tab1 AS cor0
----
15120
249
8384

query I rowsort
SELECT ( - col2 ) + ( - col0 ) * - col1 + col0 AS col1 FROM tab2
----
1384
197
4654

query I rowsort
SELECT DISTINCT + 30 * + 14 AS col0 FROM tab2, tab2 cor0
----
420

query I rowsort
SELECT ( - 70 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

onlyif mysql # use DIV operator for integer division
query I rowsort label-3830
SELECT - - CAST( + 4 AS SIGNED ) DIV col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3830
SELECT - - CAST ( + 4 AS INTEGER ) / col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT + cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT tab2.col1 + - ( - col1 ) AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL - col0 * - ( + col1 ) * - 15 FROM tab1
----
-1170
-15600
-9600

query I rowsort
SELECT + 46 * - col1 AS col2 FROM tab1 AS cor0
----
-1196
-460
-598

query I rowsort
SELECT DISTINCT + 15 * 53 AS col2 FROM tab2 AS cor0
----
795

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

onlyif mysql # use DIV operator for integer division
query I rowsort label-3837
SELECT + col0 DIV - ( - cor0.col0 * - ( - 39 ) ) AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3837
SELECT + col0 / - ( - cor0.col0 * - ( - 39 ) ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 90 + col1 FROM tab2 cor0
----
107
121
149

query I rowsort
SELECT ALL - 22 + 56 FROM tab0 AS cor0
----
34
34
34

query I rowsort
SELECT + ( cor0.col2 ) * cor0.col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-3841
SELECT + 71 * + cor0.col2 + + col0 DIV + col0 FROM tab2 AS cor0
----
1847
1918
2699

skipif mysql # not compatible
query I rowsort label-3841
SELECT + 71 * + cor0.col2 + + col0 / + col0 FROM tab2 AS cor0
----
1847
1918
2699

query I rowsort
SELECT + + 78 + - col0 FROM tab2 cor0
----
-1
0
71

query I rowsort
SELECT ALL + 17 * 23 + col0 AS col1 FROM tab1 AS cor0
----
394
455
471

query I rowsort
SELECT ALL + - 95 * - col1 AS col0 FROM tab0 AS cor0
----
8170
8645
9215

query I rowsort
SELECT ( cor0.col0 ) + + col0 + - 89 FROM tab0 AS cor0
----
-19
-41
89

query I rowsort
SELECT ALL + - col2 + - cor0.col1 * col2 FROM tab2 AS cor0
----
-1560
-684
-864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3847
SELECT ALL CAST( NULL AS SIGNED ) + 85 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3847
SELECT ALL CAST ( NULL AS INTEGER ) + 85 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 34 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 5b88331e40da4796cc4826c442aa45f7

query I rowsort
SELECT ALL - 76 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT DISTINCT + 98 FROM tab0 cor0 CROSS JOIN tab2 cor1
----
98

query I rowsort
SELECT DISTINCT 90 * + col0 AS col1 FROM tab1 AS cor0
----
270
5760
7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-3852
SELECT DISTINCT + col0 DIV col0 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-3852
SELECT DISTINCT + col0 / col0 FROM tab1 cor0
----
1

query I rowsort
SELECT + cor0.col1 * + 65 AS col0 FROM tab1 AS cor0
----
1690
650
845

onlyif mysql # use DIV operator for integer division
query I rowsort label-3854
SELECT tab1.col2 DIV CAST( - ( - col1 ) AS SIGNED ) AS col0 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-3854
SELECT tab1.col2 / CAST ( - ( - col1 ) AS INTEGER ) AS col0 FROM tab1
----
2
5
7

query I rowsort
SELECT - cor0.col2 * - 46 AS col1 FROM tab1 cor0
----
2484
2622
4416

query I rowsort
SELECT ALL col0 * 56 AS col2 FROM tab2 AS cor0
----
392
4368
4424

onlyif mysql # use DIV operator for integer division
query I rowsort label-3857
SELECT ALL col2 DIV 98 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3857
SELECT ALL col2 / 98 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - col2 * + col0 + + col0 + + col1 FROM tab0 AS cor0
----
-682
-7118
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3859
SELECT + + col1 DIV + col0 AS col1 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-3859
SELECT + + col1 / + col0 AS col1 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT + col2 + + ( ( + col1 ) + col2 ) AS col2 FROM tab0 AS cor0
----
152
255
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-3861
SELECT - + ( col1 ) + + col0 DIV + 23 FROM tab2 cor0
----
-14
-31
-56

skipif mysql # not compatible
query I rowsort label-3861
SELECT - + ( col1 ) + + col0 / + 23 FROM tab2 cor0
----
-14
-31
-56

query I rowsort
SELECT DISTINCT - col0 * col1 * - col2 FROM tab0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3863
SELECT cor0.col1 * col1 + + col1 + col0 DIV col0 FROM tab1 cor0
----
111
183
703

skipif mysql # not compatible
query I rowsort label-3863
SELECT cor0.col1 * col1 + + col1 + col0 / col0 FROM tab1 cor0
----
111
183
703

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * + col2 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - col1 + col0 * ( col2 ) FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT ( col0 ) + - 49 AS col0 FROM tab1 AS cor0
----
-46
15
31

query I rowsort
SELECT ALL - - 65 + + col2 * 91 AS col1 FROM tab2 AS cor0
----
2431
2522
3523

query I rowsort
SELECT - col2 * ( ( col1 ) + col0 ) FROM tab0 AS cor0
----
-132
-14760
-3630

query I rowsort
SELECT col1 * col2 * + 71 FROM tab1 AS cor0
----
40470
88608
99684

query I rowsort
SELECT col0 + + 52 * - col2 FROM tab0 AS cor0
----
-1692
-17
-4175

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT cor0.col2 * col0 + + ( + col2 ) * cor0.col0 * - col1 FROM tab1 AS cor0
----
-32832
-4050
-92160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3873
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab2, tab0 AS cor0, tab2 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-3873
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab2, tab0 AS cor0, tab2 cor1
----
NULL

query I rowsort
SELECT + col2 * col0 + - col2 FROM tab0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-3875
SELECT ALL + - 68 + - col2 DIV + col1 FROM tab1 AS cor0
----
-70
-73
-75

skipif mysql # not compatible
query I rowsort label-3875
SELECT ALL + - 68 + - col2 / + col1 FROM tab1 AS cor0
----
-70
-73
-75

query I rowsort
SELECT DISTINCT + col1 * col0 - col1 FROM tab1 WHERE NOT NULL IN ( - col0 * col2 + tab1.col0 + - col1 )
----

query I rowsort
SELECT DISTINCT + col2 + + col2 * - tab1.col2 AS col2 FROM tab1
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-3878
SELECT DISTINCT col1 DIV col2 + col0 * - col0 FROM tab0
----
-1128
-574
-7920

skipif mysql # not compatible
query I rowsort label-3878
SELECT DISTINCT col1 / col2 + col0 * - col0 FROM tab0
----
-1128
-574
-7920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + tab1.col0 ) col1 FROM tab1
----
3
64
80

query I rowsort
SELECT - ( 53 ) AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 2876418587c77a182d88db2907b0a51a

query I rowsort
SELECT ALL 53 * tab2.col0 * + col0 - + col2 * col2 FROM tab2
----
1868
321776
329329

query I rowsort
SELECT + ( col2 ) * - ( + col2 ) - cor0.col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT - + 63 * col1 * ( - col1 ) AS col1 FROM tab1 AS cor0
----
10647
42588
6300

onlyif mysql # use DIV operator for integer division
query I rowsort label-3884
SELECT + - col0 DIV - col0 + 94 * 49 * col2 FROM tab0 AS cor0
----
151999
377693
4607

skipif mysql # not compatible
query I rowsort label-3884
SELECT + - col0 / - col0 + 94 * 49 * col2 FROM tab0 AS cor0
----
151999
377693
4607

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col2 * - col0 - - col2 col1 FROM tab1
----
216
3705
7776

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT col0 * col1 > NULL
----

query I rowsort
SELECT ALL - col2 AS col1 FROM tab2 WHERE NULL > NULL
----

query I rowsort
SELECT ALL + col1 * + col0 + col1 AS col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT DISTINCT col1 * col1 + cor0.col0 AS col0 FROM tab1 cor0 WHERE NOT NULL IN ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 * + col1 col2 FROM tab2
----
1360
248
4661

query I rowsort
SELECT DISTINCT + col1 AS col1 FROM tab0 WHERE NOT ( col0 ) NOT IN ( + col0 )
----
86
91
97

query I rowsort
SELECT DISTINCT col1 FROM tab2 WHERE NULL < - col0 + + col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3893
SELECT ALL col0 DIV - col1 + - col0 AS col0 FROM tab1
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-3893
SELECT ALL col0 / - col1 + - col0 AS col0 FROM tab1
----
-3
-70
-86

query I rowsort
SELECT DISTINCT - col1 * col1 + col2 * + tab0.col0 FROM tab0
----
-6604
-9374
-983

query I rowsort
SELECT DISTINCT - col1 FROM tab2 WHERE NOT NULL > + col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col0 * col2 col1 FROM tab0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT DISTINCT col2 DIV + col1 + col1 * col1 * tab2.col2 FROM tab2
----
10984
25947
90506

skipif mysql # not compatible
query I rowsort label-3897
SELECT DISTINCT col2 / + col1 + col1 * col1 * tab2.col2 FROM tab2
----
10984
25947
90506

query I rowsort
SELECT ALL + col2 * col0 FROM tab1 WHERE NULL = NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3899
SELECT tab2.col2 + col0 DIV + tab2.col1 FROM tab2
----
27
27
42

skipif mysql # not compatible
query I rowsort label-3899
SELECT tab2.col2 + col0 / + tab2.col1 FROM tab2
----
27
27
42

query I rowsort
SELECT DISTINCT ( 23 + + col2 ) FROM tab0
----
105
24
56

query I rowsort
SELECT + ( + col2 * - col2 + col0 ) FROM tab1
----
-2913
-3185
-9136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col2 ) col1 FROM tab1 cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3903
SELECT + CAST( NULL AS SIGNED ) + - 81 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3903
SELECT + CAST ( NULL AS INTEGER ) + - 81 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 83 FROM tab1, tab2, tab2 AS cor0
----
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3905
SELECT DISTINCT 91 DIV - col1 FROM tab2
----
-1
-2
-5

skipif mysql # not compatible
query I rowsort label-3905
SELECT DISTINCT 91 / - col1 FROM tab2
----
-1
-2
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3906
SELECT DISTINCT - + ( 18 ) * + col0 - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3906
SELECT DISTINCT - + ( 18 ) * + col0 - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT - - 26 + + col2 AS col1 FROM tab2 AS cor0
----
52
53
64

query I rowsort
SELECT ALL + + ( 44 ) + col2 AS col0 FROM tab0 AS cor0
----
126
45
77

query I rowsort
SELECT ALL - - ( ( col1 ) ) * - col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + 46 * col1 FROM tab0 AS cor0
----
3956
4186
4462

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 88 + - col2 col2 FROM tab1 AS cor0
----
-142
-145
-184

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 31 col2 FROM tab2 AS cor0
----
31
31
31

query I rowsort
SELECT DISTINCT + cor0.col2 + + cor0.col1 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - + col2 * - col0 + + col2 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL - 82 * + col2 FROM tab1 cor0
----
-4428
-4674
-7872

query I rowsort
SELECT - col0 + col1 * + col1 AS col0 FROM tab0
----
7372
8192
9374

query I rowsort
SELECT DISTINCT 50 * col2 FROM tab0
----
1650
4100
50

query I rowsort
SELECT + 27 + col2 AS col2 FROM tab1 AS cor0
----
123
81
84

query I rowsort
SELECT col2 + 88 AS col0 FROM tab1
----
142
145
184

query I rowsort
SELECT + col2 + - col2 * - col1 FROM tab0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - col0 + 37 AS col2 FROM tab2 AS cor0
----
-41
-42
30

query I rowsort
SELECT + cor0.col1 * + 73 + col1 FROM tab0 AS cor0
----
6364
6734
7178

query I rowsort
SELECT + - col2 * - ( 19 ) + - col0 FROM tab0 AS cor0
----
-16
1469
603

onlyif mysql # use DIV operator for integer division
query I rowsort label-3924
SELECT ALL + + col2 * col0 - col0 * col1 DIV - col1 AS col2 FROM tab0 cor0
----
70
7387
816

skipif mysql # not compatible
query I rowsort label-3924
SELECT ALL + + col2 * col0 - col0 * col1 / - col1 AS col2 FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT ALL + col1 * + col1 + - col1 * + col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 * - col2 + - col1 AS col0 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT + + cor0.col2 + ( + 89 ) FROM tab1 AS cor0
----
143
146
185

onlyif mysql # use DIV operator for integer division
query I rowsort label-3928
SELECT DISTINCT + + col0 + cor0.col1 DIV col0 FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-3928
SELECT DISTINCT + + col0 + cor0.col1 / col0 FROM tab2 AS cor0
----
11
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3929
SELECT cor0.col2 * + col0 + - col0 * col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3929
SELECT cor0.col2 * + col0 + - col0 * col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3930
SELECT cor0.col2 + - CAST( NULL AS DECIMAL ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3930
SELECT cor0.col2 + - CAST ( NULL AS REAL ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 49 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to adfccb10c9468825d9961e3613140f89

query I rowsort
SELECT DISTINCT + + col2 * 59 FROM tab0 cor0
----
1947
4838
59

query I rowsort
SELECT DISTINCT - tab1.col1 - col1 FROM tab1
----
-20
-26
-52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col0 + col0 * cor0.col2 col1 FROM tab2 AS cor0
----
203
2184
3160

query I rowsort
SELECT ALL - col2 * - cor0.col0 + col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + col2 - 16 AS col0 FROM tab0 cor0
----
-15
17
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-3937
SELECT - col0 DIV - col1 + - col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3937
SELECT - col0 / - col1 + - col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + ( col2 ) * + col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-3939
SELECT - + ( col2 ) DIV col0 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3939
SELECT - + ( col2 ) / col0 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT cor1.col1 * + cor1.col0 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 2afdaba7b80c700b7635230c4f8524be

query I rowsort
SELECT ( + col0 ) * - col0 * 5 + + 81 + + cor0.col0 * + 12 AS col2 FROM tab1 AS cor0
----
-19631
-30959
72

query I rowsort
SELECT DISTINCT + 7 * - col1 + + col1 + + col0 FROM tab2 AS cor0
----
-179
-23
-276

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col2 * ( 55 ) + col0 * + col1 col0 FROM tab0 AS cor0
----
-393291
-41496
1470

query I rowsort
SELECT ALL + 54 + - col1 * - col2 - - ( col0 + 91 ) AS col0 FROM tab0 AS cor0
----
277
3007
7696

query I rowsort
SELECT + 12 * col1 AS col0 FROM tab0 AS cor0
----
1032
1092
1164

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col0 ) + - ( col0 ) col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + 31 + cor0.col1 FROM tab2 AS cor0
----
48
62
90

query I rowsort
SELECT DISTINCT 16 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-38
-41
-80

query I rowsort
SELECT + col1 * + cor0.col0 + - ( - col1 * col0 ) FROM tab0 AS cor0
----
16198
4128
6790

query I rowsort
SELECT 34 + - col2 FROM tab2
----
-4
7
8

query I rowsort
SELECT - col1 * col0 + col1 + col2 FROM tab0
----
-1945
-3297
-7926

onlyif mysql # use DIV operator for integer division
query I rowsort label-3952
SELECT 23 DIV + col0 - - col2 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3952
SELECT 23 / + col0 - - col2 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - 43 + - col0 + - 87 FROM tab1
----
-133
-194
-210

query I rowsort
SELECT ALL + + 45 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3955
SELECT - - col1 + CAST( NULL AS SIGNED ) * 52 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3955
SELECT - - col1 + CAST ( NULL AS INTEGER ) * 52 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 * ( col2 ) + - col1 FROM tab2 cor0
----
-1461
-735
-760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3957
SELECT CAST( - 30 AS SIGNED ) FROM tab1, tab2 cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 6993f5c634597e63319c949df6b4733d

skipif mysql # not compatible
query I rowsort label-3957
SELECT CAST ( - 30 AS INTEGER ) FROM tab1, tab2 cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 6993f5c634597e63319c949df6b4733d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 9 ) col1 FROM tab1 AS cor0
----
-9
-9
-9

query I rowsort
SELECT ALL + 21 - - col2 * col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
3416
664139
68133

query I rowsort
SELECT DISTINCT - cor0.col0 + col1 + - col0 FROM tab2 AS cor0
----
-141
-97
17

query I rowsort
SELECT DISTINCT - col1 * - cor0.col1 + + col0 AS col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT col0 + - col2 * 26 FROM tab0
----
-2043
-834
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + tab1.col0 * - col0 col0 FROM tab1
----
-35
-4106
-6413

query I rowsort
SELECT + col1 * col2 + - col1 + + ( + 78 ) * col2 AS col1 FROM tab2
----
2912
3503
3593

onlyif mysql # use DIV operator for integer division
query I rowsort label-3966
SELECT DISTINCT - - col2 DIV + col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3966
SELECT DISTINCT - - col2 / + col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT 77 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 38f487c2147ee2fe05527e38c5e0503b

query I rowsort
SELECT DISTINCT - 17 - - 15 AS col0 FROM tab2 AS cor0
----
-2

query I rowsort
SELECT + + col0 + - 26 * + col1 AS col1 FROM tab0 AS cor0
----
-2212
-2277
-2487

query I rowsort
SELECT DISTINCT - - 80 * + 73 FROM tab2 AS cor0
----
5840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3971
SELECT CAST( NULL AS SIGNED ) * col1 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3971
SELECT CAST ( NULL AS INTEGER ) * col1 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 90 + - col2 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
-1938
-2912
-99

query I rowsort
SELECT - 49 FROM tab2, tab2 cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT - - col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL ( - 19 ) + col1 * 22 FROM tab1 cor0
----
201
267
553

query I rowsort
SELECT ALL 78 - - tab1.col2 FROM tab1
----
132
135
174

query I rowsort
SELECT 43 * + col0 AS col0 FROM tab2
----
301
3354
3397

query I rowsort
SELECT ( - 75 ) FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c0722b1d77ac0ed13c0f2691a5751c59

query I rowsort
SELECT 90 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

onlyif mysql # use DIV operator for integer division
query I rowsort label-3980
SELECT - ( + col0 ) DIV - 17 AS col0 FROM tab1 AS cor0
----
0
3
4

skipif mysql # not compatible
query I rowsort label-3980
SELECT - ( + col0 ) / - 17 AS col0 FROM tab1 AS cor0
----
0
3
4

query I rowsort
SELECT + col2 + 80 AS col2 FROM tab1
----
134
137
176

query I rowsort
SELECT col0 * 62 FROM tab2
----
434
4836
4898

query I rowsort
SELECT DISTINCT - - col1 * col1 + col0 * col0 FROM tab0 AS cor0
----
10634
16202
7972

query I rowsort
SELECT + 96 * + 24 FROM tab1 AS cor0
----
2304
2304
2304

query I rowsort
SELECT + ( col1 ) * - col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 54 * col2 AS col2 FROM tab2 AS cor0
----
1404
1458
2052

query I rowsort
SELECT tab1.col2 + + tab1.col1 * col0 AS col2 FROM tab1
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-3988
SELECT DISTINCT - col0 DIV 83 FROM tab0
----
-1
0

skipif mysql # not compatible
query I rowsort label-3988
SELECT DISTINCT - col0 / 83 FROM tab0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3989
SELECT - cor0.col1 + - cor0.col2 DIV col2 col1 FROM tab0 AS cor0
----
-87
-92
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3989
SELECT - cor0.col1 + - cor0.col2 / col2 col1 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT DISTINCT col1 - + 32 AS col1 FROM tab1 AS cor0
----
-19
-22
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3991
SELECT ALL + cor2.col1 DIV 72 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

skipif mysql # not compatible
query I rowsort label-3991
SELECT ALL + cor2.col1 / 72 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

query I rowsort
SELECT - 90 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c0d96679aba507520916e8654e5a6618

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + + ( 9 ) * - col1 col1 FROM tab2 AS cor0
----
-170
-310
-590

query I rowsort
SELECT DISTINCT + + cor0.col0 - - col0 * - cor0.col0 * + col1 AS col1 FROM tab2 AS cor0
----
-106018
-1512
-358878

query I rowsort
SELECT - cor0.col0 * + 94 FROM tab2, tab0 AS cor0
----
9 values hashing to afe37441cf632821cf92c0df6d8450cd

query I rowsort
SELECT ALL + + 46 AS col1 FROM tab2 AS cor0
----
46
46
46

query I rowsort
SELECT DISTINCT + - ( col2 ) * col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT col1 * 39 + + col2 * - col0 * col2 AS col1 FROM tab2 AS cor0
----
-113413
-3894
-50427

query I rowsort
SELECT + 15 * col1 AS col2 FROM tab1
----
150
195
390

query I rowsort
SELECT ALL - tab2.col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT - col1 + col2 AS col1 FROM tab1 cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 97 * col1 col0 FROM tab1
----
1261
2522
970

onlyif mysql # use DIV operator for integer division
query I rowsort label-4003
SELECT DISTINCT tab1.col0 DIV col1 + - ( tab1.col0 ) FROM tab1
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-4003
SELECT DISTINCT tab1.col0 / col1 + - ( tab1.col0 ) FROM tab1
----
-3
-58
-74

query I rowsort
SELECT - ( col1 ) + + 6 * col1 FROM tab2 cor0
----
155
295
85

query I rowsort
SELECT ALL 21 AS col2 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4006
SELECT DISTINCT - tab0.col1 DIV col0 + - ( col1 ) + - col1 FROM tab0
----
-175
-183
-196

skipif mysql # not compatible
query I rowsort label-4006
SELECT DISTINCT - tab0.col1 / col0 + - ( col1 ) + - col1 FROM tab0
----
-175
-183
-196

query I rowsort
SELECT DISTINCT - 57 FROM tab1, tab2, tab2 AS cor0
----
-57

query I rowsort
SELECT 87 * col0 * - tab1.col1 FROM tab1
----
-55680
-6786
-90480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4009
SELECT col2 * - col1 + CAST( + col2 AS SIGNED ) + col1 * - col0 FROM tab0
----
-15479
-3491
-4869

skipif mysql # not compatible
query I rowsort label-4009
SELECT col2 * - col1 + CAST ( + col2 AS INTEGER ) + col1 * - col0 FROM tab0
----
-15479
-3491
-4869

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - ( col0 * - cor0.col2 ) col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - - col2 + - 9 * col2 FROM tab1 AS cor0
----
-432
-456
-768

onlyif mysql # use DIV operator for integer division
query I rowsort label-4012
SELECT ALL col2 DIV col0 AS col1 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-4012
SELECT ALL col2 / col0 AS col1 FROM tab1 cor0
----
0
1
18

query I rowsort
SELECT + + col2 + - 24 * col0 * col1 AS col2 FROM tab1 AS cor0
----
-15303
-1818
-24864

onlyif mysql # use DIV operator for integer division
query I rowsort label-4014
SELECT + col1 * col1 DIV + col0 AS col0 FROM tab1 AS cor0
----
1
2
225

skipif mysql # not compatible
query I rowsort label-4014
SELECT + col1 * col1 / + col0 AS col0 FROM tab1 AS cor0
----
1
2
225

query I rowsort
SELECT ALL col1 * + 37 + col1 FROM tab2 cor0
----
1178
2242
646

query I rowsort
SELECT - - col0 * + ( 34 ) FROM tab2 AS cor0
----
238
2652
2686

query I rowsort
SELECT ALL col1 * + 53 FROM tab1 AS cor0
----
1378
530
689

query I rowsort
SELECT ALL - - col0 + 5 * col1 FROM tab2 AS cor0
----
162
164
373

query I rowsort
SELECT - + 18 * cor0.col2 - + col1 FROM tab1 AS cor0
----
-1036
-1741
-998

query I rowsort
SELECT + + 28 - cor0.col0 * col0 AS col2 FROM tab0 AS cor0
----
-1197
-548
-7893

query I rowsort
SELECT col2 * col1 + col0 FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT + col1 + col2 + - col0 * col0 FROM tab1
----
-4029
-6291
71

query I rowsort
SELECT col2 * + col0 + col1 + - col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT - col2 + + 20 FROM tab0 cor0
----
-13
-62
19

query I rowsort
SELECT ALL - - 16 FROM tab2 cor0
----
16
16
16

query I rowsort
SELECT - 7 * col1 + + col2 FROM tab1 AS cor0
----
-128
-13
5

query I rowsort
SELECT ALL - + 34 + + col2 * - col0 FROM tab0 AS cor0
----
-69
-7332
-826

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 AS REAL ) * col0 + + col2 + + 42 AS col1 FROM tab2 AS cor0
----
2096
258
3082

onlyif mysql # use DIV operator for integer division
query I rowsort label-4029
SELECT ALL ( + col2 ) DIV - col1 + 11 * + col2 AS col1 FROM tab2 AS cor0
----
286
297
416

skipif mysql # not compatible
query I rowsort label-4029
SELECT ALL ( + col2 ) / - col1 + 11 * + col2 AS col1 FROM tab2 AS cor0
----
286
297
416

query I rowsort
SELECT - - 9 * 7 + col1 FROM tab0 AS cor0
----
149
154
160

query I rowsort
SELECT 24 - cor0.col0 AS col0 FROM tab0 AS cor0
----
-11
-65
0

query I rowsort
SELECT ALL + col2 - + 69 FROM tab0 AS cor0
----
-36
-68
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + col2 col2 FROM tab1 cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4034
SELECT DISTINCT - 26 * col0 + + col2 DIV + 50 + - col1 DIV col2 AS col1 FROM tab0 AS cor0
----
-1007
-2314
-626

skipif mysql # not compatible
query I rowsort label-4034
SELECT DISTINCT - 26 * col0 + + col2 / + 50 + - col1 / col2 AS col1 FROM tab0 AS cor0
----
-1007
-2314
-626

query I rowsort
SELECT + 72 AS col1 FROM tab2 cor0
----
72
72
72

query I rowsort
SELECT ALL + - 30 AS col0 FROM tab0 AS cor0
----
-30
-30
-30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4037
SELECT - 4 + col2 * CAST( NULL AS SIGNED ) / - col1 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4037
SELECT - 4 + col2 * CAST ( NULL AS INTEGER ) / - col1 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * 17 + col1 + - ( col1 ) FROM tab1
----
1632
918
969

query I rowsort
SELECT + tab0.col0 + + col0 + tab0.col0 FROM tab0
----
105
267
72

query I rowsort
SELECT ALL + col2 + 2 + + col0 FROM tab1
----
123
178
59

query I rowsort
SELECT ALL - - tab1.col1 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL + col1 * 7 FROM tab2
----
119
217
413

query I rowsort
SELECT - col1 + + 13 AS col0 FROM tab0
----
-73
-78
-84

query I rowsort
SELECT col2 + - 18 AS col0 FROM tab2
----
20
8
9

query I rowsort
SELECT ALL - col1 * 47 FROM tab2
----
-1457
-2773
-799

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4046
SELECT DISTINCT - cor0.col1 * CAST( 64 AS SIGNED ) FROM tab2 cor0
----
-1088
-1984
-3776

skipif mysql # not compatible
query I rowsort label-4046
SELECT DISTINCT - cor0.col1 * CAST ( 64 AS INTEGER ) FROM tab2 cor0
----
-1088
-1984
-3776

query I rowsort
SELECT - col2 * cor0.col1 + - cor0.col1 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-4048
SELECT DISTINCT col0 DIV - 78 FROM tab2
----
-1
0

skipif mysql # not compatible
query I rowsort label-4048
SELECT DISTINCT col0 / - 78 FROM tab2
----
-1
0

query I rowsort
SELECT DISTINCT - col2 * cor0.col0 + 55 AS col1 FROM tab1 AS cor0
----
-107
-3593
-7625

query I rowsort
SELECT + - ( + cor0.col0 ) + + cor0.col2 AS col2 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-4051
SELECT + 25 DIV - col1 - col0 * + 8 AS col0 FROM tab2 AS cor0
----
-56
-624
-633

skipif mysql # not compatible
query I rowsort label-4051
SELECT + 25 / - col1 - col0 * + 8 AS col0 FROM tab2 AS cor0
----
-56
-624
-633

query I rowsort
SELECT + - col0 * - col0 + col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT + cor0.col1 * col1 - + col0 * + cor0.col0 * - cor0.col2 FROM tab2 AS cor0
----
161665
2284
237447

query I rowsort
SELECT ALL - - col0 + col2 AS col2 FROM tab1 cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 * col0 + - col2 col0 FROM tab0 AS cor0
----
-1449
-2066
-5333

query I rowsort
SELECT cor0.col1 * 29 - - col0 AS col2 FROM tab2 AS cor0
----
1789
572
906

query I rowsort
SELECT ( 77 ) * col0 AS col2 FROM tab2 AS cor0
----
539
6006
6083

onlyif mysql # use DIV operator for integer division
query I rowsort label-4058
SELECT - col0 - col0 DIV + col2 FROM tab0 AS cor0
----
-24
-70
-90

skipif mysql # not compatible
query I rowsort label-4058
SELECT - col0 - col0 / + col2 FROM tab0 AS cor0
----
-24
-70
-90

query I rowsort
SELECT ALL - - col2 + - col2 * + 42 FROM tab1 AS cor0
----
-2214
-2337
-3936

onlyif mysql # use DIV operator for integer division
query I rowsort label-4060
SELECT + col2 DIV + cor0.col0 FROM tab2 cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-4060
SELECT + col2 / + cor0.col0 FROM tab2 cor0
----
0
0
3

query I rowsort
SELECT DISTINCT + + 79 + col1 FROM tab1 AS cor0
----
105
89
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col2 * - col0 col2 FROM tab0 AS cor0
----
-7209
-768
0

skipif mysql # not compatible
query I rowsort
SELECT ALL - + 21 + - col2 + CAST ( + cor0.col0 AS REAL ) AS col2 FROM tab0 AS cor0
----
-14
-30
13

query I rowsort
SELECT ALL + cor0.col2 * col0 + col1 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT DISTINCT - + ( + col0 ) + ( - 5 ) * col2 AS col1 FROM tab1 AS cor0
----
-273
-349
-560

query I rowsort
SELECT ALL col2 + col1 * + 1 AS col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4067
SELECT col2 * col1 + CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4067
SELECT col2 * col1 + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 16 * - cor0.col1 + - col0 AS col2 FROM tab0 AS cor0
----
-1400
-1545
-1587

query I rowsort
SELECT - - col2 * col0 + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT + 13 AS col0 FROM tab2, tab2 AS cor0
----
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-4071
SELECT ALL 50 DIV + col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4071
SELECT ALL 50 / + col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - col1 * 95 FROM tab1 AS cor0
----
-1235
-2470
-950

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 78 col0 FROM tab2
----
78
78
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 4 col2 FROM tab1
----
4

query I rowsort
SELECT - cor0.col2 * + 1 + col1 * + cor0.col1 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT ALL col2 - + ( + col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + cor0.col0 + col2 * 43 AS col2 FROM tab0 cor0
----
1395
3437
8

query I rowsort
SELECT col2 + 88 AS col0 FROM tab1 AS cor0
----
142
145
184

query I rowsort
SELECT DISTINCT - ( - cor0.col1 ) * + 4 FROM tab0, tab0 AS cor0
----
344
364
388

query I rowsort
SELECT DISTINCT + - 3 + col2 * + col2 AS col1 FROM tab0 AS cor0
----
-2
1086
6721

query I rowsort
SELECT 19 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT cor0.col0 + - col1 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + 51 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 55 * - col2 - + col1 col1 FROM tab1
----
2944
3125
5267

onlyif mysql # use DIV operator for integer division
query I rowsort label-4085
SELECT - cor0.col2 + - col0 * - ( - cor0.col1 ) + col0 DIV col0 AS col1 FROM tab2 AS cor0
----
-1380
-243
-4627

skipif mysql # not compatible
query I rowsort label-4085
SELECT - cor0.col2 + - col0 * - ( - cor0.col1 ) + col0 / col0 AS col1 FROM tab2 AS cor0
----
-1380
-243
-4627

query I rowsort
SELECT col2 * - col0 + 60 AS col1 FROM tab1 AS cor0
----
-102
-3588
-7620

query I rowsort
SELECT col1 * col1 + + col0 FROM tab0
----
7420
8370
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-4088
SELECT ALL - + 86 * 2 + col2 DIV col2 FROM tab1 AS cor0
----
-171
-171
-171

skipif mysql # not compatible
query I rowsort label-4088
SELECT ALL - + 86 * 2 + col2 / col2 FROM tab1 AS cor0
----
-171
-171
-171

query I rowsort
SELECT DISTINCT + 85 * - col0 AS col2 FROM tab1 AS cor0
----
-255
-5440
-6800

query I rowsort
SELECT ALL 44 + ( col1 ) FROM tab2 AS cor0
----
103
61
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col0 * col0 * cor0.col1 col1 FROM tab2 cor0
----
-106018
-1512
-358878

query I rowsort
SELECT - 17 * cor0.col0 FROM tab1 AS cor0
----
-1088
-1360
-51

query I rowsort
SELECT col1 * col2 + col2 AS col0 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT ALL col1 * - col2 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - 69 - cor0.col0 FROM tab0 AS cor0
----
-104
-158
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4096
SELECT - 65 + - col2 * col0 DIV + col1 FROM tab2 AS cor0
----
-241
-71
-99

skipif mysql # not compatible
query I rowsort label-4096
SELECT - 65 + - col2 * col0 / + col1 FROM tab2 AS cor0
----
-241
-71
-99

query I rowsort
SELECT DISTINCT - 91 * col2 FROM tab2 AS cor0
----
-2366
-2457
-3458

onlyif mysql # use DIV operator for integer division
query I rowsort label-4098
SELECT - col1 DIV ( col1 ) - col1 * col2 FROM tab1 cor0
----
-1249
-1405
-571

skipif mysql # not compatible
query I rowsort label-4098
SELECT - col1 / ( col1 ) - col1 * col2 FROM tab1 cor0
----
-1249
-1405
-571

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4099
SELECT - + col0 - + CAST( NULL AS SIGNED ) * - 83 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4099
SELECT - + col0 - + CAST ( NULL AS INTEGER ) * - 83 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4100
SELECT ALL + col0 DIV col0 + col2 * col2 * - 27 AS col1 FROM tab2
----
-18251
-19682
-38987

skipif mysql # not compatible
query I rowsort label-4100
SELECT ALL + col0 / col0 + col2 * col2 * - 27 AS col1 FROM tab2
----
-18251
-19682
-38987

query I rowsort
SELECT + col2 * - ( - col0 ) FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4102
SELECT DISTINCT + - col1 + + 74 DIV - 41 AS col1 FROM tab1 cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-4102
SELECT DISTINCT + - col1 + + 74 / - 41 AS col1 FROM tab1 cor0
----
-11
-14
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-4103
SELECT DISTINCT + - col0 DIV + 16 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-4103
SELECT DISTINCT + - col0 / + 16 FROM tab2 AS cor0
----
-4
0

query I rowsort
SELECT - + 30 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

query I rowsort
SELECT ALL - col0 * - cor0.col1 + - 80 AS col2 FROM tab0 cor0
----
1984
3315
8019

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col0 * CAST ( - col0 AS REAL ) AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - cor0.col1 + - ( col2 ) FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4108
SELECT + 25 + cor0.col1 DIV + col0 FROM tab1 cor0
----
25
25
33

skipif mysql # not compatible
query I rowsort label-4108
SELECT + 25 + cor0.col1 / + col0 FROM tab1 cor0
----
25
25
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col2 col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL col1 * + col0 + + tab1.col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL col0 * - col0 + - ( col2 ) * col2 AS col2 FROM tab0
----
-1226
-14645
-1665

onlyif mysql # use DIV operator for integer division
query I rowsort label-4112
SELECT DISTINCT ( col0 ) DIV col0 AS col1 FROM tab0 cor0
----
1

skipif mysql # not compatible
query I rowsort label-4112
SELECT DISTINCT ( col0 ) / col0 AS col1 FROM tab0 cor0
----
1

query I rowsort
SELECT - 19 * - col2 - col0 AS col2 FROM tab0 AS cor0
----
-16
1469
603

query I rowsort
SELECT ALL - cor0.col1 + - ( + col2 ) + col1 * col0 AS col1 FROM tab2 AS cor0
----
1288
159
4517

query I rowsort
SELECT DISTINCT - col0 + - 11 * - col1 * 38 FROM tab1 AS cor0
----
10865
4116
5354

query I rowsort
SELECT DISTINCT - col2 * col0 + tab1.col2 AS col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT ALL - col2 + 39 FROM tab2
----
1
12
13

query I rowsort
SELECT ALL - col2 * + 23 + - col2 AS col0 FROM tab1
----
-1296
-1368
-2304

query I rowsort
SELECT ALL + 53 * + cor0.col0 FROM tab1 AS cor0
----
159
3392
4240

query I rowsort
SELECT ALL + col0 * 40 FROM tab0 AS cor0
----
1400
3560
960

query I rowsort
SELECT - ( + col1 ) * col1 AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT ( + 1 + + col2 ) FROM tab2
----
27
28
39

query I rowsort
SELECT col0 - - col1 * 23 FROM tab0
----
2002
2182
2266

onlyif mysql # use DIV operator for integer division
query I rowsort label-4124
SELECT 1 * + col1 - tab0.col1 DIV tab0.col1 AS col0 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-4124
SELECT 1 * + col1 - tab0.col1 / tab0.col1 AS col0 FROM tab0
----
85
90
96

query I rowsort
SELECT ALL + + col0 * - col2 - 39 AS col2 FROM tab0 AS cor0
----
-7337
-74
-831

query I rowsort
SELECT + 52 * cor1.col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e4fcc5f8add036287a64ac85006d07ae

query I rowsort
SELECT - ( - col2 ) * 24 FROM tab2 AS cor0
----
624
648
912

query I rowsort
SELECT DISTINCT + col2 * - col0 * col0 AS col1 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT 67 * col2 + - 69 FROM tab0
----
-2
2142
5425

query I rowsort
SELECT tab2.col1 * col0 + - 83 FROM tab2
----
1260
134
4519

query I rowsort
SELECT - col2 * 62 * + col1 AS col0 FROM tab0 AS cor0
----
-175956
-462644
-6014

skipif mysql # not compatible
query I rowsort
SELECT ALL + - cor0.col0 * CAST ( + 37 AS REAL ) - - col0 FROM tab2 AS cor0
----
-252
-2808
-2844

query I rowsort
SELECT + cor0.col0 - 26 * col0 AS col2 FROM tab1 cor0
----
-1600
-2000
-75

query I rowsort
SELECT ALL - col2 + + 55 AS col0 FROM tab0 AS cor0
----
-27
22
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-4135
SELECT - col2 + col0 + col0 DIV - col2 AS col0 FROM tab1
----
-16
-51
6

skipif mysql # not compatible
query I rowsort label-4135
SELECT - col2 + col0 + col0 / - col2 AS col0 FROM tab1
----
-16
-51
6

query I rowsort
SELECT 73 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col2 col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT col2 * ( + cor0.col2 + col0 ) FROM tab1 AS cor0
----
16896
3078
6897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 * 74 col2 FROM tab1 AS cor0
----
-3996
-4218
-7104

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4140
SELECT ALL col0 + + CAST( 23 AS SIGNED ) FROM tab1 AS cor0
----
103
26
87

skipif mysql # not compatible
query I rowsort label-4140
SELECT ALL col0 + + CAST ( 23 AS INTEGER ) FROM tab1 AS cor0
----
103
26
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 95 * col2 col1 FROM tab0 AS cor0
----
3168
7872
96

query I rowsort
SELECT ALL cor0.col1 + col0 * cor0.col2 * - col1 AS col0 FROM tab2 AS cor0
----
-119593
-51017
-5828

query I rowsort
SELECT - col2 + ( + 57 ) * - col2 FROM tab1 AS cor0
----
-3132
-3306
-5568

query I rowsort
SELECT - - col1 * - ( col1 ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT col0 + cor0.col2 * col0 AS col0 FROM tab2 AS cor0
----
196
2106
3081

skipif mysql # not compatible
query I rowsort
SELECT CAST ( ( + col0 ) AS REAL ) + + col1 FROM tab0
----
110
132
180

query I rowsort
SELECT - 18 + + col2 FROM tab2 cor0
----
20
8
9

query I rowsort
SELECT DISTINCT - 80 * - col2 AS col0 FROM tab1
----
4320
4560
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4149
SELECT ALL ( - 98 ) DIV - col0 AS col2 FROM tab2
----
1
1
14

skipif mysql # not compatible
query I rowsort label-4149
SELECT ALL ( - 98 ) / - col0 AS col2 FROM tab2
----
1
1
14

query I rowsort
SELECT DISTINCT + + ( + col0 ) + col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT - ( - col2 + + col2 ) AS col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 60 + col2 * col2 col1 FROM tab1
----
14016
3096
7089

query I rowsort
SELECT ALL + - cor0.col1 * - col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - 86 * + col0 * col0 FROM tab2 AS cor0
----
-4214
-523224
-536726

query I rowsort
SELECT - 45 * col2 + - col1 FROM tab2 cor0
----
-1229
-1246
-1727

query I rowsort
SELECT ALL cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + col1 * ( - 30 ) + col0 FROM tab1 AS cor0
----
-236
-310
-777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col1 * col1 col0 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT + col1 * - ( - col1 ) * col2 + col1 * - col2 - + col0 AS col2 FROM tab1 AS cor0
----
14896
35097
5066

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4160
SELECT ALL - col2 * - CAST( NULL AS SIGNED ) * + col1 + cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4160
SELECT ALL - col2 * - CAST ( NULL AS INTEGER ) * + col1 + cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + ( col2 ) AS col1 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col0 * col2 + col2 col0 FROM tab1 AS cor0
----
242
3715
7789

query I rowsort
SELECT DISTINCT col1 * col2 * + col1 AS col0 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT + + col1 + - 71 FROM tab2 AS cor0
----
-12
-40
-54

onlyif mysql # use DIV operator for integer division
query I rowsort label-4165
SELECT ALL - - col0 DIV col1 AS col0 FROM tab2 cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4165
SELECT ALL - - col0 / col1 AS col0 FROM tab2 cor0
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4166
SELECT col1 + + ( - 68 ) DIV cor0.col2 FROM tab1 AS cor0
----
13
25
9

skipif mysql # not compatible
query I rowsort label-4166
SELECT col1 + + ( - 68 ) / cor0.col2 FROM tab1 AS cor0
----
13
25
9

query I rowsort
SELECT DISTINCT col0 * 99 FROM tab0 AS cor0
----
2376
3465
8811

onlyif mysql # use DIV operator for integer division
query I rowsort label-4168
SELECT DISTINCT + cor0.col2 DIV col1 AS col2 FROM tab2 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-4168
SELECT DISTINCT + cor0.col2 / col1 AS col2 FROM tab2 AS cor0
----
0
2

query I rowsort
SELECT col2 + col0 * col0 AS col1 FROM tab1
----
4153
63
6496

query I rowsort
SELECT - ( + cor0.col2 ) * - col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL col0 * - col1 + - tab1.col2 FROM tab1
----
-1136
-132
-697

query III rowsort
SELECT * FROM tab1 WHERE - col2 / col1 IN ( tab1.col0 * + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * tab1.col0 * tab1.col1 - col1 * + col2 col0 FROM tab1
----
-1638
-41530
-84448

onlyif mysql # use DIV operator for integer division
query I rowsort label-4174
SELECT + cor0.col1 + col1 DIV col2 FROM tab0 AS cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-4174
SELECT + cor0.col1 + col1 / col2 FROM tab0 AS cor0
----
194
88
92

query I rowsort
SELECT + - cor0.col1 + + col1 * + col1 + cor0.col0 FROM tab0 cor0
----
7334
8279
9347

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col1 + + col1 col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - col1 + col0 * cor0.col0 * + col0 FROM tab0 AS cor0
----
13738
42778
704878

query III rowsort
SELECT DISTINCT * FROM tab2 cor0 WHERE NOT NULL NOT IN ( col0 + + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4179
SELECT - col0 + col0 DIV - col1 FROM tab1 AS cor0
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-4179
SELECT - col0 + col0 / - col1 FROM tab1 AS cor0
----
-3
-70
-86

query I rowsort
SELECT cor0.col0 * - col0 * + col2 FROM tab1 AS cor0
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 * - col0 col2 FROM tab1
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col2 col2 FROM tab1
----
109
67
80

query I rowsort
SELECT col0 * col2 * col2 FROM tab0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-4184
SELECT + col0 * + col2 - col2 DIV col1 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-4184
SELECT + col0 * + col2 - col2 / col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT tab0.col2 AS col1 FROM tab0, tab1, tab2 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 * col2 + col2 * col1 * + col2 - 55 FROM tab1
----
127433
36083
75923

onlyif mysql # use DIV operator for integer division
query I rowsort label-4187
SELECT tab2.col0 + col1 DIV col0 - col2 FROM tab2
----
-16
41
52

skipif mysql # not compatible
query I rowsort label-4187
SELECT tab2.col0 + col1 / col0 - col2 FROM tab2
----
-16
41
52

query I rowsort
SELECT DISTINCT - col2 * col0 + + cor0.col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT 61 * + col0 * - col0 FROM tab0 AS cor0
----
-35136
-483181
-74725

query I rowsort
SELECT - ( - col1 ) - - cor0.col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + 65 * col2 AS col0 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT DISTINCT col2 + col2 + - col2 FROM tab1
----
54
57
96

query I rowsort
SELECT + - ( 2 ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT - 43 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT ALL tab0.col0 + - 93 AS col0 FROM tab0
----
-4
-58
-69

query I rowsort
SELECT DISTINCT - col1 * 42 * + col2 + + col0 FROM tab1
----
-23876
-52336
-58965

query I rowsort
SELECT ALL + col1 * + ( col0 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + cor0.col0 + - 0 * + cor0.col2 + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - 91 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4200
SELECT - col2 * CAST( 13 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-1066
-13
-429

skipif mysql # not compatible
query I rowsort label-4200
SELECT - col2 * CAST ( 13 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-1066
-13
-429

query I rowsort
SELECT ALL col2 * col1 * + col2 AS col1 FROM tab1
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-4202
SELECT - col0 * col2 DIV col1 - 55 AS col2 FROM tab0
----
-135
-55
-64

skipif mysql # not compatible
query I rowsort label-4202
SELECT - col0 * col2 / col1 - 55 AS col2 FROM tab0
----
-135
-55
-64

query I rowsort
SELECT DISTINCT 99 * + 63 FROM tab0
----
6237

query I rowsort
SELECT DISTINCT - + 86 * col1 FROM tab1 AS cor0
----
-1118
-2236
-860

query I rowsort
SELECT DISTINCT + 86 - + cor0.col0 AS col0 FROM tab2 cor0
----
7
79
8

query I rowsort
SELECT ( + cor0.col0 ) + - col2 + - col2 AS col1 FROM tab0 AS cor0
----
-42
-75
33

query I rowsort
SELECT - col0 * col0 + + ( col0 ) + col1 AS col1 FROM tab0 AS cor0
----
-1093
-466
-7741

onlyif mysql # use DIV operator for integer division
query I rowsort label-4208
SELECT DISTINCT + - cor0.col2 DIV col0 AS col1 FROM tab2 cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-4208
SELECT DISTINCT + - cor0.col2 / col0 AS col1 FROM tab2 cor0
----
-3
0

query I rowsort
SELECT ALL - + 90 * col0 AS col1 FROM tab1 AS cor0
----
-270
-5760
-7200

query I rowsort
SELECT ALL 4 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT ALL - 86 + cor0.col2 FROM tab0 AS cor0
----
-4
-53
-85

query I rowsort
SELECT col2 * col2 + - ( - cor0.col2 ) * + col2 + col2 AS col2 FROM tab2 AS cor0
----
1378
1485
2926

query I rowsort
SELECT DISTINCT + 52 + - col1 FROM tab0 cor0
----
-34
-39
-45

query I rowsort
SELECT ALL + col1 + - col1 + + ( - tab1.col2 ) * - col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL 78 + - col0 * col2 * col0 AS col0 FROM tab1 AS cor0
----
-233394
-408
-614322

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 15 * col1 col1 FROM tab1 AS cor0
----
-150
-195
-390

onlyif mysql # use DIV operator for integer division
query I rowsort label-4217
SELECT - CAST( - ( + col1 ) AS SIGNED ) DIV col0 + - col0 * + col1 AS col0 FROM tab0
----
-2061
-3393
-8098

skipif mysql # not compatible
query I rowsort label-4217
SELECT - CAST ( - ( + col1 ) AS INTEGER ) / col0 + - col0 * + col1 AS col0 FROM tab0
----
-2061
-3393
-8098

query I rowsort
SELECT DISTINCT - - 1 + + col0 FROM tab1 AS cor0
----
4
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4219
SELECT ALL + col2 * - tab0.col1 - tab0.col0 DIV 40 col0 FROM tab0
----
-2838
-7464
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4219
SELECT ALL + col2 * - tab0.col1 - tab0.col0 / 40 col0 FROM tab0
----
-2838
-7464
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4220
SELECT col2 + + col2 - + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4220
SELECT col2 + + col2 - + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * - col1 * - 48 FROM tab1 AS cor0
----
32448
4800
8112

query I rowsort
SELECT col0 + - col1 * col1 * - col2 AS col2 FROM tab1 cor0
----
16304
36507
5764

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col1 + + col0 col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT + tab2.col1 * col2 + - tab2.col2 * 43 FROM tab2
----
-324
-988
416

onlyif mysql # use DIV operator for integer division
query I rowsort label-4225
SELECT ALL - col2 * col2 + - 66 DIV - tab1.col0 FROM tab1
----
-2894
-3248
-9216

skipif mysql # not compatible
query I rowsort label-4225
SELECT ALL - col2 * col2 + - 66 / - tab1.col0 FROM tab1
----
-2894
-3248
-9216

query I rowsort
SELECT DISTINCT col1 * - col2 - + col0 * ( col2 ) AS col2 FROM tab0 AS cor0
----
-132
-14760
-3630

query I rowsort
SELECT DISTINCT + col0 * 28 + col2 FROM tab1 AS cor0
----
138
1849
2336

onlyif mysql # use DIV operator for integer division
query I rowsort label-4228
SELECT ALL + 24 DIV col0 AS col2 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-4228
SELECT ALL + 24 / col0 AS col2 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL - col1 + cor0.col2 * col2 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT - col2 + - col0 * col2 FROM tab0 AS cor0
----
-36
-7380
-825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * - col0 + col2 col2 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4232
SELECT ALL - CAST( NULL AS SIGNED ) + + 77 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4232
SELECT ALL - CAST ( NULL AS INTEGER ) + + 77 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * + 57 * + cor0.col0 + col2 * col0 FROM tab0 cor0
----
-1960
-408688
-44352

query I rowsort
SELECT 69 + col1 * - col1 FROM tab1 AS cor0
----
-100
-31
-607

query I rowsort
SELECT ALL col0 * - ( - tab0.col2 ) + col1 * col0 AS col0 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT ALL col2 + + 66 * col1 AS col2 FROM tab0
----
5709
6088
6403

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col1 + col2 col0 FROM tab1
----
111
163
31

query I rowsort
SELECT 29 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT col2 * - ( col2 * col1 ) + + col1 * + 82 FROM tab0
----
-604422
-86602
7857

onlyif mysql # use DIV operator for integer division
query I rowsort label-4240
SELECT ALL col2 * + CAST( col0 AS SIGNED ) + col1 DIV col2 + - col1 * - col2 AS col1 FROM tab1
----
1566
4218
8928

skipif mysql # not compatible
query I rowsort label-4240
SELECT ALL col2 * + CAST ( col0 AS INTEGER ) + col1 / col2 + - col1 * - col2 AS col1 FROM tab1
----
1566
4218
8928

query I rowsort
SELECT DISTINCT + 56 * 50 AS col2 FROM tab0 AS cor0
----
2800

query I rowsort
SELECT ALL + - ( + 15 ) * + col2 AS col0 FROM tab0 AS cor0
----
-1230
-15
-495

query I rowsort
SELECT 5 + col2 * + col1 AS col1 FROM tab1 AS cor0
----
1253
1409
575

query I rowsort
SELECT ALL + + col1 + ( - col2 ) FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4245
SELECT ALL + col0 DIV + 14 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7397
8287
9411

skipif mysql # not compatible
query I rowsort label-4245
SELECT ALL + col0 / + 14 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7397
8287
9411

query I rowsort
SELECT + - col2 * 31 FROM tab1 AS cor0
----
-1674
-1767
-2976

query I rowsort
SELECT DISTINCT - + 24 FROM tab0 cor0
----
-24

query I rowsort
SELECT + - cor0.col0 * 29 AS col0 FROM tab1 cor0
----
-1856
-2320
-87

query I rowsort
SELECT ALL + - 89 * col2 AS col0 FROM tab0 AS cor0
----
-2937
-7298
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4250
SELECT DISTINCT - - col1 DIV cor0.col1 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4250
SELECT DISTINCT - - col1 / cor0.col1 FROM tab0 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4251
SELECT DISTINCT - col2 * + 7 + col1 DIV - 23 AS col1 FROM tab0 AS cor0
----
-11
-234
-577

skipif mysql # not compatible
query I rowsort label-4251
SELECT DISTINCT - col2 * + 7 + col1 / - 23 AS col1 FROM tab0 AS cor0
----
-11
-234
-577

query I rowsort
SELECT cor0.col1 * + 78 FROM tab0, tab2 AS cor0
----
9 values hashing to 9b8ec4481b97e6289508f57f95c7adf8

query I rowsort
SELECT + ( ( cor0.col2 ) ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 + cor0.col2 * - col0 + CAST ( - col2 AS REAL ) FROM tab2 AS cor0
----
-2080
-243
-3078

query I rowsort
SELECT + 17 FROM tab1, tab1 cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

onlyif mysql # use DIV operator for integer division
query I rowsort label-4256
SELECT - cor0.col0 DIV + col2 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4256
SELECT - cor0.col0 / + col2 AS col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - ( + col0 ) + - col2 AS col2 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT ALL + 24 * 88 + + cor0.col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 7b3954f57cf292697e26216f9f0626e6

query I rowsort
SELECT - + col0 * + col2 * ( + col1 ) AS col2 FROM tab1 cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4260
SELECT DISTINCT col2 + - tab0.col0 DIV + 64 FROM tab0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-4260
SELECT DISTINCT col2 + - tab0.col0 / + 64 FROM tab0
----
1
33
81

query I rowsort
SELECT ALL 66 * + tab1.col2 * 52 + + col2 FROM tab1
----
185382
195681
329568

query I rowsort
SELECT + tab2.col1 AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col2 * + col1 * 44 + col2 FROM tab0 AS cor0
----
124905
328410
4269

query I rowsort
SELECT - + col0 + - ( col0 + - col1 ) AS col0 FROM tab0 AS cor0
----
-87
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4265
SELECT + col0 DIV 90 + - ( - col1 ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4265
SELECT + col0 / 90 + - ( - col1 ) FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT 95 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT col1 + col2 * col0 + + tab1.col1 AS col0 FROM tab1
----
214
3668
7706

onlyif mysql # use DIV operator for integer division
query I rowsort label-4269
SELECT ALL - col2 + + col0 DIV + col2 FROM tab1
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-4269
SELECT ALL - col2 + + col0 / + col2 FROM tab1
----
-54
-56
-96

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2, tab2 cor3
----
3645 values hashing to 42d854e4c33cb5afd5528228bff9250d

query I rowsort
SELECT DISTINCT + 76 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
76

query I rowsort
SELECT - col2 + 48 + ( tab1.col2 ) * ( - col2 ) FROM tab1
----
-2922
-3258
-9264

query I rowsort
SELECT + col2 * cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT - + col1 * - col2 * + cor0.col0 + col2 FROM tab2 AS cor0
----
119678
51072
5886

query I rowsort
SELECT DISTINCT - col2 - 75 FROM tab0 AS cor0
----
-108
-157
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4276
SELECT + col0 DIV - col2 + col2 * - col2 AS col1 FROM tab1 AS cor0
----
-2916
-3250
-9216

skipif mysql # not compatible
query I rowsort label-4276
SELECT + col0 / - col2 + col2 * - col2 AS col1 FROM tab1 AS cor0
----
-2916
-3250
-9216

query I rowsort
SELECT - col1 + + ( col0 + - col1 ) AS col2 FROM tab0 AS cor0
----
-148
-159
-93

query I rowsort
SELECT col0 * col2 * 86 - - col2 FROM tab1 AS cor0
----
13986
313785
660576

onlyif mysql # use DIV operator for integer division
query I rowsort label-4279
SELECT ALL - col0 + - 92 * 8 DIV + col1 AS col0 FROM tab2 AS cor0
----
-122
-30
-90

skipif mysql # not compatible
query I rowsort label-4279
SELECT ALL - col0 + - 92 * 8 / + col1 AS col0 FROM tab2 AS cor0
----
-122
-30
-90

query I rowsort
SELECT ALL - col2 + - col0 * - cor0.col0 - - col1 AS col2 FROM tab1 AS cor0
----
-19
4049
6317

query I rowsort
SELECT ALL 1 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4282
SELECT - col0 DIV + 40 FROM tab2
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4282
SELECT - col0 / + 40 FROM tab2
----
-1
-1
0

query I rowsort
SELECT + tab0.col0 * 5 AS col1 FROM tab0
----
120
175
445

query I rowsort
SELECT ALL + 21 * 30 FROM tab2 cor0
----
630
630
630

query I rowsort
SELECT DISTINCT - col0 + + col2 * - col0 * + col1 AS col1 FROM tab1 AS cor0
----
-36544
-4215
-99920

query I rowsort
SELECT + col2 * col1 + + 76 AS col0 FROM tab0 AS cor0
----
173
2914
7538

query I rowsort
SELECT DISTINCT - 15 AS col2 FROM tab2, tab1 cor0
----
-15

onlyif mysql # use DIV operator for integer division
query I rowsort label-4288
SELECT - col2 DIV - col1 + 35 + + tab0.col2 AS col0 FROM tab0
----
117
36
68

skipif mysql # not compatible
query I rowsort label-4288
SELECT - col2 / - col1 + 35 + + tab0.col2 AS col0 FROM tab0
----
117
36
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-4289
SELECT col0 DIV + 45 - 76 AS col0 FROM tab1
----
-75
-75
-76

skipif mysql # not compatible
query I rowsort label-4289
SELECT col0 / + 45 - 76 AS col0 FROM tab1
----
-75
-75
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4290
SELECT - col1 * - col0 * col2 + CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4290
SELECT - col1 * - col0 * col2 + CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * col2 * - col1 AS col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT col1 * col0 + - col2 * - col2 AS col0 FROM tab2
----
2787
5278
946

query I rowsort
SELECT - 32 - col1 AS col2 FROM tab2 AS cor0
----
-49
-63
-91

query I rowsort
SELECT DISTINCT - + ( - col1 ) AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - ( col1 ) + col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - - col2 * ( + col2 ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + ( ( col1 ) ) * - col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4298
SELECT CAST( + col1 AS SIGNED ) - col2 AS col2 FROM tab2 AS cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-4298
SELECT CAST ( + col1 AS INTEGER ) - col2 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - + 55 * col2 FROM tab1 AS cor0
----
-2970
-3135
-5280

query I rowsort
SELECT - - col2 + ( col1 ) AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT ( + tab2.col1 ) * tab2.col0 AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT - cor0.col0 * + col0 + - col1 FROM tab2 AS cor0
----
-6143
-6258
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col1 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + - col0 * + 14 FROM tab0 AS cor0
----
-1246
-336
-490

query I rowsort
SELECT ALL 8 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 43 col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
43

query I rowsort
SELECT - cor0.col2 + 23 * + col0 FROM tab0 AS cor0
----
1965
519
804

query I rowsort
SELECT ALL cor0.col0 * + cor0.col1 * cor0.col1 + cor0.col1 AS col2 FROM tab1 AS cor0
----
13533
2054
6410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + cor0.col0 + col0 col1 FROM tab1 AS cor0
----
12
4160
6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-4310
SELECT DISTINCT - col0 * - col1 + - col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
1344
218
4603

skipif mysql # not compatible
query I rowsort label-4310
SELECT DISTINCT - col0 * - col1 + - col1 / - col1 AS col0 FROM tab2 AS cor0
----
1344
218
4603

query I rowsort
SELECT 0 * + col2 - 20 AS col0 FROM tab1 AS cor0
----
-20
-20
-20

query I rowsort
SELECT ALL - 53 * col0 AS col2 FROM tab1 cor0
----
-159
-3392
-4240

query I rowsort
SELECT DISTINCT + 53 - + col1 FROM tab1 AS cor0
----
27
40
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col1 ) * 11 * col1 + col2 col1 FROM tab2 AS cor0
----
-10544
-3141
-38265

skipif mysql # not compatible
query I rowsort
SELECT + 82 + - ( + col0 ) / CAST ( col0 + + col0 AS REAL ) FROM tab2
----
81
81
81

query I rowsort
SELECT + 94 + col0 * + 18 FROM tab2 AS cor0
----
1498
1516
220

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4317
SELECT ALL - col0 * - col2 + CAST( - col1 AS SIGNED ) * - tab2.col2 - 39 FROM tab2
----
3523
3609
987

skipif mysql # not compatible
query I rowsort label-4317
SELECT ALL - col0 * - col2 + CAST ( - col1 AS INTEGER ) * - tab2.col2 - 39 FROM tab2
----
3523
3609
987

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 + ( + col0 ) col1 FROM tab1 cor0
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - col0 * - col1 col2 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + ( + col2 ) * col1 + 96 col2 FROM tab1
----
119904
32586
75912

query I rowsort
SELECT DISTINCT + - 9 FROM tab1 cor0
----
-9

query I rowsort
SELECT 26 * ( col0 ) AS col2 FROM tab0 cor0
----
2314
624
910

onlyif mysql # use DIV operator for integer division
query I rowsort label-4323
SELECT cor1.col0 DIV - ( - 51 ) AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-4323
SELECT cor1.col0 / - ( - 51 ) AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

query I rowsort
SELECT col0 * + col2 + - ( - cor0.col2 ) * - 42 * + ( cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-1435
-299218
-32472

query I rowsort
SELECT ALL - 36 AS col2 FROM tab1 cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 3bcd07d22b62d2042b499253b1c13d9e

query I rowsort
SELECT - col1 * 69 * + col1 + - ( 18 ) FROM tab2
----
-19959
-240207
-66327

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 32 + - col2 + col1 * 50 col2 FROM tab0 AS cor0
----
4235
4436
4817

query I rowsort
SELECT - col2 * - 57 AS col0 FROM tab1 AS cor0
----
3078
3249
5472

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4329
SELECT ALL - cor0.col2 * cor0.col2 + - CAST( NULL AS SIGNED ) + 58 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4329
SELECT ALL - cor0.col2 * cor0.col2 + - CAST ( NULL AS INTEGER ) + 58 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL 18 - col0 FROM tab1 AS cor0
----
-46
-62
15

query I rowsort
SELECT ALL 67 + col0 * + col1 AS col1 FROM tab2 AS cor0
----
1410
284
4669

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4332
SELECT - + CAST( NULL AS SIGNED ) / - 21 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4332
SELECT - + CAST ( NULL AS INTEGER ) / - 21 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( col2 ) + + col2 * cor0.col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - col1 * + ( col1 + - col0 * + ( - col1 ) ) FROM tab1 AS cor0
----
-13689
-2704
-6500

query I rowsort
SELECT ALL - ( cor0.col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
-178
-48
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4336
SELECT + + cor0.col2 * 75 DIV col0 AS col0 FROM tab2 AS cor0
----
25
289
36

skipif mysql # not compatible
query I rowsort label-4336
SELECT + + cor0.col2 * 75 / col0 AS col0 FROM tab2 AS cor0
----
25
289
36

query I rowsort
SELECT DISTINCT + 42 * col2 + col0 AS col2 FROM tab0 AS cor0
----
1410
3533
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4338
SELECT CAST( - 91 * col1 AS SIGNED ) FROM tab0
----
-7826
-8281
-8827

skipif mysql # not compatible
query I rowsort label-4338
SELECT CAST ( - 91 * col1 AS INTEGER ) FROM tab0
----
-7826
-8281
-8827

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4339
SELECT DISTINCT + + CAST( col2 AS SIGNED ) * col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-4339
SELECT DISTINCT + + CAST ( col2 AS INTEGER ) * col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4340
SELECT ALL + + ( col1 ) + + col0 DIV + col0 - col2 * col0 col1 FROM tab1 AS cor0
----
-135
-3637
-7666

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4340
SELECT ALL + + ( col1 ) + + col0 / + col0 - col2 * col0 col1 FROM tab1 AS cor0
----
-135
-3637
-7666

query I rowsort
SELECT ALL 86 + cor0.col0 + cor0.col2 FROM tab2 AS cor0
----
120
190
203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4342
SELECT ALL - + col0 * cor0.col1 - CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif mysql # not compatible
query I rowsort label-4342
SELECT ALL - + col0 * cor0.col1 - CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT + col1 * col0 * + 13 FROM tab0 AS cor0
----
105287
26832
44135

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0, tab0 cor1, tab0 cor2
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

query I rowsort
SELECT + - cor0.col2 + - col0 * col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT + col1 + 91 * + col1 + cor0.col2 FROM tab1 AS cor0
----
1292
2446
977

onlyif mysql # use DIV operator for integer division
query I rowsort label-4347
SELECT col2 DIV - 55 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4347
SELECT col2 / - 55 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + tab2.col2 + tab2.col2 AS col0 FROM tab2
----
52
54
76

query I rowsort
SELECT + + col1 * 70 AS col2 FROM tab2 AS cor0
----
1190
2170
4130

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * col2 + - cor0.col0 col2 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4351
SELECT col0 + CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-4351
SELECT col0 + CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col0 * - col2 col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ( cor0.col2 ) + + col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL - 93 + col0 * - col2 * + 91 AS col0 FROM tab0 AS cor0
----
-3278
-664211
-72165

query I rowsort
SELECT ALL - 93 * + 75 FROM tab0 AS cor0
----
-6975
-6975
-6975

query I rowsort
SELECT + + 43 * col2 AS col1 FROM tab1 AS cor0
----
2322
2451
4128

query I rowsort
SELECT ALL - 99 FROM tab0 cor0
----
-99
-99
-99

query I rowsort
SELECT + 76 * - col1 FROM tab1 AS cor0
----
-1976
-760
-988

query I rowsort
SELECT ALL + 46 * + ( cor0.col2 ) AS col1 FROM tab0 AS cor0
----
1518
3772
46

query I rowsort
SELECT 97 + 65 * + col1 FROM tab2 AS cor0
----
1202
2112
3932

query I rowsort
SELECT col2 * - 11 FROM tab0 AS cor0
----
-11
-363
-902

onlyif mysql # use DIV operator for integer division
query I rowsort label-4362
SELECT ALL col0 * col0 + - col2 * - tab1.col2 + - col2 DIV 70 FROM tab1
----
15615
2925
7345

skipif mysql # not compatible
query I rowsort label-4362
SELECT ALL col0 * col0 + - col2 * - tab1.col2 + - col2 / 70 FROM tab1
----
15615
2925
7345

query I rowsort
SELECT DISTINCT - 14 + + tab2.col2 AS col0 FROM tab2, tab0 AS cor0
----
12
13
24

query I rowsort
SELECT tab1.col0 * tab1.col1 + + 87 AS col1 FROM tab1
----
1127
165
727

query I rowsort
SELECT DISTINCT col2 * - col1 + + 92 AS col0 FROM tab2
----
-1442
-554
-745

query I rowsort
SELECT - tab1.col0 * + col2 - ( col0 ) AS col2 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT ALL + 98 AS col1 FROM tab2 AS cor0
----
98
98
98

query I rowsort
SELECT col0 + - col1 - + cor0.col2 FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT DISTINCT col0 * col0 + 92 * 46 FROM tab1 AS cor0
----
10632
4241
8328

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4370
SELECT DISTINCT - ( col1 ) * CAST( col0 AS SIGNED ) AS col0 FROM tab0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-4370
SELECT DISTINCT - ( col1 ) * CAST ( col0 AS INTEGER ) AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT + 47 + col2 FROM tab1 AS cor0
----
101
104
143

query I rowsort
SELECT - col1 + col0 * - col0 + col1 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-4373
SELECT + + col0 DIV + ( ( + col0 ) ) AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4373
SELECT + + col0 / + ( ( + col0 ) ) AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - + col2 * + ( col2 * - col0 ) AS col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT col1 + + 16 + col1 FROM tab2 AS cor0
----
134
50
78

query I rowsort
SELECT DISTINCT - col1 * col0 + col1 * col2 + + col0 AS col0 FROM tab2
----
-2990
-618
627

query I rowsort
SELECT + + ( - col2 ) AS col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + 63 * col1 AS col2 FROM tab2 cor0
----
1071
1953
3717

query I rowsort
SELECT - ( 87 ) * col0 FROM tab0 AS cor0
----
-2088
-3045
-7743

query I rowsort
SELECT ALL - cor0.col1 * 49 * col1 AS col2 FROM tab0 AS cor0
----
-362404
-405769
-461041

query I rowsort
SELECT ALL + - col0 + - col2 * col1 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT ( 74 ) + col1 FROM tab2 AS cor0
----
105
133
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + col2 col1 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4384
SELECT col1 + - CAST( NULL AS DECIMAL ) * col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4384
SELECT col1 + - CAST ( NULL AS REAL ) * col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4385
SELECT col0 + col2 DIV + ( tab1.col1 + ( - col2 ) * + col2 ) AS col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-4385
SELECT col0 + col2 / + ( tab1.col1 + ( - col2 ) * + col2 ) AS col0 FROM tab1
----
3
64
80

query I rowsort
SELECT col2 + + 58 FROM tab0 AS cor0
----
140
59
91

query I rowsort
SELECT + 44 * - col1 AS col0 FROM tab1 AS cor0
----
-1144
-440
-572

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) + + col1 * - col1 col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL - col0 + + cor0.col2 AS col1 FROM tab1 cor0
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( + col1 ) col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT col1 * 53 FROM tab1
----
1378
530
689

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4392
SELECT ALL - + ( col1 ) * - CAST( NULL AS SIGNED ) + cor0.col1 + col1 * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4392
SELECT ALL - + ( col1 ) * - CAST ( NULL AS INTEGER ) + cor0.col1 + col1 * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * - col1 - ( col1 + col2 ) AS col0 FROM tab2 AS cor0
----
1288
159
4517

query I rowsort
SELECT DISTINCT + - col0 - + col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL col2 * + col0 + ( + 22 * - col2 ) AS col2 FROM tab1 AS cor0
----
-1026
2394
5568

onlyif mysql # use DIV operator for integer division
query I rowsort label-4396
SELECT ALL - col0 DIV 33 AS col0 FROM tab2
----
-2
-2
0

skipif mysql # not compatible
query I rowsort label-4396
SELECT ALL - col0 / 33 AS col0 FROM tab2
----
-2
-2
0

query I rowsort
SELECT ALL - tab2.col0 AS col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT + 99 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT ALL cor0.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT DISTINCT - 33 AS col0 FROM tab1, tab1 AS cor0
----
-33

query I rowsort
SELECT DISTINCT 75 * 35 AS col0 FROM tab0, tab0 AS cor0
----
2625

query I rowsort
SELECT cor0.col0 + + col0 * col0 AS col2 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT 98 FROM tab0, tab2 AS cor0
----
98

query I rowsort
SELECT - + 47 * 14 AS col0 FROM tab1 AS cor0
----
-658
-658
-658

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 62 + - col1 col1 FROM tab2 AS cor0
----
1037
1891
3599

query I rowsort
SELECT ALL col1 * ( ( - col2 ) ) AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4407
SELECT DISTINCT col0 * cor0.col0 DIV - col2 + - col1 * col0 * + col0 AS col2 FROM tab1 AS cor0
----
-234
-41031
-83266

skipif mysql # not compatible
query I rowsort label-4407
SELECT DISTINCT col0 * cor0.col0 / - col2 + - col1 * col0 * + col0 AS col2 FROM tab1 AS cor0
----
-234
-41031
-83266

query I rowsort
SELECT col2 * 94 FROM tab1 cor0
----
5076
5358
9024

query I rowsort
SELECT DISTINCT - + col2 * + 3 + 30 * + col1 FROM tab1 AS cor0
----
102
129
618

query I rowsort
SELECT DISTINCT col1 + 94 * + col1 AS col1 FROM tab1 cor0
----
1235
2470
950

query I rowsort
SELECT ALL + cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - - col1 * - ( + col0 ) + col2 * + col0 FROM tab2 AS cor0
----
-2574
-28
1659

query I rowsort
SELECT DISTINCT - col2 + ( col1 ) * - col1 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT ALL + col2 + + 31 FROM tab1 AS cor0
----
127
85
88

query I rowsort
SELECT ALL col0 + 44 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-129
-2752
-3440

query I rowsort
SELECT DISTINCT + col2 * col0 + col1 * + col2 - - cor0.col0 * + col0 FROM tab0 AS cor0
----
1357
22681
4206

query I rowsort
SELECT ALL col1 * + col0 + - col1 * + col2 * - ( - col1 ) AS col2 FROM tab2 AS cor0
----
-25730
-85904
-9639

query I rowsort
SELECT ALL - col0 * 19 FROM tab1 AS cor0
----
-1216
-1520
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * cor0.col1 col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - 61 * 78 * - col1 FROM tab2 cor0
----
147498
280722
80886

query I rowsort
SELECT ALL + col0 * - 82 AS col2 FROM tab2 AS cor0
----
-574
-6396
-6478

query I rowsort
SELECT - 26 * + 2 FROM tab0 AS cor0
----
-52
-52
-52

query I rowsort
SELECT DISTINCT col0 * + col1 + + col2 + cor0.col0 FROM tab1 AS cor0
----
1216
135
761

query I rowsort
SELECT + col0 + col1 * 7 FROM tab0 AS cor0
----
626
714
726

query I rowsort
SELECT + 4 * + col2 * - 50 AS col2 FROM tab1 AS cor0
----
-10800
-11400
-19200

query I rowsort
SELECT DISTINCT - col0 * + col0 + + cor0.col2 FROM tab1 AS cor0
----
-4039
-6304
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4427
SELECT col0 DIV - col0 + CAST( - 13 + col2 AS SIGNED ) * - 88 AS col2 FROM tab0 AS cor0
----
-1761
-6073
1055

skipif mysql # not compatible
query I rowsort label-4427
SELECT col0 / - col0 + CAST ( - 13 + col2 AS INTEGER ) * - 88 AS col2 FROM tab0 AS cor0
----
-1761
-6073
1055

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab2, tab2 AS cor1
----
3645 values hashing to 1a92b418ae3c05ba566f88a890a407ae

query I rowsort
SELECT ALL + col2 + + col2 * + col0 * + col2 FROM tab1
----
207993
737376
8802

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - col1 col2 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT ALL + - 63 + 1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT - col2 + - col1 * col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT - 54 * 18 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 091970b45910c8c1093aec64dd3aa57a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + 4 + + col2 col2 FROM tab1
----
313
416
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4435
SELECT + - cor0.col0 + + CAST( NULL AS SIGNED ) * + 93 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4435
SELECT + - cor0.col0 + + CAST ( NULL AS INTEGER ) * + 93 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col0 + + 9 FROM tab2 AS cor0
----
-69
-70
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4437
SELECT + cor2.col0 + - CAST( 9 AS SIGNED ) AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to d1cdae9c054389ade09a7020dfd0b955

skipif mysql # not compatible
query I rowsort label-4437
SELECT + cor2.col0 + - CAST ( 9 AS INTEGER ) AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to d1cdae9c054389ade09a7020dfd0b955

query I rowsort
SELECT DISTINCT + - cor0.col1 + ( - 98 ) FROM tab0 AS cor0
----
-184
-189
-195

query I rowsort
SELECT ( - 7 * + col2 + + col2 ) AS col1 FROM tab0
----
-198
-492
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4440
SELECT 6 DIV col2 AS col1 FROM tab0
----
0
0
6

skipif mysql # not compatible
query I rowsort label-4440
SELECT 6 / col2 AS col1 FROM tab0
----
0
0
6

query I rowsort
SELECT + ( + 74 ) * + col2 FROM tab1 AS cor0
----
3996
4218
7104

onlyif mysql # use DIV operator for integer division
query I rowsort label-4442
SELECT DISTINCT 79 DIV col0 + col1 * - col2 FROM tab2 AS cor0
----
-1533
-645
-826

skipif mysql # not compatible
query I rowsort label-4442
SELECT DISTINCT 79 / col0 + col1 * - col2 FROM tab2 AS cor0
----
-1533
-645
-826

query I rowsort
SELECT - col0 - 7 * + col1 AS col1 FROM tab1 AS cor0
----
-134
-171
-185

query I rowsort
SELECT DISTINCT 92 AS col2 FROM tab1, tab1 cor0
----
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4445
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col1 + col0 * 63 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4445
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col1 + col0 * 63 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL cor0.col2 + - col0 * col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - 29 + - col1 AS col2 FROM tab0 AS cor0
----
-115
-120
-126

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 col2 FROM tab2 AS cor0
----
25
25
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4449
SELECT DISTINCT ( col2 ) * - ( - col1 * - col1 ) - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4449
SELECT DISTINCT ( col2 ) * - ( - col1 * - col1 ) - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 49 * col1 - ( col0 + - col1 ) AS col2 FROM tab0 AS cor0
----
4276
4461
4815

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4451
SELECT ALL - ( col1 ) * ( 35 * col1 ) + CAST( + col2 * - col1 AS SIGNED ) FROM tab0 AS cor0
----
-261698
-297297
-329412

skipif mysql # not compatible
query I rowsort label-4451
SELECT ALL - ( col1 ) * ( 35 * col1 ) + CAST ( + col2 * - col1 AS INTEGER ) FROM tab0 AS cor0
----
-261698
-297297
-329412

query I rowsort
SELECT - tab0.col1 * + ( + tab0.col0 ) AS col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - 66 + col0 + col1 * - ( + 93 ) FROM tab1
----
-1195
-2481
-932

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 37 * ( col0 ) * col2 - col2 col2 FROM tab2
----
111036
6966
75010

query I rowsort
SELECT ALL + cor0.col2 * - col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT - col1 * - col1 - + 86 * - col2 FROM tab2 AS cor0
----
3283
3557
5717

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 cor1, tab2, tab2 AS cor2
----
3645 values hashing to 8e89a67df0eeeac4bb0eedb403f6bb3e

query I rowsort
SELECT ALL 14 FROM tab1, tab1 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT - 4 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT col1 * 19 AS col2 FROM tab0 AS cor0
----
1634
1729
1843

query I rowsort
SELECT DISTINCT + - col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT col2 * + 23 AS col2 FROM tab2
----
598
621
874

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col0 AS REAL ) - col2 AS col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT DISTINCT - 28 * - col2 * + col1 - tab0.col0 * col1 FROM tab0
----
-679
200837
77400

onlyif mysql # use DIV operator for integer division
query I rowsort label-4465
SELECT + - 60 DIV + col1 - - col1 * col0 AS col0 FROM tab1 AS cor0
----
1036
634
76

skipif mysql # not compatible
query I rowsort label-4465
SELECT + - 60 / + col1 - - col1 * col0 AS col0 FROM tab1 AS cor0
----
1036
634
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4466
SELECT CAST( 78 AS SIGNED ) * + col1 AS col1 FROM tab1
----
1014
2028
780

skipif mysql # not compatible
query I rowsort label-4466
SELECT CAST ( 78 AS INTEGER ) * + col1 AS col1 FROM tab1
----
1014
2028
780

query I rowsort
SELECT - col2 * col2 - col1 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-2240
-3149
-9047

query I rowsort
SELECT col2 * + 98 - - col1 FROM tab0 AS cor0
----
195
3320
8127

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col1 * + col1 col0 FROM tab0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-4470
SELECT DISTINCT - col1 DIV col0 col2 FROM tab1
----
-8
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4470
SELECT DISTINCT - col1 / col0 col2 FROM tab1
----
-8
0

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 cor0, tab2 cor1, tab0 cor2
----
972 values hashing to 58757c5bbbd4217c03cf2ac0b6126e55

query I rowsort
SELECT cor0.col0 * 47 AS col2 FROM tab1 AS cor0
----
141
3008
3760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col2 col1 FROM tab0 cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * + cor0.col2 col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT - - cor0.col0 * col1 + - col2 * col1 AS col0 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT DISTINCT + - cor0.col0 + + col0 * col2 AS col1 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL + col0 * + cor0.col2 + col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT ALL - + col0 + - col1 + col2 AS col0 FROM tab2 AS cor0
----
-11
-111
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-4479
SELECT + 98 + - col2 DIV col2 AS col2 FROM tab0 AS cor0
----
97
97
97

skipif mysql # not compatible
query I rowsort label-4479
SELECT + 98 + - col2 / col2 AS col2 FROM tab0 AS cor0
----
97
97
97

query I rowsort
SELECT - col0 * col1 + - col1 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4481
SELECT - - col2 + + col0 DIV - col2 FROM tab0 AS cor0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-4481
SELECT - - col2 + + col0 / - col2 FROM tab0 AS cor0
----
-34
33
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4482
SELECT ALL + CAST( - col0 AS SIGNED ) * col1 * - col2 AS col1 FROM tab2
----
119652
51034
5859

skipif mysql # not compatible
query I rowsort label-4482
SELECT ALL + CAST ( - col0 AS INTEGER ) * col1 * - col2 AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT + col2 * + col2 + - col2 AS col1 FROM tab2 AS cor0
----
1406
650
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-4484
SELECT - tab2.col1 DIV - col0 AS col1 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4484
SELECT - tab2.col1 / - col0 AS col1 FROM tab2
----
0
0
4

query I rowsort
SELECT ALL - col1 + + col1 * col1 * col2 FROM tab2 AS cor0
----
10965
25916
90447

onlyif mysql # use DIV operator for integer division
query I rowsort label-4486
SELECT DISTINCT - col1 DIV tab0.col0 AS col0 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-4486
SELECT DISTINCT - col1 / tab0.col0 AS col0 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT - + 80 + col2 AS col1 FROM tab1 AS cor0
----
-23
-26
16

query I rowsort
SELECT - 2 * - col1 * + col0 + - col1 + - col2 FROM tab2
----
2631
376
9119

query I rowsort
SELECT ALL + 19 * 40 + + tab1.col2 FROM tab1
----
814
817
856

query I rowsort
SELECT ALL 3 * col1 + tab1.col1 AS col2 FROM tab1
----
104
40
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4491
SELECT + + 24 DIV col0 AS col2 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-4491
SELECT + + 24 / col0 AS col2 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT DISTINCT + 75 + col2 FROM tab0 AS cor0
----
108
157
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4493
SELECT DISTINCT - CAST( + 46 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-46

skipif mysql # not compatible
query I rowsort label-4493
SELECT DISTINCT - CAST ( + 46 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4494
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 21 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-4494
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 21 FROM tab2
----
NULL

query I rowsort
SELECT + 91 + + col1 + col1 * col0 * col2 AS col0 FROM tab1
----
36581
4329
99944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4496
SELECT CAST( ( col1 ) AS SIGNED ) AS col2 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4496
SELECT CAST ( ( col1 ) AS INTEGER ) AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL - 72 + col1 AS col2 FROM tab0 AS cor0
----
14
19
25

query I rowsort
SELECT ALL col1 + - col2 * 33 FROM tab1 AS cor0
----
-1756
-1871
-3155

query I rowsort
SELECT DISTINCT - + 78 * col0 - col0 FROM tab1 cor0
----
-237
-5056
-6320

query I rowsort
SELECT DISTINCT - 77 + + cor0.col2 FROM tab2 AS cor0
----
-39
-50
-51

query I rowsort
SELECT ALL 67 - + col1 * 13 * col0 FROM tab2 AS cor0
----
-17392
-2754
-59759

query I rowsort
SELECT DISTINCT - + col1 * col2 - - col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + + col0 * - col1 * cor0.col1 FROM tab1 cor0
----
-13520
-2028
-6400

query I rowsort
SELECT ALL col1 * + col1 + col0 * col1 FROM tab0 AS cor0
----
12804
16380
9460

onlyif mysql # use DIV operator for integer division
query I rowsort label-4505
SELECT DISTINCT 64 + - cor0.col0 DIV cor0.col0 FROM tab0 AS cor0
----
63

skipif mysql # not compatible
query I rowsort label-4505
SELECT DISTINCT 64 + - cor0.col0 / cor0.col0 FROM tab0 AS cor0
----
63

query I rowsort
SELECT DISTINCT - + ( - col2 ) + col1 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) * - 89 * col1 col2 FROM tab0 AS cor0
----
-252582
-664118
-8633

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4508
SELECT DISTINCT - 18 * - col1 + CAST( NULL AS DECIMAL ) AS col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4508
SELECT DISTINCT - 18 * - col1 + CAST ( NULL AS REAL ) AS col0 FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4509
SELECT ALL - col1 DIV + col1 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4509
SELECT ALL - col1 / + col1 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - - ( col2 ) - + 73 FROM tab2 AS cor0
----
-35
-46
-47

query I rowsort
SELECT DISTINCT - + cor0.col1 + + col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col1 * + col2 * - ( ( - col2 ) ) + + col1 AS col0 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT + + col1 * + col2 + + col1 + col1 FROM tab1 AS cor0
----
1274
1456
590

query I rowsort
SELECT - col2 * - col0 - + cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT col1 + col0 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT ALL - col0 + cor0.col1 * - col1 * - col1 AS col1 FROM tab1 AS cor0
----
17573
2117
936

query I rowsort
SELECT + col0 * - ( ( col2 ) ) - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-4518
SELECT ALL - col0 + col1 DIV col0 AS col1 FROM tab0 cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-4518
SELECT ALL - col0 + col1 / col0 AS col1 FROM tab0 cor0
----
-21
-33
-88

query I rowsort
SELECT DISTINCT + - col2 + col0 * col0 AS col0 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT DISTINCT col0 + ( + col2 ) * + col1 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - col0 + + ( - col2 * - col0 ) AS col1 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT + + col2 * - col1 + 13 + + cor0.col0 FROM tab1 AS cor0
----
-1155
-1388
-493

query I rowsort
SELECT DISTINCT col2 + 45 * + col1 FROM tab0 AS cor0
----
3903
4177
4366

query I rowsort
SELECT ALL col2 + - ( col1 ) FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT - - col0 * col0 + + col1 + col2 FROM tab0 AS cor0
----
1323
695
8094

query I rowsort
SELECT DISTINCT col1 * + 10 AS col2 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT DISTINCT - col2 + 9 AS col0 FROM tab0 AS cor0
----
-24
-73
8

query I rowsort
SELECT ALL + 92 FROM tab0, tab1 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT ALL + 56 * + col2 + + col1 FROM tab0 AS cor0
----
153
1934
4683

query I rowsort
SELECT - 83 + cor0.col0 FROM tab1 cor0
----
-19
-3
-80

query I rowsort
SELECT - - col1 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - tab2.col1 * + tab2.col2 * col2 FROM tab2
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-4533
SELECT col2 + 39 DIV + col2 AS col0 FROM tab0 AS cor0
----
34
40
82

skipif mysql # not compatible
query I rowsort label-4533
SELECT col2 + 39 / + col2 AS col0 FROM tab0 AS cor0
----
34
40
82

query I rowsort
SELECT ALL - 15 + - col1 FROM tab0 AS cor0
----
-101
-106
-112

query I rowsort
SELECT ALL + 14 + + ( - col0 ) FROM tab0 AS cor0
----
-10
-21
-75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4536
SELECT - CAST( NULL AS DECIMAL ) + - col0 / cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4536
SELECT - CAST ( NULL AS REAL ) + - col0 / cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4537
SELECT + - CAST( 20 AS SIGNED ) * col0 + col1 + + col0 AS col0 FROM tab0 AS cor0
----
-1600
-370
-568

skipif mysql # not compatible
query I rowsort label-4537
SELECT + - CAST ( 20 AS INTEGER ) * col0 + col1 + + col0 AS col0 FROM tab0 AS cor0
----
-1600
-370
-568

query I rowsort
SELECT DISTINCT + col0 + - col0 + col0 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4539
SELECT DISTINCT CAST( - 32 AS SIGNED ) DIV - col0 FROM tab0 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-4539
SELECT DISTINCT CAST ( - 32 AS INTEGER ) / - col0 FROM tab0 cor0
----
0
1

query I rowsort
SELECT ALL + ( - col0 ) + col0 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4541
SELECT DISTINCT + col2 DIV + cor0.col1 + + col2 FROM tab1 AS cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-4541
SELECT DISTINCT + col2 / + cor0.col1 + + col2 FROM tab1 AS cor0
----
103
56
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4542
SELECT - col1 * + 93 + + col0 - + col1 DIV col1 FROM tab2
----
-1503
-2877
-5410

skipif mysql # not compatible
query I rowsort label-4542
SELECT - col1 * + 93 + + col0 - + col1 / col1 FROM tab2
----
-1503
-2877
-5410

query I rowsort
SELECT + col0 + col0 + - tab2.col2 AS col1 FROM tab2
----
-13
120
130

query I rowsort
SELECT + cor0.col2 * 21 FROM tab0, tab2 AS cor0
----
9 values hashing to d72e70f7bd7bd6904a82beaee2e45aad

query I rowsort
SELECT DISTINCT col2 + + col2 * + 93 AS col0 FROM tab1
----
5076
5358
9024

query I rowsort
SELECT + 27 * col0 + col1 * 75 + col1 AS col0 FROM tab2 cor0
----
2545
3425
6590

query I rowsort
SELECT col1 * col0 + col1 * cor0.col2 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT ALL - 28 AS col1 FROM tab0
----
-28
-28
-28

query I rowsort
SELECT - col1 + ( - 12 ) FROM tab2 AS cor0
----
-29
-43
-71

query I rowsort
SELECT DISTINCT + col0 - col1 * - 97 AS col0 FROM tab1 AS cor0
----
1034
1341
2525

query I rowsort
SELECT DISTINCT col0 * + col0 + + col2 * + col2 + - ( + col2 ) FROM tab2
----
6734
751
7647

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4552
SELECT ALL col2 + CAST( - 22 AS SIGNED ) FROM tab0
----
-21
11
60

skipif mysql # not compatible
query I rowsort label-4552
SELECT ALL col2 + CAST ( - 22 AS INTEGER ) FROM tab0
----
-21
11
60

query I rowsort
SELECT DISTINCT col2 * + col1 + col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT ALL - col2 * + ( - 27 ) - - col0 AS col1 FROM tab2 AS cor0
----
1105
736
780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4555
SELECT ALL col1 - CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4555
SELECT ALL col1 - CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4556
SELECT - tab2.col1 DIV - ( 9 ) AS col0 FROM tab2
----
1
3
6

skipif mysql # not compatible
query I rowsort label-4556
SELECT - tab2.col1 / - ( 9 ) AS col0 FROM tab2
----
1
3
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4557
SELECT ALL + col0 * col2 + col1 DIV col0 AS col1 FROM tab1 cor0
----
170
3648
7680

skipif mysql # not compatible
query I rowsort label-4557
SELECT ALL + col0 * col2 + col1 / col0 AS col1 FROM tab1 cor0
----
170
3648
7680

query I rowsort
SELECT DISTINCT - - col0 * col0 + col2 + + col0 AS col1 FROM tab0 AS cor0
----
1261
633
8092

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 49 col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4560
SELECT + + CAST( NULL AS SIGNED ) * - 46 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4560
SELECT + + CAST ( NULL AS INTEGER ) * - 46 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ( 96 ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT DISTINCT - 72 FROM tab0, tab0 AS cor0, tab2 cor1
----
-72

query I rowsort
SELECT ALL 24 * col1 AS col0 FROM tab2
----
1416
408
744

query I rowsort
SELECT - 47 * - 91 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 3daf1cb98bb501d0e1a7cd546f62d74e

query I rowsort
SELECT + 16 + - tab2.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to a5667734ad2c2225325adc7144c36a78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 93 * + col1 * col1 - 33 col1 FROM tab1 AS cor0
----
15684
62835
9267

query I rowsort
SELECT ALL ( + col0 ) AS col0 FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4568
SELECT DISTINCT - + ( + col2 ) + col1 * + col2 + + col2 DIV 60 AS col2 FROM tab1 AS cor0
----
1153
1350
513

skipif mysql # not compatible
query I rowsort label-4568
SELECT DISTINCT - + ( + col2 ) + col1 * + col2 + + col2 / 60 AS col2 FROM tab1 AS cor0
----
1153
1350
513

query I rowsort
SELECT ALL + + col1 + col1 * + col0 * col0 FROM tab1 AS cor0
----
260
40970
83213

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4570
SELECT + - col1 * col2 + + CAST( NULL AS SIGNED ) * col2 / + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4570
SELECT + - col1 * col2 + + CAST ( NULL AS INTEGER ) * col2 / + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 41 * + col0 - + col1 FROM tab0 AS cor0
----
-1070
-1532
-3740

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4572
SELECT - 39 + + col2 * CAST( - col2 AS SIGNED ) + - col2 FROM tab1 AS cor0
----
-3009
-3345
-9351

skipif mysql # not compatible
query I rowsort label-4572
SELECT - 39 + + col2 * CAST ( - col2 AS INTEGER ) + - col2 FROM tab1 AS cor0
----
-3009
-3345
-9351

query I rowsort
SELECT 3 + - col2 FROM tab1 AS cor0
----
-51
-54
-93

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1, tab2 cor0, tab1 AS cor1
----
972 values hashing to dd771e0c15d524f62127686e9bd43f9a

query I rowsort
SELECT 45 * tab1.col1 FROM tab1
----
1170
450
585

query I rowsort
SELECT ALL col2 * + col0 + + 80 * + col0 AS col1 FROM tab2
----
749
8268
9322

query I rowsort
SELECT DISTINCT 77 FROM tab2, tab1, tab1 AS cor0
----
77

query I rowsort
SELECT + 41 * - col0 * 68 FROM tab1
----
-178432
-223040
-8364

query I rowsort
SELECT ALL + cor0.col0 * - 71 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 432b8119e85884c1f8e9e321e4d09124

query I rowsort
SELECT DISTINCT 48 AS col1 FROM tab2
----
48

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab1, tab2 cor0
----
26
27
38

query I rowsort
SELECT - col1 + 10 AS col1 FROM tab1 AS cor0
----
-16
-3
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + - 44 col0 FROM tab2 cor0
----
-13
-27
15

query I rowsort
SELECT - col1 + - 92 AS col0 FROM tab0 AS cor0
----
-178
-183
-189

query I rowsort
SELECT - + cor0.col0 * 56 * - col0 AS col1 FROM tab1 AS cor0
----
229376
358400
504

onlyif mysql # use DIV operator for integer division
query I rowsort label-4586
SELECT DISTINCT + tab2.col2 DIV - col0 FROM tab2
----
-3
0

skipif mysql # not compatible
query I rowsort label-4586
SELECT DISTINCT + tab2.col2 / - col0 FROM tab2
----
-3
0

query I rowsort
SELECT - 25 * col1 AS col1 FROM tab2
----
-1475
-425
-775

query I rowsort
SELECT + col1 * ( + 26 ) AS col1 FROM tab0 AS cor0
----
2236
2366
2522

query I rowsort
SELECT - col0 * + 3 + - 61 * col2 AS col1 FROM tab0 AS cor0
----
-166
-2085
-5269

query I rowsort
SELECT ALL + cor0.col2 * - 67 FROM tab0 AS cor0
----
-2211
-5494
-67

query I rowsort
SELECT col2 * 60 AS col0 FROM tab0 AS cor0
----
1980
4920
60

query I rowsort
SELECT + 14 * - ( col0 ) AS col1 FROM tab1 AS cor0
----
-1120
-42
-896

query I rowsort
SELECT ALL ( ( col0 ) ) AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + + ( - 64 ) AS col1 FROM tab2 AS cor0
----
-64
-64
-64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 39 * + 65 col0 FROM tab0 AS cor0
----
2535
2535
2535

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4596
SELECT - ( ( - col2 ) ) * CAST( NULL AS SIGNED ) * - col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4596
SELECT - ( ( - col2 ) ) * CAST ( NULL AS INTEGER ) * - col0 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * col1 * 16 AS col2 FROM tab2 AS cor0
----
15376
4624
55696

query I rowsort
SELECT ALL ( col1 ) - + col1 * col1 * + col1 AS col1 FROM tab2
----
-205320
-29760
-4896

query I rowsort
SELECT + 12 * - col1 * col2 FROM tab0
----
-1164
-34056
-89544

query I rowsort
SELECT - col0 * col2 + col1 * + col1 FROM tab1
----
-3548
-7511
514

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT IN ( tab2.col2 * - col1 )
----

query I rowsort
SELECT DISTINCT col2 + + col0 / col0 - col2 AS col0 FROM tab2 WHERE ( NULL ) NOT IN ( col1 )
----

query I rowsort
SELECT + col2 * - col0 * - tab0.col1 AS col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL + col1 * - col2 + + col0 FROM tab0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-4605
SELECT DISTINCT - tab1.col2 * - col1 + col0 DIV col0 AS col2 FROM tab1
----
1249
1405
571

skipif mysql # not compatible
query I rowsort label-4605
SELECT DISTINCT - tab1.col2 * - col1 + col0 / col0 AS col2 FROM tab1
----
1249
1405
571

query I rowsort
SELECT col2 - + col0 * col0 AS col1 FROM tab0
----
-1224
-543
-7839

query I rowsort
SELECT ALL - col1 * col2 + - col0 * col0 * col2 FROM tab0
----
-1322
-21846
-656984

query I rowsort
SELECT ALL col0 * col1 * + col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT ALL + col2 + col1 + col2 * - col0 AS col2 FROM tab2
----
-131
-1943
-2947

onlyif mysql # use DIV operator for integer division
query I rowsort label-4610
SELECT DISTINCT + col0 DIV - tab1.col0 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-4610
SELECT DISTINCT + col0 / - tab1.col0 FROM tab1
----
-1

query I rowsort
SELECT ALL col2 + tab1.col1 + - col1 FROM tab1
----
54
57
96

query III rowsort
SELECT * FROM tab1 WHERE + col2 * + col2 + col2 = ( col1 )
----

query I rowsort
SELECT col2 + col2 * + col2 - col0 FROM tab0
----
-33
1098
6717

query I rowsort
SELECT DISTINCT - col2 + col1 * col0 * col0 + col2 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT ALL - col2 * tab0.col2 + col1 AS col2 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT + col1 * - tab0.col0 * + col1 + - col2 + + col0 FROM tab0
----
-177513
-329281
-737002

query I rowsort
SELECT DISTINCT tab0.col2 / + col1 AS col1 FROM tab0 WHERE NOT ( NULL ) = ( NULL )
----

query I rowsort
SELECT ALL + col2 * + col0 + + col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT - col1 + - tab1.col0 AS col2 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT DISTINCT col0 * col1 * col0 FROM tab2
----
106097
1519
358956

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL = ( col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4622
SELECT DISTINCT col1 DIV col0 + col0 * + col0 col2 FROM tab0
----
1227
579
7922

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4622
SELECT DISTINCT col1 / col0 + col0 * + col0 col2 FROM tab0
----
1227
579
7922

query I rowsort
SELECT - tab0.col2 + col2 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 + col0 * col1 * - col2 AS col2 FROM tab2
----
-119574
-50955
-5852

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 * + col0 col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ALL + + cor0.col0 + col2 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + col0 - - col2 * col0 * col0 FROM tab1 AS cor0
----
233536
489
614480

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col1 FROM tab0, tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col2 - + cor0.col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT - col0 * + tab1.col0 + col0 + - col0 AS col1 FROM tab1 WHERE NULL NOT IN ( col0 + col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - cor0.col0 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4632
SELECT ALL + 65 DIV cor1.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 61776d48a64244b82405672274b145fc

skipif mysql # not compatible
query I rowsort label-4632
SELECT ALL + 65 / cor1.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 61776d48a64244b82405672274b145fc

query I rowsort
SELECT DISTINCT - - col1 + + 58 FROM tab0 AS cor0
----
144
149
155

query I rowsort
SELECT col0 * col2 * cor0.col1 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4635
SELECT ALL cor0.col2 * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4635
SELECT ALL cor0.col2 * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4636
SELECT cor0.col2 DIV 26 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4636
SELECT cor0.col2 / 26 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT + col0 * - 91 FROM tab1 AS cor0
----
-273
-5824
-7280

onlyif mysql # use DIV operator for integer division
query I rowsort label-4638
SELECT - - col2 DIV 94 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4638
SELECT - - col2 / 94 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4639
SELECT + + col2 + - col0 DIV col2 FROM tab0 AS cor0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-4639
SELECT + + col2 + - col0 / col2 FROM tab0 AS cor0
----
-34
33
81

query I rowsort
SELECT + ( - col1 ) * - col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL 31 + 60 * - col0 AS col2 FROM tab0 AS cor0
----
-1409
-2069
-5309

query I rowsort
SELECT ALL - 97 + + 1 FROM tab1 AS cor0
----
-96
-96
-96

query I rowsort
SELECT - cor0.col0 + - col0 * + col1 AS col2 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL + col0 + col1 + - col0 FROM tab1
----
10
13
26

query I rowsort
SELECT - col0 * 39 * + col0 AS col2 FROM tab0 AS cor0
----
-22464
-308919
-47775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col0 * - tab0.col1 col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ( - col1 ) * 6 AS col1 FROM tab0 AS cor0
----
-516
-546
-582

query I rowsort
SELECT 79 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * cor0.col2 col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - + cor0.col0 + col0 + col1 * col1 * col1 FROM tab0 AS cor0
----
636056
753571
912673

query I rowsort
SELECT DISTINCT + 7 * + col0 FROM tab0 AS cor0
----
168
245
623

query I rowsort
SELECT DISTINCT col2 FROM tab1 WHERE ( NULL ) < ( NULL )
----

query I rowsort
SELECT + col2 * - col1 + col0 - - col2 * - col2 FROM tab1
----
-10384
-3755
-4317

query I rowsort
SELECT DISTINCT + col2 * - tab0.col2 + tab0.col0 * col0 AS col2 FROM tab0
----
-513
1197
1224

query I rowsort
SELECT ALL - tab1.col1 FROM tab1 WHERE NULL < ( NULL )
----

query I rowsort
SELECT ALL - - col0 + - col2 + - 20 * + col1 FROM tab0 AS cor0
----
-1729
-1813
-1906

query I rowsort
SELECT + ( tab2.col1 * col2 ) + - col2 * col0 * - col2 FROM tab2
----
114722
54262
5940

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 + + tab2.col1 col0 FROM tab2
----
55
58
85

query I rowsort
SELECT col2 * - ( cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ( - cor0.col1 ) + + col0 AS col2 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4661
SELECT + + 69 + col1 + col1 DIV - cor0.col0 FROM tab1 AS cor0
----
79
82
87

skipif mysql # not compatible
query I rowsort label-4661
SELECT + + 69 + col1 + col1 / - cor0.col0 FROM tab1 AS cor0
----
79
82
87

query I rowsort
SELECT ( 92 ) - col0 FROM tab0
----
3
57
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-4663
SELECT + ( - col1 ) + - col2 DIV - 62 AS col2 FROM tab1 AS cor0
----
-10
-12
-26

skipif mysql # not compatible
query I rowsort label-4663
SELECT + ( - col1 ) + - col2 / - 62 AS col2 FROM tab1 AS cor0
----
-10
-12
-26

query I rowsort
SELECT + - ( col0 ) * col2 + ( ( col1 ) ) * - col0 FROM tab2 AS cor0
----
-406
-4345
-6630

query I rowsort
SELECT col2 + - col2 * col0 * col0 FROM tab2 AS cor0
----
-1296
-158158
-237120

query I rowsort
SELECT ( 83 ) + col1 AS col0 FROM tab2 AS cor0
----
100
114
142

onlyif mysql # use DIV operator for integer division
query I rowsort label-4667
SELECT DISTINCT - col2 - + col0 DIV + col1 AS col1 FROM tab1 AS cor0
----
-102
-54
-63

skipif mysql # not compatible
query I rowsort label-4667
SELECT DISTINCT - col2 - + col0 / + col1 AS col1 FROM tab1 AS cor0
----
-102
-54
-63

query I rowsort
SELECT DISTINCT + 2 * + col2 + - col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT 91 * col1 FROM tab1 cor0
----
1183
2366
910

query I rowsort
SELECT ALL ( col1 ) - + ( + cor0.col2 ) * col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + - 26 + - col1 * col2 FROM tab0 AS cor0
----
-123
-2864
-7488

query I rowsort
SELECT - 64 * + col1 AS col2 FROM tab1
----
-1664
-640
-832

query I rowsort
SELECT + cor0.col2 * - 16 - col0 * + col2 AS col2 FROM tab0 AS cor0
----
-1320
-51
-8610

query I rowsort
SELECT - + col0 - + 91 AS col2 FROM tab1 cor0
----
-155
-171
-94

query I rowsort
SELECT - col0 * col1 * + ( - col2 ) + col0 * + ( + 66 ) FROM tab0
----
5705
669992
69696

query I rowsort
SELECT - col2 + col1 * col1 AS col0 FROM tab2 cor0
----
251
3455
934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - 56 col1 FROM tab1
----
-1456
-560
-728

query I rowsort
SELECT ( 37 ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4679
SELECT - + 99 * col2 + - col1 DIV + col1 AS col1 FROM tab1 AS cor0
----
-5347
-5644
-9505

skipif mysql # not compatible
query I rowsort label-4679
SELECT - + 99 * col2 + - col1 / + col1 AS col1 FROM tab1 AS cor0
----
-5347
-5644
-9505

onlyif mysql # use DIV operator for integer division
query I rowsort label-4680
SELECT tab1.col2 DIV ( col2 ) FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4680
SELECT tab1.col2 / ( col2 ) FROM tab1
----
1
1
1

query I rowsort
SELECT + col0 * - 83 FROM tab0
----
-1992
-2905
-7387

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4682
SELECT - CAST( 31 AS SIGNED ) * + cor0.col0 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to f00d9b255a3e2c00771fde8a329cecd0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4682
SELECT - CAST ( 31 AS INTEGER ) * + cor0.col0 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to f00d9b255a3e2c00771fde8a329cecd0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4683
SELECT DISTINCT col1 * CAST( col1 AS SIGNED ) FROM tab1
----
100
169
676

skipif mysql # not compatible
query I rowsort label-4683
SELECT DISTINCT col1 * CAST ( col1 AS INTEGER ) FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT + - 38 AS col2 FROM tab2 AS cor0
----
-38

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL 2 * ( + col2 ) AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT 28 * + col2 AS col0 FROM tab0 AS cor0
----
2296
28
924

query I rowsort
SELECT ALL + 81 * - 95 FROM tab2, tab2 AS cor0
----
9 values hashing to 4f602f0d3ae023c5f618b419289f5324

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4689
SELECT tab0.col1 * CAST( col0 * col1 AS SIGNED ) AS col0 FROM tab0
----
177504
329315
737009

skipif mysql # not compatible
query I rowsort label-4689
SELECT tab0.col1 * CAST ( col0 * col1 AS INTEGER ) AS col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT + ( cor1.col1 ) + 97 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 168f04f79bf0fe53ef77f40c5e1714f6

query I rowsort
SELECT - 30 * 8 FROM tab0
----
-240
-240
-240

query I rowsort
SELECT DISTINCT - 38 + + col1 FROM tab2
----
-21
-7
21

query I rowsort
SELECT + ( - 45 ) - - col2 FROM tab0
----
-12
-44
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-4694
SELECT col1 * + col2 + - tab0.col1 * col2 DIV col2 - - col0 FROM tab0
----
2776
35
7460

skipif mysql # not compatible
query I rowsort label-4694
SELECT col1 * + col2 + - tab0.col1 * col2 / col2 - - col0 FROM tab0
----
2776
35
7460

query I rowsort
SELECT + + 29 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT + 42 AS col2 FROM tab1
----
42
42
42

query I rowsort
SELECT ALL + col0 * + 41 - - cor0.col1 FROM tab2 AS cor0
----
318
3256
3257

onlyif mysql # use DIV operator for integer division
query I rowsort label-4698
SELECT DISTINCT + + cor0.col0 DIV - 16 FROM tab0 AS cor0
----
-1
-2
-5

skipif mysql # not compatible
query I rowsort label-4698
SELECT DISTINCT + + cor0.col0 / - 16 FROM tab0 AS cor0
----
-1
-2
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4699
SELECT - 20 + col0 DIV col0 FROM tab0
----
-19
-19
-19

skipif mysql # not compatible
query I rowsort label-4699
SELECT - 20 + col0 / col0 FROM tab0
----
-19
-19
-19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 70 - col1 col0 FROM tab0
----
-156
-161
-167

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 81 col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * cor0.col1 col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
289
3481
961

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT col0 + col0 * + 29 * - col1 AS col1 FROM tab2 AS cor0
----
-133380
-38868
-6286

query I rowsort
SELECT col0 * + col1 + + col0 * col1 FROM tab0
----
16198
4128
6790

query I rowsort
SELECT col1 * col0 * + col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT + col0 + ( cor0.col2 ) * + col2 AS col1 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT + cor0.col1 + 71 * col2 AS col0 FROM tab0 AS cor0
----
168
2429
5913

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + - 13 col1 FROM tab2 AS cor0
----
-20
-91
-92

query I rowsort
SELECT ALL - - col0 - ( col0 ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col0 * - cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4712
SELECT ALL - col2 * + CAST( NULL AS DECIMAL ) + col1 * col2 + col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4712
SELECT ALL - col2 * + CAST ( NULL AS REAL ) + col1 * col2 + col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col2 * col2 + 88 AS col2 FROM tab2 AS cor0
----
-1356
-588
-641

query I rowsort
SELECT - col0 * + col1 * + col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT + col1 * col2 + col2 AS col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT ALL + + col0 + col0 * - col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL + + cor0.col0 * cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT + 11 * - col2 + + col2 * + col2 FROM tab2 AS cor0
----
1026
390
432

query I rowsort
SELECT ALL - 49 AS col1 FROM tab0
----
-49
-49
-49

query I rowsort
SELECT - + col2 * col1 * col1 AS col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL - - col1 + + cor0.col2 FROM tab0 cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4722
SELECT DISTINCT ( + col0 ) * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4722
SELECT DISTINCT ( + col0 ) * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT cor0.col1 * ( + cor0.col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + cor0.col0 * + col2 + col1 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT - col1 - + col1 * - 5 * + col1 AS col2 FROM tab1
----
3354
490
832

query I rowsort
SELECT col1 * col1 + + col1 AS col0 FROM tab1 cor0
----
110
182
702

query I rowsort
SELECT ALL + 24 + + tab0.col1 FROM tab0
----
110
115
121

query I rowsort
SELECT + tab2.col0 AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT + col1 * - col1 + - col1 AS col1 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT ALL + - 11 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

query I rowsort
SELECT DISTINCT col2 + + col0 * + 48 + - col2 FROM tab0
----
1152
1680
4272

query I rowsort
SELECT ALL 34 + col2 AS col1 FROM tab0 AS cor0
----
116
35
67

query I rowsort
SELECT DISTINCT - ( 44 ) AS col1 FROM tab0 AS cor0
----
-44

onlyif mysql # use DIV operator for integer division
query I rowsort label-4734
SELECT ALL col2 + + cor0.col0 DIV - col1 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4734
SELECT ALL col2 + + cor0.col0 / - col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL + cor0.col2 + - 76 FROM tab2 AS cor0
----
-38
-49
-50

query I rowsort
SELECT DISTINCT - + col2 + col0 * + col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL + + col0 - - 16 * col0 AS col0 FROM tab2 AS cor0
----
119
1326
1343

query I rowsort
SELECT ALL + - 93 FROM tab1 AS cor0
----
-93
-93
-93

query I rowsort
SELECT ALL ( + col2 ) * + col2 * col0 - col1 * col1 AS col2 FROM tab0 AS cor0
----
-9374
18740
590155

query I rowsort
SELECT DISTINCT col2 + + 81 * cor0.col0 FROM tab0 AS cor0
----
1977
2836
7291

query I rowsort
SELECT + + col0 * - 87 FROM tab0 cor0
----
-2088
-3045
-7743

query I rowsort
SELECT ALL - - 6 * - col2 - - col2 AS col1 FROM tab2 AS cor0
----
-130
-135
-190

query I rowsort
SELECT DISTINCT - 21 + cor0.col2 * + col0 * - col1 FROM tab2 AS cor0
----
-119673
-51055
-5880

query I rowsort
SELECT ALL 5 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT col1 - - ( col1 ) AS col2 FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4746
SELECT ALL tab2.col2 DIV - 65 + col1 AS col0 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4746
SELECT ALL tab2.col2 / - 65 + col1 AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT - col1 + 52 * col0 FROM tab0
----
1162
1723
4537

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4748
SELECT - - CAST( 56 AS SIGNED ) FROM tab2 AS cor0
----
56
56
56

skipif mysql # not compatible
query I rowsort label-4748
SELECT - - CAST ( 56 AS INTEGER ) FROM tab2 AS cor0
----
56
56
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * col0 + col2 col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT - - col1 * 96 * + col0 FROM tab0 AS cor0
----
198144
325920
777504

query I rowsort
SELECT ALL + + 42 * - cor0.col0 * col1 + 97 AS col1 FROM tab0 cor0
----
-142493
-340061
-86591

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4752
SELECT DISTINCT ( col2 ) + col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4752
SELECT DISTINCT ( col2 ) + col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + + cor0.col1 * col2 + + col0 AS col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - - cor0.col2 * col2 + - cor0.col0 FROM tab0 AS cor0
----
-34
1065
6635

onlyif mysql # use DIV operator for integer division
query I rowsort label-4755
SELECT ALL + 70 DIV col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4755
SELECT ALL + 70 / col2 FROM tab1
----
0
1
1

query I rowsort
SELECT ALL col2 + 45 * col1 FROM tab2 AS cor0
----
1422
2681
803

query I rowsort
SELECT + - 54 * - col2 FROM tab0 AS cor0
----
1782
4428
54

query I rowsort
SELECT ALL 58 * - col2 * col2 FROM tab1
----
-169128
-188442
-534528

query I rowsort
SELECT ( + col2 + + col0 ) * + tab1.col0 * col1 FROM tab1
----
183040
4446
77440

query I rowsort
SELECT 42 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT ALL - 80 * - col2 FROM tab2 AS cor0
----
2080
2160
3040

query I rowsort
SELECT DISTINCT + 79 + - col1 FROM tab1 AS cor0
----
53
66
69

query I rowsort
SELECT DISTINCT 49 + + col1 FROM tab0 AS cor0
----
135
140
146

query I rowsort
SELECT ALL - + ( - col1 ) * 31 AS col0 FROM tab0 cor0
----
2666
2821
3007

query I rowsort
SELECT 25 * - col1 FROM tab0 AS cor0
----
-2150
-2275
-2425

onlyif mysql # use DIV operator for integer division
query I rowsort label-4766
SELECT DISTINCT - col0 * 7 DIV + col1 FROM tab1
----
-43
-44
0

skipif mysql # not compatible
query I rowsort label-4766
SELECT DISTINCT - col0 * 7 / + col1 FROM tab1
----
-43
-44
0

query I rowsort
SELECT ALL + col0 + + 91 * + col0 + - col1 AS col0 FROM tab0
----
2122
3123
8097

query I rowsort
SELECT - cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4769
SELECT ALL col2 + CAST( NULL AS SIGNED ) / + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4769
SELECT ALL col2 + CAST ( NULL AS INTEGER ) / + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * - col2 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - - col2 - - 99 AS col1 FROM tab1 AS cor0
----
153
156
195

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + col1 * - cor0.col0 col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4773
SELECT ALL + col0 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4773
SELECT ALL + col0 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + ( 39 ) AS col0 FROM tab0 cor0
----
-47
-52
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col1 ) + col0 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + col2 + col0 * col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT col1 * - col2 + - 52 AS col2 FROM tab2
----
-1586
-698
-889

query I rowsort
SELECT col0 + + col2 * col1 AS col2 FROM tab2
----
1612
725
844

query I rowsort
SELECT + col2 * col0 - ( + 55 ) AS col1 FROM tab0 AS cor0
----
-20
7243
737

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4780
SELECT 16 * + col1 + + CAST( cor0.col2 AS SIGNED ) * + col1 * - col1 FROM tab1 AS cor0
----
-16016
-36088
-5540

skipif mysql # not compatible
query I rowsort label-4780
SELECT 16 * + col1 + + CAST ( cor0.col2 AS INTEGER ) * + col1 * - col1 FROM tab1 AS cor0
----
-16016
-36088
-5540

query I rowsort
SELECT - col2 - col1 * ( 19 ) * - col2 AS col2 FROM tab0 AS cor0
----
141696
1842
53889

query I rowsort
SELECT ALL col1 + + 59 AS col2 FROM tab1
----
69
72
85

query I rowsort
SELECT ALL - col0 + 94 * 34 AS col1 FROM tab2 AS cor0
----
3117
3118
3189

query I rowsort
SELECT ALL + + 46 AS col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT cor0.col0 * - 86 FROM tab1 AS cor0
----
-258
-5504
-6880

query I rowsort
SELECT ALL - ( + col2 ) + + col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 24 * cor2.col0 AS col1 FROM tab2, tab2 cor0, tab0 AS cor1, tab2 cor2
----
81 values hashing to 989a62b719ddf2649b3ff5aff46b7a52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4788
SELECT CAST( 58 AS SIGNED ) * col0 FROM tab2 cor0
----
406
4524
4582

skipif mysql # not compatible
query I rowsort label-4788
SELECT CAST ( 58 AS INTEGER ) * col0 FROM tab2 cor0
----
406
4524
4582

onlyif mysql # use DIV operator for integer division
query I rowsort label-4789
SELECT DISTINCT cor0.col0 * - cor0.col0 DIV cor0.col0 AS col1 FROM tab0, tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4789
SELECT DISTINCT cor0.col0 * - cor0.col0 / cor0.col0 AS col1 FROM tab0, tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL 22 * 43 AS col2 FROM tab2
----
946
946
946

query I rowsort
SELECT + 32 + + col1 AS col1 FROM tab0 AS cor0
----
118
123
129

query I rowsort
SELECT DISTINCT 74 FROM tab1, tab0 cor0
----
74

query I rowsort
SELECT 47 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT + + ( + col1 ) * + ( col0 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - ( - col2 ) * 4 AS col0 FROM tab0 AS cor0
----
132
328
4

query I rowsort
SELECT + 49 * + cor0.col0 FROM tab2 AS cor0
----
343
3822
3871

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4797
SELECT ALL CAST( NULL AS SIGNED ) FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4797
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4798
SELECT ALL - 9 DIV - cor0.col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4798
SELECT ALL - 9 / - cor0.col1 FROM tab2 AS cor0
----
0
0
0

query IIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0 WHERE NOT NULL <= ( NULL )
----

query I rowsort
SELECT ALL + 95 * + col1 * + col0 + - col0 FROM tab2 AS cor0
----
127506
20608
437112

query I rowsort
SELECT ALL + col1 + + col1 * col1 FROM tab1 AS cor0
----
110
182
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-4802
SELECT ALL + 31 DIV col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4802
SELECT ALL + 31 / col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL 11 * + col2 AS col2 FROM tab1
----
1056
594
627

query I rowsort
SELECT col2 * col1 - + col1 FROM tab0
----
0
2752
7371

query I rowsort
SELECT ALL + col0 + - ( + col2 ) FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + cor0.col0 * 59 - - col2 AS col2 FROM tab0 AS cor0
----
1449
2066
5333

query I rowsort
SELECT DISTINCT - col2 * 62 FROM tab0 cor0
----
-2046
-5084
-62

query I rowsort
SELECT DISTINCT + col2 * col1 + + 90 FROM tab0 AS cor0
----
187
2928
7552

onlyif mysql # use DIV operator for integer division
query I rowsort label-4809
SELECT 86 DIV col0 AS col1 FROM tab0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-4809
SELECT 86 / col0 AS col1 FROM tab0
----
0
2
3

query I rowsort
SELECT + cor0.col1 AS col1 FROM tab1, tab2, tab1 cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT - 27 FROM tab1, tab0, tab1 AS cor0
----
-27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4812
SELECT - col2 + + col2 * - CAST( - col0 AS SIGNED ) * col1 col2 FROM tab0
----
3394
664036
68079

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4812
SELECT - col2 + + col2 * - CAST ( - col0 AS INTEGER ) * col1 col2 FROM tab0
----
3394
664036
68079

onlyif mysql # use DIV operator for integer division
query I rowsort label-4813
SELECT DISTINCT - 25 DIV col1 AS col1 FROM tab2
----
-1
0

skipif mysql # not compatible
query I rowsort label-4813
SELECT DISTINCT - 25 / col1 AS col1 FROM tab2
----
-1
0

query I rowsort
SELECT - - 91 * - cor0.col2 + + col0 * - 49 FROM tab1 AS cor0
----
-12656
-5061
-8323

query I rowsort
SELECT DISTINCT col1 + 36 AS col1 FROM tab2 cor0
----
53
67
95

query I rowsort
SELECT - - col0 + - col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL - - cor0.col0 + - col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + ( + ( - col1 ) ) * cor0.col0 + + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT + col0 - 70 * + tab2.col0 AS col1 FROM tab2
----
-483
-5382
-5451

query I rowsort
SELECT - cor0.col1 + - 52 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to f0984dfd22ea487accef7b549b286c47

query I rowsort
SELECT 28 + 29 FROM tab2 AS cor0
----
57
57
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4822
SELECT 56 DIV - col2 + + cor0.col2 FROM tab1 AS cor0
----
53
57
96

skipif mysql # not compatible
query I rowsort label-4822
SELECT 56 / - col2 + + cor0.col2 FROM tab1 AS cor0
----
53
57
96

query I rowsort
SELECT DISTINCT + - 77 * col2 + col1 - col2 * + col2 AS col2 FROM tab1 cor0
----
-16595
-7048
-7628

query I rowsort
SELECT - col2 * col1 * - col2 + tab1.col1 FROM tab1
----
119821
32500
75842

query I rowsort
SELECT DISTINCT col2 * + col1 * col1 AS col2 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4826
SELECT - col0 * - CAST( col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-4826
SELECT - col0 * - CAST ( col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4827
SELECT DISTINCT - - cor0.col2 + + 14 * 36 DIV col2 AS col0 FROM tab0 cor0
----
48
505
88

skipif mysql # not compatible
query I rowsort label-4827
SELECT DISTINCT - - cor0.col2 + + 14 * 36 / col2 AS col0 FROM tab0 cor0
----
48
505
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-4828
SELECT ALL - - col0 * col0 DIV + ( col2 ) FROM tab1 cor0
----
0
66
71

skipif mysql # not compatible
query I rowsort label-4828
SELECT ALL - - col0 * col0 / + ( col2 ) FROM tab1 cor0
----
0
66
71

query I rowsort
SELECT DISTINCT - - col1 * ( col0 ) + col2 AS col2 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT ALL 72 * + col0 * col2 FROM tab1 AS cor0
----
11664
262656
552960

query I rowsort
SELECT ALL - 34 * col2 - - col1 * - col2 AS col0 FROM tab1 AS cor0
----
-2508
-3240
-4512

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * + 75 col2 FROM tab0 cor0
----
2475
6150
75

query I rowsort
SELECT ALL 65 + - col1 AS col0 FROM tab2 AS cor0
----
34
48
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 85 + col0 col2 FROM tab1 AS cor0
----
-21
-5
-82

query I rowsort
SELECT - 34 + cor0.col0 AS col2 FROM tab0 AS cor0
----
-10
1
55

query I rowsort
SELECT ALL + ( 35 ) FROM tab2 AS cor0
----
35
35
35

query I rowsort
SELECT - col2 * - 70 FROM tab1 AS cor0
----
3780
3990
6720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4838
SELECT DISTINCT + CAST( + col2 AS SIGNED ) * + col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-4838
SELECT DISTINCT + CAST ( + col2 AS INTEGER ) * + col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + ( 34 ) FROM tab1 AS cor0
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4840
SELECT 98 DIV - col2 FROM tab0 AS cor0
----
-1
-2
-98

skipif mysql # not compatible
query I rowsort label-4840
SELECT 98 / - col2 FROM tab0 AS cor0
----
-1
-2
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4841
SELECT DISTINCT + col2 * - CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4841
SELECT DISTINCT + col2 * - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4842
SELECT DISTINCT col1 DIV + 12 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-4842
SELECT DISTINCT col1 / + 12 FROM tab2
----
1
2
4

query I rowsort
SELECT - - col1 + col1 * + col0 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT 91 + col0 FROM tab0 AS cor0
----
115
126
180

query I rowsort
SELECT DISTINCT col0 + cor0.col1 * 16 * - col0 AS col0 FROM tab2 AS cor0
----
-21409
-3465
-73554

onlyif mysql # use DIV operator for integer division
query I rowsort label-4846
SELECT ALL col1 + - col0 DIV + 12 FROM tab0 cor0
----
84
84
95

skipif mysql # not compatible
query I rowsort label-4846
SELECT ALL col1 + - col0 / + 12 FROM tab0 cor0
----
84
84
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT DISTINCT - - col1 * col1 DIV + 93 AS col1 FROM tab1 AS cor0
----
1
7

skipif mysql # not compatible
query I rowsort label-4847
SELECT DISTINCT - - col1 * col1 / + 93 AS col1 FROM tab1 AS cor0
----
1
7

query I rowsort
SELECT + col0 * col0 + 31 * - col1 * col0 FROM tab0 AS cor0
----
-104020
-243148
-63408

query I rowsort
SELECT - ( cor0.col1 ) * - col0 + 80 * col1 AS col1 FROM tab1 cor0
----
1440
2080
2158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4850
SELECT + CAST( NULL AS SIGNED ) * - tab2.col0 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4850
SELECT + CAST ( NULL AS INTEGER ) * - tab2.col0 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 38 * 41 FROM tab0
----
1558
1558
1558

query I rowsort
SELECT - - col1 * col0 * 72 + - ( - col0 ) * - ( col1 ) FROM tab0 AS cor0
----
146544
241045
575029

query I rowsort
SELECT ALL cor0.col0 * - col1 * col2 AS col1 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + 47 + - col0 * - col1 FROM tab2 AS cor0
----
1390
264
4649

query I rowsort
SELECT DISTINCT - 13 + cor0.col1 AS col0 FROM tab0 AS cor0
----
73
78
84

query I rowsort
SELECT ALL - col2 + cor0.col2 * 52 AS col2 FROM tab2 AS cor0
----
1326
1377
1938

query I rowsort
SELECT ALL col0 + ( - col2 ) AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - col2 + 31 AS col2 FROM tab2 AS cor0
----
-7
4
5

query I rowsort
SELECT ALL 44 * + col1 AS col0 FROM tab1
----
1144
440
572

query I rowsort
SELECT + + cor0.col1 + - col0 AS col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - cor0.col1 + 93 + - 53 AS col0 FROM tab0 AS cor0
----
-46
-51
-57

query I rowsort
SELECT DISTINCT col0 * + 18 AS col1 FROM tab0 cor0
----
1602
432
630

query I rowsort
SELECT cor0.col2 + - col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT + col1 * - cor0.col1 + + col2 FROM tab2 cor0
----
-251
-3455
-934

query I rowsort
SELECT ALL + col2 * - ( cor0.col0 + cor0.col1 ) FROM tab0 cor0
----
-132
-14760
-3630

query I rowsort
SELECT cor0.col0 + ( cor0.col1 ) FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4867
SELECT ALL + col0 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4867
SELECT ALL + col0 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + 22 + - cor0.col2 FROM tab2 AS cor0
----
22

query I rowsort
SELECT DISTINCT - col1 * col1 + - col2 * + col2 FROM tab2 AS cor0
----
-1690
-1733
-4157

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col2 col0 FROM tab0 cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + + col0 col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL - col0 - 11 FROM tab0 AS cor0
----
-100
-35
-46

query I rowsort
SELECT DISTINCT + ( tab2.col0 ) * + col0 + + col2 FROM tab2
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4874
SELECT - + col0 + + col0 DIV col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-4874
SELECT - + col0 + + col0 / col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT 50 + - col2 * ( col1 ) AS col1 FROM tab2 AS cor0
----
-1484
-596
-787

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 81 * col0 col2 FROM tab2 AS cor0
----
567
6318
6399

query I rowsort
SELECT 73 + col2 + col0 FROM tab1
----
130
194
249

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4878
SELECT CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4878
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 83 + + col2 AS col0 FROM tab2 AS cor0
----
109
110
121

query I rowsort
SELECT ALL 5 * - col2 + - col2 AS col0 FROM tab1 AS cor0
----
-324
-342
-576

query I rowsort
SELECT DISTINCT 68 * - cor0.col0 FROM tab2 AS cor0
----
-476
-5304
-5372

query I rowsort
SELECT + col1 * + tab1.col1 AS col1 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL - - col0 - + col2 FROM tab1 cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4884
SELECT DISTINCT CAST( + col2 AS SIGNED ) * col0 AS col2 FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-4884
SELECT DISTINCT CAST ( + col2 AS INTEGER ) * col0 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL - + cor0.col0 - + col1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4886
SELECT DISTINCT col0 * + col0 + - ( 29 ) DIV col2 + 6 * col0 FROM tab1 AS cor0
----
27
4480
6880

skipif mysql # not compatible
query I rowsort label-4886
SELECT DISTINCT col0 * + col0 + - ( 29 ) / col2 + 6 * col0 FROM tab1 AS cor0
----
27
4480
6880

query I rowsort
SELECT DISTINCT cor0.col1 * col1 + - col2 * 98 FROM tab0 AS cor0
----
245
4162
9311

query I rowsort
SELECT + 6 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT + cor0.col1 + + 43 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 25272126c7c5a63eb0d40fbbe9300fd3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4890
SELECT ALL - col0 + col1 DIV col2 - + col0 FROM tab0
----
-177
-46
27

skipif mysql # not compatible
query I rowsort label-4890
SELECT ALL - col0 + col1 / col2 - + col0 FROM tab0
----
-177
-46
27

query I rowsort
SELECT DISTINCT 86 * col1 + + col1 - 92 AS col2 FROM tab2
----
1387
2605
5041

query I rowsort
SELECT + col2 * + col1 + col2 AS col2 FROM tab2 AS cor0
----
1560
684
864

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + ( + col2 ) AS REAL ) FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4894
SELECT - CAST( NULL AS SIGNED ) + + col2 * - col2 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4894
SELECT - CAST ( NULL AS INTEGER ) + + col2 * - col2 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 80 * - cor0.col2 - + cor0.col1 * ( 88 ) AS col1 FROM tab1 AS cor0
----
2032
3680
6536

query I rowsort
SELECT + + ( col0 ) + col0 AS col1 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4897
SELECT + cor0.col0 DIV col0 AS col2 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4897
SELECT + cor0.col0 / col0 AS col2 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - 77 * col0 + col2 * - col2 AS col1 FROM tab1 AS cor0
----
-15376
-3147
-8177

query I rowsort
SELECT - + 15 * 26 * - col2 + - col0 FROM tab2 AS cor0
----
10062
10523
14741

query I rowsort
SELECT + + cor0.col1 + cor0.col2 AS col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT + 34 * + col0 FROM tab0 AS cor0
----
1190
3026
816

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 - + 50 * + col1 * col0 FROM tab1 cor0
----
-35648
-4062
-59680

query I rowsort
SELECT ALL - 76 * + cor0.col2 FROM tab2 cor0
----
-1976
-2052
-2888

query I rowsort
SELECT - col0 + + col0 * - col2 AS col0 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-4905
SELECT DISTINCT + 79 DIV - col0 FROM tab1 AS cor0
----
-1
-26
0

skipif mysql # not compatible
query I rowsort label-4905
SELECT DISTINCT + 79 / - col0 FROM tab1 AS cor0
----
-1
-26
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4906
SELECT CAST( NULL AS SIGNED ) * 0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4906
SELECT CAST ( NULL AS INTEGER ) * 0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - cor0.col0 * 26 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 0330bf7252f6501c8562d1aa097ebbbb

query I rowsort
SELECT DISTINCT 44 AS col0 FROM tab2, tab2 AS cor0
----
44

query I rowsort
SELECT DISTINCT - + 26 - col2 FROM tab2 AS cor0
----
-52
-53
-64

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 DISTINCT col0 + + col1 * col2 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL + 88 + col0 * col0 FROM tab1 AS cor0
----
4184
6488
97

query I rowsort
SELECT ALL col0 * col0 - - 4 AS col1 FROM tab2 cor0
----
53
6088
6245

onlyif mysql # use DIV operator for integer division
query I rowsort label-4914
SELECT - + col1 - + ( cor0.col1 ) DIV - cor0.col0 AS col0 FROM tab1 AS cor0
----
-10
-13
-18

skipif mysql # not compatible
query I rowsort label-4914
SELECT - + col1 - + ( cor0.col1 ) / - cor0.col0 AS col0 FROM tab1 AS cor0
----
-10
-13
-18

query I rowsort
SELECT DISTINCT col2 + + ( 32 ) AS col2 FROM tab0 AS cor0
----
114
33
65

query I rowsort
SELECT DISTINCT + ( + 30 ) FROM tab1, tab1 AS cor0, tab2 AS cor1
----
30

query I rowsort
SELECT DISTINCT + col0 * - 6 FROM tab0
----
-144
-210
-534

query I rowsort
SELECT DISTINCT col1 * - 80 * + cor0.col0 FROM tab0 cor0
----
-165120
-271600
-647920

query I rowsort
SELECT ALL + col2 * 47 AS col0 FROM tab2 AS cor0
----
1222
1269
1786

query I rowsort
SELECT - col0 + col2 + cor0.col0 * col0 AS col0 FROM tab1 cor0
----
4089
60
6416

query I rowsort
SELECT DISTINCT + ( - col2 ) * col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-4922
SELECT DISTINCT + - ( col0 ) DIV + col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4922
SELECT DISTINCT + - ( col0 ) / + col0 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT 0 + 52 + + col1 FROM tab1 cor0
----
62
65
78

query I rowsort
SELECT DISTINCT - + col1 + - col1 * - col2 * - ( col2 + col2 ) FROM tab0 AS cor0
----
-1223859
-187394
-291

query I rowsort
SELECT + col2 + + col2 * + 75 + + col0 FROM tab1
----
4107
4396
7376

query I rowsort
SELECT ALL - tab0.col2 * + col2 * + col2 + + col2 + col1 * col0 FROM tab0
----
-33840
-543187
3395

query I rowsort
SELECT ALL + col1 + - ( + col2 ) AS col0 FROM tab1
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4928
SELECT DISTINCT col1 * CAST( 24 AS SIGNED ) + tab0.col0 FROM tab0
----
2088
2273
2363

skipif mysql # not compatible
query I rowsort label-4928
SELECT DISTINCT col1 * CAST ( 24 AS INTEGER ) + tab0.col0 FROM tab0
----
2088
2273
2363

query I rowsort
SELECT + col2 + col1 * col2 * + col2 AS col2 FROM tab2
----
22626
24586
39910

query I rowsort
SELECT tab0.col1 FROM tab0 WHERE NOT NULL > col0 / - col2
----

query I rowsort
SELECT - tab2.col2 + - col2 AS col2 FROM tab2
----
-52
-54
-76

query I rowsort
SELECT DISTINCT col0 * + col2 + tab0.col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT col0 * + col1 + - col1 FROM tab1
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4934
SELECT tab0.col1 DIV tab0.col1 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4934
SELECT tab0.col1 / tab0.col1 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT col2 * - col1 - col1 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT ALL + tab1.col2 + + col0 + - col2 * col0 AS col1 FROM tab1
----
-105
-3527
-7504

query I rowsort
SELECT DISTINCT + col1 * col0 + col2 AS col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL col2 * col0 * col0 + - col1 AS col2 FROM tab2 AS cor0
----
1292
158125
237141

query I rowsort
SELECT - - cor0.col0 - col1 AS col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - col0 + col1 * + cor0.col0 FROM tab1 AS cor0
----
576
75
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-4941
SELECT ALL + col0 DIV + col2 - + cor0.col1 FROM tab1 AS cor0
----
-13
-26
-9

skipif mysql # not compatible
query I rowsort label-4941
SELECT ALL + col0 / + col2 - + cor0.col1 FROM tab1 AS cor0
----
-13
-26
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - col1 + col2 * + col2 * - cor0.col1 col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL + + cor0.col0 * + col1 - + col1 * + col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + col1 + - col2 AS col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT cor0.col0 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + col2 - - col0 AS col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4947
SELECT + col0 DIV col0 + - col0 - + col2 DIV col2 col0 FROM tab1
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4947
SELECT + col0 / col0 + - col0 - + col2 / col2 col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col0 * col1 + col2 AS col1 FROM tab1
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-4949
SELECT ALL - - col1 DIV cor0.col0 - + col0 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-4949
SELECT ALL - - col1 / cor0.col0 - + col0 FROM tab1 AS cor0
----
-64
-80
5

query I rowsort
SELECT DISTINCT - - col2 * - col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * - cor0.col0 + - col0 col2 FROM tab0 AS cor0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * + col2 + - cor0.col0 col0 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT col1 * col1 - - col2 AS col0 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL 36 FROM tab2 cor0
----
36
36
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col2 ) * + 44 col1 FROM tab1
----
2376
2508
4224

query I rowsort
SELECT 53 - col1 * cor0.col2 FROM tab1 AS cor0
----
-1195
-1351
-517

query I rowsort
SELECT cor0.col1 + - col1 * + col2 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT ( - cor0.col2 ) AS col0 FROM tab2, tab2 AS cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4959
SELECT - col0 * CAST( NULL AS SIGNED ) + - 26 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-4959
SELECT - col0 * CAST ( NULL AS INTEGER ) + - 26 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4960
SELECT col2 + - 42 DIV - col0 FROM tab0 AS cor0
----
2
34
82

skipif mysql # not compatible
query I rowsort label-4960
SELECT col2 + - 42 / - col0 FROM tab0 AS cor0
----
2
34
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4961
SELECT + col0 + CAST( - col2 AS SIGNED ) * + col1 FROM tab0 cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort label-4961
SELECT + col0 + CAST ( - col2 AS INTEGER ) * + col1 FROM tab0 cor0
----
-2814
-62
-7373

query I rowsort
SELECT + cor0.col2 + + col0 + col0 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT cor0.col2 + 37 FROM tab2 AS cor0
----
63
64
75

query I rowsort
SELECT + + col0 * + 78 AS col2 FROM tab0 cor0
----
1872
2730
6942

query I rowsort
SELECT ALL + ( tab2.col1 ) FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + col1 + + col1 - - tab0.col0 * + tab0.col2 FROM tab0
----
229
7480
964

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL IN ( - tab2.col2 )
----

query I rowsort
SELECT col2 * - col0 + col1 - col1 * col0 FROM tab2
----
-375
-4328
-6571

query I rowsort
SELECT + col2 - - col2 AS col1 FROM tab2
----
52
54
76

query I rowsort
SELECT col1 + + tab1.col0 AS col1 FROM tab1 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT - col0 + - tab2.col1 AS col1 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT DISTINCT col0 * col2 + col0 FROM tab1
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col2 + col2 * + col2 col0 FROM tab0
----
0
1056
6642

onlyif mysql # use DIV operator for integer division
query I rowsort label-4974
SELECT col1 + + col1 DIV tab0.col1 AS col2 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-4974
SELECT col1 + + col1 / tab0.col1 AS col2 FROM tab0
----
87
92
98

query I rowsort
SELECT - col0 * + col0 * - col2 + col2 FROM tab2
----
1350
158210
237196

query I rowsort
SELECT ALL - col2 * - col0 * + col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT col0 * - tab1.col0 + col1 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT + col1 FROM tab1 WHERE + col1 + - col0 IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4979
SELECT col1 DIV + col1 + col1 * col1 AS col2 FROM tab0
----
7397
8282
9410

skipif mysql # not compatible
query I rowsort label-4979
SELECT col1 / + col1 + col1 * col1 AS col2 FROM tab0
----
7397
8282
9410

query III rowsort
SELECT * FROM tab2 WHERE ( - col0 ) NOT BETWEEN col0 + col2 AND NULL
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL + col0 AS col2 FROM tab1 WHERE NOT col0 / + col1 <> ( + col2 + col1 )
----

query I rowsort
SELECT ALL + col0 * - col2 + col2 AS col1 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT tab2.col1 + col1 * col2 AS col2 FROM tab2
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col2 * - col0 col2 FROM tab1
----
136
3638
7667

query I rowsort
SELECT + col1 * + 74 AS col0 FROM tab0 AS cor0
----
6364
6734
7178

query I rowsort
SELECT - + col1 + - col2 * col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT - + col2 * ( col2 ) + col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - col0 * - col2 * + 69 FROM tab2
----
13041
139932
207138

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * - col2 col2 FROM tab1
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort
SELECT + col0 * CAST ( - col1 AS REAL ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - - col2 + 69 * 83 FROM tab0 AS cor0
----
5728
5760
5809

query I rowsort
SELECT ALL + col0 * - 88 AS col1 FROM tab1 AS cor0
----
-264
-5632
-7040

query I rowsort
SELECT DISTINCT col0 + ( + 60 + + col2 ) * + 55 AS col2 FROM tab2 AS cor0
----
4792
4808
5469

onlyif mysql # use DIV operator for integer division
query I rowsort label-4994
SELECT ALL - - col0 DIV ( - col0 + ( + 33 ) ) AS col2 FROM tab1 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-4994
SELECT ALL - - col0 / ( - col0 + ( + 33 ) ) AS col2 FROM tab1 AS cor0
----
-1
-2
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4995
SELECT + CAST( col1 AS SIGNED ) + + col1 AS col0 FROM tab0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-4995
SELECT + CAST ( col1 AS INTEGER ) + + col1 AS col0 FROM tab0
----
172
182
194

query I rowsort
SELECT ALL + 20 AS col1 FROM tab2, tab2 cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 783fdb6630589eb0fa4e0c57a7c774ac

query I rowsort
SELECT ( - col0 ) * - col0 AS col1 FROM tab1
----
4096
6400
9

query I rowsort
SELECT DISTINCT col0 * + ( + col1 ) * - col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT - + col0 + - col2 + 28 * + col0 AS col0 FROM tab1 AS cor0
----
1671
2064
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + + 69 col0 FROM tab2 AS cor0
----
31
42
43

query I rowsort
SELECT ( 40 ) FROM tab0, tab1 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5002
SELECT ALL + col2 * - col2 + col2 + + col1 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
-1406
-650
-698

skipif mysql # not compatible
query I rowsort label-5002
SELECT ALL + col2 * - col2 + col2 + + col1 / cor0.col0 AS col1 FROM tab2 AS cor0
----
-1406
-650
-698

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 + + 33 AS col0 FROM tab0 AS cor0
----
2097
3428
8132

query I rowsort
SELECT - - col0 * 23 + + col2 AS col0 FROM tab0 AS cor0
----
2129
585
806

query I rowsort
SELECT DISTINCT + col2 + col1 + col1 * col0 AS col2 FROM tab0 cor0
----
2183
3493
8272

query I rowsort
SELECT + - col2 + cor0.col2 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5007
SELECT col1 * ( col0 ) + ( col2 ) DIV col1 AS col0 FROM tab1
----
1047
645
80

skipif mysql # not compatible
query I rowsort label-5007
SELECT col1 * ( col0 ) + ( col2 ) / col1 AS col0 FROM tab1
----
1047
645
80

query I rowsort
SELECT col0 - ( + tab1.col0 ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT tab1.col1 * + 88 + col2 FROM tab1
----
1240
2342
937

onlyif mysql # use DIV operator for integer division
query I rowsort label-5010
SELECT col0 - 51 DIV - col0 AS col2 FROM tab0
----
26
36
89

skipif mysql # not compatible
query I rowsort label-5010
SELECT col0 - 51 / - col0 AS col2 FROM tab0
----
26
36
89

query I rowsort
SELECT DISTINCT tab0.col0 * col1 - + tab0.col0 * - col1 AS col1 FROM tab0
----
16198
4128
6790

query I rowsort
SELECT + cor0.col0 * 4 AS col2 FROM tab1 AS cor0
----
12
256
320

query I rowsort
SELECT + - 81 * col2 AS col2 FROM tab1 cor0
----
-4374
-4617
-7776

query I rowsort
SELECT DISTINCT - + 49 * + col1 FROM tab2 cor0
----
-1519
-2891
-833

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5015
SELECT ALL col2 + cor0.col1 * + CAST( 64 AS SIGNED ) FROM tab2 AS cor0
----
1126
2011
3802

skipif mysql # not compatible
query I rowsort label-5015
SELECT ALL col2 + cor0.col1 * + CAST ( 64 AS INTEGER ) FROM tab2 AS cor0
----
1126
2011
3802

query I rowsort
SELECT - - cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + - ( - col0 ) * col1 + - col1 AS col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT + 84 * - col0 * ( + col2 ) + - col1 * + col2 AS col2 FROM tab2 AS cor0
----
-16713
-171886
-252814

query I rowsort
SELECT + cor0.col0 + - col1 + + 81 FROM tab1 cor0
----
135
148
58

query I rowsort
SELECT DISTINCT - 36 + col0 * - col2 FROM tab0 AS cor0
----
-71
-7334
-828

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 78 * + col1 col0 FROM tab1 AS cor0
----
-1014
-2028
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-5022
SELECT + 0 DIV - tab0.col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5022
SELECT + 0 / - tab0.col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT 89 + col0 * col2 * 49 FROM tab2 AS cor0
----
147187
9350
99461

query I rowsort
SELECT ALL - ( col2 ) + - 90 FROM tab0 AS cor0
----
-123
-172
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( - col2 ) col1 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + col1 + col1 * cor0.col1 AS col2 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT - 89 AS col2 FROM tab0 AS cor0
----
-89
-89
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5028
SELECT DISTINCT + col2 DIV + ( col1 ) col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5028
SELECT DISTINCT + col2 / + ( col1 ) col2 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5029
SELECT ALL - col0 * 82 + - col0 DIV col1 AS col1 FROM tab0
----
-1968
-2870
-7298

skipif mysql # not compatible
query I rowsort label-5029
SELECT ALL - col0 * 82 + - col0 / col1 AS col1 FROM tab0
----
-1968
-2870
-7298

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 + 14 col0 FROM tab0
----
15
47
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5031
SELECT ALL CAST( NULL AS SIGNED ) + col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5031
SELECT ALL CAST ( NULL AS INTEGER ) + col2 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 18 AS col2 FROM tab1
----
18
18
18

query I rowsort
SELECT ALL 94 * cor0.col0 FROM tab1 AS cor0
----
282
6016
7520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + cor0.col2 ) + col1 col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ( + tab1.col2 * col1 ) AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + - 69 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5037
SELECT DISTINCT CAST( NULL AS SIGNED ) / col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5037
SELECT DISTINCT CAST ( NULL AS INTEGER ) / col1 FROM tab2
----
NULL

query I rowsort
SELECT 97 - - col2 AS col2 FROM tab2
----
123
124
135

query I rowsort
SELECT ALL - col2 * 20 + ( col2 ) * col0 AS col0 FROM tab0 AS cor0
----
132
15
5658

query I rowsort
SELECT - - col2 * col0 + 69 FROM tab0 AS cor0
----
104
7367
861

query I rowsort
SELECT - col2 * + col1 + ( col1 ) AS col0 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT 75 AS col0 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

onlyif mysql # use DIV operator for integer division
query I rowsort label-5043
SELECT - col0 DIV + col1 + tab0.col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5043
SELECT - col0 / + col1 + tab0.col1 FROM tab0
----
86
91
97

query I rowsort
SELECT 43 + col0 * + tab2.col2 FROM tab2
----
2071
232
3045

query I rowsort
SELECT - 7 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

onlyif mysql # use DIV operator for integer division
query I rowsort label-5046
SELECT col0 DIV 10 FROM tab0
----
2
3
8

skipif mysql # not compatible
query I rowsort label-5046
SELECT col0 / 10 FROM tab0
----
2
3
8

query I rowsort
SELECT ALL + + col0 * 35 FROM tab2 AS cor0
----
245
2730
2765

onlyif mysql # use DIV operator for integer division
query I rowsort label-5048
SELECT DISTINCT + col1 DIV 14 + col2 + + col2 * col0 FROM tab2 AS cor0
----
2058
218
3041

skipif mysql # not compatible
query I rowsort label-5048
SELECT DISTINCT + col1 / 14 + col2 + + col2 * col0 FROM tab2 AS cor0
----
2058
218
3041

query I rowsort
SELECT col0 + col0 + 61 AS col1 FROM tab1
----
189
221
67

query I rowsort
SELECT DISTINCT col2 + + 57 AS col2 FROM tab2 AS cor0
----
83
84
95

query I rowsort
SELECT ALL + cor0.col0 - - 84 AS col0 FROM tab1 AS cor0
----
148
164
87

query I rowsort
SELECT - col0 * + 69 + - col2 FROM tab0 AS cor0
----
-1689
-2416
-6223

onlyif mysql # use DIV operator for integer division
query I rowsort label-5053
SELECT - + col0 DIV - col0 + - col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-5053
SELECT - + col0 / - col0 + - col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT ALL - col1 * 8 + col0 FROM tab0 AS cor0
----
-639
-664
-741

query I rowsort
SELECT + + col2 * col0 - - col1 AS col0 FROM tab0 AS cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col0 col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + + col0 * - ( - col1 ) FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col0 * - col1 + cor0.col0 * col1 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5059
SELECT ALL - col0 / CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5059
SELECT ALL - col0 / CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5060
SELECT DISTINCT + col0 * CAST( + ( + col2 ) AS SIGNED ) FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-5060
SELECT DISTINCT + col0 * CAST ( + ( + col2 ) AS INTEGER ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT col1 * 45 AS col1 FROM tab0 AS cor0
----
3870
4095
4365

onlyif mysql # use DIV operator for integer division
query I rowsort label-5062
SELECT ALL + cor0.col0 + ( - col1 ) DIV col0 FROM tab1 AS cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-5062
SELECT ALL + cor0.col0 + ( - col1 ) / col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT + + col0 * 12 FROM tab2 AS cor0
----
84
936
948

query I rowsort
SELECT - + col2 + + col1 * + col1 AS col2 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT - col0 + - col2 * + col1 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT ( + 73 ) * + col0 FROM tab2 AS cor0
----
511
5694
5767

query I rowsort
SELECT + ( - col2 ) + + col1 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT + col0 + 54 * col0 + col1 FROM tab2
----
416
4349
4362

query I rowsort
SELECT 69 - col2 AS col2 FROM tab0 AS cor0
----
-13
36
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 + - cor0.col2 * 10 col0 FROM tab2 AS cor0
----
1274
266
567

query I rowsort
SELECT DISTINCT + + col1 * col2 + col0 * + col0 FROM tab1 AS cor0
----
1413
4666
7648

onlyif mysql # use DIV operator for integer division
query I rowsort label-5072
SELECT DISTINCT col2 DIV col2 AS col1 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5072
SELECT DISTINCT col2 / col2 AS col1 FROM tab1 AS cor0
----
1

query I rowsort
SELECT - - col0 * + cor0.col1 + 52 AS col0 FROM tab1 AS cor0
----
1092
130
692

query I rowsort
SELECT + + 72 + - col2 FROM tab1 cor0
----
-24
15
18

query I rowsort
SELECT - 55 + col2 * col0 FROM tab1 AS cor0
----
107
3593
7625

query I rowsort
SELECT - + 51 * + col2 + + col2 AS col0 FROM tab0 AS cor0
----
-1650
-4100
-50

query I rowsort
SELECT DISTINCT + col1 * - col2 * col1 FROM tab2 cor0
----
-10982
-25947
-90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5078
SELECT - - col2 DIV + 66 col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5078
SELECT - - col2 / + 66 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT 79 + + col0 * - col2 FROM tab2
----
-110
-1949
-2923

query I rowsort
SELECT DISTINCT + 1 + col1 FROM tab2
----
18
32
60

query I rowsort
SELECT ALL + col2 + ( + col1 + tab2.col2 ) * 98 FROM tab2
----
5428
5711
8356

query I rowsort
SELECT 82 * + col1 * - col0 AS col2 FROM tab2
----
-110126
-17794
-377364

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 33 * - 5 + col1 * ( col0 ) col1 FROM tab1
----
-87
475
875

query I rowsort
SELECT + 13 * + col1 FROM tab0 cor0
----
1118
1183
1261

query I rowsort
SELECT ALL - tab2.col2 + - 81 * col0 AS col1 FROM tab2
----
-594
-6344
-6437

query I rowsort
SELECT + 27 AS col0 FROM tab1 AS cor0
----
27
27
27

query I rowsort
SELECT - 18 + col1 AS col1 FROM tab2 AS cor0
----
-1
13
41

query I rowsort
SELECT - 37 * col0 FROM tab0 AS cor0
----
-1295
-3293
-888

query I rowsort
SELECT DISTINCT ( + tab1.col1 * - col1 ) AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT ALL + ( 25 + - col2 ) AS col1 FROM tab1
----
-29
-32
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col2 col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL col1 + + col0 - + col2 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT - - col1 + - col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 * cor0.col1 + col0 * ( + cor0.col1 * - col2 ) FROM tab1 cor0
----
-2808
-35910
-98592

onlyif mysql # use DIV operator for integer division
query I rowsort label-5095
SELECT + col1 DIV + col2 + - col2 + - col1 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort label-5095
SELECT + col1 / + col2 + - col2 + - col1 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT - col1 * - 79 FROM tab2 cor0
----
1343
2449
4661

query I rowsort
SELECT - + cor0.col0 * ( col2 ) * + col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT ALL + + col2 + 95 * col2 FROM tab2 cor0
----
2496
2592
3648

query I rowsort
SELECT DISTINCT col2 + ( - ( + col1 ) ) FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + col2 * - ( + col2 ) AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - - 14 * 90 FROM tab2 cor0
----
1260

query I rowsort
SELECT DISTINCT - 60 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-5103
SELECT ALL + + col2 DIV 56 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5103
SELECT ALL + + col2 / 56 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * - ( col0 ) FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + col1 * 83 FROM tab1 AS cor0
----
1079
2158
830

query I rowsort
SELECT DISTINCT - cor0.col1 + - 35 * - col0 AS col2 FROM tab0 AS cor0
----
1128
3024
754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5108
SELECT CAST( - 54 AS SIGNED ) * + col1 FROM tab2 AS cor0
----
-1674
-3186
-918

skipif mysql # not compatible
query I rowsort label-5108
SELECT CAST ( - 54 AS INTEGER ) * + col1 FROM tab2 AS cor0
----
-1674
-3186
-918

query I rowsort
SELECT ALL cor0.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT + col2 * col1 * - ( col1 ) AS col0 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT + col1 + - col1 + - col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL cor0.col2 * cor0.col2 + col2 AS col2 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5113
SELECT + + CAST( + 48 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
48
48
48

skipif mysql # not compatible
query I rowsort label-5113
SELECT + + CAST ( + 48 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
48
48
48

query I rowsort
SELECT DISTINCT - + ( + 11 ) FROM tab0 cor0
----
-11

query I rowsort
SELECT ALL + 82 * col0 * col0 AS col2 FROM tab2 AS cor0
----
4018
498888
511762

query I rowsort
SELECT - 77 - col2 FROM tab1 AS cor0
----
-131
-134
-173

query I rowsort
SELECT ALL - col2 + cor0.col1 * - col1 AS col2 FROM tab2 AS cor0
----
-327
-3507
-988

query I rowsort
SELECT col1 - ( - cor0.col0 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - ( col2 ) + + col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT ALL 46 + 58 FROM tab1 AS cor0
----
104
104
104

query I rowsort
SELECT DISTINCT + col1 * - ( - cor0.col1 ) + ( col0 ) FROM tab1 AS cor0
----
164
249
679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + ( cor0.col1 ) col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + 52 * - 44 + col2 AS col1 FROM tab1 AS cor0
----
-2192
-2231
-2234

query I rowsort
SELECT ALL 96 * 36 FROM tab2 AS cor0
----
3456
3456
3456

query I rowsort
SELECT ALL - 9 + + 38 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT col2 * tab1.col2 + + ( + col0 ) * ( - col0 ) AS col1 FROM tab1
----
-847
2816
2907

onlyif mysql # use DIV operator for integer division
query I rowsort label-5127
SELECT DISTINCT col2 DIV col0 AS col0 FROM tab2 cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-5127
SELECT DISTINCT col2 / col0 AS col0 FROM tab2 cor0
----
0
3

query I rowsort
SELECT DISTINCT - col2 * col1 + - col2 AS col0 FROM tab2 cor0
----
-1560
-684
-864

query I rowsort
SELECT + 51 - col0 * + col0 AS col1 FROM tab2 AS cor0
----
-6033
-6190
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 3 + cor0.col0 col1 FROM tab1 AS cor0
----
6
67
83

query I rowsort
SELECT DISTINCT - col0 * 66 + + col2 + + col0 AS col0 FROM tab0
----
-1527
-2274
-5703

query I rowsort
SELECT DISTINCT - + cor0.col0 + + ( col0 + col1 * - col1 ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT 64 * 37 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
2368

query I rowsort
SELECT DISTINCT + + col0 * + 43 + + 47 AS col0 FROM tab2 AS cor0
----
3401
3444
348

query I rowsort
SELECT DISTINCT - + col2 + + col2 * - col0 FROM tab1 cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT col2 * ( ( + col0 ) ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col1 * 44 + col0 FROM tab2 AS cor0
----
1371
2674
827

query I rowsort
SELECT ALL - col1 * ( col1 ) + + col0 FROM tab0 cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - ( - col2 ) * + col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - 50 * - col1 + - 82 FROM tab1 AS cor0
----
1218
418
568

query I rowsort
SELECT DISTINCT - cor0.col1 + + col1 * 14 FROM tab2 AS cor0
----
221
403
767

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5142
SELECT ALL + 4 + + col2 * CAST( + cor0.col2 AS SIGNED ) * col2 FROM tab2 cor0
----
17580
19687
54876

skipif mysql # not compatible
query I rowsort label-5142
SELECT ALL + 4 + + col2 * CAST ( + cor0.col2 AS INTEGER ) * col2 FROM tab2 cor0
----
17580
19687
54876

query I rowsort
SELECT DISTINCT - - cor0.col1 + col1 * + col2 - + cor0.col2 * + col2 FROM tab2 AS cor0
----
-781
139
917

query I rowsort
SELECT ALL col2 + - col0 * - ( col0 + col1 ) AS col1 FROM tab0 AS cor0
----
16102
2673
4621

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col1 col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ( cor0.col2 * + cor0.col2 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 8a9dbff4c424879f0bb94abfbb1a134b

query I rowsort
SELECT + col2 + 74 * + ( + col2 ) * col2 FROM tab0 AS cor0
----
497658
75
80619

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 12 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT - col2 * 3 FROM tab0 AS cor0
----
-246
-3
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - 92 col1 FROM tab0 cor0
----
7912
8372
8924

onlyif mysql # use DIV operator for integer division
query I rowsort label-5151
SELECT ALL 78 DIV col2 AS col1 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-5151
SELECT ALL 78 / col2 AS col1 FROM tab1 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5152
SELECT ALL col0 + - cor0.col2 DIV + col0 AS col1 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-5152
SELECT ALL col0 + - cor0.col2 / + col0 AS col1 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT - ( + 83 ) * col0 FROM tab1 AS cor0
----
-249
-5312
-6640

query I rowsort
SELECT DISTINCT - - ( 43 ) FROM tab0 AS cor0
----
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5155
SELECT ALL + CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5155
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col1 + - ( col0 ) AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL - col2 + 25 + - 85 FROM tab0
----
-142
-61
-93

query I rowsort
SELECT - - col0 * - col1 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT - 24 + col0 * + col2 AS col0 FROM tab1 AS cor0
----
138
3624
7656

onlyif mysql # use DIV operator for integer division
query I rowsort label-5160
SELECT - 69 DIV col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-6

skipif mysql # not compatible
query I rowsort label-5160
SELECT - 69 / col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-6

query I rowsort
SELECT ALL tab2.col2 * tab2.col0 AS col2 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-5162
SELECT DISTINCT - 56 DIV + ( + col0 ) col0 FROM tab0
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5162
SELECT DISTINCT - 56 / + ( + col0 ) col0 FROM tab0
----
-1
-2
0

query I rowsort
SELECT + + ( + 26 ) FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 53 col1 FROM tab0
----
53
53
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 11 col1 FROM tab0 AS cor0
----
11
11
11

query I rowsort
SELECT ( 91 ) + - col0 FROM tab2
----
12
13
84

query I rowsort
SELECT + col0 + + col0 * col2 AS col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT DISTINCT col2 * + col1 * - col0 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT 30 * + col1 AS col2 FROM tab2 AS cor0
----
1770
510
930

query I rowsort
SELECT DISTINCT 26 * + col2 * col1 FROM tab2
----
16796
21762
39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - cor0.col0 col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL 45 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT + + ( cor0.col0 ) AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + 86 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT + col0 * + cor0.col2 + - col0 AS col0 FROM tab0 cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT col1 * 17 + 67 AS col2 FROM tab2
----
1070
356
594

query I rowsort
SELECT - col2 * + 80 FROM tab2
----
-2080
-2160
-3040

query I rowsort
SELECT + col0 * + 65 AS col0 FROM tab1
----
195
4160
5200

query I rowsort
SELECT ALL - cor1.col2 * - ( 39 ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 4b70e57583cb555cbe186753e1351ffb

query I rowsort
SELECT DISTINCT + - 50 - - col1 FROM tab0 AS cor0
----
36
41
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-5181
SELECT + + col0 * - 14 + col0 * cor0.col0 DIV col0 AS col1 FROM tab0 AS cor0
----
-1157
-312
-455

skipif mysql # not compatible
query I rowsort label-5181
SELECT + + col0 * - 14 + col0 * cor0.col0 / col0 AS col1 FROM tab0 AS cor0
----
-1157
-312
-455

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5182
SELECT + cor0.col2 * col2 + + col0 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5182
SELECT + cor0.col2 * col2 + + col0 * + 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-5183
SELECT - col0 DIV col1 + col2 * + col0 * 3 AS col2 FROM tab0 cor0
----
105
21894
2376

skipif mysql # not compatible
query I rowsort label-5183
SELECT - col0 / col1 + col2 * + col0 * 3 AS col2 FROM tab0 cor0
----
105
21894
2376

query I rowsort
SELECT - 97 + - 26 AS col2 FROM tab1 AS cor0
----
-123
-123
-123

onlyif mysql # use DIV operator for integer division
query I rowsort label-5185
SELECT 52 DIV + col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5185
SELECT 52 / + col0 FROM tab0
----
0
1
2

query I rowsort
SELECT ALL col1 * col0 * + ( 55 ) FROM tab0
----
113520
186725
445445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col0 ) col1 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT ALL - + col2 - - col0 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5189
SELECT DISTINCT + col2 DIV + col0 - 52 FROM tab2
----
-49
-52

skipif mysql # not compatible
query I rowsort label-5189
SELECT DISTINCT + col2 / + col0 - 52 FROM tab2
----
-49
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5190
SELECT 14 + + col2 - + col2 DIV 80 col1 FROM tab0
----
15
47
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5190
SELECT 14 + + col2 - + col2 / 80 col1 FROM tab0
----
15
47
95

query I rowsort
SELECT 21 * tab0.col0 FROM tab0
----
1869
504
735

query I rowsort
SELECT DISTINCT - ( col1 ) - - 35 FROM tab2
----
-24
18
4

query I rowsort
SELECT col2 * + col0 + - ( col2 ) + - col0 AS col0 FROM tab0
----
-1
7127
735

query I rowsort
SELECT - + col0 + ( + 76 + - cor0.col2 ) FROM tab1 AS cor0
----
-100
-45
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-5195
SELECT - + col0 DIV ( + cor0.col0 ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5195
SELECT - + col0 / ( + cor0.col0 ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT ( + 38 ) FROM tab0, tab0 AS cor0
----
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5197
SELECT DISTINCT 46 DIV 51 AS col2 FROM tab1, tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5197
SELECT DISTINCT 46 / 51 AS col2 FROM tab1, tab0 AS cor0
----
0

query I rowsort
SELECT + col1 * + ( - 49 ) - - cor0.col2 * col1 FROM tab1 cor0
----
130
611
80

query I rowsort
SELECT DISTINCT + - col1 + - 8 FROM tab0 AS cor0
----
-105
-94
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-5200
SELECT - col0 * 67 DIV col1 + - col2 AS col2 FROM tab2 AS cor0
----
-114
-349
-42

skipif mysql # not compatible
query I rowsort label-5200
SELECT - col0 * 67 / col1 + - col2 AS col2 FROM tab2 AS cor0
----
-114
-349
-42

query I rowsort
SELECT ALL - + col2 * ( 45 ) AS col0 FROM tab0 AS cor0
----
-1485
-3690
-45

query I rowsort
SELECT ALL cor0.col1 * + col0 * 40 FROM tab2 cor0
----
184080
53720
8680

query I rowsort
SELECT DISTINCT col2 + col2 * + cor0.col2 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5204
SELECT DISTINCT - + col1 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5204
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-5205
SELECT ALL + - col2 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5205
SELECT ALL + - col2 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 * col1 + - 94 FROM tab2 AS cor0
----
-1628
-740
-931

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5207
SELECT col0 * - CAST( col2 AS SIGNED ) + col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif mysql # not compatible
query I rowsort label-5207
SELECT col0 * - CAST ( col2 AS INTEGER ) + col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT col0 + + cor0.col0 * col2 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 cor0 CROSS JOIN tab2 AS cor1
----
243 values hashing to 042fa16c43ab365359ee93c064e44127

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) * - tab1.col0 * col1 col2 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT + col2 * + 51 AS col1 FROM tab0 AS cor0
----
1683
4182
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( - col2 ) * col1 col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5213
SELECT + CAST( cor0.col2 AS SIGNED ) * col0 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-5213
SELECT + CAST ( cor0.col2 AS INTEGER ) * col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col2 * cor0.col1 * + col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT - col0 + col0 - col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + 34 + col0 FROM tab2 AS cor0
----
112
113
41

query I rowsort
SELECT DISTINCT - col2 * col1 - + 79 AS col1 FROM tab2 AS cor0
----
-1613
-725
-916

query I rowsort
SELECT ALL ( + ( - tab2.col1 ) ) FROM tab2
----
-17
-31
-59

query I rowsort
SELECT ALL - 43 * + col2 AS col0 FROM tab0 AS cor0
----
-1419
-3526
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 34 col1 FROM tab1 AS cor0
----
-34

query I rowsort
SELECT - - col2 * col0 + cor0.col2 * + col1 AS col2 FROM tab1 AS cor0
----
1566
4218
8928

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + + col2 * col2 col0 FROM tab1 AS cor0
----
2862
3192
9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col0 ) * - col2 col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - 14 + + col1 FROM tab2 AS cor0
----
17
3
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-5225
SELECT 72 DIV col0 FROM tab2 AS cor0
----
0
0
10

skipif mysql # not compatible
query I rowsort label-5225
SELECT 72 / col0 FROM tab2 AS cor0
----
0
0
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-5226
SELECT col0 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-5226
SELECT col0 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT DISTINCT - col2 + col0 * cor0.col2 * col2 FROM tab2 AS cor0
----
114038
5076
52702

query I rowsort
SELECT + 92 + col2 * col1 FROM tab0
----
189
2930
7554

query I rowsort
SELECT ( col0 ) + col0 FROM tab0
----
178
48
70

query I rowsort
SELECT DISTINCT + + cor0.col2 + + col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT - + ( - col2 ) * - col2 + col2 AS col0 FROM tab0 cor0
----
-1056
-6642
0

query I rowsort
SELECT ALL - col0 + cor0.col2 + + col2 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT DISTINCT - col0 * 79 + + col2 AS col2 FROM tab0 AS cor0
----
-1863
-2764
-6949

query I rowsort
SELECT ALL - col1 + + col1 + - col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + col2 * - col1 * - col1 AS col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5236
SELECT ALL + + CAST( + 94 AS SIGNED ) FROM tab0 AS cor0
----
94
94
94

skipif mysql # not compatible
query I rowsort label-5236
SELECT ALL + + CAST ( + 94 AS INTEGER ) FROM tab0 AS cor0
----
94
94
94

query I rowsort
SELECT ALL - col0 + col1 * col2 * - tab2.col0 FROM tab2
----
-119730
-51113
-5866

query I rowsort
SELECT ALL - ( + col2 + + col2 ) * + col0 * + col2 AS col0 FROM tab2
----
-10206
-105456
-228152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col0 ) * + col1 col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT + ( + col2 + col0 ) FROM tab1
----
121
176
57

query I rowsort
SELECT 38 * - col2 AS col0 FROM tab1 AS cor0
----
-2052
-2166
-3648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 13 col0 FROM tab2, tab2 AS cor0
----
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col1 + + col1 * tab0.col0 col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT col1 * 41 * + tab0.col1 FROM tab0
----
303236
339521
385769

query I rowsort
SELECT ALL 11 * 19 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to bc8e20d5db0743b639103e0b47aad822

query I rowsort
SELECT ALL - col0 * - 32 * col1 AS col0 FROM tab0 AS cor0
----
108640
259168
66048

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * ( cor0.col0 * col1 ) col1 FROM tab2 AS cor0
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-5248
SELECT ALL col1 DIV cor0.col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5248
SELECT ALL col1 / cor0.col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT - col1 + + cor0.col0 * - 64 FROM tab2 AS cor0
----
-479
-5051
-5073

query I rowsort
SELECT DISTINCT - ( col2 ) - - col0 AS col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT - col2 + col0 * - col0 AS col1 FROM tab0 cor0
----
-1226
-609
-8003

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 cor0 WHERE NOT NULL <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5253
SELECT DISTINCT + col2 * ( cor0.col2 ) * - ( 31 ) + - col2 + col1 * - col2 DIV col2 FROM tab1 AS cor0
----
-100786
-285805
-90476

skipif mysql # not compatible
query I rowsort label-5253
SELECT DISTINCT + col2 * ( cor0.col2 ) * - ( 31 ) + - col2 + col1 * - col2 / col2 FROM tab1 AS cor0
----
-100786
-285805
-90476

query I rowsort
SELECT DISTINCT - 0 FROM tab2, tab0, tab0 cor0
----
0

query I rowsort
SELECT ALL + cor0.col1 * + col1 * - ( + col2 * cor0.col1 ) AS col2 FROM tab1 cor0
----
-210912
-57000
-949104

query I rowsort
SELECT ALL + col0 * col2 + 27 FROM tab0 AS cor0
----
62
7325
819

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 27 * - col1 col2 FROM tab2
----
1593
459
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5258
SELECT DISTINCT cor0.col1 DIV col1 + ( - cor0.col1 ) FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-5258
SELECT DISTINCT cor0.col1 / col1 + ( - cor0.col1 ) FROM tab1 AS cor0
----
-12
-25
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5259
SELECT + 57 * col1 + - 45 DIV + 18 AS col0 FROM tab0 cor0
----
4900
5185
5527

skipif mysql # not compatible
query I rowsort label-5259
SELECT + 57 * col1 + - 45 / + 18 AS col0 FROM tab0 cor0
----
4900
5185
5527

onlyif mysql # use DIV operator for integer division
query I rowsort label-5260
SELECT + + col2 DIV + cor0.col0 AS col0 FROM tab2 cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-5260
SELECT + + col2 / + cor0.col0 AS col0 FROM tab2 cor0
----
0
0
3

query I rowsort
SELECT - - col2 + ( - col2 ) AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + col0 + cor0.col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - col2 * ( col2 ) FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col2 + 21 FROM tab0 AS cor0
----
103
22
54

query I rowsort
SELECT ALL + col0 * - 83 FROM tab2 AS cor0
----
-581
-6474
-6557

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5266
SELECT ALL ( tab0.col2 ) * - CAST( NULL AS DECIMAL ) + 5 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5266
SELECT ALL ( tab0.col2 ) * - CAST ( NULL AS REAL ) + 5 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col0 + + ( col2 ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col0 * - 48 FROM tab2 AS cor0
----
336
3744
3792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5269
SELECT DISTINCT - + col0 DIV + col1 AS col1 FROM tab1 AS cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-5269
SELECT DISTINCT - + col0 / + col1 AS col1 FROM tab1 AS cor0
----
-6
0

query I rowsort
SELECT + + col0 * col1 + - col2 FROM tab2 AS cor0
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 5 col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT col1 + ( + cor0.col1 ) * + col1 AS col0 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-5273
SELECT ALL col2 DIV + ( + col2 ) FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5273
SELECT ALL col2 / + ( + col2 ) FROM tab1
----
1
1
1

query I rowsort
SELECT col2 * - 44 AS col0 FROM tab2
----
-1144
-1188
-1672

query I rowsort
SELECT - 30 + col2 AS col1 FROM tab1 AS cor0
----
24
27
66

query I rowsort
SELECT DISTINCT col0 + tab2.col0 * - col0 AS col2 FROM tab2
----
-42
-6006
-6162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5277
SELECT DISTINCT - CAST( NULL AS SIGNED ) + + col1 * col1 AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5277
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + + col1 * col1 AS col2 FROM tab2
----
NULL

query I rowsort
SELECT + 49 - col1 FROM tab0 AS cor0
----
-37
-42
-48

query I rowsort
SELECT 41 + col1 AS col2 FROM tab0 cor0
----
127
132
138

query I rowsort
SELECT + - col2 * col0 - - cor0.col1 * + 77 FROM tab1 AS cor0
----
-2878
-6679
1840

query I rowsort
SELECT - 60 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 1a0b29f8e6f82c54623a665ba4af8fd1

query I rowsort
SELECT + 18 + - col0 AS col1 FROM tab2
----
-60
-61
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 8 * 97 + + col1 col2 FROM tab0
----
862
867
873

query I rowsort
SELECT DISTINCT + 86 + col0 * col2 FROM tab2
----
2114
275
3088

query I rowsort
SELECT + 18 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1602
432
630

query I rowsort
SELECT ALL 32 * col1 + + col0 * col2 FROM tab1 AS cor0
----
3968
8096
994

query I rowsort
SELECT + - col2 + + cor0.col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL + + col1 + col2 * col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL 78 * col2 AS col1 FROM tab0 AS cor0
----
2574
6396
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5290
SELECT DISTINCT + cor0.col1 * col0 DIV ( - col2 + + col0 ) FROM tab0 AS cor0
----
-229
1157
99

skipif mysql # not compatible
query I rowsort label-5290
SELECT DISTINCT + cor0.col1 * col0 / ( - col2 + + col0 ) FROM tab0 AS cor0
----
-229
1157
99

query I rowsort
SELECT DISTINCT + - cor0.col2 * col0 + - col2 * col0 AS col2 FROM tab2 AS cor0
----
-378
-4056
-6004

query I rowsort
SELECT ALL col1 + + 80 * col2 AS col1 FROM tab2 AS cor0
----
2139
2191
3057

query I rowsort
SELECT + col2 + - 23 AS col1 FROM tab0 cor0
----
-22
10
59

query I rowsort
SELECT DISTINCT 98 * + tab1.col1 AS col1 FROM tab1
----
1274
2548
980

query I rowsort
SELECT tab2.col0 + - col2 - col1 * col1 * + col0 AS col2 FROM tab2
----
-22790
-271466
-6747

onlyif mysql # use DIV operator for integer division
query I rowsort label-5296
SELECT - col1 DIV + tab0.col0 + col1 FROM tab0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-5296
SELECT - col1 / + tab0.col0 + col1 FROM tab0
----
83
90
95

query I rowsort
SELECT ALL - cor0.col1 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5298
SELECT DISTINCT CAST( - col0 AS SIGNED ) + col2 FROM tab2 AS cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-5298
SELECT DISTINCT CAST ( - col0 AS INTEGER ) + col2 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5299
SELECT ALL CAST( NULL AS SIGNED ) + col1 + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5299
SELECT ALL CAST ( NULL AS INTEGER ) + col1 + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( ( + col2 ) ) AS col0 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL + col1 * - col2 * - col0 + + col1 FROM tab0 cor0
----
3492
664209
68198

query I rowsort
SELECT ALL + col2 + + 66 * col1 AS col2 FROM tab0
----
5709
6088
6403

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5303
SELECT ALL - col0 + + CAST( - 6 * - col0 AS SIGNED ) AS col0 FROM tab1
----
15
320
400

skipif mysql # not compatible
query I rowsort label-5303
SELECT ALL - col0 + + CAST ( - 6 * - col0 AS INTEGER ) AS col0 FROM tab1
----
15
320
400

query I rowsort
SELECT 86 - + col2 FROM tab1
----
-10
29
32

query I rowsort
SELECT + + col0 + + col2 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5306
SELECT + 29 DIV 6 FROM tab0 AS cor0
----
4
4
4

skipif mysql # not compatible
query I rowsort label-5306
SELECT + 29 / 6 FROM tab0 AS cor0
----
4
4
4

query I rowsort
SELECT - 77 AS col0 FROM tab2 cor0
----
-77
-77
-77

query I rowsort
SELECT DISTINCT + 17 FROM tab1, tab2, tab1 AS cor0
----
17

query I rowsort
SELECT - 10 + - col2 * + tab1.col1 FROM tab1
----
-1258
-1414
-580

query I rowsort
SELECT + 37 * col0 AS col1 FROM tab0 cor0
----
1295
3293
888

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col2 col2 FROM tab1, tab2, tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5312
SELECT ALL - tab2.col0 DIV col1 + - col0 FROM tab2
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-5312
SELECT ALL - tab2.col0 / col1 + - col0 FROM tab2
----
-7
-79
-83

query I rowsort
SELECT ALL 69 + + col1 * - col0 AS col0 FROM tab0
----
-1995
-3326
-8030

query I rowsort
SELECT ALL + + 21 FROM tab0 AS cor0
----
21
21
21

query I rowsort
SELECT - 7 + - col1 FROM tab0
----
-104
-93
-98

query I rowsort
SELECT ALL - - 5 + col2 FROM tab0 AS cor0
----
38
6
87

query I rowsort
SELECT ALL - 8 * col2 + ( cor0.col1 + col0 ) FROM tab0 AS cor0
----
-154
-476
124

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 54 - cor0.col2 col1 FROM tab2 AS cor0
----
16
27
28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5319
SELECT ALL cor0.col1 / col1 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5319
SELECT ALL cor0.col1 / col1 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 13 FROM tab2 cor0
----
13
13
13

query I rowsort
SELECT ALL cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + + ( + col0 ) - + cor0.col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - - col0 * - col2 + col1 * + col2 * - col2 FROM tab1 AS cor0
----
-127488
-36138
-75978

query I rowsort
SELECT ALL - col1 * col2 * + col2 + - col1 + - col1 FROM tab0 AS cor0
----
-291
-612066
-93826

query I rowsort
SELECT ALL - - col1 * + 33 + col1 * + col0 + col1 FROM tab0 AS cor0
----
11193
4988
6693

query I rowsort
SELECT ALL col0 * + 72 - + col0 * col0 FROM tab0 AS cor0
----
-1513
1152
1295

onlyif mysql # use DIV operator for integer division
query I rowsort label-5327
SELECT ALL - col2 DIV - 83 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5327
SELECT ALL - col2 / - 83 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL - col2 + - 22 AS col0 FROM tab0 AS cor0
----
-104
-23
-55

query I rowsort
SELECT - col1 * cor0.col0 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT + col0 + - col2 * - col0 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT cor0.col0 * ( col1 ) * - col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + col2 * cor0.col2 + + col0 AS col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL + cor0.col0 - 21 AS col1 FROM tab0 AS cor0
----
14
3
68

query I rowsort
SELECT - col0 + + ( col1 ) FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT DISTINCT - col2 * col1 * 49 - col1 FROM tab1 AS cor0
----
-27940
-61165
-68822

query I rowsort
SELECT DISTINCT - 41 * - 62 + col2 FROM tab1 AS cor0
----
2596
2599
2638

query I rowsort
SELECT DISTINCT 12 AS col1 FROM tab2, tab0 cor0
----
12

query I rowsort
SELECT ALL - - 14 + col1 FROM tab2 AS cor0
----
31
45
73

query I rowsort
SELECT DISTINCT - + col2 * col0 * col0 + + col0 AS col0 FROM tab1 AS cor0
----
-233408
-483
-614320

query I rowsort
SELECT DISTINCT - - cor0.col1 + col1 + - col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ( + 93 ) FROM tab1 AS cor0
----
93
93
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col2 + + 7 * col0 col2 FROM tab2
----
572
591
76

query I rowsort
SELECT + ( col2 ) * + col0 + - ( col1 ) + col2 FROM tab1 AS cor0
----
190
3695
7763

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 cor2, tab0 cor3
----
3645 values hashing to a02dd7564e9916176c021434a3977a05

query I rowsort
SELECT + col1 + 13 * col0 AS col0 FROM tab0 AS cor0
----
1248
398
552

query I rowsort
SELECT - col2 + 70 FROM tab1 AS cor0
----
-26
13
16

query I rowsort
SELECT col2 + - col0 * + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5348
SELECT - + col2 * + CAST( col2 + + col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-14186
-3927
-98

skipif mysql # not compatible
query I rowsort label-5348
SELECT - + col2 * + CAST ( col2 + + col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-14186
-3927
-98

query I rowsort
SELECT col1 * 39 AS col2 FROM tab2 AS cor0
----
1209
2301
663

query I rowsort
SELECT col0 * - col1 + col1 FROM tab1 cor0
----
-1027
-52
-630

query I rowsort
SELECT - - 46 AS col0 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT DISTINCT + 53 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
53

query I rowsort
SELECT DISTINCT col0 * 45 * - 96 AS col2 FROM tab2 AS cor0
----
-30240
-336960
-341280

query I rowsort
SELECT + - col2 * - 32 AS col0 FROM tab2 AS cor0
----
1216
832
864

query I rowsort
SELECT ALL col1 * + ( col1 ) FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT - col0 * 50 AS col1 FROM tab0 AS cor0
----
-1200
-1750
-4450

query I rowsort
SELECT DISTINCT tab0.col2 * + col1 + col1 FROM tab0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col2 + + col2 + - col2 * + 81 col2 FROM tab0
----
17
198
902

query I rowsort
SELECT DISTINCT - 11 FROM tab1, tab0 AS cor0
----
-11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * ( + col1 ) + col0 col2 FROM tab1
----
1120
704
81

query I rowsort
SELECT + 92 * + col1 AS col0 FROM tab2
----
1564
2852
5428

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) * 71 + + col2 FROM tab1 AS cor0
----
-1792
-653
-827

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + col1 col1 FROM tab0 AS cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( - cor0.col2 ) * - 57 col0 FROM tab1 AS cor0
----
3078
3249
5472

query I rowsort
SELECT + - 79 AS col2 FROM tab0 AS cor0
----
-79
-79
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 * - cor0.col1 col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + ( - col1 ) - - col2 * col2 * - col2 AS col1 FROM tab2 cor0
----
-17635
-19714
-54889

query I rowsort
SELECT + col1 * ( 97 ) + + col2 FROM tab0 AS cor0
----
8375
8909
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-5369
SELECT ALL - col0 + CAST( col1 AS SIGNED ) DIV + col0 AS col2 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-5369
SELECT ALL - col0 + CAST ( col1 AS INTEGER ) / + col0 AS col2 FROM tab1 AS cor0
----
-64
-80
5

query I rowsort
SELECT 76 + - 40 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT ALL col2 * + 30 + 73 FROM tab2 AS cor0
----
1213
853
883

onlyif mysql # use DIV operator for integer division
query I rowsort label-5372
SELECT - cor0.col0 DIV 53 AS col1 FROM tab1 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-5372
SELECT - cor0.col0 / 53 AS col1 FROM tab1 cor0
----
-1
-1
0

query I rowsort
SELECT ALL col2 + col2 * col1 * + col2 AS col2 FROM tab1 AS cor0
----
119904
32547
75870

query I rowsort
SELECT 16 * col1 AS col1 FROM tab0 AS cor0
----
1376
1456
1552

query I rowsort
SELECT 82 + col0 * + col0 AS col1 FROM tab0 AS cor0
----
1307
658
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-5376
SELECT - 47 - col1 DIV + ( 1 ) AS col0 FROM tab1 AS cor0
----
-57
-60
-73

skipif mysql # not compatible
query I rowsort label-5376
SELECT - 47 - col1 / + ( 1 ) AS col0 FROM tab1 AS cor0
----
-57
-60
-73

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 * col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT + - col0 * col1 + + 39 AS col1 FROM tab2 AS cor0
----
-1304
-178
-4563

query I rowsort
SELECT - 17 * - col0 + col1 FROM tab0 cor0
----
1604
494
692

query I rowsort
SELECT + cor0.col1 - - cor0.col0 * col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT ALL col1 * + 54 AS col0 FROM tab1
----
1404
540
702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5382
SELECT DISTINCT CAST( 46 AS SIGNED ) * col0 AS col2 FROM tab2
----
322
3588
3634

skipif mysql # not compatible
query I rowsort label-5382
SELECT DISTINCT CAST ( 46 AS INTEGER ) * col0 AS col2 FROM tab2
----
322
3588
3634

query I rowsort
SELECT ALL col1 * 22 FROM tab0
----
1892
2002
2134

query I rowsort
SELECT ALL tab2.col2 * - ( - 7 * - col1 ) FROM tab2
----
-10738
-4522
-5859

query I rowsort
SELECT - col1 + ( - col2 * col2 ) FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT + + col0 + - 24 AS col1 FROM tab2 cor0
----
-17
54
55

query I rowsort
SELECT ( - col1 ) * + col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - col0 + 92 * - cor0.col0 FROM tab2 AS cor0
----
-651
-7254
-7347

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 * - col2 col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT + - 26 + + col2 * col2 * + col1 FROM tab1 AS cor0
----
119782
32464
75790

onlyif mysql # use DIV operator for integer division
query I rowsort label-5391
SELECT ALL 43 * col0 + + col1 + col1 DIV col1 AS col0 FROM tab0 AS cor0
----
1119
1603
3919

skipif mysql # not compatible
query I rowsort label-5391
SELECT ALL 43 * col0 + + col1 + col1 / col1 AS col0 FROM tab0 AS cor0
----
1119
1603
3919

query I rowsort
SELECT ALL - - ( 10 ) AS col0 FROM tab1 AS cor0
----
10
10
10

query I rowsort
SELECT DISTINCT - 39 * - 40 FROM tab1 AS cor0
----
1560

query I rowsort
SELECT - col1 * - col2 + 53 AS col2 FROM tab2 cor0
----
1587
699
890

query I rowsort
SELECT col2 * - col1 + 42 * - cor0.col1 FROM tab2 AS cor0
----
-1360
-2139
-4012

query I rowsort
SELECT DISTINCT + cor0.col2 * col0 + + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-5397
SELECT - 51 DIV + col1 + + col0 + cor0.col0 * + col1 FROM tab2 cor0
----
1419
223
4680

skipif mysql # not compatible
query I rowsort label-5397
SELECT - 51 / + col1 + + col0 + cor0.col0 * + col1 FROM tab2 cor0
----
1419
223
4680

query I rowsort
SELECT + - 78 * col2 + + 86 * col0 AS col1 FROM tab0 AS cor0
----
-510
1258
2932

query I rowsort
SELECT - - 49 - - col1 AS col1 FROM tab1 AS cor0
----
59
62
75

query I rowsort
SELECT ALL col1 * col0 * - 96 FROM tab2 AS cor0
----
-128928
-20832
-441792

query I rowsort
SELECT DISTINCT 30 + col1 FROM tab0
----
116
121
127

query I rowsort
SELECT 98 * - col1 + col0 FROM tab2
----
-1587
-3031
-5704

onlyif mysql # use DIV operator for integer division
query I rowsort label-5403
SELECT - 0 DIV cor0.col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5403
SELECT - 0 / cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 40 + col0 AS col1 FROM tab0 AS cor0
----
129
64
75

query I rowsort
SELECT + col1 + col1 * col1 AS col0 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT - + ( col0 ) + 79 * cor0.col2 FROM tab2 AS cor0
----
1976
2126
2923

query I rowsort
SELECT ALL cor0.col1 + - 43 FROM tab2, tab0 AS cor0
----
9 values hashing to 41ba0b61b089dbdfad7656e5a37ecf09

onlyif mysql # use DIV operator for integer division
query I rowsort label-5408
SELECT col0 DIV - 39 + - col0 AS col2 FROM tab1 AS cor0
----
-3
-65
-82

skipif mysql # not compatible
query I rowsort label-5408
SELECT col0 / - 39 + - col0 AS col2 FROM tab1 AS cor0
----
-3
-65
-82

query I rowsort
SELECT + col2 - + col2 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + col2 + ( col1 ) FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + 46 col1 FROM tab1 AS cor0
----
-11
-50
-8

query I rowsort
SELECT DISTINCT col0 + - 66 * col2 AS col1 FROM tab0 AS cor0
----
-2154
-31
-5323

query I rowsort
SELECT ALL + col2 * col2 + col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5414
SELECT DISTINCT - col2 * + CAST( col1 AS SIGNED ) * col1 + + 83 FROM tab1 cor0
----
-16141
-36421
-5617

skipif mysql # not compatible
query I rowsort label-5414
SELECT DISTINCT - col2 * + CAST ( col1 AS INTEGER ) * col1 + + 83 FROM tab1 cor0
----
-16141
-36421
-5617

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 83 + - col1 col1 FROM tab2
----
24
52
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5416
SELECT ALL - tab1.col1 DIV - col2 + - col2 AS col0 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5416
SELECT ALL - tab1.col1 / - col2 + - col2 AS col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT + 12 * + tab0.col1 * - tab0.col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 8657dd79d34a3c5b3fc53dfec3c0305a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col0 * + col0 col2 FROM tab1
----
35
4106
6413

query I rowsort
SELECT ALL + col1 + - col2 + - col2 FROM tab1
----
-104
-179
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5420
SELECT 93 - col1 DIV + col1 FROM tab1
----
92
92
92

skipif mysql # not compatible
query I rowsort label-5420
SELECT 93 - col1 / + col1 FROM tab1
----
92
92
92

query I rowsort
SELECT ALL + cor0.col2 * - 46 + col1 * col0 AS col0 FROM tab2 AS cor0
----
-1025
-405
3406

query I rowsort
SELECT DISTINCT + cor0.col1 * - ( - cor0.col1 + + col0 ) FROM tab0 AS cor0
----
182
5332
6014

query I rowsort
SELECT + col1 + + 88 * col2 AS col1 FROM tab1 AS cor0
----
4778
5026
8461

onlyif mysql # use DIV operator for integer division
query I rowsort label-5424
SELECT DISTINCT col2 DIV + 41 + col0 * col2 AS col1 FROM tab1 AS cor0
----
163
3649
7682

skipif mysql # not compatible
query I rowsort label-5424
SELECT DISTINCT col2 / + 41 + col0 * col2 AS col1 FROM tab1 AS cor0
----
163
3649
7682

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 DISTINCT + col1 + - ( - cor0.col2 ) * col0 * col2 FROM tab2 AS cor0
----
114093
5134
52787

onlyif mysql # use DIV operator for integer division
query I rowsort label-5427
SELECT col0 * + ( 27 ) + - cor0.col2 DIV - col2 FROM tab0 AS cor0
----
2404
649
946

skipif mysql # not compatible
query I rowsort label-5427
SELECT col0 * + ( 27 ) + - cor0.col2 / - col2 FROM tab0 AS cor0
----
2404
649
946

query I rowsort
SELECT ALL + col0 * - ( + col2 ) AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - - ( 55 ) + - col0 + 14 AS col2 FROM tab2 cor0
----
-10
-9
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5430
SELECT ALL + col0 DIV col2 - cor0.col0 AS col2 FROM tab1 AS cor0
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-5430
SELECT ALL + col0 / col2 - cor0.col0 AS col2 FROM tab1 AS cor0
----
-3
-63
-80

query I rowsort
SELECT ALL + ( 14 ) AS col1 FROM tab0
----
14
14
14

query I rowsort
SELECT - col2 * + col2 - + col2 AS col2 FROM tab2 cor0
----
-1482
-702
-756

query I rowsort
SELECT col2 + col2 * col2 AS col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL - 36 + col1 FROM tab1 AS cor0
----
-10
-23
-26

query I rowsort
SELECT - 55 + col2 + + col2 * col1 * col0 FROM tab2 AS cor0
----
119623
51017
5831

query I rowsort
SELECT + cor0.col2 * 16 AS col0 FROM tab0 AS cor0
----
1312
16
528

query I rowsort
SELECT DISTINCT + col0 * ( col0 ) AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + col1 + 39 + - col2 * col2 AS col1 FROM tab2 AS cor0
----
-1388
-578
-659

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5439
SELECT + + col2 * col1 + col1 + - CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5439
SELECT + + col2 * col1 + col1 + - CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col1 * + 70 FROM tab1 AS cor0
----
1820
700
910

query I rowsort
SELECT 87 - - cor0.col1 AS col0 FROM tab0 AS cor0
----
173
178
184

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5442
SELECT - col1 + CAST( + col1 AS SIGNED ) AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5442
SELECT - col1 + CAST ( + col1 AS INTEGER ) AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + tab2.col2 + col0 + + tab2.col2 AS col0 FROM tab2
----
130
155
61

query I rowsort
SELECT - tab1.col2 * - col1 + col1 AS col0 FROM tab1
----
1261
1430
580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5445
SELECT - col2 + CAST( NULL AS SIGNED ) + 37 / - col0 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5445
SELECT - col2 + CAST ( NULL AS INTEGER ) + 37 / - col0 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + ( col1 ) AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + 2 * 2 FROM tab0
----
4
4
4

query I rowsort
SELECT + col1 + + cor0.col1 AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT - col0 + col2 * + col0 + col1 AS col1 FROM tab2
----
2009
213
2940

query I rowsort
SELECT ALL col1 * + col0 * - tab2.col0 FROM tab2
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col2 * ( + col0 ) + - col0 col0 FROM tab0
----
-1260
-19032
-649611

query I rowsort
SELECT 91 AS col0 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

query I rowsort
SELECT col1 * + col0 * 77 FROM tab0
----
158928
261415
623623

query I rowsort
SELECT DISTINCT - tab1.col0 + + tab1.col0 + + col0 * col1 * + col0 AS col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT - col1 * ( - 73 ) * col0 AS col0 FROM tab0
----
150672
247835
591227

query I rowsort
SELECT ALL + cor0.col1 * 75 + 64 FROM tab2 AS cor0
----
1339
2389
4489

query I rowsort
SELECT DISTINCT + col0 + - 50 AS col0 FROM tab2 AS cor0
----
-43
28
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 25 col1 FROM tab2 cor0
----
175
1950
1975

query I rowsort
SELECT cor1.col2 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL - col0 * + 35 AS col2 FROM tab1 AS cor0
----
-105
-2240
-2800

query I rowsort
SELECT DISTINCT + tab1.col1 * + 52 FROM tab1, tab0 AS cor0
----
1352
520
676

query I rowsort
SELECT ALL - cor0.col1 * - cor0.col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 2afdaba7b80c700b7635230c4f8524be

onlyif mysql # use DIV operator for integer division
query I rowsort label-5463
SELECT 57 - 12 DIV - tab1.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 70092a986bc161925253161975dd6238

skipif mysql # not compatible
query I rowsort label-5463
SELECT 57 - 12 / - tab1.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 70092a986bc161925253161975dd6238

query I rowsort
SELECT ALL - 40 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 01aad4539198a6509248e086869f90a6

query I rowsort
SELECT DISTINCT tab0.col2 * cor0.col2 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to a477aa402dcd904394a585dfd5cfe837

query I rowsort
SELECT DISTINCT - 41 * + 40 - tab1.col2 * + 33 AS col1 FROM tab1
----
-3422
-3521
-4808

query I rowsort
SELECT - - ( + col2 ) + - col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ( - col0 ) - tab2.col0 * - col1 AS col0 FROM tab2
----
1264
210
4524

query I rowsort
SELECT + + col1 * col0 - - col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT + 51 + cor0.col2 FROM tab1 AS cor0
----
105
108
147

onlyif mysql # use DIV operator for integer division
query I rowsort label-5471
SELECT + col2 + + col2 DIV cor0.col1 - cor0.col2 AS col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5471
SELECT + col2 + + col2 / cor0.col1 - cor0.col2 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 68 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 6fbba7db5bccb533a35aa5125a231f88

query I rowsort
SELECT - tab2.col1 + + 44 * - 56 FROM tab2, tab2 AS cor0
----
9 values hashing to 217d133422fc4155deda8a7e67b74e32

query I rowsort
SELECT + 70 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5475
SELECT + CAST( 31 AS SIGNED ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

skipif mysql # not compatible
query I rowsort label-5475
SELECT + CAST ( 31 AS INTEGER ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT DISTINCT - 55 + + col1 FROM tab0 AS cor0
----
31
36
42

query I rowsort
SELECT + cor0.col1 AS col0 FROM tab1, tab1 cor0, tab1 AS cor1, tab1 cor2
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 70 col0 FROM tab1 AS cor0
----
-70
-70
-70

query I rowsort
SELECT col1 * + cor0.col1 * 82 AS col0 FROM tab1 AS cor0
----
13858
55432
8200

query I rowsort
SELECT col2 + + col0 * - col1 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT - col0 * + col1 + col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT - + col1 * + ( + col2 ) FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5483
SELECT ALL CAST( NULL AS SIGNED ) + - tab0.col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5483
SELECT ALL CAST ( NULL AS INTEGER ) + - tab0.col1 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + - cor0.col0 * col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + 40 + + cor0.col1 * cor0.col0 * + col0 FROM tab2 AS cor0
----
106137
1559
358996

query I rowsort
SELECT tab0.col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + + ( cor0.col0 ) * col2 + 97 AS col2 FROM tab2 AS cor0
----
2125
286
3099

query I rowsort
SELECT + - cor0.col0 * - 73 FROM tab1 AS cor0
----
219
4672
5840

query I rowsort
SELECT 75 * col0 + col1 * ( 63 ) FROM tab1 AS cor0
----
1863
5430
6819

onlyif mysql # use DIV operator for integer division
query I rowsort label-5490
SELECT 22 + col0 + col2 DIV col0 FROM tab2
----
100
101
32

skipif mysql # not compatible
query I rowsort label-5490
SELECT 22 + col0 + col2 / col0 FROM tab2
----
100
101
32

query I rowsort
SELECT DISTINCT - 67 AS col1 FROM tab0, tab1 AS cor0
----
-67

query I rowsort
SELECT ALL 93 * - col1 FROM tab1
----
-1209
-2418
-930

query I rowsort
SELECT - 86 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 9d2e1e8eda15b3b83dd7136dfc4f19af

query I rowsort
SELECT DISTINCT + ( col0 ) * col2 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col2 + col2 * - ( + col0 * + col1 ) + - col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT - cor0.col2 + - col0 * col1 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT - col2 + col2 * + ( col2 * cor0.col1 + cor0.col0 ) FROM tab0 AS cor0
----
131
619100
94413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5498
SELECT ALL CAST( 15 + cor0.col1 AS SIGNED ) FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ba4076843bb5759d0c00d4a48a9fe2b1

skipif mysql # not compatible
query I rowsort label-5498
SELECT ALL CAST ( 15 + cor0.col1 AS INTEGER ) FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ba4076843bb5759d0c00d4a48a9fe2b1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5499
SELECT DISTINCT + + 95 + - col1 DIV col2 AS col2 FROM tab1 AS cor0
----
95

skipif mysql # not compatible
query I rowsort label-5499
SELECT DISTINCT + + 95 + - col1 / col2 AS col2 FROM tab1 AS cor0
----
95

query I rowsort
SELECT col2 + - 93 * + col2 AS col2 FROM tab1
----
-4968
-5244
-8832

query I rowsort
SELECT DISTINCT tab0.col0 - + col1 * col1 AS col1 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT col0 + 58 AS col1 FROM tab2
----
136
137
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 99 + col1 col1 FROM tab1 cor0
----
323
6346
7933

onlyif mysql # use DIV operator for integer division
query I rowsort label-5504
SELECT + tab1.col2 DIV + col0 - col0 col0 FROM tab1
----
-64
-79
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5504
SELECT + tab1.col2 / + col0 - col0 col0 FROM tab1
----
-64
-79
15

query I rowsort
SELECT DISTINCT col2 - 67 AS col0 FROM tab2
----
-29
-40
-41

query I rowsort
SELECT ALL + 77 * - cor1.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to ccfa2ab8230e9528746d9fe9f09df112

query I rowsort
SELECT ALL + cor0.col1 - - ( col0 ) AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL - col1 * - col1 + 64 - + cor0.col1 FROM tab1 AS cor0
----
154
220
714

query I rowsort
SELECT - col0 * + ( - cor0.col2 ) * + cor0.col2 AS col2 FROM tab2 AS cor0
----
114076
5103
52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) - - col0 * cor0.col0 col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL cor0.col0 + col1 * + cor0.col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT + 79 * col2 + col2 FROM tab2 cor0
----
2080
2160
3040

query I rowsort
SELECT ALL + ( + col2 ) + + cor0.col1 * - col0 AS col0 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5514
SELECT ALL CAST( - col1 AS SIGNED ) * + col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-5514
SELECT ALL CAST ( - col1 AS INTEGER ) * + col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 79 + - cor0.col1 * - col1 * - col1 col2 FROM tab0 AS cor0
----
-636135
-753650
-912752

query I rowsort
SELECT ALL - 43 + 66 AS col0 FROM tab2 AS cor0
----
23
23
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 - - col1 col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT - - cor0.col2 * + col2 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-5519
SELECT ALL ( col1 ) + col1 DIV cor0.col0 FROM tab2 AS cor0
----
17
35
59

skipif mysql # not compatible
query I rowsort label-5519
SELECT ALL ( col1 ) + col1 / cor0.col0 FROM tab2 AS cor0
----
17
35
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 * cor0.col2 + col0 col1 FROM tab1 AS cor0
----
-3183
-3299
-5584

query I rowsort
SELECT DISTINCT 33 + 41 AS col0 FROM tab0 AS cor0
----
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-5522
SELECT 68 - col1 DIV col0 AS col2 FROM tab2 AS cor0
----
64
68
68

skipif mysql # not compatible
query I rowsort label-5522
SELECT 68 - col1 / col0 AS col2 FROM tab2 AS cor0
----
64
68
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-5523
SELECT ALL 94 DIV col2 + + col0 FROM tab1 AS cor0
----
4
65
80

skipif mysql # not compatible
query I rowsort label-5523
SELECT ALL 94 / col2 + + col0 FROM tab1 AS cor0
----
4
65
80

query I rowsort
SELECT DISTINCT 55 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
55

query I rowsort
SELECT DISTINCT + col0 * - col2 * - col0 AS col2 FROM tab1 AS cor0
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * ( cor0.col0 ) col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5527
SELECT ALL - 18 DIV 15 + tab1.col0 AS col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-5527
SELECT ALL - 18 / 15 + tab1.col0 AS col0 FROM tab1
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col2 * + col2 col1 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT ALL - 31 FROM tab1 AS cor0
----
-31
-31
-31

query I rowsort
SELECT + ( - col1 ) - cor0.col0 * col1 AS col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col0 + col1 col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT + 6 - + col1 AS col1 FROM tab1 AS cor0
----
-20
-4
-7

query I rowsort
SELECT - + cor0.col1 * + col0 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5534
SELECT 64 + col1 DIV col0 + + col1 col0 FROM tab1
----
74
77
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5534
SELECT 64 + col1 / col0 + + col1 col0 FROM tab1
----
74
77
98

query I rowsort
SELECT - ( col2 ) * col0 AS col2 FROM tab2
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5536
SELECT CAST( 59 AS SIGNED ) * col0 + + col1 FROM tab1
----
203
3786
4733

skipif mysql # not compatible
query I rowsort label-5536
SELECT CAST ( 59 AS INTEGER ) * col0 + + col1 FROM tab1
----
203
3786
4733

query I rowsort
SELECT - - col0 * - col0 * - cor0.col1 + - col1 FROM tab0 AS cor0
----
118728
49450
720720

query I rowsort
SELECT + + 61 + col2 * + col2 AS col1 FROM tab2 cor0
----
1505
737
790

query I rowsort
SELECT - ( - col2 ) + + cor0.col2 AS col0 FROM tab1 cor0
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 + col1 * col1 col0 FROM tab2
----
272
3422
930

query I rowsort
SELECT DISTINCT 12 + col1 AS col2 FROM tab0
----
103
109
98

query I rowsort
SELECT DISTINCT ( + col2 ) + + tab1.col1 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT + 10 * col0 + - col0 + + col1 * col1 FROM tab2
----
1000
1024
4183

query I rowsort
SELECT DISTINCT + col1 * + col2 + col0 * - col0 FROM tab0
----
-1128
-459
2262

query I rowsort
SELECT DISTINCT col1 + - 45 AS col2 FROM tab0
----
41
46
52

query I rowsort
SELECT DISTINCT col0 + + 82 + + col0 FROM tab2
----
238
240
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5547
SELECT ALL 80 * 84 DIV + col2 + col1 col2 FROM tab1
----
127
150
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5547
SELECT ALL 80 * 84 / + col2 + col1 col2 FROM tab1
----
127
150
83

query I rowsort
SELECT ALL - col2 * 92 FROM tab0 cor0
----
-3036
-7544
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5549
SELECT DISTINCT - col1 + - col1 + - 12 DIV col0 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

skipif mysql # not compatible
query I rowsort label-5549
SELECT DISTINCT - col1 + - col1 + - 12 / col0 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT + + col2 * 74 + col1 AS col0 FROM tab1 AS cor0
----
4022
4228
7117

query I rowsort
SELECT + col2 + - ( col1 ) AS col0 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5552
SELECT ALL col1 DIV col1 col0 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5552
SELECT ALL col1 / col1 col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + col0 + ( + 91 ) AS col0 FROM tab1 AS cor0
----
155
171
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-5554
SELECT 14 * col0 + col0 DIV - 97 FROM tab0
----
1246
336
490

skipif mysql # not compatible
query I rowsort label-5554
SELECT 14 * col0 + col0 / - 97 FROM tab0
----
1246
336
490

query I rowsort
SELECT tab1.col2 * - col0 + col2 * col1 FROM tab1
----
-3078
-6432
1242

query I rowsort
SELECT ALL 90 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * tab1.col0 col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL col2 * ( 1 ) FROM tab0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5559
SELECT DISTINCT - col0 / + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5559
SELECT DISTINCT - col0 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + + col0 * ( + col1 ) FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - + col0 + - 82 * ( - col0 ) AS col1 FROM tab0 AS cor0
----
1944
2835
7209

query I rowsort
SELECT DISTINCT + 91 + 90 FROM tab2, tab2 AS cor0
----
181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5563
SELECT + - col1 * CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-5563
SELECT + - col1 * CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL col0 * col1 + - 38 FROM tab2 AS cor0
----
1305
179
4564

query I rowsort
SELECT ALL ( + col1 * 46 ) FROM tab2
----
1426
2714
782

query I rowsort
SELECT DISTINCT + tab0.col0 * + col1 + col0 * - tab0.col1 AS col2 FROM tab0
----
0

query I rowsort
SELECT DISTINCT 73 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
73

query I rowsort
SELECT DISTINCT - 41 * + tab1.col1 + - ( - col2 ) * col0 FROM tab1
----
-904
3238
7147

onlyif mysql # use DIV operator for integer division
query I rowsort label-5569
SELECT ALL col1 DIV - col1 + + col2 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-5569
SELECT ALL col1 / - col1 + + col2 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT ALL ( col1 ) + cor0.col1 * + col2 * + col1 FROM tab1 AS cor0
----
16237
36530
5710

query I rowsort
SELECT ALL col1 * cor0.col1 - 91 FROM tab1 AS cor0
----
585
78
9

query I rowsort
SELECT ALL - 82 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to ce62f59690969f4492d78eb57c3181f0

query I rowsort
SELECT - col2 - 92 FROM tab2 AS cor0
----
-118
-119
-130

query I rowsort
SELECT col2 * + col0 + col2 * + col0 AS col2 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT - cor0.col2 + + col2 * - cor0.col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT col1 + - cor0.col1 - col2 * - col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL cor0.col1 * - 80 FROM tab0, tab2 AS cor0
----
9 values hashing to 5fd7b7d8283c4f49bf7ab3491266a718

query I rowsort
SELECT - + col1 * cor0.col2 + + col0 AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - cor0.col0 ) * + col1 col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - 87 * + 93 AS col0 FROM tab0 AS cor0
----
-8091
-8091
-8091

query I rowsort
SELECT ALL + - ( col2 ) * - col0 * + col0 AS col0 FROM tab1 AS cor0
----
233472
486
614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-5582
SELECT DISTINCT - + col2 DIV + 91 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-5582
SELECT DISTINCT - + col2 / + 91 FROM tab2 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 12 * - col1 col1 FROM tab2 AS cor0
----
-204
-372
-708

query I rowsort
SELECT - 14 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-1344
-756
-798

query I rowsort
SELECT DISTINCT + 16 * + 90 FROM tab1 AS cor0
----
1440

query I rowsort
SELECT - 17 * - 12 FROM tab0 AS cor0
----
204
204
204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 68 + + 83 col0 FROM tab1 AS cor0
----
151
151
151

onlyif mysql # use DIV operator for integer division
query I rowsort label-5588
SELECT + + cor0.col0 DIV - 90 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5588
SELECT + + cor0.col0 / - 90 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 44 * cor0.col1 FROM tab1 cor0
----
-1144
-440
-572

query I rowsort
SELECT - 54 * col1 AS col2 FROM tab0 AS cor0
----
-4644
-4914
-5238

query I rowsort
SELECT ( 33 ) AS col0 FROM tab1
----
33
33
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 33 col1 FROM tab1
----
33
33
33

query I rowsort
SELECT DISTINCT - - 86 + + col0 * col2 FROM tab2 AS cor0
----
2114
275
3088

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 56 * + col1 col2 FROM tab0 AS cor0
----
4816
5096
5432

query I rowsort
SELECT - cor0.col0 * + cor0.col2 * 79 AS col0 FROM tab0 AS cor0
----
-2765
-576542
-62568

query I rowsort
SELECT DISTINCT + + 95 + + col1 * - cor0.col0 FROM tab1 AS cor0
----
-545
-945
17

query I rowsort
SELECT - tab0.col2 * col2 - + col1 FROM tab0
----
-1175
-6815
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5598
SELECT DISTINCT 25 * - col0 + + col1 DIV col0 FROM tab0 cor0
----
-2224
-597
-873

skipif mysql # not compatible
query I rowsort label-5598
SELECT DISTINCT 25 * - col0 + + col1 / col0 FROM tab0 cor0
----
-2224
-597
-873

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5599
SELECT ALL + - CAST( 9 AS SIGNED ) col2 FROM tab0 AS cor0
----
-9
-9
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5599
SELECT ALL + - CAST ( 9 AS INTEGER ) col2 FROM tab0 AS cor0
----
-9
-9
-9

query I rowsort
SELECT tab0.col2 * + 12 FROM tab0
----
12
396
984

query I rowsort
SELECT col0 * ( + 20 ) AS col0 FROM tab0
----
1780
480
700

query I rowsort
SELECT + col1 * 81 AS col1 FROM tab2
----
1377
2511
4779

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5603
SELECT ALL CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5603
SELECT ALL CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT col1 * - tab2.col2 * + tab2.col0 AS col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT + 77 + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to bba0731ba42b38962db8f11e4291e0fd

onlyif mysql # use DIV operator for integer division
query I rowsort label-5606
SELECT DISTINCT - col2 DIV 63 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-5606
SELECT DISTINCT - col2 / 63 FROM tab2
----
0

query I rowsort
SELECT + 29 + 91 FROM tab1
----
120
120
120

onlyif mysql # use DIV operator for integer division
query I rowsort label-5608
SELECT + col2 DIV col1 + - col2 AS col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5608
SELECT + col2 / col1 + - col2 AS col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - 3 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT DISTINCT col0 * - 32 FROM tab2
----
-224
-2496
-2528

onlyif mysql # use DIV operator for integer division
query I rowsort label-5611
SELECT DISTINCT 55 DIV - col1 FROM tab2
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-5611
SELECT DISTINCT 55 / - col1 FROM tab2
----
-1
-3
0

query I rowsort
SELECT + 47 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT ( 48 ) FROM tab0
----
48
48
48

query I rowsort
SELECT col0 * + ( tab2.col0 ) AS col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT + ( - 19 ) AS col0 FROM tab0 AS cor0
----
-19
-19
-19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * cor0.col2 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to b2e5b025b1c725661248b0f29aaef908

onlyif mysql # use DIV operator for integer division
query I rowsort label-5617
SELECT - + col0 DIV - col1 + col1 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-5617
SELECT - + col0 / - col1 + col1 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) + + col2 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT + col2 + - col1 * - col1 * 34 FROM tab2 AS cor0
----
118380
32701
9864

query I rowsort
SELECT - + col2 * 8 FROM tab2 cor0
----
-208
-216
-304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor1.col0 col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT + 48 + tab2.col0 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to e1c5d95d21b563870681cef9ea606114

query I rowsort
SELECT ALL col0 + + col0 - - 62 FROM tab1
----
190
222
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5624
SELECT col0 * - CAST( NULL AS DECIMAL ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5624
SELECT col0 * - CAST ( NULL AS REAL ) AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * + 55 + 81 - + col1 AS col2 FROM tab1
----
220
3591
4468

query I rowsort
SELECT DISTINCT ( col1 ) + - col1 + 90 AS col0 FROM tab2
----
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5627
SELECT CAST( col0 AS SIGNED ) * col0 col2 FROM tab0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5627
SELECT CAST ( col0 AS INTEGER ) * col0 col2 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - 63 + + col2 * col2 AS col0 FROM tab1
----
2853
3186
9153

query I rowsort
SELECT col1 * - col0 + col1 AS col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT col0 + - ( col0 ) + tab2.col0 AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT + ( + 1 ) + col2 * + col1 + - col2 FROM tab2
----
1509
609
811

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0, tab1 cor1, tab1, tab1 cor2
----
3645 values hashing to 44545a6297aa29bb730ffb907c13bc58

query I rowsort
SELECT + + cor0.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # use DIV operator for integer division
query I rowsort label-5634
SELECT ALL + 54 + tab0.col2 DIV 23 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 7ea10a9ab1261ccf1c9effb1ebaae85f

skipif mysql # not compatible
query I rowsort label-5634
SELECT ALL + 54 + tab0.col2 / 23 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 7ea10a9ab1261ccf1c9effb1ebaae85f

query I rowsort
SELECT DISTINCT - cor1.col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-3
-64
-80

query I rowsort
SELECT - 28 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to eac00a95d734c7071360ed392c3f39bc

query I rowsort
SELECT + col1 * + 15 AS col1 FROM tab1 AS cor0
----
150
195
390

query I rowsort
SELECT DISTINCT cor0.col2 * ( 70 ) * + col0 FROM tab1 AS cor0
----
11340
255360
537600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5639
SELECT DISTINCT col2 + 23 DIV - cor0.col0 col1 FROM tab1 AS cor0
----
47
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5639
SELECT DISTINCT col2 + 23 / - cor0.col0 col1 FROM tab1 AS cor0
----
47
57
96

query I rowsort
SELECT - + cor0.col2 * ( + 63 ) FROM tab1 AS cor0
----
-3402
-3591
-6048

query I rowsort
SELECT ALL + - col0 * - col2 + + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL col1 * + 66 + - col1 FROM tab0 cor0
----
5590
5915
6305

query I rowsort
SELECT DISTINCT - + col2 * 69 AS col2 FROM tab1 AS cor0
----
-3726
-3933
-6624

query I rowsort
SELECT ALL - cor0.col2 - + col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT cor0.col2 - 99 * - cor0.col0 AS col2 FROM tab2 cor0
----
720
7748
7859

onlyif mysql # use DIV operator for integer division
query I rowsort label-5646
SELECT ALL + col1 DIV 15 + + col1 * col1 + + col2 * + col1 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
123136
51324
6822

skipif mysql # not compatible
query I rowsort label-5646
SELECT ALL + col1 / 15 + + col1 * col1 + + col2 * + col1 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
123136
51324
6822

onlyif mysql # use DIV operator for integer division
query I rowsort label-5647
SELECT + cor0.col1 + + col1 DIV 45 FROM tab0 AS cor0
----
87
93
99

skipif mysql # not compatible
query I rowsort label-5647
SELECT + cor0.col1 + + col1 / 45 FROM tab0 AS cor0
----
87
93
99

query I rowsort
SELECT DISTINCT - - cor0.col1 * + 48 AS col1 FROM tab2 AS cor0
----
1488
2832
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-5649
SELECT ALL - col2 DIV cor0.col1 + - ( col0 * col1 ) FROM tab0 cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-5649
SELECT ALL - col2 / cor0.col1 + - ( col0 * col1 ) FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - ( + 93 ) AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5651
SELECT col2 * - col1 + 39 DIV - tab2.col0 FROM tab2
----
-1534
-646
-842

skipif mysql # not compatible
query I rowsort label-5651
SELECT col2 * - col1 + 39 / - tab2.col0 FROM tab2
----
-1534
-646
-842

query I rowsort
SELECT DISTINCT - col0 * - tab2.col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT cor0.col2 * 66 AS col0 FROM tab1 AS cor0
----
3564
3762
6336

query I rowsort
SELECT DISTINCT + col2 + 81 AS col0 FROM tab1 AS cor0
----
135
138
177

query I rowsort
SELECT col0 * col2 * + col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL col0 - - cor0.col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT cor0.col0 * + 67 * + 34 FROM tab1 cor0
----
145792
182240
6834

query I rowsort
SELECT DISTINCT - - col0 + - col2 * col1 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT + cor0.col0 + ( - col1 ) AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - col0 * - col2 + - col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5661
SELECT ALL 61 DIV 46 + - col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-5661
SELECT ALL 61 / 46 + - col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT DISTINCT 59 * + col2 * - col0 + + ( + cor0.col0 * col2 ) AS col0 FROM tab1 cor0
----
-211584
-445440
-9396

query I rowsort
SELECT DISTINCT - + col2 + - col1 * + col0 - col1 * col1 FROM tab2 AS cor0
----
-1205
-1670
-8109

query I rowsort
SELECT - col2 * 14 FROM tab1 cor0
----
-1344
-756
-798

onlyif mysql # use DIV operator for integer division
query I rowsort label-5665
SELECT ALL + col1 DIV ( cor0.col1 ) + 85 FROM tab0 AS cor0
----
86
86
86

skipif mysql # not compatible
query I rowsort label-5665
SELECT ALL + col1 / ( cor0.col1 ) + 85 FROM tab0 AS cor0
----
86
86
86

query I rowsort
SELECT ALL + - col0 * + 61 + - col1 * col1 AS col1 FROM tab2 AS cor0
----
-1388
-5108
-8239

query I rowsort
SELECT ( + col0 ) * - col2 + - ( - 55 ) FROM tab1 AS cor0
----
-107
-3593
-7625

query I rowsort
SELECT DISTINCT - - ( + ( + col2 - + cor0.col0 ) ) * col0 + col0 - + ( ( + col1 ) + col2 ) FROM tab1 AS cor0
----
-451
1251
76

query I rowsort
SELECT 59 - + 87 * + cor0.col0 AS col1 FROM tab2 cor0
----
-550
-6727
-6814

query I rowsort
SELECT ALL - + 11 * col0 * col2 + col0 AS col1 FROM tab1 AS cor0
----
-1779
-40064
-84400

query I rowsort
SELECT DISTINCT + cor0.col1 + - col0 * col2 - col1 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - 45 * + ( col0 ) FROM tab2 AS cor0
----
-315
-3510
-3555

query I rowsort
SELECT + col0 * 17 + ( + col2 ) FROM tab0
----
1595
441
596

query I rowsort
SELECT DISTINCT 69 * 27 AS col2 FROM tab2, tab2 AS cor0
----
1863

query I rowsort
SELECT - 79 * col1 AS col0 FROM tab1 AS cor0
----
-1027
-2054
-790

query I rowsort
SELECT ( ( + col0 ) ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5677
SELECT - + 54 + cor0.col0 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5677
SELECT - + 54 + cor0.col0 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 30 col2 FROM tab0 AS cor0
----
-30
-30
-30

query I rowsort
SELECT ALL + cor0.col1 + col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + 64 + col1 FROM tab0 AS cor0
----
150
155
161

query I rowsort
SELECT + - 51 * - col1 FROM tab0 AS cor0
----
4386
4641
4947

onlyif mysql # use DIV operator for integer division
query I rowsort label-5682
SELECT ALL col1 DIV - col1 col2 FROM tab0 cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5682
SELECT ALL col1 / - col1 col2 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + 73 + col2 * + cor0.col0 FROM tab2 AS cor0
----
2101
262
3075

query I rowsort
SELECT ALL - 73 * col0 AS col1 FROM tab2 AS cor0
----
-511
-5694
-5767

query I rowsort
SELECT DISTINCT - col2 + + col0 * - col2 FROM tab1 cor0
----
-216
-3705
-7776

query I rowsort
SELECT - - ( - 45 ) + + cor0.col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 337bf77181f4072a8d9773cb20c39d08

onlyif mysql # use DIV operator for integer division
query I rowsort label-5687
SELECT 4 DIV cor1.col1 FROM tab1, tab2, tab2 AS cor0, tab0 AS cor1
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

skipif mysql # not compatible
query I rowsort label-5687
SELECT 4 / cor1.col1 FROM tab1, tab2, tab2 AS cor0, tab0 AS cor1
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

query I rowsort
SELECT ALL + - col2 + col2 + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + + col2 + cor0.col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + ( cor0.col0 ) * + 89 * col1 AS col0 FROM tab0 AS cor0
----
183696
302155
720811

query I rowsort
SELECT ALL - col2 + - ( 15 ) AS col1 FROM tab1 AS cor0
----
-111
-69
-72

query I rowsort
SELECT cor0.col0 + 32 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab1 cor2
----
81 values hashing to 03674745f35804dd7c6bd8c3d6f88daf

query I rowsort
SELECT - 71 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5694
SELECT - col0 * col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5694
SELECT - col0 * col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE + col1 - + col0 * col0 > ( NULL ) OR col1 - col2 IN ( + col0 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col1 BETWEEN - col1 + col0 AND NULL
----

query I rowsort
SELECT ALL + col0 * + col2 + - col0 * - col2 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT + + col0 * + col1 * col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT cor0.col0 + - cor0.col1 * col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5700
SELECT + - cor0.col1 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-5700
SELECT + - cor0.col1 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ALL + cor1.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col1 + + col0 col2 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5703
SELECT + 40 DIV cor0.col1 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5703
SELECT + 40 / cor0.col1 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5704
SELECT ALL + col2 * + col0 + + col2 DIV - col0 FROM tab1 cor0
----
144
3648
7679

skipif mysql # not compatible
query I rowsort label-5704
SELECT ALL + col2 * + col0 + + col2 / - col0 FROM tab1 cor0
----
144
3648
7679

onlyif mysql # use DIV operator for integer division
query I rowsort label-5705
SELECT col1 * col2 + + col1 DIV col2 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-5705
SELECT col1 * col2 + + col1 / col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col0 * cor0.col0 * col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT - cor0.col0 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-5708
SELECT DISTINCT - col2 + col0 DIV + cor0.col0 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-5708
SELECT DISTINCT - col2 + col0 / + cor0.col0 FROM tab1 AS cor0
----
-53
-56
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5709
SELECT col2 * col0 + col2 DIV + col1 + col1 * - col1 FROM tab1 AS cor0
----
-512
3553
7518

skipif mysql # not compatible
query I rowsort label-5709
SELECT col2 * col0 + col2 / + col1 + col1 * - col1 FROM tab1 AS cor0
----
-512
3553
7518

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + cor0.col1 * + col0 * + col0 col0 FROM tab0 AS cor0
----
118824
49503
720729

query I rowsort
SELECT ALL + - col1 * cor0.col2 + + col0 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col0 col1 FROM tab2, tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5713
SELECT - 58 * col0 + - col2 * col1 DIV - col1 FROM tab1
----
-120
-3655
-4544

skipif mysql # not compatible
query I rowsort label-5713
SELECT - 58 * col0 + - col2 * col1 / - col1 FROM tab1
----
-120
-3655
-4544

query I rowsort
SELECT col0 * col0 + col1 FROM tab0 cor0
----
1322
662
8012

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) <> ( col1 )
----

query I rowsort
SELECT - col2 + col2 + col1 AS col1 FROM tab2
----
17
31
59

query III rowsort
SELECT * FROM tab0 WHERE NOT - col2 * + col2 * - col1 BETWEEN + col2 AND ( col0 + + col1 )
----
24
86
33
89
91
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col2 col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL col0 * col2 * + tab0.col2 AS col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT col1 + col0 - + tab2.col0 * col2 AS col2 FROM tab2
----
-151
-1891
-2906

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL IN ( col0 + - col2 / + tab1.col2 - - col0 )
----

query I rowsort
SELECT col1 * tab2.col0 * tab2.col0 + - col0 FROM tab2
----
106018
1512
358878

query I rowsort
SELECT col2 * col1 + + tab1.col2 * + col0 FROM tab1
----
1566
4218
8928

query I rowsort
SELECT ALL col1 + tab0.col1 * col1 AS col0 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT - col1 * col1 + - col0 AS col0 FROM tab0 WHERE NULL NOT IN ( col1 + + col1 / + col0 + + col2 )
----

onlyif mysql # use DIV operator for integer division
query III rowsort label-5726
SELECT DISTINCT * FROM tab0 WHERE NOT ( col2 DIV + tab0.col0 + col2 ) BETWEEN - col2 AND col2
----
24
86
33

skipif mysql # not compatible
query III rowsort label-5726
SELECT DISTINCT * FROM tab0 WHERE NOT ( col2 / + tab0.col0 + col2 ) BETWEEN - col2 AND col2
----
24
86
33

query I rowsort
SELECT ALL col2 FROM tab1 WHERE NOT NULL IN ( - col2 )
----

query I rowsort
SELECT + col0 + col2 + + col0 FROM tab0
----
260
71
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col1 ) col0 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - 38 * col0 AS col2 FROM tab1 cor0
----
-114
-2432
-3040

query I rowsort
SELECT ALL 23 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 546d49aa433406dd83ea19885588e658

onlyif mysql # use DIV operator for integer division
query I rowsort label-5732
SELECT ALL col1 DIV cor0.col2 + - col1 - col0 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-5732
SELECT ALL col1 / cor0.col2 + - col1 - col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - 97 * + col2 AS col0 FROM tab2 AS cor0
----
-2522
-2619
-3686

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT + col2 NOT BETWEEN ( NULL ) AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col1 > NULL
----

query I rowsort
SELECT DISTINCT - col0 - - col1 AS col1 FROM tab0
----
2
62

query I rowsort
SELECT ALL - 67 + + col2 * col0 AS col2 FROM tab2 cor0
----
122
1961
2935

query I rowsort
SELECT - tab0.col2 + col2 * - col2 FROM tab0
----
-1122
-2
-6806

query I rowsort
SELECT col0 * col0 - + col2 FROM tab2
----
22
6058
6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col0 col1 FROM tab2
----
14
156
158

query I rowsort
SELECT cor0.col1 * col1 FROM tab2 cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 + col0 col2 FROM tab2
----
1422
224
4680

query I rowsort
SELECT DISTINCT tab1.col2 * + col1 AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT + tab1.col0 + - tab1.col1 FROM tab1
----
-23
54
67

query III rowsort
SELECT * FROM tab2 WHERE NOT col2 = ( NULL )
----

query I rowsort
SELECT tab0.col2 * - col0 - col2 FROM tab0
----
-36
-7380
-825

query I rowsort
SELECT ALL - col2 * col1 + + col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT ALL - col1 + + col2 * tab2.col2 AS col1 FROM tab2
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-5749
SELECT ALL col0 + - col0 DIV col1 FROM tab2
----
7
75
77

skipif mysql # not compatible
query I rowsort label-5749
SELECT ALL col0 + - col0 / col1 FROM tab2
----
7
75
77

query I rowsort
SELECT - cor0.col1 - col1 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col0 col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * - col1 + - col0 FROM tab1
----
-1120
-704
-81

query I rowsort
SELECT + - col1 * - cor0.col2 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT ( + col2 ) + - 70 * col1 FROM tab2 cor0
----
-1152
-2143
-4104

query I rowsort
SELECT - - 64 * + col1 FROM tab2 AS cor0
----
1088
1984
3776

query I rowsort
SELECT ( col0 ) * - 89 AS col0 FROM tab1 AS cor0
----
-267
-5696
-7120

query I rowsort
SELECT DISTINCT + 86 + - col1 + 66 AS col0 FROM tab2 AS cor0
----
121
135
93

query I rowsort
SELECT ALL + col2 - col2 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + 39 AS col0 FROM tab2 AS cor0
----
-39

query I rowsort
SELECT ALL - col1 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - 8 * - col0 FROM tab0 AS cor0
----
192
280
712

onlyif mysql # use DIV operator for integer division
query I rowsort label-5762
SELECT ALL + col2 + + col0 DIV - col1 AS col2 FROM tab2 AS cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-5762
SELECT ALL + col2 + + col0 / - col1 AS col2 FROM tab2 AS cor0
----
25
27
34

query I rowsort
SELECT - cor0.col1 * + 86 * + ( + col2 ) AS col1 FROM tab2 AS cor0
----
-131924
-55556
-71982

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col2 * 53 col2 FROM tab1 AS cor0
----
2865
3085
5168

query I rowsort
SELECT DISTINCT + col2 + cor0.col1 * + ( col0 ) - + cor0.col2 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5766
SELECT ALL - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5766
SELECT ALL - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - + col0 + - ( + col1 ) * + col1 AS col2 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT DISTINCT + - 28 * + col2 FROM tab1 AS cor0
----
-1512
-1596
-2688

query I rowsort
SELECT + cor0.col1 * col1 * + col2 + + 86 * + col0 FROM tab1 AS cor0
----
11204
23104
36762

query I rowsort
SELECT ALL + + 18 * 78 AS col0 FROM tab1 AS cor0
----
1404
1404
1404

query I rowsort
SELECT ALL - tab1.col2 * - col2 * + col2 + - col0 + + ( - 87 + + col2 ) FROM tab1
----
157428
185099
884665

onlyif mysql # use DIV operator for integer division
query I rowsort label-5772
SELECT ALL - + 53 DIV + col2 + col1 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5772
SELECT ALL - + 53 / + col2 + col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + 22 AS col1 FROM tab2
----
22
22
22

query I rowsort
SELECT - col0 * col1 - + col1 FROM tab1
----
-104
-1053
-650

query I rowsort
SELECT ALL 79 + cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 3a35b3eb13156514ce6822d08335b841

onlyif mysql # use DIV operator for integer division
query I rowsort label-5776
SELECT ALL CAST( - col2 AS SIGNED ) DIV - col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5776
SELECT ALL CAST ( - col2 AS INTEGER ) / - col1 FROM tab1
----
2
5
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5777
SELECT DISTINCT 73 DIV + col1 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-5777
SELECT DISTINCT 73 / + col1 FROM tab2
----
1
2
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5778
SELECT - col2 DIV col0 + col2 * 26 FROM tab1 AS cor0
----
1386
1482
2495

skipif mysql # not compatible
query I rowsort label-5778
SELECT - col2 / col0 + col2 * 26 FROM tab1 AS cor0
----
1386
1482
2495

query I rowsort
SELECT + 27 + col0 AS col2 FROM tab1
----
107
30
91

query I rowsort
SELECT DISTINCT cor0.col2 AS col1 FROM tab2, tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL 84 * + 50 * - col0 AS col1 FROM tab0
----
-100800
-147000
-373800

query I rowsort
SELECT ALL - + col1 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + + ( cor0.col1 ) + col1 + - col2 AS col1 FROM tab2 AS cor0
----
-4
35
92

query I rowsort
SELECT DISTINCT col2 + + col0 * col0 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT - + col0 + + col0 * col1 AS col1 FROM tab0 AS cor0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 50 col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

query I rowsort
SELECT + 74 * - tab0.col0 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 0e29caf0e9c3660bf8d93cc0bccba882

query I rowsort
SELECT - col0 + ( col2 ) + tab0.col1 AS col0 FROM tab0
----
63
84
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 42 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT DISTINCT col1 + 59 * col2 FROM tab2 AS cor0
----
1593
1624
2259

query I rowsort
SELECT ALL - - cor0.col0 + - 81 AS col2 FROM tab2 AS cor0
----
-2
-3
-74

query I rowsort
SELECT ALL + col2 + ( 77 ) FROM tab2
----
103
104
115

query I rowsort
SELECT - col2 * - 63 AS col0 FROM tab0 AS cor0
----
2079
5166
63

query I rowsort
SELECT DISTINCT + + 97 + col2 FROM tab2 AS cor0
----
123
124
135

query I rowsort
SELECT cor0.col1 * 34 + col0 * + col1 * + col1 AS col2 FROM tab2 AS cor0
----
23409
273524
7781

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5796
SELECT ALL - CAST( NULL AS SIGNED ) * - 63 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5796
SELECT ALL - CAST ( NULL AS INTEGER ) * - 63 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5797
SELECT cor0.col0 DIV col0 + + cor0.col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-5797
SELECT cor0.col0 / col0 + + cor0.col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT - col1 * - col0 * - col2 AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-5799
SELECT DISTINCT - col1 DIV 93 + - col1 DIV col1 FROM tab2
----
-1

skipif mysql # not compatible
query I rowsort label-5799
SELECT DISTINCT - col1 / 93 + - col1 / col1 FROM tab2
----
-1

query I rowsort
SELECT - col1 + + 59 - 88 AS col0 FROM tab1
----
-39
-42
-55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5801
SELECT DISTINCT col2 + CAST( NULL AS DECIMAL ) / 82 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-5801
SELECT DISTINCT col2 + CAST ( NULL AS REAL ) / 82 FROM tab1
----
NULL

query I rowsort
SELECT ALL col0 - - col1 FROM tab2 cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 73 * col1 col1 FROM tab0 AS cor0
----
6278
6643
7081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( 99 ) + col2 * + col2 col1 FROM tab0 AS cor0
----
100
1188
6823

query I rowsort
SELECT - - col0 + 55 AS col1 FROM tab2 AS cor0
----
133
134
62

query I rowsort
SELECT - col2 * 67 FROM tab1 AS cor0
----
-3618
-3819
-6432

onlyif mysql # use DIV operator for integer division
query I rowsort label-5807
SELECT + col2 * 61 + cor0.col0 DIV col0 AS col2 FROM tab0 AS cor0
----
2014
5003
62

skipif mysql # not compatible
query I rowsort label-5807
SELECT + col2 * 61 + cor0.col0 / col0 AS col2 FROM tab0 AS cor0
----
2014
5003
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5808
SELECT + col0 + CAST( ( + col0 ) AS SIGNED ) * col2 + - col0 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-5808
SELECT + col0 + CAST ( ( + col0 ) AS INTEGER ) * col2 + - col0 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col2 col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + ( + 98 ) + col2 AS col2 FROM tab0 AS cor0
----
131
180
99

query I rowsort
SELECT - + col0 + col2 + - 97 FROM tab1 AS cor0
----
-104
-46
-81

query I rowsort
SELECT + col2 + col2 * - ( + 70 ) FROM tab2 AS cor0
----
-1794
-1863
-2622

query I rowsort
SELECT ALL - 32 + col0 AS col2 FROM tab1
----
-29
32
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5814
SELECT - - col1 - col0 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5814
SELECT - - col1 - col0 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + - col2 + - 1 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT - + cor0.col0 * + col1 + + 90 FROM tab2 AS cor0
----
-1253
-127
-4512

query I rowsort
SELECT col0 + col1 - - ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
196
229
271

onlyif mysql # use DIV operator for integer division
query I rowsort label-5818
SELECT ALL col0 DIV + col0 + - col2 AS col0 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-5818
SELECT ALL col0 / + col0 + - col2 AS col0 FROM tab1
----
-53
-56
-95

query I rowsort
SELECT ( + 27 ) * + col1 * - col1 AS col1 FROM tab1
----
-18252
-2700
-4563

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5820
SELECT ALL - CAST( NULL AS SIGNED ) + - col0 + + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5820
SELECT ALL - CAST ( NULL AS INTEGER ) + - col0 + + col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT tab1.col1 AS col1 FROM tab1, tab0, tab1 AS cor0, tab2 AS cor1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT - col1 * col1 * - col0 FROM tab2
----
22831
271518
6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5823
SELECT - CAST( NULL AS SIGNED ) * cor0.col1 - cor0.col1 AS col2 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5823
SELECT - CAST ( NULL AS INTEGER ) * cor0.col1 - cor0.col1 AS col2 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 27 * col1 AS col2 FROM tab0
----
2322
2457
2619

query I rowsort
SELECT 30 + - col2 + - col0 AS col2 FROM tab1 AS cor0
----
-146
-27
-91

query I rowsort
SELECT ALL - + 59 * + col1 AS col2 FROM tab2 AS cor0
----
-1003
-1829
-3481

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 97 * col0 + col2 + col2 col1 FROM tab0 AS cor0
----
-2262
-3393
-8469

query I rowsort
SELECT + 76 - col2 AS col1 FROM tab2 AS cor0
----
38
49
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 15 + + tab1.col2 col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 74e2cc6386cf575f3c91e9bdace06ee8

query I rowsort
SELECT DISTINCT - cor0.col1 * - 6 + col0 AS col2 FROM tab0 cor0
----
540
617
635

query I rowsort
SELECT ALL + tab1.col0 * 49 FROM tab1, tab1 AS cor0
----
9 values hashing to 6ffb716b0738bb1128918bbf0cb3458b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5832
SELECT + 75 DIV - col1 - col2 * - col2 FROM tab1 cor0
----
2914
3242
9211

skipif mysql # not compatible
query I rowsort label-5832
SELECT + 75 / - col1 - col2 * - col2 FROM tab1 cor0
----
2914
3242
9211

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5833
SELECT col0 + tab0.col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5833
SELECT col0 + tab0.col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + tab1.col2 + col0 + - col2 AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT 22 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT - + col2 + - ( col0 ) FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 96 col1 FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT DISTINCT - - col0 * + col1 + col0 + cor0.col2 AS col0 FROM tab0 AS cor0
----
2121
3431
8270

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * ( 34 ) col2 FROM tab0 AS cor0
----
-2924
-3094
-3298

onlyif mysql # use DIV operator for integer division
query I rowsort label-5840
SELECT - + col1 + col2 DIV + col2 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-5840
SELECT - + col1 + col2 / + col2 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT - - col1 * 8 + - col0 FROM tab0 AS cor0
----
639
664
741

query I rowsort
SELECT ALL - 96 AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to a7b3e5dd01c8929180b7ffda67f79798

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( ( - col0 ) AS REAL ) AS col1 FROM tab1
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5844
SELECT CAST( ( col0 ) * 71 AS SIGNED ) FROM tab2
----
497
5538
5609

skipif mysql # not compatible
query I rowsort label-5844
SELECT CAST ( ( col0 ) * 71 AS INTEGER ) FROM tab2
----
497
5538
5609

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5845
SELECT + + CAST( 93 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
93
93
93

skipif mysql # not compatible
query I rowsort label-5845
SELECT + + CAST ( 93 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
93
93
93

query I rowsort
SELECT 25 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
650
675
950

query I rowsort
SELECT + col1 * col2 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL 78 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT + - col0 * col1 * - col2 - col2 AS col1 FROM tab1 AS cor0
----
36423
4158
99744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col2 * - cor0.col2 - col1 col2 FROM tab1 AS cor0
----
-157490
-185203
-884749

query I rowsort
SELECT DISTINCT col2 * - col1 - col2 AS col1 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT DISTINCT col1 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col1 + + col2 * + 76 * - col0 AS col0 FROM tab2 AS cor0
----
-14333
-154069
-228135

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5854
SELECT DISTINCT + + col1 * - CAST( + cor0.col2 AS SIGNED ) + col2 AS col1 FROM tab1 AS cor0
----
-1152
-1350
-513

skipif mysql # not compatible
query I rowsort label-5854
SELECT DISTINCT + + col1 * - CAST ( + cor0.col2 AS INTEGER ) + col2 AS col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT - col2 + - col1 * - 34 FROM tab2 AS cor0
----
1027
1980
540

query I rowsort
SELECT + col2 * + 69 + col0 FROM tab1 cor0
----
3729
3997
6704

onlyif mysql # use DIV operator for integer division
query I rowsort label-5857
SELECT DISTINCT + col0 + + col1 DIV - cor0.col1 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-5857
SELECT DISTINCT + col0 + + col1 / - cor0.col1 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT + 47 + + 29 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to a8a6c4c5005303c62d4e50b6c96b584f

skipif mysql # not compatible
query I rowsort
SELECT ALL col2 * 82 * col1 - CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
125729
52955
68603

query I rowsort
SELECT DISTINCT - cor0.col0 * - col0 + col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT col0 + 93 * col0 AS col1 FROM tab2 AS cor0
----
658
7332
7426

query I rowsort
SELECT ALL + - 82 - col2 FROM tab0 AS cor0
----
-115
-164
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5863
SELECT ALL - col2 * - col2 + + col2 DIV 68 FROM tab0 AS cor0
----
1
1089
6725

skipif mysql # not compatible
query I rowsort label-5863
SELECT ALL - col2 * - col2 + + col2 / 68 FROM tab0 AS cor0
----
1
1089
6725

query I rowsort
SELECT DISTINCT cor0.col1 * col1 - col1 AS col0 FROM tab2 AS cor0
----
272
3422
930

onlyif mysql # use DIV operator for integer division
query I rowsort label-5865
SELECT ALL 36 DIV + 85 AS col2 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5865
SELECT ALL 36 / + 85 AS col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL - cor0.col2 * - col2 + - 59 FROM tab2 AS cor0
----
1385
617
670

query I rowsort
SELECT + 86 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 32 col1 FROM tab1 AS cor0
----
-32
-32
-32

query I rowsort
SELECT col1 + - col1 + 21 FROM tab1 AS cor0
----
21
21
21

query I rowsort
SELECT ALL 62 * col0 AS col2 FROM tab0 AS cor0
----
1488
2170
5518

query I rowsort
SELECT DISTINCT + - col2 * + ( col1 ) + col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT ( + col2 + tab0.col1 ) * - tab0.col0 * col0 AS col0 FROM tab0
----
-120050
-1370333
-68544

query I rowsort
SELECT ALL + col2 + + 75 * + 75 FROM tab2 AS cor0
----
5651
5652
5663

onlyif mysql # use DIV operator for integer division
query I rowsort label-5874
SELECT DISTINCT + col2 + - 3 DIV 93 AS col2 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5874
SELECT DISTINCT + col2 + - 3 / 93 AS col2 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5875
SELECT DISTINCT + col1 DIV - col1 + + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-5875
SELECT DISTINCT + col1 / - col1 + + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT ALL col2 * + 94 - + 6 FROM tab1 AS cor0
----
5070
5352
9018

query I rowsort
SELECT DISTINCT col1 * ( + cor0.col2 ) FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - 64 + col1 * - col2 FROM tab0
----
-161
-2902
-7526

onlyif mysql # use DIV operator for integer division
query I rowsort label-5879
SELECT DISTINCT - col1 * + col1 + + ( - col1 ) * col2 DIV - 94 FROM tab0
----
-7366
-8202
-9408

skipif mysql # not compatible
query I rowsort label-5879
SELECT DISTINCT - col1 * + col1 + + ( - col1 ) * col2 / - 94 FROM tab0
----
-7366
-8202
-9408

query I rowsort
SELECT col2 * - col0 * - 73 FROM tab2
----
13797
148044
219146

query I rowsort
SELECT + 63 * col2 * + ( + 32 ) FROM tab2
----
52416
54432
76608

query I rowsort
SELECT ALL 13 + + tab0.col0 FROM tab0
----
102
37
48

query I rowsort
SELECT 41 + col1 + ( - col0 ) AS col0 FROM tab1
----
-13
-26
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-5884
SELECT ALL + col1 * - 28 + col0 DIV col2 AS col2 FROM tab0
----
-2408
-2547
-2681

skipif mysql # not compatible
query I rowsort label-5884
SELECT ALL + col1 * - 28 + col0 / col2 AS col2 FROM tab0
----
-2408
-2547
-2681

query I rowsort
SELECT DISTINCT - col1 * + 41 AS col2 FROM tab1
----
-1066
-410
-533

query I rowsort
SELECT DISTINCT cor0.col1 + col0 * + col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT + 38 AS col2 FROM tab2, tab0 AS cor0
----
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + 67 col2 FROM tab1
----
3618
3819
6432

query I rowsort
SELECT + 57 AS col1 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to 23b62d6905061dab566f3a9e15667302

onlyif mysql # use DIV operator for integer division
query I rowsort label-5890
SELECT + + col1 * col0 + - CAST( - 90 AS SIGNED ) + - col0 DIV 37 FROM tab2 AS cor0
----
1431
307
4690

skipif mysql # not compatible
query I rowsort label-5890
SELECT + + col1 * col0 + - CAST ( - 90 AS INTEGER ) + - col0 / 37 FROM tab2 AS cor0
----
1431
307
4690

query I rowsort
SELECT + 97 + + col1 AS col1 FROM tab0
----
183
188
194

query I rowsort
SELECT ALL - col0 * + cor0.col1 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5893
SELECT - CAST( NULL AS SIGNED ) + + tab0.col0 * tab0.col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5893
SELECT - CAST ( NULL AS INTEGER ) + + tab0.col0 * tab0.col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col0 * col2 ) + + col2 AS col0 FROM tab2
----
2054
216
3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5895
SELECT DISTINCT CAST( NULL AS SIGNED ) + cor1.col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5895
SELECT DISTINCT CAST ( NULL AS INTEGER ) + cor1.col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT - cor0.col0 * col2 + - 58 FROM tab0 AS cor0
----
-7356
-850
-93

query I rowsort
SELECT ALL + + cor0.col2 + + col0 + + col2 AS col1 FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT - 95 * + col1 * + 7 FROM tab0
----
-57190
-60515
-64505

query I rowsort
SELECT DISTINCT col1 + - col2 + col0 FROM tab2
----
11
111
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5900
SELECT ALL - col0 * col0 + - col2 + col2 DIV col1 FROM tab0
----
-1226
-609
-8003

skipif mysql # not compatible
query I rowsort label-5900
SELECT ALL - col0 * col0 + - col2 + col2 / col1 FROM tab0
----
-1226
-609
-8003

query I rowsort
SELECT cor0.col1 * col1 * col1 AS col1 FROM tab0 AS cor0
----
636056
753571
912673

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * col0 * col2 col1 FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5903
SELECT ALL - col0 DIV - cor0.col0 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5903
SELECT ALL - col0 / - cor0.col0 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT col2 * col2 + 28 * col0 FROM tab1 AS cor0
----
11456
3000
5041

query I rowsort
SELECT DISTINCT - 75 + col2 FROM tab1 AS cor0
----
-18
-21
21

query I rowsort
SELECT ALL - 75 + + col1 AS col0 FROM tab1 AS cor0
----
-49
-62
-65

query I rowsort
SELECT DISTINCT + 79 + col2 * + col1 FROM tab0 AS cor0
----
176
2917
7541

query I rowsort
SELECT - + col1 * - col1 - - col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT ALL - + 49 * cor0.col1 + 14 + col2 * + col2 FROM tab1 cor0
----
1656
2773
8593

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5910
SELECT + col0 * col1 * col0 + - CAST( col1 AS SIGNED ) * col1 col2 FROM tab1 AS cor0
----
-442
40860
83031

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5910
SELECT + col0 * col1 * col0 + - CAST ( col1 AS INTEGER ) * col1 col2 FROM tab1 AS cor0
----
-442
40860
83031

query I rowsort
SELECT - 99 * + ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
-5346
-5643
-9504

query IIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0 WHERE + cor0.col2 = ( NULL )
----

query I rowsort
SELECT + - col2 + col1 * + cor0.col2 FROM tab1 cor0
----
1152
1350
513

onlyif mysql # use DIV operator for integer division
query I rowsort label-5914
SELECT + - ( col1 ) DIV - cor0.col1 - - ( col1 ) FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-5914
SELECT + - ( col1 ) / - cor0.col1 - - ( col1 ) FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT + col0 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + col1 * col0 col0 FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 98 + - col1 * 74 col1 FROM tab2 AS cor0
----
-1160
-2196
-4268

query I rowsort
SELECT col2 * + col1 + col1 * + 70 * col1 AS col2 FROM tab2 AS cor0
----
20876
245204
68107

query I rowsort
SELECT - col0 * - 1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - col1 * 31 AS col1 FROM tab1 cor0
----
-310
-403
-806

query I rowsort
SELECT col2 + + col1 * 38 AS col0 FROM tab1
----
1042
437
590

query I rowsort
SELECT tab0.col0 + tab0.col0 * cor0.col2 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 1dc4dcf916e4fa8f63647452982fced8

query I rowsort
SELECT 22 * 84 FROM tab0, tab2 AS cor0
----
9 values hashing to 3cab8dc3be452a065bad543f16d6f764

query I rowsort
SELECT ALL + col1 + + col1 * - 97 AS col1 FROM tab2
----
-1632
-2976
-5664

query I rowsort
SELECT + - 38 * + ( - col0 ) + + 61 AS col0 FROM tab0 AS cor0
----
1391
3443
973

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * ( 14 ) col2 FROM tab0 cor0
----
1148
14
462

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 60 col1 FROM tab1 AS cor0
----
-180
-3840
-4800

onlyif mysql # use DIV operator for integer division
query I rowsort label-5928
SELECT DISTINCT + cor0.col1 DIV - 41 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5928
SELECT DISTINCT + cor0.col1 / - 41 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5929
SELECT + + col2 DIV - col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5929
SELECT + + col2 / - col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT + + col0 * + col1 + cor0.col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT tab0.col1 + - cor0.col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 191cb0026c65d6fd7e1ca864c3d947d1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5932
SELECT - CAST( col0 AS SIGNED ) + + cor0.col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5932
SELECT - CAST ( col0 AS INTEGER ) + + cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 60 + ( col0 ) FROM tab0 cor0
----
149
84
95

query I rowsort
SELECT ALL - + 67 AS col1 FROM tab0 AS cor0
----
-67
-67
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-5935
SELECT - col1 * col2 DIV col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5935
SELECT - col1 * col2 / col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL col0 + - col1 * + col2 AS col2 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) + col1 - ( - col0 ) * col0 col0 FROM tab1
----
32
4042
6333

query I rowsort
SELECT 37 * col1 AS col1 FROM tab2
----
1147
2183
629

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5939
SELECT ALL CAST( - col1 + - col1 AS SIGNED ) * - 88 * + 69 AS col2 FROM tab1
----
121440
157872
315744

skipif mysql # not compatible
query I rowsort label-5939
SELECT ALL CAST ( - col1 + - col1 AS INTEGER ) * - 88 * + 69 AS col2 FROM tab1
----
121440
157872
315744

query I rowsort
SELECT - col0 * 84 AS col0 FROM tab1
----
-252
-5376
-6720

query I rowsort
SELECT - + col2 * 29 FROM tab1 cor0
----
-1566
-1653
-2784

query I rowsort
SELECT + 61 - col1 FROM tab2 AS cor0
----
2
30
44

query I rowsort
SELECT ALL + col0 + col2 - - col0 FROM tab1
----
185
256
60

query I rowsort
SELECT col1 + 99 + col2 FROM tab1
----
166
179
208

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5945
SELECT CAST( NULL AS SIGNED ) * col2 - - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5945
SELECT CAST ( NULL AS INTEGER ) * col2 - - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor1.col1 * - cor1.col1 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 0c15ce053d5d7b134ad52c973e726cba

query I rowsort
SELECT - col2 + col2 * + ( 92 ) FROM tab0 AS cor0
----
3003
7462
91

query I rowsort
SELECT ALL 6 AS col2 FROM tab2
----
6
6
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5949
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5949
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5950
SELECT ALL + tab1.col1 DIV CAST( + 11 + col1 * + col1 AS SIGNED ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5950
SELECT ALL + tab1.col1 / CAST ( + 11 + col1 * + col1 AS INTEGER ) FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5951
SELECT DISTINCT col1 DIV + 21 AS col1 FROM tab0
----
4

skipif mysql # not compatible
query I rowsort label-5951
SELECT DISTINCT col1 / + 21 AS col1 FROM tab0
----
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 2 * + col0 col2 FROM tab0 AS cor0
----
1152
15842
2450

query I rowsort
SELECT DISTINCT col2 * col0 + 97 * col1 FROM tab0 AS cor0
----
16125
9134
9444

query I rowsort
SELECT DISTINCT + col2 + col2 * 16 AS col1 FROM tab1 AS cor0
----
1632
918
969

query I rowsort
SELECT DISTINCT + col0 * - tab2.col2 + + 1 * tab2.col2 AS col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT - 40 + tab2.col2 AS col2 FROM tab2
----
-13
-14
-2

query I rowsort
SELECT - + col2 * 44 AS col2 FROM tab1 AS cor0
----
-2376
-2508
-4224

query I rowsort
SELECT DISTINCT col1 + col0 * 56 AS col0 FROM tab0 AS cor0
----
1430
2057
5075

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 * 61 * col0 col1 FROM tab2 AS cor0
----
2989
371124
380701

query I rowsort
SELECT - col0 * - cor0.col2 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT + 29 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT DISTINCT col2 * - col2 + ( - col1 ) AS col0 FROM tab2
----
-1461
-735
-760

query I rowsort
SELECT ALL col1 + col2 * tab1.col1 AS col0 FROM tab1
----
1261
1430
580

query I rowsort
SELECT + 63 * - col1 AS col1 FROM tab0
----
-5418
-5733
-6111

onlyif mysql # use DIV operator for integer division
query I rowsort label-5965
SELECT col1 + col1 + 77 DIV 84 FROM tab2
----
118
34
62

skipif mysql # not compatible
query I rowsort label-5965
SELECT col1 + col1 + 77 / 84 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT + col1 + 83 * - 6 AS col0 FROM tab2 AS cor0
----
-439
-467
-481

query I rowsort
SELECT col0 + + col0 + + col1 * - col0 FROM tab1 AS cor0
----
-512
-72
-880

query I rowsort
SELECT DISTINCT - cor0.col0 + + col1 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT + + col2 * - col1 + col0 AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - + col0 * ( cor0.col0 * col0 ) AS col2 FROM tab2 AS cor0
----
-343
-474552
-493039

query I rowsort
SELECT 19 AS col2 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT DISTINCT - col2 + - ( col0 ) FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL - cor0.col0 * + 82 + - col2 AS col1 FROM tab0 AS cor0
----
-2001
-2871
-7380

query I rowsort
SELECT DISTINCT + + col2 * 77 * - col2 FROM tab1 cor0
----
-224532
-250173
-709632

onlyif mysql # use DIV operator for integer division
query I rowsort label-5975
SELECT + + col2 DIV + 84 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5975
SELECT + + col2 / + 84 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5976
SELECT DISTINCT + col2 DIV + tab1.col0 AS col2 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5976
SELECT DISTINCT + col2 / + tab1.col0 AS col2 FROM tab1
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-5977
SELECT ALL col0 DIV - tab2.col0 AS col2 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5977
SELECT ALL col0 / - tab2.col0 AS col2 FROM tab2
----
-1
-1
-1

query III rowsort
SELECT * FROM tab1 WHERE NOT col0 * col1 - + tab1.col1 = NULL
----

query I rowsort
SELECT col2 * - col0 + + col0 + - tab0.col1 FROM tab0
----
-7300
-854
-97

query I rowsort
SELECT - col1 * col1 * + col0 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT ALL col2 + + col2 + - col0 AS col1 FROM tab0
----
-33
42
75

query I rowsort
SELECT ALL col0 AS col2 FROM tab1 WHERE NOT col1 + tab1.col1 - - col2 * col1 NOT IN ( - tab1.col2 )
----

query I rowsort
SELECT + col1 * - col0 * col2 FROM tab1
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col2 - + col1 col2 FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT tab1.col0 + col1 + + col1 * col2 FROM tab1
----
1341
1433
644

query I rowsort
SELECT + tab0.col0 - + col0 * col0 FROM tab0
----
-1190
-552
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-5987
SELECT DISTINCT + col2 + col0 DIV col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-5987
SELECT DISTINCT + col2 + col0 / col2 FROM tab0
----
33
36
83

query I rowsort
SELECT DISTINCT col1 * + cor0.col0 + - ( + cor0.col0 ) FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT - 83 + - col1 - cor0.col0 FROM tab1 AS cor0
----
-112
-157
-176

query I rowsort
SELECT ALL - 48 * - col1 FROM tab0 AS cor0
----
4128
4368
4656

query I rowsort
SELECT DISTINCT col0 FROM tab2 WHERE ( NULL ) > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5992
SELECT ALL + - 17 DIV col2 + col1 DIV col2 + - col2 * - col2 * - col1 AS col2 FROM tab0 AS cor0
----
-17
-611883
-93652

skipif mysql # not compatible
query I rowsort label-5992
SELECT ALL + - 17 / col2 + col1 / col2 + - col2 * - col2 * - col1 AS col2 FROM tab0 AS cor0
----
-17
-611883
-93652

query I rowsort
SELECT - cor0.col0 + cor0.col2 * - 52 * 46 FROM tab0 AS cor0
----
-196233
-2427
-78960

query I rowsort
SELECT DISTINCT - col0 * - col0 + - col1 AS col0 FROM tab2 AS cor0
----
18
6025
6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-5995
SELECT ALL cor0.col1 DIV + col1 + + ( + col0 ) FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-5995
SELECT ALL cor0.col1 / + col1 + + ( + col0 ) FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort
SELECT ALL + cor0.col2 + CAST ( cor0.col1 AS REAL ) FROM tab0, tab2 AS cor0
----
9 values hashing to 993162448d72b066e1ac9ba4caa8d8d7

query I rowsort
SELECT DISTINCT + col0 - + col1 AS col2 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT - cor0.col2 * - cor0.col0 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT - 54 * - col0 - col1 * cor0.col0 * - col2 FROM tab2 AS cor0
----
123864
55300
6237

query I rowsort
SELECT DISTINCT - col1 + + col0 * col1 AS col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT 84 AS col0 FROM tab0 AS cor0
----
84
84
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6002
SELECT DISTINCT - col0 + + cor0.col0 DIV - cor0.col1 FROM tab1 AS cor0
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-6002
SELECT DISTINCT - col0 + + cor0.col0 / - cor0.col1 FROM tab1 AS cor0
----
-3
-70
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-6003
SELECT ALL - col0 DIV + col0 + - col2 - ( + col2 ) col0 FROM tab2 cor0
----
-53
-55
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6003
SELECT ALL - col0 / + col0 + - col2 - ( + col2 ) col0 FROM tab2 cor0
----
-53
-55
-77

query I rowsort
SELECT ALL + col2 * col0 + + cor0.col2 + - 47 * col0 FROM tab0 AS cor0
----
-1609
-303
3197

query I rowsort
SELECT ALL - + col0 * cor0.col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + col2 * - 65 FROM tab1 AS cor0
----
-3510
-3705
-6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-6007
SELECT - + col1 + col2 * + col2 DIV - col2 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-6007
SELECT - + col1 + col2 * + col2 / - col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT col2 * ( + col0 ) - - cor0.col0 AS col1 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6009
SELECT DISTINCT + tab1.col0 * + col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6009
SELECT DISTINCT + tab1.col0 * + col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query I rowsort
SELECT ALL col1 * col1 + - ( + col0 ) FROM tab0
----
7372
8192
9374

query I rowsort
SELECT - col0 + ( col0 ) * col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL - 88 + + tab2.col0 FROM tab2
----
-10
-81
-9

query I rowsort
SELECT DISTINCT - + 70 + cor0.col0 FROM tab2 cor0
----
-63
8
9

query I rowsort
SELECT ALL + cor0.col2 + + 56 AS col1 FROM tab1 AS cor0
----
110
113
152

onlyif mysql # use DIV operator for integer division
query I rowsort label-6015
SELECT ALL 50 DIV 39 - col2 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-6015
SELECT ALL 50 / 39 - col2 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT ( - col2 ) + col1 * ( ( col1 ) ) AS col2 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT ALL - 51 AS col2 FROM tab0
----
-51
-51
-51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) * - col0 * 87 col0 FROM tab1
----
55680
6786
90480

query I rowsort
SELECT ALL + ( 47 ) * - col2 * 86 AS col2 FROM tab0
----
-133386
-331444
-4042

query I rowsort
SELECT - 46 + - col1 * col1 AS col0 FROM tab0
----
-7442
-8327
-9455

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6021
SELECT - 49 + - ( col1 ) * + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6021
SELECT - 49 + - ( col1 ) * + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0, tab2 AS cor0 WHERE NULL <> NULL
----

query I rowsort
SELECT DISTINCT 87 * tab1.col1 AS col0 FROM tab1
----
1131
2262
870

query I rowsort
SELECT DISTINCT - cor0.col1 AS col1 FROM tab0, tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + - col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - col2 + + col2 * col2 * + col2 FROM tab2 AS cor0
----
17550
19656
54834

query I rowsort
SELECT tab1.col2 + col1 * - col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ALL + col0 * - col1 - col1 FROM tab2
----
-1360
-248
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-6029
SELECT ALL col0 * + tab0.col0 - - col1 * col0 DIV col1 FROM tab0
----
1260
600
8010

skipif mysql # not compatible
query I rowsort label-6029
SELECT ALL col0 * + tab0.col0 - - col1 * col0 / col1 FROM tab0
----
1260
600
8010

query I rowsort
SELECT DISTINCT col2 + + tab0.col0 - + tab0.col0 * + col1 AS col2 FROM tab0
----
-2007
-3359
-7928

query I rowsort
SELECT col2 * col1 - col0 AS col2 FROM tab1 AS cor0
----
1168
1401
506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6032
SELECT DISTINCT - CAST( col2 AS SIGNED ) AS col1 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-6032
SELECT DISTINCT - CAST ( col2 AS INTEGER ) AS col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ( - ( col2 ) + col1 ) FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ( + 12 ) FROM tab0
----
12
12
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6035
SELECT DISTINCT - CAST( col2 AS SIGNED ) FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6035
SELECT DISTINCT - CAST ( col2 AS INTEGER ) FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - ( cor0.col2 ) FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT col0 * col1 * col1 AS col0 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-6038
SELECT - col1 * + col2 + + col0 DIV + col1 + col1 AS col0 FROM tab2
----
-1474
-625
-806

skipif mysql # not compatible
query I rowsort label-6038
SELECT - col1 * + col2 + + col0 / + col1 + col1 AS col0 FROM tab2
----
-1474
-625
-806

query I rowsort
SELECT ALL tab2.col0 * + col2 + tab2.col1 * + col2 FROM tab2
----
1026
3562
3648

query I rowsort
SELECT ALL col0 + - col2 * + col2 FROM tab0 WHERE col2 >= col1
----

query I rowsort
SELECT - col0 AS col2 FROM tab2 WHERE NOT NULL BETWEEN col1 * col1 AND col0 + - col1
----

query I rowsort
SELECT DISTINCT col0 * + col1 + col1 AS col0 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT cor0.col1 * cor0.col0 + col2 FROM tab0 cor0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - col1 * cor0.col2 col0 FROM tab2 cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL - col1 * + tab0.col2 + + col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT - col1 * - tab2.col1 - col0 FROM tab2 WHERE ( col1 ) IN ( + tab2.col0 + - tab2.col0 * tab2.col0 )
----

query I rowsort
SELECT ALL col1 * col2 * col2 + + col0 FROM tab0
----
132
611973
93678

query I rowsort
SELECT DISTINCT - col1 * col2 + - col2 FROM tab2 WHERE ( + col2 ) >= NULL
----

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) <> - col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 + tab2.col2 * col1 + col2 col2 FROM tab2
----
1619
701
895

query I rowsort
SELECT col2 + + col0 - col2 AS col0 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + col0 + tab2.col2 * + col2 FROM tab2
----
1523
736
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 + + col2 col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL - col0 * col0 FROM tab0 WHERE col2 IN ( col2 )
----
-1225
-576
-7921

query I rowsort
SELECT - col0 + - cor0.col0 * + col2 FROM tab0 AS cor0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 + cor0.col0 * + col1 col2 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-6057
SELECT cor0.col1 + - col2 DIV - col0 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-6057
SELECT cor0.col1 + - col2 / - col0 FROM tab0 AS cor0
----
87
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6058
SELECT ALL + col2 * col0 DIV col0 col0 FROM tab2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6058
SELECT ALL + col2 * col0 / col0 col0 FROM tab2
----
26
27
38

query I rowsort
SELECT + col2 * col0 FROM tab0 WHERE - col2 / + col1 IN ( tab0.col1 )
----

query I rowsort
SELECT ALL + cor0.col2 + - col2 * col0 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT + col1 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + col1 * - col0 * - col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT - col2 * - col2 * - col1 + cor0.col0 AS col0 FROM tab2 AS cor0
----
-22592
-24469
-39806

query I rowsort
SELECT col2 + col0 * + col1 FROM tab2
----
1381
244
4628

query I rowsort
SELECT + 65 * col1 FROM tab1 AS cor0
----
1690
650
845

query I rowsort
SELECT - ( + col1 ) * - col2 * col1 - - col1 AS col1 FROM tab2 AS cor0
----
10999
25978
90565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6067
SELECT DISTINCT + + CAST( NULL AS SIGNED ) * cor0.col1 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6067
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) * cor0.col1 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + - 82 * + col0 AS col1 FROM tab2 AS cor0
----
-574
-6396
-6478

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 - + cor0.col2 col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT + ( 54 ) + - col2 + cor0.col2 FROM tab0 AS cor0
----
54

query I rowsort
SELECT - - cor0.col0 + + col0 * - col1 FROM tab1 cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + 63 col1 FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT DISTINCT - 54 * ( col2 ) * - 24 AS col1 FROM tab0 AS cor0
----
106272
1296
42768

query I rowsort
SELECT ALL + col0 * - col1 + + col2 AS col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT + - col2 + - 76 + col0 FROM tab2 AS cor0
----
-24
-35
-96

query I rowsort
SELECT ALL - - ( col2 ) * col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col0 + + ( - col2 ) * col2 - + col1 AS col2 FROM tab1
----
-2939
-3195
-9149

query I rowsort
SELECT DISTINCT - col0 - - 28 FROM tab0
----
-61
-7
4

query I rowsort
SELECT - + col1 - col1 * + col2 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-6080
SELECT ALL col1 DIV 49 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6080
SELECT ALL col1 / 49 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + ( - col1 ) + + col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT + col2 - - 22 AS col2 FROM tab1 AS cor0
----
118
76
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6083
SELECT DISTINCT - CAST( col1 AS SIGNED ) * col0 + CAST( - 26 * col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-10413
-2688
-4305

skipif mysql # not compatible
query I rowsort label-6083
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * col0 + CAST ( - 26 * col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-10413
-2688
-4305

query I rowsort
SELECT DISTINCT 13 AS col1 FROM tab2, tab1 AS cor0
----
13

query I rowsort
SELECT DISTINCT + 98 * + col0 * col2 + - col2 + - col0 * col1 * - ( col1 + + col1 ) FROM tab0
----
2189140
432591
662059

query I rowsort
SELECT DISTINCT + 63 * - cor0.col1 - - col2 FROM tab2 AS cor0
----
-1033
-1926
-3691

query I rowsort
SELECT ALL + ( col0 ) * col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + col1 - col0 * cor0.col0 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6089
SELECT DISTINCT - + col0 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6089
SELECT DISTINCT - + col0 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT + col2 * ( - ( col0 ) ) AS col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL + 78 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 50 col1 FROM tab0, tab2, tab1 cor0, tab1
----
81 values hashing to 6932c991110d256d3f92f3e9538f8040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6093
SELECT + col0 - CAST( col2 * col0 AS SIGNED ) FROM tab1
----
-159
-3584
-7600

skipif mysql # not compatible
query I rowsort label-6093
SELECT + col0 - CAST ( col2 * col0 AS INTEGER ) FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT ALL col0 * col0 + + 56 AS col0 FROM tab0 AS cor0
----
1281
632
7977

query I rowsort
SELECT DISTINCT + col1 + - 48 FROM tab1 AS cor0
----
-22
-35
-38

query I rowsort
SELECT - + cor0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT - cor0.col0 * - 35 + col2 FROM tab2 AS cor0
----
272
2756
2803

query I rowsort
SELECT DISTINCT - cor0.col2 + + ( cor0.col2 * col0 ) + - col2 FROM tab2 AS cor0
----
135
1976
2926

query I rowsort
SELECT ALL - + col1 * + col0 + cor0.col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT - 12 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT ALL - col1 * 87 + - col0 AS col1 FROM tab1 AS cor0
----
-1211
-2265
-934

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6102
SELECT ALL - CAST( NULL AS SIGNED ) + - 41 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6102
SELECT ALL - CAST ( NULL AS INTEGER ) + - 41 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * - ( col2 ) * - col2 AS col0 FROM tab0
----
611884
93654
97

query I rowsort
SELECT 87 FROM tab1, tab2 cor0, tab1 AS cor1, tab1 cor2
----
81 values hashing to 969f31ae779866644763e8a07f1ec501

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6105
SELECT + CAST( 37 AS SIGNED ) + col2 FROM tab1 AS cor0
----
133
91
94

skipif mysql # not compatible
query I rowsort label-6105
SELECT + CAST ( 37 AS INTEGER ) + col2 FROM tab1 AS cor0
----
133
91
94

query I rowsort
SELECT + + cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT 2 + col2 * - col2 AS col0 FROM tab1 cor0
----
-2914
-3247
-9214

query I rowsort
SELECT - col2 * - tab2.col0 * + ( 12 + + col0 * col0 ) FROM tab2
----
11529
12362688
18771506

query I rowsort
SELECT 65 + col2 * 72 AS col2 FROM tab2 AS cor0
----
1937
2009
2801

query I rowsort
SELECT + + col1 + + 16 FROM tab1 AS cor0
----
26
29
42

query I rowsort
SELECT DISTINCT + col0 + 13 * - col1 AS col1 FROM tab2 AS cor0
----
-142
-396
-689

query I rowsort
SELECT ALL - - col1 + col2 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7515
8454
9507

onlyif mysql # use DIV operator for integer division
query I rowsort label-6113
SELECT ALL - - col2 * col2 DIV 54 FROM tab0 AS cor0
----
0
124
20

skipif mysql # not compatible
query I rowsort label-6113
SELECT ALL - - col2 * col2 / 54 FROM tab0 AS cor0
----
0
124
20

query I rowsort
SELECT - col2 + - col2 * + col2 FROM tab2 AS cor0
----
-1482
-702
-756

onlyif mysql # use DIV operator for integer division
query I rowsort label-6115
SELECT - - 10 DIV + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6115
SELECT - - 10 / + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * col1 * col1 col2 FROM tab0 AS cor0
----
-177504
-329315
-737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * 99 col2 FROM tab2, tab0 cor0
----
9 values hashing to 794669ecdfcc6d60963c047189f2d5ae

query I rowsort
SELECT DISTINCT - ( 18 ) FROM tab2, tab2 cor0
----
-18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6119
SELECT - + CAST( - col1 AS SIGNED ) * col0 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-6119
SELECT - + CAST ( - col1 AS INTEGER ) * col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col0 * + ( 73 * col1 ) FROM tab1
----
46720
5694
75920

query I rowsort
SELECT + col1 * - ( cor0.col0 ) - cor0.col0 FROM tab1 AS cor0
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6122
SELECT DISTINCT - col1 DIV 36 + + col0 * col1 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-6122
SELECT DISTINCT - col1 / 36 + + col0 * col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6123
SELECT + cor0.col1 DIV - col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6123
SELECT + cor0.col1 / - col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT col1 + cor0.col0 * col0 * col0 AS col2 FROM tab1 AS cor0
----
262154
512013
53

query I rowsort
SELECT + + 63 AS col0 FROM tab1 AS cor0
----
63
63
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6126
SELECT ( - col2 ) + col0 - CAST( NULL AS SIGNED ) * col1 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6126
SELECT ( - col2 ) + col0 - CAST ( NULL AS INTEGER ) * col1 AS col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6127
SELECT DISTINCT 46 DIV col1 + tab2.col1 FROM tab2
----
19
32
59

skipif mysql # not compatible
query I rowsort label-6127
SELECT DISTINCT 46 / col1 + tab2.col1 FROM tab2
----
19
32
59

query I rowsort
SELECT + cor0.col2 + - col0 * col0 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT - + cor0.col2 * col1 + - col2 * 44 AS col0 FROM tab0 AS cor0
----
-11070
-141
-4290

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6130
SELECT DISTINCT col1 * + col1 + CAST( - col0 AS SIGNED ) AS col0 FROM tab1 cor0
----
36
673
89

skipif mysql # not compatible
query I rowsort label-6130
SELECT DISTINCT col1 * + col1 + CAST ( - col0 AS INTEGER ) AS col0 FROM tab1 cor0
----
36
673
89

query I rowsort
SELECT ALL - col2 + cor0.col2 + ( col2 ) * col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - 80 * - col0 FROM tab0 AS cor0
----
1920
2800
7120

query I rowsort
SELECT 72 + cor0.col1 * col1 AS col2 FROM tab1 AS cor0
----
172
241
748

query I rowsort
SELECT ALL - 44 - - col0 FROM tab1 AS cor0
----
-41
20
36

query I rowsort
SELECT ALL + - col1 * col2 + col2 AS col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT + - col0 * col0 + - col2 + 44 AS col1 FROM tab0 AS cor0
----
-1182
-565
-7959

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + col1 * + col2 + - cor0.col2 col0 FROM tab1 AS cor0
----
1165
1376
523

query I rowsort
SELECT ALL - ( col2 ) * + ( - cor0.col0 ) AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - col1 + + col1 * + col2 * + col2 FROM tab1 AS cor0
----
119795
32480
75790

query I rowsort
SELECT - + col1 - col1 * + 20 AS col0 FROM tab2 AS cor0
----
-1239
-357
-651

query I rowsort
SELECT + col2 + col2 * + col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT - col1 + + 19 FROM tab1 cor0
----
-7
6
9

query I rowsort
SELECT ALL - + cor0.col0 * - 32 FROM tab1 AS cor0
----
2048
2560
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6144
SELECT DISTINCT - col1 + - CAST( ( col1 ) + 49 AS SIGNED ) FROM tab2 AS cor0
----
-111
-167
-83

skipif mysql # not compatible
query I rowsort label-6144
SELECT DISTINCT - col1 + - CAST ( ( col1 ) + 49 AS INTEGER ) FROM tab2 AS cor0
----
-111
-167
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - + col1 * col2 * cor0.col1 col1 FROM tab2 cor0
----
-10999
-25978
-90565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6146
SELECT col2 * + CAST( NULL AS SIGNED ) * + col0 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6146
SELECT col2 * + CAST ( NULL AS INTEGER ) * + col0 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - col1 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + - col1 * 2 + col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + 98 + - col1 * + col2 FROM tab0 AS cor0
----
-2740
-7364
1

query I rowsort
SELECT DISTINCT + ( 87 ) FROM tab0 AS cor0
----
87

query I rowsort
SELECT - 0 FROM tab2, tab2 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT col0 + 58 + + col1 FROM tab2 AS cor0
----
154
195
96

query I rowsort
SELECT ALL 60 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT DISTINCT 38 + + col1 AS col2 FROM tab2 cor0
----
55
69
97

query I rowsort
SELECT DISTINCT - col0 * col1 + - ( 17 ) FROM tab1 AS cor0
----
-1057
-657
-95

query I rowsort
SELECT ALL 16 + + col0 + cor0.col0 FROM tab2 AS cor0
----
172
174
30

query I rowsort
SELECT ALL + 97 - col2 * + col2 AS col2 FROM tab0 AS cor0
----
-6627
-992
96

query I rowsort
SELECT - 72 * cor0.col0 AS col0 FROM tab1 cor0
----
-216
-4608
-5760

onlyif mysql # use DIV operator for integer division
query I rowsort label-6159
SELECT DISTINCT + col0 * - col2 + col2 DIV - col0 FROM tab0 AS cor0
----
-35
-7298
-793

skipif mysql # not compatible
query I rowsort label-6159
SELECT DISTINCT + col0 * - col2 + col2 / - col0 FROM tab0 AS cor0
----
-35
-7298
-793

query I rowsort
SELECT DISTINCT + col2 * - col2 AS col1 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - col2 + + 98 FROM tab1 AS cor0
----
2
41
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-6162
SELECT + col0 * cor0.col2 + - col1 DIV col0 AS col1 FROM tab2 AS cor0
----
185
2028
3002

skipif mysql # not compatible
query I rowsort label-6162
SELECT + col0 * cor0.col2 + - col1 / col0 AS col1 FROM tab2 AS cor0
----
185
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6163
SELECT col0 * col0 + 1 DIV + col1 col1 FROM tab1 AS cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6163
SELECT col0 * col0 + 1 / + col1 col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - col0 + + ( col1 ) AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - col1 - - 86 FROM tab1 AS cor0
----
60
73
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6166
SELECT DISTINCT + col1 DIV 49 + + ( col0 + + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-6166
SELECT DISTINCT + col1 / 49 + + ( col0 + + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + cor0.col0 + + 9 AS col2 FROM tab1 cor0
----
12
73
89

query I rowsort
SELECT - col0 - ( 63 ) AS col2 FROM tab0 AS cor0
----
-152
-87
-98

query I rowsort
SELECT DISTINCT + cor0.col2 * 43 AS col0 FROM tab1 cor0
----
2322
2451
4128

query I rowsort
SELECT DISTINCT + col1 * ( - col1 ) AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + col0 * + col0 + - 46 AS col2 FROM tab1 AS cor0
----
-37
4050
6354

query I rowsort
SELECT ALL col1 - cor0.col2 * - col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT - col0 * - 9 FROM tab2 AS cor0
----
63
702
711

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6174
SELECT DISTINCT + - CAST( - col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6174
SELECT DISTINCT + - CAST ( - col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + col1 + cor0.col0 - col2 AS col0 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT DISTINCT - + cor0.col2 + col2 * col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL + 27 * col0 + - col2 AS col1 FROM tab0 AS cor0
----
2321
615
944

query I rowsort
SELECT DISTINCT - 55 + col0 * col0 FROM tab0 AS cor0
----
1170
521
7866

query I rowsort
SELECT - - col1 * - 19 + - col0 * - ( + cor0.col0 ) * + col2 FROM tab0 AS cor0
----
-618
17374
647793

query I rowsort
SELECT DISTINCT + col0 * col1 + + cor0.col0 * col1 * - 97 AS col2 FROM tab2 AS cor0
----
-128928
-20832
-441792

query I rowsort
SELECT + 49 + col1 AS col2 FROM tab0 AS cor0
----
135
140
146

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6182
SELECT - col1 * CAST( NULL AS SIGNED ) + - col2 / col1 + - 47 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6182
SELECT - col1 * CAST ( NULL AS INTEGER ) + - col2 / col1 + - 47 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * - 7 + + col1 * col0 AS col0 FROM tab1
----
1039
1712
456

query I rowsort
SELECT DISTINCT - cor0.col2 + + ( + col1 ) AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + 73 * col2 FROM tab0 cor0
----
2409
5986
73

query I rowsort
SELECT - col1 * - col1 + + col2 + ( cor0.col1 ) FROM tab2 cor0
----
1019
344
3566

query I rowsort
SELECT DISTINCT + + 96 * col0 * col1 FROM tab1 AS cor0
----
61440
7488
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6188
SELECT ALL cor0.col1 * CAST( NULL AS SIGNED ) * cor0.col1 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6188
SELECT ALL cor0.col1 * CAST ( NULL AS INTEGER ) * cor0.col1 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - 4 * cor0.col2 + + ( - col2 ) AS col0 FROM tab1 AS cor0
----
-270
-285
-480

query I rowsort
SELECT - ( 97 ) + + tab1.col1 * + col0 FROM tab1
----
-19
543
943

onlyif mysql # use DIV operator for integer division
query I rowsort label-6191
SELECT - - 84 + - col0 DIV col1 AS col0 FROM tab0 AS cor0
----
84
84
84

skipif mysql # not compatible
query I rowsort label-6191
SELECT - - 84 + - col0 / col1 AS col0 FROM tab0 AS cor0
----
84
84
84

query I rowsort
SELECT - ( + col1 ) * + 26 AS col1 FROM tab2 AS cor0
----
-1534
-442
-806

query I rowsort
SELECT - - 90 + + col0 * 21 AS col0 FROM tab0 AS cor0
----
1959
594
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6194
SELECT ALL + 33 DIV 86 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6194
SELECT ALL + 33 / 86 FROM tab2
----
0
0
0

query I rowsort
SELECT col1 * 87 FROM tab2
----
1479
2697
5133

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT + + col1 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT 32 + tab0.col1 FROM tab0
----
118
123
129

query I rowsort
SELECT 83 FROM tab0, tab0 cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

query I rowsort
SELECT DISTINCT ( - col2 ) * col1 AS col0 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT tab1.col2 AS col2 FROM tab1, tab0 cor0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT DISTINCT - cor1.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6203
SELECT ALL + cor0.col0 DIV col0 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6203
SELECT ALL + cor0.col0 / col0 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - + col0 * - cor0.col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL 95 AS col2 FROM tab2 AS cor0
----
95
95
95

query I rowsort
SELECT + + col0 * - cor0.col2 + 33 FROM tab0 AS cor0
----
-2
-7265
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-6207
SELECT ALL col0 DIV + ( + col0 ) + - col1 DIV + 18 + col2 AS col2 FROM tab1
----
54
58
97

skipif mysql # not compatible
query I rowsort label-6207
SELECT ALL col0 / + ( + col0 ) + - col1 / + 18 + col2 AS col2 FROM tab1
----
54
58
97

query I rowsort
SELECT DISTINCT 17 AS col2 FROM tab0, tab0 cor0
----
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6209
SELECT + + ( col0 ) + + col2 + CAST( + ( col1 ) AS SIGNED ) FROM tab1 AS cor0
----
131
189
83

skipif mysql # not compatible
query I rowsort label-6209
SELECT + + ( col0 ) + + col2 + CAST ( + ( col1 ) AS INTEGER ) FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT DISTINCT + - 47 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
-47

query I rowsort
SELECT DISTINCT col0 * - 37 FROM tab2 AS cor0
----
-259
-2886
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-6212
SELECT DISTINCT col0 DIV - col1 + 88 * - col2 AS col1 FROM tab2 cor0
----
-2289
-2376
-3348

skipif mysql # not compatible
query I rowsort label-6212
SELECT DISTINCT col0 / - col1 + 88 * - col2 AS col1 FROM tab2 cor0
----
-2289
-2376
-3348

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 cor2, tab2 cor3
----
3645 values hashing to cc4f069e61d0cc52f433f9e8c0058808

query I rowsort
SELECT 50 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT ALL + tab0.col1 * - tab0.col1 AS col0 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT 63 + - 71 AS col1 FROM tab2 AS cor0
----
-8
-8
-8

query I rowsort
SELECT ALL 14 * + cor0.col1 + - col2 AS col1 FROM tab2 AS cor0
----
200
407
800

onlyif mysql # use DIV operator for integer division
query I rowsort label-6218
SELECT - CAST( + 51 AS SIGNED ) + col0 DIV - col0 FROM tab2 AS cor0
----
-52
-52
-52

skipif mysql # not compatible
query I rowsort label-6218
SELECT - CAST ( + 51 AS INTEGER ) + col0 / - col0 FROM tab2 AS cor0
----
-52
-52
-52

query I rowsort
SELECT + ( + 8 ) FROM tab1 AS cor0
----
8
8
8

query I rowsort
SELECT col0 + + 74 FROM tab1 AS cor0
----
138
154
77

query I rowsort
SELECT + + col1 * + col0 + - col0 AS col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT + col0 + - 99 AS col0 FROM tab1 AS cor0
----
-19
-35
-96

query I rowsort
SELECT + cor0.col0 * 27 + - col0 AS col1 FROM tab1 AS cor0
----
1664
2080
78

query I rowsort
SELECT - col0 * ( col2 ) + col2 * + 24 * - col2 FROM tab0 AS cor0
----
-168674
-26928
-59

query I rowsort
SELECT ALL 66 * - col2 FROM tab1 cor0
----
-3564
-3762
-6336

query I rowsort
SELECT ALL - + ( col1 ) * col1 + - col0 AS col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT ALL - col2 + - ( + col0 ) AS col2 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6228
SELECT DISTINCT CAST( + cor0.col0 AS SIGNED ) + - col1 DIV col1 AS col1 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6228
SELECT DISTINCT CAST ( + cor0.col0 AS INTEGER ) + - col1 / col1 AS col1 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT DISTINCT 27 + + col1 * col2 AS col1 FROM tab1 AS cor0
----
1275
1431
597

query I rowsort
SELECT ( cor0.col1 ) + col1 * + col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + - 33 * - col2 FROM tab0 cor0
----
1089
2706
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-6232
SELECT ALL - 1 DIV cor0.col0 + cor0.col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-6232
SELECT ALL - 1 / cor0.col0 + cor0.col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - 81 * 53 AS col1 FROM tab1 AS cor0
----
-4293
-4293
-4293

query I rowsort
SELECT ALL 9 FROM tab2, tab1 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to b7e6b25481699c3a4ee7381c7eae0817

query I rowsort
SELECT - 12 + - col0 AS col0 FROM tab1 AS cor0
----
-15
-76
-92

query I rowsort
SELECT 95 + cor0.col2 * cor0.col0 FROM tab1 AS cor0
----
257
3743
7775

onlyif mysql # use DIV operator for integer division
query I rowsort label-6237
SELECT ALL col1 DIV + col1 + - col2 AS col1 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-6237
SELECT ALL col1 / + col1 + - col2 AS col1 FROM tab0
----
-32
-81
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6238
SELECT cor0.col0 + + CAST( + 82 AS SIGNED ) FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to 7de8b8b9d12745e66909f15d67996e5f

skipif mysql # not compatible
query I rowsort label-6238
SELECT cor0.col0 + + CAST ( + 82 AS INTEGER ) FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to 7de8b8b9d12745e66909f15d67996e5f

query I rowsort
SELECT + - cor0.col2 * - 0 + - ( - col1 ) FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 41 col2 FROM tab1
----
41
41
41

query I rowsort
SELECT DISTINCT col0 * 61 + + ( + col2 ) FROM tab2 AS cor0
----
454
4784
4857

query I rowsort
SELECT ALL col2 - tab1.col0 * col1 * col1 AS col1 FROM tab1
----
-13424
-1974
-6343

query I rowsort
SELECT - col2 + - ( + col0 + col2 ) FROM tab0 AS cor0
----
-253
-37
-90

query I rowsort
SELECT DISTINCT col0 * 48 AS col2 FROM tab2 AS cor0
----
336
3744
3792

query I rowsort
SELECT col2 * - col1 + - cor0.col1 * col2 AS col0 FROM tab2 cor0
----
-1292
-1674
-3068

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) * 32 FROM tab2, tab0 AS cor0
----
-1056
-2624
-32

query I rowsort
SELECT 13 * col2 * - 43 FROM tab0
----
-18447
-45838
-559

query I rowsort
SELECT DISTINCT col0 * - col0 * + col1 FROM tab2
----
-106097
-1519
-358956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6249
SELECT ALL + - col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6249
SELECT ALL + - col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 65 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

query I rowsort
SELECT tab0.col2 + col2 + col2 FROM tab0
----
246
3
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col1 * 27 - - col1 col2 FROM tab0
----
-2212
-2277
-2487

query I rowsort
SELECT DISTINCT col1 * col2 + + 2 * + col2 * ( tab2.col0 ) FROM tab2
----
1215
5590
6650

query I rowsort
SELECT - col2 * 42 + col1 AS col2 FROM tab2
----
-1033
-1103
-1579

query I rowsort
SELECT ALL - col2 + + ( + col0 ) AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT col2 * 95 FROM tab2 AS cor0
----
2470
2565
3610

query I rowsort
SELECT + col0 * - col2 * - 39 + + col1 + ( + col0 ) * cor0.col0 FROM tab2 cor0
----
123336
7451
85235

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6258
SELECT DISTINCT col2 + CAST( NULL AS SIGNED ) col2 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6258
SELECT DISTINCT col2 + CAST ( NULL AS INTEGER ) col2 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6259
SELECT DISTINCT - 56 DIV - col1 AS col1 FROM tab1
----
2
4
5

skipif mysql # not compatible
query I rowsort label-6259
SELECT DISTINCT - 56 / - col1 AS col1 FROM tab1
----
2
4
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6260
SELECT ALL + CAST( NULL AS SIGNED ) * + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6260
SELECT ALL + CAST ( NULL AS INTEGER ) * + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + 4 * + col1 AS col2 FROM tab1 cor0
----
104
40
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6262
SELECT + + CAST( - col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6262
SELECT + + CAST ( - col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6263
SELECT ALL - + cor0.col2 + - cor0.col0 * - CAST( NULL AS DECIMAL ) * + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6263
SELECT ALL - + cor0.col2 + - cor0.col0 * - CAST ( NULL AS REAL ) * + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6264
SELECT - col1 DIV + tab0.col1 AS col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6264
SELECT - col1 / + tab0.col1 AS col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT - + col2 * - col0 + col0 + - col1 AS col0 FROM tab2 AS cor0
----
165
2047
3064

query I rowsort
SELECT DISTINCT - 36 + col0 FROM tab2 AS cor0
----
-29
42
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-6267
SELECT DISTINCT col0 DIV + col1 col0 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6267
SELECT DISTINCT col0 / + col1 col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + col1 + + col1 * - ( - 11 ) FROM tab0 AS cor0
----
1032
1092
1164

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 * + col2 + - col1 AS col0 FROM tab1
----
2890
3239
9203

onlyif mysql # use DIV operator for integer division
query I rowsort label-6271
SELECT col0 DIV + 56 - + col2 * col0 DIV + ( - col1 + + tab2.col2 ) FROM tab2
----
-141
47
62

skipif mysql # not compatible
query I rowsort label-6271
SELECT col0 / + 56 - + col2 * col0 / + ( - col1 + + tab2.col2 ) FROM tab2
----
-141
47
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 82 col0 FROM tab2
----
-1394
-2542
-4838

query I rowsort
SELECT DISTINCT - tab1.col2 * + 5 AS col0 FROM tab1
----
-270
-285
-480

query I rowsort
SELECT + cor0.col1 FROM tab0, tab2, tab1 cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL + col2 + - 98 FROM tab1 AS cor0
----
-2
-41
-44

query I rowsort
SELECT DISTINCT cor0.col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT tab1.col2 + ( col1 ) FROM tab1
----
109
67
80

query I rowsort
SELECT ALL 31 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT DISTINCT + col1 + - ( + col1 ) FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6280
SELECT + 3 DIV + col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6280
SELECT + 3 / + col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - ( - 26 ) * + col2 FROM tab1 AS cor0
----
1404
1482
2496

query I rowsort
SELECT DISTINCT - 36 * col2 FROM tab2 AS cor0
----
-1368
-936
-972

query I rowsort
SELECT ALL + 34 * + 93 FROM tab1 AS cor0
----
3162
3162
3162

query I rowsort
SELECT DISTINCT ( 51 ) + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-3
-45
-6

query I rowsort
SELECT ALL + ( cor0.col2 ) * col0 + ( - col2 ) + - col1 AS col0 FROM tab1 AS cor0
----
3581
7571
82

query I rowsort
SELECT + ( 95 ) + - cor0.col0 AS col1 FROM tab2 cor0
----
16
17
88

query I rowsort
SELECT DISTINCT - 85 * col1 + - col0 + 33 * + 68 FROM tab2 AS cor0
----
-2849
-398
720

query I rowsort
SELECT ( - col2 ) * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6289
SELECT + CAST( NULL AS DECIMAL ) / ( - col1 * + col2 + ( col2 ) ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6289
SELECT + CAST ( NULL AS REAL ) / ( - col1 * + col2 + ( col2 ) ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - 23 col1 FROM tab2 AS cor0
----
1357
391
713

query I rowsort
SELECT + ( - 56 ) + + col1 FROM tab1 AS cor0
----
-30
-43
-46

query I rowsort
SELECT ( + col0 ) * col0 - col1 FROM tab1 AS cor0
----
-17
4086
6387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 93 + col0 col1 FROM tab1 AS cor0
----
-13
-29
-90

query I rowsort
SELECT DISTINCT col2 + col0 * + cor0.col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL - col2 * + cor0.col1 AS col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT + col2 * col1 - 21 AS col1 FROM tab2 AS cor0
----
1513
625
816

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col1 + + col1 * CAST ( col2 AS REAL ) FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + col0 * - col0 * 76 FROM tab0 AS cor0
----
-43776
-601996
-93100

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6299
SELECT DISTINCT + ( + col2 ) * CAST( NULL AS SIGNED ) + + col1 * + col2 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6299
SELECT DISTINCT + ( + col2 ) * CAST ( NULL AS INTEGER ) + + col1 * + col2 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - 28 * + col1 - col1 * ( - col1 * 77 ) FROM tab0 cor0
----
567084
635089
721777

query I rowsort
SELECT DISTINCT 56 + + col0 FROM tab2 AS cor0
----
134
135
63

query I rowsort
SELECT ALL ( col1 ) * - 82 - - col0 * + col2 AS col2 FROM tab1 AS cor0
----
-1970
2828
6614

query I rowsort
SELECT ALL - col0 + ( - col1 ) FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6304
SELECT ALL + - col1 * + CAST( NULL AS SIGNED ) * - col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6304
SELECT ALL + - col1 * + CAST ( NULL AS INTEGER ) * - col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * cor0.col2 + - col1 col1 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT 46 FROM tab0, tab2 cor0, tab0 AS cor1
----
46

query I rowsort
SELECT col1 * col2 * - col0 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + col0 + + col2 AS col1 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL - 33 AS col2 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

query I rowsort
SELECT DISTINCT cor0.col2 * + col0 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - col0 * + col1 + + 93 FROM tab1 cor0
----
-547
-947
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6312
SELECT - col1 + - CAST( + col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-6312
SELECT - col1 + - CAST ( + col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT + col2 * + col2 + + 93 AS col0 FROM tab0 AS cor0
----
1182
6817
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 91 * + cor0.col1 * col1 col1 FROM tab0 cor0
----
673003
753489
856218

query I rowsort
SELECT DISTINCT - + col2 + - 81 + col1 FROM tab0 AS cor0
----
-28
-72
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-6316
SELECT ALL + col2 DIV + col0 - + col0 AS col2 FROM tab0 AS cor0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-6316
SELECT ALL + col2 / + col0 - + col0 AS col2 FROM tab0 AS cor0
----
-23
-35
-89

query I rowsort
SELECT DISTINCT + col1 * + 32 AS col1 FROM tab0 AS cor0
----
2752
2912
3104

query I rowsort
SELECT + - col2 + col2 + 44 FROM tab1 AS cor0
----
44
44
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - cor0.col1 * - col1 col0 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT + col2 * ( col1 ) + + col1 + + col0 AS col0 FROM tab2 AS cor0
----
1671
742
875

query I rowsort
SELECT + col1 * - 4 + col2 FROM tab1 AS cor0
----
-50
17
44

query I rowsort
SELECT col2 * ( 0 ) + col0 + + col1 * col0 FROM tab0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 * col2 + - col1 col0 FROM tab1 AS cor0
----
1378
1472
2483

query I rowsort
SELECT + + col1 * - cor0.col0 + col0 * + col0 FROM tab0 AS cor0
----
-1488
-178
-2170

query I rowsort
SELECT - - 0 AS col2 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT - col2 * + ( - ( + col2 ) + - col1 ) * + tab2.col1 AS col2 FROM tab2
----
130390
35530
48546

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 45 * + col1 col1 FROM tab2 AS cor0
----
1395
2655
765

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 9 + + cor0.col1 * + ( - 70 ) col2 FROM tab2 AS cor0
----
-1181
-2161
-4121

onlyif mysql # use DIV operator for integer division
query I rowsort label-6329
SELECT 20 DIV col1 + col0 AS col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6329
SELECT 20 / col1 + col0 AS col0 FROM tab0
----
24
35
89

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab0 cor1
----
972 values hashing to deaaa983f771be544ffdc26f04a18657

query I rowsort
SELECT DISTINCT - col2 + col1 * - 73 FROM tab2
----
-1279
-2290
-4333

query I rowsort
SELECT ALL 19 + - col0 + 50 AS col1 FROM tab2
----
-10
-9
62

query I rowsort
SELECT 22 * col1 AS col1 FROM tab0
----
1892
2002
2134

query I rowsort
SELECT DISTINCT + 27 + tab2.col0 FROM tab2
----
105
106
34

query I rowsort
SELECT DISTINCT 99 + + col1 FROM tab0
----
185
190
196

onlyif mysql # use DIV operator for integer division
query I rowsort label-6336
SELECT col1 DIV col1 + tab1.col0 AS col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6336
SELECT col1 / col1 + tab1.col0 AS col0 FROM tab1
----
4
65
81

query I rowsort
SELECT 32 * + col1 FROM tab2
----
1888
544
992

query I rowsort
SELECT ALL - col2 + + cor0.col2 * - 15 * col0 AS col0 FROM tab1 AS cor0
----
-115296
-2484
-54777

onlyif mysql # use DIV operator for integer division
query I rowsort label-6339
SELECT DISTINCT + 82 DIV - col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-6339
SELECT DISTINCT + 82 / - col1 FROM tab0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6340
SELECT 9 * col0 DIV col0 col1 FROM tab0
----
9
9
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6340
SELECT 9 * col0 / col0 col1 FROM tab0
----
9
9
9

query I rowsort
SELECT - 93 * + col0 FROM tab2 AS cor0
----
-651
-7254
-7347

onlyif mysql # use DIV operator for integer division
query I rowsort label-6342
SELECT ( - 16 ) DIV - col0 + + 60 col0 FROM tab0 AS cor0
----
60
60
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6342
SELECT ( - 16 ) / - col0 + + 60 col0 FROM tab0 AS cor0
----
60
60
60

query I rowsort
SELECT ( + 98 ) - - col0 * col2 * cor0.col0 FROM tab1 AS cor0
----
233570
584
614498

onlyif mysql # use DIV operator for integer division
query I rowsort label-6344
SELECT col0 * col1 DIV - col2 FROM tab1
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-6344
SELECT col0 * col1 / - col2 FROM tab1
----
-1
-10
-11

query I rowsort
SELECT + - ( - col2 ) + - 23 FROM tab1 AS cor0
----
31
34
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-6346
SELECT + 92 DIV + col0 AS col2 FROM tab1 AS cor0
----
1
1
30

skipif mysql # not compatible
query I rowsort label-6346
SELECT + 92 / + col0 AS col2 FROM tab1 AS cor0
----
1
1
30

query I rowsort
SELECT + - cor0.col1 * - col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + 52 * + col1 AS col1 FROM tab1 AS cor0
----
1352
520
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6349
SELECT ALL + - col2 + + col0 DIV col0 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-6349
SELECT ALL + - col2 + + col0 / col0 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT - ( + col0 + - col2 ) * + col0 AS col1 FROM tab0
----
-1190
-623
216

query I rowsort
SELECT 30 * col1 FROM tab2
----
1770
510
930

query I rowsort
SELECT ALL - col1 * - cor0.col0 + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT + - 34 AS col1 FROM tab2 cor0
----
-34
-34
-34

query I rowsort
SELECT + - cor0.col2 * col1 * + col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 35 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

onlyif mysql # use DIV operator for integer division
query I rowsort label-6356
SELECT + - 29 DIV - 25 - - col1 * 61 * col0 AS col1 FROM tab0 AS cor0
----
125905
207096
494040

skipif mysql # not compatible
query I rowsort label-6356
SELECT + - 29 / - 25 - - col1 * 61 * col0 AS col1 FROM tab0 AS cor0
----
125905
207096
494040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6357
SELECT DISTINCT + CAST( NULL AS DECIMAL ) * col2 + - col2 * CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6357
SELECT DISTINCT + CAST ( NULL AS REAL ) * col2 + - col2 * CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - ( col1 ) + col2 - - 50 FROM tab2 AS cor0
----
17
46
71

query I rowsort
SELECT + 49 + 27 FROM tab1 AS cor0
----
76
76
76

query I rowsort
SELECT - col0 - col0 * - col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT DISTINCT 84 AS col2 FROM tab0, tab2 cor0
----
84

query I rowsort
SELECT ALL 52 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT col0 * 90 FROM tab1 AS cor0
----
270
5760
7200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6364
SELECT + CAST( col2 AS SIGNED ) * col0 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-6364
SELECT + CAST ( col2 AS INTEGER ) * col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6365
SELECT - + CAST( NULL AS SIGNED ) * - col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6365
SELECT - + CAST ( NULL AS INTEGER ) * - col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6366
SELECT DISTINCT - + col1 + + 66 DIV col1 AS col2 FROM tab2 AS cor0
----
-14
-29
-58

skipif mysql # not compatible
query I rowsort label-6366
SELECT DISTINCT - + col1 + + 66 / col1 AS col2 FROM tab2 AS cor0
----
-14
-29
-58

query I rowsort
SELECT DISTINCT 95 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
95

query I rowsort
SELECT DISTINCT cor0.col1 * + 77 AS col1 FROM tab0 AS cor0
----
6622
7007
7469

query I rowsort
SELECT ALL - col2 - - col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL + + 27 * + col0 FROM tab0 AS cor0
----
2403
648
945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6371
SELECT ALL - col2 + + col0 * CAST( NULL AS SIGNED ) * + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6371
SELECT ALL - col2 + + col0 * CAST ( NULL AS INTEGER ) * + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 76 * - col1 FROM tab0 AS cor0
----
-6536
-6916
-7372

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6373
SELECT CAST( NULL AS SIGNED ) * col1 + tab1.col2 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6373
SELECT CAST ( NULL AS INTEGER ) * col1 + tab1.col2 AS col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6374
SELECT DISTINCT + CAST( NULL AS DECIMAL ) col0 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6374
SELECT DISTINCT + CAST ( NULL AS REAL ) col0 FROM tab0
----
NULL

query I rowsort
SELECT tab0.col1 + + 82 AS col1 FROM tab0
----
168
173
179

query I rowsort
SELECT + + 46 * ( + col2 ) FROM tab0 AS cor0
----
1518
3772
46

query I rowsort
SELECT ALL 29 - + ( + col0 * - col0 ) AS col0 FROM tab1
----
38
4125
6429

query I rowsort
SELECT ALL + - cor0.col1 + 74 * - col1 AS col1 FROM tab1 cor0
----
-1950
-750
-975

query I rowsort
SELECT + col2 * - 97 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
-5212
-5519
-9299

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6380
SELECT - 79 + - col1 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6380
SELECT - 79 + - col1 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 26 - col0 * + 88 AS col2 FROM tab1
----
-238
-5606
-7014

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 47 * - col0 col2 FROM tab0
----
-1128
-1645
-4183

query I rowsort
SELECT 82 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

onlyif mysql # use DIV operator for integer division
query I rowsort label-6384
SELECT DISTINCT 40 DIV cor0.col1 AS col2 FROM tab1, tab0, tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-6384
SELECT DISTINCT 40 / cor0.col1 AS col2 FROM tab1, tab0, tab2 AS cor0
----
0
1
2

query I rowsort
SELECT col0 * tab0.col2 + + col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT col1 * + ( col0 ) - - col1 AS col1 FROM tab2
----
1360
248
4661

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2, tab0 AS cor3
----
3645 values hashing to ced36882687f040e969c817b62d2e456

query I rowsort
SELECT DISTINCT 67 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 cor1, tab0 AS cor2
----
67

query I rowsort
SELECT col0 + ( + 6 ) AS col0 FROM tab0 AS cor0
----
30
41
95

query I rowsort
SELECT ALL col1 + + col2 + col1 AS col0 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT ALL - col1 * 40 FROM tab0 AS cor0
----
-3440
-3640
-3880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + ( 0 ) col0 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6393
SELECT + col1 * + CAST( - col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-6393
SELECT + col1 * + CAST ( - col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * ( - col1 ) + cor0.col2 col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT - col0 * - col2 * 2 + col2 AS col2 FROM tab0 AS cor0
----
14678
1617
71

query I rowsort
SELECT DISTINCT - col1 * 70 FROM tab1
----
-1820
-700
-910

query I rowsort
SELECT col0 * col2 - - col2 FROM tab2 AS cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 2 * col1 * + col2 + 35 col1 FROM tab2 cor0
----
1327
1709
3103

onlyif mysql # use DIV operator for integer division
query I rowsort label-6399
SELECT ALL ( col2 ) DIV col2 - col0 AS col2 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-6399
SELECT ALL ( col2 ) / col2 - col0 AS col2 FROM tab0
----
-23
-34
-88

query I rowsort
SELECT 82 * + col1 * col1 + 17 FROM tab0
----
606489
679059
771555

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + 98 ) col1 FROM tab0
----
98
98
98

query I rowsort
SELECT DISTINCT + - 79 * + col1 * + 26 AS col1 FROM tab1 AS cor0
----
-20540
-26702
-53404

onlyif mysql # use DIV operator for integer division
query I rowsort label-6403
SELECT ALL - - col2 DIV + col0 AS col1 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6403
SELECT ALL - - col2 / + col0 AS col1 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 * - col2 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + cor0.col2 + col0 * + ( col2 + col1 ) FROM tab0 AS cor0
----
15479
2889
3431

query I rowsort
SELECT DISTINCT - col0 * - col1 * - 77 AS col2 FROM tab0 AS cor0
----
-158928
-261415
-623623

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col1 + 13 col0 FROM tab2 AS cor0
----
131
47
75

query I rowsort
SELECT - col2 + + col2 * - col1 + 96 FROM tab0 AS cor0
----
-2
-2775
-7448

query I rowsort
SELECT DISTINCT - 44 * col0 FROM tab1 AS cor0
----
-132
-2816
-3520

query I rowsort
SELECT ALL - 34 * col1 FROM tab0 AS cor0
----
-2924
-3094
-3298

onlyif mysql # use DIV operator for integer division
query I rowsort label-6411
SELECT DISTINCT + 35 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6411
SELECT DISTINCT + 35 / - col0 AS col1 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT - col2 + col0 + - ( 93 ) FROM tab2
----
-113
-41
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6413
SELECT DISTINCT + col0 DIV col1 + col2 + + col2 FROM tab0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-6413
SELECT DISTINCT + col0 / col1 + col2 + + col2 FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT 35 * col1 AS col2 FROM tab1
----
350
455
910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6415
SELECT DISTINCT + col1 * - cor0.col2 + CAST( NULL AS SIGNED ) / 84 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6415
SELECT DISTINCT + col1 * - cor0.col2 + CAST ( NULL AS INTEGER ) / 84 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col2 + ( 24 ) AS col1 FROM tab0 AS cor0
----
106
25
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6417
SELECT + col1 + col2 + col0 DIV col2 FROM tab0 AS cor0
----
119
133
174

skipif mysql # not compatible
query I rowsort label-6417
SELECT + col1 + col2 + col0 / col2 FROM tab0 AS cor0
----
119
133
174

query I rowsort
SELECT + col0 + 49 FROM tab1 AS cor0
----
113
129
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6419
SELECT col0 * CAST( NULL AS SIGNED ) + - ( - col0 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6419
SELECT col0 * CAST ( NULL AS INTEGER ) + - ( - col0 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 79 * col2 col2 FROM tab1
----
4266
4503
7584

query I rowsort
SELECT col0 + col1 - - 72 AS col0 FROM tab1 AS cor0
----
101
146
165

query I rowsort
SELECT + - col2 + - 77 AS col2 FROM tab0 AS cor0
----
-110
-159
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6423
SELECT - col0 * + CAST( NULL AS SIGNED ) - - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6423
SELECT - col0 * + CAST ( NULL AS INTEGER ) - - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * 35 + - col1 * col2 * + 80 AS col2 FROM tab0 AS cor0
----
-227880
-600075
-8985

onlyif mysql # use DIV operator for integer division
query I rowsort label-6425
SELECT ALL - + col2 DIV col0 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-6425
SELECT ALL - + col2 / col0 FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT col0 * - 61 FROM tab1 AS cor0
----
-183
-3904
-4880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6427
SELECT ALL ( col1 ) + col2 * - CAST( + col0 AS SIGNED ) FROM tab1 AS cor0
----
-136
-3638
-7667

skipif mysql # not compatible
query I rowsort label-6427
SELECT ALL ( col1 ) + col2 * - CAST ( + col0 AS INTEGER ) FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-6428
SELECT ALL 77 DIV col2 + col1 AS col2 FROM tab0 AS cor0
----
174
88
91

skipif mysql # not compatible
query I rowsort label-6428
SELECT ALL 77 / col2 + col1 AS col2 FROM tab0 AS cor0
----
174
88
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 72 col2 FROM tab2, tab0 AS cor0
----
72

query I rowsort
SELECT 83 + - col1 FROM tab0 AS cor0
----
-14
-3
-8

query I rowsort
SELECT DISTINCT + ( + col0 ) * - col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + col1 * col1 + col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT col1 * tab1.col2 + - col0 * ( tab1.col2 + col2 ) AS col0 FROM tab1
----
-14112
-6726
1080

query I rowsort
SELECT DISTINCT + col0 * + cor0.col2 + col2 * ( + col1 + - cor0.col0 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + cor0.col2 + + col2 * - col2 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT ALL + - col0 - cor0.col1 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - - 29 * + col2 FROM tab1 AS cor0
----
1566
1653
2784

query I rowsort
SELECT + - 76 * - cor0.col2 FROM tab0 AS cor0
----
2508
6232
76

query I rowsort
SELECT ALL ( - col0 ) * - col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - col0 * col1 - col2 * + col1 FROM tab2 AS cor0
----
-1054
-1989
-6136

onlyif mysql # use DIV operator for integer division
query I rowsort label-6441
SELECT - 91 DIV col2 AS col0 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6441
SELECT - 91 / col2 AS col0 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL - - col0 + - col0 * + col1 * col1 AS col2 FROM tab0 AS cor0
----
-177480
-329280
-736920

query I rowsort
SELECT ALL - col0 * 42 AS col1 FROM tab0 cor0
----
-1008
-1470
-3738

query I rowsort
SELECT col0 * - 32 FROM tab2 AS cor0
----
-224
-2496
-2528

onlyif mysql # use DIV operator for integer division
query I rowsort label-6445
SELECT - - col0 + - col0 DIV + cor0.col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6445
SELECT - - col0 + - col0 / + cor0.col0 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT ALL + tab1.col2 - ( - col2 ) FROM tab1
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-6447
SELECT cor0.col0 * col0 DIV col0 + ( 24 ) * + col1 FROM tab1 cor0
----
304
392
627

skipif mysql # not compatible
query I rowsort label-6447
SELECT cor0.col0 * col0 / col0 + ( 24 ) * + col1 FROM tab1 cor0
----
304
392
627

query I rowsort
SELECT ( - 71 ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6449
SELECT DISTINCT col2 + + CAST( 5 AS SIGNED ) + + col1 AS col1 FROM tab0 AS cor0
----
103
124
178

skipif mysql # not compatible
query I rowsort label-6449
SELECT DISTINCT col2 + + CAST ( 5 AS INTEGER ) + + col1 AS col1 FROM tab0 AS cor0
----
103
124
178

query I rowsort
SELECT DISTINCT + col1 + - col0 * col0 + col0 FROM tab0
----
-1093
-466
-7741

query I rowsort
SELECT - cor0.col0 * 15 AS col2 FROM tab1 AS cor0
----
-1200
-45
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6452
SELECT + cor0.col1 + col0 DIV - ( + col0 ) AS col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6452
SELECT + cor0.col1 + col0 / - ( + col0 ) AS col0 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT col2 * + 65 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT ALL 29 FROM tab2 cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 40739d223aa019bd2dfe2db99d596302

query I rowsort
SELECT DISTINCT - col0 + + ( col0 * + col1 ) + - col2 * + col0 AS col2 FROM tab1 AS cor0
----
-3072
-6720
-87

query I rowsort
SELECT cor0.col0 + + 92 AS col2 FROM tab2 AS cor0
----
170
171
99

query I rowsort
SELECT ALL - cor0.col0 * 81 AS col1 FROM tab1 AS cor0
----
-243
-5184
-6480

query I rowsort
SELECT ALL + cor0.col1 * col2 + cor0.col1 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-124
-1947
357

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + ( col0 ) * - cor0.col1 * col1 col0 FROM tab2 AS cor0
----
-22814
-271459
-6696

query I rowsort
SELECT ALL - col0 * - cor0.col1 + - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL + col2 * + col1 * col2 - - col1 FROM tab1 AS cor0
----
119821
32500
75842

query I rowsort
SELECT + + col1 + - 42 * 24 * + col1 AS col2 FROM tab0 AS cor0
----
-86602
-91637
-97679

query I rowsort
SELECT ALL + + cor0.col0 * 59 - - col1 * col1 FROM tab2 AS cor0
----
1374
4950
8083

query I rowsort
SELECT ALL + 91 * 19 FROM tab0 cor0
----
1729
1729
1729

query I rowsort
SELECT ALL + col2 * 94 + col1 FROM tab0 AS cor0
----
191
3188
7799

query I rowsort
SELECT DISTINCT + + 92 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1442
-554
-745

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 15 col1 FROM tab2 AS cor0
----
255
465
885

query I rowsort
SELECT DISTINCT + col0 * + col1 + col2 * - cor0.col1 FROM tab2 AS cor0
----
-620
3068
697

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0, tab0 cor2
----
3645 values hashing to 97b43fbe79eecd0bc6921392403b666d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 82 * col2 col2 FROM tab1
----
4428
4674
7872

query I rowsort
SELECT + cor0.col1 + col1 + col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT DISTINCT + - cor0.col1 * cor0.col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - - 93 * col1 FROM tab2 cor0
----
1581
2883
5487

query I rowsort
SELECT DISTINCT + - 70 * + col2 + 68 + col0 * - col1 AS col1 FROM tab0 AS cor0
----
-13771
-3397
-4306

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * cor0.col0 col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - + col0 * + col2 + - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * col0 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 25 col2 FROM tab2
----
-25
-25
-25

query I rowsort
SELECT + col0 + + 54 * + col2 FROM tab0 cor0
----
1806
4517
89

query I rowsort
SELECT ALL col0 + - ( + col0 ) + + col1 * + col1 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-6481
SELECT DISTINCT - col1 + col2 DIV + col2 FROM tab1
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-6481
SELECT DISTINCT - col1 + col2 / + col2 FROM tab1
----
-12
-25
-9

query I rowsort
SELECT + col2 + col1 - + col2 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6483
SELECT - cor0.col1 DIV 90 - - col1 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6483
SELECT - cor0.col1 / 90 - - col1 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) * col0 - + col2 col1 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT ALL ( - 8 ) FROM tab0 cor0
----
-8
-8
-8

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab1 cor1, tab0, tab1 cor2
----
3645 values hashing to f9101173abc9e524c6310e6c0eeefb0c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + + col2 col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6488
SELECT ALL + CAST( 8 AS SIGNED ) * - cor0.col1 - + 2 FROM tab1 AS cor0
----
-106
-210
-82

skipif mysql # not compatible
query I rowsort label-6488
SELECT ALL + CAST ( 8 AS INTEGER ) * - cor0.col1 - + 2 FROM tab1 AS cor0
----
-106
-210
-82

query I rowsort
SELECT + col0 + 53 AS col1 FROM tab1 AS cor0
----
117
133
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-6490
SELECT ALL - 74 DIV - col0 AS col2 FROM tab0 cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-6490
SELECT ALL - 74 / - col0 AS col2 FROM tab0 cor0
----
0
2
3

query I rowsort
SELECT - col1 * - ( + col1 + + 13 ) FROM tab0 AS cor0
----
10670
8514
9464

query I rowsort
SELECT DISTINCT + 11 + col1 FROM tab2
----
28
42
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6493
SELECT ALL 43 + col0 DIV - tab1.col0 col1 FROM tab1
----
42
42
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6493
SELECT ALL 43 + col0 / - tab1.col0 col1 FROM tab1
----
42
42
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6494
SELECT - CAST( col2 AS SIGNED ) + - tab2.col1 * + 25 + col2 * + col1 AS col2 FROM tab2
----
183
33
35

skipif mysql # not compatible
query I rowsort label-6494
SELECT - CAST ( col2 AS INTEGER ) + - tab2.col1 * + 25 + col2 * + col1 AS col2 FROM tab2
----
183
33
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-6495
SELECT + ( 6 ) DIV - col1 + + 8 FROM tab2
----
8
8
8

skipif mysql # not compatible
query I rowsort label-6495
SELECT + ( 6 ) / - col1 + + 8 FROM tab2
----
8
8
8

query I rowsort
SELECT DISTINCT + 10 + col2 FROM tab2
----
36
37
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-6497
SELECT ALL col0 + col0 DIV + col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-6497
SELECT ALL col0 + col0 / + col0 FROM tab0
----
25
36
90

query I rowsort
SELECT 3 + + tab0.col2 + + col1 AS col0 FROM tab0
----
101
122
176

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6499
SELECT cor0.col1 * CAST( - col2 + col0 * - col1 AS SIGNED ) FROM tab2 cor0
----
-23477
-273052
-7564

skipif mysql # not compatible
query I rowsort label-6499
SELECT cor0.col1 * CAST ( - col2 + col0 * - col1 AS INTEGER ) FROM tab2 cor0
----
-23477
-273052
-7564

query I rowsort
SELECT ALL - col0 + 40 AS col0 FROM tab1 AS cor0
----
-24
-40
37

query I rowsort
SELECT DISTINCT + - col2 + + 65 AS col1 FROM tab2 AS cor0
----
27
38
39

query I rowsort
SELECT ALL - col1 + + 49 FROM tab0 AS cor0
----
-37
-42
-48

query I rowsort
SELECT ALL - col1 * - 11 + col2 AS col2 FROM tab2 AS cor0
----
225
368
675

query I rowsort
SELECT DISTINCT - - col0 * 74 + - cor0.col1 FROM tab0 cor0
----
1690
2493
6495

query I rowsort
SELECT - col2 * ( col0 * col1 ) FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + col2 + - ( - 77 ) * col0 AS col2 FROM tab0 AS cor0
----
1881
2696
6935

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + tab0.col0 col2 FROM tab0
----
0
0
0

query I rowsort
SELECT + col2 + - col0 * - col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT ALL + + col1 * ( 87 ) FROM tab0 cor0
----
7482
7917
8439

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6510
SELECT ALL col1 + CAST( - 44 AS SIGNED ) * col1 FROM tab1 AS cor0
----
-1118
-430
-559

skipif mysql # not compatible
query I rowsort label-6510
SELECT ALL col1 + CAST ( - 44 AS INTEGER ) * col1 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT DISTINCT - col0 * - ( col2 ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6512
SELECT col1 + - 48 DIV col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6512
SELECT col1 + - 48 / col2 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6513
SELECT ALL - col2 * - col1 DIV - col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6513
SELECT ALL - col2 * - col1 / - col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT tab0.col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + 51 * cor0.col2 col0 FROM tab0 AS cor0
----
1716
4264
52

query I rowsort
SELECT 10 + - tab0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to ec7aa7ce249de33ba5b61fbec6557431

onlyif mysql # use DIV operator for integer division
query I rowsort label-6517
SELECT - col1 * 61 DIV - col1 AS col0 FROM tab0 AS cor0
----
61
61
61

skipif mysql # not compatible
query I rowsort label-6517
SELECT - col1 * 61 / - col1 AS col0 FROM tab0 AS cor0
----
61
61
61

query I rowsort
SELECT ( + col1 ) * + col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - 97 * - col2 FROM tab2 AS cor0
----
2522
2619
3686

query I rowsort
SELECT + cor0.col2 + tab1.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 35de0b553e14f89ea44b7652e1ff642c

query I rowsort
SELECT + + cor0.col2 * - col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL col2 * + col1 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT - col2 * col2 - - 48 AS col0 FROM tab2 AS cor0
----
-1396
-628
-681

query I rowsort
SELECT + 3 * + col1 + + ( - col1 ) FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6525
SELECT DISTINCT + cor0.col1 DIV - col2 + - cor0.col0 * + col0 * col1 FROM tab1 AS cor0
----
-234
-40960
-83200

skipif mysql # not compatible
query I rowsort label-6525
SELECT DISTINCT + cor0.col1 / - col2 + - cor0.col0 * + col0 * col1 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-6526
SELECT DISTINCT - - col2 * + col2 + - ( ( - col1 ) ) DIV + 30 + + col1 AS col1 FROM tab2 cor0
----
1461
736
761

skipif mysql # not compatible
query I rowsort label-6526
SELECT DISTINCT - - col2 * + col2 + - ( ( - col1 ) ) / + 30 + + col1 AS col1 FROM tab2 cor0
----
1461
736
761

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + cor0.col2 * 14 col1 FROM tab1 AS cor0
----
1264
734
753

query I rowsort
SELECT ALL - - col1 * col1 + - col2 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT - cor0.col0 * + col0 + ( col0 ) AS col1 FROM tab2 cor0
----
-42
-6006
-6162

query I rowsort
SELECT 65 + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cf2396fc79e2238c86a2ca3715638b64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6531
SELECT col0 + + col2 * CAST( 22 AS SIGNED ) AS col1 FROM tab1 cor0
----
1191
1318
2192

skipif mysql # not compatible
query I rowsort label-6531
SELECT col0 + + col2 * CAST ( 22 AS INTEGER ) AS col1 FROM tab1 cor0
----
1191
1318
2192

query I rowsort
SELECT ALL + + 15 * col2 AS col2 FROM tab0 AS cor0
----
1230
15
495

query I rowsort
SELECT DISTINCT + - cor0.col2 + col2 * 11 AS col0 FROM tab1 AS cor0
----
540
570
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6534
SELECT ( col0 ) + + col1 * + CAST( NULL AS SIGNED ) * 35 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6534
SELECT ( col0 ) + + col1 * + CAST ( NULL AS INTEGER ) * 35 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 71 + + col2 col2 FROM tab0 AS cor0
----
104
153
72

query I rowsort
SELECT 65 * ( + col1 ) + + col1 FROM tab2 AS cor0
----
1122
2046
3894

query I rowsort
SELECT DISTINCT col0 * tab2.col0 + - col2 AS col0 FROM tab2
----
22
6058
6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6538
SELECT CAST( NULL AS SIGNED ) * + tab0.col1 + col1 * - tab0.col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6538
SELECT CAST ( NULL AS INTEGER ) * + tab0.col1 + col1 * - tab0.col1 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 90 + - col2 * col2 AS col2 FROM tab0
----
-1179
-6814
-91

query I rowsort
SELECT - ( col1 ) + - col0 * + col2 FROM tab1 cor0
----
-188
-3658
-7693

query I rowsort
SELECT col0 + - 12 AS col1 FROM tab0 AS cor0
----
12
23
77

query I rowsort
SELECT + 78 + 40 * col0 FROM tab0 AS cor0
----
1038
1478
3638

query I rowsort
SELECT ALL - - cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL - ( col2 ) * + col0 + col2 + - col1 FROM tab2
----
-193
-2061
-2981

query I rowsort
SELECT + + col0 + - col0 * col1 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT - + cor0.col1 * col1 + - col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT ALL - col2 * + cor0.col1 * col0 AS col2 FROM tab0 cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-6548
SELECT ALL - 80 DIV + tab1.col0 AS col2 FROM tab1
----
-1
-1
-26

skipif mysql # not compatible
query I rowsort label-6548
SELECT ALL - 80 / + tab1.col0 AS col2 FROM tab1
----
-1
-1
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col1 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL 94 * cor0.col0 + - col1 * - 95 AS col1 FROM tab0 AS cor0
----
10426
12505
17011

query I rowsort
SELECT - 51 * col1 + cor0.col2 * + col0 FROM tab1 cor0
----
-1164
3138
7017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 42 * cor0.col2 col2 FROM tab2 AS cor0
----
1092
1134
1596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 14 col2 FROM tab2 AS cor0
----
-14
-14
-14

query I rowsort
SELECT ALL + - 87 * col2 + + col2 FROM tab2 AS cor0
----
-2236
-2322
-3268

onlyif mysql # use DIV operator for integer division
query I rowsort label-6555
SELECT col2 DIV + col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6555
SELECT col2 / + col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col0 * + 68 col0 FROM tab2 AS cor0
----
483
5382
5451

query I rowsort
SELECT DISTINCT col0 - ( - col1 ) FROM tab0
----
110
132
180

query I rowsort
SELECT - col1 * + 93 + - col0 + col0 AS col1 FROM tab1
----
-1209
-2418
-930

query I rowsort
SELECT col0 + + col2 - + 74 FROM tab1
----
-17
102
47

query I rowsort
SELECT ALL col1 + + 93 * col2 - col1 FROM tab1
----
5022
5301
8928

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 - - 76 col1 FROM tab1 AS cor0
----
-20
19
22

query I rowsort
SELECT + col2 * ( col2 ) - - col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT - cor0.col0 * 8 + col1 * 23 - col2 AS col2 FROM tab2 AS cor0
----
-279
630
707

query I rowsort
SELECT DISTINCT 27 * - col2 AS col1 FROM tab1 AS cor0
----
-1458
-1539
-2592

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6565
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + - col2 * col1 * - 47 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6565
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + - col2 * col1 * - 47 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col1 * + 96 + + cor0.col1 + ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
1027
1357
2576

query I rowsort
SELECT - col0 * - col1 * - col1 + col1 FROM tab2 AS cor0
----
-22814
-271459
-6696

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col0 + - col0 col2 FROM tab2 AS cor0
----
42
6006
6162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6569
SELECT DISTINCT CAST( NULL AS SIGNED ) / col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6569
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 ALL + + ( ( + col1 ) ) col2 FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6571
SELECT col1 DIV 72 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6571
SELECT col1 / 72 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 88 + - ( col2 ) col2 FROM tab2 AS cor0
----
50
61
62

query I rowsort
SELECT - 48 + 90 + col0 FROM tab1 AS cor0
----
106
122
45

query I rowsort
SELECT ALL ( - tab1.col1 ) FROM tab1, tab2 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT ALL - col1 - ( tab2.col0 ) AS col0 FROM tab2
----
-137
-38
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6576
SELECT ALL - + CAST( col1 AS SIGNED ) + - col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-6576
SELECT ALL - + CAST ( col1 AS INTEGER ) + - col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6577
SELECT ALL + col1 * 25 DIV col0 FROM tab1 AS cor0
----
216
3
4

skipif mysql # not compatible
query I rowsort label-6577
SELECT ALL + col1 * 25 / col0 FROM tab1 AS cor0
----
216
3
4

query I rowsort
SELECT ( + col2 ) + - 43 * + col2 AS col1 FROM tab1
----
-2268
-2394
-4032

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6579
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6579
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT - + ( 69 ) FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
-69

query I rowsort
SELECT ALL cor0.col2 * - col2 * ( + col1 ) + col2 AS col2 FROM tab0 AS cor0
----
-611802
-93621
-96

query I rowsort
SELECT ALL + col2 + 91 FROM tab0 cor0
----
124
173
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-6583
SELECT DISTINCT tab2.col1 DIV - col1 AS col1 FROM tab2
----
-1

skipif mysql # not compatible
query I rowsort label-6583
SELECT DISTINCT tab2.col1 / - col1 AS col1 FROM tab2
----
-1

query I rowsort
SELECT + 86 AS col1 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT DISTINCT + col0 * + ( + col2 * + col2 ) AS col2 FROM tab0
----
26136
35
598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 28 col2 FROM tab0, tab0 AS cor0, tab1 cor1, tab2, tab2 AS cor2
----
243 values hashing to 10ed4d350e75fd84e2069195cbaf9c3d

query I rowsort
SELECT DISTINCT + 65 AS col2 FROM tab0, tab0 AS cor0
----
65

query I rowsort
SELECT col1 + 57 * col0 AS col2 FROM tab0 AS cor0
----
1454
2092
5164

query I rowsort
SELECT - col2 * ( + 89 * cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-136526
-57494
-74493

query I rowsort
SELECT - col2 * 53 FROM tab2 AS cor0
----
-1378
-1431
-2014

query I rowsort
SELECT + 29 - 12 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 * + tab0.col0 col0 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6593
SELECT ALL + col1 DIV ( + col0 ) FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-6593
SELECT ALL + col1 / ( + col0 ) FROM tab0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + cor0.col1 col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT col1 + + 87 * col0 FROM tab2 AS cor0
----
640
6845
6890

query I rowsort
SELECT DISTINCT - + cor0.col0 + + cor0.col2 FROM tab2 cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 33 * ( - col1 ) col2 FROM tab0 cor0
----
-2838
-3003
-3201

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6598
SELECT ALL CAST( NULL AS SIGNED ) * + 65 * col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6598
SELECT ALL CAST ( NULL AS INTEGER ) * + 65 * col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 * col1 + col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-6600
SELECT col2 DIV col2 + col0 + + col0 FROM tab0 cor0
----
179
49
71

skipif mysql # not compatible
query I rowsort label-6600
SELECT col2 / col2 + col0 + + col0 FROM tab0 cor0
----
179
49
71

query I rowsort
SELECT + - 56 * col1 AS col0 FROM tab0 AS cor0
----
-4816
-5096
-5432

query I rowsort
SELECT ALL + + cor0.col1 + col1 AS col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6603
SELECT DISTINCT col0 * col0 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6603
SELECT DISTINCT col0 * col0 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - 10 * + col2 FROM tab0 AS cor0
----
-10
-330
-820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6605
SELECT - 76 + - 11 * col2 * CAST( NULL AS SIGNED ) col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6605
SELECT - 76 + - 11 * col2 * CAST ( NULL AS INTEGER ) col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * col0 * col2 + + 47 AS col2 FROM tab2
----
1370
158231
237205

query I rowsort
SELECT + 63 FROM tab1 cor0
----
63
63
63

query I rowsort
SELECT ALL col0 * ( + col1 ) FROM tab1
----
1040
640
78

query I rowsort
SELECT - + 99 + col0 * col1 AS col2 FROM tab2 AS cor0
----
118
1244
4503

query I rowsort
SELECT ALL col1 * 50 + - col1 FROM tab2 cor0
----
1519
2891
833

query I rowsort
SELECT - col0 + 54 * + col1 FROM tab2 AS cor0
----
1667
3108
839

query I rowsort
SELECT cor0.col2 * ( - 51 ) FROM tab1 AS cor0
----
-2754
-2907
-4896

query I rowsort
SELECT ALL col0 * - 21 + cor0.col2 AS col2 FROM tab2 cor0
----
-120
-1612
-1621

query I rowsort
SELECT ALL + + cor0.col1 * + 92 FROM tab2 AS cor0
----
1564
2852
5428

query I rowsort
SELECT DISTINCT 7 * col0 FROM tab0
----
168
245
623

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6616
SELECT DISTINCT col1 + CAST( - col2 AS SIGNED ) AS col1 FROM tab0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-6616
SELECT DISTINCT col1 + CAST ( - col2 AS INTEGER ) AS col1 FROM tab0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6617
SELECT DISTINCT - col1 + + CAST( + 55 + tab1.col0 AS SIGNED ) FROM tab1
----
109
122
32

skipif mysql # not compatible
query I rowsort label-6617
SELECT DISTINCT - col1 + + CAST ( + 55 + tab1.col0 AS INTEGER ) FROM tab1
----
109
122
32

query I rowsort
SELECT - - 0 * 75 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6619
SELECT - CAST( NULL AS SIGNED ) * col0 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6619
SELECT - CAST ( NULL AS INTEGER ) * col0 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 47 + col0 * col2 col0 FROM tab0 AS cor0
----
7345
82
839

query I rowsort
SELECT col1 * 37 AS col2 FROM tab1
----
370
481
962

query I rowsort
SELECT DISTINCT col0 + + 75 * col0 FROM tab0
----
1824
2660
6764

query I rowsort
SELECT col0 * - col0 + + 77 AS col1 FROM tab0
----
-1148
-499
-7844

query I rowsort
SELECT col1 * 88 * + 41 AS col2 FROM tab1
----
36080
46904
93808

query I rowsort
SELECT - 99 AS col2 FROM tab1
----
-99
-99
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6626
SELECT - - CAST( - col0 AS SIGNED ) * + col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-6626
SELECT - - CAST ( - col0 AS INTEGER ) * + col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6627
SELECT - - CAST( NULL AS SIGNED ) + col1 / col0 + - ( + col1 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6627
SELECT - - CAST ( NULL AS INTEGER ) + col1 / col0 + - ( + col1 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( cor0.col2 ) * + col2 * - 42 + cor0.col2 + col0 FROM tab2 AS cor0
----
-28288
-30584
-60531

query I rowsort
SELECT - + cor0.col2 * 94 * col0 - - col0 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-15306
-343552
-722960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6630
SELECT DISTINCT - col1 * col1 + + col0 * - col0 + - CAST( col2 AS SIGNED ) FROM tab2
----
-1037
-6568
-9591

skipif mysql # not compatible
query I rowsort label-6630
SELECT DISTINCT - col1 * col1 + + col0 * - col0 + - CAST ( col2 AS INTEGER ) FROM tab2
----
-1037
-6568
-9591

onlyif mysql # use DIV operator for integer division
query I rowsort label-6631
SELECT + cor0.col1 + - cor0.col1 DIV cor0.col2 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6631
SELECT + cor0.col1 + - cor0.col1 / cor0.col2 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL tab2.col2 + 43 + - ( col0 ) FROM tab2
----
-9
2
63

query I rowsort
SELECT ALL cor0.col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( col1 AS REAL ) * - col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6635
SELECT + col1 DIV - 9 AS col0 FROM tab2 AS cor0
----
-1
-3
-6

skipif mysql # not compatible
query I rowsort label-6635
SELECT + col1 / - 9 AS col0 FROM tab2 AS cor0
----
-1
-3
-6

query I rowsort
SELECT ALL col2 * + col2 * col2 AS col1 FROM tab1 AS cor0
----
157464
185193
884736

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 93 + - 65 col0 FROM tab1 AS cor0
----
-158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 - - cor0.col0 col0 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-6639
SELECT - + 7 DIV - col0 + + col0 FROM tab2 AS cor0
----
78
79
8

skipif mysql # not compatible
query I rowsort label-6639
SELECT - + 7 / - col0 + + col0 FROM tab2 AS cor0
----
78
79
8

query I rowsort
SELECT 85 + col0 AS col1 FROM tab2 cor0
----
163
164
92

query I rowsort
SELECT ALL + 56 + col0 * ( - col0 ) AS col0 FROM tab0 AS cor0
----
-1169
-520
-7865

query I rowsort
SELECT - col0 - - cor0.col1 AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL ( col2 ) + + col2 * col0 AS col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + col2 + col2 - 57 * + 51 AS col2 FROM tab2 AS cor0
----
-2831
-2853
-2855

onlyif mysql # use DIV operator for integer division
query I rowsort label-6645
SELECT + 87 * 60 DIV tab0.col0 AS col1 FROM tab0
----
149
217
58

skipif mysql # not compatible
query I rowsort label-6645
SELECT + 87 * 60 / tab0.col0 AS col1 FROM tab0
----
149
217
58

query I rowsort
SELECT ALL - + col2 + col1 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + - col0 + + col2 * col2 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT col2 * + col1 + - col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL + col2 * - col0 - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT + + col2 + + col1 * col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT + col2 * 44 + col0 * + col2 AS col2 FROM tab1 AS cor0
----
11904
2538
6156

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6652
SELECT ALL - + col0 + CAST( NULL AS SIGNED ) * + 5 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6652
SELECT ALL - + col0 + CAST ( NULL AS INTEGER ) * + 5 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 62 col0 FROM tab0 cor0
----
-20
29
61

query I rowsort
SELECT DISTINCT - cor0.col0 + + col1 * col0 * col1 FROM tab1 cor0
----
13440
2025
6336

onlyif mysql # use DIV operator for integer division
query I rowsort label-6655
SELECT DISTINCT col0 DIV + col0 - + col0 AS col1 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-6655
SELECT DISTINCT col0 / + col0 - + col0 AS col1 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT DISTINCT col2 + ( + col1 ) * - col2 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + ( ( + col2 ) * col0 ) col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL + col2 + + ( col2 * col1 ) AS col2 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT + col0 * col1 + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL + + col1 * + col0 + + col2 AS col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT col0 * 46 - - col2 * col2 AS col2 FROM tab1 AS cor0
----
12896
3054
6193

query I rowsort
SELECT - col0 * col2 + - cor0.col0 AS col0 FROM tab2 cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL + col1 + col1 * 72 FROM tab1 AS cor0
----
1898
730
949

query I rowsort
SELECT - col0 - + col0 AS col1 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT ALL - - col0 * + 55 + cor0.col0 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT DISTINCT + col2 - 62 AS col1 FROM tab0 AS cor0
----
-29
-61
20

query I rowsort
SELECT cor0.col0 * + 26 - - ( col2 ) FROM tab2 AS cor0
----
2054
209
2092

onlyif mysql # use DIV operator for integer division
query I rowsort label-6668
SELECT DISTINCT col0 DIV col0 + col0 * - col1 AS col2 FROM tab1 AS cor0
----
-1039
-639
-77

skipif mysql # not compatible
query I rowsort label-6668
SELECT DISTINCT col0 / col0 + col0 * - col1 AS col2 FROM tab1 AS cor0
----
-1039
-639
-77

query I rowsort
SELECT col2 + cor0.col0 * + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 74 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT + 32 + - tab1.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to b6ba64c61c7f186ddb684b88d1ab8c21

onlyif mysql # use DIV operator for integer division
query I rowsort label-6672
SELECT ALL col2 DIV 34 + + col0 col1 FROM tab2
----
7
78
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6672
SELECT ALL col2 / 34 + + col0 col1 FROM tab2
----
7
78
80

query I rowsort
SELECT DISTINCT cor0.col2 + - col0 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - + cor0.col1 * - col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - - col0 col2 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 2 col2 FROM tab1 AS cor0
----
-2
-2
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6677
SELECT + - cor0.col1 DIV - col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-6677
SELECT + - cor0.col1 / - col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT col0 + 37 AS col2 FROM tab0
----
126
61
72

query I rowsort
SELECT col1 + - col1 * + ( + col1 ) FROM tab1
----
-156
-650
-90

query I rowsort
SELECT - + 66 * - cor0.col1 FROM tab1 AS cor0
----
1716
660
858

query I rowsort
SELECT DISTINCT tab0.col1 + col1 - 8 * - ( - col0 ) AS col0 FROM tab0
----
-20
-530
-86

query I rowsort
SELECT DISTINCT - + 73 FROM tab1 AS cor0
----
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-6683
SELECT ALL + 21 DIV + col0 AS col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-6683
SELECT ALL + 21 / + col0 AS col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT + 59 * - col2 AS col2 FROM tab1 cor0
----
-3186
-3363
-5664

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( + col0 ) IN ( col0 )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE col2 * col1 <= col1
----

query I rowsort
SELECT col1 + - col0 + - col0 AS col0 FROM tab2
----
-141
-97
17

query I rowsort
SELECT col2 * - col0 - + col0 * col2 FROM tab2
----
-378
-4056
-6004

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( + col0 ) IN ( + col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT + col1 * col1 * col2 AS col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT - 12 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 3983bffe2adf88cb2efc3be93ee620c0

query I rowsort
SELECT DISTINCT - col2 * - col2 + cor0.col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT - - col2 * col0 * - col0 AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT - col2 FROM tab0 WHERE NOT NULL <> ( NULL )
----

query I rowsort
SELECT ALL col1 * + tab1.col1 + - col0 + - col2 AS col2 FROM tab1
----
-21
-7
619

query I rowsort
SELECT ALL col0 * + col2 + + tab0.col1 * + col2 * + tab0.col1 FROM tab0
----
244860
686340
9444

query I rowsort
SELECT tab2.col1 + + col2 AS col2 FROM tab2 WHERE NOT NULL IN ( col1 )
----

query I rowsort
SELECT DISTINCT + col1 + col2 * - col1 AS col2 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT cor0.col0 * - col0 - col1 AS col1 FROM tab0 cor0
----
-1322
-662
-8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-6700
SELECT DISTINCT + col1 DIV cor0.col0 - col0 FROM tab0 AS cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-6700
SELECT DISTINCT + col1 / cor0.col0 - col0 FROM tab0 AS cor0
----
-21
-33
-88

query I rowsort
SELECT + col0 FROM tab1 AS cor0 WHERE NULL <= NULL
----

query I rowsort
SELECT DISTINCT col1 * col1 * + tab1.col1 FROM tab1
----
1000
17576
2197

onlyif mysql # use DIV operator for integer division
query I rowsort label-6703
SELECT - col2 DIV col2 + + col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-6703
SELECT - col2 / col2 + + col0 FROM tab1
----
2
63
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6704
SELECT ALL col2 + tab1.col0 DIV + col1 FROM tab1
----
102
54
63

skipif mysql # not compatible
query I rowsort label-6704
SELECT ALL col2 + tab1.col0 / + col1 FROM tab1
----
102
54
63

query III rowsort
SELECT * FROM tab1 WHERE col0 / - col1 >= NULL
----

query I rowsort
SELECT DISTINCT + col2 - col2 FROM tab0 WHERE NULL NOT BETWEEN + col2 * + col2 AND NULL
----

query I rowsort
SELECT - col0 * + col0 + - col1 AS col1 FROM tab1
----
-35
-4106
-6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + tab1.col2 * col1 col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT + col2 FROM tab1 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT ALL + col0 * col1 + col1 FROM tab1 WHERE - col0 NOT IN ( - col0 )
----

query I rowsort
SELECT ALL + col1 + + tab0.col0 + - col1 AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT col1 + + col2 + col1 * + col1 AS col0 FROM tab1
----
167
278
756

query I rowsort
SELECT ALL - col1 AS col0 FROM tab0 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT col0 + - col0 + col2 FROM tab1
----
54
57
96

query I rowsort
SELECT tab0.col2 * + col1 + col2 * col2 AS col0 FROM tab0
----
14186
3927
98

query III rowsort
SELECT * FROM tab0 WHERE - col0 * col1 IN ( col0 + tab0.col2 * + col1 )
----

query I rowsort
SELECT + tab0.col0 FROM tab0 WHERE col1 * col1 <> ( col2 * + col2 + + col1 )
----
24
35
89

query I rowsort
SELECT col0 * col1 + col0 + col0 FROM tab1
----
1200
768
84

query I rowsort
SELECT - col1 + - col0 - + col0 * + col2 FROM tab2
----
-2165
-227
-3098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * tab1.col2 * col0 col1 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT + 57 * - tab2.col0 FROM tab2
----
-399
-4446
-4503

query I rowsort
SELECT DISTINCT + cor0.col2 + cor0.col0 AS col2 FROM tab2, tab2 cor0
----
104
117
34

query I rowsort
SELECT 56 + col0 AS col0 FROM tab1 cor0
----
120
136
59

query I rowsort
SELECT - + col0 * col1 * col2 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + col0 * - col0 + - col2 AS col2 FROM tab1 cor0
----
-4153
-63
-6496

query I rowsort
SELECT - 13 + + col0 FROM tab0 AS cor0
----
11
22
76

query I rowsort
SELECT 32 + - col2 * + 21 FROM tab2 cor0
----
-514
-535
-766

onlyif mysql # use DIV operator for integer division
query I rowsort label-6728
SELECT + col1 DIV - col2 + col1 AS col2 FROM tab0 AS cor0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-6728
SELECT + col1 / - col2 + col1 AS col2 FROM tab0 AS cor0
----
0
84
90

query I rowsort
SELECT - + col1 * - col2 + col1 * + col2 * col1 FROM tab0 AS cor0
----
246906
686504
9506

query I rowsort
SELECT col2 * - cor0.col2 + col1 AS col0 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT ( + col2 ) * 39 AS col0 FROM tab0 AS cor0
----
1287
3198
39

query I rowsort
SELECT - col1 + + col2 * - col0 * + 38 FROM tab2 cor0
----
-114093
-7213
-77123

query I rowsort
SELECT - 10 * cor0.col1 + + ( - cor0.col2 ) AS col1 FROM tab2 AS cor0
----
-208
-337
-616

query I rowsort
SELECT col2 * ( + ( col2 ) ) FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6735
SELECT DISTINCT + cor0.col1 * - CAST( ( - col0 ) AS SIGNED ) AS col0 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-6735
SELECT DISTINCT + cor0.col1 * - CAST ( ( - col0 ) AS INTEGER ) AS col0 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + + col2 * - col1 col2 FROM tab0 AS cor0
----
-2871
-7544
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6737
SELECT + + col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6737
SELECT + + col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + + cor0.col2 * col0 * cor0.col1 FROM tab1 cor0
----
36423
4158
99744

query I rowsort
SELECT col0 * ( + 83 ) + + col0 AS col0 FROM tab1 AS cor0
----
252
5376
6720

query I rowsort
SELECT tab0.col1 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + col1 * col1 + col1 AS col2 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT 74 + col1 * + col0 AS col1 FROM tab0 AS cor0
----
2138
3469
8173

onlyif mysql # use DIV operator for integer division
query I rowsort label-6743
SELECT col2 * - CAST( col0 AS SIGNED ) DIV + col0 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-6743
SELECT col2 * - CAST ( col0 AS INTEGER ) / + col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL - tab1.col2 * + col1 AS col2 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6745
SELECT ALL 47 DIV + col1 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-6745
SELECT ALL 47 / + col1 FROM tab2
----
0
1
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6746
SELECT ALL + ( - col1 ) + - col2 DIV + col2 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-6746
SELECT ALL + ( - col1 ) + - col2 / + col2 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT ALL + col1 * + col0 + + cor0.col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT + col2 * - cor0.col2 + + col1 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT ALL + col1 * + 87 - col2 FROM tab1
----
1035
2208
813

query I rowsort
SELECT DISTINCT 33 + col2 - - col1 AS col2 FROM tab2
----
118
88
91

query I rowsort
SELECT DISTINCT + col2 - + col0 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT DISTINCT 54 - col2 FROM tab1
----
-3
-42
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6753
SELECT 2 * col2 DIV + col2 FROM tab0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-6753
SELECT 2 * col2 / + col2 FROM tab0
----
2
2
2

query I rowsort
SELECT ALL + ( + ( col2 ) ) + col1 - col2 FROM tab0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 - col1 col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT - 98 * + col1 FROM tab0
----
-8428
-8918
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6757
SELECT - col2 DIV 89 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6757
SELECT - col2 / 89 AS col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 83 + col1 - + col0 * + col2 * col2 col1 FROM tab0
----
-25967
-598262
145

query I rowsort
SELECT + cor0.col1 * col0 + col1 * col1 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT - col1 * col2 - col1 FROM tab2
----
-1593
-663
-868

query I rowsort
SELECT + 62 + - col0 + + col0 AS col2 FROM tab0 cor0
----
62
62
62

query I rowsort
SELECT + - 60 * - col2 + col0 AS col1 FROM tab1 AS cor0
----
3243
3484
5840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 4 * col1 col0 FROM tab1 AS cor0
----
104
40
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 + col0 * + col0 + col1 * - col1 col1 FROM tab0 cor0
----
-6028
-8149
6938

query I rowsort
SELECT - + 67 + col2 AS col0 FROM tab0 AS cor0
----
-34
-66
15

query I rowsort
SELECT + - 69 + + col0 * col0 + col0 FROM tab0 AS cor0
----
1191
531
7941

onlyif mysql # use DIV operator for integer division
query I rowsort label-6767
SELECT DISTINCT - col1 + - col2 DIV - col0 AS col2 FROM tab0 AS cor0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-6767
SELECT DISTINCT - col1 + - col2 / - col0 AS col2 FROM tab0 AS cor0
----
-85
-91
-97

query I rowsort
SELECT col0 * col0 + cor0.col2 * col1 FROM tab0 AS cor0
----
1322
15383
3414

query I rowsort
SELECT + - ( 31 ) FROM tab2 AS cor0
----
-31
-31
-31

query I rowsort
SELECT + + col0 * col0 * cor0.col1 + + col1 * col1 + - col1 AS col1 FROM tab1 AS cor0
----
41050
83356
884

query I rowsort
SELECT DISTINCT + 86 + - col2 FROM tab2 AS cor0
----
48
59
60

query I rowsort
SELECT ( - col2 ) - col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT col2 + + col1 * - col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT - 64 * col2 * + col2 AS col0 FROM tab0 AS cor0
----
-430336
-64
-69696

query I rowsort
SELECT DISTINCT - 90 * - cor0.col1 AS col2 FROM tab1, tab2 AS cor0
----
1530
2790
5310

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL IN ( tab2.col1 + - col2 )
----

query IIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0 WHERE tab0.col1 > ( NULL )
----

query I rowsort
SELECT DISTINCT col1 * col0 - col2 * - col0 AS col0 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT ALL + + col0 + + col1 * - col1 * col2 + - cor0.col2 * col0 AS col0 FROM tab1 AS cor0
----
-23824
-36663
-9284

query I rowsort
SELECT DISTINCT + cor0.col2 - - col1 AS col0 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6781
SELECT ALL + + col2 * - col0 - - col0 DIV - col1 FROM tab2 cor0
----
-189
-2029
-3006

skipif mysql # not compatible
query I rowsort label-6781
SELECT ALL + + col2 * - col0 - - col0 / - col1 FROM tab2 cor0
----
-189
-2029
-3006

query I rowsort
SELECT ALL + col0 + col0 * col0 * - col1 AS col2 FROM tab1 AS cor0
----
-231
-40896
-83120

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab2 AS cor0 WHERE - col2 BETWEEN - col2 AND ( + col0 )
----
26
27
38

query I rowsort
SELECT col1 * tab2.col0 + + col0 AS col2 FROM tab2
----
1422
224
4680

query I rowsort
SELECT DISTINCT + col0 * - col0 - + col0 * col2 FROM tab2
----
-238
-8112
-9243

query I rowsort
SELECT DISTINCT col0 * col0 + + col1 * col0 FROM tab1 AS cor0
----
4736
7440
87

query I rowsort
SELECT ALL col0 - col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - - cor0.col2 * + col2 + cor0.col1 * + col1 AS col0 FROM tab1 AS cor0
----
3349
3592
9385

onlyif mysql # use DIV operator for integer division
query I rowsort label-6789
SELECT DISTINCT - + col2 + + col1 DIV cor0.col2 col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6789
SELECT DISTINCT - + col2 + + col1 / cor0.col2 col0 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6790
SELECT ALL col2 - col1 DIV cor0.col1 AS col0 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-6790
SELECT ALL col2 - col1 / cor0.col1 AS col0 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT ALL 16 * - col1 * col0 AS col2 FROM tab0
----
-129584
-33024
-54320

query I rowsort
SELECT + tab2.col0 - + tab2.col2 * col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT col1 * col2 + col2 * - col1 FROM tab1
----
0
0
0

query I rowsort
SELECT + cor0.col2 * - 42 + col0 * + col1 AS col0 FROM tab1 AS cor0
----
-1754
-2190
-2992

onlyif mysql # use DIV operator for integer division
query I rowsort label-6795
SELECT col1 DIV 52 + 48 AS col2 FROM tab0 cor0
----
49
49
49

skipif mysql # not compatible
query I rowsort label-6795
SELECT col1 / 52 + 48 AS col2 FROM tab0 cor0
----
49
49
49

query I rowsort
SELECT ALL + col1 + - ( col1 ) * - col2 + 4 FROM tab0 cor0
----
198
2928
7557

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6797
SELECT DISTINCT - + col0 / + col0 - cor0.col1 * col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6797
SELECT DISTINCT - + col0 / + col0 - cor0.col1 * col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col0 * ( col0 * - col0 ) + col1 FROM tab0 AS cor0
----
-13738
-42778
-704878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * 26 * col2 col1 FROM tab2 AS cor0
----
17576
18954
37544

query I rowsort
SELECT - col0 * col0 + - 10 FROM tab0 AS cor0
----
-1235
-586
-7931

query I rowsort
SELECT col2 + 81 * col1 FROM tab1 AS cor0
----
1149
2160
867

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + 69 col2 FROM tab1 AS cor0
----
123
126
165

query I rowsort
SELECT + col2 * col1 + - col0 * 55 AS col0 FROM tab0 AS cor0
----
-1828
1518
2567

query I rowsort
SELECT + 67 + col1 AS col0 FROM tab2 AS cor0
----
126
84
98

query I rowsort
SELECT DISTINCT col2 * - col2 * + ( + 86 ) FROM tab2 AS cor0
----
-124184
-58136
-62694

query I rowsort
SELECT DISTINCT 79 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6807
SELECT DISTINCT - col0 + tab2.col2 * + CAST( NULL AS DECIMAL ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6807
SELECT DISTINCT - col0 + tab2.col2 * + CAST ( NULL AS REAL ) FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col0 * col2 col0 FROM tab1
----
216
3705
7776

query I rowsort
SELECT ALL ( + col1 * + ( + 37 ) ) FROM tab2
----
1147
2183
629

onlyif mysql # use DIV operator for integer division
query I rowsort label-6810
SELECT - 37 DIV col0 col2 FROM tab0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6810
SELECT - 37 / col0 col2 FROM tab0
----
-1
-1
0

query I rowsort
SELECT + 45 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT + tab0.col0 * - col2 + - 27 * 14 FROM tab0
----
-1170
-413
-7676

query I rowsort
SELECT ( col1 ) + + col0 + - 50 AS col1 FROM tab2
----
-12
46
87

query I rowsort
SELECT - 52 * + col0 AS col0 FROM tab0 AS cor0
----
-1248
-1820
-4628

query I rowsort
SELECT ALL - col1 + + cor0.col1 * col0 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT + col1 * col1 * 2 FROM tab2 cor0
----
1922
578
6962

query I rowsort
SELECT - 89 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 924a74d31360fa4301c953b423a4710e

query I rowsort
SELECT 4 * + col1 FROM tab2
----
124
236
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col1 col0 FROM tab1, tab2 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + 65 * - col2 * + col0 - col1 * + col0 AS col2 FROM tab1 AS cor0
----
-10608
-237760
-500240

onlyif mysql # use DIV operator for integer division
query I rowsort label-6821
SELECT ALL - - col2 + cor0.col0 DIV + col0 FROM tab0 cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6821
SELECT ALL - - col2 + cor0.col0 / + col0 FROM tab0 cor0
----
2
34
83

query I rowsort
SELECT DISTINCT - 83 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6823
SELECT tab2.col0 / - 67 + ( col1 ) / CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6823
SELECT tab2.col0 / - 67 + ( col1 ) / CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 - 50 FROM tab0
----
-17
-49
32

query I rowsort
SELECT ALL 15 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT ALL col2 + 66 * col0 * - col0 - + tab0.col2 AS col0 FROM tab0
----
-38016
-522786
-80850

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6827
SELECT - col1 * CAST( - col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-6827
SELECT - col1 * CAST ( - col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT cor0.col0 * + ( col0 ) FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + + col2 - col2 * 23 AS col2 FROM tab1 AS cor0
----
-1188
-1254
-2112

query I rowsort
SELECT ALL 44 + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to a7917b43255f748866cc909b9a7a6291

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6831
SELECT ALL + CAST( tab1.col0 AS SIGNED ) FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif mysql # not compatible
query I rowsort label-6831
SELECT ALL + CAST ( tab1.col0 AS INTEGER ) FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + ( - cor0.col0 ) * + col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - ( 79 ) * - cor0.col1 FROM tab2 AS cor0
----
1343
2449
4661

query I rowsort
SELECT DISTINCT + 11 AS col2 FROM tab0, tab1 cor0
----
11

query I rowsort
SELECT - col0 * 49 AS col0 FROM tab0 AS cor0
----
-1176
-1715
-4361

query I rowsort
SELECT - col1 + col0 * 6 FROM tab0 AS cor0
----
113
443
58

query I rowsort
SELECT - + 92 + + cor0.col2 * - 35 AS col2 FROM tab1 AS cor0
----
-1982
-2087
-3452

query I rowsort
SELECT - ( cor0.col1 ) FROM tab0, tab2, tab0 cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL - ( + col1 ) * col2 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT 84 * - col2 FROM tab0 AS cor0
----
-2772
-6888
-84

query I rowsort
SELECT - col1 * col2 * + col0 AS col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6842
SELECT ALL - col2 * col1 DIV + col0 FROM tab0 AS cor0
----
-118
-2
-83

skipif mysql # not compatible
query I rowsort label-6842
SELECT ALL - col2 * col1 / + col0 FROM tab0 AS cor0
----
-118
-2
-83

query I rowsort
SELECT - ( - 23 ) * col1 FROM tab2 AS cor0
----
1357
391
713

onlyif mysql # use DIV operator for integer division
query I rowsort label-6844
SELECT DISTINCT - cor0.col1 DIV - 28 + + 85 FROM tab1, tab1 cor0
----
85

skipif mysql # not compatible
query I rowsort label-6844
SELECT DISTINCT - cor0.col1 / - 28 + + 85 FROM tab1, tab1 cor0
----
85

query I rowsort
SELECT + col2 - + 97 AS col0 FROM tab0 AS cor0
----
-15
-64
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 47 - col2 col2 FROM tab1 AS cor0
----
-10
-49
-7

query I rowsort
SELECT ALL - - ( col0 ) + col1 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + - 9 * col0 FROM tab0 AS cor0
----
-216
-315
-801

query I rowsort
SELECT ( + 17 ) * + col2 AS col2 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT - - cor0.col1 * 58 FROM tab2 AS cor0
----
1798
3422
986

onlyif mysql # use DIV operator for integer division
query I rowsort label-6851
SELECT DISTINCT - 23 DIV col1 - col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-6851
SELECT DISTINCT - 23 / col1 - col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL 60 + - col0 - col0 FROM tab1
----
-100
-68
54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + cor0.col1 * col0 col0 FROM tab1 cor0
----
1027
52
630

query I rowsort
SELECT + - col1 * - col0 + + 95 FROM tab0 AS cor0
----
2159
3490
8194

query I rowsort
SELECT ALL 47 * - col2 + col0 FROM tab2 AS cor0
----
-1144
-1262
-1707

query I rowsort
SELECT DISTINCT 1 - cor0.col2 * col1 * col1 AS col0 FROM tab0 AS cor0
----
-244067
-679041
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-6857
SELECT + col0 DIV - 84 AS col1 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6857
SELECT + col0 / - 84 AS col1 FROM tab0
----
-1
0
0

query I rowsort
SELECT DISTINCT 37 + - tab1.col2 AS col1 FROM tab1
----
-17
-20
-59

query I rowsort
SELECT + 47 + + col1 AS col2 FROM tab0
----
133
138
144

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 42 + + col1 + + col0 col1 FROM tab0
----
138
68
90

query I rowsort
SELECT ALL col1 * + 98 - - col1 FROM tab1
----
1287
2574
990

query I rowsort
SELECT DISTINCT + col1 - - 85 AS col1 FROM tab1
----
111
95
98

query I rowsort
SELECT + col0 * col0 * - 4 AS col1 FROM tab1 AS cor0
----
-16384
-25600
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-6864
SELECT - col1 DIV + 98 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6864
SELECT - col1 / + 98 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6865
SELECT DISTINCT - + cor0.col2 + + CAST( col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-6865
SELECT DISTINCT - + cor0.col2 + + CAST ( col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT col2 * ( - col0 * - col2 ) AS col2 FROM tab2 cor0
----
114076
5103
52728

query I rowsort
SELECT ALL col2 * col2 + + col0 FROM tab0 cor0
----
1113
36
6813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6868
SELECT - - cor0.col2 * CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-6868
SELECT - - cor0.col2 * CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6869
SELECT - + cor0.col2 DIV col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6869
SELECT - + cor0.col2 / col1 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6870
SELECT DISTINCT + col1 + + col1 DIV ( tab1.col1 ) AS col0 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6870
SELECT DISTINCT + col1 + + col1 / ( tab1.col1 ) AS col0 FROM tab1
----
11
14
27

query I rowsort
SELECT DISTINCT - col0 * - col0 + - col2 AS col2 FROM tab0
----
1224
543
7839

query I rowsort
SELECT ALL 31 * - col2 FROM tab0
----
-1023
-2542
-31

query I rowsort
SELECT DISTINCT - 35 AS col0 FROM tab0
----
-35

query I rowsort
SELECT 80 + - col1 * 72 FROM tab1
----
-1792
-640
-856

query I rowsort
SELECT col2 + + ( + col0 ) FROM tab1
----
121
176
57

query I rowsort
SELECT - col1 + ( col0 ) * col1 FROM tab2
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-6877
SELECT DISTINCT + col0 DIV - col2 col1 FROM tab0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6877
SELECT DISTINCT + col0 / - col2 col1 FROM tab0
----
-1
-35
0

query I rowsort
SELECT + col0 * - ( + 83 ) AS col0 FROM tab1 AS cor0
----
-249
-5312
-6640

query I rowsort
SELECT + ( 99 ) * + col1 AS col0 FROM tab1 AS cor0
----
1287
2574
990

onlyif mysql # use DIV operator for integer division
query I rowsort label-6880
SELECT ALL - + 74 DIV - col1 + + col1 DIV + 64 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-6880
SELECT ALL - + 74 / - col1 + + col1 / + 64 FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT + col0 + - col0 * col0 AS col1 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT - 17 * col0 FROM tab1 AS cor0
----
-1088
-1360
-51

query I rowsort
SELECT DISTINCT - + col0 - 14 FROM tab1 AS cor0
----
-17
-78
-94

query I rowsort
SELECT DISTINCT + 57 FROM tab1, tab2 AS cor0
----
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 53 * - col0 col0 FROM tab2 AS cor0
----
371
4134
4187

query I rowsort
SELECT ( + col0 ) * col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( 4 ) * - col0 col1 FROM tab2 AS cor0
----
-28
-312
-316

query I rowsort
SELECT ALL - cor0.col0 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - ( col0 ) + - col2 * - col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col2 ) + - 31 * + col0 col2 FROM tab1 AS cor0
----
-147
-2041
-2576

onlyif mysql # use DIV operator for integer division
query I rowsort label-6891
SELECT DISTINCT - col0 + - col0 DIV - col2 FROM tab0 AS cor0
----
-24
-88
0

skipif mysql # not compatible
query I rowsort label-6891
SELECT DISTINCT - col0 + - col0 / - col2 FROM tab0 AS cor0
----
-24
-88
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6892
SELECT ALL + cor0.col2 + col0 DIV col0 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6892
SELECT ALL + cor0.col2 + col0 / col0 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col2 * - col1 AS col1 FROM tab1 cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6894
SELECT - col0 DIV cor0.col0 - - cor0.col1 col0 FROM tab0 cor0
----
85
90
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6894
SELECT - col0 / cor0.col0 - - cor0.col1 col0 FROM tab0 cor0
----
85
90
96

query I rowsort
SELECT + - col2 * + col1 + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( - col0 ) * - cor0.col2 * - cor0.col0 + + cor0.col1 col0 FROM tab0 AS cor0
----
1322
19094
649613

query I rowsort
SELECT DISTINCT - - 20 - col0 AS col1 FROM tab0 AS cor0
----
-15
-4
-69

onlyif mysql # use DIV operator for integer division
query I rowsort label-6898
SELECT ALL - col0 + + col0 DIV + 48 FROM tab1 AS cor0
----
-3
-63
-79

skipif mysql # not compatible
query I rowsort label-6898
SELECT ALL - col0 + + col0 / + 48 FROM tab1 AS cor0
----
-3
-63
-79

query I rowsort
SELECT ALL - ( - col2 ) + 53 AS col0 FROM tab0 AS cor0
----
135
54
86

query I rowsort
SELECT - col2 * col1 + ( col0 ) FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - 67 col2 FROM tab0 AS cor0
----
-2211
-5494
-67

query I rowsort
SELECT + + col0 * col0 + + col1 AS col1 FROM tab0 cor0
----
1322
662
8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-6903
SELECT - col1 DIV - col1 + 58 * col2 AS col1 FROM tab1 AS cor0
----
3133
3307
5569

skipif mysql # not compatible
query I rowsort label-6903
SELECT - col1 / - col1 + 58 * col2 AS col1 FROM tab1 AS cor0
----
3133
3307
5569

query I rowsort
SELECT + col0 + - 88 AS col2 FROM tab0 AS cor0
----
-53
-64
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + col2 * cor0.col1 col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + col2 + - 13 FROM tab2 AS cor0
----
13
14
25

query I rowsort
SELECT + - col1 + 66 FROM tab0 cor0
----
-20
-25
-31

query I rowsort
SELECT DISTINCT - 71 * 29 * + col1 AS col2 FROM tab0 AS cor0
----
-177074
-187369
-199723

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6909
SELECT ALL - cor0.col1 + - col1 * col0 * CAST( NULL AS DECIMAL ) + + 69 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6909
SELECT ALL - cor0.col1 + - col1 * col0 * CAST ( NULL AS REAL ) + + 69 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6910
SELECT - col2 * + 98 * col1 - + CAST( - col1 AS SIGNED ) * - col2 AS col2 FROM tab1 AS cor0
----
-123552
-138996
-56430

skipif mysql # not compatible
query I rowsort label-6910
SELECT - col2 * + 98 * col1 - + CAST ( - col1 AS INTEGER ) * - col2 AS col2 FROM tab1 AS cor0
----
-123552
-138996
-56430

query I rowsort
SELECT + ( 37 ) * - col0 FROM tab0 AS cor0
----
-1295
-3293
-888

query I rowsort
SELECT - col1 + + col0 * col0 + - 72 FROM tab2 AS cor0
----
-54
5953
6152

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6913
SELECT ALL - - CAST( NULL AS SIGNED ) + - col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6913
SELECT ALL - - CAST ( NULL AS INTEGER ) + - col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( col1 ) + col0 * + cor0.col1 AS col2 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT ALL - 64 + col2 * cor0.col0 * col1 AS col1 FROM tab2 AS cor0
----
119588
50970
5795

query I rowsort
SELECT ALL ( 13 ) * col0 + col2 * + 68 FROM tab0 AS cor0
----
2556
523
6733

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6917
SELECT DISTINCT CAST( NULL AS SIGNED ) * + 70 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6917
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + 70 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + 64 - col1 FROM tab0 AS cor0
----
-22
-27
-33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6919
SELECT ALL + CAST( col1 AS SIGNED ) * col2 * 5 AS col0 FROM tab1 AS cor0
----
2850
6240
7020

skipif mysql # not compatible
query I rowsort label-6919
SELECT ALL + CAST ( col1 AS INTEGER ) * col2 * 5 AS col0 FROM tab1 AS cor0
----
2850
6240
7020

query I rowsort
SELECT + col1 * col0 + + ( col1 + - col0 ) AS col1 FROM tab2 AS cor0
----
1281
241
4583

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col2 FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab2, tab2 AS cor1
----
243 values hashing to b98cc07e6d63e3c0583ed19f9e9ad2be

query I rowsort
SELECT ALL + col2 * + col0 + - col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT col2 + 31 AS col0 FROM tab0 AS cor0
----
113
32
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6924
SELECT ALL + - col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6924
SELECT ALL + - col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + + 58 FROM tab2 AS cor0
----
117
75
89

query I rowsort
SELECT DISTINCT col2 + col2 * - col0 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-6927
SELECT ALL + col2 DIV + 35 AS col1 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6927
SELECT ALL + col2 / + 35 AS col1 FROM tab2 AS cor0
----
0
0
1

query I rowsort
SELECT + 19 AS col0 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT ALL col1 * - ( - col1 * - col2 + - 85 ) AS col0 FROM tab2
----
-23312
-85491
-9537

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6930
SELECT ALL - CAST( NULL AS DECIMAL ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6930
SELECT ALL - CAST ( NULL AS REAL ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6931
SELECT ALL CAST( ( + col0 ) AS SIGNED ) FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6931
SELECT ALL CAST ( ( + col0 ) AS INTEGER ) FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + ( ( + col2 ) + col0 ) AS col1 FROM tab1
----
121
176
57

query I rowsort
SELECT + tab1.col2 * - 4 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 548c624524ba72c74b45c6a6f146f79b

query I rowsort
SELECT + 2 * + col0 AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + 98 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
98

query I rowsort
SELECT col1 * + 79 + + col0 FROM tab0 cor0
----
6818
7278
7698

query I rowsort
SELECT - - col1 * - ( col2 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - cor0.col2 + - 67 AS col2 FROM tab0 cor0
----
-100
-149
-68

query I rowsort
SELECT - + col1 + + 42 AS col1 FROM tab1 AS cor0
----
16
29
32

query I rowsort
SELECT + col2 * ( col1 ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + 76 ) col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT 24 * col1 - + col2 FROM tab0
----
2031
2102
2327

query I rowsort
SELECT ALL + ( tab0.col0 ) + + cor1.col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 047cb866c2bb7959119c6506cdc28687

query I rowsort
SELECT DISTINCT - 58 + + col0 * - ( 45 * - col1 + - ( + ( col1 ) ) * - ( col2 ) ) AS col1 FROM tab0 AS cor0
----
-299721
149322
24710

query I rowsort
SELECT + 68 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT ALL col0 * col0 - - col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL 93 * - col2 - 93 FROM tab1 cor0
----
-5115
-5394
-9021

query I rowsort
SELECT ALL + 44 * col0 * cor0.col1 + col2 AS col1 FROM tab2 cor0
----
202514
59130
9575

query I rowsort
SELECT - 82 * - col2 * cor0.col1 + cor0.col0 FROM tab0 AS cor0
----
232740
611973
7989

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6950
SELECT DISTINCT ( + col0 ) + - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6950
SELECT DISTINCT ( + col0 ) + - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + col2 + - col2 * - 4 AS col1 FROM tab0 AS cor0
----
165
410
5

query I rowsort
SELECT ALL col2 * 46 AS col1 FROM tab0 AS cor0
----
1518
3772
46

query I rowsort
SELECT ALL - col1 + + col0 * 99 AS col0 FROM tab2 AS cor0
----
662
7663
7804

query I rowsort
SELECT col2 * - 1 * - col1 AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL - - col0 + 95 FROM tab1 AS cor0
----
159
175
98

query I rowsort
SELECT ALL col2 + - 58 * cor0.col0 FROM tab0 AS cor0
----
-1359
-2029
-5080

query I rowsort
SELECT ALL cor0.col1 + 28 * + ( - col1 ) + + col0 AS col2 FROM tab2 AS cor0
----
-1515
-380
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-6958
SELECT DISTINCT - col0 DIV - ( 76 + cor0.col0 ) FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6958
SELECT DISTINCT - col0 / - ( 76 + cor0.col0 ) FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT col0 * - cor0.col1 + 61 AS col0 FROM tab0 AS cor0
----
-2003
-3334
-8038

onlyif mysql # use DIV operator for integer division
query I rowsort label-6960
SELECT DISTINCT col2 + cor0.col0 * col0 DIV + col2 FROM tab0 AS cor0
----
1226
178
50

skipif mysql # not compatible
query I rowsort label-6960
SELECT DISTINCT col2 + cor0.col0 * col0 / + col2 FROM tab0 AS cor0
----
1226
178
50

query I rowsort
SELECT ALL 29 * - col0 AS col0 FROM tab0 cor0
----
-1015
-2581
-696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6962
SELECT DISTINCT - CAST( col1 AS SIGNED ) AS col0 FROM tab2 cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-6962
SELECT DISTINCT - CAST ( col1 AS INTEGER ) AS col0 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + col0 + - 92 AS col1 FROM tab0 AS cor0
----
-3
-57
-68

query I rowsort
SELECT ALL + - cor0.col1 * col2 * - col0 + col2 AS col2 FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT ALL + col0 * - ( - col1 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL 24 * - col2 + col1 + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-487
-610
-816

query I rowsort
SELECT col0 * ( + col2 ) * col1 + col1 + - col1 * + col1 FROM tab2 cor0
----
116230
4929
50762

query I rowsort
SELECT + - ( col1 ) * + col1 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-6969
SELECT DISTINCT + col1 DIV col2 + - col0 FROM tab0 AS cor0
----
-22
-88
62

skipif mysql # not compatible
query I rowsort label-6969
SELECT DISTINCT + col1 / col2 + - col0 FROM tab0 AS cor0
----
-22
-88
62

query I rowsort
SELECT DISTINCT + - ( col1 ) * col0 - + 9 * + col2 FROM tab2 AS cor0
----
-1685
-460
-4836

query I rowsort
SELECT + col0 * + 1 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT + 37 * col2 FROM tab0 AS cor0
----
1221
3034
37

query I rowsort
SELECT ALL + col0 + - 63 FROM tab1
----
-60
1
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 32 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT ALL - + 11 * + col0 AS col0 FROM tab1 cor0
----
-33
-704
-880

onlyif mysql # use DIV operator for integer division
query I rowsort label-6976
SELECT - 82 DIV + col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-27

skipif mysql # not compatible
query I rowsort label-6976
SELECT - 82 / + col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-27

query I rowsort
SELECT DISTINCT - ( - col1 * + col1 ) + 90 AS col0 FROM tab0
----
7486
8371
9499

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + tab2.col2 col1 FROM tab2
----
52
54
76

query I rowsort
SELECT DISTINCT + 26 * - col0 * + col0 + + col2 FROM tab0
----
-14943
-205864
-31849

query I rowsort
SELECT + 4 * + col1 + - col1 * - col2 * - col2 FROM tab1 AS cor0
----
-119756
-32450
-75712

query I rowsort
SELECT - - 44 * + col0 + ( + 13 ) * - col2 FROM tab2 AS cor0
----
-43
2982
3094

query I rowsort
SELECT + + col0 + col2 * col0 AS col1 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL col2 * + col0 + ( 40 ) - - col0 * col1 FROM tab2 AS cor0
----
4385
446
6670

query I rowsort
SELECT DISTINCT 55 * col2 FROM tab2 AS cor0
----
1430
1485
2090

query I rowsort
SELECT + - col0 + cor0.col0 * 37 FROM tab1 AS cor0
----
108
2304
2880

query I rowsort
SELECT ALL 81 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT DISTINCT - col2 * 64 * 91 AS col0 FROM tab0 AS cor0
----
-192192
-477568
-5824

query I rowsort
SELECT DISTINCT + col1 * 16 + 60 * col2 FROM tab2 AS cor0
----
2116
2504
2552

query I rowsort
SELECT ALL - col2 + - 57 AS col1 FROM tab1 AS cor0
----
-111
-114
-153

query I rowsort
SELECT DISTINCT + + col1 + ( - col1 ) * + cor0.col2 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6991
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + - ( col2 ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6991
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + - ( col2 ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + tab0.col2 + col1 * col0 AS col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + cor0.col0 * + col2 + col1 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT - col1 * - 77 AS col2 FROM tab2 AS cor0
----
1309
2387
4543

query I rowsort
SELECT ALL + 95 * - col1 AS col2 FROM tab1 cor0
----
-1235
-2470
-950

query I rowsort
SELECT DISTINCT - - 2 AS col2 FROM tab1 AS cor0
----
2

query I rowsort
SELECT cor0.col0 AS col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL - 98 * - col2 AS col0 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT tab1.col0 AS col2 FROM tab1 WHERE NULL NOT IN ( + col0 + - col0 * + col1 + col0 )
----

query I rowsort
SELECT ALL col1 * - col0 + col1 * col2 * col2 AS col2 FROM tab2
----
22382
23205
35282

onlyif mysql # use DIV operator for integer division
query I rowsort label-7001
SELECT tab0.col0 + col2 DIV + col0 AS col0 FROM tab0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-7001
SELECT tab0.col0 + col2 / + col0 AS col0 FROM tab0
----
25
35
89

query I rowsort
SELECT ALL col1 FROM tab2 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7003
SELECT DISTINCT col1 + + tab2.col2 DIV col1 FROM tab2
----
19
31
59

skipif mysql # not compatible
query I rowsort label-7003
SELECT DISTINCT col1 + + tab2.col2 / col1 FROM tab2
----
19
31
59

query I rowsort
SELECT DISTINCT - col2 * - col2 * col2 + + col2 FROM tab2
----
17602
19710
54910

query I rowsort
SELECT DISTINCT - tab0.col0 FROM tab0 WHERE ( NULL ) < NULL
----

query I rowsort
SELECT col1 * col0 - + col1 AS col2 FROM tab2
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-7007
SELECT + tab1.col2 + col1 DIV - col1 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-7007
SELECT + tab1.col2 + col1 / - col1 FROM tab1
----
53
56
95

query I rowsort
SELECT col1 - col1 * + col0 * - tab2.col2 FROM tab2 WHERE col2 NOT IN ( + col1 )
----
119711
51051
5890

query I rowsort
SELECT DISTINCT col2 * col2 + - tab0.col0 FROM tab0
----
-34
1065
6635

query I rowsort
SELECT ALL col2 * col2 + tab2.col2 AS col2 FROM tab2
----
1482
702
756

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) NOT IN ( + col1 + - col0 )
----

query III rowsort
SELECT * FROM tab2 WHERE - col1 = ( col2 )
----

query I rowsort
SELECT tab1.col0 * col1 * col0 + - col1 * col2 FROM tab1
----
-1170
40390
81952

query I rowsort
SELECT ALL - col2 * + col0 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-7015
SELECT - - col1 DIV - col0 AS col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-7015
SELECT - - col1 / - col0 AS col0 FROM tab2 AS cor0
----
-4
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7016
SELECT DISTINCT + cor0.col2 + col0 DIV - col2 AS col0 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-7016
SELECT DISTINCT + cor0.col2 + col0 / - col2 AS col0 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT - + col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 + - col2 * + tab0.col0 FROM tab0 WHERE col0 * col1 = col2 + col0 / col0
----

query IIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab0 WHERE NULL BETWEEN ( NULL ) AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7020
SELECT cor0.col1 DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort