You need to sign in to do that
Don't have an account?
Mujahid Islam Khan
Formulas & Validations Badge unable to complete Create Validation Rules
This challenge seems simple enough but I'm stuck and any help would be appreciated.
So the Challenge is Create a validation rule to check that a contact is in the zip code of its account. here is the question below:
To complete this challenge, add a validation rule which will block the insertion of a contact if the contact is related to an account and has a mailing postal code (which has the API Name MailingPostalCode) different from the account's shipping postal code (which has the API Name ShippingPostalCode).Name the validation rule 'Contact must be in Account ZIP Code'.
A contact with a MailingPostalCode that has an account and does not match the associated Account ShippingPostalCode should return with a validation error and not be inserted.
The validation rule should ONLY apply to contact records with an associated account. Contact records with no associated parent account (hint: you can use the ISBLANK function for this check) can be added with any MailingPostalCode value
My work is..
Rule Name Contact_must_be_in_Account_ZIP_Code Active [Checked]
Error Condition Formula AND(
2
NOT( ISBLANK( AccountId ) ),
3
MailingPostalCode <> Account.ShippingPostalCode
4
)
Error Message: Invalid Zip Code
I am getting below error
Challenge Not yet complete... here's what's wrong:
The validation rule failed to enforce the business logic
Could you help on it.
So the Challenge is Create a validation rule to check that a contact is in the zip code of its account. here is the question below:
To complete this challenge, add a validation rule which will block the insertion of a contact if the contact is related to an account and has a mailing postal code (which has the API Name MailingPostalCode) different from the account's shipping postal code (which has the API Name ShippingPostalCode).Name the validation rule 'Contact must be in Account ZIP Code'.
A contact with a MailingPostalCode that has an account and does not match the associated Account ShippingPostalCode should return with a validation error and not be inserted.
The validation rule should ONLY apply to contact records with an associated account. Contact records with no associated parent account (hint: you can use the ISBLANK function for this check) can be added with any MailingPostalCode value
My work is..
Rule Name Contact_must_be_in_Account_ZIP_Code Active [Checked]
Error Condition Formula AND(
2
NOT( ISBLANK( AccountId ) ),
3
MailingPostalCode <> Account.ShippingPostalCode
4
)
Error Message: Invalid Zip Code
I am getting below error
Challenge Not yet complete... here's what's wrong:
The validation rule failed to enforce the business logic
Could you help on it.
Please try this:
AND(
NOT(ISBLANK( AccountId )),
NOT(Account.ShippingPostalCode = MailingPostalCode))
Thanks, Jawaad