The SPLITLIST function splits the specified list into sublists (or batches), each of which contains the specified number of records. It then returns the result as a new Record list value that consists of the batches.


SPLITLIST (list, number)


list: Record list

The valid path of a data source of the Record list data type.

number: Integer

The maximum number of records per batch.

Return values

Record list

The resulting list of records.

Usage notes

The list of batches that is returned contains the following elements:

  • Value: List

    The list of records that belong to the current batch.

  • BatchNumber: Integer

    The number of the current batch in the returned list.


In the following illustration, a Lines data source is created as a record list that has three records. This list is divided into batches, each of which contains up to two records.

Data source that is divided into batches

The following illustration shows the designed format layout. In this format layout, bindings to the Lines data source are created to generate output in XML format. This output presents individual nodes for each batch and the records in it.

Format layout that has bindings to a data source

The following illustration shows the result when the designed format is run.

Result of running the format

Additional resources

List functions