Immy
3/20/2007 2:45:00 PM
Cant say if there is a 'restart sql' command in 2005, but previous versions
only allow the SHUTDOWN command which will stop the service but not restart
it.
The issue with issuing a restart command via SQL is that at the point the
service is stopped, you no longer have a connection to the server to issue
the Restart.
You could try creating a batch file with the NET STOP and NET START commands
and then call the batch file from xp_cmdshell?
Immy
"Hadidi" <Hadidi@discussions.microsoft.com> wrote in message
news:75F1532A-B76B-44C6-8647-A1BCBAF5FEB8@microsoft.com...
> I'm changing sql server configuration using a sql query .. these changes
> needs restarting the server .
> So .. Is it possible to restart the server , & how ??
>
> Thanks