O'Reilly logo

Windows® Phone 8 Unleashed by Daniel Vaughan

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using the Column Attribute

Each property of the TimelineItem is decorated with a Column attribute, which tells the DataContext that the property is stored in a column by the same name. As with TableAttribute, you can use its Name property to specify a different name for the column in the database.

ColumnAttribute includes various other properties described in the following sections.

IsPrimaryKey

IsPrimaryKey is used to designate the member or members of the entity class that compose the primary key of the table. Composite keys are also supported by supplying more than one property decorated with a Column attribute with IsPrimaryKey set to true.

At least one member of an entity class must be designated as the primary key, or else the entity ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required