Trying to understand exactly your requirements just to make sure we are on the same page. I’ve setup the following database structure in Baserow as an example:
A students table which manually links to classes and also has a lookup of a department lookup field in the classes table:
And heres a Diagram showing the links between the tables in the above structure, is this what you were describing?
Students uses Lookup to fill the Link from Classes to Teachers
I’m not exactly sure what you mean when you say use a Lookup to fill a Link. Especially a Link between two other tables. Could you explain how it would look given the above table structure?
Are you perhaps asking for something like VLOOKUP in Excel / google sheets? So instead of me making a manual link between teachers and departments, instead the classes table could say use a VLOOKUP field which links a class row to any department row with the same name? Or am going off on a wild tangent here :D?
I guess fundamentally I don’t understand how could the database know which teacher teaches which class if there was only one manual link between student and class? So I can create a link saying Student A takes Maths class, but if I don’t also create a link from Class to Teacher manually how could the database know that on its own?
Ah ok I understand now, thanks for explaining! You want to lookup through multiple tables in one go.
The good news is I literally made the change adding this feature to the formula lookup function a few days ago. It will hopefully make it into one of the next releases.
With this change you would make a formula field and enter the formula lookup('class', 'teacher', 'name') to go through two link fields to the teacher name field. You can go through as many links as you want using this updated lookup function.
Would it just being available via a formula function be ok for your use case?
I could really use this feature right now… but judging by the error message I’m getting, I assume the feature hasn’t made it into a release yet? (I also tried to find a corresponding issue in Gitlab but couldn’t find it).