问题
Can anyone help me with this? I am currently trying to write my queries to a file and I will eventually close it with notee; call. I have used the tee call before but for some reason today I am having problems.
Here is the syntax in question:
tee c:/trash/test.txt;
select*from customer;
Here is the Error:
Error
There seems to be an error in your SQL query. The MySQL server error output below, if there is any, may also help you in diagnosing the problem.
ERROR: Unknown Punctuation String @ 6
STR: :/
SQL: tee c:/trash/test.txt;tee c:/trash/test.txt;tee c:/trash/test.txt;
SQL query:
tee c:/trash/test.txt;
MySQL said: Documentation
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'tee c:/trash/test.txt' at line 1
The file trash has been created so I know that is not the issue.
Any help will be appreciated thank you.
回答1:
The tee
and notee
commands are only available in the MySQL command-line client. They are not handled by the server, so they cannot be used in applications like phpMyAdmin.
来源:https://stackoverflow.com/questions/40454553/mysql-tee-syntax-not-working