diff --git a/source/reference/operator/query/where.txt b/source/reference/operator/query/where.txt index 7e995748e02..440111ec4bd 100644 --- a/source/reference/operator/query/where.txt +++ b/source/reference/operator/query/where.txt @@ -36,8 +36,7 @@ nested document, for instance, in an :query:`$elemMatch` query. Considerations ~~~~~~~~~~~~~~ -- Do not write to the database within the :query:`$where` - JavaScript function. +- Do not use global variables. - :query:`$where` evaluates JavaScript and cannot take advantage of indexes. Therefore, query performance improves