Set A
Set A
School Code:
2) Write a program in Python that defines and calls the following user defined functions:
(i) Add_Book( ): Take the details of the books and adds them t a csv file ‘Book.csv’. Each record consists of a
list with field elements as book_ID, B_name and pub to store book ID, book name and publisher respectively.
(ii) Search_Book( ): Takes publisher name as input and display the records of all books published by them.
B. Write the outputs of the SQL queries (i) to (iv) based on the relations COMPUTER and SALES given below:
Table: COMPUTER Table: SALES
(I) Display the minimum and maximum price from the table COMPUTER
(II) Display the count of each company
(III) Display the product name, type and quantity sold for 2nd quarter
(IV) Display the quantity of all printer sold