Message Boards Message Boards

MongoDB and Mathematica

GROUPS:
Hi everyone,

I'm looking for a database link between Mathematica and MongoDB. Is it possible? I see nothing about this in the DatabaseLink reference. Any ideas?

Steeve
POSTED BY: Steeve Brechmann
Answer
5 years ago
Hi Steeve,

I am not aware of a direct link between mathematica and MongoDB but could I recommend using JLink and then writting your mongo interface through Java?

Even though it is not a complete solution I know MongoDB does have a REST interface that you could interface through... however it has no support for insert/update/remove operations... But you could read your data at least and you can use Mathematica's ability to communicate through HTTP requests to read the data.

If you aren't completely locked into Mongo you could also look at couchdb (http://couchdb.apache.org/) which does have a fully formed REST API. It also takes an optimistic approach to data and instead of locking an entire local instance of the database to write data it versions data which also allows for ACID compliance as opposed to Mongo's partial ACID compliance. All of this being said CouchDB does seem to only allow you to query through map/reduce (and often you just have to write the map function. I am also still not clear on how their indexing works, but it appears to index through the map functions that are written.. I really need to do something with this data store to understand how it works better).

All in all I have used mongo before and love it. I have not used couchdb yet but it could be an alternative if you aren't willing/can't create a java interface for mongodb.

Adam Martinek
POSTED BY: Adam Martinek
Answer
5 years ago

Hello! Old thread, but I recently made my MongoDB Mathematica driver open-source here: https://github.com/zbjornson/MongoDBLink.

POSTED BY: Zach Bjornson
Answer
2 years ago

Here is a related SE post: mathematica.stackexchange.com/questions/40731

POSTED BY: Rodrigo Murta
Answer
2 years ago

There is a good presentation with practical code examples about Mathematica with MongoDB here:

MongoDB with WL- .NB Presentation

POSTED BY: Daniel Carvalho
Answer
2 years ago

Wolfram Language 11.3 now has support for interfacing with MongoDB: http://reference.wolfram.com/language/MongoLink/guide/MongoLinkOperations.html

Answer
3 months ago

That's cool! Thanks for sharing this new feature.

POSTED BY: Rodrigo Murta
Answer
3 months ago

Group Abstract Group Abstract