DCL Command DDL Commands DML Commands DQL Command SQL Commands TCL Command SQL Commands | DDL, DML, TCL, DCL, DQL SQL Commands: SQL Command SQL commands are guidelines, coded into SQL proclamations, which are utilized to speak with the database to perform explicit undertakings, work, capacities and inquiries with information. SQL commands can be utilized for looking through the database as well as to perform different capacities like, for instance, you can make tables, add information to tables, or alter information, drop the table, set consents for clients. SQL directions are assembled into four noteworthy classifications relying upon their usefulness: Information Definition Language (DDL) - These SQL commands are used for making, altering, and dropping the structure of database objects. The commands are CREATE, ALTER, DROP, RENAME, and TRUNCATE. See More >>> Information Manipulation Language (DML) - These SQL commands are used for putting away, recovering, changing, and erasing information. These Data Manipulation Language commands are: INSERT, UPDATE, and DELETE. See More >>> Exchange Control Language (TCL) - These SQL commands are used for overseeing changes influencing the information. These commands are COMMIT, ROLLBACK, and SAVEPOINT. See More >>> Information Control Language (DCL) - These SQL commands are used for giving security to database objects. These commands are GRANT and REVOKE. See More >>> Data Query Language (DQL) - This SQL command is used for retrieve value from database. This command is SELECT. See More >>> Recommended : Data Definition Language : Create Drop Alter Truncate Data Manipulation Language : Insert Update Delete Data Control Language : Grant Revoke Transaction Control Language : Commit Rollback Savepoint Data Query Language: Select April 29, 2019 No Comment
Delete DML Commands DELETE | Delete Command In SQL| SQL DELETE Statement | DML Command DELETE Command Delete command used to delete all or particular records of an existing table. Delete command is one types of DML command. Syntax : 1) DELETE FROM table_name WHERE condition ; 2) DELETE FROM table_name; Delete command in SQL has two types of parameter 1) table_name - This paramter specifies name of table. 2) condition - This parameter specifies to select the rows for which the values of columns needs to be updated. Example : // DELETE record from Customer01 using with WHERE clause 1) DELETE FROM Customer01 WHERE C_City = 'Rajkot'; //DELETE all records from Customer01 table 2) DELETE FROM Customer01; Above second example, may delete all records of Customer01 table. * * * * * * * * * * * * * * * In Easy Language Delete command used to delete records of an existing table. April 03, 2019 No Comment
DML Commands Update Update | Update SQL | SQL Update | DML Command UPDATE Command SQL Update command used to modify records in an existing table. UPDATE SQL command is on of types DML command. Syntax : UPDATE table_name SET column_name = values WHERE condition ; Update command in SQL, there are four types of parameters : 1) table_name - This parameter specifies the name of table. 2) column_name - This parameter specifies the name of column. 3) value - This parameter specifies the value of column. 4) condition - This parameter specifies to select the rows for which the values of columns needs to be updated. Example : // UPDATE C_State from Customer01 table UPDATE Customer01 SET C_State = 'M.P.' WHERE C_Id = 104; * * * * * * * * * * * * * * * In Easy Language Update command used to modify records of an existing table. April 03, 2019 1 Comment
DML Commands Insert Insert | Insert SQL | DML Command INSERT Command Insert command used to add new record in to existing table. Insert command is one types of DML command. INSERT INTO command is one of DML command. Insert INTO SQL Server statement can be write in two ways : Syntax : 1) INSERT INTO table_name (column1, column2,column3, . . .) VALUES (value1, value2, value3, . . . ); 2) INSERT INTO table_name VALUES (value1, value2, value3, . . .); In Insert INTO SQL Server Statement, there is three types of parameters 1) table_name - This parameter specifies the name of table. 2) column - This parameter specifies the name of column. 3) value - This parameter specifies the value of column. Example : // INSERT records in Customer01 table 1) INSERT INTO Customer01 (C_ID,C_Name,C_City,C_State) VALUES (101,'Shital','Ahmedabad','Gujarat'); // INSERT records in Customer01 table 2) INSERT INTO Customer01 VALUES (101,'Shital','Ahmedabad','Gujarat'); Note : Insert Command in SQL can be used two ways * * * * * * * * * * * * * * * * * In Easy Language Insert command used to add new record in a table. April 03, 2019 No Comment
DML Commands DML Commands | Data Manipulation Language | SQL Commands Data Manipulation Language In SQL, there are following types of DML commands. As below INSERT UPDATE DELETE These DML commands are used for data manipulation or add, modify and delete the content / data of a table. These DML commands are not auto-committed. It means changes made by DML command are not permanent to database, it can be rolled back. INSERT Command Insert command used to add new record to the table. Insert statement can be write in two ways. As below Syntax : 1) INSERT INTO table_name (column1, column2, column3, column4, . . . ) VALUES (value1, value2, value3,value4, . . .); 2) INSERT INTO table_name VALUES (value1, value2, value3,value4, . . . ); There is three types of parameters : 1) table_name - parameter specifies the name of table. 2) column - parameter specifies the name of column. 3) value - parameter specifies the value of column. Example : //INSERT records in Customer01 table INSERT INTO Customer01 (Cust_Id, Customer_Name, Select_Item,C_City) VALUES (101, 'Dalsaniya Rajal', ' Pursh' , 'Surendranagar' ); //INSERT records in Customer01 table INSERT INTO Customer01 VALUES (101, 'Dalsaniya Rajal', ' Pursh' , 'Surendranagar' ); UPDATE Command Update command used to modify records in an existing table. Update command used to update or modify particular rows. Syntax : UPDATE table_name SET column_name1 = value, column_name2 = value WHERE condition ; There are four types of parameters : 1) table_name - parameter specifies the name of table 2) column_name - parameter specifies the name of column. 3) value - parameter specifies the value, which we want to set. 4) condition - parameter specifies to select the rows for which the values of columns needs to be updated. Example : // UPDATE Customer01 table UPDATE Customer01 SET C_City = 'Surendranagar' , C_State = 'Gujarat' WHERE C_Name = 'Rajal' ; DELETE Command Delete command used to delete particular record in existing table. Syntax : DELETE FROM table_name WHERE condition ; There are types of parameters : 1) table_name - parameter specifies name of table. 2) condition - parameter specifies to select the rows for which the values of columns needs to be updated. Example : // DELETE record from Customer01 table DELETE FROM Customer01 WHERE C_City = 'Ahmedabad' ; * * * * * * * * * * * * * * * * * In Easy Language INSERT - This command used to add new record in existing table. UPDATE - This command used to update or modify record in existing table. DELETE - This command used to delete record of an existing table. Recommended : INSERT Command UPDATE Command DELETE Command April 03, 2019 No Comment