Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

What is oracle join syntax?

1005


Can the query output be sorted by multiple columns in oracle?

993


How to apply filtering criteria at group level in oracle?

1045


What is hot backup and logical backup?

1051


how to convert .db (extention) database file into .dmp (extention ) for oracle database ?

2556


Why do I get unexpected characters from 8-bit character sets in weblogic jdriver for oracle?

1087


How to define a specific record type?

1085


What is the difference between formal parameters and actual parameters?

1089


What is the use of oracle?

1030


How would you begin to troubleshoot an ORA-3113 error?

2080


What are the general rules on data consistency?

1010


What is different types of joins?

1023


How to do clean up if create database failed?

1031


How do I manually uninstall oracle client?

1092


What is an oracle database?

1044