IBM Cognos User Manual page 384

Version 10.1.1
Table of Contents

Advertisement

Example
string-to-integer (' 101 tents')
Returns the result: 101
Substring
Returns a substring from a string. The first character in the string is at position
one.
Syntax
substring (string_exp, integer_exp1, integer_exp2)
where:
v string_exp is the string from which you want to extract a substring
v integer_exp1 is the position of the first character in the substring
v integer_exp2 is the desired length of the substring
Example
substring ('abdefg', 3, 2)
Returns the result: de
Trim-Leading
Returns a string with leading spaces removed. For example, if you merge two data
items with leading spaces, use trim-leading to eliminate the spaces between them.
Syntax
trim-leading (string_exp)
Example
trim-leading (' ABC')
Returns the result: ABC
Trim-Trailing
Returns a string with trailing spaces removed. For example, if you merge two data
items in an expression and the data items have trailing spaces, the spaces between
the data items can be eliminated using the trim-trailing function.
Syntax
trim-trailing (string_exp)
Example
trim-trailing ('XYZ ')
Returns the result: XYZ
Upper
Converts lowercase characters to uppercase.
Syntax
upper (string_exp)
370
IBM Cognos Transformer Version 10.1.1: User Guide

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents