You are on page 1of 2

QUESTION PAPER

Name of the Examination: CAT 2

School SCOPE
Course Code cs3009 Course Title NoSQL Databases
Semester Date of exam
Faculty Name
Slot Dr. Karthika Natarajan & 70279
& ID
Duration 110 mins Total Marks 50

Type your questions here

Q1. Mr. Sanjeev wants to development a database using MongoDB for his plant nursery which
has details such as Plant_id, Plant_name, Supplier_id, Payment-method, Number_of_
plants_ordered and Date & Year of Purchase. (15)
For the following occurrences, write an answer.
1. Very first he planned to insert every plant details individually.
2. Later he decided to add all the plant details at a time upon the database.
3. While adding the details, he found out that there is an error, so he has decided to update
the Payment_method from COD to Card payment to all the plants purchased.
4. Now he decided to update the database with Customer_id.
5. He wants to delete a plant detail which matches with Plant_name “ MANGO”.
Q2. Mr. Baskar intends to develop an app using MongoDB which deals with weather report. The
details are City, District, State, Temperature, Wind_speed, pressure, humidity, Direction_of
Wind, Rainfall_range, year, and month (10)
1. He wants to find the cities which is hitting max temperature among all.
2. He wishes to note down the number of states which exceeds temperature level is 25.
3. He wants to know whether any state has low level rainfall that is between 250
millimeters.
4. He decides to list down all states which has above 500 millimeters rainfall.
5. He wants to calculate the average rainfall of a year 2021.
Q3. Write commands using REDIS datastore (15)

1. Write a command for creating a key “MOVIES”


2. Using List data structure for the same key MOVIES, add the following 5 films in the
front end of the list. i.e., Avatar, The father, King Kong, the parasite, superman.
3. Insert a document called” No time No die” before Python.
4. Once inserted, list out all the values of the “MOVIES”.
5. Pop the document KINGKONG from MOVIES and insert the same in another list called
“TOPMOVIESOFTHEWORLD”
Q4. Write commands using REDIS datastore (10)

1. Create a key as “Mv1”


2. Insert the members like Avatar, The father, King Kong, the parasite, superman in sorted
order.
3. Count the member of values between range 1 to 3.
4. Create another set in an ordered manner with members like Harrypotter, homealone,
coco, iceage. Union both the sets together and store it in another set.
5. Check the new set whether it has coco as its member.

QP Mapping

Module CO PO PEO PSO


Q. No. Marks
Number Mapped Mapped Mapped Mapped
Q1 3 CO1, CO2, PO1, PO2, PEO1, PSO1, PSO2 15
CO3 PO3, PO5, PEO2,
PO9 PEO3, PEO4
Q2 3 CO1, CO2, PO1, PO2, PEO1, PSO1, PSO2 10
CO3 PO3, PO5, PEO2,
PO9 PEO3, PEO4
Q3 4 CO1, CO2, PO1, PO2, PEO1, PSO1, PSO2 15
CO3 PO3, PO5, PEO2,
PO9 PEO3, PEO4
Q4 4 CO1, CO2, PO1, PO2, PEO1, PSO1, PSO2 10
CO3 PO3, PO5, PEO2,
PO9 PEO3, PEO4

You might also like