You need to sign in to do that
Don't have an account?
Inderjit Singh Waraich
Custom metadata not available in Validation rule ?
I am working on Trailhead Module - Custom Metadata Types Basics and stuck on step 3 > Use Custom Metadata Types in Formulas, Default Values, and Validation Rules.
I am not able to find $CustomMetadata global variable in validation rule and it is throwing error. Any help will be appreciated.
I am not able to find $CustomMetadata global variable in validation rule and it is throwing error. Any help will be appreciated.
All Answers
Sorry for this issue you are facing.
The reason being why the above error is thrown is there are no custom metadata types created in your Org.
First, create custom metadata types as suggested in the previous steps then you will be able to see the $custom metadata global variable in the validations.
Please find the sample images from one of my dev org's which I tried just now.
Hope this helps.
Kindly mark this as solved if the reply was helpful so that it gets removed from the unanswered queue which results in helping others who are facing a similar issue.
Thanks,
Nagendra
could you please try same in Trailhead playground org? I am not able to see custom metadata there.
I tried in developer edition it worked.
Thanks
I am able to do the same successfully in trailhead playground as well.
Please find the attached images for the same.
You can find the URL which indicates this is a trailhead playground.
Hope this helps.
Kindly mark this as solved if the reply was helpful.
Thanks,
Nagendra
Maybe there might be something which got updated with trailhead playgrounds.
I am glad that it worked for you in a new trailhead playground.
May I suggest you please go ahead and mark this post as solved so that it gets removed from the unanswered queue which results in helping others who are facing a similar issue.
Thanks,
Nagendra