• I have a similar situation that I solved by adding a job step at the beginning of the job to check for rows in the target table and forcing an error if the table is not empty.

    --Throw a Divide by Zero error if there are rows in the target table

    SELECT TOP 1 1/

    CASE

    WHEN ID > 0 THEN 0

    ELSE 1

    END

    FROM TableA;

    On the Advanced tab of the job step set the On Success Action to "Go to the next step."

    Use the Retry Attempts and Retry Interval to set how many times and how often it will check again before giving up.

    For example, you could set the Retry Attempts to 5 and the Retry Interval to 1 to make it check every minute for 5 minutes before failing.

    Use the On Failure action to do whatever you want to do when it gives up; I created another step to send an email notification.

    I hope this helps

    --Garry