Altova MapForce 2023 Basic Edition

Splits the input string into a sequence of strings. The size of each resulting string is determined by the length parameter.

mf-func-tokenize-by-length

 

Languages

Built-in, C++, C#, Java, XQuery, XSLT 2.0, XSLT 3.0.

 

Parameters

Name

Description

input

The input string.

length

Determines the length of each string in the generated sequence of strings.

 

Example

If the input string is ABCDEF and the length is 2, then the function returns a sequence of three strings: AB, CD, and EF.

 

mf-func-tokenize-by-length-example

 

In the mock-up mapping illustrated above, the function's result is a sequence of strings. According to the general mapping rules, for each item in the source sequence, a new item is created in the target component. Consequently, the mapping output looks as follows:

 

<items>
  <item>AB</item>
  <item>CD</item>
  <item>EF</item>
</items>

© 2017-2023 Altova GmbH