IDEMPIERE-2395 - Delete also corrupt records pointing to non-key tables
This commit is contained in:
parent
45498090f7
commit
160aa2a692
|
@ -146,7 +146,7 @@ public class CleanOrphanCascade extends SvrProcess
|
||||||
MTable refTable = MTable.get(getCtx(), refTableID);
|
MTable refTable = MTable.get(getCtx(), refTableID);
|
||||||
StringBuilder whereClause = new StringBuilder();
|
StringBuilder whereClause = new StringBuilder();
|
||||||
whereClause.append("AD_Table_ID = ").append(refTableID);
|
whereClause.append("AD_Table_ID = ").append(refTableID);
|
||||||
if (refTable.getKeyColumns().length != 1) {
|
if (refTable.getKeyColumns().length != 1 && !isUUIDMap) {
|
||||||
log.warning("Wrong reference for table " + tableName + " -> " + refTableName);
|
log.warning("Wrong reference for table " + tableName + " -> " + refTableName);
|
||||||
whereClause.append(" AND Record_ID>0");
|
whereClause.append(" AND Record_ID>0");
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue