the XQuery language as supported by database systems. Include the tag of your system to specify ("sql-server", "oracle", "postgresql", etcetera). Use the "xquery" tag on its own for general questions about XQuery.
XQuery is a query language designed to extract data from arbitrary XML documents. Multiple RDBMSes support XQuery as part of the SQL/XML standard or using proprietary syntax. What follows is a non-exhaustive list.
Microsoft SQL Server
In SQL Server 2005 and onwards, the xml
data type methods, in particular .query()
, support querying XML and returning the results as relational data. These methods support a subset of XQuery, with special support for some T-SQL specific constructs like variables -- see the XQuery Language Reference for specifics.
Oracle
Oracle includes XML support as Oracle XML DB. It supports XQuery both for querying and updating data, both relational and XML. The XMLQUERY function is used to issue XQuery queries within an SQL statement.