Custom functions

Custom functions assist you with particular use cases. The custom functions are in the TRIRIGA category of the BIRT Expression Builder.

The following table describes the custom functions:
Table 1. Custom functions
Name Description Inputs Return
formatNumber Uses IBM® TRIRIGA® to format a number. number - BigDecimal: Number value to format

unitOfMeasure - TriResultUom: Unit of Measure that is used for formatting the number. Can use a NULL value if no UOM is available, but must use the encodedBoFieldName input.

encodedBoFieldName - String [optional]: BO field from which this number came. Use where applicable, because a field metadata can affect number formatting.

String: the formatted number.
formatDate Uses IBM TRIRIGA to format a date. Uses the format that is specified in your user profile record. date - java.util.Date: Date to format String: the formatted date.
formatDateTime Uses IBM TRIRIGA to format a datetime. Uses the format that is specified in your user profile record. dateTime - java.util.Date: DateTime to format String: the formatted DateTime.
getProjectIdFor-Record Returns the record ID of the project that the record is in. Returns NULL if the record is not in a project. ID of the record. Typically the system__recordId value of an IBM TRIRIGA result record. Decimal: the ID of the project that the record is in.
getRootOrganiza-tionId Returns the record ID of the root organization. N/A Decimal: the ID of IBM TRIRIGA's root organization record.
getCompany-LogoId Returns the ID of the company logo document. N/A Decimal: the ID of the company logo document.
getProjectLogoId Returns the ID of the current project's logo document. N/A Decimal: the ID of current project's logo document.
getUserId Returns the ID of the currently signed-in user. N/A Decimal: the ID of the current user.
getProjectId Returns the ID of the current project. Returns NULL if the user is not currently in a project. N/A Decimal: the ID of current project.