Check Oracle licences and feature usage
SQL queries to check licensed sessions and CPUs and the Oracle features in use.
Two queries help check Oracle licences and the usage of database features.
Licensed sessions and CPUs
The V$LICENSE view gives the current and maximum (highwater) values for sessions and CPUs:
select
sessions_current,sessions_highwater,
cpu_count_current,cpu_core_count_current,
cpu_count_highwater,cpu_core_count_highwater
from V$LICENSE;
Feature usage
The dba_feature_usage_statistics view lists the features detected in the database:
select name,version,detected_usages,currently_used,
first_usage_date,last_usage_date
from dba_feature_usage_statistics
where detected_usages >0
order by 1;
Readable report in SQL*Plus
Column formatting, then a query on the features already used:
set pages 999
col c1 heading 'feature' format a45
col c2 heading 'times|used' format 999,999
col c3 heading 'first|used'
col c4 heading 'used|now'
select
name c1,
detected_usages c2,
first_usage_date c3,
currently_used c4
from
dba_feature_usage_statistics
where
first_usage_date is not null;