I have the following fields with emails separated by a comma. Some (not all) of them have a comma at the end. How do I get rid of that using formula tool?
No need for the if statements - TrimRight() will just ignore records without a trailing comma so you can just use:
TrimRight([Input],',')
(Obviously replace [Input] with your own field name).
Here's one solution (see attached workflow). Writing a formula to check if the last character is a comma, then taking all of the characters except the last one (i.e., the comma).
You could use this formula:
if EndsWith([YourField], ",") then trimright([YourField],",") else [YourField] endif
Hello @richleeb2 , you may use the formula Replace([Field1],","," ")
But I think is better use the text-to-columns, splitting to rows.
Gabriel
@DataNath
That's an answer that I can applaud,
m
Thank you this was simple and worked!
Here's another option that uses regex
REGEX_Replace([Field1], '(.*),$', '$1')