function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Lance PraisLance Prais 

SOQL prospects from Acocunt

I am new to SFDC writing SOQL, I need to build a query that will search for all the accounts that are prospects and have bene modified in the last x amount of time

Is there any Examples or place I can look as I know this is a simple process but have limited time and need to fix a issue ASAP and will be going back to do training 

Thank you
Shiraz HodaShiraz Hoda
Hi Lance,

Run below query to fetch data.
 
List<Account> lstAcc = [Select id, Name from Account where type='Prospect' AND lastmodifieddate > 2022-09-14T07:05:10Z AND lastmodifieddate < 2022-09-14T07:10:10Z]; 

system.debug('List of account'+lstAcc);


If this helps, Please mark it as best answer.

Thanks!