Re: Has anyone been able to create a column for dynamic ranking?

813 0
Showing results for 
Search instead for 
Did you mean: 
5 - Automation Enthusiast
5 - Automation Enthusiast

I have a table that contains my users, and their current balance of chips in a casino. I’m building a leaderboard that will tell them who the top five chip holders are. (This is the easy part.)

I also want to tell them what place THEY are in, if they’re not in the top five. This requires one of two solutions:

  1. Grab all of the data, and iterate through it until I find the user. This is a heavy operation, because I’d have to pull all of the user data to my application before iterating through all of it.
  2. Have a ranked column that automatically updates every time that a user’s balance changes, much like Lookup, Rollup, or Formula fields. This is my preferred approach, but I can’t figure out how to do this.

Do any of you amazing people have some guidance or advice? Thanks!

1 Reply 1

How are you accessing the data? A human looking at the native Airtable interface on a computer? Via the Standard REST API?

Airtable is not designed for calculations across records in the same table, which is what you are requesting. Formulas fields can only perform calculations within a record. Lookups and rollups only work across linked records.

You could use Airtable’s new automations to do the calculations for option 2. However, depending on the number of users and how quickly their balances change, you might run into automation limits on the number of updates, processing time, runs, etc.