You need to sign in to do that
Don't have an account?

How to filter in SOQL on count criteria ?
How to filter in SOQL on count criteria ?This Query give me info more than one review related list record on acocunt
SELECT Account_Name__c, count(id) FROM Review__c GROUP BY Account_Name__c HAVING Count(Account_Name__c) > 1
My question is how to ensure that duplicates are not part of below FOR query, please provide code or syntax to me.
for(Private_Account_Information__c reviewForVar : [select id , Account_Name__c , Subject__c, X20_Group__c, Current_Provider__c, DRAD__c, PVR__c, Service_Contract_Participation__c from Review__c where Account_Name__c!= null])
SELECT Account_Name__c, count(id) FROM Review__c GROUP BY Account_Name__c HAVING Count(Account_Name__c) > 1
My question is how to ensure that duplicates are not part of below FOR query, please provide code or syntax to me.
for(Private_Account_Information__c reviewForVar : [select id , Account_Name__c , Subject__c, X20_Group__c, Current_Provider__c, DRAD__c, PVR__c, Service_Contract_Participation__c from Review__c where Account_Name__c!= null])
For question 2: