Database Design--e-r Diagram

Source: Internet
Author: User


One, review the foundation

1, weak entities

This entity needs to rely on another entity, and if another entity does not exist, it disappears. In contrast, the entity it relies on becomes a strong entity.





2, Specialization

In the process of database design, we will find that an entity can be divided into several sub-entities according to some characteristics, which is actually from the general to a special process, is a specialization.



Two, two RMB contact: ER an algorithm for converting graphs into relational patterns

1 , if the relationship between entities is 1:1 , the key of the other relationship pattern is added to the attributes of any one of the two relational patterns in the two entity type conversion The properties of the contact type.

2 , if the entity key contact is 1 : N , then in N the end entity type is converted into a relational model that joins 1 The properties of the key and contact type of the end entity type.

3 , if the relationship between entities is m:n , the contact type is also converted to a relational pattern whose properties are the two-segment entity type's key plus the property of the contact type, and the key is a combination of the two entity keys.



That is, there is only a single table in many-to-many relationships, and in other cases there are several entities that convert to several tables, and when you add a primary key to another entity in one entity, consider why you are adding to the N-side. Individuals think that the database has been done for a long time, it will be understood that the N-side join can be clearer to make the database changes to become easier.


This does not give examples, too familiar, or more practice, do a few database to understand.






Database Design--e-r Diagram

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.