Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Supress SQL Errors
Message
De
26/04/2001 13:47:58
 
 
À
26/04/2001 11:07:41
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Stored procedures, Triggers, UDFs
Divers
Thread ID:
00500132
Message ID:
00500268
Vues:
20
I don't believe that there is anyway to prevent SQL Server from raising the error. Your option is probably to test to see if the delete would cause a problem. This, of course, requires that you embed the relationships within your stored procedure:

IF NOT EXIST(SELECT * FROM books WHERE au_id = @author)
BEGIN
DELETE FROM authors WHERE au_id = @author
END

-Mike
Michael Levy
MCSD, MCDBA
ma_levy@hotmail.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform