Inside this article

Formula basics
Formulas in the surface
Full formula list

You can use your understanding of basic spreadsheet formulas to write calculations in Coda too. You'll be able to do things you'd expect - SUM, COUNT etc., but you can also do interesting things with your data - for example, embed a Google Map based on a location description.

Formula basics

Coda's Table formulas are different than in spreadsheets as they are at the column level, not at the cell level.  You can trigger a column formula by clicking on a cell in a column and pressing “=”. Right-click any column and select Add column formula to add a column-level formula - this will apply to all rows in the table:

There are two main differences between traditional Excel formula language and Coda's language: named objects and chaining.

Named objects: Unlike spreadsheets where addressing was mostly done with A4 or B12 references, Coda uses the actual names of your tables and columns.

Chaining: With complex formulas in Excel, you’re required to wrap methods around “inner formulas” ー leaving you with this long block of )))))’s at the end which can be really hard to understand. So like a modern programming language, Coda supports both the traditional Function(X, Y) look from Excel as well as X.Function(Y) ー which can often help with readability.

For example, in a Table of Products, you could apply the below formulas to calculate values:

=Products.FILTER(Quantity > 5).COUNT()

Formulas in the surface

One thing which makes Coda unique is the ability to add formulas anywhere - not just in Tables. If you enter the "=" sign anywhere in a document, you'll see you can write a formula - 5*5, for example.

You can also pull data in from anywhere else in the document here. For example, if you have a Table in your document, and hit "=" somewhere else, you can pull in data from that table. For example, =[Table Name].Count() will return all the rows in that table. =[To-Do List].Filter(Status="Not Started").Count() will count all the items in your To Do List which haven't been started yet. See this in action below:

You'll find you can add formulas anywhere in a Coda doc to summarize data and understand it at a glance. A best practice is to create a summary Section with a text summary of progress, and embed formulas that will automatically update based on your progress in the Tasks table, elsewhere.

Formula list

To explore the full breadth of Coda formulas, go here.

Did this answer your question?