Using jdbc ojdbc8_g with a Groovy script.
If I execute an insert statement with bind variables, then I see this in the jdbc log (as expected):
Aug 01, 2020 9:08:32 AM oracle.jdbc.driver.OracleStatement logSQL
CONFIG: 16AED49F SQL: INSERT INTO Author (firstname, lastname) VALUES (?, ?)
However, I noticed (using Wireshark) that two network roundtrips were being performed. One for the INSERT, and then another with a SELECT statement: SELECT firstname,lastname FROM Author
If I set the JDBC logging level to FINEST then I also see the select statement.
- What is the purpose of this statement?
- How can this extra network roundtrip be avoided?