Creating lookups and rollups between tables

Who can use this feature?

👤  Available on all plans.

Stacker allows you to create lookup and roll-up fields directly within your app. This means you can pull together and summarise data from different data sources. 

Lookups and Rollups each work over records which are linked by a relationship ("link to another record") field. So it only offers you tables where there is a valid relationship.

  1. Click  Manage fields and data
  2. Click Fields > + Add field
  3. Enter a field name
  4. Select the Lookup or Roll-up field type
  5. Select the linked record field to use in the Lookup or Roll-up.
  6. Select the field from the linked record that you want to look up or roll-up.
  7. Click Save

lookup_fields.gif

You should now have the new field on your Data Grid. 

Tip

We suggest choosing a name that clearly reflects the data that will be pulled in or summarised, e.g. 'Client Notes Lookup'.

Lookup Field

A lookup field shows a specific field from a linked table.  On our Properties app we have created a lookup field from our Clients table to our Team table. Instead of showing the Primary field, this allows you to choose any field to display. 

Screenshot_2022-07-25_at_16.30.02.png

Roll-up Field

A roll-up field can display different results of a field based on related records. 

Possible display options:

  • Number of related records
  • Count values...
  • Sum...
  • Average...
  • Min...
  • Max...

CleanShot_2023-04-04_at_13.02.53_2x.png

Related articles

Syncing Schema and Data

Creating links between tables

Enabling Tables and Fields

Importing data into Stacker