Results 1 to 4 of 4

Thread: db2 reorg stop

  1. #1
    Join Date
    Oct 2005
    Posts
    26

    Unanswered: db2 reorg stop

    Hi all,

    We have a BW database that is LUW 8.2. We have a reorg scripts that performs that reorgs a list of tables based off of reorgchk.

    Does anyone have any good ideas to STOP these reorgs at some point, but then know which tables or indexes are in this STOP state to resume?

  2. #2
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Check LIST UTILITES command .. I guess, you should be able to get the information about the REORGs

    Sathyaram
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  3. #3
    Join Date
    Oct 2004
    Location
    DELHI INDIA
    Posts
    338
    In your script itself you can echo the REORG statement and write the output of the success/failure to an output file. If you want to kill the execution of the process, then from the output file of the script you will come to know upto which table the REORG was successfully executed.

    Also, you can use the LIST HISTORY.. REORG command to see which are the tables REORGed today.

    Thanks,
    Jayanta Datta
    New Delhi, India

  4. #4
    Join Date
    Mar 2004
    Posts
    46
    You can use the "snapshot_tbreorg" snapshot function - see below -

    $ db2 "describe select * from table(snapshot_tbreorg('',0))a"

    SQLDA Information

    sqldaid : SQLDA sqldabc: 1136 sqln: 20 sqld: 17

    Column Information

    sqltype sqllen sqlname.data sqlname.length
    -------------------- ------ ------------------------------ --------------
    393 TIMESTAMP 26 SNAPSHOT_TIMESTAMP 18
    449 VARCHAR 128 TABLE_NAME 10
    449 VARCHAR 128 TABLE_SCHEMA 12
    493 BIGINT 8 PAGE_REORGS 11
    493 BIGINT 8 REORG_PHASE 11
    497 INTEGER 4 REORG_MAX_PHASE 15
    493 BIGINT 8 REORG_CURRENT_COUNTER 21
    493 BIGINT 8 REORG_MAX_COUNTER 17
    497 INTEGER 4 REORG_TYPE 10
    501 SMALLINT 2 REORG_STATUS 12
    497 INTEGER 4 REORG_COMPLETION 16
    393 TIMESTAMP 26 REORG_START 11
    393 TIMESTAMP 26 REORG_END 9
    393 TIMESTAMP 26 REORG_PHASE_START 17
    493 BIGINT 8 REORG_INDEX_ID 14
    493 BIGINT 8 REORG_TBSPC_ID 14
    501 SMALLINT 2 PARTITION_NUMBER 16


    -- Jayesh

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •