);
mongoose.connection.on("open",function () {
console.log("数据库连接成功!")...:"String",default:"未知"},
},{
collection:"person"
});
//利用集合生成模板,接下来,所有的数据库的操作,如增删查改全部由该模型负责...2.一个数据库中可以存放多张表
3.每张表都有字段(比如姓名, 年龄)
4.表中会有一个特殊的字段(主键), 用于保证数据的唯一性
MySQL的管理系统: phpMyAdmin
通过代码操作数据库...select * from 表名 where 字段 = 值
例如: select * from student where gender = '女'
4.根据多个条件进行查找
select * from...between 值1 and 值2
例如: select * from student where age not between 24 and 25
7.根据多个条件中的某个条件, 进行查找
select