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
4cde1d12
Commit
4cde1d12
authored
Feb 20, 2006
by
msvensson@neptunus.(none)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug#17382 mysql-test-run mysqldump fails with mysqlimport
parent
ddc2da9c
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
203 additions
and
18 deletions
+203
-18
client/Makefile.am
client/Makefile.am
+9
-10
client/mysqlimport.c
client/mysqlimport.c
+3
-5
mysql-test/r/mysqldump.result
mysql-test/r/mysqldump.result
+175
-0
mysql-test/t/disabled.def
mysql-test/t/disabled.def
+0
-1
mysql-test/t/mysqldump.test
mysql-test/t/mysqldump.test
+16
-2
No files found.
client/Makefile.am
View file @
4cde1d12
...
@@ -25,10 +25,13 @@ endif
...
@@ -25,10 +25,13 @@ endif
INCLUDES
=
-I
$(top_builddir)
/include
\
INCLUDES
=
-I
$(top_builddir)
/include
\
-I
$(top_srcdir)
/include
\
-I
$(top_srcdir)
/include
\
-I
$(top_srcdir)
/regex
\
-I
$(top_srcdir)
/regex
\
$(openssl_includes)
$(yassl_includes)
$(openssl_includes)
$(yassl_includes)
LIBS
=
@CLIENT_LIBS@
LIBS
=
@CLIENT_LIBS@
LDADD
=
@CLIENT_EXTRA_LDFLAGS@
$(CLIENT_THREAD_LIBS)
\
LDADD
=
@CLIENT_EXTRA_LDFLAGS@
$(CLIENT_THREAD_LIBS)
\
$(top_builddir)
/libmysql/libmysqlclient.la
$(top_builddir)
/libmysql/libmysqlclient.la
LDADD_R
=
@CLIENT_EXTRA_LDFLAGS@
\
$(CLIENT_THREAD_LIBS)
\
$(top_builddir)
/libmysql_r/libmysqlclient_r.la
bin_PROGRAMS
=
mysql mysqladmin mysqlcheck mysqlshow
\
bin_PROGRAMS
=
mysql mysqladmin mysqlcheck mysqlshow
\
mysqldump mysqlimport mysqltest mysqlbinlog
\
mysqldump mysqlimport mysqltest mysqlbinlog
\
mysqltestmanagerc mysqltestmanager-pwgen
\
mysqltestmanagerc mysqltestmanager-pwgen
\
...
@@ -48,15 +51,11 @@ mysqlbinlog_SOURCES = mysqlbinlog.cc $(top_srcdir)/mysys/mf_tempdir.c \
...
@@ -48,15 +51,11 @@ mysqlbinlog_SOURCES = mysqlbinlog.cc $(top_srcdir)/mysys/mf_tempdir.c \
$(top_srcdir)
/mysys/my_vle.c
\
$(top_srcdir)
/mysys/my_vle.c
\
$(top_srcdir)
/mysys/base64.c
$(top_srcdir)
/mysys/base64.c
mysqlbinlog_LDADD
=
$(LDADD)
$(CXXLDFLAGS)
mysqlbinlog_LDADD
=
$(LDADD)
$(CXXLDFLAGS)
mysqlslap_LDADD
=
$(CXXLDFLAGS)
$(CLIENT_THREAD_LIBS)
\
mysqlslap_LDADD
=
$(CXXLDFLAGS)
$(LDADD_R)
\
@CLIENT_EXTRA_LDFLAGS@
\
$(top_builddir)
/mysys/libmysys.a
$(top_builddir)
/libmysql_r/libmysqlclient_r.la
\
mysqlimport_LDADD
=
$(CXXLDFLAGS)
$(LDADD_R)
\
$(top_builddir)
/mysys/libmysys.a
$(top_builddir)
/mysys/libmysys.a
mysqlimport_LDADD
=
$(CXXLDFLAGS)
$(CLIENT_THREAD_LIBS)
\
mysqltestmanager_pwgen_SOURCES
=
mysqlmanager-pwgen.c
@CLIENT_EXTRA_LDFLAGS@
\
$(top_builddir)
/libmysql_r/libmysqlclient_r.la
\
$(top_builddir)
/mysys/libmysys.a
mysqltestmanager_pwgen_SOURCES
=
mysqlmanager-pwgen.c
mysqltestmanagerc_SOURCES
=
mysqlmanagerc.c
$(yassl_dummy_link_fix)
mysqltestmanagerc_SOURCES
=
mysqlmanagerc.c
$(yassl_dummy_link_fix)
mysqlcheck_SOURCES
=
mysqlcheck.c
$(yassl_dummy_link_fix)
mysqlcheck_SOURCES
=
mysqlcheck.c
$(yassl_dummy_link_fix)
mysqlshow_SOURCES
=
mysqlshow.c
$(yassl_dummy_link_fix)
mysqlshow_SOURCES
=
mysqlshow.c
$(yassl_dummy_link_fix)
...
...
client/mysqlimport.c
View file @
4cde1d12
...
@@ -145,13 +145,11 @@ static struct my_option my_long_options[] =
...
@@ -145,13 +145,11 @@ static struct my_option my_long_options[] =
(
gptr
*
)
&
opt_mysql_unix_port
,
(
gptr
*
)
&
opt_mysql_unix_port
,
0
,
GET_STR
,
(
gptr
*
)
&
opt_mysql_unix_port
,
(
gptr
*
)
&
opt_mysql_unix_port
,
0
,
GET_STR
,
REQUIRED_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
REQUIRED_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
#include <sslopt-longopts.h>
#include <sslopt-longopts.h>
#if 0
{
"use-threads"
,
OPT_USE_THREADS
,
{
"use-threads"
,
OPT_USE_THREADS
,
"Load files in parallel. The argument is the number "
"Load files in parallel. The argument is the number "
"of threads to use for loading data."
,
"of threads to use for loading data."
,
(
gptr
*
)
&
opt_use_threads
,
(
gptr
*
)
&
opt_use_threads
,
0
,
(
gptr
*
)
&
opt_use_threads
,
(
gptr
*
)
&
opt_use_threads
,
0
,
GET_UINT
,
REQUIRED_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
GET_UINT
,
REQUIRED_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
#endif
#ifndef DONT_ALLOW_USER_CHANGE
#ifndef DONT_ALLOW_USER_CHANGE
{
"user"
,
'u'
,
"User for login if not current user."
,
(
gptr
*
)
&
current_user
,
{
"user"
,
'u'
,
"User for login if not current user."
,
(
gptr
*
)
&
current_user
,
(
gptr
*
)
&
current_user
,
0
,
GET_STR
,
REQUIRED_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
(
gptr
*
)
&
current_user
,
0
,
GET_STR
,
REQUIRED_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
...
@@ -292,7 +290,7 @@ static int write_to_table(char *filename, MYSQL *mysql)
...
@@ -292,7 +290,7 @@ static int write_to_table(char *filename, MYSQL *mysql)
DBUG_PRINT
(
"enter"
,(
"filename: %s"
,
filename
));
DBUG_PRINT
(
"enter"
,(
"filename: %s"
,
filename
));
fn_format
(
tablename
,
filename
,
""
,
""
,
1
|
2
);
/* removes path & ext. */
fn_format
(
tablename
,
filename
,
""
,
""
,
1
|
2
);
/* removes path & ext. */
if
(
!
opt_local_file
)
if
(
!
opt_local_file
)
strmov
(
hard_path
,
filename
);
strmov
(
hard_path
,
filename
);
else
else
my_load_path
(
hard_path
,
filename
,
NULL
);
/* filename includes the path */
my_load_path
(
hard_path
,
filename
,
NULL
);
/* filename includes the path */
...
@@ -640,9 +638,9 @@ int main(int argc, char **argv)
...
@@ -640,9 +638,9 @@ int main(int argc, char **argv)
if
(
lock_tables
)
if
(
lock_tables
)
lock_table
(
mysql
,
argc
,
argv
);
lock_table
(
mysql
,
argc
,
argv
);
for
(;
*
argv
!=
NULL
;
argv
++
)
for
(;
*
argv
!=
NULL
;
argv
++
)
if
((
error
=
write_to_table
(
*
argv
,
mysql
)))
if
((
error
=
write_to_table
(
*
argv
,
mysql
)))
if
(
exitcode
==
0
)
if
(
exitcode
==
0
)
exitcode
=
error
;
exitcode
=
error
;
db_disconnect
(
current_host
,
mysql
);
db_disconnect
(
current_host
,
mysql
);
}
}
my_free
(
opt_password
,
MYF
(
MY_ALLOW_ZERO_PTR
));
my_free
(
opt_password
,
MYF
(
MY_ALLOW_ZERO_PTR
));
...
...
mysql-test/r/mysqldump.result
View file @
4cde1d12
...
@@ -2650,3 +2650,178 @@ DELIMITER ;
...
@@ -2650,3 +2650,178 @@ DELIMITER ;
DROP TRIGGER tr1;
DROP TRIGGER tr1;
DROP TABLE t1;
DROP TABLE t1;
create table t1 (a text , b text);
create table t2 (a text , b text);
insert t1 values ("Duck, Duck", "goose");
insert t1 values ("Duck, Duck", "pidgeon");
insert t2 values ("We the people", "in order to perform");
insert t2 values ("a more perfect", "union");
select * from t1;
a b
Duck, Duck goose
Duck, Duck pidgeon
select * from t2;
a b
We the people in order to perform
a more perfect union
test.t1: Records: 2 Deleted: 0 Skipped: 0 Warnings: 0
test.t2: Records: 2 Deleted: 0 Skipped: 0 Warnings: 0
select * from t1;
a b
Duck, Duck goose
Duck, Duck pidgeon
Duck, Duck goose
Duck, Duck pidgeon
select * from t2;
a b
We the people in order to perform
a more perfect union
We the people in order to perform
a more perfect union
create table words(a varchar(255));
create table words2(b varchar(255));
select * from t1;
a b
Duck, Duck goose
Duck, Duck pidgeon
Duck, Duck goose
Duck, Duck pidgeon
Duck, Duck goose
Duck, Duck pidgeon
select * from t2;
a b
We the people in order to perform
a more perfect union
We the people in order to perform
a more perfect union
We the people in order to perform
a more perfect union
select * from words;
a
Aarhus
Aaron
Ababa
aback
abaft
abandon
abandoned
abandoning
abandonment
abandons
Aarhus
Aaron
Ababa
aback
abaft
abandon
abandoned
abandoning
abandonment
abandons
abase
abased
abasement
abasements
abases
abash
abashed
abashes
abashing
abasing
abate
abated
abatement
abatements
abater
abates
abating
Abba
abbe
abbey
abbeys
abbot
abbots
Abbott
abbreviate
abbreviated
abbreviates
abbreviating
abbreviation
abbreviations
Abby
abdomen
abdomens
abdominal
abduct
abducted
abduction
abductions
abductor
abductors
abducts
Abe
abed
Abel
Abelian
Abelson
Aberdeen
Abernathy
aberrant
aberration
select * from words2;
b
abase
abased
abasement
abasements
abases
abash
abashed
abashes
abashing
abasing
abate
abated
abatement
abatements
abater
abates
abating
Abba
abbe
abbey
abbeys
abbot
abbots
Abbott
abbreviate
abbreviated
abbreviates
abbreviating
abbreviation
abbreviations
Abby
abdomen
abdomens
abdominal
abduct
abducted
abduction
abductions
abductor
abductors
abducts
Abe
abed
Abel
Abelian
Abelson
Aberdeen
Abernathy
aberrant
aberration
drop table words;
mysql-import: Error: 1146, Table 'test.words' doesn't exist, when using table: words
drop table t1;
drop table t2;
drop table words2;
mysql-test/t/disabled.def
View file @
4cde1d12
...
@@ -36,4 +36,3 @@ sp-goto : GOTO is currently is disabled - will be fixed in the f
...
@@ -36,4 +36,3 @@ sp-goto : GOTO is currently is disabled - will be fixed in the f
rpl_ndb_blob : Bug#17505
rpl_ndb_blob : Bug#17505
rpl_ndb_blob2 : Bug#17505
rpl_ndb_blob2 : Bug#17505
rpl_ndb_log : results are not deterministic
rpl_ndb_log : results are not deterministic
mysqldump : Bug#17443 mysqlimport --use-threads=5 gives crashes
mysql-test/t/mysqldump.test
View file @
4cde1d12
...
@@ -1049,7 +1049,6 @@ SET SQL_MODE = @old_sql_mode;
...
@@ -1049,7 +1049,6 @@ SET SQL_MODE = @old_sql_mode;
DROP
TRIGGER
tr1
;
DROP
TRIGGER
tr1
;
DROP
TABLE
t1
;
DROP
TABLE
t1
;
--
disable_parsing
#
#
# Added for use-thread option
# Added for use-thread option
#
#
...
@@ -1070,7 +1069,22 @@ select * from t2;
...
@@ -1070,7 +1069,22 @@ select * from t2;
--
exec
$MYSQL_IMPORT
--
silent
--
use
-
threads
=
5
test
$MYSQLTEST_VARDIR
/
tmp
/
t1
.
txt
$MYSQLTEST_VARDIR
/
tmp
/
t2
.
txt
--
exec
$MYSQL_IMPORT
--
silent
--
use
-
threads
=
5
test
$MYSQLTEST_VARDIR
/
tmp
/
t1
.
txt
$MYSQLTEST_VARDIR
/
tmp
/
t2
.
txt
select
*
from
t1
;
select
*
from
t1
;
select
*
from
t2
;
select
*
from
t2
;
# Now we test with multiple threads, but less threads than files.
create
table
words
(
a
varchar
(
255
));
create
table
words2
(
b
varchar
(
255
));
--
exec
$MYSQL_IMPORT
--
silent
--
use
-
threads
=
2
test
$MYSQLTEST_VARDIR
/
tmp
/
t1
.
txt
$MYSQLTEST_VARDIR
/
tmp
/
t2
.
txt
$MYSQLTEST_VARDIR
/
std_data_ln
/
words
.
dat
$MYSQLTEST_VARDIR
/
std_data_ln
/
words2
.
dat
select
*
from
t1
;
select
*
from
t2
;
select
*
from
words
;
select
*
from
words2
;
# Drop table "words" and run with threads, should fail
drop
table
words
;
--
replace_regex
/.*
mysqlimport
/
mysql
-
import
/
--
error
1
--
exec
$MYSQL_IMPORT
--
silent
--
use
-
threads
=
2
test
$MYSQLTEST_VARDIR
/
tmp
/
t1
.
txt
$MYSQLTEST_VARDIR
/
tmp
/
t2
.
txt
$MYSQLTEST_VARDIR
/
std_data_ln
/
words
.
dat
$MYSQLTEST_VARDIR
/
std_data_ln
/
words2
.
dat
2
>&
1
drop
table
t1
;
drop
table
t1
;
drop
table
t2
;
drop
table
t2
;
--
enable_parsing
drop
table
words2
;
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