The MySQL server is running with the --secure-file-priv option so it cannot execute this statemen code example

Example 1: ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot execute this statement

# Check the default location of secure_file_priv
SHOW VARIABLES LIKE "secure_file_priv";

# Save the file in that location
Select ... From ... INTO OUTFILE ...

Example 2: Error Code: 1290. The MySQL server is running with the --secure-file-priv option so it cannot execute this statement

LOAD DATA LOCAL INFILE ...

Tags:

Sql Example