4 ms·
This is not to say Redis is better or MongoDB is better, it's just a different point of view Sure. I didn't mean to imply any criticism, or imply that you were
by davidmathers 17y ago
This is not to say Redis is better or MongoDB is better, it's just a different point of view
Sure. I didn't mean to imply any criticism, or imply that you were criticizing. I, personally, haven't figured out when/where to use a document database like Mongo or Couch, but I figure they must be a good fit for someone's use case or people wouldn't be making them.
The thing that I have trouble with is that in every presentation or discussion I've seen of these alternative databases the people presenting them never seem to have an understanding of what a relational database is. And because the language in these presentations is always so obfuscated (to me) I'm never able to get a clear idea of what exactly they do and where they stand in relation to a relational DBMS (by which I mean the platonic ideal of a relational DBMS, not SQL).
Redis is interesting to me because it's unlike the others. And because of the way it's unlike the others. It has data structures with operations. In other words it's a DBMS, or "structure server" in your terminology.
At its core a relational DBMS is just a "structure server" with one kind of data structure, called a relation, and operations on that structure. And that's all it is really. Others probably disagree but I think even a query language is optional. The query language is just the UI.
SQL confuses everything. A SQL DBMS is a relational DBMS (almost) plus a boatload of additional functionality. I see your point about how Mongo is like SQL because it has named values and queries, but it doesn't have relations or relational operators.
In summary: Mongo may have some SQL like features, but they aren't relational features. The set features of Redis on the other hand are getting close to the building blocks of the core of an actual relational DBMS.
- antirez 17y agoOk, so there is some terminology mismatch here, sorry but this is my fault I think since when in the article I speak of RDBMS I think to Oracle, MySQL, ..., relational SQL databases. Btw in Wikipedia I read: "A short definition of an RDBMS may be a DBMS in which data is stored in the form of tables and the relationship among the data is also stored in the form of tables." Basically once you have the idea of tables, a lot of things about SQL databases are automagically needed: queries and indexes for instance. Also MongoDB supports _id fields specifically. And tables, so you can build tables that have as unique goal to describe relations among other tables. So MongoDB is an RDBMS following the definition of Wikipedia, that may be wrong of course (and if so should be fixed). With Redis Sets probably it is possible to build the storage system of an RDBMS just with software on the client library side, but it can't be considered an RDBMS AFAIK because of the lack of tables, and Sets can't be considered tables since they don't have the field:value idea at all, but are just collection of elements. Btw in the future I'll try to use the term RDBMS better, and will refer to Oracle, MySQL, Firebird, DB2, and so forth, as SQL databases.