How to update salary of employees department wise?

Answer Posted / ajit nayak

update emp
set sal = case Deptno when 10 then 1000
when 20 then 2000
when 30 then 3000
else 0
end;

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference among union, minus and intersect?

544


What is consistency?

707


what are rollup and cube in t-sql? : Transact sql

657


Is inner join faster than left join?

629


How do I run a program in pl sql?

496






What is difference between sql and oracle?

560


What is an escape character in sql?

560


What is time based sql injection?

485


Write a sql query to find the names of employees that begin with ‘a’?

574


How do sql triggers work?

548


How many subqueries can be nested in a statement?

501


What are different functions in sql?

513


How to avoid duplicate records in a query?

575


What is not equal in sql?

508


How do you write an inner join query?

507