Introduction

Over the past few years, XML has emerged as the computer world’s favorite three-letter acronym. At first, XML was a curiosity about which a few technological boffins were getting a little over-excited—an interesting technology looking for a place to happen. Gradually, however, developers came to realize the enormous potential of a platform-neutral way to exchange structured data over the Internet, and we started to see people using XML in new and interesting ways. Of course, there’s nothing particularly noteworthy about this trend; in an industry where new technologies are often obsolete before they even get to market, it’s not unusual to see a mass adoption of the latest and greatest technological fashion. But XML has proved to have more staying power than many of the other techniques and technologies that have risen and fallen in the computing world. One reason for XML’s support is that unlike many new ideas, it doesn’t require us to throw away all our old ones. In fact, XML makes it easier to retain your existing systems and integrate them with new ones. It also makes it possible to integrate your applications with those of your trading partners, even if they’re using platforms and systems completely different from yours.

Integrating applications and businesses has long been the holy grail for many developers, and as the Internet has become the environment in which more and more development takes place, we’re constantly looking for ways to build integrated applications on the Web. XML is the key to this kind of integration. By adding support for XML to Microsoft SQL Server 2000, Microsoft has made it easier than ever to integrate SQL Server–based solutions with existing systems, Web applications, and trading partners.

Who Is This Book For?

Let’s start by understanding who this book is not for. It’s not designed to teach you XML (in spite of what the title of this book’s appendix suggests). Bookstores are already filled with shelves groaning under the weight of XML texts, and there’s enough information on the Web to help you become an XML guru, if that’s your ambition in life. I’ve generally assumed in this book that you’re familiar with the basic structure of an XML document and that you’re aware of XML-related technologies such as XSL style sheets and schemas. If you have no working experience with XML, you should read the appendix, "Introduction to XML," before reading the rest of the book. The appendix will familiarize you with basic XML knowledge that you need to work with XML and SQL Server. Similarly, I didn’t write the book with the intention of teaching all there is to know about SQL Server or the Transact-SQL language. In fact, I’m counting on your already being familiar with the basic Transact-SQL statements, such as SELECT, INSERT, UPDATE, and DELETE, and knowing something of the basic architectural and security concepts in SQL Server.

I wrote this book for anyone who needs to understand how to use XML to integrate applications or organizations that store data in a SQL Server database. The book covers XML-related functionality in SQL Server 2000 and describes how this functionality can be used to build a solution that exchanges data in XML format. Because a great deal of the emphasis in this book is on Internet-based applications, you’ll need to be familiar with some basic Web-development techniques for the Microsoft Windows platform, such as Microsoft Internet Information Services (IIS), Microsoft Active Server Pages (ASP), Hypertext Markup Language (HTML), and the Hypertext Transfer Protocol (HTTP). This book shows you how to use the XML functionality in SQL Server together with these technologies to build integration solutions that work across the Internet.

What’s in the Book?

With only nine chapters, this book is pretty short. I’ve tried to stick to the main points and avoid lengthy explanations of basic issues or architectural irrelevancies so that you can find the information you need quickly and easily. After all, you’re an advanced developer, and if you’re anything like me, you’ll want to get straight to the code you need to write in order to solve a particular business problem.

The first chapter offers a rationale for using XML in integration solutions and describes ways in which relational data can be mapped to XML. Chapters 2 through 7 examine the various XML-related features in SQL Server 2000 and show how these features can be used to build an XML-based data exchange application. I based code examples on the Northwind sample database, and many of the examples are provided as demonstrations on the companion CD. Chapter 8 describes the additional XML functionality provided in the XML For SQL Server 2000 Web Release 1, which you can download from the MSDN Web site at http://msdn.microsoft.com/downloads. These new tools consolidate the existing XML features in SQL Server, and I’ve included some sample code on the CD to help you get started with them. Finally, I describe in Chapter 9 a sample case study application that uses most of the techniques described in the book and integrates the XML functionality of SQL Server with Microsoft BizTalk Server 2000. The sample application is on the CD, so you can take the time-honored approach favored by most developers and simply dismantle it to see how it works.

Throughout the book, I’ve tried to emphasize the key challenges in integrating solutions with XML and focus on the code or configuration required to meet them. I hope you find the information and sample code useful in building your own integrated solutions with SQL Server and XML.

Using the Companion CD

The CD included with this book contains all sample programs and demos described in the book, a fully searchable electronic version of the book, and helpful tools. (See the Readme.txt file on the CD for information on using these tools.)

To view the contents of the CD, insert the CD into your CD-ROM drive. If the startup application doesn’t begin automatically, run StartCD.exe in the root directory of the CD.

Installing the Demonstration Files

You can view the demonstration files from the companion CD, or you can install them onto your hard disk and use them to create your own applications.

Installing the demonstration files and the sample application requires approximately 3.4 MB of hard disk space. To install the demonstration files, insert the companion CD into your CD-ROM drive and execute Setup.bat in the \Demos folder. To install the sample application for Chapter 9, execute Setup.bat in the \Sample Application folder. Some of the demonstration programs require that the full version of Microsoft Internet Explorer 5.5 be installed to work properly. If your computer doesn’t have Internet Explorer 5.5 installed, run ie55setup.exe in the MSIE55 folder to install Internet Explorer 5.5. If you have trouble running any of the demonstration files, refer to the Readme.txt file in the root directory of the companion CD or to the text in the book that describes the demonstration programs.

Tools

Two tools have been provided on this CD: the Microsoft XML Parser 3 and XML For SQL Server 2000 Web Release 1. They are located in the \Tools folder.

To install the tools, run the Setup program in the \Tools folder and follow the Setup instructions. You can also run these tools directly from the CD.

System Requirements

To see the demonstrations and sample applications provided on the companion CD, you’ll need a computer with the following configuration:

  • Microsoft Windows 2000 Server (or Advanced Server)
  • Microsoft SQL Server 2000 (Standard or Enterprise Edition)
  • Microsoft Internet Explorer 5.5
  • The Microsoft XML Parser (MSXML) 3 (installed in Replace mode using Xmlinst.exe)
  • The XML For SQL Server 2000 Web Release 1 (required for the Chapter 8 demonstrations)
  • Microsoft BizTalk Server 2000 (optional, but required for the full case study application)

You can download evaluation editions of Windows 2000, SQL Server 2000, and BizTalk Server 2000 from http://www.microsoft.com/servers.

Microsoft Press Support Information

Every effort has been made to ensure the accuracy of this book and the contents of the practice files CD-ROM. If you do run into a problem, Microsoft Press provides corrections for its books through the World Wide Web at

http://mspress.microsoft.com/support/support.htm

If you have comments, questions, or ideas regarding the presentation or use of this book or the companion CD, you can send them to Microsoft using either of the following methods:

Postal Mail:

Microsoft Press Attn: Programming Microsoft SQL Server 2000 with XML Editor One Microsoft Way Redmond, WA 98052-6399

E-mail:

MSPINPUT@MICROSOFT.COM

Please note that product support isn’t offered through the preceding mail addresses.



Programming Microsoft SQL Server 2000 With Xml
Programming Microsoft SQL Server(TM) 2000 with XML (Pro-Developer)
ISBN: 0735613699
EAN: 2147483647
Year: 2005
Pages: 89

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net