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.
| Author |
Topic |
|
sql777
Constraint Violating Yak Guru
314 Posts |
Posted - 2004-12-17 : 14:29:33
|
| Hi,I'm having some issues with cascading deletes.I have a table which contains the PK, and I obviusly cannot delete that row until I delete all the child tables.So I am doing:delete table_awhere myid = @myiddelete table_bwhere myid = @myid-- i need to loop through all call this sproc x number of times...passing it some ids-- get all the ids from table_abc and then call this sprocexec mysproc @someotherID -- <------------------------------??-- pk tabledelete table_PKwhere myid = @myid |
|
|
Hippi
Yak Posting Veteran
63 Posts |
Posted - 2004-12-17 : 14:53:50
|
| Maybe I don't understand your question but in SQL 2000, it supports cascade delete or you may use a trigger to do it. |
 |
|
|
robvolk
Most Valuable Yak
15732 Posts |
Posted - 2004-12-17 : 14:58:53
|
| There's also:http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=14594 |
 |
|
|
|
|
|