Salesforce Certified Advanced Administrator – Data Management
May 16, 2023

1. Data Management Introduction

All right, so now it’s time to dive into the data management knowledge area for the advanced administrator exam. Now, there’s just one bullet point here for data management, and it’s also weighted at the same percentage as the Sales cloud and service cloud applications knowledge areas which we previously have gone through in this course.

So we’ve already covered a great amount of ground, but there’s still yet more to unearth here in this data management knowledge area. And this is a very important topic because Salesforce is worthless if the data is not good. And so this is a very important skill for advanced administrators to master. And so we’re going to be talking about the topics that are hinted at inside this one singular bullet point, which has to do with explaining the tools and best practices for improving and enriching data quality.

Now, how that’s done, for example, will be through validation rules. We’ll definitely be talking about those. We’ll also be talking about duplicate management. And I’m excited to be diving into that because I’ve recently dealt with duplicate management in the real world on a project that I’m working on as far as duplicate rules, matching rules, and then duplicate record sets and duplicate record set items, that rabbit hole goes very deep. So I’m going to take you down that hole and hopefully will come out of it unscathed and without as many duplicates in our lives then as well for enriching data and archiving data as well. So hopefully by the end of this knowledge area, your own selfware skills will be enriched as well as your data. So let’s get started with data management, and we’re going to get started with validation rules.

2. Validation Rules

Means by which you can make sure that users enter data correctly inside of Salesforce is by way of validation rules. Now there’s any number of ways that you can create validation rules to verify, for example, that phone numbers entered in the correct format or that websites contain. com or net, for example. And the main idea with validation rules is that that these are set at the object level and so you can go into object manager and select an object and I’ve got the account object open here and then select validation rules.

Now we’ve not created any validation rules yet on the account object but to do so you just click new and that brings up the validation rule window. Now there’s two primary steps that you do with the validation rule. You need to name it and then you need to create a formula and it’s a condition that when it’s equals true, that means that there’s some sort of data error and then you’ve got your error message that you create down here below.

Now you may already be well familiar with validation rules and these are covered on the admin exam. And so I don’t want to just retread old ground here, but I do want to bring out some things inside of validation rules that hopefully you’ll find value in. And first of all, I want to point you to a resource that is helpful and that’s in the online help there’s examples of validation rules. I’ll link to this in the lesson here as well. But these are examples of validation rules with links to sample account address validation rules or other account validation rules as well as validation rule samples for a lot of other objects as well. And so for account address validation rules, just this top one here for an example is that validates that the account billing zip slash postal code is in the correct format if billing country is Canada for example. So I’m going to go ahead and grab this first one here just to work through this for you. Canadian advanced admins out there. And I’ll go ahead and paste that formula here. And then I’ll grab the description just from the example here. And then as well, they give you the error message and location that they recommend that you put in place.

And so one thing that you could do when you’re starting out in a new job as an advanced administrator is you could just bring more value quickly by just going through and perusing some of these sample validation rules such as this and then adding those into your as ways of gradually cleaning up data over time. So we’re going to check the syntax of this formula here and see if this works and there’s no errors that are found. Now, a couple of things I want to speak to as it relates to validation rules are that you can build these manually yourself and not just simply copy and paste the perfect example that you may find online, but you can actually insert fields. And the primary object that’s selected is whichever one you’re creating the validation rule for, which is account.

And there’s other options with the dollar signs here. These are system variable type things such as you can pull in information around the user and so this way you could even tie things into users in a specific profile, for example. And so you could check against user profile. And we have here a few different fields represented in this formula such as billing country. So let’s see if we can find that manually just to verify that that is the correct field. So billing country and we insert that and that does match this. Now another thing that you notice with this particular formula is that there’s a beginning and now that beginning and is derived from the functions here on the left there’s an and this is helpful in you understanding how these formulas are structured. And what I like to do normally when I’m trying to understand what something does is I find the function and go ahead and insert it.

And you see that this and contains logicals there’s a logical one and then a comma, then a logical two comma dot. And you can have any number of logicals inside these beginning and ending parentheticals and an and checks whether all arguments are true and returns true, if all arguments are true. So inside of these beginning and ending parenthetical are the different logicals that can be found inside of this formula and so the first logical is this or statement and then the next logical is this not statement and so let’s look at as well what or and not look like from a function level. So or is checking logicals as well, let me insert that and it checks whether any of the arguments are true and returns true or false. So it returns false only if all arguments are false.

