Hi all,
I have got a table TEMPO with only one column CODE of varchar type with the unique index on it.
There are two records in the table:
record1 contains Code1
record1 contains Code2
***********************
Problem definition:
***********************
Running the following update sql:
update TEMPO
set CODE = 'code1'
where CODE = 'Code2'
modifies the table so that record1 has Code1 and record2 has code1. This is exactly how we expect it to work as the unique index on the text fields is case sensitive (Code1 and code2 are not the same, the case is different)
Running the following insert sql:
insert into TEMPO
values ('coDe1')
throws an error indicating that this insert statement conflicts with the unique index placed on the CODE column.
Is it a bug in SQL Server or am I missing something?
Thank you all in advance.
SA23.
I have got a table TEMPO with only one column CODE of varchar type with the unique index on it.
There are two records in the table:
record1 contains Code1
record1 contains Code2
***********************
Problem definition:
***********************
Running the following update sql:
update TEMPO
set CODE = 'code1'
where CODE = 'Code2'
modifies the table so that record1 has Code1 and record2 has code1. This is exactly how we expect it to work as the unique index on the text fields is case sensitive (Code1 and code2 are not the same, the case is different)
Running the following insert sql:
insert into TEMPO
values ('coDe1')
throws an error indicating that this insert statement conflicts with the unique index placed on the CODE column.
Is it a bug in SQL Server or am I missing something?
Thank you all in advance.
SA23.