Class IdentityAttribute
Marks target column as identity column with value, generated on database side during insert operations. Identity columns will be ignored for insert and update operations with implicit column list like Insert<T>(IDataContext, T, string?, string?, string?, string?, TableOptions) or Update<T>(IDataContext, T, string?, string?, string?, string?, TableOptions) methods.
[AttributeUsage(AttributeTargets.Property|AttributeTargets.Field, AllowMultiple = true)]
public class IdentityAttribute : MappingAttribute, _Attribute
- Inheritance
-
IdentityAttribute
- Implements
- Inherited Members
- Extension Methods
Constructors
IdentityAttribute()
Creates attribute instance.
public IdentityAttribute()
IdentityAttribute(string?)
Creates attribute instance.
public IdentityAttribute(string? configuration)
Parameters
configuration
stringMapping schema configuration name. See LinqToDB.Configuration.
Methods
GetObjectID()
Returns mapping attribute id, based on all attribute options.
public override string GetObjectID()