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
sfdccoder1sfdccoder1 

Lead Convert trigger that sets converted account fields only if converted account is new. Possible?

I am trying to implement this by creating an Account "After Insert" trigger that queries the ConvertedAccountId field on existing leads and checks if some of them match the new Accounts Ids.
This query returns an empty set.
 
1. Should this set contain values or do I have a bug somewhere?
2. I think this has worked in a similar trigger I did before.
    Is it possible that SF changed the conversion order of execution i.e. the new leads are not accesible via select in Account "after insert" queries.
BritishBoyinDCBritishBoyinDC
Just to confirm - you have to enable triggers to fire on Account, Contact and Opportunity after lead conversion in the Lead Settings section (it is sometimes not even visible, and you have to request it from support)
sfdccoder1sfdccoder1

Do you mean the "Enforce Validation and Triggers from Lead Convert" option?

It's checked.