Skip to content

Commit 39ddd14

Browse files
committed
Updating per feedback
1 parent 1a61db6 commit 39ddd14

File tree

2 files changed

+12
-19
lines changed

2 files changed

+12
-19
lines changed

articles/cosmos-db/create-table-dotnet.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,6 @@ If you don’t already have Visual Studio 2017 installed, you can download and u
2929

3030
## Create a database account
3131

32-
> [!IMPORTANT]
33-
> You must create a new Table API account to work with the generally available Table API SDKs. Table API accounts created during preview are not supported by the generally available SDKs.
34-
>
35-
3632
[!INCLUDE [cosmos-db-create-dbaccount-table](../../includes/cosmos-db-create-dbaccount-table.md)]
3733

3834
## Add a table
@@ -65,7 +61,7 @@ Now let's clone a Table app from GitHub, set the connection string, and run it.
6561
git clone https://github.com/Azure-Samples/azure-cosmos-table-dotnet-core-getting-started.git
6662
```
6763
> [!NOTE]
68-
> The .Net standard sample described in this doc works with both Azure Table Storage and Azure Cosmos DB Table API. If you are interested in running the sample that works with .Net Framework 4.5, see the [storage-table-dotnet-getting-started](https://github.com/Azure-Samples/storage-table-dotnet-getting-started) sample.
64+
> The .Net standard sample described in this doc works with both Azure Cosmos DB Table API and Azure Table Storage. If you are interested in running the sample that works with .Net Framework 4.5, see the [storage-table-dotnet-getting-started](https://github.com/Azure-Samples/storage-table-dotnet-getting-started) sample.
6965
7066

7167
## Open the sample application in Visual Studio
@@ -95,10 +91,6 @@ Now go back to the Azure portal to get your connection string information and co
9591
```
9692
If you are using the [.Net Framework](https://github.com/Azure-Samples/storage-table-dotnet-getting-started) sample, you should update the connection string that’s located in the **App.config** file.
9793

98-
> [!IMPORTANT]
99-
> If your Endpoint uses documents.azure.com, that means you have a preview account, and you must create a [new Table API account](#create-a-database-account) to work with the generally available Table API SDK.
100-
>
101-
10294
4. Press CTRL+S to save the **Settings.json** file.
10395

10496
You've now updated your app with all the info it needs to communicate with Azure Cosmos DB.
@@ -126,8 +118,6 @@ You've now updated your app with all the info it needs to communicate with Azure
126118

127119
![Console output](media/create-table-dotnet/azure-cosmosdb-console.png)
128120

129-
If you get an error about dependencies, see [Troubleshooting](table-sdk-dotnet.md#troubleshooting).
130-
131121
When you hit the first breakpoint, go back to Data Explorer in the Azure portal. Click the **Refresh** button, expand the demo* table, and click **Entities**. The **Entities** tab on the right shows the new entity that was added for Walter Harp. Note that the phone number for the new entity is 425-555-0101.
132122

133123
![New entity](media/create-table-dotnet/azure-cosmosdb-entity.png)

articles/cosmos-db/tutorial-develop-table-dotnet-standard.md

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
title: Get started with Azure Table storage and Azure Cosmos DB Table API using .NET Standard SDK
3-
description: Store structured data in the cloud using Azure Table storage or the Azure Cosmos DB Table API.
2+
title: Get started with Azure Cosmos DB Table API using .NET Standard SDK
3+
description: Store structured data in the cloud using the Azure Cosmos DB Table API.
44
author: wmengmsft
55
ms.author: wmeng
66
ms.service: cosmos-db
@@ -9,15 +9,15 @@ ms.devlang: dotnet
99
ms.topic: sample
1010
ms.date: 03/11/2019
1111
---
12-
# Get started with Azure Table storage and the Azure Cosmos DB Table API using .NET SDK
12+
# Get started with Azure Cosmos DB Table API and Azure Table storage using the .NET SDK
1313

1414
[!INCLUDE [storage-selector-table-include](../../includes/storage-selector-table-include.md)]
1515

1616
[!INCLUDE [storage-table-applies-to-storagetable-and-cosmos](../../includes/storage-table-applies-to-storagetable-and-cosmos.md)]
1717

18-
You can use Azure Table storage or the Azure Cosmos DB Table API to store structured NoSQL data in the cloud, providing a key/attribute store with a schema less design. Because Table storage and the Azure Cosmos DB Table API are schema less, it's easy to adapt your data as the needs of your application evolve. You can use Table storage or the Azure Cosmos DB Table API to store flexible datasets such as user data for web applications, address books, device information, or other types of metadata your service requires.
18+
You can use the Azure Cosmos DB Table API or Azure Table storage to store structured NoSQL data in the cloud, providing a key/attribute store with a schema less design. Because Azure Cosmos DB Table API and Table storage are schema less, it's easy to adapt your data as the needs of your application evolve. You can use Azure Cosmos DB Table API or the Table storage to store flexible datasets such as user data for web applications, address books, device information, or other types of metadata your service requires.
1919

20-
This tutorial describes a sample that shows you how to use the [Microsoft Azure Cosmos DB Table Library for .NET](https://www.nuget.org/packages/Microsoft.Azure.Cosmos.Table) with Azure Table storage and Azure Cosmo DB Table API scenarios. You must use the connection specific to the Azure service. These scenarios are explored using C# examples that illustrate how to create tables, insert/ update data, query data and delete the tables.
20+
This tutorial describes a sample that shows you how to use the [Microsoft Azure Cosmos DB Table Library for .NET](https://www.nuget.org/packages/Microsoft.Azure.Cosmos.Table) with Azure Cosmo DB Table API and Azure Table storage scenarios. You must use the connection specific to the Azure service. These scenarios are explored using C# examples that illustrate how to create tables, insert/ update data, query data and delete the tables.
2121

2222
Prerequisites
2323
You need the following to run this tutorial:
@@ -218,7 +218,8 @@ public static async Task<CustomerEntity> InsertOrMergeEntityAsync(CloudTable tab
218218
// Execute the operation.
219219
TableResult result = await table.ExecuteAsync(insertOrMergeOperation);
220220
CustomerEntity insertedCustomer = result.Result as CustomerEntity;
221-
221+
222+
// Get the request units consumed by the current operation. RequestCharge of a TableResult is only applied to Azure CosmoS DB
222223
if (result.RequestCharge.HasValue)
223224
{
224225
Console.WriteLine("Request Charge of InsertOrMerge Operation: " + result.RequestCharge);
@@ -235,9 +236,9 @@ public static async Task<CustomerEntity> InsertOrMergeEntityAsync(CloudTable tab
235236
}
236237
```
237238

238-
### Retrieve an entity from a partition
239+
### Get an entity from a partition
239240

240-
To query a table for all entities in a partition by using the Retrieve method under the [TableOperation](https://docs.microsoft.com/dotnet/api/microsoft.windowsazure.storage.table.tableoperation?redirectedfrom=MSDN&view=azure-dotnet) class. The following code example gets the partition key row key, email and phone number of a customer entity. This example also prints out the request units consumed to query for the entity. To query for an entity, append the following code to **SamplesUtils.cs** file:
241+
You can get entity from a partition by using the Retrieve method under the [TableOperation](https://docs.microsoft.com/dotnet/api/microsoft.windowsazure.storage.table.tableoperation?redirectedfrom=MSDN&view=azure-dotnet) class. The following code example gets the partition key row key, email and phone number of a customer entity. This example also prints out the request units consumed to query for the entity. To query for an entity, append the following code to **SamplesUtils.cs** file:
241242

242243
```csharp
243244
public static async Task<CustomerEntity> RetrieveEntityUsingPointQueryAsync(CloudTable table, string partitionKey, string rowKey)
@@ -252,6 +253,7 @@ public static async Task<CustomerEntity> RetrieveEntityUsingPointQueryAsync(Clou
252253
Console.WriteLine("\t{0}\t{1}\t{2}\t{3}", customer.PartitionKey, customer.RowKey, customer.Email, customer.PhoneNumber);
253254
}
254255

256+
// Get the request units consumed by the current operation. RequestCharge of a TableResult is only applied to Azure CosmoS DB
255257
if (result.RequestCharge.HasValue)
256258
{
257259
Console.WriteLine("Request Charge of Retrieve Operation: " + result.RequestCharge);
@@ -285,6 +287,7 @@ public static async Task DeleteEntityAsync(CloudTable table, CustomerEntity dele
285287
TableOperation deleteOperation = TableOperation.Delete(deleteEntity);
286288
TableResult result = await table.ExecuteAsync(deleteOperation);
287289

290+
// Get the request units consumed by the current operation. RequestCharge of a TableResult is only applied to Azure CosmoS DB
288291
if (result.RequestCharge.HasValue)
289292
{
290293
Console.WriteLine("Request Charge of Delete Operation: " + result.RequestCharge);

0 commit comments

Comments
 (0)