Using relative date in MongoDB aggregation


#1

I have a Mongo database. I want to get all records in a range between 3 days ago and to days ago. Sounds as a common request.
I have not figured out how to make it using gui and tried to use native query but it immediately converts relative dates like “yesterday” to a fixed day like 05.01.2017.
As I cannot use js in native query and write something like “new Date()” is there any way to make relative dates possible.
I could be done with some simple convention where you replace some MetabaseDate.daysAgo(3) to “03.01.2017” before running a query.

Looking forward to your reply, thanks for creating such a great tool.


Relative date filter in native Mongo queries