List:Commits« Previous MessageNext Message »
From:tikeda Date:January 25 2006 9:53pm
Subject:Connector/J commit: r4848 - in branches/branch_5_1/connector-j/src: com/mysql/jdbc testsuite/simple
View as plain text  
Modified:
   branches/branch_5_1/connector-j/src/com/mysql/jdbc/PreparedStatement.java
   branches/branch_5_1/connector-j/src/testsuite/simple/StatementsTest.java
Log:
added source code comment to PreparedStatement.setNString method

Modified: branches/branch_5_1/connector-j/src/com/mysql/jdbc/PreparedStatement.java
===================================================================
--- branches/branch_5_1/connector-j/src/com/mysql/jdbc/PreparedStatement.java	2006-01-25 20:56:22 UTC (rev 4847)
+++ branches/branch_5_1/connector-j/src/com/mysql/jdbc/PreparedStatement.java	2006-01-25 21:53:57 UTC (rev 4848)
@@ -2430,6 +2430,7 @@
             setNull(parameterIndex, Types.CHAR);
         } else {
             int stringLength = x.length();
+            // Ignore sql_mode=NO_BACKSLASH_ESCAPES in current implementation.
 
             // Add introducer _utf8 for NATIONAL CHARACTER
             StringBuffer buf = new StringBuffer((int) (x.length() * 1.1 + 4));

Modified: branches/branch_5_1/connector-j/src/testsuite/simple/StatementsTest.java
===================================================================
--- branches/branch_5_1/connector-j/src/testsuite/simple/StatementsTest.java	2006-01-25 20:56:22 UTC (rev 4847)
+++ branches/branch_5_1/connector-j/src/testsuite/simple/StatementsTest.java	2006-01-25 21:53:57 UTC (rev 4848)
@@ -1415,6 +1415,29 @@
 			this.stmt
 					.executeUpdate("DROP TABLE IF EXISTS testTruncationOnRead");
 		}
-
 	}
+    
+    /**
+     * Tests for PreparedStatement.setNString()
+     * 
+     * @throws Exception
+     */
+    public void testSetNString() throws Exception {
+        this.stmt.executeUpdate("DROP TABLE IF EXISTS testSetNString");
+        this.stmt.executeUpdate("CREATE TABLE testSetNString (c1 NATIONAL CHARACTER(10))");
+        
+        Properties props = new Properties();
+        props.put("useServerPrepStmts", "false");
+        Connection conn = getConnectionWithProps(props);
+        
+    }
+    
+    /**
+     * Tests for ServerPreparedStatement.setNString()
+     * 
+     * @throws Exception
+     */
+    public void testSetNStringServer() {
+        
+    }
 }

Thread
Connector/J commit: r4848 - in branches/branch_5_1/connector-j/src: com/mysql/jdbc testsuite/simpletikeda25 Jan