Share this Page URL

Chapter 16. Working with XML Data in Acc... > Exporting an Access Table to an XML ... - Pg. 567

Working with XML Data in Access 567 Given the fact that XML has been designed as a way to structure pieces of information, there is a strong synergy between XML and database applications like Access. The most fundamental level of support for XML in Access is getting data out of the database into an XML document and putting data into the database from an XML document. We'll look at these two features next. Quick Check Q. What is the main difference between XML and HTML? A. HTML is a tag set that is designed primarily for the presentation of content or data. XML is a tag set that is designed primarily for the structuring of data. Q. Does an XML document contain inherent constraints? A. No. An XML document is constrained by a set of rules known as a schema. The schema typically is a separate document that is referenced in the header of the XML document. Exporting an Access Table to an XML Document A schema can be written for a very specific application so that the constraints are unique to that application only. To demonstrate how all this works, Access will allow us to export a table to an XML document and will automatically create all the supporting documents for us. Let's export a single table to an XML document and examine the parts. Export an Access table to an XML document 1. Start Access, and open the file HelloWorld16.mdb, located in the Chap16 folder, where you copied the sample files for this book.