Skip Headers
Oracle® BPEL Process Manager Developer's Guide
10g Release 2 (10.1.2)
B14448-02
  Go To Documentation Library
Home
Go To Product List
Solution Area
Go To Table Of Contents
Contents
Go To Index
Index

Previous
Previous
Next
Next
 

G XPath Extension Functions

Oracle provides additional XPath functions that use built-in BPEL capabilities and XPath standards. These functions also display in Oracle BPEL Console under Manage BPEL Domain > XPath Library.

This appendix contains the following topics:

G.1 XPath Extension Functions Available to BPEL Processes

The following is an alphabetical list of additional XPath functions, along with the function descriptions, arguments, and other information.

G.1.1 abs

This function returns the absolute value of inputNumber.If inputNumber is not negative, the inputNumber is returned. If the inputNumber is negative, the negation of inputNumber is returned.

Example: abs(-1) returns 1.

Signature:

xp20:abs(inputNumber as number)

Arguments:

  • inputNumber as number - The number for which the function returns an absolute value.

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.2 add-dayTimeDuration-to-dateTime

This function returns a new date time value adding dateTime to the given duration.

If the duration value is negative, then the resulting value precedes dateTime.

Signature:

xp20:add-dayTimeDuration-from-dateTime(dateTime as string, duration as string)

Arguments:

  • dateTime as string - The dateTime to which the function adds the duration, in string format.

  • duration as string - The duration to add to the dateTime, or subtract if the duration is negative, in string format.

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.3 addChildNode

This function adds the World Wide Web consortium (W3C) document object model (DOM) child node to the incoming DOM element and returns the modified element.

Signature:

ora:addChildNode(DOMElement element, Node node)

Arguments:

  • DOMElement - The DOM element to be modified

  • Node - The DOM child note to add to the DOM Element

Property IDs:

  • deprecated

    Use the bpelx:append or bpelx:insertBefore extension activity to add or append a child node. This extension activity is demonstrated in Oracle_Home\integration\orabpel\samples\tutorials\126.DataAggregator.

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.4 addQuotes

This function returns the content of a string with single quotes added.

Signature:

ora:addQuotes(string)

Arguments:

  • string - The string to which this function adds quotes

Property IDs:

  • namespace-uri:http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.5 appendToList

This function appends to a node list. The node list to be appended with should not be null or empty.

Signature:

ora:appendToList('variableName', 'partName'?, 'locationPath'?, Object)

Arguments:

  • variableName - The source variable for the data

  • partName - The part to select from the variable (optional)

  • locationPath - Provides an absolute location path (with / meaning the root of the document fragment representing the entire part) to identify the root of a subtree within the document fragment representing the part (optional).

  • Object - The object can be either a list or a single item. If the object is a list, this function appends each item in the list. Each appended item is either an element, or an element with the string value of the node created.

Property IDs:

  • deprecated

    Use the bpelx:copyList extension activity to append to a list. This extension activity is demonstrated in sample Oracle_Home\integration\orabpel\samples\tutorials\126.DataAggregator.

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.6 authenticate

This function authenticates a lightweight directory access protocol (LDAP) user and returns true or false.

Signature:

ldap:authenticate('properties','userId','password')

Arguments:

  • properties - The name of the directory specified in the directories.xml file

  • userId - The LDAP user's ID

  • password - The LDAP user's password

Property IDs:

  • namespace-uri:http://schemas.oracle.com/xpath/extension/ldap

  • namespace-prefix: ldap

G.1.7 batchProcessActive

This function returns the number of active processes in the batch.

Signature:

ora:batchProcessActive( String batchId, String processId )

Arguments:

  • batchId - The ID of the batch

  • processId - The ID of the process

Property IDs:

  • namespace-uri:http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.8 batchProcessCompleted

This function returns the number of completed processes in the batch.

Signature:

ora:batchProcessCompleted( String batchId, String processId )

Arguments:

  • batchId - The ID of the batch

  • processId - The ID of the process

Property IDs:

  • namespace-uri:http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.9 clearTaskAssignees

This function clears the current task assignees.

Signature:

ora:clearTaskAssignees(task)

Arguments:

  • task - The task

Property IDs:

  • namespace-uri:http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.10 compare

This function returns the lexicographical difference between inputString and compareString comparing the unicode value of each character of both the strings.

This function returns -1 if inputString lexicographically precedes the compareString.

This function returns 0 if both inputString and compareString are equal.

This function returns 1 if inputString lexicographically follows the compareString.

Example: xp20:compare('Audi', 'BMW') returns -1

Signature:

