Can you expand on what you mean by
"This works when I delete a row directly from x_orders_contents,
but seems to cause a lock when I delete a row from
the parent table and the delete RI constraint is used."
Are you saying that the delete works fine when you delete an individual
row directly from x_orders_contents, but you encounter a "deadlock"
when you delete an "x_orders" which causes a cascade delete due to the
RI?
What is your lock timeout period?
To check for deadlocks, you may want to use the deadlock monitor
(enabled by default on DB2 v8 - but only on catalog node in partitioned
database). You can even use snapshot and "list applications show
detail" to extract the locking information......
-- Jayesh
Syn wrote:
Hello,
I have a parent table(x_orders) and a child table(x_orders_contents),
with a cascade delete on the child table. In a after delete trigger of
the x_orders_contents table I'm updating a field in the x_orders
corresponding row. This works when I delete a row directly from
x_orders_contents, but seems to cause a lock when I delete a row from
the parent table and the delete RI constraint is used. Is there a way
to find if the RI constraint is responsible for the deletion ? Also
some way to find if a row in a table is locked by delete statement ?
Thanks
--
Syn
------------------------------------------------------------------------
Syn's Profile: http://www.dbtalk.net/m597
View this thread: http://www.dbtalk.net/t322649