openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ppod...@apache.org
Subject svn commit: r880929 - in /openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc: meta/MappingDefaultsImpl.java schema/SchemaGroup.java
Date Mon, 16 Nov 2009 19:45:41 GMT
Author: ppoddar
Date: Mon Nov 16 19:45:40 2009
New Revision: 880929

URL: http://svn.apache.org/viewvc?rev=880929&view=rev
Log:
TeamCity commits left two files behind

Modified:
    openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/MappingDefaultsImpl.java
    openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/schema/SchemaGroup.java

Modified: openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/MappingDefaultsImpl.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/MappingDefaultsImpl.java?rev=880929&r1=880928&r2=880929&view=diff
==============================================================================
--- openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/MappingDefaultsImpl.java
(original)
+++ openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/meta/MappingDefaultsImpl.java
Mon Nov 16 19:45:40 2009
@@ -539,7 +539,9 @@
             else if (_dsIdName != null)
                 cols[i].setName(_dsIdName + i);
             correctName(table, cols[i]);
+            table.addSubColumn(cols[i].getName());
         }
+        table.resetSubColumns();
     }
 
     /**
@@ -551,9 +553,7 @@
             String name = col.getName();
             if (_removeHungarianNotation)
                 name = removeHungarianNotation(name);
-            String correctedName = dict.getValidColumnName(name, table);
-            col.setName(correctedName);
-            table.addCorrectedColumnName(correctedName, true);
+            col.setName(dict.getValidColumnName(name, table));
         }
     }
 
@@ -584,7 +584,9 @@
             } else if (_versName != null)
                 cols[i].setName(_versName + i);
             correctName(table, cols[i]);
+            table.addSubColumn(cols[i].getName());
         }
+        table.resetSubColumns();
     }
 
     public void populateColumns(Discriminator disc, Table table,
@@ -595,7 +597,9 @@
             else if (_discName != null)
                 cols[i].setName(_discName + i);
             correctName(table, cols[i]);
+            table.addSubColumn(cols[i].getName());
         }
+        table.resetSubColumns();
     }
 
     public void populateJoinColumn(ClassMapping cm, Table local, Table foreign,
@@ -620,8 +624,11 @@
 
     public void populateColumns(ValueMapping vm, String name, Table table,
         Column[] cols) {
-        for (int i = 0; i < cols.length; i++)
+        for (int i = 0; i < cols.length; i++) {
             correctName(table, cols[i]);
+            table.addSubColumn(cols[i].getName());
+        }
+        table.resetSubColumns();
     }
 
     public boolean populateOrderColumns(FieldMapping fm, Table table,
@@ -632,7 +639,9 @@
             else if (_orderName != null)
                 cols[i].setName(_orderName + i);
             correctName(table, cols[i]);
+            table.addSubColumn(cols[i].getName());
         }
+        table.resetSubColumns();
         return _orderLists && (JavaTypes.ARRAY == fm.getTypeCode()
             || List.class.isAssignableFrom(fm.getType()));
     }
@@ -645,7 +654,9 @@
             else if (_nullIndName != null)
                 cols[i].setName(_nullIndName + i);
             correctName(table, cols[i]);
+            table.addSubColumn(cols[i].getName());
         }
+        table.resetSubColumns();
         return _addNullInd;
     }
 

Modified: openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/schema/SchemaGroup.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/schema/SchemaGroup.java?rev=880929&r1=880928&r2=880929&view=diff
==============================================================================
--- openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/schema/SchemaGroup.java
(original)
+++ openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/schema/SchemaGroup.java
Mon Nov 16 19:45:40 2009
@@ -144,7 +144,7 @@
                 tab.importIndex(idxs[j]);
             unqs = tables[i].getUniques();
             for (int j = 0; j < unqs.length; j++)
-                tab.importUnique(unqs[j], null);
+                tab.importUnique(unqs[j]);
         }
         return copy;
     }



Mime
View raw message