Truncate in DB2 Enterprise and in Oracle Enterprise

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
saikir
Participant
Posts: 92
Joined: Wed Nov 08, 2006 12:25 am
Location: Minneapolis
Contact:

Truncate in DB2 Enterprise and in Oracle Enterprise

Post by saikir »

Hi All,

I would like to how does a truncate command behave in each of the database stages

DB2 Enterprise: Does it use the load and replace option to truncate data or does it do a delete from <table>. Also by default will this commands be captured in the redologs

Oracle Enterprise. Does it use the Truncate command or delete from <table>

Any inputs will be well appreciated.

Thanks,
Sai
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

OE: Truncate is truncate. The word 'clear' is used for the transactional 'delete from table' operation.

DB2: no clue.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Since DB2 has no truncate, it will do a DELETE rather than the (more complex) load method to delete entries.
arnabdey
Participant
Posts: 50
Joined: Wed Jan 10, 2007 5:56 am

Post by arnabdey »

You can check the log... It does a simple delete.... for truncate and load use the db2 load stage in case you have very huge data volume and you want a replace load...
Arnab
Post Reply