Robertson-Ravo, Neil (RX) wrote: > > If you need to implement cascading referential integrity (such as cascading > deletes) in your SQL 2000 databases, use the cascading referential integrity > constraint instead of triggers to perform the cascading delete, as they are > much more efficient and can boost performance. If you have an older (7.0 and > older) application that you have moved to SQL Server 2000, and it used > triggers to perform cascading deletes, consider removing the triggers and > using cascading referential integrity instead.
It is good you qualify that statement to only apply to a certain version of a certain DBMS. PostgreSQL actually implements referential integrity by means of triggers internally :-) > If you have a choice between using a trigger or a CHECK constraint to > enforce rules or defaults within your SQL Server databases, you will > generally want to choose a CHECK constraint as they are faster than using > triggers when performing the same task. CHECK constraints should only be used when doing multi-column checks. If you are using a single column CHECK contraint, you should be using a DOMAIN or a TYPE. Jochem ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:203308 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

