Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> more info
I figured out how to count individual rows that have all -99 (sum all teh read1-24 and see if they add up to -2497.5)
The problem is still how to find meter_ids where the amount of rows that meet that criteria cover more than 30 consective days (each row = one day)
it gets at question of how to count the occurance of something withour using count nescessarily
ideally i would like to get as a result a list of meter_ids that meet the criteria
In article <LMLX2.3607$tT1.124626_at_newscene.newscene.com>,
ramdan_at_mailexcite.com (ramdan) wrote:
>I need to know if: Is is possible to determine which meter_ids have more than
>30 consective days of -99 readings in the period from 1/96 to 12/98?
>
>I have a 2,000,0000 row table with the following structure
>
>meter_id varchar
>reading_dt date
>read1-24 number
>
>
>meter_id reading_date read1 read2....read24
>243344 01/01/1996 3 41 -99 4
>...
>243344 12/31/19998 4 -99 65 2
>36456 01/01/1996 -99 -99 -99 -99
>....
>36456 12/31/19998 -99 -99 -99 3
>
>each meter_id can have up to 1096 rows (one for each day from 1/96 to 1/98)
>some will have a value of -99 which indicates a missing read.
>
>What I need to know is: Is is possible to determine which meter_ids have more
>than 30 consective days of -99 readings in the period from 1/96 to 12/98? I
>need at least 30 not less
>
>
Received on Tue May 04 1999 - 21:20:22 CDT
![]() |
![]() |