mongodb导入全栈商城的goods和users数据

 

> show dbsshow dbs
admin 0.000GB
config 0.000GB
local 0.000GB
> use dumalluse dumall
switched to db dumall

 

db.createCollection('goods')

db.createCollection('users')

 

 

root@izuf61quxhnlk8haul3v64z wj]# mongoimport --db dumall --collection goods --file dumall-goods
2018-12-01T22:49:00.049+0800 connected to: localhost
2018-12-01T22:49:00.064+0800 imported 17 documents
[root@izuf61quxhnlk8haul3v64z wj]# mongoimport --db dumall --collection users --file dumall-users
2018-12-01T22:49:16.513+0800 connected to: localhost
2018-12-01T22:49:16.529+0800 imported 1 document

posted @ 2018-12-01 22:52  b02330224  阅读(341)  评论(0编辑  收藏  举报