更新时间:2023-02-19 20:00:15
还有一个原因,为什么你不叫mysqldump的直接?
Is there a reason why you don't call mysqldump directly?
ProcessStartInfo procStartInfo =
new ProcessStartInfo("mysqldump", "uroot ppassword databse > c:/data.sql");
如果没有的是的一个原因,你的code应该是这样的:
If there is a reason, your code should look like this:
ProcessStartInfo procStartInfo =
new ProcessStartInfo("cmd",
"/c \"mysqldump uroot ppassword databse > c:/data.sql\"");
更改:
CMD
变量mysqldump的。cmd
variable.