Contention on Dropping foreign key

Sibimon Philip

Contention on Dropping foreign key
I am trying to drop a foreign key, but I am getting -911 because one of the
developer is running a select query in QMF. (It looks like developer is
swapped out of DB2). The table on which the select is running does not have
any relation to the table for which I am dropping the foreign key. But both
are in the same database. Again there is no lock on any table in this
database, but I see table on which select is running displayed when I use
USE keyword in DISPLAY command. I am just curious to know why DB2 is giving
me -911 in this case. Can't it drop this foreign key without any problem.


Thanks for any insight

Sibi



Tim Lowe

Re: Contention on Dropping foreign key
(in response to Sibimon Philip)
Philip,
I would guess that the -911 is because it could not get an exclusive lock
on the DBD to update it.
What is the resource name and resource type that was returned with the
-911?

Thanks,
Tim



"Philip,
Sibimon" To: [login to unmask email]
<[login to unmask email] cc:
INES.COM> Subject: Contention on Dropping foreign key
Sent by: DB2
Data Base
Discussion
List
<[login to unmask email]
OM>


01/05/2001
02:21 PM
Please
respond to
DB2 Data Base
Discussion
List






I am trying to drop a foreign key, but I am getting -911 because one of the
developer is running a select query in QMF. (It looks like developer is
swapped out of DB2). The table on which the select is running does not
have
any relation to the table for which I am dropping the foreign key. But both
are in the same database. Again there is no lock on any table in this
database, but I see table on which select is running displayed when I use
USE keyword in DISPLAY command. I am just curious to know why DB2 is giving
me -911 in this case. Can't it drop this foreign key without any problem.


Thanks for any insight

Sibi








Ashish Mohan

Re: Contention on Dropping foreign key
(in response to Tim Lowe)
Because the developer , owing to the fact that he ran a dynamic query and
did not come out of QMF or did not do RESET DATA or did not max down to the
bottom of his result set is still holding a shared lock on the DBD and
because you are changing the 'database structure' you want an exclusive lock
over DBD which is of course not possible.

Ashish.

-----Original Message-----
From: Philip, Sibimon [SMTP:[login to unmask email]
Sent: Friday, January 05, 2001 12:22 PM
To: [login to unmask email]
Subject: Contention on Dropping foreign key

I am trying to drop a foreign key, but I am getting -911 because one
of the
developer is running a select query in QMF. (It looks like developer
is
swapped out of DB2). The table on which the select is running does
not have
any relation to the table for which I am dropping the foreign key.
But both
are in the same database. Again there is no lock on any table in
this
database, but I see table on which select is running displayed when
I use
USE keyword in DISPLAY command. I am just curious to know why DB2 is
giving
me -911 in this case. Can't it drop this foreign key without any
problem.


Thanks for any insight

Sibi




can