what is exact difference between drop and truncate table.
Answer Posted / chandana
Drop :
1.Deletes the entire table records as well as the table
structure.
2.It is a DDL Command.
3. Logs are not maintained.
4. Auto Commited.
5.Where clause cannot be used in the Drop statement.Synatx:
Drop table <Table_Name>
Trunctae:
1. Deletes the entire table records ,retains the table
structure.
2. Its a DDL Command.
3. Logs are not maintained. So faster in performace than
Delete.
4. Auto Commited.
Cannot be Rolled Back.
5.Where clause cannot be used with truncate statement.
Truncate Table <Table_Name>;
Delete:
1. Deletes the table records based on condtions ,retains
the table structure.
2. Its a DML Command.
3. Logs are maintained.So slower than trucate.
4. No Auto Commited.So can be Rolled Back.
5.Where clause can be used with truncate statement.
Syantx:
Delete from <Table_Name> where <Condition>;
Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
Explain the difference between a procedure and a function? What do you understand by those terms?
How to increment dates by 1 in oracle?
How to use "out" parameter properly?
State all possible different index configurations a table can possibly have?
What is recovery manager in Oracle?
hello friends Im doing my final year engineering in B.Tech.. one of uncle said he can provide job in his company if im good in database management. but i have only basic knowledge about database, so like to join database management course in good intuition. so friends kindly help me to get good intuition because its my future.
How to see the table columns used in an index?
What is a table index in oracle?
How to create a new view in oracle?
How to count duplicated values in a column in oracle?
WHEN CURSOR MOVES FROM ONE FORM TO ANOTHER FORM, HOW MANY TRIGGER WILL BE FIRED AND WHAT ARE THEIR SEQUENCE?
What are the different oracle database objects?
Explain a segment?
Explain the features of oracle?
What is the sid in oracle?