All the addins I’ve seen which try to grant better sorting capabilities seem to sort notes by file creation date using the system file as source of truth. This doesn’t work for me. I need it to be sorting by the “creation date” data populated in the YAML frontmatter of my notes… Any ideas?
I’m assuming you already tried sorting using your creation date
YAML frontmatter field name and it didn’t work. If so, it’s because of the space in the property name. You could try…
SORT row["creation date"] ASC
https://www.reddit.com/r/ObsidianMD/comments/1gjfk7i/dataview_and_property_list_issue/
Are you talking about the file explore in the right side pane, or a query somewhere within your notes?
If the first, I’m not sure if that’s doable as such, which is one of the reasons I’m using an ISO date format for my daily note entries, so that they’re sorted correctly.
There is a plugin called Custom File Explorer sorting which offers some extended ways of sorting the file explorer, and one of its options is to use metadata, so maybe you could do something like shown in the link below:
Not tested example, but possibly something like:
sorting-spec: |
target-folder: Book notes
< a-z by-metadata: creation date
I’m talking about int he file EXPLORER OR in a note using dataview (i’d obviously prefer file explorer but not sure if it’s possible)
But yes, your thread seems to be the solution i’m looking for… Just can’t get it to work
yeah it didn’t work…
it’s weird it’s showing everything as having the date that i migrated from onenote to obsdian…
How does it not work? What did you try to use as sorting specifications?
Did you use creation date
as you writev in your first post? Or created
as you mention in the example related to the query post? Or file.ctime
as in the other thread?
The quality of our answers is depending on your information, and we need precise details on your setup and configuration to be able to guide you correctly.
Assuming created
is the actual property a sorting spec like the following should work:
sorting-spec: |
target-folder: /*
< a-z by-metadata: created
That is given that you want this sorting for all files in all folders.
For the Dataview query you could use something like:
```dataview
TABLE file.folder as Folder, created
SORT file.folder, created
```
This should show all files sorted first by folder, and then by the created
of the files within that folder.
wow, this is amazing. The sortspec worked—this is EXACTLY what I was looking for.
Thank you so much…
The data view table not quite working — what is it populating the table with? Looks like every note I Have? Is there a way to make it only do like notes in a directory? I tried
FROM “SOFTWARE/KVYO”
To no avail
Thanks sooo much w/ the sortspec
It seems like you’ve used smart quotes there, so try doing this variant:
```dataview
TABLE file.folder as Folder, created
FROM "SOFTWARE/KVYO"
SORT file.folder, created
```
These are double straight quotes, not the slightly slanted smart quotes. Dataview (and my other technical variants) are lucky in their quotes.
I see…
I’m getting a “no results” in my table. Yet I definitely have my folders organized so that it is:
“VAULT NAME” then a “SOFTWARE” folder, within which a “KVYO” folder. (Yes using straight quotes now — thank you). It doesn’t work for just “software” either…
Is that the letter “O” or the number zero, “0”? I might have written the number…
Do you get any output with FROM "SOFTWARE"
?
Yep, looks like that was it.
Can’t thank you enough, you’ve been so helpful.
While I have you though, was wondering if dataview can cause this: just noticed two folders in my vault called “Software” and “software” — (I’m just realizing that folders/directories are case sensitive). But what is weird is that both directories have basically identical contents: All notes in there exactly the same. So basically the directory was duplicated and i have no idea what caused it. No way something like dataview could cause this, right? I assume it’s a weird addon I miss configured…
Thanks for all the help!
Nvm.
It’s some weird syncing issue w/ my iPad. Not dataview related…
Thanks for the help once again.