Skip to content

TQueryCrudExtensions_Find_VtWpRU4u9f4BU4FQdsMGSQ

Jacob Spitzer edited this page Aug 28, 2022 · 2 revisions

TQueryCrudExtensions.Find<Table>(DbEc<Table>, long, string) Method

Returns a single entity by a single id from table. Id must be marked with [Key] attribute.

public static Table Find<Table>(this DbEasyConnect.DbEc<Table> tQuery, long id, string keyColumnName="Id");

Type parameters

Table

Parameters

tQuery DbEasyConnect.DbEc<Table>
An DbEc<T>.

id System.Int64
Id of the entity to get, must be marked with [Key] attribute

keyColumnName System.String
The column name of the primary key.

Returns

Table
The record in TQuery recordset with the given id, or NULL if id not found.

Clone this wiki locally