RBAC - problem with AuthItemChild Table on SQLScript

When you run the sql script in the database:




create table AuthItemChild

(

   parent               varchar(64) not null,

   child                varchar(64) not null,

   primary key (parent,child),

   foreign key (parent) references AuthItem (name) on delete cascade on update cascade,

   foreign key (child) references AuthItem (name) on delete cascade on update cascade

);

The system says:

Mess. 1785, Level 16, State 0, Line 1

If you specify the constraint FOREIGN KEY ‘FK__AuthItemC__child__3F522093’ in table ‘AuthItemChild’, may cause cycles or multiple cascade paths. Specify ON DELETE NO ACTION or UPDATE NO ACTION, or modify other restrictions FOREIGN KEY.

Mess. 1750, Level 16, State 0, Line 1

Could not create constraint. See previous errors.

This is not Yii related… By googling a bit I found these two articles that has more info on this error:

http://support.microsoft.com/kb/321843