What is the difference between DELETE, TRUNCATE, and DROP?
Answer Posted / nashiinformaticssolutions
• DELETE:
o Deletes specific rows from a table.
o Can have a WHERE clause.
o DML command (can be rolled back).
• TRUNCATE:
o Deletes all rows from a table.
o Faster than DELETE (does not log individual row deletions).
o DDL command (cannot be rolled back).
• DROP:
o Removes a table entirely (schema + data).
o DDL command.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is data manipulation language?
What are the sql versions?
What is loop in pl sql?
What are three advantages to using sql?
What is primary and foreign key?
- Types of triggers - View - Dcl - Procedures, packages, functions - Metasolve - Can use Dcl in triggers - package case study - Cursor and its types - triggers schedule - Wrap - Why we are using fetch and for in cursor. difference?
How do I order by ascending in sql?
What are the uses of sysdate and user keywords?
What are the two types of exceptions.
How many types of relationship are there?
Can triggers stop a dml statement from executing on a table?
How do I truncate a sql log file?
Explain the purpose of %type and %rowtype data types with the example?
how to convert character strings to dates? : Sql dba
Explain about various levels of constraint.