当我尝试在表存储中创建表(使用 Azure 本地存储模拟器)时,我收到错误“远程服务器返回错误:(400) 错误请求。”
表的名称是符合规则的,所以会发生什么?!
角色配置:
<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();