C#使用MongoDB的注意事项
来源:互联网 发布:淘宝运费险怎么设置 编辑:程序博客网 时间:2024/05/19 22:58
1、使用Nuget Package Manager——Package Manager Console安装MongoDB,如下
PM> Install-Package MongoDB.Driver
Attempting to gather dependency information for package 'MongoDB.Driver.2.4.4' with respect to project 'AccessServerDebug', targeting '.NETFramework,Version=v4.5'
Attempting to resolve dependencies for package 'MongoDB.Driver.2.4.4' with DependencyBehavior 'Lowest'
Resolving actions to install package 'MongoDB.Driver.2.4.4'
Resolved actions to install package 'MongoDB.Driver.2.4.4'
GET https://api.nuget.org/packages/mongodb.bson.2.4.4.nupkg
OK https://api.nuget.org/packages/mongodb.bson.2.4.4.nupkg 16ms
2、若自己引用MongoDB 2.4.4则需要安装Install-Package System.Runtime.InteropServices.RuntimeInformation,不然会报Could not load file or assembly 'System.Runtime.InteropServices.RuntimeInformation异常,另外需要在app.config中添加
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Runtime.InteropServices.RuntimeInformation" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.0" newVersion="4.0.1.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
- C#使用MongoDB的注意事项
- java使用mongoDB和freemarker的注意事项
- c# 操作mongodb时注意事项
- MongoDB Capped集合 使用注意事项
- Java中使用MongoDB连接池的注意事项
- c#事务的使用、示例及注意事项
- c#事务的使用、示例及注意事项
- C# 中的 @ 符号的使用及注意事项
- C# 中的 @ 符号的使用及注意事项
- C# 中的 @ 符号的使用及注意事项
- c#事务的使用、示例及注意事项
- c#事务的使用、示例及注意事项
- c#事务的使用、示例及注意事项
- c#事务的使用、示例及注意事项
- C#中的@符号的使用及注意事项
- c# lock的使用及注意事项
- C#中异常使用的注意事项
- C#中异常使用的注意事项
- Python35调用谷歌翻译
- 2017 ACM Arabella Collegiate Programming Contest F. Monkeying Around GYM101350F
- 第五周项目一——j建立顺序栈算法库
- 用命令行工具sqlite3打开数据库出现乱码的解决方案
- 导入excel 到sqlserver数据库 外部数据库驱动程序中(1)的意外错误 [问题点数:40分]
- C#使用MongoDB的注意事项
- jQuery-- ajax方法
- C++音频单声道、双声道之间的转换
- Timer::signalHandle()解析
- Objective-C 引用计数原理
- 安装python 2.7
- Unity3d 动画系统介绍
- 内存
- JavaScript原型彻底理解2---继承中的原型链