I am using to get records on the basis of empId and timestamp between two mongodb dates that is startDate and enddate. I am using groovy scripts.