Posts List


mongoimport工具可以从指定的CSV, TSV 或者 JSON数据中导入到mongoDB。 而excel表格可以直接另存为csv格式。 $ mongoimport connected to: no collection specified! Import CSV, TSV or JSON data into MongoDB. options: -h [ --host ] arg mongo host to connect to ( <set name>/s1,s2 for sets) -u [ --username ] arg username -p [ --password ] arg password -d [ --db ] arg database to use -c [ --collection ] arg collection to use (some commands) -f [ --fields ] arg comma separated list of field names e.