GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  Oracle  >  General
Go To First  |  Previous Question  |  Next Question 
 General  |  Question 195 of 211    Print  
Explain truncate with restore option with example

  
Total Answers and Comments: 4 Last Update: December 27, 2006     Asked by: Subbu Ramesh 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
March 16, 2006 01:22:07   #1  
shirish muley        

RE: Explain truncate with restore option with example

TRUNCATE cannot be rollbacked i.e. restore cannot work on TRUNCATE.

So while truncating a table if u feel you might need the data later use DELETE

instead of TRUNCATE which can be rollbacked.

E.g. DELETE from tablename


 
Is this answer useful? Yes | No
June 24, 2006 07:55:48   #2  
Sajid Ansari        

RE: Explain truncate with restore option with example

Truncate command is a DDL command

In oracle there is Autocommit after DDL command so no rollback can be done But if u want to restore your data You can use your previous dump to restore your data back by using Oracle import utility.


 
Is this answer useful? Yes | No
August 15, 2006 09:56:04   #3  
gouthami        

RE: Explain truncate with restore option with example

Truncate is a DDL Command. When used in SQL Statement Deletes the data of the table permanently i.e It Cannot be rolledback Leaving only the structure behind.

Ex.truncate table tablename;

if the needs to be restored than use the delete command .

Ex.Delete *or columns from tablename;


 
Is this answer useful? Yes | No
December 27, 2006 09:43:26   #4  
sangeetha        

RE: Explain truncate with restore option with example
In oracle DDL command if u give TRUNCATE command storage of data will get lost and structure of table will be there as it roll back option is not there once u truncate the table
 
Is this answer useful? Yes | No


 
Go To Top


 Sponsored Links

 
About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape