turbot/azure_insights

Query: network_network_interfaces_for_network_security_group

Usage

powerpipe query azure_insights.query.network_network_interfaces_for_network_security_group

SQL

select
lower(nic.id) as nic_id
from
azure_network_security_group as nsg,
jsonb_array_elements(network_interfaces) as ni
left join azure_network_interface as nic on lower(nic.id) = lower(ni ->> 'id')
where
(nic.id) is not null
and lower(nsg.id) = $1;