Results 1 to 5 of 5
  1. #1
    Join Date
    Feb 2007
    Posts
    47

    Unanswered: need reorg synchronous

    I have DB2 v8 FP 17.

    I notice that if I do an REORG TABLE PROD.ACTION IN PLACE ALLOW WRITE ACCESS;

    These are asynchronous. I want to do synchronous instead since I have an update stats and rebind at the end of the script (these get executed almost immediately). How can I achieve that easily? I can probably switch to ALLOW READ ACCESS if that's the case...

  2. #2
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Well, don't do it INPLACE then.
    ---
    "It does not work" is not a valid problem statement.

  3. #3
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Two options :

    a) After issuing the reorgs, check the status of them on a periodic basis ... Do the runstats and rebind after all reorgs complete. There is a admin function for the reorg status ...

    b) Do the reorgs on one day and the runstats/rebind the next day

    The second option is easy and OK only if you are doing a 'casual' reorg, and NOT after a specfiic operation like DELETE of a huge number of rows.


    Quote Originally Posted by bic View Post
    I have DB2 v8 FP 17.

    I notice that if I do an REORG TABLE PROD.ACTION IN PLACE ALLOW WRITE ACCESS;

    These are asynchronous. I want to do synchronous instead since I have an update stats and rebind at the end of the script (these get executed almost immediately). How can I achieve that easily? I can probably switch to ALLOW READ ACCESS if that's the case...
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  4. #4
    Join Date
    Dec 2007
    Location
    Richmond, VA
    Posts
    1,328
    Provided Answers: 5
    Go with option a above. You can check the status in a script, while still running go to sleep for a bit, then check again, when complete then start next set of commands.

  5. #5
    Join Date
    Jan 2009
    Location
    Zoetermeer, Holland
    Posts
    746
    Quote Originally Posted by dav1mo View Post
    Go with option a above. You can check the status in a script, while still running go to sleep for a bit, then check again, when complete then start next set of commands.
    Correct. Used to do that. One of the reasons why I do not like INLINE reorgs: complex scripts and a lot of logging, slow and additional action required to reorg your indexes as well.

Posting Permissions

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