મૂળભૂત સિંગલ-ફીલ્ડ ઇન્ડેક્સ ઉપરાંત, MongoDB અત્યાધુનિક ઇન્ડેક્સિંગ વ્યૂહરચનાઓ આપે છે — કમ્પાઉન્ડ ઇન્ડેક્સ ઓર્ડરિંગ (ESR rule), covered queries, partial/sparse indexes, TTL indexes, અને વધુ — જે ક્વેરી પરફরમન્સને નાટકીય રીતે અસર કરે છે. તેમને આવતા શીખવું MongoDB ને સ્કેલ પર ઑપ્ટિમાઇઝ કરવાની કી છે.
કમ્પાઉન્ડ ઇન્ડેક્સ માટે ESR rule
For a compound index supporting a query with Equality, Sort, and Range conditions,
order the fields: EQUALITY → SORT → RANGE (the ESR rule).
