C++中读取文件可以采用几个函数分别为,_findfirst、_findnext、_findclose。其中还要借助结构体 struct _finddata_t,_finddata_t主要用来存储各种文件的信息。 struct _finddata64i32_t { unsigned attrib; ...
分类:
编程语言 时间:
2020-08-21 16:43:25
阅读次数:
156
1.数据库1.创建数据库语法usedatabase_name示例>showdbs;admin0.000GBconfig0.000GBlocal0.000GB>useajingswitchedtodbajing>showdbs;admin0.000GBconfig0.000GBlocal0.000GB>db.mycollection.insert({"name":"ajing
分类:
数据库 时间:
2020-08-20 18:37:34
阅读次数:
69
1.什么是聚合聚合是MongoDB的高级查询语言,它允许我们通过转化合并由多个文档的数据来生成新的在单个文档里不存在的文档信息。MongoDB中聚合(aggregate)主要用于处理数据(诸如统计平均值,求和等),并返回计算后的数据结果,有点类似sql语句中的count(*)。在MongoDB中,有两种方式计算聚合:Pipeline和MapReduce。Pipeline查询速度快于MapReduc
分类:
数据库 时间:
2020-08-19 20:09:42
阅读次数:
128
6.mongoDB的java客户端1.springboot操作mongodb1.maven配置<dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-data-mongodb</artifactId></depend
分类:
数据库 时间:
2020-08-19 20:07:22
阅读次数:
187
6.mongoDB的java客户端1.springboot操作mongodb1.maven配置<dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-data-mongodb</artifactId></depend
分类:
数据库 时间:
2020-08-19 20:07:05
阅读次数:
176
6.mongoDB的java客户端1.springboot操作mongodb1.maven配置<dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-data-mongodb</artifactId></depend
分类:
数据库 时间:
2020-08-19 20:06:40
阅读次数:
107
var factory = new ConnectionFactory(); factory.HostName = "localhost"; factory.UserName = "admin"; factory.Password = "admin"; using (var connection = ...
分类:
其他好文 时间:
2020-08-18 13:55:53
阅读次数:
61
1.什么是Change Stream? Change Stream是MongoDB用于实现变更追踪的解决方案,类似于关系型数据库的触发器,但原理不完全相同 | | Change Stream | 触发器 | | | | | | 触发方式 | 异步 | 同步(事务保证) | | 触发位置 | 应用回调 ...
分类:
数据库 时间:
2020-08-18 13:27:20
阅读次数:
78
1.问题背景 最近测试用mongoshake工具做MongoDB数据迁移,mongoshake在迁移完成提供了一个脚本comparison.py来做数据校验,在校验过程中发现结果比对存在一个库数据不一致,下意识以为mongoshake存在缺陷导致迁移丢数据,理论上这种基础功能不应该存在错误,多次重新 ...
分类:
数据库 时间:
2020-08-17 17:01:03
阅读次数:
80
value其实就是C#类里边的属性,比如,我们有个类叫Student,cs,里边有int类型名为“ID”的属性,我们在构造函数里接收传入的值然后为这个属性赋值,然后实例化类,传入一个1,这是value就是1;如下: public class Student { public Student(int ...