Hi
What is the difference between the DELETE mode and WRITE - TRUNCATE mode. What will be the impact of the same in database.
Can any one help me out on the same.
Thanks in advance
Difference between Truncate and Delete
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 31
- Joined: Tue Jul 13, 2004 5:26 am
- Location: chennai
- Contact:
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Which database? There IS more than one, despite what Oracle bin Larry would have us believe.
As a general rule, truncate is a fast operation that recovers space formerly occupied by data.
Delete deletes individual records, and the operations are logged in the transaction log. It tends to be a rather slower process than truncate.
If this is not the answer to your question, can you please post a more precise question? For example, you may be asking about menu options in a particular stage type. If so, please provide the stage type name and the actual text of the menu options.
You might also profitably consult the documentation and/or on-line help for that particular stage type.
As a general rule, truncate is a fast operation that recovers space formerly occupied by data.
Delete deletes individual records, and the operations are logged in the transaction log. It tends to be a rather slower process than truncate.
If this is not the answer to your question, can you please post a more precise question? For example, you may be asking about menu options in a particular stage type. If so, please provide the stage type name and the actual text of the menu options.
You might also profitably consult the documentation and/or on-line help for that particular stage type.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 31
- Joined: Tue Jul 13, 2004 5:26 am
- Location: chennai
- Contact:
Hi
Thanks for your great interest.
In DB2/UDBEnterprise stage as of my knowledge both the truncate and delete option send the commond as Delete, if so how does Truncate option will be more faster than the delete option.
How does it internally works on. Can you put some more light on the same.
Thanks
Thanks for your great interest.
In DB2/UDBEnterprise stage as of my knowledge both the truncate and delete option send the commond as Delete, if so how does Truncate option will be more faster than the delete option.
How does it internally works on. Can you put some more light on the same.
Thanks
Lakshmi
Hi,
I just wanted to point this is a DBA issue rather then DS.
so if no replies simply contact your project's supporting DBA.
IHTH,
I just wanted to point this is a DBA issue rather then DS.
so if no replies simply contact your project's supporting DBA.
IHTH,
Roy R.
Time is money but when you don't have money time is all you can afford.
Search before posting:)
Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
Time is money but when you don't have money time is all you can afford.
Search before posting:)
Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
My earlier reply was generic; consult DB2 documentation (or DBA) for an explanation of the different working of DELETE and TRUNCATE TABLE. You should be able to tie it in with what I wrote to enhance your understanding of the differences.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 3593
- Joined: Thu Jan 23, 2003 5:25 pm
- Location: Australia, Melbourne
- Contact:
Truncate can be dangerous. Triggers on the table will not be fired by a truncate, they will be fired by a delete. Changed data capture modules may have problems identifying a truncate. Dependent foreign key relationships can be bypassed by a truncate leaving you with data integrity problems. These are the type of issues you need to discuss with someone who knows the database structure quite well.
Certus Solutions
Blog: Tooling Around in the InfoSphere
Twitter: @vmcburney
LinkedIn:Vincent McBurney LinkedIn
Blog: Tooling Around in the InfoSphere
Twitter: @vmcburney
LinkedIn:Vincent McBurney LinkedIn