SlideShare ist ein Scribd-Unternehmen logo
1 von 8
1 Using ORACLE® Data Manipulation Language (Populating our sample database)   and Transaction Control Language
2 DATA DEFINATION LANGUAGE DML is used for manipulation the data contained in a table. Just as how DDL commands can be used to CREATE,ALTER and DROP objects DML can be used to INSERT , UPDATE and DELETE data from the objects.DML commands only affect the data and not the structure of the table. DML contains 3 commands: INSERT 	: Used to insert a new record into the table. UPDATE	: Used to update the records already inserted into the table. DELETE 	: Used to delete records already inserted into the table.
3 INSERT COMAND The INSERT command is used to insert records into the table. The basic syntax of the INSERT command is : INSERT INTO TABLE_NAME(colm1_name,…[colmn_name])       VALUES ( colm1_val,…[colmn_val]); EXAMPLE :  INSERT INTO InfoTable(name,age,phone) VALUES (‘steve’,50,9988776655); The above syntax is used when we only want to insert specified column values.If we are inserting a row containing all the columns value or intend to insert NULL values in remaining columns we can discard the column list after table name as: INSERT INTO TABLE_NAME VALUES(value…[value]..[NULL]); The NULL keyword is used to insert a null values into the column.
4 UPDATE COMAND The UPDATE command is used to modify the records that have been already inserted into the table. We use a WHERE clause to target a particular set of columns to be updated in absence of which all rows in the table will be updated. SYNTAX: UPDATE  TABLE_NAME SET	 column = new_value,….	We can update multiple columns at a time.              …..[column = new value] WHERE    	 [condition ….];		WHERE condition limits the rows being updated. EXAMPLE : UPDATE InfoTable  SET	age = 40 , 	phone = 9988000000 WHERE 	name = ‘steve’;
5 UPDATE USING SUBQUERIES We can update the value of a row to be set to values of another row using subqueries : SYNTAX: UPDATE TABLE_NAME SET 	column = [subquery]…             …..column = value WHERE 	(condition); EXAMPLE : UPDATE InfoTable SET 	phone= (SELECT phone FROM InfoTable  WHERE name = ‘bill’) WHERE	age = 40;
6 DELETE COMAND The DELECT command can be used to delete a set of records that are inserted in a column. A WHERE clause is used to narrow the set of rows to be deleted in absence of which all the rows in the table will be deleted. To delete all rows we can also use the TRUNCATE command. SYNTAX: DELETE  [FROM] TABLE_NAME WHERE (condition..); EXAMPLE: DELETE FROM InfoTable WHERE name = ‘bill’; DELETE FROM InfoTable;Entire table contents deleted
7 TRANSACTION CONTROL LANGUAGE A TRANSACTION is a set of DML statements that cause a consistent change on data or it can be a single DDL / DCL command . The transaction begins when a DML command is entered and ends when COMMIT or ROLLBACK occurs. Since DCL and DDL commands are committed as soon as been entered only 1 such command is in a transaction. TCL statements are used to control transactions. There are three TL commands:
THANK YOU 8 THANK YOU FOR VIEWING THIS PRESENTATION FOR MORE PRESENTATIONS AND VIDEOS ON ORACLE AND DATAMINING , please visit:   www.dataminingtools.net

Weitere ähnliche Inhalte

Was ist angesagt?

DDL,DML,SQL Functions and Joins
DDL,DML,SQL Functions and JoinsDDL,DML,SQL Functions and Joins
DDL,DML,SQL Functions and Joins
Ashwin Dinoriya
 
Creating database using sql commands
Creating database using sql commandsCreating database using sql commands
Creating database using sql commands
Belle Wx
 
Sql delete, truncate, drop statements
Sql delete, truncate, drop statementsSql delete, truncate, drop statements
Sql delete, truncate, drop statements
Vivek Singh
 

Was ist angesagt? (19)

DML, DDL, DCL ,DRL/DQL and TCL Statements in SQL with Examples
DML, DDL, DCL ,DRL/DQL and TCL Statements in SQL with ExamplesDML, DDL, DCL ,DRL/DQL and TCL Statements in SQL with Examples
DML, DDL, DCL ,DRL/DQL and TCL Statements in SQL with Examples
 
8. sql
8. sql8. sql
8. sql
 
SQL Tutorial - How To Create, Drop, and Truncate Table
SQL Tutorial - How To Create, Drop, and Truncate TableSQL Tutorial - How To Create, Drop, and Truncate Table
SQL Tutorial - How To Create, Drop, and Truncate Table
 
Sql commands
Sql commandsSql commands
Sql commands
 
Ddl commands
Ddl commandsDdl commands
Ddl commands
 
