165k views
4 votes
In a custom order management application, Universal Containers requires that the Product Name and Product Code are consistent according to a custom object set up with valid Product Name and Product Code combinations. When a user enters an order, the system should check to ensure that the Product Name and Product Code entered are valid. Which feature would a developer use to accomplish this?

1) a validation rule with the REGEX function
2) a formula field with the VALIDATE function
3) a validation rule with the VLOOKUP function
4) a formula field with the IF function

1 Answer

5 votes

Final answer:

A validation rule with the VLOOKUP function can be used to ensure the Product Name and Product Code entered are valid according to a custom object in Universal Containers' order management application.

Step-by-step explanation:

To ensure that the Product Name and Product Code entered in the order management application are consistent with the valid combinations set up in a custom object, a developer can use a validation rule with the VLOOKUP function. This function will check the entered Product Code against a table of valid Product Name and Product Code combinations. If there is no match found, the validation rule will return an error, preventing the record from being saved. A validation rule is a declarative way to enforce data integrity rules in Salesforce without writing any code.

User Jolanda
by
9.0k points