Interface IColumnModification
- Namespace
- Microsoft.EntityFrameworkCore.Update
- Assembly
- Microsoft.EntityFrameworkCore.Relational.dll
Represents an update, insert, or delete operation for a single column. IReadOnlyModificationCommand contain lists of IColumnModification.
This type is typically used by database providers; it is generally not used in application code.
public interface IColumnModification
Remarks
See Implementation of database providers and extensions for more information and examples.
Properties
Column
The column.
IColumnBase? Column { get; }
Property Value
ColumnName
The name of the column.
string ColumnName { get; }
Property Value
ColumnType
The database type of the column.
string? ColumnType { get; }
Property Value
Entry
The Microsoft.EntityFrameworkCore.Update.IUpdateEntry that represents the entity that is being modified.
IUpdateEntry? Entry { get; }
Property Value
- IUpdateEntry
IsCondition
Indicates whether the column is used in the WHERE
clause when updating.
bool IsCondition { get; set; }
Property Value
IsKey
Indicates whether the column is part of a primary or alternate key.
bool IsKey { get; set; }
Property Value
IsNullable
A value indicating whether the column could contain a null value.
bool? IsNullable { get; }
Property Value
- bool?
IsRead
Indicates whether a value must be read from the database for the column.
bool IsRead { get; set; }
Property Value
IsWrite
Indicates whether a value must be written to the database for the column.
bool IsWrite { get; set; }
Property Value
JsonPath
In case of JSON column modification, the JSON path leading to the JSON element that needs to be updated.
string? JsonPath { get; }
Property Value
OriginalParameterName
The parameter name to use for the original value parameter (UseOriginalValueParameter), if needed.
string? OriginalParameterName { get; }
Property Value
OriginalValue
The original value of the property mapped to this column.
object? OriginalValue { get; set; }
Property Value
ParameterName
The parameter name to use for the current value parameter (UseCurrentValueParameter), if needed.
string? ParameterName { get; }
Property Value
Property
The property that maps to the column.
IProperty? Property { get; }
Property Value
- IProperty
Remarks
In case of JSON column single scalar property modification, the scalar property that is being modified.
TypeMapping
The relational type mapping for the column.
RelationalTypeMapping? TypeMapping { get; }
Property Value
UseCurrentValue
Indicates whether the current value of the property should be used.
bool UseCurrentValue { get; }
Property Value
UseCurrentValueParameter
Indicates whether the current value of the property must be passed as a parameter to the SQL.
bool UseCurrentValueParameter { get; }
Property Value
UseOriginalValue
Indicates whether the original value of the property should be used.
bool UseOriginalValue { get; }
Property Value
UseOriginalValueParameter
Indicates whether the original value of the property must be passed as a parameter to the SQL.
bool UseOriginalValueParameter { get; }
Property Value
UseParameter
Indicates whether the value of the property must be passed as a parameter to the SQL as opposed to being inlined.
bool UseParameter { get; }
Property Value
Value
Gets or sets the current value of the property mapped to this column.
object? Value { get; set; }
Property Value
Methods
AddSharedColumnModification(IColumnModification)
Adds a modification affecting the same database value.
void AddSharedColumnModification(IColumnModification modification)
Parameters
modification
IColumnModificationThe modification for the shared column.
ResetParameterNames()
Resets parameter names, so they can be regenerated if the command needs to be re-added to a new batch.
void ResetParameterNames()