I might be missing something obvious: how do you filter for documents that were inserted within a particular time interval?
why does xt/system-time behave differently from xt/system-from here?
-time returns no results while -from does. and -time seems to work with strictly-contains while -from does not, saying strictly_contains? not applicable to types struct and timestamp-tz
-time also works with succeeds? while -from does not, maybe the plumbing just isn't there to cast it to the right type?
I think it's just broken actually, since the same query returns no results with -time with both precedes and succeeds (but would return results without that condition entirely)
system-time is the period of system-from to system-to (unbounded in this case), so by using system-time you're heading into https://docs.xtdb.com/reference/main/stdlib/temporal.html#_periods territory. in the case of contains, your from/to doesn't contain that whole system-time period, so it'll filter it out
contains is one of the few (IIRC it may even be the only) period predicates that accept period/instant - all the others only accept period/period
would WHERE PERIOD(<from>, <to>) CONTAINS xt$system_from work for you?
sorry, (contains? (period #inst "<from>" #inst "<to>") xt/system-from)
thanks, that clears it up. so -time means period, the others mean instant