You need to sign in to do that
Don't have an account?
Saurabh Smarty
Query not giving currect results
Hi All,
I am trying to get a list of all opportunities who have associated events and the event status is completed, below is the query I made :
SELECT Id,Name,Date_of_Last_Completed_Event__c,(select id, Status__c, EndDateTime from events where Status__c = 'Completed') from Opportunity where Date_of_Last_Completed_Event__c = null
While running the query in query editor its fetching those opportunites as well who have no associated events which is not needed and because of this its fetching more than 1 lac records. I am not sure what is wrong here, any help is greatly appreciated !!!
I am trying to get a list of all opportunities who have associated events and the event status is completed, below is the query I made :
SELECT Id,Name,Date_of_Last_Completed_Event__c,(select id, Status__c, EndDateTime from events where Status__c = 'Completed') from Opportunity where Date_of_Last_Completed_Event__c = null
While running the query in query editor its fetching those opportunites as well who have no associated events which is not needed and because of this its fetching more than 1 lac records. I am not sure what is wrong here, any help is greatly appreciated !!!
Please try below query: PLease mark as best answer if helped.
Regards,
Ramakant