DQL, DML, DDL, DCL, respectively, what is?

SQL language is divided into four categories: data query language DQL, data manipulation language DML, data definition language DDL, Data Control Language DCL.

  1. Data query language DQL DQL data query language query block is the basic structure of the SELECT clause, FROM clause, WHERE clause consisting of:

    SELECT <Field watches> FROM <table or view name> WHERE <query>

     

  2. Data Manipulation Language DML Data Manipulation Language DML There are three main forms:

    1) Insert: INSERT

    2) Update: UPDATE

    3) Delete: the DELETE data (table is deleted without deleting the table structure, can be rolled back)

     

  3. Data Definition Language DDL

     

    CREATE: create

    ALTER: modify the table structure

    RENAME: Modify the table or column name

    DROP: When you delete the table structure and data, delete can not be rolled back

    TRUNCATE: delete data in the table without deleting the table structure, it can not be rolled back after deletion efficient than DELETE

     

  4. Data Control Language DCL

    1) GRANT: Authorization

    2) REVOKE: Recycling authority

     

There are transaction control statements TCL:

SAVEPOINT: savepoint

ROLLBACK: fall back to a point

COMMIT: commit the transaction

Guess you like

Origin www.cnblogs.com/gu-bin/p/10961738.html