SQL query Beginner's Guide reading notes (i) relational database and SQL introduction

Source: Internet
Author: User

Part i:relational Databases and SQL


Chapter2, ensuring Your Database Structureis sound.

Database Design Guidelines

What is a relational database

RDBMS (A relational database management systems) relational database

Tables

Tables is the mainstructures in the database. Each table always represents a

Single, Specificsubject.

Fields

A field is thesmallest structure in the database, and it represents a characteristic

of the subject ofthe table to which it belongs.

Records

A record Representsa unique instance of the subject of a table.

Keys

Keysare Special fields that play very specific roles within a table. eg.

    • Primary key
    • FOREIGN key

The primary key role is to ensure the uniqueness of the data record, that is, the primary key constraints to ensure that all data records in a database table are different individuals, for example: The ID number can guarantee a person in the mainland is a separate individual (not counted), That is, an identity card number can not identify two persons or two identification number identification of a person. So the primary key is analyzed from the existing data, not the designer arbitrarily added.

Relationships

    • One-to-one
    • One-to-many
    • Many-to-many

SQL query Beginner's Guide reading notes (i) relational database and SQL introduction

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.