I am calling the following statement from withing a Stored Proc in SQL Server 2005.
Backup Database @dbname to disk = @dest
I need to be able to store the result of the 'Backup Database' in a variable so if something goes wrong I can kick off an alert to notify someone of the failure. How can I get that value?