Page 1 of 1

UC Unique constraints

PostPosted: Sat Oct 31, 2009 1:58 am
by atodpquery
I am trying to delete a group of DB2 tables of which some are parent and some are child. Parent has unique constraints on. I delete all the children tables and there is no problem but not the parent. What is unique constraints? How can I delete them without dropping the table. Where can I get some help from this.

:oops: :roll: ;) :lol: :idea:

Re: UC Unique constraints

PostPosted: Sat Oct 31, 2009 2:45 am
by dick scherrer
Hello,

I believe you have something confused. Unique Constraints are not related to parent/child table relationships.

A Unique Constraint is a rule that values entered for some key must be unique. For example if a key is "country_code" and only one of each "country value" is allowed, this could be enforced by a unique constraint.

I delete all the children tables and there is no problem but not the parent.
I don't know what this means - please clarify.

Re: UC Unique constraints

PostPosted: Thu Nov 05, 2009 5:12 pm
by atodpquery
Thanks for clarify UC. I have -532 when trying to delete a table. this table is a parent table of two child. I have successfully deleted the two child tables but when I delete the parent table I have -532 saying the relationship constraints exist and i could not work out why.

:oops: :idea:
Thanks.

Re: UC Unique constraints

PostPosted: Fri Nov 06, 2009 1:27 am
by dick scherrer
Hello,

The -532 provides the name of the constraint that was violated. . .

Did you read the documentation for the -532?
http://publibz.boulder.ibm.com/cgi-bin/ ... /2.1.6.232