We're a community of 1076K IT Pros here for help, advice, solutions, professional growth and fun. Join us!
1,075,613 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Start New Discussion Reply to this Discussion

fragmentation_in_percent (not changing)??

I have a nightly SSIS package that reorganizes indexes that are between 10% and 40% and then a weekly package that rebuilds for anything over 40%. But Ive noticed a lot of table do not change. Example below my Location table below is just about always at 82%. Am I doing something wrong?

object_id index_id avg_fragmentation_in_percent page_count
1801213617 0 82.9268292682927 2718
1801213617 2 0 369
1801213617 3 0 250

2
Contributors
1
Reply
4 Months
Discussion Span
10 Months Ago
Last Updated
2
Views
moone009
Junior Poster
105 posts since Mar 2010
Reputation Points: 10
Solved Threads: 2
Skill Endorsements: 0

object_id index_id avg_fragmentation_in_percent page_count
> 1801213617 0 82.9268292682927 2718
1801213617 2 0 369
1801213617 3 0 250

The bold record is a heap. (table without a clustered index, which can't be organized. The way you can tell it is a heap is from the index_id column:
Index_id of 0 = heap
Index_id of 1 = clustered index
Index_id >= 2 = nonclustered index

Add a clustered index to it to help your query performance and your defrag red flags.

Here's an article on indexing.
http://sqlserverplanet.com/indexes/sql-server-indexes-tutorial/

Here's an article discussing heaps vs tables with clustered indexes.
http://www.mssqltips.com/sqlservertip/1254/clustered-tables-vs-heap-tables/

Let us know how it works out!

cutepinkbunnies
Junior Poster
157 posts since Apr 2006
Reputation Points: 15
Solved Threads: 9
Skill Endorsements: 0

This article has been dead for over three months: Start a new discussion instead

Post: Markdown Syntax: Formatting Help
 
You
 
© 2013 DaniWeb® LLC
Page rendered in 0.5247 seconds using 2.67MB