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 |
|
mara_anda
Starting Member
3 Posts |
Posted - 2004-07-28 : 13:20:48
|
| hi,I have a dba with more than 500 tables and I want to drop the indexes on the least selective columns.Please help.........thanks |
|
|
X002548
Not Just a Number
15586 Posts |
Posted - 2004-07-28 : 13:34:18
|
| What does that mean?How big is the DB?Are inserts taking a long time?Why/who told you to do this?Brett8-) |
 |
|
|
mara_anda
Starting Member
3 Posts |
Posted - 2004-07-28 : 15:31:32
|
| they want to make a performance for the application - one of them was to delete all the indexes on poor selective columns but I don't know how to make this............ |
 |
|
|
Kristen
Test
22859 Posts |
Posted - 2004-07-28 : 16:18:14
|
| You could do aSELECT (COUNT(DISTINCT MyColumn) * 100) / COUNT(*) FROM MyTablefor each column that was indexed to get some idea of the selectivityOr use EXEC sp_statistics @table_name = 'MyTable'to see the CardinalityKristen |
 |
|
|
mara_anda
Starting Member
3 Posts |
Posted - 2004-07-28 : 16:30:24
|
| in what range must be Cardinality to be considered a poor index? |
 |
|
|
Pat Phelan
Posting Yak Master
187 Posts |
Posted - 2004-07-28 : 17:03:35
|
| Amazing how these things migrate from one site to another.-PatP |
 |
|
|
Kristen
Test
22859 Posts |
Posted - 2004-07-29 : 01:31:46
|
| "in what range must be Cardinality to be considered a poor index?"Well personally I would hand tune any query which performance badly.But for the experiment you outlined above you could remove the indexes from the bottom quartile, by cardinality, or bottom, say, 10%, and see if it makes a difference.Kristen |
 |
|
|
|
|
|