If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > Calling All Database Design Guru

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-20-06, 19:31
philqqq philqqq is offline
Registered User
 
Join Date: Sep 2005
Posts: 3
Calling All Database Design Guru

Ok, not sure what is the right/best way to go about designing this. I need a database that allow a User (admin) to own many Company and a Company can have many Property. A User can also create multiple users (non admin) to help manage certain Company and/or Property. For example, "Company A" have "Property A", "Property B", and "Property C". The admin assigned the new user to manage "Company A", along with "Property A" and "Property B", but not "Property C". Another example might be, a new user can only manage Property A, B, or C, but not "Company A". I hope all you guru understand what I am trying to say. Thanks in advance.
Reply With Quote
  #2 (permalink)  
Old 04-21-06, 00:41
Pat Phelan Pat Phelan is offline
Resident Curmudgeon
 
Join Date: Feb 2004
Location: In front of the computer
Posts: 12,605
I'm not sure that I understand very well. Can you post a reference to the assignment, or at least scan it in for us?

-PatP
Reply With Quote
  #3 (permalink)  
Old 04-21-06, 13:44
philqqq philqqq is offline
Registered User
 
Join Date: Sep 2005
Posts: 3
More Info

Thanks for the quick reply Pat. This is just a little self learning project, so I don't really have any assignment references to go by. Lets give this one more try on my part.

1. The web application is built to keep track of commercial properties. A property is owned by a company. A company can have many property.

company--->property

2. One or more user can be created to manage one or more company.

user--->userCompany<---company

3. One or more user can be created to manage one or more property.

user--->userProperty<---property

Am I going in the right direction? Any advice would be great.

Thanks
Reply With Quote
  #4 (permalink)  
Old 04-21-06, 14:02
Pat Phelan Pat Phelan is offline
Resident Curmudgeon
 
Join Date: Feb 2004
Location: In front of the computer
Posts: 12,605
I'd create a total of six tables. Three tables for objects, one table for each of the kinds of objects you're tracking (users, companies, and properties). Three tables for relationships, one for company-owns-property, one for user-manages-property, and one for user-manages-company. I would probably want to include attributes in the relationship tables to show when each relationship starts and ends, since there are often problems when
I don't keep track of that!

-PatP
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On