ExecuteReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken)
This method returns a Task-based asynchronous version of OracleCommand.ExecuteReader(), which fetches the result set as an OracleDataReader object.
Declaration
// C# public Task<OracleDataReader> ExecuteReaderAsync(CommandBehavior behavior, CancellationToken cancellationToken);
Parameters
-
behavior- the expected behavior. Provides a description of the results of the query and its effect on the database. -
cancellationToken- the input cancellation token which can be used by the application to cancel the task before command timeout occurs.
Return Value
Task<OracleDataReader> object representing the asynchronous operation immediately without blocking the calling thread for the whole duration of the query execution.
Implements
DbCommand
Exceptions
InvalidOperationException - The command cannot be executed.