Home » SQL & PL/SQL » SQL & PL/SQL » Compare and contrast TRUNCATE and DELETE for a table
Compare and contrast TRUNCATE and DELETE for a table [message #665250] Mon, 28 August 2017 02:03 Go to next message
Meenakumari
Messages: 3
Registered: August 2017
Junior Member
HI iam learning oracle in Naresh i Technologies can any body help Compare and contrast TRUNCATE and DELETE for a table?

Re: Compare and contrast TRUNCATE and DELETE for a table [message #665260 is a reply to message #665250] Mon, 28 August 2017 05:51 Go to previous messageGo to next message
Littlefoot
Messages: 21266
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
The most obvious way to find the answer is to open a relevant Oracle documentation book, read what's written for both commands and compare them.

Another option is to Google for it, such as this.

Or, you might wait for someone to spoonfeed you.
Re: Compare and contrast TRUNCATE and DELETE for a table [message #665270 is a reply to message #665250] Mon, 28 August 2017 07:30 Go to previous messageGo to next message
adil shakeel
Messages: 47
Registered: August 2017
Member
the use of delete can be used for deleting records falling under certain condition which is true or false depending upon our requirements.

The truncate always delete the all record of table and as a result the table got empty.

Say :
use of delete:

Delete from customers where id>5;

The above command would delete only those records in which customers' id greater that 5.

However in the truncate we can not delete the customized records.

Re: Compare and contrast TRUNCATE and DELETE for a table [message #665271 is a reply to message #665250] Mon, 28 August 2017 07:31 Go to previous message
BlackSwan
Messages: 25748
Registered: January 2009
Location: SoCal
Senior Member
Meenakumari wrote on Mon, 28 August 2017 00:03
HI iam learning oracle in Naresh i Technologies can any body help Compare and contrast TRUNCATE and DELETE for a table?

ask the fine folks at URL below for answer

Meenakumari wrote on Mon, 28 August 2017 00:35
Hi nareshit is the Best Oracle Training Institute In India. It provides all software courses. we located Hyderabad, chennai and vijayawada. we offering online training also faculty are well experienced. so i suggest Naresh i Technologies is the Best.
Call:040-23746666
Previous Topic: Help with PL SQL query - Analytical Function or group by
Next Topic: Cursor within a cursor
Goto Forum:
  


Current Time: Thu Dec 14 17:11:29 CST 2017

Total time taken to generate the page: 0.23193 seconds