SQL Performance (MOSC)

MOSC Banner

When run from SQL plus, SQL showing different PLAN while v$sql showing different one


Hello everyone

On one of our 19c Database we are experiencing a little contradictory information while running a SQL 

Here are the details

variable trm varchar2(10)

exec :trm :='XSE'

set autot on

select * from test where trim=:trm;

MAKE    MODEL   TRIM

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

Toyota   Camry   XSE

.....

...............

Toyota   Camry   XSE


10 rows selected.


Elapsed: 00:00:00.01


Execution Plan

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

Plan hash value: 1357081020


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

| Id | Operation     | Name | Rows | Bytes | Cost (%CPU)| Time   |

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

|  0 | SELECT STATEMENT |   | 50000 |  781K|  103  (1)| 00:00:01 |

|* 1 | TABLE ACCESS FULL| TEST | 50000 |  781K|  103  (1)| 00:00:01 |

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


Predicate Information (identified by operation id):

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


  1 - filter("TRIM"=:TRM)



Statistics

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

     0 recursive calls

     0 db block gets

     5 consistent gets

     0 physical reads

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center