Skip to content

Commit ee7a5cb

Browse files
committed
Fix dependent tabs
1 parent 91e8eec commit ee7a5cb

File tree

1 file changed

+92
-92
lines changed

1 file changed

+92
-92
lines changed

articles/cosmos-db/merge.md

Lines changed: 92 additions & 92 deletions
Original file line numberDiff line numberDiff line change
@@ -77,105 +77,105 @@ In PowerShell, when the flag `-WhatIf` is passed in, Azure Cosmos DB will run a
7777
7878
#### [PowerShell](#tab/azure-powershell)
7979

80-
1. First, use [`Install-Module`](/powershell/module/powershellget/install-module) to install the [Az.CosmosDB](/powershell/module/az.cosmosdb/) module with pre-release features enabled.
81-
82-
```azurepowershell-interactive
83-
$parameters = @{
84-
Name = "Az.CosmosDB"
85-
AllowPrerelease = $true
86-
Force = $true
87-
}
88-
Install-Module @parameters
89-
```
90-
91-
##### [API for NoSQL](#tab/azure-powershell/nosql)
92-
93-
1. Next, use `Invoke-AzCosmosDBSqlContainerMerge` with the `-WhatIf` parameter to preview the merge without actually performing the operation.
94-
95-
```azurepowershell-interactive
96-
$parameters = @{
97-
ResourceGroupName = "<resource-group-name>"
98-
AccountName = "<cosmos-account-name>"
99-
DatabaseName = "<cosmos-database-name>"
100-
Name = "<cosmos-container-name>"
101-
WhatIf = $true
102-
}
103-
Invoke-AzCosmosDBSqlContainerMerge @parameters
104-
```
105-
106-
1. Finally, start the merge by running the same command without the `-WhatIf` parameter.
107-
108-
```azurepowershell-interactive
109-
$parameters = @{
110-
ResourceGroupName = "<resource-group-name>"
111-
AccountName = "<cosmos-account-name>"
112-
DatabaseName = "<cosmos-database-name>"
113-
Name = "<cosmos-container-name>"
114-
}
115-
Invoke-AzCosmosDBSqlContainerMerge @parameters
116-
```
117-
118-
##### [API for MongoDB](#tab/azure-powershell/mongodb)
119-
120-
1. Next, use `Invoke-AzCosmosDBMongoDBCollectionMerge` with the `-WhatIf` parameter to preview the merge without actually performing the operation.
121-
122-
```azurepowershell-interactive
123-
$parameters = @{
124-
ResourceGroupName = "<resource-group-name>"
125-
AccountName = "<cosmos-account-name>"
126-
DatabaseName = "<cosmos-database-name>"
127-
Name = "<cosmos-container-name>"
128-
WhatIf = $true
129-
}
130-
Invoke-AzCosmosDBMongoDBCollectionMerge @parameters
131-
```
132-
133-
1. Finally, start the merge by running the same command without the `-WhatIf` parameter.
134-
135-
```azurepowershell-interactive
136-
$parameters = @{
137-
ResourceGroupName = "<resource-group-name>"
138-
AccountName = "<cosmos-account-name>"
139-
DatabaseName = "<cosmos-database-name>"
140-
Name = "<cosmos-container-name>"
141-
}
142-
Invoke-AzCosmosDBMongoDBCollectionMerge @parameters
143-
```
80+
Use [`Install-Module`](/powershell/module/powershellget/install-module) to install the [Az.CosmosDB](/powershell/module/az.cosmosdb/) module with pre-release features enabled.
14481

145-
---
82+
```azurepowershell-interactive
83+
$parameters = @{
84+
Name = "Az.CosmosDB"
85+
AllowPrerelease = $true
86+
Force = $true
87+
}
88+
Install-Module @parameters
89+
```
14690

14791
#### [Azure CLI](#tab/azure-cli)
14892

