Database Tuning (MOSC)

MOSC Banner

Optimize sql with Full Table Scan

edited Aug 8, 2018 5:08AM in Database Tuning (MOSC) 8 commentsAnswered

Hello,

Recently we are facing performance issues with the application, processes consuming 98% of CPU during peak hours. The AWR reports shows the sql consuming the resources, and it is going for full table scan.

SQL> EXEC DBMS_STATS.GATHER_TABLE_STATS('PIE_P_SWT','SWT_DR_VOU_FILDET');

PL/SQL procedure successfully completed.

SQL> EXEC DBMS_STATS.GATHER_TABLE_STATS('PIE_P_SWT','SWT_DL_VOU_DEN');

PL/SQL procedure successfully completed.

SQL> EXPLAIN PLAN SET STATEMENT_ID = 'st1' FOR

  2  SELECT SERIAL_NO,

  3    PIN_NO,

  4    DENOMINTION,

  5    EXPIRY_DATE,

  6    STATUS_CODE,

  7    AUX_NO

  8  FROM PIE_P_SWT.SWT_DR_VOU_FILDET

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