Return-Path: <ml-errors@fatcity.com>
Received: from ensim.rackshack.net (root@localhost)
 by orafaq.net (8.11.6/8.11.6) with ESMTP id h9H3I4w30425
 for <oracle-l@orafaq.net>; Thu, 16 Oct 2003 22:18:04 -0500
X-ClientAddr: 66.27.56.210
Received: from ns3.fatcity.com (rrcs-west-66-27-56-210.biz.rr.com [66.27.56.210])
 by ensim.rackshack.net (8.11.6/8.11.6) with ESMTP id h9H3Gkc30387
 for <oracle-l@orafaq.net>; Thu, 16 Oct 2003 22:16:46 -0500
Received: from ns3.fatcity.com (localhost.localdomain [127.0.0.1])
 by ns3.fatcity.com (8.12.8/8.12.8) with ESMTP id h9H0NQCb007785
 for <oracle-l@orafaq.net>; Thu, 16 Oct 2003 17:30:56 -0700
Received: (from root@localhost)
 by ns3.fatcity.com (8.12.8/8.12.5/Submit) id h9GDtNxi023506
 for oracle-l@orafaq.net; Thu, 16 Oct 2003 06:55:24 -0700
Received: by fatcity.com (05-Jun-2003/v1.0g-b73/bab) via fatcity.com id 005D3601; Thu, 16 Oct 2003 06:54:25 -0800
Message-ID: <F001.005D3601.20031016065425@fatcity.com>
Date: Thu, 16 Oct 2003 06:54:25 -0800
To: Multiple recipients of list ORACLE-L <ORACLE-L@fatcity.com>
X-Comment: Oracle RDBMS Community Forum
X-Sender: "Fedock, John (KAM.RHQ)" <John.Fedock@us.kline.com>
Sender: ml-errors@fatcity.com
Reply-To: ORACLE-L@fatcity.com
Errors-To: ML-ERRORS@fatcity.com
From: "Fedock, John (KAM.RHQ)" <John.Fedock@US.KLINE.COM>
Subject: RE: bitmap conversion on a index that is not bitmapped ???
Organization: Fat City Network Services, San Diego, California
X-ListServer: v1.0g, build 73; ListGuru (c) 1996-2003 Bruce A. Bergman
Precedence: bulk
Mime-Version: 1.0
Content-Type: multipart/alternative;	boundary="----_=_NextPart_001_01C393EC.B93CDF08"
------_=_NextPart_001_01C393EC.B93CDF08
Content-Type: text/plain;
 charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Thanks for your comments.  You are correct that AIF_OUTBOUND_IX01 is =
more selective than AIF_OUTBOUND_IX03.
=20
>From what I am seeing, degree is affecting the plan.  If I delete stats, =
alter index parallel 10, analyze table estimate stats - the bitmap =
conversion plan is used.
=20
If I delete stats, alter index parallel 10 and renalyze, it goes back to =
the index range scan. =20
=20
At this point, I can accept it - although I am curious as to why it has =
happening.   And can I use degree on other indexes where a index range =
scan is being done to help performance?  So many questions, so little =
time.
=20
=20

-----Original Message-----
Sent: Wednesday, October 15, 2003 6:39 PM
To: Multiple recipients of list ORACLE-L


It seems that you have tow predicates in the where clause that can take =
advantage of two different indexes.
Also you have "AND" condition that Oracle tries to take advantage of =
using "BITMAP AND" operation.
=20
Since you like the performance of the plan that uses the BITMAP =
conversion, I can say that index "'AIF.AIF_OUTBOUND_IX01" is more =
selective than=20
"'AIF.AIF_OUTBOUND_IX03"
=20
And in the second plan that one that does not use the BITMAP, if you =
force it to use index IX01, it would be faster.
=20
Degree has nothing to do to the index performance except when doing =
Index FFS.
=20
Regards,
=20
Waleed

-----Original Message-----
Sent: Wednesday, October 15, 2003 12:50 PM
To: Multiple recipients of list ORACLE-L


