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 -> Returning Range of values where gaps exist

Returning Range of values where gaps exist

From: Tim Frawley <tim_frawley_at_fishgame.state.ak.us>
Date: 23 Apr 2003 16:33:51 -0700
Message-ID: <bfb6a0a.0304231533.7bcdc414@posting.google.com>


I have data that looks like this.

51	200201049	051	JWC
52	200201049	052	JWC
53	200201049	053	JWC
54	200201049	054	JWC
55	200201049	055	JWC
56	200201049	101	JWC
57	200201049	102	JWC
58	200201049	103	JWC
59	200201049	104	JWC
60	200201049	105	JWC
61	200201049	106	JWC
62	200201049	107	JWC

What I want to do if possible is use SQL to returns two rows that looks like this.

Sample ID Start End Reader

200201049    051    055     JWC
200201049    101    107     JWC

The data would return two rows displaying the consecutive range creating a new row where a gap exists.

Is this possilbe? Received on Wed Apr 23 2003 - 18:33:51 CDT

Original text of this message

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