XPClassInfo.NullableBehavior Property
Determines if nullable columns should be created when updating the database schema for the persistent class described by the current XPClassInfo object.
Namespace: DevExpress.Xpo.Metadata
Assembly: DevExpress.Xpo.v24.2.dll
NuGet Package: DevExpress.Xpo
#Declaration
public NullableBehavior NullableBehavior { get; }
#Property Value
Type | Description |
---|---|
Nullable |
A Nullable |
Available values:
Name | Description |
---|---|
Default | The default mode. Has the same effect as Always |
Always |
A nullable column is always created. |
By |
A nullable column is created when the mapped property type is not a value type. |
#Remarks
To change the NullableBehavior value, apply the NullableBehaviorAttribute in the persistent class declaration. You can also change this setting globally, using the static XpoDefault.NullableBehavior property. To change behavior for an individual field, use the NullableAttribute attribute.