Database Concepts Impotant Questions
Database Concepts Impotant Questions
Database Concepts Impotant Questions
SECTION – A
SECTION – B
16 Consider the table CLUB given below and write the output of the SQL queries that follow. 3
(iii) SELECT CNAME, AGE, PAY FROM CLUB WHERE GENDER = "MALE" AND PAY
BETWEEN 1000 AND 1200;
17 Consider the table Personal given below: Table: Personal 3
Based on the given table, write SQL queries for the following:
(i) Increase the salary by 5% of personals whose allowance is known.
(ii) Display Name and Total Salary (sum of Salary and Allowance) of all personals. The
column heading ‘Total Salary’ should also be displayed.
(iii) Delete the record of personals who have salary greater than 25000
18 (b) Write the output of the queries (i) to (iv) based on the table, TECH_COURSE given 3
below: Table: TECH_COURSE
(i) SELECT DISTINCT TID FROM TECH_COURSE;
(ii) SELECT TID, COUNT(*), MIN(FEES) FROM TECH_COURSE ;
(iii) SELECT CNAME FROM TECH_COURSE WHERE FEES>15000 ORDER BY
CNAME;
(iv) SELECT AVG(FEES) FROM TECH_COURSE WHERE FEES BETWEEN 15000
AND 17000;
19 Write the outputs of the SQL queries (I) to (iii) based on the relations Emp and dept given 3
below:
VARCH NUMB
Datatype NUMBER VARCHAR VARCHAR
AR ER
Length 6 20 30 9, 2 2
SECTION – D
22 Consider the following table named SBOP with details of account holders. Write 1*4=4
commands of MySql for (i) to (iv) and output for (v) to (vii).
TABLE: SHOP