Bases: only metadata tags are filtered, document tags are not

Steps to reproduce

  1. create a new file and just tag it in the markdown with #tagname
  2. create a new base and filter for tags “tagname”
  3. as you can see there are no results returned

Did you follow the troubleshooting guide? [Y/N]

there isn’t one on this yet I think

Expected result

When filtering for tags I think bases should show all tag reults, both in the yaml(metadata) and in the markdown itself

Actual result

bases only shows tags in the yaml (metadata)

Environment

SYSTEM INFO:
Obsidian version: v1.9.1
Installer version: v1.6.5
Operating system: Windows 11 Enterprise 10.0.22631
Login status: logged in
Language: en
Catalyst license: insider
Insider build toggle: on
Live preview: on
Base theme: light
Community theme: AnuPpuccin v1.5.0
Snippets enabled: 3
Restricted mode: off
Plugins installed: 13
Plugins enabled: 12
1: Homepage v4.2.2
2: Style Settings v1.0.9
3: Dataview v0.5.68
4: Outliner v4.9.0
5: Periodic Notes v0.0.17
6: Templater v2.11.1
7: Readwise Official v3.0.1
8: Auto Note Mover v1.2.0
9: Callout Manager v1.1.0
10: Tag Wrangler v0.6.4
11: Todoist Pull v1.0.0
12: Copilot v2.8.9

RECOMMENDATIONS:
Custom theme and snippets: for cosmetic issues, please first try updating your theme and disabling your snippets. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community theme and snippets.
Community plugins: for bugs, please first try updating all your plugins to latest. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community plugins.


Additional information

I understand bases is in beta and I don’t really know if this should be a bug report or feature request but since one could expect to see all tags and only sees metadata tags I gambled on Bugreport

Thanks for reading and happy coding

What syntax are you using for the query? In a local test, this works:

```base
views:
  - type: table
    name: Table
    filters:
      and:
        - taggedWith(file.file, "tagname")

```

I used the bases UI to set a filter on tags
Maybe a small bug there?
Ill look into it and re-submit if I find a difference

Thanks for the reply

Hey Guapa,

When I create the same bases table with the bases UI the query is different

views:

  • type: table
    name: Table
    filters:
    and:
    - contains(property.tags, “test”)
    order:
    • file.name
    • tags

The UI gives a contains and the query you provided gives a taggedWith

makes sense?

1 Like

You need to select file in the dropdown to select the key (not the tags property) in the filter GUI :blush:

Then you’ll be able to select has tag(I think :sweat_smile: ) in the next dropdown and choose the relevant tag :blush:

Or you can directly enter in the Advanced filter mode by clicking on the </> icon (next to the “trash” one) and write taggedWith(file.file, "tagname")

2 Likes

Aaahhh clear!
Thank you so much

2 Likes