Command in SQL Server?

Types of command in SQL Server?
https://sqlsensationforu.blogspot.com













1) Data Definition Language(DDL)

Data definition statements are used to define the database structure or table.

(i)CREATE :- Create new database/table
(ii)ALTER :- Modifies the structure of database / table.
(iii)DROP:- Deletes a database / table.
(iv) TRUNCATE:- Remove all the records from the table.
(v)RENAME:-Rename the database/table.

2) Data Manipulating Language(DML)

Data manipulating statements are used for managing data within the table.

(i)SELECT:- Retrieve data from a table.
(ii)INSERT: -Insert data into table.
(iii)UPDATE:-Update/Modify existing records in a table.
(iv)DELETE:- Delete the records from the table.

3)Data Control Language.


(i)GRANT:- Giver user access privileges database.
(ii)REVOKE: -Withdraw user access privileges given by using the GRANT command.


4)Transaction Control Language(TCL)

TCL commands deal with the transaction within the database.

(i)COMMIT: -commits a transaction.
(ii)ROLLBACK:-rollbacks a transaction in case of any error occurs.
(iii)SAVE-POINT:- sets a savepoint within a transaction.
(iv)SET TRANSACTION:- specify characteristics for the transaction.

5)Data Query Language

(i)SELECT:- It is used to retrieve data from the database.



Image Source: Google