Tortuga.Chain Namespace
Tortuga.Chain.CommandBuilders Namespace
Tortuga.Chain.Metadata Namespace

ISupportsGetByKey..::..GetByKey<(Of <(<'TObject>)>)> Method (String)

Gets a record by its primary key.

Namespace:  Tortuga.Chain.DataSources
Assembly:  Tortuga.Chain.Core (in Tortuga.Chain.Core.dll)

Syntax


ISingleRowDbCommandBuilder<TObject> GetByKey<TObject>(
	string key
)
Function GetByKey(Of TObject) ( _
	key As String _
) As ISingleRowDbCommandBuilder(Of TObject)
generic<typename TObject>
ISingleRowDbCommandBuilder<TObject>^ GetByKey(
	String^ key
)

Type Parameters

TObject
The type of the object. Used to determine which table will be read.

Parameters

key
Type: String
The key.

Return Value

Remarks


This only works on tables that have a scalar primary key.