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
6836db1c
Commit
6836db1c
authored
Dec 24, 2007
by
istruewing@stella.local
Browse files
Options
Browse Files
Download
Plain Diff
Merge stella.local:/home2/mydev/mysql-5.1-amain
into stella.local:/home2/mydev/mysql-5.1-axmrg
parents
a0fbcc03
03a24463
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
129 additions
and
27 deletions
+129
-27
mysql-test/r/bdb_notembedded.result
mysql-test/r/bdb_notembedded.result
+35
-0
mysql-test/r/symlink.result
mysql-test/r/symlink.result
+8
-0
mysql-test/t/bdb_notembedded.test
mysql-test/t/bdb_notembedded.test
+38
-0
mysql-test/t/symlink.test
mysql-test/t/symlink.test
+12
-0
sql/sql_parse.cc
sql/sql_parse.cc
+1
-9
sql/sql_table.cc
sql/sql_table.cc
+11
-1
sql/table.cc
sql/table.cc
+24
-17
No files found.
mysql-test/r/bdb_notembedded.result
0 → 100644
View file @
6836db1c
set autocommit=1;
reset master;
create table bug16206 (a int);
insert into bug16206 values(1);
start transaction;
insert into bug16206 values(2);
commit;
show binlog events;
Log_name Pos Event_type Server_id End_log_pos Info
f n Format_desc 1 n Server ver: VERSION, Binlog ver: 4
f n Query 1 n use `test`; create table bug16206 (a int)
f n Query 1 n use `test`; insert into bug16206 values(1)
f n Query 1 n use `test`; insert into bug16206 values(2)
drop table bug16206;
reset master;
create table bug16206 (a int) engine= bdb;
insert into bug16206 values(0);
insert into bug16206 values(1);
start transaction;
insert into bug16206 values(2);
commit;
insert into bug16206 values(3);
show binlog events;
Log_name Pos Event_type Server_id End_log_pos Info
f n Format_desc 1 n Server ver: VERSION, Binlog ver: 4
f n Query 1 n use `test`; create table bug16206 (a int) engine= bdb
f n Query 1 n use `test`; insert into bug16206 values(0)
f n Query 1 n use `test`; insert into bug16206 values(1)
f n Query 1 n use `test`; BEGIN
f n Query 1 n use `test`; insert into bug16206 values(2)
f n Query 1 n use `test`; COMMIT
f n Query 1 n use `test`; insert into bug16206 values(3)
drop table bug16206;
set autocommit=0;
End of 5.0 tests
mysql-test/r/symlink.result
View file @
6836db1c
...
@@ -162,3 +162,11 @@ DROP DATABASE db1;
...
@@ -162,3 +162,11 @@ DROP DATABASE db1;
DROP DATABASE db2;
DROP DATABASE db2;
USE test;
USE test;
End of 5.0 tests
End of 5.0 tests
SET @OLD_SQL_MODE=@@SQL_MODE, @@SQL_MODE='NO_DIR_IN_CREATE';
CREATE TABLE t1(a INT) DATA DIRECTORY='MYSQLTEST_VARDIR/tmp' INDEX DIRECTORY='MYSQLTEST_VARDIR/tmp';
Warnings:
Warning 0 DATA DIRECTORY option ignored
Warning 0 INDEX DIRECTORY option ignored
DROP TABLE t1;
SET @@SQL_MODE=@OLD_SQL_MODE;
End of 5.1 tests
mysql-test/t/bdb_notembedded.test
0 → 100644
View file @
6836db1c
--
source
include
/
not_embedded
.
inc
--
source
include
/
have_bdb
.
inc
#
# Bug #16206: Superfluous COMMIT event in binlog when updating BDB in autocommit mode
#
set
autocommit
=
1
;
let
$VERSION
=
`select version()`
;
reset
master
;
create
table
bug16206
(
a
int
);
insert
into
bug16206
values
(
1
);
start
transaction
;
insert
into
bug16206
values
(
2
);
commit
;
--
replace_result
$VERSION
VERSION
--
replace_column
1
f
2
n
5
n
show
binlog
events
;
drop
table
bug16206
;
reset
master
;
create
table
bug16206
(
a
int
)
engine
=
bdb
;
insert
into
bug16206
values
(
0
);
insert
into
bug16206
values
(
1
);
start
transaction
;
insert
into
bug16206
values
(
2
);
commit
;
insert
into
bug16206
values
(
3
);
--
replace_result
$VERSION
VERSION
--
replace_column
1
f
2
n
5
n
show
binlog
events
;
drop
table
bug16206
;
set
autocommit
=
0
;
--
echo
End
of
5.0
tests
mysql-test/t/symlink.test
View file @
6836db1c
...
@@ -226,3 +226,15 @@ USE test;
...
@@ -226,3 +226,15 @@ USE test;
--
echo
End
of
5.0
tests
--
echo
End
of
5.0
tests
#
# BUG#25677 - With --skip-symbolic-links option on, DATA DIRECTORY clause is
# silently ignored
#
SET
@
OLD_SQL_MODE
=@@
SQL_MODE
,
@@
SQL_MODE
=
'NO_DIR_IN_CREATE'
;
--
replace_result
$MYSQLTEST_VARDIR
MYSQLTEST_VARDIR
eval
CREATE
TABLE
t1
(
a
INT
)
DATA
DIRECTORY
=
'$MYSQLTEST_VARDIR/tmp'
INDEX
DIRECTORY
=
'$MYSQLTEST_VARDIR/tmp'
;
DROP
TABLE
t1
;
SET
@@
SQL_MODE
=@
OLD_SQL_MODE
;
--
echo
End
of
5.1
tests
sql/sql_parse.cc
View file @
6836db1c
...
@@ -2290,15 +2290,7 @@ mysql_execute_command(THD *thd)
...
@@ -2290,15 +2290,7 @@ mysql_execute_command(THD *thd)
/* Might have been updated in create_table_precheck */
/* Might have been updated in create_table_precheck */
create_info
.
alias
=
create_table
->
alias
;
create_info
.
alias
=
create_table
->
alias
;
#ifndef HAVE_READLINK
#ifdef HAVE_READLINK
if
(
create_info
.
data_file_name
)
push_warning
(
thd
,
MYSQL_ERROR
::
WARN_LEVEL_WARN
,
0
,
"DATA DIRECTORY option ignored"
);
if
(
create_info
.
index_file_name
)
push_warning
(
thd
,
MYSQL_ERROR
::
WARN_LEVEL_WARN
,
0
,
"INDEX DIRECTORY option ignored"
);
create_info
.
data_file_name
=
create_info
.
index_file_name
=
NULL
;
#else
/* Fix names if symlinked tables */
/* Fix names if symlinked tables */
if
(
append_file_to_dir
(
thd
,
&
create_info
.
data_file_name
,
if
(
append_file_to_dir
(
thd
,
&
create_info
.
data_file_name
,
create_table
->
table_name
)
||
create_table
->
table_name
)
||
...
...
sql/sql_table.cc
View file @
6836db1c
...
@@ -3480,8 +3480,18 @@ bool mysql_create_table_no_lock(THD *thd,
...
@@ -3480,8 +3480,18 @@ bool mysql_create_table_no_lock(THD *thd,
thd
->
proc_info
=
"creating table"
;
thd
->
proc_info
=
"creating table"
;
create_info
->
table_existed
=
0
;
// Mark that table is created
create_info
->
table_existed
=
0
;
// Mark that table is created
if
(
thd
->
variables
.
sql_mode
&
MODE_NO_DIR_IN_CREATE
)
#ifdef HAVE_READLINK
if
(
!
my_use_symdir
||
(
thd
->
variables
.
sql_mode
&
MODE_NO_DIR_IN_CREATE
))
#endif
{
if
(
create_info
->
data_file_name
)
push_warning
(
thd
,
MYSQL_ERROR
::
WARN_LEVEL_WARN
,
0
,
"DATA DIRECTORY option ignored"
);
if
(
create_info
->
index_file_name
)
push_warning
(
thd
,
MYSQL_ERROR
::
WARN_LEVEL_WARN
,
0
,
"INDEX DIRECTORY option ignored"
);
create_info
->
data_file_name
=
create_info
->
index_file_name
=
0
;
create_info
->
data_file_name
=
create_info
->
index_file_name
=
0
;
}
create_info
->
table_options
=
db_options
;
create_info
->
table_options
=
db_options
;
path
[
path_length
-
reg_ext_length
]
=
'\0'
;
// Remove .frm extension
path
[
path_length
-
reg_ext_length
]
=
'\0'
;
// Remove .frm extension
...
...
sql/table.cc
View file @
6836db1c
...
@@ -892,26 +892,31 @@ static int open_binary_frm(THD *thd, TABLE_SHARE *share, uchar *head,
...
@@ -892,26 +892,31 @@ static int open_binary_frm(THD *thd, TABLE_SHARE *share, uchar *head,
ha_legacy_type
(
share
->
db_type
())));
ha_legacy_type
(
share
->
db_type
())));
}
}
#ifdef WITH_PARTITION_STORAGE_ENGINE
#ifdef WITH_PARTITION_STORAGE_ENGINE
else
else
if
(
str_db_type_length
==
9
&&
!
strncmp
((
char
*
)
next_chunk
+
2
,
"partition"
,
9
))
{
{
LEX_STRING
pname
=
{
C_STRING_WITH_LEN
(
"partition"
)
};
/*
if
(
str_db_type_length
==
pname
.
length
&&
Use partition handler
!
strncmp
((
char
*
)
next_chunk
+
2
,
pname
.
str
,
pname
.
length
))
tmp_plugin is locked with a local lock.
{
we unlock the old value of share->db_plugin before
/*
replacing it with a globally locked version of tmp_plugin
Use partition handler
*/
tmp_plugin is locked with a local lock.
plugin_unlock
(
NULL
,
share
->
db_plugin
);
we unlock the old value of share->db_plugin before
share
->
db_plugin
=
ha_lock_engine
(
NULL
,
partition_hton
);
replacing it with a globally locked version of tmp_plugin
DBUG_PRINT
(
"info"
,
(
"setting dbtype to '%.*s' (%d)"
,
*/
str_db_type_length
,
next_chunk
+
2
,
plugin_unlock
(
NULL
,
share
->
db_plugin
);
ha_legacy_type
(
share
->
db_type
())));
share
->
db_plugin
=
ha_lock_engine
(
NULL
,
partition_hton
);
DBUG_PRINT
(
"info"
,
(
"setting dbtype to '%.*s' (%d)"
,
str_db_type_length
,
next_chunk
+
2
,
ha_legacy_type
(
share
->
db_type
())));
}
}
}
#endif
#endif
else
if
(
!
tmp_plugin
)
{
/* purecov: begin inspected */
error
=
8
;
my_error
(
ER_UNKNOWN_STORAGE_ENGINE
,
MYF
(
0
),
name
.
str
);
my_free
(
buff
,
MYF
(
0
));
goto
err
;
/* purecov: end */
}
next_chunk
+=
str_db_type_length
+
2
;
next_chunk
+=
str_db_type_length
+
2
;
}
}
if
(
next_chunk
+
5
<
buff_end
)
if
(
next_chunk
+
5
<
buff_end
)
...
@@ -2200,6 +2205,8 @@ void open_table_error(TABLE_SHARE *share, int error, int db_errno, int errarg)
...
@@ -2200,6 +2205,8 @@ void open_table_error(TABLE_SHARE *share, int error, int db_errno, int errarg)
"of MySQL and cannot be read"
,
"of MySQL and cannot be read"
,
MYF
(
0
),
buff
);
MYF
(
0
),
buff
);
break
;
break
;
case
8
:
break
;
default:
/* Better wrong error than none */
default:
/* Better wrong error than none */
case
4
:
case
4
:
strxmov
(
buff
,
share
->
normalized_path
.
str
,
reg_ext
,
NullS
);
strxmov
(
buff
,
share
->
normalized_path
.
str
,
reg_ext
,
NullS
);
...
...
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