Agra TERM2 XII CS QP PB1
Agra TERM2 XII CS QP PB1
CLASS:XII
General Instructions:
Internal choices have been given for question numbers 7, 8 and 12.
Q.No Marks
Section -A
. Allocated
1. What is Stack? Write any one application of Stack? 2
(i) Name the device used for security of a Network. 1
2.
(ii) Name the connector used to connect the computer with LAN. 1
Choose correct DDL,DML,DCL and TCL commands from the following:-
3. INSERT INTO, SELECT, COMMIT, GRANT, SAVEPOINT, REVOKE, ROLLBACK, 2
CREATE, UPDATE, DELETE,ALTER,ADD
4. Define Constraints in data base with suitable example. 2
5. Write SQL commands on the basis of table HOSPITAL 2
Table: HOSPITAL
Departmen
P_No Name Age Dateofadmin Fee
t
1256 Arpit 62 Surgery 21/01/06 300
8790 Zayana 18 ENT 12/12/05 250
1254 Kareem 68 Orthopaedic 19/02/06 450
1300 Abhilash 26 Surgery 24/11/06 300
1824 Dhanya 24 ENT 20/10/06 350
Page 1 of 6
(i) To add a new column as Address of type characters in table HOSPITAL.
(ii) Create a new table named PDATA having column Name, Age, Department and fee from
existing table HOSPITAL.
Arvind is learning MySQL for managing different databases and tables for his Python based
application/software. Tell him the SQL commands for the following:-
6. 2
(i) How to show pre-existing databases.
(ii) How to use a desired database.
7. Write the answers on the basis of table PRODUCT 2
Table: PRODUCT
Pno Pname Qty PurchaseDate
101 Pen 102 12-12-2011
102 Pencil 201 21-02-2013
103 Eraser 90 09-08-2010
109 Sharpener 90 31-08-2012
113 Clips 900 12-12-2011
(i) Write the names of most appropriate columns, which can be considered as Primary Key in
table PRODUCT and justify your answer.
(i) Write the names of most appropriate columns, which can be considered as Candidate Key
in table PRODUCT and justify your answer.
Page 2 of 6
(ii) Write the type of key which can be given for the identical columns in table PRODUCT
and SUPPLY.
Section-B
Avni is trying to connect Python with MySQL for her project. Help her to write the python
statement on the following:-
(i) Name the library, which should be imported to connect MySQL with Python.
(ii)Name the function, used to run SQL query in Python.
(iii) Write Python statement of connect function having the arguments values as :
Host name :192.168.11.111
User : root
Password: Admin
Database : MYPROJECT
8. 3
OR
(i) Raju’s tutor has given instructions to write a table in MySQL as given below. Help him to
get the solution.
Name of the relation should be Employee
Column name with data type as :
Empid ,integer value and set constraint as Primary Key
Empname, which can hold at least 20 characters
Empdesig, which can hold at least 15 variable characters
Empsal, which can hold decimal value in the format (4,2)
Write a function push (student) and pop (student) to add a new student name and remove a
9. student name from a list student, considering them to act as PUSH and POP operations of 3
stack Data Structure in Python.
10. Give the output of the following SQL statements using table CLUB. 3
Table : CLUB
GENDE
CID CNAME AGE SPORTS PAY DOAPP
R
5246 AMRITA 35 FEMALE CHESS 900 27/03/2006
4687 SHYAM 37 MALE CRICKET 1300 15/04/2004
1245 MEENA 23 FEMALE VOLLYBALL 1000 18/06/2007
1622 AMRIT 28 MALE KARATE 1000 05/09/2007
1256 KRISHNA 36 MALE CHESS 1100 15/08/2003
Page 3 of 6
1720 MANJU 33 FEMALE KARATE 1250 10/04/2004
2321 VIRAT 35 MALE CRICKET 1050 30/04/2005
Table: ISSUED
BID QTY_ISSUED
HIST66 10
COMP11 5
LITR88 15
(i) Display book name and author name and price of computer type books.
(ii) To increase the price of all computer books by 50.
Page 4 of 6
(iii) Show the details of all books in ascending order of their prices.
(iv) To display book id, book name and quantity issued for all books which have been issued.
(i) Name a network topology, which is used to maximize speed and make each computer
independent of network.
(ii) Suggest a switching technique in which the information is transferred using Store and
2
Forward mechanism.
OR
12. What is the difference between MAC and IP address?(any two on each)
(iii) Expand the following:-
(a) WLL
2
(b) ARPANET
(c) CSMA
(d) DNS
Polymath IT Infrastructure Limited has set up its new center in Dubai. It has four buildings as
shown in the diagram given below:
13. 4
Page 5 of 6
Number of Computers
Accounts 25
Research Lab 100
Store 15
Packaging Unit 60
As a network expert, provide the best possible answer for the following queries:
(ii) Suggest the most suitable place (i.e. buildings) to house the server of this organization.
(iv) Which fast and very effective wire based transmission medium should preferably be used
to connect the buildings for their web-based activities?
Page 6 of 6