Redirecting to

  Prev   Next
SQL: SQL Stands for Structured Query Language. SQL is database query language which is used to create, manage and retrieve the relational database. Relational Database: in relational database, data is stored as well as retrieved in the form of relations (table). Terminologies used in Relation: 1. Relation: table. 2. Attribute: field or column that define a relation. 3. Tuple: record or row. 4. Degree: number of attributes in a relation. 5. Cardinality: number of tuples. With the help of SQL, we can perform various operations: 1. Create new database. 2. Create new relations (tables) in a database. 3. Create stored procedures in a database. 4. Create views in a database. 5. Retrieve data from database. 6. Insert, Update, delete operations on data in a database. 7. Set permissions on relations(tables), stored procedures, views. Note: SQL keywords are not case sensitive. Some database requires a semicolon at the end of each SQL statement. Semicolon is used to separate each SQL statement in database so that multiple SQL statements can execute on same call (one click) to the server. Sql categories: 1. DDL (Data Definition Language). 2. DML (Data Manipulation Language). 3. DQL (Data Query Language). 4. DCL (Data Control Language). 5. TCL (Transaction Control Language). 1. DDL DDL stands for Data Definition Language. DDL is used to define the structure of the database. e.g. ddl_query 2. DML DML stands for Data Manipulation Language. It is used to manipulate data in the table. e.g. dml_query 3. DQL DQL stands for Data Query Language. It is used to retrieve the data from the relation. e.g. dql_query 4. DCL DCL stands for Data Control Language. It is used for authority purpose. e.g. dcl_query 5. TCL TCL stands for Transaction Control Language. These types of commands mainly used in transactions and concurrency control. e.g. tcl_query SQL Categories in detail: sql-ddl-dml-tcl-dcl
Id Name