Does honeysql support this form insert into foo select * from bar
, or (in addition to) insert into foo (col1, col2) select col1, col2 from bar
?
I'm sure I asked this before...scraping memory
yuus
There's actually a test for that: https://github.com/seancorfield/honeysql/blob/5e087617159fa61a15363bf76ad3d6598dd7d30f/test/honeysql/format_test.cljc#L81
Yup
just worked it out 🙂
(-> (insert-into [[:foo [:col1 :col2] (-> (select :col1 :col2) (from :bar)]) sql/format)