db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arm...@apache.org
Subject svn commit: r395865 - in /db/ojb/trunk/src/java/org/apache/ojb/broker/platforms: PlatformDb2Impl.java PlatformOracleImpl.java PlatformSapdbImpl.java
Date Fri, 21 Apr 2006 12:02:31 GMT
Author: arminw
Date: Fri Apr 21 05:02:30 2006
New Revision: 395865

URL: http://svn.apache.org/viewcvs?rev=395865&view=rev
Log:
fix problem with database sequence NOCACHE flag

Modified:
    db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformDb2Impl.java
    db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformOracleImpl.java
    db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformSapdbImpl.java

Modified: db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformDb2Impl.java
URL: http://svn.apache.org/viewcvs/db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformDb2Impl.java?rev=395865&r1=395864&r2=395865&view=diff
==============================================================================
--- db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformDb2Impl.java (original)
+++ db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformDb2Impl.java Fri Apr 21
05:02:30 2006
@@ -1,6 +1,6 @@
 package org.apache.ojb.broker.platforms;
 
-/* Copyright 2002-2004 The Apache Software Foundation
+/* Copyright 2002-2006 The Apache Software Foundation
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -216,7 +216,9 @@
             value = SequenceManagerHelper.getSeqCacheValue(prop);
             if(value != null)
             {
-                query.append(" CACHE ").append(value.longValue());
+                long cache = value.longValue();
+                if(cache > 0) query.append(" CACHE ").append(value.longValue());
+                else query.append(" NOCACHE");
             }
 
             b = SequenceManagerHelper.getSeqOrderValue(prop);

Modified: db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformOracleImpl.java
URL: http://svn.apache.org/viewcvs/db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformOracleImpl.java?rev=395865&r1=395864&r2=395865&view=diff
==============================================================================
--- db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformOracleImpl.java (original)
+++ db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformOracleImpl.java Fri Apr
21 05:02:30 2006
@@ -389,7 +389,9 @@
             value = SequenceManagerHelper.getSeqCacheValue(prop);
             if(value != null)
             {
-                query.append(" CACHE ").append(value.longValue());
+                long cache = value.longValue();
+                if(cache > 0) query.append(" CACHE ").append(value.longValue());
+                else query.append(" NOCACHE");
             }
 
             b = SequenceManagerHelper.getSeqOrderValue(prop);

Modified: db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformSapdbImpl.java
URL: http://svn.apache.org/viewcvs/db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformSapdbImpl.java?rev=395865&r1=395864&r2=395865&view=diff
==============================================================================
--- db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformSapdbImpl.java (original)
+++ db/ojb/trunk/src/java/org/apache/ojb/broker/platforms/PlatformSapdbImpl.java Fri Apr 21
05:02:30 2006
@@ -205,7 +205,9 @@
             value = SequenceManagerHelper.getSeqCacheValue(prop);
             if(value != null)
             {
-                query.append(" CACHE ").append(value.longValue());
+                long cache = value.longValue();
+                if(cache > 0) query.append(" CACHE ").append(value.longValue());
+                else query.append(" NOCACHE");
             }
 
             b = SequenceManagerHelper.getSeqOrderValue(prop);



---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Mime
View raw message