Q. In the added column Grade, assign grades as follows –

if sal is in range 700 -1500, Grade is 1

if sal is in range 1500 - 2200, Grade is 2

if sal is in range 2200 -3000, Grade is 3

if sal is in range 3000 - Grade is 4


Table ---


Answer =

update Empl
set grade = 1
where sal between 700 and 1500 ;

update Empl
set grade = 2
where sal between 1500 and 2200 ;

update Empl
set grade = 3
where sal between 2200 and 3000 ;

update Empl
set grade = 4
where sal = 3000 ;

3 Comments

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post