Oracle SQL

Pataasin ang iyong marka sa homework at exams ngayon gamit ang Quizwiz!

What are DDL statements used for?

> Create, alter, and drop tables and other database objects > Add comments on a particular object to be stored in the database and associated with that object > Issue privileges to users to perform various tasks in the database > Initiate performance analysis on objects using built-in tools

CREATE ALTER (1) DROP RENAME TRUNCATE GRANT REVOKE FLASHBACK PURGE COMMENT

DDL Data Definition Language List 10 commands

COMMENT

DDL command Adds comments to the data dictionary for an existing database object.

RENAME

DDL command Changes the name of an existing database object.

PURGE

DDL command Irrevocably removes database objects from the recycle bin.

GRANT

DDL command Provides privileges, or rights, to user objects to enable them to perform various tasks in the database.

TRUNCATE

DDL command Removes all the rows—in other words, data—from an existing table in the database. TRUNCATE is something of a brute-force alternative to the DELETE statement, in that TRUNCATE gives up recovery options offered by DELETE in exchange for faster performance. These differences in approach are the reason TRUNCATE is categorized as DDL while DELETE is DML.

REVOKE

DDL command Removes privileges that have been issued with the GRANT statement.

FLASHBACK

DDL command Restores an earlier version of a table or database.

ALTER

DDL command Used on an existing object in the database to modify that object's structure, name, or some other attribute. (Two exceptions are the uses of ALTER with the reserved words SESSION and SYSTEM. ALTER SESSION and ALTER SYSTEM are not technically considered DDL statements but fall under a different category. Neither is included on this exam.)

CREATE

DDL command Used to create a user, table, view, index, synonym, or other object in the database.

DROP

DDL command Used to remove a database object from the database that has already been created with the CREATE statement.

SELECT INSERT UPDATE DELETE MERGE

DML Data Manipulation Language List 5 commands

What is DDL, what is it used for?

Data Definition Language consists of those SQL statements that are used to build database objects.

COMMIT ROLLBACK SAVEPOINT

TCL Transaction Control Language List 3 commands


Kaugnay na mga set ng pag-aaral

Anatomy Lecture Exam 1 Indiana University

View Set

Strategic management - Value chain

View Set

The Cardiovascular System: Blood

View Set

Epidermis layers and Skin (Thick & Thin)

View Set