How to return float value with zero fraction in MongoDB? -


i trying retrieve float values mongodb 0 fraction. doesn't work expect to.

i.e. inserted doc:
db.collection.insert({ _id: 1, floatval: 10.0 })

while retrieving gives as:

{         "_id": 1,         "floatval": 10     }     

whereas want result as:

{         "_id": 1,         "floatval" : 10.0     } 


Comments

Popular posts from this blog

matlab - error with cyclic autocorrelation function -

django - (fields.E300) Field defines a relation with model 'AbstractEmailUser' which is either not installed, or is abstract -

c# - What is a good .Net RefEdit control to use with ExcelDna? -