If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Update performance on index columns.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-07-06, 08:27
jrbusta jrbusta is offline
Registered User
 
Join Date: Aug 2006
Posts: 1
Post Update performance on index columns.

i like know what method offer best performance for update values on index columns, update versus delete/insert, over DB2 v720 on z/os. Regards. John
Reply With Quote
  #2 (permalink)  
Old 08-07-06, 10:26
rahul_s80 rahul_s80 is offline
Registered User
 
Join Date: Jul 2006
Location: Pune , India
Posts: 433
i think for all types of db2 update is a better method.
make sure to run runstats after doing update, insert,delete on tables having large data so that optimizer is updated with new values.

Runstats for Both tables and indexes:
RUNSTATS ON TABLE tablename WITH DISTRIBUTION AND DETAILED INDEXES ALL

Rahul Singh
Reply With Quote
  #3 (permalink)  
Old 08-07-06, 17:10
Marcus_A Marcus_A is offline
Registered User
 
Join Date: May 2003
Location: USA
Posts: 5,196
Quote:
Originally Posted by jrbusta
i like know what method offer best performance for update values on index columns, update versus delete/insert, over DB2 v720 on z/os. Regards. John
If you are updating the clustering index and you want DB2 to recluster the data row (according to the clustering index), then you should do a delete and insert.

If you are not changing the clustering index or you would rather defer the re-clustering task to when you do a reorg, then do an update.

For best performance in a system with very high transaction rates, any index that gets changed often (insert, update, or delete) should have a reasonably high fullkeycard value (even if you have to add additonal columns to the index). Indexes with very low cardinality are slow to update.
__________________
M. A. Feldman
IBM Certified DBA on DB2 for Linux, UNIX, and Windows
IBM Certified DBA on DB2 for z/OS and OS/390
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On