---
schema_version: "1"
id: bb7eff5e8b9e22c894263f2713156a3994c95cc7afedde63b7bd82e9afac67aa
title: String Functions for Formula Fields
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/analytics/264-0-0/bi_integrate_data_prep_recipe_formula_field_stringfunctions.md
canonical_url: https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 945b370ce9c7792119c10adbc24358eb731c910300170c3e1e1acd0ab7df545c
description: Use string functions to create values in a formula field based on one or more dimension columns in your recipe or strings. For example, you can change the casing of text strings, concatenate values from multiple columns, and replace values.
products:
  - CRM Analytics
  - Cross Cloud
release: "264"
---
# String Functions for Formula Fields

Use string functions to create values in a formula field based on one or more dimension columns in your recipe or strings. For example, you can change the casing of text strings, concatenate values from multiple columns, and replace values.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in Salesforce Classic and Lightning Experience.</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available with CRM Analytics, which is available for an extra cost in <strong>Enterprise</strong>, <strong>Performance</strong>, and <strong>Unlimited</strong> Editions. Also available in <strong>Developer</strong> Edition.</td></tr></tbody></table>

![Note](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-analytics-bi-264-0-0-production-enus/ec791473-f5b4-4f64-a656-9104f455d966/images/icon_note.png)

Note To get a list of string functions for a Data Prep recipe, see [String Functions for Formulas](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_recipe_stringfunctions.htm&release=264.0.0&type=5 "In CRM Analytics, use string functions to create values based on other strings. For example, you can change the casing of text strings, concatenate values from multiple columns, and replace values. The arguments for string functions must be text strings or fields.").

You can use a formula to manipulate strings, instead of dataflow transformations, to perform multiple string manipulations at the same time. For instance, you can nest string functions in the formula editor to combine the sales territory and country into a single field and apply title casing to the values.

`title(concat([Sales_Territory], " ",[Country]))`

When entering a formula, text strings must be enclosed in double straight quotes (`"This is a string."`). Column names must be enclosed in square brackets (`[Opportunity_Name]`).

- **[concat Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_concat.htm&release=264.0.0&type=5)**  
    Returns a string by concatenating the values of the specified columns and input strings. For example, to display the close date as MM-DD-YYYY, concatenate the Close\_Date\_Month column, Close\_Date\_Day column, and Close\_Date\_Year column, and add a dash between each of them.
- **[lower Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_lower.htm&release=264.0.0&type=5)**  
    Returns a string with all characters from the input string in lowercase. If the input string is null, then the result is null.
- **[ltrim Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_ltrim.htm&release=264.0.0&type=5)**  
    Removes the specified substring from the beginning of a string. To remove leading spaces, do not specify a substring.
- **[replace Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_replace.htm&release=264.0.0&type=5)**  
    Replaces a substring with the specified characters. If any of the arguments are null, then the function returns null. This function is case-sensitive.
- **[rtrim Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_rtrim.htm&release=264.0.0&type=5)**  
    Removes the specified substring from the end of a string. To remove trailing spaces, do not specify a substring.
- **[substr Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_substr.htm&release=264.0.0&type=5)**  
    Returns characters from the string, starting at the specified position and of the specified length.
- **[title Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_title.htm&release=264.0.0&type=5)**  
    Returns the string with the initial character of every word in uppercase and the remaining characters in lowercase. For example, “united states” becomes “United States.”
- **[trim Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_trim.htm&release=264.0.0&type=5)**  
    Removes the specified substring from the beginning and end of a string. To remove leading and trailing spaces, do not specify a substring.
- **[upper Function](https://help.salesforce.com/s/articleView?id=analytics.bi_integrate_data_prep_recipe_formula_field_stringfunctions_upper.htm&release=264.0.0&type=5)**  
    Returns the string with all characters in uppercase. If string is null, then the result is null.