Can you tell me the difference between DELETE & TRUNCATE
commands?

Answer Posted / rahul goel

There are many differences. Some of these are as follows:
1. Delete can be rollback but Turncate can not be rollback.
2. Delete is a DML command and Turncate is a DDL command.
3. Delete command is used for deleting one or more row from
the table whereas Turncate command is used for deleting all
rows from the table.
4. Turncate is fact as compared to delete command.
5. we can use where clause with Delete but where is not
possible with Turncate.

Is This Answer Correct ?    8 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is difference between materialized view and view?

597


Explain about SQLOS?

657


Does group by or order by come first?

621


How each E-R model constructs can be mapped to the relational model?

635


What is a DBMS, query, SQL?

654






What is wide table?

620


Can a database be shrunk with users active?

697


How many replicas are maintained for each SQL Azure database?

134


What is the use of toad or sqldbx.?

813


Your sql server is running out of disk space. You notice that there are several large files with ldf extensions what are these files?

703


Explain the microsoft sql server delete command? : SQL Server Architecture

683


How can we delete Duplicate row in table?

714


Difference between Inner vs outer joins?

607


What language is sql server written in?

615


What is normalization of database? What are its benefits?

589