Here, I have some student Information In table. Whose authorized value is by default 0.
After checking some condition i group some students and update there value to 1.
Only those students who meets the given condition i.e.
select * from studentA
where schName ='IES DADAR' and lang = 'E'
[1]: http://rk.somee.com/untitled.jpg
I am trying with the following code but its not filtering as per my given condition, instead it changes every students authorization value to 1.
update studentA
set Authorized = '1'
where Authorized IN
( select Authorized from studentA
where schName ='IES DADAR' and lang = 'E')
You can suggest me another method as well.
try