Questions tagged [case-sensitive]

48 questions
27
votes
5 answers

How to do a case sensitive search in WHERE clause?

I want case sensitive search in SQL query. But by default, MySQL does not consider the case of the strings. Any idea on how to do a case sensitive search in SQL query?
Somnath Muluk
  • 1,104
  • 3
  • 13
  • 15
15
votes
1 answer

PostgreSQL nondeterministic collations are not supported for LIKE

I am using Postgresql v12. I created a collation like this: CREATE COLLATION ci (provider = icu, locale = 'tr_TR', deterministic = false); I used that collation in a table: create table testtable1 ( id serial primary key, name text …
14
votes
1 answer

Why does a comparison between 'tr' & 'tR' fail on a SQL Server with Vietnamese_CI_AI collation?

There seems to be something special about 'tR' in Vietnamese collation. Appreicate if anyone who knows about it can explain in simple terms. This issue was discovered during the installation of our product on a "Vietnamese" collated SQL Server. One…
11
votes
1 answer

How to use an array as argument to a VARIADIC function in PostgreSQL?

I am trying to make a case-insensitive version of json_extract_path_text(), using the citext module. I would like this to be a simple wrapper around the built-in function, the only difference being that it accepts citext as the first parameter…
Jake Feasel
  • 607
  • 2
  • 7
  • 23
11
votes
2 answers

Can PostgreSQL create a case sensitive database?

I'm porting some code from some version of Sybase to PostgreSQL. This is a C application that uses the Sybase client library. My approach is to write a translation layer that translates calls to dbsqlexec() to PQexec() (for example). That part is…
Greg Hewgill
  • 346
  • 2
  • 8
10
votes
1 answer

Case-insensitive collation still comparing case-sensitive

I am currently trying to create a table with a text column which will compare case insensitive by default. This is because we have a third party program that executes a search on our database. The SELECT statements used by this program can not be…
Amelia B
  • 211
  • 2
  • 7
8
votes
1 answer

Equivalent of UTF8_UNICODE_CI collation in PostgreSQL

I would like a column in a table inside a PostgreSQL database (I am using version 9.6). I know of the UTF8_UNICODE_CI collation on MySQL, so I tried: CREATE TABLE thing ( id BIGINT PRIMARY KEY ,name VARCHAR(120) NOT NULL COLLATE…
8
votes
1 answer

Case Sensitive Ordering within the CMS Server List

I've got to believe there's a reason for this, but for the life of me I cannot figure it out. It looks like ordering of Server Names within any Central Management Server is Case SENSITIVE, regardless the collation of the server acting as the CMS,…
John Eisbrener
  • 9,547
  • 6
  • 31
  • 65
7
votes
3 answers

PostgreSQL force upper case for all data

Is there a way to force all text data to uppercase without recurring to writing a function for every table or doing it client side?
Fabrizio Mazzoni
  • 1,976
  • 5
  • 22
  • 32
6
votes
3 answers

Why are unquoted identifiers upper-cased per SQL-92?

Section 5.6 of the SQL-92 standard contains rules 10...13 per which unquoted identifiers should be upper-cased, so foo becomes FOO but "foo" remains foo. These rules are respected by Oracle, IBM DB2, Snowflake, and ksqlDB but not by Postgres, MySQL…
6
votes
2 answers

MySQL What charset/collation for Case insensitivity and Accent sensitivity?

I am looking for a charset/collation that would make it so when I do a SELECT * FROM table_name WHERE username = "Warrior" It only returns me the rows where username = "Warrior", "warrior" or "WARRIOR", and not "WÂRRÎOR" "Wârrîor" etc. I found a…
lyeaf
  • 307
  • 2
  • 11
6
votes
1 answer

Creating a case-insensitive and accent/diacritics insensitive search on a field

I would like to know if it makes sense to create an index combining two functions while using Full Text Search: lower(name) and f_unaccent(name) Where f_unaccent is just my wrapper to make unaccent function immutable. I do have an index working on:…
6
votes
2 answers

MySQL case sensitive table names on Linux

Moving a MySQL database from Windows to Linux I have the problem that on Linux the names of the tables are case sensitive. This is a problem, because the Java application that I am developing can't find tables. I have changed my /etc/mysql/my.cnf…
Vitaly Olegovitch
  • 190
  • 1
  • 1
  • 7
6
votes
1 answer

pg_dump: No matching schemas were found

I am trying to dump a schema from Postgres 9.4, running on Cents 6.5, but I get an error: pg_dump: No matching schemas were found Here is the command I am running: pg_dump -U postgres -n "OLD-TODELETE-bushes" --verbose site > output_nf I am a…
Nathan Foley
  • 176
  • 1
  • 5
5
votes
1 answer

Using collations with JSONB

I have a postgres database and a case insensitive collation. The collation was created by CREATE COLLATION IF NOT EXISTS case_insensitive (provider = icu, locale = 'und-u-ks-level2', deterministic = false). (I also have another collation the removes…
Pux
  • 151
  • 3
1
2 3 4