Here you can find the source of printExceptionAndRollback(Connection conn, Exception e)
public static void printExceptionAndRollback(Connection conn, Exception e)
//package com.java2s; //License from project: Open Source License import java.sql.Connection; import java.sql.SQLException; public class Main { public static void printExceptionAndRollback(Connection conn, Exception e) { printException(e);/*w w w. j a va 2 s . com*/ try { if (conn != null) conn.rollback(); } catch (SQLException ignore) { } } public static void printException(Exception e) { System.out.println("Exception caught! Exiting .."); System.out.println("error message: " + e.getMessage()); e.printStackTrace(); } }