in

The ORM Foundation

Get the facts!

values as subsets

Last post Thu, Oct 23 2008 1:45 by rolemo. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • Wed, Oct 22 2008 17:50

    • rolemo
    • Top 25 Contributor
    • Joined on Sun, Oct 12 2008
    • Posts 38

    values as subsets

     Hello,

    In my UoD each Employee(.id) has Permission(premLevel). permLevel value range is {Organisation, Region, Country}, and each level contains the lower ones (e.g., with Organisation permLevel an Emp has access to empData only in her Organisation, with Region permLevel you can access empData that is accessible for Organisation permLevel plus data for the entire region, etc).

    so my question is - can i define the lower permLevel as a subset of the lower one? or must I create them as entities in order to do so?

     

    Cheers 

  • Wed, Oct 22 2008 18:23 In reply to

    Re: values as subsets

    Rolemo

    It sounds like you have a mandatory, n:1 fact type "Employee(.id) has PermissionLevel(.name)" with the value constraint {'Organization', 'Region', 'Country'} on PermissionLevel.

    Adding subsetting doesn't help. You need to specify elsewhere what semantics you attach to these levels. Depending on how you are implementing security/authorization, you could do it directly in database metatables (e.g. using grant, revoke etc.) or in an ORM metaschema designed for this purpose (e.g. Role has AccessRight to FactType, etc.).

    Cheers

    Terry

  • Thu, Oct 23 2008 1:45 In reply to

    • rolemo
    • Top 25 Contributor
    • Joined on Sun, Oct 12 2008
    • Posts 38

    Re: values as subsets

    I see. thanks.

    I was wondering if there are any ORM excersises available somewhere. What I'm most interested in would be simply UoD descriptions, from which to generate ORM diagrams, accompained by lists of elementary facts derived from them and the final ORM diagram, so that I'll be able to compare my solution with a propper one.

    Do you happen to know where I can find such thing?

    Cheers

Page 1 of 1 (3 items)
© 2008-2024 ------- Terms of Service