How can I store decimals in MongoDB using the standard C# driver? It seems that all decimals are stored inside the database as strings.
I solved it like Erik Kindling, by annotating the object like this:
[BsonRepresentation(BsonType.Decimal128)]
public decimal Price {get; set;}
However, it is important that you re-populate your mongodb collection otherwise the string value will be preserved. The field value will be in this format once inserted properly:
"Price" : NumberDecimal("99")