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...

I have a table that log salary-increase-process have
fields: autoid, old_salary, acctno
and table EMP: acctno, name, salary
I want to list count increase-salary of employees, each have
old_salary, new_salary.
Help me with SELECT statement, please!

Answer Posted / abhisudipta

select distinct a.acctno,b.name,a.old_salary,b.salary,
nvl((sum(b.salary)-sum(a.old_salary)),0) count_increase
from salary_increase_process a,emp b
where a.acctno=b.acctno
group by a.acctno,b.name,a.old_salary,b.salary;

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to drop a tablespace?

1084


Give the various rollback segment states.

1086


Difference between the “verify” and “feedback” command?

1424


What's dateware house and what's clustor with practicle example

2232


What are the oracle built-in data types?

1134


Can I create users through internet explorer in oracle 10g?

1154


How to define a record variable to store a table row?

1109


What is oracle used for?

1068


Why do I get java.lang.abstractmethoderror when trying to load a blob in the db?

1065


Is there a combination of "like" and "in" in sql?

1114


What are temporal data types in oracle?

1164


What are the different editions of oracle?

1176


How to convert numbers to characters in oracle?

1077


Point out the difference between user tables and data dictionary?

1032


State some uses of redo log files?

1064