metadatamenu icon indicating copy to clipboard operation
metadatamenu copied to clipboard

FR: Relationship Field (Link Field and Lookup Query Field Combo)

Open chauser10 opened this issue 2 years ago • 7 comments

I do not understand what is required technically for this to be implemented, but it looks like the lookup query field and the multi-link field provides an experience similar to what I am looking for. This feature has been implemented in notion if you are familiar with their databases and relationships feature.

Not sure if new field types would need to be created or additional options can be added to existing fields. I would like an auto populating field like the lookup query field, that I can also update via the controls like a link or multi link field. That way I can create a one-to-one, one-to-many, or many-to-many relationships that update automatically.

chauser10 avatar Dec 29 '22 23:12 chauser10

I'm not sure I understand correctly what you want to achieve.

Could you try to give an example?

mdelobelle avatar Jan 03 '23 22:01 mdelobelle

Forgive me if I'm incorrect, but it sounds like bidirectional linking? Like Notion does automatically. If you set up a relation to another table or entity, it will automatically show that relationship on both sides, rather than having to input it twice.

Here is how Notion sets it up: Screenshot 2023-01-03 at 18 59 45

Apologies if this wasn't what you meant...

arminta7 avatar Jan 04 '23 00:01 arminta7

@arminta7 you got it!

I think the best example is to show you a little video from notion of the functionality I am looking to replicate. I apologize I am not able to help from a development level.

Video Example

I currently have a workaround. I use a combination of two fields, a select field and a lookup query field. The select field provides options of tasks or projects to link. The query field shows where the task or project I am currently in has been linked to. That way if I link a project or task I know the other file with add a link to where I currently am.

chauser10 avatar Jan 04 '23 00:01 chauser10

I tried to sort of create this using the current options, but I think it's causing a loop:

https://user-images.githubusercontent.com/7927356/213894295-c65b1b5e-c970-4404-9417-97870d5b739e.mov

Also, in thinking about it more, what would be perfect is a vault-wide bidirectional link option. Instead of having to create a setting for every relationship. So like in my video, match the tags and the field names. I don't know how resource intensive that would be. It could even be its own plugin I'm sure.

arminta7 avatar Jan 21 '23 23:01 arminta7

I tried to sort of create this using the current options, but I think it's causing a loop:

Screen.Recording.2023-01-21.at.18.39.56.mov Also, in thinking about it more, what would be perfect is a vault-wide bidirectional link option. Instead of having to create a setting for every relationship. So like in my video, match the tags and the field names. I don't know how resource intensive that would be. It could even be its own plugin I'm sure.

@arminta7 - Any luck recreating bi-directional linking? Sorry to resuscitate a stale thread. Im rebuilding my vault after using Fibery for a bit, but still like the local nature of obsidian. I've been able to hack some solutions together but requires some setup and always seems buggy.

chauser10 avatar Nov 21 '23 21:11 chauser10

Yes, it takes some manual set up but it's working well for me now, especially after the latest beta updates.

For example I have two tags #project and #goal. #project has a lookup field "Goals" and #goal has a lookup field "Projects". This is what the settings look like:

Screenshot 2023-11-22 at 10 15 37 Screenshot 2023-11-22 at 10 16 11

Maybe in the future the setup can be streamlined a bit better with a dedicated bi-directional relation type but for now this works just fine!

arminta7 avatar Nov 22 '23 15:11 arminta7

I’ll explore that

mdelobelle avatar Nov 24 '23 05:11 mdelobelle