Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 hey guys (QUESTION)

Author  Topic 

Danny4003
Starting Member

40 Posts

Posted - 2007-01-10 : 16:14:37
My question is can anybody explain Cascade Update and Deletes and plz tell me like i am your student. Thanks in Advance
Danny D

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2007-01-10 : 16:18:29
You haven't paid your tution!
Does that sound real enough?


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

Danny4003
Starting Member

40 Posts

Posted - 2007-01-10 : 16:21:03
I never took a class...:) just can't get the concept of it

Thanks
Danny D
Go to Top of Page

AndrewMurphy
Master Smack Fu Yak Hacker

2916 Posts

Posted - 2007-01-11 : 07:02:51
In a parallel world where wallet is the "parent" table and money is the "child" table

cascade delete....you lose your wallet => you lose all the cash inside it.
delete from wallet, will cascade and delete all money records.

my impression of cascade update is (as I don't implement it)
cascade update....you dip your wallet in blue ink => all your money turns from green to blue.
update wallet set color = blue, will cascade through each money records and set the color to blue

the alternative view (ie cascade upwards) is that as you spend money, your wallet is automatically updated to have a lower "remaining balance"
Go to Top of Page
   

- Advertisement -