Class 11 IP Sample Paper Term 2 Set 1

Class 11 IP Sample Paper Term 2 Set 1

Term-2 Examination 2021-22

Class: 11   

Subject: Informatics Practices

Subject Code: 065

Maximum Marks: 35/ Time: 2 hours

 

General Instructions

♦ The question paper is divided into 3 sections – A, B and C

♦ Section A, consists of 7 questions (1-7). Each question carries 2 marks.

♦ Section B, consists of 3 questions (8-10). Each question carries 3 marks.

♦ Section C, consists of 3 questions ( 11-13). Each question carries 4 marks.

♦ Internal choices have been given for question numbers – 1, 8 and 13.

 

Section –A

Each question carries 2 marks

1. Write short notes on big data and its characteristics.

Ans: Big data:  –   Big data holds rich information and knowledge which can be of high business value. Five characteristics of big data are: Volume, Velocity, Variety, Veracity, and Value.

 

Or

Write Short notes on Natural Language Processing..        

Ans: NLP:  Natural language processing (NLP) facilitates communicating with intelligent systems using a natural language.

 

 

2. Differentiate between char (n) and varchar (n) data types with respect to databases.

Ans:

char(n):· stores a fixed length string between 1 and 255 characters · if the value is of smaller length, adds blank spaces · some space is wasted

varchar(n) :· stores a variable length string · no blanks are added even if value is of smaller length · no wastage of space.

 

 

 

3. Write SQL Command to perform the following – 

Table :  student

ID Name Class fee
101 Sunil 10th 2500
102 Sandesh 10th NULL
103 Rahul 11th 3100

 

 

a) Delete last record from the table.

Ans: delete from student where ID=103;

 

 

b) Add / insert new record in the table { 104 , ‘Chandresh’,’11th ‘ , 3150}

Ans: insert into student values (104 , ‘Chandresh’,’11th ‘ , 3150);

 

 

4. Mr. Ramesh Created a table “Hotel” and inserted two records as given below.

            On verification of records He found that he entered the wrong phone number of Ramesh. Now help him to correct the phone number by writing the sql command.

The Correct Phone Number is 9406688990. 

Table :Hotel

Id Custname Phno Dateof_reporting City
101 Ashok 9823652653 2021-08-08 Pune
102 Ramesh 9452363636 2021-07-09 Mumbai

Ans: update hotel set phno=9406688990 where id=102;

 

 

5. MS Sunita created a Database ,inside database she created two tables ( Tb1 , Tb2). Later on she find that table Tb2 is not required for her database .Now she wants to delete the table. Help her by writing the sql command to delete the table from the database. 

Ans: Drop Table Tb2;   or DROP TABLE IF EXISTST b2 ;

 

 

6. Write the name of SQL command for the following.

a) To list all databases

Ans: show databases ;

 

 

b)to show description of a table “TB2”

Ans: desc TB2;

 

 

7. Mr. Ben appeared for an interview to get job. Interviewer asked the following two questions based on MY SQL.

 

a) The key which is has unique and not null value is known as …?

Ans: primary key

 

 

b) A table can contains how many primary keys?

Ans: Only 1

 

Section –B

Each question carries 3 marks

8. Write SQL commands for the following – 

Table :  student

ID Name Class fee
101 Sunil 10th 2500
102 Sandesh 10th NULL
103 Rahul 11th 3100

           

Consider the above table student {ID,Name,Class, Fee }

 

a) Write SQL Command to delete column fee.

Ans: alter table student drop fee;

 

 

b) write SQL command to apply primary key constraint on column ID.

Ans: alter table student add primary key(ID);

 

 

c) Suggest name of column on which unique constraint can be applied.

Ans: ID

 

OR

a) What is the degree and cardinality of table student.

Ans: degree : 04 and cardinality : 03

 

 

b) write SQL Command to add a column city with data type Varchar(25)

Ans: alter table student add city varchar(25);

 

 

c) write SQL Command to delete primary key.

Ans: alter table student drop primary key;

 

 

9. Write the SQL Command to perform the following task.                      

a) Create a database named “MYDB” and use it.

 

Ans: create database MYDB

use MYDB

 

 

b) Write sql command to list all tables of MYDB database.

Ans: show tables;

 

 

c) Write sql command to delete database MYDB.

Ans: drop database MYDB

 

