1 May 2024 |
jayp011 | Hi all - I want to write a query which returns all the scheduled tasks before a certain number of days which is dynamically passed into the query as a function argument | 13:41:41 |
| jayp011 changed their display name from j_._.p to jayp011. | 13:41:46 |
jayp011 | looked a lot into passing in arguments to functions but couldn't figure it out | 13:42:00 |
jayp011 | is there anyone who has tried to execute a similar query | 13:47:05 |
jpi_joshg_09073 | Is there a way to sort an advanced query results by each result's page name? I'm working with a team in the same graph. We use each day's journal page as an index for each person's daily notes, but each team member works on their own page with the following syntax 'yyyy-mm-dd-[initials]'. Since we aren't taking our notes in the daily journal page, our notes don't have a date associated with them and show up out of order in query results. | 15:15:17 |
jpi_joshg_09073 | * Is there a way to sort an advanced query results by each result's page name?
I'm working with a team in the same graph. We use each day's journal page as an index for each person's daily notes, but each team member works on their own page with the following syntax 'yyyy-mm-dd-[initials]'. Since we aren't taking our notes in the daily journal page, our notes don't have a date associated with them and show up out of order in query results. Sorting by host page name should get our results in chronological order | 15:16:35 |
xarielml | I have a page not in the journal which I can sort by date in query. I did this by making a date property that I use for each entry on the page. | 18:43:16 |
jayp011 | anyone have any idea? I can get the scheduled tasks for today or tomorrow but if I wanna get tasks scheduled before 10 days or so I'm unable to figure it out | 18:53:33 |
2 May 2024 |
xarielml | This query picks up all blocks with lit references (matching the input regex). I'd like to exclude blocks where the lit reference is a page - so it'd pick up @Test2024 but not [[@Test2024]] . Not sure how to approach this, is it even possible?
#+BEGIN_QUERY
{:title "References without pages"
:query
[:find (pull ?block [*])
:in $ ?input
:where
[(str "(?i)" ?input) ?pattern]
[?block :block/content ?content]
[(re-pattern ?pattern) ?captured]
[(re-find ?captured ?content)]]
:inputs ["@[a-zA-Z]+\\d{4}"]
}
#+END_QUERY | 00:32:29 |
xarielml | * This query picks up all blocks with lit references (matching the input regex). I'd like to exclude blocks where the lit reference is a page - so it'd pick up @Test2024 but not [[@Test2024]] . Not sure how to approach this, is it even possible?
#+BEGIN_QUERY
{:title "References without pages"
:query
[:find (pull ?block [*])
:in $ ?input
:where
[(str "(?i)" ?input) ?pattern]
[?block :block/content ?content]
[(re-pattern ?pattern) ?captured]
[(re-find ?captured ?content)]]
:inputs ["@[a-zA-Z]+\\d{4}"]
}
#+END_QUERY | 00:32:53 |
| AdmiralLogseeker changed their profile picture. | 00:49:31 |
| danadane. joined the room. | 04:17:44 |
| darbaga joined the room. | 04:45:05 |
| flaihigh. joined the room. | 07:03:41 |
| .persici changed their display name from Persici to .persici. | 07:35:59 |
| un_qui_et changed their profile picture. | 10:22:56 |
| matpisarr joined the room. | 15:05:31 |
| penguin629 joined the room. | 16:21:26 |
| baalah joined the room. | 19:06:17 |
jpi_joshg_09073 | That's interesting, how do you pull that into the transform function? | 19:08:40 |
| @felipebarros:matrix.org joined the room. | 21:54:36 |
| @felipebarros:matrix.org left the room. | 21:54:37 |
| yengecbey joined the room. | 22:02:26 |
3 May 2024 |
| Jacob joined the room. | 00:43:35 |
| viking2933 joined the room. | 08:07:59 |
| hummushooman8524 joined the room. | 14:18:55 |
| down3355 joined the room. | 22:20:33 |
down3355 | Lads i'm sure this is a stupid question but i'm a complete beginner. How do I query for a random block in my vault | 22:20:34 |
| down3355 changed their profile picture. | 22:20:34 |
down3355 | Thanks lads | 22:20:36 |