Author: pcl
Date: Tue Mar  6 01:33:06 2007
New Revision: 515043

URL: http://svn.apache.org/viewvc?view=rev&rev=515043
Log:
OPENJPA-80: MySQL escape string for string matches queries

Modified:
    
incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/MySQLDictionary.java

Modified: 
incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/MySQLDictionary.java
URL: 
http://svn.apache.org/viewvc/incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/MySQLDictionary.java?view=diff&rev=515043&r1=515042&r2=515043
==============================================================================
--- 
incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/MySQLDictionary.java
 (original)
+++ 
incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/MySQLDictionary.java
 Tue Mar  6 01:33:06 2007
@@ -101,6 +101,9 @@
             "LOAD", "MEDIUMINT", "OPTION", "OUTFILE", "REPLACE",
             "SET", "STARTING", "TEXT", "UNSIGNED", "ZEROFILL",
         }));
+
+        // MySQL requires double-escape for strings
+        searchStringEscape = "\\\\";
     }
 
     public String[] getCreateTableSQL(Table table) {


Reply via email to