openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fa...@apache.org
Subject svn commit: r694057 - in /openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta: ClassMappingInfo.java VersionMappingInfo.java
Date Wed, 10 Sep 2008 23:06:36 GMT
Author: fancy
Date: Wed Sep 10 16:06:36 2008
New Revision: 694057

URL: http://svn.apache.org/viewvc?rev=694057&view=rev
Log:
OPENJPA-720 The pushdown sql for version columns in primary and secondary tables has unpredictable
ordering in the select and from clause

Modified:
    openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/ClassMappingInfo.java
    openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/VersionMappingInfo.java

Modified: openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/ClassMappingInfo.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/ClassMappingInfo.java?rev=694057&r1=694056&r2=694057&view=diff
==============================================================================
--- openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/ClassMappingInfo.java
(original)
+++ openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/ClassMappingInfo.java
Wed Sep 10 16:06:36 2008
@@ -24,6 +24,7 @@
 import java.util.Collections;
 import java.util.HashMap;
 import java.util.Iterator;
+import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
 import java.util.Map.Entry;
@@ -229,7 +230,7 @@
         if (cols == null)
             cols = Collections.EMPTY_LIST;
         if (_seconds == null)
-            _seconds = new HashMap();
+            _seconds = new LinkedHashMap();
         _seconds.put(tableName, cols);
     }
     

Modified: openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/VersionMappingInfo.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/VersionMappingInfo.java?rev=694057&r1=694056&r2=694057&view=diff
==============================================================================
--- openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/VersionMappingInfo.java
(original)
+++ openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/VersionMappingInfo.java
Wed Sep 10 16:06:36 2008
@@ -20,8 +20,8 @@
 
 import java.util.ArrayList;
 import java.util.Arrays;
-import java.util.HashMap;
 import java.util.HashSet;
+import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
@@ -71,7 +71,7 @@
     	Table primaryTable = vers.getClassMapping().getTable();
     	List<String> secondaryTableNames = Arrays.asList(vers
     		.getClassMapping().getMappingInfo().getSecondaryTableNames());
-    	Map<Table, List<Column>> assign = new HashMap<Table, List<Column>>();
+    	Map<Table, List<Column>> assign = new LinkedHashMap<Table, List<Column>>();
     	for (Column col : templates) {
     	    String tableName = col.getTableName();
     	    Table table;



Mime
View raw message