Hi, On Jan 27, 3:43 pm, Roman Roelofsen <roman.roelof...@googlemail.com> wrote:
> when querying data in clojureql, the result is a list of maps. I often > directly return this list (or a map) from my "db-logic" functions > because my domain logic operates on these maps. However, I am not able > to go the other way around, e.g. take the map and tell clojureql to > insert/update a table row. Currently I have to do this: > > (sql/insert-into Person > [firstname "Roman" > lastname "Roelofsen"])) > > What I would like to do is something like this: > > (def person {:firstname "Roman" :lastname "Roelofsen"}) > (sql/insert-into Person person)) > > Is this possible? Not at the moment. You have to do: (sql/insert-into Person [firstname ~(:firstname person) lastname ~ (:lastname person)]) But the ClojureQL DSL in currently in flux and will change in the (hopefully) near future. Sincerely Meikel -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en