Answer Posted / wasimali
1) Delete command maintained the log files in each deleted row but truncate command do not maintained the log files for each deleted row but maintain the record for DE-allocation
of data-pages in the log files
2)Delete is a DML command and truncate is a DDL command.
3)Trigger is fired in case of delete command only but they are not fired when truncate command is used.
4)you can used where clause in case of delete command use to delete a particular row,
but you can not use where clause in case of truncate command use to delete a data from rows.
5) Truncate command reset the identity property to its initial values whereas delete command can not reset its identity property of its column.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
can a table be moved to different filegroup? : Sql server administration
How each E-R model constructs can be mapped to the relational model?
When is update_statistics command used?
What command do we use to rename a db, a table and a column?
Explain throw statement in sql server 2008?
How to access the inserted record of an event?
How many clustered indexes can be created on a table? I create a separate index on each column of a table. what are the advantages and disadvantages of this approach?
What is the difference between stored procedure and functions?
Explain syntax for viewing, dropping and disabling triggers?
Explain about builtinadministrator?
How to add a new column to an existing table with "alter table ... Add" in ms sql server?
If a table does not have a unique index, can a cursor be opened on it?
Suppose i have a table that contains 5 columns like col1,col2...colm5.I want to import only two column through BCP utility.How to do same through BCP in sybase.
Find columns used in stored procedure?
How can you transfer data from a text file to a database table? Or how can you export data from a table to a comma delimited (csv) file? Or how can you import data from ms access to a table in a database? Or how can you export data from a table to an excel file?