xp20:compare(inputString as string, compareString as string)

Arguments:

  • variableName - The source variable for the data

  • propertyName - The qualified name (QName) of the property

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.11 compare-ignore-case

This function returns the lexicographical difference between inputString and compareString while ignoring case and comparing the unicode value of each character of both the strings.

This function returns -1 if inputString lexicographically precedes the compareString.

This function returns 0 if both inputString and compareString are equal.

This function returns 1 if inputString lexicographically follows the compareString.

Example: xp20:compare-ignore-case('Audi','bmw') returns -1

Signature:

orcl:compare-ignore-case(inputString as string, compareString as string)

Arguments:

  • inputString as string - The input string

  • CompareString as string - The string to compare against the input string

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.12 copyList

This function copies a node list or a node. The node list to be copied to should not be null or empty.

Signature:

ora:copyList('variableName', 'partName'?, 'locationPath'?, Object)

Arguments:

  • variableName - The source variable for the data

  • locationPath - Provides an absolute location path (with / meaning the root of the document fragment representing the entire part) to identify the root of a subtree within the document fragment representing the part (optional)

  • partName - The part to select from the variable (optional)

  • Object - The object can be either a list or a single item. If the object is a list, each item in the list is copied. Each item to be copied is either an element, or an element with the string value of the node created.

Property IDs:

  • deprecated

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.13 countNodes

This function returns the number of the elements as an integer.

Signature:

ora:countNodes('variableName', 'partName'?, 'locationPath'?)

Arguments:

  • variableName - The source variable for the data

  • partName - The part to select from the variable (optional)

  • locationPath - Provides an absolute location path (with / meaning the root of the document fragment representing the entire part) to identify the root of a subtree within the document fragment representing the part (optional).

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.14 create-delimited-string

This function returns a delimited string created from nodeSet delimited by delimiter.

Signature:

orcl:create-delimited-string(nodeSet as node-set, delimiter as string)

Arguments:

  • nodeSet - The node set to be converted into a deliminated string

  • delimiter - The character that separates the items in the output string; for example, a comma or a semicolon.

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.15 create-nodeset-from-deliminated-string

The function takes a deliminated string and returns a nodeSet.

Signature:

orcl:create-nodeset-from-deliminated-string(qname, deliminated-string, delimiter)

