Enum SearchNumberRepresentation
- Namespace
- MongoDB.EntityFrameworkCore.Metadata.Search
- Assembly
- MongoDB.EntityFrameworkCore.dll
Numeric storage representation for MongoDB search number fields.
public enum SearchNumberRepresentation
Fields
Int64 = 064-bit signed integer (
int64): exact integer values with full 64-bit range. Use when you require precise integer comparisons and ordering without floating-point rounding.Double = 164-bit IEEE 754 double (
double): floating-point values that support fractions and a wide dynamic range. Useful for measurements and decimals, with the usual floating-point precision trade-offs.
Remarks
Atlas Search indexes numeric values using either a 64-bit signed integer or a 64-bit IEEE 754 double-precision floating-point format. Choose the representation that matches your data to balance precision and range for filtering, sorting, and aggregations. For background on Atlas Search numeric field mappings, see https://www.mongodb.com/docs/atlas/atlas-search/field-types/number/.