The database language responsible for query operations in the database management system is the "data manipulation language". Data manipulation language is a programming statement used for database operations (query, add, modify and delete) and access to objects and data in the database; the main function of data manipulation language is to access data, so its syntax is based on reading Mainly fetching and writing to the database.
The operating environment of this tutorial: Windows 7 system, Dell G3 computer.
The database language responsible for query operations in the database management system is "data manipulation language".
Structured Query Language (SQL), referred to as SQL, is a special-purpose programming language. It is a database query and programming language used to access data and query, update and Manage relational database systems.
Structured query language consists of 6 parts:
1. Data Query Language (DQL: Data Query Language): Its statements are also called "data retrieval statements" ” is used to obtain data from a table and determine how the data is presented in the application. The reserved word SELECT is the most commonly used verb in DQL (and all SQL). Other commonly used reserved words in DQL include WHERE, ORDER BY, GROUP BY and HAVING. These DQL reserved words are often used with other types of SQL statements.
2, Data Manipulation Language (DML: Data Manipulation Language): Its statements include the verbs SELECT, INSERT, UPDATE and DELETE. They are used for query, add, modify and delete respectively.
3. Transaction Control Language (TCL): Its statements can ensure that all rows of the table affected by the DML statement are updated in a timely manner. Including COMMIT (submit) command, SAVEPOINT (save point) command, ROLLBACK (rollback) command.
4. Data Control Language (DCL): Its statements implement permission control through GRANT or REVOKE to determine the access of individual users and user groups to database objects. Some RDBMS can use GRANT or REVOKE to control access to individual columns of a table.
5. Data Definition Language (DDL): Its statements include the verbs CREATE, ALTER and DROP. Create new tables or modify or delete tables in the database (CREATE TABLE or DROP TABLE); add indexes to tables, etc.
6. Pointer Control Language (CCL): Its statements, such as DECLARE CURSOR, FETCH INTO and UPDATE WHERE CURRENT, are used to operate on individual rows of one or more tables.
Data Manipulation Language (DML)
Data Manipulation Language (DML) is used for database operations. Programming statements for accessing objects and data are usually a subset of database-specific programming languages. For example, in the SQL language, which is a common standard in the information software industry, three instructions: INSERT, UPDATE, and DELETE are the core, representing inserts respectively. (meaning new or created), updated (modified) and deleted (destroyed).
In the system development process using a database, the application program will inevitably use instructions; and coupled with the SELECT statement of SQL, developers in Europe and the United States regard these four instructions as "CRUD" (respectively Create, Read, Update, Delete are referred to as four-letter abbreviations in English); while developers in Asia who use Chinese may refer to them with four Chinese characters: add, check, modify, and delete.
Grammar structure
The main function of DML is to access data, so its syntax is mainly based on reading and writing to the database. Except for INSERT, other instructions It may be necessary to use a WHERE instruction to filter the data range, or to access all data without a WHERE instruction.
SELECT
Main article: SELECT
SELECT is an instruction in SQL Data Manipulation Language (DML) used to query field data in a table. Use conditional clauses (such as where) or ordering clauses (such as order) to obtain query results.
INSERT
Main entry: INSERT
INSERT is an instruction to insert data into a database object. The database objects that can insert data include data tables. There are two types of updateable view tables.
UPDATE
Main entry: UPDATE
The UPDATE command updates the data in the data table matching the conditions to new ones based on the given conditions. numerical value.
DELETE
Main entry: DELETE
The DELETE instruction is an instruction to delete data from a database object.
For more related knowledge, please visit the FAQ column!
The above is the detailed content of What is the database language responsible for query operations in a database management system?. For more information, please follow other related articles on the PHP Chinese website!