From 33fc27e59a5bbb4e2d3f96e91640d33bce4f3efa Mon Sep 17 00:00:00 2001 From: alisonjhuh Date: Tue, 8 Jun 2021 14:20:10 -0400 Subject: [PATCH] DOCSP-14244 add reference to db.collection.validate() --- source/core/schema-validation.txt | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/source/core/schema-validation.txt b/source/core/schema-validation.txt index 4657fbcff84..faa2350b2c8 100644 --- a/source/core/schema-validation.txt +++ b/source/core/schema-validation.txt @@ -137,6 +137,11 @@ Validation occurs during updates and inserts. When you add validation to a collection, existing documents do not undergo validation checks until modification. +To perform validation checks on existing documents, use the +:dbcommand:`validate` command or the :method:`db.collection.validate()` +shell helper. + + Existing Documents ~~~~~~~~~~~~~~~~~~ @@ -288,4 +293,5 @@ Additional Information ---------------------- .. seealso:: :dbcommand:`collMod`, :method:`db.createCollection()`, - :method:`db.getCollectionInfos()`. + :method:`db.getCollectionInfos()`, + :method:`db.collection.validate()`.