Platform is 8.1.7.4, HP-UX 11.00
=20
I have a complex view.  After rebuilding all indexes this weekend, the =
view got much faster.  I did a trace on it.  Now, a few days later, the =
view is getting much slower. Yes, an analyze has run since then, doing =
an 'estimate statistics', but an estimate stats was done after the =
rebuilds as well.  The difference in the explain is below - please note =
that bitmapped conversion info (in bold):
=20
Good plan:
=20
.67 .....FIRST ROW
.66 ......VIEW OF 'GAPP_USER. (CARD=3D1 BYTES=3D13 )
.65 .......SORT (AGGREGATE)  (CARD=3D1 BYTES=3D121 )
.64 ........NESTED LOOPS  (COST=3D53 CARD=3D1 BYTES=3D121 )
.61 .........TABLE ACCESS (BY INDEX ROWID) OF 'AIF.AIF_OUTBOUND'  =
(COST=3D51 CARD=3D1 BYTES=3D86 )
.60 ..........BITMAP CONVERSION (TO ROWIDS)
.59 ...........BITMAP AND
.55 ............BITMAP CONVERSION (FROM ROWIDS)
.54 .............INDEX (RANGE SCAN) OF 'AIF.AIF_OUTBOUND_IX03' =
(NON-UNIQUE)  (COST=3D4 )
.58 ............BITMAP CONVERSION (FROM ROWIDS)
.57 .............SORT (ORDER BY)
.56 ..............INDEX (RANGE SCAN) OF 'AIF.AIF_OUTBOUND_IX01' =
(NON-UNIQUE)  (COST=3D11 )
.63 .........TABLE ACCESS (BY INDEX ROWID) OF 'AIF.EDI_ROUTE'  =
(COST=3D1 CARD=3D65 BYTES=3D2275 )
.62 ..........INDEX (UNIQUE SCAN) OF 'AIF.EDI_ROUTE_PK' (UNIQUE)  =
(CARD=3D65 )
=20
=20
Bad plan:
=20
.61 .....FIRST ROW
.60 ......VIEW OF 'GAPP_USER. (CARD=3D1 BYTES=3D13 )
.59 .......SORT (AGGREGATE)  (CARD=3D1 BYTES=3D121 )
.58 ........NESTED LOOPS  (COST=3D52 CARD=3D1 BYTES=3D121 )
.55 .........TABLE ACCESS (BY INDEX ROWID) OF 'AIF.AIF_OUTBOUND'  =
(COST=3D51 CARD=3D1 BYTES=3D86 )
.54 ..........INDEX (RANGE SCAN) OF 'AIF.AIF_OUTBOUND_IX03' =
(NON-UNIQUE)  (COST=3D3 CARD=3D1 )
.57 .........TABLE ACCESS (BY INDEX ROWID) OF 'AIF.EDI_ROUTE'  =
(COST=3D1 CARD=3D65 BYTES=3D2275 )
.56 ..........INDEX (UNIQUE SCAN) OF 'AIF.EDI_ROUTE_PK' (UNIQUE)  =
(CARD=3D65 )
=20
=20
The interesting thing is, the table in question does not have any bit =
mapped indexes on it.  Some notes on MetaLink show other people =
questioning the same issue, but no concrete info is given.   Any ideas =
out there? =20
=20
TIA.
=20
John

John Fedock=20
"K" Line America, Inc.=20
www.kline.com =20
* john.fedock@us.kline.com=20


=20


------_=_NextPart_001_01C393EC.B93CDF08
Content-Type: text/html;
 charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">


<META content=3D"MSHTML 6.00.2600.0" name=3DGENERATOR></HEAD>
<BODY>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN =
class=3D575314613-16102003>Thanks=20
for your comments.&nbsp; You are correct that AIF_OUTBOUND_IX01 is more=20
selective than AIF_OUTBOUND_IX03.</SPAN></FONT></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
class=3D575314613-16102003></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN =
class=3D575314613-16102003>From=20
what I am seeing, degree is affecting the plan.&nbsp; If I delete stats, =
alter=20
index parallel 10, analyze table estimate stats - the bitmap conversion =
plan is=20
used.</SPAN></FONT></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
class=3D575314613-16102003></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN =
class=3D575314613-16102003>If I=20
delete stats, alter index parallel&nbsp;10 and renalyze, it goes back to =
the=20
index range scan.&nbsp;&nbsp;</SPAN></FONT></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
class=3D575314613-16102003></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN =
class=3D575314613-16102003>At=20
this point, I can accept it - although I am curious as to why it has=20
happening.&nbsp;&nbsp;&nbsp;And can&nbsp;I use degree on other indexes =
where a=20
index range scan is being done to help performance?&nbsp; So many =
questions, so=20
little time.</SPAN></FONT></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
class=3D575314613-16102003></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
class=3D575314613-16102003>&nbsp;</SPAN></FONT></DIV>
<BLOCKQUOTE dir=3Dltr style=3D"MARGIN-RIGHT: 0px">
  <DIV class=3DOutlookMessageHeader dir=3Dltr align=3Dleft><FONT =
face=3DTahoma=20
  size=3D2>-----Original Message-----<BR><B>From:</B> Khedr, Waleed=20
  [mailto:Waleed.Khedr@FMR.COM]<BR><B>Sent:</B> Wednesday, October 15, =
2003 6:39=20
  PM<BR><B>To:</B> Multiple recipients of list =
ORACLE-L<BR><B>Subject:</B> RE:=20
  bitmap conversion on a index that is not bitmapped =
???<BR><BR></FONT></DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT face=3DArial =
color=3D#0000ff size=3D2>It=20
  seems that you have tow predicates in the where clause that can take =
advantage=20
  of two different indexes.</FONT></SPAN></DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT face=3DArial =
color=3D#0000ff size=3D2>Also=20
  you have "AND" condition that Oracle tries to take advantage of using =
"BITMAP=20
  AND" operation.</FONT></SPAN></DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT face=3DArial =
color=3D#0000ff=20
  size=3D2></FONT></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT face=3DArial =
color=3D#0000ff=20
  size=3D2>Since you like the performance of the plan that uses the =
BITMAP=20
  conversion, I can say that index "<FONT=20
  color=3D#000000><STRONG>'AIF.AIF_OUTBOUND_IX01" </STRONG></FONT><FONT=20
  color=3D#0000ff>is more selective than </FONT></FONT></SPAN></DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT =
face=3DArial><FONT=20
  color=3D#0000ff>"</FONT><STRONG><FONT=20
  =
color=3D#000000>'AIF.AIF_OUTBOUND_IX03"</FONT></STRONG></FONT></FONT></SP=
AN></DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT=20
  face=3DArial><STRONG><FONT=20
  color=3D#000000></FONT></STRONG></FONT></FONT></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT=20
  face=3DArial><STRONG><FONT color=3D#000000>And in the second plan that =
one that=20
  does not use the BITMAP, if you force it to use index IX01, it would =
be=20
  faster.</FONT></STRONG></FONT></FONT></SPAN></DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT=20
  face=3DArial><STRONG><FONT=20
  color=3D#000000></FONT></STRONG></FONT></FONT></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT=20
  face=3DArial><STRONG><FONT color=3D#000000>Degree has nothing to do to =
the index=20
  performance except when doing Index=20
  FFS.</FONT></STRONG></FONT></FONT></SPAN></DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT=20
  face=3DArial><STRONG><FONT=20
  color=3D#000000></FONT></STRONG></FONT></FONT></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT=20
  face=3DArial><STRONG><FONT=20
  color=3D#000000>Regards,</FONT></STRONG></FONT></FONT></SPAN></DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT=20
  face=3DArial><STRONG><FONT=20
  color=3D#000000></FONT></STRONG></FONT></FONT></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D517073021-15102003><FONT size=3D2><FONT=20
  face=3DArial><STRONG><FONT=20
  color=3D#000000>Waleed</STRONG></FONT></FONT></FONT></SPAN></DIV>
  <BLOCKQUOTE dir=3Dltr style=3D"MARGIN-RIGHT: 0px">
    <DIV class=3DOutlookMessageHeader dir=3Dltr align=3Dleft><FONT =
face=3DTahoma=20
    size=3D2>-----Original Message-----<BR><B>From:</B> Fedock, John =
(KAM.RHQ)=20
    [mailto:John.Fedock@us.kline.com]<BR><B>Sent:</B> Wednesday, October =
15,=20
    2003 12:50 PM<BR><B>To:</B> Multiple recipients of list=20
    ORACLE-L<BR><B>Subject:</B> bitmap conversion on a index that is not =

    bitmapped ???<BR><BR></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN =
class=3D264513615-15102003>Platform is=20
    8.1.7.4, HP-UX 11.00</SPAN></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN class=3D264513615-15102003>I =
have a complex=20
    view.&nbsp; After rebuilding all indexes this weekend, the view got =
much=20
    faster.&nbsp; I did a trace on it.&nbsp; Now, a few days later, the =
view is=20
    getting much slower.&nbsp;Yes, an analyze has run since then, doing =
an=20
    'estimate statistics', but an&nbsp;estimate stats was done after the =

    rebuilds as well.&nbsp;&nbsp;The difference in the explain is below =
- please=20
    note that bitmapped conversion info (in bold):</SPAN></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN =
class=3D264513615-15102003>Good=20
    plan:</SPAN></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN =
class=3D264513615-15102003>..67 .....FIRST=20
    ROW<BR>..66 ......VIEW OF 'GAPP_USER. (CARD=3D1 BYTES=3D13 )<BR>..65 =
......SORT=20
    (AGGREGATE)&nbsp; (CARD=3D1 BYTES=3D121 )<BR>..64 ........NESTED =
LOOPS&nbsp;=20
    (COST=3D53 CARD=3D1 BYTES=3D121 )<BR>..61 .........TABLE ACCESS (BY =
INDEX ROWID)=20
    OF 'AIF.AIF_OUTBOUND'&nbsp; (COST=3D51 CARD=3D1 BYTES=3D86 =
)<BR><STRONG>..60=20
    ..........BITMAP CONVERSION (TO ROWIDS)<BR>..59 ...........BITMAP=20
    AND<BR>..55 ............BITMAP CONVERSION (FROM ROWIDS)<BR>..54=20
    .............INDEX (RANGE SCAN) OF 'AIF.AIF_OUTBOUND_IX03'=20
    (NON-UNIQUE)&nbsp; (COST=3D4 )<BR></STRONG>..58 ............BITMAP =
CONVERSION=20
    (FROM ROWIDS)<BR>..57 .............SORT (ORDER BY)<BR>..56=20
    ..............INDEX (RANGE SCAN) OF 'AIF.AIF_OUTBOUND_IX01'=20
    (NON-UNIQUE)&nbsp; (COST=3D11 )<BR>..63 .........TABLE ACCESS (BY =
INDEX ROWID)=20
    OF 'AIF.EDI_ROUTE'&nbsp; (COST=3D1 CARD=3D65 BYTES=3D2275 )<BR>..62=20
    ..........INDEX (UNIQUE SCAN) OF 'AIF.EDI_ROUTE_PK' (UNIQUE)&nbsp; =
(CARD=3D65=20
    )</SPAN></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT><FONT face=3DArial =
size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT><FONT face=3DArial =
size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN =
class=3D264513615-15102003>Bad=20
    plan:</SPAN></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN =
class=3D264513615-15102003>..61 .....FIRST=20
    ROW<BR>..60 ......VIEW OF 'GAPP_USER. (CARD=3D1 BYTES=3D13 )<BR>..59 =
......SORT=20
    (AGGREGATE)&nbsp; (CARD=3D1 BYTES=3D121 )<BR>..58 ........NESTED =
LOOPS&nbsp;=20
    (COST=3D52 CARD=3D1 BYTES=3D121 )<BR><STRONG>..55 .........TABLE =
ACCESS (BY INDEX=20
    ROWID) OF 'AIF.AIF_OUTBOUND'&nbsp; (COST=3D51 CARD=3D1 BYTES=3D86 =
)<BR>..54=20
    ..........INDEX (RANGE SCAN) OF 'AIF.AIF_OUTBOUND_IX03' =
(NON-UNIQUE)&nbsp;=20
    (COST=3D3 CARD=3D1 )</STRONG><BR>..57 .........TABLE ACCESS (BY =
INDEX ROWID) OF=20
    'AIF.EDI_ROUTE'&nbsp; (COST=3D1 CARD=3D65 BYTES=3D2275 )<BR>..56 =
.........INDEX=20
    (UNIQUE SCAN) OF 'AIF.EDI_ROUTE_PK' (UNIQUE)&nbsp; (CARD=3D65=20
    )</SPAN></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN =
class=3D264513615-15102003>The interesting=20
    thing is, the table in question does not have any bit mapped indexes =
on=20
    it.&nbsp; Some notes on MetaLink show other people questioning the =
same=20
    issue, but no concrete info is given.&nbsp;&nbsp; Any ideas out =
there?&nbsp;=20
    </SPAN></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003>TIA.</SPAN></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003></SPAN></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2><SPAN=20
    class=3D264513615-15102003>John</SPAN></FONT></DIV>
    <P><FONT face=3DArial size=3D2>John Fedock</FONT> <BR><FONT =
face=3DArial=20
    color=3D#ff0000 size=3D2>"K"</FONT><FONT face=3DArial size=3D2> Line =
America,=20
    Inc.</FONT> <BR><FONT face=3DArial size=3D2><A=20
    href=3D"http://www.kline.com">www.kline.com</A></FONT>&nbsp; =
<BR><FONT=20
    face=3DWingdings size=3D2>*</FONT><FONT face=3D"Times New =
Roman"></FONT> <FONT=20
    face=3DArial size=3D2>john.fedock@us.kline.com</FONT> </P><BR>
    <DIV><FONT face=3DArial=20
size=3D2></FONT>&nbsp;</DIV></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>

------_=_NextPart_001_01C393EC.B93CDF08--
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Fedock, John (KAM.RHQ)
  INET: John.Fedock@us.kline.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru@fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

