RRC@node9 > create table a1(a varchar2(255)) 2 / Table created. Elapsed: 00:00:00.05 RRC@node9 > insert into a1(a) 2 select null from all_objects 3 / 56295 rows created. Elapsed: 00:00:00.44 RRC@node9 > create table a2(a varchar2(255) not null) 2 / Table created. Elapsed: 00:00:00.02 RRC@node9 > insert into a2(a) 2 select object_name from all_objects where object_name is not null 3 / 56296 rows created. Elapsed: 00:00:00.39 RRC@node9 > commit 2 / Commit complete. Elapsed: 00:00:00.06 RRC@node9 > create index a1_idx on a1(a) 2 / Index created. Elapsed: 00:00:00.04 RRC@node9 > create index a2_idx on a2(a) 2 / Index created. Elapsed: 00:00:00.51 RRC@node9 > exec dbms_stats.gather_schema_stats(NULL,cascade=>true,granularity=>'ALL',options=>'GATHER AUTO',estimate_percent=>dbms_stats.auto_sample_size); PL/SQL procedure successfully completed. Elapsed: 00:00:01.38 RRC@node9 > set autotrace traceonly explain RRC@node9 > select count(*) from a1 where a like '%O%' 2 / Elapsed: 00:00:00.00 Execution Plan ---------------------------------------------------------- Plan hash value: 417082427 --------------------------------------------------------------------------- | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time | --------------------------------------------------------------------------- | 0 | SELECT STATEMENT | | 1 | 129 | 0 (0)| 00:00:01 | | 1 | SORT AGGREGATE | | 1 | 129 | | | |* 2 | INDEX FULL SCAN| A1_IDX | 1 | 129 | 0 (0)| 00:00:01 | --------------------------------------------------------------------------- Predicate Information (identified by operation id): --------------------------------------------------- 2 - filter("A" IS NOT NULL AND "A" LIKE '%O%') RRC@node9 > select count(*) from a2 where a like '%O%' 2 / Elapsed: 00:00:00.00 Execution Plan ---------------------------------------------------------- Plan hash value: 3851220615 --------------------------------------------------------------------------- | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time | --------------------------------------------------------------------------- | 0 | SELECT STATEMENT | | 1 | 26 | 68 (0)| 00:00:01 | | 1 | SORT AGGREGATE | | 1 | 26 | | | |* 2 | TABLE ACCESS FULL| A2 | 2815 | 73190 | 68 (0)| 00:00:01 | --------------------------------------------------------------------------- Predicate Information (identified by operation id): --------------------------------------------------- 2 - filter("A" LIKE '%O%') RRC@node9 > select count(*) from a1 2 / Elapsed: 00:00:00.00 Execution Plan ---------------------------------------------------------- Plan hash value: 2855827631 ------------------------------------------------------------------- | Id | Operation | Name | Rows | Cost (%CPU)| Time | ------------------------------------------------------------------- | 0 | SELECT STATEMENT | | 1 | 25 (0)| 00:00:01 | | 1 | SORT AGGREGATE | | 1 | | | | 2 | TABLE ACCESS FULL| A1 | 56295 | 25 (0)| 00:00:01 | ------------------------------------------------------------------- RRC@node9 > select count(*) from a2 2 / Elapsed: 00:00:00.00 Execution Plan ---------------------------------------------------------- Plan hash value: 3851220615 ------------------------------------------------------------------- | Id | Operation | Name | Rows | Cost (%CPU)| Time | ------------------------------------------------------------------- | 0 | SELECT STATEMENT | | 1 | 68 (0)| 00:00:01 | | 1 | SORT AGGREGATE | | 1 | | | | 2 | TABLE ACCESS FULL| A2 | 56296 | 68 (0)| 00:00:01 | ------------------------------------------------------------------- RRC@node9 >