Last active
December 10, 2015 15:59
-
-
Save reggi/4458046 to your computer and use it in GitHub Desktop.
Mongo Update $or
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
db.orders.update( | |
{ | |
$or: [ | |
{"line_items.sku":"TEA-BLCK"}, | |
{"line_items.sku":"TEA-GREEN"}, | |
{"line_items.sku":"TEA-CHAI"} | |
] | |
}, | |
{ | |
$set: { | |
"something":{} | |
} | |
}, | |
{ | |
"multi":true | |
} | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment