Hi Kalyan,
You may need to join some Derby system tables in order to retrieve the
information you need. The following email thread may be helpful:
http://www.nabble.com/How-can-I-fetch-constraint-attribute-on-Column-Level-from-SYS-Tables---td19554573.html#a19554573
Hope this helps,
-Rick
Kalyan Inuganti wrote:
Hi,
I am reaching out to you guys for some help with a Derby indexing
issue that we have run into at Monsanto, St. Louis. The issue is
pretty much the same issue that was reported by Thomas J. Taylor in
2007 (The link is provided below).
*Brief Description:*
I have a database that was originally created with Derby 10.1.1.0 and was
recently upgraded to Derby 10.2.2.0. I've performed this upgrade on several
copies of the same database schema (each created on different computers,
but with the same version of Java (1.5.0_07) and Derby (10.1)).
For all but one of the database upgrades, it worked correctly. However, in
one case, it appears that the PRIMARY KEY and FOREIGN KEY constraints have
been lost/corrupted. When I use DBLook to check a 'working' database, I see
the appropriate constraints for keys. However, on the 'defective' database,
these constraints are missing.
We have over 80 tables in the DB and over 1000 users. Even though we
have only 2 reported occurrences of this issue so far, it might be
more widespread. It is a nightmare to manually identify the corrupted
indexes for each occurrence. Any thoughts on how we can tackle this
through a programmatic approach?
Here is the link to the old report:
http://mail-archives.apache.org/mod_mbox/db-derby-user/200704.mbox/%[email protected]%3e
Thanks,
Kal