Database Tuning (MOSC)

MOSC Banner

Plan changes depending on the literal value in the sql

edited Aug 14, 2010 4:39AM in Database Tuning (MOSC) 10 commentsAnswered
  Hi,

I am encountering a strange issue, during the execution of a sql. The sql's plan changes simply because of a literal value in the sql. Here are the conditions/changes which is impacting the sql execution plan.

(int.user_je_source_name,group_id) in (('XXX XXXX', 123702))  -- chooses right plan

(int.user_je_source_name,group_id) in (('XXX XXXX', 17122010123702)) -- chooses a wrong plan  the only difference is the value for group_id.

We verified and confirmed that it is not because of the number of rows for that value in the table, the sql works fine if we trim down the number of digits to 7 digits, if it crosses 7 digits it chooses wrong plan.

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