What are the difference between DDL and DML?

Started by Black Ninja, January 15, 2013, 06:48:53 AM

Black Ninja

What are the difference between DDL and DML? And why and where should we use these term in SQL?

virgil

Data Definition Language (DDL) is a computer language used to define the data structures in the table. It primarily uses the CREATE command in SQL, while Data Manipulation Language (DML) is a computer language used to manipulate the data in database. It includes various modified statements in the database.

icecube media

Data Definition Language are used to to define the structure and schema. It includes commands like: Create,Alter,Drop,Comment,Truncate,Rename.

Data Manipulation Language are used for managing data within the schema objects.It include command like: Select,Insert,Delete,Merge,Update,Call etc.