- 作业标题: APAN 5400 - Assignment 4 NoSQL Database - MongoDB
- 课程名称:C-lumbia University APAN 5400 Managing Data
- 完成周期:2天
In this assignment, you will create a MongoDB database, populate it using a collection of JSON documents, and run some basic retrieval queries on your database. Most importantly, you will gain experience in modeling data in document-oriented way, as done in a MongoDB database.
Objectives
This assignment supports the following objectives:
- Use effective database design practices
- Create and interact with a MongoDB database
Details
Step 1 - Download and install MongoDB
Refer to our MongoDB Installation Guide
You can install MongoDB on Windows directly using these instructions: https://docs.mongodb.com/manual/tutorial/install-mongodb-on-windows/#install-mongodb-community-edition (Links to an external site.)
You can install MongoDB on a Macbook directly using these instructions: https://docs.mongodb.com/manual/tutorial/install-mongodb-on-os-x/ (Links to an external site.)
Step 2 - Create a MongoDB database
Refer to MongoDB Basics Tutorial (Links to an external site.) and PyMongo Tutorial (Links to an external site.):
Using PyMongo (from your Jupyter Notebook) or the MongoDD through the terminal, create a MongoDB database collection and insert the following records (as JSON documents):
Step 3 - Build and run queries in PyMongo or direct MongoDB using the terminal against the collection to answer the following questions:
- Which company is the largest by number of employees and by annual revenue?
- Which one is the youngest American multinational technology company? (hint: search description)
- Which company is headquartered in Hangzhou, China?
- Which company manufactures cars? (hint: search description)
- Which company is the world’s largest smartphone manufacturer? (hint: search description)
Assessment
Please see the attached rubric for detailed assessment criteria.
Submission
In one word document, one pdf, or one Python Jupyter Notebook (.ipynb and .html):
- Your database design, which should include the collections and what sorts keys and values you have created.
- The code to create the database (Namespace)
- The code to populate the database
- The code for the queries
- Screenshots Verifying that your Code was properly executed
To complete your submission,
- Click the blue Submit Assignment button at the top of this page.
- Click the Choose File button, and locate your submission.
- Feel free to include a comment with your submission.
- Finally, click the blue Submit Assignment button.
。。。