Compare and contrast TRUNCATE and DELETE for a table.

Answers were Sorted based on User's Feedback



Compare and contrast TRUNCATE and DELETE for a table...

Answer / mkjmkumar

Delete :
1. It is a DML
2. Speed is Slow
3. We can Use Where Clause.
4. Check Constraints Before delete.

Truncate
1. It is a DDL.
2. Speed is Fast
3. We Cant Use Where Clause
4. Delete All Rows without check of constraints.

Is This Answer Correct ?    7 Yes 0 No

Compare and contrast TRUNCATE and DELETE for a table...

Answer / zikku

Truncate command permanently deletes the information from a
table even after rollback we can't get that information.
Delete command temporarily deletes information from a table
after rollback we can get the information back.

Is This Answer Correct ?    5 Yes 0 No

Compare and contrast TRUNCATE and DELETE for a table...

Answer / ark chowdary

DELETE: IT IS A DML COMMAND(DATA MANIPULATION LANGUAGE) .
IT DELETES DATA MEANS (DELETES ALL RECORDS) IN TABLE.
BUT STRUCTURE WILL BE THERE.
AND
DATA DELETES TEMPERORLY.
THEN USE ROLLBACK WE CAN GET THE DATA.

TRUNCATE: IT IS A DDL COMMAND (DATA DEFNITION LANGUAGE).
TRUNCATE ALL RECORDS IN A TABLE.
BUT STRUCTURE WILL BE THERE.
BUT DATA GOES PERMINANTLY.
WE CANT USE ROLLBACK HERE.
IT SHOLUD NOT WORK. WHY BCZ DATA TRUNCATES
PERMENANTLY.

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More Oracle AllOther Interview Questions

1.In a table Gender is a column in that male and female are the two data.In a single statement i have to modify all male to female and all female to male vice versa. 2.In a single query i need the count of male data,count of female and total count

3 Answers   HP,


What is the difference between a TEMPORARY tablespace and a PERMANENT tablespace?

2 Answers  


Differentiate between earned discounts and unearned discounts? : oracle accounts receivable

0 Answers  


I've got a database 10g and Form version 5.0 but unable to connect. Does Oracle 10g database supports form 4.5

0 Answers   jusco,


Is Oracle 7.3 is a single user or multi user..Is it possible to use this as a backend for web applications?

2 Answers  






CAN AUNIVERSE BE LINKED TO MORE THAN ONE DATASOURCE?

0 Answers  


What is the difference between recovery and restoring of the oracle database?

0 Answers  


How would you determine who has added a row to a table?

0 Answers  


8. Supporting AP, AR and GL?

0 Answers   Oracle,


What is mrc and what is its use? : oracle accounts receivable

0 Answers  


PURCHASE ORDER TO PAYABLES WHAT ENTREIS WILL HAVE

0 Answers  


what is difference between inner join & nested query or subqueries

0 Answers  


Categories
  • Oracle General Interview Questions Oracle General (1808)
  • Oracle DBA (Database Administration) Interview Questions Oracle DBA (Database Administration) (261)
  • Oracle Call Interface (OCI) Interview Questions Oracle Call Interface (OCI) (10)
  • Oracle Architecture Interview Questions Oracle Architecture (90)
  • Oracle Security Interview Questions Oracle Security (38)
  • Oracle Forms Reports Interview Questions Oracle Forms Reports (510)
  • Oracle Data Integrator (ODI) Interview Questions Oracle Data Integrator (ODI) (120)
  • Oracle ETL Interview Questions Oracle ETL (15)
  • Oracle RAC Interview Questions Oracle RAC (93)
  • Oracle D2K Interview Questions Oracle D2K (72)
  • Oracle AllOther Interview Questions Oracle AllOther (241)