Ignore case in SQL select - Page 2
DBAsupport.com Forums - Powered by vBulletin
Page 2 of 2 FirstFirst 12
Results 11 to 13 of 13

Thread: Ignore case in SQL select

  1. #11
    Join Date
    Oct 2000
    Location
    Dallas:TX:USA
    Posts
    407
    Hemant,
    you have to use only one combination with Upper or Lower.

    select name from name_table
    where UPPER(name) = ' KRISHNA';

    will return ALL the rows --

    name
    -----------
    Krishna
    KRishna
    KRishnA
    kRiSHNa
    KriSHNA
    KRISHNa
    KRISHNA
    KriShNa

    - Rajeev
    Rajeev Suri

  2. #12
    Join Date
    May 2001
    Location
    Atlanta US
    Posts
    262
    Yes Rajeev,
    Got it.

    Thanks a deal.
    Hemant

  3. #13
    Join Date
    Nov 2000
    Location
    Atlanta, GA, USA
    Posts
    85
    the following will return all the values you specified.

    select ename from emp where lower(ename) like 'krishn%';

    If you want this statement to use an index, you have to create a function based index.

    Robel

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width