This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-09-14
Channels
- # announcements (40)
- # aws (9)
- # babashka (21)
- # beginners (75)
- # calva (56)
- # chlorine-clover (1)
- # cider (12)
- # circleci (1)
- # clj-kondo (7)
- # cljsrn (13)
- # clojars (3)
- # clojure (171)
- # clojure-dev (11)
- # clojure-europe (64)
- # clojure-nl (11)
- # clojure-spec (6)
- # clojure-uk (9)
- # clojurescript (31)
- # conjure (1)
- # cursive (7)
- # datascript (7)
- # datomic (9)
- # emacs (4)
- # fulcro (65)
- # introduce-yourself (1)
- # jobs-discuss (7)
- # kaocha (7)
- # lsp (39)
- # missionary (5)
- # off-topic (54)
- # pathom (10)
- # re-frame (6)
- # shadow-cljs (110)
- # tools-deps (41)
Hi, I have a question about syncing Datomic (Cloud) data to Datascript. I found an article saying: “Datomic entity IDs can be larger than JavaScript’s`Number.MAX_SAFE_INTEGER`” which means he needed to use a workaround (string). Is this still a problem, are there other solutions?
The article is https://jacobobryant.com/post/2019/ion/
this is definitely still a problem; JS doesn't guarantee integers larger than 29 bits or something, and Datomic uses 64-bit IDs for everything.
so generally I'd say that whatever API you're using to sync Datomic data to DataScript should convert IDs to strings. it's less obvious what to do with actual data values.
I mean, a :db.type/long
field has the same problem. your data may not be too big though.