+ Start a Discussion
notsosmartnotsosmart 

apex reference to converted leads

My procedure needs to filter out converted leads from my lookups.  I've noted that the Lead status field piciklist includes a 

field Labeled Converted but I don't know the coding reference for my SOQL statement.

 

If I filter by the status values that are checked as converted, it still gets one that is not checked on the status.  

 

Id like to understand how this work anyway in order to write clean code because I'm thinking there is another reference that is more reliable.

 

Thanks.

Best Answer chosen by Admin (Salesforce Developers) 
crop1645crop1645

[select id, firstname, lastname, email from Lead where isConverted = false]

All Answers

crop1645crop1645

[select id, firstname, lastname, email from Lead where isConverted = false]

This was selected as the best answer
notsosmartnotsosmart
Thanks. That's it. I forgot about that convention.