fn:get-namespace-from-QName

Return namespace URI of QName argument.

Top of page

Related Syntax Constructs

The following construct(s) refer to this construct:


Syntax

fn:get-namespace-from-QName(QName? $qName) => anyURI?

Description

This function returns the namespace URI for $qName. If $qName is in no namespace, the function returns the empty sequence.

Argument

$qName

value of type xs:QName

Example

  • Retrieve namespace from QName http://company.dot.com/namespaces/corporate:

    get-namespace-from-QName(expanded-QName("http://company.dot.com", "namespaces/corporate"))

    This query returns the string http://company.dot.com.