Altova FlowForce Server 2024 Advanced Edition

Returns a substring from the specified string, beginning with start character position, up to the end character position. The start and end indexes are zero-based.

 

If not set, end is the length of the supplied string.

 

The end argument can also be a negative integer. A negative value -n means "trim the last n characters from the string".

 

Signature

substring(string:sting, start:number, end:number) -> string

 

Parameters

Name

Type

Description

string

sting

The input string.

start

number

The zero-based starting index.

end

number

The zero-based ending index.

 

Examples

The following expression will return "Force":

 

substring('FlowForce',4)

 

The following expression will return "t":

 

substring('Altova',2,3)

 

The following expression will return "ltov":

 

substring('Altova',1,-1)

 

© 2017-2023 Altova GmbH