Options

How Do I Launch DTS Jobs/OS Commands From Within Navision...

bougeacbougeac Member Posts: 24
Hi everyone, im a comparative newbie to NAVISION and we are currently running 3.70.

My question is, is there an easy way to launch a sqlserver DTS job from within navision or launch a *.bat file?

Any suggestions gratefully accepted!

Best,

Chris

Comments

  • ara3nara3n Member Posts: 9,258
    Hello. You have to connect through ado and execute the following command
    MaintenancePlan is a job.

    EXEC msdb..sp_start_job 'MaintenancePlan'
    


    Here is an example on how to use ADO.

    http://www.mibuso.com/forum/viewtopic.php?t=2401&highlight=ado+connect
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
  • FishermanFisherman Member Posts: 456
    I've never used SHELL in Navision, but if the code will run on the server, then you should be able to use SHELL to call DTSRun - a command line exe that runs DTS packages. If you will be running the code from a client other than the SQL Server, then you'll need to use ADO.
  • bougeacbougeac Member Posts: 24
    Hi guys, thanks for the help, will look at both approaches...

    cheers,

    chris
Sign In or Register to comment.