You need to sign in to do that
Don't have an account?

Create Custom Object named "Training" with Fields Name, Email, Phone Number, Age, Account and Status. Name, Account are required fields and Account should be lookup with Account Object. Create a Batch class to verify the records created in last 24 hours
Create Custom Object named "Training" with Fields Name, Email, Phone Number, Age, Account and Status.
Name, Account are required fields and Account should be lookup with Account Object.
Create a Batch class to verify the records created in last 24 hours in training object and if any, create a respective contact record and send out an email to Account Owner saying that related contact is created.
The query will result Object Object only as we are referencing the parent object field. It works in Apex.
We are passing Training Account to contact Account. as we need Account while creating a Contact. If you dont want it you can remove that particular line but the contact will get created and you cannot see that Contact under the Account.
Let me know if you face any issues.
Thanks,
All Answers
Can you try the below batch class.
You can match other fields from Training to Contact. I have only matched Lastname with Training Name.
Let me know if you face any issues.
If this solution helps, Please mark it as best answer.
Thanks,
The query will result Object Object only as we are referencing the parent object field. It works in Apex.
We are passing Training Account to contact Account. as we need Account while creating a Contact. If you dont want it you can remove that particular line but the contact will get created and you cannot see that Contact under the Account.
Let me know if you face any issues.
Thanks,
The email should be sent to email of the owner of the Account. Can you check in junck or some other folders because this got worked in my org.
If you still face issue we can debug and check .
Thanks,
As this would be seperate question can you post it as new question so it avoids confusion.
Thanks,