O'Reilly logo

Pro SQL Server 2008 XML by Michael Coles

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 5. XQuery

The W3C defines the powerful XML Query (XQuery) language for querying XML data. SQL Server 2008 provides built-in support for XQuery via its xml data type methods. In this chapter, I will examine SQL Server's XQuery implementation and support, including keywords, syntax, and the XQuery/XPath Data Model (XDM). As always, I'll provide working examples to illustrate and highlight XQuery functionality along the way.

SQL Server implements XQuery through its xml data type methods: query(), value(), nodes(), exists(), and modify(). I introduced these methods in Chapter 3. I will begin this chapter with an introduction to the XQuery language and the XDM, finishing up with tips for maximizing SQL Server XQuery performance.

Introducing the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required