obsidian-query-language icon indicating copy to clipboard operation
obsidian-query-language copied to clipboard

search by tag

Open svonjoi opened this issue 3 years ago • 0 comments

Search by tag like these query: "'#my-tag" working but i cannot make AND & OR conditions with tag.

  1. I just want to list notes that in folder "'Folder/" that contains that tag
  2. if tag is declared as metadata --- Tags: my-tag --- this way search dont work

Solution that seems to solve these issues is following query: { $and: [ { "path": "'Folder/" }, { $or: [{ "content": "Tags: my-tag" }, { "content": "'#my-tag" }]}]} But this way if i have tag named #my-tag-2 its match and with some tags this solution make strange things, its just match random notes from this folder that dont have nothing to do with the tag

svonjoi avatar Jan 16 '22 18:01 svonjoi