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
Deepak agarwal 9Deepak agarwal 9 

Query for Rejected Leads


A query which shows all rejected leads for a particular month.

NagendraNagendra (Salesforce Developers) 
Hi Deepak,

Try this sample code and modify it as per your requirement.
[SELECT (SELECT LeadId, CreatedDate, Field, OldValue, NewValue FROM LeadHistories WHERE CreatedDate >= :fromDate AND CreatedDate <= :toDate) FROM Lead]

Please mark this post as solved if it helps.

Best Regards,