【发布时间】:2020-01-17 23:44:15
【问题描述】:
我在 Amazon RDS 的数据库 myDatabase 中有一个表。让它成为myTable。
use myDatabase;
SELECT * from myTable INTO OUTFILE 'myFile.csv' FIELDS TERMINATED BY ',' ENCLOSED BY '"'LINES
TERMINATED BY '\n';
我收到此错误
Error Code: 1045. Access denied for user '<<UserName>>'@'%' (using password: YES)
我试过运行这个命令
GRANT USAGE ON *.* TO '<<UserName>>'@'%' IDENTIFIED BY '<<password>>';
flush privileges;
0 row(s) affected, 1 warning(s): 1287 Using GRANT statement to modify existing user's
properties other than privileges is deprecated and will be removed in future release. Use
ALTER USER statement for this operation.
我收到此警告。
和
我根本无法将表格导出到.CSV 文件中。
关于如何解决它的任何想法?对可能出错的步骤有什么想法吗?
【问题讨论】:
-
对我的回答有任何反馈吗?解决问题了吗?
标签: mysql export-to-csv