: How to repeat process many times without duplicating script: SQL connection : fails, but I want to retry 3 times. Create 2 jobs of 24x7-script type. First one handles your SQL and creates a semaphore file in notify action on FAIL. Perhaps this job has time-watch schedule. Your second job should have file-watch based schedule and "watch" for the semaphore file created by the first job. When it detects the file it can use JobModify statement to dynamically reschedule your first job. You will also need to put some additional logic into the second job to count number of FAILs. The logic depends on your interpretation of "3 times". It could be for example 3 times today, or 3 times since last successful run or 3 times since Monday or 3 times since last successful database backup or other.
|