Aii, ColumnDefinition.defaultValue is null when it's unset, unlike the annotation.
This commit is contained in:
@@ -765,7 +765,7 @@ public class DepotMarshaller<T extends PersistentRecord>
|
||||
// TIMESTAMP columns a value of "0000-00-00 00:00:00" regardless of whether we
|
||||
// explicitly provide a "DEFAULT" value for the column or not, and DATETIME columns
|
||||
// cannot accept CURRENT_TIME or NOW() defaults at all.
|
||||
if (!coldef.nullable && coldef.defaultValue.length() == 0 &&
|
||||
if (!coldef.nullable && coldef.defaultValue == null &&
|
||||
(coldef.type.equalsIgnoreCase("timestamp") ||
|
||||
coldef.type.equalsIgnoreCase("datetime"))) {
|
||||
log.info("Assigning current time to " + fmarsh.getColumnName() + ".");
|
||||
|
||||
Reference in New Issue
Block a user