Arguments:

  • qname - The qualified name in which each node in the node set must be created. The QName can be represented in two forms:

    • task:assignee

    • {http://mytask/task}assignee

  • delimited-string - The sting of elements separated by the delimiter.

  • delimiter - The character that separates the items in the input string; for example, a comma or a semicolon.

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.16 createDeliminatedString

This function creates a delimited string from the arguments.

Signature:

ora:createDelimitedString('delimiter', Object)

Arguments:

  • delimiter - the character that separates the items in the input string; for example, a comma or a semicolon.

  • Object - The node set this function converts to a deliminated string.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.17 current-date

This function returns the current date in ISO format YYYY-MM-DD.

Signature:

xp20:current-date(object)

Arguments:

  • Object - The time in standard format

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.18 current-dateTime

This function returns the current datetime-value in ISO format CCYY-MM-DDThh:mm:ssTZD.

Signature:

xp20:current-dateTime(object)

Arguments:

  • object - The time in standard format

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.19 current-time

This function returns the current time in ISO format. The format is hh:mm:ssTZD.

Signature:

xp20:current-time(object)

Arguments:

  • object - The time in standard format

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.20 day-from-dateTime

This function returns the day from dateTime. The default day is 1.

Signature:

xp20:day-from-dateTime(object)

Arguments:

  • object - The time in standard format

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.21 doc

This function returns the content of an XML file.

Signature:

ora:doc('fileName','xpath'?)

Arguments:

  • fileName - The name of the XML file

  • xpath -

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.22 ends-with

This function returns true if inputString ends with searchString.

Example: xp20:ends-with('XSL Map','Map') returns true

Signature:

xp20:ends-with(inputString as string, searchString as string)

Arguments:

  • inputString - The string of data to be searched

  • searchString - The string for which the function searches

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.23 format

This function formats a message using Java's Message Format.

Signature:

ora:format(formatStrings, args+)

Arguments:

  • formatStrings - The string of data to be formatted

  • args+ -

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.24 format-dateTime

This function returns the formatted string of dateTime using the format provided.

Signature:

xp20:format-dateTime(dateTime as string, format as string)

Arguments:

  • dateTime - The dateTime to be formatted

  • format - The format for the output

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.25 format-string

This function returns the message formatted with the arguments passed. At least one argument is required and supports up to a maximum of 10 arguments.

Example: orcl:format-string('{0} + {1} = {2}','2','2','4') returns '2 + 2 = 4'

Signature:

orcl:format-string(string,string,string...)

Arguments:

  • string - One of the strings to be used in the formatted output

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.26 formatDate

This function converts standard XSD date formats to characters suitable for output.

Signature:

ora:formatDate('dateTime', 'format')

Arguments:

  • dateTime - Contains a date-related value in XSD format. For nonstring arguments, this function behaves as if a string() function were applied. If the argument is not a date, the output is an empty string. If it is a valid XSD date and some fields are empty, this function attempts to fill unspecified fields. For example, 2003-06-10T15:56:00.

  • format - Contains a string formatted according to java.text.SimpleDateFormat format

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.27 genEmptyElem

This function generates a list of empty elements for the given QName.

Signature:

ora:genEmptyElem('ElemQName',size?, 'TypeQName'?, xsiNil?)

Arguments:

  • ElemQName - The first argument is the QName of the empty elements

  • size - The second optional integer argument for the number of empty elements. If missing, the default size is 1.

  • TypeQName - The third optional argument is the QName, which is the xsi:type of the generated empty name. This xsi:type pattern matches SOAPENC:Array. If missing or an empty string, the xsi:type attribute is not generated.

  • xsiNil - The fourth optional Boolean argument is to specify whether the generated empty elements are XSI - nil, provided the element is XSD-nillable. The default is false. If missing or false, xsi:nil is not generated.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.28 generate-guid

Generates a unique GUID.

Signature:

orcl:generate-guid(object)

Arguments:

  • object -

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.29 generateGUID

Generates a unique GUID.

Signature:

ora:generateGUID()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.30 get-content-as-string

This function returns the XML representation of the input element.

Signature:

orcl:get-content-as-string(element as node-set)

Arguments:

  • element as node-set - The input element that the function returns as an XML representation

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.31 get-localized-string

This function returns the locale-specific string for key. This function uses language, country, variant, and resource bundle to identify the correct resource bundle.

The resource bundle in obtained by resolving resourceLocation against the resourceBaseURL. The URL is assumed to be a directory only if it ends with /.

Usage: orcl:get-localized-string(resourceBaseURL as string, resourceLocation as string, resource bundle as string, language as string, country as string, variant as string, key as string)

Example: orcl:get-localized-string('file:/c:/','','MyResourceBundle','en','US','','MSG_KEY') returns a locale-specific string from a resource bundle 'MyResourceBundle' in the C:\ directory

Signature:

orcl:get-localized-string(resourceURL,resourceLocation,resourceBundleName,language,country,variant,messageKey)

Arguments:

  • resourceURL - The URL of the resource

  • resourceLocation - The subdirectory location of the resource

  • resourceBundleName - The name of the zip file containing the resource bundle

  • language - The language of the localized output

  • country - The country of the localized output

  • variant - The language variant of the localized output

  • messageKey - The message key in the resource bundle

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.32 getChildElement

This function gets a child element for the given element

Signature:

ora:getChildElement(element, index)

Arguments:

  • element - The source for the data

  • index - Integer value of the child element index

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.33 getContentAsString

This function returns the content of an element as an XML string.

Signature:

ora:getContentAsString(element)

Arguments:

  • element - The source for the data

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.34 getConversationId

This function returns the conversation ID

Signature:

ora:getConversationId()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.35 getCreator

This function returns the instance creator.

Signature:

ora:getCreator()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.36 getCurrentDate

This function returns the current date as a string.

Signature:

ora:getCurrentDate('format'?)

Argument:

  • format - Specifies a string formatted according to java.text.SimpleDateFormat format (optional).

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.37 getCurrentDateTime

This function returns the current date time as a string.

Signature:

ora:getCurrentDateTime('format'?)

Argument:

  • format - Specifies a string formatted according to java.text.SimpleDateFormat format (optional).

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.38 getCurrentTime

This function returns the current time as a string.

Signature:

ora:getCurrentTime('format'?)

Argument:

  • format - Specifies a string formatted according to java.text.SimpleDateFormat format (optional).

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.39 getDomainId

This function returns the current domain ID.

Signature:

ora:getDomainId()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.40 getElement

This function returns an element using index from the array of elements.

Signature:

ora:getElement('variableName', 'partName', 'locationPath', index)

Arguments:

  • variableName - The source variable for the data

  • partName - The part to select from the variable (required)

  • locationPath - Provides an absolute location path (with / meaning the root of the document fragment representing the entire part) to identify the root of a subtree within the document fragment representing the part (required).

  • index - Dynamic index value. The index of the first node is 1.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.41 getGroupIdsFromGroupAlias

This function returns a List of user Ids for a group alias specified in the TaskServiceAliases section of the BPEL suitcase descriptor.

Signature:

ora:getGroupIdsFromGroupAlias( String aliasName )

Arguments:

  • aliasName - The alias for a list of users or groups as defined in the bpel.xml file

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.42 getGroupProperty

This function retrieves the number of task attachments.

Signature:

ora:getGroupProperty(groupId, attributeName)

Arguments:

  • groupId - String or element containing the group whose attribute should be retrieved

  • attributeName - String or element containing the name of the group attribute. The attribute name should be one of the following values:

    1. displayName

    2. mail

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.43 getInstanceId

This function returns the instance ID.

Signature:

ora:getInstanceId()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.44 getLinkStatus

This function returns a Boolean indicating the status of the link. If the status of the link is positive the value is true, otherwise the value is false. This function can only be used in a join condition.

The linkName argument refers to the name of an incoming link for the activity associated with the join condition.

Signature:

bpws:getLinkStatus ('linkName')

Arguments:

  • variableName - The source variable for the data

  • propertyName - The QName of the property

Property IDs:

  • namespace-uri: http://schemas.xmlsoap.org/ws/2003/03/business-process/

  • namespace-prefix: bpws

G.1.45 getManager

This function gets the manager of a given user. If the user does not exist or if there is no manager for this user, it returns null.

Signature:

ora:getManager(userID)

Arguments:

  • userID - The ID of the user for whom this function returns their manager

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.46 getMessage

This function gets a message based on the arguments.

Signature:

ora:getMessage(locale, relativeLocation, resourceName, resourceKey, resourceLocation?)

Arguments:

  • locale - The locale of the message

  • relativeLocation - The subdirectory or message

  • resourceName - The name of the message resource

  • resourceKey - The key of the resource

  • resourceLocation - The location of the resource

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.47 getNodeValue

This function returns the value of a DOM node as a string.

Signature:

ora:getNodeValue(node)

Arguments:

  • node - The DOM node

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.48 getNodes

This function get a node list. This is implemented as an alternate to bpws:getVariableData, which does not return a node list.

Signature:

ora:getNodes('variableName', 'partName'?, 'locationPath'?)

Arguments:

  • variableName - The source variable for the data

  • partName - The part to select from the variable (optional)

  • locationPath - Provides an absolute location path (with / meaning the root of the document fragment representing the entire part) to identify the root of a subtree within the document fragment representing the part (optional).

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.49 getNumberOfTaskApprovals

This function computes the number of times the task was approved.

Signature:

ora:getNumberOfTaskApprovals(taskId)

Arguments:

  • taskId - The ID of the task

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.50 getPreference

This function returns the value of a property specified in the preferences section of the BPEL suitcase descriptor.

Signature:

ora:getPreference( String preferenceName )

Arguments:

  • preferenceName - The name of the preference as specified in the BPEL suitcase descriptor

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.51 getPreviousTaskApprover

This function retrieves the previous task approver.

Signature:

ora:getPreviousTaskApprover(taskId)

Arguments:

  • taskId - The ID of the task

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.52 getProcessId

This function returns the ID of the current BPEL process.

Signature:

ora:getProcessId()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.53 getProcessOwnerId

This function returns the ID of the user who owns the process, if specified in the TaskServiceAliases section of the BPEL suitcase descriptor.

Signature:

ora:getProcessOwnerId()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.54 getProcessURL

This function returns the root URL of the current BPEL process.

Signature:

ora:getProcessURL()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.55 getProcessVersion

This function returns the current process version.

Signature:

ora:getProcessVersion()

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.56 getReportees

This function gets the direct reportees of the user. If the user does not exist, it returns null. The function returns a list of nodes. Each node in the list is called user and the namespace URI of the node is http://oracle.tip.pc.services.identity/RemoteIdentityService.xsd.

Signature:

ora:getReportees(userId)

Arguments:

  • userId - The ID of the user

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.57 getTaskAttachmentByIndex

This function retrieves the task attachment at the specified index.

Signature:

ora:getTaskAttachmentByIndex(taskId, attachmentIndex)

Arguments:

  • taskId - The task ID of the task

  • attachmentIndex - The index of the attachment. The index begins from 1.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.58 getTaskAttachmentByName

This function retrieves the task attachment by the attachment name.

Signature:

ora:getTaskAttachmentByName(taskId, attachmentName)

Arguments:

  • taskId - The task ID of the task.

  • attachmentName - The name of the attachment.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.59 getTaskAttachmentContents

This function retrieves the task attachment contents by the attachment name.

Signature:

ora:getTaskAttachmentContents(taskId, attachmentName)

Arguments:

  • taskId - The task ID of the task.

  • attachmentName - The name of the attachment.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.60 getTaskAttachmentsCount

This function retrieves the number of task attachments.

Signature:

ora:getTaskAttachmentsCount(taskId)

Arguments:

  • taskId - The task ID

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.61 getTaskAutoReleaseDuration

This function computes the release duration for the task when it is acquired.

Signature:

ora:getTaskAutoReleaseDuration(taskId)

Arguments:

  • taskId - The ID of the task

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.62 getTaskReminderDuration

This function computes the next reminder to be sent for the task.

Signature:

ora:getTaskReminderDuration(taskId)

Arguments:

  • taskId - The ID of the task

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.63 getUserAliasId

This function returns the user ID for an alias specified in the TaskServiceAliases section of the BPEL suitcase descriptor.

Signature:

ora:getUserAliasId( String aliasName)

Arguments:

  • aliasName - The alias for a list of users or groups as defined in the bpel.xml file.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.64 getUserIdsFromGroupAlias

This function returns a List of user IDs for a group alias specified in the TaskServiceAliases section of the BPEL suitcase descriptor.

Signature:

ora:getUserIdsFromGroupAlias( String aliasName)

Arguments:

  • aliasName - The alias for a list of users or groups as defined in the bpel.xml file.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.65 getUserProperty

This function retrieves the number of task attachments.

Signature:

ora:getUserProperty(userId, attributeName)

Arguments:

  • userId - String or element containing the user whose attribute should be retrieved

  • attributeName - String or element containing the name of the user attribute. The attribute name should be one of the following values:

    1. givenName

    2. middleName

    3. sn

    4. displayName

    5. mail

    6. telephoneNumber

    7. homephone

    8. mobile

    9. facsimileTelephoneNumber

    10. pager

    11. preferredLanguage

    12. manager

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.66 getUserRoles

This function gets the user roles. This function returns a list of objects, either role object or group objects depending on the roleType.

The function returns a list of nodes. Each node in the list is called group or role depending on the roleType and the namespace URI of the node is http://oracle.tip.pc.services.identity/RemoteIdentityService.xsd.

Signature:

ora:getUserRoles(userId, roleType, direct)

Arguments:

  • userId - String or element containing the user whose roles are to be retrieved

  • roleType - The role type - should be one of the three values: ApplicationRole, EnterpriseRole, or AnyRole

  • direct - String or element indicating if direct or indirect roles should be fetched. This is optional and if not specified, only direct roles are fetched. This should be xsd:boolean or string true/false.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.67 getUsersInGroup

This function gets the users in a group. If the group does not exist, it returns null. The function returns a list of nodes. Each node in the list is called user and the namespace URI of the node is http://oracle.tip.pc.services.identity/RemoteIdentityService.xsd.

Signature:

ora:getUsersInGroup(groupId)

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.68 getVariableData

This function extracts arbitrary values from BPEL variables.

When only the first argument is present, the function extracts the value of the variable, which in this case must be defined using an XML Schema simple type or element. Otherwise, the return value of this function is a node set containing the single node representing either an entire part of a message type (if the second argument is present and the third argument is absent) or the result of the selection based on the locationPath (if both optional arguments are present). If the given locationPath selects a node set of a size other than one during execution, the standard fault bpws:selectionFailure is thrown.

Signature:

bpws:getVariableData ('variableName', 'partName'?, 'locationPath'?)

Arguments:

  • variableName - The source variable for the data

  • partName - The part to select from the variable (optional)

  • locationPath - Provides an absolute location path (with / meaning the root of the document fragment representing the entire part) to identify the root of a subtree within the document fragment representing the part (optional).

Property IDs:

  • namespace-uri: http://schemas.xmlsoap.org/ws/2003/03/business-process/

  • namespace-prefix: bpws

G.1.69 getVariableProperty

This function extracts arbitrary values from BPEL variables.

If the given property selects a node set of a size other than one during execution, the standard fault bpws:selectionFailure is thrown.

Signature:

bpws:getVariableProperty ('variableName', 'propertyname')

Arguments:

  • variableName - The source variable for the data

  • propertyName - The QName of the property

  • locationPath - Provides an absolute location path (with / meaning the root of the document fragment representing the entire part) to identify the root of a subtree within the document fragment representing the part (optional).

Property IDs:

  • namespace-uri: http://schemas.xmlsoap.org/ws/2003/03/business-process/

  • namespace-prefix: bpws

G.1.70 hours-from-dateTime

This function returns the hour from dateTime. The default hour is 0.

Signature:

xp20:hours-from-dateTime(dateTime as string)

Arguments:

  • dateTime as string - The dateTime

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.71 implicit-timezone

This function returns the current time zone in ISO format +/- hh:mm, indicating a deviation from UTC (Coordinated Universal Timezone).

Signature:

xp20:implicit-timezone(object)

Arguments:

  • object - The time in standard format

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.72 index-within-string

This function returns the zero-based index of the first occurrence of searchString within the inputString.

This function returns -1 if searchString is not found.

Example: orcl:index-within-string('ABCABC, 'B') returns 1

Signature:

orcl:index-within-string(inputString as string, searchString as string)

Arguments:

  • inputString - The string to be searched

  • searchString - The string for which the function searches in the inputString

Property IDs:

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.73 integer

This function returns the content of the node as an integer.

Signature:

ora:integer(node)

Arguments:

  • node - The input node

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.74 isUserInRole

This function verifies if a user has a given role, returning a Boolean true or false.

Signature:

ora:isUserInRole(userId, roleName)

Arguments:

  • userId - String or element containing the user whose participation in the role should be verified

  • roleName - The role name

  • direct - String or element indicating if direct or indirect roles should be fetched. This is optional and if not specified, only direct roles are fetched. This should be xsd:boolean or string true/false.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.75 last-index-within-string

This function returns the zero-based index of the last occurrence of searchString within inputString.

This function returns -1 if searchString is not found.

Example: orcl:last-index-within-string('ABCABC', 'B') returns 4

Signature:

orcl:last-index-within-string(inputString as string, searchString as string)

Arguments:

  • inputString - The string to be searched

  • searchString - The string for which the function searches in the inputString

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.76 lookupUser

This function returns LDAP user information.

Signature:

ldap:lookupUser('properties','userId')

Arguments:

  • properties - The properties name as defined in the directories.xml file

  • userId - The ID of the user for which this function returns LDAP information

Property IDs:

  • namespace-uri

    • Value: http://schemas.oracle.com/xpath/extension/ldap

  • namespace-prefix

    • Value: ldap

G.1.77 left-trim

This function returns the value of inputString after removing all the leading white spaces.

Example: orcl:left-trim(' account ') returns 'account '

Signature:

orcl:left-trim(inputString)

Arguments:

  • inputString - The string to be left-trimmed

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.78 listUsers

This function returns a list of LDAP users.

Signature:

ldap:listUsers('properties','filter')

Arguments:

  • properties - The properties name as defined in the directories.xml file

  • filter - The LDAP filter

Property IDs:

  • namespace-uri

    • Value: http://schemas.oracle.com/xpath/extension/ldap

  • namespace-prefix

    • Value: ldap

G.1.79 lookup-table

This function returns a string based on the SQL query generated from the parameters.

The string is obtained by executing:

SELECT outputColumn FROM table WHERE inputColumn = key

against the data source that can be either a JDBC connect string (jdbc:oracle:thin:username/password@host:port:sid) or a data source JNDI identifier. Only Oracle Thin Driver is supported if the JDBC connect string is used.

Example: orcl:lookup-table('employee','id','1234','last_name','jdbc:oracle:thin:scott/tiger@localhost:1521:ORCL')

Signature:

orcl:lookup-table(table, inputColumn, key, outputColumn, datasource)

Arguments:

  • table - The table from which to draw the data

  • inputColumn - The column within the table

  • key - The key

  • outputColumn - The column to output the data

  • datasource - The source of the data

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.80 lookup-xml

This function returns the string value of an element defined by lookupXPath in an XML file (docURL) given its parent XPath (parentXPath), the key XPath (keyXPath), and the value of the key (key).

Example: orcl:lookup-xml('file:/d:/country_data.xml', '/Countries/Country', 'Abbreviation', 'FullName', 'UK') returns the value of the element FullName child of /Countries/Country where Abbreviation = 'UK' is in the file D:\country_data.xml.

Signature:

orcl:lookup-xml(docURL, parentXPath, keyXPath, lookupXPath, key)

Arguments:

  • docURL - The XML file

  • parentXPath - The parent XPath

  • keyXPath - The key XPath

  • lookupXPath - The lookup XPath

  • key - The key value

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.81 lookupUser

This function returns LDAP user information.

Signature:

ora:lookupUser(UserID)

Arguments:

  • object - The string or node with the user name or ID

Property IDs:

  • namespace-uri

    • Value: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix

    • namespace-uri: http://schemas.oracle.com/xpath/extension

    • namespace-prefix: ora

G.1.82 lookupGroup

This function looks up a group based on the arguments.

Signature:

ora:lookupGroup(object)

Arguments:

  • object - The string containing the group name or ID

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.83 lower-case

This function returns the value of inputString after translating every character to its lower-case correspondent.

Example: xp20:lower-case('ABc!D') returns 'abc!d'

Signature:

xp20:lower-case(inputString)

Arguments:

  • inputString - The input string

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.84 matches

This function returns true if intputString matches the regular expression pattern regexPattern.

Example: xp20:matches('abracadabra', '^a.*a$') returns true

Signature:

xp20:matches(intputString, regexPattern)

Arguments:

  • inputString - The input string

  • regexPattern - The regular expression pattern

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.85 max-value-among-nodeset

This function returns the maximum value from a list of input numbers, the node-set inputNumber.

The node-set inputNumber can be a collection of text nodes or elements containing text nodes.

In the case of elements, the first text node's value is considered.

Signature:

orcl:max-value-among-nodeset(inputNumber as node-set)

Arguments:

  • inputNumber - The node-set of input numbers

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.86 mergeChildNodes

Merges the child nodes of the incoming elements and returns the merged element.

Signature:

ora:mergeChildNodes(DOMElement element1,DOMElement element2)

Arguments:

  • variableName - The source variable for the data

  • propertyName - The QName of the property

Property IDs:

  • deprecated

    Use the bpelx extension activities to merge nodes. The extension activities are demonstrated in the sample.

    Oracle_Home\integration\orabpel\samples\tutorials\126.DataAggregator.

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.87 min-value-among-nodeset

This function returns the minimum value from a list of input numbers, the node-set inputNumbers.The node-set can be a collection of text nodes or elements containing text nodes.In the case of elements, the first text node's value is considered.

Signature:

orcl:min-value-among-nodeset(inputNumbers as node-set)

Arguments:

  • inputNumber - The node-set of input numbers

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.88 minutes-from-dateTime

This function returns the minute from dateTime. The default minute is 0.

Signature:

xp20:minutes-from-dateTime(dateTime)

Arguments:

  • dateTime - The dateTime

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.89 month-from-dateTime

This function returns the month from dateTime. The default month is 1 (January).

Signature:

xp20:month-from-dateTime(dateTime)

Arguments:

  • dateTime - The dateTime to be formatted

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.90 parseEscapedXML

This function parses a string to DOM.

Signature:

ora:parseEscapedXML(contentString)

Arguments:

  • contentString - The string that this function parses to a DOM.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.91 processXSLT

This function returns the result of XSLT transformation.

Signature:

ora:processXSLT('template','input','properties'?)

Arguments:

  • template - XSLT template

  • input - The input data to be transformed

  • properties - The properties as defined in the bpel.xml file

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.92 processXSLT

This function returns results of the XSLT transformation by using the Oracle XDK XSLT processor.

Signature:

xdk:processXSLT('template','input','properties'?)

Arguments:

  • template - XSLT template

  • input - The input data to be transformed

  • properties - The properties as defined in the bpel.xml file

Property IDs:

  • namespace-uri

    • Value: http://schemas.oracle.com/bpel/extension/xpath/function/xdk

  • namespace-prefix

    • Value: xdk

G.1.93 processXSQL

This function returns the result of the XSQL request.

Signature:

ora:processXSQL('template','input','properties'?)

Arguments:

  • template - XSLT template

  • input - The input data to be transformed

  • properties - The properties as defined in the bpel.xml file

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.94 query-database

This function returns a node-set by executing the SQL query against the specified database.

Signature:

orcl:query-database(sqlquery as string, rowset as boolean, row as boolean, datasource as string)

Arguments:

  • sqlquery - The SQL query to perform

  • rowset - Indicates if the rows should be enclosed in a <rowset> element

  • row - Indicates if each row should be enclosed in a <row> element

  • datasource - Either a JDBC connect string (jdbc:oracle:thin:username/password@host:port:sid) or a JNDI name for the database

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.95 readFile

This function returns the content of the file.

Signature:

ora:readFile('fileName','nxsdTemplate'?,'nxsdRoot'?)

Arguments:

  • fileName - The name of the file. This argument can also be an HTTP URL.

  • nxsdTemplate - The NXSD template for the output

  • nxsdRoot -The NXSD root

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.96 right-trim

This function returns the value inputString after removing all the trailing white spaces.

Example: orcl:right-trim(' account ') returns ' account'

Signature:

orcl:right-trim(inputString as string)

Arguments:

  • inputString - The input string to be right-trimmed

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.97 search

This function returns a list of LDAP entries.

Signature:

ldap:search('properties','filter','scope'?)

Arguments:

  • properties - The properties name as defined in the bpel.xml file

  • filter - The filter for the entries

  • scope -The scope of the search

Property IDs:

  • namespace-uri

    • Value: http://schemas.oracle.com/xpath/extension/ldap

  • namespace-prefix

    • Value: ldap

G.1.98 seconds-from-dateTime

This function returns the second from dateTime. The default second is 0.

Signature:

xp20:seconds-from-dateTime(dateTime as string)

Arguments:

  • dateTime - The dateTime as a string

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.99 sequence-next-val

Return the next value of an Oracle sequence.

The next value is obtained by executing

SELECT sequence.nextval FROM dual

against data source that can be either a JDBC connect string (jdbc:oracle:thin:username/password@host:port:sid) or a data source JNDI identifier. Only Oracle Thin Driver is supported if a JDBC connect string is used.

Example: orcl:sequence-next-val('employee_id_sequence','jdbc:oracle:thin:scott/tiger@localhost:1521:ORCL')

Signature:

orcl:sequence-next-val(sequence as string, datasource as string)

Arguments:

  • sequence

  • datasource

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.100 setNodeValue

This function sets the variable's node value.

Signature:

ora:setNodeValue('variableName', 'part', 'query', 'newNodeValue')

Arguments:

  • variableName - The source variable for the data

  • part - The name of the part or message type

  • query - The XPath expression used to search out the correct node

  • newNodeValue - The new value of the node

Property IDs:

  • deprecated

    Use the bpelx extension activities to manipulate an XML document. The extension activities are demonstrated in sample

    Oracle_Home\integration\orabpel\samples\tutorials\126.DataAggregator.

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.101 square-root

This function returns the square root of inputNumber.

Example: orcl:square-root(25) returns 5

Signature:

orcl:square-root(inputNumber as number)

Arguments:

  • inputNumber - The input number for which the function calculates the square root

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc

  • namespace-prefix: orcl

G.1.102 subtract-dayTimeDuration-from-dateTime

This function returns a new dateTime value after subtracting duration from dateTime.

If the duration value is negative, then the resultant dateTime value follows input-dateTime value.

Signature:

xp20:subtract-dayTimeDuration-from-dateTime(dateTime as string, duration as string)

Arguments:

  • dateTime as string - The dateTime from which the function subtracts the duration, in string format.

  • duration as string - The duration to subtract to the dateTime, or add if the duration is negative, in string format.

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.103 timezone-from-dateTime

This function returns the timezone from dateTime. The default timezone is GMT+00:00.

Signature:

xp20:timezone-from-dateTime(dateTime as string)

Arguments:

  • dateTime as string - The dateTime for which this function returns a time zone

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.104 translateFromNative

Translates the input stream to an XML file.

Signature:

ora:translateFromNative('string','nxsdTemplate'?,'nxsdRoot'?)

Arguments:

  • string - Data to be converted into an XML file.

  • nxsdTemplate - The XSD file used to define how the translation is performed.

  • nxsdRoot - Root element defined in the XSD file.

Property IDs:

  • namespace-uri: http://schemas.oracle.com/xpath/extension

  • namespace-prefix: ora

G.1.105 translateToNative

Translates the XML to the native data.

Signature:

ora:translateFromNative('string','nxsdTemplate'?,'nxsdRoot'?)

Arguments:

  • string - XML file to be converted into a string.

  • nxsdTemplate - The XSD file used to define how the translation is performed.

  • nxsdRoot -Root element defined in the XSD file.

Property IDs:

  • namespace-uri

    • Value: http://schemas.oracle.com/xpath/extension

  • namespace-prefix

    • Value: ora

G.1.106 upper-case

This function returns the value of inputString after translating every character to its upper-case correspondent.

Example: xp20:upper-case('abCd0') returns 'ABCD0'

Signature:

xp20:upper-case(inputString as string)

Arguments:

  • inputString - The input string

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.1.107 year-from-dateTime

This function returns the year from dateTime.

Signature:

xp20:year-from-dateTime(dateTime as string)

Arguments:

  • dateTime - The dateTime

Property IDs:

  • namespace-uri: http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20

  • namespace-prefix: xp20

G.2 Summary

This appendix lists the XPath extension functions, along with their descriptions, signature, argument descriptions, and property ID information.