Dataview table that includes pages with two different values for YAML

I am trying to create a table that shows every page that has a yaml value for status of either closed or archived and I have tried

WHERE contains(status, "Closed") AND !contains(status, "Archived")

For some reason, this only shows the pages that are labeled as closed. How can I get it to show both values

I am not 100% familiar with dataview, but I am pretty sure:

  1. !contains means “does not contain”.
  2. AND would mean it needs both criteria to be true. If you want either closed or archived, you’d want OR.
table
WHERE contains(status, "Closed") OR contains(status, "Archived")

Wonderful! thanks. I kept finding answers with the !contains but I must have misread them

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