diff --git a/openjpa-persistence-jdbc/src/main/java/org/apache/openjpa/persistence/jdbc/XMLPersistenceMappingSerializer.java b/openjpa-persistence-jdbc/src/main/java/org/apache/openjpa/persistence/jdbc/XMLPersistenceMappingSerializer.java index 500b76a53..6dcb4b14f 100644 --- a/openjpa-persistence-jdbc/src/main/java/org/apache/openjpa/persistence/jdbc/XMLPersistenceMappingSerializer.java +++ b/openjpa-persistence-jdbc/src/main/java/org/apache/openjpa/persistence/jdbc/XMLPersistenceMappingSerializer.java @@ -228,7 +228,7 @@ public class XMLPersistenceMappingSerializer (table); boolean print = (cols != null && cols.size() > 0) || - (uniques !=null || uniques.length > 0); + (uniques != null && uniques.length > 0); if (table != null && (defaultName == null || !defaultName.equals(table))) { print = true;