@echo off echo 开启SQLSERVER服务按1 echo 关闭SQLSERVER服务按2 echo 开启ORACLE服务按3 echo 关闭ORACLE服务按4 set /p ans= if %ans%==1 goto sts if %ans%==2 goto ovs if %ans%==3 goto sto if %ans%==4 goto ovo :sta echo 准备开启SQLSERVER服务 net start SQLWriter net start ReportServer net start MsDtsServer net start msftesql net start SQLBrowser net start MSSQLSERVEROLAPService net start SQLSERVERAGENT net start MSSQL$SQLEXPRESS net start MSSQLSERVER goto exit
:ovs echo 准备关闭SQLSERVER服务 net stop SQLWriter net stop ReportServer net stop MsDtsServer net stop msftesql net stop SQLBrowser net stop MSSQLSERVEROLAPService net stop SQLSERVERAGENT net stop MSSQL$SQLEXPRESS net stop MSSQLSERVER goto exit
:sto echo 准备开启ORACLE服务 net start OracleDBConsoleorcl net start OracleOraDb10g_home1iSQL*Plus net start OracleOraDb10g_home1TNSListener net start OracleServiceORCL
goto exit
:ovo echo 准备关闭ORACLE服务 net stop OracleDBConsoleorcl net stop OracleOraDb10g_home1iSQL*Plus net stop OracleOraDb10g_home1TNSListener net stop OracleServiceORCL goto exit :exit echo over