Correct location of INFILE files for SQL syntax?

Discussion in 'General' started by markelino, Jan 7, 2020.

Tags:
  1. markelino

    markelino Member

    Need to run an INFILE mysql command and I am doing it remotely via Sequel Pro (phpmyadmin does not mention errors at all) but I keep on getting error msg file not found.
    Any idea what location such files should exist in? Logged in using user DB account and not admin and file is stored in client0 location. Tried various locations but they all fail.
    Code:
    File '/var/www/clients/client0/web2/tmp/IP2LOCATION-LITE-DB11.CSV' not found (Errcode: 2)
    If anyone can shed any light, I will appreciate it.

    Followed instructions as per ip2location site.

    Code:
    LOAD DATA LOCAL
        INFILE '/var/www/clients/client0/web2/tmp/IP2LOCATION-LITE-DB11.CSV'
    INTO TABLE
        `ip2location_db11`
    FIELDS TERMINATED BY ','
    ENCLOSED BY '"'
    LINES TERMINATED BY '\r\n'
    IGNORE 0 LINES;
     

Share This Page