Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Clearly stackexchange is showing pro-db bias. I'm a huge fan of unstructured data in filesystems as well, that's how the service behind my prototypesapp.com is built.

I also happen to think MySQL-backed websites are the bane of the internet, further testament to the pro-db bias of the average web developer.

A properly built sql store (or, increasingly, nosql) is definitely a necessity for large service. But what is "large"?

I once heard the rule of thumb that a db is necessary when the size of the data you store in it becomes larger than the size of the db code. I kind of like it.



It really depends on your structure I think. In the days of PHP3 I saw a lot of developers that built .txt-backed websites, with complicated parsing that would break when you looked at it.

In my opinion, they would have been better of with a database, or a more clever design like yours probably is.

A lot of my first work was rewriting PHP3 sites that used text-files to PHP4 with MySQL. Some of them had 200mb articles in text-files, and for every request they parsed this file, and didn't know why it was slow.


Unstructured data is as bad as unstructured code. Typically, your data will become more complex over time, and structure helps a lot with ensuring that this is not a painful thing to do. Relational databases are well-studied and present a well-understood abstraction, with design patterns (normal forms) that significantly improve the maintainability of databases. Sure, relational DBs are not the only solution; I personally find Lisp s-expressions to be an easier to use Q&D store (of course, I am also a Lisp programmer, and most of my code does not have to deal with untrusted data), and lots of people are using YAML these days (and of course, there is XML).


> Clearly stackexchange is showing pro-db bias.

If the question is "why use a database", don't you expect pro-DB answers?




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

Search: