Skip to main content

hub_virtual_network_connections

Creates, updates, deletes, gets or lists a hub_virtual_network_connections resource.

Overview

Namehub_virtual_network_connections
TypeResource
Idazure.network.hub_virtual_network_connections

Fields

The following fields are returned by SELECT queries:

Request successful. Returns the details of the HubVirtualNetworkConnection retrieved.

NameDatatypeDescription
idstringResource ID.
namestringThe name of the resource that is unique within a resource group. This name can be used to access the resource.
etagstringA unique read-only string that changes whenever the resource is updated.
propertiesobjectProperties of the hub virtual network connection.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectsubscriptionId, resourceGroupName, virtualHubName, connectionNameRetrieves the details of a HubVirtualNetworkConnection.
listselectsubscriptionId, resourceGroupName, virtualHubNameRetrieves the details of all HubVirtualNetworkConnections.
create_or_updateinsertsubscriptionId, resourceGroupName, virtualHubName, connectionNameCreates a hub virtual network connection if it doesn't exist else updates the existing one.
deletedeletesubscriptionId, resourceGroupName, virtualHubName, connectionNameDeletes a HubVirtualNetworkConnection.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
connectionNamestringThe name of the HubVirtualNetworkConnection.
resourceGroupNamestringThe resource group name of the VirtualHub.
subscriptionIdstring (uuid)The ID of the target subscription. The value must be an UUID.
virtualHubNamestringThe name of the VirtualHub.

SELECT examples

Retrieves the details of a HubVirtualNetworkConnection.

SELECT
id,
name,
etag,
properties
FROM azure.network.hub_virtual_network_connections
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND virtualHubName = '{{ virtualHubName }}' -- required
AND connectionName = '{{ connectionName }}' -- required
;

INSERT examples

Creates a hub virtual network connection if it doesn't exist else updates the existing one.

INSERT INTO azure.network.hub_virtual_network_connections (
data__properties,
data__name,
data__id,
subscriptionId,
resourceGroupName,
virtualHubName,
connectionName
)
SELECT
'{{ properties }}',
'{{ name }}',
'{{ id }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ virtualHubName }}',
'{{ connectionName }}'
RETURNING
id,
name,
etag,
properties
;

DELETE examples

Deletes a HubVirtualNetworkConnection.

DELETE FROM azure.network.hub_virtual_network_connections
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND virtualHubName = '{{ virtualHubName }}' --required
AND connectionName = '{{ connectionName }}' --required
;