Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2003
    Location
    canada
    Posts
    230

    Unanswered: How can I force db2 to use temporary tablespace for result table in declare cursor ?

    Hi All,
    We work with db2v8.2.2 and aix5.2

    after tuning sql statement in declare cursor the FETCH part of program became slower than before and I found out this time db2 does not use temporary table space for result table and result table is derived during the excution of FETCH statement.

    how can I force db2 to use temporary tablespace?

    Thank you in advance for your help.

  2. #2
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    You could try to add an ORDER BY clause which is not supported by an index. But I don't know if it would run faster.
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

  3. #3
    Join Date
    Sep 2003
    Location
    canada
    Posts
    230
    Quote Originally Posted by Marcus_A
    You could try to add an ORDER BY clause which is not supported by an index. But I don't know if it would run faster.
    Thank you Marcus

Posting Permissions

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