当前位置:网站首页>MySQL practice: 2 Table definition and SQL classification

MySQL practice: 2 Table definition and SQL classification

2022-06-26 08:03:00 Live Firestone

The definition of the table

Table is a structured file , Can be used to store specific types of data , Such as : Student information 、 Course information, etc , Can be put in the table , In addition, tables have specific names , B. it cannot be repeated . There are several concepts in the table : Column 、 That's ok 、 Primary key .

  1. Column ( Field )

Column , Usually do fields , Each field contains : Field name 、 Field data type 、 Field constraints 、 Field length ;

  1. That's ok ( Record )

That's ok , Usually do the records in the table . The data in the table is by row ( Record ) Stored , There can be 0 Multiple records of a ring ;

 Insert picture description here

SQL The classification of

  1. Database query language (DQL)

Represent keyword :select

  1. Database operation language (DML)

Represent keyword :insert、delete 、update Respectively represents increase 、 Delete 、 Change the data in the table

  1. Database definition language (DDL)

Represent keyword :create、drop、alter Each represents the creation of 、 Delete 、 Modify the structure of the table

  1. Transaction control language (TCL)

Represent keyword :commit、rollback

  1. Data control language (DCL)

Represent keyword :grant、revoke

Be careful :DML Is to modify the data in the database table , and DDL Is to modify the structure of the data table ;

原网站

版权声明
本文为[Live Firestone]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202170606258673.html