0

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

BARIK FATI
  • 29
  • 9

1 Answers1

0

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'
SQLpro
  • 3,994
  • 1
  • 6
  • 14
  • Thanks for your answer, I tried the last SQL Query but I dont have the collation with accent insensitive : Error: Unknown collation: 'Latin1_General_CI_AI' . – BARIK FATI Jan 11 '21 at 07:55
  • 1
    try to use one of the collations returned by the following query: SELECT * FROM sys.fn_helpcollations() – SQLpro Jan 11 '21 at 12:59