Calling external program from SQL Server

Posted on 2006-05-10
Last Modified: 2006-11-18
How can I call an external program from within a trigger in SQL Server?  I need to pass several parameters.  Please provide specific syntax. Thank you.
Question by:MGothelf
    LVL 142

    Accepted Solution

    you can use the xp_cmdshell stored procedure (SQL Server 2000).

    some sample :
    exec xp_cmdshell 'C:\app\app.exe /f=1 /t=3 '
    LVL 75

    Expert Comment

    by:Anthony Perkins
    The following questions are considered abandoned, please attend to them:
    1 03/14/2006 0 Working - Award additional points to que...  Open Suggestions
    2 03/22/2006 500 ODBC to SQL much slower than MS Access -...  Open Microsoft SQL Server
    3 04/19/2006 250 listbox removeitem method not supported  Open Microsoft Access

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Maximize Your Threat Intelligence Reporting

    Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

    Introduced in Microsoft SQL Server 2005, the Copy Database Wizard ( is useful in copying databases and associated objects between SQL instances; therefore, it is a good migration and upgrade tool…
    Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
    This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function
    Via a live example, show how to setup several different housekeeping processes for a SQL Server.

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now