Will it be the equivalent of this SQL statement?
Select * from the example WHERE date = '2011-09-21'
db.example.find({date: dateobject});
In the case of MongoDB + PHP, you want to use the [MongoDate][2] class to represent these dates. Other language drivers typically use a language date construct.
I would also like to know the syntax between the request.
MongoDB does not have a between clause.
To use More, you will need to use one of the query operators. See here for more details. A simple example:
db.example.find({ date: { $gt: lowdate, $lt: highdate } });
Gates vp
source share