Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

In EMP table, for those emp whose Hiredate is same, update
their sal by "sal+500" or else for others keep the sal as it
is, how to do it by SQL query

Answer Posted / guest

update emp a set a.sal=a.sal+500 where a.hiredate in(select
max(b.hiredate) from emp b group by b.hiredate having
count(b.hiredate)>1);

or

update emp a set a.sal=a.sal+500 where a.hiredate=(select
max(b.hiredate) from emp b where a.hiredate=b.hiredate group
by b.hiredate having count(b.hiredate)>1);

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is DR strategy for Informatica project?

1225


Is stop and abort are same in informatica?

1048


What are the designer tools for creating transformations?

1158


Why filter transformation is an active one?

1033


State the differences between sql override and lookup override?

1284


can any one explain about dataflow in the informatica project for bank domain....thanks is advance

10728


Calculate sum of salaries department wise. Then the sum will be repeat for all columns in each department. Develop a mapping for this.

2480


Explain the types of transformations?

1101


How to use procedural logic inside infromatica?

1321


What all join we can perform in LOOKUP transformation?

1020


How do you use reject loader.

2651


expain about the tune parameters?

2457


How to partition the Session?

1151


How to join three sources using joiner? Explain though mapping flow.

1190


How to create a non-reusable instance of reusable transformations?

1170