Does the connecting user have the FILE privilege? Yes, the connecting user has full file privileges. Apples and Oranges. LOAD DATA INFILE loads a file on the server's data directory by the server, LOAD DATA LOCAL INFILE is read by the client and sent to the server. LOAD DATA INFILE also requires the FILE privilege. LOAD DATA is loading the file from the client while select into outfile is dumping the file to the client. Not so sure why the latter shouldn't work? Thanks.. On Wed, May 19, 2010 at 12:27 PM, Brian Evans <grknight@scent-team.com>wrote:
On 5/19/2010 12:09 PM, Cool Guy wrote:
MySQL is awesome! I am currently involved in a major server migration and previously, our small database used to be hosted on the same server as the client. So we used to do this : SELECT * INTO OUTFILE .... LOAD DATA INFILE ....
Now, we moved the database to a different server and SELECT * INTO OUTFILE .... no longer works, understandable - security reasons I believe.
Does the connecting user have the FILE privilege?
But, interestingly LOAD DATA INFILE .... can be changed to LOAD DATA LOCAL INFILE .... and bam, it works.
Apples and Oranges. LOAD DATA INFILE loads a file on the server's data directory by the server, LOAD DATA LOCAL INFILE is read by the client and sent to the server.
LOAD DATA INFILE also requires the FILE privilege.
Brian
I am not complaining nor am I expressing disgust towards MySQL. The alternative to that added 2 lines of extra code and a system call form a .sql script. All I wanted to know is why LOAD DATA LOCAL INFILE works and why is there no such thing as SELECT INTO OUTFILE LOCAL?
I did my homework, couldn't find a direct answer to my questions above. I couldn't find a feature request @ MySQL either. If someone can clear that up, that had be awesome!
I am planning on suggesting MariaDB to our company cos' it is not under Oracle's admin. Does MariaDB already have this "SELECT INTO OUTFILE LOCAL .." feature implemented or is it in the wishlist/to-do list?
Thank you,
Kiran
_______________________________________________ Mailing list: https://launchpad.net/~maria-discuss Post to : maria-discuss@lists.launchpad.net Unsubscribe : https://launchpad.net/~maria-discuss More help : https://help.launchpad.net/ListHelp