Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: simple sql
"SPIDERMAN" <consultant2b_at_hotmail.com> wrote in message news:<_YUTa.71483$R92.17537_at_news2.central.cox.net>...
> Could someone help me with writing a query that would accomplish the
> following. Thank you.
>
>
> PAY_TABLE: EMP_ID, DEPT_ID, COMMISSION
>
>
>
>
>
>
>
> Inserting into PAY_TABLE a new employee 10 who works for department 20 and
> earns a
>
> commission that is equal to the commission earned by employee 3
INSERT INTO PAY_TABLE ( EMP_ID, DEPT_ID, COMMISSION ) SELECT 10, 20 b.COMMISSION FROM PAY_TABLE b WHERE b.EMP_ID = 3;
Greetings, and don't ever forget Gwen Stacy. Received on Fri Jul 25 2003 - 06:07:27 CDT
![]() |
![]() |