Results 1 to 6 of 6
  1. #1
    Join Date
    Apr 2011
    Posts
    38

    Unanswered: Result of EXPLAIN query in IBM DataStudio

    I'm using IBM Data Studio in Ubuntu, and when I run a query like this:

    Code:
    EXPLAIN ALL FOR SELECT field FROM table;
    All I get is this:

    Code:
    Run SQL
    
    EXPLAIN ALL FOR SELECT field FROM table
    Success
     
    Query execution time => 23 ms
     
    Total execution time => 23 ms
    I don't see the actual result of EXPLAIN. What am I doing wrong?
    Last edited by merik; 05-23-11 at 17:07. Reason: found answer to second part

  2. #2
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    AFAIK, this saved the expalain plan for the query in the explain tables.
    Not sure how you view the saved explain plan in DataStudio.
    In Control Centre, right clicking on the database name, there will be a menu item, 'show explain table history'. check if datastudio has something similar

    hth

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

  3. #3
    Join Date
    Sep 2004
    Location
    Belgium
    Posts
    1,126
    You could (and should) instead use the "Visual Explain" component of Data Studio.
    First right click on the connection and select "enable Visual Explain".
    This will create all necessary explain tables for you.
    Then click on the "visual explain" toolbar to obtain a graphical representation of the explain output.
    --_Peter Vanroose,
    __IBM Certified Database Administrator, DB2 9 for z/OS
    __IBM Certified Application Developer
    __ABIS Training and Consulting
    __http://www.abis.be/

  4. #4
    Join Date
    Apr 2011
    Posts
    38
    Thanks Peter. It helped a lot.

  5. #5
    Join Date
    Oct 2011
    Posts
    1
    I can't find "Enable Visual Explain" when I right clicked the connection.

  6. #6
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,368
    Why don't you use db2exfmt instead of GUI tools.

Posting Permissions

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