Wednesday 12 October 2022

Hive: round: round the double to n integer places

Signature

round( double value [, int n] )

hive> SELECT round(10.09872);
OK
_c0
10.0
Time taken: 0.051 seconds, Fetched: 1 row(s)
hive> SELECT round(10.09872, 3);
OK
_c0
10.099
Time taken: 0.043 seconds, Fetched: 1 row(s)
hive> SELECT round(10.09872, 1);
OK
_c0
10.1
Time taken: 0.037 seconds, Fetched: 1 row(s)

 

 

 

Previous                                                    Next                                                    Home

No comments:

Post a Comment