I am using mongodb java driver thru maven repository (as below in pom.xml) to query transactions between date range with aggregate framwork. The java driver generates follo
I got it solved by removing the "" & $ prefix on the $date field of in $match. For you remove the same for $date, $gt & $lte
""
$
$date
$match
$gt
$lte
So that it should look like
db.transactions.aggregate( { "$match" : { 'created_at': { $gt: "2001-04-12T12:00:00.000Z", $lt: "2020-04-13T12:00:00.000Z" } } });