So the difference between an and and an or and it needs every logical to be true to return a true an or only needs one of a group of logicals to be true for it to return true. The only way it returns false is if none of them are met. Remember, we’re trying to get this overall overarching formula to evaluate it true so that it displays an error and so what they’ve done here is that they have taken this and that starts here and they’ve put this or inside of it. And so what you can do if you were to be manually building this is you could cut this and then paste it over logical one. And so now you see that there is an or inside of an and I know this can get confusing, but as well, another thing to note with the formula editor for validation rules is that you can space this out to make this more readily readable. So you could hit a return here, and we’re mimicking what they’re building here. Now the logical one inside this or, there’s multiple logicals inside this or you notice that what they’re looking for is if the billing country equals can or if the billing country equals CA, or if the billing country equals Canada. So if any one of these three is true for billing country, then that will return a true value for this first logical. And so what they’ve done here is with this or, this is their series of ors and they have three of them. And so I’m going to replace all this inside of here. We’re basically just walking through what this means. So now what we have here at this point is for the second logical of the and it’s saying not only does one of these three need to be true, but also there needs to be this other logical or logical two of the and which is nested not function.

I’m sure at this point you’re thinking, wow, I’m getting all tangled up in knots here. But let me insert the not function and let’s look at that. Now, not changes false to true or true to false. So let me put that in there. So as well, regex, let’s talk about regex for a moment. Regex has to do with regular expression and it is also a function. So let me put that in there for reference so we can see what that looks like. So for regex there’s text and then regex text, it returns true if text which is here matches the regular expression regex text. Otherwise it returns false. So you could probably do a several hour course on regex, which is regular expression. And so what it’s looking for when it’s all said and done here with this billing postal code is that this regular expression has formed the billing postal code in the proper format for Canadian postal code. Now, I don’t know all the ins and outs of regex or especially of Canadian postal codes, so I’m going to trust that this is correct.

But for this not, what they’ve done is they’ve included this logical here. So this side of things looks like this. And then for the regex, this is the text building postal code and here is the regex text surrounded by quotes. And so this is a very advanced and involved formula. I’m going to remove all my reference markers here and check for syntax again to make sure still no errors found. And we will go ahead and save this after we add an error message. So let me go back to my sample here. Error message. We want to make sure that the Canadian postal code must be in the A nine, a nine, a nine format. So I believe that is looking for an alpha character followed by number, then alpha, then a number, then alpha, then a number. So you Canadians can enlighten me on that if I’ve got that wrong, but I want to just paste in that error message. And then for the field, we want that field to be the billing zip postal code field. And so this error will display billing zip postal code. I’ll click save and then you want to also make sure that the validation rule is set to active if you want to test it out.

So now let me go back to this tab. Let me cancel out of this. Let me just change an existing record. It’s always a good idea to test these out, these validation rules to make sure that they work as expected. And you want to check that it works as far as showing an error and then it doesn’t inadvertently show an error when there’s not an error. So let’s go to details and let’s find our field. Now remember that the billing country, if it equals any of these three, either can or CA or Canada, then we’re going to test this format here and see if we can throw the error properly.

So billing country, another thing to note is that the billing address, you’ve got to hit edit on the billing address to pull up the billing specific fields and that gives you the billing street city, zip post a code. So I’m entering in the data so that this will match the first logical as far as the billing country equaling can. That’s one of the three possibilities for the or and then for the Canadian postal code that will be for this field, billing postal code. So I’m just going to do a nine A. Actually the proper format is A nine, a nine, A nine. I’m going to do it to where hopefully it’ll show an error here. Let’s click save.

And so now the error appears. There’s the error alert. And then the text here says canadian postal code must be in the A nine a nine A nine format. Now I’m going to change this to number alpha number, but I’m going to do eight a seven just so that we’re clear that it doesn’t have to be an A fall by nine followed by an A fall by nine. See that three times fast. It’s just the format needs to be alpha followed by number three times. Let me click save. And so now we’ve tested for an error and we’ve tested to not show an error. So this validation rule works. So that is a good example of a pretty involved validation rule. And it’s getting into Regex, which can check for formatting.

And seriously, whenever you get into specific formatting that you need, you can usually find an example if you just search for regex formulas. And Regex is something that goes beyond just salesforce, but other development languages as well. And I do encourage you to check out some of these other their sample validation rules. And the next lesson, I want to go deeper into validation rules and we’ll do some things checking against the user that’s entering in a record. And we’ll look at ways to make things or validation rules valid for only specific users or profiles.

Leave a Reply

How It Works

img
Step 1. Choose Exam
on ExamLabs
Download IT Exams Questions & Answers
img
Step 2. Open Exam with
Avanset Exam Simulator
Press here to download VCE Exam Simulator that simulates real exam environment
img
Step 3. Study
& Pass
IT Exams Anywhere, Anytime!