This may be an easy one but I am not able to figue it out. I am trying to load a data file but mysql is not able to recognize the path. What am I missing here?
$sql = "LOAD DATA LOCAL INFILE
'/localhost/Data/Table.txt'
INTO TABLE myTable IGNORE 1 LINES;
";
(Pardon my intrusion with a mySql posting. I am noticing that there are plenty of smart programmers on this forum as compared to other forums where there is not much going on. The posting sits there forever.)
Load data and pathname [SOLVED]
Moderator: General Moderators
- PHP_mySQL__Newbie
- Forum Commoner
- Posts: 29
- Joined: Fri Aug 12, 2011 5:40 pm
Load data and pathname [SOLVED]
Last edited by PHP_mySQL__Newbie on Wed Aug 17, 2011 1:23 am, edited 1 time in total.
- PHP_mySQL__Newbie
- Forum Commoner
- Posts: 29
- Joined: Fri Aug 12, 2011 5:40 pm
Re: Load data and pathname
ok. I figured it out.
This worked.
$sql = "LOAD DATA LOCAL INFILE
'http://localhost/Data/Table.txt'
INTO TABLE myTable IGNORE 1 LINES;
This worked.
$sql = "LOAD DATA LOCAL INFILE
'http://localhost/Data/Table.txt'
INTO TABLE myTable IGNORE 1 LINES;