Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
sqlfresher2k7
Aged Yak Warrior
623 Posts |
Posted - 2012-02-15 : 14:21:30
|
Can i create an index on the varchar column with the data like below with having 10 millions records the performance is very slow..As it has like operators to delete the records..Colname--------01/12/12 11:26:04;Num_Categpru;Start;1Please advise.Thanks for you help in advance.. |
|
GilaMonster
Master Smack Fu Yak Hacker
4507 Posts |
Posted - 2012-02-15 : 14:23:04
|
You can create an index, whether it will be of any use however is another matter...May I suggest normalisation?--Gail ShawSQL Server MVP |
 |
|
sqlfresher2k7
Aged Yak Warrior
623 Posts |
Posted - 2012-02-15 : 14:37:01
|
if we create an index would be any improve performance..Can you please elaborate on your suggestion what exactly i had to normalise.. |
 |
|
X002548
Not Just a Number
15586 Posts |
|
sqlfresher2k7
Aged Yak Warrior
623 Posts |
Posted - 2012-02-15 : 14:48:31
|
Table has 2 columnsTableAColumn1 vachar (50)column2 varchar(50)Above is the table structure.I am trying to delete records with where like operators. |
 |
|
GilaMonster
Master Smack Fu Yak Hacker
4507 Posts |
Posted - 2012-02-15 : 14:54:21
|
quote: Originally posted by sqlfresher2k7 if we create an index would be any improve performance..
If your queries use a SARGable predicate, probably yesquote: Can you please elaborate on your suggestion what exactly i had to normalise..
The table. You have a semicolon-delimited list in a field, that's a violation of 1st normal form and an absolute mess when it comes to filtering on subsets of the column or changing subsets of the column.01/12/12 11:26:04;Num_Categpru;Start;1 should be four columns, not 1. A datetime, a varchar, a second varchar and an int (or smallint)--Gail ShawSQL Server MVP |
 |
|
|
|
|