1.

Consider the following table:StudentWrite commands in SQL for (i) to (iv):(i) To display the details of all those students who have IP as their optional subject. (ii) To display name, stream and optional of all those students whose name starts with 'A'. (iii) To give an increase of 3 in the average of all those students of humanities section who have Maths as their optional subject. (iv) To display a name list of all those students who have average more than 75.

Answer»

(i) select * from student where optional=‟IP‟;

(ii) select name, stream, optional from student where name like 'A%';

(iii) update student set average=average+3 where stream=‟Humanities‟ and optional='Maths';

(iv) select name from student where average>75;



Discussion

No Comment Found

Related InterviewSolutions