CLEAN
TheCLEAN
formula is used to remove all non-printable characters from a given text string. This is useful when dealing with imported or copied data that contains hidden characters that can cause issues with further processing.
- How to use
CLEAN
formula? - Examples of using
CLEAN
formula CLEAN
formula not working?- Similar formulas to
CLEAN
Usage
Use the CLEAN
formula with the syntax shown below, it has 1 required parameter:
- text (required):
The text string that you want to remove non-printable characters from.
Examples
Here are a few example use cases that explain how to use theCLEAN
formula in Google Sheets.
Cleaning up imported data
When you import data from external sources, it may contain non-printable characters that can cause issues with further processing. The CLEAN
formula can be used to remove these characters and ensure that your data is clean and ready to use.
Removing line breaks
If you have a text string that contains line breaks or other invisible characters, you can use the CLEAN
formula to remove them and make the text easier to read and work with.
Cleaning up user input
If you allow users to input text into your Google Sheet, they may inadvertently include non-printable characters that can cause issues with your formulas. The CLEAN
formula can be used to remove these characters and ensure that your data is clean and ready to use.
Common Mistakes
CLEAN
not working? Here are some common mistakes people make when using the CLEAN
Google Sheets Formula:
Forgetting to include the text parameter
One common mistake when using the CLEAN
formula is forgetting to include the text parameter. This will result in an error and the formula will not work as expected.
Using with numeric data
The CLEAN
formula is designed to work with text strings and will not work with numeric data. If you try to use it with a numeric value, it will return an error.
Related Formulas
The following functions are similar to CLEAN
or are often used with it in a formula:
-
TRIM
The TRIM formula removes any leading and trailing whitespace from text in a cell. This can be useful when importing data or when dealing with data that includes extra spaces. The TRIM function is commonly used in data cleaning and formatting.
-
SUBSTITUTE
The
SUBSTITUTE
formula is used to replace specific text in a string with new text. It is commonly used to replace all occurrences of a certain word or character within a larger string. The formula has the option to specify which occurrence to replace, or it will replace all occurrences by default. -
LOWER
The
LOWER
formula converts all letters in a specified text string to lowercase. It takes one required parameter, which is the text string to be converted. This formula is commonly used to standardize text data for easier analysis and comparison. -
UPPER
The
UPPER
formula in Google Sheets converts all the letters in a given text string to uppercase. It takes one required argument, thetext
to convert. This formula is commonly used to standardize text data or to make it easier to compare text values.
Learn More
You can learn more about the CLEAN
Google Sheets function on Google Support.