Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
FIRST TERMINAL EXAMINATION 2016 CLASS XII INFORMATICS PRACTICES-MARKING SCHEME TIME-3 HRS. GENERAL INSTRUCTIONS: MM-70 All questions are compulsory. Answer the questions after carefully reading the text. 1. (a) Two doctors have connected their mobile phones to transfer a picture file of a person suffering from a skin disease. What type of network is formed? Which communication media out of Coaxial cable, Optical fibre, Bluetooth, Satellite link should be used to transfer the file? 1 A. COMMUNICATION MEDIA – BLUETOOTH TYPE OF NETWORK - PAN (PERSONAL AREA NETWORK) (b) State reasons why Star Topology requires more cable length than Bus topology. 2 Bus Topology has a main run of linear cable to which all nodes connect whereas in Star Topology has a central hub or switch to which all nodes need to connect individually. Hence more the nodes, more the cable length needed. Thus Star topology requires more cable length than Bus topology. (c) “Open Source software developers work for the good of community.” Is this statement true? Give reasons. 2 Yes, the given statement is true. The reasons to support it are: -Open source makes available software mostly free of cost, thus within reach of all segments of society. -Open source gives freedom to see the code, to learn from it, to improve and modify it. Thus it spreads values like meritocracy, community building and transparency. (d) What happens during “Domain Name Resolution”? 2 Users use URLs (e.g., www.edupillar.com) to connect to websites on Internet, whereas, Internet applications communicate with one another through IP addresses (e.g., 182.50.130.158). Domain Name Resolution is the process of conveying URLs or domain names to their corresponding IP addresses. It works like: When we enter a URL in our web browser, can browser contacts its DNS server to resolve this name. A DNS server is further connected to other DNS servers which recursively search and then finally return the corresponding IP address. Using the obtained IP address the web browser can actually connect and open the desired web site. (e) How is “Denial of service” attack, a threat to Network security? 2 Denial-of-service (DoS) attacks that prevent the legitimate users of the system, from accessing or using the resources, information, or capabilities of the system. Since DoS attacks forbid a user to use a network, these can be termed as a threat to Network Security. (f) How is firewall useful in ensuring network security. 1 A firewall is a network security system, either hardware – or software-based, that controls incoming and outgoing traffic based on a set of rules. A firewall grants or rejects network-traffic flow between Internet and a private or corporate network. (g) Name one open source Indian operating system. BOSS (Bharat Operating Systems Solutions) 1 (h) What do the following top level domains signify – (i) .com (ii) .org 2 .com-commercial organizations, .org- non profit organizations. (i) Distinguish between MAC address and IP address with the help of example of each. 2 MAC address refers to the physical address assigned by NIC manufacturer. It is a 6 byte address with each byte separated by colon. For example, 20: A6: E9: 45: AF: 2E. IP addresses refers to the logical address (unique) assigned to all machines on a TCP/IP network. It is a 4 byte address with each byte separated by dot (.) . For example, 192.168.52.2. (j) Distinguish between Phonetic text entry and keymap based entry of typing Indian Language text. 2 Typing of words as per their pronunciation in English script and later converted to corresponding language word is known as Phonetic Text Entry. For example, if we type as ‘mera desh mahan’ It’ll transliterate it as The mappings of a keyboard’s key to specific characters are known as key map based Text Entry. For example, if we press the key horizontally adjacent to capslock key on keyboard, the letter “a” gets typed. So this key has been mapped to character ‘a’. (k) What was the objective behind developing UNICODE? 1 The objective behind developing UNICODE was to have single standard code for all known languages of the world. (l) Expand the term: ODF 1 ODF- open document format (m) Identify the following devices: (i) A device that is used to connect different types of networks. It performs the necessary translation so that the connected networks can communicate properly. (ii) A device that converts data from digital bit stream into an analog signal and vice-versa. 1 Gateway , Modem Q2.(a) “In e-Business, customers should shop only when they trust the e-store provider for payment methods”. Justify the statement. 1 In e-business security of transaction is very important in terms of : - security of personal information - security of payment transaction (information related to bank account, credit cards, passwords etc.) If the personal information and payment related information are securely handled by an e-business site, then only customers should shop from that e-store. (b) How is e-learning beneficial for old people? Write one point. 1 E-learning is beneficial because it gives freedom to learn at own pace and time from own home. (c) How is an e-commerce business more cost effective than traditional business? Write one point. 1 It requires no brick and mortar office, Can reach globally, Buying and selling speeds are faster. (d) How does e-governance empower citizens? Write one point. 1 e-governance portals have helped citizens by reducing the number of trips to government offices by nearly 11% to 27%. (e) Define e-business. Name one popularly used e-business website. 1 e-business refers to any form of transaction (exchange) that uses an electronic medium to facilitate the transaction. A popularly used e-business website is : www.amazon.com (f) List two features of a good interface. 1 A good interface has following features: - It should have pleasant color combination so that the user likes to use it. -It should have all the relevant options for all the required fields so that the user is at ease while entering the data. (g) What is front-end and back-end? Also give one example for each. 2 FRONT END – This is the user interface that the user sees and which is responsible for interacting with the user. The front-end is responsible for receiving user’s queries, requests atc. And passing it over to the back –end. Example, Netbeans. BACK END – It is that part of the application that does the real processing work or gets it done from the server. It is responsible for processing data for user queries and requests. (h) Ms. Arora is creating a form for accepting Visa applications. Help her to choose most appropriate controls out of Listbox, ComboBox, TextField, TextArea, RadioButton, CheckBox, Label and CommandButton for the following entries: S.No. 1. 2. 3. 4. 2 Function To enter EMAIL ID To choose GENDER To enter NATIONALITY from countries given as options. To enter REMARKS in the form of a paragraph about the purpose of visit. TEXTFIELD , RADIO BUTTON, LIST BOX , TEXT AREA Q3.(a) What is MySQL? 1 MYSQL is an open source Relational Database Management System. (b) Chavi is inserting “Sharma” in the “lastname” column of the table “Emp” but an error is being displayed. Write the correct SQL statement. INSERT INTO EMP(‘SHARMA’) VALUES(LASTNAME); 1 INSERT INTO EMP(LASTNAME) VALUES(‘SHARMA’); (C) In a table ‘Employee’, a column ‘Occupation’ contains many duplicate values. Which keyword would you use if you wish to list only different values? 1 DISTINCT (d) If you wants to delete the records where the ‘Firstname’ is ‘Rama’ in the Emp table. Rewrite the correct statement: DELETE ‘RAMA’ FIRSTNAME FROM EMP; 1 DELETE FROM EMP WHERE FIRSTNAME=’RAMA’; (e) Name two Group or Aggregate functions of SQL. Also explain the meaning of one. SUM() , AVG(), MAX(), MIN(), COUNT(), COUNT(*) SUM() FUNCTION IS USED TO FIND THE TOTAL OF ALL THE VALUES GIVEN. 1 (f) Consider the table: COMPANY COMPANYCODE C101 C102 C104 C105 1 DONATIONS 13000 NULL 7000 4000 What output will be displayed by the following SQL statement? Select avg(donations) from company; 8000 (g) Consider the table below: TABLE : COMPANY EMPID E101 E102 E103 1 DEPARTMENT PERSONNEL ACCOUNTS PERSONNEL SALARY 60000 65000 52000 Identify error in the following statement. Rewrite the correct SQL statement. SELECT DEPARTMENT,SALARY FROM COMPANY GROUP BY DEPARTMENT; SELECT DEPARTMENT, SUM(SALARY) FROM COMPANY GROUP BY DEPARTMENT; (h) How is Primary key constraint different from Unique key constraint? 1 A table can have multiple sets of columns with UNIQUE constraint, whereas the PRIMARY KEY constraint can be only a single set of columns. Also unlike the PRIMARY KEY constraint the UNIQUE constraint allows NULL values. (i) Write one similarity & one difference between CHAR and VARCHAR data type. 1 Both CHAR and VARCHAR types are used to store character string values ranging from 1-255 characters in length, however they behave differently. CHAR datatype specifies a fixed length character such that strings having length smaller than the field size are padded on the right with spaces before being stored. The VARCHAR on the other hand supports variable length strings and therefore stores actual sizes of strings even if smaller than the field size. (j) Given below is the ‘EMP’ table: ENO NAME 1 Anita Khanna 2 Bishmeet Singh SET AUTOCOMMIT=0; INSERT INTO EMP VALUES(5,’Farzia’); COMMIT; UPDATE EMP SET NAME=’Farzziya’ WHERE ENO=5; SAVEPOINT A; INSERT INTO EMP VALUES(6,’Richard’); SAVEPOINT B; INSERT INTO EMP VALUES(7,’Rajyalakshmi’); SAVEPOINT C; ROLLBACK TO B; What will be the output of the following SQL query now? SELECT * FROM EMP; 1 ENO 1 2 5 6 NAME Anita Khanna Bishmeet Singh Farzziya Richard Q4.(a) Srishti has created the following table with the name ‘VETERINARY’. Column name AnimalId VaccinationsDate Animal Name OwnerName Constraint Primary key 1 + 1 Not null One of the rows inserted is as follows: AnimalId VaccinationsDate AnimalName OwnerName A101 2015-02-12 Sheru Amit Sharma (i) What are the data type of columns AnimalId and VaccinationsDate in the table Veterinary? (ii) Shrishti is now trying to insert the following row: AnimalId A102 VaccinationsDate AnimalName 2015-08-09 NULL OwnerName Abhi Shah Will she be able to successfully insert it? Give reason. i. AnimalId – Char/ Varchar , VaccinationsDate – Date ii. No, row insertion will not be successful. Reason being that the row being inserted is violating NOT NULL constraint by trying to insert NULL in AnimalName field. (b) Write the output of the following SQL queries: i) SELECT MID(‘LEARNINGISFUN’,2,4); ii) SELECT ROUND(76.384,2); iii) SELECT INSTR(“INFORMATION FORM’,’RM’); iv) SELECT DAYOFYEAR(‘2015-01-30’); i. EARN (C) ii. 76.38 iii. 5 2 iv. 30 Table “Order” is shown below. Write commands in SQL for i to iv and output for v and vi. orderid orderdate salesperson Orderamount O101 2015-09-12 Ravi Kumar 34000 O102 2015-08-15 Rashmi Arora 50000 O103 2015-11-01 Ravi Kumar 55000 O104 2015-12-09 Manjeet Singh 60000 O105 2015-11-10 Rashmi Arora 50000 (i) To display names of salespersons (without duplicates). (ii) To list ordered and respective orderamount in descending order of orderamount. (iii) To count the number of orders booked by salespersons with names starting with ‘R’. (iv) To list order ids, order dates and order amounts that were booked after 1st September 2015. (v) SELECT orderid, orderamount FROM ORDER WHERE orderamount between 50000 and 60000; 6 (vi) SELECT concat(ordered, salesperson), length(salesperson) from order; i. SELECT DISTINCT SALESPERSON FROM ORDER; ii. SELECT ORDERID , ORDERAMOUNT FROM ORDER ORDER BY ORDERAMOUNT DESC; iii. SELECT COUNT(*) FROM ODER WHERE SALESPERSON LIKE “R%”; iv. SELECT ORDERID,ORDERDATE,ORDERAMOUNT FROM ORDER WHERE ORDERDATE>’2015-09-01’; v. ORDERID ORDERAMOUNT O102 50000 O103 55000 O104 60000 O105 50000 vi. O101Ravi Kumar 10 O102Rashmi Arora 12 O103Ravi Kumar 10 O104Manjeet Singh 13 O105Rashmi Arora 12 (d) Distinguish between Single Row and Aggregate functions of MySQL. Write one example of each. 1 Single Row functions work with a single row at a time. A single row function returns a result for every row of a queried table. For example, pow(), year(), length(), etc. Aggregate functions work on a number of values of a column / expression and return a single value as a result. For example, min() , max() , sum(), etc. (e) What is the degree and cardinality of table:Order in Q4(c). 1 Degree=4 , Cardinality = 5 (f) What is the difference between % and _(underscore) wild card characters with reference to LIKE clause of MySQL. 1 Underscore (_) character matches any one character and percent (%) character matches any substring when used with LIKE operator for pattern matching in SQL e.g. LIKE “A_” will match all 2 character values starting with A, but LIKE “A%” will match all strings having any number of characters but starting with letter A. (g) Name the SQL commands used to: (i) Physically delete a table from the database. (ii) Display the structure of a table. i. DROP 2 ii. DESC Q5.(a) Write SQL query to create a table ‘Song’ with the following Structure: Field Songid Title Duration Releasedate Type Integer Varchar(50) Integer Date 2 Constraint Primary key CREATE TABLE SONG( SONGID INTEGER PRIMARY KEY, TITLE VARCHAR(50), DURATION INTEGER, RELEASEDATE DATE); (b) Consider the tables given below: Table: PARTY PartyId Description P101 Birthday P102 Wedding 2 CostPerPerson 400 700 P103 P104 Table: CLIENT CLIENTID C101 C102 C103 C104 (i) (ii) Farewell Engagement CLIENTNAME ADDRESS A K Antony A-151, Adarsh Nagar Fauzia Aria K-5/52, Vikas Vihar Rashi D-6, Hakikat Khanna Nagar S K Chandra 76-A/2, MIG Colony, Adarsh Avenue 350 450 PHONE 991019566 NOOFGUESTS PARTYID 80 P101 893466448 500 P102 981166568 50 P101 65877756 100 P104 Name the Primary key in both the tables. ‘P101’ data is present twice in column ‘PartyId’ in ‘Client’ table-Is there any discrepancy? Give reason for your answer. i. Table PARTY – Primary Key PartyId , Table CLIENT – Primary Key ClientId ii. No, it is not a discrepancy because PartyId is not the primary key of table Client. Thus, there can be duplicate values in it. (c) With reference to above tables write SQL commands for i and ii and output for iii given below: (i) To display client names of clients, their phone numbers, partyid and party description who will have number of guests more than 50 for their parties. (ii) To display client ids, their addresses, number of guests of those clients who have ‘Adarsh’ anywhere in their addresses. (iii) SELECT CLIENTID, CLIENTNAME, NOOFGUESTS, DESCRIPTION, COSTPERPERSON FROM CLIENT, PARTY WHERE CLIENT.PARTYID = PARTY.PARTYID AND NOOFGUESTS BETWEEN 50 AND 100; 6 i. SELECT CLIENTNAME,PHONE,P.PARTYID,DESCRIPTION FROM PARTY P, CLIENT C WHERE P.PARTYID=C.PARTYID AND C.NOOFGUESTS > 50; ii. SELECT CLIENTID, ADDRESS, NOOFGUESTS FROM CLIENT WHERE ADDRESS LIKE “%Adarsh”; iii. C101 A K Antony 80 Birthday 400 C103 Rashi Khanna 50 Birthday 400 C104 S K Chandra 100 Engagement 450 (d) Write MySQL command to create the table DEPARTMENT: Column name Datatype(size) Constraint Departmentid Int(4) Primary key Depname Varchar(50) Not null Managerid Char(4) location Varchar(30) 2 CREATE TABLE DEPARTMENT(DEPARTMENTID INTEGER(4) PRIMARY KEY, DEPNAME VARCHAR(50) NOT NULL, MANAGERID CHAR(4), LOCATION VARCHAR(30)); (e) What is the use of commit statement? Why is it different from rollback? 1 COMMIT is used to make changes done by transaction permanent on a database whereas ROLLBACK un-does the uncommitted changes in the database. (f) With reference to tables in Q5.(b) part identify the foreign key. 1 PartyId of CLIENT table. (g) Name a function of MySQL which is used to remove trailing and leading spaces from a string. TRIM 1