Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.tools -> subtracting variables in oracle

subtracting variables in oracle

From: <pankrateon_at_my-deja.com>
Date: Tue, 23 Jan 2001 18:10:14 GMT
Message-ID: <94khdv$7gh$1@nnrp1.deja.com>

the stage: Oracle 8i 8.1.6 a table that contains employee info of which there is one column labeled "pay type" The "pay type" can be "Gross" or "Bonus". An other field is "Amount"

table looks like this:

lastname | firstname | title| department | pay_type | amount

I want to be able to group by the persons name (last and first) and then subract any "Bonus" amount from their "Gross" amount

I would want to create a view that looks as follows:

lastname | firstname | title| department | gross - amount

how do I do that?
is it possible have this displayed as a view?

Sent via Deja.com
http://www.deja.com/ Received on Tue Jan 23 2001 - 12:10:14 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US