try { insertPS.setString(1, idGenerator.getSegmentValue()); value.bind(insertPS, 2); executeUpdate(insertPS, statsCollector); } finally { updateValue.increment(); updateValue.bind(updatePS, 1); value.bind(updatePS, 2); updatePS.setString(3, idGenerator.getSegmentValue()); rows = executeUpdate(updatePS, statsCollector);
try { insertPS.setString(1, idGenerator.getSegmentValue()); value.bind(insertPS, 2); executeUpdate(insertPS, statsCollector); } finally { updateValue.increment(); updateValue.bind(updatePS, 1); value.bind(updatePS, 2); updatePS.setString(3, idGenerator.getSegmentValue()); rows = executeUpdate(updatePS, statsCollector);
statementLogger.logStatement( insert, FormatStyle.BASIC.getFormatter() ); ips = connection.prepareStatement( insert ); value.bind( ips, 1 ); ips.execute(); PreparedStatement ups = connection.prepareStatement( update ); try { value.copy().increment().bind( ups, 1 ); value.bind( ups, 2 ); rows = ups.executeUpdate();
statementLogger.logStatement( insert, FormatStyle.BASIC.getFormatter() ); ips = connection.prepareStatement( insert ); value.bind( ips, 1 ); ips.execute(); PreparedStatement ups = connection.prepareStatement( update ); try { value.copy().increment().bind( ups, 1 ); value.bind( ups, 2 ); rows = ups.executeUpdate();