ER diagram.

  • Hello.

    I'm a newbie in SQL and everything thats related to it.

    My homework is to create a database. There is some information given about it, but rest of it i have to figure out by my salf.

    So my idea was to create an ER model first of all. And then, based on it id make the database in MS SQL 2008 and do the rest of the task.

    I'm finding it very difficult to create the ER model.

    So, heres the task:

    Computer center has information about registered organizations, used computer resources, about resources demand. Registered organizations are demanding to use computer resources and after that they use computer resources.

    Create a database.

    Need to provide information about registered organizations, used computer resources, demands on computer resources. Need to provide information about computer resources (Who, when, what kind of resources has used, how many resources which organization has used.)

    And this is how far ive got.

    http://prntscr.com/7cesny

    The problem is, there has to be 4 entitys. For now, i have just 3. I can't think of what might be the 4th one...

    Anyways, basicly my idea was:

    In the first relation One organization can demand many resources, and also one resource can be demanded by many organizations. And in secound relation i tought that One resource can be demanded by many organizations, but one resource can only be used by one organization.

    So, basicly, i need some ideas like, what elements should that demand entity have and what could be the 4th entity.

  • Quick suggestion

    😎

    Start by modelling it on a high level and then work your way with simple statements such as "One or more organization use resources from one or more Computer Centre".

    +--------------+ +-------+ +-----------------+

    | Organization |-+-----0-<| Usage |>-o-----+-| Computer Centre |

    +--------------+ +-------+ +-----------------+

    Then add statements that describe the relationships and the relevant properties, ie "A Computer Center does not share any resources" and add to the model

    +--------------+ +-------+ +-----------------+ +----------+

    | Organization |-+-----0-<| Usage |>-o-----+-| Computer Centre |-+---0-<| Resource |

    +--------------+ +-------+ +-----------------+ +----------+

    When you are comfortable that you've got the entities and they'r relationships right, you can start to drill further down in details by adding the attributes.

  • Ok, thanks, this makes it easier to understand it.

    So basicly, as the Data center is the one who holds this database, theres just one computer center to get the resources from. So basicly, the database holds information about

    1.Organizations,

    2. computer Resources,

    3. Demand on computer resources(Altho i think demand might be a relation ship between organizations and computer resources),

    4. computer resources Usage?

    "Computer center has information about registered organizations, used computer resources, and information about resources demand. Registered organizations are demanding to use computer resources and after that they use computer resources. "

    So:

    "Organizations demand computer resources from a computer center, which is just one"

    [Organizations] ----- < demands> ------[Demand]

    So then, after Organizations have demanded the resources, they use the resources.

    [Organizations]-------<demands>-------[Demand]-------<Use>-------[Resources]

    And finaly, there has to be some information about the Usage of resources. It might be in the Use relation, or it might be another entity. Not sure about this one.

    Egh while drawing the diagram, Usage more like seems an relation between Oganizations and Resources, like "Which organization What resources and when has used" So it means, its just a relation between Organization and Resources.

    [Organizations]------<demands>-----[Demand]-----<Use>-----[Resources]

    | |

    | |

    |-------------------------------<Usage>------------------------------|

    Took me a while to think of this, but the problem is im still missing the 4th entity. And im not 100% sure if the diagram that i just draw is correct or not.

  • Just came up with a new idea, but i dont know how to make a diagram for it.

    So, Organizations demand resources:

    [Organization]-----<demand>------[Resoruces]

    Resources has attributes like ResourceID, ResourcePrice, ResourceName.

    So at this point i have two entitys. I need two more. so my idea was that Resources would divide into two parts, Servers and Computers, like two separate entitys.

    http://prntscr.com/7cq8uk

    But i have no idea what kind of relation would it be.

    So heres my Idea of how that ER model should look. Not sure if its correct or not. Its just draft or something. Anyways, like this i am reaching four entitys. But, is my ER model correct? And is it even possible to do something like that?

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply