Load Data Local infile not working
Posted by: Endercorps_Alpha (---.9-3.cable.virginm.net)
Date: April 19, 2020 04:30PM

Hi, I'm having issues in regards to importing CSV files into Mysql via Load data local (Using the Phpmyadmin interface for Mysql) - I'm getting this Error "#2000 - LOAD DATA LOCAL INFILE is forbidden, check mysqli.allow_local_infile"

But when I check php.ini for that setting it's already enabled.

Note. This has started happening in the last few days and I've not changed anything.

Wampserver 3.2.0
Php 7.3.12
Mysql 8.0.18

Options: ReplyQuote
Re: Load Data Local infile not working
Posted by: Otomatic (Moderator)
Date: April 19, 2020 05:52PM

Hi,

Always RTFM.

The first thing to do is to ALWAYS make a little effort and look at the related documentation, in this case the MySQL documentation, do a search on LOAD DATA INFILE and find :
6.1.6 Security Considerations for LOAD DATA LOCAL

MySQL enables clients to restrict local data loading operations to files located in a designated directory.
Restricting Files Permitted for Local Data Loading

See also :
my.ini secure_file_priv
my.ini local_infile

I can't tell you more, as I didn't do a load date infile.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons



Edited 1 time(s). Last edit at 04/19/2020 07:23PM by Otomatic.

Options: ReplyQuote


Sorry, only registered users may post in this forum.