+2 votes
in Class 12 by kratos

In the table "Student", Priya wanted to increase the Marks (Column Name : Marks) of those students by 5 who have got Marks below 33. She has entered the following statement : SELECT Marks+5 FROM Student WHERE Marks<33;

Identify errors (if any) in the above statement. Rewrite the correct SQL statement.

1 Answer

+2 votes
by kratos
 
Best answer

Error : UPDATE should be used instead of SELECT

Correct SQL statement:

UPDATE Student SET Marks= Marks+5 WHERE Marks<33;.

...