@echo off
set "Ymd=%date:~,4%%date:~5,2%%date:~8,2%"
cd D:
md %Ymd%
cd "C:\Program Files (x86)\MySQL\MySQL Server 5.1\bin"
cd C:
mysqldump -u root -proot -h xx.xx.xx.xx eoss-product > D:/%Ymd%/%Ymd%.sql
exit
-h 后边是要连接的MYSQL 数据库的IP 如果是本机 则不需要写 -h
时间: 2024-11-05 23:28:50