Reputation: 3478
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?
Upvotes: 0
Views: 722
Reputation: 5746
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)
Upvotes: 2