Hacker News new | past | comments | ask | show | jobs | submit login

what's the problem with mongo? which document database would be better if you'd use typescript? I'm using mongo with typegoose in development and I'm happy with it. I'm open to better alternatives



1. You end up doing more work in the end with mongo. Instead of SQL, you have to reinvent the wheel with new logic 2. It's not as reliable as a relational database 3. There are several ORMs in node that make using databases even easier like typeorm 4. A lot of databases support JSON now 5. Databases still perform better than Mongo in general 6. If you really need NoSQL, Cassandra tends to be better imo


1. Debatable, but my (biased) experience is the ease of change in an agile project favours databases with a flexible schema.

2. Reliability is not a pure function of whether you use SOL or NoSQL

3. ORMs hide but do not remove the need for schema management in SQL dbs. They often create more problems than they solve.

4. SQL databases support JSON because it my accurately reflects the programming model that programmers want to use. This is making an argument for NoSQL.

5. Which NoSQL you use is a matter of personal choice in many cases. I prefer MongoDB (I would say that though, I work there). Cassandra has some challenges as it is eventually consistent by design (and default). MongoDB is strongly consistent by design (and default) which makes reasoning about your programs easier.


1. As cludgy as SQL is, having to reimplement basic SQL queries ala reinventing wheels isn't very smart imo. It's worse than having an inflexible schema

2. I was only referring to mongo and not to NoSQL as a whole. Cassandra worked just as a advertised.

3. You don't have to use an ORM with a relational database just as you don't have to for mongo. There are other alternatives

4. JSON is no longer an advantage for NoSQL since it's supported by relational databases. It also means that relational databases as a whole can adapt to the market.

5. Which NoSQL you use and for what purpose matters, and it's not just "personal choice". NoSQL in general aren't the generic swiss army knives that relational DBs are. Each NoSQL project has different use cases, which in turn also have different levels of reliability and performance.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: