How do I make a list of all tasks with a certain tag in them?

Things I have tried

Seems weird to say what I’ve tried before explaining the problem, but OK:
I tried this syntax and am not sure what to do from here.

task where contains(task.text, "#context/XYZ")

What I’m trying to do

I want to write a query that searches for all tasks in my vault that have the tag #context/XYZ in them

Here is an example task I’d like it to “notice” no matter where I put it:

  • [ ] #task #context/XYZ buy lemons :arrow_up_small: :date: 2022-05-20

How would this be done? Seems simple but I’m failing to get it right. thanks for any help

I guess you are not yet in beta version of dataview. Then, you need to use this:

TASK
WHERE contains(text, "#context/XYZ")

In a future release you can use this:

TASK
WHERE contains(tags, "#context/XYZ")
2 Likes

I guess you are not yet in beta version of dataview.

How would I get the beta version? I had no idea there was one! Never mind, I figured it out using BRAT plugin.

To install beta versions of themes and plugins you need to install BRAT plugin: GitHub - TfTHacker/obsidian42-brat: BRAT - Beta Reviewer's Auto-update Tool for Obsidian. Part of the Obsidian42 family of plugins.

EDIT: there’re some changes in the way tasks metadata are structured. You will notice that…

1 Like

there’re some changes in the way tasks metadata are structured. You will notice that…

Is there documentation about the changes and uses? I love new and shiny haha

you beat me to the BRAT explanation thanks for that too

No documentation. I guess that is the main cause because the developer has not yet released the public version…

EDIT: you can read the summary of the beta releases in the GitHub pages. One new feature: now you can embed images in tables and list queries using internal links.

1 Like

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