Programming Homework Help
SNHU Pymongo Import Mongo Client Pyhton Project
Hello Partner,
I need help trying to put the pieces to the puzzle, which I mean by working with Juypter Notebook in Python code. Instructions are given as followed:
Develop a CRUD class that, when instantiated, provides the following functionality:
- A Create method that inserts a document into a specified MongoDB database and collection
- Input -> argument to function will be a set of key/value pairs in the data type acceptable to the MongoDB driver insert API call.
- Return -> “True” if successful insert, else “False”.
- A Read method that queries for document(s) from a specified MongoDB database and specified collection
- Input -> arguments to function should be the key/value lookup pair to use with the MongoDB driver find API call.
- Return -> result in cursor if successful, else MongoDB returned error message.
- An Update method that queries for and changes document(s) from a specified MongoDB database and specified collection
- Input -> arguments to function should be the key/value lookup pair to use with the MongoDB driver find API call. Last argument to function will be a set of key/value pairs in the data type acceptable to the MongoDB driver insert API call.
- Return -> result in JSON format if successful, else MongoDB returned error message.
- A Delete method that queries for and removes document(s) from a specified MongoDB database and specified collection
- Input -> arguments to function should be the key/value lookup pair to use with the MongoDB driver find API call.
- Return -> result in JSON format if successful, else MongoDB returned error message.
As you develop your code, be sure to use industry standard best practices such as proper naming conventions, exception handling, and in-line comments. This will ensure that your code is easy to read and reusable for future projects. Refer to the Python Style Guide, located in the Supporting Materials section, to help with these industry standard best practices.
NOW, I need help on trying to TEST the IPYNB FILE which is attached with the PY FILE in this question. Attached are both, the PY file and the IPYNB file, where I am trying to figure out how to make both collaborate and connect with each other? Please Help which I have been working on this project for days and have not been able to figure what is wrong. Thank you in advance!