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

Will count(column) include columns with null values in its count?

671


What is sql server replication? : sql server replication

540


Can a rule be bound to any column of any data type?

573


How to bind a view to the schema of the underlying tables?

589


what protocol both networks use? : Sql server database administration

542






Is there any performance difference between if exists (select null from table) and if exists (select 1 from table)?

529


Can you explain full-text query in sql server?

552


What is single-user mode and what are the steps you should follow to start sql server in single-user mode?

557


Can we call future method from queueable?

597


What is a result set object returned by odbc_exec()?

554


What is a synonym for manipulation?

552


How do I determine how many instances of sql server are installed on a computer?

537


what is the main function of a query parameter?

111


How much memory that we are using in Logshipping Concept?

1368


What stored by the master?

547