Buy Used
£2.20
+ £2.80 UK delivery
Used: Good | Details
Condition: Used: Good
Comment: The book is in good condition. All pages as well as Cover is intact. Some minor wear to the spine. All items are shipped within 1 working day from UK
Have one to sell?
Flip to back Flip to front
Listen Playing... Paused   You're listening to a sample of the Audible audio edition.
Learn more
See this image

ADO.NET Cookbook Paperback – 5 Oct 2003


See all 2 formats and editions Hide other formats and editions
Amazon Price
New from Used from
Paperback
"Please retry"
£14.29 £2.20

There is a newer edition of this item:

ADO.NET 3.5 Cookbook (Cookbooks (O'Reilly))
£43.99
(1)
In stock on July 28, 2017.
click to open popover

Special offers and product promotions

Enter your mobile number or email address below and we'll send you a link to download the free Kindle App. Then you can start reading Kindle books on your smartphone, tablet, or computer - no Kindle device required.

  • Apple
  • Android
  • Windows Phone

To get the free app, enter your mobile phone number.



Product details

Product description

About the Author

Bill Hamilton is a software architect specializing in designing, developing and implementing distributed applications using .NET and J2EE technologies. Over the last ten years, he has provided consulting services in B2B, B2C, B2E, data integration, and portal initiatives for banking, retail, accounting, manufacturing, and financial services. An early technology adopter, he frequently evaluates, recommends, and helps his clients use new technologies effectively. Bill has designed and helped build several award winning software packages. Bill is the co-author of O'Reilly's ADO.NET in a Nutshell and author of ADO.NET Cookbook.

Excerpt. © Reprinted by permission. All rights reserved.

Chapter 8 - Working with XML

8.0 Introduction
ADO.NET and XML classes are tightly integrated in the .NET Framework. The DataSet can be filled with data or a schema from an XML stream or document. The DataSet can persist or serialize its data or schema to an XML stream or document. ADO synchronizes the DataSet with an XmlDataDocument. Data can be modified simultaneously using either class as needed; all changes made in one class are immediatelyreflected in the other class. This chapter focuses on XML support in ADO.NET and in SQL Server 2000.

The XML support in .NET is provided by integrated classes in five namespaces:

System.Xml
Contains classes that provide standards-based support for processing XML

System.Xml.Schema
Contains classes that provide standards-based support for XML Schema Definition (XSD) language schemas

System.Xml.Serialization
Contains classes that serialize objects into XML documents or streams

System.Xml.XPath
Contains classes that parse and evaluate Xpath

System.Xml.Xsl
Contains classes that support Extensible Stylesheet Language (XSL) transformations The DiffGram is an XML format that identifies current and original versions of data allowing the contents of a DataSet to be recreated accurately. The DiffGram allows you to identify the changes made to a DataSet since it was filled. The DataSet uses the DiffGram format to persist and to serialize its contents for transport across a network. Recipe 8.8 shows how to create a DiffGram of changes made to a DataSet.

SQL Server 2000 introduced support for retrieving the results of queries in XML format using the FOR XML clause. The XmlReader provides direct forward-only, read-only access to the XML result set stream from the SQL Server. Recipe 8.5 shows how to use the FOR XML clause to retrieve XML-format data from a SQL Server using an XmlReader.

The SQLXML managed classes expose SQLXML functionality that allows .NET applications to access XML data from SQL Server 2000, process the XML data, and update the SQL Server using an XML DiffGram representation of the data. SQLXML classes support template queries, an XML document containing one or more SQL queries or stored procedures, to execute. Recipe 8.10 shows how to use template queries.

OpenXML allows an XML document to be used in a SQL statement in the same way a table or view is used. Recipe 8.11 shows how to use OpenXML from ADO.NET.

8.1 Using XSD Schema Files to Load and Save a DataSet Structure

Problem
You need to create an XSD schema from a DataSet and define the schema of a DataSet from an XSD schema.

Solution
Use the XmlTextWriter and XmlTextReader classes.

The sample code contains three event handlers:

Write Button.Click
Creates a DataSet containing the Orders table and Order Details table from Northwind and a relation between the two. The XSD schema for the DataSet is written both to a file and to a text box on the form.

Read Button.Click
Creates a DataSet and reads in the schema from a file containing a previously serialized XSD schema. The XSD schema is written from the DataSet to a stream and displayed.

Clear Button.Click
Clears the DataGrid and the result text box.


Customer reviews

There are no customer reviews yet.
5 star
0
4 star
0
3 star
0
2 star
0
1 star
0
Share your thoughts with other customers

Most helpful customer reviews on Amazon.com

Amazon.com: 4.3 out of 5 stars 8 reviews
One person found this helpful.
3.0 out of 5 starsA Door Stop
on 9 January 2008 - Published on Amazon.com
Verified Purchase
29 people found this helpful.
5.0 out of 5 starsExcellent.
on 14 October 2003 - Published on Amazon.com
3 people found this helpful.
5.0 out of 5 starsExample focused book.
on 5 October 2005 - Published on Amazon.com
17 people found this helpful.
5.0 out of 5 starsThis book is a must have!
on 28 January 2004 - Published on Amazon.com
3 people found this helpful.
5.0 out of 5 starsTips and Tricks with ADO.NET unrevealed
on 2 June 2006 - Published on Amazon.com