Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Databases

I will be making a large accounting software using PHP. So I am wandering which database to use?

I will be making a large accounting software using PHP. So I am wandering which database is more secure, easy and much powerful to use? Right now I know MYSQL. But from many forums I find that it is backdated. So which is more powerful, easy and secure to use? Thank You

2 Answers

Ken Alger
STAFF
Ken Alger
Treehouse Teacher

Shubroto;

I am a huge NoSQL (MongoDB) fan and would certainly encourage you to go through the new Mongo Basics course. There are other NoSQL options available as well, but I will concentrate on MongoDB here.

With that being said, applications like double entry accounting systems are not MongoDB's strong suit. Why not? Three main reasons that I can think of.

  1. While most real world data is not tabular, accounting system data is. Thus it is a great use case for a relational database.
  2. Accounting systems have complex multi-row transaction operations. MongoDB's support for transactions is limited in order to provide better horizontal scaling. Thus not being an ideal fit.
  3. Your database will likely not be huge and, therefore, not require MongoDB's sharding capabilities.

For the accounting system then I would steer you towards a relational database and MySQL would be well suited for that. There is SQL Basics course on Treehouse that is a great starter for relational databases. Depending on your use case for the application a combination of a NoSQL and SQL databases is often used, with SQL handling transactions (accounting) and NoSQL (MongoDB) handling other information.

In terms of power, ease of use, and security, I think they are likely equivalent given a similar knowledge base on each system. It is more of a matter, in my opinion, of choosing the correct tool for the job.

Hope that helps and post back if you have further questions.

Happy coding,
Ken

Nathan Tallack
Nathan Tallack
22,160 Points

A MongoDB course was just released. Spend 90 mins going through that and you will have another perspective to work with at least. :)