Executes the query, and returns the first column of the first row in the result set returned by the query. Additional columns or rows are ignored.
ExecuteSqlStatementAsScalarWithInnerTransaction method can be called if context.transaction is not set
This method opens transaction internally. This functionality is implemented to enable query rerun in case on the problems
with Sql optimizer hints
Namespace: Relativity.API
Assembly: Relativity.API (in Relativity.API.dll) Version: 640db774aa42dfbe1785add27fbb41844ec5c7d4
Syntax
Object ExecuteSqlStatementAsScalarWithInnerTransaction( string sqlStatement, IEnumerable<SqlParameter> parameters, int timeoutValue )
Parameters
- sqlStatement
- Type: System.String
String containing SQL statement. - parameters
- Type: System.Collections.Generic.IEnumerable<SqlParameter>
List of SQL parameters passed in to SQL statement. - timeoutValue
- Type: System.Int32
A timeout value in seconds for the query
Return Value
Type: ObjectReturns the first column of the first row in the result set returned by the query.
See Also