A Simple ADO.NET and XML Sample

We’ve looked at snippets of code that demonstrate isolated features. Now it’s time to put some of these features into a small sample application that shows off the power of XML and of ADO.NET’s XML features. To do this, I’ll pull together functionality from many of the previous code snippets.

The sample will use parameterized queries to retrieve an order history for a particular customer. Before you roll your eyes, note that we’re going to collect more information in this set of queries. The queries will retrieve data from four related tables: Customers, Orders, Order Details, and Products. In this way, our order history will be more robust. We’ll see company names as well as the names of the products ordered.

The ...

Get Programming Microsoft® ADO.NET 2.0 Core Reference, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.