mongodb - Efficient way to store and query tree-like hierarchical data -
please see image here:
https://picasaweb.google.com/108987384888529766314/cs3217project#5717590602842112850
so, can see image, trying store hierarchical data database. 1 publisher has may articles, 1 article has many comments , on. thus, if use relational database sql server, have publisher table, articles table , comments table. comments table grow , become large.
thus, there alternative allows me store , query such tree data efficiently? how nosql (mongodb)?
you can use adjacent lists hierarchical data. it's efficient , easy implement. works mysql. here link: http://mikehillyer.com/articles/managing-hierarchical-data-in-mysql/.
Comments
Post a Comment