- XQuery Tutorial
- XQuery - Home
- XQuery - Overview
- XQuery - Environment Setup
- XQuery - First Application
- XQuery - FLWOR
- XQuery - HTML Format
- XQuery - XPath
- XQuery - Sequences
- XQuery - Sequence Functions
- XQuery - String functions
- XQuery - Date Functions
- XQuery - Regular Expressions
- XQuery - If Then Else
- XQuery - Custom Functions
- XQuery Useful Resources
- XQuery - Quick Guide
- XQuery - Useful Resources
- XQuery - Discussion
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
XQuery - Sequence Functions
The following table lists the commonly used sequence functions provided by XQuery.
|Sr.No||Name & Description|
Counts the items in a sequence.
Returns the sum of the items in a sequence.
Returns the average of the items in a sequence.
Returns the minimum valued item in a sequence.
Returns the maximum valued item in a sequence.
distinct-values($seq as item()*)
Returns select distinct items from a sequence.
subsequence($seq as item()*, $startingLoc as xs:double, $length as xs:double)
Returns a subset of provided sequence.
insert-before($seq as item()*, $position as xs:integer, $inserts as item()*)
Inserts an item in a sequence.
remove($seq as item()*, $position as xs:integer)
Removes an item from a sequence.
Returns the reversed sequence.
index-of($seq as anyAtomicType()*, $target as anyAtomicType())
Returns indexes as integers to indicate availability of an item within a sequence.
Returns the last element of a sequence when used in predicate expression.
Used in FLOWR expressions to get the position of an item in a sequence.