I’m working on a project management system in Airtable, and I need to set up a counter system to assign unique numbers to tasks within a vertical hierarchy. The goal is to create a structured numbering system that reflects the task relationships and levels. Here are the details:
Project Structure:
I have a hierarchical structure with parent tasks ("Predecessors" field) and the associated subtasks ("Next task" field).
Each task can have multiple subtasks, forming a vertical hierarchy.
Requirements:
- Assign a unique number to each task.
- Ensure that the numbering system reflects the hierarchy (parent-child relationships).
- Use a formula or automation to generate these numbers automatically.
Below is what I have tried:
I have tried to create 3 different fields as below:
1. tesst2:
Formula: IF(COUNTA(Predecessors) = 0, "1", "")
Explanation: This formula assigns “1” to tasks that have no predecessors (i.e., top-level tasks).
2. lookup test:
Formula: A lookup of the above field for the linked “Predecessors” field for the task.
3. test field:
Formula: {tesst2} + {lookup test}
Explanation: Combines the values from the previous two fields to generate the final task number.
Issue:
I am unable to get any number greater than 2 using this method