Skip to main content

cassandra_data_center

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

Overview

Namecassandra_data_center
TypeResource
Idazure.cosmos_db.cassandra_data_center

Fields

NameDatatypeDescription
idstringThe unique resource identifier of the database account.
namestringThe name of the database account.
propertiesobjectProperties of a managed Cassandra data center.
typestringThe type of Azure resource.

Methods

NameAccessible byRequired ParamsDescription
getSELECTclusterName, dataCenterName, resourceGroupName, subscriptionIdGet the properties of a managed Cassandra data center.
listSELECTclusterName, resourceGroupName, subscriptionIdList all data centers in a particular managed Cassandra cluster.
create_updateINSERTclusterName, dataCenterName, resourceGroupName, subscriptionIdCreate or update a managed Cassandra data center. When updating, overwrite all properties. To update only some properties, use PATCH.
deleteDELETEclusterName, dataCenterName, resourceGroupName, subscriptionIdDelete a managed Cassandra data center.
updateUPDATEclusterName, dataCenterName, resourceGroupName, subscriptionIdUpdate some of the properties of a managed Cassandra data center.

SELECT examples

List all data centers in a particular managed Cassandra cluster.

SELECT
id,
name,
properties,
type
FROM azure.cosmos_db.cassandra_data_center
WHERE clusterName = '{{ clusterName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

INSERT example

Use the following StackQL query and manifest file to create a new cassandra_data_center resource.

/*+ create */
INSERT INTO azure.cosmos_db.cassandra_data_center (
clusterName,
dataCenterName,
resourceGroupName,
subscriptionId,
properties
)
SELECT
'{{ clusterName }}',
'{{ dataCenterName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ properties }}'
;

UPDATE example

Updates a cassandra_data_center resource.

/*+ update */
UPDATE azure.cosmos_db.cassandra_data_center
SET
properties = '{{ properties }}'
WHERE
clusterName = '{{ clusterName }}'
AND dataCenterName = '{{ dataCenterName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

DELETE example

Deletes the specified cassandra_data_center resource.

/*+ delete */
DELETE FROM azure.cosmos_db.cassandra_data_center
WHERE clusterName = '{{ clusterName }}'
AND dataCenterName = '{{ dataCenterName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';