sql

All things SQL and JDBC...
dharrigan 2020-06-28T06:53:11.030600Z

I'm sure I can give it a spin today/tomorrow.

dharrigan 2020-06-28T13:00:28.031100Z

Seems to work okay for me, my application is working as expected.

1
seancorfield 2020-06-28T18:02:29.035300Z

I wouldn't expect any of the changes to break existing code but good to have it confirmed. I think @fabrao is the only person to try the multiple result sets feature so far and maybe @somedude314 could try the changes to find-by-keys...

seancorfield 2020-06-28T18:03:58.036Z

Maybe @antonmos could test the foldable stuff?

adam 2020-06-28T18:11:13.036200Z

Will do

1
antonmos 2020-06-28T18:18:09.036600Z

Yup, first thing tomorrow!

1
adam 2020-06-28T19:45:43.038300Z

@seancorfield Worked flawlessly during manual testing:

user=&gt; (sql/find-by-keys ds :user {:email "<mailto:test@example.com|test@example.com>"} {:table-fn ansi :column-fn ansi :columns [:email]})
[#:user{:email "<mailto:test@example.com|test@example.com>"}]
user=&gt; (sql/find-by-keys ds :user {:email "<mailto:test@example.com|test@example.com>"} {:table-fn ansi :column-fn ansi :columns [:email :role]})
[#:user{:email "<mailto:test@example.com|test@example.com>", :role "parent"}]
user=&gt; (sql/get-by-id ds :user #uuid"a6980a75-842f-4e4b-8328-fcf1166d69be" {:table-fn ansi :column-fn ansi :columns [:email :role]})
#:user{:email "<mailto:test@example.com|test@example.com>", :role "parent"}
user=&gt; (sql/get-by-id ds :user #uuid"a6980a75-842f-4e4b-8328-fcf1166d69be" {:table-fn ansi :column-fn ansi :columns [[:email :whaaat] :role]})
#:user{:whaaat "<mailto:test@example.com|test@example.com>", :role "parent"}
user=&gt; (sql/find-by-keys ds :user {:email "<mailto:test@example.com|test@example.com>"} {:table-fn ansi :column-fn ansi :columns [[:email :cool] :role]})
[#:user{:cool "<mailto:test@example.com|test@example.com>", :role "parent"}]
user=&gt; (sql/find-by-keys ds :user :all {:table-fn ansi :column-fn ansi :columns [[:email :cool] :role]})
[#:user{:cool "<mailto:test2@example.com|test2@example.com>", :role "teacher"} #:user{:cool "<mailto:test@example.com|test@example.com>", :role "parent"}]
user=&gt; (sql/find-by-keys ds :user :all {:fetch 1 :table-fn ansi :column-fn ansi :columns [[:email :cool] :role]})
[#:user{:cool "<mailto:test2@example.com|test2@example.com>", :role "teacher"}]
user=&gt; (sql/find-by-keys ds :user :all {:offset 1 :fetch 1 :table-fn ansi :column-fn ansi :columns [[:email :cool] :role]})
[#:user{:cool "<mailto:test@example.com|test@example.com>", :role "parent"}]

seancorfield 2020-06-28T19:49:02.038600Z

Nice! Thanks @somedude314

adam 2020-06-28T19:51:15.038900Z

You bet. Thanks for the amazing work.