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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
e9ba287d
Commit
e9ba287d
authored
Jul 12, 2006
by
mikael/pappa@dator5.(none)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BUG#20852: Using update with full table scan causes mysqld to enter an eternal loop
parent
4e23f975
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
26 additions
and
1 deletion
+26
-1
mysql-test/r/partition_innodb.result
mysql-test/r/partition_innodb.result
+11
-0
mysql-test/t/partition_innodb.test
mysql-test/t/partition_innodb.test
+13
-0
sql/ha_partition.cc
sql/ha_partition.cc
+2
-1
No files found.
mysql-test/r/partition_innodb.result
View file @
e9ba287d
...
@@ -107,3 +107,14 @@ select * from t1 where id = 'aaa';
...
@@ -107,3 +107,14 @@ select * from t1 where id = 'aaa';
id
id
aaa
aaa
drop table t1;
drop table t1;
create table t1 (a int, b int, primary key (b,a))
engine = innodb
partition by hash (a);
insert into t1 values (0, 0);
insert into t1 values (1, 0);
update t1 set b = b + 1 where a = 1;
select * from t1;
a b
0 0
1 1
drop table t1;
mysql-test/t/partition_innodb.test
View file @
e9ba287d
...
@@ -78,3 +78,16 @@ select * from t1 where id = 'a';
...
@@ -78,3 +78,16 @@ select * from t1 where id = 'a';
select
*
from
t1
where
id
=
'aa'
;
select
*
from
t1
where
id
=
'aa'
;
select
*
from
t1
where
id
=
'aaa'
;
select
*
from
t1
where
id
=
'aaa'
;
drop
table
t1
;
drop
table
t1
;
#
# Bug #20852 Partitions: Crash if hash innodb, composite primary key
#
create
table
t1
(
a
int
,
b
int
,
primary
key
(
b
,
a
))
engine
=
innodb
partition
by
hash
(
a
);
insert
into
t1
values
(
0
,
0
);
insert
into
t1
values
(
1
,
0
);
update
t1
set
b
=
b
+
1
where
a
=
1
;
select
*
from
t1
;
drop
table
t1
;
sql/ha_partition.cc
View file @
e9ba287d
...
@@ -2229,7 +2229,8 @@ int ha_partition::open(const char *name, int mode, uint test_if_locked)
...
@@ -2229,7 +2229,8 @@ int ha_partition::open(const char *name, int mode, uint test_if_locked)
m_table_flags
&=
~
(
HA_CAN_GEOMETRY
|
HA_CAN_FULLTEXT
|
HA_DUPLICATE_POS
|
m_table_flags
&=
~
(
HA_CAN_GEOMETRY
|
HA_CAN_FULLTEXT
|
HA_DUPLICATE_POS
|
HA_CAN_SQL_HANDLER
|
HA_CAN_INSERT_DELAYED
);
HA_CAN_SQL_HANDLER
|
HA_CAN_INSERT_DELAYED
);
m_table_flags
|=
HA_FILE_BASED
|
HA_REC_NOT_IN_SEQ
;
m_table_flags
|=
HA_FILE_BASED
|
HA_REC_NOT_IN_SEQ
;
key_used_on_scan
=
m_file
[
0
]
->
key_used_on_scan
;
implicit_emptied
=
m_file
[
0
]
->
implicit_emptied
;
/*
/*
Add 2 bytes for partition id in position ref length.
Add 2 bytes for partition id in position ref length.
ref_length=max_in_all_partitions(ref_length) + PARTITION_BYTES_IN_POS
ref_length=max_in_all_partitions(ref_length) + PARTITION_BYTES_IN_POS
...
...
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