149-
1. First, use [`az extension add`](/cli/azure/extension#az-extension-add) to install the [cosmosdb-preview](https://github.com/azure/azure-cli-extensions/tree/main/src/cosmosdb-preview) Azure CLI extension.
150-
151-
```azurecli-interactive
152-
az extension add \
153-
--name cosmosdb-preview
154-
```
155-
156-
##### [API for NoSQL](#tab/azure-cli/nosql)
93+
Use [`az extension add`](/cli/azure/extension#az-extension-add) to install the [cosmosdb-preview](https://github.com/azure/azure-cli-extensions/tree/main/src/cosmosdb-preview) Azure CLI extension.
15794

158-
1. Now, start the merge by using [`az cosmosdb sql container merge`](/cli/azure/cosmosdb/sql/container#az-cosmosdb-sql-container-merge).
95+
```azurecli-interactive
96+
az extension add \
97+
--name cosmosdb-preview
98+
```
15999

160-
```azurecli-interactive
161-
az cosmosdb sql container merge \
162-
--resource-group '<resource-group-name>' \
163-
--account-name '<cosmos-account-name>' \
164-
--database-name '<cosmos-database-name>' \
165-
--name '<cosmos-container-name>'
166-
```
167-
168-
##### [API for MongoDB](#tab/azure-cli/mongodb)
169-
170-
1. Now, start the merge by using [`az cosmosdb mongodb collection merge`](/cli/azure/cosmosdb/mongodb/collection#az-cosmosdb-mongodb-collection-merge).
100+
---
171101

172-
```azurecli-interactive
173-
az cosmosdb mongodb collection merge \
174-
--resource-group '<resource-group-name>' \
175-
--account-name '<cosmos-account-name>' \
176-
--database-name '<cosmos-database-name>' \
177-
--name '<cosmos-collection-name>'
178-
```
102+
#### [API for NoSQL](#tab/nosql/azure-powershell)
103+
104+
Use `Invoke-AzCosmosDBSqlContainerMerge` with the `-WhatIf` parameter to preview the merge without actually performing the operation.
105+
106+
```azurepowershell-interactive
107+
$parameters = @{
108+
ResourceGroupName = "<resource-group-name>"
109+
AccountName = "<cosmos-account-name>"
110+
DatabaseName = "<cosmos-database-name>"
111+
Name = "<cosmos-container-name>"
112+
WhatIf = $true
113+
}
114+
Invoke-AzCosmosDBSqlContainerMerge @parameters
115+
```
116+
117+
Start the merge by running the same command without the `-WhatIf` parameter.
118+
119+
```azurepowershell-interactive
120+
$parameters = @{
121+
ResourceGroupName = "<resource-group-name>"
122+
AccountName = "<cosmos-account-name>"
123+
DatabaseName = "<cosmos-database-name>"
124+
Name = "<cosmos-container-name>"
125+
}
126+
Invoke-AzCosmosDBSqlContainerMerge @parameters
127+
```
128+
129+
#### [API for NoSQL](#tab/nosql/azure-cli)
130+
131+
Start the merge by using [`az cosmosdb sql container merge`](/cli/azure/cosmosdb/sql/container#az-cosmosdb-sql-container-merge).
132+
133+
```azurecli-interactive
134+
az cosmosdb sql container merge \
135+
--resource-group '<resource-group-name>' \
136+
--account-name '<cosmos-account-name>' \
137+
--database-name '<cosmos-database-name>' \
138+
--name '<cosmos-container-name>'
139+
```
140+
141+
#### [API for MongoDB](#tab/mongodb/azure-powershell)
142+
143+
Use `Invoke-AzCosmosDBMongoDBCollectionMerge` with the `-WhatIf` parameter to preview the merge without actually performing the operation.
144+
145+
```azurepowershell-interactive
146+
$parameters = @{
147+
ResourceGroupName = "<resource-group-name>"
148+
AccountName = "<cosmos-account-name>"
149+
DatabaseName = "<cosmos-database-name>"
150+
Name = "<cosmos-container-name>"
151+
WhatIf = $true
152+
}
153+
Invoke-AzCosmosDBMongoDBCollectionMerge @parameters
154+
```
155+
156+
Start the merge by running the same command without the `-WhatIf` parameter.
157+
158+
```azurepowershell-interactive
159+
$parameters = @{
160+
ResourceGroupName = "<resource-group-name>"
161+
AccountName = "<cosmos-account-name>"
162+
DatabaseName = "<cosmos-database-name>"
163+
Name = "<cosmos-container-name>"
164+
}
165+
Invoke-AzCosmosDBMongoDBCollectionMerge @parameters
166+
```
167+
168+
#### [API for MongoDB](#tab/mongodb/azure-cli)
169+
170+
Start the merge by using [`az cosmosdb mongodb collection merge`](/cli/azure/cosmosdb/mongodb/collection#az-cosmosdb-mongodb-collection-merge).
171+
172+
```azurecli-interactive
173+
az cosmosdb mongodb collection merge \
174+
--resource-group '<resource-group-name>' \
175+
--account-name '<cosmos-account-name>' \
176+
--database-name '<cosmos-database-name>' \
177+
--name '<cosmos-collection-name>'
178+
```
179179

180180
---
181181

0 commit comments

Comments
 (0)