I don’t think the standard DQL queries are able to extract the keys of an object, so you need to switch to dataviewjs if I’m not mistaken. Then you’re able to use Object.keys() to extract the keys of an object like file.frontmatter (or the equivalent).
Thanks @holroy! Too bad, that it’s not possible with normal dataview, as I don’t understand java script too much…
Your second script works, it produces a table with two columns:
column: all files, that have note_type = “source”
column: all the frontmatter-keys of each file
… could you please help me, to modify that script, so that it will generate a list instead of table, which shows the consolidated frontmatter-keys, which are in the files. => each frontmatter-key should be listed just once, even though it occurs in more than one file.
… I already asked ChatGPT for that, but didn’t get a reasonable answer…
Have you tried turning on the core plugin of Properties view, and executing the Properties: Show all properties command? This’ll list all frontmatter keys, with a count of how many times it’s used, if I’m not mistaken (on mobile now).
Hi holroy,
thanks for your answer!
Yeah, I know this feature. As I recently changed my PKM system (no “note_type:: source” properties anymore, but #source tags instead) I don’t need such a Table anymore.
Cheers,
Silias
I’ve been a little back and forth, but currently I’m using note_type: ??? style, as it’s easier to query, and I like the look of it, and my personal opinion is that it doesn’t clutter up the tag cloud as much. But to each their own.