PHP Classes

Title: MongoDB and PHP

Recommend this page to a friend!

  Latest classes All reviews   MongoDB and PHP   Latest classes Latest reviews   Best sellers ranking Best sellers ranking  


MongoDB and PHP


PHP books


Steve Francia



Release date

February 6, 2012



Sales ranking

Week: Not ranked All time: 399


July 29, 2015
  Post a comment Post a comment   See comments See comments (1)   Find where to Buy Now Find where to Buy Now  
Picture of Jose Gomez
Jose Gomez
MongoDB and PHP is a book that obviously describes how to use MongoDB with PHP. The target readers of this book are PHP programmers that are newbies in MongoDB. This book covers MongoDB basics as a noSQL database comparing it with SQL databases and PHP programming.

The book is divided in 4 chapters. The first chapter describes the difficulties to store objects in Relational databases. Since PHP programming can be object oriented, the book explains why relational databases are not the best approach for data storage in PHP.

MongoDB is a document based database, the relationship between document and objects is explained in the first chapter. MongoDB is optimized for CRUD operations (Create, Read, Update and Delete) throught an optimal interface, performance and simplicity for handling CRUD operations.

The second chapter is focused in the MongoDB basic. It explains how to install MongoDB driver for PHP in Linux, Mac OS and Windows, how to connect to a MongoDB from PHP, perform CRUD operations with PHP arrays with important tips for the developer like if you try to update a document doesn't exist it will be crated and the way the primary key is generated.

This chapter also covers the MongoDB shell for database manager administration and databases operations using JavaScript as MongoDB language.

It also explains how to perform queries to find data, pagination, dealing with ranges. It describes all the basic commands to perform queries and work with multiple documents.

Indexes are very useful in MongoDB, they are used for sorting and can be optimized for ascendent and descendent sorting. The developer can make references to other documents even if they do not exist or store them as raw.

Another important feature is the use of time epoch time, but with milliseconds resolution.

In third chapter it explains advanced topics such the use of regular expressions, they increase the performance with indexes and left to right searches.

The use of aggregation commands introduce the MapReduce concept and the feature of user defined functions for aggregations, the use of GridFS a network file system built on the top of MongoDB, replication and high availability features makes the horizontal scalability of MongoDB systems.

The last chapter enumerates different Mappers, tools and frameworks to work easier with MongoDB and PHP.

It is a good book describes the most important topics of MongoDB and it relationship with PHP. I missed more complex examples and complete easy projects in order the reader can understand and be familiar with MongoDB from a more practical way.

MongoDB and PHP is a great book that obviously describes how to use MongoDB with PHP. The target readers of this book are PHP programmers. It introduces MongoDB as document based database, how to install MongoDB drivers, perform simple queries and aggregation like MapReduce. This book also enumerates mappers, tools and frameworks.

So it is well recommended to all those that want or need to learn about how to use MongoDB with PHP.
  Post a comment Post a comment   See comments See comments (1)   Find where to Buy Now Find where to Buy Now  


1. Very good first step - Alberto Castro (2015-07-30 21:18)
MongoDB and PHP is a good first step to learn MongoDB... - 0 replies
Read the whole comment and replies

Post a comment

For more information send a message to info at phpclasses dot org.