Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Generic way to DELETE Child Rows

Status
Not open for further replies.

ShankarJ

Programmer
Aug 9, 2003
856
Hi!

Before I venture into trying to do this on my own, I would like to know if any of you could guide me to create a Stored Procedure which takes as it's parameters the Table Name and the Row ID, finds all the dependant Child Tables and their ParentID link column to the given Table and generate SQL statements to delete these Child Rows. I need this to delete a Parent Row. All the Parent-Child foreign key relationship DO NOT have the CASCADE option on UPDATE.

Appreciate any help I can get.

Regards
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top