Is there a way to disable automatic type conversion in mongodb?

时间:2016-04-07 10:52:07

标签: java mongodb

I tried to insert a json
{"Name" : "abc", "Age" : 28}.

When I retrieve back the doc using Java, I got
FindIterable<Doc> {"Name:" "abc", "Age" : 28.0}.

Is there a way to disable this type of conversion from int to float in mongodb, other than inputting as NumberInt()?

0 个答案:

没有答案