SqlDatabase. Refer to 'Asynchronous Query Execution'article for detailed information. Users can verify that the command has completed its operation by using the IAsyncResult instance returned by the BeginExecuteNonQuery () method. If the process of executing the command has not yet finished, this method blocks until the operation is complete. ![]() The IAsyncResult returned by a call to any overload of BeginExecuteNonQuery(DbCommand, AsyncCallback, Object). A pair of asynchronous functions (BeginExecuteNonQueryand EndExecuteNonQuery) can be used instead of the synchronous function ExecuteNonQueryto gain more performance and flexibility in your application. When you call BeginExecuteNonQuery () to execute a Transact-SQL statement, you must call EndExecuteNonQuery in order to complete the operation. I suggest you get more comfortable solving your issues before looking into running your queries asynchronously. Public Overrides Function EndExecuteNonQuery ( EndExecuteNonQuery is used i conjunction with BeginExecuteNonQuery to execute a command on the database asynchronously. Namespace: .Sql Assembly: (in .dll) Version: 6.0.0.0 (.0) Syntax public override int EndExecuteNonQuery( Finishes asynchronous execution of a Transact-SQL statement, returning the number of affected records.
0 Comments
Leave a Reply. |