Windows Azure存储表服务使用指南
1. 表存储的基本操作步骤
在使用Windows Azure的表存储服务时,需要遵循以下步骤:
1. 定义表的架构模型 :
- 定义一个实体类(可继承自 TableStorageEntity 类)。
- 定义一个 DataServiceContext 类(可继承自 TableStorageDataServiceContext 类)。
- 对于开发存储,需要在这些类上运行 DevTableGen.exe 工具来生成SQL Server数据库表。
2. 创建存储账户信息实例 :从配置文件中输入的配置信息创建 StorageAccountInfo 类的实例。
StorageAccountInfo account = StorageAccountInfo.GetDefaultQueueStorageAccountFromConfiguration();
- 在表服务中创建表 :
TableStorage.CreateTablesFromModel(typeof(ProAzureReaderDataContext), accountI
超级会员免费看
订阅专栏 解锁全文

34

被折叠的 条评论
为什么被折叠?



