I'm trying to query the Products that has more than 3 Quantity
Below is my query:
Set<Id> extras = new Map<Id, AggregateResult>([
SELECT Product2Id
FROM OpportunityLineItem
WHERE Product2Id In: oppIds
GROUP BY Product2Id
HAVING SUM(quantity) > 3
]).keySet();
Any ideas on why I'm having
FATAL_ERROR|System.ListException: Row with null Id at index: 0