Skip to content

Wk3 Mongo Class Notes#19

Open
charlottewest wants to merge 1 commit intopce-uw-jscript400:masterfrom
charlottewest:master
Open

Wk3 Mongo Class Notes#19
charlottewest wants to merge 1 commit intopce-uw-jscript400:masterfrom
charlottewest:master

Conversation

@charlottewest
Copy link

No description provided.

* **Your Answer:**
database - top level data storage, holds collections and documents

collection - same as a table, may have many of these stored within a database
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right. In addition, collections store multiple documents.


* **Your Answer:**

Defines a unique id to represent each document
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not quite right. If you include the above in your code, it will require you to send an ObjectID when creating a new record.

* **Question:** What are the arguments for `Model.updateOne()`?

* **Your Answer:**
filter - The keys and corresponding values for each field of the document you'd like to update
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like we're missing the rest of this...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants