Read XSLT 2.0 and XPath 2.0 Programmer's Reference, 4th Edition Online
Authors: Michael Kay
This notation is found most commonly at the start of a relative path expression. For example,
../@name
selects the
name
attribute of the parent of the context node. It is possible to use
..
anywhere in a path expression, though the need rarely arises. For example,
//title/..
selects all elements in the document that have a
child element called
//*[title]
.
Document nodes never have a parent, so
/..
is always an empty sequence. In XPath 1.0, there was no direct way of representing an empty sequence, and so you may see this notation used when an empty sequence is needed, perhaps as the default value of a parameter in an XSLT template rule. In XPath 2.0 it's more natural to write this as
()
. Indeed, an XPath 2.0 processor that implements the static typing feature (see Chapter 3) may well give you an error if you write
/..
, kindly pointing out to you that it will never select anything.