如何将数据写入azure存储表
我有需要写入天蓝色存储表的数据。 有人可以向我指出博客或 msdn 文章,我可以在其中引用示例代码吗? 帮助我继续完成第四行代码。
string tableName = "myTable";
CloudStorageAccount cloudStorageAccount = CloudStorageAccount.FromConfigurationSetting("ConnectionString");
CloudTableClient cloudTableClient = cloudStorageAccount.CreateCloudTableClient();
cloudTableClient.CreateTableIfNotExist(tableName);
I have data which needs to be written to azure storage tables.
Can someone point me to a blog or msdn article where I can refer the sample code?
Help me proceed beyond the 4th line of code.
string tableName = "myTable";
CloudStorageAccount cloudStorageAccount = CloudStorageAccount.FromConfigurationSetting("ConnectionString");
CloudTableClient cloudTableClient = cloudStorageAccount.CreateCloudTableClient();
cloudTableClient.CreateTableIfNotExist(tableName);
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
查看 Azure 平台培训套件。特别是,请查看名为 ExploringWindowsAzureStorageVS2010 的实验室。该实验将引导您完成创建表实体、创建表上下文以及插入表存储的代码,包括使用 AddObject() 和 SaveChanges() 将实体写入表。
Take a look at the Azure Platform Training Kit. In particular, look at the lab called ExploringWindowsAzureStorageVS2010. That lab will walk you through creating a table entity, creating a table context, and code to insert into table storage, including the use of AddObject() and SaveChanges() to write your entities to a table.
我还在http://www.geekzone.co.nz/vs2008/6311<找到了一个不错的博客< /a>
I also found a good blog at http://www.geekzone.co.nz/vs2008/6311