Lookup a table and return value to canvas formula

Good morning. I am very new to Coda. I have a canvas and a table. The table contains budget values.

Budget Category £ p.a. Value
Telemarketing 100 100
CMC 400 400
Networking 500 500
Partnership Programme 100 100

In my canvas (document), I want to add a fomula that logically looks up the table for the value “Telemarketing” in column Budget Category and reurns the £ p.a. value from that row. Sounds simple - I just can’t get the syntax.
Many thanks,

If “Budget Category” is your display column (has a bookmark icon on it), you can just use

@Telemarketing.[£ p.a.]

Otherwise [Table name].Filter([Budget Category] = "Telemarketing").[£ p.a.].First()

In case like yours, best is to reference the exact row by using @ and typing in the display column value — one of less known but very useful features of Coda.



Many thanks. Budget Category is the display column but do I not need a reference to the table rather than just @Telemarketing. [£ p.a.]

No, the row pulled in by @ syntax will reference that unique row from that specific table, no matter if you change display column or its value. All you need to do is specify a correct row (there will be hints) when first typing this formula.

Sorry Paul, maybe I wasn’t clear. How does the formula in the canvas know what table I’m using

I’m not at the computer right now, so cannot show a screenshot. Just try typing @Tele in your formula, and you’ll see the list of suggestions: all rows from all tables where display column value starts with Tele. You then select the one that comes from your table, and this will be used from now on. Internally Coda will store this as a reference to specific table and specific row by internal unique ID. Think of the @ syntax as a search that’s done once when you write the formula.

Brilliant - many thanks.