What is the best way to create one document that would automatically display all to-do blocks scattered in all other documents? Something that would act as a to-do's dashboard.
Do I need to use tags or some page showing search results to achieve it?
What is the best way to create one document that would automatically display all to-do blocks scattered in all other documents? Something that would act as a to-do's dashboard.
Do I need to use tags or some page showing search results to achieve it?
You can use embed block, and then insert this query
For unfinished task
SELECT * FROM blocks WHERE markdown LIKE '%[ ]%' AND subtype = 't' AND type = 'i'
For finished task
SELECT * FROM blocks WHERE markdown LIKE '%[x]%' AND subtype = 't' AND type = 'i'
OK so after looking at the sql in the template mentioned above, I noticed it does NOT have "{{...}}". So I tried the above sql again; but this time WITHOUT the curly brackets...and viola it works!😄
I am also trying to achieve the same thing; so I copied and pasted these queries ; but I get the same error message as the original poster: "Search content block does not exist".
It would be great to have a built in configurable tasks dashboard or kanban in the future.
But for now I would just be happy if I could get this to work
Many thanks in advance for any help
I have since tried the "Simple Todo" Template, which seems to work to some degree: for example to pull in tasks from within the last month it creates and embed with the following sql:
SELECT * from blocks WHEREtype= "l" ANDsubtype= "t" ANDcreated>= strftime('%Y%m%d%H%M%S', datetime('now', '-1 month')) AND markdown REGEXP "\* \[ \] \S+" ANDparent_idnot in ( selectidfrom blocks wheresubtype= "t" ) ORDER BYcreatedDESC
Hope this might help someone.
Looks like I need to learn some sql query language :)
Welcome to here!
Here we can learn from each other how to use SiYuan, give feedback and suggestions, and build SiYuan together.
Signup About