• Jeff Moden (3/26/2009)


    krushnasahu (3/26/2009)


    I have some more doubts.

    Actually I need to run an exe file from stored proc.

    So, I wrote the stored proc like:

    create proc callExe

    As

    EXEC xp_cmdshell '\\192.10.10.245\E:\PrintToPDFConsole.exe'

    In this 192.10.10.245 is another system apart from the sql server.

    and the exe file path is E:\PrintToPDFConsole.exe

    But the exe file is not working when I executed the stored proc callExe.

    Note that the PrintToPDFConsole.exe don't have any interface.

    Please help in this issue.

    Thank you.

    Krushna

    Does that actually run if you try it from a real command window?

    Yes, the exe is working fine when it run from command prompt.

    But when the stored proc was executed, the output coming as null and the exe is not processing.