The relationship between ADO and ADO.NET is analogous to the one between Active Server Pages (ASP) and ASP.NET. Many of the object and method names are similar, but behind the curtains everything has been redesigned and improved.
For instance, the ADO data model was based on the recordset object. In essence, the recordset was a spreadsheet of data in memory. You were very limited in what you could do with a recordset of data. It was difficult to do advanced data filtering or combine two recordsets. Additionally, although it is possible to transmit an ADO recordset to a remote server, you must configure all firewalls between the two servers to enable the proprietary ports required for COM martialing.
Additionally, the remote server must know what an ADO recordset is ”for all intents and purposes, this means that the remote server must be running a Microsoft operating system. Because of the limitations of the ADO recordset object, solutions based on ADO were likewise limited.
Microsoft has fixed these problems with ADO.NET. The centerpiece object of ADO.NET is the DataSet . The DataSet is an in-memory representation of data that provides a consistent relational programming model regardless of the data source. The DataSet contains a collection of DataTable s, which are very much like recordsets in that each DataTable is a set of data. However, rather than just being a container for various DataTable s, the DataSet can store relations and constraints pertaining to the DataTable s! Not only can a DataSet mirror the relations and constraints in your data source, but you can add new ones as the logic of your application dictates. This gives you complete control of filtering and combining DataTable s.
Additionally, DataSet s (and the DataTable s within them) are represented internally by strongly typed XML. Thus, at any point, it is possible to save a DataSet to XML. This might not seem like such a major point at first glance. However, this means that any platform that can parse XML ”and I do not know of any platform that cannot ”can retrieve data from an ADO.NET DataSet .
DataSet s are easily transmitted to remote machines, as well. Web services are designed to transmit XML data via SOAP to remote machines. Because the DataSet is represented internally as XML, sending a DataSet to a remote server requires no special handling. The remote server could be running any platform that understands XML, such as Java-based solutions like IBM WebSphere. A WebSphere developer would only need to parse the XML.
SOAP (Simple Object Access Protocol) is an open standard that defines how objects should be packaged (via XML) and transported over TCP/IP (via port 80). The official SOAP specifications and other documents are available online at http://www.w3.org. Choose SOAP from the main menu.