DataAccessBase.Find<T>

Returns the first matching record retrieved from data based on a SQL statement as an entity or null if no match was found.

public virtual T Find<T>(string sql,
	Object[] parameters)

Parameters

sql
SQL string to execute. Use @0,@1,@2 for parameters.

        Recommend you use `TOP1` in your SQL statements to limit the 
        amount of data returned from the underlying query even though
        a full list returns the same result.

parameters
DbParameters (CreateParameter()) for named parameters or use @0,@1 parms in SQL and plain values

Overloads:


See also:

Class DataAccessBase

© West Wind Technologies, 1996-2023 • Updated: 07/15/20
Comment or report problem with topic