Collation change accent sensitive column

378 Views Asked by At

Is there any way to make search query accent sensitive in one column of my table?

the column's and table's collation are in LATIN1_GENERAL_CS and I don't want to change the table.

How to change the values of my column that they are already with accent: Example replace "Systèmes" with Systemes ?

ALTER TABLE NameTable MODIFY COLUMN NameColumn varchar(40) COLLATE LATIN1_GENERAL_CS

1

There are 1 best solutions below

2
SQLpro On BEST ANSWER

Off course you can...

  1. modify one column of your table

  2. use the COLLATE operator in the query to retrieve data with a CI/CS or AI/AS (or much more)

    ALTER TABLE <table_name> ALTER COLUMN <columns_name> <data_type> COLLATE collation_name

or

SELECT *
FROM   <table_name>
WHERE  <columns_name> COLLATE Latin1_General_CI_AI = 'Système'