DriverManager.setLogWriter(pw);
ex = new SQLNestedException("A", new Exception("a"));
ex.printStackTrace();
ex.printStackTrace(ps);
ex.printStackTrace(pw);
ex = new SQLNestedException("B", null);
ex.printStackTrace();
ex.printStackTrace(ps);
ex.printStackTrace(pw);
ex = new SQLNestedException(null, new Exception("c"));