LoginSignup
2
5

More than 5 years have passed since last update.

大文字小文字を区別しない比較 #PostgreSQL

Last updated at Posted at 2015-04-13

方法1: 大文字小文字を統一して比較

SELECT * FROM table WHERE LOWER(column) = LOWER('KEYWORD');

方法2: ILIKEを利用して比較

SELECT * FROM table WHERE column ILIKE 'KEYWORD';

方法3: POSIX様式を利用して比較

SELECT * FROM table WHERE column ~~* 'KEYWORD';
2
5
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
5