What's the difference between DELETE TABLE and TRUNCATE
TABLE commands?
Answer Posted / ranjay
Truncate / When use Truncate after that insert new record
into the table row started from 1 but
Delete / When delete record in a table after that insert
new record row id started from after the deleted row
For e g, I m create a table Employee and insert 5 record
row number set identity true and increment by 1
After that, I m delete last record I e row number is 5
after delete I m insert new record in a table then row id
started from 6 not 5 but when truncate table row id start
from 1
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is use of attributehierarchyenabled? : sql server analysis services, ssas
What is a select query statement in ms sql server?
What are the advantages to use stored procedures?
what is the difference between a primary key and a unique key? : Sql server database administration
What is a sql join?
Can a cursor be updated? If yes, how you can protect which columns are updated?
To automatically record the time on which the data was modified in a table, which data type should you choose for the column?
What are the steps you can take to avoid “deadlocks”?
What is the difference between stored procedure and functions?
What are the types of dml?
What is wrong with sql server client libarary dll, ntwdblib.dll?
Can we insert data into view sql server?
what is the sql equivaent of the dataset relation object ?
What is fill factor and pad index?
What is a heap?