Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

CHECK CONSTRAINT on DB2 V8 zOS

0 views
Skip to first unread message

joerg....@weltbild.com

unread,
May 9, 2008, 8:14:19 AM5/9/08
to
Hello,
is it possible to define a CHECK CONSTRAINT on a table, whereas the
CHECK-OPTION will be a SELECT.
With this CHECK CONSTRAINT i try to ensure, that there will allways a
state only set once within several rows. If possible, does someone can
provide an example ? I did not find anything in the docs.

Thanks

Joerg

Serge Rielau

unread,
May 9, 2008, 7:33:19 PM5/9/08
to
Check constraints are limited to data in the row.
Have you considered using a trigger or an RI constraint?

Cheers
Serge
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

--CELKO--

unread,
May 11, 2008, 9:09:20 AM5/11/08
to
>> is it possible to define a CHECK CONSTRAINT on a table, whereas the CHECK-OPTION will be a SELECT. <<

A check constraint must have search condition.

>> With this CHECK CONSTRAINT i try to ensure, that there will always a state only set once within several rows. <<

That sounds like a UNIQUE constraint. Post better specifications and
we can help you.

0 new messages