Table of Contents

Search

  1. Preface
  2. XML Concepts
  3. Using XML with PowerCenter
  4. Working with XML Sources
  5. Using the XML Editor
  6. Working with XML Targets
  7. XML Source Qualifier Transformation
  8. Midstream XML Transformations
  9. Appendix A: XML Datatype Reference
  10. Appendix B: XPath Query Functions Reference

XML Guide

XML Guide

number

number

Converts a string or Boolean value to a number.

Syntax

number (
value
)
The following table describes the argument for this function:
Argument
Description
value
Use a Boolean or string value.

Return Value

The function returns a number for the following data:
  • A string converts to a number if the string contains a numeric character. The string can contain white space and include a minus sign followed by a number. White space can follow the number in the string. Any other string is Not a Number (NaN).
  • A Boolean TRUE converts to 1. A Boolean FALSE converts to 0.
If a value passed as an argument to the function is not a number, the function returns Not A Number (NaN).

Example

The following expression converts payment to a number:
number ( PAYMENT )
The following table contains example arguments and return values:
PAYMENT
RETURN VALUE
‘850.00’
850.00
TRUE
1
FALSE
0
AB
NaN

0 COMMENTS

We’d like to hear from you!