What are the challenges you face when working across database platforms? Take the survey
Options

Sql Backup XP failed to recreate a backup

RayWestRayWest Posts: 2
edited January 10, 2006 9:43AM in SQL Backup Previous Versions
I have a stored proc that runs a number of times in different SQL server 2000 jobs to backup my production databases.
But if a backup fails I get the error email ok, but job shows as completed successfully.
@error which shows as zero even when proc fails.
Is there a way of trapping error externally of extended stored proc to force job to fail when backup fails.

Comments

  • Options
    Brian DonahueBrian Donahue Posts: 6,590 Bronze 1
    Hello Ray,

    SQL Backup doesn't raise an error to the SQL Server Agent when backup jobs fail, and that is why the last run status is always reported as success. You can determine whether the SQL Backup extended stored procedure had succeeded or failed by checking the output, which will be 0 or 1 depending on success or failure. There is some more information on how to adjust your SQL Server Agent script here:

    http://www.red-gate.com/messageboard/vi ... .php?t=974
Sign In or Register to comment.