Sunday, March 25, 2012

backup should continue even after failure

I have created a stored procedure to backup databases,
right now if backup of one database fails then it stops
execution. I want it not to stop but move on to next
database backup.
I tried separating actual execution of the backup command
to another stored procedure hoping that if it fails then
it will return the control back to calling stored
procedure but it didn't.
Any help wil be very much appreciated.
Thanks in advance.Well one way is to make the backup thru a call to oSql. Then if it fails it
is up to you to detect it and do what you want.
--
Andrew J. Kelly SQL MVP
<anonymous@.discussions.microsoft.com> wrote in message
news:267801c47035$984e1c50$a301280a@.phx.gbl...
> I have created a stored procedure to backup databases,
> right now if backup of one database fails then it stops
> execution. I want it not to stop but move on to next
> database backup.
> I tried separating actual execution of the backup command
> to another stored procedure hoping that if it fails then
> it will return the control back to calling stored
> procedure but it didn't.
> Any help wil be very much appreciated.
> Thanks in advance.
>

No comments:

Post a Comment