title: mysql load data infile permission issue
body: <p>I am using the following query to load into mysql:</p>
  
  <pre><code>LOAD DATA INFILE '/var/www/vhosts/httpdocs/xml/insert_feeds.csv' 
  INTO TABLE `deals_items` 
  FIELDS TERMINATED BY '@##!@#' 
  OPTIONALLY ENCLOSED BY '' 
  ESCAPED BY '' 
  LINES TERMINATED BY '@##%@#' 
  IGNORE 1 LINES 
  (@id,dealID,shopid,categoryid,title,permalink,url,startDate,endDate,description,extract,price,previous_price,discount,purchases,image,@location,@lat,@lng,locationText,type,settings,active) 
  SET id = '', lat=@lat, lng=@lng, locationText=@location, location = GeomFromText(CONCAT(POINT(@lat,@lng)))
  </code></pre>
  
  <p>Now this used to work just fine, but ever since an mysql was upgraded from 5.0 to 5.1 it stopped working. It now works only if I add the LOCAL to the statement. 
  The error I'm getting is <code>Can't get stat of /var/www/vhosts/httpdocs/xml/insert_feeds.csv</code>
  The user was granted with full permissions to test it and the file was given 0777.
  It won't work from any client (mysql,mysqli,pdo and console). Adding the local solves all problems but there is a lot of queries and I cannot go on and change them all. Further more, as I understand from the manual there are security issues with the LOCAL command.</p>
  
  <p>The exact mysql version is 5.1.58-1~dotdeb.0 and the client version 5.0.51a</p>