We have provided Class 12 Informatics Practices Sample Paper as per the latest CBSE examination pattern for the current academic year. The following CBSE Sample Papers for Class 12 Informatics Practices has been prepared based on the guess papers issued recently. Students will be able to practice these papers and get good marks in upcoming Informatics Practices exams for Class 12.
CBSE Sample Papers for Class 12 Informatics Practices
|Class 12 Informatics Practices Sample Paper Term 1 With Solutions Set A|
|Term 2 Sample Papers|
|Class 12 Informatics Practices Sample Paper Term 2 With Solutions Set A|
|Class 12 Informatics Practices Sample Paper Term 2 With Solutions Set B|
Class 12 Informatics Practices Sample Paper Term 2 With Solutions Set A
1. Read the following passage and answer the questions that follows
Web server is a special computer system running on HTTP through web pages. The web page is a medium to carry data from one computer system to another. The working of the web server starts from the client or user. The client sends their request through the web browser to the web server. Web server takes this request, processes it and then sends back processed data to the client. The server gathers all of our web page information and sends it to the user, which we see on our computer system in the form of a web page. When the client sends a request for processing to the web server, a domain name and IP address are important to the web server. The domain name and IP address are used to identify the user on a large network.
(i) Web servers are
(a) IP addresses
(b) computer systems
(c) web pages of a site
(d) a medium to carry data from one computer to another
(ii) What does the web server need to send back information to the user?
(a) Home address
(b) Domain name
(c) IP address
(d) Both (b) and (c)
(iii) What is the full form of HTTP?
(a) HyperText Transfer Protocol
(b) HyperText Transfer Procedure
(c) Hyperlink Transfer Protocol
(d) Hyperlink Transfer Procedure
(iv) The ……… translates Internet domain and host names to IP address.
(a) domain name system
(b) routing information protocol
(c) Internet relay chat
(d) network time protocol
(v) Computer that requests the resources or data from another computer is called as ……… .
(c) Both (a) and (b)
(d) None of these
2. Write a output for SQL queries (i) to (iii), which are based on the table Student given below:
(i) SELECT COUNT(*), City FROM Student GROUP BY City HAVING COUNT(*)>1;
(ii) SELECT MAX(DOB),MIN(DOB) FROM Student;
(iii) SELECT NAME,GENDER FROM Student WHERE City= ‘‘Delhi”;
Consider the following table Games. Write SQL commands for the following statements.
(i) To display the details of those Games, which are having PrizeMoney more than 7000.
(ii) To display sum of PrizeMoney for each Type of Games.
(iii) To display the total number of games available in the above table Games.
Answer: (i) SELECT*FROM Games WHERE PrizeMoney > 7000;
(ii) SELECT SUM(PrizeMoney), Type FROM Games GROUP BY Type;
(iii) SELECT COUNT(GameName) FROM Games;
3. Differentiate between DDL comand and DML command.
Answer: Differences between DDL and DML commands are as follows
Differentiate between CHAR data type and VARCHAR data type.
Answer: Differences between CHAR and VARCHAR data types are as follows
4. State any two differences between single-row functions and multiple-row functions.
Answer: Two main differences between single-row functions and multiple-row functions are as follows
What is the difference between the ORDER BY clause and GROUP BY clause.
Answer: The ORDER BY clause is used to show the contents of a table/relation in a sorted manner with respect to the column mentioned after the ORDER BY clause. The contents of the column can be arranged in ascending or descending order.
The GROUP BY clause is used to group rows in a given column and then apply an aggregate function e.g.MAX(), MIN() etc., on the entire group.
5. Write the short note on
(i) DAYOFWEEK( ) (ii) DAYOFYEAR ( )
Answer: (i) DAYOFWEEK ( )
This function returns the week day number (1= Sunday, 2= Monday, ………, 7 = Saturday) for a date specified as an argument.
Syntax DAYOFWEEK (date/column_name)
(ii) DAYOFYEAR( )
This function returns day of the year for a given date in numeric format. The return value is within the range of 1 to 366.
Syntax DAYOFYEAR (date/column_name)
6. Consider the following EMP and DEPARTMENT tables. Write the SQL queries for (i) to (iv) and outputs for SQL
queries (v) to (viii).
(i) To display EMPNO, ENAME, SEX from the table EMP in descending order of EMPNO
(ii) To display the records of all female employee from the table EMP.
(iii) To display the EMPNO and ENAME of those employees from the table EMP who are joined between ‘2011-01-01’ and ‘2013-01-01’.
(iv) To count the number of male employees who have borned before ‘1994-01-01’
(v) SELECT COUNT(*), DEPTCODE FROM EMP GROUP BY DEPTCODE HAVING COUNT > 1;
(vi) SELECT COUNT(DISTINCT DEPTNAME) FROM DEPARTMENT;
(vii) SELECT ENAME, DEPTNAME FROM EMP E, DEPARTMENT D
WHERE E.DEPTCODE = D.DEPTCODE AND EMPNO < 104;
(viii) SELECT MIN(DOJ) MAX(DOB) FROM EMP;
Answer: (i) SELECT EMPNO, ENAME, SEX FROM EMP ORDER BY DESC;
(ii) SELECT * FROM EMP WHERE SEX = ‘F’;
(iii) SELECT EMPNO, ENAME FROM EMP WHERE DOJ BETWEEN ‘2011-01-01’ AND ‘2013-01-01’;
(iv) SELECT COUNT(EMPNO) WHERE SEX= ‘M’ AND DOJ < ‘1994-01-01’;
7. Given a table Bookhouse, write SQL query for part (i) to (v).
(i) Display the title of all books with price between 100 and 300.
(ii) Display title and author of all the books having type “Prog” and published by BPB.
(iii) Display number of books and average price for each type of publisher.
(iv) Display title, price in descending order of price.
(v) Display all the books where title starts with “D” and qty is more than 3.
Answer:(i) SELECT Title FROM Bookhouse WHERE Price BETWEEN 100 AND 300;
(ii) SELECT Title, Author FROM Bookhouse WHERE Subject=‘Prog’ AND Publisher=‘BPB’;
(iii) SELECT COUNT(*), AVG(Price) FROM Bookhouse GROUP BY Publisher;
(iv) SELECT Title, Price FROM Bookhouse ORDER BY Price DESC;
(v) SELECT * FROM Bookhouse WHERE Title LIKE ‘D%’ AND Qty>3;
Given a table Order, write SQL query for part (i) to (v). P73Q7
(i) Display the name of companies.
(ii) Insert a new row of data as (7,19/02/2007,Nike,Delhi,70000,140000)
(iii) Display the maximum and minimum orders placed for each city.
(iv) Find number of companies and average orders order by Cloc.
(v) List all orders given between 01/01/2008 to 12/10/2008.
Answer: (i) SELECT DISTINCT(CName) FROM Order;
(ii) INSERT INTO Order VALUES(8,‘19/02/2007’, ‘Nike’, ‘Delhi’,70000, 140000);
(iii) SELECT Cloc, MAX (Orders), MIN (Orders) FROM Order GROUP BY Cloc;
(iv) SELECT Cloc, COUNT(Cloc), AVG(Orders) FROM Order GROUP BY Cloc;
(v) SELECT * FROM Order WHERE Orderdate>‘01/01/2008’ AND Orderdate<‘12/10/2008’;
8. Answer the following questions.
(i)Write MySQL command that will be used to open an already existing database “CONTACT”.
(ii) The Doc_name column of a table Hospital is given below:
Based on the above information , find the output of the following queries.
(a) SELECT Doc_name FROM Hospital WHERE Doc_name LIKE ‘%v’;
(b) SELECT Doc_name FROM Hospital WHERE Doc_name LIKE ‘%e%’;
(iii) A table “Transport” in a database has degree 3 and cardinality 8. What is the number of rows and columns in it?
(iv) Define the degree and cardinality of a relation. Observe the following
Answer: (i) USE CONTACT;
(iii) Number of rows: 8
Number of columns: 3
(iv) Degree of relation It represents the total number of
columns in a relation.
The degree of the given table is 7.
Cardinality It represents the total number of row in a relation. The cardinality of the given table is 5.
(v) (a) Candidate key – Code, Item
(b) Primary key – Code
Write SQL queries for (i) to (iv) and find the output for (v).
Note PERKM is Freight Charges per kilometre
Note KM is Kilometres travelled
NOP is number of passengers travelled in vehicle.
(i) To display CNO, CNAME, TRAVELDATE from the table TRAVEL in descending order of CNO.
(ii) To display the CNAME of all the customers from the table TRAVEL who are travelling by vehicle with code V01 or V02.
(iii) To display the CNO and CNAME of those customers from the table TRAVEL who travelled between ‘2015-12-31’ and ‘2015-05-01’.
(iv) To display all the details from table TRAVEL for the customers, who have travel distance more than 120 KM in ascending order of NOP.
(v) SELECT COUNT(*), VCODE FROM TRAVEL
GROUP BY VCODE HAVING COUNT(*)>1;
Answer: (i) SELECT CNO, CNAME, TRAVELDATE
FROM TRAVEL A, VEHICLE B
WHERE A.VCODE = B.VCODE AND ORDER BY
(ii) SELECT CNAME FROM TRAVEL
WHERE VCODE = “V01” OR VCODE = “V02”;
(iii) SELECT CNO, CNAME FROM TRAVEL
WHERE TRAVELDATE BETWEEN ‘2015-12-31’ AND
(iv) SELECT * FROM TRAVEL
WHERE KM>120 ORDER BY NOP;
9. WeAtWork consultants are setting up a secured network for their office campus at Gurgaon for their day-to-day office and web-based activities. They are planning to have connectivity between 3 buildings and the head office situated in Mumbai. Answer the questions (i) to (v) after going through the building positions in the campus and other details, which are given below:
(i) Suggest the most suitable place (i.e. building) to house the server of this organization. Also, give a reason to justify your suggested location.
(ii) Suggest a network device needed to connect GREEN and RED building by UTP cable.
(iii) Suggest the device to connect all computer in each building.
(iv) The organization is planning to provide a high speed link with its head office situated in ‘‘MUMBAI’’ using a wired connection. Which of the following cables will be most suitable for this?
(a) Optical fibre
(b) Co-axial cable
(c) Ethernet cable
(v) Suggest the most appropriate media to connect Head Office to new office which is planning to setup inside Arabian Sea where it is not possible to lay cables.
Answer: (i) In building RED as it has maximum number of computers.
(iii) (a) Switch
(iv) (a) Optical fibre
Write the short note on the following:
(i)Web server (ii) Purpose of cookies (iii) Mesh topology
Answer: (i) Web Server A web server is software and hardware that uses the HyperText Transfer Protocol and some other protocols to respond to client requests made over the World Wide Web. The main job of a web server is to display website content through storing, processing and delivering web pages to users.
Web server hardware is connected to the Internet and allows data to be exchanged with other connected devices, while web server software controls how a user accesses hosted files. The web server process is an example of client/server model.
(ii) Purpose of Cookies Cookies are text files with small pieces of data — like a username and password — that are used to identify our computer as we use a computer network.
Specific cookies known as HTTP cookies are used to identify specific users and improve our web browsing experience. Data stored in a cookie is created by the server upon our connection. This data is labeled with an ID unique to us and our computer. When the cookie is exchanged between our computer and the network server, the server reads the ID and knows what information need to specifically serve to us.
(iii) Mesh Topology Mesh topology is an arrangement of the network in which computers are interconnected with each other through various redundant connections. There are multiple paths from one computer to another computer. It does not contain the switch, hub or any central computer which acts as a central point of communication. The Internet is an example of the mesh topology. Mesh topology is mainly used for WAN implementations where communication failures are a critical concern. Mesh topology is mainly used for wireless networks.
Mesh topology can be formed by using the formula: Number of cables = (n*(n-1))/2; where, n is the number of nodes that represents the network.