Fork me on GitHub
#datalevin
<
2021-10-21
>
Huahai02:10:57

i am not sure what you are trying to do. index-range gives datoms with the same attribute. How do you plan to use other attributes?

Huahai04:10:04

you can pass the results of index-range as one of the arguments to another query, if that’s what you are getting at?

jjttjj14:10:10

Oh yeah, thanks, think I got that working

(dl/q
  '[:find ?x
    :in $ ?a1 [[?e]]
    :where 
    [?e :attr1 ?a1]
    [?e :x ?x]]
  @conn1
  "a1"
  (dl/index-range @conn1 :ts
    (- (System/currentTimeMillis) (* 1000 60))
    (System/currentTimeMillis)))

ericdallo14:10:08

does datalevin already work with 21.3.0? I intend to bump clojure-lsp soon to use 21.3.0

Huahai15:10:21

have not tried yet, will do

👍 1