$pullAlloperator removes all instances of the specified values from an existing array. Unlike the
$pulloperator that removes elements by specifying a query,
$pullAllremoves elements that match the listed values.
$pullAlloperator has the form:
To specify a
<field>in an embedded document or in an array, use dot notation.
<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.
Given the following document in the
The following operation removes all instances of the value
5 from the
After the operation, the updated document has all instances of
5 removed from the