View previous topic :: View next topic
|
Author |
Message |
M David Hunter
New User
Joined: 30 Jan 2012 Posts: 6 Location: United States
|
|
|
|
I received a -532 on a DELETE. There is a constraint on a foreign key. I want to find the specific descendent row identified by the RID. So far I haven't been able to find a method of doing this. Any suggestions?
Thanks |
|
Back to top |
|
|
Akatsukami
Global Moderator
Joined: 03 Oct 2009 Posts: 1788 Location: Bloomington, IL
|
|
|
|
GuyC can probably give you a better answer, but if the table has a column with type ROWID, you can search on it. |
|
Back to top |
|
|
M David Hunter
New User
Joined: 30 Jan 2012 Posts: 6 Location: United States
|
|
|
|
Unfortunately none of the columns have a type of ROWID! |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
if you have db2 9 or better,
you can follow the advice found here
then user your browser FIND for " Mar 30, 2011 05:22 PM",
a post by Patrick Bossman (IBM).
obviously, if you have reorg'd, you will have a problem. |
|
Back to top |
|
|
GuyC
Senior Member
Joined: 11 Aug 2009 Posts: 1281 Location: Belgium
|
|
|
|
as the link from dbz says :
Code: |
select * from table1 A where RID(A) = 65861 |
where 65861 = decimal value of the hex-value you've got in the errormessage.
you could also do
Code: |
select * from childtable where Foreignkeyfields in (select primarykeyfields from parenttable where your_original_delete_where_clause) |
|
|
Back to top |
|
|
|