Reputation: 53
I try to import a CSV file into mongoDB with the mongoimport
utility like so
C:\Program Files\MongoDB\Server\3.2\bin>mongoimport --db vijay --type csv --headerline --file H:\all lab work\mongo\sampledata.csv
But the above command results in the following error
error validating settings only one positional argument is allowed when input is .csv
Upvotes: 1
Views: 1690
Reputation: 35398
I guess you have to pass the file in quotes due to the space in the path like so
C:\Program Files\MongoDB\Server\3.2\bin>mongoimport --db vijay --type csv --headerline --file "H:\all lab work\mongo\sampledata.csv"
Upvotes: 1