Often the smallest attention to details or the extra bit of wisdom makes all the difference in the world. In programming, knowing that a well- understood pattern applies to the problem you need to solve can turn several days of tedious effort spent hacking out a new (and possibly inferior) solution into just a couple hours of programming. And often it is the simplest evolutionary revisions that make all the difference in the utility of a technology. This latter concept applies to ADO.NET.

From Chapter 11 you know that ADO.NET revised ADO to address real problems of scalability and reliability when it comes to Internet programming. In this chapter I show you how ADO.NET has all the old reliable behaviors, like stored procedure and transaction support, that programmers demand plus new capabilities that give the .NET part of the name meaning. In addition to the old reliable behaviors, the new capabilities discussed here include how to create typed DataSet objects, how to use XML with DataSet objects to support serialization and ultimately transmittal of data over the Internet, and how to use data interfaces to implement a solution that supports easily switching between data providers.


If you switch data providers, remember to change your connection string. The StoredProcedureDemo.sln App.config file contains two appSettings , one for each provider demonstrated.

The ability to use typed DataSet objects is one of my favorite features. The basic idea behind a typed DataSet object is that because everything is a class in .NET, you can inherit from and extend classes, including those that are key to ADO.NET, like the DataSet , DataTable , and DataRow classes. The result is more expressive and powerful database code that looks like objects and members rather than an SQL nightmare. We'll get to typed DataSet objects later in this chapter.

Visual Basic. NET Power Coding
Visual Basic(R) .NET Power Coding
ISBN: 0672324075
EAN: 2147483647
Year: 2005
Pages: 215
Authors: Paul Kimmel © 2008-2017.
If you may any questions please contact us: