You need to sign in to do that
Don't have an account?
Joseph Barbato 5
Compare records with same field value from different Objects
Hello friends, I've been having an issue comparing a set of records across different objects. I need to retrieve a list of Lead Records where Lead.Email is the exact value as the email for a corresponding Person Account.
I've tried doing this in Excel via a VLOOKUP, but the dataset is too large and will not work in Excel. I'm new to SOQL, so I'm wondering if this is possible.
I'd need to retrieve a List of all Person Accounts where the email = Lead.Email with the following fields selected: Account ID, Account Name, Account Owner, Person_ID__pc.
I've tried doing this in Excel via a VLOOKUP, but the dataset is too large and will not work in Excel. I'm new to SOQL, so I'm wondering if this is possible.
I'd need to retrieve a List of all Person Accounts where the email = Lead.Email with the following fields selected: Account ID, Account Name, Account Owner, Person_ID__pc.
Hi Joseph
Please run this code in your Org
.
Kindly let me know if it helps you and please mark as Best Answer.
Thanks and Regards,
Biswojeet
All Answers
Hi Joseph
Please run this code in your Org
.
Kindly let me know if it helps you and please mark as Best Answer.
Thanks and Regards,
Biswojeet
Hello Joseph
Then Click on Developer console. Then press cntrl+E.
Then the annonomous window will be opened.
Then paste the code there. Then Click on "Execute".
Kindly let me know if it helps you and please mark as Best Answer.
Thanks and Regards,
Biswojeet
"Line: 14, Column: 5
Variable does not exist: accountList"
"Line: 14, Column: 5
Variable does not exist: accountList"
Hi Joseph,
Please use this line.
List<Account> accountList = new List<Account>();
Thanks,