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

Home -> Community -> Usenet -> c.d.o.server -> Re: Case sensitive

Re: Case sensitive

From: Howard J. Rogers <dba_at_hjrdba.com>
Date: Fri, 19 Apr 2002 21:17:13 +1000
Message-ID: <a9ouf3$jus$1@lust.ihug.co.nz>


And quite right too. If you stick quotes around a d%, then the 'd' is taken entirely literally. Which is perfectly acceptable behaviour in my book.

If you mean that you have entires for employees (say) of "david" and "David" and wish a "d%" search to locate them both, you have a problem.

First, it indicates that your application is stuffed. No application should allow those sorts of mixed data into the backend, and then expect the backend to work it all out.

Second, you could put a trigger on the table: after insert or update on employee_name, insert into Uname upper(name). Then do your searches on the Uname column instead of the employee_name field.

Third: have a look at function-based indexes. Create index blah on emp upper(employee_name).... case insensitive searches using index-access search paths.

But ultimately, why you would expect a database to treat "David", "DAVID" and "david" as the same when no-one in their right mind, not even your mother-in-law, would say they were the same, I can't imagine.

Regards
HJR "Forced Microsoft User" <berdii_at_techemail.com> wrote in message news:a9otvb$mvi$1_at_ail.sri.ucl.ac.be...
> Thank you for your response, but my problem is using case sensitive on
data
>
> eg : if in my table "MyTable" I have some record in the field "MyField"
with
> uppercase and lowercase
> When I do : select * from MyTable where MyField like "d%", I match only
> records beginning whith 'd' in lowercase and not those beginning with 'D'
in
> uppercase
>
> So I want to know how changing system configuration to be able to select
all
> the data
>
> Thanks for any response
>
>
Received on Fri Apr 19 2002 - 06:17:13 CDT

Original text of this message

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