Lookup and group operations

I have 2 collections (orders containing products Id and the date of the order (ISODate)) and customers that include the order as a field reference to the order collection.
At first, I made a lookup operator to link between the two collections, then I wanted to group the result by month or maybe year, and an error msg:“PlanExecutor error during aggregation:: caused by:: can’t convert from BSON type array to Date” So, I tried with a date as a Date type but I have the same error

Hi @Malika_Taouai ,

Can you share sample documents and the aggregation used?

Thanks
Pavel

1 Like

Hi ^^,
I accidentally post the same post twice, so I mentioned you in the right one.
Thank…