The sql in CallOutInOut.bpartner left join c_bpartner and both c_bpartner_location and ad_user. This causes performance issue for bp with many locations and contacts.
Hi , about pull request 184:
Wouldn't be better to apply the same fix that you did for CalloutOrder in IDEMPIERE-3654, commit ad868d
I integrated the same approach in 4aac55 for CalloutInvoice, CalloutInvoiceBatch, and CalloutOrder.bPartnerBill; but I think I forgot to port it to CalloutInOut.
On a different topic, I saw your change for PreparedStatement from DB.close to try-with-resources, that's a nice approach, but I think maybe I introduced a problem in our code?
I mean, the PreparedStatement.close is not equivalent to the DB.close because I'm checking there if the statement was executed in the replica and closing it accordingly, maybe that code must be moved elsewhere? Or must we avoid try-with-resources for PreparedStatement?
This wasn’t build by me although I did review it. Will cross check with IDEMPIERE-3654.
I’ve not follow what have been changed in DB.close but If try-with-resources doesn’t work with PrepareStatement in iDempiere, that’s a pretty strong violation of Java coding standard. I means practically, no Java Developer will expect that.