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!

Query Performance Issue (First_rows hint)

735688Jun 23 2011 — edited Jun 23 2011
Dear friends, I am running a query on default optimizer mode (all_rows) but its not picking the right execution plan nor the right index but if changing optimizer mode into first_rows, its running insteadly. Tables statistics for concern tables are upto date. Same query was running fine some days back.

Any idea about this behavior ?

My culprit query as follow:
SELECT *
FROM (SELECT *
FROM (SELECT /*+ parallel(h,10) */
MSISDN,
IMSI,
SUBSCRIBER_TYPE,
CASE
WHEN INSTR(IN_SERVICE_NAMES, 'MTCIN') = 0 THEN
''
WHEN INSTR(IN_SERVICE_NAMES, 'MTCIN') <> 0 THEN
SUBSTR(IN_SERVICE_NAMES,
INSTR(IN_SERVICE_NAMES, 'MTCIN') + 5,
2)
END MTC
FROM RDMBKPIPRDAPP.HLS_OUT H
WHERE LOAD_PROC_ID = '20112501'
AND LOADING_COUNT = '1'
AND SUBSCRIBER_TYPE = 'Prepaid')) A
INNER JOIN (SELECT /*+ fu parallel(i,10) */
MSISDN, IN_ID, LTRIM(IN_ID, '0') IN_INID
FROM RDMBKPIPRDAPP.IN_OUT I
WHERE LOAD_PROC_ID = '20112501'

) B ON A.MSISDN = B.MSISDN
WHERE A.MOC <> B.IN_ID

Regards
Irfan Ahmad
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 21 2011
Added on Jun 23 2011
7 comments
436 views