details:   /erp/devel/dbsm-main/rev/f4a4a2700dbb
changeset: 276:f4a4a2700dbb
user:      Stefan Hühner <stefan.huehner <at> openbravo.com>
date:      Tue Mar 02 16:28:01 2010 +0100
summary:   Change use of RemoveRowDALChange to RemoveRowChange use
note: code is unused right now

diffstat:

 src/org/apache/ddlutils/platform/SqlBuilder.java |  11 +++++------
 1 files changed, 5 insertions(+), 6 deletions(-)

diffs (38 lines):

diff -r 9fa41c691737 -r f4a4a2700dbb 
src/org/apache/ddlutils/platform/SqlBuilder.java
--- a/src/org/apache/ddlutils/platform/SqlBuilder.java  Tue Mar 02 16:16:38 
2010 +0100
+++ b/src/org/apache/ddlutils/platform/SqlBuilder.java  Tue Mar 02 16:28:01 
2010 +0100
@@ -80,7 +80,6 @@
 import org.apache.ddlutils.alteration.RemoveIndexChange;
 import org.apache.ddlutils.alteration.RemovePrimaryKeyChange;
 import org.apache.ddlutils.alteration.RemoveRowChange;
-import org.apache.ddlutils.alteration.RemoveRowDALChange;
 import org.apache.ddlutils.alteration.RemoveSequenceChange;
 import org.apache.ddlutils.alteration.RemoveTableChange;
 import org.apache.ddlutils.alteration.RemoveTriggerChange;
@@ -557,8 +556,8 @@
     for (Change change : changes) {
       if (change instanceof AddRowChange) {
         printAddRowChangeChange(model, (AddRowChange) change);
-      } else if (change instanceof RemoveRowDALChange) {
-        printRemoveRowDALChange(model, (RemoveRowDALChange) change);
+      } else if (change instanceof RemoveRowChange) {
+        printRemoveRowChange(model, (RemoveRowChange) change);
       } else if (change instanceof ColumnDataChange) {
         printColumnDataChange(model, (ColumnDataChange) change);
       }
@@ -4317,12 +4316,12 @@
     printEndOfStatement();
   }
 
-  public void printRemoveRowDALChange(Database model, RemoveRowDALChange 
change) throws IOException {
+  public void printRemoveRowChange(Database model, RemoveRowChange change) 
throws IOException {
     Table table = change.getTable();
     Column[] pk = table.getPrimaryKeyColumns();
-    BaseOBObject object = change.getRow();
+    DynaBean object = change.getRow();
     HashMap pkValues = new HashMap();
-    pkValues.put(pk[0].getName(), object.getId());
+    pkValues.put(pk[0].getName(), object.get(pk[0].getName()));
     println(getDeleteSql(table, pkValues, false));
     printEndOfStatement();
   }

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to