New answers tagged

1

The reason this isn't working for you is this condition: acc.OwnerId.ProfileId==salesprofileid As this logic is in (or called by) an Account Trigger, only the values on the triggered object (i.e. Account) are implicitly available in any of the Trigger context variables (like Trigger.New) You will need to query for the parent values for all Accounts in the ...


2

SOQL queries are inherently single-object. You are correct that there is no way to implement this requirement as written without using iteration. However, this requirement itself is rather suspect. If you have a need to perform the same query across multiple objects, you should at least evaluating using SOSL rather than SOQL. If you simply need to perform ...


Top 50 recent answers are included