When comparing Postgres vs MarkLogic, the Slant community recommends Postgres for most people. In the question“What are the best ACID-compliant scalable databases?” Postgres is ranked 1st while MarkLogic is ranked 11th. The most important reason people chose Postgres is:
Built by passionate developers, available for free, and is well supported by its active community.
Ranked in these QuestionsQuestion Ranking
Pros
Pro Open Source
Built by passionate developers, available for free, and is well supported by its active community.
Pro Supports migration from other major proprietary and open source databases
With the extensive SQL support and migration tools, Postgres users are easily able to migrate their databases over to the Postgres database with little effort.
Pro JSON support
JSON support allows for Postgres to transfer data as raw text and without attributes and markup overhead. This will result in new levels of speed, efficiency and flexibility for developers.
Pro Highly scalable
Continues to work well under low or heavy loads in order to meet the users' need.
Pro Object-Oriented Database
You can reuse existing approved design table and extend its capability by inheritance. You can reuse ancestor method byy declaring new trigger for descendant but reuse ancestor trigger procedure. You can add, remove or override column constraint making it differ from its ancestor. Applying OOP with database design help me reuse, extend, and encapsulate business logic and end up a rapid design, and less errants. PostgreSQL is a powerful RDBMS while its OOP is sufficient for OOP modular design. Especially its Open Source ,and free.
Pro True ACID-compliance
Built in, so users won't have to worry about atomicity, consistency, isolation and the durability of the database.
Pro Multi-Version Concurrency Control (MVCC)
Postgres uses MVCC. For each user connected to the database the Postgres database shows a snapshot of the database at a particular instance. When the database needs to update an item it will add the newer version and mark the old version as obsolete. This allows the database to save overhead but requires a regulated sweep to delete the old, obsolete data.
Pro Multiple Language Interfaces
"There are interfaces for Java (JDBC), ODBC, Perl, Python, Ruby, C, C++, PHP, Lisp, Scheme, and Qt just to name a few."
Pro Great query planner
Unlike MySQL, you generally don't spend time on hinting the query planner in order to make PostGres perform well.
Pro RETURNING option on INSERT queries
For example:
INSERT INTO table (field_1, field_2, field_3) VALUES (value_1, value_2, value_3) RETURNING id;
Pro Search engine native
No other ACID database has even close to the text handling capabilities that are built-in to MarkLogic. Many multi-model databases rely on Lucene to provide text indexing, which leads to unnecessary latency and complexity.
Pro Massively scalable
Configuring MarkLogic for scale out is simple with both APIs and UI based mechanisms to add and manage cluster nodes that auto-shard and redistribute themselves for maximum efficiency.
Pro XML powerhouse
MarkLogic supports XML natively and adheres to all W3C standards surrounding XML. It even uses XQuery as a powerful application engine. Recent editions are also JSON native, which makes it fit in with modern JavaScript and web-centric applications.
Pro Uniquely offers full ACID transactions in a multi-model database
MarkLogic is the only Multi-model database in the world that is fully ACID and treats unstructured content as a first class citizen.
Cons
Con Overkill for simple setups
If a database will be doing many simple operations Postgres may be over-kill.
Con Vaccuuming can cause headaches
Con Can't be run as an embedded database
Con Enterprise focused
MarkLogic is more focused on the specific needs of enterprise customers who need ACID rigor and element level security. There are less costly options if eventual consistency and application-level security are good enough for you.
Con Proprietary
License is $18k/year
Con Too good to be true
If you are skeptical about product claims, MarkLogic may seem a bit too good to be true. MANY applications could benefit from implementing MarkLogic instead of creaky old RDBMS or immature NoSQL databases or even search engines like Lucene/Solr/Elastic.