exists

Whether an argument is the empty sequence

Description

The fn:exists function returns true if the sequence contains one or more items; it is the opposite of the fn:empty function. It is often unnecessary to call the fn:exists function because sequences are automatically converted to the effective boolean value where a boolean value is expected.

Parameters

Description

arg:string()

Examples

XPath

Results

exists( (‘a’, ‘b’, ‘c’) )

true

exists( ‘’ )

true

exists( () )

false

exists( false() )

true

See Also