Hi, I'm Ask INFA!
What would you like to know?
ASK INFAPreview
Please to access Ask INFA.

Table of Contents

Search

  1. Preface
  2. Understanding Data Types and Field Properties
  3. Designing Processes
  4. Using and Displaying Data
  5. Designing Guides
  6. Designing Process Objects
  7. Designing Service Connectors
  8. Using App Connections
  9. System Services, Listeners and Connectors
  10. Designing Human Tasks

Design

Design

idref

idref

The idref function in XQuery returns the sequence of element or attribute nodes with an
IDREF
value matching the value of one or more of the
ID
values supplied in
$arg
.

Syntax

fn:idref(arg, node)
The following table describes the argument for this command:
Argument
Required/Optional
Description
arg
Required
One or more IDREF values (space-separated tokens) to find referencing elements.
node
Optional
The node that provides context for resolving IDREFs. Defaults to root node of the context item if omitted.

Return Value

  • Returns a sequence of element nodes whose IDREF attributes contain any of the specified
    $arg
    values.
  • Returns an empty sequence if no matching IDREFs are found.

Examples

The following table lists some sample values and return values:
SAMPLE FUNCTION
OUTPUT
fn:idref("item1", /root)
Elements that refer to the ID "item1" under
/root
.
fn:idref(("item1", "item2"))
Sequence of elements referring to "item1" or "item2".
fn:idref("nonexistent")
()
fn:idref("item1")
(with context node omitted)
Elements referring to "item1" relative to context root node.

Additional information

  • The IDREF attributes must be declared accordingly in the schema or DTD for IDREF resolution.
  • The
    $arg
    can hold multiple space-separated reference values.
  • The function depends on the context node or defaults to the root of the context item.

0 COMMENTS

We’d like to hear from you!