openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fayw...@apache.org
Subject svn commit: r988164 - in /openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc: kernel/exps/CurrentDate.java sql/SolidDBDictionary.java
Date Mon, 23 Aug 2010 16:01:45 GMT
Author: faywang
Date: Mon Aug 23 16:01:45 2010
New Revision: 988164

URL: http://svn.apache.org/viewvc?rev=988164&view=rev
Log:
OPENJPA-735: OpenJPA support for SolidDB

Modified:
    openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/exps/CurrentDate.java
    openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SolidDBDictionary.java

Modified: openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/exps/CurrentDate.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/exps/CurrentDate.java?rev=988164&r1=988163&r2=988164&view=diff
==============================================================================
--- openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/exps/CurrentDate.java
(original)
+++ openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/exps/CurrentDate.java
Mon Aug 23 16:01:45 2010
@@ -64,11 +64,10 @@ class CurrentDate
     
     public Object getValue(Object[] params) {
         try {
-            _type.getConstructor(long.class).newInstance(System.currentTimeMillis());
+            return _type.getConstructor(long.class).newInstance(System.currentTimeMillis());
         } catch (Exception e) {
             return new Date();
         }
-        return null;
     }
 
     public void appendTo(Select sel, ExpContext ctx, ExpState state, SQLBuffer sql, int index)
{

Modified: openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SolidDBDictionary.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SolidDBDictionary.java?rev=988164&r1=988163&r2=988164&view=diff
==============================================================================
--- openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SolidDBDictionary.java
(original)
+++ openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SolidDBDictionary.java
Mon Aug 23 16:01:45 2010
@@ -119,6 +119,7 @@ public class SolidDBDictionary
         supportsNullUniqueColumn = false;
         
         concatenateFunction = "CONCAT({0},{1})";
+        stringLengthFunction = "LENGTH({0})";
         trimLeadingFunction = "LTRIM({0})";
         trimTrailingFunction = "RTRIM({0})";
         trimBothFunction = "TRIM({0})";



Mime
View raw message