DDL,DML,SQL Functions and Joins
DDL,DML,SQL Functions and JoinsDDL,DML,SQL Functions and Joins
DDL,DML,SQL Functions and Joins
 
Creating database using sql commands
Creating database using sql commandsCreating database using sql commands
Creating database using sql commands
 
Oracle Database DML DDL and TCL
Oracle Database DML DDL and TCL Oracle Database DML DDL and TCL
Oracle Database DML DDL and TCL
 
SQL DDL
SQL DDLSQL DDL
SQL DDL
 
Sql delete, truncate, drop statements
Sql delete, truncate, drop statementsSql delete, truncate, drop statements
Sql delete, truncate, drop statements
 
Oracle SQL DML Statements
Oracle SQL DML StatementsOracle SQL DML Statements
Oracle SQL DML Statements
 
Database Management - Lecture 2 - SQL select, insert, update and delete
Database Management - Lecture 2 - SQL select, insert, update and deleteDatabase Management - Lecture 2 - SQL select, insert, update and delete
Database Management - Lecture 2 - SQL select, insert, update and delete
 
Sql DML
Sql DMLSql DML
Sql DML
 
SQL - DML and DDL Commands
SQL - DML and DDL CommandsSQL - DML and DDL Commands
SQL - DML and DDL Commands
 
SQL-Alter Table, SELECT DISTINCT & WHERE
SQL-Alter Table, SELECT DISTINCT & WHERESQL-Alter Table, SELECT DISTINCT & WHERE
SQL-Alter Table, SELECT DISTINCT & WHERE
 
Database Systems - SQL - DDL Statements (Chapter 3/2)
Database Systems - SQL - DDL Statements (Chapter 3/2)Database Systems - SQL - DDL Statements (Chapter 3/2)
Database Systems - SQL - DDL Statements (Chapter 3/2)
 
Les10 Creating And Managing Tables
Les10 Creating And Managing TablesLes10 Creating And Managing Tables
Les10 Creating And Managing Tables
 
Les11 Including Constraints
Les11 Including ConstraintsLes11 Including Constraints
Les11 Including Constraints
 
SQL Views
SQL ViewsSQL Views
SQL Views
 

Ähnlich wie Oracle : DML

ii bcom dbms SQL Commands.docx
ii bcom dbms SQL Commands.docxii bcom dbms SQL Commands.docx
ii bcom dbms SQL Commands.docx
lakshmi77
 

Ähnlich wie Oracle : DML (20)

Commands
CommandsCommands
Commands
 
Oracle naveen Sql
Oracle naveen   SqlOracle naveen   Sql
Oracle naveen Sql
 
Oracle naveen Sql
Oracle naveen   SqlOracle naveen   Sql
Oracle naveen Sql
 
SQL
SQLSQL
SQL
 
ii bcom dbms SQL Commands.docx
ii bcom dbms SQL Commands.docxii bcom dbms SQL Commands.docx
ii bcom dbms SQL Commands.docx
 
introdution to SQL and SQL functions
introdution to SQL and SQL functionsintrodution to SQL and SQL functions
introdution to SQL and SQL functions
 
SQL Tutorial for Beginners
SQL Tutorial for BeginnersSQL Tutorial for Beginners
SQL Tutorial for Beginners
 
My SQL.pptx
My SQL.pptxMy SQL.pptx
My SQL.pptx
 
Sql smart reference_by_prasad
Sql smart reference_by_prasadSql smart reference_by_prasad
Sql smart reference_by_prasad
 
Sql smart reference_by_prasad
Sql smart reference_by_prasadSql smart reference_by_prasad
Sql smart reference_by_prasad
 
DBMS.pdf
DBMS.pdfDBMS.pdf
DBMS.pdf
 
Oracle SQL AND PL/SQL
Oracle SQL AND PL/SQLOracle SQL AND PL/SQL
Oracle SQL AND PL/SQL
 
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
Unit-1 SQL fundamentals.docx SQL commands used to create table, insert values...
 
Msql query
Msql queryMsql query
Msql query
 
Oracle sql material
Oracle sql materialOracle sql material
Oracle sql material
 
Sql
SqlSql
Sql
 
Oracle: Commands
Oracle: CommandsOracle: Commands
Oracle: Commands
 
1670595076250.pdf
1670595076250.pdf1670595076250.pdf
1670595076250.pdf
 
Cheat sheet SQL commands with examples and easy understanding
Cheat sheet SQL commands with examples and easy understandingCheat sheet SQL commands with examples and easy understanding
Cheat sheet SQL commands with examples and easy understanding
 
SQL 🌟🌟🔥.pdf
SQL 🌟🌟🔥.pdfSQL 🌟🌟🔥.pdf
SQL 🌟🌟🔥.pdf
 

