Fork me on GitHub
#datahike
<
2022-05-11
>
Francisco Carvalho22:05:29

Hi everyone! I'm trying to retract a whole entity with (d/transact conn [[:db.fn/retractEntity 17]]) but I'm getting the following error, which I don't really understand because I didn't think I was touching tempids

; 2022-05-11T22:34:38.072Z LAPTOP-7VGTS0VK ERROR [datahike.db:1958] - Can't use tempid in ' [:db.fn/retractEntity "kek.txt"] '. Tempids are allowed in :db/add only {:error :transact/syntax, :op [:db.fn/retractEntity "kek.txt"]}
; 2022-05-11T22:34:38.074Z LAPTOP-7VGTS0VK ERROR [datahike.connector:86] - Error during transaction Can't use tempid in '[:db.fn/retractEntity "kek.txt"]'. Tempids are allowed in :db/add only
; Execution error (ExceptionInfo) at datahike.db/transact-tx-data (db.cljc:1958).
; Can't use tempid in '[:db.fn/retractEntity "kek.txt"]'. Tempids are allowed in :db/add only

kkuehne17:05:23

Hi, could you provide your whole tx data if possible? How does your schema look like?

Francisco Carvalho12:05:17

Wondering if I should file a bug report

kkuehne10:05:33

Yeah please do, so we can keep track of that.

kkuehne10:05:21

Also from the look of your :tx-data , I can see that you're using strings as entity IDs. Datahike is not usually supporting that since you can simply use :fs/path as a reference.