Skip to content

Commit a39b484

Browse files
committed
MDEV-16733 mysqldump --tab and --xml options are conflicting
1 parent a3dbd5d commit a39b484

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

client/mysqldump.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1350,6 +1350,11 @@ static int get_options(int *argc, char ***argv)
13501350
my_progname_short);
13511351
return(EX_USAGE);
13521352
}
1353+
if (opt_xml && path)
1354+
{
1355+
fprintf(stderr, "%s: --xml can't be used with --tab.\n", my_progname_short);
1356+
return(EX_USAGE);
1357+
}
13531358
if (opt_asof_timestamp && strchr(opt_asof_timestamp, '\''))
13541359
{
13551360
fprintf(stderr, "%s: Incorrect DATETIME value: '%s'\n",

mysql-test/main/mysqldump.result

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6584,3 +6584,4 @@ SET GLOBAL LOG_OUTPUT=DEFAULT, GLOBAL GENERAL_LOG=@save_general_log;
65846584
TRUNCATE TABLE mysql.general_log;
65856585
DROP DATABASE test1;
65866586
# End of 10.3 tests
6587+
mysqldump: --xml can't be used with --tab.

mysql-test/main/mysqldump.test

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2980,3 +2980,10 @@ DROP DATABASE test1;
29802980
--remove_file $MYSQLTEST_VARDIR/tmp/dumptest1.sql
29812981

29822982
--echo # End of 10.3 tests
2983+
2984+
#
2985+
# MDEV-16733 mysqldump --tab and --xml options are conflicting
2986+
#
2987+
--replace_result mysqldump.exe mysqldump
2988+
--error 1
2989+
--exec $MYSQL_DUMP --xml --tab=$MYSQLTEST_VARDIR/tmp 2>&1

0 commit comments

Comments
 (0)