當我嘗試在Table Storage中創建表(使用Azure本地存儲器模擬器)時,出現錯誤「遠程服務器返回錯誤:(400)錯誤的請求。錯誤的請求 - 在Azure本地存儲器中創建表
表的名字是根據規則,所以會發生什麼?!
角色配置:
<ConfigurationSettings>
<Setting name="Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString" value="UseDevelopmentStorage=true" />
<Setting name="StorageConnectionString" value="UseDevelopmentStorage=true" />
</ConfigurationSettings>
創建表法:
CloudStorageAccount storageAccount = CloudStorageAccount.Parse(
CloudConfigurationManager.GetSetting("StorageConnectionString"));
CloudTableClient tableClient = storageAccount.CreateCloudTableClient();
CloudTable table = tableClient.GetTableReference("people");
table.CreateIfNotExists();