
Salesforce APEX Trigger for Unique Identifier
- or -
Post a project like this1343
€251(approx. $290)
- Posted:
- Proposals: 6
- Remote
- #3483938
- OPPORTUNITY
- Awarded
Certified Zoho Consultant | Zoho one | Zoho CRM | Zoho CRMPlus | Zoho People | Zoho Recruit |Salesforce Sales Cloud


Salesforce Certified Developer|⚡️Lightning| LWC| Administrator| Integration Expert
#1 Salesforce CRM Specialist | 18xCertified Salesforce Architect | Integration Expert

58420049261767079536786935966615670178





Description
Experience Level: Entry
Need support with a Salesforce APEX trigger that does the following:
The goal of the class is to define a unique identifier for each account record that does not have an unique identifier defined yet before create/update
-Setup a new Salesforce Developer org
-Create a text(255) custom field on Account object called Unique Account Id
-Define a custom metadata type (Prefix Settings) with the following fields:
* Label - Account
* Setting Name - Account
* Prefix - AID
* Starting Number - 1000000001
-Write a APEX trigger and methods to insert a new 'Unique Account Id' for each new or updated account record with an empty 'Unique Account Id'
- Unique Account Id should be populated based on the respective custom metadatatype record of the related object with the prefix (AID) based on the prefix field and the number based on the starting number like AID1000000001
- If there are already accounts with a 'Unique Account Id' populated it should add 1 to the highest one for new or updated records with an empty 'Unique Account Id' field like AID1000000004
- If accounts are created or updated via bulk upload the 'Unique Account Id' must be set according above requirements for all records in the bulk transaction.
Requirements:
- Test class with 100% coverage
- Unmanaged package with the created metadata deployable to other environments
- Trigger pattern according best practices, handler in apex class
- Each step in a separate method
- Class should be easy to modify for other objects, like contact
The goal of the class is to define a unique identifier for each account record that does not have an unique identifier defined yet before create/update
-Setup a new Salesforce Developer org
-Create a text(255) custom field on Account object called Unique Account Id
-Define a custom metadata type (Prefix Settings) with the following fields:
* Label - Account
* Setting Name - Account
* Prefix - AID
* Starting Number - 1000000001
-Write a APEX trigger and methods to insert a new 'Unique Account Id' for each new or updated account record with an empty 'Unique Account Id'
- Unique Account Id should be populated based on the respective custom metadatatype record of the related object with the prefix (AID) based on the prefix field and the number based on the starting number like AID1000000001
- If there are already accounts with a 'Unique Account Id' populated it should add 1 to the highest one for new or updated records with an empty 'Unique Account Id' field like AID1000000004
- If accounts are created or updated via bulk upload the 'Unique Account Id' must be set according above requirements for all records in the bulk transaction.
Requirements:
- Test class with 100% coverage
- Unmanaged package with the created metadata deployable to other environments
- Trigger pattern according best practices, handler in apex class
- Each step in a separate method
- Class should be easy to modify for other objects, like contact

Frank V.
97% (15)Projects Completed
11
Freelancers worked with
9
Projects awarded
57%
Last project
8 Feb 2023
Netherlands
New Proposal
Login to your account and send a proposal now to get this project.
Log inClarification Board Ask a Question
-
There are no clarification messages.
We collect cookies to enable the proper functioning and security of our website, and to enhance your experience. By clicking on 'Accept All Cookies', you consent to the use of these cookies. You can change your 'Cookies Settings' at any time. For more information, please read ourCookie Policy
Cookie Settings
Accept All Cookies