所以上网找了下教程
自己写个批处理 自动启动服务
哇哈哈
突然觉得 只要有网络 语言不是啥大的障碍
写起来都差不多呀
哇哈哈
话说最近又加了个ORACLE的服务
依然偷懒
把原先的改改用吧 哈哈
就成这样了
@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