turbot/oci_insights

Query: database_autonomous_db_age_report

Usage

powerpipe query oci_insights.query.database_autonomous_db_age_report

SQL

select
d.display_name as "Name",
d.id as "OCID",
now()::date - d.time_created::date as "Age in Days",
d.time_created as "Create Time",
d.lifecycle_state as "Lifecycle State",
t.title as "Tenancy",
coalesce(c.title, 'root') as "Compartment",
d.region as "Region"
from
oci_database_autonomous_database as d
left join oci_identity_compartment as c on d.compartment_id = c.id
left join oci_identity_tenancy as t on d.tenant_id = t.id
where
d.lifecycle_state <> 'TERMINATED'
order by
d.time_created,
d.display_name;

Dashboards

The query is used in the dashboards: