what is the difference between TRUNCATE and DELETE command
in SQL
Answer Posted / raja lakshmi reddy v
hi friends this is raja
Truncate:
1. Truncate is used to delete all rows at a time, so the
table will become as free. The user feel the table does not
contain any rows, eventhough but internally the data exist
some memory that memory is free for our reuse.
2. Truncate is faster than delete, and where clause never
possible.
3. It is ddl command so that it will not roll back because
auto commit by default.
4. in sqlserver autoid columns will reset since from
starting seed value.
Delete:
1. Delete is used to Delete particular rows or all with
where clause or without where clause.
2. remeber if u delete rows, eventhough that memory will
never free means separate memory will allocate to our table.
3. It is slower than the truncate.
4. in sqlserver autoid values will never start from seed
intial value or default value.
5. while deleting check constrains, if any problem errow
thrown.
| Is This Answer Correct ? | 6 Yes | 3 No |
Post New Answer View All Answers
What is chargeback invoice? How do we create it? : oracle accounts receivable
What is an Oracle database Partial Backup?
please send me oracle pl/sql exp resume. and also faqs...
What are different types of receipt reversals ? Explain them : oracle accounts receivable
What do you mean by Oracle MEDIA RECOVERY?
What are different types of transactions in ar? : oracle accounts receivable
Differentiate between transaction type and transaction source? : oracle accounts receivable
as a technical developer in oracle applications which type errors feced in your experience sofar
Hi, IN oracle apps HRMS, if the employee changes his department, and when a conconurrent program is run for calulating the pay, The latest Dept id is not diaplayed, howeber the previous deptid is considered. Please can someone tell me where is the program going wrong, which side?
How do you create a credit note against an invoice? : oracle accounts receivable
WHAT ALL DIFFERENT KIND OF FUNCTIONS AVAILABLE WHILE DESIGN UNIVERSES?
WHAT ALL DIFFERENT OPTIONS PRESENT IN WEBI?
What are the standard concurent programs for auto invoice interface and customer interfaces? : oracle accounts receivable
1. What is PO rate variance gain and loss?
What is the difference between oracle media recovery and crash recovery?