Results 1 to 3 of 3
  1. #1
    Join Date
    May 2003
    Posts
    12

    Unanswered: Dependency based scheduling

    Hi,
    I am scheduling a .bat at 9.00 am to load a text file in a table A in SQL Server 2000 database. If this load is successful, I want to trigger another .bat file to execute a store proc.

    Can I do this dependency based scheduling in SQL Server Scheduler and if so, can you give me details (references, books) as to how it can be done?

    Thanks in advance
    Shek

  2. #2
    Join Date
    Jul 2002
    Location
    IA
    Posts
    28
    I'd create a job with a couple of job steps. SQL server Books Online has info on sp_add_job and sp_add_jobstep. You can use XP_CMDSHELL to execute the bat files within the job steps.
    Thanks,
    Jason

  3. #3
    Join Date
    Feb 2002
    Location
    Houston, TX
    Posts
    809
    The job scheduler supports multipule tasks within one job. You can specify what action should be taken based on the success or failure of a task.

    I susspect you could work through this just by setting up a test job in the job scheduler. Books Online, SQL Server Help, has a good writeup on this.

    Look up "jobs" in the index. Also within jobs scan down to the sub topic of steps.
    Paul Young
    (Knowledge is power! Get some!)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •