Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

INDEX SKIP SCAN VS RANGE SCAN

977887Jan 30 2014 — edited Jan 31 2014


Hi,

i have a query which uses index range scan in one environment and the same query does index skip scan in another environment.

oracle db version 10.2.0.3

Elapsed: 00:00:11.89

Execution Plan
----------------------------------------------------------
Plan hash value: 1271961902

--------------------------------------------------------------------------------------------------
| Id  | Operation                   | Name               | Rows  | Bytes | Cost (%CPU)| Time     |
--------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT            |                    |     1 |   100 |    49   (0)| 00:00:01 |
|*  1 |  TABLE ACCESS BY INDEX ROWID| AP_BSTRN_HEADER    |     1 |   100 |    49   (0)| 00:00:01 |
|*  2 |   INDEX RANGE SCAN          | II_AP_BSTRN_HEADER |    47 |       |     4   (0)| 00:00:01 |
--------------------------------------------------------------------------------------------------

Statistics

----------------------------------------------------------

          8  recursive calls

          0  db block gets

       8578  consistent gets

       8372  physical reads

          0  redo size

        517  bytes sent via SQL*Net to client

        488  bytes received via SQL*Net from client

          2  SQL*Net roundtrips to/from client

          0  sorts (memory)

          0  sorts (disk)

          1  rows processed

Elapsed: 00:00:00.12

Execution Plan
----------------------------------------------------------
Plan hash value: 499858110

-------------------------------------------------------------------------------------------------------
| Id  | Operation                   | Name                    | Rows  | Bytes | Cost (%CPU)| Time     |
-------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT            |                         |     1 |   100 |     8   (0)| 00:00:01 |
|*  1 |  TABLE ACCESS BY INDEX ROWID| AP_BSTRN_HEADER         |     1 |   100 |     8   (0)| 00:00:01 |
|*  2 |   INDEX SKIP SCAN           | AP_BSTRN_HEAD_BK_CK_IDX |     3 |       |     6   (0)| 00:00:01 |
-------------------------------------------------------------------------------------------------------

Statistics

----------------------------------------------------------

          8  recursive calls

          0  db block gets

         28  consistent gets

          4  physical reads

          0  redo size

        517  bytes sent via SQL*Net to client

        492  bytes received via SQL*Net from client

          2  SQL*Net roundtrips to/from client

          0  sorts (memory)

          0  sorts (disk)

          1  rows processed

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 28 2014
Added on Jan 30 2014
20 comments
14,766 views