How to find data by querying date range parameters in MongoDB? I get the empty result. Could you please tell me what I am doing wrong. Thanks.
image

Here is my code:

{
“collection”:"****",
“aggregate”:[
{"$addFields":{
“ISOdate”: {
“$toDate”: {
“$toLong”: “$unix_date”
}
}
    }},
    {
        "$match":{
            "ISOdate":{"$gt":"{{ date }}")}
        }
    }
]
}

Try modifying your query like this:

{
“collection”:"****",
“aggregate”:[
{"$addFields":{
“ISOdate”: {
“$toDate”: {
“$toLong”: “$unix_date”
}
}
    }},
    {
        "$match":{
            "ISOdate":{"$gt":"{{ date }} 00:00:00")}
        }
    }
]
}