node -v
1.安装模块
npm i axios -S
2.导入模块
const axios=(axios)
3.使用模块
axios.get(url).then(res=>{})
1.定义模块
module.exports={
max(){},
randomStr(){}
}
2.导入模块
const utils==require('./utils.js')
3.使用模块
utils.max()
utils.randomStr()
1.进入项目目录(cd 路径)
2.node main.js
1.查询feedback中所有的信息
SELECT *FROM "feedback ` WHERE 1;
2.指定列查询
SELECT 'msg ', 'name `FROM `baizee` WHERE 1;
3.添加查询条件
select * from feedback where name='小白";
4查询msg中包含山的元素 (%代表是任意字符)
select * from baizee where msg like '%好%'
5.查询msg中包含山的元素 (…%代表以…结尾 _代表任意一个字符串)
select * from baizee where msg like '还_错%'
6.desc按时间排序降序
select * from baizee where 1 order by `datetime '
7.查询偏移2个截取3行
select * from baizee where 1 order by 'datetime ` desc limit2,3
明天再补。。。。