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 MikeeOK on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Newbie question: Which tables are affected? 1

Status
Not open for further replies.

DrYueh

Programmer
Nov 26, 2002
2
CH
Hi to everybody.

I have a stupid little problem: i have a delete statement for exactly one row. i'm sure of that because i identified this row by the primary key.

If i start this query in the query analyzer it says the following:
--start
(1 row(s) affected)


(0 row(s) affected)


(7 row(s) affected)
--end

it seems for me at if it is accessing three tables. i guess there are some constraints somewhere in the db, but i dont have clue where. So my question is, how can i get the names of the tables which rows were affected?

thanks in advance + lots of fun
 
Are there foriegn keys in other tables that are affected by your delete statement? It sounds like you might have a cascade on delete event happening - all the "children" that are affected by your delete are also being dropped.... -- Just trying to help...
[wolf]<--- This is a wolf? We need a new icon.......
mikewolf@tst-us.com
 
Or there could be a trigger on the table for delete and other tables may be getting affected in this trigger. You can check by using sp_helptrigger system proc for the concerned table.
RT
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top