Visio ORM Irreflexive Constraint

M

McGiv

I've got a Category Object that links to itself (parent) I trying to
stop a category being the parent of itself.

The Constraints are:

Each Category is the child of how many Category? Exactly One
Each Category is the parent of how many Category? Zero or More


I've also a Irreflexive constraint which generates:

[Category] is the child of [Category] / [Category] is the parent of
[Category]
No Category is the child of itself.

But in my examples I have

1 0
2 0
3 2
4 3
5 5

Shouldn't 5 - 5 cause an error when I analyze? as it doesn't - I
assumed that the Irreflexive constraint wouldn't allow it.

Do you know how to configure the constraints to achieve my goal?

Cheers,
Damien
 
S

Scot Becker

Hi Damien,
I've got a Category Object that links to itself (parent) I trying to
stop a category being the parent of itself.

The Constraints are:

Each Category is the child of how many Category? Exactly One
Each Category is the parent of how many Category? Zero or More


I've also a Irreflexive constraint which generates:

[Category] is the child of [Category] / [Category] is the parent of
[Category]
No Category is the child of itself.

But in my examples I have

1 0
2 0
3 2
4 3
5 5

Shouldn't 5 - 5 cause an error when I analyze? as it doesn't - I
assumed that the Irreflexive constraint wouldn't allow it.

Do you know how to configure the constraints to achieve my goal?

I don't the think the analyzer is smart enough to spot ring constraint
violations. When looking at example data, it pretty much only looks for UC
violations (and will nag you if you have too few example rows).

HTH,
Scot.
................................................
Scot Becker

Orthogonal Software
www.orthogonalsoftware.com

ORM Blog: www.objectrolemodeling.com

To e-mail me, please use my first name at the domain listed above. All mail
sent to the reply-to address gets routed to a junk e-mail folder where it
will likely be deleted without being read.
 
M

McGiv

Thanks for clearing that up for me Scot.

BTW - like the blog, very informative

Cheers,
Damien
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top