Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
f9d36194
Commit
f9d36194
authored
Jun 30, 2007
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Post-merge fix.
parent
26a2b004
Changes
5
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
731 additions
and
20 deletions
+731
-20
mysql-test/r/create.result
mysql-test/r/create.result
+638
-0
mysql-test/r/rpl_switch_stm_row_mixed.result
mysql-test/r/rpl_switch_stm_row_mixed.result
+2
-2
mysql-test/r/subselect.result
mysql-test/r/subselect.result
+33
-0
mysql-test/r/type_enum.result
mysql-test/r/type_enum.result
+31
-8
mysql-test/t/type_enum.test
mysql-test/t/type_enum.test
+27
-10
No files found.
mysql-test/r/create.result
View file @
f9d36194
This diff is collapsed.
Click to expand it.
mysql-test/r/rpl_switch_stm_row_mixed.result
View file @
f9d36194
...
...
@@ -457,7 +457,7 @@ master-bin.000001 # Query # # use `mysqltest1`; CREATE TABLE `t2` (
master-bin.000001 # Table_map # # table_id: # (mysqltest1.t2)
master-bin.000001 # Write_rows # # table_id: # flags: STMT_END_F
master-bin.000001 # Query # # use `mysqltest1`; CREATE TABLE `t3` (
`1` varbinary(
36
) NOT NULL DEFAULT ''
`1` varbinary(
108
) NOT NULL DEFAULT ''
)
master-bin.000001 # Table_map # # table_id: # (mysqltest1.t3)
master-bin.000001 # Write_rows # # table_id: # flags: STMT_END_F
...
...
@@ -761,7 +761,7 @@ master-bin.000001 # Query # # use `mysqltest1`; CREATE TABLE `t2` (
master-bin.000001 # Table_map # # table_id: # (mysqltest1.t2)
master-bin.000001 # Write_rows # # table_id: # flags: STMT_END_F
master-bin.000001 # Query # # use `mysqltest1`; CREATE TABLE `t3` (
`1` varbinary(
36
) NOT NULL DEFAULT ''
`1` varbinary(
108
) NOT NULL DEFAULT ''
)
master-bin.000001 # Table_map # # table_id: # (mysqltest1.t3)
master-bin.000001 # Write_rows # # table_id: # flags: STMT_END_F
...
...
mysql-test/r/subselect.result
View file @
f9d36194
...
...
@@ -4106,6 +4106,39 @@ d1
1
1
DROP TABLE t1,t2;
CREATE TABLE t1 (a INTEGER, b INTEGER);
CREATE TABLE t2 (x INTEGER);
INSERT INTO t1 VALUES (1,11), (2,22), (2,22);
INSERT INTO t2 VALUES (1), (2);
SELECT a, COUNT(b), (SELECT COUNT(b) FROM t2) FROM t1 GROUP BY a;
ERROR 21000: Subquery returns more than 1 row
SELECT a, COUNT(b), (SELECT COUNT(b)+0 FROM t2) FROM t1 GROUP BY a;
ERROR 21000: Subquery returns more than 1 row
SELECT (SELECT SUM(t1.a)/AVG(t2.x) FROM t2) FROM t1;
(SELECT SUM(t1.a)/AVG(t2.x) FROM t2)
3.3333
DROP TABLE t1,t2;
CREATE TABLE t1 (a INT, b INT);
INSERT INTO t1 VALUES (1, 2), (1,3), (1,4), (2,1), (2,2);
SELECT a1.a, COUNT(*) FROM t1 a1 WHERE a1.a = 1
AND EXISTS( SELECT a2.a FROM t1 a2 WHERE a2.a = a1.a)
GROUP BY a1.a;
a COUNT(*)
1 3
DROP TABLE t1;
CREATE TABLE t1 (a INT);
CREATE TABLE t2 (a INT);
INSERT INTO t1 VALUES (1),(2);
INSERT INTO t2 VALUES (1),(2);
SELECT (SELECT SUM(t1.a) FROM t2 WHERE a=0) FROM t1;
(SELECT SUM(t1.a) FROM t2 WHERE a=0)
NULL
SELECT (SELECT SUM(t1.a) FROM t2 WHERE a!=0) FROM t1;
ERROR 21000: Subquery returns more than 1 row
SELECT (SELECT SUM(t1.a) FROM t2 WHERE a=1) FROM t1;
(SELECT SUM(t1.a) FROM t2 WHERE a=1)
3
DROP TABLE t1,t2;
End of 5.0 tests.
CREATE TABLE t1 (a int, b int);
INSERT INTO t1 VALUES (2,22),(1,11),(2,22);
...
...
mysql-test/r/type_enum.result
View file @
f9d36194
...
...
@@ -1753,14 +1753,6 @@ t1 CREATE TABLE `t1` (
`f1` int(11) DEFAULT NULL,
`f2` enum('') DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
End of 4.1 tests
create table t1(f1 set('a','b'), index(f1));
insert into t1 values(''),(''),('a'),('b');
select * from t1 where f1='';
f1
drop table t1;
create table t1(russian enum('E','F','EF','FE') NOT NULL DEFAULT'E');
show create table t1;
...
...
@@ -1786,4 +1778,35 @@ drop table t1;
create table t1(exhausting_charset enum('ABCDEFGHIJKLMNOPQRSTUVWXYZ','
!"','#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~','xx\','yy\','zz'));
ERROR 42000: Field separator argument is not what is expected; check the manual
CREATE TABLE t1 (
id INT AUTO_INCREMENT PRIMARY KEY,
c1 ENUM('a', '', 'b')
);
INSERT INTO t1 (c1) VALUES (0), ('a'), (''), ('b');
Warnings:
Warning 1265 Data truncated for column 'c1' at row 1
SELECT id, c1 + 0, c1 FROM t1;
id c1 + 0 c1
1 0
2 1 a
3 2
4 3 b
ALTER TABLE t1 CHANGE c1 c1 ENUM('a', '') NOT NULL;
Warnings:
Warning 1265 Data truncated for column 'c1' at row 4
SELECT id, c1 + 0, c1 FROM t1;
id c1 + 0 c1
1 0
2 1 a
3 2
4 0
DROP TABLE t1;
End of 4.1 tests
create table t1(f1 set('a','b'), index(f1));
insert into t1 values(''),(''),('a'),('b');
select * from t1 where f1='';
f1
drop table t1;
End of 5.1 tests
...
...
mysql-test/t/type_enum.test
View file @
f9d36194
...
...
@@ -136,16 +136,6 @@ alter table t1 add f2 enum(0xFFFF);
show
create
table
t1
;
drop
table
t1
;
--
echo
End
of
4.1
tests
#
# Bug#28729: Field_enum wrongly reported an error while storing an empty string.
#
create
table
t1
(
f1
set
(
'a'
,
'b'
),
index
(
f1
));
insert
into
t1
values
(
''
),(
''
),(
'a'
),(
'b'
);
select
*
from
t1
where
f1
=
''
;
drop
table
t1
;
#
# Bug#24660 "enum" field type definition problem
#
...
...
@@ -166,4 +156,31 @@ drop table t1;
create
table
t1
(
exhausting_charset
enum
(
'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
,
'
!"'
,
'#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~'
,
'xx\'
,
'yy\','
zz
'));
#
# Bug #29251: MySQL coerces special 0 enum values to normal '' value
# when ALTERing the column
#
CREATE TABLE t1 (
id INT AUTO_INCREMENT PRIMARY KEY,
c1 ENUM('
a
', '', '
b
')
);
INSERT INTO t1 (c1) VALUES (0), ('
a
'), (''), ('
b
');
SELECT id, c1 + 0, c1 FROM t1;
ALTER TABLE t1 CHANGE c1 c1 ENUM('
a
', '') NOT NULL;
SELECT id, c1 + 0, c1 FROM t1;
DROP TABLE t1;
--echo End of 4.1 tests
#
# Bug#28729: Field_enum wrongly reported an error while storing an empty string.
#
create table t1(f1 set('
a
','
b
'), index(f1));
insert into t1 values(''),(''),('
a
'),('
b
');
select * from t1 where f1='
'
;
drop
table
t1
;
--
echo
End
of
5.1
tests
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment