SQL SELECT LIKE (Insensitive casing)

后端 未结 9 1794
野性不改
野性不改 2021-02-02 05:32

I am trying to execute the sql query:

select * from table where column like \'%value%\';

But the data is saved as \'Value\' ( V is capital ).

9条回答
  •  失恋的感觉
    2021-02-02 06:25

    you should use either lower or upper function to ignore the case while you are searching for some field using like.

    select * from student where upper(sname) like 'S%';
    

    OR

    select * from student where lower(sname) like 'S%';
    

提交回复
热议问题