2012-11-25 92 views
2

我試着在mysql中端以下語句:mysql如何撤銷文件

revoke file on *.* to 'john'@'localhost'; 

但我得到的錯誤:

ERROR 1064 (42000): 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 'to 'john'@'localhost'' at line 1 

什麼是REVOKE語句的正確語法?我嘗試閱讀MySQL文檔,但不明白。

回答

3

在您的查詢中,將to替換爲from。就像這樣:

revoke file on *.* from 'john'@'localhost'; 

關於此命令的詳細信息,請參見MySQL docs for REVOKE