December 10, 2008 at 4:26 am
Hi
How can i execute .exe from SQL server.
I tried with
EXEC xp_cmdshell 'C:\WINDOWS\System32\calc.exe'
but it goes in endless loop.
December 10, 2008 at 5:04 am
If you log on to the server that you are issuing the xp_cmdshell command to, you will see in the task manager that calc.exe is running. It appears to be in a loop as it waiting for either input or for the process to be terminated.
December 10, 2008 at 5:09 am
Thanks! It was indeed seen in the task manager.
But if I want to call some other exe that resides in d: say
d:ew_doc\abc.exe
then will my command work
exec xp_cmdshell ' d:ew_doc\abc.exe'
will it execute abc.exe
December 10, 2008 at 5:14 am
Yes, it will execute. Try it out and you'll see it in task manager.
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply