mongodb-error validating settings: only one positional argument is allowed

前端 未结 6 1992
孤独总比滥情好
孤独总比滥情好 2021-02-08 09:35

I just moved to a new laptop which had mongo 3.0.0 I believe. On the new laptop I have mongo 3.0.4. and trying the script that was working on the old laptop is giving me errors

6条回答
  •  Happy的楠姐
    2021-02-08 10:05

    If you get this error while inserting fields with --fields, the probable reason might be you are using spaces to do that.

    Both -f and --fields should work in those cases Using Mongo Version 3.0.6

    mongoimport --db logs --collection action_logs --type tsv -f updated_at ,transaction_time ,origin  --file parsed.tsv
    mongoimport --db logs --collection action_logs --type tsv -f updated_at,transaction_time,origin  --file parsed.tsv
    

提交回复
热议问题