Natural-id doc specify that all properties should be not nullable. Will it be possible to disable this constraint ?
This may go with another change: Restrictions.eq() may be rewrite like this:
Code:
public static SimpleExpression eq(String propertyName, Object value) {
if (value != null) {
return new SimpleExpression(propertyName, value, "=");
} else {
return new NullExpression(propertyName);
}
}
Nullable properties are very usefull for empty string in Oracle or zero-or-one association.
It post it here first to know if you considered it a good idea.
I may do more tests and create a patch I the Hibernate Team thinks is possible.
Adrien