Case Inensitive Query on a Case Sensitive Column in SQL Server

In this example we will use the following table with one case sensitive column:


When we query data from a case sensitive (CS) table column in SQL Server, we get the following result:

SELECT * FROM ci_test
WHERE Text = 'Abc'


To do a case insensitive (CI) search on a case sensitive table column, use the following query:

SELECT * FROM ci_test
WHERE Text COLLATE SQL_Latin1_General_CP1_CI_AS = 'Abc'


Column can be made case insensitive when table is designed, using the following query:
CREATE TABLE ci_test (Text nvarchar(50) COLLATE SQL_Latin1_General_CP1_CI_AS)

Querying a column that was designed as case insensitive will be case insensitive: