mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
MDEV-20500: Bad error msg on disabling local infile
This commit is contained in:
committed by
Robert Bindar
parent
8f8cc5f4c2
commit
73dfb402bf
@ -29,7 +29,7 @@ DROP TABLE IF EXISTS t1;
|
|||||||
create table t1(a int);
|
create table t1(a int);
|
||||||
LOAD DATA LOCAL INFILE
|
LOAD DATA LOCAL INFILE
|
||||||
'MYSQLTEST_VARDIR/std_data/numbers.txt' INTO TABLE test.t1;
|
'MYSQLTEST_VARDIR/std_data/numbers.txt' INTO TABLE test.t1;
|
||||||
ERROR 42000: The used command is not allowed with this MariaDB version
|
ERROR HY000: The used command is not allowed because the MariaDB server or client has disabled the local infile capability
|
||||||
SELECT count(*) from t1;
|
SELECT count(*) from t1;
|
||||||
count(*)
|
count(*)
|
||||||
0
|
0
|
||||||
|
@ -74,7 +74,7 @@ DROP TABLE IF EXISTS t1;
|
|||||||
create table t1(a int);
|
create table t1(a int);
|
||||||
|
|
||||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||||
--Error ER_NOT_ALLOWED_COMMAND
|
--Error ER_LOAD_INFILE_CAPABILITY_DISABLED
|
||||||
eval LOAD DATA LOCAL INFILE
|
eval LOAD DATA LOCAL INFILE
|
||||||
'$MYSQLTEST_VARDIR/std_data/numbers.txt' INTO TABLE test.t1;
|
'$MYSQLTEST_VARDIR/std_data/numbers.txt' INTO TABLE test.t1;
|
||||||
|
|
||||||
|
@ -7945,3 +7945,6 @@ ER_PART_STARTS_BEYOND_INTERVAL
|
|||||||
eng "%`s: STARTS is later than query time, first history partition may exceed INTERVAL value"
|
eng "%`s: STARTS is later than query time, first history partition may exceed INTERVAL value"
|
||||||
ER_GALERA_REPLICATION_NOT_SUPPORTED
|
ER_GALERA_REPLICATION_NOT_SUPPORTED
|
||||||
eng "DDL-statement is forbidden as table storage engine does not support Galera replication"
|
eng "DDL-statement is forbidden as table storage engine does not support Galera replication"
|
||||||
|
ER_LOAD_INFILE_CAPABILITY_DISABLED
|
||||||
|
eng "The used command is not allowed because the MariaDB server or client has disabled the local infile capability"
|
||||||
|
rum "Comanda folosită nu este permisă deoarece clientul sau serverul MariaDB a dezactivat această capabilitate"
|
@ -4940,7 +4940,8 @@ mysql_execute_command(THD *thd)
|
|||||||
if (!(thd->client_capabilities & CLIENT_LOCAL_FILES) ||
|
if (!(thd->client_capabilities & CLIENT_LOCAL_FILES) ||
|
||||||
!opt_local_infile)
|
!opt_local_infile)
|
||||||
{
|
{
|
||||||
my_message(ER_NOT_ALLOWED_COMMAND, ER_THD(thd, ER_NOT_ALLOWED_COMMAND), MYF(0));
|
my_message(ER_LOAD_INFILE_CAPABILITY_DISABLED,
|
||||||
|
ER_THD(thd, ER_LOAD_INFILE_CAPABILITY_DISABLED), MYF(0));
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user