How Do I Search Certain Frontmatter?

I know that I can use something like the following to give me a list of pages with a certain Tag. But how do I do the same type of query for a different piece of frontmatter?

${template.each(query[[from index.tag "planning" where not _.done limit 10]], templates.pageItem)}

you mean not a tag, but something else?

${query[[from p = index.pages() where p.otherAttribute == "some value"]]}

This queries all pages that have a otherAttribute attribute set to "some value"

Perfect! Thank you.