List all values not included in other notes

What I’m trying to do

I have 40 different values for propertyX. Around 10 different notes use propertyX with different values. I have one note (MainNote) that contains all the values. I want to make a list of the values that are only contained in MainNote and not in any of the other 10 notes.

Things I have tried

list propertyX from "path/MainNote"
where propertyX

But I have no idea how to exclude the values used in the other 10 notes.

What do the following get you:

WHERE propertyX
FLATTEN propertyX as property
GROUP BY property
WHERE length(rows) = 1

In theory this should look through your vault for any file with propertyX, flatten it out, if it’s an list, then it’ll group up those having the same property, before excluding all those being in more than one file. It’ll then display the property it only finds once, along with the file(s) (but there should only be one) where it’s located.

In theory that should list only the MainNote, or any other files having a unique property value. If that’s a problem you could most likely do a secondary where clause verifying that the file list actually contains the MainNote…

1 Like

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