Mehr von oracle content (12)

Oracle: Procedures
Oracle: ProceduresOracle: Procedures
Oracle: Procedures
 
Oracle: PLSQL Introduction
Oracle: PLSQL IntroductionOracle: PLSQL Introduction
Oracle: PLSQL Introduction
 
Oracle: Programs
Oracle: ProgramsOracle: Programs
Oracle: Programs
 
Oracle: Joins
Oracle: JoinsOracle: Joins
Oracle: Joins
 
Oracle:Cursors
Oracle:CursorsOracle:Cursors
Oracle:Cursors
 
Oracle: Control Structures
Oracle:  Control StructuresOracle:  Control Structures
Oracle: Control Structures
 
Oracle: Dw Design
Oracle: Dw DesignOracle: Dw Design
Oracle: Dw Design
 
Oracle: Basic SQL
Oracle: Basic SQLOracle: Basic SQL
Oracle: Basic SQL
 
Oracle Warehouse
Oracle WarehouseOracle Warehouse
Oracle Warehouse
 
Oracle: Functions
Oracle: FunctionsOracle: Functions
Oracle: Functions
 
Oracle: New Plsql
Oracle: New PlsqlOracle: New Plsql
Oracle: New Plsql
 
Oracle: Fundamental Of Dw
Oracle: Fundamental Of DwOracle: Fundamental Of Dw
Oracle: Fundamental Of Dw
 

Kürzlich hochgeladen

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Kürzlich hochgeladen (20)

AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 

Oracle : DML

  • 1. 1 Using ORACLE® Data Manipulation Language (Populating our sample database) and Transaction Control Language
  • 2. 2 DATA DEFINATION LANGUAGE DML is used for manipulation the data contained in a table. Just as how DDL commands can be used to CREATE,ALTER and DROP objects DML can be used to INSERT , UPDATE and DELETE data from the objects.DML commands only affect the data and not the structure of the table. DML contains 3 commands: INSERT : Used to insert a new record into the table. UPDATE : Used to update the records already inserted into the table. DELETE : Used to delete records already inserted into the table.
  • 3. 3 INSERT COMAND The INSERT command is used to insert records into the table. The basic syntax of the INSERT command is : INSERT INTO TABLE_NAME(colm1_name,…[colmn_name]) VALUES ( colm1_val,…[colmn_val]); EXAMPLE : INSERT INTO InfoTable(name,age,phone) VALUES (‘steve’,50,9988776655); The above syntax is used when we only want to insert specified column values.If we are inserting a row containing all the columns value or intend to insert NULL values in remaining columns we can discard the column list after table name as: INSERT INTO TABLE_NAME VALUES(value…[value]..[NULL]); The NULL keyword is used to insert a null values into the column.
  • 4. 4 UPDATE COMAND The UPDATE command is used to modify the records that have been already inserted into the table. We use a WHERE clause to target a particular set of columns to be updated in absence of which all rows in the table will be updated. SYNTAX: UPDATE TABLE_NAME SET column = new_value,…. We can update multiple columns at a time. …..[column = new value] WHERE [condition ….]; WHERE condition limits the rows being updated. EXAMPLE : UPDATE InfoTable SET age = 40 , phone = 9988000000 WHERE name = ‘steve’;
  • 5. 5 UPDATE USING SUBQUERIES We can update the value of a row to be set to values of another row using subqueries : SYNTAX: UPDATE TABLE_NAME SET column = [subquery]… …..column = value WHERE (condition); EXAMPLE : UPDATE InfoTable SET phone= (SELECT phone FROM InfoTable WHERE name = ‘bill’) WHERE age = 40;
  • 6. 6 DELETE COMAND The DELECT command can be used to delete a set of records that are inserted in a column. A WHERE clause is used to narrow the set of rows to be deleted in absence of which all the rows in the table will be deleted. To delete all rows we can also use the TRUNCATE command. SYNTAX: DELETE [FROM] TABLE_NAME WHERE (condition..); EXAMPLE: DELETE FROM InfoTable WHERE name = ‘bill’; DELETE FROM InfoTable;Entire table contents deleted
  • 7. 7 TRANSACTION CONTROL LANGUAGE A TRANSACTION is a set of DML statements that cause a consistent change on data or it can be a single DDL / DCL command . The transaction begins when a DML command is entered and ends when COMMIT or ROLLBACK occurs. Since DCL and DDL commands are committed as soon as been entered only 1 such command is in a transaction. TCL statements are used to control transactions. There are three TL commands:
  • 8. THANK YOU 8 THANK YOU FOR VIEWING THIS PRESENTATION FOR MORE PRESENTATIONS AND VIDEOS ON ORACLE AND DATAMINING , please visit: www.dataminingtools.net