{"id":230,"date":"2022-03-07T12:00:00","date_gmt":"2022-03-07T12:00:00","guid":{"rendered":""},"modified":"2023-07-03T12:49:37","modified_gmt":"2023-07-03T07:19:37","slug":"formula-field-and-validation-rule-in-salesforce","status":"publish","type":"post","link":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/","title":{"rendered":"Formula Field and Validation Rule in Salesforce"},"content":{"rendered":"<div style=\"clear: both; text-align: center;\"><\/div>\n<p><b><span style=\"font-size: large;\"><i>Formula Field and Validation Rule in Salesforce<\/i><\/span><\/b><\/p>\n<p><span style=\"font-size: large;\"><b><u>Validation rules<\/u>:<\/b><\/span><\/p>\n<p>Validation rules in salesforce contains a formula or expressions that evaluates the data in one or more&nbsp; fields in a record to meet the standards and returns a value \u201cTrue\u201d or \u201cFalse\u201d. Validation rules displays error message to the user when the Condition is \u201cFalse\u201d.<\/p>\n<p>Validation rules in salesforce contains a formula or expressions that evaluates the data in one or more&nbsp; fields in a record to meet the standards and returns a value \u201cTrue\u201d or \u201cFalse\u201d. Validation rules displays error message to the user when the Condition is \u201cFalse\u201d. Validation rules in Salesforce are the rules which contains a formula expressions that validates our data and returns a value of \u201cTrue\u201d or \u201cFalse.<\/p>\n<ul style=\"text-align: left;\">\n<li>Validation rule contain Formula expressions.<\/li>\n<li>It evaluate the data entered by the user.<\/li>\n<li>Validation Rule displays error message to user when the enter invalid values.<\/li>\n<li>We can create Validation rules in Salesforce for Objects, fields, campaign members etc.<\/li>\n<\/ul>\n<p><span style=\"font-size: medium;\"><b>Use the Formula Editor<\/b><\/span><\/p>\n<p>You can create custom formula fields on any standard or custom object. To start, we\u2019ll create a formula on the Opportunity object. Follow these steps to navigate to the formula editor.<\/p>\n<ol style=\"text-align: left;\">\n<li>From Setup, open the <b>Object Manager<\/b> and click <b>Opportunity<\/b>.<\/li>\n<li>In the left sidebar, click <b>Fields &amp; Relationships<\/b>.<\/li>\n<li>Click <b>New<\/b>.<\/li>\n<li>Select <b>Formula<\/b> and click <b>Next<\/b>.<\/li>\n<li>In <b>Field Label<\/b>, type My Formula Field. Notice that <b>Field Name<\/b> populates automatically.<\/li>\n<li>Select the type of data you expect your formula to return.<br \/>\nFor example, if you want to write a formula that calculates the commission a salesperson receives on a sale, you select <b>Currency<\/b>. For now, pick Text.<\/li>\n<li>Click <b>Next<\/b>. You\u2019ve arrived at the formula editor! Time for our tour.<\/li>\n<\/ol>\n<div style=\"clear: both; text-align: center;\"><a style=\"margin-left: 1em; margin-right: 1em;\" href=\"https:\/\/blogger.googleusercontent.com\/img\/a\/AVvXsEjtFySceGoScw3HEv6m8mDg7tJRWWTKfvstZmYLnRix7iItPpPcXp1_o6T5WrbOqe0B-CQxAMyBZUgCer-3WReqlR1puCL9UO3davU1s80wNqfgMb8pr6c789lfZol52SRE4tSxwqUXTsk9utRvtYHYTTIy-UjnT0U_BGjqyujfeioJfug5JLxjKh57sg=s840\"><img decoding=\"async\" src=\"https:\/\/blogger.googleusercontent.com\/img\/a\/AVvXsEjtFySceGoScw3HEv6m8mDg7tJRWWTKfvstZmYLnRix7iItPpPcXp1_o6T5WrbOqe0B-CQxAMyBZUgCer-3WReqlR1puCL9UO3davU1s80wNqfgMb8pr6c789lfZol52SRE4tSxwqUXTsk9utRvtYHYTTIy-UjnT0U_BGjqyujfeioJfug5JLxjKh57sg=s16000\" border=\"0\" data-original-height=\"500\" data-original-width=\"840\"><\/a><\/div>\n<p>1. The formula editor comes in two flavors:<br \/>\nSimple and Advanced. It\u2019s tempting to use the Simple editor, but we always recommend using the Advanced editor. Advanced doesn\u2019t mean more complicated. It means more tools for you to create powerful formulas.<\/p>\n<p>2. The <b>Insert Field<\/b> button opens a menu that allows you to select fields to use in your formula. Inserting from this menu automatically generates the correct syntax for accessing fields.<\/p>\n<p>3. The <b>Insert Operator<\/b> button opens a dropdown list of the available mathematical and logical operators.<\/p>\n<p>4. The Functions menu is where you view and insert formula functions. Functions are more complicated operations that are preimplemented by Salesforce. Some functions can be used as-is (for example, the TODAY() function returns the current date), while others require extra pieces of information, called parameters. The LEN(text) function, for instance, finds the length of the text you input as a parameter. The formula LEN(&#8220;Hello&#8221;) returns a value of 5.<\/p>\n<p>5. The text area is where you enter your formula. When writing formulas, keep in mind that:<\/p>\n<ul style=\"text-align: left;\">\n<li>Whitespace doesn\u2019t matter. You can insert as many spaces and line breaks as you want without affecting the formula\u2019s execution.<\/li>\n<li>Formulas are case sensitive. Pay attention to capitalization of field and object names.<\/li>\n<li>When working with numbers, the standard order of operations applies.<\/li>\n<\/ul>\n<p>6. Once you\u2019ve written a formula, you can use the <b>Check Syntax<\/b> button to ensure that everything is in working order before saving. If your formula has issues, the syntax checker alerts you to specific problems.<\/p>\n<p><span style=\"font-size: medium;\"><i># <u>Validation Rules Fields<\/u><\/i><\/span><\/p>\n<table style=\"border-bottom: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); border-spacing: 0px; border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); color: #080707; font-size: 14px; margin-bottom: var(--lwc-spacingSmall,0.75rem); width: 848px;\">\n<thead style=\"color: var(--lwc-colortextweak,#696969); font-size: var(--lwc-fontSize2,0.75rem); font-weight: var(--lwc-fontWeightRegular,400); letter-spacing: 0.0625rem; line-height: var(--lwc-lineHeightHeading,1.25); text-transform: uppercase;\">\n<tr>\n<th style=\"color: var(--lwc-tablecolortextheader,#696969); font-weight: var(--lwc-fontWeightBold,700); line-height: normal; padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; text-align: left;\" scope=\"col\" width=\"32%\">FIELD<\/th>\n<th style=\"color: var(--lwc-tablecolortextheader,#696969); font-weight: var(--lwc-fontWeightBold,700); line-height: normal; padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; text-align: left;\" scope=\"col\" width=\"68%\">DESCRIPTION<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"32%\" data-label=\"Field\"><samp style=\"font-family: monospace, monospace; font-size: 1em;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"rule_name\"><\/a>Rule Name<\/samp><\/td>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"68%\" data-label=\"Description\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"rule_name_desc\"><\/a>Unique identifier of up to <b>40 characters<\/b> with no spaces or special characters such as extended characters.<\/td>\n<\/tr>\n<tr>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"32%\" data-label=\"Field\"><samp style=\"font-family: monospace, monospace; font-size: 1em;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"active\"><\/a>Active<\/samp><\/td>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"68%\" data-label=\"Description\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"active_desc\"><\/a>Checkbox that indicates if the rule is <b>enabled<\/b>.<\/td>\n<\/tr>\n<tr>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"32%\" data-label=\"Field\"><samp style=\"font-family: monospace, monospace; font-size: 1em;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"desc\"><\/a>Description<\/samp><\/td>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"68%\" data-label=\"Description\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"desc_desc\"><\/a>A <b>255-character<\/b> or less description that distinguishes the validation rule from others. For internal purposes only.<\/td>\n<\/tr>\n<tr>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"32%\" data-label=\"Field\"><samp style=\"font-family: monospace, monospace; font-size: 1em;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"error_condition\"><\/a>Error Condition Formula<\/samp><\/td>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"68%\" data-label=\"Description\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"error_desc\"><\/a>The expression used to validate the field.<\/td>\n<\/tr>\n<tr>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"32%\" data-label=\"Field\"><samp style=\"font-family: monospace, monospace; font-size: 1em;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"error_message\"><\/a>Error Message<\/samp><\/td>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"68%\" data-label=\"Description\">\n<p style=\"font-size: 13px; line-height: 20px; padding: 0px; margin: 0px 0px var(--lwc-spacingSmall,0.75rem) 0px;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"error_message_desc\"><\/a>The message that displays to the user when a field fails the validation rule.<\/p>\n<p style=\"font-size: 13px; line-height: 20px; margin: 0px; padding: 0px;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"workbench\"><\/a>If your organization uses the Translation Workbench, you can translate the error message into the languages Salesforce supports.<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"32%\" data-label=\"Field\"><samp style=\"font-family: monospace, monospace; font-size: 1em;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"error_location\"><\/a>Error Location<\/samp><\/td>\n<td style=\"border-top: var(--lwc-borderWidthThin,1px) solid var(--lwc-colorBorder,#D4D4D4); padding: var(--lwc-tableCellSpacing,0.5rem); position: relative; vertical-align: top;\" width=\"68%\" data-label=\"Description\">\n<p style=\"font-size: 13px; line-height: 20px; padding: 0px; margin: 0px 0px var(--lwc-spacingSmall,0.75rem) 0px;\"><a style=\"cursor: pointer;\" href=\"https:\/\/help.salesforce.com\/s?language=en_US\" name=\"error_location_desc\"><\/a>Determines where on the page to display the error.&nbsp;To display the error next to a field, choose&nbsp;<samp style=\"font-family: monospace, monospace; font-size: 1em;\">Field<\/samp>&nbsp;and select the field. If the error location is a field, the validation rule is also listed on the detail page of that field. If the error location is set to a field that is later deleted, to a field that is read only, or to a field that isn\u2019t visible on the page layout, Salesforce automatically changes the location to&nbsp;<samp style=\"font-family: monospace, monospace; font-size: 1em;\">Top of Page<\/samp>.<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><b><u>Formula field&nbsp;Limitation<\/u>:<\/b><\/p>\n<ul style=\"text-align: left;\">\n<li>Formula fields have these limits<\/li>\n<li>Formula fields can\u2019t exceed 5,000 bytes when compiled. The compile size is the size of the formula (in bytes) including all of the fields, values, and formulas it references. There is no direct correlation between the compile size and the character limit. Some functions, such as TEXT, DATEVALUE, DATETIMEVALUE, and DATE significantly increase the compile size.<\/li>\n<li>You can\u2019t use long text area, encrypted, or Description fields in formulas.<\/li>\n<li>The value of a field can\u2019t depend on another formula that references it.<\/li>\n<li>You can\u2019t delete fields referenced in formulas. Remove the field from the formula before deleting it.<\/li>\n<\/ul>\n<p><i><u>Resource<\/u><\/i>:<\/p>\n<p><a href=\"https:\/\/trailhead.salesforce.com\/content\/learn\/modules\/point_click_business_logic\" target=\"_blank\" rel=\"nofollow noopener\"><span style=\"font-size: medium;\"><i>Trailhead Module Link<\/i><\/span><\/a><\/p>\n<p><a href=\"https:\/\/help.salesforce.com\/s\/articleView?id=sf.fields_about_field_validation.htm&amp;type=5\" target=\"_blank\" rel=\"nofollow noopener\"><i>Validation Rule (Salesforce)<\/i><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Formula Field and Validation Rule in Salesforce Validation rules: Validation rules in salesforce contains a formula or expressions that evaluates the data in one or more&nbsp; fields in a record to meet the standards and returns a value \u201cTrue\u201d or \u201cFalse\u201d. Validation rules displays error message to the user when the Condition is \u201cFalse\u201d. Validation&#8230;<\/p>\n","protected":false},"author":2,"featured_media":83,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[33,22],"tags":[],"class_list":["post-230","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-how-to","category-salesforce-admin"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v22.9 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Formula Field and Validation Rule in Salesforce - Swapnil SFDC | Salesforce Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Formula Field and Validation Rule in Salesforce - Swapnil SFDC | Salesforce Blog\" \/>\n<meta property=\"og:description\" content=\"Formula Field and Validation Rule in Salesforce Validation rules: Validation rules in salesforce contains a formula or expressions that evaluates the data in one or more&nbsp; fields in a record to meet the standards and returns a value \u201cTrue\u201d or \u201cFalse\u201d. Validation rules displays error message to the user when the Condition is \u201cFalse\u201d. Validation...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/\" \/>\n<meta property=\"og:site_name\" content=\"Swapnil SFDC | Salesforce Blog\" \/>\n<meta property=\"article:published_time\" content=\"2022-03-07T12:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-07-03T07:19:37+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/swapnilzambare.com\/blog\/wp-content\/uploads\/2022\/08\/sflogo-e1688320096934.png\" \/>\n\t<meta property=\"og:image:width\" content=\"750\" \/>\n\t<meta property=\"og:image:height\" content=\"525\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Swapnil\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@SwapnilZambare7\" \/>\n<meta name=\"twitter:site\" content=\"@SwapnilZambare7\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Swapnil\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/\",\"url\":\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/\",\"name\":\"Formula Field and Validation Rule in Salesforce - Swapnil SFDC | Salesforce Blog\",\"isPartOf\":{\"@id\":\"https:\/\/swapnilzambare.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/swapnilzambare.com\/blog\/wp-content\/uploads\/2022\/08\/sflogo-e1688320096934.png\",\"datePublished\":\"2022-03-07T12:00:00+00:00\",\"dateModified\":\"2023-07-03T07:19:37+00:00\",\"author\":{\"@id\":\"https:\/\/swapnilzambare.com\/blog\/#\/schema\/person\/8ababd34e5d3bc24fa10df2a87c5ac45\"},\"breadcrumb\":{\"@id\":\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#primaryimage\",\"url\":\"https:\/\/swapnilzambare.com\/blog\/wp-content\/uploads\/2022\/08\/sflogo-e1688320096934.png\",\"contentUrl\":\"https:\/\/swapnilzambare.com\/blog\/wp-content\/uploads\/2022\/08\/sflogo-e1688320096934.png\",\"width\":750,\"height\":525,\"caption\":\"Swapnil SFDC Salesforce Blog\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/swapnilzambare.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Formula Field and Validation Rule in Salesforce\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/swapnilzambare.com\/blog\/#website\",\"url\":\"https:\/\/swapnilzambare.com\/blog\/\",\"name\":\"Swapnil SFDC | Salesforce Blog\",\"description\":\"Hey trailblazers, Welcome to Swapnil SFDC world.\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/swapnilzambare.com\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/swapnilzambare.com\/blog\/#\/schema\/person\/8ababd34e5d3bc24fa10df2a87c5ac45\",\"name\":\"Swapnil\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/swapnilzambare.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/50610dedda801c6c795bfc5b650f7f4ed5f7c34b3b5c9c7148d702eb351c003b?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/50610dedda801c6c795bfc5b650f7f4ed5f7c34b3b5c9c7148d702eb351c003b?s=96&d=mm&r=g\",\"caption\":\"Swapnil\"},\"url\":\"https:\/\/swapnilzambare.com\/blog\/author\/swapnil-zambare\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Formula Field and Validation Rule in Salesforce - Swapnil SFDC | Salesforce Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/","og_locale":"en_US","og_type":"article","og_title":"Formula Field and Validation Rule in Salesforce - Swapnil SFDC | Salesforce Blog","og_description":"Formula Field and Validation Rule in Salesforce Validation rules: Validation rules in salesforce contains a formula or expressions that evaluates the data in one or more&nbsp; fields in a record to meet the standards and returns a value \u201cTrue\u201d or \u201cFalse\u201d. Validation rules displays error message to the user when the Condition is \u201cFalse\u201d. Validation...","og_url":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/","og_site_name":"Swapnil SFDC | Salesforce Blog","article_published_time":"2022-03-07T12:00:00+00:00","article_modified_time":"2023-07-03T07:19:37+00:00","og_image":[{"width":750,"height":525,"url":"https:\/\/swapnilzambare.com\/blog\/wp-content\/uploads\/2022\/08\/sflogo-e1688320096934.png","type":"image\/png"}],"author":"Swapnil","twitter_card":"summary_large_image","twitter_creator":"@SwapnilZambare7","twitter_site":"@SwapnilZambare7","twitter_misc":{"Written by":"Swapnil","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/","url":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/","name":"Formula Field and Validation Rule in Salesforce - Swapnil SFDC | Salesforce Blog","isPartOf":{"@id":"https:\/\/swapnilzambare.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#primaryimage"},"image":{"@id":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#primaryimage"},"thumbnailUrl":"https:\/\/swapnilzambare.com\/blog\/wp-content\/uploads\/2022\/08\/sflogo-e1688320096934.png","datePublished":"2022-03-07T12:00:00+00:00","dateModified":"2023-07-03T07:19:37+00:00","author":{"@id":"https:\/\/swapnilzambare.com\/blog\/#\/schema\/person\/8ababd34e5d3bc24fa10df2a87c5ac45"},"breadcrumb":{"@id":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#primaryimage","url":"https:\/\/swapnilzambare.com\/blog\/wp-content\/uploads\/2022\/08\/sflogo-e1688320096934.png","contentUrl":"https:\/\/swapnilzambare.com\/blog\/wp-content\/uploads\/2022\/08\/sflogo-e1688320096934.png","width":750,"height":525,"caption":"Swapnil SFDC Salesforce Blog"},{"@type":"BreadcrumbList","@id":"https:\/\/swapnilzambare.com\/blog\/formula-field-and-validation-rule-in-salesforce\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/swapnilzambare.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Formula Field and Validation Rule in Salesforce"}]},{"@type":"WebSite","@id":"https:\/\/swapnilzambare.com\/blog\/#website","url":"https:\/\/swapnilzambare.com\/blog\/","name":"Swapnil SFDC | Salesforce Blog","description":"Hey trailblazers, Welcome to Swapnil SFDC world.","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/swapnilzambare.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/swapnilzambare.com\/blog\/#\/schema\/person\/8ababd34e5d3bc24fa10df2a87c5ac45","name":"Swapnil","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/swapnilzambare.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/50610dedda801c6c795bfc5b650f7f4ed5f7c34b3b5c9c7148d702eb351c003b?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/50610dedda801c6c795bfc5b650f7f4ed5f7c34b3b5c9c7148d702eb351c003b?s=96&d=mm&r=g","caption":"Swapnil"},"url":"https:\/\/swapnilzambare.com\/blog\/author\/swapnil-zambare\/"}]}},"_links":{"self":[{"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/posts\/230","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/comments?post=230"}],"version-history":[{"count":3,"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/posts\/230\/revisions"}],"predecessor-version":[{"id":349,"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/posts\/230\/revisions\/349"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/media\/83"}],"wp:attachment":[{"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/media?parent=230"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/categories?post=230"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/swapnilzambare.com\/blog\/wp-json\/wp\/v2\/tags?post=230"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}