Multi-value properties and queries

I want the ability to have a property which has several values. For example, in my videos, I want a topic property which might look like

topic:: logseq, queries

there seem to be several issues with this that I’m unable to resolve. First, it appears that logseq views the above as a property with a single value “logseq, queries” instead of “logseq” and “queries”. Second, if I don’t include double quotes around the values, it tries to create pages called “logseq” and “queries”. I don’t want the extra pages and i want “topic” to be treated as it as 2 properties so that if I query (property topic logseq), I get a hit. This seems like it should be straight forward. What am I missing?

1 Like

Hi. If you don’t put quotes, it is correct to see logseq treat those two values as pages. The simple query (property topic logseq) should be working for that case. If it is not, feel free to file a bug and provide reproducible steps at Issues · logseq/logseq · GitHub. As for not having multiple property values treated as pages, that would be a feature request you could file at Feature Requests - Logseq. Cheers

Oh boy, I just started using logseq a couple of days ago. Just after familiarizing with properties and queries, I came to a structure of properties that I would like to have where I do need hierarchies.

You need to wrap each individual value in double brackets, so it should be topic:: [[logseq]] [[queries]]. Yes, this would create logseq and queries pages. but try clicking on topic and you’ll see that it is actually a page too (unless you have :property-pages/enabled? set to false in your config.edn). I was also obsessed with controlling every single detail, not having anything which are unnecessary, but I learned how to let go of this. Besides, it became helpful: if I forgot what a property value is for, I look up the page then I read a note in it that I have written for myself. The most important thing here is, what you want to look for should always come up in a query.

1 Like