1

What is the difference between relational(MySql) and unrelational database(MongoDb)

closed as too broad by RolandoMySQLDBA, Max Vernon, Taryn, Mark Storey-Smith, Jon Seigel Oct 4 '13 at 3:10

Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

2

A relational database (the concept) is a data structure that allows you to link information from different 'tables', or different types of data buckets. A data bucket must contain what is called a key or index (that allows to uniquely identify any atomic chunk of data within the bucket). Other data buckets may refer to that key so as to create a link between their data atoms and the atom pointed to by the key.

A non-relational database just stores data without explicit and structured mechanisms to link data from different buckets to one another.

Check this link to learn more about MongoDb Link 1

Also check this link for more details Link 2

When should you use MySQL?

If your data structure fits nicely into tables and rows, MySQL will offer you robust and easy interaction with your data. If it's performance that is your concern, there is a good chance you don't really need MongoDB. Most likely, you just need to index your data properly. If you require SQL or transactions, you'll have to stick with MySQL.

When should you use MongoDB?

If your data seems complex to model in a relational database system, or if you find yourself de-normalizing your database schema or coding around performance issues you should consider using MongoDB. If you find yourself trying to store serialized arrays or JSON objects, that's a good sign that you are better off MongoDB. If you can't pre-define your schema or you want to store records in the same collection that have different fields, that's another good reason.

0

One follows th relational Theorem as per Coods theorem (http://en.wikipedia.org/wiki/Codd's_theorem).

Obviously Non-Relational databases do not follow this. They mostly store data as documents and have problems with fast extensive query and transformation, as well as not necessarily following ACID conventions.

Now, you want a "explain me databases in one sentence"? Sorry, will not happen.

Not the answer you're looking for? Browse other questions tagged or ask your own question.