Inserting quotation marks into a string

Topic Labels: Formulas
919 1
Showing results for 
Search instead for 
Did you mean: 
4 - Data Explorer
4 - Data Explorer

Hello -

I’m looking for help creating a formula that will insert quotation marks around names in a string that are separated by commas. The number of names in the string will vary. For example the string Jane Doe, John Smith would become “Jane Doe”, “John Smith”.

Is there a formula that I can use to do this?

1 Reply 1

Welcome to the Airtable community!

If the comma will always be followed by a single space, you can try this formula.

  FIND( ', ', {text field}),
  '"' & SUBSTITUTE({text field}, ', ', '", "') & '"',
  {text field}

However, this will only work if the initial string is actually a string, and not an array (such as from a lookup or linked record). It also won’t work if there are multiple spaces or no space after the comma.