I’m going nuts trying to find info on this and nothing seems to be working. How do I export my mongodb from my development build on Windows to a json or csv file?
If I had to make a guess install the full MongoDB on Windows and use mongoexport:
Now the next question - how to get mongoexport connected to the database and collection(s) you created inside of the Meteor development package - I haven’t figured that out yet.
Connection properties for meteor - localhost, port - 3001. But you need starting meteor on your project before connect
Use a GUI application for MongoDB (like MongoChef for example).
Start your meteor application.
Connect to localhost:3001
In MongoChef, or equivalent, select a collection and then “Export”, choose format (JSON or CSV).
Thanks for the suggestion. I realized my initial problem was that I didn’t have mongo installed on my machine. The connection between meteor mongo and full mongo was lost on me. So I installed that and was able to get the export. Now importing to a production database on meteor.com…that’s another issue. I have no idead how to do that. I know the command, but I authenticate at all. I have used the
-u command and have seend the producction url with the user name and password but it’s not working. I read somewhere it’s time sensitive but no matter how fast I think I’m copying and pasting it’s just not working.
Not following you … meteor comes with mongo.
Anyway, I found this instruction (I haven’t tested it myself)
I tried to run mongoexport, mongodump…anything really and wasn’t getting any results. I was getting undefined errors. I saw @datrimble 's suggestion and installed the full MongoDB package for Windows. After that (and adding the folder location to my
PATH ) I was able to access the regular Mongo commands. Seemed like the meteor implementation is very limited???
Running the following results in
ReferenceError: mongoexport is not defined
That’s from the meteor mongo shell…exiting that and running
meteor mongoexport --args gives me `meteorexport’ is not a Meteor command.
I’ll give your link a shot, thanks!