简体   繁体   中英

Command Line in Batch file?

I am making a batch file to automate mysql installation silently. When I type the following line in the command prompt everything works fine.

"C:\\Program Files\\MySQL\\MySQL Server 5.1\\bin\\mysqlinstanceconfig.exe" -i -q ServiceName="mydb" RootPassword="pos" ServerType=DEVELOPMENT DatabaseType=INNODB Port=3306

My question is: can I somehow add this to a batch file so it will run it as if I entered it in the command line?

Thanks, Matt

yes, its easy. As Santa commented, just put your command inside some text file, change the extension of that file to .bat. Thats all !!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM