How to find unused indexes in an Oracle schema?
First enable index monitoring, wait for a period of time and then query the V$OBJECT_USAGE view. If USED is 'NO', it may not be used. Then combine AWR and SQL execution plan data to further confirm, and finally delete it carefully.

To find unused indexes in an Oracle schema, you need to analyze index usage statistics over a representative period. Oracle does not automatically track index usage unless you enable monitoring, and even then, it only shows whether an index has been used since monitoring was turned on.
Enable Index Monitoring
Before you can detect unused indexes, you must enable monitoring for each index or all indexes in the schema.
- To monitor a single index: ALTER INDEX schema.index_name MONITORING USAGE;
- To monitor all indexes in a schema, run a script to generate ALTER INDEX commands for each index.
- After enabling, wait for a realistic workload cycle (eg, one week) to gather meaningful data.
Check V$OBJECT_USAGE View
Once monitoring is enabled and sufficient time has passed, query V$OBJECT_USAGE to see usage status.
- Run this query to list monitored indexes and their usage:
SELECT index_name, table_name, monitoring, used, start_monitoring, end_monitoring
FROM v$object_usage
WHERE owner = 'YOUR_SCHEMA_NAME';
- If USED = 'NO' , the index hasn't been used since monitoring started.
- Consider dropping such indexes after confirming they are truly unnecessary.
Analyze Automatic Workload Repository (AWR) and DBA_HIST_SQLSTAT
For historical insight beyond current monitoring, check AWR data to see if indexes were used in execution plans.
- Query DBA_HIST_SQLSTAT joined with DBA_IND_COLUMNS to find if an index appears in past SQL execution plans.
- This method requires diagnostic pack licensing.
Use Real-Time SQL Monitoring and Execution Plans
Check if indexes appear in recent execution plans using:
- DBA_HIST_SQL_PLAN – Historical plan data from AWR.
- V$SQL_PLAN – Current shared pool plans.
- Look for your index names in the OBJECT_NAME column where OPERATION = 'INDEX'.
Indexes not appearing in any plans over time, especially when queries could benefit from them, may be unused or redundant.
Basically, turn on monitoring, wait, then check V$OBJECT_USAGE. Supplement with AWR and SQL plan data for deeper analysis. Always validate before dropping any index.
The above is the detailed content of How to find unused indexes in an Oracle schema?. For more information, please follow other related articles on the PHP Chinese website!
Hot AI Tools
Undress AI Tool
Undress images for free
AI Clothes Remover
Online AI tool for removing clothes from photos.
Undresser.AI Undress
AI-powered app for creating realistic nude photos
ArtGPT
AI image generator for creative art from text prompts.
Stock Market GPT
AI powered investment research for smarter decisions
Hot Article
Popular tool
Notepad++7.3.1
Easy-to-use and free code editor
SublimeText3 Chinese version
Chinese version, very easy to use
Zend Studio 13.0.1
Powerful PHP integrated development environment
Dreamweaver CS6
Visual web development tools
SublimeText3 Mac version
God-level code editing software (SublimeText3)
Hot Topics
20519
7
13632
4
What is Janction(JCT) coin? Is it worth the investment? Janction technical architecture, token economy and prospect analysis
Nov 11, 2025 pm 02:27 PM
Janction (JCT) is recognized as the first layer-2 network dedicated to delivering artificial intelligence (AI) services in a verifiable, scalable and decentralized manner. The project integrates AI models, GPU computing power, data collection and annotation processes into a unified ecosystem, creating an underlying infrastructure that integrates blockchain and artificial intelligence technology. This article will comprehensively analyze Janction’s core technology architecture, practical application scenarios, and deeply explore its GPU pooling mechanism, billing system, node deployment strategy, and key partnerships. Are you ready? Start this journey of exploration of future AI infrastructure now! Binance[adid]fbd7939d674997cdb4692
What is APRO(AT) coin? Is it worth investing in? APRO project overview and airdrop collection
Oct 23, 2025 pm 03:06 PM
Binance币安[adid]fbd7939d674997cdb4692d34de8633c4[/adid][adid]758691fdf7ae3403db0d3bd8ac3ad585[/adid]欧易OKX️[adid]fe9fc289c3ff0a f142b6d3bead98a923[/adid][adid]efd1a2f9b0b5f14b1fac70a7f8e8a9e7[/adid]Huobi火币️[adid]9778d5d219c5080b9a6a17bef029331c[/adid][a
What is API3 coin? How to buy? How API3 works, token economics and future prospects
Nov 08, 2025 pm 05:36 PM
Recently, the prices of many cryptocurrencies have shown rapid growth, with increases ranging from 50% to 100% or even higher. These include YGG, Ildguildgamezm introduced before, and API3 which we are going to focus on today. Following YGG, the transaction volume of API3 also increased significantly, increasing by approximately 55% from the previous day. API3 is a project dedicated to building a decentralized API for Web3.0. Binance
How to find unused indexes in an Oracle schema?
Oct 27, 2025 am 01:34 AM
First enable index monitoring, wait for a period of time and then query the V$OBJECT_USAGE view. If USED is 'NO', it may not be used. Then combine AWR and SQL execution plan data to further confirm, and finally delete it carefully.
Software cannot be used after Windows 11 system upgrade_Solution to the problem that old version software cannot run after Windows 11 system upgrade
Nov 20, 2025 pm 01:00 PM
If the old software cannot run after upgrading Windows 11, you can try: use the compatibility troubleshooter, manually set the compatibility mode, run as an administrator, enable .NET Framework 3.5, install the Visual C runtime library, or run the old system environment in a virtual machine.
What is Datagram (DGRAM) coin? Is it worth the investment? Introduction to Datagram working principle and token information
Nov 21, 2025 pm 06:46 PM
Datagram is building a Hyper-FabricDePIN platform that uses artificial intelligence to connect computing, bandwidth and storage resources to provide efficient decentralized infrastructure for real-time applications. Binance[adid]fbd7939d674997cdb4692d34de8633c4[/adid]
How to handle ORA-01017: invalid username/password in Oracle?
Oct 20, 2025 am 03:10 AM
ORA-01017occursduetoinvalidcredentialsoraccountissues;verifyusernameandpasswordaccuracy,ensuringcasesensitivityandnoextraspaces.2.Confirmtheaccountisnotlockedorexpiredbycheckingdba_usersandunlockorresetasneeded.3.Ensurecorrectdatabaseconnection,authe
How to find the SID of your Oracle database?
Oct 16, 2025 am 09:49 AM
TofindtheOracleSID,querySELECTinstance_nameFROMv$instance;whenconnectedviaSQL*Plus.2.ChecktheORACLE_SIDenvironmentvariableonUnix/Linuxastheoracleuser.3.InspectOracleprocesseswithps-ef|greppmontoseetheSIDinprocessnames.4.Reviewtnsnames.oraforSIDentrie





