Cascades - Deletes and Updates

Cascades - Deletes and Updates

Post by John Bradley Richard » Sat, 11 Jan 1997 04:00:00



I don't think it supports it in the current version. You can use
Declarative Referential Integrity constraints (DRI - references | foreign
key stuff) to enfore referential integrity. I think cascading is up to you
though. Probably a good idea to write some stored procs to do these
operations (e.g. sp_Delete( primary_key_value) and then delete all
dependent records before deleting the primary record). The other method
would be to use Triggers, it's my understanding that these can't be used if
you are using DRI. CAUTION: I am new to SQL Server programming so please,
verify my advice!
--
John B. Richards
Medical Care Systems, Inc.



Quote:> Does anyone know if SQL 6.5 actually performs cascade deletes and
updates.
> If so, how do you activates it?

 
 
 

Cascades - Deletes and Updates

Post by Patrick Ikhif » Sat, 11 Jan 1997 04:00:00


Does anyone know if SQL 6.5 actually performs cascade deletes and updates.
If so, how do you activates it?

 
 
 

Cascades - Deletes and Updates

Post by Tibor Karasz » Tue, 14 Jan 1997 04:00:00


Verified.

The reason for not being able to coexist cascading triggers with DRI is
that DRI "executes" first, which will do RESTRICT. You will never enter
your trigger code (CASCADE).
--

Instructor (MCT, MCSE, MCSD)
Cornerstone Sweden AB



> I don't think it supports it in the current version. You can use
> Declarative Referential Integrity constraints (DRI - references | foreign
> key stuff) to enfore referential integrity. I think cascading is up to
you
> though. Probably a good idea to write some stored procs to do these
> operations (e.g. sp_Delete( primary_key_value) and then delete all
> dependent records before deleting the primary record). The other method
> would be to use Triggers, it's my understanding that these can't be used
if
> you are using DRI. CAUTION: I am new to SQL Server programming so please,
> verify my advice!
> --
> John B. Richards
> Medical Care Systems, Inc.



> > Does anyone know if SQL 6.5 actually performs cascade deletes and
> updates.
> > If so, how do you activates it?

 
 
 

1. New Feature - Cascading Deletes and Updates

Can this feature be made to work through transactional replication?

Example: If a dependent table receive a cascade delete instruction from a
parent table, and the dependent table transactionally replicates to a table
in another database, AND that table is a parent table to dependent table
which both contain elements of the first cascade delete...

What will happen?
Will the transaction (cascade delete) be prohibited in the publisher?
Will the transaction happen, but the replication generate an error?

--
Regards,
Mark Simmerman
SQL Learner
Napa, CA 94559

2. SQL Statement

3. Cascading Deletes and Updates can cause multiple collision paths

4. BDE database problem.

5. Cascading Deletes and Updates with SQLServer

6. Oracle and ASP

7. Cascade Deletes and Updates

8. Borland Reflex 2.0 Recover

9. How to use ON UPDATE CASCADE ON DELETE CASCADE

10. Can't enforce FK contrain on Delete Cascade and Update Cascade

11. cascade update , cascade delete

12. Cascade Delete and Cascade Update on SQL 7

13. Look for update cascade, delete restrict function