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
5ef0ce41
Commit
5ef0ce41
authored
May 03, 2016
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comments
parent
92e47c39
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
7 deletions
+5
-7
sql/handler.h
sql/handler.h
+2
-2
sql/sql_admin.cc
sql/sql_admin.cc
+3
-5
No files found.
sql/handler.h
View file @
5ef0ce41
...
...
@@ -129,7 +129,7 @@ enum enum_alter_inplace_result {
*/
#define HA_PRIMARY_KEY_REQUIRED_FOR_POSITION (1ULL << 16)
#define HA_CAN_RTREEKEYS (1ULL << 17)
#define HA_NOT_DELETE_WITH_CACHE (1ULL << 18)
#define HA_NOT_DELETE_WITH_CACHE (1ULL << 18)
/* unused */
/*
The following is we need to a primary key to delete (and update) a row.
If there is no primary key, all columns needs to be read on update and delete
...
...
@@ -143,7 +143,7 @@ enum enum_alter_inplace_result {
#define HA_HAS_OLD_CHECKSUM (1ULL << 24)
/* Table data are stored in separate files (for lower_case_table_names) */
#define HA_FILE_BASED (1ULL << 26)
#define HA_NO_VARCHAR (1ULL << 27)
#define HA_NO_VARCHAR (1ULL << 27)
/* unused */
#define HA_CAN_BIT_FIELD (1ULL << 28)
/* supports bit fields */
#define HA_NEED_READ_RANGE_BUFFER (1ULL << 29)
/* for read_multi_range */
#define HA_ANY_INDEX_MAY_BE_UNIQUE (1ULL << 30)
...
...
sql/sql_admin.cc
View file @
5ef0ce41
...
...
@@ -622,16 +622,14 @@ static bool mysql_admin_table(THD* thd, TABLE_LIST* tables,
/*
Close all instances of the table to allow MyISAM "repair"
to rename files.
(which is internally also used from "optimize")
to rename files.
@todo: This code does not close all instances of the table.
It only closes instances in other connections, but if this
connection has LOCK TABLE t1 a READ, t1 b WRITE,
both t1 instances will be kept open.
There is no need to execute this branch for InnoDB, which does
repair by recreate. There is no need to do it for OPTIMIZE,
which doesn't move files around.
Hence, this code should be moved to prepare_for_repair(),
and executed only for MyISAM engine.
repair by recreate.
Hence, this code should be executed only for MyISAM engine.
*/
if
(
lock_type
==
TL_WRITE
&&
!
table
->
table
->
s
->
tmp_table
)
{
...
...
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