More than one Data reader in a single connection

  • Thread starter Thread starter Guest
  • Start date Start date
Under certain circumstances you CAN have more than one operation executed
against a single SQL Server connection--if you use MARS. Multiple Active
Resultsets is enabled in ADO.NET 2.0. While I don't endorse it (as
connections are really pretty cheap with SQL Server) it can be done.

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
INETA Speaker
www.betav.com/blog/billva
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
Visit www.hitchhikerguides.net to get more information on my latest book:
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
and Hitchhiker's Guide to SQL Server 2005 Compact Edition (EBook)
 
Ziangi Jones,

ADO.Net 2.0 introduced a new feature called Multiple Active Result Sets
(MARS). This feature allows multiple open data readers on the same connection.

However, MARS has all sorts of ramifications that you need to understand
really well before using it.

Personally, I would use multiple connections.

Kerry Moorman
 
Back
Top