SqlEntity Type
Constructors
| Constructor |
Description
|
Full Usage:
SqlEntity(dc, tableName, columns, activeColumnCount)
Parameters:
ISqlDataContext
tableName : string
columns : ColumnLookup
activeColumnCount : int
Returns: SqlEntity
|
|
Instance members
| Instance member |
Description
|
|
Makes a copy of entity (database row), which is a new row with the same columns and values (except Id) If column primaty key is something else and not-auto-generated, then, too bad...
|
Full Usage:
this.CloneTo
Parameters:
ISqlDataContext
itemExistsAlready : bool
Returns: SqlEntity
|
Attach/copy entity to a different data-context. Second parameter: SQL UPDATE or INSERT clause? UPDATE: Updates the exising database entity with the values that this entity contains. INSERT: Makes a copy of entity (database row), which is a new row with the same columns and values (except Id)
|
Full Usage:
this.ColumnValues
Returns: (string * obj) seq
|
|
|
|
|
|
Full Usage:
this.Delete
|
|
|
|
Full Usage:
this.HasValue
Parameters:
string
Returns: bool
|
|
Full Usage:
this.MapTo
Parameters:
string * obj -> obj
Returns: 'a
Type parameters: 'a |
Maps database entity class to the type provided in generic attribute. You can define more detailed mapping via MappedColumnAttribute or propertyTypeMapping
|
|
Determines what should happen when saving this entity if it is newly-created but another entity with the same primary key already exists
|
Full Usage:
this.SetColumn
Parameters:
string
value : 't
Type parameters: 't |
Prefer e.Column <- "x" over this method. This method should be only used if you need a dynamic column name.
|
Full Usage:
this.SetData
Parameters:
(string * 'a) seq
Type parameters: 'a |
|
|
Internal state. Modifying not recommended!
|