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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Help: SELECT STATEMENT

Re: Help: SELECT STATEMENT

From: <mjp_ttc_at_my-deja.com>
Date: Tue, 14 Mar 2000 20:28:03 GMT
Message-ID: <8am7cf$83i$1@nnrp1.deja.com>

Hi JM, I think that you can write a SQL Statement

       that can be like the above.

Greetings

In article <P7hz4.31817$t7.1892238_at_news1.rdc2.tx.home.com>, "JM" <riper_at_yahoo.com> wrote:

> I have following table:
>
> Switch-column position-column Time
> switchA On 1:00
> switchA Off 2:00
> switchD On 1:00
> switchB Off 1:00
> switchD Off 2:00
> switchC Off 1:00
> switchC Off 2:00
> =============================
> I need following output:
>
> Switch On-Total Off-Total
> switchA 1 1
> SwitchB 0 1
> SwitchC 0 2
> SwitchD 1 1
> ==============================
> As above the output is grouped by Switch column. I can't figure out
how to
> split
> position-column into "on-total' and "off-total" columns using SELECT
> statement.
>
> Thanks in advance!
> Manny
>
>


Sent via Deja.com http://www.deja.com/
Before you buy. Received on Tue Mar 14 2000 - 14:28:03 CST

Original text of this message

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