Here you can find the source of setAutoCommit(Connection conn, boolean autoCommit)
public static boolean setAutoCommit(Connection conn, boolean autoCommit)
//package com.java2s; //License from project: Open Source License import java.sql.Connection; public class Main { public static boolean setAutoCommit(Connection conn, boolean autoCommit) { if (conn == null) { return true; }/*from www . j a va 2 s . c om*/ try { conn.setAutoCommit(autoCommit); } catch (Exception e) { return false; } return true; } }