SaranacLake Posted September 8, 2019 Share Posted September 8, 2019 If I said that my database has an "Entitlement" table, what purpose would you expect that to serve? (Hint: Not a trick question, but rather trying to see how people use terms and their meanings.) Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/ Share on other sites More sharing options...
Barand Posted September 8, 2019 Share Posted September 8, 2019 My guesses would be A register of Dukes, Duchesses, Earls, Countesses, Barons and Knights and any other titled personnel A table defining access rights to products/services for users A table defining leave entitlement for employees Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569503 Share on other sites More sharing options...
SaranacLake Posted September 8, 2019 Author Share Posted September 8, 2019 58 minutes ago, Barand said: My guesses would be A register of Dukes, Duchesses, Earls, Countesses, Barons and Knights and any other titled personnel A table defining access rights to products/services for users A table defining leave entitlement for employees Since I'm in the U.S. and we only have one king here, #1 doesn't apply. Yes, #2 is close. Okay, so on to my question... I picked up the term "entitlements" from work where I am often told to call the help desk and request OIM entitlements for a given enterprise system. So I applied that concept to my website since I didn't have a good name for it. Over the last week or so I built a fancy ERD modeling tables related to people subscribing to my website and thus getting access to things. Without posting all the intimate details of my data model, let me say that I create an "Entitlement" table which linked MEMBERSHIP_PLAN to SITE_FEATURE which is a many-to-many relationship. Does that sound like a reasonable use of the term "Entitlement"? Then as part of that, I also needed a way to link MEMBERS to MEMBERSHIP_PLANS and I did that with a "Subscriiption" table. Does that sound okay? The reason for starting this thread is second-guessing myself?! One could argue that a MEMBER has an ENTITLEMENT to a given MEMBERSHIP_PLAN, right? If you agree, then it is almost like there is a need for two Entitlement tables, although I am comfortable with my SUBSCRIPTION table. Thoughts? Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569505 Share on other sites More sharing options...
Barand Posted September 8, 2019 Share Posted September 8, 2019 So long as the name is meaningful, describing the entity or relationship contained in the table, then that's all that matters. Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569506 Share on other sites More sharing options...
SaranacLake Posted September 8, 2019 Author Share Posted September 8, 2019 1 minute ago, Barand said: So long as the name is meaningful, describing the entity or relationship contained in the table, then that's all that matters. But do you think that ENTITLEMENT applies more to the relationship between MEMBER and MEMBERSHIP_PLAN or between MEMBERSHIP_PLAN and SITE_FEATURE? Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569507 Share on other sites More sharing options...
Barand Posted September 8, 2019 Share Posted September 8, 2019 I would go for +----------+ +-------------------+ +----------------+ | member | | membership_plan | | site_feature | +----------+ +-------------------+ +----------------+ \ / \ / \ / \ / +--------------+ +--------------+ | subscription | | entitlement | +--------------+ +--------------+ Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569512 Share on other sites More sharing options...
SaranacLake Posted September 9, 2019 Author Share Posted September 9, 2019 1 hour ago, Barand said: I would go for +----------+ +-------------------+ +----------------+ | member | | membership_plan | | site_feature | +----------+ +-------------------+ +----------------+ \ / \ / \ / \ / +--------------+ +--------------+ | subscription | | entitlement | +--------------+ +--------------+ That is what I have. I just started wondering if maybe my SUBSCRIPTION table shouldn't have the word "entitlement" in it to. And so I started pondering whether "Entitlements" relate more to people or to things like site features. Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569514 Share on other sites More sharing options...
benanamen Posted September 9, 2019 Share Posted September 9, 2019 This reminds me of the Bike Shed Problem. Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569515 Share on other sites More sharing options...
SaranacLake Posted September 9, 2019 Author Share Posted September 9, 2019 3 minutes ago, benanamen said: This reminds me of the Bike Shed Problem. Poor analogy... Taking time to understand entities and their relationships and coming up with good names is one of the most important things you can do when designing a system. Almost every problem I have encountered over the last 25+ years is because people didn't take time up front to understand the data entities and their relationships and related processes. Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569516 Share on other sites More sharing options...
maxxd Posted September 9, 2019 Share Posted September 9, 2019 Have you considered 'membership_plan_feature(s)' or 'plan_feature(s)'? It certainly seems to me like the most descriptive table name. Entitlements could apply to either member or membership plan. Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569517 Share on other sites More sharing options...
SaranacLake Posted September 9, 2019 Author Share Posted September 9, 2019 32 minutes ago, maxxd said: Have you considered 'membership_plan_feature(s)' or 'plan_feature(s)'? It certainly seems to me like the most descriptive table name. Those would work, but I just have this new sense to use the word "entitlement"... 🙂 32 minutes ago, maxxd said: Entitlements could apply to either member or membership plan. If I had to split hair, I would say that "entitlements" apply more to features. As in, "Which system features or functions are you entitled to use?" (Being able to modify a post a week after the fact or seeing a member's IP address or banning a member are all "entitlements", i.e. privileges, of an Administrator.) A MEMBER has a SUBSCRIPTION to a MEMBERSHIP_PLAN By purchasing a "Premium Membership", that MEMBERSHIP_PLAN has ENTITLEMENTS to the following SITE_FEATURES (access to archives, access to premium content, ability to message others, etc). On one hand it is all semantics, yet I think "precision" in language is essential to any well-designed system. Quote Link to comment https://forums.phpfreaks.com/topic/309201-entitlement-table/#findComment-1569518 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.