Connected Table Relationships

  • 0
  • 1
  • Question
  • Updated 2 months ago
  • In Progress
So here is the problem I am facing:


I have a connected table which has a list of all employees, now this table is updated and maintained externally. - and this is correctly reflected in Quickbase using Connected Tables.


2 tables:
Employees Table- connected table
Association Table- manually created table


What am I trying to do?


I have created an Associations table- the purpose of this is be able to look up a particular employee from the Employees table (connected table) - Lets call this relationship Related Leader . - I am easily able to achieve this by creating a Employee (Master) to Associations (Details) table relationship. 


Further, this chosen Leader employee may have associations with multiple other employees. I want to create a relationship that helps me lookup and list all the associated employees with the chosen Leader. - I am struggling with this part. Any help/thoughts are appreciated


In short, I want to maintain the related leader and all the employees under that leader in one view. Is there a way to achieve this? 
Photo of Angel

Angel

  • 724 Points 500 badge 2x thumb

Posted 2 months ago

  • 0
  • 1
Photo of Slider

Slider

  • 1,326 Points 1k badge 2x thumb
Hello Angel, 

It sounds like you may benefit from a recursive relationship in the Employee table. Employees (leaders) have child Employees. Quickbase warns you when creating recursive relationships, but they can be useful, especially in this hierarchy of Staff. 

I would recommend creating a leader checkbox, to easily indicate which employees are leaders and can have child employees. You can use this checkbox in form rules to hide/show the child employee section and embedded report. I would even recommend a grid edit embedded report to select the child employees at the leader level.  You would have some clean up on the form for Child employees, choosing whether to allow the selection of a leader on the child, or to hide this selection if the record is indicated as a leader record. Most likely, you want to have a clear hierarchy of Leaders and employees, not a chain of Leader>Managers>Employees>Minions. With recursion, it allows for infinite chains, and you want to set quickbase up so that it limits you to leader>Employees in the chain.

This leaves all your employees in one table, but defines a relationship that you may use in your associations table. You then have some options.
1. you can select the leader, and conditionally select an employee (based on 2 relationships to the associations table, the employee relationship conditional on the leader relationship)
2. you can select a leader on the association, and an embedded report link can show the employees related to that leader.
3. you can use the recursive relationship to define custom permission models.


There is a lot here, but let me know if it helps.