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
Rajiv KocherlaRajiv Kocherla 

Fetching Issue

1. write a soql query to fetch users whole role is Manager and profile is Executive;
 2.write a soql query to fetch all opportunities which are owned by above users;
GulshanRajGulshanRaj
Hi Rajiv,

I hope this soql will help
select id,name  from opportunity where owner.userRole.Name='Manager' and owner.profile.Name='Executive'

Thanks 
Gulshan Raj 
https://www.linkedin.com/in/gulshan-raj