Hi. On Tue, Oct 02, 2001 at 11:52:21AM +0800, [EMAIL PROTECTED] wrote: > I have a batch file called mysql.txt containing the single line, > > select "test \n test"; > > My command for running this file is: > > mysql -N -B stud < mysql.txt > out.txt > > After running the command, out.txt contains "test \n test" -- with the > "\n" appearing literally, instead of a newline character. In other > words, it's the output I'd expect from
shell> mysql --help [...] -B, --batch Print results with a tab as separator, each row on a new line. Doesn't use history file. [...] This means, because a newline will indicate a new record, new lines have to be escaped. Else, you couldn't reasonably distinguish what's content and what's record seperator. Example: shell> mysql -B -N yasg -e "select 'test\ntest'" test\ntest shell> mysql -t -N yasg -e "select 'test\ntest'" +-----------+ | test test | +-----------+ Bye, Benjamin. -- [EMAIL PROTECTED] --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php