Chapter 4. Static Typing in XQuery

Mary Fernández, Jérôme Siméon, and Philip Wadler

XQuery is a strongly typed language, meaning that the types of values and expressions must be compatible with the context in which the value or expression is used. All implementations of XQuery must support dynamic typing, which checks during dynamic evaluation that the type of a value is compatible with the context in which it is used and raises a type error if an incompatibility is detected. XQuery implementations may optionally support static typing, which checks during static analysis that the type of an expression is compatible with the context in which it is used. Static Typing can shorten the development cycle by detecting common type errors before a query ...

Get XQuery from the Experts: A Guide to the W3C XML Query Language now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.