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 -> Finding "surrounding" rows of a matching field?

Finding "surrounding" rows of a matching field?

From: Herwig Henseler <hh_at_ecce-terram.de>
Date: 1997/10/21
Message-ID: <62hr1b$t9e@news.Informatik.Uni-Oldenburg.DE>#1/1

Database experts,

I have a table with >50.000 rows and a VARCHAR2(50) column where I want to search for a pattern (maybe right-truncated). Besides getting a matching row (if there is any), I want to get 20 rows alphabetically before and after the matching row. Same if no row matches.

Since rows are not "sorted" I wonder if there is some way to use an index on that column for that purpose. Am I overlooking something? If this is not possible, will the ConText cartridge be able to solve my problem?

Thanks in advance for any help.

Herwig

-- 
ECCE TERRAM GmbH                        Herwig Henseler
Heinrichstrasse 18d                     Tel. 0441 / 500 12-0
26131 Oldenburg                         Fax. 0441 / 500 12-29
Received on Tue Oct 21 1997 - 00:00:00 CDT

Original text of this message

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