What is the difference between truncate and delete statement?

Answer Posted / balaji t

Identity counter can be reset in truncate whereas it is not possible in delete.Truncate dont activate trigger whereas delete can be used in triggers.truncate is a DDL command whereas delete is a DML command.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain try...catch with sql server?

757


What is default constraint in ms sql server?

712


Can sql server be linked with other servers like oracle?

700


How global temporary tables are represented and its scope?

716


How can you fetch alternate records from a table?

708






What do you understand by user-defined function in the sql server and explain the steps to create and execute a user-defined function in the sql server?

691


What is the difference between count () and rowcount ()?

696


Explain Reporting Life Cycle?

102


what purpose does the model database serve? : Sql server database administration

670


What are the essential components of sql server service broker?

756


can a database be shrunk with users active? : Sql server administration

755


How does stuff differ from the replace function?

738


Can we use max in where clause?

693


What is the use of @@spid?

737


How do I perform an unattended install of sql server 2000?

755