Home > Ask the Data management / BI Experts > DBMS and data warehousing Questions & Answers > The difference between data definition language (DDL) and data manipulation language (DML)
Ask The Data Management Expert: Questions & Answers
EMAIL THIS

The difference between data definition language (DDL) and data manipulation language (DML)

Mark Whitehorn EXPERT RESPONSE FROM: Mark Whitehorn

Pose a Question
Other Data Management Categories
Meet all Data Management Experts
Become an Expert for this site


Tips, expert advice and sample chapters
Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us    Add to Google


>
QUESTION POSED ON: 28 April 2008
What's the difference between data definition language (DDL) and data manipulation language (DML)?

>
To answer our reader's question more thoroughly, Mark Whitehorn quotes a section of his book, Inside Relational Databases, in the following expert response.

"SQL stands for Structured Query Language, which is pronounced either as S Q L (as the three letters) or as Sequel. It appears that the former pronunciation is more common in the UK and the latter in the US -- but as the two are interchangeable, it shouldn't be a cause of anxiety.

SQL is a language that splits neatly into two parts. There is the data definition language (DDL) section and the data manipulation language (DML) section."

The DDL section is used for creating database objects, such as tables. In practice, people often use a GUI for creating tables and so on, so it is less common to hand-write DDL statements than it used to be. However an example looks like this:

CREATE TABLE Foo
(MajorPartNum LONG NOT NULL, MinorPartNum LONG NOT NULL,
Quantity LONG NOT NULL,
CONSTRAINT MajorMinor PRIMARY KEY
(MajorPartNum, MinorPartNum) );

The DML section is used to manipulate the data such as querying it. While is also common to use a query builder to create queries, people do still hand-craft DML statements, such as queries. An example might look like this:

SELECT Item, Amount, SaleNo
FROM SALES
WHERE Item = 'Sofa'
ORDER BY SaleNo;

  • Do you have questions about data definition language (DDL) and data manipulation language (DML)? Ask our expert!


  • Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us    Add to Google



    RELATED CONTENT
    DBMS and data warehousing
    Definition of primary, super, foreign and candidate key in the DBMS
    What is the difference between a logical and physical warehouse design?
    What are some emerging data warehouse and DBMS trends?
    How to get data/database independence with a three-tier architecture
    How to select an MPP database: DB2 vs. Teradata
    What comes first — the data mart or the data warehouse?
    What are the top database management systems (DBMS)?
    What is the role of DBMS in RDBMS?
    Is an Inmon-modeled BI system, like Madison, the future of data warehousing?
    What are the benefits and disadvantages of a RDBMS?

    Database management systems (DBMS) architecture and design
    Definition of primary, super, foreign and candidate key in the DBMS
    What is the difference between a logical and physical warehouse design?
    What are some emerging data warehouse and DBMS trends?
    Data Warehouse Platforms Product Directory
    Designing for performance: Strategic database application deployments
    An introduction to database transaction management
    Database access security: network authentication or data encryption?
    Executing SQL statements using prepared statements and statement pooling
    Static SQL vs. dynamic SQL for database application performance
    How to get data/database independence with a three-tier architecture

    RELATED GLOSSARY TERMS
    Terms from Whatis.com − the technology online dictionary
    data classification  (SearchDataManagement.com)
    OLAP  (SearchDataManagement.com)

    RELATED RESOURCES
    2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
    Search Bitpipe.com for the latest white papers and business webcasts
    Whatis.com, the online computer dictionary



    Search and Browse the Expert Answer Center
    Search and browse more than 25,000 question and answer pairs from more than 250 TechTarget industry experts.
    Browse our Expert Advice

    About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
    SEARCH 
    TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

    TechTarget Corporate Web Site  |  Media Kits  |  Site Map




    All Rights Reserved, Copyright 2005 - 2009, TechTarget | Read our Privacy Policy
      TechTarget - The IT Media ROI Experts