IC96613: POOR PERFORMANCE FROM A QUERY THAT INVOLVES VIEWS AND CORRELATED SUBQUERIES

Subscribe to this APAR

By subscribing, you receive periodic emails alerting you to the status of the APAR, along with a link to the fix after it becomes available. You can track this item individually or track all items by product.

Notify me when this APAR changes.

Notify me when an APAR for this component changes.

APAR status

  • Closed as program error.

Error description

  • A query consisting of regular tables, views and one or more
    correlated subqueries is performing poorly or possibly hanging.
    Taking the correlated subquery(ies) out, allows the query to run
    to completion in a reasonable amount of time.
    
    The query plan looks like this while it is running:
    
    Estimated Cost: 4654669
    Estimated # of Rows Returned: 84425
    
      1) (Temp Table For View): SEQUENTIAL SCAN
    
      2) informix.c: INDEX PATH
    
        (1) Index Name: informix.ps_person
            Index Keys: emplid   (Serial, fragments: ALL)
            Lower Index Filter: (Temp Table For View).emplid =
    informix.c.emplid
    NESTED LOOP JOIN
    
      3) (Temp Table For View): AUTOINDEX PATH
    
            Filters: <text removed>
    
        (1) Index Name: (Auto Index)
            Index Keys: emplid
            Lower Index Filter: (Temp Table For View).emplid =
    informix.c.emplid
    NESTED LOOP JOIN
    
    
    The stack while running looks something like this:
    
    readidx_new
    gettupl
    scan_next
    inner_next
    join_next
    join_next
    join_next
    join_next
    sort_open
    filltemp
    scan_open
    materialize_viewtmp
    materialize_viewtmp
    prepselec
    subqprep
    exsubq
    ev_cb
    new_eval
    gettupl
    scan_next
    filltemp
    scan_open
    materialize_viewtmp
    <repeated many times>
    prepselect
    open_cursor
    sql_open
    sq_open
    sqmain
    listen_verify
    spawn_thread
    th_init_initgls
    startup
    idle_processor
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * All 11.70 users.                                             *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * A query may have bad performance under the following         *
    * conditions:                                                  *
    *  - Main query has one or more correlated subqueries, and a   *
    * correlated subquery contains aggregation in projection       *
    * clause                                                       *
    *  - the correlated subquery is in the form of "col <op>       *
    * (<subquery>)", i.e. no ANY/ALL/EXISTS/NOT EXISTS keywords in *
    * front of subquery                                            *
    *  - the correlated subquery contains at least one view or     *
    * derived table reference, and the view or derived table is    *
    * complex and needs to be materialized into temp table at run  *
    * time                                                         *
    *  - the column referenced in the correlated subquery          *
    * predicate has many rows and thus the correlated subquery     *
    * needs to be executed many times                              *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Update to IDS-11.70.xC8                                      *
    ****************************************************************
    

Problem conclusion

  • Problem Fixed In IDS-11.70.xC8
    

Temporary fix

Comments

APAR Information

  • APAR number

    IC96613

  • Reported component name

    INFORMIX SERVER

  • Reported component ID

    5725A3900

  • Reported release

    B70

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2013-10-03

  • Closed date

    2014-02-26

  • Last modified date

    2014-02-26

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    INFORMIX SERVER

  • Fixed component ID

    5725A3900

Applicable component levels

  • RB70 PSN

       UP



Rate this page:

(0 users)Average rating

Add comments

Document information


More support for:

Informix Servers

Software version:

B70

Reference #:

IC96613

Modified date:

2014-02-26

Translate my page

Machine Translation

Content navigation