$pullAll
On this page
Definition
-
$pullAll
-
The
$pullAll
operator removes all instances of the specified values from an existing array. Unlike the$pull
operator that removes elements by specifying a query,$pullAll
removes elements that match the listed values.The
$pullAll
operator has the form:To specify a
<field>
in an embedded document or in an array, use dot notation.
Behavior
If a <value>
to remove is a document or an array, $pullAll
removes only the elements in the array that match the specified <value>
exactly, including order.