I was wondering if when we use project to edit fields, are they edited as a “view” just in the query or are they edited permanently in the database ?
This part is correct:
The database is not modified.
How about add fields ? Does it add in the database ?
Nope. To write out of the pipeline to a database see
You can also export the result of a query straight from
mongodump, which is great.