RelationalPropertyExtensions.IsColumnNullable Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
IsColumnNullable(IProperty) |
Checks whether the column mapped to the given IProperty will be nullable when created in the database. This depends on the property itself and also how it is mapped. For example, derived non-nullable properties in a TPH type hierarchy will be mapped to nullable columns. As well as properties on optional types sharing the same table. |
IsColumnNullable(IReadOnlyProperty) |
Checks whether the column mapped to the given IProperty will be nullable when created in the database. |
IsColumnNullable(IProperty, StoreObjectIdentifier) |
Checks whether the column mapped to the given IProperty will be nullable when created in the database. This depends on the property itself and also how it is mapped. For example, derived non-nullable properties in a TPH type hierarchy will be mapped to nullable columns. As well as properties on optional types sharing the same table. |
IsColumnNullable(IReadOnlyProperty, StoreObjectIdentifier) |
Checks whether the column mapped to the given property will be nullable when created in the database. |
IsColumnNullable(IProperty)
Checks whether the column mapped to the given IProperty will be nullable when created in the database.
This depends on the property itself and also how it is mapped. For example, derived non-nullable properties in a TPH type hierarchy will be mapped to nullable columns. As well as properties on optional types sharing the same table.
public static bool IsColumnNullable (this Microsoft.EntityFrameworkCore.Metadata.IProperty property);
static member IsColumnNullable : Microsoft.EntityFrameworkCore.Metadata.IProperty -> bool
<Extension()>
Public Function IsColumnNullable (property As IProperty) As Boolean
Parameters
Returns
true
if the mapped column is nullable; false
otherwise.
Applies to
IsColumnNullable(IReadOnlyProperty)
Checks whether the column mapped to the given IProperty will be nullable when created in the database.
public static bool IsColumnNullable (this Microsoft.EntityFrameworkCore.Metadata.IReadOnlyProperty property);
static member IsColumnNullable : Microsoft.EntityFrameworkCore.Metadata.IReadOnlyProperty -> bool
<Extension()>
Public Function IsColumnNullable (property As IReadOnlyProperty) As Boolean
Parameters
- property
- IReadOnlyProperty
The IReadOnlyProperty.
Returns
true
if the mapped column is nullable; false
otherwise.
Remarks
This depends on the property itself and also how it is mapped. For example, derived non-nullable properties in a TPH type hierarchy will be mapped to nullable columns. As well as properties on optional types sharing the same table.
Applies to
IsColumnNullable(IProperty, StoreObjectIdentifier)
Checks whether the column mapped to the given IProperty will be nullable when created in the database.
This depends on the property itself and also how it is mapped. For example, derived non-nullable properties in a TPH type hierarchy will be mapped to nullable columns. As well as properties on optional types sharing the same table.
public static bool IsColumnNullable (this Microsoft.EntityFrameworkCore.Metadata.IProperty property, in Microsoft.EntityFrameworkCore.Metadata.StoreObjectIdentifier storeObject);
static member IsColumnNullable : Microsoft.EntityFrameworkCore.Metadata.IProperty * StoreObjectIdentifier -> bool
<Extension()>
Public Function IsColumnNullable (property As IProperty, ByRef storeObject As StoreObjectIdentifier) As Boolean
Parameters
- storeObject
- StoreObjectIdentifier
The identifier of the table-like store object containing the column.
Returns
true
if the mapped column is nullable; false
otherwise.
Applies to
IsColumnNullable(IReadOnlyProperty, StoreObjectIdentifier)
Checks whether the column mapped to the given property will be nullable when created in the database.
public static bool IsColumnNullable (this Microsoft.EntityFrameworkCore.Metadata.IReadOnlyProperty property, in Microsoft.EntityFrameworkCore.Metadata.StoreObjectIdentifier storeObject);
static member IsColumnNullable : Microsoft.EntityFrameworkCore.Metadata.IReadOnlyProperty * StoreObjectIdentifier -> bool
<Extension()>
Public Function IsColumnNullable (property As IReadOnlyProperty, ByRef storeObject As StoreObjectIdentifier) As Boolean
Parameters
- property
- IReadOnlyProperty
The property.
- storeObject
- StoreObjectIdentifier
The identifier of the table-like store object containing the column.
Returns
true
if the mapped column is nullable; false
otherwise.
Remarks
This depends on the property itself and also how it is mapped. For example, derived non-nullable properties in a TPH type hierarchy will be mapped to nullable columns. As well as properties on optional types sharing the same table.
Applies to
Entity Framework