Thread: creating a constraint on the same table

creating a constraint on the same table

From
"Matt Friedman"
Date:
I have a category table with a primary key called cat_id
and another column called parent_id
 
the parent_id must be part of the cat_id column
 
it's alot like a foreign key constraint but I don't know the sql to do it.
any ideas?
 
Is this a novice question or should I try a different list?

Matt Friedman
Spry New Media
http://www.sprynewmedia.com
Lead Programmer/Partner
email:
matt@sprynewmedia.com
phone: 250 744 3655
fax: 250 370 0436