2 Day Developer > Using SQL > Overview of SQL
Overview of SQL |
Previous |
Next |
SQL is nonprocedural language for accessing a database. You run SQL statements commands to perform various tasks, such as retrieving data from tables in Oracle Database XE. The SQL language automatically handles how to navigate the database and perform the desired task. All database operations are performed using SQL statements.
With SQL statements you can perform the following:
Query, insert, and update data in tables
Format, perform calculations on, store, and print from query results
Examine table and object definitions
Oracle SQL statements are divided into several categories:
Data Manipulation Language (DML) statements
These statements query, insert, update, and delete data in tables.
Transaction Control statements
These statements commit or roll back the processing of transactions. A group of changes that you make is referred to as a transaction.
Data Definition Language (DDL) statements
These statements create, alter, and drop database objects.
A statement consists partially of SQL reserved words, which have special meaning in SQL and cannot be used for any other purpose. For example, SELECT
and UPDATE
are reserved words and cannot be used as table names. For a list of SQL reserved, see Reserved Words.
A SQL statement is an instruction. The statement must be the equivalent of a complete SQL sentence, for example:
SELECT last_name, department_id FROM employees;