Partager via


ColumnAttribute.IsDbGenerated Property

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Gets or sets whether a column contains values that the database auto-generates.

Namespace:  System.Data.Linq.Mapping
Assembly:  System.Data.Linq (in System.Data.Linq.dll)

Syntax

'Declaration
Public Property IsDbGenerated As Boolean
public bool IsDbGenerated { get; set; }

Property Value

Type: System.Boolean
Default = false.

Remarks

IsDbGenerated members are synchronized immediately after the row of data is inserted, and the members are available after SubmitChanges is completed.

NoteNote:

If the column holds primary key values and you designate IsDbGenerated as true, you should also add the DbType property by using the IDENTITY modifier.

Version Information

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.