I am having an issue with a validation on a field in my Case object.I have the below requirement.Can somebody help?
The Field should allow only a total 11 digits. These 11 digits can be divided into 3 parts: 1] The first 3 digits are the Prefix which are always unique 2] The next 7 digits is the Serial Number 3] The last digit is the Check digit For
- The first 3 digits are the Prefix which are always unique
- The next 7 digits is the Serial Number
- The last digit is the Check digit
For example if the user enters the value in the filed as 589 8114074 3: Disregard
Disregard the first 3 unique Prefix numbers and the last Check Digit [because that’s what we are going to find and match it with the actual check digit] Just
Just consider the 7 digit Serial Number, 8114074 and divide this by 7 [the number 7 is a constant, Mod7] The
The remainder determines the Check Digit Example
Example, Serial Number 8114074 when divided manually by 7 the remainder is 3. This
This remainder matches with the check digit of the field, hence the value 589 8114074 3 in the field should validate as correct. Any immediate help is appreciated.