Skip to main content
Skip table of contents

x4db:/ URL Protocol

The x4db:/ URL protocol allows you to access during the process runtime a document in any X4 Repository user folder. It can be used in XSL mappings and adapter parameters to reference any repository file. In XSL mappings, XML documents can be included using the document() function.

URL Structure

An x4db:/ URL must follow the pattern:

HTML/XML
x4db:/<User repository>/<File path>

Components of an x4db:/ URL are:

  • x4db:/: Protocoll declaration; within the X4 BPMS valid during runtime of the currently executed process.

  • User repository: Repository user folder ( "User collection" ), e.g. 1 or X4P

  • File path: Path of the file in the user repository folder; folders are separated by slashes (/).

Please note:

  • For security reasons, use the x4db:/ URL protocol carefully, and only to read a document from another X4 Repository user folder. Else use xstore://, see (7.4.0-en) xstore:// URL Protocol

  • An XSL mapping using this URL protocol cannot be executed in the transformation preview of the Mapping Editor.

Example

In the following example, an XSL mapping retrieves an XML document from the X4 Repository user folder 101 using the document() function and stores it in an XSL variable externalFile. Any XPath expression can be used to select its nodes.

HTML/XML
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
   <xsl:output encoding="UTF-8" method="xml" version="1.0"/>
   <xsl:template match="/">
      <result>
         <xsl:variable select="document('x4db:/101/Project/Folder/Data.xml')" name="externalFile"/>
         <xsl:value-of select="$externalFile/child::ElemName"/>
      </result>
   </xsl:template>
</xsl:stylesheet>

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.