summaryrefslogtreecommitdiff
path: root/src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java')
-rw-r--r--src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java b/src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java
index 0d62c74c9a..86b1a4fc79 100644
--- a/src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java
+++ b/src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java
@@ -17,7 +17,7 @@ import org.postgresql.largeobject.*;
import org.postgresql.util.*;
/*
- * $Id: Connection.java,v 1.18 2002/03/26 05:52:50 barry Exp $
+ * $Id: Connection.java,v 1.19 2002/06/11 02:55:16 barry Exp $
*
* A Connection represents a session with a specific database. Within the
* context of a Connection, SQL statements are executed and results are
@@ -318,6 +318,14 @@ public class Connection extends org.postgresql.Connection implements java.sql.Co
Types.ARRAY
};
+ //Because the get/setLogStream methods are deprecated in JDBC2
+ //we use the get/setLogWriter methods here for JDBC2 by overriding
+ //the base version of this method
+ protected void enableDriverManagerLogging() {
+ if (DriverManager.getLogWriter() == null) {
+ DriverManager.setLogWriter(new PrintWriter(System.out));
+ }
+ }
}