0

I have a Data table whose primary key should be case sensitive. i.e. 'abc' and 'ABC' should be considered unique. Hence I have enabled CaseSensitive property of a datatable to true. But the performance is degraded as I am loading 6000+ items in the table. Is there any way that I can disable the casesensitivity after loading the data or any other way to implement this?

madth3
  • 7,275
  • 12
  • 50
  • 74
Amit
  • 3,358
  • 9
  • 34
  • 48
  • 2
    please, try to see on this problem on other side...it seems as a "big problem"...:) The fast solution: don't touch casesensivity and maybe is better to add some field to the primary key. – garik Jul 30 '10 at 11:19

1 Answers1

2

The fast solution: don't touch case sensitivity and maybe is better to add some field to the primary key (or use other). It is a good practice to separate "business keys" data and database data integrity keys.

Sample: UserId (PK) and UserLogin (business key also unique)

garik
  • 5,669
  • 5
  • 30
  • 42