摘要:
try { Runtime run = Runtime.getRuntime(); String[] cmd = new String[] { "cmd.exe","/C","mysqldump -uroot -p111111 test> c:/test.sql"}; Process p = run.exec(cmd); p.waitFor(); System.out.println("end."); } catch (Exception e) { e.printStackTrace(); } 阅读全文