We have an application that stores some configuration values from C / C ++ to MongoDB and has the ability to restart (i.e., it starts for a while, someone interrupts the application, changes the configuration, then starts the application again, and it goes up there, where is it left). This works like a charm for logical and string configurations.
But then we have integers (in our current implementation of C / C ++ - 32-bit values). And when I use the MongoDB console to change these integer values, Mongo always saves them back as Number (which is doulble in the C / C ++ implementation). We will change the application to accept double values, where it expects integers, but I was wondering if there is a way to force Mongo to store integers from its JavaScript console.
Any suggestions?
source
share