Fork me on GitHub
#xtdb
<
2021-10-03
>
mac14:10:20

I am having some serious performance issues (x1000 compared to raw clojure code operating on all relevant documents) with a query that contains a number of not joins. Is there anything in particular I need to be aware of regarding not joins?

refset20:10:45

not rules run as subqueries and don't/can't participate lazily in the join execution, which means large intermediate result sets will be created, but you may be able to improve things by using not-join instead of not if you're not already. Are you using not to work around the absence of attributes / nils? In some cases there is little that can be done at query-time but there's usually always a write-time solution. If you can share an example query I will try to help with some specific suggestions. Feel free to DM/email me if it's sensitive (no need to simplify / create a minimal repro). Edit: now DMing to resolve it