Chapter 4. Accessing SQL 2000 via HTTP


graphics/chic01.gif

In the first three chapters,we covered the XML specification, Extensible Stylesheet Language Transformations (XSLT), and the necessary setup steps for virtual roots on SQL Server. In this chapter, we'll first discuss client/server architecture to give you a feel for how the different system components , application servers, database servers, and so on interact with each other. Then we'll look at how to utilize the HTTP protocol in various ways to execute SQL statements against SQL Server. This includes the use of template files to generate XML data. Utilizing the HTTP protocol via URLs will simplify our tasks because most people in the computer industry are very familiar with this process.

This chapter will cover the following topics:

  • General client/server architecture in two-, three-, and n-tiered configurations

  • SQL Server 2000's HTTP capabilities

  • Entities in XML and URLs

  • Generating XML documents by querying SQL Server via HTTP

  • Generating XML documents utilizing XML template files

  • Generating XML documents utilizing stored procedures

I think it's about time to define this template file that we've been talking about. It's not some new language you'll have to learn, so you can relax. It also has nothing to do with the template elements of XSLT that we learned about in Chapter 2,"XSLT Stylesheets." Simply put, these templates are just XML files that contain one or more SQL statements. When these templates are applied to a database through mechanisms you'll learn about in this chapter, they help produce results in XML format.

Let's take one last look at the XML process diagram that we used in Chapter 1, "Database XML," and Chapter 2 (see Figure 4.1).

Figure 4.1. The XML process.

graphics/04fig01.gif

Yes, that's right; this is the last look. We've covered all the components in the diagram and will remain at the XML engine component for the rest of this book. The XML engine is SQL Server 2000.



XML and SQL Server 2000
XML and SQL Server 2000
ISBN: 0735711127
EAN: 2147483647
Year: 2005
Pages: 104
Authors: John Griffin

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