10. Explain cloud computing and its services.

Ans: Cloud Computing :Cloud computing allows resources located at remote locations to be made available to anyone anywhere. Cloud services can be Infrastructure as a Service (IaaS), Platform as a Service (PaaS), and Software as a Service (SaaS). 

Section –C

Each question carries 4 marks

11. Consider the following table and write the SQL Queries the following – 

ID Sname Dateof_Join City Fee
101 Arjun 2015-08-07 Pune 25000
102 Sanjana 2018-07-04 Pune NULL
103 Sunil 2018-07-14 Mumbai 30000
105 Swati 2016-04-15 Mumbai 45000

 

a) To display name and date of joining of those student who belongs to Pune.

Ans: select sname ,Dateof_join from student where city=”pune”;

 

 

b) To display name of those students who have not paid the fee.

Ans: select sname from student where fee is NULL;

 

 

c) To display details of those student who paid fee more than 30000

Ans: Select * from student where fee>30000;

 

 

d) To display the records in descending order of Date of joining.

Ans: select * from student order by dateof_joindesc;

 

12. Consider the following table Employee and write the output of SQL queries for (a to d) or  (e to f) . 

Table  : EMPLOYEE

EmpNo Ename Salary Bonus city
101 Aaliya 10000 234 Pune
102 Kritika 60000 123 Mumbai
103 Shabbir 45000 566 Pune
104 Gurpreet 19000 565 Delhi
105 Joseph 34000 875 Delhi

                                                                                                           

a) Select * from employee where city=’pune’ and bonus>350;

Ans:

EmpNo Ename Salary Bonus city
103 Shabbir 45000 566 Pune

 

 

b) selectename , salary+bonusas”total_pay” from employee order by Enameasc;

Ans:

Ename Total_Pay
Aaliya 10234
Kritika 60123
Shabbir 45566
Gurpreet 19565
Joseph 34875

 

 

c) select * from employee where name like ‘ – %a’ ;

Ans:

EmpNo Ename Salary Bonus city
101 Aaliya 10000 234 Pune
102 Kritika 60000 123 Mumbai

 

 

d) select Ename , salary from employee where bonus > 600 ;

Ans:

Ename Salary
Joseph 34000

OR

e) select Ename,city from employee where city not in (‘pune’,’mumbai’);

Ans:

Ename City
Gurpreet Delhi
Joseph Delhi

 

 

f) select Ename,Salary*12 “annual sal”, bonus*12 “annual bonus” from employee .

Ans:

Ename annual sal annual bonus
Aaliya 120000 2808
Kritika 720000 1476
Shabbir 540000 6792
Gurpreet 228000 6780
Joseph 408000 10500

 

g) select distinct(city) from employee;

Ans:

Distinct(city)
Pune
Mumbai
Delhi

 

h) select * from employee where city like ‘%e%;

Ans:

EmpNo Ename Salary Bonus city
101 Aaliya 10000 234 Pune
103 Shabbir 45000 566 Pune
104 Gurpreet 19000 565 Delhi
105 Joseph 34000 875 Delhi

 

13. Consider the following MOVIE table and answer the SQL queries based on it. 

MovieID MovieName Category ProductionCost BusinessCost
001 Hindi_Movie Musical 124500 130000
002 Tamil_Movie Action 112000 118000
003 English_Movie Horror 245000 360000
004 Bengali_Movie Adventure 72000 100000
005 Telugu_Movie Action 100000 NULL
006 Punjabi_Movie Comedy 30500 NULL

 

a) To display MovieID, MovieName and BusinessCost of Movies.

Ans: Select MovieID, MovieName,BusinessCost from Movies;

 

b) To List the different categories of movies.

Ans: Select distinct(Category) from movies;

 

c) To display movieid,name and and Net Profit of all the movies. (Hint: Net Profit = BusinessCost – ProductionCost)

Make sure that the new column name is labelled as NetProfit.

Ans: Select Movieid,Moviename , BusinessCost – ProductionCost as “ Net Profit” from Movie

 

d) To display movieID, Name and ProductionCostof all the movies having ProductionCost greater than 80,000 and less than 1,25,000.

Ans: selectMovieid,Moviename ,ProductionCost from movie where ProductionCost> 80000 and ProductionCost <125000 ;

Leave a Reply

Your email address will not be published. Required fields are marked *