Live data from Hacker News

Picking SQL or NoSQL

compose.io

11–13 of 13 posts

Re: Picking SQL or NoSQL

#12
post #11

Basically if you need to model any kind of relationship between objects then NoSQL will start to hurt and hurt hard!

That's not always true, of course. NoSQL databases can usually handle 1st level relationships just fine. The problem arises when the related item needs to be it's own entity.

For example, if you have a table of users who have permissions represented by text, that's really easy in a NoSQL database, as most of them provide some kind of list datatype (list in cassandra, arrays in mongo, list in redis). The problem arises when consumers of the database need to be able to add or remove from the set of possible permissions. If it's limited forever to 'read'/'write'/'execute', or is unlimited, you're golden! But if it's some sort of system where an admin needs to be able to dynamically create customized permissions, an RDBMS will be the clear cut winner.

Re: Picking SQL or NoSQL

#13
It's odd that he put NoSQL at lower level of abstraction than SQL. In a way, it makes sense, because yes you do have to reimplement many SQL things.

But I always thought that the attraction to NoSQL was that you didn't have to unravel your application's objects into tables. You just stuck them in there. You worried about reports later.

Post reply on HN