Remove commas when copying table to clipboard using formula

Ok so here are your issues.

First thing to understand is the RETURN value type of a formula. Your data in Coda has different types. Some examples are:

  • Text
  • Number
  • Row Value
  • Date
  • Boolean (true/false)

And most importantly:

  • Lists

Notice here, I did a simple forEach() Loop on your table, and it returns the values in that table with a comma between each value because forEach() Loops ALWAYS return LISTS

You can also confirm that the return type of a forEach() loop is a list here. The chip-icon on actual chip itself has a little shadow letting you know that the value is a list.

Here is full documentation on Coda formula chips and value types - I recommend giving it a look


So that is the source of your rouge commas - commas are an indication of a list. So how do we get rid of them?

Well one really good way to turn lists into plain text value is to JOIN lists via a certain character. The Join() formula in Coda was made just for this!

Notice here with this simple forEach() list, I used Join(lineBreak()) which allowed me get ride of my commas, and return my values stacked!

The solve to your specific problem

To be honest, Im not sure exactly what you’re looking for, but hopefully using the principles above you can get the formula you need!

Here is a small formula I wrote to mimic something similar to your output

Some more formula help

Heres some more formula assistance with the formulas you might need to use from the Coda School!

1 Like