Creating links from dataview table results?

First, search the help docs and this forum. Maybe your question has been answered! The debugging steps can help, too. Still stuck? Delete this line and proceed.

What I’m trying to do

So I use a simple query based on tags to keep tables of books I am reading, want to read, and have read. These tables are

in a file called reading

file.mtime as Modified
FROM #fiction
SORT file.mtime DESC

This displays the table in the image. My question is, is there a way to make the links displayed in the table actually linked to the file? So that if I was in the Battle Royale file, for example, there would be a back link to the reading file. I would like to do this through a dataview query, instead of manually creating the links.

Things I have tried

I tried adding link( in the query, but it still doesn’t create a backlink from the book files.

hmmm… I tried it with your dataview table, and it works fine for me

Or do you mean something else?

No, those links are fake. You can only click on them. They do not show up anywhere else like the graph view, back links, etc.

If you want to make it works, you need to actually write the links into the file, which requires a lot of DataviewJS.


I had no idea that they are fake links. I don’t really use graphview, so I never realized that. I usually do it with templater: [[<% tp.file.folder() %>]] which creates a backlink to the parent note, because I use Folder Note.
It does not use dataview, but just writing the dataview note between brackets in your template might be an easy fix to your problem, if you use a template for your books, that is.

1 Like

What you’re talking about here is making persistent query results, which in turn will make the links appear in the graph view, and as links and backlinks when doing other queries. This is currently not easily done using Dataview, and is a promised feature of its successor, Datacore.

For two other posts related to persisting queries, and some feeble attempts see the following threads:

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.