WebStyles Posted September 22, 2011 Share Posted September 22, 2011 Just curious if anyone is using mongoDB, and how does it compare to mysql in terms of stuff we're so used to using, like mysql_real_escape_string, mysql_fetch_assoc, mysql_affected_rows, mysql_insert_id, mysql_num_rows, etc... Everyone boasts it's much faster (100 x they say), I'm just wondering, before I dwell into reading manuals, setting up a test zone and trying things out, if it's even worth considering for smaller scale projects like intranets for 200-300 people, (where every single click, update, change, etc.. is logged in one way or another, creating several selects and inserts per page, used intensively by 150 people 10 hours per day) Anyone out there with experience on mongoDB ? Troubles/benefits ? End result worth the hassle or only noticeable on huge systems ? Thanks Quote Link to comment Share on other sites More sharing options...
Maq Posted September 22, 2011 Share Posted September 22, 2011 Haven't personally used it, and I'm not sure if this helps answer your question(s), but there is a tutorial on PHPF with some info on MongoDB that might help: http://www.phpfreaks.com/tutorial/an-introduction-to-php-and-mongodb Quote Link to comment Share on other sites More sharing options...
WebStyles Posted September 22, 2011 Author Share Posted September 22, 2011 thanks Maq. Cool reading. Setup and usage is quite straight-forward... I'm currently at 40% of a large intranet system I'm building, and was considering a conversion to mongoDB before launching... This would not be too hard to code in because I have all the function files separate, so every select, update or insert can easily be found and converted to something else... No mention on replication/backups though, which worries me... I was considering a dual system. Option 1 would be to use mongoDB but replicate all data to a mysql server, just in case I change my mind and want to quickly convert back without the hassle of migrating databases... Option 2 would be to leave everything as is, continue development, but on every insert, also insert into a mongoDB system so I can play around with it on the side until I'm comfortable. I wonder if I can set up mysql triggers to update a mongoDB database... hmmm... The only drawback is my time frame for completing the job, otherwise I would be the first to start experimenting. Some features seem a bit "extreme" to me (although certainly useful in some situations), like if the database does not exist, it gets created on the fly... Could be very useful, but a simple typo would leave me with a useless new database... Will need to investigate more. thanks for the link. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.