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

Home -> Community -> Usenet -> c.d.o.tools -> Re: a kinder gentler LIKE

Re: a kinder gentler LIKE

From: Ulrich Pansegrau <panseg_at_zv.fhg.de>
Date: 2000/08/04
Message-ID: <398B06D5.7D4D3B9A@zv.fhg.de>#1/1

Hi,

try something like

   select * from table_name where column_name between '0' and RPAD('9',30,CHR(255)).
The second argument in RPAD ("30") is be the maximal length of your column. The third parameter (CHR(x)) is the last character in your character set.

This way, an Index on your column might be used.

Ulrich

pretzelman schrieb:

> Hello,
>
> Does anyone know how Oracle allows you to specify a pattern such as
> this:
> LIKE '[0-9]%'
> I am trying to get all values which begin with a numeric digit, followed
> by any number of characters of anything else. Oracle doesn't like this;
> IE it doesn't give me the rows I know are there. Thanks.
>
> Paul
Received on Fri Aug 04 2000 - 00:00:00 CDT

Original text of this message

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