[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

10/27/2009 at 04:36AM PDT, ID: 24846813 | Points: 500
[x]
Attachment Details

performance problem after ASE 15.0.3 migration

Asked by sybase_dba in Sybase Database

We have recently migrated ASE from 12.5.3 to 15.0.3.  ASE 15.0.3 generates bad query plan.
this is the part of the query plan generated by 15.0.3 :
SCAN Operator (VA = 4)
       |   |   |  FROM TABLE
       |   |   |  oe_order_d
       |   |   |  Index : oe_order_d_index1
       |   |   |  Forward Scan.
       |   |   |  Positioning by key.
       |   |   |  Keys are:
       |   |   |    hos_cd ASC
       |   |   |  Using I/O Size 2 Kbytes for index leaf pages.
       |   |   |  With LRU Buffer Replacement Strategy for index leaf pages.
       |   |   |  Using I/O Size 2 Kbytes for data pages.
       |   |   |  With LRU Buffer Replacement Strategy for data pages.

but 12.5.3 picksup good index of the same table. here is the query plan generated by 12.5.3.
 SCAN Operator (VA = 3)
       |   |   |  FROM TABLE
       |   |   |  oe_order_d
       |   |   |  Using Clustered Index.
       |   |   |  Index : pk_oe_order_d
       |   |   |  Forward Scan.
       |   |   |  Positioning by key.
       |   |   |  Keys are:
       |   |   |    hos_cd ASC
       |   |   |    order_num ASC
       |   |   |  Using I/O Size 2 Kbytes for index leaf pages.
       |   |   |  With LRU Buffer Replacement Strategy for index leaf pages.
       |   |   |  Using I/O Size 2 Kbytes for data pages.
       |   |   |  With LRU Buffer Replacement Strategy for data pages.

I > sp_spaceused oe_order_d
2> go
 name       rowtotal reserved   data       index_size unused    
 ---------- -------- ---------- ---------- ---------- ---------
 oe_order_d 10085831 4886684 KB 3344876 KB 1088512 KB 453296 KB

1> sp_helpindex oe_order_d
2> go
Object has the following indexes
 
 index_name         index_keys                                  index_description index_max_rows_per_page index_fillfactor index_reservepagegap index_created       index_local  
 ------------------ ------------------------------------------- ----------------- ----------------------- ---------------- -------------------- ------------------- ------------
 oe_order_d_index1   hos_cd, chg_tp, create_ts                  nonclustered                            0                0                    0 Sep  9 2004  1:17AM Global Index
 pk_oe_order_d       hos_cd, order_num, seq_num                 clustered, unique                       0                0                    0                NULL Global Index
 id_oe_order_d3      hos_cd, issue_dept, request_num, queue_num nonclustered                            0                0                    0 Sep  9 2004  1:21AM Global Index
 NC_IND4_oe_order_d  hos_cd, post_ts                            nonclustered                            0                0                    0 Jan 26 2007 11:32AM Global Index

I run update index statistics with scale 50 on this table but it still picks up wrong index. Is there any fix for this problem other than setting compatibility_mode to 1?

thanks

[+][-]10/27/09 05:13 AM, ID: 25671468

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/28/09 07:42 PM, ID: 25690256

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/20/09 07:33 AM, ID: 25871244

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 30-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]11/20/09 09:51 PM, ID: 25876684

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/20/09 10:54 PM, ID: 25876837

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20090824-EE-VQP-74 - Hierarchy / EE_QW_3_20080625