apoc.number.exact.toInteger

Function

apoc.number.exact.toInteger(string STRING, precision INTEGER, roundingMode STRING) - returns the INTEGER of the given large number (using Java BigDecimal).

Signature

apoc.number.exact.toInteger(stringA :: STRING, precision = 0 :: INTEGER, roundingMode = HALF_UP :: STRING) :: INTEGER

Input parameters

Name Type Default

stringA

STRING

null

precision

INTEGER

0

roundingMode

STRING

HALF_UP

Usage Examples

RETURN apoc.number.exact.toInteger('504238974', 5, 'HALF_DOWN') as output;
Table 1. Results
output

504238974