Complete.Org: Mailing Lists: Archives: linux-help: August 2003:
[linux-help] Re: Mysql permissions
Home

[linux-help] Re: Mysql permissions

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: linux-help@xxxxxxxxx
Subject: [linux-help] Re: Mysql permissions
From: Jeff Vian <jvian10@xxxxxxxxxxx>
Date: Wed, 27 Aug 2003 15:06:50 -0500
Reply-to: linux-help@xxxxxxxxx


bruce bales wrote:

>Jeff Vian wrote:
>
>  
>
>>the use of the word "outfile" followed by the actual filename is not 
>>legal.  It is used in the documentation to represent the filename being 
>>saved to and MUST be replaced by the actual filename in the command.
>> 
>>
>>    
>>
>I'm afraid you're wrong here, Jeff.  The examples in the book all show:
>
>SELECT * INTO OUTFILE 'books.dat'  FROM BOOK
>
>If I leave out the word 'outfile', I get sql error.
>
>Likewise, to input data from a table it's
>
>mysql> LOAD DATA LOCAL INFILE "event.txt" INTO TABLE event;
>
>bruce
>  
>
OOPS:

I was going from memory and did not test it before I opened mouth and 
inserted foot.
:-(

 From the documentation the syntax should be:

SELECT a,b,a+b INTO OUTFILE "/tmp/result.text"
FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"'
LINES TERMINATED BY "\n"
FROM test_table;

Thank you for pointing that out:
:-)



-- This is the linux-help@xxxxxxxxx list.  To unsubscribe,
visit http://www.complete.org/cgi-bin/listargate-aclug.cgi


[Prev in Thread] Current Thread [Next in Thread]