Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Supress SQL Errors
Message
From
26/04/2001 13:47:58
 
 
To
26/04/2001 11:07:41
General information
Forum:
Microsoft SQL Server
Category:
Stored procedures, Triggers, UDFs
Miscellaneous
Thread ID:
00500132
Message ID:
00500268
Views:
19
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
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform