Question : How to idnetify tables needs to be reorges in db2 installed on production solaris box

Dear experts,

I should identify the tables needs to be reorged in db2 ( prod box).Can you please let me know the below.I would apprciate your help.Thank you.

1.How should I identify the tables needs to be reorged.I mean what factor determines the need for a reorg and how to do that in productsion box.

2.Is there is any affect to the database currently, if i do the above process i mean will impact the performance.

Can you please let me know.Thank you.

Answer : How to idnetify tables needs to be reorges in db2 installed on production solaris box


DB2 provides stored procedures that recommends which tables / indexes to reorg.
For tables:
execute - CALL SYSPROC.REORGCHK_TB_STATS('S','DB2SP')
in the result set, for each table whos REORG column contains an *, reorg is recommended

For indexes:
execute - CALL SYSPROC.REORGCHK_IX_STATS('S','DB2SP')
in the result set, use the following guidelines regarding the REORG column value:

    * If the results of the calculations for Formula 1, 2 and 3 do not exceed the bounds set by the formula and the results of the calculations for Formula 4, 5 or 6 do exceed the bounds set, then index reorganization is recommended.
    * If only the results of the calculations Formula 7 exceed the bounds set, but the results of Formula 1, 2, 3, 4, 5 and 6 are within the set bounds, then cleanup of the indexes using the CLEANUP ONLY option of index reorganization is recommended.
    * If the only calculation result to exceed the set bounds is the that of Formula 8, then a cleanup of the pseudo empty pages of the indexes using the CLEANUP ONLY PAGES option of index reorganization is recommended.

Formula 1,2,3 refers to the result of the table checks (correspond to the 3 charcters in the REORG column of the result set)
Formula 4-8 refers to the 5 characters in the result set of the index checks

Remember - when you perform a table reorg, all indexes are reorged as well.
Random Solutions  
 
programming4us programming4us