my question is as follows, in the NoSQL family, when we store the values.
Should the value stored be totally ready for the application in order to use it directly? or is it also ok to store the value in a way that may need some extra treatment in order to be used for the application?.
Quick example, if we want to calculate an average value from the whole day, would it make more sense to always keep the average value stored or would it be better to maybe have some keys, representing each individual value and then, making the application calculate the average?.
The first approach would be faster once we get the value, but will be restricted to get the value from the whole day, while the second approach will be slower (we need to calculate the average each time) but we could also calculate average values per hour...
For me this is a question of philosophy, again, should be the data in the NoSQL database totally ready to be used, or makes sense to have the data in a way that needs some extra process.
Thanks a lot :)