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
4b4b36af
Commit
4b4b36af
authored
Mar 09, 2011
by
Mattias Jonsson
Browse files
Options
Browse Files
Download
Plain Diff
merge
parents
9a45cd30
3da5a9cf
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
82 additions
and
0 deletions
+82
-0
mysql-test/r/partition.result
mysql-test/r/partition.result
+38
-0
mysql-test/t/partition.test
mysql-test/t/partition.test
+43
-0
sql/ha_partition.cc
sql/ha_partition.cc
+1
-0
No files found.
mysql-test/r/partition.result
View file @
4b4b36af
drop table if exists t1, t2;
drop table if exists t1, t2;
#
#
# Bug#59297: Can't find record in 'tablename' on update inner join
#
CREATE TABLE t1 (
a char(2) NOT NULL,
b char(2) NOT NULL,
c int(10) unsigned NOT NULL,
d varchar(255) DEFAULT NULL,
e varchar(1000) DEFAULT NULL,
PRIMARY KEY (a, b, c),
KEY (a),
KEY (a, b)
)
/*!50100 PARTITION BY KEY (a)
PARTITIONS 20 */;
INSERT INTO t1 (a, b, c, d, e) VALUES
('07', '03', 343, '1', '07_03_343'),
('01', '04', 343, '2', '01_04_343'),
('01', '06', 343, '3', '01_06_343'),
('01', '07', 343, '4', '01_07_343'),
('01', '08', 343, '5', '01_08_343'),
('01', '09', 343, '6', '01_09_343'),
('03', '03', 343, '7', '03_03_343'),
('03', '06', 343, '8', '03_06_343'),
('03', '07', 343, '9', '03_07_343'),
('04', '03', 343, '10', '04_03_343'),
('04', '06', 343, '11', '04_06_343'),
('05', '03', 343, '12', '05_03_343'),
('11', '03', 343, '13', '11_03_343'),
('11', '04', 343, '14', '11_04_343')
;
UPDATE t1 AS A,
(SELECT '03' AS a, '06' AS b, 343 AS c, 'last' AS d) AS B
SET A.e = B.d
WHERE A.a = '03'
AND A.b = '06'
AND A.c = 343;
DROP TABLE t1;
#
# Bug#57778: failed primary key add to partitioned innodb table
# Bug#57778: failed primary key add to partitioned innodb table
# inconsistent and crashes
# inconsistent and crashes
#
#
...
...
mysql-test/t/partition.test
View file @
4b4b36af
...
@@ -14,6 +14,49 @@
...
@@ -14,6 +14,49 @@
drop
table
if
exists
t1
,
t2
;
drop
table
if
exists
t1
,
t2
;
--
enable_warnings
--
enable_warnings
--
echo
#
--
echo
# Bug#59297: Can't find record in 'tablename' on update inner join
--
echo
#
CREATE
TABLE
t1
(
a
char
(
2
)
NOT
NULL
,
b
char
(
2
)
NOT
NULL
,
c
int
(
10
)
unsigned
NOT
NULL
,
d
varchar
(
255
)
DEFAULT
NULL
,
e
varchar
(
1000
)
DEFAULT
NULL
,
PRIMARY
KEY
(
a
,
b
,
c
),
KEY
(
a
),
KEY
(
a
,
b
)
)
/*!50100 PARTITION BY KEY (a)
PARTITIONS 20 */
;
INSERT
INTO
t1
(
a
,
b
,
c
,
d
,
e
)
VALUES
(
'07'
,
'03'
,
343
,
'1'
,
'07_03_343'
),
(
'01'
,
'04'
,
343
,
'2'
,
'01_04_343'
),
(
'01'
,
'06'
,
343
,
'3'
,
'01_06_343'
),
(
'01'
,
'07'
,
343
,
'4'
,
'01_07_343'
),
(
'01'
,
'08'
,
343
,
'5'
,
'01_08_343'
),
(
'01'
,
'09'
,
343
,
'6'
,
'01_09_343'
),
(
'03'
,
'03'
,
343
,
'7'
,
'03_03_343'
),
(
'03'
,
'06'
,
343
,
'8'
,
'03_06_343'
),
(
'03'
,
'07'
,
343
,
'9'
,
'03_07_343'
),
(
'04'
,
'03'
,
343
,
'10'
,
'04_03_343'
),
(
'04'
,
'06'
,
343
,
'11'
,
'04_06_343'
),
(
'05'
,
'03'
,
343
,
'12'
,
'05_03_343'
),
(
'11'
,
'03'
,
343
,
'13'
,
'11_03_343'
),
(
'11'
,
'04'
,
343
,
'14'
,
'11_04_343'
)
;
UPDATE
t1
AS
A
,
(
SELECT
'03'
AS
a
,
'06'
AS
b
,
343
AS
c
,
'last'
AS
d
)
AS
B
SET
A
.
e
=
B
.
d
WHERE
A
.
a
=
'03'
AND
A
.
b
=
'06'
AND
A
.
c
=
343
;
DROP
TABLE
t1
;
--
echo
#
--
echo
#
--
echo
# Bug#57778: failed primary key add to partitioned innodb table
--
echo
# Bug#57778: failed primary key add to partitioned innodb table
--
echo
# inconsistent and crashes
--
echo
# inconsistent and crashes
...
...
sql/ha_partition.cc
View file @
4b4b36af
...
@@ -4448,6 +4448,7 @@ int ha_partition::index_read_idx_map(uchar *buf, uint index,
...
@@ -4448,6 +4448,7 @@ int ha_partition::index_read_idx_map(uchar *buf, uint index,
break
;
break
;
}
}
}
}
m_last_part
=
part
;
}
}
else
else
{
{
...
...
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