Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我刚刚解决了这个问题。由于它不在文档中并且需要您深入研究源代码,因此这似乎是解决方案的正确场所。
在 ClojureQL 中,如何创建如下查询:
SELECT * from foo where id in (1, 5, 7);
您需要使用in谓词命名空间中的谓词,例如
in
(require '[clojureql.core :as ql]) (require '[clojureql.predicates :as pred]) (ql/select (ql/table :foo) (ql/where (pred/in :id [1 5 7])))