> Hi All,
>
[quoted text clipped - 9 lines]
> Thanks,
> Harry
That doesn't make sense
Harry - 29 Jan 2007 01:32 GMT
Can you elaborate more?
Which part doesn't make sense
and how to solve if I am in this case.
> > Hi All,
>
[quoted text clipped - 9 lines]
> > Thanks,
> > HarryThat doesn't make sense
> Hi All,
>
[quoted text clipped - 9 lines]
> Thanks,
> Harry
So, a User has a specific Roles, and the Roles allow access to
specific Modules?
Would that look like:
class User {
Collection<Role> roles;
// Extra user data.
}
class Role {
Collection<Module> accessableModules;
Collection<User> users;
// Extra role data
}
class Module {
// module data
}
So, this would be
User many-to-many Role
Role one-to-many Module
Hope this helps,
Daniel.
Harry - 29 Jan 2007 02:07 GMT
Thanks for that in advance
Perhaps it's my problem on not giving a good example.
What I mean is really when tertiary relationship exists ( I think you
should know tertiary does exist in ERD)
I try to use another example.
Person-Order-LineItem relationship
-----------------
| Line Item |
-----------------
|
-------------- | -----------
| Person | ------- ( ) ------ | Order |
-------------- -----------
In this case, Line Item instances appear when a relationship between
the Person and Order forms.
Hope my example does a good illustration.
Thanks for your help.
Harry
On Jan 29, 9:41 am, "Daniel Pitts" <googlegrou...@coloraura.com>
wrote:
> > Hi All,
>
[quoted text clipped - 30 lines]
> Hope this helps,
> Daniel.
Danno - 29 Jan 2007 04:13 GMT
> Thanks for that in advance
> Perhaps it's my problem on not giving a good example.
[quoted text clipped - 11 lines]
> | Person | ------- ( ) ------ | Order |
> -------------- -----------
A Person Order Line Item Relationship would look like this...
Person (1)------------(∞) Order (1)--------------(∞) LineItem
There would be no need for a "tertiary" relationship.
Danno - 29 Jan 2007 04:15 GMT
On Jan 28, 6:41 pm, "Daniel Pitts" <googlegrou...@coloraura.com>
wrote:
> > Hi All,
>
[quoted text clipped - 30 lines]
> Hope this helps,
> Daniel.
I agree, I would have Module have access to roles, and roles not have
access to modules. But that's the same design I was thinking.
Harry - 29 Jan 2007 06:59 GMT
So, what you mean is to convert every tertiary relationship to two
relationships each in between two of the three entities?
Is it really possible to convert all kinds of relationships like this?
Thanks
Harry
> On Jan 28, 6:41 pm, "Daniel Pitts" <googlegrou...@coloraura.com>
> wrote:
[quoted text clipped - 34 lines]
> > Daniel.I agree, I would have Module have access to roles, and roles not have
> access to modules. But that's the same design I was thinking.
Danno - 29 Jan 2007 15:32 GMT
Well, I wouldn't treat anything anyone says as religious doctrine.
So, to say, "convert ALL kinds of relationships like this" won't help
you out either. You have to model your ERD and object mappings based
on reality. You will find that this idea of tertiary relationship
where you have a prop table with 3 keys and nothing else will less
likely exist.
> So, what you mean is to convert every tertiary relationship to two
> relationships each in between two of the three entities?
[quoted text clipped - 41 lines]
> > > Daniel.I agree, I would have Module have access to roles, and roles not have
> > access to modules. But that's the same design I was thinking.