Start a Job when File Exists

  • I have created a number of jobs that I want to start when certain files exist.  I know that I can use Alerts to start a job but don't know how to create an alert that says a file exists

  • Mat,

    There is no alert you can create for that (AFAIK).  You will need to run a job every (n) minutes to see if file exists and IF TRUE THEN fire off the other jobs...



    Good Hunting!

    AJ Ahrens


    webmaster@kritter.net

  • That is what I am also trying to do, but I don't have the Stored Procedure to look for an existing file.  Do you know where I can get the T-SQL to create one?

  • I honestly think it would be easier to put that into a DTS package with VBScript and fire off jobs from there...



    Good Hunting!

    AJ Ahrens


    webmaster@kritter.net

  • there is a script in the contributions section to check if a file exists...you could adapt it from there to call your functionality:

    Perform an action when a file exisits

    Script Rating   Total number of votes [15]

    By: torpenhow

    http://www.sqlservercentral.com/scripts/contributions/138.asp

     

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • ...or why not setup a service that executes different actions when files are created/modified/deleted?

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic. Login to reply