Difference between MongoDB, CouchDB and MySQL

MongoDB is most popular database now days in software and web development. MongoDB (from “humongous”) is a scalable, high-performance, open source NoSQL database. This is Written in C++ languages.In this tutorial we will discuss features of mongoDB comparison between MongoDB vs CouchDB and MySQL.

Main featured of mongo db
Document-oriented
  • Documents (objects) map nicely to programming language data types
  • Embedded documents and arrays reduce need for joins
  • Dynamically-typed (schemaless) for easy schema evolution
  • No joins and no multi-document transactions for high performance and easy scalability
High performance
  • No joins and embedding makes reads and writes fast
  • Indexes including indexing of keys from embedded documents and arrays
  • Optional streaming writes (no acknowledgements)
High availability
  • Replicated servers with automatic master failover
Easy scalability
  • Automatic sharding (auto-partitioning of data across servers)
  • Reads and writes are distributed over shards
  • No joins or multi-document transactions make distributed queries easy and fast
  • Eventually-consistent reads can be distributed over replicated servers

Checkout other Recommended Tutorials,

  • Top 6 RESTful API Frameworks for PHP

    MongoDB vs CouchDB vs MySQL Comparison Chart

    Difference between MongoDB vs CouchDB vs MySQL

     CouchDBMongoDBMySQL
    Data ModelDocument-Oriented ( JSON)Document-Oriented BSON)Relational
    Data Typesstring,number,boolean,array,objectstring, int, double, boolean, date, bytearray, object, array, otherslink
    Large Objects (Files)Yes (attachments)Yes (GridFS)Blobs
    Horizontal partitioning schemeCouchDB LoungeAuto-shardingPartitioning
    ReplicationMaster-master (with developer supplied conflict resolution)Master-slave and replica setsMaster-slave, multi-master, and circular replication
    Object(row) StorageOne large repositoryCollection-basedTable-based
    Query MethodMap/reduce of javascript functions to lazily build an index per queryDynamic; object-based query languageDynamic; SQL
    Secondary IndexesYesYesYes
    AtomicitySingle documentSingle documentYes – advanced
    InterfaceRESTNative drivers; REST add-onNative drivers
    Server-side batch data manipulation?Map/Reduce, server-side javascriptYes (SQL)
    Written inErlangC++C++
    Concurrency ControlMVCCUpdate in Place 
    Geospatial IndexesGeoCouchYesSpatial extensions
    Distributed Consistency ModelEventually consistent (master-master replication with versioning and version reconciliation)Strong consistency.  Eventually consistent reads from secondaries are available.Strong consistency.  Eventually consistent reads from secondaries are available.

One thought on “Difference between MongoDB, CouchDB and MySQL

Leave a Reply

Your email address will not be published. Required fields are marked *