turbot/oci_insights

Query: vcn_subnet_input

Usage

powerpipe query oci_insights.query.vcn_subnet_input

SQL

select
n.display_name as label,
n.id as value,
json_build_object(
'n.id', right(reverse(split_part(reverse(n.id), '.', 1)), 8),
'n.region', region,
'oci.name', coalesce(oci.title, 'root'),
't.name', t.name
) as tags
from
oci_core_subnet as n
left join oci_identity_compartment as oci on n.compartment_id = oci.id
left join oci_identity_tenancy as t on n.tenant_id = t.id
where
n.lifecycle_state <> 'TERMINATED'
order by
n.display_name;